Skip to content

Docx Editor

v@eigenpal/[email protected] Feature

This release adds 2 notable features for engineering teams evaluating rollout.

✓ No known CVEs patched
Read the diff → Tool health → What is this tool? →

✓ No known CVEs patched in this version

Topics

docx docx-editor editor javascript msword next
+7 more
prosemirror react vite vue word word-editor wysiwyg

Summary

AI summary

Updates Patch Changes, Minor Changes, and Word-style across a mixed release.

Full changelog

Minor Changes

  • 5fddb75: Image layout modes (Word-style): right-click image menu and toolbar dropdown now share five directional options (In Line with Text · Square Left · Square Right · Behind Text · In Front of Text) plus Cut/Copy/Paste/Delete. Inline ↔ anchor transitions promote inline images to anchored floats at the same rendered position (Word's behavior) and back, with full OOXML round-trip. Layout helpers (hitTestImage, captureInlinePositionEmu, deriveLayoutChoice, IMAGE_LAYOUT_OPTIONS, toolbarValueToLayoutTarget) are exported from @eigenpal/docx-core/layout-painter so framework adapters share them.
  • c605277: Close 16 OOXML rendering gaps from the post-PR-#421 audit (#423): vertical anchor align, the six unhandled relativeFrom variants, bare wp:positionH/V, image crop (wp:srcRect), transparency (a:alphaModFix), wp:effectExtent shadow padding, rotation pivot, layoutInCell / allowOverlap round-trip, w:vanish / w:rtl / w:effect per-run, w:trHeight hRule="exact" enforcement, and w:noWrap on cells. w:framePr and w:cols-with-anchored-images are preserved on round-trip; visual rendering of those is left as a documented follow-up.

Patch Changes

  • aefb8c6: Serialize all integer-typed OOXML attributes (EMU and twips) as integers. Floating-point drift from arithmetic like inches * 1440 (e.g. 0.7 * 1440 === 1008.0000000000001) or (px / 96) * 914400 (e.g. cy="495299.99999999994") caused saved files to fail to open in Microsoft Word, even though tolerant readers accepted them. (fixes #417)

    Behavior changes for callers:

    • pixelsToEmu, twipsToEmu, and emuToTwips now round their result to the nearest integer. Previously they could return values like 495299.99999999994.
    • createEmptyDocument rounds pageWidth, pageHeight, and all margin* options to integer twips at the API boundary.
    • InsertImageCommand (agent.insertImage) now correctly converts width / height from pixels to EMU. Previously it multiplied pixels by 914400 instead of 9525, producing images 96× the requested size (a 100 px image became a 96-inch image). Default 100 px now produces a ~1.04-inch image, matching the documented behavior.

    Defensive: every integer-typed XML attribute in the document, paragraph, table, and run serializers now coerces its value to an integer at write time, so fractional values reaching the serializer through any code path can no longer corrupt the saved file.

  • b6c26db: Render wp:wrapNone anchored images (behind / inFront) as positioned floats instead of block images. They no longer consume paragraph flow height or create text-wrap exclusion zones, matching Word's behavior.

Weekly OSS security release digest.

The CVE patches and breaking changes that affected production tools this week. One email, every Sunday.

No spam, unsubscribe anytime.

Share this release

Track Docx Editor

Get notified when new releases ship.

Sign up free

About Docx Editor

All releases →

Related context

Earlier breaking changes

Beta — feedback welcome: [email protected]