Symptom
With the UI running in English (i18next initialized with lng: "en", English strings rendered), document.documentElement.lang is still "zh" — the static template value from index.html:2.
Expected
applyHtmlDir(initial) (src/renderer/i18n/index.ts:29) runs at module evaluation and should set <html lang> to the resolved UI language ("en" / "zh-CN"). Observed value "zh" matches neither possible output, so the call either never ran or was overwritten afterwards — needs investigation (probed via CDP on a fresh-userData dev instance, 2026-06-07).
Impact
Small but real: lang drives screen-reader pronunciation and CJK glyph selection (Han unification — lang="zh" biases Chinese glyph forms even when the UI is English). Also a correctness smell: the i18n module's DOM side effect silently not taking effect may hint at an evaluation-order issue worth understanding.
Source: side-finding during #52 investigation (2026-06-07)
Symptom
With the UI running in English (i18next initialized with
lng: "en", English strings rendered),document.documentElement.langis still"zh"— the static template value fromindex.html:2.Expected
applyHtmlDir(initial)(src/renderer/i18n/index.ts:29) runs at module evaluation and should set<html lang>to the resolved UI language ("en"/"zh-CN"). Observed value"zh"matches neither possible output, so the call either never ran or was overwritten afterwards — needs investigation (probed via CDP on a fresh-userData dev instance, 2026-06-07).Impact
Small but real:
langdrives screen-reader pronunciation and CJK glyph selection (Han unification —lang="zh"biases Chinese glyph forms even when the UI is English). Also a correctness smell: the i18n module's DOM side effect silently not taking effect may hint at an evaluation-order issue worth understanding.Source: side-finding during #52 investigation (2026-06-07)