@excalidraw/excalidraw 0.9.0 → 0.11.0-11a3380

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 (624) hide show
  1. package/CHANGELOG.md +498 -3
  2. package/README.md +537 -101
  3. package/dist/excalidraw-assets/i18n-ar-SA-json-f37c9765d6ba9c94db28.js +1 -0
  4. package/dist/excalidraw-assets/i18n-bg-BG-json-d8c72e41cf02e763b54c.js +1 -0
  5. package/dist/excalidraw-assets/i18n-bn-BD-json-246ddff2b69891d1399d.js +1 -0
  6. package/dist/excalidraw-assets/i18n-ca-ES-json-2583291c4633e96df9d6.js +1 -0
  7. package/dist/excalidraw-assets/i18n-cs-CZ-json-7fb82d30a7139f991154.js +1 -0
  8. package/dist/excalidraw-assets/i18n-da-DK-json-5f58e2d75044deee8410.js +1 -0
  9. package/dist/excalidraw-assets/i18n-de-DE-json-20912cca3094f0524a21.js +1 -0
  10. package/dist/excalidraw-assets/i18n-el-GR-json-96277306136a9ee3d56c.js +1 -0
  11. package/dist/excalidraw-assets/i18n-es-ES-json-2d9209d0d8b45e340212.js +1 -0
  12. package/dist/excalidraw-assets/i18n-eu-ES-json-40142a580d932c8cb50d.js +1 -0
  13. package/dist/excalidraw-assets/i18n-fa-IR-json-5aa04fe7e238f87f3607.js +1 -0
  14. package/dist/excalidraw-assets/i18n-fi-FI-json-2e5665a625fe47e2a60f.js +1 -0
  15. package/dist/excalidraw-assets/i18n-fr-FR-json-ad79d60ccbf7da435101.js +1 -0
  16. package/dist/excalidraw-assets/i18n-he-IL-json-5aa3ca202abb250e82bd.js +1 -0
  17. package/dist/excalidraw-assets/i18n-hi-IN-json-8fe2d63926e008f5725c.js +1 -0
  18. package/dist/excalidraw-assets/i18n-hu-HU-json-78e1c51d6d92ed32aa2f.js +1 -0
  19. package/dist/excalidraw-assets/i18n-id-ID-json-6c529ed7cc3d5353bdc0.js +1 -0
  20. package/dist/excalidraw-assets/i18n-it-IT-json-7c39e59e8682963a7851.js +1 -0
  21. package/dist/excalidraw-assets/i18n-ja-JP-json-2263e6c8e274763d04cc.js +1 -0
  22. package/dist/excalidraw-assets/i18n-kab-KAB-json-9974a930bde67748d79a.js +1 -0
  23. package/dist/excalidraw-assets/i18n-kk-KZ-json-b1da82815e51b638b28e.js +1 -0
  24. package/dist/excalidraw-assets/i18n-ko-KR-json-36dce31f57535a3884fc.js +1 -0
  25. package/dist/excalidraw-assets/i18n-lt-LT-json-7e4b8147241a2807a1f1.js +1 -0
  26. package/dist/excalidraw-assets/i18n-lv-LV-json-0292c4b3153e02ba01cc.js +1 -0
  27. package/dist/excalidraw-assets/i18n-mr-IN-json-85e3bad5588e60eda6ed.js +1 -0
  28. package/dist/excalidraw-assets/i18n-my-MM-json-a50d126ec63009915802.js +1 -0
  29. package/dist/excalidraw-assets/i18n-nb-NO-json-dd7cd6513e3d00551949.js +1 -0
  30. package/dist/excalidraw-assets/i18n-nl-NL-json-a2e36932c7b397dfdf8b.js +1 -0
  31. package/dist/excalidraw-assets/i18n-nn-NO-json-76159e8cfa136255e657.js +1 -0
  32. package/dist/excalidraw-assets/i18n-oc-FR-json-8fcbd2e5e589bc9b3f05.js +1 -0
  33. package/dist/excalidraw-assets/i18n-pa-IN-json-664d068563584bb41ae4.js +1 -0
  34. package/dist/excalidraw-assets/i18n-pl-PL-json-17d817993f240f65dc1f.js +1 -0
  35. package/dist/excalidraw-assets/i18n-pt-BR-json-dfbe3455644130e9851c.js +1 -0
  36. package/dist/excalidraw-assets/i18n-pt-PT-json-bda935fce18a7b179bcb.js +1 -0
  37. package/dist/excalidraw-assets/i18n-ro-RO-json-3473997bac53931c8b1c.js +1 -0
  38. package/dist/excalidraw-assets/i18n-ru-RU-json-2a58c91c91fbb9009a4a.js +1 -0
  39. package/dist/excalidraw-assets/i18n-si-LK-json-0ad49043e4c810f4e8f2.js +1 -0
  40. package/dist/excalidraw-assets/i18n-sk-SK-json-6a88d3cef7420263d448.js +1 -0
  41. package/dist/excalidraw-assets/i18n-sl-SI-json-d883f256ad475721b51e.js +1 -0
  42. package/dist/excalidraw-assets/i18n-sv-SE-json-ab9784b6a181e4b3e52b.js +1 -0
  43. package/dist/excalidraw-assets/i18n-ta-IN-json-49b6bc876b7703f493e7.js +1 -0
  44. package/dist/excalidraw-assets/i18n-tr-TR-json-e6a720f75140ee82da6d.js +1 -0
  45. package/dist/excalidraw-assets/i18n-uk-UA-json-1d95323ec8040114490e.js +1 -0
  46. package/dist/excalidraw-assets/i18n-zh-CN-json-facce09827627d918c14.js +1 -0
  47. package/dist/excalidraw-assets/i18n-zh-HK-json-a6e21fe69a6a6f8c8ea6.js +1 -0
  48. package/dist/excalidraw-assets/i18n-zh-TW-json-37610fbce479c7f8cef2.js +1 -0
  49. package/dist/excalidraw-assets/vendor-52b1f3361986b6c6a4fe.js +2 -0
  50. package/dist/excalidraw-assets/vendor-52b1f3361986b6c6a4fe.js.LICENSE.txt +12 -0
  51. package/dist/excalidraw-assets-dev/i18n-ar-SA-json-505ef559f47ea6b69719.js +22 -0
  52. package/dist/excalidraw-assets-dev/i18n-bg-BG-json-bcb00de8d85335103437.js +22 -0
  53. package/dist/excalidraw-assets-dev/i18n-bn-BD-json-20cb88b768b6656f69a0.js +22 -0
  54. package/dist/excalidraw-assets-dev/i18n-ca-ES-json-c0a2946ac526da48c821.js +22 -0
  55. package/dist/excalidraw-assets-dev/i18n-cs-CZ-json-3b57cc3db37bad8747c9.js +22 -0
  56. package/dist/excalidraw-assets-dev/i18n-da-DK-json-9fd1d27b5e867510c0c4.js +22 -0
  57. package/dist/excalidraw-assets-dev/i18n-de-DE-json-80aa4aed6cc5f0f47bec.js +22 -0
  58. package/dist/excalidraw-assets-dev/i18n-el-GR-json-08221c6f5387a7ef440e.js +22 -0
  59. package/dist/excalidraw-assets-dev/i18n-es-ES-json-bb7d7aa7840ad87ac15d.js +22 -0
  60. package/dist/excalidraw-assets-dev/i18n-eu-ES-json-1aff52bfd1a98cc073a3.js +22 -0
  61. package/dist/excalidraw-assets-dev/i18n-fa-IR-json-1af59f1130dd499b2aee.js +22 -0
  62. package/dist/excalidraw-assets-dev/i18n-fi-FI-json-874b4f80c8cb7c54ba9e.js +22 -0
  63. package/dist/excalidraw-assets-dev/i18n-fr-FR-json-b55b922b008349e24e30.js +22 -0
  64. package/dist/excalidraw-assets-dev/i18n-he-IL-json-e16fce9c2852e89a31f2.js +22 -0
  65. package/dist/excalidraw-assets-dev/i18n-hi-IN-json-96d1324664dcf226249e.js +22 -0
  66. package/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e29c373127695ccfe28.js +22 -0
  67. package/dist/excalidraw-assets-dev/i18n-id-ID-json-c3b8c47e9f2cd5a218a4.js +22 -0
  68. package/dist/excalidraw-assets-dev/i18n-it-IT-json-c4ba0fd51730152b3389.js +22 -0
  69. package/dist/excalidraw-assets-dev/i18n-ja-JP-json-4fb9df48c7c2aca8709b.js +22 -0
  70. package/dist/excalidraw-assets-dev/i18n-kab-KAB-json-56a2f5b742bb44d84587.js +22 -0
  71. package/dist/excalidraw-assets-dev/i18n-kk-KZ-json-69f5849187a51635aa55.js +22 -0
  72. package/dist/excalidraw-assets-dev/i18n-ko-KR-json-be749d83561b4547fca0.js +22 -0
  73. package/dist/excalidraw-assets-dev/i18n-lt-LT-json-f74d8fbb36e64d164cb3.js +22 -0
  74. package/dist/excalidraw-assets-dev/i18n-lv-LV-json-05cafa9d59e825d37a30.js +22 -0
  75. package/dist/excalidraw-assets-dev/i18n-mr-IN-json-4df0aaed6b5bd9c354bf.js +22 -0
  76. package/dist/excalidraw-assets-dev/i18n-my-MM-json-10cd0a77755d74cc2d88.js +22 -0
  77. package/dist/excalidraw-assets-dev/i18n-nb-NO-json-0328d43c8eb21619f1ef.js +22 -0
  78. package/dist/excalidraw-assets-dev/i18n-nl-NL-json-ce7bba8e06a59e62a4d0.js +22 -0
  79. package/dist/excalidraw-assets-dev/i18n-nn-NO-json-64d56d9257aa9516e081.js +22 -0
  80. package/dist/excalidraw-assets-dev/i18n-oc-FR-json-efae2c9bbbc42a6f6c70.js +22 -0
  81. package/dist/excalidraw-assets-dev/i18n-pa-IN-json-6378d9552735e33a9fe3.js +22 -0
  82. package/dist/excalidraw-assets-dev/i18n-pl-PL-json-ed1bf39b6b8f8061299d.js +22 -0
  83. package/dist/excalidraw-assets-dev/i18n-pt-BR-json-2a02a619bfa9700ce852.js +22 -0
  84. package/dist/excalidraw-assets-dev/i18n-pt-PT-json-d28b9a54ff94e15ff9bb.js +22 -0
  85. package/dist/excalidraw-assets-dev/i18n-ro-RO-json-00d5715f05aa3063960a.js +22 -0
  86. package/dist/excalidraw-assets-dev/i18n-ru-RU-json-ac0637166d5b462e339f.js +22 -0
  87. package/dist/excalidraw-assets-dev/i18n-si-LK-json-63d7c3f1c548dd28b002.js +22 -0
  88. package/dist/excalidraw-assets-dev/i18n-sk-SK-json-42cdbcaa7b9a48f2d39f.js +22 -0
  89. package/dist/excalidraw-assets-dev/i18n-sl-SI-json-56b1f2e0db09f030df1d.js +22 -0
  90. package/dist/excalidraw-assets-dev/i18n-sv-SE-json-3eb8200f34c205bc6564.js +22 -0
  91. package/dist/excalidraw-assets-dev/i18n-ta-IN-json-6d1328c5b1be8952f272.js +22 -0
  92. package/dist/excalidraw-assets-dev/i18n-tr-TR-json-f19e7eace448e972fc37.js +22 -0
  93. package/dist/excalidraw-assets-dev/i18n-uk-UA-json-da0e1d496b320531f5dc.js +22 -0
  94. package/dist/excalidraw-assets-dev/i18n-zh-CN-json-84fc26b884a0a83892c9.js +22 -0
  95. package/dist/excalidraw-assets-dev/i18n-zh-HK-json-07799e9c9378a2263273.js +22 -0
  96. package/dist/excalidraw-assets-dev/i18n-zh-TW-json-61c7460fdc361e477121.js +22 -0
  97. package/dist/excalidraw-assets-dev/vendor-c0592035c3911af79359.js +98 -0
  98. package/dist/excalidraw.development.js +1065 -350
  99. package/dist/excalidraw.production.min.js +1 -1
  100. package/dist/excalidraw.production.min.js.LICENSE.txt +23 -1
  101. package/package.json +32 -25
  102. package/types/actions/actionAddToLibrary.d.ts +298 -1
  103. package/types/actions/actionAlign.d.ts +91 -6
  104. package/types/actions/actionBoundText.d.ts +123 -0
  105. package/types/actions/actionCanvas.d.ts +861 -8
  106. package/types/actions/actionClipboard.d.ts +563 -4
  107. package/types/actions/actionDeleteSelected.d.ts +323 -1
  108. package/types/actions/actionDistribute.d.ts +33 -2
  109. package/types/actions/actionDuplicateSelection.d.ts +22 -1
  110. package/types/actions/actionExport.d.ts +956 -8
  111. package/types/actions/actionFinalize.d.ts +206 -1
  112. package/types/actions/actionFlip.d.ts +35 -2
  113. package/types/actions/actionGroup.d.ts +45 -2
  114. package/types/actions/actionMenu.d.ts +334 -4
  115. package/types/actions/actionNavigate.d.ts +14 -1
  116. package/types/actions/actionProperties.d.ts +1389 -12
  117. package/types/actions/actionSelectAll.d.ts +15 -1
  118. package/types/actions/actionStyles.d.ts +125 -2
  119. package/types/actions/actionToggleGridMode.d.ts +111 -1
  120. package/types/actions/actionToggleLock.d.ts +17 -0
  121. package/types/actions/actionToggleStats.d.ts +109 -1
  122. package/types/actions/actionToggleViewMode.d.ts +110 -1
  123. package/types/actions/actionToggleZenMode.d.ts +110 -1
  124. package/types/actions/actionZindex.d.ts +67 -4
  125. package/types/actions/index.d.ts +5 -2
  126. package/types/actions/manager.d.ts +10 -15
  127. package/types/actions/register.d.ts +3 -1
  128. package/types/actions/shortcuts.d.ts +2 -1
  129. package/types/actions/types.d.ts +20 -24
  130. package/types/align.d.ts +0 -1
  131. package/types/analytics.d.ts +1 -1
  132. package/types/appState.d.ts +27 -11
  133. package/types/charts.d.ts +8 -0
  134. package/types/clipboard.d.ts +5 -4
  135. package/types/components/Actions.d.ts +9 -5
  136. package/types/components/App.d.ts +68 -17
  137. package/types/components/Avatar.d.ts +3 -2
  138. package/types/components/ButtonIconSelect.d.ts +1 -0
  139. package/types/components/Card.d.ts +1 -1
  140. package/types/components/CheckboxItem.d.ts +2 -1
  141. package/types/components/ClearCanvas.d.ts +5 -0
  142. package/types/components/ColorPicker.d.ts +6 -1
  143. package/types/components/ConfirmDialog.d.ts +11 -0
  144. package/types/components/ContextMenu.d.ts +3 -0
  145. package/types/components/DarkModeToggle.d.ts +3 -3
  146. package/types/components/Dialog.d.ts +4 -2
  147. package/types/components/HintViewer.d.ts +3 -2
  148. package/types/components/ImageExportDialog.d.ts +5 -4
  149. package/types/components/InitializeApp.d.ts +2 -10
  150. package/types/components/JSONExportDialog.d.ts +6 -5
  151. package/types/components/LayerUI.d.ts +12 -5
  152. package/types/components/LibraryButton.d.ts +1 -0
  153. package/types/components/LibraryMenu.d.ts +18 -0
  154. package/types/components/LibraryMenuItems.d.ts +24 -0
  155. package/types/components/LibraryUnit.d.ts +9 -5
  156. package/types/components/LoadingMessage.d.ts +3 -1
  157. package/types/components/LockButton.d.ts +1 -0
  158. package/types/components/MobileMenu.d.ts +8 -2
  159. package/types/components/Modal.d.ts +1 -0
  160. package/types/components/PasteChartDialog.d.ts +1 -1
  161. package/types/components/{LockIcon.d.ts → PenModeButton.d.ts} +4 -5
  162. package/types/components/Popover.d.ts +5 -1
  163. package/types/components/PublishLibrary.d.ts +17 -0
  164. package/types/components/SidebarLockButton.d.ts +9 -0
  165. package/types/components/SingleLibraryItem.d.ts +11 -0
  166. package/types/components/Spinner.d.ts +7 -0
  167. package/types/components/Stack.d.ts +1 -1
  168. package/types/components/Toast.d.ts +3 -1
  169. package/types/components/ToolButton.d.ts +15 -4
  170. package/types/components/Tooltip.d.ts +9 -1
  171. package/types/components/UserList.d.ts +6 -5
  172. package/types/components/icons.d.ts +57 -40
  173. package/types/constants.d.ts +45 -11
  174. package/types/data/blob.d.ts +44 -4
  175. package/types/data/encode.d.ts +29 -1
  176. package/types/data/encryption.d.ts +9 -0
  177. package/types/data/filesystem.d.ts +18 -0
  178. package/types/data/index.d.ts +5 -3
  179. package/types/data/json.d.ts +8 -9
  180. package/types/data/library.d.ts +90 -8
  181. package/types/data/resave.d.ts +5 -0
  182. package/types/data/restore.d.ts +5 -3
  183. package/types/data/types.d.ts +9 -4
  184. package/types/{disitrubte.d.ts → distribute.d.ts} +0 -1
  185. package/types/element/Hyperlink.d.ts +131 -0
  186. package/types/element/bounds.d.ts +12 -1
  187. package/types/element/collision.d.ts +4 -2
  188. package/types/element/dragElements.d.ts +3 -5
  189. package/types/element/image.d.ts +22 -0
  190. package/types/element/index.d.ts +2 -4
  191. package/types/element/linearElementEditor.d.ts +142 -9
  192. package/types/element/mutateElement.d.ts +2 -2
  193. package/types/element/newElement.d.ts +8 -3
  194. package/types/element/resizeElements.d.ts +3 -3
  195. package/types/element/sizeHelpers.d.ts +2 -1
  196. package/types/element/textElement.d.ts +26 -2
  197. package/types/element/textWysiwyg.d.ts +6 -5
  198. package/types/element/typeChecks.d.ts +11 -5
  199. package/types/element/types.d.ts +35 -8
  200. package/types/errors.d.ts +3 -0
  201. package/types/galines.d.ts +1 -1
  202. package/types/groups.d.ts +1 -0
  203. package/types/i18n.d.ts +1 -1
  204. package/types/jotai.d.ts +122 -0
  205. package/types/keys.d.ts +10 -3
  206. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-2d5f019d3158606ce049.d.ts → excalidraw-assets/i18n-ar-SA-json-f37c9765d6ba9c94db28.d.ts} +0 -0
  207. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-4d16bcc700cc54fb5150.d.ts → excalidraw-assets/i18n-bg-BG-json-d8c72e41cf02e763b54c.d.ts} +0 -0
  208. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-54b9f1fcf9d30cb7e16b.d.ts → excalidraw-assets/i18n-bn-BD-json-246ddff2b69891d1399d.d.ts} +0 -0
  209. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-88b8054cb50aeb2839a0.d.ts → excalidraw-assets/i18n-ca-ES-json-2583291c4633e96df9d6.d.ts} +0 -0
  210. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-ade0d6de22b384a864b5.d.ts → excalidraw-assets/i18n-cs-CZ-json-7fb82d30a7139f991154.d.ts} +0 -0
  211. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-e3aeb716c01117aa817c.d.ts → excalidraw-assets/i18n-da-DK-json-5f58e2d75044deee8410.d.ts} +0 -0
  212. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-35458983ee43054138fb.d.ts → excalidraw-assets/i18n-de-DE-json-20912cca3094f0524a21.d.ts} +0 -0
  213. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-87b1add30a2f905d5383.d.ts → excalidraw-assets/i18n-el-GR-json-96277306136a9ee3d56c.d.ts} +0 -0
  214. package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-b5a444a20160d317c888.d.ts → excalidraw-assets/i18n-es-ES-json-2d9209d0d8b45e340212.d.ts} +0 -0
  215. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9a3fdf94110439c2826a.d.ts → i18n-eu-ES-json-40142a580d932c8cb50d.d.ts} +0 -0
  216. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9a7bef3582993b3fde41.d.ts → i18n-fa-IR-json-5aa04fe7e238f87f3607.d.ts} +0 -0
  217. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9bf98c30c5eacdcb1d2b.d.ts → i18n-fi-FI-json-2e5665a625fe47e2a60f.d.ts} +0 -0
  218. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-efd63375f9605b72c4af.d.ts → i18n-fr-FR-json-ad79d60ccbf7da435101.d.ts} +0 -0
  219. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-047db6df7a74c0298938.d.ts → i18n-he-IL-json-5aa3ca202abb250e82bd.d.ts} +0 -0
  220. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-35c0e8b92b0dba8a4e6d.d.ts → i18n-hi-IN-json-8fe2d63926e008f5725c.d.ts} +0 -0
  221. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-93c3fd2b081c849d4e04.d.ts → i18n-hu-HU-json-78e1c51d6d92ed32aa2f.d.ts} +0 -0
  222. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-deaa23a1909c5ca3188b.d.ts → i18n-id-ID-json-6c529ed7cc3d5353bdc0.d.ts} +0 -0
  223. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-08195bd47d46584560ff.d.ts → i18n-it-IT-json-7c39e59e8682963a7851.d.ts} +0 -0
  224. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-6acefe26cfe1d2f12349.d.ts → i18n-ja-JP-json-2263e6c8e274763d04cc.d.ts} +0 -0
  225. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-9924fbd53652d5f15134.d.ts → i18n-kab-KAB-json-9974a930bde67748d79a.d.ts} +0 -0
  226. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-cdcaf0f176ae3bed5fae.d.ts → i18n-kk-KZ-json-b1da82815e51b638b28e.d.ts} +0 -0
  227. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-e749f7948c1b822fc757.d.ts → i18n-ko-KR-json-36dce31f57535a3884fc.d.ts} +0 -0
  228. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-cs-CZ-json-85a469d813bb069829e7.d.ts → i18n-lt-LT-json-7e4b8147241a2807a1f1.d.ts} +0 -0
  229. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-cs-CZ-json-8b577e35bb3be3287a0b.d.ts → i18n-lv-LV-json-0292c4b3153e02ba01cc.d.ts} +0 -0
  230. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-3fafb93744f3fe7634ea.d.ts → i18n-mr-IN-json-85e3bad5588e60eda6ed.d.ts} +0 -0
  231. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-a52c17c4bd1b1db22464.d.ts → i18n-my-MM-json-a50d126ec63009915802.d.ts} +0 -0
  232. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-e521697dab684b2ac173.d.ts → i18n-nb-NO-json-dd7cd6513e3d00551949.d.ts} +0 -0
  233. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-f72002171c2c56b967cd.d.ts → i18n-nl-NL-json-a2e36932c7b397dfdf8b.d.ts} +0 -0
  234. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-f85a8a52534c04c3f3b8.d.ts → i18n-nn-NO-json-76159e8cfa136255e657.d.ts} +0 -0
  235. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-060595a09e0004e33936.d.ts → i18n-oc-FR-json-8fcbd2e5e589bc9b3f05.d.ts} +0 -0
  236. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-0ae6dd3287c4d9187ed9.d.ts → i18n-pa-IN-json-664d068563584bb41ae4.d.ts} +0 -0
  237. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-3b209ec86ca2ce69bdfa.d.ts → i18n-pl-PL-json-17d817993f240f65dc1f.d.ts} +0 -0
  238. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-f8f9a3a1729a4935edbc.d.ts → i18n-pt-BR-json-dfbe3455644130e9851c.d.ts} +0 -0
  239. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-2c2246b5f03e518b157c.d.ts → i18n-pt-PT-json-bda935fce18a7b179bcb.d.ts} +0 -0
  240. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-32dc3bf0f789ef18e65d.d.ts → i18n-ro-RO-json-3473997bac53931c8b1c.d.ts} +0 -0
  241. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-af5c541f9ac1526a9eb7.d.ts → i18n-ru-RU-json-2a58c91c91fbb9009a4a.d.ts} +0 -0
  242. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-f96b60c302d96c66ffd7.d.ts → i18n-si-LK-json-0ad49043e4c810f4e8f2.d.ts} +0 -0
  243. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-7ee232d4ef08da0903f6.d.ts → i18n-sk-SK-json-6a88d3cef7420263d448.d.ts} +0 -0
  244. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-95e4c55eb845ae827609.d.ts → i18n-sl-SI-json-d883f256ad475721b51e.d.ts} +0 -0
  245. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-c732ff7772327332c259.d.ts → i18n-sv-SE-json-ab9784b6a181e4b3e52b.d.ts} +0 -0
  246. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-f488b2da71daf406eb0f.d.ts → i18n-ta-IN-json-49b6bc876b7703f493e7.d.ts} +0 -0
  247. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-343add77fd58a5f2daee.d.ts → i18n-tr-TR-json-e6a720f75140ee82da6d.d.ts} +0 -0
  248. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-46abeda8d809d4091924.d.ts → i18n-uk-UA-json-1d95323ec8040114490e.d.ts} +0 -0
  249. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-a10d316db60e5c683310.d.ts → i18n-zh-CN-json-facce09827627d918c14.d.ts} +0 -0
  250. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-c1d5c5510660a11a428e.d.ts → i18n-zh-HK-json-a6e21fe69a6a6f8c8ea6.d.ts} +0 -0
  251. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fr-FR-json-0d90c291749f4d0d0be6.d.ts → i18n-zh-TW-json-37610fbce479c7f8cef2.d.ts} +0 -0
  252. package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fr-FR-json-6a418571305eecefe9bc.d.ts → vendor-52b1f3361986b6c6a4fe.d.ts} +0 -0
  253. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-0a4540a233e8caaf94d9.d.ts → i18n-ar-SA-json-505ef559f47ea6b69719.d.ts} +0 -0
  254. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-0c75d11c063d62b35b71.d.ts → i18n-bg-BG-json-bcb00de8d85335103437.d.ts} +0 -0
  255. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-42e4a9a6e2c159061c2e.d.ts → i18n-bn-BD-json-20cb88b768b6656f69a0.d.ts} +0 -0
  256. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-63e2f39b63698b7eec53.d.ts → i18n-ca-ES-json-c0a2946ac526da48c821.d.ts} +0 -0
  257. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-26395bf4e2d6709dca77.d.ts → i18n-cs-CZ-json-3b57cc3db37bad8747c9.d.ts} +0 -0
  258. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-8e2bb5d514f8cc8a936b.d.ts → i18n-da-DK-json-9fd1d27b5e867510c0c4.d.ts} +0 -0
  259. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-b6c71fc307b4fef4b72b.d.ts → i18n-de-DE-json-80aa4aed6cc5f0f47bec.d.ts} +0 -0
  260. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-be04e761ddcbc1c4ef62.d.ts → i18n-el-GR-json-08221c6f5387a7ef440e.d.ts} +0 -0
  261. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-0d4b865327b1c8a2e162.d.ts → i18n-es-ES-json-bb7d7aa7840ad87ac15d.d.ts} +0 -0
  262. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-0d6f2cdd7cc53fc24d55.d.ts → i18n-eu-ES-json-1aff52bfd1a98cc073a3.d.ts} +0 -0
  263. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-15172cbf8d8b0f2a1f11.d.ts → i18n-fa-IR-json-1af59f1130dd499b2aee.d.ts} +0 -0
  264. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-5e1e08fdf7498c74acc5.d.ts → i18n-fi-FI-json-874b4f80c8cb7c54ba9e.d.ts} +0 -0
  265. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-f06e683fbdf44f0ebde6.d.ts → i18n-fr-FR-json-b55b922b008349e24e30.d.ts} +0 -0
  266. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-cs-CZ-json-3d54eebf950d01467bb5.d.ts → i18n-he-IL-json-e16fce9c2852e89a31f2.d.ts} +0 -0
  267. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-cs-CZ-json-71bced584264c00ae327.d.ts → i18n-hi-IN-json-96d1324664dcf226249e.d.ts} +0 -0
  268. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-36d3bb51775cf6439260.d.ts → i18n-hu-HU-json-5e29c373127695ccfe28.d.ts} +0 -0
  269. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-5030e9ac8691da749eba.d.ts → i18n-id-ID-json-c3b8c47e9f2cd5a218a4.d.ts} +0 -0
  270. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-5c7f9a0825ce685c7858.d.ts → i18n-it-IT-json-c4ba0fd51730152b3389.d.ts} +0 -0
  271. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-8da7966bd6dfa56b82c2.d.ts → i18n-ja-JP-json-4fb9df48c7c2aca8709b.d.ts} +0 -0
  272. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-ab1adfc4c415380a8a35.d.ts → i18n-kab-KAB-json-56a2f5b742bb44d84587.d.ts} +0 -0
  273. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-2b516aa8f8b476154402.d.ts → i18n-kk-KZ-json-69f5849187a51635aa55.d.ts} +0 -0
  274. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-6296dc761fd8118e1e78.d.ts → i18n-ko-KR-json-be749d83561b4547fca0.d.ts} +0 -0
  275. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-d4c14b7f18bddb549e91.d.ts → i18n-lt-LT-json-f74d8fbb36e64d164cb3.d.ts} +0 -0
  276. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-e5ab1f25e7610ad2c05e.d.ts → i18n-lv-LV-json-05cafa9d59e825d37a30.d.ts} +0 -0
  277. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-24023bb070a10e04a83b.d.ts → i18n-mr-IN-json-4df0aaed6b5bd9c354bf.d.ts} +0 -0
  278. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-2fd2ed034bbb31a25ded.d.ts → i18n-my-MM-json-10cd0a77755d74cc2d88.d.ts} +0 -0
  279. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-4f103c28e06da0dc2e6f.d.ts → i18n-nb-NO-json-0328d43c8eb21619f1ef.d.ts} +0 -0
  280. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-c5fd5e8031140d6bafbb.d.ts → i18n-nl-NL-json-ce7bba8e06a59e62a4d0.d.ts} +0 -0
  281. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-5a679533a42b77a05d96.d.ts → i18n-nn-NO-json-64d56d9257aa9516e081.d.ts} +0 -0
  282. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-5dc6d99195af9d060ac0.d.ts → i18n-oc-FR-json-efae2c9bbbc42a6f6c70.d.ts} +0 -0
  283. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-86dffdf09ca14041d5aa.d.ts → i18n-pa-IN-json-6378d9552735e33a9fe3.d.ts} +0 -0
  284. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-aa9909cb72236eb377f1.d.ts → i18n-pl-PL-json-ed1bf39b6b8f8061299d.d.ts} +0 -0
  285. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-00fee41aad7582723ba6.d.ts → i18n-pt-BR-json-2a02a619bfa9700ce852.d.ts} +0 -0
  286. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-058a78a0d62102edc16f.d.ts → i18n-pt-PT-json-d28b9a54ff94e15ff9bb.d.ts} +0 -0
  287. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-1d24e65912cb13d89613.d.ts → i18n-ro-RO-json-00d5715f05aa3063960a.d.ts} +0 -0
  288. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-2d77bb0a44634fa78695.d.ts → i18n-ru-RU-json-ac0637166d5b462e339f.d.ts} +0 -0
  289. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-2249e2273f1c8ea609ec.d.ts → i18n-si-LK-json-63d7c3f1c548dd28b002.d.ts} +0 -0
  290. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-7043401a4303666c9542.d.ts → i18n-sk-SK-json-42cdbcaa7b9a48f2d39f.d.ts} +0 -0
  291. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-793074fb924464bc4564.d.ts → i18n-sl-SI-json-56b1f2e0db09f030df1d.d.ts} +0 -0
  292. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-d59cbe6664dcf219c750.d.ts → i18n-sv-SE-json-3eb8200f34c205bc6564.d.ts} +0 -0
  293. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-15405475fc235bd269f0.d.ts → i18n-ta-IN-json-6d1328c5b1be8952f272.d.ts} +0 -0
  294. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-7b83b92b6e883e3d08e1.d.ts → i18n-tr-TR-json-f19e7eace448e972fc37.d.ts} +0 -0
  295. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-853dbfc1fcf5a9658ed5.d.ts → i18n-uk-UA-json-da0e1d496b320531f5dc.d.ts} +0 -0
  296. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-dd75fd04034452f7ddc2.d.ts → i18n-zh-CN-json-84fc26b884a0a83892c9.d.ts} +0 -0
  297. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-hi-IN-json-6f529355d7944d9d34a6.d.ts → i18n-zh-HK-json-07799e9c9378a2263273.d.ts} +0 -0
  298. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-hi-IN-json-711c31911b0455f9b7db.d.ts → i18n-zh-TW-json-61c7460fdc361e477121.d.ts} +0 -0
  299. package/types/packages/excalidraw/dist/excalidraw-assets-dev/{image-0ad20139bba28f28b031.d.ts → vendor-c0592035c3911af79359.d.ts} +0 -0
  300. package/types/packages/excalidraw/dist/excalidraw.production.min.d.ts +1 -3
  301. package/types/packages/excalidraw/entry.d.ts +0 -2
  302. package/types/packages/excalidraw/env.d.ts +1 -0
  303. package/types/packages/excalidraw/example/App.d.ts +8 -0
  304. package/types/packages/excalidraw/example/index.d.ts +1 -0
  305. package/types/packages/excalidraw/example/initialData.d.ts +172 -0
  306. package/types/packages/excalidraw/example/sidebar/Sidebar.d.ts +5 -0
  307. package/types/packages/excalidraw/index.d.ts +9 -7
  308. package/types/packages/excalidraw/webpack.dev-server.config.d.ts +19 -0
  309. package/types/packages/excalidraw/webpack.dev.config.d.ts +6 -8
  310. package/types/packages/excalidraw/webpack.prod.config.d.ts +10 -9
  311. package/types/packages/utils.d.ts +19 -9
  312. package/types/renderer/renderElement.d.ts +17 -5
  313. package/types/renderer/renderScene.d.ts +5 -9
  314. package/types/scene/Scene.d.ts +2 -3
  315. package/types/scene/comparisons.d.ts +3 -2
  316. package/types/scene/export.d.ts +4 -4
  317. package/types/scene/index.d.ts +2 -2
  318. package/types/scene/selection.d.ts +1 -1
  319. package/types/scene/types.d.ts +16 -8
  320. package/types/scene/zoom.d.ts +12 -5
  321. package/types/shapes.d.ts +7 -3
  322. package/types/types.d.ts +121 -25
  323. package/types/utils.d.ts +48 -8
  324. package/types/zindex.d.ts +2 -2
  325. package/dist/excalidraw-assets/i18n-ar-SA-json-9a7bef3582993b3fde41.js +0 -1
  326. package/dist/excalidraw-assets/i18n-bg-BG-json-93c3fd2b081c849d4e04.js +0 -1
  327. package/dist/excalidraw-assets/i18n-ca-ES-json-e749f7948c1b822fc757.js +0 -1
  328. package/dist/excalidraw-assets/i18n-cs-CZ-json-8b577e35bb3be3287a0b.js +0 -1
  329. package/dist/excalidraw-assets/i18n-de-DE-json-f72002171c2c56b967cd.js +0 -1
  330. package/dist/excalidraw-assets/i18n-el-GR-json-f8f9a3a1729a4935edbc.js +0 -1
  331. package/dist/excalidraw-assets/i18n-es-ES-json-2c2246b5f03e518b157c.js +0 -1
  332. package/dist/excalidraw-assets/i18n-fa-IR-json-95e4c55eb845ae827609.js +0 -1
  333. package/dist/excalidraw-assets/i18n-fi-FI-json-a10d316db60e5c683310.js +0 -1
  334. package/dist/excalidraw-assets/i18n-fr-FR-json-97d3c042d3a35ef178f1.js +0 -1
  335. package/dist/excalidraw-assets/i18n-he-IL-json-2636e07fd8cc89d175d9.js +0 -1
  336. package/dist/excalidraw-assets/i18n-hi-IN-json-15259c14d6c8090e6041.js +0 -1
  337. package/dist/excalidraw-assets/i18n-hu-HU-json-83f954e3c1e57b6fd4f2.js +0 -1
  338. package/dist/excalidraw-assets/i18n-id-ID-json-9c439203bdabe6684608.js +0 -1
  339. package/dist/excalidraw-assets/i18n-it-IT-json-32a61d0b3e05b538bf63.js +0 -1
  340. package/dist/excalidraw-assets/i18n-ja-JP-json-7780222c69cc877e19a5.js +0 -1
  341. package/dist/excalidraw-assets/i18n-kab-KAB-json-9438814b6f8d2d4bca30.js +0 -1
  342. package/dist/excalidraw-assets/i18n-kk-KZ-json-c6e1e808c0237fb1c06e.js +0 -1
  343. package/dist/excalidraw-assets/i18n-ko-KR-json-60158040fc55af420fec.js +0 -1
  344. package/dist/excalidraw-assets/i18n-lv-LV-json-0a84813c147df37dafd5.js +0 -1
  345. package/dist/excalidraw-assets/i18n-my-MM-json-b7cafa3196e9247a3744.js +0 -1
  346. package/dist/excalidraw-assets/i18n-nb-NO-json-7817632f1248c4374b19.js +0 -1
  347. package/dist/excalidraw-assets/i18n-nl-NL-json-7bedb9ed0d2a6ce6dbef.js +0 -1
  348. package/dist/excalidraw-assets/i18n-nn-NO-json-cc3e8135a35bc8f98708.js +0 -1
  349. package/dist/excalidraw-assets/i18n-oc-FR-json-7cd0233768ae95a4ff67.js +0 -1
  350. package/dist/excalidraw-assets/i18n-pa-IN-json-0346c42fd5a76dafe221.js +0 -1
  351. package/dist/excalidraw-assets/i18n-pl-PL-json-fd71968e6ed066a9a7e4.js +0 -1
  352. package/dist/excalidraw-assets/i18n-pt-BR-json-464cb502a9c0fedb90bc.js +0 -1
  353. package/dist/excalidraw-assets/i18n-pt-PT-json-7b7c90b1b9d2f1c8516b.js +0 -1
  354. package/dist/excalidraw-assets/i18n-ro-RO-json-ac25005e74f8dd8d360c.js +0 -1
  355. package/dist/excalidraw-assets/i18n-ru-RU-json-ef8daff1f5e8b77e4cad.js +0 -1
  356. package/dist/excalidraw-assets/i18n-sk-SK-json-f50495416e3b91a65ed6.js +0 -1
  357. package/dist/excalidraw-assets/i18n-sv-SE-json-2fd231ccf2c37b2df52d.js +0 -1
  358. package/dist/excalidraw-assets/i18n-tr-TR-json-a940d18e2fb0ff323575.js +0 -1
  359. package/dist/excalidraw-assets/i18n-uk-UA-json-f6fb2e431947fd51c7cd.js +0 -1
  360. package/dist/excalidraw-assets/i18n-zh-CN-json-3333609e8b26b63da65d.js +0 -1
  361. package/dist/excalidraw-assets/i18n-zh-TW-json-08026b081d7dae088759.js +0 -1
  362. package/dist/excalidraw-assets/image-eafab0c39ce13f7fea67.js +0 -1
  363. package/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.js +0 -2
  364. package/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.js.LICENSE.txt +0 -1
  365. package/dist/excalidraw-assets-dev/i18n-ar-SA-json-42e4a9a6e2c159061c2e.js +0 -22
  366. package/dist/excalidraw-assets-dev/i18n-bg-BG-json-8e2bb5d514f8cc8a936b.js +0 -22
  367. package/dist/excalidraw-assets-dev/i18n-ca-ES-json-0d4b865327b1c8a2e162.js +0 -22
  368. package/dist/excalidraw-assets-dev/i18n-cs-CZ-json-3d54eebf950d01467bb5.js +0 -22
  369. package/dist/excalidraw-assets-dev/i18n-de-DE-json-5030e9ac8691da749eba.js +0 -22
  370. package/dist/excalidraw-assets-dev/i18n-el-GR-json-6296dc761fd8118e1e78.js +0 -22
  371. package/dist/excalidraw-assets-dev/i18n-es-ES-json-c5fd5e8031140d6bafbb.js +0 -22
  372. package/dist/excalidraw-assets-dev/i18n-fa-IR-json-aa9909cb72236eb377f1.js +0 -22
  373. package/dist/excalidraw-assets-dev/i18n-fi-FI-json-2d77bb0a44634fa78695.js +0 -22
  374. package/dist/excalidraw-assets-dev/i18n-fr-FR-json-2249e2273f1c8ea609ec.js +0 -22
  375. package/dist/excalidraw-assets-dev/i18n-he-IL-json-853dbfc1fcf5a9658ed5.js +0 -22
  376. package/dist/excalidraw-assets-dev/i18n-hi-IN-json-dfd13380f880265721d1.js +0 -22
  377. package/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e40f12439fdaf31e5f8.js +0 -22
  378. package/dist/excalidraw-assets-dev/i18n-id-ID-json-d0fd59d99eb8268ad32d.js +0 -22
  379. package/dist/excalidraw-assets-dev/i18n-it-IT-json-dc31d253c180bd8bc42c.js +0 -22
  380. package/dist/excalidraw-assets-dev/i18n-ja-JP-json-db2805c4535d81f39148.js +0 -22
  381. package/dist/excalidraw-assets-dev/i18n-kab-KAB-json-b88f94c29607a0102313.js +0 -22
  382. package/dist/excalidraw-assets-dev/i18n-kk-KZ-json-3c033b44668ea8f33a22.js +0 -22
  383. package/dist/excalidraw-assets-dev/i18n-ko-KR-json-87c10c8f44988dd0e13a.js +0 -22
  384. package/dist/excalidraw-assets-dev/i18n-lv-LV-json-1a80ea1c8f3354d394cf.js +0 -22
  385. package/dist/excalidraw-assets-dev/i18n-my-MM-json-8a534e22357023f607a4.js +0 -22
  386. package/dist/excalidraw-assets-dev/i18n-nb-NO-json-49fa9e922f887d2f60a7.js +0 -22
  387. package/dist/excalidraw-assets-dev/i18n-nl-NL-json-df1ade23a540ca746458.js +0 -22
  388. package/dist/excalidraw-assets-dev/i18n-nn-NO-json-6d27231c8f6f5056953c.js +0 -22
  389. package/dist/excalidraw-assets-dev/i18n-oc-FR-json-069879d69e9d37f7131f.js +0 -22
  390. package/dist/excalidraw-assets-dev/i18n-pa-IN-json-5e2e9c3078bfca8530b1.js +0 -22
  391. package/dist/excalidraw-assets-dev/i18n-pl-PL-json-f161c5a49ee47f8e771c.js +0 -22
  392. package/dist/excalidraw-assets-dev/i18n-pt-BR-json-715832c0500f14d50107.js +0 -22
  393. package/dist/excalidraw-assets-dev/i18n-pt-PT-json-482e046bcfea32653cf0.js +0 -22
  394. package/dist/excalidraw-assets-dev/i18n-ro-RO-json-4a2e4f653982cc7b046e.js +0 -22
  395. package/dist/excalidraw-assets-dev/i18n-ru-RU-json-aa92dea266fa031249ca.js +0 -22
  396. package/dist/excalidraw-assets-dev/i18n-sk-SK-json-118350b0f0cdc9be21b6.js +0 -22
  397. package/dist/excalidraw-assets-dev/i18n-sv-SE-json-0b0469f979b4abbbd52a.js +0 -22
  398. package/dist/excalidraw-assets-dev/i18n-tr-TR-json-fc6af871b929adde7bd8.js +0 -22
  399. package/dist/excalidraw-assets-dev/i18n-uk-UA-json-0455e3b621d70d11a5be.js +0 -22
  400. package/dist/excalidraw-assets-dev/i18n-zh-CN-json-3fe440d4981c65767b68.js +0 -22
  401. package/dist/excalidraw-assets-dev/i18n-zh-TW-json-a78c1cbb2eaa5ad69af6.js +0 -22
  402. package/dist/excalidraw-assets-dev/image-0ad20139bba28f28b031.js +0 -33
  403. package/dist/excalidraw-assets-dev/vendor-87b1add30a2f905d5383.js +0 -356
  404. package/types/components/ExportDialog.d.ts +0 -17
  405. package/types/components/GitHubCorner.d.ts +0 -4
  406. package/types/is-mobile.d.ts +0 -6
  407. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-fr-FR-json-79fa555bfea0a356f393.d.ts +0 -0
  408. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-fr-FR-json-97d3c042d3a35ef178f1.d.ts +0 -0
  409. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-157ae036fcf470528687.d.ts +0 -0
  410. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-2636e07fd8cc89d175d9.d.ts +0 -0
  411. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-d006423b531ab062bb85.d.ts +0 -0
  412. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-faa97890de44ed584a45.d.ts +0 -0
  413. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-15259c14d6c8090e6041.d.ts +0 -0
  414. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-3035c3b3ab3ce981dbc7.d.ts +0 -0
  415. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-4f59e58d6a805face4bc.d.ts +0 -0
  416. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-d959b869453c591a8861.d.ts +0 -0
  417. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-50a13e322a60bb701615.d.ts +0 -0
  418. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-83f954e3c1e57b6fd4f2.d.ts +0 -0
  419. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-96eea4d71b4795e36e1c.d.ts +0 -0
  420. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-a366989217753fe3d02b.d.ts +0 -0
  421. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-5403b38ac77691c5eca4.d.ts +0 -0
  422. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-87212daac6113b5bf808.d.ts +0 -0
  423. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-8d13d29ee41be15a1f99.d.ts +0 -0
  424. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-9c439203bdabe6684608.d.ts +0 -0
  425. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-1741b35480eb0defb489.d.ts +0 -0
  426. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-32a61d0b3e05b538bf63.d.ts +0 -0
  427. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-59f2e9d3dac07f3264cb.d.ts +0 -0
  428. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-90283cd2809f4165506b.d.ts +0 -0
  429. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-37ae69a9327343f0df49.d.ts +0 -0
  430. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-7780222c69cc877e19a5.d.ts +0 -0
  431. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-9e0a78ddb43d5709fb29.d.ts +0 -0
  432. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-ccb5ffd0f8a0980c2ec0.d.ts +0 -0
  433. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-1f8d0a51645c871d2289.d.ts +0 -0
  434. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-9438814b6f8d2d4bca30.d.ts +0 -0
  435. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-d9acc7b8ee952e356d06.d.ts +0 -0
  436. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-dac787e0446cdb747fe1.d.ts +0 -0
  437. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kk-KZ-json-c6e1e808c0237fb1c06e.d.ts +0 -0
  438. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-60158040fc55af420fec.d.ts +0 -0
  439. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-d61af373bea59d1ff4c6.d.ts +0 -0
  440. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-e42ededaa35032a201b9.d.ts +0 -0
  441. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-f07afc9e756716038f58.d.ts +0 -0
  442. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-07f6bffcb44fdd9aad4f.d.ts +0 -0
  443. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-0a84813c147df37dafd5.d.ts +0 -0
  444. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-7eea5c4054f8418fdd10.d.ts +0 -0
  445. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-26d1e27bab3b8ac4a3e6.d.ts +0 -0
  446. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-8d09c35cfec8011379c5.d.ts +0 -0
  447. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-a8f9bb37a7b947e9dfba.d.ts +0 -0
  448. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-b7cafa3196e9247a3744.d.ts +0 -0
  449. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-347a7289682a3cd91131.d.ts +0 -0
  450. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-7817632f1248c4374b19.d.ts +0 -0
  451. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-8ce0749d46f0b4a8defb.d.ts +0 -0
  452. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-c01fab8602e1b658d5d1.d.ts +0 -0
  453. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-23fdfd9f11bc8efbaf56.d.ts +0 -0
  454. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-51adbd1d4d0bf1d01a7b.d.ts +0 -0
  455. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-7bedb9ed0d2a6ce6dbef.d.ts +0 -0
  456. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-cf922daa828029c1aff5.d.ts +0 -0
  457. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-b5931de6e1ed336bf087.d.ts +0 -0
  458. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-cc3e8135a35bc8f98708.d.ts +0 -0
  459. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-d363be6b3dcdbf3a868a.d.ts +0 -0
  460. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-f5f8364c660de496ad5e.d.ts +0 -0
  461. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-29d6193adb907d4f5890.d.ts +0 -0
  462. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-5d63281a55d45fa9b895.d.ts +0 -0
  463. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-7cd0233768ae95a4ff67.d.ts +0 -0
  464. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-917cae387efe3c7daa7b.d.ts +0 -0
  465. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-c6414107ad634b113aba.d.ts +0 -0
  466. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-0346c42fd5a76dafe221.d.ts +0 -0
  467. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-27063e4865142ac11b1a.d.ts +0 -0
  468. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-94904044e3de6d7a03b9.d.ts +0 -0
  469. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-f0c779291da384fb5173.d.ts +0 -0
  470. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-16af1b83ac16af57ad07.d.ts +0 -0
  471. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-77216f119758846c11a6.d.ts +0 -0
  472. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-a4a5c6e0a9877c43476a.d.ts +0 -0
  473. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-fd71968e6ed066a9a7e4.d.ts +0 -0
  474. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-03a046855063512eb9ff.d.ts +0 -0
  475. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-464cb502a9c0fedb90bc.d.ts +0 -0
  476. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-8a2b5677633283f9709d.d.ts +0 -0
  477. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-db86828d6e3ced9f9854.d.ts +0 -0
  478. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-186d1c052145da982c22.d.ts +0 -0
  479. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-7b7c90b1b9d2f1c8516b.d.ts +0 -0
  480. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-7ed352e9de6dc74ef503.d.ts +0 -0
  481. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-9fc68d7dfd57ed065217.d.ts +0 -0
  482. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-bc0cd589bd87a3079407.d.ts +0 -0
  483. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-75692b7a0166d6ad27a4.d.ts +0 -0
  484. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-ac25005e74f8dd8d360c.d.ts +0 -0
  485. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-bc3b1ac81c49d9f46bc3.d.ts +0 -0
  486. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-f13a2e7b7a63fbfb6ae7.d.ts +0 -0
  487. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-69b1a919b7f42adfd6ec.d.ts +0 -0
  488. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-7c2a2061d0ca99cf7007.d.ts +0 -0
  489. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-d7d997a13f420a4c013f.d.ts +0 -0
  490. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-ef8daff1f5e8b77e4cad.d.ts +0 -0
  491. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-0879aa8d30b34085d3ca.d.ts +0 -0
  492. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-0ef09f90308059d22ae8.d.ts +0 -0
  493. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-4757551ceb15fa0a29a9.d.ts +0 -0
  494. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-a76fdcb6e89ea3e90968.d.ts +0 -0
  495. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-f50495416e3b91a65ed6.d.ts +0 -0
  496. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-2fd231ccf2c37b2df52d.d.ts +0 -0
  497. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-baf46a1a4335217900ec.d.ts +0 -0
  498. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-dc7718d79b9bf93a4ba4.d.ts +0 -0
  499. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-fa5bd09f128972b13ac2.d.ts +0 -0
  500. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-4d087f24f2b782404c82.d.ts +0 -0
  501. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-a0167ddcd5781d778bb4.d.ts +0 -0
  502. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-a940d18e2fb0ff323575.d.ts +0 -0
  503. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-b574833ee1c2f58fd24e.d.ts +0 -0
  504. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-cba7e62d9610795a5ac3.d.ts +0 -0
  505. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-5ae9937f0ed82468050e.d.ts +0 -0
  506. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-a9a8ea7adb95c0a03680.d.ts +0 -0
  507. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-f0cab296bdc4089ffa77.d.ts +0 -0
  508. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-f6fb2e431947fd51c7cd.d.ts +0 -0
  509. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-1070e5dfd3c6adf4fe95.d.ts +0 -0
  510. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-3333609e8b26b63da65d.d.ts +0 -0
  511. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-45da9983459601b845e8.d.ts +0 -0
  512. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-94f562845a945a45e385.d.ts +0 -0
  513. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-08026b081d7dae088759.d.ts +0 -0
  514. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-0e77c896018bcd221bf6.d.ts +0 -0
  515. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-62dd29f7a9ca5ff7ecde.d.ts +0 -0
  516. package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-7dd3d9ba72493687c286.d.ts +0 -0
  517. package/types/packages/excalidraw/dist/excalidraw-assets/image-5fe4e27670d5147fb1f2.d.ts +0 -0
  518. package/types/packages/excalidraw/dist/excalidraw-assets/image-eafab0c39ce13f7fea67.d.ts +0 -0
  519. package/types/packages/excalidraw/dist/excalidraw-assets/vendor-5678a46e9c49ae846a9e.d.ts +0 -0
  520. package/types/packages/excalidraw/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.d.ts +0 -0
  521. package/types/packages/excalidraw/dist/excalidraw-assets/vendor-e28bbc4a18db117e244e.d.ts +0 -0
  522. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hi-IN-json-dfd13380f880265721d1.d.ts +0 -2
  523. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hi-IN-json-f902998f48c9e940b8b7.d.ts +0 -2
  524. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e40f12439fdaf31e5f8.d.ts +0 -2
  525. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-ada5d1cef817fe19894a.d.ts +0 -2
  526. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-b9b0249ff44723872095.d.ts +0 -2
  527. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-e65692a1c5aebfe5bc81.d.ts +0 -2
  528. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-835f87669363ce6e7c70.d.ts +0 -2
  529. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-d0fd59d99eb8268ad32d.d.ts +0 -2
  530. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-d264f60071587cc03dbc.d.ts +0 -2
  531. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-e8eedd65d1eefcfb47af.d.ts +0 -2
  532. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-8a32d12ac801fef52a55.d.ts +0 -2
  533. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-8a43a149865c6779fc8e.d.ts +0 -2
  534. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-90e37ac7e4f9b56017c8.d.ts +0 -2
  535. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-dc31d253c180bd8bc42c.d.ts +0 -2
  536. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-3c9f0500ad7ae95e6331.d.ts +0 -2
  537. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-482de550c6b58749e363.d.ts +0 -2
  538. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-9bd61e0b60ea12007ec2.d.ts +0 -2
  539. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-db2805c4535d81f39148.d.ts +0 -2
  540. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-4d3c40103366973ea8e7.d.ts +0 -2
  541. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-6ecc1e42c03166ce44c2.d.ts +0 -2
  542. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-b88f94c29607a0102313.d.ts +0 -2
  543. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-ca34961870049ab8dc31.d.ts +0 -2
  544. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kk-KZ-json-3c033b44668ea8f33a22.d.ts +0 -2
  545. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-66e46599a7674b2c8e4b.d.ts +0 -2
  546. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-87c10c8f44988dd0e13a.d.ts +0 -2
  547. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-934a52d336cd86c43b15.d.ts +0 -2
  548. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-c88ade101a1937c0c881.d.ts +0 -2
  549. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-1a80ea1c8f3354d394cf.d.ts +0 -2
  550. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-23fd249423ee6a324e83.d.ts +0 -2
  551. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-6aaf2bb3aefbce847dfd.d.ts +0 -2
  552. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-52026701113f0ab7f523.d.ts +0 -2
  553. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-64b5010692f50278902c.d.ts +0 -2
  554. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-8a534e22357023f607a4.d.ts +0 -2
  555. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-bfb9dc9b1422cc6ca14e.d.ts +0 -2
  556. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-489122304d05e212e873.d.ts +0 -2
  557. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-49fa9e922f887d2f60a7.d.ts +0 -2
  558. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-b306f0e8dc387da1d79b.d.ts +0 -2
  559. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-f5dde6f364d92ce556dc.d.ts +0 -2
  560. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-82e96e181260b8988806.d.ts +0 -2
  561. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-b43931c3681d44a32403.d.ts +0 -2
  562. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-c1909d14fa3ba5a2776b.d.ts +0 -2
  563. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-df1ade23a540ca746458.d.ts +0 -2
  564. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-65d7cb4781c95aef4417.d.ts +0 -2
  565. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-6d27231c8f6f5056953c.d.ts +0 -2
  566. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-7ec9cc490ddfcebec38a.d.ts +0 -2
  567. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-8cd74dd7b1f63e23abb0.d.ts +0 -2
  568. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-069879d69e9d37f7131f.d.ts +0 -2
  569. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-73ae6f9c6fdc4df09309.d.ts +0 -2
  570. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-77013b778932c4e50835.d.ts +0 -2
  571. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-8d148718b907f1827ff2.d.ts +0 -2
  572. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-d4cec6a3268fab4e3cee.d.ts +0 -2
  573. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-5e2e9c3078bfca8530b1.d.ts +0 -2
  574. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-649c3a5cc136f4bf90d0.d.ts +0 -2
  575. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-7722b4613d295aa2fe1d.d.ts +0 -2
  576. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-cfe2c9217cf01e4702e2.d.ts +0 -2
  577. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-4a49c6798301bbf50ad1.d.ts +0 -2
  578. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-86837d86cca9e22510de.d.ts +0 -2
  579. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-d537cb96a3465cf853a2.d.ts +0 -2
  580. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-f161c5a49ee47f8e771c.d.ts +0 -2
  581. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-715832c0500f14d50107.d.ts +0 -2
  582. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-832bd65611c82efb2c59.d.ts +0 -2
  583. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-9e5e38e222f73caab707.d.ts +0 -2
  584. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-e57c8c128e5e4799b5da.d.ts +0 -2
  585. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-482e046bcfea32653cf0.d.ts +0 -2
  586. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-6b9495717c9da1a29f28.d.ts +0 -2
  587. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-8d32158e1b3d0bb5a561.d.ts +0 -2
  588. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-cc40c74df3147e2397fd.d.ts +0 -2
  589. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-d5a3eb8ee8456a57f17b.d.ts +0 -2
  590. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-13589d429b0eb2bd6ad7.d.ts +0 -2
  591. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-4a2e4f653982cc7b046e.d.ts +0 -2
  592. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-5a30a45a0e1df37c54e7.d.ts +0 -2
  593. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-bcbf3b8c2275de0f2a3c.d.ts +0 -2
  594. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-2d9fbf7de6605bdecddf.d.ts +0 -2
  595. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-9ac76447545318b66e63.d.ts +0 -2
  596. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-9e6a7149ce143fb48bf4.d.ts +0 -2
  597. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-aa92dea266fa031249ca.d.ts +0 -2
  598. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-118350b0f0cdc9be21b6.d.ts +0 -2
  599. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-2028ec0b65d6eed7403a.d.ts +0 -2
  600. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-7a7f7823653192b39c0e.d.ts +0 -2
  601. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-f33008479ba846a43320.d.ts +0 -2
  602. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-fd05a3a822b86b5566fc.d.ts +0 -2
  603. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-0b0469f979b4abbbd52a.d.ts +0 -2
  604. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-104c3ec1c05628a0adc2.d.ts +0 -2
  605. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-d45d82c4601f5591f3cd.d.ts +0 -2
  606. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-fd3b941b3df61ae391a9.d.ts +0 -2
  607. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-5abc34c49a78088dc890.d.ts +0 -2
  608. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-84336db0450baf5b60b1.d.ts +0 -2
  609. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-b486cbc4ab9a99ee37b0.d.ts +0 -2
  610. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-eba8c7f5b842181a3696.d.ts +0 -2
  611. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-fc6af871b929adde7bd8.d.ts +0 -2
  612. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-0455e3b621d70d11a5be.d.ts +0 -2
  613. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-0a3ab1e3431530135c0e.d.ts +0 -2
  614. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-1570a6ac23a753933f82.d.ts +0 -2
  615. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-c1d4fcf6be7603dcca2d.d.ts +0 -2
  616. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-3fe440d4981c65767b68.d.ts +0 -2
  617. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-6bb82eee4ed00ddca3a9.d.ts +0 -2
  618. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-98deec89f30ce8f46495.d.ts +0 -2
  619. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-dc0e18b1488087e7e8ac.d.ts +0 -2
  620. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-063b4405857a856e2b6d.d.ts +0 -2
  621. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-0e9e8f4777ff0435e2c4.d.ts +0 -2
  622. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-8dc37e8c1841fe55fc89.d.ts +0 -2
  623. package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-a78c1cbb2eaa5ad69af6.d.ts +0 -2
  624. package/types/packages/excalidraw/postcss.config.d.ts +0 -1
