@betteroffice/docx 0.0.1 → 0.0.3

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.
Files changed (165) hide show
  1. package/README.md +19 -0
  2. package/dist/chunk-AEQOEQJ7.mjs +57 -0
  3. package/dist/chunk-AZ52IWB6.mjs +16 -0
  4. package/dist/{chunk-SINEY6ZF.mjs → chunk-B4IR6YP4.mjs} +1 -1
  5. package/dist/chunk-GGEGIQRK.mjs +1 -0
  6. package/dist/chunk-IFT6DUJX.mjs +1 -0
  7. package/dist/chunk-J7LNO6SM.mjs +1 -0
  8. package/dist/{chunk-H3JCIGWK.mjs → chunk-NJHOPXZW.mjs} +1 -1
  9. package/dist/{chunk-KXNZFTTK.mjs → chunk-WBH3SXI6.mjs} +1 -1
  10. package/dist/chunk-WON6K4FY.mjs +1 -0
  11. package/dist/chunk-Y7RUNRU2.mjs +1 -0
  12. package/dist/collaboration/index.d.mts +65 -0
  13. package/dist/collaboration/index.mjs +1 -0
  14. package/dist/{content-sSHuWw49.d.mts → content-MOZ6hKP4.d.mts} +357 -357
  15. package/dist/core.d.mts +148 -341
  16. package/dist/core.mjs +1 -1
  17. package/dist/{displayListQueries-p-ijSzdh.d.mts → displayListQueries-BJlo7Jkz.d.mts} +24 -6
  18. package/dist/docx/index.d.mts +40 -520
  19. package/dist/docx/index.mjs +2 -2
  20. package/dist/editor/index.d.mts +36 -151
  21. package/dist/editor/index.mjs +1 -1
  22. package/dist/{fontLoader-Bx6DK6-2.d.mts → fontLoader-aSewHMKF.d.mts} +65 -63
  23. package/dist/{formatting-DoL7KBSL.d.mts → formatting-D1EPSaJP.d.mts} +1 -1
  24. package/dist/{rustDisplayList-dqunvwxH.d.mts → frameDelta-D965X8yK.d.mts} +3 -274
  25. package/dist/generated/edit/docx_edit_bg.wasm +0 -0
  26. package/dist/generated/layout/docx_layout_bg.wasm +0 -0
  27. package/dist/generated/opc/ooxml_opc_bg.wasm +0 -0
  28. package/dist/generated/parse/docx_parse_bg.wasm +0 -0
  29. package/dist/index-Dx4Z3lkz.d.mts +1010 -0
  30. package/dist/layout/index.d.mts +19 -240
  31. package/dist/layout/index.mjs +1 -1
  32. package/dist/layout/pagination/index.d.mts +10 -58
  33. package/dist/layout/pagination/index.mjs +1 -1
  34. package/dist/layout/render/index.d.mts +11 -11
  35. package/dist/layout/render/index.mjs +1 -1
  36. package/dist/plugin-api/RenderedDomContext.d.mts +9 -9
  37. package/dist/plugin-api/index.d.mts +191 -6
  38. package/dist/plugin-api/resolveItemPositions.d.mts +4 -5
  39. package/dist/rustDisplayList-BRuZBqdL.d.mts +278 -0
  40. package/dist/rustMeasureSource-D1KsQvVC.d.mts +106 -0
  41. package/dist/selectiveSave-CVoajSKE.d.mts +56 -0
  42. package/dist/styles/index.d.mts +4 -39
  43. package/dist/styles/index.mjs +1 -1
  44. package/dist/{styles-VxNcXLdi.d.mts → styles-Dn_o3Vo5.d.mts} +2 -2
  45. package/dist/types/content.d.mts +2 -2
  46. package/dist/types/document.d.mts +40 -14
  47. package/dist/{types-DNrYr6yQ.d.mts → types-BfqUl2h_.d.mts} +3 -71
  48. package/dist/utils/comments.d.mts +2 -2
  49. package/dist/utils/index.d.mts +110 -576
  50. package/dist/utils/index.mjs +1 -84
  51. package/dist/utils/stylePreview.d.mts +2 -2
  52. package/dist/utils/units.d.mts +33 -2
  53. package/dist/wasm-DO3BUV7C.mjs +1 -0
  54. package/dist/wasm-NWXX4H5G.mjs +1 -0
  55. package/dist/wasm-edit.d.mts +14 -5
  56. package/dist/wasm-edit.mjs +1 -1
  57. package/dist/wasm-layout.d.mts +10 -1
  58. package/dist/wasm-layout.mjs +1 -1
  59. package/dist/wasm-opc.mjs +1 -1
  60. package/dist/wasm-parse.mjs +1 -1
  61. package/dist/yrs/index.d.mts +6 -881
  62. package/dist/yrs/index.mjs +1 -1
  63. package/dist/yrs/residentEngineWorker.mjs +1 -1
  64. package/package.json +16 -139
  65. package/dist/Subscribable-DOz6Ohoo.d.mts +0 -33
  66. package/dist/agent/index.d.mts +0 -531
  67. package/dist/agent/index.mjs +0 -1
  68. package/dist/chunk-34K66SY4.mjs +0 -1
  69. package/dist/chunk-4RCISPPE.mjs +0 -1
  70. package/dist/chunk-52GB3Y42.mjs +0 -1
  71. package/dist/chunk-6NEKRDXF.mjs +0 -1
  72. package/dist/chunk-6PW4CWUG.mjs +0 -1
  73. package/dist/chunk-7DEIW7FL.mjs +0 -1
  74. package/dist/chunk-7PCO5I2O.mjs +0 -1
  75. package/dist/chunk-BI3B33LI.mjs +0 -1
  76. package/dist/chunk-BIQWVK5P.mjs +0 -2
  77. package/dist/chunk-CIRN3LZA.mjs +0 -1
  78. package/dist/chunk-DXKG3HQ5.mjs +0 -16
  79. package/dist/chunk-FPZBTOD6.mjs +0 -1
  80. package/dist/chunk-FZIA7OFY.mjs +0 -1
  81. package/dist/chunk-GWKJ2Y4Y.mjs +0 -1
  82. package/dist/chunk-HJGAQIU7.mjs +0 -2
  83. package/dist/chunk-I6KKMUUC.mjs +0 -1
  84. package/dist/chunk-IL5JZJT7.mjs +0 -1
  85. package/dist/chunk-JY6ILTNS.mjs +0 -1
  86. package/dist/chunk-KEE52TT5.mjs +0 -1
  87. package/dist/chunk-KVKLLTDP.mjs +0 -58
  88. package/dist/chunk-L5ISVQ3W.mjs +0 -1
  89. package/dist/chunk-LDUWIM7M.mjs +0 -1
  90. package/dist/chunk-N5Q3YN64.mjs +0 -1
  91. package/dist/chunk-NEWOMDTX.mjs +0 -1
  92. package/dist/chunk-O2QSE2I7.mjs +0 -1
  93. package/dist/chunk-OJOHXQNQ.mjs +0 -1
  94. package/dist/chunk-OMR3TWCD.mjs +0 -2
  95. package/dist/chunk-P3KDV4M2.mjs +0 -1
  96. package/dist/chunk-Q7PO7V73.mjs +0 -1
  97. package/dist/chunk-QOUFE3VX.mjs +0 -1
  98. package/dist/chunk-TYHI7RAD.mjs +0 -1
  99. package/dist/chunk-UIEJWORW.mjs +0 -1
  100. package/dist/chunk-VAOUFAUH.mjs +0 -1
  101. package/dist/chunk-VBOTMRXV.mjs +0 -1
  102. package/dist/chunk-VCER63GQ.mjs +0 -1
  103. package/dist/chunk-WAUF2UC7.mjs +0 -2
  104. package/dist/chunk-X4XDO3LZ.mjs +0 -1
  105. package/dist/chunk-XQBCCJBO.mjs +0 -9
  106. package/dist/chunk-XWUOLYRQ.mjs +0 -2
  107. package/dist/chunk-XYH6XWP3.mjs +0 -10
  108. package/dist/chunk-YBIM6UJV.mjs +0 -8
  109. package/dist/chunk-YCIH2Q3E.mjs +0 -1
  110. package/dist/chunk-ZOV5KL7C.mjs +0 -1
  111. package/dist/colorResolver-n0o7H7ep.d.mts +0 -290
  112. package/dist/core-plugins.d.mts +0 -37
  113. package/dist/core-plugins.mjs +0 -1
  114. package/dist/docx/parser.d.mts +0 -41
  115. package/dist/docx/parser.mjs +0 -1
  116. package/dist/docx/rezip.d.mts +0 -148
  117. package/dist/docx/rezip.mjs +0 -1
  118. package/dist/docx/serializer/index.d.mts +0 -42
  119. package/dist/docx/serializer/index.mjs +0 -1
  120. package/dist/editorTree-DO5PyDK8.d.mts +0 -37
  121. package/dist/executor-7O2RBJ2B.mjs +0 -1
  122. package/dist/headerFooterLayout-0zPT64Qc.d.mts +0 -316
  123. package/dist/headless.d.mts +0 -69
  124. package/dist/headless.mjs +0 -1
  125. package/dist/layout/flow/index.d.mts +0 -149
  126. package/dist/layout/flow/index.mjs +0 -1
  127. package/dist/layout/measure/index.d.mts +0 -324
  128. package/dist/layout/measure/index.mjs +0 -1
  129. package/dist/layout/pagination/types.d.mts +0 -4
  130. package/dist/layout/pagination/types.mjs +0 -1
  131. package/dist/managers/AutoSaveManager.d.mts +0 -81
  132. package/dist/managers/AutoSaveManager.mjs +0 -1
  133. package/dist/managers/TableSelectionManager.d.mts +0 -74
  134. package/dist/managers/TableSelectionManager.mjs +0 -1
  135. package/dist/managers/types.d.mts +0 -113
  136. package/dist/managers/types.mjs +0 -0
  137. package/dist/mcp-cli.mjs +0 -142
  138. package/dist/mcp.d.mts +0 -162
  139. package/dist/mcp.mjs +0 -16
  140. package/dist/measureBlocksPipeline-Df0Bbrwy.d.mts +0 -109
  141. package/dist/measuredBlock-DZwz8zhD.d.mts +0 -26
  142. package/dist/plugin-api/types.d.mts +0 -193
  143. package/dist/plugin-api/types.mjs +0 -0
  144. package/dist/processTemplate-HDUIZFJ5.mjs +0 -1
  145. package/dist/registry-DMM5VTdT.d.mts +0 -165
  146. package/dist/rustPagination-Bj2hq013.d.mts +0 -106
  147. package/dist/sectionConfigs-DW3J8q0X.d.mts +0 -55
  148. package/dist/selectionContext-Buc9BCU1.d.mts +0 -570
  149. package/dist/selectiveSave-oFBJ1n71.d.mts +0 -16
  150. package/dist/selectiveXmlPatch-ypkxlTD_.d.mts +0 -23
  151. package/dist/settingsParser-CcGvtmCK.d.mts +0 -33
  152. package/dist/types/agentApi.d.mts +0 -456
  153. package/dist/types/agentApi.mjs +0 -1
  154. package/dist/types-dYdjUZMo.d.mts +0 -311
  155. package/dist/units-O5Y02RKQ.d.mts +0 -34
  156. package/dist/utils/headingCollector.d.mts +0 -28
  157. package/dist/utils/headingCollector.mjs +0 -1
  158. package/dist/utils/highlightColors.d.mts +0 -14
  159. package/dist/utils/highlightColors.mjs +0 -1
  160. package/dist/utils/textSelection.d.mts +0 -92
  161. package/dist/utils/textSelection.mjs +0 -1
  162. package/dist/variableDetector-Borj29SF.d.mts +0 -115
  163. package/dist/wasm-FZQ5XB2Y.mjs +0 -1
  164. package/dist/wasm-SA237OSP.mjs +0 -1
  165. package/dist/watermarkApi-DCxjutkg.d.mts +0 -38
