aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-04-05 16:32:28 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-04-05 16:56:14 +0200
commit9aa43df9115fe947d8ee35eb03e2e7e8c31e5cb8 (patch)
treee5481b6b2589ab777599fbbd4822b1d4d6b1e396
parentSlightly better parameter checking on save-event. (diff)
downloadcalp-9aa43df9115fe947d8ee35eb03e2e7e8c31e5cb8.tar.gz
calp-9aa43df9115fe947d8ee35eb03e2e7e8c31e5cb8.tar.xz
Made sidebar date headings sticky.
-rw-r--r--module/calp/html/view/calendar.scm2
-rw-r--r--static/_global.scss1
-rw-r--r--static/style.scss16
3 files changed, 14 insertions, 5 deletions
diff --git a/module/calp/html/view/calendar.scm b/module/calp/html/view/calendar.scm
index 5a8e977e..cfbb1865 100644
--- a/module/calp/html/view/calendar.scm
+++ b/module/calp/html/view/calendar.scm
@@ -122,7 +122,7 @@ window.default_calendar='~a';"
,(calendar-styles calendars)
,@(when (debug)
- '((style ".root { background-color: pink; }"))))
+ '((style ":root { --background-color: pink; }"))))
(body
(div (@ (class "root"))
diff --git a/static/_global.scss b/static/_global.scss
index 41f426f9..58e05155 100644
--- a/static/_global.scss
+++ b/static/_global.scss
@@ -13,4 +13,5 @@ $popup-style: "left";
/* Each popup can have a different amoutn of tabs.
Override this as appropriate */
--tabcount: 4;
+ --background-color: white;
}
diff --git a/static/style.scss b/static/style.scss
index efe8291d..c5705e24 100644
--- a/static/style.scss
+++ b/static/style.scss
@@ -11,6 +11,8 @@ html, body {
max-width: 100%;
height: 100%;
+ background-color: var(--background-color);
+
grid-template-columns: auto auto 20em;
grid-template-rows: auto;
@@ -227,10 +229,16 @@ Each event within the eventlist
padding-left: 2px;
margin-top: 1em;
- header h2 {
- width: 100%;
- text-align: center;
- font-size: 14pt;
+ header {
+ position: sticky;
+ top: 0;
+ background-color: var(--background-color);
+
+ h2 {
+ width: 100%;
+ text-align: center;
+ font-size: 14pt;
+ }
}
}