@excalidraw/element 0.18.0-0457ac9 → 0.18.0-063e025

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 (123) hide show
  1. package/dist/dev/index.js +1305 -895
  2. package/dist/dev/index.js.map +4 -4
  3. package/dist/prod/index.js +18 -18
  4. package/dist/types/common/src/colors.d.ts +1 -1
  5. package/dist/types/common/src/constants.d.ts +9 -7
  6. package/dist/types/common/src/utils.d.ts +0 -42
  7. package/dist/types/element/src/Scene.d.ts +1 -1
  8. package/dist/types/element/src/align.d.ts +2 -2
  9. package/dist/types/element/src/binding.d.ts +6 -6
  10. package/dist/types/element/src/bounds.d.ts +19 -6
  11. package/dist/types/element/src/collision.d.ts +1 -1
  12. package/dist/types/element/src/comparisons.d.ts +1 -0
  13. package/dist/types/element/src/distribute.d.ts +2 -2
  14. package/dist/types/element/src/duplicate.d.ts +3 -3
  15. package/dist/types/element/src/embeddable.d.ts +2 -2
  16. package/dist/types/element/src/flowchart.d.ts +3 -3
  17. package/dist/types/element/src/fractionalIndex.d.ts +2 -2
  18. package/dist/types/element/src/frame.d.ts +4 -4
  19. package/dist/types/element/src/groups.d.ts +9 -9
  20. package/dist/types/element/src/index.d.ts +1 -1
  21. package/dist/types/element/src/linearElementEditor.d.ts +10 -10
  22. package/dist/types/element/src/newElement.d.ts +1 -0
  23. package/dist/types/element/src/renderElement.d.ts +0 -3
  24. package/dist/types/element/src/resizeElements.d.ts +2 -2
  25. package/dist/types/element/src/selection.d.ts +5 -5
  26. package/dist/types/element/src/textElement.d.ts +7 -7
  27. package/dist/types/element/src/transform.d.ts +2 -2
  28. package/dist/types/element/src/typeChecks.d.ts +25 -25
  29. package/dist/types/element/src/types.d.ts +8 -1
  30. package/dist/types/element/src/visualdebug.d.ts +1 -2
  31. package/dist/types/element/src/zindex.d.ts +2 -2
  32. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +12 -6
  33. package/dist/types/excalidraw/actions/actionAlign.d.ts +6 -6
  34. package/dist/types/excalidraw/actions/actionBoundText.d.ts +8 -4
  35. package/dist/types/excalidraw/actions/actionCanvas.d.ts +61 -389
  36. package/dist/types/excalidraw/actions/actionClipboard.d.ts +8 -4
  37. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +4 -2
  38. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +13 -7
  39. package/dist/types/excalidraw/actions/actionDeselect.d.ts +4 -2
  40. package/dist/types/excalidraw/actions/actionDistribute.d.ts +2 -3
  41. package/dist/types/excalidraw/actions/actionElementLink.d.ts +4 -2
  42. package/dist/types/excalidraw/actions/actionElementLock.d.ts +9 -5
  43. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +4 -2
  44. package/dist/types/excalidraw/actions/actionExport.d.ts +8 -4
  45. package/dist/types/excalidraw/actions/actionFrame.d.ts +29 -20
  46. package/dist/types/excalidraw/actions/actionGroup.d.ts +23 -19
  47. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +7 -4
  48. package/dist/types/excalidraw/actions/actionLink.d.ts +5 -3
  49. package/dist/types/excalidraw/actions/actionMenu.d.ts +4 -2
  50. package/dist/types/excalidraw/actions/actionProperties.d.ts +35 -22
  51. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +9 -7
  52. package/dist/types/excalidraw/actions/actionStyles.d.ts +4 -2
  53. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +5 -3
  54. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +8 -7
  55. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +5 -3
  56. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +5 -3
  57. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +8 -7
  58. package/dist/types/excalidraw/actions/actionToggleShapeSwitch.d.ts +1 -1
  59. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +5 -3
  60. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +5 -3
  61. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +5 -3
  62. package/dist/types/excalidraw/actions/index.d.ts +1 -1
  63. package/dist/types/excalidraw/actions/types.d.ts +4 -4
  64. package/dist/types/excalidraw/{animated-trail.d.ts → animatedTrail.d.ts} +4 -3
  65. package/dist/types/excalidraw/appState.d.ts +2 -1
  66. package/dist/types/excalidraw/components/Actions.d.ts +2 -3
  67. package/dist/types/excalidraw/components/ActiveConfirmDialog.d.ts +1 -1
  68. package/dist/types/excalidraw/components/App.d.ts +61 -32
  69. package/dist/types/excalidraw/components/ColorPicker/ColorPicker.d.ts +2 -2
  70. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +1 -1
  71. package/dist/types/excalidraw/components/CommandPalette/defaultCommandPaletteItems.d.ts +1 -2
  72. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +2 -2
  73. package/dist/types/excalidraw/components/CursorHint.d.ts +46 -0
  74. package/dist/types/excalidraw/components/EyeDropper.d.ts +1 -1
  75. package/dist/types/excalidraw/components/Island.d.ts +7 -0
  76. package/dist/types/excalidraw/components/LibraryMenu.d.ts +1 -1
  77. package/dist/types/excalidraw/components/OverwriteConfirm/OverwriteConfirmState.d.ts +1 -1
  78. package/dist/types/excalidraw/components/SVGLayer.d.ts +1 -1
  79. package/dist/types/excalidraw/components/SearchMenu.d.ts +1 -1
  80. package/dist/types/excalidraw/components/Sidebar/Sidebar.d.ts +1 -1
  81. package/dist/types/excalidraw/components/Stats/Angle.d.ts +2 -2
  82. package/dist/types/excalidraw/components/Stats/Dimension.d.ts +2 -2
  83. package/dist/types/excalidraw/components/Stats/DragInput.d.ts +2 -2
  84. package/dist/types/excalidraw/components/Stats/MultiAngle.d.ts +2 -2
  85. package/dist/types/excalidraw/components/Stats/MultiDimension.d.ts +2 -2
  86. package/dist/types/excalidraw/components/Stats/MultiPosition.d.ts +2 -2
  87. package/dist/types/excalidraw/components/Stats/Position.d.ts +3 -3
  88. package/dist/types/excalidraw/components/Stats/utils.d.ts +1 -1
  89. package/dist/types/excalidraw/components/TTDDialog/TTDContext.d.ts +4 -4
  90. package/dist/types/excalidraw/components/TTDDialog/useTTDChatStorage.d.ts +3 -3
  91. package/dist/types/excalidraw/components/hyperlink/helpers.d.ts +2 -2
  92. package/dist/types/excalidraw/components/icons.d.ts +2 -0
  93. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +6 -3
  94. package/dist/types/excalidraw/data/blob.d.ts +8 -4
  95. package/dist/types/excalidraw/data/index.d.ts +4 -4
  96. package/dist/types/excalidraw/data/json.d.ts +10 -8
  97. package/dist/types/excalidraw/data/library.d.ts +1 -1
  98. package/dist/types/excalidraw/eraser/index.d.ts +2 -3
  99. package/dist/types/excalidraw/hooks/useAppStateValue.d.ts +29 -0
  100. package/dist/types/excalidraw/hooks/useLibraryItemSvg.d.ts +1 -1
  101. package/dist/types/excalidraw/{laser-trails.d.ts → laserTrails.d.ts} +5 -7
  102. package/dist/types/excalidraw/lasso/index.d.ts +2 -3
  103. package/dist/types/excalidraw/renderer/animation.d.ts +5 -1
  104. package/dist/types/excalidraw/renderer/interactiveScene.d.ts +1 -3
  105. package/dist/types/excalidraw/scene/Renderer.d.ts +12 -11
  106. package/dist/types/excalidraw/scene/export.d.ts +3 -3
  107. package/dist/types/excalidraw/scene/index.d.ts +2 -2
  108. package/dist/types/excalidraw/scene/types.d.ts +1 -3
  109. package/dist/types/excalidraw/snapping.d.ts +7 -7
  110. package/dist/types/excalidraw/types.d.ts +168 -11
  111. package/dist/types/excalidraw/viewport.d.ts +316 -0
  112. package/dist/types/excalidraw/wysiwyg/textWysiwyg.d.ts +2 -3
  113. package/dist/types/laser-pointer/src/index.d.ts +2 -0
  114. package/dist/types/laser-pointer/src/math.d.ts +16 -0
  115. package/dist/types/laser-pointer/src/simplify.d.ts +2 -0
  116. package/dist/types/laser-pointer/src/state.d.ts +35 -0
  117. package/dist/types/utils/src/export.d.ts +3 -3
  118. package/dist/types/utils/src/index.d.ts +1 -2
  119. package/package.json +4 -4
  120. package/dist/types/excalidraw/animation-frame-handler.d.ts +0 -16
  121. package/dist/types/excalidraw/scene/scroll.d.ts +0 -18
  122. package/dist/types/utils/src/bbox.d.ts +0 -9
  123. package/dist/types/utils/src/withinBounds.d.ts +0 -19
