add: better layout

This commit is contained in:
trisua 2025-07-25 15:12:15 -04:00
parent 2cc9ed7445
commit dbd70d9592
19 changed files with 451 additions and 87 deletions

View file

@ -1,4 +1,3 @@
(text "{%- import \"components.lisp\" as components -%}")
(text "<!doctype html>")
(html
("lang" "en")
@ -19,8 +18,64 @@
(text "{% block head %}{% endblock %}"))
(body
; nav
(nav
("class" "flex w-full justify-between gap-2")
(div
("class" "flex side")
(div
("class" "dropdown")
(button
("onclick" "open_dropdown(event)")
("exclude" "dropdown")
("class" "button camo fade")
(text "{{ icon \"menu\" }}"))
(div
("class" "inner")
(a
("class" "button")
("href" "/")
(text "new"))
(a
("class" "button")
("href" "/{{ what_page_slug }}")
(text "what"))
(a
("class" "button")
("href" "https://trisua.com/t/attobin")
(text "source"))))
(a
("class" "button camo fade")
("href" "/")
("title" "new")
(text "{{ icon \"plus\" }}")))
(div
("class" "side flex")
(text "{% block nav_extras %}{% endblock %}")
; theme switches
(button
("class" "button camo fade")
("id" "switch_light")
("title" "Switch theme")
("onclick" "set_theme('Dark')")
(text "{{ icon \"sun\" }}"))
(button
("class" "button camo fade hidden")
("id" "switch_dark")
("title" "Switch theme")
("onclick" "set_theme('Light')")
(text "{{ icon \"moon\" }}"))))
; page
(article
("class" "content_container flex flex-col")
("id" "page")
(ul ("id" "messages"))
(text "{% block body %}{% endblock %}"))))
(text "{% block body %}{% endblock %}")
(div ("style" "min-height: 32px")))
(script (text "setTimeout(() => init_dropdowns(document.body), 150);"))))