Summary: | XSLT CSS classes offered for translations | ||
---|---|---|---|
Product: | Koha | Reporter: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Component: | I18N/L10N | Assignee: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Status: | CLOSED FIXED | QA Contact: | Martin Renvoize (ashimema) <martin.renvoize> |
Severity: | normal | ||
Priority: | P5 - low | CC: | f.demians, fridolin.somers, jonathan.druart, lucas, tomascohen |
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | Trivial patch | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: |
24.05.00,23.11.06
|
Circulation function: | |
Bug Depends on: | 30554 | ||
Bug Blocks: | |||
Attachments: |
Bug 36837: Simplify XSLT and aid translatability
Bug 36837: Simplify XSLT and aid translatability Bug 36837: (follow-up) UNIMARC case |
Description
Tomás Cohen Arazi (tcohen)
2024-05-13 13:09:38 UTC
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. |