diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-03-09 10:22:58 +0100 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-03-15 01:43:12 +0100 |
commit | 64af09519398da394b57a6fab17f76a4e6d99cdf (patch) | |
tree | 91b50575d7541f7f79c6d33ff9973c2ae5c3f2f0 /module | |
parent | Calp server now 404s on missing file on disk. (diff) | |
download | calp-64af09519398da394b57a6fab17f76a4e6d99cdf.tar.gz calp-64af09519398da394b57a6fab17f76a4e6d99cdf.tar.xz |
Fix anchors in non-js page.
Now blocks link to their entry in the sidebar, and the sidebar entries
link to (one of) their blocks.
Diffstat (limited to '')
-rw-r--r-- | module/calp/html/vcomponent.scm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/module/calp/html/vcomponent.scm b/module/calp/html/vcomponent.scm index 87b22eaf..f593133c 100644 --- a/module/calp/html/vcomponent.scm +++ b/module/calp/html/vcomponent.scm @@ -232,11 +232,11 @@ (stream-map (lambda (ev) (fmt-single-event - ev `((id ,(html-id ev)) + ev `((id ,(html-id ev) "-side") (data-calendar ,(base64encode (or (prop (parent ev) 'NAME) "unknown")))) fmt-header: (lambda body - `(a (@ (href "#" ,(html-id ev) #; (date-link (as-date (prop ev 'DTSTART))) + `(a (@ (href "#" ,(html-id ev) "-block" #; (date-link (as-date (prop ev 'DTSTART))) ) (class "hidelink")) ,@body)))) @@ -269,11 +269,11 @@ ;; surrounding <a /> element which allows something to happen when an element ;; is clicked with JS turned off. Our JS disables this, and handles clicks itself. - `((a (@ (href "#" ,(html-id ev)) + `((a (@ (href "#" ,(html-id ev) "-side") (class "hidelink")) (vevent-block (@ ,@(assq-merge extra-attributes - `((id ,(html-id ev)) + `((id ,(html-id ev) "-block") (data-calendar ,(base64encode (or (prop (parent ev) 'NAME) "unknown"))) (data-uid ,(output-uid ev)) |