@excalidraw/math 0.18.0-ac0d305 → 0.18.0-b1c6bfc

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 (268) hide show
  1. package/dist/dev/index.js +80 -65
  2. package/dist/dev/index.js.map +3 -3
  3. package/dist/prod/index.js +1 -1
  4. package/dist/types/common/debug.d.ts +21 -0
  5. package/dist/types/common/src/appEventBus.d.ts +27 -0
  6. package/dist/types/common/src/bounds.d.ts +10 -0
  7. package/dist/types/common/src/colors.d.ts +59 -39
  8. package/dist/types/common/src/constants.d.ts +25 -27
  9. package/dist/types/common/src/editorInterface.d.ts +34 -0
  10. package/dist/types/common/src/font-metadata.d.ts +1 -3
  11. package/dist/types/common/src/index.d.ts +5 -0
  12. package/dist/types/common/src/keys.d.ts +1 -1
  13. package/dist/types/common/src/utility-types.d.ts +0 -1
  14. package/dist/types/common/src/utils.d.ts +53 -42
  15. package/dist/types/common/src/versionedSnapshotStore.d.ts +17 -0
  16. package/dist/types/element/src/Scene.d.ts +5 -3
  17. package/dist/types/element/src/arrowheads.d.ts +3 -0
  18. package/dist/types/element/src/arrows/focus.d.ts +27 -0
  19. package/dist/types/element/src/arrows/helpers.d.ts +5 -0
  20. package/dist/types/element/src/binding.d.ts +67 -48
  21. package/dist/types/element/src/bounds.d.ts +7 -13
  22. package/dist/types/element/src/collision.d.ts +7 -2
  23. package/dist/types/element/src/comparisons.d.ts +7 -7
  24. package/dist/types/element/src/distribute.d.ts +2 -1
  25. package/dist/types/element/src/dragElements.d.ts +3 -3
  26. package/dist/types/element/src/duplicate.d.ts +3 -3
  27. package/dist/types/element/src/elbowArrow.d.ts +2 -0
  28. package/dist/types/element/src/fractionalIndex.d.ts +2 -2
  29. package/dist/types/element/src/frame.d.ts +6 -2
  30. package/dist/types/element/src/heading.d.ts +2 -1
  31. package/dist/types/element/src/image.d.ts +1 -11
  32. package/dist/types/element/src/index.d.ts +4 -3
  33. package/dist/types/element/src/linearElementEditor.d.ts +23 -22
  34. package/dist/types/element/src/mutateElement.d.ts +5 -1
  35. package/dist/types/element/src/newElement.d.ts +6 -6
  36. package/dist/types/element/src/renderElement.d.ts +1 -7
  37. package/dist/types/element/src/resizeElements.d.ts +10 -10
  38. package/dist/types/element/src/resizeTest.d.ts +6 -5
  39. package/dist/types/element/src/selection.d.ts +10 -10
  40. package/dist/types/element/src/shape.d.ts +9 -8
  41. package/dist/types/element/src/textElement.d.ts +1 -1
  42. package/dist/types/element/src/textMeasurements.d.ts +1 -3
  43. package/dist/types/element/src/textWrapping.d.ts +26 -0
  44. package/dist/types/{excalidraw/data → element/src}/transform.d.ts +3 -3
  45. package/dist/types/element/src/transformHandles.d.ts +8 -27
  46. package/dist/types/element/src/typeChecks.d.ts +4 -7
  47. package/dist/types/element/src/types.d.ts +12 -13
  48. package/dist/types/element/src/utils.d.ts +9 -4
  49. package/dist/types/element/src/zindex.d.ts +7 -1
  50. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +170 -210
  51. package/dist/types/excalidraw/actions/actionAlign.d.ts +6 -7
  52. package/dist/types/excalidraw/actions/actionBoundText.d.ts +94 -121
  53. package/dist/types/excalidraw/actions/actionCanvas.d.ts +556 -902
  54. package/dist/types/excalidraw/actions/actionClipboard.d.ts +125 -897
  55. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +45 -59
  56. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +148 -192
  57. package/dist/types/excalidraw/actions/actionDeselect.d.ts +160 -0
  58. package/dist/types/excalidraw/actions/actionDistribute.d.ts +2 -3
  59. package/dist/types/excalidraw/actions/actionDuplicateSelection.d.ts +3 -4
  60. package/dist/types/excalidraw/actions/actionElementLink.d.ts +54 -74
  61. package/dist/types/excalidraw/actions/actionElementLock.d.ts +92 -119
  62. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +60 -74
  63. package/dist/types/excalidraw/actions/actionExport.d.ts +173 -1412
  64. package/dist/types/excalidraw/actions/actionFinalize.d.ts +10 -396
  65. package/dist/types/excalidraw/actions/actionFlip.d.ts +2 -3
  66. package/dist/types/excalidraw/actions/actionFrame.d.ts +265 -356
  67. package/dist/types/excalidraw/actions/actionGroup.d.ts +97 -132
  68. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +137 -189
  69. package/dist/types/excalidraw/actions/actionLink.d.ts +60 -74
  70. package/dist/types/excalidraw/actions/actionMenu.d.ts +49 -437
  71. package/dist/types/excalidraw/actions/actionNavigate.d.ts +18 -361
  72. package/dist/types/excalidraw/actions/actionProperties.d.ts +154 -2533
  73. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +48 -66
  74. package/dist/types/excalidraw/actions/actionStyles.d.ts +45 -58
  75. package/dist/types/excalidraw/actions/actionTextAutoResize.d.ts +4 -4
  76. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +173 -0
  77. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +60 -74
  78. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +173 -0
  79. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +60 -74
  80. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +48 -68
  81. package/dist/types/excalidraw/actions/actionToggleShapeSwitch.d.ts +1 -1
  82. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +59 -73
  83. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +60 -74
  84. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +60 -74
  85. package/dist/types/excalidraw/actions/actionZindex.d.ts +8 -9
  86. package/dist/types/excalidraw/actions/index.d.ts +4 -1
  87. package/dist/types/excalidraw/actions/register.d.ts +2 -2
  88. package/dist/types/excalidraw/actions/shortcuts.d.ts +1 -1
  89. package/dist/types/excalidraw/actions/types.d.ts +4 -4
  90. package/dist/types/excalidraw/appState.d.ts +29 -22
  91. package/dist/types/excalidraw/charts/charts.bar.d.ts +2 -0
  92. package/dist/types/excalidraw/charts/charts.constants.d.ts +48 -0
  93. package/dist/types/excalidraw/charts/charts.helpers.d.ts +32 -0
  94. package/dist/types/excalidraw/charts/charts.line.d.ts +2 -0
  95. package/dist/types/excalidraw/charts/charts.parse.d.ts +10 -0
  96. package/dist/types/excalidraw/charts/charts.radar.d.ts +2 -0
  97. package/dist/types/excalidraw/charts/charts.types.d.ts +18 -0
  98. package/dist/types/excalidraw/charts/index.d.ts +7 -0
  99. package/dist/types/excalidraw/clipboard.d.ts +13 -36
  100. package/dist/types/excalidraw/components/Actions.d.ts +14 -4
  101. package/dist/types/excalidraw/components/App.d.ts +109 -70
  102. package/dist/types/excalidraw/components/AppStateObserver.d.ts +37 -0
  103. package/dist/types/excalidraw/components/Card.d.ts +1 -3
  104. package/dist/types/excalidraw/components/ColorPicker/ColorInput.d.ts +2 -4
  105. package/dist/types/excalidraw/components/ColorPicker/ColorPicker.d.ts +1 -3
  106. package/dist/types/excalidraw/components/ColorPicker/Picker.d.ts +2 -0
  107. package/dist/types/excalidraw/components/ColorPicker/PickerColorList.d.ts +2 -1
  108. package/dist/types/excalidraw/components/ColorPicker/ShadeList.d.ts +2 -1
  109. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +0 -1
  110. package/dist/types/excalidraw/components/ColorPicker/keyboardNavHandlers.d.ts +0 -1
  111. package/dist/types/excalidraw/components/CommandPalette/CommandPalette.d.ts +1 -0
  112. package/dist/types/excalidraw/components/CommandPalette/types.d.ts +2 -4
  113. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +2 -2
  114. package/dist/types/excalidraw/components/DarkModeToggle.d.ts +1 -1
  115. package/dist/types/excalidraw/components/DefaultSidebar.d.ts +9 -13
  116. package/dist/types/excalidraw/components/ElementLinkDialog.d.ts +1 -1
  117. package/dist/types/excalidraw/components/Ellipsify.d.ts +1 -2
  118. package/dist/types/excalidraw/components/ErrorDialog.d.ts +1 -1
  119. package/dist/types/excalidraw/components/EyeDropper.d.ts +0 -1
  120. package/dist/types/excalidraw/components/FilledButton.d.ts +2 -1
  121. package/dist/types/excalidraw/components/FontPicker/FontPickerTrigger.d.ts +2 -1
  122. package/dist/types/excalidraw/components/FontPicker/keyboardNavHandlers.d.ts +0 -1
  123. package/dist/types/excalidraw/components/HelpDialog.d.ts +1 -1
  124. package/dist/types/excalidraw/components/HintViewer.d.ts +4 -3
  125. package/dist/types/excalidraw/components/IconPicker.d.ts +14 -9
  126. package/dist/types/excalidraw/components/InlineIcon.d.ts +3 -1
  127. package/dist/types/excalidraw/components/LayerUI.d.ts +2 -1
  128. package/dist/types/excalidraw/components/LibraryMenuControlButtons.d.ts +1 -1
  129. package/dist/types/excalidraw/components/LibraryMenuHeaderContent.d.ts +1 -2
  130. package/dist/types/excalidraw/components/LibraryMenuSection.d.ts +1 -1
  131. package/dist/types/excalidraw/components/LibraryUnit.d.ts +2 -3
  132. package/dist/types/excalidraw/components/LoadingMessage.d.ts +0 -1
  133. package/dist/types/excalidraw/components/MobileMenu.d.ts +3 -5
  134. package/dist/types/excalidraw/components/MobileToolBar.d.ts +10 -0
  135. package/dist/types/excalidraw/components/Modal.d.ts +0 -1
  136. package/dist/types/excalidraw/components/OverwriteConfirm/OverwriteConfirm.d.ts +1 -1
  137. package/dist/types/excalidraw/components/PasteChartDialog.d.ts +4 -5
  138. package/dist/types/excalidraw/components/Popover.d.ts +2 -1
  139. package/dist/types/excalidraw/components/PropertiesPopover.d.ts +1 -1
  140. package/dist/types/excalidraw/components/RadioGroup.d.ts +0 -1
  141. package/dist/types/excalidraw/components/RadioSelection.d.ts +4 -4
  142. package/dist/types/excalidraw/components/Range.d.ts +10 -4
  143. package/dist/types/excalidraw/components/ScrollableList.d.ts +0 -1
  144. package/dist/types/excalidraw/components/Sidebar/Sidebar.d.ts +15 -21
  145. package/dist/types/excalidraw/components/Sidebar/SidebarHeader.d.ts +1 -1
  146. package/dist/types/excalidraw/components/Sidebar/SidebarTab.d.ts +1 -2
  147. package/dist/types/excalidraw/components/Sidebar/SidebarTabTrigger.d.ts +1 -2
  148. package/dist/types/excalidraw/components/Sidebar/SidebarTabTriggers.d.ts +1 -2
  149. package/dist/types/excalidraw/components/Sidebar/SidebarTabs.d.ts +1 -2
  150. package/dist/types/excalidraw/components/Spinner.d.ts +4 -4
  151. package/dist/types/excalidraw/components/Stats/CanvasGrid.d.ts +0 -1
  152. package/dist/types/excalidraw/components/Stats/Collapsible.d.ts +0 -1
  153. package/dist/types/excalidraw/components/Stats/DragInput.d.ts +0 -1
  154. package/dist/types/excalidraw/components/Stats/index.d.ts +7 -8
  155. package/dist/types/excalidraw/components/Stats/utils.d.ts +1 -1
  156. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatHistoryMenu.d.ts +15 -0
  157. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatInterface.d.ts +23 -0
  158. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatMessage.d.ts +14 -0
  159. package/dist/types/excalidraw/components/TTDDialog/Chat/TTDChatPanel.d.ts +27 -0
  160. package/dist/types/excalidraw/components/TTDDialog/Chat/index.d.ts +3 -0
  161. package/dist/types/excalidraw/components/TTDDialog/Chat/useChatAgent.d.ts +8 -0
  162. package/dist/types/excalidraw/components/TTDDialog/CodeMirrorEditor.d.ts +11 -0
  163. package/dist/types/excalidraw/components/TTDDialog/MermaidToExcalidraw.d.ts +3 -2
  164. package/dist/types/excalidraw/components/TTDDialog/TTDContext.d.ts +13 -0
  165. package/dist/types/excalidraw/components/TTDDialog/TTDDialog.d.ts +12 -29
  166. package/dist/types/excalidraw/components/TTDDialog/TTDDialogInput.d.ts +3 -3
  167. package/dist/types/excalidraw/components/TTDDialog/TTDDialogOutput.d.ts +5 -2
  168. package/dist/types/excalidraw/components/TTDDialog/TTDDialogPanel.d.ts +13 -9
  169. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTab.d.ts +1 -2
  170. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTabTrigger.d.ts +1 -2
  171. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTabTriggers.d.ts +1 -2
  172. package/dist/types/excalidraw/components/TTDDialog/TTDPreviewPanel.d.ts +9 -0
  173. package/dist/types/excalidraw/components/TTDDialog/TTDWelcomeMessage.d.ts +1 -0
  174. package/dist/types/excalidraw/components/TTDDialog/TextToDiagram.d.ts +9 -0
  175. package/dist/types/excalidraw/components/TTDDialog/common.d.ts +16 -16
  176. package/dist/types/excalidraw/components/TTDDialog/hooks/useChatManagement.d.ts +13 -0
  177. package/dist/types/excalidraw/components/TTDDialog/hooks/useMermaidRenderer.d.ts +14 -0
  178. package/dist/types/excalidraw/components/TTDDialog/hooks/useTextGeneration.d.ts +7 -0
  179. package/dist/types/excalidraw/components/TTDDialog/mermaid-lang-lite.d.ts +2 -0
  180. package/dist/types/excalidraw/components/TTDDialog/types.d.ts +95 -0
  181. package/dist/types/excalidraw/components/TTDDialog/useTTDChatStorage.d.ts +22 -0
  182. package/dist/types/excalidraw/components/TTDDialog/utils/chat.d.ts +10 -0
  183. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidAutoFix.d.ts +1 -0
  184. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidError.d.ts +10 -0
  185. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidValidation.d.ts +1 -0
  186. package/dist/types/excalidraw/components/TextField.d.ts +1 -0
  187. package/dist/types/excalidraw/components/Toast.d.ts +11 -7
  188. package/dist/types/excalidraw/components/ToolPopover.d.ts +25 -0
  189. package/dist/types/excalidraw/components/Trans.d.ts +2 -2
  190. package/dist/types/excalidraw/components/canvases/InteractiveCanvas.d.ts +7 -3
  191. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenu.d.ts +47 -35
  192. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuContent.d.ts +7 -5
  193. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuGroup.d.ts +3 -3
  194. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItem.d.ts +13 -22
  195. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCheckbox.d.ts +5 -0
  196. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContent.d.ts +5 -4
  197. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContentRadio.d.ts +2 -2
  198. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCustom.d.ts +2 -2
  199. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemLink.d.ts +6 -6
  200. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSub.d.ts +23 -0
  201. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubContent.d.ts +8 -0
  202. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubTrigger.d.ts +12 -0
  203. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuTrigger.d.ts +3 -4
  204. package/dist/types/excalidraw/components/dropdownMenu/common.d.ts +2 -2
  205. package/dist/types/excalidraw/components/dropdownMenu/dropdownMenuUtils.d.ts +2 -0
  206. package/dist/types/excalidraw/components/hoc/withInternalFallback.d.ts +1 -1
  207. package/dist/types/excalidraw/components/hyperlink/helpers.d.ts +1 -1
  208. package/dist/types/excalidraw/components/icons.d.ts +44 -22
  209. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +20 -2
  210. package/dist/types/excalidraw/components/main-menu/MainMenu.d.ts +39 -35
  211. package/dist/types/excalidraw/components/shapes.d.ts +74 -1
  212. package/dist/types/excalidraw/data/blob.d.ts +329 -8
  213. package/dist/types/excalidraw/data/encode.d.ts +4 -4
  214. package/dist/types/excalidraw/data/encryption.d.ts +5 -5
  215. package/dist/types/excalidraw/data/filesystem.d.ts +5 -7
  216. package/dist/types/excalidraw/data/index.d.ts +4 -5
  217. package/dist/types/excalidraw/data/json.d.ts +171 -4
  218. package/dist/types/excalidraw/data/library.d.ts +24 -9
  219. package/dist/types/excalidraw/data/resave.d.ts +7 -2
  220. package/dist/types/excalidraw/data/restore.d.ts +25 -10
  221. package/dist/types/excalidraw/data/types.d.ts +4 -1
  222. package/dist/types/excalidraw/editor-jotai.d.ts +11 -11
  223. package/dist/types/excalidraw/errors.d.ts +14 -0
  224. package/dist/types/excalidraw/hooks/useLibraryItemSvg.d.ts +1 -1
  225. package/dist/types/excalidraw/hooks/useOutsideClick.d.ts +4 -3
  226. package/dist/types/excalidraw/hooks/useScrollPosition.d.ts +1 -2
  227. package/dist/types/excalidraw/i18n.d.ts +2 -2
  228. package/dist/types/excalidraw/renderer/animation.d.ts +12 -0
  229. package/dist/types/excalidraw/renderer/helpers.d.ts +6 -8
  230. package/dist/types/excalidraw/renderer/interactiveScene.d.ts +8 -14
  231. package/dist/types/excalidraw/scene/Renderer.d.ts +5 -2
  232. package/dist/types/excalidraw/scene/export.d.ts +2 -2
  233. package/dist/types/excalidraw/scene/scroll.d.ts +1 -6
  234. package/dist/types/excalidraw/scene/types.d.ts +22 -5
  235. package/dist/types/excalidraw/shortcut.d.ts +1 -0
  236. package/dist/types/excalidraw/snapping.d.ts +5 -5
  237. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-bindings.d.ts +1 -1
  238. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-loader.d.ts +1 -1
  239. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-wasm.d.ts +1 -1
  240. package/dist/types/excalidraw/subset/woff2/woff2-loader.d.ts +2 -2
  241. package/dist/types/excalidraw/subset/woff2/woff2-wasm.d.ts +1 -1
  242. package/dist/types/excalidraw/textAutoResizeHandle.d.ts +15 -0
  243. package/dist/types/excalidraw/types.d.ts +123 -36
  244. package/dist/types/excalidraw/wysiwyg/textWysiwyg.d.ts +7 -3
  245. package/dist/types/math/src/curve.d.ts +4 -1
  246. package/dist/types/math/src/point.d.ts +7 -2
  247. package/dist/types/math/src/polygon.d.ts +2 -2
  248. package/dist/types/math/src/range.d.ts +1 -3
  249. package/dist/types/math/src/segment.d.ts +3 -3
  250. package/dist/types/math/src/types.d.ts +25 -1
  251. package/dist/types/utils/src/bbox.d.ts +1 -1
  252. package/dist/types/utils/src/export.d.ts +5 -5
  253. package/dist/types/utils/src/shape.d.ts +6 -6
  254. package/dist/types/utils/src/withinBounds.d.ts +2 -2
  255. package/package.json +2 -2
  256. package/dist/types/excalidraw/charts.d.ts +0 -27
  257. package/dist/types/excalidraw/components/DiagramToCodePlugin/DiagramToCodePlugin.d.ts +0 -4
  258. package/dist/types/excalidraw/components/ExcalidrawLogo.d.ts +0 -16
  259. package/dist/types/excalidraw/components/InitializeApp.d.ts +0 -10
  260. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTrigger.d.ts +0 -9
  261. package/dist/types/excalidraw/components/footer/FooterCenter.d.ts +0 -8
  262. package/dist/types/excalidraw/components/live-collaboration/LiveCollaborationTrigger.d.ts +0 -10
  263. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.Center.d.ts +0 -58
  264. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.Hints.d.ts +0 -19
  265. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.d.ts +0 -85
  266. package/dist/types/excalidraw/data/reconcile.d.ts +0 -7
  267. package/dist/types/excalidraw/index.d.ts +0 -47
  268. package/dist/types/excalidraw/polyfill.d.ts +0 -2
