Repository :
http://git.fedorahosted.org/cgit/copr.git
On branch : master
---------------------------------------------------------------
commit 9d02b61f5b75b658ff379f3e9b6f112bdb15e14d
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 13:12:59 2013 +0100
UX - show details of build only after click
and decorate hovered line with underline
---------------------------------------------------------------
coprs_frontend/coprs/static/copr.css | 4 ++++
coprs_frontend/coprs/static/copr.js | 8 ++++----
.../templates/coprs/detail/_builds_table.html | 2 +-
3 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/coprs_frontend/coprs/static/copr.css b/coprs_frontend/coprs/static/copr.css
index cde5420..38059dc 100644
--- a/coprs_frontend/coprs/static/copr.css
+++ b/coprs_frontend/coprs/static/copr.css
@@ -266,6 +266,10 @@ table.builds-table tr.details {
display: none;
}
+tr.build-state:hover {
+ text-decoration: underline;
+}
+
tr.build-pending {
color: #3B6EB4;
}
diff --git a/coprs_frontend/coprs/static/copr.js b/coprs_frontend/coprs/static/copr.js
index cb09b34..41b9fd6 100644
--- a/coprs_frontend/coprs/static/copr.js
+++ b/coprs_frontend/coprs/static/copr.js
@@ -1,20 +1,20 @@
// showing build details
$(document).ready(function () {
$("table.builds-table tr[class^='build-']").each(function (i, e) {
- $(this).hover(function() { $("table.builds-table tr.details").hide();
$(this).next().show(); });
+ $(this).click(function() { $("table.builds-table tr.details").hide();
$(this).next().show(); });
});
});
// build detail menu arrow slider
$(document).ready(function() {
- $("div.horizontal-menu li").hover(
+ $("div.horizontal-menu li").click(
function() {
$("div.horizontal-menu
li.selected").removeClass('selected').addClass('left-for-now');
- $(this).toggleClass('hovered');
+ $(this).toggleClass('clicked');
},
function() {
$("div.horizontal-menu
li.left-for-now").removeClass('left-for-now').addClass('selected');
- $(this).toggleClass('hovered');
+ $(this).toggleClass('clicked');
}
);
});
diff --git a/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
b/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
index cc0d842..f65d7ed 100644
--- a/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
+++ b/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
@@ -12,7 +12,7 @@
<th>State</th>
</tr>
{% for build in builds %}
- <tr class="build-{{ build.state }}">
+ <tr class="build-{{ build.state }} build-state">
<td>{{ build.id }}</td>
<td>{{ build.submitted_on|date_from_secs }}</td>
<td>{{ build.user.name }}</td>