@excalidraw/excalidraw 0.18.0-195a743 → 0.18.0-298812e

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 (139) hide show
  1. package/dist/dev/{chunk-T3M44BFV.js → chunk-JCUIYZXF.js} +7 -3
  2. package/dist/dev/chunk-JCUIYZXF.js.map +7 -0
  3. package/dist/dev/{chunk-WMGEUIQQ.js → chunk-RQWTCZLD.js} +2 -2
  4. package/dist/dev/{chunk-H3EW23X2.js → chunk-ZPGIVNNG.js} +14840 -9652
  5. package/dist/dev/chunk-ZPGIVNNG.js.map +7 -0
  6. package/dist/dev/data/{image-TTQKTTOH.js → image-CB4ZYE3A.js} +3 -3
  7. package/dist/dev/index.css +38 -2
  8. package/dist/dev/index.css.map +2 -2
  9. package/dist/dev/index.js +857 -5250
  10. package/dist/dev/index.js.map +4 -4
  11. package/dist/dev/locales/{en-I23TB6DJ.js → en-ZDTPSZNL.js} +2 -2
  12. package/dist/dev/subset-shared.chunk.js +1 -1
  13. package/dist/dev/subset-worker.chunk.js +1 -1
  14. package/dist/prod/{chunk-GK4XUKZB.js → chunk-7TMLMBQX.js} +1 -1
  15. package/dist/prod/{chunk-2Z7RPVPO.js → chunk-GCFVWREF.js} +3 -3
  16. package/dist/prod/chunk-WFJFO6F4.js +33 -0
  17. package/dist/prod/data/image-XJI4SWH2.js +1 -0
  18. package/dist/prod/index.css +1 -1
  19. package/dist/prod/index.js +18 -18
  20. package/dist/prod/locales/{en-TC3OFDA6.js → en-MHZ26NAR.js} +1 -1
  21. package/dist/prod/subset-shared.chunk.js +1 -1
  22. package/dist/prod/subset-worker.chunk.js +1 -1
  23. package/dist/types/common/src/constants.d.ts +1 -0
  24. package/dist/types/{excalidraw → common/src}/emitter.d.ts +1 -1
  25. package/dist/types/common/src/font-metadata.d.ts +4 -2
  26. package/dist/types/common/src/index.d.ts +1 -0
  27. package/dist/types/common/src/utility-types.d.ts +5 -0
  28. package/dist/types/common/src/utils.d.ts +16 -4
  29. package/dist/types/element/src/Scene.d.ts +4 -4
  30. package/dist/types/element/src/ShapeCache.d.ts +1 -1
  31. package/dist/types/element/src/align.d.ts +1 -1
  32. package/dist/types/element/src/binding.d.ts +1 -1
  33. package/dist/types/element/src/bounds.d.ts +1 -1
  34. package/dist/types/{excalidraw/change.d.ts → element/src/delta.d.ts} +40 -35
  35. package/dist/types/element/src/dragElements.d.ts +1 -1
  36. package/dist/types/element/src/flowchart.d.ts +1 -1
  37. package/dist/types/element/src/frame.d.ts +3 -2
  38. package/dist/types/element/src/index.d.ts +45 -2
  39. package/dist/types/element/src/linearElementEditor.d.ts +4 -8
  40. package/dist/types/element/src/newElement.d.ts +1 -1
  41. package/dist/types/element/src/resizeElements.d.ts +1 -1
  42. package/dist/types/element/src/selection.d.ts +1 -6
  43. package/dist/types/element/src/store.d.ts +227 -0
  44. package/dist/types/element/src/textElement.d.ts +1 -1
  45. package/dist/types/element/src/transformHandles.d.ts +4 -4
  46. package/dist/types/element/src/typeChecks.d.ts +2 -1
  47. package/dist/types/element/src/types.d.ts +6 -1
  48. package/dist/types/element/src/zindex.d.ts +3 -3
  49. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +24 -42
  50. package/dist/types/excalidraw/actions/actionAlign.d.ts +8 -8
  51. package/dist/types/excalidraw/actions/actionBoundText.d.ts +16 -28
  52. package/dist/types/excalidraw/actions/actionCanvas.d.ts +194 -272
  53. package/dist/types/excalidraw/actions/actionClipboard.d.ts +50 -86
  54. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +8 -14
  55. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +22 -40
  56. package/dist/types/excalidraw/actions/actionDistribute.d.ts +4 -4
  57. package/dist/types/excalidraw/actions/actionDuplicateSelection.d.ts +2 -2
  58. package/dist/types/excalidraw/actions/actionElementLink.d.ts +8 -14
  59. package/dist/types/excalidraw/actions/actionElementLock.d.ts +18 -30
  60. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +8 -14
  61. package/dist/types/excalidraw/actions/actionExport.d.ts +159 -213
  62. package/dist/types/excalidraw/actions/actionFinalize.d.ts +14 -26
  63. package/dist/types/excalidraw/actions/actionFlip.d.ts +4 -4
  64. package/dist/types/excalidraw/actions/actionFrame.d.ts +76 -100
  65. package/dist/types/excalidraw/actions/actionGroup.d.ts +22 -34
  66. package/dist/types/excalidraw/actions/actionHistory.d.ts +1 -2
  67. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +7 -13
  68. package/dist/types/excalidraw/actions/actionLink.d.ts +9 -15
  69. package/dist/types/excalidraw/actions/actionMenu.d.ts +26 -44
  70. package/dist/types/excalidraw/actions/actionNavigate.d.ts +16 -28
  71. package/dist/types/excalidraw/actions/actionProperties.d.ts +106 -196
  72. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +10 -16
  73. package/dist/types/excalidraw/actions/actionStyles.d.ts +12 -18
  74. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +10 -16
  75. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +10 -16
  76. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +10 -189
  77. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +10 -16
  78. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +10 -16
  79. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +10 -16
  80. package/dist/types/excalidraw/actions/actionZindex.d.ts +10 -10
  81. package/dist/types/excalidraw/actions/types.d.ts +1 -1
  82. package/dist/types/excalidraw/appState.d.ts +23 -23
  83. package/dist/types/excalidraw/components/App.d.ts +9 -9
  84. package/dist/types/excalidraw/components/ColorPicker/ColorInput.d.ts +2 -1
  85. package/dist/types/excalidraw/components/ColorPicker/ColorPicker.d.ts +5 -1
  86. package/dist/types/excalidraw/components/ColorPicker/CustomColorList.d.ts +1 -1
  87. package/dist/types/excalidraw/components/ColorPicker/Picker.d.ts +2 -3
  88. package/dist/types/excalidraw/components/ColorPicker/PickerColorList.d.ts +2 -3
  89. package/dist/types/excalidraw/components/ColorPicker/ShadeList.d.ts +2 -2
  90. package/dist/types/excalidraw/components/ColorPicker/TopPicks.d.ts +1 -1
  91. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +1 -1
  92. package/dist/types/excalidraw/components/ColorPicker/keyboardNavHandlers.d.ts +1 -1
  93. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +2 -28
  94. package/dist/types/excalidraw/components/ElementLinkDialog.d.ts +1 -1
  95. package/dist/types/excalidraw/components/Range.d.ts +3 -3
  96. package/dist/types/excalidraw/components/Stats/Angle.d.ts +1 -1
  97. package/dist/types/excalidraw/components/Stats/CanvasGrid.d.ts +1 -1
  98. package/dist/types/excalidraw/components/Stats/Collapsible.d.ts +2 -1
  99. package/dist/types/excalidraw/components/Stats/Dimension.d.ts +1 -1
  100. package/dist/types/excalidraw/components/Stats/DragInput.d.ts +1 -1
  101. package/dist/types/excalidraw/components/Stats/FontSize.d.ts +1 -1
  102. package/dist/types/excalidraw/components/Stats/MultiAngle.d.ts +1 -1
  103. package/dist/types/excalidraw/components/Stats/MultiDimension.d.ts +1 -1
  104. package/dist/types/excalidraw/components/Stats/MultiFontSize.d.ts +1 -1
  105. package/dist/types/excalidraw/components/Stats/MultiPosition.d.ts +1 -1
  106. package/dist/types/excalidraw/components/Stats/Position.d.ts +1 -1
  107. package/dist/types/excalidraw/components/Stats/utils.d.ts +2 -1
  108. package/dist/types/excalidraw/components/hyperlink/Hyperlink.d.ts +1 -1
  109. package/dist/types/excalidraw/components/hyperlink/helpers.d.ts +1 -1
  110. package/dist/types/excalidraw/components/icons.d.ts +1 -0
  111. package/dist/types/excalidraw/components/shapes.d.ts +1 -1
  112. package/dist/types/excalidraw/data/blob.d.ts +1 -1
  113. package/dist/types/excalidraw/data/transform.d.ts +1 -1
  114. package/dist/types/excalidraw/fonts/Fonts.d.ts +1 -1
  115. package/dist/types/excalidraw/history.d.ts +14 -22
  116. package/dist/types/excalidraw/hooks/useEmitter.d.ts +1 -1
  117. package/dist/types/excalidraw/index.d.ts +9 -9
  118. package/dist/types/excalidraw/lasso/index.d.ts +1 -0
  119. package/dist/types/excalidraw/renderer/helpers.d.ts +6 -1
  120. package/dist/types/excalidraw/scene/Renderer.d.ts +1 -1
  121. package/dist/types/excalidraw/scene/index.d.ts +2 -2
  122. package/dist/types/excalidraw/snapping.d.ts +2 -2
  123. package/dist/types/excalidraw/types.d.ts +13 -6
  124. package/dist/types/excalidraw/visualdebug.d.ts +1 -1
  125. package/dist/types/math/src/curve.d.ts +2 -0
  126. package/dist/types/math/src/vector.d.ts +4 -0
  127. package/dist/types/utils/src/bbox.d.ts +1 -1
  128. package/dist/types/utils/src/index.d.ts +1 -1
  129. package/dist/types/utils/src/withinBounds.d.ts +1 -1
  130. package/history.ts +68 -94
  131. package/package.json +3 -3
  132. package/dist/dev/chunk-H3EW23X2.js.map +0 -7
  133. package/dist/dev/chunk-T3M44BFV.js.map +0 -7
  134. package/dist/prod/chunk-7M43VNIB.js +0 -33
  135. package/dist/prod/data/image-7YYIWLVQ.js +0 -1
  136. package/dist/types/excalidraw/store.d.ts +0 -129
  137. /package/dist/dev/{chunk-WMGEUIQQ.js.map → chunk-RQWTCZLD.js.map} +0 -0
  138. /package/dist/dev/data/{image-TTQKTTOH.js.map → image-CB4ZYE3A.js.map} +0 -0
  139. /package/dist/dev/locales/{en-I23TB6DJ.js.map → en-ZDTPSZNL.js.map} +0 -0
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { LinearElementEditor } from "@excalidraw/element/linearElementEditor";
2
+ import { LinearElementEditor } from "@excalidraw/element";
3
3
  import type { ExcalidrawElement } from "@excalidraw/element/types";
