Show More
@@ -1,210 +1,209 b'' | |||
|
1 | 1 | {% extends "boards/base.html" %} |
|
2 | 2 | |
|
3 | 3 | {% load i18n %} |
|
4 | 4 | {% load board %} |
|
5 | 5 | {% load static %} |
|
6 | 6 | {% load tz %} |
|
7 | 7 | |
|
8 | 8 | {% block head %} |
|
9 | 9 | <meta name="robots" content="noindex"> |
|
10 | 10 | |
|
11 | 11 | {% if tag %} |
|
12 | 12 | <title>{{ tag.name }} - {{ site_name }}</title> |
|
13 | 13 | {% else %} |
|
14 | 14 | <title>{{ site_name }}</title> |
|
15 | 15 | {% endif %} |
|
16 | 16 | |
|
17 | 17 | {% if prev_page_link %} |
|
18 | 18 | <link rel="prev" href="{{ prev_page_link }}" /> |
|
19 | 19 | {% endif %} |
|
20 | 20 | {% if next_page_link %} |
|
21 | 21 | <link rel="next" href="{{ next_page_link }}" /> |
|
22 | 22 | {% endif %} |
|
23 | 23 | |
|
24 | 24 | {% endblock %} |
|
25 | 25 | |
|
26 | 26 | {% block content %} |
|
27 | 27 | |
|
28 | 28 | {% get_current_language as LANGUAGE_CODE %} |
|
29 | 29 | {% get_current_timezone as TIME_ZONE %} |
|
30 | 30 | |
|
31 | 31 | {% for banner in banners %} |
|
32 | 32 | <div class="post"> |
|
33 | 33 | <div class="title">{{ banner.title }}</div> |
|
34 | 34 | <div>{{ banner.get_text|safe }}</div> |
|
35 | 35 | <div>{% trans 'Details' %}: <a href="{{ banner.post.get_absolute_url }}">>>{{ banner.post.id }}</a></div> |
|
36 | 36 | </div> |
|
37 | 37 | {% endfor %} |
|
38 | 38 | |
|
39 | 39 | {% if tag %} |
|
40 | 40 | <div class="tag_info" style="border-bottom: solid .5ex #{{ tag.get_color }}"> |
|
41 | 41 | {% if random_image_post %} |
|
42 | 42 | <div class="tag-image"> |
|
43 | 43 | {% with image=random_image_post.get_first_image %} |
|
44 | 44 | <a href="{{ random_image_post.get_absolute_url }}"><img |
|
45 | 45 | src="{{ image.get_thumb_url }}" |
|
46 | 46 | width="{{ image.get_preview_size.0 }}" |
|
47 | 47 | height="{{ image.get_preview_size.1 }}" |
|
48 | 48 | alt="{{ random_image_post.id }}"/></a> |
|
49 | 49 | {% endwith %} |
|
50 | 50 | </div> |
|
51 | 51 | {% endif %} |
|
52 | 52 | <div class="tag-text-data"> |
|
53 | 53 | <h2> |
|
54 | 54 | /{{ tag.get_view|safe }}/ |
|
55 | 55 | </h2> |
|
56 | 56 | {% if perms.change_tag %} |
|
57 | 57 | <div class="moderator_info"><a href="{% url 'admin:boards_tag_change' tag.id %}">{% trans 'Edit tag' %}</a></div> |
|
58 | 58 | {% endif %} |
|
59 | 59 | <p> |
|
60 | 60 | <form action="{% url 'tag' tag.name %}" method="post" class="post-button-form"> |
|
61 | 61 | {% if is_favorite %} |
|
62 | 62 | <button name="method" value="unsubscribe" class="fav">β {% trans "Remove from favorites" %}</button> |
|
63 | 63 | {% else %} |
|
64 | 64 | <button name="method" value="subscribe" class="not_fav">β {% trans "Add to favorites" %}</button> |
|
65 | 65 | {% endif %} |
|
66 | 66 | </form> |
|
67 | 67 | <form action="{% url 'tag' tag.name %}" method="post" class="post-button-form"> |
|
68 | 68 | {% if is_hidden %} |
|
69 | 69 | <button name="method" value="unhide" class="fav">{% trans "Show" %}</button> |
|
70 | 70 | {% else %} |
|
71 | 71 | <button name="method" value="hide" class="not_fav">{% trans "Hide" %}</button> |
|
72 | 72 | {% endif %} |
|
73 | 73 | </form> |
|
74 | 74 | <a href="{% url 'tag_gallery' tag.name %}">{% trans 'Gallery' %}</a> |
|
75 | 75 | </p> |
|
76 | 76 | {% if tag.get_description %} |
|
77 | 77 | <p>{{ tag.get_description|safe }}</p> |
|
78 | 78 | {% endif %} |
|
79 | 79 | <p> |
|
80 | 80 | {% with active_count=tag.get_active_thread_count bumplimit_count=tag.get_bumplimit_thread_count archived_count=tag.get_archived_thread_count %} |
|
81 | 81 | {% if active_count %} |
|
82 | 82 | β {{ active_count }}  |
|
83 | 83 | {% endif %} |
|
84 | 84 | {% if bumplimit_count %} |
|
85 | 85 | β {{ bumplimit_count }}  |
|
86 | 86 | {% endif %} |
|
87 | 87 | {% if archived_count %} |
|
88 | 88 | β {{ archived_count }}  |
|
89 | 89 | {% endif %} |
|
90 | 90 | {% endwith %} |
|
91 | 91 | β₯ {{ tag.get_post_count }} |
|
92 | 92 | </p> |
|
93 | 93 | {% if tag.get_all_parents %} |
|
94 | 94 | <p> |
|
95 | 95 | {% for parent in tag.get_all_parents %} |
|
96 | 96 | {{ parent.get_view|safe }} > |
|
97 | 97 | {% endfor %} |
|
98 | 98 | {{ tag.get_view|safe }} |
|
99 | 99 | </p> |
|
100 | 100 | {% endif %} |
|
101 | 101 | {% if tag.get_children.all %} |
|
102 | 102 | <p> |
|
103 | 103 | {% trans "Subsections: " %} |
|
104 | 104 | {% for child in tag.get_children.all %} |
|
105 | 105 | {{ child.get_view|safe }}{% if not forloop.last%}, {% endif %} |
|
106 | 106 | {% endfor %} |
|
107 | 107 | </p> |
|
108 | 108 | {% endif %} |
|
109 | 109 | </div> |
|
110 | 110 | </div> |
|
111 | 111 | {% endif %} |
|
112 | 112 | |
|
113 | 113 | {% if threads %} |
|
114 | 114 | {% if prev_page_link %} |
|
115 | 115 | <div class="page_link"> |
|
116 | 116 | <a href="{{ prev_page_link }}"><< {% trans "Previous page" %} <<</a> |
|
117 | 117 | </div> |
|
118 | 118 | {% endif %} |
|
119 | 119 | |
|
120 | 120 | {% for thread in threads %} |
|
121 | 121 | <div class="thread"> |
|
122 | 122 | {% post_view thread.get_opening_post thread=thread truncated=True need_open_link=True %} |
|
123 | 123 | {% if not thread.archived %} |
|
124 | 124 | {% with last_replies=thread.get_last_replies %} |
|
125 | 125 | {% if last_replies %} |
|
126 | 126 | {% with skipped_replies_count=thread.get_skipped_replies_count %} |
|
127 | 127 | {% if skipped_replies_count %} |
|
128 | 128 | <div class="skipped_replies"> |
|
129 | 129 | <a href="{% url 'thread' thread.get_opening_post_id %}"> |
|
130 | 130 | {% blocktrans count count=skipped_replies_count %}Skipped {{ count }} reply. Open thread to see all replies.{% plural %}Skipped {{ count }} replies. Open thread to see all replies.{% endblocktrans %} |
|
131 | 131 | </a> |
|
132 | 132 | </div> |
|
133 | 133 | {% endif %} |
|
134 | 134 | {% endwith %} |
|
135 | 135 | <div class="last-replies"> |
|
136 | 136 | {% for post in last_replies %} |
|
137 | 137 | {% post_view post truncated=True %} |
|
138 | 138 | {% endfor %} |
|
139 | 139 | </div> |
|
140 | 140 | {% endif %} |
|
141 | 141 | {% endwith %} |
|
142 | 142 | {% endif %} |
|
143 | 143 | </div> |
|
144 | 144 | {% endfor %} |
|
145 | 145 | |
|
146 | 146 | {% if next_page_link %} |
|
147 | 147 | <div class="page_link"> |
|
148 | 148 | <a href="{{ next_page_link }}">>> {% trans "Next page" %} >></a> |
|
149 | 149 | </div> |
|
150 | 150 | {% endif %} |
|
151 | 151 | {% else %} |
|
152 | 152 | <div class="post"> |
|
153 | 153 | {% trans 'No threads exist. Create the first one!' %}</div> |
|
154 | 154 | {% endif %} |
|
155 | 155 | |
|
156 | 156 | <div class="post-form-w"> |
|
157 | 157 | <script src="{% static 'js/panel.js' %}"></script> |
|
158 | 158 | <div class="post-form" data-hasher="{% static 'js/3party/sha256.js' %}" |
|
159 | 159 | data-pow-script="{% static 'js/proof_of_work.js' %}"> |
|
160 | 160 | <div class="form-title">{% trans "Create new thread" %}</div> |
|
161 | 161 | <div class="swappable-form-full"> |
|
162 | 162 | <form enctype="multipart/form-data" method="post" id="form">{% csrf_token %} |
|
163 | 163 | {{ form.as_div }} |
|
164 | 164 | <div class="form-submit"> |
|
165 | 165 | <input type="submit" value="{% trans "Post" %}"/> |
|
166 | 166 | <button id="preview-button" type="button" onclick="return false;">{% trans 'Preview' %}</button> |
|
167 | 167 | <button id="file-source-button" type="button" onclick="return false;">{% trans 'Change file source' %}</button> |
|
168 | 168 | </div> |
|
169 | 169 | </form> |
|
170 | 170 | </div> |
|
171 | 171 | <div> |
|
172 | 172 | {% trans 'Tags must be delimited by spaces. Text or image is required.' %} |
|
173 | 173 | {% with size=max_file_size|filesizeformat %} |
|
174 | 174 | {% blocktrans %}Max file size is {{ size }}.{% endblocktrans %} |
|
175 | 175 | {% endwith %} |
|
176 | 176 | </div> |
|
177 | 177 | <div id="preview-text"></div> |
|
178 | 178 | <div><a href="{% url "staticpage" name="help" %}">{% trans 'Text syntax' %}</a></div> |
|
179 | 179 | <div><a href="{% url "tags" "required" %}">{% trans 'Tags' %}</a></div> |
|
180 | 180 | </div> |
|
181 | 181 | </div> |
|
182 | 182 | |
|
183 | 183 | <script src="{% static 'js/form.js' %}"></script> |
|
184 | 184 | <script src="{% static 'js/3party/jquery.blockUI.js' %}"></script> |
|
185 | 185 | <script src="{% static 'js/thread_create.js' %}"></script> |
|
186 | 186 | |
|
187 | 187 | {% endblock %} |
|
188 | 188 | |
|
189 | 189 | {% block metapanel %} |
|
190 | 190 | |
|
191 | 191 | <span class="metapanel"> |
|
192 | <b><a href="{% url "authors" %}">{{ site_name }}</a> {{ version }}</b> | |
|
193 | 192 | {% trans "Pages:" %} |
|
194 | 193 | [ |
|
195 | 194 | {% with dividers=paginator.get_dividers %} |
|
196 | 195 | {% for page in paginator.get_divided_range %} |
|
197 | 196 | {% if page in dividers %} |
|
198 | 197 | β¦, |
|
199 | 198 | {% endif %} |
|
200 | 199 | <a |
|
201 | 200 | {% ifequal page current_page.number %} |
|
202 | 201 | class="current_page" |
|
203 | 202 | {% endifequal %} |
|
204 | 203 | href="{% page_url paginator page %}">{{ page }}</a>{% if not forloop.last %},{% endif %} |
|
205 | 204 | {% endfor %} |
|
206 | 205 | {% endwith %} |
|
207 | 206 | ] |
|
208 | 207 | </span> |
|
209 | 208 | |
|
210 | 209 | {% endblock %} |
@@ -1,93 +1,94 b'' | |||
|
1 | 1 | {% load staticfiles %} |
|
2 | 2 | {% load i18n %} |
|
3 | 3 | {% load l10n %} |
|
4 | 4 | {% load static from staticfiles %} |
|
5 | 5 | |
|
6 | 6 | <!DOCTYPE html> |
|
7 | 7 | <html> |
|
8 | 8 | <head> |
|
9 | 9 | <link rel="stylesheet" type="text/css" href="{% static 'css/base.css' %}" media="all"/> |
|
10 | 10 | <link rel="stylesheet" type="text/css" href="{% static 'css/3party/highlight.css' %}" media="all"/> |
|
11 | 11 | <link rel="stylesheet" type="text/css" href="{% static 'css/3party/jquery-ui.min.css' %}" media="all"/> |
|
12 | 12 | <link rel="stylesheet" type="text/css" href="{% static theme_css %}" media="all"/> |
|
13 | 13 | |
|
14 | 14 | {% if rss_url %} |
|
15 | 15 | <link rel="alternate" type="application/rss+xml" href="{{ rss_url }}" title="{% trans 'Feed' %}"/> |
|
16 | 16 | {% endif %} |
|
17 | 17 | |
|
18 | 18 | <link rel="icon" type="image/png" |
|
19 | 19 | href="{% static 'favicon.png' %}"> |
|
20 | 20 | |
|
21 | 21 | <meta name="viewport" content="width=device-width, initial-scale=1"/> |
|
22 | 22 | <meta charset="utf-8"/> |
|
23 | 23 | |
|
24 | 24 | {% block head %}{% endblock %} |
|
25 | 25 | </head> |
|
26 | 26 | <body data-image-viewer="{{ image_viewer }}" |
|
27 | 27 | data-pow-difficulty="{{ pow_difficulty }}" |
|
28 | 28 | data-update-script="{% static 'js/updates.js' %}"> |
|
29 | 29 | <script src="{% static 'js/jquery-2.2.0.min.js' %}"></script> |
|
30 | 30 | |
|
31 | 31 | <header class="navigation_panel"> |
|
32 | 32 | <a class="link" href="{% url 'landing' %}">{{ site_name }}</a> |
|
33 | 33 | <a href="{% url 'index' %}" title="{% trans "All threads" %}">~~~</a>, |
|
34 | 34 | {% if tags_str %} |
|
35 | 35 | <form action="{% url 'index' %}" method="post" class="post-button-form">{% csrf_token %} |
|
36 | 36 | {% if only_favorites %} |
|
37 | 37 | <button name="method" value="toggle_fav" class="fav">β </button>, |
|
38 | 38 | {% else %} |
|
39 | 39 | <button name="method" value="toggle_fav" class="not_fav">β </button>, |
|
40 | 40 | {% endif %} |
|
41 | 41 | </form> |
|
42 | 42 | {{ tags_str|safe }}, |
|
43 | 43 | {% endif %} |
|
44 | 44 | <a href="{% url 'tags' 'required'%}" title="{% trans 'Tag management' %}">{% trans "tags" %}</a>, |
|
45 | 45 | <a href="{% url 'search' %}" title="{% trans 'Search' %}">{% trans 'search' %}</a>, |
|
46 | 46 | <a href="{% url 'feed' %}" title="{% trans 'Feed' %}">{% trans 'feed' %}</a>, |
|
47 | 47 | <a href="{% url 'random' %}" title="{% trans 'Random images' %}">{% trans 'images' %}</a>{% if has_fav_threads %}, |
|
48 | 48 | |
|
49 | 49 | <a href="{% url 'feed' %}?favorites" id="fav-panel-btn">{% trans 'favorites' %} <span id="new-fav-post-count" {% if not new_post_count %}style="display: none" {% endif %}>{{ new_post_count }}</span></a> |
|
50 | 50 | {% endif %} |
|
51 | 51 | |
|
52 | 52 | {% if usernames %} |
|
53 | 53 | <a class="right-link link" href="{% url 'notifications' %}" title="{% trans 'Notifications' %}"> |
|
54 | 54 | {% trans 'Notifications' %} |
|
55 | 55 | {% ifnotequal new_notifications_count 0 %} |
|
56 | 56 | (<b>{{ new_notifications_count }}</b>) |
|
57 | 57 | {% endifnotequal %} |
|
58 | 58 | </a> |
|
59 | 59 | {% endif %} |
|
60 | 60 | |
|
61 | 61 | <a class="right-link link" href="{% url 'settings' %}">{% trans 'Settings' %}</a> |
|
62 | 62 | </header> |
|
63 | 63 | |
|
64 | 64 | <div id="fav-panel"><div class="post">{% trans "Loading..." %}</div></div> |
|
65 | 65 | |
|
66 | 66 | {% block content %}{% endblock %} |
|
67 | 67 | |
|
68 | 68 | <script src="{% static 'js/3party/jquery-ui.min.js' %}"></script> |
|
69 | 69 | <script src="{% static 'js/jquery.mousewheel.js' %}"></script> |
|
70 | 70 | <script src="{% static 'js/3party/highlight.min.js' %}"></script> |
|
71 | 71 | |
|
72 | 72 | <script src="{% url 'js_info_dict' %}"></script> |
|
73 | 73 | |
|
74 | 74 | <script src="{% static 'js/popup.js' %}"></script> |
|
75 | 75 | <script src="{% static 'js/image.js' %}"></script> |
|
76 | 76 | <script src="{% static 'js/refpopup.js' %}"></script> |
|
77 | 77 | <script src="{% static 'js/main.js' %}"></script> |
|
78 | 78 | |
|
79 | 79 | <footer class="navigation_panel"> |
|
80 | <b><a href="{% url "authors" %}">{{ site_name }}</a> {{ version }}</b> | |
|
80 | 81 | {% block metapanel %}{% endblock %} |
|
81 | 82 | {% if rss_url %} |
|
82 | 83 | [<a href="{{ rss_url }}">RSS</a>] |
|
83 | 84 | {% endif %} |
|
84 | 85 | [<a href="{% url 'admin:index' %}">{% trans 'Admin' %}</a>] |
|
85 | 86 | [<a href="{% url 'index' %}?order=pub">{% trans 'New threads' %}</a>] |
|
86 | 87 | {% with ppd=posts_per_day|floatformat:2 %} |
|
87 | 88 | {% blocktrans %}Speed: {{ ppd }} posts per day{% endblocktrans %} |
|
88 | 89 | {% endwith %} |
|
89 | 90 | <a class="link" href="#top" id="up">{% trans 'Up' %}</a> |
|
90 | 91 | </footer> |
|
91 | 92 | |
|
92 | 93 | </body> |
|
93 | 94 | </html> |
General Comments 0
You need to be logged in to leave comments.
Login now