Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -187,16 +187,23 @@ Supported locales:
Guidelines:

- Add English keys first, then update every locale file in `src/core/i18n/translations/`.
- User-facing copy is not complete until every supported locale has complete, accurate localized text in the same PR. Do not ship English-only page body, FAQ, table, example, schema, or SEO copy with only localized metadata, and do not make only part of a page original while leaving the rest as English fallback copy.
- Hard merge rule: user-facing copy is not complete until every supported locale in the same PR has complete, accurate localized text. This includes headings, body copy, CTAs, FAQ, table text, examples, schema-visible text, and SEO metadata.
- Hard merge rule: every supported locale has complete, accurate localized text before a PR can merge.
- No English-only originality: new or rewritten content cannot be authored only for `en` while other locales receive fallback, literal filler, or metadata-only localization.
- No partial originality: the complete affected user-facing surface must be localized. Do not make only one locale, one section, or only above-the-fold copy original while leaving the rest as generic fallback copy.
- partial originality is not acceptable for any user-facing copy, SEO copy, FAQ, table, example, or schema-visible text.
- Partial localization is a merge blocker. Split scope before opening the PR if the full multilingual copy cannot be reviewed accurately.
- Preserve technical terms such as `JSON`, `JWT`, `API`, `Base64`, and `UUID` when that is the natural localized form.
- For Chinese copy, use spaces between Chinese text and English terms or numbers where readability requires it.
- Keep labels short enough for compact tool controls.
- Use the [i18n glossary](docs/i18n/glossary.md) for privacy, runtime, workflow, and tool-family terminology.
- For larger localized copy or SEO template changes, follow the [localization quality review checklist](docs/specs/localization-quality-review.md).

Checks:

```bash
npm run check:i18n
npm run check:i18n-qa
npm run check:metadata-localization
```

Expand Down
44 changes: 44 additions & 0 deletions docs/i18n/glossary.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Byteflow i18n Glossary

This glossary is the source of truth for user-facing localization of privacy, runtime, workflow, and tool-family terms. Every copy change must keep all supported locales aligned: `en`, `zh-CN`, `zh-TW`, `ja`, `ko`, `de`, and `fr`.

## Rules

- Localize complete page copy in the same PR: title, description, headings, body copy, CTAs, FAQ, table text, examples, schema-visible text, and SEO metadata.
- Hard merge rule: user-facing copy is not complete until every supported locale in the same PR has complete, accurate localized text.
- User-facing copy must ship as complete, accurate localized text across every supported locale.
- No English-only originality: do not author original content only for `en` while other locales receive fallback, literal filler, or metadata-only localization.
- No partial originality: the complete affected user-facing surface must be localized. Do not make only one locale, one section, or only above-the-fold copy original while leaving the rest as generic fallback copy.
- Partial localization is a merge blocker. Split scope before opening the PR if accurate localization for all supported locales is not ready.
- Keep technical tokens such as `JSON`, `JWT`, `API`, `Base64`, `UUID`, `SHA-256`, and `HMAC` unchanged when that is the natural local form.
- Prefer clear product language over literal translation when a locale has a more natural technical term.

## Privacy And Runtime Terms

| Concept | en | zh-CN | zh-TW | ja | ko | de | fr |
| --- | --- | --- | --- | --- | --- | --- | --- |
| Browser-local | Browser-local | 浏览器本地 | 瀏覽器本地 | ブラウザ内 | 브라우저 로컬 | browserlokal | local dans le navigateur |
| Offline capable | Offline capable | 支持离线 | 支援離線 | オフライン対応 | 오프라인 가능 | offlinefähig | utilisable hors ligne |
| External request | External request | 外部请求 | 外部請求 | 外部リクエスト | 외부 요청 | externe Anfrage | requête externe |
| Sensitive input | Sensitive input | 敏感输入 | 敏感輸入 | 機密入力 | 민감한 입력 | sensible Eingabe | entrée sensible |
| Privacy-first | Privacy-first | 隐私优先 | 隱私優先 | プライバシー重視 | 개인정보 우선 | datenschutzfreundlich | respectueux de la vie privée |
| Local-first | Local-first | 本地优先 | 本地優先 | ローカル優先 | 로컬 우선 | lokal zuerst | local-first |

## Tool Family Terms

| Concept | en | zh-CN | zh-TW | ja | ko | de | fr |
| --- | --- | --- | --- | --- | --- | --- | --- |
| Formatter | Formatter | 格式化工具 | 格式化工具 | フォーマッター | 포매터 | Formatierer | formateur |
| Encoder | Encoder | 编码器 | 編碼器 | エンコーダー | 인코더 | Encoder | encodeur |
| Decoder | Decoder | 解码器 | 解碼器 | デコーダー | 디코더 | Decoder | décodeur |
| Hash | Hash | 哈希 | 雜湊 | ハッシュ | 해시 | Hash | hash |
| Workflow | Workflow | 工作流 | 工作流 | ワークフロー | 워크플로 | Workflow | workflow |
| Pipeline | Pipeline | Pipeline | Pipeline | パイプライン | 파이프라인 | Pipeline | pipeline |

## Writing Notes

