1 {% extends 'page.html.twig' %}
4 <form action="{{ url_for('titles') }}" method="post" enctype="multipart/form-data" class="ui form">
5 <div class="ui basic fitted segment loader_selector">
6 <table class="listing ui celled striped table">
9 <th class="id_row">#</th>
10 <th>{{ _T("Short form") }}</th>
11 <th>{{ _T("Long form") }}</th>
12 <th>{{ _T("Actions") }}</th>
18 <span class="visually-hidden">
22 <td class="left" data-title="{{ _T("Short form") }}">
23 <div class="required field">
24 <label for="short_label" class="visually-hidden">{{ _T("Short form") }}</label>
25 <input size="20" type="text" name="short_label" required="required"/>
28 <td class="left" data-title="{{ _T("Long form") }}">
29 <div class="required field">
30 <label for="long_label" class="visually-hidden">{{ _T("Long form") }}</label>
31 <input size="20" type="text" name="long_label" required="required"/>
34 <td class="center actions_row">
35 <input type="hidden" name="new" value="1" />
36 <button type="submit" name="valid" class="ui labeled icon button">
37 <i class="plus green icon" aria-hidden="true"></i>
44 {% for title in titles_list %}
47 {% if preferences.pref_show_id %}
52 <span class="displaynone">
53 <a href="{{ url_for('editTitle', {'id': title.id}) }}">
54 {{ _T("%s title")|replace({'%s': title.short|escape}) }}
58 <td class="left" data-title="{{ _T("Short form") }}">{{ title.short|escape }}</td>
59 <td class="left" data-title="{{ _T("Long form") }}">{{ title.long|escape }}</td>
60 <td class="center actions_row">
62 href="{{ url_for('editTitle', {'id': title.id}) }}"
63 class="action single-edit"
65 <i class="ui edit icon tooltip" aria-hidden="true"></i>
66 <span class="ui special popup">{{ _T("Edit '%s' title")|replace({'%s': title.short|escape}) }}</span>
68 {% if title.id == 1 or title.id == 2 %}
69 <i class="ui icon"> </i>
72 href="{{ url_for('removeTitle', {'id': title.id}) }}"
75 <i class="ui trash red icon tooltip" aria-hidden="true"></i>
76 <span class="ui special popup">{{ _T("Delete '%s' title")|replace({'%s': title.short|escape}) }}</span>
85 {% include 'components/forms/csrf.html.twig' %}
89 {% block javascripts %}
90 <script type="text/javascript">
92 {% set modal_onapprove = "
93 $('.modal-form form #redirect_uri').val(window.location.href);
94 $('.modal-form form').submit();
96 {% include "elements/js/modal_action.js.twig" with {
97 selector: ".single-edit",
98 modal_title_twig: _T("Edit title")|e("js"),
100 modal_onapprove: modal_onapprove
103 {% include "elements/js/removal.js.twig" with {
104 single_action: "true"