@@ -1,21 +1,21 @@
1
1
  import type { ExcalidrawElement, ExcalidrawTextElement, OrderedExcalidrawElement } from "@excalidraw/element/types";
2
- import type { AppClassProperties, AppState } from "../types";
2
+ import type { AppClassProperties, UIAppState } from "../types";
3
3
  export declare const actionGroup: {
4
4
  name: "group";
5
5
  label: string;
6
- icon: (appState: import("../types").UIAppState) => import("react/jsx-runtime").JSX.Element;
6
+ icon: (appState: UIAppState) => import("react/jsx-runtime").JSX.Element;
7
7
  trackEvent: {
8
8
  category: "element";
9
9
  };
10
- perform: (elements: readonly OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: AppClassProperties) => {
11
- appState: Readonly<AppState>;
10
+ perform: (elements: readonly OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: unknown, app: AppClassProperties) => {
11
+ appState: Readonly<import("../types").AppState>;
12
12
  elements: readonly OrderedExcalidrawElement[];
13
13
  captureUpdate: "EVENTUALLY";
14
14
  } | {
15
15
  appState: {
16
- editingGroupId: AppState["editingGroupId"];
17
- selectedElementIds: AppState["selectedElementIds"];
18
- selectedGroupIds: AppState["selectedGroupIds"];
16
+ editingGroupId: import("../types").AppState["editingGroupId"];
17
+ selectedElementIds: import("../types").AppState["selectedElementIds"];
18
+ selectedGroupIds: import("../types").AppState["selectedGroupIds"];
19
19
  contextMenu: {
20
20
  items: import("../components/ContextMenu").ContextMenuItems;
21
21
  top: number;
@@ -48,7 +48,7 @@ export declare const actionGroup: {
48
48
  clip: boolean;
49
49
  };
50
50
  editingFrame: string | null;
51
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
51
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
52
52
  editingTextElement: ExcalidrawTextElement | null;
53
53
  activeTool: {
54
54
  lastActiveTool: import("../types").ActiveTool | null;
@@ -68,9 +68,10 @@ export declare const actionGroup: {
68
68
  currentItemStrokeColor: string;
69
69
  currentItemBackgroundColor: string;
70
70
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
71
- currentItemStrokeWidth: number;
71
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
72
72
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
73
73
  currentItemRoughness: number;
74
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
74
75
  currentItemOpacity: number;
75
76
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
76
77
  currentItemFontSize: number;
@@ -83,6 +84,7 @@ export declare const actionGroup: {
83
84
  viewBackgroundColor: string;
84
85
  scrollX: number;
85
86
  scrollY: number;
87
+ scrollConstraints: import("../types").ScrollConstraints | null;
86
88
  cursorButton: "up" | "down";
87
89
  scrolledOutside: boolean;
88
90
  name: string | null;
@@ -168,7 +170,7 @@ export declare const actionGroup: {
168
170
  elements: OrderedExcalidrawElement[];
169
171
  captureUpdate: "IMMEDIATELY";
170
172
  };
171
- predicate: (elements: readonly ExcalidrawElement[], appState: AppState, _: import("../types").ExcalidrawProps, app: AppClassProperties) => boolean;
173
+ predicate: (elements: readonly ExcalidrawElement[], appState: import("../types").AppState, _: import("../types").ExcalidrawProps, app: AppClassProperties) => boolean;
172
174
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
173
175
  PanelComponent: ({ elements, appState, updateData, app }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
174
176
  } & {
@@ -177,19 +179,19 @@ export declare const actionGroup: {
177
179
  export declare const actionUngroup: {
178
180
  name: "ungroup";
179
181
  label: string;
180
- icon: (appState: import("../types").UIAppState) => import("react/jsx-runtime").JSX.Element;
182
+ icon: (appState: UIAppState) => import("react/jsx-runtime").JSX.Element;
181
183
  trackEvent: {
182
184
  category: "element";
183
185
  };
184
- perform: (elements: readonly OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: AppClassProperties) => {
185
- appState: Readonly<AppState>;
186
+ perform: (elements: readonly OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>, _: unknown, app: AppClassProperties) => {
187
+ appState: Readonly<import("../types").AppState>;
186
188
  elements: readonly OrderedExcalidrawElement[];
187
189
  captureUpdate: "EVENTUALLY";
188
190
  } | {
189
191
  appState: {
190
- editingGroupId: AppState["editingGroupId"];
191
- selectedElementIds: AppState["selectedElementIds"];
192
- selectedGroupIds: AppState["selectedGroupIds"];
192
+ editingGroupId: import("../types").AppState["editingGroupId"];
193
+ selectedElementIds: import("../types").AppState["selectedElementIds"];
194
+ selectedGroupIds: import("../types").AppState["selectedGroupIds"];
193
195
  contextMenu: {
194
196
  items: import("../components/ContextMenu").ContextMenuItems;
195
197
  top: number;
@@ -222,7 +224,7 @@ export declare const actionUngroup: {
222
224
  clip: boolean;
223
225
  };
224
226
  editingFrame: string | null;
225
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
227
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
226
228
  editingTextElement: ExcalidrawTextElement | null;
227
229
  activeTool: {
228
230
  lastActiveTool: import("../types").ActiveTool | null;
@@ -242,9 +244,10 @@ export declare const actionUngroup: {
242
244
  currentItemStrokeColor: string;
243
245
  currentItemBackgroundColor: string;
244
246
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
245
- currentItemStrokeWidth: number;
247
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
246
248
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
247
249
  currentItemRoughness: number;
250
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
248
251
  currentItemOpacity: number;
249
252
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
250
253
  currentItemFontSize: number;
@@ -257,6 +260,7 @@ export declare const actionUngroup: {
257
260
  viewBackgroundColor: string;
258
261
  scrollX: number;
259
262
  scrollY: number;
263
+ scrollConstraints: import("../types").ScrollConstraints | null;
260
264
  cursorButton: "up" | "down";
261
265
  scrolledOutside: boolean;
262
266
  name: string | null;
@@ -343,7 +347,7 @@ export declare const actionUngroup: {
343
347
  captureUpdate: "IMMEDIATELY";
344
348
  };
345
349
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
346
- predicate: (elements: readonly ExcalidrawElement[], appState: AppState) => boolean;
350
+ predicate: (elements: readonly ExcalidrawElement[], appState: import("../types").AppState) => boolean;
347
351
  PanelComponent: ({ elements, appState, updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
348
352
  } & {
349
353
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
@@ -2,7 +2,7 @@ import type { ExcalidrawLinearElement } from "@excalidraw/element/types";
2
2
  export declare const actionToggleLinearEditor: {
3
3
  name: "toggleLinearEditor";
4
4
  category: string;
5
- label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, app: import("../types").AppClassProperties) => "labels.lineEditor.editArrow" | "labels.lineEditor.edit";
5
+ label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").UIAppState>, app: import("../types").AppClassProperties) => "labels.lineEditor.editArrow" | "labels.lineEditor.edit";
6
6
  keywords: string[];
7
7
  trackEvent: {
8
8
  category: "element";
@@ -75,7 +75,7 @@ export declare const actionToggleLinearEditor: {
75
75
  clip: boolean;
76
76
  };
77
77
  editingFrame: string | null;
78
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
78
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
79
79
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
80
80
  activeTool: {
81
81
  lastActiveTool: import("../types").ActiveTool | null;
@@ -95,9 +95,10 @@ export declare const actionToggleLinearEditor: {
95
95
  currentItemStrokeColor: string;
96
96
  currentItemBackgroundColor: string;
97
97
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
98
- currentItemStrokeWidth: number;
98
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
99
99
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
100
100
  currentItemRoughness: number;
101
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
101
102
  currentItemOpacity: number;
102
103
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
103
104
  currentItemFontSize: number;
@@ -110,6 +111,7 @@ export declare const actionToggleLinearEditor: {
110
111
  viewBackgroundColor: string;
111
112
  scrollX: number;
112
113
  scrollY: number;
114
+ scrollConstraints: import("../types").ScrollConstraints | null;
113
115
  cursorButton: "up" | "down";
114
116
  scrolledOutside: boolean;
115
117
  name: string | null;
@@ -209,7 +211,7 @@ export declare const actionTogglePolygon: {
209
211
  category: string;
210
212
  icon: import("react/jsx-runtime").JSX.Element;
211
213
  keywords: string[];
212
- label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>, app: import("../types").AppClassProperties) => "labels.polygon.breakPolygon" | "labels.polygon.convertToPolygon";
214
+ label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").UIAppState>, app: import("../types").AppClassProperties) => "labels.polygon.breakPolygon" | "labels.polygon.convertToPolygon";
213
215
  trackEvent: {
214
216
  category: "element";
215
217
  };
@@ -649,6 +651,7 @@ export declare const actionTogglePolygon: {
649
651
  points: readonly import("@excalidraw/math").LocalPoint[];
650
652
  pressures: readonly number[];
651
653
  simulatePressure: boolean;
654
+ strokeOptions: import("@excalidraw/element/types").StrokeOptions;
652
655
  }> & {
653
656
  index: import("@excalidraw/element/types").FractionalIndex;
654
657
  }))[];
@@ -1,6 +1,6 @@
1
1
  export declare const actionLink: {
2
2
  name: "hyperlink";
3
- label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").AppState>) => "labels.link.editEmbed" | "labels.link.edit" | "labels.link.create";
3
+ label: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: Readonly<import("../types").UIAppState>) => "labels.link.editEmbed" | "labels.link.edit" | "labels.link.create";
4
4
  icon: import("react/jsx-runtime").JSX.Element;
5
5
  perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>) => false | {
6
6
  elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[];
@@ -39,7 +39,7 @@ export declare const actionLink: {
39
39
  clip: boolean;
40
40
  };
41
41
  editingFrame: string | null;
42
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
42
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
43
43
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
44
44
  activeTool: {
45
45
  lastActiveTool: import("../types").ActiveTool | null;
@@ -59,9 +59,10 @@ export declare const actionLink: {
59
59
  currentItemStrokeColor: string;
60
60
  currentItemBackgroundColor: string;
61
61
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
62
- currentItemStrokeWidth: number;
62
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
63
63
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
64
64
  currentItemRoughness: number;
65
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
65
66
  currentItemOpacity: number;
66
67
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
67
68
  currentItemFontSize: number;
@@ -74,6 +75,7 @@ export declare const actionLink: {
74
75
  viewBackgroundColor: string;
75
76
  scrollX: number;
76
77
  scrollY: number;
78
+ scrollConstraints: import("../types").ScrollConstraints | null;
77
79
  cursorButton: "up" | "down";
78
80
  scrolledOutside: boolean;
79
81
  name: string | null;
@@ -46,7 +46,7 @@ export declare const actionShortcuts: {
46
46
  clip: boolean;
47
47
  };
48
48
  editingFrame: string | null;
49
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
49
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
50
50
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
51
51
  activeTool: {
52
52
  lastActiveTool: import("../types").ActiveTool | null;
@@ -66,9 +66,10 @@ export declare const actionShortcuts: {
66
66
  currentItemStrokeColor: string;
67
67
  currentItemBackgroundColor: string;
68
68
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
69
- currentItemStrokeWidth: number;
69
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
70
70
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
71
71
  currentItemRoughness: number;
72
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
72
73
  currentItemOpacity: number;
73
74
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
74
75
  currentItemFontSize: number;
@@ -81,6 +82,7 @@ export declare const actionShortcuts: {
81
82
  viewBackgroundColor: string;
82
83
  scrollX: number;
83
84
  scrollY: number;
85
+ scrollConstraints: import("../types").ScrollConstraints | null;
84
86
  cursorButton: "up" | "down";
85
87
  scrolledOutside: boolean;
86
88
  name: string | null;
@@ -1,8 +1,14 @@
1
+ import { type StrokeWidthKey } from "@excalidraw/common";
1
2
  import { LinearElementEditor } from "@excalidraw/element";
2
- import type { Arrowhead, ExcalidrawBindableElement, ExcalidrawElement, ExcalidrawLinearElement, ExcalidrawTextElement, FontFamilyValues, TextAlign } from "@excalidraw/element/types";
3
+ import type { Arrowhead, ExcalidrawBindableElement, ExcalidrawElement, ExcalidrawLinearElement, ExcalidrawTextElement, FontFamilyValues, StrokeVariability, NonDeleted, NonDeletedExcalidrawElement, TextAlign } from "@excalidraw/element/types";
3
4
  import type { AppClassProperties, AppState, Primitive } from "../types";
4
- export declare const changeProperty: (elements: readonly ExcalidrawElement[], appState: AppState, callback: (element: ExcalidrawElement) => ExcalidrawElement, includeBoundText?: boolean) => ExcalidrawElement[];
5
- export declare const getFormValue: <T extends Primitive>(elements: readonly ExcalidrawElement[], app: AppClassProperties, getAttribute: (element: ExcalidrawElement) => T, elementPredicate: true | ((element: ExcalidrawElement) => boolean), defaultValue: T | ((isSomeElementSelected: boolean) => T)) => T;
5
+ export declare const changeProperty: (elements: readonly ExcalidrawElement[], appState: AppState, callback: (element: NonDeletedExcalidrawElement) => ExcalidrawElement, includeBoundText?: boolean) => ExcalidrawElement[];
6
+ export declare const getFormValue: <T extends Primitive>(elements: readonly ExcalidrawElement[], app: AppClassProperties,
7
+ /**
8
+ * input value (usually the element attribute value,
9
+ * but depends on what the action's PanelComponent input expects)
10
+ */
11
+ getValue: (element: ExcalidrawElement) => T, elementPredicate: true | ((element: ExcalidrawElement) => boolean), defaultValue: T | ((isSomeElementSelected: boolean) => T)) => T;
6
12
  export declare const actionChangeStrokeColor: import("./types").Action<Pick<AppState, "currentItemStrokeColor">> & {
7
13
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
8
14
  };
@@ -12,12 +18,15 @@ export declare const actionChangeBackgroundColor: import("./types").Action<Pick<
12
18
  export declare const actionChangeFillStyle: import("./types").Action<import("@excalidraw/element/types").FillStyle> & {
13
19
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
14
20
  };
15
- export declare const actionChangeStrokeWidth: import("./types").Action<number> & {
21
+ export declare const actionChangeStrokeWidth: import("./types").Action<StrokeWidthKey> & {
16
22
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
17
23
  };
18
24
  export declare const actionChangeSloppiness: import("./types").Action<number> & {
19
25
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
20
26
  };
27
+ export declare const actionChangeFreedrawMode: import("./types").Action<StrokeVariability> & {
28
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
29
+ };
21
30
  export declare const actionChangeStrokeStyle: import("./types").Action<import("@excalidraw/element/types").StrokeStyle> & {
22
31
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
23
32
  };
@@ -45,22 +54,22 @@ export declare const actionDecreaseFontSize: {
45
54
  isLoading: boolean;
46
55
  errorMessage: React.ReactNode;
47
56
  activeEmbeddable: {
48
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
57
+ element: NonDeletedExcalidrawElement;
49
58
  state: "hover" | "active";
50
59
  } | null;
51
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
52
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
53
- multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
54
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
60
+ newElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
61
+ resizingElement: NonDeletedExcalidrawElement | null;
62
+ multiElement: NonDeleted<ExcalidrawLinearElement> | null;
63
+ selectionElement: NonDeletedExcalidrawElement | null;
55
64
  isBindingEnabled: boolean;
56
65
  boxSelectionMode: import("../types").BoxSelectionMode;
57
66
  bindingPreference: "enabled" | "disabled";
58
67
  isMidpointSnappingEnabled: boolean;
59
68
  suggestedBinding: {
60
- element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
69
+ element: NonDeleted<ExcalidrawBindableElement>;
61
70
  midPoint?: import("@excalidraw/math").GlobalPoint;
62
71
  } | null;
63
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
72
+ frameToHighlight: NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
64
73
  frameRendering: {
65
74
  enabled: boolean;
66
75
  name: boolean;
@@ -68,7 +77,7 @@ export declare const actionDecreaseFontSize: {
68
77
  clip: boolean;
69
78
  };
70
79
  editingFrame: string | null;
71
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
80
+ elementsToHighlight: readonly NonDeletedExcalidrawElement[] | null;
72
81
  editingTextElement: ExcalidrawTextElement | null;
73
82
  activeTool: {
74
83
  lastActiveTool: import("../types").ActiveTool | null;
@@ -88,9 +97,10 @@ export declare const actionDecreaseFontSize: {
88
97
  currentItemStrokeColor: string;
89
98
  currentItemBackgroundColor: string;
90
99
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
91
- currentItemStrokeWidth: number;
100
+ currentItemStrokeWidthKey: StrokeWidthKey;
92
101
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
93
102
  currentItemRoughness: number;
103
+ currentItemStrokeVariability: StrokeVariability;
94
104
  currentItemOpacity: number;
95
105
  currentItemFontFamily: FontFamilyValues;
96
106
  currentItemTextAlign: TextAlign;
@@ -102,6 +112,7 @@ export declare const actionDecreaseFontSize: {
102
112
  viewBackgroundColor: string;
103
113
  scrollX: number;
104
114
  scrollY: number;
115
+ scrollConstraints: import("../types").ScrollConstraints | null;
105
116
  cursorButton: "up" | "down";
106
117
  scrolledOutside: boolean;
107
118
  name: string | null;
@@ -215,22 +226,22 @@ export declare const actionIncreaseFontSize: {
215
226
  isLoading: boolean;
216
227
  errorMessage: React.ReactNode;
217
228
  activeEmbeddable: {
218
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
229
+ element: NonDeletedExcalidrawElement;
219
230
  state: "hover" | "active";
220
231
  } | null;
221
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
222
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
223
- multiElement: import("@excalidraw/element/types").NonDeleted<ExcalidrawLinearElement> | null;
224
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
232
+ newElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
233
+ resizingElement: NonDeletedExcalidrawElement | null;
234
+ multiElement: NonDeleted<ExcalidrawLinearElement> | null;
235
+ selectionElement: NonDeletedExcalidrawElement | null;
225
236
  isBindingEnabled: boolean;
226
237
  boxSelectionMode: import("../types").BoxSelectionMode;
227
238
  bindingPreference: "enabled" | "disabled";
228
239
  isMidpointSnappingEnabled: boolean;
229
240
  suggestedBinding: {
230
- element: import("@excalidraw/element/types").NonDeleted<ExcalidrawBindableElement>;
241
+ element: NonDeleted<ExcalidrawBindableElement>;
231
242
  midPoint?: import("@excalidraw/math").GlobalPoint;
232
243
  } | null;
233
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
244
+ frameToHighlight: NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
234
245
  frameRendering: {
235
246
  enabled: boolean;
236
247
  name: boolean;
@@ -238,7 +249,7 @@ export declare const actionIncreaseFontSize: {
238
249
  clip: boolean;
239
250
  };
240
251
  editingFrame: string | null;
241
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
252
+ elementsToHighlight: readonly NonDeletedExcalidrawElement[] | null;
242
253
  editingTextElement: ExcalidrawTextElement | null;
243
254
  activeTool: {
244
255
  lastActiveTool: import("../types").ActiveTool | null;
@@ -258,9 +269,10 @@ export declare const actionIncreaseFontSize: {
258
269
  currentItemStrokeColor: string;
259
270
  currentItemBackgroundColor: string;
260
271
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
261
- currentItemStrokeWidth: number;
272
+ currentItemStrokeWidthKey: StrokeWidthKey;
262
273
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
263
274
  currentItemRoughness: number;
275
+ currentItemStrokeVariability: StrokeVariability;
264
276
  currentItemOpacity: number;
265
277
  currentItemFontFamily: FontFamilyValues;
266
278
  currentItemTextAlign: TextAlign;
@@ -272,6 +284,7 @@ export declare const actionIncreaseFontSize: {
272
284
  viewBackgroundColor: string;
273
285
  scrollX: number;
274
286
  scrollY: number;
287
+ scrollConstraints: import("../types").ScrollConstraints | null;
275
288
  cursorButton: "up" | "down";
276
289
  scrolledOutside: boolean;
277
290
  name: string | null;
@@ -1,5 +1,5 @@
1
1
  import { LinearElementEditor } from "@excalidraw/element";
2
- import type { ExcalidrawElement } from "@excalidraw/element/types";
2
+ import type { ExcalidrawElement, ExcalidrawLinearElement, NonDeleted } from "@excalidraw/element/types";
3
3
  export declare const actionSelectAll: {
4
4
  name: "selectAll";
5
5
  label: string;
@@ -26,19 +26,19 @@ export declare const actionSelectAll: {
26
26
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
27
27
  state: "hover" | "active";
28
28
  } | null;
29
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
29
+ newElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
30
30
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
31
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
31
+ multiElement: NonDeleted<ExcalidrawLinearElement> | null;
32
32
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
33
33
  isBindingEnabled: boolean;
34
34
  boxSelectionMode: import("../types").BoxSelectionMode;
35
35
  bindingPreference: "enabled" | "disabled";
36
36
  isMidpointSnappingEnabled: boolean;
37
37
  suggestedBinding: {
38
- element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
38
+ element: NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
39
39
  midPoint?: import("@excalidraw/math").GlobalPoint;
40
40
  } | null;
41
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
41
+ frameToHighlight: NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
42
42
  frameRendering: {
43
43
  enabled: boolean;
44
44
  name: boolean;
@@ -46,7 +46,7 @@ export declare const actionSelectAll: {
46
46
  clip: boolean;
47
47
  };
48
48
  editingFrame: string | null;
49
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
49
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
50
50
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
51
51
  activeTool: {
52
52
  lastActiveTool: import("../types").ActiveTool | null;
@@ -66,9 +66,10 @@ export declare const actionSelectAll: {
66
66
  currentItemStrokeColor: string;
67
67
  currentItemBackgroundColor: string;
68
68
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
69
- currentItemStrokeWidth: number;
69
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
70
70
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
71
71
  currentItemRoughness: number;
72
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
72
73
  currentItemOpacity: number;
73
74
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
74
75
  currentItemFontSize: number;
@@ -81,6 +82,7 @@ export declare const actionSelectAll: {
81
82
  viewBackgroundColor: string;
82
83
  scrollX: number;
83
84
  scrollY: number;
85
+ scrollConstraints: import("../types").ScrollConstraints | null;
84
86
  cursorButton: "up" | "down";
85
87
  scrolledOutside: boolean;
86
88
  name: string | null;
@@ -44,7 +44,7 @@ export declare const actionCopyStyles: {
44
44
  clip: boolean;
45
45
  };
46
46
  editingFrame: string | null;
47
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
47
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
48
48
  editingTextElement: ExcalidrawTextElement | null;
49
49
  activeTool: {
50
50
  lastActiveTool: import("../types").ActiveTool | null;
@@ -64,9 +64,10 @@ export declare const actionCopyStyles: {
64
64
  currentItemStrokeColor: string;
65
65
  currentItemBackgroundColor: string;
66
66
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
67
- currentItemStrokeWidth: number;
67
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
68
68
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
69
69
  currentItemRoughness: number;
70
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
70
71
  currentItemOpacity: number;
71
72
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
72
73
  currentItemFontSize: number;
@@ -79,6 +80,7 @@ export declare const actionCopyStyles: {
79
80
  viewBackgroundColor: string;
80
81
  scrollX: number;
81
82
  scrollY: number;
83
+ scrollConstraints: import("../types").ScrollConstraints | null;
82
84
  cursorButton: "up" | "down";
83
85
  scrolledOutside: boolean;
84
86
  name: string | null;
@@ -40,7 +40,7 @@ export declare const actionToggleArrowBinding: {
40
40
  clip: boolean;
41
41
  };
42
42
  editingFrame: string | null;
43
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
43
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
44
44
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
45
45
  activeTool: {
46
46
  lastActiveTool: import("../types").ActiveTool | null;
@@ -60,9 +60,10 @@ export declare const actionToggleArrowBinding: {
60
60
  currentItemStrokeColor: string;
61
61
  currentItemBackgroundColor: string;
62
62
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
63
- currentItemStrokeWidth: number;
63
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
64
64
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
65
65
  currentItemRoughness: number;
66
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
66
67
  currentItemOpacity: number;
67
68
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
68
69
  currentItemFontSize: number;
@@ -75,6 +76,7 @@ export declare const actionToggleArrowBinding: {
75
76
  viewBackgroundColor: string;
76
77
  scrollX: number;
77
78
  scrollY: number;
79
+ scrollConstraints: import("../types").ScrollConstraints | null;
78
80
  cursorButton: "up" | "down";
79
81
  scrolledOutside: boolean;
80
82
  name: string | null;
@@ -166,7 +168,7 @@ export declare const actionToggleArrowBinding: {
166
168
  };
167
169
  captureUpdate: "NEVER";
168
170
  };
169
- checked: (appState: Readonly<import("../types").AppState>) => boolean;
171
+ checked: (appState: Readonly<import("../types").UIAppState>) => boolean;
170
172
  } & {
171
173
  keyTest?: undefined;
172
174
  };
@@ -1,4 +1,3 @@
1
- import type { AppState } from "../types";
2
1
  export declare const actionToggleGridMode: {
3
2
  name: "gridMode";
4
3
  icon: import("react/jsx-runtime").JSX.Element;
@@ -7,9 +6,9 @@ export declare const actionToggleGridMode: {
7
6
  viewMode: true;
8
7
  trackEvent: {
9
8
  category: "canvas";
10
- predicate: (appState: Readonly<AppState>) => boolean;
9
+ predicate: (appState: Readonly<import("../types").AppState>) => boolean;
11
10
  };
12
- perform(elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>): {
11
+ perform(elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<import("../types").AppState>): {
13
12
  appState: {
14
13
  gridModeEnabled: boolean;
15
14
  objectsSnapModeEnabled: false;
@@ -45,7 +44,7 @@ export declare const actionToggleGridMode: {
45
44
  clip: boolean;
46
45
  };
47
46
  editingFrame: string | null;
48
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
47
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
49
48
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
50
49
  activeTool: {
51
50
  lastActiveTool: import("../types").ActiveTool | null;
@@ -65,9 +64,10 @@ export declare const actionToggleGridMode: {
65
64
  currentItemStrokeColor: string;
66
65
  currentItemBackgroundColor: string;
67
66
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
68
- currentItemStrokeWidth: number;
67
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
69
68
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
70
69
  currentItemRoughness: number;
70
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
71
71
  currentItemOpacity: number;
72
72
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
73
73
  currentItemFontSize: number;
@@ -80,6 +80,7 @@ export declare const actionToggleGridMode: {
80
80
  viewBackgroundColor: string;
81
81
  scrollX: number;
82
82
  scrollY: number;
83
+ scrollConstraints: import("../types").ScrollConstraints | null;
83
84
  cursorButton: "up" | "down";
84
85
  scrolledOutside: boolean;
85
86
  name: string | null;
@@ -169,8 +170,8 @@ export declare const actionToggleGridMode: {
169
170
  };
170
171
  captureUpdate: "EVENTUALLY";
171
172
  };
172
- checked: (appState: AppState) => boolean;
173
- predicate: (element: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps) => boolean;
173
+ checked: (appState: Readonly<import("../types").UIAppState>) => boolean;
174
+ predicate: (element: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: import("../types").AppState, props: import("../types").ExcalidrawProps) => boolean;
174
175
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
175
176
  } & {
176
177
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
@@ -40,7 +40,7 @@ export declare const actionToggleMidpointSnapping: {
40
40
  clip: boolean;
41
41
  };
42
42
  editingFrame: string | null;
43
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
43
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
44
44
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
45
45
  activeTool: {
46
46
  lastActiveTool: import("../types").ActiveTool | null;
@@ -60,9 +60,10 @@ export declare const actionToggleMidpointSnapping: {
60
60
  currentItemStrokeColor: string;
61
61
  currentItemBackgroundColor: string;
62
62
  currentItemFillStyle: import("@excalidraw/element/types").ExcalidrawElement["fillStyle"];
63
- currentItemStrokeWidth: number;
63
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
64
64
  currentItemStrokeStyle: import("@excalidraw/element/types").ExcalidrawElement["strokeStyle"];
65
65
  currentItemRoughness: number;
66
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
66
67
  currentItemOpacity: number;
67
68
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
68
69
  currentItemFontSize: number;
@@ -75,6 +76,7 @@ export declare const actionToggleMidpointSnapping: {
75
76
  viewBackgroundColor: string;
76
77
  scrollX: number;
77
78
  scrollY: number;
79
+ scrollConstraints: import("../types").ScrollConstraints | null;
78
80
  cursorButton: "up" | "down";
79
81
  scrolledOutside: boolean;
80
82
  name: string | null;
@@ -166,7 +168,7 @@ export declare const actionToggleMidpointSnapping: {
166
168
  };
167
169
  captureUpdate: "NEVER";
168
170
  };
169
- checked: (appState: Readonly<import("../types").AppState>) => boolean;
171
+ checked: (appState: Readonly<import("../types").UIAppState>) => boolean;
170
172
  } & {
171
173
  keyTest?: undefined;
172
174
  };