4
4
  export declare const actionSelectAll: {
5
5
  name: "selectAll";
@@ -12,13 +12,13 @@ export declare const actionSelectAll: {
12
12
  perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>, value: any, app: import("../types").AppClassProperties) => false | {
13
13
  appState: {
14
14
  selectedLinearElement: LinearElementEditor | null;
15
- editingGroupId: string | null;
16
15
  selectedElementIds: Readonly<{
17
16
  [id: string]: true;
18
17
  }>;
19
18
  selectedGroupIds: {
20
19
  [groupId: string]: boolean;
21
20
  };
21
+ editingGroupId: string | null;
22
22
  contextMenu: {
23
23
  items: import("../components/ContextMenu").ContextMenuItems;
24
24
  top: number;
@@ -37,7 +37,7 @@ export declare const actionSelectAll: {
37
37
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
38
38
  isBindingEnabled: boolean;
39
39
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
40
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
40
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
41
41
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
42
42
  frameRendering: {
43
43
  enabled: boolean;
@@ -162,7 +162,7 @@ export declare const actionSelectAll: {
162
162
  data: import("../charts").Spreadsheet;
163
163
  };
164
164
  pendingImageElementId: string | null;
165
- showHyperlinkPopup: false | "editor" | "info";
165
+ showHyperlinkPopup: false | "info" | "editor";
166
166
  snapLines: readonly import("../snapping").SnapLine[];
167
167
  originSnapOffset: {
168
168
  x: number;
@@ -173,20 +173,14 @@ export declare const actionSelectAll: {
173
173
  followedBy: Set<import("../types").SocketId>;
174
174
  isCropping: boolean;
175
175
  croppingElementId: string | null;
176
- searchMatches: readonly {
177
- id: string;
178
- focus: boolean;
179
- matchedLines: {
180
- offsetX: number;
181
- offsetY: number;
182
- width: number;
183
- height: number;
184
- }[];
185
- }[];
176
+ searchMatches: Readonly<{
177
+ focusedId: string | null;
178
+ matches: readonly import("../types").SearchMatch[];
179
+ }> | null;
186
180
  };
187
181
  captureUpdate: "IMMEDIATELY";
188
182
  };
189
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
183
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
190
184
  } & {
191
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
185
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
192
186
  };
@@ -30,7 +30,7 @@ export declare const actionCopyStyles: {
30
30
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
31
31
  isBindingEnabled: boolean;
32
32
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
33
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
33
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
34
34
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
35
35
  frameRendering: {
36
36
  enabled: boolean;
@@ -41,7 +41,7 @@ export declare const actionCopyStyles: {
41
41
  editingFrame: string | null;
42
42
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
43
43
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
44
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
44
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
45
45
  activeTool: {
46
46
  lastActiveTool: import("../types").ActiveTool | null;
47
47
  locked: boolean;
@@ -157,8 +157,8 @@ export declare const actionCopyStyles: {
157
157
  data: import("../charts").Spreadsheet;
158
158
  };
159
159
  pendingImageElementId: string | null;
160
- showHyperlinkPopup: false | "editor" | "info";
161
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
160
+ showHyperlinkPopup: false | "info" | "editor";
161
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
162
162
  snapLines: readonly import("../snapping").SnapLine[];
163
163
  originSnapOffset: {
164
164
  x: number;
@@ -169,22 +169,16 @@ export declare const actionCopyStyles: {
169
169
  followedBy: Set<import("../types").SocketId>;
170
170
  isCropping: boolean;
171
171
  croppingElementId: string | null;
172
- searchMatches: readonly {
173
- id: string;
174
- focus: boolean;
175
- matchedLines: {
176
- offsetX: number;
177
- offsetY: number;
178
- width: number;
179
- height: number;
180
- }[];
181
- }[];
172
+ searchMatches: Readonly<{
173
+ focusedId: string | null;
174
+ matches: readonly import("../types").SearchMatch[];
175
+ }> | null;
182
176
  };
183
177
  captureUpdate: "EVENTUALLY";
184
178
  };
185
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
179
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
186
180
  } & {
187
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
181
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
188
182
  };
189
183
  export declare const actionPasteStyles: {
190
184
  name: "pasteStyles";
@@ -200,7 +194,7 @@ export declare const actionPasteStyles: {
200
194
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
201
195
  captureUpdate: "IMMEDIATELY";
202
196
  };
203
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
197
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
204
198
  } & {
205
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
199
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
206
200
  };
@@ -32,7 +32,7 @@ export declare const actionToggleGridMode: {
32
32
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
33
  isBindingEnabled: boolean;
34
34
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
35
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
35
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
36
36
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
37
37
  frameRendering: {
38
38
  enabled: boolean;
@@ -43,7 +43,7 @@ export declare const actionToggleGridMode: {
43
43
  editingFrame: string | null;
44
44
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
45
45
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
46
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
46
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
47
47
  activeTool: {
48
48
  lastActiveTool: import("../types").ActiveTool | null;
49
49
  locked: boolean;
@@ -163,8 +163,8 @@ export declare const actionToggleGridMode: {
163
163
  data: import("../charts").Spreadsheet;
164
164
  };
165
165
  pendingImageElementId: string | null;
166
- showHyperlinkPopup: false | "editor" | "info";
167
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
166
+ showHyperlinkPopup: false | "info" | "editor";
167
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
168
168
  snapLines: readonly import("../snapping").SnapLine[];
169
169
  originSnapOffset: {
170
170
  x: number;
@@ -174,22 +174,16 @@ export declare const actionToggleGridMode: {
174
174
  followedBy: Set<import("../types").SocketId>;
175
175
  isCropping: boolean;
176
176
  croppingElementId: string | null;
177
- searchMatches: readonly {
178
- id: string;
179
- focus: boolean;
180
- matchedLines: {
181
- offsetX: number;
182
- offsetY: number;
183
- width: number;
184
- height: number;
185
- }[];
186
- }[];
177
+ searchMatches: Readonly<{
178
+ focusedId: string | null;
179
+ matches: readonly import("../types").SearchMatch[];
180
+ }> | null;
187
181
  };
188
182
  captureUpdate: "EVENTUALLY";
189
183
  };
190
184
  checked: (appState: AppState) => boolean;
191
185
  predicate: (element: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps) => boolean;
192
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
186
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
193
187
  } & {
194
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
188
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
195
189
  };
@@ -30,7 +30,7 @@ export declare const actionToggleObjectsSnapMode: {
30
30
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
31
31
  isBindingEnabled: boolean;
32
32
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
33
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
33
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
34
34
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
35
35
  frameRendering: {
36
36
  enabled: boolean;
@@ -41,7 +41,7 @@ export declare const actionToggleObjectsSnapMode: {
41
41
  editingFrame: string | null;
42
42
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
43
43
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
44
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
44
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
45
45
  activeTool: {
46
46
  lastActiveTool: import("../types").ActiveTool | null;
47
47
  locked: boolean;
@@ -161,8 +161,8 @@ export declare const actionToggleObjectsSnapMode: {
161
161
  data: import("../charts").Spreadsheet;
162
162
  };
163
163
  pendingImageElementId: string | null;
164
- showHyperlinkPopup: false | "editor" | "info";
165
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
164
+ showHyperlinkPopup: false | "info" | "editor";
165
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
166
166
  snapLines: readonly import("../snapping").SnapLine[];
167
167
  originSnapOffset: {
168
168
  x: number;
@@ -172,22 +172,16 @@ export declare const actionToggleObjectsSnapMode: {
172
172
  followedBy: Set<import("../types").SocketId>;
173
173
  isCropping: boolean;
174
174
  croppingElementId: string | null;
175
- searchMatches: readonly {
176
- id: string;
177
- focus: boolean;
178
- matchedLines: {
179
- offsetX: number;
180
- offsetY: number;
181
- width: number;
182
- height: number;
183
- }[];
184
- }[];
175
+ searchMatches: Readonly<{
176
+ focusedId: string | null;
177
+ matches: readonly import("../types").SearchMatch[];
178
+ }> | null;
185
179
  };
186
180
  captureUpdate: "EVENTUALLY";
187
181
  };
188
182
  checked: (appState: Readonly<import("../types").AppState>) => boolean;
189
183
  predicate: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: import("../types").AppState, appProps: import("../types").ExcalidrawProps) => boolean;
190
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
184
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
191
185
  } & {
192
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
186
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
193
187
  };
@@ -12,179 +12,6 @@ export declare const actionToggleSearchMenu: {
12
12
  predicate: (appState: Readonly<AppState>) => boolean;
13
13
  };
14
14
  perform(elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties): false | {
15
- appState: {
16
- openSidebar: null;
17
- contextMenu: {
18
- items: import("../components/ContextMenu").ContextMenuItems;
19
- top: number;
20
- left: number;
21
- } | null;
22
- showWelcomeScreen: boolean;
23
- isLoading: boolean;
24
- errorMessage: import("react").ReactNode;
25
- activeEmbeddable: {
26
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
27
- state: "hover" | "active";
28
- } | null;
29
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
30
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
31
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
32
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
- isBindingEnabled: boolean;
34
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
35
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
36
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
37
- frameRendering: {
38
- enabled: boolean;
39
- name: boolean;
40
- outline: boolean;
41
- clip: boolean;
42
- };
43
- editingFrame: string | null;
44
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
45
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
46
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
47
- activeTool: {
48
- lastActiveTool: import("../types").ActiveTool | null;
49
- locked: boolean;
50
- fromSelection: boolean;
51
- } & import("../types").ActiveTool;
52
- penMode: boolean;
53
- penDetected: boolean;
54
- exportBackground: boolean;
55
- exportEmbedScene: boolean;
56
- exportWithDarkMode: boolean;
57
- exportScale: number;
58
- currentItemStrokeColor: string;
59
- currentItemBackgroundColor: string;
60
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
61
- currentItemStrokeWidth: number;
62
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
63
- currentItemRoughness: number;
64
- currentItemOpacity: number;
65
- currentItemFontFamily: number;
66
- currentItemFontSize: number;
67
- currentItemTextAlign: string;
68
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
69
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
70
- currentHoveredFontFamily: number | null;
71
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
72
- currentItemArrowType: "round" | "sharp" | "elbow";
73
- viewBackgroundColor: string;
74
- scrollX: number;
75
- scrollY: number;
76
- cursorButton: "up" | "down";
77
- scrolledOutside: boolean;
78
- name: string | null;
79
- isResizing: boolean;
80
- isRotating: boolean;
81
- zoom: Readonly<{
82
- value: import("../types").NormalizedZoomValue;
83
- }>;
84
- openMenu: "canvas" | "shape" | null;
85
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | null;
86
- openDialog: {
87
- name: "imageExport" | "help" | "jsonExport";
88
- } | {
89
- name: "ttd";
90
- tab: "text-to-diagram" | "mermaid";
91
- } | {
92
- name: "commandPalette";
93
- } | {
94
- name: "elementLinkSelector";
95
- sourceElementId: string;
96
- } | null;
97
- defaultSidebarDockedPreference: boolean;
98
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
99
- selectedElementIds: Readonly<{
100
- [id: string]: true;
101
- }>;
102
- hoveredElementIds: Readonly<{
103
- [id: string]: true;
104
- }>;
105
- previousSelectedElementIds: {
106
- [id: string]: true;
107
- };
108
- selectedElementsAreBeingDragged: boolean;
109
- shouldCacheIgnoreZoom: boolean;
110
- toast: {
111
- message: string;
112
- closable?: boolean | undefined;
113
- duration?: number | undefined;
114
- } | null;
115
- zenModeEnabled: boolean;
116
- theme: import("@excalidraw/element/types").Theme;
117
- gridSize: number;
118
- gridStep: number;
119
- gridModeEnabled: boolean;
120
- viewModeEnabled: boolean;
121
- selectedGroupIds: {
122
- [groupId: string]: boolean;
123
- };
124
- editingGroupId: string | null;
125
- width: number;
126
- height: number;
127
- offsetTop: number;
128
- offsetLeft: number;
129
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
130
- collaborators: Map<import("../types").SocketId, Readonly<{
131
- pointer?: import("../types").CollaboratorPointer | undefined;
132
- button?: "up" | "down" | undefined;
133
- selectedElementIds?: Readonly<{
134
- [id: string]: true;
135
- }> | undefined;
136
- username?: string | null | undefined;
137
- userState?: import("@excalidraw/common").UserIdleState | undefined;
138
- color?: {
139
- background: string;
140
- stroke: string;
141
- } | undefined;
142
- avatarUrl?: string | undefined;
143
- id?: string | undefined;
144
- socketId?: import("../types").SocketId | undefined;
145
- isCurrentUser?: boolean | undefined;
146
- isInCall?: boolean | undefined;
147
- isSpeaking?: boolean | undefined;
148
- isMuted?: boolean | undefined;
149
- }>>;
150
- stats: {
151
- open: boolean;
152
- panels: number;
153
- };
154
- currentChartType: import("@excalidraw/element/types").ChartType;
155
- pasteDialog: {
156
- shown: false;
157
- data: null;
158
- } | {
159
- shown: true;
160
- data: import("../charts").Spreadsheet;
161
- };
162
- pendingImageElementId: string | null;
163
- showHyperlinkPopup: false | "editor" | "info";
164
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
165
- snapLines: readonly import("../snapping").SnapLine[];
166
- originSnapOffset: {
167
- x: number;
168
- y: number;
169
- } | null;
170
- objectsSnapModeEnabled: boolean;
171
- userToFollow: import("../types").UserToFollow | null;
172
- followedBy: Set<import("../types").SocketId>;
173
- isCropping: boolean;
174
- croppingElementId: string | null;
175
- searchMatches: readonly {
176
- id: string;
177
- focus: boolean;
178
- matchedLines: {
179
- offsetX: number;
180
- offsetY: number;
181
- width: number;
182
- height: number;
183
- }[];
184
- }[];
185
- };
186
- captureUpdate: "EVENTUALLY";
187
- } | {
188
15
  appState: {
189
16
  openSidebar: {
190
17
  name: "default";
@@ -209,7 +36,7 @@ export declare const actionToggleSearchMenu: {
209
36
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
210
37
  isBindingEnabled: boolean;
211
38
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
212
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
39
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
213
40
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
214
41
  frameRendering: {
215
42
  enabled: boolean;
@@ -220,7 +47,7 @@ export declare const actionToggleSearchMenu: {
220
47
  editingFrame: string | null;
221
48
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
222
49
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
223
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
50
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
224
51
  activeTool: {
225
52
  lastActiveTool: import("../types").ActiveTool | null;
226
53
  locked: boolean;
@@ -326,8 +153,8 @@ export declare const actionToggleSearchMenu: {
326
153
  data: import("../charts").Spreadsheet;
327
154
  };
328
155
  pendingImageElementId: string | null;
329
- showHyperlinkPopup: false | "editor" | "info";
330
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
156
+ showHyperlinkPopup: false | "info" | "editor";
157
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
331
158
  snapLines: readonly import("../snapping").SnapLine[];
332
159
  originSnapOffset: {
333
160
  x: number;
@@ -338,22 +165,16 @@ export declare const actionToggleSearchMenu: {
338
165
  followedBy: Set<import("../types").SocketId>;
339
166
  isCropping: boolean;
340
167
  croppingElementId: string | null;
341
- searchMatches: readonly {
342
- id: string;
343
- focus: boolean;
344
- matchedLines: {
345
- offsetX: number;
346
- offsetY: number;
347
- width: number;
348
- height: number;
349
- }[];
350
- }[];
168
+ searchMatches: Readonly<{
169
+ focusedId: string | null;
170
+ matches: readonly import("../types").SearchMatch[];
171
+ }> | null;
351
172
  };
352
173
  captureUpdate: "EVENTUALLY";
353
174
  };
354
175
  checked: (appState: AppState) => boolean;
355
176
  predicate: (element: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps) => boolean;
356
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
177
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
357
178
  } & {
358
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
179
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
359
180
  };
@@ -32,7 +32,7 @@ export declare const actionToggleStats: {
32
32
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
33
  isBindingEnabled: boolean;
34
34
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
35
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
35
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
36
36
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
37
37
  frameRendering: {
38
38
  enabled: boolean;
@@ -43,7 +43,7 @@ export declare const actionToggleStats: {
43
43
  editingFrame: string | null;
44
44
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
45
45
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
46
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
46
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
47
47
  activeTool: {
48
48
  lastActiveTool: import("../types").ActiveTool | null;
49
49
  locked: boolean;
@@ -160,8 +160,8 @@ export declare const actionToggleStats: {
160
160
  data: import("../charts").Spreadsheet;
161
161
  };
162
162
  pendingImageElementId: string | null;
163
- showHyperlinkPopup: false | "editor" | "info";
164
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
163
+ showHyperlinkPopup: false | "info" | "editor";
164
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
165
165
  snapLines: readonly import("../snapping").SnapLine[];
166
166
  originSnapOffset: {
167
167
  x: number;
@@ -172,21 +172,15 @@ export declare const actionToggleStats: {
172
172
  followedBy: Set<import("../types").SocketId>;
173
173
  isCropping: boolean;
174
174
  croppingElementId: string | null;
175
- searchMatches: readonly {
176
- id: string;
177
- focus: boolean;
178
- matchedLines: {
179
- offsetX: number;
180
- offsetY: number;
181
- width: number;
182
- height: number;
183
- }[];
184
- }[];
175
+ searchMatches: Readonly<{
176
+ focusedId: string | null;
177
+ matches: readonly import("../types").SearchMatch[];
178
+ }> | null;
185
179
  };
186
180
  captureUpdate: "EVENTUALLY";
187
181
  };
188
182
  checked: (appState: Readonly<import("../types").AppState>) => boolean;
189
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
183
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
190
184
  } & {
191
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
185
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
192
186
  };
@@ -29,7 +29,7 @@ export declare const actionToggleViewMode: {
29
29
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
30
30
  isBindingEnabled: boolean;
31
31
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
32
- suggestedBindings: import("@excalidraw/element/binding").SuggestedBinding[];
32
+ suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
33
33
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
34
34
  frameRendering: {
35
35
  enabled: boolean;
@@ -40,7 +40,7 @@ export declare const actionToggleViewMode: {
40
40
  editingFrame: string | null;
41
41
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
42
42
  editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
43
- editingLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
43
+ editingLinearElement: import("@excalidraw/element").LinearElementEditor | null;
44
44
  activeTool: {
45
45
  lastActiveTool: import("../types").ActiveTool | null;
46
46
  locked: boolean;
@@ -160,8 +160,8 @@ export declare const actionToggleViewMode: {
160
160
  data: import("../charts").Spreadsheet;
161
161
  };
162
162
  pendingImageElementId: string | null;
163
- showHyperlinkPopup: false | "editor" | "info";
164
- selectedLinearElement: import("@excalidraw/element/linearElementEditor").LinearElementEditor | null;
163
+ showHyperlinkPopup: false | "info" | "editor";
164
+ selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
165
165
  snapLines: readonly import("../snapping").SnapLine[];
166
166
  originSnapOffset: {
167
167
  x: number;
@@ -172,22 +172,16 @@ export declare const actionToggleViewMode: {
172
172
  followedBy: Set<import("../types").SocketId>;
173
173
  isCropping: boolean;
174
174
  croppingElementId: string | null;
175
- searchMatches: readonly {
176
- id: string;
177
- focus: boolean;
178
- matchedLines: {
179
- offsetX: number;
180
- offsetY: number;
181
- width: number;
182
- height: number;
183
- }[];
184
- }[];
175
+ searchMatches: Readonly<{
176
+ focusedId: string | null;
177
+ matches: readonly import("../types").SearchMatch[];
178
+ }> | null;
185
179
  };
186
180
  captureUpdate: "EVENTUALLY";
187
181
  };
188
182
  checked: (appState: Readonly<import("../types").AppState>) => boolean;
189
183
  predicate: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: import("../types").AppState, appProps: import("../types").ExcalidrawProps) => boolean;
190
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
184
+ keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
191
185
  } & {
192
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
186
+ keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
193
187
  };