2025-07-20 02:49:01 -04:00
|
|
|
(text "{% extends \"root.lisp\" %} {% block head %}")
|
2025-07-21 02:11:23 -04:00
|
|
|
(text "{% if not metadata.page_title -%}")
|
2025-07-20 02:49:01 -04:00
|
|
|
(title
|
|
|
|
(text "{{ entry.slug }}"))
|
2025-07-21 02:11:23 -04:00
|
|
|
(text "{%- endif %} {{ metadata_head|safe }}")
|
2025-07-21 22:28:43 -04:00
|
|
|
|
2025-07-25 15:12:15 -04:00
|
|
|
(text "{% if not metadata.share_title -%}")
|
|
|
|
(meta ("property" "og:title") ("content" "{{ entry.slug }}"))
|
|
|
|
(meta ("property" "twitter:title") ("content" "{{ entry.slug }}"))
|
|
|
|
(text "{%- endif %}")
|
|
|
|
|
2025-07-21 22:28:43 -04:00
|
|
|
(text "{% if metadata.page_icon|length == 0 -%}")
|
2025-07-21 02:11:23 -04:00
|
|
|
(link ("rel" "icon") ("href" "/public/favicon.svg"))
|
2025-07-21 22:28:43 -04:00
|
|
|
(text "{%- endif %}")
|
|
|
|
|
2025-07-20 02:49:01 -04:00
|
|
|
(text "{% endblock %} {% block body %}")
|
|
|
|
(div
|
|
|
|
("class" "flex flex-col gap-2")
|
|
|
|
(div
|
2025-07-21 02:11:23 -04:00
|
|
|
("class" "card container")
|
2025-07-20 02:49:01 -04:00
|
|
|
("style" "min-height: 15rem")
|
|
|
|
(text "{{ entry.content|markdown|safe }}"))
|
|
|
|
(div
|
|
|
|
("class" "w-full flex justify-between gap-2")
|
|
|
|
(a
|
|
|
|
("class" "button")
|
|
|
|
("href" "/{{ entry.slug }}/edit")
|
|
|
|
(text "Edit"))
|
|
|
|
|
|
|
|
(div
|
|
|
|
("class" "flex flex-col gap-1 items-end fade")
|
2025-07-21 02:11:23 -04:00
|
|
|
; dates
|
2025-07-20 02:49:01 -04:00
|
|
|
(span (text "Pub: {{ entry.created / 1000|int|date(format=\"%Y-%m-%d %H:%M\", timezone=\"Etc/UTC\") }} UTC"))
|
|
|
|
(span (text "Edit: {{ entry.edited / 1000|int|date(format=\"%Y-%m-%d %H:%M\", timezone=\"Etc/UTC\") }} UTC"))
|
2025-07-21 02:11:23 -04:00
|
|
|
|
|
|
|
; auto theme
|
|
|
|
(text "{% if metadata.access_recommended_theme != 'None' -%}")
|
2025-07-25 15:12:15 -04:00
|
|
|
(span ("id" "auto_theme") (text "Auto theme: {{ metadata.access_recommended_theme }}"))
|
2025-07-21 02:11:23 -04:00
|
|
|
(script ("defer" "true") (text "setTimeout(() => { temporary_set_theme('{{ metadata.access_recommended_theme }}') }, 150);"))
|
|
|
|
(text "{%- endif %}")
|
|
|
|
|
|
|
|
; views
|
|
|
|
(text "{% if not metadata.option_disable_views -%}")
|
|
|
|
(span (text "Views: {{ views }}"))
|
|
|
|
(text "{%- endif %}")
|
|
|
|
|
|
|
|
; easy-to-read
|
|
|
|
(text "{% if metadata.access_easy_read|length > 0 -%}")
|
|
|
|
(a ("class" "button small") ("href" "/{{ metadata.access_easy_read }}") (b (text "E2R")))
|
|
|
|
(text "{%- endif %}"))))
|
|
|
|
|
2025-07-25 15:12:15 -04:00
|
|
|
(div ("style" "display: none") ("id" "metadata_css") (text "{{ metadata_css|safe }}"))
|
2025-07-20 02:49:01 -04:00
|
|
|
|
|
|
|
(link ("rel" "stylesheet") ("href" "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/styles/default.min.css"))
|
|
|
|
(script ("src" "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/highlight.min.js"))
|
|
|
|
(script (text "hljs.highlightAll();"))
|
|
|
|
|
2025-07-25 15:12:15 -04:00
|
|
|
(text "{% endblock %}")
|
|
|
|
(text "{% block nav_extras %}")
|
|
|
|
(button
|
|
|
|
("class" "button camo fade no_fill")
|
|
|
|
("title" "Toggle high-contrast")
|
|
|
|
("onclick" "toggle_metadata_css(event)")
|
|
|
|
(text "{{ icon \"contrast\" }}"))
|
2025-07-20 02:49:01 -04:00
|
|
|
(text "{% endblock %}")
|