@excalidraw/element 0.18.0-c158187 → 0.18.0-c1dbbdf

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 (121) hide show
  1. package/dist/dev/index.js +3420 -2566
  2. package/dist/dev/index.js.map +4 -4
  3. package/dist/prod/index.js +12 -12
  4. package/dist/types/common/debug.d.ts +21 -0
  5. package/dist/types/common/src/colors.d.ts +57 -40
  6. package/dist/types/common/src/constants.d.ts +4 -0
  7. package/dist/types/common/src/editorInterface.d.ts +1 -1
  8. package/dist/types/common/src/index.d.ts +1 -1
  9. package/dist/types/common/src/utils.d.ts +3 -5
  10. package/dist/types/element/src/Scene.d.ts +2 -0
  11. package/dist/types/element/src/arrows/focus.d.ts +27 -0
  12. package/dist/types/element/src/arrows/helpers.d.ts +5 -0
  13. package/dist/types/element/src/binding.d.ts +13 -8
  14. package/dist/types/element/src/collision.d.ts +4 -3
  15. package/dist/types/element/src/distribute.d.ts +2 -1
  16. package/dist/types/element/src/elbowArrow.d.ts +2 -0
  17. package/dist/types/element/src/index.d.ts +2 -0
  18. package/dist/types/element/src/linearElementEditor.d.ts +5 -0
  19. package/dist/types/element/src/mutateElement.d.ts +2 -0
  20. package/dist/types/element/src/types.d.ts +1 -1
  21. package/dist/types/element/src/utils.d.ts +5 -3
  22. package/dist/types/{common → element}/src/visualdebug.d.ts +20 -2
  23. package/dist/types/element/src/zindex.d.ts +1 -1
  24. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +30 -27
  25. package/dist/types/excalidraw/actions/actionBoundText.d.ts +20 -18
  26. package/dist/types/excalidraw/actions/actionCanvas.d.ts +121 -109
  27. package/dist/types/excalidraw/actions/actionClipboard.d.ts +20 -18
  28. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +10 -9
  29. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +32 -27
  30. package/dist/types/excalidraw/actions/actionElementLink.d.ts +6 -9
  31. package/dist/types/excalidraw/actions/actionElementLock.d.ts +20 -18
  32. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +10 -9
  33. package/dist/types/excalidraw/actions/actionExport.d.ts +42 -42
  34. package/dist/types/excalidraw/actions/actionFrame.d.ts +40 -36
  35. package/dist/types/excalidraw/actions/actionGroup.d.ts +20 -18
  36. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +12 -9
  37. package/dist/types/excalidraw/actions/actionLink.d.ts +10 -9
  38. package/dist/types/excalidraw/actions/actionMenu.d.ts +6 -9
  39. package/dist/types/excalidraw/actions/actionProperties.d.ts +20 -18
  40. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +10 -9
  41. package/dist/types/excalidraw/actions/actionStyles.d.ts +10 -9
  42. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +172 -0
  43. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +10 -9
  44. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +172 -0
  45. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +10 -9
  46. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +6 -9
  47. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +10 -9
  48. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +10 -9
  49. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +10 -9
  50. package/dist/types/excalidraw/actions/index.d.ts +2 -0
  51. package/dist/types/excalidraw/actions/shortcuts.d.ts +1 -1
  52. package/dist/types/excalidraw/actions/types.d.ts +1 -1
  53. package/dist/types/excalidraw/appState.d.ts +9 -7
  54. package/dist/types/excalidraw/charts/charts.bar.d.ts +2 -0
  55. package/dist/types/excalidraw/charts/charts.constants.d.ts +48 -0
  56. package/dist/types/excalidraw/charts/charts.helpers.d.ts +32 -0
  57. package/dist/types/excalidraw/charts/charts.line.d.ts +2 -0
  58. package/dist/types/excalidraw/charts/charts.parse.d.ts +10 -0
  59. package/dist/types/excalidraw/charts/charts.radar.d.ts +2 -0
  60. package/dist/types/excalidraw/charts/charts.types.d.ts +18 -0
  61. package/dist/types/excalidraw/charts/index.d.ts +7 -0
  62. package/dist/types/excalidraw/clipboard.d.ts +4 -4
  63. package/dist/types/excalidraw/components/App.d.ts +10 -3
  64. package/dist/types/excalidraw/components/Card.d.ts +1 -2
  65. package/dist/types/excalidraw/components/ColorPicker/ColorInput.d.ts +0 -5
  66. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +0 -1
  67. package/dist/types/excalidraw/components/CommandPalette/types.d.ts +1 -1
  68. package/dist/types/excalidraw/components/FilledButton.d.ts +1 -0
  69. package/dist/types/excalidraw/components/PasteChartDialog.d.ts +4 -5
  70. package/dist/types/excalidraw/components/PropertiesPopover.d.ts +1 -1
  71. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatHistoryMenu.d.ts +15 -0
  72. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatInterface.d.ts +23 -0
  73. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatMessage.d.ts +14 -0
  74. package/dist/types/excalidraw/components/TTDDialog/Chat/TTDChatPanel.d.ts +27 -0
  75. package/dist/types/excalidraw/components/TTDDialog/Chat/index.d.ts +3 -0
  76. package/dist/types/excalidraw/components/TTDDialog/Chat/useChatAgent.d.ts +8 -0
  77. package/dist/types/excalidraw/components/TTDDialog/CodeMirrorEditor.d.ts +11 -0
  78. package/dist/types/excalidraw/components/TTDDialog/MermaidToExcalidraw.d.ts +3 -2
  79. package/dist/types/excalidraw/components/TTDDialog/TTDContext.d.ts +13 -0
  80. package/dist/types/excalidraw/components/TTDDialog/TTDDialog.d.ts +12 -28
  81. package/dist/types/excalidraw/components/TTDDialog/TTDDialogInput.d.ts +3 -3
  82. package/dist/types/excalidraw/components/TTDDialog/TTDDialogOutput.d.ts +5 -1
  83. package/dist/types/excalidraw/components/TTDDialog/TTDDialogPanel.d.ts +13 -9
  84. package/dist/types/excalidraw/components/TTDDialog/TTDPreviewPanel.d.ts +9 -0
  85. package/dist/types/excalidraw/components/TTDDialog/TTDWelcomeMessage.d.ts +1 -0
  86. package/dist/types/excalidraw/components/TTDDialog/TextToDiagram.d.ts +9 -0
  87. package/dist/types/excalidraw/components/TTDDialog/common.d.ts +14 -13
  88. package/dist/types/excalidraw/components/TTDDialog/hooks/useChatManagement.d.ts +13 -0
  89. package/dist/types/excalidraw/components/TTDDialog/hooks/useMermaidRenderer.d.ts +14 -0
  90. package/dist/types/excalidraw/components/TTDDialog/hooks/useTextGeneration.d.ts +7 -0
  91. package/dist/types/excalidraw/components/TTDDialog/mermaid-lang-lite.d.ts +2 -0
  92. package/dist/types/excalidraw/components/TTDDialog/types.d.ts +95 -0
  93. package/dist/types/excalidraw/components/TTDDialog/useTTDChatStorage.d.ts +22 -0
  94. package/dist/types/excalidraw/components/TTDDialog/utils/TTDStreamFetch.d.ts +24 -0
  95. package/dist/types/excalidraw/components/TTDDialog/utils/chat.d.ts +10 -0
  96. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidAutoFix.d.ts +1 -0
  97. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidError.d.ts +10 -0
  98. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidValidation.d.ts +1 -0
  99. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenu.d.ts +30 -16
  100. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuContent.d.ts +3 -2
  101. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItem.d.ts +11 -12
  102. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCheckbox.d.ts +5 -0
  103. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContent.d.ts +2 -1
  104. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSub.d.ts +23 -0
  105. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubContent.d.ts +8 -0
  106. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubTrigger.d.ts +12 -0
  107. package/dist/types/excalidraw/components/dropdownMenu/common.d.ts +1 -1
  108. package/dist/types/excalidraw/components/dropdownMenu/dropdownMenuUtils.d.ts +2 -0
  109. package/dist/types/excalidraw/components/icons.d.ts +11 -2
  110. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +17 -0
  111. package/dist/types/excalidraw/components/main-menu/MainMenu.d.ts +23 -14
  112. package/dist/types/excalidraw/components/shapes.d.ts +74 -1
  113. package/dist/types/excalidraw/data/blob.d.ts +32 -30
  114. package/dist/types/excalidraw/data/json.d.ts +16 -15
  115. package/dist/types/excalidraw/errors.d.ts +14 -0
  116. package/dist/types/excalidraw/index.d.ts +4 -0
  117. package/dist/types/excalidraw/types.d.ts +24 -13
  118. package/dist/types/math/src/point.d.ts +6 -1
  119. package/dist/types/math/src/types.d.ts +25 -1
  120. package/package.json +9 -3
  121. package/dist/types/excalidraw/charts.d.ts +0 -27
