@excalidraw/math 0.18.0-51ad895 → 0.18.0-51ca8ab

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 (277) hide show
  1. package/dist/dev/index.js +44 -10
  2. package/dist/dev/index.js.map +2 -2
  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 +26 -18
  9. package/dist/types/common/src/editorInterface.d.ts +1 -1
  10. package/dist/types/common/src/font-metadata.d.ts +1 -3
  11. package/dist/types/common/src/index.d.ts +4 -1
  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 +40 -76
  15. package/dist/types/common/src/versionedSnapshotStore.d.ts +17 -0
  16. package/dist/types/element/src/Scene.d.ts +10 -6
  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 +19 -12
  21. package/dist/types/element/src/bounds.d.ts +24 -17
  22. package/dist/types/element/src/collision.d.ts +4 -3
  23. package/dist/types/element/src/comparisons.d.ts +8 -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 +4 -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 +12 -7
  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 -0
  33. package/dist/types/element/src/linearElementEditor.d.ts +8 -4
  34. package/dist/types/element/src/mutateElement.d.ts +5 -1
  35. package/dist/types/element/src/newElement.d.ts +7 -6
  36. package/dist/types/element/src/renderElement.d.ts +0 -6
  37. package/dist/types/element/src/resizeElements.d.ts +10 -10
  38. package/dist/types/element/src/resizeTest.d.ts +1 -1
  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 +3 -23
  46. package/dist/types/element/src/typeChecks.d.ts +3 -4
  47. package/dist/types/element/src/types.d.ts +11 -2
  48. package/dist/types/element/src/utils.d.ts +9 -5
  49. package/dist/types/element/src/zindex.d.ts +1 -1
  50. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +152 -207
  51. package/dist/types/excalidraw/actions/actionAlign.d.ts +0 -1
  52. package/dist/types/excalidraw/actions/actionBoundText.d.ts +79 -116
  53. package/dist/types/excalidraw/actions/actionCanvas.d.ts +413 -977
  54. package/dist/types/excalidraw/actions/actionClipboard.d.ts +111 -148
  55. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +38 -57
  56. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +121 -178
  57. package/dist/types/excalidraw/actions/actionDeselect.d.ts +161 -0
  58. package/dist/types/excalidraw/actions/actionDistribute.d.ts +0 -1
  59. package/dist/types/excalidraw/actions/actionDuplicateSelection.d.ts +2 -3
  60. package/dist/types/excalidraw/actions/actionElementLink.d.ts +50 -73
  61. package/dist/types/excalidraw/actions/actionElementLock.d.ts +79 -116
  62. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +54 -73
  63. package/dist/types/excalidraw/actions/actionExport.d.ts +116 -469
  64. package/dist/types/excalidraw/actions/actionFinalize.d.ts +1 -2
  65. package/dist/types/excalidraw/actions/actionFlip.d.ts +0 -1
  66. package/dist/types/excalidraw/actions/actionFrame.d.ts +236 -344
  67. package/dist/types/excalidraw/actions/actionGroup.d.ts +83 -128
  68. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +122 -174
  69. package/dist/types/excalidraw/actions/actionLink.d.ts +56 -75
  70. package/dist/types/excalidraw/actions/actionMenu.d.ts +44 -67
  71. package/dist/types/excalidraw/actions/actionNavigate.d.ts +14 -17
  72. package/dist/types/excalidraw/actions/actionProperties.d.ts +104 -132
  73. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +41 -64
  74. package/dist/types/excalidraw/actions/actionStyles.d.ts +37 -55
  75. package/dist/types/excalidraw/actions/actionTextAutoResize.d.ts +4 -4
  76. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +174 -0
  77. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +54 -73
  78. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +174 -0
  79. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +54 -73
  80. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +44 -67
  81. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +53 -72
  82. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +54 -73
  83. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +54 -73
  84. package/dist/types/excalidraw/actions/actionZindex.d.ts +8 -9
  85. package/dist/types/excalidraw/actions/index.d.ts +4 -1
  86. package/dist/types/excalidraw/actions/manager.d.ts +1 -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 +1 -1
  90. package/dist/types/excalidraw/{animated-trail.d.ts → animatedTrail.d.ts} +4 -3
  91. package/dist/types/excalidraw/appState.d.ts +23 -19
  92. package/dist/types/excalidraw/charts/charts.bar.d.ts +2 -0
  93. package/dist/types/excalidraw/charts/charts.constants.d.ts +48 -0
  94. package/dist/types/excalidraw/charts/charts.helpers.d.ts +32 -0
  95. package/dist/types/excalidraw/charts/charts.line.d.ts +2 -0
  96. package/dist/types/excalidraw/charts/charts.parse.d.ts +10 -0
  97. package/dist/types/excalidraw/charts/charts.radar.d.ts +2 -0
  98. package/dist/types/excalidraw/charts/charts.types.d.ts +18 -0
  99. package/dist/types/excalidraw/charts/index.d.ts +7 -0
  100. package/dist/types/excalidraw/clipboard.d.ts +13 -38
  101. package/dist/types/excalidraw/components/Actions.d.ts +1 -1
  102. package/dist/types/excalidraw/components/ActiveConfirmDialog.d.ts +1 -1
  103. package/dist/types/excalidraw/components/App.d.ts +135 -79
  104. package/dist/types/excalidraw/components/AppStateObserver.d.ts +37 -0
  105. package/dist/types/excalidraw/components/Card.d.ts +1 -3
  106. package/dist/types/excalidraw/components/ColorPicker/ColorInput.d.ts +2 -4
  107. package/dist/types/excalidraw/components/ColorPicker/ColorPicker.d.ts +0 -1
  108. package/dist/types/excalidraw/components/ColorPicker/colorPickerUtils.d.ts +1 -2
  109. package/dist/types/excalidraw/components/ColorPicker/keyboardNavHandlers.d.ts +0 -1
  110. package/dist/types/excalidraw/components/CommandPalette/defaultCommandPaletteItems.d.ts +1 -2
  111. package/dist/types/excalidraw/components/CommandPalette/types.d.ts +1 -2
  112. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +3 -3
  113. package/dist/types/excalidraw/components/DarkModeToggle.d.ts +1 -1
  114. package/dist/types/excalidraw/components/DefaultSidebar.d.ts +9 -13
  115. package/dist/types/excalidraw/components/ElementLinkDialog.d.ts +1 -1
  116. package/dist/types/excalidraw/components/Ellipsify.d.ts +1 -2
  117. package/dist/types/excalidraw/components/ErrorDialog.d.ts +1 -1
  118. package/dist/types/excalidraw/components/EyeDropper.d.ts +1 -2
  119. package/dist/types/excalidraw/components/FilledButton.d.ts +1 -0
  120. package/dist/types/excalidraw/components/FontPicker/keyboardNavHandlers.d.ts +0 -1
  121. package/dist/types/excalidraw/components/HelpDialog.d.ts +1 -1
  122. package/dist/types/excalidraw/components/IconPicker.d.ts +14 -9
  123. package/dist/types/excalidraw/components/InlineIcon.d.ts +2 -2
  124. package/dist/types/excalidraw/components/Island.d.ts +7 -0
  125. package/dist/types/excalidraw/components/LibraryMenu.d.ts +1 -1
  126. package/dist/types/excalidraw/components/LibraryMenuControlButtons.d.ts +1 -1
  127. package/dist/types/excalidraw/components/LibraryMenuHeaderContent.d.ts +1 -2
  128. package/dist/types/excalidraw/components/LibraryUnit.d.ts +2 -3
  129. package/dist/types/excalidraw/components/LoadingMessage.d.ts +0 -1
  130. package/dist/types/excalidraw/components/MobileToolBar.d.ts +0 -1
  131. package/dist/types/excalidraw/components/Modal.d.ts +0 -1
  132. package/dist/types/excalidraw/components/OverwriteConfirm/OverwriteConfirm.d.ts +1 -1
  133. package/dist/types/excalidraw/components/OverwriteConfirm/OverwriteConfirmState.d.ts +1 -1
  134. package/dist/types/excalidraw/components/PasteChartDialog.d.ts +4 -5
  135. package/dist/types/excalidraw/components/PropertiesPopover.d.ts +1 -1
  136. package/dist/types/excalidraw/components/RadioGroup.d.ts +0 -1
  137. package/dist/types/excalidraw/components/RadioSelection.d.ts +4 -4
  138. package/dist/types/excalidraw/components/Range.d.ts +10 -4
  139. package/dist/types/excalidraw/components/SVGLayer.d.ts +1 -1
  140. package/dist/types/excalidraw/components/ScrollableList.d.ts +0 -1
  141. package/dist/types/excalidraw/components/SearchMenu.d.ts +1 -1
  142. package/dist/types/excalidraw/components/Sidebar/Sidebar.d.ts +16 -22
  143. package/dist/types/excalidraw/components/Sidebar/SidebarHeader.d.ts +1 -1
  144. package/dist/types/excalidraw/components/Sidebar/SidebarTab.d.ts +1 -2
  145. package/dist/types/excalidraw/components/Sidebar/SidebarTabTrigger.d.ts +1 -2
  146. package/dist/types/excalidraw/components/Sidebar/SidebarTabTriggers.d.ts +1 -2
  147. package/dist/types/excalidraw/components/Sidebar/SidebarTabs.d.ts +1 -2
  148. package/dist/types/excalidraw/components/Spinner.d.ts +4 -4
  149. package/dist/types/excalidraw/components/Stats/CanvasGrid.d.ts +0 -1
  150. package/dist/types/excalidraw/components/Stats/Collapsible.d.ts +0 -1
  151. package/dist/types/excalidraw/components/Stats/DragInput.d.ts +0 -1
  152. package/dist/types/excalidraw/components/Stats/index.d.ts +7 -8
  153. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatHistoryMenu.d.ts +15 -0
  154. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatInterface.d.ts +23 -0
  155. package/dist/types/excalidraw/components/TTDDialog/Chat/ChatMessage.d.ts +14 -0
  156. package/dist/types/excalidraw/components/TTDDialog/Chat/TTDChatPanel.d.ts +27 -0
  157. package/dist/types/excalidraw/components/TTDDialog/Chat/index.d.ts +3 -0
  158. package/dist/types/excalidraw/components/TTDDialog/Chat/useChatAgent.d.ts +8 -0
  159. package/dist/types/excalidraw/components/TTDDialog/CodeMirrorEditor.d.ts +11 -0
  160. package/dist/types/excalidraw/components/TTDDialog/MermaidToExcalidraw.d.ts +3 -2
  161. package/dist/types/excalidraw/components/TTDDialog/TTDContext.d.ts +13 -0
  162. package/dist/types/excalidraw/components/TTDDialog/TTDDialog.d.ts +12 -29
  163. package/dist/types/excalidraw/components/TTDDialog/TTDDialogInput.d.ts +3 -3
  164. package/dist/types/excalidraw/components/TTDDialog/TTDDialogOutput.d.ts +5 -2
  165. package/dist/types/excalidraw/components/TTDDialog/TTDDialogPanel.d.ts +13 -9
  166. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTab.d.ts +1 -2
  167. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTabTrigger.d.ts +1 -2
  168. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTabTriggers.d.ts +1 -2
  169. package/dist/types/excalidraw/components/TTDDialog/TTDPreviewPanel.d.ts +9 -0
  170. package/dist/types/excalidraw/components/TTDDialog/TTDWelcomeMessage.d.ts +1 -0
  171. package/dist/types/excalidraw/components/TTDDialog/TextToDiagram.d.ts +9 -0
  172. package/dist/types/excalidraw/components/TTDDialog/common.d.ts +16 -16
  173. package/dist/types/excalidraw/components/TTDDialog/hooks/useChatManagement.d.ts +13 -0
  174. package/dist/types/excalidraw/components/TTDDialog/hooks/useMermaidRenderer.d.ts +14 -0
  175. package/dist/types/excalidraw/components/TTDDialog/hooks/useTextGeneration.d.ts +7 -0
  176. package/dist/types/excalidraw/components/TTDDialog/mermaid-lang-lite.d.ts +2 -0
  177. package/dist/types/excalidraw/components/TTDDialog/types.d.ts +95 -0
  178. package/dist/types/excalidraw/components/TTDDialog/useTTDChatStorage.d.ts +22 -0
  179. package/dist/types/excalidraw/components/TTDDialog/utils/chat.d.ts +10 -0
  180. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidAutoFix.d.ts +1 -0
  181. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidError.d.ts +10 -0
  182. package/dist/types/excalidraw/components/TTDDialog/utils/mermaidValidation.d.ts +1 -0
  183. package/dist/types/excalidraw/components/Toast.d.ts +11 -7
  184. package/dist/types/excalidraw/components/Trans.d.ts +2 -2
  185. package/dist/types/excalidraw/components/canvases/InteractiveCanvas.d.ts +2 -1
  186. package/dist/types/excalidraw/components/canvases/NewElementCanvas.d.ts +1 -0
  187. package/dist/types/excalidraw/components/canvases/StaticCanvas.d.ts +1 -1
  188. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenu.d.ts +48 -38
  189. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuContent.d.ts +7 -6
  190. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuGroup.d.ts +3 -3
  191. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItem.d.ts +13 -22
  192. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCheckbox.d.ts +5 -0
  193. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContent.d.ts +5 -4
  194. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemContentRadio.d.ts +2 -2
  195. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCustom.d.ts +2 -2
  196. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemLink.d.ts +6 -6
  197. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSub.d.ts +23 -0
  198. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubContent.d.ts +8 -0
  199. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubTrigger.d.ts +12 -0
  200. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuTrigger.d.ts +3 -4
  201. package/dist/types/excalidraw/components/dropdownMenu/common.d.ts +2 -2
  202. package/dist/types/excalidraw/components/dropdownMenu/dropdownMenuUtils.d.ts +2 -0
  203. package/dist/types/excalidraw/components/hoc/withInternalFallback.d.ts +1 -1
  204. package/dist/types/excalidraw/components/hyperlink/helpers.d.ts +1 -1
  205. package/dist/types/excalidraw/components/icons.d.ts +41 -21
  206. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +24 -3
  207. package/dist/types/excalidraw/components/main-menu/MainMenu.d.ts +39 -32
  208. package/dist/types/excalidraw/components/shapes.d.ts +81 -1
  209. package/dist/types/excalidraw/data/blob.d.ts +330 -7
  210. package/dist/types/excalidraw/data/encode.d.ts +4 -4
  211. package/dist/types/excalidraw/data/encryption.d.ts +5 -5
  212. package/dist/types/excalidraw/data/filesystem.d.ts +5 -7
  213. package/dist/types/excalidraw/data/index.d.ts +4 -5
  214. package/dist/types/excalidraw/data/json.d.ts +172 -4
  215. package/dist/types/excalidraw/data/library.d.ts +25 -10
  216. package/dist/types/excalidraw/data/resave.d.ts +7 -2
  217. package/dist/types/excalidraw/data/restore.d.ts +25 -10
  218. package/dist/types/excalidraw/editor-jotai.d.ts +11 -11
  219. package/dist/types/excalidraw/eraser/index.d.ts +2 -3
  220. package/dist/types/excalidraw/errors.d.ts +14 -0
  221. package/dist/types/excalidraw/hooks/useLibraryItemSvg.d.ts +1 -1
  222. package/dist/types/excalidraw/hooks/useOutsideClick.d.ts +1 -2
  223. package/dist/types/excalidraw/hooks/useScrollPosition.d.ts +1 -2
  224. package/dist/types/excalidraw/i18n.d.ts +2 -2
  225. package/dist/types/excalidraw/{laser-trails.d.ts → laserTrails.d.ts} +5 -7
  226. package/dist/types/excalidraw/lasso/index.d.ts +2 -3
  227. package/dist/types/excalidraw/renderer/animation.d.ts +5 -1
  228. package/dist/types/excalidraw/renderer/helpers.d.ts +6 -4
  229. package/dist/types/excalidraw/renderer/interactiveScene.d.ts +8 -6
  230. package/dist/types/excalidraw/scene/Renderer.d.ts +428 -18
  231. package/dist/types/excalidraw/scene/export.d.ts +2 -2
  232. package/dist/types/excalidraw/scene/index.d.ts +2 -2
  233. package/dist/types/excalidraw/scene/types.d.ts +7 -2
  234. package/dist/types/excalidraw/snapping.d.ts +5 -5
  235. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-bindings.d.ts +1 -1
  236. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-loader.d.ts +1 -1
  237. package/dist/types/excalidraw/subset/harfbuzz/harfbuzz-wasm.d.ts +1 -1
  238. package/dist/types/excalidraw/subset/woff2/woff2-loader.d.ts +2 -2
  239. package/dist/types/excalidraw/subset/woff2/woff2-wasm.d.ts +1 -1
  240. package/dist/types/excalidraw/textAutoResizeHandle.d.ts +15 -0
  241. package/dist/types/excalidraw/types.d.ts +264 -25
  242. package/dist/types/excalidraw/viewport.d.ts +316 -0
  243. package/dist/types/excalidraw/wysiwyg/textWysiwyg.d.ts +7 -3
  244. package/dist/types/fractional-indexing/src/index.d.ts +29 -0
  245. package/dist/types/laser-pointer/src/index.d.ts +2 -0
  246. package/dist/types/laser-pointer/src/math.d.ts +16 -0
  247. package/dist/types/laser-pointer/src/simplify.d.ts +2 -0
  248. package/dist/types/laser-pointer/src/state.d.ts +35 -0
  249. package/dist/types/math/src/constants.d.ts +0 -1
  250. package/dist/types/math/src/curve.d.ts +4 -1
  251. package/dist/types/math/src/point.d.ts +8 -2
  252. package/dist/types/math/src/polygon.d.ts +2 -2
  253. package/dist/types/math/src/range.d.ts +1 -3
  254. package/dist/types/math/src/segment.d.ts +3 -3
  255. package/dist/types/math/src/types.d.ts +25 -1
  256. package/dist/types/utils/src/export.d.ts +5 -5
  257. package/dist/types/utils/src/index.d.ts +1 -2
  258. package/dist/types/utils/src/shape.d.ts +6 -6
  259. package/package.json +2 -2
  260. package/dist/types/common/src/visualdebug.d.ts +0 -41
  261. package/dist/types/excalidraw/animation-frame-handler.d.ts +0 -16
  262. package/dist/types/excalidraw/charts.d.ts +0 -27
  263. package/dist/types/excalidraw/components/DiagramToCodePlugin/DiagramToCodePlugin.d.ts +0 -4
  264. package/dist/types/excalidraw/components/ExcalidrawLogo.d.ts +0 -16
  265. package/dist/types/excalidraw/components/InitializeApp.d.ts +0 -10
  266. package/dist/types/excalidraw/components/TTDDialog/TTDDialogTrigger.d.ts +0 -8
  267. package/dist/types/excalidraw/components/footer/FooterCenter.d.ts +0 -8
  268. package/dist/types/excalidraw/components/live-collaboration/LiveCollaborationTrigger.d.ts +0 -22
  269. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.Center.d.ts +0 -58
  270. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.Hints.d.ts +0 -19
  271. package/dist/types/excalidraw/components/welcome-screen/WelcomeScreen.d.ts +0 -85
  272. package/dist/types/excalidraw/data/reconcile.d.ts +0 -7
  273. package/dist/types/excalidraw/index.d.ts +0 -46
  274. package/dist/types/excalidraw/polyfill.d.ts +0 -2
  275. package/dist/types/excalidraw/scene/scroll.d.ts +0 -23
  276. package/dist/types/utils/src/bbox.d.ts +0 -9
  277. package/dist/types/utils/src/withinBounds.d.ts +0 -19
