@a3s-lab/office 0.26.0 → 0.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +75 -2
- package/dist/0~4595.js +16 -2
- package/dist/0~5093.js +463 -201
- package/dist/0~6090.js +77 -77
- package/dist/{0~2805.js → 0~7043.js} +305 -2
- package/dist/0~document-editor.js +2451 -985
- package/dist/0~spreadsheet-editor.js +1324 -378
- package/dist/0~work-docx-export.js +492 -10
- package/dist/0~work-docx-import.js +171 -98
- package/dist/0~work-office-diagnostics.js +198 -4
- package/dist/{164.js → 1544.js} +1083 -785
- package/dist/4104.js +145 -29
- package/dist/6282.js +1774 -384
- package/dist/core.js +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/features/work/editors/document-command-catalog.d.ts +102 -0
- package/dist/internal/features/work/editors/document-font-dialog-model.d.ts +83 -0
- package/dist/internal/features/work/editors/document-font-dialog-script-font-model.d.ts +18 -0
- package/dist/internal/features/work/editors/document-font-dialog.d.ts +9 -0
- package/dist/internal/features/work/editors/document-home-ribbon.d.ts +2 -1
- package/dist/internal/features/work/editors/document-page-chrome-editor.d.ts +6 -0
- package/dist/internal/features/work/editors/document-page-chrome-ribbon.d.ts +2 -1
- package/dist/internal/features/work/editors/document-strike-ribbon.d.ts +7 -0
- package/dist/internal/features/work/editors/document-text-case-ribbon.d.ts +4 -0
- package/dist/internal/features/work/editors/document-toolbar.d.ts +3 -1
- package/dist/internal/features/work/editors/document-underline-ribbon.d.ts +9 -0
- package/dist/internal/features/work/editors/document-wps-shortcuts.d.ts +1 -0
- package/dist/internal/features/work/editors/spreadsheet-cell-fill-format.d.ts +11 -0
- package/dist/internal/features/work/editors/spreadsheet-cell-format.d.ts +2 -1
- package/dist/internal/features/work/editors/spreadsheet-format-cells-dialog-model.d.ts +13 -2
- package/dist/internal/features/work/editors/spreadsheet-format-cells-fill-panel.d.ts +13 -0
- package/dist/internal/features/work/editors/spreadsheet-format-cells-fill-preview.d.ts +6 -0
- package/dist/internal/features/work/editors/spreadsheet-format-painter.d.ts +1 -1
- package/dist/internal/features/work/editors/work-office-chrome.d.ts +9 -1
- package/dist/internal/features/work/work-document-character-formatting.d.ts +16 -1
- package/dist/internal/features/work/work-document-character-position.d.ts +9 -0
- package/dist/internal/features/work/work-document-character-scale.d.ts +8 -0
- package/dist/internal/features/work/work-document-character-spacing.d.ts +8 -0
- package/dist/internal/features/work/work-document-emphasis.d.ts +7 -0
- package/dist/internal/features/work/work-document-equations.d.ts +2 -1
- package/dist/internal/features/work/work-document-format-changes.d.ts +16 -2
- package/dist/internal/features/work/work-document-hidden-text.d.ts +5 -0
- package/dist/internal/features/work/work-document-kerning.d.ts +10 -0
- package/dist/internal/features/work/work-document-script-font-extension.d.ts +2 -0
- package/dist/internal/features/work/work-document-script-fonts.d.ts +51 -0
- package/dist/internal/features/work/work-document-strike.d.ts +21 -0
- package/dist/internal/features/work/work-document-text-case.d.ts +10 -0
- package/dist/internal/features/work/work-document-underline.d.ts +37 -0
- package/dist/internal/features/work/work-document-word-line-metrics.d.ts +12 -0
- package/dist/internal/features/work/work-docx-character-position.d.ts +2 -0
- package/dist/internal/features/work/work-docx-character-scale.d.ts +2 -0
- package/dist/internal/features/work/work-docx-character-spacing.d.ts +4 -0
- package/dist/internal/features/work/work-docx-emphasis-diagnostics.d.ts +3 -0
- package/dist/internal/features/work/work-docx-emphasis.d.ts +14 -0
- package/dist/internal/features/work/work-docx-hidden-text-diagnostics.d.ts +3 -0
- package/dist/internal/features/work/work-docx-hidden-text-export.d.ts +16 -0
- package/dist/internal/features/work/work-docx-hidden-text.d.ts +11 -0
- package/dist/internal/features/work/work-docx-kerning-diagnostics.d.ts +3 -0
- package/dist/internal/features/work/work-docx-kerning.d.ts +14 -0
- package/dist/internal/features/work/work-docx-run-fonts-diagnostics.d.ts +3 -0
- package/dist/internal/features/work/work-docx-run-fonts-export.d.ts +14 -0
- package/dist/internal/features/work/work-docx-run-fonts.d.ts +13 -0
- package/dist/internal/features/work/work-docx-run-formatting-import.d.ts +23 -2
- package/dist/internal/features/work/work-docx-run-script-font-import.d.ts +9 -0
- package/dist/internal/features/work/work-docx-strike.d.ts +8 -0
- package/dist/internal/features/work/work-docx-theme-reference.d.ts +1 -1
- package/dist/internal/features/work/work-docx-twips.d.ts +6 -0
- package/dist/internal/features/work/work-docx-underline.d.ts +3 -0
- package/dist/internal/features/work/work-spreadsheet-gradient-fill-canvas.d.ts +10 -0
- package/dist/internal/features/work/work-spreadsheet-native-fill-canvas.d.ts +8 -0
- package/dist/internal/features/work/work-spreadsheet-pattern-fill-canvas.d.ts +8 -0
- package/dist/internal/features/work/work-xlsx-cell-style-origin.d.ts +2 -1
- package/dist/internal/features/work/work-xlsx-cell-style-writer.d.ts +3 -0
- package/dist/internal/features/work/work-xlsx-cell-styles.d.ts +4 -0
- package/dist/internal/features/work/work-xlsx-gradient-fill.d.ts +31 -0
- package/dist/internal/features/work/work-xlsx-native-fill.d.ts +17 -0
- package/dist/internal/features/work/work-xlsx-pattern-fill.d.ts +21 -0
- package/dist/office-kernel.wasm +0 -0
- package/dist/styles.css +770 -80
- package/docs/latest/en/browser-editor-architecture.md +10 -0
- package/package.json +32 -1
package/dist/core.js
CHANGED
|
@@ -7,6 +7,6 @@ export { createArtifact, createOfficeId, officeTemplates } from "./5184.js";
|
|
|
7
7
|
export { createOfficeDocumentCollaborationBinding, initializeOfficeDocumentCollaboration, officeDocumentCollaborationFragment, readOfficeDocumentCollaboration } from "./6282.js";
|
|
8
8
|
export { createOfficeMarkdownCollaborationBinding, initializeOfficeMarkdownCollaboration, readOfficeMarkdownCollaboration, replaceOfficeMarkdownCollaboration } from "./2591.js";
|
|
9
9
|
export { createOfficePresentationCollaborationBinding, initializeOfficePresentationCollaboration, readOfficePresentationCollaboration, replaceOfficePresentationCollaboration } from "./4560.js";
|
|
10
|
-
export { createOfficeSpreadsheetCollaborationBinding, initializeOfficeSpreadsheetCollaboration, readOfficeSpreadsheetCollaboration, replaceOfficeSpreadsheetCollaboration } from "./
|
|
10
|
+
export { createOfficeSpreadsheetCollaborationBinding, initializeOfficeSpreadsheetCollaboration, readOfficeSpreadsheetCollaboration, replaceOfficeSpreadsheetCollaboration } from "./1544.js";
|
|
11
11
|
export { normalizeWorkSpreadsheetBubbleScale, normalizeWorkSpreadsheetBubbleSizeRepresents, normalizeWorkSpreadsheetChartAxisGroup, normalizeWorkSpreadsheetCombinationSeriesType, normalizeWorkSpreadsheetDataLabelPosition, normalizeWorkSpreadsheetDataLabels, normalizeWorkSpreadsheetDoughnutHoleSize, normalizeWorkSpreadsheetErrorBars, normalizeWorkSpreadsheetRadarStyle, normalizeWorkSpreadsheetScatterStyle, normalizeWorkSpreadsheetTrendline, normalizeWorkSpreadsheetTrendlineType, workSpreadsheetChartSupportsAxes, workSpreadsheetChartSupportsErrorBars, workSpreadsheetChartSupportsTrendlines, workSpreadsheetChartTypeLabel, workSpreadsheetChartUsesNumericXAxis, workSpreadsheetCombinationSeriesTypeLabel, workSpreadsheetDataLabelPositionLabel, workSpreadsheetErrorBarTypeLabel, workSpreadsheetErrorBarValueTypeLabel, workSpreadsheetTrendlineTypeLabel } from "./8715.js";
|
|
12
12
|
export { core_OFFICE_COLLABORATION_VERSION as OFFICE_COLLABORATION_VERSION };
|
package/dist/index.js
CHANGED
|
@@ -10,6 +10,6 @@ export { createArtifact, createOfficeId, officeTemplates } from "./5184.js";
|
|
|
10
10
|
export { createOfficeDocumentCollaborationBinding, initializeOfficeDocumentCollaboration, officeDocumentCollaborationFragment, readOfficeDocumentCollaboration } from "./6282.js";
|
|
11
11
|
export { createOfficeMarkdownCollaborationBinding, initializeOfficeMarkdownCollaboration, readOfficeMarkdownCollaboration, replaceOfficeMarkdownCollaboration } from "./2591.js";
|
|
12
12
|
export { createOfficePresentationCollaborationBinding, initializeOfficePresentationCollaboration, readOfficePresentationCollaboration, replaceOfficePresentationCollaboration } from "./4560.js";
|
|
13
|
-
export { createOfficeSpreadsheetCollaborationBinding, initializeOfficeSpreadsheetCollaboration, readOfficeSpreadsheetCollaboration, replaceOfficeSpreadsheetCollaboration } from "./
|
|
13
|
+
export { createOfficeSpreadsheetCollaborationBinding, initializeOfficeSpreadsheetCollaboration, readOfficeSpreadsheetCollaboration, replaceOfficeSpreadsheetCollaboration } from "./1544.js";
|
|
14
14
|
export { normalizeWorkSpreadsheetBubbleScale, normalizeWorkSpreadsheetBubbleSizeRepresents, normalizeWorkSpreadsheetChartAxisGroup, normalizeWorkSpreadsheetCombinationSeriesType, normalizeWorkSpreadsheetDataLabelPosition, normalizeWorkSpreadsheetDataLabels, normalizeWorkSpreadsheetDoughnutHoleSize, normalizeWorkSpreadsheetErrorBars, normalizeWorkSpreadsheetRadarStyle, normalizeWorkSpreadsheetScatterStyle, normalizeWorkSpreadsheetTrendline, normalizeWorkSpreadsheetTrendlineType, workSpreadsheetChartSupportsAxes, workSpreadsheetChartSupportsErrorBars, workSpreadsheetChartSupportsTrendlines, workSpreadsheetChartTypeLabel, workSpreadsheetChartUsesNumericXAxis, workSpreadsheetCombinationSeriesTypeLabel, workSpreadsheetDataLabelPositionLabel, workSpreadsheetErrorBarTypeLabel, workSpreadsheetErrorBarValueTypeLabel, workSpreadsheetTrendlineTypeLabel } from "./8715.js";
|
|
15
15
|
export { src_DOCUMENT_SNAPSHOT_VERSION as DOCUMENT_SNAPSHOT_VERSION, src_DOCUMENT_SOURCE_VERSION as DOCUMENT_SOURCE_VERSION, src_OFFICE_COLLABORATION_VERSION as OFFICE_COLLABORATION_VERSION };
|
|
@@ -143,6 +143,20 @@ export declare const documentCommandCatalog: {
|
|
|
143
143
|
readonly editor: readonly ["Mod-Shift-v"];
|
|
144
144
|
};
|
|
145
145
|
};
|
|
146
|
+
readonly fontDialog: {
|
|
147
|
+
readonly id: "font.dialog";
|
|
148
|
+
readonly label: "字体高级设置";
|
|
149
|
+
readonly location: {
|
|
150
|
+
readonly area: "ribbon";
|
|
151
|
+
readonly tab: "home";
|
|
152
|
+
readonly group: "font";
|
|
153
|
+
};
|
|
154
|
+
readonly shortcut: {
|
|
155
|
+
readonly label: "Cmd/Ctrl+D";
|
|
156
|
+
readonly aria: "Control+D Meta+D";
|
|
157
|
+
readonly editor: readonly ["Mod-d"];
|
|
158
|
+
};
|
|
159
|
+
};
|
|
146
160
|
readonly formatPainter: {
|
|
147
161
|
readonly id: "clipboard.formatPainter";
|
|
148
162
|
readonly label: "格式刷";
|
|
@@ -194,6 +208,34 @@ export declare const documentCommandCatalog: {
|
|
|
194
208
|
readonly editor: readonly ["Mod-u"];
|
|
195
209
|
};
|
|
196
210
|
};
|
|
211
|
+
readonly doubleUnderline: {
|
|
212
|
+
readonly id: "font.doubleUnderline";
|
|
213
|
+
readonly label: "双下划线";
|
|
214
|
+
readonly location: {
|
|
215
|
+
readonly area: "ribbon";
|
|
216
|
+
readonly tab: "home";
|
|
217
|
+
readonly group: "font";
|
|
218
|
+
};
|
|
219
|
+
readonly shortcut: {
|
|
220
|
+
readonly label: "Cmd/Ctrl+Shift+D";
|
|
221
|
+
readonly aria: "Control+Shift+D Meta+Shift+D";
|
|
222
|
+
readonly editor: readonly ["Mod-Shift-d"];
|
|
223
|
+
};
|
|
224
|
+
};
|
|
225
|
+
readonly wordsUnderline: {
|
|
226
|
+
readonly id: "font.wordsUnderline";
|
|
227
|
+
readonly label: "仅字下划线";
|
|
228
|
+
readonly location: {
|
|
229
|
+
readonly area: "ribbon";
|
|
230
|
+
readonly tab: "home";
|
|
231
|
+
readonly group: "font";
|
|
232
|
+
};
|
|
233
|
+
readonly shortcut: {
|
|
234
|
+
readonly label: "Cmd/Ctrl+Shift+W";
|
|
235
|
+
readonly aria: "Control+Shift+W Meta+Shift+W";
|
|
236
|
+
readonly editor: readonly ["Mod-Shift-w"];
|
|
237
|
+
};
|
|
238
|
+
};
|
|
197
239
|
readonly strike: {
|
|
198
240
|
readonly id: "font.strike";
|
|
199
241
|
readonly label: "删除线";
|
|
@@ -203,6 +245,43 @@ export declare const documentCommandCatalog: {
|
|
|
203
245
|
readonly group: "font";
|
|
204
246
|
};
|
|
205
247
|
};
|
|
248
|
+
readonly doubleStrike: {
|
|
249
|
+
readonly id: "font.doubleStrike";
|
|
250
|
+
readonly label: "双删除线";
|
|
251
|
+
readonly location: {
|
|
252
|
+
readonly area: "ribbon";
|
|
253
|
+
readonly tab: "home";
|
|
254
|
+
readonly group: "font";
|
|
255
|
+
};
|
|
256
|
+
};
|
|
257
|
+
readonly allCaps: {
|
|
258
|
+
readonly id: "font.allCaps";
|
|
259
|
+
readonly label: "全部大写";
|
|
260
|
+
readonly location: {
|
|
261
|
+
readonly area: "ribbon";
|
|
262
|
+
readonly tab: "home";
|
|
263
|
+
readonly group: "font";
|
|
264
|
+
};
|
|
265
|
+
readonly shortcut: {
|
|
266
|
+
readonly label: "Cmd/Ctrl+Shift+A";
|
|
267
|
+
readonly aria: "Control+Shift+A Meta+Shift+A";
|
|
268
|
+
readonly editor: readonly ["Mod-Shift-a"];
|
|
269
|
+
};
|
|
270
|
+
};
|
|
271
|
+
readonly smallCaps: {
|
|
272
|
+
readonly id: "font.smallCaps";
|
|
273
|
+
readonly label: "小型大写";
|
|
274
|
+
readonly location: {
|
|
275
|
+
readonly area: "ribbon";
|
|
276
|
+
readonly tab: "home";
|
|
277
|
+
readonly group: "font";
|
|
278
|
+
};
|
|
279
|
+
readonly shortcut: {
|
|
280
|
+
readonly label: "Cmd/Ctrl+Shift+K";
|
|
281
|
+
readonly aria: "Control+Shift+K Meta+Shift+K";
|
|
282
|
+
readonly editor: readonly ["Mod-Shift-k"];
|
|
283
|
+
};
|
|
284
|
+
};
|
|
206
285
|
readonly subscript: {
|
|
207
286
|
readonly id: "font.subscript";
|
|
208
287
|
readonly label: "下标";
|
|
@@ -240,6 +319,20 @@ export declare const documentCommandCatalog: {
|
|
|
240
319
|
readonly group: "font";
|
|
241
320
|
};
|
|
242
321
|
};
|
|
322
|
+
readonly hiddenText: {
|
|
323
|
+
readonly id: "font.hiddenText";
|
|
324
|
+
readonly label: "隐藏文字";
|
|
325
|
+
readonly location: {
|
|
326
|
+
readonly area: "ribbon";
|
|
327
|
+
readonly tab: "home";
|
|
328
|
+
readonly group: "font";
|
|
329
|
+
};
|
|
330
|
+
readonly shortcut: {
|
|
331
|
+
readonly label: "Cmd/Ctrl+Shift+H";
|
|
332
|
+
readonly aria: "Control+Shift+H Meta+Shift+H";
|
|
333
|
+
readonly editor: readonly ["Mod-Shift-h"];
|
|
334
|
+
};
|
|
335
|
+
};
|
|
243
336
|
readonly clearFormatting: {
|
|
244
337
|
readonly id: "font.clearFormatting";
|
|
245
338
|
readonly label: "清除格式";
|
|
@@ -519,6 +612,15 @@ export declare const documentCommandCatalog: {
|
|
|
519
612
|
readonly group: "show";
|
|
520
613
|
};
|
|
521
614
|
};
|
|
615
|
+
readonly showHiddenText: {
|
|
616
|
+
readonly id: "view.showHiddenText";
|
|
617
|
+
readonly label: "显示隐藏文字";
|
|
618
|
+
readonly location: {
|
|
619
|
+
readonly area: "ribbon";
|
|
620
|
+
readonly tab: "view";
|
|
621
|
+
readonly group: "show";
|
|
622
|
+
};
|
|
623
|
+
};
|
|
522
624
|
readonly wordCount: {
|
|
523
625
|
readonly id: "status.wordCount";
|
|
524
626
|
readonly label: "字数统计";
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import type { Editor } from '@tiptap/core';
|
|
2
|
+
import { type WorkDocumentEmphasisMark } from '../work-document-emphasis';
|
|
3
|
+
import { type DocumentFontDialogScriptFontPatch, type DocumentFontFamilySource } from './document-font-dialog-script-font-model';
|
|
4
|
+
export type { DocumentFontFamilySource } from './document-font-dialog-script-font-model';
|
|
5
|
+
export type DocumentCharacterSpacingMode = 'condensed' | 'expanded' | 'mixed' | 'normal';
|
|
6
|
+
export type DocumentCharacterPositionMode = 'lowered' | 'mixed' | 'normal' | 'raised';
|
|
7
|
+
export type DocumentCharacterScaleMode = 'mixed' | 'value';
|
|
8
|
+
export type DocumentEmphasisMarkMode = 'inherit' | 'mixed' | WorkDocumentEmphasisMark;
|
|
9
|
+
export interface DocumentFontDialogSource {
|
|
10
|
+
characterScale: {
|
|
11
|
+
mixed: boolean;
|
|
12
|
+
value: number | null;
|
|
13
|
+
};
|
|
14
|
+
characterPosition: {
|
|
15
|
+
mixed: boolean;
|
|
16
|
+
value: number | null;
|
|
17
|
+
};
|
|
18
|
+
characterSpacing: {
|
|
19
|
+
mixed: boolean;
|
|
20
|
+
value: number | null;
|
|
21
|
+
};
|
|
22
|
+
kerningThreshold: {
|
|
23
|
+
mixed: boolean;
|
|
24
|
+
value: number | null;
|
|
25
|
+
};
|
|
26
|
+
emphasisMark: {
|
|
27
|
+
mixed: boolean;
|
|
28
|
+
value: WorkDocumentEmphasisMark | null;
|
|
29
|
+
};
|
|
30
|
+
hiddenText: {
|
|
31
|
+
mixed: boolean;
|
|
32
|
+
value: boolean | null;
|
|
33
|
+
};
|
|
34
|
+
latinFont: DocumentFontFamilySource;
|
|
35
|
+
eastAsiaFont: DocumentFontFamilySource;
|
|
36
|
+
complexScriptFont: DocumentFontFamilySource;
|
|
37
|
+
fontFamily: string | null;
|
|
38
|
+
fontSize: string | null;
|
|
39
|
+
previewText: string;
|
|
40
|
+
selectedCharacters: number;
|
|
41
|
+
}
|
|
42
|
+
export interface DocumentFontDialogDraft {
|
|
43
|
+
characterScaleMode: DocumentCharacterScaleMode;
|
|
44
|
+
characterScalePercent: string;
|
|
45
|
+
characterPositionMode: DocumentCharacterPositionMode;
|
|
46
|
+
characterPositionPoints: string;
|
|
47
|
+
characterSpacingMode: DocumentCharacterSpacingMode;
|
|
48
|
+
characterSpacingPoints: string;
|
|
49
|
+
kerningEnabled: boolean;
|
|
50
|
+
kerningThresholdPoints: string;
|
|
51
|
+
emphasisMark: DocumentEmphasisMarkMode;
|
|
52
|
+
hiddenText: boolean;
|
|
53
|
+
latinFont: string;
|
|
54
|
+
eastAsiaFont: string;
|
|
55
|
+
complexScriptFont: string;
|
|
56
|
+
}
|
|
57
|
+
export interface DocumentFontDialogPatch extends DocumentFontDialogScriptFontPatch {
|
|
58
|
+
characterScalePercent?: number;
|
|
59
|
+
characterPositionHalfPoints?: number;
|
|
60
|
+
characterSpacingTwips?: number;
|
|
61
|
+
kerningThresholdHalfPoints?: number | null;
|
|
62
|
+
emphasisMark?: WorkDocumentEmphasisMark | null;
|
|
63
|
+
hiddenText?: boolean;
|
|
64
|
+
}
|
|
65
|
+
export interface DocumentFontDialogTouched {
|
|
66
|
+
characterPosition: boolean;
|
|
67
|
+
characterScale: boolean;
|
|
68
|
+
characterSpacing: boolean;
|
|
69
|
+
complexScriptFont: boolean;
|
|
70
|
+
eastAsiaFont: boolean;
|
|
71
|
+
emphasisMark: boolean;
|
|
72
|
+
hiddenText: boolean;
|
|
73
|
+
kerning: boolean;
|
|
74
|
+
latinFont: boolean;
|
|
75
|
+
}
|
|
76
|
+
export declare function documentFontDialogSource(editor: Editor): DocumentFontDialogSource;
|
|
77
|
+
export declare function createDocumentFontDialogDraft(source: DocumentFontDialogSource): DocumentFontDialogDraft;
|
|
78
|
+
export declare function documentFontDialogDraftError(draft: DocumentFontDialogDraft): string | null;
|
|
79
|
+
export declare function documentFontDialogPatch(source: DocumentFontDialogSource, draft: DocumentFontDialogDraft, touched: DocumentFontDialogTouched): DocumentFontDialogPatch;
|
|
80
|
+
export declare function applyDocumentFontDialogPatch(editor: Editor, selection: {
|
|
81
|
+
from: number;
|
|
82
|
+
to: number;
|
|
83
|
+
}, patch: DocumentFontDialogPatch): boolean;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { Editor } from '@tiptap/core';
|
|
2
|
+
import { type WorkDocumentScriptFontPatch } from '../work-document-script-fonts';
|
|
3
|
+
export interface DocumentFontFamilySource {
|
|
4
|
+
mixed: boolean;
|
|
5
|
+
value: string | null;
|
|
6
|
+
}
|
|
7
|
+
export interface DocumentFontDialogScriptFontPatch {
|
|
8
|
+
latinFont?: string | null;
|
|
9
|
+
eastAsiaFont?: string | null;
|
|
10
|
+
complexScriptFont?: string | null;
|
|
11
|
+
}
|
|
12
|
+
export declare function documentFontFamilyDraftValue(source: DocumentFontFamilySource): string;
|
|
13
|
+
export declare function appendDocumentFontDialogScriptFontPatch(patch: DocumentFontDialogScriptFontPatch, key: keyof DocumentFontDialogScriptFontPatch, source: DocumentFontFamilySource, draft: string, touched: boolean): void;
|
|
14
|
+
export declare function addDocumentScriptFontValues(latin: Map<string, string | null>, eastAsia: Map<string, string | null>, complexScript: Map<string, string | null>, attributes: Record<string, unknown>): void;
|
|
15
|
+
export declare function applyDocumentScriptFontPatch(editor: Editor, selection: {
|
|
16
|
+
from: number;
|
|
17
|
+
to: number;
|
|
18
|
+
}, scalarPatch: Readonly<Record<string, boolean | number | string | null>>, scriptFontPatch: WorkDocumentScriptFontPatch): boolean;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { WorkDocumentLayoutFont } from '../work-document-fonts';
|
|
2
|
+
import { type DocumentFontDialogPatch, type DocumentFontDialogSource } from './document-font-dialog-model';
|
|
3
|
+
export declare function DocumentFontDialog({ source, layoutFonts, restoreFocusTarget, onApply, onClose, }: {
|
|
4
|
+
source: DocumentFontDialogSource;
|
|
5
|
+
layoutFonts?: readonly WorkDocumentLayoutFont[];
|
|
6
|
+
restoreFocusTarget: () => HTMLElement | null;
|
|
7
|
+
onApply: (patch: DocumentFontDialogPatch) => boolean;
|
|
8
|
+
onClose: () => void;
|
|
9
|
+
}): import("react").JSX.Element;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { Editor } from '@tiptap/core';
|
|
2
2
|
import type { WorkDocumentLayoutFont } from '../work-document-fonts';
|
|
3
3
|
import type { DocumentFindReplaceMode } from './document-find-replace-panel';
|
|
4
|
-
export declare function DocumentHomeRibbon({ editor, findReplaceMode, layoutFonts, onFindText, }: {
|
|
4
|
+
export declare function DocumentHomeRibbon({ editor, findReplaceMode, layoutFonts, onFindText, onOpenFontDialog, }: {
|
|
5
5
|
editor: Editor;
|
|
6
6
|
findReplaceMode: DocumentFindReplaceMode | null;
|
|
7
7
|
layoutFonts?: readonly WorkDocumentLayoutFont[];
|
|
8
8
|
onFindText: (replace: boolean) => void;
|
|
9
|
+
onOpenFontDialog?: () => void;
|
|
9
10
|
}): import("react").JSX.Element | null;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { Editor, Extensions } from '@tiptap/core';
|
|
2
2
|
import { normalizeDocumentPageChromeHref } from '../work-document-page-chrome-commands';
|
|
3
|
+
import { type WorkDocumentUnderlineStyle } from '../work-document-underline';
|
|
4
|
+
import { type WorkDocumentStrikeStyle } from '../work-document-strike';
|
|
3
5
|
export type DocumentPageChromeAlignment = 'center' | 'justify' | 'left' | 'right';
|
|
4
6
|
export interface DocumentPageChromeEditorState {
|
|
5
7
|
alignment: DocumentPageChromeAlignment;
|
|
@@ -9,9 +11,13 @@ export interface DocumentPageChromeEditorState {
|
|
|
9
11
|
color: string;
|
|
10
12
|
italic: boolean;
|
|
11
13
|
link: string | null;
|
|
14
|
+
strike: boolean;
|
|
15
|
+
strikeStyle: WorkDocumentStrikeStyle;
|
|
12
16
|
subscript: boolean;
|
|
13
17
|
superscript: boolean;
|
|
14
18
|
underline: boolean;
|
|
19
|
+
underlineColor: string | null;
|
|
20
|
+
underlineStyle: WorkDocumentUnderlineStyle;
|
|
15
21
|
}
|
|
16
22
|
export interface DocumentPageChromeRichTextEditorProps {
|
|
17
23
|
autoFocus?: boolean;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import type { Editor } from '@tiptap/core';
|
|
2
2
|
export type DocumentPageChromeEditingPart = 'footer' | 'header';
|
|
3
|
-
export declare function DocumentPageChromeRibbon({ editor, editingPart, showPageNumber, onEditingPartChange, onTogglePageNumber, onClose, }: {
|
|
3
|
+
export declare function DocumentPageChromeRibbon({ editor, editingPart, showPageNumber, onEditingPartChange, onTogglePageNumber, onOpenFontDialog, onClose, }: {
|
|
4
4
|
editor: Editor;
|
|
5
5
|
editingPart: DocumentPageChromeEditingPart;
|
|
6
6
|
showPageNumber: boolean;
|
|
7
7
|
onEditingPartChange: (part: DocumentPageChromeEditingPart) => void;
|
|
8
8
|
onTogglePageNumber: () => void;
|
|
9
|
+
onOpenFontDialog?: () => void;
|
|
9
10
|
onClose: () => void;
|
|
10
11
|
}): import("react").JSX.Element;
|
|
@@ -29,6 +29,7 @@ interface DocumentToolbarProps {
|
|
|
29
29
|
navigationOpen: boolean;
|
|
30
30
|
pageColor: string;
|
|
31
31
|
showPageNumbers: boolean;
|
|
32
|
+
showHiddenText: boolean;
|
|
32
33
|
showRulers: boolean;
|
|
33
34
|
spellcheckEnabled: boolean;
|
|
34
35
|
viewMode: DocumentViewMode;
|
|
@@ -45,6 +46,7 @@ interface DocumentToolbarProps {
|
|
|
45
46
|
onOpenLayout: (target: DocumentLayoutPanelTab) => void;
|
|
46
47
|
onToggleNavigation: () => void;
|
|
47
48
|
onTogglePageNumbers: () => void;
|
|
49
|
+
onToggleHiddenText: () => void;
|
|
48
50
|
onToggleRulers: () => void;
|
|
49
51
|
onPageColorChange: (color: string) => void;
|
|
50
52
|
onToggleSpellcheck: () => void;
|
|
@@ -77,5 +79,5 @@ interface DocumentToolbarProps {
|
|
|
77
79
|
onOpenWordCount: () => void;
|
|
78
80
|
onOpenFindReplace: (mode: DocumentFindReplaceMode) => void;
|
|
79
81
|
}
|
|
80
|
-
export declare function DocumentToolbar({ editor, defaultRibbonCollapsed, reviewOnly, suggestionOnly, history, layoutOpen, layout, layoutFonts, navigationOpen, pageColor, showPageNumbers, showRulers, spellcheckEnabled, viewMode, zoom, pageChromeEditor, pageChromeEditingPart, pageChromeShowPageNumber, onRequestImage, onPageChromeEditingPartChange, onClosePageChrome, onTogglePageChromePageNumber, onToggleLayout, onLayoutChange, onOpenLayout, onToggleNavigation, onTogglePageNumbers, onToggleRulers, onPageColorChange, onToggleSpellcheck, onViewModeChange, onZoomChange, onZoomFit, onInsertSection, onInsertNote, onInsertCaption, onInsertCrossReference, citationsOpen, citationSourceCount, onToggleCitations, onInsertField, onRefreshFields, canInsertComment, onInsertComment, commentsOpen, commentCount, onToggleComments, trackChanges, changesOpen, changeCount, findReplaceMode, fileActions, onRibbonTabChange, onToggleTrackChanges, onToggleChanges, onDecideChange, onOpenWordCount, onOpenFindReplace, }: DocumentToolbarProps): import("react").JSX.Element;
|
|
82
|
+
export declare function DocumentToolbar({ editor, defaultRibbonCollapsed, reviewOnly, suggestionOnly, history, layoutOpen, layout, layoutFonts, navigationOpen, pageColor, showPageNumbers, showHiddenText, showRulers, spellcheckEnabled, viewMode, zoom, pageChromeEditor, pageChromeEditingPart, pageChromeShowPageNumber, onRequestImage, onPageChromeEditingPartChange, onClosePageChrome, onTogglePageChromePageNumber, onToggleLayout, onLayoutChange, onOpenLayout, onToggleNavigation, onTogglePageNumbers, onToggleHiddenText, onToggleRulers, onPageColorChange, onToggleSpellcheck, onViewModeChange, onZoomChange, onZoomFit, onInsertSection, onInsertNote, onInsertCaption, onInsertCrossReference, citationsOpen, citationSourceCount, onToggleCitations, onInsertField, onRefreshFields, canInsertComment, onInsertComment, commentsOpen, commentCount, onToggleComments, trackChanges, changesOpen, changeCount, findReplaceMode, fileActions, onRibbonTabChange, onToggleTrackChanges, onToggleChanges, onDecideChange, onOpenWordCount, onOpenFindReplace, }: DocumentToolbarProps): import("react").JSX.Element;
|
|
81
83
|
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Editor } from '@tiptap/core';
|
|
2
|
+
export declare function DocumentUnderlineRibbon({ editor, label, menuLabel, colorLabel, showColor, className, }: {
|
|
3
|
+
editor: Editor;
|
|
4
|
+
label?: string;
|
|
5
|
+
menuLabel?: string;
|
|
6
|
+
colorLabel?: string;
|
|
7
|
+
showColor?: boolean;
|
|
8
|
+
className?: string;
|
|
9
|
+
}): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Cell } from '@fortune-sheet/core';
|
|
2
|
+
import { type XlsxNativeFill } from '../work-xlsx-native-fill';
|
|
3
|
+
export type SpreadsheetCellFillFormat = {
|
|
4
|
+
kind: 'none';
|
|
5
|
+
} | {
|
|
6
|
+
color: string;
|
|
7
|
+
kind: 'solid';
|
|
8
|
+
} | XlsxNativeFill;
|
|
9
|
+
export declare function spreadsheetCellFillFormat(cell: Cell | null | undefined): SpreadsheetCellFillFormat;
|
|
10
|
+
export declare function normalizeSpreadsheetCellFillFormat(value: unknown): SpreadsheetCellFillFormat | null;
|
|
11
|
+
export declare function withSpreadsheetCellFillFormat(cell: Cell, fill: SpreadsheetCellFillFormat): Cell | null;
|
|
@@ -4,6 +4,7 @@ import { type SpreadsheetUnderlineStyle } from '../work-spreadsheet-underline';
|
|
|
4
4
|
import { type SpreadsheetTextOrientationId } from '../work-spreadsheet-text-orientation';
|
|
5
5
|
import { type SpreadsheetCellBorderFormat } from './spreadsheet-cell-border';
|
|
6
6
|
import { type SpreadsheetCellRange } from './spreadsheet-cell-range';
|
|
7
|
+
import { type SpreadsheetCellFillFormat } from './spreadsheet-cell-fill-format';
|
|
7
8
|
export declare const MAX_SPREADSHEET_CELL_FORMAT_CELLS = 10000;
|
|
8
9
|
export type SpreadsheetHorizontalAlignment = 'general' | 'left' | 'center' | 'right';
|
|
9
10
|
export type SpreadsheetVerticalAlignment = 'top' | 'middle' | 'bottom';
|
|
@@ -21,7 +22,7 @@ export interface SpreadsheetCellFormatPatch {
|
|
|
21
22
|
italic?: boolean;
|
|
22
23
|
underline?: SpreadsheetUnderlineStyle;
|
|
23
24
|
strike?: boolean;
|
|
24
|
-
|
|
25
|
+
fill?: SpreadsheetCellFillFormat;
|
|
25
26
|
borders?: readonly SpreadsheetCellBorderFormat[];
|
|
26
27
|
locked?: boolean;
|
|
27
28
|
hidden?: boolean;
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import type { Cell } from '@fortune-sheet/core';
|
|
2
2
|
import type { WorkSpreadsheetContent } from '../work-types';
|
|
3
3
|
import { type SpreadsheetUnderlineStyle } from '../work-spreadsheet-underline';
|
|
4
|
+
import type { XlsxGradientFill } from '../work-xlsx-gradient-fill';
|
|
5
|
+
import type { XlsxPatternFill } from '../work-xlsx-pattern-fill';
|
|
4
6
|
import { type SpreadsheetCellBorderFormat, type SpreadsheetCellBorderStyle } from './spreadsheet-cell-border';
|
|
5
7
|
import { type SpreadsheetCellFormatPatch, type SpreadsheetHorizontalAlignment, type SpreadsheetVerticalAlignment } from './spreadsheet-cell-format';
|
|
8
|
+
import { type SpreadsheetCellFillFormat } from './spreadsheet-cell-fill-format';
|
|
6
9
|
import { type SpreadsheetCellRange } from './spreadsheet-cell-range';
|
|
7
10
|
export { spreadsheetFormatCellsTabs, type SpreadsheetFormatCellsTabId, } from './spreadsheet-format-cells-intent';
|
|
8
11
|
export interface SpreadsheetFormatCellsField<T> {
|
|
@@ -22,7 +25,7 @@ export interface SpreadsheetFormatCellsFields {
|
|
|
22
25
|
italic: SpreadsheetFormatCellsField<boolean>;
|
|
23
26
|
underline: SpreadsheetFormatCellsField<SpreadsheetUnderlineStyle>;
|
|
24
27
|
strike: SpreadsheetFormatCellsField<boolean>;
|
|
25
|
-
|
|
28
|
+
fill: SpreadsheetFormatCellsField<SpreadsheetCellFillFormat>;
|
|
26
29
|
borders: SpreadsheetFormatCellsField<readonly SpreadsheetCellBorderFormat[]>;
|
|
27
30
|
locked: SpreadsheetFormatCellsField<boolean>;
|
|
28
31
|
hidden: SpreadsheetFormatCellsField<boolean>;
|
|
@@ -46,15 +49,22 @@ export interface SpreadsheetFormatCellsDraft {
|
|
|
46
49
|
italic: boolean;
|
|
47
50
|
underline: SpreadsheetUnderlineStyle;
|
|
48
51
|
strike: boolean;
|
|
49
|
-
|
|
52
|
+
fill: SpreadsheetFormatCellsFillDraft;
|
|
50
53
|
borders: SpreadsheetCellBorderFormat[];
|
|
51
54
|
borderColor: string;
|
|
52
55
|
borderStyle: SpreadsheetCellBorderStyle;
|
|
53
56
|
locked: boolean;
|
|
54
57
|
hidden: boolean;
|
|
55
58
|
}
|
|
59
|
+
export interface SpreadsheetFormatCellsFillDraft {
|
|
60
|
+
gradient: XlsxGradientFill;
|
|
61
|
+
mode: SpreadsheetCellFillFormat['kind'];
|
|
62
|
+
pattern: XlsxPatternFill;
|
|
63
|
+
solidColor: string;
|
|
64
|
+
}
|
|
56
65
|
export type SpreadsheetFormatCellsTouched = Partial<Record<keyof SpreadsheetCellFormatPatch, true>>;
|
|
57
66
|
export interface SpreadsheetFormatCellsDraftErrors {
|
|
67
|
+
fill?: string;
|
|
58
68
|
numberFormat?: string;
|
|
59
69
|
fontSize?: string;
|
|
60
70
|
rotation?: string;
|
|
@@ -66,3 +76,4 @@ export declare function createSpreadsheetFormatCellsDialogSource(content: WorkSp
|
|
|
66
76
|
export declare function createSpreadsheetFormatCellsDraft(source: SpreadsheetFormatCellsDialogSource): SpreadsheetFormatCellsDraft;
|
|
67
77
|
export declare function spreadsheetFormatCellsPatch(source: SpreadsheetFormatCellsDialogSource, draft: SpreadsheetFormatCellsDraft, touched: SpreadsheetFormatCellsTouched): SpreadsheetCellFormatPatch;
|
|
68
78
|
export declare function spreadsheetFormatCellsDraftErrors(draft: SpreadsheetFormatCellsDraft): SpreadsheetFormatCellsDraftErrors;
|
|
79
|
+
export declare function spreadsheetFormatCellsActiveFill(draft: SpreadsheetFormatCellsDraft): SpreadsheetCellFillFormat;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Dispatch, SetStateAction } from 'react';
|
|
2
|
+
import type { SpreadsheetCellFormatPatch } from './spreadsheet-cell-format';
|
|
3
|
+
import { type SpreadsheetFormatCellsDialogSource, type SpreadsheetFormatCellsDraft, type SpreadsheetFormatCellsDraftErrors, type SpreadsheetFormatCellsTouched } from './spreadsheet-format-cells-dialog-model';
|
|
4
|
+
interface FillPanelProps {
|
|
5
|
+
source: SpreadsheetFormatCellsDialogSource;
|
|
6
|
+
draft: SpreadsheetFormatCellsDraft;
|
|
7
|
+
errors: SpreadsheetFormatCellsDraftErrors;
|
|
8
|
+
touched: SpreadsheetFormatCellsTouched;
|
|
9
|
+
setDraft: Dispatch<SetStateAction<SpreadsheetFormatCellsDraft>>;
|
|
10
|
+
touch: (field: keyof SpreadsheetCellFormatPatch) => void;
|
|
11
|
+
}
|
|
12
|
+
export declare function SpreadsheetFormatCellsFillPanel({ source, draft, errors, touched, setDraft, touch, }: FillPanelProps): import("react").JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { XlsxPatternFillType } from '../work-xlsx-pattern-fill';
|
|
2
|
+
import type { SpreadsheetCellFillFormat } from './spreadsheet-cell-fill-format';
|
|
3
|
+
export declare function SpreadsheetFormatCellsFillPreview({ fill, patternLabels, }: {
|
|
4
|
+
fill: SpreadsheetCellFillFormat;
|
|
5
|
+
patternLabels: Readonly<Record<XlsxPatternFillType, string>>;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Cell } from '@fortune-sheet/core';
|
|
2
|
-
export declare const spreadsheetCellFormatAttributes: readonly ["bl", "it", "ff", "fs", "fc", "ht", "vt", "tb", "cl", "un", "tr", "ct", "bg"];
|
|
2
|
+
export declare const spreadsheetCellFormatAttributes: readonly ["bl", "it", "ff", "fs", "fc", "ht", "vt", "tb", "cl", "un", "tr", "ct", "bg", "a3sXlsxPatternFill", "a3sXlsxGradientFill"];
|
|
3
3
|
export type SpreadsheetCellFormatAttribute = (typeof spreadsheetCellFormatAttributes)[number];
|
|
4
4
|
export type SpreadsheetFormatPainterMode = 'once' | 'locked';
|
|
5
5
|
export type SpreadsheetCellFormatSnapshot = Record<SpreadsheetCellFormatAttribute, unknown>;
|
|
@@ -23,6 +23,12 @@ export interface WorkOfficeQuickAccessAction {
|
|
|
23
23
|
disabled?: boolean;
|
|
24
24
|
onSelect: () => void | Promise<void>;
|
|
25
25
|
}
|
|
26
|
+
interface WorkOfficeRibbonDialogLauncher {
|
|
27
|
+
label: string;
|
|
28
|
+
shortcut?: string;
|
|
29
|
+
ariaKeyShortcuts?: string;
|
|
30
|
+
onClick: () => void;
|
|
31
|
+
}
|
|
26
32
|
export declare function WorkOfficeRibbon<T extends string>({ ariaLabel, tabs, defaultTab, activeTab, onTabChange, panels, fileActions, quickAccessActions, adaptive, collapsible, collapsed: controlledCollapsed, defaultCollapsed, onCollapsedChange, className, toolbarClassName, }: {
|
|
27
33
|
ariaLabel: string;
|
|
28
34
|
tabs: readonly WorkOfficeRibbonTab<T>[];
|
|
@@ -47,9 +53,10 @@ export declare function WorkOfficePreviewBar({ ariaLabel, label, detail, fileAct
|
|
|
47
53
|
fileActions?: readonly WorkOfficeFileAction[];
|
|
48
54
|
className?: string;
|
|
49
55
|
}): import("react").JSX.Element;
|
|
50
|
-
export declare function WorkOfficeRibbonGroup({ label, priority, children, }: {
|
|
56
|
+
export declare function WorkOfficeRibbonGroup({ label, priority, dialogLauncher, children, }: {
|
|
51
57
|
label: string;
|
|
52
58
|
priority?: 'high' | 'normal' | 'low';
|
|
59
|
+
dialogLauncher?: WorkOfficeRibbonDialogLauncher;
|
|
53
60
|
children: ReactNode;
|
|
54
61
|
}): import("react").JSX.Element;
|
|
55
62
|
export declare function WorkOfficeRibbonButton({ label, visibleLabel, badge, active, displayLabel, className, title, children, ...props }: Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'aria-label' | 'children'> & {
|
|
@@ -78,3 +85,4 @@ export declare function WorkOfficeZoomControls({ zoom, minimum, maximum, step, d
|
|
|
78
85
|
sliderLabel: string;
|
|
79
86
|
onChange: (zoom: number) => void;
|
|
80
87
|
}): import("react").JSX.Element;
|
|
88
|
+
export {};
|
|
@@ -1,12 +1,27 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { Extension, type Editor } from '@tiptap/core';
|
|
2
|
+
import { type WorkDocumentEmphasisMark } from './work-document-emphasis';
|
|
3
|
+
import { type WorkDocumentTextCase } from './work-document-text-case';
|
|
2
4
|
declare module '@tiptap/core' {
|
|
3
5
|
interface Commands<ReturnType> {
|
|
4
6
|
documentCharacterFormatting: {
|
|
7
|
+
setDocumentCharacterScale: (characterScalePercent: number) => ReturnType;
|
|
5
8
|
toggleDocumentSubscript: () => ReturnType;
|
|
6
9
|
toggleDocumentSuperscript: () => ReturnType;
|
|
10
|
+
setDocumentCharacterSpacing: (characterSpacingTwips: number) => ReturnType;
|
|
11
|
+
setDocumentCharacterPosition: (characterPositionHalfPoints: number) => ReturnType;
|
|
12
|
+
setDocumentKerningThreshold: (kerningThresholdHalfPoints: number) => ReturnType;
|
|
13
|
+
unsetDocumentKerningThreshold: () => ReturnType;
|
|
14
|
+
setDocumentEmphasisMark: (emphasisMark: WorkDocumentEmphasisMark) => ReturnType;
|
|
15
|
+
unsetDocumentEmphasisMark: () => ReturnType;
|
|
16
|
+
setDocumentHiddenText: (hiddenText: boolean) => ReturnType;
|
|
17
|
+
unsetDocumentHiddenText: () => ReturnType;
|
|
18
|
+
toggleDocumentHiddenText: () => ReturnType;
|
|
19
|
+
setDocumentTextCase: (textCase: WorkDocumentTextCase) => ReturnType;
|
|
20
|
+
toggleDocumentTextCase: (textCase: Exclude<WorkDocumentTextCase, 'none'>) => ReturnType;
|
|
7
21
|
};
|
|
8
22
|
}
|
|
9
23
|
}
|
|
24
|
+
export declare const DocumentCharacterFormatting: Extension<any, any>;
|
|
10
25
|
export declare const DocumentSubscript: import("@tiptap/core").Mark<import("@tiptap/extension-subscript").SubscriptExtensionOptions, any>;
|
|
11
26
|
export declare const DocumentSuperscript: import("@tiptap/core").Mark<import("@tiptap/extension-superscript").SuperscriptExtensionOptions, any>;
|
|
12
27
|
export declare function toggleDocumentSubscript(editor: Editor): boolean;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const DOCUMENT_CHARACTER_POSITION_ATTRIBUTE = "data-office-character-position-half-points";
|
|
2
|
+
export declare const DOCUMENT_CHARACTER_POSITION_CSS_PROPERTY = "--work-document-character-position";
|
|
3
|
+
export declare const DOCUMENT_CHARACTER_POSITION_MAX_HALF_POINTS = 3168;
|
|
4
|
+
export declare const DOCUMENT_CHARACTER_POSITION_MIN_HALF_POINTS: number;
|
|
5
|
+
export declare function normalizeDocumentCharacterPositionHalfPoints(value: unknown): number | null;
|
|
6
|
+
export declare function documentCharacterPositionDomAttributes(value: unknown): Record<string, string>;
|
|
7
|
+
export declare function documentCharacterPositionHalfPointsFromElement(element: HTMLElement): number | null;
|
|
8
|
+
export declare function documentCharacterPositionHalfPointsFromCss(value: unknown): number | null;
|
|
9
|
+
export declare function documentCharacterPositionPoints(value: unknown): number | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const DOCUMENT_CHARACTER_SCALE_ATTRIBUTE = "data-office-character-scale-percent";
|
|
2
|
+
export declare const DOCUMENT_CHARACTER_SCALE_DEFAULT_PERCENT = 100;
|
|
3
|
+
export declare const DOCUMENT_CHARACTER_SCALE_MIN_PERCENT = 1;
|
|
4
|
+
export declare const DOCUMENT_CHARACTER_SCALE_MAX_PERCENT = 600;
|
|
5
|
+
export declare function normalizeDocumentCharacterScalePercent(value: unknown): number | null;
|
|
6
|
+
export declare function documentCharacterScaleDomAttributes(value: unknown): Record<string, string>;
|
|
7
|
+
export declare function documentCharacterScalePercentFromElement(element: HTMLElement): number | null;
|
|
8
|
+
export declare function documentCharacterScalePercentFromCss(value: unknown): number | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const DOCUMENT_CHARACTER_SPACING_ATTRIBUTE = "data-office-character-spacing-twips";
|
|
2
|
+
export declare const DOCUMENT_CHARACTER_SPACING_MAX_TWIPS = 31680;
|
|
3
|
+
export declare const DOCUMENT_CHARACTER_SPACING_MIN_TWIPS: number;
|
|
4
|
+
export declare function normalizeDocumentCharacterSpacingTwips(value: unknown): number | null;
|
|
5
|
+
export declare function documentCharacterSpacingDomAttributes(value: unknown): Record<string, string>;
|
|
6
|
+
export declare function documentCharacterSpacingTwipsFromElement(element: HTMLElement): number | null;
|
|
7
|
+
export declare function documentCharacterSpacingTwipsFromCss(value: unknown): number | null;
|
|
8
|
+
export declare function documentCharacterSpacingPoints(value: unknown): number | null;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare const DOCUMENT_EMPHASIS_MARK_ATTRIBUTE = "data-office-emphasis-mark";
|
|
2
|
+
export declare const DOCUMENT_EMPHASIS_MARKS: readonly ["none", "dot", "comma", "circle", "underDot"];
|
|
3
|
+
export type WorkDocumentEmphasisMark = (typeof DOCUMENT_EMPHASIS_MARKS)[number];
|
|
4
|
+
export declare function normalizeDocumentEmphasisMark(value: unknown): WorkDocumentEmphasisMark | null;
|
|
5
|
+
export declare function documentEmphasisMarkCss(value: unknown): string;
|
|
6
|
+
export declare function documentEmphasisMarkDomAttributes(value: unknown): Record<string, string>;
|
|
7
|
+
export declare function documentEmphasisMarkFromElement(element: HTMLElement): WorkDocumentEmphasisMark | null;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Node } from '@tiptap/core';
|
|
2
|
+
import { type WorkDocumentEmphasisMark } from './work-document-emphasis';
|
|
2
3
|
export type WorkDocumentEquationDisplay = 'inline' | 'block';
|
|
3
4
|
export type WorkDocumentEquationJustification = 'left' | 'right' | 'center' | 'centerGroup';
|
|
4
5
|
export type WorkDocumentEquationBarPosition = 'top' | 'bottom';
|
|
@@ -203,7 +204,7 @@ export interface WorkDocumentEquationWordFitText {
|
|
|
203
204
|
id?: number;
|
|
204
205
|
}
|
|
205
206
|
export type WorkDocumentEquationWordVerticalAlignment = 'baseline' | 'superscript' | 'subscript';
|
|
206
|
-
export type WorkDocumentEquationWordEmphasisMark =
|
|
207
|
+
export type WorkDocumentEquationWordEmphasisMark = WorkDocumentEmphasisMark;
|
|
207
208
|
export interface WorkDocumentEquationWordLanguages {
|
|
208
209
|
latin?: string;
|
|
209
210
|
eastAsia?: string;
|