@@ -1,7 +1,5 @@
1
- import { a as Layout } from './types-DNrYr6yQ.mjs';
2
- import { M as MeasuredBlock } from './measuredBlock-DZwz8zhD.mjs';
3
- import { Z as DrawingScene, b0 as ShapeTextBodyProperties } from './content-sSHuWw49.mjs';
4
- import { x as TextModernEffects } from './formatting-DoL7KBSL.mjs';
1
+ import { D as DrawingScene, d as ShapeTextBodyProperties } from './content-MOZ6hKP4.mjs';
2
+ import { T as TextModernEffects } from './formatting-D1EPSaJP.mjs';
5
3
 
6
4
  interface DisplayList {
7
5
  /** Contract version. Undefined reads as legacy version 0. */
@@ -764,273 +762,4 @@ declare function applyFrameDelta(previous: RetainedFrame | null, delta: DecodedF
764
762
  */
765
763
  declare function applyFrameDeltaOwned(previous: RetainedFrame | null, delta: DecodedFrameDelta): RetainedFrame;
766
764
 
767
- /**
768
- * JS seam to the Rust display-list builder (crates/docx-layout).
769
- *
770
- * Marshals the same `{ measured, options, layout }` triple the golden
771
- * fixtures pin (see scripts/export-displaylist-fixtures.ts) across the wasm
772
- * boundary and parses the resulting DisplayList. All paint/geometry decisions
773
- * happen in Rust — this module is serialization glue only.
774
- *
775
- * The wasm module is loaded lazily via dynamic import on first build, so the
776
- * ~800KB inlined binary costs nothing until the experimental canvas renderer
777
- * is actually enabled.
778
- *
779
- * @experimental part of the rust-canvas-engine change; shape may evolve.
780
- */
781
-
782
- /**
783
- * One header/footer part in the `headersFooters` envelope field: the measured
784
- * blocks of the HF ProseMirror doc identified by `rId`, plus the band metrics
785
- * `convertHeaderFooterPmDocToContent` computed (passed through verbatim — the
786
- * Rust builder re-derives nothing).
787
- */
788
- interface DisplayListHfVariant {
789
- rId: string;
790
- kind: 'header' | 'footer';
791
- type: 'default' | 'first' | 'even';
792
- /** `toMeasuredBlocks(content.blocks, content.measures)` — same schema as body `measured` */
793
- measured: MeasuredBlock[];
794
- /** HeaderFooterContent.height (in-flow stack incl. floating blocks) */
795
- height: number;
796
- /** HeaderFooterContent.flowHeight (in-flow band height; fallback: height) */
797
- flowHeight?: number;
798
- visualTop?: number;
799
- visualBottom?: number;
800
- /**
801
- * Per-page resolved widths of PAGE/NUMPAGES field runs in this HF part, so a
802
- * centered/right-aligned line carrying such a field re-centers per page. The
803
- * line width is measured ONCE at the field's fallback text ("1"), so without
804
- * this the builder holds the same centered position on every page even though
805
- * "Page 2 of 3"/"Page 10 of 12" have different widths. Omitted ⇒ the fields
806
- * ride the char-distributed fallback width (byte-identical to before).
807
- */
808
- fieldWidths?: DisplayListFieldWidths[];
809
- }
810
- /**
811
- * Per-page widths of one PAGE/NUMPAGES field run in an HF part. `pmStart` is the
812
- * field run's position in the HF ProseMirror doc (the key the Rust builder
813
- * matches). `fallbackWidth` is the width the measure baked into `line.width`
814
- * (the field's fallback text); `perPage[i]` is the width of the field's resolved
815
- * text on layout page index `i` (PAGE → that page's number, NUMPAGES → total).
816
- */
817
- interface DisplayListFieldWidths {
818
- pmStart: number;
819
- fallbackWidth: number;
820
- perPage: number[];
821
- }
822
- /**
823
- * Optional header/footer payload of the builder envelope. Absent ⇒ the Rust
824
- * output is byte-identical to the body-only build. Flags come off the section
825
- * properties / settings the DOM painter uses; distances are the same px the
826
- * painter resolves (`headerDistance ?? page.margins.header ?? 48`).
827
- */
828
- interface DisplayListHeadersFooters {
829
- titlePg?: boolean;
830
- evenAndOddHeaders?: boolean;
831
- headerDistance?: number;
832
- footerDistance?: number;
833
- /** Page-level Word watermark, painted behind body/header/footer content. */
834
- watermark?: DisplayListWatermark;
835
- variants: DisplayListHfVariant[];
836
- /** Stable section identity. Undefined = document-global legacy envelope. */
837
- sectionId?: string;
838
- /** Zero-based section index. */
839
- sectionIndex?: number;
840
- }
841
- type DisplayListWatermark = DisplayListTextWatermark | DisplayListPictureWatermark;
842
- interface DisplayListTextWatermark {
843
- kind: 'text';
844
- text: string;
845
- font: string;
846
- color: string;
847
- semitransparent: boolean;
848
- layout: 'diagonal' | 'horizontal';
849
- fontSize?: number;
850
- /** Undefined defaults to true for watermarks. */
851
- decorative?: boolean;
852
- }
853
- interface DisplayListPictureWatermark {
854
- kind: 'picture';
855
- relId?: string;
856
- dataUrl?: string;
857
- scale: number;
858
- washout: boolean;
859
- widthEmu?: number;
860
- heightEmu?: number;
861
- /** Undefined defaults to true for watermarks. */
862
- decorative?: boolean;
863
- }
864
- /** One measured note in a page/section note area. */
865
- interface DisplayListNoteItem {
866
- kind?: 'footnote' | 'endnote';
867
- id?: number;
868
- displayLabel?: string;
869
- measured?: MeasuredBlock[];
870
- height?: number;
871
- anchorDocStart?: number;
872
- anchorDocEnd?: number;
873
- customMarkFollows?: boolean;
874
- }
875
- /** Typed non-fragmented note-region input for the Rust display builder. */
876
- interface DisplayListNoteArea {
877
- pageIndex?: number;
878
- sectionId?: string;
879
- kind?: 'footnote' | 'endnote';
880
- placement?: 'pageBottom' | 'beneathText' | 'sectEnd' | 'docEnd';
881
- y?: number;
882
- height?: number;
883
- columns?: number;
884
- separator?: DisplayListNoteItem;
885
- notes?: DisplayListNoteItem[];
886
- }
887
- /** Stable reviewer palette entry for comments/revisions. */
888
- interface DisplayListCommentAuthor {
889
- id?: string;
890
- name?: string;
891
- paletteIndex?: number;
892
- color?: string;
893
- }
894
- /** One reply of a comment thread (a11y announcement input). */
895
- interface DisplayListCommentReply {
896
- id?: number;
897
- authorId?: string;
898
- authorName?: string;
899
- date?: string;
900
- /** Plain-text body (the builder caps it before it reaches primitives). */
901
- text?: string;
902
- }
903
- /**
904
- * Per-comment thread metadata keyed by comment id, joined by the builder onto
905
- * every primitive carrying that id in `commentIds` so the a11y mirror can
906
- * announce the complete thread (author name, date, body, replies). All string
907
- * values are file-derived/attacker-controlled; consumers must only ever
908
- * assign them via textContent/setAttribute.
909
- */
910
- interface DisplayListCommentThread {
911
- /** Comment id — matches the numeric ids in `resolvedCommentIds`/`commentIds`. */
912
- id?: number;
913
- authorId?: string;
914
- authorName?: string;
915
- date?: string;
916
- /** Plain-text body (builder-capped before emission). */
917
- text?: string;
918
- /** Replies in thread order (builder-capped count and text). */
919
- replies?: DisplayListCommentReply[];
920
- }
921
- /** The `{ measured, options, layout }` envelope the Rust builder consumes. */
922
- interface DisplayListBuildInputs {
923
- /** Serialization contract version. Undefined reads as legacy version 0. */
924
- contractVersion?: number;
925
- measured: MeasuredBlock[];
926
- options: unknown;
927
- layout: Layout;
928
- /** header/footer parts + section flags; omitted ⇒ body-only display list */
929
- headersFooters?: DisplayListHeadersFooters;
930
- /**
931
- * Doc-wide font-id chains keyed `"<family lowercase>|<bold 0|1>|<italic 0|1>"`
932
- * → measurement `FontStore` ids — the SAME map the measurement input carries.
933
- * Present only under Rust measurement (the ids must belong to a populated
934
- * store); its presence against that store is what gates GlyphRun emission.
935
- * Omitted ⇒ every text run takes the browser-measured `TextRunPrimitive` path
936
- * (byte-identical to the pre-glyph build).
937
- */
938
- fontChains?: Record<string, number[]>;
939
- /** Page/section note regions. Undefined = no note emission. */
940
- noteAreas?: DisplayListNoteArea[];
941
- /** Resolved comments suppressed from active tint. Undefined = none known. */
942
- resolvedCommentIds?: number[];
943
- /** Stable reviewer palette. Undefined = legacy hard-coded colors. */
944
- commentAuthors?: DisplayListCommentAuthor[];
945
- /** Per-comment thread metadata for a11y announcements. Undefined = none. */
946
- commentThreads?: DisplayListCommentThread[];
947
- }
948
- /** Minimal engine surface, injectable so tests can fake the wasm module. */
949
- interface RustDisplayListEngine {
950
- buildDisplayListJson(input: string): string;
951
- /** Resident editing engines expose binary deltas; the stateless layout wasm does not. */
952
- buildDisplayListFrame?(input: string, expectedFrameEpoch: number): Uint8Array;
953
- /** One-owner ordinary input path; available on the resident editing engine. */
954
- applyInput?(text: string, expectedFrameEpoch: number): Uint8Array;
955
- displayHitTestRegionsJson?(pageIndex: number, x: number, y: number): string;
956
- displayRangeRectsJson?(from: number, to: number): string;
957
- displayRangeRectsRegionJson?(region: 'body' | 'header' | 'footer', rId: string, from: number, to: number): string;
958
- }
959
- type RustDisplayListSourceErrorStage = 'load' | 'build' | 'parse' | 'decode' | 'apply';
960
- interface RustDisplayFrameResult {
961
- displayList: DisplayList;
962
- /** Null only on the compatibility JSON engine path. */
963
- frame: RetainedFrame | null;
964
- transport: 'frame-delta-v1' | 'json';
965
- }
966
- /**
967
- * Typed terminal error from the mandatory Rust display-list source. Hosts may
968
- * surface this through their editor error boundary; it is never permission to
969
- * silently substitute painter geometry.
970
- */
971
- declare class RustDisplayListSourceError extends Error {
972
- readonly stage: RustDisplayListSourceErrorStage;
973
- constructor(stage: RustDisplayListSourceErrorStage, cause: unknown);
974
- }
975
- /**
976
- * Query surface over an already-built display list, injectable so tests can
977
- * fake the wasm module.
978
- *
979
- * The `*Json` calls take the display-list JSON string as an argument (the Rust
980
- * side re-parses it per query — callers should cache the string). The
981
- * session-handle members parse the list ONCE (`openDisplayList` → handle) and
982
- * answer many queries by handle with no re-serialization, reusing the same
983
- * hit/range logic so results are byte-identical. The handle members are
984
- * OPTIONAL: the embedded wasm carries them only after the integrator re-embeds,
985
- * so `createDisplayListQueries` feature-detects `hasDisplayListSession` and
986
- * falls back to the `*Json` path when they are absent.
987
- */
988
- interface RustDisplayListQueryEngine {
989
- /** region-aware hit test → `{"region","rId"?,"pos"}` or `"null"` JSON */
990
- hitTestRegionsJson(displayList: string, pageIndex: number, x: number, y: number): string;
991
- /** body PM range → JSON array of `{pageIndex,x,y,width,height}` rects */
992
- rangeRectsJson(displayList: string, from: number, to: number): string;
993
- /**
994
- * Region-aware PM range → JSON array of rects. `region` is
995
- * `'body' | 'header' | 'footer'`; `rId` scopes header/footer to one HF part
996
- * (empty for body / match-any). OPTIONAL: the embedded wasm carries it only
997
- * after the integrator re-embeds, so `createDisplayListQueries` falls back to
998
- * `[]` when absent (HF selection geometry stays a documented gap until then).
999
- */
1000
- rangeRectsRegionJson?(displayList: string, region: string, rId: string, from: number, to: number): string;
1001
- /** true when the embedded wasm carries the region-aware range-rect exports */
1002
- hasRangeRectsRegion?(): boolean;
1003
- /** true when the embedded wasm carries the session-handle exports below */
1004
- hasDisplayListSession?(): boolean;
1005
- /** parse a display list once, return a handle for the by-handle queries */
1006
- openDisplayList?(displayList: string): number;
1007
- /** free a handle's parsed display list */
1008
- closeDisplayList?(handle: number): void;
1009
- /** region-aware hit test against a stored display list (by handle) */
1010
- hitTestRegionsByHandle?(handle: number, pageIndex: number, x: number, y: number): string;
1011
- /** body PM range against a stored display list (by handle) */
1012
- rangeRectsByHandle?(handle: number, from: number, to: number): string;
1013
- /** region-aware PM range against a stored display list (by handle) */
1014
- rangeRectsRegionByHandle?(handle: number, region: string, rId: string, from: number, to: number): string;
1015
- }
1016
- /**
1017
- * Lazily load the wasm query surface (hit-test + range-rects). Shares the
1018
- * module promise with `buildRustDisplayList`, so on the canvas-renderer path
1019
- * the engine is already resolved by the time the first display list lands.
1020
- */
1021
- declare function loadRustDisplayListQueryEngine(): Promise<RustDisplayListQueryEngine>;
1022
- /** Display-only fields sent to an engine that already retains pagination. */
1023
- declare function encodeDisplayListFrameExtras(inputs: DisplayListBuildInputs): string;
1024
- /**
1025
- * Build a DisplayList for a computed layout through the Rust engine. Throws
1026
- * when the wasm module fails to load or the builder rejects the input — the
1027
- * caller is expected to fall back to the DOM painter.
1028
- */
1029
- declare function buildRustDisplayList(inputs: DisplayListBuildInputs, engine?: RustDisplayListEngine): Promise<DisplayList>;
1030
- /**
1031
- * Production display build. Resident editing engines return FrameDelta v1;
1032
- * older/stateless engines retain the full-JSON parity path.
1033
- */
1034
- declare function buildRustDisplayFrame(inputs: DisplayListBuildInputs, engine?: RustDisplayListEngine, previous?: RetainedFrame | null): Promise<RustDisplayFrameResult>;
1035
-
1036
- export { applyFrameDeltaOwned as A, buildRustDisplayFrame as B, buildRustDisplayList as C, type DisplayList as D, decodeFrameDelta as E, FRAME_DELTA_HEADER_BYTES as F, type GlyphRunPrimitive as G, type HfRegion as H, type ImagePrimitive as I, encodeDisplayListFrameExtras as J, loadRustDisplayListQueryEngine as K, type LinePrimitive as L, type PositionedGlyph as P, type RustDisplayListQueryEngine as R, type TextRunPrimitive as T, type DisplayListHeadersFooters as a, type DisplayPage as b, type DisplayPrimitive as c, type DecodedFrameDelta as d, type DecorationPrimitive as e, type DisplayBounds as f, type DisplayListBuildInputs as g, type DisplayListHfVariant as h, type DisplayListPictureWatermark as i, type DisplayListTextWatermark as j, type DisplayListWatermark as k, type DocAttrs as l, FRAME_DELTA_PAGE_OP_BYTES as m, FRAME_DELTA_VERSION as n, FrameDeltaError as o, type FrameDeltaErrorCode as p, type FramePageOperation as q, type RectPrimitive as r, type RetainedFrame as s, type RetainedFramePage as t, type RustDisplayFrameResult as u, type RustDisplayListEngine as v, RustDisplayListSourceError as w, type RustDisplayListSourceErrorStage as x, type TableCellRef as y, applyFrameDelta as z };
765
+ export { type DisplayList as D, FRAME_DELTA_HEADER_BYTES as F, type GlyphRunPrimitive as G, type HfRegion as H, type ImagePrimitive as I, type LinePrimitive as L, type PositionedGlyph as P, type RetainedFrame as R, type TextRunPrimitive as T, type DisplayPage as a, type DisplayPrimitive as b, type DecodedFrameDelta as c, type DecorationPrimitive as d, type DisplayBounds as e, type DocAttrs as f, FRAME_DELTA_PAGE_OP_BYTES as g, FRAME_DELTA_VERSION as h, FrameDeltaError as i, type FrameDeltaErrorCode as j, type FramePageOperation as k, type RectPrimitive as l, type RetainedFramePage as m, type TableCellRef as n, applyFrameDelta as o, applyFrameDeltaOwned as p, decodeFrameDelta as q };