@zsviczian/excalidraw 0.16.1-obsidian-2 → 0.16.1-obsidian-3

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.
Files changed (50) hide show
  1. package/dist/excalidraw.development.js +90 -24
  2. package/dist/excalidraw.production.min.js +1 -1
  3. package/package.json +1 -1
  4. package/types/actions/actionAddToLibrary.d.ts +9 -27
  5. package/types/actions/actionAlign.d.ts +8 -8
  6. package/types/actions/actionBoundText.d.ts +6 -18
  7. package/types/actions/actionCanvas.d.ts +206 -125
  8. package/types/actions/actionClipboard.d.ts +19 -49
  9. package/types/actions/actionDeleteSelected.d.ts +11 -29
  10. package/types/actions/actionDistribute.d.ts +4 -4
  11. package/types/actions/actionDuplicateSelection.d.ts +2 -2
  12. package/types/actions/actionElementLock.d.ts +8 -20
  13. package/types/actions/actionExport.d.ts +35 -89
  14. package/types/actions/actionFinalize.d.ts +8 -20
  15. package/types/actions/actionFlip.d.ts +4 -4
  16. package/types/actions/actionFrame.d.ts +11 -29
  17. package/types/actions/actionGroup.d.ts +10 -22
  18. package/types/actions/actionLinearEditor.d.ts +3 -9
  19. package/types/actions/actionMenu.d.ts +13 -31
  20. package/types/actions/actionProperties.d.ts +43 -121
  21. package/types/actions/actionSelectAll.d.ts +5 -11
  22. package/types/actions/actionStyles.d.ts +7 -13
  23. package/types/actions/actionToggleGridMode.d.ts +5 -11
  24. package/types/actions/actionToggleObjectsSnapMode.d.ts +5 -11
  25. package/types/actions/actionToggleStats.d.ts +5 -11
  26. package/types/actions/actionToggleViewMode.d.ts +5 -11
  27. package/types/actions/actionToggleZenMode.d.ts +5 -11
  28. package/types/actions/actionZindex.d.ts +8 -8
  29. package/types/actions/shortcuts.d.ts +1 -1
  30. package/types/actions/types.d.ts +1 -1
  31. package/types/appState.d.ts +7 -10
  32. package/types/components/Actions.d.ts +3 -4
  33. package/types/components/App.d.ts +7 -6
  34. package/types/components/ColorPicker/colorPickerUtils.d.ts +1 -1
  35. package/types/components/LaserTool/LaserPathManager.d.ts +28 -0
  36. package/types/components/LaserTool/LaserPointerButton.d.ts +10 -0
  37. package/types/components/LaserTool/LaserTool.d.ts +7 -0
  38. package/types/components/LayerUI.d.ts +2 -1
  39. package/types/components/dropdownMenu/DropdownMenu.d.ts +6 -3
  40. package/types/components/dropdownMenu/DropdownMenuItem.d.ts +2 -1
  41. package/types/components/dropdownMenu/DropdownMenuItemCustom.d.ts +2 -1
  42. package/types/components/dropdownMenu/DropdownMenuItemLink.d.ts +2 -1
  43. package/types/components/dropdownMenu/common.d.ts +1 -1
  44. package/types/components/icons.d.ts +2 -0
  45. package/types/components/main-menu/MainMenu.d.ts +6 -3
  46. package/types/element/Hyperlink.d.ts +5 -11
  47. package/types/element/embeddable.d.ts +3 -9
  48. package/types/element/linearElementEditor.d.ts +3 -9
  49. package/types/types.d.ts +15 -17
  50. package/types/utils.d.ts +3 -4
@@ -65,15 +65,9 @@ export declare const actionCut: {
65
65
  elementsToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawElement>[] | null;
66
66
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
67
67
  activeTool: {
68
- lastActiveTool: import("../types").LastActiveTool;
68
+ lastActiveTool: import("../types").ActiveTool | null;
69
69
  locked: boolean;
70
- } & ({
71
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
72
- customType: null;
73
- } | {
74
- type: "custom";
75
- customType: string;
76
- });
70
+ } & import("../types").ActiveTool;
77
71
  penMode: boolean;
