From 53c8480434e6fed46e8ae9be0800182d45701179 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Fri, 15 Sep 2023 13:46:13 +0000 Subject: [PATCH] Bug 34802: Improve translation of title tags: Tags and comments This patch modifies tag and comments management templates so that title tags can be more easily translated. The patch also makes some modifications to titles, breadcrumb navigation, and page headers in order to make them more consistent with each other and with other similar pages. To test, apply the patch and go to Tools. Test each of the following pages and each variation of the page to confirm that titles, breadcrumbs, and page headers look correct. - Tags - Main page - Viewing tags by status: Approved, pending, and rejected (link in the right-hand column) - List of records by tag - This page has been modified so that the menu of tag link in the left-hand sidebar is styled consistently with other sidebar menus. - Comments - Approved comments - Comments awaiting moderation Signed-off-by: David Nind --- .../prog/en/modules/reviews/reviewswaiting.tt | 12 ++++++- .../prog/en/modules/tags/list.tt | 27 ++++++++------ .../prog/en/modules/tags/review.tt | 36 +++++++++++++++++-- 3 files changed, 61 insertions(+), 14 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reviews/reviewswaiting.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reviews/reviewswaiting.tt index 21d49e4de0..13e06c44cc 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reviews/reviewswaiting.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reviews/reviewswaiting.tt @@ -1,8 +1,18 @@ [% USE raw %] [% USE Asset %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -[% IF ( status ) %]Approved comments[% ELSE %]Comments awaiting moderation[% END %] › Comments › Tools › Koha +[% FILTER collapse %] + [% IF( status ) %] + [% t("Approved comments") | html %] + [% ELSE %] + [% t("Comments awaiting moderation") | html %] + [% END %] › + [% t("Comments") | html %] › + [% t("Tools") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/list.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/list.tt index a2e0ce2f74..b2fb2b521d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/list.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/list.tt @@ -2,9 +2,15 @@ [% USE Asset %] [% USE AuthorisedValues %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -[% IF ( do_it ) %]Review[% ELSE %]Review tags[% END %] › Tags › Tools › Koha +[% FILTER collapse %] + [% tx("Results for tag '{tag}'", { tag = tag }) | html %] › + [% t("Tags") | html %] › + [% t("Tools") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] @@ -24,7 +30,7 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color : Tags [% END %] [% WRAPPER breadcrumb_item bc_active= 1 %] - Results for tag [% tag | html %] + [% tx("Results for tag '{tag}'", { tag = tag }) | html %] [% END %] [% END #/ WRAPPER breadcrumbs %] [% END #/ WRAPPER sub-header.inc %] @@ -34,10 +40,9 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
-

Results for tag [% tag | html %]

+

[% tx("Results for tag '{tag}'", { tag = tag }) | html %]

[% IF ( titles ) %] -

Titles tagged with the term [% tag | html %]

@@ -89,12 +94,14 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt index 7c66bfb024..cfa435a2d9 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt @@ -4,7 +4,18 @@ [% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -[% IF ( do_it ) %]Review[% ELSE %]Review tags[% END %] › Tags › Tools › Koha +[% FILTER collapse %] + [% IF ( filter_approved_ok ) %] + [% t("Approved") | html %] › + [% ELSIF ( filter_approved_pending ) %] + [% t("Pending") | html %] › + [% ELSIF ( filter_approved_rej ) %] + [% t("Rejected") | html %] › + [% END %] + [% t("Tags") | html %] › + [% t("Tools") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %]