@beyondwork/docx-react-component 1.0.124 → 1.0.126
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/dist/api/public-types.cjs +147 -35
- package/dist/api/public-types.d.cts +2 -2
- package/dist/api/public-types.d.ts +2 -2
- package/dist/api/public-types.js +3 -3
- package/dist/api/v3.cjs +796 -102
- package/dist/api/v3.d.cts +3 -3
- package/dist/api/v3.d.ts +3 -3
- package/dist/api/v3.js +10 -10
- package/dist/{canonical-document-CG2TgAzj.d.cts → canonical-document-CXCFCbAz.d.cts} +2 -0
- package/dist/{canonical-document-CG2TgAzj.d.ts → canonical-document-CXCFCbAz.d.ts} +2 -0
- package/dist/{chunk-PFYUJU3Q.js → chunk-2QL5DAKF.js} +98 -43
- package/dist/{chunk-4IPEZYQX.js → chunk-4EENH4FG.js} +1 -1
- package/dist/{chunk-BOHHIVQ2.js → chunk-4G3OS2H6.js} +3 -3
- package/dist/{chunk-A74Y5NE4.js → chunk-4YJVRIUB.js} +52 -21
- package/dist/{chunk-FNWKE74J.js → chunk-5DGKFNQT.js} +5 -1
- package/dist/{chunk-RSYN6FTS.js → chunk-6F5QW44A.js} +2 -2
- package/dist/{chunk-ZMRO6P3A.js → chunk-6IGWPAR4.js} +505 -44
- package/dist/{chunk-KOHQFZMM.js → chunk-BYSRJ4FE.js} +1 -1
- package/dist/{chunk-H6IL5ABU.js → chunk-CXSYRB37.js} +64 -20
- package/dist/{chunk-32ZAOQ54.js → chunk-D5HYZQTG.js} +1 -1
- package/dist/{chunk-TY4DIJO3.js → chunk-ESJ2MES5.js} +1 -1
- package/dist/{chunk-Q76XPPTA.js → chunk-FPRWV54X.js} +101 -14
- package/dist/{chunk-MPH4ZQS4.js → chunk-GL7XRYBY.js} +624 -87
- package/dist/{chunk-IR7QV2BX.js → chunk-KV435YXO.js} +2 -2
- package/dist/{chunk-N4VIXI2Z.js → chunk-MWSBGJQO.js} +137 -18
- package/dist/{chunk-7PC6XUNO.js → chunk-TQDQU2E3.js} +2 -2
- package/dist/{chunk-4B74ETJI.js → chunk-V6XVZFFH.js} +2 -2
- package/dist/{chunk-NAMAWCXN.js → chunk-YD2JE54B.js} +1 -1
- package/dist/{chunk-ZRHLLPSJ.js → chunk-YHZHPXDB.js} +85 -18
- package/dist/{chunk-HXHQA4BU.js → chunk-YIYM4ZAP.js} +1 -1
- package/dist/{chunk-LGWNN3L2.js → chunk-ZDOAUP3V.js} +2 -2
- package/dist/compare.d.cts +1 -1
- package/dist/compare.d.ts +1 -1
- package/dist/core/commands/formatting-commands.d.cts +2 -2
- package/dist/core/commands/formatting-commands.d.ts +2 -2
- package/dist/core/commands/image-commands.cjs +65 -20
- package/dist/core/commands/image-commands.d.cts +2 -2
- package/dist/core/commands/image-commands.d.ts +2 -2
- package/dist/core/commands/image-commands.js +5 -5
- package/dist/core/commands/section-layout-commands.d.cts +2 -2
- package/dist/core/commands/section-layout-commands.d.ts +2 -2
- package/dist/core/commands/style-commands.d.cts +2 -2
- package/dist/core/commands/style-commands.d.ts +2 -2
- package/dist/core/commands/table-structure-commands.cjs +65 -20
- package/dist/core/commands/table-structure-commands.d.cts +2 -2
- package/dist/core/commands/table-structure-commands.d.ts +2 -2
- package/dist/core/commands/table-structure-commands.js +4 -4
- package/dist/core/commands/text-commands.cjs +66 -21
- package/dist/core/commands/text-commands.d.cts +2 -2
- package/dist/core/commands/text-commands.d.ts +2 -2
- package/dist/core/commands/text-commands.js +5 -5
- package/dist/core/selection/mapping.d.cts +2 -2
- package/dist/core/selection/mapping.d.ts +2 -2
- package/dist/core/state/editor-state.d.cts +2 -2
- package/dist/core/state/editor-state.d.ts +2 -2
- package/dist/index.cjs +1677 -240
- package/dist/index.d.cts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +62 -25
- package/dist/io/docx-session.cjs +51 -20
- package/dist/io/docx-session.d.cts +4 -4
- package/dist/io/docx-session.d.ts +4 -4
- package/dist/io/docx-session.js +4 -4
- package/dist/legal.cjs +36 -12
- package/dist/legal.d.cts +1 -1
- package/dist/legal.d.ts +1 -1
- package/dist/legal.js +3 -3
- package/dist/{loader-D9y4ZRjj.d.ts → loader-CS9-9KFa.d.ts} +3 -3
- package/dist/{loader-D9KCtj4m.d.cts → loader-OoWJ1_17.d.cts} +3 -3
- package/dist/{public-types-CNnMHZM9.d.ts → public-types-BP3vqJR5.d.cts} +157 -11
- package/dist/{public-types-DajNGKV4.d.cts → public-types-DdcHqcow.d.ts} +157 -11
- package/dist/public-types.cjs +147 -35
- package/dist/public-types.d.cts +2 -2
- package/dist/public-types.d.ts +2 -2
- package/dist/public-types.js +3 -3
- package/dist/runtime/collab.d.cts +3 -3
- package/dist/runtime/collab.d.ts +3 -3
- package/dist/runtime/document-runtime.cjs +945 -134
- package/dist/runtime/document-runtime.d.cts +2 -2
- package/dist/runtime/document-runtime.d.ts +2 -2
- package/dist/runtime/document-runtime.js +14 -14
- package/dist/{session-DyQGlryH.d.cts → session-Cq-fzx3B.d.cts} +3 -3
- package/dist/{session-DEmaOEjA.d.ts → session-DyFQt8Ph.d.ts} +3 -3
- package/dist/session.cjs +51 -20
- package/dist/session.d.cts +5 -5
- package/dist/session.d.ts +5 -5
- package/dist/session.js +5 -5
- package/dist/tailwind.cjs +238 -73
- package/dist/tailwind.d.cts +2 -2
- package/dist/tailwind.d.ts +2 -2
- package/dist/tailwind.js +7 -7
- package/dist/{types-CxE1aZiv.d.cts → types-Bg7D-GD3.d.cts} +2 -2
- package/dist/{types-DjJNaE9c.d.ts → types-bJAgMq1M.d.ts} +2 -2
- package/dist/ui-tailwind/editor-surface/search-plugin.d.cts +3 -3
- package/dist/ui-tailwind/editor-surface/search-plugin.d.ts +3 -3
- package/dist/ui-tailwind/editor-surface/search-plugin.js +4 -4
- package/dist/ui-tailwind.cjs +238 -73
- package/dist/ui-tailwind.d.cts +3 -3
- package/dist/ui-tailwind.d.ts +3 -3
- package/dist/ui-tailwind.js +7 -7
- package/package.json +1 -1
|
@@ -3,7 +3,7 @@ import { ReactNode } from 'react';
|
|
|
3
3
|
import * as Y from 'yjs';
|
|
4
4
|
import * as y_protocols_awareness from 'y-protocols/awareness';
|
|
5
5
|
import { Awareness } from 'y-protocols/awareness';
|
|
6
|
-
import { S as SectionProperties, f as PersistedEditorSnapshotVersion, g as CDS_SCHEMA_VERSION, I as ISO8601DateTime, C as CanonicalDocument, h as CompatibilityReportVersion, i as Base64, M as ModelValidationIssue, j as CommentThread, k as CommentEntry, l as CommentResolution, m as RevisionMetadataRecord$1, n as RevisionRecord$1, p as CanonicalSourceRef, q as SdtDataBindingState, F as FieldFamily$1, r as FieldRefreshStatus$1, T as TocRegion, s as CanonicalAnchor, t as PreserveOnlyObjectSizing, u as TableCellNode, v as TableLook, w as TableStyleFormatting, x as TableWidth, y as TableBorders, z as TableStyleConditionalRegion, A as TableCellBorders, E as CellShading, G as TextMark, H as Mutable, J as ParagraphNode, K as TableIndent, L as TableCellMargins, N as TableNode,
|
|
6
|
+
import { S as SectionProperties, f as PersistedEditorSnapshotVersion, g as CDS_SCHEMA_VERSION, I as ISO8601DateTime, C as CanonicalDocument, h as CompatibilityReportVersion, i as Base64, M as ModelValidationIssue, j as CommentThread, k as CommentEntry, l as CommentResolution, m as RevisionMetadataRecord$1, n as RevisionRecord$1, p as CanonicalSourceRef, q as SdtDataBindingState, F as FieldFamily$1, r as FieldRefreshStatus$1, T as TocRegion, s as CanonicalAnchor, t as PreserveOnlyObjectSizing, u as TableCellNode, B as BlockNode, v as TableLook, w as TableStyleFormatting, x as TableWidth, y as TableBorders, z as TableStyleConditionalRegion, A as TableCellBorders, E as CellShading, G as TextMark, H as Mutable, J as ParagraphNode, K as TableIndent, L as TableCellMargins, N as TableNode, Q as FieldRegistryEntry, U as FootnoteProperties, V as EndnoteProperties, W as CanonicalTheme, X as InlineNode, Y as CanonicalParagraphFormatting, Z as CanonicalRunFormatting, _ as FillSpec, $ as TextProperties, a0 as StrokeSpec, a1 as ChartModel, a2 as ResolvedTheme, a3 as ColorRef, a4 as SupportedFieldFamily$1, a5 as HeaderDocument, a6 as FooterDocument, a7 as ParagraphBorders } from './canonical-document-CXCFCbAz.js';
|
|
7
7
|
import * as prosemirror_state from 'prosemirror-state';
|
|
8
8
|
import { Command } from 'prosemirror-state';
|
|
9
9
|
import { Schema } from 'prosemirror-model';
|
|
@@ -2013,6 +2013,10 @@ interface RuntimeNumberingLayoutFacts {
|
|
|
2013
2013
|
sourceBlockPath?: string;
|
|
2014
2014
|
sourceBlockId?: string;
|
|
2015
2015
|
paragraphIndex?: number;
|
|
2016
|
+
targetKey?: string;
|
|
2017
|
+
targetKind?: string;
|
|
2018
|
+
canonicalAddressKey?: string;
|
|
2019
|
+
listAddressKey?: string;
|
|
2016
2020
|
sourceRef?: RuntimeFieldRegionLayoutFacts["sourceRef"];
|
|
2017
2021
|
numberingSourceRef?: RuntimeFieldRegionLayoutFacts["sourceRef"];
|
|
2018
2022
|
numberingOrigin?: "paragraph" | "paragraph-style";
|
|
@@ -2023,6 +2027,12 @@ interface RuntimeNumberingLayoutFacts {
|
|
|
2023
2027
|
numberingInstanceId?: string;
|
|
2024
2028
|
level?: number;
|
|
2025
2029
|
format?: string;
|
|
2030
|
+
formatPosture?: {
|
|
2031
|
+
status: "approximated";
|
|
2032
|
+
requestedFormat: string;
|
|
2033
|
+
renderedFormat: "decimal";
|
|
2034
|
+
reason: "unsupported-numbering-format-decimal-fallback" | "numbering-format-range-decimal-fallback";
|
|
2035
|
+
};
|
|
2026
2036
|
markerText?: string;
|
|
2027
2037
|
markerSuffix?: "tab" | "space" | "nothing";
|
|
2028
2038
|
markerJustification?: "left" | "center" | "right" | "both" | "distribute";
|
|
@@ -2038,7 +2048,9 @@ interface RuntimeNumberingLayoutFacts {
|
|
|
2038
2048
|
hangingTwips?: number;
|
|
2039
2049
|
};
|
|
2040
2050
|
tabStops?: readonly RuntimeNumberingTabStopFacts[];
|
|
2051
|
+
unavailableReasons?: readonly RuntimeNumberingUnavailableReason[];
|
|
2041
2052
|
}
|
|
2053
|
+
type RuntimeNumberingUnavailableReason = "canonical-numbering-input-missing" | "numbering-marker-lane-unavailable" | "numbering-text-column-unavailable";
|
|
2042
2054
|
interface RuntimeNumberingTabStopFacts {
|
|
2043
2055
|
positionTwips: number;
|
|
2044
2056
|
align?: string;
|
|
@@ -2198,7 +2210,7 @@ interface RuntimePageAnchor {
|
|
|
2198
2210
|
type EditableTargetKind = "paragraph-text" | "sdt-paragraph-text" | "table-cell-paragraph-text" | "nested-table-cell-paragraph-text" | "sdt-table-cell-paragraph-text" | "table-structure-table" | "table-structure-row" | "table-structure-column" | "table-structure-cell" | "table-structure-span" | "secondary-story-paragraph-text" | "textbox-paragraph-text" | "field-result-text" | "field-region-refresh" | "toc-region-refresh" | "hyperlink-text" | "hyperlink-destination" | "bookmark-anchor" | "bookmark-content-range" | "comment-anchor" | "revision-anchor" | "object-anchor" | "custom-xml-content" | "opaque-content";
|
|
2199
2211
|
type EditableTargetCommandFamily = "text-leaf" | "table-structure" | "field" | "link-bookmark" | "comment-revision" | "object" | "metadata" | "preserve-only-refusal";
|
|
2200
2212
|
type EditableTargetEditability = "editable" | "non-editable";
|
|
2201
|
-
type EditableTargetBlocker = "protected-section" | "protected-range" | "locked-content-control" | "preserve-only" | "opaque-content" | "field-generated-text" | "review-posture" | "synthetic-layout-cell" | "unmodeled-target";
|
|
2213
|
+
type EditableTargetBlocker = "protected-section" | "protected-range" | "locked-content-control" | "preserve-only" | "opaque-content" | "field-generated-text" | "review-posture" | "synthetic-layout-cell" | "unmodeled-target" | "list-text-readback-missing" | "list-structure-command-missing" | "list-target-stale" | "list-secondary-story-unsupported" | "list-table-target-missing" | "list-export-persistence-missing" | "numbering-format-unsupported" | "picture-bullet-preserve-only" | "marker-geometry-unavailable";
|
|
2202
2214
|
interface EditableTargetPosture {
|
|
2203
2215
|
readonly blockers: readonly EditableTargetBlocker[];
|
|
2204
2216
|
readonly protected?: boolean;
|
|
@@ -2402,10 +2414,54 @@ interface EditableTargetRef {
|
|
|
2402
2414
|
readonly table?: EditableTargetTableIdentity;
|
|
2403
2415
|
readonly editableOwner?: EditableTargetOwnerIdentity;
|
|
2404
2416
|
readonly canonicalAddress?: EditableTargetCanonicalAddress;
|
|
2417
|
+
/**
|
|
2418
|
+
* List-specific address for numbered/bulleted paragraph text. Table-cell
|
|
2419
|
+
* list items keep their primary `canonicalAddress` as the table text target
|
|
2420
|
+
* for existing table commands; this additive address lets list consumers use
|
|
2421
|
+
* the same paragraph without narrowing it to table-only authority.
|
|
2422
|
+
*/
|
|
2423
|
+
readonly listAddress?: EditableTargetCanonicalAddress;
|
|
2405
2424
|
readonly staleCheck: EditableTargetStaleCheck;
|
|
2406
2425
|
readonly posture: EditableTargetPosture;
|
|
2407
2426
|
}
|
|
2408
2427
|
type CanonicalAnchorObjectKind = "legacy-image" | "picture" | "shape" | "textbox" | "chart" | "smartart" | "opaque";
|
|
2428
|
+
/**
|
|
2429
|
+
* Per-block cache for {@link collectEditableTargetRefs}.
|
|
2430
|
+
*
|
|
2431
|
+
* Each cache entry holds the editable targets produced for one canonical
|
|
2432
|
+
* block (paragraph, table, sdt, etc.) under a specific collection context.
|
|
2433
|
+
* Cache hits short-circuit the per-block walk on subsequent calls when the
|
|
2434
|
+
* block reference is unchanged AND the surrounding context (story key,
|
|
2435
|
+
* blockPath position, table identity, content-control posture) is
|
|
2436
|
+
* identical.
|
|
2437
|
+
*
|
|
2438
|
+
* The intended consumer is the document runtime: instantiate one cache per
|
|
2439
|
+
* runtime instance and reuse it across `getCachedSurface` calls so the
|
|
2440
|
+
* editable-target walk does not run on every keystroke. Block references
|
|
2441
|
+
* are preserved across text-only edits for unchanged paragraphs/tables, so
|
|
2442
|
+
* the cache hit-rate approaches 100 % minus the directly edited block.
|
|
2443
|
+
*
|
|
2444
|
+
* The cache is safe across both text-only and structural edits:
|
|
2445
|
+
* - Text-only edits replace the affected block's reference, naturally
|
|
2446
|
+
* missing the cache for that block while leaving siblings cached.
|
|
2447
|
+
* - Structural edits (paragraph splits, table merges) replace blocks
|
|
2448
|
+
* and shift `blockPath` indices; the entry's recorded `blockPath` is
|
|
2449
|
+
* compared against the live walk's `blockPath` so a stale entry whose
|
|
2450
|
+
* block survived but moved is rejected and recomputed.
|
|
2451
|
+
*
|
|
2452
|
+
* The cache uses {@link WeakMap} so dropped block references are
|
|
2453
|
+
* collected automatically; callers do not need to invalidate entries
|
|
2454
|
+
* manually.
|
|
2455
|
+
*/
|
|
2456
|
+
interface EditableTargetBlockCache {
|
|
2457
|
+
get(block: BlockNode): EditableTargetBlockCacheEntry | undefined;
|
|
2458
|
+
set(block: BlockNode, entry: EditableTargetBlockCacheEntry): void;
|
|
2459
|
+
}
|
|
2460
|
+
interface EditableTargetBlockCacheEntry {
|
|
2461
|
+
readonly blockPath: string;
|
|
2462
|
+
readonly signature: string;
|
|
2463
|
+
readonly targets: readonly EditableTargetRef[];
|
|
2464
|
+
}
|
|
2409
2465
|
|
|
2410
2466
|
/**
|
|
2411
2467
|
* Layer 02 · runtime page-graph types.
|
|
@@ -4341,6 +4397,12 @@ interface GeometryHitTarget {
|
|
|
4341
4397
|
lineIndex: number;
|
|
4342
4398
|
rect: GeometryRect$1;
|
|
4343
4399
|
precision: GeometryPrecision;
|
|
4400
|
+
generatedContentKind?: "numbering-marker";
|
|
4401
|
+
generatedContentBoundary?: {
|
|
4402
|
+
policy: "snap-to-authored-text";
|
|
4403
|
+
authoredTextStartsAtPx?: number;
|
|
4404
|
+
selectionPolicy: "exclude-generated-marker";
|
|
4405
|
+
};
|
|
4344
4406
|
}
|
|
4345
4407
|
type SemanticDisplayEntryKind = "text-line" | "editable-target" | "field-region" | "page-local-field-ledger" | "numbering-marker" | "table-frame" | "table-row" | "table-column" | "table-cell" | "toc-leader" | "toc-page-label" | "field-result" | "inline-object" | "floating-object" | "placeholder" | "background" | "border" | "debug-classification";
|
|
4346
4408
|
interface GeometryTableRowRange {
|
|
@@ -4374,6 +4436,20 @@ interface GeometryProjectionWarning {
|
|
|
4374
4436
|
message: string;
|
|
4375
4437
|
}
|
|
4376
4438
|
type GeometryEditableTargetUnavailableReason = "editable-target-block-geometry-missing" | "editable-target-table-geometry-missing" | "editable-target-command-geometry-missing" | "editable-target-page-geometry-unavailable";
|
|
4439
|
+
type GeometryNumberingUnavailableReason = "canonical-numbering-input-missing" | "numbering-marker-lane-unavailable" | "numbering-text-column-unavailable";
|
|
4440
|
+
interface GeometryNumberingFormatPosture {
|
|
4441
|
+
status: "approximated";
|
|
4442
|
+
requestedFormat: string;
|
|
4443
|
+
renderedFormat: "decimal";
|
|
4444
|
+
reason: "unsupported-numbering-format-decimal-fallback" | "numbering-format-range-decimal-fallback";
|
|
4445
|
+
}
|
|
4446
|
+
interface GeometryNumberingMarkerBoundary {
|
|
4447
|
+
generatedContent: "numbering-marker";
|
|
4448
|
+
caretPolicy: "snap-to-authored-text";
|
|
4449
|
+
selectionPolicy: "exclude-marker-unless-list-item-action";
|
|
4450
|
+
coordinateSpace: "frame-px";
|
|
4451
|
+
authoredTextStartsAtPx?: number;
|
|
4452
|
+
}
|
|
4377
4453
|
interface SemanticDisplayEntry {
|
|
4378
4454
|
entryId: string;
|
|
4379
4455
|
kind: SemanticDisplayEntryKind;
|
|
@@ -4417,6 +4493,21 @@ interface SemanticDisplayEntry {
|
|
|
4417
4493
|
editableTargetOwnerReason?: string;
|
|
4418
4494
|
editableTargetOwnerCanonicalAddress?: EditableTargetOwnerAddressRouting;
|
|
4419
4495
|
editableTargetUnavailableReason?: GeometryEditableTargetUnavailableReason;
|
|
4496
|
+
numberingLayoutId?: string;
|
|
4497
|
+
numberingKey?: string;
|
|
4498
|
+
numberingTargetKey?: string;
|
|
4499
|
+
numberingTargetKind?: string;
|
|
4500
|
+
numberingCanonicalAddressKey?: string;
|
|
4501
|
+
numberingListAddressKey?: string;
|
|
4502
|
+
numberingMarkerText?: string;
|
|
4503
|
+
numberingMarkerSuffix?: "tab" | "space" | "nothing";
|
|
4504
|
+
numberingFormat?: string;
|
|
4505
|
+
numberingFormatPosture?: GeometryNumberingFormatPosture;
|
|
4506
|
+
numberingUnavailableReasons?: readonly GeometryNumberingUnavailableReason[];
|
|
4507
|
+
markerGlyphRect?: GeometryRect$1;
|
|
4508
|
+
markerLaneRect?: GeometryRect$1;
|
|
4509
|
+
textColumnRect?: GeometryRect$1;
|
|
4510
|
+
markerBoundary?: GeometryNumberingMarkerBoundary;
|
|
4420
4511
|
rect: GeometryRect$1;
|
|
4421
4512
|
status: GeometryRehydrationStatus;
|
|
4422
4513
|
precision: GeometryPrecision;
|
|
@@ -4489,6 +4580,9 @@ interface HitTestResult$1 {
|
|
|
4489
4580
|
* available; missing anchor metadata leaves it undefined.
|
|
4490
4581
|
*/
|
|
4491
4582
|
assoc?: "before" | "after";
|
|
4583
|
+
generatedContentKind?: "numbering-marker";
|
|
4584
|
+
generatedContentBoundary?: "snap-to-authored-text";
|
|
4585
|
+
semanticEntryId?: string;
|
|
4492
4586
|
}
|
|
4493
4587
|
type AnchorQueryKind = "runtime-offset" | "block-id" | "fragment-id" | "scope-id" | "comment-id" | "revision-id" | "page-index";
|
|
4494
4588
|
interface AnchorQuery {
|
|
@@ -5737,24 +5831,29 @@ type EditorCommand = {
|
|
|
5737
5831
|
} | {
|
|
5738
5832
|
type: "list.toggle";
|
|
5739
5833
|
kind: "bulleted" | "numbered";
|
|
5740
|
-
paragraphIndexes
|
|
5834
|
+
paragraphIndexes?: readonly number[];
|
|
5835
|
+
editableTargets?: readonly EditableTargetRef[];
|
|
5741
5836
|
origin?: CommandOrigin;
|
|
5742
5837
|
} | {
|
|
5743
5838
|
type: "list.indent";
|
|
5744
|
-
paragraphIndexes
|
|
5839
|
+
paragraphIndexes?: readonly number[];
|
|
5840
|
+
editableTargets?: readonly EditableTargetRef[];
|
|
5745
5841
|
origin?: CommandOrigin;
|
|
5746
5842
|
} | {
|
|
5747
5843
|
type: "list.outdent";
|
|
5748
|
-
paragraphIndexes
|
|
5844
|
+
paragraphIndexes?: readonly number[];
|
|
5845
|
+
editableTargets?: readonly EditableTargetRef[];
|
|
5749
5846
|
origin?: CommandOrigin;
|
|
5750
5847
|
} | {
|
|
5751
5848
|
type: "list.restart-numbering";
|
|
5752
|
-
paragraphIndex
|
|
5849
|
+
paragraphIndex?: number;
|
|
5850
|
+
editableTarget?: EditableTargetRef | null;
|
|
5753
5851
|
startAt?: number;
|
|
5754
5852
|
origin?: CommandOrigin;
|
|
5755
5853
|
} | {
|
|
5756
5854
|
type: "list.continue-numbering";
|
|
5757
|
-
paragraphIndex
|
|
5855
|
+
paragraphIndex?: number;
|
|
5856
|
+
editableTarget?: EditableTargetRef | null;
|
|
5758
5857
|
origin?: CommandOrigin;
|
|
5759
5858
|
} | {
|
|
5760
5859
|
type: "table.apply-structure";
|
|
@@ -5883,6 +5982,8 @@ interface CommandExecutionContext {
|
|
|
5883
5982
|
*/
|
|
5884
5983
|
renderSnapshot?: RuntimeRenderSnapshot;
|
|
5885
5984
|
activeStorySize?: number;
|
|
5985
|
+
activeStoryKey?: string;
|
|
5986
|
+
editableTargetCache?: EditableTargetBlockCache;
|
|
5886
5987
|
textTarget?: TextTransactionTextTarget;
|
|
5887
5988
|
rejectTargetlessTableStructureInsert?: boolean;
|
|
5888
5989
|
}
|
|
@@ -6950,6 +7051,21 @@ interface RuntimeOperationStep {
|
|
|
6950
7051
|
readonly kind: RuntimeOperationStepKind;
|
|
6951
7052
|
/** Human-readable one-line description; used in audit `compiledOperations`. */
|
|
6952
7053
|
readonly summary: string;
|
|
7054
|
+
/**
|
|
7055
|
+
* Optional command-surface target hint. Semantic ranges identify intent, but
|
|
7056
|
+
* text mutation must still resolve against the runtime's current editable
|
|
7057
|
+
* target graph before dispatch so table/SDT/nested structure offsets cannot
|
|
7058
|
+
* masquerade as paragraph text positions.
|
|
7059
|
+
*/
|
|
7060
|
+
readonly editableTargetHint?: {
|
|
7061
|
+
readonly kind: "text-leaf";
|
|
7062
|
+
readonly storyKey: string;
|
|
7063
|
+
readonly blockPath: string;
|
|
7064
|
+
readonly semanticBlockRange: {
|
|
7065
|
+
readonly from: number;
|
|
7066
|
+
readonly to: number;
|
|
7067
|
+
};
|
|
7068
|
+
};
|
|
6953
7069
|
/**
|
|
6954
7070
|
* Document-coordinate range the step operates on. Absent for steps
|
|
6955
7071
|
* that target the scope as a whole.
|
|
@@ -8125,6 +8241,17 @@ interface CreateDocumentRuntimeOptions {
|
|
|
8125
8241
|
* See CLAUDE.md (lane status table) §Phase 2.5 §3.7.
|
|
8126
8242
|
*/
|
|
8127
8243
|
seedLayoutCache?: RuntimePageGraph;
|
|
8244
|
+
/**
|
|
8245
|
+
* Mounted-shell cold-load guard. When provided, only the first editor
|
|
8246
|
+
* surface facet is projected with these realized block ranges. This is a
|
|
8247
|
+
* presentation residency hint, not layout truth: L04 page graph reads must
|
|
8248
|
+
* continue to start from their normal full/lazy layout query state.
|
|
8249
|
+
* Headless callers omit this to preserve full-surface semantics.
|
|
8250
|
+
*/
|
|
8251
|
+
initialSurfaceViewportBlockRanges?: readonly {
|
|
8252
|
+
start: number;
|
|
8253
|
+
end: number;
|
|
8254
|
+
}[];
|
|
8128
8255
|
}
|
|
8129
8256
|
declare function createDocumentRuntime(options: CreateDocumentRuntimeOptions): DocumentRuntime;
|
|
8130
8257
|
/**
|
|
@@ -8596,7 +8723,7 @@ interface RuntimeWordFieldMatrixProvider {
|
|
|
8596
8723
|
* `runtime.collab.*` family graduate its live path when hosts supply it
|
|
8597
8724
|
* and fall back to deterministic mocks when they don't.
|
|
8598
8725
|
*/
|
|
8599
|
-
type RuntimeApiHandle = Pick<DocumentRuntime, "now" | "getSessionState" | "setDocumentMode" | "exportDocx" | "getCompatibilityReport" | "getWarnings" | "getRenderSnapshot" | "getDocumentNavigationSnapshot" | "getCanonicalDocument" | "findAllText" | "replaceText" | "applyFormattingOperation" | "getReviewWorkSnapshot" | "getSuggestionsSnapshot" | "acceptChange" | "rejectChange" | "resolveComment" | "getCommentThreadForChange" | "ensureCommentThreadForChange" | "addReplyToChange" | "queryScopes" | "getWorkflowMarkupSnapshot" | "getInteractionGuardSnapshot" | "getWorkflowOverlay" | "addScope" | "setScopeGuardPolicy" | "getScopeGuardPolicy" | "setWorkflowMetadataEntries" | "getWorkflowMetadataSnapshot" | "getVisibilityPolicy" | "getVisibilityPolicies" | "setVisibilityPolicy" | "clearVisibilityPolicy" | "subscribeVisibilityPolicy" | "getMarkupModePolicy" | "setMarkupModePolicy" | "subscribeMarkupModePolicy" | "getScope" | "getLocationForAnchor" | "compileScopeBundleById" | "compileScopeList" | "compileScopeCardById" | "compileScopeRailSnapshot" | "applyScopeReplacement" | "applyScopeFormatting" | "dispatch" | "debug" | "layout" | "geometry"> & {
|
|
8726
|
+
type RuntimeApiHandle = Pick<DocumentRuntime, "now" | "getSessionState" | "setDocumentMode" | "exportDocx" | "getCompatibilityReport" | "getWarnings" | "getRenderSnapshot" | "getDocumentNavigationSnapshot" | "getCanonicalDocument" | "findAllText" | "replaceText" | "applyActiveStoryTextCommand" | "applyFormattingOperation" | "getReviewWorkSnapshot" | "getSuggestionsSnapshot" | "acceptChange" | "rejectChange" | "resolveComment" | "getCommentThreadForChange" | "ensureCommentThreadForChange" | "addReplyToChange" | "queryScopes" | "getWorkflowMarkupSnapshot" | "getInteractionGuardSnapshot" | "getWorkflowOverlay" | "addScope" | "setScopeGuardPolicy" | "getScopeGuardPolicy" | "setWorkflowMetadataEntries" | "getWorkflowMetadataSnapshot" | "getVisibilityPolicy" | "getVisibilityPolicies" | "setVisibilityPolicy" | "clearVisibilityPolicy" | "subscribeVisibilityPolicy" | "getMarkupModePolicy" | "setMarkupModePolicy" | "subscribeMarkupModePolicy" | "getScope" | "getLocationForAnchor" | "compileScopeBundleById" | "compileScopeList" | "compileScopeCardById" | "compileScopeRailSnapshot" | "applyScopeReplacement" | "applyScopeFormatting" | "dispatch" | "debug" | "layout" | "geometry"> & {
|
|
8600
8727
|
/**
|
|
8601
8728
|
* Optional collab session — hosts that wire Yjs/Awareness pass the
|
|
8602
8729
|
* session here so `api.runtime.collab.getPresence` / `.getPosture`
|
|
@@ -11400,7 +11527,7 @@ type AiActionsTargetInput = {
|
|
|
11400
11527
|
readonly tableTextScopeLimit?: number;
|
|
11401
11528
|
};
|
|
11402
11529
|
interface AiActionsMatch {
|
|
11403
|
-
readonly kind: SemanticScopeKind | "table-text";
|
|
11530
|
+
readonly kind: SemanticScopeKind | "table-text" | "hyperlink-text";
|
|
11404
11531
|
readonly text: string;
|
|
11405
11532
|
readonly excerpt: string;
|
|
11406
11533
|
readonly handle?: ScopeHandle;
|
|
@@ -11439,7 +11566,7 @@ interface DiscoverActionsResult {
|
|
|
11439
11566
|
readonly blockerDetails?: readonly AiActionsBlockerDetail[];
|
|
11440
11567
|
}
|
|
11441
11568
|
interface AiActionsTargetSummary {
|
|
11442
|
-
readonly kind: SemanticScopeKind | "table-text";
|
|
11569
|
+
readonly kind: SemanticScopeKind | "table-text" | "hyperlink-text";
|
|
11443
11570
|
readonly handle?: ScopeHandle;
|
|
11444
11571
|
readonly actionHandle?: string;
|
|
11445
11572
|
readonly readback?: AiTableTextReadback;
|
|
@@ -11458,6 +11585,12 @@ interface RewriteActionsInput {
|
|
|
11458
11585
|
readonly origin?: "ui" | "agent" | "host";
|
|
11459
11586
|
readonly proposalId?: string;
|
|
11460
11587
|
}
|
|
11588
|
+
interface HyperlinkTextEditActionsInput {
|
|
11589
|
+
readonly target: AiActionsExactTargetInput;
|
|
11590
|
+
readonly text: string;
|
|
11591
|
+
readonly actorId?: string;
|
|
11592
|
+
readonly origin?: "ui" | "agent" | "host";
|
|
11593
|
+
}
|
|
11461
11594
|
interface RewriteAllActionsInput extends Omit<RewriteActionsInput, "target"> {
|
|
11462
11595
|
readonly query: string;
|
|
11463
11596
|
readonly kind?: SemanticScopeKind;
|
|
@@ -11648,6 +11781,12 @@ type RunPlanActionsStep = (RunPlanStepBase & {
|
|
|
11648
11781
|
readonly href: string;
|
|
11649
11782
|
readonly actorId?: string;
|
|
11650
11783
|
readonly origin?: "ui" | "agent" | "host";
|
|
11784
|
+
}) | (RunPlanStepBase & {
|
|
11785
|
+
readonly kind: "hyperlinkTextEdit";
|
|
11786
|
+
readonly target: AiActionsExactTargetInput;
|
|
11787
|
+
readonly text: string;
|
|
11788
|
+
readonly actorId?: string;
|
|
11789
|
+
readonly origin?: "ui" | "agent" | "host";
|
|
11651
11790
|
}) | (RunPlanStepBase & {
|
|
11652
11791
|
readonly kind: "listOperation";
|
|
11653
11792
|
readonly target: AiActionsExactTargetInput;
|
|
@@ -11703,7 +11842,7 @@ interface ApplyActionsResult {
|
|
|
11703
11842
|
readonly results?: readonly ApplyActionsResult[];
|
|
11704
11843
|
}
|
|
11705
11844
|
interface AiActionsCommandReference {
|
|
11706
|
-
readonly command: NonNullable<ApplyTableActionResult["commandReference"]>["command"] | "field.refresh" | "toc.refresh" | "bookmark.edit-content" | "hyperlink.update-destination" | "list.toggle" | "list.indent" | "list.outdent" | "list.restart-numbering" | "list.continue-numbering";
|
|
11845
|
+
readonly command: NonNullable<ApplyTableActionResult["commandReference"]>["command"] | "field.refresh" | "toc.refresh" | "bookmark.edit-content" | "hyperlink.update-destination" | "text.insert" | "list.toggle" | "list.indent" | "list.outdent" | "list.restart-numbering" | "list.continue-numbering";
|
|
11707
11846
|
readonly actorId: string;
|
|
11708
11847
|
readonly origin: "ui" | "agent" | "host";
|
|
11709
11848
|
readonly emittedAtUtc: string;
|
|
@@ -11765,6 +11904,7 @@ declare function createActionsFamily(runtime: RuntimeApiHandle): {
|
|
|
11765
11904
|
tocRefresh(input: TocRefreshActionsInput): ApplyActionsResult;
|
|
11766
11905
|
bookmarkEdit(input: BookmarkEditActionsInput): ApplyActionsResult;
|
|
11767
11906
|
hyperlinkDestinationEdit(input: HyperlinkDestinationEditActionsInput): ApplyActionsResult;
|
|
11907
|
+
hyperlinkTextEdit(input: HyperlinkTextEditActionsInput): ApplyActionsResult;
|
|
11768
11908
|
listOperation(input: ListOperationActionsInput): ApplyActionsResult;
|
|
11769
11909
|
tableFragment(input: TableFragmentActionsInput): ApplyActionsResult;
|
|
11770
11910
|
tableSelection(input: TableSelectionActionsInput): ApplyActionsResult;
|
|
@@ -14155,6 +14295,12 @@ interface ResolvedNumberingGeometrySnapshot {
|
|
|
14155
14295
|
interface ResolvedNumberingSnapshot {
|
|
14156
14296
|
level: number;
|
|
14157
14297
|
format: string;
|
|
14298
|
+
formatPosture?: {
|
|
14299
|
+
status: "approximated";
|
|
14300
|
+
requestedFormat: string;
|
|
14301
|
+
renderedFormat: "decimal";
|
|
14302
|
+
reason: "unsupported-numbering-format-decimal-fallback" | "numbering-format-range-decimal-fallback";
|
|
14303
|
+
};
|
|
14158
14304
|
text?: string;
|
|
14159
14305
|
startAt: number;
|
|
14160
14306
|
paragraphStyleId?: string;
|