Skip to content

Conversation

@tdonohue
Copy link
Member

@tdonohue tdonohue commented Nov 8, 2024

References

Description

After upgrading to Klaro 0.7.19 (or later), our custom message translations are no longer loading into Klaro. This can be seen on both https://sandbox.dspace.org and https://demo.dspace.org because the Klaro Cookie pop-up shows the default Klaro text like this:
klaro-text

The main issue is that the Klaro 'zz' "default translations" no longer seem to work. The reason is because Klaro only uses the zz translations if no other languages can be found, and (as of 0.7.19) the klaro-no-translations package is wrongly including all the translations (see kiprotect/klaro#515). So, there's no longer a way to tell Klaro to not include translations and therefore to only use the zz language code.

This PR fixes the issue by changing our Klaro configuration to force Klaro to always use a (different, fake) language code of zy. In our Klaro configuration, we then use our i18n keys for the zy language, and translate it to the user's language as we did before.

Instructions for Reviewers

  • Verify the Klaro cookie popup works as before. It's easiest to verify by opening the homepage in an Incognito window.

This bug does NOT impact 7.6.2 or 8.0 (as they both used Klaro 0.7.18). However, it does impact main, dspace-8_x and dspace-7_x as they all now use Klaro 0.7.21 (and this Klaro bug began with 0.7.19).

@tdonohue tdonohue added bug 1 APPROVAL pull request only requires a single approval to merge port to dspace-7_x This PR needs to be ported to `dspace-7_x` branch for next bug-fix release labels Nov 8, 2024
@tdonohue tdonohue added this to the 8.1 milestone Nov 8, 2024
@tdonohue
Copy link
Member Author

tdonohue commented Nov 8, 2024

NOTE: This does NOT require porting to main as that branch now uses Orejime (and this bug doesn't exist in that library). See #3199

@tdonohue
Copy link
Member Author

tdonohue commented Nov 8, 2024

This was previously approved in #3586 (comment) So, once this passes tests, it can be merged & ported to dspace-7_x

@tdonohue tdonohue linked an issue Nov 8, 2024 that may be closed by this pull request
@tdonohue tdonohue merged commit 9add368 into DSpace:dspace-8_x Nov 8, 2024
@dspace-bot
Copy link
Contributor

@tdonohue tdonohue removed the port to dspace-7_x This PR needs to be ported to `dspace-7_x` branch for next bug-fix release label Nov 8, 2024
4science-it pushed a commit to 4Science/dspace-angular that referenced this pull request Dec 16, 2025
[DSC-2529] allow space in email pattern + trim on submit

Approved-by: Andrea Barbasso
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1 APPROVAL pull request only requires a single approval to merge bug

Projects

Development

Successfully merging this pull request may close these issues.

Cookie dialog has a strange text in current DSpace 8.1 Snapshot

2 participants