By using this site, you agree to have cookies stored on your device, strictly for functional purposes, such as storing your session and preferences.

Dismiss

 repo-forum.html

View raw Download
text/html • 2.19 kiB
HTML document, ASCII text
        
            
1
{% extends "repo.html" %}
2
{% set active_page = "forum" %}
3
4
{% block title %}
5
{% trans username=username, repository=repository %}Forum of {{ username }}/{{ repository }}{% endtrans %}
6
{% endblock %}
7
{% block content %}
8
<x-vbox>
9
<x-frame style="--width: 896px;" class="flexible-space">
10
<x-vbox>
11
<details class="reply-area">
12
<summary>{% trans %}Post topic{% endtrans %}</summary>
13
14
<form method="POST" action="new">
15
<x-vbox>
16
<x-vbox class="nopad">
17
<label for="subject">{% trans %}Subject{% endtrans %}</label>
18
<input id="subject" name="subject" required>
19
</x-vbox>
20
<textarea name="message" style="box-sizing: border-box;" rows="8" required></textarea>
21
<x-buttonbox>
22
<button type="submit">{% trans %}Submit{% endtrans %}</button>
23
</x-buttonbox>
24
</x-vbox>
25
</form>
26
</details>
27
{% for post in Post.query.filter_by(repo=repo_data, parent=none).order_by(Post.last_updated.desc()) %}
28
<article class="card card-horizontal">
29
{% if post.state == 0 %}
30
<div class="card-top state-label" style="background: var(--color-done); color: var(--color-done-text);">
31
{% trans %}done{% endtrans %}
32
</div>
33
{% elif post.state == 1 %}
34
<div class="card-top state-label" style="background: var(--color-pending); color: var(--color-pending-text);">
35
{% trans %}active{% endtrans %}
36
</div>
37
{% endif %}
38
<section class="card-main">
39
<h3><a href="{{ post.number }}">{{ post.subject }}</a> ({{ post.children | length }})</h3>
40
<p><a href="/{{ post.owner.username }}">{{ post.owner.username }}</a></p>
41
</section>
42
</article>
43
{% endfor %}
44
</x-vbox>
45
</x-frame>
46
</x-vbox>
47
{% endblock %}
48