@excalidraw/excalidraw 0.9.0 → 0.11.0-11a3380
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +498 -3
- package/README.md +537 -101
- package/dist/excalidraw-assets/i18n-ar-SA-json-f37c9765d6ba9c94db28.js +1 -0
- package/dist/excalidraw-assets/i18n-bg-BG-json-d8c72e41cf02e763b54c.js +1 -0
- package/dist/excalidraw-assets/i18n-bn-BD-json-246ddff2b69891d1399d.js +1 -0
- package/dist/excalidraw-assets/i18n-ca-ES-json-2583291c4633e96df9d6.js +1 -0
- package/dist/excalidraw-assets/i18n-cs-CZ-json-7fb82d30a7139f991154.js +1 -0
- package/dist/excalidraw-assets/i18n-da-DK-json-5f58e2d75044deee8410.js +1 -0
- package/dist/excalidraw-assets/i18n-de-DE-json-20912cca3094f0524a21.js +1 -0
- package/dist/excalidraw-assets/i18n-el-GR-json-96277306136a9ee3d56c.js +1 -0
- package/dist/excalidraw-assets/i18n-es-ES-json-2d9209d0d8b45e340212.js +1 -0
- package/dist/excalidraw-assets/i18n-eu-ES-json-40142a580d932c8cb50d.js +1 -0
- package/dist/excalidraw-assets/i18n-fa-IR-json-5aa04fe7e238f87f3607.js +1 -0
- package/dist/excalidraw-assets/i18n-fi-FI-json-2e5665a625fe47e2a60f.js +1 -0
- package/dist/excalidraw-assets/i18n-fr-FR-json-ad79d60ccbf7da435101.js +1 -0
- package/dist/excalidraw-assets/i18n-he-IL-json-5aa3ca202abb250e82bd.js +1 -0
- package/dist/excalidraw-assets/i18n-hi-IN-json-8fe2d63926e008f5725c.js +1 -0
- package/dist/excalidraw-assets/i18n-hu-HU-json-78e1c51d6d92ed32aa2f.js +1 -0
- package/dist/excalidraw-assets/i18n-id-ID-json-6c529ed7cc3d5353bdc0.js +1 -0
- package/dist/excalidraw-assets/i18n-it-IT-json-7c39e59e8682963a7851.js +1 -0
- package/dist/excalidraw-assets/i18n-ja-JP-json-2263e6c8e274763d04cc.js +1 -0
- package/dist/excalidraw-assets/i18n-kab-KAB-json-9974a930bde67748d79a.js +1 -0
- package/dist/excalidraw-assets/i18n-kk-KZ-json-b1da82815e51b638b28e.js +1 -0
- package/dist/excalidraw-assets/i18n-ko-KR-json-36dce31f57535a3884fc.js +1 -0
- package/dist/excalidraw-assets/i18n-lt-LT-json-7e4b8147241a2807a1f1.js +1 -0
- package/dist/excalidraw-assets/i18n-lv-LV-json-0292c4b3153e02ba01cc.js +1 -0
- package/dist/excalidraw-assets/i18n-mr-IN-json-85e3bad5588e60eda6ed.js +1 -0
- package/dist/excalidraw-assets/i18n-my-MM-json-a50d126ec63009915802.js +1 -0
- package/dist/excalidraw-assets/i18n-nb-NO-json-dd7cd6513e3d00551949.js +1 -0
- package/dist/excalidraw-assets/i18n-nl-NL-json-a2e36932c7b397dfdf8b.js +1 -0
- package/dist/excalidraw-assets/i18n-nn-NO-json-76159e8cfa136255e657.js +1 -0
- package/dist/excalidraw-assets/i18n-oc-FR-json-8fcbd2e5e589bc9b3f05.js +1 -0
- package/dist/excalidraw-assets/i18n-pa-IN-json-664d068563584bb41ae4.js +1 -0
- package/dist/excalidraw-assets/i18n-pl-PL-json-17d817993f240f65dc1f.js +1 -0
- package/dist/excalidraw-assets/i18n-pt-BR-json-dfbe3455644130e9851c.js +1 -0
- package/dist/excalidraw-assets/i18n-pt-PT-json-bda935fce18a7b179bcb.js +1 -0
- package/dist/excalidraw-assets/i18n-ro-RO-json-3473997bac53931c8b1c.js +1 -0
- package/dist/excalidraw-assets/i18n-ru-RU-json-2a58c91c91fbb9009a4a.js +1 -0
- package/dist/excalidraw-assets/i18n-si-LK-json-0ad49043e4c810f4e8f2.js +1 -0
- package/dist/excalidraw-assets/i18n-sk-SK-json-6a88d3cef7420263d448.js +1 -0
- package/dist/excalidraw-assets/i18n-sl-SI-json-d883f256ad475721b51e.js +1 -0
- package/dist/excalidraw-assets/i18n-sv-SE-json-ab9784b6a181e4b3e52b.js +1 -0
- package/dist/excalidraw-assets/i18n-ta-IN-json-49b6bc876b7703f493e7.js +1 -0
- package/dist/excalidraw-assets/i18n-tr-TR-json-e6a720f75140ee82da6d.js +1 -0
- package/dist/excalidraw-assets/i18n-uk-UA-json-1d95323ec8040114490e.js +1 -0
- package/dist/excalidraw-assets/i18n-zh-CN-json-facce09827627d918c14.js +1 -0
- package/dist/excalidraw-assets/i18n-zh-HK-json-a6e21fe69a6a6f8c8ea6.js +1 -0
- package/dist/excalidraw-assets/i18n-zh-TW-json-37610fbce479c7f8cef2.js +1 -0
- package/dist/excalidraw-assets/vendor-52b1f3361986b6c6a4fe.js +2 -0
- package/dist/excalidraw-assets/vendor-52b1f3361986b6c6a4fe.js.LICENSE.txt +12 -0
- package/dist/excalidraw-assets-dev/i18n-ar-SA-json-505ef559f47ea6b69719.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-bg-BG-json-bcb00de8d85335103437.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-bn-BD-json-20cb88b768b6656f69a0.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ca-ES-json-c0a2946ac526da48c821.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-cs-CZ-json-3b57cc3db37bad8747c9.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-da-DK-json-9fd1d27b5e867510c0c4.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-de-DE-json-80aa4aed6cc5f0f47bec.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-el-GR-json-08221c6f5387a7ef440e.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-es-ES-json-bb7d7aa7840ad87ac15d.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-eu-ES-json-1aff52bfd1a98cc073a3.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-fa-IR-json-1af59f1130dd499b2aee.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-fi-FI-json-874b4f80c8cb7c54ba9e.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-fr-FR-json-b55b922b008349e24e30.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-he-IL-json-e16fce9c2852e89a31f2.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-hi-IN-json-96d1324664dcf226249e.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e29c373127695ccfe28.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-id-ID-json-c3b8c47e9f2cd5a218a4.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-it-IT-json-c4ba0fd51730152b3389.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ja-JP-json-4fb9df48c7c2aca8709b.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-kab-KAB-json-56a2f5b742bb44d84587.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-kk-KZ-json-69f5849187a51635aa55.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ko-KR-json-be749d83561b4547fca0.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-lt-LT-json-f74d8fbb36e64d164cb3.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-lv-LV-json-05cafa9d59e825d37a30.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-mr-IN-json-4df0aaed6b5bd9c354bf.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-my-MM-json-10cd0a77755d74cc2d88.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-nb-NO-json-0328d43c8eb21619f1ef.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-nl-NL-json-ce7bba8e06a59e62a4d0.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-nn-NO-json-64d56d9257aa9516e081.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-oc-FR-json-efae2c9bbbc42a6f6c70.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-pa-IN-json-6378d9552735e33a9fe3.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-pl-PL-json-ed1bf39b6b8f8061299d.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-pt-BR-json-2a02a619bfa9700ce852.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-pt-PT-json-d28b9a54ff94e15ff9bb.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ro-RO-json-00d5715f05aa3063960a.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ru-RU-json-ac0637166d5b462e339f.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-si-LK-json-63d7c3f1c548dd28b002.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-sk-SK-json-42cdbcaa7b9a48f2d39f.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-sl-SI-json-56b1f2e0db09f030df1d.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-sv-SE-json-3eb8200f34c205bc6564.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-ta-IN-json-6d1328c5b1be8952f272.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-tr-TR-json-f19e7eace448e972fc37.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-uk-UA-json-da0e1d496b320531f5dc.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-zh-CN-json-84fc26b884a0a83892c9.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-zh-HK-json-07799e9c9378a2263273.js +22 -0
- package/dist/excalidraw-assets-dev/i18n-zh-TW-json-61c7460fdc361e477121.js +22 -0
- package/dist/excalidraw-assets-dev/vendor-c0592035c3911af79359.js +98 -0
- package/dist/excalidraw.development.js +1065 -350
- package/dist/excalidraw.production.min.js +1 -1
- package/dist/excalidraw.production.min.js.LICENSE.txt +23 -1
- package/package.json +32 -25
- package/types/actions/actionAddToLibrary.d.ts +298 -1
- package/types/actions/actionAlign.d.ts +91 -6
- package/types/actions/actionBoundText.d.ts +123 -0
- package/types/actions/actionCanvas.d.ts +861 -8
- package/types/actions/actionClipboard.d.ts +563 -4
- package/types/actions/actionDeleteSelected.d.ts +323 -1
- package/types/actions/actionDistribute.d.ts +33 -2
- package/types/actions/actionDuplicateSelection.d.ts +22 -1
- package/types/actions/actionExport.d.ts +956 -8
- package/types/actions/actionFinalize.d.ts +206 -1
- package/types/actions/actionFlip.d.ts +35 -2
- package/types/actions/actionGroup.d.ts +45 -2
- package/types/actions/actionMenu.d.ts +334 -4
- package/types/actions/actionNavigate.d.ts +14 -1
- package/types/actions/actionProperties.d.ts +1389 -12
- package/types/actions/actionSelectAll.d.ts +15 -1
- package/types/actions/actionStyles.d.ts +125 -2
- package/types/actions/actionToggleGridMode.d.ts +111 -1
- package/types/actions/actionToggleLock.d.ts +17 -0
- package/types/actions/actionToggleStats.d.ts +109 -1
- package/types/actions/actionToggleViewMode.d.ts +110 -1
- package/types/actions/actionToggleZenMode.d.ts +110 -1
- package/types/actions/actionZindex.d.ts +67 -4
- package/types/actions/index.d.ts +5 -2
- package/types/actions/manager.d.ts +10 -15
- package/types/actions/register.d.ts +3 -1
- package/types/actions/shortcuts.d.ts +2 -1
- package/types/actions/types.d.ts +20 -24
- package/types/align.d.ts +0 -1
- package/types/analytics.d.ts +1 -1
- package/types/appState.d.ts +27 -11
- package/types/charts.d.ts +8 -0
- package/types/clipboard.d.ts +5 -4
- package/types/components/Actions.d.ts +9 -5
- package/types/components/App.d.ts +68 -17
- package/types/components/Avatar.d.ts +3 -2
- package/types/components/ButtonIconSelect.d.ts +1 -0
- package/types/components/Card.d.ts +1 -1
- package/types/components/CheckboxItem.d.ts +2 -1
- package/types/components/ClearCanvas.d.ts +5 -0
- package/types/components/ColorPicker.d.ts +6 -1
- package/types/components/ConfirmDialog.d.ts +11 -0
- package/types/components/ContextMenu.d.ts +3 -0
- package/types/components/DarkModeToggle.d.ts +3 -3
- package/types/components/Dialog.d.ts +4 -2
- package/types/components/HintViewer.d.ts +3 -2
- package/types/components/ImageExportDialog.d.ts +5 -4
- package/types/components/InitializeApp.d.ts +2 -10
- package/types/components/JSONExportDialog.d.ts +6 -5
- package/types/components/LayerUI.d.ts +12 -5
- package/types/components/LibraryButton.d.ts +1 -0
- package/types/components/LibraryMenu.d.ts +18 -0
- package/types/components/LibraryMenuItems.d.ts +24 -0
- package/types/components/LibraryUnit.d.ts +9 -5
- package/types/components/LoadingMessage.d.ts +3 -1
- package/types/components/LockButton.d.ts +1 -0
- package/types/components/MobileMenu.d.ts +8 -2
- package/types/components/Modal.d.ts +1 -0
- package/types/components/PasteChartDialog.d.ts +1 -1
- package/types/components/{LockIcon.d.ts → PenModeButton.d.ts} +4 -5
- package/types/components/Popover.d.ts +5 -1
- package/types/components/PublishLibrary.d.ts +17 -0
- package/types/components/SidebarLockButton.d.ts +9 -0
- package/types/components/SingleLibraryItem.d.ts +11 -0
- package/types/components/Spinner.d.ts +7 -0
- package/types/components/Stack.d.ts +1 -1
- package/types/components/Toast.d.ts +3 -1
- package/types/components/ToolButton.d.ts +15 -4
- package/types/components/Tooltip.d.ts +9 -1
- package/types/components/UserList.d.ts +6 -5
- package/types/components/icons.d.ts +57 -40
- package/types/constants.d.ts +45 -11
- package/types/data/blob.d.ts +44 -4
- package/types/data/encode.d.ts +29 -1
- package/types/data/encryption.d.ts +9 -0
- package/types/data/filesystem.d.ts +18 -0
- package/types/data/index.d.ts +5 -3
- package/types/data/json.d.ts +8 -9
- package/types/data/library.d.ts +90 -8
- package/types/data/resave.d.ts +5 -0
- package/types/data/restore.d.ts +5 -3
- package/types/data/types.d.ts +9 -4
- package/types/{disitrubte.d.ts → distribute.d.ts} +0 -1
- package/types/element/Hyperlink.d.ts +131 -0
- package/types/element/bounds.d.ts +12 -1
- package/types/element/collision.d.ts +4 -2
- package/types/element/dragElements.d.ts +3 -5
- package/types/element/image.d.ts +22 -0
- package/types/element/index.d.ts +2 -4
- package/types/element/linearElementEditor.d.ts +142 -9
- package/types/element/mutateElement.d.ts +2 -2
- package/types/element/newElement.d.ts +8 -3
- package/types/element/resizeElements.d.ts +3 -3
- package/types/element/sizeHelpers.d.ts +2 -1
- package/types/element/textElement.d.ts +26 -2
- package/types/element/textWysiwyg.d.ts +6 -5
- package/types/element/typeChecks.d.ts +11 -5
- package/types/element/types.d.ts +35 -8
- package/types/errors.d.ts +3 -0
- package/types/galines.d.ts +1 -1
- package/types/groups.d.ts +1 -0
- package/types/i18n.d.ts +1 -1
- package/types/jotai.d.ts +122 -0
- package/types/keys.d.ts +10 -3
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-2d5f019d3158606ce049.d.ts → excalidraw-assets/i18n-ar-SA-json-f37c9765d6ba9c94db28.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-4d16bcc700cc54fb5150.d.ts → excalidraw-assets/i18n-bg-BG-json-d8c72e41cf02e763b54c.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-54b9f1fcf9d30cb7e16b.d.ts → excalidraw-assets/i18n-bn-BD-json-246ddff2b69891d1399d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-88b8054cb50aeb2839a0.d.ts → excalidraw-assets/i18n-ca-ES-json-2583291c4633e96df9d6.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-ade0d6de22b384a864b5.d.ts → excalidraw-assets/i18n-cs-CZ-json-7fb82d30a7139f991154.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/image-e3aeb716c01117aa817c.d.ts → excalidraw-assets/i18n-da-DK-json-5f58e2d75044deee8410.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-35458983ee43054138fb.d.ts → excalidraw-assets/i18n-de-DE-json-20912cca3094f0524a21.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-87b1add30a2f905d5383.d.ts → excalidraw-assets/i18n-el-GR-json-96277306136a9ee3d56c.d.ts} +0 -0
- package/types/packages/excalidraw/dist/{excalidraw-assets-dev/vendor-b5a444a20160d317c888.d.ts → excalidraw-assets/i18n-es-ES-json-2d9209d0d8b45e340212.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9a3fdf94110439c2826a.d.ts → i18n-eu-ES-json-40142a580d932c8cb50d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9a7bef3582993b3fde41.d.ts → i18n-fa-IR-json-5aa04fe7e238f87f3607.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-9bf98c30c5eacdcb1d2b.d.ts → i18n-fi-FI-json-2e5665a625fe47e2a60f.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ar-SA-json-efd63375f9605b72c4af.d.ts → i18n-fr-FR-json-ad79d60ccbf7da435101.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-047db6df7a74c0298938.d.ts → i18n-he-IL-json-5aa3ca202abb250e82bd.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-35c0e8b92b0dba8a4e6d.d.ts → i18n-hi-IN-json-8fe2d63926e008f5725c.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-93c3fd2b081c849d4e04.d.ts → i18n-hu-HU-json-78e1c51d6d92ed32aa2f.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-bg-BG-json-deaa23a1909c5ca3188b.d.ts → i18n-id-ID-json-6c529ed7cc3d5353bdc0.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-08195bd47d46584560ff.d.ts → i18n-it-IT-json-7c39e59e8682963a7851.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-6acefe26cfe1d2f12349.d.ts → i18n-ja-JP-json-2263e6c8e274763d04cc.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-9924fbd53652d5f15134.d.ts → i18n-kab-KAB-json-9974a930bde67748d79a.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-cdcaf0f176ae3bed5fae.d.ts → i18n-kk-KZ-json-b1da82815e51b638b28e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-ca-ES-json-e749f7948c1b822fc757.d.ts → i18n-ko-KR-json-36dce31f57535a3884fc.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-cs-CZ-json-85a469d813bb069829e7.d.ts → i18n-lt-LT-json-7e4b8147241a2807a1f1.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-cs-CZ-json-8b577e35bb3be3287a0b.d.ts → i18n-lv-LV-json-0292c4b3153e02ba01cc.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-3fafb93744f3fe7634ea.d.ts → i18n-mr-IN-json-85e3bad5588e60eda6ed.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-a52c17c4bd1b1db22464.d.ts → i18n-my-MM-json-a50d126ec63009915802.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-e521697dab684b2ac173.d.ts → i18n-nb-NO-json-dd7cd6513e3d00551949.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-f72002171c2c56b967cd.d.ts → i18n-nl-NL-json-a2e36932c7b397dfdf8b.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-de-DE-json-f85a8a52534c04c3f3b8.d.ts → i18n-nn-NO-json-76159e8cfa136255e657.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-060595a09e0004e33936.d.ts → i18n-oc-FR-json-8fcbd2e5e589bc9b3f05.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-0ae6dd3287c4d9187ed9.d.ts → i18n-pa-IN-json-664d068563584bb41ae4.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-3b209ec86ca2ce69bdfa.d.ts → i18n-pl-PL-json-17d817993f240f65dc1f.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-el-GR-json-f8f9a3a1729a4935edbc.d.ts → i18n-pt-BR-json-dfbe3455644130e9851c.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-2c2246b5f03e518b157c.d.ts → i18n-pt-PT-json-bda935fce18a7b179bcb.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-32dc3bf0f789ef18e65d.d.ts → i18n-ro-RO-json-3473997bac53931c8b1c.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-af5c541f9ac1526a9eb7.d.ts → i18n-ru-RU-json-2a58c91c91fbb9009a4a.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-es-ES-json-f96b60c302d96c66ffd7.d.ts → i18n-si-LK-json-0ad49043e4c810f4e8f2.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-7ee232d4ef08da0903f6.d.ts → i18n-sk-SK-json-6a88d3cef7420263d448.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-95e4c55eb845ae827609.d.ts → i18n-sl-SI-json-d883f256ad475721b51e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-c732ff7772327332c259.d.ts → i18n-sv-SE-json-ab9784b6a181e4b3e52b.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fa-IR-json-f488b2da71daf406eb0f.d.ts → i18n-ta-IN-json-49b6bc876b7703f493e7.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-343add77fd58a5f2daee.d.ts → i18n-tr-TR-json-e6a720f75140ee82da6d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-46abeda8d809d4091924.d.ts → i18n-uk-UA-json-1d95323ec8040114490e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-a10d316db60e5c683310.d.ts → i18n-zh-CN-json-facce09827627d918c14.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fi-FI-json-c1d5c5510660a11a428e.d.ts → i18n-zh-HK-json-a6e21fe69a6a6f8c8ea6.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fr-FR-json-0d90c291749f4d0d0be6.d.ts → i18n-zh-TW-json-37610fbce479c7f8cef2.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/{i18n-fr-FR-json-6a418571305eecefe9bc.d.ts → vendor-52b1f3361986b6c6a4fe.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-0a4540a233e8caaf94d9.d.ts → i18n-ar-SA-json-505ef559f47ea6b69719.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-0c75d11c063d62b35b71.d.ts → i18n-bg-BG-json-bcb00de8d85335103437.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-42e4a9a6e2c159061c2e.d.ts → i18n-bn-BD-json-20cb88b768b6656f69a0.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ar-SA-json-63e2f39b63698b7eec53.d.ts → i18n-ca-ES-json-c0a2946ac526da48c821.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-26395bf4e2d6709dca77.d.ts → i18n-cs-CZ-json-3b57cc3db37bad8747c9.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-8e2bb5d514f8cc8a936b.d.ts → i18n-da-DK-json-9fd1d27b5e867510c0c4.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-b6c71fc307b4fef4b72b.d.ts → i18n-de-DE-json-80aa4aed6cc5f0f47bec.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-bg-BG-json-be04e761ddcbc1c4ef62.d.ts → i18n-el-GR-json-08221c6f5387a7ef440e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-0d4b865327b1c8a2e162.d.ts → i18n-es-ES-json-bb7d7aa7840ad87ac15d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-0d6f2cdd7cc53fc24d55.d.ts → i18n-eu-ES-json-1aff52bfd1a98cc073a3.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-15172cbf8d8b0f2a1f11.d.ts → i18n-fa-IR-json-1af59f1130dd499b2aee.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-5e1e08fdf7498c74acc5.d.ts → i18n-fi-FI-json-874b4f80c8cb7c54ba9e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-ca-ES-json-f06e683fbdf44f0ebde6.d.ts → i18n-fr-FR-json-b55b922b008349e24e30.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-cs-CZ-json-3d54eebf950d01467bb5.d.ts → i18n-he-IL-json-e16fce9c2852e89a31f2.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-cs-CZ-json-71bced584264c00ae327.d.ts → i18n-hi-IN-json-96d1324664dcf226249e.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-36d3bb51775cf6439260.d.ts → i18n-hu-HU-json-5e29c373127695ccfe28.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-5030e9ac8691da749eba.d.ts → i18n-id-ID-json-c3b8c47e9f2cd5a218a4.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-5c7f9a0825ce685c7858.d.ts → i18n-it-IT-json-c4ba0fd51730152b3389.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-8da7966bd6dfa56b82c2.d.ts → i18n-ja-JP-json-4fb9df48c7c2aca8709b.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-de-DE-json-ab1adfc4c415380a8a35.d.ts → i18n-kab-KAB-json-56a2f5b742bb44d84587.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-2b516aa8f8b476154402.d.ts → i18n-kk-KZ-json-69f5849187a51635aa55.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-6296dc761fd8118e1e78.d.ts → i18n-ko-KR-json-be749d83561b4547fca0.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-d4c14b7f18bddb549e91.d.ts → i18n-lt-LT-json-f74d8fbb36e64d164cb3.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-el-GR-json-e5ab1f25e7610ad2c05e.d.ts → i18n-lv-LV-json-05cafa9d59e825d37a30.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-24023bb070a10e04a83b.d.ts → i18n-mr-IN-json-4df0aaed6b5bd9c354bf.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-2fd2ed034bbb31a25ded.d.ts → i18n-my-MM-json-10cd0a77755d74cc2d88.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-4f103c28e06da0dc2e6f.d.ts → i18n-nb-NO-json-0328d43c8eb21619f1ef.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-es-ES-json-c5fd5e8031140d6bafbb.d.ts → i18n-nl-NL-json-ce7bba8e06a59e62a4d0.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-5a679533a42b77a05d96.d.ts → i18n-nn-NO-json-64d56d9257aa9516e081.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-5dc6d99195af9d060ac0.d.ts → i18n-oc-FR-json-efae2c9bbbc42a6f6c70.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-86dffdf09ca14041d5aa.d.ts → i18n-pa-IN-json-6378d9552735e33a9fe3.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fa-IR-json-aa9909cb72236eb377f1.d.ts → i18n-pl-PL-json-ed1bf39b6b8f8061299d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-00fee41aad7582723ba6.d.ts → i18n-pt-BR-json-2a02a619bfa9700ce852.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-058a78a0d62102edc16f.d.ts → i18n-pt-PT-json-d28b9a54ff94e15ff9bb.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-1d24e65912cb13d89613.d.ts → i18n-ro-RO-json-00d5715f05aa3063960a.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fi-FI-json-2d77bb0a44634fa78695.d.ts → i18n-ru-RU-json-ac0637166d5b462e339f.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-2249e2273f1c8ea609ec.d.ts → i18n-si-LK-json-63d7c3f1c548dd28b002.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-7043401a4303666c9542.d.ts → i18n-sk-SK-json-42cdbcaa7b9a48f2d39f.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-793074fb924464bc4564.d.ts → i18n-sl-SI-json-56b1f2e0db09f030df1d.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-fr-FR-json-d59cbe6664dcf219c750.d.ts → i18n-sv-SE-json-3eb8200f34c205bc6564.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-15405475fc235bd269f0.d.ts → i18n-ta-IN-json-6d1328c5b1be8952f272.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-7b83b92b6e883e3d08e1.d.ts → i18n-tr-TR-json-f19e7eace448e972fc37.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-853dbfc1fcf5a9658ed5.d.ts → i18n-uk-UA-json-da0e1d496b320531f5dc.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-he-IL-json-dd75fd04034452f7ddc2.d.ts → i18n-zh-CN-json-84fc26b884a0a83892c9.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-hi-IN-json-6f529355d7944d9d34a6.d.ts → i18n-zh-HK-json-07799e9c9378a2263273.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{i18n-hi-IN-json-711c31911b0455f9b7db.d.ts → i18n-zh-TW-json-61c7460fdc361e477121.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/{image-0ad20139bba28f28b031.d.ts → vendor-c0592035c3911af79359.d.ts} +0 -0
- package/types/packages/excalidraw/dist/excalidraw.production.min.d.ts +1 -3
- package/types/packages/excalidraw/entry.d.ts +0 -2
- package/types/packages/excalidraw/env.d.ts +1 -0
- package/types/packages/excalidraw/example/App.d.ts +8 -0
- package/types/packages/excalidraw/example/index.d.ts +1 -0
- package/types/packages/excalidraw/example/initialData.d.ts +172 -0
- package/types/packages/excalidraw/example/sidebar/Sidebar.d.ts +5 -0
- package/types/packages/excalidraw/index.d.ts +9 -7
- package/types/packages/excalidraw/webpack.dev-server.config.d.ts +19 -0
- package/types/packages/excalidraw/webpack.dev.config.d.ts +6 -8
- package/types/packages/excalidraw/webpack.prod.config.d.ts +10 -9
- package/types/packages/utils.d.ts +19 -9
- package/types/renderer/renderElement.d.ts +17 -5
- package/types/renderer/renderScene.d.ts +5 -9
- package/types/scene/Scene.d.ts +2 -3
- package/types/scene/comparisons.d.ts +3 -2
- package/types/scene/export.d.ts +4 -4
- package/types/scene/index.d.ts +2 -2
- package/types/scene/selection.d.ts +1 -1
- package/types/scene/types.d.ts +16 -8
- package/types/scene/zoom.d.ts +12 -5
- package/types/shapes.d.ts +7 -3
- package/types/types.d.ts +121 -25
- package/types/utils.d.ts +48 -8
- package/types/zindex.d.ts +2 -2
- package/dist/excalidraw-assets/i18n-ar-SA-json-9a7bef3582993b3fde41.js +0 -1
- package/dist/excalidraw-assets/i18n-bg-BG-json-93c3fd2b081c849d4e04.js +0 -1
- package/dist/excalidraw-assets/i18n-ca-ES-json-e749f7948c1b822fc757.js +0 -1
- package/dist/excalidraw-assets/i18n-cs-CZ-json-8b577e35bb3be3287a0b.js +0 -1
- package/dist/excalidraw-assets/i18n-de-DE-json-f72002171c2c56b967cd.js +0 -1
- package/dist/excalidraw-assets/i18n-el-GR-json-f8f9a3a1729a4935edbc.js +0 -1
- package/dist/excalidraw-assets/i18n-es-ES-json-2c2246b5f03e518b157c.js +0 -1
- package/dist/excalidraw-assets/i18n-fa-IR-json-95e4c55eb845ae827609.js +0 -1
- package/dist/excalidraw-assets/i18n-fi-FI-json-a10d316db60e5c683310.js +0 -1
- package/dist/excalidraw-assets/i18n-fr-FR-json-97d3c042d3a35ef178f1.js +0 -1
- package/dist/excalidraw-assets/i18n-he-IL-json-2636e07fd8cc89d175d9.js +0 -1
- package/dist/excalidraw-assets/i18n-hi-IN-json-15259c14d6c8090e6041.js +0 -1
- package/dist/excalidraw-assets/i18n-hu-HU-json-83f954e3c1e57b6fd4f2.js +0 -1
- package/dist/excalidraw-assets/i18n-id-ID-json-9c439203bdabe6684608.js +0 -1
- package/dist/excalidraw-assets/i18n-it-IT-json-32a61d0b3e05b538bf63.js +0 -1
- package/dist/excalidraw-assets/i18n-ja-JP-json-7780222c69cc877e19a5.js +0 -1
- package/dist/excalidraw-assets/i18n-kab-KAB-json-9438814b6f8d2d4bca30.js +0 -1
- package/dist/excalidraw-assets/i18n-kk-KZ-json-c6e1e808c0237fb1c06e.js +0 -1
- package/dist/excalidraw-assets/i18n-ko-KR-json-60158040fc55af420fec.js +0 -1
- package/dist/excalidraw-assets/i18n-lv-LV-json-0a84813c147df37dafd5.js +0 -1
- package/dist/excalidraw-assets/i18n-my-MM-json-b7cafa3196e9247a3744.js +0 -1
- package/dist/excalidraw-assets/i18n-nb-NO-json-7817632f1248c4374b19.js +0 -1
- package/dist/excalidraw-assets/i18n-nl-NL-json-7bedb9ed0d2a6ce6dbef.js +0 -1
- package/dist/excalidraw-assets/i18n-nn-NO-json-cc3e8135a35bc8f98708.js +0 -1
- package/dist/excalidraw-assets/i18n-oc-FR-json-7cd0233768ae95a4ff67.js +0 -1
- package/dist/excalidraw-assets/i18n-pa-IN-json-0346c42fd5a76dafe221.js +0 -1
- package/dist/excalidraw-assets/i18n-pl-PL-json-fd71968e6ed066a9a7e4.js +0 -1
- package/dist/excalidraw-assets/i18n-pt-BR-json-464cb502a9c0fedb90bc.js +0 -1
- package/dist/excalidraw-assets/i18n-pt-PT-json-7b7c90b1b9d2f1c8516b.js +0 -1
- package/dist/excalidraw-assets/i18n-ro-RO-json-ac25005e74f8dd8d360c.js +0 -1
- package/dist/excalidraw-assets/i18n-ru-RU-json-ef8daff1f5e8b77e4cad.js +0 -1
- package/dist/excalidraw-assets/i18n-sk-SK-json-f50495416e3b91a65ed6.js +0 -1
- package/dist/excalidraw-assets/i18n-sv-SE-json-2fd231ccf2c37b2df52d.js +0 -1
- package/dist/excalidraw-assets/i18n-tr-TR-json-a940d18e2fb0ff323575.js +0 -1
- package/dist/excalidraw-assets/i18n-uk-UA-json-f6fb2e431947fd51c7cd.js +0 -1
- package/dist/excalidraw-assets/i18n-zh-CN-json-3333609e8b26b63da65d.js +0 -1
- package/dist/excalidraw-assets/i18n-zh-TW-json-08026b081d7dae088759.js +0 -1
- package/dist/excalidraw-assets/image-eafab0c39ce13f7fea67.js +0 -1
- package/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.js +0 -2
- package/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.js.LICENSE.txt +0 -1
- package/dist/excalidraw-assets-dev/i18n-ar-SA-json-42e4a9a6e2c159061c2e.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-bg-BG-json-8e2bb5d514f8cc8a936b.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-ca-ES-json-0d4b865327b1c8a2e162.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-cs-CZ-json-3d54eebf950d01467bb5.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-de-DE-json-5030e9ac8691da749eba.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-el-GR-json-6296dc761fd8118e1e78.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-es-ES-json-c5fd5e8031140d6bafbb.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-fa-IR-json-aa9909cb72236eb377f1.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-fi-FI-json-2d77bb0a44634fa78695.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-fr-FR-json-2249e2273f1c8ea609ec.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-he-IL-json-853dbfc1fcf5a9658ed5.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-hi-IN-json-dfd13380f880265721d1.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e40f12439fdaf31e5f8.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-id-ID-json-d0fd59d99eb8268ad32d.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-it-IT-json-dc31d253c180bd8bc42c.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-ja-JP-json-db2805c4535d81f39148.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-kab-KAB-json-b88f94c29607a0102313.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-kk-KZ-json-3c033b44668ea8f33a22.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-ko-KR-json-87c10c8f44988dd0e13a.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-lv-LV-json-1a80ea1c8f3354d394cf.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-my-MM-json-8a534e22357023f607a4.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-nb-NO-json-49fa9e922f887d2f60a7.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-nl-NL-json-df1ade23a540ca746458.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-nn-NO-json-6d27231c8f6f5056953c.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-oc-FR-json-069879d69e9d37f7131f.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-pa-IN-json-5e2e9c3078bfca8530b1.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-pl-PL-json-f161c5a49ee47f8e771c.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-pt-BR-json-715832c0500f14d50107.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-pt-PT-json-482e046bcfea32653cf0.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-ro-RO-json-4a2e4f653982cc7b046e.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-ru-RU-json-aa92dea266fa031249ca.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-sk-SK-json-118350b0f0cdc9be21b6.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-sv-SE-json-0b0469f979b4abbbd52a.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-tr-TR-json-fc6af871b929adde7bd8.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-uk-UA-json-0455e3b621d70d11a5be.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-zh-CN-json-3fe440d4981c65767b68.js +0 -22
- package/dist/excalidraw-assets-dev/i18n-zh-TW-json-a78c1cbb2eaa5ad69af6.js +0 -22
- package/dist/excalidraw-assets-dev/image-0ad20139bba28f28b031.js +0 -33
- package/dist/excalidraw-assets-dev/vendor-87b1add30a2f905d5383.js +0 -356
- package/types/components/ExportDialog.d.ts +0 -17
- package/types/components/GitHubCorner.d.ts +0 -4
- package/types/is-mobile.d.ts +0 -6
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-fr-FR-json-79fa555bfea0a356f393.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-fr-FR-json-97d3c042d3a35ef178f1.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-157ae036fcf470528687.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-2636e07fd8cc89d175d9.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-d006423b531ab062bb85.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-he-IL-json-faa97890de44ed584a45.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-15259c14d6c8090e6041.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-3035c3b3ab3ce981dbc7.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-4f59e58d6a805face4bc.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hi-IN-json-d959b869453c591a8861.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-50a13e322a60bb701615.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-83f954e3c1e57b6fd4f2.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-96eea4d71b4795e36e1c.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-hu-HU-json-a366989217753fe3d02b.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-5403b38ac77691c5eca4.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-87212daac6113b5bf808.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-8d13d29ee41be15a1f99.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-id-ID-json-9c439203bdabe6684608.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-1741b35480eb0defb489.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-32a61d0b3e05b538bf63.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-59f2e9d3dac07f3264cb.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-it-IT-json-90283cd2809f4165506b.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-37ae69a9327343f0df49.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-7780222c69cc877e19a5.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-9e0a78ddb43d5709fb29.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ja-JP-json-ccb5ffd0f8a0980c2ec0.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-1f8d0a51645c871d2289.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-9438814b6f8d2d4bca30.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-d9acc7b8ee952e356d06.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kab-KAB-json-dac787e0446cdb747fe1.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-kk-KZ-json-c6e1e808c0237fb1c06e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-60158040fc55af420fec.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-d61af373bea59d1ff4c6.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-e42ededaa35032a201b9.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ko-KR-json-f07afc9e756716038f58.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-07f6bffcb44fdd9aad4f.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-0a84813c147df37dafd5.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-lv-LV-json-7eea5c4054f8418fdd10.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-26d1e27bab3b8ac4a3e6.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-8d09c35cfec8011379c5.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-a8f9bb37a7b947e9dfba.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-my-MM-json-b7cafa3196e9247a3744.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-347a7289682a3cd91131.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-7817632f1248c4374b19.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-8ce0749d46f0b4a8defb.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nb-NO-json-c01fab8602e1b658d5d1.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-23fdfd9f11bc8efbaf56.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-51adbd1d4d0bf1d01a7b.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-7bedb9ed0d2a6ce6dbef.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nl-NL-json-cf922daa828029c1aff5.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-b5931de6e1ed336bf087.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-cc3e8135a35bc8f98708.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-d363be6b3dcdbf3a868a.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-nn-NO-json-f5f8364c660de496ad5e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-29d6193adb907d4f5890.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-5d63281a55d45fa9b895.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-7cd0233768ae95a4ff67.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-917cae387efe3c7daa7b.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-oc-FR-json-c6414107ad634b113aba.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-0346c42fd5a76dafe221.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-27063e4865142ac11b1a.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-94904044e3de6d7a03b9.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pa-IN-json-f0c779291da384fb5173.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-16af1b83ac16af57ad07.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-77216f119758846c11a6.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-a4a5c6e0a9877c43476a.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pl-PL-json-fd71968e6ed066a9a7e4.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-03a046855063512eb9ff.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-464cb502a9c0fedb90bc.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-8a2b5677633283f9709d.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-BR-json-db86828d6e3ced9f9854.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-186d1c052145da982c22.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-7b7c90b1b9d2f1c8516b.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-7ed352e9de6dc74ef503.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-9fc68d7dfd57ed065217.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-pt-PT-json-bc0cd589bd87a3079407.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-75692b7a0166d6ad27a4.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-ac25005e74f8dd8d360c.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-bc3b1ac81c49d9f46bc3.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ro-RO-json-f13a2e7b7a63fbfb6ae7.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-69b1a919b7f42adfd6ec.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-7c2a2061d0ca99cf7007.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-d7d997a13f420a4c013f.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-ru-RU-json-ef8daff1f5e8b77e4cad.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-0879aa8d30b34085d3ca.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-0ef09f90308059d22ae8.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-4757551ceb15fa0a29a9.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-a76fdcb6e89ea3e90968.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sk-SK-json-f50495416e3b91a65ed6.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-2fd231ccf2c37b2df52d.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-baf46a1a4335217900ec.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-dc7718d79b9bf93a4ba4.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-sv-SE-json-fa5bd09f128972b13ac2.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-4d087f24f2b782404c82.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-a0167ddcd5781d778bb4.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-a940d18e2fb0ff323575.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-b574833ee1c2f58fd24e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-tr-TR-json-cba7e62d9610795a5ac3.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-5ae9937f0ed82468050e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-a9a8ea7adb95c0a03680.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-f0cab296bdc4089ffa77.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-uk-UA-json-f6fb2e431947fd51c7cd.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-1070e5dfd3c6adf4fe95.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-3333609e8b26b63da65d.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-45da9983459601b845e8.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-CN-json-94f562845a945a45e385.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-08026b081d7dae088759.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-0e77c896018bcd221bf6.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-62dd29f7a9ca5ff7ecde.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/i18n-zh-TW-json-7dd3d9ba72493687c286.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/image-5fe4e27670d5147fb1f2.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/image-eafab0c39ce13f7fea67.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/vendor-5678a46e9c49ae846a9e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/vendor-c4dbf2f5c3b177853c42.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets/vendor-e28bbc4a18db117e244e.d.ts +0 -0
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hi-IN-json-dfd13380f880265721d1.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hi-IN-json-f902998f48c9e940b8b7.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-5e40f12439fdaf31e5f8.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-ada5d1cef817fe19894a.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-b9b0249ff44723872095.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-hu-HU-json-e65692a1c5aebfe5bc81.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-835f87669363ce6e7c70.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-d0fd59d99eb8268ad32d.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-d264f60071587cc03dbc.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-id-ID-json-e8eedd65d1eefcfb47af.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-8a32d12ac801fef52a55.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-8a43a149865c6779fc8e.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-90e37ac7e4f9b56017c8.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-it-IT-json-dc31d253c180bd8bc42c.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-3c9f0500ad7ae95e6331.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-482de550c6b58749e363.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-9bd61e0b60ea12007ec2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ja-JP-json-db2805c4535d81f39148.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-4d3c40103366973ea8e7.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-6ecc1e42c03166ce44c2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-b88f94c29607a0102313.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kab-KAB-json-ca34961870049ab8dc31.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-kk-KZ-json-3c033b44668ea8f33a22.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-66e46599a7674b2c8e4b.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-87c10c8f44988dd0e13a.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-934a52d336cd86c43b15.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ko-KR-json-c88ade101a1937c0c881.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-1a80ea1c8f3354d394cf.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-23fd249423ee6a324e83.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-lv-LV-json-6aaf2bb3aefbce847dfd.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-52026701113f0ab7f523.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-64b5010692f50278902c.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-8a534e22357023f607a4.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-my-MM-json-bfb9dc9b1422cc6ca14e.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-489122304d05e212e873.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-49fa9e922f887d2f60a7.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-b306f0e8dc387da1d79b.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nb-NO-json-f5dde6f364d92ce556dc.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-82e96e181260b8988806.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-b43931c3681d44a32403.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-c1909d14fa3ba5a2776b.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nl-NL-json-df1ade23a540ca746458.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-65d7cb4781c95aef4417.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-6d27231c8f6f5056953c.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-7ec9cc490ddfcebec38a.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-nn-NO-json-8cd74dd7b1f63e23abb0.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-069879d69e9d37f7131f.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-73ae6f9c6fdc4df09309.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-77013b778932c4e50835.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-8d148718b907f1827ff2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-oc-FR-json-d4cec6a3268fab4e3cee.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-5e2e9c3078bfca8530b1.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-649c3a5cc136f4bf90d0.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-7722b4613d295aa2fe1d.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pa-IN-json-cfe2c9217cf01e4702e2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-4a49c6798301bbf50ad1.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-86837d86cca9e22510de.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-d537cb96a3465cf853a2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pl-PL-json-f161c5a49ee47f8e771c.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-715832c0500f14d50107.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-832bd65611c82efb2c59.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-9e5e38e222f73caab707.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-BR-json-e57c8c128e5e4799b5da.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-482e046bcfea32653cf0.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-6b9495717c9da1a29f28.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-8d32158e1b3d0bb5a561.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-cc40c74df3147e2397fd.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-pt-PT-json-d5a3eb8ee8456a57f17b.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-13589d429b0eb2bd6ad7.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-4a2e4f653982cc7b046e.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-5a30a45a0e1df37c54e7.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ro-RO-json-bcbf3b8c2275de0f2a3c.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-2d9fbf7de6605bdecddf.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-9ac76447545318b66e63.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-9e6a7149ce143fb48bf4.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-ru-RU-json-aa92dea266fa031249ca.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-118350b0f0cdc9be21b6.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-2028ec0b65d6eed7403a.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-7a7f7823653192b39c0e.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-f33008479ba846a43320.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sk-SK-json-fd05a3a822b86b5566fc.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-0b0469f979b4abbbd52a.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-104c3ec1c05628a0adc2.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-d45d82c4601f5591f3cd.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-sv-SE-json-fd3b941b3df61ae391a9.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-5abc34c49a78088dc890.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-84336db0450baf5b60b1.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-b486cbc4ab9a99ee37b0.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-eba8c7f5b842181a3696.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-tr-TR-json-fc6af871b929adde7bd8.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-0455e3b621d70d11a5be.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-0a3ab1e3431530135c0e.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-1570a6ac23a753933f82.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-uk-UA-json-c1d4fcf6be7603dcca2d.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-3fe440d4981c65767b68.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-6bb82eee4ed00ddca3a9.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-98deec89f30ce8f46495.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-CN-json-dc0e18b1488087e7e8ac.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-063b4405857a856e2b6d.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-0e9e8f4777ff0435e2c4.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-8dc37e8c1841fe55fc89.d.ts +0 -2
- package/types/packages/excalidraw/dist/excalidraw-assets-dev/i18n-zh-TW-json-a78c1cbb2eaa5ad69af6.d.ts +0 -2
- package/types/packages/excalidraw/postcss.config.d.ts +0 -1
package/README.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
#### Note
|
|
2
|
+
|
|
3
|
+
⚠️ ⚠️ ⚠️ You are viewing the docs for the **next** release, in case you want to check the docs for the stable release, you can view it [here](https://www.npmjs.com/package/@excalidraw/excalidraw).
|
|
4
|
+
|
|
1
5
|
### Excalidraw
|
|
2
6
|
|
|
3
7
|
Excalidraw exported as a component to directly embed in your projects.
|
|
@@ -26,7 +30,7 @@ If you want to load assets from a different path you can set a variable `window.
|
|
|
26
30
|
|
|
27
31
|
#### Note
|
|
28
32
|
|
|
29
|
-
**If you don't want to wait for the next stable release and try out the unreleased changes you can use
|
|
33
|
+
**If you don't want to wait for the next stable release and try out the unreleased changes you can use `@excalidraw/excalidraw@next`.**
|
|
30
34
|
|
|
31
35
|
### Demo
|
|
32
36
|
|
|
@@ -42,7 +46,7 @@ If you are using a Web bundler (for instance, Webpack), you can import it as an
|
|
|
42
46
|
|
|
43
47
|
```js
|
|
44
48
|
import React, { useEffect, useState, useRef } from "react";
|
|
45
|
-
import Excalidraw from "@excalidraw/excalidraw";
|
|
49
|
+
import { Excalidraw } from "@excalidraw/excalidraw";
|
|
46
50
|
import InitialData from "./initialData";
|
|
47
51
|
|
|
48
52
|
import "./styles.scss";
|
|
@@ -322,7 +326,7 @@ const App = () => {
|
|
|
322
326
|
className: "excalidraw-wrapper",
|
|
323
327
|
ref: excalidrawWrapperRef,
|
|
324
328
|
},
|
|
325
|
-
React.createElement(Excalidraw
|
|
329
|
+
React.createElement(ExcalidrawLib.Excalidraw, {
|
|
326
330
|
initialData: InitialData,
|
|
327
331
|
onChange: (elements, state) =>
|
|
328
332
|
console.log("Elements :", elements, "State : ", state),
|
|
@@ -347,12 +351,37 @@ To view the full example visit :point_down:
|
|
|
347
351
|
|
|
348
352
|
</details>
|
|
349
353
|
|
|
354
|
+
### Customizing styles
|
|
355
|
+
|
|
356
|
+
Excalidraw is using CSS variables to style certain components. To override them, you should set your own on the `.excalidraw` and `.excalidraw.theme--dark` (for dark mode variables) selectors.
|
|
357
|
+
|
|
358
|
+
Make sure the selector has higher specificity, e.g. by prefixing it with your app's selector:
|
|
359
|
+
|
|
360
|
+
```css
|
|
361
|
+
.your-app .excalidraw {
|
|
362
|
+
--color-primary: red;
|
|
363
|
+
}
|
|
364
|
+
.your-app .excalidraw.theme--dark {
|
|
365
|
+
--color-primary: pink;
|
|
366
|
+
}
|
|
367
|
+
```
|
|
368
|
+
|
|
369
|
+
Most notably, you can customize the primary colors, by overriding these variables:
|
|
370
|
+
|
|
371
|
+
- `--color-primary`
|
|
372
|
+
- `--color-primary-darker`
|
|
373
|
+
- `--color-primary-darkest`
|
|
374
|
+
- `--color-primary-light`
|
|
375
|
+
- `--color-primary-contrast-offset` — a slightly darker (in light mode), or lighter (in dark mode) `--color-primary` color to fix contrast issues (see [Chubb illusion](https://en.wikipedia.org/wiki/Chubb_illusion)). It will fall back to `--color-primary` if not present.
|
|
376
|
+
|
|
377
|
+
For a complete list of variables, check [theme.scss](https://github.com/excalidraw/excalidraw/blob/master/src/css/theme.scss), though most of them will not make sense to override.
|
|
378
|
+
|
|
350
379
|
### Props
|
|
351
380
|
|
|
352
381
|
| Name | Type | Default | Description |
|
|
353
382
|
| --- | --- | --- | --- |
|
|
354
383
|
| [`onChange`](#onChange) | Function | | This callback is triggered whenever the component updates due to any change. This callback will receive the excalidraw elements and the current app state. |
|
|
355
|
-
| [`initialData`](#initialData) | <pre>{elements?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
384
|
+
| [`initialData`](#initialData) | <pre>{elements?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>, appState?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState<a> } </pre> | null | The initial data with which app loads. |
|
|
356
385
|
| [`ref`](#ref) | [`createRef`](https://reactjs.org/docs/refs-and-the-dom.html#creating-refs) | [`useRef`](https://reactjs.org/docs/hooks-reference.html#useref) | [`callbackRef`](https://reactjs.org/docs/refs-and-the-dom.html#callback-refs) | <pre>{ current: { readyPromise: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/utils.ts#L317">resolvablePromise</a> } }</pre> | | Ref to be passed to Excalidraw |
|
|
357
386
|
| [`onCollabButtonClick`](#onCollabButtonClick) | Function | | Callback to be triggered when the collab button is clicked |
|
|
358
387
|
| [`isCollaborating`](#isCollaborating) | `boolean` | | This implies if the app is in collaboration mode |
|
|
@@ -365,14 +394,18 @@ To view the full example visit :point_down:
|
|
|
365
394
|
| [`zenModeEnabled`](#zenModeEnabled) | boolean | | This implies if the zen mode is enabled |
|
|
366
395
|
| [`gridModeEnabled`](#gridModeEnabled) | boolean | | This implies if the grid mode is enabled |
|
|
367
396
|
| [`libraryReturnUrl`](#libraryReturnUrl) | string | | What URL should [libraries.excalidraw.com](https://libraries.excalidraw.com) be installed to |
|
|
368
|
-
| [`theme`](#theme) |
|
|
397
|
+
| [`theme`](#theme) | [THEME.LIGHT](#THEME-1) | [THEME.LIGHT](#THEME-1) | [THEME.LIGHT](#THEME-1) | The theme of the Excalidraw component |
|
|
369
398
|
| [`name`](#name) | string | | Name of the drawing |
|
|
370
399
|
| [`UIOptions`](#UIOptions) | <pre>{ canvasActions: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L208"> CanvasActions<a/> }</pre> | [DEFAULT UI OPTIONS](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L129) | To customise UI options. Currently we support customising [`canvas actions`](#canvasActions) |
|
|
371
|
-
| [`onPaste`](#onPaste) | <pre>(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#
|
|
400
|
+
| [`onPaste`](#onPaste) | <pre>(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L21">ClipboardData</a>, event: ClipboardEvent | null) => boolean</pre> | | Callback to be triggered if passed when the something is pasted in to the scene |
|
|
372
401
|
| [`detectScroll`](#detectScroll) | boolean | true | Indicates whether to update the offsets when nearest ancestor is scrolled. |
|
|
373
402
|
| [`handleKeyboardGlobally`](#handleKeyboardGlobally) | boolean | false | Indicates whether to bind the keyboard events to document. |
|
|
374
403
|
| [`onLibraryChange`](#onLibraryChange) | <pre>(items: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => void | Promise<any> </pre> | | The callback if supplied is triggered when the library is updated and receives the library items. |
|
|
375
404
|
| [`autoFocus`](#autoFocus) | boolean | false | Implies whether to focus the Excalidraw component on page load |
|
|
405
|
+
| [`generateIdForFile`](#generateIdForFile) | `(file: File) => string | Promise<string>` | Allows you to override `id` generation for files added on canvas |
|
|
406
|
+
| [`onLinkOpen`](#onLinkOpen) | <pre>(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">NonDeletedExcalidrawElement</a>, event: CustomEvent) </pre> | | This prop if passed will be triggered when link of an element is clicked. |
|
|
407
|
+
| [`onPointerDown`](#onPointerDown) | <pre>(activeTool: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L93"> AppState["activeTool"]</a>, pointerDownState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L365">PointerDownState</a>) => void</pre> | | This prop if passed gets triggered on pointer down evenets |
|
|
408
|
+
| [`onScrollChange`](#onScrollChange) | (scrollX: number, scrollY: number) | | This prop if passed gets triggered when scrolling the canvas. |
|
|
376
409
|
|
|
377
410
|
### Dimensions of Excalidraw
|
|
378
411
|
|
|
@@ -383,12 +416,14 @@ Excalidraw takes `100%` of `width` and `height` of the containing block so make
|
|
|
383
416
|
Every time component updates, this callback if passed will get triggered and has the below signature.
|
|
384
417
|
|
|
385
418
|
```js
|
|
386
|
-
(excalidrawElements, appState) => void;
|
|
419
|
+
(excalidrawElements, appState, files) => void;
|
|
387
420
|
```
|
|
388
421
|
|
|
389
|
-
1.`excalidrawElements`: Array of [excalidrawElements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
422
|
+
1.`excalidrawElements`: Array of [excalidrawElements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) in the scene.
|
|
390
423
|
|
|
391
|
-
2.`appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
424
|
+
2.`appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) of the scene.
|
|
425
|
+
|
|
426
|
+
3. `files`: The [`BinaryFiles`]([BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64) which are added to the scene.
|
|
392
427
|
|
|
393
428
|
Here you can try saving the data to your backend or local storage for example.
|
|
394
429
|
|
|
@@ -396,12 +431,13 @@ Here you can try saving the data to your backend or local storage for example.
|
|
|
396
431
|
|
|
397
432
|
This helps to load Excalidraw with `initialData`. It must be an object or a [promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/Promise) which resolves to an object containing the below optional fields.
|
|
398
433
|
|
|
399
|
-
| Name | Type |
|
|
434
|
+
| Name | Type | Description |
|
|
400
435
|
| --- | --- | --- |
|
|
401
|
-
| `elements` | [ExcalidrawElement[]](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
402
|
-
| `appState` | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
436
|
+
| `elements` | [ExcalidrawElement[]](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) | The elements with which Excalidraw should be mounted. |
|
|
437
|
+
| `appState` | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) | The App state with which Excalidraw should be mounted. |
|
|
403
438
|
| `scrollToContent` | boolean | This attribute implies whether to scroll to the nearest element to center once Excalidraw is mounted. By default, it will not scroll the nearest element to the center. Make sure you pass `initialData.appState.scrollX` and `initialData.appState.scrollY` when `scrollToContent` is false so that scroll positions are retained |
|
|
404
|
-
| `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
439
|
+
| `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) | Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)> | This library items with which Excalidraw should be mounted. |
|
|
440
|
+
| `files` | [BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64) | The files added to the scene. |
|
|
405
441
|
|
|
406
442
|
```json
|
|
407
443
|
{
|
|
@@ -442,17 +478,23 @@ You can pass a `ref` when you want to access some excalidraw APIs. We expose the
|
|
|
442
478
|
| --- | --- | --- |
|
|
443
479
|
| ready | `boolean` | This is set to true once Excalidraw is rendered |
|
|
444
480
|
| readyPromise | [resolvablePromise](https://github.com/excalidraw/excalidraw/blob/master/src/utils.ts#L317) | This promise will be resolved with the api once excalidraw has rendered. This will be helpful when you want do some action on the host app once this promise resolves. For this to work you will have to pass ref as shown [here](#readyPromise) |
|
|
445
|
-
| [updateScene](#updateScene) | <
|
|
481
|
+
| [updateScene](#updateScene) | <code>(scene: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>) => void </code> | updates the scene with the sceneData |
|
|
482
|
+
| [updateLibrary](#updateLibrary) | <code>(<a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/library.ts#L136">opts</a>) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>> </code> | updates the scene with the sceneData |
|
|
483
|
+
| [addFiles](#addFiles) | <code>(files: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts">BinaryFileData</a>) => void </code> | add files data to the appState |
|
|
446
484
|
| resetScene | `({ resetLoadingState: boolean }) => void` | Resets the scene. If `resetLoadingState` is passed as true then it will also force set the loading state to false. |
|
|
447
|
-
| getSceneElementsIncludingDeleted | <
|
|
448
|
-
| getSceneElements | <
|
|
449
|
-
| getAppState | <
|
|
485
|
+
| getSceneElementsIncludingDeleted | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a></code> | Returns all the elements including the deleted in the scene |
|
|
486
|
+
| getSceneElements | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a></code> | Returns all the elements excluding the deleted in the scene |
|
|
487
|
+
| getAppState | <code> () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L66">AppState</a></code> | Returns current appState |
|
|
450
488
|
| history | `{ clear: () => void }` | This is the history API. `history.clear()` will clear the history |
|
|
451
|
-
| scrollToContent | <
|
|
489
|
+
| scrollToContent | <code> (target?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a> | <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a>[]) => void </code> | Scroll the nearest element out of the elements supplied to the center. Defaults to the elements on the scene. |
|
|
452
490
|
| refresh | `() => void` | Updates the offsets for the Excalidraw component so that the coordinates are computed correctly (for example the cursor position). You don't have to call this when the position is changed on page scroll or when the excalidraw container resizes (we handle that ourselves). For any other cases if the position of excalidraw is updated (example due to scroll on parent container and not page scroll) you should call this API. |
|
|
453
491
|
| [importLibrary](#importlibrary) | `(url: string, token?: string) => void` | Imports library from given URL |
|
|
454
492
|
| setToastMessage | `(message: string) => void` | This API can be used to show the toast with custom message. |
|
|
455
493
|
| [id](#id) | string | Unique ID for the excalidraw component. |
|
|
494
|
+
| [getFiles](#getFiles) | <code>() => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64">files</a> </code> | This API can be used to get the files present in the scene. It may contain files that aren't referenced by any element, so if you're persisting the files to a storage, you should compare them against stored elements. |
|
|
495
|
+
| [setActiveTool](#setActiveTool) | <code>(tool: { type: typeof <a href="https://github.com/excalidraw/excalidraw/blob/master/src/shapes.tsx#L4">SHAPES</a>[number]["value"] | "eraser" } | { type: "custom"; customType: string }) => void</code> | This API can be used to set the active tool |
|
|
496
|
+
| [setCursor](#setCursor) | <code>(cursor: string) => void </code> | This API can be used to set customise the mouse cursor on the canvas |
|
|
497
|
+
| [resetCursor](#resetCursor) | <code>() => void </code> | This API can be used to reset to default mouse cursor on the canvas |
|
|
456
498
|
|
|
457
499
|
#### `readyPromise`
|
|
458
500
|
|
|
@@ -465,7 +507,7 @@ Since plain object is passed as a `ref`, the `readyPromise` is resolved as soon
|
|
|
465
507
|
### `updateScene`
|
|
466
508
|
|
|
467
509
|
<pre>
|
|
468
|
-
(<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>)
|
|
510
|
+
(scene: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L207">sceneData</a>) => void
|
|
469
511
|
</pre>
|
|
470
512
|
|
|
471
513
|
You can use this function to update the scene with the sceneData. It accepts the below attributes.
|
|
@@ -474,8 +516,37 @@ You can use this function to update the scene with the sceneData. It accepts the
|
|
|
474
516
|
| --- | --- | --- |
|
|
475
517
|
| `elements` | [`ImportedDataState["elements"]`](https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17) | The `elements` to be updated in the scene |
|
|
476
518
|
| `appState` | [`ImportedDataState["appState"]`](https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L18) | The `appState` to be updated in the scene. |
|
|
477
|
-
| `collaborators` | <pre>Map<string, <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
519
|
+
| `collaborators` | <pre>Map<string, <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L35">Collaborator></a></pre> | The list of collaborators to be updated in the scene. |
|
|
478
520
|
| `commitToHistory` | `boolean` | Implies if the `history (undo/redo)` should be recorded. Defaults to `false`. |
|
|
521
|
+
| `libraryItems` | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) | Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)> | ((currentItems: [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)>) => [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200) | Promise<[LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200)>) | The `libraryItems` to be update in the scene. |
|
|
522
|
+
|
|
523
|
+
### `updateLibrary`
|
|
524
|
+
|
|
525
|
+
<pre>
|
|
526
|
+
(opts: {
|
|
527
|
+
libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224">LibraryItemsSource</a>;
|
|
528
|
+
merge?: boolean;
|
|
529
|
+
prompt?: boolean;
|
|
530
|
+
openLibraryMenu?: boolean;
|
|
531
|
+
defaultStatus?: "unpublished" | "published";
|
|
532
|
+
}) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>>
|
|
533
|
+
</pre>
|
|
534
|
+
|
|
535
|
+
You can use this function to update the library. It accepts the below attributes.
|
|
536
|
+
|
|
537
|
+
| Name | Type | Default | Description |
|
|
538
|
+
| --- | --- | --- | --- |
|
|
539
|
+
| `libraryItems` | | [LibraryItems](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224) | The `libraryItems` to be replaced/merged with current library |
|
|
540
|
+
| `merge` | boolean | `false` | Whether to merge with existing library items. |
|
|
541
|
+
| `prompt` | boolean | `false` | Whether to prompt user for confirmation. |
|
|
542
|
+
| `openLibraryMenu` | boolean | `false` | Whether to open the library menu before importing. |
|
|
543
|
+
| `defaultStatus` | <code>"unpublished" | "published"</code> | `"unpublished"` | Default library item's `status` if not present. |
|
|
544
|
+
|
|
545
|
+
### `addFiles`
|
|
546
|
+
|
|
547
|
+
<pre>(files: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts">BinaryFileData</a>) => void </pre>
|
|
548
|
+
|
|
549
|
+
Adds supplied files data to the `appState.files` cache on top of existing files present in the cache.
|
|
479
550
|
|
|
480
551
|
#### `onCollabButtonClick`
|
|
481
552
|
|
|
@@ -504,7 +575,7 @@ This callback is triggered when mouse pointer is updated.
|
|
|
504
575
|
```
|
|
505
576
|
|
|
506
577
|
1. `exportedElements`: An array of [non deleted elements](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L87) which needs to be exported.
|
|
507
|
-
2. `appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
578
|
+
2. `appState`: [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) of the scene.
|
|
508
579
|
3. `canvas`: The `HTMLCanvasElement` of the scene.
|
|
509
580
|
|
|
510
581
|
#### `langCode`
|
|
@@ -523,7 +594,7 @@ import { defaultLang, languages } from "@excalidraw/excalidraw";
|
|
|
523
594
|
#### `renderTopRightUI`
|
|
524
595
|
|
|
525
596
|
<pre>
|
|
526
|
-
(isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
597
|
+
(isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>) => JSX | null
|
|
527
598
|
</pre>
|
|
528
599
|
|
|
529
600
|
A function returning JSX to render custom UI in the top right corner of the app.
|
|
@@ -531,7 +602,7 @@ A function returning JSX to render custom UI in the top right corner of the app.
|
|
|
531
602
|
#### `renderFooter`
|
|
532
603
|
|
|
533
604
|
<pre>
|
|
534
|
-
(isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
605
|
+
(isMobile: boolean, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>) => JSX | null
|
|
535
606
|
</pre>
|
|
536
607
|
|
|
537
608
|
A function returning JSX to render custom UI footer. For example, you can use this to render a language picker that was previously being rendered by Excalidraw itself (for now, you'll need to implement your own language picker).
|
|
@@ -558,7 +629,7 @@ If supplied, this URL will be used when user tries to install a library from [li
|
|
|
558
629
|
|
|
559
630
|
#### `theme`
|
|
560
631
|
|
|
561
|
-
This prop controls Excalidraw's theme. When supplied, the value takes precedence over `intialData.appState.theme`, the theme will be fully controlled by the host app, and users won't be able to toggle it from within the app.
|
|
632
|
+
This prop controls Excalidraw's theme. When supplied, the value takes precedence over `intialData.appState.theme`, the theme will be fully controlled by the host app, and users won't be able to toggle it from within the app. You can use [`THEME`](#THEME-1) to specify the theme.
|
|
562
633
|
|
|
563
634
|
#### `name`
|
|
564
635
|
|
|
@@ -566,7 +637,7 @@ This prop sets the name of the drawing which will be used when exporting the dra
|
|
|
566
637
|
|
|
567
638
|
#### `UIOptions`
|
|
568
639
|
|
|
569
|
-
This prop can be used to customise UI of Excalidraw. Currently we support customising
|
|
640
|
+
This prop can be used to customise UI of Excalidraw. Currently we support customising [`canvasActions`](#canvasActions) and [`dockedSidebarBreakpoint`](dockedSidebarBreakpoint). It accepts the below parameters
|
|
570
641
|
|
|
571
642
|
<pre>
|
|
572
643
|
{ canvasActions: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L208"> CanvasActions<a/> }
|
|
@@ -584,6 +655,12 @@ This prop can be used to customise UI of Excalidraw. Currently we support custom
|
|
|
584
655
|
| `theme` | boolean | true | Implies whether to show `Theme toggle` |
|
|
585
656
|
| `saveAsImage` | boolean | true | Implies whether to show `Save as image button` |
|
|
586
657
|
|
|
658
|
+
##### `dockedSidebarBreakpoint`
|
|
659
|
+
|
|
660
|
+
This prop indicates at what point should we break to a docked, permanent sidebar. If not passed it defaults to [`MQ_RIGHT_SIDEBAR_MAX_WIDTH_PORTRAIT`](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L167). If the `width` of the `excalidraw` container exceeds `dockedSidebarBreakpoint`, the sidebar will be dockable. If user choses to dock the sidebar, it will push the right part of the UI towards the left, making space for the sidebar as shown below.
|
|
661
|
+
|
|
662
|
+

|
|
663
|
+
|
|
587
664
|
#### `exportOpts`
|
|
588
665
|
|
|
589
666
|
The below attributes can be set in `UIOptions.canvasActions.export` to customize the export dialog. If `UIOptions.canvasActions.export` is `false` the export button will not be rendered.
|
|
@@ -591,7 +668,7 @@ The below attributes can be set in `UIOptions.canvasActions.export` to customize
|
|
|
591
668
|
| Attribute | Type | Default | Description |
|
|
592
669
|
| --- | --- | --- | --- |
|
|
593
670
|
| `saveFileToDisk` | boolean | true | Implies if save file to disk button should be shown |
|
|
594
|
-
| `
|
|
671
|
+
| `onExportToBackend` | <pre> (exportedElements: readonly NonDeletedExcalidrawElement[],appState: AppState,canvas: HTMLCanvasElement | null) => void </pre> | | This callback is triggered when the shareable-link button is clicked in the export dialog. The link button will only be shown if this callback is passed. |
|
|
595
672
|
| `renderCustomUI` | <pre> (exportedElements: readonly NonDeletedExcalidrawElement[],appState: AppState,canvas: HTMLCanvasElement | null) => void </pre> | | This callback should be supplied if you want to render custom UI in the export dialog. |
|
|
596
673
|
|
|
597
674
|
#### `onPaste`
|
|
@@ -599,18 +676,14 @@ The below attributes can be set in `UIOptions.canvasActions.export` to customize
|
|
|
599
676
|
This callback is triggered if passed when something is pasted into the scene. You can use this callback in case you want to do something additional when the paste event occurs.
|
|
600
677
|
|
|
601
678
|
<pre>
|
|
602
|
-
(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#
|
|
679
|
+
(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/clipboard.ts#L21">ClipboardData</a>, event: ClipboardEvent | null) => boolean
|
|
603
680
|
</pre>
|
|
604
681
|
|
|
605
682
|
This callback must return a `boolean` value or a [promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/Promise) which resolves to a boolean value.
|
|
606
683
|
|
|
607
|
-
In case you want to prevent the excalidraw paste action you must return `
|
|
684
|
+
In case you want to prevent the excalidraw paste action you must return `false`, it will stop the native excalidraw clipboard management flow (nothing will be pasted into the scene).
|
|
608
685
|
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
No, Excalidraw package doesn't come with collaboration built in, since the implementation is specific to each host app. We expose APIs which you can use to communicate with Excalidraw which you can use to implement it. You can check our own implementation [here](https://github.com/excalidraw/excalidraw/blob/master/src/excalidraw-app/index.tsx).
|
|
612
|
-
|
|
613
|
-
### importLibrary
|
|
686
|
+
#### `importLibrary`
|
|
614
687
|
|
|
615
688
|
Imports library from given URL. You should call this on `hashchange`, passing the `addLibrary` value if you detect it as shown below. Optionally pass a CSRF `token` to skip prompting during installation (retrievable via `token` key from the url coming from [https://libraries.excalidraw.com](https://libraries.excalidraw.com/)).
|
|
616
689
|
|
|
@@ -632,19 +705,39 @@ useEffect(() => {
|
|
|
632
705
|
|
|
633
706
|
Try out the [Demo](#Demo) to see it in action.
|
|
634
707
|
|
|
635
|
-
|
|
708
|
+
#### `setActiveTool`
|
|
709
|
+
|
|
710
|
+
This API has the below signature. It sets the `tool` passed in param as the active tool.
|
|
711
|
+
|
|
712
|
+
<pre>
|
|
713
|
+
(tool: { type: typeof <a href="https://github.com/excalidraw/excalidraw/blob/master/src/shapes.tsx#L4">SHAPES</a>[number]["value"] | "eraser" } | { type: "custom"; customType: string }) => void
|
|
714
|
+
</pre>
|
|
715
|
+
|
|
716
|
+
#### `setCursor`
|
|
717
|
+
|
|
718
|
+
This API can be used to customise the mouse cursor on the canvas and has the below signature. It sets the mouse cursor to the cursor passed in param.
|
|
719
|
+
|
|
720
|
+
<pre>
|
|
721
|
+
(cursor: string) => void
|
|
722
|
+
</pre>
|
|
723
|
+
|
|
724
|
+
#### `resetCursor`
|
|
725
|
+
|
|
726
|
+
This API can be used to reset to default mouse cursor.
|
|
727
|
+
|
|
728
|
+
#### `detectScroll`
|
|
636
729
|
|
|
637
730
|
Indicates whether Excalidraw should listen for `scroll` event on the nearest scrollable container in the DOM tree and recompute the coordinates (e.g. to correctly handle the cursor) when the component's position changes. You can disable this when you either know this doesn't affect your app or you want to take care of it yourself (calling the [`refresh()`](#ref) method).
|
|
638
731
|
|
|
639
|
-
|
|
732
|
+
#### `handleKeyboardGlobally`
|
|
640
733
|
|
|
641
734
|
Indicates whether to bind keyboard events to `document`. Disabled by default, meaning the keyboard events are bound to the Excalidraw component. This allows for multiple Excalidraw components to live on the same page, and ensures that Excalidraw keyboard handling doesn't collide with your app's (or the browser) when the component isn't focused.
|
|
642
735
|
|
|
643
736
|
Enable this if you want Excalidraw to handle keyboard even if the component isn't focused (e.g. a user is interacting with the navbar, sidebar, or similar).
|
|
644
737
|
|
|
645
|
-
|
|
738
|
+
#### `onLibraryChange`
|
|
646
739
|
|
|
647
|
-
|
|
740
|
+
This callback if supplied will get triggered when the library is updated and has the below signature.
|
|
648
741
|
|
|
649
742
|
<pre>
|
|
650
743
|
(items: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => void | Promise<any>
|
|
@@ -652,58 +745,74 @@ Ths callback if supplied will get triggered when the library is updated and has
|
|
|
652
745
|
|
|
653
746
|
It is invoked with empty items when user clears the library. You can use this callback when you want to do something additional when library is updated for example persisting it to local storage.
|
|
654
747
|
|
|
655
|
-
|
|
748
|
+
#### `id`
|
|
656
749
|
|
|
657
750
|
The unique id of the excalidraw component. This can be used to identify the excalidraw component, for example importing the library items to the excalidraw component from where it was initiated when you have multiple excalidraw components rendered on the same page as shown in [multiple excalidraw demo](https://codesandbox.io/s/multiple-excalidraw-k1xx5).
|
|
658
751
|
|
|
659
|
-
|
|
752
|
+
#### `autoFocus`
|
|
660
753
|
|
|
661
754
|
This prop implies whether to focus the Excalidraw component on page load. Defaults to false.
|
|
662
755
|
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
#### `getSceneVersion`
|
|
666
|
-
|
|
667
|
-
**How to use**
|
|
668
|
-
|
|
669
|
-
<pre>
|
|
670
|
-
import { getSceneVersion } from "@excalidraw/excalidraw";
|
|
671
|
-
getSceneVersion(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>)
|
|
672
|
-
</pre>
|
|
756
|
+
#### `generateIdForFile`
|
|
673
757
|
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
#### `isInvisiblySmallElement`
|
|
758
|
+
Allows you to override `id` generation for files added on canvas (images). By default, an SHA-1 digest of the file is used.
|
|
677
759
|
|
|
678
|
-
|
|
760
|
+
```
|
|
761
|
+
(file: File) => string | Promise<string>
|
|
762
|
+
```
|
|
679
763
|
|
|
680
|
-
|
|
681
|
-
isInvisiblySmallElement(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement</a>): boolean
|
|
682
|
-
</pre>
|
|
764
|
+
#### `onLinkOpen`
|
|
683
765
|
|
|
684
|
-
|
|
766
|
+
This prop if passed will be triggered when clicked on link. To handle the redirect yourself (such as when using your own router for internal links), you must call `event.preventDefault()`.
|
|
685
767
|
|
|
686
|
-
```
|
|
687
|
-
|
|
768
|
+
```
|
|
769
|
+
(element: ExcalidrawElement, event: CustomEvent<{ nativeEvent: MouseEvent }>) => void
|
|
688
770
|
```
|
|
689
771
|
|
|
690
|
-
|
|
772
|
+
Example:
|
|
773
|
+
|
|
774
|
+
```ts
|
|
775
|
+
const history = useHistory();
|
|
776
|
+
|
|
777
|
+
// open internal links using the app's router, but opens external links in
|
|
778
|
+
// a new tab/window
|
|
779
|
+
const onLinkOpen: ExcalidrawProps["onLinkOpen"] = useCallback(
|
|
780
|
+
(element, event) => {
|
|
781
|
+
const link = element.link;
|
|
782
|
+
const { nativeEvent } = event.detail;
|
|
783
|
+
const isNewTab = nativeEvent.ctrlKey || nativeEvent.metaKey;
|
|
784
|
+
const isNewWindow = nativeEvent.shiftKey;
|
|
785
|
+
const isInternalLink =
|
|
786
|
+
link.startsWith("/") || link.includes(window.location.origin);
|
|
787
|
+
if (isInternalLink && !isNewTab && !isNewWindow) {
|
|
788
|
+
history.push(link.replace(window.location.origin, ""));
|
|
789
|
+
// signal that we're handling the redirect ourselves
|
|
790
|
+
event.preventDefault();
|
|
791
|
+
}
|
|
792
|
+
},
|
|
793
|
+
[history],
|
|
794
|
+
);
|
|
795
|
+
```
|
|
691
796
|
|
|
692
|
-
#### `
|
|
797
|
+
#### `onPointerDown`
|
|
693
798
|
|
|
694
|
-
|
|
799
|
+
This prop if passed will be triggered on pointer down events and has the below signature.
|
|
695
800
|
|
|
696
801
|
<pre>
|
|
697
|
-
|
|
802
|
+
(activeTool: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L93"> AppState["activeTool"]</a>, pointerDownState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L365">PointerDownState</a>) => void
|
|
698
803
|
</pre>
|
|
699
804
|
|
|
700
|
-
|
|
805
|
+
#### `onScrollChange`
|
|
701
806
|
|
|
702
|
-
|
|
703
|
-
|
|
807
|
+
This prop if passed will be triggered when canvas is scrolled and has the below signature.
|
|
808
|
+
|
|
809
|
+
```ts
|
|
810
|
+
(scrollX: number, scrollY: number) => void
|
|
704
811
|
```
|
|
705
812
|
|
|
706
|
-
|
|
813
|
+
### Does it support collaboration ?
|
|
814
|
+
|
|
815
|
+
No, Excalidraw package doesn't come with collaboration built in, since the implementation is specific to each host app. We expose APIs which you can use to communicate with Excalidraw which you can use to implement it. You can check our own implementation [here](https://github.com/excalidraw/excalidraw/blob/master/src/excalidraw-app/index.tsx).
|
|
707
816
|
|
|
708
817
|
### Restore utilities
|
|
709
818
|
|
|
@@ -712,7 +821,7 @@ This function returns an object where each element is mapped to its id.
|
|
|
712
821
|
**_Signature_**
|
|
713
822
|
|
|
714
823
|
<pre>
|
|
715
|
-
restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17">ImportedDataState["appState"]</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
824
|
+
restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L17">ImportedDataState["appState"]</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>> | null): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>
|
|
716
825
|
</pre>
|
|
717
826
|
|
|
718
827
|
**_How to use_**
|
|
@@ -721,7 +830,7 @@ restoreAppState(appState: <a href="https://github.com/excalidraw/excalidraw/blob
|
|
|
721
830
|
import { restoreAppState } from "@excalidraw/excalidraw";
|
|
722
831
|
```
|
|
723
832
|
|
|
724
|
-
This function will make sure all the keys have appropriate values in [appState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
833
|
+
This function will make sure all the keys have appropriate values in [appState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) and if any key is missing, it will be set to default value.
|
|
725
834
|
|
|
726
835
|
When `localAppState` is supplied, it's used in place of values that are missing (`undefined`) in `appState` instead of defaults. Use this as a way to not override user's defaults if you persist them. Required: supply `null`/`undefined` if not applicable.
|
|
727
836
|
|
|
@@ -730,7 +839,7 @@ When `localAppState` is supplied, it's used in place of values that are missing
|
|
|
730
839
|
**_Signature_**
|
|
731
840
|
|
|
732
841
|
<pre>
|
|
733
|
-
restoreElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ImportedDataState["elements"]</a>, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
842
|
+
restoreElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ImportedDataState["elements"]</a>, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>
|
|
734
843
|
</pre>
|
|
735
844
|
|
|
736
845
|
**_How to use_**
|
|
@@ -748,7 +857,7 @@ When `localElements` are supplied, they are used to ensure that existing restore
|
|
|
748
857
|
**_Signature_**
|
|
749
858
|
|
|
750
859
|
<pre>
|
|
751
|
-
restoreElements(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L12">ImportedDataState</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
860
|
+
restoreElements(data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L12">ImportedDataState</a>, localAppState: Partial<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>> | null | undefined, localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L16">ExcalidrawElement[]</a> | null | undefined): <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L4">DataState</a>
|
|
752
861
|
</pre>
|
|
753
862
|
|
|
754
863
|
See [`restoreAppState()`](https://github.com/excalidraw/excalidraw/blob/master/src/packages/excalidraw/README.md#restoreAppState) about `localAppState`, and [`restoreElements()`](https://github.com/excalidraw/excalidraw/blob/master/src/packages/excalidraw/README.md#restoreElements) about `localElements`.
|
|
@@ -761,18 +870,23 @@ import { restore } from "@excalidraw/excalidraw";
|
|
|
761
870
|
|
|
762
871
|
This function makes sure elements and state is set to appropriate values and set to default value if not present. It is a combination of [restoreElements](#restoreElements) and [restoreAppState](#restoreAppState).
|
|
763
872
|
|
|
764
|
-
#### `
|
|
873
|
+
#### `restoreLibraryItems`
|
|
765
874
|
|
|
766
875
|
**_Signature_**
|
|
767
876
|
|
|
768
877
|
<pre>
|
|
769
|
-
|
|
770
|
-
elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L78">ExcalidrawElement[]</a>,
|
|
771
|
-
appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L42">AppState</a>,
|
|
772
|
-
}): string
|
|
878
|
+
restoreLibraryItems(libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L22">ImportedDataState["libraryItems"]</a>, defaultStatus: "published" | "unpublished")
|
|
773
879
|
</pre>
|
|
774
880
|
|
|
775
|
-
|
|
881
|
+
**_How to use_**
|
|
882
|
+
|
|
883
|
+
```js
|
|
884
|
+
import { restoreLibraryItems } from "@excalidraw/excalidraw";
|
|
885
|
+
|
|
886
|
+
restoreLibraryItems(libraryItems, "unpublished");
|
|
887
|
+
```
|
|
888
|
+
|
|
889
|
+
This function normalizes library items elements, adding missing values when needed.
|
|
776
890
|
|
|
777
891
|
### Export utilities
|
|
778
892
|
|
|
@@ -785,14 +899,17 @@ Takes the scene elements and state and returns a JSON string. Deleted `elements`
|
|
|
785
899
|
elements,
|
|
786
900
|
appState
|
|
787
901
|
getDimensions,
|
|
788
|
-
|
|
902
|
+
files
|
|
903
|
+
}: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L12">ExportOpts</a>
|
|
789
904
|
</pre>
|
|
790
905
|
|
|
791
906
|
| Name | Type | Default | Description |
|
|
792
907
|
| --- | --- | --- | --- |
|
|
793
908
|
| elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types) | | The elements to be exported to canvas |
|
|
794
909
|
| appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L12) | [defaultAppState](https://github.com/excalidraw/excalidraw/blob/master/src/appState.ts#L11) | The app state of the scene |
|
|
795
|
-
| getDimensions | `(width: number, height: number) => {width: number, height: number, scale
|
|
910
|
+
| getDimensions | `(width: number, height: number) => { width: number, height: number, scale?: number }` | undefined | A function which returns the `width`, `height`, and optionally `scale` (defaults `1`), with which canvas is to be exported. |
|
|
911
|
+
| maxWidthOrHeight | `number` | undefined | The maximum width or height of the exported image. If provided, `getDimensions` is ignored. |
|
|
912
|
+
| files | [BinaryFiles](The [`BinaryFiles`](<[BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64)>) | undefined | The files added to the scene. |
|
|
796
913
|
|
|
797
914
|
**How to use**
|
|
798
915
|
|
|
@@ -808,7 +925,7 @@ This function returns the canvas with the exported elements, appState and dimens
|
|
|
808
925
|
|
|
809
926
|
<pre>
|
|
810
927
|
exportToBlob(
|
|
811
|
-
opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#
|
|
928
|
+
opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L14">ExportOpts</a> & {
|
|
812
929
|
mimeType?: string,
|
|
813
930
|
quality?: number;
|
|
814
931
|
})
|
|
@@ -834,21 +951,51 @@ Returns a promise which resolves with a [blob](https://developer.mozilla.org/en-
|
|
|
834
951
|
|
|
835
952
|
<pre>
|
|
836
953
|
exportToSvg({
|
|
837
|
-
elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
838
|
-
appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
954
|
+
elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>,
|
|
955
|
+
appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>,
|
|
839
956
|
exportPadding?: number,
|
|
840
957
|
metadata?: string,
|
|
958
|
+
files?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64">BinaryFiles</a>
|
|
841
959
|
})
|
|
842
960
|
</pre>
|
|
843
961
|
|
|
844
962
|
| Name | Type | Default | Description |
|
|
845
963
|
| --- | --- | --- | --- |
|
|
846
|
-
| elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#
|
|
847
|
-
| appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#
|
|
964
|
+
| elements | [Excalidraw Element []](https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106) | | The elements to exported as svg |
|
|
965
|
+
| appState | [AppState](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79) | [defaultAppState](https://github.com/excalidraw/excalidraw/blob/master/src/appState.ts#L11) | The app state of the scene |
|
|
848
966
|
| exportPadding | number | 10 | The padding to be added on canvas |
|
|
967
|
+
| files | [BinaryFiles](The [`BinaryFiles`](<[BinaryFiles](https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L64)>) | undefined | The files added to the scene. |
|
|
849
968
|
|
|
850
969
|
This function returns a promise which resolves to svg of the exported drawing.
|
|
851
970
|
|
|
971
|
+
#### `exportToClipboard`
|
|
972
|
+
|
|
973
|
+
**_Signature_**
|
|
974
|
+
|
|
975
|
+
<pre>
|
|
976
|
+
exportToClipboard(
|
|
977
|
+
opts: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/packages/utils.ts#L14">ExportOpts</a> & {
|
|
978
|
+
mimeType?: string,
|
|
979
|
+
quality?: number;
|
|
980
|
+
type: 'png' | 'svg' |'json'
|
|
981
|
+
})
|
|
982
|
+
</pre>
|
|
983
|
+
|
|
984
|
+
| Name | Type | Default | Description |
|
|
985
|
+
| --- | --- | --- | --- | --- | --- |
|
|
986
|
+
| opts | | | This param is same as the params passed to `exportToCanvas`. You can refer to [`exportToCanvas`](#exportToCanvas). |
|
|
987
|
+
| mimeType | string | "image/png" | Indicates the image format, this will be used when exporting as `png`. |
|
|
988
|
+
| quality | number | 0.92 | A value between 0 and 1 indicating the [image quality](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob#parameters). Applies only to `image/jpeg`/`image/webp` MIME types. This will be used when exporting as `png`. |
|
|
989
|
+
| type | 'png' | 'svg' | 'json' | | This determines the format to which the scene data should be exported. |
|
|
990
|
+
|
|
991
|
+
**How to use**
|
|
992
|
+
|
|
993
|
+
```js
|
|
994
|
+
import { exportToClipboard } from "@excalidraw/excalidraw";
|
|
995
|
+
```
|
|
996
|
+
|
|
997
|
+
Copies the scene data in the specified format (determined by `type`) to clipboard.
|
|
998
|
+
|
|
852
999
|
##### Additional attributes of appState for `export\*` APIs
|
|
853
1000
|
|
|
854
1001
|
| Name | Type | Default | Description |
|
|
@@ -856,27 +1003,66 @@ This function returns a promise which resolves to svg of the exported drawing.
|
|
|
856
1003
|
| exportBackground | boolean | true | Indicates whether background should be exported |
|
|
857
1004
|
| viewBackgroundColor | string | #fff | The default background color |
|
|
858
1005
|
| exportWithDarkMode | boolean | false | Indicates whether to export with dark mode |
|
|
859
|
-
| exportEmbedScene | boolean | false | Indicates whether scene data should be embedded in svg. This will increase the
|
|
1006
|
+
| exportEmbedScene | boolean | false | Indicates whether scene data should be embedded in svg/png. This will increase the image size. |
|
|
1007
|
+
|
|
1008
|
+
### Extra API's
|
|
1009
|
+
|
|
1010
|
+
#### `serializeAsJSON`
|
|
1011
|
+
|
|
1012
|
+
**_Signature_**
|
|
1013
|
+
|
|
1014
|
+
<pre>
|
|
1015
|
+
serializeAsJSON({
|
|
1016
|
+
elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>,
|
|
1017
|
+
appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>,
|
|
1018
|
+
}): string
|
|
1019
|
+
</pre>
|
|
1020
|
+
|
|
1021
|
+
Takes the scene elements and state and returns a JSON string. Deleted `elements`as well as most properties from `AppState` are removed from the resulting JSON. (see [`serializeAsJSON()`](https://github.com/excalidraw/excalidraw/blob/master/src/data/json.ts#L16) source for details).
|
|
1022
|
+
|
|
1023
|
+
If you want to overwrite the source field in the JSON string, you can set `window.EXCALIDRAW_EXPORT_SOURCE` to the desired value.
|
|
860
1024
|
|
|
861
|
-
|
|
1025
|
+
#### `serializeLibraryAsJSON`
|
|
1026
|
+
|
|
1027
|
+
**_Signature_**
|
|
1028
|
+
|
|
1029
|
+
<pre>
|
|
1030
|
+
serializeLibraryAsJSON({
|
|
1031
|
+
libraryItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems[]</a>,
|
|
1032
|
+
</pre>
|
|
1033
|
+
|
|
1034
|
+
Takes the library items and returns a JSON string.
|
|
1035
|
+
|
|
1036
|
+
If you want to overwrite the source field in the JSON string, you can set `window.EXCALIDRAW_EXPORT_SOURCE` to the desired value.
|
|
1037
|
+
|
|
1038
|
+
#### `getSceneVersion`
|
|
862
1039
|
|
|
863
1040
|
**How to use**
|
|
864
1041
|
|
|
865
|
-
|
|
866
|
-
import {
|
|
867
|
-
|
|
1042
|
+
<pre>
|
|
1043
|
+
import { getSceneVersion } from "@excalidraw/excalidraw";
|
|
1044
|
+
getSceneVersion(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a>)
|
|
1045
|
+
</pre>
|
|
868
1046
|
|
|
869
|
-
|
|
1047
|
+
This function returns the current scene version.
|
|
870
1048
|
|
|
871
|
-
|
|
872
|
-
| ----------- | -------------------- |
|
|
873
|
-
| Virgil | The handwritten font |
|
|
874
|
-
| Helvetica | The Normal Font |
|
|
875
|
-
| Cascadia | The Code Font |
|
|
1049
|
+
#### `isInvisiblySmallElement`
|
|
876
1050
|
|
|
877
|
-
|
|
1051
|
+
**_Signature_**
|
|
878
1052
|
|
|
879
|
-
|
|
1053
|
+
<pre>
|
|
1054
|
+
isInvisiblySmallElement(element: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement</a>): boolean
|
|
1055
|
+
</pre>
|
|
1056
|
+
|
|
1057
|
+
**How to use**
|
|
1058
|
+
|
|
1059
|
+
```js
|
|
1060
|
+
import { isInvisiblySmallElement } from "@excalidraw/excalidraw";
|
|
1061
|
+
```
|
|
1062
|
+
|
|
1063
|
+
Returns `true` if element is invisibly small (e.g. width & height are zero).
|
|
1064
|
+
|
|
1065
|
+
#### `loadLibraryFromBlob`
|
|
880
1066
|
|
|
881
1067
|
```js
|
|
882
1068
|
import { loadLibraryFromBlob } from "@excalidraw/excalidraw";
|
|
@@ -890,23 +1076,59 @@ loadLibraryFromBlob(blob: <a href="https://developer.mozilla.org/en-US/docs/Web/
|
|
|
890
1076
|
|
|
891
1077
|
This function loads the library from the blob.
|
|
892
1078
|
|
|
893
|
-
|
|
1079
|
+
#### `loadFromBlob`
|
|
894
1080
|
|
|
895
1081
|
**How to use**
|
|
896
1082
|
|
|
897
1083
|
```js
|
|
898
1084
|
import { loadFromBlob } from "@excalidraw/excalidraw";
|
|
1085
|
+
|
|
1086
|
+
const scene = await loadFromBlob(file, null, null);
|
|
1087
|
+
excalidrawAPI.updateScene(scene);
|
|
899
1088
|
```
|
|
900
1089
|
|
|
901
1090
|
**Signature**
|
|
902
1091
|
|
|
903
1092
|
<pre>
|
|
904
|
-
loadFromBlob(
|
|
1093
|
+
loadFromBlob(
|
|
1094
|
+
blob: <a href="https://developer.mozilla.org/en-US/docs/Web/API/Blob">Blob</a>,
|
|
1095
|
+
localAppState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a> | null,
|
|
1096
|
+
localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a> | null,
|
|
1097
|
+
fileHandle?: FileSystemHandle | null
|
|
1098
|
+
) => Promise<<a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/restore.ts#L53">RestoredDataState</a>>
|
|
905
1099
|
</pre>
|
|
906
1100
|
|
|
907
|
-
This function loads the scene data from the blob. If you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob
|
|
1101
|
+
This function loads the scene data from the blob (or file). If you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob`. Throws if blob doesn't contain valid scene data.
|
|
908
1102
|
|
|
909
|
-
|
|
1103
|
+
#### `loadSceneOrLibraryFromBlob`
|
|
1104
|
+
|
|
1105
|
+
**How to use**
|
|
1106
|
+
|
|
1107
|
+
```js
|
|
1108
|
+
import { loadSceneOrLibraryFromBlob, MIME_TYPES } from "@excalidraw/excalidraw";
|
|
1109
|
+
|
|
1110
|
+
const contents = await loadSceneOrLibraryFromBlob(file, null, null);
|
|
1111
|
+
if (contents.type === MIME_TYPES.excalidraw) {
|
|
1112
|
+
excalidrawAPI.updateScene(contents.data);
|
|
1113
|
+
} else if (contents.type === MIME_TYPES.excalidrawlib) {
|
|
1114
|
+
excalidrawAPI.updateLibrary(contents.data);
|
|
1115
|
+
}
|
|
1116
|
+
```
|
|
1117
|
+
|
|
1118
|
+
**Signature**
|
|
1119
|
+
|
|
1120
|
+
<pre>
|
|
1121
|
+
loadSceneOrLibraryFromBlob(
|
|
1122
|
+
blob: <a href="https://developer.mozilla.org/en-US/docs/Web/API/Blob">Blob</a>,
|
|
1123
|
+
localAppState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a> | null,
|
|
1124
|
+
localElements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L106">ExcalidrawElement[]</a> | null,
|
|
1125
|
+
fileHandle?: FileSystemHandle | null
|
|
1126
|
+
) => Promise<{ type: string, data: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/restore.ts#L53">RestoredDataState</a> | <a href="https://github.com/excalidraw/excalidraw/blob/master/src/data/types.ts#L33">ImportedLibraryState</a>}>
|
|
1127
|
+
</pre>
|
|
1128
|
+
|
|
1129
|
+
This function loads either scene or library data from the supplied blob. If the blob contains scene data, and you pass `localAppState`, `localAppState` value will be preferred over the `appState` derived from `blob`. Throws if blob doesn't contain neither valid scene data or library data.
|
|
1130
|
+
|
|
1131
|
+
#### `getFreeDrawSvgPath`
|
|
910
1132
|
|
|
911
1133
|
**How to use**
|
|
912
1134
|
|
|
@@ -922,6 +1144,220 @@ getFreeDrawSvgPath(element: <a href="https://github.com/excalidraw/excalidraw/bl
|
|
|
922
1144
|
|
|
923
1145
|
This function returns the free draw svg path for the element.
|
|
924
1146
|
|
|
1147
|
+
#### `isLinearElement`
|
|
1148
|
+
|
|
1149
|
+
**How to use**
|
|
1150
|
+
|
|
1151
|
+
```js
|
|
1152
|
+
import { isLinearElement } from "@excalidraw/excalidraw";
|
|
1153
|
+
```
|
|
1154
|
+
|
|
1155
|
+
**Signature**
|
|
1156
|
+
|
|
1157
|
+
<pre>
|
|
1158
|
+
isLinearElement(elementType?: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L80">ExcalidrawElement</a>): boolean
|
|
1159
|
+
</pre>
|
|
1160
|
+
|
|
1161
|
+
This function returns true if the element is linear type (`arrow` |`line`) else returns false.
|
|
1162
|
+
|
|
1163
|
+
#### `getNonDeletedElements`
|
|
1164
|
+
|
|
1165
|
+
**How to use**
|
|
1166
|
+
|
|
1167
|
+
```js
|
|
1168
|
+
import { getNonDeletedElements } from "@excalidraw/excalidraw";
|
|
1169
|
+
```
|
|
1170
|
+
|
|
1171
|
+
**Signature**
|
|
1172
|
+
|
|
1173
|
+
<pre>
|
|
1174
|
+
getNonDeletedElements(elements: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L80"> readonly ExcalidrawElement[]</a>): as readonly <a href="https://github.com/excalidraw/excalidraw/blob/master/src/element/types.ts#L90">NonDeletedExcalidrawElement[]</a>
|
|
1175
|
+
</pre>
|
|
1176
|
+
|
|
1177
|
+
This function returns an array of deleted elements.
|
|
1178
|
+
|
|
1179
|
+
#### `mergeLibraryItems`
|
|
1180
|
+
|
|
1181
|
+
```js
|
|
1182
|
+
import { mergeLibraryItems } from "@excalidraw/excalidraw";
|
|
1183
|
+
```
|
|
1184
|
+
|
|
1185
|
+
**_Signature_**
|
|
1186
|
+
|
|
1187
|
+
<pre>
|
|
1188
|
+
mergeLibraryItems(localItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>, otherItems: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>) => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L200">LibraryItems</a>
|
|
1189
|
+
</pre>
|
|
1190
|
+
|
|
1191
|
+
This function merges two `LibraryItems` arrays, where unique items from `otherItems` are sorted first in the returned array.
|
|
1192
|
+
|
|
1193
|
+
#### `parseLibraryTokensFromUrl`
|
|
1194
|
+
|
|
1195
|
+
**How to use**
|
|
1196
|
+
|
|
1197
|
+
```js
|
|
1198
|
+
import { parseLibraryTokensFromUrl } from "@excalidraw/excalidraw";
|
|
1199
|
+
```
|
|
1200
|
+
|
|
1201
|
+
**Signature**
|
|
1202
|
+
|
|
1203
|
+
<pre>
|
|
1204
|
+
parseLibraryTokensFromUrl(): {
|
|
1205
|
+
libraryUrl: string;
|
|
1206
|
+
idToken: string | null;
|
|
1207
|
+
} | null
|
|
1208
|
+
</pre>
|
|
1209
|
+
|
|
1210
|
+
Parses library parameters from URL if present (expects the `#addLibrary` hash key), and returns an object with the `libraryUrl` and `idToken`. Returns `null` if `#addLibrary` hash key not found.
|
|
1211
|
+
|
|
1212
|
+
#### `useHandleLibrary`
|
|
1213
|
+
|
|
1214
|
+
**How to use**
|
|
1215
|
+
|
|
1216
|
+
```js
|
|
1217
|
+
import { useHandleLibrary } from "@excalidraw/excalidraw";
|
|
1218
|
+
|
|
1219
|
+
export const App = () => {
|
|
1220
|
+
// ...
|
|
1221
|
+
useHandleLibrary({ excalidrawAPI });
|
|
1222
|
+
};
|
|
1223
|
+
```
|
|
1224
|
+
|
|
1225
|
+
**Signature**
|
|
1226
|
+
|
|
1227
|
+
<pre>
|
|
1228
|
+
useHandleLibrary(opts: {
|
|
1229
|
+
excalidrawAPI: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L432">ExcalidrawAPI</a>,
|
|
1230
|
+
getInitialLibraryItems?: () => <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L224">LibraryItemsSource</a>
|
|
1231
|
+
});
|
|
1232
|
+
</pre>
|
|
1233
|
+
|
|
1234
|
+
A hook that automatically imports library from url if `#addLibrary` hash key exists on initial load, or when it changes during the editing session (e.g. when a user installs a new library), and handles initial library load if `getInitialLibraryItems` getter is supplied.
|
|
1235
|
+
|
|
1236
|
+
In the future, we will be adding support for handling library persistence to browser storage (or elsewhere).
|
|
1237
|
+
|
|
1238
|
+
#### `sceneCoordsToViewportCoords`
|
|
1239
|
+
|
|
1240
|
+
```js
|
|
1241
|
+
import { sceneCoordsToViewportCoords } from "@excalidraw/excalidraw";
|
|
1242
|
+
```
|
|
1243
|
+
|
|
1244
|
+
**_Signature_**
|
|
1245
|
+
|
|
1246
|
+
<pre>
|
|
1247
|
+
sceneCoordsToViewportCoords({sceneX: number, sceneY: number}, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>): {x: number, y: number}
|
|
1248
|
+
</pre>
|
|
1249
|
+
|
|
1250
|
+
This function returns equivalent viewport coords for the provided scene coords in params.
|
|
1251
|
+
|
|
1252
|
+
#### `viewportCoordsToSceneCoords`
|
|
1253
|
+
|
|
1254
|
+
```js
|
|
1255
|
+
import { viewportCoordsToSceneCoords } from "@excalidraw/excalidraw";
|
|
1256
|
+
```
|
|
1257
|
+
|
|
1258
|
+
**_Signature_**
|
|
1259
|
+
|
|
1260
|
+
<pre>
|
|
1261
|
+
viewportCoordsToSceneCoords({clientX: number, clientY: number}, appState: <a href="https://github.com/excalidraw/excalidraw/blob/master/src/types.ts#L79">AppState</a>): {x: number, y: number}
|
|
1262
|
+
</pre>
|
|
1263
|
+
|
|
1264
|
+
This function returns equivalent scene coords for the provided viewport coords in params.
|
|
1265
|
+
|
|
1266
|
+
### Exported constants
|
|
1267
|
+
|
|
1268
|
+
#### `FONT_FAMILY`
|
|
1269
|
+
|
|
1270
|
+
**How to use**
|
|
1271
|
+
|
|
1272
|
+
```js
|
|
1273
|
+
import { FONT_FAMILY } from "@excalidraw/excalidraw";
|
|
1274
|
+
```
|
|
1275
|
+
|
|
1276
|
+
`FONT_FAMILY` contains all the font families used in `Excalidraw` as explained below
|
|
1277
|
+
|
|
1278
|
+
| Font Family | Description |
|
|
1279
|
+
| ----------- | -------------------- |
|
|
1280
|
+
| Virgil | The handwritten font |
|
|
1281
|
+
| Helvetica | The Normal Font |
|
|
1282
|
+
| Cascadia | The Code Font |
|
|
1283
|
+
|
|
1284
|
+
Defaults to `FONT_FAMILY.Virgil` unless passed in `initialData.appState.currentItemFontFamily`.
|
|
1285
|
+
|
|
1286
|
+
#### `THEME`
|
|
1287
|
+
|
|
1288
|
+
**How to use**
|
|
1289
|
+
|
|
1290
|
+
```js
|
|
1291
|
+
import { THEME } from "@excalidraw/excalidraw";
|
|
1292
|
+
```
|
|
1293
|
+
|
|
1294
|
+
`THEME` contains all the themes supported by `Excalidraw` as explained below
|
|
1295
|
+
|
|
1296
|
+
| Theme | Description |
|
|
1297
|
+
| ----- | --------------- |
|
|
1298
|
+
| LIGHT | The light theme |
|
|
1299
|
+
| DARK | The Dark theme |
|
|
1300
|
+
|
|
1301
|
+
Defaults to `THEME.LIGHT` unless passed in `initialData.appState.theme`
|
|
1302
|
+
|
|
1303
|
+
### `MIME_TYPES`
|
|
1304
|
+
|
|
1305
|
+
**How to use **
|
|
1306
|
+
|
|
1307
|
+
```js
|
|
1308
|
+
import { MIME_TYPES } from "@excalidraw/excalidraw";
|
|
1309
|
+
```
|
|
1310
|
+
|
|
1311
|
+
[`MIME_TYPES`](https://github.com/excalidraw/excalidraw/blob/master/src/constants.ts#L92) contains all the mime types supported by `Excalidraw`.
|
|
1312
|
+
|
|
925
1313
|
## Need help?
|
|
926
1314
|
|
|
927
1315
|
Check out the existing [Q&A](https://github.com/excalidraw/excalidraw/discussions?discussions_q=label%3Apackage%3Aexcalidraw). If you have any queries or need help, ask us [here](https://github.com/excalidraw/excalidraw/discussions?discussions_q=label%3Apackage%3Aexcalidraw).
|
|
1316
|
+
|
|
1317
|
+
### Development
|
|
1318
|
+
|
|
1319
|
+
#### Install the dependencies
|
|
1320
|
+
|
|
1321
|
+
```bash
|
|
1322
|
+
yarn
|
|
1323
|
+
```
|
|
1324
|
+
|
|
1325
|
+
#### Start the server
|
|
1326
|
+
|
|
1327
|
+
```bash
|
|
1328
|
+
yarn start
|
|
1329
|
+
```
|
|
1330
|
+
|
|
1331
|
+
[http://localhost:3001](http://localhost:3001) will open in your default browser.
|
|
1332
|
+
|
|
1333
|
+
The example is same as the [codesandbox example](https://ehlz3.csb.app/)
|
|
1334
|
+
|
|
1335
|
+
#### Create a test release
|
|
1336
|
+
|
|
1337
|
+
You can create a test release by posting the below comment in your pull request
|
|
1338
|
+
|
|
1339
|
+
```
|
|
1340
|
+
@excalibot trigger release
|
|
1341
|
+
```
|
|
1342
|
+
|
|
1343
|
+
Once the version is released `@excalibot` will post a comment with the release version.
|
|
1344
|
+
|
|
1345
|
+
#### Creating a production release
|
|
1346
|
+
|
|
1347
|
+
To release the next stable version follow the below steps
|
|
1348
|
+
|
|
1349
|
+
```
|
|
1350
|
+
yarn prerelease version
|
|
1351
|
+
```
|
|
1352
|
+
|
|
1353
|
+
You need to pass the `version` for which you want to create the release. This will make the changes needed before making the release like updating `package.json`, `changelog` and more.
|
|
1354
|
+
|
|
1355
|
+
The next step is to run the `release` script
|
|
1356
|
+
|
|
1357
|
+
```
|
|
1358
|
+
yarn release
|
|
1359
|
+
```
|
|
1360
|
+
|
|
1361
|
+
This will publish the package.
|
|
1362
|
+
|
|
1363
|
+
Right now there are two steps to create a production release but once this works fine these scripts will be combined and more automation will be done.
|