@excalidraw/excalidraw 0.18.0-b7aac689a → 0.18.0-c141960
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.
- package/dist/dev/{chunk-QF5FRM6O.js → chunk-AWYOLLYX.js} +49 -26
- package/dist/dev/chunk-AWYOLLYX.js.map +7 -0
- package/dist/dev/chunk-PMQWN2AA.js +69 -0
- package/dist/dev/chunk-PMQWN2AA.js.map +7 -0
- package/dist/dev/{chunk-CBGOW5JB.js → chunk-SJTAY27F.js} +185 -389
- package/dist/dev/chunk-SJTAY27F.js.map +7 -0
- package/dist/dev/data/{image-SURZSZNX.js → image-S2GFZH7W.js} +2 -2
- package/dist/dev/index.css +944 -498
- package/dist/dev/index.css.map +3 -3
- package/dist/dev/index.js +10424 -7221
- package/dist/dev/index.js.map +4 -4
- package/dist/dev/locales/{ar-SA-XORAP2EK.js → ar-SA-USQAA427.js} +299 -142
- package/dist/dev/locales/ar-SA-USQAA427.js.map +7 -0
- package/dist/dev/locales/{az-AZ-NAUU3Z4Y.js → az-AZ-CVQRXULV.js} +240 -83
- package/dist/dev/locales/az-AZ-CVQRXULV.js.map +7 -0
- package/dist/dev/locales/{bg-BG-AAABLFCY.js → bg-BG-E4I2JVOQ.js} +228 -71
- package/dist/dev/locales/bg-BG-E4I2JVOQ.js.map +7 -0
- package/dist/dev/locales/{bn-BD-PM4AC5WG.js → bn-BD-O55ROP2R.js} +208 -51
- package/dist/dev/locales/bn-BD-O55ROP2R.js.map +7 -0
- package/dist/dev/locales/bn-IN-OL7OUKTP.js +743 -0
- package/dist/dev/locales/bn-IN-OL7OUKTP.js.map +7 -0
- package/dist/dev/locales/{ca-ES-YNNMFRQX.js → ca-ES-73KY52DM.js} +274 -117
- package/dist/dev/locales/ca-ES-73KY52DM.js.map +7 -0
- package/dist/dev/locales/{cs-CZ-DGZA5IKG.js → cs-CZ-2YGHPQ24.js} +228 -71
- package/dist/dev/locales/cs-CZ-2YGHPQ24.js.map +7 -0
- package/dist/dev/locales/{da-DK-N76F4QAJ.js → da-DK-OEIZIPJU.js} +297 -140
- package/dist/dev/locales/da-DK-OEIZIPJU.js.map +7 -0
- package/dist/dev/locales/de-CH-4GJTW23D.js +743 -0
- package/dist/dev/locales/de-CH-4GJTW23D.js.map +7 -0
- package/dist/dev/locales/{de-DE-DMRXZ2SZ.js → de-DE-YRH6WMM5.js} +198 -41
- package/dist/dev/locales/de-DE-YRH6WMM5.js.map +7 -0
- package/dist/dev/locales/{el-GR-HIKPLEXI.js → el-GR-W7S64QNM.js} +273 -116
- package/dist/dev/locales/el-GR-W7S64QNM.js.map +7 -0
- package/dist/dev/locales/{en-SMAPCEOQ.js → en-ZO6QSABV.js} +4 -2
- package/dist/dev/locales/{es-ES-AQYVXC32.js → es-ES-7JEN5PTZ.js} +211 -54
- package/dist/dev/locales/es-ES-7JEN5PTZ.js.map +7 -0
- package/dist/dev/locales/{eu-ES-3TOEU5DE.js → eu-ES-HQNHU6VR.js} +209 -52
- package/dist/dev/locales/eu-ES-HQNHU6VR.js.map +7 -0
- package/dist/dev/locales/{fa-IR-527GAKUP.js → fa-IR-IN6XOPA6.js} +285 -128
- package/dist/dev/locales/fa-IR-IN6XOPA6.js.map +7 -0
- package/dist/dev/locales/{fi-FI-M3WLVDFP.js → fi-FI-5BAAYJDZ.js} +239 -82
- package/dist/dev/locales/fi-FI-5BAAYJDZ.js.map +7 -0
- package/dist/dev/locales/{fr-FR-YE4VDJFI.js → fr-FR-KCXBY2R4.js} +202 -45
- package/dist/dev/locales/fr-FR-KCXBY2R4.js.map +7 -0
- package/dist/dev/locales/{gl-ES-KMXUYGUN.js → gl-ES-5OPGWS6N.js} +211 -54
- package/dist/dev/locales/gl-ES-5OPGWS6N.js.map +7 -0
- package/dist/dev/locales/he-IL-3A6ZWK6L.js +743 -0
- package/dist/dev/locales/he-IL-3A6ZWK6L.js.map +7 -0
- package/dist/dev/locales/hi-IN-HZTBH6EG.js +743 -0
- package/dist/dev/locales/hi-IN-HZTBH6EG.js.map +7 -0
- package/dist/dev/locales/{hu-HU-VIYZI3X4.js → hu-HU-52IRZEAZ.js} +237 -80
- package/dist/dev/locales/hu-HU-52IRZEAZ.js.map +7 -0
- package/dist/dev/locales/{id-ID-22TWZNLA.js → id-ID-W6HBGXTS.js} +244 -87
- package/dist/dev/locales/id-ID-W6HBGXTS.js.map +7 -0
- package/dist/dev/locales/{it-IT-MDEQ2SG3.js → it-IT-AV75ICYT.js} +201 -44
- package/dist/dev/locales/it-IT-AV75ICYT.js.map +7 -0
- package/dist/dev/locales/{ja-JP-K2DI4W6B.js → ja-JP-SS4G3ZXF.js} +246 -89
- package/dist/dev/locales/ja-JP-SS4G3ZXF.js.map +7 -0
- package/dist/dev/locales/{kaa-6BPSNM3R.js → kaa-Y5BBB3IW.js} +201 -44
- package/dist/dev/locales/kaa-Y5BBB3IW.js.map +7 -0
- package/dist/dev/locales/{kab-KAB-2S7ZURK7.js → kab-KAB-KDVZQXBT.js} +209 -52
- package/dist/dev/locales/kab-KAB-KDVZQXBT.js.map +7 -0
- package/dist/dev/locales/{kk-KZ-UJPYGRQQ.js → kk-KZ-762YODLJ.js} +174 -17
- package/dist/dev/locales/kk-KZ-762YODLJ.js.map +7 -0
- package/dist/dev/locales/{km-KH-M5T5JKUE.js → km-KH-K2TE5MIK.js} +197 -40
- package/dist/dev/locales/km-KH-K2TE5MIK.js.map +7 -0
- package/dist/dev/locales/{ko-KR-RQX37SNF.js → ko-KR-75RUMBCO.js} +217 -60
- package/dist/dev/locales/ko-KR-75RUMBCO.js.map +7 -0
- package/dist/dev/locales/{ku-TR-5XJDIERL.js → ku-TR-E6DJ6LYM.js} +197 -40
- package/dist/dev/locales/ku-TR-E6DJ6LYM.js.map +7 -0
- package/dist/dev/locales/{lt-LT-MGUBX6CA.js → lt-LT-BYS5DA45.js} +178 -21
- package/dist/dev/locales/lt-LT-BYS5DA45.js.map +7 -0
- package/dist/dev/locales/{lv-LV-MD7N5VHD.js → lv-LV-SPQ2VWX3.js} +195 -38
- package/dist/dev/locales/lv-LV-SPQ2VWX3.js.map +7 -0
- package/dist/dev/locales/{mr-IN-4XWMNGQC.js → mr-IN-2HLK6LUA.js} +203 -46
- package/dist/dev/locales/mr-IN-2HLK6LUA.js.map +7 -0
- package/dist/dev/locales/{my-MM-O4Z74GN5.js → my-MM-P2LR44WR.js} +180 -23
- package/dist/dev/locales/my-MM-P2LR44WR.js.map +7 -0
- package/dist/dev/locales/{nb-NO-BMB73KRH.js → nb-NO-7YZHFFVS.js} +219 -62
- package/dist/dev/locales/nb-NO-7YZHFFVS.js.map +7 -0
- package/dist/dev/locales/{nl-NL-F2257BLQ.js → nl-NL-TF2OVIKN.js} +217 -60
- package/dist/dev/locales/nl-NL-TF2OVIKN.js.map +7 -0
- package/dist/dev/locales/{nn-NO-NCORG7TS.js → nn-NO-2BWEL2IS.js} +200 -43
- package/dist/dev/locales/nn-NO-2BWEL2IS.js.map +7 -0
- package/dist/dev/locales/{oc-FR-ATFBDMF6.js → oc-FR-5JYIFGLE.js} +212 -55
- package/dist/dev/locales/oc-FR-5JYIFGLE.js.map +7 -0
- package/dist/dev/locales/{pa-IN-D2I375G4.js → pa-IN-KBBGER76.js} +189 -32
- package/dist/dev/locales/pa-IN-KBBGER76.js.map +7 -0
- package/dist/dev/locales/{percentages-YKFLWNK2.js → percentages-2RAYDWNS.js} +2 -2
- package/dist/dev/locales/{pl-PL-YJHOWAAW.js → pl-PL-BWZ2X734.js} +213 -56
- package/dist/dev/locales/pl-PL-BWZ2X734.js.map +7 -0
- package/dist/dev/locales/{pt-BR-APOPYZJ7.js → pt-BR-ERVIQI63.js} +236 -79
- package/dist/dev/locales/pt-BR-ERVIQI63.js.map +7 -0
- package/dist/dev/locales/pt-PT-ZNJ5NB5S.js +743 -0
- package/dist/dev/locales/pt-PT-ZNJ5NB5S.js.map +7 -0
- package/dist/dev/locales/{ro-RO-L575VRQA.js → ro-RO-UYNXGUB7.js} +202 -45
- package/dist/dev/locales/ro-RO-UYNXGUB7.js.map +7 -0
- package/dist/dev/locales/{ru-RU-BLG6HZG5.js → ru-RU-F7LPIMGQ.js} +252 -95
- package/dist/dev/locales/ru-RU-F7LPIMGQ.js.map +7 -0
- package/dist/dev/locales/si-LK-5GF2DJUH.js +743 -0
- package/dist/dev/locales/si-LK-5GF2DJUH.js.map +7 -0
- package/dist/dev/locales/{sk-SK-DY6IPO5U.js → sk-SK-H6WE7IJX.js} +199 -42
- package/dist/dev/locales/sk-SK-H6WE7IJX.js.map +7 -0
- package/dist/dev/locales/{sl-SI-5DZSRA47.js → sl-SI-4PJ6LBI7.js} +196 -39
- package/dist/dev/locales/sl-SI-4PJ6LBI7.js.map +7 -0
- package/dist/dev/locales/{sv-SE-V32YHALQ.js → sv-SE-E5VQLCRE.js} +201 -44
- package/dist/dev/locales/sv-SE-E5VQLCRE.js.map +7 -0
- package/dist/dev/locales/{ta-IN-5JRAGQAO.js → ta-IN-2YWIVLKF.js} +256 -99
- package/dist/dev/locales/ta-IN-2YWIVLKF.js.map +7 -0
- package/dist/dev/locales/{th-TH-55ACRHDJ.js → th-TH-IV7RUTDK.js} +288 -131
- package/dist/dev/locales/th-TH-IV7RUTDK.js.map +7 -0
- package/dist/dev/locales/{tr-TR-7QYBXDBO.js → tr-TR-LEQWIQH7.js} +256 -99
- package/dist/dev/locales/tr-TR-LEQWIQH7.js.map +7 -0
- package/dist/dev/locales/{uk-UA-TJS2TMRH.js → uk-UA-DWVOQPTB.js} +228 -71
- package/dist/dev/locales/uk-UA-DWVOQPTB.js.map +7 -0
- package/dist/dev/locales/{si-LK-KT7GGO6D.js → uz-UZ-CKXQ3QKG.js} +211 -54
- package/dist/dev/locales/uz-UZ-CKXQ3QKG.js.map +7 -0
- package/dist/dev/locales/vi-VN-3P6DZOGS.js +743 -0
- package/dist/dev/locales/vi-VN-3P6DZOGS.js.map +7 -0
- package/dist/dev/locales/{zh-CN-4MXUOFTH.js → zh-CN-XXVG53TQ.js} +198 -41
- package/dist/dev/locales/zh-CN-XXVG53TQ.js.map +7 -0
- package/dist/dev/locales/{zh-HK-RBTGIU3U.js → zh-HK-JCHGKEUE.js} +174 -17
- package/dist/dev/locales/zh-HK-JCHGKEUE.js.map +7 -0
- package/dist/dev/locales/{zh-TW-U5VF4CCU.js → zh-TW-ARVT7RZU.js} +203 -46
- package/dist/dev/locales/zh-TW-ARVT7RZU.js.map +7 -0
- package/dist/prod/chunk-KRJFZ5JQ.js +1 -0
- package/dist/prod/chunk-N7QNUCIG.js +12 -0
- package/dist/prod/chunk-XJNFOLHK.js +4 -0
- package/dist/prod/data/{image-HXEZYJPQ.js → image-SMWA6JLH.js} +1 -1
- package/dist/prod/index.css +1 -1
- package/dist/prod/index.js +23 -23
- package/dist/prod/locales/ar-SA-F62BVQMB.js +8 -0
- package/dist/prod/locales/az-AZ-7PGSKYOB.js +1 -0
- package/dist/prod/locales/bg-BG-AAEXMUQ4.js +5 -0
- package/dist/prod/locales/bn-BD-ONOFQYIQ.js +3 -0
- package/dist/prod/locales/bn-IN-YT3I2M3F.js +3 -0
- package/dist/prod/locales/ca-ES-GG4YH2FN.js +8 -0
- package/dist/prod/locales/cs-CZ-IS5VTBOP.js +7 -0
- package/dist/prod/locales/da-DK-VPQ2KWAY.js +2 -0
- package/dist/prod/locales/de-CH-G4Y2G6IS.js +7 -0
- package/dist/prod/locales/de-DE-RAT2LIDI.js +7 -0
- package/dist/prod/locales/el-GR-DNJB2AZO.js +7 -0
- package/dist/prod/locales/en-FOCNVEEU.js +1 -0
- package/dist/prod/locales/es-ES-IMTENLBU.js +7 -0
- package/dist/prod/locales/eu-ES-XLOS36YS.js +7 -0
- package/dist/prod/locales/fa-IR-J6Z2YOGX.js +9 -0
- package/dist/prod/locales/fi-FI-B2IQ7SBP.js +6 -0
- package/dist/prod/locales/fr-FR-N5BRDCMI.js +12 -0
- package/dist/prod/locales/gl-ES-BOYALFRN.js +6 -0
- package/dist/prod/locales/he-IL-H7M7HGY5.js +8 -0
- package/dist/prod/locales/hi-IN-7AB5CA2Q.js +3 -0
- package/dist/prod/locales/hu-HU-ZZM7UJLP.js +3 -0
- package/dist/prod/locales/id-ID-RZ7JNCXA.js +8 -0
- package/dist/prod/locales/it-IT-ZX7HN56D.js +8 -0
- package/dist/prod/locales/ja-JP-NBNBUHIR.js +7 -0
- package/dist/prod/locales/kaa-QWYSGEM7.js +1 -0
- package/dist/prod/locales/kab-KAB-Q3HBKQ5I.js +4 -0
- package/dist/prod/locales/kk-KZ-HF2NTCRX.js +1 -0
- package/dist/prod/locales/km-KH-CN6HHF5U.js +7 -0
- package/dist/prod/locales/ko-KR-SJQMUXM7.js +5 -0
- package/dist/prod/locales/ku-TR-VM4BHTPC.js +6 -0
- package/dist/prod/locales/lt-LT-QIWZQ7AG.js +3 -0
- package/dist/prod/locales/lv-LV-YQFCB4WZ.js +4 -0
- package/dist/prod/locales/mr-IN-GR2ZJPSQ.js +9 -0
- package/dist/prod/locales/my-MM-M5XJDJQ2.js +1 -0
- package/dist/prod/locales/nb-NO-2RU2YF7H.js +8 -0
- package/dist/prod/locales/nl-NL-MUHXDQFK.js +7 -0
- package/dist/prod/locales/nn-NO-72RCA552.js +4 -0
- package/dist/prod/locales/oc-FR-65ITQYQ2.js +4 -0
- package/dist/prod/locales/pa-IN-WESENMFH.js +4 -0
- package/dist/prod/locales/percentages-OEPNEGCM.js +1 -0
- package/dist/prod/locales/pl-PL-7C4NGVUA.js +12 -0
- package/dist/prod/locales/pt-BR-QH23C2IX.js +6 -0
- package/dist/prod/locales/pt-PT-O5XBATXI.js +8 -0
- package/dist/prod/locales/ro-RO-QHCHEGM5.js +12 -0
- package/dist/prod/locales/ru-RU-FUMQ2LLB.js +6 -0
- package/dist/prod/locales/si-LK-JYUINGNN.js +1 -0
- package/dist/prod/locales/sk-SK-R25O52BS.js +7 -0
- package/dist/prod/locales/sl-SI-5KPVX4FS.js +6 -0
- package/dist/prod/locales/sv-SE-MVMXV6O4.js +8 -0
- package/dist/prod/locales/ta-IN-A32FQB4D.js +6 -0
- package/dist/prod/locales/th-TH-CXMWNVBY.js +1 -0
- package/dist/prod/locales/tr-TR-YHFI3W2D.js +4 -0
- package/dist/prod/locales/uk-UA-UTJIIKT5.js +6 -0
- package/dist/prod/locales/uz-UZ-H4EGTR7D.js +1 -0
- package/dist/prod/locales/vi-VN-XBV2ESZM.js +7 -0
- package/dist/prod/locales/zh-CN-CKCJ4HAO.js +11 -0
- package/dist/prod/locales/zh-HK-ISASRRMF.js +1 -0
- package/dist/prod/locales/zh-TW-KYRW5V3R.js +9 -0
- package/dist/types/common/src/constants.d.ts +21 -15
- package/dist/types/common/src/editorInterface.d.ts +34 -0
- package/dist/types/common/src/index.d.ts +2 -0
- package/dist/types/common/src/utils.d.ts +9 -3
- package/dist/types/common/src/visualdebug.d.ts +41 -0
- package/dist/types/element/src/Scene.d.ts +6 -2
- package/dist/types/element/src/align.d.ts +2 -1
- package/dist/types/element/src/binding.d.ts +55 -43
- package/dist/types/element/src/bounds.d.ts +1 -1
- package/dist/types/element/src/collision.d.ts +6 -2
- package/dist/types/element/src/delta.d.ts +16 -4
- package/dist/types/element/src/distribute.d.ts +2 -1
- package/dist/types/element/src/groups.d.ts +1 -0
- package/dist/types/element/src/index.d.ts +1 -3
- package/dist/types/element/src/linearElementEditor.d.ts +17 -19
- package/dist/types/element/src/positionElementsOnGrid.d.ts +2 -0
- package/dist/types/element/src/renderElement.d.ts +5 -2
- package/dist/types/element/src/resizeTest.d.ts +5 -4
- package/dist/types/element/src/store.d.ts +6 -1
- package/dist/types/element/src/textElement.d.ts +1 -1
- package/dist/types/element/src/transformHandles.d.ts +5 -4
- package/dist/types/element/src/typeChecks.d.ts +2 -3
- package/dist/types/element/src/types.d.ts +7 -11
- package/dist/types/element/src/utils.d.ts +2 -1
- package/dist/types/element/src/zindex.d.ts +7 -1
- package/dist/types/excalidraw/actions/actionAddToLibrary.d.ts +34 -16
- package/dist/types/excalidraw/actions/actionAlign.d.ts +6 -6
- package/dist/types/excalidraw/actions/actionBoundText.d.ts +25 -13
- package/dist/types/excalidraw/actions/actionCanvas.d.ts +153 -275
- package/dist/types/excalidraw/actions/actionClipboard.d.ts +45 -777
- package/dist/types/excalidraw/actions/actionCropEditor.d.ts +12 -6
- package/dist/types/excalidraw/actions/actionDeleteSelected.d.ts +45 -29
- package/dist/types/excalidraw/actions/actionDistribute.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionDuplicateSelection.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionElementLink.d.ts +11 -7
- package/dist/types/excalidraw/actions/actionElementLock.d.ts +23 -11
- package/dist/types/excalidraw/actions/actionEmbeddable.d.ts +12 -6
- package/dist/types/excalidraw/actions/actionExport.d.ts +68 -952
- package/dist/types/excalidraw/actions/actionFinalize.d.ts +10 -394
- package/dist/types/excalidraw/actions/actionFlip.d.ts +2 -2
- package/dist/types/excalidraw/actions/actionFrame.d.ts +50 -28
- package/dist/types/excalidraw/actions/actionGroup.d.ts +24 -12
- package/dist/types/excalidraw/actions/actionLinearEditor.d.ts +47 -14
- package/dist/types/excalidraw/actions/actionLink.d.ts +9 -3
- package/dist/types/excalidraw/actions/actionMenu.d.ts +10 -374
- package/dist/types/excalidraw/actions/actionNavigate.d.ts +21 -361
- package/dist/types/excalidraw/actions/actionProperties.d.ts +87 -2418
- package/dist/types/excalidraw/actions/actionSelectAll.d.ts +12 -6
- package/dist/types/excalidraw/actions/actionStyles.d.ts +13 -7
- package/dist/types/excalidraw/actions/actionTextAutoResize.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleGridMode.d.ts +11 -5
- package/dist/types/excalidraw/actions/actionToggleObjectsSnapMode.d.ts +11 -5
- package/dist/types/excalidraw/actions/actionToggleSearchMenu.d.ts +10 -6
- package/dist/types/excalidraw/actions/actionToggleShapeSwitch.d.ts +1 -1
- package/dist/types/excalidraw/actions/actionToggleStats.d.ts +11 -5
- package/dist/types/excalidraw/actions/actionToggleViewMode.d.ts +11 -5
- package/dist/types/excalidraw/actions/actionToggleZenMode.d.ts +12 -6
- package/dist/types/excalidraw/actions/actionZindex.d.ts +2 -2
- package/dist/types/excalidraw/actions/index.d.ts +2 -2
- package/dist/types/excalidraw/actions/manager.d.ts +1 -1
- package/dist/types/excalidraw/actions/register.d.ts +1 -1
- package/dist/types/excalidraw/actions/types.d.ts +4 -4
- package/dist/types/excalidraw/appState.d.ts +9 -4
- package/dist/types/excalidraw/clipboard.d.ts +64 -1
- package/dist/types/excalidraw/components/Actions.d.ts +20 -7
- package/dist/types/excalidraw/components/App.d.ts +35 -25
- package/dist/types/excalidraw/components/ColorPicker/Picker.d.ts +2 -0
- package/dist/types/excalidraw/components/ColorPicker/PickerColorList.d.ts +2 -1
- package/dist/types/excalidraw/components/ColorPicker/ShadeList.d.ts +2 -1
- package/dist/types/excalidraw/components/CommandPalette/CommandPalette.d.ts +1 -0
- package/dist/types/excalidraw/components/CommandPalette/types.d.ts +1 -2
- package/dist/types/excalidraw/components/Ellipsify.d.ts +4 -0
- package/dist/types/excalidraw/components/ExcalidrawLogo.d.ts +1 -1
- package/dist/types/excalidraw/components/FilledButton.d.ts +1 -1
- package/dist/types/excalidraw/components/FontPicker/FontPicker.d.ts +2 -1
- package/dist/types/excalidraw/components/FontPicker/FontPickerTrigger.d.ts +3 -1
- package/dist/types/excalidraw/components/HintViewer.d.ts +4 -3
- package/dist/types/excalidraw/components/InlineIcon.d.ts +3 -1
- package/dist/types/excalidraw/components/LayerUI.d.ts +2 -1
- package/dist/types/excalidraw/components/LibraryMenuSection.d.ts +1 -1
- package/dist/types/excalidraw/components/LinkButton.d.ts +4 -0
- package/dist/types/excalidraw/components/MobileMenu.d.ts +3 -5
- package/dist/types/excalidraw/components/MobileToolBar.d.ts +11 -0
- package/dist/types/excalidraw/components/Popover.d.ts +2 -1
- package/dist/types/excalidraw/components/PropertiesPopover.d.ts +1 -0
- package/dist/types/excalidraw/components/Stats/utils.d.ts +1 -1
- package/dist/types/excalidraw/components/TTDDialog/TTDDialogTrigger.d.ts +1 -2
- package/dist/types/excalidraw/components/TextField.d.ts +1 -0
- package/dist/types/excalidraw/components/ToolPopover.d.ts +25 -0
- package/dist/types/excalidraw/components/canvases/InteractiveCanvas.d.ts +6 -3
- package/dist/types/excalidraw/components/dropdownMenu/DropdownMenu.d.ts +4 -2
- package/dist/types/excalidraw/components/dropdownMenu/DropdownMenuContent.d.ts +2 -1
- package/dist/types/excalidraw/components/icons.d.ts +10 -0
- package/dist/types/excalidraw/components/live-collaboration/LiveCollaborationTrigger.d.ts +13 -1
- package/dist/types/excalidraw/components/main-menu/MainMenu.d.ts +0 -3
- package/dist/types/excalidraw/components/shapes.d.ts +129 -1
- package/dist/types/excalidraw/data/blob.d.ts +3 -7
- package/dist/types/excalidraw/data/reconcile.d.ts +1 -0
- package/dist/types/excalidraw/data/restore.d.ts +7 -2
- package/dist/types/excalidraw/data/types.d.ts +4 -1
- package/dist/types/excalidraw/hooks/useLibraryItemSvg.d.ts +1 -1
- package/dist/types/excalidraw/hooks/useOutsideClick.d.ts +3 -1
- package/dist/types/excalidraw/hooks/useTextEditorFocus.d.ts +14 -0
- package/dist/types/excalidraw/index.d.ts +4 -4
- package/dist/types/excalidraw/renderer/animation.d.ts +12 -0
- package/dist/types/excalidraw/renderer/helpers.d.ts +1 -5
- package/dist/types/excalidraw/renderer/interactiveScene.d.ts +5 -13
- package/dist/types/excalidraw/renderer/staticScene.d.ts +4 -1
- package/dist/types/excalidraw/scene/types.d.ts +15 -3
- package/dist/types/excalidraw/shortcut.d.ts +1 -0
- package/dist/types/excalidraw/types.d.ts +37 -24
- package/dist/types/math/src/segment.d.ts +1 -0
- package/history.ts +1 -1
- package/package.json +6 -6
- package/dist/dev/chunk-CBGOW5JB.js.map +0 -7
- package/dist/dev/chunk-MFAYKRVR.js +0 -66
- package/dist/dev/chunk-MFAYKRVR.js.map +0 -7
- package/dist/dev/chunk-QF5FRM6O.js.map +0 -7
- package/dist/dev/locales/ar-SA-XORAP2EK.js.map +0 -7
- package/dist/dev/locales/az-AZ-NAUU3Z4Y.js.map +0 -7
- package/dist/dev/locales/bg-BG-AAABLFCY.js.map +0 -7
- package/dist/dev/locales/bn-BD-PM4AC5WG.js.map +0 -7
- package/dist/dev/locales/ca-ES-YNNMFRQX.js.map +0 -7
- package/dist/dev/locales/cs-CZ-DGZA5IKG.js.map +0 -7
- package/dist/dev/locales/da-DK-N76F4QAJ.js.map +0 -7
- package/dist/dev/locales/de-DE-DMRXZ2SZ.js.map +0 -7
- package/dist/dev/locales/el-GR-HIKPLEXI.js.map +0 -7
- package/dist/dev/locales/es-ES-AQYVXC32.js.map +0 -7
- package/dist/dev/locales/eu-ES-3TOEU5DE.js.map +0 -7
- package/dist/dev/locales/fa-IR-527GAKUP.js.map +0 -7
- package/dist/dev/locales/fi-FI-M3WLVDFP.js.map +0 -7
- package/dist/dev/locales/fr-FR-YE4VDJFI.js.map +0 -7
- package/dist/dev/locales/gl-ES-KMXUYGUN.js.map +0 -7
- package/dist/dev/locales/he-IL-4MU5N22B.js +0 -586
- package/dist/dev/locales/he-IL-4MU5N22B.js.map +0 -7
- package/dist/dev/locales/hi-IN-ZHZNZWFC.js +0 -586
- package/dist/dev/locales/hi-IN-ZHZNZWFC.js.map +0 -7
- package/dist/dev/locales/hu-HU-VIYZI3X4.js.map +0 -7
- package/dist/dev/locales/id-ID-22TWZNLA.js.map +0 -7
- package/dist/dev/locales/it-IT-MDEQ2SG3.js.map +0 -7
- package/dist/dev/locales/ja-JP-K2DI4W6B.js.map +0 -7
- package/dist/dev/locales/kaa-6BPSNM3R.js.map +0 -7
- package/dist/dev/locales/kab-KAB-2S7ZURK7.js.map +0 -7
- package/dist/dev/locales/kk-KZ-UJPYGRQQ.js.map +0 -7
- package/dist/dev/locales/km-KH-M5T5JKUE.js.map +0 -7
- package/dist/dev/locales/ko-KR-RQX37SNF.js.map +0 -7
- package/dist/dev/locales/ku-TR-5XJDIERL.js.map +0 -7
- package/dist/dev/locales/lt-LT-MGUBX6CA.js.map +0 -7
- package/dist/dev/locales/lv-LV-MD7N5VHD.js.map +0 -7
- package/dist/dev/locales/mr-IN-4XWMNGQC.js.map +0 -7
- package/dist/dev/locales/my-MM-O4Z74GN5.js.map +0 -7
- package/dist/dev/locales/nb-NO-BMB73KRH.js.map +0 -7
- package/dist/dev/locales/nl-NL-F2257BLQ.js.map +0 -7
- package/dist/dev/locales/nn-NO-NCORG7TS.js.map +0 -7
- package/dist/dev/locales/oc-FR-ATFBDMF6.js.map +0 -7
- package/dist/dev/locales/pa-IN-D2I375G4.js.map +0 -7
- package/dist/dev/locales/pl-PL-YJHOWAAW.js.map +0 -7
- package/dist/dev/locales/pt-BR-APOPYZJ7.js.map +0 -7
- package/dist/dev/locales/pt-PT-W56WCN7P.js +0 -586
- package/dist/dev/locales/pt-PT-W56WCN7P.js.map +0 -7
- package/dist/dev/locales/ro-RO-L575VRQA.js.map +0 -7
- package/dist/dev/locales/ru-RU-BLG6HZG5.js.map +0 -7
- package/dist/dev/locales/si-LK-KT7GGO6D.js.map +0 -7
- package/dist/dev/locales/sk-SK-DY6IPO5U.js.map +0 -7
- package/dist/dev/locales/sl-SI-5DZSRA47.js.map +0 -7
- package/dist/dev/locales/sv-SE-V32YHALQ.js.map +0 -7
- package/dist/dev/locales/ta-IN-5JRAGQAO.js.map +0 -7
- package/dist/dev/locales/th-TH-55ACRHDJ.js.map +0 -7
- package/dist/dev/locales/tr-TR-7QYBXDBO.js.map +0 -7
- package/dist/dev/locales/uk-UA-TJS2TMRH.js.map +0 -7
- package/dist/dev/locales/vi-VN-Y5CQ2EKQ.js +0 -586
- package/dist/dev/locales/vi-VN-Y5CQ2EKQ.js.map +0 -7
- package/dist/dev/locales/zh-CN-4MXUOFTH.js.map +0 -7
- package/dist/dev/locales/zh-HK-RBTGIU3U.js.map +0 -7
- package/dist/dev/locales/zh-TW-U5VF4CCU.js.map +0 -7
- package/dist/prod/chunk-I4UNSFV6.js +0 -12
- package/dist/prod/chunk-IRHK23LL.js +0 -4
- package/dist/prod/chunk-Z3N5DIM6.js +0 -1
- package/dist/prod/locales/ar-SA-G6X2FPQ2.js +0 -10
- package/dist/prod/locales/az-AZ-76LH7QW2.js +0 -1
- package/dist/prod/locales/bg-BG-XCXSNQG7.js +0 -5
- package/dist/prod/locales/bn-BD-2XOGV67Q.js +0 -5
- package/dist/prod/locales/ca-ES-6MX7JW3Y.js +0 -8
- package/dist/prod/locales/cs-CZ-2BRQDIVT.js +0 -11
- package/dist/prod/locales/da-DK-5WZEPLOC.js +0 -5
- package/dist/prod/locales/de-DE-XR44H4JA.js +0 -8
- package/dist/prod/locales/el-GR-BZB4AONW.js +0 -10
- package/dist/prod/locales/en-TYY6KWIJ.js +0 -1
- package/dist/prod/locales/es-ES-U4NZUMDT.js +0 -9
- package/dist/prod/locales/eu-ES-A7QVB2H4.js +0 -11
- package/dist/prod/locales/fa-IR-HGAKTJCU.js +0 -8
- package/dist/prod/locales/fi-FI-Z5N7JZ37.js +0 -6
- package/dist/prod/locales/fr-FR-RHASNOE6.js +0 -9
- package/dist/prod/locales/gl-ES-HMX3MZ6V.js +0 -10
- package/dist/prod/locales/he-IL-6SHJWFNN.js +0 -10
- package/dist/prod/locales/hi-IN-IWLTKZ5I.js +0 -4
- package/dist/prod/locales/hu-HU-A5ZG7DT2.js +0 -7
- package/dist/prod/locales/id-ID-SAP4L64H.js +0 -10
- package/dist/prod/locales/it-IT-JPQ66NNP.js +0 -11
- package/dist/prod/locales/ja-JP-DBVTYXUO.js +0 -8
- package/dist/prod/locales/kaa-6HZHGXH3.js +0 -1
- package/dist/prod/locales/kab-KAB-ZGHBKWFO.js +0 -8
- package/dist/prod/locales/kk-KZ-P5N5QNE5.js +0 -1
- package/dist/prod/locales/km-KH-HSX4SM5Z.js +0 -11
- package/dist/prod/locales/ko-KR-MTYHY66A.js +0 -9
- package/dist/prod/locales/ku-TR-6OUDTVRD.js +0 -9
- package/dist/prod/locales/lt-LT-XHIRWOB4.js +0 -3
- package/dist/prod/locales/lv-LV-5QDEKY6T.js +0 -7
- package/dist/prod/locales/mr-IN-CRQNXWMA.js +0 -13
- package/dist/prod/locales/my-MM-5M5IBNSE.js +0 -1
- package/dist/prod/locales/nb-NO-T6EIAALU.js +0 -10
- package/dist/prod/locales/nl-NL-IS3SIHDZ.js +0 -8
- package/dist/prod/locales/nn-NO-6E72VCQL.js +0 -8
- package/dist/prod/locales/oc-FR-POXYY2M6.js +0 -8
- package/dist/prod/locales/pa-IN-N4M65BXN.js +0 -4
- package/dist/prod/locales/percentages-BXMCSKIN.js +0 -1
- package/dist/prod/locales/pl-PL-T2D74RX3.js +0 -9
- package/dist/prod/locales/pt-BR-5N22H2LF.js +0 -9
- package/dist/prod/locales/pt-PT-UZXXM6DQ.js +0 -9
- package/dist/prod/locales/ro-RO-JPDTUUEW.js +0 -11
- package/dist/prod/locales/ru-RU-B4JR7IUQ.js +0 -9
- package/dist/prod/locales/si-LK-N5RQ5JYF.js +0 -1
- package/dist/prod/locales/sk-SK-C5VTKIMK.js +0 -6
- package/dist/prod/locales/sl-SI-NN7IZMDC.js +0 -6
- package/dist/prod/locales/sv-SE-XGPEYMSR.js +0 -10
- package/dist/prod/locales/ta-IN-2NMHFXQM.js +0 -9
- package/dist/prod/locales/th-TH-HPSO5L25.js +0 -2
- package/dist/prod/locales/tr-TR-DEFEU3FU.js +0 -7
- package/dist/prod/locales/uk-UA-QMV73CPH.js +0 -6
- package/dist/prod/locales/vi-VN-M7AON7JQ.js +0 -5
- package/dist/prod/locales/zh-CN-LNUGB5OW.js +0 -10
- package/dist/prod/locales/zh-HK-E62DVLB3.js +0 -1
- package/dist/prod/locales/zh-TW-RAJ6MFWO.js +0 -9
- /package/dist/dev/data/{image-SURZSZNX.js.map → image-S2GFZH7W.js.map} +0 -0
- /package/dist/dev/locales/{en-SMAPCEOQ.js.map → en-ZO6QSABV.js.map} +0 -0
- /package/dist/dev/locales/{percentages-YKFLWNK2.js.map → percentages-2RAYDWNS.js.map} +0 -0
|
@@ -11,10 +11,10 @@ export type ActionResult = {
|
|
|
11
11
|
captureUpdate: CaptureUpdateActionType;
|
|
12
12
|
replaceFiles?: boolean;
|
|
13
13
|
} | false;
|
|
14
|
-
type ActionFn = (elements: readonly OrderedExcalidrawElement[], appState: Readonly<AppState>, formData:
|
|
14
|
+
type ActionFn<TData = any> = (elements: readonly OrderedExcalidrawElement[], appState: Readonly<AppState>, formData: TData | undefined, app: AppClassProperties) => ActionResult | Promise<ActionResult>;
|
|
15
15
|
export type UpdaterFn = (res: ActionResult) => void;
|
|
16
16
|
export type ActionFilterFn = (action: Action) => void;
|
|
17
|
-
export type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "copyText" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "objectsSnapMode" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeArrowType" | "
|
|
17
|
+
export type ActionName = "copy" | "cut" | "paste" | "copyAsPng" | "copyAsSvg" | "copyText" | "sendBackward" | "bringForward" | "sendToBack" | "bringToFront" | "copyStyles" | "selectAll" | "pasteStyles" | "gridMode" | "zenMode" | "objectsSnapMode" | "stats" | "changeStrokeColor" | "changeBackgroundColor" | "changeFillStyle" | "changeStrokeWidth" | "changeStrokeShape" | "changeSloppiness" | "changeStrokeStyle" | "changeArrowhead" | "changeArrowType" | "changeArrowProperties" | "changeOpacity" | "changeFontSize" | "undo" | "redo" | "finalize" | "changeProjectName" | "changeExportBackground" | "changeExportEmbedScene" | "changeExportScale" | "saveToActiveFile" | "saveFileToDisk" | "loadScene" | "duplicateSelection" | "deleteSelectedElements" | "changeViewBackgroundColor" | "clearCanvas" | "zoomIn" | "zoomOut" | "resetZoom" | "zoomToFit" | "zoomToFitSelection" | "zoomToFitSelectionInViewport" | "changeFontFamily" | "changeTextAlign" | "changeVerticalAlign" | "toggleFullScreen" | "toggleShortcuts" | "group" | "ungroup" | "goToCollaborator" | "addToLibrary" | "changeRoundness" | "alignTop" | "alignBottom" | "alignLeft" | "alignRight" | "alignVerticallyCentered" | "alignHorizontallyCentered" | "distributeHorizontally" | "distributeVertically" | "flipHorizontal" | "flipVertical" | "viewMode" | "exportWithDarkMode" | "toggleTheme" | "increaseFontSize" | "decreaseFontSize" | "unbindText" | "hyperlink" | "bindText" | "unlockAllElements" | "toggleElementLock" | "toggleLinearEditor" | "toggleEraserTool" | "toggleHandTool" | "selectAllElementsInFrame" | "removeAllElementsFromFrame" | "updateFrameRendering" | "setFrameAsActiveTool" | "setEmbeddableAsActiveTool" | "createContainerFromText" | "wrapTextInContainer" | "commandPalette" | "autoResize" | "elementStats" | "searchMenu" | "copyElementLink" | "linkToElement" | "cropEditor" | "wrapSelectionInFrame" | "toggleLassoTool" | "toggleShapeSwitch" | "togglePolygon";
|
|
18
18
|
export type PanelComponentProps = {
|
|
19
19
|
elements: readonly ExcalidrawElement[];
|
|
20
20
|
appState: AppState;
|
|
@@ -24,13 +24,13 @@ export type PanelComponentProps = {
|
|
|
24
24
|
app: AppClassProperties;
|
|
25
25
|
renderAction: (name: ActionName, data?: PanelComponentProps["data"]) => React.JSX.Element | null;
|
|
26
26
|
};
|
|
27
|
-
export interface Action {
|
|
27
|
+
export interface Action<TData = any> {
|
|
28
28
|
name: ActionName;
|
|
29
29
|
label: string | ((elements: readonly ExcalidrawElement[], appState: Readonly<AppState>, app: AppClassProperties) => string);
|
|
30
30
|
keywords?: string[];
|
|
31
31
|
icon?: React.ReactNode | ((appState: UIAppState, elements: readonly ExcalidrawElement[]) => React.ReactNode);
|
|
32
32
|
PanelComponent?: React.FC<PanelComponentProps>;
|
|
33
|
-
perform: ActionFn
|
|
33
|
+
perform: ActionFn<TData>;
|
|
34
34
|
keyPriority?: number;
|
|
35
35
|
keyTest?: (event: React.KeyboardEvent | KeyboardEvent, appState: AppState, elements: readonly ExcalidrawElement[], app: AppClassProperties) => boolean;
|
|
36
36
|
predicate?: (elements: readonly ExcalidrawElement[], appState: AppState, appProps: ExcalidrawProps, app: AppClassProperties) => boolean;
|
|
@@ -18,18 +18,25 @@ export declare const clearAppStateForLocalStorage: (appState: Partial<AppState>)
|
|
|
18
18
|
} | undefined;
|
|
19
19
|
selectedLinearElement?: import("@excalidraw/element").LinearElementEditor | null | undefined;
|
|
20
20
|
zenModeEnabled?: boolean | undefined;
|
|
21
|
+
shouldCacheIgnoreZoom?: boolean | undefined;
|
|
22
|
+
exportScale?: number | undefined;
|
|
23
|
+
bindMode?: import("@excalidraw/element/types").BindMode | undefined;
|
|
24
|
+
gridSize?: number | undefined;
|
|
21
25
|
showWelcomeScreen?: boolean | undefined;
|
|
22
26
|
activeTool?: ({
|
|
23
27
|
lastActiveTool: import("./types").ActiveTool | null;
|
|
24
28
|
locked: boolean;
|
|
25
29
|
fromSelection: boolean;
|
|
26
30
|
} & import("./types").ActiveTool) | undefined;
|
|
31
|
+
preferredSelectionTool?: {
|
|
32
|
+
type: "selection" | "lasso";
|
|
33
|
+
initialized: boolean;
|
|
34
|
+
} | undefined;
|
|
27
35
|
penMode?: boolean | undefined;
|
|
28
36
|
penDetected?: boolean | undefined;
|
|
29
37
|
exportBackground?: boolean | undefined;
|
|
30
38
|
exportEmbedScene?: boolean | undefined;
|
|
31
39
|
exportWithDarkMode?: boolean | undefined;
|
|
32
|
-
exportScale?: number | undefined;
|
|
33
40
|
currentItemStrokeColor?: string | undefined;
|
|
34
41
|
currentItemBackgroundColor?: string | undefined;
|
|
35
42
|
currentItemFillStyle?: import("@excalidraw/element/types").FillStyle | undefined;
|
|
@@ -46,7 +53,7 @@ export declare const clearAppStateForLocalStorage: (appState: Partial<AppState>)
|
|
|
46
53
|
currentItemArrowType?: "round" | "sharp" | "elbow" | undefined;
|
|
47
54
|
cursorButton?: "up" | "down" | undefined;
|
|
48
55
|
scrolledOutside?: boolean | undefined;
|
|
49
|
-
openMenu?: "canvas" |
|
|
56
|
+
openMenu?: "canvas" | null | undefined;
|
|
50
57
|
openSidebar?: {
|
|
51
58
|
name: string;
|
|
52
59
|
tab?: string | undefined;
|
|
@@ -56,8 +63,6 @@ export declare const clearAppStateForLocalStorage: (appState: Partial<AppState>)
|
|
|
56
63
|
previousSelectedElementIds?: {
|
|
57
64
|
[id: string]: true;
|
|
58
65
|
} | undefined;
|
|
59
|
-
shouldCacheIgnoreZoom?: boolean | undefined;
|
|
60
|
-
gridSize?: number | undefined;
|
|
61
66
|
gridStep?: number | undefined;
|
|
62
67
|
gridModeEnabled?: boolean | undefined;
|
|
63
68
|
stats?: {
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { ALLOWED_PASTE_MIME_TYPES } from "@excalidraw/common";
|
|
2
|
+
import type { ValueOf } from "@excalidraw/common/utility-types";
|
|
3
|
+
import type { IMAGE_MIME_TYPES, STRING_MIME_TYPES } from "@excalidraw/common";
|
|
2
4
|
import type { ExcalidrawElement, NonDeletedExcalidrawElement } from "@excalidraw/element/types";
|
|
5
|
+
import type { FileSystemHandle } from "./data/filesystem";
|
|
3
6
|
import type { Spreadsheet } from "./charts";
|
|
4
7
|
import type { BinaryFiles } from "./types";
|
|
5
8
|
export type PastedMixedContent = {
|
|
@@ -57,10 +60,70 @@ export declare const readSystemClipboard: () => Promise<{
|
|
|
57
60
|
"image/avif"?: string | File | undefined;
|
|
58
61
|
"image/jfif"?: string | File | undefined;
|
|
59
62
|
}>;
|
|
63
|
+
type AllowedParsedDataTransferItem = {
|
|
64
|
+
type: ValueOf<typeof IMAGE_MIME_TYPES>;
|
|
65
|
+
kind: "file";
|
|
66
|
+
file: File;
|
|
67
|
+
fileHandle: FileSystemHandle | null;
|
|
68
|
+
} | {
|
|
69
|
+
type: ValueOf<typeof STRING_MIME_TYPES>;
|
|
70
|
+
kind: "string";
|
|
71
|
+
value: string;
|
|
72
|
+
};
|
|
73
|
+
type ParsedDataTransferItem = {
|
|
74
|
+
type: string;
|
|
75
|
+
kind: "file";
|
|
76
|
+
file: File;
|
|
77
|
+
fileHandle: FileSystemHandle | null;
|
|
78
|
+
} | {
|
|
79
|
+
type: string;
|
|
80
|
+
kind: "string";
|
|
81
|
+
value: string;
|
|
82
|
+
};
|
|
83
|
+
type ParsedDataTransferItemType<T extends AllowedParsedDataTransferItem["type"]> = AllowedParsedDataTransferItem & {
|
|
84
|
+
type: T;
|
|
85
|
+
};
|
|
86
|
+
export type ParsedDataTransferFile = Extract<AllowedParsedDataTransferItem, {
|
|
87
|
+
kind: "file";
|
|
88
|
+
}>;
|
|
89
|
+
type ParsedDataTranferList = ParsedDataTransferItem[] & {
|
|
90
|
+
/**
|
|
91
|
+
* Only allows filtering by known `string` data types, since `file`
|
|
92
|
+
* types can have multiple items of the same type (e.g. multiple image files)
|
|
93
|
+
* unlike `string` data transfer items.
|
|
94
|
+
*/
|
|
95
|
+
findByType: typeof findDataTransferItemType;
|
|
96
|
+
/**
|
|
97
|
+
* Only allows filtering by known `string` data types, since `file`
|
|
98
|
+
* types can have multiple items of the same type (e.g. multiple image files)
|
|
99
|
+
* unlike `string` data transfer items.
|
|
100
|
+
*/
|
|
101
|
+
getData: typeof getDataTransferItemData;
|
|
102
|
+
getFiles: typeof getDataTransferFiles;
|
|
103
|
+
};
|
|
104
|
+
declare const findDataTransferItemType: <T extends ValueOf<{
|
|
105
|
+
readonly text: "text/plain";
|
|
106
|
+
readonly html: "text/html";
|
|
107
|
+
readonly json: "application/json";
|
|
108
|
+
readonly excalidraw: "application/vnd.excalidraw+json";
|
|
109
|
+
readonly excalidrawlib: "application/vnd.excalidrawlib+json";
|
|
110
|
+
readonly excalidrawlibIds: "application/vnd.excalidrawlib.ids+json";
|
|
111
|
+
}>>(this: ParsedDataTranferList, type: T) => ParsedDataTransferItemType<T> | null;
|
|
112
|
+
declare const getDataTransferItemData: <T extends ValueOf<{
|
|
113
|
+
readonly text: "text/plain";
|
|
114
|
+
readonly html: "text/html";
|
|
115
|
+
readonly json: "application/json";
|
|
116
|
+
readonly excalidraw: "application/vnd.excalidraw+json";
|
|
117
|
+
readonly excalidrawlib: "application/vnd.excalidrawlib+json";
|
|
118
|
+
readonly excalidrawlibIds: "application/vnd.excalidrawlib.ids+json";
|
|
119
|
+
}>>(this: ParsedDataTranferList, type: T) => ParsedDataTransferItemType<ValueOf<typeof STRING_MIME_TYPES>>["value"] | null;
|
|
120
|
+
declare const getDataTransferFiles: (this: ParsedDataTranferList) => ParsedDataTransferFile[];
|
|
121
|
+
export declare const parseDataTransferEvent: (event: ClipboardEvent | DragEvent | React.DragEvent<HTMLDivElement>) => Promise<ParsedDataTranferList>;
|
|
60
122
|
/**
|
|
61
123
|
* Attempts to parse clipboard event.
|
|
62
124
|
*/
|
|
63
|
-
export declare const parseClipboard: (
|
|
125
|
+
export declare const parseClipboard: (dataList: ParsedDataTranferList, isPlainPaste?: boolean) => Promise<ClipboardData>;
|
|
64
126
|
export declare const copyBlobToClipboardAsPng: (blob: Blob | Promise<Blob>) => Promise<void>;
|
|
65
127
|
export declare const copyTextToSystemClipboard: (text: string | null, clipboardEvent?: ClipboardEvent | null) => Promise<void>;
|
|
128
|
+
export declare const isClipboardEvent: (event: React.SyntheticEvent | Event) => event is ClipboardEvent;
|
|
66
129
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ExcalidrawElement, NonDeletedElementsMap, NonDeletedSceneElementsMap } from "@excalidraw/element/types";
|
|
2
2
|
import "./Actions.scss";
|
|
3
|
-
import type { AppClassProperties, AppProps, UIAppState, Zoom } from "../types";
|
|
3
|
+
import type { AppClassProperties, AppProps, UIAppState, Zoom, AppState } from "../types";
|
|
4
4
|
import type { ActionManager } from "../actions/manager";
|
|
5
5
|
export declare const canChangeStrokeColor: (appState: UIAppState, targetElements: ExcalidrawElement[]) => boolean;
|
|
6
6
|
export declare const canChangeBackgroundColor: (appState: UIAppState, targetElements: ExcalidrawElement[]) => boolean;
|
|
@@ -10,9 +10,23 @@ export declare const SelectedShapeActions: ({ appState, elementsMap, renderActio
|
|
|
10
10
|
renderAction: ActionManager["renderAction"];
|
|
11
11
|
app: AppClassProperties;
|
|
12
12
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
export declare const
|
|
14
|
-
activeTool: UIAppState["activeTool"];
|
|
13
|
+
export declare const CompactShapeActions: ({ appState, elementsMap, renderAction, app, setAppState, }: {
|
|
15
14
|
appState: UIAppState;
|
|
15
|
+
elementsMap: NonDeletedElementsMap | NonDeletedSceneElementsMap;
|
|
16
|
+
renderAction: ActionManager["renderAction"];
|
|
17
|
+
app: AppClassProperties;
|
|
18
|
+
setAppState: React.Component<any, AppState>["setState"];
|
|
19
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export declare const MobileShapeActions: ({ appState, elementsMap, renderAction, app, setAppState, }: {
|
|
21
|
+
appState: UIAppState;
|
|
22
|
+
elementsMap: NonDeletedElementsMap | NonDeletedSceneElementsMap;
|
|
23
|
+
renderAction: ActionManager["renderAction"];
|
|
24
|
+
app: AppClassProperties;
|
|
25
|
+
setAppState: React.Component<any, AppState>["setState"];
|
|
26
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export declare const ShapesSwitcher: ({ activeTool, setAppState, app, UIOptions, }: {
|
|
28
|
+
activeTool: UIAppState["activeTool"];
|
|
29
|
+
setAppState: React.Component<any, AppState>["setState"];
|
|
16
30
|
app: AppClassProperties;
|
|
17
31
|
UIOptions: AppProps["UIOptions"];
|
|
18
32
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -24,11 +38,10 @@ export declare const UndoRedoActions: ({ renderAction, className, }: {
|
|
|
24
38
|
renderAction: ActionManager["renderAction"];
|
|
25
39
|
className?: string | undefined;
|
|
26
40
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
27
|
-
export declare const
|
|
41
|
+
export declare const ExitZenModeButton: ({ actionManager, showExitZenModeBtn, }: {
|
|
28
42
|
actionManager: ActionManager;
|
|
29
43
|
showExitZenModeBtn: boolean;
|
|
30
44
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
31
|
-
export declare const
|
|
32
|
-
|
|
33
|
-
className?: string | undefined;
|
|
45
|
+
export declare const ExitViewModeButton: ({ actionManager, }: {
|
|
46
|
+
actionManager: ActionManager;
|
|
34
47
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import { type EXPORT_IMAGE_TYPES, Emitter } from "@excalidraw/common";
|
|
3
|
-
import { LinearElementEditor, FlowChartCreator, Scene, Store, type ElementUpdate } from "@excalidraw/element";
|
|
4
|
-
import type { ExcalidrawElement, NonDeleted, NonDeletedExcalidrawElement, ExcalidrawFrameLikeElement, ExcalidrawIframeElement, ExcalidrawEmbeddableElement, Ordered } from "@excalidraw/element/types";
|
|
2
|
+
import { type EXPORT_IMAGE_TYPES, Emitter, type EditorInterface, type StylesPanelMode } from "@excalidraw/common";
|
|
3
|
+
import { LinearElementEditor, FlowChartCreator, Scene, Store, type ElementUpdate, StoreDelta, type ApplyToOptions } from "@excalidraw/element";
|
|
4
|
+
import type { ExcalidrawElement, NonDeleted, NonDeletedExcalidrawElement, ExcalidrawFrameLikeElement, ExcalidrawIframeElement, ExcalidrawEmbeddableElement, Ordered, SceneElementsMap } from "@excalidraw/element/types";
|
|
5
5
|
import type { Mutable } from "@excalidraw/common/utility-types";
|
|
6
6
|
import { ActionManager } from "../actions/manager";
|
|
7
7
|
import { AnimationFrameHandler } from "../animation-frame-handler";
|
|
@@ -14,7 +14,7 @@ import { LassoTrail } from "../lasso";
|
|
|
14
14
|
import { EraserTrail } from "../eraser";
|
|
15
15
|
import type { ExportedElements } from "../data";
|
|
16
16
|
import type { FileSystemHandle } from "../data/filesystem";
|
|
17
|
-
import type { AppClassProperties, AppProps, AppState, ExcalidrawImperativeAPI, BinaryFiles, LibraryItems, SceneData,
|
|
17
|
+
import type { AppClassProperties, AppProps, AppState, ExcalidrawImperativeAPI, BinaryFiles, LibraryItems, SceneData, FrameNameBoundsCache, SidebarName, SidebarTabName, ToolType, OnUserFollowedPayload, GenerateDiagramToCode, NullableGridSize, Offsets } from "../types";
|
|
18
18
|
import type { RoughCanvas } from "roughjs/bin/canvas";
|
|
19
19
|
import type { ActionResult } from "../actions/types";
|
|
20
20
|
export declare const ExcalidrawContainerContext: React.Context<{
|
|
@@ -23,17 +23,18 @@ export declare const ExcalidrawContainerContext: React.Context<{
|
|
|
23
23
|
}>;
|
|
24
24
|
export declare const useApp: () => AppClassProperties;
|
|
25
25
|
export declare const useAppProps: () => AppProps;
|
|
26
|
-
export declare const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
canFitSidebar: boolean;
|
|
34
|
-
};
|
|
26
|
+
export declare const useEditorInterface: () => Readonly<{
|
|
27
|
+
formFactor: "phone" | "tablet" | "desktop";
|
|
28
|
+
desktopUIMode: "compact" | "full";
|
|
29
|
+
userAgent: Readonly<{
|
|
30
|
+
isMobileDevice: boolean;
|
|
31
|
+
platform: "other" | "ios" | "android" | "unknown";
|
|
32
|
+
}>;
|
|
35
33
|
isTouchScreen: boolean;
|
|
34
|
+
canFitSidebar: boolean;
|
|
35
|
+
isLandscape: boolean;
|
|
36
36
|
}>;
|
|
37
|
+
export declare const useStylesPanelMode: () => StylesPanelMode;
|
|
37
38
|
export declare const useExcalidrawContainer: () => {
|
|
38
39
|
container: HTMLDivElement | null;
|
|
39
40
|
id: string | null;
|
|
@@ -48,14 +49,14 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
48
49
|
rc: RoughCanvas;
|
|
49
50
|
unmounted: boolean;
|
|
50
51
|
actionManager: ActionManager;
|
|
51
|
-
|
|
52
|
+
editorInterface: EditorInterface;
|
|
53
|
+
private stylesPanelMode;
|
|
52
54
|
private excalidrawContainerRef;
|
|
53
55
|
scene: Scene;
|
|
54
56
|
fonts: Fonts;
|
|
55
57
|
renderer: Renderer;
|
|
56
58
|
visibleElements: readonly NonDeletedExcalidrawElement[];
|
|
57
59
|
private resizeObserver;
|
|
58
|
-
private nearestScrollableContainer;
|
|
59
60
|
library: AppClassProperties["library"];
|
|
60
61
|
libraryItemsFromStorage: LibraryItems | undefined;
|
|
61
62
|
id: string;
|
|
@@ -82,6 +83,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
82
83
|
private elementsPendingErasure;
|
|
83
84
|
flowChartCreator: FlowChartCreator;
|
|
84
85
|
private flowChartNavigator;
|
|
86
|
+
bindModeHandler: ReturnType<typeof setTimeout> | null;
|
|
85
87
|
hitLinkElement?: NonDeletedExcalidrawElement;
|
|
86
88
|
lastPointerDownEvent: React.PointerEvent<HTMLElement> | null;
|
|
87
89
|
lastPointerUpEvent: React.PointerEvent<HTMLElement> | PointerEvent | null;
|
|
@@ -153,6 +155,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
153
155
|
x: number;
|
|
154
156
|
y: number;
|
|
155
157
|
};
|
|
158
|
+
blockDragging: boolean;
|
|
156
159
|
};
|
|
157
160
|
eventListeners: {
|
|
158
161
|
onMove: {
|
|
@@ -222,6 +225,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
222
225
|
x: number;
|
|
223
226
|
y: number;
|
|
224
227
|
};
|
|
228
|
+
blockDragging: boolean;
|
|
225
229
|
};
|
|
226
230
|
eventListeners: {
|
|
227
231
|
onMove: {
|
|
@@ -246,6 +250,10 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
246
250
|
constructor(props: AppProps);
|
|
247
251
|
updateEditorAtom: <Value, Args extends unknown[], Result>(atom: WritableAtom<Value, Args, Result>, ...args: Args) => Result;
|
|
248
252
|
private onWindowMessage;
|
|
253
|
+
private handleSkipBindMode;
|
|
254
|
+
private resetDelayedBindMode;
|
|
255
|
+
private previousHoveredBindableElement;
|
|
256
|
+
private handleDelayedBindModeChange;
|
|
249
257
|
private cacheEmbeddableRef;
|
|
250
258
|
/**
|
|
251
259
|
* Returns gridSize taking into account `gridModeEnabled`.
|
|
@@ -297,9 +305,11 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
297
305
|
*/
|
|
298
306
|
private resetScene;
|
|
299
307
|
private initializeScene;
|
|
300
|
-
private
|
|
301
|
-
|
|
302
|
-
private
|
|
308
|
+
private getFormFactor;
|
|
309
|
+
refreshEditorInterface: () => void;
|
|
310
|
+
private reconcileStylesPanelMode;
|
|
311
|
+
/** TO BE USED LATER */
|
|
312
|
+
private setDesktopUIMode;
|
|
303
313
|
private clearImageShapeCache;
|
|
304
314
|
componentDidMount(): Promise<void>;
|
|
305
315
|
componentWillUnmount(): void;
|
|
@@ -316,6 +326,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
316
326
|
private static resetTapTwice;
|
|
317
327
|
private onTouchStart;
|
|
318
328
|
private onTouchEnd;
|
|
329
|
+
private insertClipboardContent;
|
|
319
330
|
pasteFromClipboard: (event: ClipboardEvent) => Promise<void>;
|
|
320
331
|
addElementsFromPasteOrLibrary: (opts: {
|
|
321
332
|
elements: readonly ExcalidrawElement[];
|
|
@@ -397,6 +408,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
397
408
|
*/
|
|
398
409
|
captureUpdate?: SceneData["captureUpdate"];
|
|
399
410
|
}) => void;
|
|
411
|
+
applyDeltas: (deltas: StoreDelta[], options?: ApplyToOptions) => [SceneElementsMap, AppState, boolean];
|
|
400
412
|
mutateElement: <TElement extends Mutable<ExcalidrawElement>>(element: TElement, updates: ElementUpdate<TElement>, informMutation?: boolean) => TElement;
|
|
401
413
|
private triggerRender;
|
|
402
414
|
/**
|
|
@@ -488,7 +500,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
488
500
|
sceneY: number;
|
|
489
501
|
link: string;
|
|
490
502
|
}) => NonDeleted<ExcalidrawEmbeddableElement> | undefined;
|
|
491
|
-
private
|
|
503
|
+
private newImagePlaceholder;
|
|
492
504
|
private handleLinearElementOnPointerDown;
|
|
493
505
|
private getCurrentItemRoundness;
|
|
494
506
|
private createGenericElementOnPointerDown;
|
|
@@ -509,11 +521,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
509
521
|
* and when you don't want to loose those modifications
|
|
510
522
|
*/
|
|
511
523
|
private getLatestInitializedImageElement;
|
|
512
|
-
|
|
513
|
-
* inserts image into elements array and rerenders
|
|
514
|
-
*/
|
|
515
|
-
private insertImageElement;
|
|
516
|
-
private onImageAction;
|
|
524
|
+
private onImageToolbarButtonClick;
|
|
517
525
|
private getImageNaturalDimensions;
|
|
518
526
|
/** updates image cache, refreshing updated elements and/or setting status
|
|
519
527
|
to error for images that fail during <img> element creation */
|
|
@@ -524,9 +532,9 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
524
532
|
* to render new images. This is just a failsafe */
|
|
525
533
|
private scheduleImageRefresh;
|
|
526
534
|
private updateBindingEnabledOnPointerMove;
|
|
527
|
-
private maybeSuggestBindingAtCursor;
|
|
528
535
|
private clearSelection;
|
|
529
536
|
private handleInteractiveCanvasRef;
|
|
537
|
+
private insertImages;
|
|
530
538
|
private handleAppOnDrop;
|
|
531
539
|
loadFileToCanvas: (file: File, fileHandle: FileSystemHandle | null) => Promise<void>;
|
|
532
540
|
private handleCanvasContextMenu;
|
|
@@ -541,6 +549,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
541
549
|
private updateDOMRect;
|
|
542
550
|
refresh: () => void;
|
|
543
551
|
private getCanvasOffsets;
|
|
552
|
+
watchState: () => void;
|
|
544
553
|
private updateLanguage;
|
|
545
554
|
}
|
|
546
555
|
declare global {
|
|
@@ -550,6 +559,7 @@ declare global {
|
|
|
550
559
|
elements: readonly ExcalidrawElement[];
|
|
551
560
|
state: AppState;
|
|
552
561
|
setState: React.Component<any, AppState>["setState"];
|
|
562
|
+
watchState: (prev: any, next: any) => void | undefined;
|
|
553
563
|
app: InstanceType<typeof App>;
|
|
554
564
|
history: History;
|
|
555
565
|
store: Store;
|
|
@@ -10,8 +10,10 @@ interface PickerProps {
|
|
|
10
10
|
palette: ColorPaletteCustom;
|
|
11
11
|
updateData: (formData?: any) => void;
|
|
12
12
|
children?: React.ReactNode;
|
|
13
|
+
showTitle?: boolean;
|
|
13
14
|
onEyeDropperToggle: (force?: boolean) => void;
|
|
14
15
|
onEscape: (event: React.KeyboardEvent | KeyboardEvent) => void;
|
|
16
|
+
showHotKey?: boolean;
|
|
15
17
|
}
|
|
16
18
|
export declare const Picker: React.ForwardRefExoticComponent<PickerProps & React.RefAttributes<unknown>>;
|
|
17
19
|
export {};
|
|
@@ -4,6 +4,7 @@ interface PickerColorListProps {
|
|
|
4
4
|
color: string | null;
|
|
5
5
|
onChange: (color: string) => void;
|
|
6
6
|
activeShade: number;
|
|
7
|
+
showHotKey?: boolean;
|
|
7
8
|
}
|
|
8
|
-
declare const PickerColorList: ({ palette, color, onChange, activeShade, }: PickerColorListProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare const PickerColorList: ({ palette, color, onChange, activeShade, showHotKey, }: PickerColorListProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
10
|
export default PickerColorList;
|
|
@@ -3,6 +3,7 @@ interface ShadeListProps {
|
|
|
3
3
|
color: string | null;
|
|
4
4
|
onChange: (color: string) => void;
|
|
5
5
|
palette: ColorPaletteCustom;
|
|
6
|
+
showHotKey?: boolean;
|
|
6
7
|
}
|
|
7
|
-
export declare const ShadeList: ({ color, onChange, palette }: ShadeListProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const ShadeList: ({ color, onChange, palette, showHotKey, }: ShadeListProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
9
|
export {};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import type { ActionManager } from "../../actions/manager";
|
|
3
3
|
import type { Action } from "../../actions/types";
|
|
4
|
-
import type { UIAppState } from "../../types";
|
|
5
4
|
export type CommandPaletteItem = {
|
|
6
5
|
label: string;
|
|
7
6
|
/** additional keywords to match against
|
|
@@ -12,7 +11,7 @@ export type CommandPaletteItem = {
|
|
|
12
11
|
* (deburred name + keywords)
|
|
13
12
|
*/
|
|
14
13
|
haystack?: string;
|
|
15
|
-
icon?:
|
|
14
|
+
icon?: Action["icon"];
|
|
16
15
|
category: string;
|
|
17
16
|
order?: number;
|
|
18
17
|
predicate?: boolean | Action["predicate"];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import "./ExcalidrawLogo.scss";
|
|
3
|
-
type LogoSize = "xs" | "small" | "normal" | "large" | "custom";
|
|
3
|
+
type LogoSize = "xs" | "small" | "normal" | "large" | "custom" | "mobile";
|
|
4
4
|
interface LogoProps {
|
|
5
5
|
size?: LogoSize;
|
|
6
6
|
withText?: boolean;
|
|
@@ -4,7 +4,7 @@ export type ButtonVariant = "filled" | "outlined" | "icon";
|
|
|
4
4
|
export type ButtonColor = "primary" | "danger" | "warning" | "muted" | "success";
|
|
5
5
|
export type ButtonSize = "medium" | "large";
|
|
6
6
|
export type FilledButtonProps = {
|
|
7
|
-
label
|
|
7
|
+
label?: string;
|
|
8
8
|
children?: React.ReactNode;
|
|
9
9
|
onClick?: (event: React.MouseEvent) => void;
|
|
10
10
|
status?: null | "loading" | "success";
|
|
@@ -16,6 +16,7 @@ interface FontPickerProps {
|
|
|
16
16
|
onHover: (fontFamily: FontFamilyValues) => void;
|
|
17
17
|
onLeave: () => void;
|
|
18
18
|
onPopupChange: (open: boolean) => void;
|
|
19
|
+
compactMode?: boolean;
|
|
19
20
|
}
|
|
20
|
-
export declare const FontPicker: React.MemoExoticComponent<({ isOpened, selectedFontFamily, hoveredFontFamily, onSelect, onHover, onLeave, onPopupChange, }: FontPickerProps) => import("react/jsx-runtime").JSX.Element>;
|
|
21
|
+
export declare const FontPicker: React.MemoExoticComponent<({ isOpened, selectedFontFamily, hoveredFontFamily, onSelect, onHover, onLeave, onPopupChange, compactMode, }: FontPickerProps) => import("react/jsx-runtime").JSX.Element>;
|
|
21
22
|
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import type { FontFamilyValues } from "@excalidraw/element/types";
|
|
2
2
|
interface FontPickerTriggerProps {
|
|
3
3
|
selectedFontFamily: FontFamilyValues | null;
|
|
4
|
+
isOpened?: boolean;
|
|
5
|
+
compactMode?: boolean;
|
|
4
6
|
}
|
|
5
|
-
export declare const FontPickerTrigger: ({ selectedFontFamily, }: FontPickerTriggerProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const FontPickerTrigger: ({ selectedFontFamily, isOpened, compactMode, }: FontPickerTriggerProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export {};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import type { EditorInterface } from "@excalidraw/common";
|
|
1
2
|
import "./HintViewer.scss";
|
|
2
|
-
import type { AppClassProperties,
|
|
3
|
+
import type { AppClassProperties, UIAppState } from "../types";
|
|
3
4
|
interface HintViewerProps {
|
|
4
5
|
appState: UIAppState;
|
|
5
6
|
isMobile: boolean;
|
|
6
|
-
|
|
7
|
+
editorInterface: EditorInterface;
|
|
7
8
|
app: AppClassProperties;
|
|
8
9
|
}
|
|
9
|
-
export declare const HintViewer: ({ appState, isMobile,
|
|
10
|
+
export declare const HintViewer: ({ appState, isMobile, editorInterface, app, }: HintViewerProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
10
11
|
export {};
|
|
@@ -17,6 +17,7 @@ interface LayerUIProps {
|
|
|
17
17
|
onPenModeToggle: AppClassProperties["togglePenMode"];
|
|
18
18
|
showExitZenModeBtn: boolean;
|
|
19
19
|
langCode: Language["code"];
|
|
20
|
+
renderTopLeftUI?: ExcalidrawProps["renderTopLeftUI"];
|
|
20
21
|
renderTopRightUI?: ExcalidrawProps["renderTopRightUI"];
|
|
21
22
|
renderCustomStats?: ExcalidrawProps["renderCustomStats"];
|
|
22
23
|
UIOptions: AppProps["UIOptions"];
|
|
@@ -27,5 +28,5 @@ interface LayerUIProps {
|
|
|
27
28
|
isCollaborating: boolean;
|
|
28
29
|
generateLinkForSelection?: AppProps["generateLinkForSelection"];
|
|
29
30
|
}
|
|
30
|
-
declare const _default: React.MemoExoticComponent<({ actionManager, appState, files, setAppState, elements, canvas, onLockToggle, onHandToolToggle, onPenModeToggle, showExitZenModeBtn, renderTopRightUI, renderCustomStats, UIOptions, onExportImage, renderWelcomeScreen, children, app, isCollaborating, generateLinkForSelection, }: LayerUIProps) => import("react/jsx-runtime").JSX.Element>;
|
|
31
|
+
declare const _default: React.MemoExoticComponent<({ actionManager, appState, files, setAppState, elements, canvas, onLockToggle, onHandToolToggle, onPenModeToggle, showExitZenModeBtn, renderTopLeftUI, renderTopRightUI, renderCustomStats, UIOptions, onExportImage, renderWelcomeScreen, children, app, isCollaborating, generateLinkForSelection, }: LayerUIProps) => import("react/jsx-runtime").JSX.Element>;
|
|
31
32
|
export default _default;
|
|
@@ -3,7 +3,7 @@ import type { ExcalidrawElement, NonDeleted } from "@excalidraw/element/types";
|
|
|
3
3
|
import type { SvgCache } from "../hooks/useLibraryItemSvg";
|
|
4
4
|
import type { LibraryItem } from "../types";
|
|
5
5
|
import type { ReactNode } from "react";
|
|
6
|
-
type LibraryOrPendingItem = (LibraryItem | /* pending library item */ {
|
|
6
|
+
type LibraryOrPendingItem = readonly (LibraryItem | /* pending library item */ {
|
|
7
7
|
id: null;
|
|
8
8
|
elements: readonly NonDeleted<ExcalidrawElement>[];
|
|
9
9
|
})[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import type { NonDeletedExcalidrawElement } from "@excalidraw/element/types";
|
|
3
3
|
import type { ActionManager } from "../actions/manager";
|
|
4
|
-
import type { AppClassProperties, AppProps, AppState,
|
|
4
|
+
import type { AppClassProperties, AppProps, AppState, UIAppState } from "../types";
|
|
5
5
|
import type { JSX } from "react";
|
|
6
6
|
type MobileMenuProps = {
|
|
7
7
|
appState: UIAppState;
|
|
@@ -10,16 +10,14 @@ type MobileMenuProps = {
|
|
|
10
10
|
renderImageExportDialog: () => React.ReactNode;
|
|
11
11
|
setAppState: React.Component<any, AppState>["setState"];
|
|
12
12
|
elements: readonly NonDeletedExcalidrawElement[];
|
|
13
|
-
onLockToggle: () => void;
|
|
14
13
|
onHandToolToggle: () => void;
|
|
15
14
|
onPenModeToggle: AppClassProperties["togglePenMode"];
|
|
16
15
|
renderTopRightUI?: (isMobile: boolean, appState: UIAppState) => JSX.Element | null;
|
|
17
|
-
|
|
16
|
+
renderTopLeftUI?: (isMobile: boolean, appState: UIAppState) => JSX.Element | null;
|
|
18
17
|
renderSidebars: () => JSX.Element | null;
|
|
19
|
-
device: Device;
|
|
20
18
|
renderWelcomeScreen: boolean;
|
|
21
19
|
UIOptions: AppProps["UIOptions"];
|
|
22
20
|
app: AppClassProperties;
|
|
23
21
|
};
|
|
24
|
-
export declare const MobileMenu: ({ appState, elements, actionManager, setAppState,
|
|
22
|
+
export declare const MobileMenu: ({ appState, elements, actionManager, setAppState, onHandToolToggle, renderTopLeftUI, renderTopRightUI, renderSidebars, renderWelcomeScreen, UIOptions, app, onPenModeToggle, }: MobileMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
23
|
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import "./ToolIcon.scss";
|
|
3
|
+
import "./MobileToolBar.scss";
|
|
4
|
+
import type { AppClassProperties, UIAppState } from "../types";
|
|
5
|
+
type MobileToolBarProps = {
|
|
6
|
+
app: AppClassProperties;
|
|
7
|
+
onHandToolToggle: () => void;
|
|
8
|
+
setAppState: React.Component<any, UIAppState>["setState"];
|
|
9
|
+
};
|
|
10
|
+
export declare const MobileToolBar: ({ app, onHandToolToggle, setAppState, }: MobileToolBarProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -10,6 +10,7 @@ type Props = {
|
|
|
10
10
|
offsetTop?: number;
|
|
11
11
|
viewportWidth?: number;
|
|
12
12
|
viewportHeight?: number;
|
|
13
|
+
className?: string;
|
|
13
14
|
};
|
|
14
|
-
export declare const Popover: ({ children, left, top, onCloseRequest, fitInViewport, offsetLeft, offsetTop, viewportWidth, viewportHeight, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export declare const Popover: ({ children, left, top, onCloseRequest, fitInViewport, offsetLeft, offsetTop, viewportWidth, viewportHeight, className, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
15
16
|
export {};
|
|
@@ -10,6 +10,7 @@ interface PropertiesPopoverProps {
|
|
|
10
10
|
onPointerLeave?: React.PointerEventHandler<HTMLDivElement>;
|
|
11
11
|
onFocusOutside?: Popover.PopoverContentProps["onFocusOutside"];
|
|
12
12
|
onPointerDownOutside?: Popover.PopoverContentProps["onPointerDownOutside"];
|
|
13
|
+
preventAutoFocusOnTouch?: boolean;
|
|
13
14
|
}
|
|
14
15
|
export declare const PropertiesPopover: React.ForwardRefExoticComponent<PropertiesPopoverProps & React.RefAttributes<HTMLDivElement>>;
|
|
15
16
|
export {};
|
|
@@ -15,5 +15,5 @@ export declare const newOrigin: (x1: number, y1: number, w1: number, h1: number,
|
|
|
15
15
|
x: number;
|
|
16
16
|
y: number;
|
|
17
17
|
};
|
|
18
|
-
export declare const moveElement: (newTopLeftX: number, newTopLeftY: number, originalElement: ExcalidrawElement, scene: Scene, originalElementsMap: ElementsMap, shouldInformMutation?: boolean) => void;
|
|
18
|
+
export declare const moveElement: (newTopLeftX: number, newTopLeftY: number, originalElement: ExcalidrawElement, scene: Scene, appState: AppState, originalElementsMap: ElementsMap, shouldInformMutation?: boolean) => void;
|
|
19
19
|
export declare const getAtomicUnits: (targetElements: readonly ExcalidrawElement[], appState: AppState) => AtomicUnit[];
|