superdoc 2.27.0-next.1 → 2.27.0-next.11
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-BCQ5RHxy.es.js → create-super-doc-ui-B29zw5qD.es.js} +192 -13
- package/dist/chunks/{create-super-doc-ui-DK14sCrT.cjs → create-super-doc-ui-D1eOhAjv.cjs} +197 -12
- package/dist/collaboration-upgrade-engine.cjs +1 -1
- package/dist/collaboration-upgrade-engine.es.js +1 -1
- package/dist/document-api/src/contract/operation-definitions.d.ts +2 -2
- package/dist/document-api/src/history/history.types.d.ts +0 -6
- package/dist/document-api/src/index.d.ts +4 -4
- package/dist/document-api/src/lists/lists.types.d.ts +3 -0
- package/dist/document-api/src/styles/apply.d.ts +26 -2
- package/dist/document-api/src/styles/index.d.ts +3 -3
- package/dist/document-api/src/styles/schema.d.ts +3 -1
- package/dist/document-api/src/styles/validation.d.ts +10 -9
- package/dist/document-api/src/types/receipt.d.ts +2 -1
- package/dist/document-api/src/types/temporary-mutation.d.ts +39 -4
- package/dist/layout-engine/contracts/src/direction-context.d.ts +1 -2
- package/dist/layout-engine/contracts/src/resolved-layout.d.ts +0 -34
- package/dist/layout-engine/layout-bridge/src/neutral-hit.d.ts +0 -7
- package/dist/layout-engine/layout-engine/src/index.d.ts +0 -1
- package/dist/layout-engine/painters/dom/src/features/inline-direction/run-direction.d.ts +0 -3
- 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/style.css +1 -1
- package/dist/style.layered.css +1 -1
- package/dist/superdoc/src/core/types/index.d.ts +3 -60
- package/dist/superdoc/src/core/v2-integration/v2-integration.d.ts +2 -5
- package/dist/superdoc/src/helpers/tracked-change-comment-lane.d.ts +1 -0
- package/dist/superdoc/src/helpers/v2-review-mutation-impact.d.ts +0 -6
- package/dist/superdoc/src/internal/toolbar/built-in/LinkedStyle.vue.d.ts +3 -1
- package/dist/superdoc/src/internal/toolbar/built-in/toolbarTexts.d.ts +1 -0
- package/dist/superdoc/src/internal/toolbar/built-in-toolbar.d.ts +1 -0
- package/dist/superdoc/src/public/ui/style-match-patch.d.ts +7 -0
- package/dist/superdoc/src/public/ui/types.d.ts +5 -1
- package/dist/superdoc/src/public/ui-react.d.ts +0 -5
- package/dist/superdoc/src/public/ui-vue.d.ts +0 -5
- package/dist/superdoc/src/public/ui.d.cts +18 -0
- package/dist/superdoc/src/public/ui.d.ts +1 -10
- package/dist/superdoc.cjs +117 -85
- package/dist/superdoc.es.js +110 -80
- package/dist-cdn/style.layered.css +1 -1
- package/dist-cdn/superdoc.min.css +1 -1
- package/dist-cdn/superdoc.min.js +38 -38
- package/package.json +2 -5
- package/dist/superdoc/src/components/CommentsLayer/comment-schemas.d.ts +0 -18
- package/dist/superdoc/src/components/CommentsLayer/types.d.ts +0 -3
- package/dist/superdoc/src/components/CommentsLayer/use-conversation.d.ts +0 -22
- package/dist/superdoc/src/components/CommentsLayer/use-floating-comment.d.ts +0 -11
- package/dist/superdoc/src/core/collaboration/room-overwrite.d.ts +0 -22
- package/dist/superdoc/src/core/index.d.ts +0 -1
- package/dist/superdoc/src/stores/hrbr-fields-store.d.ts +0 -43
|
@@ -64,7 +64,7 @@ import { CaptionsApi, CaptionsAdapter } from './captions/captions.js';
|
|
|
64
64
|
import { FieldsApi, FieldsAdapter } from './fields/fields.js';
|
|
65
65
|
import { CitationsApi, CitationsAdapter } from './citations/citations.js';
|
|
66
66
|
import { AuthoritiesApi, AuthoritiesAdapter } from './authorities/authorities.js';
|
|
67
|
-
export type { TemporaryMutationInput, TemporaryMutationHandleInput, TemporaryMutationCommitInput, TemporaryMutationReplaceInput, TemporaryMutationReceipt, TemporaryMutationMetadata, TemporaryMutationOperation, } from './types/temporary-mutation.js';
|
|
67
|
+
export type { TemporaryMutationInput, TemporaryMutationHandleInput, TemporaryMutationCommitInput, TemporaryMutationReplaceInput, TemporaryMutationReceipt, TemporaryMutationMetadata, TemporaryMutationOperation, TemporaryOperationResultTarget, } from './types/temporary-mutation.js';
|
|
68
68
|
export * from './types/index.js';
|
|
69
69
|
export * from './contract/index.js';
|
|
70
70
|
export * from './capabilities/capabilities.js';
|
|
@@ -116,10 +116,10 @@ export type { FormatReadSelectionAdapter, FormatReadSelectionInput, FormatReadSe
|
|
|
116
116
|
export type { InlineRunPatch, InlineRunPatchKey, InlinePropertyStorage, InlinePropertyType, InlinePropertyCarrier, InlinePropertyRegistryEntry, UnderlinePatch, ShadingPatch, BorderPatch, FitTextPatch, LangPatch, RFontsPatch, EastAsianLayoutPatch, StylisticSetPatch, } from './format/inline-run-patch.js';
|
|
117
117
|
export { CLEAR_INLINE_FORMATTING_KEYS, INLINE_PROPERTY_REGISTRY, INLINE_PROPERTY_KEY_SET, INLINE_PROPERTY_BY_KEY, INLINE_PROPERTY_KEYS_BY_STORAGE, validateInlineRunPatch, buildInlineRunPatchSchema, } from './format/inline-run-patch.js';
|
|
118
118
|
export { PROPERTY_REGISTRY, EXCLUDED_KEYS, ALLOWED_KEYS_BY_CHANNEL, getPropertyDefinition, toJsonSchema, buildPatchSchema, buildStateSchema, } from './styles/index.js';
|
|
119
|
-
export type { ValueSchema, MergeStrategy, PropertyDefinition, StylesAdapter, StylesApplyInput, StylesApplyRunInput, StylesApplyParagraphInput, StylesApplyOptions, StylesApplyReceipt, StylesBooleanState, StylesNumberState, StylesEnumState, StylesObjectState, StylesArrayState, StylesStateMap, StylesChannel, StylesRunPatch, StylesParagraphPatch, StylesTargetResolution, StylesApplyReceiptSuccess, StylesApplyReceiptFailure, NormalizedStylesApplyOptions, StyleCatalogView, StyleCatalogItemType, StyleCatalogFilterType, StyleProvenance, StyleCatalogDiagnosticSeverity, StyleSourcePartStatus, StyleCatalogUsageStatus, StyleCatalogPreviewStatus, StyleCatalogViewStatus, StyleCatalogItemVisibility, StyleCatalogItemUsage, StyleCatalogItemPreview, StyleCatalogPreviewFontSource, StyleCatalogPreviewColorSource, StyleCatalogPreviewSources, StyleCatalogItem, StyleCatalogDefaults, StyleCatalogDiagnostic, StyleCatalogSourceStatus, StylesGetCatalogInput, StylesGetCatalogResult, StylesGetCatalogAdapter, StylesGetThemeInput, StylesThemeSourceStatus, StylesGetThemeResult, StylesGetThemeAdapter, } from './styles/index.js';
|
|
119
|
+
export type { ValueSchema, MergeStrategy, PropertyDefinition, StylesAdapter, StylesApplyInput, StylesApplyRunInput, StylesApplyParagraphInput, StylesApplyStyleRunInput, StylesStyleRunPatch, StylesDocDefaultsResolution, StylesStyleResolution, StylesApplyOptions, StylesApplyReceipt, StylesBooleanState, StylesNumberState, StylesEnumState, StylesObjectState, StylesArrayState, StylesStateMap, StylesChannel, StylesRunPatch, StylesParagraphPatch, StylesTargetResolution, StylesApplyReceiptSuccess, StylesApplyReceiptFailure, NormalizedStylesApplyOptions, StyleCatalogView, StyleCatalogItemType, StyleCatalogFilterType, StyleProvenance, StyleCatalogDiagnosticSeverity, StyleSourcePartStatus, StyleCatalogUsageStatus, StyleCatalogPreviewStatus, StyleCatalogViewStatus, StyleCatalogItemVisibility, StyleCatalogItemUsage, StyleCatalogItemPreview, StyleCatalogPreviewFontSource, StyleCatalogPreviewColorSource, StyleCatalogPreviewSources, StyleCatalogItem, StyleCatalogDefaults, StyleCatalogDiagnostic, StyleCatalogSourceStatus, StylesGetCatalogInput, StylesGetCatalogResult, StylesGetCatalogAdapter, StylesGetThemeInput, StylesThemeSourceStatus, StylesGetThemeResult, StylesGetThemeAdapter, } from './styles/index.js';
|
|
120
120
|
export { STYLE_CATALOG_VIEWS, STYLE_CATALOG_FILTER_TYPES, executeStylesGetCatalog, validateStylesGetCatalogInput, executeStylesGetTheme, validateStylesGetThemeInput, } from './styles/index.js';
|
|
121
121
|
export type { StylesScope, StyleRunPatch, StyleConflictPolicy, StyleChannelState, StylesCreateAdapter, StylesCreateApi, StylesCreateInput, StylesCreateParagraphInput, StylesCreateCharacterInput, StylesCreateOptions, NormalizedStylesCreateOptions, StylesCreateResolution, StylesCreateReceipt, StylesCreateReceiptSuccess, StylesCreateReceiptFailure, } from './styles/index.js';
|
|
122
|
-
export { STYLE_EXCLUDED_KEYS, EXCLUDED_KEYS_BY_SCOPE, SCOPE_LABEL, STYLE_XML_PATH, executeStylesCreate, validateStylesCreateInput, validateStylesCreateOptions, validatePatchObject, } from './styles/index.js';
|
|
122
|
+
export { STYLE_EXCLUDED_KEYS, EXCLUDED_KEYS_BY_SCOPE, SCOPE_LABEL, STYLE_XML_PATH, STYLE_RUN_XML_PATH, validateStylesApplyInput, executeStylesCreate, validateStylesCreateInput, validateStylesCreateOptions, validatePatchObject, } from './styles/index.js';
|
|
123
123
|
export type { TemplatesAdapter, TemplatesApi, TemplatesApplyInput, TemplatesApplyOptions, TemplatesApplySource, TemplatesApplySourcePath, TemplatesApplySourceBase64, TemplateBodyPolicy, TemplateScope, NormalizedTemplatesApplyOptions, TemplateScopeReport, TemplateSkipReason, TemplateScopeSkip, TemplateUnsupportedItem, TemplateChangeKind, TemplateChangedPart, TemplateIdMapping, TemplateApplyWarning, TemplatesApplySourceInfo, TemplatesApplyReceiptSuccess, TemplatesApplyFailureCode, TemplatesApplyReceiptFailure, TemplatesApplyReceipt, } from './templates/index.js';
|
|
124
124
|
export { executeTemplatesApply } from './templates/index.js';
|
|
125
125
|
export type { CreateAdapter, CreateApi } from './create/create.js';
|
|
@@ -169,7 +169,7 @@ export type { ParagraphsAdapter, ParagraphFormatApi, ParagraphStylesApi } from '
|
|
|
169
169
|
export type { ParagraphTarget, ParagraphBlockType, ParagraphMutationResult, ParagraphMutationSuccess, ParagraphMutationFailure, MutationResolution, ParagraphAlignment, TabStopAlignment, TabStopLeader, BorderSide, ClearBorderSide, LineRule, ParagraphsSetStyleInput, ParagraphSemanticStyleRole, ParagraphsSetStyleRefInput, ParagraphsClearStyleInput, ParagraphsResetDirectFormattingInput, ParagraphsSetAlignmentInput, ParagraphsClearAlignmentInput, ParagraphsSetIndentationInput, ParagraphsClearIndentationInput, ParagraphsSetSpacingInput, ParagraphsClearSpacingInput, ParagraphsSetKeepOptionsInput, ParagraphsSetOutlineLevelInput, ParagraphsSetFlowOptionsInput, ParagraphsSetTabStopInput, ParagraphsClearTabStopInput, ParagraphsClearAllTabStopsInput, ParagraphsSetBorderInput, ParagraphsClearBorderInput, ParagraphsSetShadingInput, ParagraphsClearShadingInput, ParagraphsSetMarkRunPropsInput, ParagraphsSetDirectionInput, ParagraphsClearDirectionInput, ParagraphsSetNumberingInput, ParagraphDirection, AlignmentPolicy, } from './paragraphs/paragraphs.js';
|
|
170
170
|
export { PARAGRAPH_ALIGNMENTS, TAB_STOP_ALIGNMENTS, TAB_STOP_LEADERS, BORDER_SIDES, CLEAR_BORDER_SIDES, LINE_RULES, PARAGRAPH_DIRECTIONS, ALIGNMENT_POLICIES, } from './paragraphs/paragraphs.js';
|
|
171
171
|
export type { BlockAddress, BlockRange, CanContinueReason, CanJoinReason, JoinDirection, ListInsertInput, ListItemAddress, ListItemInfo, ListKind, ListsAttachInput, ListsCanContinuePreviousInput, ListsCanContinuePreviousResult, ListsCanJoinInput, ListsCanJoinResult, ListsConvertToTextInput, ListsConvertToTextResult, ListsContinuePreviousInput, ListsCreateInput, ListsCreateResult, ListsDetachInput, ListsDetachResult, ListsDeleteInput, ListsDeleteResult, ListsFailureCode, ListsGetInput, ListsInsertResult, ListsJoinInput, ListsJoinResult, ListsListQuery, ListsListResult, ListsMutateItemResult, ListsSeparateInput, ListsSeparateResult, ListsMergeInput, ListsMergeResult, ListsSplitInput, ListsSplitResult, ListsSetLevelInput, ListsSetLevelRestartInput, ListsSetValueInput, ListTargetInput, MutationScope, LevelAlignment, TrailingCharacter, ListPresetId, ListPresetMarker, ListLevelTemplate, ListTemplate, ListsApplyTemplateInput, ListsApplyPresetInput, ListsCaptureTemplateInput, ListsCaptureTemplateResult, ListsCaptureTemplateSuccessResult, ListsSetLevelNumberingInput, ListsSetLevelBulletInput, ListsSetLevelPictureBulletInput, ListsSetLevelAlignmentInput, ListsSetLevelIndentsInput, ListsSetLevelTrailingCharacterInput, ListsSetLevelMarkerFontInput, ListsClearLevelOverridesInput, ListsSetTypeInput, ListStyle, ListLevelStyle, ListLevelLayout, ListsGetStyleInput, ListsGetStyleResult, ListsGetStyleSuccessResult, ListsApplyStyleInput, ListsRestartAtInput, ListsSetLevelNumberStyleInput, ListsSetLevelTextInput, ListsSetLevelStartInput, ListsSetLevelLayoutInput, ListsGetStateInput, ListsGetStateResult, ListsApplyInput, ListsContinueV2Input, ListsRestartV2Input, ListsRemoveV2Input, } from './lists/lists.types.js';
|
|
172
|
-
export { LIST_KINDS, LIST_INSERT_POSITIONS, JOIN_DIRECTIONS, MUTATION_SCOPES, LEVEL_ALIGNMENTS, TRAILING_CHARACTERS, LIST_PRESET_IDS, LIST_PRESET_MARKERS, } from './lists/lists.types.js';
|
|
172
|
+
export { LIST_KINDS, LIST_INSERT_POSITIONS, JOIN_DIRECTIONS, MUTATION_SCOPES, LEVEL_ALIGNMENTS, TRAILING_CHARACTERS, LIST_PRESET_IDS, LIST_PRESET_MARKERS, LIST_CUSTOM_NUMBERING_FORMATS, } from './lists/lists.types.js';
|
|
173
173
|
export type { CreateSectionBreakInput, CreateSectionBreakResult, DocumentMutationResult, SectionAddress, SectionBorderSpec, SectionBreakCreateLocation, SectionBreakRepresentation, SectionBreakType, SectionColumns, SectionDirection, SectionDomain, SectionHeaderFooterKind, SectionHeaderFooterMargins, SectionHeaderFooterRefs, SectionHeaderFooterVariant, SectionInfo, SectionLineNumbering, SectionLineNumberRestart, SectionMutationResult, SectionOrientation, SectionPageBorders, SectionPageMargins, SectionPageNumbering, SectionPageNumberingChapterSeparator, SectionPageNumberingFormat, SectionPageSetup, SectionRangeDomain, SectionTargetInput, SectionVerticalAlign, SectionsClearHeaderFooterRefInput, SectionsClearPageBordersInput, SectionsGetInput, SectionsListQuery, SectionsListResult, SectionsSetBreakTypeInput, SectionsSetColumnsInput, SectionsSetHeaderFooterMarginsInput, SectionsSetHeaderFooterRefInput, SectionsSetLineNumberingInput, SectionsSetLinkToPreviousInput, SectionsSetOddEvenHeadersFootersInput, SectionsSetPageBordersInput, SectionsSetPageMarginsInput, SectionsSetPageNumberingInput, SectionsSetPageSetupInput, SectionsSetSectionDirectionInput, SectionsSetTitlePageInput, SectionsSetVerticalAlignInput, } from './sections/sections.types.js';
|
|
174
174
|
export type { CommentsCreateReceipt, CommentsCreateInput, CommentCreateAttributionInput, CommentsPatchInput, CommentsDeleteInput, CommentsAdapter, CommentsApi, GetCommentInput, TrackedChangeCommentTarget, TrackedChangeCommentTargetSide, TextSearchCommentTarget, AddCommentInput, EditCommentInput, ReplyToCommentInput, MoveCommentInput, ResolveCommentInput, ReopenCommentInput, RemoveCommentInput, SetCommentInternalInput, GoToCommentInput, SetCommentActiveInput, } from './comments/comments.js';
|
|
175
175
|
export { executeCommentsCreate, executeCommentsPatch, executeCommentsDelete, executeGetComment, executeListComments, } from './comments/comments.js';
|
|
@@ -206,10 +206,12 @@ export interface ListsConvertToTextInput {
|
|
|
206
206
|
target: ListItemAddress;
|
|
207
207
|
includeMarker?: boolean;
|
|
208
208
|
}
|
|
209
|
+
export declare const LIST_CUSTOM_NUMBERING_FORMATS: readonly ["01, 02, 03, ...", "001, 002, 003, ...", "0001, 0002, 0003, ..."];
|
|
209
210
|
/** A captured snapshot of one level's formatting properties. */
|
|
210
211
|
export interface ListLevelTemplate {
|
|
211
212
|
level: number;
|
|
212
213
|
numFmt?: string;
|
|
214
|
+
customFormat?: string;
|
|
213
215
|
lvlText?: string;
|
|
214
216
|
start?: number;
|
|
215
217
|
alignment?: LevelAlignment;
|
|
@@ -274,6 +276,7 @@ export interface ListsSetLevelNumberingInput {
|
|
|
274
276
|
target: ListItemAddress;
|
|
275
277
|
level: number;
|
|
276
278
|
numFmt: string;
|
|
279
|
+
customFormat?: string;
|
|
277
280
|
lvlText: string;
|
|
278
281
|
start?: number;
|
|
279
282
|
/** Format numeric placeholders as decimal. False removes legal numbering; omit to preserve it. */
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ReceiptFailure } from '../types/receipt.js';
|
|
2
2
|
import { StylesChannel } from './registry.js';
|
|
3
3
|
import { StylesGetCatalogInput, StylesGetCatalogResult } from './catalog.js';
|
|
4
|
+
import { StyleRunPatch } from './create.js';
|
|
4
5
|
import { StylesGetThemeInput, StylesGetThemeResult } from './theme.js';
|
|
5
6
|
/** Tri-state for OOXML boolean style properties. */
|
|
6
7
|
export type StylesBooleanState = 'on' | 'off' | 'inherit';
|
|
@@ -78,12 +79,22 @@ export interface StylesParagraphPatch {
|
|
|
78
79
|
borders?: Record<string, unknown>;
|
|
79
80
|
tabStops?: unknown[];
|
|
80
81
|
}
|
|
81
|
-
export interface
|
|
82
|
+
export interface StylesDocDefaultsResolution {
|
|
82
83
|
scope: 'docDefaults';
|
|
83
84
|
channel: StylesChannel;
|
|
84
85
|
xmlPart: string;
|
|
85
86
|
xmlPath: string;
|
|
86
87
|
}
|
|
88
|
+
export interface StylesStyleResolution {
|
|
89
|
+
scope: 'style';
|
|
90
|
+
styleId: string;
|
|
91
|
+
channel: 'run';
|
|
92
|
+
xmlPart: string;
|
|
93
|
+
xmlPath: typeof STYLE_RUN_XML_PATH;
|
|
94
|
+
linkedStyleId?: string;
|
|
95
|
+
}
|
|
96
|
+
export type StylesTargetResolution = StylesDocDefaultsResolution | StylesStyleResolution;
|
|
97
|
+
export declare const STYLE_RUN_XML_PATH = "w:styles/w:style/w:rPr";
|
|
87
98
|
export interface StylesApplyRunInput {
|
|
88
99
|
target: {
|
|
89
100
|
scope: 'docDefaults';
|
|
@@ -98,7 +109,18 @@ export interface StylesApplyParagraphInput {
|
|
|
98
109
|
};
|
|
99
110
|
patch: StylesParagraphPatch;
|
|
100
111
|
}
|
|
101
|
-
export type
|
|
112
|
+
export type StylesStyleRunPatch = {
|
|
113
|
+
[K in keyof StyleRunPatch]?: StyleRunPatch[K] | null;
|
|
114
|
+
};
|
|
115
|
+
export interface StylesApplyStyleRunInput {
|
|
116
|
+
target: {
|
|
117
|
+
scope: 'style';
|
|
118
|
+
styleId: string;
|
|
119
|
+
channel: 'run';
|
|
120
|
+
};
|
|
121
|
+
patch: StylesStyleRunPatch;
|
|
122
|
+
}
|
|
123
|
+
export type StylesApplyInput = StylesApplyRunInput | StylesApplyParagraphInput | StylesApplyStyleRunInput;
|
|
102
124
|
export interface StylesApplyOptions {
|
|
103
125
|
dryRun?: boolean;
|
|
104
126
|
expectedRevision?: string;
|
|
@@ -121,6 +143,7 @@ export type StylesApplyReceipt = StylesApplyReceiptSuccess | StylesApplyReceiptF
|
|
|
121
143
|
export interface StylesAdapter {
|
|
122
144
|
apply(input: StylesApplyRunInput, options: NormalizedStylesApplyOptions): StylesApplyReceipt;
|
|
123
145
|
apply(input: StylesApplyParagraphInput, options: NormalizedStylesApplyOptions): StylesApplyReceipt;
|
|
146
|
+
apply(input: StylesApplyStyleRunInput, options: NormalizedStylesApplyOptions): StylesApplyReceipt;
|
|
124
147
|
apply(input: StylesApplyInput, options: NormalizedStylesApplyOptions): StylesApplyReceipt;
|
|
125
148
|
/** Read the normalized style catalogue. See `styles/catalog.ts`. */
|
|
126
149
|
getCatalog?(input?: StylesGetCatalogInput): StylesGetCatalogResult;
|
|
@@ -134,6 +157,7 @@ export interface NormalizedStylesApplyOptions {
|
|
|
134
157
|
export interface StylesApi {
|
|
135
158
|
apply(input: StylesApplyRunInput, options?: StylesApplyOptions): StylesApplyReceipt;
|
|
136
159
|
apply(input: StylesApplyParagraphInput, options?: StylesApplyOptions): StylesApplyReceipt;
|
|
160
|
+
apply(input: StylesApplyStyleRunInput, options?: StylesApplyOptions): StylesApplyReceipt;
|
|
137
161
|
apply(input: StylesApplyInput, options?: StylesApplyOptions): StylesApplyReceipt;
|
|
138
162
|
/** Read the normalized style catalogue for discovery and quick-gallery UI. */
|
|
139
163
|
getCatalog(input?: StylesGetCatalogInput): StylesGetCatalogResult;
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
export type { ValueSchema, StylesChannel, StylesScope, MergeStrategy, PropertyDefinition } from './registry.js';
|
|
7
7
|
export { PROPERTY_REGISTRY, ALLOWED_KEYS_BY_CHANNEL, EXCLUDED_KEYS, STYLE_EXCLUDED_KEYS, EXCLUDED_KEYS_BY_SCOPE, SCOPE_LABEL, XML_PATH_BY_CHANNEL, getPropertyDefinition, ST_VERTICAL_ALIGN_RUN, ST_EM, ST_TEXT_ALIGNMENT, ST_TEXT_DIRECTION, ST_TEXTBOX_TIGHT_WRAP, ST_TEXT_TRANSFORM, ST_JUSTIFICATION, } from './registry.js';
|
|
8
8
|
export { toJsonSchema, buildPatchSchema, buildStateSchema } from './schema.js';
|
|
9
|
-
export type { StylesBooleanState, StylesNumberState, StylesEnumState, StylesObjectState, StylesArrayState, StylesRunPatch, StylesParagraphPatch, StylesTargetResolution, StylesApplyRunInput, StylesApplyParagraphInput, StylesApplyInput, StylesApplyOptions, StylesStateMap, StylesApplyReceiptSuccess, StylesApplyReceiptFailure, StylesApplyReceipt, StylesAdapter, NormalizedStylesApplyOptions, StylesApi, } from './apply.js';
|
|
10
|
-
export { executeStylesApply } from './apply.js';
|
|
9
|
+
export type { StylesBooleanState, StylesNumberState, StylesEnumState, StylesObjectState, StylesArrayState, StylesRunPatch, StylesParagraphPatch, StylesTargetResolution, StylesApplyRunInput, StylesApplyParagraphInput, StylesApplyStyleRunInput, StylesStyleRunPatch, StylesDocDefaultsResolution, StylesStyleResolution, StylesApplyInput, StylesApplyOptions, StylesStateMap, StylesApplyReceiptSuccess, StylesApplyReceiptFailure, StylesApplyReceipt, StylesAdapter, NormalizedStylesApplyOptions, StylesApi, } from './apply.js';
|
|
10
|
+
export { STYLE_RUN_XML_PATH, executeStylesApply } from './apply.js';
|
|
11
11
|
export type { StyleRunPatch, StyleConflictPolicy, StyleChannelState, StylesCreateParagraphInput, StylesCreateCharacterInput, StylesCreateInput, StylesCreateOptions, NormalizedStylesCreateOptions, StylesCreateResolution, StylesCreateReceiptSuccess, StylesCreateReceiptFailure, StylesCreateReceipt, StylesCreateAdapter, StylesCreateApi, } from './create.js';
|
|
12
12
|
export { STYLE_XML_PATH, executeStylesCreate, validateStylesCreateInput, validateStylesCreateOptions, } from './create.js';
|
|
13
13
|
export type { StyleCatalogView, StyleCatalogItemType, StyleCatalogFilterType, StyleProvenance, StyleCatalogDiagnosticSeverity, StyleSourcePartStatus, StyleCatalogUsageStatus, StyleCatalogPreviewStatus, StyleCatalogViewStatus, StyleCatalogItemVisibility, StyleCatalogItemUsage, StyleCatalogItemPreview, StyleCatalogPreviewFontSource, StyleCatalogPreviewColorSource, StyleCatalogPreviewSources, StyleCatalogItem, StyleCatalogDefaults, StyleCatalogDiagnostic, StyleCatalogSourceStatus, StylesGetCatalogInput, StylesGetCatalogResult, StylesGetCatalogAdapter, } from './catalog.js';
|
|
@@ -15,4 +15,4 @@ export { STYLE_CATALOG_VIEWS, STYLE_CATALOG_FILTER_TYPES, executeStylesGetCatalo
|
|
|
15
15
|
export type { StylesGetThemeInput, StylesThemeSourceStatus, StylesGetThemeResult, StylesGetThemeAdapter, } from './theme.js';
|
|
16
16
|
export { executeStylesGetTheme, validateStylesGetThemeInput } from './theme.js';
|
|
17
17
|
export type { PatchKeyClassification } from './validation.js';
|
|
18
|
-
export { validateValue, classifyPatchKey, validatePatchObject } from './validation.js';
|
|
18
|
+
export { validateValue, classifyPatchKey, validatePatchObject, validateStylesApplyInput } from './validation.js';
|
|
@@ -10,7 +10,9 @@ export declare function toJsonSchema(schema: ValueSchema): JsonSchema;
|
|
|
10
10
|
* a schema that advertised them on `docDefaults` would describe an input the
|
|
11
11
|
* validator rejects.
|
|
12
12
|
*/
|
|
13
|
-
export declare function buildPatchSchema(channel: StylesChannel, scope?: StylesScope
|
|
13
|
+
export declare function buildPatchSchema(channel: StylesChannel, scope?: StylesScope, options?: {
|
|
14
|
+
nullable?: boolean;
|
|
15
|
+
}): JsonSchema;
|
|
14
16
|
/**
|
|
15
17
|
* Builds a JSON Schema for the before/after state map of a given scope.
|
|
16
18
|
*
|
|
@@ -13,6 +13,13 @@ export type StylesApplyInputShape = {
|
|
|
13
13
|
channel: StylesChannel;
|
|
14
14
|
};
|
|
15
15
|
patch: Record<string, unknown>;
|
|
16
|
+
} | {
|
|
17
|
+
target: {
|
|
18
|
+
scope: 'style';
|
|
19
|
+
styleId: string;
|
|
20
|
+
channel: 'run';
|
|
21
|
+
};
|
|
22
|
+
patch: Record<string, unknown>;
|
|
16
23
|
};
|
|
17
24
|
export declare function validateStylesApplyInput(input: unknown): asserts input is StylesApplyInputShape;
|
|
18
25
|
export declare function validateStylesApplyOptions(options: unknown): void;
|
|
@@ -36,12 +43,6 @@ export type PatchKeyClassification = {
|
|
|
36
43
|
* cross-channel lookups.
|
|
37
44
|
*/
|
|
38
45
|
export declare function classifyPatchKey(key: string, channel: StylesChannel, scope?: StylesScope): PatchKeyClassification;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
* Shared by `styles.apply` (scope `docDefaults`) and `styles.create` (scope
|
|
43
|
-
* `style`); `field` names the caller's own input path so the error points at
|
|
44
|
-
* `patch` or at `run` / `paragraph` rather than at whichever one happened to
|
|
45
|
-
* write this code.
|
|
46
|
-
*/
|
|
47
|
-
export declare function validatePatchObject(patch: Record<string, unknown>, channel: StylesChannel, scope: StylesScope, field: string): void;
|
|
46
|
+
export declare function validatePatchObject(patch: Record<string, unknown>, channel: StylesChannel, scope: StylesScope, field: string, options?: {
|
|
47
|
+
allowNull?: boolean;
|
|
48
|
+
}): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BlockNavigationAddress, EntityAddress, SelectionTarget, TextAddress, TrackedChangeAddress } from './address.js';
|
|
1
|
+
import { BlockNavigationAddress, EntityAddress, SelectionTarget, TextAddress, TextTarget, TrackedChangeAddress } from './address.js';
|
|
2
2
|
import { BlockNodeAddress } from './base.js';
|
|
3
3
|
import { BookmarkAddress } from '../bookmarks/bookmarks.types.js';
|
|
4
4
|
import { StoryLocator } from './story.types.js';
|
|
@@ -131,6 +131,7 @@ export interface ReceiptEffects {
|
|
|
131
131
|
insertedText?: TextMutationEffect[];
|
|
132
132
|
/** Blocks created by the mutation, in document order. */
|
|
133
133
|
insertedBlocks?: BlockMutationEffect[];
|
|
134
|
+
resultText?: TextTarget;
|
|
134
135
|
}
|
|
135
136
|
export type ReceiptSuccess = {
|
|
136
137
|
/** Caller correlation for this commit. Never replayed as the original edit on Undo/Redo. */
|
|
@@ -1,12 +1,47 @@
|
|
|
1
1
|
import { DocumentApiSurface } from '../index.js';
|
|
2
|
-
import { ReceiptSuccess } from './receipt.js';
|
|
2
|
+
import { ReceiptFailureResult, ReceiptSuccess } from './receipt.js';
|
|
3
|
+
import { PlainTextInsertInput } from '../insert/insert.js';
|
|
4
|
+
import { ParagraphTextReplaceInput, ReplaceMutationOptions, TextReplaceInput } from '../replace/replace.js';
|
|
5
|
+
import { MutationOptions, TrackedTextMutationOptions } from '../write/write.js';
|
|
6
|
+
import { BodyStoryLocator } from './story.types.js';
|
|
3
7
|
type TemporaryCall<Name extends string, Method extends (...args: never[]) => unknown> = {
|
|
4
8
|
operation: Name;
|
|
5
9
|
input: Parameters<Method>[0];
|
|
6
10
|
options?: Parameters<Method>[1];
|
|
7
11
|
};
|
|
12
|
+
type TemporaryText<Name extends 'insert' | 'replace', Input> = {
|
|
13
|
+
operation: Name;
|
|
14
|
+
input: Input;
|
|
15
|
+
options?: MutationOptions & {
|
|
16
|
+
author?: never;
|
|
17
|
+
};
|
|
18
|
+
} | {
|
|
19
|
+
operation: Name;
|
|
20
|
+
input: Exclude<Input, {
|
|
21
|
+
target: BodyStoryLocator;
|
|
22
|
+
}>;
|
|
23
|
+
options: TrackedTextMutationOptions;
|
|
24
|
+
};
|
|
25
|
+
export interface TemporaryOperationResultTarget {
|
|
26
|
+
kind: 'operationResult';
|
|
27
|
+
operationId: string;
|
|
28
|
+
}
|
|
29
|
+
type CommentsCreate = DocumentApiSurface['comments']['create'];
|
|
30
|
+
type TemporaryCommentInput = Omit<Parameters<CommentsCreate>[0], 'target'> & {
|
|
31
|
+
target?: Parameters<CommentsCreate>[0]['target'] | TemporaryOperationResultTarget;
|
|
32
|
+
};
|
|
8
33
|
/** Operations run in order against the temporary document, as one atomic update. */
|
|
9
|
-
export type TemporaryMutationOperation =
|
|
34
|
+
export type TemporaryMutationOperation = {
|
|
35
|
+
id?: string;
|
|
36
|
+
} & (TemporaryText<'insert', PlainTextInsertInput> | TemporaryText<'replace', TextReplaceInput> | {
|
|
37
|
+
operation: 'replace';
|
|
38
|
+
input: ParagraphTextReplaceInput;
|
|
39
|
+
options?: ReplaceMutationOptions;
|
|
40
|
+
} | TemporaryCall<'delete', DocumentApiSurface['delete']> | TemporaryCall<'blocks.delete', DocumentApiSurface['blocks']['delete']> | TemporaryCall<'trackChanges.decide', DocumentApiSurface['trackChanges']['decide']> | {
|
|
41
|
+
operation: 'comments.create';
|
|
42
|
+
input: TemporaryCommentInput;
|
|
43
|
+
options?: Parameters<CommentsCreate>[1];
|
|
44
|
+
});
|
|
10
45
|
export interface TemporaryMutationInput {
|
|
11
46
|
/** Host tag echoed on every temporary mutation and its rollback/commit receipt. */
|
|
12
47
|
tag: string;
|
|
@@ -39,11 +74,11 @@ export interface TemporaryMutationMetadata {
|
|
|
39
74
|
tag: string;
|
|
40
75
|
onNativeEdit?: 'cancel' | 'preserve';
|
|
41
76
|
}
|
|
42
|
-
export type TemporaryMutationReceipt = ReceiptSuccess & {
|
|
77
|
+
export type TemporaryMutationReceipt = (ReceiptSuccess & {
|
|
43
78
|
temporary: TemporaryMutationMetadata;
|
|
44
79
|
revision: {
|
|
45
80
|
before: string;
|
|
46
81
|
after: string;
|
|
47
82
|
};
|
|
48
|
-
};
|
|
83
|
+
}) | ReceiptFailureResult;
|
|
49
84
|
export {};
|
|
@@ -197,8 +197,7 @@ export declare function getParagraphInlineDirection(attrs: {
|
|
|
197
197
|
*
|
|
198
198
|
* Prefers the resolved {@link TableDirectionContext} when present, falls
|
|
199
199
|
* back to the legacy `tableProperties.rightToLeft` (or `bidiVisual` alias)
|
|
200
|
-
* for compatibility.
|
|
201
|
-
* retirement signal.
|
|
200
|
+
* for compatibility.
|
|
202
201
|
*
|
|
203
202
|
* Per ECMA-376 §17.4.1, `w:bidiVisual` affects only cell ordering and
|
|
204
203
|
* table-visual properties. Cell paragraph inline direction is independent;
|
|
@@ -111,8 +111,6 @@ export type ResolvedGroupItem = {
|
|
|
111
111
|
/**
|
|
112
112
|
* A resolved fragment wrapper item.
|
|
113
113
|
* Carries positioning and metadata needed to create the fragment's DOM wrapper.
|
|
114
|
-
* Inner content rendering is delegated to the Fragment-based render path via
|
|
115
|
-
* fragmentIndex; see the compat-fallback note on that field.
|
|
116
114
|
*/
|
|
117
115
|
export type ResolvedFragmentItem = {
|
|
118
116
|
kind: 'fragment';
|
|
@@ -138,14 +136,6 @@ export type ResolvedFragmentItem = {
|
|
|
138
136
|
fragment: Fragment;
|
|
139
137
|
/** Block ID. Written to data-block-id. */
|
|
140
138
|
blockId: string;
|
|
141
|
-
/**
|
|
142
|
-
* Index back into page.fragments.
|
|
143
|
-
*
|
|
144
|
-
* AIDEV-NOTE: compat-fallback. The painter currently reads inner content from
|
|
145
|
-
* Fragment via this index because ResolvedFragmentItem does not carry full
|
|
146
|
-
* content yet. Becomes unused once paint items are self-describing; do not
|
|
147
|
-
* promote this to a permanent API surface.
|
|
148
|
-
*/
|
|
149
139
|
fragmentIndex: number;
|
|
150
140
|
/** ProseMirror start position for click-to-position mapping. */
|
|
151
141
|
pmStart?: number;
|
|
@@ -280,14 +270,6 @@ export type ResolvedTableItem = {
|
|
|
280
270
|
zIndex?: number;
|
|
281
271
|
/** Block ID — written to data-block-id. */
|
|
282
272
|
blockId: string;
|
|
283
|
-
/**
|
|
284
|
-
* Index back into page.fragments.
|
|
285
|
-
*
|
|
286
|
-
* AIDEV-NOTE: compat-fallback. The painter currently reads inner content from
|
|
287
|
-
* Fragment via this index because ResolvedFragmentItem does not carry full
|
|
288
|
-
* content yet. Becomes unused once paint items are self-describing; do not
|
|
289
|
-
* promote this to a permanent API surface.
|
|
290
|
-
*/
|
|
291
273
|
fragmentIndex: number;
|
|
292
274
|
/** Source TableFragment back-pointer (see ResolvedFragmentItem.fragment). */
|
|
293
275
|
fragment: Fragment;
|
|
@@ -357,14 +339,6 @@ export type ResolvedImageItem = {
|
|
|
357
339
|
zIndex?: number;
|
|
358
340
|
/** Block ID — written to data-block-id. */
|
|
359
341
|
blockId: string;
|
|
360
|
-
/**
|
|
361
|
-
* Index back into page.fragments.
|
|
362
|
-
*
|
|
363
|
-
* AIDEV-NOTE: compat-fallback. The painter currently reads inner content from
|
|
364
|
-
* Fragment via this index because ResolvedFragmentItem does not carry full
|
|
365
|
-
* content yet. Becomes unused once paint items are self-describing; do not
|
|
366
|
-
* promote this to a permanent API surface.
|
|
367
|
-
*/
|
|
368
342
|
fragmentIndex: number;
|
|
369
343
|
/** Source ImageFragment back-pointer (see ResolvedFragmentItem.fragment). */
|
|
370
344
|
fragment: Fragment;
|
|
@@ -426,14 +400,6 @@ export type ResolvedDrawingItem = {
|
|
|
426
400
|
zIndex?: number;
|
|
427
401
|
/** Block ID — written to data-block-id. */
|
|
428
402
|
blockId: string;
|
|
429
|
-
/**
|
|
430
|
-
* Index back into page.fragments.
|
|
431
|
-
*
|
|
432
|
-
* AIDEV-NOTE: compat-fallback. The painter currently reads inner content from
|
|
433
|
-
* Fragment via this index because ResolvedFragmentItem does not carry full
|
|
434
|
-
* content yet. Becomes unused once paint items are self-describing; do not
|
|
435
|
-
* promote this to a permanent API surface.
|
|
436
|
-
*/
|
|
437
403
|
fragmentIndex: number;
|
|
438
404
|
/** Source DrawingFragment back-pointer (see ResolvedFragmentItem.fragment). */
|
|
439
405
|
fragment: Fragment;
|
|
@@ -35,13 +35,6 @@ export type LayoutHit = {
|
|
|
35
35
|
sourceAnchor?: SourceAnchor;
|
|
36
36
|
/** Diagnostics for partially supported or rejected hits. */
|
|
37
37
|
diagnostics?: LayoutHitDiagnostic[];
|
|
38
|
-
/**
|
|
39
|
-
* Legacy PM-shaped position hit.
|
|
40
|
-
*
|
|
41
|
-
* AIDEV-NOTE: compat-fallback - callers may still consume `pmPosition`.
|
|
42
|
-
* Retire once providers stop relying on PM positions to map this hit back to
|
|
43
|
-
* a document ref. Do not gate new editor-neutral behavior on this field.
|
|
44
|
-
*/
|
|
45
38
|
legacyPm?: PositionHit;
|
|
46
39
|
};
|
|
47
40
|
export type LayoutHitDiagnostic = {
|
|
@@ -302,7 +302,6 @@ export type LayoutDocumentContinuation = {
|
|
|
302
302
|
}): Promise<LayoutContinuationBatch>;
|
|
303
303
|
dispose(): void;
|
|
304
304
|
};
|
|
305
|
-
/** AIDEV-NOTE: The handle owns one live paginator; advancing never replays a stopped prefix. */
|
|
306
305
|
export declare function createLayoutDocumentContinuation(blocks: FlowBlock[], measures: Measure[], options?: LayoutOptions, execution?: LayoutExecutionControl): LayoutDocumentContinuation;
|
|
307
306
|
export type LayoutRangeBoundaryPolicy = 'conservative-context' | 'overscan' | 'degraded-on-incomplete-state';
|
|
308
307
|
export type LayoutRangeExactness = 'exact' | 'pending-layout' | 'degraded-unsupported' | 'stale';
|
|
@@ -26,9 +26,6 @@ export declare const RTL_DATE_LIKE_TOKEN_RE: RegExp;
|
|
|
26
26
|
* FE70-FEFF Arabic-B). The block range covers Hebrew, Arabic, Syriac, NKo,
|
|
27
27
|
* etc.; the Script properties add presentation forms without including
|
|
28
28
|
* noncharacters (FDD0-FDEF) or the BOM (FEFF).
|
|
29
|
-
*
|
|
30
|
-
* AIDEV-NOTE: also used by editing/runtime mixed-bidi handling. Consolidating
|
|
31
|
-
* crosses a layer boundary; tracked under SD-3169 follow-ups.
|
|
32
29
|
*/
|
|
33
30
|
export declare const STRONG_RTL_CHAR_RE: RegExp;
|
|
34
31
|
/**
|
package/dist/public/ui-react.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D1eOhAjv.cjs");
|
|
3
3
|
const require_slice_source = require("../chunks/slice-source-CFaqq0Vo.cjs");
|
|
4
4
|
let react = require("react");
|
|
5
5
|
let use_sync_external_store_shim = require("use-sync-external-store/shim");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-B29zw5qD.es.js";
|
|
2
2
|
import { t as toSliceSource } from "../chunks/slice-source-gfOhG2MW.es.js";
|
|
3
3
|
import { createContext, createElement, useCallback, useContext, useEffect, useRef, useState } from "react";
|
|
4
4
|
import { useSyncExternalStore } from "use-sync-external-store/shim";
|
package/dist/public/ui-vue.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D1eOhAjv.cjs");
|
|
3
3
|
const require_slice_source = require("../chunks/slice-source-CFaqq0Vo.cjs");
|
|
4
4
|
let superdoc_entry_vue = require("vue");
|
|
5
5
|
//#region src/public/ui/vue.ts
|
package/dist/public/ui-vue.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-B29zw5qD.es.js";
|
|
2
2
|
import { t as toSliceSource } from "../chunks/slice-source-gfOhG2MW.es.js";
|
|
3
3
|
import { computed, inject, onScopeDispose, provide, shallowRef, toRaw, toValue, watch } from "vue";
|
|
4
4
|
//#region src/public/ui/vue.ts
|
package/dist/public/ui.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D1eOhAjv.cjs");
|
|
3
3
|
//#region ../document-api/src/types/receipt.ts
|
|
4
4
|
/** Read a known failure.details.reason without assuming every failure has one. */
|
|
5
5
|
function getDocumentApiRejectionReason(details) {
|
package/dist/public/ui.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { f as shallowEqual, o as BUILT_IN_COMMAND_IDS, t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { f as shallowEqual, o as BUILT_IN_COMMAND_IDS, t as createSuperDocUI } from "../chunks/create-super-doc-ui-B29zw5qD.es.js";
|
|
2
2
|
//#region ../document-api/src/types/receipt.ts
|
|
3
3
|
/** Read a known failure.details.reason without assuming every failure has one. */
|
|
4
4
|
function getDocumentApiRejectionReason(details) {
|