You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thai-speaking users currently fall back to English. Add ไทย to the language picker and provide Thai translations for all 3,340 messages in the current English ARB, including the four Stress Nerd Stats labels on main.
The Thai ARB preserves every key, metadata entry and ICU argument. Product names, technical abbreviations and dynamic external names retain their source values. Regression coverage checks message completeness, plural/select rendering, saved language selection on a short screen, and numbered OS notifications.
Validation with Flutter 3.41.6:
flutter gen-l10n — passed.
flutter analyze --no-pub — passed.
flutter test --no-pub --concurrency=1 for thai_l10n_test.dart, language_picker_sheet_test.dart, notification_number_bodies_l10n_test.dart, investigate_stress_index_test.dart and investigate_stress_load_test.dart — 23 passed.
Full suite with the translation on base 09009839 — 6,613 passed, 28 skipped, 1 failed on macOS. The failure is health_workout_export_delete_gate_test.dart:99 (“a failed delete does not write a duplicate on top of it”). That test assumes a non-Apple host, while HealthExporter.isApple is true on macOS. The same failure was reproduced on an untouched export of 09009839 without Thai support (10 passed, 1 failed). The current base is 797a9a4f; its stress tests are included in the targeted run above.
Summary by Sourcery
Add complete Thai language support and verify its integration across localization, language selection, and notification flows.
New Features:
Add Thai localization across the app and make Thai available in the language picker.
Enhancements:
Preserve Thai localization coverage for ICU arguments, dynamic values, and numbered notification content.
Tests:
Add regression coverage for Thai message completeness, plural and select rendering, language-picker persistence, and localized notifications.
Summary by CodeRabbit
New Features
Added Thai-language translations for app screens and messages, including onboarding, profiles, settings, health features, and error messages.
Added Thai to the language names shown in the app.
This PR introduces Thai as a selectable app locale by supplying a full 3,340-message ARB translation and registering it with the picker, with focused tests covering catalog parity, ICU behavior, notifications, selection, and persisted locale state. Targeted validation passes; the reported full-suite macOS failure reproduces on the unchanged base and is unrelated to Thai localization.
Sequence diagram for persisted Thai language selection
sequenceDiagram
actor User
participant Picker as Language picker
participant Locale as Locale storage
participant App as App localization
User->>Picker: Select Thai
Picker->>Locale: Persist locale th
Picker->>App: Apply Thai locale
App-->>User: Render Thai messages
App->>Locale: Load saved locale
Locale-->>App: Return th
Loading
Flow diagram for Thai locale selection and localization
Trigger a new review: Comment @sourcery-ai review on the pull request.
Continue discussions: Reply directly to Sourcery's review comments.
Generate a GitHub issue from a review comment: Ask Sourcery to create an
issue from a review comment by replying to it. You can also reply to a
review comment with @sourcery-ai issue to create an issue from it.
Generate a pull request title: Write @sourcery-ai anywhere in the pull
request title to generate a title at any time. You can also comment @sourcery-ai title on the pull request to (re-)generate the title at any time.
Generate a pull request summary: Write @sourcery-ai summary anywhere in
the pull request body to generate a PR summary at any time exactly where you
want it. You can also comment @sourcery-ai summary on the pull request to
(re-)generate the summary at any time.
Generate reviewer's guide: Comment @sourcery-ai guide on the pull
request to (re-)generate the reviewer's guide at any time.
Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
pull request to resolve all Sourcery comments. Useful if you've already
addressed all the comments and don't want to see them anymore.
Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
request to dismiss all existing Sourcery reviews. Especially useful if you
want to start fresh with a new review - don't forget to comment @sourcery-ai review to trigger a new review!
OpenStrap/edge#646: Adds English localization keys that the Thai catalog translates.
OpenStrap/edge#632: Adds English Stress Nerd Stats keys that the Thai catalog translates.
OpenStrap/edge#613: Changes the language-picker sheet, where the Thai option appears.
Suggested labels:Review effort 5/5
Suggested reviewers:sourcery-ai
Merge Risk: Minimal · previous review f2318
The missing description does not affect generated translations; no material merge risk is identified.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "feat(l10n): add Thai language support" matches the main change. The PR adds Thai (th) to the language picker and adds a full Thai ARB localization catalog (app_th.arb) covering the app's UI…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "feat(l10n): add Thai language support" matches the main change. The PR adds Thai (th) to the language picker and adds a full Thai ARB localization catalog (app_th.arb) covering the app's UI strings. The title is short, specific, and states the primary change.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Step calibration, raw-reading retention and compaction, the ChatGPT reset
warning and the CVHR no-comparison note were added to English after this
branch was cut, and the Thai key-parity test caught them.
The reason will be displayed to describe this comment to others. Learn more.
Additional comments: 1
lib/l10n/app_th.arb-5018-5018: 1
5018-5018: Minor · Maintainability & Code Quality · Quick win
Unverified finding
Verification ran but could not confirm this finding. It is shown for review, not as a verified issue.
Restore the missing message description.
The English template defines @investigateCvhrNoComparisonYet, but the Thai entry has no matching metadata block. Add the template description so the Thai catalog preserves the promised metadata. (raw.githubusercontent.com)
Proposed fix
"investigateCvhrNoComparisonYet": "ยังมีคืนก่อนหน้าไม่มากพอที่จะบอกได้ว่าการแกว่งของอัตราการเต้นหัวใจที่หน้านี้นับอยู่สูงกว่าปกติหรือไม่",
+ "@investigateCvhrNoComparisonYet": {+ "description": "Sentence: too few older nights exist yet to compare the recent heart-rate cycling against"+ },
"investigateCvhrInsideUsual": "ในคืนล่าสุด ๆ รอบการเปลี่ยนแปลงอัตราการเต้นหัวใจที่การคัดกรองนี้นับได้ยังอยู่ในช่วงของ {n} คืนก่อนหน้า",
Reviewing files that changed from the base of the PR and between 5466988 and f2318e5.
Files ignored due to path filters: 2
test/notification_number_bodies_l10n_test.dart is excluded by !test/**
test/thai_l10n_test.dart is excluded by !test/**
Files selected for processing: 1
lib/l10n/app_th.arb
Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.
Already reviewed the last commit. Use @coderabbitai full review to rerun a review of the entire changeset.
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
Already reviewed the last commit. Use @coderabbitai full review to rerun a review of the entire changeset.
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
Already reviewed the last commit. Use @coderabbitai full review to rerun a review of the entire changeset.
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
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
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.
Thai-speaking users currently fall back to English. Add ไทย to the language picker and provide Thai translations for all 3,340 messages in the current English ARB, including the four Stress Nerd Stats labels on
main.The Thai ARB preserves every key, metadata entry and ICU argument. Product names, technical abbreviations and dynamic external names retain their source values. Regression coverage checks message completeness, plural/select rendering, saved language selection on a short screen, and numbered OS notifications.
Validation with Flutter 3.41.6:
flutter gen-l10n— passed.flutter analyze --no-pub— passed.flutter test --no-pub --concurrency=1forthai_l10n_test.dart,language_picker_sheet_test.dart,notification_number_bodies_l10n_test.dart,investigate_stress_index_test.dartandinvestigate_stress_load_test.dart— 23 passed.09009839— 6,613 passed, 28 skipped, 1 failed on macOS. The failure ishealth_workout_export_delete_gate_test.dart:99(“a failed delete does not write a duplicate on top of it”). That test assumes a non-Apple host, whileHealthExporter.isAppleis true on macOS. The same failure was reproduced on an untouched export of09009839without Thai support (10 passed, 1 failed). The current base is797a9a4f; its stress tests are included in the targeted run above.Summary by Sourcery
Add complete Thai language support and verify its integration across localization, language selection, and notification flows.
New Features:
Enhancements:
Tests:
Summary by CodeRabbit