@@ -1,18 +1,17 @@
1
- /// <reference types="react" />
2
- import type { Theme } from "@excalidraw/element/types";
1
+ import type { ExcalidrawElement, Theme } from "@excalidraw/element/types";
3
2
  import "../components/ToolIcon.scss";
4
- import type { AppState } from "../types";
3
+ import type { AppClassProperties, AppState, BinaryFiles, ExcalidrawProps } from "../types";
5
4
  export declare const actionChangeProjectName: import("./types").Action<string | null> & {
6
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
5
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
7
6
  };
8
7
  export declare const actionChangeExportScale: import("./types").Action<number> & {
9
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
8
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
10
9
  };
11
10
  export declare const actionChangeExportBackground: import("./types").Action<boolean> & {
12
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
11
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
13
12
  };
14
13
  export declare const actionChangeExportEmbedScene: import("./types").Action<boolean> & {
15
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
14
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
16
15
  };
17
16
  export declare const actionSaveToActiveFile: {
18
17
  name: "saveToActiveFile";
@@ -21,187 +20,22 @@ export declare const actionSaveToActiveFile: {
21
20
  trackEvent: {
22
21
  category: "export";
23
22
  };
24
- predicate: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
25
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: unknown, app: import("../types").AppClassProperties) => Promise<{
26
- captureUpdate: "EVENTUALLY";
23
+ predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: ExcalidrawProps, app: AppClassProperties) => boolean;
24
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: unknown, app: AppClassProperties) => Promise<false | {
25
+ captureUpdate: "NEVER";
27
26
  appState: {
28
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
27
+ fileHandle: FileSystemFileHandle | null;
29
28
  toast: {
30
29
  message: string;
31
- } | null;
32
- contextMenu: {
33
- items: import("../components/ContextMenu").ContextMenuItems;
34
- top: number;
35
- left: number;
36
- } | null;
37
- showWelcomeScreen: boolean;
38
- isLoading: boolean;
39
- errorMessage: import("react").ReactNode;
40
- activeEmbeddable: {
41
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
42
- state: "active" | "hover";
43
- } | null;
44
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
45
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
46
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
47
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
48
- isBindingEnabled: boolean;
49
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
50
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
51
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
52
- frameRendering: {
53
- enabled: boolean;
54
- name: boolean;
55
- outline: boolean;
56
- clip: boolean;
30
+ duration: number;
57
31
  };
58
- editingFrame: string | null;
59
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
60
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
61
- activeTool: {
62
- lastActiveTool: import("../types").ActiveTool | null;
63
- locked: boolean;
64
- fromSelection: boolean;
65
- } & import("../types").ActiveTool;
66
- preferredSelectionTool: {
67
- type: "selection" | "lasso";
68
- initialized: boolean;
69
- };
70
- penMode: boolean;
71
- penDetected: boolean;
72
- exportBackground: boolean;
73
- exportEmbedScene: boolean;
74
- exportWithDarkMode: boolean;
75
- exportScale: number;
76
- currentItemStrokeColor: string;
77
- currentItemBackgroundColor: string;
78
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
79
- currentItemStrokeWidth: number;
80
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
81
- currentItemRoughness: number;
82
- currentItemOpacity: number;
83
- currentItemFontFamily: number;
84
- currentItemFontSize: number;
85
- currentItemTextAlign: string;
86
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
87
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
88
- currentHoveredFontFamily: number | null;
89
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
90
- currentItemArrowType: "round" | "sharp" | "elbow";
91
- viewBackgroundColor: string;
92
- scrollX: number;
93
- scrollY: number;
94
- cursorButton: "up" | "down";
95
- scrolledOutside: boolean;
96
- name: string | null;
97
- isResizing: boolean;
98
- isRotating: boolean;
99
- zoom: Readonly<{
100
- value: import("../types").NormalizedZoomValue;
101
- }>;
102
- openMenu: "canvas" | null;
103
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
104
- openSidebar: {
105
- name: string;
106
- tab?: string | undefined;
107
- } | null;
108
- openDialog: {
109
- name: "imageExport" | "help" | "jsonExport";
110
- } | {
111
- name: "ttd";
112
- tab: "mermaid" | "text-to-diagram";
113
- } | {
114
- name: "commandPalette";
115
- } | {
116
- name: "settings";
117
- } | {
118
- name: "elementLinkSelector";
119
- sourceElementId: string;
120
- } | null;
121
- defaultSidebarDockedPreference: boolean;
122
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
123
- selectedElementIds: Readonly<{
124
- [id: string]: true;
125
- }>;
126
- hoveredElementIds: Readonly<{
127
- [id: string]: true;
128
- }>;
129
- previousSelectedElementIds: {
130
- [id: string]: true;
131
- };
132
- selectedElementsAreBeingDragged: boolean;
133
- shouldCacheIgnoreZoom: boolean;
134
- zenModeEnabled: boolean;
135
- theme: Theme;
136
- gridSize: number;
137
- gridStep: number;
138
- gridModeEnabled: boolean;
139
- viewModeEnabled: boolean;
140
- selectedGroupIds: {
141
- [groupId: string]: boolean;
142
- };
143
- editingGroupId: string | null;
144
- width: number;
145
- height: number;
146
- offsetTop: number;
147
- offsetLeft: number;
148
- collaborators: Map<import("../types").SocketId, Readonly<{
149
- pointer?: import("../types").CollaboratorPointer | undefined;
150
- button?: "up" | "down" | undefined;
151
- selectedElementIds?: Readonly<{
152
- [id: string]: true;
153
- }> | undefined;
154
- username?: string | null | undefined;
155
- userState?: import("@excalidraw/common").UserIdleState | undefined;
156
- color?: {
157
- background: string;
158
- stroke: string;
159
- } | undefined;
160
- avatarUrl?: string | undefined;
161
- id?: string | undefined;
162
- socketId?: import("../types").SocketId | undefined;
163
- isCurrentUser?: boolean | undefined;
164
- isInCall?: boolean | undefined;
165
- isSpeaking?: boolean | undefined;
166
- isMuted?: boolean | undefined;
167
- }>>;
168
- stats: {
169
- open: boolean;
170
- panels: number;
171
- };
172
- currentChartType: import("@excalidraw/element/types").ChartType;
173
- pasteDialog: {
174
- shown: false;
175
- data: null;
176
- } | {
177
- shown: true;
178
- data: import("../charts").Spreadsheet;
179
- };
180
- showHyperlinkPopup: false | "info" | "editor";
181
- selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
182
- snapLines: readonly import("../snapping").SnapLine[];
183
- originSnapOffset: {
184
- x: number;
185
- y: number;
186
- } | null;
187
- objectsSnapModeEnabled: boolean;
188
- userToFollow: import("../types").UserToFollow | null;
189
- followedBy: Set<import("../types").SocketId>;
190
- isCropping: boolean;
191
- croppingElementId: string | null;
192
- searchMatches: Readonly<{
193
- focusedId: string | null;
194
- matches: readonly import("../types").SearchMatch[];
195
- }> | null;
196
- activeLockedId: string | null;
197
- lockedMultiSelections: {
198
- [groupId: string]: true;
199
- };
200
- bindMode: import("@excalidraw/element/types").BindMode;
201
32
  };
202
33
  } | {
203
- captureUpdate: "EVENTUALLY";
204
- appState?: undefined;
34
+ captureUpdate: "NEVER";
35
+ appState: {
36
+ toast: null;
37
+ fileHandle?: undefined;
38
+ };
205
39
  }>;
