@zsviczian/excalidraw 0.10.0-obsidian-39 → 0.10.0-obsidian-40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/excalidraw.development.js +72 -29
- package/dist/excalidraw.production.min.js +1 -1
- package/package.json +1 -1
- package/types/actions/actionAddToLibrary.d.ts +9 -15
- package/types/actions/actionCanvas.d.ts +45 -61
- package/types/actions/actionClipboard.d.ts +15 -25
- package/types/actions/actionDeleteSelected.d.ts +9 -15
- package/types/actions/actionExport.d.ts +27 -45
- package/types/actions/actionFinalize.d.ts +6 -10
- package/types/actions/actionMenu.d.ts +9 -15
- package/types/actions/actionProperties.d.ts +36 -60
- package/types/actions/actionStyles.d.ts +3 -5
- package/types/actions/actionToggleGridMode.d.ts +3 -5
- package/types/actions/actionToggleStats.d.ts +3 -5
- package/types/actions/actionToggleViewMode.d.ts +3 -5
- package/types/actions/actionToggleZenMode.d.ts +3 -5
- package/types/actions/actionUnbindText.d.ts +11 -0
- package/types/actions/index.d.ts +2 -0
- package/types/actions/shortcuts.d.ts +1 -1
- package/types/actions/types.d.ts +1 -1
- package/types/appState.d.ts +0 -5
- package/types/components/App.d.ts +9 -1
- package/types/components/LayerUI.d.ts +2 -2
- package/types/components/MobileMenu.d.ts +2 -2
- package/types/components/PenModeButton.d.ts +3 -3
- package/types/components/Tooltip.d.ts +7 -0
- package/types/components/icons.d.ts +1 -0
- package/types/constants.d.ts +1 -0
- package/types/element/Hyperlink.d.ts +116 -0
- package/types/element/collision.d.ts +1 -0
- package/types/element/linearElementEditor.d.ts +3 -6
- package/types/element/newElement.d.ts +1 -1
- package/types/element/textWysiwyg.d.ts +1 -3
- package/types/element/types.d.ts +1 -0
- package/types/keys.d.ts +1 -0
- package/types/renderer/renderElement.d.ts +1 -0
- package/types/scene/index.d.ts +1 -1
- package/types/scene/zoom.d.ts +12 -5
- package/types/types.d.ts +4 -5
|
@@ -34,7 +34,8 @@ export declare const actionChangeFillStyle: {
|
|
|
34
34
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
35
35
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
36
36
|
elementLocked: boolean;
|
|
37
|
-
|
|
37
|
+
penMode: boolean;
|
|
38
|
+
penDetected: boolean;
|
|
38
39
|
exportBackground: boolean;
|
|
39
40
|
exportEmbedScene: boolean;
|
|
40
41
|
exportWithDarkMode: boolean;
|
|
@@ -62,10 +63,6 @@ export declare const actionChangeFillStyle: {
|
|
|
62
63
|
isRotating: boolean;
|
|
63
64
|
zoom: Readonly<{
|
|
64
65
|
value: import("../../src/types").NormalizedZoomValue;
|
|
65
|
-
translation: Readonly<{
|
|
66
|
-
x: number;
|
|
67
|
-
y: number;
|
|
68
|
-
}>;
|
|
69
66
|
}>;
|
|
70
67
|
openMenu: "canvas" | "shape" | null;
|
|
71
68
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -104,6 +101,7 @@ export declare const actionChangeFillStyle: {
|
|
|
104
101
|
data: import("../charts").Spreadsheet;
|
|
105
102
|
};
|
|
106
103
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
104
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
107
105
|
};
|
|
108
106
|
commitToHistory: true;
|
|
109
107
|
};
|
|
@@ -130,7 +128,8 @@ export declare const actionChangeStrokeWidth: {
|
|
|
130
128
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
131
129
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
132
130
|
elementLocked: boolean;
|
|
133
|
-
|
|
131
|
+
penMode: boolean;
|
|
132
|
+
penDetected: boolean;
|
|
134
133
|
exportBackground: boolean;
|
|
135
134
|
exportEmbedScene: boolean;
|
|
136
135
|
exportWithDarkMode: boolean;
|
|
@@ -158,10 +157,6 @@ export declare const actionChangeStrokeWidth: {
|
|
|
158
157
|
isRotating: boolean;
|
|
159
158
|
zoom: Readonly<{
|
|
160
159
|
value: import("../../src/types").NormalizedZoomValue;
|
|
161
|
-
translation: Readonly<{
|
|
162
|
-
x: number;
|
|
163
|
-
y: number;
|
|
164
|
-
}>;
|
|
165
160
|
}>;
|
|
166
161
|
openMenu: "canvas" | "shape" | null;
|
|
167
162
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -200,6 +195,7 @@ export declare const actionChangeStrokeWidth: {
|
|
|
200
195
|
data: import("../charts").Spreadsheet;
|
|
201
196
|
};
|
|
202
197
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
198
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
203
199
|
};
|
|
204
200
|
commitToHistory: true;
|
|
205
201
|
};
|
|
@@ -226,7 +222,8 @@ export declare const actionChangeSloppiness: {
|
|
|
226
222
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
227
223
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
228
224
|
elementLocked: boolean;
|
|
229
|
-
|
|
225
|
+
penMode: boolean;
|
|
226
|
+
penDetected: boolean;
|
|
230
227
|
exportBackground: boolean;
|
|
231
228
|
exportEmbedScene: boolean;
|
|
232
229
|
exportWithDarkMode: boolean;
|
|
@@ -254,10 +251,6 @@ export declare const actionChangeSloppiness: {
|
|
|
254
251
|
isRotating: boolean;
|
|
255
252
|
zoom: Readonly<{
|
|
256
253
|
value: import("../../src/types").NormalizedZoomValue;
|
|
257
|
-
translation: Readonly<{
|
|
258
|
-
x: number;
|
|
259
|
-
y: number;
|
|
260
|
-
}>;
|
|
261
254
|
}>;
|
|
262
255
|
openMenu: "canvas" | "shape" | null;
|
|
263
256
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -296,6 +289,7 @@ export declare const actionChangeSloppiness: {
|
|
|
296
289
|
data: import("../charts").Spreadsheet;
|
|
297
290
|
};
|
|
298
291
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
292
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
299
293
|
};
|
|
300
294
|
commitToHistory: true;
|
|
301
295
|
};
|
|
@@ -322,7 +316,8 @@ export declare const actionChangeStrokeStyle: {
|
|
|
322
316
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
323
317
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
324
318
|
elementLocked: boolean;
|
|
325
|
-
|
|
319
|
+
penMode: boolean;
|
|
320
|
+
penDetected: boolean;
|
|
326
321
|
exportBackground: boolean;
|
|
327
322
|
exportEmbedScene: boolean;
|
|
328
323
|
exportWithDarkMode: boolean;
|
|
@@ -350,10 +345,6 @@ export declare const actionChangeStrokeStyle: {
|
|
|
350
345
|
isRotating: boolean;
|
|
351
346
|
zoom: Readonly<{
|
|
352
347
|
value: import("../../src/types").NormalizedZoomValue;
|
|
353
|
-
translation: Readonly<{
|
|
354
|
-
x: number;
|
|
355
|
-
y: number;
|
|
356
|
-
}>;
|
|
357
348
|
}>;
|
|
358
349
|
openMenu: "canvas" | "shape" | null;
|
|
359
350
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -392,6 +383,7 @@ export declare const actionChangeStrokeStyle: {
|
|
|
392
383
|
data: import("../charts").Spreadsheet;
|
|
393
384
|
};
|
|
394
385
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
386
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
395
387
|
};
|
|
396
388
|
commitToHistory: true;
|
|
397
389
|
};
|
|
@@ -418,7 +410,8 @@ export declare const actionChangeOpacity: {
|
|
|
418
410
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
419
411
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
420
412
|
elementLocked: boolean;
|
|
421
|
-
|
|
413
|
+
penMode: boolean;
|
|
414
|
+
penDetected: boolean;
|
|
422
415
|
exportBackground: boolean;
|
|
423
416
|
exportEmbedScene: boolean;
|
|
424
417
|
exportWithDarkMode: boolean;
|
|
@@ -446,10 +439,6 @@ export declare const actionChangeOpacity: {
|
|
|
446
439
|
isRotating: boolean;
|
|
447
440
|
zoom: Readonly<{
|
|
448
441
|
value: import("../../src/types").NormalizedZoomValue;
|
|
449
|
-
translation: Readonly<{
|
|
450
|
-
x: number;
|
|
451
|
-
y: number;
|
|
452
|
-
}>;
|
|
453
442
|
}>;
|
|
454
443
|
openMenu: "canvas" | "shape" | null;
|
|
455
444
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -488,6 +477,7 @@ export declare const actionChangeOpacity: {
|
|
|
488
477
|
data: import("../charts").Spreadsheet;
|
|
489
478
|
};
|
|
490
479
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
480
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
491
481
|
};
|
|
492
482
|
commitToHistory: true;
|
|
493
483
|
};
|
|
@@ -514,7 +504,8 @@ export declare const actionChangeFontSize: {
|
|
|
514
504
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
515
505
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
516
506
|
elementLocked: boolean;
|
|
517
|
-
|
|
507
|
+
penMode: boolean;
|
|
508
|
+
penDetected: boolean;
|
|
518
509
|
exportBackground: boolean;
|
|
519
510
|
exportEmbedScene: boolean;
|
|
520
511
|
exportWithDarkMode: boolean;
|
|
@@ -542,10 +533,6 @@ export declare const actionChangeFontSize: {
|
|
|
542
533
|
isRotating: boolean;
|
|
543
534
|
zoom: Readonly<{
|
|
544
535
|
value: import("../../src/types").NormalizedZoomValue;
|
|
545
|
-
translation: Readonly<{
|
|
546
|
-
x: number;
|
|
547
|
-
y: number;
|
|
548
|
-
}>;
|
|
549
536
|
}>;
|
|
550
537
|
openMenu: "canvas" | "shape" | null;
|
|
551
538
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -584,6 +571,7 @@ export declare const actionChangeFontSize: {
|
|
|
584
571
|
data: import("../charts").Spreadsheet;
|
|
585
572
|
};
|
|
586
573
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
574
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
587
575
|
};
|
|
588
576
|
commitToHistory: boolean;
|
|
589
577
|
};
|
|
@@ -610,7 +598,8 @@ export declare const actionDecreaseFontSize: {
|
|
|
610
598
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
611
599
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
612
600
|
elementLocked: boolean;
|
|
613
|
-
|
|
601
|
+
penMode: boolean;
|
|
602
|
+
penDetected: boolean;
|
|
614
603
|
exportBackground: boolean;
|
|
615
604
|
exportEmbedScene: boolean;
|
|
616
605
|
exportWithDarkMode: boolean;
|
|
@@ -638,10 +627,6 @@ export declare const actionDecreaseFontSize: {
|
|
|
638
627
|
isRotating: boolean;
|
|
639
628
|
zoom: Readonly<{
|
|
640
629
|
value: import("../../src/types").NormalizedZoomValue;
|
|
641
|
-
translation: Readonly<{
|
|
642
|
-
x: number;
|
|
643
|
-
y: number;
|
|
644
|
-
}>;
|
|
645
630
|
}>;
|
|
646
631
|
openMenu: "canvas" | "shape" | null;
|
|
647
632
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -680,6 +665,7 @@ export declare const actionDecreaseFontSize: {
|
|
|
680
665
|
data: import("../charts").Spreadsheet;
|
|
681
666
|
};
|
|
682
667
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
668
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
683
669
|
};
|
|
684
670
|
commitToHistory: boolean;
|
|
685
671
|
};
|
|
@@ -706,7 +692,8 @@ export declare const actionIncreaseFontSize: {
|
|
|
706
692
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
707
693
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
708
694
|
elementLocked: boolean;
|
|
709
|
-
|
|
695
|
+
penMode: boolean;
|
|
696
|
+
penDetected: boolean;
|
|
710
697
|
exportBackground: boolean;
|
|
711
698
|
exportEmbedScene: boolean;
|
|
712
699
|
exportWithDarkMode: boolean;
|
|
@@ -734,10 +721,6 @@ export declare const actionIncreaseFontSize: {
|
|
|
734
721
|
isRotating: boolean;
|
|
735
722
|
zoom: Readonly<{
|
|
736
723
|
value: import("../../src/types").NormalizedZoomValue;
|
|
737
|
-
translation: Readonly<{
|
|
738
|
-
x: number;
|
|
739
|
-
y: number;
|
|
740
|
-
}>;
|
|
741
724
|
}>;
|
|
742
725
|
openMenu: "canvas" | "shape" | null;
|
|
743
726
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -776,6 +759,7 @@ export declare const actionIncreaseFontSize: {
|
|
|
776
759
|
data: import("../charts").Spreadsheet;
|
|
777
760
|
};
|
|
778
761
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
762
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
779
763
|
};
|
|
780
764
|
commitToHistory: boolean;
|
|
781
765
|
};
|
|
@@ -802,7 +786,8 @@ export declare const actionChangeFontFamily: {
|
|
|
802
786
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
803
787
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
804
788
|
elementLocked: boolean;
|
|
805
|
-
|
|
789
|
+
penMode: boolean;
|
|
790
|
+
penDetected: boolean;
|
|
806
791
|
exportBackground: boolean;
|
|
807
792
|
exportEmbedScene: boolean;
|
|
808
793
|
exportWithDarkMode: boolean;
|
|
@@ -830,10 +815,6 @@ export declare const actionChangeFontFamily: {
|
|
|
830
815
|
isRotating: boolean;
|
|
831
816
|
zoom: Readonly<{
|
|
832
817
|
value: import("../../src/types").NormalizedZoomValue;
|
|
833
|
-
translation: Readonly<{
|
|
834
|
-
x: number;
|
|
835
|
-
y: number;
|
|
836
|
-
}>;
|
|
837
818
|
}>;
|
|
838
819
|
openMenu: "canvas" | "shape" | null;
|
|
839
820
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -872,6 +853,7 @@ export declare const actionChangeFontFamily: {
|
|
|
872
853
|
data: import("../charts").Spreadsheet;
|
|
873
854
|
};
|
|
874
855
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
856
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
875
857
|
};
|
|
876
858
|
commitToHistory: true;
|
|
877
859
|
};
|
|
@@ -898,7 +880,8 @@ export declare const actionChangeTextAlign: {
|
|
|
898
880
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
899
881
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
900
882
|
elementLocked: boolean;
|
|
901
|
-
|
|
883
|
+
penMode: boolean;
|
|
884
|
+
penDetected: boolean;
|
|
902
885
|
exportBackground: boolean;
|
|
903
886
|
exportEmbedScene: boolean;
|
|
904
887
|
exportWithDarkMode: boolean;
|
|
@@ -926,10 +909,6 @@ export declare const actionChangeTextAlign: {
|
|
|
926
909
|
isRotating: boolean;
|
|
927
910
|
zoom: Readonly<{
|
|
928
911
|
value: import("../../src/types").NormalizedZoomValue;
|
|
929
|
-
translation: Readonly<{
|
|
930
|
-
x: number;
|
|
931
|
-
y: number;
|
|
932
|
-
}>;
|
|
933
912
|
}>;
|
|
934
913
|
openMenu: "canvas" | "shape" | null;
|
|
935
914
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -968,6 +947,7 @@ export declare const actionChangeTextAlign: {
|
|
|
968
947
|
data: import("../charts").Spreadsheet;
|
|
969
948
|
};
|
|
970
949
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
950
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
971
951
|
};
|
|
972
952
|
commitToHistory: true;
|
|
973
953
|
};
|
|
@@ -995,7 +975,8 @@ export declare const actionChangeSharpness: {
|
|
|
995
975
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
996
976
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
997
977
|
elementLocked: boolean;
|
|
998
|
-
|
|
978
|
+
penMode: boolean;
|
|
979
|
+
penDetected: boolean;
|
|
999
980
|
exportBackground: boolean;
|
|
1000
981
|
exportEmbedScene: boolean;
|
|
1001
982
|
exportWithDarkMode: boolean;
|
|
@@ -1022,10 +1003,6 @@ export declare const actionChangeSharpness: {
|
|
|
1022
1003
|
isRotating: boolean;
|
|
1023
1004
|
zoom: Readonly<{
|
|
1024
1005
|
value: import("../../src/types").NormalizedZoomValue;
|
|
1025
|
-
translation: Readonly<{
|
|
1026
|
-
x: number;
|
|
1027
|
-
y: number;
|
|
1028
|
-
}>;
|
|
1029
1006
|
}>;
|
|
1030
1007
|
openMenu: "canvas" | "shape" | null;
|
|
1031
1008
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -1064,6 +1041,7 @@ export declare const actionChangeSharpness: {
|
|
|
1064
1041
|
data: import("../charts").Spreadsheet;
|
|
1065
1042
|
};
|
|
1066
1043
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
1044
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
1067
1045
|
};
|
|
1068
1046
|
commitToHistory: true;
|
|
1069
1047
|
};
|
|
@@ -1092,7 +1070,8 @@ export declare const actionChangeArrowhead: {
|
|
|
1092
1070
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1093
1071
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
1094
1072
|
elementLocked: boolean;
|
|
1095
|
-
|
|
1073
|
+
penMode: boolean;
|
|
1074
|
+
penDetected: boolean;
|
|
1096
1075
|
exportBackground: boolean;
|
|
1097
1076
|
exportEmbedScene: boolean;
|
|
1098
1077
|
exportWithDarkMode: boolean;
|
|
@@ -1121,10 +1100,6 @@ export declare const actionChangeArrowhead: {
|
|
|
1121
1100
|
isRotating: boolean;
|
|
1122
1101
|
zoom: Readonly<{
|
|
1123
1102
|
value: import("../../src/types").NormalizedZoomValue;
|
|
1124
|
-
translation: Readonly<{
|
|
1125
|
-
x: number;
|
|
1126
|
-
y: number;
|
|
1127
|
-
}>;
|
|
1128
1103
|
}>;
|
|
1129
1104
|
openMenu: "canvas" | "shape" | null;
|
|
1130
1105
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -1163,6 +1138,7 @@ export declare const actionChangeArrowhead: {
|
|
|
1163
1138
|
data: import("../charts").Spreadsheet;
|
|
1164
1139
|
};
|
|
1165
1140
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
1141
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
1166
1142
|
};
|
|
1167
1143
|
commitToHistory: true;
|
|
1168
1144
|
};
|
|
@@ -18,7 +18,8 @@ export declare const actionCopyStyles: {
|
|
|
18
18
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
19
19
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
20
20
|
elementLocked: boolean;
|
|
21
|
-
|
|
21
|
+
penMode: boolean;
|
|
22
|
+
penDetected: boolean;
|
|
22
23
|
exportBackground: boolean;
|
|
23
24
|
exportEmbedScene: boolean;
|
|
24
25
|
exportWithDarkMode: boolean;
|
|
@@ -47,10 +48,6 @@ export declare const actionCopyStyles: {
|
|
|
47
48
|
isRotating: boolean;
|
|
48
49
|
zoom: Readonly<{
|
|
49
50
|
value: import("../types").NormalizedZoomValue;
|
|
50
|
-
translation: Readonly<{
|
|
51
|
-
x: number;
|
|
52
|
-
y: number;
|
|
53
|
-
}>;
|
|
54
51
|
}>;
|
|
55
52
|
openMenu: "canvas" | "shape" | null;
|
|
56
53
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -88,6 +85,7 @@ export declare const actionCopyStyles: {
|
|
|
88
85
|
data: import("../charts").Spreadsheet;
|
|
89
86
|
};
|
|
90
87
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
88
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
91
89
|
};
|
|
92
90
|
commitToHistory: false;
|
|
93
91
|
};
|
|
@@ -18,7 +18,8 @@ export declare const actionToggleGridMode: {
|
|
|
18
18
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
19
19
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
20
20
|
elementLocked: boolean;
|
|
21
|
-
|
|
21
|
+
penMode: boolean;
|
|
22
|
+
penDetected: boolean;
|
|
22
23
|
exportBackground: boolean;
|
|
23
24
|
exportEmbedScene: boolean;
|
|
24
25
|
exportWithDarkMode: boolean;
|
|
@@ -47,10 +48,6 @@ export declare const actionToggleGridMode: {
|
|
|
47
48
|
isRotating: boolean;
|
|
48
49
|
zoom: Readonly<{
|
|
49
50
|
value: import("../types").NormalizedZoomValue;
|
|
50
|
-
translation: Readonly<{
|
|
51
|
-
x: number;
|
|
52
|
-
y: number;
|
|
53
|
-
}>;
|
|
54
51
|
}>;
|
|
55
52
|
openMenu: "canvas" | "shape" | null;
|
|
56
53
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -88,6 +85,7 @@ export declare const actionToggleGridMode: {
|
|
|
88
85
|
data: import("../charts").Spreadsheet;
|
|
89
86
|
};
|
|
90
87
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
88
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
91
89
|
};
|
|
92
90
|
commitToHistory: false;
|
|
93
91
|
};
|
|
@@ -17,7 +17,8 @@ export declare const actionToggleStats: {
|
|
|
17
17
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
18
18
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
19
19
|
elementLocked: boolean;
|
|
20
|
-
|
|
20
|
+
penMode: boolean;
|
|
21
|
+
penDetected: boolean;
|
|
21
22
|
exportBackground: boolean;
|
|
22
23
|
exportEmbedScene: boolean;
|
|
23
24
|
exportWithDarkMode: boolean;
|
|
@@ -46,10 +47,6 @@ export declare const actionToggleStats: {
|
|
|
46
47
|
isRotating: boolean;
|
|
47
48
|
zoom: Readonly<{
|
|
48
49
|
value: import("../types").NormalizedZoomValue;
|
|
49
|
-
translation: Readonly<{
|
|
50
|
-
x: number;
|
|
51
|
-
y: number;
|
|
52
|
-
}>;
|
|
53
50
|
}>;
|
|
54
51
|
openMenu: "canvas" | "shape" | null;
|
|
55
52
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -87,6 +84,7 @@ export declare const actionToggleStats: {
|
|
|
87
84
|
data: import("../charts").Spreadsheet;
|
|
88
85
|
};
|
|
89
86
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
87
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
90
88
|
};
|
|
91
89
|
commitToHistory: false;
|
|
92
90
|
};
|
|
@@ -17,7 +17,8 @@ export declare const actionToggleViewMode: {
|
|
|
17
17
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
18
18
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
19
19
|
elementLocked: boolean;
|
|
20
|
-
|
|
20
|
+
penMode: boolean;
|
|
21
|
+
penDetected: boolean;
|
|
21
22
|
exportBackground: boolean;
|
|
22
23
|
exportEmbedScene: boolean;
|
|
23
24
|
exportWithDarkMode: boolean;
|
|
@@ -46,10 +47,6 @@ export declare const actionToggleViewMode: {
|
|
|
46
47
|
isRotating: boolean;
|
|
47
48
|
zoom: Readonly<{
|
|
48
49
|
value: import("../types").NormalizedZoomValue;
|
|
49
|
-
translation: Readonly<{
|
|
50
|
-
x: number;
|
|
51
|
-
y: number;
|
|
52
|
-
}>;
|
|
53
50
|
}>;
|
|
54
51
|
openMenu: "canvas" | "shape" | null;
|
|
55
52
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -87,6 +84,7 @@ export declare const actionToggleViewMode: {
|
|
|
87
84
|
data: import("../charts").Spreadsheet;
|
|
88
85
|
};
|
|
89
86
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
87
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
90
88
|
};
|
|
91
89
|
commitToHistory: false;
|
|
92
90
|
};
|
|
@@ -17,7 +17,8 @@ export declare const actionToggleZenMode: {
|
|
|
17
17
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
18
18
|
elementType: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw";
|
|
19
19
|
elementLocked: boolean;
|
|
20
|
-
|
|
20
|
+
penMode: boolean;
|
|
21
|
+
penDetected: boolean;
|
|
21
22
|
exportBackground: boolean;
|
|
22
23
|
exportEmbedScene: boolean;
|
|
23
24
|
exportWithDarkMode: boolean;
|
|
@@ -46,10 +47,6 @@ export declare const actionToggleZenMode: {
|
|
|
46
47
|
isRotating: boolean;
|
|
47
48
|
zoom: Readonly<{
|
|
48
49
|
value: import("../types").NormalizedZoomValue;
|
|
49
|
-
translation: Readonly<{
|
|
50
|
-
x: number;
|
|
51
|
-
y: number;
|
|
52
|
-
}>;
|
|
53
50
|
}>;
|
|
54
51
|
openMenu: "canvas" | "shape" | null;
|
|
55
52
|
openPopup: "canvasColorPicker" | "backgroundColorPicker" | "strokeColorPicker" | null;
|
|
@@ -87,6 +84,7 @@ export declare const actionToggleZenMode: {
|
|
|
87
84
|
data: import("../charts").Spreadsheet;
|
|
88
85
|
};
|
|
89
86
|
pendingImageElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawImageElement> | null;
|
|
87
|
+
showHyperlinkPopup: false | "info" | "editor";
|
|
90
88
|
};
|
|
91
89
|
commitToHistory: false;
|
|
92
90
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const actionUnbindText: {
|
|
2
|
+
name: "unbindText";
|
|
3
|
+
contextItemLabel: string;
|
|
4
|
+
perform: (elements: readonly import("../element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>) => {
|
|
5
|
+
elements: readonly import("../element/types").ExcalidrawElement[];
|
|
6
|
+
appState: Readonly<import("../types").AppState>;
|
|
7
|
+
commitToHistory: true;
|
|
8
|
+
};
|
|
9
|
+
} & {
|
|
10
|
+
keyTest?: undefined;
|
|
11
|
+
};
|
package/types/actions/index.d.ts
CHANGED
|
@@ -18,3 +18,5 @@ export { actionCopy, actionCut, actionCopyAsPng, actionCopyAsSvg, } from "./acti
|
|
|
18
18
|
export { actionToggleGridMode } from "./actionToggleGridMode";
|
|
19
19
|
export { actionToggleZenMode } from "./actionToggleZenMode";
|
|
20
20
|
export { actionToggleStats } from "./actionToggleStats";
|
|
21
|
+
export { actionUnbindText } from "./actionUnbindText";
|
|
22
|
+
export { actionLink } from "../element/Hyperlink";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare type ShortcutName = "cut" | "copy" | "paste" | "copyStyles" | "pasteStyles" | "selectAll" | "deleteSelectedElements" | "duplicateSelection" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyAsPng" | "copyAsSvg" | "group" | "ungroup" | "gridMode" | "zenMode" | "stats" | "addToLibrary" | "viewMode" | "flipHorizontal" | "flipVertical";
|
|
1
|
+
export declare type ShortcutName = "cut" | "copy" | "paste" | "copyStyles" | "pasteStyles" | "selectAll" | "deleteSelectedElements" | "duplicateSelection" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyAsPng" | "copyAsSvg" | "group" | "ungroup" | "gridMode" | "zenMode" | "stats" | "addToLibrary" | "viewMode" | "flipHorizontal" | "flipVertical" | "link";
|
|
2
2
|
export declare const getShortcutFromShortcutName: (name: ShortcutName) => string;
|
package/types/actions/types.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ export declare type ActionResult = {
|
|
|
14
14
|
declare type ActionFn = (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>, formData: any, app: AppClassProperties) => ActionResult | Promise<ActionResult>;
|
|
15
15
|
export declare type UpdaterFn = (res: ActionResult) => void;
|
|
16
16
|
export declare type ActionFilterFn = (action: Action) => void;
|
|
17
|
-
export declare type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeOpacity" | "changeFontSize" | "toggleCanvasMenu" | "toggleEditMenu" | "undo" | "redo" | "finalize" | "changeProjectName" | "changeExportBackground" | "changeExportEmbedScene" | "changeExportScale" | "saveToActiveFile" | "saveFileToDisk" | "loadScene" | "duplicateSelection" | "deleteSelectedElements" | "changeViewBackgroundColor" | "clearCanvas" | "zoomIn" | "zoomOut" | "resetZoom" | "zoomToFit" | "zoomToSelection" | "changeFontFamily" | "changeTextAlign" | "toggleFullScreen" | "toggleShortcuts" | "group" | "ungroup" | "goToCollaborator" | "addToLibrary" | "changeSharpness" | "alignTop" | "alignBottom" | "alignLeft" | "alignRight" | "alignVerticallyCentered" | "alignHorizontallyCentered" | "distributeHorizontally" | "distributeVertically" | "flipHorizontal" | "flipVertical" | "viewMode" | "exportWithDarkMode" | "toggleTheme" | "increaseFontSize" | "decreaseFontSize";
|
|
17
|
+
export declare type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeOpacity" | "changeFontSize" | "toggleCanvasMenu" | "toggleEditMenu" | "undo" | "redo" | "finalize" | "changeProjectName" | "changeExportBackground" | "changeExportEmbedScene" | "changeExportScale" | "saveToActiveFile" | "saveFileToDisk" | "loadScene" | "duplicateSelection" | "deleteSelectedElements" | "changeViewBackgroundColor" | "clearCanvas" | "zoomIn" | "zoomOut" | "resetZoom" | "zoomToFit" | "zoomToSelection" | "changeFontFamily" | "changeTextAlign" | "toggleFullScreen" | "toggleShortcuts" | "group" | "ungroup" | "goToCollaborator" | "addToLibrary" | "changeSharpness" | "alignTop" | "alignBottom" | "alignLeft" | "alignRight" | "alignVerticallyCentered" | "alignHorizontallyCentered" | "distributeHorizontally" | "distributeVertically" | "flipHorizontal" | "flipVertical" | "viewMode" | "exportWithDarkMode" | "toggleTheme" | "increaseFontSize" | "decreaseFontSize" | "unbindText" | "link";
|
|
18
18
|
export declare type PanelComponentProps = {
|
|
19
19
|
elements: readonly ExcalidrawElement[];
|
|
20
20
|
appState: AppState;
|
package/types/appState.d.ts
CHANGED
|
@@ -6,17 +6,12 @@ export declare const clearAppStateForLocalStorage: (appState: Partial<AppState>)
|
|
|
6
6
|
viewBackgroundColor?: string | undefined;
|
|
7
7
|
zoom?: Readonly<{
|
|
8
8
|
value: NormalizedZoomValue;
|
|
9
|
-
translation: Readonly<{
|
|
10
|
-
x: number;
|
|
11
|
-
y: number;
|
|
12
|
-
}>;
|
|
13
9
|
}> | undefined;
|
|
14
10
|
shouldCacheIgnoreZoom?: boolean | undefined;
|
|
15
11
|
theme?: string | undefined;
|
|
16
12
|
name?: string | undefined;
|
|
17
13
|
elementType?: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | undefined;
|
|
18
14
|
elementLocked?: boolean | undefined;
|
|
19
|
-
penLocked?: boolean | undefined;
|
|
20
15
|
exportBackground?: boolean | undefined;
|
|
21
16
|
exportEmbedScene?: boolean | undefined;
|
|
22
17
|
exportWithDarkMode?: boolean | undefined;
|
|
@@ -29,6 +29,10 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
29
29
|
private excalidrawContainerValue;
|
|
30
30
|
files: BinaryFiles;
|
|
31
31
|
imageCache: AppClassProperties["imageCache"];
|
|
32
|
+
hitLinkElement?: NonDeletedExcalidrawElement;
|
|
33
|
+
lastPointerDown: React.PointerEvent<HTMLCanvasElement> | null;
|
|
34
|
+
lastPointerUp: React.PointerEvent<HTMLElement> | PointerEvent | null;
|
|
35
|
+
contextMenuOpen: boolean;
|
|
32
36
|
constructor(props: AppProps);
|
|
33
37
|
private renderCanvas;
|
|
34
38
|
render(): JSX.Element;
|
|
@@ -68,7 +72,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
68
72
|
setAppState: (obj: any) => void;
|
|
69
73
|
removePointer: (event: React.PointerEvent<HTMLElement> | PointerEvent) => void;
|
|
70
74
|
toggleLock: () => void;
|
|
71
|
-
|
|
75
|
+
togglePenMode: () => void;
|
|
72
76
|
toggleZenMode: () => void;
|
|
73
77
|
toggleStats: () => void;
|
|
74
78
|
scrollToContent: (target?: ExcalidrawElement | readonly ExcalidrawElement[]) => void;
|
|
@@ -107,6 +111,10 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
107
111
|
private getElementsAtPosition;
|
|
108
112
|
private startTextEditing;
|
|
109
113
|
private handleCanvasDoubleClick;
|
|
114
|
+
private getElementLinkAtPosition;
|
|
115
|
+
private redirectToLink;
|
|
116
|
+
private attachLinkListener;
|
|
117
|
+
private detachLinkListener;
|
|
110
118
|
private handleCanvasPointerMove;
|
|
111
119
|
private handleTouchMove;
|
|
112
120
|
private handleCanvasPointerDown;
|
|
@@ -15,7 +15,7 @@ interface LayerUIProps {
|
|
|
15
15
|
elements: readonly NonDeletedExcalidrawElement[];
|
|
16
16
|
onCollabButtonClick?: () => void;
|
|
17
17
|
onLockToggle: () => void;
|
|
18
|
-
|
|
18
|
+
onPenModeToggle: () => void;
|
|
19
19
|
onInsertElements: (elements: readonly NonDeletedExcalidrawElement[]) => void;
|
|
20
20
|
zenModeEnabled: boolean;
|
|
21
21
|
showExitZenModeBtn: boolean;
|
|
@@ -35,5 +35,5 @@ interface LayerUIProps {
|
|
|
35
35
|
insertOnCanvasDirectly: boolean;
|
|
36
36
|
}) => void;
|
|
37
37
|
}
|
|
38
|
-
declare const _default: React.MemoExoticComponent<({ actionManager, appState, files, setAppState, canvas, elements, onCollabButtonClick, onLockToggle,
|
|
38
|
+
declare const _default: React.MemoExoticComponent<({ actionManager, appState, files, setAppState, canvas, elements, onCollabButtonClick, onLockToggle, onPenModeToggle, onInsertElements, zenModeEnabled, showExitZenModeBtn, showThemeBtn, toggleZenMode, isCollaborating, renderTopRightUI, renderCustomFooter, viewModeEnabled, libraryReturnUrl, UIOptions, focusContainer, library, id, onImageAction, }: LayerUIProps) => JSX.Element>;
|
|
39
39
|
export default _default;
|
|
@@ -12,7 +12,7 @@ declare type MobileMenuProps = {
|
|
|
12
12
|
libraryMenu: JSX.Element | null;
|
|
13
13
|
onCollabButtonClick?: () => void;
|
|
14
14
|
onLockToggle: () => void;
|
|
15
|
-
|
|
15
|
+
onPenModeToggle: () => void;
|
|
16
16
|
canvas: HTMLCanvasElement | null;
|
|
17
17
|
isCollaborating: boolean;
|
|
18
18
|
renderCustomFooter?: (isMobile: boolean, appState: AppState) => JSX.Element;
|
|
@@ -23,5 +23,5 @@ declare type MobileMenuProps = {
|
|
|
23
23
|
}) => void;
|
|
24
24
|
renderTopRightUI?: (isMobile: boolean, appState: AppState) => JSX.Element | null;
|
|
25
25
|
};
|
|
26
|
-
export declare const MobileMenu: ({ appState, elements, libraryMenu, actionManager, renderJSONExportDialog, renderImageExportDialog, setAppState, onCollabButtonClick, onLockToggle,
|
|
26
|
+
export declare const MobileMenu: ({ appState, elements, libraryMenu, actionManager, renderJSONExportDialog, renderImageExportDialog, setAppState, onCollabButtonClick, onLockToggle, onPenModeToggle, canvas, isCollaborating, renderCustomFooter, viewModeEnabled, showThemeBtn, onImageAction, renderTopRightUI, }: MobileMenuProps) => JSX.Element;
|
|
27
27
|
export {};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import "./ToolIcon.scss";
|
|
3
|
-
declare type
|
|
3
|
+
declare type PenModeIconProps = {
|
|
4
4
|
title?: string;
|
|
5
5
|
name?: string;
|
|
6
6
|
checked: boolean;
|
|
7
7
|
onChange?(): void;
|
|
8
8
|
zenModeEnabled?: boolean;
|
|
9
9
|
isMobile?: boolean;
|
|
10
|
-
|
|
10
|
+
penDetected: boolean;
|
|
11
11
|
};
|
|
12
|
-
export declare const
|
|
12
|
+
export declare const PenModeButton: (props: PenModeIconProps) => JSX.Element | null;
|
|
13
13
|
export {};
|
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
import "./Tooltip.scss";
|
|
2
2
|
import React from "react";
|
|
3
|
+
export declare const getTooltipDiv: () => HTMLDivElement;
|
|
4
|
+
export declare const updateTooltipPosition: (tooltip: HTMLDivElement, item: {
|
|
5
|
+
left: number;
|
|
6
|
+
top: number;
|
|
7
|
+
width: number;
|
|
8
|
+
height: number;
|
|
9
|
+
}, position?: "bottom" | "top") => void;
|
|
3
10
|
declare type TooltipProps = {
|
|
4
11
|
children: React.ReactNode;
|
|
5
12
|
label: string;
|