fix(thread): translate the branch picker's PR-tab strings - #5273
Merged
Conversation
The branches tab already went through i18n, but the PR tab (added later) hardcoded its labels/messages in English, so pt-BR users saw untranslated "Search pull requests…", "Branches"/"PRs" tabs, loading/empty states, and the fork-hidden-count message.
pedrofrxncx
enabled auto-merge (squash)
July 27, 2026 18:43
decocms Bot
pushed a commit
that referenced
this pull request
Jul 27, 2026
PR: #5273 fix(thread): translate the branch picker's PR-tab strings Bump type: patch - decocms (apps/api/package.json): 4.133.7 -> 4.133.8 Deploy-Scope: web
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.
Source
Repo-wide i18n rule (CLAUDE.md): "Never hardcode user-facing strings in apps/web/src".
BranchPicker's "Branches" tab already goes throught(), but its "PRs" tab — added in a later PR — hardcoded every one of its strings in English.Why
pt-BR users hit raw English text ("Search pull requests…", "Branches"/"PRs" tab labels, loading/error/empty states, the open-PRs group heading, the fork-hidden-count footer, and the "Last 7 days" branch group heading) inside an otherwise fully-translated picker. This is the same proven i18n-hardening lane as #5048/#5062/#5099/#5110/#5141/#5170/#5214/#5218.
Changes
apps/web/src/components/thread/github/branch-picker.tsx— replaced 9 hardcoded strings witht("thread.branchPicker.*")calls (tab labels, PR loading/error/empty states, open-PRs heading, hidden-fork-count message with{count}interpolation, and the "Last 7 days" branch group heading).apps/web/src/i18n/en/thread.ts/apps/web/src/i18n/pt-br/thread.ts— added the matchingthread.branchPicker.*keys (pt-BR mirrors English exactly, following the existing pattern in this dictionary).No logic change — pure string extraction, same behavior in English, now translated in pt-BR.
How to verify
cd apps/web && bunx tsc --noEmit— thesatisfies Record<keyof typeof enDomain, string>constraint onpt-br/thread.tsfails to compile if a key is missing, so a clean typecheck proves translation completeness.Local checks run
bun run fmt— clean.bunx tsc --noEmitinapps/web— clean (this also validates translation-key completeness, see above).Summary by cubic
Localized the Branch Picker PR tab by moving all user-facing strings to i18n. This fixes untranslated English text for pt-BR users and aligns with the repo i18n rule.
apps/web/src/components/thread/github/branch-picker.tsxwitht("thread.branchPicker.*")(search placeholder, tab labels, loading/error/empty states, open-PRs heading, hidden fork count with{count}, and "Last 7 days").apps/web/src/i18n/en/thread.tsandapps/web/src/i18n/pt-br/thread.ts.Written for commit 4b74aa5. Summary will update on new commits.