Bug 33912 - Improve translation of title tags: Cataloging
Summary: Improve translation of title tags: Cataloging
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 33906
  Show dependency treegraph
 
Reported: 2023-06-06 15:53 UTC by Owen Leonard
Modified: 2024-07-04 20:37 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Medium patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00
Circulation function:


Attachments
Bug 33912: Improve translation of title tags: Cataloging (79.91 KB, patch)
2023-06-12 19:27 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 33912: Improve translation of title tags: Cataloging (79.96 KB, patch)
2023-06-23 19:43 UTC, Phil Ringnalda
Details | Diff | Splinter Review
Bug 33912: (follow-up) Correct case where a search has not been submited (1.27 KB, patch)
2023-07-07 12:39 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 33912: Improve translation of title tags: Cataloging (80.21 KB, patch)
2023-09-01 09:32 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 33912: (follow-up) Correct case where a search has not been submited (1.35 KB, patch)
2023-09-01 09:32 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2023-06-06 15:53:53 UTC
This patch will modify cataloging templates in the staff client so that translatable strings in the <title> tag are wrapped in the correct translation function, e.g. [% t('Translate me') %]
Comment 1 Owen Leonard 2023-06-12 19:27:00 UTC
Created attachment 152284 [details] [review]
Bug 33912: Improve translation of title tags: Cataloging

This patch updates cataloging templates, including cataloging "value
builder" plugins, so that title tags can be more easily translated.

To test, apply the patch and confirm that the following cataloging
pages have the correct title tags:

- Cataloging home page
- Catalog concerns
- Cataloging search results
  - Select two results ->
    - Merge selected
- Basic MARC editor (Add, edit)
  - Replace via Z39.50
- Advanced MARC editor
- Item editor
- Bibliographic detail page ->
  - Edit ->
    - Attach item
  - Edit ->
    - Link to host record (with EasyAnalytics enabled)
- Authorities -> New from Z39.50/SRU

The patch updates 81 different cataloging plugins. It's not necessary to
configure your MARC framework to use any particular plugin. The plugins
can be loaded in their own tab for the purpose of testing just the
title. I've made a list of direct links here:

https://gitlab.com/-/snippets/2555254
Comment 2 Phil Ringnalda 2023-06-23 19:08:47 UTC
Will this affect the way they are presented to translators?

I verified that the unimarc plugins still have the same title they had before, but in a great many instances that title is completely wrong. Right now, in https://git.koha-community.org/Koha-community/Koha/src/commit/88000fbccbcfe707ee3d8bf72f549c1ac11be3f3/misc/translator/po/de-DE-marc-UNIMARC.po#L2496 translators apparently deal with the thirteen bogus plugins that all use the title "Framework plugin example &rsaquo; Cataloguing &rsaquo; Koha" with one translation, but if doing this will require that they translate it thirteen separate times, then this bug ought to depend on one for fixing those titles (and another for fixing the way that we have templates for unimarc_field_123d.tt, unimarc_field_123e.tt, unimarc_field_123f.tt, and unimarc_field_123g.tt, but the plugins for all four just use the unimarc_field_123g.tt template so the strings for d/e/f are unused).
Comment 3 Katrin Fischer 2023-06-23 19:23:05 UTC
Identical strings are still "grouped" into one translation, there should be no negative effects. What it will do is breaking things into individual strings, so "Koha" "Cataloguing" and the specific page descriptions are different strings. This will actually reduce the amount of typing/work needed.
Comment 4 Phil Ringnalda 2023-06-23 19:43:52 UTC
Created attachment 152653 [details] [review]
Bug 33912: Improve translation of title tags: Cataloging

This patch updates cataloging templates, including cataloging "value
builder" plugins, so that title tags can be more easily translated.

To test, apply the patch and confirm that the following cataloging
pages have the correct title tags:

- Cataloging home page
- Catalog concerns
- Cataloging search results
  - Select two results ->
    - Merge selected
- Basic MARC editor (Add, edit)
  - Replace via Z39.50
- Advanced MARC editor
- Item editor
- Bibliographic detail page ->
  - Edit ->
    - Attach item
  - Edit ->
    - Link to host record (with EasyAnalytics enabled)
- Authorities -> New from Z39.50/SRU

The patch updates 81 different cataloging plugins. It's not necessary to
configure your MARC framework to use any particular plugin. The plugins
can be loaded in their own tab for the purpose of testing just the
title. I've made a list of direct links here:

https://gitlab.com/-/snippets/2555254
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Comment 5 Jonathan Druart 2023-07-07 06:59:15 UTC
On /cataloguing/addbooks.pl there is an extra '>' at the beginning of the title.
Comment 6 Owen Leonard 2023-07-07 12:39:15 UTC
Created attachment 153173 [details] [review]
Bug 33912: (follow-up) Correct case where a search has not been submited

The former cataloging home page, addbooks.pl, shows an extra ">" in the
title if a search has not been submitted. This patch corrects it.
Comment 7 Jonathan Druart 2023-09-01 09:32:10 UTC
You have added [% USE raw %] when it was not needed, but not blocker.
Comment 8 Jonathan Druart 2023-09-01 09:32:56 UTC
Created attachment 155083 [details] [review]
Bug 33912: Improve translation of title tags: Cataloging

This patch updates cataloging templates, including cataloging "value
builder" plugins, so that title tags can be more easily translated.

To test, apply the patch and confirm that the following cataloging
pages have the correct title tags:

- Cataloging home page
- Catalog concerns
- Cataloging search results
  - Select two results ->
    - Merge selected
- Basic MARC editor (Add, edit)
  - Replace via Z39.50
- Advanced MARC editor
- Item editor
- Bibliographic detail page ->
  - Edit ->
    - Attach item
  - Edit ->
    - Link to host record (with EasyAnalytics enabled)
- Authorities -> New from Z39.50/SRU

The patch updates 81 different cataloging plugins. It's not necessary to
configure your MARC framework to use any particular plugin. The plugins
can be loaded in their own tab for the purpose of testing just the
title. I've made a list of direct links here:

https://gitlab.com/-/snippets/2555254
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 9 Jonathan Druart 2023-09-01 09:32:58 UTC
Created attachment 155084 [details] [review]
Bug 33912: (follow-up) Correct case where a search has not been submited

The former cataloging home page, addbooks.pl, shows an extra ">" in the
title if a search has not been submitted. This patch corrects it.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 10 Tomás Cohen Arazi (tcohen) 2023-09-01 14:10:23 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 11 Fridolin Somers 2023-09-08 05:47:53 UTC
Not backported to 23.05.x