78
72
  penDetected: boolean;
79
73
  exportBackground: boolean;
@@ -178,7 +172,7 @@ export declare const actionCut: {
178
172
  dynamicStyle: string;
179
173
  invertBindingBehaviour: boolean;
180
174
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
181
- snapLines: import("../snapping").SnapLine[];
175
+ snapLines: readonly import("../snapping").SnapLine[];
182
176
  originSnapOffset: {
183
177
  x: number;
184
178
  y: number;
@@ -248,15 +242,9 @@ export declare const actionCut: {
248
242
  elementsToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawElement>[] | null;
249
243
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
250
244
  activeTool: {
251
- lastActiveTool: import("../types").LastActiveTool;
245
+ lastActiveTool: import("../types").ActiveTool | null;
252
246
  locked: boolean;
253
- } & ({
254
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
255
- customType: null;
256
- } | {
257
- type: "custom";
258
- customType: string;
259
- });
247
+ } & import("../types").ActiveTool;
260
248
  penMode: boolean;
261
249
  penDetected: boolean;
262
250
  exportBackground: boolean;
@@ -361,7 +349,7 @@ export declare const actionCut: {
361
349
  dynamicStyle: string;
362
350
  invertBindingBehaviour: boolean;
363
351
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
364
- snapLines: import("../snapping").SnapLine[];
352
+ snapLines: readonly import("../snapping").SnapLine[];
365
353
  originSnapOffset: {
366
354
  x: number;
367
355
  y: number;
@@ -373,15 +361,9 @@ export declare const actionCut: {
373
361
  elements: import("../element/types").ExcalidrawElement[];
374
362
  appState: {
375
363
  activeTool: {
376
- lastActiveTool: import("../types").LastActiveTool;
364
+ lastActiveTool: import("../types").ActiveTool | null;
377
365
  locked: boolean;
378
- } & ({
379
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
380
- customType: null;
381
- } | {
382
- type: "custom";
383
- customType: string;
384
- });
366
+ } & import("../types").ActiveTool;
385
367
  multiElement: null;
386
368
  activeEmbeddable: null;
387
369
  selectedElementIds: {};
@@ -511,7 +493,7 @@ export declare const actionCut: {
511
493
  dynamicStyle: string;
512
494
  invertBindingBehaviour: boolean;
513
495
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
514
- snapLines: import("../snapping").SnapLine[];
496
+ snapLines: readonly import("../snapping").SnapLine[];
515
497
  originSnapOffset: {
516
498
  x: number;
517
499
  y: number;
@@ -522,9 +504,9 @@ export declare const actionCut: {
522
504
  };
523
505
  predicate: (elements: readonly import("../element/types").ExcalidrawElement[], appState: import("../types").AppState, appProps: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
524
506
  contextItemLabel: string;
525
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
507
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
526
508
  } & {
527
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
509
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
528
510
  };
529
511
  export declare const actionCopyAsSvg: {
530
512
  name: "copyAsSvg";
@@ -567,15 +549,9 @@ export declare const actionCopyAsSvg: {
567
549
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
568
550
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
569
551
  activeTool: {
570
- lastActiveTool: import("../types").LastActiveTool;
552
+ lastActiveTool: import("../types").ActiveTool | null;
571
553
  locked: boolean;
572
- } & ({
573
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
574
- customType: null;
575
- } | {
576
- type: "custom";
577
- customType: string;
578
- });
554
+ } & import("../types").ActiveTool;
579
555
  penMode: boolean;
580
556
  penDetected: boolean;
581
557
  exportBackground: boolean;
@@ -680,7 +656,7 @@ export declare const actionCopyAsSvg: {
680
656
  dynamicStyle: string;
681
657
  invertBindingBehaviour: boolean;
682
658
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
683
- snapLines: import("../snapping").SnapLine[];
659
+ snapLines: readonly import("../snapping").SnapLine[];
684
660
  originSnapOffset: {
685
661
  x: number;
686
662
  y: number;
@@ -735,15 +711,9 @@ export declare const actionCopyAsPng: {
735
711
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
736
712
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
737
713
  activeTool: {
738
- lastActiveTool: import("../types").LastActiveTool;
714
+ lastActiveTool: import("../types").ActiveTool | null;
739
715
  locked: boolean;
740
- } & ({
741
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
742
- customType: null;
743
- } | {
744
- type: "custom";
745
- customType: string;
746
- });
716
+ } & import("../types").ActiveTool;
747
717
  penMode: boolean;
748
718
  penDetected: boolean;
749
719
  exportBackground: boolean;
@@ -848,7 +818,7 @@ export declare const actionCopyAsPng: {
848
818
  dynamicStyle: string;
849
819
  invertBindingBehaviour: boolean;
850
820
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
851
- snapLines: import("../snapping").SnapLine[];
821
+ snapLines: readonly import("../snapping").SnapLine[];
852
822
  originSnapOffset: {
853
823
  x: number;
854
824
  y: number;
@@ -859,9 +829,9 @@ export declare const actionCopyAsPng: {
859
829
  }>;
860
830
  predicate: (elements: readonly import("../element/types").ExcalidrawElement[]) => boolean;
861
831
  contextItemLabel: string;
862
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
832
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
863
833
  } & {
864
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
834
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
865
835
  };
866
836
  export declare const copyText: {
867
837
  name: "copyText";
@@ -41,15 +41,9 @@ export declare const actionDeleteSelected: {
41
41
  elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
42
42
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
43
43
  activeTool: {
44
- lastActiveTool: import("../types").LastActiveTool;
44
+ lastActiveTool: import("../types").ActiveTool | null;
45
45
  locked: boolean;
46
- } & ({
47
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
48
- customType: null;
49
- } | {
50
- type: "custom";
51
- customType: string;
52
- });
46
+ } & import("../types").ActiveTool;
53
47
  penMode: boolean;
54
48
  penDetected: boolean;
55
49
  exportBackground: boolean;
@@ -154,7 +148,7 @@ export declare const actionDeleteSelected: {
154
148
  dynamicStyle: string;
155
149
  invertBindingBehaviour: boolean;
156
150
  selectedLinearElement: LinearElementEditor | null;
157
- snapLines: import("../snapping").SnapLine[];
151
+ snapLines: readonly import("../snapping").SnapLine[];
158
152
  originSnapOffset: {
159
153
  x: number;
160
154
  y: number;
@@ -224,15 +218,9 @@ export declare const actionDeleteSelected: {
224
218
  elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
225
219
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
226
220
  activeTool: {
227
- lastActiveTool: import("../types").LastActiveTool;
221
+ lastActiveTool: import("../types").ActiveTool | null;
228
222
  locked: boolean;
229
- } & ({
230
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
231
- customType: null;
232
- } | {
233
- type: "custom";
234
- customType: string;
235
- });
223
+ } & import("../types").ActiveTool;
236
224
  penMode: boolean;
237
225
  penDetected: boolean;
238
226
  exportBackground: boolean;
@@ -337,7 +325,7 @@ export declare const actionDeleteSelected: {
337
325
  dynamicStyle: string;
338
326
  invertBindingBehaviour: boolean;
339
327
  selectedLinearElement: LinearElementEditor | null;
340
- snapLines: import("../snapping").SnapLine[];
328
+ snapLines: readonly import("../snapping").SnapLine[];
341
329
  originSnapOffset: {
342
330
  x: number;
343
331
  y: number;
@@ -349,15 +337,9 @@ export declare const actionDeleteSelected: {
349
337
  elements: ExcalidrawElement[];
350
338
  appState: {
351
339
  activeTool: {
352
- lastActiveTool: import("../types").LastActiveTool;
340
+ lastActiveTool: import("../types").ActiveTool | null;
353
341
  locked: boolean;
354
- } & ({
355
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
356
- customType: null;
357
- } | {
358
- type: "custom";
359
- customType: string;
360
- });
342
+ } & import("../types").ActiveTool;
361
343
  multiElement: null;
362
344
  activeEmbeddable: null;
363
345
  selectedElementIds: {};
@@ -487,7 +469,7 @@ export declare const actionDeleteSelected: {
487
469
  dynamicStyle: string;
488
470
  invertBindingBehaviour: boolean;
489
471
  selectedLinearElement: LinearElementEditor | null;
490
- snapLines: import("../snapping").SnapLine[];
472
+ snapLines: readonly import("../snapping").SnapLine[];
491
473
  originSnapOffset: {
492
474
  x: number;
493
475
  y: number;
@@ -497,8 +479,8 @@ export declare const actionDeleteSelected: {
497
479
  commitToHistory: boolean;
498
480
  };
499
481
  contextItemLabel: string;
500
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly ExcalidrawElement[]) => boolean;
482
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[]) => boolean;
501
483
  PanelComponent: ({ elements, appState, updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
502
484
  } & {
503
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly ExcalidrawElement[]) => boolean) | undefined;
485
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[]) => boolean) | undefined;
504
486
  };
@@ -10,10 +10,10 @@ export declare const distributeHorizontally: {
10
10
  elements: import("../scene/Scene").ExcalidrawElementsIncludingDeleted;
11
11
  commitToHistory: true;
12
12
  };
13
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
13
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
14
14
  PanelComponent: ({ elements, appState, updateData, app }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
15
15
  } & {
16
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
16
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
17
17
  };
18
18
  export declare const distributeVertically: {
19
19
  name: "distributeVertically";
@@ -25,8 +25,8 @@ export declare const distributeVertically: {
25
25
  elements: import("../scene/Scene").ExcalidrawElementsIncludingDeleted;
26
26
  commitToHistory: true;
27
27
  };
28
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
28
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
29
29
  PanelComponent: ({ elements, appState, updateData, app }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
30
30
  } & {
31
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
31
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
32
32
  };
@@ -14,8 +14,8 @@ export declare const actionDuplicateSelection: {
14
14
  replaceFiles?: boolean | undefined;
15
15
  };
16
16
  contextItemLabel: string;
17
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
17
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
18
18
  PanelComponent: ({ elements, appState, updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
19
19
  } & {
20
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
20
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
21
21
  };
@@ -40,15 +40,9 @@ export declare const actionToggleElementLock: {
40
40
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
41
41
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
42
42
  activeTool: {
43
- lastActiveTool: import("../types").LastActiveTool;
43
+ lastActiveTool: import("../types").ActiveTool | null;
44
44
  locked: boolean;
45
- } & ({
46
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
47
- customType: null;
48
- } | {
49
- type: "custom";
50
- customType: string;
51
- });
45
+ } & import("../types").ActiveTool;
52
46
  penMode: boolean;
53
47
  penDetected: boolean;
54
48
  exportBackground: boolean;
@@ -152,7 +146,7 @@ export declare const actionToggleElementLock: {
152
146
  };
153
147
  dynamicStyle: string;
154
148
  invertBindingBehaviour: boolean;
155
- snapLines: import("../snapping").SnapLine[];
149
+ snapLines: readonly import("../snapping").SnapLine[];
156
150
  originSnapOffset: {
157
151
  x: number;
158
152
  y: number;
@@ -162,9 +156,9 @@ export declare const actionToggleElementLock: {
162
156
  commitToHistory: true;
163
157
  };
164
158
  contextItemLabel: (elements: readonly ExcalidrawElement[], appState: Readonly<import("../types").AppState>, app: import("../types").AppClassProperties) => "labels.elementLock.unlock" | "labels.elementLock.lock" | "labels.elementLock.lockAll" | "labels.elementLock.unlockAll";
165
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: import("../types").AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean;
159
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent, appState: import("../types").AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean;
166
160
  } & {
167
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: import("../types").AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
161
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent, appState: import("../types").AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
168
162
  };
169
163
  export declare const actionUnlockAllElements: {
170
164
  name: "unlockAllElements";
@@ -210,15 +204,9 @@ export declare const actionUnlockAllElements: {
210
204
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
211
205
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
212
206
  activeTool: {
213
- lastActiveTool: import("../types").LastActiveTool;
207
+ lastActiveTool: import("../types").ActiveTool | null;
214
208
  locked: boolean;
215
- } & ({
216
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
217
- customType: null;
218
- } | {
219
- type: "custom";
220
- customType: string;
221
- });
209
+ } & import("../types").ActiveTool;
222
210
  penMode: boolean;
223
211
  penDetected: boolean;
224
212
  exportBackground: boolean;
@@ -320,7 +308,7 @@ export declare const actionUnlockAllElements: {
320
308
  dynamicStyle: string;
321
309
  invertBindingBehaviour: boolean;
322
310
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
323
- snapLines: import("../snapping").SnapLine[];
311
+ snapLines: readonly import("../snapping").SnapLine[];
324
312
  originSnapOffset: {
325
313
  x: number;
326
314
  y: number;
@@ -37,15 +37,9 @@ export declare const actionChangeProjectName: {
37
37
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
38
38
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
39
39
  activeTool: {
40
- lastActiveTool: import("../types").LastActiveTool;
40
+ lastActiveTool: import("../types").ActiveTool | null;
41
41
  locked: boolean;
42
- } & ({
43
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
44
- customType: null;
45
- } | {
46
- type: "custom";
47
- customType: string;
48
- });
42
+ } & import("../types").ActiveTool;
49
43
  penMode: boolean;
50
44
  penDetected: boolean;
51
45
  exportBackground: boolean;
@@ -149,7 +143,7 @@ export declare const actionChangeProjectName: {
149
143
  dynamicStyle: string;
150
144
  invertBindingBehaviour: boolean;
151
145
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
152
- snapLines: import("../snapping").SnapLine[];
146
+ snapLines: readonly import("../snapping").SnapLine[];
153
147
  originSnapOffset: {
154
148
  x: number;
155
149
  y: number;
@@ -202,15 +196,9 @@ export declare const actionChangeExportScale: {
202
196
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
203
197
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
204
198
  activeTool: {
205
- lastActiveTool: import("../types").LastActiveTool;
199
+ lastActiveTool: import("../types").ActiveTool | null;
206
200
  locked: boolean;
207
- } & ({
208
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
209
- customType: null;
210
- } | {
211
- type: "custom";
212
- customType: string;
213
- });
201
+ } & import("../types").ActiveTool;
214
202
  penMode: boolean;
215
203
  penDetected: boolean;
216
204
  exportBackground: boolean;
@@ -314,7 +302,7 @@ export declare const actionChangeExportScale: {
314
302
  dynamicStyle: string;
315
303
  invertBindingBehaviour: boolean;
316
304
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
317
- snapLines: import("../snapping").SnapLine[];
305
+ snapLines: readonly import("../snapping").SnapLine[];
318
306
  originSnapOffset: {
319
307
  x: number;
320
308
  y: number;
@@ -367,15 +355,9 @@ export declare const actionChangeExportBackground: {
367
355
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
368
356
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
369
357
  activeTool: {
370
- lastActiveTool: import("../types").LastActiveTool;
358
+ lastActiveTool: import("../types").ActiveTool | null;
371
359
  locked: boolean;
372
- } & ({
373
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
374
- customType: null;
375
- } | {
376
- type: "custom";
377
- customType: string;
378
- });
360
+ } & import("../types").ActiveTool;
379
361
  penMode: boolean;
380
362
  penDetected: boolean;
381
363
  exportEmbedScene: boolean;
@@ -479,7 +461,7 @@ export declare const actionChangeExportBackground: {
479
461
  dynamicStyle: string;
480
462
  invertBindingBehaviour: boolean;
481
463
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
482
- snapLines: import("../snapping").SnapLine[];
464
+ snapLines: readonly import("../snapping").SnapLine[];
483
465
  originSnapOffset: {
484
466
  x: number;
485
467
  y: number;
@@ -532,15 +514,9 @@ export declare const actionChangeExportEmbedScene: {
532
514
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
533
515
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
534
516
  activeTool: {
535
- lastActiveTool: import("../types").LastActiveTool;
517
+ lastActiveTool: import("../types").ActiveTool | null;
536
518
  locked: boolean;
537
- } & ({
538
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
539
- customType: null;
540
- } | {
541
- type: "custom";
542
- customType: string;
543
- });
519
+ } & import("../types").ActiveTool;
544
520
  penMode: boolean;
545
521
  penDetected: boolean;
546
522
  exportBackground: boolean;
@@ -644,7 +620,7 @@ export declare const actionChangeExportEmbedScene: {
644
620
  dynamicStyle: string;
645
621
  invertBindingBehaviour: boolean;
646
622
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
647
- snapLines: import("../snapping").SnapLine[];
623
+ snapLines: readonly import("../snapping").SnapLine[];
648
624
  originSnapOffset: {
649
625
  x: number;
650
626
  y: number;
@@ -701,15 +677,9 @@ export declare const actionSaveToActiveFile: {
701
677
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
702
678
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
703
679
  activeTool: {
704
- lastActiveTool: import("../types").LastActiveTool;
680
+ lastActiveTool: import("../types").ActiveTool | null;
705
681
  locked: boolean;
706
- } & ({
707
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
708
- customType: null;
709
- } | {
710
- type: "custom";
711
- customType: string;
712
- });
682
+ } & import("../types").ActiveTool;
713
683
  penMode: boolean;
714
684
  penDetected: boolean;
715
685
  exportBackground: boolean;
@@ -808,7 +778,7 @@ export declare const actionSaveToActiveFile: {
808
778
  dynamicStyle: string;
809
779
  invertBindingBehaviour: boolean;
810
780
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
811
- snapLines: import("../snapping").SnapLine[];
781
+ snapLines: readonly import("../snapping").SnapLine[];
812
782
  originSnapOffset: {
813
783
  x: number;
814
784
  y: number;
@@ -819,9 +789,9 @@ export declare const actionSaveToActiveFile: {
819
789
  commitToHistory: false;
820
790
  appState?: undefined;
821
791
  }>;
822
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
792
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
823
793
  } & {
824
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
794
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
825
795
  };
826
796
  export declare const actionSaveFileToDisk: {
827
797
  name: "saveFileToDisk";
@@ -864,15 +834,9 @@ export declare const actionSaveFileToDisk: {
864
834
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
865
835
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
866
836
  activeTool: {
867
- lastActiveTool: import("../types").LastActiveTool;
837
+ lastActiveTool: import("../types").ActiveTool | null;
868
838
  locked: boolean;
869
- } & ({
870
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
871
- customType: null;
872
- } | {
873
- type: "custom";
874
- customType: string;
875
- });
839
+ } & import("../types").ActiveTool;
876
840
  penMode: boolean;
877
841
  penDetected: boolean;
878
842
  exportBackground: boolean;
@@ -976,7 +940,7 @@ export declare const actionSaveFileToDisk: {
976
940
  dynamicStyle: string;
977
941
  invertBindingBehaviour: boolean;
978
942
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
979
- snapLines: import("../snapping").SnapLine[];
943
+ snapLines: readonly import("../snapping").SnapLine[];
980
944
  originSnapOffset: {
981
945
  x: number;
982
946
  y: number;
@@ -987,10 +951,10 @@ export declare const actionSaveFileToDisk: {
987
951
  commitToHistory: false;
988
952
  appState?: undefined;
989
953
  }>;
990
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
954
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
991
955
  PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
992
956
  } & {
993
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
957
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
994
958
  };
995
959
  export declare const actionLoadScene: {
996
960
  name: "loadScene";
@@ -1001,18 +965,11 @@ export declare const actionLoadScene: {
1001
965
  perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: any, app: import("../types").AppClassProperties) => Promise<false | {
1002
966
  elements: import("../element/types").ExcalidrawElement[];
1003
967
  appState: {
1004
- theme: Theme;
1005
- name: string;
1006
968
  activeTool: {
1007
- lastActiveTool: import("../types").LastActiveTool;
969
+ lastActiveTool: import("../types").ActiveTool | null;
1008
970
  locked: boolean;
1009
- } & ({
1010
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
1011
- customType: null;
1012
- } | {
1013
- type: "custom";
1014
- customType: string;
1015
- });
971
+ } & import("../types").ActiveTool;
972
+ name: string;
1016
973
  toast: {
1017
974
  message: string;
1018
975
  closable?: boolean | undefined;
@@ -1096,6 +1053,7 @@ export declare const actionLoadScene: {
1096
1053
  selectedElementsAreBeingDragged: boolean;
1097
1054
  shouldCacheIgnoreZoom: boolean;
1098
1055
  zenModeEnabled: boolean;
1056
+ theme: Theme;
1099
1057
  gridSize: number | null;
1100
1058
  previousGridSize: number | null;
1101
1059
  viewModeEnabled: boolean;
@@ -1141,7 +1099,7 @@ export declare const actionLoadScene: {
1141
1099
  dynamicStyle: string;
1142
1100
  invertBindingBehaviour: boolean;
1143
1101
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
1144
- snapLines: import("../snapping").SnapLine[];
1102
+ snapLines: readonly import("../snapping").SnapLine[];
1145
1103
  originSnapOffset: {
1146
1104
  x: number;
1147
1105
  y: number;
@@ -1184,15 +1142,9 @@ export declare const actionLoadScene: {
1184
1142
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
1185
1143
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
1186
1144
  activeTool: {
1187
- lastActiveTool: import("../types").LastActiveTool;
1145
+ lastActiveTool: import("../types").ActiveTool | null;
1188
1146
  locked: boolean;
1189
- } & ({
1190
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
1191
- customType: null;
1192
- } | {
1193
- type: "custom";
1194
- customType: string;
1195
- });
1147
+ } & import("../types").ActiveTool;
1196
1148
  penMode: boolean;
1197
1149
  penDetected: boolean;
1198
1150
  exportBackground: boolean;
@@ -1297,7 +1249,7 @@ export declare const actionLoadScene: {
1297
1249
  dynamicStyle: string;
1298
1250
  invertBindingBehaviour: boolean;
1299
1251
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
1300
- snapLines: import("../snapping").SnapLine[];
1252
+ snapLines: readonly import("../snapping").SnapLine[];
1301
1253
  originSnapOffset: {
1302
1254
  x: number;
1303
1255
  y: number;
@@ -1307,9 +1259,9 @@ export declare const actionLoadScene: {
1307
1259
  files: import("../types").BinaryFiles;
1308
1260
  commitToHistory: false;
1309
1261
  }>;
1310
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1262
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
1311
1263
  } & {
1312
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1264
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
1313
1265
  };
1314
1266
  export declare const actionExportWithDarkMode: {
1315
1267
  name: "exportWithDarkMode";
@@ -1351,15 +1303,9 @@ export declare const actionExportWithDarkMode: {
1351
1303
  editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
1352
1304
  editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
1353
1305
  activeTool: {
1354
- lastActiveTool: import("../types").LastActiveTool;
1306
+ lastActiveTool: import("../types").ActiveTool | null;
1355
1307
  locked: boolean;
1356
- } & ({
1357
- type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand" | "mermaid";
1358
- customType: null;
1359
- } | {
1360
- type: "custom";
1361
- customType: string;
1362
- });
1308
+ } & import("../types").ActiveTool;
1363
1309
  penMode: boolean;
1364
1310
  penDetected: boolean;
1365
1311
  exportBackground: boolean;
@@ -1463,7 +1409,7 @@ export declare const actionExportWithDarkMode: {
1463
1409
  dynamicStyle: string;
1464
1410
  invertBindingBehaviour: boolean;
1465
1411
  selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
1466
- snapLines: import("../snapping").SnapLine[];
1412
+ snapLines: readonly import("../snapping").SnapLine[];
1467
1413
  originSnapOffset: {
1468
1414
  x: number;
1469
1415
  y: number;