@excalidraw/math 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 (119) hide show
  1. package/dist/types/common/src/colors.d.ts +1 -1
  2. package/dist/types/common/src/constants.d.ts +9 -7
  3. package/dist/types/common/src/utils.d.ts +0 -42
  4. package/dist/types/element/src/Scene.d.ts +1 -1
  5. package/dist/types/element/src/align.d.ts +2 -2
  6. package/dist/types/element/src/binding.d.ts +6 -6
  7. package/dist/types/element/src/bounds.d.ts +19 -6
  8. package/dist/types/element/src/collision.d.ts +1 -1
  9. package/dist/types/element/src/comparisons.d.ts +1 -0
  10. package/dist/types/element/src/distribute.d.ts +2 -2
  11. package/dist/types/element/src/duplicate.d.ts +3 -3
  12. package/dist/types/element/src/embeddable.d.ts +2 -2
  13. package/dist/types/element/src/flowchart.d.ts +3 -3
  14. package/dist/types/element/src/fractionalIndex.d.ts +2 -2
  15. package/dist/types/element/src/frame.d.ts +4 -4
  16. package/dist/types/element/src/groups.d.ts +9 -9
  17. package/dist/types/element/src/index.d.ts +1 -1
  18. package/dist/types/element/src/linearElementEditor.d.ts +10 -10
  19. package/dist/types/element/src/newElement.d.ts +1 -0
  20. package/dist/types/element/src/renderElement.d.ts +0 -3
  21. package/dist/types/element/src/resizeElements.d.ts +2 -2
  22. package/dist/types/element/src/selection.d.ts +5 -5
  23. package/dist/types/element/src/textElement.d.ts +7 -7
  24. package/dist/types/element/src/transform.d.ts +2 -2
  25. package/dist/types/element/src/typeChecks.d.ts +25 -25
  26. package/dist/types/element/src/types.d.ts +8 -1
  27. package/dist/types/element/src/zindex.d.ts +2 -2
  28. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +12 -6
  29. package/dist/types/excalidraw/actions/actionAlign.d.ts +6 -6
  30. package/dist/types/excalidraw/actions/actionBoundText.d.ts +8 -4
  31. package/dist/types/excalidraw/actions/actionCanvas.d.ts +61 -389
  32. package/dist/types/excalidraw/actions/actionClipboard.d.ts +8 -4
  33. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +4 -2
  34. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +13 -7
  35. package/dist/types/excalidraw/actions/actionDeselect.d.ts +4 -2
  36. package/dist/types/excalidraw/actions/actionDistribute.d.ts +2 -3
  37. package/dist/types/excalidraw/actions/actionElementLink.d.ts +4 -2
  38. package/dist/types/excalidraw/actions/actionElementLock.d.ts +9 -5
  39. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +4 -2
  40. package/dist/types/excalidraw/actions/actionExport.d.ts +8 -4
  41. package/dist/types/excalidraw/actions/actionFrame.d.ts +29 -20
  42. package/dist/types/excalidraw/actions/actionGroup.d.ts +23 -19
  43. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +7 -4
  44. package/dist/types/excalidraw/actions/actionLink.d.ts +5 -3
  45. package/dist/types/excalidraw/actions/actionMenu.d.ts +4 -2
  46. package/dist/types/excalidraw/actions/actionProperties.d.ts +35 -22
  47. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +9 -7
  48. package/dist/types/excalidraw/actions/actionStyles.d.ts +4 -2
  49. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +5 -3
  50. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +8 -7
  51. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +5 -3
  52. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +5 -3
  53. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +8 -7
  54. package/dist/types/excalidraw/actions/actionToggleShapeSwitch.d.ts +1 -1
  55. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +5 -3
  56. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +5 -3
  57. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +5 -3
  58. package/dist/types/excalidraw/actions/index.d.ts +1 -1
  59. package/dist/types/excalidraw/actions/types.d.ts +4 -4
  60. package/dist/types/excalidraw/{animated-trail.d.ts → animatedTrail.d.ts} +4 -3
  61. package/dist/types/excalidraw/appState.d.ts +2 -1
  62. package/dist/types/excalidraw/components/Actions.d.ts +2 -3
  63. package/dist/types/excalidraw/components/ActiveConfirmDialog.d.ts +1 -1
  64. package/dist/types/excalidraw/components/App.d.ts +61 -32
  65. package/dist/types/excalidraw/components/ColorPicker/ColorPicker.d.ts +2 -2
  66. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +1 -1
  67. package/dist/types/excalidraw/components/CommandPalette/defaultCommandPaletteItems.d.ts +1 -2
  68. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +2 -2
  69. package/dist/types/excalidraw/components/CursorHint.d.ts +46 -0
  70. package/dist/types/excalidraw/components/EyeDropper.d.ts +1 -1
  71. package/dist/types/excalidraw/components/Island.d.ts +7 -0
  72. package/dist/types/excalidraw/components/LibraryMenu.d.ts +1 -1
  73. package/dist/types/excalidraw/components/OverwriteConfirm/OverwriteConfirmState.d.ts +1 -1
  74. package/dist/types/excalidraw/components/SVGLayer.d.ts +1 -1
  75. package/dist/types/excalidraw/components/SearchMenu.d.ts +1 -1
  76. package/dist/types/excalidraw/components/Sidebar/Sidebar.d.ts +1 -1
  77. package/dist/types/excalidraw/components/Stats/Angle.d.ts +2 -2
  78. package/dist/types/excalidraw/components/Stats/Dimension.d.ts +2 -2
  79. package/dist/types/excalidraw/components/Stats/DragInput.d.ts +2 -2
  80. package/dist/types/excalidraw/components/Stats/MultiAngle.d.ts +2 -2
  81. package/dist/types/excalidraw/components/Stats/MultiDimension.d.ts +2 -2
  82. package/dist/types/excalidraw/components/Stats/MultiPosition.d.ts +2 -2
  83. package/dist/types/excalidraw/components/Stats/Position.d.ts +3 -3
  84. package/dist/types/excalidraw/components/Stats/utils.d.ts +1 -1
  85. package/dist/types/excalidraw/components/TTDDialog/TTDContext.d.ts +4 -4
  86. package/dist/types/excalidraw/components/TTDDialog/useTTDChatStorage.d.ts +3 -3
  87. package/dist/types/excalidraw/components/hyperlink/helpers.d.ts +2 -2
  88. package/dist/types/excalidraw/components/icons.d.ts +2 -0
  89. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +6 -3
  90. package/dist/types/excalidraw/data/blob.d.ts +8 -4
  91. package/dist/types/excalidraw/data/index.d.ts +4 -4
  92. package/dist/types/excalidraw/data/json.d.ts +10 -8
  93. package/dist/types/excalidraw/data/library.d.ts +1 -1
  94. package/dist/types/excalidraw/eraser/index.d.ts +2 -3
  95. package/dist/types/excalidraw/hooks/useAppStateValue.d.ts +29 -0
  96. package/dist/types/excalidraw/hooks/useLibraryItemSvg.d.ts +1 -1
  97. package/dist/types/excalidraw/{laser-trails.d.ts → laserTrails.d.ts} +5 -7
  98. package/dist/types/excalidraw/lasso/index.d.ts +2 -3
  99. package/dist/types/excalidraw/renderer/animation.d.ts +5 -1
  100. package/dist/types/excalidraw/renderer/interactiveScene.d.ts +1 -3
  101. package/dist/types/excalidraw/scene/Renderer.d.ts +12 -11
  102. package/dist/types/excalidraw/scene/export.d.ts +3 -3
  103. package/dist/types/excalidraw/scene/index.d.ts +2 -2
  104. package/dist/types/excalidraw/scene/types.d.ts +1 -3
  105. package/dist/types/excalidraw/snapping.d.ts +7 -7
  106. package/dist/types/excalidraw/types.d.ts +168 -11
  107. package/dist/types/excalidraw/viewport.d.ts +316 -0
  108. package/dist/types/excalidraw/wysiwyg/textWysiwyg.d.ts +2 -3
  109. package/dist/types/laser-pointer/src/index.d.ts +2 -0
  110. package/dist/types/laser-pointer/src/math.d.ts +16 -0
  111. package/dist/types/laser-pointer/src/simplify.d.ts +2 -0
  112. package/dist/types/laser-pointer/src/state.d.ts +35 -0
  113. package/dist/types/utils/src/export.d.ts +3 -3
  114. package/dist/types/utils/src/index.d.ts +1 -2
  115. package/package.json +2 -2
  116. package/dist/types/excalidraw/animation-frame-handler.d.ts +0 -16
  117. package/dist/types/excalidraw/scene/scroll.d.ts +0 -18
  118. package/dist/types/utils/src/bbox.d.ts +0 -9
  119. package/dist/types/utils/src/withinBounds.d.ts +0 -19
