add: socket

This commit is contained in:
trisua 2025-08-24 17:58:39 -04:00
parent 8c86dd6cda
commit c48cf78314
10 changed files with 227 additions and 13 deletions

View file

@ -0,0 +1,9 @@
(text "{% macro avatar(id, size=\"24px\") -%}")
(img
("title" "User avatar")
("src" "{{ config.service_hosts.buckets }}/avatars/{{ id }}")
("alt" "User avatar")
("class" "avatar shadow")
("loading" "lazy")
("style" "--size: {{ size }}"))
(text "{%- endmacro %}")

View file

@ -3,7 +3,7 @@
(text "Login — {{ name }}"))
(text "{% endblock %} {% block body %}")
(div
("class" "card")
("class" "card container small")
(h4 (text "Login with Tetratto"))
(form
@ -24,7 +24,7 @@
("id" "username")))
(div
("class" "flex flex_col gap_1")
(label ("for" "username") (b (text "Password")))
(label ("for" "password") (b (text "Password")))
(input
("class" "surface")
("type" "password")

View file

@ -1,3 +1,4 @@
(text "{%- import \"components.lisp\" as components -%}")
(text "<!doctype html>")
(html
("lang" "en")
@ -35,8 +36,12 @@
(button
("onclick" "open_dropdown(event)")
("exclude" "dropdown")
("class" "button camo fade")
(text "{{ icon \"menu\" }}"))
("class" "button camo")
(text "{% if user -%}")
(text "{{ components::avatar(id=user.id) }}")
(text "{%- else -%}")
(text "{{ icon \"menu\" }}")
(text "{%- endif %}"))
(div
("class" "inner left")
(a