- Chinese: use Simplified Chinese for `zh-CN` and Traditional Chinese for `zh-TW`. Keep spaces around Latin technical tokens when readability improves.
- Japanese: keep particles natural and avoid English carryover except accepted technical tokens.
- Korean: check particles after English tokens and avoid awkward transliteration.
- German: prefer compounds where natural, but avoid overlong button text.
- French: keep accents, agreement, and apostrophes correct; do not use unaccented fallback copy.
7 changes: 6 additions & 1 deletion docs/specs/localization-quality-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,12 @@ The previous localization pass allowed weak copy to land for four concrete reaso
- Do not use synthetic translation generation for production localized copy.
- Treat checked-in localized JSON as user-facing copy, even when the path contains `generated`.
- For every localized copy change, review all supported locales: `zh-CN`, `zh-TW`, `ja`, `ko`, `de`, and `fr`.
- New user-facing pages, guides, comparisons, alternatives, tutorials, FAQ, schema-visible text, examples, tables, and SEO copy must be fully localized for every supported locale in the same change. Localized titles or descriptions are not enough when the body remains English, and partial originality is not acceptable.
- Hard merge rule: user-facing copy is not complete until every supported locale in the same PR has complete, accurate localized text.
- New user-facing pages, guides, comparisons, alternatives, tutorials, headings, CTAs, FAQ, schema-visible text, examples, tables, and SEO copy must be fully localized for every supported locale in the same change.
- No English-only originality: original content cannot exist only in `en` while non-English locales receive fallback, literal filler, or metadata-only localization. Localized titles or descriptions are not enough when the body remains English.
- No partial originality: original treatment must cover the complete affected user-facing surface, not only one locale, one section, or only above-the-fold copy.
- Partial localization is a merge blocker. Reduce the PR scope instead of shipping partial multilingual content.
- Use `docs/i18n/glossary.md` as the source of truth for privacy, runtime, workflow, and tool-family terms.
- Preserve accepted technical terms such as `JSON`, `YAML`, `TOML`, `JWT`, `API`, `Base32`, `Base58`, `Base64`, and `UUID` when that is the natural localized form.
- Translate workflow terms deliberately. Do not leave `fixture`, `payload`, or similar English terms in non-English copy unless the locale commonly uses that term in technical UI.
- Check grammar and typography, not just key presence. Watch for Korean particles, Japanese spacing around particles, German compound terms, French agreement, and Chinese spacing around Latin technical terms.
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"scripts": {
"dev": "next dev",
"analyze": "ANALYZE=true next build --webpack",
"validate": "npm run check:sw-version && npm run check:sitemap-lastmod && npm run check:security-headers && npm run check:pwa-manifests && npm run check:runtime-scripts && npm run check:bundle-boundaries && npm run check:performance-budget && npm run check:og-tool-images && npm run check:ia-stability && npm run check:analytics-taxonomy && npm run check:registry-manifests && npm run check:tool-index && npm run check:legacy-routes && npm run check:client-tool-lookup && npm run check:privacy-copy && npm run check:i18n && npm run check:types",
"validate": "npm run check:sw-version && npm run check:sitemap-lastmod && npm run check:security-headers && npm run check:pwa-manifests && npm run check:runtime-scripts && npm run check:bundle-boundaries && npm run check:performance-budget && npm run check:og-tool-images && npm run check:ia-stability && npm run check:analytics-taxonomy && npm run check:registry-manifests && npm run check:tool-index && npm run check:legacy-routes && npm run check:client-tool-lookup && npm run check:privacy-copy && npm run check:i18n && npm run check:i18n-qa && npm run check:types",
"build:app": "next build",
"build:post": "npm run check:canonical && npm run check:hreflang && npm run check:legacy-routes && npm run check:metadata-localization && npm run check:jsonld-structured-data && npm run check:performance-budget:report && npm run check:rendered-i18n-copy && npm run check:related-tools && npm run check:content-template:legacy-paths && npm run check:content-template && npm run check:content-template:quality && npm run check:content-template:uniqueness && npm run check:faq-schema && npm run check:content-template:zh-cn && npm run check:content-template:quality:zh-cn && npm run check:faq-schema:zh-cn && npm run check:content-template:zh-tw && npm run check:content-template:quality:zh-tw && npm run check:faq-schema:zh-tw && npm run check:content-template:ja && npm run check:content-template:quality:ja && npm run check:faq-schema:ja && npm run check:content-template:ko && npm run check:content-template:quality:ko && npm run check:faq-schema:ko && npm run check:content-template:de && npm run check:content-template:quality:de && npm run check:faq-schema:de && npm run check:content-template:fr && npm run check:content-template:quality:fr && npm run check:faq-schema:fr && npm run postprocess:export-html-lang && npm run check:export-html-lang && npm run postprocess:export-robots-meta && npm run check:export-robots-meta && npm run build:sw",
"build": "npm run validate && npm run build:app && npm run build:post",
Expand All @@ -62,6 +62,7 @@
"test:e2e:smoke": "node scripts/e2e/run-playwright-smoke.js",
"test:e2e:pwa": "node scripts/e2e/run-playwright-smoke.js --pwa",
"check:i18n": "node scripts/gates/check-i18n.js",
"check:i18n-qa": "node scripts/gates/check-i18n-qa.js",
"check:i18n:ratchet": "node scripts/gates/check-i18n-untranslated-ratchet.js --mode=fail",
"check:i18n:ratchet:warn": "node scripts/gates/check-i18n-untranslated-ratchet.js --mode=warn",
"check:i18n:ratchet:fail": "node scripts/gates/check-i18n-untranslated-ratchet.js --mode=fail",
Expand Down
Loading