add: forums ui
This commit is contained in:
parent
2be87c397d
commit
9ec52abfe4
24 changed files with 770 additions and 64 deletions
42
crates/app/src/public/html/communities/topic.lisp
Normal file
42
crates/app/src/public/html/communities/topic.lisp
Normal file
|
@ -0,0 +1,42 @@
|
|||
(text "{% import \"components.html\" as components %} {% extends \"communities/base.html\" %} {% block content %}")
|
||||
(div
|
||||
("class" "flex flex_col gap_4 w_full")
|
||||
(text "{{ macros::community_nav(community=community, selected=\"posts\") }}")
|
||||
(div
|
||||
("class" "card_nest")
|
||||
(div
|
||||
("class" "card small flex justify_between gap_2")
|
||||
(text "{{ components::topic_display(id=topic_id, topic=topic, community=community, show_description=false) }}")
|
||||
(div
|
||||
("class" "flex gap_2")
|
||||
(a
|
||||
("href" "/communities/intents/post?community={{ community.id }}&topic={{ topic_id }}")
|
||||
("class" "button small lowered")
|
||||
("data-turbo" "false")
|
||||
(icon (text "plus"))
|
||||
(span
|
||||
(str (text "general:action.post"))))
|
||||
(a
|
||||
("href" "/community/{{ community.title }}")
|
||||
("class" "button lowered small")
|
||||
(icon (text "arrow-left"))
|
||||
(str (text "general:action.back")))))
|
||||
(div
|
||||
("class" "card flex flex_col gap_4")
|
||||
(span ("class" "no_p_margin") (text "{{ topic.description|markdown|safe }}"))
|
||||
(hr)
|
||||
(div
|
||||
("class" "w_full")
|
||||
("style" "overflow: auto")
|
||||
(table
|
||||
("class" "w_full")
|
||||
(thead
|
||||
(th (text "Title"))
|
||||
(th (text "Replies"))
|
||||
(th (text "Score"))
|
||||
(th (text "Created")))
|
||||
(tbody
|
||||
(text "{% for post in pinned %} {{ components::topic_post_display(post=post[0], owner=post[1], is_pinned=true) }} {% endfor %}")
|
||||
(text "{% for post in feed %} {{ components::topic_post_display(post=post[0], owner=post[1]) }} {% endfor %}"))))
|
||||
(text "{{ components::pagination(page=page, items=feed|length) }}"))))
|
||||
(text "{% endblock %}")
|
Loading…
Add table
Add a link
Reference in a new issue