Repository navigation
Conversation
Settings still rendered about 90 English literals from SettingsScreen.kt, SettingsLogic.kt and SettingsComponents.kt regardless of locale: card blurbs, button labels, toggle details, toasts, screen-reader text, the strap status pill and detail, the sex options and the "Settings" overline. They now resolve through string resources: 96 new keys, translated into all nine locales, and 14 literals reuse existing keys with identical English. strapStatusTitle/strapStatusDetail become strapStatusTitleRes/ strapStatusDetailRes returning @stringres, following spo2MissingCaptionRes, so the branches stay testable on the JVM; StrapStatusDetailTest keeps its wording checks by reading the English values from values/strings.xml. Left in English on purpose: the "NOOP" wordmark, the support email subject, and four strings inside the 5/MG card that is compiled out (if (false && ...)). The Android i18n baseline drops the 26 SettingsScreen.kt entries this extracts.
…nglish The Tanaka caption was left as 'Auto · %1$s bpm (Tanaka)' in de, es, fr, it, pl and pt-PT, which the i18n echo ratchet counts as untranslated. Spell the word out in each locale, agreeing with the heart-rate noun it qualifies.
paradix86
force-pushed
the
i18n/android-hardcoded-settings
branch
from
September 30, 2026 06:09
297cfb1 to
38d9ffd
Compare
5 of 12 tasks
This was referenced Oct 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Android Settings screen still showed about 90 English literals whatever the phone's language: card blurbs, button labels, toggle details, toasts, screen-reader text, the strap status pill and detail, the sex options, and the "SETTINGS" overline on every card. On an Italian phone, for example, the Profile card read "These power your heart-rate zones…", "Choose photo" and "Male / Female / Non-binary".
This PR moves them into string resources:
Scope is the Settings screen only:
SettingsScreen.kt,SettingsLogic.kt,SettingsComponents.kt. Other screens will follow as separate PRs, one concern each.Notes
strapStatusTitle/strapStatusDetailbecomestrapStatusTitleRes/strapStatusDetailRes, returning@StringRes, followingspo2MissingCaptionRes.uiStringneeds the Application, so returning text would make the branches untestable on the JVM.StrapStatusDetailTestkeeps every wording assertion by resolving each id to its English value invalues/strings.xml. It fails rather than skips if that file cannot be found.SexOptioncarries alabelResin place of alabel.Age, %1$s years,Step calibration, %1$.1f counter ticks per step. The HRV-window toast became two whole sentences instead of splicing "deep-sleep" / "whole-night" into English.if (false && showFiveMGControls)).Tools/i18n_audit_baseline.jsondrops the 26SettingsScreen.ktentries this extracts. It was edited narrowly rather than via--update-baseline, which on a Windows checkout would rewrite path separators and touch unrelated entries.Out of scope, noticed along the way
PaletteTokens.ktand are still English.Verification
Tools/i18n_audit.py --ci origin/main: Android OK. No new hardcoded literals; the tool counts 213 on main and 188 here. Every focus locale is complete.Tools/doc_comment_lint.py: OK.testFullDebugUnitTest: 6464 tests,StrapStatusDetailTest4/4. The 9 failures are Windows-host-only (CRLF / file-lock) inGlowRingFlatArcTest,StrapLogArchiveTestandWhoopDatabaseUpgradeTest; none touches this change.Related
Refs #2493 (Android: use profile weight from Health Connect). Both PRs edit the Profile card in
SettingsScreen.ktand the ninestrings.xmlfiles, so whichever merges second will need a rebase. I will rebase this one onto the other, in either order.Italian translations reviewed by a native Italian speaker (the author). The other languages follow each locale file's existing terminology; native review welcome.