@myoc/common 0.19.505 → 0.19.507
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/types/element/src/Scene.d.ts +5 -3
- package/dist/types/element/src/bounds.d.ts +4 -2
- package/dist/types/element/src/duplicate.d.ts +1 -0
- package/dist/types/element/src/frame.d.ts +7 -6
- package/dist/types/element/src/linearElementEditor.d.ts +2 -2
- package/dist/types/element/src/selection.d.ts +2 -2
- package/dist/types/element/src/shape.d.ts +1 -1
- package/dist/types/element/src/typeChecks.d.ts +1 -0
- package/dist/types/element/src/utils.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +3 -3
- package/dist/types/excalidraw/actions/actionBoundText.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionCanvas.d.ts +11 -11
- package/dist/types/excalidraw/actions/actionClipboard.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionCropEditor.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +3 -3
- package/dist/types/excalidraw/actions/actionDeselect.d.ts +168 -0
- package/dist/types/excalidraw/actions/actionElementLink.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionElementLock.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionExport.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionFrame.d.ts +4 -4
- package/dist/types/excalidraw/actions/actionGroup.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionLink.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionMenu.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionProperties.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionSelectAll.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionStyles.d.ts +3 -5
- package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleStats.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +2 -3
- package/dist/types/excalidraw/actions/index.d.ts +1 -0
- package/dist/types/excalidraw/actions/types.d.ts +1 -1
- package/dist/types/excalidraw/appState.d.ts +1 -0
- package/dist/types/excalidraw/components/App.d.ts +9 -0
- package/dist/types/excalidraw/components/PublishLibrary.d.ts +3 -2
- package/dist/types/excalidraw/components/canvases/InteractiveCanvas.d.ts +1 -1
- package/dist/types/excalidraw/components/canvases/NewElementCanvas.d.ts +1 -0
- package/dist/types/excalidraw/components/canvases/StaticCanvas.d.ts +1 -1
- package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContentRadio.d.ts +2 -1
- package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +1 -0
- package/dist/types/excalidraw/data/blob.d.ts +4 -8
- package/dist/types/excalidraw/data/json.d.ts +1 -1
- package/dist/types/excalidraw/scene/Renderer.d.ts +425 -19
- package/dist/types/excalidraw/scene/types.d.ts +2 -0
- package/dist/types/excalidraw/types.d.ts +15 -2
- package/dist/types/fractional-indexing/src/index.d.ts +29 -0
- package/dist/types/math/src/constants.d.ts +0 -1
- package/dist/types/math/src/curve.d.ts +4 -1
- package/package.json +3 -2
|
@@ -124,9 +124,9 @@ export declare const actionLoadScene: {
|
|
|
124
124
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
125
125
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
126
126
|
isBindingEnabled: boolean;
|
|
127
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
127
128
|
bindingPreference: "enabled" | "disabled";
|
|
128
129
|
isMidpointSnappingEnabled: boolean;
|
|
129
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
130
130
|
suggestedBinding: {
|
|
131
131
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
132
132
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -277,9 +277,9 @@ export declare const actionLoadScene: {
|
|
|
277
277
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
278
278
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
279
279
|
isBindingEnabled: boolean;
|
|
280
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
280
281
|
bindingPreference: "enabled" | "disabled";
|
|
281
282
|
isMidpointSnappingEnabled: boolean;
|
|
282
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
283
283
|
suggestedBinding: {
|
|
284
284
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
285
285
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -39,9 +39,9 @@ export declare const actionSelectAllElementsInFrame: {
|
|
|
39
39
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
40
40
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
41
41
|
isBindingEnabled: boolean;
|
|
42
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
42
43
|
bindingPreference: "enabled" | "disabled";
|
|
43
44
|
isMidpointSnappingEnabled: boolean;
|
|
44
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
45
45
|
suggestedBinding: {
|
|
46
46
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
47
47
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -223,9 +223,9 @@ export declare const actionRemoveAllElementsFromFrame: {
|
|
|
223
223
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
224
224
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
225
225
|
isBindingEnabled: boolean;
|
|
226
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
226
227
|
bindingPreference: "enabled" | "disabled";
|
|
227
228
|
isMidpointSnappingEnabled: boolean;
|
|
228
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
229
229
|
suggestedBinding: {
|
|
230
230
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
231
231
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -411,9 +411,9 @@ export declare const actionupdateFrameRendering: {
|
|
|
411
411
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
412
412
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
413
413
|
isBindingEnabled: boolean;
|
|
414
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
414
415
|
bindingPreference: "enabled" | "disabled";
|
|
415
416
|
isMidpointSnappingEnabled: boolean;
|
|
416
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
417
417
|
suggestedBinding: {
|
|
418
418
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
419
419
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -592,9 +592,9 @@ export declare const actionSetFrameAsActiveTool: {
|
|
|
592
592
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
593
593
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
594
594
|
isBindingEnabled: boolean;
|
|
595
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
595
596
|
bindingPreference: "enabled" | "disabled";
|
|
596
597
|
isMidpointSnappingEnabled: boolean;
|
|
597
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
598
598
|
suggestedBinding: {
|
|
599
599
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
600
600
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -45,9 +45,9 @@ export declare const actionGroup: {
|
|
|
45
45
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
46
46
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
47
47
|
isBindingEnabled: boolean;
|
|
48
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
48
49
|
bindingPreference: "enabled" | "disabled";
|
|
49
50
|
isMidpointSnappingEnabled: boolean;
|
|
50
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
51
51
|
suggestedBinding: {
|
|
52
52
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
53
53
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -228,9 +228,9 @@ export declare const actionUngroup: {
|
|
|
228
228
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
229
229
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
230
230
|
isBindingEnabled: boolean;
|
|
231
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
231
232
|
bindingPreference: "enabled" | "disabled";
|
|
232
233
|
isMidpointSnappingEnabled: boolean;
|
|
233
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
234
234
|
suggestedBinding: {
|
|
235
235
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
236
236
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -72,9 +72,9 @@ export declare const actionToggleLinearEditor: {
|
|
|
72
72
|
multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
|
|
73
73
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
74
74
|
isBindingEnabled: boolean;
|
|
75
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
75
76
|
bindingPreference: "enabled" | "disabled";
|
|
76
77
|
isMidpointSnappingEnabled: boolean;
|
|
77
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
78
78
|
suggestedBinding: {
|
|
79
79
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
80
80
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -36,9 +36,9 @@ export declare const actionLink: {
|
|
|
36
36
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
37
37
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
38
38
|
isBindingEnabled: boolean;
|
|
39
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
39
40
|
bindingPreference: "enabled" | "disabled";
|
|
40
41
|
isMidpointSnappingEnabled: boolean;
|
|
41
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
42
42
|
suggestedBinding: {
|
|
43
43
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
44
44
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -43,9 +43,9 @@ export declare const actionShortcuts: {
|
|
|
43
43
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
44
44
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
45
45
|
isBindingEnabled: boolean;
|
|
46
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
46
47
|
bindingPreference: "enabled" | "disabled";
|
|
47
48
|
isMidpointSnappingEnabled: boolean;
|
|
48
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
49
49
|
suggestedBinding: {
|
|
50
50
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
51
51
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -65,9 +65,9 @@ export declare const actionDecreaseFontSize: {
|
|
|
65
65
|
multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
|
|
66
66
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
67
67
|
isBindingEnabled: boolean;
|
|
68
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
68
69
|
bindingPreference: "enabled" | "disabled";
|
|
69
70
|
isMidpointSnappingEnabled: boolean;
|
|
70
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
|
|
71
71
|
suggestedBinding: {
|
|
72
72
|
element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
|
|
73
73
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -244,9 +244,9 @@ export declare const actionIncreaseFontSize: {
|
|
|
244
244
|
multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
|
|
245
245
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
246
246
|
isBindingEnabled: boolean;
|
|
247
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
247
248
|
bindingPreference: "enabled" | "disabled";
|
|
248
249
|
isMidpointSnappingEnabled: boolean;
|
|
249
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
|
|
250
250
|
suggestedBinding: {
|
|
251
251
|
element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
|
|
252
252
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -43,9 +43,9 @@ export declare const actionSelectAll: {
|
|
|
43
43
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
44
44
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
45
45
|
isBindingEnabled: boolean;
|
|
46
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
46
47
|
bindingPreference: "enabled" | "disabled";
|
|
47
48
|
isMidpointSnappingEnabled: boolean;
|
|
48
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
49
49
|
suggestedBinding: {
|
|
50
50
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
51
51
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -41,9 +41,9 @@ export declare const actionCopyStyles: {
|
|
|
41
41
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
42
42
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
43
43
|
isBindingEnabled: boolean;
|
|
44
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
44
45
|
bindingPreference: "enabled" | "disabled";
|
|
45
46
|
isMidpointSnappingEnabled: boolean;
|
|
46
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
47
47
|
suggestedBinding: {
|
|
48
48
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
49
49
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -174,9 +174,8 @@ export declare const actionCopyStyles: {
|
|
|
174
174
|
};
|
|
175
175
|
captureUpdate: "EVENTUALLY";
|
|
176
176
|
};
|
|
177
|
-
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
|
|
178
177
|
} & {
|
|
179
|
-
keyTest?:
|
|
178
|
+
keyTest?: undefined;
|
|
180
179
|
};
|
|
181
180
|
export declare const actionPasteStyles: {
|
|
182
181
|
name: "pasteStyles";
|
|
@@ -192,7 +191,6 @@ export declare const actionPasteStyles: {
|
|
|
192
191
|
elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
|
|
193
192
|
captureUpdate: "IMMEDIATELY";
|
|
194
193
|
};
|
|
195
|
-
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
|
|
196
194
|
} & {
|
|
197
|
-
keyTest?:
|
|
195
|
+
keyTest?: undefined;
|
|
198
196
|
};
|
|
@@ -38,8 +38,8 @@ export declare const actionToggleArrowBinding: {
|
|
|
38
38
|
resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
39
39
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
40
40
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
41
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
41
42
|
isMidpointSnappingEnabled: boolean;
|
|
42
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
43
43
|
suggestedBinding: {
|
|
44
44
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
45
45
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -42,9 +42,9 @@ export declare const actionToggleGridMode: {
|
|
|
42
42
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
43
43
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
44
44
|
isBindingEnabled: boolean;
|
|
45
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
45
46
|
bindingPreference: "enabled" | "disabled";
|
|
46
47
|
isMidpointSnappingEnabled: boolean;
|
|
47
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
48
48
|
suggestedBinding: {
|
|
49
49
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
50
50
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -38,8 +38,8 @@ export declare const actionToggleMidpointSnapping: {
|
|
|
38
38
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
39
39
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
40
40
|
isBindingEnabled: boolean;
|
|
41
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
41
42
|
bindingPreference: "enabled" | "disabled";
|
|
42
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
43
43
|
suggestedBinding: {
|
|
44
44
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
45
45
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -40,9 +40,9 @@ export declare const actionToggleObjectsSnapMode: {
|
|
|
40
40
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
41
41
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
42
42
|
isBindingEnabled: boolean;
|
|
43
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
43
44
|
bindingPreference: "enabled" | "disabled";
|
|
44
45
|
isMidpointSnappingEnabled: boolean;
|
|
45
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
46
46
|
suggestedBinding: {
|
|
47
47
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
48
48
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -46,9 +46,9 @@ export declare const actionToggleSearchMenu: {
|
|
|
46
46
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
47
47
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
48
48
|
isBindingEnabled: boolean;
|
|
49
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
49
50
|
bindingPreference: "enabled" | "disabled";
|
|
50
51
|
isMidpointSnappingEnabled: boolean;
|
|
51
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
52
52
|
suggestedBinding: {
|
|
53
53
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
54
54
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -42,9 +42,9 @@ export declare const actionToggleStats: {
|
|
|
42
42
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
43
43
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
44
44
|
isBindingEnabled: boolean;
|
|
45
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
45
46
|
bindingPreference: "enabled" | "disabled";
|
|
46
47
|
isMidpointSnappingEnabled: boolean;
|
|
47
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
48
48
|
suggestedBinding: {
|
|
49
49
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
50
50
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -39,9 +39,9 @@ export declare const actionToggleViewMode: {
|
|
|
39
39
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
40
40
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
41
41
|
isBindingEnabled: boolean;
|
|
42
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
42
43
|
bindingPreference: "enabled" | "disabled";
|
|
43
44
|
isMidpointSnappingEnabled: boolean;
|
|
44
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
45
45
|
suggestedBinding: {
|
|
46
46
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
47
47
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -39,9 +39,9 @@ export declare const actionToggleZenMode: {
|
|
|
39
39
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
40
40
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
41
41
|
isBindingEnabled: boolean;
|
|
42
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
42
43
|
bindingPreference: "enabled" | "disabled";
|
|
43
44
|
isMidpointSnappingEnabled: boolean;
|
|
44
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
45
45
|
suggestedBinding: {
|
|
46
46
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
47
47
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -178,7 +178,6 @@ export declare const actionToggleZenMode: {
|
|
|
178
178
|
};
|
|
179
179
|
checked: (appState: Readonly<import("../types").AppState>) => boolean;
|
|
180
180
|
predicate: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: import("../types").AppState, appProps: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
|
|
181
|
-
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
|
|
182
181
|
} & {
|
|
183
|
-
keyTest?:
|
|
182
|
+
keyTest?: undefined;
|
|
184
183
|
};
|
|
@@ -6,6 +6,7 @@ export { actionChangeStrokeColor, actionChangeBackgroundColor, actionChangeStrok
|
|
|
6
6
|
export { actionChangeViewBackgroundColor, actionZoomIn, actionZoomOut, actionResetZoom, actionZoomToFit, actionToggleTheme, } from "./actionCanvas";
|
|
7
7
|
export { actionSetEmbeddableAsActiveTool } from "./actionEmbeddable";
|
|
8
8
|
export { actionFinalize } from "./actionFinalize";
|
|
9
|
+
export { actionDeselect } from "./actionDeselect";
|
|
9
10
|
export { actionChangeProjectName, actionChangeExportBackground, actionSaveToActiveFile, actionSaveFileToDisk, actionLoadScene, } from "./actionExport";
|
|
10
11
|
export { actionCopyStyles, actionPasteStyles } from "./actionStyles";
|
|
11
12
|
export { actionShortcuts } from "./actionMenu";
|
|
@@ -14,7 +14,7 @@ export type ActionResult = {
|
|
|
14
14
|
type ActionFn<TData = any> = (elements: readonly OrderedExcalidrawElement[], appState: Readonly<AppState>, formData: TData | undefined, app: AppClassProperties) => ActionResult | Promise<ActionResult>;
|
|
15
15
|
export type UpdaterFn = (res: ActionResult) => void;
|
|
16
16
|
export type ActionFilterFn = (action: Action) => void;
|
|
17
|
-
export type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "copyText" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "objectsSnapMode" | "arrowBinding" | "midpointSnapping" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeArrowType" | "changeArrowProperties" | "changeOpacity" | "changeFontSize" | "undo" | "redo" | "finalize" | "changeProjectName" | "changeExportBackground" | "changeExportEmbedScene" | "changeExportScale" | "saveToActiveFile" | "saveFileToDisk" | "loadScene" | "duplicateSelection" | "deleteSelectedElements" | "changeViewBackgroundColor" | "zoomIn" | "zoomOut" | "resetZoom" | "zoomToFit" | "zoomToFitSelection" | "zoomToFitSelectionInViewport" | "changeFontFamily" | "changeTextAlign" | "changeVerticalAlign" | "toggleFullScreen" | "toggleShortcuts" | "group" | "ungroup" | "goToCollaborator" | "addToLibrary" | "changeRoundness" | "alignTop" | "alignBottom" | "alignLeft" | "alignRight" | "alignVerticallyCentered" | "alignHorizontallyCentered" | "distributeHorizontally" | "distributeVertically" | "arrangeElements" | "normaliseElements" | "flipHorizontal" | "flipVertical" | "viewMode" | "exportWithDarkMode" | "toggleTheme" | "increaseFontSize" | "decreaseFontSize" | "unbindText" | "hyperlink" | "bindText" | "unlockAllElements" | "toggleElementLock" | "toggleLinearEditor" | "toggleEraserTool" | "toggleHandTool" | "selectAllElementsInFrame" | "removeAllElementsFromFrame" | "updateFrameRendering" | "setFrameAsActiveTool" | "setEmbeddableAsActiveTool" | "createContainerFromText" | "wrapTextInContainer" | "commandPalette" | "autoResize" | "elementStats" | "searchMenu" | "copyElementLink" | "linkToElement" | "cropEditor" | "wrapSelectionInFrame" | "smartZoom" | "toggleLassoTool" | "toggleShapeSwitch" | "togglePolygon";
|
|
17
|
+
export type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "copyText" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "objectsSnapMode" | "arrowBinding" | "midpointSnapping" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeArrowType" | "changeArrowProperties" | "changeOpacity" | "changeFontSize" | "undo" | "redo" | "finalize" | "changeProjectName" | "changeExportBackground" | "changeExportEmbedScene" | "changeExportScale" | "saveToActiveFile" | "saveFileToDisk" | "loadScene" | "duplicateSelection" | "deleteSelectedElements" | "changeViewBackgroundColor" | "zoomIn" | "zoomOut" | "resetZoom" | "zoomToFit" | "zoomToFitSelection" | "zoomToFitSelectionInViewport" | "changeFontFamily" | "changeTextAlign" | "changeVerticalAlign" | "toggleFullScreen" | "toggleShortcuts" | "group" | "ungroup" | "goToCollaborator" | "addToLibrary" | "changeRoundness" | "alignTop" | "alignBottom" | "alignLeft" | "alignRight" | "alignVerticallyCentered" | "alignHorizontallyCentered" | "distributeHorizontally" | "distributeVertically" | "arrangeElements" | "normaliseElements" | "flipHorizontal" | "flipVertical" | "deselect" | "viewMode" | "exportWithDarkMode" | "toggleTheme" | "increaseFontSize" | "decreaseFontSize" | "unbindText" | "hyperlink" | "bindText" | "unlockAllElements" | "toggleElementLock" | "toggleLinearEditor" | "toggleEraserTool" | "toggleHandTool" | "selectAllElementsInFrame" | "removeAllElementsFromFrame" | "updateFrameRendering" | "setFrameAsActiveTool" | "setEmbeddableAsActiveTool" | "createContainerFromText" | "wrapTextInContainer" | "commandPalette" | "autoResize" | "elementStats" | "searchMenu" | "copyElementLink" | "linkToElement" | "cropEditor" | "wrapSelectionInFrame" | "smartZoom" | "toggleLassoTool" | "toggleShapeSwitch" | "togglePolygon";
|
|
18
18
|
export type PanelComponentProps = {
|
|
19
19
|
elements: readonly ExcalidrawElement[];
|
|
20
20
|
appState: AppState;
|
|
@@ -27,6 +27,7 @@ export declare const clearAppStateForLocalStorage: (appState: Partial<AppState>)
|
|
|
27
27
|
metric: import("./types").NormaliseMetric;
|
|
28
28
|
} | undefined;
|
|
29
29
|
isBindingEnabled?: boolean | undefined;
|
|
30
|
+
boxSelectionMode?: import("./types").BoxSelectionMode | undefined;
|
|
30
31
|
bindingPreference?: "disabled" | "enabled" | undefined;
|
|
31
32
|
isMidpointSnappingEnabled?: boolean | undefined;
|
|
32
33
|
preferredSelectionTool?: {
|
|
@@ -363,6 +363,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
363
363
|
} | "cursor" | "center";
|
|
364
364
|
retainSeed?: boolean;
|
|
365
365
|
fitToContent?: boolean;
|
|
366
|
+
preserveFrameChildrenOrder?: boolean;
|
|
366
367
|
}) => void;
|
|
367
368
|
private addElementsFromMixedContentPaste;
|
|
368
369
|
private addTextFromPaste;
|
|
@@ -505,7 +506,15 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
505
506
|
private handleCanvasClick;
|
|
506
507
|
private getElementLinkAtPosition;
|
|
507
508
|
private handleElementLinkClick;
|
|
509
|
+
/**
|
|
510
|
+
* finds candidate frame under cursor (when dragging frame children/elements
|
|
511
|
+
* inside frames)
|
|
512
|
+
*/
|
|
508
513
|
private getTopLayerFrameAtSceneCoords;
|
|
514
|
+
private updateFrameToHighlight;
|
|
515
|
+
private maybeUpdateFrameToHighlightOnPointerMove;
|
|
516
|
+
private insertNewElements;
|
|
517
|
+
private insertNewElement;
|
|
509
518
|
private handleCanvasPointerMove;
|
|
510
519
|
private handleEraser;
|
|
511
520
|
private handleTouchMove;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./PublishLibrary.scss";
|
|
2
|
-
import type { LibraryItems, UIAppState } from "../types";
|
|
3
|
-
declare const PublishLibrary: ({ onClose, libraryItems, appState, onSuccess, onError, updateItemsInStorage, onRemove, }: {
|
|
2
|
+
import type { CompressImageFile, LibraryItems, UIAppState } from "../types";
|
|
3
|
+
declare const PublishLibrary: ({ onClose, libraryItems, appState, onSuccess, onError, updateItemsInStorage, onRemove, compressImageFile, }: {
|
|
4
4
|
onClose: () => void;
|
|
5
5
|
libraryItems: LibraryItems;
|
|
6
6
|
appState: UIAppState;
|
|
@@ -12,5 +12,6 @@ declare const PublishLibrary: ({ onClose, libraryItems, appState, onSuccess, onE
|
|
|
12
12
|
onError: (error: Error) => void;
|
|
13
13
|
updateItemsInStorage: (items: LibraryItems) => void;
|
|
14
14
|
onRemove: (id: string) => void;
|
|
15
|
+
compressImageFile: CompressImageFile;
|
|
15
16
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
16
17
|
export default PublishLibrary;
|
|
@@ -11,7 +11,7 @@ type InteractiveCanvasProps = {
|
|
|
11
11
|
visibleElements: readonly NonDeletedExcalidrawElement[];
|
|
12
12
|
selectedElements: readonly NonDeletedExcalidrawElement[];
|
|
13
13
|
allElementsMap: NonDeletedSceneElementsMap;
|
|
14
|
-
|
|
14
|
+
canvasNonce: string;
|
|
15
15
|
selectionNonce: number | undefined;
|
|
16
16
|
scale: number;
|
|
17
17
|
appState: InteractiveCanvasAppState;
|
|
@@ -4,6 +4,7 @@ import type { AppState } from "../../types";
|
|
|
4
4
|
import type { RoughCanvas } from "roughjs/bin/canvas";
|
|
5
5
|
interface NewElementCanvasProps {
|
|
6
6
|
appState: AppState;
|
|
7
|
+
newElement: NonNullable<AppState["newElement"]>;
|
|
7
8
|
elementsMap: RenderableElementsMap;
|
|
8
9
|
allElementsMap: NonDeletedSceneElementsMap;
|
|
9
10
|
scale: number;
|
|
@@ -9,7 +9,7 @@ type StaticCanvasProps = {
|
|
|
9
9
|
elementsMap: RenderableElementsMap;
|
|
10
10
|
allElementsMap: NonDeletedSceneElementsMap;
|
|
11
11
|
visibleElements: readonly NonDeletedExcalidrawElement[];
|
|
12
|
-
|
|
12
|
+
canvasNonce: string;
|
|
13
13
|
selectionNonce: number | undefined;
|
|
14
14
|
scale: number;
|
|
15
15
|
appState: StaticCanvasAppState;
|
|
@@ -9,9 +9,10 @@ type Props<T> = {
|
|
|
9
9
|
onChange: (value: T) => void;
|
|
10
10
|
children: React.ReactNode;
|
|
11
11
|
name: string;
|
|
12
|
+
icon?: React.ReactNode;
|
|
12
13
|
};
|
|
13
14
|
declare const DropdownMenuItemContentRadio: {
|
|
14
|
-
<T>({ value, shortcut, onChange, choices, children, name, }: Props<T>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
<T>({ value, shortcut, onChange, choices, children, name, icon, }: Props<T>): import("react/jsx-runtime").JSX.Element;
|
|
15
16
|
displayName: string;
|
|
16
17
|
};
|
|
17
18
|
export default DropdownMenuItemContentRadio;
|
|
@@ -66,6 +66,7 @@ export declare const Preferences: {
|
|
|
66
66
|
additionalItems?: React.ReactNode;
|
|
67
67
|
}): import("react/jsx-runtime").JSX.Element;
|
|
68
68
|
ToggleToolLock: () => import("react/jsx-runtime").JSX.Element;
|
|
69
|
+
BoxSelectionMode: () => import("react/jsx-runtime").JSX.Element;
|
|
69
70
|
ToggleSnapMode: () => import("react/jsx-runtime").JSX.Element;
|
|
70
71
|
ToggleArrowBinding: () => import("react/jsx-runtime").JSX.Element;
|
|
71
72
|
ToggleMidpointSnapping: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { IMAGE_MIME_TYPES, MIME_TYPES } from "@excalidraw/common";
|
|
2
2
|
import type { ValueOf } from "@excalidraw/common/utility-types";
|
|
3
3
|
import type { ExcalidrawElement, FileId } from "@excalidraw/element/types";
|
|
4
|
-
import type { AppState, DataURL, LibraryItem } from "../types";
|
|
4
|
+
import type { AppState, CompressImageFile, DataURL, LibraryItem } from "../types";
|
|
5
5
|
import type { ImportedLibraryData } from "./types";
|
|
6
6
|
export declare const getMimeType: (blob: Blob | string) => string;
|
|
7
7
|
export declare const getFileHandleType: (handle: FileSystemFileHandle | null) => string | null;
|
|
@@ -62,9 +62,9 @@ fileHandle?: FileSystemFileHandle | null) => Promise<{
|
|
|
62
62
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
63
63
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
64
64
|
isBindingEnabled: boolean;
|
|
65
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
65
66
|
bindingPreference: "enabled" | "disabled";
|
|
66
67
|
isMidpointSnappingEnabled: boolean;
|
|
67
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
68
68
|
suggestedBinding: {
|
|
69
69
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
70
70
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -236,9 +236,9 @@ fileHandle?: FileSystemFileHandle | null) => Promise<{
|
|
|
236
236
|
multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
237
237
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
238
238
|
isBindingEnabled: boolean;
|
|
239
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
239
240
|
bindingPreference: "enabled" | "disabled";
|
|
240
241
|
isMidpointSnappingEnabled: boolean;
|
|
241
|
-
startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
242
242
|
suggestedBinding: {
|
|
243
243
|
element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
244
244
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|
|
@@ -368,11 +368,7 @@ export declare const getDataURL: (file: Blob | File) => Promise<DataURL>;
|
|
|
368
368
|
export declare const getDataURL_sync: (data: string | Uint8Array | ArrayBuffer, mimeType: ValueOf<typeof MIME_TYPES>) => DataURL;
|
|
369
369
|
export declare const dataURLToFile: (dataURL: DataURL, filename?: string) => File;
|
|
370
370
|
export declare const dataURLToString: (dataURL: DataURL) => string;
|
|
371
|
-
export declare const resizeImageFile:
|
|
372
|
-
/** undefined indicates auto */
|
|
373
|
-
outputType?: (typeof MIME_TYPES)["jpg"];
|
|
374
|
-
maxWidthOrHeight: number;
|
|
375
|
-
}) => Promise<File>;
|
|
371
|
+
export declare const resizeImageFile: CompressImageFile;
|
|
376
372
|
export declare const SVGStringToFile: (SVGString: string, filename?: string) => File & {
|
|
377
373
|
type: typeof MIME_TYPES.svg;
|
|
378
374
|
};
|
|
@@ -60,9 +60,9 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
|
|
|
60
60
|
multiElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
|
|
61
61
|
selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
|
|
62
62
|
isBindingEnabled: boolean;
|
|
63
|
+
boxSelectionMode: import("../types").BoxSelectionMode;
|
|
63
64
|
bindingPreference: "enabled" | "disabled";
|
|
64
65
|
isMidpointSnappingEnabled: boolean;
|
|
65
|
-
startBoundElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
|
|
66
66
|
suggestedBinding: {
|
|
67
67
|
element: NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
|
|
68
68
|
midPoint?: import("@excalidraw/math").GlobalPoint;
|