@myoc/excalidraw 0.19.502 → 0.19.504

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 (329) hide show
  1. package/CHANGELOG.md +586 -9
  2. package/README.md +111 -14
  3. package/dist/dev/{chunk-WBVI4CIR.js → chunk-KLM3KPI7.js} +26 -3
  4. package/dist/dev/chunk-KLM3KPI7.js.map +7 -0
  5. package/dist/dev/{chunk-ERXRO4IP.js → chunk-OF725VHI.js} +2 -2
  6. package/dist/dev/chunk-URPEKBQ3.js +69 -0
  7. package/dist/dev/chunk-URPEKBQ3.js.map +7 -0
  8. package/dist/dev/{chunk-WGIZZ2NT.js → chunk-Z5DMFRJ5.js} +60 -72
  9. package/dist/dev/chunk-Z5DMFRJ5.js.map +7 -0
  10. package/dist/dev/data/{image-BOZX7YCK.js → image-ZR5DXOGS.js} +3 -3
  11. package/dist/dev/index.css +225 -95
  12. package/dist/dev/index.css.map +3 -3
  13. package/dist/dev/index.js +6949 -4013
  14. package/dist/dev/index.js.map +4 -4
  15. package/dist/dev/locales/{ar-SA-B565KYUE.js → ar-SA-U3PIVEZH.js} +4 -2
  16. package/dist/dev/locales/{ar-SA-B565KYUE.js.map → ar-SA-U3PIVEZH.js.map} +2 -2
  17. package/dist/dev/locales/{az-AZ-2OH7OPJT.js → az-AZ-COAM4HVM.js} +3 -1
  18. package/dist/dev/locales/{az-AZ-2OH7OPJT.js.map → az-AZ-COAM4HVM.js.map} +2 -2
  19. package/dist/dev/locales/{bg-BG-MP6UWIVG.js → bg-BG-D6B2W7JL.js} +4 -2
  20. package/dist/dev/locales/{bg-BG-MP6UWIVG.js.map → bg-BG-D6B2W7JL.js.map} +2 -2
  21. package/dist/dev/locales/{bn-BD-WUCPUYTQ.js → bn-BD-BU7GZAZW.js} +3 -1
  22. package/dist/dev/locales/{bn-BD-WUCPUYTQ.js.map → bn-BD-BU7GZAZW.js.map} +2 -2
  23. package/dist/dev/locales/{bn-IN-QX4DSL53.js → bn-IN-MYKDEVNA.js} +3 -1
  24. package/dist/dev/locales/{bn-IN-QX4DSL53.js.map → bn-IN-MYKDEVNA.js.map} +2 -2
  25. package/dist/dev/locales/{ca-ES-KWEKW4C3.js → ca-ES-GEEW5L7T.js} +57 -3
  26. package/dist/dev/locales/{ca-ES-KWEKW4C3.js.map → ca-ES-GEEW5L7T.js.map} +2 -2
  27. package/dist/dev/locales/{cs-CZ-W5AHZB5H.js → cs-CZ-LNVE3QM5.js} +57 -3
  28. package/dist/dev/locales/{cs-CZ-W5AHZB5H.js.map → cs-CZ-LNVE3QM5.js.map} +2 -2
  29. package/dist/dev/locales/{da-DK-ITTM6YM4.js → da-DK-CAYJG7FJ.js} +56 -2
  30. package/dist/dev/locales/{da-DK-ITTM6YM4.js.map → da-DK-CAYJG7FJ.js.map} +2 -2
  31. package/dist/dev/locales/{de-CH-OAWPDQFJ.js → de-CH-GCXOD4LK.js} +63 -9
  32. package/dist/dev/locales/de-CH-GCXOD4LK.js.map +7 -0
  33. package/dist/dev/locales/{de-DE-ZRDYEPMS.js → de-DE-CGDBECYD.js} +57 -3
  34. package/dist/dev/locales/{de-DE-ZRDYEPMS.js.map → de-DE-CGDBECYD.js.map} +2 -2
  35. package/dist/dev/locales/{el-GR-QXASZLPE.js → el-GR-G5QZC24A.js} +57 -3
  36. package/dist/dev/locales/{el-GR-QXASZLPE.js.map → el-GR-G5QZC24A.js.map} +2 -2
  37. package/dist/dev/locales/{en-GV3XLAUG.js → en-I7VEBYIX.js} +4 -2
  38. package/dist/dev/locales/{es-ES-VLQBB7FJ.js → es-ES-UMEOH76W.js} +57 -3
  39. package/dist/dev/locales/{es-ES-VLQBB7FJ.js.map → es-ES-UMEOH76W.js.map} +2 -2
  40. package/dist/dev/locales/{eu-ES-TF2DGTZU.js → eu-ES-IWRZXJC5.js} +57 -3
  41. package/dist/dev/locales/{eu-ES-TF2DGTZU.js.map → eu-ES-IWRZXJC5.js.map} +2 -2
  42. package/dist/dev/locales/{fa-IR-ITKFQ7QV.js → fa-IR-QOYVIIJA.js} +57 -3
  43. package/dist/dev/locales/{fa-IR-ITKFQ7QV.js.map → fa-IR-QOYVIIJA.js.map} +2 -2
  44. package/dist/dev/locales/{fi-FI-UWZRVXFI.js → fi-FI-BXRW65OA.js} +57 -3
  45. package/dist/dev/locales/{fi-FI-UWZRVXFI.js.map → fi-FI-BXRW65OA.js.map} +2 -2
  46. package/dist/dev/locales/{fr-FR-A72LKGCO.js → fr-FR-R2QH5VCW.js} +57 -3
  47. package/dist/dev/locales/{fr-FR-A72LKGCO.js.map → fr-FR-R2QH5VCW.js.map} +2 -2
  48. package/dist/dev/locales/{gl-ES-2QCVIBFP.js → gl-ES-4ES3ZADP.js} +57 -3
  49. package/dist/dev/locales/{gl-ES-2QCVIBFP.js.map → gl-ES-4ES3ZADP.js.map} +2 -2
  50. package/dist/dev/locales/{he-IL-WJNUHU26.js → he-IL-TRQRRYPH.js} +57 -3
  51. package/dist/dev/locales/{he-IL-WJNUHU26.js.map → he-IL-TRQRRYPH.js.map} +2 -2
  52. package/dist/dev/locales/{hi-IN-XGMO235V.js → hi-IN-U46BOJEC.js} +66 -12
  53. package/dist/dev/locales/hi-IN-U46BOJEC.js.map +7 -0
  54. package/dist/dev/locales/{hu-HU-37FDQFIS.js → hu-HU-JDULJ6XL.js} +146 -92
  55. package/dist/dev/locales/hu-HU-JDULJ6XL.js.map +7 -0
  56. package/dist/dev/locales/{id-ID-EJIDCO4E.js → id-ID-BLIXNCUT.js} +57 -3
  57. package/dist/dev/locales/{id-ID-EJIDCO4E.js.map → id-ID-BLIXNCUT.js.map} +2 -2
  58. package/dist/dev/locales/{it-IT-X34PIOJ2.js → it-IT-6TBW7RUK.js} +57 -3
  59. package/dist/dev/locales/{it-IT-X34PIOJ2.js.map → it-IT-6TBW7RUK.js.map} +2 -2
  60. package/dist/dev/locales/{ja-JP-37FC23PR.js → ja-JP-6HYAQFYX.js} +57 -3
  61. package/dist/dev/locales/{ja-JP-37FC23PR.js.map → ja-JP-6HYAQFYX.js.map} +2 -2
  62. package/dist/dev/locales/{kaa-7ZYDFVKA.js → kaa-Z5UP62XJ.js} +56 -2
  63. package/dist/dev/locales/{kaa-7ZYDFVKA.js.map → kaa-Z5UP62XJ.js.map} +2 -2
  64. package/dist/dev/locales/{kab-KAB-MILWXBA6.js → kab-KAB-Z7STWQKS.js} +57 -3
  65. package/dist/dev/locales/{kab-KAB-MILWXBA6.js.map → kab-KAB-Z7STWQKS.js.map} +2 -2
  66. package/dist/dev/locales/{kk-KZ-7BWTPIAV.js → kk-KZ-BWHY45DX.js} +56 -2
  67. package/dist/dev/locales/{kk-KZ-7BWTPIAV.js.map → kk-KZ-BWHY45DX.js.map} +2 -2
  68. package/dist/dev/locales/{km-KH-BV4P2KSZ.js → km-KH-HGLNWNRU.js} +57 -3
  69. package/dist/dev/locales/{km-KH-BV4P2KSZ.js.map → km-KH-HGLNWNRU.js.map} +2 -2
  70. package/dist/dev/locales/{ko-KR-TSXE5P7B.js → ko-KR-CO36WKPC.js} +57 -3
  71. package/dist/dev/locales/{ko-KR-TSXE5P7B.js.map → ko-KR-CO36WKPC.js.map} +2 -2
  72. package/dist/dev/locales/{ku-TR-ASSXNN3U.js → ku-TR-AACVIARC.js} +57 -3
  73. package/dist/dev/locales/{ku-TR-ASSXNN3U.js.map → ku-TR-AACVIARC.js.map} +2 -2
  74. package/dist/dev/locales/{lt-LT-G7RZYQQU.js → lt-LT-CFYYFLDV.js} +56 -2
  75. package/dist/dev/locales/{lt-LT-G7RZYQQU.js.map → lt-LT-CFYYFLDV.js.map} +2 -2
  76. package/dist/dev/locales/{lv-LV-DXNPBJZU.js → lv-LV-QCBBOFFU.js} +57 -3
  77. package/dist/dev/locales/{lv-LV-DXNPBJZU.js.map → lv-LV-QCBBOFFU.js.map} +2 -2
  78. package/dist/dev/locales/{mr-IN-7F2ZCTCF.js → mr-IN-B2CM5GK5.js} +57 -3
  79. package/dist/dev/locales/{mr-IN-7F2ZCTCF.js.map → mr-IN-B2CM5GK5.js.map} +2 -2
  80. package/dist/dev/locales/{my-MM-NBI3KQGW.js → my-MM-756BNN36.js} +56 -2
  81. package/dist/dev/locales/{my-MM-NBI3KQGW.js.map → my-MM-756BNN36.js.map} +2 -2
  82. package/dist/dev/locales/{nb-NO-4DCTQT6L.js → nb-NO-5BLHQI4J.js} +57 -3
  83. package/dist/dev/locales/{nb-NO-4DCTQT6L.js.map → nb-NO-5BLHQI4J.js.map} +2 -2
  84. package/dist/dev/locales/{nl-NL-XGZJ7V2V.js → nl-NL-225BLGAH.js} +58 -4
  85. package/dist/dev/locales/nl-NL-225BLGAH.js.map +7 -0
  86. package/dist/dev/locales/{nn-NO-FR534JV5.js → nn-NO-4J7MR6GH.js} +56 -2
  87. package/dist/dev/locales/{nn-NO-FR534JV5.js.map → nn-NO-4J7MR6GH.js.map} +2 -2
  88. package/dist/dev/locales/{oc-FR-YQCIKZIK.js → oc-FR-XCETH7KF.js} +57 -3
  89. package/dist/dev/locales/{oc-FR-YQCIKZIK.js.map → oc-FR-XCETH7KF.js.map} +2 -2
  90. package/dist/dev/locales/{pa-IN-UM43JGD2.js → pa-IN-32NBAN5L.js} +57 -3
  91. package/dist/dev/locales/{pa-IN-UM43JGD2.js.map → pa-IN-32NBAN5L.js.map} +2 -2
  92. package/dist/dev/locales/{percentages-OGWD7R2K.js → percentages-ZRLRVMSI.js} +2 -2
  93. package/dist/dev/locales/{pl-PL-2UGKA6HK.js → pl-PL-R6OJ54BT.js} +57 -3
  94. package/dist/dev/locales/{pl-PL-2UGKA6HK.js.map → pl-PL-R6OJ54BT.js.map} +2 -2
  95. package/dist/dev/locales/{pt-BR-H23QFYE3.js → pt-BR-7AFGAKGR.js} +57 -3
  96. package/dist/dev/locales/{pt-BR-H23QFYE3.js.map → pt-BR-7AFGAKGR.js.map} +2 -2
  97. package/dist/dev/locales/{pt-PT-RHKJH5I5.js → pt-PT-S6BMW6MY.js} +57 -3
  98. package/dist/dev/locales/{pt-PT-RHKJH5I5.js.map → pt-PT-S6BMW6MY.js.map} +2 -2
  99. package/dist/dev/locales/{ro-RO-IIFONL3T.js → ro-RO-4JVGQHS2.js} +57 -3
  100. package/dist/dev/locales/{ro-RO-IIFONL3T.js.map → ro-RO-4JVGQHS2.js.map} +2 -2
  101. package/dist/dev/locales/{ru-RU-QEP6D7GK.js → ru-RU-IESI752T.js} +59 -5
  102. package/dist/dev/locales/ru-RU-IESI752T.js.map +7 -0
  103. package/dist/dev/locales/{si-LK-LZYJQLHF.js → si-LK-H75E7PKD.js} +57 -3
  104. package/dist/dev/locales/{si-LK-LZYJQLHF.js.map → si-LK-H75E7PKD.js.map} +2 -2
  105. package/dist/dev/locales/{sk-SK-RWC6UWGY.js → sk-SK-EUK2NR2F.js} +57 -3
  106. package/dist/dev/locales/{sk-SK-RWC6UWGY.js.map → sk-SK-EUK2NR2F.js.map} +2 -2
  107. package/dist/dev/locales/{sl-SI-QJT2CAUO.js → sl-SI-AKW7R5PW.js} +57 -3
  108. package/dist/dev/locales/{sl-SI-QJT2CAUO.js.map → sl-SI-AKW7R5PW.js.map} +2 -2
  109. package/dist/dev/locales/{sv-SE-3MAT3NDX.js → sv-SE-QIBOOXLJ.js} +57 -3
  110. package/dist/dev/locales/{sv-SE-3MAT3NDX.js.map → sv-SE-QIBOOXLJ.js.map} +2 -2
  111. package/dist/dev/locales/{ta-IN-J7XOYF2T.js → ta-IN-LBK2NQ5K.js} +56 -2
  112. package/dist/dev/locales/{ta-IN-J7XOYF2T.js.map → ta-IN-LBK2NQ5K.js.map} +2 -2
  113. package/dist/dev/locales/{th-TH-2OI52EOQ.js → th-TH-YJ2E6GVT.js} +56 -2
  114. package/dist/dev/locales/{th-TH-2OI52EOQ.js.map → th-TH-YJ2E6GVT.js.map} +2 -2
  115. package/dist/dev/locales/{tr-TR-G7TAUHUI.js → tr-TR-Y5GO2XJW.js} +57 -3
  116. package/dist/dev/locales/{tr-TR-G7TAUHUI.js.map → tr-TR-Y5GO2XJW.js.map} +2 -2
  117. package/dist/dev/locales/{uk-UA-IVSVBJIG.js → uk-UA-XYAFHHJW.js} +57 -3
  118. package/dist/dev/locales/{uk-UA-IVSVBJIG.js.map → uk-UA-XYAFHHJW.js.map} +2 -2
  119. package/dist/dev/locales/{uz-UZ-KCVDUVDE.js → uz-UZ-LF3CBRYE.js} +56 -2
  120. package/dist/dev/locales/{uz-UZ-KCVDUVDE.js.map → uz-UZ-LF3CBRYE.js.map} +2 -2
  121. package/dist/dev/locales/{vi-VN-KBZAVWP5.js → vi-VN-WDPZEUOJ.js} +56 -2
  122. package/dist/dev/locales/{vi-VN-KBZAVWP5.js.map → vi-VN-WDPZEUOJ.js.map} +2 -2
  123. package/dist/dev/locales/{zh-CN-IS26RG2D.js → zh-CN-SZ37453H.js} +57 -3
  124. package/dist/dev/locales/{zh-CN-IS26RG2D.js.map → zh-CN-SZ37453H.js.map} +2 -2
  125. package/dist/dev/locales/{zh-HK-KBWQ6SJC.js → zh-HK-QDQ5QNBC.js} +56 -2
  126. package/dist/dev/locales/{zh-HK-KBWQ6SJC.js.map → zh-HK-QDQ5QNBC.js.map} +2 -2
  127. package/dist/dev/locales/{zh-TW-JKJWJQ4J.js → zh-TW-CYU6GFBV.js} +57 -3
  128. package/dist/dev/locales/{zh-TW-JKJWJQ4J.js.map → zh-TW-CYU6GFBV.js.map} +2 -2
  129. package/dist/dev/subset-shared.chunk.js +1 -1
  130. package/dist/dev/subset-worker.chunk.js +1 -1
  131. package/dist/prod/chunk-3FGJVPJS.js +12 -0
  132. package/dist/prod/chunk-3PELD44J.js +1 -0
  133. package/dist/prod/chunk-44LLHLSZ.js +4 -0
  134. package/dist/prod/{chunk-SNEYYD2R.js → chunk-KG57QRSG.js} +1 -1
  135. package/dist/prod/data/image-XPYUWCHN.js +1 -0
  136. package/dist/prod/index.css +1 -1
  137. package/dist/prod/index.js +26 -24
  138. package/dist/prod/locales/{ar-SA-EYKRCXR6.js → ar-SA-TS6M4GHP.js} +1 -1
  139. package/dist/prod/locales/{az-AZ-ZNDJBVCS.js → az-AZ-HJWG4CPD.js} +1 -1
  140. package/dist/prod/locales/{bg-BG-O5I6U3AR.js → bg-BG-K42QREUV.js} +1 -1
  141. package/dist/prod/locales/{bn-IN-HPUBVY4I.js → bn-BD-IFEECH4W.js} +1 -1
  142. package/dist/prod/locales/{bn-BD-CXZY522G.js → bn-IN-OE7SKNFR.js} +1 -1
  143. package/dist/prod/locales/{ca-ES-AREX5NEO.js → ca-ES-MKBCGNOG.js} +3 -3
  144. package/dist/prod/locales/{cs-CZ-HXAZMFYH.js → cs-CZ-V77HGUP7.js} +2 -2
  145. package/dist/prod/locales/{da-DK-5X7ZLFU3.js → da-DK-I5RFNTM4.js} +2 -2
  146. package/dist/prod/locales/{de-DE-G3JVZ4MQ.js → de-CH-WLRDEVBV.js} +3 -3
  147. package/dist/prod/locales/{de-CH-76ZNVSOF.js → de-DE-DTI4WUSC.js} +4 -4
  148. package/dist/prod/locales/{el-GR-4AZTZGY6.js → el-GR-ZXDJ2OS4.js} +3 -3
  149. package/dist/prod/locales/en-Y2V7YPBM.js +1 -0
  150. package/dist/prod/locales/{es-ES-ART7BI3G.js → es-ES-DYQHAD43.js} +2 -2
  151. package/dist/prod/locales/{eu-ES-BIF4XBMT.js → eu-ES-QDSYU5Y3.js} +3 -3
  152. package/dist/prod/locales/{fa-IR-D4HHKAAI.js → fa-IR-26LZG4PM.js} +3 -3
  153. package/dist/prod/locales/{fi-FI-O35ZY7UI.js → fi-FI-6YS4KDE4.js} +2 -2
  154. package/dist/prod/locales/{fr-FR-XEFNCM4I.js → fr-FR-BRLLPTZC.js} +2 -2
  155. package/dist/prod/locales/{gl-ES-U4NYM3X5.js → gl-ES-OKUZTLYG.js} +3 -3
  156. package/dist/prod/locales/{he-IL-656ABAVQ.js → he-IL-26MGYIU7.js} +3 -3
  157. package/dist/prod/locales/hi-IN-Q4ZOGTP2.js +3 -0
  158. package/dist/prod/locales/hu-HU-P2OXPSN5.js +3 -0
  159. package/dist/prod/locales/{id-ID-FLZFU3OO.js → id-ID-2EIKXYN6.js} +3 -3
  160. package/dist/prod/locales/{it-IT-GIGIGIBJ.js → it-IT-4CFKVXI2.js} +4 -4
  161. package/dist/prod/locales/{ja-JP-43VXGDWI.js → ja-JP-MAND2Z4V.js} +4 -4
  162. package/dist/prod/locales/{kaa-L3IMSDYL.js → kaa-HQRTCXTJ.js} +1 -1
  163. package/dist/prod/locales/{kab-KAB-XKPWJLNL.js → kab-KAB-JKIKKTGH.js} +2 -2
  164. package/dist/prod/locales/{kk-KZ-SXPDDY2H.js → kk-KZ-HXQ63ZFC.js} +1 -1
  165. package/dist/prod/locales/{km-KH-DOS4CPGC.js → km-KH-PKL3LSGX.js} +3 -3
  166. package/dist/prod/locales/{ko-KR-BGC6VCY4.js → ko-KR-KXLREZX3.js} +2 -2
  167. package/dist/prod/locales/{ku-TR-J7IUITIA.js → ku-TR-MJ4IER3X.js} +3 -3
  168. package/dist/prod/locales/{lt-LT-AC3LV5KG.js → lt-LT-H6WFQ6FJ.js} +2 -2
  169. package/dist/prod/locales/{lv-LV-I6AY7QG2.js → lv-LV-GOCK6SJW.js} +2 -2
  170. package/dist/prod/locales/{mr-IN-5SP4HV5B.js → mr-IN-IXVLDMEQ.js} +2 -2
  171. package/dist/prod/locales/{my-MM-S7ECRBYZ.js → my-MM-YG6MYTTD.js} +1 -1
  172. package/dist/prod/locales/{nb-NO-6PNHTF4R.js → nb-NO-XGWJISD2.js} +3 -3
  173. package/dist/prod/locales/{nl-NL-R4C4SUIG.js → nl-NL-XVDVCPNC.js} +4 -4
  174. package/dist/prod/locales/{nn-NO-3TFXTM7Y.js → nn-NO-EMX5MJX5.js} +2 -2
  175. package/dist/prod/locales/{oc-FR-IK6GIE7H.js → oc-FR-ROEINTVO.js} +2 -2
  176. package/dist/prod/locales/{pa-IN-YAKHYJET.js → pa-IN-ZYN6SUDY.js} +1 -1
  177. package/dist/prod/locales/percentages-5DKR754L.js +1 -0
  178. package/dist/prod/locales/{pl-PL-BIY22ZWU.js → pl-PL-6VTG7PHC.js} +3 -3
  179. package/dist/prod/locales/{pt-BR-Q23NUPD6.js → pt-BR-5YFKRR5G.js} +2 -2
  180. package/dist/prod/locales/{pt-PT-LOPEJLPJ.js → pt-PT-GEIXXZ67.js} +1 -1
  181. package/dist/prod/locales/{ro-RO-W3D2ZATV.js → ro-RO-E2P6TFZI.js} +4 -4
  182. package/dist/prod/locales/{ru-RU-DCTW7QSH.js → ru-RU-YBIIY43T.js} +4 -4
  183. package/dist/prod/locales/{si-LK-FYRRHO3C.js → si-LK-673C2CI2.js} +1 -1
  184. package/dist/prod/locales/{sk-SK-MC7UOHQO.js → sk-SK-CKZHQ4AP.js} +2 -2
  185. package/dist/prod/locales/{sl-SI-L6B6HFY5.js → sl-SI-557H2GWM.js} +2 -2
  186. package/dist/prod/locales/{sv-SE-KMY6L2BA.js → sv-SE-XOPKKDWS.js} +3 -3
  187. package/dist/prod/locales/{ta-IN-ZQCYE2JK.js → ta-IN-XBH7DQI3.js} +3 -3
  188. package/dist/prod/locales/{th-TH-WS7ECBAV.js → th-TH-TOCWH3R4.js} +1 -1
  189. package/dist/prod/locales/{tr-TR-S5FI7JRW.js → tr-TR-GXW6CYY5.js} +2 -2
  190. package/dist/prod/locales/{uk-UA-4EZUWUSQ.js → uk-UA-IJKTNUDG.js} +3 -3
  191. package/dist/prod/locales/{uz-UZ-OKHL6AFA.js → uz-UZ-TBZZEA4V.js} +1 -1
  192. package/dist/prod/locales/{vi-VN-K34TWHF7.js → vi-VN-MULSGNVB.js} +3 -3
  193. package/dist/prod/locales/{zh-CN-JE4UZWNO.js → zh-CN-MVX3E32U.js} +3 -3
  194. package/dist/prod/locales/{zh-HK-RM35YDXX.js → zh-HK-JNU5RLIE.js} +1 -1
  195. package/dist/prod/locales/{zh-TW-ONGLV6Y5.js → zh-TW-LENVCA6T.js} +3 -3
  196. package/dist/prod/subset-shared.chunk.js +1 -1
  197. package/dist/prod/subset-worker.chunk.js +1 -1
  198. package/dist/types/common/debug.d.ts +21 -0
  199. package/dist/types/common/src/appEventBus.d.ts +27 -0
  200. package/dist/types/common/src/colors.d.ts +1 -1
  201. package/dist/types/common/src/constants.d.ts +3 -0
  202. package/dist/types/common/src/index.d.ts +3 -0
  203. package/dist/types/common/src/utils.d.ts +4 -7
  204. package/dist/types/common/src/versionedSnapshotStore.d.ts +17 -0
  205. package/dist/types/element/src/Scene.d.ts +2 -0
  206. package/dist/types/element/src/arrange-algorithms/maxRects.d.ts +16 -0
  207. package/dist/types/element/src/arrowheads.d.ts +3 -0
  208. package/dist/types/element/src/arrows/focus.d.ts +27 -0
  209. package/dist/types/element/src/arrows/helpers.d.ts +5 -0
  210. package/dist/types/element/src/binding.d.ts +13 -8
  211. package/dist/types/element/src/bounds.d.ts +1 -1
  212. package/dist/types/element/src/collision.d.ts +4 -3
  213. package/dist/types/element/src/distribute.d.ts +2 -1
  214. package/dist/types/element/src/elbowArrow.d.ts +2 -0
  215. package/dist/types/element/src/index.d.ts +4 -0
  216. package/dist/types/element/src/linearElementEditor.d.ts +6 -1
  217. package/dist/types/element/src/mutateElement.d.ts +2 -0
  218. package/dist/types/element/src/selection.d.ts +5 -1
  219. package/dist/types/element/src/shapes.d.ts +2 -22
  220. package/dist/types/element/src/textElement.d.ts +1 -1
  221. package/dist/types/element/src/textWrapping.d.ts +26 -0
  222. package/dist/types/element/src/types.d.ts +6 -3
  223. package/dist/types/element/src/utils.d.ts +5 -3
  224. package/dist/types/element/src/zindex.d.ts +1 -1
  225. package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +38 -35
  226. package/dist/types/excalidraw/actions/actionAlign.d.ts +8 -8
  227. package/dist/types/excalidraw/actions/actionArrange.d.ts +2 -2
  228. package/dist/types/excalidraw/actions/actionBoundText.d.ts +27 -25
  229. package/dist/types/excalidraw/actions/actionCanvas.d.ts +159 -148
  230. package/dist/types/excalidraw/actions/actionClipboard.d.ts +28 -26
  231. package/dist/types/excalidraw/actions/actionCropEditor.d.ts +13 -12
  232. package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +43 -38
  233. package/dist/types/excalidraw/actions/actionDistribute.d.ts +4 -4
  234. package/dist/types/excalidraw/actions/actionDuplicateSelection.d.ts +2 -2
  235. package/dist/types/excalidraw/actions/actionElementLink.d.ts +9 -12
  236. package/dist/types/excalidraw/actions/actionElementLock.d.ts +28 -26
  237. package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +13 -12
  238. package/dist/types/excalidraw/actions/actionExport.d.ts +87 -380
  239. package/dist/types/excalidraw/actions/actionFlip.d.ts +4 -4
  240. package/dist/types/excalidraw/actions/actionFrame.d.ts +54 -50
  241. package/dist/types/excalidraw/actions/actionGroup.d.ts +31 -29
  242. package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +15 -12
  243. package/dist/types/excalidraw/actions/actionLink.d.ts +15 -14
  244. package/dist/types/excalidraw/actions/actionMenu.d.ts +11 -14
  245. package/dist/types/excalidraw/actions/actionProperties.d.ts +33 -31
  246. package/dist/types/excalidraw/actions/actionSelectAll.d.ts +16 -15
  247. package/dist/types/excalidraw/actions/actionSmartZoom.d.ts +2 -2
  248. package/dist/types/excalidraw/actions/actionStyles.d.ts +17 -15
  249. package/dist/types/excalidraw/actions/actionTextAutoResize.d.ts +3 -3
  250. package/dist/types/excalidraw/actions/actionToggleArrowBinding.d.ts +181 -0
  251. package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +15 -14
  252. package/dist/types/excalidraw/actions/actionToggleMidpointSnapping.d.ts +181 -0
  253. package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +15 -14
  254. package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +11 -14
  255. package/dist/types/excalidraw/actions/actionToggleStats.d.ts +15 -14
  256. package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +15 -14
  257. package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +15 -14
  258. package/dist/types/excalidraw/actions/actionZindex.d.ts +8 -8
  259. package/dist/types/excalidraw/actions/index.d.ts +2 -0
  260. package/dist/types/excalidraw/actions/shortcuts.d.ts +1 -1
  261. package/dist/types/excalidraw/actions/types.d.ts +1 -1
  262. package/dist/types/excalidraw/appState.d.ts +15 -13
  263. package/dist/types/excalidraw/charts/charts.bar.d.ts +2 -0
  264. package/dist/types/excalidraw/charts/charts.constants.d.ts +48 -0
  265. package/dist/types/excalidraw/charts/charts.helpers.d.ts +32 -0
  266. package/dist/types/excalidraw/charts/charts.line.d.ts +2 -0
  267. package/dist/types/excalidraw/charts/charts.parse.d.ts +10 -0
  268. package/dist/types/excalidraw/charts/charts.radar.d.ts +2 -0
  269. package/dist/types/excalidraw/charts/charts.types.d.ts +18 -0
  270. package/dist/types/excalidraw/charts/index.d.ts +7 -0
  271. package/dist/types/excalidraw/clipboard.d.ts +6 -7
  272. package/dist/types/excalidraw/components/App.d.ts +57 -14
  273. package/dist/types/excalidraw/components/AppStateObserver.d.ts +37 -0
  274. package/dist/types/excalidraw/components/CommandPalette/types.d.ts +1 -1
  275. package/dist/types/excalidraw/components/IconPicker.d.ts +14 -9
  276. package/dist/types/excalidraw/components/PasteChartDialog.d.ts +4 -5
  277. package/dist/types/excalidraw/components/PropertiesPopover.d.ts +1 -1
  278. package/dist/types/excalidraw/components/Range.d.ts +10 -4
  279. package/dist/types/excalidraw/components/Toast.d.ts +8 -4
  280. package/dist/types/excalidraw/components/canvases/InteractiveCanvas.d.ts +1 -0
  281. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenu.d.ts +30 -17
  282. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuContent.d.ts +3 -2
  283. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItem.d.ts +11 -13
  284. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuItemCheckbox.d.ts +5 -0
  285. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSub.d.ts +23 -0
  286. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubContent.d.ts +8 -0
  287. package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuSubTrigger.d.ts +12 -0
  288. package/dist/types/excalidraw/components/dropdownMenu/common.d.ts +1 -1
  289. package/dist/types/excalidraw/components/dropdownMenu/dropdownMenuUtils.d.ts +2 -0
  290. package/dist/types/excalidraw/components/icons.d.ts +23 -9
  291. package/dist/types/excalidraw/components/main-menu/DefaultItems.d.ts +17 -0
  292. package/dist/types/excalidraw/components/main-menu/MainMenu.d.ts +23 -13
  293. package/dist/types/excalidraw/components/shapes.d.ts +263 -0
  294. package/dist/types/excalidraw/data/blob.d.ts +57 -56
  295. package/dist/types/excalidraw/data/filesystem.d.ts +3 -5
  296. package/dist/types/excalidraw/data/index.d.ts +2 -3
  297. package/dist/types/excalidraw/data/json.d.ts +43 -34
  298. package/dist/types/excalidraw/data/resave.d.ts +7 -2
  299. package/dist/types/excalidraw/editorPreferences.d.ts +11 -0
  300. package/dist/types/excalidraw/hooks/useAppStateValue.d.ts +29 -0
  301. package/dist/types/excalidraw/index.d.ts +26 -3
  302. package/dist/types/excalidraw/textAutoResizeHandle.d.ts +15 -0
  303. package/dist/types/excalidraw/types.d.ts +114 -16
  304. package/dist/types/excalidraw/wysiwyg/textWysiwyg.d.ts +5 -1
  305. package/dist/types/math/src/point.d.ts +7 -2
  306. package/dist/types/math/src/types.d.ts +25 -1
  307. package/package.json +8 -8
  308. package/dist/dev/chunk-DJHLEOOZ.js +0 -69
  309. package/dist/dev/chunk-DJHLEOOZ.js.map +0 -7
  310. package/dist/dev/chunk-WBVI4CIR.js.map +0 -7
  311. package/dist/dev/chunk-WGIZZ2NT.js.map +0 -7
  312. package/dist/dev/locales/de-CH-OAWPDQFJ.js.map +0 -7
  313. package/dist/dev/locales/hi-IN-XGMO235V.js.map +0 -7
  314. package/dist/dev/locales/hu-HU-37FDQFIS.js.map +0 -7
  315. package/dist/dev/locales/nl-NL-XGZJ7V2V.js.map +0 -7
  316. package/dist/dev/locales/ru-RU-QEP6D7GK.js.map +0 -7
  317. package/dist/prod/chunk-AJI3LATG.js +0 -1
  318. package/dist/prod/chunk-P4DO2K62.js +0 -4
  319. package/dist/prod/chunk-SXXYW6U7.js +0 -12
  320. package/dist/prod/data/image-P7BXXOZA.js +0 -1
  321. package/dist/prod/locales/en-IT7EQLWB.js +0 -1
  322. package/dist/prod/locales/hi-IN-Z55GAFFR.js +0 -3
  323. package/dist/prod/locales/hu-HU-UJ62DVIW.js +0 -3
  324. package/dist/prod/locales/percentages-OL6W367U.js +0 -1
  325. package/dist/types/excalidraw/charts.d.ts +0 -27
  326. /package/dist/dev/{chunk-ERXRO4IP.js.map → chunk-OF725VHI.js.map} +0 -0
  327. /package/dist/dev/data/{image-BOZX7YCK.js.map → image-ZR5DXOGS.js.map} +0 -0
  328. /package/dist/dev/locales/{en-GV3XLAUG.js.map → en-I7VEBYIX.js.map} +0 -0
  329. /package/dist/dev/locales/{percentages-OGWD7R2K.js.map → percentages-ZRLRVMSI.js.map} +0 -0
