@docx-editor.dev/core 2.15.0 → 2.16.0
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 +9 -15
- package/dist/automation.cjs +1 -1
- package/dist/automation.d.ts +11 -9
- package/dist/automation.js +1 -1
- package/dist/binding.cjs +1 -1
- package/dist/binding.d.ts +12 -16
- package/dist/binding.js +1 -1
- package/dist/{chunk-Q4AB7E4O.cjs → chunk-4MIFIUEV.cjs} +1 -1
- package/dist/chunk-66DTF4TD.cjs +2 -0
- package/dist/chunk-67U2OZS7.cjs +2 -0
- package/dist/chunk-6EGMDUL7.js +21 -0
- package/dist/chunk-ABXCIZVW.js +2 -0
- package/dist/chunk-AEIAYDCG.js +1 -0
- package/dist/{chunk-YL4Q5LZP.cjs → chunk-BPSGGVP5.cjs} +1 -1
- package/dist/chunk-CMV2MTDE.js +5 -0
- package/dist/chunk-DYPT6YDY.js +1 -0
- package/dist/chunk-EWV5JMJY.cjs +21 -0
- package/dist/chunk-FAD7DH6Q.cjs +1 -0
- package/dist/chunk-GHNTGVKG.cjs +11 -0
- package/dist/chunk-GQVKCK33.js +2 -0
- package/dist/chunk-I4ENGOOZ.js +1 -0
- package/dist/chunk-IZHDCQUC.js +20 -0
- package/dist/chunk-KEXMDQ2Z.js +1 -0
- package/dist/chunk-KQEUFAAG.cjs +20 -0
- package/dist/chunk-QVJO5FUR.js +11 -0
- package/dist/chunk-SIUUTE5M.js +2 -0
- package/dist/chunk-TDHR2QLH.cjs +1 -0
- package/dist/{chunk-PXKZUTHX.cjs → chunk-WGHVIB6B.cjs} +2 -2
- package/dist/chunk-XKQTITOJ.cjs +5 -0
- package/dist/{chunk-KXPVOPR5.js → chunk-YKDRBDI2.js} +1 -1
- package/dist/chunk-YRTRPSSA.cjs +1 -0
- package/dist/collaboration/replication.cjs +1 -1
- package/dist/collaboration/replication.d.ts +4 -4
- package/dist/collaboration/replication.js +1 -1
- package/dist/collaboration.d.ts +4 -4
- package/dist/contracts/editor.d.ts +9 -7
- package/dist/contracts/interaction.d.ts +73 -10
- package/dist/contracts/modules.d.ts +8 -8
- package/dist/{custom-node-writes-C9ArIlJh.d.ts → custom-node-writes-4WOL8JB_.d.ts} +2 -2
- package/dist/{editor-sRxrFJd8.d.ts → editor-PDx0fqSo.d.ts} +26 -125
- package/dist/editor-scope-DZJT4ukT.d.ts +53 -0
- package/dist/editor.cjs +1 -1
- package/dist/editor.css +1 -1
- package/dist/editor.d.ts +32 -26
- package/dist/editor.js +1 -1
- package/dist/export.cjs +2 -2
- package/dist/export.d.ts +24 -12
- package/dist/export.js +2 -2
- package/dist/{font-resolver-BYEHQGTw.d.ts → font-resolver-CdqOugwZ.d.ts} +2 -2
- package/dist/{headless-document-view-DELC4E5v.d.ts → headless-document-view-C9ONlGtf.d.ts} +2 -2
- package/dist/{hf-references-DTrHkktY.d.ts → hf-references-BZVHctVD.d.ts} +1 -1
- package/dist/{index-C3Gvq4jN.d.ts → index-BVb4a6O3.d.ts} +74 -28
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +20 -18
- package/dist/index.js +1 -1
- package/dist/{layout-shaping-DoGR5cf8.d.ts → layout-shaping-D_U5z-Qh.d.ts} +1 -1
- package/dist/layout.cjs +1 -1
- package/dist/layout.d.ts +270 -459
- package/dist/layout.js +1 -1
- package/dist/{note-properties-DSe8igrz.d.ts → note-properties-BosjbkGC.d.ts} +1 -1
- package/dist/{omml-equation-BpRmfDAf.d.ts → omml-equation-oLlbPpVy.d.ts} +1 -1
- package/dist/output.cjs +1 -1
- package/dist/output.d.ts +6 -6
- package/dist/output.js +1 -1
- package/dist/{protocol-DZzKxH5r.d.ts → protocol-CUsqt13U.d.ts} +28 -6
- package/dist/{review-items-DYRx187i.d.ts → review-items-kC-YI70C.d.ts} +1 -1
- package/dist/{review-reads-LbGUdNzn.d.ts → review-reads-DdvADsmp.d.ts} +8 -7
- package/dist/{revision-projection-DHRJH48u.d.ts → revision-projection-CN_DiOl_.d.ts} +1 -1
- package/dist/{semantic-cell-selection-BXVWCBYm.d.ts → semantic-cell-selection-BMrXDniV.d.ts} +4 -4
- package/dist/{semantic-interaction-DZsDmPg5.d.ts → semantic-interaction-NGeYzYCN.d.ts} +1 -1
- package/dist/{semantic-paint-f7SqN4oW.d.ts → semantic-paint-CM8F-8pH.d.ts} +2 -2
- package/dist/{semantic-records-EIdwId-a.d.ts → semantic-records-BreR44Ki.d.ts} +1231 -947
- package/dist/store.cjs +1 -1
- package/dist/store.d.ts +80 -20
- package/dist/store.js +1 -1
- package/dist/{tree-op-types-egdarvH_.d.ts → tree-op-types-C5rZzoAz.d.ts} +131 -53
- package/dist/{tree-package-fragment-DjkH4ESI.d.ts → tree-package-fragment-DDQHk8sv.d.ts} +3 -3
- package/dist/{tree-session-contract-CGOOgPjW.d.ts → tree-session-contract-dKgbKH9A.d.ts} +18 -8
- package/dist/{tree-store-DKJB0IcA.d.ts → tree-store-DU192chS.d.ts} +1 -1
- package/package.json +2 -2
- package/dist/chunk-24APKZAN.cjs +0 -11
- package/dist/chunk-2YH4MSHX.cjs +0 -2
- package/dist/chunk-5Y7AADI6.js +0 -1
- package/dist/chunk-AREFLNUP.js +0 -11
- package/dist/chunk-AS7YZNQE.cjs +0 -2
- package/dist/chunk-AVGCKH6A.cjs +0 -20
- package/dist/chunk-CDYVDQRI.cjs +0 -5
- package/dist/chunk-HOEWFH5U.cjs +0 -1
- package/dist/chunk-KFELX7CN.js +0 -2
- package/dist/chunk-LGFKIF4M.cjs +0 -1
- package/dist/chunk-M52QXFKI.js +0 -1
- package/dist/chunk-MNUKSXRO.js +0 -1
- package/dist/chunk-PBOIGBDO.js +0 -2
- package/dist/chunk-PMHGONET.cjs +0 -1
- package/dist/chunk-QJYH6AYD.js +0 -1
- package/dist/chunk-QRC37MWG.cjs +0 -20
- package/dist/chunk-RJSB6RJ7.js +0 -20
- package/dist/chunk-SB54HLFJ.js +0 -20
- package/dist/chunk-XCESLTJL.js +0 -2
- package/dist/chunk-Z4527AXR.js +0 -5
package/dist/layout.d.ts
CHANGED
|
@@ -1,53 +1,23 @@
|
|
|
1
|
-
import { l as NumberingLevel, m as NumberingIndex, n as LayoutBox, D as DrawingPoint,
|
|
2
|
-
export {
|
|
3
|
-
export { C as CacheLookup, b as CacheMiss, c as CacheProvenance, e as LayoutEnvironmentShapedMeasurerOptions, f as LayoutFontConfiguration, g as LayoutFontSource, h as LayoutFontSubstitution, i as LayoutShapingConfigurationError, j as LayoutShapingEnvironment, L as LayoutShapingInstrumentation, a as LayoutShapingOptions, O as OperationSnapshot, k as OperationSnapshotField, l as OperationSnapshotGuard, P as PreparedLayoutFontConfiguration, R as ResolvedCache, m as ResourceDependencyProvenance, S as ShapedMeasurerOptions, n as captureOperationSnapshot, o as createLayoutShapedMeasurer, p as createLayoutShaping, q as createShapedMeasurer, d as disposeLayoutShaping, r as guardOperationSnapshot, s as layoutFontConfigurationFingerprint, t as prepareLayoutFontConfiguration } from './layout-shaping-
|
|
4
|
-
import { a as OoxmlNode, q as OoxmlProperty,
|
|
5
|
-
export { W as DrawingAccessibility, z as DrawingHorizontalReferenceFrame, X as DrawingTransform, A as DrawingVerticalReferenceFrame, u as ImageWrapTarget, S as SourceCrop, U as TableBorderStyle,
|
|
6
|
-
import { H as HeadlessDocumentView, D as DocumentProperties, r as relationshipTargetIn } from './headless-document-view-
|
|
7
|
-
import { b as RevisionAttribution, R as RevisionDisplayMode, a as RevisionAuthorFilter } from './revision-projection-
|
|
8
|
-
export { D as DEFAULT_REVISION_DISPLAY_MODE, c as RevisionFilter, d as RevisionKind, f as formatRevisionOf, m as markRevisionRemovesMark, p as paragraphMarkFormatRevisionOf, e as paragraphMarkRevisionOf, g as paragraphMarkRevisionsOf, r as revisionAuthorFilter, h as revisionsAreDeletion, i as revisionsVisible, s as shownMarkRevision } from './revision-projection-
|
|
9
|
-
import { b as ResolvedFootnoteProperties, R as ResolvedEndnoteProperties } from './note-properties-
|
|
10
|
-
import {
|
|
11
|
-
import { a as SectionColumns } from './semantic-cell-selection-
|
|
12
|
-
export { C as CellSelection, D as DEFAULT_SECTION_PROPERTIES, b as DEFAULT_VERTICAL_WEIGHT, c as DocumentSection, d as DocumentSectionsEnumeration, e as DrawingOverlayFrame, H as HitPoint, f as HitTestOptions, M as MAX_DOCUMENT_SECTIONS, P as PlacedCell, g as SectionBreakType, h as SectionColumnDefinition, i as SectionMargins, j as SectionPageNumbering, S as SectionProperties, k as SemanticHit, l as SemanticHitDrawing, T as TableCellAddress, m as TableCellContext, n as caretBoxOnLine, o as cellSelectionBetween, p as cellSelectionRects, q as cellSelectionText, r as contentControlAtPoint, s as enumerateDocumentSections, t as enumerateDocumentSectionsBounded, u as findDrawingOverlayFrameInLayout, v as geometryOfSection, w as hitTestPage, x as hitTestSheet, y as isFurniturePoint, z as lineEndOffset, A as pageAtY, B as paragraphSectionNode, E as paragraphsInCells, F as parsePageNumbering, G as parseSectionProperties, I as projectedSectionSourceIndexes, J as readSectionProperties, K as spanOffsetX, L as spansInCells, N as tableContextAt } from './semantic-cell-selection-
|
|
13
|
-
export { M as MAX_SDT_NESTING, c as collectFlowBlocks, b as commentBodyText, d as commentInitials, m as contentControlContentChildren, i as isContentControl, h as isContentControlContent, p as paragraphOrderOfPart } from './review-reads-
|
|
14
|
-
import { a as ReviewItem } from './review-items-
|
|
15
|
-
export { i as CommentAnchor, j as CommentPosition, C as CommentRecord, h as CommentThreadState, c as ReviewCommentItem, d as ReviewCustomItem, R as ReviewModelInput, e as ReviewPosition, f as ReviewRange, b as ReviewRevisionItem, g as ReviewRevisionKind, W as W15_NAMESPACE_URI, p as activeReviewItem, m as firstReviewRange, r as reviewItemKey, q as reviewItemPositionRank, o as reviewItemRanges, s as reviewItemsAt, u as reviewThreadRootOf } from './review-items-
|
|
16
|
-
import { S as SemanticPosition, b as SelectionRect, a as SemanticSelection } from './semantic-interaction-
|
|
17
|
-
export { c as CaretAtOptions, C as CaretGeometry, M as MoveCaretOptions, N as NavigationCommand, d as caretAt, e as caretStops, f as caretStopsForBlocks, g as compositionAnchor, h as contentControlAtSemantic, i as contentControlsInLayout, j as deletedTextBoundaries, k as hitTestSemantic, m as moveCaret, p as paragraphTextFromLayout, s as spansInSelection } from './semantic-interaction-
|
|
18
|
-
import './omml-equation-
|
|
1
|
+
import { l as NumberingLevel, m as NumberingIndex, S as SemanticLayout, n as ParagraphFragmentRecord, o as LayoutBox, D as DrawingPoint, p as DrawingInsets, a as StyleSpanRecord, I as InlineDrawingRecord, M as ModelRange, q as TableBorderSide, B as BlockFragmentRecord, A as AnchoredDrawingRecord, r as PageRecord, s as SemanticTableStructure, L as LineRecord, t as NoteAreaRecord, H as HeaderFooterStoryRecord, u as NoteStoryRecord, C as ContentControlBoundaryRecord$1, v as ContentControlLock, T as TextMeasurer, V as VersionedShapingLibrary, e as TextShaper, w as FontByteValidator, g as FixedPointRoundingMode, x as FixedPoint, k as ShapedRun, y as SourceRange, z as StyleCascadeTable, E as HyperlinkProjector, G as InlineDrawingLayoutContext, J as FieldLinkProjector, K as StoryPageFieldNeeds, O as RefFieldContext, Q as HyperlinkFieldSpec, U as SpanLinkRecord, P as PageGeometry, W as ResolvedListItem } from './semantic-records-BreR44Ki.js';
|
|
2
|
+
export { X as AUTO_PARAGRAPH_SPACING_PT, Y as AUTO_PREFERRED_WIDTH, Z as AbstractNumDefinition, _ as AnchoredDrawingLayoutFallback, $ as BidiEmbeddingLevels, a0 as BorderGridGeometry, a1 as CELL_PAD, a2 as CascadedParagraphFormatting, a3 as CellBorderBox, a4 as CellMarginsPt, a5 as CellVerticalAlign, a6 as CjkTypographySettings, a7 as ContentControlGeometryFragment, a8 as ContentControlLevel, a9 as ContentControlMappedType, aa as DEFAULT_CELL_MARGINS, ab as DEFAULT_PAGE_GEOMETRY, ac as DEFAULT_RUN_STYLE, ad as DEFAULT_TAB_INTERVAL_PT, ae as DEFAULT_TAB_INTERVAL_TWIPS, af as DeclaredFontSubstitution, ag as DrawingClipFallback, ah as DrawingGeometry, ai as EMPTY_NUMBERING_INDEX, aj as EMPTY_TAB_STOPS, ak as EquationFractionGeometry, al as EquationGeometry, am as EquationNaryGeometry, an as EquationRadicalGeometry, ao as EquationRowGeometry, ap as EquationScriptGeometry, aq as EquationSpanRecord, ar as EquationTextGeometry, as as FieldAtomMarker, at as FontFingerprintInputs, h as FontRequest, au as FontResolutionError, av as FontResolutionErrorCode, aw as FontResourceDefinition, ax as FontResourceInstrumentation, F as FontResourceSnapshot, ay as FontResourceSnapshotOptions, az as FontSlot, j as FontSubstitution, aA as FontValidationResult, aB as GlyphOutline, aC as HARD_MAX_AGGREGATE_FONT_BYTES, aD as HARD_MAX_FONT_BYTES, aE as HARD_MAX_FONT_SOURCES, aF as LevelOverride, aG as LineSpacingRule, aH as ListMarkerAlign, aI as ListMarkerRecord, aJ as ListSuffix, aK as MAX_BORDER_SPACE_PT, aL as MAX_BORDER_WIDTH_PT, aM as MAX_LVL_OVERRIDES, aN as MAX_NUMBERING_DEFINITIONS, aO as MAX_PARAGRAPH_SPACING_PT, aP as MAX_STYLE_BASED_ON_DEPTH, aQ as MAX_STYLE_DEFINITIONS, aR as MAX_TABLE_BORDER_STROKES, aS as MAX_TABLE_NESTING, aT as MAX_TABLE_ROW_HEIGHT_PT, aU as MAX_TAB_POSITION_TWIPS, aV as MAX_TAB_STOPS, N as NormalizationPolicy, aW as NumDefinition, aX as NumberingLevelIndent, aY as PARAGRAPH_BORDER_SIDES, aZ as PageRefCalibrationCell, a_ as PageRefFieldProjection, a$ as ParagraphAutoSpacingContext, b0 as ParagraphBorderEdge, b1 as ParagraphBorderSide, b2 as ParagraphBorderStrokeRecord, b3 as ParagraphBorders, b4 as ParagraphBottomBorderRecord, b5 as ParagraphIndent, b6 as ParagraphLayoutInputs, b7 as ParagraphLineSpacing, b8 as ParagraphSpacing, b9 as PreferredWidth, ba as PreferredWidthType, bb as RefFieldSpec, bc as RefNoteParts, bd as ResolvedCellBorders, f as ResolvedFont, R as ResolvedRunStyle, be as ResolvedTabStops, bf as ResolvedTableBorderEdge, bg as ResolvedTableBorderEdgeSegment, bh as ResolvedUnderline, bi as SINGLE_LINE_SPACING, bj as ScriptItem, bk as SemanticArtifactRootStoryKind, bl as SemanticArtifactStoryKind, bm as SemanticCommentArtifactRecord, bn as SemanticReviewArtifactOccurrence, bo as SemanticReviewArtifactOccurrenceGeometry, bp as SemanticReviewArtifactPosition, i as SemanticReviewArtifactRecord, bq as SemanticReviewArtifactSource, br as SemanticTableCell, bs as SemanticTableRow, bt as SemanticTrackedChangeArtifactRecord, bu as ShapeInput, bv as ShapedCluster, bw as ShapedFontSpan, bx as ShapedGlyph, by as ShapedRunComparatorInputs, bz as ShapedVerticalMetrics, bA as ShapingEnvironment, bB as ShapingEnvironmentFingerprintInputs, d as ShapingEnvironmentInput, bC as StyleDefinition, bD as TAB_LEADER_GLYPH, bE as TabAlignment, bF as TabDestination, bG as TabLeader, bH as TabStop, bI as TableAlignment, bJ as TableBorderBox, bK as TableBorderSideName, bL as TableBorderStrokeRecord, c as TableCellFragmentRecord, bM as TableCellStyleFormatting, bN as TableFragmentRecord, b as TableRowFragmentRecord, bO as TableRowHeight, bP as TableRowHeightRule, bQ as TextDirection, bR as TextboxStoryFallbackReason, bS as TextboxStoryLayout, bT as UnsupportedScriptError, bU as VerticalAlign, bV as appliedSpaceBefore, bW as applyLineSpacing, bX as baselineShiftPtOf, bY as borderExtentPt, bZ as borderWeight, b_ as bottomBorderExtentPt, b$ as boundedStructuralFontValidator, c0 as buildNumberingIndex, c1 as buildStyleCascadeTable, c2 as cascadeParagraphFormatting, c3 as cascadeRunProperties, c4 as cascadedBottomBorder, c5 as cascadedParagraphBorders, c6 as cascadedTabStops, c7 as collapsedSpaceBefore, c8 as createFontResourceSnapshot, c9 as createShapedRun, ca as createShapingEnvironment, cb as defaultTabIntervalFromSettings, cc as displayText, cd as fixedPoint, ce as fontRequestKey, cf as isValidStyleId, cg as itemizeScriptFontSlots, ch as layoutEquation, ci as listMarkerBox, cj as measureDisplayText, ck as mergeListIndent, cl as nextTabDestination, cm as paragraphBorderExtentPt, cn as paragraphBorderStrokeWidthPt, co as paragraphBorders, cp as paragraphBordersFingerprint, cq as paragraphBreaksBefore, cr as paragraphContextualSpacing, cs as paragraphLineSpacing, ct as paragraphSpacing, cu as paragraphTabStops, cv as parseRefInstruction, cw as readBorderSide, cx as readCellBorders, cy as readNumPr, cz as readTableBorders, cA as readTableStructure, cB as resolveBorderConflict, cC as resolveNumberingLevel, cD as resolveParagraphLayoutInputs, cE as resolveRunStyle, cF as resolveStoryListItems, cG as resolveStoryRefFields, cH as resolveTableCellBorderGrid, cI as runStylesEqual, cJ as shapedRunComparatorInputs, cK as shapingEnvironmentFingerprint, cL as shapingEnvironmentFingerprintInputs, cM as styleForFontSlot, cN as tabAdvanceWidth, cO as tabStopsFingerprint, cP as walkStoryParagraphs, cQ as withDefaultTabInterval, cR as withNumberingStyleLinks, cS as withResolvedListItems } from './semantic-records-BreR44Ki.js';
|
|
3
|
+
export { C as CacheLookup, b as CacheMiss, c as CacheProvenance, e as LayoutEnvironmentShapedMeasurerOptions, f as LayoutFontConfiguration, g as LayoutFontSource, h as LayoutFontSubstitution, i as LayoutShapingConfigurationError, j as LayoutShapingEnvironment, L as LayoutShapingInstrumentation, a as LayoutShapingOptions, O as OperationSnapshot, k as OperationSnapshotField, l as OperationSnapshotGuard, P as PreparedLayoutFontConfiguration, R as ResolvedCache, m as ResourceDependencyProvenance, S as ShapedMeasurerOptions, n as captureOperationSnapshot, o as createLayoutShapedMeasurer, p as createLayoutShaping, q as createShapedMeasurer, d as disposeLayoutShaping, r as guardOperationSnapshot, s as layoutFontConfigurationFingerprint, t as prepareLayoutFontConfiguration } from './layout-shaping-D_U5z-Qh.js';
|
|
4
|
+
import { I as ImpactClass, a as OoxmlNode, q as OoxmlProperty, O as OoxmlPart, c as OoxmlElement, T as TreeDocOp, b as OoxmlPackage, ak as ContentControlKind, al as ContentControlLevel, an as ContentControlLock$1, ah as ContentControlDataBinding } from './tree-op-types-C5rZzoAz.js';
|
|
5
|
+
export { W as DrawingAccessibility, z as DrawingHorizontalReferenceFrame, X as DrawingImageEffects, Y as DrawingTransform, A as DrawingVerticalReferenceFrame, u as ImageWrapTarget, S as SourceCrop, U as TableBorderStyle, cM as VectorShapeComponent, Z as VectorShapeProjection } from './tree-op-types-C5rZzoAz.js';
|
|
6
|
+
import { H as HeadlessDocumentView, D as DocumentProperties, r as relationshipTargetIn } from './headless-document-view-C9ONlGtf.js';
|
|
7
|
+
import { b as RevisionAttribution, R as RevisionDisplayMode, a as RevisionAuthorFilter } from './revision-projection-CN_DiOl_.js';
|
|
8
|
+
export { D as DEFAULT_REVISION_DISPLAY_MODE, c as RevisionFilter, d as RevisionKind, f as formatRevisionOf, m as markRevisionRemovesMark, p as paragraphMarkFormatRevisionOf, e as paragraphMarkRevisionOf, g as paragraphMarkRevisionsOf, r as revisionAuthorFilter, h as revisionsAreDeletion, i as revisionsVisible, s as shownMarkRevision } from './revision-projection-CN_DiOl_.js';
|
|
9
|
+
import { b as ResolvedFootnoteProperties, R as ResolvedEndnoteProperties } from './note-properties-BosjbkGC.js';
|
|
10
|
+
import { T as TreeModelChange, N as NoteKind, H as noteTypeOf } from './tree-store-DU192chS.js';
|
|
11
|
+
import { a as SectionColumns } from './semantic-cell-selection-BMrXDniV.js';
|
|
12
|
+
export { C as CellSelection, D as DEFAULT_SECTION_PROPERTIES, b as DEFAULT_VERTICAL_WEIGHT, c as DocumentSection, d as DocumentSectionsEnumeration, e as DrawingOverlayFrame, H as HitPoint, f as HitTestOptions, M as MAX_DOCUMENT_SECTIONS, P as PlacedCell, g as SectionBreakType, h as SectionColumnDefinition, i as SectionMargins, j as SectionPageNumbering, S as SectionProperties, k as SemanticHit, l as SemanticHitDrawing, T as TableCellAddress, m as TableCellContext, n as caretBoxOnLine, o as cellSelectionBetween, p as cellSelectionRects, q as cellSelectionText, r as contentControlAtPoint, s as enumerateDocumentSections, t as enumerateDocumentSectionsBounded, u as findDrawingOverlayFrameInLayout, v as geometryOfSection, w as hitTestPage, x as hitTestSheet, y as isFurniturePoint, z as lineEndOffset, A as pageAtY, B as paragraphSectionNode, E as paragraphsInCells, F as parsePageNumbering, G as parseSectionProperties, I as projectedSectionSourceIndexes, J as readSectionProperties, K as spanOffsetX, L as spansInCells, N as tableContextAt } from './semantic-cell-selection-BMrXDniV.js';
|
|
13
|
+
export { M as MAX_SDT_NESTING, c as collectFlowBlocks, b as commentBodyText, d as commentInitials, m as contentControlContentChildren, i as isContentControl, h as isContentControlContent, p as paragraphOrderOfPart } from './review-reads-DdvADsmp.js';
|
|
14
|
+
import { a as ReviewItem } from './review-items-kC-YI70C.js';
|
|
15
|
+
export { i as CommentAnchor, j as CommentPosition, C as CommentRecord, h as CommentThreadState, c as ReviewCommentItem, d as ReviewCustomItem, R as ReviewModelInput, e as ReviewPosition, f as ReviewRange, b as ReviewRevisionItem, g as ReviewRevisionKind, W as W15_NAMESPACE_URI, p as activeReviewItem, m as firstReviewRange, r as reviewItemKey, q as reviewItemPositionRank, o as reviewItemRanges, s as reviewItemsAt, u as reviewThreadRootOf } from './review-items-kC-YI70C.js';
|
|
16
|
+
import { S as SemanticPosition, b as SelectionRect, a as SemanticSelection } from './semantic-interaction-NGeYzYCN.js';
|
|
17
|
+
export { c as CaretAtOptions, C as CaretGeometry, M as MoveCaretOptions, N as NavigationCommand, d as caretAt, e as caretStops, f as caretStopsForBlocks, g as compositionAnchor, h as contentControlAtSemantic, i as contentControlsInLayout, j as deletedTextBoundaries, k as hitTestSemantic, m as moveCaret, p as paragraphTextFromLayout, s as spansInSelection } from './semantic-interaction-NGeYzYCN.js';
|
|
18
|
+
import './omml-equation-oLlbPpVy.js';
|
|
19
19
|
import './contracts/types.js';
|
|
20
|
-
import './hf-references-
|
|
21
|
-
|
|
22
|
-
/** Synchronous platform-neutral SHA-256 used before font bytes cross into a shaping implementation. */
|
|
23
|
-
declare const sha256FontBytes: (bytes: Uint8Array) => string;
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Page-field evaluation context for furniture projection.
|
|
27
|
-
*
|
|
28
|
-
* `pageNumber` is the displayed PAGE value after section `w:pgNumType/@w:start` (1-based).
|
|
29
|
-
* `pageCount` is document NUMPAGES. `sectionPageCount` is SECTIONPAGES for the attached
|
|
30
|
-
* section. `format` is the authored `w:pgNumType/@w:fmt` applied only to PAGE.
|
|
31
|
-
*
|
|
32
|
-
* A new field here must also join `sameFieldPageContext` below, or finalize compares two
|
|
33
|
-
* contexts that differ in it as equal and keeps a reused story's stale text.
|
|
34
|
-
*/
|
|
35
|
-
interface FieldPageContext {
|
|
36
|
-
readonly pageNumber: number;
|
|
37
|
-
readonly pageCount: number;
|
|
38
|
-
/** SECTIONPAGES; defaults to `pageCount` when omitted (single-section callers). */
|
|
39
|
-
readonly sectionPageCount?: number;
|
|
40
|
-
/** Authored ST_NumberFormat for PAGE; absent → decimal. */
|
|
41
|
-
readonly format?: string;
|
|
42
|
-
}
|
|
43
|
-
/**
|
|
44
|
-
* Format a displayed PAGE value through the shared ST_NumberFormat resolver.
|
|
45
|
-
*
|
|
46
|
-
* Unknown / script-specific formats fall back to decimal (same convention as list markers).
|
|
47
|
-
* `none` / `bullet` are meaningless for page numbers and also fall back to decimal so a
|
|
48
|
-
* hostile fmt cannot blank the furniture.
|
|
49
|
-
*/
|
|
50
|
-
declare function formatPageNumber(value: number, format: string | undefined): string;
|
|
20
|
+
import './hf-references-BZVHctVD.js';
|
|
51
21
|
|
|
52
22
|
/**
|
|
53
23
|
* The result of counting ONE list paragraph: the level that applied, the counter vector after it,
|
|
@@ -88,6 +58,187 @@ interface ListCounterState {
|
|
|
88
58
|
*/
|
|
89
59
|
declare function createListCounterState(index: NumberingIndex): ListCounterState;
|
|
90
60
|
|
|
61
|
+
/**
|
|
62
|
+
* What a batch of commits can affect.
|
|
63
|
+
*
|
|
64
|
+
* `paragraphIds` is the set the commits touched directly. What that set MEANS depends on
|
|
65
|
+
* `impact`: for a local impact it bounds the work, for a structural one it only says where
|
|
66
|
+
* the reflow starts.
|
|
67
|
+
*/
|
|
68
|
+
interface LayoutScope {
|
|
69
|
+
readonly impact: ImpactClass;
|
|
70
|
+
/** Node ids touched directly by the coalesced commits. */
|
|
71
|
+
readonly paragraphIds: ReadonlySet<string>;
|
|
72
|
+
/** Ids the commits created — no previous layout exists for these. */
|
|
73
|
+
readonly created: ReadonlySet<string>;
|
|
74
|
+
/** Ids the commits removed — any retained layout for these must be released. */
|
|
75
|
+
readonly deleted: ReadonlySet<string>;
|
|
76
|
+
/** Cache keys the commits invalidated (styles, numbering, fonts). */
|
|
77
|
+
readonly dependencyKeys: ReadonlySet<string>;
|
|
78
|
+
/** True when the block SEQUENCE changed, so ids alone cannot bound the reflow. */
|
|
79
|
+
readonly structural: boolean;
|
|
80
|
+
/** The revision this scope describes — the layout result must carry the same one. */
|
|
81
|
+
readonly revision: number;
|
|
82
|
+
}
|
|
83
|
+
/** How the scheduler produces layouts and when it publishes them. */
|
|
84
|
+
interface LayoutSchedulerOptions {
|
|
85
|
+
/**
|
|
86
|
+
* Produce a complete layout for the CURRENT model state.
|
|
87
|
+
*
|
|
88
|
+
* Given the accumulated scope so an incremental implementation can use it. It must tag
|
|
89
|
+
* the result with the revision it actually read, which is what makes staleness detectable
|
|
90
|
+
* rather than assumed.
|
|
91
|
+
*/
|
|
92
|
+
readonly run: (scope: LayoutScope) => SemanticLayout;
|
|
93
|
+
/** The model's revision right now. Read at publish time, never cached. */
|
|
94
|
+
readonly currentRevision: () => number;
|
|
95
|
+
/** Called with a layout that is known current. Never called with a stale one. */
|
|
96
|
+
readonly publish: (layout: SemanticLayout, scope: LayoutScope) => void;
|
|
97
|
+
/**
|
|
98
|
+
* Defer work to a later turn, returning a canceller.
|
|
99
|
+
*
|
|
100
|
+
* Injected rather than assumed: the browser wants an animation frame, tests want to step
|
|
101
|
+
* the queue by hand, and a server has neither.
|
|
102
|
+
*/
|
|
103
|
+
readonly schedule?: (run: () => void) => () => void;
|
|
104
|
+
/**
|
|
105
|
+
* Run a layout in slices instead of in one call (task 9.5).
|
|
106
|
+
*
|
|
107
|
+
* Optional: without it `run` is used and completes in one turn, which is right for a
|
|
108
|
+
* document small enough that slicing costs more than it saves.
|
|
109
|
+
*/
|
|
110
|
+
readonly runCooperatively?: (scope: LayoutScope) => CooperativeRun;
|
|
111
|
+
}
|
|
112
|
+
interface CooperativeRun {
|
|
113
|
+
/**
|
|
114
|
+
* Advance the work. Returns the finished layout, or null to be called again.
|
|
115
|
+
*
|
|
116
|
+
* Split so a global relayout does not hold the main thread for the whole document: the
|
|
117
|
+
* scheduler yields between slices and a newer revision can cancel the run mid-flight
|
|
118
|
+
* rather than the user waiting for work whose result is already stale.
|
|
119
|
+
*/
|
|
120
|
+
step(): SemanticLayout | null;
|
|
121
|
+
/** Abandon the run. Nothing partial is ever published. */
|
|
122
|
+
cancel(): void;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Coalesces commits into layout passes.
|
|
126
|
+
*
|
|
127
|
+
* A keystroke is one commit but must not be one full layout pass, so changes accumulate into a
|
|
128
|
+
* scope and are laid out together. Every published layout is tagged with the revision it actually
|
|
129
|
+
* read, which is what makes a stale result detectable rather than merely late.
|
|
130
|
+
*/
|
|
131
|
+
interface LayoutScheduler {
|
|
132
|
+
/** Record a commit. Coalesces with anything already pending. */
|
|
133
|
+
notify(change: TreeModelChange): void;
|
|
134
|
+
/** Request a relayout for a reason the store did not report (page size, zoom, fonts). */
|
|
135
|
+
invalidateAll(revision: number, reason?: string): void;
|
|
136
|
+
/** Run any pending work now, synchronously. Returns whether a layout was published. */
|
|
137
|
+
flush(): boolean;
|
|
138
|
+
/** The scope that would be used if `flush` ran now, or null when nothing is pending. */
|
|
139
|
+
pending(): LayoutScope | null;
|
|
140
|
+
/** Drop pending work without publishing — for teardown. */
|
|
141
|
+
cancel(): void;
|
|
142
|
+
/** How many layouts were discarded for being stale. Diagnostics, and a test hook. */
|
|
143
|
+
readonly staleDiscards: number;
|
|
144
|
+
/** How many cooperative runs were abandoned because a newer revision arrived. */
|
|
145
|
+
readonly cancelledRuns: number;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* Build the scheduler that turns a stream of commits into coalesced layout passes.
|
|
149
|
+
*
|
|
150
|
+
* Keystrokes arrive faster than a document can be laid out, so changes accumulate into one scope
|
|
151
|
+
* and are laid out together rather than once per commit.
|
|
152
|
+
*/
|
|
153
|
+
declare function createLayoutScheduler(options: LayoutSchedulerOptions): LayoutScheduler;
|
|
154
|
+
|
|
155
|
+
interface PositionedTableAnchorSignal {
|
|
156
|
+
readonly anchorId: string;
|
|
157
|
+
readonly column: number;
|
|
158
|
+
readonly fragmentIndex: number;
|
|
159
|
+
readonly anchorY: number;
|
|
160
|
+
}
|
|
161
|
+
interface PendingPositionedTableTokens {
|
|
162
|
+
readonly token: string;
|
|
163
|
+
readonly previous: PendingPositionedTableTokens | undefined;
|
|
164
|
+
readonly length: number;
|
|
165
|
+
readonly signature: string;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/** Numeric, auto-height text frames. Other frame variants retain ordinary flow. */
|
|
169
|
+
interface ParagraphFrame {
|
|
170
|
+
readonly x: number;
|
|
171
|
+
readonly y: number;
|
|
172
|
+
readonly width: number;
|
|
173
|
+
readonly horizontalAnchor: 'page' | 'margin' | 'text';
|
|
174
|
+
readonly verticalAnchor: 'page' | 'margin' | 'text';
|
|
175
|
+
/** Equal authored frame properties group adjacent paragraphs into one frame. */
|
|
176
|
+
readonly token: string;
|
|
177
|
+
readonly wrap: 'around' | 'none' | 'notBeside';
|
|
178
|
+
readonly hSpace: number;
|
|
179
|
+
readonly vSpace: number;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
interface PendingParagraphFrame {
|
|
183
|
+
readonly frame: ParagraphFrame;
|
|
184
|
+
readonly fragment: ParagraphFragmentRecord;
|
|
185
|
+
readonly groupId: string;
|
|
186
|
+
readonly sourceOrder: number;
|
|
187
|
+
}
|
|
188
|
+
/** Immutable prefix shared by every checkpoint; one node per pending paragraph. */
|
|
189
|
+
interface PendingParagraphFrames {
|
|
190
|
+
readonly item: PendingParagraphFrame;
|
|
191
|
+
readonly previous: PendingParagraphFrames | undefined;
|
|
192
|
+
readonly length: number;
|
|
193
|
+
readonly signature: string;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
/** Synchronous platform-neutral SHA-256 used before font bytes cross into a shaping implementation. */
|
|
197
|
+
declare const sha256FontBytes: (bytes: Uint8Array) => string;
|
|
198
|
+
|
|
199
|
+
type AutonumFieldKind = 'AUTONUM' | 'AUTONUMLGL' | 'AUTONUMOUT';
|
|
200
|
+
/** One recognized AUTONUM-family instruction: the kind and its supported switches. */
|
|
201
|
+
interface AutonumFieldSpec {
|
|
202
|
+
readonly kind: AutonumFieldKind;
|
|
203
|
+
/** ST_NumberFormat resolved from the `\*` switch; null paints decimal. */
|
|
204
|
+
readonly numFmt: string | null;
|
|
205
|
+
/** `\e`: display the number without its trailing period. */
|
|
206
|
+
readonly suppressPeriod: boolean;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Recognize `AUTONUM | AUTONUMLGL | AUTONUMOUT [\* <format>] [\e] [\* MERGEFORMAT]`, or null
|
|
210
|
+
* for anything else. Any unrecognized switch fails the parse so the field stays inert (paints
|
|
211
|
+
* nothing — its historical rendering), never the raw instruction, never a guessed number.
|
|
212
|
+
*/
|
|
213
|
+
declare function parseAutonumInstruction(raw: string): AutonumFieldSpec | null;
|
|
214
|
+
|
|
215
|
+
/**
|
|
216
|
+
* Page-field evaluation context for furniture projection.
|
|
217
|
+
*
|
|
218
|
+
* `pageNumber` is the displayed PAGE value after section `w:pgNumType/@w:start` (1-based).
|
|
219
|
+
* `pageCount` is document NUMPAGES. `sectionPageCount` is SECTIONPAGES for the attached
|
|
220
|
+
* section. `format` is the authored `w:pgNumType/@w:fmt` applied only to PAGE.
|
|
221
|
+
*
|
|
222
|
+
* A new field here must also join `sameFieldPageContext` below, or finalize compares two
|
|
223
|
+
* contexts that differ in it as equal and keeps a reused story's stale text.
|
|
224
|
+
*/
|
|
225
|
+
interface FieldPageContext {
|
|
226
|
+
readonly pageNumber: number;
|
|
227
|
+
readonly pageCount: number;
|
|
228
|
+
/** SECTIONPAGES; defaults to `pageCount` when omitted (single-section callers). */
|
|
229
|
+
readonly sectionPageCount?: number;
|
|
230
|
+
/** Authored ST_NumberFormat for PAGE; absent → decimal. */
|
|
231
|
+
readonly format?: string;
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
* Format a displayed PAGE value through the shared ST_NumberFormat resolver.
|
|
235
|
+
*
|
|
236
|
+
* Unknown / script-specific formats fall back to decimal (same convention as list markers).
|
|
237
|
+
* `none` / `bullet` are meaningless for page numbers and also fall back to decimal so a
|
|
238
|
+
* hostile fmt cannot blank the furniture.
|
|
239
|
+
*/
|
|
240
|
+
declare function formatPageNumber(value: number, format: string | undefined): string;
|
|
241
|
+
|
|
91
242
|
/**
|
|
92
243
|
* Lookup of derived display marks keyed by {@link formatNoteScopeId}.
|
|
93
244
|
*
|
|
@@ -273,6 +424,8 @@ interface WrapExclusionInput {
|
|
|
273
424
|
/** Paint layer relative to body text — not the OOXML wrap element. */
|
|
274
425
|
type DrawingPaintLayer = 'behind' | 'inFront';
|
|
275
426
|
interface ExclusionZone {
|
|
427
|
+
/** Non-drawing objects publish their anchor exclusion directly instead of synthesizing it. */
|
|
428
|
+
readonly sourceKind?: 'table' | 'frame';
|
|
276
429
|
readonly drawingNodeId: string;
|
|
277
430
|
readonly anchorParagraphId: string;
|
|
278
431
|
/** UTF-16 model offset of the anchor atom — exclusions apply at/after this point in the paragraph. */
|
|
@@ -318,106 +471,12 @@ interface PendingLine {
|
|
|
318
471
|
columnBreakAfter?: boolean;
|
|
319
472
|
/** Model ranges on this line covering deleted content; see {@link LineRecord.deletedRanges}. */
|
|
320
473
|
deletedRanges?: readonly ModelRange[];
|
|
321
|
-
/** Vertical gap inserted before this line to clear a
|
|
474
|
+
/** Vertical gap inserted before this line to clear a drawing exclusion band. */
|
|
322
475
|
exclusionSkipBefore?: number;
|
|
323
476
|
/** Tracked anchored-drawing attributions on this line; see {@link LineRecord.anchorRevisions}. */
|
|
324
477
|
anchorRevisions?: readonly RevisionAttribution[];
|
|
325
478
|
}
|
|
326
479
|
|
|
327
|
-
/**
|
|
328
|
-
* What a batch of commits can affect.
|
|
329
|
-
*
|
|
330
|
-
* `paragraphIds` is the set the commits touched directly. What that set MEANS depends on
|
|
331
|
-
* `impact`: for a local impact it bounds the work, for a structural one it only says where
|
|
332
|
-
* the reflow starts.
|
|
333
|
-
*/
|
|
334
|
-
interface LayoutScope {
|
|
335
|
-
readonly impact: ImpactClass;
|
|
336
|
-
/** Node ids touched directly by the coalesced commits. */
|
|
337
|
-
readonly paragraphIds: ReadonlySet<string>;
|
|
338
|
-
/** Ids the commits created — no previous layout exists for these. */
|
|
339
|
-
readonly created: ReadonlySet<string>;
|
|
340
|
-
/** Ids the commits removed — any retained layout for these must be released. */
|
|
341
|
-
readonly deleted: ReadonlySet<string>;
|
|
342
|
-
/** Cache keys the commits invalidated (styles, numbering, fonts). */
|
|
343
|
-
readonly dependencyKeys: ReadonlySet<string>;
|
|
344
|
-
/** True when the block SEQUENCE changed, so ids alone cannot bound the reflow. */
|
|
345
|
-
readonly structural: boolean;
|
|
346
|
-
/** The revision this scope describes — the layout result must carry the same one. */
|
|
347
|
-
readonly revision: number;
|
|
348
|
-
}
|
|
349
|
-
/** How the scheduler produces layouts and when it publishes them. */
|
|
350
|
-
interface LayoutSchedulerOptions {
|
|
351
|
-
/**
|
|
352
|
-
* Produce a complete layout for the CURRENT model state.
|
|
353
|
-
*
|
|
354
|
-
* Given the accumulated scope so an incremental implementation can use it. It must tag
|
|
355
|
-
* the result with the revision it actually read, which is what makes staleness detectable
|
|
356
|
-
* rather than assumed.
|
|
357
|
-
*/
|
|
358
|
-
readonly run: (scope: LayoutScope) => SemanticLayout;
|
|
359
|
-
/** The model's revision right now. Read at publish time, never cached. */
|
|
360
|
-
readonly currentRevision: () => number;
|
|
361
|
-
/** Called with a layout that is known current. Never called with a stale one. */
|
|
362
|
-
readonly publish: (layout: SemanticLayout, scope: LayoutScope) => void;
|
|
363
|
-
/**
|
|
364
|
-
* Defer work to a later turn, returning a canceller.
|
|
365
|
-
*
|
|
366
|
-
* Injected rather than assumed: the browser wants an animation frame, tests want to step
|
|
367
|
-
* the queue by hand, and a server has neither.
|
|
368
|
-
*/
|
|
369
|
-
readonly schedule?: (run: () => void) => () => void;
|
|
370
|
-
/**
|
|
371
|
-
* Run a layout in slices instead of in one call (task 9.5).
|
|
372
|
-
*
|
|
373
|
-
* Optional: without it `run` is used and completes in one turn, which is right for a
|
|
374
|
-
* document small enough that slicing costs more than it saves.
|
|
375
|
-
*/
|
|
376
|
-
readonly runCooperatively?: (scope: LayoutScope) => CooperativeRun;
|
|
377
|
-
}
|
|
378
|
-
interface CooperativeRun {
|
|
379
|
-
/**
|
|
380
|
-
* Advance the work. Returns the finished layout, or null to be called again.
|
|
381
|
-
*
|
|
382
|
-
* Split so a global relayout does not hold the main thread for the whole document: the
|
|
383
|
-
* scheduler yields between slices and a newer revision can cancel the run mid-flight
|
|
384
|
-
* rather than the user waiting for work whose result is already stale.
|
|
385
|
-
*/
|
|
386
|
-
step(): SemanticLayout | null;
|
|
387
|
-
/** Abandon the run. Nothing partial is ever published. */
|
|
388
|
-
cancel(): void;
|
|
389
|
-
}
|
|
390
|
-
/**
|
|
391
|
-
* Coalesces commits into layout passes.
|
|
392
|
-
*
|
|
393
|
-
* A keystroke is one commit but must not be one full layout pass, so changes accumulate into a
|
|
394
|
-
* scope and are laid out together. Every published layout is tagged with the revision it actually
|
|
395
|
-
* read, which is what makes a stale result detectable rather than merely late.
|
|
396
|
-
*/
|
|
397
|
-
interface LayoutScheduler {
|
|
398
|
-
/** Record a commit. Coalesces with anything already pending. */
|
|
399
|
-
notify(change: TreeModelChange): void;
|
|
400
|
-
/** Request a relayout for a reason the store did not report (page size, zoom, fonts). */
|
|
401
|
-
invalidateAll(revision: number, reason?: string): void;
|
|
402
|
-
/** Run any pending work now, synchronously. Returns whether a layout was published. */
|
|
403
|
-
flush(): boolean;
|
|
404
|
-
/** The scope that would be used if `flush` ran now, or null when nothing is pending. */
|
|
405
|
-
pending(): LayoutScope | null;
|
|
406
|
-
/** Drop pending work without publishing — for teardown. */
|
|
407
|
-
cancel(): void;
|
|
408
|
-
/** How many layouts were discarded for being stale. Diagnostics, and a test hook. */
|
|
409
|
-
readonly staleDiscards: number;
|
|
410
|
-
/** How many cooperative runs were abandoned because a newer revision arrived. */
|
|
411
|
-
readonly cancelledRuns: number;
|
|
412
|
-
}
|
|
413
|
-
/**
|
|
414
|
-
* Build the scheduler that turns a stream of commits into coalesced layout passes.
|
|
415
|
-
*
|
|
416
|
-
* Keystrokes arrive faster than a document can be laid out, so changes accumulate into one scope
|
|
417
|
-
* and are laid out together rather than once per commit.
|
|
418
|
-
*/
|
|
419
|
-
declare function createLayoutScheduler(options: LayoutSchedulerOptions): LayoutScheduler;
|
|
420
|
-
|
|
421
480
|
/**
|
|
422
481
|
* What one cell side is before any ADJACENT cell has its say.
|
|
423
482
|
*
|
|
@@ -456,259 +515,22 @@ interface CompoundBorderMetrics {
|
|
|
456
515
|
*/
|
|
457
516
|
declare function computeDoubleBorderMetricsPt(widthPt: number): CompoundBorderMetrics;
|
|
458
517
|
|
|
459
|
-
/**
|
|
460
|
-
declare const
|
|
461
|
-
|
|
462
|
-
/**
|
|
463
|
-
* `w:tblW` / `w:tcW` / `w:wBefore` (CT_TblWidth, 17.4.63 / 17.4.71 / 17.4.86): a PREFERRED
|
|
464
|
-
* width plus the unit it is stated in. Preferred is the operative word — it is what the
|
|
465
|
-
* producer asked for, not what the table resolved to.
|
|
466
|
-
*
|
|
467
|
-
* `pct` is stated in fiftieths of a percent (5000 = 100%) by Word, and in the `"50%"`
|
|
468
|
-
* string form of `ST_Percentage` by others; both are read. `auto` and `nil` carry no width.
|
|
469
|
-
*/
|
|
470
|
-
type PreferredWidthType = 'dxa' | 'pct' | 'auto' | 'nil';
|
|
471
|
-
/**
|
|
472
|
-
* `w:tblW` / `w:tcW` — a requested width, whose UNIT depends on its type.
|
|
473
|
-
*
|
|
474
|
-
* Points for `dxa`, percent for `pct`, and zero for `auto`/`nil`. Reading `value` without `type`
|
|
475
|
-
* is always wrong.
|
|
476
|
-
*/
|
|
477
|
-
interface PreferredWidth {
|
|
478
|
-
readonly type: PreferredWidthType;
|
|
479
|
-
/** POINTS for `dxa`, PERCENT (0–100) for `pct`, 0 for `auto`/`nil`. */
|
|
480
|
-
readonly value: number;
|
|
481
|
-
}
|
|
482
|
-
/** The frozen "no preferred width" value — what a table or cell that declares none resolves to. */
|
|
483
|
-
declare const AUTO_PREFERRED_WIDTH: PreferredWidth;
|
|
484
|
-
|
|
485
|
-
/**
|
|
486
|
-
* The uniform 3 pt (60 twip) inset this lane used to apply on every side.
|
|
487
|
-
*
|
|
488
|
-
* Word's defaults are not uniform — see {@link DEFAULT_CELL_MARGINS} — so nothing resolves
|
|
489
|
-
* against this any more. Kept because it is published.
|
|
490
|
-
*/
|
|
491
|
-
declare const CELL_PAD = 3;
|
|
492
|
-
/** Resolved cell padding in points, after the table default and any per-cell override. */
|
|
493
|
-
interface CellMarginsPt {
|
|
494
|
-
readonly top: number;
|
|
495
|
-
readonly right: number;
|
|
496
|
-
readonly bottom: number;
|
|
497
|
-
readonly left: number;
|
|
498
|
-
}
|
|
499
|
-
/**
|
|
500
|
-
* Word's own default cell padding, for a document whose styles part states none.
|
|
501
|
-
*
|
|
502
|
-
* 0 top, 0 bottom, 108 twips left and right — the values `TableNormal` carries. A uniform
|
|
503
|
-
* 3 pt on all four sides made every row of every table that authored no `w:tblCellMar` 6 pt
|
|
504
|
-
* taller than Word's, and that error compounds down a table until it paginates a page early.
|
|
505
|
-
* A document that DOES ship a default table style resolves against that instead; this is the
|
|
506
|
-
* floor beneath it.
|
|
507
|
-
*/
|
|
508
|
-
declare const DEFAULT_CELL_MARGINS: CellMarginsPt;
|
|
509
|
-
|
|
510
|
-
/** `w:vAlign` — where a cell's content sits when the row is taller than the content. */
|
|
511
|
-
type CellVerticalAlign = 'top' | 'center' | 'bottom';
|
|
512
|
-
|
|
513
|
-
/**
|
|
514
|
-
* Layout-time nesting ceiling. Parse-time depth (MAX_DEPTH = 256 XML levels) alone still
|
|
515
|
-
* admits ~80 levels of `w:tbl` recursion into the layout walk; deeper tables render as an
|
|
516
|
-
* empty cell box rather than recursing.
|
|
517
|
-
*/
|
|
518
|
-
declare const MAX_TABLE_NESTING = 16;
|
|
519
|
-
/**
|
|
520
|
-
* Soft ceiling on an authored `w:trHeight` (~22"). Hostile `w:val` otherwise becomes a
|
|
521
|
-
* multi-page row that every pagination preflight and cell box inherits.
|
|
522
|
-
*/
|
|
523
|
-
declare const MAX_TABLE_ROW_HEIGHT_PT: number;
|
|
524
|
-
/**
|
|
525
|
-
* `w:trPr/w:trHeight` (17.4.81) resolved for layout. Points leave the reader already —
|
|
526
|
-
* twips convert once here, matching every other table geometry boundary.
|
|
527
|
-
*
|
|
528
|
-
* Word quirk (matches Form025U and Word's UI export): a present `@w:val` with an omitted
|
|
529
|
-
* `@w:hRule` is treated as `atLeast`, not ECMA's `auto`. Explicit `auto` still ignores val.
|
|
530
|
-
*/
|
|
531
|
-
type TableRowHeightRule = 'auto' | 'atLeast' | 'exact';
|
|
532
|
-
/**
|
|
533
|
-
* `w:trHeight` — a row's height rule and its value.
|
|
534
|
-
*
|
|
535
|
-
* `auto` carries no value at all, which is why this is a union rather than a rule plus an
|
|
536
|
-
* optional number.
|
|
537
|
-
*/
|
|
538
|
-
type TableRowHeight = {
|
|
539
|
-
readonly rule: 'auto';
|
|
540
|
-
} | {
|
|
541
|
-
readonly rule: 'atLeast' | 'exact';
|
|
542
|
-
readonly valuePt: number;
|
|
543
|
-
};
|
|
544
|
-
/** `w:tblPr/w:jc` (17.4.29, ST_JcTable): where the table sits within the text column. */
|
|
545
|
-
type TableAlignment = 'left' | 'center' | 'right';
|
|
546
|
-
/**
|
|
547
|
-
* `w:tblpPr/@w:horzAnchor` (17.4.58) and `@w:vertAnchor` (17.4.66): the box a floated
|
|
548
|
-
* table's offsets are measured from. Absent means `text` for both.
|
|
549
|
-
*/
|
|
550
|
-
type TableFloatAnchor = 'text' | 'margin' | 'page';
|
|
551
|
-
/** `w:tblpPr/@w:tblpXSpec` (17.4.63, ST_XAlign). */
|
|
552
|
-
type TableFloatXSpec = 'left' | 'center' | 'right' | 'inside' | 'outside';
|
|
553
|
-
/** `w:tblpPr/@w:tblpYSpec` (17.4.65, ST_YAlign). */
|
|
554
|
-
type TableFloatYSpec = 'inline' | 'top' | 'center' | 'bottom' | 'inside' | 'outside';
|
|
555
|
-
/**
|
|
556
|
-
* `w:tblPr/w:tblpPr` (17.4.57) — a table positioned against an anchor box rather than at
|
|
557
|
-
* the point in the text where it was authored.
|
|
558
|
-
*
|
|
559
|
-
* A spec (`tblpXSpec`/`tblpYSpec`) supersedes the matching offset when both are present:
|
|
560
|
-
* 17.4.57 states the alignment outright, and the offset only answers "how far from the
|
|
561
|
-
* anchor" for the case where no alignment was stated.
|
|
562
|
-
*/
|
|
563
|
-
interface TableFloatPosition {
|
|
564
|
-
readonly horzAnchor: TableFloatAnchor;
|
|
565
|
-
readonly vertAnchor: TableFloatAnchor;
|
|
566
|
-
readonly xSpec?: TableFloatXSpec;
|
|
567
|
-
/** `w:tblpX` in points; signed, so a table can be pulled into the margin. */
|
|
568
|
-
readonly xPt: number;
|
|
569
|
-
readonly ySpec?: TableFloatYSpec;
|
|
570
|
-
/** `w:tblpY` in points; signed. */
|
|
571
|
-
readonly yPt: number;
|
|
572
|
-
}
|
|
573
|
-
/**
|
|
574
|
-
* One cell in the resolved table structure.
|
|
575
|
-
*
|
|
576
|
-
* `gridSpan` is clamped at READ time and layout never re-derives it — the value comes from a file
|
|
577
|
-
* and would otherwise be a loop bound an attacker controls.
|
|
578
|
-
*/
|
|
579
|
-
interface SemanticTableCell {
|
|
580
|
-
readonly id: string;
|
|
581
|
-
/** Clamped to [1, MAX_TABLE_COLUMNS] at read time; layout never re-derives it. */
|
|
582
|
-
readonly gridSpan: number;
|
|
583
|
-
/**
|
|
584
|
-
* Absolute grid column this cell starts on, after `w:gridBefore` and every preceding
|
|
585
|
-
* span. Structural conditional formats and cell geometry both key on this, never on the
|
|
586
|
-
* cell's position in the row: one `gridSpan` cell otherwise shifts firstCol/lastCol and
|
|
587
|
-
* the vertical bands for every cell after it.
|
|
588
|
-
*/
|
|
589
|
-
readonly gridColumn: number;
|
|
590
|
-
/** Canonical `w:gridCol` node id for this cell's start column, when the grid is authored. */
|
|
591
|
-
readonly gridColumnId?: string;
|
|
592
|
-
/** A vMerge cell that is not the restart continues the cell above: box, no content. */
|
|
593
|
-
readonly vMergeContinue: boolean;
|
|
594
|
-
/** `w:vAlign` — defaults to top when omitted/unrecognised. */
|
|
595
|
-
readonly vAlign: CellVerticalAlign;
|
|
596
|
-
/** `w:textDirection`; unsupported values keep horizontal layout. */
|
|
597
|
-
readonly textDirection: 'horizontal' | 'btLr';
|
|
598
|
-
/** Resolved per-side margins (tcMar over tblCellMar over the table style over Word's default). */
|
|
599
|
-
readonly margins: CellMarginsPt;
|
|
600
|
-
/** Three-state authored `tcBorders` (omitted / none / edge). */
|
|
601
|
-
readonly borders: CellBorderBox;
|
|
602
|
-
/** Validated 6-hex shading fill, absent for none/auto. */
|
|
603
|
-
readonly shading?: string;
|
|
604
|
-
/**
|
|
605
|
-
* `w:tcW` — the width this cell asked for, as authored.
|
|
606
|
-
*
|
|
607
|
-
* Published for consumers that need the cell's own statement (a column-resize handle has
|
|
608
|
-
* to write back to it). Column geometry is NOT derived from this field: the resolver works
|
|
609
|
-
* from a flat claim list built in the same pass, because resolving a column means looking
|
|
610
|
-
* at every cell that covers it across every row, not at one cell at a time. Read
|
|
611
|
-
* `columnWidthsPt` for what the table actually laid out.
|
|
612
|
-
*/
|
|
613
|
-
readonly preferredWidth: PreferredWidth;
|
|
614
|
-
/**
|
|
615
|
-
* What the table style says about this cell's paragraphs and runs (17.7.6.6) — a header
|
|
616
|
-
* row's bold and centring live here, not in the cell's own properties.
|
|
617
|
-
*/
|
|
618
|
-
readonly styleFormatting: TableCellStyleFormatting;
|
|
619
|
-
/** Block children in reading order, with content-control wrappers flattened. */
|
|
620
|
-
readonly blocks: readonly OoxmlElement[];
|
|
621
|
-
}
|
|
622
|
-
/** One row in the resolved structure: its cells, its height rule, and any row-level revision. */
|
|
623
|
-
interface SemanticTableRow {
|
|
624
|
-
readonly id: string;
|
|
625
|
-
/** Pending Word row insertion/deletion authored in `w:trPr`. */
|
|
626
|
-
readonly revisionKind?: 'insert' | 'delete';
|
|
627
|
-
/**
|
|
628
|
-
* The `w:trPr/w:ins|w:del` attribution, carried with the kind so a painted row can say
|
|
629
|
-
* WHOSE pending decision it is — the review model addresses the decision by exactly this
|
|
630
|
-
* `(id, author, date)` triple, and a surface with only the kind could highlight the row
|
|
631
|
-
* but never open its card.
|
|
632
|
-
*/
|
|
633
|
-
readonly revisionId?: string;
|
|
634
|
-
readonly revisionAuthor?: string;
|
|
635
|
-
readonly revisionDate?: string;
|
|
636
|
-
/** `w:trPr/w:tblHeader` — the row repeats atop each page the table continues onto. */
|
|
637
|
-
readonly isHeader: boolean;
|
|
638
|
-
/**
|
|
639
|
-
* `w:trPr/w:cantSplit` — the row must stay on one page. When it cannot fit a fresh page,
|
|
640
|
-
* layout fails closed rather than fragmenting or overflowing the content box.
|
|
641
|
-
*/
|
|
642
|
-
readonly cantSplit: boolean;
|
|
643
|
-
/** `w:trPr/w:trHeight` — auto / atLeast floor / exact (clipped) row height. */
|
|
644
|
-
readonly height: TableRowHeight;
|
|
645
|
-
readonly cells: readonly SemanticTableCell[];
|
|
646
|
-
}
|
|
647
|
-
/**
|
|
648
|
-
* A table resolved into a rectangular grid: column widths, rows, and the widths it asked for.
|
|
649
|
-
*
|
|
650
|
-
* The grid is normalized here so layout never has to reconcile `w:gridCol` against actual cell
|
|
651
|
-
* spans — vertical merges and column spans are already accounted for.
|
|
652
|
-
*/
|
|
653
|
-
interface SemanticTableStructure {
|
|
654
|
-
readonly columnWidthsPt: readonly number[];
|
|
655
|
-
readonly rows: readonly SemanticTableRow[];
|
|
656
|
-
/** `w:tblPr/w:tblW` — the width the table asked for. */
|
|
657
|
-
readonly tableWidth: PreferredWidth;
|
|
658
|
-
/**
|
|
659
|
-
* `w:tblInd` (17.4.50) in points — "this indentation should shift the table into the text
|
|
660
|
-
* margin by the specified amount". Applies to a left-aligned table; `w:jc` decides the
|
|
661
|
-
* placement outright for the other two.
|
|
662
|
-
*/
|
|
663
|
-
readonly indentPt: number;
|
|
664
|
-
/** `w:tblPr/w:jc` (17.4.29) — where the table sits in the text column. */
|
|
665
|
-
readonly alignment: TableAlignment;
|
|
666
|
-
/**
|
|
667
|
-
* `w:tblPr/w:tblpPr` (17.4.57) — present when the table is positioned against an anchor
|
|
668
|
-
* box. Placement then comes from {@link tableFloatOriginX} rather than `w:jc`/`w:tblInd`.
|
|
669
|
-
*/
|
|
670
|
-
readonly float?: TableFloatPosition;
|
|
671
|
-
/**
|
|
672
|
-
* `w:tblCellSpacing` (17.4.45) in points: the gap between adjacent cell edges. Applied as
|
|
673
|
-
* a half-gap inset on each side of every cell, so cells separate visually without the grid
|
|
674
|
-
* itself moving. Word ALSO grows the table's overall width by the spacing it adds around
|
|
675
|
-
* the outside; that part is not modelled, so a spaced table is laid out on the same grid
|
|
676
|
-
* its file states rather than a wider one.
|
|
677
|
-
*/
|
|
678
|
-
readonly cellSpacingPt: number;
|
|
679
|
-
/**
|
|
680
|
-
* `w:tblPr/w:tblLayout/@w:type="fixed"` (17.4.52 — 17.4.53 is the `w:tblPrEx` exception
|
|
681
|
-
* variant, not this element). Fixed layout takes the grid as final;
|
|
682
|
-
* anything else is autofit, which in Word never renders wider than the text column.
|
|
683
|
-
*/
|
|
684
|
-
readonly layoutFixed: boolean;
|
|
685
|
-
/** Table-level `tblBorders` (three-state, including insideH/insideV). */
|
|
686
|
-
readonly tableBorders: TableBorderBox;
|
|
687
|
-
/** Table-level `tblCellMar` defaults (per-side, Word's own default when a side is omitted). */
|
|
688
|
-
readonly defaultMargins: CellMarginsPt;
|
|
689
|
-
}
|
|
518
|
+
/** Soft ceiling on fragments emitted for one authored row (hostile / runaway splits). */
|
|
519
|
+
declare const MAX_TABLE_ROW_FRAGMENTS = 4096;
|
|
690
520
|
/**
|
|
691
|
-
*
|
|
521
|
+
* Why a table could not be paginated as authored.
|
|
692
522
|
*
|
|
693
|
-
*
|
|
694
|
-
*
|
|
695
|
-
* also apply to them — Word centres a centred table in the text column whatever indent the
|
|
696
|
-
* file carries. A table wider than its container starts flush so its leading edge stays on
|
|
697
|
-
* the page rather than being centred off it.
|
|
523
|
+
* Each is a bound: a row taller than a page, a row that cannot be split, or a row producing more
|
|
524
|
+
* fragments than the limit allows.
|
|
698
525
|
*/
|
|
699
|
-
|
|
526
|
+
type TablePaginationErrorCode = 'table-row-overheight' | 'table-row-split-unsupported' | 'table-row-fragment-limit';
|
|
700
527
|
/**
|
|
701
|
-
*
|
|
702
|
-
*
|
|
528
|
+
* Bounded table pagination failure. Prefer this over emitting a fragment that overflows
|
|
529
|
+
* the page content box.
|
|
703
530
|
*/
|
|
704
|
-
declare
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
interface PositionedTableAnchorSignal {
|
|
709
|
-
readonly anchorId: string;
|
|
710
|
-
readonly column: number;
|
|
711
|
-
readonly fragmentIndex: number;
|
|
531
|
+
declare class TablePaginationError extends Error {
|
|
532
|
+
readonly code: TablePaginationErrorCode;
|
|
533
|
+
constructor(code: TablePaginationErrorCode, message: string);
|
|
712
534
|
}
|
|
713
535
|
|
|
714
536
|
/** The flow state as it stood immediately before one block was placed. */
|
|
@@ -719,6 +541,8 @@ interface FlowCheckpoint {
|
|
|
719
541
|
readonly pageFragments: readonly BlockFragmentRecord[];
|
|
720
542
|
/** Anchored drawings already collected for the open page. */
|
|
721
543
|
readonly pendingAnchoredDrawings: readonly AnchoredDrawingRecord[];
|
|
544
|
+
/** Local frame paragraphs waiting for their next regular paragraph anchor. */
|
|
545
|
+
readonly pendingParagraphFrames?: PendingParagraphFrames;
|
|
722
546
|
/**
|
|
723
547
|
* Anchored drawings overlap resolution pushed onto the NEXT page, and how many times each
|
|
724
548
|
* drawing has been pushed.
|
|
@@ -731,7 +555,7 @@ interface FlowCheckpoint {
|
|
|
731
555
|
readonly deferredAnchoredDrawings: readonly AnchoredDrawingRecord[];
|
|
732
556
|
readonly anchorPageDeferCounts: ReadonlyMap<string, number>;
|
|
733
557
|
/** Sheet-positioned tables and zero-line anchors still owed by the open page. */
|
|
734
|
-
readonly pendingPositionedTableTokens?:
|
|
558
|
+
readonly pendingPositionedTableTokens?: PendingPositionedTableTokens;
|
|
735
559
|
readonly positionedTableAnchorSignals?: readonly PositionedTableAnchorSignal[];
|
|
736
560
|
readonly cursorY: number;
|
|
737
561
|
readonly lineCounter: number;
|
|
@@ -889,39 +713,17 @@ interface LayoutSession {
|
|
|
889
713
|
*/
|
|
890
714
|
declare function createLayoutSession(): LayoutSession;
|
|
891
715
|
|
|
892
|
-
/**
|
|
893
|
-
declare const
|
|
894
|
-
/**
|
|
895
|
-
* Why a table could not be paginated as authored.
|
|
896
|
-
*
|
|
897
|
-
* Each is a bound: a row taller than a page, a row that cannot be split, or a row producing more
|
|
898
|
-
* fragments than the limit allows.
|
|
899
|
-
*/
|
|
900
|
-
type TablePaginationErrorCode = 'table-row-overheight' | 'table-row-split-unsupported' | 'table-row-fragment-limit';
|
|
901
|
-
/**
|
|
902
|
-
* Bounded table pagination failure. Prefer this over emitting a fragment that overflows
|
|
903
|
-
* the page content box.
|
|
904
|
-
*/
|
|
905
|
-
declare class TablePaginationError extends Error {
|
|
906
|
-
readonly code: TablePaginationErrorCode;
|
|
907
|
-
constructor(code: TablePaginationErrorCode, message: string);
|
|
908
|
-
}
|
|
716
|
+
/** Far above anything Word authors (its UI caps at 63) while keeping allocation bounded. */
|
|
717
|
+
declare const MAX_TABLE_COLUMNS = 1024;
|
|
909
718
|
|
|
910
|
-
type AutonumFieldKind = 'AUTONUM' | 'AUTONUMLGL' | 'AUTONUMOUT';
|
|
911
|
-
/** One recognized AUTONUM-family instruction: the kind and its supported switches. */
|
|
912
|
-
interface AutonumFieldSpec {
|
|
913
|
-
readonly kind: AutonumFieldKind;
|
|
914
|
-
/** ST_NumberFormat resolved from the `\*` switch; null paints decimal. */
|
|
915
|
-
readonly numFmt: string | null;
|
|
916
|
-
/** `\e`: display the number without its trailing period. */
|
|
917
|
-
readonly suppressPeriod: boolean;
|
|
918
|
-
}
|
|
919
719
|
/**
|
|
920
|
-
*
|
|
921
|
-
*
|
|
922
|
-
*
|
|
720
|
+
* Where a table's left edge sits inside the box that contains it.
|
|
721
|
+
*
|
|
722
|
+
* Ordinary left-aligned tables start at their indent; centered/right-aligned tables
|
|
723
|
+
* use the remaining width. A verified legacy content-aligned table instead aligns
|
|
724
|
+
* the leading cell's content edge with the text column, without changing its indent.
|
|
923
725
|
*/
|
|
924
|
-
declare function
|
|
726
|
+
declare function tableOriginX(structure: SemanticTableStructure, containerWidthPt: number): number;
|
|
925
727
|
|
|
926
728
|
/**
|
|
927
729
|
* Depth-first paragraph fragments of one page, in reading order.
|
|
@@ -1552,6 +1354,7 @@ declare function lineSegments(line: LineRecord): readonly LineSegment[];
|
|
|
1552
1354
|
interface DocumentStyleDependencies {
|
|
1553
1355
|
readonly styleCascade: () => StyleCascadeTable | undefined;
|
|
1554
1356
|
readonly defaultTabStopPt: () => number;
|
|
1357
|
+
readonly compatibilityMode?: () => number | undefined;
|
|
1555
1358
|
readonly numberingIndex: () => NumberingIndex;
|
|
1556
1359
|
}
|
|
1557
1360
|
/** Build the cascade and numbering projections layout consumes. @public */
|
|
@@ -1651,6 +1454,7 @@ interface HeaderFooterStoryLayout {
|
|
|
1651
1454
|
* painted no marker for as long as headers have been editable. Everything new goes here.
|
|
1652
1455
|
*/
|
|
1653
1456
|
interface HeaderFooterStoryInputs {
|
|
1457
|
+
readonly compatibilityMode?: number;
|
|
1654
1458
|
/**
|
|
1655
1459
|
* `numbering.xml`, so a `w:numPr` paragraph in this story resolves a marker — directly or
|
|
1656
1460
|
* inside an anchored text box, which lays out with its own per-box counters.
|
|
@@ -1723,6 +1527,7 @@ interface CreateDocumentFurnitureSourceOptions {
|
|
|
1723
1527
|
readonly styleCascade?: () => StyleCascadeTable | undefined;
|
|
1724
1528
|
readonly numberingIndex?: () => NumberingIndex;
|
|
1725
1529
|
readonly defaultTabStopPt?: () => number;
|
|
1530
|
+
readonly compatibilityMode?: () => number | undefined;
|
|
1726
1531
|
readonly displayMode?: RevisionDisplayMode;
|
|
1727
1532
|
readonly revisionAuthorFilter?: RevisionAuthorFilter;
|
|
1728
1533
|
readonly inlineDrawingLayoutForPart?: (partName: string) => InlineDrawingLayoutContext | undefined;
|
|
@@ -1873,6 +1678,7 @@ interface LayoutNoteStoryOptions {
|
|
|
1873
1678
|
*/
|
|
1874
1679
|
readonly numberingIndex?: NumberingIndex;
|
|
1875
1680
|
readonly defaultTabStopPt?: number;
|
|
1681
|
+
readonly compatibilityMode?: number;
|
|
1876
1682
|
readonly displayMode?: RevisionDisplayMode;
|
|
1877
1683
|
readonly revisionAuthorFilter?: RevisionAuthorFilter;
|
|
1878
1684
|
/**
|
|
@@ -2035,6 +1841,7 @@ interface NotesLayoutInput {
|
|
|
2035
1841
|
/** `numbering.xml`, so a `w:numPr` paragraph inside a note resolves a marker. */
|
|
2036
1842
|
readonly numberingIndex?: NumberingIndex;
|
|
2037
1843
|
readonly defaultTabStopPt?: number;
|
|
1844
|
+
readonly compatibilityMode?: number;
|
|
2038
1845
|
readonly displayMode?: RevisionDisplayMode;
|
|
2039
1846
|
readonly revisionAuthorFilter?: RevisionAuthorFilter;
|
|
2040
1847
|
/**
|
|
@@ -2172,6 +1979,7 @@ interface CreateDocumentNotesInputOptions {
|
|
|
2172
1979
|
readonly styleCascade?: () => StyleCascadeTable | undefined;
|
|
2173
1980
|
readonly numberingIndex?: () => NumberingIndex;
|
|
2174
1981
|
readonly defaultTabStopPt?: number;
|
|
1982
|
+
readonly compatibilityMode?: number;
|
|
2175
1983
|
readonly inlineDrawingLayoutForPart?: (partName: string) => InlineDrawingLayoutContext | undefined;
|
|
2176
1984
|
readonly drawingTokenForParagraphForPart?: (partName: string, paragraph: OoxmlNode) => string;
|
|
2177
1985
|
readonly drawingLayoutEpochForPart?: (partName: string) => string;
|
|
@@ -2245,40 +2053,6 @@ declare function paragraphShadingBox(lines: readonly {
|
|
|
2245
2053
|
readonly box: LayoutBox;
|
|
2246
2054
|
}[], x: number, width: number): LayoutBox | undefined;
|
|
2247
2055
|
|
|
2248
|
-
/**
|
|
2249
|
-
* A deterministic measurer for tests and headless use.
|
|
2250
|
-
*
|
|
2251
|
-
* Monospace by construction: every character is the same width and every line the same
|
|
2252
|
-
* height, scaled by `w:sz` when present. Real shaping is the HarfBuzz path; this exists so
|
|
2253
|
-
* layout behaviour can be asserted without a font stack deciding the answer.
|
|
2254
|
-
*/
|
|
2255
|
-
declare function createFixedMeasurer(charWidth?: number, lineHeight?: number): TextMeasurer;
|
|
2256
|
-
|
|
2257
|
-
/**
|
|
2258
|
-
* Every content control a part declares, in document order, WITHOUT geometry.
|
|
2259
|
-
*
|
|
2260
|
-
* For callers that want the ROSTER rather than the rectangles — the Tab walk through form
|
|
2261
|
-
* fields is the one, and it needs story order, not boxes. `fragments` comes back empty here
|
|
2262
|
-
* by design; a caller that needs geometry reads `layout.contentControls`, which covers every
|
|
2263
|
-
* story the layout draws.
|
|
2264
|
-
*/
|
|
2265
|
-
declare function contentControlRecordsInPart(part: OoxmlPart,
|
|
2266
|
-
/**
|
|
2267
|
-
* Keep only controls holding one of these paragraphs.
|
|
2268
|
-
*
|
|
2269
|
-
* For a notes PART, which holds every note in the document rather than one story. Rostered
|
|
2270
|
-
* whole, Tab walked out of the open footnote and into the next one, and the keystrokes after
|
|
2271
|
-
* it landed in a note the reader was not in.
|
|
2272
|
-
*/
|
|
2273
|
-
withinParagraphs?: ReadonlySet<string>): readonly ContentControlBoundaryRecord$1[];
|
|
2274
|
-
/**
|
|
2275
|
-
* The innermost content control holding `paragraphId`, in `part`.
|
|
2276
|
-
*
|
|
2277
|
-
* Deepest wins, matching the geometry path's innermost-by-nesting rule: a control inside a
|
|
2278
|
-
* control is the one the caret is actually in.
|
|
2279
|
-
*/
|
|
2280
|
-
declare function contentControlHoldingParagraph(part: OoxmlPart, paragraphId: string): ContentControlBoundaryRecord$1 | null;
|
|
2281
|
-
|
|
2282
2056
|
/**
|
|
2283
2057
|
* Everything a layout pass needs beyond the document itself.
|
|
2284
2058
|
*
|
|
@@ -2301,7 +2075,7 @@ interface SemanticLayoutOptions {
|
|
|
2301
2075
|
* Supplied by the multi-section orchestrator, which retains once over the union —
|
|
2302
2076
|
* retaining per section evicted every other section's entries. `false` skips retention
|
|
2303
2077
|
* for this pass entirely (the orchestrator strides sweeps). See
|
|
2304
|
-
*
|
|
2078
|
+
* `retainLiveBreakKeys`.
|
|
2305
2079
|
*/
|
|
2306
2080
|
readonly retainKeys?: Set<string> | false;
|
|
2307
2081
|
/**
|
|
@@ -2383,6 +2157,8 @@ interface SemanticLayoutOptions {
|
|
|
2383
2157
|
* here — which is why the prepared-block memo does not key on it.
|
|
2384
2158
|
*/
|
|
2385
2159
|
readonly defaultTabStopPt?: number;
|
|
2160
|
+
/** Explicit Word compatibility mode; absent retains existing geometry. */
|
|
2161
|
+
readonly compatibilityMode?: number;
|
|
2386
2162
|
/**
|
|
2387
2163
|
* Turns a typed `w:hyperlink` into the SANITIZED record its spans carry.
|
|
2388
2164
|
*
|
|
@@ -2452,6 +2228,41 @@ interface SemanticLayoutOptions {
|
|
|
2452
2228
|
*/
|
|
2453
2229
|
readonly emptyTocSuppressedResultParagraphIds?: ReadonlySet<string>;
|
|
2454
2230
|
}
|
|
2231
|
+
|
|
2232
|
+
/**
|
|
2233
|
+
* A deterministic measurer for tests and headless use.
|
|
2234
|
+
*
|
|
2235
|
+
* Monospace by construction: every character is the same width and every line the same
|
|
2236
|
+
* height, scaled by `w:sz` when present. Real shaping is the HarfBuzz path; this exists so
|
|
2237
|
+
* layout behaviour can be asserted without a font stack deciding the answer.
|
|
2238
|
+
*/
|
|
2239
|
+
declare function createFixedMeasurer(charWidth?: number, lineHeight?: number): TextMeasurer;
|
|
2240
|
+
|
|
2241
|
+
/**
|
|
2242
|
+
* Every content control a part declares, in document order, WITHOUT geometry.
|
|
2243
|
+
*
|
|
2244
|
+
* For callers that want the ROSTER rather than the rectangles — the Tab walk through form
|
|
2245
|
+
* fields is the one, and it needs story order, not boxes. `fragments` comes back empty here
|
|
2246
|
+
* by design; a caller that needs geometry reads `layout.contentControls`, which covers every
|
|
2247
|
+
* story the layout draws.
|
|
2248
|
+
*/
|
|
2249
|
+
declare function contentControlRecordsInPart(part: OoxmlPart,
|
|
2250
|
+
/**
|
|
2251
|
+
* Keep only controls holding one of these paragraphs.
|
|
2252
|
+
*
|
|
2253
|
+
* For a notes PART, which holds every note in the document rather than one story. Rostered
|
|
2254
|
+
* whole, Tab walked out of the open footnote and into the next one, and the keystrokes after
|
|
2255
|
+
* it landed in a note the reader was not in.
|
|
2256
|
+
*/
|
|
2257
|
+
withinParagraphs?: ReadonlySet<string>): readonly ContentControlBoundaryRecord$1[];
|
|
2258
|
+
/**
|
|
2259
|
+
* The innermost content control holding `paragraphId`, in `part`.
|
|
2260
|
+
*
|
|
2261
|
+
* Deepest wins, matching the geometry path's innermost-by-nesting rule: a control inside a
|
|
2262
|
+
* control is the one the caret is actually in.
|
|
2263
|
+
*/
|
|
2264
|
+
declare function contentControlHoldingParagraph(part: OoxmlPart, paragraphId: string): ContentControlBoundaryRecord$1 | null;
|
|
2265
|
+
|
|
2455
2266
|
/**
|
|
2456
2267
|
* Lay one story part out into pages.
|
|
2457
2268
|
*
|
|
@@ -2860,4 +2671,4 @@ declare function paragraphMarkDeleted(paragraph: OoxmlNode): boolean;
|
|
|
2860
2671
|
*/
|
|
2861
2672
|
declare function revisionRemovesParagraph(paragraph: OoxmlNode, displayMode?: RevisionDisplayMode, authorFilter?: RevisionAuthorFilter): boolean;
|
|
2862
2673
|
|
|
2863
|
-
export {
|
|
2674
|
+
export { AnchoredDrawingRecord, type AutonumFieldKind, type AutonumFieldSpec, BlockFragmentRecord, COMPOUND_BORDER_MIN_GAP_PT, COMPOUND_BORDER_MIN_STROKE_PT, type CanvasMeasurerOptions, type CanvasTextContext, type CanvasTextMetrics, type CompoundBorderMetrics, ContentControlBoundaryRecord$1 as ContentControlBoundaryRecord, type ContentControlFragmentRecord, ContentControlLock, type CreateDocumentFurnitureSourceOptions, type CreateDocumentNotesInputOptions, DEFAULT_CANVAS_FONT_STACK, type DocumentFurnitureSource, type DocumentLinkProjectors, type DocumentStyleDependencies, DrawingInsets, DrawingPoint, FieldLinkProjector, type FieldLinkRegistry, FixedPoint, FixedPointRoundingMode, FontByteValidator, GRAPHEME_SEGMENTER_LOCALE, type GraphemeBoundary, type GraphemeSegment, type GraphemeWordSegmentRecord, HARFBUZZ_SHAPING_LIBRARY, type HarfBuzzFaceCacheEvent, type HarfBuzzOutlineCacheEvent, type HarfBuzzShapeCacheEvent, HarfBuzzShapingError, type HarfBuzzShapingErrorCode, type HarfBuzzTextShaper, type HarfBuzzTextShaperInstrumentation, type HarfBuzzTextShaperOptions, HeaderFooterStoryRecord, type HeaderFooterVariantName, HyperlinkFieldSpec, HyperlinkProjector, InlineDrawingRecord, type KeyedRange, LayoutBox, type LayoutCacheStats, type LayoutScheduler, type LayoutSchedulerOptions, type LayoutScope, type LayoutSession, type LayoutSessionStats, LineRecord, type LineSegment, type ListCounterAdvance, type ListCounterState, MAX_EACH_PAGE_MARK_CANDIDATES, MAX_LVL_TEXT_LENGTH, MAX_MARKER_TEXT_LENGTH, MAX_NOTES_LAID_OUT, MAX_NOTE_FRAGMENTS, MAX_NOTE_OVERFLOW_PAGES, MAX_NOTE_REFLOW_ATTEMPTS, MAX_TABLE_COLUMNS, MAX_TABLE_ROW_FRAGMENTS, type MaterializationInput, NoteAreaRecord, type NoteDisplayMark, type NoteLayoutFallbackReason, type NoteMarkContext, type NotePaginationFallbackReason, type NoteReferenceSite, type NoteSeparatorLayout, type NoteSeparatorRuleStyle, type NoteStoryDrawings, type NoteStoryLayout, NoteStoryRecord, type NotesAttachResult, type NotesLayoutInput, NumberingIndex, NumberingLevel, type PageFurniture, PageGeometry, PageRecord, type PageRefIndex, ParagraphFragmentRecord, type ParagraphKeyInputs, type ParagraphLayoutCache, type ParagraphLayoutCacheOptions, RefFieldContext, type RefFieldRefreshOptions, type RegisteredFieldLink, ResolvedListItem, type ResolvedSurfaceMeasurer, ReviewItem, type ReviewParagraphAnchor, RevisionAttribution, RevisionAuthorFilter, RevisionDisplayMode, SectionColumns, SelectionRect, type SemanticDrawingLayer, type SemanticDrawingVisit, SemanticLayout, type SemanticLayoutOptions, SemanticPosition, type SemanticRootStoryKind, SemanticSelection, type SemanticSpanVisit, type SemanticStoryKind, type SemanticStoryVisit, SemanticTableStructure, ShapedRun, SourceRange, SpanLinkRecord, type StoryDrawingContext, type StoryDrawingHost, type StoryParagraphFragmentContext, type StoryProjectionDependencies, StyleCascadeTable, StyleSpanRecord, TableBorderSide, TablePaginationError, type TablePaginationErrorCode, TextMeasurer, TextShaper, VersionedShapingLibrary, type ViewportWindow, WORD_SEGMENTER_LOCALE, type WordBoundary, type WordBoundaryResolverDeps, type WordSegment, anchorLineY, attachNotesToLayout, boundedFallbackWordSegments, buildPageRefIndex, clampListValue, computeDoubleBorderMetricsPt, computeFootnoteReserves, contentControlBoundaries, contentControlHoldingParagraph, contentControlRecordsInPart, contentControlsOfLayout, createBoundedFallbackWordBoundary, createDefaultWordBoundary, createDocumentFurnitureSource, createDocumentLinkProjectors, createDocumentNotesInput, createDocumentStyleDependencies, createFieldLinkRegistry, createFixedMeasurer, createHarfBuzzTextShaper, createIntlWordBoundary, createLayoutScheduler, createLayoutSession, createListCounterState, createParagraphLayoutCache, defaultNoteSeparatorRuleStyle, deriveNoteDisplayMarks, deriveNoteDisplayMarksResolved, documentOrder, documentRelationshipTargetIn, effectiveBorderSide, effectiveContentControlLock, emptyTocPlaceholderParagraphIds, emptyTocSuppressedResultParagraphIds, everyStoryOrder, expandLvlText, exportSourceRangeOf, filterRefsOnPage, findSeparatorNote, forEachSemanticDrawing, forEachSemanticSpan, forEachSemanticStory, forEachStoryParagraphFragment, formatDecimal, formatDecimalZero, formatLowerLetter, formatLowerRoman, formatNumFmt, formatPageNumber, formatUpperLetter, formatUpperRoman, fragmentOwnsAtomOffset, fragmentsOfParagraph, graphemeBoundaryEpoch, graphemeCount, graphemeOffsetToUtf16, harfBuzzFontValidator, initializeHarfBuzz, intlGraphemeBoundary, isCanvasMeasurementAvailable, isCumulativeGeometryTrustedFromLineOrigin, isGeometryTrustedCaretOffset, isHarfBuzzInitialized, isIntlSegmenterAvailable, isIntlWordSegmenterAvailable, isMarkerOnlySeparatorNote, isWholeGraphemeHorizontalBoundary, keyedRangeRects, layoutHeaderFooterStory, layoutNoteById, layoutNoteSeparator, layoutNoteStory, layoutSemanticDocument, lineAtPosition, lineSegments, linesOf, normalNotesOf, noteDisplayMarkMap, noteLineIdPrefix, noteMarkKey, noteSeparatorAreaBox, noteStoryBlocks, pageRefPageNumbersFromLayout, pagesToMaterialize, paragraphFragmentsOf, paragraphFragmentsOfBlocks, paragraphLayoutKey, paragraphMarkDeleted, paragraphShading, paragraphShadingBox, parseAutonumInstruction, planRefFieldResultRefresh, positionPastDeletion, projectedNoteMarkText, provisionalNoteMarks, resetGraphemeBoundary, resolveDefaultSurfaceMeasurer, resolveDefaultWordBoundary, resolveOoxmlShadingFill, resolveStrictHexFill, reviewAnchorIndex, reviewItemGeometry, revisionRemovesParagraph, roundFontUnitToFixedPoint, segmentGraphemes, segmentWords, selectionRects, semanticHorizontalBoundaries, setGraphemeBoundary, setHarfBuzzWasmUrl, sha256FontBytes, shadingFillFromElement, shapedHorizontalBoundaries, storyBlocks, syntheticSeparatorBox, tableOriginX, tocFieldChromeParagraphIds, tryCreateCanvasMeasurer, unionLayoutBoxes, utf16OffsetToGrapheme, wordBoundary, wordSegmentsToGraphemeRecords };
|