Repository navigation
#886 Localisation: component and shared text - #968
Closed
ivanfenenko wants to merge 1 commit into
Closed
ivanfenenko wants to merge 1 commit into
ivanfenenko wants to merge 1 commit into
Conversation
Design-system components and the domain/shared code they read now take their English from the string files on both platforms: session list, dock and picker, live updates, top bar, composer, dictation card, activity card and sheet, step rail, image gallery and viewer, attachments, and small default labels. Relative times, session list section titles, share subjects, theme errors and the new-session title are keyed too. The hardcoded-text check now scans design-system components (galleries, previews, sample declarations and animation labels excluded).
ivanfenenko
force-pushed
the
feature/886-l10n-components
branch
from
November 2, 2026 23:16
c68ff6d to
78ba524
Compare
ivanfenenko
changed the base branch from
feature/886-l10n-settings
to
feature/886-l10n-timeline
November 2, 2026 23:16
ivanfenenko
marked this pull request as ready for review
November 3, 2026 15:59
Merged
Collaborator
Author
There was a problem hiding this comment.
Automated review: no finding that 2+ of 1 passes agreed on.
1 finding(s) from a single pass, not posted
android/app/src/main/java/dev/opencode/mobile/ui/components/chrome/OpenCodeSessionListDock.kt:710low: Ask about worktree expand/collapse reuse (glm-5.3-flash)
opencode pr-review · passes: muse-spark-1.3-contributor, glm-5.3-flash, deepseek-v4.1-flash · $0.148 · 2 pass(es) failed
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.
Summary
Stage 2 slice for #886 (Localisation): text built inside design-system components and in domain/shared code now comes from the string files on both platforms. Part of the unmerged localisation stack, based on
feature/886-l10n-settings(#957). Not compiled yet; the whole stack is built and verified once.stepsLabel, "Working", agent and status words), step rail, image gallery and viewer, attachments, outgoing message, branch pill actions, code-file line and diff summary labels, drop overlay, page indicator, file tabs, hunk pill, split pane, list item, selectable card, reorderable list, server address input, section header count, session-list skeleton, onboarding skeleton illustration.RelativeTimeFormatting.formatreturnsUiText; iOS resolvesString(localized:). The Add Project caption no longer uses.unlocalized.session.new_title).Navigation.kt. The Feedback share subject becomesUiText.ThemeManager.loadErrorisUiText/OpenCodeText.ProjectFilesException.detailisUiText; its fallback reusesfiles.error.check_server_connection.HomeSessionLadderSection.titleisUiText.SessionListSession.caption: UiTextSessionListStatus.toListItemStatus(…, text: UiTextLookup),compactStatus(text)SessionListScopeLoad/SessionListWorktreeEmptyCopyconstants are@StringRes;WorktreeFilterClear.messageis@StringResOpenCodeSessionConnectionStatus.labelis@StringResOpenCodeAttachmentVariant.labelis@StringRes(kindLabel()for display)OpenCodeTopBarLeading.Close.contentDescription: String?(defaults tocomponent_close)openCodeDetailLeading,openCodeActivityStepCount,openCodeActivityAgentSectionLabelare@ComposableModifier.composerAttachmentPasteMenu(pasteLabel = …)uses the systemandroid.R.string.pastesessionComposerSendLabel,questionSelectionHintandunavailableCopyreturnUiTextServerAddressInput.hintandReorderableList.contextActionLabeldefaults come from resourcesOpenCodeText.localized(_:)/localized(ifPresent:)for app text that shared code already resolved withString(localized:). It is not counted as debt.WorktreeFilterClear.messageand theSessionListWorktreeEmptyCopy/ scope-load title, message and retry values areOpenCodeTextThemeManager.loadError: OpenCodeText?OpenCodeDictationUnavailableReason.actionTitle: OpenCodeTextOpenCodeSessionConnectionStatus.label/accessibilityLabel(LocalizedStringResource)component.*,session_list.*,live_updates.*,relative_time.*,dictation.*,share.*,theme.*andsession.*, in one contiguous block instrings.xml. The catalog stays sorted; the change is insertions only (git diff --diff-algorithm=histogram). Existing keys reused where the meaning matches:common.retry,common.selected,common.open,common.cancel,common.remove,common.loading_sessions,top_bar.back,home.show_worktrees/home.hide_worktrees,home.worktree_count,files.error.check_server_connection, andsession_list.status.runningfor the illustration.scripts/check-hardcoded-text.mjs:ui/componentsand iOSComponents/.*Preview*/*Sample*declarations and Compose animation debug labels.\u{…}escapes ("+$additions") no longer count.Checks
node scripts/check-string-keys.mjs: pass, 932 shared keys (933 Android names includingapp_name).node scripts/check-hardcoded-text.mjs: 75.xmllint --nooutonstrings.xmlandpython3 -m json.toolon the catalog: pass.xcrun swiftc -parseon every changed Swift file: pass.R.string/R.pluralsand structured iOS key referenced in changed files exists.RelativeTimeFormattingTest,HomeSessionLadderTest,HomeSessionOrderStabilizerTest,SessionListStatusMappingTest,SessionListCompactRowTest,SessionListItemIndexTest,SessionListFilterTest,CrossProjectSessionListSessionsTest,SessionComposerSendLabelTest,DictationUnavailableCopyTest,ProjectFilesRepositoryTest.DictationUnavailableCopyTests. Other iOS tests compare English strings that are unchanged.gitleaksis not installed locally; the Secret Scan workflow covers it.Evidence
Verified once for the whole stack.
Issue
#886
Risks / Follow-ups
@Composablehelpers called from modifier chains and default parameters (openCodeDetailLeading,scopeControlDescription,stepRailAccessibilityLabel,OpenCodeActivityStatus.spoken(),titleBlockAccessibilityLabel,outgoingMessageInteractionModifier,questionSelectionDecorator). Also@StringRes valin companion objects, theProjectFilesExceptionsecondary constructor, and theUiTextcaption onSessionListSession.String(localized:defaultValue:)insidenonisolateddomain code (OptimisticSessionCreate.placeholderTitle,SessionDomainAdapter). AlsoOpenCodeText/LocalizedStringKeyternaries inOpenCodeHunkNavigationPill,StartDecoratorandRequestPagerKind,switchexpressions inOpenCodeAttachmentVariant.label, and the newOpenCodeText.localizedfactory.'on iOS too (was’).*_hintvs*_description(scheme picker, outgoing message, shell and side-question modes, activity rows).oneform (1 sessions,1m ago). The multi-argument "Added file %1$s, %2$d additions, %3$d deletions" and "%1$d of %2$d" are plain strings.OptimisticSessionCreate.PLACEHOLDER_TITLE,SessionDomainAdapter):Session.titleis aStringcarried through data, cache and every display site, and ViewModels must not callgetString. Thesession.new_titlekey exists on both platforms; iOS uses it.HomeWorktreeCopy.worktreeSubtitle): the row model lives inui/sessionchat, which another slice owns.HomeText.worktreeSubtitleis ready to swap in.files.*key, outside this slice's prefixes..unlocalized(prompt.selectedVariantLabel)): "Default" comes fromModelModels.defaultVariantLabeland Session Chat's UI models.SessionListFilterTab.all()("All", "N projects") andHomeSessionLadder.RECENT_HINT(not shown).Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.