39 lines
1.2 KiB
Text
39 lines
1.2 KiB
Text
|
(lambda (tag-list history-list)
|
||
|
(let ([class-sec `(ul ((class "tag-list")))])
|
||
|
`(footer
|
||
|
(section
|
||
|
(h5 "tagged")
|
||
|
,(begin
|
||
|
(for-each
|
||
|
(lambda (tag)
|
||
|
(set! class-sec
|
||
|
(append class-sec
|
||
|
;; append unwraps one layer of list, hence (( ... ))
|
||
|
`((li
|
||
|
((class "tag-item"))
|
||
|
(span
|
||
|
((class "hx-target"))
|
||
|
(a ((href ,(string-append "/tagged/" tag))
|
||
|
(hx-get ,(string-append "/hx/tagged/" tag))
|
||
|
(hx-target "closest span.hx-target")
|
||
|
(hx-swap "innerHTML"))
|
||
|
,tag)))))))
|
||
|
tag-list)
|
||
|
class-sec))
|
||
|
(hr)
|
||
|
(p
|
||
|
((class "doc-history"))
|
||
|
(small
|
||
|
,(foldr
|
||
|
(lambda (history acc)
|
||
|
(if (non-empty-string? acc)
|
||
|
(string-append acc "modified: " (~a history) "\n")
|
||
|
(string-append acc "published: " (~a history))))
|
||
|
""
|
||
|
history-list)))
|
||
|
(p
|
||
|
((class "license-info"))
|
||
|
(small
|
||
|
(a
|
||
|
((href "/license"))
|
||
|
"license"))))))
|