]> git.immae.eu Git - github/wallabag/wallabag.git/blob - src/Wallabag/CoreBundle/Resources/views/themes/baggy/Config/index.html.twig
views: Add doc and translations on ignore origin rules forms
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Resources / views / themes / baggy / Config / index.html.twig
1 {% extends "WallabagCoreBundle::layout.html.twig" %}
2
3 {% block title %}{{ 'config.page_title'|trans }}{% endblock %}
4
5 {% block content %}
6 <h2>{{ 'config.tab_menu.settings'|trans }}</h2>
7
8 {{ form_start(form.config) }}
9 {{ form_errors(form.config) }}
10
11 <fieldset class="w500p inline">
12 <div class="row">
13 {{ form_label(form.config.theme) }}
14 {{ form_errors(form.config.theme) }}
15 {{ form_widget(form.config.theme) }}
16 </div>
17 <a href="#" title="{{ 'config.form_settings.help_theme'|trans }}">
18 <i class="material-icons">live_help</i>
19 </a>
20 </fieldset>
21
22 <fieldset class="w500p inline">
23 <div class="row">
24 {{ form_label(form.config.items_per_page) }}
25 {{ form_errors(form.config.items_per_page) }}
26 {{ form_widget(form.config.items_per_page) }}
27 </div>
28 <a href="#" title="{{ 'config.form_settings.help_items_per_page'|trans }}">
29 <i class="material-icons">live_help</i>
30 </a>
31 </fieldset>
32
33 <fieldset class="w500p inline">
34 <div class="row">
35 {{ form_label(form.config.reading_speed) }}
36 {{ form_errors(form.config.reading_speed) }}
37 {{ form_widget(form.config.reading_speed) }}
38 <p>
39 {{ 'config.form_settings.reading_speed.help_message'|trans }}
40 <a href="http://www.myreadspeed.com/calculate/">myreadspeed</a>
41 </p>
42 </div>
43 <a href="#" title="{{ 'config.form_settings.help_reading_speed'|trans }}">
44 <i class="material-icons">live_help</i>
45 </a>
46 </fieldset>
47
48 <fieldset class="w500p inline">
49 <div class="row">
50 {{ form_label(form.config.action_mark_as_read) }}
51 {{ form_errors(form.config.action_mark_as_read) }}
52 {{ form_widget(form.config.action_mark_as_read) }}
53 </div>
54 </fieldset>
55
56 <fieldset class="w500p inline">
57 <div class="row">
58 {{ form_label(form.config.language) }}
59 {{ form_errors(form.config.language) }}
60 {{ form_widget(form.config.language) }}
61 </div>
62 <a href="#" title="{{ 'config.form_settings.help_language'|trans }}">
63 <i class="material-icons">live_help</i>
64 </a>
65 </fieldset>
66
67 <fieldset class="w500p inline">
68 <div class="row">
69 {{ form_label(form.config.pocket_consumer_key) }}
70 {{ form_errors(form.config.pocket_consumer_key) }}
71 {{ form_widget(form.config.pocket_consumer_key) }}
72 <p>
73 &raquo;
74 <a href="https://getpocket.com/developer/docs/authentication">https://getpocket.com/developer/docs/authentication</a>
75 </p>
76 </div>
77 <a href="#" title="{{ 'config.form_settings.help_pocket_consumer_key'|trans }}">
78 <i class="material-icons">live_help</i>
79 </a>
80 </fieldset>
81
82 <fieldset class="w500p inline">
83 <div class="row">
84 <h3>{{ 'config.form_settings.android_configuration'|trans }}</h3>
85 <a href="wallabag://{{ app.user.username }}@{{ wallabag_url }}">{{ 'config.form_settings.android_instruction' | trans }}</a>
86 <br/>
87 <img id="androidQrcode" />
88 <script>
89 document.getElementById('androidQrcode').src = jrQrcode.getQrBase64('wallabag://{{ app.user.username }}@{{ wallabag_url }}');
90 </script>
91 </div>
92 </fieldset>
93
94 {{ form_rest(form.config) }}
95 </form>
96
97 <h2>{{ 'config.tab_menu.feed'|trans }}</h2>
98
99 {{ form_start(form.feed) }}
100 {{ form_errors(form.feed) }}
101
102 <div class="row">
103 {{ 'config.form_feed.description'|trans }}
104 </div>
105
106 <fieldset class="w500p inline">
107 <div class="row">
108 <label>{{ 'config.form_feed.token_label'|trans }}</label>
109 {% if feed.token %}
110 {{ feed.token }}
111 {% else %}
112 <em>{{ 'config.form_feed.no_token'|trans }}</em>
113 {% endif %}
114
115 {% if feed.token %}
116 – <a href="{{ path('generate_token') }}">{{ 'config.form_feed.token_reset'|trans }}</a>
117 – <a href="{{ path('revoke_token') }}">{{ 'config.form_feed.token_revoke'|trans }}</a>
118 {% else %}
119 – <a href="{{ path('generate_token') }}">{{ 'config.form_feed.token_create'|trans }}</a>
120 {% endif %}
121 </div>
122 </fieldset>
123
124 {% if feed.token %}
125 <fieldset class="w500p inline">
126 <div class="row">
127 <label>{{ 'config.form_feed.feed_links'|trans }}</label>
128 <ul>
129 <li><a href="{{ path('unread_feed', {'username': feed.username, 'token': feed.token}) }}">{{ 'config.form_feed.feed_link.unread'|trans }}</a></li>
130 <li><a href="{{ path('starred_feed', {'username': feed.username, 'token': feed.token}) }}">{{ 'config.form_feed.feed_link.starred'|trans }}</a></li>
131 <li><a href="{{ path('archive_feed', {'username': feed.username, 'token': feed.token}) }}">{{ 'config.form_feed.feed_link.archive'|trans }}</a></li>
132 <li><a href="{{ path('all_feed', {'username': feed.username, 'token': feed.token}) }}">{{ 'config.form_feed.feed_link.all'|trans }}</a></li>
133 </ul>
134 </div>
135 </fieldset>
136 {% endif %}
137
138 <fieldset class="w500p inline">
139 <div class="row">
140 {{ form_label(form.feed.feed_limit) }}
141 {{ form_errors(form.feed.feed_limit) }}
142 {{ form_widget(form.feed.feed_limit) }}
143 </div>
144 </fieldset>
145
146 {{ form_rest(form.feed) }}
147 </form>
148
149 <h2>{{ 'config.tab_menu.user_info'|trans }}</h2>
150
151 {{ form_start(form.user) }}
152 {{ form_errors(form.user) }}
153 <fieldset class="w500p inline">
154 <div class="row">
155 <label>{{ 'config.form_user.login_label'|trans }}</label>
156 {{ app.user.username }}
157 </div>
158 </fieldset>
159
160 <fieldset class="w500p inline">
161 <div class="row">
162 {{ form_label(form.user.name) }}
163 {{ form_errors(form.user.name) }}
164 {{ form_widget(form.user.name) }}
165 </div>
166 </fieldset>
167
168 <fieldset class="w500p inline">
169 <div class="row">
170 {{ form_label(form.user.email) }}
171 {{ form_errors(form.user.email) }}
172 {{ form_widget(form.user.email) }}
173 </div>
174 </fieldset>
175
176 {{ form_widget(form.user.save) }}
177
178 {% if twofactor_auth %}
179 <h5>{{ 'config.otp.page_title'|trans }}</h5>
180
181 <div class="row">
182 {{ 'config.form_user.two_factor_description'|trans }}
183 </div>
184
185 <table>
186 <thead>
187 <tr>
188 <th>{{ 'config.form_user.two_factor.table_method'|trans }}</th>
189 <th>{{ 'config.form_user.two_factor.table_state'|trans }}</th>
190 <th>{{ 'config.form_user.two_factor.table_action'|trans }}</th>
191 </tr>
192 </thead>
193
194 <tbody>
195 <tr>
196 <td>{{ 'config.form_user.two_factor.emailTwoFactor_label'|trans }}</td>
197 <td>{% if app.user.isEmailTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
198 <td><a href="{{ path('config_otp_email') }}" class="waves-effect waves-light btn{% if app.user.isEmailTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_email'|trans }}</a> {% if app.user.isEmailTwoFactor %}<a href="{{ path('disable_otp_email') }}" class="waves-effect waves-light btn">Disable</a>{% endif %}</td>
199 </tr>
200 <tr>
201 <td>{{ 'config.form_user.two_factor.googleTwoFactor_label'|trans }}</td>
202 <td>{% if app.user.isGoogleTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
203 <td><a href="{{ path('config_otp_app') }}" class="waves-effect waves-light btn{% if app.user.isGoogleTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_app'|trans }}</a> {% if app.user.isGoogleTwoFactor %}<a href="{{ path('disable_otp_app') }}" class="waves-effect waves-light btn">Disable</a>{% endif %}</td>
204 </tr>
205 </tbody>
206 </table>
207
208 {% endif %}
209
210 {{ form_widget(form.user._token) }}
211 </form>
212
213 {% if enabled_users > 1 %}
214 <h2>{{ 'config.form_user.delete.title'|trans }}</h2>
215
216 <p>{{ 'config.form_user.delete.description'|trans }}</p>
217 <a href="{{ path('delete_account') }}" onclick="return confirm('{{ 'config.form_user.delete.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red delete-account">
218 {{ 'config.form_user.delete.button'|trans }}
219 </a>
220 {% endif %}
221
222 <h2>{{ 'config.tab_menu.password'|trans }}</h2>
223
224 {{ form_start(form.pwd) }}
225 {{ form_errors(form.pwd) }}
226
227 <div class="row">
228 {{ 'config.form_password.description'|trans }}
229 </div>
230
231 <fieldset class="w500p inline">
232 <div class="row">
233 {{ form_label(form.pwd.old_password) }}
234 {{ form_errors(form.pwd.old_password) }}
235 {{ form_widget(form.pwd.old_password) }}
236 </div>
237 </fieldset>
238
239 <fieldset class="w500p inline">
240 <div class="row">
241 {{ form_label(form.pwd.new_password.first) }}
242 {{ form_errors(form.pwd.new_password.first) }}
243 {{ form_widget(form.pwd.new_password.first) }}
244 </div>
245 </fieldset>
246
247 <fieldset class="w500p inline">
248 <div class="row">
249 {{ form_label(form.pwd.new_password.second) }}
250 {{ form_errors(form.pwd.new_password.second) }}
251 {{ form_widget(form.pwd.new_password.second) }}
252 </div>
253 </fieldset>
254
255 {{ form_rest(form.pwd) }}
256 </form>
257
258 <h2>{{ 'config.tab_menu.rules'|trans }}</h2>
259
260 <ul>
261 {% for tagging_rule in app.user.config.taggingRules %}
262 <li>
263 {{ 'config.form_rules.if_label'|trans }}
264 « {{ tagging_rule.rule }} »
265 {{ 'config.form_rules.then_tag_as_label'|trans }}
266 « {{ tagging_rule.tags|join(', ') }} »
267 <a href="{{ path('edit_tagging_rule', {id: tagging_rule.id}) }}" title="{{ 'config.form_rules.edit_rule_label'|trans }}" class="tool mode_edit">✎</a>
268 <a href="{{ path('delete_tagging_rule', {id: tagging_rule.id}) }}" title="{{ 'config.form_rules.delete_rule_label'|trans }}" class="tool delete icon-trash icon"></a>
269 </li>
270 {% endfor %}
271 </ul>
272
273 {{ form_start(form.new_tagging_rule) }}
274 {{ form_errors(form.new_tagging_rule) }}
275
276 <fieldset class="w500p inline">
277 <div class="row">
278 {{ form_label(form.new_tagging_rule.rule) }}
279 {{ form_errors(form.new_tagging_rule.rule) }}
280 {{ form_widget(form.new_tagging_rule.rule) }}
281 </div>
282 </fieldset>
283
284 <fieldset class="w500p inline">
285 <div class="row">
286 {{ form_label(form.new_tagging_rule.tags) }}
287 {{ form_errors(form.new_tagging_rule.tags) }}
288 {{ form_widget(form.new_tagging_rule.tags) }}
289 </div>
290 </fieldset>
291
292 {{ form_rest(form.new_tagging_rule) }}
293 </form>
294
295 <div class="row">
296 <h3>{{ 'config.form_rules.card.import_tagging_rules'|trans }}</h3>
297 <p>{{ 'config.form_rules.card.import_tagging_rules_detail'|trans }}</p>
298 </div>
299
300 {{ form_start(form.import_tagging_rule) }}
301 {{ form_errors(form.import_tagging_rule) }}
302
303 <fieldset class="w500p inline">
304 <div class="row">
305 {{ form_label(form.import_tagging_rule.file) }}
306 {{ form_errors(form.import_tagging_rule.file) }}
307 {{ form_widget(form.import_tagging_rule.file) }}
308 </div>
309 </fieldset>
310
311 {{ form_rest(form.import_tagging_rule) }}
312 </form>
313
314 {% if app.user.config.taggingRules is not empty %}
315 <div class="row">
316 <h3>{{ 'config.form_rules.card.export_tagging_rules'|trans }}</h3>
317 <p>{{ 'config.form_rules.card.export_tagging_rules_detail'|trans }}</p>
318 <p><a href="{{ path('export_tagging_rule') }}" class="waves-effect waves-light btn">{{ 'config.form_rules.export'|trans }}</a></p>
319 </div>
320 {% endif %}
321
322 <div class="row">
323 <div class="input-field col s12">
324 <h3>{{ 'config.form_rules.faq.title'|trans }}</h3>
325
326 <h4>{{ 'config.form_rules.faq.tagging_rules_definition_title'|trans }}</h4>
327 <p class="help">{{ 'config.form_rules.faq.tagging_rules_definition_description'|trans|raw }}</p>
328
329 <h4>{{ 'config.form_rules.faq.how_to_use_them_title'|trans }}</h4>
330 <p class="help">{{ 'config.form_rules.faq.how_to_use_them_description'|trans|raw }}</p>
331
332 <h4>{{ 'config.form_rules.faq.variables_available_title'|trans }}</h4>
333 <p class="help">
334 {{ 'config.form_rules.faq.variables_available_description'|trans }}
335 </p>
336
337 <table class="bordered">
338 <thead>
339 <tr>
340 <th>{{ 'config.form_rules.faq.variable_description.label'|trans }}</th>
341 <th>{{ 'config.form_rules.faq.meaning'|trans }}</th>
342 <th>{{ 'config.form_rules.faq.operator_description.label'|trans }}</th>
343 <th>{{ 'config.form_rules.faq.meaning'|trans }}</th>
344 </tr>
345 </thead>
346
347 <tbody>
348 <tr>
349 <td>title</td>
350 <td>{{ 'config.form_rules.faq.variable_description.title'|trans }}</td>
351 <td>&lt;=</td>
352 <td>{{ 'config.form_rules.faq.operator_description.less_than'|trans }}</td>
353 </tr>
354 <tr>
355 <td>url</td>
356 <td>{{ 'config.form_rules.faq.variable_description.url'|trans }}</td>
357 <td>&lt;</td>
358 <td>{{ 'config.form_rules.faq.operator_description.strictly_less_than'|trans }}</td>
359 </tr>
360 <tr>
361 <td>isArchived</td>
362 <td>{{ 'config.form_rules.faq.variable_description.isArchived'|trans }}</td>
363 <td>&gt;=</td>
364 <td>{{ 'config.form_rules.faq.operator_description.greater_than'|trans }}</td>
365 </tr>
366 <tr>
367 <td>isStarred</td>
368 <td>{{ 'config.form_rules.faq.variable_description.isStarred'|trans }}</td>
369 <td>&gt;</td>
370 <td>{{ 'config.form_rules.faq.operator_description.strictly_greater_than'|trans }}</td>
371 </tr>
372 <tr>
373 <td>content</td>
374 <td>{{ 'config.form_rules.faq.variable_description.content'|trans }}</td>
375 <td>=</td>
376 <td>{{ 'config.form_rules.faq.operator_description.equal_to'|trans }}</td>
377 </tr>
378 <tr>
379 <td>language</td>
380 <td>{{ 'config.form_rules.faq.variable_description.language'|trans }}</td>
381 <td>!=</td>
382 <td>{{ 'config.form_rules.faq.operator_description.not_equal_to'|trans }}</td>
383 </tr>
384 <tr>
385 <td>mimetype</td>
386 <td>{{ 'config.form_rules.faq.variable_description.mimetype'|trans }}</td>
387 <td>OR</td>
388 <td>{{ 'config.form_rules.faq.operator_description.or'|trans }}</td>
389 </tr>
390 <tr>
391 <td>readingTime</td>
392 <td>{{ 'config.form_rules.faq.variable_description.readingTime'|trans }}</td>
393 <td>AND</td>
394 <td>{{ 'config.form_rules.faq.operator_description.and'|trans }}</td>
395 </tr>
396 <tr>
397 <td>domainName</td>
398 <td>{{ 'config.form_rules.faq.variable_description.domainName'|trans }}</td>
399 <td>matches</td>
400 <td>{{ 'config.form_rules.faq.operator_description.matches'|trans|raw }}</td>
401 </tr>
402 </tbody>
403 </table>
404 </div>
405 </div>
406
407 <h2>{{ 'config.tab_menu.ignore_origin'|trans }}</h2>
408
409 <ul>
410 {% for ignore_origin_rule in app.user.config.ignoreOriginRules %}
411 <li>
412 {{ 'config.form_rules.if_label'|trans }}
413 « {{ ignore_origin_rule.rule }} »
414 <a href="{{ path('edit_ignore_origin_rule', {id: ignore_origin_rule.id}) }}" title="{{ 'config.form_rules.edit_rule_label'|trans }}" class="tool mode_edit">✎</a>
415 <a href="{{ path('delete_ignore_origin_rule', {id: ignore_origin_rule.id}) }}" title="{{ 'config.form_rules.delete_rule_label'|trans }}" class="tool delete icon-trash icon"></a>
416 </li>
417 {% endfor %}
418 </ul>
419
420 {{ form_start(form.new_ignore_origin_user_rule) }}
421 {{ form_errors(form.new_ignore_origin_user_rule) }}
422
423 <fieldset class="w500p inline">
424 <div class="row">
425 {{ form_label(form.new_ignore_origin_user_rule.rule) }}
426 {{ form_errors(form.new_ignore_origin_user_rule.rule) }}
427 {{ form_widget(form.new_ignore_origin_user_rule.rule) }}
428 </div>
429 </fieldset>
430
431 {{ form_rest(form.new_ignore_origin_user_rule) }}
432 </form>
433
434 <div class="row">
435 <div class="input-field col s12">
436 <h4>{{ 'config.form_ignore_origin_rules.faq.title'|trans }}</h4>
437
438 <h5>{{ 'config.form_ignore_origin_rules.faq.ignore_origin_rules_definition_title'|trans }}</h5>
439 <p class="help">{{ 'config.form_ignore_origin_rules.faq.ignore_origin_rules_definition_description'|trans|raw }}</p>
440
441 <h5>{{ 'config.form_ignore_origin_rules.faq.how_to_use_them_title'|trans }}</h5>
442 <p class="help">{{ 'config.form_ignore_origin_rules.faq.how_to_use_them_description'|trans|raw }}</p>
443
444 <h5>{{ 'config.form_ignore_origin_rules.faq.variables_available_title'|trans }}</h5>
445 <p class="help">
446 {{ 'config.form_ignore_origin_rules.faq.variables_available_description'|trans }}
447 </p>
448
449 <table class="bordered">
450 <thead>
451 <tr>
452 <th>{{ 'config.form_ignore_origin_rules.faq.variable_description.label'|trans }}</th>
453 <th>{{ 'config.form_ignore_origin_rules.faq.meaning'|trans }}</th>
454 <th>{{ 'config.form_ignore_origin_rules.faq.operator_description.label'|trans }}</th>
455 <th>{{ 'config.form_ignore_origin_rules.faq.meaning'|trans }}</th>
456 </tr>
457 </thead>
458
459 <tbody>
460 <tr>
461 <td>host</td>
462 <td>{{ 'config.form_ignore_origin_rules.faq.variable_description.host'|trans }}</td>
463 <td>=</td>
464 <td>{{ 'config.form_ignore_origin_rules.faq.operator_description.equal_to'|trans }}</td>
465 </tr>
466 <tr>
467 <td>_all</td>
468 <td>{{ 'config.form_ignore_origin_rules.faq.variable_description._all'|trans }}</td>
469 <td>~</td>
470 <td>{{ 'config.form_ignore_origin_rules.faq.operator_description.matches'|trans|raw }}</td>
471 </tr>
472 </tbody>
473 </table>
474 </div>
475 </div>
476
477 <h2>{{ 'config.reset.title'|trans }}</h2>
478 <fieldset class="w500p inline">
479 <p>{{ 'config.reset.description'|trans }}</p>
480 <ul>
481 <li>
482 <a href="{{ path('config_reset', { type: 'annotations'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
483 {{ 'config.reset.annotations'|trans }}
484 </a>
485 </li>
486 <li>
487 <a href="{{ path('config_reset', { type: 'tags'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
488 {{ 'config.reset.tags'|trans }}
489 </a>
490 </li>
491 <li>
492 <a href="{{ path('config_reset', { type: 'archived'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
493 {{ 'config.reset.archived'|trans }}
494 </a>
495 </li>
496 <li>
497 <a href="{{ path('config_reset', { type: 'entries'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
498 {{ 'config.reset.entries'|trans }}
499 </a>
500 </li>
501 </ul>
502 </fieldset>
503 {% endblock %}