Skip to content

Add a HTML sanitizer for translated message resources - #1

Open
linxia0415 wants to merge 1 commit into
mainfrom
pr-37429
Open

Add a HTML sanitizer for translated message resources#1
linxia0415 wants to merge 1 commit into
mainfrom
pr-37429

Conversation

@linxia0415

@linxia0415 linxia0415 commented Jun 3, 2026

Copy link
Copy Markdown

Closes #37428

Summary by CodeRabbit

  • Bug Fixes

    • Standardized WebAuthn error message formatting across all supported languages.
    • Fixed HTML formatting issues in email notification templates.
    • Corrected placeholder syntax and malformed HTML markup in localized messages.
  • Improvements

    • Enhanced message validation with HTML safety checks.
    • Improved pluralization logic for validation error messages.
    • Simplified TOTP authenticator setup instructions in multiple languages.

Closes #37428

Signed-off-by: Alexander Schwartz <alexander.schwartz@gmx.net>
@coderabbitai

coderabbitai Bot commented Jun 3, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

This pull request implements HTML safety verification for Keycloak localization messages, updates message formatting patterns across theme files, modernizes TOTP setup instructions, and corrects email template HTML across 50+ localization files. The core feature adds OWASP-based HTML sanitization to validate translated content.

Changes

Keycloak Theme Localization & HTML Safety Verification

