Tweak current slot highlight
This commit is contained in:
parent
91ad6fc563
commit
0a0c466847
2 changed files with 7 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
||||||
$(function() {
|
$(function() {
|
||||||
var SLOT_REFRESH_INTERVAL = 60 * 1000;
|
var SLOT_REFRESH_INTERVAL = 60 * 1000;
|
||||||
|
var haveScrolledToCurrentSlot = false;
|
||||||
|
|
||||||
/* Schedule display localisation */
|
/* Schedule display localisation */
|
||||||
var showCurrentTab = function() {
|
var showCurrentTab = function() {
|
||||||
|
@ -118,6 +119,11 @@ $(function() {
|
||||||
|
|
||||||
if (confStartTime <= now && confEndTime > now) {
|
if (confStartTime <= now && confEndTime > now) {
|
||||||
slot.addClass("slot-active");
|
slot.addClass("slot-active");
|
||||||
|
|
||||||
|
if (!haveScrolledToCurrentSlot) {
|
||||||
|
haveScrolledToCurrentSlot = true;
|
||||||
|
slot[0].scrollIntoView();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
slot.removeClass("slot-active");
|
slot.removeClass("slot-active");
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,7 +85,7 @@ h3, .h3 {
|
||||||
}
|
}
|
||||||
|
|
||||||
.slot-active {
|
.slot-active {
|
||||||
background-color: $blaze;
|
background-color: #EECC96;
|
||||||
}
|
}
|
||||||
|
|
||||||
.conf-clock {
|
.conf-clock {
|
||||||
|
|
Loading…
Reference in a new issue