From 71d1c5fa106d22d3d66bbac8d30009589875e3a7 Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Wed, 25 Nov 2009 15:19:25 +0100 Subject: [PATCH] Highlight today in the minical. --- kronolith/js/kronolith.js | 6 +++++- kronolith/themes/screen.css | 5 ++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/kronolith/js/kronolith.js b/kronolith/js/kronolith.js index 3f8a5be71..e871e7ef6 100644 --- a/kronolith/js/kronolith.js +++ b/kronolith/js/kronolith.js @@ -751,7 +751,7 @@ KronolithCore = { buildMinical: function(tbody, date, view, idPrefix) { var dates = this.viewDates(date, 'month'), day = dates[0].clone(), - date7 = date.clone().add(1).week(), + date7 = date.clone().add(1).week(), today = Date.today(), weekStart, weekEnd, weekEndDay, dateString, td, tr, i; // Remove old calendar rows. Maybe we should only rebuild the minical @@ -788,6 +788,10 @@ KronolithCore = { (view == 'agenda' && !day.isBefore(date) && day.isBefore(date7)))) { td.addClassName('kronolithSelected'); } + // Highlight today. + if (day.equals(today)) { + td.addClassName('kronolithToday'); + } td.innerHTML = day.getDate(); tr.insert(td); day.next().day(); diff --git a/kronolith/themes/screen.css b/kronolith/themes/screen.css index eca0b52a9..549e583d9 100644 --- a/kronolith/themes/screen.css +++ b/kronolith/themes/screen.css @@ -806,8 +806,7 @@ div#kronolithEventTabTags { color: silver; } .kronolithMinical .kronolithSelected { - background-color: #ebf3fc; - border: 1px #808080 solid; + background-color: #ffc; } /* Main views */ @@ -1130,7 +1129,7 @@ table.kronolithView td.kronolithFirstCol { border-color: transparent; color: silver; } -.kronolithViewMonth .kronolithToday { +.kronolithToday, .kronolithMinical .kronolithToday { background-color: #ebf3fc; border-color: #808080; } -- 2.11.0