Layer / File(s) Summary
HTML Safety Verification System
misc/theme-verifier/pom.xml, misc/theme-verifier/src/main/java/org/keycloak/themeverifier/VerifyMessageProperties.java, misc/theme-verifier/src/test/java/org/keycloak/themeverifier/VerifyMessagePropertiesTest.java, misc/theme-verifier/src/test/resources/*
New Maven dependencies for OWASP HTML sanitizer and Apache Commons Text. Core verifySafeHtml() method with policy-based sanitization, HTML normalization, anchor-tag constraint validation, and special handling for email paths. Test updates and four new fixture files validate detection of illegal HTML tags, prohibited HTML, and mismatched anchors.
ICU Pluralization Message Updates
js/apps/account-ui/maven-resources/theme/keycloak.v3/account/messages/messages_en.properties, js/apps/admin-ui/maven-resources/theme/keycloak.v2/admin/messages/messages_en.properties, themes/src/main/resources/theme/base/admin/messages/messages_en.properties, themes/src/main/resources/theme/base/login/messages/messages_en.properties, themes/src/main/resources-community/theme/base/login/messages/messages_sk.properties
Replace fixed value(s) suffix in error-invalid-multivalued-size messages with ICU choice expressions ({2,choice,...}) to render singular/plural forms based on value count.
TOTP Setup Instruction Modernization
themes/src/main/resources-community/theme/base/account/messages/messages_*.properties, themes/src/main/resources-community/theme/base/login/messages/messages_*.properties
Update totpStep1 and loginTotpStep1 messages across Finnish, Lithuanian, Slovak, Swedish, and Chinese (account), plus Lithuanian, Norwegian, Slovak, and Swedish (login) with generic authenticator app installation instructions; remove app-specific links to FreeOTP/Google Authenticator. Slovak file also corrects impersonateTitleHtml by removing stray HTML closing tag.
WebAuthn Error Message HTML Normalization
themes/src/main/resources-community/theme/base/login/messages/messages_{ar,ca,cs,de,el,es,fa,fi,fr,hr,ka,ko,lt,sk,th,tr,uk,zh_CN,zh_TW}.properties, themes/src/main/resources/theme/base/login/messages/messages_en.properties
Standardize HTML line-break markup from <br/> to <br /> (space before self-closing slash) in webauthn-error-registration, webauthn-error-api-get, webauthn-error-auth-verification, and webauthn-error-register-verification messages across 20 languages.
Email Template HTML Corrections
js/apps/admin-ui/maven-resources-community/theme/keycloak.v2/admin/messages/messages_zh_CN.properties, themes/src/main/resources-community/theme/base/email/messages/messages_{da,fa,hu,lt,nl,no,tr,uk}.properties
Fix malformed HTML in email templates: correct anchor tag syntax (<a href="{...}">...</a>), fix placeholder usage, adjust bold tag formatting, close unclosed paragraphs, normalize HTML entity escaping, and remove RTL style attributes. Also remove extra space in admin Chinese template placeholder.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 HTML safety hops with care,

OWASP policies pass with flair,

Locales now speak with choice sublime,

From <br/> to <br /> — format in time!

Safe emails bloom in every land,

Translation tested, hand in hand! 🌍

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 8.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ❓ Inconclusive The description is minimal but does reference the related issue (#37428). However, it lacks detailed explanation of what the change does, why it's necessary, and how it works. Expand the description to explain the purpose of the HTML sanitizer, what security concerns it addresses, and provide context about the changes made to the theme-verifier tool.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: adding HTML sanitization for translated message resources, which is the core functionality introduced in the PR.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch pr-37429

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 8

🧹 Nitpick comments (1)
misc/theme-verifier/pom.xml (1)

75-79: ⚡ Quick win

Use the repo-managed sanitizer version property instead of a literal version.

This module currently hardcodes the OWASP sanitizer version while the root build already centralizes it, which can drift over time.

Suggested diff
         <dependency>
             <groupId>com.googlecode.owasp-java-html-sanitizer</groupId>
             <artifactId>owasp-java-html-sanitizer</artifactId>
-            <version>20240325.1</version>
+            <version>${owasp.html.sanitizer.version}</version>
         </dependency>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@misc/theme-verifier/pom.xml` around lines 75 - 79, Replace the hardcoded
version for the
com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer dependency
with the repository-managed Maven property used in the parent POM (i.e., change
the <version>20240325.1</version> to the centralized property reference like
${owasp-java-html-sanitizer.version} or the repo's canonical property name);
update the dependency declaration around the artifactId
"owasp-java-html-sanitizer" so it inherits the version from the parent instead
of using the literal value.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@misc/theme-verifier/src/main/java/org/keycloak/themeverifier/VerifyMessageProperties.java`:
- Around line 65-80: The verifySafeHtml() method currently throws
RuntimeException when FileInputStream reading fails for the primary file and the
englishFile; update it to follow the same checked-error contract as verify() by
changing the method signature to throw MojoExecutionException and replace the
two RuntimeException throws in the catch blocks with new
MojoExecutionException(...) that include the same descriptive message and pass
the caught IOException as the cause; ensure you reference the local variables
file and englishFile in the new exception messages so logs remain informative.

In `@misc/theme-verifier/src/test/resources/illegalHtmlTag_en.properties`:
- Line 17: The fixture currently uses a malformed closing tag ("</div") which
tests syntax errors rather than the disallowed <div> element; update the
property value for the resource key (the line starting with "key=") to use a
properly closed disallowed tag, e.g. change `Some <div>tag</div` to `Some
<div>tag</div>`, so the test explicitly targets the disallowed <div> element.

In
`@themes/src/main/resources-community/theme/base/account/messages/messages_lt.properties`:
- Line 101: The value for key totpStep1 currently contains Italian text; replace
it with the correct Lithuanian string for the TOTP installation instruction
(e.g., "Įdiekite vieną iš šių programėlių savo telefone:") by updating the
totpStep1 property so it matches the surrounding Lithuanian localization and
preserves encoding/escaping conventions used in messages_lt.properties.

In
`@themes/src/main/resources-community/theme/base/account/messages/messages_zh_CN.properties`:
- Line 112: The value for the localization key totpStep1 contains Traditional
Chinese characters; update the string to use Simplified Chinese equivalents
(replace 手機→手机, 安裝→安装, 應用程式→应用程序) so the messages_zh_CN.properties entry for
totpStep1 is written in Simplified Chinese.

In
`@themes/src/main/resources-community/theme/base/email/messages/messages_da.properties`:
- Line 9: The value for the identityProviderLinkBodyHtml property contains a
stray 'n' at the start of the fourth paragraph ("<p>nHvis..."); edit the
identityProviderLinkBodyHtml string to remove that stray 'n' so the paragraph
reads "<p>Hvis du ikke vil forbinde...</p>", preserving surrounding HTML and
placeholders ({0},{1},{2},{3},{5}).

In
`@themes/src/main/resources-community/theme/base/email/messages/messages_lt.properties`:
- Line 6: The localization value for identityProviderLinkBodyHtml contains a
typo at the start ("žas pageidauja"); update the message string for
identityProviderLinkBodyHtml to begin with the correct word (e.g., "Kažkas
pageidauja...") so the sentence is complete and natural in Lithuanian; ensure
you only change the beginning word and preserve all placeholders
({0},{1},{2},{3},{4}) and HTML structure unchanged.
- Line 3: Fix the stray character in the Lithuanian email template value for the
key emailVerificationBodyHtml: remove the leading "n" before "Jei" so the
paragraph reads "<p>Jei paskyros nekūrėte, tuomet ignoruokite šį laišką.</p>"
(update the messages_lt.properties entry for emailVerificationBodyHtml
accordingly) and run a quick search of the same key to ensure no other
accidental characters exist in the translation string.

In
`@themes/src/main/resources-community/theme/base/login/messages/messages_lt.properties`:
- Line 71: The value for key loginTotpStep1 is in Italian; update the
messages_lt.properties entry for loginTotpStep1 to the correct Lithuanian
translation (e.g., "Įdiekite vieną iš šių programėlių savo telefone:") so it
matches the surrounding Lithuanian localization and preserves the same message
intent.

---

Nitpick comments:
In `@misc/theme-verifier/pom.xml`:
- Around line 75-79: Replace the hardcoded version for the
com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer dependency
with the repository-managed Maven property used in the parent POM (i.e., change
the <version>20240325.1</version> to the centralized property reference like
${owasp-java-html-sanitizer.version} or the repo's canonical property name);
update the dependency declaration around the artifactId
"owasp-java-html-sanitizer" so it inherits the version from the parent instead
of using the literal value.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: e6e13d5a-2e23-4427-b4c3-8e8a83845c1b

📥 Commits

Reviewing files that changed from the base of the PR and between 1c47add and 02f48f7.

📒 Files selected for processing (48)
  • js/apps/account-ui/maven-resources/theme/keycloak.v3/account/messages/messages_en.properties
  • js/apps/admin-ui/maven-resources-community/theme/keycloak.v2/admin/messages/messages_zh_CN.properties
  • js/apps/admin-ui/maven-resources/theme/keycloak.v2/admin/messages/messages_en.properties
  • misc/theme-verifier/pom.xml
  • misc/theme-verifier/src/main/java/org/keycloak/themeverifier/VerifyMessageProperties.java
  • misc/theme-verifier/src/test/java/org/keycloak/themeverifier/VerifyMessagePropertiesTest.java
  • misc/theme-verifier/src/test/resources/changedAnchor_de.properties
  • misc/theme-verifier/src/test/resources/changedAnchor_en.properties
  • misc/theme-verifier/src/test/resources/duplicateKeys_en.properties
  • misc/theme-verifier/src/test/resources/illegalHtmlTag_en.properties
  • misc/theme-verifier/src/test/resources/noHtml_de.properties
  • misc/theme-verifier/src/test/resources/noHtml_en.properties
  • themes/src/main/resources-community/theme/base/account/messages/messages_fi.properties
  • themes/src/main/resources-community/theme/base/account/messages/messages_lt.properties
  • themes/src/main/resources-community/theme/base/account/messages/messages_sk.properties
  • themes/src/main/resources-community/theme/base/account/messages/messages_sv.properties
  • themes/src/main/resources-community/theme/base/account/messages/messages_zh_CN.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_da.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_fa.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_hu.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_lt.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_nl.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_no.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_tr.properties
  • themes/src/main/resources-community/theme/base/email/messages/messages_uk.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_ar.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_ca.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_cs.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_de.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_el.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_es.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_fa.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_fi.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_fr.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_hr.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_ka.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_ko.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_lt.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_no.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_sk.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_sv.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_th.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_tr.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_uk.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_zh_CN.properties
  • themes/src/main/resources-community/theme/base/login/messages/messages_zh_TW.properties
  • themes/src/main/resources/theme/base/admin/messages/messages_en.properties
  • themes/src/main/resources/theme/base/login/messages/messages_en.properties

Comment on lines +65 to +80
private void verifySafeHtml() {
PropertyResourceBundle bundle;
try (FileInputStream fis = new FileInputStream(file)) {
bundle = new PropertyResourceBundle(fis);
} catch (IOException e) {
throw new RuntimeException("unable to read file " + file, e);
}

PropertyResourceBundle bundleEnglish;
String englishFile = file.getAbsolutePath().replaceAll("resources-community", "resources")
.replaceAll("_[a-zA-Z-_]*\\.properties", "_en.properties");
try (FileInputStream fis = new FileInputStream(englishFile)) {
bundleEnglish = new PropertyResourceBundle(fis);
} catch (IOException e) {
throw new RuntimeException("unable to read file " + englishFile, e);
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Keep error handling consistent with verify()’s MojoExecutionException contract.

verifySafeHtml() throws RuntimeException for file-read failures (Line 70, Line 79), which bypasses the plugin’s checked error flow and returns inconsistent build failures.

Suggested diff
-    private void verifySafeHtml() {
+    private void verifySafeHtml() throws IOException {
         PropertyResourceBundle bundle;
-        try (FileInputStream fis = new FileInputStream(file)) {
-            bundle = new PropertyResourceBundle(fis);
-        } catch (IOException e) {
-            throw new RuntimeException("unable to read file " + file, e);
-        }
+        try (FileInputStream fis = new FileInputStream(file)) {
+            bundle = new PropertyResourceBundle(fis);
+        }

         PropertyResourceBundle bundleEnglish;
         String englishFile = file.getAbsolutePath().replaceAll("resources-community", "resources")
                 .replaceAll("_[a-zA-Z-_]*\\.properties", "_en.properties");
-        try (FileInputStream fis = new FileInputStream(englishFile)) {
-            bundleEnglish = new PropertyResourceBundle(fis);
-        } catch (IOException e) {
-            throw new RuntimeException("unable to read file " + englishFile, e);
-        }
+        try (FileInputStream fis = new FileInputStream(englishFile)) {
+            bundleEnglish = new PropertyResourceBundle(fis);
+        }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@misc/theme-verifier/src/main/java/org/keycloak/themeverifier/VerifyMessageProperties.java`
around lines 65 - 80, The verifySafeHtml() method currently throws
RuntimeException when FileInputStream reading fails for the primary file and the
englishFile; update it to follow the same checked-error contract as verify() by
changing the method signature to throw MojoExecutionException and replace the
two RuntimeException throws in the catch blocks with new
MojoExecutionException(...) that include the same descriptive message and pass
the caught IOException as the cause; ensure you reference the local variables
file and englishFile in the new exception messages so logs remain informative.

# See the License for the specific language governing permissions and
# limitations under the License.
#
key=Some <div>tag</div No newline at end of file

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Make the fixture explicitly test a disallowed tag, not malformed syntax.

Using </div (missing >) makes this case ambiguous. If the goal is “disallowed <div>”, close the tag properly for a clearer and more stable assertion target.

Suggested diff
-key=Some <div>tag</div
+key=Some <div>tag</div>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
key=Some <div>tag</div
key=Some <div>tag</div>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@misc/theme-verifier/src/test/resources/illegalHtmlTag_en.properties` at line
17, The fixture currently uses a malformed closing tag ("</div") which tests
syntax errors rather than the disallowed <div> element; update the property
value for the resource key (the line starting with "key=") to use a properly
closed disallowed tag, e.g. change `Some <div>tag</div` to `Some
<div>tag</div>`, so the test explicitly targets the disallowed <div> element.

configureAuthenticators=Sukonfigūruotas autentifikatorius
mobile=Mobilus
totpStep1=Įdiekite <a href="https://freeotp.github.io/" target="_blank">FreeOTP</a> arba Google Authenticator savo įrenginyje. Programėlės prieinamos <a href="https://play.google.com">Google Play</a> ir Apple App Store.
totpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Critical: Wrong language used in Lithuanian localization.

The totpStep1 value contains Italian text ("Installa una delle seguenti applicazioni sul tuo cellulare:") instead of Lithuanian. This file is messages_lt.properties and all surrounding messages are in Lithuanian.

🌐 Proposed fix with correct Lithuanian translation
-totpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:
+totpStep1=Įdiekite vieną iš šių programėlių savo mobiliajame telefone:
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
totpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:
totpStep1=Įdiekite vieną iš šių programėlių savo mobiliajame telefone:
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/account/messages/messages_lt.properties`
at line 101, The value for key totpStep1 currently contains Italian text;
replace it with the correct Lithuanian string for the TOTP installation
instruction (e.g., "Įdiekite vieną iš šių programėlių savo telefone:") by
updating the totpStep1 property so it matches the surrounding Lithuanian
localization and preserves encoding/escaping conventions used in
messages_lt.properties.

configureAuthenticators=配置的认证者
mobile=手机
totpStep1=在你的设备上安装 <a href="https://fedorahosted.org/freeotp/" target="_blank">FreeOTP</a> 或者 Google Authenticator.两个应用可以从 <a href="https://play.google.com">Google Play</a> 和 Apple App Store下载。
totpStep1=在您的手機上安裝以下應用程式之一:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Critical: Traditional Chinese characters used in Simplified Chinese file.

The totpStep1 value uses Traditional Chinese characters (手機, 應用程式, 安裝) in a Simplified Chinese file (messages_zh_CN.properties). The file should use Simplified Chinese characters.

🌐 Proposed fix with Simplified Chinese characters
-totpStep1=在您的手機上安裝以下應用程式之一:
+totpStep1=在您的手机上安装以下应用程序之一:

Note: Changed 手機→手机, 安裝→安装, 應用程式→应用程序

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
totpStep1=在您的手機上安裝以下應用程式之一
totpStep1=在您的手机上安装以下应用程序之一
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/account/messages/messages_zh_CN.properties`
at line 112, The value for the localization key totpStep1 contains Traditional
Chinese characters; update the string to use Simplified Chinese equivalents
(replace 手機→手机, 安裝→安装, 應用程式→应用程序) so the messages_zh_CN.properties entry for
totpStep1 is written in Simplified Chinese.

identityProviderLinkSubject=Link {0}
identityProviderLinkBody=Nogen vil forbinde din "{1}" konto med "{0}" kontoen som er tilknyttet brugeren {2}. Hvis dette var dig, bedes du klikke på forbindet herunder for at forbinde de to konti\n\n{3}\n\nDette link vil udløbe efter {5}.\n\nHvis du ikke vil forbinde disse konti, kan du bare ignore denne besked. Hvis du vælger at forbinde de to konti, kan du logge ind som {1} via {0}.
identityProviderLinkBodyHtml=<p>Nogen vil forbinde din <b>{1}</b> konto med <b>{0}</b> kontoen som er tilknyttet brugeren {2}. Hvis dette var dig, bedes du klikke på forbindet herunder for at forbinde de to konti</p><p><a href="{3}">Bekræft</a></p><p>Dette link vil udløbe efter {5}.</p><p>nHvis du ikke vil forbinde disse konti, kan du bare ignore denne besked. Hvis du vælger at forbinde de to konti, kan du logge ind som {1} via {0}.
identityProviderLinkBodyHtml=<p>Nogen vil forbinde din <b>{1}</b> konto med <b>{0}</b> kontoen som er tilknyttet brugeren {2}. Hvis dette var dig, bedes du klikke på forbindet herunder for at forbinde de to konti</p><p><a href="{3}">Bekræft</a></p><p>Dette link vil udløbe efter {5}.</p><p>nHvis du ikke vil forbinde disse konti, kan du bare ignore denne besked. Hvis du vælger at forbinde de to konti, kan du logge ind som {1} via {0}.</p>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Possible typo: stray 'n' character in HTML content.

The HTML contains <p>nHvis du ikke vil forbinde... where the 'n' prefix before "Hvis" appears to be a typo. This should likely be <p>Hvis du ikke vil forbinde... (without the leading 'n').

Suggested fix
-identityProviderLinkBodyHtml=<p>Nogen vil forbinde din <b>{1}</b> konto med <b>{0}</b> kontoen som er tilknyttet brugeren {2}. Hvis dette var dig, bedes du klikke på forbindet herunder for at forbinde de to konti</p><p><a href="{3}">Bekræft</a></p><p>Dette link vil udløbe efter {5}.</p><p>nHvis du ikke vil forbinde disse konti, kan du bare ignore denne besked. Hvis du vælger at forbinde de to konti, kan du logge ind som {1} via {0}.</p>
+identityProviderLinkBodyHtml=<p>Nogen vil forbinde din <b>{1}</b> konto med <b>{0}</b> kontoen som er tilknyttet brugeren {2}. Hvis dette var dig, bedes du klikke på forbindet herunder for at forbinde de to konti</p><p><a href="{3}">Bekræft</a></p><p>Dette link vil udløbe efter {5}.</p><p>Hvis du ikke vil forbinde disse konti, kan du bare ignore denne besked. Hvis du vælger at forbinde de to konti, kan du logge ind som {1} via {0}.</p>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/email/messages/messages_da.properties`
at line 9, The value for the identityProviderLinkBodyHtml property contains a
stray 'n' at the start of the fourth paragraph ("<p>nHvis..."); edit the
identityProviderLinkBodyHtml string to remove that stray 'n' so the paragraph
reads "<p>Hvis du ikke vil forbinde...</p>", preserving surrounding HTML and
placeholders ({0},{1},{2},{3},{5}).

emailVerificationSubject=El. pašto patvirtinimas
emailVerificationBody=Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą\n\n{0}\n\nŠi nuoroda galioja {1} min.\n\nJei paskyros nekūrėte, tuomet ignuoruokite šį laišką.
emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tao buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href=LT"{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>nJei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>
emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tao buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href="{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>nJei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Possible typo: stray 'n' character in HTML content.

The HTML contains <p>nJei paskyros nekūrėte... where the 'n' prefix before "Jei" appears to be a typo. This should likely be <p>Jei paskyros nekūrėte... (without the leading 'n').

Suggested fix
-emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tao buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href="{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>nJei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>
+emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href="{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>Jei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tao buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href="{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>nJei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>
emailVerificationBodyHtml=<p>Paskyra {2} sukurta naudojant šį el. pašto adresą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą</p><p><a href="{0}">{0}</a></p><p>Ši nuoroda galioja {1} min.</p><p>Jei paskyros nekūrėte, tuomet ignuoruokite šį laišką.</p>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/email/messages/messages_lt.properties`
at line 3, Fix the stray character in the Lithuanian email template value for
the key emailVerificationBodyHtml: remove the leading "n" before "Jei" so the
paragraph reads "<p>Jei paskyros nekūrėte, tuomet ignoruokite šį laišką.</p>"
(update the messages_lt.properties entry for emailVerificationBodyHtml
accordingly) and run a quick search of the same key to ensure no other
accidental characters exist in the translation string.

identityProviderLinkSubject=Sąsaja {0}
identityProviderLinkBody=Kažas pageidauja susieti Jūsų "{1}" paskyrą su "{0}" {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras\n\n{3}\n\nŠi nuoroda galioja {4} min.\n\nJei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.
identityProviderLinkBodyHtml=<p>žas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href=LT"{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>
identityProviderLinkBodyHtml=<p>žas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href="{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Possible typo: missing characters at beginning of sentence.

The HTML starts with žas pageidauja which appears to be missing the beginning of the word. This should likely be Kažkas pageidauja (meaning "Someone wants").

Suggested fix
-identityProviderLinkBodyHtml=<p>žas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href="{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>
+identityProviderLinkBodyHtml=<p>Kažkas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href="{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
identityProviderLinkBodyHtml=<p>žas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href="{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>
identityProviderLinkBodyHtml=<p>Kažkas pageidauja susieti Jūsų <b>{1}</b> paskyrą su <b>{0}</b> {2} naudotojo paskyrą. Jei tai buvote Jūs, tuomet paspauskite žemiau esančią nuorodą norėdami susieti paskyras</p><p><a href="{3}">{3}</a></p><p>Ši nuoroda galioja {4} min.</p><p>Jei paskyrų susieti nenorite, tuomet ignoruokite šį laišką. Jei paskyras susiesite, tuomet prie {1} galėsiste prisijungti per {0}.</p>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/email/messages/messages_lt.properties`
at line 6, The localization value for identityProviderLinkBodyHtml contains a
typo at the start ("žas pageidauja"); update the message string for
identityProviderLinkBodyHtml to begin with the correct word (e.g., "Kažkas
pageidauja...") so the sentence is complete and natural in Lithuanian; ensure
you only change the beginning word and preserve all placeholders
({0},{1},{2},{3},{4}) and HTML structure unchanged.

gssDelegationCredential=GSS prisijungimo duomenų delegavimas

loginTotpStep1=Įdiekite <a href="https://freeotp.github.io/" target="_blank">FreeOTP</a> arba Google Authenticator savo įrenginyje. Programėlės prieinamos <a href="https://play.google.com">Google Play</a> ir Apple App Store.
loginTotpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Critical: Wrong language used in Lithuanian localization.

The loginTotpStep1 value contains Italian text ("Installa una delle seguenti applicazioni sul tuo cellulare:") instead of Lithuanian. This file is messages_lt.properties and all surrounding messages are in Lithuanian.

🌐 Proposed fix with correct Lithuanian translation
-loginTotpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:
+loginTotpStep1=Įdiekite vieną iš šių programėlių savo mobiliajame telefone:
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
loginTotpStep1=Installa una delle seguenti applicazioni sul tuo cellulare:
loginTotpStep1=Įdiekite vieną iš šių programėlių savo mobiliajame telefone:
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@themes/src/main/resources-community/theme/base/login/messages/messages_lt.properties`
at line 71, The value for key loginTotpStep1 is in Italian; update the
messages_lt.properties entry for loginTotpStep1 to the correct Lithuanian
translation (e.g., "Įdiekite vieną iš šių programėlių savo telefone:") so it
matches the surrounding Lithuanian localization and preserves the same message
intent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants