@dwelle/excalidraw 0.3.54 → 0.3.57
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 +18 -0
- package/dist/excalidraw-assets-dev/{image-73be8b3c1837ea26950c.js → image-eddc6ed66acd3a3f3d46.js} +0 -0
- package/dist/excalidraw.development.js +63 -63
- package/dist/excalidraw.production.min.js +1 -1
- package/package.json +2 -2
- package/types/actions/actionAddToLibrary.d.ts +18 -6
- package/types/actions/actionAlign.d.ts +18 -0
- package/types/actions/actionBoundText.d.ts +116 -0
- package/types/actions/actionCanvas.d.ts +67 -18
- package/types/actions/actionClipboard.d.ts +37 -10
- package/types/actions/actionDeleteSelected.d.ts +19 -6
- package/types/actions/actionDistribute.d.ts +6 -0
- package/types/actions/actionDuplicateSelection.d.ts +3 -0
- package/types/actions/actionExport.d.ts +71 -18
- package/types/actions/actionFinalize.d.ts +11 -4
- package/types/actions/actionFlip.d.ts +6 -0
- package/types/actions/actionGroup.d.ts +6 -0
- package/types/actions/actionMenu.d.ts +29 -6
- package/types/actions/actionNavigate.d.ts +3 -0
- package/types/actions/actionProperties.d.ts +82 -26
- package/types/actions/actionSelectAll.d.ts +3 -0
- package/types/actions/actionStyles.d.ts +11 -2
- package/types/actions/actionToggleGridMode.d.ts +9 -2
- package/types/actions/actionToggleStats.d.ts +8 -2
- package/types/actions/actionToggleViewMode.d.ts +9 -2
- package/types/actions/actionToggleZenMode.d.ts +9 -2
- package/types/actions/actionZindex.d.ts +12 -0
- package/types/actions/index.d.ts +1 -1
- package/types/actions/manager.d.ts +3 -3
- package/types/actions/types.d.ts +7 -9
- package/types/appState.d.ts +9 -4
- package/types/components/Actions.d.ts +4 -4
- package/types/components/App.d.ts +3 -2
- package/types/components/ImageExportDialog.d.ts +2 -2
- package/types/components/JSONExportDialog.d.ts +2 -2
- package/types/components/ToolButton.d.ts +3 -0
- package/types/constants.d.ts +1 -0
- package/types/data/restore.d.ts +1 -1
- package/types/element/Hyperlink.d.ts +9 -3
- package/types/element/dragElements.d.ts +1 -1
- package/types/element/linearElementEditor.d.ts +5 -2
- package/types/element/sizeHelpers.d.ts +2 -1
- package/types/element/textElement.d.ts +1 -2
- package/types/element/typeChecks.d.ts +2 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/image-eddc6ed66acd3a3f3d46.d.ts +0 -0
- package/types/scene/Scene.d.ts +1 -1
- package/types/types.d.ts +10 -3
- package/types/utils.d.ts +2 -0
|
@@ -3,6 +3,9 @@ import { ExcalidrawElement } from "../element/types";
|
|
|
3
3
|
import { AppState } from "../types";
|
|
4
4
|
export declare const distributeHorizontally: {
|
|
5
5
|
name: "distributeHorizontally";
|
|
6
|
+
trackEvent: {
|
|
7
|
+
category: "element";
|
|
8
|
+
};
|
|
6
9
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
7
10
|
appState: Readonly<AppState>;
|
|
8
11
|
elements: ExcalidrawElement[];
|
|
@@ -15,6 +18,9 @@ export declare const distributeHorizontally: {
|
|
|
15
18
|
};
|
|
16
19
|
export declare const distributeVertically: {
|
|
17
20
|
name: "distributeVertically";
|
|
21
|
+
trackEvent: {
|
|
22
|
+
category: "element";
|
|
23
|
+
};
|
|
18
24
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
19
25
|
appState: Readonly<AppState>;
|
|
20
26
|
elements: ExcalidrawElement[];
|
|
@@ -3,6 +3,9 @@ import { ExcalidrawElement } from "../element/types";
|
|
|
3
3
|
import { AppState } from "../types";
|
|
4
4
|
export declare const actionDuplicateSelection: {
|
|
5
5
|
name: "duplicateSelection";
|
|
6
|
+
trackEvent: {
|
|
7
|
+
category: "element";
|
|
8
|
+
};
|
|
6
9
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => false | {
|
|
7
10
|
commitToHistory: true;
|
|
8
11
|
elements?: readonly ExcalidrawElement[] | null | undefined;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import "../components/ToolIcon.scss";
|
|
3
3
|
export declare const actionChangeProjectName: {
|
|
4
4
|
name: "changeProjectName";
|
|
5
|
+
trackEvent: false;
|
|
5
6
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
6
7
|
appState: {
|
|
7
8
|
name: any;
|
|
@@ -16,8 +17,11 @@ export declare const actionChangeProjectName: {
|
|
|
16
17
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
17
18
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
18
19
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
activeTool: {
|
|
21
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
22
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
23
|
+
locked: boolean;
|
|
24
|
+
};
|
|
21
25
|
penMode: boolean;
|
|
22
26
|
penDetected: boolean;
|
|
23
27
|
exportBackground: boolean;
|
|
@@ -95,6 +99,10 @@ export declare const actionChangeProjectName: {
|
|
|
95
99
|
};
|
|
96
100
|
export declare const actionChangeExportScale: {
|
|
97
101
|
name: "changeExportScale";
|
|
102
|
+
trackEvent: {
|
|
103
|
+
category: "export";
|
|
104
|
+
action: string;
|
|
105
|
+
};
|
|
98
106
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
99
107
|
appState: {
|
|
100
108
|
exportScale: any;
|
|
@@ -109,8 +117,11 @@ export declare const actionChangeExportScale: {
|
|
|
109
117
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
110
118
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
111
119
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
112
|
-
|
|
113
|
-
|
|
120
|
+
activeTool: {
|
|
121
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
122
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
123
|
+
locked: boolean;
|
|
124
|
+
};
|
|
114
125
|
penMode: boolean;
|
|
115
126
|
penDetected: boolean;
|
|
116
127
|
exportBackground: boolean;
|
|
@@ -188,6 +199,10 @@ export declare const actionChangeExportScale: {
|
|
|
188
199
|
};
|
|
189
200
|
export declare const actionChangeExportBackground: {
|
|
190
201
|
name: "changeExportBackground";
|
|
202
|
+
trackEvent: {
|
|
203
|
+
category: "export";
|
|
204
|
+
action: string;
|
|
205
|
+
};
|
|
191
206
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
192
207
|
appState: {
|
|
193
208
|
exportBackground: any;
|
|
@@ -202,8 +217,11 @@ export declare const actionChangeExportBackground: {
|
|
|
202
217
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
203
218
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
204
219
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
205
|
-
|
|
206
|
-
|
|
220
|
+
activeTool: {
|
|
221
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
222
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
223
|
+
locked: boolean;
|
|
224
|
+
};
|
|
207
225
|
penMode: boolean;
|
|
208
226
|
penDetected: boolean;
|
|
209
227
|
exportEmbedScene: boolean;
|
|
@@ -281,6 +299,10 @@ export declare const actionChangeExportBackground: {
|
|
|
281
299
|
};
|
|
282
300
|
export declare const actionChangeExportEmbedScene: {
|
|
283
301
|
name: "changeExportEmbedScene";
|
|
302
|
+
trackEvent: {
|
|
303
|
+
category: "export";
|
|
304
|
+
action: string;
|
|
305
|
+
};
|
|
284
306
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
285
307
|
appState: {
|
|
286
308
|
exportEmbedScene: any;
|
|
@@ -295,8 +317,11 @@ export declare const actionChangeExportEmbedScene: {
|
|
|
295
317
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
296
318
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
297
319
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
298
|
-
|
|
299
|
-
|
|
320
|
+
activeTool: {
|
|
321
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
322
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
323
|
+
locked: boolean;
|
|
324
|
+
};
|
|
300
325
|
penMode: boolean;
|
|
301
326
|
penDetected: boolean;
|
|
302
327
|
exportBackground: boolean;
|
|
@@ -374,6 +399,9 @@ export declare const actionChangeExportEmbedScene: {
|
|
|
374
399
|
};
|
|
375
400
|
export declare const actionSaveToActiveFile: {
|
|
376
401
|
name: "saveToActiveFile";
|
|
402
|
+
trackEvent: {
|
|
403
|
+
category: "export";
|
|
404
|
+
};
|
|
377
405
|
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any, app: import("../types").AppClassProperties) => Promise<{
|
|
378
406
|
commitToHistory: false;
|
|
379
407
|
appState: {
|
|
@@ -390,8 +418,11 @@ export declare const actionSaveToActiveFile: {
|
|
|
390
418
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
391
419
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
392
420
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
393
|
-
|
|
394
|
-
|
|
421
|
+
activeTool: {
|
|
422
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
423
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
424
|
+
locked: boolean;
|
|
425
|
+
};
|
|
395
426
|
penMode: boolean;
|
|
396
427
|
penDetected: boolean;
|
|
397
428
|
exportBackground: boolean;
|
|
@@ -471,6 +502,9 @@ export declare const actionSaveToActiveFile: {
|
|
|
471
502
|
};
|
|
472
503
|
export declare const actionSaveFileToDisk: {
|
|
473
504
|
name: "saveFileToDisk";
|
|
505
|
+
trackEvent: {
|
|
506
|
+
category: "export";
|
|
507
|
+
};
|
|
474
508
|
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any, app: import("../types").AppClassProperties) => Promise<{
|
|
475
509
|
commitToHistory: false;
|
|
476
510
|
appState: {
|
|
@@ -486,8 +520,11 @@ export declare const actionSaveFileToDisk: {
|
|
|
486
520
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
487
521
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
488
522
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
489
|
-
|
|
490
|
-
|
|
523
|
+
activeTool: {
|
|
524
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
525
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
526
|
+
locked: boolean;
|
|
527
|
+
};
|
|
491
528
|
penMode: boolean;
|
|
492
529
|
penDetected: boolean;
|
|
493
530
|
exportBackground: boolean;
|
|
@@ -568,10 +605,17 @@ export declare const actionSaveFileToDisk: {
|
|
|
568
605
|
};
|
|
569
606
|
export declare const actionLoadScene: {
|
|
570
607
|
name: "loadScene";
|
|
608
|
+
trackEvent: {
|
|
609
|
+
category: "export";
|
|
610
|
+
};
|
|
571
611
|
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: any, app: import("../types").AppClassProperties) => Promise<false | {
|
|
572
612
|
elements: import("../element/types").ExcalidrawElement[];
|
|
573
613
|
appState: {
|
|
574
|
-
|
|
614
|
+
activeTool: {
|
|
615
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
616
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
617
|
+
locked: boolean;
|
|
618
|
+
};
|
|
575
619
|
scrollX: number;
|
|
576
620
|
scrollY: number;
|
|
577
621
|
viewBackgroundColor: string;
|
|
@@ -592,7 +636,6 @@ export declare const actionLoadScene: {
|
|
|
592
636
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
593
637
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
594
638
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
595
|
-
elementLocked: boolean;
|
|
596
639
|
penMode: boolean;
|
|
597
640
|
penDetected: boolean;
|
|
598
641
|
exportBackground: boolean;
|
|
@@ -666,8 +709,11 @@ export declare const actionLoadScene: {
|
|
|
666
709
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
667
710
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
668
711
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
669
|
-
|
|
670
|
-
|
|
712
|
+
activeTool: {
|
|
713
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
714
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
715
|
+
locked: boolean;
|
|
716
|
+
};
|
|
671
717
|
penMode: boolean;
|
|
672
718
|
penDetected: boolean;
|
|
673
719
|
exportBackground: boolean;
|
|
@@ -748,6 +794,10 @@ export declare const actionLoadScene: {
|
|
|
748
794
|
};
|
|
749
795
|
export declare const actionExportWithDarkMode: {
|
|
750
796
|
name: "exportWithDarkMode";
|
|
797
|
+
trackEvent: {
|
|
798
|
+
category: "export";
|
|
799
|
+
action: string;
|
|
800
|
+
};
|
|
751
801
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
752
802
|
appState: {
|
|
753
803
|
exportWithDarkMode: any;
|
|
@@ -762,8 +812,11 @@ export declare const actionExportWithDarkMode: {
|
|
|
762
812
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
763
813
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
764
814
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
765
|
-
|
|
766
|
-
|
|
815
|
+
activeTool: {
|
|
816
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
817
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
818
|
+
locked: boolean;
|
|
819
|
+
};
|
|
767
820
|
penMode: boolean;
|
|
768
821
|
penDetected: boolean;
|
|
769
822
|
exportBackground: boolean;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import { LinearElementEditor } from "../element/linearElementEditor";
|
|
3
3
|
export declare const actionFinalize: {
|
|
4
4
|
name: "finalize";
|
|
5
|
+
trackEvent: false;
|
|
5
6
|
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: any, { canvas, focusContainer }: import("../types").AppClassProperties) => {
|
|
6
7
|
elements: import("../element/types").ExcalidrawElement[] | undefined;
|
|
7
8
|
appState: {
|
|
@@ -16,8 +17,11 @@ export declare const actionFinalize: {
|
|
|
16
17
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
17
18
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
18
19
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
activeTool: {
|
|
21
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
22
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
23
|
+
locked: boolean;
|
|
24
|
+
};
|
|
21
25
|
penMode: boolean;
|
|
22
26
|
penDetected: boolean;
|
|
23
27
|
exportBackground: boolean;
|
|
@@ -92,7 +96,11 @@ export declare const actionFinalize: {
|
|
|
92
96
|
} | {
|
|
93
97
|
elements: readonly import("../element/types").ExcalidrawElement[];
|
|
94
98
|
appState: {
|
|
95
|
-
|
|
99
|
+
activeTool: {
|
|
100
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
101
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
102
|
+
locked: boolean;
|
|
103
|
+
};
|
|
96
104
|
draggingElement: null;
|
|
97
105
|
multiElement: null;
|
|
98
106
|
editingElement: null;
|
|
@@ -108,7 +116,6 @@ export declare const actionFinalize: {
|
|
|
108
116
|
selectionElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
109
117
|
isBindingEnabled: boolean;
|
|
110
118
|
editingLinearElement: LinearElementEditor | null;
|
|
111
|
-
elementLocked: boolean;
|
|
112
119
|
penMode: boolean;
|
|
113
120
|
penDetected: boolean;
|
|
114
121
|
exportBackground: boolean;
|
|
@@ -3,6 +3,9 @@ import { ExcalidrawElement } from "../element/types";
|
|
|
3
3
|
import { AppState } from "../types";
|
|
4
4
|
export declare const actionFlipHorizontal: {
|
|
5
5
|
name: "flipHorizontal";
|
|
6
|
+
trackEvent: {
|
|
7
|
+
category: "element";
|
|
8
|
+
};
|
|
6
9
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
7
10
|
elements: readonly ExcalidrawElement[];
|
|
8
11
|
appState: Readonly<AppState>;
|
|
@@ -16,6 +19,9 @@ export declare const actionFlipHorizontal: {
|
|
|
16
19
|
};
|
|
17
20
|
export declare const actionFlipVertical: {
|
|
18
21
|
name: "flipVertical";
|
|
22
|
+
trackEvent: {
|
|
23
|
+
category: "element";
|
|
24
|
+
};
|
|
19
25
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
20
26
|
elements: readonly ExcalidrawElement[];
|
|
21
27
|
appState: Readonly<AppState>;
|
|
@@ -3,6 +3,9 @@ import { ExcalidrawElement } from "../element/types";
|
|
|
3
3
|
import { AppState } from "../types";
|
|
4
4
|
export declare const actionGroup: {
|
|
5
5
|
name: "group";
|
|
6
|
+
trackEvent: {
|
|
7
|
+
category: "element";
|
|
8
|
+
};
|
|
6
9
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
7
10
|
appState: Readonly<AppState>;
|
|
8
11
|
elements: readonly ExcalidrawElement[];
|
|
@@ -21,6 +24,9 @@ export declare const actionGroup: {
|
|
|
21
24
|
};
|
|
22
25
|
export declare const actionUngroup: {
|
|
23
26
|
name: "ungroup";
|
|
27
|
+
trackEvent: {
|
|
28
|
+
category: "element";
|
|
29
|
+
};
|
|
24
30
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
25
31
|
appState: Readonly<AppState>;
|
|
26
32
|
elements: readonly ExcalidrawElement[];
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
export declare const actionToggleCanvasMenu: {
|
|
3
3
|
name: "toggleCanvasMenu";
|
|
4
|
+
trackEvent: {
|
|
5
|
+
category: "menu";
|
|
6
|
+
};
|
|
4
7
|
perform: (_: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>) => {
|
|
5
8
|
appState: {
|
|
6
9
|
openMenu: "canvas" | null;
|
|
@@ -15,8 +18,11 @@ export declare const actionToggleCanvasMenu: {
|
|
|
15
18
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
16
19
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
17
20
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
18
|
-
|
|
19
|
-
|
|
21
|
+
activeTool: {
|
|
22
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
23
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
24
|
+
locked: boolean;
|
|
25
|
+
};
|
|
20
26
|
penMode: boolean;
|
|
21
27
|
penDetected: boolean;
|
|
22
28
|
exportBackground: boolean;
|
|
@@ -94,6 +100,9 @@ export declare const actionToggleCanvasMenu: {
|
|
|
94
100
|
};
|
|
95
101
|
export declare const actionToggleEditMenu: {
|
|
96
102
|
name: "toggleEditMenu";
|
|
103
|
+
trackEvent: {
|
|
104
|
+
category: "menu";
|
|
105
|
+
};
|
|
97
106
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>) => {
|
|
98
107
|
appState: {
|
|
99
108
|
openMenu: "shape" | null;
|
|
@@ -108,8 +117,11 @@ export declare const actionToggleEditMenu: {
|
|
|
108
117
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
109
118
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
110
119
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
111
|
-
|
|
112
|
-
|
|
120
|
+
activeTool: {
|
|
121
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
122
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
123
|
+
locked: boolean;
|
|
124
|
+
};
|
|
113
125
|
penMode: boolean;
|
|
114
126
|
penDetected: boolean;
|
|
115
127
|
exportBackground: boolean;
|
|
@@ -187,6 +199,10 @@ export declare const actionToggleEditMenu: {
|
|
|
187
199
|
};
|
|
188
200
|
export declare const actionFullScreen: {
|
|
189
201
|
name: "toggleFullScreen";
|
|
202
|
+
trackEvent: {
|
|
203
|
+
category: "canvas";
|
|
204
|
+
predicate: (appState: Readonly<import("../types").AppState>) => boolean;
|
|
205
|
+
};
|
|
190
206
|
perform: () => {
|
|
191
207
|
commitToHistory: false;
|
|
192
208
|
};
|
|
@@ -196,6 +212,10 @@ export declare const actionFullScreen: {
|
|
|
196
212
|
};
|
|
197
213
|
export declare const actionShortcuts: {
|
|
198
214
|
name: "toggleShortcuts";
|
|
215
|
+
trackEvent: {
|
|
216
|
+
category: "menu";
|
|
217
|
+
action: string;
|
|
218
|
+
};
|
|
199
219
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: any, { focusContainer }: import("../types").AppClassProperties) => {
|
|
200
220
|
appState: {
|
|
201
221
|
showHelpDialog: boolean;
|
|
@@ -210,8 +230,11 @@ export declare const actionShortcuts: {
|
|
|
210
230
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
211
231
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
212
232
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
213
|
-
|
|
214
|
-
|
|
233
|
+
activeTool: {
|
|
234
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser";
|
|
235
|
+
lastActiveToolBeforeEraser: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | null;
|
|
236
|
+
locked: boolean;
|
|
237
|
+
};
|
|
215
238
|
penMode: boolean;
|
|
216
239
|
penDetected: boolean;
|
|
217
240
|
exportBackground: boolean;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
export declare const actionGoToCollaborator: {
|
|
3
3
|
name: "goToCollaborator";
|
|
4
|
+
trackEvent: {
|
|
5
|
+
category: "collab";
|
|
6
|
+
};
|
|
4
7
|
perform: (_elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any) => {
|
|
5
8
|
appState: Readonly<import("../types").AppState>;
|
|
6
9
|
commitToHistory: false;
|