There are three strings that are more or less like this: ``` If set, this will override the global value set in the {preference} preference ``` They are built in a way that splits it into * `If set, this will override the global value set in the` * `preference` At least in spanish, `preference` needs to be put in before `{preference}`: `Si se define, tendrá precedencia sobre el valor global definido en la preferencia de sistema {preference}` So (in the translation) we need to put a space or similar for `preference`. But it turns out this string is reused in many other places, so translating it correctly actually breaks translations in many places. I think (at least) other latin languages will suffer the same. This is terrible and needs to get fixed.
Created attachment 175609 [details] [review] Bug 38727: Improve translatability in categories.tt This makes the strings easier to translated for maintaining them as a whole instead of splitting them Extra: it adds a missing dot for consistency. To test: 1. In the categories edit page, check the 3 'If set...' texts 2. Apply this patch and reload => SUCCESS: No visual change 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
You should escape the result of a translation.
Created attachment 175619 [details] [review] Bug 38727: Improve translatability in categories.tt This makes the strings easier to translated for maintaining them as a whole instead of splitting them Bonus 1: it adds a missing dot for consistency. Bonus 2: makes a string more idiomatic. To test: 1. In the categories edit page, check the 3 'If set...' texts 2. Apply this patch and reload => SUCCESS: No visual change 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(In reply to Jonathan Druart from comment #2) > You should escape the result of a translation. Thanks for pointing me in that direction :-D
Created attachment 176107 [details] [review] Bug 38727: Improve translatability in categories.tt This makes the strings easier to translated for maintaining them as a whole instead of splitting them Bonus 1: it adds a missing dot for consistency. Bonus 2: makes a string more idiomatic. To test: 1. In the categories edit page, check the 3 'If set...' texts 2. Apply this patch and reload => SUCCESS: No visual change 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com>
Still this one is ugly: msgid ", holds placed by patrons of this category will not be given priority." Because of the "If <i>Yes</i>"
Created attachment 176675 [details] [review] Bug 38727: Improve translatability in categories.tt This makes the strings easier to translated for maintaining them as a whole instead of splitting them Bonus 1: it adds a missing dot for consistency. Bonus 2: makes a string more idiomatic. To test: 1. In the categories edit page, check the 3 'If set...' texts 2. Apply this patch and reload => SUCCESS: No visual change 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 176676 [details] [review] Bug 38727: Add missing closing div Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Pushed for 25.05! Well done everyone, thank you!