oasis-editor 0.0.88 → 0.0.89
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/{OasisEditorApp-Bx4I4GCm.js → OasisEditorApp-cKm4OFIF.js} +1325 -171
- package/dist/assets/{importDocxWorker-BcELKms0.js → importDocxWorker-DVDyiqYf.js} +1 -1
- package/dist/core/commands/table/tableCommandUtils.d.ts +2 -1
- package/dist/core/commands/table/tableFloatingCommands.d.ts +5 -0
- package/dist/core/commands/table.d.ts +1 -0
- package/dist/core/model/index.d.ts +2 -2
- package/dist/core/model/types/layout.d.ts +4 -0
- package/dist/core/model/types/nodes.d.ts +23 -7
- package/dist/core/model/types/primitives.d.ts +17 -0
- package/dist/core/model/types/styles.d.ts +43 -6
- package/dist/core/model.d.ts +1 -0
- package/dist/core/tableStyleResolver.d.ts +20 -0
- package/dist/export/docx/tableXml.d.ts +1 -0
- package/dist/export/pdf/draw/drawFragment.d.ts +13 -1
- package/dist/export/pdf/draw/drawTextBoxShape.d.ts +1 -0
- package/dist/i18n/locales/en.d.ts +18 -0
- package/dist/i18n/locales/pt-BR.d.ts +18 -0
- package/dist/import/docx/tableProperties.d.ts +2 -1
- package/dist/import/docx/tables.d.ts +1 -1
- package/dist/{index-Ds5uOUe8.js → index-BICQTKCZ.js} +1401 -850
- package/dist/layoutProjection/floatingObjects.d.ts +15 -1
- package/dist/layoutProjection/paginationTrack.d.ts +2 -0
- package/dist/layoutProjection/paragraphPagination.d.ts +2 -2
- package/dist/oasis-editor.js +50 -50
- package/dist/oasis-editor.umd.cjs +4 -4
- package/dist/ui/canvas/CanvasLayoutSnapshot.d.ts +1 -1
- package/dist/ui/canvas/CanvasTableLayout.d.ts +7 -1
- package/dist/ui/canvas/canvasBorders.d.ts +2 -0
- package/dist/ui/canvas/canvasSnapshotTypes.d.ts +12 -0
- package/dist/ui/components/Dialogs/TablePropertiesDialog.d.ts +22 -1
- package/dist/ui/editorUiTypes.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CanvasLayoutSnapshot, BuildCanvasLayoutSnapshotOptions } from './canvasSnapshotTypes.js';
|
|
2
2
|
|
|
3
|
-
export type { ResolveTextBoxRenderHeight, CanvasSnapshotSlot, CanvasSnapshotLine, CanvasSnapshotTableCellInfo, CanvasSnapshotParagraph, CanvasSnapshotInlineImage, CanvasSnapshotFloatingTextBox, CanvasSnapshotFloatingImage, CanvasSnapshotInlineTextBox, CanvasSnapshotPage, CanvasLayoutSnapshot, BuildCanvasLayoutSnapshotOptions, } from './canvasSnapshotTypes.js';
|
|
3
|
+
export type { ResolveTextBoxRenderHeight, CanvasSnapshotSlot, CanvasSnapshotLine, CanvasSnapshotTableCellInfo, CanvasSnapshotParagraph, CanvasSnapshotInlineImage, CanvasSnapshotFloatingTextBox, CanvasSnapshotFloatingImage, CanvasSnapshotInlineTextBox, CanvasSnapshotFloatingTable, CanvasSnapshotPage, CanvasLayoutSnapshot, BuildCanvasLayoutSnapshotOptions, } from './canvasSnapshotTypes.js';
|
|
4
4
|
/**
|
|
5
5
|
* Coordinate contract ("screen-anchored local" space)
|
|
6
6
|
* ----------------------------------------------------
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { EditorParagraphNode, EditorPosition, EditorState, EditorTableNode } from '../../core/model.js';
|
|
1
|
+
import { EditorParagraphNode, EditorPosition, EditorState, EditorTableNode, EditorRevisionMetadata } from '../../core/model.js';
|
|
2
2
|
import { projectParagraphLayout } from '../../layoutProjection/index.js';
|
|
3
3
|
import { VerticalRenderMode } from './verticalText.js';
|
|
4
4
|
|
|
5
|
+
export declare function resolveCanvasTableWidth(table: EditorTableNode, contentWidth: number): number;
|
|
5
6
|
export type CanvasUnsupportedReason = "unsupported:v-span" | "unsupported:v-merge" | "unsupported:nested-table";
|
|
6
7
|
export interface CanvasTableBorderSpec {
|
|
7
8
|
width: number;
|
|
@@ -41,10 +42,15 @@ export interface CanvasTableCellLayoutEntry {
|
|
|
41
42
|
right: CanvasTableBorderSpec;
|
|
42
43
|
bottom: CanvasTableBorderSpec;
|
|
43
44
|
left: CanvasTableBorderSpec;
|
|
45
|
+
topLeftToBottomRight?: CanvasTableBorderSpec;
|
|
46
|
+
topRightToBottomLeft?: CanvasTableBorderSpec;
|
|
44
47
|
};
|
|
45
48
|
paragraphs: CanvasTableParagraphLayoutEntry[];
|
|
46
49
|
/** Vertical text flow inside this cell (`horizontal` when not rotated). */
|
|
47
50
|
verticalMode: VerticalRenderMode;
|
|
51
|
+
revision?: EditorRevisionMetadata & {
|
|
52
|
+
type: "insert" | "delete" | "merge" | "property";
|
|
53
|
+
};
|
|
48
54
|
}
|
|
49
55
|
export interface CanvasTableLayoutResult {
|
|
50
56
|
tableId: string;
|
|
@@ -8,6 +8,8 @@ export interface CanvasBorderBox {
|
|
|
8
8
|
right?: CanvasBorderEdge;
|
|
9
9
|
bottom?: CanvasBorderEdge;
|
|
10
10
|
left?: CanvasBorderEdge;
|
|
11
|
+
topLeftToBottomRight?: CanvasBorderEdge;
|
|
12
|
+
topRightToBottomLeft?: CanvasBorderEdge;
|
|
11
13
|
}
|
|
12
14
|
/**
|
|
13
15
|
* Strokes the four edges of a rectangular box. Edges left `undefined` are
|
|
@@ -25,6 +25,7 @@ export interface CanvasSnapshotTableCellInfo {
|
|
|
25
25
|
width: number;
|
|
26
26
|
height: number;
|
|
27
27
|
anchorPosition: EditorPosition;
|
|
28
|
+
revisionId?: string;
|
|
28
29
|
}
|
|
29
30
|
export interface CanvasSnapshotParagraph {
|
|
30
31
|
paragraph: EditorParagraphNode;
|
|
@@ -109,6 +110,16 @@ export interface CanvasSnapshotInlineTextBox {
|
|
|
109
110
|
/** Shape rotation in degrees, when rotated. */
|
|
110
111
|
rotation?: number;
|
|
111
112
|
}
|
|
113
|
+
export interface CanvasSnapshotFloatingTable {
|
|
114
|
+
tableId: string;
|
|
115
|
+
zone: EditorEditingZone;
|
|
116
|
+
footnoteId?: string;
|
|
117
|
+
pageIndex: number;
|
|
118
|
+
left: number;
|
|
119
|
+
top: number;
|
|
120
|
+
width: number;
|
|
121
|
+
height: number;
|
|
122
|
+
}
|
|
112
123
|
export interface CanvasSnapshotPage {
|
|
113
124
|
index: number;
|
|
114
125
|
left: number;
|
|
@@ -130,6 +141,7 @@ export interface CanvasLayoutSnapshot {
|
|
|
130
141
|
floatingImages: CanvasSnapshotFloatingImage[];
|
|
131
142
|
inlineTextBoxes: CanvasSnapshotInlineTextBox[];
|
|
132
143
|
floatingTextBoxes: CanvasSnapshotFloatingTextBox[];
|
|
144
|
+
floatingTables: CanvasSnapshotFloatingTable[];
|
|
133
145
|
unsupportedRegions: Array<{
|
|
134
146
|
pageIndex: number;
|
|
135
147
|
zone: EditorEditingZone;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditorBorderStyle, EditorDocxWidthValue, EditorTableRowHeightRule } from '../../../core/model.js';
|
|
1
|
+
import { EditorBorderStyle, EditorDocxWidthValue, EditorTableRowHeightRule, EditorTableFloatingLayout } from '../../../core/model.js';
|
|
2
2
|
|
|
3
3
|
type TableWidthUnit = "points" | "percent";
|
|
4
4
|
type BorderStyleValue = "none" | "solid" | "dashed" | "dotted";
|
|
@@ -10,6 +10,17 @@ export interface TablePropertiesDialogInitialValues {
|
|
|
10
10
|
tableIndentLeft: string;
|
|
11
11
|
tableWrapping: "none" | "around";
|
|
12
12
|
floatingSummary: string;
|
|
13
|
+
floatingHorizontalAnchor: "margin" | "page" | "text";
|
|
14
|
+
floatingVerticalAnchor: "margin" | "page" | "text";
|
|
15
|
+
floatingX: string;
|
|
16
|
+
floatingY: string;
|
|
17
|
+
floatingXAlign: "" | "left" | "center" | "right" | "inside" | "outside";
|
|
18
|
+
floatingYAlign: "" | "top" | "center" | "bottom" | "inside" | "outside";
|
|
19
|
+
floatingDistanceTop: string;
|
|
20
|
+
floatingDistanceRight: string;
|
|
21
|
+
floatingDistanceBottom: string;
|
|
22
|
+
floatingDistanceLeft: string;
|
|
23
|
+
floatingOverlap: "overlap" | "never";
|
|
13
24
|
rowHeight: string;
|
|
14
25
|
rowHeightRule: EditorTableRowHeightRule | "";
|
|
15
26
|
repeatHeader: boolean;
|
|
@@ -33,6 +44,10 @@ export interface TablePropertiesDialogInitialValues {
|
|
|
33
44
|
borderRight: boolean;
|
|
34
45
|
borderBottom: boolean;
|
|
35
46
|
borderLeft: boolean;
|
|
47
|
+
borderStart: boolean;
|
|
48
|
+
borderEnd: boolean;
|
|
49
|
+
borderTopLeftToBottomRight: boolean;
|
|
50
|
+
borderTopRightToBottomLeft: boolean;
|
|
36
51
|
shading: string;
|
|
37
52
|
altTitle: string;
|
|
38
53
|
altDescription: string;
|
|
@@ -42,11 +57,17 @@ export interface TablePropertiesDialogBorders {
|
|
|
42
57
|
right: EditorBorderStyle | null;
|
|
43
58
|
bottom: EditorBorderStyle | null;
|
|
44
59
|
left: EditorBorderStyle | null;
|
|
60
|
+
start: EditorBorderStyle | null;
|
|
61
|
+
end: EditorBorderStyle | null;
|
|
62
|
+
topLeftToBottomRight: EditorBorderStyle | null;
|
|
63
|
+
topRightToBottomLeft: EditorBorderStyle | null;
|
|
45
64
|
}
|
|
46
65
|
export interface TablePropertiesDialogApplyValues {
|
|
47
66
|
tableWidth: EditorDocxWidthValue | null;
|
|
48
67
|
tableAlign: "left" | "center" | "right" | null;
|
|
49
68
|
tableIndentLeft: EditorDocxWidthValue | null;
|
|
69
|
+
tableFloating: EditorTableFloatingLayout | null;
|
|
70
|
+
tableOverlap: "overlap" | "never" | null;
|
|
50
71
|
rowHeight: EditorDocxWidthValue | null;
|
|
51
72
|
rowHeightRule: EditorTableRowHeightRule | null;
|
|
52
73
|
repeatHeader: boolean;
|