@@ -1,19 +1,8 @@
1
- /// <reference types="react" />
2
1
  import { type SceneBounds } from "@excalidraw/element";
3
2
  import type { ExcalidrawElement } from "@excalidraw/element/types";
4
3
  import type { AppState, Offsets } from "../types";
5
- export declare const actionChangeViewBackgroundColor: {
6
- name: "changeViewBackgroundColor";
7
- label: string;
8
- trackEvent: false;
9
- predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
10
- perform: (_: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: any) => {
11
- appState: any;
12
- captureUpdate: "IMMEDIATELY" | "EVENTUALLY";
13
- };
14
- PanelComponent: ({ elements, appState, updateData, appProps, data }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
15
- } & {
16
- keyTest?: undefined;
4
+ export declare const actionChangeViewBackgroundColor: import("./types").Action<Partial<AppState>> & {
5
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
17
6
  };
18
7
  export declare const actionClearCanvas: {
19
8
  name: "clearCanvas";
@@ -23,7 +12,7 @@ export declare const actionClearCanvas: {
23
12
  category: "canvas";
24
13
  };
25
14
  predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
26
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
15
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
27
16
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
28
17
  appState: {
29
18
  files: {};
@@ -39,13 +28,6 @@ export declare const actionClearCanvas: {
39
28
  open: boolean;
40
29
  panels: number;
41
30
  };
42
- pasteDialog: {
43
- shown: false;
44
- data: null;
45
- } | {
46
- shown: true;
47
- data: import("../charts").Spreadsheet;
48
- };
49
31
  activeTool: {
50
32
  lastActiveTool: import("../types").ActiveTool | null;
51
33
  locked: boolean;
@@ -59,31 +41,35 @@ export declare const actionClearCanvas: {
59
41
  clip: boolean;
60
42
  };
61
43
  name: string | null;
62
- zoom: Readonly<{
63
- value: import("../types").NormalizedZoomValue;
64
- }>;
44
+ zoom: import("../types").Zoom;
65
45
  scrollX: number;
66
46
  scrollY: number;
67
47
  viewModeEnabled: boolean;
68
- openDialog: {
48
+ openDialog: null | {
69
49
  name: "imageExport" | "help" | "jsonExport";
70
50
  } | {
71
51
  name: "ttd";
72
- tab: "mermaid" | "text-to-diagram";
52
+ tab: "text-to-diagram" | "mermaid";
73
53
  } | {
74
54
  name: "commandPalette";
55
+ } | {
56
+ name: "settings";
75
57
  } | {
76
58
  name: "elementLinkSelector";
77
- sourceElementId: string;
78
- } | null;
79
- editingGroupId: string | null;
59
+ sourceElementId: ExcalidrawElement["id"];
60
+ } | {
61
+ name: "charts";
62
+ data: import("../charts").Spreadsheet;
63
+ rawText: string;
64
+ };
65
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
80
66
  selectedElementIds: Readonly<{
81
67
  [id: string]: true;
82
68
  }>;
83
69
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
84
70
  activeEmbeddable: {
85
71
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
86
- state: "active" | "hover";
72
+ state: "hover" | "active";
87
73
  } | null;
88
74
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
89
75
  selectedGroupIds: {
@@ -91,40 +77,33 @@ export declare const actionClearCanvas: {
91
77
  };
92
78
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
93
79
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
80
+ newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
94
81
  isBindingEnabled: boolean;
95
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
82
+ isMidpointSnappingEnabled: boolean;
83
+ suggestedBinding: {
84
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
85
+ midPoint?: import("@excalidraw/math").GlobalPoint;
86
+ } | null;
96
87
  isRotating: boolean;
97
88
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
98
- collaborators: Map<import("../types").SocketId, Readonly<{
99
- pointer?: import("../types").CollaboratorPointer | undefined;
100
- button?: "up" | "down" | undefined;
101
- selectedElementIds?: Readonly<{
102
- [id: string]: true;
103
- }> | undefined;
104
- username?: string | null | undefined;
105
- userState?: import("@excalidraw/common").UserIdleState | undefined;
106
- color?: {
107
- background: string;
108
- stroke: string;
109
- } | undefined;
110
- avatarUrl?: string | undefined;
111
- id?: string | undefined;
112
- socketId?: import("../types").SocketId | undefined;
113
- isCurrentUser?: boolean | undefined;
114
- isInCall?: boolean | undefined;
115
- isSpeaking?: boolean | undefined;
116
- isMuted?: boolean | undefined;
117
- }>>;
89
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
118
90
  snapLines: readonly import("../snapping").SnapLine[];
119
91
  zenModeEnabled: boolean;
120
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
92
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
121
93
  isCropping: boolean;
122
- croppingElementId: string | null;
94
+ croppingElementId: ExcalidrawElement["id"] | null;
123
95
  searchMatches: Readonly<{
124
- focusedId: string | null;
96
+ focusedId: ExcalidrawElement["id"] | null;
125
97
  matches: readonly import("../types").SearchMatch[];
126
98
  }> | null;
127
99
  activeLockedId: string | null;
100
+ hoveredElementIds: Readonly<{
101
+ [id: string]: true;
102
+ }>;
103
+ shouldCacheIgnoreZoom: boolean;
104
+ exportScale: number;
105
+ currentItemArrowType: "sharp" | "round" | "elbow";
106
+ bindMode: import("@excalidraw/element/types").BindMode;
128
107
  contextMenu: {
129
108
  items: import("../components/ContextMenu").ContextMenuItems;
130
109
  top: number;
@@ -132,55 +111,53 @@ export declare const actionClearCanvas: {
132
111
  } | null;
133
112
  showWelcomeScreen: boolean;
134
113
  isLoading: boolean;
135
- errorMessage: import("react").ReactNode;
136
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
114
+ errorMessage: React.ReactNode;
137
115
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
116
+ boxSelectionMode: import("../types").BoxSelectionMode;
117
+ bindingPreference: "enabled" | "disabled";
138
118
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
139
119
  editingFrame: string | null;
120
+ preferredSelectionTool: {
121
+ type: "selection" | "lasso";
122
+ initialized: boolean;
123
+ };
140
124
  exportWithDarkMode: boolean;
141
- exportScale: number;
142
125
  currentItemStrokeColor: string;
143
126
  currentItemBackgroundColor: string;
144
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
127
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
145
128
  currentItemStrokeWidth: number;
146
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
129
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
147
130
  currentItemRoughness: number;
148
131
  currentItemOpacity: number;
149
- currentItemFontFamily: number;
132
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
150
133
  currentItemFontSize: number;
151
- currentItemTextAlign: string;
134
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
152
135
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
153
136
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
154
- currentHoveredFontFamily: number | null;
137
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
155
138
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
156
- currentItemArrowType: "round" | "sharp" | "elbow";
157
139
  cursorButton: "up" | "down";
158
140
  scrolledOutside: boolean;
159
141
  isResizing: boolean;
160
- openMenu: "canvas" | "shape" | null;
161
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
142
+ openMenu: "canvas" | null;
143
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
162
144
  openSidebar: {
163
- name: string;
164
- tab?: string | undefined;
145
+ name: import("../types").SidebarName;
146
+ tab?: import("../types").SidebarTabName;
165
147
  } | null;
166
148
  defaultSidebarDockedPreference: boolean;
167
149
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
168
- hoveredElementIds: Readonly<{
169
- [id: string]: true;
170
- }>;
171
150
  previousSelectedElementIds: {
172
151
  [id: string]: true;
173
152
  };
174
153
  selectedElementsAreBeingDragged: boolean;
175
- shouldCacheIgnoreZoom: boolean;
176
154
  toast: {
177
- message: string;
178
- closable?: boolean | undefined;
179
- duration?: number | undefined;
155
+ message: React.ReactNode;
156
+ closable?: boolean;
157
+ duration?: number;
180
158
  } | null;
181
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
182
- currentChartType: import("@excalidraw/element/types").ChartType;
183
- showHyperlinkPopup: false | "editor" | "info";
159
+ fileHandle: FileSystemFileHandle | null;
160
+ showHyperlinkPopup: false | "info" | "editor";
184
161
  originSnapOffset: {
185
162
  x: number;
186
163
  y: number;
@@ -191,7 +168,6 @@ export declare const actionClearCanvas: {
191
168
  lockedMultiSelections: {
192
169
  [groupId: string]: true;
193
170
  };
194
- stylesPanelMode: "compact" | "full";
195
171
  };
196
172
  captureUpdate: "IMMEDIATELY";
197
173
  };
@@ -206,7 +182,7 @@ export declare const actionZoomIn: {
206
182
  trackEvent: {
207
183
  category: "canvas";
208
184
  };
209
- perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
185
+ perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
210
186
  appState: {
211
187
  userToFollow: null;
212
188
  scrollX: number;
@@ -221,18 +197,24 @@ export declare const actionZoomIn: {
221
197
  } | null;
222
198
  showWelcomeScreen: boolean;
223
199
  isLoading: boolean;
224
- errorMessage: import("react").ReactNode;
200
+ errorMessage: React.ReactNode;
225
201
  activeEmbeddable: {
226
202
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
227
- state: "active" | "hover";
203
+ state: "hover" | "active";
228
204
  } | null;
229
205
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
230
206
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
231
207
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
232
208
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
233
209
  isBindingEnabled: boolean;
210
+ boxSelectionMode: import("../types").BoxSelectionMode;
211
+ bindingPreference: "enabled" | "disabled";
212
+ isMidpointSnappingEnabled: boolean;
234
213
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
235
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
214
+ suggestedBinding: {
215
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
216
+ midPoint?: import("@excalidraw/math").GlobalPoint;
217
+ } | null;
236
218
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
237
219
  frameRendering: {
238
220
  enabled: boolean;
@@ -242,12 +224,16 @@ export declare const actionZoomIn: {
242
224
  };
243
225
  editingFrame: string | null;
244
226
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
245
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
227
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
246
228
  activeTool: {
247
229
  lastActiveTool: import("../types").ActiveTool | null;
248
230
  locked: boolean;
249
231
  fromSelection: boolean;
250
232
  } & import("../types").ActiveTool;
233
+ preferredSelectionTool: {
234
+ type: "selection" | "lasso";
235
+ initialized: boolean;
236
+ };
251
237
  penMode: boolean;
252
238
  penDetected: boolean;
253
239
  exportBackground: boolean;
@@ -256,42 +242,48 @@ export declare const actionZoomIn: {
256
242
  exportScale: number;
257
243
  currentItemStrokeColor: string;
258
244
  currentItemBackgroundColor: string;
259
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
245
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
260
246
  currentItemStrokeWidth: number;
261
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
247
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
262
248
  currentItemRoughness: number;
263
249
  currentItemOpacity: number;
264
- currentItemFontFamily: number;
250
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
265
251
  currentItemFontSize: number;
266
- currentItemTextAlign: string;
252
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
267
253
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
268
254
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
269
- currentHoveredFontFamily: number | null;
255
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
270
256
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
271
- currentItemArrowType: "round" | "sharp" | "elbow";
257
+ currentItemArrowType: "sharp" | "round" | "elbow";
272
258
  viewBackgroundColor: string;
273
259
  cursorButton: "up" | "down";
274
260
  scrolledOutside: boolean;
275
261
  name: string | null;
276
262
  isResizing: boolean;
277
263
  isRotating: boolean;
278
- openMenu: "canvas" | "shape" | null;
279
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
264
+ openMenu: "canvas" | null;
265
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
280
266
  openSidebar: {
281
- name: string;
282
- tab?: string | undefined;
267
+ name: import("../types").SidebarName;
268
+ tab?: import("../types").SidebarTabName;
283
269
  } | null;
284
- openDialog: {
270
+ openDialog: null | {
285
271
  name: "imageExport" | "help" | "jsonExport";
286
272
  } | {
287
273
  name: "ttd";
288
- tab: "mermaid" | "text-to-diagram";
274
+ tab: "text-to-diagram" | "mermaid";
289
275
  } | {
290
276
  name: "commandPalette";
277
+ } | {
278
+ name: "settings";
291
279
  } | {
292
280
  name: "elementLinkSelector";
293
- sourceElementId: string;
294
- } | null;
281
+ sourceElementId: ExcalidrawElement["id"];
282
+ } | {
283
+ name: "charts";
284
+ data: import("../charts").Spreadsheet;
285
+ rawText: string;
286
+ };
295
287
  defaultSidebarDockedPreference: boolean;
296
288
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
297
289
  selectedElementIds: Readonly<{
@@ -306,9 +298,9 @@ export declare const actionZoomIn: {
306
298
  selectedElementsAreBeingDragged: boolean;
307
299
  shouldCacheIgnoreZoom: boolean;
308
300
  toast: {
309
- message: string;
310
- closable?: boolean | undefined;
311
- duration?: number | undefined;
301
+ message: React.ReactNode;
302
+ closable?: boolean;
303
+ duration?: number;
312
304
  } | null;
313
305
  zenModeEnabled: boolean;
314
306
  theme: import("@excalidraw/element/types").Theme;
@@ -319,45 +311,18 @@ export declare const actionZoomIn: {
319
311
  selectedGroupIds: {
320
312
  [groupId: string]: boolean;
321
313
  };
322
- editingGroupId: string | null;
314
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
323
315
  width: number;
324
316
  height: number;
325
317
  offsetTop: number;
326
318
  offsetLeft: number;
327
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
328
- collaborators: Map<import("../types").SocketId, Readonly<{
329
- pointer?: import("../types").CollaboratorPointer | undefined;
330
- button?: "up" | "down" | undefined;
331
- selectedElementIds?: Readonly<{
332
- [id: string]: true;
333
- }> | undefined;
334
- username?: string | null | undefined;
335
- userState?: import("@excalidraw/common").UserIdleState | undefined;
336
- color?: {
337
- background: string;
338
- stroke: string;
339
- } | undefined;
340
- avatarUrl?: string | undefined;
341
- id?: string | undefined;
342
- socketId?: import("../types").SocketId | undefined;
343
- isCurrentUser?: boolean | undefined;
344
- isInCall?: boolean | undefined;
345
- isSpeaking?: boolean | undefined;
346
- isMuted?: boolean | undefined;
347
- }>>;
319
+ fileHandle: FileSystemFileHandle | null;
320
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
348
321
  stats: {
349
322
  open: boolean;
350
323
  panels: number;
351
324
  };
352
- currentChartType: import("@excalidraw/element/types").ChartType;
353
- pasteDialog: {
354
- shown: false;
355
- data: null;
356
- } | {
357
- shown: true;
358
- data: import("../charts").Spreadsheet;
359
- };
360
- showHyperlinkPopup: false | "editor" | "info";
325
+ showHyperlinkPopup: false | "info" | "editor";
361
326
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
362
327
  snapLines: readonly import("../snapping").SnapLine[];
363
328
  originSnapOffset: {
@@ -367,16 +332,16 @@ export declare const actionZoomIn: {
367
332
  objectsSnapModeEnabled: boolean;
368
333
  followedBy: Set<import("../types").SocketId>;
369
334
  isCropping: boolean;
370
- croppingElementId: string | null;
335
+ croppingElementId: ExcalidrawElement["id"] | null;
371
336
  searchMatches: Readonly<{
372
- focusedId: string | null;
337
+ focusedId: ExcalidrawElement["id"] | null;
373
338
  matches: readonly import("../types").SearchMatch[];
374
339
  }> | null;
375
340
  activeLockedId: string | null;
376
341
  lockedMultiSelections: {
377
342
  [groupId: string]: true;
378
343
  };
379
- stylesPanelMode: "compact" | "full";
344
+ bindMode: import("@excalidraw/element/types").BindMode;
380
345
  };
381
346
  captureUpdate: "EVENTUALLY";
382
347
  };
@@ -393,7 +358,7 @@ export declare const actionZoomOut: {
393
358
  trackEvent: {
394
359
  category: "canvas";
395
360
  };
396
- perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
361
+ perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
397
362
  appState: {
398
363
  userToFollow: null;
399
364
  scrollX: number;
@@ -408,18 +373,24 @@ export declare const actionZoomOut: {
408
373
  } | null;
409
374
  showWelcomeScreen: boolean;
410
375
  isLoading: boolean;
411
- errorMessage: import("react").ReactNode;
376
+ errorMessage: React.ReactNode;
412
377
  activeEmbeddable: {
413
378
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
414
- state: "active" | "hover";
379
+ state: "hover" | "active";
415
380
  } | null;
416
381
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
417
382
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
418
383
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
419
384
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
420
385
  isBindingEnabled: boolean;
386
+ boxSelectionMode: import("../types").BoxSelectionMode;
387
+ bindingPreference: "enabled" | "disabled";
388
+ isMidpointSnappingEnabled: boolean;
421
389
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
422
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
390
+ suggestedBinding: {
391
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
392
+ midPoint?: import("@excalidraw/math").GlobalPoint;
393
+ } | null;
423
394
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
424
395
  frameRendering: {
425
396
  enabled: boolean;
@@ -429,12 +400,16 @@ export declare const actionZoomOut: {
429
400
  };
430
401
  editingFrame: string | null;
431
402
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
432
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
403
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
433
404
  activeTool: {
434
405
  lastActiveTool: import("../types").ActiveTool | null;
435
406
  locked: boolean;
436
407
  fromSelection: boolean;
437
408
  } & import("../types").ActiveTool;
409
+ preferredSelectionTool: {
410
+ type: "selection" | "lasso";
411
+ initialized: boolean;
412
+ };
438
413
  penMode: boolean;
439
414
  penDetected: boolean;
440
415
  exportBackground: boolean;
@@ -443,42 +418,48 @@ export declare const actionZoomOut: {
443
418
  exportScale: number;
444
419
  currentItemStrokeColor: string;
445
420
  currentItemBackgroundColor: string;
446
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
421
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
447
422
  currentItemStrokeWidth: number;
448
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
423
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
449
424
  currentItemRoughness: number;
450
425
  currentItemOpacity: number;
451
- currentItemFontFamily: number;
426
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
452
427
  currentItemFontSize: number;
453
- currentItemTextAlign: string;
428
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
454
429
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
455
430
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
456
- currentHoveredFontFamily: number | null;
431
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
457
432
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
458
- currentItemArrowType: "round" | "sharp" | "elbow";
433
+ currentItemArrowType: "sharp" | "round" | "elbow";
459
434
  viewBackgroundColor: string;
460
435
  cursorButton: "up" | "down";
461
436
  scrolledOutside: boolean;
462
437
  name: string | null;
463
438
  isResizing: boolean;
464
439
  isRotating: boolean;
465
- openMenu: "canvas" | "shape" | null;
466
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
440
+ openMenu: "canvas" | null;
441
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
467
442
  openSidebar: {
468
- name: string;
469
- tab?: string | undefined;
443
+ name: import("../types").SidebarName;
444
+ tab?: import("../types").SidebarTabName;
470
445
  } | null;
471
- openDialog: {
446
+ openDialog: null | {
472
447
  name: "imageExport" | "help" | "jsonExport";
473
448
  } | {
474
449
  name: "ttd";
475
- tab: "mermaid" | "text-to-diagram";
450
+ tab: "text-to-diagram" | "mermaid";
476
451
  } | {
477
452
  name: "commandPalette";
453
+ } | {
454
+ name: "settings";
478
455
  } | {
479
456
  name: "elementLinkSelector";
480
- sourceElementId: string;
481
- } | null;
457
+ sourceElementId: ExcalidrawElement["id"];
458
+ } | {
459
+ name: "charts";
460
+ data: import("../charts").Spreadsheet;
461
+ rawText: string;
462
+ };
482
463
  defaultSidebarDockedPreference: boolean;
483
464
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
484
465
  selectedElementIds: Readonly<{
@@ -493,9 +474,9 @@ export declare const actionZoomOut: {
493
474
  selectedElementsAreBeingDragged: boolean;
494
475
  shouldCacheIgnoreZoom: boolean;
495
476
  toast: {
496
- message: string;
497
- closable?: boolean | undefined;
498
- duration?: number | undefined;
477
+ message: React.ReactNode;
478
+ closable?: boolean;
479
+ duration?: number;
499
480
  } | null;
500
481
  zenModeEnabled: boolean;
501
482
  theme: import("@excalidraw/element/types").Theme;
@@ -506,45 +487,18 @@ export declare const actionZoomOut: {
506
487
  selectedGroupIds: {
507
488
  [groupId: string]: boolean;
508
489
  };
509
- editingGroupId: string | null;
490
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
510
491
  width: number;
511
492
  height: number;
512
493
  offsetTop: number;
513
494
  offsetLeft: number;
514
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
515
- collaborators: Map<import("../types").SocketId, Readonly<{
516
- pointer?: import("../types").CollaboratorPointer | undefined;
517
- button?: "up" | "down" | undefined;
518
- selectedElementIds?: Readonly<{
519
- [id: string]: true;
520
- }> | undefined;
521
- username?: string | null | undefined;
522
- userState?: import("@excalidraw/common").UserIdleState | undefined;
523
- color?: {
524
- background: string;
525
- stroke: string;
526
- } | undefined;
527
- avatarUrl?: string | undefined;
528
- id?: string | undefined;
529
- socketId?: import("../types").SocketId | undefined;
530
- isCurrentUser?: boolean | undefined;
531
- isInCall?: boolean | undefined;
532
- isSpeaking?: boolean | undefined;
533
- isMuted?: boolean | undefined;
534
- }>>;
495
+ fileHandle: FileSystemFileHandle | null;
496
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
535
497
  stats: {
536
498
  open: boolean;
537
499
  panels: number;
538
500
  };
539
- currentChartType: import("@excalidraw/element/types").ChartType;
540
- pasteDialog: {
541
- shown: false;
542
- data: null;
543
- } | {
544
- shown: true;
545
- data: import("../charts").Spreadsheet;
546
- };
547
- showHyperlinkPopup: false | "editor" | "info";
501
+ showHyperlinkPopup: false | "info" | "editor";
548
502
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
549
503
  snapLines: readonly import("../snapping").SnapLine[];
550
504
  originSnapOffset: {
@@ -554,16 +508,16 @@ export declare const actionZoomOut: {
554
508
  objectsSnapModeEnabled: boolean;
555
509
  followedBy: Set<import("../types").SocketId>;
556
510
  isCropping: boolean;
557
- croppingElementId: string | null;
511
+ croppingElementId: ExcalidrawElement["id"] | null;
558
512
  searchMatches: Readonly<{
559
- focusedId: string | null;
513
+ focusedId: ExcalidrawElement["id"] | null;
560
514
  matches: readonly import("../types").SearchMatch[];
561
515
  }> | null;
562
516
  activeLockedId: string | null;
563
517
  lockedMultiSelections: {
564
518
  [groupId: string]: true;
565
519
  };
566
- stylesPanelMode: "compact" | "full";
520
+ bindMode: import("@excalidraw/element/types").BindMode;
567
521
  };
568
522
  captureUpdate: "EVENTUALLY";
569
523
  };
@@ -580,7 +534,7 @@ export declare const actionResetZoom: {
580
534
  trackEvent: {
581
535
  category: "canvas";
582
536
  };
583
- perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
537
+ perform: (_elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
584
538
  appState: {
585
539
  userToFollow: null;
586
540
  scrollX: number;
@@ -595,18 +549,24 @@ export declare const actionResetZoom: {
595
549
  } | null;
596
550
  showWelcomeScreen: boolean;
597
551
  isLoading: boolean;
598
- errorMessage: import("react").ReactNode;
552
+ errorMessage: React.ReactNode;
599
553
  activeEmbeddable: {
600
554
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
601
- state: "active" | "hover";
555
+ state: "hover" | "active";
602
556
  } | null;
603
557
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
604
558
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
605
559
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
606
560
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
607
561
  isBindingEnabled: boolean;
562
+ boxSelectionMode: import("../types").BoxSelectionMode;
563
+ bindingPreference: "enabled" | "disabled";
564
+ isMidpointSnappingEnabled: boolean;
608
565
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
609
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
566
+ suggestedBinding: {
567
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
568
+ midPoint?: import("@excalidraw/math").GlobalPoint;
569
+ } | null;
610
570
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
611
571
  frameRendering: {
612
572
  enabled: boolean;
@@ -616,12 +576,16 @@ export declare const actionResetZoom: {
616
576
  };
617
577
  editingFrame: string | null;
618
578
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
619
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
579
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
620
580
  activeTool: {
621
581
  lastActiveTool: import("../types").ActiveTool | null;
622
582
  locked: boolean;
623
583
  fromSelection: boolean;
624
584
  } & import("../types").ActiveTool;
585
+ preferredSelectionTool: {
586
+ type: "selection" | "lasso";
587
+ initialized: boolean;
588
+ };
625
589
  penMode: boolean;
626
590
  penDetected: boolean;
627
591
  exportBackground: boolean;
@@ -630,42 +594,48 @@ export declare const actionResetZoom: {
630
594
  exportScale: number;
631
595
  currentItemStrokeColor: string;
632
596
  currentItemBackgroundColor: string;
633
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
597
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
634
598
  currentItemStrokeWidth: number;
635
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
599
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
636
600
  currentItemRoughness: number;
637
601
  currentItemOpacity: number;
638
- currentItemFontFamily: number;
602
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
639
603
  currentItemFontSize: number;
640
- currentItemTextAlign: string;
604
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
641
605
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
642
606
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
643
- currentHoveredFontFamily: number | null;
607
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
644
608
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
645
- currentItemArrowType: "round" | "sharp" | "elbow";
609
+ currentItemArrowType: "sharp" | "round" | "elbow";
646
610
  viewBackgroundColor: string;
647
611
  cursorButton: "up" | "down";
648
612
  scrolledOutside: boolean;
649
613
  name: string | null;
650
614
  isResizing: boolean;
651
615
  isRotating: boolean;
652
- openMenu: "canvas" | "shape" | null;
653
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
616
+ openMenu: "canvas" | null;
617
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
654
618
  openSidebar: {
655
- name: string;
656
- tab?: string | undefined;
619
+ name: import("../types").SidebarName;
620
+ tab?: import("../types").SidebarTabName;
657
621
  } | null;
658
- openDialog: {
622
+ openDialog: null | {
659
623
  name: "imageExport" | "help" | "jsonExport";
660
624
  } | {
661
625
  name: "ttd";
662
- tab: "mermaid" | "text-to-diagram";
626
+ tab: "text-to-diagram" | "mermaid";
663
627
  } | {
664
628
  name: "commandPalette";
629
+ } | {
630
+ name: "settings";
665
631
  } | {
666
632
  name: "elementLinkSelector";
667
- sourceElementId: string;
668
- } | null;
633
+ sourceElementId: ExcalidrawElement["id"];
634
+ } | {
635
+ name: "charts";
636
+ data: import("../charts").Spreadsheet;
637
+ rawText: string;
638
+ };
669
639
  defaultSidebarDockedPreference: boolean;
670
640
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
671
641
  selectedElementIds: Readonly<{
@@ -680,9 +650,9 @@ export declare const actionResetZoom: {
680
650
  selectedElementsAreBeingDragged: boolean;
681
651
  shouldCacheIgnoreZoom: boolean;
682
652
  toast: {
683
- message: string;
684
- closable?: boolean | undefined;
685
- duration?: number | undefined;
653
+ message: React.ReactNode;
654
+ closable?: boolean;
655
+ duration?: number;
686
656
  } | null;
687
657
  zenModeEnabled: boolean;
688
658
  theme: import("@excalidraw/element/types").Theme;
@@ -693,45 +663,18 @@ export declare const actionResetZoom: {
693
663
  selectedGroupIds: {
694
664
  [groupId: string]: boolean;
695
665
  };
696
- editingGroupId: string | null;
666
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
697
667
  width: number;
698
668
  height: number;
699
669
  offsetTop: number;
700
670
  offsetLeft: number;
701
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
702
- collaborators: Map<import("../types").SocketId, Readonly<{
703
- pointer?: import("../types").CollaboratorPointer | undefined;
704
- button?: "up" | "down" | undefined;
705
- selectedElementIds?: Readonly<{
706
- [id: string]: true;
707
- }> | undefined;
708
- username?: string | null | undefined;
709
- userState?: import("@excalidraw/common").UserIdleState | undefined;
710
- color?: {
711
- background: string;
712
- stroke: string;
713
- } | undefined;
714
- avatarUrl?: string | undefined;
715
- id?: string | undefined;
716
- socketId?: import("../types").SocketId | undefined;
717
- isCurrentUser?: boolean | undefined;
718
- isInCall?: boolean | undefined;
719
- isSpeaking?: boolean | undefined;
720
- isMuted?: boolean | undefined;
721
- }>>;
671
+ fileHandle: FileSystemFileHandle | null;
672
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
722
673
  stats: {
723
674
  open: boolean;
724
675
  panels: number;
725
676
  };
726
- currentChartType: import("@excalidraw/element/types").ChartType;
727
- pasteDialog: {
728
- shown: false;
729
- data: null;
730
- } | {
731
- shown: true;
732
- data: import("../charts").Spreadsheet;
733
- };
734
- showHyperlinkPopup: false | "editor" | "info";
677
+ showHyperlinkPopup: false | "info" | "editor";
735
678
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
736
679
  snapLines: readonly import("../snapping").SnapLine[];
737
680
  originSnapOffset: {
@@ -741,16 +684,16 @@ export declare const actionResetZoom: {
741
684
  objectsSnapModeEnabled: boolean;
742
685
  followedBy: Set<import("../types").SocketId>;
743
686
  isCropping: boolean;
744
- croppingElementId: string | null;
687
+ croppingElementId: ExcalidrawElement["id"] | null;
745
688
  searchMatches: Readonly<{
746
- focusedId: string | null;
689
+ focusedId: ExcalidrawElement["id"] | null;
747
690
  matches: readonly import("../types").SearchMatch[];
748
691
  }> | null;
749
692
  activeLockedId: string | null;
750
693
  lockedMultiSelections: {
751
694
  [groupId: string]: true;
752
695
  };
753
- stylesPanelMode: "compact" | "full";
696
+ bindMode: import("@excalidraw/element/types").BindMode;
754
697
  };
755
698
  captureUpdate: "EVENTUALLY";
756
699
  };
@@ -761,19 +704,14 @@ export declare const actionResetZoom: {
761
704
  };
762
705
  export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToViewport, viewportZoomFactor, minZoom, maxZoom, }: {
763
706
  bounds: SceneBounds;
764
- canvasOffsets?: Partial<{
765
- top: number;
766
- right: number;
767
- bottom: number;
768
- left: number;
769
- }> | undefined;
707
+ canvasOffsets?: Offsets;
770
708
  appState: Readonly<AppState>;
771
709
  /** whether to fit content to viewport (beyond >100%) */
772
710
  fitToViewport: boolean;
773
711
  /** zoom content to cover X of the viewport, when fitToViewport=true */
774
- viewportZoomFactor?: number | undefined;
775
- minZoom?: number | undefined;
776
- maxZoom?: number | undefined;
712
+ viewportZoomFactor?: number;
713
+ minZoom?: number;
714
+ maxZoom?: number;
777
715
  }) => {
778
716
  appState: {
779
717
  scrollX: number;
@@ -788,18 +726,24 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
788
726
  } | null;
789
727
  showWelcomeScreen: boolean;
790
728
  isLoading: boolean;
791
- errorMessage: import("react").ReactNode;
729
+ errorMessage: React.ReactNode;
792
730
  activeEmbeddable: {
793
731
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
794
- state: "active" | "hover";
732
+ state: "hover" | "active";
795
733
  } | null;
796
734
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
797
735
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
798
736
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
799
737
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
800
738
  isBindingEnabled: boolean;
739
+ boxSelectionMode: import("../types").BoxSelectionMode;
740
+ bindingPreference: "enabled" | "disabled";
741
+ isMidpointSnappingEnabled: boolean;
801
742
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
802
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
743
+ suggestedBinding: {
744
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
745
+ midPoint?: import("@excalidraw/math").GlobalPoint;
746
+ } | null;
803
747
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
804
748
  frameRendering: {
805
749
  enabled: boolean;
@@ -809,12 +753,16 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
809
753
  };
810
754
  editingFrame: string | null;
811
755
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
812
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
756
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
813
757
  activeTool: {
814
758
  lastActiveTool: import("../types").ActiveTool | null;
815
759
  locked: boolean;
816
760
  fromSelection: boolean;
817
761
  } & import("../types").ActiveTool;
762
+ preferredSelectionTool: {
763
+ type: "selection" | "lasso";
764
+ initialized: boolean;
765
+ };
818
766
  penMode: boolean;
819
767
  penDetected: boolean;
820
768
  exportBackground: boolean;
@@ -823,42 +771,48 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
823
771
  exportScale: number;
824
772
  currentItemStrokeColor: string;
825
773
  currentItemBackgroundColor: string;
826
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
774
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
827
775
  currentItemStrokeWidth: number;
828
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
776
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
829
777
  currentItemRoughness: number;
830
778
  currentItemOpacity: number;
831
- currentItemFontFamily: number;
779
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
832
780
  currentItemFontSize: number;
833
- currentItemTextAlign: string;
781
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
834
782
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
835
783
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
836
- currentHoveredFontFamily: number | null;
784
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
837
785
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
838
- currentItemArrowType: "round" | "sharp" | "elbow";
786
+ currentItemArrowType: "sharp" | "round" | "elbow";
839
787
  viewBackgroundColor: string;
840
788
  cursorButton: "up" | "down";
841
789
  scrolledOutside: boolean;
842
790
  name: string | null;
843
791
  isResizing: boolean;
844
792
  isRotating: boolean;
845
- openMenu: "canvas" | "shape" | null;
846
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
793
+ openMenu: "canvas" | null;
794
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
847
795
  openSidebar: {
848
- name: string;
849
- tab?: string | undefined;
796
+ name: import("../types").SidebarName;
797
+ tab?: import("../types").SidebarTabName;
850
798
  } | null;
851
- openDialog: {
799
+ openDialog: null | {
852
800
  name: "imageExport" | "help" | "jsonExport";
853
801
  } | {
854
802
  name: "ttd";
855
- tab: "mermaid" | "text-to-diagram";
803
+ tab: "text-to-diagram" | "mermaid";
856
804
  } | {
857
805
  name: "commandPalette";
806
+ } | {
807
+ name: "settings";
858
808
  } | {
859
809
  name: "elementLinkSelector";
860
- sourceElementId: string;
861
- } | null;
810
+ sourceElementId: ExcalidrawElement["id"];
811
+ } | {
812
+ name: "charts";
813
+ data: import("../charts").Spreadsheet;
814
+ rawText: string;
815
+ };
862
816
  defaultSidebarDockedPreference: boolean;
863
817
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
864
818
  selectedElementIds: Readonly<{
@@ -873,9 +827,9 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
873
827
  selectedElementsAreBeingDragged: boolean;
874
828
  shouldCacheIgnoreZoom: boolean;
875
829
  toast: {
876
- message: string;
877
- closable?: boolean | undefined;
878
- duration?: number | undefined;
830
+ message: React.ReactNode;
831
+ closable?: boolean;
832
+ duration?: number;
879
833
  } | null;
880
834
  zenModeEnabled: boolean;
881
835
  theme: import("@excalidraw/element/types").Theme;
@@ -886,45 +840,18 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
886
840
  selectedGroupIds: {
887
841
  [groupId: string]: boolean;
888
842
  };
889
- editingGroupId: string | null;
843
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
890
844
  width: number;
891
845
  height: number;
892
846
  offsetTop: number;
893
847
  offsetLeft: number;
894
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
895
- collaborators: Map<import("../types").SocketId, Readonly<{
896
- pointer?: import("../types").CollaboratorPointer | undefined;
897
- button?: "up" | "down" | undefined;
898
- selectedElementIds?: Readonly<{
899
- [id: string]: true;
900
- }> | undefined;
901
- username?: string | null | undefined;
902
- userState?: import("@excalidraw/common").UserIdleState | undefined;
903
- color?: {
904
- background: string;
905
- stroke: string;
906
- } | undefined;
907
- avatarUrl?: string | undefined;
908
- id?: string | undefined;
909
- socketId?: import("../types").SocketId | undefined;
910
- isCurrentUser?: boolean | undefined;
911
- isInCall?: boolean | undefined;
912
- isSpeaking?: boolean | undefined;
913
- isMuted?: boolean | undefined;
914
- }>>;
848
+ fileHandle: FileSystemFileHandle | null;
849
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
915
850
  stats: {
916
851
  open: boolean;
917
852
  panels: number;
918
853
  };
919
- currentChartType: import("@excalidraw/element/types").ChartType;
920
- pasteDialog: {
921
- shown: false;
922
- data: null;
923
- } | {
924
- shown: true;
925
- data: import("../charts").Spreadsheet;
926
- };
927
- showHyperlinkPopup: false | "editor" | "info";
854
+ showHyperlinkPopup: false | "info" | "editor";
928
855
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
929
856
  snapLines: readonly import("../snapping").SnapLine[];
930
857
  originSnapOffset: {
@@ -935,34 +862,29 @@ export declare const zoomToFitBounds: ({ bounds, appState, canvasOffsets, fitToV
935
862
  userToFollow: import("../types").UserToFollow | null;
936
863
  followedBy: Set<import("../types").SocketId>;
937
864
  isCropping: boolean;
938
- croppingElementId: string | null;
865
+ croppingElementId: ExcalidrawElement["id"] | null;
939
866
  searchMatches: Readonly<{
940
- focusedId: string | null;
867
+ focusedId: ExcalidrawElement["id"] | null;
941
868
  matches: readonly import("../types").SearchMatch[];
942
869
  }> | null;
943
870
  activeLockedId: string | null;
944
871
  lockedMultiSelections: {
945
872
  [groupId: string]: true;
946
873
  };
947
- stylesPanelMode: "compact" | "full";
874
+ bindMode: import("@excalidraw/element/types").BindMode;
948
875
  };
949
876
  captureUpdate: "EVENTUALLY";
950
877
  };
951
878
  export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitToViewport, viewportZoomFactor, minZoom, maxZoom, }: {
952
- canvasOffsets?: Partial<{
953
- top: number;
954
- right: number;
955
- bottom: number;
956
- left: number;
957
- }> | undefined;
879
+ canvasOffsets?: Offsets;
958
880
  targetElements: readonly ExcalidrawElement[];
959
881
  appState: Readonly<AppState>;
960
882
  /** whether to fit content to viewport (beyond >100%) */
961
883
  fitToViewport: boolean;
962
884
  /** zoom content to cover X of the viewport, when fitToViewport=true */
963
- viewportZoomFactor?: number | undefined;
964
- minZoom?: number | undefined;
965
- maxZoom?: number | undefined;
885
+ viewportZoomFactor?: number;
886
+ minZoom?: number;
887
+ maxZoom?: number;
966
888
  }) => {
967
889
  appState: {
968
890
  scrollX: number;
@@ -977,18 +899,24 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
977
899
  } | null;
978
900
  showWelcomeScreen: boolean;
979
901
  isLoading: boolean;
980
- errorMessage: import("react").ReactNode;
902
+ errorMessage: React.ReactNode;
981
903
  activeEmbeddable: {
982
904
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
983
- state: "active" | "hover";
905
+ state: "hover" | "active";
984
906
  } | null;
985
907
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
986
908
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
987
909
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
988
910
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
989
911
  isBindingEnabled: boolean;
912
+ boxSelectionMode: import("../types").BoxSelectionMode;
913
+ bindingPreference: "enabled" | "disabled";
914
+ isMidpointSnappingEnabled: boolean;
990
915
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
991
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
916
+ suggestedBinding: {
917
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
918
+ midPoint?: import("@excalidraw/math").GlobalPoint;
919
+ } | null;
992
920
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
993
921
  frameRendering: {
994
922
  enabled: boolean;
@@ -998,12 +926,16 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
998
926
  };
999
927
  editingFrame: string | null;
1000
928
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1001
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
929
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1002
930
  activeTool: {
1003
931
  lastActiveTool: import("../types").ActiveTool | null;
1004
932
  locked: boolean;
1005
933
  fromSelection: boolean;
1006
934
  } & import("../types").ActiveTool;
935
+ preferredSelectionTool: {
936
+ type: "selection" | "lasso";
937
+ initialized: boolean;
938
+ };
1007
939
  penMode: boolean;
1008
940
  penDetected: boolean;
1009
941
  exportBackground: boolean;
@@ -1012,42 +944,48 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
1012
944
  exportScale: number;
1013
945
  currentItemStrokeColor: string;
1014
946
  currentItemBackgroundColor: string;
1015
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
947
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
1016
948
  currentItemStrokeWidth: number;
1017
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
949
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1018
950
  currentItemRoughness: number;
1019
951
  currentItemOpacity: number;
1020
- currentItemFontFamily: number;
952
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1021
953
  currentItemFontSize: number;
1022
- currentItemTextAlign: string;
954
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
1023
955
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1024
956
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1025
- currentHoveredFontFamily: number | null;
957
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
1026
958
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1027
- currentItemArrowType: "round" | "sharp" | "elbow";
959
+ currentItemArrowType: "sharp" | "round" | "elbow";
1028
960
  viewBackgroundColor: string;
1029
961
  cursorButton: "up" | "down";
1030
962
  scrolledOutside: boolean;
1031
963
  name: string | null;
1032
964
  isResizing: boolean;
1033
965
  isRotating: boolean;
1034
- openMenu: "canvas" | "shape" | null;
1035
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
966
+ openMenu: "canvas" | null;
967
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1036
968
  openSidebar: {
1037
- name: string;
1038
- tab?: string | undefined;
969
+ name: import("../types").SidebarName;
970
+ tab?: import("../types").SidebarTabName;
1039
971
  } | null;
1040
- openDialog: {
972
+ openDialog: null | {
1041
973
  name: "imageExport" | "help" | "jsonExport";
1042
974
  } | {
1043
975
  name: "ttd";
1044
- tab: "mermaid" | "text-to-diagram";
976
+ tab: "text-to-diagram" | "mermaid";
1045
977
  } | {
1046
978
  name: "commandPalette";
979
+ } | {
980
+ name: "settings";
1047
981
  } | {
1048
982
  name: "elementLinkSelector";
1049
- sourceElementId: string;
1050
- } | null;
983
+ sourceElementId: ExcalidrawElement["id"];
984
+ } | {
985
+ name: "charts";
986
+ data: import("../charts").Spreadsheet;
987
+ rawText: string;
988
+ };
1051
989
  defaultSidebarDockedPreference: boolean;
1052
990
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1053
991
  selectedElementIds: Readonly<{
@@ -1062,9 +1000,9 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
1062
1000
  selectedElementsAreBeingDragged: boolean;
1063
1001
  shouldCacheIgnoreZoom: boolean;
1064
1002
  toast: {
1065
- message: string;
1066
- closable?: boolean | undefined;
1067
- duration?: number | undefined;
1003
+ message: React.ReactNode;
1004
+ closable?: boolean;
1005
+ duration?: number;
1068
1006
  } | null;
1069
1007
  zenModeEnabled: boolean;
1070
1008
  theme: import("@excalidraw/element/types").Theme;
@@ -1075,45 +1013,18 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
1075
1013
  selectedGroupIds: {
1076
1014
  [groupId: string]: boolean;
1077
1015
  };
1078
- editingGroupId: string | null;
1016
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
1079
1017
  width: number;
1080
1018
  height: number;
1081
1019
  offsetTop: number;
1082
1020
  offsetLeft: number;
1083
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
1084
- collaborators: Map<import("../types").SocketId, Readonly<{
1085
- pointer?: import("../types").CollaboratorPointer | undefined;
1086
- button?: "up" | "down" | undefined;
1087
- selectedElementIds?: Readonly<{
1088
- [id: string]: true;
1089
- }> | undefined;
1090
- username?: string | null | undefined;
1091
- userState?: import("@excalidraw/common").UserIdleState | undefined;
1092
- color?: {
1093
- background: string;
1094
- stroke: string;
1095
- } | undefined;
1096
- avatarUrl?: string | undefined;
1097
- id?: string | undefined;
1098
- socketId?: import("../types").SocketId | undefined;
1099
- isCurrentUser?: boolean | undefined;
1100
- isInCall?: boolean | undefined;
1101
- isSpeaking?: boolean | undefined;
1102
- isMuted?: boolean | undefined;
1103
- }>>;
1021
+ fileHandle: FileSystemFileHandle | null;
1022
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
1104
1023
  stats: {
1105
1024
  open: boolean;
1106
1025
  panels: number;
1107
1026
  };
1108
- currentChartType: import("@excalidraw/element/types").ChartType;
1109
- pasteDialog: {
1110
- shown: false;
1111
- data: null;
1112
- } | {
1113
- shown: true;
1114
- data: import("../charts").Spreadsheet;
1115
- };
1116
- showHyperlinkPopup: false | "editor" | "info";
1027
+ showHyperlinkPopup: false | "info" | "editor";
1117
1028
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1118
1029
  snapLines: readonly import("../snapping").SnapLine[];
1119
1030
  originSnapOffset: {
@@ -1124,16 +1035,16 @@ export declare const zoomToFit: ({ canvasOffsets, targetElements, appState, fitT
1124
1035
  userToFollow: import("../types").UserToFollow | null;
1125
1036
  followedBy: Set<import("../types").SocketId>;
1126
1037
  isCropping: boolean;
1127
- croppingElementId: string | null;
1038
+ croppingElementId: ExcalidrawElement["id"] | null;
1128
1039
  searchMatches: Readonly<{
1129
- focusedId: string | null;
1040
+ focusedId: ExcalidrawElement["id"] | null;
1130
1041
  matches: readonly import("../types").SearchMatch[];
1131
1042
  }> | null;
1132
1043
  activeLockedId: string | null;
1133
1044
  lockedMultiSelections: {
1134
1045
  [groupId: string]: true;
1135
1046
  };
1136
- stylesPanelMode: "compact" | "full";
1047
+ bindMode: import("@excalidraw/element/types").BindMode;
1137
1048
  };
1138
1049
  captureUpdate: "EVENTUALLY";
1139
1050
  };
@@ -1144,7 +1055,7 @@ export declare const actionZoomToFitSelectionInViewport: {
1144
1055
  trackEvent: {
1145
1056
  category: "canvas";
1146
1057
  };
1147
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1058
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1148
1059
  appState: {
1149
1060
  scrollX: number;
1150
1061
  scrollY: number;
@@ -1158,18 +1069,24 @@ export declare const actionZoomToFitSelectionInViewport: {
1158
1069
  } | null;
1159
1070
  showWelcomeScreen: boolean;
1160
1071
  isLoading: boolean;
1161
- errorMessage: import("react").ReactNode;
1072
+ errorMessage: React.ReactNode;
1162
1073
  activeEmbeddable: {
1163
1074
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
1164
- state: "active" | "hover";
1075
+ state: "hover" | "active";
1165
1076
  } | null;
1166
1077
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
1167
1078
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1168
1079
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
1169
1080
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1170
1081
  isBindingEnabled: boolean;
1082
+ boxSelectionMode: import("../types").BoxSelectionMode;
1083
+ bindingPreference: "enabled" | "disabled";
1084
+ isMidpointSnappingEnabled: boolean;
1171
1085
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
1172
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1086
+ suggestedBinding: {
1087
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1088
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1089
+ } | null;
1173
1090
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
1174
1091
  frameRendering: {
1175
1092
  enabled: boolean;
@@ -1179,12 +1096,16 @@ export declare const actionZoomToFitSelectionInViewport: {
1179
1096
  };
1180
1097
  editingFrame: string | null;
1181
1098
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1182
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1099
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1183
1100
  activeTool: {
1184
1101
  lastActiveTool: import("../types").ActiveTool | null;
1185
1102
  locked: boolean;
1186
1103
  fromSelection: boolean;
1187
1104
  } & import("../types").ActiveTool;
1105
+ preferredSelectionTool: {
1106
+ type: "selection" | "lasso";
1107
+ initialized: boolean;
1108
+ };
1188
1109
  penMode: boolean;
1189
1110
  penDetected: boolean;
1190
1111
  exportBackground: boolean;
@@ -1193,42 +1114,48 @@ export declare const actionZoomToFitSelectionInViewport: {
1193
1114
  exportScale: number;
1194
1115
  currentItemStrokeColor: string;
1195
1116
  currentItemBackgroundColor: string;
1196
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1117
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
1197
1118
  currentItemStrokeWidth: number;
1198
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1119
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1199
1120
  currentItemRoughness: number;
1200
1121
  currentItemOpacity: number;
1201
- currentItemFontFamily: number;
1122
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1202
1123
  currentItemFontSize: number;
1203
- currentItemTextAlign: string;
1124
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
1204
1125
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1205
1126
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1206
- currentHoveredFontFamily: number | null;
1127
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
1207
1128
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1208
- currentItemArrowType: "round" | "sharp" | "elbow";
1129
+ currentItemArrowType: "sharp" | "round" | "elbow";
1209
1130
  viewBackgroundColor: string;
1210
1131
  cursorButton: "up" | "down";
1211
1132
  scrolledOutside: boolean;
1212
1133
  name: string | null;
1213
1134
  isResizing: boolean;
1214
1135
  isRotating: boolean;
1215
- openMenu: "canvas" | "shape" | null;
1216
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1136
+ openMenu: "canvas" | null;
1137
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1217
1138
  openSidebar: {
1218
- name: string;
1219
- tab?: string | undefined;
1139
+ name: import("../types").SidebarName;
1140
+ tab?: import("../types").SidebarTabName;
1220
1141
  } | null;
1221
- openDialog: {
1142
+ openDialog: null | {
1222
1143
  name: "imageExport" | "help" | "jsonExport";
1223
1144
  } | {
1224
1145
  name: "ttd";
1225
- tab: "mermaid" | "text-to-diagram";
1146
+ tab: "text-to-diagram" | "mermaid";
1226
1147
  } | {
1227
1148
  name: "commandPalette";
1149
+ } | {
1150
+ name: "settings";
1228
1151
  } | {
1229
1152
  name: "elementLinkSelector";
1230
- sourceElementId: string;
1231
- } | null;
1153
+ sourceElementId: ExcalidrawElement["id"];
1154
+ } | {
1155
+ name: "charts";
1156
+ data: import("../charts").Spreadsheet;
1157
+ rawText: string;
1158
+ };
1232
1159
  defaultSidebarDockedPreference: boolean;
1233
1160
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1234
1161
  selectedElementIds: Readonly<{
@@ -1243,9 +1170,9 @@ export declare const actionZoomToFitSelectionInViewport: {
1243
1170
  selectedElementsAreBeingDragged: boolean;
1244
1171
  shouldCacheIgnoreZoom: boolean;
1245
1172
  toast: {
1246
- message: string;
1247
- closable?: boolean | undefined;
1248
- duration?: number | undefined;
1173
+ message: React.ReactNode;
1174
+ closable?: boolean;
1175
+ duration?: number;
1249
1176
  } | null;
1250
1177
  zenModeEnabled: boolean;
1251
1178
  theme: import("@excalidraw/element/types").Theme;
@@ -1256,45 +1183,18 @@ export declare const actionZoomToFitSelectionInViewport: {
1256
1183
  selectedGroupIds: {
1257
1184
  [groupId: string]: boolean;
1258
1185
  };
1259
- editingGroupId: string | null;
1186
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
1260
1187
  width: number;
1261
1188
  height: number;
1262
1189
  offsetTop: number;
1263
1190
  offsetLeft: number;
1264
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
1265
- collaborators: Map<import("../types").SocketId, Readonly<{
1266
- pointer?: import("../types").CollaboratorPointer | undefined;
1267
- button?: "up" | "down" | undefined;
1268
- selectedElementIds?: Readonly<{
1269
- [id: string]: true;
1270
- }> | undefined;
1271
- username?: string | null | undefined;
1272
- userState?: import("@excalidraw/common").UserIdleState | undefined;
1273
- color?: {
1274
- background: string;
1275
- stroke: string;
1276
- } | undefined;
1277
- avatarUrl?: string | undefined;
1278
- id?: string | undefined;
1279
- socketId?: import("../types").SocketId | undefined;
1280
- isCurrentUser?: boolean | undefined;
1281
- isInCall?: boolean | undefined;
1282
- isSpeaking?: boolean | undefined;
1283
- isMuted?: boolean | undefined;
1284
- }>>;
1191
+ fileHandle: FileSystemFileHandle | null;
1192
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
1285
1193
  stats: {
1286
1194
  open: boolean;
1287
1195
  panels: number;
1288
1196
  };
1289
- currentChartType: import("@excalidraw/element/types").ChartType;
1290
- pasteDialog: {
1291
- shown: false;
1292
- data: null;
1293
- } | {
1294
- shown: true;
1295
- data: import("../charts").Spreadsheet;
1296
- };
1297
- showHyperlinkPopup: false | "editor" | "info";
1197
+ showHyperlinkPopup: false | "info" | "editor";
1298
1198
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1299
1199
  snapLines: readonly import("../snapping").SnapLine[];
1300
1200
  originSnapOffset: {
@@ -1305,16 +1205,16 @@ export declare const actionZoomToFitSelectionInViewport: {
1305
1205
  userToFollow: import("../types").UserToFollow | null;
1306
1206
  followedBy: Set<import("../types").SocketId>;
1307
1207
  isCropping: boolean;
1308
- croppingElementId: string | null;
1208
+ croppingElementId: ExcalidrawElement["id"] | null;
1309
1209
  searchMatches: Readonly<{
1310
- focusedId: string | null;
1210
+ focusedId: ExcalidrawElement["id"] | null;
1311
1211
  matches: readonly import("../types").SearchMatch[];
1312
1212
  }> | null;
1313
1213
  activeLockedId: string | null;
1314
1214
  lockedMultiSelections: {
1315
1215
  [groupId: string]: true;
1316
1216
  };
1317
- stylesPanelMode: "compact" | "full";
1217
+ bindMode: import("@excalidraw/element/types").BindMode;
1318
1218
  };
1319
1219
  captureUpdate: "EVENTUALLY";
1320
1220
  };
@@ -1329,7 +1229,7 @@ export declare const actionZoomToFitSelection: {
1329
1229
  trackEvent: {
1330
1230
  category: "canvas";
1331
1231
  };
1332
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1232
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1333
1233
  appState: {
1334
1234
  scrollX: number;
1335
1235
  scrollY: number;
@@ -1343,18 +1243,24 @@ export declare const actionZoomToFitSelection: {
1343
1243
  } | null;
1344
1244
  showWelcomeScreen: boolean;
1345
1245
  isLoading: boolean;
1346
- errorMessage: import("react").ReactNode;
1246
+ errorMessage: React.ReactNode;
1347
1247
  activeEmbeddable: {
1348
1248
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
1349
- state: "active" | "hover";
1249
+ state: "hover" | "active";
1350
1250
  } | null;
1351
1251
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
1352
1252
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1353
1253
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
1354
1254
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1355
1255
  isBindingEnabled: boolean;
1256
+ boxSelectionMode: import("../types").BoxSelectionMode;
1257
+ bindingPreference: "enabled" | "disabled";
1258
+ isMidpointSnappingEnabled: boolean;
1356
1259
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
1357
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1260
+ suggestedBinding: {
1261
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1262
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1263
+ } | null;
1358
1264
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
1359
1265
  frameRendering: {
1360
1266
  enabled: boolean;
@@ -1364,12 +1270,16 @@ export declare const actionZoomToFitSelection: {
1364
1270
  };
1365
1271
  editingFrame: string | null;
1366
1272
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1367
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1273
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1368
1274
  activeTool: {
1369
1275
  lastActiveTool: import("../types").ActiveTool | null;
1370
1276
  locked: boolean;
1371
1277
  fromSelection: boolean;
1372
1278
  } & import("../types").ActiveTool;
1279
+ preferredSelectionTool: {
1280
+ type: "selection" | "lasso";
1281
+ initialized: boolean;
1282
+ };
1373
1283
  penMode: boolean;
1374
1284
  penDetected: boolean;
1375
1285
  exportBackground: boolean;
@@ -1378,42 +1288,48 @@ export declare const actionZoomToFitSelection: {
1378
1288
  exportScale: number;
1379
1289
  currentItemStrokeColor: string;
1380
1290
  currentItemBackgroundColor: string;
1381
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1291
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
1382
1292
  currentItemStrokeWidth: number;
1383
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1293
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1384
1294
  currentItemRoughness: number;
1385
1295
  currentItemOpacity: number;
1386
- currentItemFontFamily: number;
1296
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1387
1297
  currentItemFontSize: number;
1388
- currentItemTextAlign: string;
1298
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
1389
1299
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1390
1300
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1391
- currentHoveredFontFamily: number | null;
1301
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
1392
1302
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1393
- currentItemArrowType: "round" | "sharp" | "elbow";
1303
+ currentItemArrowType: "sharp" | "round" | "elbow";
1394
1304
  viewBackgroundColor: string;
1395
1305
  cursorButton: "up" | "down";
1396
1306
  scrolledOutside: boolean;
1397
1307
  name: string | null;
1398
1308
  isResizing: boolean;
1399
1309
  isRotating: boolean;
1400
- openMenu: "canvas" | "shape" | null;
1401
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1310
+ openMenu: "canvas" | null;
1311
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1402
1312
  openSidebar: {
1403
- name: string;
1404
- tab?: string | undefined;
1313
+ name: import("../types").SidebarName;
1314
+ tab?: import("../types").SidebarTabName;
1405
1315
  } | null;
1406
- openDialog: {
1316
+ openDialog: null | {
1407
1317
  name: "imageExport" | "help" | "jsonExport";
1408
1318
  } | {
1409
1319
  name: "ttd";
1410
- tab: "mermaid" | "text-to-diagram";
1320
+ tab: "text-to-diagram" | "mermaid";
1411
1321
  } | {
1412
1322
  name: "commandPalette";
1323
+ } | {
1324
+ name: "settings";
1413
1325
  } | {
1414
1326
  name: "elementLinkSelector";
1415
- sourceElementId: string;
1416
- } | null;
1327
+ sourceElementId: ExcalidrawElement["id"];
1328
+ } | {
1329
+ name: "charts";
1330
+ data: import("../charts").Spreadsheet;
1331
+ rawText: string;
1332
+ };
1417
1333
  defaultSidebarDockedPreference: boolean;
1418
1334
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1419
1335
  selectedElementIds: Readonly<{
@@ -1428,9 +1344,9 @@ export declare const actionZoomToFitSelection: {
1428
1344
  selectedElementsAreBeingDragged: boolean;
1429
1345
  shouldCacheIgnoreZoom: boolean;
1430
1346
  toast: {
1431
- message: string;
1432
- closable?: boolean | undefined;
1433
- duration?: number | undefined;
1347
+ message: React.ReactNode;
1348
+ closable?: boolean;
1349
+ duration?: number;
1434
1350
  } | null;
1435
1351
  zenModeEnabled: boolean;
1436
1352
  theme: import("@excalidraw/element/types").Theme;
@@ -1441,45 +1357,18 @@ export declare const actionZoomToFitSelection: {
1441
1357
  selectedGroupIds: {
1442
1358
  [groupId: string]: boolean;
1443
1359
  };
1444
- editingGroupId: string | null;
1360
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
1445
1361
  width: number;
1446
1362
  height: number;
1447
1363
  offsetTop: number;
1448
1364
  offsetLeft: number;
1449
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
1450
- collaborators: Map<import("../types").SocketId, Readonly<{
1451
- pointer?: import("../types").CollaboratorPointer | undefined;
1452
- button?: "up" | "down" | undefined;
1453
- selectedElementIds?: Readonly<{
1454
- [id: string]: true;
1455
- }> | undefined;
1456
- username?: string | null | undefined;
1457
- userState?: import("@excalidraw/common").UserIdleState | undefined;
1458
- color?: {
1459
- background: string;
1460
- stroke: string;
1461
- } | undefined;
1462
- avatarUrl?: string | undefined;
1463
- id?: string | undefined;
1464
- socketId?: import("../types").SocketId | undefined;
1465
- isCurrentUser?: boolean | undefined;
1466
- isInCall?: boolean | undefined;
1467
- isSpeaking?: boolean | undefined;
1468
- isMuted?: boolean | undefined;
1469
- }>>;
1365
+ fileHandle: FileSystemFileHandle | null;
1366
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
1470
1367
  stats: {
1471
1368
  open: boolean;
1472
1369
  panels: number;
1473
1370
  };
1474
- currentChartType: import("@excalidraw/element/types").ChartType;
1475
- pasteDialog: {
1476
- shown: false;
1477
- data: null;
1478
- } | {
1479
- shown: true;
1480
- data: import("../charts").Spreadsheet;
1481
- };
1482
- showHyperlinkPopup: false | "editor" | "info";
1371
+ showHyperlinkPopup: false | "info" | "editor";
1483
1372
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1484
1373
  snapLines: readonly import("../snapping").SnapLine[];
1485
1374
  originSnapOffset: {
@@ -1490,16 +1379,16 @@ export declare const actionZoomToFitSelection: {
1490
1379
  userToFollow: import("../types").UserToFollow | null;
1491
1380
  followedBy: Set<import("../types").SocketId>;
1492
1381
  isCropping: boolean;
1493
- croppingElementId: string | null;
1382
+ croppingElementId: ExcalidrawElement["id"] | null;
1494
1383
  searchMatches: Readonly<{
1495
- focusedId: string | null;
1384
+ focusedId: ExcalidrawElement["id"] | null;
1496
1385
  matches: readonly import("../types").SearchMatch[];
1497
1386
  }> | null;
1498
1387
  activeLockedId: string | null;
1499
1388
  lockedMultiSelections: {
1500
1389
  [groupId: string]: true;
1501
1390
  };
1502
- stylesPanelMode: "compact" | "full";
1391
+ bindMode: import("@excalidraw/element/types").BindMode;
1503
1392
  };
1504
1393
  captureUpdate: "EVENTUALLY";
1505
1394
  };
@@ -1515,7 +1404,7 @@ export declare const actionZoomToFit: {
1515
1404
  trackEvent: {
1516
1405
  category: "canvas";
1517
1406
  };
1518
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1407
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1519
1408
  appState: {
1520
1409
  scrollX: number;
1521
1410
  scrollY: number;
@@ -1529,18 +1418,24 @@ export declare const actionZoomToFit: {
1529
1418
  } | null;
1530
1419
  showWelcomeScreen: boolean;
1531
1420
  isLoading: boolean;
1532
- errorMessage: import("react").ReactNode;
1421
+ errorMessage: React.ReactNode;
1533
1422
  activeEmbeddable: {
1534
1423
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
1535
- state: "active" | "hover";
1424
+ state: "hover" | "active";
1536
1425
  } | null;
1537
1426
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
1538
1427
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1539
1428
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
1540
1429
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1541
1430
  isBindingEnabled: boolean;
1431
+ boxSelectionMode: import("../types").BoxSelectionMode;
1432
+ bindingPreference: "enabled" | "disabled";
1433
+ isMidpointSnappingEnabled: boolean;
1542
1434
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
1543
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1435
+ suggestedBinding: {
1436
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1437
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1438
+ } | null;
1544
1439
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
1545
1440
  frameRendering: {
1546
1441
  enabled: boolean;
@@ -1550,12 +1445,16 @@ export declare const actionZoomToFit: {
1550
1445
  };
1551
1446
  editingFrame: string | null;
1552
1447
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1553
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1448
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1554
1449
  activeTool: {
1555
1450
  lastActiveTool: import("../types").ActiveTool | null;
1556
1451
  locked: boolean;
1557
1452
  fromSelection: boolean;
1558
1453
  } & import("../types").ActiveTool;
1454
+ preferredSelectionTool: {
1455
+ type: "selection" | "lasso";
1456
+ initialized: boolean;
1457
+ };
1559
1458
  penMode: boolean;
1560
1459
  penDetected: boolean;
1561
1460
  exportBackground: boolean;
@@ -1564,230 +1463,48 @@ export declare const actionZoomToFit: {
1564
1463
  exportScale: number;
1565
1464
  currentItemStrokeColor: string;
1566
1465
  currentItemBackgroundColor: string;
1567
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1466
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
1568
1467
  currentItemStrokeWidth: number;
1569
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1468
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1570
1469
  currentItemRoughness: number;
1571
1470
  currentItemOpacity: number;
1572
- currentItemFontFamily: number;
1471
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1573
1472
  currentItemFontSize: number;
1574
- currentItemTextAlign: string;
1473
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
1575
1474
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1576
1475
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1577
- currentHoveredFontFamily: number | null;
1476
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
1578
1477
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1579
- currentItemArrowType: "round" | "sharp" | "elbow";
1478
+ currentItemArrowType: "sharp" | "round" | "elbow";
1580
1479
  viewBackgroundColor: string;
1581
1480
  cursorButton: "up" | "down";
1582
1481
  scrolledOutside: boolean;
1583
1482
  name: string | null;
1584
1483
  isResizing: boolean;
1585
1484
  isRotating: boolean;
1586
- openMenu: "canvas" | "shape" | null;
1587
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1485
+ openMenu: "canvas" | null;
1486
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1588
1487
  openSidebar: {
1589
- name: string;
1590
- tab?: string | undefined;
1488
+ name: import("../types").SidebarName;
1489
+ tab?: import("../types").SidebarTabName;
1591
1490
  } | null;
1592
- openDialog: {
1491
+ openDialog: null | {
1593
1492
  name: "imageExport" | "help" | "jsonExport";
1594
1493
  } | {
1595
1494
  name: "ttd";
1596
- tab: "mermaid" | "text-to-diagram";
1495
+ tab: "text-to-diagram" | "mermaid";
1597
1496
  } | {
1598
1497
  name: "commandPalette";
1498
+ } | {
1499
+ name: "settings";
1599
1500
  } | {
1600
1501
  name: "elementLinkSelector";
1601
- sourceElementId: string;
1602
- } | null;
1603
- defaultSidebarDockedPreference: boolean;
1604
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1605
- selectedElementIds: Readonly<{
1606
- [id: string]: true;
1607
- }>;
1608
- hoveredElementIds: Readonly<{
1609
- [id: string]: true;
1610
- }>;
1611
- previousSelectedElementIds: {
1612
- [id: string]: true;
1613
- };
1614
- selectedElementsAreBeingDragged: boolean;
1615
- shouldCacheIgnoreZoom: boolean;
1616
- toast: {
1617
- message: string;
1618
- closable?: boolean | undefined;
1619
- duration?: number | undefined;
1620
- } | null;
1621
- zenModeEnabled: boolean;
1622
- theme: import("@excalidraw/element/types").Theme;
1623
- gridSize: number;
1624
- gridStep: number;
1625
- gridModeEnabled: boolean;
1626
- viewModeEnabled: boolean;
1627
- selectedGroupIds: {
1628
- [groupId: string]: boolean;
1629
- };
1630
- editingGroupId: string | null;
1631
- width: number;
1632
- height: number;
1633
- offsetTop: number;
1634
- offsetLeft: number;
1635
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
1636
- collaborators: Map<import("../types").SocketId, Readonly<{
1637
- pointer?: import("../types").CollaboratorPointer | undefined;
1638
- button?: "up" | "down" | undefined;
1639
- selectedElementIds?: Readonly<{
1640
- [id: string]: true;
1641
- }> | undefined;
1642
- username?: string | null | undefined;
1643
- userState?: import("@excalidraw/common").UserIdleState | undefined;
1644
- color?: {
1645
- background: string;
1646
- stroke: string;
1647
- } | undefined;
1648
- avatarUrl?: string | undefined;
1649
- id?: string | undefined;
1650
- socketId?: import("../types").SocketId | undefined;
1651
- isCurrentUser?: boolean | undefined;
1652
- isInCall?: boolean | undefined;
1653
- isSpeaking?: boolean | undefined;
1654
- isMuted?: boolean | undefined;
1655
- }>>;
1656
- stats: {
1657
- open: boolean;
1658
- panels: number;
1659
- };
1660
- currentChartType: import("@excalidraw/element/types").ChartType;
1661
- pasteDialog: {
1662
- shown: false;
1663
- data: null;
1502
+ sourceElementId: ExcalidrawElement["id"];
1664
1503
  } | {
1665
- shown: true;
1504
+ name: "charts";
1666
1505
  data: import("../charts").Spreadsheet;
1506
+ rawText: string;
1667
1507
  };
1668
- showHyperlinkPopup: false | "editor" | "info";
1669
- selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1670
- snapLines: readonly import("../snapping").SnapLine[];
1671
- originSnapOffset: {
1672
- x: number;
1673
- y: number;
1674
- } | null;
1675
- objectsSnapModeEnabled: boolean;
1676
- userToFollow: import("../types").UserToFollow | null;
1677
- followedBy: Set<import("../types").SocketId>;
1678
- isCropping: boolean;
1679
- croppingElementId: string | null;
1680
- searchMatches: Readonly<{
1681
- focusedId: string | null;
1682
- matches: readonly import("../types").SearchMatch[];
1683
- }> | null;
1684
- activeLockedId: string | null;
1685
- lockedMultiSelections: {
1686
- [groupId: string]: true;
1687
- };
1688
- stylesPanelMode: "compact" | "full";
1689
- };
1690
- captureUpdate: "EVENTUALLY";
1691
- };
1692
- keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1693
- } & {
1694
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1695
- };
1696
- export declare const actionToggleTheme: {
1697
- name: "toggleTheme";
1698
- label: (_: readonly ExcalidrawElement[], appState: Readonly<AppState>) => "buttons.lightMode" | "buttons.darkMode";
1699
- keywords: string[];
1700
- icon: (appState: import("../types").UIAppState) => import("react/jsx-runtime").JSX.Element;
1701
- viewMode: true;
1702
- trackEvent: {
1703
- category: "canvas";
1704
- };
1705
- perform: (_: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: any) => {
1706
- appState: {
1707
- theme: any;
1708
- contextMenu: {
1709
- items: import("../components/ContextMenu").ContextMenuItems;
1710
- top: number;
1711
- left: number;
1712
- } | null;
1713
- showWelcomeScreen: boolean;
1714
- isLoading: boolean;
1715
- errorMessage: import("react").ReactNode;
1716
- activeEmbeddable: {
1717
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
1718
- state: "active" | "hover";
1719
- } | null;
1720
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
1721
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1722
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
1723
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1724
- isBindingEnabled: boolean;
1725
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
1726
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1727
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
1728
- frameRendering: {
1729
- enabled: boolean;
1730
- name: boolean;
1731
- outline: boolean;
1732
- clip: boolean;
1733
- };
1734
- editingFrame: string | null;
1735
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1736
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1737
- activeTool: {
1738
- lastActiveTool: import("../types").ActiveTool | null;
1739
- locked: boolean;
1740
- fromSelection: boolean;
1741
- } & import("../types").ActiveTool;
1742
- penMode: boolean;
1743
- penDetected: boolean;
1744
- exportBackground: boolean;
1745
- exportEmbedScene: boolean;
1746
- exportWithDarkMode: boolean;
1747
- exportScale: number;
1748
- currentItemStrokeColor: string;
1749
- currentItemBackgroundColor: string;
1750
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1751
- currentItemStrokeWidth: number;
1752
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1753
- currentItemRoughness: number;
1754
- currentItemOpacity: number;
1755
- currentItemFontFamily: number;
1756
- currentItemFontSize: number;
1757
- currentItemTextAlign: string;
1758
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1759
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1760
- currentHoveredFontFamily: number | null;
1761
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1762
- currentItemArrowType: "round" | "sharp" | "elbow";
1763
- viewBackgroundColor: string;
1764
- scrollX: number;
1765
- scrollY: number;
1766
- cursorButton: "up" | "down";
1767
- scrolledOutside: boolean;
1768
- name: string | null;
1769
- isResizing: boolean;
1770
- isRotating: boolean;
1771
- zoom: Readonly<{
1772
- value: import("../types").NormalizedZoomValue;
1773
- }>;
1774
- openMenu: "canvas" | "shape" | null;
1775
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1776
- openSidebar: {
1777
- name: string;
1778
- tab?: string | undefined;
1779
- } | null;
1780
- openDialog: {
1781
- name: "imageExport" | "help" | "jsonExport";
1782
- } | {
1783
- name: "ttd";
1784
- tab: "mermaid" | "text-to-diagram";
1785
- } | {
1786
- name: "commandPalette";
1787
- } | {
1788
- name: "elementLinkSelector";
1789
- sourceElementId: string;
1790
- } | null;
1791
1508
  defaultSidebarDockedPreference: boolean;
1792
1509
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1793
1510
  selectedElementIds: Readonly<{
@@ -1802,11 +1519,12 @@ export declare const actionToggleTheme: {
1802
1519
  selectedElementsAreBeingDragged: boolean;
1803
1520
  shouldCacheIgnoreZoom: boolean;
1804
1521
  toast: {
1805
- message: string;
1806
- closable?: boolean | undefined;
1807
- duration?: number | undefined;
1522
+ message: React.ReactNode;
1523
+ closable?: boolean;
1524
+ duration?: number;
1808
1525
  } | null;
1809
1526
  zenModeEnabled: boolean;
1527
+ theme: import("@excalidraw/element/types").Theme;
1810
1528
  gridSize: number;
1811
1529
  gridStep: number;
1812
1530
  gridModeEnabled: boolean;
@@ -1814,45 +1532,18 @@ export declare const actionToggleTheme: {
1814
1532
  selectedGroupIds: {
1815
1533
  [groupId: string]: boolean;
1816
1534
  };
1817
- editingGroupId: string | null;
1535
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
1818
1536
  width: number;
1819
1537
  height: number;
1820
1538
  offsetTop: number;
1821
1539
  offsetLeft: number;
1822
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
1823
- collaborators: Map<import("../types").SocketId, Readonly<{
1824
- pointer?: import("../types").CollaboratorPointer | undefined;
1825
- button?: "up" | "down" | undefined;
1826
- selectedElementIds?: Readonly<{
1827
- [id: string]: true;
1828
- }> | undefined;
1829
- username?: string | null | undefined;
1830
- userState?: import("@excalidraw/common").UserIdleState | undefined;
1831
- color?: {
1832
- background: string;
1833
- stroke: string;
1834
- } | undefined;
1835
- avatarUrl?: string | undefined;
1836
- id?: string | undefined;
1837
- socketId?: import("../types").SocketId | undefined;
1838
- isCurrentUser?: boolean | undefined;
1839
- isInCall?: boolean | undefined;
1840
- isSpeaking?: boolean | undefined;
1841
- isMuted?: boolean | undefined;
1842
- }>>;
1540
+ fileHandle: FileSystemFileHandle | null;
1541
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
1843
1542
  stats: {
1844
1543
  open: boolean;
1845
1544
  panels: number;
1846
1545
  };
1847
- currentChartType: import("@excalidraw/element/types").ChartType;
1848
- pasteDialog: {
1849
- shown: false;
1850
- data: null;
1851
- } | {
1852
- shown: true;
1853
- data: import("../charts").Spreadsheet;
1854
- };
1855
- showHyperlinkPopup: false | "editor" | "info";
1546
+ showHyperlinkPopup: false | "info" | "editor";
1856
1547
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
1857
1548
  snapLines: readonly import("../snapping").SnapLine[];
1858
1549
  originSnapOffset: {
@@ -1863,31 +1554,33 @@ export declare const actionToggleTheme: {
1863
1554
  userToFollow: import("../types").UserToFollow | null;
1864
1555
  followedBy: Set<import("../types").SocketId>;
1865
1556
  isCropping: boolean;
1866
- croppingElementId: string | null;
1557
+ croppingElementId: ExcalidrawElement["id"] | null;
1867
1558
  searchMatches: Readonly<{
1868
- focusedId: string | null;
1559
+ focusedId: ExcalidrawElement["id"] | null;
1869
1560
  matches: readonly import("../types").SearchMatch[];
1870
1561
  }> | null;
1871
1562
  activeLockedId: string | null;
1872
1563
  lockedMultiSelections: {
1873
1564
  [groupId: string]: true;
1874
1565
  };
1875
- stylesPanelMode: "compact" | "full";
1566
+ bindMode: import("@excalidraw/element/types").BindMode;
1876
1567
  };
1877
1568
  captureUpdate: "EVENTUALLY";
1878
1569
  };
1879
1570
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
1880
- predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
1881
1571
  } & {
1882
1572
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
1883
1573
  };
1574
+ export declare const actionToggleTheme: import("./types").Action<import("@excalidraw/element/types").Theme> & {
1575
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
1576
+ };
1884
1577
  export declare const actionToggleEraserTool: {
1885
1578
  name: "toggleEraserTool";
1886
1579
  label: string;
1887
1580
  trackEvent: {
1888
1581
  category: "toolbar";
1889
1582
  };
1890
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1583
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
1891
1584
  appState: {
1892
1585
  selectedElementIds: {};
1893
1586
  selectedGroupIds: {};
@@ -1904,14 +1597,20 @@ export declare const actionToggleEraserTool: {
1904
1597
  } | null;
1905
1598
  showWelcomeScreen: boolean;
1906
1599
  isLoading: boolean;
1907
- errorMessage: import("react").ReactNode;
1600
+ errorMessage: React.ReactNode;
1908
1601
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
1909
1602
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1910
1603
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
1911
1604
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1912
1605
  isBindingEnabled: boolean;
1606
+ boxSelectionMode: import("../types").BoxSelectionMode;
1607
+ bindingPreference: "enabled" | "disabled";
1608
+ isMidpointSnappingEnabled: boolean;
1913
1609
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
1914
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1610
+ suggestedBinding: {
1611
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1612
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1613
+ } | null;
1915
1614
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
1916
1615
  frameRendering: {
1917
1616
  enabled: boolean;
@@ -1921,7 +1620,11 @@ export declare const actionToggleEraserTool: {
1921
1620
  };
1922
1621
  editingFrame: string | null;
1923
1622
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
1924
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1623
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1624
+ preferredSelectionTool: {
1625
+ type: "selection" | "lasso";
1626
+ initialized: boolean;
1627
+ };
1925
1628
  penMode: boolean;
1926
1629
  penDetected: boolean;
1927
1630
  exportBackground: boolean;
@@ -1930,19 +1633,19 @@ export declare const actionToggleEraserTool: {
1930
1633
  exportScale: number;
1931
1634
  currentItemStrokeColor: string;
1932
1635
  currentItemBackgroundColor: string;
1933
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1636
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
1934
1637
  currentItemStrokeWidth: number;
1935
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1638
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
1936
1639
  currentItemRoughness: number;
1937
1640
  currentItemOpacity: number;
1938
- currentItemFontFamily: number;
1641
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
1939
1642
  currentItemFontSize: number;
1940
- currentItemTextAlign: string;
1643
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
1941
1644
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1942
1645
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
1943
- currentHoveredFontFamily: number | null;
1646
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
1944
1647
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
1945
- currentItemArrowType: "round" | "sharp" | "elbow";
1648
+ currentItemArrowType: "sharp" | "round" | "elbow";
1946
1649
  viewBackgroundColor: string;
1947
1650
  scrollX: number;
1948
1651
  scrollY: number;
@@ -1951,26 +1654,30 @@ export declare const actionToggleEraserTool: {
1951
1654
  name: string | null;
1952
1655
  isResizing: boolean;
1953
1656
  isRotating: boolean;
1954
- zoom: Readonly<{
1955
- value: import("../types").NormalizedZoomValue;
1956
- }>;
1957
- openMenu: "canvas" | "shape" | null;
1958
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1657
+ zoom: import("../types").Zoom;
1658
+ openMenu: "canvas" | null;
1659
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1959
1660
  openSidebar: {
1960
- name: string;
1961
- tab?: string | undefined;
1661
+ name: import("../types").SidebarName;
1662
+ tab?: import("../types").SidebarTabName;
1962
1663
  } | null;
1963
- openDialog: {
1664
+ openDialog: null | {
1964
1665
  name: "imageExport" | "help" | "jsonExport";
1965
1666
  } | {
1966
1667
  name: "ttd";
1967
- tab: "mermaid" | "text-to-diagram";
1668
+ tab: "text-to-diagram" | "mermaid";
1968
1669
  } | {
1969
1670
  name: "commandPalette";
1671
+ } | {
1672
+ name: "settings";
1970
1673
  } | {
1971
1674
  name: "elementLinkSelector";
1972
- sourceElementId: string;
1973
- } | null;
1675
+ sourceElementId: ExcalidrawElement["id"];
1676
+ } | {
1677
+ name: "charts";
1678
+ data: import("../charts").Spreadsheet;
1679
+ rawText: string;
1680
+ };
1974
1681
  defaultSidebarDockedPreference: boolean;
1975
1682
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
1976
1683
  hoveredElementIds: Readonly<{
@@ -1982,9 +1689,9 @@ export declare const actionToggleEraserTool: {
1982
1689
  selectedElementsAreBeingDragged: boolean;
1983
1690
  shouldCacheIgnoreZoom: boolean;
1984
1691
  toast: {
1985
- message: string;
1986
- closable?: boolean | undefined;
1987
- duration?: number | undefined;
1692
+ message: React.ReactNode;
1693
+ closable?: boolean;
1694
+ duration?: number;
1988
1695
  } | null;
1989
1696
  zenModeEnabled: boolean;
1990
1697
  theme: import("@excalidraw/element/types").Theme;
@@ -1992,45 +1699,18 @@ export declare const actionToggleEraserTool: {
1992
1699
  gridStep: number;
1993
1700
  gridModeEnabled: boolean;
1994
1701
  viewModeEnabled: boolean;
1995
- editingGroupId: string | null;
1702
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
1996
1703
  width: number;
1997
1704
  height: number;
1998
1705
  offsetTop: number;
1999
1706
  offsetLeft: number;
2000
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
2001
- collaborators: Map<import("../types").SocketId, Readonly<{
2002
- pointer?: import("../types").CollaboratorPointer | undefined;
2003
- button?: "up" | "down" | undefined;
2004
- selectedElementIds?: Readonly<{
2005
- [id: string]: true;
2006
- }> | undefined;
2007
- username?: string | null | undefined;
2008
- userState?: import("@excalidraw/common").UserIdleState | undefined;
2009
- color?: {
2010
- background: string;
2011
- stroke: string;
2012
- } | undefined;
2013
- avatarUrl?: string | undefined;
2014
- id?: string | undefined;
2015
- socketId?: import("../types").SocketId | undefined;
2016
- isCurrentUser?: boolean | undefined;
2017
- isInCall?: boolean | undefined;
2018
- isSpeaking?: boolean | undefined;
2019
- isMuted?: boolean | undefined;
2020
- }>>;
1707
+ fileHandle: FileSystemFileHandle | null;
1708
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
2021
1709
  stats: {
2022
1710
  open: boolean;
2023
1711
  panels: number;
2024
1712
  };
2025
- currentChartType: import("@excalidraw/element/types").ChartType;
2026
- pasteDialog: {
2027
- shown: false;
2028
- data: null;
2029
- } | {
2030
- shown: true;
2031
- data: import("../charts").Spreadsheet;
2032
- };
2033
- showHyperlinkPopup: false | "editor" | "info";
1713
+ showHyperlinkPopup: false | "info" | "editor";
2034
1714
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
2035
1715
  snapLines: readonly import("../snapping").SnapLine[];
2036
1716
  originSnapOffset: {
@@ -2041,16 +1721,16 @@ export declare const actionToggleEraserTool: {
2041
1721
  userToFollow: import("../types").UserToFollow | null;
2042
1722
  followedBy: Set<import("../types").SocketId>;
2043
1723
  isCropping: boolean;
2044
- croppingElementId: string | null;
1724
+ croppingElementId: ExcalidrawElement["id"] | null;
2045
1725
  searchMatches: Readonly<{
2046
- focusedId: string | null;
1726
+ focusedId: ExcalidrawElement["id"] | null;
2047
1727
  matches: readonly import("../types").SearchMatch[];
2048
1728
  }> | null;
2049
1729
  activeLockedId: string | null;
2050
1730
  lockedMultiSelections: {
2051
1731
  [groupId: string]: true;
2052
1732
  };
2053
- stylesPanelMode: "compact" | "full";
1733
+ bindMode: import("@excalidraw/element/types").BindMode;
2054
1734
  };
2055
1735
  captureUpdate: "IMMEDIATELY";
2056
1736
  };
@@ -2066,7 +1746,7 @@ export declare const actionToggleLassoTool: {
2066
1746
  category: "toolbar";
2067
1747
  };
2068
1748
  predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
2069
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1749
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
2070
1750
  appState: {
2071
1751
  selectedElementIds: {};
2072
1752
  selectedGroupIds: {};
@@ -2083,14 +1763,20 @@ export declare const actionToggleLassoTool: {
2083
1763
  } | null;
2084
1764
  showWelcomeScreen: boolean;
2085
1765
  isLoading: boolean;
2086
- errorMessage: import("react").ReactNode;
1766
+ errorMessage: React.ReactNode;
2087
1767
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
2088
1768
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
2089
1769
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
2090
1770
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
2091
1771
  isBindingEnabled: boolean;
1772
+ boxSelectionMode: import("../types").BoxSelectionMode;
1773
+ bindingPreference: "enabled" | "disabled";
1774
+ isMidpointSnappingEnabled: boolean;
2092
1775
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
2093
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1776
+ suggestedBinding: {
1777
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1778
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1779
+ } | null;
2094
1780
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
2095
1781
  frameRendering: {
2096
1782
  enabled: boolean;
@@ -2100,7 +1786,11 @@ export declare const actionToggleLassoTool: {
2100
1786
  };
2101
1787
  editingFrame: string | null;
2102
1788
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
2103
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1789
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1790
+ preferredSelectionTool: {
1791
+ type: "selection" | "lasso";
1792
+ initialized: boolean;
1793
+ };
2104
1794
  penMode: boolean;
2105
1795
  penDetected: boolean;
2106
1796
  exportBackground: boolean;
@@ -2109,19 +1799,19 @@ export declare const actionToggleLassoTool: {
2109
1799
  exportScale: number;
2110
1800
  currentItemStrokeColor: string;
2111
1801
  currentItemBackgroundColor: string;
2112
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1802
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
2113
1803
  currentItemStrokeWidth: number;
2114
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1804
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
2115
1805
  currentItemRoughness: number;
2116
1806
  currentItemOpacity: number;
2117
- currentItemFontFamily: number;
1807
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
2118
1808
  currentItemFontSize: number;
2119
- currentItemTextAlign: string;
1809
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
2120
1810
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
2121
1811
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
2122
- currentHoveredFontFamily: number | null;
1812
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
2123
1813
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
2124
- currentItemArrowType: "round" | "sharp" | "elbow";
1814
+ currentItemArrowType: "sharp" | "round" | "elbow";
2125
1815
  viewBackgroundColor: string;
2126
1816
  scrollX: number;
2127
1817
  scrollY: number;
@@ -2130,26 +1820,30 @@ export declare const actionToggleLassoTool: {
2130
1820
  name: string | null;
2131
1821
  isResizing: boolean;
2132
1822
  isRotating: boolean;
2133
- zoom: Readonly<{
2134
- value: import("../types").NormalizedZoomValue;
2135
- }>;
2136
- openMenu: "canvas" | "shape" | null;
2137
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1823
+ zoom: import("../types").Zoom;
1824
+ openMenu: "canvas" | null;
1825
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
2138
1826
  openSidebar: {
2139
- name: string;
2140
- tab?: string | undefined;
1827
+ name: import("../types").SidebarName;
1828
+ tab?: import("../types").SidebarTabName;
2141
1829
  } | null;
2142
- openDialog: {
1830
+ openDialog: null | {
2143
1831
  name: "imageExport" | "help" | "jsonExport";
2144
1832
  } | {
2145
1833
  name: "ttd";
2146
- tab: "mermaid" | "text-to-diagram";
1834
+ tab: "text-to-diagram" | "mermaid";
2147
1835
  } | {
2148
1836
  name: "commandPalette";
1837
+ } | {
1838
+ name: "settings";
2149
1839
  } | {
2150
1840
  name: "elementLinkSelector";
2151
- sourceElementId: string;
2152
- } | null;
1841
+ sourceElementId: ExcalidrawElement["id"];
1842
+ } | {
1843
+ name: "charts";
1844
+ data: import("../charts").Spreadsheet;
1845
+ rawText: string;
1846
+ };
2153
1847
  defaultSidebarDockedPreference: boolean;
2154
1848
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
2155
1849
  hoveredElementIds: Readonly<{
@@ -2161,9 +1855,9 @@ export declare const actionToggleLassoTool: {
2161
1855
  selectedElementsAreBeingDragged: boolean;
2162
1856
  shouldCacheIgnoreZoom: boolean;
2163
1857
  toast: {
2164
- message: string;
2165
- closable?: boolean | undefined;
2166
- duration?: number | undefined;
1858
+ message: React.ReactNode;
1859
+ closable?: boolean;
1860
+ duration?: number;
2167
1861
  } | null;
2168
1862
  zenModeEnabled: boolean;
2169
1863
  theme: import("@excalidraw/element/types").Theme;
@@ -2171,45 +1865,18 @@ export declare const actionToggleLassoTool: {
2171
1865
  gridStep: number;
2172
1866
  gridModeEnabled: boolean;
2173
1867
  viewModeEnabled: boolean;
2174
- editingGroupId: string | null;
1868
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
2175
1869
  width: number;
2176
1870
  height: number;
2177
1871
  offsetTop: number;
2178
1872
  offsetLeft: number;
2179
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
2180
- collaborators: Map<import("../types").SocketId, Readonly<{
2181
- pointer?: import("../types").CollaboratorPointer | undefined;
2182
- button?: "up" | "down" | undefined;
2183
- selectedElementIds?: Readonly<{
2184
- [id: string]: true;
2185
- }> | undefined;
2186
- username?: string | null | undefined;
2187
- userState?: import("@excalidraw/common").UserIdleState | undefined;
2188
- color?: {
2189
- background: string;
2190
- stroke: string;
2191
- } | undefined;
2192
- avatarUrl?: string | undefined;
2193
- id?: string | undefined;
2194
- socketId?: import("../types").SocketId | undefined;
2195
- isCurrentUser?: boolean | undefined;
2196
- isInCall?: boolean | undefined;
2197
- isSpeaking?: boolean | undefined;
2198
- isMuted?: boolean | undefined;
2199
- }>>;
1873
+ fileHandle: FileSystemFileHandle | null;
1874
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
2200
1875
  stats: {
2201
1876
  open: boolean;
2202
1877
  panels: number;
2203
1878
  };
2204
- currentChartType: import("@excalidraw/element/types").ChartType;
2205
- pasteDialog: {
2206
- shown: false;
2207
- data: null;
2208
- } | {
2209
- shown: true;
2210
- data: import("../charts").Spreadsheet;
2211
- };
2212
- showHyperlinkPopup: false | "editor" | "info";
1879
+ showHyperlinkPopup: false | "info" | "editor";
2213
1880
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
2214
1881
  snapLines: readonly import("../snapping").SnapLine[];
2215
1882
  originSnapOffset: {
@@ -2220,16 +1887,16 @@ export declare const actionToggleLassoTool: {
2220
1887
  userToFollow: import("../types").UserToFollow | null;
2221
1888
  followedBy: Set<import("../types").SocketId>;
2222
1889
  isCropping: boolean;
2223
- croppingElementId: string | null;
1890
+ croppingElementId: ExcalidrawElement["id"] | null;
2224
1891
  searchMatches: Readonly<{
2225
- focusedId: string | null;
1892
+ focusedId: ExcalidrawElement["id"] | null;
2226
1893
  matches: readonly import("../types").SearchMatch[];
2227
1894
  }> | null;
2228
1895
  activeLockedId: string | null;
2229
1896
  lockedMultiSelections: {
2230
1897
  [groupId: string]: true;
2231
1898
  };
2232
- stylesPanelMode: "compact" | "full";
1899
+ bindMode: import("@excalidraw/element/types").BindMode;
2233
1900
  };
2234
1901
  captureUpdate: "NEVER";
2235
1902
  };
@@ -2244,7 +1911,7 @@ export declare const actionToggleHandTool: {
2244
1911
  };
2245
1912
  icon: import("react/jsx-runtime").JSX.Element;
2246
1913
  viewMode: false;
2247
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
1914
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => {
2248
1915
  appState: {
2249
1916
  selectedElementIds: {};
2250
1917
  selectedGroupIds: {};
@@ -2261,14 +1928,20 @@ export declare const actionToggleHandTool: {
2261
1928
  } | null;
2262
1929
  showWelcomeScreen: boolean;
2263
1930
  isLoading: boolean;
2264
- errorMessage: import("react").ReactNode;
1931
+ errorMessage: React.ReactNode;
2265
1932
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
2266
1933
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
2267
1934
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
2268
1935
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
2269
1936
  isBindingEnabled: boolean;
1937
+ boxSelectionMode: import("../types").BoxSelectionMode;
1938
+ bindingPreference: "enabled" | "disabled";
1939
+ isMidpointSnappingEnabled: boolean;
2270
1940
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
2271
- suggestedBindings: import("@excalidraw/element").SuggestedBinding[];
1941
+ suggestedBinding: {
1942
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
1943
+ midPoint?: import("@excalidraw/math").GlobalPoint;
1944
+ } | null;
2272
1945
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
2273
1946
  frameRendering: {
2274
1947
  enabled: boolean;
@@ -2278,7 +1951,11 @@ export declare const actionToggleHandTool: {
2278
1951
  };
2279
1952
  editingFrame: string | null;
2280
1953
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
2281
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
1954
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
1955
+ preferredSelectionTool: {
1956
+ type: "selection" | "lasso";
1957
+ initialized: boolean;
1958
+ };
2282
1959
  penMode: boolean;
2283
1960
  penDetected: boolean;
2284
1961
  exportBackground: boolean;
@@ -2287,19 +1964,19 @@ export declare const actionToggleHandTool: {
2287
1964
  exportScale: number;
2288
1965
  currentItemStrokeColor: string;
2289
1966
  currentItemBackgroundColor: string;
2290
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
1967
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
2291
1968
  currentItemStrokeWidth: number;
2292
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
1969
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
2293
1970
  currentItemRoughness: number;
2294
1971
  currentItemOpacity: number;
2295
- currentItemFontFamily: number;
1972
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
2296
1973
  currentItemFontSize: number;
2297
- currentItemTextAlign: string;
1974
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
2298
1975
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
2299
1976
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
2300
- currentHoveredFontFamily: number | null;
1977
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
2301
1978
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
2302
- currentItemArrowType: "round" | "sharp" | "elbow";
1979
+ currentItemArrowType: "sharp" | "round" | "elbow";
2303
1980
  viewBackgroundColor: string;
2304
1981
  scrollX: number;
2305
1982
  scrollY: number;
@@ -2308,26 +1985,30 @@ export declare const actionToggleHandTool: {
2308
1985
  name: string | null;
2309
1986
  isResizing: boolean;
2310
1987
  isRotating: boolean;
2311
- zoom: Readonly<{
2312
- value: import("../types").NormalizedZoomValue;
2313
- }>;
2314
- openMenu: "canvas" | "shape" | null;
2315
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
1988
+ zoom: import("../types").Zoom;
1989
+ openMenu: "canvas" | null;
1990
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
2316
1991
  openSidebar: {
2317
- name: string;
2318
- tab?: string | undefined;
1992
+ name: import("../types").SidebarName;
1993
+ tab?: import("../types").SidebarTabName;
2319
1994
  } | null;
2320
- openDialog: {
1995
+ openDialog: null | {
2321
1996
  name: "imageExport" | "help" | "jsonExport";
2322
1997
  } | {
2323
1998
  name: "ttd";
2324
- tab: "mermaid" | "text-to-diagram";
1999
+ tab: "text-to-diagram" | "mermaid";
2325
2000
  } | {
2326
2001
  name: "commandPalette";
2002
+ } | {
2003
+ name: "settings";
2327
2004
  } | {
2328
2005
  name: "elementLinkSelector";
2329
- sourceElementId: string;
2330
- } | null;
2006
+ sourceElementId: ExcalidrawElement["id"];
2007
+ } | {
2008
+ name: "charts";
2009
+ data: import("../charts").Spreadsheet;
2010
+ rawText: string;
2011
+ };
2331
2012
  defaultSidebarDockedPreference: boolean;
2332
2013
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
2333
2014
  hoveredElementIds: Readonly<{
@@ -2339,9 +2020,9 @@ export declare const actionToggleHandTool: {
2339
2020
  selectedElementsAreBeingDragged: boolean;
2340
2021
  shouldCacheIgnoreZoom: boolean;
2341
2022
  toast: {
2342
- message: string;
2343
- closable?: boolean | undefined;
2344
- duration?: number | undefined;
2023
+ message: React.ReactNode;
2024
+ closable?: boolean;
2025
+ duration?: number;
2345
2026
  } | null;
2346
2027
  zenModeEnabled: boolean;
2347
2028
  theme: import("@excalidraw/element/types").Theme;
@@ -2349,45 +2030,18 @@ export declare const actionToggleHandTool: {
2349
2030
  gridStep: number;
2350
2031
  gridModeEnabled: boolean;
2351
2032
  viewModeEnabled: boolean;
2352
- editingGroupId: string | null;
2033
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
2353
2034
  width: number;
2354
2035
  height: number;
2355
2036
  offsetTop: number;
2356
2037
  offsetLeft: number;
2357
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
2358
- collaborators: Map<import("../types").SocketId, Readonly<{
2359
- pointer?: import("../types").CollaboratorPointer | undefined;
2360
- button?: "up" | "down" | undefined;
2361
- selectedElementIds?: Readonly<{
2362
- [id: string]: true;
2363
- }> | undefined;
2364
- username?: string | null | undefined;
2365
- userState?: import("@excalidraw/common").UserIdleState | undefined;
2366
- color?: {
2367
- background: string;
2368
- stroke: string;
2369
- } | undefined;
2370
- avatarUrl?: string | undefined;
2371
- id?: string | undefined;
2372
- socketId?: import("../types").SocketId | undefined;
2373
- isCurrentUser?: boolean | undefined;
2374
- isInCall?: boolean | undefined;
2375
- isSpeaking?: boolean | undefined;
2376
- isMuted?: boolean | undefined;
2377
- }>>;
2038
+ fileHandle: FileSystemFileHandle | null;
2039
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
2378
2040
  stats: {
2379
2041
  open: boolean;
2380
2042
  panels: number;
2381
2043
  };
2382
- currentChartType: import("@excalidraw/element/types").ChartType;
2383
- pasteDialog: {
2384
- shown: false;
2385
- data: null;
2386
- } | {
2387
- shown: true;
2388
- data: import("../charts").Spreadsheet;
2389
- };
2390
- showHyperlinkPopup: false | "editor" | "info";
2044
+ showHyperlinkPopup: false | "info" | "editor";
2391
2045
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
2392
2046
  snapLines: readonly import("../snapping").SnapLine[];
2393
2047
  originSnapOffset: {
@@ -2398,16 +2052,16 @@ export declare const actionToggleHandTool: {
2398
2052
  userToFollow: import("../types").UserToFollow | null;
2399
2053
  followedBy: Set<import("../types").SocketId>;
2400
2054
  isCropping: boolean;
2401
- croppingElementId: string | null;
2055
+ croppingElementId: ExcalidrawElement["id"] | null;
2402
2056
  searchMatches: Readonly<{
2403
- focusedId: string | null;
2057
+ focusedId: ExcalidrawElement["id"] | null;
2404
2058
  matches: readonly import("../types").SearchMatch[];
2405
2059
  }> | null;
2406
2060
  activeLockedId: string | null;
2407
2061
  lockedMultiSelections: {
2408
2062
  [groupId: string]: true;
2409
2063
  };
2410
- stylesPanelMode: "compact" | "full";
2064
+ bindMode: import("@excalidraw/element/types").BindMode;
2411
2065
  };
2412
2066
  captureUpdate: "IMMEDIATELY";
2413
2067
  };