@@ -2,12 +2,11 @@ import { IMAGE_MIME_TYPES, MIME_TYPES } from "@excalidraw/common";
2
2
  import type { ValueOf } from "@excalidraw/common/utility-types";
3
3
  import type { ExcalidrawElement, FileId } from "@excalidraw/element/types";
4
4
  import type { AppState, DataURL, LibraryItem } from "../types";
5
- import type { FileSystemHandle } from "browser-fs-access";
6
5
  import type { ImportedLibraryData } from "./types";
7
6
  export declare const getMimeType: (blob: Blob | string) => string;
8
- export declare const getFileHandleType: (handle: FileSystemHandle | null) => string | null;
7
+ export declare const getFileHandleType: (handle: FileSystemFileHandle | null) => string | null;
9
8
  export declare const isImageFileHandleType: (type: string | null) => type is "png" | "svg";
10
- export declare const isImageFileHandle: (handle: FileSystemHandle | null) => boolean;
9
+ export declare const isImageFileHandle: (handle: FileSystemFileHandle | null) => handle is FileSystemFileHandle;
11
10
  export declare const isSupportedImageFileType: (type: string | null | undefined) => boolean;
12
11
  export declare const isSupportedImageFile: (blob: Blob | null | undefined) => blob is Blob & {
13
12
  type: ValueOf<typeof IMAGE_MIME_TYPES>;
@@ -15,8 +14,8 @@ export declare const isSupportedImageFile: (blob: Blob | null | undefined) => bl
15
14
  export declare const loadSceneOrLibraryFromBlob: (blob: Blob | File,
16
15
  /** @see restore.localAppState */
17
16
  localAppState: AppState | null, localElements: readonly ExcalidrawElement[] | null,
18
- /** FileSystemHandle. Defaults to `blob.handle` if defined, otherwise null. */
19
- fileHandle?: FileSystemHandle | null) => Promise<{
17
+ /** FileSystemFileHandle. Defaults to `blob.handle` if defined, otherwise null. */
18
+ fileHandle?: FileSystemFileHandle | null) => Promise<{
20
19
  type: "application/vnd.excalidraw+json";
21
20
  data: {
22
21
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
@@ -43,12 +42,21 @@ fileHandle?: FileSystemHandle | null) => Promise<{
43
42
  } | {
44
43
  name: "elementLinkSelector";
45
44
  sourceElementId: ExcalidrawElement["id"];
45
+ } | {
46
+ name: "charts";
47
+ data: import("../charts").Spreadsheet;
48
+ rawText: string;
46
49
  };
47
50
  editingGroupId: import("@excalidraw/element/types").GroupId | null;
48
51
  selectedElementIds: Readonly<{
49
52
  [id: string]: true;
50
53
  }>;
51
54
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
55
+ activeTool: {
56
+ lastActiveTool: import("../types").ActiveTool | null;
57
+ locked: boolean;
58
+ fromSelection: boolean;
59
+ } & import("../types").ActiveTool;
52
60
  activeEmbeddable: {
53
61
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
54
62
  state: "hover" | "active";
@@ -61,13 +69,17 @@ fileHandle?: FileSystemHandle | null) => Promise<{
61
69
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
62
70
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
63
71
  isBindingEnabled: boolean;
64
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
72
+ isMidpointSnappingEnabled: boolean;
73
+ suggestedBinding: {
74
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
75
+ midPoint?: import("@excalidraw/math").GlobalPoint;
76
+ } | null;
65
77
  isRotating: boolean;
66
78
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
67
79
  collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
68
80
  snapLines: readonly import("../snapping").SnapLine[];
69
81
  zenModeEnabled: boolean;
70
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
82
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
71
83
  isCropping: boolean;
72
84
  croppingElementId: ExcalidrawElement["id"] | null;
73
85
  searchMatches: Readonly<{
@@ -80,8 +92,15 @@ fileHandle?: FileSystemHandle | null) => Promise<{
80
92
  }>;
81
93
  shouldCacheIgnoreZoom: boolean;
82
94
  exportScale: number;
95
+ currentItemArrowType: "sharp" | "round" | "elbow";
83
96
  bindMode: import("@excalidraw/element/types").BindMode;
84
97
  gridSize: number;
98
+ gridModeEnabled: boolean;
99
+ objectsSnapModeEnabled: boolean;
100
+ wheelZoomsOnDefault?: boolean | undefined;
101
+ selectedElementsAreBeingDragged: boolean;
102
+ gridStep: number;
103
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
85
104
  contextMenu: {
86
105
  items: import("../components/ContextMenu").ContextMenuItems;
87
106
  top: number;
@@ -92,7 +111,6 @@ fileHandle?: FileSystemHandle | null) => Promise<{
92
111
  myocSimplifiedMode: boolean;
93
112
  dontResizeLimitMBs: number;
94
113
  hideMainMenus: boolean;
95
- wheelZoomsOnDefault?: boolean | undefined;
96
114
  arrangeConfiguration: {
97
115
  algorithm: import("@excalidraw/element/types").ArrangeAlgorithms;
98
116
  gap: number;
@@ -103,13 +121,9 @@ fileHandle?: FileSystemHandle | null) => Promise<{
103
121
  };
104
122
  errorMessage: React.ReactNode;
105
123
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
124
+ bindingPreference: "enabled" | "disabled";
106
125
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
107
126
  editingFrame: string | null;
108
- activeTool: {
109
- lastActiveTool: import("../types").ActiveTool | null;
110
- locked: boolean;
111
- fromSelection: boolean;
112
- } & import("../types").ActiveTool;
113
127
  preferredSelectionTool: {
114
128
  type: "selection" | "lasso";
115
129
  initialized: boolean;
@@ -131,9 +145,7 @@ fileHandle?: FileSystemHandle | null) => Promise<{
131
145
  currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
132
146
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
133
147
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
134
- currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
135
148
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
136
- currentItemArrowType: "sharp" | "round" | "elbow";
137
149
  cursorButton: "up" | "down";
138
150
  scrolledOutside: boolean;
139
151
  isResizing: boolean;
@@ -148,33 +160,21 @@ fileHandle?: FileSystemHandle | null) => Promise<{
148
160
  previousSelectedElementIds: {
149
161
  [id: string]: true;
150
162
  };
151
- selectedElementsAreBeingDragged: boolean;
152
163
  toast: {
153
- message: string;
164
+ message: React.ReactNode;
154
165
  closable?: boolean;
155
166
  duration?: number;
156
167
  } | null;
157
- gridStep: number;
158
- gridModeEnabled: boolean;
159
- fileHandle: FileSystemHandle | null;
168
+ fileHandle: FileSystemFileHandle | null;
160
169
  stats: {
161
170
  open: boolean;
162
171
  panels: number;
163
172
  };
164
- currentChartType: import("@excalidraw/element/types").ChartType;
165
- pasteDialog: {
166
- shown: false;
167
- data: null;
168
- } | {
169
- shown: true;
170
- data: import("../charts").Spreadsheet;
171
- };
172
173
  showHyperlinkPopup: false | "info" | "editor";
173
174
  originSnapOffset: {
174
175
  x: number;
175
176
  y: number;
176
177
  } | null;
177
- objectsSnapModeEnabled: boolean;
178
178
  userToFollow: import("../types").UserToFollow | null;
179
179
  followedBy: Set<import("../types").SocketId>;
180
180
  lockedMultiSelections: {
@@ -190,8 +190,8 @@ fileHandle?: FileSystemHandle | null) => Promise<{
190
190
  export declare const loadFromBlob: (blob: Blob,
191
191
  /** @see restore.localAppState */
192
192
  localAppState: AppState | null, localElements: readonly ExcalidrawElement[] | null,
193
- /** FileSystemHandle. Defaults to `blob.handle` if defined, otherwise null. */
194
- fileHandle?: FileSystemHandle | null) => Promise<{
193
+ /** FileSystemFileHandle. Defaults to `blob.handle` if defined, otherwise null. */
194
+ fileHandle?: FileSystemFileHandle | null) => Promise<{
195
195
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
196
196
  appState: {
197
197
  viewBackgroundColor: string;
@@ -216,12 +216,21 @@ fileHandle?: FileSystemHandle | null) => Promise<{
216
216
  } | {
217
217
  name: "elementLinkSelector";
218
218
  sourceElementId: ExcalidrawElement["id"];
219
+ } | {
220
+ name: "charts";
221
+ data: import("../charts").Spreadsheet;
222
+ rawText: string;
219
223
  };
220
224
  editingGroupId: import("@excalidraw/element/types").GroupId | null;
221
225
  selectedElementIds: Readonly<{
222
226
  [id: string]: true;
223
227
  }>;
224
228
  frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
229
+ activeTool: {
230
+ lastActiveTool: import("../types").ActiveTool | null;
231
+ locked: boolean;
232
+ fromSelection: boolean;
233
+ } & import("../types").ActiveTool;
225
234
  activeEmbeddable: {
226
235
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
227
236
  state: "hover" | "active";
@@ -234,13 +243,17 @@ fileHandle?: FileSystemHandle | null) => Promise<{
234
243
  multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
235
244
  newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
236
245
  isBindingEnabled: boolean;
237
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
246
+ isMidpointSnappingEnabled: boolean;
247
+ suggestedBinding: {
248
+ element: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
249
+ midPoint?: import("@excalidraw/math").GlobalPoint;
250
+ } | null;
238
251
  isRotating: boolean;
239
252
  elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
240
253
  collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
241
254
  snapLines: readonly import("../snapping").SnapLine[];
242
255
  zenModeEnabled: boolean;
243
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
256
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
244
257
  isCropping: boolean;
245
258
  croppingElementId: ExcalidrawElement["id"] | null;
246
259
  searchMatches: Readonly<{
@@ -253,8 +266,15 @@ fileHandle?: FileSystemHandle | null) => Promise<{
253
266
  }>;
254
267
  shouldCacheIgnoreZoom: boolean;
255
268
  exportScale: number;
269
+ currentItemArrowType: "sharp" | "round" | "elbow";
256
270
  bindMode: import("@excalidraw/element/types").BindMode;
257
271
  gridSize: number;
272
+ gridModeEnabled: boolean;
273
+ objectsSnapModeEnabled: boolean;
274
+ wheelZoomsOnDefault?: boolean | undefined;
275
+ selectedElementsAreBeingDragged: boolean;
276
+ gridStep: number;
277
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
258
278
  contextMenu: {
259
279
  items: import("../components/ContextMenu").ContextMenuItems;
260
280
  top: number;
@@ -265,7 +285,6 @@ fileHandle?: FileSystemHandle | null) => Promise<{
265
285
  myocSimplifiedMode: boolean;
266
286
  dontResizeLimitMBs: number;
267
287
  hideMainMenus: boolean;
268
- wheelZoomsOnDefault?: boolean | undefined;
269
288
  arrangeConfiguration: {
270
289
  algorithm: import("@excalidraw/element/types").ArrangeAlgorithms;
271
290
  gap: number;
@@ -276,13 +295,9 @@ fileHandle?: FileSystemHandle | null) => Promise<{
276
295
  };
277
296
  errorMessage: React.ReactNode;
278
297
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
298
+ bindingPreference: "enabled" | "disabled";
279
299
  startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
280
300
  editingFrame: string | null;
281
- activeTool: {
282
- lastActiveTool: import("../types").ActiveTool | null;
283
- locked: boolean;
284
- fromSelection: boolean;
285
- } & import("../types").ActiveTool;
286
301
  preferredSelectionTool: {
287
302
  type: "selection" | "lasso";
288
303
  initialized: boolean;
@@ -304,9 +319,7 @@ fileHandle?: FileSystemHandle | null) => Promise<{
304
319
  currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
305
320
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
306
321
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
307
- currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
308
322
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
309
- currentItemArrowType: "sharp" | "round" | "elbow";
310
323
  cursorButton: "up" | "down";
311
324
  scrolledOutside: boolean;
312
325
  isResizing: boolean;
@@ -321,33 +334,21 @@ fileHandle?: FileSystemHandle | null) => Promise<{
321
334
  previousSelectedElementIds: {
322
335
  [id: string]: true;
323
336
  };
324
- selectedElementsAreBeingDragged: boolean;
325
337
  toast: {
326
- message: string;
338
+ message: React.ReactNode;
327
339
  closable?: boolean;
328
340
  duration?: number;
329
341
  } | null;
330
- gridStep: number;
331
- gridModeEnabled: boolean;
332
- fileHandle: FileSystemHandle | null;
342
+ fileHandle: FileSystemFileHandle | null;
333
343
  stats: {
334
344
  open: boolean;
335
345
  panels: number;
336
346
  };
337
- currentChartType: import("@excalidraw/element/types").ChartType;
338
- pasteDialog: {
339
- shown: false;
340
- data: null;
341
- } | {
342
- shown: true;
343
- data: import("../charts").Spreadsheet;
344
- };
345
347
  showHyperlinkPopup: false | "info" | "editor";
346
348
  originSnapOffset: {
347
349
  x: number;
348
350
  y: number;
349
351
  } | null;
350
- objectsSnapModeEnabled: boolean;
351
352
  userToFollow: import("../types").UserToFollow | null;
352
353
  followedBy: Set<import("../types").SocketId>;
353
354
  lockedMultiSelections: {
@@ -376,7 +377,7 @@ export declare const SVGStringToFile: (SVGString: string, filename?: string) =>
376
377
  type: typeof MIME_TYPES.svg;
377
378
  };
378
379
  export declare const ImageURLToFile: (imageUrl: string, filename?: string) => Promise<File | undefined>;
379
- export declare const getFileHandle: (event: DragEvent | React.DragEvent | DataTransferItem) => Promise<FileSystemHandle | null>;
380
+ export declare const getFileHandle: (event: DragEvent | React.DragEvent | DataTransferItem) => Promise<FileSystemFileHandle | null>;
380
381
  export declare const createFile: (blob: File | Blob | ArrayBuffer, mimeType: string, name: string | undefined) => File;
381
382
  /** attempts to detect correct mimeType if none is set, or if an image
382
383
  * has an incorrect extension.
@@ -1,6 +1,5 @@
1
1
  import { supported as nativeFileSystemSupported } from "browser-fs-access";
2
2
  import { MIME_TYPES } from "@excalidraw/common";
3
- import type { FileSystemHandle } from "browser-fs-access";
4
3
  type FILE_EXTENSION = Exclude<keyof typeof MIME_TYPES, "binary">;
5
4
  export declare const fileOpen: <M extends boolean | undefined = false>(opts: {
6
5
  extensions?: FILE_EXTENSION[];
@@ -14,8 +13,7 @@ export declare const fileSave: (blob: Blob | Promise<Blob>, opts: {
14
13
  extension: FILE_EXTENSION;
15
14
  mimeTypes?: string[];
16
15
  description: string;
17
- /** existing FileSystemHandle */
18
- fileHandle?: FileSystemHandle | null;
19
- }) => Promise<FileSystemHandle | null>;
16
+ /** existing FileSystemFileHandle */
17
+ fileHandle?: FileSystemFileHandle | null;
18
+ }) => Promise<FileSystemFileHandle | null>;
20
19
  export { nativeFileSystemSupported };
21
- export type { FileSystemHandle };
@@ -1,5 +1,4 @@
1
1
  import type { ExcalidrawElement, ExcalidrawFrameLikeElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
2
- import type { FileSystemHandle } from "./filesystem";
3
2
  import type { ExportType } from "../scene/types";
4
3
  import type { AppState, BinaryFiles } from "../types";
5
4
  export { loadFromBlob } from "./blob";
@@ -17,6 +16,6 @@ export declare const exportCanvas: (type: Omit<ExportType, "backend">, elements:
17
16
  viewBackgroundColor: string;
18
17
  /** filename, if applicable */
19
18
  name?: string;
20
- fileHandle?: FileSystemHandle | null;
19
+ fileHandle?: FileSystemFileHandle | null;
21
20
  exportingFrame: ExcalidrawFrameLikeElement | null;
22
- }) => Promise<FileSystemHandle | null | undefined>;
21
+ }) => Promise<FileSystemFileHandle | null | undefined>;
@@ -1,11 +1,19 @@
1
- import type { ExcalidrawElement } from "@excalidraw/element/types";
1
+ import type { ExcalidrawElement, NonDeleted } from "@excalidraw/element/types";
2
+ import type { MaybePromise } from "@excalidraw/common/utility-types";
2
3
  import type { AppState, BinaryFiles, LibraryItems } from "../types";
3
4
  import type { ImportedDataState, ImportedLibraryData } from "./types";
5
+ export type JSONExportData = {
6
+ elements: readonly NonDeleted<ExcalidrawElement>[];
7
+ appState: AppState;
8
+ files: BinaryFiles;
9
+ };
4
10
  export declare const serializeAsJSON: (elements: readonly ExcalidrawElement[], appState: Partial<AppState>, files: BinaryFiles, type: "local" | "database") => string;
5
- export declare const saveAsJSON: (elements: readonly ExcalidrawElement[], appState: AppState, files: BinaryFiles,
6
- /** filename */
7
- name?: string) => Promise<{
8
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
11
+ export declare const saveAsJSON: ({ data, filename, fileHandle, }: {
12
+ data: MaybePromise<JSONExportData>;
13
+ filename: string;
14
+ fileHandle: AppState["fileHandle"];
15
+ }) => Promise<{
16
+ fileHandle: FileSystemFileHandle | null;
9
17
  }>;
10
18
  export declare const loadFromJSON: (localAppState: AppState, localElements: readonly ExcalidrawElement[] | null) => Promise<{
11
19
  elements: import("@excalidraw/element/types").OrderedExcalidrawElement[];
@@ -32,12 +40,21 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
32
40
  } | {
33
41
  name: "elementLinkSelector";
34
42
  sourceElementId: ExcalidrawElement["id"];
43
+ } | {
44
+ name: "charts";
45
+ data: import("../charts").Spreadsheet;
46
+ rawText: string;
35
47
  };
36
48
  editingGroupId: import("@excalidraw/element/types").GroupId | null;
37
49
  selectedElementIds: Readonly<{
38
50
  [id: string]: true;
39
51
  }>;
40
- frameToHighlight: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
52
+ frameToHighlight: NonDeleted<import("@excalidraw/element/types").ExcalidrawFrameLikeElement> | null;
53
+ activeTool: {
54
+ lastActiveTool: import("../types").ActiveTool | null;
55
+ locked: boolean;
56
+ fromSelection: boolean;
57
+ } & import("../types").ActiveTool;
41
58
  activeEmbeddable: {
42
59
  element: import("@excalidraw/element/types").NonDeletedExcalidrawElement;
43
60
  state: "hover" | "active";
@@ -47,16 +64,20 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
47
64
  [groupId: string]: boolean;
48
65
  };
49
66
  selectedLinearElement: import("@excalidraw/element").LinearElementEditor | null;
50
- multiElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
51
- newElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
67
+ multiElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawLinearElement> | null;
68
+ newElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawNonSelectionElement> | null;
52
69
  isBindingEnabled: boolean;
53
- suggestedBinding: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
70
+ isMidpointSnappingEnabled: boolean;
71
+ suggestedBinding: {
72
+ element: NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement>;
73
+ midPoint?: import("@excalidraw/math").GlobalPoint;
74
+ } | null;
54
75
  isRotating: boolean;
55
- elementsToHighlight: import("@excalidraw/element/types").NonDeleted<ExcalidrawElement>[] | null;
76
+ elementsToHighlight: NonDeleted<ExcalidrawElement>[] | null;
56
77
  collaborators: Map<import("../types").SocketId, import("../types").Collaborator>;
57
78
  snapLines: readonly import("../snapping").SnapLine[];
58
79
  zenModeEnabled: boolean;
59
- editingTextElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
80
+ editingTextElement: import("@excalidraw/element/types").ExcalidrawTextElement | null;
60
81
  isCropping: boolean;
61
82
  croppingElementId: ExcalidrawElement["id"] | null;
62
83
  searchMatches: Readonly<{
@@ -69,8 +90,15 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
69
90
  }>;
70
91
  shouldCacheIgnoreZoom: boolean;
71
92
  exportScale: number;
93
+ currentItemArrowType: "sharp" | "round" | "elbow";
72
94
  bindMode: import("@excalidraw/element/types").BindMode;
73
95
  gridSize: number;
96
+ gridModeEnabled: boolean;
97
+ objectsSnapModeEnabled: boolean;
98
+ wheelZoomsOnDefault?: boolean | undefined;
99
+ selectedElementsAreBeingDragged: boolean;
100
+ gridStep: number;
101
+ currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
74
102
  contextMenu: {
75
103
  items: import("../components/ContextMenu").ContextMenuItems;
76
104
  top: number;
@@ -81,7 +109,6 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
81
109
  myocSimplifiedMode: boolean;
82
110
  dontResizeLimitMBs: number;
83
111
  hideMainMenus: boolean;
84
- wheelZoomsOnDefault?: boolean | undefined;
85
112
  arrangeConfiguration: {
86
113
  algorithm: import("@excalidraw/element/types").ArrangeAlgorithms;
87
114
  gap: number;
@@ -92,13 +119,9 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
92
119
  };
93
120
  errorMessage: React.ReactNode;
94
121
  resizingElement: import("@excalidraw/element/types").NonDeletedExcalidrawElement | null;
95
- startBoundElement: import("@excalidraw/element/types").NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
122
+ bindingPreference: "enabled" | "disabled";
123
+ startBoundElement: NonDeleted<import("@excalidraw/element/types").ExcalidrawBindableElement> | null;
96
124
  editingFrame: string | null;
97
- activeTool: {
98
- lastActiveTool: import("../types").ActiveTool | null;
99
- locked: boolean;
100
- fromSelection: boolean;
101
- } & import("../types").ActiveTool;
102
125
  preferredSelectionTool: {
103
126
  type: "selection" | "lasso";
104
127
  initialized: boolean;
@@ -120,9 +143,7 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
120
143
  currentItemTextAlign: import("@excalidraw/element/types").TextAlign;
121
144
  currentItemStartArrowhead: import("@excalidraw/element/types").Arrowhead | null;
122
145
  currentItemEndArrowhead: import("@excalidraw/element/types").Arrowhead | null;
123
- currentHoveredFontFamily: import("@excalidraw/element/types").FontFamilyValues | null;
124
146
  currentItemRoundness: import("@excalidraw/element/types").StrokeRoundness;
125
- currentItemArrowType: "sharp" | "round" | "elbow";
126
147
  cursorButton: "up" | "down";
127
148
  scrolledOutside: boolean;
128
149
  isResizing: boolean;
@@ -137,33 +158,21 @@ export declare const loadFromJSON: (localAppState: AppState, localElements: read
137
158
  previousSelectedElementIds: {
138
159
  [id: string]: true;
139
160
  };
140
- selectedElementsAreBeingDragged: boolean;
141
161
  toast: {
142
- message: string;
162
+ message: React.ReactNode;
143
163
  closable?: boolean;
144
164
  duration?: number;
145
165
  } | null;
146
- gridStep: number;
147
- gridModeEnabled: boolean;
148
- fileHandle: import("browser-fs-access").FileSystemHandle | null;
166
+ fileHandle: FileSystemFileHandle | null;
149
167
  stats: {
150
168
  open: boolean;
151
169
  panels: number;
152
170
  };
153
- currentChartType: import("@excalidraw/element/types").ChartType;
154
- pasteDialog: {
155
- shown: false;
156
- data: null;
157
- } | {
158
- shown: true;
159
- data: import("../charts").Spreadsheet;
160
- };
161
171
  showHyperlinkPopup: false | "info" | "editor";
162
172
  originSnapOffset: {
163
173
  x: number;
164
174
  y: number;
165
175
  } | null;
166
- objectsSnapModeEnabled: boolean;
167
176
  userToFollow: import("../types").UserToFollow | null;
168
177
  followedBy: Set<import("../types").SocketId>;
169
178
  lockedMultiSelections: {
@@ -1,5 +1,10 @@
1
+ import type { MaybePromise } from "@excalidraw/common/utility-types";
1
2
  import type { ExcalidrawElement } from "@excalidraw/element/types";
2
3
  import type { AppState, BinaryFiles } from "../types";
3
- export declare const resaveAsImageWithScene: (elements: readonly ExcalidrawElement[], appState: AppState, files: BinaryFiles, name: string) => Promise<{
4
- fileHandle: import("browser-fs-access").FileSystemHandle;
4
+ export declare const resaveAsImageWithScene: (data: MaybePromise<{
5
+ elements: readonly ExcalidrawElement[];
6
+ appState: AppState;
7
+ files: BinaryFiles;
8
+ }>, fileHandle: FileSystemFileHandle, filename: string) => Promise<{
9
+ fileHandle: FileSystemFileHandle;
5
10
  }>;
@@ -0,0 +1,11 @@
1
+ import type { AppState, ArrangePreferences, EditorPreferences, NormalisePreferences, SmartZoomPreferences } from "./types";
2
+ export type ResolvedSmartZoomPreferences = Required<SmartZoomPreferences>;
3
+ export type ResolvedArrangePreferences = Required<ArrangePreferences>;
4
+ export type ResolvedNormalisePreferences = Required<NormalisePreferences>;
5
+ export type ResolvedEditorPreferences = {
6
+ smartZoom: ResolvedSmartZoomPreferences;
7
+ arrange: ResolvedArrangePreferences;
8
+ normalise: ResolvedNormalisePreferences;
9
+ };
10
+ export declare const DEFAULT_SMART_ZOOM_PREFERENCES: ResolvedSmartZoomPreferences;
11
+ export declare const getEffectiveEditorPreferences: (appState: Readonly<Pick<AppState, "arrangeConfiguration" | "normaliseConfiguration">>, editorPreferences?: EditorPreferences) => ResolvedEditorPreferences;
@@ -0,0 +1,29 @@
1
+ import type { AppState } from "../types";
2
+ /**
3
+ * Subscribes to specific appState changes. The component re-renders
4
+ * only when the specified prop(s) change — not on every appState update.
5
+ *
6
+ * Works both inside and outside the <Excalidraw> tree, as long as
7
+ * ExcalidrawAPIContext.Provider is an ancestor (automatically provided
8
+ * inside <Excalidraw>, or manually by the host app).
9
+ *
10
+ * Returns the narrowed value depending on prop form:
11
+ * - `keyof AppState` → `AppState[K]`
12
+ * - `(keyof AppState)[]` → whole `AppState`
13
+ * - selector function → selector's return type `T`
14
+ *
15
+ * If excalidrawAPI is not ready yet (host apps), hook is rerendered with latest
16
+ * value once available.
17
+ */
18
+ export declare function useAppStateValue<K extends keyof AppState>(prop: K, _internal?: boolean): AppState[K];
19
+ export declare function useAppStateValue(props: (keyof AppState)[], _internal?: boolean): AppState;
20
+ export declare function useAppStateValue<T>(selector: (appState: AppState) => T, _internal?: boolean): T;
21
+ /**
22
+ * Subscribes to specific appState changes without causing component rerenders.
23
+ *
24
+ * The callback is called on every matching change, but also on initial render
25
+ * so you can initialize your state.
26
+ */
27
+ export declare function useOnAppStateChange<K extends keyof AppState>(prop: K, callback: (value: AppState[K], appState: AppState) => void): undefined;
28
+ export declare function useOnAppStateChange(props: (keyof AppState)[], callback: (props: AppState, appState: AppState) => void): undefined;
29
+ export declare function useOnAppStateChange<T>(selector: (appState: AppState) => T, callback: (value: T, appState: AppState) => void): undefined;
@@ -3,10 +3,19 @@ import Footer from "./components/footer/FooterCenter";
3
3
  import LiveCollaborationTrigger from "./components/live-collaboration/LiveCollaborationTrigger";
4
4
  import MainMenu from "./components/main-menu/MainMenu";
5
5
  import WelcomeScreen from "./components/welcome-screen/WelcomeScreen";
6
+ import { useOnAppStateChange as _useOnAppStateChange } from "./hooks/useAppStateValue";
6
7
  import "./css/app.scss";
7
8
  import "./css/styles.scss";
8
9
  import "./fonts/fonts.css";
9
- import type { ExcalidrawProps } from "./types";
10
+ import type { AppState, ExcalidrawProps } from "./types";
11
+ /**
12
+ * Stateless provider that allows `useExcalidrawAPI()` (and hooks built
13
+ * on it, such as `useAppStateValue()` and `useOnAppStateChange()`) to work
14
+ * outside the <Excalidraw> component tree.
15
+ */
16
+ export declare const ExcalidrawAPIProvider: ({ children, }: {
17
+ children: React.ReactNode;
18
+ }) => import("react/jsx-runtime").JSX.Element;
10
19
  export declare const Excalidraw: React.MemoExoticComponent<(props: ExcalidrawProps) => import("react/jsx-runtime").JSX.Element>;
11
20
  export { getSceneVersion, hashElementsVersion, hashString, getNonDeletedElements, } from "@excalidraw/element";
12
21
  export { getTextFromElements } from "@excalidraw/element";
@@ -19,7 +28,7 @@ export { serializeAsJSON, serializeLibraryAsJSON } from "./data/json";
19
28
  export { loadFromBlob, loadSceneOrLibraryFromBlob, loadLibraryFromBlob, } from "./data/blob";
20
29
  export { mergeLibraryItems, getLibraryItemsHash } from "./data/library";
21
30
  export { isLinearElement } from "@excalidraw/element";
22
- export { FONT_FAMILY, THEME, MIME_TYPES, ROUNDNESS, DEFAULT_LASER_COLOR, UserIdleState, normalizeLink, sceneCoordsToViewportCoords, viewportCoordsToSceneCoords, getFormFactor, } from "@excalidraw/common";
31
+ export { FONT_FAMILY, THEME, MIME_TYPES, ROUNDNESS, DEFAULT_LASER_COLOR, UserIdleState, normalizeLink, sceneCoordsToViewportCoords, viewportCoordsToSceneCoords, getFormFactor, throttleRAF, } from "@excalidraw/common";
23
32
  export { mutateElement, newElementWith, bumpVersion, } from "@excalidraw/element";
24
33
  export { CaptureUpdateAction } from "@excalidraw/element";
25
34
  export { parseLibraryTokensFromUrl, useHandleLibrary } from "./data/library";
@@ -28,7 +37,7 @@ export { Button } from "./components/Button";
28
37
  export { Footer };
29
38
  export { MainMenu };
30
39
  export { Ellipsify } from "./components/Ellipsify";
31
- export { useEditorInterface, useStylesPanelMode } from "./components/App";
40
+ export { useEditorInterface, useStylesPanelMode, useExcalidrawAPI, ExcalidrawAPIContext, } from "./components/App";
32
41
  export { WelcomeScreen };
33
42
  export { LiveCollaborationTrigger };
34
43
  export { Stats } from "./components/Stats";
@@ -39,4 +48,18 @@ export { elementsOverlappingBBox, isElementInsideBBox, elementPartiallyOverlapsW
39
48
  export { DiagramToCodePlugin } from "./components/DiagramToCodePlugin/DiagramToCodePlugin";
40
49
  export { getDataURL } from "./data/blob";
41
50
  export { isElementLink } from "@excalidraw/element";
51
+ export { Fonts } from "./fonts/Fonts";
42
52
  export { setCustomTextMetricsProvider } from "@excalidraw/element";
53
+ export { CommandPalette } from "./components/CommandPalette/CommandPalette";
54
+ export type { ArrangePreferences, EditorPreferences, NormalisePreferences, SmartZoomPreferences, } from "./types";
55
+ export { renderSpreadsheet, tryParseSpreadsheet, isSpreadsheetValidForChartType, } from "./charts";
56
+ /**
57
+ * hook that subscribes to specific appState prop(s)
58
+ *
59
+ * @param prop - appState prop(s) to subscribe to, or a selector function.
60
+ * NOTE `prop/selector` is memoized and will not change after initial render
61
+ */
62
+ export declare function useExcalidrawStateValue<K extends keyof AppState>(prop: K): AppState[K] | undefined;
63
+ export declare function useExcalidrawStateValue<T extends keyof AppState>(props: T[]): AppState | undefined;
64
+ export declare function useExcalidrawStateValue<T>(selector: (appState: AppState) => T): T | undefined;
65
+ export { _useOnAppStateChange as useOnExcalidrawStateChange };
@@ -0,0 +1,15 @@
1
+ import { type GlobalPoint } from "@excalidraw/math";
2
+ import type { EditorInterface } from "@excalidraw/common";
3
+ import type { ExcalidrawTextElement } from "@excalidraw/element/types";
4
+ export declare const getTextBoxPadding: (zoomValue: number) => number;
5
+ export declare const getTextAutoResizeHandle: (textElement: ExcalidrawTextElement, zoomValue: number, formFactor: EditorInterface["formFactor"]) => {
6
+ center: GlobalPoint | import("@excalidraw/math").LocalPoint;
7
+ start: GlobalPoint;
8
+ end: GlobalPoint;
9
+ hitboxWidth: number;
10
+ hitboxHeight: number;
11
+ } | null;
12
+ export declare const isPointHittingTextAutoResizeHandle: (point: Readonly<{
13
+ x: number;
14
+ y: number;
15
+ }>, textElement: ExcalidrawTextElement, zoomValue: number, formFactor: EditorInterface["formFactor"]) => boolean;