@stll/folio-core 0.62.0 → 0.63.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -6
- package/dist/ai-edits/apply.d.ts +40 -10
- package/dist/ai-edits/apply.js +563 -219
- package/dist/ai-edits/batch-claims.d.ts +13 -4
- package/dist/ai-edits/batch-claims.js +6 -6
- package/dist/ai-edits/block-identity.d.ts +3 -4
- package/dist/ai-edits/block-identity.js +15 -1
- package/dist/ai-edits/blockRange.d.ts +7 -7
- package/dist/ai-edits/blockRange.js +2 -1
- package/dist/ai-edits/character-boundaries.d.ts +5 -6
- package/dist/ai-edits/clean-text.d.ts +8 -8
- package/dist/ai-edits/comment-lifecycle.d.ts +15 -6
- package/dist/ai-edits/comment-lifecycle.js +74 -23
- package/dist/ai-edits/headless.d.ts +42 -39
- package/dist/ai-edits/headless.js +157 -114
- package/dist/ai-edits/index.d.ts +2 -1
- package/dist/ai-edits/index.js +2 -1
- package/dist/ai-edits/inline-emphasis.d.ts +5 -6
- package/dist/ai-edits/minimal-replacement.d.ts +12 -13
- package/dist/ai-edits/newListNumbering.d.ts +16 -3
- package/dist/ai-edits/newListNumbering.js +97 -34
- package/dist/ai-edits/note-references.d.ts +14 -14
- package/dist/ai-edits/note-story-inventory.d.ts +2 -2
- package/dist/ai-edits/pending-suggestions.d.ts +8 -8
- package/dist/ai-edits/pending-suggestions.js +5 -1
- package/dist/ai-edits/read.d.ts +10 -11
- package/dist/ai-edits/read.js +6 -0
- package/dist/ai-edits/referenceClassification.d.ts +2 -2
- package/dist/ai-edits/removed-blocks.d.ts +20 -0
- package/dist/ai-edits/removed-blocks.js +69 -0
- package/dist/ai-edits/result-validation.d.ts +4 -5
- package/dist/ai-edits/result-validation.js +4 -3
- package/dist/ai-edits/revisionStretches.d.ts +3 -3
- package/dist/ai-edits/revisionStretches.js +17 -0
- package/dist/ai-edits/scoped-reading.d.ts +3 -4
- package/dist/ai-edits/snapshot.d.ts +24 -23
- package/dist/ai-edits/snapshot.js +44 -30
- package/dist/ai-edits/table-cell-mutations.d.ts +6 -6
- package/dist/ai-edits/table-cell-mutations.js +7 -4
- package/dist/ai-edits/table-geometry.d.ts +6 -6
- package/dist/ai-edits/table-mutation-plan.d.ts +5 -5
- package/dist/ai-edits/table-mutation-plan.js +1 -4
- package/dist/ai-edits/table-row-column-mutations.d.ts +16 -16
- package/dist/ai-edits/table-targets.d.ts +8 -9
- package/dist/ai-edits/table-template.d.ts +6 -6
- package/dist/ai-edits/types.d.ts +48 -44
- package/dist/ai-edits/word-diff.d.ts +12 -13
- package/dist/ai-edits/word-diff.js +23 -21
- package/dist/ai-suggestions/apply.d.ts +3 -3
- package/dist/ai-suggestions/apply.js +0 -12
- package/dist/ai-suggestions/conflict.d.ts +4 -5
- package/dist/ai-suggestions/conflict.js +3 -1
- package/dist/ai-suggestions/text-positions.d.ts +3 -4
- package/dist/ai-suggestions/types.d.ts +13 -14
- package/dist/compare/column-alignment.d.ts +4 -5
- package/dist/compare/compare.d.ts +12 -12
- package/dist/compare/compare.js +2 -1
- package/dist/compare/content-alignment.d.ts +16 -16
- package/dist/compare/content-alignment.js +29 -25
- package/dist/compare/content-types.d.ts +23 -24
- package/dist/compare/content.d.ts +27 -27
- package/dist/compare/content.js +6 -3
- package/dist/compare/formatting.d.ts +2 -2
- package/dist/compare/import-style-closure.d.ts +2 -2
- package/dist/compare/inline-atom-resources.d.ts +2 -3
- package/dist/compare/inline-atoms.d.ts +6 -7
- package/dist/compare/inline-provenance.d.ts +6 -7
- package/dist/compare/inline-provenance.js +22 -20
- package/dist/compare/inserted-resource-snapshot.d.ts +3 -3
- package/dist/compare/plan.d.ts +5 -6
- package/dist/compare/plan.js +5 -6
- package/dist/compare/reproducible-package.d.ts +2 -3
- package/dist/compare/reproducible-package.js +1 -1
- package/dist/compare/scenario.d.ts +9 -9
- package/dist/compare/section-boundary-properties.d.ts +6 -6
- package/dist/compare/section-boundary-properties.js +4 -4
- package/dist/compare/style-resources.d.ts +5 -6
- package/dist/compare/types.d.ts +29 -28
- package/dist/compare/types.js +14 -7
- package/dist/compare/verification.d.ts +11 -11
- package/dist/content-controls/checkboxDisplay.d.ts +2 -2
- package/dist/content-controls/checkboxDisplay.js +2 -1
- package/dist/content-controls/errors.d.ts +8 -7
- package/dist/content-controls/errors.js +6 -3
- package/dist/content-controls/findContentControls.d.ts +7 -8
- package/dist/content-controls/mutateContentControls.d.ts +17 -6
- package/dist/content-controls/mutateContentControls.js +3 -2
- package/dist/controller/activeEditorStory.d.ts +4 -5
- package/dist/controller/canonicalClipboard.d.ts +3 -3
- package/dist/controller/canonicalClipboard.js +3 -1
- package/dist/controller/canonicalClipboardResources.d.ts +3 -3
- package/dist/controller/canonicalClipboardResources.js +3 -2
- package/dist/controller/canonicalComments.d.ts +7 -6
- package/dist/controller/canonicalComments.js +2 -1
- package/dist/controller/canonicalComposition.d.ts +2 -2
- package/dist/controller/canonicalComposition.js +11 -14
- package/dist/controller/canonicalInlineProjection.d.ts +11 -10
- package/dist/controller/canonicalInlineProjection.js +70 -38
- package/dist/controller/canonicalInput.d.ts +3 -3
- package/dist/controller/canonicalInput.js +1 -3
- package/dist/controller/canonicalInputTimer.d.ts +5 -6
- package/dist/controller/canonicalListRendering.d.ts +6 -5
- package/dist/controller/canonicalOperations.d.ts +6 -6
- package/dist/controller/canonicalPublicOperations.d.ts +13 -13
- package/dist/controller/canonicalPublicOperations.js +14 -15
- package/dist/controller/canonicalReview.d.ts +2 -2
- package/dist/controller/canonicalSelection.d.ts +2 -2
- package/dist/controller/canonicalSelection.js +15 -0
- package/dist/controller/canonicalSession.d.ts +25 -17
- package/dist/controller/canonicalSession.js +231 -43
- package/dist/controller/canonicalStoryEditor.d.ts +2 -2
- package/dist/controller/canonicalStructure.d.ts +3 -3
- package/dist/controller/canonicalStructure.js +144 -21
- package/dist/controller/canonicalTocSelection.d.ts +2 -2
- package/dist/controller/collaborationModules.d.ts +2 -3
- package/dist/controller/committedLayoutDiff.d.ts +4 -5
- package/dist/controller/contentControlWidgetController.d.ts +7 -8
- package/dist/controller/folioEditor.d.ts +6 -6
- package/dist/controller/folioEditorEvents.d.ts +7 -8
- package/dist/controller/fontReadiness.d.ts +12 -12
- package/dist/controller/fontReadiness.js +123 -31
- package/dist/controller/headerFooterEditorManager.d.ts +9 -10
- package/dist/controller/headerFooterEditorManager.js +3 -10
- package/dist/controller/hiddenEditorApi.d.ts +5 -5
- package/dist/controller/hiddenEditorManager.d.ts +15 -14
- package/dist/controller/hiddenEditorManager.js +4 -1
- package/dist/controller/hyphenationReadiness.d.ts +4 -5
- package/dist/controller/hyphenationReadiness.js +0 -1
- package/dist/controller/latestRequestGate.d.ts +3 -4
- package/dist/controller/layoutPipeline.d.ts +7 -8
- package/dist/controller/layoutPipeline.js +16 -5
- package/dist/controller/layoutRunOptions.d.ts +4 -5
- package/dist/controller/layoutScheduler.d.ts +8 -9
- package/dist/controller/layoutSession.d.ts +7 -7
- package/dist/controller/noteEditorManager.d.ts +7 -7
- package/dist/controller/noteEditorManager.js +0 -1
- package/dist/controller/readOnlySelection.d.ts +12 -0
- package/dist/controller/readOnlySelection.js +62 -0
- package/dist/display-list/build/buildContext.d.ts +8 -6
- package/dist/display-list/build/buildDisplayList.d.ts +6 -6
- package/dist/display-list/build/buildDisplayList.js +20 -2
- package/dist/display-list/build/colors.d.ts +6 -7
- package/dist/display-list/build/commentAnnotations.d.ts +3 -4
- package/dist/display-list/build/floatingImages.d.ts +5 -6
- package/dist/display-list/build/fontTable.d.ts +4 -5
- package/dist/display-list/build/fontTable.js +2 -1
- package/dist/display-list/build/furniture.d.ts +7 -6
- package/dist/display-list/build/furniture.js +1 -0
- package/dist/display-list/build/glyphs.d.ts +7 -7
- package/dist/display-list/build/glyphs.js +17 -26
- package/dist/display-list/build/headerFooterPrimitives.d.ts +4 -5
- package/dist/display-list/build/headerFooterPrimitives.js +5 -1
- package/dist/display-list/build/imagePrimitives.d.ts +5 -5
- package/dist/display-list/build/imagePrimitives.js +0 -10
- package/dist/display-list/build/pageBorderPrimitives.d.ts +4 -5
- package/dist/display-list/build/pageBorderPrimitives.js +8 -11
- package/dist/display-list/build/pageFurniture.d.ts +6 -7
- package/dist/display-list/build/pageFurniture.js +5 -1
- package/dist/display-list/build/paragraphPrimitives.d.ts +5 -4
- package/dist/display-list/build/paragraphPrimitives.js +138 -108
- package/dist/display-list/build/previewPrimitives.d.ts +2 -3
- package/dist/display-list/build/previewPrimitives.js +38 -9
- package/dist/display-list/build/regions.d.ts +5 -5
- package/dist/display-list/build/storyPrimitives.d.ts +4 -4
- package/dist/display-list/build/strokes.d.ts +10 -10
- package/dist/display-list/build/tablePrimitives.d.ts +5 -5
- package/dist/display-list/build/tablePrimitives.js +15 -2
- package/dist/display-list/build/textBoxPrimitives.d.ts +3 -4
- package/dist/display-list/build/textBoxPrimitives.js +4 -0
- package/dist/display-list/build/textDecorations.d.ts +10 -11
- package/dist/display-list/build/unsupported.d.ts +4 -5
- package/dist/display-list/build/watermarkPrimitives.d.ts +5 -4
- package/dist/display-list/build/watermarkPrimitives.js +5 -17
- package/dist/display-list/dom/renderDisplayListToDom.d.ts +8 -8
- package/dist/display-list/dom/renderDisplayListToDom.js +52 -10
- package/dist/display-list/editor/displayListPagePainter.d.ts +4 -5
- package/dist/display-list/editor/pageRenderer.d.ts +5 -6
- package/dist/display-list/editor/pageRenderer.js +1 -0
- package/dist/display-list/html/renderDisplayListToHtml.d.ts +5 -6
- package/dist/display-list/pageResourceOwnership.d.ts +4 -0
- package/dist/display-list/pageResourceOwnership.js +32 -0
- package/dist/display-list/primitives.d.ts +13 -13
- package/dist/display-list/primitives.js +2 -0
- package/dist/display-list/selectDisplayPages.d.ts +2 -3
- package/dist/display-list/types.d.ts +54 -33
- package/dist/document-operations.d.ts +59 -46
- package/dist/document-operations.js +41 -4
- package/dist/document-stories.d.ts +3 -4
- package/dist/docx/altChunk.d.ts +5 -6
- package/dist/docx/appVersionNormalization.d.ts +6 -5
- package/dist/docx/appVersionNormalization.js +2 -1
- package/dist/docx/archiveInflation.d.ts +16 -16
- package/dist/docx/archiveInflation.js +1 -1
- package/dist/docx/attributeRemainder.d.ts +10 -9
- package/dist/docx/attributeRemainder.js +36 -1
- package/dist/docx/blockContentParser.d.ts +15 -7
- package/dist/docx/blockContentParser.js +5 -6
- package/dist/docx/blockCustomXmlShell.d.ts +2 -3
- package/dist/docx/blockPlainText.d.ts +3 -4
- package/dist/docx/blockPlainText.js +5 -1
- package/dist/docx/bookmarkIdNormalization.d.ts +2 -3
- package/dist/docx/bookmarkIds.d.ts +5 -6
- package/dist/docx/bookmarkParser.d.ts +20 -21
- package/dist/docx/bookmarkParser.js +3 -2
- package/dist/docx/borderParser.d.ts +2 -3
- package/dist/docx/builtInStyles.d.ts +11 -11
- package/dist/docx/bulletMarkers.d.ts +8 -3
- package/dist/docx/bulletMarkers.js +3 -43
- package/dist/docx/canonicalModel.d.ts +2 -0
- package/dist/docx/canonicalModel.js +1 -0
- package/dist/docx/canonicalResourceSave.d.ts +5 -4
- package/dist/docx/canonicalResourceSave.js +2 -1
- package/dist/docx/canonicalSave.d.ts +8 -6
- package/dist/docx/canonicalSave.js +2 -1
- package/dist/docx/canonicalSessionInput.d.ts +5 -4
- package/dist/docx/canonicalSessionInput.js +2 -1
- package/dist/docx/canonicalStoryRepack.d.ts +2 -2
- package/dist/docx/chartPreview.d.ts +6 -0
- package/dist/docx/chartPreview.js +302 -0
- package/dist/docx/commentAnchorIndex.d.ts +6 -5
- package/dist/docx/commentAnchorIndex.js +236 -1
- package/dist/docx/commentIdNormalization.d.ts +4 -5
- package/dist/docx/commentParser.d.ts +4 -5
- package/dist/docx/commentParser.js +2 -1
- package/dist/docx/commentRangeIntegrity.d.ts +6 -5
- package/dist/docx/commentRangeIntegrity.js +17 -1
- package/dist/docx/commentRangeJoin.d.ts +2 -3
- package/dist/docx/commentReferenceCompletion.d.ts +2 -3
- package/dist/docx/commentReferenceNormalization.d.ts +4 -4
- package/dist/docx/commentReplyMarkers.d.ts +3 -4
- package/dist/docx/commentTextParagraph.d.ts +2 -3
- package/dist/docx/commentThreadKey.d.ts +2 -3
- package/dist/docx/compatibility.d.ts +12 -13
- package/dist/docx/conformance.d.ts +2 -3
- package/dist/docx/conformance.js +1 -1
- package/dist/docx/containerChildren.d.ts +18 -18
- package/dist/docx/containerChildren.gen.d.ts +5 -6
- package/dist/docx/contentTypeRegistry.d.ts +2 -2
- package/dist/docx/corePropertiesParser.d.ts +2 -2
- package/dist/docx/danglingRelationshipReferences.d.ts +3 -3
- package/dist/docx/defaultParagraphStyle.d.ts +6 -6
- package/dist/docx/diagramPreview.d.ts +5 -4
- package/dist/docx/diagramPreview.js +8 -3
- package/dist/docx/documentClone.js +1 -2
- package/dist/docx/documentGrid.d.ts +2 -2
- package/dist/docx/documentParser.d.ts +11 -11
- package/dist/docx/documentSectionFacts.d.ts +5 -6
- package/dist/docx/drawingAnchor.d.ts +14 -14
- package/dist/docx/drawingGroupChildren.d.ts +8 -8
- package/dist/docx/drawingIdNormalization.d.ts +3 -4
- package/dist/docx/drawingRelationships.d.ts +2 -2
- package/dist/docx/drawingUtils.d.ts +16 -17
- package/dist/docx/drawingUtils.js +4 -2
- package/dist/docx/encryption/agileDecryption.d.ts +2 -3
- package/dist/docx/encryption/compoundFile.d.ts +5 -6
- package/dist/docx/encryption/containerFormat.d.ts +4 -5
- package/dist/docx/encryption/cryptoBytes.d.ts +8 -9
- package/dist/docx/encryption/encryptionInfo.d.ts +5 -6
- package/dist/docx/encryption/errors.d.ts +7 -6
- package/dist/docx/encryption/errors.js +2 -1
- package/dist/docx/encryption/openEncryptedDocx.d.ts +5 -6
- package/dist/docx/ensureParaIds.d.ts +8 -7
- package/dist/docx/ensureParaIds.js +3 -2
- package/dist/docx/fieldParser.d.ts +32 -33
- package/dist/docx/fieldParser.js +8 -6
- package/dist/docx/fieldState.d.ts +5 -6
- package/dist/docx/foldedListNumberFields.d.ts +15 -16
- package/dist/docx/fontTableParser.d.ts +2 -3
- package/dist/docx/footnoteParser.d.ts +11 -11
- package/dist/docx/footnoteParser.js +19 -0
- package/dist/docx/graphicFrameLocks.d.ts +5 -6
- package/dist/docx/groupDrawingParser.d.ts +4 -5
- package/dist/docx/groupDrawingParser.js +10 -5
- package/dist/docx/headerFooterParser.d.ts +14 -14
- package/dist/docx/headerFooterRefParser.d.ts +6 -7
- package/dist/docx/headerFooterReferenceNormalization.d.ts +5 -5
- package/dist/docx/headerFooterVerbatim.d.ts +16 -16
- package/dist/docx/hyperlinkParser.d.ts +20 -21
- package/dist/docx/hyperlinkParser.js +54 -11
- package/dist/docx/imageParser.d.ts +19 -19
- package/dist/docx/imageParser.js +6 -3
- package/dist/docx/imageRawXml.d.ts +9 -10
- package/dist/docx/importedIdCollisions.d.ts +3 -4
- package/dist/docx/index.d.ts +1 -0
- package/dist/docx/inlineContentRemovals.d.ts +2 -3
- package/dist/docx/inlineWrapperContent.d.ts +38 -33
- package/dist/docx/inlineWrapperContent.js +29 -23
- package/dist/docx/inlineWrapperParser.d.ts +4 -5
- package/dist/docx/inlineWrapperParser.js +14 -0
- package/dist/docx/linkedSdtPreservation.d.ts +6 -4
- package/dist/docx/linkedSdtPreservation.js +2 -1
- package/dist/docx/listMarkerComputation.d.ts +4 -5
- package/dist/docx/listModelNormalization.d.ts +2 -2
- package/dist/docx/listModelNormalization.js +15 -11
- package/dist/docx/listNumberingInstances.d.ts +8 -8
- package/dist/docx/listRendering.d.ts +5 -6
- package/dist/docx/listTemplate.d.ts +5 -5
- package/dist/docx/markupRangeMarker.d.ts +21 -4
- package/dist/docx/markupRangeMarker.js +35 -1
- package/dist/docx/mathToMathml.d.ts +8 -3
- package/dist/docx/mathToMathml.js +72 -4
- package/dist/docx/metadataPrivacy.d.ts +17 -16
- package/dist/docx/metadataPrivacy.js +7 -5
- package/dist/docx/metafileRaster.d.ts +4 -5
- package/dist/docx/metafileSvg.d.ts +2 -3
- package/dist/docx/metafileSvg.js +28 -39
- package/dist/docx/metafileSvgShared.d.ts +27 -0
- package/dist/docx/metafileSvgShared.js +28 -0
- package/dist/docx/modelValidation.d.ts +5 -6
- package/dist/docx/modelValidation.js +144 -1
- package/dist/docx/newImage.d.ts +2 -3
- package/dist/docx/nonVisualDrawingProps.d.ts +3 -3
- package/dist/docx/normalizeBaseDirection.d.ts +2 -3
- package/dist/docx/normalizeBaseDirection.js +6 -2
- package/dist/docx/noteIds.d.ts +2 -3
- package/dist/docx/notePropertiesParser.d.ts +3 -4
- package/dist/docx/noteReferenceMark.d.ts +6 -6
- package/dist/docx/noteReferenceStyles.d.ts +7 -8
- package/dist/docx/noteReferenceStyles.js +0 -13
- package/dist/docx/numberingIds.d.ts +3 -3
- package/dist/docx/numberingParser.d.ts +15 -16
- package/dist/docx/numberingParser.js +6 -30
- package/dist/docx/numberingReference.d.ts +2 -2
- package/dist/docx/numberingReferenceNormalization.d.ts +5 -5
- package/dist/docx/numberingReferenceNormalization.js +6 -9
- package/dist/docx/numericIdAllocator.d.ts +2 -2
- package/dist/docx/numericIdAllocator.js +2 -1
- package/dist/docx/numericIdNormalization.d.ts +3 -3
- package/dist/docx/numericIdNormalization.js +0 -1
- package/dist/docx/ooxmlCounterFormatter.d.ts +3 -4
- package/dist/docx/opaqueCarrier.d.ts +5 -6
- package/dist/docx/packageParts.d.ts +8 -9
- package/dist/docx/paraIdAttribute.d.ts +11 -12
- package/dist/docx/paraIdRangeNormalization.d.ts +3 -4
- package/dist/docx/paragraphMarkPropertyPresence.d.ts +4 -5
- package/dist/docx/paragraphParser.d.ts +9 -9
- package/dist/docx/paragraphParser.js +45 -23
- package/dist/docx/paragraphProperties.d.ts +2 -3
- package/dist/docx/paragraphProperties.js +15 -2
- package/dist/docx/paragraphPropertySource.d.ts +58 -57
- package/dist/docx/paragraphPropertySource.js +39 -2
- package/dist/docx/paragraphTextBoxEnrichment.d.ts +2 -3
- package/dist/docx/paragraphTextBoxEnrichment.js +21 -6
- package/dist/docx/paragraphTraversal.d.ts +19 -10
- package/dist/docx/paragraphTraversal.js +110 -75
- package/dist/docx/parseContext.d.ts +5 -6
- package/dist/docx/parseWarningMessage.d.ts +3 -4
- package/dist/docx/parser.d.ts +13 -12
- package/dist/docx/parser.js +45 -16
- package/dist/docx/parserEnums.d.ts +37 -38
- package/dist/docx/preservedRunContent.d.ts +5 -6
- package/dist/docx/preservedRunContent.js +16 -0
- package/dist/docx/previewBudget.d.ts +6 -6
- package/dist/docx/previewBudget.js +1 -1
- package/dist/docx/propertyElementAttributes.d.ts +10 -11
- package/dist/docx/rasterMime.d.ts +4 -4
- package/dist/docx/relsParser.d.ts +20 -21
- package/dist/docx/removeHeaderFooterParts.d.ts +2 -2
- package/dist/docx/renderedPageBreakNormalization.d.ts +2 -2
- package/dist/docx/replyToComment.d.ts +4 -5
- package/dist/docx/replyToComment.js +2 -1
- package/dist/docx/reviewHistoryNamespace.d.ts +2 -3
- package/dist/docx/reviewResolutionProvenance.d.ts +17 -13
- package/dist/docx/reviewResolutionProvenance.js +17 -5
- package/dist/docx/revisionIdNormalization.d.ts +6 -5
- package/dist/docx/revisionIdNormalization.js +2 -1
- package/dist/docx/rezip.d.ts +43 -42
- package/dist/docx/rezip.js +117 -125
- package/dist/docx/runConsolidator.d.ts +7 -7
- package/dist/docx/runConsolidator.js +13 -0
- package/dist/docx/runParser.d.ts +12 -13
- package/dist/docx/runParser.js +31 -10
- package/dist/docx/runPayload.d.ts +2 -3
- package/dist/docx/runPropertyPresence.d.ts +7 -8
- package/dist/docx/saveDiagnostics.d.ts +3 -4
- package/dist/docx/sdtProperties.d.ts +6 -7
- package/dist/docx/sdtPropertiesPatch.d.ts +2 -3
- package/dist/docx/sectionParser.d.ts +15 -16
- package/dist/docx/sectionReferenceHistory.d.ts +8 -7
- package/dist/docx/sectionReferenceHistory.js +2 -1
- package/dist/docx/selectedXmlIdentityScan.d.ts +2 -3
- package/dist/docx/selectiveSave.d.ts +3 -4
- package/dist/docx/selectiveSave.js +6 -3
- package/dist/docx/selectiveSaveFlags.d.ts +5 -6
- package/dist/docx/selectiveSaveFlags.js +1 -1
- package/dist/docx/selectiveSaveTripwire.d.ts +3 -4
- package/dist/docx/selectiveXmlPatch.d.ts +28 -28
- package/dist/docx/serializer/blockCustomXmlSerializer.d.ts +2 -3
- package/dist/docx/serializer/blockSdtSerializer.d.ts +2 -3
- package/dist/docx/serializer/blockSdtSerializer.js +2 -1
- package/dist/docx/serializer/borderSerializer.d.ts +2 -2
- package/dist/docx/serializer/borderSerializer.js +8 -0
- package/dist/docx/serializer/commentSerializer.d.ts +7 -8
- package/dist/docx/serializer/documentSerializer.d.ts +13 -14
- package/dist/docx/serializer/documentSerializer.js +17 -1
- package/dist/docx/serializer/fontTableSerializer.d.ts +2 -3
- package/dist/docx/serializer/groupTextBoxWriteBack.d.ts +2 -2
- package/dist/docx/serializer/groupTextBoxWriteBack.js +1 -4
- package/dist/docx/serializer/headerFooterSerializer.d.ts +2 -2
- package/dist/docx/serializer/headerFooterSerializer.js +5 -1
- package/dist/docx/serializer/markupRangeAttributes.d.ts +11 -6
- package/dist/docx/serializer/markupRangeAttributes.js +33 -6
- package/dist/docx/serializer/noteSerializer.d.ts +5 -6
- package/dist/docx/serializer/noteSerializer.js +26 -1
- package/dist/docx/serializer/numberingSerializer.d.ts +2 -3
- package/dist/docx/serializer/numberingSerializer.js +14 -0
- package/dist/docx/serializer/paragraphSerializer.d.ts +8 -9
- package/dist/docx/serializer/paragraphSerializer.js +33 -20
- package/dist/docx/serializer/partNamespaces.d.ts +11 -10
- package/dist/docx/serializer/partNamespaces.js +2 -1
- package/dist/docx/serializer/runSerializer.d.ts +11 -12
- package/dist/docx/serializer/runSerializer.js +7 -2
- package/dist/docx/serializer/sdtPropertiesSerializer.d.ts +5 -6
- package/dist/docx/serializer/sectionPropertiesSerializer.d.ts +2 -3
- package/dist/docx/serializer/settingsSerializer.d.ts +2 -3
- package/dist/docx/serializer/settingsSerializer.js +9 -6
- package/dist/docx/serializer/stylesSerializer.d.ts +3 -4
- package/dist/docx/serializer/stylesSerializer.js +4 -1
- package/dist/docx/serializer/tableSerializer.d.ts +18 -18
- package/dist/docx/serializer/tableSerializer.js +22 -2
- package/dist/docx/serializer/textFormattingSerializer.d.ts +3 -3
- package/dist/docx/serializer/themeSerializer.d.ts +2 -3
- package/dist/docx/serializer/trackedChangeAttributes.d.ts +4 -4
- package/dist/docx/serializer/xmlUtils.d.ts +3 -4
- package/dist/docx/server/applyDocxXmlPatchProposal.d.ts +12 -11
- package/dist/docx/server/applyDocxXmlPatchProposal.js +5 -3
- package/dist/docx/server/boundedArchive.d.ts +13 -12
- package/dist/docx/server/boundedArchive.js +5 -4
- package/dist/docx/server/build.d.ts +16 -15
- package/dist/docx/server/build.js +11 -7
- package/dist/docx/server/createBilingualDocument.d.ts +15 -14
- package/dist/docx/server/createBilingualDocument.js +60 -23
- package/dist/docx/server/createBilingualDocx.d.ts +5 -6
- package/dist/docx/server/createBilingualDocx.js +7 -3
- package/dist/docx/server/docxToMarkdown.d.ts +2 -3
- package/dist/docx/server/docxToMarkdown.js +2 -1
- package/dist/docx/server/evaluateDocxXmlPatchProposal.d.ts +20 -19
- package/dist/docx/server/evaluateDocxXmlPatchProposal.js +6 -4
- package/dist/docx/server/extractDocxText.d.ts +10 -11
- package/dist/docx/server/extractDocxText.js +3 -2
- package/dist/docx/server/inspectDocxPackage.d.ts +16 -15
- package/dist/docx/server/inspectDocxPackage.js +5 -4
- package/dist/docx/server/materializeYjsDocx.d.ts +10 -9
- package/dist/docx/server/materializeYjsDocx.js +3 -2
- package/dist/docx/server/migrateYjsAttrSchema.d.ts +8 -8
- package/dist/docx/server/migrateYjsAttrSchema.js +5 -4
- package/dist/docx/server/validateDocxConformance.d.ts +14 -15
- package/dist/docx/settingsHeaderFooterUpdate.d.ts +2 -3
- package/dist/docx/settingsParser.d.ts +2 -2
- package/dist/docx/settingsParser.js +12 -0
- package/dist/docx/shadingParser.d.ts +2 -3
- package/dist/docx/shapeAlternateContent.d.ts +8 -7
- package/dist/docx/shapeAlternateContent.js +84 -9
- package/dist/docx/shapeParser.d.ts +4 -5
- package/dist/docx/shapeParser.js +2 -1
- package/dist/docx/storyBlockReplay.d.ts +5 -5
- package/dist/docx/storyBlockReplay.js +10 -2
- package/dist/docx/storyPlainText.d.ts +9 -10
- package/dist/docx/streamingXmlParser.d.ts +8 -8
- package/dist/docx/strictNames.d.ts +4 -5
- package/dist/docx/strictNames.gen.d.ts +6 -7
- package/dist/docx/strictValueEncodings.gen.d.ts +5 -6
- package/dist/docx/structuralXmlPatch.d.ts +2 -2
- package/dist/docx/styleParser.d.ts +11 -12
- package/dist/docx/styleParser.js +1 -3
- package/dist/docx/styleReferenceResolution.d.ts +3 -4
- package/dist/docx/tableLook.d.ts +7 -7
- package/dist/docx/tableParser.d.ts +47 -39
- package/dist/docx/tableParser.js +2 -4
- package/dist/docx/tableRowPropertyPresence.d.ts +5 -6
- package/dist/docx/textBoxParser.d.ts +25 -26
- package/dist/docx/textBoxParser.js +18 -19
- package/dist/docx/themeColorAttribute.d.ts +3 -4
- package/dist/docx/themeParser.d.ts +9 -10
- package/dist/docx/trackedChangeInfo.d.ts +5 -6
- package/dist/docx/trackedMoveRangeNormalization.d.ts +3 -3
- package/dist/docx/trackedMoveRangeNormalization.js +52 -21
- package/dist/docx/transitionalSpelling.d.ts +7 -8
- package/dist/docx/universalMeasure.d.ts +5 -6
- package/dist/docx/unzip.d.ts +15 -16
- package/dist/docx/unzip.js +2 -2
- package/dist/docx/verbatimCapture.d.ts +8 -7
- package/dist/docx/verbatimCapture.js +5 -3
- package/dist/docx/verticalMergeProjection.d.ts +4 -5
- package/dist/docx/verticalMergeProjection.js +1 -1
- package/dist/docx/vmlImageParser.d.ts +4 -5
- package/dist/docx/vmlPreview.d.ts +9 -10
- package/dist/docx/vmlPreview.js +0 -3
- package/dist/docx/watermarkParser.d.ts +4 -5
- package/dist/docx/wmfSvg.d.ts +10 -0
- package/dist/docx/wmfSvg.js +451 -0
- package/dist/docx/wordprocessingPrefixes.d.ts +12 -13
- package/dist/docx/wrapPolygon.d.ts +5 -6
- package/dist/docx/wrapTypes.js +1 -2
- package/dist/docx/xmlEncoding.d.ts +2 -3
- package/dist/docx/xmlNamespaceContext.d.ts +5 -6
- package/dist/docx/xmlParser.d.ts +49 -50
- package/dist/docx/xmlParser.js +12 -12
- package/dist/docx/xmlResourceLimits.d.ts +12 -11
- package/dist/docx/xmlResourceLimits.js +5 -2
- package/dist/docx/xmlSafety.d.ts +3 -4
- package/dist/export-pdf.d.ts +13 -13
- package/dist/export-pdf.js +4 -2
- package/dist/fields/bookmarkPages.d.ts +2 -3
- package/dist/fields/bookmarkText.d.ts +2 -2
- package/dist/fields/bookmarkText.js +3 -2
- package/dist/fields/evaluateField.d.ts +3 -3
- package/dist/fields/fieldContext.d.ts +2 -3
- package/dist/fields/resolveFieldValues.d.ts +7 -8
- package/dist/fields/sectionPageCounts.d.ts +2 -3
- package/dist/fields/seqValues.d.ts +2 -3
- package/dist/fonts/FontFaceLifecycle.d.ts +12 -0
- package/dist/fonts/FontFaceLifecycle.js +56 -0
- package/dist/fonts/documentFontFacts.d.ts +17 -0
- package/dist/fonts/documentFontFacts.js +41 -0
- package/dist/fonts/embeddedFontFingerprint.d.ts +2 -3
- package/dist/fonts/embeddedFontFingerprint.js +3 -2
- package/dist/fonts/embeddedFonts.d.ts +7 -8
- package/dist/fonts/fontAlternates.d.ts +4 -5
- package/dist/fonts/fontAlternates.js +2 -1
- package/dist/fonts/fontDeobfuscation.d.ts +3 -4
- package/dist/fonts/fontDeobfuscation.js +7 -3
- package/dist/fonts/fontsourceFaces.d.ts +7 -8
- package/dist/fonts/fontsourceFaces.js +16 -0
- package/dist/fonts/headlessMeasure.d.ts +12 -12
- package/dist/fonts/headlessMeasure.js +2 -1
- package/dist/fonts/sfnt/parse.d.ts +7 -7
- package/dist/fonts/sfnt/parse.js +4 -2
- package/dist/fonts/sfnt/subset.d.ts +6 -6
- package/dist/fonts/sfnt/subset.js +2 -1
- package/dist/fonts/sfnt/tables.d.ts +16 -16
- package/dist/fonts/sfnt/tables.js +2 -1
- package/dist/fonts/sfnt/woff.d.ts +6 -6
- package/dist/fonts/sfnt/woff.js +2 -1
- package/dist/headless-layout.d.ts +9 -9
- package/dist/headless-layout.js +9 -1
- package/dist/i18n/messages/ar.gen.d.ts +2 -2
- package/dist/i18n/messages/catalogs.gen.d.ts +2 -3
- package/dist/i18n/messages/cs.gen.d.ts +2 -2
- package/dist/i18n/messages/de.gen.d.ts +2 -2
- package/dist/i18n/messages/en.gen.d.ts +2 -2
- package/dist/i18n/messages/es.gen.d.ts +2 -2
- package/dist/i18n/messages/et.gen.d.ts +2 -2
- package/dist/i18n/messages/fr.gen.d.ts +2 -2
- package/dist/i18n/messages/he.gen.d.ts +2 -2
- package/dist/i18n/messages/hi.gen.d.ts +2 -2
- package/dist/i18n/messages/hu.gen.d.ts +2 -2
- package/dist/i18n/messages/locales.d.ts +3 -4
- package/dist/i18n/messages/lt.gen.d.ts +2 -2
- package/dist/i18n/messages/lv.gen.d.ts +2 -2
- package/dist/i18n/messages/pl.gen.d.ts +2 -2
- package/dist/i18n/messages/pt-BR.gen.d.ts +2 -2
- package/dist/i18n/messages/sk.gen.d.ts +2 -2
- package/dist/i18n/messages/tr.gen.d.ts +2 -2
- package/dist/i18n/messages/zh-CN.gen.d.ts +2 -2
- package/dist/i18n/messages.d.ts +4 -4
- package/dist/internal/acceptedBlockProjection.d.ts +2 -3
- package/dist/internal/acceptedBlockProjection.js +5 -1
- package/dist/internal/compare/inline-presentation.d.ts +4 -4
- package/dist/internal/headlessRevisionResolutionGuard.d.ts +2 -3
- package/dist/internal/indexedPositionMap.d.ts +2 -3
- package/dist/internal/noteMarkerAttrs.d.ts +3 -4
- package/dist/internal/pageBreakRunDescendantIndex.d.ts +3 -4
- package/dist/internal/pageBreakRunPartition.d.ts +4 -4
- package/dist/internal/pageBreakRunSourceDescendantIndex.d.ts +4 -5
- package/dist/internal/pageBreakRunSourceDescendantIndex.js +5 -1
- package/dist/internal/paragraphFormattingSerialization.d.ts +6 -6
- package/dist/internal/paragraphFormattingSerialization.js +3 -1
- package/dist/internal/prosemirrorAttrBoundary.d.ts +9 -10
- package/dist/internal/prosemirrorAttrBoundary.js +2 -1
- package/dist/internal/revisionResolutionEdits.d.ts +2 -2
- package/dist/internal/revisionResolutionInline.d.ts +4 -3
- package/dist/internal/revisionResolutionInline.js +69 -48
- package/dist/internal/revisionResolutionStep.d.ts +3 -3
- package/dist/internal/revisionResolutionTracking.d.ts +2 -2
- package/dist/internal/revisionResolutionTracking.js +3 -3
- package/dist/internal/sectionEndpointResolution.d.ts +5 -5
- package/dist/internal/sectionReferenceResolution.d.ts +6 -7
- package/dist/internal/wholeStoryRevisionResolution.d.ts +6 -4
- package/dist/internal/wholeStoryRevisionResolution.js +168 -52
- package/dist/layout-bridge/cellSelectionHighlight.d.ts +2 -3
- package/dist/layout-bridge/convert/endnoteLayout.d.ts +8 -8
- package/dist/layout-bridge/convert/endnoteLayout.js +2 -1
- package/dist/layout-bridge/convert/fixedTableColumnWidths.d.ts +2 -3
- package/dist/layout-bridge/convert/flowBlockPostprocessing.d.ts +5 -6
- package/dist/layout-bridge/convert/flowBorders.d.ts +3 -4
- package/dist/layout-bridge/convert/flowConversionShared.d.ts +9 -7
- package/dist/layout-bridge/convert/footnoteLayout.d.ts +14 -14
- package/dist/layout-bridge/convert/footnoteLayout.js +10 -0
- package/dist/layout-bridge/convert/headerFooterLayout.d.ts +13 -12
- package/dist/layout-bridge/convert/headerFooterLayout.js +10 -4
- package/dist/layout-bridge/convert/imageConversion.d.ts +6 -7
- package/dist/layout-bridge/convert/listMarkers.d.ts +9 -9
- package/dist/layout-bridge/convert/markupViewFlow.d.ts +3 -3
- package/dist/layout-bridge/convert/noteReferences.d.ts +2 -3
- package/dist/layout-bridge/convert/pageBreakSplitting.d.ts +4 -4
- package/dist/layout-bridge/convert/pageBreakSplitting.js +4 -0
- package/dist/layout-bridge/convert/paragraphAttrs.d.ts +2 -2
- package/dist/layout-bridge/convert/paragraphAttrs.js +18 -11
- package/dist/layout-bridge/convert/paragraphConversion.d.ts +4 -5
- package/dist/layout-bridge/convert/paragraphConversion.js +9 -2
- package/dist/layout-bridge/convert/paragraphFrames.d.ts +2 -2
- package/dist/layout-bridge/convert/paragraphFrames.js +1 -1
- package/dist/layout-bridge/convert/paragraphMarkFormatting.d.ts +3 -4
- package/dist/layout-bridge/convert/paragraphRuns.d.ts +3 -4
- package/dist/layout-bridge/convert/paragraphRuns.js +35 -14
- package/dist/layout-bridge/convert/runFormattingMerge.d.ts +5 -5
- package/dist/layout-bridge/convert/runFormattingMerge.js +1 -0
- package/dist/layout-bridge/convert/runMarkFormatting.d.ts +2 -3
- package/dist/layout-bridge/convert/runMarkFormatting.js +12 -4
- package/dist/layout-bridge/convert/sectionBoundaries.d.ts +6 -6
- package/dist/layout-bridge/convert/tableConversion.d.ts +3 -4
- package/dist/layout-bridge/convert/tableConversion.js +1 -1
- package/dist/layout-bridge/convert/templatePreviewFlow.d.ts +6 -7
- package/dist/layout-bridge/convert/textBoxFill.d.ts +3 -4
- package/dist/layout-bridge/convert/textFormattingConversion.d.ts +8 -7
- package/dist/layout-bridge/convert/textFormattingConversion.js +10 -1
- package/dist/layout-bridge/convert/toFlowBlocks.d.ts +3 -3
- package/dist/layout-bridge/convert/toFlowBlocks.js +19 -11
- package/dist/layout-bridge/convert/wrapEditorViewAsSurface.d.ts +3 -4
- package/dist/layout-bridge/dom/clickToPositionDom.d.ts +12 -13
- package/dist/layout-bridge/dom/clickToPositionDom.js +30 -4
- package/dist/layout-bridge/dom/findBodyPmSpans.d.ts +5 -6
- package/dist/layout-bridge/dom/findHfPmSpans.d.ts +10 -11
- package/dist/layout-bridge/dom/imeCaretAnchor.d.ts +3 -3
- package/dist/layout-bridge/dom/noteStoryDom.d.ts +2 -3
- package/dist/layout-bridge/dom/textStreamDom.d.ts +16 -9
- package/dist/layout-bridge/dom/textStreamDom.js +18 -3
- package/dist/layout-bridge/engine/clickToPosition.d.ts +8 -9
- package/dist/layout-bridge/engine/clickToPosition.js +77 -94
- package/dist/layout-bridge/engine/hitTest.d.ts +18 -19
- package/dist/layout-bridge/engine/hitTest.js +2 -1
- package/dist/layout-bridge/engine/linePmRange.d.ts +7 -0
- package/dist/layout-bridge/engine/linePmRange.js +34 -0
- package/dist/layout-bridge/engine/selectionRects.d.ts +7 -8
- package/dist/layout-bridge/engine/selectionRects.js +53 -77
- package/dist/layout-bridge/headerFooterLayout.d.ts +4 -5
- package/dist/layout-bridge/measuring/measureBlocksPipeline.d.ts +2 -3
- package/dist/layout-bridge/sectionColumns.d.ts +2 -3
- package/dist/layout-bridge/tableInsertHover.d.ts +6 -7
- package/dist/layout-engine/anchorLayoutInCellCompatibility.d.ts +2 -3
- package/dist/layout-engine/footnoteColumnReflow.d.ts +2 -2
- package/dist/layout-engine/headerFooterRefs.d.ts +2 -3
- package/dist/layout-engine/imageLayout.d.ts +2 -3
- package/dist/layout-engine/index.d.ts +3 -3
- package/dist/layout-engine/index.js +9 -6
- package/dist/layout-engine/justificationCompatibility.d.ts +2 -3
- package/dist/layout-engine/keep-together.d.ts +7 -8
- package/dist/layout-engine/keep-together.js +1 -1
- package/dist/layout-engine/layoutFlowShared.d.ts +3 -4
- package/dist/layout-engine/layoutInstrumentation.d.ts +18 -19
- package/dist/layout-engine/lineFlow.d.ts +4 -5
- package/dist/layout-engine/measure/advanceComposition.d.ts +8 -8
- package/dist/layout-engine/measure/advanceComposition.js +24 -5
- package/dist/layout-engine/measure/automaticTextSpacing.d.ts +36 -0
- package/dist/layout-engine/measure/automaticTextSpacing.js +178 -0
- package/dist/layout-engine/measure/cache.d.ts +22 -22
- package/dist/layout-engine/measure/cache.js +50 -14
- package/dist/layout-engine/measure/clampFloatingWrapMargins.d.ts +2 -3
- package/dist/layout-engine/measure/complexScriptFormatting.d.ts +5 -5
- package/dist/layout-engine/measure/crossRunWords.d.ts +8 -8
- package/dist/layout-engine/measure/crossRunWords.js +9 -4
- package/dist/layout-engine/measure/effectiveLineBreakPolicy.d.ts +3 -3
- package/dist/layout-engine/measure/effectiveLineBreakPolicy.js +3 -1
- package/dist/layout-engine/measure/featureFlags.d.ts +4 -5
- package/dist/layout-engine/measure/floatingLineClearance.d.ts +3 -4
- package/dist/layout-engine/measure/floatingTablePosition.d.ts +3 -3
- package/dist/layout-engine/measure/floatingZones.d.ts +11 -10
- package/dist/layout-engine/measure/font-metrics.worker.d.ts +3 -4
- package/dist/layout-engine/measure/font-metrics.worker.js +2 -1
- package/dist/layout-engine/measure/hyperlinkInstance.d.ts +3 -4
- package/dist/layout-engine/measure/hyphenationDictionaries.d.ts +17 -34
- package/dist/layout-engine/measure/hyphenationDictionaries.js +6 -5
- package/dist/layout-engine/measure/hyphenationPreload.d.ts +2 -3
- package/dist/layout-engine/measure/inlineObjectMetrics.d.ts +3 -4
- package/dist/layout-engine/measure/justification.d.ts +7 -7
- package/dist/layout-engine/measure/lineBreakProvider.d.ts +16 -11
- package/dist/layout-engine/measure/lineBreakProvider.js +29 -4
- package/dist/layout-engine/measure/lineBreaks.d.ts +7 -8
- package/dist/layout-engine/measure/lineBreaks.js +5 -2
- package/dist/layout-engine/measure/lineFitting.d.ts +11 -11
- package/dist/layout-engine/measure/lineFitting.js +17 -6
- package/dist/layout-engine/measure/lineTypography.d.ts +7 -8
- package/dist/layout-engine/measure/lineTypography.js +1 -0
- package/dist/layout-engine/measure/listMarkerWidth.d.ts +9 -6
- package/dist/layout-engine/measure/listMarkerWidth.js +7 -3
- package/dist/layout-engine/measure/measureBlocks.d.ts +7 -7
- package/dist/layout-engine/measure/measureBlocks.js +13 -7
- package/dist/layout-engine/measure/measureContainer.d.ts +5 -6
- package/dist/layout-engine/measure/measureContainer.js +27 -6
- package/dist/layout-engine/measure/measureHelpers.d.ts +21 -18
- package/dist/layout-engine/measure/measureHelpers.js +12 -3
- package/dist/layout-engine/measure/measureParagraph.d.ts +5 -5
- package/dist/layout-engine/measure/measureParagraph.js +57 -11
- package/dist/layout-engine/measure/measureProvider.d.ts +15 -9
- package/dist/layout-engine/measure/measureProvider.js +66 -4
- package/dist/layout-engine/measure/measureTypes.d.ts +17 -14
- package/dist/layout-engine/measure/measureWorker.d.ts +8 -8
- package/dist/layout-engine/measure/measureWorkerProtocol.d.ts +6 -7
- package/dist/layout-engine/measure/paragraphMeasureShared.d.ts +19 -20
- package/dist/layout-engine/measure/paragraphTabs.d.ts +6 -7
- package/dist/layout-engine/measure/paragraphTabs.js +16 -17
- package/dist/layout-engine/measure/smallCapsCasing.d.ts +6 -7
- package/dist/layout-engine/measure/tabCalculator.d.ts +15 -16
- package/dist/layout-engine/measure/tableCellFloating.d.ts +6 -6
- package/dist/layout-engine/measure/tableCellFlow.d.ts +7 -7
- package/dist/layout-engine/measure/tableCellGrid.d.ts +14 -14
- package/dist/layout-engine/measure/tableFragmentBorderGeometry.d.ts +2 -2
- package/dist/layout-engine/measure/tableInlinePlacement.d.ts +3 -3
- package/dist/layout-engine/measure/textBoxParagraphLayout.d.ts +4 -4
- package/dist/layout-engine/measure/textMeasurementPolicy.d.ts +8 -8
- package/dist/layout-engine/noColumnBalanceCompatibility.d.ts +7 -0
- package/dist/layout-engine/noColumnBalanceCompatibility.js +5 -0
- package/dist/layout-engine/noteAreaFlow.d.ts +4 -5
- package/dist/layout-engine/paginator.d.ts +18 -11
- package/dist/layout-engine/paginator.js +51 -11
- package/dist/layout-engine/paragraphFragmentRange.d.ts +2 -3
- package/dist/layout-engine/paragraphFrame.d.ts +2 -21
- package/dist/layout-engine/paragraphFrame.js +1 -17
- package/dist/layout-engine/paragraphLayout.d.ts +2 -2
- package/dist/layout-engine/paragraphLayout.js +28 -9
- package/dist/layout-engine/paragraphSequence.d.ts +3 -4
- package/dist/layout-engine/paragraphSpacing.d.ts +10 -10
- package/dist/layout-engine/pmPageIndex.d.ts +3 -4
- package/dist/layout-engine/renderedBreakReconciliation.d.ts +7 -7
- package/dist/layout-engine/section-breaks.d.ts +15 -15
- package/dist/layout-engine/sectionLayout.d.ts +7 -7
- package/dist/layout-engine/sectionLayout.js +1 -4
- package/dist/layout-engine/sectionVerticalAlignment.d.ts +2 -3
- package/dist/layout-engine/tableIndentCompatibility.d.ts +2 -3
- package/dist/layout-engine/tableLayout.d.ts +4 -5
- package/dist/layout-engine/tableLayout.js +17 -9
- package/dist/layout-engine/tableRowBreak.d.ts +6 -6
- package/dist/layout-engine/tableRowBreak.js +10 -5
- package/dist/layout-engine/textBoxFlow.d.ts +6 -6
- package/dist/layout-engine/textBoxGroup.d.ts +3 -4
- package/dist/layout-engine/textBoxLayout.d.ts +2 -2
- package/dist/layout-engine/types.d.ts +108 -88
- package/dist/layout-painter/anchoredImagePosition.d.ts +4 -5
- package/dist/layout-painter/borderStroke.d.ts +4 -4
- package/dist/layout-painter/cursiveJoiners.d.ts +7 -7
- package/dist/layout-painter/documentColors.d.ts +6 -7
- package/dist/layout-painter/imageLayout.d.ts +13 -14
- package/dist/layout-painter/index.d.ts +8 -7
- package/dist/layout-painter/index.js +7 -2
- package/dist/layout-painter/registry/modules/image.d.ts +2 -3
- package/dist/layout-painter/registry/modules/paragraph.d.ts +2 -3
- package/dist/layout-painter/registry/modules/table.d.ts +2 -3
- package/dist/layout-painter/registry/modules/textBox.d.ts +2 -3
- package/dist/layout-painter/registry/modules.d.ts +2 -3
- package/dist/layout-painter/registry/registry.d.ts +4 -5
- package/dist/layout-painter/registry/types.d.ts +8 -9
- package/dist/layout-painter/renderFragment.d.ts +4 -5
- package/dist/layout-painter/renderImage.d.ts +12 -13
- package/dist/layout-painter/renderPage.d.ts +27 -25
- package/dist/layout-painter/renderPage.js +116 -31
- package/dist/layout-painter/renderParagraph.d.ts +19 -15
- package/dist/layout-painter/renderParagraph.js +186 -46
- package/dist/layout-painter/renderTable.d.ts +7 -8
- package/dist/layout-painter/renderTable.js +27 -15
- package/dist/layout-painter/renderTextBox.d.ts +5 -6
- package/dist/layout-painter/renderTextBox.js +9 -1
- package/dist/layout-painter/renderUtils.d.ts +11 -14
- package/dist/layout-painter/renderUtils.js +1 -19
- package/dist/layout-painter/renderWatermark.d.ts +5 -4
- package/dist/layout-painter/sdtBoundary.d.ts +4 -5
- package/dist/layout-painter/tableRowPaintGeometry.d.ts +2 -2
- package/dist/managers/AutoSaveManager.d.ts +11 -12
- package/dist/managers/AutoSaveManager.js +17 -3
- package/dist/managers/ClipboardManager.d.ts +7 -8
- package/dist/managers/ContextMenuManager.d.ts +3 -4
- package/dist/managers/DocumentLoaderManager.d.ts +5 -6
- package/dist/managers/EditorModeManager.d.ts +12 -12
- package/dist/managers/ErrorManager.d.ts +2 -3
- package/dist/managers/FindReplaceManager.d.ts +6 -6
- package/dist/managers/HistoryManager.d.ts +9 -10
- package/dist/managers/Subscribable.d.ts +2 -3
- package/dist/managers/TableSelectionManager.d.ts +9 -10
- package/dist/managers/TableSelectionManager.js +3 -13
- package/dist/managers/autoSaveCodec.d.ts +8 -9
- package/dist/managers/editorShortcuts.d.ts +14 -15
- package/dist/managers/reviewDisplayMode.d.ts +4 -5
- package/dist/managers/types.d.ts +7 -8
- package/dist/markdown/annotations.d.ts +6 -7
- package/dist/markdown/escape.d.ts +6 -7
- package/dist/markdown/fromMarkdown.d.ts +2 -3
- package/dist/markdown/images.d.ts +2 -3
- package/dist/markdown/index.d.ts +3 -3
- package/dist/markdown/index.js +28 -2
- package/dist/markdown/internals.d.ts +4 -5
- package/dist/markdown/internals.js +3 -2
- package/dist/markdown/renderBlock.d.ts +2 -3
- package/dist/markdown/renderBlock.js +5 -1
- package/dist/markdown/renderParagraph.d.ts +4 -5
- package/dist/markdown/renderParagraph.js +42 -17
- package/dist/markdown/renderRuns.d.ts +3 -3
- package/dist/markdown/renderRuns.js +15 -10
- package/dist/markdown/renderTable.d.ts +2 -3
- package/dist/markdown/renderTable.js +21 -8
- package/dist/markdown/trailers.d.ts +2 -3
- package/dist/markdown/types.d.ts +7 -8
- package/dist/model.d.ts +1 -1
- package/dist/paged-layout/LayoutSelectionGate.d.ts +2 -2
- package/dist/paged-layout/blockGeometry.d.ts +5 -6
- package/dist/paged-layout/editorScrollRoot.d.ts +5 -5
- package/dist/paged-layout/fitWidthZoom.d.ts +36 -0
- package/dist/paged-layout/fitWidthZoom.js +31 -0
- package/dist/paged-layout/hiddenEditorScroll.d.ts +2 -3
- package/dist/paged-layout/incrementalMeasure.d.ts +6 -7
- package/dist/paged-layout/pageText.d.ts +2 -2
- package/dist/paged-layout/paragraphFlash.d.ts +7 -7
- package/dist/paged-layout/paragraphFlashTypes.d.ts +3 -4
- package/dist/paged-layout/rangeProjection.d.ts +11 -12
- package/dist/paged-layout/readOnlyEditAttempt.d.ts +2 -2
- package/dist/paged-layout/scrollNavigation.d.ts +5 -6
- package/dist/paged-layout/scrollPageInfo.d.ts +5 -6
- package/dist/paged-layout/scrollToPmPosition.d.ts +4 -5
- package/dist/paged-layout/sectionBlockWidths.d.ts +3 -3
- package/dist/paged-layout/sectionBlockWidths.js +0 -3
- package/dist/paged-layout/sectionGeometry.d.ts +10 -11
- package/dist/paged-layout/selectionViewportRect.d.ts +5 -6
- package/dist/paged-layout/tableColumnResize.d.ts +2 -3
- package/dist/paged-layout/tableInsertButtonGeometry.d.ts +2 -3
- package/dist/paged-layout/transactionDirtyRange.d.ts +2 -3
- package/dist/paged-layout/zoomScrollAnchor.d.ts +5 -5
- package/dist/panel-layout.d.ts +11 -12
- package/dist/pdf/contentStream.d.ts +11 -12
- package/dist/pdf/fonts.d.ts +11 -11
- package/dist/pdf/fonts.js +2 -20
- package/dist/pdf/images.d.ts +7 -7
- package/dist/pdf/images.js +6 -2
- package/dist/pdf/objects.d.ts +23 -24
- package/dist/pdf/pageSpace.d.ts +9 -10
- package/dist/pdf/paint.d.ts +8 -8
- package/dist/pdf/paint.js +30 -2
- package/dist/pdf/writePdf.d.ts +8 -8
- package/dist/pdf/writePdf.js +2 -1
- package/dist/prosemirror/addTrackedDeletionMark.d.ts +2 -2
- package/dist/prosemirror/alternateContentAttrs.d.ts +5 -4
- package/dist/prosemirror/alternateContentAttrs.js +13 -3
- package/dist/prosemirror/anchoredTextBoxes.d.ts +10 -11
- package/dist/prosemirror/attrs/index.d.ts +86 -86
- package/dist/prosemirror/attrs/index.js +127 -99
- package/dist/prosemirror/authoredTransformAttrs.d.ts +3 -3
- package/dist/prosemirror/autospacingBase.d.ts +5 -5
- package/dist/prosemirror/bookmarkBoundaryAttrs.d.ts +7 -7
- package/dist/prosemirror/bookmarkBoundaryAttrs.js +31 -2
- package/dist/prosemirror/bookmarkBoundaryIntegrity.d.ts +3 -4
- package/dist/prosemirror/canonicalCommands.d.ts +38 -21
- package/dist/prosemirror/canonicalCommands.js +5 -4
- package/dist/prosemirror/canonicalSelectionRange.d.ts +14 -4
- package/dist/prosemirror/canonicalSelectionRange.js +20 -1
- package/dist/prosemirror/cellDragSelection.d.ts +6 -7
- package/dist/prosemirror/cellDragSelection.js +9 -0
- package/dist/prosemirror/clearRunColor.d.ts +2 -3
- package/dist/prosemirror/clearRunColor.js +8 -5
- package/dist/prosemirror/clipboardIntent.d.ts +3 -4
- package/dist/prosemirror/commands/clearParagraphIndent.d.ts +2 -3
- package/dist/prosemirror/commands/comments.d.ts +28 -28
- package/dist/prosemirror/commands/comments.js +220 -83
- package/dist/prosemirror/commands/contentControls.d.ts +9 -9
- package/dist/prosemirror/commands/contentControls.js +2 -1
- package/dist/prosemirror/commands/contentControlsBlockFill.d.ts +2 -3
- package/dist/prosemirror/commands/contentControlsBlockFill.js +2 -1
- package/dist/prosemirror/commands/formatPainter.d.ts +5 -5
- package/dist/prosemirror/commands/formatPainter.js +14 -11
- package/dist/prosemirror/commands/formatting.d.ts +20 -20
- package/dist/prosemirror/commands/hyperlink.d.ts +5 -6
- package/dist/prosemirror/commands/hyperlink.js +7 -6
- package/dist/prosemirror/commands/image.d.ts +14 -14
- package/dist/prosemirror/commands/pageBreak.d.ts +2 -3
- package/dist/prosemirror/commands/pageBreak.js +2 -1
- package/dist/prosemirror/commands/paragraph.d.ts +35 -35
- package/dist/prosemirror/commands/paragraphBookmarkJoin.d.ts +5 -5
- package/dist/prosemirror/commands/paragraphBookmarkJoin.js +4 -7
- package/dist/prosemirror/commands/pastePlainText.d.ts +4 -5
- package/dist/prosemirror/commands/propertyChangeScope.d.ts +13 -13
- package/dist/prosemirror/commands/propertyChangeScope.js +2 -0
- package/dist/prosemirror/commands/resolveAllTableChanges.d.ts +3 -3
- package/dist/prosemirror/commands/resolveNodePropertyChangeAttrs.d.ts +3 -3
- package/dist/prosemirror/commands/resolveParagraphProperties.d.ts +3 -3
- package/dist/prosemirror/commands/resolveParagraphProperties.js +1 -1
- package/dist/prosemirror/commands/sectionBreak.d.ts +9 -8
- package/dist/prosemirror/commands/sectionBreak.js +14 -1
- package/dist/prosemirror/commands/table.d.ts +34 -34
- package/dist/prosemirror/commands/tableCellMergeResolution.d.ts +8 -8
- package/dist/prosemirror/commands/tableCellMergeResolution.js +3 -2
- package/dist/prosemirror/commands/tableMergeFoldDecisions.d.ts +19 -18
- package/dist/prosemirror/commentBoundaryOwnership.d.ts +15 -0
- package/dist/prosemirror/commentBoundaryOwnership.js +4 -0
- package/dist/prosemirror/commentIdAllocator.d.ts +10 -9
- package/dist/prosemirror/commentIdAllocator.js +4 -1
- package/dist/prosemirror/commentOps.d.ts +6 -7
- package/dist/prosemirror/commentOps.js +3 -19
- package/dist/prosemirror/commentRangeBoundaryAttrs.d.ts +16 -0
- package/dist/prosemirror/commentRangeBoundaryAttrs.js +51 -0
- package/dist/prosemirror/commentRangeInlineAtoms.d.ts +5 -5
- package/dist/prosemirror/commentRangeInlineAtoms.js +1 -0
- package/dist/prosemirror/commentReferenceAttrs.d.ts +3 -4
- package/dist/prosemirror/commentReferenceAttrs.js +4 -1
- package/dist/prosemirror/commentReferenceIntegrity.d.ts +15 -6
- package/dist/prosemirror/commentReferenceIntegrity.js +93 -1
- package/dist/prosemirror/containerFinalParagraph.d.ts +4 -4
- package/dist/prosemirror/contentControlRevisions.d.ts +7 -7
- package/dist/prosemirror/conversion/effectiveTableCellFormatting.d.ts +4 -4
- package/dist/prosemirror/conversion/fromProseDoc.d.ts +10 -10
- package/dist/prosemirror/conversion/fromProseDoc.js +477 -178
- package/dist/prosemirror/conversion/hyphenTextCarriers.d.ts +2 -3
- package/dist/prosemirror/conversion/markInterner.d.ts +2 -3
- package/dist/prosemirror/conversion/preservedSinkCarriers.d.ts +5 -5
- package/dist/prosemirror/conversion/runShadingMark.d.ts +3 -4
- package/dist/prosemirror/conversion/sdtAttrs.d.ts +6 -7
- package/dist/prosemirror/conversion/toProseDoc.d.ts +15 -9
- package/dist/prosemirror/conversion/toProseDoc.js +318 -202
- package/dist/prosemirror/copyOriginDom.d.ts +8 -0
- package/dist/prosemirror/copyOriginDom.js +21 -0
- package/dist/prosemirror/copyOriginResolution.d.ts +15 -0
- package/dist/prosemirror/copyOriginResolution.js +202 -0
- package/dist/prosemirror/documentSchema.d.ts +2 -3
- package/dist/prosemirror/emptyFieldResultRuns.d.ts +3 -3
- package/dist/prosemirror/emptyRangeAnchor.d.ts +6 -6
- package/dist/prosemirror/executeEditorCommand.d.ts +4 -5
- package/dist/prosemirror/extensions/ExtensionManager.d.ts +2 -3
- package/dist/prosemirror/extensions/StarterKit.d.ts +3 -4
- package/dist/prosemirror/extensions/StarterKit.js +5 -1
- package/dist/prosemirror/extensions/core/DocExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/core/DocExtension.js +1 -1
- package/dist/prosemirror/extensions/core/HistoryExtension.d.ts +3 -6
- package/dist/prosemirror/extensions/core/HistoryExtension.js +5 -4
- package/dist/prosemirror/extensions/core/ParagraphExtension.d.ts +8 -9
- package/dist/prosemirror/extensions/core/ParagraphExtension.js +17 -9
- package/dist/prosemirror/extensions/core/TextExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/create.d.ts +4 -5
- package/dist/prosemirror/extensions/features/AutoBidiDetectionExtension.d.ts +6 -7
- package/dist/prosemirror/extensions/features/BaseKeymapExtension.d.ts +3 -4
- package/dist/prosemirror/extensions/features/BidiShortcutExtension.d.ts +2 -13
- package/dist/prosemirror/extensions/features/ContentControlWidgetsExtension.d.ts +2 -13
- package/dist/prosemirror/extensions/features/DropCursorExtension.d.ts +2 -9
- package/dist/prosemirror/extensions/features/EmptyParagraphFormatExtension.d.ts +7 -8
- package/dist/prosemirror/extensions/features/GapCursorExtension.d.ts +2 -16
- package/dist/prosemirror/extensions/features/ImageDragExtension.d.ts +2 -12
- package/dist/prosemirror/extensions/features/ImagePasteExtension.d.ts +2 -9
- package/dist/prosemirror/extensions/features/ImagePasteExtension.js +2 -1
- package/dist/prosemirror/extensions/features/JoinedRunStyleExtension.d.ts +3 -18
- package/dist/prosemirror/extensions/features/ListExtension.d.ts +6 -7
- package/dist/prosemirror/extensions/features/ParaIdAllocatorExtension.d.ts +11 -10
- package/dist/prosemirror/extensions/features/ParaIdAllocatorExtension.js +94 -53
- package/dist/prosemirror/extensions/features/ParagraphChangeTrackerExtension.d.ts +20 -20
- package/dist/prosemirror/extensions/features/ParagraphChangeTrackerExtension.js +2 -1
- package/dist/prosemirror/extensions/features/PasteCleanupExtension.d.ts +2 -19
- package/dist/prosemirror/extensions/features/PasteStyleInlinerExtension.d.ts +4 -15
- package/dist/prosemirror/extensions/features/PasteStyleInlinerExtension.js +5 -2
- package/dist/prosemirror/extensions/features/SelectionTrackerExtension.d.ts +2 -2
- package/dist/prosemirror/extensions/features/SelectionTrackerExtension.js +2 -8
- package/dist/prosemirror/extensions/features/bidiShortcutController.d.ts +5 -6
- package/dist/prosemirror/extensions/features/clipboardTrackedRevisions.d.ts +4 -0
- package/dist/prosemirror/extensions/features/clipboardTrackedRevisions.js +72 -0
- package/dist/prosemirror/extensions/features/pasteCleanup.d.ts +4 -4
- package/dist/prosemirror/extensions/features/pasteCleanup.js +3 -2
- package/dist/prosemirror/extensions/features/pastedHeadingStyles.d.ts +2 -3
- package/dist/prosemirror/extensions/features/pastedHtmlLists.d.ts +3 -4
- package/dist/prosemirror/extensions/markRegistry.d.ts +4 -5
- package/dist/prosemirror/extensions/marks/AllCapsExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/BoldExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/CharacterSpacingExtension.d.ts +2 -11
- package/dist/prosemirror/extensions/marks/CharacterStyleExtension.d.ts +2 -17
- package/dist/prosemirror/extensions/marks/CommentExtension.d.ts +2 -9
- package/dist/prosemirror/extensions/marks/FontFamilyExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/FontFamilyExtension.js +12 -4
- package/dist/prosemirror/extensions/marks/FontSizeExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/FootnoteRefExtension.d.ts +2 -8
- package/dist/prosemirror/extensions/marks/FootnoteRefExtension.js +42 -4
- package/dist/prosemirror/extensions/marks/HiddenTextExtension.d.ts +2 -20
- package/dist/prosemirror/extensions/marks/HighlightExtension.d.ts +4 -4
- package/dist/prosemirror/extensions/marks/HighlightExtension.js +6 -4
- package/dist/prosemirror/extensions/marks/HyperlinkExtension.d.ts +5 -6
- package/dist/prosemirror/extensions/marks/HyperlinkExtension.js +9 -3
- package/dist/prosemirror/extensions/marks/InlineWrapperExtension.d.ts +3 -16
- package/dist/prosemirror/extensions/marks/ItalicExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/LanguageExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/marks/RtlExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/marks/RunFormattingOverrideExtension.d.ts +5 -5
- package/dist/prosemirror/extensions/marks/RunIdentityExtension.d.ts +3 -3
- package/dist/prosemirror/extensions/marks/RunShadingExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/marks/SmallCapsExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/StrikeExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/StrikeExtension.js +9 -3
- package/dist/prosemirror/extensions/marks/SubscriptExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/SubscriptExtension.js +3 -2
- package/dist/prosemirror/extensions/marks/SuperscriptExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/SuperscriptExtension.js +3 -2
- package/dist/prosemirror/extensions/marks/TextColorExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/TextColorExtension.js +7 -6
- package/dist/prosemirror/extensions/marks/TextEffectExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/marks/TextEffectsExtensions.d.ts +6 -13
- package/dist/prosemirror/extensions/marks/TextEffectsExtensions.js +1 -4
- package/dist/prosemirror/extensions/marks/TrackedChangeExtensions.d.ts +4 -12
- package/dist/prosemirror/extensions/marks/TrackedChangeExtensions.js +18 -2
- package/dist/prosemirror/extensions/marks/UnderlineExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/marks/UnderlineExtension.js +10 -3
- package/dist/prosemirror/extensions/marks/markUtils.d.ts +83 -25
- package/dist/prosemirror/extensions/marks/markUtils.js +138 -74
- package/dist/prosemirror/extensions/marks/noteReferenceDeletion.d.ts +3 -3
- package/dist/prosemirror/extensions/nodes/BlockBookmarkBoundaryExtension.d.ts +6 -25
- package/dist/prosemirror/extensions/nodes/BlockBookmarkBoundaryExtension.js +4 -4
- package/dist/prosemirror/extensions/nodes/BlockCustomXmlExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/nodes/BlockMoveRangeBoundaryExtension.d.ts +10 -0
- package/dist/prosemirror/extensions/nodes/BlockMoveRangeBoundaryExtension.js +59 -0
- package/dist/prosemirror/extensions/nodes/BlockSdtExtension.d.ts +2 -20
- package/dist/prosemirror/extensions/nodes/BookmarkBoundaryExtension.d.ts +3 -4
- package/dist/prosemirror/extensions/nodes/BookmarkBoundaryExtension.js +1 -1
- package/dist/prosemirror/extensions/nodes/CommentRangeBoundaryExtension.d.ts +10 -0
- package/dist/prosemirror/extensions/nodes/CommentRangeBoundaryExtension.js +43 -0
- package/dist/prosemirror/extensions/nodes/CommentReferenceExtension.d.ts +3 -5
- package/dist/prosemirror/extensions/nodes/CommentReferenceExtension.js +5 -73
- package/dist/prosemirror/extensions/nodes/FieldExtension.d.ts +3 -11
- package/dist/prosemirror/extensions/nodes/FieldExtension.js +12 -2
- package/dist/prosemirror/extensions/nodes/HardBreakExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/nodes/HorizontalRuleExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/nodes/ImageExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/nodes/MathExtension.d.ts +2 -10
- package/dist/prosemirror/extensions/nodes/MoveRangeBoundaryExtension.d.ts +4 -5
- package/dist/prosemirror/extensions/nodes/MoveRangeBoundaryExtension.js +8 -4
- package/dist/prosemirror/extensions/nodes/NoteMarkerExtension.d.ts +3 -4
- package/dist/prosemirror/extensions/nodes/PageBreakExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/nodes/PageBreakRunExtension.d.ts +2 -4
- package/dist/prosemirror/extensions/nodes/PreservedBlockExtension.d.ts +3 -29
- package/dist/prosemirror/extensions/nodes/PreservedXmlExtension.d.ts +3 -13
- package/dist/prosemirror/extensions/nodes/RangeAnchorExtension.d.ts +4 -5
- package/dist/prosemirror/extensions/nodes/RangeAnchorExtension.js +20 -4
- package/dist/prosemirror/extensions/nodes/RenderedPageBreakExtension.d.ts +3 -5
- package/dist/prosemirror/extensions/nodes/SdtExtension.d.ts +3 -10
- package/dist/prosemirror/extensions/nodes/ShapeExtension.d.ts +11 -11
- package/dist/prosemirror/extensions/nodes/ShapeExtension.js +5 -6
- package/dist/prosemirror/extensions/nodes/SymbolExtension.d.ts +2 -3
- package/dist/prosemirror/extensions/nodes/SymbolExtension.js +3 -3
- package/dist/prosemirror/extensions/nodes/TabExtension.d.ts +2 -6
- package/dist/prosemirror/extensions/nodes/TableExtension.d.ts +10 -10
- package/dist/prosemirror/extensions/nodes/TableExtension.js +11 -13
- package/dist/prosemirror/extensions/nodes/TextBoxAnchorExtension.d.ts +3 -10
- package/dist/prosemirror/extensions/nodes/TextBoxExtension.d.ts +4 -5
- package/dist/prosemirror/extensions/nodes/bookmarkBoundaryDom.d.ts +7 -5
- package/dist/prosemirror/extensions/nodes/bookmarkBoundaryDom.js +9 -3
- package/dist/prosemirror/extensions/types.d.ts +27 -27
- package/dist/prosemirror/fieldRepresentation.d.ts +6 -5
- package/dist/prosemirror/fieldRepresentation.js +13 -3
- package/dist/prosemirror/findReplaceSelection.d.ts +9 -9
- package/dist/prosemirror/hyperlinkRemoval.d.ts +6 -5
- package/dist/prosemirror/hyperlinkRemoval.js +14 -1
- package/dist/prosemirror/imageCommit.d.ts +5 -23
- package/dist/prosemirror/imageCommit.js +1 -29
- package/dist/prosemirror/imagePictureNames.d.ts +4 -5
- package/dist/prosemirror/indexedNodeLookup.d.ts +4 -4
- package/dist/prosemirror/inlineDisplayText.d.ts +4 -5
- package/dist/prosemirror/inlineWrapperStack.d.ts +8 -9
- package/dist/prosemirror/insertOperations.d.ts +4 -4
- package/dist/prosemirror/keptRangeBoundaries.d.ts +76 -0
- package/dist/prosemirror/keptRangeBoundaries.js +381 -0
- package/dist/prosemirror/listAutoformatMarkers.d.ts +3 -4
- package/dist/prosemirror/listInstanceReferences.d.ts +3 -4
- package/dist/prosemirror/listInstanceReferences.js +1 -1
- package/dist/prosemirror/listLabels.d.ts +15 -5
- package/dist/prosemirror/listLabels.js +101 -16
- package/dist/prosemirror/listMarker.d.ts +13 -13
- package/dist/prosemirror/listMarker.js +7 -2
- package/dist/prosemirror/listNumbering.d.ts +11 -11
- package/dist/prosemirror/listNumbering.js +0 -16
- package/dist/prosemirror/listRendering.d.ts +5 -5
- package/dist/prosemirror/listRendering.js +4 -0
- package/dist/prosemirror/listRenderingAttrs.d.ts +12 -11
- package/dist/prosemirror/listRenderingAttrs.js +9 -5
- package/dist/prosemirror/listState.d.ts +9 -10
- package/dist/prosemirror/markupViewNotes.d.ts +2 -3
- package/dist/prosemirror/markupViewProjection.d.ts +12 -11
- package/dist/prosemirror/moveRangeBoundaryAttrs.d.ts +7 -6
- package/dist/prosemirror/moveRangeBoundaryAttrs.js +27 -4
- package/dist/prosemirror/noteReferenceOccurrenceId.d.ts +2 -3
- package/dist/prosemirror/noteReferenceOccurrences.d.ts +12 -11
- package/dist/prosemirror/noteReferenceOccurrences.js +4 -2
- package/dist/prosemirror/noteReferenceReview.d.ts +13 -13
- package/dist/prosemirror/noteReferenceReview.js +4 -10
- package/dist/prosemirror/numberedRefFields.d.ts +5 -5
- package/dist/prosemirror/numberingAttr.d.ts +14 -14
- package/dist/prosemirror/outlineLevelAttr.d.ts +3 -4
- package/dist/prosemirror/pageBreakRunProjection.d.ts +5 -5
- package/dist/prosemirror/paraText.d.ts +4 -5
- package/dist/prosemirror/paragraphAlignment.d.ts +2 -3
- package/dist/prosemirror/paragraphDirection.d.ts +8 -9
- package/dist/prosemirror/paragraphFormattingProvenance.d.ts +14 -7
- package/dist/prosemirror/paragraphFormattingProvenance.js +8 -0
- package/dist/prosemirror/paragraphIndentation.d.ts +7 -7
- package/dist/prosemirror/paragraphList.d.ts +39 -0
- package/dist/prosemirror/paragraphList.js +81 -0
- package/dist/prosemirror/paragraphMarkJoin.d.ts +12 -2
- package/dist/prosemirror/paragraphMarkJoin.js +34 -3
- package/dist/prosemirror/paragraphPropertyCarry.d.ts +7 -7
- package/dist/prosemirror/paragraphSpacing.d.ts +9 -9
- package/dist/prosemirror/paragraphSpacing.js +16 -10
- package/dist/prosemirror/pluginKeyOwner.d.ts +3 -4
- package/dist/prosemirror/plugins/aiCitationDecorations.d.ts +10 -10
- package/dist/prosemirror/plugins/aiCitationDecorations.js +0 -12
- package/dist/prosemirror/plugins/aiSuggestionDecorations.d.ts +10 -10
- package/dist/prosemirror/plugins/aiSuggestionDecorations.js +0 -14
- package/dist/prosemirror/plugins/anonymizationDecorations.d.ts +11 -11
- package/dist/prosemirror/plugins/anonymizationDecorations.js +0 -18
- package/dist/prosemirror/plugins/autocompleteSuggestion.d.ts +21 -21
- package/dist/prosemirror/plugins/autocompleteSuggestion.js +3 -25
- package/dist/prosemirror/plugins/contentControlWidgets.d.ts +14 -14
- package/dist/prosemirror/plugins/contentControlWidgets.js +13 -7
- package/dist/prosemirror/plugins/createDocScanPlugin.d.ts +6 -6
- package/dist/prosemirror/plugins/documentNumbering.d.ts +11 -9
- package/dist/prosemirror/plugins/documentNumbering.js +42 -42
- package/dist/prosemirror/plugins/documentStyleState.d.ts +9 -10
- package/dist/prosemirror/plugins/documentStyles.d.ts +4 -4
- package/dist/prosemirror/plugins/documentStyles.js +2 -1
- package/dist/prosemirror/plugins/lockedControlKeyHandling.d.ts +4 -0
- package/dist/prosemirror/plugins/lockedControlKeyHandling.js +16 -0
- package/dist/prosemirror/plugins/paragraphStyleResolution.d.ts +3 -3
- package/dist/prosemirror/plugins/paragraphStyleResolution.js +23 -1
- package/dist/prosemirror/plugins/pmTextScan.d.ts +5 -6
- package/dist/prosemirror/plugins/revisionIds.d.ts +13 -12
- package/dist/prosemirror/plugins/revisionIds.js +13 -1
- package/dist/prosemirror/plugins/selectionTracker.d.ts +9 -10
- package/dist/prosemirror/plugins/suggestionMode.d.ts +18 -18
- package/dist/prosemirror/plugins/suggestionMode.js +11 -3
- package/dist/prosemirror/plugins/templateDirectives.d.ts +12 -12
- package/dist/prosemirror/plugins/templateDirectives.js +0 -17
- package/dist/prosemirror/plugins/templatePreviewValues.d.ts +16 -16
- package/dist/prosemirror/plugins/templatePreviewValues.js +0 -23
- package/dist/prosemirror/plugins/templateSlashMenu.d.ts +12 -13
- package/dist/prosemirror/plugins/templateSlashMenu.js +3 -21
- package/dist/prosemirror/plugins/transactionInvariants.d.ts +7 -8
- package/dist/prosemirror/positionSweep.d.ts +4 -5
- package/dist/prosemirror/positionSweep.js +1 -1
- package/dist/prosemirror/preservedXmlReview.d.ts +3 -4
- package/dist/prosemirror/queries.d.ts +5 -6
- package/dist/prosemirror/rangeAnchorAttrs.d.ts +4 -5
- package/dist/prosemirror/rangeAnchorAttrs.js +4 -1
- package/dist/prosemirror/rebaseParagraphRunFormatting.d.ts +3 -3
- package/dist/prosemirror/rebaseParagraphRunFormatting.js +6 -5
- package/dist/prosemirror/rebaseParagraphRuns.d.ts +4 -4
- package/dist/prosemirror/rebaseParagraphRuns.js +15 -11
- package/dist/prosemirror/rejoinRunCarriers.d.ts +3 -3
- package/dist/prosemirror/replacedAnnotations.d.ts +31 -17
- package/dist/prosemirror/replacedAnnotations.js +80 -11
- package/dist/prosemirror/revisionCarriers.d.ts +13 -13
- package/dist/prosemirror/runContentProjection.d.ts +6 -0
- package/dist/prosemirror/runContentProjection.js +24 -0
- package/dist/prosemirror/runFormattingFromMarks.d.ts +5 -6
- package/dist/prosemirror/runFormattingFromMarks.js +19 -17
- package/dist/prosemirror/runFormattingInlineCarriers.d.ts +16 -15
- package/dist/prosemirror/runFormattingInlineCarriers.js +1 -0
- package/dist/prosemirror/runFormattingMarkNames.d.ts +2 -3
- package/dist/prosemirror/runFormattingProvenance.d.ts +5 -6
- package/dist/prosemirror/runFormattingReconciliation.d.ts +4 -4
- package/dist/prosemirror/runFormattingReconciliation.js +6 -4
- package/dist/prosemirror/runIdentity.d.ts +6 -7
- package/dist/prosemirror/runIdentityAcrossRevisions.d.ts +16 -5
- package/dist/prosemirror/runIdentityAcrossRevisions.js +92 -32
- package/dist/prosemirror/runPropertyChangeResolution.d.ts +3 -3
- package/dist/prosemirror/runPropertyChangeResolution.js +11 -10
- package/dist/prosemirror/runStyleFormatting.d.ts +23 -23
- package/dist/prosemirror/runStyleFormatting.js +4 -2
- package/dist/prosemirror/schema/index.d.ts +7 -6
- package/dist/prosemirror/schema/index.js +0 -7
- package/dist/prosemirror/schema/marks.d.ts +36 -39
- package/dist/prosemirror/schema/nodes.d.ts +42 -35
- package/dist/prosemirror/sectionCarrier.d.ts +7 -8
- package/dist/prosemirror/sectionMarkEdits.d.ts +3 -4
- package/dist/prosemirror/sectionMarkEdits.js +21 -1
- package/dist/prosemirror/selectionMarks.d.ts +2 -2
- package/dist/prosemirror/selectionState.d.ts +5 -6
- package/dist/prosemirror/selectionState.js +1 -4
- package/dist/prosemirror/shapeGeometryAdjustments.d.ts +2 -3
- package/dist/prosemirror/storyListNumbering.d.ts +2 -2
- package/dist/prosemirror/storyListNumbering.js +2 -1
- package/dist/prosemirror/styles/index.js +1 -2
- package/dist/prosemirror/styles/paragraphStyleCascade.d.ts +9 -9
- package/dist/prosemirror/styles/paragraphStyleCascade.js +17 -2
- package/dist/prosemirror/styles/resolvedStyleAttrs.d.ts +8 -8
- package/dist/prosemirror/styles/styleResolver.d.ts +6 -7
- package/dist/prosemirror/styles/styleResolver.js +17 -0
- package/dist/prosemirror/styles/styleToggleCascade.d.ts +4 -4
- package/dist/prosemirror/styles/tableStyleRegions.d.ts +5 -6
- package/dist/prosemirror/tableCellMergeRevision.d.ts +3 -4
- package/dist/prosemirror/tableCellPaste.d.ts +11 -12
- package/dist/prosemirror/tableCellRevisionVisibility.d.ts +2 -3
- package/dist/prosemirror/tableGridMutation.d.ts +12 -12
- package/dist/prosemirror/tableResize.d.ts +18 -18
- package/dist/prosemirror/tableResize.js +64 -53
- package/dist/prosemirror/tableRunIn.d.ts +10 -5
- package/dist/prosemirror/tableRunIn.js +44 -9
- package/dist/prosemirror/textBoxAnchorAttrs.d.ts +3 -4
- package/dist/prosemirror/textBoxAnchorAttrs.js +4 -1
- package/dist/prosemirror/textBoxHostCollapse.d.ts +8 -0
- package/dist/prosemirror/textBoxHostCollapse.js +79 -0
- package/dist/prosemirror/textBoxHostParagraph.d.ts +2 -3
- package/dist/prosemirror/textInput.d.ts +13 -6
- package/dist/prosemirror/textInput.js +26 -2
- package/dist/prosemirror/trackedRevisionPath.d.ts +6 -6
- package/dist/prosemirror/trackedRevisionPath.js +7 -4
- package/dist/prosemirror/trackedRunInlineAtoms.d.ts +8 -8
- package/dist/prosemirror/trackedRunInlineAtoms.js +3 -2
- package/dist/prosemirror/utils/extractTrackedChanges.d.ts +4 -5
- package/dist/prosemirror/utils/findParagraphByParaId.d.ts +3 -4
- package/dist/prosemirror/utils/tabCalculator.js +1 -2
- package/dist/prosemirror/utils/visualLineNavigation.d.ts +7 -7
- package/dist/prosemirror/utils/visualLineNavigation.js +2 -14
- package/dist/prosemirror/validation.d.ts +7 -8
- package/dist/prosemirror/validation.js +25 -10
- package/dist/prosemirror/yjsDocumentMetadata.d.ts +19 -19
- package/dist/prosemirror/yjsDocumentMetadata.js +21 -15
- package/dist/prosemirror/zeroWidthAnchors.d.ts +7 -6
- package/dist/prosemirror/zeroWidthAnchors.js +53 -16
- package/dist/redline.d.ts +11 -10
- package/dist/redline.js +6 -3
- package/dist/redlineOperationLimit.d.ts +5 -4
- package/dist/redlineOperationLimit.js +2 -1
- package/dist/render-dom/BodySelectionOverlay.d.ts +4 -5
- package/dist/render-dom/HeaderFooterSelectionOverlay.d.ts +6 -7
- package/dist/render-dom/RemoteSelectionOverlay.d.ts +5 -6
- package/dist/render-dom/RenderedDomContext.d.ts +6 -7
- package/dist/render-dom/commentAnchorAttributes.d.ts +6 -6
- package/dist/render-dom/resolveSidebarItemPositions.d.ts +5 -6
- package/dist/reviewHistoryLimits.d.ts +3 -0
- package/dist/reviewHistoryLimits.js +4 -0
- package/dist/server.d.ts +2 -1
- package/dist/server.js +2 -1
- package/dist/shaping/placeRun.d.ts +7 -8
- package/dist/shaping/shaper.d.ts +18 -36
- package/dist/shaping/shaper.js +2 -1
- package/dist/style-engine/index.js +1 -2
- package/dist/style-engine/styleEngine.d.ts +5 -6
- package/dist/style-sets/extract.d.ts +8 -9
- package/dist/style-sets/stellaStyle.d.ts +4 -5
- package/dist/style-sets/styleSetNormalization.d.ts +6 -7
- package/dist/style-sets/types.d.ts +5 -6
- package/dist/symbols.d.ts +8 -9
- package/dist/types/block-id.d.ts +11 -12
- package/dist/types/canonicalCapabilities.d.ts +11 -19
- package/dist/types/canonicalCapabilities.js +5 -12
- package/dist/types/canonicalComments.d.ts +3 -4
- package/dist/types/canonicalSave.d.ts +2 -3
- package/dist/types/canonicalSections.d.ts +2 -3
- package/dist/types/documentEnumValues.d.ts +48 -49
- package/dist/types/docxSerialization.d.ts +4 -5
- package/dist/types/editor-story.d.ts +2 -3
- package/dist/types/remote-selection.d.ts +2 -3
- package/dist/types/wrap.d.ts +5 -6
- package/dist/utils/authorColors.d.ts +4 -5
- package/dist/utils/base64.d.ts +2 -2
- package/dist/utils/baseDirection.d.ts +4 -5
- package/dist/utils/borderCss.d.ts +9 -10
- package/dist/utils/boundedContentIdentity.d.ts +13 -0
- package/dist/utils/boundedContentIdentity.js +42 -0
- package/dist/utils/canonicalJson.d.ts +2 -3
- package/dist/utils/clipboard.d.ts +23 -23
- package/dist/utils/clipboard.js +11 -8
- package/dist/utils/colorResolver.d.ts +22 -23
- package/dist/utils/colorResolver.js +0 -20
- package/dist/utils/createDocument.d.ts +4 -4
- package/dist/utils/cursiveJoining.d.ts +7 -8
- package/dist/utils/documentLoaderBehavior.d.ts +3 -4
- package/dist/utils/documentPointerDown.d.ts +5 -0
- package/dist/utils/documentPointerDown.js +28 -0
- package/dist/utils/docxInput.d.ts +3 -4
- package/dist/utils/domGuards.d.ts +7 -8
- package/dist/utils/findMatchView.d.ts +4 -4
- package/dist/utils/findReplace.d.ts +16 -16
- package/dist/utils/findSearchKey.d.ts +5 -5
- package/dist/utils/findVerticalScrollParent.d.ts +3 -4
- package/dist/utils/fontFamilyMerge.d.ts +2 -2
- package/dist/utils/fontLoader.d.ts +12 -13
- package/dist/utils/fontResolver.d.ts +16 -14
- package/dist/utils/fontResolver.js +33 -5
- package/dist/utils/fontWeights.d.ts +2 -3
- package/dist/utils/formatToStyle.d.ts +14 -14
- package/dist/utils/formatToStyle.js +17 -15
- package/dist/utils/headerFooter.d.ts +11 -12
- package/dist/utils/headerFooter.js +10 -0
- package/dist/utils/headingCollector.d.ts +3 -4
- package/dist/utils/hexId.d.ts +6 -7
- package/dist/utils/hexId.js +1 -1
- package/dist/utils/horizontalScale.d.ts +5 -6
- package/dist/utils/htmlComments.d.ts +2 -3
- package/dist/utils/imageLuminance.d.ts +4 -5
- package/dist/utils/imageResize.d.ts +18 -0
- package/dist/utils/imageResize.js +37 -0
- package/dist/utils/imageValidation.d.ts +3 -4
- package/dist/utils/imageValidation.js +1 -1
- package/dist/utils/joiningTypes.gen.d.ts +5 -6
- package/dist/utils/mergeDocumentContent.d.ts +2 -3
- package/dist/utils/mergeDocumentContent.js +7 -0
- package/dist/utils/noteReferenceLabels.d.ts +7 -8
- package/dist/utils/ooxmlSymbol.d.ts +5 -3
- package/dist/utils/ooxmlSymbol.js +51 -1
- package/dist/utils/outlineDepth.d.ts +4 -5
- package/dist/utils/paragraphBaseDirection.d.ts +2 -3
- package/dist/utils/paragraphBaseDirection.js +2 -1
- package/dist/utils/paragraphFormattingMerge.d.ts +4 -5
- package/dist/utils/paragraphFormattingMerge.js +2 -0
- package/dist/utils/paragraphFrame.d.ts +20 -0
- package/dist/utils/paragraphFrame.js +13 -0
- package/dist/utils/paragraphInlineLayout.d.ts +101 -4
- package/dist/utils/paragraphInlineLayout.js +164 -1
- package/dist/utils/replaceText.d.ts +2 -2
- package/dist/utils/replaceText.js +4 -0
- package/dist/utils/rotationBoundingBox.d.ts +7 -8
- package/dist/utils/sanitizeImageSrc.d.ts +3 -4
- package/dist/utils/scriptSegments.d.ts +34 -16
- package/dist/utils/scriptSegments.js +26 -6
- package/dist/utils/sliceText.js +1 -2
- package/dist/utils/stripXmlDeclarations.d.ts +2 -3
- package/dist/utils/tableOfContentsStyle.d.ts +2 -2
- package/dist/utils/tableOperations.d.ts +16 -17
- package/dist/utils/tableOperations.js +44 -41
- package/dist/utils/tablePlacement.d.ts +3 -4
- package/dist/utils/textAdvanceGapsDom.d.ts +8 -0
- package/dist/utils/textAdvanceGapsDom.js +49 -0
- package/dist/utils/textDirectionFlow.d.ts +3 -4
- package/dist/utils/textEncoding.js +1 -2
- package/dist/utils/textFormattingMerge.d.ts +4 -5
- package/dist/utils/tiffConverter.d.ts +5 -6
- package/dist/utils/trailingText.d.ts +4 -5
- package/dist/utils/units.d.ts +19 -20
- package/dist/utils/urlSecurity.d.ts +6 -6
- package/dist/utils/urlSecurity.js +2 -1
- package/dist/utils/zoom.d.ts +4 -5
- package/dist/version-comparison.d.ts +30 -29
- package/dist/version-comparison.js +10 -8
- package/dist/watermark/index.d.ts +5 -5
- package/dist/watermark/index.js +9 -0
- package/package.json +16 -16
|
@@ -5,32 +5,43 @@ import { inlineBookmarksOf } from "../prosemirror/commands/paragraphBookmarkJoin
|
|
|
5
5
|
import { resolveAllTableChanges } from "../prosemirror/commands/resolveAllTableChanges.js";
|
|
6
6
|
import { resolveAllNodePropertyChangeAttrs } from "../prosemirror/commands/resolveNodePropertyChangeAttrs.js";
|
|
7
7
|
import { resolveParagraphChangeAttrs } from "../prosemirror/commands/resolveParagraphProperties.js";
|
|
8
|
+
import { resolveCommentReferences } from "../prosemirror/commentReferenceIntegrity.js";
|
|
9
|
+
import { isBlockBoundaryNode, paragraphRemainsOf } from "../prosemirror/keptRangeBoundaries.js";
|
|
10
|
+
import { joinedParagraphAttrs } from "../prosemirror/paragraphMarkJoin.js";
|
|
8
11
|
import { rebaseParagraphRunContent } from "../prosemirror/rebaseParagraphRuns.js";
|
|
9
12
|
import { createResolvedCommentPointCollector } from "../prosemirror/replacedAnnotations.js";
|
|
10
13
|
import { expandRunFormattingCarrier } from "../prosemirror/runFormattingInlineCarriers.js";
|
|
11
14
|
import { readAuthoredRunFormatting, reconcileRunFormattingMarks } from "../prosemirror/runFormattingReconciliation.js";
|
|
12
15
|
import { paragraphRunStyleContext } from "../prosemirror/runStyleFormatting.js";
|
|
13
16
|
import { runParagraphsIntoTables, runsIntoFollowingTable } from "../prosemirror/tableRunIn.js";
|
|
14
|
-
import {
|
|
17
|
+
import { paragraphContentOf } from "../prosemirror/zeroWidthAnchors.js";
|
|
15
18
|
import { recordNodeResolution } from "./revisionResolutionEdits.js";
|
|
16
19
|
import { resolveInlineRevisions } from "./revisionResolutionInline.js";
|
|
17
20
|
import { composeRevisionResolutionMaps } from "./revisionResolutionStep.js";
|
|
18
21
|
import { REVIEW_CARRIERS } from "@stll/docx-core/model";
|
|
19
22
|
import { Fragment, Slice } from "prosemirror-model";
|
|
20
23
|
import { Mapping, ReplaceStep, StepMap, Transform } from "prosemirror-transform";
|
|
24
|
+
import { paragraphMarkOutcome } from "@stll/docx-core/ops";
|
|
21
25
|
//#region src/internal/wholeStoryRevisionResolution.ts
|
|
22
26
|
const resolveProperties = ({ doc, mode, styleResolver, numbering, steps, changedRanges }) => {
|
|
27
|
+
const removedMark = doc.type.schema.marks[mode === "accept" ? "deletion" : "insertion"];
|
|
23
28
|
const collector = createResolvedCommentPointCollector({
|
|
24
|
-
removes: (node) =>
|
|
29
|
+
removes: (node) => removedMark?.isInSet(node.marks) !== void 0,
|
|
25
30
|
retiresStructure: () => mode === "accept"
|
|
26
31
|
});
|
|
27
32
|
let structural = false;
|
|
33
|
+
let removedEndpointCount = 0;
|
|
34
|
+
const removedReferences = [];
|
|
28
35
|
let runsIntoTable = false;
|
|
29
36
|
const walk = ({ node, position, eligibleComments = true, previous }) => {
|
|
30
37
|
const childComments = eligibleComments && collector.visit(node, position, previous);
|
|
31
38
|
if (node.isText) return node;
|
|
32
39
|
if (!runsIntoTable && !node.isTextblock) {
|
|
33
|
-
for (let index = 0; index + 1 < node.childCount; index++) if (runsIntoFollowingTable(
|
|
40
|
+
for (let index = 0; index + 1 < node.childCount; index++) if (runsIntoFollowingTable({
|
|
41
|
+
parent: node,
|
|
42
|
+
index,
|
|
43
|
+
mode
|
|
44
|
+
})) {
|
|
34
45
|
runsIntoTable = true;
|
|
35
46
|
break;
|
|
36
47
|
}
|
|
@@ -44,8 +55,23 @@ const resolveProperties = ({ doc, mode, styleResolver, numbering, steps, changed
|
|
|
44
55
|
numbering
|
|
45
56
|
}) : null;
|
|
46
57
|
let resolved = node;
|
|
47
|
-
if (nextAttrs)
|
|
48
|
-
|
|
58
|
+
if (nextAttrs) {
|
|
59
|
+
if (node.type.name === "paragraph" && ownsSection(node) && nextAttrs["_sectionProperties"] == null) {
|
|
60
|
+
const properties = expectParagraphAttrs(node)._sectionProperties;
|
|
61
|
+
removedEndpointCount++;
|
|
62
|
+
for (const { type, rId } of properties?.headerReferences ?? []) removedReferences.push({
|
|
63
|
+
part: "header",
|
|
64
|
+
type,
|
|
65
|
+
relationshipId: rId
|
|
66
|
+
});
|
|
67
|
+
for (const { type, rId } of properties?.footerReferences ?? []) removedReferences.push({
|
|
68
|
+
part: "footer",
|
|
69
|
+
type,
|
|
70
|
+
relationshipId: rId
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
resolved = recreateProseNodeWithParagraphPropertySource(node, { attrs: nextAttrs });
|
|
74
|
+
} else if (node.type.name !== "paragraph") resolved = resolveAllNodePropertyChangeAttrs(node, mode);
|
|
49
75
|
if (resolved !== node) {
|
|
50
76
|
if (node.type.name === "paragraph") changedRanges.push({
|
|
51
77
|
from: position,
|
|
@@ -68,13 +94,13 @@ const resolveProperties = ({ doc, mode, styleResolver, numbering, steps, changed
|
|
|
68
94
|
const carrier = expandRunFormattingCarrier(inline, pos);
|
|
69
95
|
if (!carrier) return !inline.isAtom;
|
|
70
96
|
for (const { node: representation } of carrier.representations) {
|
|
71
|
-
|
|
97
|
+
const authoredFormatting = readAuthoredRunFormatting({
|
|
98
|
+
context: previousContext,
|
|
99
|
+
marks: representation.marks,
|
|
100
|
+
styleResolver
|
|
101
|
+
});
|
|
72
102
|
const marks = reconcileRunFormattingMarks({
|
|
73
|
-
authoredFormatting
|
|
74
|
-
context: previousContext,
|
|
75
|
-
marks: representation.marks,
|
|
76
|
-
styleResolver
|
|
77
|
-
}),
|
|
103
|
+
authoredFormatting,
|
|
78
104
|
context: nextContext,
|
|
79
105
|
node: representation,
|
|
80
106
|
styleResolver
|
|
@@ -120,7 +146,9 @@ const resolveProperties = ({ doc, mode, styleResolver, numbering, steps, changed
|
|
|
120
146
|
}),
|
|
121
147
|
structural,
|
|
122
148
|
runsIntoTable,
|
|
123
|
-
|
|
149
|
+
removedEndpointCount,
|
|
150
|
+
removedReferences,
|
|
151
|
+
pointComments: mode === "accept" ? new Set(collector.finish().keys()) : /* @__PURE__ */ new Set()
|
|
124
152
|
};
|
|
125
153
|
};
|
|
126
154
|
const structuralReplacementMap = ({ replacements, tables, bookmarkJoins, origin }) => {
|
|
@@ -224,6 +252,14 @@ const removedEndpoint = (node, context) => {
|
|
|
224
252
|
relationshipId: rId
|
|
225
253
|
});
|
|
226
254
|
};
|
|
255
|
+
/** A cleared record (null) and an absent one (undefined) both end no section. */
|
|
256
|
+
const ownsSection = (paragraph) => expectParagraphAttrs(paragraph)._sectionProperties != null;
|
|
257
|
+
const precedingSectionOwner = (preceding, properties) => {
|
|
258
|
+
if (preceding?.type.name !== "paragraph") return "unavailable";
|
|
259
|
+
if (!ownsSection(preceding)) return "available";
|
|
260
|
+
const precedingProperties = expectParagraphAttrs(preceding)._sectionProperties;
|
|
261
|
+
return JSON.stringify(precedingProperties) === JSON.stringify(properties) ? "same" : "occupied";
|
|
262
|
+
};
|
|
227
263
|
const resolveStructure = ({ node, position, context }) => {
|
|
228
264
|
if (node.isLeaf) return node;
|
|
229
265
|
const textBoxAnchor = anchoredTextBoxId(node);
|
|
@@ -252,6 +288,12 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
252
288
|
let chain = null;
|
|
253
289
|
let pendingBookmarks = [];
|
|
254
290
|
let followingContainerChild = false;
|
|
291
|
+
const precedingParagraphs = [];
|
|
292
|
+
let previousSurvivorIsParagraph = false;
|
|
293
|
+
for (const { node: child } of entries) {
|
|
294
|
+
precedingParagraphs.push(previousSurvivorIsParagraph);
|
|
295
|
+
if (child !== null && !isBlockBoundaryNode(child)) previousSurvivorIsParagraph = child.type.name === "paragraph";
|
|
296
|
+
}
|
|
255
297
|
const flush = () => {
|
|
256
298
|
if (!chain) return;
|
|
257
299
|
let final = chain.node;
|
|
@@ -337,7 +379,7 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
337
379
|
paragraph = filler;
|
|
338
380
|
}
|
|
339
381
|
if (paragraph.type.name !== "paragraph") {
|
|
340
|
-
if (paragraph
|
|
382
|
+
if (isBlockBoundaryNode(paragraph)) {
|
|
341
383
|
pendingBookmarks.push(paragraph);
|
|
342
384
|
continue;
|
|
343
385
|
}
|
|
@@ -350,6 +392,26 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
350
392
|
const markWasAdded = marker?.kind === "ins" || marker?.kind === "moveTo";
|
|
351
393
|
const joins = marker && markWasAdded !== (context.mode === "accept");
|
|
352
394
|
if (joins && chain) {
|
|
395
|
+
const properties = expectParagraphAttrs(paragraph)._sectionProperties;
|
|
396
|
+
const preceding = entries[index - 1]?.node;
|
|
397
|
+
const outcome = paragraphMarkOutcome({
|
|
398
|
+
follows: "paragraph",
|
|
399
|
+
holdsContent: paragraphContentOf(paragraph),
|
|
400
|
+
markWasAdded,
|
|
401
|
+
containerStillEndsWithParagraph: true,
|
|
402
|
+
followingTableCanReceiveRunIn: false,
|
|
403
|
+
removedSectionProperties: markWasAdded && properties !== void 0,
|
|
404
|
+
precedingSectionOwner: precedingSectionOwner(preceding, properties),
|
|
405
|
+
followingHasSectionProperties: ownsSection(chain.node)
|
|
406
|
+
});
|
|
407
|
+
if (outcome.sectionDestination === "preceding" && preceding?.type.name === "paragraph") entries[index - 1].node = recreateProseNodeWithParagraphPropertySource(preceding, { attrs: {
|
|
408
|
+
...preceding.attrs,
|
|
409
|
+
_sectionProperties: properties
|
|
410
|
+
} });
|
|
411
|
+
else if (outcome.sectionDestination === "following") chain.node = recreateProseNodeWithParagraphPropertySource(chain.node, { attrs: {
|
|
412
|
+
...chain.node.attrs,
|
|
413
|
+
_sectionProperties: properties
|
|
414
|
+
} });
|
|
353
415
|
const boundaries = pendingBookmarks.toReversed();
|
|
354
416
|
let bookmarks = Fragment.empty;
|
|
355
417
|
if (boundaries.length > 0) {
|
|
@@ -365,6 +427,8 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
365
427
|
});
|
|
366
428
|
pendingBookmarks = [];
|
|
367
429
|
}
|
|
430
|
+
const joinedAttrs = joinedParagraphAttrs(paragraph, chain.node);
|
|
431
|
+
if (joinedAttrs !== chain.node.attrs) chain.node = recreateProseNodeWithParagraphPropertySource(chain.node, { attrs: joinedAttrs });
|
|
368
432
|
const displacedToken = getProseParagraphPropertySourceToken(paragraph);
|
|
369
433
|
const selectedToken = getProseParagraphPropertySourceToken(chain.node);
|
|
370
434
|
context.transfers.push({
|
|
@@ -386,11 +450,54 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
386
450
|
continue;
|
|
387
451
|
}
|
|
388
452
|
flushBookmarks();
|
|
389
|
-
|
|
390
|
-
|
|
453
|
+
let follows = "nothing";
|
|
454
|
+
if (chain) follows = "paragraph";
|
|
455
|
+
else if (followingContainerChild) follows = "table";
|
|
456
|
+
let containerStillEndsWithParagraph = true;
|
|
457
|
+
if (follows === "table") containerStillEndsWithParagraph = node.lastChild?.type.name === "paragraph";
|
|
458
|
+
else if (follows === "nothing") containerStillEndsWithParagraph = precedingParagraphs[index] === true;
|
|
459
|
+
const outcome = paragraphMarkOutcome({
|
|
460
|
+
follows,
|
|
461
|
+
holdsContent: paragraphContentOf(paragraph),
|
|
462
|
+
markWasAdded,
|
|
463
|
+
containerStillEndsWithParagraph,
|
|
464
|
+
followingTableCanReceiveRunIn: false,
|
|
465
|
+
removedSectionProperties: markWasAdded && ownsSection(paragraph),
|
|
466
|
+
precedingSectionOwner: precedingSectionOwner(entries[index - 1]?.node, expectParagraphAttrs(paragraph)._sectionProperties),
|
|
467
|
+
followingHasSectionProperties: chain !== null && ownsSection(chain.node)
|
|
468
|
+
});
|
|
469
|
+
const remains = marker && !paragraphContentOf(paragraph) && outcome.kind === "remove" && joins && index + reversed.length + 1 > 1 ? paragraphRemainsOf(paragraph) : void 0;
|
|
470
|
+
const between = follows === "table" ? remains?.blocks ?? [] : [];
|
|
471
|
+
const toPrevious = follows === "table" ? remains?.comments ?? [] : remains?.inline ?? [];
|
|
472
|
+
const commentHost = entries[index - 1]?.node;
|
|
473
|
+
if (remains !== void 0 && (toPrevious.length === 0 || commentHost?.type.name === "paragraph")) {
|
|
474
|
+
const properties = expectParagraphAttrs(paragraph)._sectionProperties;
|
|
475
|
+
const hostEntry = entries[index - 1];
|
|
476
|
+
if (toPrevious.length > 0 && commentHost && hostEntry) {
|
|
477
|
+
const comments = Fragment.fromArray(toPrevious);
|
|
478
|
+
hostEntry.node = recreateProseNodeWithParagraphPropertySource(commentHost, { content: commentHost.content.append(comments) });
|
|
479
|
+
const hostEnd = hostEntry.position + hostEntry.original.nodeSize - 1;
|
|
480
|
+
context.replacements.push({
|
|
481
|
+
from: hostEnd,
|
|
482
|
+
to: hostEnd,
|
|
483
|
+
slice: new Slice(comments, 0, 0)
|
|
484
|
+
});
|
|
485
|
+
}
|
|
486
|
+
const preceding = entries[index - 1]?.node;
|
|
487
|
+
if (outcome.sectionDestination === "preceding" && preceding?.type.name === "paragraph") entries[index - 1].node = recreateProseNodeWithParagraphPropertySource(preceding, { attrs: {
|
|
488
|
+
...preceding.attrs,
|
|
489
|
+
_sectionProperties: properties
|
|
490
|
+
} });
|
|
491
|
+
else if (outcome.sectionDestination === "following" && chain) chain.node = recreateProseNodeWithParagraphPropertySource(chain.node, { attrs: {
|
|
492
|
+
...chain.node.attrs,
|
|
493
|
+
_sectionProperties: properties
|
|
494
|
+
} });
|
|
495
|
+
context.replacements.push({
|
|
391
496
|
from: entry.position,
|
|
392
|
-
to: entry.position +
|
|
497
|
+
to: entry.position + entry.original.nodeSize,
|
|
498
|
+
slice: new Slice(Fragment.fromArray(between), 0, 0)
|
|
393
499
|
});
|
|
500
|
+
for (const block of between.toReversed()) reversed.push(block);
|
|
394
501
|
removedEndpoint(paragraph, context);
|
|
395
502
|
continue;
|
|
396
503
|
}
|
|
@@ -424,37 +531,39 @@ const resolveStructure = ({ node, position, context }) => {
|
|
|
424
531
|
return !pending;
|
|
425
532
|
});
|
|
426
533
|
const entry = entries.at(-1);
|
|
427
|
-
if (!pending && entry)
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
reversed.
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
to: entry.position + carrier.nodeSize
|
|
448
|
-
});
|
|
449
|
-
} else {
|
|
450
|
-
const filler = node.type.schema.nodes["paragraph"]?.createAndFill();
|
|
451
|
-
if (filler) {
|
|
452
|
-
reversed[0] = filler;
|
|
453
|
-
context.replacements.push({
|
|
534
|
+
if (!pending && entry) {
|
|
535
|
+
if (context.mode === "accept") {
|
|
536
|
+
const cleared = recreateProseNodeWithParagraphPropertySource(carrier, { attrs: {
|
|
537
|
+
...carrier.attrs,
|
|
538
|
+
reviewCarrier: void 0
|
|
539
|
+
} });
|
|
540
|
+
recordNodeResolution({
|
|
541
|
+
before: carrier,
|
|
542
|
+
after: cleared,
|
|
543
|
+
position: entry.position,
|
|
544
|
+
steps: context.steps
|
|
545
|
+
});
|
|
546
|
+
context.changedRanges.push({
|
|
547
|
+
from: entry.position,
|
|
548
|
+
to: entry.position + carrier.nodeSize
|
|
549
|
+
});
|
|
550
|
+
reversed[reversed.length - 1] = cleared;
|
|
551
|
+
} else if (reversed.length > 1) {
|
|
552
|
+
reversed.pop();
|
|
553
|
+
context.deleted.push({
|
|
454
554
|
from: entry.position,
|
|
455
|
-
to: entry.position + carrier.nodeSize
|
|
456
|
-
slice: new Slice(Fragment.from(filler), 0, 0)
|
|
555
|
+
to: entry.position + carrier.nodeSize
|
|
457
556
|
});
|
|
557
|
+
} else {
|
|
558
|
+
const filler = node.type.schema.nodes["paragraph"]?.createAndFill();
|
|
559
|
+
if (filler) {
|
|
560
|
+
reversed[0] = filler;
|
|
561
|
+
context.replacements.push({
|
|
562
|
+
from: entry.position,
|
|
563
|
+
to: entry.position + carrier.nodeSize,
|
|
564
|
+
slice: new Slice(Fragment.from(filler), 0, 0)
|
|
565
|
+
});
|
|
566
|
+
}
|
|
458
567
|
}
|
|
459
568
|
}
|
|
460
569
|
}
|
|
@@ -559,6 +668,8 @@ const resolveStoryRevisions = ({ doc, mode, styleResolver, numbering }) => {
|
|
|
559
668
|
keepType: doc.type.schema.marks[mode === "accept" ? "insertion" : "deletion"],
|
|
560
669
|
removeType: doc.type.schema.marks[mode === "accept" ? "deletion" : "insertion"]
|
|
561
670
|
});
|
|
671
|
+
const inlineResolved = inline?.resolved ?? properties;
|
|
672
|
+
const comments = inline ? resolveCommentReferences(inlineResolved) : null;
|
|
562
673
|
const context = {
|
|
563
674
|
mode,
|
|
564
675
|
styleResolver,
|
|
@@ -571,16 +682,17 @@ const resolveStoryRevisions = ({ doc, mode, styleResolver, numbering }) => {
|
|
|
571
682
|
bookmarkJoins: [],
|
|
572
683
|
structural: propertyResult.structural,
|
|
573
684
|
failed: false,
|
|
574
|
-
removedEndpointCount:
|
|
575
|
-
removedReferences: [],
|
|
576
|
-
droppedTextBoxAnchors: inline ? droppedTextBoxAnchorIds(properties,
|
|
685
|
+
removedEndpointCount: propertyResult.removedEndpointCount,
|
|
686
|
+
removedReferences: [...propertyResult.removedReferences],
|
|
687
|
+
droppedTextBoxAnchors: inline ? droppedTextBoxAnchorIds(properties, inlineResolved) : /* @__PURE__ */ new Set()
|
|
577
688
|
};
|
|
578
689
|
const resolved = resolveStructure({
|
|
579
|
-
node:
|
|
690
|
+
node: comments?.doc ?? inlineResolved,
|
|
580
691
|
position: -1,
|
|
581
692
|
context
|
|
582
693
|
}) ?? doc;
|
|
583
694
|
if (inline) steps.push(...inline.steps);
|
|
695
|
+
if (comments) steps.push(...comments.steps);
|
|
584
696
|
steps.push(...context.steps);
|
|
585
697
|
const replacements = [...context.replacements, ...context.deleted.map(({ from, to }) => ({
|
|
586
698
|
from,
|
|
@@ -594,14 +706,16 @@ const resolveStoryRevisions = ({ doc, mode, styleResolver, numbering }) => {
|
|
|
594
706
|
origin: 0
|
|
595
707
|
});
|
|
596
708
|
for (const { from, to, slice } of replacements.toReversed()) steps.push(new ReplaceStep(from, to, slice));
|
|
597
|
-
|
|
709
|
+
let preStructureMap = inline?.positionMap ?? StepMap.empty;
|
|
710
|
+
for (const map of comments?.positionMaps ?? []) preStructureMap = composeRevisionResolutionMaps(preStructureMap, map);
|
|
711
|
+
const positionMap = composeRevisionResolutionMaps(preStructureMap, structuralMap);
|
|
598
712
|
return {
|
|
599
713
|
resolved,
|
|
600
714
|
mapping: new Mapping([positionMap]),
|
|
601
715
|
positionMap,
|
|
602
716
|
steps,
|
|
603
717
|
changedRanges: [...propertyRanges, ...inline?.ranges ?? []],
|
|
604
|
-
|
|
718
|
+
preStructureMap,
|
|
605
719
|
tableRanges: context.tableRanges,
|
|
606
720
|
transfers: context.transfers,
|
|
607
721
|
structuralRanges: context.changedRanges,
|
|
@@ -610,7 +724,9 @@ const resolveStoryRevisions = ({ doc, mode, styleResolver, numbering }) => {
|
|
|
610
724
|
failed: context.failed,
|
|
611
725
|
removedEndpointCount: context.removedEndpointCount,
|
|
612
726
|
removedReferences: context.removedReferences,
|
|
613
|
-
runsIntoTable: propertyResult.runsIntoTable
|
|
727
|
+
runsIntoTable: propertyResult.runsIntoTable,
|
|
728
|
+
/** The boundaries removed content left standing, for the range repair. */
|
|
729
|
+
keptBoundaries: inline?.keptBoundaries ?? /* @__PURE__ */ new Set()
|
|
614
730
|
};
|
|
615
731
|
};
|
|
616
732
|
//#endregion
|
|
@@ -10,8 +10,7 @@ import { EditorState } from "prosemirror-state";
|
|
|
10
10
|
* `instanceof` to dodge bundling issues across `prosemirror-tables` copies
|
|
11
11
|
* (the same trick used inline in the selection-overlay update).
|
|
12
12
|
*/
|
|
13
|
-
declare function applyCellSelectionHighlight(pagesContainer: HTMLElement, state: EditorState, options?: {
|
|
13
|
+
export declare function applyCellSelectionHighlight(pagesContainer: HTMLElement, state: EditorState, options?: {
|
|
14
14
|
scope?: "body" | "header" | "footer";
|
|
15
15
|
}): void;
|
|
16
|
-
//#endregion
|
|
17
|
-
export { applyCellSelectionHighlight };
|
|
16
|
+
//#endregion
|
|
@@ -13,13 +13,13 @@ type EndnoteArea = {
|
|
|
13
13
|
blocks: FlowBlock[];
|
|
14
14
|
measures: Measure[];
|
|
15
15
|
};
|
|
16
|
-
type PreparedEndnoteAreas = {
|
|
16
|
+
export type PreparedEndnoteAreas = {
|
|
17
17
|
areas: readonly EndnoteArea[];
|
|
18
18
|
noteAreas: NoteAreaLayout;
|
|
19
19
|
/** The endnote each area content block belongs to, by block id. */
|
|
20
20
|
noteStoryByBlockId: ReadonlyMap<string, NoteStoryKey>;
|
|
21
21
|
};
|
|
22
|
-
type PrepareEndnoteAreasInput = {
|
|
22
|
+
export type PrepareEndnoteAreasInput = {
|
|
23
23
|
/** The body's top-level flow blocks, markers already renumbered. */
|
|
24
24
|
blocks: readonly FlowBlock[];
|
|
25
25
|
endnotes: readonly document_d_exports.Endnote[] | undefined;
|
|
@@ -42,12 +42,12 @@ type PrepareEndnoteAreasInput = {
|
|
|
42
42
|
* for. `undefined` when no reference names a note, so a document without
|
|
43
43
|
* endnotes lays out exactly as it did before.
|
|
44
44
|
*/
|
|
45
|
-
declare function prepareEndnoteAreas(input: PrepareEndnoteAreasInput): PreparedEndnoteAreas | undefined;
|
|
45
|
+
export declare function prepareEndnoteAreas(input: PrepareEndnoteAreasInput): PreparedEndnoteAreas | undefined;
|
|
46
46
|
/**
|
|
47
47
|
* The body blocks with each endnote area in place: before the section break
|
|
48
48
|
* that ends the section it follows, or after the last body block.
|
|
49
49
|
*/
|
|
50
|
-
declare function spliceEndnoteAreas(blocks: FlowBlock[], measures: Measure[], prepared: PreparedEndnoteAreas | undefined): {
|
|
50
|
+
export declare function spliceEndnoteAreas(blocks: FlowBlock[], measures: Measure[], prepared: PreparedEndnoteAreas | undefined): {
|
|
51
51
|
blocks: FlowBlock[];
|
|
52
52
|
measures: Measure[];
|
|
53
53
|
};
|
|
@@ -56,10 +56,10 @@ declare function spliceEndnoteAreas(blocks: FlowBlock[], measures: Measure[], pr
|
|
|
56
56
|
* `toFlowBlocks`' `trailingEndnoteIds`. Empty for `sectEnd`, whose final area
|
|
57
57
|
* depends on where the references fall.
|
|
58
58
|
*/
|
|
59
|
-
declare function trailingEndnoteIds(endnotes: readonly document_d_exports.Endnote[] | undefined, position: document_d_exports.EndnotePosition): ReadonlySet<number>;
|
|
59
|
+
export declare function trailingEndnoteIds(endnotes: readonly document_d_exports.Endnote[] | undefined, position: document_d_exports.EndnotePosition): ReadonlySet<number>;
|
|
60
60
|
/** `w:pos` for the document: the settings value, else the final section's. */
|
|
61
|
-
declare function resolveEndnotePosition(settingsPosition: document_d_exports.EndnotePosition | undefined, finalSection: document_d_exports.SectionProperties | undefined): document_d_exports.EndnotePosition;
|
|
61
|
+
export declare function resolveEndnotePosition(settingsPosition: document_d_exports.EndnotePosition | undefined, finalSection: document_d_exports.SectionProperties | undefined): document_d_exports.EndnotePosition;
|
|
62
62
|
/** The first column's width in a section: what an endnote area there wraps to. */
|
|
63
|
-
declare function endnoteAreaWidth(section: document_d_exports.SectionProperties | undefined): number;
|
|
63
|
+
export declare function endnoteAreaWidth(section: document_d_exports.SectionProperties | undefined): number;
|
|
64
64
|
//#endregion
|
|
65
|
-
export {
|
|
65
|
+
export {};
|
|
@@ -73,7 +73,8 @@ function prepareEndnoteAreas(input) {
|
|
|
73
73
|
const measures = [separator.measure];
|
|
74
74
|
separatorBlockIds.set(String(separator.block.id), "separator");
|
|
75
75
|
for (const noteId of noteIds) {
|
|
76
|
-
const
|
|
76
|
+
const note = notesById.get(noteId);
|
|
77
|
+
const content = convertFootnoteToContent(note, input.displayNumbers.get(noteId) ?? 0, width, {
|
|
77
78
|
...input.options,
|
|
78
79
|
displayText: input.displayTexts.get(noteId) ?? String(noteId)
|
|
79
80
|
});
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Node } from "prosemirror-model";
|
|
2
2
|
//#region src/layout-bridge/convert/fixedTableColumnWidths.d.ts
|
|
3
3
|
/** Resolve absolute cell preferences for an unbounded fixed-layout grid (§17.4.53). */
|
|
4
|
-
declare const fixedTableColumnWidths: (table: Node, grid: readonly number[]) => readonly number[];
|
|
5
|
-
//#endregion
|
|
6
|
-
export { fixedTableColumnWidths };
|
|
4
|
+
export declare const fixedTableColumnWidths: (table: Node, grid: readonly number[]) => readonly number[];
|
|
5
|
+
//#endregion
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { FlowBlock } from "../../layout-engine/types.js";
|
|
2
2
|
//#region src/layout-bridge/convert/flowBlockPostprocessing.d.ts
|
|
3
|
-
declare function suppressFinalEmptyParagraphAfterTable(blocks: FlowBlock[]): void;
|
|
4
|
-
declare function suppressFinalParagraphInRepeatedEmptySuffix(blocks: FlowBlock[]): void;
|
|
5
|
-
declare function reserveLeadingEmptyOutlineHeight(blocks: FlowBlock[]): void;
|
|
6
|
-
declare function mergeRunInParagraphs(blocks: FlowBlock[]): FlowBlock[];
|
|
7
|
-
//#endregion
|
|
8
|
-
export { mergeRunInParagraphs, reserveLeadingEmptyOutlineHeight, suppressFinalEmptyParagraphAfterTable, suppressFinalParagraphInRepeatedEmptySuffix };
|
|
3
|
+
export declare function suppressFinalEmptyParagraphAfterTable(blocks: FlowBlock[]): void;
|
|
4
|
+
export declare function suppressFinalParagraphInRepeatedEmptySuffix(blocks: FlowBlock[]): void;
|
|
5
|
+
export declare function reserveLeadingEmptyOutlineHeight(blocks: FlowBlock[]): void;
|
|
6
|
+
export declare function mergeRunInParagraphs(blocks: FlowBlock[]): FlowBlock[];
|
|
7
|
+
//#endregion
|
|
@@ -2,7 +2,7 @@ import { document_d_exports } from "../../types/document.js";
|
|
|
2
2
|
import { BorderStyle } from "../../layout-engine/types.js";
|
|
3
3
|
//#region src/layout-bridge/convert/flowBorders.d.ts
|
|
4
4
|
/** A parsed border, or the same shape read off ProseMirror attributes. */
|
|
5
|
-
type ConvertibleBorder = {
|
|
5
|
+
export type ConvertibleBorder = {
|
|
6
6
|
style?: document_d_exports.BorderStyleValue;
|
|
7
7
|
size?: number;
|
|
8
8
|
space?: number;
|
|
@@ -12,6 +12,5 @@ type ConvertibleBorder = {
|
|
|
12
12
|
* Convert an OOXML BorderSpec to a layout-engine BorderStyle.
|
|
13
13
|
* Shared by paragraph borders, cell borders, and header/footer borders.
|
|
14
14
|
*/
|
|
15
|
-
declare function convertBorderSpecToLayout(border: ConvertibleBorder, theme?: document_d_exports.Theme | null): BorderStyle | undefined;
|
|
16
|
-
//#endregion
|
|
17
|
-
export { ConvertibleBorder, convertBorderSpecToLayout };
|
|
15
|
+
export declare function convertBorderSpecToLayout(border: ConvertibleBorder, theme?: document_d_exports.Theme | null): BorderStyle | undefined;
|
|
16
|
+
//#endregion
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { document_d_exports } from "../../types/document.js";
|
|
2
2
|
import { RunStyleResolver } from "../../prosemirror/runStyleFormatting.js";
|
|
3
3
|
import { ListCounterStreams } from "../../prosemirror/listMarker.js";
|
|
4
|
+
import { DocumentFontFacts } from "../../fonts/documentFontFacts.js";
|
|
4
5
|
import { ParagraphAttrs, ParagraphBlock, TableBlock } from "../../layout-engine/types.js";
|
|
5
6
|
import { FontAlternates } from "../../fonts/fontAlternates.js";
|
|
6
7
|
import { Node } from "prosemirror-model";
|
|
@@ -8,11 +9,13 @@ import { Node } from "prosemirror-model";
|
|
|
8
9
|
/**
|
|
9
10
|
* Options for the conversion.
|
|
10
11
|
*/
|
|
11
|
-
type ToFlowBlocksOptions = {
|
|
12
|
+
export type ToFlowBlocksOptions = {
|
|
12
13
|
/** Paint comment anchors and highlights; false leaves authored marks intact. */
|
|
13
14
|
showCommentHighlights?: boolean;
|
|
14
15
|
/** Embedded families owned by this editor, never ambient process state. */
|
|
15
16
|
embeddedFontFamilyMap?: ReadonlyMap<string, string>;
|
|
17
|
+
/** Authored font-table facts owned by this document. */
|
|
18
|
+
documentFontFacts?: DocumentFontFacts;
|
|
16
19
|
/** Default font family. */
|
|
17
20
|
defaultFont?: string;
|
|
18
21
|
/** Default font size in points. */
|
|
@@ -92,7 +95,7 @@ type ToFlowBlocksOptions = {
|
|
|
92
95
|
*/
|
|
93
96
|
trailingEndnoteIds?: ReadonlySet<number>;
|
|
94
97
|
};
|
|
95
|
-
type FlowConversionOptions = ToFlowBlocksOptions & {
|
|
98
|
+
export type FlowConversionOptions = ToFlowBlocksOptions & {
|
|
96
99
|
firstPageBreakRunPosition: (node: Node) => number | undefined;
|
|
97
100
|
/** `w:doNotUseIndentAsNumberingTabStop`, read from the document node. */
|
|
98
101
|
numberingTabIgnoresIndent: boolean;
|
|
@@ -105,11 +108,10 @@ type FlowConversionOptions = ToFlowBlocksOptions & {
|
|
|
105
108
|
* Convert twips to pixels (1 twip = 1/1440 inch, 1 inch = 96 CSS px).
|
|
106
109
|
* No rounding — precision prevents cumulative layout drift across paragraphs.
|
|
107
110
|
*/
|
|
108
|
-
declare function twipsToPixels(twips: number): number;
|
|
109
|
-
declare function nextBlockId(): string;
|
|
111
|
+
export declare function twipsToPixels(twips: number): number;
|
|
112
|
+
export declare function nextBlockId(): string;
|
|
110
113
|
/**
|
|
111
114
|
* Reset the block ID counter (useful for testing).
|
|
112
115
|
*/
|
|
113
|
-
declare function resetBlockIdCounter(): void;
|
|
114
|
-
//#endregion
|
|
115
|
-
export { FlowConversionOptions, ToFlowBlocksOptions, nextBlockId, resetBlockIdCounter, twipsToPixels };
|
|
116
|
+
export declare function resetBlockIdCounter(): void;
|
|
117
|
+
//#endregion
|
|
@@ -4,8 +4,8 @@ import { FOOTNOTE_ENTRY_MARGIN_BOTTOM, FOOTNOTE_FALLBACK_LINE_HEIGHT, FOOTNOTE_S
|
|
|
4
4
|
import { ToFlowBlocksOptions } from "./flowConversionShared.js";
|
|
5
5
|
import "./toFlowBlocks.js";
|
|
6
6
|
//#region src/layout-bridge/convert/footnoteLayout.d.ts
|
|
7
|
-
type MeasureBlocksFn = (blocks: FlowBlock[], contentWidth: number) => Measure[];
|
|
8
|
-
type ConvertFootnoteOptions = Pick<ToFlowBlocksOptions, "embeddedFontFamilyMap"> & {
|
|
7
|
+
export type MeasureBlocksFn = (blocks: FlowBlock[], contentWidth: number) => Measure[];
|
|
8
|
+
export type ConvertFootnoteOptions = Pick<ToFlowBlocksOptions, "embeddedFontFamilyMap" | "documentFontFacts"> & {
|
|
9
9
|
/** Whether comment highlights are painted. Defaults to true. */
|
|
10
10
|
showCommentHighlights?: boolean;
|
|
11
11
|
markupView?: DisplayMode;
|
|
@@ -38,7 +38,7 @@ type ConvertFootnoteOptions = Pick<ToFlowBlocksOptions, "embeddedFontFamilyMap">
|
|
|
38
38
|
* render inside the body but never get an entry in the per-page footnote
|
|
39
39
|
* area.
|
|
40
40
|
*/
|
|
41
|
-
declare function collectFootnoteRefs(blocks: FlowBlock[]): {
|
|
41
|
+
export declare function collectFootnoteRefs(blocks: FlowBlock[]): {
|
|
42
42
|
footnoteId: number;
|
|
43
43
|
pmPos: number;
|
|
44
44
|
}[];
|
|
@@ -46,7 +46,7 @@ declare function collectFootnoteRefs(blocks: FlowBlock[]): {
|
|
|
46
46
|
* Scan FlowBlocks for runs with endnoteRefId set, in document order.
|
|
47
47
|
* Same recursive walk as `collectFootnoteRefs`.
|
|
48
48
|
*/
|
|
49
|
-
declare function collectEndnoteRefs(blocks: FlowBlock[]): {
|
|
49
|
+
export declare function collectEndnoteRefs(blocks: FlowBlock[]): {
|
|
50
50
|
endnoteId: number;
|
|
51
51
|
pmPos: number;
|
|
52
52
|
}[];
|
|
@@ -61,8 +61,8 @@ type NumberableNote = {
|
|
|
61
61
|
* `normal` notes are numbered; separator/continuation notes and refs to
|
|
62
62
|
* missing notes consume no number.
|
|
63
63
|
*/
|
|
64
|
-
declare function computeNoteDisplayNumbers(notes: readonly NumberableNote[], refNoteIds: readonly number[]): Map<number, number>;
|
|
65
|
-
type NoteDisplayNumberMaps = {
|
|
64
|
+
export declare function computeNoteDisplayNumbers(notes: readonly NumberableNote[], refNoteIds: readonly number[]): Map<number, number>;
|
|
65
|
+
export type NoteDisplayNumberMaps = {
|
|
66
66
|
/** footnote `w:id` → sequential display number */
|
|
67
67
|
footnoteNumbers?: ReadonlyMap<number, number>;
|
|
68
68
|
/** endnote `w:id` → formatted display text */
|
|
@@ -79,14 +79,14 @@ type NoteDisplayNumberMaps = {
|
|
|
79
79
|
* so click-to-position still resolves into the marker (same contract as the
|
|
80
80
|
* template preview substitution).
|
|
81
81
|
*/
|
|
82
|
-
declare function remapNoteMarkerText(blocks: FlowBlock[], maps: NoteDisplayNumberMaps): FlowBlock[];
|
|
82
|
+
export declare function remapNoteMarkerText(blocks: FlowBlock[], maps: NoteDisplayNumberMaps): FlowBlock[];
|
|
83
83
|
/**
|
|
84
84
|
* After layout, determine which footnotes appear on which pages.
|
|
85
85
|
* Checks each page's fragments to see if any footnoteRef PM positions fall within.
|
|
86
86
|
*
|
|
87
87
|
* Returns Map<pageNumber, footnoteId[]> in document order.
|
|
88
88
|
*/
|
|
89
|
-
declare function mapFootnotesToPages(pages: Page[], footnoteRefs: {
|
|
89
|
+
export declare function mapFootnotesToPages(pages: Page[], footnoteRefs: {
|
|
90
90
|
footnoteId: number;
|
|
91
91
|
pmPos: number;
|
|
92
92
|
}[]): Map<number, number[]>;
|
|
@@ -94,31 +94,31 @@ declare function mapFootnotesToPages(pages: Page[], footnoteRefs: {
|
|
|
94
94
|
* Convert a Footnote's content paragraphs to FlowBlocks suitable for rendering.
|
|
95
95
|
* Prepends the display number to the first run of the first paragraph.
|
|
96
96
|
*/
|
|
97
|
-
declare function convertFootnoteToContent(footnote: document_d_exports.Footnote | document_d_exports.Endnote, displayNumber: number, contentWidth: number, options?: ConvertFootnoteOptions): FootnoteContent;
|
|
97
|
+
export declare function convertFootnoteToContent(footnote: document_d_exports.Footnote | document_d_exports.Endnote, displayNumber: number, contentWidth: number, options?: ConvertFootnoteOptions): FootnoteContent;
|
|
98
98
|
/**
|
|
99
99
|
* A note story's content as flow blocks, through the same projection and
|
|
100
100
|
* conversion a note's text takes. `referenceMarkText` is what the story's own
|
|
101
101
|
* `w:footnoteRef`/`w:endnoteRef` mark shows; a story without one (a separator
|
|
102
102
|
* story) is converted as authored.
|
|
103
103
|
*/
|
|
104
|
-
declare function convertNoteStoryToFlowBlocks(content: document_d_exports.Footnote["content"], options: ConvertFootnoteOptions, referenceMarkText?: string): {
|
|
104
|
+
export declare function convertNoteStoryToFlowBlocks(content: document_d_exports.Footnote["content"], options: ConvertFootnoteOptions, referenceMarkText?: string): {
|
|
105
105
|
flowBlocks: FlowBlock[];
|
|
106
106
|
hasReferenceMark: boolean;
|
|
107
107
|
};
|
|
108
|
-
declare function applyFootnotePresentation(blocks: FlowBlock[], displayNumber: number | string): FlowBlock[];
|
|
108
|
+
export declare function applyFootnotePresentation(blocks: FlowBlock[], displayNumber: number | string): FlowBlock[];
|
|
109
109
|
/**
|
|
110
110
|
* Build footnote content for all footnotes referenced in the document.
|
|
111
111
|
* Returns a Map<footnoteId, FootnoteContent>.
|
|
112
112
|
*/
|
|
113
|
-
declare function buildFootnoteContentMap(footnotes: document_d_exports.Footnote[], footnoteRefs: {
|
|
113
|
+
export declare function buildFootnoteContentMap(footnotes: document_d_exports.Footnote[], footnoteRefs: {
|
|
114
114
|
footnoteId: number;
|
|
115
115
|
}[], contentWidth: number, options?: ConvertFootnoteOptions): Map<number, FootnoteContent>;
|
|
116
116
|
/**
|
|
117
117
|
* Calculate per-page footnote reserved heights.
|
|
118
118
|
* Returns Map<pageNumber, reservedHeight>.
|
|
119
119
|
*/
|
|
120
|
-
declare function calculateFootnoteReservedHeights(pageFootnoteMap: Map<number, number[]>, footnoteContentMap: Map<number, {
|
|
120
|
+
export declare function calculateFootnoteReservedHeights(pageFootnoteMap: Map<number, number[]>, footnoteContentMap: Map<number, {
|
|
121
121
|
height: number;
|
|
122
122
|
}>): Map<number, number>;
|
|
123
123
|
//#endregion
|
|
124
|
-
export {
|
|
124
|
+
export { FOOTNOTE_ENTRY_MARGIN_BOTTOM, FOOTNOTE_FALLBACK_LINE_HEIGHT, FOOTNOTE_SEPARATOR_HEIGHT };
|
|
@@ -7,6 +7,13 @@ import { remapMarkupViewBlocks } from "./markupViewFlow.js";
|
|
|
7
7
|
import { collectNoteRefs } from "./noteReferences.js";
|
|
8
8
|
import { toFlowBlocks } from "./toFlowBlocks.js";
|
|
9
9
|
//#region src/layout-bridge/convert/footnoteLayout.ts
|
|
10
|
+
/**
|
|
11
|
+
* Footnote Layout Utilities
|
|
12
|
+
*
|
|
13
|
+
* Handles scanning for footnote references, mapping them to pages,
|
|
14
|
+
* converting footnote content to measurable FlowBlocks, and computing
|
|
15
|
+
* per-page footnote area heights for layout space reservation.
|
|
16
|
+
*/
|
|
10
17
|
/** Default footnote font size in points */
|
|
11
18
|
const FOOTNOTE_FONT_SIZE = 8;
|
|
12
19
|
/**
|
|
@@ -211,6 +218,7 @@ function convertNoteStoryToFlowBlocks(content, options, referenceMarkText) {
|
|
|
211
218
|
if (options.styles) flowOptions.styles = options.styles;
|
|
212
219
|
if (options.theme !== void 0) flowOptions.theme = options.theme;
|
|
213
220
|
if (options.embeddedFontFamilyMap !== void 0) flowOptions.embeddedFontFamilyMap = options.embeddedFontFamilyMap;
|
|
221
|
+
if (options.documentFontFacts !== void 0) flowOptions.documentFontFacts = options.documentFontFacts;
|
|
214
222
|
if (options.fontAlternates !== void 0) flowOptions.fontAlternates = options.fontAlternates;
|
|
215
223
|
if (options.defaultTabStopTwips !== void 0) flowOptions.defaultTabStopTwips = options.defaultTabStopTwips;
|
|
216
224
|
if (options.lineBreakRules) flowOptions.lineBreakRules = options.lineBreakRules;
|
|
@@ -405,6 +413,8 @@ function createFootnoteNumberRun(displayNumber, paragraph) {
|
|
|
405
413
|
};
|
|
406
414
|
const embeddedFontFamilyMap = firstFormattedRun?.embeddedFontFamilyMap ?? paragraph.attrs?.embeddedFontFamilyMap;
|
|
407
415
|
if (embeddedFontFamilyMap) numberRun.embeddedFontFamilyMap = embeddedFontFamilyMap;
|
|
416
|
+
const documentFontFacts = firstFormattedRun?.documentFontFacts ?? paragraph.attrs?.documentFontFacts;
|
|
417
|
+
if (documentFontFacts !== void 0) numberRun.documentFontFacts = documentFontFacts;
|
|
408
418
|
const fontFamily = firstFormattedRun?.fontFamily ?? paragraph.attrs?.defaultFontFamily;
|
|
409
419
|
if (fontFamily) numberRun.fontFamily = fontFamily;
|
|
410
420
|
const alternateFontFamily = firstFormattedRun?.fontFamily !== void 0 ? firstFormattedRun.alternateFontFamily : paragraph.attrs?.defaultAlternateFontFamily;
|