Skip to content

Commit 31a94f6

Browse files
committed
fix(app): complete Spanish translations for General settings
I ran into incomplete Spanish translations in General Settings while using the IDE in Spanish. Added the missing keys to packages/app/src/i18n/es.ts and updated the parity test so missing translations in this section fail the build. Closes anomalyco#32095
1 parent 3f81402 commit 31a94f6

2 files changed

Lines changed: 45 additions & 3 deletions

File tree

‎packages/app/src/i18n/es.ts‎

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -628,14 +628,19 @@ export const dict = {
628628
"settings.desktop.wsl.description": "Ejecutar el servidor OpenCode dentro de WSL en Windows.",
629629

630630
"settings.general.section.appearance": "Apariencia",
631+
"settings.general.section.advanced": "Avanzado",
631632
"settings.general.section.notifications": "Notificaciones del sistema",
632633
"settings.general.section.updates": "Actualizaciones",
633634
"settings.general.section.sounds": "Efectos de sonido",
634-
"settings.general.section.feed": "Feed",
635+
"settings.general.section.feed": "Novedades",
635636
"settings.general.section.display": "Pantalla",
636637

637638
"settings.general.row.language.title": "Idioma",
638639
"settings.general.row.language.description": "Cambiar el idioma de visualización para OpenCode",
640+
"settings.general.row.shell.title": "Shell de terminal",
641+
"settings.general.row.shell.description": "Shell usado en la terminal. Los compatibles también se usan para herramientas del agente.",
642+
"settings.general.row.shell.autoDefault": "Auto (predeterminado)",
643+
"settings.general.row.shell.terminalOnly": "solo terminal",
639644
"settings.general.row.appearance.title": "Apariencia",
640645
"settings.general.row.appearance.description": "Personaliza cómo se ve OpenCode en tu dispositivo",
641646
"settings.general.row.colorScheme.title": "Esquema de color",
@@ -644,15 +649,27 @@ export const dict = {
644649
"settings.general.row.theme.description": "Personaliza el tema de OpenCode.",
645650
"settings.general.row.font.title": "Fuente de código",
646651
"settings.general.row.font.description": "Personaliza la fuente usada en bloques de código",
647-
"settings.general.row.terminalFont.title": "Terminal Font",
648-
"settings.general.row.terminalFont.description": "Customise the font used in the terminal",
652+
"settings.general.row.terminalFont.title": "Fuente de terminal",
653+
"settings.general.row.terminalFont.description": "Personaliza la fuente usada en la terminal",
649654
"settings.general.row.uiFont.title": "Fuente de la interfaz",
650655
"settings.general.row.uiFont.description": "Personaliza la fuente usada en toda la interfaz",
651656
"settings.general.row.followup.title": "Comportamiento de seguimiento",
652657
"settings.general.row.followup.description":
653658
"Elige si los prompts de seguimiento se dirigen inmediatamente o esperan en una cola",
654659
"settings.general.row.followup.option.queue": "Cola",
655660
"settings.general.row.followup.option.steer": "Dirigir",
661+
"settings.general.row.showFileTree.title": "Árbol de archivos",
662+
"settings.general.row.showFileTree.description": "Mostrar el árbol de archivos en sesiones",
663+
"settings.general.row.showNavigation.title": "Controles de navegación",
664+
"settings.general.row.showNavigation.description": "Mostrar los botones atrás y adelante en la barra de título del escritorio",
665+
"settings.general.row.showSearch.title": "Paleta de comandos",
666+
"settings.general.row.showSearch.description": "Mostrar el botón de búsqueda y paleta de comandos en la barra de título",
667+
"settings.general.row.showTerminal.title": "Panel de terminal",
668+
"settings.general.row.showTerminal.description": "Mostrar el botón de terminal en la barra de título",
669+
"settings.general.row.showStatus.title": "Estado del servidor",
670+
"settings.general.row.showStatus.description": "Mostrar el botón de estado del servidor en la barra de título",
671+
"settings.general.row.showCustomAgents.title": "Agentes personalizados",
672+
"settings.general.row.showCustomAgents.description": "Mostrar el selector de agentes en el compositor",
656673
"settings.general.row.reasoningSummaries.title": "Mostrar resúmenes de razonamiento",
657674
"settings.general.row.reasoningSummaries.description":
658675
"Mostrar resúmenes del razonamiento del modelo en la línea de tiempo",
@@ -665,6 +682,10 @@ export const dict = {
665682
"settings.general.row.showSessionProgressBar.title": "Mostrar barra de progreso de la sesión",
666683
"settings.general.row.showSessionProgressBar.description":
667684
"Mostrar la barra de progreso animada en la parte superior de la sesión cuando el agente esté trabajando",
685+
"settings.general.row.newLayoutDesigns.title": "Nuevo diseño y maquetación",
686+
"settings.general.row.newLayoutDesigns.description": "Habilitar el diseño, inicio, compositor e interfaz de sesión rediseñados",
687+
"settings.general.row.pinchZoom.title": "Zoom con gestos y scroll",
688+
"settings.general.row.pinchZoom.description": "Permite usar gestos en el trackpad y Ctrl+desplazamiento para ampliar la vista.",
668689
"settings.general.row.wayland.title": "Usar Wayland nativo",
669690
"settings.general.row.wayland.description": "Deshabilitar fallback a X11 en Wayland. Requiere reinicio.",
670691
"settings.general.row.wayland.tooltip":

‎packages/app/src/i18n/parity.test.ts‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,17 @@ import { dict as tr } from "./tr"
2121
const locales = [ar, br, bs, da, de, es, fr, ja, ko, no, pl, ru, uk, th, tr, zh, zht]
2222
const keys = ["command.session.previous.unseen", "command.session.next.unseen"] as const
2323

24+
const ALLOW_LIST = ["OpenCode", "Wayland", "X11", "Linux", "Ctrl"] as const
25+
26+
const enDict = en as Record<string, string>
27+
const esDict = es as Record<string, string>
28+
29+
const generalKeys = Object.keys(enDict).filter((key) => key.startsWith("settings.general."))
30+
31+
function isAllowListed(value: string): boolean {
32+
return ALLOW_LIST.some((term) => term === value)
33+
}
34+
2435
describe("i18n parity", () => {
2536
test("non-English locales translate targeted unseen session keys", () => {
2637
for (const locale of locales) {
@@ -30,4 +41,14 @@ describe("i18n parity", () => {
3041
}
3142
}
3243
})
44+
45+
test("Spanish locale defines and translates all General settings keys", () => {
46+
for (const key of generalKeys) {
47+
expect(esDict[key]).toBeDefined()
48+
const englishValue = enDict[key]
49+
if (!isAllowListed(englishValue)) {
50+
expect(esDict[key]).not.toBe(englishValue)
51+
}
52+
}
53+
})
3354
})

0 commit comments

Comments
 (0)