From 6ff617a73374c77a0356d0418b558eecf566f4c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Guillot?= Date: Thu, 2 Jan 2020 13:03:34 -0800 Subject: [PATCH] Make menu consistent across feed pages --- locale/translations.go | 27 ++++++---- locale/translations/de_DE.json | 1 + locale/translations/en_US.json | 1 + locale/translations/es_ES.json | 1 + locale/translations/fr_FR.json | 1 + locale/translations/it_IT.json | 1 + locale/translations/nl_NL.json | 1 + locale/translations/pl_PL.json | 1 + locale/translations/ru_RU.json | 1 + locale/translations/zh_CN.json | 1 + template/common.go | 20 ++++++++ template/html/add_subscription.html | 12 +---- template/html/choose_subscription.html | 12 +---- template/html/common/feed_menu.html | 19 +++++++ template/html/edit_feed.html | 7 +-- template/html/feeds.html | 15 +----- template/html/import.html | 12 +---- template/views.go | 68 +++++--------------------- 18 files changed, 83 insertions(+), 118 deletions(-) create mode 100644 template/html/common/feed_menu.html diff --git a/locale/translations.go b/locale/translations.go index d73b6b02..cd513306 100644 --- a/locale/translations.go +++ b/locale/translations.go @@ -47,6 +47,7 @@ var translations = map[string]string{ "menu.add_feed": "Abonnement hinzufügen", "menu.add_user": "Benutzer anlegen", "menu.flush_history": "Verlauf leeren", + "menu.feed_entries": "Artikel", "search.label": "Suche", "search.placeholder": "Suche...", "pagination.next": "Nächste", @@ -353,6 +354,7 @@ var translations = map[string]string{ "menu.add_feed": "Add subscription", "menu.add_user": "Add user", "menu.flush_history": "Flush history", + "menu.feed_entries": "Entries", "search.label": "Search", "search.placeholder": "Search...", "pagination.next": "Next", @@ -639,6 +641,7 @@ var translations = map[string]string{ "menu.add_feed": "Agregar suscripción", "menu.add_user": "Agregar usuario", "menu.flush_history": "Borrar historial", + "menu.feed_entries": "Artículos", "search.label": "Buscar", "search.placeholder": "Búsqueda...", "pagination.next": "Siguiente", @@ -925,6 +928,7 @@ var translations = map[string]string{ "menu.add_feed": "Ajouter un abonnement", "menu.add_user": "Ajouter un utilisateur", "menu.flush_history": "Supprimer l'historique", + "menu.feed_entries": "Articles", "search.label": "Recherche", "search.placeholder": "Recherche...", "pagination.next": "Suivant", @@ -1231,6 +1235,7 @@ var translations = map[string]string{ "menu.add_feed": "Aggiungi feed", "menu.add_user": "Aggiungi utente", "menu.flush_history": "Svuota la cronologia", + "menu.feed_entries": "Articoli", "search.label": "Cerca", "search.placeholder": "Cerca...", "pagination.next": "Successivo", @@ -1517,6 +1522,7 @@ var translations = map[string]string{ "menu.add_feed": "Feed toevoegen", "menu.add_user": "Gebruiker toevoegen", "menu.flush_history": "Verwijder geschiedenis", + "menu.feed_entries": "Lidwoord", "search.label": "Zoeken", "search.placeholder": "Zoeken...", "pagination.next": "Volgende", @@ -1821,6 +1827,7 @@ var translations = map[string]string{ "menu.add_feed": "Dodaj subskrypcję", "menu.add_user": "Dodaj użytkownika", "menu.flush_history": "Usuń historię", + "menu.feed_entries": "Artykuły", "search.label": "Szukaj", "search.placeholder": "Szukaj...", "pagination.next": "Następny", @@ -2133,6 +2140,7 @@ var translations = map[string]string{ "menu.add_feed": "Добавить подписку", "menu.add_user": "Добавить пользователя", "menu.flush_history": "Отчистить историю", + "menu.feed_entries": "статьи", "search.label": "Поиск", "search.placeholder": "Поиск…", "pagination.next": "Следующая", @@ -2427,6 +2435,7 @@ var translations = map[string]string{ "menu.add_feed": "新增订阅", "menu.add_user": "新建用户", "menu.flush_history": "清理历史", + "menu.feed_entries": "文章", "search.label": "搜索", "search.placeholder": "搜索…", "pagination.next": "下一页", @@ -2683,13 +2692,13 @@ var translations = map[string]string{ } var translationsChecksums = map[string]string{ - "de_DE": "7b608117d1f832440680696aa796d0c950218e9d2ce0cc7a58c3fd183ce8527f", - "en_US": "7842b6735d09ff9aef21439ae3b99a9bd85f6fe3764e31f77e56261f12a0d4bc", - "es_ES": "2372fe8e0a45125b345904d1c661a81e4e5003240837cf347e78f236809b4121", - "fr_FR": "c9371fc612b4fc75a10e2480d2fe6da1916e45b45d057fedf626eed82d75b5fa", - "it_IT": "d86a4e99e451c0a38810c20326f6b6ac9dcb0810bdef4d4e168c025a3be3b063", - "nl_NL": "ef7e7d20c8548a6ef96b12c3709c4da4e663a2cdc54fcdc8cfaf6f987eb4126a", - "pl_PL": "083af42ed3123e8fcfe54204928b4f27f505bd2fdf9dc2b949f77e0c09c18ce9", - "ru_RU": "c78a1655230afc5c4fb9ebb4ef8970b944e4b8c157db4f8b0cfc29f126de75fa", - "zh_CN": "4c43cab1df36f656a7f8912daf5ef8fbf01a35c87f8569bca3716dbb3117f33a", + "de_DE": "b02e4b146458b740ef59978b47db321bf7fcf47f3eda79fc763560e80123ca2e", + "en_US": "91000303814fb62060f6605b2b6481550f3686f1e293f30ca3c5d77cc60ac467", + "es_ES": "01c0b685ed7e90852deca665a652eb426751be1af1e431fac66df8d3f6ab083c", + "fr_FR": "3f2394d5c3e3a3e849f3fdf64ae519409d73cf27094cf06cb8ab1e4090d31b2a", + "it_IT": "17563329ba60a365351155492ebe120ff6942e8cf7dd9a56304027bc0957008e", + "nl_NL": "bd0a01c49b7fa34cdcbda9b9743c292178afdd024f2acb97ce863617faddbea2", + "pl_PL": "d5f75a944522d03c64e95d21f1c80004464c8b2de75dae649d7216154467b511", + "ru_RU": "2716429c2bdb6a417d464d313e5b4a1820884129c5d85d75bf1884945decfbcb", + "zh_CN": "9c6cc04f821c7570a738f81b57c4b98ae58151affff31476dd150a01111f94f3", } diff --git a/locale/translations/de_DE.json b/locale/translations/de_DE.json index 6989050a..e3164365 100644 --- a/locale/translations/de_DE.json +++ b/locale/translations/de_DE.json @@ -42,6 +42,7 @@ "menu.add_feed": "Abonnement hinzufügen", "menu.add_user": "Benutzer anlegen", "menu.flush_history": "Verlauf leeren", + "menu.feed_entries": "Artikel", "search.label": "Suche", "search.placeholder": "Suche...", "pagination.next": "Nächste", diff --git a/locale/translations/en_US.json b/locale/translations/en_US.json index d3423602..5e20a2fd 100644 --- a/locale/translations/en_US.json +++ b/locale/translations/en_US.json @@ -42,6 +42,7 @@ "menu.add_feed": "Add subscription", "menu.add_user": "Add user", "menu.flush_history": "Flush history", + "menu.feed_entries": "Entries", "search.label": "Search", "search.placeholder": "Search...", "pagination.next": "Next", diff --git a/locale/translations/es_ES.json b/locale/translations/es_ES.json index a73e6d1f..422a7856 100644 --- a/locale/translations/es_ES.json +++ b/locale/translations/es_ES.json @@ -42,6 +42,7 @@ "menu.add_feed": "Agregar suscripción", "menu.add_user": "Agregar usuario", "menu.flush_history": "Borrar historial", + "menu.feed_entries": "Artículos", "search.label": "Buscar", "search.placeholder": "Búsqueda...", "pagination.next": "Siguiente", diff --git a/locale/translations/fr_FR.json b/locale/translations/fr_FR.json index 94fad16f..ecfac521 100644 --- a/locale/translations/fr_FR.json +++ b/locale/translations/fr_FR.json @@ -42,6 +42,7 @@ "menu.add_feed": "Ajouter un abonnement", "menu.add_user": "Ajouter un utilisateur", "menu.flush_history": "Supprimer l'historique", + "menu.feed_entries": "Articles", "search.label": "Recherche", "search.placeholder": "Recherche...", "pagination.next": "Suivant", diff --git a/locale/translations/it_IT.json b/locale/translations/it_IT.json index 9a4bb0cb..9b3f69c6 100644 --- a/locale/translations/it_IT.json +++ b/locale/translations/it_IT.json @@ -42,6 +42,7 @@ "menu.add_feed": "Aggiungi feed", "menu.add_user": "Aggiungi utente", "menu.flush_history": "Svuota la cronologia", + "menu.feed_entries": "Articoli", "search.label": "Cerca", "search.placeholder": "Cerca...", "pagination.next": "Successivo", diff --git a/locale/translations/nl_NL.json b/locale/translations/nl_NL.json index 3fd3ac59..d071b4b4 100644 --- a/locale/translations/nl_NL.json +++ b/locale/translations/nl_NL.json @@ -42,6 +42,7 @@ "menu.add_feed": "Feed toevoegen", "menu.add_user": "Gebruiker toevoegen", "menu.flush_history": "Verwijder geschiedenis", + "menu.feed_entries": "Lidwoord", "search.label": "Zoeken", "search.placeholder": "Zoeken...", "pagination.next": "Volgende", diff --git a/locale/translations/pl_PL.json b/locale/translations/pl_PL.json index 5e4d0176..99c72ba9 100644 --- a/locale/translations/pl_PL.json +++ b/locale/translations/pl_PL.json @@ -42,6 +42,7 @@ "menu.add_feed": "Dodaj subskrypcję", "menu.add_user": "Dodaj użytkownika", "menu.flush_history": "Usuń historię", + "menu.feed_entries": "Artykuły", "search.label": "Szukaj", "search.placeholder": "Szukaj...", "pagination.next": "Następny", diff --git a/locale/translations/ru_RU.json b/locale/translations/ru_RU.json index e47ba9b5..a8fb4305 100644 --- a/locale/translations/ru_RU.json +++ b/locale/translations/ru_RU.json @@ -42,6 +42,7 @@ "menu.add_feed": "Добавить подписку", "menu.add_user": "Добавить пользователя", "menu.flush_history": "Отчистить историю", + "menu.feed_entries": "статьи", "search.label": "Поиск", "search.placeholder": "Поиск…", "pagination.next": "Следующая", diff --git a/locale/translations/zh_CN.json b/locale/translations/zh_CN.json index b4e0f314..fddaf85a 100644 --- a/locale/translations/zh_CN.json +++ b/locale/translations/zh_CN.json @@ -42,6 +42,7 @@ "menu.add_feed": "新增订阅", "menu.add_user": "新建用户", "menu.flush_history": "清理历史", + "menu.feed_entries": "文章", "search.label": "搜索", "search.placeholder": "搜索…", "pagination.next": "下一页", diff --git a/template/common.go b/template/common.go index 1dae0c76..ffd1329b 100644 --- a/template/common.go +++ b/template/common.go @@ -77,6 +77,25 @@ var templateCommonMap = map[string]string{ {{ end }} +{{ end }}`, + "feed_menu": `{{ define "feed_menu" }} + {{ end }}`, "item_meta": `{{ define "item_meta" }}
@@ -332,6 +351,7 @@ var templateCommonMap = map[string]string{ var templateCommonMapChecksums = map[string]string{ "entry_pagination": "4faa91e2eae150c5e4eab4d258e039dfdd413bab7602f0009360e6d52898e353", "feed_list": "db406e7cb81292ce1d974d63f63270384a286848b2e74fe36bf711b4eb5717dd", + "feed_menu": "318d8662dda5ca9dfc75b909c8461e79c86fb5082df1428f67aaf856f19f4b50", "item_meta": "285daae854456d0156967fdbe2834c954f2c772239bb736c88041d49a4a21219", "layout": "f19597d8cd74e17b33826c25b8421f46fef87276f0d95c695bba8f53bb4f95e6", "pagination": "3386e90c6e1230311459e9a484629bc5d5bf39514a75ef2e73bbbc61142f7abb", diff --git a/template/html/add_subscription.html b/template/html/add_subscription.html index c3e80763..e435f32d 100644 --- a/template/html/add_subscription.html +++ b/template/html/add_subscription.html @@ -3,17 +3,7 @@ {{ define "content"}} {{ if not .categories }} diff --git a/template/html/choose_subscription.html b/template/html/choose_subscription.html index de330032..cf7cf5a6 100644 --- a/template/html/choose_subscription.html +++ b/template/html/choose_subscription.html @@ -3,17 +3,7 @@ {{ define "content"}}
diff --git a/template/html/common/feed_menu.html b/template/html/common/feed_menu.html new file mode 100644 index 00000000..faba6fd2 --- /dev/null +++ b/template/html/common/feed_menu.html @@ -0,0 +1,19 @@ +{{ define "feed_menu" }} + +{{ end }} \ No newline at end of file diff --git a/template/html/edit_feed.html b/template/html/edit_feed.html index da393b5a..8bb5692e 100644 --- a/template/html/edit_feed.html +++ b/template/html/edit_feed.html @@ -8,13 +8,10 @@ {{ t "menu.feeds" }}
  • - {{ t "menu.add_feed" }} + {{ t "menu.feed_entries" }}
  • - {{ t "menu.export" }} -
  • -
  • - {{ t "menu.import" }} + {{ t "menu.refresh_feed" }}
  • diff --git a/template/html/feeds.html b/template/html/feeds.html index e4d24bf5..fa9d8adb 100644 --- a/template/html/feeds.html +++ b/template/html/feeds.html @@ -3,20 +3,7 @@ {{ define "content"}} {{ if not .feeds }} diff --git a/template/html/import.html b/template/html/import.html index 12454860..042b1962 100644 --- a/template/html/import.html +++ b/template/html/import.html @@ -3,17 +3,7 @@ {{ define "content"}} {{ if .errorMessage }} diff --git a/template/views.go b/template/views.go index c4e9b865..4e87b57e 100644 --- a/template/views.go +++ b/template/views.go @@ -34,17 +34,7 @@ var templateViewsMap = map[string]string{ {{ define "content"}} {{ if not .categories }} @@ -298,17 +288,7 @@ var templateViewsMap = map[string]string{ {{ define "content"}} @@ -442,13 +422,10 @@ var templateViewsMap = map[string]string{ {{ t "menu.feeds" }}
  • - {{ t "menu.add_feed" }} + {{ t "menu.feed_entries" }}
  • - {{ t "menu.export" }} -
  • -
  • - {{ t "menu.import" }} + {{ t "menu.refresh_feed" }}
  • @@ -803,20 +780,7 @@ var templateViewsMap = map[string]string{ {{ define "content"}} {{ if not .feeds }} @@ -876,17 +840,7 @@ var templateViewsMap = map[string]string{ {{ define "content"}} {{ if .errorMessage }} @@ -1351,22 +1305,22 @@ var templateViewsMap = map[string]string{ var templateViewsMapChecksums = map[string]string{ "about": "4035658497363d7af7f79be83190404eb21ec633fe8ec636bdfc219d9fc78cfc", - "add_subscription": "5bae8c60989593257f515f9c73b35c854a94bee4b2fb08ad38aa93b17be9c1b5", + "add_subscription": "0dbea93b6fc07423fa066122ad960c69616b829533371a2dbadec1e22d4f1ae0", "bookmark_entries": "65588da78665699dd3f287f68325e9777d511f1a57fee4131a5bb6d00bb68df8", "categories": "2c5dd0ed6355bd5acc393bbf6117d20458b5581aab82036008324f6bbbe2af75", "category_entries": "dee7b9cd60c6c46f01dd4289940679df31c1fce28ce4aa7249fa459023e1eeb4", "category_feeds": "527c2ffbc4fcec775071424ba1022ae003525dba53a28cc41f48fb7b30aa984b", - "choose_subscription": "26f37a6e1c52cf70a0900dbbbb99f9ee905698ea11b722798093e22166798755", + "choose_subscription": "84c9730cadd78e6ee5a6b4c499aab33acddb4324ac01924d33387543eec4d702", "create_category": "6b22b5ce51abf4e225e23a79f81be09a7fb90acb265e93a8faf9446dff74018d", "create_user": "9b73a55233615e461d1f07d99ad1d4d3b54532588ab960097ba3e090c85aaf3a", "edit_category": "b1c0b38f1b714c5d884edcd61e5b5295a5f1c8b71c469b35391e4dcc97cc6d36", - "edit_feed": "34aa0d668b3ea1a1b5fa480c20cebeae729b37010af3bb915d2a9eed73d3b996", + "edit_feed": "cc0b5dbb73f81398410958b41771ed38246bc7ae4bd548228f0d48c49a598c2a", "edit_user": "c692db9de1a084c57b93e95a14b041d39bf489846cbb91fc982a62b72b77062a", "entry": "4258936829a5baf9d5b95d3884add13034105a931ee844ee4c4d3a6f1928f61a", "feed_entries": "9c70b82f55e4b311eff20be1641733612e3c1b406ce8010861e4c417d97b6dcc", - "feeds": "fa06cd1e1e3fec79132386972c640a2fe91237f5dba572389d5f45be74545f25", + "feeds": "ec7d3fa96735bd8422ba69ef0927dcccddc1cc51327e0271f0312d3f881c64fd", "history_entries": "87e17d39de70eb3fdbc4000326283be610928758eae7924e4b08dcb446f3b6a9", - "import": "5eb56cecaa4d369b9acc991a82be7617710c551089a2e99d34ce8b6e5c37df0a", + "import": "1b59b3bd55c59fcbc6fbb346b414dcdd26d1b4e0c307e437bb58b3f92ef01ad1", "integrations": "6104ff6ff3ac3c1ae5e850c78250aab6e99e2342a337589f3848459fa333766a", "login": "2e72d2d4b9786641b696bedbed5e10b04bdfd68254ddbbdb0a53cca621d200c7", "search_entries": "274950d03298c24f3942e209c0faed580a6d57be9cf76a6c236175a7e766ac6a",