Repository navigation
fix(i18n): grid.import 已存映射五键在 ko/de/fr/es/pt/ru/ar 补译(#3920) - #3936
Conversation
…s/pt/ru/ar (#3920) Five keys — grid.import.savedMapping, chooseSavedMapping, manualMapping, savedMappingHint and savedMappingPreviewNote — were byte-identical to en in seven of the nine non-en packs (35 values). Only zh and ja had been translated, and two of the five are multi-clause sentences, so this was not a deliberately untranslated term. Each translation reuses vocabulary the pack already ships (stepMapping for "mapping", legacyFallbackNotice for "type coercion", view.readonlyTooltip for "read-only", validateHint for "on the server"); es follows the usted ruling of objectui#3844, pt the pack's pt-BR, ru keeps its yo, fr the straight apostrophe and the space before colon/semicolon, ar U+060C/U+061B, ko the particle spelling of fields.file.exceedsMaxSize. The quote around {{name}} follows each pack's measured majority for wrapping a placeholder: de low/high German pair (38 vs 3 ASCII), fr guillemets with an ASCII space (25 vs 18), ru tight guillemets (23 vs 18), ASCII for ko (38:0), pt (39:0), es (22:19) and ar (27:15). Germanising the two de sentences closes the 45/47 gap de-quote-pairing-3876.test.ts documented; its census moves to 47/47/0 exactly as that file's header predicted, the count identity still holds, and the two keys are now pinned there by name so the empty rdqKeys list cannot become an assertion that passes because nothing is produced. en/zh/ja untouched. grid.import.transform, the sixth key in the same block and English in the same seven packs, is deliberately left alone and pinned as still-English. The general "no non-en value may equal en" gate the card proposed is not part of this change: its denominator is unmeasured. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
… grid.import.transform The pin that records `transform` as untranslated said only "that finding waits its turn"; it now names the issue, and states why that one is the sharper of the two — it is the third column header of SavedMappingSummary, rendered directly under the savedMappingHint this change translated, beside two headers that were always translated. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
|
越界发现已另立单:#3938 —— 它比本单那五个更扎眼:它是 搜重记录: Generated by Claude Code Generated by Claude Code |
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
|
✅ 验收通过(objectui 分片 PM,session 实物核验:head 要点:35 值补译逐包带术语锚点依据(es 敬称承 #3844、ru 保 ё、ar 用阿拉伯标点、ko 助词写法承既有先例);de 顺带闭合 #3876 预告的 45/47 引号缺口(恒等式仍立,普查计数按预告更新);判据措辞纠正(3546 钉的是族内规则非全局 ASCII)与两条自写断言的方向修正(de 闭引号误禁、ko 结尾符取法)诚实且正确;草稿脚本控制字节自查拦截合规。反向验证 canonical-first 型 6 红方向吻合。范围外 finding #3938(同 block 第六键)已由 PM 晋级,串行于本单合入后。 Generated by Claude Code |
…bjectstack-ai#3938) (objectstack-ai#3949) The third column header of the import wizard's saved-mapping summary was byte-identical to `en` — the literal `Transform` — in seven of the nine non-`en` packs. zh (`转换`) and ja (`変換`) had translated it, which rules out the "deliberately untranslated term" reading. It is the sixth key of the same six-line block objectui#3920 / PR objectstack-ai#3936 fixed the other five of, left out of that card only to keep its 5-keys / 35-values census verifiable against it. Each value is the singular of the word the pack already uses for `en`'s plural "transforms" in `grid.import.savedMappingHint` — the sentence `SavedMappingSummary` renders directly above this header, translated by objectstack-ai#3936: ko `변환`, de `Transformation`, fr `Transformation`, es `Transformación`, pt `Transformação`, ru `Преобразование`, ar `التحويل`. That is the anchor rather than `legacyFallbackNotice`'s term, which the card suggested: `en`'s own sentence lists "transforms" and "type coercion" as two different server-side operations and `legacyFallbackNotice` is about the second, so reusing de "Typkonvertierung" / ko "형 변환" / ar "تحويل الأنواع" here would name the wrong operation. The new test asserts each pack's coercion term is present in that sentence and absent from the header. The pin PR objectstack-ai#3936 left in `gridImportSavedMapping-i18n-3920.test.ts` asserting these seven were still English is replaced by the translated pin it asked for: 7-of-7 no longer serve the `en` value, `en`/zh/ja untouched, and all three headers of the summary row (`csvColumn`, `mapsTo`, `transform`) differ from their `en` values — the row, not the key, is the criterion. `KEYS` stays at five so objectstack-ai#3920's census remains checkable against its card. Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt Co-authored-by: Claude <noreply@anthropic.com>
Fixes #3920
前提复核(先证再改)
在
origin/main@230ffd875逐键复核,卡片前提成立:grid.import的savedMapping/chooseSavedMapping/manualMapping/savedMappingHint/savedMappingPreviewNote五键,在 ko / de / fr / es / pt / ru / ar 七包与 en 逐字节相同,合计 35 个值;只有 zh 与 ja 真的译了。其中两条是多子句说明文字,不是占位符或专名,
所以不是「刻意不译的术语」。
三道 i18n 门禁都看不见:
all-locales-key-parity只比键名集合与占位符形状(英文原文完美通过);call-site 门禁只判 key 能否解析;
check-i18n-en-drift.mjs只在 en 值变化时要求九包跟随,而这些键落地时就带着英文进的七包,从没有过「变化」事件。
译文(5 键 × 7 包 = 35 值)
savedMappingchooseSavedMappingmanualMappingsavedMappingHintsavedMappingPreviewNotesavedMappingchooseSavedMappingmanualMappingsavedMappingHintsavedMappingPreviewNotesavedMappingchooseSavedMappingmanualMappingsavedMappingHintsavedMappingPreviewNote每包「基准依据」(译文不是新造词,都取自本包既有值)
stepMapping"Zuordnung"、legacyFallbackNotice"Typkonvertierung"、view.readonlyTooltip"schreibgeschützt"、validateHint"auf dem Server";Sie 体(
downloadTemplateHint"Laden Sie … herunter");noneOption"— Keine —" 是manualMapping那对 em dash 的同族先例(同文件、上方 6 行)。stepMapping"Correspondance"、legacyFallbackNotice"conversion de type" 与"côté serveur"、
view.readonlyTooltip"en lecture seule"、validateHint"avant l'import";直撇号
'(本包 518 vs 21 弯撇);冒号/分号前带空格(冒号 59/61、问号 49/49、分号 13/14 都是U+0020,全包无窄不断空格)。
stepMapping"Asignación"、legacyFallbackNotice"conversión de tipos"、view.readonlyTooltip"solo lectura"、validateHint"en el servidor";敬称遵循objectui#3844 为本包定下的 usted(该单实测 102 usted vs 30 tú,tú 仅集中在 auth /
报表编辑器 / organizations),
grid.import本身也是 usted("Obtenga"、"revise y ajuste"、"Elija"、"Seleccione")。
stepMapping"Mapeamento"、legacyFallbackNotice"conversão de tipos"、view.readonlyTooltip"somente leitura"、validateHint"no servidor";本包是 pt-BR(registro 125 / registo 0,arquivo 17 / ficheiro 0,Salvar 19 / Guardar 0),缩合按 pt 写法
("no servidor" = em+o,"na importação" = em+a)。
stepMapping"Сопоставление"、legacyFallbackNotice"приведение типов"、view.readonlyTooltip"только для чтения"、validateHint"на сервере";保留 ё(本包 176 处)。
stepMapping"تعيين"、legacyFallbackNotice"تحويل الأنواع"、view.readonlyTooltip"للقراءة فقط"、validateHint"على الخادم";标点用阿语的U+060C 与 U+061B(本包 81 vs 2 个 ASCII 逗号、11 vs 1 个 ASCII 分号);
يدويًا与既有تلقائيًا同形;اختر تعييناً محفوظاً…沿用chooseTemplate的اختر قالباً…。stepMapping"매핑"、legacyFallbackNotice"형 변환"、view.readonlyTooltip"읽기 전용"、validateHint"서버에서";{{name}}后的助词歧义沿用本包
fields.file.exceedsMaxSize的"{{name}}"이(가)写法(占位符是动态值,作者期无法定 은/는 与 이/가),不擅自选一支。
引号排印:改用实测多数派,并说明为什么卡片引用的钉子不是本簇的判据
卡片说「其余 ASCII ——
residue-namespaces-3546.test.tsx701 行已钉住这套约定」。读了那处:701 行只钉
empty.*一族(ko/fr/es/pt/ru/ar 在那族用 ASCII),而它自己的注释写的是「引号风格跟随同包内的 sibling empty-state 值」—— 是族内规则,不是全包法令。
grid.import内没有别的带引号值可跟随(已逐行确认),所以判据落到外面一圈:每包怎么包裹一个
{{placeholder}}。剔除本单要修的两条英文残留后的实测分母:"…"«…»„…“„…“«…»«…»fr 与 ru 两包 guillemet 确实是多数派(与卡片 item 2 的建议一致),fr 内侧空格是 U+0020
(全包 25/25,无 U+202F/U+00A0),ru/es/ar 则贴紧写。es(22:19)与 ar(27:15)是接近值,
按计数落 ASCII;两包的分裂是成文批次而非语义差别(objectui#3546 各切片用 ASCII,更早的值用
guillemet),所以用多数派而不是自造的语义规则做裁决。
顺带闭合 #3876 留下的 45/47 缺口
de-quote-pairing-3876.test.ts的文件头写明:那 45 vs 47 的 2 个多出来的“正是本单这两条英文句子的开引号,并预言「把它们德语化后恒等式仍成立(47 === 47 + 0)」。
实测正如其言 —— de 全包普查从
„45 /“47 /”2 变为„47 /“47 /”0,count(“) === count(„) + count(”)依旧成立。该文件里三个字面计数已随之更新(
okSpans45 → 47、census 三元组、rdqKeys从两键清单变[]),并新增一条按键名钉这两个值的
it—— 因为只留rdqKeys === []会让断言变成「因为什么都没产出所以绿」,而这套 suite 存在的目的正是拦这种绿。#3876 自己的 20 键 / 22 span 普查表未改动:
把后续修复折进那张表会毁掉「#3876 到底动了什么」的记录。
反向验证(先声明方向,再跑)
预判方向是红(不是「计数归零反而多出诊断」那一类,因为断言钉的是 canonical 结果本身)。
把 de 五键还原成英文后实测:6 条红,指名 de 的 5 个键,普查回到 45/47/2。
一条诚实的例外要记下来:
the hint keeps the + formula那条在还原后仍然绿 ——en 原文本身就有两个
+。它不是本缺陷的探测器,只是译文形状的钉子,不应被读成「反向验证覆盖了全部断言」。
另外,两条红最先出现在我自己新写的断言上,不是译文上,都已修正并把原因写进注释:
(1) 「七包都不得含
“」对 de 是错的 —— U+201C 是德语的闭引号,该条现在只禁 en 的成对形态
“{{name}}”与”,“的单独禁令跳过 de;(2)
savedMapping的结尾符原本取 sibling 的「后两字符」,在 ko 上等于要求两个不同标签以同一个音节
릿结尾,现在改成抽取「冒号及其前导空白」(fr 空格 + 冒号、zh/ja 全角冒号都能过)。范围
auth.*.emailPlaceholder(name@example.com)、fields.image.counter(
{{current}} / {{total}})、grid.import.templateFileName、collaboration.userStatusTitle本就理应各包相同,[finding] 「同一 en 字符串必须同一译文」不能做成门禁:281 组共享 en 值里 164 组至少有一个包刻意分开译 —— 记下分母,并点出其中两组像是笔误 #3880 记录了同族的另一面。本单改为按键名钉。approvalsInbox直引号是另一单,de-quote-pairing-3876里那三键的显式清单原样保留。
grid.import.transform(同一 block 第六个键,同样在这七包是英文Transform)本单不修,另开单;并在新测试里钉成「仍是英文」,数目再漂会红,修它的人必须回来删掉那条。
验证
pnpm exec vitest run packages/i18n/ --maxWorkers=2— 34 files / 599 passed(含 parity / drift / 呼号门 /
de-quote-pairing-3876/ 新增钉子)pnpm exec turbo run type-check --concurrency=2— 78 successful, 78 totalnode scripts/check-i18n-call-site-keys.mjs— 3483 call sites,全部解析node scripts/check-i18n-en-drift.mjs—No en value changed in this range.node scripts/check-control-bytes.mjs— OK(3835 tracked text files)🤖 Generated with Claude Code
https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
Generated by Claude Code