Repository navigation
fix(muya): add missing image i18n keys ('Click to add an image' / 'Load image failed') - #4427
Merged
Merged
Conversation
…i18n keys An i18n-key audit (prompted by the #4424 heading-copy-link crash) found two more keys used via i18n.t() but absent from the locale resources. Before #4424's crash-safety fix these threw in a non-en locale; after it they displayed the raw English key. Added both to all 9 locales. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Jocs
added a commit
that referenced
this pull request
Jun 10, 2026
…4434) Fill the highest-value missing automated tests from the @muyajs/core migration regression audit — the recently-fixed bugs and data-loss-adjacent paths that had no engine coverage. - headingLocaleCrash.spec.ts (#4424/#4427 TOP priority): boots Muya under a non-en (zh-CN) locale and types `#` to create a heading, exercising the HeadingCopyLink `i18n.t` path that used to crash. Asserts no throw, the translated copy-anchor label resolves per-locale, the affordance still emits `heading-copy-link`, and `I18n.t` stays crash-safe (raw-key fall-through) for a key missing from a non-en locale. - formatToggle.spec.ts: the public `Format.format()` toggle-OFF and `clear` paths over a real boot (strong/em/del/u/mark/link/inline-code) — only the apply-side `_addFormat` was previously covered. - backspaceUnwrap.spec.ts (data-loss): Backspace-at-offset-0 cross-block surgery — paragraph merge + caret join point, and block-quote / list unwrap across all four branches (only/first/middle), asserting no item is dropped. - tableCell backspaceSafety.spec.ts (data-loss): empty-table Backspace → paragraph replacement, and previous-cell caret jump without destructive merge. - table insertRowColumn.spec.ts: insertRow/insertColumn shape, per-column alignment inheritance, delimiter round-trip, and returned caret cell — only the removal paths were previously unit-tested. All assert already-correct behavior (coverage gaps, not failing-first) and pass on current develop. Gates: lint, lint:types, check-circular, test, test:spec. Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up audit after the #4424
#-typing crash: scanned everyi18n.t('…')literal key in the muya engine against the locale resources and found 2 more missing —'Click to add an image'and'Load image failed'. Pre-#4424 these would crash in a non-enlocale; post-#4424 they render the raw English key. Added both to all 9 locales (en/zh-CN/zh-TW/de/es/fr/ja/ko/pt). Re-audit: 0 missing. lint/lint:types/test (581) green.