@excalidraw/excalidraw 0.18.0-432a46e → 0.18.0-4e471c107

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 (435) hide show
  1. package/dist/dev/chunk-CBGOW5JB.js +5669 -0
  2. package/dist/dev/chunk-CBGOW5JB.js.map +7 -0
  3. package/dist/dev/chunk-CP5DND7P.js +7 -0
  4. package/dist/dev/chunk-CP5DND7P.js.map +7 -0
  5. package/dist/dev/{chunk-LMHBUWQS.js → chunk-QF5FRM6O.js} +16 -5
  6. package/dist/dev/chunk-QF5FRM6O.js.map +7 -0
  7. package/dist/dev/data/{image-5HAY2PCR.js → image-SURZSZNX.js} +3 -3
  8. package/dist/dev/index.css +143 -68
  9. package/dist/dev/index.css.map +3 -3
  10. package/dist/dev/index.js +17109 -17527
  11. package/dist/dev/index.js.map +4 -4
  12. package/dist/dev/locales/{en-OZCJJ2HN.js → en-SMAPCEOQ.js} +2 -2
  13. package/dist/dev/subset-shared.chunk.js +1 -1
  14. package/dist/dev/subset-worker.chunk.js +1 -1
  15. package/dist/prod/chunk-A66AFZZU.js +7 -0
  16. package/dist/prod/chunk-I4UNSFV6.js +12 -0
  17. package/dist/prod/chunk-IRHK23LL.js +4 -0
  18. package/dist/prod/data/image-HXEZYJPQ.js +1 -0
  19. package/dist/prod/index.css +1 -1
  20. package/dist/prod/index.js +25 -17
  21. package/dist/prod/locales/{en-B4ZKOASM.js → en-TYY6KWIJ.js} +1 -1
  22. package/dist/prod/subset-shared.chunk.js +1 -1
  23. package/dist/prod/subset-worker.chunk.js +1 -1
  24. package/dist/types/{packages/common → common}/src/colors.d.ts +1 -0
  25. package/dist/types/{packages/common → common}/src/constants.d.ts +23 -3
  26. package/dist/types/{packages/excalidraw → common/src}/emitter.d.ts +1 -1
  27. package/dist/types/{packages/common → common}/src/font-metadata.d.ts +4 -2
  28. package/dist/types/{packages/common → common}/src/index.d.ts +1 -0
  29. package/dist/types/{packages/common → common}/src/utility-types.d.ts +5 -0
  30. package/dist/types/{packages/common → common}/src/utils.d.ts +18 -1
  31. package/dist/types/{packages/excalidraw/scene → element/src}/Scene.d.ts +11 -14
  32. package/dist/types/element/src/align.d.ts +7 -0
  33. package/dist/types/{packages/element → element}/src/binding.d.ts +26 -15
  34. package/dist/types/{packages/element → element}/src/bounds.d.ts +18 -5
  35. package/dist/types/element/src/collision.d.ts +32 -0
  36. package/dist/types/{packages/element → element}/src/cropElement.d.ts +1 -1
  37. package/dist/types/{packages/excalidraw/change.d.ts → element/src/delta.d.ts} +63 -38
  38. package/dist/types/element/src/distance.d.ts +3 -0
  39. package/dist/types/{packages/element → element}/src/dragElements.d.ts +3 -2
  40. package/dist/types/{packages/element → element}/src/duplicate.d.ts +10 -13
  41. package/dist/types/{packages/element → element}/src/elbowArrow.d.ts +1 -1
  42. package/dist/types/{packages/element → element}/src/flowchart.d.ts +3 -2
  43. package/dist/types/{packages/element → element}/src/fractionalIndex.d.ts +9 -3
  44. package/dist/types/{packages/element → element}/src/frame.d.ts +5 -4
  45. package/dist/types/{packages/element → element}/src/heading.d.ts +0 -1
  46. package/dist/types/element/src/index.d.ts +57 -0
  47. package/dist/types/{packages/element → element}/src/linearElementEditor.d.ts +22 -36
  48. package/dist/types/{packages/element → element}/src/mutateElement.d.ts +11 -3
  49. package/dist/types/{packages/element → element}/src/newElement.d.ts +4 -3
  50. package/dist/types/{packages/element → element}/src/resizeElements.d.ts +5 -4
  51. package/dist/types/{packages/element → element}/src/selection.d.ts +11 -5
  52. package/dist/types/element/src/shape.d.ts +42 -0
  53. package/dist/types/{packages/element → element}/src/sizeHelpers.d.ts +2 -2
  54. package/dist/types/element/src/store.d.ts +232 -0
  55. package/dist/types/{packages/element → element}/src/textElement.d.ts +5 -3
  56. package/dist/types/{packages/element → element}/src/typeChecks.d.ts +19 -1
  57. package/dist/types/{packages/element → element}/src/types.d.ts +15 -2
  58. package/dist/types/element/src/utils.d.ts +31 -0
  59. package/dist/types/{packages/element → element}/src/zindex.d.ts +1 -1
  60. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionAddToLibrary.d.ts +45 -51
  61. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionBoundText.d.ts +30 -34
  62. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionCanvas.d.ts +364 -214
  63. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionClipboard.d.ts +87 -98
  64. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionCropEditor.d.ts +15 -17
  65. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionDeleteSelected.d.ts +40 -45
  66. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionElementLink.d.ts +14 -16
  67. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionElementLock.d.ts +45 -51
  68. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionEmbeddable.d.ts +15 -17
  69. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionExport.d.ts +145 -163
  70. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionFinalize.d.ts +73 -37
  71. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionFrame.d.ts +107 -115
  72. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionGroup.d.ts +30 -34
  73. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionHistory.d.ts +1 -2
  74. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +683 -0
  75. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionLink.d.ts +14 -16
  76. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionMenu.d.ts +42 -48
  77. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionNavigate.d.ts +29 -33
  78. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionProperties.d.ts +218 -240
  79. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionSelectAll.d.ts +14 -16
  80. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionStyles.d.ts +15 -17
  81. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionToggleGridMode.d.ts +15 -17
  82. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionToggleObjectsSnapMode.d.ts +15 -17
  83. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +183 -0
  84. package/dist/types/excalidraw/actions/actionToggleShapeSwitch.d.ts +19 -0
  85. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionToggleStats.d.ts +15 -18
  86. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionToggleViewMode.d.ts +15 -18
  87. package/dist/types/{packages/excalidraw → excalidraw}/actions/actionToggleZenMode.d.ts +15 -18
  88. package/dist/types/{packages/excalidraw → excalidraw}/actions/types.d.ts +4 -3
  89. package/dist/types/{packages/excalidraw → excalidraw}/animated-trail.d.ts +7 -1
  90. package/dist/types/{packages/excalidraw → excalidraw}/appState.d.ts +20 -10
  91. package/dist/types/{packages/excalidraw → excalidraw}/components/App.d.ts +38 -22
  92. package/dist/types/{packages/excalidraw → excalidraw}/components/ButtonIcon.d.ts +1 -0
  93. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/ColorInput.d.ts +2 -1
  94. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/ColorPicker.d.ts +5 -1
  95. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/CustomColorList.d.ts +1 -1
  96. package/dist/types/excalidraw/components/ColorPicker/HotkeyLabel.d.ts +7 -0
  97. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/Picker.d.ts +2 -3
  98. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/PickerColorList.d.ts +2 -3
  99. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/ShadeList.d.ts +2 -2
  100. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/TopPicks.d.ts +1 -1
  101. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/colorPickerUtils.d.ts +2 -2
  102. package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/keyboardNavHandlers.d.ts +1 -1
  103. package/dist/types/excalidraw/components/ConvertElementTypePopup.d.ts +23 -0
  104. package/dist/types/{packages/excalidraw → excalidraw}/components/ElementLinkDialog.d.ts +4 -3
  105. package/dist/types/{packages/excalidraw/components/ButtonIconSelect.d.ts → excalidraw/components/RadioSelection.d.ts} +1 -1
  106. package/dist/types/excalidraw/components/Range.d.ts +8 -0
  107. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/Angle.d.ts +1 -1
  108. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/CanvasGrid.d.ts +1 -1
  109. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/Collapsible.d.ts +2 -1
  110. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/Dimension.d.ts +1 -1
  111. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/DragInput.d.ts +12 -2
  112. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/FontSize.d.ts +1 -1
  113. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/MultiAngle.d.ts +1 -1
  114. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/MultiDimension.d.ts +1 -1
  115. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/MultiFontSize.d.ts +1 -1
  116. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/MultiPosition.d.ts +1 -1
  117. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/Position.d.ts +1 -1
  118. package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/utils.d.ts +4 -11
  119. package/dist/types/excalidraw/components/UnlockPopup.d.ts +8 -0
  120. package/dist/types/{packages/excalidraw → excalidraw}/components/canvases/InteractiveCanvas.d.ts +1 -0
  121. package/dist/types/{packages/excalidraw → excalidraw}/components/hyperlink/Hyperlink.d.ts +3 -2
  122. package/dist/types/{packages/excalidraw → excalidraw}/components/hyperlink/helpers.d.ts +2 -1
  123. package/dist/types/{packages/excalidraw → excalidraw}/components/icons.d.ts +4 -0
  124. package/dist/types/{packages/excalidraw → excalidraw}/components/shapes.d.ts +1 -1
  125. package/dist/types/{packages/excalidraw → excalidraw}/data/transform.d.ts +1 -1
  126. package/dist/types/{packages/excalidraw → excalidraw}/editor-jotai.d.ts +6 -6
  127. package/dist/types/excalidraw/eraser/index.d.ts +12 -0
  128. package/dist/types/{packages/excalidraw → excalidraw}/fonts/Fonts.d.ts +1 -1
  129. package/dist/types/excalidraw/history.d.ts +48 -0
  130. package/dist/types/{packages/excalidraw → excalidraw}/hooks/useEmitter.d.ts +1 -1
  131. package/dist/types/{packages/excalidraw → excalidraw}/index.d.ts +9 -9
  132. package/dist/types/excalidraw/lasso/index.d.ts +16 -0
  133. package/dist/types/excalidraw/lasso/utils.d.ts +13 -0
  134. package/dist/types/excalidraw/renderer/helpers.d.ts +18 -0
  135. package/dist/types/{packages/excalidraw → excalidraw}/scene/Renderer.d.ts +1 -2
  136. package/dist/types/excalidraw/scene/index.d.ts +4 -0
  137. package/dist/types/{packages/excalidraw → excalidraw}/scene/scrollbars.d.ts +2 -3
  138. package/dist/types/{packages/excalidraw → excalidraw}/scene/types.d.ts +2 -0
  139. package/dist/types/{packages/excalidraw → excalidraw}/snapping.d.ts +2 -2
  140. package/dist/types/{packages/excalidraw → excalidraw}/types.d.ts +32 -11
  141. package/dist/types/{packages/excalidraw → excalidraw}/wysiwyg/textWysiwyg.d.ts +3 -1
  142. package/dist/types/{packages/math → math}/src/angle.d.ts +2 -0
  143. package/dist/types/math/src/constants.d.ts +3 -0
  144. package/dist/types/math/src/curve.d.ts +74 -0
  145. package/dist/types/{packages/math → math}/src/index.d.ts +1 -0
  146. package/dist/types/{packages/math → math}/src/point.d.ts +1 -1
  147. package/dist/types/{packages/math → math}/src/polygon.d.ts +1 -0
  148. package/dist/types/{packages/math → math}/src/rectangle.d.ts +2 -0
  149. package/dist/types/{packages/math → math}/src/segment.d.ts +1 -1
  150. package/dist/types/{packages/math → math}/src/types.d.ts +1 -0
  151. package/dist/types/{packages/math → math}/src/vector.d.ts +8 -2
  152. package/dist/types/{packages/utils → utils}/src/bbox.d.ts +1 -1
  153. package/dist/types/{packages/utils → utils}/src/index.d.ts +1 -1
  154. package/dist/types/{packages/utils → utils}/src/withinBounds.d.ts +1 -1
  155. package/history.ts +147 -110
  156. package/package.json +30 -10
  157. package/dist/dev/chunk-LMHBUWQS.js.map +0 -7
  158. package/dist/dev/chunk-S7W4OWSF.js +0 -18442
  159. package/dist/dev/chunk-S7W4OWSF.js.map +0 -7
  160. package/dist/dev/chunk-ZG3EI5XS.js +0 -7
  161. package/dist/dev/chunk-ZG3EI5XS.js.map +0 -7
  162. package/dist/prod/chunk-6U3AYISY.js +0 -12
  163. package/dist/prod/chunk-LRITYP5X.js +0 -31
  164. package/dist/prod/chunk-U24AOZ3B.js +0 -7
  165. package/dist/prod/data/image-W3GRS73V.js +0 -1
  166. package/dist/types/excalidraw-app/app_constants.d.ts +0 -44
  167. package/dist/types/packages/element/src/Shape.d.ts +0 -17
  168. package/dist/types/packages/element/src/ShapeCache.d.ts +0 -25
  169. package/dist/types/packages/element/src/align.d.ts +0 -7
  170. package/dist/types/packages/element/src/collision.d.ts +0 -26
  171. package/dist/types/packages/element/src/distance.d.ts +0 -3
  172. package/dist/types/packages/element/src/index.d.ts +0 -16
  173. package/dist/types/packages/element/src/shapes.d.ts +0 -23
  174. package/dist/types/packages/element/src/utils.d.ts +0 -21
  175. package/dist/types/packages/excalidraw/actions/actionLinearEditor.d.ts +0 -192
  176. package/dist/types/packages/excalidraw/actions/actionToggleSearchMenu.d.ts +0 -357
  177. package/dist/types/packages/excalidraw/components/ButtonSelect.d.ts +0 -9
  178. package/dist/types/packages/excalidraw/components/ColorPicker/HotkeyLabel.d.ts +0 -8
  179. package/dist/types/packages/excalidraw/components/Range.d.ts +0 -8
  180. package/dist/types/packages/excalidraw/history.d.ts +0 -40
  181. package/dist/types/packages/excalidraw/renderer/helpers.d.ts +0 -13
  182. package/dist/types/packages/excalidraw/scene/index.d.ts +0 -4
  183. package/dist/types/packages/excalidraw/store.d.ts +0 -129
  184. package/dist/types/packages/excalidraw/tests/fixtures/diagramFixture.d.ts +0 -504
  185. package/dist/types/packages/excalidraw/tests/fixtures/elementFixture.d.ts +0 -7
  186. package/dist/types/packages/excalidraw/tests/helpers/api.d.ts +0 -89
  187. package/dist/types/packages/excalidraw/tests/helpers/colorize.d.ts +0 -2
  188. package/dist/types/packages/excalidraw/tests/helpers/mocks.d.ts +0 -5
  189. package/dist/types/packages/excalidraw/tests/helpers/polyfills.d.ts +0 -36
  190. package/dist/types/packages/excalidraw/tests/helpers/ui.d.ts +0 -189
  191. package/dist/types/packages/excalidraw/tests/queries/dom.d.ts +0 -2
  192. package/dist/types/packages/excalidraw/tests/queries/toolQueries.d.ts +0 -2
  193. package/dist/types/packages/excalidraw/tests/test-utils.d.ts +0 -139
  194. package/dist/types/packages/excalidraw/visualdebug.d.ts +0 -41
  195. package/dist/types/packages/math/src/curve.d.ts +0 -40
  196. package/dist/types/packages/utils/src/collision.d.ts +0 -8
  197. /package/dist/dev/data/{image-5HAY2PCR.js.map → image-SURZSZNX.js.map} +0 -0
  198. /package/dist/dev/locales/{en-OZCJJ2HN.js.map → en-SMAPCEOQ.js.map} +0 -0
  199. /package/dist/types/{packages/common → common}/src/binary-heap.d.ts +0 -0
  200. /package/dist/types/{packages/common → common}/src/keys.d.ts +0 -0
  201. /package/dist/types/{packages/common → common}/src/points.d.ts +0 -0
  202. /package/dist/types/{packages/common → common}/src/promise-pool.d.ts +0 -0
  203. /package/dist/types/{packages/common → common}/src/queue.d.ts +0 -0
  204. /package/dist/types/{packages/common → common}/src/random.d.ts +0 -0
  205. /package/dist/types/{packages/common → common}/src/url.d.ts +0 -0
  206. /package/dist/types/{packages/element → element}/src/comparisons.d.ts +0 -0
  207. /package/dist/types/{packages/element → element}/src/containerCache.d.ts +0 -0
  208. /package/dist/types/{packages/element → element}/src/distribute.d.ts +0 -0
  209. /package/dist/types/{packages/element → element}/src/elementLink.d.ts +0 -0
  210. /package/dist/types/{packages/element → element}/src/embeddable.d.ts +0 -0
  211. /package/dist/types/{packages/element → element}/src/groups.d.ts +0 -0
  212. /package/dist/types/{packages/element → element}/src/image.d.ts +0 -0
  213. /package/dist/types/{packages/element → element}/src/renderElement.d.ts +0 -0
  214. /package/dist/types/{packages/element → element}/src/resizeTest.d.ts +0 -0
  215. /package/dist/types/{packages/element → element}/src/showSelectedShapeActions.d.ts +0 -0
  216. /package/dist/types/{packages/element → element}/src/sortElements.d.ts +0 -0
  217. /package/dist/types/{packages/element → element}/src/textMeasurements.d.ts +0 -0
  218. /package/dist/types/{packages/element → element}/src/textWrapping.d.ts +0 -0
  219. /package/dist/types/{packages/element → element}/src/transformHandles.d.ts +0 -0
  220. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionAlign.d.ts +0 -0
  221. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionDistribute.d.ts +0 -0
  222. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionDuplicateSelection.d.ts +0 -0
  223. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionFlip.d.ts +0 -0
  224. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionTextAutoResize.d.ts +0 -0
  225. /package/dist/types/{packages/excalidraw → excalidraw}/actions/actionZindex.d.ts +0 -0
  226. /package/dist/types/{packages/excalidraw → excalidraw}/actions/index.d.ts +0 -0
  227. /package/dist/types/{packages/excalidraw → excalidraw}/actions/manager.d.ts +0 -0
  228. /package/dist/types/{packages/excalidraw → excalidraw}/actions/register.d.ts +0 -0
  229. /package/dist/types/{packages/excalidraw → excalidraw}/actions/shortcuts.d.ts +0 -0
  230. /package/dist/types/{packages/excalidraw → excalidraw}/analytics.d.ts +0 -0
  231. /package/dist/types/{packages/excalidraw → excalidraw}/animation-frame-handler.d.ts +0 -0
  232. /package/dist/types/{packages/excalidraw → excalidraw}/charts.d.ts +0 -0
  233. /package/dist/types/{packages/excalidraw → excalidraw}/clients.d.ts +0 -0
  234. /package/dist/types/{packages/excalidraw → excalidraw}/clipboard.d.ts +0 -0
  235. /package/dist/types/{packages/excalidraw → excalidraw}/components/Actions.d.ts +0 -0
  236. /package/dist/types/{packages/excalidraw → excalidraw}/components/ActiveConfirmDialog.d.ts +0 -0
  237. /package/dist/types/{packages/excalidraw → excalidraw}/components/Avatar.d.ts +0 -0
  238. /package/dist/types/{packages/excalidraw → excalidraw}/components/BraveMeasureTextError.d.ts +0 -0
  239. /package/dist/types/{packages/excalidraw → excalidraw}/components/Button.d.ts +0 -0
  240. /package/dist/types/{packages/excalidraw → excalidraw}/components/ButtonIconCycle.d.ts +0 -0
  241. /package/dist/types/{packages/excalidraw → excalidraw}/components/ButtonSeparator.d.ts +0 -0
  242. /package/dist/types/{packages/excalidraw → excalidraw}/components/Card.d.ts +0 -0
  243. /package/dist/types/{packages/excalidraw → excalidraw}/components/CheckboxItem.d.ts +0 -0
  244. /package/dist/types/{packages/excalidraw → excalidraw}/components/ColorPicker/PickerHeading.d.ts +0 -0
  245. /package/dist/types/{packages/excalidraw → excalidraw}/components/CommandPalette/CommandPalette.d.ts +0 -0
  246. /package/dist/types/{packages/excalidraw → excalidraw}/components/CommandPalette/defaultCommandPaletteItems.d.ts +0 -0
  247. /package/dist/types/{packages/excalidraw → excalidraw}/components/CommandPalette/types.d.ts +0 -0
  248. /package/dist/types/{packages/excalidraw → excalidraw}/components/ConfirmDialog.d.ts +0 -0
  249. /package/dist/types/{packages/excalidraw → excalidraw}/components/ContextMenu.d.ts +0 -0
  250. /package/dist/types/{packages/excalidraw → excalidraw}/components/DarkModeToggle.d.ts +0 -0
  251. /package/dist/types/{packages/excalidraw → excalidraw}/components/DefaultSidebar.d.ts +0 -0
  252. /package/dist/types/{packages/excalidraw → excalidraw}/components/DiagramToCodePlugin/DiagramToCodePlugin.d.ts +0 -0
  253. /package/dist/types/{packages/excalidraw → excalidraw}/components/Dialog.d.ts +0 -0
  254. /package/dist/types/{packages/excalidraw → excalidraw}/components/DialogActionButton.d.ts +0 -0
  255. /package/dist/types/{packages/excalidraw → excalidraw}/components/ElementCanvasButtons.d.ts +0 -0
  256. /package/dist/types/{packages/excalidraw → excalidraw}/components/ErrorDialog.d.ts +0 -0
  257. /package/dist/types/{packages/excalidraw → excalidraw}/components/ExcalidrawLogo.d.ts +0 -0
  258. /package/dist/types/{packages/excalidraw → excalidraw}/components/EyeDropper.d.ts +0 -0
  259. /package/dist/types/{packages/excalidraw → excalidraw}/components/FilledButton.d.ts +0 -0
  260. /package/dist/types/{packages/excalidraw → excalidraw}/components/FixedSideContainer.d.ts +0 -0
  261. /package/dist/types/{packages/excalidraw → excalidraw}/components/FollowMode/FollowMode.d.ts +0 -0
  262. /package/dist/types/{packages/excalidraw → excalidraw}/components/FontPicker/FontPicker.d.ts +0 -0
  263. /package/dist/types/{packages/excalidraw → excalidraw}/components/FontPicker/FontPickerList.d.ts +0 -0
  264. /package/dist/types/{packages/excalidraw → excalidraw}/components/FontPicker/FontPickerTrigger.d.ts +0 -0
  265. /package/dist/types/{packages/excalidraw → excalidraw}/components/FontPicker/keyboardNavHandlers.d.ts +0 -0
  266. /package/dist/types/{packages/excalidraw → excalidraw}/components/HandButton.d.ts +0 -0
  267. /package/dist/types/{packages/excalidraw → excalidraw}/components/HelpButton.d.ts +0 -0
  268. /package/dist/types/{packages/excalidraw → excalidraw}/components/HelpDialog.d.ts +0 -0
  269. /package/dist/types/{packages/excalidraw → excalidraw}/components/HintViewer.d.ts +0 -0
  270. /package/dist/types/{packages/excalidraw → excalidraw}/components/IconPicker.d.ts +0 -0
  271. /package/dist/types/{packages/excalidraw → excalidraw}/components/ImageExportDialog.d.ts +0 -0
  272. /package/dist/types/{packages/excalidraw → excalidraw}/components/InitializeApp.d.ts +0 -0
  273. /package/dist/types/{packages/excalidraw → excalidraw}/components/InlineIcon.d.ts +0 -0
  274. /package/dist/types/{packages/excalidraw → excalidraw}/components/Island.d.ts +0 -0
  275. /package/dist/types/{packages/excalidraw → excalidraw}/components/JSONExportDialog.d.ts +0 -0
  276. /package/dist/types/{packages/excalidraw → excalidraw}/components/LaserPointerButton.d.ts +0 -0
  277. /package/dist/types/{packages/excalidraw → excalidraw}/components/LayerUI.d.ts +0 -0
  278. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenu.d.ts +0 -0
  279. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenuBrowseButton.d.ts +0 -0
  280. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenuControlButtons.d.ts +0 -0
  281. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenuHeaderContent.d.ts +0 -0
  282. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenuItems.d.ts +0 -0
  283. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryMenuSection.d.ts +0 -0
  284. /package/dist/types/{packages/excalidraw → excalidraw}/components/LibraryUnit.d.ts +0 -0
  285. /package/dist/types/{packages/excalidraw → excalidraw}/components/LoadingMessage.d.ts +0 -0
  286. /package/dist/types/{packages/excalidraw → excalidraw}/components/LockButton.d.ts +0 -0
  287. /package/dist/types/{packages/excalidraw → excalidraw}/components/MagicButton.d.ts +0 -0
  288. /package/dist/types/{packages/excalidraw → excalidraw}/components/MobileMenu.d.ts +0 -0
  289. /package/dist/types/{packages/excalidraw → excalidraw}/components/Modal.d.ts +0 -0
  290. /package/dist/types/{packages/excalidraw → excalidraw}/components/OverwriteConfirm/OverwriteConfirm.d.ts +0 -0
  291. /package/dist/types/{packages/excalidraw → excalidraw}/components/OverwriteConfirm/OverwriteConfirmActions.d.ts +0 -0
  292. /package/dist/types/{packages/excalidraw → excalidraw}/components/OverwriteConfirm/OverwriteConfirmState.d.ts +0 -0
  293. /package/dist/types/{packages/excalidraw → excalidraw}/components/Paragraph.d.ts +0 -0
  294. /package/dist/types/{packages/excalidraw → excalidraw}/components/PasteChartDialog.d.ts +0 -0
  295. /package/dist/types/{packages/excalidraw → excalidraw}/components/PenModeButton.d.ts +0 -0
  296. /package/dist/types/{packages/excalidraw → excalidraw}/components/Popover.d.ts +0 -0
  297. /package/dist/types/{packages/excalidraw → excalidraw}/components/ProjectName.d.ts +0 -0
  298. /package/dist/types/{packages/excalidraw → excalidraw}/components/PropertiesPopover.d.ts +0 -0
  299. /package/dist/types/{packages/excalidraw → excalidraw}/components/PublishLibrary.d.ts +0 -0
  300. /package/dist/types/{packages/excalidraw → excalidraw}/components/QuickSearch.d.ts +0 -0
  301. /package/dist/types/{packages/excalidraw → excalidraw}/components/RadioGroup.d.ts +0 -0
  302. /package/dist/types/{packages/excalidraw → excalidraw}/components/SVGLayer.d.ts +0 -0
  303. /package/dist/types/{packages/excalidraw → excalidraw}/components/ScrollableList.d.ts +0 -0
  304. /package/dist/types/{packages/excalidraw → excalidraw}/components/SearchMenu.d.ts +0 -0
  305. /package/dist/types/{packages/excalidraw → excalidraw}/components/Section.d.ts +0 -0
  306. /package/dist/types/{packages/excalidraw → excalidraw}/components/ShareableLinkDialog.d.ts +0 -0
  307. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/Sidebar.d.ts +0 -0
  308. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarHeader.d.ts +0 -0
  309. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarTab.d.ts +0 -0
  310. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarTabTrigger.d.ts +0 -0
  311. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarTabTriggers.d.ts +0 -0
  312. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarTabs.d.ts +0 -0
  313. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/SidebarTrigger.d.ts +0 -0
  314. /package/dist/types/{packages/excalidraw → excalidraw}/components/Sidebar/common.d.ts +0 -0
  315. /package/dist/types/{packages/excalidraw → excalidraw}/components/Spinner.d.ts +0 -0
  316. /package/dist/types/{packages/excalidraw → excalidraw}/components/Stack.d.ts +0 -0
  317. /package/dist/types/{packages/excalidraw → excalidraw}/components/Stats/index.d.ts +0 -0
  318. /package/dist/types/{packages/excalidraw → excalidraw}/components/Switch.d.ts +0 -0
  319. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/MermaidToExcalidraw.d.ts +0 -0
  320. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialog.d.ts +0 -0
  321. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogInput.d.ts +0 -0
  322. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogOutput.d.ts +0 -0
  323. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogPanel.d.ts +0 -0
  324. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogPanels.d.ts +0 -0
  325. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogSubmitShortcut.d.ts +0 -0
  326. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogTab.d.ts +0 -0
  327. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogTabTrigger.d.ts +0 -0
  328. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogTabTriggers.d.ts +0 -0
  329. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogTabs.d.ts +0 -0
  330. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/TTDDialogTrigger.d.ts +0 -0
  331. /package/dist/types/{packages/excalidraw → excalidraw}/components/TTDDialog/common.d.ts +0 -0
  332. /package/dist/types/{packages/excalidraw → excalidraw}/components/TextField.d.ts +0 -0
  333. /package/dist/types/{packages/excalidraw → excalidraw}/components/Toast.d.ts +0 -0
  334. /package/dist/types/{packages/excalidraw → excalidraw}/components/ToolButton.d.ts +0 -0
  335. /package/dist/types/{packages/excalidraw → excalidraw}/components/Tooltip.d.ts +0 -0
  336. /package/dist/types/{packages/excalidraw → excalidraw}/components/Trans.d.ts +0 -0
  337. /package/dist/types/{packages/excalidraw → excalidraw}/components/UserList.d.ts +0 -0
  338. /package/dist/types/{packages/excalidraw → excalidraw}/components/canvases/NewElementCanvas.d.ts +0 -0
  339. /package/dist/types/{packages/excalidraw → excalidraw}/components/canvases/StaticCanvas.d.ts +0 -0
  340. /package/dist/types/{packages/excalidraw → excalidraw}/components/canvases/index.d.ts +0 -0
  341. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenu.d.ts +0 -0
  342. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuContent.d.ts +0 -0
  343. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuGroup.d.ts +0 -0
  344. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuItem.d.ts +0 -0
  345. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuItemContent.d.ts +0 -0
  346. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuItemContentRadio.d.ts +0 -0
  347. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuItemCustom.d.ts +0 -0
  348. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuItemLink.d.ts +0 -0
  349. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuSeparator.d.ts +0 -0
  350. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/DropdownMenuTrigger.d.ts +0 -0
  351. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/common.d.ts +0 -0
  352. /package/dist/types/{packages/excalidraw → excalidraw}/components/dropdownMenu/dropdownMenuUtils.d.ts +0 -0
  353. /package/dist/types/{packages/excalidraw → excalidraw}/components/footer/Footer.d.ts +0 -0
  354. /package/dist/types/{packages/excalidraw → excalidraw}/components/footer/FooterCenter.d.ts +0 -0
  355. /package/dist/types/{packages/excalidraw → excalidraw}/components/hoc/withInternalFallback.d.ts +0 -0
  356. /package/dist/types/{packages/excalidraw → excalidraw}/components/live-collaboration/LiveCollaborationTrigger.d.ts +0 -0
  357. /package/dist/types/{packages/excalidraw → excalidraw}/components/main-menu/DefaultItems.d.ts +0 -0
  358. /package/dist/types/{packages/excalidraw → excalidraw}/components/main-menu/MainMenu.d.ts +0 -0
  359. /package/dist/types/{packages/excalidraw → excalidraw}/components/welcome-screen/WelcomeScreen.Center.d.ts +0 -0
  360. /package/dist/types/{packages/excalidraw → excalidraw}/components/welcome-screen/WelcomeScreen.Hints.d.ts +0 -0
  361. /package/dist/types/{packages/excalidraw → excalidraw}/components/welcome-screen/WelcomeScreen.d.ts +0 -0
  362. /package/dist/types/{packages/excalidraw → excalidraw}/context/tunnels.d.ts +0 -0
  363. /package/dist/types/{packages/excalidraw → excalidraw}/context/ui-appState.d.ts +0 -0
  364. /package/dist/types/{packages/excalidraw → excalidraw}/cursor.d.ts +0 -0
  365. /package/dist/types/{packages/excalidraw → excalidraw}/data/EditorLocalStorage.d.ts +0 -0
  366. /package/dist/types/{packages/excalidraw → excalidraw}/data/ai/types.d.ts +0 -0
  367. /package/dist/types/{packages/excalidraw → excalidraw}/data/blob.d.ts +0 -0
  368. /package/dist/types/{packages/excalidraw → excalidraw}/data/encode.d.ts +0 -0
  369. /package/dist/types/{packages/excalidraw → excalidraw}/data/encryption.d.ts +0 -0
  370. /package/dist/types/{packages/excalidraw → excalidraw}/data/filesystem.d.ts +0 -0
  371. /package/dist/types/{packages/excalidraw → excalidraw}/data/image.d.ts +0 -0
  372. /package/dist/types/{packages/excalidraw → excalidraw}/data/index.d.ts +0 -0
  373. /package/dist/types/{packages/excalidraw → excalidraw}/data/json.d.ts +0 -0
  374. /package/dist/types/{packages/excalidraw → excalidraw}/data/library.d.ts +0 -0
  375. /package/dist/types/{packages/excalidraw → excalidraw}/data/reconcile.d.ts +0 -0
  376. /package/dist/types/{packages/excalidraw → excalidraw}/data/resave.d.ts +0 -0
  377. /package/dist/types/{packages/excalidraw → excalidraw}/data/restore.d.ts +0 -0
  378. /package/dist/types/{packages/excalidraw → excalidraw}/data/types.d.ts +0 -0
  379. /package/dist/types/{packages/excalidraw → excalidraw}/deburr.d.ts +0 -0
  380. /package/dist/types/{packages/excalidraw → excalidraw}/errors.d.ts +0 -0
  381. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Cascadia/index.d.ts +0 -0
  382. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/ComicShanns/index.d.ts +0 -0
  383. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Emoji/index.d.ts +0 -0
  384. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/ExcalidrawFontFace.d.ts +0 -0
  385. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Excalifont/index.d.ts +0 -0
  386. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Helvetica/index.d.ts +0 -0
  387. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Liberation/index.d.ts +0 -0
  388. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Lilita/index.d.ts +0 -0
  389. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Nunito/index.d.ts +0 -0
  390. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Virgil/index.d.ts +0 -0
  391. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/Xiaolai/index.d.ts +0 -0
  392. /package/dist/types/{packages/excalidraw → excalidraw}/fonts/index.d.ts +0 -0
  393. /package/dist/types/{packages/excalidraw → excalidraw}/gesture.d.ts +0 -0
  394. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useCallbackRefState.d.ts +0 -0
  395. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useCopiedIndicator.d.ts +0 -0
  396. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useCreatePortalContainer.d.ts +0 -0
  397. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useLibraryItemSvg.d.ts +0 -0
  398. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useOutsideClick.d.ts +0 -0
  399. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useScrollPosition.d.ts +0 -0
  400. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useStable.d.ts +0 -0
  401. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useStableCallback.d.ts +0 -0
  402. /package/dist/types/{packages/excalidraw → excalidraw}/hooks/useTransition.d.ts +0 -0
  403. /package/dist/types/{packages/excalidraw → excalidraw}/i18n.d.ts +0 -0
  404. /package/dist/types/{packages/excalidraw → excalidraw}/index-node.d.ts +0 -0
  405. /package/dist/types/{packages/excalidraw → excalidraw}/laser-trails.d.ts +0 -0
  406. /package/dist/types/{packages/excalidraw → excalidraw}/mermaid.d.ts +0 -0
  407. /package/dist/types/{packages/excalidraw → excalidraw}/polyfill.d.ts +0 -0
  408. /package/dist/types/{packages/excalidraw → excalidraw}/reactUtils.d.ts +0 -0
  409. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/interactiveScene.d.ts +0 -0
  410. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/renderNewElementScene.d.ts +0 -0
  411. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/renderSnaps.d.ts +0 -0
  412. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/roundRect.d.ts +0 -0
  413. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/staticScene.d.ts +0 -0
  414. /package/dist/types/{packages/excalidraw → excalidraw}/renderer/staticSvgScene.d.ts +0 -0
  415. /package/dist/types/{packages/excalidraw → excalidraw}/scene/export.d.ts +0 -0
  416. /package/dist/types/{packages/excalidraw → excalidraw}/scene/normalize.d.ts +0 -0
  417. /package/dist/types/{packages/excalidraw → excalidraw}/scene/scroll.d.ts +0 -0
  418. /package/dist/types/{packages/excalidraw → excalidraw}/scene/zoom.d.ts +0 -0
  419. /package/dist/types/{packages/excalidraw → excalidraw}/subset/harfbuzz/harfbuzz-bindings.d.ts +0 -0
  420. /package/dist/types/{packages/excalidraw → excalidraw}/subset/harfbuzz/harfbuzz-loader.d.ts +0 -0
  421. /package/dist/types/{packages/excalidraw → excalidraw}/subset/harfbuzz/harfbuzz-wasm.d.ts +0 -0
  422. /package/dist/types/{packages/excalidraw → excalidraw}/subset/subset-main.d.ts +0 -0
  423. /package/dist/types/{packages/excalidraw → excalidraw}/subset/subset-shared.chunk.d.ts +0 -0
  424. /package/dist/types/{packages/excalidraw → excalidraw}/subset/subset-worker.chunk.d.ts +0 -0
  425. /package/dist/types/{packages/excalidraw → excalidraw}/subset/woff2/woff2-bindings.d.ts +0 -0
  426. /package/dist/types/{packages/excalidraw → excalidraw}/subset/woff2/woff2-loader.d.ts +0 -0
  427. /package/dist/types/{packages/excalidraw → excalidraw}/subset/woff2/woff2-wasm.d.ts +0 -0
  428. /package/dist/types/{packages/excalidraw → excalidraw}/workers.d.ts +0 -0
  429. /package/dist/types/{packages/math → math}/src/ellipse.d.ts +0 -0
  430. /package/dist/types/{packages/math → math}/src/line.d.ts +0 -0
  431. /package/dist/types/{packages/math → math}/src/range.d.ts +0 -0
  432. /package/dist/types/{packages/math → math}/src/triangle.d.ts +0 -0
  433. /package/dist/types/{packages/math → math}/src/utils.d.ts +0 -0
  434. /package/dist/types/{packages/utils → utils}/src/export.d.ts +0 -0
  435. /package/dist/types/{packages/utils → utils}/src/shape.d.ts +0 -0
