fix(core): fixed failing detection of French display language [no changelog]
What changed, and why it matters
This is a tiny UI text-formatting fix. The code that decides whether to put a space before a colon (a French typographic rule) was checking for the wrong language code ('fr' instead of 'fr-FR'). The patch corrects the code so French labels on the Trezor screen get the proper colon spacing. There is no security relevance visible in the commit.
No security action needed. Treat as a normal localization fix.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The change is a one-line string comparison fix in core/src/trezor/ui/layouts/properties.py. The with_colon() helper inserts a non-breaking space before a colon only when translations.get_language() returns ‘fr-FR’. Previously it checked for ‘fr’, which never matched the actual locale identifier, so the French-specific formatting was never applied. This is purely a localization/UI correctness fix.
Changed components
core/src/trezor/ui/layouts/properties.pyInspect captured patch +1 / −1
diff --git a/core/src/trezor/ui/layouts/properties.py b/core/src/trezor/ui/layouts/properties.py
index c923b140..16f0157e 100644
--- a/core/src/trezor/ui/layouts/properties.py
+++ b/core/src/trezor/ui/layouts/properties.py
@@ -42,7 +42,7 @@ def with_colon(
return None
NBSP = "\u00a0"
- separator = f"{NBSP}:" if translations.get_language() == "fr" else ":"
+ separator = f"{NBSP}:" if translations.get_language() == "fr-FR" else ":"
if isinstance(properties, str):
if properties:
return f"{properties}{separator}"
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.