fix(deps): update superdoc#41
Merged
Merged
Conversation
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.
This PR contains the following updates:
0.8.0-next.122→0.11.0-next.21.8.0-next.105→1.10.0-next.21.30.0-next.101→1.34.0-next.2Release Notes
superdoc-dev/superdoc (superdoc)
v1.34.0-next.2Compare Source
Bug Fixes
Features
v1.34.0-next.1Compare Source
Bug Fixes
Features
v1.33.1Compare Source
Fixed
showFormattingMarksButtonconfiguration flag. Setmodules.toolbar.showFormattingMarksButton = trueto restore the button. This gives developers more control over the default toolbar layout, distinct from thelayoutEngineOptions.showFormattingMarkssetting which controls whether marks render in the document.v1.33.0Compare Source
What's New
Custom XML Data Storage Parts API — Full read/write access to custom XML parts via
document.customXml.parts.list(),get(),create(),patch(), andremove(). Supports filtering by namespace, schema references, and partName. Handles OOXML package coordination (storage parts, properties parts, relationships) automatically.EMF+ image extraction — Render EMF+ images by extracting embedded bitmaps from EMF+ payloads. Supports compressed PNG/JPEG extraction and raw pixel formats (24/32-bit RGB/ARGB). Falls back to placeholder for vector-only EMF+ files.
Images inside Word textboxes — Inline drawings now render alongside text inside Word textbox content. Displays at baseline with proper alt-text support.
Paragraph direction toolbar — New headless toolbar entries
direction-ltranddirection-rtlfor programmatic paragraph direction control. Direction buttons can be added to custom toolbars via the headless toolbar API.TOC programmatic update — Update table of contents entries via
editor.toc.update()with options to refresh page numbers, rebuild entries, or change configuration (tab leaders, indentation).Fixes
RTL/Logical direction preservation — Paragraph
w:bidi, tablew:bidiVisual, and cell marginsw:tcMarwith logicalstart/endkeys now preserve correctly on round-trip. Table visual direction (cell ordering) respects explicitw:bidiVisual w:val="0"overrides.RTL date rendering parity — Date tokens inside RTL runs render in correct visual order matching Word (via directional isolation and RLM injection for separators).
RTL paragraph alignment mirroring — Left/right alignment on RTL paragraphs mirrors to stored OOXML justification (
left↔right,centerunchanged). LTR paragraphs unaffected.Tracked changes + comments round-trip — Comments anchored to tracked changes now re-thread correctly on re-import. Cascade resolution of tracked-change acceptance resolves anchored user comments in one action. Reply nesting under TC bubbles preserved across save/reopen.
Slash command menu dismissal — Backspace/Delete now close the menu without inserting the slash. Escape closes and inserts the slash. Subsequent
/immediately reopens the menu (no cooldown). Search header and empty state now visible while filtering.Content control mutations under lock — Locked SDTs (
sdtLocked) now accept programmatic mutations (text.setValue,replaceContent,appendContent,setLockMode) via attribute steps and inner-range writes. Lock mode (read-only, form-fill) still enforced by API guards.Toolbar dropdown keyboard focus — Enter on a dropdown button now reopens the dropdown after Escape, and space/enter properly navigate inside the dropdown menu.
Comment highlight specificity — Search highlights and comment highlights no longer suppress each other. Lock-hover styling excluded from hidden content controls.
Header/footer missing in collaboration — Headers and footers no longer disappear when opening shared documents in collaboration mode.
Finding cross-page matches — Search results now reliably scroll into view on Enter/click. Focus restored to find input after navigation to prevent document mutations.
SVG image import — SVG images in imported DOCX files now render with correct MIME type.
Numbered list preservation — Numbering.xml definitions (both active and tentative lists) now round-trip unchanged. Blank documents no longer gain unused numbering definitions on export.
Hyperlink preservation in tracked changes — Hyperlinks inside tracked changes now survive export/re-import with proper marking. Pasted URLs get correct underline handling on unlink.
Paragraph margin normalization —
w:pgMarattributes with float-valued twips round to integers on export per ECMA-376ST_TwipsMeasure.Highlight marks on round-trip — Complex-script (
w:bCs), italic-complex-script (w:iCs), and highlight toggles no longer inject phantom elements on export when absent from source.Content control type defaults — New content controls now default to
richText(ECMA-376 compliant) instead ofunknown. Imported typeless Word controls resolve torichTextcorrectly.Run-level bidi/script metadata — Text runs now preserve
w:rtlflag and complex-script (w:cs) + language tag metadata for Wave 1b/1c rendering pipelines.Document API offset alignment — Bookmark/citation offsets now match the flattened text model used for writes. Round-trip write-then-read returns the same offset.
Package shape hardening — Package exports now pass consumer typecheck matrix and package integrity audits. All public types verified free of tier-4-any exports.
Improvements
Viewport entity surface — Content controls now expose hit-testing and rect-lookup on the viewport surface (same as comments and tracked changes).
getRect({ target: { type: 'contentControl', ... } })returns painted rects without data-attribute scraping.Hidden content control appearance — Content controls with
appearance:hiddennow render fully transparent. No padding, border, or hover state. Alias labels excluded from copy-paste and screen readers.Type precision on awareness — Collaboration awareness state now types
AwarenessStateinstead ofany[], exposing documented fields (name,email,image,clientId,color).Direction context resolver chain — New
@superdoc/contractsmodule centralizes paragraph/table/section/cell direction resolution with per-axis separation (inline vs visual vs writing mode). Eliminates spec violations where section RTL leaked to paragraphs.Table cell margin precedence — Cell-level
w:tcMarnow correctly overrides table-levelw:tblCellMardefaults in both LTR and RTL tables.Table border/margin logical sides — Table borders and cell margins using logical
start/endkeys map to physical sides with RTL-aware fallback. Single visual mirror point (DomPainter) eliminates double-mirror bugs.Theme font preservation — Paragraph runs with
w:*Themefont slots (w:asciiTheme,w:hAnsiTheme,w:cstheme,w:eastAsiaTheme) now survive round-trip. User font overrides drop theme refs correctly.Comment reference styling — Synthesized comment anchor runs now emit
w:rStyle w:val="CommentReference"matching Word's canonical output.TOC rebuild on schema mismatch — Table of contents updates now sanitize nested marks when the consumer schema omits
tocPageNumber, preventing import failures.Indent command cache fallback — Increase/Decrease Indent now compute on-miss instead of crashing when fired before rendering pass completes.
Error type precision —
ProofingError.causenow types asunknown(correctly opaque).EditorTransactionEvent.transactionnow types as ProseMirrorTransaction.v1.32.0Compare Source
What's New
<w:docPartObj>wrappers transparently in tables and structured content blocks, preventing silent content loss.tables.applyPresetfor visual styling;lists.deleteremoves entire list sequences.ui.viewport.getHost(),positionAt(),contextAt()for coordinate resolution;ui.selection.getRects(),getAnchorRect()for geometry;ui.commands.has(),require()for typed registry; context-menu contribution API;ui.selection.restore(capture)with story-scoping;ui.createScope()for lifecycle management;observe()aliases on all handles; shortcut binding at registration.type-surface.config.cjssource of truth; 53 consumer-typecheck scenarios with skipLibCheck:false; drained 6 shims; explicittypeson converter/docx-zipper/file-zipper subpaths.Improvements
<w:del>/<w:ins>wrappers on split fields.disableContextMenu: trueso browser menus work.Fixes
document.xml.rels,[Content_Types].xml) now properly escaped on export.v1.31.2Compare Source
Fixes
v1.31.1Compare Source
Fixes
v1.31.0Compare Source
What's New
Improvements
Breaking Changes
v1.30.1Compare Source
Based on my analysis of the changes, here are the release notes:
Breaking Changes
Removed
ui.reviewAPI — The merged comments + tracked-changes feed shipped in an earlier release turned out to be speculative; no customer actually needed the merged view. Building review sidebars now requires composingui.comments.itemsandui.trackChanges.itemsdirectly (roughly 30 lines of code, demonstrated in the BYO-UI demo's ActivitySidebar).Renamed
useSuperDocReviewtouseSuperDocTrackChanges— The hook now returns tracked changes only, mirroring the structure ofuseSuperDocComments. Signature:(items, total, activeId).Improvements
Simplified
ui.trackChangesdomain — Separated tracked changes from comments, keeping eachui.<domain>namespace focused on one document-API domain. The controller surface is now tighter and layering is more predictable.ui.trackChangesexposesitems/total/activeIdfor observation plusaccept/reject/acceptAll/rejectAll/next/previous/scrollTofor navigation and mutations.Documentation
Clarified
useSuperDocTrackChangesreturn type — JSDoc now explicitly documents the return shape as(items, total, activeId), matching the pattern set byuseSuperDocComments.v1.30.0Compare Source
What's New
UI Controller —
createSuperDocUI({ superdoc })gives you a browser-side state controller for building custom sidebars, toolbars, and selection-driven UIs without reaching into editor internals. Select any slice of state (selection, toolbar, comments, tracked changes, viewport geometry) and subscribe.React hooks —
SuperDocUIProvider,useSuperDocUI,useSuperDocSlice,useSuperDocSelection,useSuperDocComments,useSuperDocReview,useSuperDocToolbar, anduseSuperDocCommandeliminate per-project glue code. Provider creates one controller per app, handles cleanup, no stale-closure bugs.Selection primitives —
editor.doc.selection.current()returnsSelectionInfowith the active range, activeMarks, activeCommentIds, activeChangeIds — everything a floating toolbar needs.editor.doc.selection.onChange()subscribes to changes. No ProseMirror internals required.Multi-block comments —
comments.createnow acceptsTextTargetwith multiple segments, so drag-selecting across paragraphs anchors a comment across all of them instead of silently collapsing.Comment reopen — Implements the inverse of resolve.
comments.patch({ status: 'active' })re-inserts the comment mark and removes anchor nodes, round-tripping through DOCX.Custom toolbar commands —
ui.commands.register({ id, execute, getState })adds custom buttons (AI rewrite, insert mention, internal workflows) to the same surface as built-ins. Custom state binds to external app signals viainvalidate().Tracked change anchors —
extract()now includesblock.textSpansmapping each change to exact text, plusblockIdsandwordRevisionIdsfor navigation — no more ambiguous excerpts when words repeat.Selection.capture() — Freeze addressable selection when a composer opens (before focus shifts). Pass the captured target directly to
comments.createon submit.ui.viewport.getRect() — Get rects for sticky cards anchored to comments or changes. Returns success/failure with reason (not-ready, invalid-target, unresolved, not-mounted).
Extra bullet styles — Square and circle bullets alongside disc (default).
Improvements
Selection in state —
ui.select(s => s.selection, ...)now exposestarget,activeMarks,activeCommentIds,activeChangeIdsalongsideemptyandquotedText. One subscription covers floating-menu, format-toolbar, and mention-popover needs.Per-command observables —
ui.commands.bold.observe(({ active, disabled }) => ...)lets a 50-button toolbar re-render only the changed button instead of the whole bar.Toolbar command routing — All dispatch paths (per-id, per-command, aggregate) use the same resolver so custom overrides (
register({ override: true })) apply everywhere.Viewport scrolling —
editor.doc.ranges.scrollIntoView({ target, block?, behavior? })handles paginated/virtualized layouts, mounts pages on demand, works for text or entity targets (comment/change by id).Host-routed decisions — Tracked change accept/reject routes through the document host editor (not child editors), so decisions apply document-wide.
Story-aware scroll —
ui.comments.scrollTo()andui.review.scrollTo()preserve story metadata so non-body comments (headers, footers, notes) anchor correctly.Reviewer merge & split — Lists can merge adjacent items or split at a selected position via
lists.merge()/lists.split().Child editor telemetry — Story editors (headers, footers, footnotes) skip document-open telemetry; only the primary editor reports.
Fixes
Comment activation — Non-collapsed selections no longer flicker the active comment. Clicks on tracked changes inside comments preserve the activation.
Line break rendering — Manual line breaks now render faithfully in all contexts.
Table clicks — Clicks in table gaps no longer jump the cursor to a different page or select the wrong paragraph.
Footer alignment — Page numbers and footer content align correctly even with malformed spacing metadata.
Floating textboxes — DrawingML shapes that re-prefix namespaces (e.g.
ns6:graphicinstead ofa:graphic) now render.Bullet style export — Picking square/circle styles exports to DOCX with matching
w:lvlTextmarkers.Comments export — Comments from Word-native range-based files export in the correct format instead of being merged incorrectly.
Symbol font stripping — Transitioning from bullet to ordered lists strips symbol fonts so numbered markers render without interference.
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.
This PR was generated by Mend Renovate. View the repository job log.