@@ -5,7 +5,7 @@ interface ColorPickerKeyNavHandlerProps {
5
5
  event: React.KeyboardEvent;
6
6
  activeColorPickerSection: ActiveColorPickerSectionAtomType;
7
7
  palette: ColorPaletteCustom;
8
- color: string;
8
+ color: string | null;
9
9
  onChange: (color: string) => void;
10
10
  customColors: string[];
11
11
  setActiveColorPickerSection: (update: React.SetStateAction<ActiveColorPickerSectionAtomType>) => void;
@@ -0,0 +1,23 @@
1
+ import type { ConvertibleTypes, ExcalidrawElement, ExcalidrawTextContainer, ExcalidrawTextElementWithContainer } from "@excalidraw/element/types";
2
+ import type { Scene } from "@excalidraw/element";
3
+ import "./ConvertElementTypePopup.scss";
4
+ import type App from "./App";
5
+ export declare const convertElementTypePopupAtom: import("jotai/vanilla/atom").PrimitiveAtom<{
6
+ type: "panel";
7
+ } | null> & {
8
+ init: {
9
+ type: "panel";
10
+ } | null;
11
+ };
12
+ declare const ConvertElementTypePopup: ({ app }: {
13
+ app: App;
14
+ }) => import("react/jsx-runtime").JSX.Element;
15
+ export declare const adjustBoundTextSize: (container: ExcalidrawTextContainer, boundText: ExcalidrawTextElementWithContainer, scene: Scene) => void;
16
+ type ConversionType = "generic" | "linear" | null;
17
+ export declare const convertElementTypes: (app: App, { conversionType, nextType, direction, }: {
18
+ conversionType: ConversionType;
19
+ nextType?: ConvertibleTypes | undefined;
20
+ direction?: "left" | "right" | undefined;
21
+ }) => boolean;
22
+ export declare const getConversionTypeFromElements: (elements: ExcalidrawElement[]) => ConversionType;
23
+ export default ConvertElementTypePopup;
@@ -1,10 +1,11 @@
1
- import type { ElementsMap, ExcalidrawElement } from "@excalidraw/element/types";
1
+ import type { ExcalidrawElement } from "@excalidraw/element/types";
2
+ import type { Scene } from "@excalidraw/element";
2
3
  import "./ElementLinkDialog.scss";
3
4
  import type { AppProps, UIAppState } from "../types";
4
- declare const ElementLinkDialog: ({ sourceElementId, onClose, elementsMap, appState, generateLinkForSelection, }: {
5
+ declare const ElementLinkDialog: ({ sourceElementId, onClose, appState, scene, generateLinkForSelection, }: {
5
6
  sourceElementId: ExcalidrawElement["id"];
6
- elementsMap: ElementsMap;
7
7
  appState: UIAppState;
8
+ scene: Scene;
8
9
  onClose?: (() => void) | undefined;
9
10
  generateLinkForSelection: AppProps["generateLinkForSelection"];
10
11
  }) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,5 @@
1
1
  import type { JSX } from "react";
2
- export declare const ButtonIconSelect: <T extends Object>(props: {
2
+ export declare const RadioSelection: <T extends Object>(props: {
3
3
  options: {
4
4
  value: T;
5
5
  text: string;
@@ -0,0 +1,8 @@
1
+ import "./Range.scss";
2
+ import type { AppClassProperties } from "../types";
3
+ export type RangeProps = {
4
+ updateData: (value: number) => void;
5
+ app: AppClassProperties;
6
+ testId?: string;
7
+ };
8
+ export declare const Range: ({ updateData, app, testId }: RangeProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface AngleProps {
5
5
  element: ExcalidrawElement;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface PositionProps {
5
5
  property: "gridStep";
@@ -5,6 +5,7 @@ interface CollapsibleProps {
5
5
  openTrigger: () => void;
6
6
  children: React.ReactNode;
7
7
  className?: string;
8
+ showCollapsedIcon?: boolean;
8
9
  }
9
- declare const Collapsible: ({ label, open, openTrigger, children, className, }: CollapsibleProps) => import("react/jsx-runtime").JSX.Element;
10
+ declare const Collapsible: ({ label, open, openTrigger, children, className, showCollapsedIcon, }: CollapsibleProps) => import("react/jsx-runtime").JSX.Element;
10
11
  export default Collapsible;
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface DimensionDragInputProps {
5
5
  property: "width" | "height";
@@ -1,8 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  import type { ElementsMap, ExcalidrawElement } from "@excalidraw/element/types";
3
+ import type { Scene } from "@excalidraw/element";
4
+ import { useApp, useExcalidrawSetAppState } from "../App";
3
5
  import "./DragInput.scss";
4
6
  import type { StatsInputProperty } from "./utils";
5
- import type Scene from "../../scene/Scene";
6
7
  import type { AppState } from "../../types";
7
8
  export type DragInputCallbackType<P extends StatsInputProperty, E = ExcalidrawElement> = (props: {
8
9
  accumulatedChange: number;
@@ -16,6 +17,14 @@ export type DragInputCallbackType<P extends StatsInputProperty, E = ExcalidrawEl
16
17
  property: P;
17
18
  originalAppState: AppState;
18
19
  setInputValue: (value: number) => void;
20
+ app: ReturnType<typeof useApp>;
21
+ setAppState: ReturnType<typeof useExcalidrawSetAppState>;
22
+ }) => void;
23
+ export type DragFinishedCallbackType<E = ExcalidrawElement> = (props: {
24
+ app: ReturnType<typeof useApp>;
25
+ setAppState: ReturnType<typeof useExcalidrawSetAppState>;
26
+ originalElements: readonly E[] | null;
27
+ originalAppState: AppState;
19
28
  }) => void;
20
29
  interface StatsDragInputProps<T extends StatsInputProperty, E = ExcalidrawElement> {
21
30
  label: string | React.ReactNode;
@@ -30,6 +39,7 @@ interface StatsDragInputProps<T extends StatsInputProperty, E = ExcalidrawElemen
30
39
  appState: AppState;
31
40
  /** how many px you need to drag to get 1 unit change */
32
41
  sensitivity?: number;
42
+ dragFinishedCallback?: DragFinishedCallbackType;
33
43
  }
34
- declare const StatsDragInput: <T extends StatsInputProperty, E extends ExcalidrawElement = ExcalidrawElement>({ label, icon, dragInputCallback, value, elements, editable, shouldKeepAspectRatio, property, scene, appState, sensitivity, }: StatsDragInputProps<T, E>) => import("react/jsx-runtime").JSX.Element | null;
44
+ declare const StatsDragInput: <T extends StatsInputProperty, E extends ExcalidrawElement = ExcalidrawElement>({ label, icon, dragInputCallback, value, elements, editable, shouldKeepAspectRatio, property, scene, appState, sensitivity, dragFinishedCallback, }: StatsDragInputProps<T, E>) => import("react/jsx-runtime").JSX.Element | null;
35
45
  export default StatsDragInput;
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface FontSizeProps {
5
5
  element: ExcalidrawElement;
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface MultiAngleProps {
5
5
  elements: readonly ExcalidrawElement[];
@@ -1,6 +1,6 @@
1
1
  import type { ExcalidrawElement, NonDeletedSceneElementsMap } from "@excalidraw/element/types";
2
+ import type { Scene } from "@excalidraw/element";
2
3
  import type { AtomicUnit } from "./utils";
3
- import type Scene from "../../scene/Scene";
4
4
  import type { AppState } from "../../types";
5
5
  interface MultiDimensionProps {
6
6
  property: "width" | "height";
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement, NonDeletedSceneElementsMap } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface MultiFontSizeProps {
5
5
  elements: readonly ExcalidrawElement[];
@@ -1,6 +1,6 @@
1
1
  import type { ElementsMap, ExcalidrawElement } from "@excalidraw/element/types";
2
+ import type { Scene } from "@excalidraw/element";
2
3
  import type { AtomicUnit } from "./utils";
3
- import type Scene from "../../scene/Scene";
4
4
  import type { AppState } from "../../types";
5
5
  interface MultiPositionProps {
6
6
  property: "x" | "y";
@@ -1,5 +1,5 @@
1
1
  import type { ElementsMap, ExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  interface PositionProps {
5
5
  property: "x" | "y";
@@ -1,8 +1,9 @@
1
- import type { ElementsMap, ExcalidrawElement, NonDeletedExcalidrawElement, NonDeletedSceneElementsMap } from "@excalidraw/element/types";
2
- import type Scene from "../../scene/Scene";
1
+ import type { ElementsMap, ExcalidrawElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../../types";
4
4
  export type StatsInputProperty = "x" | "y" | "width" | "height" | "angle" | "fontSize" | "gridStep";
5
5
  export declare const SMALLEST_DELTA = 0.01;
6
+ export declare const STEP_SIZE = 10;
6
7
  export declare const isPropertyEditable: (element: ExcalidrawElement, property: keyof ExcalidrawElement) => boolean;
7
8
  export declare const getStepSizedValue: (value: number, stepSize: number) => number;
8
9
  export type AtomicUnit = Record<string, true>;
@@ -14,13 +15,5 @@ export declare const newOrigin: (x1: number, y1: number, w1: number, h1: number,
14
15
  x: number;
15
16
  y: number;
16
17
  };
17
- export declare const moveElement: (newTopLeftX: number, newTopLeftY: number, originalElement: ExcalidrawElement, elementsMap: NonDeletedSceneElementsMap, elements: readonly NonDeletedExcalidrawElement[], scene: Scene, originalElementsMap: ElementsMap, shouldInformMutation?: boolean) => void;
18
+ export declare const moveElement: (newTopLeftX: number, newTopLeftY: number, originalElement: ExcalidrawElement, scene: Scene, originalElementsMap: ElementsMap, shouldInformMutation?: boolean) => void;
18
19
  export declare const getAtomicUnits: (targetElements: readonly ExcalidrawElement[], appState: AppState) => AtomicUnit[];
19
- export declare const updateBindings: (latestElement: ExcalidrawElement, elementsMap: NonDeletedSceneElementsMap, elements: readonly NonDeletedExcalidrawElement[], scene: Scene, options?: {
20
- simultaneouslyUpdated?: readonly ExcalidrawElement[];
21
- newSize?: {
22
- width: number;
23
- height: number;
24
- };
25
- zoom?: AppState["zoom"];
26
- }) => void;
@@ -0,0 +1,8 @@
1
+ import "./UnlockPopup.scss";
2
+ import type App from "./App";
3
+ import type { AppState } from "../types";
4
+ declare const UnlockPopup: ({ app, activeLockedId, }: {
5
+ app: App;
6
+ activeLockedId: NonNullable<AppState["activeLockedId"]>;
7
+ }) => import("react/jsx-runtime").JSX.Element | null;
8
+ export default UnlockPopup;
@@ -14,6 +14,7 @@ type InteractiveCanvasProps = {
14
14
  selectionNonce: number | undefined;
15
15
  scale: number;
16
16
  appState: InteractiveCanvasAppState;
17
+ renderScrollbars: boolean;
17
18
  device: Device;
18
19
  renderInteractiveSceneCallback: (data: RenderInteractiveSceneCallback) => void;
19
20
  handleCanvasRef: (canvas: HTMLCanvasElement | null) => void;
@@ -1,9 +1,10 @@
1
+ import type { Scene } from "@excalidraw/element";
1
2
  import type { ElementsMap, ExcalidrawEmbeddableElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
2
3
  import "./Hyperlink.scss";
3
4
  import type { AppState, ExcalidrawProps, UIAppState } from "../../types";
4
- export declare const Hyperlink: ({ element, elementsMap, setAppState, onLinkOpen, setToast, updateEmbedValidationStatus, }: {
5
+ export declare const Hyperlink: ({ element, scene, setAppState, onLinkOpen, setToast, updateEmbedValidationStatus, }: {
5
6
  element: NonDeletedExcalidrawElement;
6
- elementsMap: ElementsMap;
7
+ scene: Scene;
7
8
  setAppState: React.Component<any, AppState>["setState"];
8
9
  onLinkOpen: ExcalidrawProps["onLinkOpen"];
9
10
  setToast: (toast: {
@@ -1,7 +1,8 @@
1
1
  import type { GlobalPoint, Radians } from "@excalidraw/math";
2
- import type { Bounds } from "@excalidraw/element/bounds";
2
+ import type { Bounds } from "@excalidraw/element";
3
3
  import type { ElementsMap, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
4
4
  import type { AppState, UIAppState } from "../../types";
5
+ export declare const DEFAULT_LINK_SIZE = 12;
5
6
  export declare const EXTERNAL_LINK_IMG: HTMLImageElement;
6
7
  export declare const ELEMENT_LINK_IMG: HTMLImageElement;
7
8
  export declare const getLinkHandleFromCoords: ([x1, y1, x2, y2]: Bounds, angle: Radians, appState: Pick<UIAppState, "zoom">) => Bounds;
@@ -12,13 +12,16 @@ export declare const LibraryIcon: import("react/jsx-runtime").JSX.Element;
12
12
  export declare const PlusIcon: import("react/jsx-runtime").JSX.Element;
13
13
  export declare const DotsIcon: import("react/jsx-runtime").JSX.Element;
14
14
  export declare const PinIcon: import("react/jsx-runtime").JSX.Element;
15
+ export declare const polygonIcon: import("react/jsx-runtime").JSX.Element;
15
16
  export declare const UnlockedIcon: import("react/jsx-runtime").JSX.Element;
16
17
  export declare const LockedIcon: import("react/jsx-runtime").JSX.Element;
18
+ export declare const LockedIconFilled: import("react/jsx-runtime").JSX.Element;
17
19
  export declare const WelcomeScreenMenuArrow: import("react/jsx-runtime").JSX.Element;
18
20
  export declare const WelcomeScreenHelpArrow: import("react/jsx-runtime").JSX.Element;
19
21
  export declare const WelcomeScreenTopToolbarArrow: import("react/jsx-runtime").JSX.Element;
20
22
  export declare const ExcalLogo: import("react/jsx-runtime").JSX.Element;
21
23
  export declare const SelectionIcon: import("react/jsx-runtime").JSX.Element;
24
+ export declare const LassoIcon: import("react/jsx-runtime").JSX.Element;
22
25
  export declare const RectangleIcon: import("react/jsx-runtime").JSX.Element;
23
26
  export declare const DiamondIcon: import("react/jsx-runtime").JSX.Element;
24
27
  export declare const EllipseIcon: import("react/jsx-runtime").JSX.Element;
@@ -53,6 +56,7 @@ export declare const LoadIcon: import("react/jsx-runtime").JSX.Element;
53
56
  export declare const clipboard: import("react/jsx-runtime").JSX.Element;
54
57
  export declare const palette: import("react/jsx-runtime").JSX.Element;
55
58
  export declare const bucketFillIcon: import("react/jsx-runtime").JSX.Element;
59
+ export declare const slashIcon: import("react/jsx-runtime").JSX.Element;
56
60
  export declare const ExportImageIcon: import("react/jsx-runtime").JSX.Element;
57
61
  export declare const exportToFileIcon: import("react/jsx-runtime").JSX.Element;
58
62
  export declare const zoomIn: import("react/jsx-runtime").JSX.Element;
@@ -59,4 +59,4 @@ export declare const SHAPES: readonly [{
59
59
  readonly numericKey: "0";
60
60
  readonly fillable: false;
61
61
  }];
62
- export declare const findShapeByKey: (key: string) => "line" | "ellipse" | "text" | "rectangle" | "diamond" | "image" | "selection" | "arrow" | "freedraw" | "eraser" | null;
62
+ export declare const findShapeByKey: (key: string) => "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | null;
@@ -1,4 +1,4 @@
1
- import type { ElementConstructorOpts } from "@excalidraw/element/newElement";
1
+ import type { ElementConstructorOpts } from "@excalidraw/element";
2
2
  import type { ExcalidrawBindableElement, ExcalidrawElement, ExcalidrawFrameElement, ExcalidrawFreeDrawElement, ExcalidrawGenericElement, ExcalidrawIframeLikeElement, ExcalidrawImageElement, ExcalidrawLinearElement, ExcalidrawMagicFrameElement, ExcalidrawSelectionElement, ExcalidrawTextElement, FileId, FontFamilyValues, TextAlign, VerticalAlign } from "@excalidraw/element/types";
3
3
  import type { MarkOptional } from "@excalidraw/common/utility-types";
4
4
  export type ValidLinearElement = {
@@ -1,14 +1,14 @@
1
- import { atom, createStore, type PrimitiveAtom } from "jotai";
1
+ import { atom, createStore, type PrimitiveAtom, type WritableAtom } from "jotai";
2
2
  import { createIsolation } from "jotai-scope";
3
- export { atom, PrimitiveAtom };
3
+ export { atom, PrimitiveAtom, WritableAtom };
4
4
  export declare const useAtom: typeof import("jotai").useAtom, useSetAtom: typeof import("jotai").useSetAtom, useAtomValue: typeof import("jotai").useAtomValue, useStore: (options?: {
5
5
  store?: {
6
6
  get: <Value>(atom: import("jotai").Atom<Value>) => Value;
7
- set: <Value_1, Args extends unknown[], Result>(atom: import("jotai").WritableAtom<Value_1, Args, Result>, ...args: Args) => Result;
7
+ set: <Value_1, Args extends unknown[], Result>(atom: WritableAtom<Value_1, Args, Result>, ...args: Args) => Result;
8
8
  sub: (atom: import("jotai").Atom<unknown>, listener: () => void) => () => void;
9
9
  } | ({
10
10
  get: <Value_2>(atom: import("jotai").Atom<Value_2>) => Value_2;
11
- set: <Value_1_1, Args_1 extends unknown[], Result_1>(atom: import("jotai").WritableAtom<Value_1_1, Args_1, Result_1>, ...args: Args_1) => Result_1;
11
+ set: <Value_1_1, Args_1 extends unknown[], Result_1>(atom: WritableAtom<Value_1_1, Args_1, Result_1>, ...args: Args_1) => Result_1;
12
12
  sub: (atom: import("jotai").Atom<unknown>, listener: () => void) => () => void;
13
13
  } & {
14
14
  dev4_get_internal_weak_map: () => WeakMap<import("jotai").Atom<unknown>, {
@@ -29,11 +29,11 @@ export declare const useAtom: typeof import("jotai").useAtom, useSetAtom: typeof
29
29
  }) | undefined;
30
30
  } | undefined) => {
31
31
  get: <Value_3>(atom: import("jotai").Atom<Value_3>) => Value_3;
32
- set: <Value_1_2, Args_2 extends unknown[], Result_2>(atom: import("jotai").WritableAtom<Value_1_2, Args_2, Result_2>, ...args: Args_2) => Result_2;
32
+ set: <Value_1_2, Args_2 extends unknown[], Result_2>(atom: WritableAtom<Value_1_2, Args_2, Result_2>, ...args: Args_2) => Result_2;
33
33
  sub: (atom: import("jotai").Atom<unknown>, listener: () => void) => () => void;
34
34
  } | ({
35
35
  get: <Value_4>(atom: import("jotai").Atom<Value_4>) => Value_4;
36
- set: <Value_1_3, Args_3 extends unknown[], Result_3>(atom: import("jotai").WritableAtom<Value_1_3, Args_3, Result_3>, ...args: Args_3) => Result_3;
36
+ set: <Value_1_3, Args_3 extends unknown[], Result_3>(atom: WritableAtom<Value_1_3, Args_3, Result_3>, ...args: Args_3) => Result_3;
37
37
  sub: (atom: import("jotai").Atom<unknown>, listener: () => void) => () => void;
38
38
  } & {
39
39
  dev4_get_internal_weak_map: () => WeakMap<import("jotai").Atom<unknown>, {
@@ -0,0 +1,12 @@
1
+ import { AnimatedTrail } from "../animated-trail";
2
+ import type { AnimationFrameHandler } from "../animation-frame-handler";
3
+ import type App from "../components/App";
4
+ export declare class EraserTrail extends AnimatedTrail {
5
+ private elementsToErase;
6
+ private groupsToErase;
7
+ constructor(animationFrameHandler: AnimationFrameHandler, app: App);
8
+ startPath(x: number, y: number): void;
9
+ addPointToPath(x: number, y: number, restore?: boolean): string[];
10
+ private updateElementsToBeErased;
11
+ endPath(): void;
12
+ }
@@ -1,7 +1,7 @@
1
1
  import { type FontMetadata } from "@excalidraw/common";
2
2
  import type { ExcalidrawElement } from "@excalidraw/element/types";
3
+ import type { Scene } from "@excalidraw/element";
3
4
  import { ExcalidrawFontFace } from "./ExcalidrawFontFace";
4
- import type Scene from "../scene/Scene";
5
5
  export declare class Fonts {
6
6
  static readonly loadedFontsCache: Set<string>;
7
7
  private static _registered;
@@ -0,0 +1,48 @@
1
+ import { Emitter } from "@excalidraw/common";
2
+ import { StoreDelta } from "@excalidraw/element";
3
+ import type { StoreSnapshot, Store } from "@excalidraw/element";
4
+ import type { SceneElementsMap } from "@excalidraw/element/types";
5
+ import type { AppState } from "./types";
6
+ export declare class HistoryDelta extends StoreDelta {
7
+ /**
8
+ * Apply the delta to the passed elements and appState, does not modify the snapshot.
9
+ */
10
+ applyTo(elements: SceneElementsMap, appState: AppState, snapshot: StoreSnapshot): [SceneElementsMap, AppState, boolean];
11
+ /**
12
+ * Overriding once to avoid type casting everywhere.
13
+ */
14
+ static calculate(prevSnapshot: StoreSnapshot, nextSnapshot: StoreSnapshot): HistoryDelta;
15
+ /**
16
+ * Overriding once to avoid type casting everywhere.
17
+ */
18
+ static inverse(delta: StoreDelta): HistoryDelta;
19
+ /**
20
+ * Overriding once to avoid type casting everywhere.
21
+ */
22
+ static applyLatestChanges(delta: StoreDelta, prevElements: SceneElementsMap, nextElements: SceneElementsMap, modifierOptions?: "deleted" | "inserted"): HistoryDelta;
23
+ }
24
+ export declare class HistoryChangedEvent {
25
+ readonly isUndoStackEmpty: boolean;
26
+ readonly isRedoStackEmpty: boolean;
27
+ constructor(isUndoStackEmpty?: boolean, isRedoStackEmpty?: boolean);
28
+ }
29
+ export declare class History {
30
+ private readonly store;
31
+ readonly onHistoryChangedEmitter: Emitter<[HistoryChangedEvent]>;
32
+ readonly undoStack: HistoryDelta[];
33
+ readonly redoStack: HistoryDelta[];
34
+ get isUndoStackEmpty(): boolean;
35
+ get isRedoStackEmpty(): boolean;
36
+ constructor(store: Store);
37
+ clear(): void;
38
+ /**
39
+ * Record a non-empty local durable increment, which will go into the undo stack..
40
+ * Do not re-record history entries, which were already pushed to undo / redo stack, as part of history action.
41
+ */
42
+ record(delta: StoreDelta): void;
43
+ undo(elements: SceneElementsMap, appState: AppState): void | [SceneElementsMap, AppState];
44
+ redo(elements: SceneElementsMap, appState: AppState): void | [SceneElementsMap, AppState];
45
+ private perform;
46
+ private static pop;
47
+ private static push;
48
+ }
@@ -1,2 +1,2 @@
1
- import type { Emitter } from "../emitter";
1
+ import type { Emitter } from "@excalidraw/common";
2
2
  export declare const useEmitter: <TEvent extends unknown>(emitter: Emitter<[TEvent]>, initialState: TEvent) => TEvent;
@@ -9,20 +9,20 @@ import "./fonts/fonts.css";
9
9
  import type { ExcalidrawProps } from "./types";
10
10
  export declare const Excalidraw: React.MemoExoticComponent<(props: ExcalidrawProps) => import("react/jsx-runtime").JSX.Element>;
11
11
  export { getSceneVersion, hashElementsVersion, hashString, getNonDeletedElements, } from "@excalidraw/element";
12
- export { getTextFromElements } from "@excalidraw/element/textElement";
13
- export { isInvisiblySmallElement } from "@excalidraw/element/sizeHelpers";
12
+ export { getTextFromElements } from "@excalidraw/element";
13
+ export { isInvisiblySmallElement } from "@excalidraw/element";
14
14
  export { defaultLang, useI18n, languages } from "./i18n";
15
15
  export { restore, restoreAppState, restoreElements, restoreLibraryItems, } from "./data/restore";
16
16
  export { reconcileElements } from "./data/reconcile";
17
17
  export { exportToCanvas, exportToBlob, exportToSvg, exportToClipboard, } from "@excalidraw/utils/export";
18
18
  export { serializeAsJSON, serializeLibraryAsJSON } from "./data/json";
19
19
  export { loadFromBlob, loadSceneOrLibraryFromBlob, loadLibraryFromBlob, } from "./data/blob";
20
- export { getFreeDrawSvgPath } from "@excalidraw/element/renderElement";
20
+ export { getFreeDrawSvgPath } from "@excalidraw/element";
21
21
  export { mergeLibraryItems, getLibraryItemsHash } from "./data/library";
22
- export { isLinearElement } from "@excalidraw/element/typeChecks";
22
+ export { isLinearElement } from "@excalidraw/element";
23
23
  export { FONT_FAMILY, THEME, MIME_TYPES, ROUNDNESS, DEFAULT_LASER_COLOR, UserIdleState, normalizeLink, } from "@excalidraw/common";
24
- export { mutateElement, newElementWith, bumpVersion, } from "@excalidraw/element/mutateElement";
25
- export { CaptureUpdateAction } from "./store";
24
+ export { mutateElement, newElementWith, bumpVersion, } from "@excalidraw/element";
25
+ export { CaptureUpdateAction } from "@excalidraw/element";
26
26
  export { parseLibraryTokensFromUrl, useHandleLibrary } from "./data/library";
27
27
  export { sceneCoordsToViewportCoords, viewportCoordsToSceneCoords, } from "@excalidraw/common";
28
28
  export { Sidebar } from "./components/Sidebar/Sidebar";
@@ -38,9 +38,9 @@ export { TTDDialog } from "./components/TTDDialog/TTDDialog";
38
38
  export { TTDDialogTrigger } from "./components/TTDDialog/TTDDialogTrigger";
39
39
  export { zoomToFitBounds } from "./actions/actionCanvas";
40
40
  export { convertToExcalidrawElements } from "./data/transform";
41
- export { getCommonBounds, getVisibleSceneBounds, } from "@excalidraw/element/bounds";
41
+ export { getCommonBounds, getVisibleSceneBounds } from "@excalidraw/element";
42
42
  export { elementsOverlappingBBox, isElementInsideBBox, elementPartiallyOverlapsWithOrContainsBBox, } from "@excalidraw/utils/withinBounds";
43
43
  export { DiagramToCodePlugin } from "./components/DiagramToCodePlugin/DiagramToCodePlugin";
44
44
  export { getDataURL } from "./data/blob";
45
- export { isElementLink } from "@excalidraw/element/elementLink";
46
- export { setCustomTextMetricsProvider } from "@excalidraw/element/textMeasurements";
45
+ export { isElementLink } from "@excalidraw/element";
46
+ export { setCustomTextMetricsProvider } from "@excalidraw/element";
@@ -0,0 +1,16 @@
1
+ import { type AnimationFrameHandler } from "../animation-frame-handler";
2
+ import { AnimatedTrail } from "../animated-trail";
3
+ import type App from "../components/App";
4
+ export declare class LassoTrail extends AnimatedTrail {
5
+ private intersectedElements;
6
+ private enclosedElements;
7
+ private elementsSegments;
8
+ private canvasTranslate;
9
+ private keepPreviousSelection;
10
+ constructor(animationFrameHandler: AnimationFrameHandler, app: App);
11
+ startPath(x: number, y: number, keepPreviousSelection?: boolean): void;
12
+ selectElementsFromIds: (ids: string[]) => void;
13
+ addPointToPath: (x: number, y: number, keepPreviousSelection?: boolean) => void;
14
+ private updateSelection;
15
+ endPath(): void;
16
+ }
@@ -0,0 +1,13 @@
1
+ import type { ElementsSegmentsMap, GlobalPoint } from "@excalidraw/math/types";
2
+ import type { ElementsMap, ExcalidrawElement } from "@excalidraw/element/types";
3
+ export declare const getLassoSelectedElementIds: (input: {
4
+ lassoPath: GlobalPoint[];
5
+ elements: readonly ExcalidrawElement[];
6
+ elementsMap: ElementsMap;
7
+ elementsSegments: ElementsSegmentsMap;
8
+ intersectedElements: Set<ExcalidrawElement["id"]>;
9
+ enclosedElements: Set<ExcalidrawElement["id"]>;
10
+ simplifyDistance?: number;
11
+ }) => {
12
+ selectedElementIds: string[];
13
+ };
@@ -0,0 +1,18 @@
1
+ import type { ElementsMap, ExcalidrawDiamondElement, ExcalidrawRectanguloidElement } from "@excalidraw/element/types";
2
+ import type { StaticCanvasRenderConfig } from "../scene/types";
3
+ import type { AppState, StaticCanvasAppState } from "../types";
4
+ export declare const fillCircle: (context: CanvasRenderingContext2D, cx: number, cy: number, radius: number, stroke: boolean, fill?: boolean) => void;
5
+ export declare const getNormalizedCanvasDimensions: (canvas: HTMLCanvasElement, scale: number) => [number, number];
6
+ export declare const bootstrapCanvas: ({ canvas, scale, normalizedWidth, normalizedHeight, theme, isExporting, viewBackgroundColor, }: {
7
+ canvas: HTMLCanvasElement;
8
+ scale: number;
9
+ normalizedWidth: number;
10
+ normalizedHeight: number;
11
+ theme?: import("@excalidraw/element/types").Theme | undefined;
12
+ isExporting?: boolean | undefined;
13
+ viewBackgroundColor?: string | null | undefined;
14
+ }) => CanvasRenderingContext2D;
15
+ export declare const drawHighlightForRectWithRotation: (context: CanvasRenderingContext2D, element: ExcalidrawRectanguloidElement, elementsMap: ElementsMap, padding: number) => void;
16
+ export declare const strokeEllipseWithRotation: (context: CanvasRenderingContext2D, width: number, height: number, cx: number, cy: number, angle: number) => void;
17
+ export declare const strokeRectWithRotation: (context: CanvasRenderingContext2D, x: number, y: number, width: number, height: number, cx: number, cy: number, angle: number, fill?: boolean, radius?: number) => void;
18
+ export declare const drawHighlightForDiamondWithRotation: (context: CanvasRenderingContext2D, padding: number, element: ExcalidrawDiamondElement, elementsMap: ElementsMap) => void;
@@ -1,5 +1,5 @@
1
1
  import type { ExcalidrawElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
2
- import type Scene from "./Scene";
2
+ import type { Scene } from "@excalidraw/element";
3
3
  import type { AppState } from "../types";
4
4
  export declare class Renderer {
5
5
  private scene;
@@ -16,7 +16,6 @@ export declare class Renderer {
16
16
  /** note: first render of newElement will always bust the cache
17
17
  * (we'd have to prefilter elements outside of this function) */
18
18
  newElementId: ExcalidrawElement["id"] | undefined;
19
- pendingImageElementId: AppState["pendingImageElementId"];
20
19
  sceneNonce: ReturnType<InstanceType<typeof Scene>["getSceneNonce"]>;
21
20
  }) => {
22
21
  elementsMap: Map<string, NonDeletedExcalidrawElement> & import("@excalidraw/common/utility-types").MakeBrand<"NonDeletedElementsMap"> & import("@excalidraw/common/utility-types").MakeBrand<"RenderableElementsMap">;
@@ -0,0 +1,4 @@
1
+ export { isSomeElementSelected, getElementsWithinSelection, getSelectedElements, getTargetElements, } from "@excalidraw/element";
2
+ export { calculateScrollCenter } from "./scroll";
3
+ export { hasBackground, hasStrokeWidth, hasStrokeStyle, canHaveArrowheads, canChangeRoundness, } from "@excalidraw/element";
4
+ export { getNormalizedZoom, getNormalizedGridSize, getNormalizedGridStep, } from "./normalize";
@@ -1,10 +1,9 @@
1
- import type { ExcalidrawElement } from "@excalidraw/element/types";
2
1
  import type { InteractiveCanvasAppState } from "../types";
3
- import type { ScrollBars } from "./types";
2
+ import type { RenderableElementsMap, ScrollBars } from "./types";
4
3
  export declare const SCROLLBAR_MARGIN = 4;
5
4
  export declare const SCROLLBAR_WIDTH = 6;
6
5
  export declare const SCROLLBAR_COLOR = "rgba(0,0,0,0.3)";
7
- export declare const getScrollBars: (elements: readonly ExcalidrawElement[], viewportWidth: number, viewportHeight: number, appState: InteractiveCanvasAppState) => ScrollBars;
6
+ export declare const getScrollBars: (elements: RenderableElementsMap, viewportWidth: number, viewportHeight: number, appState: InteractiveCanvasAppState) => ScrollBars;
8
7
  export declare const isOverScrollBars: (scrollBars: ScrollBars, x: number, y: number) => {
9
8
  isOverEither: boolean;
10
9
  isOverHorizontal: boolean;
@@ -93,12 +93,14 @@ export type ScrollBars = {
93
93
  y: number;
94
94
  width: number;
95
95
  height: number;
96
+ deltaMultiplier: number;
96
97
  } | null;
97
98
  vertical: {
98
99
  x: number;
99
100
  y: number;
100
101
  width: number;
101
102
  height: number;
103
+ deltaMultiplier: number;
102
104
  } | null;
103
105
  };
104
106
  export type ElementShape = Drawable | Drawable[] | null;
@@ -1,7 +1,7 @@
1
1
  import { type GlobalPoint } from "@excalidraw/math";
2
2
  import type { InclusiveRange } from "@excalidraw/math";
3
- import type { Bounds } from "@excalidraw/element/bounds";
4
- import type { MaybeTransformHandleType } from "@excalidraw/element/transformHandles";
3
+ import type { Bounds } from "@excalidraw/element";
4
+ import type { MaybeTransformHandleType } from "@excalidraw/element";
5
5
  import type { ElementsMap, ExcalidrawElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
6
6
  import type { AppClassProperties, AppState, KeyboardModifiersObject } from "./types";
7
7
  export declare const getSnapDistance: (zoomValue: number) => number;