@nanoforge-dev/editor 0.0.1 → 0.0.2-beta.394e65b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/_app/immutable/assets/0.DOl0zkp7.css +1 -0
- package/dist/client/_app/immutable/assets/0.DOl0zkp7.css.br +0 -0
- package/dist/client/_app/immutable/assets/0.DOl0zkp7.css.gz +0 -0
- package/dist/client/_app/immutable/assets/10.BP_hUVIU.css +1 -0
- package/dist/client/_app/immutable/assets/10.BP_hUVIU.css.br +0 -0
- package/dist/client/_app/immutable/assets/10.BP_hUVIU.css.gz +0 -0
- package/dist/client/_app/immutable/assets/editor.BuC0XPbM.css.gz +0 -0
- package/dist/client/_app/immutable/assets/error.CV-KWLNP.css +1 -0
- package/dist/client/_app/immutable/assets/error.CV-KWLNP.css.br +1 -0
- package/dist/client/_app/immutable/assets/error.CV-KWLNP.css.gz +0 -0
- package/dist/client/_app/immutable/chunks/08VXUWAP.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/43DmfD33.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/6RTg0lbw2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B2921r3t2.js +1 -0
- package/dist/client/_app/immutable/chunks/B2921r3t2.js.br +1 -0
- package/dist/client/_app/immutable/chunks/B2921r3t2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B4w9-fYM2.js +1 -0
- package/dist/client/_app/immutable/chunks/B4w9-fYM2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/B4w9-fYM2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B5-_aFwp.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B8J7ngcE2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B9JPFI3C2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BApLQfqY.js +6 -0
- package/dist/client/_app/immutable/chunks/BApLQfqY.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BApLQfqY.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BDBSsbMb.js +1 -0
- package/dist/client/_app/immutable/chunks/BDBSsbMb.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BDBSsbMb.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BEEn4gHE.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BEtHBSE62.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BKFRmAUx.js +0 -0
- package/dist/client/_app/immutable/chunks/BKFRmAUx.js.br +1 -0
- package/dist/client/_app/immutable/chunks/BKFRmAUx.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BKxtCVv1.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BOotOW0E2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BS47D1Yd2.js +1 -0
- package/dist/client/_app/immutable/chunks/BS47D1Yd2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BS47D1Yd2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BWDRzheF2.js +1 -0
- package/dist/client/_app/immutable/chunks/BWDRzheF2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BWDRzheF2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BWPQTe0t.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BYgofb2h.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BZqFHUa32.js +1 -0
- package/dist/client/_app/immutable/chunks/BZqFHUa32.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BZqFHUa32.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Ba7i2nA0.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bc_sGQ0U.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BeGwcela.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bk9DeFcz2.js +1 -0
- package/dist/client/_app/immutable/chunks/Bk9DeFcz2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Bk9DeFcz2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BlGyHMDZ.js +1 -0
- package/dist/client/_app/immutable/chunks/BlGyHMDZ.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BlGyHMDZ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bri6UV-V2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BvRk9kiK.js +0 -0
- package/dist/client/_app/immutable/chunks/BvRk9kiK.js.br +1 -0
- package/dist/client/_app/immutable/chunks/BvRk9kiK.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BwWAgYKi2.js +1 -0
- package/dist/client/_app/immutable/chunks/BwWAgYKi2.js.br +3 -0
- package/dist/client/_app/immutable/chunks/BwWAgYKi2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BwWrilGY.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bxkupp3x.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bz4Y3fRF.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BzGBrbo22.js +1 -0
- package/dist/client/_app/immutable/chunks/BzGBrbo22.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BzGBrbo22.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C-y9NEjX2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C50LmoI1.js +0 -0
- package/dist/client/_app/immutable/chunks/C50LmoI1.js.br +1 -0
- package/dist/client/_app/immutable/chunks/C50LmoI1.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C531GsRP.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C5_-GSwl2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/{Bi01QGTh2.js → C7bUlFLk2.js} +1 -1
- package/dist/client/_app/immutable/chunks/C7bUlFLk2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/C7bUlFLk2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C7h46wYY.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/{XIokwnxj2.js → C83DJP9w2.js} +1 -1
- package/dist/client/_app/immutable/chunks/C83DJP9w2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/C83DJP9w2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C8Ef5oNN2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CC2rA5mh.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CIPQ_RoX.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CKei9xPI2.js +2 -0
- package/dist/client/_app/immutable/chunks/CKei9xPI2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CKei9xPI2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CRfGWb83.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CVaqCwHa.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CcwsVR0C.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CfSJPG6W2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Cimd5fb32.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Cl5WnCnS.js +0 -0
- package/dist/client/_app/immutable/chunks/Cl5WnCnS.js.br +1 -0
- package/dist/client/_app/immutable/chunks/Cl5WnCnS.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/ClamHrr6.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Cm7r79vr.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CmuvbAn5.js +1 -0
- package/dist/client/_app/immutable/chunks/CmuvbAn5.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CmuvbAn5.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CnhOha0Z2.js +4 -0
- package/dist/client/_app/immutable/chunks/CnhOha0Z2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CnhOha0Z2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Coa6r0tY.js +1 -0
- package/dist/client/_app/immutable/chunks/Coa6r0tY.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Coa6r0tY.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CopQ2nXW.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CpzslTdj2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CsQS60Ue2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Ctc_6ReW.js +1 -0
- package/dist/client/_app/immutable/chunks/Ctc_6ReW.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Ctc_6ReW.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D-oSqn_W2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D-ptJ9y-.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D05T4iGw2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D3hlyOfw.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DFXoGGM32.js +1 -0
- package/dist/client/_app/immutable/chunks/DFXoGGM32.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DFXoGGM32.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/{BwWFGvpp2.js → DH-ThjiG2.js} +2 -2
- package/dist/client/_app/immutable/chunks/DH-ThjiG2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DH-ThjiG2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DHQLzCjY2.js +1 -0
- package/dist/client/_app/immutable/chunks/DHQLzCjY2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DHQLzCjY2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DHpiXF5c.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DIMkf-bt.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DISqw1ZD.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DMUM7wLl.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DT7zqm-g.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/{B1bBmRUz2.js → DT8Ddh1L2.js} +1 -1
- package/dist/client/_app/immutable/chunks/DT8Ddh1L2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DT8Ddh1L2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DTj74zXo.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DV3o63ZY2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DZFCIeNp2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D_Lu-MrJ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DauUninz.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DbInun42.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DdL9SqIa.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/De2hgUGE.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DezsRK8O.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DfAL3LhV.js +293 -0
- package/dist/client/_app/immutable/chunks/DfAL3LhV.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DfAL3LhV.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DgrK8UCQ.js +0 -0
- package/dist/client/_app/immutable/chunks/DgrK8UCQ.js.br +1 -0
- package/dist/client/_app/immutable/chunks/DgrK8UCQ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DkqhCAOL.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DmHpPYUd.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DpFanUEy2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DrH0SRf2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/{BnEty9Zf.js → DuDzfUqN2.js} +1 -1
- package/dist/client/_app/immutable/chunks/DuDzfUqN2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DuDzfUqN2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DybRo6-H.js +0 -0
- package/dist/client/_app/immutable/chunks/DybRo6-H.js.br +1 -0
- package/dist/client/_app/immutable/chunks/DybRo6-H.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Fu4roQAh.js +1 -0
- package/dist/client/_app/immutable/chunks/Fu4roQAh.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Fu4roQAh.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/FvmIjYaQ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/JwdpM2S5.js +1 -0
- package/dist/client/_app/immutable/chunks/JwdpM2S5.js.br +0 -0
- package/dist/client/_app/immutable/chunks/JwdpM2S5.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/NEE52Syq.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/SOo6toE5.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Z5eAx3Zn.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/ZLGReh43.js +3 -0
- package/dist/client/_app/immutable/chunks/ZLGReh43.js.br +0 -0
- package/dist/client/_app/immutable/chunks/ZLGReh43.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/bTuwJoIa.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/fmXr3nnJ2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/gp-XZpBa.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/i0X4ZdIN.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/mRVEsFly2.js +1 -0
- package/dist/client/_app/immutable/chunks/mRVEsFly2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/mRVEsFly2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/nr791fC2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/onAF5SnQ2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/orCHVlgT.js +1 -0
- package/dist/client/_app/immutable/chunks/orCHVlgT.js.br +0 -0
- package/dist/client/_app/immutable/chunks/orCHVlgT.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/oz_6vUea.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/sBoK_t0W2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/uo5fvlDn2.js +872 -0
- package/dist/client/_app/immutable/chunks/uo5fvlDn2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/uo5fvlDn2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/xihTtKlq.js.gz +0 -0
- package/dist/client/_app/immutable/entry/app.BzOeKbPs.js +2 -0
- package/dist/client/_app/immutable/entry/app.BzOeKbPs.js.br +0 -0
- package/dist/client/_app/immutable/entry/app.BzOeKbPs.js.gz +0 -0
- package/dist/client/_app/immutable/entry/start.CNF2MUuM.js +1 -0
- package/dist/client/_app/immutable/entry/start.CNF2MUuM.js.br +0 -0
- package/dist/client/_app/immutable/entry/start.CNF2MUuM.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/0.CPqemWaq.js +9 -0
- package/dist/client/_app/immutable/nodes/0.CPqemWaq.js.br +0 -0
- package/dist/client/_app/immutable/nodes/0.CPqemWaq.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/1.OaHPDibP.js +1 -0
- package/dist/client/_app/immutable/nodes/1.OaHPDibP.js.br +2 -0
- package/dist/client/_app/immutable/nodes/1.OaHPDibP.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/10.BRGL1_0_.js +6 -0
- package/dist/client/_app/immutable/nodes/10.BRGL1_0_.js.br +0 -0
- package/dist/client/_app/immutable/nodes/10.BRGL1_0_.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/2.BK6m2FYa.js +1 -0
- package/dist/client/_app/immutable/nodes/2.BK6m2FYa.js.br +0 -0
- package/dist/client/_app/immutable/nodes/2.BK6m2FYa.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/9.Hjdmo-wG.js +1 -0
- package/dist/client/_app/immutable/nodes/9.Hjdmo-wG.js.br +0 -0
- package/dist/client/_app/immutable/nodes/9.Hjdmo-wG.js.gz +0 -0
- package/dist/client/_app/immutable/workers/{css.worker-DRFWP4k7.js → css.worker-CvXBzhp8.js} +2 -2
- package/dist/client/_app/immutable/workers/css.worker-CvXBzhp8.js.br +0 -0
- package/dist/client/_app/immutable/workers/css.worker-CvXBzhp8.js.gz +0 -0
- package/dist/client/_app/immutable/workers/{html.worker-CXAEVlCI.js → html.worker-BO6WuOEO.js} +3 -3
- package/dist/client/_app/immutable/workers/html.worker-BO6WuOEO.js.br +0 -0
- package/dist/client/_app/immutable/workers/html.worker-BO6WuOEO.js.gz +0 -0
- package/dist/client/_app/immutable/workers/{json.worker-Dkwen84u.js → json.worker-BkJRGcCJ.js} +2 -2
- package/dist/client/_app/immutable/workers/json.worker-BkJRGcCJ.js.br +0 -0
- package/dist/client/_app/immutable/workers/json.worker-BkJRGcCJ.js.gz +0 -0
- package/dist/client/_app/immutable/workers/{ts.worker-DJwDx_mp.js → ts.worker-B0J26iPs.js} +33 -18
- package/dist/client/_app/immutable/workers/ts.worker-B0J26iPs.js.br +0 -0
- package/dist/client/_app/immutable/workers/ts.worker-B0J26iPs.js.gz +0 -0
- package/dist/client/_app/version.json +1 -1
- package/dist/client/_app/version.json.br +0 -0
- package/dist/client/_app/version.json.gz +0 -0
- package/dist/client/assets/fonts/dmmono-53a90e28.woff2 +0 -0
- package/dist/client/assets/fonts/dmmono-cd6ed524.woff2 +0 -0
- package/dist/client/assets/fonts/dmsans-56778fc7.woff2 +0 -0
- package/dist/client/assets/fonts/dmsans-7c37c8a6.woff2 +0 -0
- package/dist/client/assets/fonts/dmserifdisplay-1f997542.woff2 +0 -0
- package/dist/client/assets/fonts/dmserifdisplay-b6206db2.woff2 +0 -0
- package/dist/client/favicon.svg.gz +0 -0
- package/dist/server/chunks/0-CM-Y6ut6.js +16 -0
- package/dist/server/chunks/0-CM-Y6ut6.js.map +1 -0
- package/dist/server/chunks/{1-BgVLfks1.js → 1-C2ffLW3O.js} +7 -7
- package/dist/server/chunks/{1-BgVLfks1.js.map → 1-C2ffLW3O.js.map} +1 -1
- package/dist/server/chunks/10-DhkWDAeT.js +22 -0
- package/dist/server/chunks/10-DhkWDAeT.js.map +1 -0
- package/dist/server/chunks/{2-CzdRJh2P.js → 2-BAs82M_7.js} +13 -13
- package/dist/server/chunks/2-BAs82M_7.js.map +1 -0
- package/dist/server/chunks/3-CtfjP4uZ.js +263 -0
- package/dist/server/chunks/3-CtfjP4uZ.js.map +1 -0
- package/dist/server/chunks/4-DP-_gDay.js +29 -0
- package/dist/server/chunks/4-DP-_gDay.js.map +1 -0
- package/dist/server/chunks/5-610NKQc3.js +29 -0
- package/dist/server/chunks/5-610NKQc3.js.map +1 -0
- package/dist/server/chunks/6-Dl_h_OyU.js +98 -0
- package/dist/server/chunks/6-Dl_h_OyU.js.map +1 -0
- package/dist/server/chunks/7-BUEKgK7m.js +27 -0
- package/dist/server/chunks/7-BUEKgK7m.js.map +1 -0
- package/dist/server/chunks/8-s07Rj2Zo.js +35 -0
- package/dist/server/chunks/8-s07Rj2Zo.js.map +1 -0
- package/dist/server/chunks/9-CDMb5iwc.js +22 -0
- package/dist/server/chunks/9-CDMb5iwc.js.map +1 -0
- package/dist/server/chunks/_layout.svelte-uX7XiB9K.js +1944 -0
- package/dist/server/chunks/_layout.svelte-uX7XiB9K.js.map +1 -0
- package/dist/server/chunks/_page.svelte-Bn7BSazx.js +599 -0
- package/dist/server/chunks/_page.svelte-Bn7BSazx.js.map +1 -0
- package/dist/server/chunks/_page.svelte-DR4jsdM6.js +155 -0
- package/dist/server/chunks/_page.svelte-DR4jsdM6.js.map +1 -0
- package/dist/server/chunks/_page.svelte-vOyGpofm.js +6274 -0
- package/dist/server/chunks/_page.svelte-vOyGpofm.js.map +1 -0
- package/dist/server/chunks/_server.ts-DlC2sxcm.js +35 -0
- package/dist/server/chunks/_server.ts-DlC2sxcm.js.map +1 -0
- package/dist/server/chunks/_server.ts-a-I4s4R9.js +19 -0
- package/dist/server/chunks/_server.ts-a-I4s4R9.js.map +1 -0
- package/dist/server/chunks/{app-l-cuFP__.js → app-DUeJj5RD.js} +1 -1
- package/dist/server/chunks/app-DUeJj5RD.js.map +1 -0
- package/dist/server/chunks/{chunk-9PtDFT_4.js → chunk-ByNZkrT6.js} +5 -7
- package/dist/server/chunks/chunk-ByNZkrT6.js.map +1 -0
- package/dist/server/chunks/chunk-D7D4PA-g.js +13 -0
- package/dist/server/chunks/{client-Dx0O-q6m.js → client-bZcBshMs.js} +53 -9
- package/dist/server/chunks/client-bZcBshMs.js.map +1 -0
- package/dist/server/chunks/const-Dy5RfQqP.js +17 -0
- package/dist/server/chunks/const-Dy5RfQqP.js.map +1 -0
- package/dist/server/chunks/decorate-CQ_JIwqD.js +11 -0
- package/dist/server/chunks/decorate-CQ_JIwqD.js.map +1 -0
- package/dist/server/chunks/error-DYeUQ7mQ.js +14985 -0
- package/dist/server/chunks/error-DYeUQ7mQ.js.map +1 -0
- package/dist/server/chunks/error.svelte-DDsdZM_m.js +12 -0
- package/dist/server/chunks/error.svelte-DDsdZM_m.js.map +1 -0
- package/dist/server/chunks/{dev-7V6fUCff.js → events-Bhh2w-5S.js} +1507 -1032
- package/dist/server/chunks/events-Bhh2w-5S.js.map +1 -0
- package/dist/server/chunks/{exports-j3HcL9It.js → exports-CWOtdr_a.js} +4 -5
- package/dist/server/chunks/exports-CWOtdr_a.js.map +1 -0
- package/dist/server/chunks/format-DGOlJxF5.js +123 -0
- package/dist/server/chunks/format-DGOlJxF5.js.map +1 -0
- package/dist/server/chunks/hooks.server-BGpE7svk.js +362 -0
- package/dist/server/chunks/hooks.server-BGpE7svk.js.map +1 -0
- package/dist/server/chunks/{hooks.universal-0JHSyeLw.js → hooks.universal-DhGFdBkK.js} +2 -2
- package/dist/server/chunks/{hooks.universal-0JHSyeLw.js.map → hooks.universal-DhGFdBkK.js.map} +1 -1
- package/dist/server/chunks/{internal-BgFVxXcc.js → internal-DsA4iYdx.js} +2 -2
- package/dist/server/chunks/{internal-BgFVxXcc.js.map → internal-DsA4iYdx.js.map} +1 -1
- package/dist/server/chunks/{internal-BqoJe00m.js → internal2-DBpj29pr.js} +185 -254
- package/dist/server/chunks/internal2-DBpj29pr.js.map +1 -0
- package/dist/server/chunks/loader-circle-CFNm9vip.js +1592 -0
- package/dist/server/chunks/loader-circle-CFNm9vip.js.map +1 -0
- package/dist/server/chunks/logo-DQI0khKS.js +848 -0
- package/dist/server/chunks/logo-DQI0khKS.js.map +1 -0
- package/dist/server/chunks/project-loader-DaQVgPID.js +185 -0
- package/dist/server/chunks/project-loader-DaQVgPID.js.map +1 -0
- package/dist/server/chunks/request-handler-guINVc1G.js +1089 -0
- package/dist/server/chunks/request-handler-guINVc1G.js.map +1 -0
- package/dist/server/chunks/{runtime-ISoc6PNh.js → runtime-CDHWD9vo.js} +3 -7
- package/dist/server/chunks/runtime-CDHWD9vo.js.map +1 -0
- package/dist/server/chunks/schemas-BDVbWglI.js +11364 -0
- package/dist/server/chunks/schemas-BDVbWglI.js.map +1 -0
- package/dist/server/chunks/{hooks.server-DqaQ1y1I.js → session-DLCjVGKo.js} +77 -368
- package/dist/server/chunks/session-DLCjVGKo.js.map +1 -0
- package/dist/server/chunks/{shared-server-D--cyMsO.js → shared-server-Cha0Qlv9.js} +1 -1
- package/dist/server/chunks/shared-server-Cha0Qlv9.js.map +1 -0
- package/dist/server/chunks/{error.svelte-C5CCEI9O.js → state-DwdUA00F.js} +5 -33
- package/dist/server/chunks/state-DwdUA00F.js.map +1 -0
- package/dist/server/chunks/window-D774FEA_.js +6 -0
- package/dist/server/chunks/window-D774FEA_.js.map +1 -0
- package/dist/server/index.js +387 -235
- package/dist/server/index.js.map +1 -1
- package/dist/server/manifest.js +98 -26
- package/dist/server/manifest.js.map +1 -1
- package/package.json +57 -41
- package/dist/client/_app/immutable/assets/0.562EP7L3.css +0 -1
- package/dist/client/_app/immutable/assets/0.562EP7L3.css.br +0 -0
- package/dist/client/_app/immutable/assets/0.562EP7L3.css.gz +0 -0
- package/dist/client/_app/immutable/assets/2.Dl9w-_FK.css +0 -1
- package/dist/client/_app/immutable/assets/2.Dl9w-_FK.css.br +0 -0
- package/dist/client/_app/immutable/assets/2.Dl9w-_FK.css.gz +0 -0
- package/dist/client/_app/immutable/assets/api.CD54FDqW.css +0 -1
- package/dist/client/_app/immutable/assets/api.CD54FDqW.css.br +0 -0
- package/dist/client/_app/immutable/assets/api.CD54FDqW.css.gz +0 -0
- package/dist/client/_app/immutable/chunks/0wEXW2Hc2.js +0 -1
- package/dist/client/_app/immutable/chunks/0wEXW2Hc2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/0wEXW2Hc2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/1rG2eYdz2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/5CAt0tAC.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/5TEFcS4X2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/5k3Q8YWH.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B0Q9zT_Q.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B1GYE4NT.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B1bBmRUz2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/B1bBmRUz2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B3IjbASq.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B3VOL0kZ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B5crfj0i.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BAtlESPp.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BCAAnHTF2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BEN0jOJp.js +0 -1
- package/dist/client/_app/immutable/chunks/BEN0jOJp.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BEN0jOJp.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BHHccBgG2.js +0 -1
- package/dist/client/_app/immutable/chunks/BHHccBgG2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BHHccBgG2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BHxBHC3k.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BK6ghPUh.js +0 -1
- package/dist/client/_app/immutable/chunks/BK6ghPUh.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BK6ghPUh.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BL9YzxJT.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BNqbTcCU.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BSRtLNCV.js +0 -3
- package/dist/client/_app/immutable/chunks/BSRtLNCV.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BSRtLNCV.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BSa9oWuP.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BTEHXt4u.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BUMhJFWc.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BXNW00E2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B__0yjCH2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/B_rYXvqX.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BaORWDBQ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BeRB61Rp.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Berct1R62.js +0 -1
- package/dist/client/_app/immutable/chunks/Berct1R62.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Berct1R62.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bi01QGTh2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Bi01QGTh2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BnEty9Zf.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BnEty9Zf.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Bp42GhE_.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BqR20QL0.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BuvsQ_0P.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BwWFGvpp2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/BwWFGvpp2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/BxyUv_372.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C459oz3p.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C4oBl-ul.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C5dBxjD0.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C7TuqZTk.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C84aX3eL2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CGFoxiJT2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CGdCAl_w2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CJL4GRLV2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CKihvhpr.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CKybJfA6.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CQai7aNJ.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CQghOihB.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CTK4WrGL2.js +0 -1
- package/dist/client/_app/immutable/chunks/CTK4WrGL2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CTK4WrGL2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CUVqITEW2.js +0 -1
- package/dist/client/_app/immutable/chunks/CUVqITEW2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CUVqITEW2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CVmNMiIj.js +0 -1
- package/dist/client/_app/immutable/chunks/CVmNMiIj.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CVmNMiIj.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CW_66Q8N.js +0 -872
- package/dist/client/_app/immutable/chunks/CW_66Q8N.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CW_66Q8N.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CXBbh9s-.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CXlfFz7D2.js +0 -1
- package/dist/client/_app/immutable/chunks/CXlfFz7D2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CXlfFz7D2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/C_QqwttH.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CbFxQFBh.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CmjNmBcK.js +0 -1
- package/dist/client/_app/immutable/chunks/CmjNmBcK.js.br +0 -0
- package/dist/client/_app/immutable/chunks/CmjNmBcK.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CntDmp6G.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CqqoQT4S.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CtzzCjLE2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/CziQemry2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Czovc13W.js +0 -1
- package/dist/client/_app/immutable/chunks/Czovc13W.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Czovc13W.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D38BHtSY.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DBkS_L3S.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DEoC-BX-.js +0 -11
- package/dist/client/_app/immutable/chunks/DEoC-BX-.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DEoC-BX-.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DHkiqSLl.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DL7ZpfJd.js +0 -1
- package/dist/client/_app/immutable/chunks/DL7ZpfJd.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DL7ZpfJd.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DUC3NMun2.js +0 -4
- package/dist/client/_app/immutable/chunks/DUC3NMun2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DUC3NMun2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DWUlubL2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/D_HtEbjl.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DaCLQrfC.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DbxPn-f9.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DhPi0T7V2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DkZEX-tr.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/Dqs1VwMg2.js +0 -1
- package/dist/client/_app/immutable/chunks/Dqs1VwMg2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/Dqs1VwMg2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DrDIkqkr2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DunPnEs5.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/DxLN9Q9A.js +0 -1
- package/dist/client/_app/immutable/chunks/DxLN9Q9A.js.br +0 -0
- package/dist/client/_app/immutable/chunks/DxLN9Q9A.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/GhmjqkHA.js +0 -1
- package/dist/client/_app/immutable/chunks/GhmjqkHA.js.br +0 -0
- package/dist/client/_app/immutable/chunks/GhmjqkHA.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/H_bCfo1Z.js +0 -1
- package/dist/client/_app/immutable/chunks/H_bCfo1Z.js.br +0 -1
- package/dist/client/_app/immutable/chunks/H_bCfo1Z.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/KoMdYtDs2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/OELm4xo1.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/OdxrjoDx.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/SlhV96tq.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/X9L1iai42.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/XIokwnxj2.js.br +0 -0
- package/dist/client/_app/immutable/chunks/XIokwnxj2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/ZmwXQQ8p.js +0 -1
- package/dist/client/_app/immutable/chunks/ZmwXQQ8p.js.br +0 -0
- package/dist/client/_app/immutable/chunks/ZmwXQQ8p.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/acVTcwNd.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/bLoc39kl.js +0 -2
- package/dist/client/_app/immutable/chunks/bLoc39kl.js.br +0 -0
- package/dist/client/_app/immutable/chunks/bLoc39kl.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/dm7qVrFn2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/if7vWS9-.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/kAc38cH_.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/kks0AxFY2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/mA7hbneB.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/qWHUp0PJ2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/u6JPB_fg2.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/v_jBEYI6.js.gz +0 -0
- package/dist/client/_app/immutable/chunks/x4VkYCou2.js.gz +0 -0
- package/dist/client/_app/immutable/entry/app.CrM2Umgq.js +0 -2
- package/dist/client/_app/immutable/entry/app.CrM2Umgq.js.br +0 -0
- package/dist/client/_app/immutable/entry/app.CrM2Umgq.js.gz +0 -0
- package/dist/client/_app/immutable/entry/start.25Vi3KZA.js +0 -1
- package/dist/client/_app/immutable/entry/start.25Vi3KZA.js.br +0 -0
- package/dist/client/_app/immutable/entry/start.25Vi3KZA.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/0.Ck5XUPzX.js +0 -1
- package/dist/client/_app/immutable/nodes/0.Ck5XUPzX.js.br +0 -0
- package/dist/client/_app/immutable/nodes/0.Ck5XUPzX.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/1.Dpx0WKl2.js +0 -1
- package/dist/client/_app/immutable/nodes/1.Dpx0WKl2.js.br +0 -0
- package/dist/client/_app/immutable/nodes/1.Dpx0WKl2.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/2.CwofzauD.js +0 -4
- package/dist/client/_app/immutable/nodes/2.CwofzauD.js.br +0 -0
- package/dist/client/_app/immutable/nodes/2.CwofzauD.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/3.CU9DPzka.js +0 -1
- package/dist/client/_app/immutable/nodes/3.CU9DPzka.js.br +0 -0
- package/dist/client/_app/immutable/nodes/3.CU9DPzka.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/4.P9ayzmJ4.js +0 -5
- package/dist/client/_app/immutable/nodes/4.P9ayzmJ4.js.br +0 -0
- package/dist/client/_app/immutable/nodes/4.P9ayzmJ4.js.gz +0 -0
- package/dist/client/_app/immutable/nodes/5.Dcsjm3Pq.js +0 -1
- package/dist/client/_app/immutable/nodes/5.Dcsjm3Pq.js.br +0 -0
- package/dist/client/_app/immutable/nodes/5.Dcsjm3Pq.js.gz +0 -0
- package/dist/client/_app/immutable/workers/css.worker-DRFWP4k7.js.br +0 -0
- package/dist/client/_app/immutable/workers/css.worker-DRFWP4k7.js.gz +0 -0
- package/dist/client/_app/immutable/workers/html.worker-CXAEVlCI.js.br +0 -0
- package/dist/client/_app/immutable/workers/html.worker-CXAEVlCI.js.gz +0 -0
- package/dist/client/_app/immutable/workers/json.worker-Dkwen84u.js.br +0 -0
- package/dist/client/_app/immutable/workers/json.worker-Dkwen84u.js.gz +0 -0
- package/dist/client/_app/immutable/workers/ts.worker-DJwDx_mp.js.br +0 -0
- package/dist/client/_app/immutable/workers/ts.worker-DJwDx_mp.js.gz +0 -0
- package/dist/server/chunks/0-DmwMCtOF.js +0 -16
- package/dist/server/chunks/0-DmwMCtOF.js.map +0 -1
- package/dist/server/chunks/2-CzdRJh2P.js.map +0 -1
- package/dist/server/chunks/3-C6uctiU1.js +0 -185
- package/dist/server/chunks/3-C6uctiU1.js.map +0 -1
- package/dist/server/chunks/4-BO3KTp14.js +0 -390
- package/dist/server/chunks/4-BO3KTp14.js.map +0 -1
- package/dist/server/chunks/5-LbaHRTVX.js +0 -259
- package/dist/server/chunks/5-LbaHRTVX.js.map +0 -1
- package/dist/server/chunks/_layout.svelte-BzcRjvYO.js +0 -11
- package/dist/server/chunks/_layout.svelte-BzcRjvYO.js.map +0 -1
- package/dist/server/chunks/_page.svelte-CB5X_URD.js +0 -197
- package/dist/server/chunks/_page.svelte-CB5X_URD.js.map +0 -1
- package/dist/server/chunks/_page.svelte-DMwjXpw4.js +0 -13
- package/dist/server/chunks/_page.svelte-DMwjXpw4.js.map +0 -1
- package/dist/server/chunks/_page.svelte-XIYDQw7d.js +0 -14
- package/dist/server/chunks/_page.svelte-XIYDQw7d.js.map +0 -1
- package/dist/server/chunks/_page.svelte-paWD_HcG.js +0 -4302
- package/dist/server/chunks/_page.svelte-paWD_HcG.js.map +0 -1
- package/dist/server/chunks/api-9BLkbfaG.js +0 -9126
- package/dist/server/chunks/api-9BLkbfaG.js.map +0 -1
- package/dist/server/chunks/app-l-cuFP__.js.map +0 -1
- package/dist/server/chunks/client-Dx0O-q6m.js.map +0 -1
- package/dist/server/chunks/dev-7V6fUCff.js.map +0 -1
- package/dist/server/chunks/error.svelte-C5CCEI9O.js.map +0 -1
- package/dist/server/chunks/exports-j3HcL9It.js.map +0 -1
- package/dist/server/chunks/forms-CffPpDq6.js +0 -36
- package/dist/server/chunks/forms-CffPpDq6.js.map +0 -1
- package/dist/server/chunks/hooks.server-DqaQ1y1I.js.map +0 -1
- package/dist/server/chunks/internal-BqoJe00m.js.map +0 -1
- package/dist/server/chunks/runtime-ISoc6PNh.js.map +0 -1
- package/dist/server/chunks/server-BlOy0jJl.js +0 -91
- package/dist/server/chunks/server-BlOy0jJl.js.map +0 -1
- package/dist/server/chunks/shared-server-D--cyMsO.js.map +0 -1
- /package/dist/client/_app/immutable/chunks/{DkZEX-tr.js → 08VXUWAP.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DkZEX-tr.js.br → 08VXUWAP.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{5CAt0tAC.js → 43DmfD33.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{5CAt0tAC.js.br → 43DmfD33.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CQghOihB.js → 6RTg0lbw2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CQghOihB.js.br → 6RTg0lbw2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CqqoQT4S.js → B5-_aFwp.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CqqoQT4S.js.br → B5-_aFwp.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BNqbTcCU.js → B8J7ngcE2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BNqbTcCU.js.br → B8J7ngcE2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C84aX3eL2.js → B9JPFI3C2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C84aX3eL2.js.br → B9JPFI3C2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{Bp42GhE_.js → BEEn4gHE.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{Bp42GhE_.js.br → BEEn4gHE.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BxyUv_372.js → BEtHBSE62.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BxyUv_372.js.br → BEtHBSE62.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DunPnEs5.js → BKxtCVv1.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DunPnEs5.js.br → BKxtCVv1.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CJL4GRLV2.js → BOotOW0E2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CJL4GRLV2.js.br → BOotOW0E2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C5dBxjD0.js → BWPQTe0t.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C5dBxjD0.js.br → BWPQTe0t.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B5crfj0i.js → BYgofb2h.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B5crfj0i.js.br → BYgofb2h.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BeRB61Rp.js → Ba7i2nA0.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BeRB61Rp.js.br → Ba7i2nA0.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BAtlESPp.js → Bc_sGQ0U.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BAtlESPp.js.br → Bc_sGQ0U.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BuvsQ_0P.js → BeGwcela.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BuvsQ_0P.js.br → BeGwcela.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CGdCAl_w2.js → Bri6UV-V2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CGdCAl_w2.js.br → Bri6UV-V2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DaCLQrfC.js → BwWrilGY.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DaCLQrfC.js.br → BwWrilGY.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CXBbh9s-.js → Bxkupp3x.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CXBbh9s-.js.br → Bxkupp3x.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BqR20QL0.js → Bz4Y3fRF.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BqR20QL0.js.br → Bz4Y3fRF.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DrDIkqkr2.js → C-y9NEjX2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DrDIkqkr2.js.br → C-y9NEjX2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BUMhJFWc.js → C531GsRP.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BUMhJFWc.js.br → C531GsRP.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CKybJfA6.js → C5_-GSwl2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CKybJfA6.js.br → C5_-GSwl2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DbxPn-f9.js → C7h46wYY.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DbxPn-f9.js.br → C7h46wYY.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{KoMdYtDs2.js → C8Ef5oNN2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{KoMdYtDs2.js.br → C8Ef5oNN2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DWUlubL2.js → CC2rA5mh.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DWUlubL2.js.br → CC2rA5mh.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{kks0AxFY2.js → CIPQ_RoX.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{kks0AxFY2.js.br → CIPQ_RoX.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C_QqwttH.js → CRfGWb83.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C_QqwttH.js.br → CRfGWb83.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C7TuqZTk.js → CVaqCwHa.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C7TuqZTk.js.br → CVaqCwHa.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{SlhV96tq.js → CcwsVR0C.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{SlhV96tq.js.br → CcwsVR0C.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DhPi0T7V2.js → CfSJPG6W2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DhPi0T7V2.js.br → CfSJPG6W2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{qWHUp0PJ2.js → Cimd5fb32.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{qWHUp0PJ2.js.br → Cimd5fb32.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{if7vWS9-.js → ClamHrr6.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{if7vWS9-.js.br → ClamHrr6.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B_rYXvqX.js → Cm7r79vr.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B_rYXvqX.js.br → Cm7r79vr.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BTEHXt4u.js → CopQ2nXW.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BTEHXt4u.js.br → CopQ2nXW.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CziQemry2.js → CpzslTdj2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CziQemry2.js.br → CpzslTdj2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CtzzCjLE2.js → CsQS60Ue2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CtzzCjLE2.js.br → CsQS60Ue2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{dm7qVrFn2.js → D-oSqn_W2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{dm7qVrFn2.js.br → D-oSqn_W2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CGFoxiJT2.js → D-ptJ9y-.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CGFoxiJT2.js.br → D-ptJ9y-.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{acVTcwNd.js → D05T4iGw2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{acVTcwNd.js.br → D05T4iGw2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CQai7aNJ.js → D3hlyOfw.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CQai7aNJ.js.br → D3hlyOfw.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B3IjbASq.js → DHpiXF5c.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B3IjbASq.js.br → DHpiXF5c.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{kAc38cH_.js → DIMkf-bt.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{kAc38cH_.js.br → DIMkf-bt.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{D_HtEbjl.js → DISqw1ZD.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{D_HtEbjl.js.br → DISqw1ZD.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CKihvhpr.js → DMUM7wLl.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CKihvhpr.js.br → DMUM7wLl.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B1GYE4NT.js → DT7zqm-g.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B1GYE4NT.js.br → DT7zqm-g.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B3VOL0kZ.js → DTj74zXo.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B3VOL0kZ.js.br → DTj74zXo.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B0Q9zT_Q.js → DV3o63ZY2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B0Q9zT_Q.js.br → DV3o63ZY2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{5k3Q8YWH.js → DZFCIeNp2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{5k3Q8YWH.js.br → DZFCIeNp2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BL9YzxJT.js → D_Lu-MrJ.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BL9YzxJT.js.br → D_Lu-MrJ.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{x4VkYCou2.js → DauUninz.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{x4VkYCou2.js.br → DauUninz.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BSa9oWuP.js → DbInun42.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BSa9oWuP.js.br → DbInun42.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CbFxQFBh.js → DdL9SqIa.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CbFxQFBh.js.br → DdL9SqIa.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C4oBl-ul.js → De2hgUGE.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C4oBl-ul.js.br → De2hgUGE.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BaORWDBQ.js → DezsRK8O.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BaORWDBQ.js.br → DezsRK8O.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BHxBHC3k.js → DkqhCAOL.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BHxBHC3k.js.br → DkqhCAOL.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DBkS_L3S.js → DmHpPYUd.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DBkS_L3S.js.br → DmHpPYUd.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{D38BHtSY.js → DpFanUEy2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{D38BHtSY.js.br → DpFanUEy2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{B__0yjCH2.js → DrH0SRf2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{B__0yjCH2.js.br → DrH0SRf2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BCAAnHTF2.js → FvmIjYaQ.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BCAAnHTF2.js.br → FvmIjYaQ.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{CntDmp6G.js → NEE52Syq.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{CntDmp6G.js.br → NEE52Syq.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{X9L1iai42.js → SOo6toE5.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{X9L1iai42.js.br → SOo6toE5.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{OELm4xo1.js → Z5eAx3Zn.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{OELm4xo1.js.br → Z5eAx3Zn.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{BXNW00E2.js → bTuwJoIa.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{BXNW00E2.js.br → bTuwJoIa.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{1rG2eYdz2.js → fmXr3nnJ2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{1rG2eYdz2.js.br → fmXr3nnJ2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{mA7hbneB.js → gp-XZpBa.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{mA7hbneB.js.br → gp-XZpBa.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{DHkiqSLl.js → i0X4ZdIN.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{DHkiqSLl.js.br → i0X4ZdIN.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{C459oz3p.js → nr791fC2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{C459oz3p.js.br → nr791fC2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{OdxrjoDx.js → onAF5SnQ2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{OdxrjoDx.js.br → onAF5SnQ2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{u6JPB_fg2.js → oz_6vUea.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{u6JPB_fg2.js.br → oz_6vUea.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{5TEFcS4X2.js → sBoK_t0W2.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{5TEFcS4X2.js.br → sBoK_t0W2.js.br} +0 -0
- /package/dist/client/_app/immutable/chunks/{v_jBEYI6.js → xihTtKlq.js} +0 -0
- /package/dist/client/_app/immutable/chunks/{v_jBEYI6.js.br → xihTtKlq.js.br} +0 -0
|
@@ -1,4 +1,22 @@
|
|
|
1
|
-
|
|
1
|
+
import { n as __exportAll } from "./chunk-ByNZkrT6.js";
|
|
2
|
+
//#region node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
|
|
3
|
+
function r(e) {
|
|
4
|
+
var t, f, n = "";
|
|
5
|
+
if ("string" == typeof e || "number" == typeof e) n += e;
|
|
6
|
+
else if ("object" == typeof e) if (Array.isArray(e)) {
|
|
7
|
+
var o = e.length;
|
|
8
|
+
for (t = 0; t < o; t++) e[t] && (f = r(e[t])) && (n && (n += " "), n += f);
|
|
9
|
+
} else for (f in e) e[f] && (n && (n += " "), n += f);
|
|
10
|
+
return n;
|
|
11
|
+
}
|
|
12
|
+
function clsx() {
|
|
13
|
+
for (var e, t, f = 0, n = "", o = arguments.length; f < o; f++) (e = arguments[f]) && (t = r(e)) && (n && (n += " "), n += t);
|
|
14
|
+
return n;
|
|
15
|
+
}
|
|
16
|
+
//#endregion
|
|
17
|
+
//#region .svelte-kit/adapter-bun/chunks/index-server.js
|
|
18
|
+
var MAX_ARRAY_LEN = 2 ** 32 - 1;
|
|
19
|
+
var MAX_ARRAY_INDEX = MAX_ARRAY_LEN - 1;
|
|
2
20
|
/** @type {Record<string, string>} */
|
|
3
21
|
var escaped = {
|
|
4
22
|
"<": "\\u003C",
|
|
@@ -80,18 +98,29 @@ var is_identifier = /^[a-zA-Z_$][a-zA-Z_$0-9]*$/;
|
|
|
80
98
|
function stringify_key(key) {
|
|
81
99
|
return is_identifier.test(key) ? "." + key : "[" + JSON.stringify(key) + "]";
|
|
82
100
|
}
|
|
101
|
+
/** @param {number} n */
|
|
102
|
+
function is_valid_array_index(n) {
|
|
103
|
+
if (!Number.isInteger(n)) return false;
|
|
104
|
+
if (n < 0) return false;
|
|
105
|
+
if (n > MAX_ARRAY_INDEX) return false;
|
|
106
|
+
return true;
|
|
107
|
+
}
|
|
108
|
+
/** @param {number} n */
|
|
109
|
+
function is_valid_array_len(n) {
|
|
110
|
+
if (!Number.isInteger(n)) return false;
|
|
111
|
+
if (n < 0) return false;
|
|
112
|
+
if (n > MAX_ARRAY_LEN) return false;
|
|
113
|
+
return true;
|
|
114
|
+
}
|
|
83
115
|
/** @param {string} s */
|
|
84
|
-
function
|
|
116
|
+
function is_valid_array_index_string(s) {
|
|
85
117
|
if (s.length === 0) return false;
|
|
86
118
|
if (s.length > 1 && s.charCodeAt(0) === 48) return false;
|
|
87
119
|
for (let i = 0; i < s.length; i++) {
|
|
88
120
|
const c = s.charCodeAt(i);
|
|
89
121
|
if (c < 48 || c > 57) return false;
|
|
90
122
|
}
|
|
91
|
-
|
|
92
|
-
if (n >= 2 ** 32 - 1) return false;
|
|
93
|
-
if (n < 0) return false;
|
|
94
|
-
return true;
|
|
123
|
+
return is_valid_array_index(+s);
|
|
95
124
|
}
|
|
96
125
|
/**
|
|
97
126
|
* Finds the populated indices of an array.
|
|
@@ -99,7 +128,7 @@ function is_valid_array_index(s) {
|
|
|
99
128
|
*/
|
|
100
129
|
function valid_array_indices(array) {
|
|
101
130
|
const keys = Object.keys(array);
|
|
102
|
-
for (var i = keys.length - 1; i >= 0; i--) if (
|
|
131
|
+
for (var i = keys.length - 1; i >= 0; i--) if (is_valid_array_index_string(keys[i])) break;
|
|
103
132
|
keys.length = i + 1;
|
|
104
133
|
return keys;
|
|
105
134
|
}
|
|
@@ -667,6 +696,26 @@ function deferred() {
|
|
|
667
696
|
reject
|
|
668
697
|
};
|
|
669
698
|
}
|
|
699
|
+
/**
|
|
700
|
+
* When encountering a situation like `let [a, b, c] = $derived(blah())`,
|
|
701
|
+
* we need to stash an intermediate value that `a`, `b`, and `c` derive
|
|
702
|
+
* from, in case it's an iterable
|
|
703
|
+
* @template T
|
|
704
|
+
* @param {ArrayLike<T> | Iterable<T>} value
|
|
705
|
+
* @param {number} [n]
|
|
706
|
+
* @returns {Array<T>}
|
|
707
|
+
*/
|
|
708
|
+
function to_array(value, n) {
|
|
709
|
+
if (Array.isArray(value)) return value;
|
|
710
|
+
if (n === void 0 || !(Symbol.iterator in value)) return Array.from(value);
|
|
711
|
+
/** @type {T[]} */
|
|
712
|
+
const array = [];
|
|
713
|
+
for (const element of value) {
|
|
714
|
+
array.push(element);
|
|
715
|
+
if (array.length === n) break;
|
|
716
|
+
}
|
|
717
|
+
return array;
|
|
718
|
+
}
|
|
670
719
|
var CLEAN = 1024;
|
|
671
720
|
var DIRTY = 2048;
|
|
672
721
|
var MAYBE_DIRTY = 4096;
|
|
@@ -686,13 +735,18 @@ var USER_EFFECT = 1 << 20;
|
|
|
686
735
|
/**
|
|
687
736
|
* Tells that we marked this derived and its reactions as visited during the "mark as (maybe) dirty"-phase.
|
|
688
737
|
* Will be lifted during execution of the derived and during checking its dirty state (both are necessary
|
|
689
|
-
* because a derived might be checked but not executed).
|
|
738
|
+
* because a derived might be checked but not executed). This is a pure performance optimization flag and
|
|
739
|
+
* should not be used for any other purpose!
|
|
690
740
|
*/
|
|
691
741
|
var WAS_MARKED = 65536;
|
|
692
742
|
var REACTION_IS_UPDATING = 1 << 21;
|
|
693
743
|
var ERROR_VALUE = 1 << 23;
|
|
694
744
|
var STATE_SYMBOL = Symbol("$state");
|
|
695
745
|
var LEGACY_PROPS = Symbol("legacy props");
|
|
746
|
+
var ATTRIBUTES_CACHE = Symbol("attributes");
|
|
747
|
+
var CLASS_CACHE = Symbol("class");
|
|
748
|
+
var STYLE_CACHE = Symbol("style");
|
|
749
|
+
var TEXT_CACHE = Symbol("text");
|
|
696
750
|
/** allow users to ignore aborted signal errors if `reason.name === 'StaleReactionError` */
|
|
697
751
|
var STALE_REACTION = new class StaleReactionError extends Error {
|
|
698
752
|
name = "StaleReactionError";
|
|
@@ -765,7 +819,8 @@ function in_webcontainer() {
|
|
|
765
819
|
return !!globalThis.process?.versions?.webcontainer;
|
|
766
820
|
}
|
|
767
821
|
var HYDRATION_ERROR = {};
|
|
768
|
-
var UNINITIALIZED = Symbol();
|
|
822
|
+
var UNINITIALIZED = Symbol("uninitialized");
|
|
823
|
+
var ATTACHMENT_KEY = "@attach";
|
|
769
824
|
/**
|
|
770
825
|
* A `hydratable` value with key `%key%` was created, but at least part of it was not used during the render.
|
|
771
826
|
*
|
|
@@ -801,19 +856,6 @@ function escape_html(value, is_attr) {
|
|
|
801
856
|
}
|
|
802
857
|
return escaped + str.substring(last);
|
|
803
858
|
}
|
|
804
|
-
function r(e) {
|
|
805
|
-
var t, f, n = "";
|
|
806
|
-
if ("string" == typeof e || "number" == typeof e) n += e;
|
|
807
|
-
else if ("object" == typeof e) if (Array.isArray(e)) {
|
|
808
|
-
var o = e.length;
|
|
809
|
-
for (t = 0; t < o; t++) e[t] && (f = r(e[t])) && (n && (n += " "), n += f);
|
|
810
|
-
} else for (f in e) e[f] && (n && (n += " "), n += f);
|
|
811
|
-
return n;
|
|
812
|
-
}
|
|
813
|
-
function clsx$1() {
|
|
814
|
-
for (var e, t, f = 0, n = "", o = arguments.length; f < o; f++) (e = arguments[f]) && (t = r(e)) && (n && (n += " "), n += t);
|
|
815
|
-
return n;
|
|
816
|
-
}
|
|
817
859
|
/**
|
|
818
860
|
* `<div translate={false}>` should be rendered as `<div translate="no">` and _not_
|
|
819
861
|
* `<div translate="false">`, which is equivalent to `<div translate="yes">`. There
|
|
@@ -839,8 +881,8 @@ function attr(name, value, is_boolean = false) {
|
|
|
839
881
|
* TODO Svelte 6 revisit this, and likely turn all falsy values into the empty string (what clsx also does)
|
|
840
882
|
* @param {any} value
|
|
841
883
|
*/
|
|
842
|
-
function clsx(value) {
|
|
843
|
-
if (typeof value === "object") return clsx
|
|
884
|
+
function clsx$1(value) {
|
|
885
|
+
if (typeof value === "object") return clsx(value);
|
|
844
886
|
else return value ?? "";
|
|
845
887
|
}
|
|
846
888
|
var whitespace = [..." \n\r\f\xA0\v"];
|
|
@@ -1318,1129 +1360,1295 @@ function writable(value, start = noop) {
|
|
|
1318
1360
|
};
|
|
1319
1361
|
}
|
|
1320
1362
|
/**
|
|
1363
|
+
* Derived value store by synchronizing one or more readable stores and
|
|
1364
|
+
* applying an aggregation function over its input values.
|
|
1365
|
+
*
|
|
1366
|
+
* @template {Stores} S
|
|
1367
|
+
* @template T
|
|
1368
|
+
* @overload
|
|
1369
|
+
* @param {S} stores
|
|
1370
|
+
* @param {(values: StoresValues<S>, set: (value: T) => void, update: (fn: Updater<T>) => void) => Unsubscriber | void} fn
|
|
1371
|
+
* @param {T} [initial_value]
|
|
1372
|
+
* @returns {Readable<T>}
|
|
1373
|
+
*/
|
|
1374
|
+
/**
|
|
1375
|
+
* Derived value store by synchronizing one or more readable stores and
|
|
1376
|
+
* applying an aggregation function over its input values.
|
|
1377
|
+
*
|
|
1378
|
+
* @template {Stores} S
|
|
1379
|
+
* @template T
|
|
1380
|
+
* @overload
|
|
1381
|
+
* @param {S} stores
|
|
1382
|
+
* @param {(values: StoresValues<S>) => T} fn
|
|
1383
|
+
* @param {T} [initial_value]
|
|
1384
|
+
* @returns {Readable<T>}
|
|
1385
|
+
*/
|
|
1386
|
+
/**
|
|
1387
|
+
* @template {Stores} S
|
|
1388
|
+
* @template T
|
|
1389
|
+
* @param {S} stores
|
|
1390
|
+
* @param {Function} fn
|
|
1391
|
+
* @param {T} [initial_value]
|
|
1392
|
+
* @returns {Readable<T>}
|
|
1393
|
+
*/
|
|
1394
|
+
function derived$1(stores, fn, initial_value) {
|
|
1395
|
+
const single = !Array.isArray(stores);
|
|
1396
|
+
/** @type {Array<Readable<any>>} */
|
|
1397
|
+
const stores_array = single ? [stores] : stores;
|
|
1398
|
+
if (!stores_array.every(Boolean)) throw new Error("derived() expects stores as input, got a falsy value");
|
|
1399
|
+
const auto = fn.length < 2;
|
|
1400
|
+
return readable(initial_value, (set, update) => {
|
|
1401
|
+
let started = false;
|
|
1402
|
+
/** @type {T[]} */
|
|
1403
|
+
const values = [];
|
|
1404
|
+
let pending = 0;
|
|
1405
|
+
let cleanup = noop;
|
|
1406
|
+
const sync = () => {
|
|
1407
|
+
if (pending) return;
|
|
1408
|
+
cleanup();
|
|
1409
|
+
const result = fn(single ? values[0] : values, set, update);
|
|
1410
|
+
if (auto) set(result);
|
|
1411
|
+
else cleanup = typeof result === "function" ? result : noop;
|
|
1412
|
+
};
|
|
1413
|
+
const unsubscribers = stores_array.map((store, i) => subscribe_to_store(store, (value) => {
|
|
1414
|
+
values[i] = value;
|
|
1415
|
+
pending &= ~(1 << i);
|
|
1416
|
+
if (started) sync();
|
|
1417
|
+
}, () => {
|
|
1418
|
+
pending |= 1 << i;
|
|
1419
|
+
}));
|
|
1420
|
+
started = true;
|
|
1421
|
+
sync();
|
|
1422
|
+
return function stop() {
|
|
1423
|
+
run_all(unsubscribers);
|
|
1424
|
+
cleanup();
|
|
1425
|
+
started = false;
|
|
1426
|
+
};
|
|
1427
|
+
});
|
|
1428
|
+
}
|
|
1429
|
+
/**
|
|
1430
|
+
* Takes a store and returns a new one derived from the old one that is readable.
|
|
1431
|
+
*
|
|
1432
|
+
* @template T
|
|
1433
|
+
* @param {Readable<T>} store - store to make readonly
|
|
1434
|
+
* @returns {Readable<T>}
|
|
1435
|
+
*/
|
|
1436
|
+
function readonly(store) {
|
|
1437
|
+
return { subscribe: store.subscribe.bind(store) };
|
|
1438
|
+
}
|
|
1439
|
+
/**
|
|
1440
|
+
* Get the current value from a store by subscribing and immediately unsubscribing.
|
|
1441
|
+
*
|
|
1442
|
+
* @template T
|
|
1443
|
+
* @param {Readable<T>} store
|
|
1444
|
+
* @returns {T}
|
|
1445
|
+
*/
|
|
1446
|
+
function get$1(store) {
|
|
1447
|
+
let value;
|
|
1448
|
+
subscribe_to_store(store, (_) => value = _)();
|
|
1449
|
+
return value;
|
|
1450
|
+
}
|
|
1451
|
+
/**
|
|
1321
1452
|
* We set this to `true` when updating a store so that we correctly
|
|
1322
1453
|
* schedule effects if the update takes place inside a `$:` effect
|
|
1323
1454
|
*/
|
|
1324
1455
|
var legacy_is_updating_store = false;
|
|
1325
|
-
/** @import { Fork } from 'svelte' */
|
|
1326
|
-
/** @import { Derived, Effect, Reaction, Source, Value } from '#client' */
|
|
1327
|
-
/** @type {Set<Batch>} */
|
|
1328
|
-
var batches = /* @__PURE__ */ new Set();
|
|
1329
|
-
/** @type {Batch | null} */
|
|
1330
|
-
var current_batch = null;
|
|
1331
1456
|
/**
|
|
1332
|
-
*
|
|
1333
|
-
*
|
|
1334
|
-
*
|
|
1335
|
-
*
|
|
1457
|
+
* Returns a `subscribe` function that integrates external event-based systems with Svelte's reactivity.
|
|
1458
|
+
* It's particularly useful for integrating with web APIs like `MediaQuery`, `IntersectionObserver`, or `WebSocket`.
|
|
1459
|
+
*
|
|
1460
|
+
* If `subscribe` is called inside an effect (including indirectly, for example inside a getter),
|
|
1461
|
+
* the `start` callback will be called with an `update` function. Whenever `update` is called, the effect re-runs.
|
|
1462
|
+
*
|
|
1463
|
+
* If `start` returns a cleanup function, it will be called when the effect is destroyed.
|
|
1464
|
+
*
|
|
1465
|
+
* If `subscribe` is called in multiple effects, `start` will only be called once as long as the effects
|
|
1466
|
+
* are active, and the returned teardown function will only be called when all effects are destroyed.
|
|
1467
|
+
*
|
|
1468
|
+
* It's best understood with an example. Here's an implementation of [`MediaQuery`](https://svelte.dev/docs/svelte/svelte-reactivity#MediaQuery):
|
|
1469
|
+
*
|
|
1470
|
+
* ```js
|
|
1471
|
+
* import { createSubscriber } from 'svelte/reactivity';
|
|
1472
|
+
* import { on } from 'svelte/events';
|
|
1473
|
+
*
|
|
1474
|
+
* export class MediaQuery {
|
|
1475
|
+
* #query;
|
|
1476
|
+
* #subscribe;
|
|
1477
|
+
*
|
|
1478
|
+
* constructor(query) {
|
|
1479
|
+
* this.#query = window.matchMedia(`(${query})`);
|
|
1480
|
+
*
|
|
1481
|
+
* this.#subscribe = createSubscriber((update) => {
|
|
1482
|
+
* // when the `change` event occurs, re-run any effects that read `this.current`
|
|
1483
|
+
* const off = on(this.#query, 'change', update);
|
|
1484
|
+
*
|
|
1485
|
+
* // stop listening when all the effects are destroyed
|
|
1486
|
+
* return () => off();
|
|
1487
|
+
* });
|
|
1488
|
+
* }
|
|
1489
|
+
*
|
|
1490
|
+
* get current() {
|
|
1491
|
+
* // This makes the getter reactive, if read in an effect
|
|
1492
|
+
* this.#subscribe();
|
|
1493
|
+
*
|
|
1494
|
+
* // Return the current state of the query, whether or not we're in an effect
|
|
1495
|
+
* return this.#query.matches;
|
|
1496
|
+
* }
|
|
1497
|
+
* }
|
|
1498
|
+
* ```
|
|
1499
|
+
* @param {(update: () => void) => (() => void) | void} start
|
|
1500
|
+
* @since 5.7.0
|
|
1336
1501
|
*/
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1502
|
+
function createSubscriber(start) {
|
|
1503
|
+
let subscribers = 0;
|
|
1504
|
+
let version = source(0);
|
|
1505
|
+
/** @type {(() => void) | void} */
|
|
1506
|
+
let stop;
|
|
1507
|
+
return () => {
|
|
1508
|
+
if (effect_tracking()) {
|
|
1509
|
+
get(version);
|
|
1510
|
+
render_effect(() => {
|
|
1511
|
+
if (subscribers === 0) stop = untrack(() => start(() => increment(version)));
|
|
1512
|
+
subscribers += 1;
|
|
1513
|
+
return () => {
|
|
1514
|
+
queue_micro_task(() => {
|
|
1515
|
+
subscribers -= 1;
|
|
1516
|
+
if (subscribers === 0) {
|
|
1517
|
+
stop?.();
|
|
1518
|
+
stop = void 0;
|
|
1519
|
+
increment(version);
|
|
1520
|
+
}
|
|
1521
|
+
});
|
|
1522
|
+
};
|
|
1523
|
+
});
|
|
1524
|
+
}
|
|
1525
|
+
};
|
|
1526
|
+
}
|
|
1527
|
+
/** @import { Effect, Source, TemplateNode, } from '#client' */
|
|
1342
1528
|
/**
|
|
1343
|
-
*
|
|
1344
|
-
*
|
|
1345
|
-
*
|
|
1346
|
-
*
|
|
1529
|
+
* @typedef {{
|
|
1530
|
+
* onerror?: ((error: unknown, reset: () => void) => void) | null;
|
|
1531
|
+
* failed?: ((anchor: Node, error: () => unknown, reset: () => () => void) => void) | null;
|
|
1532
|
+
* pending?: ((anchor: Node) => void) | null;
|
|
1533
|
+
* }} BoundaryProps
|
|
1347
1534
|
*/
|
|
1348
|
-
var
|
|
1535
|
+
var flags = EFFECT_TRANSPARENT | EFFECT_PRESERVED;
|
|
1349
1536
|
/**
|
|
1350
|
-
*
|
|
1351
|
-
*
|
|
1352
|
-
*
|
|
1353
|
-
* @
|
|
1354
|
-
* @
|
|
1537
|
+
* @param {TemplateNode} node
|
|
1538
|
+
* @param {BoundaryProps} props
|
|
1539
|
+
* @param {((anchor: Node) => void)} children
|
|
1540
|
+
* @param {((error: unknown) => unknown) | undefined} [transform_error]
|
|
1541
|
+
* @returns {void}
|
|
1355
1542
|
*/
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
var
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
* Tuple format: [value, is_derived] (note: is_derived is false for deriveds, too, if they were overridden via assignment)
|
|
1364
|
-
* They keys of this map are identical to `this.#previous`
|
|
1365
|
-
* @type {Map<Value, [any, boolean]>}
|
|
1366
|
-
*/
|
|
1367
|
-
current = /* @__PURE__ */ new Map();
|
|
1368
|
-
/**
|
|
1369
|
-
* The values of any signals (sources and deriveds) that are updated in this batch _before_ those updates took place.
|
|
1370
|
-
* They keys of this map are identical to `this.#current`
|
|
1371
|
-
* @type {Map<Value, any>}
|
|
1372
|
-
*/
|
|
1373
|
-
previous = /* @__PURE__ */ new Map();
|
|
1374
|
-
/**
|
|
1375
|
-
* When the batch is committed (and the DOM is updated), we need to remove old branches
|
|
1376
|
-
* and append new ones by calling the functions added inside (if/each/key/etc) blocks
|
|
1377
|
-
* @type {Set<(batch: Batch) => void>}
|
|
1378
|
-
*/
|
|
1379
|
-
#commit_callbacks = /* @__PURE__ */ new Set();
|
|
1380
|
-
/**
|
|
1381
|
-
* If a fork is discarded, we need to destroy any effects that are no longer needed
|
|
1382
|
-
* @type {Set<(batch: Batch) => void>}
|
|
1383
|
-
*/
|
|
1384
|
-
#discard_callbacks = /* @__PURE__ */ new Set();
|
|
1543
|
+
function boundary(node, props, children, transform_error) {
|
|
1544
|
+
new Boundary(node, props, children, transform_error);
|
|
1545
|
+
}
|
|
1546
|
+
var Boundary = class {
|
|
1547
|
+
/** @type {Boundary | null} */
|
|
1548
|
+
parent;
|
|
1549
|
+
is_pending = false;
|
|
1385
1550
|
/**
|
|
1386
|
-
*
|
|
1387
|
-
*
|
|
1551
|
+
* API-level transformError transform function. Transforms errors before they reach the `failed` snippet.
|
|
1552
|
+
* Inherited from parent boundary, or defaults to identity.
|
|
1553
|
+
* @type {(error: unknown) => unknown}
|
|
1388
1554
|
*/
|
|
1389
|
-
|
|
1555
|
+
transform_error;
|
|
1556
|
+
/** @type {TemplateNode} */
|
|
1557
|
+
#anchor;
|
|
1558
|
+
/** @type {TemplateNode | null} */
|
|
1559
|
+
#hydrate_open = hydrating ? hydrate_node : null;
|
|
1560
|
+
/** @type {BoundaryProps} */
|
|
1561
|
+
#props;
|
|
1562
|
+
/** @type {((anchor: Node) => void)} */
|
|
1563
|
+
#children;
|
|
1564
|
+
/** @type {Effect} */
|
|
1565
|
+
#effect;
|
|
1566
|
+
/** @type {Effect | null} */
|
|
1567
|
+
#main_effect = null;
|
|
1568
|
+
/** @type {Effect | null} */
|
|
1569
|
+
#pending_effect = null;
|
|
1570
|
+
/** @type {Effect | null} */
|
|
1571
|
+
#failed_effect = null;
|
|
1572
|
+
/** @type {DocumentFragment | null} */
|
|
1573
|
+
#offscreen_fragment = null;
|
|
1574
|
+
#local_pending_count = 0;
|
|
1575
|
+
#pending_count = 0;
|
|
1576
|
+
#pending_count_update_queued = false;
|
|
1577
|
+
/** @type {Set<Effect>} */
|
|
1578
|
+
#dirty_effects = /* @__PURE__ */ new Set();
|
|
1579
|
+
/** @type {Set<Effect>} */
|
|
1580
|
+
#maybe_dirty_effects = /* @__PURE__ */ new Set();
|
|
1390
1581
|
/**
|
|
1391
|
-
*
|
|
1392
|
-
*
|
|
1582
|
+
* A source containing the number of pending async deriveds/expressions.
|
|
1583
|
+
* Only created if `$effect.pending()` is used inside the boundary,
|
|
1584
|
+
* otherwise updating the source results in needless `Batch.ensure()`
|
|
1585
|
+
* calls followed by no-op flushes
|
|
1586
|
+
* @type {Source<number> | null}
|
|
1393
1587
|
*/
|
|
1394
|
-
#
|
|
1588
|
+
#effect_pending = null;
|
|
1589
|
+
#effect_pending_subscriber = createSubscriber(() => {
|
|
1590
|
+
this.#effect_pending = source(this.#local_pending_count);
|
|
1591
|
+
return () => {
|
|
1592
|
+
this.#effect_pending = null;
|
|
1593
|
+
};
|
|
1594
|
+
});
|
|
1395
1595
|
/**
|
|
1396
|
-
*
|
|
1397
|
-
* @
|
|
1596
|
+
* @param {TemplateNode} node
|
|
1597
|
+
* @param {BoundaryProps} props
|
|
1598
|
+
* @param {((anchor: Node) => void)} children
|
|
1599
|
+
* @param {((error: unknown) => unknown) | undefined} [transform_error]
|
|
1398
1600
|
*/
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1601
|
+
constructor(node, props, children, transform_error) {
|
|
1602
|
+
this.#anchor = node;
|
|
1603
|
+
this.#props = props;
|
|
1604
|
+
this.#children = (anchor) => {
|
|
1605
|
+
var effect = active_effect;
|
|
1606
|
+
effect.b = this;
|
|
1607
|
+
effect.f |= 128;
|
|
1608
|
+
children(anchor);
|
|
1609
|
+
};
|
|
1610
|
+
this.parent = active_effect.b;
|
|
1611
|
+
this.transform_error = transform_error ?? this.parent?.transform_error ?? ((e) => e);
|
|
1612
|
+
this.#effect = block(() => {
|
|
1613
|
+
if (hydrating) {
|
|
1614
|
+
const comment = this.#hydrate_open;
|
|
1615
|
+
hydrate_next();
|
|
1616
|
+
const server_rendered_pending = comment.data === "[!";
|
|
1617
|
+
if (comment.data.startsWith("[?")) {
|
|
1618
|
+
const serialized_error = JSON.parse(comment.data.slice(2));
|
|
1619
|
+
this.#hydrate_failed_content(serialized_error);
|
|
1620
|
+
} else if (server_rendered_pending) this.#hydrate_pending_content();
|
|
1621
|
+
else this.#hydrate_resolved_content();
|
|
1622
|
+
} else this.#render();
|
|
1623
|
+
}, flags);
|
|
1624
|
+
if (hydrating) this.#anchor = hydrate_node;
|
|
1625
|
+
}
|
|
1626
|
+
#hydrate_resolved_content() {
|
|
1627
|
+
try {
|
|
1628
|
+
this.#main_effect = branch(() => this.#children(this.#anchor));
|
|
1629
|
+
} catch (error) {
|
|
1630
|
+
this.error(error);
|
|
1631
|
+
}
|
|
1632
|
+
}
|
|
1406
1633
|
/**
|
|
1407
|
-
* The
|
|
1408
|
-
* @type {Effect[]}
|
|
1634
|
+
* @param {unknown} error The deserialized error from the server's hydration comment
|
|
1409
1635
|
*/
|
|
1410
|
-
#
|
|
1636
|
+
#hydrate_failed_content(error) {
|
|
1637
|
+
const failed = this.#props.failed;
|
|
1638
|
+
if (!failed) return;
|
|
1639
|
+
this.#failed_effect = branch(() => {
|
|
1640
|
+
failed(this.#anchor, () => error, () => () => {});
|
|
1641
|
+
});
|
|
1642
|
+
}
|
|
1643
|
+
#hydrate_pending_content() {
|
|
1644
|
+
const pending = this.#props.pending;
|
|
1645
|
+
if (!pending) return;
|
|
1646
|
+
this.is_pending = true;
|
|
1647
|
+
this.#pending_effect = branch(() => pending(this.#anchor));
|
|
1648
|
+
queue_micro_task(() => {
|
|
1649
|
+
var fragment = this.#offscreen_fragment = document.createDocumentFragment();
|
|
1650
|
+
var anchor = create_text();
|
|
1651
|
+
fragment.append(anchor);
|
|
1652
|
+
this.#main_effect = this.#run(() => {
|
|
1653
|
+
return branch(() => this.#children(anchor));
|
|
1654
|
+
});
|
|
1655
|
+
if (this.#pending_count === 0) {
|
|
1656
|
+
this.#anchor.before(fragment);
|
|
1657
|
+
this.#offscreen_fragment = null;
|
|
1658
|
+
pause_effect(this.#pending_effect, () => {
|
|
1659
|
+
this.#pending_effect = null;
|
|
1660
|
+
});
|
|
1661
|
+
this.#resolve(current_batch);
|
|
1662
|
+
}
|
|
1663
|
+
});
|
|
1664
|
+
}
|
|
1665
|
+
#render() {
|
|
1666
|
+
try {
|
|
1667
|
+
this.is_pending = this.has_pending_snippet();
|
|
1668
|
+
this.#pending_count = 0;
|
|
1669
|
+
this.#local_pending_count = 0;
|
|
1670
|
+
this.#main_effect = branch(() => {
|
|
1671
|
+
this.#children(this.#anchor);
|
|
1672
|
+
});
|
|
1673
|
+
if (this.#pending_count > 0) {
|
|
1674
|
+
var fragment = this.#offscreen_fragment = document.createDocumentFragment();
|
|
1675
|
+
move_effect(this.#main_effect, fragment);
|
|
1676
|
+
const pending = this.#props.pending;
|
|
1677
|
+
this.#pending_effect = branch(() => pending(this.#anchor));
|
|
1678
|
+
} else this.#resolve(current_batch);
|
|
1679
|
+
} catch (error) {
|
|
1680
|
+
this.error(error);
|
|
1681
|
+
}
|
|
1682
|
+
}
|
|
1411
1683
|
/**
|
|
1412
|
-
*
|
|
1413
|
-
* @type {Effect[]}
|
|
1684
|
+
* @param {Batch} batch
|
|
1414
1685
|
*/
|
|
1415
|
-
#
|
|
1686
|
+
#resolve(batch) {
|
|
1687
|
+
this.is_pending = false;
|
|
1688
|
+
batch.transfer_effects(this.#dirty_effects, this.#maybe_dirty_effects);
|
|
1689
|
+
}
|
|
1416
1690
|
/**
|
|
1417
|
-
*
|
|
1418
|
-
* @
|
|
1691
|
+
* Defer an effect inside a pending boundary until the boundary resolves
|
|
1692
|
+
* @param {Effect} effect
|
|
1419
1693
|
*/
|
|
1420
|
-
|
|
1694
|
+
defer_effect(effect) {
|
|
1695
|
+
defer_effect(effect, this.#dirty_effects, this.#maybe_dirty_effects);
|
|
1696
|
+
}
|
|
1421
1697
|
/**
|
|
1422
|
-
*
|
|
1423
|
-
* @
|
|
1698
|
+
* Returns `false` if the effect exists inside a boundary whose pending snippet is shown
|
|
1699
|
+
* @returns {boolean}
|
|
1424
1700
|
*/
|
|
1425
|
-
|
|
1701
|
+
is_rendered() {
|
|
1702
|
+
return !this.is_pending && (!this.parent || this.parent.is_rendered());
|
|
1703
|
+
}
|
|
1704
|
+
has_pending_snippet() {
|
|
1705
|
+
return !!this.#props.pending;
|
|
1706
|
+
}
|
|
1426
1707
|
/**
|
|
1427
|
-
*
|
|
1428
|
-
*
|
|
1429
|
-
* The value contains child effects that were dirty/maybe_dirty before being reset,
|
|
1430
|
-
* so they can be rescheduled if the branch survives.
|
|
1431
|
-
* @type {Map<Effect, { d: Effect[], m: Effect[] }>}
|
|
1708
|
+
* @template T
|
|
1709
|
+
* @param {() => T} fn
|
|
1432
1710
|
*/
|
|
1433
|
-
#
|
|
1711
|
+
#run(fn) {
|
|
1712
|
+
var previous_effect = active_effect;
|
|
1713
|
+
var previous_reaction = active_reaction;
|
|
1714
|
+
var previous_ctx = component_context;
|
|
1715
|
+
set_active_effect(this.#effect);
|
|
1716
|
+
set_active_reaction(this.#effect);
|
|
1717
|
+
set_component_context(this.#effect.ctx);
|
|
1718
|
+
try {
|
|
1719
|
+
Batch.ensure();
|
|
1720
|
+
return fn();
|
|
1721
|
+
} catch (e) {
|
|
1722
|
+
handle_error(e);
|
|
1723
|
+
return null;
|
|
1724
|
+
} finally {
|
|
1725
|
+
set_active_effect(previous_effect);
|
|
1726
|
+
set_active_reaction(previous_reaction);
|
|
1727
|
+
set_component_context(previous_ctx);
|
|
1728
|
+
}
|
|
1729
|
+
}
|
|
1434
1730
|
/**
|
|
1435
|
-
*
|
|
1436
|
-
*
|
|
1731
|
+
* Updates the pending count associated with the currently visible pending snippet,
|
|
1732
|
+
* if any, such that we can replace the snippet with content once work is done
|
|
1733
|
+
* @param {1 | -1} d
|
|
1734
|
+
* @param {Batch} batch
|
|
1437
1735
|
*/
|
|
1438
|
-
#
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
skipped = true;
|
|
1453
|
-
break;
|
|
1454
|
-
}
|
|
1455
|
-
e = e.parent;
|
|
1736
|
+
#update_pending_count(d, batch) {
|
|
1737
|
+
if (!this.has_pending_snippet()) {
|
|
1738
|
+
if (this.parent) this.parent.#update_pending_count(d, batch);
|
|
1739
|
+
return;
|
|
1740
|
+
}
|
|
1741
|
+
this.#pending_count += d;
|
|
1742
|
+
if (this.#pending_count === 0) {
|
|
1743
|
+
this.#resolve(batch);
|
|
1744
|
+
if (this.#pending_effect) pause_effect(this.#pending_effect, () => {
|
|
1745
|
+
this.#pending_effect = null;
|
|
1746
|
+
});
|
|
1747
|
+
if (this.#offscreen_fragment) {
|
|
1748
|
+
this.#anchor.before(this.#offscreen_fragment);
|
|
1749
|
+
this.#offscreen_fragment = null;
|
|
1456
1750
|
}
|
|
1457
|
-
if (!skipped) return true;
|
|
1458
1751
|
}
|
|
1459
|
-
return false;
|
|
1460
1752
|
}
|
|
1461
1753
|
/**
|
|
1462
|
-
*
|
|
1463
|
-
*
|
|
1754
|
+
* Update the source that powers `$effect.pending()` inside this boundary,
|
|
1755
|
+
* and controls when the current `pending` snippet (if any) is removed.
|
|
1756
|
+
* Do not call from inside the class
|
|
1757
|
+
* @param {1 | -1} d
|
|
1758
|
+
* @param {Batch} batch
|
|
1464
1759
|
*/
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1760
|
+
update_pending_count(d, batch) {
|
|
1761
|
+
this.#update_pending_count(d, batch);
|
|
1762
|
+
this.#local_pending_count += d;
|
|
1763
|
+
if (!this.#effect_pending || this.#pending_count_update_queued) return;
|
|
1764
|
+
this.#pending_count_update_queued = true;
|
|
1765
|
+
queue_micro_task(() => {
|
|
1766
|
+
this.#pending_count_update_queued = false;
|
|
1767
|
+
if (this.#effect_pending) internal_set(this.#effect_pending, this.#local_pending_count);
|
|
1469
1768
|
});
|
|
1470
|
-
|
|
1769
|
+
}
|
|
1770
|
+
get_effect_pending() {
|
|
1771
|
+
this.#effect_pending_subscriber();
|
|
1772
|
+
return get(this.#effect_pending);
|
|
1773
|
+
}
|
|
1774
|
+
/** @param {unknown} error */
|
|
1775
|
+
error(error) {
|
|
1776
|
+
if (!this.#props.onerror && !this.#props.failed) throw error;
|
|
1777
|
+
if (current_batch?.is_fork) {
|
|
1778
|
+
if (this.#main_effect) current_batch.skip_effect(this.#main_effect);
|
|
1779
|
+
if (this.#pending_effect) current_batch.skip_effect(this.#pending_effect);
|
|
1780
|
+
if (this.#failed_effect) current_batch.skip_effect(this.#failed_effect);
|
|
1781
|
+
current_batch.oncommit(() => {
|
|
1782
|
+
this.#handle_error(error);
|
|
1783
|
+
});
|
|
1784
|
+
} else this.#handle_error(error);
|
|
1471
1785
|
}
|
|
1472
1786
|
/**
|
|
1473
|
-
*
|
|
1474
|
-
* any tracked dirty/maybe_dirty child effects
|
|
1475
|
-
* @param {Effect} effect
|
|
1476
|
-
* @param {(e: Effect) => void} callback
|
|
1787
|
+
* @param {unknown} error
|
|
1477
1788
|
*/
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
this.#
|
|
1482
|
-
for (var e of tracked.d) {
|
|
1483
|
-
set_signal_status(e, DIRTY);
|
|
1484
|
-
callback(e);
|
|
1485
|
-
}
|
|
1486
|
-
for (e of tracked.m) {
|
|
1487
|
-
set_signal_status(e, MAYBE_DIRTY);
|
|
1488
|
-
callback(e);
|
|
1489
|
-
}
|
|
1789
|
+
#handle_error(error) {
|
|
1790
|
+
if (this.#main_effect) {
|
|
1791
|
+
destroy_effect(this.#main_effect);
|
|
1792
|
+
this.#main_effect = null;
|
|
1490
1793
|
}
|
|
1491
|
-
this.#
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
if (flush_count++ > 1e3) {
|
|
1495
|
-
batches.delete(this);
|
|
1496
|
-
infinite_loop_guard();
|
|
1794
|
+
if (this.#pending_effect) {
|
|
1795
|
+
destroy_effect(this.#pending_effect);
|
|
1796
|
+
this.#pending_effect = null;
|
|
1497
1797
|
}
|
|
1498
|
-
if (
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
set_signal_status(e, DIRTY);
|
|
1502
|
-
this.schedule(e);
|
|
1503
|
-
}
|
|
1504
|
-
for (const e of this.#maybe_dirty_effects) {
|
|
1505
|
-
set_signal_status(e, MAYBE_DIRTY);
|
|
1506
|
-
this.schedule(e);
|
|
1507
|
-
}
|
|
1798
|
+
if (this.#failed_effect) {
|
|
1799
|
+
destroy_effect(this.#failed_effect);
|
|
1800
|
+
this.#failed_effect = null;
|
|
1508
1801
|
}
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
var effects = collected_effects = [];
|
|
1514
|
-
/** @type {Effect[]} */
|
|
1515
|
-
var render_effects = [];
|
|
1516
|
-
/**
|
|
1517
|
-
* @type {Effect[]}
|
|
1518
|
-
* @deprecated when we get rid of legacy mode and stores, we can get rid of this
|
|
1519
|
-
*/
|
|
1520
|
-
var updates = legacy_updates = [];
|
|
1521
|
-
for (const root of roots) try {
|
|
1522
|
-
this.#traverse(root, effects, render_effects);
|
|
1523
|
-
} catch (e) {
|
|
1524
|
-
reset_all(root);
|
|
1525
|
-
throw e;
|
|
1526
|
-
}
|
|
1527
|
-
current_batch = null;
|
|
1528
|
-
if (updates.length > 0) {
|
|
1529
|
-
var batch = Batch.ensure();
|
|
1530
|
-
for (const e of updates) batch.schedule(e);
|
|
1531
|
-
}
|
|
1532
|
-
collected_effects = null;
|
|
1533
|
-
legacy_updates = null;
|
|
1534
|
-
if (this.#is_deferred() || this.#is_blocked()) {
|
|
1535
|
-
this.#defer_effects(render_effects);
|
|
1536
|
-
this.#defer_effects(effects);
|
|
1537
|
-
for (const [e, t] of this.#skipped_branches) reset_branch(e, t);
|
|
1538
|
-
} else {
|
|
1539
|
-
if (this.#pending.size === 0) batches.delete(this);
|
|
1540
|
-
this.#dirty_effects.clear();
|
|
1541
|
-
this.#maybe_dirty_effects.clear();
|
|
1542
|
-
for (const fn of this.#commit_callbacks) fn(this);
|
|
1543
|
-
this.#commit_callbacks.clear();
|
|
1544
|
-
flush_queued_effects(render_effects);
|
|
1545
|
-
flush_queued_effects(effects);
|
|
1546
|
-
this.#deferred?.resolve();
|
|
1547
|
-
}
|
|
1548
|
-
var next_batch = current_batch;
|
|
1549
|
-
if (this.#roots.length > 0) {
|
|
1550
|
-
const batch = next_batch ??= this;
|
|
1551
|
-
batch.#roots.push(...this.#roots.filter((r) => !batch.#roots.includes(r)));
|
|
1552
|
-
}
|
|
1553
|
-
if (next_batch !== null) {
|
|
1554
|
-
batches.add(next_batch);
|
|
1555
|
-
next_batch.#process();
|
|
1802
|
+
if (hydrating) {
|
|
1803
|
+
set_hydrate_node(this.#hydrate_open);
|
|
1804
|
+
next();
|
|
1805
|
+
set_hydrate_node(skip_nodes());
|
|
1556
1806
|
}
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
#traverse(root, effects, render_effects) {
|
|
1566
|
-
root.f ^= CLEAN;
|
|
1567
|
-
var effect = root.first;
|
|
1568
|
-
while (effect !== null) {
|
|
1569
|
-
var flags = effect.f;
|
|
1570
|
-
var is_branch = (flags & 96) !== 0;
|
|
1571
|
-
if (!(is_branch && (flags & 1024) !== 0 || (flags & 8192) !== 0 || this.#skipped_branches.has(effect)) && effect.fn !== null) {
|
|
1572
|
-
if (is_branch) effect.f ^= CLEAN;
|
|
1573
|
-
else if ((flags & 4) !== 0) effects.push(effect);
|
|
1574
|
-
else if (is_dirty(effect)) {
|
|
1575
|
-
if ((flags & 16) !== 0) this.#maybe_dirty_effects.add(effect);
|
|
1576
|
-
update_effect(effect);
|
|
1577
|
-
}
|
|
1578
|
-
var child = effect.first;
|
|
1579
|
-
if (child !== null) {
|
|
1580
|
-
effect = child;
|
|
1581
|
-
continue;
|
|
1582
|
-
}
|
|
1583
|
-
}
|
|
1584
|
-
while (effect !== null) {
|
|
1585
|
-
var next = effect.next;
|
|
1586
|
-
if (next !== null) {
|
|
1587
|
-
effect = next;
|
|
1588
|
-
break;
|
|
1589
|
-
}
|
|
1590
|
-
effect = effect.parent;
|
|
1807
|
+
var onerror = this.#props.onerror;
|
|
1808
|
+
let failed = this.#props.failed;
|
|
1809
|
+
var did_reset = false;
|
|
1810
|
+
var calling_on_error = false;
|
|
1811
|
+
const reset = () => {
|
|
1812
|
+
if (did_reset) {
|
|
1813
|
+
svelte_boundary_reset_noop();
|
|
1814
|
+
return;
|
|
1591
1815
|
}
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
if ((source.f & 8388608) === 0) {
|
|
1610
|
-
this.current.set(source, [value, is_derived]);
|
|
1611
|
-
batch_values?.set(source, value);
|
|
1612
|
-
}
|
|
1613
|
-
if (!this.is_fork) source.v = value;
|
|
1614
|
-
}
|
|
1615
|
-
activate() {
|
|
1616
|
-
current_batch = this;
|
|
1617
|
-
}
|
|
1618
|
-
deactivate() {
|
|
1619
|
-
current_batch = null;
|
|
1620
|
-
batch_values = null;
|
|
1621
|
-
}
|
|
1622
|
-
flush() {
|
|
1623
|
-
try {
|
|
1624
|
-
is_processing = true;
|
|
1625
|
-
current_batch = this;
|
|
1626
|
-
this.#process();
|
|
1627
|
-
} finally {
|
|
1628
|
-
flush_count = 0;
|
|
1629
|
-
last_scheduled_effect = null;
|
|
1630
|
-
collected_effects = null;
|
|
1631
|
-
legacy_updates = null;
|
|
1632
|
-
is_processing = false;
|
|
1633
|
-
current_batch = null;
|
|
1634
|
-
batch_values = null;
|
|
1635
|
-
old_values.clear();
|
|
1636
|
-
}
|
|
1637
|
-
}
|
|
1638
|
-
discard() {
|
|
1639
|
-
for (const fn of this.#discard_callbacks) fn(this);
|
|
1640
|
-
this.#discard_callbacks.clear();
|
|
1641
|
-
this.#fork_commit_callbacks.clear();
|
|
1642
|
-
batches.delete(this);
|
|
1643
|
-
}
|
|
1644
|
-
/**
|
|
1645
|
-
* @param {Effect} effect
|
|
1646
|
-
*/
|
|
1647
|
-
register_created_effect(effect) {
|
|
1648
|
-
this.#new_effects.push(effect);
|
|
1649
|
-
}
|
|
1650
|
-
#commit() {
|
|
1651
|
-
for (const batch of batches) {
|
|
1652
|
-
var is_earlier = batch.id < this.id;
|
|
1653
|
-
/** @type {Source[]} */
|
|
1654
|
-
var sources = [];
|
|
1655
|
-
for (const [source, [value, is_derived]] of this.current) {
|
|
1656
|
-
if (batch.current.has(source)) {
|
|
1657
|
-
var batch_value = batch.current.get(source)[0];
|
|
1658
|
-
if (is_earlier && value !== batch_value) batch.current.set(source, [value, is_derived]);
|
|
1659
|
-
else continue;
|
|
1660
|
-
}
|
|
1661
|
-
sources.push(source);
|
|
1816
|
+
did_reset = true;
|
|
1817
|
+
if (calling_on_error) svelte_boundary_reset_onerror();
|
|
1818
|
+
if (this.#failed_effect !== null) pause_effect(this.#failed_effect, () => {
|
|
1819
|
+
this.#failed_effect = null;
|
|
1820
|
+
});
|
|
1821
|
+
this.#run(() => {
|
|
1822
|
+
this.#render();
|
|
1823
|
+
});
|
|
1824
|
+
};
|
|
1825
|
+
/** @param {unknown} transformed_error */
|
|
1826
|
+
const handle_error_result = (transformed_error) => {
|
|
1827
|
+
try {
|
|
1828
|
+
calling_on_error = true;
|
|
1829
|
+
onerror?.(transformed_error, reset);
|
|
1830
|
+
calling_on_error = false;
|
|
1831
|
+
} catch (error) {
|
|
1832
|
+
invoke_error_boundary(error, this.#effect && this.#effect.parent);
|
|
1662
1833
|
}
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
/** @type {Map<Reaction, boolean>} */
|
|
1675
|
-
var checked = /* @__PURE__ */ new Map();
|
|
1676
|
-
for (var source of sources) mark_effects(source, others, marked, checked);
|
|
1677
|
-
checked = /* @__PURE__ */ new Map();
|
|
1678
|
-
var current_unequal = [...batch.current.keys()].filter((c) => this.current.has(c) ? this.current.get(c)[0] !== c : true);
|
|
1679
|
-
for (const effect of this.#new_effects) if ((effect.f & 155648) === 0 && depends_on(effect, current_unequal, checked)) if ((effect.f & 4194320) !== 0) {
|
|
1680
|
-
set_signal_status(effect, DIRTY);
|
|
1681
|
-
batch.schedule(effect);
|
|
1682
|
-
} else batch.#dirty_effects.add(effect);
|
|
1683
|
-
if (batch.#roots.length > 0) {
|
|
1684
|
-
batch.apply();
|
|
1685
|
-
for (var root of batch.#roots) batch.#traverse(root, [], []);
|
|
1686
|
-
batch.#roots = [];
|
|
1834
|
+
if (failed) this.#failed_effect = this.#run(() => {
|
|
1835
|
+
try {
|
|
1836
|
+
return branch(() => {
|
|
1837
|
+
var effect = active_effect;
|
|
1838
|
+
effect.b = this;
|
|
1839
|
+
effect.f |= 128;
|
|
1840
|
+
failed(this.#anchor, () => transformed_error, () => reset);
|
|
1841
|
+
});
|
|
1842
|
+
} catch (error) {
|
|
1843
|
+
invoke_error_boundary(error, this.#effect.parent);
|
|
1844
|
+
return null;
|
|
1687
1845
|
}
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
}
|
|
1691
|
-
for (const batch of batches) if (batch.#blockers.has(this)) {
|
|
1692
|
-
batch.#blockers.delete(this);
|
|
1693
|
-
if (batch.#blockers.size === 0 && !batch.#is_deferred()) {
|
|
1694
|
-
batch.activate();
|
|
1695
|
-
batch.#process();
|
|
1696
|
-
}
|
|
1697
|
-
}
|
|
1698
|
-
}
|
|
1699
|
-
/**
|
|
1700
|
-
* @param {boolean} blocking
|
|
1701
|
-
* @param {Effect} effect
|
|
1702
|
-
*/
|
|
1703
|
-
increment(blocking, effect) {
|
|
1704
|
-
let pending_count = this.#pending.get(effect) ?? 0;
|
|
1705
|
-
this.#pending.set(effect, pending_count + 1);
|
|
1706
|
-
if (blocking) {
|
|
1707
|
-
let blocking_pending_count = this.#blocking_pending.get(effect) ?? 0;
|
|
1708
|
-
this.#blocking_pending.set(effect, blocking_pending_count + 1);
|
|
1709
|
-
}
|
|
1710
|
-
}
|
|
1711
|
-
/**
|
|
1712
|
-
* @param {boolean} blocking
|
|
1713
|
-
* @param {Effect} effect
|
|
1714
|
-
* @param {boolean} skip - whether to skip updates (because this is triggered by a stale reaction)
|
|
1715
|
-
*/
|
|
1716
|
-
decrement(blocking, effect, skip) {
|
|
1717
|
-
let pending_count = this.#pending.get(effect) ?? 0;
|
|
1718
|
-
if (pending_count === 1) this.#pending.delete(effect);
|
|
1719
|
-
else this.#pending.set(effect, pending_count - 1);
|
|
1720
|
-
if (blocking) {
|
|
1721
|
-
let blocking_pending_count = this.#blocking_pending.get(effect) ?? 0;
|
|
1722
|
-
if (blocking_pending_count === 1) this.#blocking_pending.delete(effect);
|
|
1723
|
-
else this.#blocking_pending.set(effect, blocking_pending_count - 1);
|
|
1724
|
-
}
|
|
1725
|
-
if (this.#decrement_queued || skip) return;
|
|
1726
|
-
this.#decrement_queued = true;
|
|
1846
|
+
});
|
|
1847
|
+
};
|
|
1727
1848
|
queue_micro_task(() => {
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
*/
|
|
1736
|
-
transfer_effects(dirty_effects, maybe_dirty_effects) {
|
|
1737
|
-
for (const e of dirty_effects) this.#dirty_effects.add(e);
|
|
1738
|
-
for (const e of maybe_dirty_effects) this.#maybe_dirty_effects.add(e);
|
|
1739
|
-
dirty_effects.clear();
|
|
1740
|
-
maybe_dirty_effects.clear();
|
|
1741
|
-
}
|
|
1742
|
-
/** @param {(batch: Batch) => void} fn */
|
|
1743
|
-
oncommit(fn) {
|
|
1744
|
-
this.#commit_callbacks.add(fn);
|
|
1745
|
-
}
|
|
1746
|
-
/** @param {(batch: Batch) => void} fn */
|
|
1747
|
-
ondiscard(fn) {
|
|
1748
|
-
this.#discard_callbacks.add(fn);
|
|
1749
|
-
}
|
|
1750
|
-
/** @param {(batch: Batch) => void} fn */
|
|
1751
|
-
on_fork_commit(fn) {
|
|
1752
|
-
this.#fork_commit_callbacks.add(fn);
|
|
1753
|
-
}
|
|
1754
|
-
run_fork_commit_callbacks() {
|
|
1755
|
-
for (const fn of this.#fork_commit_callbacks) fn(this);
|
|
1756
|
-
this.#fork_commit_callbacks.clear();
|
|
1757
|
-
}
|
|
1758
|
-
settled() {
|
|
1759
|
-
return (this.#deferred ??= deferred()).promise;
|
|
1760
|
-
}
|
|
1761
|
-
static ensure() {
|
|
1762
|
-
if (current_batch === null) {
|
|
1763
|
-
const batch = current_batch = new Batch();
|
|
1764
|
-
if (!is_processing) {
|
|
1765
|
-
batches.add(current_batch);
|
|
1766
|
-
if (!is_flushing_sync) queue_micro_task(() => {
|
|
1767
|
-
if (current_batch !== batch) return;
|
|
1768
|
-
batch.flush();
|
|
1769
|
-
});
|
|
1770
|
-
}
|
|
1771
|
-
}
|
|
1772
|
-
return current_batch;
|
|
1773
|
-
}
|
|
1774
|
-
apply() {
|
|
1775
|
-
batch_values = null;
|
|
1776
|
-
return;
|
|
1777
|
-
var intersects, differs;
|
|
1778
|
-
}
|
|
1779
|
-
/**
|
|
1780
|
-
*
|
|
1781
|
-
* @param {Effect} effect
|
|
1782
|
-
*/
|
|
1783
|
-
schedule(effect) {
|
|
1784
|
-
last_scheduled_effect = effect;
|
|
1785
|
-
if (effect.b?.is_pending && (effect.f & 16777228) !== 0 && (effect.f & 32768) === 0) {
|
|
1786
|
-
effect.b.defer_effect(effect);
|
|
1787
|
-
return;
|
|
1788
|
-
}
|
|
1789
|
-
var e = effect;
|
|
1790
|
-
while (e.parent !== null) {
|
|
1791
|
-
e = e.parent;
|
|
1792
|
-
var flags = e.f;
|
|
1793
|
-
if (collected_effects !== null && e === active_effect) {
|
|
1794
|
-
if ((active_reaction === null || (active_reaction.f & 2) === 0) && !legacy_is_updating_store) return;
|
|
1795
|
-
}
|
|
1796
|
-
if ((flags & 96) !== 0) {
|
|
1797
|
-
if ((flags & 1024) === 0) return;
|
|
1798
|
-
e.f ^= CLEAN;
|
|
1849
|
+
/** @type {unknown} */
|
|
1850
|
+
var result;
|
|
1851
|
+
try {
|
|
1852
|
+
result = this.transform_error(error);
|
|
1853
|
+
} catch (e) {
|
|
1854
|
+
invoke_error_boundary(e, this.#effect && this.#effect.parent);
|
|
1855
|
+
return;
|
|
1799
1856
|
}
|
|
1800
|
-
|
|
1801
|
-
|
|
1857
|
+
if (result !== null && typeof result === "object" && typeof result.then === "function")
|
|
1858
|
+
/** @type {any} */ result.then(
|
|
1859
|
+
handle_error_result,
|
|
1860
|
+
/** @param {unknown} e */
|
|
1861
|
+
(e) => invoke_error_boundary(e, this.#effect && this.#effect.parent)
|
|
1862
|
+
);
|
|
1863
|
+
else handle_error_result(result);
|
|
1864
|
+
});
|
|
1802
1865
|
}
|
|
1803
1866
|
};
|
|
1867
|
+
var OBSOLETE = Symbol("obsolete");
|
|
1804
1868
|
/**
|
|
1805
|
-
*
|
|
1806
|
-
* Returns void if no callback is provided, otherwise returns the result of calling the callback.
|
|
1807
|
-
* @template [T=void]
|
|
1808
|
-
* @param {(() => T) | undefined} [fn]
|
|
1809
|
-
* @returns {T}
|
|
1810
|
-
*/
|
|
1811
|
-
function flushSync(fn) {
|
|
1812
|
-
var was_flushing_sync = is_flushing_sync;
|
|
1813
|
-
is_flushing_sync = true;
|
|
1814
|
-
try {
|
|
1815
|
-
var result;
|
|
1816
|
-
if (fn) {
|
|
1817
|
-
if (current_batch !== null && !current_batch.is_fork) current_batch.flush();
|
|
1818
|
-
result = fn();
|
|
1819
|
-
}
|
|
1820
|
-
while (true) {
|
|
1821
|
-
flush_tasks();
|
|
1822
|
-
if (current_batch === null) return result;
|
|
1823
|
-
current_batch.flush();
|
|
1824
|
-
}
|
|
1825
|
-
} finally {
|
|
1826
|
-
is_flushing_sync = was_flushing_sync;
|
|
1827
|
-
}
|
|
1828
|
-
}
|
|
1829
|
-
function infinite_loop_guard() {
|
|
1830
|
-
try {
|
|
1831
|
-
effect_update_depth_exceeded();
|
|
1832
|
-
} catch (error) {
|
|
1833
|
-
invoke_error_boundary(error, last_scheduled_effect);
|
|
1834
|
-
}
|
|
1835
|
-
}
|
|
1836
|
-
/** @type {Set<Effect> | null} */
|
|
1837
|
-
var eager_block_effects = null;
|
|
1838
|
-
/**
|
|
1839
|
-
* @param {Array<Effect>} effects
|
|
1869
|
+
* @param {Derived} derived
|
|
1840
1870
|
* @returns {void}
|
|
1841
1871
|
*/
|
|
1842
|
-
function
|
|
1843
|
-
var
|
|
1844
|
-
if (
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
var effect = effects[i++];
|
|
1848
|
-
if ((effect.f & 24576) === 0 && is_dirty(effect)) {
|
|
1849
|
-
eager_block_effects = /* @__PURE__ */ new Set();
|
|
1850
|
-
update_effect(effect);
|
|
1851
|
-
if (effect.deps === null && effect.first === null && effect.nodes === null && effect.teardown === null && effect.ac === null) unlink_effect(effect);
|
|
1852
|
-
if (eager_block_effects?.size > 0) {
|
|
1853
|
-
old_values.clear();
|
|
1854
|
-
for (const e of eager_block_effects) {
|
|
1855
|
-
if ((e.f & 24576) !== 0) continue;
|
|
1856
|
-
/** @type {Effect[]} */
|
|
1857
|
-
const ordered_effects = [e];
|
|
1858
|
-
let ancestor = e.parent;
|
|
1859
|
-
while (ancestor !== null) {
|
|
1860
|
-
if (eager_block_effects.has(ancestor)) {
|
|
1861
|
-
eager_block_effects.delete(ancestor);
|
|
1862
|
-
ordered_effects.push(ancestor);
|
|
1863
|
-
}
|
|
1864
|
-
ancestor = ancestor.parent;
|
|
1865
|
-
}
|
|
1866
|
-
for (let j = ordered_effects.length - 1; j >= 0; j--) {
|
|
1867
|
-
const e = ordered_effects[j];
|
|
1868
|
-
if ((e.f & 24576) !== 0) continue;
|
|
1869
|
-
update_effect(e);
|
|
1870
|
-
}
|
|
1871
|
-
}
|
|
1872
|
-
eager_block_effects.clear();
|
|
1873
|
-
}
|
|
1874
|
-
}
|
|
1872
|
+
function destroy_derived_effects(derived) {
|
|
1873
|
+
var effects = derived.effects;
|
|
1874
|
+
if (effects !== null) {
|
|
1875
|
+
derived.effects = null;
|
|
1876
|
+
for (var i = 0; i < effects.length; i += 1) destroy_effect(effects[i]);
|
|
1875
1877
|
}
|
|
1876
|
-
eager_block_effects = null;
|
|
1877
1878
|
}
|
|
1878
1879
|
/**
|
|
1879
|
-
*
|
|
1880
|
-
*
|
|
1881
|
-
*
|
|
1882
|
-
* @param {Value} value
|
|
1883
|
-
* @param {Source[]} sources
|
|
1884
|
-
* @param {Set<Value>} marked
|
|
1885
|
-
* @param {Map<Reaction, boolean>} checked
|
|
1880
|
+
* @template T
|
|
1881
|
+
* @param {Derived} derived
|
|
1882
|
+
* @returns {T}
|
|
1886
1883
|
*/
|
|
1887
|
-
function
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
set_signal_status(reaction, DIRTY);
|
|
1895
|
-
schedule_effect(reaction);
|
|
1896
|
-
}
|
|
1884
|
+
function execute_derived(derived) {
|
|
1885
|
+
var value;
|
|
1886
|
+
var prev_active_effect = active_effect;
|
|
1887
|
+
var parent = derived.parent;
|
|
1888
|
+
if (!is_destroying_effect && parent !== null && derived.v !== UNINITIALIZED && (parent.f & 24576) !== 0) {
|
|
1889
|
+
derived_inert();
|
|
1890
|
+
return derived.v;
|
|
1897
1891
|
}
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
const depends = checked.get(reaction);
|
|
1906
|
-
if (depends !== void 0) return depends;
|
|
1907
|
-
if (reaction.deps !== null) for (const dep of reaction.deps) {
|
|
1908
|
-
if (includes.call(sources, dep)) return true;
|
|
1909
|
-
if ((dep.f & 2) !== 0 && depends_on(dep, sources, checked)) {
|
|
1910
|
-
checked.set(dep, true);
|
|
1911
|
-
return true;
|
|
1912
|
-
}
|
|
1892
|
+
set_active_effect(parent);
|
|
1893
|
+
try {
|
|
1894
|
+
derived.f &= ~WAS_MARKED;
|
|
1895
|
+
destroy_derived_effects(derived);
|
|
1896
|
+
value = update_reaction(derived);
|
|
1897
|
+
} finally {
|
|
1898
|
+
set_active_effect(prev_active_effect);
|
|
1913
1899
|
}
|
|
1914
|
-
|
|
1915
|
-
return false;
|
|
1900
|
+
return value;
|
|
1916
1901
|
}
|
|
1917
1902
|
/**
|
|
1918
|
-
* @param {
|
|
1903
|
+
* @param {Derived} derived
|
|
1919
1904
|
* @returns {void}
|
|
1920
1905
|
*/
|
|
1921
|
-
function
|
|
1922
|
-
|
|
1906
|
+
function update_derived(derived) {
|
|
1907
|
+
var value = execute_derived(derived);
|
|
1908
|
+
if (!derived.equals(value)) {
|
|
1909
|
+
derived.wv = increment_write_version();
|
|
1910
|
+
if (!current_batch?.is_fork || derived.deps === null) {
|
|
1911
|
+
if (current_batch !== null) {
|
|
1912
|
+
current_batch.capture(derived, value, true);
|
|
1913
|
+
previous_batch?.capture(derived, value, true);
|
|
1914
|
+
} else derived.v = value;
|
|
1915
|
+
if (derived.deps === null) {
|
|
1916
|
+
set_signal_status(derived, CLEAN);
|
|
1917
|
+
return;
|
|
1918
|
+
}
|
|
1919
|
+
}
|
|
1920
|
+
}
|
|
1921
|
+
if (is_destroying_effect) return;
|
|
1922
|
+
if (batch_values !== null) {
|
|
1923
|
+
if (effect_tracking() || current_batch?.is_fork) batch_values.set(derived, value);
|
|
1924
|
+
} else update_derived_status(derived);
|
|
1923
1925
|
}
|
|
1924
1926
|
/**
|
|
1925
|
-
*
|
|
1926
|
-
* they can be correctly rescheduled later. Tracks dirty and maybe_dirty
|
|
1927
|
-
* effects so they can be rescheduled if the branch survives.
|
|
1928
|
-
* @param {Effect} effect
|
|
1929
|
-
* @param {{ d: Effect[], m: Effect[] }} tracked
|
|
1927
|
+
* @param {Derived} derived
|
|
1930
1928
|
*/
|
|
1931
|
-
function
|
|
1932
|
-
if (
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
e
|
|
1929
|
+
function freeze_derived_effects(derived) {
|
|
1930
|
+
if (derived.effects === null) return;
|
|
1931
|
+
for (const e of derived.effects) if (e.teardown || e.ac) {
|
|
1932
|
+
e.teardown?.();
|
|
1933
|
+
e.ac?.abort(STALE_REACTION);
|
|
1934
|
+
if (e.fn !== null) e.teardown = noop;
|
|
1935
|
+
e.ac = null;
|
|
1936
|
+
remove_reactions(e, 0);
|
|
1937
|
+
destroy_effect_children(e);
|
|
1940
1938
|
}
|
|
1941
1939
|
}
|
|
1942
1940
|
/**
|
|
1943
|
-
*
|
|
1944
|
-
* @param {Effect} effect
|
|
1941
|
+
* @param {Derived} derived
|
|
1945
1942
|
*/
|
|
1946
|
-
function
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
while (e !== null) {
|
|
1950
|
-
reset_all(e);
|
|
1951
|
-
e = e.next;
|
|
1952
|
-
}
|
|
1943
|
+
function unfreeze_derived_effects(derived) {
|
|
1944
|
+
if (derived.effects === null) return;
|
|
1945
|
+
for (const e of derived.effects) if (e.teardown && e.fn !== null) update_effect(e);
|
|
1953
1946
|
}
|
|
1947
|
+
/** @import { Fork } from 'svelte' */
|
|
1948
|
+
/** @import { Derived, Effect, Reaction, Source, Value } from '#client' */
|
|
1949
|
+
/** @type {Batch | null} */
|
|
1950
|
+
var first_batch = null;
|
|
1951
|
+
/** @type {Batch | null} */
|
|
1952
|
+
var last_batch = null;
|
|
1953
|
+
/** @type {Batch | null} */
|
|
1954
|
+
var current_batch = null;
|
|
1954
1955
|
/**
|
|
1955
|
-
*
|
|
1956
|
-
*
|
|
1957
|
-
*
|
|
1958
|
-
* If `subscribe` is called inside an effect (including indirectly, for example inside a getter),
|
|
1959
|
-
* the `start` callback will be called with an `update` function. Whenever `update` is called, the effect re-runs.
|
|
1960
|
-
*
|
|
1961
|
-
* If `start` returns a cleanup function, it will be called when the effect is destroyed.
|
|
1962
|
-
*
|
|
1963
|
-
* If `subscribe` is called in multiple effects, `start` will only be called once as long as the effects
|
|
1964
|
-
* are active, and the returned teardown function will only be called when all effects are destroyed.
|
|
1965
|
-
*
|
|
1966
|
-
* It's best understood with an example. Here's an implementation of [`MediaQuery`](https://svelte.dev/docs/svelte/svelte-reactivity#MediaQuery):
|
|
1967
|
-
*
|
|
1968
|
-
* ```js
|
|
1969
|
-
* import { createSubscriber } from 'svelte/reactivity';
|
|
1970
|
-
* import { on } from 'svelte/events';
|
|
1971
|
-
*
|
|
1972
|
-
* export class MediaQuery {
|
|
1973
|
-
* #query;
|
|
1974
|
-
* #subscribe;
|
|
1975
|
-
*
|
|
1976
|
-
* constructor(query) {
|
|
1977
|
-
* this.#query = window.matchMedia(`(${query})`);
|
|
1978
|
-
*
|
|
1979
|
-
* this.#subscribe = createSubscriber((update) => {
|
|
1980
|
-
* // when the `change` event occurs, re-run any effects that read `this.current`
|
|
1981
|
-
* const off = on(this.#query, 'change', update);
|
|
1982
|
-
*
|
|
1983
|
-
* // stop listening when all the effects are destroyed
|
|
1984
|
-
* return () => off();
|
|
1985
|
-
* });
|
|
1986
|
-
* }
|
|
1987
|
-
*
|
|
1988
|
-
* get current() {
|
|
1989
|
-
* // This makes the getter reactive, if read in an effect
|
|
1990
|
-
* this.#subscribe();
|
|
1991
|
-
*
|
|
1992
|
-
* // Return the current state of the query, whether or not we're in an effect
|
|
1993
|
-
* return this.#query.matches;
|
|
1994
|
-
* }
|
|
1995
|
-
* }
|
|
1996
|
-
* ```
|
|
1997
|
-
* @param {(update: () => void) => (() => void) | void} start
|
|
1998
|
-
* @since 5.7.0
|
|
1956
|
+
* This is needed to avoid overwriting inputs
|
|
1957
|
+
* @type {Batch | null}
|
|
1999
1958
|
*/
|
|
2000
|
-
|
|
2001
|
-
let subscribers = 0;
|
|
2002
|
-
let version = source(0);
|
|
2003
|
-
/** @type {(() => void) | void} */
|
|
2004
|
-
let stop;
|
|
2005
|
-
return () => {
|
|
2006
|
-
if (effect_tracking()) {
|
|
2007
|
-
get(version);
|
|
2008
|
-
render_effect(() => {
|
|
2009
|
-
if (subscribers === 0) stop = untrack(() => start(() => increment(version)));
|
|
2010
|
-
subscribers += 1;
|
|
2011
|
-
return () => {
|
|
2012
|
-
queue_micro_task(() => {
|
|
2013
|
-
subscribers -= 1;
|
|
2014
|
-
if (subscribers === 0) {
|
|
2015
|
-
stop?.();
|
|
2016
|
-
stop = void 0;
|
|
2017
|
-
increment(version);
|
|
2018
|
-
}
|
|
2019
|
-
});
|
|
2020
|
-
};
|
|
2021
|
-
});
|
|
2022
|
-
}
|
|
2023
|
-
};
|
|
2024
|
-
}
|
|
2025
|
-
/** @import { Effect, Source, TemplateNode, } from '#client' */
|
|
1959
|
+
var previous_batch = null;
|
|
2026
1960
|
/**
|
|
2027
|
-
*
|
|
2028
|
-
*
|
|
2029
|
-
*
|
|
2030
|
-
*
|
|
2031
|
-
* }} BoundaryProps
|
|
1961
|
+
* When time travelling (i.e. working in one batch, while other batches
|
|
1962
|
+
* still have ongoing work), we ignore the real values of affected
|
|
1963
|
+
* signals in favour of their values within the batch
|
|
1964
|
+
* @type {Map<Value, any> | null}
|
|
2032
1965
|
*/
|
|
2033
|
-
var
|
|
1966
|
+
var batch_values = null;
|
|
1967
|
+
/** @type {Effect | null} */
|
|
1968
|
+
var last_scheduled_effect = null;
|
|
1969
|
+
var is_flushing_sync = false;
|
|
1970
|
+
var is_processing = false;
|
|
2034
1971
|
/**
|
|
2035
|
-
*
|
|
2036
|
-
*
|
|
2037
|
-
*
|
|
2038
|
-
* @
|
|
2039
|
-
* @returns {void}
|
|
1972
|
+
* During traversal, this is an array. Newly created effects are (if not immediately
|
|
1973
|
+
* executed) pushed to this array, rather than going through the scheduling
|
|
1974
|
+
* rigamarole that would cause another turn of the flush loop.
|
|
1975
|
+
* @type {Effect[] | null}
|
|
2040
1976
|
*/
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
1977
|
+
var collected_effects = null;
|
|
1978
|
+
/**
|
|
1979
|
+
* An array of effects that are marked during traversal as a result of a `set`
|
|
1980
|
+
* (not `internal_set`) call. These will be added to the next batch and
|
|
1981
|
+
* trigger another `batch.process()`
|
|
1982
|
+
* @type {Effect[] | null}
|
|
1983
|
+
* @deprecated when we get rid of legacy mode and stores, we can get rid of this
|
|
1984
|
+
*/
|
|
1985
|
+
var legacy_updates = null;
|
|
1986
|
+
var flush_count = 0;
|
|
1987
|
+
var uid = 1;
|
|
1988
|
+
var Batch = class Batch {
|
|
1989
|
+
id = uid++;
|
|
1990
|
+
/** True as soon as `#process` was called */
|
|
1991
|
+
#started = false;
|
|
1992
|
+
linked = true;
|
|
1993
|
+
/** @type {Batch | null} */
|
|
1994
|
+
#prev = null;
|
|
1995
|
+
/** @type {Batch | null} */
|
|
1996
|
+
#next = null;
|
|
1997
|
+
/** @type {Map<Effect, ReturnType<typeof deferred<any>>>} */
|
|
1998
|
+
async_deriveds = /* @__PURE__ */ new Map();
|
|
2048
1999
|
/**
|
|
2049
|
-
*
|
|
2050
|
-
*
|
|
2051
|
-
*
|
|
2000
|
+
* The current values of any signals that are updated in this batch.
|
|
2001
|
+
* Tuple format: [value, is_derived] (note: is_derived is false for deriveds, too, if they were overridden via assignment)
|
|
2002
|
+
* They keys of this map are identical to `this.#previous`
|
|
2003
|
+
* @type {Map<Value, [any, boolean]>}
|
|
2004
|
+
*/
|
|
2005
|
+
current = /* @__PURE__ */ new Map();
|
|
2006
|
+
/**
|
|
2007
|
+
* The values of any signals (sources and deriveds) that are updated in this batch _before_ those updates took place.
|
|
2008
|
+
* They keys of this map are identical to `this.#current`
|
|
2009
|
+
* @type {Map<Value, any>}
|
|
2010
|
+
*/
|
|
2011
|
+
previous = /* @__PURE__ */ new Map();
|
|
2012
|
+
/**
|
|
2013
|
+
* When the batch is committed (and the DOM is updated), we need to remove old branches
|
|
2014
|
+
* and append new ones by calling the functions added inside (if/each/key/etc) blocks
|
|
2015
|
+
* @type {Set<(batch: Batch) => void>}
|
|
2016
|
+
*/
|
|
2017
|
+
#commit_callbacks = /* @__PURE__ */ new Set();
|
|
2018
|
+
/**
|
|
2019
|
+
* If a fork is discarded, we need to destroy any effects that are no longer needed
|
|
2020
|
+
* @type {Set<(batch: Batch) => void>}
|
|
2021
|
+
*/
|
|
2022
|
+
#discard_callbacks = /* @__PURE__ */ new Set();
|
|
2023
|
+
/**
|
|
2024
|
+
* The number of async effects that are currently in flight
|
|
2025
|
+
*/
|
|
2026
|
+
#pending = 0;
|
|
2027
|
+
/**
|
|
2028
|
+
* Async effects that are currently in flight, _not_ inside a pending boundary
|
|
2029
|
+
* @type {Map<Effect, number>}
|
|
2030
|
+
*/
|
|
2031
|
+
#blocking_pending = /* @__PURE__ */ new Map();
|
|
2032
|
+
/**
|
|
2033
|
+
* A deferred that resolves when the batch is committed, used with `settled()`
|
|
2034
|
+
* TODO replace with Promise.withResolvers once supported widely enough
|
|
2035
|
+
* @type {{ promise: Promise<void>, resolve: (value?: any) => void, reject: (reason: unknown) => void } | null}
|
|
2036
|
+
*/
|
|
2037
|
+
#deferred = null;
|
|
2038
|
+
/**
|
|
2039
|
+
* The root effects that need to be flushed
|
|
2040
|
+
* @type {Effect[]}
|
|
2041
|
+
*/
|
|
2042
|
+
#roots = [];
|
|
2043
|
+
/**
|
|
2044
|
+
* Effects created while this batch was active.
|
|
2045
|
+
* @type {Effect[]}
|
|
2046
|
+
*/
|
|
2047
|
+
#new_effects = [];
|
|
2048
|
+
/**
|
|
2049
|
+
* Deferred effects (which run after async work has completed) that are DIRTY
|
|
2050
|
+
* @type {Set<Effect>}
|
|
2052
2051
|
*/
|
|
2053
|
-
transform_error;
|
|
2054
|
-
/** @type {TemplateNode} */
|
|
2055
|
-
#anchor;
|
|
2056
|
-
/** @type {TemplateNode | null} */
|
|
2057
|
-
#hydrate_open = hydrating ? hydrate_node : null;
|
|
2058
|
-
/** @type {BoundaryProps} */
|
|
2059
|
-
#props;
|
|
2060
|
-
/** @type {((anchor: Node) => void)} */
|
|
2061
|
-
#children;
|
|
2062
|
-
/** @type {Effect} */
|
|
2063
|
-
#effect;
|
|
2064
|
-
/** @type {Effect | null} */
|
|
2065
|
-
#main_effect = null;
|
|
2066
|
-
/** @type {Effect | null} */
|
|
2067
|
-
#pending_effect = null;
|
|
2068
|
-
/** @type {Effect | null} */
|
|
2069
|
-
#failed_effect = null;
|
|
2070
|
-
/** @type {DocumentFragment | null} */
|
|
2071
|
-
#offscreen_fragment = null;
|
|
2072
|
-
#local_pending_count = 0;
|
|
2073
|
-
#pending_count = 0;
|
|
2074
|
-
#pending_count_update_queued = false;
|
|
2075
|
-
/** @type {Set<Effect>} */
|
|
2076
2052
|
#dirty_effects = /* @__PURE__ */ new Set();
|
|
2077
|
-
/**
|
|
2053
|
+
/**
|
|
2054
|
+
* Deferred effects that are MAYBE_DIRTY
|
|
2055
|
+
* @type {Set<Effect>}
|
|
2056
|
+
*/
|
|
2078
2057
|
#maybe_dirty_effects = /* @__PURE__ */ new Set();
|
|
2079
2058
|
/**
|
|
2080
|
-
* A
|
|
2081
|
-
*
|
|
2082
|
-
*
|
|
2083
|
-
*
|
|
2084
|
-
* @type {
|
|
2059
|
+
* A map of branches that still exist, but will be destroyed when this batch
|
|
2060
|
+
* is committed — we skip over these during `process`.
|
|
2061
|
+
* The value contains child effects that were dirty/maybe_dirty before being reset,
|
|
2062
|
+
* so they can be rescheduled if the branch survives.
|
|
2063
|
+
* @type {Map<Effect, { d: Effect[], m: Effect[] }>}
|
|
2064
|
+
*/
|
|
2065
|
+
#skipped_branches = /* @__PURE__ */ new Map();
|
|
2066
|
+
/**
|
|
2067
|
+
* Inverse of #skipped_branches which we need to tell prior batches to unskip them when committing
|
|
2068
|
+
* @type {Set<Effect>}
|
|
2069
|
+
*/
|
|
2070
|
+
#unskipped_branches = /* @__PURE__ */ new Set();
|
|
2071
|
+
is_fork = false;
|
|
2072
|
+
#decrement_queued = false;
|
|
2073
|
+
constructor() {
|
|
2074
|
+
if (last_batch === null) first_batch = last_batch = this;
|
|
2075
|
+
else {
|
|
2076
|
+
last_batch.#next = this;
|
|
2077
|
+
this.#prev = last_batch;
|
|
2078
|
+
}
|
|
2079
|
+
last_batch = this;
|
|
2080
|
+
}
|
|
2081
|
+
#is_deferred() {
|
|
2082
|
+
if (this.is_fork) return true;
|
|
2083
|
+
for (const effect of this.#blocking_pending.keys()) {
|
|
2084
|
+
var e = effect;
|
|
2085
|
+
var skipped = false;
|
|
2086
|
+
while (e.parent !== null) {
|
|
2087
|
+
if (this.#skipped_branches.has(e)) {
|
|
2088
|
+
skipped = true;
|
|
2089
|
+
break;
|
|
2090
|
+
}
|
|
2091
|
+
e = e.parent;
|
|
2092
|
+
}
|
|
2093
|
+
if (!skipped) return true;
|
|
2094
|
+
}
|
|
2095
|
+
return false;
|
|
2096
|
+
}
|
|
2097
|
+
/**
|
|
2098
|
+
* Add an effect to the #skipped_branches map and reset its children
|
|
2099
|
+
* @param {Effect} effect
|
|
2085
2100
|
*/
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
}
|
|
2101
|
+
skip_effect(effect) {
|
|
2102
|
+
if (!this.#skipped_branches.has(effect)) this.#skipped_branches.set(effect, {
|
|
2103
|
+
d: [],
|
|
2104
|
+
m: []
|
|
2105
|
+
});
|
|
2106
|
+
this.#unskipped_branches.delete(effect);
|
|
2107
|
+
}
|
|
2093
2108
|
/**
|
|
2094
|
-
*
|
|
2095
|
-
*
|
|
2096
|
-
* @param {
|
|
2097
|
-
* @param {(
|
|
2109
|
+
* Remove an effect from the #skipped_branches map and reschedule
|
|
2110
|
+
* any tracked dirty/maybe_dirty child effects
|
|
2111
|
+
* @param {Effect} effect
|
|
2112
|
+
* @param {(e: Effect) => void} callback
|
|
2098
2113
|
*/
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
var
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
hydrate_next();
|
|
2114
|
-
const server_rendered_pending = comment.data === "[!";
|
|
2115
|
-
if (comment.data.startsWith("[?")) {
|
|
2116
|
-
const serialized_error = JSON.parse(comment.data.slice(2));
|
|
2117
|
-
this.#hydrate_failed_content(serialized_error);
|
|
2118
|
-
} else if (server_rendered_pending) this.#hydrate_pending_content();
|
|
2119
|
-
else this.#hydrate_resolved_content();
|
|
2120
|
-
} else this.#render();
|
|
2121
|
-
}, flags);
|
|
2122
|
-
if (hydrating) this.#anchor = hydrate_node;
|
|
2114
|
+
unskip_effect(effect, callback = (e) => this.schedule(e)) {
|
|
2115
|
+
var tracked = this.#skipped_branches.get(effect);
|
|
2116
|
+
if (tracked) {
|
|
2117
|
+
this.#skipped_branches.delete(effect);
|
|
2118
|
+
for (var e of tracked.d) {
|
|
2119
|
+
set_signal_status(e, DIRTY);
|
|
2120
|
+
callback(e);
|
|
2121
|
+
}
|
|
2122
|
+
for (e of tracked.m) {
|
|
2123
|
+
set_signal_status(e, MAYBE_DIRTY);
|
|
2124
|
+
callback(e);
|
|
2125
|
+
}
|
|
2126
|
+
}
|
|
2127
|
+
this.#unskipped_branches.add(effect);
|
|
2123
2128
|
}
|
|
2124
|
-
#
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
+
#process() {
|
|
2130
|
+
this.#started = true;
|
|
2131
|
+
if (flush_count++ > 1e3) {
|
|
2132
|
+
this.#unlink();
|
|
2133
|
+
infinite_loop_guard();
|
|
2134
|
+
}
|
|
2135
|
+
for (const e of this.#dirty_effects) {
|
|
2136
|
+
this.#maybe_dirty_effects.delete(e);
|
|
2137
|
+
set_signal_status(e, DIRTY);
|
|
2138
|
+
this.schedule(e);
|
|
2139
|
+
}
|
|
2140
|
+
for (const e of this.#maybe_dirty_effects) {
|
|
2141
|
+
set_signal_status(e, MAYBE_DIRTY);
|
|
2142
|
+
this.schedule(e);
|
|
2143
|
+
}
|
|
2144
|
+
const roots = this.#roots;
|
|
2145
|
+
this.#roots = [];
|
|
2146
|
+
this.apply();
|
|
2147
|
+
/** @type {Effect[]} */
|
|
2148
|
+
var effects = collected_effects = [];
|
|
2149
|
+
/** @type {Effect[]} */
|
|
2150
|
+
var render_effects = [];
|
|
2151
|
+
/**
|
|
2152
|
+
* @type {Effect[]}
|
|
2153
|
+
* @deprecated when we get rid of legacy mode and stores, we can get rid of this
|
|
2154
|
+
*/
|
|
2155
|
+
var updates = legacy_updates = [];
|
|
2156
|
+
for (const root of roots) try {
|
|
2157
|
+
this.#traverse(root, effects, render_effects);
|
|
2158
|
+
} catch (e) {
|
|
2159
|
+
reset_all(root);
|
|
2160
|
+
if (!this.#is_deferred()) this.discard();
|
|
2161
|
+
throw e;
|
|
2162
|
+
}
|
|
2163
|
+
current_batch = null;
|
|
2164
|
+
if (updates.length > 0) {
|
|
2165
|
+
var batch = Batch.ensure();
|
|
2166
|
+
for (const e of updates) batch.schedule(e);
|
|
2167
|
+
}
|
|
2168
|
+
collected_effects = null;
|
|
2169
|
+
legacy_updates = null;
|
|
2170
|
+
if (this.#is_deferred()) {
|
|
2171
|
+
this.#defer_effects(render_effects);
|
|
2172
|
+
this.#defer_effects(effects);
|
|
2173
|
+
for (const [e, t] of this.#skipped_branches) reset_branch(e, t);
|
|
2174
|
+
if (updates.length > 0)
|
|
2175
|
+
/** @type {Batch} */ current_batch.#process();
|
|
2176
|
+
return;
|
|
2177
|
+
}
|
|
2178
|
+
const earlier_batch = this.#find_earlier_batch();
|
|
2179
|
+
if (earlier_batch) {
|
|
2180
|
+
this.#defer_effects(render_effects);
|
|
2181
|
+
this.#defer_effects(effects);
|
|
2182
|
+
earlier_batch.#merge(this);
|
|
2183
|
+
return;
|
|
2129
2184
|
}
|
|
2185
|
+
this.#dirty_effects.clear();
|
|
2186
|
+
this.#maybe_dirty_effects.clear();
|
|
2187
|
+
for (const fn of this.#commit_callbacks) fn(this);
|
|
2188
|
+
this.#commit_callbacks.clear();
|
|
2189
|
+
previous_batch = this;
|
|
2190
|
+
flush_queued_effects(render_effects);
|
|
2191
|
+
flush_queued_effects(effects);
|
|
2192
|
+
previous_batch = null;
|
|
2193
|
+
this.#deferred?.resolve();
|
|
2194
|
+
var next_batch = current_batch;
|
|
2195
|
+
if (this.#pending === 0 && (this.#roots.length === 0 || next_batch !== null)) this.#unlink();
|
|
2196
|
+
if (this.#roots.length > 0) if (next_batch !== null) {
|
|
2197
|
+
const batch = next_batch;
|
|
2198
|
+
batch.#roots.push(...this.#roots.filter((r) => !batch.#roots.includes(r)));
|
|
2199
|
+
} else next_batch = this;
|
|
2200
|
+
if (next_batch !== null) next_batch.#process();
|
|
2130
2201
|
}
|
|
2131
2202
|
/**
|
|
2132
|
-
*
|
|
2203
|
+
* Traverse the effect tree, executing effects or stashing
|
|
2204
|
+
* them for later execution as appropriate
|
|
2205
|
+
* @param {Effect} root
|
|
2206
|
+
* @param {Effect[]} effects
|
|
2207
|
+
* @param {Effect[]} render_effects
|
|
2133
2208
|
*/
|
|
2134
|
-
#
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
});
|
|
2153
|
-
if (this.#pending_count === 0) {
|
|
2154
|
-
this.#anchor.before(fragment);
|
|
2155
|
-
this.#offscreen_fragment = null;
|
|
2156
|
-
pause_effect(this.#pending_effect, () => {
|
|
2157
|
-
this.#pending_effect = null;
|
|
2158
|
-
});
|
|
2159
|
-
this.#resolve(current_batch);
|
|
2209
|
+
#traverse(root, effects, render_effects) {
|
|
2210
|
+
root.f ^= CLEAN;
|
|
2211
|
+
var effect = root.first;
|
|
2212
|
+
while (effect !== null) {
|
|
2213
|
+
var flags = effect.f;
|
|
2214
|
+
var is_branch = (flags & 96) !== 0;
|
|
2215
|
+
if (!(is_branch && (flags & 1024) !== 0 || (flags & 8192) !== 0 || this.#skipped_branches.has(effect)) && effect.fn !== null) {
|
|
2216
|
+
if (is_branch) effect.f ^= CLEAN;
|
|
2217
|
+
else if ((flags & 4) !== 0) effects.push(effect);
|
|
2218
|
+
else if (is_dirty(effect)) {
|
|
2219
|
+
if ((flags & 16) !== 0) this.#maybe_dirty_effects.add(effect);
|
|
2220
|
+
update_effect(effect);
|
|
2221
|
+
}
|
|
2222
|
+
var child = effect.first;
|
|
2223
|
+
if (child !== null) {
|
|
2224
|
+
effect = child;
|
|
2225
|
+
continue;
|
|
2226
|
+
}
|
|
2160
2227
|
}
|
|
2161
|
-
|
|
2228
|
+
while (effect !== null) {
|
|
2229
|
+
var next = effect.next;
|
|
2230
|
+
if (next !== null) {
|
|
2231
|
+
effect = next;
|
|
2232
|
+
break;
|
|
2233
|
+
}
|
|
2234
|
+
effect = effect.parent;
|
|
2235
|
+
}
|
|
2236
|
+
}
|
|
2162
2237
|
}
|
|
2163
|
-
#
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
});
|
|
2171
|
-
if (this.#pending_count > 0) {
|
|
2172
|
-
var fragment = this.#offscreen_fragment = document.createDocumentFragment();
|
|
2173
|
-
move_effect(this.#main_effect, fragment);
|
|
2174
|
-
const pending = this.#props.pending;
|
|
2175
|
-
this.#pending_effect = branch(() => pending(this.#anchor));
|
|
2176
|
-
} else this.#resolve(current_batch);
|
|
2177
|
-
} catch (error) {
|
|
2178
|
-
this.error(error);
|
|
2238
|
+
#find_earlier_batch() {
|
|
2239
|
+
var batch = this.#prev;
|
|
2240
|
+
while (batch !== null) {
|
|
2241
|
+
if (!batch.is_fork) {
|
|
2242
|
+
for (const [value, [, is_derived]] of this.current) if (batch.current.has(value) && !is_derived) return batch;
|
|
2243
|
+
}
|
|
2244
|
+
batch = batch.#prev;
|
|
2179
2245
|
}
|
|
2246
|
+
return null;
|
|
2180
2247
|
}
|
|
2181
2248
|
/**
|
|
2182
2249
|
* @param {Batch} batch
|
|
2183
2250
|
*/
|
|
2184
|
-
#
|
|
2185
|
-
|
|
2186
|
-
|
|
2251
|
+
#merge(batch) {
|
|
2252
|
+
for (const [source, value] of batch.current) {
|
|
2253
|
+
if (!this.previous.has(source) && batch.previous.has(source)) this.previous.set(source, batch.previous.get(source));
|
|
2254
|
+
this.current.set(source, value);
|
|
2255
|
+
}
|
|
2256
|
+
for (const [effect, deferred] of batch.async_deriveds) {
|
|
2257
|
+
const d = this.async_deriveds.get(effect);
|
|
2258
|
+
if (d) deferred.promise.then(d.resolve).catch(d.reject);
|
|
2259
|
+
}
|
|
2260
|
+
batch.async_deriveds.clear();
|
|
2261
|
+
this.transfer_effects(batch.#dirty_effects, batch.#maybe_dirty_effects);
|
|
2262
|
+
/**
|
|
2263
|
+
* mark all effects that depend on `batch.current`, except the
|
|
2264
|
+
* async effects that we just resolved (TODO unless they depend
|
|
2265
|
+
* on values in this batch that are NOT in the later batch?).
|
|
2266
|
+
* Through this we also will populate the correct #skipped_branches,
|
|
2267
|
+
* oncommit callbacks etc, so we don't need to merge them separately.
|
|
2268
|
+
* @param {Value} value
|
|
2269
|
+
*/
|
|
2270
|
+
const mark = (value) => {
|
|
2271
|
+
var reactions = value.reactions;
|
|
2272
|
+
if (reactions === null) return;
|
|
2273
|
+
for (const reaction of reactions) {
|
|
2274
|
+
var flags = reaction.f;
|
|
2275
|
+
if ((flags & 2) !== 0) mark(reaction);
|
|
2276
|
+
else {
|
|
2277
|
+
var effect = reaction;
|
|
2278
|
+
if (flags & 4194320 && !this.async_deriveds.has(effect)) {
|
|
2279
|
+
this.#maybe_dirty_effects.delete(effect);
|
|
2280
|
+
set_signal_status(effect, DIRTY);
|
|
2281
|
+
this.schedule(effect);
|
|
2282
|
+
}
|
|
2283
|
+
}
|
|
2284
|
+
}
|
|
2285
|
+
};
|
|
2286
|
+
for (const source of this.current.keys()) mark(source);
|
|
2287
|
+
this.oncommit(() => batch.discard());
|
|
2288
|
+
batch.#unlink();
|
|
2289
|
+
current_batch = this;
|
|
2290
|
+
this.#process();
|
|
2291
|
+
}
|
|
2292
|
+
/**
|
|
2293
|
+
* @param {Effect[]} effects
|
|
2294
|
+
*/
|
|
2295
|
+
#defer_effects(effects) {
|
|
2296
|
+
for (var i = 0; i < effects.length; i += 1) defer_effect(effects[i], this.#dirty_effects, this.#maybe_dirty_effects);
|
|
2297
|
+
}
|
|
2298
|
+
/**
|
|
2299
|
+
* Associate a change to a given source with the current
|
|
2300
|
+
* batch, noting its previous and current values
|
|
2301
|
+
* @param {Value} source
|
|
2302
|
+
* @param {any} value
|
|
2303
|
+
* @param {boolean} [is_derived]
|
|
2304
|
+
*/
|
|
2305
|
+
capture(source, value, is_derived = false) {
|
|
2306
|
+
if (source.v !== UNINITIALIZED && !this.previous.has(source)) this.previous.set(source, source.v);
|
|
2307
|
+
if ((source.f & 8388608) === 0) {
|
|
2308
|
+
this.current.set(source, [value, is_derived]);
|
|
2309
|
+
batch_values?.set(source, value);
|
|
2310
|
+
}
|
|
2311
|
+
if (!this.is_fork) source.v = value;
|
|
2312
|
+
}
|
|
2313
|
+
activate() {
|
|
2314
|
+
current_batch = this;
|
|
2315
|
+
}
|
|
2316
|
+
deactivate() {
|
|
2317
|
+
current_batch = null;
|
|
2318
|
+
batch_values = null;
|
|
2319
|
+
}
|
|
2320
|
+
flush() {
|
|
2321
|
+
try {
|
|
2322
|
+
is_processing = true;
|
|
2323
|
+
current_batch = this;
|
|
2324
|
+
this.#process();
|
|
2325
|
+
} finally {
|
|
2326
|
+
flush_count = 0;
|
|
2327
|
+
last_scheduled_effect = null;
|
|
2328
|
+
collected_effects = null;
|
|
2329
|
+
legacy_updates = null;
|
|
2330
|
+
is_processing = false;
|
|
2331
|
+
current_batch = null;
|
|
2332
|
+
batch_values = null;
|
|
2333
|
+
old_values.clear();
|
|
2334
|
+
}
|
|
2335
|
+
}
|
|
2336
|
+
discard() {
|
|
2337
|
+
for (const fn of this.#discard_callbacks) fn(this);
|
|
2338
|
+
this.#discard_callbacks.clear();
|
|
2339
|
+
for (const deferred of this.async_deriveds.values()) deferred.reject(OBSOLETE);
|
|
2340
|
+
this.#unlink();
|
|
2341
|
+
this.#deferred?.resolve();
|
|
2187
2342
|
}
|
|
2188
2343
|
/**
|
|
2189
|
-
* Defer an effect inside a pending boundary until the boundary resolves
|
|
2190
2344
|
* @param {Effect} effect
|
|
2191
2345
|
*/
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
}
|
|
2195
|
-
/**
|
|
2196
|
-
* Returns `false` if the effect exists inside a boundary whose pending snippet is shown
|
|
2197
|
-
* @returns {boolean}
|
|
2198
|
-
*/
|
|
2199
|
-
is_rendered() {
|
|
2200
|
-
return !this.is_pending && (!this.parent || this.parent.is_rendered());
|
|
2346
|
+
register_created_effect(effect) {
|
|
2347
|
+
this.#new_effects.push(effect);
|
|
2201
2348
|
}
|
|
2202
|
-
|
|
2203
|
-
|
|
2349
|
+
#commit() {
|
|
2350
|
+
for (let batch = first_batch; batch !== null; batch = batch.#next) {
|
|
2351
|
+
var is_earlier = batch.id < this.id;
|
|
2352
|
+
/** @type {Source[]} */
|
|
2353
|
+
var sources = [];
|
|
2354
|
+
for (const [source, [value, is_derived]] of this.current) {
|
|
2355
|
+
if (batch.current.has(source)) {
|
|
2356
|
+
var batch_value = batch.current.get(source)[0];
|
|
2357
|
+
if (is_earlier && value !== batch_value) batch.current.set(source, [value, is_derived]);
|
|
2358
|
+
else continue;
|
|
2359
|
+
}
|
|
2360
|
+
sources.push(source);
|
|
2361
|
+
}
|
|
2362
|
+
if (is_earlier) for (const [effect, deferred] of this.async_deriveds) {
|
|
2363
|
+
const d = batch.async_deriveds.get(effect);
|
|
2364
|
+
if (d) deferred.promise.then(d.resolve).catch(d.reject);
|
|
2365
|
+
}
|
|
2366
|
+
var current = [...batch.current.keys()].filter((source) => !batch.current.get(source)[1]);
|
|
2367
|
+
if (!batch.#started || current.length === 0) continue;
|
|
2368
|
+
var others = current.filter((source) => !this.current.has(source));
|
|
2369
|
+
if (others.length === 0) {
|
|
2370
|
+
if (is_earlier) batch.discard();
|
|
2371
|
+
} else if (sources.length > 0) {
|
|
2372
|
+
if (is_earlier) for (const unskipped of this.#unskipped_branches) batch.unskip_effect(unskipped, (e) => {
|
|
2373
|
+
if ((e.f & 4194320) !== 0) batch.schedule(e);
|
|
2374
|
+
else batch.#defer_effects([e]);
|
|
2375
|
+
});
|
|
2376
|
+
batch.activate();
|
|
2377
|
+
/** @type {Set<Value>} */
|
|
2378
|
+
var marked = /* @__PURE__ */ new Set();
|
|
2379
|
+
/** @type {Map<Reaction, boolean>} */
|
|
2380
|
+
var checked = /* @__PURE__ */ new Map();
|
|
2381
|
+
for (var source of sources) mark_effects(source, others, marked, checked);
|
|
2382
|
+
checked = /* @__PURE__ */ new Map();
|
|
2383
|
+
var current_unequal = [...batch.current].filter(([c, v1]) => {
|
|
2384
|
+
const v2 = this.current.get(c);
|
|
2385
|
+
if (!v2) return true;
|
|
2386
|
+
return v2[0] !== v1[0] || v2[1] !== v1[1];
|
|
2387
|
+
}).map(([c]) => c);
|
|
2388
|
+
if (current_unequal.length > 0) {
|
|
2389
|
+
for (const effect of this.#new_effects) if ((effect.f & 155648) === 0 && depends_on(effect, current_unequal, checked)) if ((effect.f & 4194320) !== 0) {
|
|
2390
|
+
set_signal_status(effect, DIRTY);
|
|
2391
|
+
batch.schedule(effect);
|
|
2392
|
+
} else batch.#dirty_effects.add(effect);
|
|
2393
|
+
}
|
|
2394
|
+
if (batch.#roots.length > 0 && !batch.#decrement_queued) {
|
|
2395
|
+
batch.apply();
|
|
2396
|
+
for (var root of batch.#roots) batch.#traverse(root, [], []);
|
|
2397
|
+
batch.#roots = [];
|
|
2398
|
+
}
|
|
2399
|
+
batch.deactivate();
|
|
2400
|
+
}
|
|
2401
|
+
}
|
|
2204
2402
|
}
|
|
2205
2403
|
/**
|
|
2206
|
-
* @
|
|
2207
|
-
* @param {
|
|
2404
|
+
* @param {boolean} blocking
|
|
2405
|
+
* @param {Effect} effect
|
|
2208
2406
|
*/
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
set_active_reaction(this.#effect);
|
|
2215
|
-
set_component_context(this.#effect.ctx);
|
|
2216
|
-
try {
|
|
2217
|
-
Batch.ensure();
|
|
2218
|
-
return fn();
|
|
2219
|
-
} catch (e) {
|
|
2220
|
-
handle_error(e);
|
|
2221
|
-
return null;
|
|
2222
|
-
} finally {
|
|
2223
|
-
set_active_effect(previous_effect);
|
|
2224
|
-
set_active_reaction(previous_reaction);
|
|
2225
|
-
set_component_context(previous_ctx);
|
|
2407
|
+
increment(blocking, effect) {
|
|
2408
|
+
this.#pending += 1;
|
|
2409
|
+
if (blocking) {
|
|
2410
|
+
let blocking_pending_count = this.#blocking_pending.get(effect) ?? 0;
|
|
2411
|
+
this.#blocking_pending.set(effect, blocking_pending_count + 1);
|
|
2226
2412
|
}
|
|
2227
2413
|
}
|
|
2228
2414
|
/**
|
|
2229
|
-
*
|
|
2230
|
-
*
|
|
2231
|
-
* @param {1 | -1} d
|
|
2232
|
-
* @param {Batch} batch
|
|
2415
|
+
* @param {boolean} blocking
|
|
2416
|
+
* @param {Effect} effect
|
|
2233
2417
|
*/
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
if (this.#pending_count === 0) {
|
|
2241
|
-
this.#resolve(batch);
|
|
2242
|
-
if (this.#pending_effect) pause_effect(this.#pending_effect, () => {
|
|
2243
|
-
this.#pending_effect = null;
|
|
2244
|
-
});
|
|
2245
|
-
if (this.#offscreen_fragment) {
|
|
2246
|
-
this.#anchor.before(this.#offscreen_fragment);
|
|
2247
|
-
this.#offscreen_fragment = null;
|
|
2248
|
-
}
|
|
2418
|
+
decrement(blocking, effect) {
|
|
2419
|
+
this.#pending -= 1;
|
|
2420
|
+
if (blocking) {
|
|
2421
|
+
let blocking_pending_count = this.#blocking_pending.get(effect) ?? 0;
|
|
2422
|
+
if (blocking_pending_count === 1) this.#blocking_pending.delete(effect);
|
|
2423
|
+
else this.#blocking_pending.set(effect, blocking_pending_count - 1);
|
|
2249
2424
|
}
|
|
2425
|
+
if (this.#decrement_queued) return;
|
|
2426
|
+
this.#decrement_queued = true;
|
|
2427
|
+
queue_micro_task(() => {
|
|
2428
|
+
this.#decrement_queued = false;
|
|
2429
|
+
if (this.linked) this.flush();
|
|
2430
|
+
});
|
|
2250
2431
|
}
|
|
2251
2432
|
/**
|
|
2252
|
-
*
|
|
2253
|
-
*
|
|
2254
|
-
* Do not call from inside the class
|
|
2255
|
-
* @param {1 | -1} d
|
|
2256
|
-
* @param {Batch} batch
|
|
2433
|
+
* @param {Set<Effect>} dirty_effects
|
|
2434
|
+
* @param {Set<Effect>} maybe_dirty_effects
|
|
2257
2435
|
*/
|
|
2258
|
-
|
|
2259
|
-
this.#
|
|
2260
|
-
this.#
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
queue_micro_task(() => {
|
|
2264
|
-
this.#pending_count_update_queued = false;
|
|
2265
|
-
if (this.#effect_pending) internal_set(this.#effect_pending, this.#local_pending_count);
|
|
2266
|
-
});
|
|
2436
|
+
transfer_effects(dirty_effects, maybe_dirty_effects) {
|
|
2437
|
+
for (const e of dirty_effects) this.#dirty_effects.add(e);
|
|
2438
|
+
for (const e of maybe_dirty_effects) this.#maybe_dirty_effects.add(e);
|
|
2439
|
+
dirty_effects.clear();
|
|
2440
|
+
maybe_dirty_effects.clear();
|
|
2267
2441
|
}
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2442
|
+
/** @param {(batch: Batch) => void} fn */
|
|
2443
|
+
oncommit(fn) {
|
|
2444
|
+
this.#commit_callbacks.add(fn);
|
|
2271
2445
|
}
|
|
2272
|
-
/** @param {
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2446
|
+
/** @param {(batch: Batch) => void} fn */
|
|
2447
|
+
ondiscard(fn) {
|
|
2448
|
+
this.#discard_callbacks.add(fn);
|
|
2449
|
+
}
|
|
2450
|
+
settled() {
|
|
2451
|
+
return (this.#deferred ??= deferred()).promise;
|
|
2452
|
+
}
|
|
2453
|
+
static ensure() {
|
|
2454
|
+
if (current_batch === null) {
|
|
2455
|
+
const batch = current_batch = new Batch();
|
|
2456
|
+
if (!is_processing && !is_flushing_sync) queue_micro_task(() => {
|
|
2457
|
+
if (!batch.#started) batch.flush();
|
|
2281
2458
|
});
|
|
2282
|
-
}
|
|
2459
|
+
}
|
|
2460
|
+
return current_batch;
|
|
2461
|
+
}
|
|
2462
|
+
apply() {
|
|
2463
|
+
batch_values = null;
|
|
2283
2464
|
}
|
|
2284
2465
|
/**
|
|
2285
|
-
*
|
|
2466
|
+
*
|
|
2467
|
+
* @param {Effect} effect
|
|
2286
2468
|
*/
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
if (this.#pending_effect) {
|
|
2293
|
-
destroy_effect(this.#pending_effect);
|
|
2294
|
-
this.#pending_effect = null;
|
|
2295
|
-
}
|
|
2296
|
-
if (this.#failed_effect) {
|
|
2297
|
-
destroy_effect(this.#failed_effect);
|
|
2298
|
-
this.#failed_effect = null;
|
|
2299
|
-
}
|
|
2300
|
-
if (hydrating) {
|
|
2301
|
-
set_hydrate_node(this.#hydrate_open);
|
|
2302
|
-
next();
|
|
2303
|
-
set_hydrate_node(skip_nodes());
|
|
2469
|
+
schedule(effect) {
|
|
2470
|
+
last_scheduled_effect = effect;
|
|
2471
|
+
if (effect.b?.is_pending && (effect.f & 16777228) !== 0 && (effect.f & 32768) === 0) {
|
|
2472
|
+
effect.b.defer_effect(effect);
|
|
2473
|
+
return;
|
|
2304
2474
|
}
|
|
2305
|
-
var
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
svelte_boundary_reset_noop();
|
|
2312
|
-
return;
|
|
2313
|
-
}
|
|
2314
|
-
did_reset = true;
|
|
2315
|
-
if (calling_on_error) svelte_boundary_reset_onerror();
|
|
2316
|
-
if (this.#failed_effect !== null) pause_effect(this.#failed_effect, () => {
|
|
2317
|
-
this.#failed_effect = null;
|
|
2318
|
-
});
|
|
2319
|
-
this.#run(() => {
|
|
2320
|
-
this.#render();
|
|
2321
|
-
});
|
|
2322
|
-
};
|
|
2323
|
-
/** @param {unknown} transformed_error */
|
|
2324
|
-
const handle_error_result = (transformed_error) => {
|
|
2325
|
-
try {
|
|
2326
|
-
calling_on_error = true;
|
|
2327
|
-
onerror?.(transformed_error, reset);
|
|
2328
|
-
calling_on_error = false;
|
|
2329
|
-
} catch (error) {
|
|
2330
|
-
invoke_error_boundary(error, this.#effect && this.#effect.parent);
|
|
2475
|
+
var e = effect;
|
|
2476
|
+
while (e.parent !== null) {
|
|
2477
|
+
e = e.parent;
|
|
2478
|
+
var flags = e.f;
|
|
2479
|
+
if (collected_effects !== null && e === active_effect) {
|
|
2480
|
+
if ((active_reaction === null || (active_reaction.f & 2) === 0) && !legacy_is_updating_store) return;
|
|
2331
2481
|
}
|
|
2332
|
-
if (
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
var effect = active_effect;
|
|
2336
|
-
effect.b = this;
|
|
2337
|
-
effect.f |= 128;
|
|
2338
|
-
failed(this.#anchor, () => transformed_error, () => reset);
|
|
2339
|
-
});
|
|
2340
|
-
} catch (error) {
|
|
2341
|
-
invoke_error_boundary(error, this.#effect.parent);
|
|
2342
|
-
return null;
|
|
2343
|
-
}
|
|
2344
|
-
});
|
|
2345
|
-
};
|
|
2346
|
-
queue_micro_task(() => {
|
|
2347
|
-
/** @type {unknown} */
|
|
2348
|
-
var result;
|
|
2349
|
-
try {
|
|
2350
|
-
result = this.transform_error(error);
|
|
2351
|
-
} catch (e) {
|
|
2352
|
-
invoke_error_boundary(e, this.#effect && this.#effect.parent);
|
|
2353
|
-
return;
|
|
2482
|
+
if ((flags & 96) !== 0) {
|
|
2483
|
+
if ((flags & 1024) === 0) return;
|
|
2484
|
+
e.f ^= CLEAN;
|
|
2354
2485
|
}
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
handle_error_result,
|
|
2358
|
-
/** @param {unknown} e */
|
|
2359
|
-
(e) => invoke_error_boundary(e, this.#effect && this.#effect.parent)
|
|
2360
|
-
);
|
|
2361
|
-
else handle_error_result(result);
|
|
2362
|
-
});
|
|
2363
|
-
}
|
|
2364
|
-
};
|
|
2365
|
-
/**
|
|
2366
|
-
* @param {Derived} derived
|
|
2367
|
-
* @returns {void}
|
|
2368
|
-
*/
|
|
2369
|
-
function destroy_derived_effects(derived) {
|
|
2370
|
-
var effects = derived.effects;
|
|
2371
|
-
if (effects !== null) {
|
|
2372
|
-
derived.effects = null;
|
|
2373
|
-
for (var i = 0; i < effects.length; i += 1) destroy_effect(effects[i]);
|
|
2486
|
+
}
|
|
2487
|
+
this.#roots.push(e);
|
|
2374
2488
|
}
|
|
2375
|
-
|
|
2489
|
+
#unlink() {
|
|
2490
|
+
if (!this.linked) return;
|
|
2491
|
+
var prev = this.#prev;
|
|
2492
|
+
var next = this.#next;
|
|
2493
|
+
if (prev === null) first_batch = next;
|
|
2494
|
+
else prev.#next = next;
|
|
2495
|
+
if (next === null) last_batch = prev;
|
|
2496
|
+
else next.#prev = prev;
|
|
2497
|
+
this.linked = false;
|
|
2498
|
+
}
|
|
2499
|
+
};
|
|
2376
2500
|
/**
|
|
2377
|
-
*
|
|
2378
|
-
*
|
|
2501
|
+
* Synchronously flush any pending updates.
|
|
2502
|
+
* Returns void if no callback is provided, otherwise returns the result of calling the callback.
|
|
2503
|
+
* @template [T=void]
|
|
2504
|
+
* @param {(() => T) | undefined} [fn]
|
|
2379
2505
|
* @returns {T}
|
|
2380
2506
|
*/
|
|
2381
|
-
function
|
|
2382
|
-
var
|
|
2383
|
-
|
|
2384
|
-
var parent = derived.parent;
|
|
2385
|
-
if (!is_destroying_effect && parent !== null && (parent.f & 24576) !== 0) {
|
|
2386
|
-
derived_inert();
|
|
2387
|
-
return derived.v;
|
|
2388
|
-
}
|
|
2389
|
-
set_active_effect(parent);
|
|
2507
|
+
function flushSync(fn) {
|
|
2508
|
+
var was_flushing_sync = is_flushing_sync;
|
|
2509
|
+
is_flushing_sync = true;
|
|
2390
2510
|
try {
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2511
|
+
var result;
|
|
2512
|
+
if (fn) {
|
|
2513
|
+
if (current_batch !== null && !current_batch.is_fork) current_batch.flush();
|
|
2514
|
+
result = fn();
|
|
2515
|
+
}
|
|
2516
|
+
while (true) {
|
|
2517
|
+
flush_tasks();
|
|
2518
|
+
if (current_batch === null) return result;
|
|
2519
|
+
current_batch.flush();
|
|
2520
|
+
}
|
|
2394
2521
|
} finally {
|
|
2395
|
-
|
|
2522
|
+
is_flushing_sync = was_flushing_sync;
|
|
2523
|
+
}
|
|
2524
|
+
}
|
|
2525
|
+
function infinite_loop_guard() {
|
|
2526
|
+
try {
|
|
2527
|
+
effect_update_depth_exceeded();
|
|
2528
|
+
} catch (error) {
|
|
2529
|
+
invoke_error_boundary(error, last_scheduled_effect);
|
|
2396
2530
|
}
|
|
2397
|
-
return value;
|
|
2398
2531
|
}
|
|
2532
|
+
/** @type {Set<Effect> | null} */
|
|
2533
|
+
var eager_block_effects = null;
|
|
2399
2534
|
/**
|
|
2400
|
-
* @param {
|
|
2535
|
+
* @param {Array<Effect>} effects
|
|
2401
2536
|
* @returns {void}
|
|
2402
2537
|
*/
|
|
2403
|
-
function
|
|
2404
|
-
var
|
|
2405
|
-
if (
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2538
|
+
function flush_queued_effects(effects) {
|
|
2539
|
+
var length = effects.length;
|
|
2540
|
+
if (length === 0) return;
|
|
2541
|
+
var i = 0;
|
|
2542
|
+
while (i < length) {
|
|
2543
|
+
var effect = effects[i++];
|
|
2544
|
+
if ((effect.f & 24576) === 0 && is_dirty(effect)) {
|
|
2545
|
+
eager_block_effects = /* @__PURE__ */ new Set();
|
|
2546
|
+
update_effect(effect);
|
|
2547
|
+
if (effect.deps === null && effect.first === null && effect.nodes === null && effect.teardown === null && effect.ac === null) unlink_effect(effect);
|
|
2548
|
+
if (eager_block_effects?.size > 0) {
|
|
2549
|
+
old_values.clear();
|
|
2550
|
+
for (const e of eager_block_effects) {
|
|
2551
|
+
if ((e.f & 24576) !== 0) continue;
|
|
2552
|
+
/** @type {Effect[]} */
|
|
2553
|
+
const ordered_effects = [e];
|
|
2554
|
+
let ancestor = e.parent;
|
|
2555
|
+
while (ancestor !== null) {
|
|
2556
|
+
if (eager_block_effects.has(ancestor)) {
|
|
2557
|
+
eager_block_effects.delete(ancestor);
|
|
2558
|
+
ordered_effects.push(ancestor);
|
|
2559
|
+
}
|
|
2560
|
+
ancestor = ancestor.parent;
|
|
2561
|
+
}
|
|
2562
|
+
for (let j = ordered_effects.length - 1; j >= 0; j--) {
|
|
2563
|
+
const e = ordered_effects[j];
|
|
2564
|
+
if ((e.f & 24576) !== 0) continue;
|
|
2565
|
+
update_effect(e);
|
|
2566
|
+
}
|
|
2567
|
+
}
|
|
2568
|
+
eager_block_effects.clear();
|
|
2413
2569
|
}
|
|
2414
2570
|
}
|
|
2415
2571
|
}
|
|
2416
|
-
|
|
2417
|
-
if (batch_values !== null) {
|
|
2418
|
-
if (effect_tracking() || current_batch?.is_fork) batch_values.set(derived, value);
|
|
2419
|
-
} else update_derived_status(derived);
|
|
2572
|
+
eager_block_effects = null;
|
|
2420
2573
|
}
|
|
2421
2574
|
/**
|
|
2422
|
-
*
|
|
2575
|
+
* This is similar to `mark_reactions`, but it only marks async/block effects
|
|
2576
|
+
* depending on `value` and at least one of the other `sources`, so that
|
|
2577
|
+
* these effects can re-run after another batch has been committed
|
|
2578
|
+
* @param {Value} value
|
|
2579
|
+
* @param {Source[]} sources
|
|
2580
|
+
* @param {Set<Value>} marked
|
|
2581
|
+
* @param {Map<Reaction, boolean>} checked
|
|
2423
2582
|
*/
|
|
2424
|
-
function
|
|
2425
|
-
if (
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2583
|
+
function mark_effects(value, sources, marked, checked) {
|
|
2584
|
+
if (marked.has(value)) return;
|
|
2585
|
+
marked.add(value);
|
|
2586
|
+
if (value.reactions !== null) for (const reaction of value.reactions) {
|
|
2587
|
+
const flags = reaction.f;
|
|
2588
|
+
if ((flags & 2) !== 0) mark_effects(reaction, sources, marked, checked);
|
|
2589
|
+
else if ((flags & 4194320) !== 0 && (flags & 2048) === 0 && depends_on(reaction, sources, checked)) {
|
|
2590
|
+
set_signal_status(reaction, DIRTY);
|
|
2591
|
+
schedule_effect(reaction);
|
|
2592
|
+
}
|
|
2433
2593
|
}
|
|
2434
2594
|
}
|
|
2435
2595
|
/**
|
|
2436
|
-
* @param {
|
|
2596
|
+
* @param {Reaction} reaction
|
|
2597
|
+
* @param {Source[]} sources
|
|
2598
|
+
* @param {Map<Reaction, boolean>} checked
|
|
2437
2599
|
*/
|
|
2438
|
-
function
|
|
2439
|
-
|
|
2440
|
-
|
|
2600
|
+
function depends_on(reaction, sources, checked) {
|
|
2601
|
+
const depends = checked.get(reaction);
|
|
2602
|
+
if (depends !== void 0) return depends;
|
|
2603
|
+
if (reaction.deps !== null) for (const dep of reaction.deps) {
|
|
2604
|
+
if (includes.call(sources, dep)) return true;
|
|
2605
|
+
if ((dep.f & 2) !== 0 && depends_on(dep, sources, checked)) {
|
|
2606
|
+
checked.set(dep, true);
|
|
2607
|
+
return true;
|
|
2608
|
+
}
|
|
2609
|
+
}
|
|
2610
|
+
checked.set(reaction, false);
|
|
2611
|
+
return false;
|
|
2612
|
+
}
|
|
2613
|
+
/**
|
|
2614
|
+
* @param {Effect} effect
|
|
2615
|
+
* @returns {void}
|
|
2616
|
+
*/
|
|
2617
|
+
function schedule_effect(effect) {
|
|
2618
|
+
/** @type {Batch} */ current_batch.schedule(effect);
|
|
2619
|
+
}
|
|
2620
|
+
/**
|
|
2621
|
+
* Mark all the effects inside a skipped branch CLEAN, so that
|
|
2622
|
+
* they can be correctly rescheduled later. Tracks dirty and maybe_dirty
|
|
2623
|
+
* effects so they can be rescheduled if the branch survives.
|
|
2624
|
+
* @param {Effect} effect
|
|
2625
|
+
* @param {{ d: Effect[], m: Effect[] }} tracked
|
|
2626
|
+
*/
|
|
2627
|
+
function reset_branch(effect, tracked) {
|
|
2628
|
+
if ((effect.f & 32) !== 0 && (effect.f & 1024) !== 0) return;
|
|
2629
|
+
if ((effect.f & 2048) !== 0) tracked.d.push(effect);
|
|
2630
|
+
else if ((effect.f & 4096) !== 0) tracked.m.push(effect);
|
|
2631
|
+
set_signal_status(effect, CLEAN);
|
|
2632
|
+
var e = effect.first;
|
|
2633
|
+
while (e !== null) {
|
|
2634
|
+
reset_branch(e, tracked);
|
|
2635
|
+
e = e.next;
|
|
2636
|
+
}
|
|
2637
|
+
}
|
|
2638
|
+
/**
|
|
2639
|
+
* Mark an entire effect tree clean following an error
|
|
2640
|
+
* @param {Effect} effect
|
|
2641
|
+
*/
|
|
2642
|
+
function reset_all(effect) {
|
|
2643
|
+
set_signal_status(effect, CLEAN);
|
|
2644
|
+
var e = effect.first;
|
|
2645
|
+
while (e !== null) {
|
|
2646
|
+
reset_all(e);
|
|
2647
|
+
e = e.next;
|
|
2648
|
+
}
|
|
2441
2649
|
}
|
|
2442
2650
|
/** @import { Derived, Effect, Source, Value } from '#client' */
|
|
2443
|
-
/** @type {Set<
|
|
2651
|
+
/** @type {Set<Effect>} */
|
|
2444
2652
|
var eager_effects = /* @__PURE__ */ new Set();
|
|
2445
2653
|
/** @type {Map<Source, any>} */
|
|
2446
2654
|
var old_values = /* @__PURE__ */ new Map();
|
|
@@ -2466,7 +2674,7 @@ function source(v, stack) {
|
|
|
2466
2674
|
* @param {V} v
|
|
2467
2675
|
* @param {Error | null} [stack]
|
|
2468
2676
|
*/
|
|
2469
|
-
|
|
2677
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
2470
2678
|
function state(v, stack) {
|
|
2471
2679
|
const s = source(v, stack);
|
|
2472
2680
|
push_reaction_value(s);
|
|
@@ -2478,7 +2686,7 @@ function state(v, stack) {
|
|
|
2478
2686
|
* @param {boolean} [immutable]
|
|
2479
2687
|
* @returns {Source<V>}
|
|
2480
2688
|
*/
|
|
2481
|
-
|
|
2689
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
2482
2690
|
function mutable_source(initial_value, immutable = false, trackable = true) {
|
|
2483
2691
|
const s = source(initial_value);
|
|
2484
2692
|
if (!immutable) s.equals = safe_equals;
|
|
@@ -2493,7 +2701,7 @@ function mutable_source(initial_value, immutable = false, trackable = true) {
|
|
|
2493
2701
|
* @returns {V}
|
|
2494
2702
|
*/
|
|
2495
2703
|
function set(source, value, should_proxy = false) {
|
|
2496
|
-
if (active_reaction !== null && (!untracking || (active_reaction.f & 131072) !== 0) && is_runes() && (active_reaction.f & 4325394) !== 0 && (current_sources === null || !
|
|
2704
|
+
if (active_reaction !== null && (!untracking || (active_reaction.f & 131072) !== 0) && is_runes() && (active_reaction.f & 4325394) !== 0 && (current_sources === null || !current_sources.has(source))) state_unsafe_mutation();
|
|
2497
2705
|
return internal_set(source, should_proxy ? proxy(value) : value, legacy_updates);
|
|
2498
2706
|
}
|
|
2499
2707
|
/**
|
|
@@ -2525,7 +2733,13 @@ function flush_eager_effects() {
|
|
|
2525
2733
|
eager_effects_deferred = false;
|
|
2526
2734
|
for (const effect of eager_effects) {
|
|
2527
2735
|
if ((effect.f & 1024) !== 0) set_signal_status(effect, MAYBE_DIRTY);
|
|
2528
|
-
|
|
2736
|
+
let dirty;
|
|
2737
|
+
try {
|
|
2738
|
+
dirty = is_dirty(effect);
|
|
2739
|
+
} catch {
|
|
2740
|
+
dirty = true;
|
|
2741
|
+
}
|
|
2742
|
+
if (dirty) update_effect(effect);
|
|
2529
2743
|
}
|
|
2530
2744
|
eager_effects.clear();
|
|
2531
2745
|
}
|
|
@@ -2553,11 +2767,12 @@ function mark_reactions(signal, status, updated_during_traversal) {
|
|
|
2553
2767
|
if (!runes && reaction === active_effect) continue;
|
|
2554
2768
|
var not_dirty = (flags & DIRTY) === 0;
|
|
2555
2769
|
if (not_dirty) set_signal_status(reaction, status);
|
|
2556
|
-
if ((flags &
|
|
2770
|
+
if ((flags & 131072) !== 0) eager_effects.add(reaction);
|
|
2771
|
+
else if ((flags & 2) !== 0) {
|
|
2557
2772
|
var derived = reaction;
|
|
2558
2773
|
batch_values?.delete(derived);
|
|
2559
2774
|
if ((flags & 65536) === 0) {
|
|
2560
|
-
if (flags & 512) reaction.f |= WAS_MARKED;
|
|
2775
|
+
if (flags & 512 && (active_effect === null || (active_effect.f & 2097152) === 0)) reaction.f |= WAS_MARKED;
|
|
2561
2776
|
mark_reactions(derived, MAYBE_DIRTY, updated_during_traversal);
|
|
2562
2777
|
}
|
|
2563
2778
|
} else if (not_dirty) {
|
|
@@ -2746,13 +2961,13 @@ function init_operations() {
|
|
|
2746
2961
|
first_child_getter = get_descriptor(node_prototype, "firstChild").get;
|
|
2747
2962
|
next_sibling_getter = get_descriptor(node_prototype, "nextSibling").get;
|
|
2748
2963
|
if (is_extensible(element_prototype)) {
|
|
2749
|
-
element_prototype
|
|
2750
|
-
element_prototype
|
|
2751
|
-
element_prototype
|
|
2752
|
-
element_prototype.__style = void 0;
|
|
2964
|
+
/** @type {any} */ element_prototype[CLASS_CACHE] = void 0;
|
|
2965
|
+
/** @type {any} */ element_prototype[ATTRIBUTES_CACHE] = null;
|
|
2966
|
+
/** @type {any} */ element_prototype[STYLE_CACHE] = void 0;
|
|
2753
2967
|
element_prototype.__e = void 0;
|
|
2754
2968
|
}
|
|
2755
|
-
if (is_extensible(text_prototype))
|
|
2969
|
+
if (is_extensible(text_prototype))
|
|
2970
|
+
/** @type {any} */ text_prototype[TEXT_CACHE] = void 0;
|
|
2756
2971
|
}
|
|
2757
2972
|
/**
|
|
2758
2973
|
* @param {string} value
|
|
@@ -2765,7 +2980,7 @@ function create_text(value = "") {
|
|
|
2765
2980
|
* @template {Node} N
|
|
2766
2981
|
* @param {N} node
|
|
2767
2982
|
*/
|
|
2768
|
-
|
|
2983
|
+
/*@__NO_SIDE_EFFECTS__*/
|
|
2769
2984
|
function get_first_child(node) {
|
|
2770
2985
|
return first_child_getter.call(node);
|
|
2771
2986
|
}
|
|
@@ -2773,7 +2988,7 @@ function get_first_child(node) {
|
|
|
2773
2988
|
* @template {Node} N
|
|
2774
2989
|
* @param {N} node
|
|
2775
2990
|
*/
|
|
2776
|
-
|
|
2991
|
+
/*@__NO_SIDE_EFFECTS__*/
|
|
2777
2992
|
function get_next_sibling(node) {
|
|
2778
2993
|
return next_sibling_getter.call(node);
|
|
2779
2994
|
}
|
|
@@ -2981,7 +3196,7 @@ function destroy_effect(effect, remove_dom = true) {
|
|
|
2981
3196
|
remove_effect_dom(effect.nodes.start, effect.nodes.end);
|
|
2982
3197
|
removed = true;
|
|
2983
3198
|
}
|
|
2984
|
-
|
|
3199
|
+
effect.f |= DESTROYING;
|
|
2985
3200
|
destroy_effect_children(effect, remove_dom && !removed);
|
|
2986
3201
|
remove_reactions(effect, 0);
|
|
2987
3202
|
var transitions = effect.nodes && effect.nodes.t;
|
|
@@ -3061,8 +3276,10 @@ function pause_children(effect, transitions, local) {
|
|
|
3061
3276
|
var child = effect.first;
|
|
3062
3277
|
while (child !== null) {
|
|
3063
3278
|
var sibling = child.next;
|
|
3064
|
-
|
|
3065
|
-
|
|
3279
|
+
if ((child.f & 64) === 0) {
|
|
3280
|
+
var transparent = (child.f & 65536) !== 0 || (child.f & 32) !== 0 && (effect.f & 16) !== 0;
|
|
3281
|
+
pause_children(child, transitions, transparent ? local : false);
|
|
3282
|
+
}
|
|
3066
3283
|
child = sibling;
|
|
3067
3284
|
}
|
|
3068
3285
|
}
|
|
@@ -3110,13 +3327,12 @@ function set_active_effect(effect) {
|
|
|
3110
3327
|
/**
|
|
3111
3328
|
* When sources are created within a reaction, reading and writing
|
|
3112
3329
|
* them within that reaction should not cause a re-run
|
|
3113
|
-
* @type {null | Source
|
|
3330
|
+
* @type {null | Set<Source>}
|
|
3114
3331
|
*/
|
|
3115
3332
|
var current_sources = null;
|
|
3116
3333
|
/** @param {Value} value */
|
|
3117
3334
|
function push_reaction_value(value) {
|
|
3118
|
-
if (active_reaction !== null && true)
|
|
3119
|
-
else current_sources.push(value);
|
|
3335
|
+
if (active_reaction !== null && true) (current_sources ??= /* @__PURE__ */ new Set()).add(value);
|
|
3120
3336
|
}
|
|
3121
3337
|
/**
|
|
3122
3338
|
* The dependencies of the reaction that is currently being executed. In many cases,
|
|
@@ -3181,7 +3397,7 @@ function is_dirty(reaction) {
|
|
|
3181
3397
|
function schedule_possible_effect_self_invalidation(signal, effect, root = true) {
|
|
3182
3398
|
var reactions = signal.reactions;
|
|
3183
3399
|
if (reactions === null) return;
|
|
3184
|
-
if (current_sources !== null &&
|
|
3400
|
+
if (current_sources !== null && current_sources.has(signal)) return;
|
|
3185
3401
|
for (var i = 0; i < reactions.length; i++) {
|
|
3186
3402
|
var reaction = reactions[i];
|
|
3187
3403
|
if ((reaction.f & 2) !== 0) schedule_possible_effect_self_invalidation(reaction, effect, false);
|
|
@@ -3333,7 +3549,7 @@ function get(signal) {
|
|
|
3333
3549
|
var is_derived = (signal.f & 2) !== 0;
|
|
3334
3550
|
captured_signals?.add(signal);
|
|
3335
3551
|
if (active_reaction !== null && !untracking) {
|
|
3336
|
-
if (!(active_effect !== null && (active_effect.f & 16384) !== 0) && (current_sources === null || !
|
|
3552
|
+
if (!(active_effect !== null && (active_effect.f & 16384) !== 0) && (current_sources === null || !current_sources.has(signal))) {
|
|
3337
3553
|
var deps = active_reaction.deps;
|
|
3338
3554
|
if ((active_reaction.f & 2097152) !== 0) {
|
|
3339
3555
|
if (signal.rv < read_version) {
|
|
@@ -3343,7 +3559,8 @@ function get(signal) {
|
|
|
3343
3559
|
else new_deps.push(signal);
|
|
3344
3560
|
}
|
|
3345
3561
|
} else {
|
|
3346
|
-
|
|
3562
|
+
active_reaction.deps ??= [];
|
|
3563
|
+
if (!includes.call(active_reaction.deps, signal)) active_reaction.deps.push(signal);
|
|
3347
3564
|
var reactions = signal.reactions;
|
|
3348
3565
|
if (reactions === null) signal.reactions = [active_reaction];
|
|
3349
3566
|
else if (!includes.call(reactions, active_reaction)) reactions.push(active_reaction);
|
|
@@ -3536,7 +3753,7 @@ var RAW_TEXT_ELEMENTS = [
|
|
|
3536
3753
|
function is_raw_text_element(name) {
|
|
3537
3754
|
return RAW_TEXT_ELEMENTS.includes(name);
|
|
3538
3755
|
}
|
|
3539
|
-
var REGEX_VALID_TAG_NAME = /^[a-zA-Z][a-zA-Z0-9]*(-[a-zA-Z0-9.\-_\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u{10000}-\u{EFFFF}]
|
|
3756
|
+
var REGEX_VALID_TAG_NAME = /^[a-zA-Z][a-zA-Z0-9]*(-[a-zA-Z0-9.\-_\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u{10000}-\u{EFFFF}]*)?$/u;
|
|
3540
3757
|
var INVALID_ATTR_NAME_CHAR_REGEX = /[\s'">/=\u{FDD0}-\u{FDEF}\u{FFFE}\u{FFFF}\u{1FFFE}\u{1FFFF}\u{2FFFE}\u{2FFFF}\u{3FFFE}\u{3FFFF}\u{4FFFE}\u{4FFFF}\u{5FFFE}\u{5FFFF}\u{6FFFE}\u{6FFFF}\u{7FFFE}\u{7FFFF}\u{8FFFE}\u{8FFFF}\u{9FFFE}\u{9FFFF}\u{AFFFE}\u{AFFFF}\u{BFFFE}\u{BFFFF}\u{CFFFE}\u{CFFFF}\u{DFFFE}\u{DFFFF}\u{EFFFE}\u{EFFFF}\u{FFFFE}\u{FFFFF}\u{10FFFE}\u{10FFFF}]/u;
|
|
3541
3758
|
/**
|
|
3542
3759
|
* @param {Renderer} renderer
|
|
@@ -3582,7 +3799,7 @@ function render(component, options = {}) {
|
|
|
3582
3799
|
*/
|
|
3583
3800
|
function attributes(attrs, css_hash, classes, styles, flags = 0) {
|
|
3584
3801
|
if (styles) attrs.style = to_style(attrs.style, styles);
|
|
3585
|
-
if (attrs.class) attrs.class = clsx(attrs.class);
|
|
3802
|
+
if (attrs.class) attrs.class = clsx$1(attrs.class);
|
|
3586
3803
|
if (css_hash || classes) attrs.class = to_class(attrs.class, css_hash, classes);
|
|
3587
3804
|
let attr_str = "";
|
|
3588
3805
|
let name;
|
|
@@ -3592,7 +3809,7 @@ function attributes(attrs, css_hash, classes, styles, flags = 0) {
|
|
|
3592
3809
|
for (name of Object.keys(attrs)) {
|
|
3593
3810
|
if (typeof attrs[name] === "function") continue;
|
|
3594
3811
|
if (name[0] === "$" && name[1] === "$") continue;
|
|
3595
|
-
if (INVALID_ATTR_NAME_CHAR_REGEX.test(name)) continue;
|
|
3812
|
+
if (name === "" || INVALID_ATTR_NAME_CHAR_REGEX.test(name)) continue;
|
|
3596
3813
|
var value = attrs[name];
|
|
3597
3814
|
var lower = name.toLowerCase();
|
|
3598
3815
|
if (lowercase) name = lower;
|
|
@@ -3707,6 +3924,16 @@ function once(get_value) {
|
|
|
3707
3924
|
};
|
|
3708
3925
|
}
|
|
3709
3926
|
/**
|
|
3927
|
+
* Create an unique ID
|
|
3928
|
+
* @param {Renderer} renderer
|
|
3929
|
+
* @returns {string}
|
|
3930
|
+
*/
|
|
3931
|
+
function props_id(renderer) {
|
|
3932
|
+
const uid = renderer.global.uid();
|
|
3933
|
+
renderer.push("<!--$" + uid + "-->");
|
|
3934
|
+
return uid;
|
|
3935
|
+
}
|
|
3936
|
+
/**
|
|
3710
3937
|
* @template T
|
|
3711
3938
|
* @param {()=>T} fn
|
|
3712
3939
|
* @returns {(new_value?: T) => (T | void)}
|
|
@@ -4269,7 +4496,10 @@ var Renderer = class Renderer {
|
|
|
4269
4496
|
} catch (error) {
|
|
4270
4497
|
const { context, failed, transformError } = item.#boundary;
|
|
4271
4498
|
set_ssr_context(context);
|
|
4272
|
-
let
|
|
4499
|
+
let promise = transformError(error);
|
|
4500
|
+
set_ssr_context(null);
|
|
4501
|
+
let transformed = await promise;
|
|
4502
|
+
set_ssr_context(context);
|
|
4273
4503
|
const failed_renderer = new Renderer(item.global, item);
|
|
4274
4504
|
failed_renderer.type = item.type;
|
|
4275
4505
|
failed_renderer.#out.push(Renderer.#serialize_failed_boundary(transformed));
|
|
@@ -4423,7 +4653,252 @@ var SSRState = class {
|
|
|
4423
4653
|
}
|
|
4424
4654
|
}
|
|
4425
4655
|
};
|
|
4656
|
+
/** @import { HydratableLookupEntry } from '#server' */
|
|
4657
|
+
/**
|
|
4658
|
+
* @template T
|
|
4659
|
+
* @param {string} key
|
|
4660
|
+
* @param {() => T} fn
|
|
4661
|
+
* @returns {T}
|
|
4662
|
+
*/
|
|
4663
|
+
function hydratable(key, fn) {
|
|
4664
|
+
experimental_async_required("hydratable");
|
|
4665
|
+
const { hydratable } = get_render_context();
|
|
4666
|
+
let entry = hydratable.lookup.get(key);
|
|
4667
|
+
if (entry !== void 0) return entry.value;
|
|
4668
|
+
const value = fn();
|
|
4669
|
+
entry = encode(key, value, hydratable.unresolved_promises);
|
|
4670
|
+
hydratable.lookup.set(key, entry);
|
|
4671
|
+
return value;
|
|
4672
|
+
}
|
|
4673
|
+
/**
|
|
4674
|
+
* @param {string} key
|
|
4675
|
+
* @param {any} value
|
|
4676
|
+
* @param {Map<Promise<any>, string>} [unresolved]
|
|
4677
|
+
*/
|
|
4678
|
+
function encode(key, value, unresolved) {
|
|
4679
|
+
/** @type {HydratableLookupEntry} */
|
|
4680
|
+
const entry = {
|
|
4681
|
+
value,
|
|
4682
|
+
serialized: ""
|
|
4683
|
+
};
|
|
4684
|
+
let uid = 1;
|
|
4685
|
+
entry.serialized = uneval(entry.value, (value, uneval) => {
|
|
4686
|
+
if (is_promise(value)) {
|
|
4687
|
+
const placeholder = `"${uid++}"`;
|
|
4688
|
+
const p = value.then((v) => {
|
|
4689
|
+
entry.serialized = entry.serialized.replace(placeholder, () => `r(${uneval(v)})`);
|
|
4690
|
+
}).catch((devalue_error) => hydratable_serialization_failed(key, serialization_stack(entry.stack, devalue_error?.stack)));
|
|
4691
|
+
unresolved?.set(p, key);
|
|
4692
|
+
p.catch(() => {}).finally(() => unresolved?.delete(p));
|
|
4693
|
+
(entry.promises ??= []).push(p);
|
|
4694
|
+
return placeholder;
|
|
4695
|
+
}
|
|
4696
|
+
});
|
|
4697
|
+
return entry;
|
|
4698
|
+
}
|
|
4699
|
+
/**
|
|
4700
|
+
* @param {any} value
|
|
4701
|
+
* @returns {value is Promise<any>}
|
|
4702
|
+
*/
|
|
4703
|
+
function is_promise(value) {
|
|
4704
|
+
return Object.prototype.toString.call(value) === "[object Promise]";
|
|
4705
|
+
}
|
|
4706
|
+
/**
|
|
4707
|
+
* @param {string | undefined} root_stack
|
|
4708
|
+
* @param {string | undefined} uneval_stack
|
|
4709
|
+
*/
|
|
4710
|
+
function serialization_stack(root_stack, uneval_stack) {
|
|
4711
|
+
let out = "";
|
|
4712
|
+
if (root_stack) out += root_stack + "\n";
|
|
4713
|
+
if (uneval_stack) out += "Caused by:\n" + uneval_stack + "\n";
|
|
4714
|
+
return out || "<missing stack trace>";
|
|
4715
|
+
}
|
|
4716
|
+
/** @import { Snippet } from 'svelte' */
|
|
4717
|
+
/** @import { Renderer } from '../renderer' */
|
|
4718
|
+
/** @import { Getters } from '#shared' */
|
|
4719
|
+
/**
|
|
4720
|
+
* Create a snippet programmatically
|
|
4721
|
+
* @template {unknown[]} Params
|
|
4722
|
+
* @param {(...params: Getters<Params>) => {
|
|
4723
|
+
* render: () => string
|
|
4724
|
+
* setup?: (element: Element) => void | (() => void)
|
|
4725
|
+
* }} fn
|
|
4726
|
+
* @returns {Snippet<Params>}
|
|
4727
|
+
*/
|
|
4728
|
+
function createRawSnippet(fn) {
|
|
4729
|
+
return (renderer, ...args) => {
|
|
4730
|
+
var getters = args.map((value) => () => value);
|
|
4731
|
+
renderer.push(fn(...getters).render().trim());
|
|
4732
|
+
};
|
|
4733
|
+
}
|
|
4734
|
+
/** @import { SSRContext } from '#server' */
|
|
4735
|
+
/** @import { Renderer } from './internal/server/renderer.js' */
|
|
4736
|
+
var index_server_exports = /* @__PURE__ */ __exportAll({
|
|
4737
|
+
afterUpdate: () => noop,
|
|
4738
|
+
beforeUpdate: () => noop,
|
|
4739
|
+
createContext: () => createContext,
|
|
4740
|
+
createEventDispatcher: () => createEventDispatcher,
|
|
4741
|
+
createRawSnippet: () => createRawSnippet,
|
|
4742
|
+
flushSync: () => noop,
|
|
4743
|
+
fork: () => fork,
|
|
4744
|
+
getAbortSignal: () => getAbortSignal,
|
|
4745
|
+
getAllContexts: () => getAllContexts,
|
|
4746
|
+
getContext: () => getContext,
|
|
4747
|
+
hasContext: () => hasContext,
|
|
4748
|
+
hydratable: () => hydratable,
|
|
4749
|
+
hydrate: () => hydrate,
|
|
4750
|
+
mount: () => mount,
|
|
4751
|
+
onDestroy: () => onDestroy,
|
|
4752
|
+
onMount: () => noop,
|
|
4753
|
+
setContext: () => setContext,
|
|
4754
|
+
settled: () => settled,
|
|
4755
|
+
tick: () => tick,
|
|
4756
|
+
unmount: () => unmount,
|
|
4757
|
+
untrack: () => run
|
|
4758
|
+
});
|
|
4759
|
+
/** @param {() => void} fn */
|
|
4760
|
+
function onDestroy(fn) {
|
|
4761
|
+
/** @type {Renderer} */ ssr_context.r.on_destroy(fn);
|
|
4762
|
+
}
|
|
4763
|
+
function createEventDispatcher() {
|
|
4764
|
+
return noop;
|
|
4765
|
+
}
|
|
4766
|
+
function mount() {
|
|
4767
|
+
lifecycle_function_unavailable("mount");
|
|
4768
|
+
}
|
|
4769
|
+
function hydrate() {
|
|
4770
|
+
lifecycle_function_unavailable("hydrate");
|
|
4771
|
+
}
|
|
4772
|
+
function unmount() {
|
|
4773
|
+
lifecycle_function_unavailable("unmount");
|
|
4774
|
+
}
|
|
4775
|
+
function fork() {
|
|
4776
|
+
lifecycle_function_unavailable("fork");
|
|
4777
|
+
}
|
|
4778
|
+
async function tick() {}
|
|
4779
|
+
async function settled() {}
|
|
4780
|
+
//#endregion
|
|
4781
|
+
//#region .svelte-kit/adapter-bun/chunks/events.js
|
|
4782
|
+
/**
|
|
4783
|
+
* Used on elements, as a map of event type -> event handler,
|
|
4784
|
+
* and on events themselves to track which element handled an event
|
|
4785
|
+
*/
|
|
4786
|
+
var event_symbol = Symbol("events");
|
|
4787
|
+
/** @type {Set<string>} */
|
|
4788
|
+
var all_registered_events = /* @__PURE__ */ new Set();
|
|
4789
|
+
/** @type {Set<(events: Array<string>) => void>} */
|
|
4790
|
+
var root_event_handles = /* @__PURE__ */ new Set();
|
|
4791
|
+
/**
|
|
4792
|
+
* @param {string} event_name
|
|
4793
|
+
* @param {EventTarget} dom
|
|
4794
|
+
* @param {EventListener} [handler]
|
|
4795
|
+
* @param {AddEventListenerOptions} [options]
|
|
4796
|
+
*/
|
|
4797
|
+
function create_event(event_name, dom, handler, options = {}) {
|
|
4798
|
+
/**
|
|
4799
|
+
* @this {EventTarget}
|
|
4800
|
+
*/
|
|
4801
|
+
function target_handler(event) {
|
|
4802
|
+
if (!options.capture) handle_event_propagation.call(dom, event);
|
|
4803
|
+
if (!event.cancelBubble) return without_reactive_context(() => {
|
|
4804
|
+
return handler?.call(this, event);
|
|
4805
|
+
});
|
|
4806
|
+
}
|
|
4807
|
+
if (event_name.startsWith("pointer") || event_name.startsWith("touch") || event_name === "wheel") queue_micro_task(() => {
|
|
4808
|
+
dom.addEventListener(event_name, target_handler, options);
|
|
4809
|
+
});
|
|
4810
|
+
else dom.addEventListener(event_name, target_handler, options);
|
|
4811
|
+
return target_handler;
|
|
4812
|
+
}
|
|
4813
|
+
/**
|
|
4814
|
+
* Attaches an event handler to an element and returns a function that removes the handler. Using this
|
|
4815
|
+
* rather than `addEventListener` will preserve the correct order relative to handlers added declaratively
|
|
4816
|
+
* (with attributes like `onclick`), which use event delegation for performance reasons
|
|
4817
|
+
*
|
|
4818
|
+
* @param {EventTarget} element
|
|
4819
|
+
* @param {string} type
|
|
4820
|
+
* @param {EventListener} handler
|
|
4821
|
+
* @param {AddEventListenerOptions} [options]
|
|
4822
|
+
*/
|
|
4823
|
+
function on(element, type, handler, options = {}) {
|
|
4824
|
+
var target_handler = create_event(type, element, handler, options);
|
|
4825
|
+
return () => {
|
|
4826
|
+
element.removeEventListener(type, target_handler, options);
|
|
4827
|
+
};
|
|
4828
|
+
}
|
|
4829
|
+
var last_propagated_event = null;
|
|
4830
|
+
/**
|
|
4831
|
+
* @this {EventTarget}
|
|
4832
|
+
* @param {Event} event
|
|
4833
|
+
* @returns {void}
|
|
4834
|
+
*/
|
|
4835
|
+
function handle_event_propagation(event) {
|
|
4836
|
+
var handler_element = this;
|
|
4837
|
+
var owner_document = handler_element.ownerDocument;
|
|
4838
|
+
var event_name = event.type;
|
|
4839
|
+
var path = event.composedPath?.() || [];
|
|
4840
|
+
var current_target = path[0] || event.target;
|
|
4841
|
+
last_propagated_event = event;
|
|
4842
|
+
var path_idx = 0;
|
|
4843
|
+
var handled_at = last_propagated_event === event && event[event_symbol];
|
|
4844
|
+
if (handled_at) {
|
|
4845
|
+
var at_idx = path.indexOf(handled_at);
|
|
4846
|
+
if (at_idx !== -1 && (handler_element === document || handler_element === window)) {
|
|
4847
|
+
event[event_symbol] = handler_element;
|
|
4848
|
+
return;
|
|
4849
|
+
}
|
|
4850
|
+
var handler_idx = path.indexOf(handler_element);
|
|
4851
|
+
if (handler_idx === -1) return;
|
|
4852
|
+
if (at_idx <= handler_idx) path_idx = at_idx;
|
|
4853
|
+
}
|
|
4854
|
+
current_target = path[path_idx] || event.target;
|
|
4855
|
+
if (current_target === handler_element) return;
|
|
4856
|
+
define_property(event, "currentTarget", {
|
|
4857
|
+
configurable: true,
|
|
4858
|
+
get() {
|
|
4859
|
+
return current_target || owner_document;
|
|
4860
|
+
}
|
|
4861
|
+
});
|
|
4862
|
+
var previous_reaction = active_reaction;
|
|
4863
|
+
var previous_effect = active_effect;
|
|
4864
|
+
set_active_reaction(null);
|
|
4865
|
+
set_active_effect(null);
|
|
4866
|
+
try {
|
|
4867
|
+
/**
|
|
4868
|
+
* @type {unknown}
|
|
4869
|
+
*/
|
|
4870
|
+
var throw_error;
|
|
4871
|
+
/**
|
|
4872
|
+
* @type {unknown[]}
|
|
4873
|
+
*/
|
|
4874
|
+
var other_errors = [];
|
|
4875
|
+
while (current_target !== null) {
|
|
4876
|
+
if (current_target === handler_element) break;
|
|
4877
|
+
try {
|
|
4878
|
+
var delegated = current_target[event_symbol]?.[event_name];
|
|
4879
|
+
if (delegated != null && (!current_target.disabled || event.target === current_target)) delegated.call(current_target, event);
|
|
4880
|
+
} catch (error) {
|
|
4881
|
+
if (throw_error) other_errors.push(error);
|
|
4882
|
+
else throw_error = error;
|
|
4883
|
+
}
|
|
4884
|
+
if (event.cancelBubble) break;
|
|
4885
|
+
path_idx++;
|
|
4886
|
+
current_target = path_idx < path.length ? path[path_idx] : null;
|
|
4887
|
+
}
|
|
4888
|
+
if (throw_error) {
|
|
4889
|
+
for (let error of other_errors) queueMicrotask(() => {
|
|
4890
|
+
throw error;
|
|
4891
|
+
});
|
|
4892
|
+
throw throw_error;
|
|
4893
|
+
}
|
|
4894
|
+
} finally {
|
|
4895
|
+
event[event_symbol] = handler_element;
|
|
4896
|
+
delete event.currentTarget;
|
|
4897
|
+
set_active_reaction(previous_reaction);
|
|
4898
|
+
set_active_effect(previous_effect);
|
|
4899
|
+
}
|
|
4900
|
+
}
|
|
4426
4901
|
//#endregion
|
|
4427
|
-
export {
|
|
4902
|
+
export { onDestroy as $, flushSync as A, hydrating as B, define_property as C, clsx as Ct, ensure_array_like as D, element as E, get_first_child as F, is_passive_event as G, hydration_mismatch as H, get_next_sibling as I, is_valid_array_index as J, is_plain_object as K, get_type as L, get$1 as M, getAllContexts as N, enumerable_symbols as O, getContext as P, noop as Q, hasContext as R, create_text as S, writable as St, derived$1 as T, index_server_exports as U, hydration_failed as V, init_operations as W, mount as X, is_valid_array_len as Y, mutable_source as Z, boundary as _, to_array as _t, ATTACHMENT_KEY as a, render as at, component_context as b, unsubscribe_stores as bt, LEGACY_PROPS as c, setContext as ct, array_from as d, spread_props as dt, pop as et, attr as f, store_get as ft, bind_props as g, tick as gt, attributes as h, stringify_string as ht, root_event_handles as i, readonly as it, get as j, escape_html as k, MAX_ARRAY_INDEX as l, set_hydrate_node as lt, attr_style as m, stringify_key as mt, handle_event_propagation as n, push as nt, DevalueError as o, run as ot, attr_class as p, stringify as pt, is_primitive as q, on as r, readable as rt, HYDRATION_ERROR as s, set as st, all_registered_events as t, props_id as tt, active_effect as u, set_hydrating as ut, clear_text_content as v, uneval as vt, derived as w, component_root as x, valid_array_indices as xt, clsx$1 as y, unmount as yt, hydrate_node as z };
|
|
4428
4903
|
|
|
4429
|
-
//# sourceMappingURL=
|
|
4904
|
+
//# sourceMappingURL=events-Bhh2w-5S.js.map
|