Mercurial > libervia-templates
diff sat_templates/templates/bulma/forum/overview.html @ 413:0190a0d32909 default tip
Forum: Major redesign of forums:
Forums have been redesigned. They follow the new general design with 2 or 3 panels,
allowing to have directly a forum if one is found/set up, and a panel on the left to
search/discover other ones.
Categories have been rewritten to be usable with pubsub relationships, a XEP-0277 type
node is used for topics, and each item has a comments node for the threads.
The thread view is set in `forum/show_messages.html` template. It has a header with a
search box and a button to (un)subscribe.
Items are displayed with the same macros as for the blog items.
Below a room is set for editor, tags and attachments.
rel 463
author | Goffi <goffi@goffi.org> |
---|---|
date | Fri, 05 Sep 2025 21:54:09 +0200 |
parents | c1d33d7e4b96 |
children |
line wrap: on
line diff
--- a/sat_templates/templates/bulma/forum/overview.html Sun Aug 31 12:38:49 2025 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,51 +0,0 @@ -{% extends 'base/base.html' %} - -{% macro generate_forums(forums_data, level=0) %} - {% if level == 0 %} - <section class="section"> - {% for forum in forums_data %} - <div class="box content has-text-centered has-background-info mt-4"> - <h4 class="title has-text-white">{{ forum.title }}</h4> - {% if 'short-desc' in forum %} - <p class="subtitle is-size-7 is-italic has-text-white">{{ forum['short-desc'] }}</h5> - {% endif %} - </div> - {% if 'sub-forums' in forum %} - {{ generate_forums(forum['sub-forums'], level=level+1) }} - {% endif %} - {% endfor %} - </section> - {% else %} - <div class="forum forum__panel_{{panel_type}}"> - {% for forum in forums_data %} - <div class="my-2 forum forum__cat_{{panel_type}} forum__level_{{level}}"> - {% if 'http_url' in forum %} - <a href="{{forum['http_url']}}" class="box content x-is-hoverable"> - {% else %} - <a class="box content"> - {% endif %} - <h4 class="title">{{ forum.title }}</h4> - {% if 'short-desc' in forum %} - <p class="subtitle is-size-7 is-italic">{{ forum['short-desc'] }}</p> - {% endif %} - </a> - {% if 'sub-forums' in forum %} - {{ generate_forums(forum['sub-forums'], level=level+1) }} - {% endif %} - </div> - {% endfor %} - </div> -{% endif %} -{% endmacro %} - -{% block body %} -{% if not forums %} - <div class="message"> - <div class="message-body">{% trans %}No forums found on this server!{% endtrans %}</div> - </div> -{% else %} - <div class="container forums"> - {{ generate_forums(forums) }} - </div> -{% endif %} -{% endblock body %}