@dwelle/excalidraw 0.3.63 → 0.3.66
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/CHANGELOG.md +28 -0
- package/README_NEXT.md +246 -35
- package/dist/excalidraw.development.js +52 -52
- package/dist/excalidraw.production.min.js +1 -1
- package/package.json +8 -8
- package/types/actions/actionAddToLibrary.d.ts +21 -3
- package/types/actions/actionBoundText.d.ts +7 -1
- package/types/actions/actionCanvas.d.ts +57 -9
- package/types/actions/actionClipboard.d.ts +36 -6
- package/types/actions/actionDeleteSelected.d.ts +22 -4
- package/types/actions/actionDuplicateSelection.d.ts +1 -1
- package/types/actions/actionExport.d.ts +64 -10
- package/types/actions/actionFinalize.d.ts +18 -5
- package/types/actions/actionMenu.d.ts +21 -3
- package/types/actions/actionProperties.d.ts +91 -13
- package/types/actions/actionStyles.d.ts +7 -1
- package/types/actions/actionToggleGridMode.d.ts +7 -1
- package/types/actions/actionToggleStats.d.ts +7 -1
- package/types/actions/actionToggleViewMode.d.ts +7 -1
- package/types/actions/actionToggleZenMode.d.ts +7 -1
- package/types/appState.d.ts +8 -2
- package/types/charts.d.ts +8 -0
- package/types/clipboard.d.ts +1 -1
- package/types/components/App.d.ts +9 -3
- package/types/components/Avatar.d.ts +3 -2
- package/types/components/LibraryMenu.d.ts +3 -3
- package/types/components/LibraryMenuItems.d.ts +5 -4
- package/types/components/LibraryUnit.d.ts +2 -1
- package/types/constants.d.ts +3 -0
- package/types/data/blob.d.ts +21 -1
- package/types/data/json.d.ts +0 -2
- package/types/data/library.d.ts +50 -51
- package/types/data/types.d.ts +2 -2
- package/types/distribute.d.ts +6 -0
- package/types/element/Hyperlink.d.ts +7 -1
- package/types/element/linearElementEditor.d.ts +11 -2
- package/types/packages/excalidraw/dist/excalidraw.production.min.d.ts +1 -3
- package/types/packages/excalidraw/index.d.ts +5 -5
- package/types/packages/utils.d.ts +7 -3
- package/types/scene/Scene.d.ts +1 -2
- package/types/types.d.ts +23 -5
- package/types/utils.d.ts +10 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dwelle/excalidraw",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.66",
|
|
4
4
|
"main": "main.js",
|
|
5
5
|
"types": "types/packages/excalidraw/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -40,13 +40,13 @@
|
|
|
40
40
|
"@babel/core": "7.17.0",
|
|
41
41
|
"@babel/plugin-transform-arrow-functions": "7.16.7",
|
|
42
42
|
"@babel/plugin-transform-async-to-generator": "7.16.0",
|
|
43
|
-
"@babel/plugin-transform-runtime": "7.
|
|
43
|
+
"@babel/plugin-transform-runtime": "7.17.10",
|
|
44
44
|
"@babel/plugin-transform-typescript": "7.16.1",
|
|
45
|
-
"@babel/preset-env": "7.
|
|
45
|
+
"@babel/preset-env": "7.17.10",
|
|
46
46
|
"@babel/preset-react": "7.16.7",
|
|
47
47
|
"@babel/preset-typescript": "7.16.7",
|
|
48
|
-
"autoprefixer": "10.4.
|
|
49
|
-
"babel-loader": "8.2.
|
|
48
|
+
"autoprefixer": "10.4.7",
|
|
49
|
+
"babel-loader": "8.2.5",
|
|
50
50
|
"babel-plugin-transform-class-properties": "6.24.1",
|
|
51
51
|
"cross-env": "7.0.3",
|
|
52
52
|
"css-loader": "6.7.1",
|
|
@@ -54,12 +54,12 @@
|
|
|
54
54
|
"postcss-loader": "6.2.1",
|
|
55
55
|
"sass-loader": "12.4.0",
|
|
56
56
|
"terser-webpack-plugin": "5.3.1",
|
|
57
|
-
"ts-loader": "9.
|
|
58
|
-
"typescript": "4.
|
|
57
|
+
"ts-loader": "9.3.0",
|
|
58
|
+
"typescript": "4.6.4",
|
|
59
59
|
"webpack": "5.72.0",
|
|
60
60
|
"webpack-bundle-analyzer": "4.5.0",
|
|
61
61
|
"webpack-cli": "4.9.2",
|
|
62
|
-
"webpack-dev-server": "4.
|
|
62
|
+
"webpack-dev-server": "4.9.0",
|
|
63
63
|
"webpack-merge": "5.8.0"
|
|
64
64
|
},
|
|
65
65
|
"repository": "https://github.com/dwelle/excalidraw",
|
|
@@ -20,7 +20,13 @@ export declare const actionAddToLibrary: {
|
|
|
20
20
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
21
21
|
activeTool: {
|
|
22
22
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
23
|
-
lastActiveToolBeforeEraser: "
|
|
23
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
24
|
+
locked: boolean;
|
|
25
|
+
customType: null;
|
|
26
|
+
} | {
|
|
27
|
+
type: "custom";
|
|
28
|
+
customType: string;
|
|
29
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
24
30
|
locked: boolean;
|
|
25
31
|
};
|
|
26
32
|
penMode: boolean;
|
|
@@ -108,7 +114,13 @@ export declare const actionAddToLibrary: {
|
|
|
108
114
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
109
115
|
activeTool: {
|
|
110
116
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
111
|
-
lastActiveToolBeforeEraser: "
|
|
117
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
118
|
+
locked: boolean;
|
|
119
|
+
customType: null;
|
|
120
|
+
} | {
|
|
121
|
+
type: "custom";
|
|
122
|
+
customType: string;
|
|
123
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
112
124
|
locked: boolean;
|
|
113
125
|
};
|
|
114
126
|
penMode: boolean;
|
|
@@ -197,7 +209,13 @@ export declare const actionAddToLibrary: {
|
|
|
197
209
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
198
210
|
activeTool: {
|
|
199
211
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
200
|
-
lastActiveToolBeforeEraser: "
|
|
212
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
213
|
+
locked: boolean;
|
|
214
|
+
customType: null;
|
|
215
|
+
} | {
|
|
216
|
+
type: "custom";
|
|
217
|
+
customType: string;
|
|
218
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
201
219
|
locked: boolean;
|
|
202
220
|
};
|
|
203
221
|
penMode: boolean;
|
|
@@ -39,7 +39,13 @@ export declare const actionBindText: {
|
|
|
39
39
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
40
40
|
activeTool: {
|
|
41
41
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
42
|
-
lastActiveToolBeforeEraser: "
|
|
42
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
43
|
+
locked: boolean;
|
|
44
|
+
customType: null;
|
|
45
|
+
} | {
|
|
46
|
+
type: "custom";
|
|
47
|
+
customType: string;
|
|
48
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
43
49
|
locked: boolean;
|
|
44
50
|
};
|
|
45
51
|
penMode: boolean;
|
|
@@ -37,7 +37,13 @@ export declare const actionClearCanvas: {
|
|
|
37
37
|
};
|
|
38
38
|
activeTool: {
|
|
39
39
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
40
|
-
lastActiveToolBeforeEraser: "
|
|
40
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
41
|
+
locked: boolean;
|
|
42
|
+
customType: null;
|
|
43
|
+
} | {
|
|
44
|
+
type: "custom";
|
|
45
|
+
customType: string;
|
|
46
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
41
47
|
locked: boolean;
|
|
42
48
|
};
|
|
43
49
|
scrollX: number;
|
|
@@ -47,7 +53,6 @@ export declare const actionClearCanvas: {
|
|
|
47
53
|
value: NormalizedZoomValue;
|
|
48
54
|
}>;
|
|
49
55
|
shouldCacheIgnoreZoom: boolean;
|
|
50
|
-
name: string;
|
|
51
56
|
isLoading: boolean;
|
|
52
57
|
errorMessage: string | null;
|
|
53
58
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
@@ -77,6 +82,7 @@ export declare const actionClearCanvas: {
|
|
|
77
82
|
currentItemLinearStrokeSharpness: import("../element/types").StrokeSharpness;
|
|
78
83
|
cursorButton: "up" | "down";
|
|
79
84
|
scrolledOutside: boolean;
|
|
85
|
+
name: string;
|
|
80
86
|
isResizing: boolean;
|
|
81
87
|
isRotating: boolean;
|
|
82
88
|
openMenu: "canvas" | "shape" | null;
|
|
@@ -134,7 +140,13 @@ export declare const actionZoomIn: {
|
|
|
134
140
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
135
141
|
activeTool: {
|
|
136
142
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
137
|
-
lastActiveToolBeforeEraser: "
|
|
143
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
144
|
+
locked: boolean;
|
|
145
|
+
customType: null;
|
|
146
|
+
} | {
|
|
147
|
+
type: "custom";
|
|
148
|
+
customType: string;
|
|
149
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
138
150
|
locked: boolean;
|
|
139
151
|
};
|
|
140
152
|
penMode: boolean;
|
|
@@ -234,7 +246,13 @@ export declare const actionZoomOut: {
|
|
|
234
246
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
235
247
|
activeTool: {
|
|
236
248
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
237
|
-
lastActiveToolBeforeEraser: "
|
|
249
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
250
|
+
locked: boolean;
|
|
251
|
+
customType: null;
|
|
252
|
+
} | {
|
|
253
|
+
type: "custom";
|
|
254
|
+
customType: string;
|
|
255
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
238
256
|
locked: boolean;
|
|
239
257
|
};
|
|
240
258
|
penMode: boolean;
|
|
@@ -334,7 +352,13 @@ export declare const actionResetZoom: {
|
|
|
334
352
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
335
353
|
activeTool: {
|
|
336
354
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
337
|
-
lastActiveToolBeforeEraser: "
|
|
355
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
356
|
+
locked: boolean;
|
|
357
|
+
customType: null;
|
|
358
|
+
} | {
|
|
359
|
+
type: "custom";
|
|
360
|
+
customType: string;
|
|
361
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
338
362
|
locked: boolean;
|
|
339
363
|
};
|
|
340
364
|
penMode: boolean;
|
|
@@ -434,7 +458,13 @@ export declare const actionZoomToSelected: {
|
|
|
434
458
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
435
459
|
activeTool: {
|
|
436
460
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
437
|
-
lastActiveToolBeforeEraser: "
|
|
461
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
462
|
+
locked: boolean;
|
|
463
|
+
customType: null;
|
|
464
|
+
} | {
|
|
465
|
+
type: "custom";
|
|
466
|
+
customType: string;
|
|
467
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
438
468
|
locked: boolean;
|
|
439
469
|
};
|
|
440
470
|
penMode: boolean;
|
|
@@ -533,7 +563,13 @@ export declare const actionZoomToFit: {
|
|
|
533
563
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
534
564
|
activeTool: {
|
|
535
565
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
536
|
-
lastActiveToolBeforeEraser: "
|
|
566
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
567
|
+
locked: boolean;
|
|
568
|
+
customType: null;
|
|
569
|
+
} | {
|
|
570
|
+
type: "custom";
|
|
571
|
+
customType: string;
|
|
572
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
537
573
|
locked: boolean;
|
|
538
574
|
};
|
|
539
575
|
penMode: boolean;
|
|
@@ -628,7 +664,13 @@ export declare const actionToggleTheme: {
|
|
|
628
664
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
629
665
|
activeTool: {
|
|
630
666
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
631
|
-
lastActiveToolBeforeEraser: "
|
|
667
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
668
|
+
locked: boolean;
|
|
669
|
+
customType: null;
|
|
670
|
+
} | {
|
|
671
|
+
type: "custom";
|
|
672
|
+
customType: string;
|
|
673
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
632
674
|
locked: boolean;
|
|
633
675
|
};
|
|
634
676
|
penMode: boolean;
|
|
@@ -718,7 +760,13 @@ export declare const actionErase: {
|
|
|
718
760
|
selectedGroupIds: {};
|
|
719
761
|
activeTool: {
|
|
720
762
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
721
|
-
lastActiveToolBeforeEraser: "
|
|
763
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
764
|
+
locked: boolean;
|
|
765
|
+
customType: null;
|
|
766
|
+
} | {
|
|
767
|
+
type: "custom";
|
|
768
|
+
customType: string;
|
|
769
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
722
770
|
locked: boolean;
|
|
723
771
|
};
|
|
724
772
|
isLoading: boolean;
|
|
@@ -33,7 +33,13 @@ export declare const actionCut: {
|
|
|
33
33
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
34
34
|
activeTool: {
|
|
35
35
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
36
|
-
lastActiveToolBeforeEraser: "
|
|
36
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
37
|
+
locked: boolean;
|
|
38
|
+
customType: null;
|
|
39
|
+
} | {
|
|
40
|
+
type: "custom";
|
|
41
|
+
customType: string;
|
|
42
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
37
43
|
locked: boolean;
|
|
38
44
|
};
|
|
39
45
|
penMode: boolean;
|
|
@@ -140,7 +146,13 @@ export declare const actionCut: {
|
|
|
140
146
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
141
147
|
activeTool: {
|
|
142
148
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
143
|
-
lastActiveToolBeforeEraser: "
|
|
149
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
150
|
+
locked: boolean;
|
|
151
|
+
customType: null;
|
|
152
|
+
} | {
|
|
153
|
+
type: "custom";
|
|
154
|
+
customType: string;
|
|
155
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
144
156
|
locked: boolean;
|
|
145
157
|
};
|
|
146
158
|
penMode: boolean;
|
|
@@ -218,8 +230,14 @@ export declare const actionCut: {
|
|
|
218
230
|
elements: import("../element/types").ExcalidrawElement[];
|
|
219
231
|
appState: {
|
|
220
232
|
activeTool: {
|
|
221
|
-
type: "selection";
|
|
222
|
-
lastActiveToolBeforeEraser: "
|
|
233
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
234
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
235
|
+
locked: boolean;
|
|
236
|
+
customType: null;
|
|
237
|
+
} | {
|
|
238
|
+
type: "custom";
|
|
239
|
+
customType: string;
|
|
240
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
223
241
|
locked: boolean;
|
|
224
242
|
};
|
|
225
243
|
multiElement: null;
|
|
@@ -331,7 +349,13 @@ export declare const actionCopyAsSvg: {
|
|
|
331
349
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
332
350
|
activeTool: {
|
|
333
351
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
334
|
-
lastActiveToolBeforeEraser: "
|
|
352
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
353
|
+
locked: boolean;
|
|
354
|
+
customType: null;
|
|
355
|
+
} | {
|
|
356
|
+
type: "custom";
|
|
357
|
+
customType: string;
|
|
358
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
335
359
|
locked: boolean;
|
|
336
360
|
};
|
|
337
361
|
penMode: boolean;
|
|
@@ -433,7 +457,13 @@ export declare const actionCopyAsPng: {
|
|
|
433
457
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
434
458
|
activeTool: {
|
|
435
459
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
436
|
-
lastActiveToolBeforeEraser: "
|
|
460
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
461
|
+
locked: boolean;
|
|
462
|
+
customType: null;
|
|
463
|
+
} | {
|
|
464
|
+
type: "custom";
|
|
465
|
+
customType: string;
|
|
466
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
437
467
|
locked: boolean;
|
|
438
468
|
};
|
|
439
469
|
penMode: boolean;
|
|
@@ -24,7 +24,13 @@ export declare const actionDeleteSelected: {
|
|
|
24
24
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
25
25
|
activeTool: {
|
|
26
26
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
27
|
-
lastActiveToolBeforeEraser: "
|
|
27
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
28
|
+
locked: boolean;
|
|
29
|
+
customType: null;
|
|
30
|
+
} | {
|
|
31
|
+
type: "custom";
|
|
32
|
+
customType: string;
|
|
33
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
28
34
|
locked: boolean;
|
|
29
35
|
};
|
|
30
36
|
penMode: boolean;
|
|
@@ -131,7 +137,13 @@ export declare const actionDeleteSelected: {
|
|
|
131
137
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
132
138
|
activeTool: {
|
|
133
139
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
134
|
-
lastActiveToolBeforeEraser: "
|
|
140
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
141
|
+
locked: boolean;
|
|
142
|
+
customType: null;
|
|
143
|
+
} | {
|
|
144
|
+
type: "custom";
|
|
145
|
+
customType: string;
|
|
146
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
135
147
|
locked: boolean;
|
|
136
148
|
};
|
|
137
149
|
penMode: boolean;
|
|
@@ -209,8 +221,14 @@ export declare const actionDeleteSelected: {
|
|
|
209
221
|
elements: ExcalidrawElement[];
|
|
210
222
|
appState: {
|
|
211
223
|
activeTool: {
|
|
212
|
-
type: "selection";
|
|
213
|
-
lastActiveToolBeforeEraser: "
|
|
224
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
225
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
226
|
+
locked: boolean;
|
|
227
|
+
customType: null;
|
|
228
|
+
} | {
|
|
229
|
+
type: "custom";
|
|
230
|
+
customType: string;
|
|
231
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
214
232
|
locked: boolean;
|
|
215
233
|
};
|
|
216
234
|
multiElement: null;
|
|
@@ -9,7 +9,7 @@ export declare const actionDuplicateSelection: {
|
|
|
9
9
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => false | {
|
|
10
10
|
commitToHistory: true;
|
|
11
11
|
elements?: readonly ExcalidrawElement[] | null | undefined;
|
|
12
|
-
appState?: MarkOptional<AppState, "width" | "height" | "
|
|
12
|
+
appState?: MarkOptional<AppState, "width" | "height" | "offsetTop" | "offsetLeft"> | null | undefined;
|
|
13
13
|
files?: import("../types").BinaryFiles | null | undefined;
|
|
14
14
|
syncHistory?: boolean | undefined;
|
|
15
15
|
replaceFiles?: boolean | undefined;
|
|
@@ -19,7 +19,13 @@ export declare const actionChangeProjectName: {
|
|
|
19
19
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
20
20
|
activeTool: {
|
|
21
21
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
22
|
-
lastActiveToolBeforeEraser: "
|
|
22
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
23
|
+
locked: boolean;
|
|
24
|
+
customType: null;
|
|
25
|
+
} | {
|
|
26
|
+
type: "custom";
|
|
27
|
+
customType: string;
|
|
28
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
23
29
|
locked: boolean;
|
|
24
30
|
};
|
|
25
31
|
penMode: boolean;
|
|
@@ -119,7 +125,13 @@ export declare const actionChangeExportScale: {
|
|
|
119
125
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
120
126
|
activeTool: {
|
|
121
127
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
122
|
-
lastActiveToolBeforeEraser: "
|
|
128
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
129
|
+
locked: boolean;
|
|
130
|
+
customType: null;
|
|
131
|
+
} | {
|
|
132
|
+
type: "custom";
|
|
133
|
+
customType: string;
|
|
134
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
123
135
|
locked: boolean;
|
|
124
136
|
};
|
|
125
137
|
penMode: boolean;
|
|
@@ -219,7 +231,13 @@ export declare const actionChangeExportBackground: {
|
|
|
219
231
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
220
232
|
activeTool: {
|
|
221
233
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
222
|
-
lastActiveToolBeforeEraser: "
|
|
234
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
235
|
+
locked: boolean;
|
|
236
|
+
customType: null;
|
|
237
|
+
} | {
|
|
238
|
+
type: "custom";
|
|
239
|
+
customType: string;
|
|
240
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
223
241
|
locked: boolean;
|
|
224
242
|
};
|
|
225
243
|
penMode: boolean;
|
|
@@ -319,7 +337,13 @@ export declare const actionChangeExportEmbedScene: {
|
|
|
319
337
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
320
338
|
activeTool: {
|
|
321
339
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
322
|
-
lastActiveToolBeforeEraser: "
|
|
340
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
341
|
+
locked: boolean;
|
|
342
|
+
customType: null;
|
|
343
|
+
} | {
|
|
344
|
+
type: "custom";
|
|
345
|
+
customType: string;
|
|
346
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
323
347
|
locked: boolean;
|
|
324
348
|
};
|
|
325
349
|
penMode: boolean;
|
|
@@ -420,7 +444,13 @@ export declare const actionSaveToActiveFile: {
|
|
|
420
444
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
421
445
|
activeTool: {
|
|
422
446
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
423
|
-
lastActiveToolBeforeEraser: "
|
|
447
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
448
|
+
locked: boolean;
|
|
449
|
+
customType: null;
|
|
450
|
+
} | {
|
|
451
|
+
type: "custom";
|
|
452
|
+
customType: string;
|
|
453
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
424
454
|
locked: boolean;
|
|
425
455
|
};
|
|
426
456
|
penMode: boolean;
|
|
@@ -522,7 +552,13 @@ export declare const actionSaveFileToDisk: {
|
|
|
522
552
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
523
553
|
activeTool: {
|
|
524
554
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
525
|
-
lastActiveToolBeforeEraser: "
|
|
555
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
556
|
+
locked: boolean;
|
|
557
|
+
customType: null;
|
|
558
|
+
} | {
|
|
559
|
+
type: "custom";
|
|
560
|
+
customType: string;
|
|
561
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
526
562
|
locked: boolean;
|
|
527
563
|
};
|
|
528
564
|
penMode: boolean;
|
|
@@ -613,7 +649,13 @@ export declare const actionLoadScene: {
|
|
|
613
649
|
appState: {
|
|
614
650
|
activeTool: {
|
|
615
651
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
616
|
-
lastActiveToolBeforeEraser: "
|
|
652
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
653
|
+
locked: boolean;
|
|
654
|
+
customType: null;
|
|
655
|
+
} | {
|
|
656
|
+
type: "custom";
|
|
657
|
+
customType: string;
|
|
658
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
617
659
|
locked: boolean;
|
|
618
660
|
};
|
|
619
661
|
scrollX: number;
|
|
@@ -624,7 +666,6 @@ export declare const actionLoadScene: {
|
|
|
624
666
|
}>;
|
|
625
667
|
shouldCacheIgnoreZoom: boolean;
|
|
626
668
|
theme: string;
|
|
627
|
-
name: string;
|
|
628
669
|
isLoading: boolean;
|
|
629
670
|
errorMessage: string | null;
|
|
630
671
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
@@ -658,6 +699,7 @@ export declare const actionLoadScene: {
|
|
|
658
699
|
currentItemLinearStrokeSharpness: import("../element/types").StrokeSharpness;
|
|
659
700
|
cursorButton: "up" | "down";
|
|
660
701
|
scrolledOutside: boolean;
|
|
702
|
+
name: string;
|
|
661
703
|
isResizing: boolean;
|
|
662
704
|
isRotating: boolean;
|
|
663
705
|
openMenu: "canvas" | "shape" | null;
|
|
@@ -711,7 +753,13 @@ export declare const actionLoadScene: {
|
|
|
711
753
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
712
754
|
activeTool: {
|
|
713
755
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
714
|
-
lastActiveToolBeforeEraser: "
|
|
756
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
757
|
+
locked: boolean;
|
|
758
|
+
customType: null;
|
|
759
|
+
} | {
|
|
760
|
+
type: "custom";
|
|
761
|
+
customType: string;
|
|
762
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
715
763
|
locked: boolean;
|
|
716
764
|
};
|
|
717
765
|
penMode: boolean;
|
|
@@ -814,7 +862,13 @@ export declare const actionExportWithDarkMode: {
|
|
|
814
862
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
815
863
|
activeTool: {
|
|
816
864
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
817
|
-
lastActiveToolBeforeEraser: "
|
|
865
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
866
|
+
locked: boolean;
|
|
867
|
+
customType: null;
|
|
868
|
+
} | {
|
|
869
|
+
type: "custom";
|
|
870
|
+
customType: string;
|
|
871
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
818
872
|
locked: boolean;
|
|
819
873
|
};
|
|
820
874
|
penMode: boolean;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { LinearElementEditor } from "../element/linearElementEditor";
|
|
3
|
+
import { AppState } from "../types";
|
|
3
4
|
export declare const actionFinalize: {
|
|
4
5
|
name: "finalize";
|
|
5
6
|
trackEvent: false;
|
|
6
|
-
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<
|
|
7
|
+
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<AppState>, _: any, { canvas, focusContainer }: import("../types").AppClassProperties) => {
|
|
7
8
|
elements: import("../element/types").ExcalidrawElement[] | undefined;
|
|
8
9
|
appState: {
|
|
9
10
|
cursorButton: "up";
|
|
@@ -20,7 +21,13 @@ export declare const actionFinalize: {
|
|
|
20
21
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
21
22
|
activeTool: {
|
|
22
23
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
23
|
-
lastActiveToolBeforeEraser: "
|
|
24
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
25
|
+
locked: boolean;
|
|
26
|
+
customType: null;
|
|
27
|
+
} | {
|
|
28
|
+
type: "custom";
|
|
29
|
+
customType: string;
|
|
30
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
24
31
|
locked: boolean;
|
|
25
32
|
};
|
|
26
33
|
penMode: boolean;
|
|
@@ -99,7 +106,13 @@ export declare const actionFinalize: {
|
|
|
99
106
|
cursorButton: "up";
|
|
100
107
|
activeTool: {
|
|
101
108
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
102
|
-
lastActiveToolBeforeEraser: "
|
|
109
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
110
|
+
locked: boolean;
|
|
111
|
+
customType: null;
|
|
112
|
+
} | {
|
|
113
|
+
type: "custom";
|
|
114
|
+
customType: string;
|
|
115
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
103
116
|
locked: boolean;
|
|
104
117
|
};
|
|
105
118
|
draggingElement: null;
|
|
@@ -184,8 +197,8 @@ export declare const actionFinalize: {
|
|
|
184
197
|
};
|
|
185
198
|
commitToHistory: boolean;
|
|
186
199
|
};
|
|
187
|
-
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState:
|
|
200
|
+
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean;
|
|
188
201
|
PanelComponent: ({ appState, updateData, data }: import("react").PropsWithChildren<import("./types").PanelComponentProps>) => JSX.Element;
|
|
189
202
|
} & {
|
|
190
|
-
keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState:
|
|
203
|
+
keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean) | undefined;
|
|
191
204
|
};
|
|
@@ -20,7 +20,13 @@ export declare const actionToggleCanvasMenu: {
|
|
|
20
20
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
21
21
|
activeTool: {
|
|
22
22
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
23
|
-
lastActiveToolBeforeEraser: "
|
|
23
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
24
|
+
locked: boolean;
|
|
25
|
+
customType: null;
|
|
26
|
+
} | {
|
|
27
|
+
type: "custom";
|
|
28
|
+
customType: string;
|
|
29
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
24
30
|
locked: boolean;
|
|
25
31
|
};
|
|
26
32
|
penMode: boolean;
|
|
@@ -119,7 +125,13 @@ export declare const actionToggleEditMenu: {
|
|
|
119
125
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
120
126
|
activeTool: {
|
|
121
127
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
122
|
-
lastActiveToolBeforeEraser: "
|
|
128
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
129
|
+
locked: boolean;
|
|
130
|
+
customType: null;
|
|
131
|
+
} | {
|
|
132
|
+
type: "custom";
|
|
133
|
+
customType: string;
|
|
134
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
123
135
|
locked: boolean;
|
|
124
136
|
};
|
|
125
137
|
penMode: boolean;
|
|
@@ -232,7 +244,13 @@ export declare const actionShortcuts: {
|
|
|
232
244
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
233
245
|
activeTool: {
|
|
234
246
|
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
235
|
-
lastActiveToolBeforeEraser: "
|
|
247
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
248
|
+
locked: boolean;
|
|
249
|
+
customType: null;
|
|
250
|
+
} | {
|
|
251
|
+
type: "custom";
|
|
252
|
+
customType: string;
|
|
253
|
+
lastActiveToolBeforeEraser: import("../types").LastActiveToolBeforeEraser;
|
|
236
254
|
locked: boolean;
|
|
237
255
|
};
|
|
238
256
|
penMode: boolean;
|