@afbin/cli 0.4.1 → 0.4.2
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/README.md +5 -0
- package/dist/afbin.mjs +33 -12
- package/dist/index.mjs +11 -1
- package/dist/runtime/dist/web/.vite/manifest.json +216 -216
- package/dist/runtime/dist/web/assets/{Account-CvOF6jpD.js → Account-qnxwLep7.js} +1 -1
- package/dist/runtime/dist/web/assets/Account-qnxwLep7.js.br +0 -0
- package/dist/runtime/dist/web/assets/Account-qnxwLep7.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ArtifactAddress-DORDne01.js → ArtifactAddress-1ftOG9A5.js} +2 -2
- package/dist/runtime/dist/web/assets/ArtifactAddress-1ftOG9A5.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactAddress-1ftOG9A5.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ArtifactData-BdL9R2dA.js → ArtifactData-CZq-MLWc.js} +1 -1
- package/dist/runtime/dist/web/assets/ArtifactData-CZq-MLWc.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactData-CZq-MLWc.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ArtifactEditor-BZXbOk_F.js → ArtifactEditor-Cd_-Z6DK.js} +1 -1
- package/dist/runtime/dist/web/assets/ArtifactEditor-Cd_-Z6DK.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactEditor-Cd_-Z6DK.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{AssetPageHeader-DX2RcYTv.js → AssetPageHeader-BqdRtu9K.js} +1 -1
- package/dist/runtime/dist/web/assets/AssetPageHeader-BqdRtu9K.js.br +0 -0
- package/dist/runtime/dist/web/assets/AssetPageHeader-BqdRtu9K.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Assets-dgdXIgAW.js → Assets-D6htDZnu.js} +1 -1
- package/dist/runtime/dist/web/assets/Assets-D6htDZnu.js.br +0 -0
- package/dist/runtime/dist/web/assets/Assets-D6htDZnu.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{AvatarCircle-MNnIhRvg.js → AvatarCircle-CBpOuCGy.js} +1 -1
- package/dist/runtime/dist/web/assets/AvatarCircle-CBpOuCGy.js.br +0 -0
- package/dist/runtime/dist/web/assets/AvatarCircle-CBpOuCGy.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Chat-V1ku1-60.js → Chat-DueKnMAf.js} +1 -1
- package/dist/runtime/dist/web/assets/Chat-DueKnMAf.js.br +0 -0
- package/dist/runtime/dist/web/assets/Chat-DueKnMAf.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ConfirmDialog-Ph1VDgNN.js → ConfirmDialog-hdkXS1mg.js} +1 -1
- package/dist/runtime/dist/web/assets/ConfirmDialog-hdkXS1mg.js.br +0 -0
- package/dist/runtime/dist/web/assets/ConfirmDialog-hdkXS1mg.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{DatasetCatalogView-DBJEPKFI.js → DatasetCatalogView-DKNdjYA_.js} +1 -1
- package/dist/runtime/dist/web/assets/DatasetCatalogView-DKNdjYA_.js.br +0 -0
- package/dist/runtime/dist/web/assets/DatasetCatalogView-DKNdjYA_.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{DatasetEditor-CMqN1duq.js → DatasetEditor-C22-4oJL.js} +1 -1
- package/dist/runtime/dist/web/assets/DatasetEditor-C22-4oJL.js.br +0 -0
- package/dist/runtime/dist/web/assets/DatasetEditor-C22-4oJL.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Docs-DVoW7b7v.js → Docs-B80IZLN8.js} +1 -1
- package/dist/runtime/dist/web/assets/Docs-B80IZLN8.js.br +0 -0
- package/dist/runtime/dist/web/assets/Docs-B80IZLN8.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Document-udhy5mlX.js → Document-C6-E9V3_.js} +4 -4
- package/dist/runtime/dist/web/assets/Document-C6-E9V3_.js.br +0 -0
- package/dist/runtime/dist/web/assets/Document-C6-E9V3_.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{DocumentChrome-EUbW_JvA.js → DocumentChrome-Bw4_z5yQ.js} +1 -1
- package/dist/runtime/dist/web/assets/DocumentChrome-Bw4_z5yQ.js.br +0 -0
- package/dist/runtime/dist/web/assets/DocumentChrome-Bw4_z5yQ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{DocumentSharing-BuTXuflA.js → DocumentSharing-BiTakFtn.js} +1 -1
- package/dist/runtime/dist/web/assets/DocumentSharing-BiTakFtn.js.br +0 -0
- package/dist/runtime/dist/web/assets/DocumentSharing-BiTakFtn.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{FileUpload-D6RTOrHD.js → FileUpload-B-da-wki.js} +1 -1
- package/dist/runtime/dist/web/assets/FileUpload-B-da-wki.js.br +0 -0
- package/dist/runtime/dist/web/assets/FileUpload-B-da-wki.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Folder-DoNsFB2I.js → Folder-B-OlCz39.js} +1 -1
- package/dist/runtime/dist/web/assets/Folder-B-OlCz39.js.br +0 -0
- package/dist/runtime/dist/web/assets/Folder-B-OlCz39.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ForkArtifact-DDmXl1BZ.js → ForkArtifact-DXYU1-qL.js} +1 -1
- package/dist/runtime/dist/web/assets/ForkArtifact-DXYU1-qL.js.br +0 -0
- package/dist/runtime/dist/web/assets/ForkArtifact-DXYU1-qL.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{GetStarted-YjltMEeN.js → GetStarted-CFsSvXR0.js} +1 -1
- package/dist/runtime/dist/web/assets/GetStarted-CFsSvXR0.js.br +0 -0
- package/dist/runtime/dist/web/assets/GetStarted-CFsSvXR0.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Home-DijnltFZ.js → Home-BSO7YYXA.js} +1 -1
- package/dist/runtime/dist/web/assets/Home-BSO7YYXA.js.br +0 -0
- package/dist/runtime/dist/web/assets/Home-BSO7YYXA.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Login-DLwn4aUr.js → Login-CszZ8VGu.js} +1 -1
- package/dist/runtime/dist/web/assets/Login-CszZ8VGu.js.br +0 -0
- package/dist/runtime/dist/web/assets/Login-CszZ8VGu.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{NotFound-svz4wCeL.js → NotFound-D2MOGkIO.js} +1 -1
- package/dist/runtime/dist/web/assets/NotFound-D2MOGkIO.js.br +0 -0
- package/dist/runtime/dist/web/assets/NotFound-D2MOGkIO.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Notifications-BGeJKv2W.js → Notifications-M7BiDhSo.js} +1 -1
- package/dist/runtime/dist/web/assets/Notifications-M7BiDhSo.js.br +0 -0
- package/dist/runtime/dist/web/assets/Notifications-M7BiDhSo.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Profile-B38GeCbR.js → Profile-DqV5PMEi.js} +2 -2
- package/dist/runtime/dist/web/assets/Profile-DqV5PMEi.js.br +0 -0
- package/dist/runtime/dist/web/assets/Profile-DqV5PMEi.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Program-D3-Gfvjo.js → Program-CdwfK2zE.js} +1 -1
- package/dist/runtime/dist/web/assets/Program-CdwfK2zE.js.br +0 -0
- package/dist/runtime/dist/web/assets/Program-CdwfK2zE.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{RowMenu-J4Gbci3B.js → RowMenu-B2c9LyOb.js} +1 -1
- package/dist/runtime/dist/web/assets/RowMenu-B2c9LyOb.js.br +0 -0
- package/dist/runtime/dist/web/assets/RowMenu-B2c9LyOb.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Schedules-D05tndQ1.js +1 -0
- package/dist/runtime/dist/web/assets/Schedules-D05tndQ1.js.br +0 -0
- package/dist/runtime/dist/web/assets/Schedules-D05tndQ1.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ScreenshotEditor-CUmN5F2q.js → ScreenshotEditor-B8g3LiBx.js} +1 -1
- package/dist/runtime/dist/web/assets/ScreenshotEditor-B8g3LiBx.js.br +0 -0
- package/dist/runtime/dist/web/assets/ScreenshotEditor-B8g3LiBx.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{ShareLink-n8KhtnaI.js → ShareLink-qbYss_Eh.js} +1 -1
- package/dist/runtime/dist/web/assets/ShareLink-qbYss_Eh.js.br +0 -0
- package/dist/runtime/dist/web/assets/ShareLink-qbYss_Eh.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Shelf-BgwHOaeW.js → Shelf-anhc5No9.js} +1 -1
- package/dist/runtime/dist/web/assets/Shelf-anhc5No9.js.br +0 -0
- package/dist/runtime/dist/web/assets/Shelf-anhc5No9.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{SocialPreviewEditor-DwHHRW29.js → SocialPreviewEditor-B4nUY6FA.js} +1 -1
- package/dist/runtime/dist/web/assets/SocialPreviewEditor-B4nUY6FA.js.br +0 -0
- package/dist/runtime/dist/web/assets/SocialPreviewEditor-B4nUY6FA.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Starter-I01MNooi.js → Starter-DrID859q.js} +1 -1
- package/dist/runtime/dist/web/assets/Starter-DrID859q.js.br +0 -0
- package/dist/runtime/dist/web/assets/Starter-DrID859q.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Trash-Cu0KXeW7.js → Trash-DoKID_ux.js} +1 -1
- package/dist/runtime/dist/web/assets/Trash-DoKID_ux.js.br +0 -0
- package/dist/runtime/dist/web/assets/Trash-DoKID_ux.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{Welcome-B8iPt_Nh.js → Welcome-Ct29u9Y9.js} +1 -1
- package/dist/runtime/dist/web/assets/Welcome-Ct29u9Y9.js.br +0 -0
- package/dist/runtime/dist/web/assets/Welcome-Ct29u9Y9.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{WorkspaceLayout-fF_ot7EK.js → WorkspaceLayout-Qf3x5yOM.js} +1 -1
- package/dist/runtime/dist/web/assets/WorkspaceLayout-Qf3x5yOM.js.br +0 -0
- package/dist/runtime/dist/web/assets/WorkspaceLayout-Qf3x5yOM.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{browser-artifact-write-ZsGe-hXr.js → browser-artifact-write-CG72iseh.js} +1 -1
- package/dist/runtime/dist/web/assets/browser-artifact-write-CG72iseh.js.br +0 -0
- package/dist/runtime/dist/web/assets/browser-artifact-write-CG72iseh.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{chevron-down-COGO5cmx.js → chevron-down-M1fHuk7u.js} +1 -1
- package/dist/runtime/dist/web/assets/{chevron-left-BJZiR3W-.js → chevron-left-NHmvDJpN.js} +1 -1
- package/dist/runtime/dist/web/assets/{copy-PNNAtmJH.js → copy-v5iTV3kk.js} +1 -1
- package/dist/runtime/dist/web/assets/copy-v5iTV3kk.js.br +0 -0
- package/dist/runtime/dist/web/assets/copy-v5iTV3kk.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{database-CKOnpvwb.js → database-BbH2eTSj.js} +1 -1
- package/dist/runtime/dist/web/assets/database-BbH2eTSj.js.br +2 -0
- package/dist/runtime/dist/web/assets/database-BbH2eTSj.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{document-update-client-DUF0zs2Z.js → document-update-client-td73lQ81.js} +1 -1
- package/dist/runtime/dist/web/assets/document-update-client-td73lQ81.js.br +0 -0
- package/dist/runtime/dist/web/assets/document-update-client-td73lQ81.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{dom-mounter-64phOf1s.js → dom-mounter-BSxIt5bC.js} +1 -1
- package/dist/runtime/dist/web/assets/dom-mounter-BSxIt5bC.js.br +0 -0
- package/dist/runtime/dist/web/assets/dom-mounter-BSxIt5bC.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{download-j-nqks7p.js → download-Dk3mxCBK.js} +1 -1
- package/dist/runtime/dist/web/assets/download-Dk3mxCBK.js.br +0 -0
- package/dist/runtime/dist/web/assets/download-Dk3mxCBK.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{eye-BNpzRKAK.js → eye-DEiYMLrO.js} +1 -1
- package/dist/runtime/dist/web/assets/eye-DEiYMLrO.js.br +0 -0
- package/dist/runtime/dist/web/assets/eye-DEiYMLrO.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{file-up-DH-HiKEX.js → file-up-GoLKOXxO.js} +1 -1
- package/dist/runtime/dist/web/assets/file-up-GoLKOXxO.js.br +1 -0
- package/dist/runtime/dist/web/assets/file-up-GoLKOXxO.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{git-fork-PQOXxmWW.js → git-fork-CN41g1lF.js} +1 -1
- package/dist/runtime/dist/web/assets/git-fork-CN41g1lF.js.br +0 -0
- package/dist/runtime/dist/web/assets/git-fork-CN41g1lF.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{http-C2exCIpl.js → http-DEdzW08u.js} +1 -1
- package/dist/runtime/dist/web/assets/http-DEdzW08u.js.br +0 -0
- package/dist/runtime/dist/web/assets/http-DEdzW08u.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{list-Dj3WErnh.js → list-CA_o21oZ.js} +1 -1
- package/dist/runtime/dist/web/assets/list-CA_o21oZ.js.br +0 -0
- package/dist/runtime/dist/web/assets/list-CA_o21oZ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{loader-circle-BXxJOPx-.js → loader-circle-2p_rsu6P.js} +1 -1
- package/dist/runtime/dist/web/assets/{lock-B1nhk71f.js → lock-BRsIxNP2.js} +1 -1
- package/dist/runtime/dist/web/assets/lock-BRsIxNP2.js.br +0 -0
- package/dist/runtime/dist/web/assets/lock-BRsIxNP2.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{person-mentions-BEjAedYZ.js → person-mentions-C7vQd7Vr.js} +1 -1
- package/dist/runtime/dist/web/assets/person-mentions-C7vQd7Vr.js.br +0 -0
- package/dist/runtime/dist/web/assets/person-mentions-C7vQd7Vr.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{plus-BtWrAD8F.js → plus-BNzHjmEg.js} +1 -1
- package/dist/runtime/dist/web/assets/{rotate-ccw-CSJ78xUE.js → rotate-ccw-CIMUmeuJ.js} +1 -1
- package/dist/runtime/dist/web/assets/rotate-ccw-CIMUmeuJ.js.br +0 -0
- package/dist/runtime/dist/web/assets/rotate-ccw-CIMUmeuJ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{search-agWZofH1.js → search-CmIkt7xE.js} +1 -1
- package/dist/runtime/dist/web/assets/{session-D__Apnw9.js → session-BsshdoaV.js} +1 -1
- package/dist/runtime/dist/web/assets/session-BsshdoaV.js.br +0 -0
- package/dist/runtime/dist/web/assets/session-BsshdoaV.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{shelf-CeaX4iBg.js → shelf-DUXW45ap.js} +1 -1
- package/dist/runtime/dist/web/assets/shelf-DUXW45ap.js.br +0 -0
- package/dist/runtime/dist/web/assets/shelf-DUXW45ap.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{solid-app-BtmRR9Ax.js → solid-app-BNcsMwv4.js} +2 -2
- package/dist/runtime/dist/web/assets/solid-app-BNcsMwv4.js.br +0 -0
- package/dist/runtime/dist/web/assets/solid-app-BNcsMwv4.js.gz +0 -0
- package/dist/runtime/dist/web/assets/solid-app-DRAhiXqs.css +2 -0
- package/dist/runtime/dist/web/assets/solid-app-DRAhiXqs.css.br +0 -0
- package/dist/runtime/dist/web/assets/solid-app-DRAhiXqs.css.gz +0 -0
- package/dist/runtime/dist/web/assets/{undo-2-Di8QrlfX.js → undo-2--XbU60MY.js} +1 -1
- package/dist/runtime/dist/web/assets/undo-2--XbU60MY.js.br +0 -0
- package/dist/runtime/dist/web/assets/undo-2--XbU60MY.js.gz +0 -0
- package/dist/runtime/dist/web/assets/{users-BJrdLUkX.js → users-Bm0xpNrq.js} +1 -1
- package/dist/runtime/dist/web/assets/users-Bm0xpNrq.js.br +0 -0
- package/dist/runtime/dist/web/assets/users-Bm0xpNrq.js.gz +0 -0
- package/dist/runtime/dist/web/solid-app.html +2 -2
- package/dist/runtime/draft-compile-worker.mjs +10 -0
- package/dist/runtime/host.mjs +12 -2
- package/dist/runtime/lambda-page-runtime.js +1 -1
- package/dist/runtime/lib/build-assets/.server-reader-cache.json +1 -1
- package/dist/runtime/lib/build-assets/offline/.build-cache.json +10 -7
- package/dist/runtime/lib/build-assets/offline/manifest.json +4 -4
- package/dist/runtime/lib/build-assets/offline/solid.js.gz +0 -0
- package/dist/runtime/lib/build-assets/prepared-sources.sha256 +1 -1
- package/dist/runtime/pool-worker.mjs +3 -0
- package/dist/runtime/preview/{ScreenshotEditor-R3UODF65.js → ScreenshotEditor-LHC3JZSA.js} +1 -1
- package/dist/runtime/preview/{annotate-U27XXRZK.js → annotate-THM7GL72.js} +1 -1
- package/dist/runtime/preview/chrome.css +1 -1
- package/dist/runtime/preview/{chunk-7RMKAFBO.js → chunk-4O7LVK2Q.js} +1 -1
- package/dist/runtime/preview/chunk-7T3V6PAW.js +1 -0
- package/dist/runtime/preview/{chunk-3KKU74WM.js → chunk-RDT3C3F6.js} +1 -1
- package/dist/runtime/preview/client.js +13 -13
- package/dist/runtime/preview/connect.js +1 -0
- package/dist/runtime/preview/{dom-mounter-3OQN7G4J.js → dom-mounter-2URPGP2F.js} +1 -1
- package/dist/runtime/preview/{engine-I6R47UTB.js → engine-5UO3LPN5.js} +1 -1
- package/dist/runtime/preview/{selection-actions-426G2H4N.js → selection-actions-LBFPODLD.js} +1 -1
- package/dist/runtime/preview/{session-UFN5GQK2.js → session-A2Z3M7QD.js} +1 -1
- package/dist/runtime/preview/update-parts-ZLXTYSVY.js +1 -0
- package/dist/runtime/preview.mjs +74496 -74135
- package/dist/runtime/public/chat/install.ps1 +1 -1
- package/dist/runtime/public/chat/install.sh +1 -1
- package/dist/runtime/public/chat/release.json +1 -1
- package/dist/runtime/public/islands/{boot-74e9143aa374c62b.js → boot-281adc05179334e6.js} +1 -1
- package/dist/runtime/public/islands/boot-281adc05179334e6.js.br +0 -0
- package/dist/runtime/public/islands/boot-281adc05179334e6.js.gz +0 -0
- package/dist/runtime/public/islands/{chunk-51a4b62dc42f3594.js → chunk-1af2f1c5f3e99805.js} +1 -1
- package/dist/runtime/public/islands/chunk-1af2f1c5f3e99805.js.br +0 -0
- package/dist/runtime/public/islands/chunk-1af2f1c5f3e99805.js.gz +0 -0
- package/dist/runtime/public/islands/{chunk-f451297257164687.js → chunk-2f5d885a7394f865.js} +1 -1
- package/dist/runtime/public/islands/chunk-2f5d885a7394f865.js.br +0 -0
- package/dist/runtime/public/islands/{chunk-f451297257164687.js.gz → chunk-2f5d885a7394f865.js.gz} +0 -0
- package/dist/runtime/public/islands/{chunk-68a083200dbd5bf7.js → chunk-3cb86bf7badbd2c3.js} +1 -1
- package/dist/runtime/public/islands/chunk-3cb86bf7badbd2c3.js.br +0 -0
- package/dist/runtime/public/islands/chunk-3cb86bf7badbd2c3.js.gz +0 -0
- package/dist/runtime/public/islands/{chunk-adcd632c8be50ba7.js → chunk-5e05b99cb275660b.js} +1 -1
- package/dist/runtime/public/islands/chunk-5e05b99cb275660b.js.br +0 -0
- package/dist/runtime/public/islands/{chunk-adcd632c8be50ba7.js.gz → chunk-5e05b99cb275660b.js.gz} +0 -0
- package/dist/runtime/public/islands/{chunk-e817ee4addba2d95.js → chunk-d924d4620b11b893.js} +1 -1
- package/dist/runtime/public/islands/chunk-d924d4620b11b893.js.br +0 -0
- package/dist/runtime/public/islands/chunk-d924d4620b11b893.js.gz +0 -0
- package/dist/runtime/public/islands/{chunk-1fa28532f51beb9c.js → chunk-dfe07cc2b19c50cc.js} +1 -1
- package/dist/runtime/public/islands/{frame-editor-6b8a50886fff8604.js → frame-editor-66b0c0d98283e912.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-66b0c0d98283e912.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-66b0c0d98283e912.js.gz +0 -0
- package/dist/runtime/public/islands/{frame-editor-chunk-87b0311faf57261c.js → frame-editor-chunk-091e41cba1670be1.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-chunk-091e41cba1670be1.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-091e41cba1670be1.js.gz +0 -0
- package/dist/runtime/public/islands/{frame-editor-chunk-69c553d9c4562981.js → frame-editor-chunk-5ea52db3a6d93294.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-chunk-5ea52db3a6d93294.js.br +2 -0
- package/dist/runtime/public/islands/frame-editor-chunk-5ea52db3a6d93294.js.gz +0 -0
- package/dist/runtime/public/islands/{frame-editor-chunk-c2b9018371100824.js → frame-editor-chunk-a6db6db210776f5c.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-chunk-a6db6db210776f5c.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-a6db6db210776f5c.js.gz +0 -0
- package/dist/runtime/public/islands/{frame-editor-chunk-a13dce46b9b8401f.js → frame-editor-chunk-c9facbfeee3c9bed.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-chunk-c9facbfeee3c9bed.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-c9facbfeee3c9bed.js.gz +0 -0
- package/dist/runtime/public/islands/{frame-editor-chunk-b06f17fc7dae17e8.js → frame-editor-chunk-d6c77179f72db0ab.js} +1 -1
- package/dist/runtime/public/islands/frame-editor-chunk-d6c77179f72db0ab.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-d6c77179f72db0ab.js.gz +0 -0
- package/dist/runtime/public/islands/{image-map-a9f95f7e8d0712c1.js → image-map-7419ab54ff59434a.js} +1 -1
- package/dist/runtime/public/islands/image-map-7419ab54ff59434a.js.br +0 -0
- package/dist/runtime/public/islands/image-map-7419ab54ff59434a.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-basic-cbabcc4b41d6132a.js → kit-basic-c22b54dcd2ea6161.js} +1 -1
- package/dist/runtime/public/islands/kit-basic-c22b54dcd2ea6161.js.br +2 -0
- package/dist/runtime/public/islands/kit-basic-c22b54dcd2ea6161.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-cells-cefbceccdfd0dbe0.js → kit-cells-55ade213f1751716.js} +1 -1
- package/dist/runtime/public/islands/kit-cells-55ade213f1751716.js.br +0 -0
- package/dist/runtime/public/islands/kit-cells-55ade213f1751716.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-controls-81d17a10f9d457f2.js → kit-controls-4f1b98d7d87c4b21.js} +1 -1
- package/dist/runtime/public/islands/kit-controls-4f1b98d7d87c4b21.js.br +0 -0
- package/dist/runtime/public/islands/kit-controls-4f1b98d7d87c4b21.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-data-43947f36f1c501aa.js → kit-data-e1012fd12092b177.js} +1 -1
- package/dist/runtime/public/islands/kit-data-e1012fd12092b177.js.br +0 -0
- package/dist/runtime/public/islands/kit-data-e1012fd12092b177.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-dialog-eedc51ce82feec4b.js → kit-dialog-1e427336472b2906.js} +1 -1
- package/dist/runtime/public/islands/kit-dialog-1e427336472b2906.js.br +0 -0
- package/dist/runtime/public/islands/kit-dialog-1e427336472b2906.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-embed-3c8886cbfa06f74d.js → kit-embed-c7019820c5200806.js} +1 -1
- package/dist/runtime/public/islands/kit-embed-c7019820c5200806.js.br +0 -0
- package/dist/runtime/public/islands/kit-embed-c7019820c5200806.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-files-b7a2cb758f00a68b.js → kit-files-dc0b71ca71f2151c.js} +1 -1
- package/dist/runtime/public/islands/kit-files-dc0b71ca71f2151c.js.br +0 -0
- package/dist/runtime/public/islands/kit-files-dc0b71ca71f2151c.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-image-126e12fcae4215c1.js → kit-image-b31acf4d31a4eeaf.js} +1 -1
- package/dist/runtime/public/islands/kit-image-b31acf4d31a4eeaf.js.br +0 -0
- package/dist/runtime/public/islands/kit-image-b31acf4d31a4eeaf.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-people-5b6f5dd4aa82b657.js → kit-people-6feb1b730c5fd37f.js} +1 -1
- package/dist/runtime/public/islands/kit-people-6feb1b730c5fd37f.js.br +0 -0
- package/dist/runtime/public/islands/kit-people-6feb1b730c5fd37f.js.gz +0 -0
- package/dist/runtime/public/islands/{kit-static-28174bd8f593f8c0.js → kit-static-853aed2cd04c1b4a.js} +1 -1
- package/dist/runtime/public/islands/kit-static-853aed2cd04c1b4a.js.br +0 -0
- package/dist/runtime/public/islands/kit-static-853aed2cd04c1b4a.js.gz +0 -0
- package/dist/runtime/public/islands/manifest.json +211 -211
- package/dist/runtime/public/islands/manifest.json.br +0 -0
- package/dist/runtime/public/islands/manifest.json.gz +0 -0
- package/dist/runtime/public/islands/{morph-engine-4e664485be475dbf.js → morph-engine-c61693caf767d9bd.js} +1 -1
- package/dist/runtime/public/islands/morph-engine-c61693caf767d9bd.js.br +0 -0
- package/dist/runtime/public/islands/morph-engine-c61693caf767d9bd.js.gz +0 -0
- package/dist/runtime/public/islands/offline-ba3717e06bc69a4e.json.gzip +0 -0
- package/dist/runtime/public/islands/{page-5f87c34c7c181387.js → page-c3ae4acf0988c2b6.js} +1 -1
- package/dist/runtime/public/islands/page-c3ae4acf0988c2b6.js.br +0 -0
- package/dist/runtime/public/islands/page-c3ae4acf0988c2b6.js.gz +0 -0
- package/dist/runtime/public/islands/{rt-30ff0d94ee3732a1.js → rt-2ab0fed85481c574.js} +1 -1
- package/dist/runtime/public/islands/rt-2ab0fed85481c574.js.br +0 -0
- package/dist/runtime/public/islands/rt-2ab0fed85481c574.js.gz +0 -0
- package/dist/runtime/public/islands/{sqlite-engine-9fc56fea8b1e2aaf.js → sqlite-engine-f3956693df7cfa5c.js} +8 -8
- package/dist/runtime/public/islands/sqlite-engine-f3956693df7cfa5c.js.br +0 -0
- package/dist/runtime/public/islands/sqlite-engine-f3956693df7cfa5c.js.gz +0 -0
- package/dist/runtime/public/islands/{ssr-456cabbcb26f723d.js → ssr-ce6931fb7bda9b08.js} +3 -0
- package/dist/runtime/public/islands/ssr-ce6931fb7bda9b08.js.br +0 -0
- package/dist/runtime/public/islands/ssr-ce6931fb7bda9b08.js.gz +0 -0
- package/dist/runtime/public/islands/{url-sync-74b5212f7b3417d7.js → url-sync-b179b054c9d958a7.js} +1 -1
- package/dist/runtime/public/islands/url-sync-b179b054c9d958a7.js.br +0 -0
- package/dist/runtime/public/islands/url-sync-b179b054c9d958a7.js.gz +0 -0
- package/dist/share/man/man1/afbin.1 +6 -4
- package/dist/skills/artifactbin/references/commands.md +4 -2
- package/dist/skills/artifactbin/references/publishing.md +5 -3
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/dist/runtime/dist/web/assets/Account-CvOF6jpD.js.br +0 -0
- package/dist/runtime/dist/web/assets/Account-CvOF6jpD.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ArtifactAddress-DORDne01.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactAddress-DORDne01.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ArtifactData-BdL9R2dA.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactData-BdL9R2dA.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ArtifactEditor-BZXbOk_F.js.br +0 -0
- package/dist/runtime/dist/web/assets/ArtifactEditor-BZXbOk_F.js.gz +0 -0
- package/dist/runtime/dist/web/assets/AssetPageHeader-DX2RcYTv.js.br +0 -0
- package/dist/runtime/dist/web/assets/AssetPageHeader-DX2RcYTv.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Assets-dgdXIgAW.js.br +0 -0
- package/dist/runtime/dist/web/assets/Assets-dgdXIgAW.js.gz +0 -0
- package/dist/runtime/dist/web/assets/AvatarCircle-MNnIhRvg.js.br +0 -0
- package/dist/runtime/dist/web/assets/AvatarCircle-MNnIhRvg.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Chat-V1ku1-60.js.br +0 -0
- package/dist/runtime/dist/web/assets/Chat-V1ku1-60.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ConfirmDialog-Ph1VDgNN.js.br +0 -0
- package/dist/runtime/dist/web/assets/ConfirmDialog-Ph1VDgNN.js.gz +0 -0
- package/dist/runtime/dist/web/assets/DatasetCatalogView-DBJEPKFI.js.br +0 -0
- package/dist/runtime/dist/web/assets/DatasetCatalogView-DBJEPKFI.js.gz +0 -0
- package/dist/runtime/dist/web/assets/DatasetEditor-CMqN1duq.js.br +0 -0
- package/dist/runtime/dist/web/assets/DatasetEditor-CMqN1duq.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Docs-DVoW7b7v.js.br +0 -0
- package/dist/runtime/dist/web/assets/Docs-DVoW7b7v.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Document-udhy5mlX.js.br +0 -0
- package/dist/runtime/dist/web/assets/Document-udhy5mlX.js.gz +0 -0
- package/dist/runtime/dist/web/assets/DocumentChrome-EUbW_JvA.js.br +0 -0
- package/dist/runtime/dist/web/assets/DocumentChrome-EUbW_JvA.js.gz +0 -0
- package/dist/runtime/dist/web/assets/DocumentSharing-BuTXuflA.js.br +0 -0
- package/dist/runtime/dist/web/assets/DocumentSharing-BuTXuflA.js.gz +0 -0
- package/dist/runtime/dist/web/assets/FileUpload-D6RTOrHD.js.br +0 -0
- package/dist/runtime/dist/web/assets/FileUpload-D6RTOrHD.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Folder-DoNsFB2I.js.br +0 -0
- package/dist/runtime/dist/web/assets/Folder-DoNsFB2I.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ForkArtifact-DDmXl1BZ.js.br +0 -0
- package/dist/runtime/dist/web/assets/ForkArtifact-DDmXl1BZ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/GetStarted-YjltMEeN.js.br +0 -0
- package/dist/runtime/dist/web/assets/GetStarted-YjltMEeN.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Home-DijnltFZ.js.br +0 -0
- package/dist/runtime/dist/web/assets/Home-DijnltFZ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Login-DLwn4aUr.js.br +0 -0
- package/dist/runtime/dist/web/assets/Login-DLwn4aUr.js.gz +0 -0
- package/dist/runtime/dist/web/assets/NotFound-svz4wCeL.js.br +0 -0
- package/dist/runtime/dist/web/assets/NotFound-svz4wCeL.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Notifications-BGeJKv2W.js.br +0 -0
- package/dist/runtime/dist/web/assets/Notifications-BGeJKv2W.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Profile-B38GeCbR.js.br +0 -0
- package/dist/runtime/dist/web/assets/Profile-B38GeCbR.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Program-D3-Gfvjo.js.br +0 -0
- package/dist/runtime/dist/web/assets/Program-D3-Gfvjo.js.gz +0 -0
- package/dist/runtime/dist/web/assets/RowMenu-J4Gbci3B.js.br +0 -0
- package/dist/runtime/dist/web/assets/RowMenu-J4Gbci3B.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Schedules-DK3-YUvJ.js +0 -1
- package/dist/runtime/dist/web/assets/Schedules-DK3-YUvJ.js.br +0 -0
- package/dist/runtime/dist/web/assets/Schedules-DK3-YUvJ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ScreenshotEditor-CUmN5F2q.js.br +0 -0
- package/dist/runtime/dist/web/assets/ScreenshotEditor-CUmN5F2q.js.gz +0 -0
- package/dist/runtime/dist/web/assets/ShareLink-n8KhtnaI.js.br +0 -0
- package/dist/runtime/dist/web/assets/ShareLink-n8KhtnaI.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Shelf-BgwHOaeW.js.br +0 -0
- package/dist/runtime/dist/web/assets/Shelf-BgwHOaeW.js.gz +0 -0
- package/dist/runtime/dist/web/assets/SocialPreviewEditor-DwHHRW29.js.br +0 -0
- package/dist/runtime/dist/web/assets/SocialPreviewEditor-DwHHRW29.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Starter-I01MNooi.js.br +0 -0
- package/dist/runtime/dist/web/assets/Starter-I01MNooi.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Trash-Cu0KXeW7.js.br +0 -0
- package/dist/runtime/dist/web/assets/Trash-Cu0KXeW7.js.gz +0 -0
- package/dist/runtime/dist/web/assets/Welcome-B8iPt_Nh.js.br +0 -0
- package/dist/runtime/dist/web/assets/Welcome-B8iPt_Nh.js.gz +0 -0
- package/dist/runtime/dist/web/assets/WorkspaceLayout-fF_ot7EK.js.br +0 -0
- package/dist/runtime/dist/web/assets/WorkspaceLayout-fF_ot7EK.js.gz +0 -0
- package/dist/runtime/dist/web/assets/browser-artifact-write-ZsGe-hXr.js.br +0 -0
- package/dist/runtime/dist/web/assets/browser-artifact-write-ZsGe-hXr.js.gz +0 -0
- package/dist/runtime/dist/web/assets/copy-PNNAtmJH.js.br +0 -0
- package/dist/runtime/dist/web/assets/copy-PNNAtmJH.js.gz +0 -0
- package/dist/runtime/dist/web/assets/database-CKOnpvwb.js.br +0 -3
- package/dist/runtime/dist/web/assets/database-CKOnpvwb.js.gz +0 -0
- package/dist/runtime/dist/web/assets/document-update-client-DUF0zs2Z.js.br +0 -0
- package/dist/runtime/dist/web/assets/document-update-client-DUF0zs2Z.js.gz +0 -0
- package/dist/runtime/dist/web/assets/dom-mounter-64phOf1s.js.br +0 -0
- package/dist/runtime/dist/web/assets/dom-mounter-64phOf1s.js.gz +0 -0
- package/dist/runtime/dist/web/assets/download-j-nqks7p.js.br +0 -0
- package/dist/runtime/dist/web/assets/download-j-nqks7p.js.gz +0 -0
- package/dist/runtime/dist/web/assets/eye-BNpzRKAK.js.br +0 -0
- package/dist/runtime/dist/web/assets/eye-BNpzRKAK.js.gz +0 -0
- package/dist/runtime/dist/web/assets/file-up-DH-HiKEX.js.br +0 -0
- package/dist/runtime/dist/web/assets/file-up-DH-HiKEX.js.gz +0 -0
- package/dist/runtime/dist/web/assets/git-fork-PQOXxmWW.js.br +0 -0
- package/dist/runtime/dist/web/assets/git-fork-PQOXxmWW.js.gz +0 -0
- package/dist/runtime/dist/web/assets/http-C2exCIpl.js.br +0 -0
- package/dist/runtime/dist/web/assets/http-C2exCIpl.js.gz +0 -0
- package/dist/runtime/dist/web/assets/list-Dj3WErnh.js.br +0 -0
- package/dist/runtime/dist/web/assets/list-Dj3WErnh.js.gz +0 -0
- package/dist/runtime/dist/web/assets/lock-B1nhk71f.js.br +0 -0
- package/dist/runtime/dist/web/assets/lock-B1nhk71f.js.gz +0 -0
- package/dist/runtime/dist/web/assets/person-mentions-BEjAedYZ.js.br +0 -0
- package/dist/runtime/dist/web/assets/person-mentions-BEjAedYZ.js.gz +0 -0
- package/dist/runtime/dist/web/assets/rotate-ccw-CSJ78xUE.js.br +0 -0
- package/dist/runtime/dist/web/assets/rotate-ccw-CSJ78xUE.js.gz +0 -0
- package/dist/runtime/dist/web/assets/session-D__Apnw9.js.br +0 -0
- package/dist/runtime/dist/web/assets/session-D__Apnw9.js.gz +0 -0
- package/dist/runtime/dist/web/assets/shelf-CeaX4iBg.js.br +0 -0
- package/dist/runtime/dist/web/assets/shelf-CeaX4iBg.js.gz +0 -0
- package/dist/runtime/dist/web/assets/solid-app-BmdFnFpX.css +0 -2
- package/dist/runtime/dist/web/assets/solid-app-BmdFnFpX.css.br +0 -0
- package/dist/runtime/dist/web/assets/solid-app-BmdFnFpX.css.gz +0 -0
- package/dist/runtime/dist/web/assets/solid-app-BtmRR9Ax.js.br +0 -0
- package/dist/runtime/dist/web/assets/solid-app-BtmRR9Ax.js.gz +0 -0
- package/dist/runtime/dist/web/assets/undo-2-Di8QrlfX.js.br +0 -0
- package/dist/runtime/dist/web/assets/undo-2-Di8QrlfX.js.gz +0 -0
- package/dist/runtime/dist/web/assets/users-BJrdLUkX.js.br +0 -0
- package/dist/runtime/dist/web/assets/users-BJrdLUkX.js.gz +0 -0
- package/dist/runtime/preview/update-parts-OJC3ZSRW.js +0 -1
- package/dist/runtime/public/islands/boot-74e9143aa374c62b.js.br +0 -0
- package/dist/runtime/public/islands/boot-74e9143aa374c62b.js.gz +0 -0
- package/dist/runtime/public/islands/chunk-51a4b62dc42f3594.js.br +0 -0
- package/dist/runtime/public/islands/chunk-51a4b62dc42f3594.js.gz +0 -0
- package/dist/runtime/public/islands/chunk-68a083200dbd5bf7.js.br +0 -0
- package/dist/runtime/public/islands/chunk-68a083200dbd5bf7.js.gz +0 -0
- package/dist/runtime/public/islands/chunk-adcd632c8be50ba7.js.br +0 -0
- package/dist/runtime/public/islands/chunk-e817ee4addba2d95.js.br +0 -0
- package/dist/runtime/public/islands/chunk-e817ee4addba2d95.js.gz +0 -0
- package/dist/runtime/public/islands/chunk-f451297257164687.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-6b8a50886fff8604.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-6b8a50886fff8604.js.gz +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-69c553d9c4562981.js.br +0 -1
- package/dist/runtime/public/islands/frame-editor-chunk-69c553d9c4562981.js.gz +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-87b0311faf57261c.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-87b0311faf57261c.js.gz +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-a13dce46b9b8401f.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-a13dce46b9b8401f.js.gz +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-b06f17fc7dae17e8.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-b06f17fc7dae17e8.js.gz +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-c2b9018371100824.js.br +0 -0
- package/dist/runtime/public/islands/frame-editor-chunk-c2b9018371100824.js.gz +0 -0
- package/dist/runtime/public/islands/image-map-a9f95f7e8d0712c1.js.br +0 -0
- package/dist/runtime/public/islands/image-map-a9f95f7e8d0712c1.js.gz +0 -0
- package/dist/runtime/public/islands/kit-basic-cbabcc4b41d6132a.js.br +0 -0
- package/dist/runtime/public/islands/kit-basic-cbabcc4b41d6132a.js.gz +0 -0
- package/dist/runtime/public/islands/kit-cells-cefbceccdfd0dbe0.js.br +0 -0
- package/dist/runtime/public/islands/kit-cells-cefbceccdfd0dbe0.js.gz +0 -0
- package/dist/runtime/public/islands/kit-controls-81d17a10f9d457f2.js.br +0 -0
- package/dist/runtime/public/islands/kit-controls-81d17a10f9d457f2.js.gz +0 -0
- package/dist/runtime/public/islands/kit-data-43947f36f1c501aa.js.br +0 -0
- package/dist/runtime/public/islands/kit-data-43947f36f1c501aa.js.gz +0 -0
- package/dist/runtime/public/islands/kit-dialog-eedc51ce82feec4b.js.br +0 -0
- package/dist/runtime/public/islands/kit-dialog-eedc51ce82feec4b.js.gz +0 -0
- package/dist/runtime/public/islands/kit-embed-3c8886cbfa06f74d.js.br +0 -0
- package/dist/runtime/public/islands/kit-embed-3c8886cbfa06f74d.js.gz +0 -0
- package/dist/runtime/public/islands/kit-files-b7a2cb758f00a68b.js.br +0 -0
- package/dist/runtime/public/islands/kit-files-b7a2cb758f00a68b.js.gz +0 -0
- package/dist/runtime/public/islands/kit-image-126e12fcae4215c1.js.br +0 -0
- package/dist/runtime/public/islands/kit-image-126e12fcae4215c1.js.gz +0 -0
- package/dist/runtime/public/islands/kit-people-5b6f5dd4aa82b657.js.br +0 -0
- package/dist/runtime/public/islands/kit-people-5b6f5dd4aa82b657.js.gz +0 -0
- package/dist/runtime/public/islands/kit-static-28174bd8f593f8c0.js.br +0 -0
- package/dist/runtime/public/islands/kit-static-28174bd8f593f8c0.js.gz +0 -0
- package/dist/runtime/public/islands/morph-engine-4e664485be475dbf.js.br +0 -0
- package/dist/runtime/public/islands/morph-engine-4e664485be475dbf.js.gz +0 -0
- package/dist/runtime/public/islands/offline-4446a94ed9f706c3.json.gzip +0 -0
- package/dist/runtime/public/islands/page-5f87c34c7c181387.js.br +0 -0
- package/dist/runtime/public/islands/page-5f87c34c7c181387.js.gz +0 -0
- package/dist/runtime/public/islands/rt-30ff0d94ee3732a1.js.br +0 -0
- package/dist/runtime/public/islands/rt-30ff0d94ee3732a1.js.gz +0 -0
- package/dist/runtime/public/islands/sqlite-engine-9fc56fea8b1e2aaf.js.br +0 -0
- package/dist/runtime/public/islands/sqlite-engine-9fc56fea8b1e2aaf.js.gz +0 -0
- package/dist/runtime/public/islands/ssr-456cabbcb26f723d.js.br +0 -0
- package/dist/runtime/public/islands/ssr-456cabbcb26f723d.js.gz +0 -0
- package/dist/runtime/public/islands/url-sync-74b5212f7b3417d7.js.br +0 -0
- package/dist/runtime/public/islands/url-sync-74b5212f7b3417d7.js.gz +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{m as e}from"./solid-app-
|
|
1
|
+
import{m as e}from"./solid-app-BNcsMwv4.js";import"./src-CcX8uAQo.js";import"./sign-in-required-7zEVbzx2.js";var t=[{name:`_me.id`,type:`user`,source:`platform`,readOnly:!0,query:!0,markup:!0,summary:`The reader's account id; null for a guest.`},{name:`_now`,type:`timestamp`,source:`platform`,readOnly:!0,query:!0,markup:!1,summary:`The current instant, UTC ISO; the same on the server and in the browser.`},{name:`_tz`,type:`string`,source:`platform`,readOnly:!0,query:!0,markup:!1,summary:`The reader's IANA time zone (UTC when unknown).`},{name:`_row`,type:null,source:`control`,readOnly:!0,query:!1,markup:!1,summary:`A field of the row the control sits in: $_row.<column>.`},{name:`_value`,type:null,source:`control`,readOnly:!0,query:!1,markup:!1,summary:`The new value an editing cell holds.`}],n=/^_row\.([A-Za-z_]\w*)$/;function r(e){let r=n.test(e)?`_row`:e;return t.find(e=>e.name===r)??null}var i=`_me.id`,a=e=>e.startsWith(`_`)?`names beginning with _ belong to the built-ins ($_me.id, $_now, $_row.<column>)`:e.startsWith(`ref_`)?`ref_<id> once named a dataset table; read a dataset through <Import>`:e.includes(`__`)?`a double underscore is how SQL spells a built-in field ($_me.id binds as $_me__id)`:null,o={User:new Set([`userId`]),UserImage:new Set([`userId`]),UserHandle:new Set([`userId`])};function s(e){if(typeof e!=`string`||!e||e.length>64)return`UTC`;try{return new Intl.DateTimeFormat(`en-US`,{timeZone:e}),e}catch{return`UTC`}}function c(){try{return s(Intl.DateTimeFormat().resolvedOptions().timeZone)}catch{return`UTC`}}var l=`mx:document`,u=`mx:reader-mode`,ee=`mx:frame-hash`,te=`mx:url-values`,d=`mx:navigate`,f=`mx:navigating`,ne=`mx:data`,p=`data`,re=`mx:edit-mode`,m=`mx:edit-ready`,h=`mx:inline`,g=`mx:paste`,_=`mx:block-edit`,v=`mx:history`,y=`mx:flow-edit`,b=`mx:text-edit`,x=`mx:open-script`,S=`mx:typing`,C=`mx:selection`,w=`mx:selection-action`,T=`mx:selection-actions`,E=`mx:image-drop`,D=`mx:image-replace`,O=`mx:edit-key`,k=`mx:apply-format`,A=`mx:apply-link`,j=`mx:layout-edit`,M=`mx:slide-title`,N=`mx:commit`,P=`mx:committed`,F=`mx:select`,I=`mx:spotlight`,L=`mx:annotations`,R=`mx:annotation-pin`,z=`mx:annotation-hover`,B=`mx:annotation-layout`,V=`annotations`,H=`mx:edit-flush`,U=`mx:comment-key`,W=`mx:frame-bridge`;function G(e){if(!e||typeof e!=`object`)return!1;let t=e;return t.type===`mx:frame-bridge`&&!!t.payload&&typeof t.payload==`object`&&typeof t.payload.kind==`string`}var K=new Set([`mx:edit-error`,_,v,y,m,b,S,C,w,O,P,j,M,E,D,R,z,B,H,U,x]);function q(e,t){if(!e||typeof e!=`object`)return!1;let n=e;return typeof n.type==`string`&&K.has(n.type)&&n.nonce===t}async function J(e,t={}){let n=new Map,r=new Set,i;for(;;){let a=i?`${e}${e.includes(`?`)?`&`:`?`}cursor=${encodeURIComponent(i)}`:e,o=await fetch(a,{credentials:`same-origin`,...t});if(!o.ok)throw Error(`Annotation read failed (HTTP ${o.status})`);let s=await o.json();if(!Array.isArray(s.annotations))throw Error(`Invalid annotation page`);for(let e of s.annotations)n.set(e.id,e);if(s.next_cursor==null)return[...n.values()];if(typeof s.next_cursor!=`string`||!s.next_cursor||r.has(s.next_cursor))throw Error(`Invalid annotation cursor`);r.add(s.next_cursor),i=s.next_cursor}}function Y(e,t=fetch){let n=new AbortController,r=`/a/${encodeURIComponent(e)}`,i=async(e,r={},i=!1)=>{n.signal.throwIfAborted();let a=await t(e,{...r,credentials:`same-origin`,signal:r.signal?AbortSignal.any([n.signal,r.signal]):n.signal});n.signal.throwIfAborted();let o=i?await a.json().catch(()=>({error:`fetch_failed`})):await a.json();if(n.signal.throwIfAborted(),!a.ok&&!i)throw Error(o.detail??o.error??`request failed (${a.status})`);return o},a=(e,t)=>i(e,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(t)}),o=e=>a(`${r}/query`,e);return{dispose:()=>n.abort(),run:(e,t,n)=>o({values:e,only:t,tz:c(),...n?{localTables:n}:{}}),hold:async e=>(await a(`${r}/query`,{hold:e})).tables,people:async e=>(await a(`${r}/query`,{people:e})).people,page:async(e,t,n,r)=>{let i=await o({values:e,only:[t],page:{name:t,...n},tz:c(),...r?{localTables:r}:{}});if(!i.tables[t])throw Error(i.errors[t]??`no rows for ${t}`);return i.tables[t]},mutate:async e=>{let t=await a(`${r}/mutate`,{tz:c(),...e});if(!t.ok)throw Error(t.detail??t.error??`write failed`);return{dataset:t.dataset??``,local:t.local,mutationRunId:t.mutationRunId}},importAsset:async(e,t,n)=>{let a=new URLSearchParams({u:e,...t?{kind:t}:{}}),o=await i(`${r}/assets?${a}`,{headers:{Accept:`application/json`},signal:n},!0);return o.url?{url:o.url,image:o.image}:{refused:o.code??o.error??`fetch_failed`}}}}var X=class extends Error{status;signInRequired;constructor(e,t,n=!1){super(e),this.name=`BackendRequestError`,this.status=t,this.signInRequired=n}},Z={"Content-Type":`application/json`};function Q(e){let t=`/api/my/artifacts/${encodeURIComponent(e)}`;return{head:()=>fetch(t),version:e=>fetch(`${t}/versions/${e}`),edits:e=>fetch(`${t}/edits`,{method:`POST`,headers:Z,body:JSON.stringify(e)}),patch:e=>fetch(t,{method:`PATCH`,headers:Z,body:JSON.stringify(e)}),revert:e=>fetch(`${t}/revert`,{method:`POST`,headers:Z,body:JSON.stringify(e)})}}function ie(e,t){let n=`Could not save comment (${e})`;if(!t||typeof t!=`object`)return n;let{error:r,detail:i,details:a}=t,o=typeof r==`string`?r:n,s=typeof i==`string`?i:Array.isArray(a)&&typeof a[0]?.message==`string`?a[0].message:null;return s?`${o}: ${s}`:o}var $=async e=>({ok:e.ok,status:e.status,body:await e.json().catch(()=>({}))});function ae(t){let n=`/api/my/artifacts/${t}`,r=async(e,t,n)=>{let r=await fetch(`/api/my/artifacts?visibility=unlisted`,{method:`POST`,...e}).catch(()=>null);return r?r.ok?{ok:!0,image:await r.json()}:{ok:!1,error:await t(r)}:{ok:!1,error:n}};return{mode:`online`,unavailable:()=>null,async load(){let e=await fetch(n);return e.ok?await e.json():null},async commitEdit(e){return $(await fetch(`${n}/edits`,{method:`POST`,headers:Z,body:JSON.stringify(e)}))},async prepare(e){let n=await fetch(`/api/my/artifacts/${encodeURIComponent(t)}/prepare`,{method:`POST`,headers:Z,body:JSON.stringify({source:e})});if(n.ok)return n.json();let r=await n.json().catch(()=>({})),i=r.details?.map(e=>typeof e==`string`?e:e?.message).filter(Boolean).join(`
|
|
2
2
|
`);throw Error(i||r.error||`Unable to prepare document resources`)},async previewCss(e){let t=await fetch(`/api/preview`,{method:`POST`,headers:Z,body:JSON.stringify({markup:e})});if(!t.ok)throw new X(`preview refused`,t.status);let n=await t.json();if(typeof n.css!=`string`)throw new X(`no stylesheet`,t.status);return{css:n.css}},async previewQueries(e){let t=await fetch(`/api/query`,{method:`POST`,headers:Z,body:JSON.stringify({markup:e})});return t.ok?await t.json():null},async queryTable(e,t){let n=await fetch(`/a/${encodeURIComponent(e)}/tables`,{method:`POST`,credentials:`same-origin`,headers:Z,body:JSON.stringify(t)}),r=await n.json();if(!n.ok)throw new X(r.details?.[0]??r.error??`unavailable`,n.status);return r},importImage(e){return`imageUrl`in e?r({headers:Z,body:JSON.stringify({imageUrl:e.imageUrl})},async e=>(await e.json().catch(()=>null))?.details?.[0]??(e.status===403?`You have reached your artifact limit.`:`Could not import that image.`),`Import failed — check your connection and try again.`):r({headers:{"Content-Type":e.file.type},body:e.file},async e=>{let t=await e.json().then(e=>e?.error).catch(()=>null);return e.status===413?`That image is too large to upload.`:e.status===403?`You have reached your artifact limit.`:t===`invalid_image`?`That image type is not supported (png, jpeg, webp, gif, svg).`:`Could not upload that image.`},`Upload failed — check your connection and try again.`)},async versions(){let e=await fetch(`${n}/versions`);return e.ok?(await e.json()).versions:null},async version(e){let t=await fetch(`${n}/versions/${e}`);return t.ok?await t.json():null},async revert(e){return $(await Q(t).revert(e))},live(n,r){let i=e({url:`/a/${t}/events${r?.since?`?since=${encodeURIComponent(r.since)}`:``}`,onMessage:e=>{let t;try{t=JSON.parse(e)}catch{return}n.onPing(t)},events:{[p]:e=>{try{n.onData(JSON.parse(e))}catch{}},[V]:()=>n.onAnnotations()},onWake:n.onWake});return()=>i.close()},async liveFrame(){let e=await fetch(`/a/${t}/events/frame`,{credentials:`same-origin`});return e.ok?await e.json():null},queryTransport:()=>Y(t),listAnnotations(e,t={}){return J(`${n}/annotations${e?`?status=${e}`:``}`,t)},async createAnnotation(e,t){let r=await fetch(`${n}/annotations`,{method:`POST`,headers:{...Z,"Idempotency-Key":t},body:JSON.stringify(e)});if(r.ok)return await r.json();let i=await r.json().catch(()=>null),a=i&&typeof i==`object`?i:{};throw new X(ie(r.status,i),r.status,a.error===`sign_in_required`||a.code===`sign_in_required`)},async actOnAnnotation(e,t){let r=await fetch(`${n}/annotations/${e}`,{method:`POST`,headers:Z,body:JSON.stringify(t)});if(!r.ok)throw new X(`Could not update this comment (${r.status})`,r.status);return await r.json()},async deleteAnnotation(e){if(!(await fetch(`${n}/annotations/${e}`,{method:`DELETE`})).ok)throw Error(`Could not delete this comment. Try again.`)},async uploadCommentImage(e){let t=await fetch(`${n}/comment-images`,{method:`POST`,body:e});if(!t.ok){let e=await t.json();throw Error(e.error===`stale`?`The document changed. Your draft is preserved; retake the screenshot.`:e.error===`quota_exceeded`?`Image storage quota reached.`:`Could not upload the screenshot. Please retry.`)}return await t.json()},async members(e,n={}){let r=await fetch(`/api/my/artifacts/${encodeURIComponent(t)}/members${e===void 0?``:`?query=${encodeURIComponent(e)}`}`,{signal:n.signal});return r.ok?await r.json():null},async remoteSessions(e={}){let t=await fetch(`/api/remote/sessions`,{credentials:`same-origin`,signal:e.signal});return t.ok?await t.json():{sessions:[]}},async deleteRemoteSession(e){let t=await fetch(`/api/remote/sessions/${e}`,{method:`DELETE`,credentials:`same-origin`});if(!t.ok){let e=await t.json().catch(()=>null);throw Error(e?.error??`Could not remove agent. Try again.`)}}}}export{u as A,q as B,D as C,f as D,d as E,M as F,a as G,o as H,I,b as L,w as M,C as N,x as O,F as P,S as R,E as S,j as T,i as U,G as V,r as W,re as _,z as a,W as b,k as c,P as d,N as f,O as g,l as h,L as i,T as j,g as k,A as l,ne as m,ae as n,B as o,p,X as r,R as s,Q as t,_ as u,m as v,h as w,ee as x,y,te as z};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`M3 5h.01`,key:`18ugdj`}],[`path`,{d:`M3 12h.01`,key:`nlz23k`}],[`path`,{d:`M3 19h.01`,key:`noohij`}],[`path`,{d:`M8 5h13`,key:`1pao27`}],[`path`,{d:`M8 12h13`,key:`1za7za`}],[`path`,{d:`M8 19h13`,key:`m83p4d`}]],i=i=>t(n,e(i,{iconNode:r,name:`list`}));export{i as t};
|
|
Binary file
|
|
Binary file
|
package/dist/runtime/dist/web/assets/{loader-circle-BXxJOPx-.js → loader-circle-2p_rsu6P.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]],i=i=>t(n,e(i,{iconNode:r,name:`loader-circle`}));export{i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`rect`,{width:`18`,height:`11`,x:`3`,y:`11`,rx:`2`,ry:`2`,key:`1w4ew1`}],[`path`,{d:`M7 11V7a5 5 0 0 1 10 0v4`,key:`fwvmzm`}]],i=i=>t(n,e(i,{iconNode:r,name:`lock`}));export{i as t};
|
|
Binary file
|
|
Binary file
|
package/dist/runtime/dist/web/assets/{person-mentions-BEjAedYZ.js → person-mentions-C7vQd7Vr.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BtmRR9Ax.js";import{c as r,d as i,f as a,i as o,l as s,u as c}from"./serialize-n0A-pNlo.js";import"./src-CcX8uAQo.js";import{n as l,t as u}from"./artifact-reference-ChS4TSVz.js";import{G as d,H as f,U as p,W as m}from"./http-C2exCIpl.js";var h=[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]],g=r=>t(n,e(r,{iconNode:h,name:`pencil`})),_=[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]],v=r=>t(n,e(r,{iconNode:_,name:`trash-2`})),y=[`Question`,`Number`,...o],b=`Import`,x=`Value`,S=`Query`,C=`Mutation`,w=`Notify`,T=[`string`,`number`,`boolean`,`date`,`timestamp`,`user`,`table`],E=/^\$([A-Za-z_]\w*(?:\.[A-Za-z_]\w*)?)$/,D=/^[A-Za-z_]\w*$/;function O(e){if(typeof e!=`string`)return null;let t=E.exec(e);return t&&(!t[1].includes(`.`)||m(t[1])?.markup)?t[1]:null}function k(e){if(typeof e==`string`){let t=E.exec(e);return t?{ref:t[1]}:{literal:e}}return e===null||typeof e==`boolean`||typeof e==`number`&&Number.isFinite(e)?{literal:e}:null}function A(e){if(!e||typeof e!=`object`||Array.isArray(e))return null;let t={};for(let[n,r]of Object.entries(e)){let e=k(r);if(!e||!D.test(n))return null;t[n]=e}return t}var j=/\{\s*\$([A-Za-z_]\w*)\s*\}/g;function M(e){return typeof e==`string`?[...new Set([...e.matchAll(j)].map(e=>e[1]))]:[]}var N={components:{Question:{data:`table`},Number:{data:`table`},DataTable:{data:`table`},DeckGL:{data:`table`},Files:{data:`table`},Input:{value:`scalar`},Textarea:{value:`scalar`},Select:{value:`scalar`,options:`table`,run:`mutation`},Slider:{value:`scalar`},DatePicker:{value:`scalar`,run:`mutation`},Segmented:{value:`scalar`,options:`table`},Switch:{checked:`scalar`},Button:{run:`mutation`},Dialog:{open:`scalar`},DialogContent:{run:`mutation`},User:{userId:`scalar`},UserImage:{userId:`scalar`},UserHandle:{userId:`scalar`}},html:{input:{value:`scalar`,checked:`scalar`,run:`mutation`},textarea:{value:`scalar`,run:`mutation`},select:{value:`scalar`,options:`table`,run:`mutation`},img:{src:`scalar`}}},P={components:{},html:{img:new Set([`src`])}},F=(e,t,n)=>!!(n?P.components[e]:P.html[e.toLowerCase()])?.has(n?t:t.toLowerCase()),I=/^\d{4}-\d{2}-\d{2}([T ].*)?$/,L=(e,t,n,r)=>({message:e,tag:n,start:t.start,end:t.end,...r?{attr:r}:{}}),R=(e,t)=>{let n=e.attributes.find(e=>e.name===t);if(n)return n.value.static?{attr:n,json:n.value.json}:{attr:n}};function z(e,t,n){let r=R(e,`name`);if(!r)return n.push(L(`<${t}> needs a name attribute`,e,t,`name`)),null;if(typeof r.json!=`string`||!D.test(r.json))return n.push(L(`<${t}> name must be an identifier ([A-Za-z_][A-Za-z0-9_]*), got ${JSON.stringify(r.json??r.attr.value)}`,r.attr,t,`name`)),null;let i=d(r.json);return i?(n.push(L(`<${t}> name "${r.json}" is reserved — ${i}`,r.attr,t,`name`)),null):r.json}var B=(e,t)=>{if(e===null)return!0;switch(t){case`number`:return typeof e==`number`&&Number.isFinite(e);case`boolean`:return typeof e==`boolean`;case`timestamp`:return i(e);case`date`:return typeof e==`string`&&I.test(e);case`user`:case`string`:return typeof e==`string`}},V=new Set([`name`,`type`,`default`,`value`,`columns`,`source`,`column`,`constraints`,`url`]);function H(e){let t=x,n=[];for(let r of e.attributes)V.has(r.name)?r.value.static||n.push(L(`<Value> attribute "${r.name}" must be a JSON literal, got ${r.value.exprType}`,r,t,r.name)):n.push(L(`<Value> takes name, type, default, value, columns, url — not "${r.name}"`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=R(e,`type`),o=R(e,`source`),l=R(e,`column`),u=R(e,`constraints`),d=i?.json??(o?`user`:`string`);if(o&&(typeof o.json!=`string`||!/^ref:[A-Za-z0-9]{6,12}$/.test(o.json)||typeof l?.json!=`string`||!l.json||i||u))return{ok:!1,errors:[L(`A bound Value takes source="ref:<dataset>" and column="<field>"; type and constraints are inherited`,e,t,`source`)]};if(l&&!o)return{ok:!1,errors:[L(`Value column requires source`,e,t,`column`)]};let f;if(u)try{f=c({name:r,type:d,constraints:u.json}).constraints}catch(n){return{ok:!1,errors:[L(n instanceof Error?n.message:`Invalid constraints`,e,t,`constraints`)]}}if(!T.includes(d))return{ok:!1,errors:[L(`<Value name="${r}"> type must be one of ${T.join(` | `)}, got ${JSON.stringify(i?.json)}`,i?.attr??e,t,`type`)]};let p=R(e,`url`);if(p&&typeof p.json!=`boolean`)return{ok:!1,errors:[L(`<Value name="${r}"> url must be true or false, got ${JSON.stringify(p.json??p.attr.value)}`,p.attr,t,`url`)]};if(p&&d===`table`)return{ok:!1,errors:[L(`<Value name="${r}" type="table"> takes no url= — only a scalar <Value> travels in the link`,p.attr,t,`url`)]};let m=p?.json===!1,h=R(e,`default`),g=R(e,`value`),_=R(e,`columns`);if(d===`table`){if(h&&n.push(L(`<Value name="${r}" type="table"> holds its rows in value=, not default=`,h.attr,t,`default`)),!g)return{ok:!1,errors:[...n,L(`<Value name="${r}" type="table"> needs value={[{…}, …]} — a non-empty array of flat objects`,e,t,`value`)]};let i=g.json;if(!Array.isArray(i)||i.length===0&&!_)return{ok:!1,errors:[...n,L(`<Value name="${r}"> value must be a non-empty array of flat objects, or value={[]} with columns={[{name, type}]}`,g.attr,t,`value`)]};for(let[e,a]of i.entries()){if(typeof a!=`object`||!a||Array.isArray(a)){n.push(L(`<Value name="${r}"> value row ${e} is not an object — rows are flat objects`,g.attr,t,`value`));continue}for(let[i,o]of Object.entries(a))typeof o==`object`&&o&&n.push(L(`<Value name="${r}"> value row ${e} column "${i}" is nested — rows are flat objects`,g.attr,t,`value`))}if(n.length)return{ok:!1,errors:n};let a=i,o=s(a);if(_){let n=_.json;if(!(Array.isArray(n)&&n.every(e=>e&&typeof e==`object`&&!Array.isArray(e)&&typeof e.name==`string`&&T.includes(e.type??``)&&e.type!==`table`)))return{ok:!1,errors:[L(`<Value name="${r}"> columns must be [{name, type: string|number|boolean|date|timestamp|user}]`,_.attr,t,`columns`)]};let i;try{i=n.map(c)}catch(n){return{ok:!1,errors:[L(n instanceof Error?n.message:`Invalid columns`,e,t,`columns`)]}}let a=new Set(i.map(e=>e.name));o=[...i,...o.filter(e=>!a.has(e.name))]}return{ok:!0,decl:{kind:`table`,name:r,rows:a,columns:o,start:e.start,end:e.end}}}g&&n.push(L(`<Value name="${r}"> value= is for type="table" rows; a scalar's initial value is default=`,g.attr,t,`value`)),_&&n.push(L(`<Value name="${r}"> columns= is for type="table"`,_.attr,t,`columns`));let v=h?.json??null;return h&&!B(v,d)&&n.push(L(`<Value name="${r}" type="${d}"> default ${JSON.stringify(v)} is not a ${d}${d===`date`?` (use YYYY-MM-DD)`:``}`,h.attr,t,`default`)),n.length?{ok:!1,errors:n}:{ok:!0,decl:{kind:`scalar`,name:r,type:d,...o?{source:String(o.json).slice(4),column:String(l.json)}:{},...f?{constraints:f}:{},...m?{url:!1}:{},default:d===`timestamp`&&v!==null?a(v,r):v,start:e.start,end:e.end}}}function U(e){let t=e.children.filter(e=>e.type!==`text`||e.value.trim()!==``),n=t.length===1?t[0]:null;return n&&n.type===`expression`&&n.value.static&&typeof n.value.json==`string`?n.value.json:null}function W(e,t,n){let r=e.attributes.find(e=>e.name===t);if(!r)return;let i=r.value.static?r.value.json:void 0,a=typeof i==`string`?l.exec(i)?.[1]:void 0;if(!a){let a=typeof i==`string`&&u.test(i)?`ref:${i}`:`ref:<id>`;n.push(L(`${t} must be a literal artifact reference: ${t}="${a}"`,r,e.tag,t));return}return a}function G(e){let t=b,n=[];for(let r of e.attributes)r.name!==`name`&&r.name!==`src`&&n.push(L(`<Import> takes only name= and src="ref:<id>" — not "${r.name}"`,r,t,r.name));if(e.children.some(e=>e.type!==`text`||e.value.trim()!==``)&&n.push(L(`<Import> has no children: <Import name="…" src="ref:<id>" />`,e,t)),n.length)return{ok:!1,errors:n};let r=z(e,t,n),i=W(e,`src`,n);return e.attributes.some(e=>e.name===`src`)||n.push(L(`<Import${r?` name="${r}"`:``}> needs src="ref:<id>" — the dataset or folder it reads`,e,t,`src`)),!r||!i||n.length?{ok:!1,errors:n}:{ok:!0,decl:{name:r,ref:i,start:e.start,end:e.end}}}function K(e){let t=S,n=[];for(let r of e.attributes)r.name!==`name`&&r.name!==`source`&&n.push(L(`<Query> takes only name= and source= — the SQL is its child: <Query name="…">{\`select …\`}</Query>${r.name===`sql`?` (not a sql= attribute)`:``}`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=U(e);if(i===null)return{ok:!1,errors:[L(`<Query name="${r}"> holds a single template-literal child with the SQL: <Query name="${r}">{\`select …\`}</Query>`,e,t)]};if(i.trim()===``)return{ok:!1,errors:[L(`<Query name="${r}"> has empty SQL`,e,t)]};let a=W(e,`source`,n);return n.length?{ok:!1,errors:n}:{ok:!0,decl:{name:r,sql:i,...a?{source:a}:{},start:e.start,end:e.end}}}function q(e){let t=[];for(let n of e.attributes)n.name!==`name`&&n.name!==`on`&&n.name!==`source`&&t.push(L(`<Notify> takes only name=, on= and source=; its child is one static SQL template literal`,n,w,n.name));let n=z(e,w,t),r=W(e,`source`,t),i=R(e,`on`);(typeof i?.json!=`string`||!D.test(i.json)||d(i.json))&&t.push(L(`<Notify> on= must name a declared persistent Mutation`,i?.attr??e,w,`on`));let a=U(e);return(a===null||!a.trim())&&t.push(L(`<Notify> holds one non-empty static SQL template-literal child returning to and message`,e,w)),!n||t.length?{ok:!1,errors:t}:{ok:!0,decl:{name:n,on:i.json,sql:a,...r?{source:r}:{},start:e.start,end:e.end}}}function J(e){let t=C,n=[];for(let r of e.attributes)r.name===`source`?n.push(L(`<Mutation> takes no source= — import the dataset (<Import name="…" src="ref:<id>" />) and write its table by name: insert into <name>.rows …`,r,t,r.name)):r.name!==`name`&&r.name!==`expectedAffected`&&r.name!==`reset`&&n.push(L(`<Mutation> takes only name=, expectedAffected= and reset= — the SQL is its child: <Mutation name="…">{\`insert into <import>.rows …\`}</Mutation>${r.name===`sql`?` (not a sql= attribute)`:``}`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=U(e);if(i===null)return{ok:!1,errors:[L(`<Mutation name="${r}"> holds a single template-literal child with the SQL: <Mutation name="${r}">{\`insert into <import>.rows …\`}</Mutation>`,e,t)]};if(i.trim()===``)return{ok:!1,errors:[L(`<Mutation name="${r}"> has empty SQL`,e,t)]};let a=R(e,`expectedAffected`);if(a&&(typeof a.json!=`number`||!Number.isInteger(a.json)||a.json<0))return{ok:!1,errors:[L(`<Mutation expectedAffected> must be a non-negative integer`,a.attr,t,`expectedAffected`)]};let o=R(e,`reset`);if(o&&typeof o.json!=`string`)return{ok:!1,errors:[L(`<Mutation name="${r}"> reset must be a space-separated list of scalar <Value> names, got ${JSON.stringify(o.json??o.attr.value)}`,o.attr,t,`reset`)]};let s=typeof o?.json==`string`?o.json.trim().split(/\s+/).filter(Boolean):[];return{ok:!0,decl:{name:r,sql:i,...a?{expectedAffected:a.json}:{},...s.length?{reset:s}:{},start:e.start,end:e.end}}}var Y=new Set(y);function X(e){let t=[],n=(e,n,i,a)=>{if(e)for(let o of r(e).signals)t.push({name:o,tag:i,attr:a,expects:`scalar`,readOnly:!0,start:n.start,end:n.end})},i=e=>{for(let r of e){if(r.type===`expression`&&!r.value.static&&n(r.value.reactive,r,`expression`,`value`),r.type!==`element`)continue;r.control&&r.control.kind!==`fragment`&&n(r.control.test,r,`condition`,`test`);let e=r.isComponent&&!Y.has(r.tag);for(let i of r.attributes)if(!i.value.static)r.tag===`For`&&i.name===`each`&&i.value.reactive?.kind===`signal`?t.push({name:i.value.reactive.name,tag:r.tag,attr:i.name,expects:`table`,start:i.start,end:i.end}):e&&i.value.reactive?.kind===`signal`?t.push({name:i.value.reactive.name,tag:r.tag,attr:i.name,expects:`any`,readOnly:!0,start:i.start,end:i.end}):n(i.value.reactive,i,r.tag,i.name);else if(e&&typeof i.value.json==`string`){let e=O(i.value.json);e&&t.push({name:e,tag:r.tag,attr:i.name,expects:`any`,readOnly:!0,start:i.start,end:i.end})}for(let e of r.attributes)if(!(e.name!==`set`&&e.name!==`args`||!e.value.static))for(let[n,i]of Object.entries(A(e.value.json)??{}))e.name===`set`&&t.push({name:n,tag:r.tag,attr:e.name,expects:`scalar`,start:e.start,end:e.end}),`ref`in i&&!i.ref.startsWith(`_row.`)&&t.push({name:i.ref,tag:r.tag,attr:e.name,expects:`scalar`,readOnly:!0,start:e.start,end:e.end});let a=r.isComponent?N.components[r.tag]:N.html[r.tag.toLowerCase()];if(a)for(let e of r.attributes){let n=a[r.isComponent?e.name:e.name.toLowerCase()];if(!n||!e.value.static)continue;let i=!!(r.isComponent&&f[r.tag]?.has(e.name)),o=O(e.value.json);if(o){t.push({name:o,tag:r.tag,attr:e.name,expects:n,readOnly:i,start:e.start,end:e.end});continue}if(F(r.tag,e.name,r.isComponent))for(let a of M(e.value.json))t.push({name:a,tag:r.tag,attr:e.name,expects:n,readOnly:i,start:e.start,end:e.end})}i(r.children)}};return i(e),t}function Z(e,t){let n=[],r=new Map,i=(e,t,i,a)=>{if(r.has(e)){n.push(L(`"${e}" is declared twice in <Helmet> — every <Import>/<Value>/<Query>/<Mutation>/<Notify> name is unique`,i,a,`name`));return}r.set(e,t)};for(let t of e.imports)i(t.name,`import`,t,b);for(let t of e.values)i(t.name,t.kind===`table`?`table`:`scalar`,t,x);for(let t of e.queries)i(t.name,`table`,t,S);for(let t of e.mutations)i(t.name,`mutation`,t,C);for(let t of e.notifications??[])i(t.name,`notification`,t,w);let a=' — declare it in <Helmet> as <Value name="…" …/> or <Query name="…">{`…`}</Query>',o=e=>e===`scalar`?`a scalar <Value>`:e===`table`?`a table`:e===`import`?`an <Import> (read it in a <Query>: select … from <name>.rows)`:e===`notification`?`a <Notify>`:`a <Mutation>`;for(let e of t){if(e.name===`_me`){n.push(L(`<${e.tag} ${e.attr}="$_me"> — $_me is the reader as a row; read its id: $${p}`,e,e.tag,e.attr));continue}if(e.name.startsWith(`_`)){let t=m(e.name);t?.markup?(!e.readOnly||e.expects!==`scalar`)&&n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> cannot bind $${e.name} — built-ins are read-only. Read it in a condition ({$${e.name} ? … : …}) or show the person with <User userId="$${e.name}" />`,e,e.tag,e.attr)):n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> — ${t?`$${e.name} is not readable in markup`:`$${e.name} is not a built-in`}; markup reads $${p}`,e,e.tag,e.attr));continue}let t=r.get(e.name);t?e.expects!==`any`&&t!==e.expects&&n.push(L(e.expects===`table`?`<${e.tag} ${e.attr}="$${e.name}"> needs a table (a <Query> or a <Value type="table">), but "${e.name}" is ${o(t)}`:e.expects===`scalar`?`<${e.tag} ${e.attr}="$${e.name}"> binds a scalar value, but "${e.name}" is ${o(t)} — bind a <Value> (string | number | boolean | date | timestamp | user)`:`<${e.tag} ${e.attr}="$${e.name}"> needs a <Mutation>, but "${e.name}" is ${o(t)} — run= names the write a click performs`,e,e.tag,e.attr)):n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> refers to nothing declared${e.expects===`mutation`?' — declare it in <Helmet> as <Mutation name="…">{`insert into <import>.rows …`}</Mutation>':a}`,e,e.tag,e.attr))}for(let t of e.mutations)for(let e of t.reset??[]){let i=r.get(e);i!==`scalar`&&n.push(L(`<Mutation> "${t.name}" reset names "${e}", which is ${i?o(i):`not declared`} — reset clears scalar <Value>s${i?``:a}`,t,C,`reset`))}return n}var Q=`[A-Za-z0-9_-]{1,128}`;function $(e){return RegExp(`^/people/${Q}$`).test(e)}function ee(e){return e.matchAll(RegExp(`\\[(@[a-z0-9_]+)\\]\\(/people/(${Q})\\)`,`gi`))}function te(e){return`[@${e.username}](/people/${e.user_id})`}export{y as _,C as a,x as c,J as d,q as f,Z as g,O as h,b as i,X as l,H as m,te as n,w as o,K as p,ee as r,S as s,$ as t,G as u,v,g as y};
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";import{c as r,d as i,f as a,i as o,l as s,u as c}from"./serialize-n0A-pNlo.js";import"./src-CcX8uAQo.js";import{n as l,t as u}from"./artifact-reference-ChS4TSVz.js";import{G as d,H as f,U as p,W as m}from"./http-DEdzW08u.js";var h=[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]],g=r=>t(n,e(r,{iconNode:h,name:`pencil`})),_=[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]],v=r=>t(n,e(r,{iconNode:_,name:`trash-2`})),y=[`Question`,`Number`,...o],b=`Import`,x=`Value`,S=`Query`,C=`Mutation`,w=`Notify`,T=[`string`,`number`,`boolean`,`date`,`timestamp`,`user`,`table`],E=/^\$([A-Za-z_]\w*(?:\.[A-Za-z_]\w*)?)$/,D=/^[A-Za-z_]\w*$/;function O(e){if(typeof e!=`string`)return null;let t=E.exec(e);return t&&(!t[1].includes(`.`)||m(t[1])?.markup)?t[1]:null}function k(e){if(typeof e==`string`){let t=E.exec(e);return t?{ref:t[1]}:{literal:e}}return e===null||typeof e==`boolean`||typeof e==`number`&&Number.isFinite(e)?{literal:e}:null}function A(e){if(!e||typeof e!=`object`||Array.isArray(e))return null;let t={};for(let[n,r]of Object.entries(e)){let e=k(r);if(!e||!D.test(n))return null;t[n]=e}return t}var j=/\{\s*\$([A-Za-z_]\w*)\s*\}/g;function M(e){return typeof e==`string`?[...new Set([...e.matchAll(j)].map(e=>e[1]))]:[]}var N={components:{Question:{data:`table`},Number:{data:`table`},DataTable:{data:`table`},DeckGL:{data:`table`},Files:{data:`table`},Input:{value:`scalar`},Textarea:{value:`scalar`},Select:{value:`scalar`,options:`table`,run:`mutation`},Slider:{value:`scalar`},DatePicker:{value:`scalar`,run:`mutation`},Segmented:{value:`scalar`,options:`table`},Switch:{checked:`scalar`},Button:{run:`mutation`},Dialog:{open:`scalar`},DialogContent:{run:`mutation`},User:{userId:`scalar`},UserImage:{userId:`scalar`},UserHandle:{userId:`scalar`}},html:{input:{value:`scalar`,checked:`scalar`,run:`mutation`},textarea:{value:`scalar`,run:`mutation`},select:{value:`scalar`,options:`table`,run:`mutation`},img:{src:`scalar`}}},P={components:{},html:{img:new Set([`src`])}},F=(e,t,n)=>!!(n?P.components[e]:P.html[e.toLowerCase()])?.has(n?t:t.toLowerCase()),I=/^\d{4}-\d{2}-\d{2}([T ].*)?$/,L=(e,t,n,r)=>({message:e,tag:n,start:t.start,end:t.end,...r?{attr:r}:{}}),R=(e,t)=>{let n=e.attributes.find(e=>e.name===t);if(n)return n.value.static?{attr:n,json:n.value.json}:{attr:n}};function z(e,t,n){let r=R(e,`name`);if(!r)return n.push(L(`<${t}> needs a name attribute`,e,t,`name`)),null;if(typeof r.json!=`string`||!D.test(r.json))return n.push(L(`<${t}> name must be an identifier ([A-Za-z_][A-Za-z0-9_]*), got ${JSON.stringify(r.json??r.attr.value)}`,r.attr,t,`name`)),null;let i=d(r.json);return i?(n.push(L(`<${t}> name "${r.json}" is reserved — ${i}`,r.attr,t,`name`)),null):r.json}var B=(e,t)=>{if(e===null)return!0;switch(t){case`number`:return typeof e==`number`&&Number.isFinite(e);case`boolean`:return typeof e==`boolean`;case`timestamp`:return i(e);case`date`:return typeof e==`string`&&I.test(e);case`user`:case`string`:return typeof e==`string`}},V=new Set([`name`,`type`,`default`,`value`,`columns`,`source`,`column`,`constraints`,`url`]);function H(e){let t=x,n=[];for(let r of e.attributes)V.has(r.name)?r.value.static||n.push(L(`<Value> attribute "${r.name}" must be a JSON literal, got ${r.value.exprType}`,r,t,r.name)):n.push(L(`<Value> takes name, type, default, value, columns, url — not "${r.name}"`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=R(e,`type`),o=R(e,`source`),l=R(e,`column`),u=R(e,`constraints`),d=i?.json??(o?`user`:`string`);if(o&&(typeof o.json!=`string`||!/^ref:[A-Za-z0-9]{6,12}$/.test(o.json)||typeof l?.json!=`string`||!l.json||i||u))return{ok:!1,errors:[L(`A bound Value takes source="ref:<dataset>" and column="<field>"; type and constraints are inherited`,e,t,`source`)]};if(l&&!o)return{ok:!1,errors:[L(`Value column requires source`,e,t,`column`)]};let f;if(u)try{f=c({name:r,type:d,constraints:u.json}).constraints}catch(n){return{ok:!1,errors:[L(n instanceof Error?n.message:`Invalid constraints`,e,t,`constraints`)]}}if(!T.includes(d))return{ok:!1,errors:[L(`<Value name="${r}"> type must be one of ${T.join(` | `)}, got ${JSON.stringify(i?.json)}`,i?.attr??e,t,`type`)]};let p=R(e,`url`);if(p&&typeof p.json!=`boolean`)return{ok:!1,errors:[L(`<Value name="${r}"> url must be true or false, got ${JSON.stringify(p.json??p.attr.value)}`,p.attr,t,`url`)]};if(p&&d===`table`)return{ok:!1,errors:[L(`<Value name="${r}" type="table"> takes no url= — only a scalar <Value> travels in the link`,p.attr,t,`url`)]};let m=p?.json===!1,h=R(e,`default`),g=R(e,`value`),_=R(e,`columns`);if(d===`table`){if(h&&n.push(L(`<Value name="${r}" type="table"> holds its rows in value=, not default=`,h.attr,t,`default`)),!g)return{ok:!1,errors:[...n,L(`<Value name="${r}" type="table"> needs value={[{…}, …]} — a non-empty array of flat objects`,e,t,`value`)]};let i=g.json;if(!Array.isArray(i)||i.length===0&&!_)return{ok:!1,errors:[...n,L(`<Value name="${r}"> value must be a non-empty array of flat objects, or value={[]} with columns={[{name, type}]}`,g.attr,t,`value`)]};for(let[e,a]of i.entries()){if(typeof a!=`object`||!a||Array.isArray(a)){n.push(L(`<Value name="${r}"> value row ${e} is not an object — rows are flat objects`,g.attr,t,`value`));continue}for(let[i,o]of Object.entries(a))typeof o==`object`&&o&&n.push(L(`<Value name="${r}"> value row ${e} column "${i}" is nested — rows are flat objects`,g.attr,t,`value`))}if(n.length)return{ok:!1,errors:n};let a=i,o=s(a);if(_){let n=_.json;if(!(Array.isArray(n)&&n.every(e=>e&&typeof e==`object`&&!Array.isArray(e)&&typeof e.name==`string`&&T.includes(e.type??``)&&e.type!==`table`)))return{ok:!1,errors:[L(`<Value name="${r}"> columns must be [{name, type: string|number|boolean|date|timestamp|user}]`,_.attr,t,`columns`)]};let i;try{i=n.map(c)}catch(n){return{ok:!1,errors:[L(n instanceof Error?n.message:`Invalid columns`,e,t,`columns`)]}}let a=new Set(i.map(e=>e.name));o=[...i,...o.filter(e=>!a.has(e.name))]}return{ok:!0,decl:{kind:`table`,name:r,rows:a,columns:o,start:e.start,end:e.end}}}g&&n.push(L(`<Value name="${r}"> value= is for type="table" rows; a scalar's initial value is default=`,g.attr,t,`value`)),_&&n.push(L(`<Value name="${r}"> columns= is for type="table"`,_.attr,t,`columns`));let v=h?.json??null;return h&&!B(v,d)&&n.push(L(`<Value name="${r}" type="${d}"> default ${JSON.stringify(v)} is not a ${d}${d===`date`?` (use YYYY-MM-DD)`:``}`,h.attr,t,`default`)),n.length?{ok:!1,errors:n}:{ok:!0,decl:{kind:`scalar`,name:r,type:d,...o?{source:String(o.json).slice(4),column:String(l.json)}:{},...f?{constraints:f}:{},...m?{url:!1}:{},default:d===`timestamp`&&v!==null?a(v,r):v,start:e.start,end:e.end}}}function U(e){let t=e.children.filter(e=>e.type!==`text`||e.value.trim()!==``),n=t.length===1?t[0]:null;return n&&n.type===`expression`&&n.value.static&&typeof n.value.json==`string`?n.value.json:null}function W(e,t,n){let r=e.attributes.find(e=>e.name===t);if(!r)return;let i=r.value.static?r.value.json:void 0,a=typeof i==`string`?l.exec(i)?.[1]:void 0;if(!a){let a=typeof i==`string`&&u.test(i)?`ref:${i}`:`ref:<id>`;n.push(L(`${t} must be a literal artifact reference: ${t}="${a}"`,r,e.tag,t));return}return a}function G(e){let t=b,n=[];for(let r of e.attributes)r.name!==`name`&&r.name!==`src`&&n.push(L(`<Import> takes only name= and src="ref:<id>" — not "${r.name}"`,r,t,r.name));if(e.children.some(e=>e.type!==`text`||e.value.trim()!==``)&&n.push(L(`<Import> has no children: <Import name="…" src="ref:<id>" />`,e,t)),n.length)return{ok:!1,errors:n};let r=z(e,t,n),i=W(e,`src`,n);return e.attributes.some(e=>e.name===`src`)||n.push(L(`<Import${r?` name="${r}"`:``}> needs src="ref:<id>" — the dataset or folder it reads`,e,t,`src`)),!r||!i||n.length?{ok:!1,errors:n}:{ok:!0,decl:{name:r,ref:i,start:e.start,end:e.end}}}function K(e){let t=S,n=[];for(let r of e.attributes)r.name!==`name`&&r.name!==`source`&&n.push(L(`<Query> takes only name= and source= — the SQL is its child: <Query name="…">{\`select …\`}</Query>${r.name===`sql`?` (not a sql= attribute)`:``}`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=U(e);if(i===null)return{ok:!1,errors:[L(`<Query name="${r}"> holds a single template-literal child with the SQL: <Query name="${r}">{\`select …\`}</Query>`,e,t)]};if(i.trim()===``)return{ok:!1,errors:[L(`<Query name="${r}"> has empty SQL`,e,t)]};let a=W(e,`source`,n);return n.length?{ok:!1,errors:n}:{ok:!0,decl:{name:r,sql:i,...a?{source:a}:{},start:e.start,end:e.end}}}function q(e){let t=[];for(let n of e.attributes)n.name!==`name`&&n.name!==`on`&&n.name!==`source`&&t.push(L(`<Notify> takes only name=, on= and source=; its child is one static SQL template literal`,n,w,n.name));let n=z(e,w,t),r=W(e,`source`,t),i=R(e,`on`);(typeof i?.json!=`string`||!D.test(i.json)||d(i.json))&&t.push(L(`<Notify> on= must name a declared persistent Mutation`,i?.attr??e,w,`on`));let a=U(e);return(a===null||!a.trim())&&t.push(L(`<Notify> holds one non-empty static SQL template-literal child returning to and message`,e,w)),!n||t.length?{ok:!1,errors:t}:{ok:!0,decl:{name:n,on:i.json,sql:a,...r?{source:r}:{},start:e.start,end:e.end}}}function J(e){let t=C,n=[];for(let r of e.attributes)r.name===`source`?n.push(L(`<Mutation> takes no source= — import the dataset (<Import name="…" src="ref:<id>" />) and write its table by name: insert into <name>.rows …`,r,t,r.name)):r.name!==`name`&&r.name!==`expectedAffected`&&r.name!==`reset`&&n.push(L(`<Mutation> takes only name=, expectedAffected= and reset= — the SQL is its child: <Mutation name="…">{\`insert into <import>.rows …\`}</Mutation>${r.name===`sql`?` (not a sql= attribute)`:``}`,r,t,r.name));if(n.length)return{ok:!1,errors:n};let r=z(e,t,n);if(!r)return{ok:!1,errors:n};let i=U(e);if(i===null)return{ok:!1,errors:[L(`<Mutation name="${r}"> holds a single template-literal child with the SQL: <Mutation name="${r}">{\`insert into <import>.rows …\`}</Mutation>`,e,t)]};if(i.trim()===``)return{ok:!1,errors:[L(`<Mutation name="${r}"> has empty SQL`,e,t)]};let a=R(e,`expectedAffected`);if(a&&(typeof a.json!=`number`||!Number.isInteger(a.json)||a.json<0))return{ok:!1,errors:[L(`<Mutation expectedAffected> must be a non-negative integer`,a.attr,t,`expectedAffected`)]};let o=R(e,`reset`);if(o&&typeof o.json!=`string`)return{ok:!1,errors:[L(`<Mutation name="${r}"> reset must be a space-separated list of scalar <Value> names, got ${JSON.stringify(o.json??o.attr.value)}`,o.attr,t,`reset`)]};let s=typeof o?.json==`string`?o.json.trim().split(/\s+/).filter(Boolean):[];return{ok:!0,decl:{name:r,sql:i,...a?{expectedAffected:a.json}:{},...s.length?{reset:s}:{},start:e.start,end:e.end}}}var Y=new Set(y);function X(e){let t=[],n=(e,n,i,a)=>{if(e)for(let o of r(e).signals)t.push({name:o,tag:i,attr:a,expects:`scalar`,readOnly:!0,start:n.start,end:n.end})},i=e=>{for(let r of e){if(r.type===`expression`&&!r.value.static&&n(r.value.reactive,r,`expression`,`value`),r.type!==`element`)continue;r.control&&r.control.kind!==`fragment`&&n(r.control.test,r,`condition`,`test`);let e=r.isComponent&&!Y.has(r.tag);for(let i of r.attributes)if(!i.value.static)r.tag===`For`&&i.name===`each`&&i.value.reactive?.kind===`signal`?t.push({name:i.value.reactive.name,tag:r.tag,attr:i.name,expects:`table`,start:i.start,end:i.end}):e&&i.value.reactive?.kind===`signal`?t.push({name:i.value.reactive.name,tag:r.tag,attr:i.name,expects:`any`,readOnly:!0,start:i.start,end:i.end}):n(i.value.reactive,i,r.tag,i.name);else if(e&&typeof i.value.json==`string`){let e=O(i.value.json);e&&t.push({name:e,tag:r.tag,attr:i.name,expects:`any`,readOnly:!0,start:i.start,end:i.end})}for(let e of r.attributes)if(!(e.name!==`set`&&e.name!==`args`||!e.value.static))for(let[n,i]of Object.entries(A(e.value.json)??{}))e.name===`set`&&t.push({name:n,tag:r.tag,attr:e.name,expects:`scalar`,start:e.start,end:e.end}),`ref`in i&&!i.ref.startsWith(`_row.`)&&t.push({name:i.ref,tag:r.tag,attr:e.name,expects:`scalar`,readOnly:!0,start:e.start,end:e.end});let a=r.isComponent?N.components[r.tag]:N.html[r.tag.toLowerCase()];if(a)for(let e of r.attributes){let n=a[r.isComponent?e.name:e.name.toLowerCase()];if(!n||!e.value.static)continue;let i=!!(r.isComponent&&f[r.tag]?.has(e.name)),o=O(e.value.json);if(o){t.push({name:o,tag:r.tag,attr:e.name,expects:n,readOnly:i,start:e.start,end:e.end});continue}if(F(r.tag,e.name,r.isComponent))for(let a of M(e.value.json))t.push({name:a,tag:r.tag,attr:e.name,expects:n,readOnly:i,start:e.start,end:e.end})}i(r.children)}};return i(e),t}function Z(e,t){let n=[],r=new Map,i=(e,t,i,a)=>{if(r.has(e)){n.push(L(`"${e}" is declared twice in <Helmet> — every <Import>/<Value>/<Query>/<Mutation>/<Notify> name is unique`,i,a,`name`));return}r.set(e,t)};for(let t of e.imports)i(t.name,`import`,t,b);for(let t of e.values)i(t.name,t.kind===`table`?`table`:`scalar`,t,x);for(let t of e.queries)i(t.name,`table`,t,S);for(let t of e.mutations)i(t.name,`mutation`,t,C);for(let t of e.notifications??[])i(t.name,`notification`,t,w);let a=' — declare it in <Helmet> as <Value name="…" …/> or <Query name="…">{`…`}</Query>',o=e=>e===`scalar`?`a scalar <Value>`:e===`table`?`a table`:e===`import`?`an <Import> (read it in a <Query>: select … from <name>.rows)`:e===`notification`?`a <Notify>`:`a <Mutation>`;for(let e of t){if(e.name===`_me`){n.push(L(`<${e.tag} ${e.attr}="$_me"> — $_me is the reader as a row; read its id: $${p}`,e,e.tag,e.attr));continue}if(e.name.startsWith(`_`)){let t=m(e.name);t?.markup?(!e.readOnly||e.expects!==`scalar`)&&n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> cannot bind $${e.name} — built-ins are read-only. Read it in a condition ({$${e.name} ? … : …}) or show the person with <User userId="$${e.name}" />`,e,e.tag,e.attr)):n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> — ${t?`$${e.name} is not readable in markup`:`$${e.name} is not a built-in`}; markup reads $${p}`,e,e.tag,e.attr));continue}let t=r.get(e.name);t?e.expects!==`any`&&t!==e.expects&&n.push(L(e.expects===`table`?`<${e.tag} ${e.attr}="$${e.name}"> needs a table (a <Query> or a <Value type="table">), but "${e.name}" is ${o(t)}`:e.expects===`scalar`?`<${e.tag} ${e.attr}="$${e.name}"> binds a scalar value, but "${e.name}" is ${o(t)} — bind a <Value> (string | number | boolean | date | timestamp | user)`:`<${e.tag} ${e.attr}="$${e.name}"> needs a <Mutation>, but "${e.name}" is ${o(t)} — run= names the write a click performs`,e,e.tag,e.attr)):n.push(L(`<${e.tag} ${e.attr}="$${e.name}"> refers to nothing declared${e.expects===`mutation`?' — declare it in <Helmet> as <Mutation name="…">{`insert into <import>.rows …`}</Mutation>':a}`,e,e.tag,e.attr))}for(let t of e.mutations)for(let e of t.reset??[]){let i=r.get(e);i!==`scalar`&&n.push(L(`<Mutation> "${t.name}" reset names "${e}", which is ${i?o(i):`not declared`} — reset clears scalar <Value>s${i?``:a}`,t,C,`reset`))}return n}var Q=`[A-Za-z0-9_-]{1,128}`;function $(e){return RegExp(`^/people/${Q}$`).test(e)}function ee(e){return e.matchAll(RegExp(`\\[(@[a-z0-9_]+)\\]\\(/people/(${Q})\\)`,`gi`))}function te(e){return`[@${e.username}](/people/${e.user_id})`}export{y as _,C as a,x as c,J as d,q as f,Z as g,O as h,b as i,X as l,H as m,te as n,w as o,K as p,ee as r,S as s,$ as t,G as u,v,g as y};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]],i=i=>t(n,e(i,{iconNode:r,name:`plus`}));export{i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}]],i=i=>t(n,e(i,{iconNode:r,name:`rotate-ccw`}));export{i as t};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]],i=i=>t(n,e(i,{iconNode:r,name:`search`}));export{i as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{f as e}from"./DocumentChrome-EUbW_JvA.js";import{C as t,F as n,I as r,L as i,N as a,O as o,P as s,R as c,S as l,T as u,c as d,d as f,f as p,g as m,k as h,l as g,u as _,v,w as y,y as b}from"./http-C2exCIpl.js";import{D as x,E as S,T as C,f as w,i as T,n as E,o as D,p as O,s as k,u as A}from"./grid-layout-pVrfI_vF.js";import{r as j,t as M}from"./annotation-range-DqD0nTBm.js";import{a as N,c as P,i as F,o as I,s as L,t as R}from"./flow-view-Bp05LtJW.js";import{t as z}from"./runtime-id-CM5my_RX.js";import{t as B}from"./node-names-DHdYya8V.js";var V=1,H=3,U=e=>`outline: ${V}px solid ${e}; outline-offset: ${H}px;`,W=e=>e.replaceAll(`;`,` !important;`),G=e=>`rgba(100, 116, 139, ${e})`,K={selectedCss:`${U(`rgba(245, 158, 11, 0.85)`)} border-radius: 3px;`,editSelectedCss:W(U(G(.55))),handleColor:G(.6),handleDot:G(.45),handleActive:G(.95),spotlightCss:W(`outline: 2px dashed rgba(245, 158, 11, 0.9); outline-offset: ${H}px; border-radius: 3px; background: rgba(245, 158, 11, 0.06);`),handleOutset:3.5},q=new Set([`span`,`strong`,`b`,`em`,`i`,`a`,`code`,`br`,`small`,`sup`,`sub`,`s`,`del`,`u`]),ee=`http://www.w3.org/2000/svg`,J=new Set([`thead`,`tbody`,`tfoot`,`tr`,`td`,`th`,`caption`,`colgroup`,`col`]);function te(t){let n=t.localName,r=!!t.querySelector(`[${e}]`);return t.closest(`.ProseMirror`)?r?`container`:n===`hr`||n===`img`?`block`:`text`:t.closest(`[contenteditable="true"]`)?`text`:r?`container`:`block`}function ne(e,t){if(e?.type!==`element`||t?.type!==`element`||!e.isComponent||!t.isComponent||e.tag===`GridItem`||e.tag===t.tag)return!1;let n=e=>/^[A-Z][a-z]+/.exec(e)?.[0];return!!n(e.tag)&&n(e.tag)===n(t.tag)&&e.children.some(e=>e.type===`element`)}var Y=e=>e.split(`.`).slice(0,-1).join(`.`);function re(t,n){for(let r=t;r;r=r.parentElement?.closest(`[data-mx-ast]`)??null){let t=r.getAttribute(e),i=t?x(n,t):null;if(i?.type!==`element`)return null;if(!(q.has(i.tag)||J.has(i.tag)||r.namespaceURI===ee&&i.tag!==`svg`)&&!ne(i,x(n,Y(t)))){if(i.tag===`GridItem`){let e=x(n,Y(t)),r=e?.type===`element`?e.attributes.find(e=>e.name===`mode`)?.value:void 0;if(!(r?.static&&r.json===`flow`))return null}return r}}return null}function ie(e){if(e.tag===`GridItem`)return!0;let t=e.attributes.find(e=>e.name===`className`||e.name===`class`);return!t||t.value.static}function ae(e,t){if(!t)return null;let n=x(e,t);return!n||n.type!==`element`?null:n.isComponent?`embed`:S(n)?`text`:`element`}function oe(e,t,n){return!!t&&t.type===`element`&&!ne(t,x(n,e.split(`.`).slice(0,-1).join(`.`)))&&!S(t)&&e.includes(`.`)}function se(t,n){let r=[];for(let i=t.parentElement;i;i=i.parentElement){let t=i.getAttribute(e);if(!t)continue;let a=x(n,t);oe(t,a,n)&&r.push({path:t,tag:a.tag,hint:C(i.getAttribute(`class`)??``)})}return r.reverse()}function ce(t,n){let r=t.getAttribute(e);return r&&ae(n,r)||null}function le(t,n){let r=t.getAttribute(e);if(!r)return null;let i=ae(n,r);if(!i)return null;let a=x(n,r),o=a.attributes.find(e=>e.name.toLowerCase()===`id`),s=o?.value.static&&typeof o.value.json==`string`?o.value.json:void 0,c=t.getBoundingClientRect();return{kind:i,...t.closest(`.ProseMirror`)?{editor:`prose`}:{},customHeight:a.attributes.some(e=>e.name===`minHeight`&&e.value.static&&typeof e.value.json==`number`)||/\bmin-h-\[\d+px\]/.test(t.getAttribute(`class`)??``),path:r,...s?{nodeId:s}:{},tag:a.tag,rect:{x:c.x,y:c.y,width:c.width,height:c.height},className:t.getAttribute(`class`)??``,style:t.getAttribute(`style`)??``,ancestors:se(t,n)}}var ue=new Set([`p`,`h1`,`h2`,`h3`,`h4`,`h5`,`h6`,`li`,`blockquote`,`td`,`th`,`figcaption`,`dd`,`dt`,`pre`]);function de(e){let t=e.tagName.toLowerCase();if(ue.has(t))return!0;let n=e.parentElement?.tagName.toLowerCase()??``;return(e.hasAttribute(`data-mx-ast`)||e.hasAttribute(`data-mx-comment-target`))&&!ue.has(n)}function fe(e){let t=e?.nodeType===Node.ELEMENT_NODE?e:e?.parentElement??null;for(;t;t=t.parentElement)if(de(t)&&(t.hasAttribute(`data-mx-ast`)||t.hasAttribute(`data-mx-comment-target`)))return t;return null}function pe(e){let t=e.commonAncestorContainer;if(t.nodeType===Node.TEXT_NODE)return[{node:t,start:e.startOffset,end:e.endOffset}];let n=t.ownerDocument;if(!n)return[];let r=n.createTreeWalker(t,NodeFilter.SHOW_TEXT),i=[];for(let t=r.nextNode();t;t=r.nextNode()){let n=t;if(e.comparePoint(n,n.length)<0||e.comparePoint(n,0)>0)continue;let r=n===e.startContainer?e.startOffset:0,a=n===e.endContainer?e.endOffset:n.length;a>r&&i.push({node:n,start:r,end:a})}return i}function me(e){let t=e.ownerDocument,n=[],r=``;if(!t)return{text:r,pos:n};let i=t.createTreeWalker(e,NodeFilter.SHOW_TEXT),a=null,o=null;for(let e=i.nextNode();e;e=i.nextNode()){let t=e,i=t.data;for(let e=0;e<i.length;e++){let s=i[e];if(/\s/.test(s)){r.length>0&&!a&&(a={node:t,offset:e});continue}a&&=(r+=` `,n.push(a),null),r+=s,n.push({node:t,offset:e}),o={node:t,offset:e+1}}}return o&&n.push(o),{text:r,pos:n}}function he(e,t,n){return e.node===t?e.offset>=n:(t.compareDocumentPosition(e.node)&Node.DOCUMENT_POSITION_FOLLOWING)!==0}function ge(e,t,n){for(let r=0;r<e.pos.length;r++)if(he(e.pos[r],t,n))return Math.min(r,e.text.length);return e.text.length}var _e=e=>Array.from(e.children);function ve(e,t){let n=(e,t)=>{let n=[];for(let r=t;r&&r!==e;r=r.parentElement){let e=r.parentElement;if(!e)return null;n.unshift(_e(e).indexOf(r))}return n};if(t===e)return``;if(e.contains(t)){let r=n(e,t);return r?j({sibling:0,steps:r}):null}let r=e.parentElement;if(!r)return null;let i=t;for(;i&&i.parentElement!==r;)i=i.parentElement;if(!i)return null;let a=_e(r),o=a.indexOf(i)-a.indexOf(e);if(o<=0)return null;let s=n(i,t);return s?j({sibling:o,steps:s}):null}function ye(e,t){let n=[],r=``,i=null,a=pe(e);for(let e=0;e<a.length;){let o=a[e].node.parentElement,s=e;for(;s<a.length&&a[s].node.parentElement===o;)s++;let c=a.slice(e,s);if(e=s,!o)continue;let l=ve(t,o);if(l===null)continue;let u=me(o),d=ge(u,c[0].node,c[0].start),f=ge(u,c[c.length-1].node,c[c.length-1].end),p=u.text.slice(d,f);if(!p.trim())continue;n.push({rel:l,start:d,end:f,text:p});let m=fe(o)??o;i&&m!==i&&(r+=` `),r+=p,i=m}return{quote:M(r),range:{v:1,parts:n}}}function be(e,t){let n=e.getSelection();if(!n||n.isCollapsed||n.rangeCount===0)return null;let r=n.getRangeAt(0);if(!r.toString().trim()||t!==r.startContainer&&!t.contains(r.startContainer))return null;let i=ye(r,t);return i.range.parts.length>0?i:null}var xe={ArrowUp:`up`,ArrowDown:`down`,ArrowLeft:`left`,ArrowRight:`right`},Se=`.mx-rail, .mx-present, [data-mx-node-chrome]`,Ce=`[role="listbox"], [role="menu"], [role="combobox"], [role="grid"], [role="tree"]`,X=e=>e===`down`||e===`right`,we=e=>e===`up`||e===`down`;function Te(e){return e.defaultPrevented||e.isComposing||e.keyCode===229||e.shiftKey||e.ctrlKey||e.metaKey||e.altKey?null:xe[e.key]??null}function Ee(e,t,n){let r=e.indexOf(t);return r<0?null:e[r+(X(n)?1:-1)]??null}function De(e,t){let n=t=>e.contains(t)&&!t.closest(Se),r=[];for(let e of t)n(e.dom)&&r.push({el:e.dom,view:e});for(let t of e.querySelectorAll(`[data-mx-ast][contenteditable="true"]`)){if(!n(t)||t.closest(`.ProseMirror`))continue;let i=t.parentElement?.closest(`[contenteditable="true"]`);i&&e.contains(i)||r.push({el:t,view:null})}return r.sort((e,t)=>e.el===t.el?0:e.el.compareDocumentPosition(t.el)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1)}function Oe(e,{regions:t,selection:n,geometry:r}){let i=Te(e);if(!i||!n||n.rangeCount===0||!n.isCollapsed)return!1;let a=e.target;if(!a?.closest||a.closest(Ce))return!1;let o=t.find(e=>e.el.contains(n.anchorNode));if(!o||!o.el.contains(a)||!r.atEdge(o,i))return!1;let s=Ee(t.filter(e=>e===o||r.visible(e)),o,i);if(!s)return!1;let c=we(i)?r.caretX(o):null;return e.preventDefault(),e.stopPropagation(),r.enter(s,i,c),!0}var ke=(e,t,n)=>Math.max(t,Math.min(n,e)),Ae=e=>L.findFrom(e.resolve(0),1,!0),je=e=>L.findFrom(e.resolve(e.content.size),-1,!0);function Me(e,t){let{selection:n,doc:r}=e.state;if(!n.empty||!(n instanceof P))return!1;let i=X(t)?je(r):Ae(r);return i?we(t)?n.$head.start()===i.$head.start()&&e.endOfTextblock(t):n.head===i.head:!1}function Ne(e,t,n){let{doc:r}=e.state,i=X(t)?Ae(r):je(r);if(!i)return;let a=i.head;if(n!==null&&we(t))try{let t=e.domAtPos(a).node;(t.nodeType===1?t:t.parentElement)?.scrollIntoView?.({block:`nearest`});let i=e.coordsAtPos(a),o=e.dom.getBoundingClientRect(),s=e.posAtCoords({left:ke(n,o.left+1,o.right-1),top:(i.top+i.bottom)/2});s&&r.resolve(s.pos).parent.isTextblock&&(a=s.pos)}catch{}e.dispatch(e.state.tr.setSelection(P.create(r,a)).scrollIntoView()),e.focus()}var Pe=e=>typeof e.getClientRects==`function`?[...e.getClientRects()].filter(e=>e.width>0||e.height>0):[];function Fe(e){if(!e.rangeCount)return null;let t=e.getRangeAt(0),[n]=Pe(t);if(n)return n;let r=t.startContainer,i=(r.nodeType===1?r:r.parentElement)?.getBoundingClientRect?.();return i&&(i.width>0||i.height>0)?i:null}function Ie(e,t,n){let r=e.getSelection();if(!r?.rangeCount)return!1;let i=r.getRangeAt(0),a=e.document.createRange();if(a.selectNodeContents(t),X(n)?a.setStart(i.endContainer,i.endOffset):a.setEnd(i.startContainer,i.startOffset),!a.toString().trim())return!0;if(!we(n))return!1;let o=Fe(r);return o?!Pe(a).some(e=>{let t=e.top+e.height/2;return n===`down`?t>o.bottom:t<o.top}):!1}function Le(e,t,n){let r=e.caretPositionFromPoint?.(t,n);if(r){let t=e.createRange();return t.setStart(r.offsetNode,r.offset),t}return e.caretRangeFromPoint?.(t,n)??null}function Re(e,t,n,r){let i=e.document;t.scrollIntoView?.({block:`nearest`}),t.focus({preventScroll:!0});let a=null;if(r!==null&&we(n)){let e=i.createRange();e.selectNodeContents(t);let o=Pe(e);if(o.length){let e=X(n)?o.reduce((e,t)=>t.top<e.top?t:e):o.reduce((e,t)=>t.bottom>e.bottom?t:e),s=t.getBoundingClientRect(),c=Le(i,ke(r,s.left+1,s.right-1),e.top+e.height/2);c&&t.contains(c.startContainer)&&(a=c)}}if(!a){let e=i.createTreeWalker(t,NodeFilter.SHOW_TEXT),r=null;for(let t=e.nextNode();t&&!(t.data.trim()&&(r=t,X(n)));t=e.nextNode());a=i.createRange(),a.selectNodeContents(r??t),a.collapse(X(n))}a.collapse(!0);let o=e.getSelection();o?.removeAllRanges(),o?.addRange(a)}function ze(e){return{visible:({el:e})=>e.isConnected&&(e.checkVisibility?.()??!0),atEdge:(t,n)=>t.view?Me(t.view,n):Ie(e,t.el,n),caretX(t){try{if(t.view)return t.view.coordsAtPos(t.view.state.selection.head).left;let n=e.getSelection();return n?Fe(n)?.left??null:null}catch{return null}},enter:(t,n,r)=>t.view?Ne(t.view,n,r):Re(e,t.el,n,r)}}var Be=`.mx-rail, .mx-present`;function Ve(e){let t=e.createElement(`div`);t.setAttribute(`data-mx-drag-preview`,``),t.setAttribute(`aria-hidden`,`true`),Object.assign(t.style,{position:`fixed`,zIndex:`48`,pointerEvents:`none`,display:`none`,padding:`2px 8px`,borderRadius:`6px`,font:`500 12px/18px system-ui, sans-serif`,whiteSpace:`nowrap`,color:`#fff`,background:`rgba(51, 65, 85, 0.92)`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.18)`});let n=e.createElement(`div`);n.setAttribute(`data-mx-drop-marker`,``),Object.assign(n.style,{position:`fixed`,zIndex:`47`,pointerEvents:`none`,display:`none`,height:`3px`,borderRadius:`3px`,background:`#16a34a`,boxShadow:`0 0 0 2px rgba(22,163,74,.12)`});let r=e.createElement(`style`);e.head.append(r),e.body.append(t,n);let i=null,a=``,o={label:`Block`,parent:`container`},s=e=>e.split(`.`).slice(0,-1).join(`.`),c=e=>e.parentElement?.closest(`[data-mx-ast]`),l=()=>{i=null,t.style.display=n.style.display=`none`,r.textContent=``},u=()=>{if(!i)return[];let t=c(i),n=a.split(`.`).length;return[...(t??e).querySelectorAll(`[data-mx-ast]`)].filter(e=>{let t=e.getAttribute(`data-mx-ast`);return t.split(`.`).length===n&&s(t)===s(a)&&c(e)===c(i)&&!e.closest(Be)})},d=(e,t,n)=>{let r=null,i=1/0;for(let a of n){let n=a.getBoundingClientRect(),o=Math.max(n.left-e,0,e-n.right),s=Math.max(n.top-t,0,t-n.bottom),c=Math.hypot(o,s);c<i&&([r,i]=[a,c])}return r},f=(i,a,s)=>{t.textContent=s===`invalid`?`Can only move within this ${o.parent.toLowerCase()}`:`⠿ ${o.label}`,t.setAttribute(`data-mx-drop-state`,s),t.style.background=s===`invalid`?`rgba(220, 38, 38, 0.92)`:`rgba(51, 65, 85, 0.92)`,r.textContent=`* { cursor: ${s===`invalid`?`not-allowed`:`grabbing`} !important; }`,t.style.display=`block`;let{width:c,height:l}=t.getBoundingClientRect(),u=(e,t,n)=>{let r=e+14,i=e-14-t,a=r+t<=n-8||i<8?r:i;return Math.max(8,Math.min(a,n-t-8))};t.style.left=`${u(i,c,e.defaultView?.innerWidth??1e3)}px`,t.style.top=`${u(a,l,e.defaultView?.innerHeight??800)}px`,s!==`valid`&&(n.style.display=`none`)};return{start(e,t,n){i=e,a=t,n&&(o=n)},update(t,r,o){if(!i?.isConnected){l();return}let s=u(),c=o?s.find(e=>e.getAttribute(`data-mx-ast`)===o)??null:e.elementFromPoint(t,r)?.closest(`[data-mx-ast]`)??null;if(!o){for(;c&&!s.includes(c);)c=c.parentElement?.closest(`[data-mx-ast]`)??null;c??=d(t,r,s)}if(s.length<2){f(t,r,`invalid`);return}if(!c||c===i){f(t,r,`none`);return}let p=c.getAttribute(`data-mx-ast`),m=Number(p.split(`.`).at(-1))>Number(a.split(`.`).at(-1));f(t,r,`valid`),n.style.display=`block`;let h=c.getBoundingClientRect(),g=i.getBoundingClientRect(),_=Math.min(h.bottom,g.bottom)>Math.max(h.top,g.top)&&(h.left>=g.right||h.right<=g.left),v=m?h.left>=g.right?h.right:h.left:h.left<g.left?h.left:h.right;return Object.assign(n.style,_?{left:`${v}px`,top:`${h.top}px`,width:`3px`,height:`${h.height}px`}:{left:`${h.left}px`,top:`${m?h.bottom:h.top}px`,width:`${h.width}px`,height:`3px`}),p},clear:l,dispose(){l(),t.remove(),n.remove(),r.remove()}}}var Z=`data-mx-hover-grip`,He=`[data-mx-node-chrome], [${Z}]`,Ue=K,We=[`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button > span { color: ${Ue.handleColor}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button[data-mx-dot] > span { background: ${Ue.handleDot}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button:hover > span { color: ${Ue.handleActive}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button[data-mx-dot]:hover > span { background: ${Ue.handleActive}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button:focus-visible { outline: 2px solid ${Ue.handleActive}; outline-offset: -2px; }`].join(`
|
|
1
|
+
import{f as e}from"./DocumentChrome-Bw4_z5yQ.js";import{C as t,F as n,I as r,L as i,N as a,O as o,P as s,R as c,S as l,T as u,c as d,d as f,f as p,g as m,k as h,l as g,u as _,v,w as y,y as b}from"./http-DEdzW08u.js";import{D as x,E as S,T as C,f as w,i as T,n as E,o as D,p as O,s as k,u as A}from"./grid-layout-pVrfI_vF.js";import{r as j,t as M}from"./annotation-range-DqD0nTBm.js";import{a as N,c as P,i as F,o as I,s as L,t as R}from"./flow-view-Bp05LtJW.js";import{t as z}from"./runtime-id-CM5my_RX.js";import{t as B}from"./node-names-DHdYya8V.js";var V=1,H=3,U=e=>`outline: ${V}px solid ${e}; outline-offset: ${H}px;`,W=e=>e.replaceAll(`;`,` !important;`),G=e=>`rgba(100, 116, 139, ${e})`,K={selectedCss:`${U(`rgba(245, 158, 11, 0.85)`)} border-radius: 3px;`,editSelectedCss:W(U(G(.55))),handleColor:G(.6),handleDot:G(.45),handleActive:G(.95),spotlightCss:W(`outline: 2px dashed rgba(245, 158, 11, 0.9); outline-offset: ${H}px; border-radius: 3px; background: rgba(245, 158, 11, 0.06);`),handleOutset:3.5},q=new Set([`span`,`strong`,`b`,`em`,`i`,`a`,`code`,`br`,`small`,`sup`,`sub`,`s`,`del`,`u`]),ee=`http://www.w3.org/2000/svg`,J=new Set([`thead`,`tbody`,`tfoot`,`tr`,`td`,`th`,`caption`,`colgroup`,`col`]);function te(t){let n=t.localName,r=!!t.querySelector(`[${e}]`);return t.closest(`.ProseMirror`)?r?`container`:n===`hr`||n===`img`?`block`:`text`:t.closest(`[contenteditable="true"]`)?`text`:r?`container`:`block`}function ne(e,t){if(e?.type!==`element`||t?.type!==`element`||!e.isComponent||!t.isComponent||e.tag===`GridItem`||e.tag===t.tag)return!1;let n=e=>/^[A-Z][a-z]+/.exec(e)?.[0];return!!n(e.tag)&&n(e.tag)===n(t.tag)&&e.children.some(e=>e.type===`element`)}var Y=e=>e.split(`.`).slice(0,-1).join(`.`);function re(t,n){for(let r=t;r;r=r.parentElement?.closest(`[data-mx-ast]`)??null){let t=r.getAttribute(e),i=t?x(n,t):null;if(i?.type!==`element`)return null;if(!(q.has(i.tag)||J.has(i.tag)||r.namespaceURI===ee&&i.tag!==`svg`)&&!ne(i,x(n,Y(t)))){if(i.tag===`GridItem`){let e=x(n,Y(t)),r=e?.type===`element`?e.attributes.find(e=>e.name===`mode`)?.value:void 0;if(!(r?.static&&r.json===`flow`))return null}return r}}return null}function ie(e){if(e.tag===`GridItem`)return!0;let t=e.attributes.find(e=>e.name===`className`||e.name===`class`);return!t||t.value.static}function ae(e,t){if(!t)return null;let n=x(e,t);return!n||n.type!==`element`?null:n.isComponent?`embed`:S(n)?`text`:`element`}function oe(e,t,n){return!!t&&t.type===`element`&&!ne(t,x(n,e.split(`.`).slice(0,-1).join(`.`)))&&!S(t)&&e.includes(`.`)}function se(t,n){let r=[];for(let i=t.parentElement;i;i=i.parentElement){let t=i.getAttribute(e);if(!t)continue;let a=x(n,t);oe(t,a,n)&&r.push({path:t,tag:a.tag,hint:C(i.getAttribute(`class`)??``)})}return r.reverse()}function ce(t,n){let r=t.getAttribute(e);return r&&ae(n,r)||null}function le(t,n){let r=t.getAttribute(e);if(!r)return null;let i=ae(n,r);if(!i)return null;let a=x(n,r),o=a.attributes.find(e=>e.name.toLowerCase()===`id`),s=o?.value.static&&typeof o.value.json==`string`?o.value.json:void 0,c=t.getBoundingClientRect();return{kind:i,...t.closest(`.ProseMirror`)?{editor:`prose`}:{},customHeight:a.attributes.some(e=>e.name===`minHeight`&&e.value.static&&typeof e.value.json==`number`)||/\bmin-h-\[\d+px\]/.test(t.getAttribute(`class`)??``),path:r,...s?{nodeId:s}:{},tag:a.tag,rect:{x:c.x,y:c.y,width:c.width,height:c.height},className:t.getAttribute(`class`)??``,style:t.getAttribute(`style`)??``,ancestors:se(t,n)}}var ue=new Set([`p`,`h1`,`h2`,`h3`,`h4`,`h5`,`h6`,`li`,`blockquote`,`td`,`th`,`figcaption`,`dd`,`dt`,`pre`]);function de(e){let t=e.tagName.toLowerCase();if(ue.has(t))return!0;let n=e.parentElement?.tagName.toLowerCase()??``;return(e.hasAttribute(`data-mx-ast`)||e.hasAttribute(`data-mx-comment-target`))&&!ue.has(n)}function fe(e){let t=e?.nodeType===Node.ELEMENT_NODE?e:e?.parentElement??null;for(;t;t=t.parentElement)if(de(t)&&(t.hasAttribute(`data-mx-ast`)||t.hasAttribute(`data-mx-comment-target`)))return t;return null}function pe(e){let t=e.commonAncestorContainer;if(t.nodeType===Node.TEXT_NODE)return[{node:t,start:e.startOffset,end:e.endOffset}];let n=t.ownerDocument;if(!n)return[];let r=n.createTreeWalker(t,NodeFilter.SHOW_TEXT),i=[];for(let t=r.nextNode();t;t=r.nextNode()){let n=t;if(e.comparePoint(n,n.length)<0||e.comparePoint(n,0)>0)continue;let r=n===e.startContainer?e.startOffset:0,a=n===e.endContainer?e.endOffset:n.length;a>r&&i.push({node:n,start:r,end:a})}return i}function me(e){let t=e.ownerDocument,n=[],r=``;if(!t)return{text:r,pos:n};let i=t.createTreeWalker(e,NodeFilter.SHOW_TEXT),a=null,o=null;for(let e=i.nextNode();e;e=i.nextNode()){let t=e,i=t.data;for(let e=0;e<i.length;e++){let s=i[e];if(/\s/.test(s)){r.length>0&&!a&&(a={node:t,offset:e});continue}a&&=(r+=` `,n.push(a),null),r+=s,n.push({node:t,offset:e}),o={node:t,offset:e+1}}}return o&&n.push(o),{text:r,pos:n}}function he(e,t,n){return e.node===t?e.offset>=n:(t.compareDocumentPosition(e.node)&Node.DOCUMENT_POSITION_FOLLOWING)!==0}function ge(e,t,n){for(let r=0;r<e.pos.length;r++)if(he(e.pos[r],t,n))return Math.min(r,e.text.length);return e.text.length}var _e=e=>Array.from(e.children);function ve(e,t){let n=(e,t)=>{let n=[];for(let r=t;r&&r!==e;r=r.parentElement){let e=r.parentElement;if(!e)return null;n.unshift(_e(e).indexOf(r))}return n};if(t===e)return``;if(e.contains(t)){let r=n(e,t);return r?j({sibling:0,steps:r}):null}let r=e.parentElement;if(!r)return null;let i=t;for(;i&&i.parentElement!==r;)i=i.parentElement;if(!i)return null;let a=_e(r),o=a.indexOf(i)-a.indexOf(e);if(o<=0)return null;let s=n(i,t);return s?j({sibling:o,steps:s}):null}function ye(e,t){let n=[],r=``,i=null,a=pe(e);for(let e=0;e<a.length;){let o=a[e].node.parentElement,s=e;for(;s<a.length&&a[s].node.parentElement===o;)s++;let c=a.slice(e,s);if(e=s,!o)continue;let l=ve(t,o);if(l===null)continue;let u=me(o),d=ge(u,c[0].node,c[0].start),f=ge(u,c[c.length-1].node,c[c.length-1].end),p=u.text.slice(d,f);if(!p.trim())continue;n.push({rel:l,start:d,end:f,text:p});let m=fe(o)??o;i&&m!==i&&(r+=` `),r+=p,i=m}return{quote:M(r),range:{v:1,parts:n}}}function be(e,t){let n=e.getSelection();if(!n||n.isCollapsed||n.rangeCount===0)return null;let r=n.getRangeAt(0);if(!r.toString().trim()||t!==r.startContainer&&!t.contains(r.startContainer))return null;let i=ye(r,t);return i.range.parts.length>0?i:null}var xe={ArrowUp:`up`,ArrowDown:`down`,ArrowLeft:`left`,ArrowRight:`right`},Se=`.mx-rail, .mx-present, [data-mx-node-chrome]`,Ce=`[role="listbox"], [role="menu"], [role="combobox"], [role="grid"], [role="tree"]`,X=e=>e===`down`||e===`right`,we=e=>e===`up`||e===`down`;function Te(e){return e.defaultPrevented||e.isComposing||e.keyCode===229||e.shiftKey||e.ctrlKey||e.metaKey||e.altKey?null:xe[e.key]??null}function Ee(e,t,n){let r=e.indexOf(t);return r<0?null:e[r+(X(n)?1:-1)]??null}function De(e,t){let n=t=>e.contains(t)&&!t.closest(Se),r=[];for(let e of t)n(e.dom)&&r.push({el:e.dom,view:e});for(let t of e.querySelectorAll(`[data-mx-ast][contenteditable="true"]`)){if(!n(t)||t.closest(`.ProseMirror`))continue;let i=t.parentElement?.closest(`[contenteditable="true"]`);i&&e.contains(i)||r.push({el:t,view:null})}return r.sort((e,t)=>e.el===t.el?0:e.el.compareDocumentPosition(t.el)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1)}function Oe(e,{regions:t,selection:n,geometry:r}){let i=Te(e);if(!i||!n||n.rangeCount===0||!n.isCollapsed)return!1;let a=e.target;if(!a?.closest||a.closest(Ce))return!1;let o=t.find(e=>e.el.contains(n.anchorNode));if(!o||!o.el.contains(a)||!r.atEdge(o,i))return!1;let s=Ee(t.filter(e=>e===o||r.visible(e)),o,i);if(!s)return!1;let c=we(i)?r.caretX(o):null;return e.preventDefault(),e.stopPropagation(),r.enter(s,i,c),!0}var ke=(e,t,n)=>Math.max(t,Math.min(n,e)),Ae=e=>L.findFrom(e.resolve(0),1,!0),je=e=>L.findFrom(e.resolve(e.content.size),-1,!0);function Me(e,t){let{selection:n,doc:r}=e.state;if(!n.empty||!(n instanceof P))return!1;let i=X(t)?je(r):Ae(r);return i?we(t)?n.$head.start()===i.$head.start()&&e.endOfTextblock(t):n.head===i.head:!1}function Ne(e,t,n){let{doc:r}=e.state,i=X(t)?Ae(r):je(r);if(!i)return;let a=i.head;if(n!==null&&we(t))try{let t=e.domAtPos(a).node;(t.nodeType===1?t:t.parentElement)?.scrollIntoView?.({block:`nearest`});let i=e.coordsAtPos(a),o=e.dom.getBoundingClientRect(),s=e.posAtCoords({left:ke(n,o.left+1,o.right-1),top:(i.top+i.bottom)/2});s&&r.resolve(s.pos).parent.isTextblock&&(a=s.pos)}catch{}e.dispatch(e.state.tr.setSelection(P.create(r,a)).scrollIntoView()),e.focus()}var Pe=e=>typeof e.getClientRects==`function`?[...e.getClientRects()].filter(e=>e.width>0||e.height>0):[];function Fe(e){if(!e.rangeCount)return null;let t=e.getRangeAt(0),[n]=Pe(t);if(n)return n;let r=t.startContainer,i=(r.nodeType===1?r:r.parentElement)?.getBoundingClientRect?.();return i&&(i.width>0||i.height>0)?i:null}function Ie(e,t,n){let r=e.getSelection();if(!r?.rangeCount)return!1;let i=r.getRangeAt(0),a=e.document.createRange();if(a.selectNodeContents(t),X(n)?a.setStart(i.endContainer,i.endOffset):a.setEnd(i.startContainer,i.startOffset),!a.toString().trim())return!0;if(!we(n))return!1;let o=Fe(r);return o?!Pe(a).some(e=>{let t=e.top+e.height/2;return n===`down`?t>o.bottom:t<o.top}):!1}function Le(e,t,n){let r=e.caretPositionFromPoint?.(t,n);if(r){let t=e.createRange();return t.setStart(r.offsetNode,r.offset),t}return e.caretRangeFromPoint?.(t,n)??null}function Re(e,t,n,r){let i=e.document;t.scrollIntoView?.({block:`nearest`}),t.focus({preventScroll:!0});let a=null;if(r!==null&&we(n)){let e=i.createRange();e.selectNodeContents(t);let o=Pe(e);if(o.length){let e=X(n)?o.reduce((e,t)=>t.top<e.top?t:e):o.reduce((e,t)=>t.bottom>e.bottom?t:e),s=t.getBoundingClientRect(),c=Le(i,ke(r,s.left+1,s.right-1),e.top+e.height/2);c&&t.contains(c.startContainer)&&(a=c)}}if(!a){let e=i.createTreeWalker(t,NodeFilter.SHOW_TEXT),r=null;for(let t=e.nextNode();t&&!(t.data.trim()&&(r=t,X(n)));t=e.nextNode());a=i.createRange(),a.selectNodeContents(r??t),a.collapse(X(n))}a.collapse(!0);let o=e.getSelection();o?.removeAllRanges(),o?.addRange(a)}function ze(e){return{visible:({el:e})=>e.isConnected&&(e.checkVisibility?.()??!0),atEdge:(t,n)=>t.view?Me(t.view,n):Ie(e,t.el,n),caretX(t){try{if(t.view)return t.view.coordsAtPos(t.view.state.selection.head).left;let n=e.getSelection();return n?Fe(n)?.left??null:null}catch{return null}},enter:(t,n,r)=>t.view?Ne(t.view,n,r):Re(e,t.el,n,r)}}var Be=`.mx-rail, .mx-present`;function Ve(e){let t=e.createElement(`div`);t.setAttribute(`data-mx-drag-preview`,``),t.setAttribute(`aria-hidden`,`true`),Object.assign(t.style,{position:`fixed`,zIndex:`48`,pointerEvents:`none`,display:`none`,padding:`2px 8px`,borderRadius:`6px`,font:`500 12px/18px system-ui, sans-serif`,whiteSpace:`nowrap`,color:`#fff`,background:`rgba(51, 65, 85, 0.92)`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.18)`});let n=e.createElement(`div`);n.setAttribute(`data-mx-drop-marker`,``),Object.assign(n.style,{position:`fixed`,zIndex:`47`,pointerEvents:`none`,display:`none`,height:`3px`,borderRadius:`3px`,background:`#16a34a`,boxShadow:`0 0 0 2px rgba(22,163,74,.12)`});let r=e.createElement(`style`);e.head.append(r),e.body.append(t,n);let i=null,a=``,o={label:`Block`,parent:`container`},s=e=>e.split(`.`).slice(0,-1).join(`.`),c=e=>e.parentElement?.closest(`[data-mx-ast]`),l=()=>{i=null,t.style.display=n.style.display=`none`,r.textContent=``},u=()=>{if(!i)return[];let t=c(i),n=a.split(`.`).length;return[...(t??e).querySelectorAll(`[data-mx-ast]`)].filter(e=>{let t=e.getAttribute(`data-mx-ast`);return t.split(`.`).length===n&&s(t)===s(a)&&c(e)===c(i)&&!e.closest(Be)})},d=(e,t,n)=>{let r=null,i=1/0;for(let a of n){let n=a.getBoundingClientRect(),o=Math.max(n.left-e,0,e-n.right),s=Math.max(n.top-t,0,t-n.bottom),c=Math.hypot(o,s);c<i&&([r,i]=[a,c])}return r},f=(i,a,s)=>{t.textContent=s===`invalid`?`Can only move within this ${o.parent.toLowerCase()}`:`⠿ ${o.label}`,t.setAttribute(`data-mx-drop-state`,s),t.style.background=s===`invalid`?`rgba(220, 38, 38, 0.92)`:`rgba(51, 65, 85, 0.92)`,r.textContent=`* { cursor: ${s===`invalid`?`not-allowed`:`grabbing`} !important; }`,t.style.display=`block`;let{width:c,height:l}=t.getBoundingClientRect(),u=(e,t,n)=>{let r=e+14,i=e-14-t,a=r+t<=n-8||i<8?r:i;return Math.max(8,Math.min(a,n-t-8))};t.style.left=`${u(i,c,e.defaultView?.innerWidth??1e3)}px`,t.style.top=`${u(a,l,e.defaultView?.innerHeight??800)}px`,s!==`valid`&&(n.style.display=`none`)};return{start(e,t,n){i=e,a=t,n&&(o=n)},update(t,r,o){if(!i?.isConnected){l();return}let s=u(),c=o?s.find(e=>e.getAttribute(`data-mx-ast`)===o)??null:e.elementFromPoint(t,r)?.closest(`[data-mx-ast]`)??null;if(!o){for(;c&&!s.includes(c);)c=c.parentElement?.closest(`[data-mx-ast]`)??null;c??=d(t,r,s)}if(s.length<2){f(t,r,`invalid`);return}if(!c||c===i){f(t,r,`none`);return}let p=c.getAttribute(`data-mx-ast`),m=Number(p.split(`.`).at(-1))>Number(a.split(`.`).at(-1));f(t,r,`valid`),n.style.display=`block`;let h=c.getBoundingClientRect(),g=i.getBoundingClientRect(),_=Math.min(h.bottom,g.bottom)>Math.max(h.top,g.top)&&(h.left>=g.right||h.right<=g.left),v=m?h.left>=g.right?h.right:h.left:h.left<g.left?h.left:h.right;return Object.assign(n.style,_?{left:`${v}px`,top:`${h.top}px`,width:`3px`,height:`${h.height}px`}:{left:`${h.left}px`,top:`${m?h.bottom:h.top}px`,width:`${h.width}px`,height:`3px`}),p},clear:l,dispose(){l(),t.remove(),n.remove(),r.remove()}}}var Z=`data-mx-hover-grip`,He=`[data-mx-node-chrome], [${Z}]`,Ue=K,We=[`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button > span { color: ${Ue.handleColor}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button[data-mx-dot] > span { background: ${Ue.handleDot}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button:hover > span { color: ${Ue.handleActive}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button[data-mx-dot]:hover > span { background: ${Ue.handleActive}; }`,`:is([data-mx-node-chrome], [${Z}])[data-mx-chrome-root] > button:focus-visible { outline: 2px solid ${Ue.handleActive}; outline-offset: -2px; }`].join(`
|
|
2
2
|
`);function Ge(e,t,n){let r=e.createElement(`div`);r.setAttribute(`data-mx-node-chrome`,``),r.setAttribute(`data-mx-chrome-root`,``),Object.assign(r.style,{position:`fixed`,zIndex:`45`,pointerEvents:`none`,display:`none`});let i=e.defaultView?.matchMedia?.(`(pointer: coarse)`).matches;e.body.append(r);let a=null,o=null,s,c=null,l=Ve(e),u=e.createElement(`style`),d=z();e.head.append(u);let f=e.createElement(`style`);f.textContent=We,e.head.append(f);let p=null,m=null,h=0,g=0,_=()=>{e.defaultView?.cancelAnimationFrame(g),g=0,p?.removeAttribute(`data-mx-resize-preview`),m?.removeAttribute(`data-mx-resize-peer`),p=m=null,u.textContent=``},v=()=>Number.parseFloat(a?.parentElement?e.defaultView.getComputedStyle(a.parentElement).columnGap:``)||0,y=()=>s?(s.width+v())/s.cols:1,b=e=>s?Math.max(1,Math.min(s.cols,Math.round((e+v())/y()))):1,x=new Map,S=(t,n,a,o)=>{let s=e.createElement(`button`);s.type=`button`;let c=e.createElement(`span`);c.textContent=n,c.setAttribute(`aria-hidden`,`true`);let l=!!o&&o!==`move`;return Object.assign(c.style,{display:`grid`,placeItems:`center`,width:l?`7px`:`18px`,height:l?`7px`:`18px`,borderRadius:`50%`,font:o===`move`?`12px system-ui`:`16px/1 system-ui`,pointerEvents:`none`}),l&&s.setAttribute(`data-mx-dot`,``),s.append(c),s.setAttribute(`aria-label`,t),Object.assign(s.style,{position:`absolute`,pointerEvents:`auto`,touchAction:`none`,width:i?`44px`:`28px`,height:i?`44px`:`28px`,padding:`0`,border:`0`,borderRadius:`50%`,background:`transparent`,display:`grid`,placeItems:`center`,font:`16px system-ui`,cursor:o===`move`?`grab`:o===`width`||o===`divider`?`ew-resize`:o===`height`?`ns-resize`:o===`resize`?`nwse-resize`:`pointer`,transform:`translate(-50%, -50%)`,...a}),s.addEventListener(`pointerdown`,e=>{e.preventDefault(),o&&B(e,o)}),o&&x.set(s,o),r.append(s),s},C=`${-K.handleOutset}px`,w=`calc(100% + ${K.handleOutset}px)`,T=S(`Move selected block`,`⠿`,{left:C,top:C},`move`),E=S(`Delete selected block`,``,{left:w,top:C}),D=e.createElementNS(`http://www.w3.org/2000/svg`,`svg`);for(let[e,t]of Object.entries({viewBox:`0 0 24 24`,width:`12`,height:`12`,fill:`none`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"aria-hidden":`true`,focusable:`false`}))D.setAttribute(e,t);for(let t of[`M3 6h18`,`M19 6v14a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V6`,`M9 6V3h6v3`,`M10 10v7`,`M14 10v7`]){let n=e.createElementNS(`http://www.w3.org/2000/svg`,`path`);n.setAttribute(`d`,t),D.append(n)}E.firstElementChild.append(D),S(`Resize selected block`,``,{left:w,top:w},`resize`),S(`Resize block width`,``,{left:w,top:`50%`},`width`),S(`Resize block height`,``,{left:`50%`,top:w},`height`);let O=S(`Resize adjacent columns`,``,{left:w,top:`50%`},`divider`),k=i?44:24,A=(e,t)=>{let n=0;for(let r=e.previousElementSibling;r;r=r.previousElementSibling){let e=r.getBoundingClientRect();if(e.bottom>t.top&&e.top<t.bottom&&e.right<=t.left){n=Math.max(n,e.right);break}}return t.left-n>=k},j=e.createElement(`div`);j.setAttribute(Z,``),j.setAttribute(`data-mx-chrome-root`,``),Object.assign(j.style,{position:`fixed`,zIndex:`45`,pointerEvents:`none`,display:`none`});let M=e.createElement(`button`);M.type=`button`,M.tabIndex=-1,M.setAttribute(`aria-label`,`Drag block`),Object.assign(M.style,{width:`${k}px`,height:`${k}px`,padding:`0`,border:`0`,borderRadius:`4px`,background:`transparent`,display:`grid`,placeItems:`center`,pointerEvents:`auto`,touchAction:`none`,cursor:`grab`});let N=e.createElement(`span`);N.textContent=`⠿`,N.setAttribute(`aria-hidden`,`true`),Object.assign(N.style,{font:`12px system-ui`,pointerEvents:`none`}),M.append(N),j.append(M),e.body.append(j);let P=null,F={label:`Block`,parent:`container`},I=()=>{let e=P;if(!e?.isConnected||a||c){j.style.display=`none`;return}let t=e.getBoundingClientRect();Object.assign(j.style,{display:`block`,left:`${A(e,t)?t.left-k:t.left}px`,top:`${t.top}px`})};M.addEventListener(`pointerdown`,e=>{e.preventDefault();let t=P;!t||!n||(n(t),a===t&&o&&T.style.display!==`none`&&B(e,`move`))}),E.addEventListener(`click`,()=>{if(o){let e=o;W(),t({kind:`delete`,paths:[e]})}});let L=()=>{if(I(),!a?.isConnected){r.style.display=`none`;return}let e=a.getBoundingClientRect(),t=c&&c.kind!==`move`?V(c):e;Object.assign(r.style,{left:`${e.left}px`,top:`${e.top}px`,width:`${s?e.width:t.width}px`,height:`${Math.max(t.height,e.height)}px`});let n=i?44:28,o=s?e.width:t.width,l=Math.max(t.height,e.height);for(let e of[...x.keys(),E])e!==T&&(e.style.width=`${Math.min(n,o/2+K.handleOutset)}px`,e.style.height=`${Math.min(n,l/2+K.handleOutset)}px`);Object.assign(T.style,{width:`${k}px`,height:`${k}px`,left:`${A(a,e)?-k/2:k/2}px`,top:`${k/2}px`}),c?.kind===`move`&&G()};function R(e,t,n=0,r=0){if(!a||!o)return;_();let i=a.getBoundingClientRect();c={kind:e,pointer:t,x:n,y:r,width:i.width,height:i.height,dx:0,dy:0,steps:0,pairTotal:e===`divider`&&a.nextElementSibling?b(i.width)+b(a.nextElementSibling.getBoundingClientRect().width):void 0},e===`move`&&(l.start(a,o,F),H())}function B(e,t){e.stopPropagation(),R(t,e.pointerId,e.clientX,e.clientY),e.currentTarget.setPointerCapture?.(e.pointerId)}let V=e=>({width:Math.min(a?.parentElement?.getBoundingClientRect().width||4e3,Math.max(40,e.width+(e.kind===`height`?0:e.dx))),height:Math.max(20,e.height+([`width`,`divider`].includes(e.kind)?0:e.dy))}),H=()=>{if(!c||!a)return;if(c.kind===`move`){G();return}let e=V(c);p=a,a.setAttribute(`data-mx-resize-preview`,d);let t=`[data-mx-resize-preview="${d}"][data-mx-resize-preview]`,n=[];if(c.kind!==`height`){if(s){let r=b(e.width);if(c.kind===`divider`&&a.nextElementSibling instanceof HTMLElement){m=a.nextElementSibling,m.setAttribute(`data-mx-resize-peer`,d);let e=c.pairTotal;r=Math.min(r,e-1),n.push(`[data-mx-resize-peer="${d}"][data-mx-resize-peer] { grid-column: span ${e-r} !important; }`)}n.push(`${t} { grid-column: span ${r} !important; }`)}else n.push(`${t} { width: ${e.width}px !important; max-width: 100% !important; }`)}[`width`,`divider`].includes(c.kind)||n.push(`${t} { min-height: ${e.height}px !important; height: auto !important; }`),u.textContent=n.join(`
|
|
3
3
|
`),L(),r.style.outline=`1px solid rgba(100,116,139,.3)`},U=()=>{let t=Date.now(),n=()=>{if(!p?.isConnected||!u.sheet){_(),L();return}let r=p.getBoundingClientRect();u.sheet.disabled=!0;let i=p.getBoundingClientRect();u.sheet.disabled=!1,Math.abs(r.width-i.width)<1&&Math.abs(r.height-i.height)<1||Date.now()-t>1500?(_(),L()):g=e.defaultView.requestAnimationFrame(n)};g=e.defaultView.requestAnimationFrame(n)},W=()=>c?(c=null,e.defaultView?.cancelAnimationFrame(h),_(),l.clear(),r.style.outline=``,L(),!0):!1,G=()=>{if(!c||!a||!o)return;let e=o.split(`.`),t=Number(e.pop()),n=a.getBoundingClientRect();return c.pointer===null?l.update(n.left,n.top,[...e,String(t+c.steps)].join(`.`)):l.update(c.x+c.dx,c.y+c.dy)},q=()=>{let n=c;if(!n||!o)return;let i=o,u=V(n);if(!a?.isConnected||Math.abs(n.dx)+Math.abs(n.dy)<3&&!n.steps){W();return}H();let d=n.kind===`move`?G():void 0;if(c=null,e.defaultView?.cancelAnimationFrame(h),r.style.outline=``,U(),n.kind===`move`){l.clear(),d&&t({kind:`move`,path:i,target:d});return}if(n.kind===`divider`&&s){t({kind:`divider`,path:i,width:b(u.width)});return}t({kind:`resize`,path:i,...n.kind===`width`||n.kind===`height`?{axis:n.kind}:{},...s?{width:b(u.width),height:s.positioned?Math.round(u.height/s.rowHeight):u.height,grid:!0}:u})},ee=t=>{!c||c.pointer!==t.pointerId||(c.dx=t.clientX-c.x,c.dy=t.clientY-c.y,e.defaultView?.cancelAnimationFrame(h),h=e.defaultView.requestAnimationFrame(H))},J=e=>{!c||c.pointer!==e.pointerId||(c.dx=e.clientX-c.x,c.dy=e.clientY-c.y,q())},te=e=>{if(e.key===`Escape`&&W()){e.preventDefault(),e.stopImmediatePropagation();return}let t=x.get(e.target);if(!t||!a||!o)return;if(e.key===`Enter`&&c){e.preventDefault(),q();return}if(![`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`].includes(e.key)||(e.preventDefault(),e.stopPropagation(),c||R(t,null),!c))return;let n=e.key===`ArrowLeft`||e.key===`ArrowRight`,r=e.key===`ArrowLeft`||e.key===`ArrowUp`?-1:1;t===`move`?c.steps+=r:n?c.dx+=r*(s?y():e.shiftKey?40:10):c.dy+=r*(s?.positioned?s.rowHeight:e.shiftKey?40:10),H()};return e.addEventListener(`pointermove`,ee,!0),e.addEventListener(`pointerup`,J,!0),e.addEventListener(`pointercancel`,W,!0),e.addEventListener(`keydown`,te,!0),e.defaultView?.addEventListener(`scroll`,L,!0),e.defaultView?.addEventListener(`resize`,L),{select(e,t,n,i){if(c)return;let l=i?.resizable??!0;F={label:i?.label??`Block`,parent:i?.parent??`container`},g&&e&&t===o&&p!==e&&(p?.removeAttribute(`data-mx-resize-preview`),p=e,e.setAttribute(`data-mx-resize-preview`,d)),a=e,o=t,s=n,r.style.display=e?`block`:`none`;let u=e?.nextElementSibling,f=!!n&&!n.positioned&&!!u&&Math.abs(u.getBoundingClientRect().top-e.getBoundingClientRect().top)<3;for(let[e,t]of x)e.style.display=n?.positioned||t===`divider`&&!f||t===`width`&&f||!l&&t!==`move`?`none`:`grid`;O.style.display=f&&l?`grid`:`none`;for(let t of r.querySelectorAll(`button`))t.setAttribute(`aria-description`,`${e?.tagName.toLowerCase()??`block`}: ${e?.textContent?.trim().slice(0,80)??``}. Arrow keys adjust; Enter commits; Escape cancels.`);L()},hover(e){P=e,I()},cancel:W,dispose(){W(),_(),l.dispose(),u.remove(),f.remove(),r.remove(),j.remove(),e.removeEventListener(`pointermove`,ee,!0),e.removeEventListener(`pointerup`,J,!0),e.removeEventListener(`pointercancel`,W,!0),e.removeEventListener(`keydown`,te,!0),e.defaultView?.removeEventListener(`scroll`,L,!0),e.defaultView?.removeEventListener(`resize`,L)}}}var Ke=`p[data-mx-ast],h1[data-mx-ast],h2[data-mx-ast],h3[data-mx-ast],h4[data-mx-ast],h5[data-mx-ast],h6[data-mx-ast],li[data-mx-ast],pre[data-mx-ast]`;function qe(e,t,n){let r=[],i=null,a=null,o=new Map,s=0,c=(t,n)=>{let r=e.caretPositionFromPoint?.(t,n);if(r)return{node:r.offsetNode,offset:r.offset};let i=e.caretRangeFromPoint?.(t,n);return i?{node:i.startContainer,offset:i.startOffset}:null},l=e.createElement(`div`);l.setAttribute(`role`,`status`),l.setAttribute(`data-mx-block-status`,``),Object.assign(l.style,{position:`fixed`,bottom:`20px`,left:`50%`,transform:`translateX(-50%)`,maxWidth:`calc(100vw - 48px)`,font:`12px/1.5 system-ui`,boxShadow:`0 2px 12px rgba(15,23,42,.06)`,zIndex:`46`,background:`rgba(255,255,255,.96)`,color:`#64748b`,padding:`7px 12px`,border:`1px solid rgba(100,116,139,.15)`,borderRadius:`20px`,display:`none`}),e.body.append(l);let u=()=>r.map(e=>e.getAttribute(`data-mx-ast`)).filter(Boolean),d=()=>{e.defaultView?.cancelAnimationFrame(s),r.forEach(e=>e.removeAttribute(`data-mx-block-selected`)),r=[];for(let[e,t]of o)t===null?e.removeAttribute(`contenteditable`):e.setAttribute(`contenteditable`,t);o.clear(),l.style.display=`none`},f=e=>(e?.nodeType===1?e:e?.parentElement)?.closest(Ke)??null,p=(e,n)=>{if(!e||!n||e.closest(`.ProseMirror`)===n.closest(`.ProseMirror`))return;let i=[...t.querySelectorAll(Ke)].filter(e=>!e.parentElement?.closest(Ke)),a=i.indexOf(e),s=i.indexOf(n);if(a<0||s<0)return;let c=i.slice(Math.min(a,s),Math.max(a,s)+1);if(!(c.length===r.length&&c.every((e,t)=>e===r[t]))){r.forEach(e=>e.removeAttribute(`data-mx-block-selected`)),r=c;for(let e of t.querySelectorAll(`.ProseMirror`))o.has(e)||o.set(e,e.getAttribute(`contenteditable`)),e.setAttribute(`contenteditable`,`false`);r.forEach(e=>e.setAttribute(`data-mx-block-selected`,``)),l.textContent=`${r.length} blocks · Delete to remove · Esc to cancel. Text replacement is unavailable across regions.`,l.style.display=`block`}},m=()=>{let t=e.defaultView?.getSelection();!t||t.isCollapsed||p(f(t.anchorNode),f(t.focusNode))},h=e=>{!t.contains(e.target)||e.target?.closest?.(He)||(d(),i=f(e.target),a=i?c(e.clientX,e.clientY):null)},g=t=>{if(!i||!a)return;let n=c(t.clientX,t.clientY),o=f(n?.node??null);if(!(!n||!o)){if(i.closest(`.ProseMirror`)===o.closest(`.ProseMirror`)){r.length&&(d(),e.defaultView?.getSelection()?.setBaseAndExtent(a.node,a.offset,n.node,n.offset));return}p(i,o),e.defaultView?.getSelection()?.setBaseAndExtent(a.node,a.offset,n.node,n.offset),t.preventDefault()}},_=t=>{g(t),i&&p(i,f(e.elementFromPoint?.(t.clientX,t.clientY)??t.target));let n=a,o=c(t.clientX,t.clientY);r.length&&n&&o&&(s=e.defaultView.requestAnimationFrame(()=>{r.length&&n.node.isConnected&&o.node.isConnected&&e.defaultView?.getSelection()?.setBaseAndExtent(n.node,n.offset,o.node,o.offset)})),i=null,a=null},v=i=>{if(!(!t.contains(i.target)&&!(r.length&&t.contains(e.defaultView?.getSelection()?.anchorNode??null))||i.target?.closest?.(`input,textarea,[role="dialog"]`))){if(i.shiftKey&&[`ArrowRight`,`ArrowDown`,`ArrowLeft`,`ArrowUp`].includes(i.key)){let n=e.defaultView?.getSelection(),a=f(n?.focusNode??null),o=a?.closest(`.ProseMirror`);if(n?.focusNode&&o&&t.contains(o)){let s=e.createRange();s.selectNodeContents(o),s.setEnd(n.focusNode,n.focusOffset);let c=i.key===`ArrowLeft`||i.key===`ArrowUp`,l=c?s.toString().length===0:s.toString().length===(o.textContent??``).length,u=[...t.querySelectorAll(Ke)].filter(e=>!e.parentElement?.closest(Ke)),d=r.length?c?r[0]:r.at(-1):a,m=d?u[u.indexOf(d)+(c?-1:1)]:null;if(m&&(l||r.length)&&(p(f(n.anchorNode),m),r.length)){n.anchorNode&&n.setBaseAndExtent(n.anchorNode,n.anchorOffset,m,c?0:m.childNodes.length),i.preventDefault(),i.stopImmediatePropagation();return}}}if(r.length){if(i.key===`Escape`){d(),i.preventDefault(),i.stopImmediatePropagation();return}if(i.key===`Delete`||i.key===`Backspace`){let e=u();d(),i.preventDefault(),i.stopImmediatePropagation(),n({kind:`delete`,paths:e});return}(i.key.length===1&&!i.ctrlKey&&!i.metaKey||i.key===`Enter`)&&(i.preventDefault(),i.stopImmediatePropagation())}}},y=e=>{r.length&&t.contains(e.target)&&(e.preventDefault(),e.stopImmediatePropagation())};return e.addEventListener(`selectionchange`,m),e.addEventListener(`pointerdown`,h,!0),e.addEventListener(`pointermove`,g,!0),e.addEventListener(`pointerup`,_,!0),e.addEventListener(`keydown`,v,!0),e.addEventListener(`paste`,y,!0),e.addEventListener(`beforeinput`,y,!0),{paths:u,clear:d,dispose(){d(),l.remove(),e.removeEventListener(`selectionchange`,m),e.removeEventListener(`pointerdown`,h,!0),e.removeEventListener(`pointermove`,g,!0),e.removeEventListener(`pointerup`,_,!0),e.removeEventListener(`keydown`,v,!0),e.removeEventListener(`paste`,y,!0),e.removeEventListener(`beforeinput`,y,!0)}}}var Je=`data-mx-selected`,Ye=`data-mx-embed-selected`,Q=`data-mx-edit-hover`,Xe=`data-mx-edit-spotlight`,Ze=`data-mx-edit-root`,Qe=new Set([`span`,`strong`,`b`,`em`,`i`,`a`,`code`,`br`,`small`,`sup`,`sub`,`s`,`del`,`u`]),$e=`.mx-rail, .mx-present, ${He}`;function et({win:t,root:n,nodes:r,views:i,activePath:o,commitActive:s,post:c}){let l=t.document,u=null,d=!1,f=null,p=!1,m=null,h=null,g=0,v=t=>n.querySelector(`[${e}="${CSS.escape(t)}"]`),y=qe(l,n,e=>c({type:_,command:e})),b=Ge(l,e=>{s(),c({type:_,command:e})},e=>A(e)),S=new Set,C=(e=!1)=>{let t=e?[...S,...n.querySelectorAll(`[${Je}], [${Ye}]`)]:S;for(let e of t)e.removeAttribute(Je),e.removeAttribute(Ye);S.clear()},w=()=>{C();let e=t.getSelection(),i=()=>{b.select(null,null),O()};if(!u||y.paths().length||e&&!e.isCollapsed&&n.contains(e.anchorNode))return i();let a=v(u);if(!a)return i();let o=ce(a,r());if(a.setAttribute(o===`embed`?Ye:Je,d?`block`:`text`),S.add(a),!d)return i();let s=x(r(),u),c=x(r(),u.split(`.`).slice(0,-1).join(`.`)),l=c?.type===`element`?Object.fromEntries(c.attributes.flatMap(e=>e.value.static?[[e.name,e.value.json]]:[])):{},f=s?.type===`element`&&s.tag===`GridItem`?{cols:E(l.cols),rowHeight:T(l.rowHeight),width:a.parentElement?.getBoundingClientRect().width??a.getBoundingClientRect().width,positioned:l.mode!==`flow`}:void 0,p=s?.type===`element`&&(Qe.has(s.tag)||a.namespaceURI===`http://www.w3.org/2000/svg`&&s.tag!==`svg`);b.select(p?null:a,p?null:u,f,{resizable:s?.type===`element`&&ie(s),label:s?.type===`element`?B(s.tag):`Block`,parent:D(u)}),O()},D=e=>{for(let t=e.split(`.`).slice(0,-1);t.length;t.pop()){let e=x(r(),t.join(`.`));if(e?.type!==`element`)break;if(!ne(e,x(r(),t.slice(0,-1).join(`.`))))return B(e.tag)}return`document`},O=()=>{let e=!d&&u?v(u):null,t=f??e;b.hover(t&&re(t,r()))},A=e=>{let i=re(e,r())??e,a=l.activeElement;a&&a!==n&&n.contains(a)&&a.blur(),t.getSelection()?.removeAllRanges(),n.setAttribute(Ze,``),n.hasAttribute(`tabindex`)||(n.tabIndex=-1),n.focus({preventScroll:!0}),M(le(i,r()),!0)},j=e=>{let n=le(e,r());if(!n)return null;for(let t of i.all)if(t.dom.contains(e)){n.inline=k(t.state);break}let a=be(t,e);return a&&(n.quote=a.quote,n.range=a.range),n},M=(e,t=!1)=>{u=e?.path??null,d=!!e&&t,e&&(e.mode=d?`block`:`typing`),w(),c({type:a,selection:e})},N=()=>{let e=o();if(!u&&!e)return;let t=v(e??u),n=t?j(t):null;n&&(n.mode=d&&!e?`block`:`typing`),c({type:a,selection:n})},P=t=>{let i=t;if(!i?.closest||!n.contains(i)||i.closest($e))return null;let a=i.closest(`[${e}]`);return a&&le(a,r())?a:null},F=e=>{f!==e&&(f?.removeAttribute(Q),f=e,f?.setAttribute(Q,te(f)),O())},I=e=>{for(let e of n.querySelectorAll(`[${Xe}]`))e.removeAttribute(Xe);let t=null;for(let n of e){let e=v(n);e&&(e.setAttribute(Xe,``),t??=e)}t?.scrollIntoView?.({block:`nearest`,behavior:`smooth`})},L=e=>[...i.all].find(t=>t.dom.contains(e)),R=e=>{i.last=L(e.target)??i.last},z=()=>{let r=t.getSelection()?.anchorNode,a=r?.nodeType===1?r:r?.parentElement;if(!a?.closest(`.ProseMirror`)||!n.contains(a))return;i.last=L(a)??i.last;let o=a.closest(`[${e}]`);o&&M(j(o))},V=e=>!!e?.closest?.(`[${Z}]`),H=e=>{V(e.target)||F(P(e.target))},U=e=>{V(e.relatedTarget)||F(P(e.relatedTarget))},W=i=>{let a=i.target;if(!a?.closest||!n.contains(a)||a.closest($e))return;a.closest(`.ProseMirror`)&&a.closest(`a`)&&i.preventDefault();let s=t.getSelection();if(s&&!s.isCollapsed&&n.contains(s.anchorNode)){w();return}let c=a.closest(`[${e}]`);if(!c){M(null);return}let u=te(c);if(u===`block`){le(c,r())&&A(c);return}if(u===`container`){let e=s?.anchorNode;e&&c.contains(e)&&l.activeElement?.isContentEditable||M(null);return}let d=j(c);(d?.kind!==`text`||o()!==d.path)&&M(d)},G=!1,K=()=>{G||(G=!0,t.requestAnimationFrame(()=>{G=!1,p||N()}))};return l.addEventListener(`focusin`,R),l.addEventListener(`selectionchange`,z),l.addEventListener(`click`,W,!0),l.addEventListener(`pointerover`,H,!0),l.addEventListener(`pointerout`,U,!0),t.addEventListener(`scroll`,K,{passive:!0}),t.addEventListener(`resize`,K,{passive:!0}),{selectedPath:()=>u,blockMode:()=>d,blockSelected:()=>y.paths().length>0,selectableAt:P,selectBlock:A,reportSelection:M,describeWithQuote:j,republishRect:N,select:e=>{let n=++g;if(!e.path){M(null);return}let i=e.path,a=()=>{let t=v(i);return t&&e.nodeId&&t.id!==e.nodeId?null:t&&le(t,r())?t:null},o=e=>{let t=()=>e.scrollIntoView?.({block:`center`,behavior:`smooth`});e.localName===`img`&&!e.complete&&e.addEventListener(`load`,t,{once:!0}),t()},s=a();if(s||!e.reveal){s?A(s):M(null),s&&e.reveal&&o(s);return}let c=0,l=()=>{if(p||n!==g)return;let e=a();e?(A(e),o(e)):++c<60&&t.setTimeout(l,25)};t.setTimeout(l,25)},setSpotlight:I,nodesChanged(){b.cancel(),y.clear(),m===null&&h===null&&(m=t.requestAnimationFrame(()=>{m=null,h=t.setTimeout(()=>{h=null,p||w()},0)})),u&&!ce(v(u)??l.createElement(`div`),r())&&(u=null)},dispose(){p=!0,m!==null&&t.cancelAnimationFrame(m),h!==null&&t.clearTimeout(h),b.dispose(),y.dispose(),l.removeEventListener(`focusin`,R),l.removeEventListener(`selectionchange`,z),l.removeEventListener(`click`,W,!0),l.removeEventListener(`pointerover`,H,!0),l.removeEventListener(`pointerout`,U,!0),t.removeEventListener(`scroll`,K),t.removeEventListener(`resize`,K),C(!0),F(null),I([]),u=null}}}function tt(e){if(!e)return null;for(let t of Array.from(e.items??[])){if(t.kind!==`file`)continue;let e=t.getAsFile();if(e&&e.type.startsWith(`image/`))return e}for(let t of Array.from(e.files??[]))if(t.type.startsWith(`image/`))return t;return null}var nt=`data-mx-drop-replace`,rt=`outline: 2px dashed rgba(100, 116, 139, 0.9) !important; outline-offset: 3px !important; opacity: 0.75 !important;`,it=`data-mx-drop-replace-label`,at=new Set([`span`,`strong`,`b`,`em`,`i`,`a`,`code`,`br`,`small`,`sup`,`sub`,`s`,`del`,`u`,`mark`]);function ot({win:n,root:r,nodes:i,selectedPath:a,selectableAt:o,selectImage:s,post:c}){let u=n.document,d=e=>{let t=e?x(i(),e):null;return t?.type===`element`&&!t.isComponent&&t.tag===`img`},f=e=>{let t=o(e);return t&&t.localName===`img`&&d(t.getAttribute(`data-mx-ast`))?t:null},p=null,m=null,h=e=>{if(e!==p){if(p?.removeAttribute(nt),m?.remove(),m=null,p=e,!e)return;e.setAttribute(nt,``),m=u.createElement(`div`),m.setAttribute(it,``),m.setAttribute(`aria-hidden`,`true`),m.textContent=`Drop to replace`,Object.assign(m.style,{position:`fixed`,zIndex:`46`,pointerEvents:`none`,transform:`translate(-50%, -50%)`,padding:`4px 10px`,borderRadius:`999px`,background:`rgba(15, 23, 42, 0.78)`,color:`#fff`,font:`500 12px/1.4 system-ui, sans-serif`,whiteSpace:`nowrap`}),u.body.append(m)}if(e&&m){let t=e.getBoundingClientRect();m.style.left=`${t.x+t.width/2}px`,m.style.top=`${t.y+t.height/2}px`}},g=e=>{let t=x(i(),e.getAttribute(`data-mx-ast`)??``);return t?.type===`element`&&at.has(t.tag)},_=(t,n)=>{let r=o(t);for(;r&&g(r);)r=o(r.parentElement);if(!r)return null;let i=[...r.querySelectorAll(`[${e}]`)].filter(e=>e.parentElement?.closest(`[data-mx-ast]`)===r&&!g(e)),a=e=>{let t=e.getBoundingClientRect();return n<t.top+t.height/2?`before`:`after`};if(i.length===0)return{path:r.getAttribute(e),side:a(r)};let s=i.find(e=>a(e)===`before`);return s?{path:s.getAttribute(e),side:`before`}:{path:i[i.length-1].getAttribute(e),side:`after`}},v=n=>{let r=f(n.target);r&&(n.preventDefault(),s(r),c({type:t,path:r.getAttribute(e)}))},y=t=>{let n=t.target===u.body||t.target===u.documentElement,i=t.type===`paste`&&n&&d(a());if(!r.contains(t.target)&&!i)return;let o=tt(`clipboardData`in t?t.clipboardData:t.dataTransfer);if(t.type===`drop`&&h(null),!o)return;t.preventDefault();let s=a(),p=t.type===`drop`?f(t.target)?.getAttribute(e):d(s)?s:null,m=!p&&t.type===`drop`?{at:_(t.target,t.clientY)}:{};c({type:l,file:o,...p?{target:p}:{},...m})},b=e=>{if(!r.contains(e.target)){h(null);return}let t=!!e.dataTransfer?.types?.includes(`Files`);t&&e.preventDefault(),h(t?f(e.target):null)},S=e=>{if(!p)return;let t=e.relatedTarget;(!t||!p.contains(t))&&h(null)},C=()=>h(null);return u.addEventListener(`paste`,y,!0),u.addEventListener(`drop`,y,!0),u.addEventListener(`dragover`,b,!0),u.addEventListener(`dragleave`,S,!0),u.addEventListener(`dragend`,C,!0),u.addEventListener(`dblclick`,v,!0),{dispose(){u.removeEventListener(`paste`,y,!0),u.removeEventListener(`drop`,y,!0),u.removeEventListener(`dragover`,b,!0),u.removeEventListener(`dragleave`,S,!0),u.removeEventListener(`dragend`,C,!0),u.removeEventListener(`dblclick`,v,!0),h(null)}}}function st({win:t,root:n,views:r,channel:a,post:o,republishRect:s}){let c=t.document,l=t=>n.querySelector(`[${e}="${CSS.escape(t)}"]`);return{applyFormat:(e,t,n)=>{let i=l(e);if(!i)return;let a=[...r.all].find(e=>e.dom.contains(i));if(a&&t!==void 0){let e=null;if(a.state.doc.descendants((t,n)=>{a.nodeDOM(n)===i&&(e=n)}),e!==null){let n=a.state.doc.nodeAt(e),r=n.attrs.source,i=(r?.attributes??[]).filter(e=>![`class`,`className`].includes(e.name));t&&i.push({name:`className`,value:{static:!0,json:t},start:0,end:0}),a.dispatch(a.state.tr.setNodeMarkup(e,void 0,{...n.attrs,source:{...r,attributes:i}}).setMeta(`mx-command`,!0)),s();return}}t!==void 0&&(t.trim()?i.setAttribute(`class`,t):i.removeAttribute(`class`)),n!==void 0&&(n.trim()?i.setAttribute(`style`,n):i.removeAttribute(`style`)),s()},applyLink:(e,n)=>{let s=r.last;if(s&&r.all.has(s)){let{from:e,to:t}=s.state.selection,r=s.state.tr,i=n?O(n):null;if(n&&!i)return;s.state.doc.nodesBetween(e,t,n=>{for(let i of n.marks)i.attrs.tag===`a`&&r.removeMark(e,t,i)}),i&&r.addMark(e,t,D.marks.inline.create({tag:`a`,source:{type:`element`,tag:`a`,isComponent:!1,attributes:[{name:`href`,value:{static:!0,json:i},start:0,end:0}],children:[],selfClosing:!1,start:0,end:0}})),s.dispatch(r.setMeta(`mx-command`,!0)),s.focus();return}let u=l(e);if(!u)return;let d=t.getSelection();if(!d||d.rangeCount===0)return;let f=d.getRangeAt(0);if(u.contains(f.commonAncestorContainer)){if(n){let e=O(n);if(!e||!(e.startsWith(`https://`)||e.startsWith(`http://`)||e.startsWith(`mailto:`)||e.startsWith(`tel:`)||e.startsWith(`/`)||e.startsWith(`#`)))return;let t=c.createElement(`a`);t.setAttribute(`href`,e),t.setAttribute(`target`,`_blank`),t.setAttribute(`rel`,`noopener noreferrer`);try{f.surroundContents(t)}catch{return}}else{let e=f.commonAncestorContainer.parentElement?.closest?.(`a`)??f.commonAncestorContainer.closest?.(`a`);if(!e)return;e.replaceWith(...Array.from(e.childNodes))}o({type:i,path:e,innerHtml:a.innerHtmlOf(u)})}}}}var $=`data-mx-parent-layout`,ct=[`.ProseMirror { outline: none; white-space: pre-wrap; overflow-wrap: break-word; }`,`[${$}="flex"], [${$}="grid"], [${$}] > .mx-prose-region, [${$}="flex"] > .mx-prose-region > .ProseMirror, [${$}="grid"] > .mx-prose-region > .ProseMirror { flex-direction: inherit; flex-wrap: inherit; justify-content: inherit; justify-items: inherit; align-items: inherit; align-content: inherit; row-gap: inherit; column-gap: inherit; grid-template-columns: inherit; grid-template-rows: inherit; grid-auto-flow: inherit; grid-auto-columns: inherit; grid-auto-rows: inherit; }`,`[${$}="flex"] > .mx-prose-region > .ProseMirror { display: flex; flex: 1 1 auto; align-self: stretch; min-width: 0; }`,`[${$}="grid"] > .mx-prose-region > .ProseMirror { display: grid; grid-column: 1 / -1; min-width: 0; }`,`[${$}="item"] > .mx-prose-region > .ProseMirror { grid-column-start: var(--mx-place-grid-column-start, auto); grid-column-end: var(--mx-place-grid-column-end, auto); grid-row-start: var(--mx-place-grid-row-start, auto); grid-row-end: var(--mx-place-grid-row-end, auto); flex-grow: var(--mx-place-flex-grow, 0); flex-shrink: var(--mx-place-flex-shrink, 1); flex-basis: var(--mx-place-flex-basis, auto); align-self: var(--mx-place-align-self, auto); justify-self: var(--mx-place-justify-self, auto); order: var(--mx-place-order, 0); min-width: 0; }`,`[data-mx-edit-region]:not([${$}]) > .mx-prose-region > .ProseMirror > table { content-visibility: auto; contain-intrinsic-block-size: auto var(--mx-region-h, 480px); }`,`[contenteditable="true"]:focus { outline: none; }`,`[${Q}="block"][${Q}] { cursor: pointer; }`,`[${Q}="container"][${Q}] { cursor: default; }`,`[${Ze}]:focus { outline: none; }`,`[${Je}="block"][${Je}], [${Ye}="block"][${Ye}] { ${K.editSelectedCss} }`,`[data-mx-block-selected][data-mx-block-selected] { ${K.editSelectedCss} }`,`[${Xe}][${Xe}] { ${K.spotlightCss} }`,`[${nt}][${nt}] { ${rt} }`].join(`
|
|
4
4
|
`),lt=`data-mx-edit-css`,ut=(e,t)=>!!e&&e.anchor.id===t.anchor.id&&e.anchor.offset===t.anchor.offset&&e.head.id===t.head.id&&e.head.offset===t.head.offset;function dt(e,t){if(e===t)return!0;if(typeof e!=`object`||typeof t!=`object`||e===null||t===null)return!1;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(!dt(e[n],t[n]))return!1;return!0}if(Array.isArray(t))return!1;let n=Object.keys(e).filter(t=>e[t]!==void 0),r=Object.keys(t).filter(e=>t[e]!==void 0);if(n.length!==r.length)return!1;for(let r of n)if(!dt(e[r],t[r]))return!1;return!0}function ft({win:t,channel:a,requestRender:l,root:_,mountCompiled:x}){let S=t.document,C=[],T=null,E=!1,D=!1,O=e=>{(t.scrollX!==e.x||t.scrollY!==e.y)&&t.scrollTo(e.x,e.y)},k={all:new Set,last:null},j=null,M=null,P,L=null,z,B,V=()=>{if(P){if(P!==z){let e=[...k.all].find(e=>!e.isDestroyed&&e.hasFocus());if(e&&ut(N(e.state),P)){P=void 0;return}}for(let e of k.all)if(I(e,P)){z&&(B=JSON.stringify(N(e.state))),P=void 0;break}}},H=e=>a.post({...e,nonce:a.nonce}),U=t=>_.querySelector(`[${e}="${CSS.escape(t)}"]`),W=et({win:t,root:_,nodes:()=>C,views:k,activePath:()=>T?.path??null,commitActive:()=>K(T),post:H}),G=e=>{e!==E&&(E=e,H({type:c,active:e}))},K=e=>{if(!e||!e.userEdited)return!1;let t=a.innerHtmlOf(e.el);return t!==e.snapshot&&(e.snapshot=t,e.userEdited=!1,G(!1),H({type:i,path:e.path,innerHtml:t}),!0)},q={onFocus(e,t){k.last=null,T={path:e,el:t,snapshot:a.innerHtmlOf(t),userEdited:!1},W.reportSelection(W.describeWithQuote(t))},onInput(e){T&&(T.userEdited=!0),G(!0)},onBlur(e){let t=T;T=null,K(t),G(!1),l()}},ee=ze(t),J=e=>{if(!_.contains(e.target)||e.key.startsWith(`Arrow`)&&!W.blockSelected()&&Oe(e,{regions:De(_,k.all),selection:t.getSelection(),geometry:ee}))return;if(e.key===`Escape`){if(e.target?.closest?.(`dialog, [role="dialog"], [role="menu"], [role="listbox"]`))return;let t=W.selectedPath(),n=t&&U(t);if(!n){H({type:m,key:`Escape`});return}if(e.preventDefault(),!W.blockMode()){W.selectBlock(n);return}let r=se(n,C).at(-1),i=r&&U(r.path);i?W.selectBlock(i):W.reportSelection(null);return}if(e.key!==`Delete`&&e.key!==`Backspace`||T)return;let n=S.activeElement;n&&n.isContentEditable||W.selectedPath()&&(e.preventDefault(),H({type:m,key:e.key}))};S.addEventListener(`keydown`,J,!0);let te=ot({win:t,root:_,nodes:()=>C,selectedPath:W.selectedPath,selectableAt:W.selectableAt,selectImage:e=>W.reportSelection(W.describeWithQuote(e)),post:H}),ne=e=>{e.defaultPrevented||!T?.el.contains(e.target)||!e.clipboardData?.getData(`text/html`)||(e.preventDefault(),H({type:`mx:edit-error`,message:`This element supports typing and plain-text paste. Use a regular paragraph for formatted paste.`}))};S.addEventListener(`paste`,ne,!0);let Y=S.createElement(`style`);Y.setAttribute(lt,``),Y.textContent=ct,S.head.appendChild(Y),H({type:v});let re=st({win:t,root:_,views:k,channel:a,post:H,republishRect:W.republishRect});return{canApplyDraft(){return!E&&!T?.userEdited},reconcileDraft(e,t,n,r,i){return!D&&!!j?.reconcile(e,t,n,r,i)},holdUnchanged(e,n){if(M?.dispose(),M=null,D||!j)return new Map;for(let e of k.all)R(e);return L={x:t.scrollX,y:t.scrollY},M=j.hold(e,n),M.stands},prepareHold(e,t,n){if(D||!j)return!0;for(let e of k.all)R(e);return j.prepareHold(e,t,n)},releaseHeld(){M?.release(),M=null,L=null},unmountCompiledDom(){L??={x:t.scrollX,y:t.scrollY};for(let e of k.all)R(e);let e=S.activeElement instanceof HTMLElement&&!!S.activeElement.closest(`[aria-label="Typography toolbar"]`),n=[...k.all].find(e=>e.hasFocus())??(e?k.last:null),r=n?N(n.state):void 0;z&&(B===void 0||B===JSON.stringify(r))?P=z:r&&!P&&(P=r),z=B=void 0,j?.dispose(),j=null,k.all.clear()},async mountCompiledDom(){if(D)return;let e=L??{x:t.scrollX,y:t.scrollY};L=null,j?.dispose();let r=M??void 0;M=null,j=x(_,C,{onFlow(e,t,n,r,i){z=B=void 0,H({type:b,path:e,expected:t,replacement:n,group:r,selection:i})},onLayout(e){H({type:u,rects:e})},onSlideTitle(e,t){H({type:n,path:e,title:t})},onOpenScript(e){H({type:o,component:e})},onError(e){H({type:`mx:edit-error`,message:e})},onBusy:G,onView(e){if(e)k.all.add(e),k.last=e,t.requestAnimationFrame(V);else for(let e of[...k.all])e.dom.isConnected||k.all.delete(e)},onHostFocus:q.onFocus,onHostInput:q.onInput,onHostBlur:q.onBlur},r),t.requestAnimationFrame(()=>t.requestAnimationFrame(()=>{D||O(e)}))},renameSlide(e,t){H({type:n,path:e,title:t})},setNodes(e){if(e!==C){if(dt(e,C)){C=e;return}C=e,W.nodesChanged()}},onParentMessage(e){let n=k.last&&k.all.has(k.last)?k.last:null;switch(e.type){case y:n&&(n.dispatch(w(n.state,e.tag).setMeta(`mx-command`,!0)),n.focus());break;case h:if(n)try{let t=F(e.kind,e.value),r=n.state.tr;n.dispatch((n.state.selection.$from.parent.attrs.tag===`pre`?r.insertText(e.value):r.replaceSelection(A(t))).setMeta(`uiEvent`,`paste`)),n.focus()}catch(e){H({type:`mx:edit-error`,message:e instanceof Error?e.message:`Paste could not be inserted.`})}else H({type:`mx:edit-error`,message:`Select a regular text paragraph before inserting Markdown.`});break;case d:re.applyFormat(e.path,e.className,e.style);break;case g:re.applyLink(e.path,e.href);break;case p:if(e.restore){P=z=e.restore,t.requestAnimationFrame(V);break}for(let e of k.all)R(e);K(T),H({type:f});break;case s:W.select(e);break;case r:W.setSpotlight(e.paths)}},dispose(){j?.dispose(),j=null,M?.dispose(),M=null,D=!0,W.dispose(),K(T),T=null,G(!1),S.removeEventListener(`keydown`,J,!0),S.removeEventListener(`paste`,ne,!0),te.dispose(),Y.remove()}}}export{ft as createFrameEditSession};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-
|
|
1
|
+
import{I as e,T as t}from"./web-Ckpee-ZJ.js";import{G as n}from"./solid-app-BNcsMwv4.js";var r=[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]],i=i=>t(n,e(i,{iconNode:r,name:`folder`})),a=[[`rect`,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`1g98yp`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`3`,rx:`1`,key:`6d4xhi`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`14`,rx:`1`,key:`nxv5o0`}],[`rect`,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`1bb6yr`}]],o=r=>t(n,e(r,{iconNode:a,name:`layout-grid`})),s=e=>e.parent_id??(e.ancestor_ids?.length?e.ancestor_ids[e.ancestor_ids.length-1]:null),c=[{key:`today`,label:`Today`},{key:`yesterday`,label:`Yesterday`},{key:`this-week`,label:`This Week`},{key:`last-month`,label:`Last Month`},{key:`older`,label:`Older`}],l=864e5,u=e=>Date.UTC(e.getFullYear(),e.getMonth(),e.getDate()),d=(e,t)=>{let n=new Date(e);if(Number.isNaN(n.getTime()))return`older`;let r=Math.max(0,Math.round((u(t)-u(n))/l));return r===0?`today`:r===1?`yesterday`:r<=7?`this-week`:r<=31?`last-month`:`older`};function f(e,t=new Date){let n=new Map(c.map(({key:e})=>[e,[]]));for(let r of e)n.get(d(r.updated_at,t)).push(r);return c.flatMap(({key:e,label:t})=>{let r=n.get(e);return r.length>0?[{key:e,label:t,rows:r}]:[]})}var p=e=>e.format===`markup`,m=e=>e.format===`folder`;function h(e){let t=[],n=[],r=[];for(let i of e)(m(i)?r:p(i)?t:n).push(i);return t.sort(g),n.sort(g),r.sort(g),{documents:t,assets:n,folders:r,total:t.length}}var g=(e,t)=>e.updated_at<t.updated_at?1:e.updated_at>t.updated_at?-1:0;export{i as a,o as i,f as n,s as r,h as t};
|
|
Binary file
|
|
Binary file
|