@@ -1,6 +1,5 @@
1
- import { type SceneBounds } from "@excalidraw/element";
2
1
  import type { ExcalidrawElement } from "@excalidraw/element/types";
3
- import type { AppState, Offsets } from "../types";
2
+ import type { AppState } from "../types";
4
3
  export declare const actionChangeViewBackgroundColor: import("./types").Action<Partial<AppState>> & {
5
4
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
6
5
  };
@@ -85,7 +84,7 @@ export declare const actionClearCanvas: {
85
84
  midPoint?: import("@excalidraw/math").GlobalPoint;
86
85
  } | null;
87
86
  isRotating: boolean;
88
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
87
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
89
88
  collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
90
89
  snapLines: readonly import("../snapping").SnapLine[];
91
90
  zenModeEnabled: boolean;
@@ -124,9 +123,10 @@ export declare const actionClearCanvas: {
124
123
  currentItemStrokeColor: string;
125
124
  currentItemBackgroundColor: string;
126
125
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
127
- currentItemStrokeWidth: number;
126
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
128
127
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
129
128
  currentItemRoughness: number;
129
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
130
130
  currentItemOpacity: number;
131
131
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
132
132
  currentItemFontSize: number;
@@ -135,6 +135,7 @@ export declare const actionClearCanvas: {
135
135
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
136
136
  currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
137
137
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
138
+ scrollConstraints: import("../types").ScrollConstraints | null;
138
139
  cursorButton: "up" | "down";
139
140
  scrolledOutside: boolean;
140
141
  isResizing: boolean;
@@ -183,12 +184,10 @@ export declare const actionZoomIn: {
183
184
  };
184
185
  perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
185
186
  appState: {
186
- userToFollow: null;
187
+ zoom: import("../types").Zoom;
187
188
  scrollX: number;
188
189
  scrollY: number;
189
- zoom: {
190
- value: import("../types").NormalizedZoomValue;
191
- };
190
+ userToFollow: null;
192
191
  contextMenu: {
193
192
  items: import("../components/ContextMenu").ContextMenuItems;
194
193
  top: number;
@@ -221,7 +220,7 @@ export declare const actionZoomIn: {
221
220
  clip: boolean;
222
221
  };
223
222
  editingFrame: string | null;
224
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
223
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
225
224
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
226
225
  activeTool: {
227
226
  lastActiveTool: import("../types").ActiveTool | null;
@@ -241,9 +240,10 @@ export declare const actionZoomIn: {
241
240
  currentItemStrokeColor: string;
242
241
  currentItemBackgroundColor: string;
243
242
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
244
- currentItemStrokeWidth: number;
243
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
245
244
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
246
245
  currentItemRoughness: number;
246
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
247
247
  currentItemOpacity: number;
248
248
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
249
249
  currentItemFontSize: number;
@@ -254,6 +254,7 @@ export declare const actionZoomIn: {
254
254
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
255
255
  currentItemArrowType: "sharp" | "round" | "elbow";
256
256
  viewBackgroundColor: string;
257
+ scrollConstraints: import("../types").ScrollConstraints | null;
257
258
  cursorButton: "up" | "down";
258
259
  scrolledOutside: boolean;
259
260
  name: string | null;
@@ -343,7 +344,7 @@ export declare const actionZoomIn: {
343
344
  };
344
345
  captureUpdate: "EVENTUALLY";
345
346
  };
346
- PanelComponent: ({ updateData, appState }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
347
+ PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
347
348
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
348
349
  } & {
349
350
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
@@ -358,12 +359,10 @@ export declare const actionZoomOut: {
358
359
  };
359
360
  perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
360
361
  appState: {
361
- userToFollow: null;
362
+ zoom: import("../types").Zoom;
362
363
  scrollX: number;
363
364
  scrollY: number;
364
- zoom: {
365
- value: import("../types").NormalizedZoomValue;
366
- };
365
+ userToFollow: null;
367
366
  contextMenu: {
368
367
  items: import("../components/ContextMenu").ContextMenuItems;
369
368
  top: number;
@@ -396,7 +395,7 @@ export declare const actionZoomOut: {
396
395
  clip: boolean;
397
396
  };
398
397
  editingFrame: string | null;
399
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
398
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
400
399
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
401
400
  activeTool: {
402
401
  lastActiveTool: import("../types").ActiveTool | null;
@@ -416,9 +415,10 @@ export declare const actionZoomOut: {
416
415
  currentItemStrokeColor: string;
417
416
  currentItemBackgroundColor: string;
418
417
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
419
- currentItemStrokeWidth: number;
418
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
420
419
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
421
420
  currentItemRoughness: number;
421
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
422
422
  currentItemOpacity: number;
423
423
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
424
424
  currentItemFontSize: number;
@@ -429,6 +429,7 @@ export declare const actionZoomOut: {
429
429
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
430
430
  currentItemArrowType: "sharp" | "round" | "elbow";
431
431
  viewBackgroundColor: string;
432
+ scrollConstraints: import("../types").ScrollConstraints | null;
432
433
  cursorButton: "up" | "down";
433
434
  scrolledOutside: boolean;
434
435
  name: string | null;
@@ -518,7 +519,7 @@ export declare const actionZoomOut: {
518
519
  };
519
520
  captureUpdate: "EVENTUALLY";
520
521
  };
521
- PanelComponent: ({ updateData, appState }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
522
+ PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
522
523
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
523
524
  } & {
524
525
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
@@ -533,12 +534,10 @@ export declare const actionResetZoom: {
533
534
  };
534
535
  perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
535
536
  appState: {
536
- userToFollow: null;
537
+ zoom: import("../types").Zoom;
537
538
  scrollX: number;
538
539
  scrollY: number;
539
- zoom: {
540
- value: import("../types").NormalizedZoomValue;
541
- };
540
+ userToFollow: null;
542
541
  contextMenu: {
543
542
  items: import("../components/ContextMenu").ContextMenuItems;
544
543
  top: number;
@@ -571,7 +570,7 @@ export declare const actionResetZoom: {
571
570
  clip: boolean;
572
571
  };
573
572
  editingFrame: string | null;
574
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
573
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
575
574
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
576
575
  activeTool: {
577
576
  lastActiveTool: import("../types").ActiveTool | null;
@@ -591,9 +590,10 @@ export declare const actionResetZoom: {
591
590
  currentItemStrokeColor: string;
592
591
  currentItemBackgroundColor: string;
593
592
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
594
- currentItemStrokeWidth: number;
593
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
595
594
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
596
595
  currentItemRoughness: number;
596
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
597
597
  currentItemOpacity: number;
598
598
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
599
599
  currentItemFontSize: number;
@@ -604,6 +604,7 @@ export declare const actionResetZoom: {
604
604
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
605
605
  currentItemArrowType: "sharp" | "round" | "elbow";
606
606
  viewBackgroundColor: string;
607
+ scrollConstraints: import("../types").ScrollConstraints | null;
607
608
  cursorButton: "up" | "down";
608
609
  scrolledOutside: boolean;
609
610
  name: string | null;
@@ -693,355 +694,11 @@ export declare const actionResetZoom: {
693
694
  };
694
695
  captureUpdate: "EVENTUALLY";
695
696
  };
696
- PanelComponent: ({ updateData, appState }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
697
+ PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
697
698
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
698
699
  } & {
699
700
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
700
701
  };
701
- export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToViewport, viewportZoomFactor, minZoom, maxZoom, }: {
702
- bounds: SceneBounds;
703
- canvasOffsets?: Offsets;
704
- appState: Readonly<AppState>;
705
- /** whether to fit content to viewport (beyond >100%) */
706
- fitToViewport: boolean;
707
- /** zoom content to cover X of the viewport, when fitToViewport=true */
708
- viewportZoomFactor?: number;
709
- minZoom?: number;
710
- maxZoom?: number;
711
- }) => {
712
- appState: {
713
- scrollX: number;
714
- scrollY: number;
715
- zoom: {
716
- value: import("../types").NormalizedZoomValue;
717
- };
718
- contextMenu: {
719
- items: import("../components/ContextMenu").ContextMenuItems;
720
- top: number;
721
- left: number;
722
- } | null;
723
- showWelcomeScreen: boolean;
724
- isLoading: boolean;
725
- errorMessage: React.ReactNode;
726
- activeEmbeddable: {
727
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
728
- state: "hover" | "active";
729
- } | null;
730
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
731
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
732
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
733
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
734
- isBindingEnabled: boolean;
735
- boxSelectionMode: import("../types").BoxSelectionMode;
736
- bindingPreference: "enabled" | "disabled";
737
- isMidpointSnappingEnabled: boolean;
738
- suggestedBinding: {
739
- element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
740
- midPoint?: import("@excalidraw/math").GlobalPoint;
741
- } | null;
742
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
743
- frameRendering: {
744
- enabled: boolean;
745
- name: boolean;
746
- outline: boolean;
747
- clip: boolean;
748
- };
749
- editingFrame: string | null;
750
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
751
- editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
752
- activeTool: {
753
- lastActiveTool: import("../types").ActiveTool | null;
754
- locked: boolean;
755
- fromSelection: boolean;
756
- } & import("../types").ActiveTool;
757
- preferredSelectionTool: {
758
- type: "selection" | "lasso";
759
- initialized: boolean;
760
- };
761
- penMode: boolean;
762
- penDetected: boolean;
763
- exportBackground: boolean;
764
- exportEmbedScene: boolean;
765
- exportWithDarkMode: boolean;
766
- exportScale: number;
767
- currentItemStrokeColor: string;
768
- currentItemBackgroundColor: string;
769
- currentItemFillStyle: ExcalidrawElement["fillStyle"];
770
- currentItemStrokeWidth: number;
771
- currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
772
- currentItemRoughness: number;
773
- currentItemOpacity: number;
774
- currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
775
- currentItemFontSize: number;
776
- currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
777
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
778
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
779
- currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
780
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
781
- currentItemArrowType: "sharp" | "round" | "elbow";
782
- viewBackgroundColor: string;
783
- cursorButton: "up" | "down";
784
- scrolledOutside: boolean;
785
- name: string | null;
786
- isResizing: boolean;
787
- isRotating: boolean;
788
- openMenu: "canvas" | null;
789
- openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
790
- openSidebar: {
791
- name: import("../types").SidebarName;
792
- tab?: import("../types").SidebarTabName;
793
- } | null;
794
- openDialog: null | {
795
- name: "imageExport" | "help" | "jsonExport";
796
- } | {
797
- name: "ttd";
798
- tab: "text-to-diagram" | "mermaid";
799
- } | {
800
- name: "commandPalette";
801
- } | {
802
- name: "settings";
803
- } | {
804
- name: "elementLinkSelector";
805
- sourceElementId: ExcalidrawElement["id"];
806
- } | {
807
- name: "charts";
808
- data: import("../charts").Spreadsheet;
809
- rawText: string;
810
- };
811
- defaultSidebarDockedPreference: boolean;
812
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
813
- selectedElementIds: Readonly<{
814
- [id: string]: true;
815
- }>;
816
- hoveredElementIds: Readonly<{
817
- [id: string]: true;
818
- }>;
819
- previousSelectedElementIds: {
820
- [id: string]: true;
821
- };
822
- selectedElementsAreBeingDragged: boolean;
823
- shouldCacheIgnoreZoom: boolean;
824
- toast: {
825
- message: React.ReactNode;
826
- closable?: boolean;
827
- duration?: number;
828
- } | null;
829
- zenModeEnabled: boolean;
830
- theme: import("@excalidraw/element/types").Theme;
831
- gridSize: number;
832
- gridStep: number;
833
- gridModeEnabled: boolean;
834
- viewModeEnabled: boolean;
835
- selectedGroupIds: {
836
- [groupId: string]: boolean;
837
- };
838
- editingGroupId: import("@excalidraw/element/types").GroupId | null;
839
- width: number;
840
- height: number;
841
- offsetTop: number;
842
- offsetLeft: number;
843
- fileHandle: FileSystemFileHandle | null;
844
- collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
845
- stats: {
846
- open: boolean;
847
- panels: number;
848
- };
849
- showHyperlinkPopup: false | "info" | "editor";
850
- selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
851
- snapLines: readonly import("../snapping").SnapLine[];
852
- originSnapOffset: {
853
- x: number;
854
- y: number;
855
- } | null;
856
- objectsSnapModeEnabled: boolean;
857
- userToFollow: import("../types").UserToFollow | null;
858
- followedBy: Set<import("../types").SocketId>;
859
- isCropping: boolean;
860
- croppingElementId: ExcalidrawElement["id"] | null;
861
- searchMatches: Readonly<{
862
- focusedId: ExcalidrawElement["id"] | null;
863
- matches: readonly import("../types").SearchMatch[];
864
- }> | null;
865
- activeLockedId: string | null;
866
- lockedMultiSelections: {
867
- [groupId: string]: true;
868
- };
869
- bindMode: import("@excalidraw/element/types").BindMode;
870
- };
871
- captureUpdate: "EVENTUALLY";
872
- };
873
- export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitToViewport, viewportZoomFactor, minZoom, maxZoom, }: {
874
- canvasOffsets?: Offsets;
875
- targetElements: readonly ExcalidrawElement[];
876
- appState: Readonly<AppState>;
877
- /** whether to fit content to viewport (beyond >100%) */
878
- fitToViewport: boolean;
879
- /** zoom content to cover X of the viewport, when fitToViewport=true */
880
- viewportZoomFactor?: number;
881
- minZoom?: number;
882
- maxZoom?: number;
883
- }) => {
884
- appState: {
885
- scrollX: number;
886
- scrollY: number;
887
- zoom: {
888
- value: import("../types").NormalizedZoomValue;
889
- };
890
- contextMenu: {
891
- items: import("../components/ContextMenu").ContextMenuItems;
892
- top: number;
893
- left: number;
894
- } | null;
895
- showWelcomeScreen: boolean;
896
- isLoading: boolean;
897
- errorMessage: React.ReactNode;
898
- activeEmbeddable: {
899
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
900
- state: "hover" | "active";
901
- } | null;
902
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
903
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
904
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
905
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
906
- isBindingEnabled: boolean;
907
- boxSelectionMode: import("../types").BoxSelectionMode;
908
- bindingPreference: "enabled" | "disabled";
909
- isMidpointSnappingEnabled: boolean;
910
- suggestedBinding: {
911
- element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
912
- midPoint?: import("@excalidraw/math").GlobalPoint;
913
- } | null;
914
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
915
- frameRendering: {
916
- enabled: boolean;
917
- name: boolean;
918
- outline: boolean;
919
- clip: boolean;
920
- };
921
- editingFrame: string | null;
922
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
923
- editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
924
- activeTool: {
925
- lastActiveTool: import("../types").ActiveTool | null;
926
- locked: boolean;
927
- fromSelection: boolean;
928
- } & import("../types").ActiveTool;
929
- preferredSelectionTool: {
930
- type: "selection" | "lasso";
931
- initialized: boolean;
932
- };
933
- penMode: boolean;
934
- penDetected: boolean;
935
- exportBackground: boolean;
936
- exportEmbedScene: boolean;
937
- exportWithDarkMode: boolean;
938
- exportScale: number;
939
- currentItemStrokeColor: string;
940
- currentItemBackgroundColor: string;
941
- currentItemFillStyle: ExcalidrawElement["fillStyle"];
942
- currentItemStrokeWidth: number;
943
- currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
944
- currentItemRoughness: number;
945
- currentItemOpacity: number;
946
- currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
947
- currentItemFontSize: number;
948
- currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
949
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
950
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
951
- currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
952
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
953
- currentItemArrowType: "sharp" | "round" | "elbow";
954
- viewBackgroundColor: string;
955
- cursorButton: "up" | "down";
956
- scrolledOutside: boolean;
957
- name: string | null;
958
- isResizing: boolean;
959
- isRotating: boolean;
960
- openMenu: "canvas" | null;
961
- openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
962
- openSidebar: {
963
- name: import("../types").SidebarName;
964
- tab?: import("../types").SidebarTabName;
965
- } | null;
966
- openDialog: null | {
967
- name: "imageExport" | "help" | "jsonExport";
968
- } | {
969
- name: "ttd";
970
- tab: "text-to-diagram" | "mermaid";
971
- } | {
972
- name: "commandPalette";
973
- } | {
974
- name: "settings";
975
- } | {
976
- name: "elementLinkSelector";
977
- sourceElementId: ExcalidrawElement["id"];
978
- } | {
979
- name: "charts";
980
- data: import("../charts").Spreadsheet;
981
- rawText: string;
982
- };
983
- defaultSidebarDockedPreference: boolean;
984
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
985
- selectedElementIds: Readonly<{
986
- [id: string]: true;
987
- }>;
988
- hoveredElementIds: Readonly<{
989
- [id: string]: true;
990
- }>;
991
- previousSelectedElementIds: {
992
- [id: string]: true;
993
- };
994
- selectedElementsAreBeingDragged: boolean;
995
- shouldCacheIgnoreZoom: boolean;
996
- toast: {
997
- message: React.ReactNode;
998
- closable?: boolean;
999
- duration?: number;
1000
- } | null;
1001
- zenModeEnabled: boolean;
1002
- theme: import("@excalidraw/element/types").Theme;
1003
- gridSize: number;
1004
- gridStep: number;
1005
- gridModeEnabled: boolean;
1006
- viewModeEnabled: boolean;
1007
- selectedGroupIds: {
1008
- [groupId: string]: boolean;
1009
- };
1010
- editingGroupId: import("@excalidraw/element/types").GroupId | null;
1011
- width: number;
1012
- height: number;
1013
- offsetTop: number;
1014
- offsetLeft: number;
1015
- fileHandle: FileSystemFileHandle | null;
1016
- collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
1017
- stats: {
1018
- open: boolean;
1019
- panels: number;
1020
- };
1021
- showHyperlinkPopup: false | "info" | "editor";
1022
- selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1023
- snapLines: readonly import("../snapping").SnapLine[];
1024
- originSnapOffset: {
1025
- x: number;
1026
- y: number;
1027
- } | null;
1028
- objectsSnapModeEnabled: boolean;
1029
- userToFollow: import("../types").UserToFollow | null;
1030
- followedBy: Set<import("../types").SocketId>;
1031
- isCropping: boolean;
1032
- croppingElementId: ExcalidrawElement["id"] | null;
1033
- searchMatches: Readonly<{
1034
- focusedId: ExcalidrawElement["id"] | null;
1035
- matches: readonly import("../types").SearchMatch[];
1036
- }> | null;
1037
- activeLockedId: string | null;
1038
- lockedMultiSelections: {
1039
- [groupId: string]: true;
1040
- };
1041
- bindMode: import("@excalidraw/element/types").BindMode;
1042
- };
1043
- captureUpdate: "EVENTUALLY";
1044
- };
1045
702
  export declare const actionZoomToFitSelectionInViewport: {
1046
703
  name: "zoomToFitSelectionInViewport";
1047
704
  label: string;
@@ -1049,6 +706,7 @@ export declare const actionZoomToFitSelectionInViewport: {
1049
706
  trackEvent: {
1050
707
  category: "canvas";
1051
708
  };
709
+ predicate: (elements: readonly ExcalidrawElement[], appState: AppState) => boolean;
1052
710
  perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1053
711
  appState: {
1054
712
  scrollX: number;
@@ -1088,7 +746,7 @@ export declare const actionZoomToFitSelectionInViewport: {
1088
746
  clip: boolean;
1089
747
  };
1090
748
  editingFrame: string | null;
1091
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
749
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1092
750
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1093
751
  activeTool: {
1094
752
  lastActiveTool: import("../types").ActiveTool | null;
@@ -1108,9 +766,10 @@ export declare const actionZoomToFitSelectionInViewport: {
1108
766
  currentItemStrokeColor: string;
1109
767
  currentItemBackgroundColor: string;
1110
768
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1111
- currentItemStrokeWidth: number;
769
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1112
770
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1113
771
  currentItemRoughness: number;
772
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1114
773
  currentItemOpacity: number;
1115
774
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1116
775
  currentItemFontSize: number;
@@ -1121,6 +780,7 @@ export declare const actionZoomToFitSelectionInViewport: {
1121
780
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1122
781
  currentItemArrowType: "sharp" | "round" | "elbow";
1123
782
  viewBackgroundColor: string;
783
+ scrollConstraints: import("../types").ScrollConstraints | null;
1124
784
  cursorButton: "up" | "down";
1125
785
  scrolledOutside: boolean;
1126
786
  name: string | null;
@@ -1211,9 +871,9 @@ export declare const actionZoomToFitSelectionInViewport: {
1211
871
  };
1212
872
  captureUpdate: "EVENTUALLY";
1213
873
  };
1214
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
874
+ keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean;
1215
875
  } & {
1216
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
876
+ keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean) | undefined;
1217
877
  };
1218
878
  export declare const actionZoomToFitSelection: {
1219
879
  name: "zoomToFitSelection";
@@ -1222,6 +882,7 @@ export declare const actionZoomToFitSelection: {
1222
882
  trackEvent: {
1223
883
  category: "canvas";
1224
884
  };
885
+ predicate: (elements: readonly ExcalidrawElement[], appState: AppState) => boolean;
1225
886
  perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1226
887
  appState: {
1227
888
  scrollX: number;
@@ -1261,7 +922,7 @@ export declare const actionZoomToFitSelection: {
1261
922
  clip: boolean;
1262
923
  };
1263
924
  editingFrame: string | null;
1264
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
925
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1265
926
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1266
927
  activeTool: {
1267
928
  lastActiveTool: import("../types").ActiveTool | null;
@@ -1281,9 +942,10 @@ export declare const actionZoomToFitSelection: {
1281
942
  currentItemStrokeColor: string;
1282
943
  currentItemBackgroundColor: string;
1283
944
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1284
- currentItemStrokeWidth: number;
945
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1285
946
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1286
947
  currentItemRoughness: number;
948
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1287
949
  currentItemOpacity: number;
1288
950
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1289
951
  currentItemFontSize: number;
@@ -1294,6 +956,7 @@ export declare const actionZoomToFitSelection: {
1294
956
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1295
957
  currentItemArrowType: "sharp" | "round" | "elbow";
1296
958
  viewBackgroundColor: string;
959
+ scrollConstraints: import("../types").ScrollConstraints | null;
1297
960
  cursorButton: "up" | "down";
1298
961
  scrolledOutside: boolean;
1299
962
  name: string | null;
@@ -1384,9 +1047,9 @@ export declare const actionZoomToFitSelection: {
1384
1047
  };
1385
1048
  captureUpdate: "EVENTUALLY";
1386
1049
  };
1387
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1050
+ keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean;
1388
1051
  } & {
1389
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1052
+ keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean) | undefined;
1390
1053
  };
1391
1054
  export declare const actionZoomToFit: {
1392
1055
  name: "zoomToFit";
@@ -1396,6 +1059,7 @@ export declare const actionZoomToFit: {
1396
1059
  trackEvent: {
1397
1060
  category: "canvas";
1398
1061
  };
1062
+ predicate: (elements: readonly ExcalidrawElement[], appState: AppState) => boolean;
1399
1063
  perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1400
1064
  appState: {
1401
1065
  scrollX: number;
@@ -1435,7 +1099,7 @@ export declare const actionZoomToFit: {
1435
1099
  clip: boolean;
1436
1100
  };
1437
1101
  editingFrame: string | null;
1438
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1102
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1439
1103
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1440
1104
  activeTool: {
1441
1105
  lastActiveTool: import("../types").ActiveTool | null;
@@ -1455,9 +1119,10 @@ export declare const actionZoomToFit: {
1455
1119
  currentItemStrokeColor: string;
1456
1120
  currentItemBackgroundColor: string;
1457
1121
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1458
- currentItemStrokeWidth: number;
1122
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1459
1123
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1460
1124
  currentItemRoughness: number;
1125
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1461
1126
  currentItemOpacity: number;
1462
1127
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1463
1128
  currentItemFontSize: number;
@@ -1468,6 +1133,7 @@ export declare const actionZoomToFit: {
1468
1133
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1469
1134
  currentItemArrowType: "sharp" | "round" | "elbow";
1470
1135
  viewBackgroundColor: string;
1136
+ scrollConstraints: import("../types").ScrollConstraints | null;
1471
1137
  cursorButton: "up" | "down";
1472
1138
  scrolledOutside: boolean;
1473
1139
  name: string | null;
@@ -1558,9 +1224,9 @@ export declare const actionZoomToFit: {
1558
1224
  };
1559
1225
  captureUpdate: "EVENTUALLY";
1560
1226
  };
1561
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1227
+ keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean;
1562
1228
  } & {
1563
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1229
+ keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean) | undefined;
1564
1230
  };
1565
1231
  export declare const actionToggleTheme: import("./types").Action<import("@excalidraw/element/types").Theme> & {
1566
1232
  keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
@@ -1609,7 +1275,7 @@ export declare const actionToggleEraserTool: {
1609
1275
  clip: boolean;
1610
1276
  };
1611
1277
  editingFrame: string | null;
1612
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1278
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1613
1279
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1614
1280
  preferredSelectionTool: {
1615
1281
  type: "selection" | "lasso";
@@ -1624,9 +1290,10 @@ export declare const actionToggleEraserTool: {
1624
1290
  currentItemStrokeColor: string;
1625
1291
  currentItemBackgroundColor: string;
1626
1292
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1627
- currentItemStrokeWidth: number;
1293
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1628
1294
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1629
1295
  currentItemRoughness: number;
1296
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1630
1297
  currentItemOpacity: number;
1631
1298
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1632
1299
  currentItemFontSize: number;
@@ -1639,6 +1306,7 @@ export declare const actionToggleEraserTool: {
1639
1306
  viewBackgroundColor: string;
1640
1307
  scrollX: number;
1641
1308
  scrollY: number;
1309
+ scrollConstraints: import("../types").ScrollConstraints | null;
1642
1310
  cursorButton: "up" | "down";
1643
1311
  scrolledOutside: boolean;
1644
1312
  name: string | null;
@@ -1724,9 +1392,9 @@ export declare const actionToggleEraserTool: {
1724
1392
  };
1725
1393
  captureUpdate: "IMMEDIATELY";
1726
1394
  };
1727
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1395
+ keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean;
1728
1396
  } & {
1729
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1397
+ keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState) => boolean) | undefined;
1730
1398
  };
1731
1399
  export declare const actionToggleLassoTool: {
1732
1400
  name: "toggleLassoTool";
@@ -1774,7 +1442,7 @@ export declare const actionToggleLassoTool: {
1774
1442
  clip: boolean;
1775
1443
  };
1776
1444
  editingFrame: string | null;
1777
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1445
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1778
1446
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1779
1447
  preferredSelectionTool: {
1780
1448
  type: "selection" | "lasso";
@@ -1789,9 +1457,10 @@ export declare const actionToggleLassoTool: {
1789
1457
  currentItemStrokeColor: string;
1790
1458
  currentItemBackgroundColor: string;
1791
1459
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1792
- currentItemStrokeWidth: number;
1460
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1793
1461
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1794
1462
  currentItemRoughness: number;
1463
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1795
1464
  currentItemOpacity: number;
1796
1465
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1797
1466
  currentItemFontSize: number;
@@ -1804,6 +1473,7 @@ export declare const actionToggleLassoTool: {
1804
1473
  viewBackgroundColor: string;
1805
1474
  scrollX: number;
1806
1475
  scrollY: number;
1476
+ scrollConstraints: import("../types").ScrollConstraints | null;
1807
1477
  cursorButton: "up" | "down";
1808
1478
  scrolledOutside: boolean;
1809
1479
  name: string | null;
@@ -1938,7 +1608,7 @@ export declare const actionToggleHandTool: {
1938
1608
  clip: boolean;
1939
1609
  };
1940
1610
  editingFrame: string | null;
1941
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1611
+ elementsToHighlight: readonly import("@excalidraw/element/types").NonDeletedExcalidrawElement[] | null;
1942
1612
  editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1943
1613
  preferredSelectionTool: {
1944
1614
  type: "selection" | "lasso";
@@ -1953,9 +1623,10 @@ export declare const actionToggleHandTool: {
1953
1623
  currentItemStrokeColor: string;
1954
1624
  currentItemBackgroundColor: string;
1955
1625
  currentItemFillStyle: ExcalidrawElement["fillStyle"];
1956
- currentItemStrokeWidth: number;
1626
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
1957
1627
  currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1958
1628
  currentItemRoughness: number;
1629
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
1959
1630
  currentItemOpacity: number;
1960
1631
  currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1961
1632
  currentItemFontSize: number;
@@ -1968,6 +1639,7 @@ export declare const actionToggleHandTool: {
1968
1639
  viewBackgroundColor: string;
1969
1640
  scrollX: number;
1970
1641
  scrollY: number;
1642
+ scrollConstraints: import("../types").ScrollConstraints | null;
1971
1643
  cursorButton: "up" | "down";
1972
1644
  scrolledOutside: boolean;
1973
1645
  name: string | null;