@@ -33,8 +33,13 @@ export declare const actionGroup: {
33
33
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
34
34
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
35
35
  isBindingEnabled: boolean;
36
+ bindingPreference: "enabled" | "disabled";
37
+ isMidpointSnappingEnabled: boolean;
36
38
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
37
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
39
+ suggestedBinding: {
40
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
41
+ midPoint?: import("@excalidraw/math").GlobalPoint;
42
+ } | null;
38
43
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
39
44
  frameRendering: {
40
45
  enabled: boolean;
@@ -102,6 +107,10 @@ export declare const actionGroup: {
102
107
  } | {
103
108
  name: "elementLinkSelector";
104
109
  sourceElementId: ExcalidrawElement["id"];
110
+ } | {
111
+ name: "charts";
112
+ data: import("../charts").Spreadsheet;
113
+ rawText: string;
105
114
  };
106
115
  defaultSidebarDockedPreference: boolean;
107
116
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -134,14 +143,6 @@ export declare const actionGroup: {
134
143
  open: boolean;
135
144
  panels: number;
136
145
  };
137
- currentChartType: import("@excalidraw/element/types").ChartType;
138
- pasteDialog: {
139
- shown: false;
140
- data: null;
141
- } | {
142
- shown: true;
143
- data: import("../charts").Spreadsheet;
144
- };
145
146
  showHyperlinkPopup: false | "info" | "editor";
146
147
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
147
148
  snapLines: readonly import("../snapping").SnapLine[];
@@ -206,8 +207,13 @@ export declare const actionUngroup: {
206
207
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
207
208
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
208
209
  isBindingEnabled: boolean;
210
+ bindingPreference: "enabled" | "disabled";
211
+ isMidpointSnappingEnabled: boolean;
209
212
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
210
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
213
+ suggestedBinding: {
214
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
215
+ midPoint?: import("@excalidraw/math").GlobalPoint;
216
+ } | null;
211
217
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
212
218
  frameRendering: {
213
219
  enabled: boolean;
@@ -275,6 +281,10 @@ export declare const actionUngroup: {
275
281
  } | {
276
282
  name: "elementLinkSelector";
277
283
  sourceElementId: ExcalidrawElement["id"];
284
+ } | {
285
+ name: "charts";
286
+ data: import("../charts").Spreadsheet;
287
+ rawText: string;
278
288
  };
279
289
  defaultSidebarDockedPreference: boolean;
280
290
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -307,14 +317,6 @@ export declare const actionUngroup: {
307
317
  open: boolean;
308
318
  panels: number;
309
319
  };
310
- currentChartType: import("@excalidraw/element/types").ChartType;
311
- pasteDialog: {
312
- shown: false;
313
- data: null;
314
- } | {
315
- shown: true;
316
- data: import("../charts").Spreadsheet;
317
- };
318
320
  showHyperlinkPopup: false | "info" | "editor";
319
321
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
320
322
  snapLines: readonly import("../snapping").SnapLine[];
@@ -37,6 +37,8 @@ export declare const actionToggleLinearEditor: {
37
37
  }>;
38
38
  hoverPointIndex: number;
39
39
  segmentMidPointHoveredCoords: import("@excalidraw/math").GlobalPoint | null;
40
+ hoveredFocusPointBinding: "start" | "end" | null;
41
+ draggedFocusPointBinding: "start" | "end" | null;
40
42
  elbowed: boolean;
41
43
  customLineAngle: number | null;
42
44
  pointerDownState: never;
@@ -58,8 +60,13 @@ export declare const actionToggleLinearEditor: {
58
60
  multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
59
61
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
60
62
  isBindingEnabled: boolean;
63
+ bindingPreference: "enabled" | "disabled";
64
+ isMidpointSnappingEnabled: boolean;
61
65
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
62
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
66
+ suggestedBinding: {
67
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
68
+ midPoint?: import("@excalidraw/math").GlobalPoint;
69
+ } | null;
63
70
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
64
71
  frameRendering: {
65
72
  enabled: boolean;
@@ -127,6 +134,10 @@ export declare const actionToggleLinearEditor: {
127
134
  } | {
128
135
  name: "elementLinkSelector";
129
136
  sourceElementId: import("@excalidraw/element/types").ExcalidrawElement["id"];
137
+ } | {
138
+ name: "charts";
139
+ data: import("../charts").Spreadsheet;
140
+ rawText: string;
130
141
  };
131
142
  defaultSidebarDockedPreference: boolean;
132
143
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -166,14 +177,6 @@ export declare const actionToggleLinearEditor: {
166
177
  open: boolean;
167
178
  panels: number;
168
179
  };
169
- currentChartType: import("@excalidraw/element/types").ChartType;
170
- pasteDialog: {
171
- shown: false;
172
- data: null;
173
- } | {
174
- shown: true;
175
- data: import("../charts").Spreadsheet;
176
- };
177
180
  showHyperlinkPopup: false | "info" | "editor";
178
181
  snapLines: readonly import("../snapping").SnapLine[];
179
182
  originSnapOffset: {
@@ -24,8 +24,13 @@ export declare const actionLink: {
24
24
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
25
25
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
26
26
  isBindingEnabled: boolean;
27
+ bindingPreference: "enabled" | "disabled";
28
+ isMidpointSnappingEnabled: boolean;
27
29
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
28
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
30
+ suggestedBinding: {
31
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
32
+ midPoint?: import("@excalidraw/math").GlobalPoint;
33
+ } | null;
29
34
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
30
35
  frameRendering: {
31
36
  enabled: boolean;
@@ -92,6 +97,10 @@ export declare const actionLink: {
92
97
  } | {
93
98
  name: "elementLinkSelector";
94
99
  sourceElementId: import("@excalidraw/element/types").ExcalidrawElement["id"];
100
+ } | {
101
+ name: "charts";
102
+ data: import("../charts").Spreadsheet;
103
+ rawText: string;
95
104
  };
96
105
  defaultSidebarDockedPreference: boolean;
97
106
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -131,14 +140,6 @@ export declare const actionLink: {
131
140
  open: boolean;
132
141
  panels: number;
133
142
  };
134
- currentChartType: import("@excalidraw/element/types").ChartType;
135
- pasteDialog: {
136
- shown: false;
137
- data: null;
138
- } | {
139
- shown: true;
140
- data: import("../charts").Spreadsheet;
141
- };
142
143
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
143
144
  snapLines: readonly import("../snapping").SnapLine[];
144
145
  originSnapOffset: {
@@ -31,8 +31,13 @@ export declare const actionShortcuts: {
31
31
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
32
32
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
33
  isBindingEnabled: boolean;
34
+ bindingPreference: "enabled" | "disabled";
35
+ isMidpointSnappingEnabled: boolean;
34
36
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
35
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
37
+ suggestedBinding: {
38
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
39
+ midPoint?: import("@excalidraw/math").GlobalPoint;
40
+ } | null;
36
41
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
37
42
  frameRendering: {
38
43
  enabled: boolean;
@@ -124,14 +129,6 @@ export declare const actionShortcuts: {
124
129
  open: boolean;
125
130
  panels: number;
126
131
  };
127
- currentChartType: import("@excalidraw/element/types").ChartType;
128
- pasteDialog: {
129
- shown: false;
130
- data: null;
131
- } | {
132
- shown: true;
133
- data: import("../charts").Spreadsheet;
134
- };
135
132
  showHyperlinkPopup: false | "info" | "editor";
136
133
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
137
134
  snapLines: readonly import("../snapping").SnapLine[];
@@ -53,8 +53,13 @@ export declare const actionDecreaseFontSize: {
53
53
  multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
54
54
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
55
55
  isBindingEnabled: boolean;
56
+ bindingPreference: "enabled" | "disabled";
57
+ isMidpointSnappingEnabled: boolean;
56
58
  startBoundElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
57
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
59
+ suggestedBinding: {
60
+ element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
61
+ midPoint?: import("@excalidraw/math").GlobalPoint;
62
+ } | null;
58
63
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
59
64
  frameRendering: {
60
65
  enabled: boolean;
@@ -121,6 +126,10 @@ export declare const actionDecreaseFontSize: {
121
126
  } | {
122
127
  name: "elementLinkSelector";
123
128
  sourceElementId: ExcalidrawElement["id"];
129
+ } | {
130
+ name: "charts";
131
+ data: import("../charts").Spreadsheet;
132
+ rawText: string;
124
133
  };
125
134
  defaultSidebarDockedPreference: boolean;
126
135
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -160,14 +169,6 @@ export declare const actionDecreaseFontSize: {
160
169
  open: boolean;
161
170
  panels: number;
162
171
  };
163
- currentChartType: import("@excalidraw/element/types").ChartType;
164
- pasteDialog: {
165
- shown: false;
166
- data: null;
167
- } | {
168
- shown: true;
169
- data: import("../charts").Spreadsheet;
170
- };
171
172
  showHyperlinkPopup: false | "info" | "editor";
172
173
  selectedLinearElement: LinearElementEditor | null;
173
174
  snapLines: readonly import("../snapping").SnapLine[];
@@ -222,8 +223,13 @@ export declare const actionIncreaseFontSize: {
222
223
  multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
223
224
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
224
225
  isBindingEnabled: boolean;
226
+ bindingPreference: "enabled" | "disabled";
227
+ isMidpointSnappingEnabled: boolean;
225
228
  startBoundElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
226
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement> | null;
229
+ suggestedBinding: {
230
+ element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
231
+ midPoint?: import("@excalidraw/math").GlobalPoint;
232
+ } | null;
227
233
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
228
234
  frameRendering: {
229
235
  enabled: boolean;
@@ -290,6 +296,10 @@ export declare const actionIncreaseFontSize: {
290
296
  } | {
291
297
  name: "elementLinkSelector";
292
298
  sourceElementId: ExcalidrawElement["id"];
299
+ } | {
300
+ name: "charts";
301
+ data: import("../charts").Spreadsheet;
302
+ rawText: string;
293
303
  };
294
304
  defaultSidebarDockedPreference: boolean;
295
305
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -329,14 +339,6 @@ export declare const actionIncreaseFontSize: {
329
339
  open: boolean;
330
340
  panels: number;
331
341
  };
332
- currentChartType: import("@excalidraw/element/types").ChartType;
333
- pasteDialog: {
334
- shown: false;
335
- data: null;
336
- } | {
337
- shown: true;
338
- data: import("../charts").Spreadsheet;
339
- };
340
342
  showHyperlinkPopup: false | "info" | "editor";
341
343
  selectedLinearElement: LinearElementEditor | null;
342
344
  snapLines: readonly import("../snapping").SnapLine[];
@@ -31,8 +31,13 @@ export declare const actionSelectAll: {
31
31
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
32
32
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
33
  isBindingEnabled: boolean;
34
+ bindingPreference: "enabled" | "disabled";
35
+ isMidpointSnappingEnabled: boolean;
34
36
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
35
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
37
+ suggestedBinding: {
38
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
39
+ midPoint?: import("@excalidraw/math").GlobalPoint;
40
+ } | null;
36
41
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
37
42
  frameRendering: {
38
43
  enabled: boolean;
@@ -100,6 +105,10 @@ export declare const actionSelectAll: {
100
105
  } | {
101
106
  name: "elementLinkSelector";
102
107
  sourceElementId: ExcalidrawElement["id"];
108
+ } | {
109
+ name: "charts";
110
+ data: import("../charts").Spreadsheet;
111
+ rawText: string;
103
112
  };
104
113
  defaultSidebarDockedPreference: boolean;
105
114
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -132,14 +141,6 @@ export declare const actionSelectAll: {
132
141
  open: boolean;
133
142
  panels: number;
134
143
  };
135
- currentChartType: import("@excalidraw/element/types").ChartType;
136
- pasteDialog: {
137
- shown: false;
138
- data: null;
139
- } | {
140
- shown: true;
141
- data: import("../charts").Spreadsheet;
142
- };
143
144
  showHyperlinkPopup: false | "info" | "editor";
144
145
  snapLines: readonly import("../snapping").SnapLine[];
145
146
  originSnapOffset: {
@@ -28,8 +28,13 @@ export declare const actionCopyStyles: {
28
28
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
29
29
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
30
30
  isBindingEnabled: boolean;
31
+ bindingPreference: "enabled" | "disabled";
32
+ isMidpointSnappingEnabled: boolean;
31
33
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
32
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
34
+ suggestedBinding: {
35
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
36
+ midPoint?: import("@excalidraw/math").GlobalPoint;
37
+ } | null;
33
38
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
34
39
  frameRendering: {
35
40
  enabled: boolean;
@@ -97,6 +102,10 @@ export declare const actionCopyStyles: {
97
102
  } | {
98
103
  name: "elementLinkSelector";
99
104
  sourceElementId: import("@excalidraw/element/types").ExcalidrawElement["id"];
105
+ } | {
106
+ name: "charts";
107
+ data: import("../charts").Spreadsheet;
108
+ rawText: string;
100
109
  };
101
110
  defaultSidebarDockedPreference: boolean;
102
111
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -131,14 +140,6 @@ export declare const actionCopyStyles: {
131
140
  open: boolean;
132
141
  panels: number;
133
142
  };
134
- currentChartType: import("@excalidraw/element/types").ChartType;
135
- pasteDialog: {
136
- shown: false;
137
- data: null;
138
- } | {
139
- shown: true;
140
- data: import("../charts").Spreadsheet;
141
- };
142
143
  showHyperlinkPopup: false | "info" | "editor";
143
144
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
144
145
  snapLines: readonly import("../snapping").SnapLine[];
@@ -0,0 +1,172 @@
1
+ export declare const actionToggleArrowBinding: {
2
+ name: "arrowBinding";
3
+ label: string;
4
+ viewMode: false;
5
+ trackEvent: {
6
+ category: "canvas";
7
+ predicate: (appState: Readonly<import("../types").AppState>) => boolean;
8
+ };
9
+ perform(elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>): {
10
+ appState: {
11
+ bindingPreference: "enabled" | "disabled";
12
+ isBindingEnabled: boolean;
13
+ contextMenu: {
14
+ items: import("../components/ContextMenu").ContextMenuItems;
15
+ top: number;
16
+ left: number;
17
+ } | null;
18
+ showWelcomeScreen: boolean;
19
+ isLoading: boolean;
20
+ errorMessage: React.ReactNode;
21
+ activeEmbeddable: {
22
+ element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
23
+ state: "hover" | "active";
24
+ } | null;
25
+ newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
26
+ resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
27
+ multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
28
+ selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
29
+ isMidpointSnappingEnabled: boolean;
30
+ startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
31
+ suggestedBinding: {
32
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
33
+ midPoint?: import("@excalidraw/math").GlobalPoint;
34
+ } | null;
35
+ frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
36
+ frameRendering: {
37
+ enabled: boolean;
38
+ name: boolean;
39
+ outline: boolean;
40
+ clip: boolean;
41
+ };
42
+ editingFrame: string | null;
43
+ elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
44
+ editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
45
+ activeTool: {
46
+ lastActiveTool: import("../types").ActiveTool | null;
47
+ locked: boolean;
48
+ fromSelection: boolean;
49
+ } & import("../types").ActiveTool;
50
+ preferredSelectionTool: {
51
+ type: "selection" | "lasso";
52
+ initialized: boolean;
53
+ };
54
+ penMode: boolean;
55
+ penDetected: boolean;
56
+ exportBackground: boolean;
57
+ exportEmbedScene: boolean;
58
+ exportWithDarkMode: boolean;
59
+ exportScale: number;
60
+ currentItemStrokeColor: string;
61
+ currentItemBackgroundColor: string;
62
+ currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
63
+ currentItemStrokeWidth: number;
64
+ currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
65
+ currentItemRoughness: number;
66
+ currentItemOpacity: number;
67
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
68
+ currentItemFontSize: number;
69
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
70
+ currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
71
+ currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
72
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
73
+ currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
74
+ currentItemArrowType: "sharp" | "round" | "elbow";
75
+ viewBackgroundColor: string;
76
+ scrollX: number;
77
+ scrollY: number;
78
+ cursorButton: "up" | "down";
79
+ scrolledOutside: boolean;
80
+ name: string | null;
81
+ isResizing: boolean;
82
+ isRotating: boolean;
83
+ zoom: import("../types").Zoom;
84
+ openMenu: "canvas" | null;
85
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
86
+ openSidebar: {
87
+ name: import("../types").SidebarName;
88
+ tab?: import("../types").SidebarTabName;
89
+ } | null;
90
+ openDialog: null | {
91
+ name: "imageExport" | "help" | "jsonExport";
92
+ } | {
93
+ name: "ttd";
94
+ tab: "text-to-diagram" | "mermaid";
95
+ } | {
96
+ name: "commandPalette";
97
+ } | {
98
+ name: "settings";
99
+ } | {
100
+ name: "elementLinkSelector";
101
+ sourceElementId: import("@excalidraw/element/types").ExcalidrawElement["id"];
102
+ } | {
103
+ name: "charts";
104
+ data: import("../charts").Spreadsheet;
105
+ rawText: string;
106
+ };
107
+ defaultSidebarDockedPreference: boolean;
108
+ lastPointerDownWith: import("@excalidraw/element/types").PointerType;
109
+ selectedElementIds: Readonly<{
110
+ [id: string]: true;
111
+ }>;
112
+ hoveredElementIds: Readonly<{
113
+ [id: string]: true;
114
+ }>;
115
+ previousSelectedElementIds: {
116
+ [id: string]: true;
117
+ };
118
+ selectedElementsAreBeingDragged: boolean;
119
+ shouldCacheIgnoreZoom: boolean;
120
+ toast: {
121
+ message: string;
122
+ closable?: boolean;
123
+ duration?: number;
124
+ } | null;
125
+ zenModeEnabled: boolean;
126
+ theme: import("@excalidraw/element/types").Theme;
127
+ gridSize: number;
128
+ gridStep: number;
129
+ gridModeEnabled: boolean;
130
+ viewModeEnabled: boolean;
131
+ selectedGroupIds: {
132
+ [groupId: string]: boolean;
133
+ };
134
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
135
+ width: number;
136
+ height: number;
137
+ offsetTop: number;
138
+ offsetLeft: number;
139
+ fileHandle: import("browser-fs-access").FileSystemHandle | null;
140
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
141
+ stats: {
142
+ open: boolean;
143
+ panels: number;
144
+ };
145
+ showHyperlinkPopup: false | "info" | "editor";
146
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
147
+ snapLines: readonly import("../snapping").SnapLine[];
148
+ originSnapOffset: {
149
+ x: number;
150
+ y: number;
151
+ } | null;
152
+ objectsSnapModeEnabled: boolean;
153
+ userToFollow: import("../types").UserToFollow | null;
154
+ followedBy: Set<import("../types").SocketId>;
155
+ isCropping: boolean;
156
+ croppingElementId: import("@excalidraw/element/types").ExcalidrawElement["id"] | null;
157
+ searchMatches: Readonly<{
158
+ focusedId: import("@excalidraw/element/types").ExcalidrawElement["id"] | null;
159
+ matches: readonly import("../types").SearchMatch[];
160
+ }> | null;
161
+ activeLockedId: string | null;
162
+ lockedMultiSelections: {
163
+ [groupId: string]: true;
164
+ };
165
+ bindMode: import("@excalidraw/element/types").BindMode;
166
+ };
167
+ captureUpdate: "NEVER";
168
+ };
169
+ checked: (appState: Readonly<import("../types").AppState>) => boolean;
170
+ } & {
171
+ keyTest?: undefined;
172
+ };
@@ -30,8 +30,13 @@ export declare const actionToggleGridMode: {
30
30
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
31
31
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
32
32
  isBindingEnabled: boolean;
33
+ bindingPreference: "enabled" | "disabled";
34
+ isMidpointSnappingEnabled: boolean;
33
35
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
34
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
36
+ suggestedBinding: {
37
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
38
+ midPoint?: import("@excalidraw/math").GlobalPoint;
39
+ } | null;
35
40
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
36
41
  frameRendering: {
37
42
  enabled: boolean;
@@ -99,6 +104,10 @@ export declare const actionToggleGridMode: {
99
104
  } | {
100
105
  name: "elementLinkSelector";
101
106
  sourceElementId: import("@excalidraw/element/types").ExcalidrawElement["id"];
107
+ } | {
108
+ name: "charts";
109
+ data: import("../charts").Spreadsheet;
110
+ rawText: string;
102
111
  };
103
112
  defaultSidebarDockedPreference: boolean;
104
113
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -137,14 +146,6 @@ export declare const actionToggleGridMode: {
137
146
  open: boolean;
138
147
  panels: number;
139
148
  };
140
- currentChartType: import("@excalidraw/element/types").ChartType;
141
- pasteDialog: {
142
- shown: false;
143
- data: null;
144
- } | {
145
- shown: true;
146
- data: import("../charts").Spreadsheet;
147
- };
148
149
  showHyperlinkPopup: false | "info" | "editor";
149
150
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
150
151
  snapLines: readonly import("../snapping").SnapLine[];