superdoc 2.28.0-next.1 → 2.28.0-next.10
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/chunks/{create-super-doc-ui-D1eOhAjv.cjs → create-super-doc-ui-B4c55pFy.cjs} +420 -84
- package/dist/chunks/{create-super-doc-ui-B29zw5qD.es.js → create-super-doc-ui-C4Ka5Ph3.es.js} +415 -85
- package/dist/collaboration-upgrade-engine.cjs +1 -1
- package/dist/collaboration-upgrade-engine.es.js +1 -1
- package/dist/document-api/src/content-controls/content-controls.types.d.ts +11 -0
- package/dist/document-api/src/contract/command-catalog.d.ts +1 -1
- package/dist/document-api/src/contract/operation-definitions.d.ts +44 -44
- package/dist/document-api/src/contract/operation-registry.d.ts +4 -0
- package/dist/document-api/src/export/export.d.ts +3 -1
- package/dist/document-api/src/export/export.types.d.ts +8 -0
- package/dist/document-api/src/get-node/get-node.d.ts +10 -4
- package/dist/document-api/src/hyperlinks/hyperlinks.types.d.ts +2 -0
- package/dist/document-api/src/index.d.ts +2 -1
- package/dist/document-api/src/replace/replace.d.ts +4 -1
- package/dist/document-api/src/types/mutation-plan.types.d.ts +2 -0
- package/dist/document-api/src/types/track-changes.types.d.ts +10 -2
- package/dist/layout-engine/contracts/src/index.d.ts +2 -0
- package/dist/layout-engine/contracts/src/resolved-layout.d.ts +1 -0
- package/dist/public/ui-react.cjs +1 -1
- package/dist/public/ui-react.es.js +1 -1
- package/dist/public/ui-vue.cjs +1 -1
- package/dist/public/ui-vue.es.js +1 -1
- package/dist/public/ui.cjs +1 -1
- package/dist/public/ui.es.js +1 -1
- package/dist/shared/common/list-marker-utils.d.ts +3 -0
- package/dist/style.css +1 -1
- package/dist/style.layered.css +1 -1
- package/dist/superdoc/src/core/SuperDoc.d.ts +2 -6
- package/dist/superdoc/src/core/collaboration/resolve-v2-collaboration-target.d.ts +2 -0
- package/dist/superdoc/src/core/config/normalize-ui-config.d.ts +1 -0
- package/dist/superdoc/src/core/editor-runtime/types.d.ts +1 -0
- package/dist/superdoc/src/core/editor-runtime/v2/v2-editor-runtime-adapter.d.ts +2 -2
- package/dist/superdoc/src/core/extensions/types.d.ts +14 -3
- package/dist/superdoc/src/core/helpers/resolve-docx-export.d.ts +6 -0
- package/dist/superdoc/src/core/types/index.d.ts +35 -1
- package/dist/superdoc/src/core/v2-integration/v2-integration.d.ts +0 -8
- package/dist/superdoc/src/internal/toolbar/built-in/color-dropdown-helpers.d.ts +0 -1
- package/dist/superdoc/src/internal/toolbar/built-in/constants.d.ts +0 -2
- package/dist/superdoc/src/public/export-types.d.ts +3 -0
- package/dist/superdoc/src/public/ui/entity-at.d.ts +1 -0
- package/dist/superdoc/src/public/ui/format-painter-helpers.d.ts +0 -13
- package/dist/superdoc/src/public/ui/types.d.ts +16 -2
- package/dist/superdoc/src/public/ui.d.cts +14 -0
- package/dist/superdoc/src/public/ui.d.ts +1 -1
- package/dist/superdoc/src/stores/comments-store.d.ts +3 -57
- package/dist/superdoc/src/stores/superdoc-store.d.ts +9 -171
- package/dist/superdoc.cjs +363 -159
- package/dist/superdoc.es.js +363 -159
- package/dist/word-layout/src/types.d.ts +1 -0
- package/dist-cdn/style.layered.css +1 -1
- package/dist-cdn/superdoc.min.css +1 -1
- package/dist-cdn/superdoc.min.js +42 -42
- package/package.json +2 -2
- package/dist/footnote-table-order.docx +0 -0
- package/dist/images/altText_add.svg +0 -3
- package/dist/images/altText_disclaimer.svg +0 -3
- package/dist/images/altText_done.svg +0 -3
- package/dist/images/altText_spinner.svg +0 -30
- package/dist/images/altText_warning.svg +0 -3
- package/dist/images/annotation-check.svg +0 -11
- package/dist/images/annotation-comment.svg +0 -16
- package/dist/images/annotation-help.svg +0 -26
- package/dist/images/annotation-insert.svg +0 -10
- package/dist/images/annotation-key.svg +0 -11
- package/dist/images/annotation-newparagraph.svg +0 -11
- package/dist/images/annotation-noicon.svg +0 -7
- package/dist/images/annotation-note.svg +0 -42
- package/dist/images/annotation-paperclip.svg +0 -6
- package/dist/images/annotation-paragraph.svg +0 -16
- package/dist/images/annotation-pushpin.svg +0 -7
- package/dist/images/checkmark.svg +0 -5
- package/dist/images/comment-actionsButton.svg +0 -3
- package/dist/images/comment-closeButton.svg +0 -3
- package/dist/images/comment-editButton.svg +0 -8
- package/dist/images/comment-popup-editButton.svg +0 -5
- package/dist/images/cursor-editorFreeHighlight.svg +0 -6
- package/dist/images/cursor-editorFreeText.svg +0 -3
- package/dist/images/cursor-editorInk.svg +0 -4
- package/dist/images/cursor-editorTextHighlight.svg +0 -8
- package/dist/images/editor-toolbar-delete.svg +0 -5
- package/dist/images/editor-toolbar-edit.svg +0 -3
- package/dist/images/findbarButton-next.svg +0 -3
- package/dist/images/findbarButton-previous.svg +0 -3
- package/dist/images/gv-toolbarButton-download.svg +0 -3
- package/dist/images/loading-icon.gif +0 -0
- package/dist/images/loading.svg +0 -1
- package/dist/images/messageBar_closingButton.svg +0 -3
- package/dist/images/messageBar_info.svg +0 -3
- package/dist/images/messageBar_warning.svg +0 -3
- package/dist/images/pages_closeButton.svg +0 -3
- package/dist/images/pages_selected.svg +0 -7
- package/dist/images/pages_viewArrow.svg +0 -3
- package/dist/images/pages_viewButton.svg +0 -3
- package/dist/images/secondaryToolbarButton-documentProperties.svg +0 -3
- package/dist/images/secondaryToolbarButton-firstPage.svg +0 -3
- package/dist/images/secondaryToolbarButton-handTool.svg +0 -3
- package/dist/images/secondaryToolbarButton-lastPage.svg +0 -3
- package/dist/images/secondaryToolbarButton-rotateCcw.svg +0 -3
- package/dist/images/secondaryToolbarButton-rotateCw.svg +0 -3
- package/dist/images/secondaryToolbarButton-scrollHorizontal.svg +0 -3
- package/dist/images/secondaryToolbarButton-scrollPage.svg +0 -3
- package/dist/images/secondaryToolbarButton-scrollVertical.svg +0 -3
- package/dist/images/secondaryToolbarButton-scrollWrapped.svg +0 -3
- package/dist/images/secondaryToolbarButton-selectTool.svg +0 -3
- package/dist/images/secondaryToolbarButton-spreadEven.svg +0 -3
- package/dist/images/secondaryToolbarButton-spreadNone.svg +0 -3
- package/dist/images/secondaryToolbarButton-spreadOdd.svg +0 -3
- package/dist/images/toolbarButton-bookmark.svg +0 -3
- package/dist/images/toolbarButton-currentOutlineItem.svg +0 -3
- package/dist/images/toolbarButton-download.svg +0 -4
- package/dist/images/toolbarButton-editorFreeText.svg +0 -5
- package/dist/images/toolbarButton-editorHighlight.svg +0 -6
- package/dist/images/toolbarButton-editorInk.svg +0 -4
- package/dist/images/toolbarButton-editorSignature.svg +0 -6
- package/dist/images/toolbarButton-editorStamp.svg +0 -8
- package/dist/images/toolbarButton-menuArrow.svg +0 -3
- package/dist/images/toolbarButton-openFile.svg +0 -3
- package/dist/images/toolbarButton-pageDown.svg +0 -3
- package/dist/images/toolbarButton-pageUp.svg +0 -3
- package/dist/images/toolbarButton-presentationMode.svg +0 -3
- package/dist/images/toolbarButton-print.svg +0 -3
- package/dist/images/toolbarButton-search.svg +0 -3
- package/dist/images/toolbarButton-secondaryToolbarToggle.svg +0 -3
- package/dist/images/toolbarButton-viewAttachments.svg +0 -3
- package/dist/images/toolbarButton-viewLayers.svg +0 -3
- package/dist/images/toolbarButton-viewOutline.svg +0 -3
- package/dist/images/toolbarButton-viewThumbnail.svg +0 -3
- package/dist/images/toolbarButton-viewsManagerToggle.svg +0 -3
- package/dist/images/toolbarButton-zoomIn.svg +0 -3
- package/dist/images/toolbarButton-zoomOut.svg +0 -3
- package/dist/images/treeitem-collapsed.svg +0 -1
- package/dist/images/treeitem-expanded.svg +0 -1
- package/dist/superdoc/src/helpers/floor.d.ts +0 -1
- package/dist/superdoc/src/index.d.cts +0 -18
- package/dist/superdoc/src/index.d.ts +0 -14
- package/dist-cdn/footnote-table-order.docx +0 -0
|
@@ -19,7 +19,7 @@ var COLLABORATION_UPGRADE_ENGINE_MINIMUM_NODE_MAJOR = 20;
|
|
|
19
19
|
var PRIVATE_ENGINE_INFO = (0, _superdoc_docx_engine_collaboration_upgrade_engine.getCollaborationUpgradeEngineInfo)();
|
|
20
20
|
var ENGINE_INFO = Object.freeze({
|
|
21
21
|
...PRIVATE_ENGINE_INFO,
|
|
22
|
-
superdocVersion: "2.28.0-next.
|
|
22
|
+
superdocVersion: "2.28.0-next.10",
|
|
23
23
|
roomSchemaVersion: Object.freeze({ ...PRIVATE_ENGINE_INFO.roomSchemaVersion }),
|
|
24
24
|
supportedBundleVersions: SUPPORTED_COLLABORATION_UPGRADE_BUNDLE_VERSIONS,
|
|
25
25
|
supportedV1ReaderContractVersions: SUPPORTED_V1_READER_CONTRACT_VERSIONS
|
|
@@ -18,7 +18,7 @@ var COLLABORATION_UPGRADE_ENGINE_MINIMUM_NODE_MAJOR = 20;
|
|
|
18
18
|
var PRIVATE_ENGINE_INFO = getCollaborationUpgradeEngineInfo$1();
|
|
19
19
|
var ENGINE_INFO = Object.freeze({
|
|
20
20
|
...PRIVATE_ENGINE_INFO,
|
|
21
|
-
superdocVersion: "2.28.0-next.
|
|
21
|
+
superdocVersion: "2.28.0-next.10",
|
|
22
22
|
roomSchemaVersion: Object.freeze({ ...PRIVATE_ENGINE_INFO.roomSchemaVersion }),
|
|
23
23
|
supportedBundleVersions: SUPPORTED_COLLABORATION_UPGRADE_BUNDLE_VERSIONS,
|
|
24
24
|
supportedV1ReaderContractVersions: SUPPORTED_V1_READER_CONTRACT_VERSIONS
|
|
@@ -3,6 +3,8 @@ import { SelectionTarget } from '../types/address.js';
|
|
|
3
3
|
import { SDFragment } from '../types/fragment.js';
|
|
4
4
|
import { ReceiptFailure, ReceiptInsert, ReceiptSuccess } from '../types/receipt.js';
|
|
5
5
|
import { StoryLocator } from '../types/story.types.js';
|
|
6
|
+
import { InlineRunPatch } from '../format/inline-run-patch.js';
|
|
7
|
+
export declare const CONTENT_CONTROL_INLINE_FORMAT_KEYS: readonly ["fontFamily", "fontSize", "bold", "italic", "underline", "strike"];
|
|
6
8
|
/**
|
|
7
9
|
* Semantic SDT subtype derived from `w:sdtPr` children.
|
|
8
10
|
*
|
|
@@ -196,9 +198,16 @@ type CreateContentControlPlacement = {
|
|
|
196
198
|
at?: never;
|
|
197
199
|
};
|
|
198
200
|
type CreateContentControlPayload = {
|
|
201
|
+
kind: 'inline';
|
|
202
|
+
content: string;
|
|
203
|
+
inline?: Pick<InlineRunPatch, (typeof CONTENT_CONTROL_INLINE_FORMAT_KEYS)[number]>;
|
|
204
|
+
html?: never;
|
|
205
|
+
json?: never;
|
|
206
|
+
} | {
|
|
199
207
|
kind: NodeKind;
|
|
200
208
|
/** Plain-text initial content. */
|
|
201
209
|
content?: string;
|
|
210
|
+
inline?: never;
|
|
202
211
|
html?: never;
|
|
203
212
|
json?: never;
|
|
204
213
|
} | {
|
|
@@ -207,12 +216,14 @@ type CreateContentControlPayload = {
|
|
|
207
216
|
/** Initial block content authored from HTML. */
|
|
208
217
|
html: string;
|
|
209
218
|
json?: never;
|
|
219
|
+
inline?: never;
|
|
210
220
|
} | {
|
|
211
221
|
kind: Extract<NodeKind, 'block'>;
|
|
212
222
|
content?: never;
|
|
213
223
|
html?: never;
|
|
214
224
|
/** Initial block content authored from an SDFragment-compatible value. */
|
|
215
225
|
json: SDFragment | Record<string, unknown> | Array<Record<string, unknown>>;
|
|
226
|
+
inline?: never;
|
|
216
227
|
};
|
|
217
228
|
export type CreateContentControlInput = CreateContentControlCommonInput & CreateContentControlPlacement & CreateContentControlPayload;
|
|
218
229
|
export interface ContentControlsListQuery extends ContentControlsPaginationOptions {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CommandCatalog, CommandStaticMetadata, OperationId } from './types.js';
|
|
2
2
|
export declare const COMMAND_CATALOG: CommandCatalog;
|
|
3
3
|
/** Operation IDs whose catalog entry has `mutates: true`. */
|
|
4
|
-
export declare const MUTATING_OPERATION_IDS: ("replace" | "find" | "delete" | "insert" | "info" | "selection.extractOoxml" | "selection.current" | "selection.releaseSnapshot" | "format.readSelection" | "projectHtml" | "projectMarkdown" | "capabilities.check" | "format.apply" | "comments.patch" | "trackChanges.decide" | "styles.getCatalog" | "blocks.delete" | "comments.create" | "blocks.split" | "blocks.merge" | "blocks.move" | "lists.getState" | "lists.apply" | "lists.continue" | "lists.restart" | "lists.remove" | "format.paragraph.setMarkRunProps" | "tables.moveRow" | "tables.moveColumn" | "format.bold" | "format.strike" | "format.color" | "format.position" | "format.cs" | "format.shading" | "format.rtl" | "format.fontFamily" | "format.lang" | "format.fontSize" | "format.fontSizeCs" | "format.highlight" | "format.italic" | "format.underline" | "format.caps" | "format.smallCaps" | "format.outline" | "format.shadow" | "format.emboss" | "format.imprint" | "format.vanish" | "format.webHidden" | "format.specVanish" | "format.border" | "format.fitText" | "format.dstrike" | "format.vertAlign" | "format.bCs" | "format.iCs" | "format.snapToGrid" | "format.oMath" | "format.letterSpacing" | "format.charScale" | "format.kerning" | "format.rStyle" | "format.rFonts" | "format.eastAsianLayout" | "format.em" | "format.ligatures" | "format.numForm" | "format.numSpacing" | "format.stylisticSets" | "format.contextualAlternates" | "get" | "getNode" | "getNodeById" | "getText" | "getMarkdown" | "getHtml" | "markdownToFragment" | "htmlToFragment" | "extract" | "clearContent" | "formatRange" | "blocks.findText" | "blocks.list" | "blocks.deleteRange" | "styles.apply" | "styles.create" | "styles.getTheme" | "templates.apply" | "create.paragraph" | "create.heading" | "create.sectionBreak" | "sections.list" | "sections.get" | "sections.setBreakType" | "sections.setPageMargins" | "sections.setHeaderFooterMargins" | "sections.setPageSetup" | "sections.setColumns" | "sections.setLineNumbering" | "sections.setPageNumbering" | "sections.setTitlePage" | "sections.setOddEvenHeadersFooters" | "sections.setVerticalAlign" | "sections.setSectionDirection" | "sections.setHeaderFooterRef" | "sections.clearHeaderFooterRef" | "sections.setLinkToPrevious" | "sections.setPageBorders" | "sections.clearPageBorders" | "styles.paragraph.setStyle" | "styles.paragraph.setStyleRef" | "styles.paragraph.clearStyle" | "format.paragraph.resetDirectFormatting" | "format.paragraph.setAlignment" | "format.paragraph.clearAlignment" | "format.paragraph.setIndentation" | "format.paragraph.clearIndentation" | "format.paragraph.setSpacing" | "format.paragraph.clearSpacing" | "format.paragraph.setKeepOptions" | "format.paragraph.setOutlineLevel" | "format.paragraph.setFlowOptions" | "format.paragraph.setTabStop" | "format.paragraph.clearTabStop" | "format.paragraph.clearAllTabStops" | "format.paragraph.setBorder" | "format.paragraph.clearBorder" | "format.paragraph.setShading" | "format.paragraph.clearShading" | "format.paragraph.setDirection" | "format.paragraph.clearDirection" | "format.paragraph.setNumbering" | "lists.list" | "lists.get" | "lists.insert" | "lists.create" | "lists.attach" | "lists.detach" | "lists.delete" | "lists.indent" | "lists.outdent" | "lists.join" | "lists.canJoin" | "lists.separate" | "lists.merge" | "lists.split" | "lists.setLevel" | "lists.setValue" | "lists.continuePrevious" | "lists.canContinuePrevious" | "lists.setLevelRestart" | "lists.convertToText" | "lists.applyTemplate" | "lists.applyPreset" | "lists.setType" | "lists.captureTemplate" | "lists.setLevelNumbering" | "lists.setLevelBullet" | "lists.setLevelPictureBullet" | "lists.setLevelAlignment" | "lists.setLevelIndents" | "lists.setLevelTrailingCharacter" | "lists.setLevelMarkerFont" | "lists.clearLevelOverrides" | "lists.getStyle" | "lists.applyStyle" | "lists.restartAt" | "lists.setLevelNumberStyle" | "lists.setLevelText" | "lists.setLevelStart" | "lists.setLevelLayout" | "comments.delete" | "comments.get" | "comments.list" | "trackChanges.list" | "trackChanges.get" | "query.match" | "ranges.resolve" | "mutations.beginTemporary" | "mutations.replaceTemporary" | "mutations.rollbackTemporary" | "mutations.commitTemporary" | "mutations.preview" | "mutations.apply" | "plan.execute" | "capabilities.get" | "capabilities.resolve" | "create.table" | "tables.convertFromText" | "tables.delete" | "tables.clearContents" | "tables.move" | "tables.split" | "tables.convertToText" | "tables.setLayout" | "tables.insertRow" | "tables.deleteRow" | "tables.setRowHeight" | "tables.distributeRows" | "tables.setRowOptions" | "tables.insertColumn" | "tables.deleteColumn" | "tables.setColumnWidth" | "tables.distributeColumns" | "tables.insertCell" | "tables.deleteCell" | "tables.mergeCells" | "tables.unmergeCells" | "tables.splitCell" | "tables.setCellProperties" | "tables.setCellText" | "tables.sort" | "tables.setAltText" | "tables.setStyle" | "tables.clearStyle" | "tables.setStyleOption" | "tables.setBorder" | "tables.clearBorder" | "tables.applyBorderPreset" | "tables.setShading" | "tables.clearShading" | "tables.setTablePadding" | "tables.setCellPadding" | "tables.setCellSpacing" | "tables.clearCellSpacing" | "tables.applyStyle" | "tables.setBorders" | "tables.setTableOptions" | "tables.applyPreset" | "tables.get" | "tables.getCells" | "tables.getProperties" | "tables.getStyles" | "tables.setDefaultStyle" | "tables.clearDefaultStyle" | "create.tableOfContents" | "toc.list" | "toc.get" | "toc.configure" | "toc.update" | "toc.remove" | "toc.markEntry" | "toc.unmarkEntry" | "toc.listEntries" | "toc.getEntry" | "toc.editEntry" | "history.get" | "history.undo" | "history.redo" | "create.image" | "images.list" | "images.get" | "images.delete" | "images.move" | "images.convertToInline" | "images.convertToFloating" | "images.setSize" | "images.setWrapType" | "images.setWrapSide" | "images.setWrapDistances" | "images.setPosition" | "images.setAnchorOptions" | "images.setZOrder" | "images.scale" | "images.setLockAspectRatio" | "images.rotate" | "images.flip" | "images.crop" | "images.resetCrop" | "images.replaceSource" | "images.setAltText" | "images.setDecorative" | "images.setName" | "images.setHyperlink" | "images.insertCaption" | "images.updateCaption" | "images.removeCaption" | "hyperlinks.list" | "hyperlinks.get" | "hyperlinks.wrap" | "hyperlinks.insert" | "hyperlinks.patch" | "hyperlinks.remove" | "headerFooters.list" | "headerFooters.get" | "headerFooters.resolve" | "headerFooters.refs.set" | "headerFooters.refs.clear" | "headerFooters.refs.setLinkedToPrevious" | "headerFooters.parts.list" | "headerFooters.parts.create" | "headerFooters.parts.delete" | "headerFooters.pageNumbers.get" | "headerFooters.pageNumbers.insert" | "headerFooters.pageNumbers.set" | "headerFooters.pageNumbers.remove" | "watermarks.apply" | "watermarks.list" | "watermarks.insert" | "watermarks.replace" | "watermarks.remove" | "create.contentControl" | "contentControls.list" | "contentControls.get" | "contentControls.listInRange" | "contentControls.selectByTag" | "contentControls.selectByTitle" | "contentControls.listChildren" | "contentControls.getParent" | "contentControls.wrap" | "contentControls.unwrap" | "contentControls.delete" | "contentControls.copy" | "contentControls.move" | "contentControls.patch" | "contentControls.setLockMode" | "contentControls.setType" | "contentControls.getContent" | "contentControls.replaceContent" | "contentControls.clearContent" | "contentControls.appendContent" | "contentControls.prependContent" | "contentControls.insertBefore" | "contentControls.insertAfter" | "contentControls.getBinding" | "contentControls.setBinding" | "contentControls.clearBinding" | "contentControls.getRawProperties" | "contentControls.patchRawProperties" | "contentControls.validateWordCompatibility" | "contentControls.normalizeWordCompatibility" | "contentControls.normalizeTagPayload" | "contentControls.text.setMultiline" | "contentControls.text.setValue" | "contentControls.text.clearValue" | "contentControls.date.setValue" | "contentControls.date.clearValue" | "contentControls.date.setDisplayFormat" | "contentControls.date.setDisplayLocale" | "contentControls.date.setStorageFormat" | "contentControls.date.setCalendar" | "contentControls.checkbox.getState" | "contentControls.checkbox.setState" | "contentControls.checkbox.toggle" | "contentControls.checkbox.setSymbolPair" | "contentControls.choiceList.getItems" | "contentControls.choiceList.setItems" | "contentControls.choiceList.setSelected" | "contentControls.repeatingSection.listItems" | "contentControls.repeatingSection.insertItemBefore" | "contentControls.repeatingSection.insertItemAfter" | "contentControls.repeatingSection.cloneItem" | "contentControls.repeatingSection.deleteItem" | "contentControls.repeatingSection.setAllowInsertDelete" | "contentControls.group.wrap" | "contentControls.group.ungroup" | "bookmarks.list" | "bookmarks.get" | "bookmarks.insert" | "bookmarks.rename" | "bookmarks.remove" | "footnotes.list" | "footnotes.get" | "footnotes.insert" | "footnotes.update" | "footnotes.remove" | "footnotes.configure" | "clipboard.parse" | "clipboard.insert" | "clipboard.serializeSelection" | "crossRefs.list" | "crossRefs.get" | "crossRefs.insert" | "crossRefs.rebuild" | "crossRefs.remove" | "index.list" | "index.get" | "index.insert" | "index.configure" | "index.rebuild" | "index.remove" | "index.entries.list" | "index.entries.get" | "index.entries.insert" | "index.entries.update" | "index.entries.remove" | "captions.list" | "captions.get" | "captions.insert" | "captions.update" | "captions.remove" | "captions.configure" | "fields.list" | "fields.get" | "fields.insert" | "fields.rebuild" | "fields.remove" | "citations.list" | "citations.get" | "citations.insert" | "citations.update" | "citations.remove" | "citations.sources.list" | "citations.sources.get" | "citations.sources.insert" | "citations.sources.update" | "citations.sources.remove" | "citations.bibliography.get" | "citations.bibliography.insert" | "citations.bibliography.rebuild" | "citations.bibliography.configure" | "citations.bibliography.remove" | "authorities.list" | "authorities.get" | "authorities.insert" | "authorities.configure" | "authorities.rebuild" | "authorities.remove" | "authorities.entries.list" | "authorities.entries.get" | "authorities.entries.insert" | "authorities.entries.update" | "authorities.entries.remove" | "diff.capture" | "diff.compare" | "diff.apply" | "export.toDocx" | "protection.get" | "protection.setEditingRestriction" | "protection.clearEditingRestriction" | "permissionRanges.list" | "permissionRanges.get" | "permissionRanges.create" | "permissionRanges.remove" | "permissionRanges.updatePrincipal" | "customXml.parts.list" | "customXml.parts.get" | "customXml.parts.create" | "customXml.parts.patch" | "customXml.parts.remove" | "metadata.attach" | "metadata.list" | "metadata.get" | "metadata.update" | "metadata.remove" | "metadata.resolve")[];
|
|
4
|
+
export declare const MUTATING_OPERATION_IDS: ("replace" | "find" | "delete" | "insert" | "info" | "selection.extractOoxml" | "selection.current" | "selection.releaseSnapshot" | "format.readSelection" | "projectHtml" | "projectMarkdown" | "capabilities.check" | "format.apply" | "comments.patch" | "trackChanges.decide" | "styles.getCatalog" | "blocks.delete" | "comments.create" | "blocks.split" | "blocks.merge" | "blocks.move" | "lists.getState" | "lists.apply" | "lists.continue" | "lists.restart" | "lists.remove" | "format.paragraph.setMarkRunProps" | "tables.moveRow" | "tables.moveColumn" | "format.bold" | "format.strike" | "format.color" | "format.position" | "format.cs" | "format.shading" | "format.rtl" | "format.fontFamily" | "format.lang" | "format.fontSize" | "format.fontSizeCs" | "format.highlight" | "format.italic" | "format.underline" | "format.caps" | "format.smallCaps" | "format.outline" | "format.shadow" | "format.emboss" | "format.imprint" | "format.vanish" | "format.webHidden" | "format.specVanish" | "format.border" | "format.dstrike" | "format.vertAlign" | "format.bCs" | "format.iCs" | "format.snapToGrid" | "format.oMath" | "format.letterSpacing" | "format.charScale" | "format.kerning" | "format.fitText" | "format.rStyle" | "format.rFonts" | "format.eastAsianLayout" | "format.em" | "format.ligatures" | "format.numForm" | "format.numSpacing" | "format.stylisticSets" | "format.contextualAlternates" | "get" | "getNode" | "getNodeById" | "getText" | "getMarkdown" | "getHtml" | "markdownToFragment" | "htmlToFragment" | "extract" | "clearContent" | "formatRange" | "blocks.findText" | "blocks.list" | "blocks.deleteRange" | "styles.apply" | "styles.create" | "styles.getTheme" | "templates.apply" | "create.paragraph" | "create.heading" | "create.sectionBreak" | "sections.list" | "sections.get" | "sections.setBreakType" | "sections.setPageMargins" | "sections.setHeaderFooterMargins" | "sections.setPageSetup" | "sections.setColumns" | "sections.setLineNumbering" | "sections.setPageNumbering" | "sections.setTitlePage" | "sections.setOddEvenHeadersFooters" | "sections.setVerticalAlign" | "sections.setSectionDirection" | "sections.setHeaderFooterRef" | "sections.clearHeaderFooterRef" | "sections.setLinkToPrevious" | "sections.setPageBorders" | "sections.clearPageBorders" | "styles.paragraph.setStyle" | "styles.paragraph.setStyleRef" | "styles.paragraph.clearStyle" | "format.paragraph.resetDirectFormatting" | "format.paragraph.setAlignment" | "format.paragraph.clearAlignment" | "format.paragraph.setIndentation" | "format.paragraph.clearIndentation" | "format.paragraph.setSpacing" | "format.paragraph.clearSpacing" | "format.paragraph.setKeepOptions" | "format.paragraph.setOutlineLevel" | "format.paragraph.setFlowOptions" | "format.paragraph.setTabStop" | "format.paragraph.clearTabStop" | "format.paragraph.clearAllTabStops" | "format.paragraph.setBorder" | "format.paragraph.clearBorder" | "format.paragraph.setShading" | "format.paragraph.clearShading" | "format.paragraph.setDirection" | "format.paragraph.clearDirection" | "format.paragraph.setNumbering" | "lists.list" | "lists.get" | "lists.insert" | "lists.create" | "lists.attach" | "lists.detach" | "lists.delete" | "lists.indent" | "lists.outdent" | "lists.join" | "lists.canJoin" | "lists.separate" | "lists.merge" | "lists.split" | "lists.setLevel" | "lists.setValue" | "lists.continuePrevious" | "lists.canContinuePrevious" | "lists.setLevelRestart" | "lists.convertToText" | "lists.applyTemplate" | "lists.applyPreset" | "lists.setType" | "lists.captureTemplate" | "lists.setLevelNumbering" | "lists.setLevelBullet" | "lists.setLevelPictureBullet" | "lists.setLevelAlignment" | "lists.setLevelIndents" | "lists.setLevelTrailingCharacter" | "lists.setLevelMarkerFont" | "lists.clearLevelOverrides" | "lists.getStyle" | "lists.applyStyle" | "lists.restartAt" | "lists.setLevelNumberStyle" | "lists.setLevelText" | "lists.setLevelStart" | "lists.setLevelLayout" | "comments.delete" | "comments.get" | "comments.list" | "trackChanges.list" | "trackChanges.get" | "query.match" | "ranges.resolve" | "mutations.beginTemporary" | "mutations.replaceTemporary" | "mutations.rollbackTemporary" | "mutations.commitTemporary" | "mutations.preview" | "mutations.apply" | "plan.execute" | "capabilities.get" | "capabilities.resolve" | "create.table" | "tables.convertFromText" | "tables.delete" | "tables.clearContents" | "tables.move" | "tables.split" | "tables.convertToText" | "tables.setLayout" | "tables.insertRow" | "tables.deleteRow" | "tables.setRowHeight" | "tables.distributeRows" | "tables.setRowOptions" | "tables.insertColumn" | "tables.deleteColumn" | "tables.setColumnWidth" | "tables.distributeColumns" | "tables.insertCell" | "tables.deleteCell" | "tables.mergeCells" | "tables.unmergeCells" | "tables.splitCell" | "tables.setCellProperties" | "tables.setCellText" | "tables.sort" | "tables.setAltText" | "tables.setStyle" | "tables.clearStyle" | "tables.setStyleOption" | "tables.setBorder" | "tables.clearBorder" | "tables.applyBorderPreset" | "tables.setShading" | "tables.clearShading" | "tables.setTablePadding" | "tables.setCellPadding" | "tables.setCellSpacing" | "tables.clearCellSpacing" | "tables.applyStyle" | "tables.setBorders" | "tables.setTableOptions" | "tables.applyPreset" | "tables.get" | "tables.getCells" | "tables.getProperties" | "tables.getStyles" | "tables.setDefaultStyle" | "tables.clearDefaultStyle" | "create.tableOfContents" | "toc.list" | "toc.get" | "toc.configure" | "toc.update" | "toc.remove" | "toc.markEntry" | "toc.unmarkEntry" | "toc.listEntries" | "toc.getEntry" | "toc.editEntry" | "history.get" | "history.undo" | "history.redo" | "create.image" | "images.list" | "images.get" | "images.delete" | "images.move" | "images.convertToInline" | "images.convertToFloating" | "images.setSize" | "images.setWrapType" | "images.setWrapSide" | "images.setWrapDistances" | "images.setPosition" | "images.setAnchorOptions" | "images.setZOrder" | "images.scale" | "images.setLockAspectRatio" | "images.rotate" | "images.flip" | "images.crop" | "images.resetCrop" | "images.replaceSource" | "images.setAltText" | "images.setDecorative" | "images.setName" | "images.setHyperlink" | "images.insertCaption" | "images.updateCaption" | "images.removeCaption" | "hyperlinks.list" | "hyperlinks.get" | "hyperlinks.wrap" | "hyperlinks.insert" | "hyperlinks.patch" | "hyperlinks.remove" | "headerFooters.list" | "headerFooters.get" | "headerFooters.resolve" | "headerFooters.refs.set" | "headerFooters.refs.clear" | "headerFooters.refs.setLinkedToPrevious" | "headerFooters.parts.list" | "headerFooters.parts.create" | "headerFooters.parts.delete" | "headerFooters.pageNumbers.get" | "headerFooters.pageNumbers.insert" | "headerFooters.pageNumbers.set" | "headerFooters.pageNumbers.remove" | "watermarks.apply" | "watermarks.list" | "watermarks.insert" | "watermarks.replace" | "watermarks.remove" | "create.contentControl" | "contentControls.list" | "contentControls.get" | "contentControls.listInRange" | "contentControls.selectByTag" | "contentControls.selectByTitle" | "contentControls.listChildren" | "contentControls.getParent" | "contentControls.wrap" | "contentControls.unwrap" | "contentControls.delete" | "contentControls.copy" | "contentControls.move" | "contentControls.patch" | "contentControls.setLockMode" | "contentControls.setType" | "contentControls.getContent" | "contentControls.replaceContent" | "contentControls.clearContent" | "contentControls.appendContent" | "contentControls.prependContent" | "contentControls.insertBefore" | "contentControls.insertAfter" | "contentControls.getBinding" | "contentControls.setBinding" | "contentControls.clearBinding" | "contentControls.getRawProperties" | "contentControls.patchRawProperties" | "contentControls.validateWordCompatibility" | "contentControls.normalizeWordCompatibility" | "contentControls.normalizeTagPayload" | "contentControls.text.setMultiline" | "contentControls.text.setValue" | "contentControls.text.clearValue" | "contentControls.date.setValue" | "contentControls.date.clearValue" | "contentControls.date.setDisplayFormat" | "contentControls.date.setDisplayLocale" | "contentControls.date.setStorageFormat" | "contentControls.date.setCalendar" | "contentControls.checkbox.getState" | "contentControls.checkbox.setState" | "contentControls.checkbox.toggle" | "contentControls.checkbox.setSymbolPair" | "contentControls.choiceList.getItems" | "contentControls.choiceList.setItems" | "contentControls.choiceList.setSelected" | "contentControls.repeatingSection.listItems" | "contentControls.repeatingSection.insertItemBefore" | "contentControls.repeatingSection.insertItemAfter" | "contentControls.repeatingSection.cloneItem" | "contentControls.repeatingSection.deleteItem" | "contentControls.repeatingSection.setAllowInsertDelete" | "contentControls.group.wrap" | "contentControls.group.ungroup" | "bookmarks.list" | "bookmarks.get" | "bookmarks.insert" | "bookmarks.rename" | "bookmarks.remove" | "footnotes.list" | "footnotes.get" | "footnotes.insert" | "footnotes.update" | "footnotes.remove" | "footnotes.configure" | "clipboard.parse" | "clipboard.insert" | "clipboard.serializeSelection" | "crossRefs.list" | "crossRefs.get" | "crossRefs.insert" | "crossRefs.rebuild" | "crossRefs.remove" | "index.list" | "index.get" | "index.insert" | "index.configure" | "index.rebuild" | "index.remove" | "index.entries.list" | "index.entries.get" | "index.entries.insert" | "index.entries.update" | "index.entries.remove" | "captions.list" | "captions.get" | "captions.insert" | "captions.update" | "captions.remove" | "captions.configure" | "fields.list" | "fields.get" | "fields.insert" | "fields.rebuild" | "fields.remove" | "citations.list" | "citations.get" | "citations.insert" | "citations.update" | "citations.remove" | "citations.sources.list" | "citations.sources.get" | "citations.sources.insert" | "citations.sources.update" | "citations.sources.remove" | "citations.bibliography.get" | "citations.bibliography.insert" | "citations.bibliography.rebuild" | "citations.bibliography.configure" | "citations.bibliography.remove" | "authorities.list" | "authorities.get" | "authorities.insert" | "authorities.configure" | "authorities.rebuild" | "authorities.remove" | "authorities.entries.list" | "authorities.entries.get" | "authorities.entries.insert" | "authorities.entries.update" | "authorities.entries.remove" | "diff.capture" | "diff.compare" | "diff.apply" | "export.toDocx" | "protection.get" | "protection.setEditingRestriction" | "protection.clearEditingRestriction" | "permissionRanges.list" | "permissionRanges.get" | "permissionRanges.create" | "permissionRanges.remove" | "permissionRanges.updatePrincipal" | "customXml.parts.list" | "customXml.parts.get" | "customXml.parts.create" | "customXml.parts.patch" | "customXml.parts.remove" | "metadata.attach" | "metadata.list" | "metadata.get" | "metadata.update" | "metadata.remove" | "metadata.resolve")[];
|
|
5
5
|
/** Maps each operation to its human-readable description. */
|
|
6
6
|
export declare const OPERATION_DESCRIPTION_MAP: Record<OperationId, string>;
|
|
7
7
|
/** Maps each operation to whether it requires an open document to execute. */
|
|
@@ -473,7 +473,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
473
473
|
};
|
|
474
474
|
readonly 'format.paragraph.setMarkRunProps': {
|
|
475
475
|
readonly memberPath: "format.paragraph.setMarkRunProps";
|
|
476
|
-
readonly description:
|
|
476
|
+
readonly description: "Set the paragraph mark's run properties (w:pPr/w:rPr), e.g. the font size or specVanish carried by the paragraph-end mark.";
|
|
477
477
|
readonly expectedResult: "Returns a ParagraphMutationResult; reports NO_OP if the encoded mark run properties already match.";
|
|
478
478
|
readonly requiresDocumentContext: true;
|
|
479
479
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -744,7 +744,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
744
744
|
};
|
|
745
745
|
readonly 'lists.captureTemplate': {
|
|
746
746
|
readonly memberPath: "lists.captureTemplate";
|
|
747
|
-
readonly description: "
|
|
747
|
+
readonly description: "Capture reusable effective list formatting, including full level overrides and Word defaults, without instance continuation checkpoints (startOverride).";
|
|
748
748
|
readonly expectedResult: "Returns a ListsCaptureTemplateResult containing the captured template.";
|
|
749
749
|
readonly requiresDocumentContext: true;
|
|
750
750
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -834,8 +834,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
834
834
|
};
|
|
835
835
|
readonly 'lists.applyStyle': {
|
|
836
836
|
readonly memberPath: "lists.applyStyle";
|
|
837
|
-
readonly description: "Apply a reusable list style to the target list. Sequence-local:
|
|
838
|
-
readonly expectedResult: "Returns a ListsMutateItemResult receipt
|
|
837
|
+
readonly description: "Apply a reusable list style to the target list. Sequence-local: preserves other sequences and levels. V2 returns CAPABILITY_UNAVAILABLE when existing numbering cannot be preserved.";
|
|
838
|
+
readonly expectedResult: "Returns a ListsMutateItemResult receipt with changed: false and no transaction when all levels already match.";
|
|
839
839
|
readonly requiresDocumentContext: true;
|
|
840
840
|
readonly metadata: CommandStaticMetadata;
|
|
841
841
|
readonly referenceDocPath: "lists/apply-style.mdx";
|
|
@@ -852,8 +852,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
852
852
|
};
|
|
853
853
|
readonly 'lists.setLevelNumberStyle': {
|
|
854
854
|
readonly memberPath: "lists.setLevelNumberStyle";
|
|
855
|
-
readonly description: "Set the numbering style (e.g. decimal, lowerLetter, upperRoman) for a specific list level. Rejects \"bullet\": use setLevelBullet instead. Sequence-local:
|
|
856
|
-
readonly expectedResult: "Returns a ListsMutateItemResult receipt
|
|
855
|
+
readonly description: "Set the numbering style (e.g. decimal, lowerLetter, upperRoman) for a specific list level. Rejects \"bullet\": use setLevelBullet instead. Sequence-local: preserves other sequences and levels. V2 returns CAPABILITY_UNAVAILABLE for numberInDash and inherited, mixed-counter, or nested-restart continuations whose numbering cannot be preserved.";
|
|
856
|
+
readonly expectedResult: "Returns a ListsMutateItemResult receipt with changed: false and no transaction when the effective value already matches.";
|
|
857
857
|
readonly requiresDocumentContext: true;
|
|
858
858
|
readonly metadata: CommandStaticMetadata;
|
|
859
859
|
readonly referenceDocPath: "lists/set-level-number-style.mdx";
|
|
@@ -861,8 +861,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
861
861
|
};
|
|
862
862
|
readonly 'lists.setLevelText': {
|
|
863
863
|
readonly memberPath: "lists.setLevelText";
|
|
864
|
-
readonly description: "Set the level text pattern (e.g. \"%1.\", \"(%1)\") for a specific list level. Uses OOXML level-placeholder syntax. Sequence-local:
|
|
865
|
-
readonly expectedResult: "Returns a ListsMutateItemResult receipt
|
|
864
|
+
readonly description: "Set the level text pattern (e.g. \"%1.\", \"(%1)\") for a specific list level. Uses OOXML level-placeholder syntax. Sequence-local: preserves other sequences and levels. V2 returns CAPABILITY_UNAVAILABLE when existing numbering cannot be preserved.";
|
|
865
|
+
readonly expectedResult: "Returns a ListsMutateItemResult receipt with changed: false and no transaction when the value already matches.";
|
|
866
866
|
readonly requiresDocumentContext: true;
|
|
867
867
|
readonly metadata: CommandStaticMetadata;
|
|
868
868
|
readonly referenceDocPath: "lists/set-level-text.mdx";
|
|
@@ -870,8 +870,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
870
870
|
};
|
|
871
871
|
readonly 'lists.setLevelStart': {
|
|
872
872
|
readonly memberPath: "lists.setLevelStart";
|
|
873
|
-
readonly description: "Set the start value for a specific list level. Rejects bullet levels and non-positive values. Sequence-local:
|
|
874
|
-
readonly expectedResult: "Returns a ListsMutateItemResult receipt
|
|
873
|
+
readonly description: "Set the start value for a specific list level. Rejects bullet levels and non-positive values. Sequence-local: preserves other sequences and levels. V2 returns CAPABILITY_UNAVAILABLE when existing numbering cannot be preserved.";
|
|
874
|
+
readonly expectedResult: "Returns a ListsMutateItemResult receipt with changed: false and no transaction when the value already matches.";
|
|
875
875
|
readonly requiresDocumentContext: true;
|
|
876
876
|
readonly metadata: CommandStaticMetadata;
|
|
877
877
|
readonly referenceDocPath: "lists/set-level-start.mdx";
|
|
@@ -879,8 +879,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
879
879
|
};
|
|
880
880
|
readonly 'lists.setLevelLayout': {
|
|
881
881
|
readonly memberPath: "lists.setLevelLayout";
|
|
882
|
-
readonly description: "Set the layout properties (alignment, indentation, trailing character, tab stop) for a specific list level. Accepts partial updates: omitted fields are left unchanged. Sequence-local:
|
|
883
|
-
readonly expectedResult: "Returns a ListsMutateItemResult receipt
|
|
882
|
+
readonly description: "Set the layout properties (alignment, indentation, trailing character, tab stop) for a specific list level. Accepts partial updates: omitted fields are left unchanged. Sequence-local: preserves other sequences and levels. V2 returns CAPABILITY_UNAVAILABLE when existing numbering cannot be preserved.";
|
|
883
|
+
readonly expectedResult: "Returns a ListsMutateItemResult receipt with changed: false and no transaction when all values already match.";
|
|
884
884
|
readonly requiresDocumentContext: true;
|
|
885
885
|
readonly metadata: CommandStaticMetadata;
|
|
886
886
|
readonly referenceDocPath: "lists/set-level-layout.mdx";
|
|
@@ -888,7 +888,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
888
888
|
};
|
|
889
889
|
readonly 'lists.getState': {
|
|
890
890
|
readonly memberPath: "lists.getState";
|
|
891
|
-
readonly description:
|
|
891
|
+
readonly description: "Read the numbering-aware list state for a paragraph (numId, ilvl, abstract reference, level format). Returns null when the target is not a list item.";
|
|
892
892
|
readonly expectedResult: "Returns a ListsGetStateResult with `isListItem` plus numId/ilvl/abstract/numFmt metadata when present.";
|
|
893
893
|
readonly requiresDocumentContext: true;
|
|
894
894
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -897,7 +897,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
897
897
|
};
|
|
898
898
|
readonly 'lists.apply': {
|
|
899
899
|
readonly memberPath: "lists.apply";
|
|
900
|
-
readonly description:
|
|
900
|
+
readonly description: "Apply a numbering definition to a paragraph. When `/word/numbering.xml` is absent it is materialized atomically together with the package content-type override and document relationship. Seeds bullet or ordered single-level definitions when no `reuseNumId` is provided.";
|
|
901
901
|
readonly expectedResult: "Returns a ListsMutateItemResult receipt with txId; partsChanged includes numbering / content-types / rels when first-list materialization fires.";
|
|
902
902
|
readonly requiresDocumentContext: true;
|
|
903
903
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -906,7 +906,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
906
906
|
};
|
|
907
907
|
readonly 'lists.continue': {
|
|
908
908
|
readonly memberPath: "lists.continue";
|
|
909
|
-
readonly description:
|
|
909
|
+
readonly description: "Continue from the previous compatible list item in the same story. Adopts the previous paragraph's numId+ilvl. Rejects with named reasons when no compatible previous item exists or when an intervening structural boundary blocks the continuation.";
|
|
910
910
|
readonly expectedResult: "Returns a ListsMutateItemResult receipt with txId.";
|
|
911
911
|
readonly requiresDocumentContext: true;
|
|
912
912
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -915,7 +915,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
915
915
|
};
|
|
916
916
|
readonly 'lists.restart': {
|
|
917
917
|
readonly memberPath: "lists.restart";
|
|
918
|
-
readonly description:
|
|
918
|
+
readonly description: "Restart numbering at a list item. Creates a new `<w:num>` that references the existing `<w:abstractNumId>` with a `<w:lvlOverride><w:startOverride/></w:lvlOverride>`. Distant paragraphs sharing the old numId are intentionally untouched.";
|
|
919
919
|
readonly expectedResult: "Returns a ListsMutateItemResult receipt with txId; partsChanged includes /word/numbering.xml.";
|
|
920
920
|
readonly requiresDocumentContext: true;
|
|
921
921
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -924,7 +924,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
924
924
|
};
|
|
925
925
|
readonly 'lists.remove': {
|
|
926
926
|
readonly memberPath: "lists.remove";
|
|
927
|
-
readonly description:
|
|
927
|
+
readonly description: "Strip the `<w:numPr>` from a list-item paragraph. The numbering definition in `/word/numbering.xml` is intentionally NOT modified; orphan cleanup is handled by the export-side stripper.";
|
|
928
928
|
readonly expectedResult: "Returns a ListsMutateItemResult receipt with txId.";
|
|
929
929
|
readonly requiresDocumentContext: true;
|
|
930
930
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -1021,7 +1021,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
1021
1021
|
readonly 'trackChanges.decide': {
|
|
1022
1022
|
readonly memberPath: "trackChanges.decide";
|
|
1023
1023
|
readonly description: "Accept or reject tracked changes by logical id, by several logical ids atomically, by selected text range, by logical anchor range ({ anchor, relativeStart, relativeEnd }), or every active change in the document. Range targets may include overlap / side selectors and may partially resolve a change, splitting surviving content into new fragments with stable ids. Legacy `{ id, range: { kind: \"partial\", ... } }` targets are promoted only when the active adapter supports `decide()`; legacy fallback adapters fail closed with `INVALID_INPUT`. `input.expectedRevision` is accepted as a compatibility alias for mutation options.";
|
|
1024
|
-
readonly expectedResult: "Returns a Receipt. `removed` lists retired tracked-change ids; `inserted` lists successor fragment ids produced by partial range splits; `invalidatedRefs` lists every retired tracked-change ref plus cascade-deleted comment ids; `remappedRefs` carries surviving comment anchors moved by the decision; `affectedStories` lists touched stories; `textRangeShifts` reports per-story visible-text deltas; `txId` correlates with history. Failures: SPAN_FRAGMENTED when a range crosses an indivisible boundary
|
|
1024
|
+
readonly expectedResult: "Returns a Receipt. `removed` lists retired tracked-change ids; `inserted` lists successor fragment ids produced by partial range splits; `invalidatedRefs` lists every retired tracked-change ref plus cascade-deleted comment ids; `remappedRefs` carries surviving comment anchors moved by the decision; `affectedStories` lists touched stories; `textRangeShifts` reports per-story visible-text deltas; `txId` correlates with history. Formatting, structural and paired move changes are decided by id. Failures: SPAN_FRAGMENTED when a range crosses an indivisible boundary; CAPABILITY_UNAVAILABLE for unpaired move sides, ambiguous mirrored text-box revisions by id, mirrored text-box revisions targeted by range or replacement side, textbox-scoped or inherited header/footer bulk decisions, range targets over changes that are not text insertions or deletions, and permissionResolver denials of an id or range target; TARGET_NOT_FOUND for unknown ids or a range with no overlapping text revision (formatting-only changes are not range targets); NO_OP for an id already resolved by an id or bulk decision (an id retired by a range decision returns TARGET_NOT_FOUND); STALE_REVISION for stale expectedRevision; REVISION_MISMATCH for stale range coverage. { kind: 'all' } skips changes permissionResolver denies and succeeds with an empty receipt when nothing is decidable.";
|
|
1025
1025
|
readonly requiresDocumentContext: true;
|
|
1026
1026
|
readonly metadata: CommandStaticMetadata;
|
|
1027
1027
|
readonly referenceDocPath: "track-changes/decide.mdx";
|
|
@@ -1060,7 +1060,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
1060
1060
|
};
|
|
1061
1061
|
readonly 'selection.releaseSnapshot': {
|
|
1062
1062
|
readonly memberPath: "selection.releaseSnapshot";
|
|
1063
|
-
readonly description:
|
|
1063
|
+
readonly description: "Release a retained exact-selection snapshot without changing document content or Undo history.";
|
|
1064
1064
|
readonly expectedResult: "Returns released=true when a same-session handle was removed; otherwise false.";
|
|
1065
1065
|
readonly requiresDocumentContext: true;
|
|
1066
1066
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -1282,7 +1282,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
1282
1282
|
};
|
|
1283
1283
|
readonly 'tables.moveRow': {
|
|
1284
1284
|
readonly memberPath: "tables.moveRow";
|
|
1285
|
-
readonly description:
|
|
1285
|
+
readonly description: "Move a row to a new position within the same table.";
|
|
1286
1286
|
readonly expectedResult: "Returns a TableMutationResult receipt; reports NO_OP if the row is already at the requested position.";
|
|
1287
1287
|
readonly requiresDocumentContext: true;
|
|
1288
1288
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -1346,7 +1346,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
1346
1346
|
};
|
|
1347
1347
|
readonly 'tables.moveColumn': {
|
|
1348
1348
|
readonly memberPath: "tables.moveColumn";
|
|
1349
|
-
readonly description:
|
|
1349
|
+
readonly description: "Move a column to a new position within the same table. Direct mode only; tables with vertical merges, nested tables, or irregular column coverage are rejected, and tracked (suggesting) mode is not supported yet.";
|
|
1350
1350
|
readonly expectedResult: "Returns a TableMutationResult receipt; reports NO_OP if the column is already at the requested position.";
|
|
1351
1351
|
readonly requiresDocumentContext: true;
|
|
1352
1352
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2054,8 +2054,8 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2054
2054
|
};
|
|
2055
2055
|
readonly 'hyperlinks.list': {
|
|
2056
2056
|
readonly memberPath: "hyperlinks.list";
|
|
2057
|
-
readonly description:
|
|
2058
|
-
readonly expectedResult:
|
|
2057
|
+
readonly description: string;
|
|
2058
|
+
readonly expectedResult: string;
|
|
2059
2059
|
readonly requiresDocumentContext: true;
|
|
2060
2060
|
readonly metadata: CommandStaticMetadata;
|
|
2061
2061
|
readonly referenceDocPath: "hyperlinks/list.mdx";
|
|
@@ -2082,7 +2082,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2082
2082
|
readonly 'hyperlinks.insert': {
|
|
2083
2083
|
readonly memberPath: "hyperlinks.insert";
|
|
2084
2084
|
readonly description: "Insert new linked text at a target position.";
|
|
2085
|
-
readonly expectedResult:
|
|
2085
|
+
readonly expectedResult: string;
|
|
2086
2086
|
readonly requiresDocumentContext: true;
|
|
2087
2087
|
readonly metadata: CommandStaticMetadata;
|
|
2088
2088
|
readonly referenceDocPath: "hyperlinks/insert.mdx";
|
|
@@ -2189,7 +2189,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2189
2189
|
};
|
|
2190
2190
|
readonly 'headerFooters.pageNumbers.get': {
|
|
2191
2191
|
readonly memberPath: "headerFooters.pageNumbers.get";
|
|
2192
|
-
readonly description:
|
|
2192
|
+
readonly description: "Read where a section shows page numbers, their alignment, the first-page choice, and the section's number style and start.";
|
|
2193
2193
|
readonly expectedResult: "Returns the header and footer placements that show a PAGE field (empty when none), first-page visibility, the number format, and the start number or null when numbering continues.";
|
|
2194
2194
|
readonly requiresDocumentContext: true;
|
|
2195
2195
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2198,7 +2198,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2198
2198
|
};
|
|
2199
2199
|
readonly 'headerFooters.pageNumbers.insert': {
|
|
2200
2200
|
readonly memberPath: "headerFooters.pageNumbers.insert";
|
|
2201
|
-
readonly description:
|
|
2201
|
+
readonly description: "Atomically number a section's pages with a live PAGE field in its header or footer, with alignment, a first-page choice, and an optional number style and start.";
|
|
2202
2202
|
readonly expectedResult: "Returns the numbered header/footer parts and whether the section uses a distinct first page; PRECONDITION_FAILED with reason page-number-exists when the target already shows a page number.";
|
|
2203
2203
|
readonly requiresDocumentContext: true;
|
|
2204
2204
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2207,7 +2207,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2207
2207
|
};
|
|
2208
2208
|
readonly 'headerFooters.pageNumbers.set': {
|
|
2209
2209
|
readonly memberPath: "headerFooters.pageNumbers.set";
|
|
2210
|
-
readonly description:
|
|
2210
|
+
readonly description: "Atomically add a section's page numbers or change them: move them between header and footer, realign them, show or hide them on the first page, and set the number style and start.";
|
|
2211
2211
|
readonly expectedResult: "Returns the numbered header/footer parts and whether the section uses a distinct first page; PRECONDITION_FAILED with reason page-number-has-content when a moved or hidden number shares its paragraph with other text or fields.";
|
|
2212
2212
|
readonly requiresDocumentContext: true;
|
|
2213
2213
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2216,7 +2216,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2216
2216
|
};
|
|
2217
2217
|
readonly 'headerFooters.pageNumbers.remove': {
|
|
2218
2218
|
readonly memberPath: "headerFooters.pageNumbers.remove";
|
|
2219
|
-
readonly description:
|
|
2219
|
+
readonly description: "Atomically remove a section's PAGE fields from its header, footer, or both, keeping other header and footer content.";
|
|
2220
2220
|
readonly expectedResult: "Returns the header/footer parts that lost a PAGE field; a paragraph left with only whitespace is removed. NO_OP when the section shows no page number.";
|
|
2221
2221
|
readonly requiresDocumentContext: true;
|
|
2222
2222
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2225,7 +2225,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2225
2225
|
};
|
|
2226
2226
|
readonly 'watermarks.apply': {
|
|
2227
2227
|
readonly memberPath: "watermarks.apply";
|
|
2228
|
-
readonly description:
|
|
2228
|
+
readonly description: "Atomically insert, replace, or remove selected watermarks in explicit scopes while preserving surrounding headers.";
|
|
2229
2229
|
readonly expectedResult: "Returns the resulting watermarks, changed header slots, preserved boundaries, and evaluated revision.";
|
|
2230
2230
|
readonly requiresDocumentContext: true;
|
|
2231
2231
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2234,7 +2234,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2234
2234
|
};
|
|
2235
2235
|
readonly 'watermarks.list': {
|
|
2236
2236
|
readonly memberPath: "watermarks.list";
|
|
2237
|
-
readonly description:
|
|
2237
|
+
readonly description: "List Word-compatible text and picture watermarks and their effective header scopes.";
|
|
2238
2238
|
readonly expectedResult: "Returns a paginated WatermarksListResult with stable watermark identities and Word placement settings.";
|
|
2239
2239
|
readonly requiresDocumentContext: true;
|
|
2240
2240
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2243,7 +2243,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2243
2243
|
};
|
|
2244
2244
|
readonly 'watermarks.insert': {
|
|
2245
2245
|
readonly memberPath: "watermarks.insert";
|
|
2246
|
-
readonly description:
|
|
2246
|
+
readonly description: "Insert a Word-compatible text or picture watermark into a header scope.";
|
|
2247
2247
|
readonly expectedResult: "Returns the inserted watermark, including its stable identity and effective header scopes.";
|
|
2248
2248
|
readonly requiresDocumentContext: true;
|
|
2249
2249
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2252,7 +2252,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2252
2252
|
};
|
|
2253
2253
|
readonly 'watermarks.replace': {
|
|
2254
2254
|
readonly memberPath: "watermarks.replace";
|
|
2255
|
-
readonly description:
|
|
2255
|
+
readonly description: "Replace an existing watermark while retaining its stable identity and owner scope.";
|
|
2256
2256
|
readonly expectedResult: "Returns the replaced watermark, or TARGET_NOT_FOUND when its identity is stale.";
|
|
2257
2257
|
readonly requiresDocumentContext: true;
|
|
2258
2258
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2261,7 +2261,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2261
2261
|
};
|
|
2262
2262
|
readonly 'watermarks.remove': {
|
|
2263
2263
|
readonly memberPath: "watermarks.remove";
|
|
2264
|
-
readonly description:
|
|
2264
|
+
readonly description: "Remove a watermark without removing unrelated header content.";
|
|
2265
2265
|
readonly expectedResult: "Returns the removed watermark identity, or TARGET_NOT_FOUND when its identity is stale.";
|
|
2266
2266
|
readonly requiresDocumentContext: true;
|
|
2267
2267
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2270,7 +2270,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2270
2270
|
};
|
|
2271
2271
|
readonly 'create.contentControl': {
|
|
2272
2272
|
readonly memberPath: "create.contentControl";
|
|
2273
|
-
readonly description: "Create a new content control (SDT) in the document, optionally seeded with plain text or structured block preset content.";
|
|
2273
|
+
readonly description: "Create a new content control (SDT) in the document, optionally seeded with plain text or structured block preset content. Inline plain-text creation at a selection inherits the document run formatting at the caret or first selected character when inline is omitted; pending browser caret overrides are excluded. To include pending overrides, capture format.readSelection({ selection: \"current\" }) and pass its uniform values through inline. An explicit inline payload supplies fontFamily, fontSize, bold, italic, underline and strike values instead, with unspecified properties inheriting from the destination paragraph. It requires explicit content and commits formatting, content, tag and lockMode in one undoable operation. If inherited formatting cannot be resolved, creation returns CAPABILITY_UNAVAILABLE without changing the document or history; pass explicit inline values to bypass automatic inheritance.";
|
|
2274
2274
|
readonly expectedResult: "Returns a ContentControlMutationResult with the created content control target.";
|
|
2275
2275
|
readonly requiresDocumentContext: true;
|
|
2276
2276
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2828,7 +2828,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2828
2828
|
};
|
|
2829
2829
|
readonly 'footnotes.insert': {
|
|
2830
2830
|
readonly memberPath: "footnotes.insert";
|
|
2831
|
-
readonly description: "Insert a new footnote or endnote at a target location or the current selection.
|
|
2831
|
+
readonly description: "Insert a new footnote or endnote at a target location or the current selection.";
|
|
2832
2832
|
readonly expectedResult: "Returns a FootnoteMutationResult indicating success with the footnote address or a failure.";
|
|
2833
2833
|
readonly requiresDocumentContext: true;
|
|
2834
2834
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -2837,7 +2837,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
2837
2837
|
};
|
|
2838
2838
|
readonly 'footnotes.update': {
|
|
2839
2839
|
readonly memberPath: "footnotes.update";
|
|
2840
|
-
readonly description: "Update the content of an existing footnote or endnote.
|
|
2840
|
+
readonly description: "Update the content of an existing footnote or endnote.";
|
|
2841
2841
|
readonly expectedResult: "Returns a FootnoteMutationResult indicating success with the updated footnote address or a failure.";
|
|
2842
2842
|
readonly requiresDocumentContext: true;
|
|
2843
2843
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -3107,7 +3107,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3107
3107
|
};
|
|
3108
3108
|
readonly 'fields.insert': {
|
|
3109
3109
|
readonly memberPath: "fields.insert";
|
|
3110
|
-
readonly description: "Insert a raw field code at a target location, optionally preserving cached result text.
|
|
3110
|
+
readonly description: "Insert a raw field code at a target location, optionally preserving cached result text.";
|
|
3111
3111
|
readonly expectedResult: "Returns a FieldMutationResult indicating success with the field address or a failure.";
|
|
3112
3112
|
readonly requiresDocumentContext: true;
|
|
3113
3113
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -3657,9 +3657,6 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3657
3657
|
readonly "format.border": OperationDefinitionEntry & {
|
|
3658
3658
|
memberPath: "format.border";
|
|
3659
3659
|
};
|
|
3660
|
-
readonly "format.fitText": OperationDefinitionEntry & {
|
|
3661
|
-
memberPath: "format.fitText";
|
|
3662
|
-
};
|
|
3663
3660
|
readonly "format.dstrike": OperationDefinitionEntry & {
|
|
3664
3661
|
memberPath: "format.dstrike";
|
|
3665
3662
|
};
|
|
@@ -3687,6 +3684,9 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3687
3684
|
readonly "format.kerning": OperationDefinitionEntry & {
|
|
3688
3685
|
memberPath: "format.kerning";
|
|
3689
3686
|
};
|
|
3687
|
+
readonly "format.fitText": OperationDefinitionEntry & {
|
|
3688
|
+
memberPath: "format.fitText";
|
|
3689
|
+
};
|
|
3690
3690
|
readonly "format.rStyle": OperationDefinitionEntry & {
|
|
3691
3691
|
memberPath: "format.rStyle";
|
|
3692
3692
|
};
|
|
@@ -3744,7 +3744,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3744
3744
|
};
|
|
3745
3745
|
readonly getNodeById: {
|
|
3746
3746
|
readonly memberPath: "getNodeById";
|
|
3747
|
-
readonly description: "
|
|
3747
|
+
readonly description: "Resolve a block ID across the body, linked headers/footers, and supported textboxes, optionally restricted by story. Paragraphs at every table-cell depth and top-level body/header/footer tables are supported; notes, comments, glossary, and nested table containers are excluded.";
|
|
3748
3748
|
readonly expectedResult: "Returns an SDNodeResult envelope with the projected SDM/1 node and canonical address.";
|
|
3749
3749
|
readonly requiresDocumentContext: true;
|
|
3750
3750
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -3948,7 +3948,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3948
3948
|
};
|
|
3949
3949
|
readonly 'blocks.split': {
|
|
3950
3950
|
readonly memberPath: "blocks.split";
|
|
3951
|
-
readonly description:
|
|
3951
|
+
readonly description: "Split a paragraph at a visible-text offset, producing two paragraphs. Preserves unambiguous simple run properties around the cut. Rejects when the paragraph contains fields, content controls, drawings, equations, or unsupported tracked-change wrappers.";
|
|
3952
3952
|
readonly expectedResult: "Returns a BlocksSplitResult; on success carries the new tail paragraph address, affectedStories, and (for engines that report them) story-absolute textRangeShifts and a txId for history correlation.";
|
|
3953
3953
|
readonly requiresDocumentContext: true;
|
|
3954
3954
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -3957,7 +3957,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3957
3957
|
};
|
|
3958
3958
|
readonly 'blocks.merge': {
|
|
3959
3959
|
readonly memberPath: "blocks.merge";
|
|
3960
|
-
readonly description:
|
|
3960
|
+
readonly description: "Merge two adjacent paragraphs in the same story. The first paragraph keeps its pPr; the second paragraph is removed. Rejects when either paragraph carries a w:sectPr or when their numbering definitions differ.";
|
|
3961
3961
|
readonly expectedResult: "Returns a BlocksMergeResult; on success carries the removed paragraph address plus affectedStories, textRangeShifts, and a txId.";
|
|
3962
3962
|
readonly requiresDocumentContext: true;
|
|
3963
3963
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -3966,7 +3966,7 @@ export declare const OPERATION_DEFINITIONS: {
|
|
|
3966
3966
|
};
|
|
3967
3967
|
readonly 'blocks.move': {
|
|
3968
3968
|
readonly memberPath: "blocks.move";
|
|
3969
|
-
readonly description:
|
|
3969
|
+
readonly description: "Move a paragraph within the same story to a new anchor paragraph (before or after). Cross-story and relationship-bearing moves reject with named reasons. Tracked-mode authoring emits paired `<w:moveFrom>` / `<w:moveTo>` review state with explicit move range marker identity; safe content (no comment/bookmark/permission anchors and no pre-existing tracked wrappers) is required for tracked authoring.";
|
|
3970
3970
|
readonly expectedResult: "Returns a BlocksMoveResult; on success carries the moved paragraph address plus affectedStories and a txId. Tracked-mode results include `trackedChangeRefs` pointing at the paired move review entity.";
|
|
3971
3971
|
readonly requiresDocumentContext: true;
|
|
3972
3972
|
readonly metadata: CommandStaticMetadata;
|
|
@@ -47,6 +47,10 @@ type AttributedTextInvokeRequest<T extends OperationId> = T extends 'insert' ? {
|
|
|
47
47
|
export type InvokeRequest<T extends OperationId> = MethodInvokeRequest<T> | AttributedTextInvokeRequest<T>;
|
|
48
48
|
/** Typed invoke result narrowed by `operationId`. */
|
|
49
49
|
export type InvokeResult<T extends OperationId> = T extends 'mutations.preview' | 'mutations.apply' ? Promise<OperationRegistry[T]['output']> : T extends 'plan.execute' ? OperationRegistry[T]['output'] | Promise<OperationRegistry[T]['output']> : OperationRegistry[T]['output'];
|
|
50
|
+
export type OperationCall<T extends OperationId> = InvokeRequest<T> extends infer Request ? (Request extends unknown ? Omit<Request, 'operationId'> : never) : never;
|
|
51
|
+
export type OperationInput<T extends OperationId> = InvokeRequest<T>['input'];
|
|
52
|
+
export type OperationOptions<T extends OperationId> = Exclude<InvokeRequest<T>['options'], undefined>;
|
|
53
|
+
export type OperationOutput<T extends OperationId> = Awaited<InvokeResult<T>>;
|
|
50
54
|
/** Loose request for callers that resolve operation identity at runtime. */
|
|
51
55
|
export type DynamicInvokeRequest = {
|
|
52
56
|
operationId: OperationId;
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import { ExportToDocxInput, ExportToDocxResult, SDExportMode } from './export.types.js';
|
|
1
|
+
import { DocxExportPolicies, ExportToDocxInput, ExportToDocxResult, SDExportMode } from './export.types.js';
|
|
2
2
|
export interface ExportAdapter {
|
|
3
3
|
toDocx(input: {
|
|
4
4
|
mode: SDExportMode;
|
|
5
|
+
policies?: Required<DocxExportPolicies>;
|
|
5
6
|
}): ExportToDocxResult;
|
|
6
7
|
}
|
|
7
8
|
export interface ExportApi {
|
|
8
9
|
toDocx(input?: ExportToDocxInput): ExportToDocxResult;
|
|
9
10
|
}
|
|
11
|
+
export declare function resolveDocxExportPolicies(input?: ExportToDocxInput): Required<DocxExportPolicies>;
|
|
10
12
|
export declare function executeExportToDocx(adapter: ExportAdapter | undefined, input?: ExportToDocxInput): ExportToDocxResult;
|
|
@@ -12,10 +12,18 @@ export declare const SD_EXPORT_MODES: readonly ["review-preserving", "final", "o
|
|
|
12
12
|
export type SDExportMode = (typeof SD_EXPORT_MODES)[number];
|
|
13
13
|
/** Default mode for modeful DOCX export. */
|
|
14
14
|
export declare const DEFAULT_SD_EXPORT_MODE: SDExportMode;
|
|
15
|
+
export declare const SD_COMMENT_EXPORT_POLICIES: readonly ["preserve", "resolve", "remove"];
|
|
16
|
+
export declare const SD_CONTENT_CONTROL_EXPORT_POLICIES: readonly ["preserve", "flatten"];
|
|
17
|
+
export interface DocxExportPolicies {
|
|
18
|
+
trackedChanges?: SDExportMode;
|
|
19
|
+
comments?: (typeof SD_COMMENT_EXPORT_POLICIES)[number];
|
|
20
|
+
contentControls?: (typeof SD_CONTENT_CONTROL_EXPORT_POLICIES)[number];
|
|
21
|
+
}
|
|
15
22
|
/** Input for `export.toDocx`. */
|
|
16
23
|
export interface ExportToDocxInput {
|
|
17
24
|
/** Tracked-change export mode. Defaults to `review-preserving`. */
|
|
18
25
|
mode?: SDExportMode;
|
|
26
|
+
policies?: DocxExportPolicies;
|
|
19
27
|
}
|
|
20
28
|
/** Structured degradation report for an export. */
|
|
21
29
|
export interface ExportToDocxReport {
|
|
@@ -1,11 +1,15 @@
|
|
|
1
|
-
import { BlockNodeType, NodeAddress } from '../types/index.js';
|
|
1
|
+
import { BlockNodeType, NodeAddress, StoryLocator } from '../types/index.js';
|
|
2
2
|
import { SDNodeResult } from '../types/sd-envelope.js';
|
|
3
3
|
/**
|
|
4
|
-
* Input for resolving a block node by its
|
|
4
|
+
* Input for resolving a block node by its ID without guessing its type.
|
|
5
|
+
* Resolves paragraphs (including table-cell paragraphs) in the body, linked
|
|
6
|
+
* header/footer parts, and supported textboxes, plus top-level body/header/footer tables.
|
|
7
|
+
* Notes, comments, glossary, and nested table containers are outside this resolver.
|
|
5
8
|
*/
|
|
6
9
|
export interface GetNodeByIdInput {
|
|
7
10
|
nodeId: string;
|
|
8
11
|
nodeType?: BlockNodeType;
|
|
12
|
+
story?: StoryLocator;
|
|
9
13
|
}
|
|
10
14
|
/**
|
|
11
15
|
* Engine-specific adapter that the getNode API delegates to.
|
|
@@ -16,7 +20,8 @@ export interface GetNodeAdapter {
|
|
|
16
20
|
*
|
|
17
21
|
* @param address - The node address to resolve.
|
|
18
22
|
* @returns SDNodeResult with the projected node and its address.
|
|
19
|
-
* @throws When the address cannot be resolved
|
|
23
|
+
* @throws When the address cannot be resolved, including AMBIGUOUS_TARGET
|
|
24
|
+
* when its node ID is duplicated within the addressed story.
|
|
20
25
|
*/
|
|
21
26
|
getNode(address: NodeAddress): SDNodeResult;
|
|
22
27
|
/**
|
|
@@ -24,7 +29,8 @@ export interface GetNodeAdapter {
|
|
|
24
29
|
*
|
|
25
30
|
* @param input - The node-id input payload.
|
|
26
31
|
* @returns SDNodeResult with the projected node and its address.
|
|
27
|
-
* @throws
|
|
32
|
+
* @throws TARGET_NOT_FOUND for no match, AMBIGUOUS_TARGET for duplicate IDs,
|
|
33
|
+
* or CAPABILITY_UNAVAILABLE for an unsupported story hint.
|
|
28
34
|
*/
|
|
29
35
|
getNodeById(input: GetNodeByIdInput): SDNodeResult;
|
|
30
36
|
}
|
|
@@ -2,6 +2,7 @@ import { BlockNodeAddress, InlineNodeAddress } from '../types/base.js';
|
|
|
2
2
|
import { TextAddress } from '../types/address.js';
|
|
3
3
|
import { DiscoveryOutput } from '../types/discovery.js';
|
|
4
4
|
import { ReceiptFailure, ReceiptSuccess } from '../types/receipt.js';
|
|
5
|
+
import { StoryLocator } from '../types/story.types.js';
|
|
5
6
|
/** Narrowed inline address for hyperlink targets. */
|
|
6
7
|
export type HyperlinkTarget = InlineNodeAddress & {
|
|
7
8
|
nodeType: 'hyperlink';
|
|
@@ -93,6 +94,7 @@ export interface HyperlinkMutationFailure {
|
|
|
93
94
|
export type HyperlinkMutationResult = HyperlinkMutationSuccess | HyperlinkMutationFailure;
|
|
94
95
|
export type HyperlinksListResult = DiscoveryOutput<HyperlinkDomain>;
|
|
95
96
|
export interface HyperlinksListQuery {
|
|
97
|
+
in?: StoryLocator;
|
|
96
98
|
within?: BlockNodeAddress;
|
|
97
99
|
hrefPattern?: string;
|
|
98
100
|
anchor?: string;
|
|
@@ -75,6 +75,7 @@ export { executeHistoryGet, executeHistoryUndo, executeHistoryRedo } from './his
|
|
|
75
75
|
export type { DiffAdapter, DiffApi } from './diff/diff.js';
|
|
76
76
|
export * from './diff/diff.types.js';
|
|
77
77
|
export type { ExportAdapter, ExportApi } from './export/export.js';
|
|
78
|
+
export { resolveDocxExportPolicies } from './export/export.js';
|
|
78
79
|
export * from './export/export.types.js';
|
|
79
80
|
export type { SelectionMutationAdapter, SelectionMutationRequest, SelectionInsertRequest, } from './selection-mutation.js';
|
|
80
81
|
export type { RangeAnchor, DocumentEdgeAnchor, PointAnchor, RefBoundaryAnchor, ResolveRangeInput, ResolveRangeOutput, RangeBlockPreview, RangePreview, RangeResolverAdapter, ScrollIntoViewInput, ScrollIntoViewOutput, } from './ranges/index.js';
|
|
@@ -185,7 +186,7 @@ export { isBlockNodeAddress } from './validation-primitives.js';
|
|
|
185
186
|
export type { InsertInput, InsertContentType, TextInsertInput, PlainTextInsertInput, RichContentInsertInput, NativeOoxmlInsertInput, LegacyInsertInput, } from './insert/insert.js';
|
|
186
187
|
export { isStructuralInsertInput } from './insert/insert.js';
|
|
187
188
|
export type { ReplaceInput, TextReplaceInput, TextReplacementGranularity, RichContentReplaceInput, ReplaceMutationOptions, NativeOoxmlReplaceInput, SnapshotReplaceInput, ParagraphTextReplaceInput, } from './replace/replace.js';
|
|
188
|
-
export { executeReplace, isStructuralReplaceInput, isRichContentReplaceInput } from './replace/replace.js';
|
|
189
|
+
export { executeReplace, isStructuralReplaceInput, isRichContentReplaceInput, TEXT_REPLACEMENT_GRANULARITIES, isTextReplacementGranularity, isSingleParagraphVisibleTextSelection, } from './replace/replace.js';
|
|
189
190
|
export { executeFind } from './find/find.js';
|
|
190
191
|
export { validateDocumentFragment, validateSDFragment } from './validation/fragment-validator.js';
|
|
191
192
|
export type { DeleteInput } from './delete/delete.js';
|