Guidelines for translating narrative content into Russian while preserving literary style and integrating it into the codebase.
This skill guides you through translating the "Book Reader" content (data.js) into Russian. It emphasizes literary quality (akin to Dostoyevsky or Bulgakov) over literal translation and provides a workflow for integrating multilingual support.
"Передавайте чувство, а не просто слова." The source material is a "Nordic Noir" style thriller. The Russian translation must reflect this cold, clinical, yet intense atmosphere. Use sophisticated, literary Russian (literaturnyy yazyk) for narrative, and more erratic, psychological language for Noa.
Tone Guidelines:
Use this to structurally prepare the codebase for Russian support.
Schema Update:
Modify src/features/reader/data.js to support Russian fields.
{
chapter: 1,
title: "PART I: THE DEFICIT",
title_ru: "ЧАСТЬ I: ДЕФИЦИТ", // [NEW]
content: "<p>...</p>",
content_ru: "<p>...</p>" // [NEW]
}
Logic Update:
Update logic.js to handle the ru language state.
const state = {
lang: 'en', // 'cn', 'id', or 'ru'
};
// In renderChapter:
let title, content;
if (state.lang === 'cn') {
title = chapter.title_cn;
content = chapter.content_cn;
} else if (state.lang === 'id') {
title = chapter.title_id;
content = chapter.content_id;
} else if (state.lang === 'ru') {
title = chapter.title_ru;
content = chapter.content_ru;
} else {
title = chapter.title;
content = chapter.content;
}
UI Update: Add a language toggle (RU) in the Settings Drawer.
Use this when generating the content.
Novel.txt or data.js chunk by chunk.<p>) is preserved.| English Term | Context | Russian Translation | Note |
|---|---|---|---|
| "HelloTalk" | The App | HelloTalk | Keep English brand name usually |
| "Social Housing" | Setting | Социальное жилье | Conveys the specific economic status |
| "Polders" | Geography | Польдеры | Standard term in Russian |
| "Apex Predator" | Metaphor | Высший хищник | Strength/Danger |