Skip to content

Commit

Permalink
Town6: Unify the look of the side-panel actions
Browse files Browse the repository at this point in the history
TYPE: Feature
LINK: OGC-1855
  • Loading branch information
BreathingFlesh authored Oct 14, 2024
1 parent 6d17e69 commit 70697c7
Show file tree
Hide file tree
Showing 10 changed files with 156 additions and 123 deletions.
2 changes: 1 addition & 1 deletion src/onegov/org/layout.py
Original file line number Diff line number Diff line change
Expand Up @@ -3347,7 +3347,7 @@ def get_pub_link(
classes = []
if filter:
filter_data[filter] = True
if toggle_active and filter in self.request.params:
if toggle_active and self.request.params.get(filter) == '1':
classes.append('active')

return Link(
Expand Down
2 changes: 1 addition & 1 deletion src/onegov/org/locale/de_CH/LC_MESSAGES/onegov.org.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE 1.0\n"
"POT-Creation-Date: 2024-09-30 10:16+0200\n"
"POT-Creation-Date: 2024-10-01 13:17+0200\n"
"PO-Revision-Date: 2022-03-15 10:21+0100\n"
"Last-Translator: Marc Sommerhalder <[email protected]>\n"
"Language-Team: German\n"
Expand Down
47 changes: 28 additions & 19 deletions src/onegov/town6/locale/de_CH/LC_MESSAGES/onegov.town6.po
Original file line number Diff line number Diff line change
Expand Up @@ -357,12 +357,8 @@ msgstr "Weitere Informationen"
msgid "More"
msgstr "Mehr"

msgid "Propose entry"
msgstr "Eintrag vorschlagen"

msgid "Something missing? Propose a new entry."
msgstr ""
"Fehlt ein Eintrag im Verzeichnis? Schlagen Sie einen neuen Eintrag vor."
msgid "Publication"
msgstr "Publikation"

msgid "Documents"
msgstr "Dokumente"
Expand All @@ -373,6 +369,9 @@ msgstr "Aktionen"
msgid "Get notifications on new entries"
msgstr "Benachrichtigungen bei neuen Einträgen erhalten"

msgid "Propose a new entry"
msgstr "Neuen Eintrag vorschlagen"

msgid "Internal Notes"
msgstr "Interne Notizen"

Expand All @@ -382,11 +381,8 @@ msgstr "Externe Verknüpfung"
msgid "More information"
msgstr "Weiterführende Informationen"

msgid "Change Request"
msgstr "Änderung vorschlagen"

msgid "Found an error? Propose a change to this entry."
msgstr "Haben Sie einen Fehler gefunden? Schlagen Sie eine Änderung vor."
msgid "Propose a change to this entry"
msgstr "Änderung für diesen Eintrag vorschlagen"

msgid ""
"Subscribers may always unsubscribe themselves through a link shown at the "
Expand Down Expand Up @@ -641,18 +637,21 @@ msgstr ""
msgid "Map"
msgstr "Karte"

msgid "Links"
msgstr "Links"

msgid "More news"
msgstr "Weitere News"
msgid "Other Entries"
msgstr "Weitere Einträge"

msgid "Previous Entry"
msgstr "Vorheriger Eintrag"

msgid "Next Entry"
msgstr "Nächster Eintrag"

msgid "Links"
msgstr "Links"

msgid "More news"
msgstr "Weitere News"

msgid "Total Amount"
msgstr "Totalbetrag"

Expand Down Expand Up @@ -942,9 +941,6 @@ msgstr "Wird publiziert bis:"
msgid "Publication end date:"
msgstr "Enddatum der Publikation:"

msgid "Publication"
msgstr "Publikation"

msgid "Not a publication"
msgstr "keine Publikation"

Expand Down Expand Up @@ -2189,6 +2185,19 @@ msgstr ""
msgid "New Note"
msgstr "Neue Notiz"

#~ msgid "Change Request"
#~ msgstr "Änderung vorschlagen"

#~ msgid "Found an error? Propose a change to this entry."
#~ msgstr "Haben Sie einen Fehler gefunden? Schlagen Sie eine Änderung vor."

#~ msgid "Propose entry"
#~ msgstr "Eintrag vorschlagen"

#~ msgid "Something missing? Propose a new entry."
#~ msgstr ""
#~ "Fehlt ein Eintrag im Verzeichnis? Schlagen Sie einen neuen Eintrag vor."

#~ msgid "Newsletter Subscription"
#~ msgstr "Newsletter-Abonnement"

Expand Down
49 changes: 29 additions & 20 deletions src/onegov/town6/locale/fr_CH/LC_MESSAGES/onegov.town6.po
Original file line number Diff line number Diff line change
Expand Up @@ -357,11 +357,8 @@ msgstr "Plus d'informations"
msgid "More"
msgstr "Plus"

msgid "Propose entry"
msgstr "Proposer une entrée"

msgid "Something missing? Propose a new entry."
msgstr "Il manque quelque chose? Proposez une nouvelle entrée."
msgid "Publication"
msgstr "Publication"

msgid "Documents"
msgstr "Documents"
Expand All @@ -372,6 +369,9 @@ msgstr "Actions"
msgid "Get notifications on new entries"
msgstr "Recevoir des notifications sur les nouvelles entrées"

msgid "Propose a new entry"
msgstr "Proposer une nouvelle entrée"

msgid "Internal Notes"
msgstr "Notes internes"

Expand All @@ -381,13 +381,8 @@ msgstr "Lien externe"
msgid "More information"
msgstr "Plus de renseignements"

msgid "Change Request"
msgstr "Demande de modification"

msgid "Found an error? Propose a change to this entry."
msgstr ""
"Vous avez trouvé une erreur? Proposez une modification à apporter à cette "
"entrée."
msgid "Propose a change to this entry"
msgstr "Proposer une modification pour cette entrée"

msgid ""
"Subscribers may always unsubscribe themselves through a link shown at the "
Expand Down Expand Up @@ -642,18 +637,21 @@ msgstr ""
msgid "Map"
msgstr "Carte"

msgid "Links"
msgstr "Liens"

msgid "More news"
msgstr "Plus de nouvelles"
msgid "Other Entries"
msgstr "Autres entrées"

msgid "Previous Entry"
msgstr "Entrée précédente"

msgid "Next Entry"
msgstr "Entrée suivante"

msgid "Links"
msgstr "Liens"

msgid "More news"
msgstr "Plus de nouvelles"

msgid "Total Amount"
msgstr "Montant total"

Expand Down Expand Up @@ -943,9 +941,6 @@ msgstr "Sera publié jusqu'au:"
msgid "Publication end date:"
msgstr "Date de fin de publication:"

msgid "Publication"
msgstr "Publication"

msgid "Not a publication"
msgstr "Pas une publication"

Expand Down Expand Up @@ -2197,6 +2192,20 @@ msgstr ""
msgid "New Note"
msgstr "Nouveau commentaire"

#~ msgid "Change Request"
#~ msgstr "Demande de modification"

#~ msgid "Found an error? Propose a change to this entry."
#~ msgstr ""
#~ "Vous avez trouvé une erreur? Proposez une modification à apporter à cette "
#~ "entrée."

#~ msgid "Propose entry"
#~ msgstr "Proposer une entrée"

#~ msgid "Something missing? Propose a new entry."
#~ msgstr "Il manque quelque chose? Proposez une nouvelle entrée."

#~ msgid "Newsletter Subscription"
#~ msgstr "Abonnement à la newsletter "

Expand Down
45 changes: 27 additions & 18 deletions src/onegov/town6/locale/it_CH/LC_MESSAGES/onegov.town6.po
Original file line number Diff line number Diff line change
Expand Up @@ -353,11 +353,8 @@ msgstr "Ulteriori informazioni"
msgid "More"
msgstr "Più"

msgid "Propose entry"
msgstr "Proponi un elemento"

msgid "Something missing? Propose a new entry."
msgstr "Manca qualcosa? Proponi un nuovo elemento."
msgid "Publication"
msgstr "Pubblicazione"

msgid "Documents"
msgstr "Documenti"
Expand All @@ -368,6 +365,9 @@ msgstr "Azioni"
msgid "Get notifications on new entries"
msgstr "Ricevi notifiche su nuovi elementi"

msgid "Propose a new entry"
msgstr "Proporre un nuovo elemento"

msgid "Internal Notes"
msgstr "Note interne"

Expand All @@ -378,11 +378,8 @@ msgstr "Collegamento esterno"
msgid "More information"
msgstr "Conferma"

msgid "Change Request"
msgstr "Richiesta di modifica"

msgid "Found an error? Propose a change to this entry."
msgstr "Trovato un errore? Proponi una modifica a questo elemento."
msgid "Propose a change to this entry"
msgstr "Suggerisci una modifica per questa voce"

msgid ""
"Subscribers may always unsubscribe themselves through a link shown at the "
Expand Down Expand Up @@ -637,18 +634,21 @@ msgstr ""
msgid "Map"
msgstr "Mappa"

msgid "Links"
msgstr "Collegamenti"

msgid "More news"
msgstr "Altre notizie"
msgid "Other Entries"
msgstr "Altri elementi"

msgid "Previous Entry"
msgstr "Voce precedente"

msgid "Next Entry"
msgstr "Prossima voce"

msgid "Links"
msgstr "Collegamenti"

msgid "More news"
msgstr "Altre notizie"

msgid "Total Amount"
msgstr "Importo totale"

Expand Down Expand Up @@ -941,9 +941,6 @@ msgstr "Sarà pubblicato fino a:"
msgid "Publication end date:"
msgstr "Data di fine pubblicazione:"

msgid "Publication"
msgstr "Pubblicazione"

msgid "Not a publication"
msgstr "Non una pubblicazione"

Expand Down Expand Up @@ -2190,6 +2187,18 @@ msgstr ""
msgid "New Note"
msgstr "Nuova nota"

#~ msgid "Change Request"
#~ msgstr "Richiesta di modifica"

#~ msgid "Found an error? Propose a change to this entry."
#~ msgstr "Trovato un errore? Proponi una modifica a questo elemento."

#~ msgid "Propose entry"
#~ msgstr "Proponi un elemento"

#~ msgid "Something missing? Propose a new entry."
#~ msgstr "Manca qualcosa? Proponi un nuovo elemento."

#~ msgid "Newsletter Subscription"
#~ msgstr "Abbonamento alla newsletter "

Expand Down
45 changes: 23 additions & 22 deletions src/onegov/town6/templates/directory.pt
Original file line number Diff line number Diff line change
Expand Up @@ -99,33 +99,28 @@
</div>
</div>

<div class="side-panel" tal:condition="layout.publication_filters">
<h3 i18n:translate>Publication</h3>
<div class="side-panel-with-bg">
<div class="filter-panel">
<ul class="tags">
<li tal:repeat="link layout.publication_links">
<span class="blank-label click-through rounded ${' '.join(link.attrs['class'])}">
${link(layout)}
</span>
</li>
</ul>
</div>
</div>
</div>

<div class="filter-panel side-panel" tal:condition="filters">
<div tal:repeat="filter filters" class="filter-periods">
<h3 class="filter-title">${filter.title}</h3>
<div metal:use-macro="layout.macros['tags']" tal:define="tags filter.tags" />
</div>
</div>

<div class="submit-yours side-panel" tal:condition="directory.enable_submissions">
<dl>
<dt>
<a href="${submit}">
<tal:b tal:condition="request.is_manager" metal:use-macro="layout.macros.access_hint" tal:define="item directory"/>
<h3 i18n:translate="">Propose entry</h3>
</a>
</dt>
<dd i18n:translate="">Something missing? Propose a new entry.</dd>
</dl>
</div>
<div class="publication-nav side-panel" tal:condition="layout.publication_filters">
<button type="button" data-toggle="pubnav" class="button small dropdown secondary" i18n:translate>${layout.publication_filter_title}</button>
<div id="pubnav" class="dropdown-pane" data-dropdown data-position="bottom" data-alignment="right" data-parent-class="cell" data-hover-pane="true" data-hover="true">
<ul class="f-dropdown">
<li tal:repeat="link layout.publication_links" tal:content="link(layout)"></li>
</ul>
</div>
</div>

<div class="side-panel files-panel" tal:condition="files and directory.show_file_links_in_sidebar|True">
<h3 i18n:translate>Documents</h3>
<ul class="more-list">
Expand All @@ -138,16 +133,22 @@
</ul>
</div>

<div class="side-panel" tal:condition="directory.enable_update_notifications|False">
<div class="side-panel" tal:condition="directory.enable_update_notifications|False or directory.enable_submissions">
<h3 i18n:translate>Actions</h3>
<div class="side-panel-with-bg">
<ul class="more-list">
<li class="icon-item">
<li class="icon-item" tal:condition="directory.enable_update_notifications|False">
<a class="list-link multi-line" href="${new_recipient_link}">
<i class="fa fa-bell"></i>
<span class="list-title" i18n:translate>Get notifications on new entries</span>
</a>
</li>
<li class="icon-item" tal:condition="directory.enable_submissions">
<a class="list-link multi-line" href="${submit}">
<i class="fa fa-folder-plus"></i>
<span class="list-title" i18n:translate>Propose a new entry</span>
</a>
</li>
</ul>
</div>
</div>
Expand Down
Loading

0 comments on commit 70697c7

Please sign in to comment.