package/README.md CHANGED
@@ -1,3 +1,7 @@
1
+ #### Note
2
+
3
+ ⚠️ ⚠️ ⚠️ You are viewing the docs for the **next** release, in case you want to check the docs for the stable release, you can view it [here](https://www.npmjs.com/package/@excalidraw/excalidraw).
4
+
1
5
  ### Excalidraw
2
6
 
3
7
  Excalidraw exported as a component to directly embed in your projects.
@@ -26,7 +30,7 @@ If you want to load assets from a different path you can set a variable `window.
26
30
 
27
31
  #### Note
28
32
 
29
- **If you don't want to wait for the next stable release and try out the unreleased changes you can use [@excalidraw/excalidraw-next](https://www.npmjs.com/package/@excalidraw/excalidraw-next).**
33
+ **If you don't want to wait for the next stable release and try out the unreleased changes you can use `@excalidraw/excalidraw@next`.**
30
34
 
31
35
  ### Demo
32
36
 
@@ -42,7 +46,7 @@ If you are using a Web bundler (for instance, Webpack), you can import it as an
42
46
 
43
47
  ```js
44
48
  import React, { useEffect, useState, useRef } from "react";
45
- import Excalidraw from "@excalidraw/excalidraw";
49
+ import { Excalidraw } from "@excalidraw/excalidraw";
46
50
  import InitialData from "./initialData";
47
51
 
48
52
  import "./styles.scss";
@@ -322,7 +326,7 @@ const App = () => {
322
326
  className: "excalidraw-wrapper",
323
327
  ref: excalidrawWrapperRef,
324
328
  },
325
- React.createElement(Excalidraw.default, {
329
+ React.createElement(ExcalidrawLib.Excalidraw, {
326
330
  initialData: InitialData,
327
331
  onChange: (elements, state) =>
328
332
  console.log("Elements :", elements, "State : ", state),
@@ -347,12 +351,37 @@ To view the full example visit :point_down:
347
351
 
348
352
  </details>
349
353
 
354
+ ### Customizing styles
355
+
356
+ Excalidraw is using CSS variables to style certain components. To override them, you should set your own on the `.excalidraw` and `.excalidraw.theme--dark` (for dark mode variables) selectors.
357
+
358
+ Make sure the selector has higher specificity, e.g. by prefixing it with your app's selector:
359
+
360
+ ```css
361
+ .your-app .excalidraw {
362
+ --color-primary: red;
363
+ }
364
+ .your-app .excalidraw.theme--dark {
365
+ --color-primary: pink;
366
+ }
367
+ ```
368
+
369
+ Most notably, you can customize the primary colors, by overriding these variables:
370
+
371
+ - `--color-primary`
372
+ - `--color-primary-darker`
373
+ - `--color-primary-darkest`
374
+ - `--color-primary-light`
375
+ - `--color-primary-contrast-offset` — a slightly darker (in light mode), or lighter (in dark mode) `--color-primary` color to fix contrast issues (see [Chubb illusion](https://en.wikipedia.org/wiki/Chubb_illusion)). It will fall back to `--color-primary` if not present.
376
+
377
+ For a complete list of variables, check [theme.scss](https://github.com/excalidraw/excalidraw/blob/master/src/css/theme.scss), though most of them will not make sense to override.
378
+
350
379
  ### Props
351
380
 
352
381
  | Name | Type | Default | Description |
353
382
  | --- | --- | --- | --- |
354
383
  | [`onChange`](#onChange) | Function | | This callback is triggered whenever the component updates due to any change. This callback will receive the excalidraw elements and the current app state. |
355
- | [`initialData`](#initialData) | <pre>{elements?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>, appState?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState<a> } </pre> | null | The initial data with which app loads. |
384
+ | [`initialData`](#initialData) | <pre>{elements?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>, appState?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState<a> } </pre> | null | The initial data with which app loads. |
356
385
  | [`ref`](#ref) | [`createRef`](https://reactjs.org/docs/refs-and-the-dom.html#creating-refs) &#124; [`useRef`](https://reactjs.org/docs/hooks-reference.html#useref) &#124; [`callbackRef`](https://reactjs.org/docs/refs-and-the-dom.html#callback-refs) &#124; <pre>{ current: { readyPromise: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/utils.ts#L317">resolvablePromise</a> } }</pre> | | Ref to be passed to Excalidraw |
357
386
  | [`onCollabButtonClick`](#onCollabButtonClick) | Function | | Callback to be triggered when the collab button is clicked |
358
387
  | [`isCollaborating`](#isCollaborating) | `boolean` | | This implies if the app is in collaboration mode |
@@ -365,14 +394,18 @@ To view the full example visit :point_down:
365
394
  | [`zenModeEnabled`](#zenModeEnabled) | boolean | | This implies if the zen mode is enabled |
366
395
  | [`gridModeEnabled`](#gridModeEnabled) | boolean | | This implies if the grid mode is enabled |
367
396
  | [`libraryReturnUrl`](#libraryReturnUrl) | string | | What URL should [libraries.excalidraw.com](https://libraries.excalidraw.com) be installed to |
368
- | [`theme`](#theme) | `light` or `dark` | | The theme of the Excalidraw component |
397
+ | [`theme`](#theme) | [THEME.LIGHT](#THEME-1) &#124; [THEME.LIGHT](#THEME-1) | [THEME.LIGHT](#THEME-1) | The theme of the Excalidraw component |
369
398
  | [`name`](#name) | string | | Name of the drawing |
370
399
  | [`UIOptions`](#UIOptions) | <pre>{ canvasActions: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L208"> CanvasActions<a/> }</pre> | [DEFAULT UI OPTIONS](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L129) | To customise UI options. Currently we support customising [`canvas actions`](#canvasActions) |
371
- | [`onPaste`](#onPaste) | <pre>(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L17">ClipboardData</a>, event: ClipboardEvent &#124; null) => boolean</pre> | | Callback to be triggered if passed when the something is pasted in to the scene |
400
+ | [`onPaste`](#onPaste) | <pre>(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L21">ClipboardData</a>, event: ClipboardEvent &#124; null) => boolean</pre> | | Callback to be triggered if passed when the something is pasted in to the scene |
372
401
  | [`detectScroll`](#detectScroll) | boolean | true | Indicates whether to update the offsets when nearest ancestor is scrolled. |
373
402
  | [`handleKeyboardGlobally`](#handleKeyboardGlobally) | boolean | false | Indicates whether to bind the keyboard events to document. |
374
403
  | [`onLibraryChange`](#onLibraryChange) | <pre>(items: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => void &#124; Promise&lt;any&gt; </pre> | | The callback if supplied is triggered when the library is updated and receives the library items. |
375
404
  | [`autoFocus`](#autoFocus) | boolean | false | Implies whether to focus the Excalidraw component on page load |
405
+ | [`generateIdForFile`](#generateIdForFile) | `(file: File) => string | Promise<string>` | Allows you to override `id` generation for files added on canvas |
406
+ | [`onLinkOpen`](#onLinkOpen) | <pre>(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">NonDeletedExcalidrawElement</a>, event: CustomEvent) </pre> | | This prop if passed will be triggered when link of an element is clicked. |
407
+ | [`onPointerDown`](#onPointerDown) | <pre>(activeTool: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L93"> AppState["activeTool"]</a>, pointerDownState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L365">PointerDownState</a>) => void</pre> | | This prop if passed gets triggered on pointer down evenets |
408
+ | [`onScrollChange`](#onScrollChange) | (scrollX: number, scrollY: number) | | This prop if passed gets triggered when scrolling the canvas. |
376
409
 
377
410
  ### Dimensions of Excalidraw
378
411
 
@@ -383,12 +416,14 @@ Excalidraw takes `100%` of `width` and `height` of the containing block so make
383
416
  Every time component updates, this callback if passed will get triggered and has the below signature.
384
417
 
385
418
  ```js
386
- (excalidrawElements, appState) => void;
419
+ (excalidrawElements, appState, files) => void;
387
420
  ```
388
421
 
389
- 1.`excalidrawElements`: Array of [excalidrawElements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78) in the scene.
422
+ 1.`excalidrawElements`: Array of [excalidrawElements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) in the scene.
390
423
 
391
- 2.`appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42) of the scene
424
+ 2.`appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) of the scene.
425
+
426
+ 3. `files`: The [`BinaryFiles`]([BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64) which are added to the scene.
392
427
 
393
428
  Here you can try saving the data to your backend or local storage for example.
394
429
 
@@ -396,12 +431,13 @@ Here you can try saving the data to your backend or local storage for example.
396
431
 
397
432
  This helps to load Excalidraw with `initialData`. It must be an object or a [promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/Promise) which resolves to an object containing the below optional fields.
398
433
 
399
- | Name | Type | Descrption |
434
+ | Name | Type | Description |
400
435
  | --- | --- | --- |
401
- | `elements` | [ExcalidrawElement[]](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78) | The elements with which Excalidraw should be mounted. |
402
- | `appState` | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42) | The App state with which Excalidraw should be mounted. |
436
+ | `elements` | [ExcalidrawElement[]](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) | The elements with which Excalidraw should be mounted. |
437
+ | `appState` | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) | The App state with which Excalidraw should be mounted. |
403
438
  | `scrollToContent` | boolean | This attribute implies whether to scroll to the nearest element to center once Excalidraw is mounted. By default, it will not scroll the nearest element to the center. Make sure you pass `initialData.appState.scrollX` and `initialData.appState.scrollY` when `scrollToContent` is false so that scroll positions are retained |
404
- | `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L151) | This library items with which Excalidraw should be mounted. |
439
+ | `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) &#124; Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)> | This library items with which Excalidraw should be mounted. |
440
+ | `files` | [BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64) | The files added to the scene. |
405
441
 
406
442
  ```json
407
443
  {
@@ -442,17 +478,23 @@ You can pass a `ref` when you want to access some excalidraw APIs. We expose the
442
478
  | --- | --- | --- |
443
479
  | ready | `boolean` | This is set to true once Excalidraw is rendered |
444
480
  | readyPromise | [resolvablePromise](https://github.com/excalidraw/excalidraw/blob/master/src/utils.ts#L317) | This promise will be resolved with the api once excalidraw has rendered. This will be helpful when you want do some action on the host app once this promise resolves. For this to work you will have to pass ref as shown [here](#readyPromise) |
445
- | [updateScene](#updateScene) | <pre>(<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>)) => void </pre> | updates the scene with the sceneData |
481
+ | [updateScene](#updateScene) | <code>(scene: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>) => void </code> | updates the scene with the sceneData |
482
+ | [updateLibrary](#updateLibrary) | <code>(<a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/library.ts#L136">opts</a>) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>> </code> | updates the scene with the sceneData |
483
+ | [addFiles](#addFiles) | <code>(files: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts">BinaryFileData</a>) => void </code> | add files data to the appState |
446
484
  | resetScene | `({ resetLoadingState: boolean }) => void` | Resets the scene. If `resetLoadingState` is passed as true then it will also force set the loading state to false. |
447
- | getSceneElementsIncludingDeleted | <pre> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a></pre> | Returns all the elements including the deleted in the scene |
448
- | getSceneElements | <pre> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a></pre> | Returns all the elements excluding the deleted in the scene |
449
- | getAppState | <pre> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a></pre> | Returns current appState |
485
+ | getSceneElementsIncludingDeleted | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a></code> | Returns all the elements including the deleted in the scene |
486
+ | getSceneElements | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a></code> | Returns all the elements excluding the deleted in the scene |
487
+ | getAppState | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L66">AppState</a></code> | Returns current appState |
450
488
  | history | `{ clear: () => void }` | This is the history API. `history.clear()` will clear the history |
451
- | scrollToContent | <pre> (target?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement</a> &#124; <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement</a>[]) => void </pre> | Scroll the nearest element out of the elements supplied to the center. Defaults to the elements on the scene. |
489
+ | scrollToContent | <code> (target?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a> &#124; <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a>[]) => void </code> | Scroll the nearest element out of the elements supplied to the center. Defaults to the elements on the scene. |
452
490
  | refresh | `() => void` | Updates the offsets for the Excalidraw component so that the coordinates are computed correctly (for example the cursor position). You don't have to call this when the position is changed on page scroll or when the excalidraw container resizes (we handle that ourselves). For any other cases if the position of excalidraw is updated (example due to scroll on parent container and not page scroll) you should call this API. |
453
491
  | [importLibrary](#importlibrary) | `(url: string, token?: string) => void` | Imports library from given URL |
454
492
  | setToastMessage | `(message: string) => void` | This API can be used to show the toast with custom message. |
455
493
  | [id](#id) | string | Unique ID for the excalidraw component. |
494
+ | [getFiles](#getFiles) | <code>() => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64">files</a> </code> | This API can be used to get the files present in the scene. It may contain files that aren't referenced by any element, so if you're persisting the files to a storage, you should compare them against stored elements. |
495
+ | [setActiveTool](#setActiveTool) | <code>(tool: { type: typeof <a href="https://github.com/excalidraw/excalidraw/blob/master/src/shapes.tsx#L4">SHAPES</a>[number]["value"] &#124; "eraser" } &#124; { type: "custom"; customType: string }) => void</code> | This API can be used to set the active tool |
496
+ | [setCursor](#setCursor) | <code>(cursor: string) => void </code> | This API can be used to set customise the mouse cursor on the canvas |
497
+ | [resetCursor](#resetCursor) | <code>() => void </code> | This API can be used to reset to default mouse cursor on the canvas |
456
498
 
457
499
  #### `readyPromise`
458
500
 
@@ -465,7 +507,7 @@ Since plain object is passed as a `ref`, the `readyPromise` is resolved as soon
465
507
  ### `updateScene`
466
508
 
467
509
  <pre>
468
- (<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>)) => void
510
+ (scene: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>) => void
469
511
  </pre>
470
512
 
471
513
  You can use this function to update the scene with the sceneData. It accepts the below attributes.
@@ -474,8 +516,37 @@ You can use this function to update the scene with the sceneData. It accepts the
474
516
  | --- | --- | --- |
475
517
  | `elements` | [`ImportedDataState["elements"]`](https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17) | The `elements` to be updated in the scene |
476
518
  | `appState` | [`ImportedDataState["appState"]`](https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L18) | The `appState` to be updated in the scene. |
477
- | `collaborators` | <pre>Map<string, <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L29">Collaborator></a></pre> | The list of collaborators to be updated in the scene. |
519
+ | `collaborators` | <pre>Map<string, <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L35">Collaborator></a></pre> | The list of collaborators to be updated in the scene. |
478
520
  | `commitToHistory` | `boolean` | Implies if the `history (undo/redo)` should be recorded. Defaults to `false`. |
521
+ | `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) &#124; Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)> &#124; ((currentItems: [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)>) => [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) &#124; Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)>) | The `libraryItems` to be update in the scene. |
522
+
523
+ ### `updateLibrary`
524
+
525
+ <pre>
526
+ (opts: {
527
+ libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224">LibraryItemsSource</a>;
528
+ merge?: boolean;
529
+ prompt?: boolean;
530
+ openLibraryMenu?: boolean;
531
+ defaultStatus?: "unpublished" | "published";
532
+ }) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>>
533
+ </pre>
534
+
535
+ You can use this function to update the library. It accepts the below attributes.
536
+
537
+ | Name | Type | Default | Description |
538
+ | --- | --- | --- | --- |
539
+ | `libraryItems` | | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224) | The `libraryItems` to be replaced/merged with current library |
540
+ | `merge` | boolean | `false` | Whether to merge with existing library items. |
541
+ | `prompt` | boolean | `false` | Whether to prompt user for confirmation. |
542
+ | `openLibraryMenu` | boolean | `false` | Whether to open the library menu before importing. |
543
+ | `defaultStatus` | <code>"unpublished" &#124; "published"</code> | `"unpublished"` | Default library item's `status` if not present. |
544
+
545
+ ### `addFiles`
546
+
547
+ <pre>(files: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts">BinaryFileData</a>) => void </pre>
548
+
549
+ Adds supplied files data to the `appState.files` cache on top of existing files present in the cache.
479
550
 
480
551
  #### `onCollabButtonClick`
481
552
 
@@ -504,7 +575,7 @@ This callback is triggered when mouse pointer is updated.
504
575
  ```
505
576
 
506
577
  1. `exportedElements`: An array of [non deleted elements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L87) which needs to be exported.
507
- 2. `appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42) of the scene.
578
+ 2. `appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) of the scene.
508
579
  3. `canvas`: The `HTMLCanvasElement` of the scene.
509
580
 
510
581
  #### `langCode`
@@ -523,7 +594,7 @@ import { defaultLang, languages } from "@excalidraw/excalidraw";
523
594
  #### `renderTopRightUI`
524
595
 
525
596
  <pre>
526
- (isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>) => JSX
597
+ (isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>) => JSX | null
527
598
  </pre>
528
599
 
529
600
  A function returning JSX to render custom UI in the top right corner of the app.
@@ -531,7 +602,7 @@ A function returning JSX to render custom UI in the top right corner of the app.
531
602
  #### `renderFooter`
532
603
 
533
604
  <pre>
534
- (isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>) => JSX
605
+ (isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>) => JSX | null
535
606
  </pre>
536
607
 
537
608
  A function returning JSX to render custom UI footer. For example, you can use this to render a language picker that was previously being rendered by Excalidraw itself (for now, you'll need to implement your own language picker).
@@ -558,7 +629,7 @@ If supplied, this URL will be used when user tries to install a library from [li
558
629
 
559
630
  #### `theme`
560
631
 
561
- This prop controls Excalidraw's theme. When supplied, the value takes precedence over `intialData.appState.theme`, the theme will be fully controlled by the host app, and users won't be able to toggle it from within the app.
632
+ This prop controls Excalidraw's theme. When supplied, the value takes precedence over `intialData.appState.theme`, the theme will be fully controlled by the host app, and users won't be able to toggle it from within the app. You can use [`THEME`](#THEME-1) to specify the theme.
562
633
 
563
634
  #### `name`
564
635
 
@@ -566,7 +637,7 @@ This prop sets the name of the drawing which will be used when exporting the dra
566
637
 
567
638
  #### `UIOptions`
568
639
 
569
- This prop can be used to customise UI of Excalidraw. Currently we support customising only [`canvasActions`](#canvasActions). It accepts the below parameters
640
+ This prop can be used to customise UI of Excalidraw. Currently we support customising [`canvasActions`](#canvasActions) and [`dockedSidebarBreakpoint`](dockedSidebarBreakpoint). It accepts the below parameters
570
641
 
571
642
  <pre>
572
643
  { canvasActions: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L208"> CanvasActions<a/> }
@@ -584,6 +655,12 @@ This prop can be used to customise UI of Excalidraw. Currently we support custom
584
655
  | `theme` | boolean | true | Implies whether to show `Theme toggle` |
585
656
  | `saveAsImage` | boolean | true | Implies whether to show `Save as image button` |
586
657
 
658
+ ##### `dockedSidebarBreakpoint`
659
+
660
+ This prop indicates at what point should we break to a docked, permanent sidebar. If not passed it defaults to [`MQ_RIGHT_SIDEBAR_MAX_WIDTH_PORTRAIT`](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L167). If the `width` of the `excalidraw` container exceeds `dockedSidebarBreakpoint`, the sidebar will be dockable. If user choses to dock the sidebar, it will push the right part of the UI towards the left, making space for the sidebar as shown below.
661
+
662
+ ![image](https://user-images.githubusercontent.com/11256141/174664866-c698c3fa-197b-43ff-956c-d79852c7b326.png)
663
+
587
664
  #### `exportOpts`
588
665
 
589
666
  The below attributes can be set in `UIOptions.canvasActions.export` to customize the export dialog. If `UIOptions.canvasActions.export` is `false` the export button will not be rendered.
@@ -591,7 +668,7 @@ The below attributes can be set in `UIOptions.canvasActions.export` to customize
591
668
  | Attribute | Type | Default | Description |
592
669
  | --- | --- | --- | --- |
593
670
  | `saveFileToDisk` | boolean | true | Implies if save file to disk button should be shown |
594
- | `exportToBackend` | <pre> (exportedElements: readonly NonDeletedExcalidrawElement[],appState: AppState,canvas: HTMLCanvasElement &#124; null) => void </pre> | | This callback is triggered when the shareable-link button is clicked in the export dialog. The link button will only be shown if this callback is passed. |
671
+ | `onExportToBackend` | <pre> (exportedElements: readonly NonDeletedExcalidrawElement[],appState: AppState,canvas: HTMLCanvasElement &#124; null) => void </pre> | | This callback is triggered when the shareable-link button is clicked in the export dialog. The link button will only be shown if this callback is passed. |
595
672
  | `renderCustomUI` | <pre> (exportedElements: readonly NonDeletedExcalidrawElement[],appState: AppState,canvas: HTMLCanvasElement &#124; null) => void </pre> | | This callback should be supplied if you want to render custom UI in the export dialog. |
596
673
 
597
674
  #### `onPaste`
@@ -599,18 +676,14 @@ The below attributes can be set in `UIOptions.canvasActions.export` to customize
599
676
  This callback is triggered if passed when something is pasted into the scene. You can use this callback in case you want to do something additional when the paste event occurs.
600
677
 
601
678
  <pre>
602
- (data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L17">ClipboardData</a>, event: ClipboardEvent &#124; null) => boolean
679
+ (data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L21">ClipboardData</a>, event: ClipboardEvent &#124; null) => boolean
603
680
  </pre>
604
681
 
605
682
  This callback must return a `boolean` value or a [promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/Promise) which resolves to a boolean value.
606
683
 
607
- In case you want to prevent the excalidraw paste action you must return `true`, it will stop the native excalidraw clipboard management flow (nothing will be pasted into the scene).
684
+ In case you want to prevent the excalidraw paste action you must return `false`, it will stop the native excalidraw clipboard management flow (nothing will be pasted into the scene).
608
685
 
609
- ### Does it support collaboration ?
610
-
611
- No, Excalidraw package doesn't come with collaboration built in, since the implementation is specific to each host app. We expose APIs which you can use to communicate with Excalidraw which you can use to implement it. You can check our own implementation [here](https://github.com/excalidraw/excalidraw/blob/master/src/excalidraw-app/index.tsx).
612
-
613
- ### importLibrary
686
+ #### `importLibrary`
614
687
 
615
688
  Imports library from given URL. You should call this on `hashchange`, passing the `addLibrary` value if you detect it as shown below. Optionally pass a CSRF `token` to skip prompting during installation (retrievable via `token` key from the url coming from [https://libraries.excalidraw.com](https://libraries.excalidraw.com/)).
616
689
 
@@ -632,19 +705,39 @@ useEffect(() => {
632
705
 
633
706
  Try out the [Demo](#Demo) to see it in action.
634
707
 
635
- ### detectScroll
708
+ #### `setActiveTool`
709
+
710
+ This API has the below signature. It sets the `tool` passed in param as the active tool.
711
+
712
+ <pre>
713
+ (tool: { type: typeof <a href="https://github.com/excalidraw/excalidraw/blob/master/src/shapes.tsx#L4">SHAPES</a>[number]["value"] &#124; "eraser" } &#124; { type: "custom"; customType: string }) => void
714
+ </pre>
715
+
716
+ #### `setCursor`
717
+
718
+ This API can be used to customise the mouse cursor on the canvas and has the below signature. It sets the mouse cursor to the cursor passed in param.
719
+
720
+ <pre>
721
+ (cursor: string) => void
722
+ </pre>
723
+
724
+ #### `resetCursor`
725
+
726
+ This API can be used to reset to default mouse cursor.
727
+
728
+ #### `detectScroll`
636
729
 
637
730
  Indicates whether Excalidraw should listen for `scroll` event on the nearest scrollable container in the DOM tree and recompute the coordinates (e.g. to correctly handle the cursor) when the component's position changes. You can disable this when you either know this doesn't affect your app or you want to take care of it yourself (calling the [`refresh()`](#ref) method).
638
731
 
639
- ### handleKeyboardGlobally
732
+ #### `handleKeyboardGlobally`
640
733
 
641
734
  Indicates whether to bind keyboard events to `document`. Disabled by default, meaning the keyboard events are bound to the Excalidraw component. This allows for multiple Excalidraw components to live on the same page, and ensures that Excalidraw keyboard handling doesn't collide with your app's (or the browser) when the component isn't focused.
642
735
 
643
736
  Enable this if you want Excalidraw to handle keyboard even if the component isn't focused (e.g. a user is interacting with the navbar, sidebar, or similar).
644
737
 
645
- ### onLibraryChange
738
+ #### `onLibraryChange`
646
739
 
647
- Ths callback if supplied will get triggered when the library is updated and has the below signature.
740
+ This callback if supplied will get triggered when the library is updated and has the below signature.
648
741
 
649
742
  <pre>
650
743
  (items: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => void | Promise<any>
@@ -652,58 +745,74 @@ Ths callback if supplied will get triggered when the library is updated and has
652
745
 
653
746
  It is invoked with empty items when user clears the library. You can use this callback when you want to do something additional when library is updated for example persisting it to local storage.
654
747
 
655
- ### id
748
+ #### `id`
656
749
 
657
750
  The unique id of the excalidraw component. This can be used to identify the excalidraw component, for example importing the library items to the excalidraw component from where it was initiated when you have multiple excalidraw components rendered on the same page as shown in [multiple excalidraw demo](https://codesandbox.io/s/multiple-excalidraw-k1xx5).
658
751
 
659
- ### autoFocus
752
+ #### `autoFocus`
660
753
 
661
754
  This prop implies whether to focus the Excalidraw component on page load. Defaults to false.
662
755
 
663
- ### Extra API's
664
-
665
- #### `getSceneVersion`
666
-
667
- **How to use**
668
-
669
- <pre>
670
- import { getSceneVersion } from "@excalidraw/excalidraw";
671
- getSceneVersion(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>)
672
- </pre>
756
+ #### `generateIdForFile`
673
757
 
674
- This function returns the current scene version.
675
-
676
- #### `isInvisiblySmallElement`
758
+ Allows you to override `id` generation for files added on canvas (images). By default, an SHA-1 digest of the file is used.
677
759
 
678
- **_Signature_**
760
+ ```
761
+ (file: File) => string | Promise<string>
762
+ ```
679
763
 
680
- <pre>
681
- isInvisiblySmallElement(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement</a>): boolean
682
- </pre>
764
+ #### `onLinkOpen`
683
765
 
684
- **How to use**
766
+ This prop if passed will be triggered when clicked on link. To handle the redirect yourself (such as when using your own router for internal links), you must call `event.preventDefault()`.
685
767
 
686
- ```js
687
- import { isInvisiblySmallElement } from "@excalidraw/excalidraw";
768
+ ```
769
+ (element: ExcalidrawElement, event: CustomEvent<{ nativeEvent: MouseEvent }>) => void
688
770
  ```
689
771
 
690
- Returns `true` if element is invisibly small (e.g. width & height are zero).
772
+ Example:
773
+
774
+ ```ts
775
+ const history = useHistory();
776
+
777
+ // open internal links using the app's router, but opens external links in
778
+ // a new tab/window
779
+ const onLinkOpen: ExcalidrawProps["onLinkOpen"] = useCallback(
780
+ (element, event) => {
781
+ const link = element.link;
782
+ const { nativeEvent } = event.detail;
783
+ const isNewTab = nativeEvent.ctrlKey || nativeEvent.metaKey;
784
+ const isNewWindow = nativeEvent.shiftKey;
785
+ const isInternalLink =
786
+ link.startsWith("/") || link.includes(window.location.origin);
787
+ if (isInternalLink && !isNewTab && !isNewWindow) {
788
+ history.push(link.replace(window.location.origin, ""));
789
+ // signal that we're handling the redirect ourselves
790
+ event.preventDefault();
791
+ }
792
+ },
793
+ [history],
794
+ );
795
+ ```
691
796
 
692
- #### `getElementMap`
797
+ #### `onPointerDown`
693
798
 
694
- **_Signature_**
799
+ This prop if passed will be triggered on pointer down events and has the below signature.
695
800
 
696
801
  <pre>
697
- getElementsMap(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>): {[id: string]: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement</a>}
802
+ (activeTool: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L93"> AppState["activeTool"]</a>, pointerDownState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L365">PointerDownState</a>) => void
698
803
  </pre>
699
804
 
700
- **How to use**
805
+ #### `onScrollChange`
701
806
 
702
- ```js
703
- import { getElementsMap } from "@excalidraw/excalidraw";
807
+ This prop if passed will be triggered when canvas is scrolled and has the below signature.
808
+
809
+ ```ts
810
+ (scrollX: number, scrollY: number) => void
704
811
  ```
705
812
 
706
- This function returns an object where each element is mapped to its id.
813
+ ### Does it support collaboration ?
814
+
815
+ No, Excalidraw package doesn't come with collaboration built in, since the implementation is specific to each host app. We expose APIs which you can use to communicate with Excalidraw which you can use to implement it. You can check our own implementation [here](https://github.com/excalidraw/excalidraw/blob/master/src/excalidraw-app/index.tsx).
707
816
 
708
817
  ### Restore utilities
709
818
 
@@ -712,7 +821,7 @@ This function returns an object where each element is mapped to its id.
712
821
  **_Signature_**
713
822
 
714
823
  <pre>
715
- restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17">ImportedDataState["appState"]</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>> | null): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>
824
+ restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17">ImportedDataState["appState"]</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>> | null): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>
716
825
  </pre>
717
826
 
718
827
  **_How to use_**
@@ -721,7 +830,7 @@ restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob
721
830
  import { restoreAppState } from "@excalidraw/excalidraw";
722
831
  ```
723
832
 
724
- This function will make sure all the keys have appropriate values in [appState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42) and if any key is missing, it will be set to default value.
833
+ This function will make sure all the keys have appropriate values in [appState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) and if any key is missing, it will be set to default value.
725
834
 
726
835
  When `localAppState` is supplied, it's used in place of values that are missing (`undefined`) in `appState` instead of defaults. Use this as a way to not override user's defaults if you persist them. Required: supply `null`/`undefined` if not applicable.
727
836
 
@@ -730,7 +839,7 @@ When `localAppState` is supplied, it's used in place of values that are missing
730
839
  **_Signature_**
731
840
 
732
841
  <pre>
733
- restoreElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ImportedDataState["elements"]</a>, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>
842
+ restoreElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ImportedDataState["elements"]</a>, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>
734
843
  </pre>
735
844
 
736
845
  **_How to use_**
@@ -748,7 +857,7 @@ When `localElements` are supplied, they are used to ensure that existing restore
748
857
  **_Signature_**
749
858
 
750
859
  <pre>
751
- restoreElements(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L12">ImportedDataState</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>> | null | undefined, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L4">DataState</a>
860
+ restoreElements(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L12">ImportedDataState</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>> | null | undefined, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L4">DataState</a>
752
861
  </pre>
753
862
 
754
863
  See [`restoreAppState()`](https://github.com/excalidraw/excalidraw/blob/master/src/packages/excalidraw/README.md#restoreAppState) about `localAppState`, and [`restoreElements()`](https://github.com/excalidraw/excalidraw/blob/master/src/packages/excalidraw/README.md#restoreElements) about `localElements`.
@@ -761,18 +870,23 @@ import { restore } from "@excalidraw/excalidraw";
761
870
 
762
871
  This function makes sure elements and state is set to appropriate values and set to default value if not present. It is a combination of [restoreElements](#restoreElements) and [restoreAppState](#restoreAppState).
763
872
 
764
- #### `serializeAsJSON`
873
+ #### `restoreLibraryItems`
765
874
 
766
875
  **_Signature_**
767
876
 
768
877
  <pre>
769
- serializeAsJSON({
770
- elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>,
771
- appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>,
772
- }): string
878
+ restoreLibraryItems(libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L22">ImportedDataState["libraryItems"]</a>, defaultStatus: "published" | "unpublished")
773
879
  </pre>
774
880
 
775
- Takes the scene elements and state and returns a JSON string. Deleted `elements`as well as most properties from `AppState` are removed from the resulting JSON. (see [`serializeAsJSON()`](https://github.com/excalidraw/excalidraw/blob/master/src/data/json.ts#L16) source for details).
881
+ **_How to use_**
882
+
883
+ ```js
884
+ import { restoreLibraryItems } from "@excalidraw/excalidraw";
885
+
886
+ restoreLibraryItems(libraryItems, "unpublished");
887
+ ```
888
+
889
+ This function normalizes library items elements, adding missing values when needed.
776
890
 
777
891
  ### Export utilities
778
892
 
@@ -785,14 +899,17 @@ Takes the scene elements and state and returns a JSON string. Deleted `elements`
785
899
  elements,
786
900
  appState
787
901
  getDimensions,
788
- }: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L10">ExportOpts</a>
902
+ files
903
+ }: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L12">ExportOpts</a>
789
904
  </pre>
790
905
 
791
906
  | Name | Type | Default | Description |
792
907
  | --- | --- | --- | --- |
793
908
  | elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types) | | The elements to be exported to canvas |
794
909
  | appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L12) | [defaultAppState](https://github.com/excalidraw/excalidraw/blob/master/src/appState.ts#L11) | The app state of the scene |
795
- | getDimensions | `(width: number, height: number) => {width: number, height: number, scale: number)` | `(width, height) => ({ width, height, scale: 1 })` | A function which returns the width, height and scale with which canvas is to be exported. |
910
+ | getDimensions | `(width: number, height: number) => { width: number, height: number, scale?: number }` | undefined | A function which returns the `width`, `height`, and optionally `scale` (defaults `1`), with which canvas is to be exported. |
911
+ | maxWidthOrHeight | `number` | undefined | The maximum width or height of the exported image. If provided, `getDimensions` is ignored. |
912
+ | files | [BinaryFiles](The [`BinaryFiles`](<[BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64)>) | undefined | The files added to the scene. |
796
913
 
797
914
  **How to use**
798
915
 
@@ -808,7 +925,7 @@ This function returns the canvas with the exported elements, appState and dimens
808
925
 
809
926
  <pre>
810
927
  exportToBlob(
811
- opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L10">ExportOpts</a> & {
928
+ opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L14">ExportOpts</a> & {
812
929
  mimeType?: string,
813
930
  quality?: number;
814
931
  })
@@ -834,21 +951,51 @@ Returns a promise which resolves with a [blob](https://developer.mozilla.org/en-
834
951
 
835
952
  <pre>
836
953
  exportToSvg({
837
- elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>,
838
- appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>,
954
+ elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>,
955
+ appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>,
839
956
  exportPadding?: number,
840
957
  metadata?: string,
958
+ files?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64">BinaryFiles</a>
841
959
  })
842
960
  </pre>
843
961
 
844
962
  | Name | Type | Default | Description |
845
963
  | --- | --- | --- | --- |
846
- | elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78) | | The elements to exported as svg |
847
- | appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42) | [defaultAppState](https://github.com/excalidraw/excalidraw/blob/master/src/appState.ts#L11) | The app state of the scene |
964
+ | elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) | | The elements to exported as svg |
965
+ | appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) | [defaultAppState](https://github.com/excalidraw/excalidraw/blob/master/src/appState.ts#L11) | The app state of the scene |
848
966
  | exportPadding | number | 10 | The padding to be added on canvas |
967
+ | files | [BinaryFiles](The [`BinaryFiles`](<[BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64)>) | undefined | The files added to the scene. |
849
968
 
850
969
  This function returns a promise which resolves to svg of the exported drawing.
851
970
 
971
+ #### `exportToClipboard`
972
+
973
+ **_Signature_**
974
+
975
+ <pre>
976
+ exportToClipboard(
977
+ opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L14">ExportOpts</a> & {
978
+ mimeType?: string,
979
+ quality?: number;
980
+ type: 'png' | 'svg' |'json'
981
+ })
982
+ </pre>
983
+
984
+ | Name | Type | Default | Description |
985
+ | --- | --- | --- | --- | --- | --- |
986
+ | opts | | | This param is same as the params passed to `exportToCanvas`. You can refer to [`exportToCanvas`](#exportToCanvas). |
987
+ | mimeType | string | "image/png" | Indicates the image format, this will be used when exporting as `png`. |
988
+ | quality | number | 0.92 | A value between 0 and 1 indicating the [image quality](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob#parameters). Applies only to `image/jpeg`/`image/webp` MIME types. This will be used when exporting as `png`. |
989
+ | type | 'png' | 'svg' | 'json' | | This determines the format to which the scene data should be exported. |
990
+
991
+ **How to use**
992
+
993
+ ```js
994
+ import { exportToClipboard } from "@excalidraw/excalidraw";
995
+ ```
996
+
997
+ Copies the scene data in the specified format (determined by `type`) to clipboard.
998
+
852
999
  ##### Additional attributes of appState for `export\*` APIs
853
1000
 
854
1001
  | Name | Type | Default | Description |
@@ -856,27 +1003,66 @@ This function returns a promise which resolves to svg of the exported drawing.
856
1003
  | exportBackground | boolean | true | Indicates whether background should be exported |
857
1004
  | viewBackgroundColor | string | #fff | The default background color |
858
1005
  | exportWithDarkMode | boolean | false | Indicates whether to export with dark mode |
859
- | exportEmbedScene | boolean | false | Indicates whether scene data should be embedded in svg. This will increase the svg size. |
1006
+ | exportEmbedScene | boolean | false | Indicates whether scene data should be embedded in svg/png. This will increase the image size. |
1007
+
1008
+ ### Extra API's
1009
+
1010
+ #### `serializeAsJSON`
1011
+
1012
+ **_Signature_**
1013
+
1014
+ <pre>
1015
+ serializeAsJSON({
1016
+ elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>,
1017
+ appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>,
1018
+ }): string
1019
+ </pre>
1020
+
1021
+ Takes the scene elements and state and returns a JSON string. Deleted `elements`as well as most properties from `AppState` are removed from the resulting JSON. (see [`serializeAsJSON()`](https://github.com/excalidraw/excalidraw/blob/master/src/data/json.ts#L16) source for details).
1022
+
1023
+ If you want to overwrite the source field in the JSON string, you can set `window.EXCALIDRAW_EXPORT_SOURCE` to the desired value.
860
1024
 
861
- ### FONT_FAMILY
1025
+ #### `serializeLibraryAsJSON`
1026
+
1027
+ **_Signature_**
1028
+
1029
+ <pre>
1030
+ serializeLibraryAsJSON({
1031
+ libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems[]</a>,
1032
+ </pre>
1033
+
1034
+ Takes the library items and returns a JSON string.
1035
+
1036
+ If you want to overwrite the source field in the JSON string, you can set `window.EXCALIDRAW_EXPORT_SOURCE` to the desired value.
1037
+
1038
+ #### `getSceneVersion`
862
1039
 
863
1040
  **How to use**
864
1041
 
865
- ```js
866
- import { FONT_FAMILY } from "@excalidraw/excalidraw";
867
- ```
1042
+ <pre>
1043
+ import { getSceneVersion } from "@excalidraw/excalidraw";
1044
+ getSceneVersion(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>)
1045
+ </pre>
868
1046
 
869
- `FONT_FAMILY` contains all the font families used in `Excalidraw` as explained below
1047
+ This function returns the current scene version.
870
1048
 
871
- | Font Family | Description |
872
- | ----------- | -------------------- |
873
- | Virgil | The handwritten font |
874
- | Helvetica | The Normal Font |
875
- | Cascadia | The Code Font |
1049
+ #### `isInvisiblySmallElement`
876
1050
 
877
- Defaults to `FONT_FAMILY.Virgil` unless passed in `initialData.appState.currentItemFontFamily`.
1051
+ **_Signature_**
878
1052
 
879
- ### loadLibraryFromBlob
1053
+ <pre>
1054
+ isInvisiblySmallElement(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a>): boolean
1055
+ </pre>
1056
+
1057
+ **How to use**
1058
+
1059
+ ```js
1060
+ import { isInvisiblySmallElement } from "@excalidraw/excalidraw";
1061
+ ```
1062
+
1063
+ Returns `true` if element is invisibly small (e.g. width & height are zero).
1064
+
1065
+ #### `loadLibraryFromBlob`
880
1066
 
881
1067
  ```js
882
1068
  import { loadLibraryFromBlob } from "@excalidraw/excalidraw";
@@ -890,23 +1076,59 @@ loadLibraryFromBlob(blob: <a href="https://developer.mozilla.org/en-US/docs/Web/
890
1076
 
891
1077
  This function loads the library from the blob.
892
1078
 
893
- ### loadFromBlob
1079
+ #### `loadFromBlob`
894
1080
 
895
1081
  **How to use**
896
1082
 
897
1083
  ```js
898
1084
  import { loadFromBlob } from "@excalidraw/excalidraw";
1085
+
1086
+ const scene = await loadFromBlob(file, null, null);
1087
+ excalidrawAPI.updateScene(scene);
899
1088
  ```
900
1089
 
901
1090
  **Signature**
902
1091
 
903
1092
  <pre>
904
- loadFromBlob(blob: <a href="https://developer.mozilla.org/en-US/docs/Web/API/Blob">Blob</a>, localAppState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a> | null)
1093
+ loadFromBlob(
1094
+ blob: <a href="https://developer.mozilla.org/en-US/docs/Web/API/Blob">Blob</a>,
1095
+ localAppState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a> | null,
1096
+ localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a> | null,
1097
+ fileHandle?: FileSystemHandle | null
1098
+ ) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/restore.ts#L53">RestoredDataState</a>>
905
1099
  </pre>
906
1100
 
907
- This function loads the scene data from the blob. If you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob`
1101
+ This function loads the scene data from the blob (or file). If you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob`. Throws if blob doesn't contain valid scene data.
908
1102
 
909
- ### getFreeDrawSvgPath
1103
+ #### `loadSceneOrLibraryFromBlob`
1104
+
1105
+ **How to use**
1106
+
1107
+ ```js
1108
+ import { loadSceneOrLibraryFromBlob, MIME_TYPES } from "@excalidraw/excalidraw";
1109
+
1110
+ const contents = await loadSceneOrLibraryFromBlob(file, null, null);
1111
+ if (contents.type === MIME_TYPES.excalidraw) {
1112
+ excalidrawAPI.updateScene(contents.data);
1113
+ } else if (contents.type === MIME_TYPES.excalidrawlib) {
1114
+ excalidrawAPI.updateLibrary(contents.data);
1115
+ }
1116
+ ```
1117
+
1118
+ **Signature**
1119
+
1120
+ <pre>
1121
+ loadSceneOrLibraryFromBlob(
1122
+ blob: <a href="https://developer.mozilla.org/en-US/docs/Web/API/Blob">Blob</a>,
1123
+ localAppState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a> | null,
1124
+ localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a> | null,
1125
+ fileHandle?: FileSystemHandle | null
1126
+ ) => Promise<{ type: string, data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/restore.ts#L53">RestoredDataState</a> | <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L33">ImportedLibraryState</a>}>
1127
+ </pre>
1128
+
1129
+ This function loads either scene or library data from the supplied blob. If the blob contains scene data, and you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob`. Throws if blob doesn't contain neither valid scene data or library data.
1130
+
1131
+ #### `getFreeDrawSvgPath`
910
1132
 
911
1133
  **How to use**
912
1134
 
@@ -922,6 +1144,220 @@ getFreeDrawSvgPath(element: <a href="https://github.com/excalidraw/excalidraw/bl
922
1144
 
923
1145
  This function returns the free draw svg path for the element.
924
1146
 
1147
+ #### `isLinearElement`
1148
+
1149
+ **How to use**
1150
+
1151
+ ```js
1152
+ import { isLinearElement } from "@excalidraw/excalidraw";
1153
+ ```
1154
+
1155
+ **Signature**
1156
+
1157
+ <pre>
1158
+ isLinearElement(elementType?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L80">ExcalidrawElement</a>): boolean
1159
+ </pre>
1160
+
1161
+ This function returns true if the element is linear type (`arrow` |`line`) else returns false.
1162
+
1163
+ #### `getNonDeletedElements`
1164
+
1165
+ **How to use**
1166
+
1167
+ ```js
1168
+ import { getNonDeletedElements } from "@excalidraw/excalidraw";
1169
+ ```
1170
+
1171
+ **Signature**
1172
+
1173
+ <pre>
1174
+ getNonDeletedElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L80"> readonly ExcalidrawElement[]</a>): as readonly <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L90">NonDeletedExcalidrawElement[]</a>
1175
+ </pre>
1176
+
1177
+ This function returns an array of deleted elements.
1178
+
1179
+ #### `mergeLibraryItems`
1180
+
1181
+ ```js
1182
+ import { mergeLibraryItems } from "@excalidraw/excalidraw";
1183
+ ```
1184
+
1185
+ **_Signature_**
1186
+
1187
+ <pre>
1188
+ mergeLibraryItems(localItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>, otherItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>
1189
+ </pre>
1190
+
1191
+ This function merges two `LibraryItems` arrays, where unique items from `otherItems` are sorted first in the returned array.
1192
+
1193
+ #### `parseLibraryTokensFromUrl`
1194
+
1195
+ **How to use**
1196
+
1197
+ ```js
1198
+ import { parseLibraryTokensFromUrl } from "@excalidraw/excalidraw";
1199
+ ```
1200
+
1201
+ **Signature**
1202
+
1203
+ <pre>
1204
+ parseLibraryTokensFromUrl(): {
1205
+ libraryUrl: string;
1206
+ idToken: string | null;
1207
+ } | null
1208
+ </pre>
1209
+
1210
+ Parses library parameters from URL if present (expects the `#addLibrary` hash key), and returns an object with the `libraryUrl` and `idToken`. Returns `null` if `#addLibrary` hash key not found.
1211
+
1212
+ #### `useHandleLibrary`
1213
+
1214
+ **How to use**
1215
+
1216
+ ```js
1217
+ import { useHandleLibrary } from "@excalidraw/excalidraw";
1218
+
1219
+ export const App = () => {
1220
+ // ...
1221
+ useHandleLibrary({ excalidrawAPI });
1222
+ };
1223
+ ```
1224
+
1225
+ **Signature**
1226
+
1227
+ <pre>
1228
+ useHandleLibrary(opts: {
1229
+ excalidrawAPI: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L432">ExcalidrawAPI</a>,
1230
+ getInitialLibraryItems?: () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224">LibraryItemsSource</a>
1231
+ });
1232
+ </pre>
1233
+
1234
+ A hook that automatically imports library from url if `#addLibrary` hash key exists on initial load, or when it changes during the editing session (e.g. when a user installs a new library), and handles initial library load if `getInitialLibraryItems` getter is supplied.
1235
+
1236
+ In the future, we will be adding support for handling library persistence to browser storage (or elsewhere).
1237
+
1238
+ #### `sceneCoordsToViewportCoords`
1239
+
1240
+ ```js
1241
+ import { sceneCoordsToViewportCoords } from "@excalidraw/excalidraw";
1242
+ ```
1243
+
1244
+ **_Signature_**
1245
+
1246
+ <pre>
1247
+ sceneCoordsToViewportCoords({sceneX: number, sceneY: number}, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>): {x: number, y: number}
1248
+ </pre>
1249
+
1250
+ This function returns equivalent viewport coords for the provided scene coords in params.
1251
+
1252
+ #### `viewportCoordsToSceneCoords`
1253
+
1254
+ ```js
1255
+ import { viewportCoordsToSceneCoords } from "@excalidraw/excalidraw";
1256
+ ```
1257
+
1258
+ **_Signature_**
1259
+
1260
+ <pre>
1261
+ viewportCoordsToSceneCoords({clientX: number, clientY: number}, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>): {x: number, y: number}
1262
+ </pre>
1263
+
1264
+ This function returns equivalent scene coords for the provided viewport coords in params.
1265
+
1266
+ ### Exported constants
1267
+
1268
+ #### `FONT_FAMILY`
1269
+
1270
+ **How to use**
1271
+
1272
+ ```js
1273
+ import { FONT_FAMILY } from "@excalidraw/excalidraw";
1274
+ ```
1275
+
1276
+ `FONT_FAMILY` contains all the font families used in `Excalidraw` as explained below
1277
+
1278
+ | Font Family | Description |
1279
+ | ----------- | -------------------- |
1280
+ | Virgil | The handwritten font |
1281
+ | Helvetica | The Normal Font |
1282
+ | Cascadia | The Code Font |
1283
+
1284
+ Defaults to `FONT_FAMILY.Virgil` unless passed in `initialData.appState.currentItemFontFamily`.
1285
+
1286
+ #### `THEME`
1287
+
1288
+ **How to use**
1289
+
1290
+ ```js
1291
+ import { THEME } from "@excalidraw/excalidraw";
1292
+ ```
1293
+
1294
+ `THEME` contains all the themes supported by `Excalidraw` as explained below
1295
+
1296
+ | Theme | Description |
1297
+ | ----- | --------------- |
1298
+ | LIGHT | The light theme |
1299
+ | DARK | The Dark theme |
1300
+
1301
+ Defaults to `THEME.LIGHT` unless passed in `initialData.appState.theme`
1302
+
1303
+ ### `MIME_TYPES`
1304
+
1305
+ **How to use **
1306
+
1307
+ ```js
1308
+ import { MIME_TYPES } from "@excalidraw/excalidraw";
1309
+ ```
1310
+
1311
+ [`MIME_TYPES`](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L92) contains all the mime types supported by `Excalidraw`.
1312
+
925
1313
  ## Need help?
926
1314
 
927
1315
  Check out the existing [Q&A](https://github.com/excalidraw/excalidraw/discussions?discussions_q=label%3Apackage%3Aexcalidraw). If you have any queries or need help, ask us [here](https://github.com/excalidraw/excalidraw/discussions?discussions_q=label%3Apackage%3Aexcalidraw).
1316
+
1317
+ ### Development
1318
+
1319
+ #### Install the dependencies
1320
+
1321
+ ```bash
1322
+ yarn
1323
+ ```
1324
+
1325
+ #### Start the server
1326
+
1327
+ ```bash
1328
+ yarn start
1329
+ ```
1330
+
1331
+ [http://localhost:3001](http://localhost:3001) will open in your default browser.
1332
+
1333
+ The example is same as the [codesandbox example](https://ehlz3.csb.app/)
1334
+
1335
+ #### Create a test release
1336
+
1337
+ You can create a test release by posting the below comment in your pull request
1338
+
1339
+ ```
1340
+ @excalibot trigger release
1341
+ ```
1342
+
1343
+ Once the version is released `@excalibot` will post a comment with the release version.
1344
+
1345
+ #### Creating a production release
1346
+
1347
+ To release the next stable version follow the below steps
1348
+
1349
+ ```
1350
+ yarn prerelease version
1351
+ ```
1352
+
1353
+ You need to pass the `version` for which you want to create the release. This will make the changes needed before making the release like updating `package.json`, `changelog` and more.
1354
+
1355
+ The next step is to run the `release` script
1356
+
1357
+ ```
1358
+ yarn release
1359
+ ```
1360
+
1361
+ This will publish the package.
1362
+
1363
+ Right now there are two steps to create a production release but once this works fine these scripts will be combined and more automation will be done.