summaryrefslogtreecommitdiff
path: root/http
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2017-06-08 02:20:34 +0200
committeremkael <emkael@tlen.pl>2017-06-08 02:20:34 +0200
commit3a893a75390288ed0bc55dd1413d973f0b611ac4 (patch)
tree0a175025757a3fc69b4b2dea4cc8bc0a357cf269 /http
parentf2c215082b8735a6851935f04122dcb6af3f5291 (diff)
Captions for data table color codes
Diffstat (limited to 'http')
-rw-r--r--http/res/ranking.css6
-rw-r--r--http/res/ranking.js18
2 files changed, 12 insertions, 12 deletions
diff --git a/http/res/ranking.css b/http/res/ranking.css
index 316aa49..6a6b1c7 100644
--- a/http/res/ranking.css
+++ b/http/res/ranking.css
@@ -1,6 +1,6 @@
-.table > tbody > tr.gold > td { background-color: #FFEF96 }
-.table > tbody > tr.silver > td { background-color: #E5E5E5 }
-.table > tbody > tr.bronze > td { background-color: #CAA077 }
+.table-hover > tbody > tr.gold > td { background-color: #FFEF96 }
+.table-hover > tbody > tr.silver > td { background-color: #E5E5E5 }
+.table-hover > tbody > tr.bronze > td { background-color: #CAA077 }
.table-hover > tbody > tr.gold:hover > td { background-color: #FFE34C }
.table-hover > tbody > tr.silver:hover > td { background-color: #CDCDCD }
.table-hover > tbody > tr.bronze:hover > td { background-color: #B88048 }
diff --git a/http/res/ranking.js b/http/res/ranking.js
index 1e34732..1cf09ab 100644
--- a/http/res/ranking.js
+++ b/http/res/ranking.js
@@ -98,14 +98,14 @@ var ranking = {
ranking.filterRows(params);
ranking.savedParams = params;
}
- $('table.table, .filters .panel-body').css('opacity', 1);
+ $('table.data-table, .filters .panel-body').css('opacity', 1);
ranking.filtersDisabled = false;
var pagesize = 40;
var page = params.get('page') || [0];
var count = $('table.table-paginate').paginate(pagesize, parseInt(page[0]));
- $('table.table tbody tr[data-paginate-visible=1]').eq(0).addClass('gold');
- $('table.table tbody tr[data-paginate-visible=1]').eq(1).addClass('silver');
- $('table.table tbody tr[data-paginate-visible=1]').eq(2).addClass('bronze');
+ $('table.data-table tbody tr[data-paginate-visible=1]').eq(0).addClass('gold');
+ $('table.data-table tbody tr[data-paginate-visible=1]').eq(1).addClass('silver');
+ $('table.data-table tbody tr[data-paginate-visible=1]').eq(2).addClass('bronze');
ranking.buildPaginator('#top-paginator', count, pagesize, page[0] || 1);
ranking.buildPaginator('#bottom-paginator', count, pagesize, page[0] || 1);
},
@@ -113,7 +113,7 @@ var ranking = {
filtersDisabled: false,
filterRows : function(params) {
- $('table.table tbody tr').show().removeClass('gold silver bronze').each(function() {
+ $('table.data-table tbody tr').show().removeClass('gold silver bronze').each(function() {
var row = $(this);
var hidden = false;
params.forEach(function(value, param) {
@@ -149,7 +149,7 @@ var ranking = {
},
changePage: function() {
- $('table.table').css('opacity', 0.1);
+ $('table.data-table').css('opacity', 0.1);
var btn = $(this);
var page = parseInt(btn.attr('data-page'));
var params = ranking.parseHash(location.hash);
@@ -166,7 +166,7 @@ var ranking = {
params.set('page', [page]);
location.hash = ranking.constructHash(params);
} else {
- $('table.table').css('opacity', 1);
+ $('table.data-table').css('opacity', 1);
}
},
@@ -181,7 +181,7 @@ var ranking = {
$('button[data-filter]').click(function(ev) {
if (!ranking.filtersDisabled) {
ranking.filtersDisabled = true;
- $('table.table, .filters .panel-body').css('opacity', 0.1);
+ $('table.data-table, .filters .panel-body').css('opacity', 0.1);
var button = $(this);
var params = ranking.parseHash(location.hash);
var param = params.get(button.attr('data-filter'));
@@ -208,7 +208,7 @@ var ranking = {
$('button[data-clear]').click(function() {
if (!ranking.filtersDisabled) {
ranking.filtersDisabled = true;
- $('table.table, .filters .panel-body').css('opacity', 0.1);
+ $('table.data-table, .filters .panel-body').css('opacity', 0.1);
var button = $(this);
var params = ranking.parseHash(location.hash);
params.delete(button.attr('data-clear'));