I was translating and found 'authority-summary' for translation. Did ```shell $ git grep authority-summary koha-tmpl/intranet-tmpl/prog/en/includes/authorities-search-results.inc: <div class="authority-summary"> koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21authResults.xsl: <xsl:text>authority-summary</xsl:text> koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCauthResults.xsl: <xsl:text>authority-summary</xsl:text> koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCauthResults.xsl: <!-- end div class authority-summary--> koha-tmpl/opac-tmpl/bootstrap/en/includes/authorities-search-results.inc: <div class="authority-summary"> ``` The next one was `authref` but it all follows the same pattern of being a <xsl:text> node.
Created attachment 166643 [details] [review] Bug 36837: Simplify XSLT and aid translatability This patch makes the XSLT contain HTML tags instead of building them from scratch with static attribute values. This made it awkward for translators as CSS classes ended up being extracted for translation purposes. Plus, there's no need to spend CPU cycles on static content generation. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 166647 [details] [review] Bug 36837: Simplify XSLT and aid translatability This patch makes the XSLT contain HTML tags instead of building them from scratch with static attribute values. This made it awkward for translators as CSS classes ended up being extracted for translation purposes. Plus, there's no need to spend CPU cycles on static content generation. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
I see no reason these should have been getting built by the xsl processing.. they're not using variables etc. More than happy with the patch, no regressions found. Going straight for a PQA here.
Created attachment 166649 [details] [review] Bug 36837: (follow-up) UNIMARC case I checked the UNIMARC authResults counterpart file. And it only contained a single case of generated elements like the previous patch. To test: 1. On latest main $ ktd --shell k$ cd misc/translator/po k$ git fetch k$ git reset --hard origin/main k$ cd /kohadevbox/koha k$ gulp po:update --lang es-ES k$ cd misc/translator/po k$ git add -u ; git commit -mWIP --no-verify 2. Apply this patches 3. Run: k$ cd /kohadevbox/koha k$ gulp po:update --lang es-ES k$ cd misc/translator/po k$ git diff => SUCCESS: Notice CSS class names are not translated anymore Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Pushed for 24.05! Well done everyone, thank you!
Pushed to 23.11.x for 23.11.06
Doesn't apply cleanly to 23.05.x, no backport.