Skip to content

Commit 1dd639b

Browse files
Revert translation breaking behavior (anomalyco#1342)
* Revert "fix(i18n/zh): cleanups to Chinese translations (anomalyco#1341)" This reverts commit 03ee1f2. * Revert "feat(i18n): add Thai language + missing translations for all other locales (anomalyco#1339)" This reverts commit db0f94e. * Revert "feat(i18n): extract en translations — session area (anomalyco#1249)" This reverts commit 3271af4. * Revert "feat(i18n): extract en translations — pages (anomalyco#1250)" This reverts commit e006aca. * Revert "feat(i18n): extract en translations — context/lib/misc (anomalyco#1251)" This reverts commit c349413.
1 parent b5b1fed commit 1dd639b

27 files changed

Lines changed: 1859 additions & 6831 deletions

‎apps/app/src/app/components/mcp-auth-modal.tsx‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
168168
statusPoll = window.setInterval(async () => {
169169
if (Date.now() - startedAt >= MCP_AUTH_TIMEOUT_MS) {
170170
stopStatusPolling();
171-
setError(translate("mcp.auth.request_timed_out"));
171+
setError("Request timed out.");
172172
return;
173173
}
174174

@@ -694,7 +694,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
694694
<CheckCircle2 size={24} class="text-green-11" />
695695
</div>
696696
<div>
697-
<p class="text-sm font-medium text-gray-12">{translate("mcp.auth.already_connected")}</p>
697+
<p class="text-sm font-medium text-gray-12">Already Connected</p>
698698
<p class="text-xs text-gray-11">
699699
{translate("mcp.auth.already_connected_description", { server: serverName() })}
700700
</p>
@@ -804,7 +804,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
804804
</div>
805805
<div class="rounded-xl border border-gray-6/70 bg-gray-2/40 px-3 py-2 flex items-center gap-3">
806806
<div class="flex-1 min-w-0">
807-
<div class="text-[10px] uppercase tracking-wide text-gray-8">{translate("mcp.auth.authorization_link")}</div>
807+
<div class="text-[10px] uppercase tracking-wide text-gray-8">Authorization link</div>
808808
<div class="text-[11px] text-gray-11 font-mono truncate">
809809
{authorizationUrl()}
810810
</div>
@@ -814,7 +814,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
814814
class="text-xs"
815815
onClick={handleCopyAuthorizationUrl}
816816
>
817-
{authUrlCopied() ? translate("mcp.auth.copied") : translate("mcp.auth.copy_link")}
817+
{authUrlCopied() ? "Copied" : "Copy link"}
818818
</Button>
819819
</div>
820820
<TextInput
@@ -851,7 +851,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
851851
1
852852
</div>
853853
<div>
854-
<p class="text-sm font-medium text-gray-12">{translate("mcp.auth.step1_title")}</p>
854+
<p class="text-sm font-medium text-gray-12">Opening your browser</p>
855855
<p class="text-xs text-gray-10 mt-1">
856856
{translate("mcp.auth.step1_description", { server: serverName() })}
857857
</p>
@@ -863,7 +863,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
863863
2
864864
</div>
865865
<div>
866-
<p class="text-sm font-medium text-gray-12">{translate("mcp.auth.step2_title")}</p>
866+
<p class="text-sm font-medium text-gray-12">Authorize OpenWork</p>
867867
<p class="text-xs text-gray-10 mt-1">
868868
{translate("mcp.auth.step2_description")}
869869
</p>
@@ -875,7 +875,7 @@ export default function McpAuthModal(props: McpAuthModalProps) {
875875
3
876876
</div>
877877
<div>
878-
<p class="text-sm font-medium text-gray-12">{translate("mcp.auth.step3_title")}</p>
878+
<p class="text-sm font-medium text-gray-12">Return here when you're done</p>
879879
<p class="text-xs text-gray-10 mt-1">
880880
{translate("mcp.auth.step3_description")}
881881
</p>

‎apps/app/src/app/components/question-modal.tsx‎

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import type { QuestionInfo } from "@opencode-ai/sdk/v2/client";
44
import { Check, ChevronRight, HelpCircle } from "lucide-solid";
55

66
import Button from "./button";
7-
import { t } from "../../i18n";
87

98
export type QuestionModalProps = {
109
open: boolean;
@@ -139,10 +138,10 @@ export default function QuestionModal(props: QuestionModalProps) {
139138
</div>
140139
<div>
141140
<h3 class="text-lg font-semibold text-gray-12">
142-
{currentQuestion()!.header || t("common.question")}
141+
{currentQuestion()!.header || "Question"}
143142
</h3>
144143
<div class="text-xs text-gray-11 font-medium">
145-
{t("question_modal.question_counter", undefined, { current: currentIndex() + 1, total: props.questions.length })}
144+
Question {currentIndex() + 1} of {props.questions.length}
146145
</div>
147146
</div>
148147
</div>
@@ -187,14 +186,14 @@ export default function QuestionModal(props: QuestionModalProps) {
187186
<Show when={currentQuestion()!.custom}>
188187
<div class="mt-4 pt-4 border-t border-dls-border">
189188
<label class="block text-xs font-semibold text-dls-secondary mb-2 uppercase tracking-wide">
190-
{t("question_modal.custom_answer_label")}
189+
Or type a custom answer
191190
</label>
192191
<input
193192
type="text"
194193
value={customInput()}
195194
onInput={(e) => setCustomInput(e.currentTarget.value)}
196195
class="w-full px-4 py-3 rounded-xl bg-dls-surface border border-dls-border focus:border-dls-accent focus:ring-4 focus:ring-[rgba(var(--dls-accent-rgb),0.2)] focus:outline-none text-sm text-dls-text placeholder:text-dls-secondary transition-shadow"
197-
placeholder={t("question_modal.custom_answer_placeholder")}
196+
placeholder="Type your answer here..."
198197
onKeyDown={(e) => {
199198
if (e.key === "Enter") {
200199
if (e.isComposing || e.keyCode === 229) return;
@@ -210,15 +209,15 @@ export default function QuestionModal(props: QuestionModalProps) {
210209
<div class="p-6 border-t border-dls-border bg-dls-hover flex justify-between items-center">
211210
<div class="text-xs text-dls-secondary flex items-center gap-2">
212211
<span class="px-1.5 py-0.5 rounded border border-dls-border bg-dls-active font-mono">↑↓</span>
213-
<span>{t("common.navigate")}</span>
212+
<span>navigate</span>
214213
<span class="px-1.5 py-0.5 rounded border border-gray-6 bg-gray-3 font-mono ml-2">↵</span>
215-
<span>{t("common.select")}</span>
214+
<span>select</span>
216215
</div>
217216

218217
<div class="flex gap-2">
219218
<Show when={currentQuestion()?.multiple || currentQuestion()?.custom}>
220219
<Button onClick={handleNext} disabled={!canProceed() || props.busy} class="!px-6">
221-
{isLastQuestion() ? t("common.submit") : t("common.next")}
220+
{isLastQuestion() ? "Submit" : "Next"}
222221
<Show when={!isLastQuestion()}>
223222
<ChevronRight size={16} class="ml-1 -mr-1 opacity-60" />
224223
</Show>

‎apps/app/src/app/components/session/composer.tsx‎

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import ComposerNotice, { type ComposerNotice as ComposerNoticeData } from "./com
77

88
import type { ComposerAttachment, ComposerDraft, ComposerPart, PromptMode, SlashCommandOption } from "../../types";
99
import { perfNow, recordPerfLog } from "../../lib/perf-log";
10-
import { t } from "../../../i18n";
1110

1211
type MentionOption = {
1312
id: string;
@@ -517,7 +516,7 @@ export default function Composer(props: ComposerProps) {
517516
span.dataset.pasteId = part.id;
518517
span.dataset.pasteLabel = part.label;
519518
span.dataset.pasteLines = String(part.lines);
520-
span.title = t("composer.expand_pasted");
519+
span.title = "Click to expand pasted text";
521520
span.className =
522521
"inline-flex items-center rounded-full px-2 py-0.5 text-[11px] font-semibold bg-gray-3 text-gray-10 border border-gray-6 cursor-pointer hover:bg-gray-4 hover:text-gray-11";
523522
return span;
@@ -1059,7 +1058,7 @@ export default function Composer(props: ComposerProps) {
10591058
const addAttachments = async (files: File[]) => {
10601059
if (attachmentsDisabled()) {
10611060
props.onNotice({
1062-
title: props.attachmentsDisabledReason ?? t("composer.attachments_unavailable"),
1061+
title: props.attachmentsDisabledReason ?? "Attachments are unavailable.",
10631062
tone: "warning",
10641063
});
10651064
return;
@@ -1079,7 +1078,7 @@ export default function Composer(props: ComposerProps) {
10791078
for (const file of supportedFiles) {
10801079
if (file.size > MAX_ATTACHMENT_BYTES) {
10811080
props.onNotice({
1082-
title: t("composer.file_exceeds_limit", undefined, { name: file.name }),
1081+
title: `${file.name} exceeds the 8MB limit.`,
10831082
tone: "warning",
10841083
});
10851084
continue;
@@ -1090,7 +1089,7 @@ export default function Composer(props: ComposerProps) {
10901089
const estimatedJsonBytes = estimateInlineAttachmentBytes(processed);
10911090
if (estimatedJsonBytes > MAX_ATTACHMENT_BYTES) {
10921091
props.onNotice({
1093-
title: t("composer.file_too_large_encoding", undefined, { name: file.name }),
1092+
title: `${file.name} is too large after encoding. Try a smaller image.`,
10941093
tone: "warning",
10951094
});
10961095
continue;
@@ -1106,7 +1105,7 @@ export default function Composer(props: ComposerProps) {
11061105
});
11071106
} catch (error) {
11081107
props.onNotice({
1109-
title: error instanceof Error ? error.message : t("composer.failed_read_attachment"),
1108+
title: error instanceof Error ? error.message : "Failed to read attachment",
11101109
tone: "error",
11111110
});
11121111
}
@@ -1222,29 +1221,29 @@ export default function Composer(props: ComposerProps) {
12221221
props.onNotice({
12231222
title:
12241223
links.length === 1
1225-
? t("composer.uploaded_single_file", undefined, { name: links[0].name })
1226-
: t("composer.uploaded_multiple_files", undefined, { count: links.length }),
1224+
? `Uploaded ${links[0].name} to the shared folder and inserted a link.`
1225+
: `Uploaded ${links.length} files to the shared folder and inserted links.`,
12271226
tone: "success",
12281227
});
12291228
return;
12301229
}
12311230
}
12321231
props.onNotice({
1233-
title: t("composer.upload_failed_local_links"),
1232+
title: "Couldn't upload to the shared folder. Inserted local links instead.",
12341233
tone: "warning",
12351234
});
12361235
}
12371236

12381237
const text = formatLinks(fallbackLinks());
12391238
if (!text) {
1240-
props.onNotice({ title: t("composer.unsupported_attachment_type"), tone: "warning" });
1239+
props.onNotice({ title: "Unsupported attachment type.", tone: "warning" });
12411240
return;
12421241
}
12431242
insertPlainTextAtSelection(text);
12441243
updateMentionQuery();
12451244
updateSlashQuery();
12461245
emitDraftChange();
1247-
props.onNotice({ title: t("composer.inserted_links_unsupported"), tone: "info" });
1246+
props.onNotice({ title: "Inserted links for unsupported files.", tone: "info" });
12481247
};
12491248

12501249
const handlePaste = (event: ClipboardEvent) => {
@@ -1278,9 +1277,10 @@ export default function Composer(props: ComposerProps) {
12781277
const hasAbsoluteWindows = /(^|\s)[a-zA-Z]:\\/.test(trimmedForCheck);
12791278
if (hasFileUrl || hasAbsolutePosix || hasAbsoluteWindows) {
12801279
props.onNotice({
1281-
title: t("composer.remote_worker_paste_warning"),
1280+
title:
1281+
"This is a remote worker. Sandboxes are remote too. To share files with it, upload them to the Shared folder in the sidebar.",
12821282
tone: "warning",
1283-
actionLabel: props.onUploadInboxFiles ? t("composer.upload_to_shared_folder") : undefined,
1283+
actionLabel: props.onUploadInboxFiles ? "Upload to shared folder" : undefined,
12841284
onAction: props.onUploadInboxFiles ? () => inboxFileInputRef?.click() : undefined,
12851285
});
12861286
}
@@ -1572,7 +1572,7 @@ export default function Composer(props: ComposerProps) {
15721572
<div class="max-h-64 overflow-y-auto bg-dls-surface p-2" onMouseDown={(event: MouseEvent) => event.preventDefault()}>
15731573
<Show
15741574
when={mentionVisible().length}
1575-
fallback={<div class="px-3 py-2 text-xs text-gray-10">{t("composer.no_matches")}</div>}
1575+
fallback={<div class="px-3 py-2 text-xs text-gray-10">No matches found.</div>}
15761576
>
15771577
<For each={mentionVisible()}>
15781578
{(option: MentionOption) => {
@@ -1635,7 +1635,7 @@ export default function Composer(props: ComposerProps) {
16351635
when={slashFiltered().length}
16361636
fallback={
16371637
<div class="px-3 py-2 text-xs text-gray-10">
1638-
{slashLoading() ? t("composer.loading_commands") : t("composer.no_commands")}
1638+
{slashLoading() ? "Loading commands..." : "No commands found."}
16391639
</div>
16401640
}
16411641
>
@@ -1662,7 +1662,7 @@ export default function Composer(props: ComposerProps) {
16621662
</div>
16631663
<Show when={cmd.source && cmd.source !== "command"}>
16641664
<span class="text-[10px] uppercase tracking-wider text-gray-10 shrink-0">
1665-
{cmd.source === "skill" ? t("composer.skill_source") : cmd.source === "mcp" ? "MCP" : ""}
1665+
{cmd.source === "skill" ? "Skill" : cmd.source === "mcp" ? "MCP" : ""}
16661666
</span>
16671667
</Show>
16681668
</button>
@@ -1697,7 +1697,7 @@ export default function Composer(props: ComposerProps) {
16971697
<div class="max-w-[160px]">
16981698
<div class="truncate text-gray-11">{attachment.name}</div>
16991699
<div class="text-[10px] text-gray-10">
1700-
{attachment.kind === "image" ? t("composer.image_kind") : attachment.mimeType || t("composer.file_kind")}
1700+
{attachment.kind === "image" ? "Image" : attachment.mimeType || "File"}
17011701
</div>
17021702
</div>
17031703
<button
@@ -1721,7 +1721,7 @@ export default function Composer(props: ComposerProps) {
17211721
<div class="relative">
17221722
<Show when={!hasDraftContent()}>
17231723
<div class="absolute left-0 top-0 text-gray-9 text-[15px] leading-relaxed pointer-events-none">
1724-
{t("composer.placeholder")}
1724+
Describe your task...
17251725
</div>
17261726
</Show>
17271727
<div
@@ -1775,8 +1775,8 @@ export default function Composer(props: ComposerProps) {
17751775
disabled={attachmentsDisabled()}
17761776
title={
17771777
attachmentsDisabled()
1778-
? props.attachmentsDisabledReason ?? t("composer.attachments_unavailable")
1779-
: t("composer.attach_files")
1778+
? props.attachmentsDisabledReason ?? "Attachments are unavailable."
1779+
: "Attach files"
17801780
}
17811781
>
17821782
<Paperclip size={16} />
@@ -1794,21 +1794,21 @@ export default function Composer(props: ComposerProps) {
17941794
? "bg-gray-4 text-gray-10"
17951795
: "bg-dls-accent text-white hover:bg-[var(--dls-accent-hover)]"
17961796
}`}
1797-
title={t("composer.run_task")}
1797+
title="Run task"
17981798
>
17991799
<ArrowUp size={15} />
1800-
<span>{t("composer.run_task")}</span>
1800+
<span>Run task</span>
18011801
</button>
18021802
}
18031803
>
18041804
<button
18051805
type="button"
18061806
onClick={() => props.onStop()}
18071807
class="inline-flex items-center gap-2 rounded-full bg-gray-12 px-4 py-2 text-[13px] font-medium text-gray-1 transition-colors hover:bg-gray-11"
1808-
title={t("composer.stop")}
1808+
title="Stop"
18091809
>
18101810
<Square size={12} fill="currentColor" />
1811-
<span>{t("composer.stop")}</span>
1811+
<span>Stop</span>
18121812
</button>
18131813
</Show>
18141814
</div>
@@ -1829,7 +1829,7 @@ export default function Composer(props: ComposerProps) {
18291829
onClick={props.onToggleAgentPicker}
18301830
disabled={props.busy}
18311831
aria-expanded={props.agentPickerOpen}
1832-
title={t("composer.agent_label")}
1832+
title="Agent"
18331833
>
18341834
<span class="max-w-[140px] truncate">{props.agentLabel}</span>
18351835
<ChevronDown size={13} />
@@ -1838,14 +1838,14 @@ export default function Composer(props: ComposerProps) {
18381838
<Show when={props.agentPickerOpen}>
18391839
<div class="absolute left-0 bottom-full z-40 mb-2 w-64 overflow-hidden rounded-[18px] border border-dls-border bg-dls-surface shadow-[var(--dls-shell-shadow)]">
18401840
<div class="border-b border-dls-border px-3 pt-2 pb-1 text-[10px] font-semibold uppercase tracking-[0.2em] text-gray-10">
1841-
{t("composer.agent_label")}
1841+
Agent
18421842
</div>
18431843

18441844
<div class="p-2 space-y-1 max-h-64 overflow-y-auto" onMouseDown={(event: MouseEvent) => event.preventDefault()}>
18451845
<Show
18461846
when={!props.agentPickerBusy}
18471847
fallback={
1848-
<div class="px-3 py-2 text-xs text-gray-10">{t("composer.loading_agents")}</div>
1848+
<div class="px-3 py-2 text-xs text-gray-10">Loading agents...</div>
18491849
}
18501850
>
18511851
<Show when={!props.agentPickerError}>
@@ -1860,7 +1860,7 @@ export default function Composer(props: ComposerProps) {
18601860
props.onSelectAgent(null);
18611861
}}
18621862
>
1863-
<span>{t("composer.default_agent")}</span>
1863+
<span>Default agent</span>
18641864
<Show when={!props.selectedAgent}>
18651865
<Check size={14} class="text-gray-10" />
18661866
</Show>
@@ -1931,7 +1931,7 @@ export default function Composer(props: ComposerProps) {
19311931
<Show when={variantMenuOpen()}>
19321932
<div class="absolute left-0 bottom-full z-40 mb-2 w-48 overflow-hidden rounded-[18px] border border-dls-border bg-dls-surface shadow-[var(--dls-shell-shadow)]">
19331933
<div class="border-b border-dls-border px-3 pt-2 pb-1 text-[10px] font-semibold uppercase tracking-[0.2em] text-gray-10">
1934-
{t("composer.behavior_label")}
1934+
Behavior
19351935
</div>
19361936
<div class="p-2 space-y-1">
19371937
<For each={props.modelBehaviorOptions}>

0 commit comments

Comments
 (0)