How every user-facing text of the Nyxs app is translated into its 10 languages, and how to keep the agent and outside services in the user's language. Use whenever adding or changing a visible string in src/ (a label, button, menu item, tooltip, placeholder, empty state, error), a slash command or prompt Nyxs sends on the user's behalf, or a request to a service that writes text the user reads.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Nyxs I18n?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/nyxs-code-nyxs-i18n)
---
name: nyxs-i18n
description: How every user-facing text of the Nyxs app is translated into its 10 languages, and how to keep the agent and outside services in the user's language. Use whenever adding or changing a visible string in src/ (a label, button, menu item, tooltip, placeholder, empty state, error), a slash command or prompt Nyxs sends on the user's behalf, or a request to a service that writes text the user reads.
---
# Languages in Nyxs
The app speaks 10 languages: `en-US es-ES fr-FR de-DE it-IT pt-BR id-ID ja-JP ko-KR hi-IN`
(`src/locales/<code>.ts`, typed by `src/locales/types.ts`).
## Every visible text comes from the locales
- No visible English literal in a component: `const t = useTranslations().<namespace>` and
`t.key`. A whole menu once shipped in English ("Organize recents": Status, Group by, Sort by…)
because its labels were literals.
- A new key goes into **all 10 files and `types.ts`**, in the same namespace and place. `tsc`
fails on a missing one in `types.ts`, not on a missing translation's quality: write each
language natively, short (German and Hindi run longest).
- Placeholders are `{name}` and filled with `.replace("{name}", value)`.
- Product names stay as they are ("Ultracode", "YouTube Music", "Claude Code").
- Outside React (lib code) use `getTranslations(getLanguage())`.
## Adding keys to the 10 files
Use the editor (Edit/Write) or a script file, not an inline shell heredoc: a heredoc through
Python or sed has turned `\n` in strings into real line breaks several times. A safe pattern is a
`.py` file written with the Write tool that inserts a block before a known anchor in each file
(`re.search(r"\n wrapUp: \{\n", s)`) with values from a dict per language, plus `types.ts`; run it,
then delete it.
## Text Nyxs sends for the user
- A command's or button's text goes to the model **as the user's message**, and the model answers
in the language of the last message it got: an English `/commit` switched a Spanish chat to
English. Every expanded command ends with `COMMAND_LANGUAGE_NOTE` (`withLanguageNote` in
`src/lib/slashCommand.ts`); keep any new text sent for the user in that path.
- When the chat should show something shorter than what the agent gets (a proposed task's "Do
it here"), pass a `shown` text (`sendAsUser(chatId, text, shown)`), like commands do.
## Outside services
A service that writes text the user reads gets the app's language: Google's Workspace MCP
servers localize their confirmation question and choices from `Accept-Language`
(`workspaceHeaders` in `src/lib/mcpElicitation.ts`); without it they answer in English. Don't
replace a service's own labels with Nyxs' unless it documents fixed values.
## Checks
`node node_modules/typescript/bin/tsc -p tsconfig.app.json --noEmit` and a test that renders the
component in `en-US` reading the label from `getTranslations("en-US")` (never a hard-coded
English string in the test).