206
40
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
207
41
  } & {
@@ -215,174 +49,23 @@ export declare const actionSaveFileToDisk: {
215
49
  trackEvent: {
216
50
  category: "export";
217
51
  };
218
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: unknown, app: import("../types").AppClassProperties) => Promise<{
219
- captureUpdate: "EVENTUALLY";
52
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, value: unknown, app: AppClassProperties) => Promise<false | {
53
+ captureUpdate: "NEVER";
220
54
  appState: {
221
55
  openDialog: null;
222
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
56
+ fileHandle: FileSystemFileHandle | null;
223
57
  toast: {
224
58
  message: string;
59
+ duration: number;
225
60
  };
226
- contextMenu: {
227
- items: import("../components/ContextMenu").ContextMenuItems;
228
- top: number;
229
- left: number;
230
- } | null;
231
- showWelcomeScreen: boolean;
232
- isLoading: boolean;
233
- errorMessage: import("react").ReactNode;
234
- activeEmbeddable: {
235
- element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
236
- state: "active" | "hover";
237
- } | null;
238
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
239
- resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
240
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
241
- selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
242
- isBindingEnabled: boolean;
243
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
244
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
245
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
246
- frameRendering: {
247
- enabled: boolean;
248
- name: boolean;
249
- outline: boolean;
250
- clip: boolean;
251
- };
252
- editingFrame: string | null;
253
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
254
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
255
- activeTool: {
256
- lastActiveTool: import("../types").ActiveTool | null;
257
- locked: boolean;
258
- fromSelection: boolean;
259
- } & import("../types").ActiveTool;
260
- preferredSelectionTool: {
261
- type: "selection" | "lasso";
262
- initialized: boolean;
263
- };
264
- penMode: boolean;
265
- penDetected: boolean;
266
- exportBackground: boolean;
267
- exportEmbedScene: boolean;
268
- exportWithDarkMode: boolean;
269
- exportScale: number;
270
- currentItemStrokeColor: string;
271
- currentItemBackgroundColor: string;
272
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
273
- currentItemStrokeWidth: number;
274
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
275
- currentItemRoughness: number;
276
- currentItemOpacity: number;
277
- currentItemFontFamily: number;
278
- currentItemFontSize: number;
279
- currentItemTextAlign: string;
280
- currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
281
- currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
282
- currentHoveredFontFamily: number | null;
283
- currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
284
- currentItemArrowType: "round" | "sharp" | "elbow";
285
- viewBackgroundColor: string;
286
- scrollX: number;
287
- scrollY: number;
288
- cursorButton: "up" | "down";
289
- scrolledOutside: boolean;
290
- name: string | null;
291
- isResizing: boolean;
292
- isRotating: boolean;
293
- zoom: Readonly<{
294
- value: import("../types").NormalizedZoomValue;
295
- }>;
296
- openMenu: "canvas" | null;
297
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
298
- openSidebar: {
299
- name: string;
300
- tab?: string | undefined;
301
- } | null;
302
- defaultSidebarDockedPreference: boolean;
303
- lastPointerDownWith: import("@excalidraw/element/types").PointerType;
304
- selectedElementIds: Readonly<{
305
- [id: string]: true;
306
- }>;
307
- hoveredElementIds: Readonly<{
308
- [id: string]: true;
309
- }>;
310
- previousSelectedElementIds: {
311
- [id: string]: true;
312
- };
313
- selectedElementsAreBeingDragged: boolean;
314
- shouldCacheIgnoreZoom: boolean;
315
- zenModeEnabled: boolean;
316
- theme: Theme;
317
- gridSize: number;
318
- gridStep: number;
319
- gridModeEnabled: boolean;
320
- viewModeEnabled: boolean;
321
- selectedGroupIds: {
322
- [groupId: string]: boolean;
323
- };
324
- editingGroupId: string | null;
325
- width: number;
326
- height: number;
327
- offsetTop: number;
328
- offsetLeft: number;
329
- collaborators: Map<import("../types").SocketId, Readonly<{
330
- pointer?: import("../types").CollaboratorPointer | undefined;
331
- button?: "up" | "down" | undefined;
332
- selectedElementIds?: Readonly<{
333
- [id: string]: true;
334
- }> | undefined;
335
- username?: string | null | undefined;
336
- userState?: import("@excalidraw/common").UserIdleState | undefined;
337
- color?: {
338
- background: string;
339
- stroke: string;
340
- } | undefined;
341
- avatarUrl?: string | undefined;
342
- id?: string | undefined;
343
- socketId?: import("../types").SocketId | undefined;
344
- isCurrentUser?: boolean | undefined;
345
- isInCall?: boolean | undefined;
346
- isSpeaking?: boolean | undefined;
347
- isMuted?: boolean | undefined;
348
- }>>;
349
- stats: {
350
- open: boolean;
351
- panels: number;
352
- };
353
- currentChartType: import("@excalidraw/element/types").ChartType;
354
- pasteDialog: {
355
- shown: false;
356
- data: null;
357
- } | {
358
- shown: true;
359
- data: import("../charts").Spreadsheet;
360
- };
361
- showHyperlinkPopup: false | "info" | "editor";
362
- selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
363
- snapLines: readonly import("../snapping").SnapLine[];
364
- originSnapOffset: {
365
- x: number;
366
- y: number;
367
- } | null;
368
- objectsSnapModeEnabled: boolean;
369
- userToFollow: import("../types").UserToFollow | null;
370
- followedBy: Set<import("../types").SocketId>;
371
- isCropping: boolean;
372
- croppingElementId: string | null;
373
- searchMatches: Readonly<{
374
- focusedId: string | null;
375
- matches: readonly import("../types").SearchMatch[];
376
- }> | null;
377
- activeLockedId: string | null;
378
- lockedMultiSelections: {
379
- [groupId: string]: true;
380
- };
381
- bindMode: import("@excalidraw/element/types").BindMode;
382
61
  };
383
62
  } | {
384
- captureUpdate: "EVENTUALLY";
385
- appState?: undefined;
63
+ captureUpdate: "NEVER";
64
+ appState: {
65
+ toast: null;
66
+ openDialog?: undefined;
67
+ fileHandle?: undefined;
68
+ };
386
69
  }>;
387
70
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
388
71
  PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => import("react/jsx-runtime").JSX.Element;
@@ -395,11 +78,12 @@ export declare const actionLoadScene: {
395
78
  trackEvent: {
396
79
  category: "export";
397
80
  };
398
- predicate: (elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
399
- perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: import("../types").AppClassProperties) => Promise<false | {
81
+ predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: ExcalidrawProps, app: AppClassProperties) => boolean;
82
+ perform: (elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[], appState: Readonly<AppState>, _: unknown, app: AppClassProperties) => Promise<false | {
400
83
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
401
84
  appState: {
402
85
  viewBackgroundColor: string;
86
+ theme: Theme;
403
87
  frameRendering: {
404
88
  enabled: boolean;
405
89
  name: boolean;
@@ -407,34 +91,40 @@ export declare const actionLoadScene: {
407
91
  clip: boolean;
408
92
  };
409
93
  name: string | null;
410
- zoom: Readonly<{
411
- value: import("../types").NormalizedZoomValue;
412
- }>;
94
+ zoom: import("../types").Zoom;
413
95
  scrollX: number;
414
96
  scrollY: number;
415
97
  viewModeEnabled: boolean;
416
- openDialog: {
98
+ openDialog: null | {
417
99
  name: "imageExport" | "help" | "jsonExport";
418
100
  } | {
419
101
  name: "ttd";
420
- tab: "mermaid" | "text-to-diagram";
102
+ tab: "text-to-diagram" | "mermaid";
421
103
  } | {
422
104
  name: "commandPalette";
423
105
  } | {
424
106
  name: "settings";
425
107
  } | {
426
108
  name: "elementLinkSelector";
427
- sourceElementId: string;
428
- } | null;
429
- editingGroupId: string | null;
109
+ sourceElementId: ExcalidrawElement["id"];
110
+ } | {
111
+ name: "charts";
112
+ data: import("../charts").Spreadsheet;
113
+ rawText: string;
114
+ };
115
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
430
116
  selectedElementIds: Readonly<{
431
117
  [id: string]: true;
432
118
  }>;
433
119
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
434
- theme: Theme;
120
+ activeTool: {
121
+ lastActiveTool: import("../types").ActiveTool | null;
122
+ locked: boolean;
123
+ fromSelection: boolean;
124
+ } & import("../types").ActiveTool;
435
125
  activeEmbeddable: {
436
126
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
437
- state: "active" | "hover";
127
+ state: "hover" | "active";
438
128
  } | null;
439
129
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
440
130
  selectedGroupIds: {
@@ -444,36 +134,21 @@ export declare const actionLoadScene: {
444
134
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
445
135
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
446
136
  isBindingEnabled: boolean;
447
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
137
+ isMidpointSnappingEnabled: boolean;
138
+ suggestedBinding: {
139
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
140
+ midPoint?: import("@excalidraw/math").GlobalPoint;
141
+ } | null;
448
142
  isRotating: boolean;
449
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
450
- collaborators: Map<import("../types").SocketId, Readonly<{
451
- pointer?: import("../types").CollaboratorPointer | undefined;
452
- button?: "up" | "down" | undefined;
453
- selectedElementIds?: Readonly<{
454
- [id: string]: true;
455
- }> | undefined;
456
- username?: string | null | undefined;
457
- userState?: import("@excalidraw/common").UserIdleState | undefined;
458
- color?: {
459
- background: string;
460
- stroke: string;
461
- } | undefined;
462
- avatarUrl?: string | undefined;
463
- id?: string | undefined;
464
- socketId?: import("../types").SocketId | undefined;
465
- isCurrentUser?: boolean | undefined;
466
- isInCall?: boolean | undefined;
467
- isSpeaking?: boolean | undefined;
468
- isMuted?: boolean | undefined;
469
- }>>;
143
+ elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
144
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
470
145
  snapLines: readonly import("../snapping").SnapLine[];
471
146
  zenModeEnabled: boolean;
472
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
147
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
473
148
  isCropping: boolean;
474
- croppingElementId: string | null;
149
+ croppingElementId: ExcalidrawElement["id"] | null;
475
150
  searchMatches: Readonly<{
476
- focusedId: string | null;
151
+ focusedId: ExcalidrawElement["id"] | null;
477
152
  matches: readonly import("../types").SearchMatch[];
478
153
  }> | null;
479
154
  activeLockedId: string | null;
@@ -482,6 +157,7 @@ export declare const actionLoadScene: {
482
157
  }>;
483
158
  shouldCacheIgnoreZoom: boolean;
484
159
  exportScale: number;
160
+ currentItemArrowType: "sharp" | "round" | "elbow";
485
161
  bindMode: import("@excalidraw/element/types").BindMode;
486
162
  gridSize: number;
487
163
  contextMenu: {
@@ -491,15 +167,11 @@ export declare const actionLoadScene: {
491
167
  } | null;
492
168
  showWelcomeScreen: boolean;
493
169
  isLoading: boolean;
494
- errorMessage: import("react").ReactNode;
170
+ errorMessage: React.ReactNode;
495
171
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
496
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
172
+ boxSelectionMode: import("../types").BoxSelectionMode;
173
+ bindingPreference: "enabled" | "disabled";
497
174
  editingFrame: string | null;
498
- activeTool: {
499
- lastActiveTool: import("../types").ActiveTool | null;
500
- locked: boolean;
501
- fromSelection: boolean;
502
- } & import("../types").ActiveTool;
503
175
  preferredSelectionTool: {
504
176
  type: "selection" | "lasso";
505
177
  initialized: boolean;
@@ -511,27 +183,28 @@ export declare const actionLoadScene: {
511
183
  exportWithDarkMode: boolean;
512
184
  currentItemStrokeColor: string;
513
185
  currentItemBackgroundColor: string;
514
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
515
- currentItemStrokeWidth: number;
516
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
186
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
187
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
188
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
517
189
  currentItemRoughness: number;
190
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
518
191
  currentItemOpacity: number;
519
- currentItemFontFamily: number;
192
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
520
193
  currentItemFontSize: number;
521
- currentItemTextAlign: string;
194
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
522
195
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
523
196
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
524
- currentHoveredFontFamily: number | null;
197
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
525
198
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
526
- currentItemArrowType: "round" | "sharp" | "elbow";
199
+ scrollConstraints: import("../types").ScrollConstraints | null;
527
200
  cursorButton: "up" | "down";
528
201
  scrolledOutside: boolean;
529
202
  isResizing: boolean;
530
203
  openMenu: "canvas" | null;
531
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
204
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
532
205
  openSidebar: {
533
- name: string;
534
- tab?: string | undefined;
206
+ name: import("../types").SidebarName;
207
+ tab?: import("../types").SidebarTabName;
535
208
  } | null;
536
209
  defaultSidebarDockedPreference: boolean;
537
210
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
@@ -540,25 +213,17 @@ export declare const actionLoadScene: {
540
213
  };
541
214
  selectedElementsAreBeingDragged: boolean;
542
215
  toast: {
543
- message: string;
544
- closable?: boolean | undefined;
545
- duration?: number | undefined;
216
+ message: React.ReactNode;
217
+ closable?: boolean;
218
+ duration?: number;
546
219
  } | null;
547
220
  gridStep: number;
548
221
  gridModeEnabled: boolean;
549
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
222
+ fileHandle: FileSystemFileHandle | null;
550
223
  stats: {
551
224
  open: boolean;
552
225
  panels: number;
553
226
  };
554
- currentChartType: import("@excalidraw/element/types").ChartType;
555
- pasteDialog: {
556
- shown: false;
557
- data: null;
558
- } | {
559
- shown: true;
560
- data: import("../charts").Spreadsheet;
561
- };
562
227
  showHyperlinkPopup: false | "info" | "editor";
563
228
  originSnapOffset: {
564
229
  x: number;
@@ -571,7 +236,7 @@ export declare const actionLoadScene: {
571
236
  [groupId: string]: true;
572
237
  };
573
238
  };
574
- files: import("../types").BinaryFiles;
239
+ files: BinaryFiles;
575
240
  captureUpdate: "IMMEDIATELY";
576
241
  } | {
577
242
  elements: readonly import("@excalidraw/element/types").OrderedExcalidrawElement[];
@@ -586,15 +251,20 @@ export declare const actionLoadScene: {
586
251
  isLoading: boolean;
587
252
  activeEmbeddable: {
588
253
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
589
- state: "active" | "hover";
254
+ state: "hover" | "active";
590
255
  } | null;
591
256
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
592
257
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
593
258
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
594
259
  selectionElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
595
260
  isBindingEnabled: boolean;
596
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
597
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
261
+ boxSelectionMode: import("../types").BoxSelectionMode;
262
+ bindingPreference: "enabled" | "disabled";
263
+ isMidpointSnappingEnabled: boolean;
264
+ suggestedBinding: {
265
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
266
+ midPoint?: import("@excalidraw/math").GlobalPoint;
267
+ } | null;
598
268
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
599
269
  frameRendering: {
600
270
  enabled: boolean;
@@ -603,8 +273,8 @@ export declare const actionLoadScene: {
603
273
  clip: boolean;
604
274
  };
605
275
  editingFrame: string | null;
606
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawElement>[] | null;
607
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
276
+ elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
277
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
608
278
  activeTool: {
609
279
  lastActiveTool: import("../types").ActiveTool | null;
610
280
  locked: boolean;
@@ -622,49 +292,53 @@ export declare const actionLoadScene: {
622
292
  exportScale: number;
623
293
  currentItemStrokeColor: string;
624
294
  currentItemBackgroundColor: string;
625
- currentItemFillStyle: import("@excalidraw/element/types").FillStyle;
626
- currentItemStrokeWidth: number;
627
- currentItemStrokeStyle: import("@excalidraw/element/types").StrokeStyle;
295
+ currentItemFillStyle: ExcalidrawElement["fillStyle"];
296
+ currentItemStrokeWidthKey: import("@excalidraw/common").StrokeWidthKey;
297
+ currentItemStrokeStyle: ExcalidrawElement["strokeStyle"];
628
298
  currentItemRoughness: number;
299
+ currentItemStrokeVariability: import("@excalidraw/element/types").StrokeVariability;
629
300
  currentItemOpacity: number;
630
- currentItemFontFamily: number;
301
+ currentItemFontFamily: import("@excalidraw/element/types").FontFamilyValues;
631
302
  currentItemFontSize: number;
632
- currentItemTextAlign: string;
303
+ currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
633
304
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
634
305
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
635
- currentHoveredFontFamily: number | null;
306
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
636
307
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
637
- currentItemArrowType: "round" | "sharp" | "elbow";
308
+ currentItemArrowType: "sharp" | "round" | "elbow";
638
309
  viewBackgroundColor: string;
639
310
  scrollX: number;
640
311
  scrollY: number;
312
+ scrollConstraints: import("../types").ScrollConstraints | null;
641
313
  cursorButton: "up" | "down";
642
314
  scrolledOutside: boolean;
643
315
  name: string | null;
644
316
  isResizing: boolean;
645
317
  isRotating: boolean;
646
- zoom: Readonly<{
647
- value: import("../types").NormalizedZoomValue;
648
- }>;
318
+ zoom: import("../types").Zoom;
649
319
  openMenu: "canvas" | null;
650
- openPopup: "fontFamily" | "canvasBackground" | "elementBackground" | "elementStroke" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
320
+ openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | "fontFamily" | "compactTextProperties" | "compactStrokeStyles" | "compactOtherProperties" | "compactArrowProperties" | null;
651
321
  openSidebar: {
652
- name: string;
653
- tab?: string | undefined;
322
+ name: import("../types").SidebarName;
323
+ tab?: import("../types").SidebarTabName;
654
324
  } | null;
655
- openDialog: {
325
+ openDialog: null | {
656
326
  name: "imageExport" | "help" | "jsonExport";
657
327
  } | {
658
328
  name: "ttd";
659
- tab: "mermaid" | "text-to-diagram";
329
+ tab: "text-to-diagram" | "mermaid";
660
330
  } | {
661
331
  name: "commandPalette";
662
332
  } | {
663
333
  name: "settings";
664
334
  } | {
665
335
  name: "elementLinkSelector";
666
- sourceElementId: string;
667
- } | null;
336
+ sourceElementId: ExcalidrawElement["id"];
337
+ } | {
338
+ name: "charts";
339
+ data: import("../charts").Spreadsheet;
340
+ rawText: string;
341
+ };
668
342
  defaultSidebarDockedPreference: boolean;
669
343
  lastPointerDownWith: import("@excalidraw/element/types").PointerType;
670
344
  selectedElementIds: Readonly<{
@@ -679,9 +353,9 @@ export declare const actionLoadScene: {
679
353
  selectedElementsAreBeingDragged: boolean;
680
354
  shouldCacheIgnoreZoom: boolean;
681
355
  toast: {
682
- message: string;
683
- closable?: boolean | undefined;
684
- duration?: number | undefined;
356
+ message: React.ReactNode;
357
+ closable?: boolean;
358
+ duration?: number;
685
359
  } | null;
686
360
  zenModeEnabled: boolean;
687
361
  theme: Theme;
@@ -692,44 +366,17 @@ export declare const actionLoadScene: {
692
366
  selectedGroupIds: {
693
367
  [groupId: string]: boolean;
694
368
  };
695
- editingGroupId: string | null;
369
+ editingGroupId: import("@excalidraw/element/types").GroupId | null;
696
370
  width: number;
697
371
  height: number;
698
372
  offsetTop: number;
699
373
  offsetLeft: number;
700
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
701
- collaborators: Map<import("../types").SocketId, Readonly<{
702
- pointer?: import("../types").CollaboratorPointer | undefined;
703
- button?: "up" | "down" | undefined;
704
- selectedElementIds?: Readonly<{
705
- [id: string]: true;
706
- }> | undefined;
707
- username?: string | null | undefined;
708
- userState?: import("@excalidraw/common").UserIdleState | undefined;
709
- color?: {
710
- background: string;
711
- stroke: string;
712
- } | undefined;
713
- avatarUrl?: string | undefined;
714
- id?: string | undefined;
715
- socketId?: import("../types").SocketId | undefined;
716
- isCurrentUser?: boolean | undefined;
717
- isInCall?: boolean | undefined;
718
- isSpeaking?: boolean | undefined;
719
- isMuted?: boolean | undefined;
720
- }>>;
374
+ fileHandle: FileSystemFileHandle | null;
375
+ collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
721
376
  stats: {
722
377
  open: boolean;
723
378
  panels: number;
724
379
  };
725
- currentChartType: import("@excalidraw/element/types").ChartType;
726
- pasteDialog: {
727
- shown: false;
728
- data: null;
729
- } | {
730
- shown: true;
731
- data: import("../charts").Spreadsheet;
732
- };
733
380
  showHyperlinkPopup: false | "info" | "editor";
734
381
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
735
382
  snapLines: readonly import("../snapping").SnapLine[];
@@ -741,9 +388,9 @@ export declare const actionLoadScene: {
741
388
  userToFollow: import("../types").UserToFollow | null;
742
389
  followedBy: Set<import("../types").SocketId>;
743
390
  isCropping: boolean;
744
- croppingElementId: string | null;
391
+ croppingElementId: ExcalidrawElement["id"] | null;
745
392
  searchMatches: Readonly<{
746
- focusedId: string | null;
393
+ focusedId: ExcalidrawElement["id"] | null;
747
394
  matches: readonly import("../types").SearchMatch[];
748
395
  }> | null;
749
396
  activeLockedId: string | null;
@@ -752,7 +399,7 @@ export declare const actionLoadScene: {
752
399
  };
753
400
  bindMode: import("@excalidraw/element/types").BindMode;
754
401
  };
755
- files: import("../types").BinaryFiles;
402
+ files: BinaryFiles;
756
403
  captureUpdate: "EVENTUALLY";
757
404
  }>;
758
405
  keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
@@ -760,5 +407,5 @@ export declare const actionLoadScene: {
760
407
  keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
761
408
  };
762
409
  export declare const actionExportWithDarkMode: import("./types").Action<boolean> & {
763
- keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>, appState: AppState, elements: readonly import("@excalidraw/element/types").ExcalidrawElement[], app: import("../types").AppClassProperties) => boolean) | undefined;
410
+ keyTest?: ((event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean) | undefined;
764
411
  };