{% macro forum_category_listing(forums, title) %} {% from _self import forum_category_entry %}
{{ title }}
{% if forums|length > 0 %}
{% for forum in forums %} {{ forum_category_entry(forum) }} {% endfor %}
{% else %}
This category is empty.
{% endif %}
{% endmacro %} {% macro forum_category_buttons(forum, perms) %}
{% if perms|perms_check(constant('MSZ_FORUM_PERM_CREATE_TOPIC')) %} New Topic {% endif %}
{% endmacro %} {% macro forum_category_entry(forum, forum_unread, forum_type, forum_icon) %} {% set forum_type = forum_type|default(null) %} {% set forum_unread = forum_unread|default(forum.forum_unread|default(false)) ? 'unread' : 'read' %} {% set forum_icon = forum_icon|default('https://static.flash.moe/images/forum-icons/forum-%s-%s.png') %} {% if forum_type is null %} {% if forum.forum_archived is defined and forum.forum_archived %} {% set forum_type = 'archive' %} {% elseif forum.forum_type is defined and forum.forum_type != 0 %} {% if forum.forum_type == 2 %} {% set forum_type = 'link' %} {% elseif forum.forum_type == 1 %} {% set forum_type = 'category' %} {% endif %} {% else %} {% set forum_type = 'default' %} {% endif %} {% endif %}
{{ forum_unread }}
{{ forum.forum_name }}
{{ forum.forum_description|nl2br }}
{% if forum.forum_subforums is defined and forum.forum_subforums|length > 0 %}
{% for subforum in forum.forum_subforums %} {{ subforum.forum_name }} {% endfor %}
{% endif %}
{% if forum.forum_type == 2 %} {% if forum.forum_link_clicks is not null %}
{{ forum.forum_link_clicks|number_format }}
{% endif %} {% elseif forum.forum_type != 1 %}
{{ forum.forum_topic_count|number_format }}
{{ forum.forum_post_count|number_format }}
{% endif %} {% if forum.forum_type == 0 or forum.forum_link_clicks is not null %}
{% if forum.forum_type != 2 %} {% if forum.recent_topic_id is null %}
There are no posts in this forum yet.
{% else %}
{{ forum.recent_topic_title }}
{% if forum.recent_post_user_id is not null %} by {{ forum.recent_post_username }}, {% endif %}
{% if forum.recent_post_user_id is not null %} {% endif %} {% endif %} {% endif %}
{% endif %}
{% endmacro %} {% macro forum_topic_buttons(topic) %}
Reply
{% endmacro %} {% macro forum_topic_locked(locked, archived) %} {% if locked is not null or archived %}
{% if archived %} This topic has been archived. {% else %} This topic was locked . {% endif %}
{% endif %} {% endmacro %} {% macro forum_topic_listing(topics) %} {% from _self import forum_topic_entry %}
Topics
{% if topics|length > 0 %} {% for topic in topics %} {{ forum_topic_entry(topic) }} {% endfor %} {% else %}
There are no topics in this forum.
{% endif %}
{% endmacro %} {% macro forum_topic_entry(topic, topic_type, topic_unread, topic_icon) %} {% set topic_type = topic_type|default(null) %} {% set topic_unread = topic_unread|default(topic.topic_unread|default(false)) ? 'unread' : 'read' %} {% set topic_icon = topic_icon|default('https://static.flash.moe/images/topic-icons/topic-%s-%s.png') %} {% if topic_type is null %} {% if topic.topic_deleted is defined and topic.topic_deleted is not null %} {% set topic_type = 'deleted' %} {% elseif topic.topic_type is defined and topic.topic_type != 0 %} {% if topic.topic_type == 2 %} {% set topic_type = 'announcement' %} {% elseif topic.topic_type == 1 %} {% set topic_type = 'pinned' %} {% endif %} {% elseif topic.topic_locked is defined and topic.topic_locked is not null %} {% set topic_type = 'locked' %} {% else %} {% set topic_type = 'default' %} {% endif %} {% endif %}
{{ topic_unread }}
{{ topic.topic_post_count|number_format }}
{{ topic.topic_view_count|number_format }}
{% if topic.respondent_id is not null %}
by {{ topic.respondent_name }}
{% endif %}
{% if topic.respondent_id is not null %} {% endif %}
{% endmacro %} {% macro forum_post_listing(posts, opening_post_id) %} {% from _self import forum_post_entry %} {% for post in posts %} {{ forum_post_entry(post, post.post_id == opening_post_id) }} {% endfor %} {% endmacro %} {% macro forum_post_entry(post, is_original_post, is_original_poster) %} {% set is_original_post = is_original_post|default(false) %} {% set is_original_poster = is_original_poster|default(false) %}
{% if post.poster_id is not null %}
{% else %}
{% endif %}
{{ post.post_text|escape|parse_text(post.post_parse)|raw }}
{% endmacro %} {% macro forum_posting_form(title, target_id, is_reply, element_id) %} {% set is_reply = is_reply ? true : false %}
{{ title }}
{#

Error: Your post contained too much text, shorten it a bit or split it out in two posts.

#} {% if not is_reply %}
{% endif %}
{% endmacro %}