@powerhousedao/ph-clint-app 0.1.0-dev.73 → 0.1.0-dev.74
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/browser/document-models/index.js +1 -1
- package/dist/browser/document-models/ph-clint-project/index.js +3 -3
- package/dist/browser/{editor-DL0W2XOS.js → editor-CAZmaheq.js} +825 -261
- package/dist/browser/{editor-DL0W2XOS.js.map → editor-CAZmaheq.js.map} +1 -1
- package/dist/browser/editors/ph-clint-project-editor/module.js +1 -1
- package/dist/browser/index.js +3 -3
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/{module-DoAlHsjp.js → module-K5q3UobV.js} +1970 -977
- package/dist/browser/module-K5q3UobV.js.map +1 -0
- package/dist/browser/{ph-clint-project-D634z5c5.js → ph-clint-project-Bbl7jqNw.js} +4 -6
- package/dist/browser/ph-clint-project-Bbl7jqNw.js.map +1 -0
- package/dist/connect/assets/editor-CQqCB-3d.js +2 -0
- package/dist/connect/assets/editor-CQqCB-3d.js.map +1 -0
- package/dist/connect/assets/{index-BXAErAWR.js → index-DmrNLi1C.js} +20 -20
- package/dist/connect/assets/index-DmrNLi1C.js.map +1 -0
- package/dist/connect/assets/index-cjUwUwMU.css +2 -0
- package/dist/connect/assets/ph-clint-project-DZ_ZplDv.js +1142 -0
- package/dist/connect/assets/ph-clint-project-DZ_ZplDv.js.map +1 -0
- package/dist/connect/index.html +3 -3
- package/dist/connect/ph-packages.json +1 -1
- package/dist/document-models/document-models.d.ts +1 -1
- package/dist/document-models/index.d.ts +1 -1
- package/dist/document-models/ph-clint-project/index.d.ts +2 -2
- package/dist/document-models/ph-clint-project/upgrades/index.d.ts +2 -2
- package/dist/document-models/ph-clint-project/upgrades/upgrade-manifest.d.ts +2 -2
- package/dist/document-models/ph-clint-project/upgrades/upgrade-manifest.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/actions.d.ts +28 -16
- package/dist/document-models/ph-clint-project/v1/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/actions.d.ts +29 -19
- package/dist/document-models/ph-clint-project/v1/gen/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/controller.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/controller.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/creators.d.ts +28 -18
- package/dist/document-models/ph-clint-project/v1/gen/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/deployment/actions.d.ts +6 -6
- package/dist/document-models/ph-clint-project/v1/gen/deployment/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/deployment/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/deployment/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/deployment/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/deployment/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/deployment/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/document-model.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/document-model.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/document-schema.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/document-schema.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/actions.d.ts +6 -6
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/error.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/external-skills/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/actions.d.ts +6 -54
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/creators.d.ts +2 -14
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/error.d.ts +1 -78
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/error.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/operations.d.ts +3 -15
- package/dist/document-models/ph-clint-project/v1/gen/features-mastra/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/actions.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/features-powerhouse/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/actions.d.ts +4 -4
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/features-routine/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/identity/actions.d.ts +5 -5
- package/dist/document-models/ph-clint-project/v1/gen/identity/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/identity/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/identity/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/identity/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/identity/error.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/identity/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/identity/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/index.d.ts +25 -20
- package/dist/document-models/ph-clint-project/v1/gen/index.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/actions.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/error.d.ts +13 -1
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/error.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/lifecycle/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/actions.d.ts +40 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/actions.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/creators.d.ts +11 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/creators.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/error.d.ts +79 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/error.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/operations.d.ts +18 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-agent-bindings/operations.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/actions.d.ts +28 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/actions.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/creators.d.ts +8 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/creators.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/error.d.ts +36 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/error.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/operations.d.ts +15 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-main-agent/operations.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/actions.d.ts +20 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/actions.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/creators.d.ts +6 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/creators.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/error.d.ts +41 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/error.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/operations.d.ts +13 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-models/operations.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/actions.d.ts +24 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/actions.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/creators.d.ts +7 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/creators.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/error.d.ts +46 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/error.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/operations.d.ts +14 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-profiles/operations.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/actions.d.ts +24 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/actions.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/creators.d.ts +7 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/creators.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/error.d.ts +51 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/error.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/operations.d.ts +14 -0
- package/dist/document-models/ph-clint-project/v1/gen/mastra-sub-agents/operations.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/gen/ph-factories.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/ph-factories.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/actions.d.ts +7 -7
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/error.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/powerhouse-packages/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/publishing/actions.d.ts +7 -7
- package/dist/document-models/ph-clint-project/v1/gen/publishing/actions.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/publishing/creators.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/publishing/creators.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/publishing/error.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/publishing/operations.d.ts +3 -3
- package/dist/document-models/ph-clint-project/v1/gen/publishing/operations.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/reducer.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/schema/index.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/schema/types.d.ts +214 -129
- package/dist/document-models/ph-clint-project/v1/gen/schema/types.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/schema/zod.d.ts +23 -7
- package/dist/document-models/ph-clint-project/v1/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/types.d.ts +5 -5
- package/dist/document-models/ph-clint-project/v1/gen/types.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/gen/utils.d.ts +2 -2
- package/dist/document-models/ph-clint-project/v1/gen/utils.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/hooks.d.ts +6 -3
- package/dist/document-models/ph-clint-project/v1/hooks.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/index.d.ts +6 -6
- package/dist/document-models/ph-clint-project/v1/module.d.ts +28 -16
- package/dist/document-models/ph-clint-project/v1/module.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/index.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/deployment.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/deployment.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/external-skills.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/external-skills.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-mastra.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-mastra.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-powerhouse.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-powerhouse.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-routine.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/features-routine.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/identity.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/identity.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/lifecycle.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/lifecycle.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-agent-bindings.d.ts +3 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-agent-bindings.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-main-agent.d.ts +3 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-main-agent.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-models.d.ts +3 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-models.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-profiles.d.ts +3 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-profiles.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-sub-agents.d.ts +3 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/mastra-sub-agents.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/src/reducers/powerhouse-packages.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/powerhouse-packages.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/publishing.d.ts +1 -1
- package/dist/document-models/ph-clint-project/v1/src/reducers/publishing.d.ts.map +1 -1
- package/dist/document-models/ph-clint-project/v1/tests/mastra-agent-bindings.test.d.ts +2 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-agent-bindings.test.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-main-agent.test.d.ts +2 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-main-agent.test.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-models.test.d.ts +2 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-models.test.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-profiles.test.d.ts +2 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-profiles.test.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-sub-agents.test.d.ts +2 -0
- package/dist/document-models/ph-clint-project/v1/tests/mastra-sub-agents.test.d.ts.map +1 -0
- package/dist/document-models/ph-clint-project/v1/utils.d.ts +2 -2
- package/dist/document-models/upgrade-manifests.d.ts +1 -1
- package/dist/document-models/upgrade-manifests.d.ts.map +1 -1
- package/dist/editors/ph-clint-project-editor/editor.d.ts.map +1 -1
- package/dist/node/document-models/index.mjs +1 -1
- package/dist/node/document-models/ph-clint-project/index.mjs +3 -3
- package/dist/node/{editor-mM5FSNXc.mjs → editor-DOw2BwlR.mjs} +825 -261
- package/dist/node/{editor-mM5FSNXc.mjs.map → editor-DOw2BwlR.mjs.map} +1 -1
- package/dist/node/editors/ph-clint-project-editor/module.mjs +1 -1
- package/dist/node/index.mjs +3 -3
- package/dist/node/index.mjs.map +1 -1
- package/dist/node/{module-DayL4J7r.mjs → module-DTtUZ4DR.mjs} +1970 -977
- package/dist/node/module-DTtUZ4DR.mjs.map +1 -0
- package/dist/node/{ph-clint-project-Btx_kiiQ.mjs → ph-clint-project-DFA4zHJv.mjs} +4 -6
- package/dist/node/ph-clint-project-DFA4zHJv.mjs.map +1 -0
- package/dist/style.css +27 -30
- package/package.json +1 -1
- package/dist/browser/module-DoAlHsjp.js.map +0 -1
- package/dist/browser/ph-clint-project-D634z5c5.js.map +0 -1
- package/dist/connect/assets/editor-DgkuaKuV.js +0 -2
- package/dist/connect/assets/editor-DgkuaKuV.js.map +0 -1
- package/dist/connect/assets/index-BSq-9kCR.css +0 -2
- package/dist/connect/assets/index-BXAErAWR.js.map +0 -1
- package/dist/connect/assets/ph-clint-project-BRYYVNTj.js +0 -758
- package/dist/connect/assets/ph-clint-project-BRYYVNTj.js.map +0 -1
- package/dist/node/module-DayL4J7r.mjs.map +0 -1
- package/dist/node/ph-clint-project-Btx_kiiQ.mjs.map +0 -1
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/esm-C3z6RsQv.js","assets/chunk-zsgVPwQN.js","assets/dist-ClzcOFHf.js","assets/preload-helper-rov5CBGT.js","assets/chunk-A7RFOIQ7-C_cZRzYs.js","assets/chunk-BTBUZ646-C-2npWfI.js","assets/chunk-EADU5A67-qrFIrs_P.js","assets/chunk-WGR4JCLS-9irtnUWa.js","assets/pg_dump-DpLFvU0N.js","assets/AddDriveModal-CBbXwG8S-CMtP_pYy.js","assets/connect-ClPSMjSP-B0m_vica.js","assets/clsx-BlWIxpLU.js","assets/src-8xf1ueaA-CW18mrFQ.js","assets/lz-string-CSbzFwDi.js","assets/esm-CIp61Ze4.js","assets/document-timeline-FWiQhfIq-ChabRuF_.js","assets/parseISO-D3w8UCNY.js","assets/dist-BzAXfaNf.js","assets/lodash.debounce-D2fhi-X6.js","assets/toast-DnODOv28-5sntLsMI.js","assets/i18next-LuHNh6Du.js","assets/ClearStorageModal-DwiCY6Lt-BX6HLKHK.js","assets/reactor-D1P2nU-G-Bgmic385.js","assets/connect.config-Cuh0hj_Q-DAwYt7T8.js","assets/module-Cfsr5pFp.js","assets/document-drive-CN2AY1E7-sMeVBFRc.js","assets/chunk-YKewjYmz-CpPGRMX8.js","assets/dist-CTgmb7N2-BAAYPyHP.js","assets/schemas-D47w5Bks-Cdf2Lkh9.js","assets/app-module-BbhoykB5-CCW5jONk.js","assets/dist-CYlqqmy32.js","assets/chunk-pbuEa-1d-BpCY5LR9.js","assets/document-editor-CHM7Pu4m-BkiwcAMk.js","assets/processor-module-CkuQiq7B-CKCqkgup.js","assets/subgraph-module-CU_-umq2-3iAEhINV.js","assets/vetra-package-VqptqKzx-BVTTpgDv.js","assets/dist-DWkgwOBk.js","assets/useTranslation-RtmqWZon.js","assets/CookiesPolicyModal-CTXUu4-8-CDv9A_Ye.js","assets/Trans-Blcalk6X.js","assets/CreateDocumentModal-CAld-5pv-CgcRndoo.js","assets/DebugSettingsModal-DeZ-x8H3-kFKY1yIP.js","assets/registerServiceWorker-1maoTQNT-C9dXFNd2.js","assets/DeleteDriveModal-B7T2CVIX-Ij3dGsPx.js","assets/DeleteItemModal-DJv71YQG-CVtPVgc9.js","assets/DisclaimerModal-Co13N7HH-DNe510Y-.js","assets/DriveSettingsModal-DmsUU0g3-CAC1UDo_.js","assets/ExportDocumentWithErrorsModal-DOV_UVlM-CuR2gzWI.js","assets/SettingsModal-BzvCwJLZ-YPWkTKes.js","assets/package-DwOpqBSI-CR11T_4r.js","assets/useRegistryPackages-BOX4NMAb-DQjVPJ3Z.js","assets/UpgradeDriveModal-BH4ecdCU-Ds9YPtnh.js","assets/InspectorModal-NoO3f3U7-CJAiPdEE.js","assets/pglite-seed-VlhY0n-A-h3YR9-PV.js","assets/MissingPackageModal-Df154H9n-CBAwY4mw.js","assets/load-C0mYtbHx-C7vYfEJ_.js","assets/editor-
|
|
2
|
-
import{r as e}from"./chunk-zsgVPwQN.js";import{c as t,d as n,f as r,k as i,l as a,m as o,mt as s,p as c,q as l,u,vt as d}from"./lz-string-CSbzFwDi.js";import{E as f,H as p,I as m,M as h,Mt as g,N as _,Ot as v,R as y,St as b,T as x,Tt as S,U as C,W as w,X as T,Y as E,Z as D,_t as ee,at as O,bt as k,ct as te,d as ne,dt as re,ft as A,g as ie,gt as ae,j as oe,mt as j,nt as se,o as ce,ot as M,ut as le,vt as N,wt as P}from"./dist-BzAXfaNf.js";import{t as F}from"./preload-helper-rov5CBGT.js";import{n as ue,r as de,t as I}from"./connect.config-Cuh0hj_Q-DAwYt7T8.js";import{a as fe,l as pe}from"./src-8xf1ueaA-CW18mrFQ.js";import{n as me,t as he}from"./toast-DnODOv28-5sntLsMI.js";import{t as ge}from"./i18next-LuHNh6Du.js";import{t as _e}from"./Trans-Blcalk6X.js";import{r as ve,t as ye}from"./useTranslation-RtmqWZon.js";import{c as be,f as xe,h as Se,i as
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/esm-C3z6RsQv.js","assets/chunk-zsgVPwQN.js","assets/dist-ClzcOFHf.js","assets/preload-helper-rov5CBGT.js","assets/chunk-A7RFOIQ7-C_cZRzYs.js","assets/chunk-BTBUZ646-C-2npWfI.js","assets/chunk-EADU5A67-qrFIrs_P.js","assets/chunk-WGR4JCLS-9irtnUWa.js","assets/pg_dump-DpLFvU0N.js","assets/AddDriveModal-CBbXwG8S-CMtP_pYy.js","assets/connect-ClPSMjSP-B0m_vica.js","assets/clsx-BlWIxpLU.js","assets/src-8xf1ueaA-CW18mrFQ.js","assets/lz-string-CSbzFwDi.js","assets/esm-CIp61Ze4.js","assets/document-timeline-FWiQhfIq-ChabRuF_.js","assets/parseISO-D3w8UCNY.js","assets/dist-BzAXfaNf.js","assets/lodash.debounce-D2fhi-X6.js","assets/toast-DnODOv28-5sntLsMI.js","assets/i18next-LuHNh6Du.js","assets/ClearStorageModal-DwiCY6Lt-BX6HLKHK.js","assets/reactor-D1P2nU-G-Bgmic385.js","assets/connect.config-Cuh0hj_Q-DAwYt7T8.js","assets/module-Cfsr5pFp.js","assets/document-drive-CN2AY1E7-sMeVBFRc.js","assets/chunk-YKewjYmz-CpPGRMX8.js","assets/dist-CTgmb7N2-BAAYPyHP.js","assets/schemas-D47w5Bks-Cdf2Lkh9.js","assets/app-module-BbhoykB5-CCW5jONk.js","assets/dist-CYlqqmy32.js","assets/chunk-pbuEa-1d-BpCY5LR9.js","assets/document-editor-CHM7Pu4m-BkiwcAMk.js","assets/processor-module-CkuQiq7B-CKCqkgup.js","assets/subgraph-module-CU_-umq2-3iAEhINV.js","assets/vetra-package-VqptqKzx-BVTTpgDv.js","assets/dist-DWkgwOBk.js","assets/useTranslation-RtmqWZon.js","assets/CookiesPolicyModal-CTXUu4-8-CDv9A_Ye.js","assets/Trans-Blcalk6X.js","assets/CreateDocumentModal-CAld-5pv-CgcRndoo.js","assets/DebugSettingsModal-DeZ-x8H3-kFKY1yIP.js","assets/registerServiceWorker-1maoTQNT-C9dXFNd2.js","assets/DeleteDriveModal-B7T2CVIX-Ij3dGsPx.js","assets/DeleteItemModal-DJv71YQG-CVtPVgc9.js","assets/DisclaimerModal-Co13N7HH-DNe510Y-.js","assets/DriveSettingsModal-DmsUU0g3-CAC1UDo_.js","assets/ExportDocumentWithErrorsModal-DOV_UVlM-CuR2gzWI.js","assets/SettingsModal-BzvCwJLZ-YPWkTKes.js","assets/package-DwOpqBSI-CR11T_4r.js","assets/useRegistryPackages-BOX4NMAb-DQjVPJ3Z.js","assets/UpgradeDriveModal-BH4ecdCU-Ds9YPtnh.js","assets/InspectorModal-NoO3f3U7-CJAiPdEE.js","assets/pglite-seed-VlhY0n-A-h3YR9-PV.js","assets/MissingPackageModal-Df154H9n-CBAwY4mw.js","assets/load-C0mYtbHx-C7vYfEJ_.js","assets/editor-CQqCB-3d.js","assets/ph-clint-project-DZ_ZplDv.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{r as e}from"./chunk-zsgVPwQN.js";import{c as t,d as n,f as r,k as i,l as a,m as o,mt as s,p as c,q as l,u,vt as d}from"./lz-string-CSbzFwDi.js";import{E as f,H as p,I as m,M as h,Mt as g,N as _,Ot as v,R as y,St as b,T as x,Tt as S,U as C,W as w,X as T,Y as E,Z as D,_t as ee,at as O,bt as k,ct as te,d as ne,dt as re,ft as A,g as ie,gt as ae,j as oe,mt as j,nt as se,o as ce,ot as M,ut as le,vt as N,wt as P}from"./dist-BzAXfaNf.js";import{t as F}from"./preload-helper-rov5CBGT.js";import{n as ue,r as de,t as I}from"./connect.config-Cuh0hj_Q-DAwYt7T8.js";import{a as fe,l as pe}from"./src-8xf1ueaA-CW18mrFQ.js";import{n as me,t as he}from"./toast-DnODOv28-5sntLsMI.js";import{t as ge}from"./i18next-LuHNh6Du.js";import{t as _e}from"./Trans-Blcalk6X.js";import{r as ve,t as ye}from"./useTranslation-RtmqWZon.js";import{c as be,f as xe,h as Se,i as L,n as R,p as Ce,r as we,s as Te,t as Ee}from"./module-Cfsr5pFp.js";import{t as De}from"./registerServiceWorker-1maoTQNT-C9dXFNd2.js";import{n as Oe}from"./document-timeline-FWiQhfIq-ChabRuF_.js";import{A as ke,C as Ae,E as je,O as Me,_ as Ne,b as Pe,c as Fe,k as Ie,m as Le,r as Re,u as ze,x as Be,y as Ve}from"./connect-ClPSMjSP-B0m_vica.js";import{t as He}from"./dist-DyIElqdF.js";import{$ as Ue,$n as We,$t as Ge,A as Ke,An as qe,At as Je,B as Ye,Bn as Xe,Bt as Ze,C as Qe,Cn as $e,Ct as et,D as tt,Dn as nt,Dt as rt,E as it,En as at,Et as ot,F as st,Fn as ct,Ft as lt,G as ut,Gn as dt,Gt as ft,H as pt,Hn as mt,Ht as ht,I as gt,In as _t,It as vt,J as yt,Jn as bt,Jt as xt,K as St,Kn as Ct,Kt as wt,L as Tt,Ln as Et,Lt as Dt,M as Ot,Mn as kt,Mt as At,N as jt,Nn as Mt,Nt,O as Pt,On as Ft,Ot as It,P as Lt,Pn as Rt,Pt as zt,Q as Bt,Qn as Vt,Qt as Ht,R as Ut,Rn as Wt,Rt as Gt,S as Kt,Sn as qt,St as Jt,T as Yt,Tn as Xt,Tt as Zt,U as Qt,Un as $t,Ut as en,V as tn,Vn as nn,Vt as rn,W as an,Wn as on,Wt as sn,X as cn,Xn as ln,Xt as un,Y as dn,Yn as fn,Yt as pn,Z as mn,Zn as hn,Zt as gn,_ as _n,_n as vn,_t as yn,a as bn,an as xn,ar as Sn,at as Cn,b as wn,bn as Tn,bt as En,c as Dn,cn as On,cr as kn,ct as An,d as jn,dn as Mn,dt as Nn,en as Pn,er as Fn,et as In,f as Ln,fn as Rn,ft as zn,g as Bn,gn as Vn,gt as Hn,h as Un,hn as Wn,ht as Gn,i as Kn,in as qn,ir as Jn,it as Yn,j as Xn,jn as Zn,jt as Qn,k as $n,kn as er,kt as tr,l as nr,ln as rr,lt as ir,m as ar,mn as or,mt as sr,n as cr,nn as lr,nr as ur,nt as dr,o as fr,on as pr,or as mr,ot as hr,p as gr,pn as _r,pt as vr,q as yr,qn as br,qt as xr,r as Sr,rn as Cr,rr as wr,rt as Tr,s as Er,sn as Dr,sr as Or,st as kr,t as Ar,tn as jr,tr as Mr,tt as Nr,u as Pr,un as Fr,ut as Ir,v as Lr,vn as Rr,vt as zr,w as Br,wn as Vr,wt as Hr,x as Ur,xn as Wr,xt as Gr,y as Kr,yn as qr,yt as Jr,z as Yr,zn as Xr,zt as Zr}from"./ph-clint-project-DZ_ZplDv.js";import*as z from"react";import Qr,{Component as $r,StrictMode as ei,Suspense as ti,createContext as ni,createElement as ri,lazy as B,useCallback as ii,useContext as ai,useEffect as V,useLayoutEffect as oi,useMemo as si,useRef as ci,useState as li,useSyncExternalStore as ui}from"react";import{Fragment as di,jsx as H,jsxs as U}from"react/jsx-runtime";import*as fi from"react-dom";import{createRoot as pi}from"react-dom/client";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var mi=class e extends Error{response;request;constructor(t,n){let r=`${e.extractMessage(t)}: ${JSON.stringify({response:t,request:n})}`;super(r),Object.setPrototypeOf(this,e.prototype),this.response=t,this.request=n,typeof Error.captureStackTrace==`function`&&Error.captureStackTrace(this,e)}static extractMessage(e){return e.errors?.[0]?.message??`GraphQL Error (Code: ${String(e.status)})`}},hi=e=>e.toUpperCase(),gi=e=>typeof e==`function`?e():e,_i=(e,t)=>e.map((e,n)=>[e,t[n]]),vi=e=>{let t={};return e instanceof Headers?t=yi(e):Array.isArray(e)?e.forEach(([e,n])=>{e&&n!==void 0&&(t[e]=n)}):e&&(t=e),t},yi=e=>{let t={};return e.forEach((e,n)=>{t[n]=e}),t},bi=e=>{try{let t=e();return Si(t)?t.catch(e=>xi(e)):t}catch(e){return xi(e)}},xi=e=>e instanceof Error?e:Error(String(e)),Si=e=>typeof e==`object`&&!!e&&`then`in e&&typeof e.then==`function`&&`catch`in e&&typeof e.catch==`function`&&`finally`in e&&typeof e.finally==`function`,Ci=e=>{throw Error(`Unhandled case: ${String(e)}`)},wi=e=>typeof e==`object`&&!!e&&!Array.isArray(e),Ti=(e,t)=>e.documents?e:{documents:e,requestHeaders:t,signal:void 0},Ei=(e,t,n)=>e.query?e:{query:e,variables:t,requestHeaders:n,signal:void 0};function Di(e){return`"${e.replace(Oi,ki)}"`}var Oi=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function ki(e){return Ai[e.charCodeAt(0)]}var Ai=`\\u0000.\\u0001.\\u0002.\\u0003.\\u0004.\\u0005.\\u0006.\\u0007.\\b.\\t.\\n.\\u000B.\\f.\\r.\\u000E.\\u000F.\\u0010.\\u0011.\\u0012.\\u0013.\\u0014.\\u0015.\\u0016.\\u0017.\\u0018.\\u0019.\\u001A.\\u001B.\\u001C.\\u001D.\\u001E.\\u001F...\\"..........................................................\\\\...................................\\u007F.\\u0080.\\u0081.\\u0082.\\u0083.\\u0084.\\u0085.\\u0086.\\u0087.\\u0088.\\u0089.\\u008A.\\u008B.\\u008C.\\u008D.\\u008E.\\u008F.\\u0090.\\u0091.\\u0092.\\u0093.\\u0094.\\u0095.\\u0096.\\u0097.\\u0098.\\u0099.\\u009A.\\u009B.\\u009C.\\u009D.\\u009E.\\u009F`.split(`.`),ji=Object.freeze({});function Mi(e,t,i=r){let s=new Map;for(let e of Object.values(n))s.set(e,Ni(t,e));let l,u=Array.isArray(e),d=[e],f=-1,p=[],m=e,h,g,_=[],v=[];do{f++;let e=f===d.length,n=e&&p.length!==0;if(e){if(h=v.length===0?void 0:_[_.length-1],m=g,g=v.pop(),n)if(u){m=m.slice();let e=0;for(let[t,n]of p){let r=t-e;n===null?(m.splice(r,1),e++):m[r]=n}}else{m={...m};for(let[e,t]of p)m[e]=t}f=l.index,d=l.keys,p=l.edits,u=l.inArray,l=l.prev}else if(g){if(h=u?f:d[f],m=g[h],m==null)continue;_.push(h)}let r;if(!Array.isArray(m)){if(c(m)||o(!1,`Invalid AST Node: ${a(m)}.`),r=(e?s.get(m.kind)?.leave:s.get(m.kind)?.enter)?.call(t,m,h,g,_,v),r===ji)break;if(r===!1){if(!e){_.pop();continue}}else if(r!==void 0&&(p.push([h,r]),!e))if(c(r))m=r;else{_.pop();continue}}r===void 0&&n&&p.push([h,m]),e?_.pop():(l={inArray:u,index:f,keys:d,edits:p,prev:l},u=Array.isArray(m),d=u?m:i[m.kind]??[],f=-1,p=[],g&&v.push(g),g=m)}while(l!==void 0);return p.length===0?e:p[p.length-1][1]}function Ni(e,t){let n=e[t];return typeof n==`object`?n:typeof n==`function`?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}function Pi(e){return Mi(e,Ii)}var Fi=80,Ii={Name:{leave:e=>e.value},Variable:{leave:e=>`$`+e.name},Document:{leave:e=>W(e.definitions,`
|
|
3
3
|
|
|
4
|
-
`)},OperationDefinition:{leave(e){let t=
|
|
4
|
+
`)},OperationDefinition:{leave(e){let t=Ri(e.variableDefinitions)?K(`(
|
|
5
5
|
`,W(e.variableDefinitions,`
|
|
6
6
|
`),`
|
|
7
7
|
)`):K(`(`,W(e.variableDefinitions,`, `),`)`),n=K(``,e.description,`
|
|
8
8
|
`)+W([e.operation,W([e.name,t]),W(e.directives,` `)],` `);return(n===`query`?``:n+` `)+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r,description:i})=>K(``,i,`
|
|
9
|
-
`)+e+`: `+t+K(` = `,n)+K(` `,W(r,` `))},SelectionSet:{leave:({selections:e})=>G(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let a=K(``,e,`: `)+t,o=a+K(`(`,W(n,`, `),`)`);return o.length>
|
|
10
|
-
`,
|
|
9
|
+
`)+e+`: `+t+K(` = `,n)+K(` `,W(r,` `))},SelectionSet:{leave:({selections:e})=>G(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let a=K(``,e,`: `)+t,o=a+K(`(`,W(n,`, `),`)`);return o.length>Fi&&(o=a+K(`(
|
|
10
|
+
`,Li(W(n,`
|
|
11
11
|
`)),`
|
|
12
12
|
)`)),W([o,W(r,` `),i],` `)}},Argument:{leave:({name:e,value:t})=>e+`: `+t},FragmentSpread:{leave:({name:e,directives:t})=>`...`+e+K(` `,W(t,` `))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>W([`...`,K(`on `,e),W(t,` `),n],` `)},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i,description:a})=>K(``,a,`
|
|
13
|
-
`)+`fragment ${e}${K(`(`,W(n,`, `),`)`)} on ${t} ${K(``,W(r,` `),` `)}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?u(e):
|
|
13
|
+
`)+`fragment ${e}${K(`(`,W(n,`, `),`)`)} on ${t} ${K(``,W(r,` `),` `)}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?u(e):Di(e)},BooleanValue:{leave:({value:e})=>e?`true`:`false`},NullValue:{leave:()=>`null`},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>`[`+W(e,`, `)+`]`},ObjectValue:{leave:({fields:e})=>`{`+W(e,`, `)+`}`},ObjectField:{leave:({name:e,value:t})=>e+`: `+t},Directive:{leave:({name:e,arguments:t})=>`@`+e+K(`(`,W(t,`, `),`)`)},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>`[`+e+`]`},NonNullType:{leave:({type:e})=>e+`!`},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>K(``,e,`
|
|
14
14
|
`)+W([`schema`,W(t,` `),G(n)],` `)},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+`: `+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>K(``,e,`
|
|
15
15
|
`)+W([`scalar`,t,W(n,` `)],` `)},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>K(``,e,`
|
|
16
16
|
`)+W([`type`,t,K(`implements `,W(n,` & `)),W(r,` `),G(i)],` `)},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>K(``,e,`
|
|
17
|
-
`)+t+(
|
|
18
|
-
`,
|
|
17
|
+
`)+t+(Ri(n)?K(`(
|
|
18
|
+
`,Li(W(n,`
|
|
19
19
|
`)),`
|
|
20
20
|
)`):K(`(`,W(n,`, `),`)`))+`: `+r+K(` `,W(i,` `))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>K(``,e,`
|
|
21
21
|
`)+W([t+`: `+n,K(`= `,r),W(i,` `)],` `)},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>K(``,e,`
|
|
@@ -24,29 +24,29 @@ import{r as e}from"./chunk-zsgVPwQN.js";import{c as t,d as n,f as r,k as i,l as
|
|
|
24
24
|
`)+W([`enum`,t,W(n,` `),G(r)],` `)},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>K(``,e,`
|
|
25
25
|
`)+W([t,W(n,` `)],` `)},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>K(``,e,`
|
|
26
26
|
`)+W([`input`,t,W(n,` `),G(r)],` `)},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,repeatable:r,locations:i})=>K(``,e,`
|
|
27
|
-
`)+`directive @`+t+(
|
|
28
|
-
`,
|
|
27
|
+
`)+`directive @`+t+(Ri(n)?K(`(
|
|
28
|
+
`,Li(W(n,`
|
|
29
29
|
`)),`
|
|
30
30
|
)`):K(`(`,W(n,`, `),`)`))+(r?` repeatable`:``)+` on `+W(i,` | `)},SchemaExtension:{leave:({directives:e,operationTypes:t})=>W([`extend schema`,W(e,` `),G(t)],` `)},ScalarTypeExtension:{leave:({name:e,directives:t})=>W([`extend scalar`,e,W(t,` `)],` `)},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>W([`extend type`,e,K(`implements `,W(t,` & `)),W(n,` `),G(r)],` `)},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>W([`extend interface`,e,K(`implements `,W(t,` & `)),W(n,` `),G(r)],` `)},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>W([`extend union`,e,W(t,` `),K(`= `,W(n,` | `))],` `)},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>W([`extend enum`,e,W(t,` `),G(n)],` `)},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>W([`extend input`,e,W(t,` `),G(n)],` `)},TypeCoordinate:{leave:({name:e})=>e},MemberCoordinate:{leave:({name:e,memberName:t})=>W([e,K(`.`,t)])},ArgumentCoordinate:{leave:({name:e,fieldName:t,argumentName:n})=>W([e,K(`.`,t),K(`(`,n,`:)`)])},DirectiveCoordinate:{leave:({name:e})=>W([`@`,e])},DirectiveArgumentCoordinate:{leave:({name:e,argumentName:t})=>W([`@`,e,K(`(`,t,`:)`)])}};function W(e,t=``){return e?.filter(e=>e).join(t)??``}function G(e){return K(`{
|
|
31
|
-
`,
|
|
31
|
+
`,Li(W(e,`
|
|
32
32
|
`)),`
|
|
33
|
-
}`)}function K(e,t,n=``){return t!=null&&t!==``?e+t+n:``}function
|
|
34
|
-
`))}function
|
|
35
|
-
`))??!1}var oi=`Accept`,si=`Content-Type`,ci=`application/json`,li=`application/graphql-response+json`,ui=e=>e.replace(/([\s,]|#[^\n\r]+)+/g,` `).trim(),di=e=>{let t=e.toLowerCase();return t.includes(li)||t.includes(ci)},fi=e=>{try{if(Array.isArray(e))return{_tag:`Batch`,executionResults:e.map(pi)};if(Gr(e))return{_tag:`Single`,executionResult:pi(e)};throw Error(`Invalid execution result: result is not object or array. \nGot:\n${String(e)}`)}catch(e){return e}},pi=e=>{if(typeof e!=`object`||!e)throw Error(`Invalid execution result: result is not object`);let t,n,r;if(`errors`in e){if(!Gr(e.errors)&&!Array.isArray(e.errors))throw Error(`Invalid execution result: errors is not plain object OR array`);t=e.errors}if(`data`in e){if(!Gr(e.data)&&e.data!==null)throw Error(`Invalid execution result: data is not plain object`);n=e.data}if(`extensions`in e){if(!Gr(e.extensions))throw Error(`Invalid execution result: extensions is not plain object`);r=e.extensions}return{data:n,errors:t,extensions:r}},mi=e=>e._tag===`Batch`?e.executionResults.some(hi):hi(e.executionResult),hi=e=>Array.isArray(e.errors)?e.errors.length>0:!!e.errors,gi=e=>typeof e==`object`&&!!e&&`kind`in e&&e.kind===n.OPERATION_DEFINITION,_i=e=>{let t,n=e.definitions.filter(gi);return n.length===1&&(t=n[0].name?.value),t},vi=e=>{let t=!1,n=e.definitions.filter(gi);return n.length===1&&(t=n[0].operation===`mutation`),t},yi=(e,n)=>{let r=typeof e==`string`||`kind`in e?e:String(e),i=typeof r==`string`?r:ti(r),a=!1,o;if(n)return{expression:i,isMutation:a,operationName:o};let s=Vr(()=>typeof r==`string`?t(r):r);return s instanceof Error?{expression:i,isMutation:a,operationName:o}:(o=_i(s),a=vi(s),{expression:i,operationName:o,isMutation:a})},bi=JSON,xi=async e=>{let t={...e,method:e.request._tag===`Single`?e.request.document.isMutation?`POST`:Ir(e.method??`post`):e.request.hasMutations?`POST`:Ir(e.method??`post`),fetchOptions:{...e.fetchOptions,errorPolicy:e.fetchOptions.errorPolicy??`none`}},n=await wi(t.method)(t),r=await n.text(),i;try{i=Ci(r,n.headers.get(si),e.fetchOptions.jsonSerializer??bi)}catch(e){i=e}let a={status:n.status,headers:n.headers,body:r};if(!n.ok)return i instanceof Error?new Fr({...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables}):new Fr(i._tag===`Batch`?{...i.executionResults,...a}:{...i.executionResult,...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables});if(i instanceof Error)throw i;if(mi(i)&&t.fetchOptions.errorPolicy===`none`)return new Fr(i._tag===`Batch`?{...i.executionResults,...a}:{...i.executionResult,...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables});switch(i._tag){case`Single`:return{...a,...Si(t)(i.executionResult)};case`Batch`:return{...a,data:i.executionResults.map(Si(t))};default:Wr(i)}},Si=e=>t=>({extensions:t.extensions,data:t.data,errors:e.fetchOptions.errorPolicy===`all`?t.errors:void 0}),Ci=(e,t,n)=>t&&di(t)?fi(n.parse(e)):fi(e),wi=e=>async t=>{let n=new Headers(t.headers),r=null,i;n.has(oi)||n.set(oi,[li,ci].join(`, `)),e===`POST`?(i=(t.fetchOptions.jsonSerializer??bi).stringify(Ti(t)),typeof i==`string`&&!n.has(si)&&n.set(si,ci)):r=Ei(t);let a={method:e,headers:n,body:i,...t.fetchOptions},o=new URL(t.url),s=a;if(t.middleware){let{url:e,...n}=await Promise.resolve(t.middleware({...a,url:t.url,operationName:t.request._tag===`Single`?t.request.document.operationName:void 0,variables:t.request.variables}));o=new URL(e),s=n}return r&&r.forEach((e,t)=>{o.searchParams.append(t,e)}),await(t.fetch??fetch)(o,s)},Ti=e=>{switch(e.request._tag){case`Single`:return{query:e.request.document.expression,variables:e.request.variables,operationName:e.request.document.operationName};case`Batch`:return Rr(e.request.query,e.request.variables??[]).map(([e,t])=>({query:e,variables:t}));default:throw Wr(e.request)}},Ei=e=>{let t=e.fetchOptions.jsonSerializer??bi,n=new URLSearchParams;switch(e.request._tag){case`Single`:return n.append(`query`,ui(e.request.document.expression)),e.request.variables&&n.append(`variables`,t.stringify(e.request.variables)),e.request.document.operationName&&n.append(`operationName`,e.request.document.operationName),n;case`Batch`:{let r=e.request.variables?.map(e=>t.stringify(e))??[],i=Rr(e.request.query.map(ui),r).map(([e,t])=>({query:e,variables:t}));return n.append(`query`,t.stringify(i)),n}default:throw Wr(e.request)}},Di=class{url;requestConfig;constructor(e,t={}){this.url=e,this.requestConfig=t}rawRequest=async(...e)=>{let[t,n,r]=e,i=qr(t,n,r),{headers:a,fetch:o=globalThis.fetch,method:s=`POST`,requestMiddleware:c,responseMiddleware:l,excludeOperationName:u,...d}=this.requestConfig,{url:f}=this;i.signal!==void 0&&(d.signal=i.signal);let p=yi(i.query,u),m=await xi({url:f,request:{_tag:`Single`,document:p,variables:i.variables},headers:{...zr(Lr(a)),...zr(i.requestHeaders)},fetch:o,method:s,fetchOptions:d,middleware:c});if(l&&await l(m,{operationName:p.operationName,variables:n,url:this.url}),m instanceof Error)throw m;return m};async request(e,...t){let[n,r]=t,i=ki(e,n,r),{headers:a,fetch:o=globalThis.fetch,method:s=`POST`,requestMiddleware:c,responseMiddleware:l,excludeOperationName:u,...d}=this.requestConfig,{url:f}=this;i.signal!==void 0&&(d.signal=i.signal);let p=yi(i.document,u),m=await xi({url:f,request:{_tag:`Single`,document:p,variables:i.variables},headers:{...zr(Lr(a)),...zr(i.requestHeaders)},fetch:o,method:s,fetchOptions:d,middleware:c});if(l&&await l(m,{operationName:p.operationName,variables:i.variables,url:this.url}),m instanceof Error)throw m;return m.data}async batchRequests(e,t){let n=Kr(e,t),{headers:r,excludeOperationName:i,...a}=this.requestConfig;n.signal!==void 0&&(a.signal=n.signal);let o=n.documents.map(({document:e})=>yi(e,i)),s=o.map(({expression:e})=>e),c=o.some(({isMutation:e})=>e),l=n.documents.map(({variables:e})=>e),u=await xi({url:this.url,request:{_tag:`Batch`,operationName:void 0,query:s,hasMutations:c,variables:l},headers:{...zr(Lr(r)),...zr(n.requestHeaders)},fetch:this.requestConfig.fetch??globalThis.fetch,method:this.requestConfig.method||`POST`,fetchOptions:a,middleware:this.requestConfig.requestMiddleware});if(this.requestConfig.responseMiddleware&&await this.requestConfig.responseMiddleware(u,{operationName:void 0,variables:l,url:this.url}),u instanceof Error)throw u;return u.data}setHeaders(e){return this.requestConfig.headers=e,this}setHeader(e,t){let{headers:n}=this.requestConfig;return n?n[e]=t:this.requestConfig.headers={[e]:t},this}setEndpoint(e){return this.url=e,this}};async function Oi(e,t,...n){let r=Ai(e,t,...n);return new Di(r.url).request({...r})}var ki=(e,t,n)=>e.document?e:{document:e,variables:t,requestHeaders:n,signal:void 0},Ai=(e,t,...n)=>{let[r,i]=n;return typeof e==`string`?{url:e,document:t,variables:r,requestHeaders:i,signal:void 0}:e},ji=(e,...t)=>e.reduce((e,n,r)=>`${e}${n}${r in t?String(t[r]):``}`,``);ge.use(ve).init({resources:{en:{code:`en`,name:`English`,translation:{common:{cancel:`Cancel`,delete:`Delete`,continue:`Continue`,empty:`Empty`,create:`Create`,save:`Save`,export:`Export`,reload:`Reload`,reloadConnect:`Click here to reload Connect`},searchbar:{placeholder:`Search Powerhouse`,filterLabel:`File type`},folderView:{sections:{folders:{title:`Folders`,empty:`No folders 🗂️`},documents:{title:`Documents and files`,empty:`No documents or files 📄`}}},files:{options:{switchboardLink:`Switchboard Link`}},modals:{deleteItem:{folder:{header:`Delete “{{item}}” folder?`,body:`Are you sure you want to delete this folder? All files and subfolders within it will be removed.`},file:{header:`Delete “{{item}}” file?`,body:`Are you sure you want to delete this file?`}},deleteDrive:{title:`Delete "{{label}}" drive?`,body:`Are you sure you want to delete this drive? All files and subfolders within it will be removed. Do you want to proceed?`,inputPlaceholder:`Enter drive name...`},upgradeDrive:{header:`Upgrade to cloud drive`,body:`You are moving files from a private to a shared drive. These files will become accessible to others in the shared drive.Do you want to proceed?`},createDocument:{header:`Create a new document`,placeholder:`Document name`},connectSettings:{title:`Settings`,body:`These settings will apply to all drives.`,clearStorage:{button:`Clear Storage`,description:`Delete previous session data`,confirmation:{title:`Clear Storage`,body:`Are you sure you want to clear the storage? This will remove all previous session data.`,clearButton:`Clear Storage`}},enabledDocumentTypes:{title:`Document Models`,description:`Documents enabled`,allSelected:`All documents are selected`}},exportDocumentWithErrors:{title:`Your document contains errors`,body:`Your document contains structure errors. Do you want to export it anyway?`},disclaimer:{title:`Disclaimer`,body:`All content provided herein our website, hyperlinked sites, associated applications, forums, blogs, social media accounts and other platforms (“Site”) is for your general information only, procured from third party sources. We make no warranties of any kind in relation to our content, including but not limited to accuracy and updatedness. No part of the content that we provide constitutes financial advice, legal advice or any other form of advice meant for your specific reliance for any purpose. Any use or reliance on our content is solely at your own risk and discretion. You should conduct your own research, review, analyse and verify our content before relying on them. Trading is a highly risky activity that can lead to major losses, please therefore consult your financial advisor before making any decision. No content on our Site is meant to be a solicitation or offer.`},cookiesPolicy:{title:`Cookies Policy`,body:`<subtitle>Use of Cookies and Similar Technologies</subtitle><p>The Site is using cookies. Cookies are small text files that are placed on your computer by websites that you visit. They are widely used in order to make websites work, or work more efficiently, as well as to provide information to the owners of the site. Cookies are typically stored on your computer´s hard drive.Information collected from cookies is used by us to evaluate the effectiveness of our Site and analyze trends. The information collected from cookies allows us to determine such things as which parts of the Site are most visited and difficulties our visitors may experience in accessing the SIte. With this knowledge, we can improve the quality of your experience on the Site by recognizing and delivering more of the most desired features and information, as well as by resolving access difficulties.</p><p>We use third party service providers, to assist us in better understanding the use of our Site. Our service providers will place cookies on the hard drive of your computer (or use similar technologies) and will receive information that we select that will educate us on such things as how visitors navigate around our Site. This information is aggregated to provide statistical data about our users browsing actions and patterns, and does not personally identify individuals. This information may include:</p><p>Computer or mobile device information, Website usage information, such as:<list></p><bullet>Page views,</bullet><bullet>Button clicks,</bullet><bullet>Input form changes (without the values being entered),</bullet><bullet>Errors.</bullet></list><p>Our service providers analyses this information and provides us with aggregate reports. The information and analysis provided by our service providers will be used to assist us in better understanding our visitors interests in our Site and how to better serve those interests. If you want to avoid using cookies altogether, you can disable cookies in your browser. However, disabling cookies might make it impossible for you to use certain features of the Site. Your use of the Site with a browser that is configured to accept cookies constitutes an acceptance of our and third-party cookies.</p>`}},notifications:{deleteDriveSuccess:`Drive successfully deleted`,deleteFolderSuccess:`Folder deleted`,fileDeleteSuccess:`File deleted`,addDriveSuccess:`New drive successfully added`,driveSyncSuccess:`Drive synced successfully`,driveSyncError:`Error synchronizing drive {{drive}}`,driveSyncConflict:`Conflict error detected in {{drive}}`,reloadApp:`It seems like you're running an outdated version of the app. Please reload Connect to get the latest version.`},footer:{cookiePolicy:`Cookie Policy`,termsOfUse:`Terms of Use`,disclaimer:`Disclaimer`,builtWith:`Built with <icon /> Powerhouse`},cookieBanner:{message:`This website uses cookies for analytic purposes only. Cookies are anonymous and do not link to user data. We collect information to improve the user experience and validate UI changes. You can still use the page without cookies. For more information, please read our <a>cookies policy.</a>`,accept:`Accept configured cookies`,reject:`Reject all cookies`,cookies:{functional:`Functional cookies`,analytics:`Analytics cookies`}}}}},fallbackLng:`en`,debug:!1,interpolation:{escapeValue:!1}}).catch(e=>{console.error(e)});function q(){return q=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},q.apply(this,arguments)}var J;(function(e){e.Pop=`POP`,e.Push=`PUSH`,e.Replace=`REPLACE`})(J||={});var Mi=`popstate`;function Ni(e){e===void 0&&(e={});function t(e,t){let{pathname:n,search:r,hash:i}=e.location;return Li(``,{pathname:n,search:r,hash:i},t.state&&t.state.usr||null,t.state&&t.state.key||`default`)}function n(e,t){return typeof t==`string`?t:Ri(t)}return Bi(t,n,null,e)}function Y(e,t){if(e===!1||e==null)throw Error(t)}function Pi(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function Fi(){return Math.random().toString(36).substr(2,8)}function Ii(e,t){return{usr:e.state,key:e.key,idx:t}}function Li(e,t,n,r){return n===void 0&&(n=null),q({pathname:typeof e==`string`?e:e.pathname,search:``,hash:``},typeof t==`string`?zi(t):t,{state:n,key:t&&t.key||r||Fi()})}function Ri(e){let{pathname:t=`/`,search:n=``,hash:r=``}=e;return n&&n!==`?`&&(t+=n.charAt(0)===`?`?n:`?`+n),r&&r!==`#`&&(t+=r.charAt(0)===`#`?r:`#`+r),t}function zi(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Bi(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=J.Pop,c=null,l=u();l??(l=0,o.replaceState(q({},o.state,{idx:l}),``));function u(){return(o.state||{idx:null}).idx}function d(){s=J.Pop;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=J.Push;let r=Li(h.location,e,t);n&&n(r,e),l=u()+1;let d=Ii(r,l),f=h.createHref(r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=J.Replace;let r=Li(h.location,e,t);n&&n(r,e),l=u();let i=Ii(r,l),d=h.createHref(r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){let t=i.location.origin===`null`?i.location.href:i.location.origin,n=typeof e==`string`?e:Ri(e);return n=n.replace(/ $/,`%20`),Y(t,`No window.location.(origin|href) available to create URL for href: `+n),new URL(n,t)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(Mi,d),c=e,()=>{i.removeEventListener(Mi,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}var X;(function(e){e.data=`data`,e.deferred=`deferred`,e.redirect=`redirect`,e.error=`error`})(X||={});var Vi=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`children`]);function Hi(e){return e.index===!0}function Ui(e,t,n,r){return n===void 0&&(n=[]),r===void 0&&(r={}),e.map((e,i)=>{let a=[...n,String(i)],o=typeof e.id==`string`?e.id:a.join(`-`);if(Y(e.index!==!0||!e.children,`Cannot specify children on an index route`),Y(!r[o],`Found a route id collision on id "`+o+`". Route id's must be globally unique within Data Router usages`),Hi(e)){let n=q({},e,t(e),{id:o});return r[o]=n,n}else{let n=q({},e,t(e),{id:o,children:void 0});return r[o]=n,e.children&&(n.children=Ui(e.children,t,a,r)),n}})}function Wi(e,t,n){return n===void 0&&(n=`/`),Gi(e,t,n,!1)}function Gi(e,t,n,r){let i=la((typeof t==`string`?zi(t):t).pathname||`/`,n);if(i==null)return null;let a=qi(e);Yi(a);let o=null;for(let e=0;o==null&&e<a.length;++e){let t=ca(i);o=aa(a[e],t,r)}return o}function Ki(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],handle:n.handle}}function qi(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r=``);let i=(e,i,a)=>{let o={relativePath:a===void 0?e.path||``:a,caseSensitive:e.caseSensitive===!0,childrenIndex:i,route:e};o.relativePath.startsWith(`/`)&&(Y(o.relativePath.startsWith(r),`Absolute route path "`+o.relativePath+`" nested under path `+(`"`+r+`" is not valid. An absolute child route path `)+`must start with the combined path of all its parent routes.`),o.relativePath=o.relativePath.slice(r.length));let s=va([r,o.relativePath]),c=n.concat(o);e.children&&e.children.length>0&&(Y(e.index!==!0,`Index routes must not have child routes. Please remove `+(`all child routes from route path "`+s+`".`)),qi(e.children,t,c,s)),!(e.path==null&&!e.index)&&t.push({path:s,score:ra(s,e.index),routesMeta:c})};return e.forEach((e,t)=>{var n;if(e.path===``||!((n=e.path)!=null&&n.includes(`?`)))i(e,t);else for(let n of Ji(e.path))i(e,t,n)}),t}function Ji(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=Ji(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function Yi(e){e.sort((e,t)=>e.score===t.score?ia(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var Xi=/^:[\w-]+$/,Zi=3,Qi=2,$i=1,ea=10,ta=-2,na=e=>e===`*`;function ra(e,t){let n=e.split(`/`),r=n.length;return n.some(na)&&(r+=ta),t&&(r+=Qi),n.filter(e=>!na(e)).reduce((e,t)=>e+(Xi.test(t)?Zi:t===``?$i:ea),r)}function ia(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function aa(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u=oa({path:s.relativePath,caseSensitive:s.caseSensitive,end:c},l),d=s.route;if(!u&&c&&n&&!r[r.length-1].route.index&&(u=oa({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!u)return null;Object.assign(i,u.params),o.push({params:i,pathname:va([a,u.pathname]),pathnameBase:ya(va([a,u.pathnameBase])),route:d}),u.pathnameBase!==`/`&&(a=va([a,u.pathnameBase]))}return o}function oa(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=sa(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,t,n)=>{let{paramName:r,isOptional:i}=t;if(r===`*`){let e=s[n]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let c=s[n];return i&&!c?e[r]=void 0:e[r]=(c||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function sa(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Pi(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "`+e+`" will be treated as if it were `+(`"`+e.replace(/\*$/,`/*`)+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+(`please change the route path to "`+e.replace(/\*$/,`/*`)+`".`));let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n)=>(r.push({paramName:t,isOptional:n!=null}),n?`/?([^\\/]+)?`:`/([^\\/]+)`));return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function ca(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return Pi(!1,`The URL path "`+e+`" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent `+(`encoding (`+t+`).`)),e}}function la(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}var ua=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,da=e=>ua.test(e);function fa(e,t){t===void 0&&(t=`/`);let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?zi(e):e,a;if(n)if(da(n))a=n;else{if(n.includes(`//`)){let e=n;n=n.replace(/\/\/+/g,`/`),Pi(!1,`Pathnames cannot have embedded double slashes - normalizing `+(e+` -> `+n))}a=n.startsWith(`/`)?pa(n.substring(1),`/`):pa(n,t)}else a=t;return{pathname:a,search:ba(r),hash:xa(i)}}function pa(e,t){let n=t.replace(/\/+$/,``).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function ma(e,t,n,r){return`Cannot include a '`+e+`' character in a manually specified `+("`to."+t+"` field ["+JSON.stringify(r)+`]. Please separate it out to the `)+("`to."+n+"` field. Alternatively you may provide the full path as ")+`a string in <Link to="..."> and the router will parse it for you.`}function ha(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function ga(e,t){let n=ha(e);return t?n.map((e,t)=>t===n.length-1?e.pathname:e.pathnameBase):n.map(e=>e.pathnameBase)}function _a(e,t,n,r){r===void 0&&(r=!1);let i;typeof e==`string`?i=zi(e):(i=q({},e),Y(!i.pathname||!i.pathname.includes(`?`),ma(`?`,`pathname`,`search`,i)),Y(!i.pathname||!i.pathname.includes(`#`),ma(`#`,`pathname`,`hash`,i)),Y(!i.search||!i.search.includes(`#`),ma(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=fa(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var va=e=>e.join(`/`).replace(/\/\/+/g,`/`),ya=e=>e.replace(/\/+$/,``).replace(/^\/*/,`/`),ba=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,xa=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,Sa=class{constructor(e,t,n,r){r===void 0&&(r=!1),this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Ca(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}var wa=[`post`,`put`,`patch`,`delete`],Ta=new Set(wa),Ea=[`get`,...wa],Da=new Set(Ea),Oa=new Set([301,302,303,307,308]),ka=new Set([307,308]),Aa={state:`idle`,location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},ja={state:`idle`,data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Ma={state:`unblocked`,proceed:void 0,reset:void 0,location:void 0},Na=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Pa=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),Fa=`remix-router-transitions`;function Ia(e){let t=e.window?e.window:typeof window<`u`?window:void 0,n=t!==void 0&&t.document!==void 0&&t.document.createElement!==void 0,r=!n;Y(e.routes.length>0,`You must provide a non-empty routes array to createRouter`);let i;if(e.mapRouteProperties)i=e.mapRouteProperties;else if(e.detectErrorBoundary){let t=e.detectErrorBoundary;i=e=>({hasErrorBoundary:t(e)})}else i=Pa;let a={},o=Ui(e.routes,i,void 0,a),s,c=e.basename||`/`,l=e.dataStrategy||Ya,u=e.patchRoutesOnNavigation,d=q({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),f=null,p=new Set,m=null,h=null,g=null,_=e.hydrationData!=null,v=Wi(o,e.history.location,c),y=!1,b=null;if(v==null&&!u){let t=Z(404,{pathname:e.history.location.pathname}),{matches:n,route:r}=lo(o);v=n,b={[r.id]:t}}v&&!e.hydrationData&&We(v,o,e.history.location.pathname).active&&(v=null);let x;if(!v){if(x=!1,v=[],d.v7_partialHydration){let t=We(null,o,e.history.location.pathname);t.active&&t.matches&&(y=!0,v=t.matches)}}else if(v.some(e=>e.route.lazy))x=!1;else if(!v.some(e=>e.route.loader))x=!0;else if(d.v7_partialHydration){let t=e.hydrationData?e.hydrationData.loaderData:null,n=e.hydrationData?e.hydrationData.errors:null;if(n){let e=v.findIndex(e=>n[e.route.id]!==void 0);x=v.slice(0,e+1).every(e=>!Ha(e.route,t,n))}else x=v.every(e=>!Ha(e.route,t,n))}else x=e.hydrationData!=null;let S,C={historyAction:e.history.action,location:e.history.location,matches:v,initialized:x,navigation:Aa,restoreScrollPosition:e.hydrationData==null?null:!1,preventScrollReset:!1,revalidation:`idle`,loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||b,fetchers:new Map,blockers:new Map},w=J.Pop,T=!1,E,D=!1,ee=new Map,O=null,k=!1,te=!1,ne=[],re=new Set,A=new Map,ie=0,ae=-1,oe=new Map,j=new Set,se=new Map,ce=new Map,M=new Set,le=new Map,N=new Map,P;function F(){if(f=e.history.listen(t=>{let{action:n,location:r,delta:i}=t;if(P){P(),P=void 0;return}Pi(N.size===0||i!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let a=Le({currentLocation:C.location,nextLocation:r,historyAction:n});if(a&&i!=null){let t=new Promise(e=>{P=e});e.history.go(i*-1),Ie(a,{state:`blocked`,location:r,proceed(){Ie(a,{state:`proceeding`,proceed:void 0,reset:void 0,location:r}),t.then(()=>e.history.go(i))},reset(){let e=new Map(C.blockers);e.set(a,Ma),I({blockers:e})}});return}return he(n,r)}),n){Mo(t,ee);let e=()=>No(t,ee);t.addEventListener(`pagehide`,e),O=()=>t.removeEventListener(`pagehide`,e)}return C.initialized||he(J.Pop,C.location,{initialHydration:!0}),S}function ue(){f&&f(),O&&O(),p.clear(),E&&E.abort(),C.fetchers.forEach((e,t)=>Oe(t)),C.blockers.forEach((e,t)=>Fe(t))}function de(e){return p.add(e),()=>p.delete(e)}function I(e,t){t===void 0&&(t={}),C=q({},C,e);let n=[],r=[];d.v7_fetcherPersist&&C.fetchers.forEach((e,t)=>{e.state===`idle`&&(M.has(t)?r.push(t):n.push(t))}),M.forEach(e=>{!C.fetchers.has(e)&&!A.has(e)&&r.push(e)}),[...p].forEach(e=>e(C,{deletedFetchers:r,viewTransitionOpts:t.viewTransitionOpts,flushSync:t.flushSync===!0})),d.v7_fetcherPersist?(n.forEach(e=>C.fetchers.delete(e)),r.forEach(e=>Oe(e))):r.forEach(e=>M.delete(e))}function fe(t,n,r){let{flushSync:i}=r===void 0?{}:r,a=C.actionData!=null&&C.navigation.formMethod!=null&&$(C.navigation.formMethod)&&C.navigation.state===`loading`&&t.state?._isRedirect!==!0,c;c=n.actionData?Object.keys(n.actionData).length>0?n.actionData:null:a?C.actionData:null;let l=n.loaderData?oo(C.loaderData,n.loaderData,n.matches||[],n.errors):C.loaderData,u=C.blockers;u.size>0&&(u=new Map(u),u.forEach((e,t)=>u.set(t,Ma)));let d=T===!0||C.navigation.formMethod!=null&&$(C.navigation.formMethod)&&t.state?._isRedirect!==!0;s&&=(o=s,void 0),k||w===J.Pop||(w===J.Push?e.history.push(t,t.state):w===J.Replace&&e.history.replace(t,t.state));let f;if(w===J.Pop){let e=ee.get(C.location.pathname);e&&e.has(t.pathname)?f={currentLocation:C.location,nextLocation:t}:ee.has(t.pathname)&&(f={currentLocation:t,nextLocation:C.location})}else if(D){let e=ee.get(C.location.pathname);e?e.add(t.pathname):(e=new Set([t.pathname]),ee.set(C.location.pathname,e)),f={currentLocation:C.location,nextLocation:t}}I(q({},n,{actionData:c,loaderData:l,historyAction:w,location:t,initialized:!0,navigation:Aa,revalidation:`idle`,restoreScrollPosition:Ue(t,n.matches||C.matches),preventScrollReset:d,blockers:u}),{viewTransitionOpts:f,flushSync:i===!0}),w=J.Pop,T=!1,D=!1,k=!1,te=!1,ne=[]}async function pe(t,n){if(typeof t==`number`){e.history.go(t);return}let r=Ra(C.location,C.matches,c,d.v7_prependBasename,t,d.v7_relativeSplatPath,n?.fromRouteId,n?.relative),{path:i,submission:a,error:o}=za(d.v7_normalizeFormMethod,!1,r,n),s=C.location,l=Li(C.location,i,n&&n.state);l=q({},l,e.history.encodeLocation(l));let u=n&&n.replace!=null?n.replace:void 0,f=J.Push;u===!0?f=J.Replace:u===!1||a!=null&&$(a.formMethod)&&a.formAction===C.location.pathname+C.location.search&&(f=J.Replace);let p=n&&`preventScrollReset`in n?n.preventScrollReset===!0:void 0,m=(n&&n.flushSync)===!0,h=Le({currentLocation:s,nextLocation:l,historyAction:f});if(h){Ie(h,{state:`blocked`,location:l,proceed(){Ie(h,{state:`proceeding`,proceed:void 0,reset:void 0,location:l}),pe(t,n)},reset(){let e=new Map(C.blockers);e.set(h,Ma),I({blockers:e})}});return}return await he(f,l,{submission:a,pendingError:o,preventScrollReset:p,replace:n&&n.replace,enableViewTransition:n&&n.viewTransition,flushSync:m})}function me(){if(Te(),I({revalidation:`loading`}),C.navigation.state!==`submitting`){if(C.navigation.state===`idle`){he(C.historyAction,C.location,{startUninterruptedRevalidation:!0});return}he(w||C.historyAction,C.navigation.location,{overrideNavigation:C.navigation,enableViewTransition:D===!0})}}async function he(t,n,r){E&&E.abort(),E=null,w=t,k=(r&&r.startUninterruptedRevalidation)===!0,He(C.location,C.matches),T=(r&&r.preventScrollReset)===!0,D=(r&&r.enableViewTransition)===!0;let i=s||o,a=r&&r.overrideNavigation,l=r!=null&&r.initialHydration&&C.matches&&C.matches.length>0&&!y?C.matches:Wi(i,n,c),u=(r&&r.flushSync)===!0;if(l&&C.initialized&&!te&&po(C.location,n)&&!(r&&r.submission&&$(r.submission.formMethod))){fe(n,{matches:l},{flushSync:u});return}let d=We(l,i,n.pathname);if(d.active&&d.matches&&(l=d.matches),!l){let{error:e,notFoundMatches:t,route:r}=Re(n.pathname);fe(n,{matches:t,loaderData:{},errors:{[r.id]:e}},{flushSync:u});return}E=new AbortController;let f=to(e.history,n,E.signal,r&&r.submission),p;if(r&&r.pendingError)p=[co(l).route.id,{type:X.error,error:r.pendingError}];else if(r&&r.submission&&$(r.submission.formMethod)){let t=await ge(f,n,r.submission,l,d.active,{replace:r.replace,flushSync:u});if(t.shortCircuited)return;if(t.pendingActionResult){let[e,r]=t.pendingActionResult;if(Q(r)&&Ca(r.error)&&r.error.status===404){E=null,fe(n,{matches:t.matches,loaderData:{},errors:{[e]:r.error}});return}}l=t.matches||l,p=t.pendingActionResult,a=Do(n,r.submission),u=!1,d.active=!1,f=to(e.history,f.url,f.signal)}let{shortCircuited:m,matches:h,loaderData:g,errors:_}=await _e(f,n,l,d.active,a,r&&r.submission,r&&r.fetcherSubmission,r&&r.replace,r&&r.initialHydration===!0,u,p);m||(E=null,fe(n,q({matches:h||l},so(p),{loaderData:g,errors:_})))}async function ge(t,n,r,i,a,o){if(o===void 0&&(o={}),Te(),I({navigation:Oo(n,r)},{flushSync:o.flushSync===!0}),a){let e=await Ge(i,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){let t=co(e.partialMatches).route.id;return{matches:e.partialMatches,pendingActionResult:[t,{type:X.error,error:e.error}]}}else if(e.matches)i=e.matches;else{let{notFoundMatches:e,error:t,route:r}=Re(n.pathname);return{matches:e,pendingActionResult:[r.id,{type:X.error,error:t}]}}}let s,l=To(i,n);if(!l.route.action&&!l.route.lazy)s={type:X.error,error:Z(405,{method:t.method,pathname:n.pathname,routeId:l.route.id})};else if(s=(await L(`action`,C,t,[l],i,null))[l.route.id],t.signal.aborted)return{shortCircuited:!0};if(go(s)){let n;return n=o&&o.replace!=null?o.replace:eo(s.response.headers.get(`Location`),new URL(t.url),c,e.history)===C.location.pathname+C.location.search,await Ce(t,s,!0,{submission:r,replace:n}),{shortCircuited:!0}}if(ho(s))throw Z(400,{type:`defer-action`});if(Q(s)){let e=co(i,l.route.id);return(o&&o.replace)!==!0&&(w=J.Push),{matches:i,pendingActionResult:[e.route.id,s]}}return{matches:i,pendingActionResult:[l.route.id,s]}}async function _e(t,n,r,i,a,l,u,f,p,m,h){let g=a||Do(n,l),_=l||u||Eo(g),v=!k&&(!d.v7_partialHydration||!p);if(i){if(v){let e=ve(h);I(q({navigation:g},e===void 0?{}:{actionData:e}),{flushSync:m})}let e=await Ge(r,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){let t=co(e.partialMatches).route.id;return{matches:e.partialMatches,loaderData:{},errors:{[t]:e.error}}}else if(e.matches)r=e.matches;else{let{error:e,notFoundMatches:t,route:r}=Re(n.pathname);return{matches:t,loaderData:{},errors:{[r.id]:e}}}}let y=s||o,[b,x]=Va(e.history,C,r,_,n,d.v7_partialHydration&&p===!0,d.v7_skipActionErrorRevalidation,te,ne,re,M,se,j,y,c,h);if(ze(e=>!(r&&r.some(t=>t.route.id===e))||b&&b.some(t=>t.route.id===e)),ae=++ie,b.length===0&&x.length===0){let e=Me();return fe(n,q({matches:r,loaderData:{},errors:h&&Q(h[1])?{[h[0]]:h[1].error}:null},so(h),e?{fetchers:new Map(C.fetchers)}:{}),{flushSync:m}),{shortCircuited:!0}}if(v){let e={};if(!i){e.navigation=g;let t=ve(h);t!==void 0&&(e.actionData=t)}x.length>0&&(e.fetchers=ye(x)),I(e,{flushSync:m})}x.forEach(e=>{Ae(e.key),e.controller&&A.set(e.key,e.controller)});let S=()=>x.forEach(e=>Ae(e.key));E&&E.signal.addEventListener(`abort`,S);let{loaderResults:w,fetcherResults:T}=await we(C,r,b,x,t);if(t.signal.aborted)return{shortCircuited:!0};E&&E.signal.removeEventListener(`abort`,S),x.forEach(e=>A.delete(e.key));let D=uo(w);if(D)return await Ce(t,D.result,!0,{replace:f}),{shortCircuited:!0};if(D=uo(T),D)return j.add(D.key),await Ce(t,D.result,!0,{replace:f}),{shortCircuited:!0};let{loaderData:ee,errors:O}=ao(C,r,w,h,x,T,le);le.forEach((e,t)=>{e.subscribe(n=>{(n||e.done)&&le.delete(t)})}),d.v7_partialHydration&&p&&C.errors&&(O=q({},C.errors,O));let oe=Me(),ce=Ne(ae),N=oe||ce||x.length>0;return q({matches:r,loaderData:ee,errors:O},N?{fetchers:new Map(C.fetchers)}:{})}function ve(e){if(e&&!Q(e[1]))return{[e[0]]:e[1].data};if(C.actionData)return Object.keys(C.actionData).length===0?null:C.actionData}function ye(e){return e.forEach(e=>{let t=C.fetchers.get(e.key),n=ko(void 0,t?t.data:void 0);C.fetchers.set(e.key,n)}),new Map(C.fetchers)}function be(e,t,n,i){if(r)throw Error(`router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.`);Ae(e);let a=(i&&i.flushSync)===!0,l=s||o,u=Ra(C.location,C.matches,c,d.v7_prependBasename,n,d.v7_relativeSplatPath,t,i?.relative),f=Wi(l,u,c),p=We(f,l,u);if(p.active&&p.matches&&(f=p.matches),!f){R(e,t,Z(404,{pathname:u}),{flushSync:a});return}let{path:m,submission:h,error:g}=za(d.v7_normalizeFormMethod,!0,u,i);if(g){R(e,t,g,{flushSync:a});return}let _=To(f,m),v=(i&&i.preventScrollReset)===!0;if(h&&$(h.formMethod)){xe(e,t,m,_,f,p.active,a,v,h);return}se.set(e,{routeId:t,path:m}),Se(e,t,m,_,f,p.active,a,v,h)}async function xe(t,n,r,i,a,l,u,f,p){Te(),se.delete(t);function m(e){return!e.route.action&&!e.route.lazy?(R(t,n,Z(405,{method:p.formMethod,pathname:r,routeId:n}),{flushSync:u}),!0):!1}if(!l&&m(i))return;Ee(t,Ao(p,C.fetchers.get(t)),{flushSync:u});let h=new AbortController,g=to(e.history,r,h.signal,p);if(l){let e=await Ge(a,new URL(g.url).pathname,g.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){R(t,n,e.error,{flushSync:u});return}else if(!e.matches){R(t,n,Z(404,{pathname:r}),{flushSync:u});return}else if(a=e.matches,i=To(a,r),m(i))return}A.set(t,h);let _=ie,v=(await L(`action`,C,g,[i],a,t))[i.route.id];if(g.signal.aborted){A.get(t)===h&&A.delete(t);return}if(d.v7_fetcherPersist&&M.has(t)){if(go(v)||Q(v)){Ee(t,jo(void 0));return}}else{if(go(v))if(A.delete(t),ae>_){Ee(t,jo(void 0));return}else return j.add(t),Ee(t,ko(p)),Ce(g,v,!1,{fetcherSubmission:p,preventScrollReset:f});if(Q(v)){R(t,n,v.error);return}}if(ho(v))throw Z(400,{type:`defer-action`});let y=C.navigation.location||C.location,b=to(e.history,y,h.signal),x=s||o,S=C.navigation.state===`idle`?C.matches:Wi(x,C.navigation.location,c);Y(S,`Didn't find any matches after fetcher action`);let T=++ie;oe.set(t,T);let D=ko(p,v.data);C.fetchers.set(t,D);let[ee,O]=Va(e.history,C,S,p,y,!1,d.v7_skipActionErrorRevalidation,te,ne,re,M,se,j,x,c,[i.route.id,v]);O.filter(e=>e.key!==t).forEach(e=>{let t=e.key,n=C.fetchers.get(t),r=ko(void 0,n?n.data:void 0);C.fetchers.set(t,r),Ae(t),e.controller&&A.set(t,e.controller)}),I({fetchers:new Map(C.fetchers)});let k=()=>O.forEach(e=>Ae(e.key));h.signal.addEventListener(`abort`,k);let{loaderResults:ce,fetcherResults:N}=await we(C,S,ee,O,b);if(h.signal.aborted)return;h.signal.removeEventListener(`abort`,k),oe.delete(t),A.delete(t),O.forEach(e=>A.delete(e.key));let P=uo(ce);if(P)return Ce(b,P.result,!1,{preventScrollReset:f});if(P=uo(N),P)return j.add(P.key),Ce(b,P.result,!1,{preventScrollReset:f});let{loaderData:F,errors:ue}=ao(C,S,ce,void 0,O,N,le);if(C.fetchers.has(t)){let e=jo(v.data);C.fetchers.set(t,e)}Ne(T),C.navigation.state===`loading`&&T>ae?(Y(w,`Expected pending action`),E&&E.abort(),fe(C.navigation.location,{matches:S,loaderData:F,errors:ue,fetchers:new Map(C.fetchers)})):(I({errors:ue,loaderData:oo(C.loaderData,F,S,ue),fetchers:new Map(C.fetchers)}),te=!1)}async function Se(t,n,r,i,a,o,s,c,l){let u=C.fetchers.get(t);Ee(t,ko(l,u?u.data:void 0),{flushSync:s});let d=new AbortController,f=to(e.history,r,d.signal);if(o){let e=await Ge(a,new URL(f.url).pathname,f.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){R(t,n,e.error,{flushSync:s});return}else if(e.matches)a=e.matches,i=To(a,r);else{R(t,n,Z(404,{pathname:r}),{flushSync:s});return}}A.set(t,d);let p=ie,m=(await L(`loader`,C,f,[i],a,t))[i.route.id];if(ho(m)&&(m=await Co(m,f.signal,!0)||m),A.get(t)===d&&A.delete(t),!f.signal.aborted){if(M.has(t)){Ee(t,jo(void 0));return}if(go(m))if(ae>p){Ee(t,jo(void 0));return}else{j.add(t),await Ce(f,m,!1,{preventScrollReset:c});return}if(Q(m)){R(t,n,m.error);return}Y(!ho(m),`Unhandled fetcher deferred data`),Ee(t,jo(m.data))}}async function Ce(r,i,a,o){let{submission:s,fetcherSubmission:l,preventScrollReset:u,replace:d}=o===void 0?{}:o;i.response.headers.has(`X-Remix-Revalidate`)&&(te=!0);let f=i.response.headers.get(`Location`);Y(f,`Expected a Location header on the redirect Response`),f=eo(f,new URL(r.url),c,e.history);let p=Li(C.location,f,{_isRedirect:!0});if(n){let n=!1;if(i.response.headers.has(`X-Remix-Reload-Document`))n=!0;else if(Na.test(f)){let r=e.history.createURL(f);n=r.origin!==t.location.origin||la(r.pathname,c)==null}if(n){d?t.location.replace(f):t.location.assign(f);return}}E=null;let m=d===!0||i.response.headers.has(`X-Remix-Replace`)?J.Replace:J.Push,{formMethod:h,formAction:g,formEncType:_}=C.navigation;!s&&!l&&h&&g&&_&&(s=Eo(C.navigation));let v=s||l;ka.has(i.response.status)&&v&&$(v.formMethod)?await he(m,p,{submission:q({},v,{formAction:f}),preventScrollReset:u||T,enableViewTransition:a?D:void 0}):await he(m,p,{overrideNavigation:Do(p,s),fetcherSubmission:l,preventScrollReset:u||T,enableViewTransition:a?D:void 0})}async function L(e,t,n,r,o,s){let u,f={};try{u=await Xa(l,e,t,n,r,o,s,a,i)}catch(e){return r.forEach(t=>{f[t.route.id]={type:X.error,error:e}}),f}for(let[e,t]of Object.entries(u))if(mo(t)){let r=t.result;f[e]={type:X.redirect,response:$a(r,n,e,o,c,d.v7_relativeSplatPath)}}else f[e]=await Qa(t);return f}async function we(t,n,r,i,a){let o=t.matches,s=L(`loader`,t,a,r,n,null),c=Promise.all(i.map(async n=>{if(n.matches&&n.match&&n.controller){let r=(await L(`loader`,t,to(e.history,n.path,n.controller.signal),[n.match],n.matches,n.key))[n.match.route.id];return{[n.key]:r}}else return Promise.resolve({[n.key]:{type:X.error,error:Z(404,{pathname:n.path})}})})),l=await s,u=(await c).reduce((e,t)=>Object.assign(e,t),{});return await Promise.all([xo(n,l,a.signal,o,t.loaderData),So(n,u,i)]),{loaderResults:l,fetcherResults:u}}function Te(){te=!0,ne.push(...ze()),se.forEach((e,t)=>{A.has(t)&&re.add(t),Ae(t)})}function Ee(e,t,n){n===void 0&&(n={}),C.fetchers.set(e,t),I({fetchers:new Map(C.fetchers)},{flushSync:(n&&n.flushSync)===!0})}function R(e,t,n,r){r===void 0&&(r={});let i=co(C.matches,t);Oe(e),I({errors:{[i.route.id]:n},fetchers:new Map(C.fetchers)},{flushSync:(r&&r.flushSync)===!0})}function De(e){return ce.set(e,(ce.get(e)||0)+1),M.has(e)&&M.delete(e),C.fetchers.get(e)||ja}function Oe(e){let t=C.fetchers.get(e);A.has(e)&&!(t&&t.state===`loading`&&oe.has(e))&&Ae(e),se.delete(e),oe.delete(e),j.delete(e),d.v7_fetcherPersist&&M.delete(e),re.delete(e),C.fetchers.delete(e)}function ke(e){let t=(ce.get(e)||0)-1;t<=0?(ce.delete(e),M.add(e),d.v7_fetcherPersist||Oe(e)):ce.set(e,t),I({fetchers:new Map(C.fetchers)})}function Ae(e){let t=A.get(e);t&&(t.abort(),A.delete(e))}function je(e){for(let t of e){let e=jo(De(t).data);C.fetchers.set(t,e)}}function Me(){let e=[],t=!1;for(let n of j){let r=C.fetchers.get(n);Y(r,`Expected fetcher: `+n),r.state===`loading`&&(j.delete(n),e.push(n),t=!0)}return je(e),t}function Ne(e){let t=[];for(let[n,r]of oe)if(r<e){let e=C.fetchers.get(n);Y(e,`Expected fetcher: `+n),e.state===`loading`&&(Ae(n),oe.delete(n),t.push(n))}return je(t),t.length>0}function Pe(e,t){let n=C.blockers.get(e)||Ma;return N.get(e)!==t&&N.set(e,t),n}function Fe(e){C.blockers.delete(e),N.delete(e)}function Ie(e,t){let n=C.blockers.get(e)||Ma;Y(n.state===`unblocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`proceeding`||n.state===`blocked`&&t.state===`unblocked`||n.state===`proceeding`&&t.state===`unblocked`,`Invalid blocker state transition: `+n.state+` -> `+t.state);let r=new Map(C.blockers);r.set(e,t),I({blockers:r})}function Le(e){let{currentLocation:t,nextLocation:n,historyAction:r}=e;if(N.size===0)return;N.size>1&&Pi(!1,`A router only supports one blocker at a time`);let i=Array.from(N.entries()),[a,o]=i[i.length-1],s=C.blockers.get(a);if(!(s&&s.state===`proceeding`)&&o({currentLocation:t,nextLocation:n,historyAction:r}))return a}function Re(e){let t=Z(404,{pathname:e}),{matches:n,route:r}=lo(s||o);return ze(),{notFoundMatches:n,route:r,error:t}}function ze(e){let t=[];return le.forEach((n,r)=>{(!e||e(r))&&(n.cancel(),t.push(r),le.delete(r))}),t}function Be(e,t,n){if(m=e,g=t,h=n||null,!_&&C.navigation===Aa){_=!0;let e=Ue(C.location,C.matches);e!=null&&I({restoreScrollPosition:e})}return()=>{m=null,g=null,h=null}}function Ve(e,t){return h&&h(e,t.map(e=>Ki(e,C.loaderData)))||e.key}function He(e,t){if(m&&g){let n=Ve(e,t);m[n]=g()}}function Ue(e,t){if(m){let n=Ve(e,t),r=m[n];if(typeof r==`number`)return r}return null}function We(e,t,n){if(u){if(!e)return{active:!0,matches:Gi(t,n,c,!0)||[]};if(Object.keys(e[0].params).length>0)return{active:!0,matches:Gi(t,n,c,!0)}}return{active:!1,matches:null}}async function Ge(e,t,n,r){if(!u)return{type:`success`,matches:e};let l=e;for(;;){let e=s==null,d=s||o,f=a;try{await u({signal:n,path:t,matches:l,fetcherKey:r,patch:(e,t)=>{n.aborted||Ka(e,t,d,f,i)}})}catch(e){return{type:`error`,error:e,partialMatches:l}}finally{e&&!n.aborted&&(o=[...o])}if(n.aborted)return{type:`aborted`};let p=Wi(d,t,c);if(p)return{type:`success`,matches:p};let m=Gi(d,t,c,!0);if(!m||l.length===m.length&&l.every((e,t)=>e.route.id===m[t].route.id))return{type:`success`,matches:null};l=m}}function Ke(e){a={},s=Ui(e,i,void 0,a)}function qe(e,t){let n=s==null;Ka(e,t,s||o,a,i),n&&(o=[...o],I({}))}return S={get basename(){return c},get future(){return d},get state(){return C},get routes(){return o},get window(){return t},initialize:F,subscribe:de,enableScrollRestoration:Be,navigate:pe,fetch:be,revalidate:me,createHref:t=>e.history.createHref(t),encodeLocation:t=>e.history.encodeLocation(t),getFetcher:De,deleteFetcher:ke,dispose:ue,getBlocker:Pe,deleteBlocker:Fe,patchRoutes:qe,_internalFetchControllers:A,_internalActiveDeferreds:le,_internalSetRoutes:Ke},S}function La(e){return e!=null&&(`formData`in e&&e.formData!=null||`body`in e&&e.body!==void 0)}function Ra(e,t,n,r,i,a,o,s){let c,l;if(o){c=[];for(let e of t)if(c.push(e),e.route.id===o){l=e;break}}else c=t,l=t[t.length-1];let u=_a(i||`.`,ga(c,a),la(e.pathname,n)||e.pathname,s===`path`);if(i??(u.search=e.search,u.hash=e.hash),(i==null||i===``||i===`.`)&&l){let e=wo(u.search);if(l.route.index&&!e)u.search=u.search?u.search.replace(/^\?/,`?index&`):`?index`;else if(!l.route.index&&e){let e=new URLSearchParams(u.search),t=e.getAll(`index`);e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();u.search=n?`?`+n:``}}return r&&n!==`/`&&(u.pathname=u.pathname===`/`?n:va([n,u.pathname])),Ri(u)}function za(e,t,n,r){if(!r||!La(r))return{path:n};if(r.formMethod&&!bo(r.formMethod))return{path:n,error:Z(405,{method:r.formMethod})};let i=()=>({path:n,error:Z(400,{type:`invalid-body`})}),a=r.formMethod||`get`,o=e?a.toUpperCase():a.toLowerCase(),s=fo(n);if(r.body!==void 0){if(r.formEncType===`text/plain`){if(!$(o))return i();let e=typeof r.body==`string`?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((e,t)=>{let[n,r]=t;return``+e+n+`=`+r+`
|
|
36
|
-
`},``):String(r.body);return{path:n,submission:{formMethod:o,formAction:s,formEncType:r.formEncType,formData:void 0,json:void 0,text:e}}}else if(r.formEncType===`application/json`){if(!$(o))return i();try{let e=typeof r.body==`string`?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:o,formAction:s,formEncType:r.formEncType,formData:void 0,json:e,text:void 0}}}catch{return i()}}}Y(typeof FormData==`function`,`FormData is not available in this environment`);let c,l;if(r.formData)c=no(r.formData),l=r.formData;else if(r.body instanceof FormData)c=no(r.body),l=r.body;else if(r.body instanceof URLSearchParams)c=r.body,l=ro(c);else if(r.body==null)c=new URLSearchParams,l=new FormData;else try{c=new URLSearchParams(r.body),l=ro(c)}catch{return i()}let u={formMethod:o,formAction:s,formEncType:r&&r.formEncType||`application/x-www-form-urlencoded`,formData:l,json:void 0,text:void 0};if($(u.formMethod))return{path:n,submission:u};let d=zi(n);return t&&d.search&&wo(d.search)&&c.append(`index`,``),d.search=`?`+c,{path:Ri(d),submission:u}}function Ba(e,t,n){n===void 0&&(n=!1);let r=e.findIndex(e=>e.route.id===t);return r>=0?e.slice(0,n?r+1:r):e}function Va(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h){let g=h?Q(h[1])?h[1].error:h[1].data:void 0,_=e.createURL(t.location),v=e.createURL(i),y=n;a&&t.errors?y=Ba(n,Object.keys(t.errors)[0],!0):h&&Q(h[1])&&(y=Ba(n,h[0]));let b=h?h[1].statusCode:void 0,x=o&&b&&b>=400,S=y.filter((e,n)=>{let{route:i}=e;if(i.lazy)return!0;if(i.loader==null)return!1;if(a)return Ha(i,t.loaderData,t.errors);if(Ua(t.loaderData,t.matches[n],e)||c.some(t=>t===e.route.id))return!0;let o=t.matches[n],l=e;return Ga(e,q({currentUrl:_,currentParams:o.params,nextUrl:v,nextParams:l.params},r,{actionResult:g,actionStatus:b,defaultShouldRevalidate:x?!1:s||_.pathname+_.search===v.pathname+v.search||_.search!==v.search||Wa(o,l)}))}),C=[];return d.forEach((e,i)=>{if(a||!n.some(t=>t.route.id===e.routeId)||u.has(i))return;let o=Wi(p,e.path,m);if(!o){C.push({key:i,routeId:e.routeId,path:e.path,matches:null,match:null,controller:null});return}let c=t.fetchers.get(i),d=To(o,e.path),h=!1;f.has(i)?h=!1:l.has(i)?(l.delete(i),h=!0):h=c&&c.state!==`idle`&&c.data===void 0?s:Ga(d,q({currentUrl:_,currentParams:t.matches[t.matches.length-1].params,nextUrl:v,nextParams:n[n.length-1].params},r,{actionResult:g,actionStatus:b,defaultShouldRevalidate:x?!1:s})),h&&C.push({key:i,routeId:e.routeId,path:e.path,matches:o,match:d,controller:new AbortController})}),[S,C]}function Ha(e,t,n){if(e.lazy)return!0;if(!e.loader)return!1;let r=t!=null&&t[e.id]!==void 0,i=n!=null&&n[e.id]!==void 0;return!r&&i?!1:typeof e.loader==`function`&&e.loader.hydrate===!0?!0:!r&&!i}function Ua(e,t,n){let r=!t||n.route.id!==t.route.id,i=e[n.route.id]===void 0;return r||i}function Wa(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith(`*`)&&e.params[`*`]!==t.params[`*`]}function Ga(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n==`boolean`)return n}return t.defaultShouldRevalidate}function Ka(e,t,n,r,i){let a;if(e){let t=r[e];Y(t,`No route found to patch children into: routeId = `+e),t.children||=[],a=t.children}else a=n;let o=Ui(t.filter(e=>!a.some(t=>qa(e,t))),i,[e||`_`,`patch`,String(a?.length||`0`)],r);a.push(...o)}function qa(e,t){return`id`in e&&`id`in t&&e.id===t.id?!0:e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive?(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children.every((e,n)=>t.children?.some(t=>qa(e,t))):!1}async function Ja(e,t,n){if(!e.lazy)return;let r=await e.lazy();if(!e.lazy)return;let i=n[e.id];Y(i,`No route found in manifest`);let a={};for(let e in r){let t=i[e]!==void 0&&e!==`hasErrorBoundary`;Pi(!t,`Route "`+i.id+`" has a static property "`+e+`" defined but its lazy function is also returning a value for this property. `+(`The lazy route property "`+e+`" will be ignored.`)),!t&&!Vi.has(e)&&(a[e]=r[e])}Object.assign(i,a),Object.assign(i,q({},t(i),{lazy:void 0}))}async function Ya(e){let{matches:t}=e,n=t.filter(e=>e.shouldLoad);return(await Promise.all(n.map(e=>e.resolve()))).reduce((e,t,r)=>Object.assign(e,{[n[r].route.id]:t}),{})}async function Xa(e,t,n,r,i,a,o,s,c,l){let u=a.map(e=>e.route.lazy?Ja(e.route,c,s):void 0),d=await e({matches:a.map((e,n)=>{let a=u[n],o=i.some(t=>t.route.id===e.route.id);return q({},e,{shouldLoad:o,resolve:async n=>(n&&r.method===`GET`&&(e.route.lazy||e.route.loader)&&(o=!0),o?Za(t,r,e,a,n,l):Promise.resolve({type:X.data,result:void 0}))})}),request:r,params:a[0].params,fetcherKey:o,context:l});try{await Promise.all(u)}catch{}return d}async function Za(e,t,n,r,i,a){let o,s,c=r=>{let o,c=new Promise((e,t)=>o=t);s=()=>o(),t.signal.addEventListener(`abort`,s);let l=i=>typeof r==`function`?r({request:t,params:n.params,context:a},...i===void 0?[]:[i]):Promise.reject(Error(`You cannot call the handler for a route which defines a boolean `+(`"`+e+`" [routeId: `+n.route.id+`]`))),u=(async()=>{try{return{type:`data`,result:await(i?i(e=>l(e)):l())}}catch(e){return{type:`error`,result:e}}})();return Promise.race([u,c])};try{let i=n.route[e];if(r)if(i){let e,[t]=await Promise.all([c(i).catch(t=>{e=t}),r]);if(e!==void 0)throw e;o=t}else if(await r,i=n.route[e],i)o=await c(i);else if(e===`action`){let e=new URL(t.url),r=e.pathname+e.search;throw Z(405,{method:t.method,pathname:r,routeId:n.route.id})}else return{type:X.data,result:void 0};else if(i)o=await c(i);else{let e=new URL(t.url);throw Z(404,{pathname:e.pathname+e.search})}Y(o.result!==void 0,`You defined `+(e===`action`?`an action`:`a loader`)+` for route `+(`"`+n.route.id+`" but didn't return anything from your \``+e+"` ")+"function. Please return a value or `null`.")}catch(e){return{type:X.error,result:e}}finally{s&&t.signal.removeEventListener(`abort`,s)}return o}async function Qa(e){let{result:t,type:n}=e;if(yo(t)){let e;try{let n=t.headers.get(`Content-Type`);e=n&&/\bapplication\/json\b/.test(n)?t.body==null?null:await t.json():await t.text()}catch(e){return{type:X.error,error:e}}return n===X.error?{type:X.error,error:new Sa(t.status,t.statusText,e),statusCode:t.status,headers:t.headers}:{type:X.data,data:e,statusCode:t.status,headers:t.headers}}if(n===X.error){if(_o(t)){var r;if(t.data instanceof Error){var i;return{type:X.error,error:t.data,statusCode:t.init?.status,headers:(i=t.init)!=null&&i.headers?new Headers(t.init.headers):void 0}}return{type:X.error,error:new Sa(t.init?.status||500,void 0,t.data),statusCode:Ca(t)?t.status:void 0,headers:(r=t.init)!=null&&r.headers?new Headers(t.init.headers):void 0}}return{type:X.error,error:t,statusCode:Ca(t)?t.status:void 0}}if(vo(t))return{type:X.deferred,deferredData:t,statusCode:t.init?.status,headers:t.init?.headers&&new Headers(t.init.headers)};if(_o(t)){var a;return{type:X.data,data:t.data,statusCode:t.init?.status,headers:(a=t.init)!=null&&a.headers?new Headers(t.init.headers):void 0}}return{type:X.data,data:t}}function $a(e,t,n,r,i,a){let o=e.headers.get(`Location`);if(Y(o,`Redirects returned/thrown from loaders/actions must have a Location header`),!Na.test(o)){let s=r.slice(0,r.findIndex(e=>e.route.id===n)+1);o=Ra(new URL(t.url),s,i,!0,o,a),e.headers.set(`Location`,o)}return e}function eo(e,t,n,r){let i=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];if(Na.test(e)){let r=e,a=r.startsWith(`//`)?new URL(t.protocol+r):new URL(r);if(i.includes(a.protocol))throw Error(`Invalid redirect location`);let o=la(a.pathname,n)!=null;if(a.origin===t.origin&&o)return a.pathname+a.search+a.hash}try{let t=r.createURL(e);if(i.includes(t.protocol))throw Error(`Invalid redirect location`)}catch{}return e}function to(e,t,n,r){let i=e.createURL(fo(t)).toString(),a={signal:n};if(r&&$(r.formMethod)){let{formMethod:e,formEncType:t}=r;a.method=e.toUpperCase(),t===`application/json`?(a.headers=new Headers({"Content-Type":t}),a.body=JSON.stringify(r.json)):t===`text/plain`?a.body=r.text:t===`application/x-www-form-urlencoded`&&r.formData?a.body=no(r.formData):a.body=r.formData}return new Request(i,a)}function no(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r==`string`?r:r.name);return t}function ro(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function io(e,t,n,r,i){let a={},o=null,s,c=!1,l={},u=n&&Q(n[1])?n[1].error:void 0;return e.forEach(n=>{if(!(n.route.id in t))return;let d=n.route.id,f=t[d];if(Y(!go(f),`Cannot handle redirect results in processLoaderData`),Q(f)){let t=f.error;if(u!==void 0&&(t=u,u=void 0),o||={},i)o[d]=t;else{let n=co(e,d);o[n.route.id]??(o[n.route.id]=t)}a[d]=void 0,c||(c=!0,s=Ca(f.error)?f.error.status:500),f.headers&&(l[d]=f.headers)}else ho(f)?(r.set(d,f.deferredData),a[d]=f.deferredData.data,f.statusCode!=null&&f.statusCode!==200&&!c&&(s=f.statusCode),f.headers&&(l[d]=f.headers)):(a[d]=f.data,f.statusCode&&f.statusCode!==200&&!c&&(s=f.statusCode),f.headers&&(l[d]=f.headers))}),u!==void 0&&n&&(o={[n[0]]:u},a[n[0]]=void 0),{loaderData:a,errors:o,statusCode:s||200,loaderHeaders:l}}function ao(e,t,n,r,i,a,o){let{loaderData:s,errors:c}=io(t,n,r,o,!1);return i.forEach(t=>{let{key:n,match:r,controller:i}=t,o=a[n];if(Y(o,`Did not find corresponding fetcher result`),!(i&&i.signal.aborted))if(Q(o)){let t=co(e.matches,r?.route.id);c&&c[t.route.id]||(c=q({},c,{[t.route.id]:o.error})),e.fetchers.delete(n)}else if(go(o))Y(!1,`Unhandled fetcher revalidation redirect`);else if(ho(o))Y(!1,`Unhandled fetcher deferred data`);else{let t=jo(o.data);e.fetchers.set(n,t)}}),{loaderData:s,errors:c}}function oo(e,t,n,r){let i=q({},t);for(let a of n){let n=a.route.id;if(t.hasOwnProperty(n)?t[n]!==void 0&&(i[n]=t[n]):e[n]!==void 0&&a.route.loader&&(i[n]=e[n]),r&&r.hasOwnProperty(n))break}return i}function so(e){return e?Q(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function co(e,t){return(t?e.slice(0,e.findIndex(e=>e.route.id===t)+1):[...e]).reverse().find(e=>e.route.hasErrorBoundary===!0)||e[0]}function lo(e){let t=e.length===1?e[0]:e.find(e=>e.index||!e.path||e.path===`/`)||{id:`__shim-error-route__`};return{matches:[{params:{},pathname:``,pathnameBase:``,route:t}],route:t}}function Z(e,t){let{pathname:n,routeId:r,method:i,type:a,message:o}=t===void 0?{}:t,s=`Unknown Server Error`,c=`Unknown @remix-run/router error`;return e===400?(s=`Bad Request`,i&&n&&r?c=`You made a `+i+` request to "`+n+`" but `+('did not provide a `loader` for route "'+r+`", `)+`so there is no way to handle the request.`:a===`defer-action`?c=`defer() is not supported in actions`:a===`invalid-body`&&(c=`Unable to encode submission body`)):e===403?(s=`Forbidden`,c=`Route "`+r+`" does not match URL "`+n+`"`):e===404?(s=`Not Found`,c=`No route matches URL "`+n+`"`):e===405&&(s=`Method Not Allowed`,i&&n&&r?c=`You made a `+i.toUpperCase()+` request to "`+n+`" but `+('did not provide an `action` for route "'+r+`", `)+`so there is no way to handle the request.`:i&&(c=`Invalid request method "`+i.toUpperCase()+`"`)),new Sa(e||500,s,Error(c),!0)}function uo(e){let t=Object.entries(e);for(let e=t.length-1;e>=0;e--){let[n,r]=t[e];if(go(r))return{key:n,result:r}}}function fo(e){let t=typeof e==`string`?zi(e):e;return Ri(q({},t,{hash:``}))}function po(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===``?t.hash!==``:e.hash===t.hash?!0:t.hash!==``}function mo(e){return yo(e.result)&&Oa.has(e.result.status)}function ho(e){return e.type===X.deferred}function Q(e){return e.type===X.error}function go(e){return(e&&e.type)===X.redirect}function _o(e){return typeof e==`object`&&!!e&&`type`in e&&`data`in e&&`init`in e&&e.type===`DataWithResponseInit`}function vo(e){let t=e;return t&&typeof t==`object`&&typeof t.data==`object`&&typeof t.subscribe==`function`&&typeof t.cancel==`function`&&typeof t.resolveData==`function`}function yo(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.headers==`object`&&e.body!==void 0}function bo(e){return Da.has(e.toLowerCase())}function $(e){return Ta.has(e.toLowerCase())}async function xo(e,t,n,r,i){let a=Object.entries(t);for(let o=0;o<a.length;o++){let[s,c]=a[o],l=e.find(e=>e?.route.id===s);if(!l)continue;let u=r.find(e=>e.route.id===l.route.id),d=u!=null&&!Wa(u,l)&&(i&&i[l.route.id])!==void 0;ho(c)&&d&&await Co(c,n,!1).then(e=>{e&&(t[s]=e)})}}async function So(e,t,n){for(let r=0;r<n.length;r++){let{key:i,routeId:a,controller:o}=n[r],s=t[i];e.find(e=>e?.route.id===a)&&ho(s)&&(Y(o,`Expected an AbortController for revalidating fetcher deferred result`),await Co(s,o.signal,!0).then(e=>{e&&(t[i]=e)}))}}async function Co(e,t,n){if(n===void 0&&(n=!1),!await e.deferredData.resolveData(t)){if(n)try{return{type:X.data,data:e.deferredData.unwrappedData}}catch(e){return{type:X.error,error:e}}return{type:X.data,data:e.deferredData.data}}}function wo(e){return new URLSearchParams(e).getAll(`index`).some(e=>e===``)}function To(e,t){let n=typeof t==`string`?zi(t).search:t.search;if(e[e.length-1].route.index&&wo(n||``))return e[e.length-1];let r=ha(e);return r[r.length-1]}function Eo(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:a,json:o}=e;if(!(!t||!n||!r)){if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(a!=null)return{formMethod:t,formAction:n,formEncType:r,formData:a,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function Do(e,t){return t?{state:`loading`,location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:`loading`,location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function Oo(e,t){return{state:`submitting`,location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function ko(e,t){return e?{state:`loading`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:`loading`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function Ao(e,t){return{state:`submitting`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function jo(e){return{state:`idle`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function Mo(e,t){try{let n=e.sessionStorage.getItem(Fa);if(n){let e=JSON.parse(n);for(let[n,r]of Object.entries(e||{}))r&&Array.isArray(r)&&t.set(n,new Set(r||[]))}}catch{}}function No(e,t){if(t.size>0){let n={};for(let[e,r]of t)n[e]=[...r];try{e.sessionStorage.setItem(Fa,JSON.stringify(n))}catch(e){Pi(!1,`Failed to save applied view transitions in sessionStorage (`+e+`).`)}}}function Po(){return Po=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Po.apply(this,arguments)}var Fo=z.createContext(null),Io=z.createContext(null),Lo=z.createContext(null),Ro=z.createContext(null),zo=z.createContext({outlet:null,matches:[],isDataRoute:!1}),Bo=z.createContext(null);function Vo(){return z.useContext(Ro)!=null}function Ho(){return!Vo()&&Y(!1),z.useContext(Ro).location}function Uo(){return z.useContext(Ro).navigationType}function Wo(e){z.useContext(Lo).static||z.useLayoutEffect(e)}function Go(){let{isDataRoute:e}=z.useContext(zo);return e?ls():Ko()}function Ko(){!Vo()&&Y(!1);let e=z.useContext(Fo),{basename:t,future:n,navigator:r}=z.useContext(Lo),{matches:i}=z.useContext(zo),{pathname:a}=Ho(),o=JSON.stringify(ga(i,n.v7_relativeSplatPath)),s=z.useRef(!1);return Wo(()=>{s.current=!0}),z.useCallback(function(n,i){if(i===void 0&&(i={}),!s.current)return;if(typeof n==`number`){r.go(n);return}let c=_a(n,JSON.parse(o),a,i.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:va([t,c.pathname])),(i.replace?r.replace:r.push)(c,i.state,i)},[t,r,o,a,e])}var qo=z.createContext(null);function Jo(e){let t=z.useContext(zo).outlet;return t&&z.createElement(qo.Provider,{value:e},t)}function Yo(){let{matches:e}=z.useContext(zo),t=e[e.length-1];return t?t.params:{}}function Xo(e,t,n,r){!Vo()&&Y(!1);let{navigator:i}=z.useContext(Lo),{matches:a}=z.useContext(zo),o=a[a.length-1],s=o?o.params:{};o&&o.pathname;let c=o?o.pathnameBase:`/`;o&&o.route;let l=Ho(),u;if(t){let e=typeof t==`string`?zi(t):t;!(c===`/`||e.pathname?.startsWith(c))&&Y(!1),u=e}else u=l;let d=u.pathname||`/`,f=d;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);f=`/`+d.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let p=Wi(e,{pathname:f}),m=ts(p&&p.map(e=>Object.assign({},e,{params:Object.assign({},s,e.params),pathname:va([c,i.encodeLocation?i.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:va([c,i.encodeLocation?i.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])})),a,n,r);return t&&m?z.createElement(Ro.Provider,{value:{location:Po({pathname:`/`,search:``,hash:``,state:null,key:`default`},u),navigationType:J.Pop}},m):m}function Zo(){let e=cs(),t=Ca(e)?e.status+` `+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null;return z.createElement(z.Fragment,null,z.createElement(`h2`,null,`Unexpected Application Error!`),z.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?z.createElement(`pre`,{style:{padding:`0.5rem`,backgroundColor:`rgba(200,200,200, 0.5)`}},n):null,null)}var Qo=z.createElement(Zo,null),$o=class extends z.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error(`React Router caught the following error during render`,e,t)}render(){return this.state.error===void 0?this.props.children:z.createElement(zo.Provider,{value:this.props.routeContext},z.createElement(Bo.Provider,{value:this.state.error,children:this.props.component}))}};function es(e){let{routeContext:t,match:n,children:r}=e,i=z.useContext(Fo);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),z.createElement(zo.Provider,{value:t},r)}function ts(e,t,n,r){if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let a=e,o=n?.errors;if(o!=null){let e=a.findIndex(e=>e.route.id&&o?.[e.route.id]!==void 0);!(e>=0)&&Y(!1),a=a.slice(0,Math.min(a.length,e+1))}let s=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let e=0;e<a.length;e++){let t=a[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(c=e),t.route.id){let{loaderData:e,errors:r}=n,i=t.route.loader&&e[t.route.id]===void 0&&(!r||r[t.route.id]===void 0);if(t.route.lazy||i){s=!0,a=c>=0?a.slice(0,c+1):[a[0]];break}}}return a.reduceRight((e,r,i)=>{let l,u=!1,d=null,f=null;n&&(l=o&&r.route.id?o[r.route.id]:void 0,d=r.route.errorElement||Qo,s&&(c<0&&i===0?(ds(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),u=!0,f=null):c===i&&(u=!0,f=r.route.hydrateFallbackElement||null)));let p=t.concat(a.slice(0,i+1)),m=()=>{let t;return t=l?d:u?f:r.route.Component?z.createElement(r.route.Component,null):r.route.element?r.route.element:e,z.createElement(es,{match:r,routeContext:{outlet:e,matches:p,isDataRoute:n!=null},children:t})};return n&&(r.route.ErrorBoundary||r.route.errorElement||i===0)?z.createElement($o,{location:n.location,revalidation:n.revalidation,component:d,error:l,children:m(),routeContext:{outlet:null,matches:p,isDataRoute:!0}}):m()},null)}var ns=function(e){return e.UseBlocker=`useBlocker`,e.UseRevalidator=`useRevalidator`,e.UseNavigateStable=`useNavigate`,e}(ns||{}),rs=function(e){return e.UseBlocker=`useBlocker`,e.UseLoaderData=`useLoaderData`,e.UseActionData=`useActionData`,e.UseRouteError=`useRouteError`,e.UseNavigation=`useNavigation`,e.UseRouteLoaderData=`useRouteLoaderData`,e.UseMatches=`useMatches`,e.UseRevalidator=`useRevalidator`,e.UseNavigateStable=`useNavigate`,e.UseRouteId=`useRouteId`,e}(rs||{});function is(e){let t=z.useContext(Fo);return!t&&Y(!1),t}function as(e){let t=z.useContext(Io);return!t&&Y(!1),t}function os(e){let t=z.useContext(zo);return!t&&Y(!1),t}function ss(e){let t=os(e),n=t.matches[t.matches.length-1];return!n.route.id&&Y(!1),n.route.id}function cs(){let e=z.useContext(Bo),t=as(rs.UseRouteError),n=ss(rs.UseRouteError);return e===void 0?t.errors?.[n]:e}function ls(){let{router:e}=is(ns.UseNavigateStable),t=ss(rs.UseNavigateStable),n=z.useRef(!1);return Wo(()=>{n.current=!0}),z.useCallback(function(r,i){i===void 0&&(i={}),n.current&&(typeof r==`number`?e.navigate(r):e.navigate(r,Po({fromRouteId:t},i)))},[e,t])}var us={};function ds(e,t,n){!t&&!us[e]&&(us[e]=!0)}var fs=(e,t,n)=>(``+t+("You can use the `"+e+"` future flag to opt-in early. ")+(`For more information, see `+n+`.`),void 0);function ps(e,t){e?.v7_startTransition===void 0&&fs(`v7_startTransition`,"React Router will begin wrapping state updates in `React.startTransition` in v7",`https://reactrouter.com/v6/upgrading/future#v7_starttransition`),e?.v7_relativeSplatPath===void 0&&(!t||t.v7_relativeSplatPath===void 0)&&fs(`v7_relativeSplatPath`,`Relative route resolution within Splat routes is changing in v7`,`https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath`),t&&(t.v7_fetcherPersist===void 0&&fs(`v7_fetcherPersist`,`The persistence behavior of fetchers is changing in v7`,`https://reactrouter.com/v6/upgrading/future#v7_fetcherpersist`),t.v7_normalizeFormMethod===void 0&&fs(`v7_normalizeFormMethod`,"Casing of `formMethod` fields is being normalized to uppercase in v7",`https://reactrouter.com/v6/upgrading/future#v7_normalizeformmethod`),t.v7_partialHydration===void 0&&fs(`v7_partialHydration`,"`RouterProvider` hydration behavior is changing in v7",`https://reactrouter.com/v6/upgrading/future#v7_partialhydration`),t.v7_skipActionErrorRevalidation===void 0&&fs(`v7_skipActionErrorRevalidation`,"The revalidation behavior after 4xx/5xx `action` responses is changing in v7",`https://reactrouter.com/v6/upgrading/future#v7_skipactionerrorrevalidation`))}z.startTransition;function ms(e){return Jo(e.context)}function hs(e){Y(!1)}function gs(e){let{basename:t=`/`,children:n=null,location:r,navigationType:i=J.Pop,navigator:a,static:o=!1,future:s}=e;Vo()&&Y(!1);let c=t.replace(/^\/*/,`/`),l=z.useMemo(()=>({basename:c,navigator:a,static:o,future:Po({v7_relativeSplatPath:!1},s)}),[c,s,a,o]);typeof r==`string`&&(r=zi(r));let{pathname:u=`/`,search:d=``,hash:f=``,state:p=null,key:m=`default`}=r,h=z.useMemo(()=>{let e=la(u,c);return e==null?null:{location:{pathname:e,search:d,hash:f,state:p,key:m},navigationType:i}},[c,u,d,f,p,m,i]);return h==null?null:z.createElement(Lo.Provider,{value:l},z.createElement(Ro.Provider,{children:n,value:h}))}var _s=function(e){return e[e.pending=0]=`pending`,e[e.success=1]=`success`,e[e.error=2]=`error`,e}(_s||{});new Promise(()=>{}),z.Component;function vs(e,t){t===void 0&&(t=[]);let n=[];return z.Children.forEach(e,(e,r)=>{if(!z.isValidElement(e))return;let i=[...t,r];if(e.type===z.Fragment){n.push.apply(n,vs(e.props.children,i));return}e.type!==hs&&Y(!1),!(!e.props.index||!e.props.children)&&Y(!1);let a={id:e.props.id||i.join(`-`),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:e.props.ErrorBoundary!=null||e.props.errorElement!=null,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(a.children=vs(e.props.children,i)),n.push(a)}),n}function ys(e){let t={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(t,{element:z.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:z.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:z.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}function bs(){return bs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bs.apply(this,arguments)}var xs=`6`;try{window.__reactRouterVersion=xs}catch{}function Ss(e,t){return Ia({basename:t?.basename,future:bs({},t?.future,{v7_prependBasename:!0}),history:Ni({window:t?.window}),hydrationData:t?.hydrationData||Cs(),routes:e,mapRouteProperties:ys,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window}).initialize()}function Cs(){let e=window?.__staticRouterHydrationData;return e&&e.errors&&(e=bs({},e,{errors:ws(e.errors)})),e}function ws(e){if(!e)return null;let t=Object.entries(e),n={};for(let[e,r]of t)if(r&&r.__type===`RouteErrorResponse`)n[e]=new Sa(r.status,r.statusText,r.data,r.internal===!0);else if(r&&r.__type===`Error`){if(r.__subType){let t=window[r.__subType];if(typeof t==`function`)try{let i=new t(r.message);i.stack=``,n[e]=i}catch{}}if(n[e]==null){let t=Error(r.message);t.stack=``,n[e]=t}}else n[e]=r;return n}var Ts=z.createContext({isTransitioning:!1}),Es=z.createContext(new Map),Ds=z.startTransition,Os=Nr.flushSync;z.useId;function ks(e){Ds?Ds(e):e()}function As(e){Os?Os(e):e()}var js=class{constructor(){this.status=`pending`,this.promise=new Promise((e,t)=>{this.resolve=t=>{this.status===`pending`&&(this.status=`resolved`,e(t))},this.reject=e=>{this.status===`pending`&&(this.status=`rejected`,t(e))}})}};function Ms(e){let{fallbackElement:t,router:n,future:r}=e,[i,a]=z.useState(n.state),[o,s]=z.useState(),[c,l]=z.useState({isTransitioning:!1}),[u,d]=z.useState(),[f,p]=z.useState(),[m,h]=z.useState(),g=z.useRef(new Map),{v7_startTransition:_}=r||{},v=z.useCallback(e=>{_?ks(e):e()},[_]),y=z.useCallback((e,t)=>{let{deletedFetchers:r,flushSync:i,viewTransitionOpts:o}=t;e.fetchers.forEach((e,t)=>{e.data!==void 0&&g.current.set(t,e.data)}),r.forEach(e=>g.current.delete(e));let c=n.window==null||n.window.document==null||typeof n.window.document.startViewTransition!=`function`;if(!o||c){i?As(()=>a(e)):v(()=>a(e));return}if(i){As(()=>{f&&(u&&u.resolve(),f.skipTransition()),l({isTransitioning:!0,flushSync:!0,currentLocation:o.currentLocation,nextLocation:o.nextLocation})});let t=n.window.document.startViewTransition(()=>{As(()=>a(e))});t.finished.finally(()=>{As(()=>{d(void 0),p(void 0),s(void 0),l({isTransitioning:!1})})}),As(()=>p(t));return}f?(u&&u.resolve(),f.skipTransition(),h({state:e,currentLocation:o.currentLocation,nextLocation:o.nextLocation})):(s(e),l({isTransitioning:!0,flushSync:!1,currentLocation:o.currentLocation,nextLocation:o.nextLocation}))},[n.window,f,u,g,v]);z.useLayoutEffect(()=>n.subscribe(y),[n,y]),z.useEffect(()=>{c.isTransitioning&&!c.flushSync&&d(new js)},[c]),z.useEffect(()=>{if(u&&o&&n.window){let e=o,t=u.promise,r=n.window.document.startViewTransition(async()=>{v(()=>a(e)),await t});r.finished.finally(()=>{d(void 0),p(void 0),s(void 0),l({isTransitioning:!1})}),p(r)}},[v,o,u,n.window]),z.useEffect(()=>{u&&o&&i.location.key===o.location.key&&u.resolve()},[u,f,i.location,o]),z.useEffect(()=>{!c.isTransitioning&&m&&(s(m.state),l({isTransitioning:!0,flushSync:!1,currentLocation:m.currentLocation,nextLocation:m.nextLocation}),h(void 0))},[c.isTransitioning,m]),z.useEffect(()=>{},[]);let b=z.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:e=>n.navigate(e),push:(e,t,r)=>n.navigate(e,{state:t,preventScrollReset:r?.preventScrollReset}),replace:(e,t,r)=>n.navigate(e,{replace:!0,state:t,preventScrollReset:r?.preventScrollReset})}),[n]),x=n.basename||`/`,S=z.useMemo(()=>({router:n,navigator:b,static:!1,basename:x}),[n,b,x]),C=z.useMemo(()=>({v7_relativeSplatPath:n.future.v7_relativeSplatPath}),[n.future.v7_relativeSplatPath]);return z.useEffect(()=>ps(r,n.future),[r,n.future]),z.createElement(z.Fragment,null,z.createElement(Fo.Provider,{value:S},z.createElement(Io.Provider,{value:i},z.createElement(Es.Provider,{value:g.current},z.createElement(Ts.Provider,{value:c},z.createElement(gs,{basename:x,location:i.location,navigationType:i.historyAction,navigator:b,future:C},i.initialized||n.future.v7_partialHydration?z.createElement(Ns,{routes:n.routes,future:n.future,state:i}):t))))),null)}var Ns=z.memo(Ps);function Ps(e){let{routes:t,future:n,state:r}=e;return Xo(t,void 0,r,n)}typeof window<`u`&&window.document!==void 0&&window.document.createElement;var Fs;(function(e){e.UseScrollRestoration=`useScrollRestoration`,e.UseSubmit=`useSubmit`,e.UseSubmitFetcher=`useSubmitFetcher`,e.UseFetcher=`useFetcher`,e.useViewTransitionState=`useViewTransitionState`})(Fs||={});var Is;(function(e){e.UseFetcher=`useFetcher`,e.UseFetchers=`useFetchers`,e.UseScrollRestoration=`useScrollRestoration`})(Is||={});function Ls(){return Ls=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ls.apply(null,arguments)}var Rs=[`shift`,`alt`,`meta`,`mod`,`ctrl`],zs={esc:`escape`,return:`enter`,".":`period`,",":`comma`,"-":`slash`," ":`space`,"`":`backquote`,"#":`backslash`,"+":`bracketright`,ShiftLeft:`shift`,ShiftRight:`shift`,AltLeft:`alt`,AltRight:`alt`,MetaLeft:`meta`,MetaRight:`meta`,OSLeft:`meta`,OSRight:`meta`,ControlLeft:`ctrl`,ControlRight:`ctrl`};function Bs(e){return(e&&zs[e]||e||``).trim().toLowerCase().replace(/key|digit|numpad|arrow/,``)}function Vs(e){return Rs.includes(e)}function Hs(e,t){return t===void 0&&(t=`,`),e.split(t)}function Us(e,t,n){t===void 0&&(t=`+`);var r=e.toLocaleLowerCase().split(t).map(function(e){return Bs(e)}),i={alt:r.includes(`alt`),ctrl:r.includes(`ctrl`)||r.includes(`control`),shift:r.includes(`shift`),meta:r.includes(`meta`),mod:r.includes(`mod`)},a=r.filter(function(e){return!Rs.includes(e)});return Ls({},i,{keys:a,description:n,hotkey:e})}(function(){typeof document<`u`&&(document.addEventListener(`keydown`,function(e){e.key!==void 0&&qs([Bs(e.key),Bs(e.code)])}),document.addEventListener(`keyup`,function(e){e.key!==void 0&&Js([Bs(e.key),Bs(e.code)])})),typeof window<`u`&&window.addEventListener(`blur`,function(){Ws.clear()})})();var Ws=new Set;function Gs(e){return Array.isArray(e)}function Ks(e,t){return t===void 0&&(t=`,`),(Gs(e)?e:e.split(t)).every(function(e){return Ws.has(e.trim().toLowerCase())})}function qs(e){var t=Array.isArray(e)?e:[e];Ws.has(`meta`)&&Ws.forEach(function(e){return!Vs(e)&&Ws.delete(e.toLowerCase())}),t.forEach(function(e){return Ws.add(e.toLowerCase())})}function Js(e){e===`meta`?Ws.clear():(Array.isArray(e)?e:[e]).forEach(function(e){return Ws.delete(e.toLowerCase())})}function Ys(e,t,n){(typeof n==`function`&&n(e,t)||n===!0)&&e.preventDefault()}function Xs(e,t,n){return typeof n==`function`?n(e,t):n===!0||n===void 0}function Zs(e){return Qs(e,[`input`,`textarea`,`select`])}function Qs(e,t){t===void 0&&(t=!1);var n=e.target,r=e.composed,i=null;return i=$s(n)&&r?e.composedPath()[0]&&e.composedPath()[0].tagName:n&&n.tagName,Gs(t)?!!(i&&t&&t.some(function(e){return e.toLowerCase()===i?.toLowerCase()})):!!(i&&t&&t)}function $s(e){return!!e.tagName&&!e.tagName.startsWith(`-`)&&e.tagName.includes(`-`)}function ec(e,t){return e.length===0&&t?(console.warn(`A hotkey has the "scopes" option set, however no active scopes were found. If you want to use the global scopes feature, you need to wrap your app in a <HotkeysProvider>`),!0):t?e.some(function(e){return t.includes(e)})||e.includes(`*`):!0}var tc=function(e,t,n){n===void 0&&(n=!1);var r=t.alt,i=t.meta,a=t.mod,o=t.shift,s=t.ctrl,c=t.keys,l=e.key,u=e.code,d=e.ctrlKey,f=e.metaKey,p=e.shiftKey,m=e.altKey,h=Bs(u),g=l.toLowerCase();if(!(c!=null&&c.includes(h))&&!(c!=null&&c.includes(g))&&![`ctrl`,`control`,`unknown`,`meta`,`alt`,`shift`,`os`].includes(h))return!1;if(!n){if(r===!m&&g!==`alt`||o===!p&&g!==`shift`)return!1;if(a){if(!f&&!d)return!1}else if(i===!f&&g!==`meta`&&g!==`os`||s===!d&&g!==`ctrl`&&g!==`control`)return!1}return c&&c.length===1&&(c.includes(g)||c.includes(h))?!0:c?Ks(c):!c},nc=Cr(void 0),rc=function(){return Er(nc)};function ic(e,t){return e&&t&&typeof e==`object`&&typeof t==`object`?Object.keys(e).length===Object.keys(t).length&&Object.keys(e).reduce(function(n,r){return n&&ic(e[r],t[r])},!0):e===t}var ac=Cr({hotkeys:[],enabledScopes:[],toggleScope:function(){},enableScope:function(){},disableScope:function(){}}),oc=function(){return Er(ac)};function sc(e){var t=kr(void 0);return ic(t.current,e)||(t.current=e),t.current}var cc=function(e){e.stopPropagation(),e.preventDefault(),e.stopImmediatePropagation()},lc=typeof window<`u`?Dr:V;function uc(e,t,n,r){var i=Ar(null),a=i[0],o=i[1],s=kr(!1),c=n instanceof Array?r instanceof Array?void 0:r:n,l=Gs(e)?e.join(c?.splitKey):e,u=n instanceof Array?n:r instanceof Array?r:void 0,d=Tr(t,u??[]),f=kr(d);u?f.current=d:f.current=t;var p=sc(c),m=oc().enabledScopes,h=rc();return lc(function(){if(!(p?.enabled===!1||!ec(m,p?.scopes))){var e=function(e,t){var n;if(t===void 0&&(t=!1),!(Zs(e)&&!Qs(e,p?.enableOnFormTags))){if(a!==null){var r=a.getRootNode();if((r instanceof Document||r instanceof ShadowRoot)&&r.activeElement!==a&&!a.contains(r.activeElement)){cc(e);return}}(n=e.target)!=null&&n.isContentEditable&&!(p!=null&&p.enableOnContentEditable)||Hs(l,p?.splitKey).forEach(function(n){var r,i=Us(n,p?.combinationKey);if(tc(e,i,p?.ignoreModifiers)||(r=i.keys)!=null&&r.includes(`*`)){if(p!=null&&p.ignoreEventWhen!=null&&p.ignoreEventWhen(e)||t&&s.current)return;if(Ys(e,i,p?.preventDefault),!Xs(e,i,p?.enabled)){cc(e);return}f.current(e,i),t||(s.current=!0)}})}},t=function(t){t.key!==void 0&&(qs(Bs(t.code)),(p?.keydown===void 0&&p?.keyup!==!0||p!=null&&p.keydown)&&e(t))},n=function(t){t.key!==void 0&&(Js(Bs(t.code)),s.current=!1,p!=null&&p.keyup&&e(t,!0))},r=a||c?.document||document;return r.addEventListener(`keyup`,n,c?.eventListenerOptions),r.addEventListener(`keydown`,t,c?.eventListenerOptions),h&&Hs(l,p?.splitKey).forEach(function(e){return h.addHotkey(Us(e,p?.combinationKey,p?.description))}),function(){r.removeEventListener(`keyup`,n,c?.eventListenerOptions),r.removeEventListener(`keydown`,t,c?.eventListenerOptions),h&&Hs(l,p?.splitKey).forEach(function(e){return h.removeHotkey(Us(e,p?.combinationKey,p?.description))})}}},[a,l,p,m]),o}var dc=Cr(null),fc={didCatch:!1,error:null},pc=class extends br{constructor(e){super(e),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=fc}static getDerivedStateFromError(e){return{didCatch:!0,error:e}}resetErrorBoundary(){let{error:e}=this.state;if(e!==null){var t,n,r=[...arguments];(t=(n=this.props).onReset)==null||t.call(n,{args:r,reason:`imperative-api`}),this.setState(fc)}}componentDidCatch(e,t){var n,r;(n=(r=this.props).onError)==null||n.call(r,e,t)}componentDidUpdate(e,t){let{didCatch:n}=this.state,{resetKeys:r}=this.props;if(n&&t.error!==null&&mc(e.resetKeys,r)){var i,a;(i=(a=this.props).onReset)==null||i.call(a,{next:r,prev:e.resetKeys,reason:`keys`}),this.setState(fc)}}render(){let{children:e,fallbackRender:t,FallbackComponent:n,fallback:r}=this.props,{didCatch:i,error:a}=this.state,o=e;if(i){let e={error:a,resetErrorBoundary:this.resetErrorBoundary};if(typeof t==`function`)o=t(e);else if(n)o=wr(n,e);else if(r!==void 0)o=r;else throw a}return wr(dc.Provider,{value:{didCatch:i,error:a,resetErrorBoundary:this.resetErrorBoundary}},o)}};function mc(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e.length!==t.length||e.some((e,n)=>!Object.is(e,t[n]))}var hc=`${I.routerBasename}:acceptedCookies`,gc=new Set,_c=vc();function vc(){try{let e=localStorage.getItem(hc);return e?JSON.parse(e):{analytics:!1,marketing:!1,functional:!1}}catch{return{analytics:!1,marketing:!1,functional:!1}}}function yc(){return _c}function bc(e){_c=e(_c),localStorage.setItem(hc,JSON.stringify(_c)),gc.forEach(e=>e())}function xc(e){return gc.add(e),()=>gc.delete(e)}var Sc=()=>[jr(xc,yc,yc),bc],Cc=[];function wc(){let e=M();return jr(t=>e?.subscribePending(t)??(()=>{}),()=>e?.getPendingInstallations()??Cc)}var Tc=`${I.routerBasename}:display-cookie-banner`,Ec=new Set,Dc=Oc();function Oc(){try{return localStorage.getItem(Tc)!==`false`}catch(e){return console.error(e),!0}}function kc(){return Dc}function Ac(e){Dc=e,localStorage.setItem(Tc,JSON.stringify(e))}function jc(e){return Ec.add(e),()=>Ec.delete(e)}var Mc=()=>[jr(jc,kc,kc),Ac],Nc=l([`sentry`]),Pc=!1;async function Fc(){return await F(()=>import(`./esm-C3z6RsQv.js`),__vite__mapDeps([0,1]))}async function Ic(){I.sentry;let e=await Fc(),t=[e.httpClientIntegration(),e.extraErrorDataIntegration({depth:5}),e.replayIntegration(),e.captureConsoleIntegration({levels:[`error`]})];I.sentry.tracing&&t.push(e.reactRouterV6BrowserTracingIntegration({useEffect:yr.useEffect,useLocation:Ho,useNavigationType:Uo,createRoutesFromChildren:vs,matchRoutes:Wi})),e.init({release:I.sentry.release,dsn:I.sentry.dsn,environment:I.sentry.env,integrations:t,ignoreErrors:[`User is not allowed to create files`,`User is not allowed to move documents`,`The user aborted a request.`],sendDefaultPii:!0,tracesSampleRate:1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1,beforeSend(e,t){let n=t.originalException;return n instanceof TypeError&&n.message.includes(`Failed to fetch`)&&!navigator.onLine?null:e}}),Pc=!0}async function Lc(){if(Pc)return(await Fc()).getClient()?.close()}function Rc(){let[e]=Sc(),{analytics:t}=e;V(()=>{if(!t){Lc().catch(e=>Nc.error(`@error`,e));return}Pc||!I.sentry.dsn||I.sentry.dsn===``||Ic().catch(e=>Nc.error(`@error`,e))},[t])}var zc=e=>{let{undo:t,redo:n,canRedo:r,canUndo:i}=e,a=window.navigator.userAgent.includes(`Mac`),o=`ctrl+z`,s=`ctrl+y`;a&&(o=`mod+z`,s=`mod+shift+z`),uc(o,e=>{e.preventDefault(),i&&t()},{},[i,t]),uc(s,e=>{e.preventDefault(),r&&n()},{},[r,n])};function Bc(...e){window.dataLayer?.push(...e)}var Vc=()=>{let e=I.gaTrackingId,[{analytics:t}]=Sc(),n=e&&t;return V(()=>{if(n){let t=document.createElement(`script`);return t.src=`https://www.googletagmanager.com/gtag/js?id=${e}`,t.async=!0,document.head.appendChild(t),window.dataLayer=window.dataLayer||[],Bc(`js`,new Date),Bc(`config`,e),()=>{document.head.removeChild(t)}}},[n,e]),null};function Hc(){let[e]=re(),t=se(e.header.id),n=Tr(()=>{b(e).length?m({type:`exportDocumentWithErrors`,documentId:e.header.id}):ne(e).catch(e=>{console.error(e),me(`Failed to export document: ${e instanceof Error?e.message:JSON.stringify(e,null,1)}`)})},[e]),r=Or(()=>async()=>{},[]),i=Tr(()=>{_(t)},[t,_]);return H(`div`,{id:`document-editor-container`,className:`flex-1`,"data-document-type":e.header.documentType,children:H(ru,{document:e,onClose:i,onExport:n,onOpenSwitchboardLink:r})})}function Uc(e){let[t,n]=Ar(!1);if(V(()=>{setTimeout(()=>{n(!0)},e.loadingTimeout??200)},[e]),!t)return null;let{customEditorLoader:r,...i}=e;return r?H(Mr,{children:r}):H(Le,{...i})}var Wc=l([`Connect`]);function Gc(e){return`fallbackRender`in e}function Kc(){return null}function qc({message:e=`Something went wrong`}){return H(`div`,{className:`text-center`,children:e})}function Jc({error:e,resetErrorBoundary:t}){let n=e instanceof Error?e.message:String(e),r=e instanceof Error?e.stack??String(e.cause):JSON.stringify(e,null,2);return H(`div`,{className:`z-10 mx-auto flex max-w-[80%] flex-1 items-center justify-center p-6`,children:U(`div`,{className:`w-full max-w-lg rounded-lg border border-gray-500 bg-white p-6 shadow-sm`,children:[U(`div`,{className:`mb-3 flex items-center gap-2`,children:[H(fe,{name:`Error`,className:`size-5 shrink-0`}),H(`h1`,{className:`text-lg font-semibold`,children:`Something went wrong`})]}),H(`p`,{className:`mb-4 text-sm text-gray-700`,children:n}),r!==`{}`&&U(`details`,{className:`group`,children:[H(`summary`,{className:`cursor-pointer select-none text-sm font-medium text-gray-700 underline hover:text-gray-700`,children:`Show details`}),H(`pre`,{className:`mt-2 max-h-48 overflow-auto rounded bg-gray-100 p-3 text-xs`,children:r})]}),H(pe,{type:`button`,onClick:t,className:`text-md mt-4 px-3 py-1.5 font-medium`,children:`Try again`})]})})}function Yc({error:e}){return H(`div`,{className:`flex size-full items-center justify-center`,children:H(`h3`,{className:`text-lg font-semibold`,children:e instanceof Error?e.message:String(e)})})}function Xc(e,t){switch(e){case`silent`:return Kc;case`text`:return()=>H(qc,{message:t});case`detailed`:return Jc;default:return Yc}}function Zc(e){let{children:t,onError:n,resetKeys:r,loggerContext:i}=e;return H(pc,{fallbackRender:Gc(e)?e.fallbackRender:Xc(e.variant,e.fallbackMessage),onError:(e,t)=>{if(e.message.includes(`Failed to fetch dynamically imported module`)&&e.message.includes(`node_modules/.vite`)){console.error(e),console.log(`Outdated chunk detected, reloading page...`),window.location.reload();return}(i?l(i):Wc).error(`@error @info`,e,t),n?.(e,t)},resetKeys:r,children:t})}function Qc(){let[e]=j(),t=A(),n=y(e.header.meta?.preferredEditor),r=p(),i=n?.Component??r?.Component??R.Component;if(!i)throw Error(`No app component found`);return H(Zc,{variant:`detailed`,resetKeys:[e.header.id],loggerContext:[`Connect`,`App`],children:H(Sr,{fallback:H(Uc,{}),children:H(Ne,{className:`flex h-full flex-col overflow-auto`,children:H(i,{children:t?H(Hc,{}):null})})})})}function $c(){return typeof document>`u`?`/`:document.querySelector(`base`)?.getAttribute(`href`)||`/`}var el=null,tl=new Set;function nl(e){el=e;for(let e of tl)e()}function rl(){return el}function il(e){return tl.add(e),()=>{tl.delete(e)}}var al=`ph-pglite-backup::`,ol=`ph:pglite-backups`,sl=720*60*60*1e3,cl={16:async()=>{let[{PGlite:e},{pgDump:t}]=await Promise.all([F(()=>import(`./dist-ClzcOFHf.js`),__vite__mapDeps([2,1,3,4,5,6,7])),F(()=>import(`./pg_dump-DpLFvU0N.js`),__vite__mapDeps([8,1,3]))]);return async n=>{let r=new e(`idb://${n.replace(/^\/pglite\//,``)}`);try{return await r.waitReady,await(await t({pg:r})).text()}finally{await r.close()}}}};function ll(e,t=15e3){return new Promise((n,r)=>{let i=indexedDB.deleteDatabase(e),a=!1,o=e=>{a||(a=!0,e())},s=setTimeout(()=>o(()=>r(Error(`IDB delete timed out for ${e} after ${t}ms`))),t);i.onsuccess=()=>o(()=>{clearTimeout(s),n()}),i.onerror=()=>o(()=>{clearTimeout(s),r(be(i,`IDB delete failed for ${e}`))})})}async function ul(e){let t=await xe(e,21,Ce);try{await new Promise((n,r)=>{let i=t.transaction(L,`readwrite`);i.oncomplete=()=>n(),i.onerror=()=>r(be(i,`FILE_DATA clear failed for ${e}`)),i.onabort=()=>r(be(i,`FILE_DATA clear aborted for ${e}`)),i.objectStore(L).clear()})}finally{t.close()}}async function dl(e,t){let n=await xe(e,21,Ce);try{let r=await xe(t,21,Ce);try{let i=n.transaction(L,`readonly`).objectStore(L),a=await new Promise((t,n)=>{let r=[],a=i.openCursor();a.onerror=()=>n(be(a,`FILE_DATA read cursor failed for ${e}`)),a.onsuccess=()=>{let e=a.result;if(!e)return t(r);r.push({key:e.key,value:e.value}),e.continue()}});await new Promise((e,n)=>{let i=r.transaction(L,`readwrite`);i.oncomplete=()=>e(),i.onerror=()=>n(be(i,`FILE_DATA write failed for ${t}`)),i.onabort=()=>n(be(i,`FILE_DATA write aborted for ${t}`));let o=i.objectStore(L);o.clear();for(let{key:e,value:t}of a)o.put(t,e)})}finally{r.close()}}finally{n.close()}}function fl(){try{let e=localStorage.getItem(ol);if(!e)return[];let t=JSON.parse(e);return Array.isArray(t)?t:[]}catch{return[]}}function pl(e){try{localStorage.setItem(ol,JSON.stringify(e))}catch{}}function ml(e){pl([...fl(),e])}function hl(e){pl(fl().filter(t=>t.name!==e))}async function gl(){let e=Date.now()-sl,t=[];for(let n of fl()){if(n.createdAt>=e){t.push(n);continue}try{await ll(n.name)}catch(e){console.warn(`Failed to delete expired pglite backup ${n.name}`,e),t.push(n)}}pl(t)}function _l(e,t){nl({idbName:e,phase:t})}async function vl(e){let t=await we(e);if(t===null||t===17)return;let n=cl[t];if(!n)throw Error(`Unsupported legacy PGlite data dir: PG_VERSION=${t} for ${e}`);let r=`${al}${e}::${new Date().toISOString()}`,i={name:r,idbName:e,createdAt:Date.now()};_l(e,`clone`),await dl(e,r),ml(i);let a;try{_l(e,`dump`),a=await(await n())(e)}catch(e){throw await ll(r).catch(()=>{}),hl(r),e}try{await ul(e),_l(e,`restore`);let t=new He(`idb://${e.replace(/^\/pglite\//,``)}`,{relaxedDurability:!1});try{await t.waitReady,console.info(`[pglite-migration] Dump preamble (first 500 chars):\n${a.slice(0,500)}`);try{await t.exec(`SET standard_conforming_strings = off;`)}catch(e){console.warn(`[pglite-migration] Could not force standard_conforming_strings=off`,e)}try{await t.exec(a)}catch(t){throw yl(e,a,t),t}}finally{await t.close()}}catch(t){throw await bl(e,r,t),t}}function yl(e,t,n){let r=n,i=typeof r.position==`string`?parseInt(r.position,10):typeof r.position==`number`?r.position:NaN;if(console.error(`[pglite-migration] Restore failed for ${e}`,{message:r.message,code:r.code,severity:r.severity,detail:r.detail,where:r.where,position:r.position,sqlLength:t.length}),Number.isFinite(i)&&i>0){let e=i-1,n=Math.max(0,e-200),r=Math.min(t.length,e+200),a=t.slice(n,e),o=t.slice(e,e+1),s=t.slice(e+1,r);console.error(`[pglite-migration] SQL context around position ${i}:\n${a}»${o}«${s}`);let c=t.lastIndexOf(`
|
|
33
|
+
}`)}function K(e,t,n=``){return t!=null&&t!==``?e+t+n:``}function Li(e){return K(` `,e.replace(/\n/g,`
|
|
34
|
+
`))}function Ri(e){return e?.some(e=>e.includes(`
|
|
35
|
+
`))??!1}var zi=`Accept`,Bi=`Content-Type`,Vi=`application/json`,Hi=`application/graphql-response+json`,Ui=e=>e.replace(/([\s,]|#[^\n\r]+)+/g,` `).trim(),Wi=e=>{let t=e.toLowerCase();return t.includes(Hi)||t.includes(Vi)},Gi=e=>{try{if(Array.isArray(e))return{_tag:`Batch`,executionResults:e.map(Ki)};if(wi(e))return{_tag:`Single`,executionResult:Ki(e)};throw Error(`Invalid execution result: result is not object or array. \nGot:\n${String(e)}`)}catch(e){return e}},Ki=e=>{if(typeof e!=`object`||!e)throw Error(`Invalid execution result: result is not object`);let t,n,r;if(`errors`in e){if(!wi(e.errors)&&!Array.isArray(e.errors))throw Error(`Invalid execution result: errors is not plain object OR array`);t=e.errors}if(`data`in e){if(!wi(e.data)&&e.data!==null)throw Error(`Invalid execution result: data is not plain object`);n=e.data}if(`extensions`in e){if(!wi(e.extensions))throw Error(`Invalid execution result: extensions is not plain object`);r=e.extensions}return{data:n,errors:t,extensions:r}},qi=e=>e._tag===`Batch`?e.executionResults.some(Ji):Ji(e.executionResult),Ji=e=>Array.isArray(e.errors)?e.errors.length>0:!!e.errors,Yi=e=>typeof e==`object`&&!!e&&`kind`in e&&e.kind===n.OPERATION_DEFINITION,Xi=e=>{let t,n=e.definitions.filter(Yi);return n.length===1&&(t=n[0].name?.value),t},Zi=e=>{let t=!1,n=e.definitions.filter(Yi);return n.length===1&&(t=n[0].operation===`mutation`),t},Qi=(e,n)=>{let r=typeof e==`string`||`kind`in e?e:String(e),i=typeof r==`string`?r:Pi(r),a=!1,o;if(n)return{expression:i,isMutation:a,operationName:o};let s=bi(()=>typeof r==`string`?t(r):r);return s instanceof Error?{expression:i,isMutation:a,operationName:o}:(o=Xi(s),a=Zi(s),{expression:i,operationName:o,isMutation:a})},$i=JSON,ea=async e=>{let t={...e,method:e.request._tag===`Single`?e.request.document.isMutation?`POST`:hi(e.method??`post`):e.request.hasMutations?`POST`:hi(e.method??`post`),fetchOptions:{...e.fetchOptions,errorPolicy:e.fetchOptions.errorPolicy??`none`}},n=await ra(t.method)(t),r=await n.text(),i;try{i=na(r,n.headers.get(Bi),e.fetchOptions.jsonSerializer??$i)}catch(e){i=e}let a={status:n.status,headers:n.headers,body:r};if(!n.ok)return i instanceof Error?new mi({...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables}):new mi(i._tag===`Batch`?{...i.executionResults,...a}:{...i.executionResult,...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables});if(i instanceof Error)throw i;if(qi(i)&&t.fetchOptions.errorPolicy===`none`)return new mi(i._tag===`Batch`?{...i.executionResults,...a}:{...i.executionResult,...a},{query:e.request._tag===`Single`?e.request.document.expression:e.request.query,variables:e.request.variables});switch(i._tag){case`Single`:return{...a,...ta(t)(i.executionResult)};case`Batch`:return{...a,data:i.executionResults.map(ta(t))};default:Ci(i)}},ta=e=>t=>({extensions:t.extensions,data:t.data,errors:e.fetchOptions.errorPolicy===`all`?t.errors:void 0}),na=(e,t,n)=>t&&Wi(t)?Gi(n.parse(e)):Gi(e),ra=e=>async t=>{let n=new Headers(t.headers),r=null,i;n.has(zi)||n.set(zi,[Hi,Vi].join(`, `)),e===`POST`?(i=(t.fetchOptions.jsonSerializer??$i).stringify(ia(t)),typeof i==`string`&&!n.has(Bi)&&n.set(Bi,Vi)):r=aa(t);let a={method:e,headers:n,body:i,...t.fetchOptions},o=new URL(t.url),s=a;if(t.middleware){let{url:e,...n}=await Promise.resolve(t.middleware({...a,url:t.url,operationName:t.request._tag===`Single`?t.request.document.operationName:void 0,variables:t.request.variables}));o=new URL(e),s=n}return r&&r.forEach((e,t)=>{o.searchParams.append(t,e)}),await(t.fetch??fetch)(o,s)},ia=e=>{switch(e.request._tag){case`Single`:return{query:e.request.document.expression,variables:e.request.variables,operationName:e.request.document.operationName};case`Batch`:return _i(e.request.query,e.request.variables??[]).map(([e,t])=>({query:e,variables:t}));default:throw Ci(e.request)}},aa=e=>{let t=e.fetchOptions.jsonSerializer??$i,n=new URLSearchParams;switch(e.request._tag){case`Single`:return n.append(`query`,Ui(e.request.document.expression)),e.request.variables&&n.append(`variables`,t.stringify(e.request.variables)),e.request.document.operationName&&n.append(`operationName`,e.request.document.operationName),n;case`Batch`:{let r=e.request.variables?.map(e=>t.stringify(e))??[],i=_i(e.request.query.map(Ui),r).map(([e,t])=>({query:e,variables:t}));return n.append(`query`,t.stringify(i)),n}default:throw Ci(e.request)}},oa=class{url;requestConfig;constructor(e,t={}){this.url=e,this.requestConfig=t}rawRequest=async(...e)=>{let[t,n,r]=e,i=Ei(t,n,r),{headers:a,fetch:o=globalThis.fetch,method:s=`POST`,requestMiddleware:c,responseMiddleware:l,excludeOperationName:u,...d}=this.requestConfig,{url:f}=this;i.signal!==void 0&&(d.signal=i.signal);let p=Qi(i.query,u),m=await ea({url:f,request:{_tag:`Single`,document:p,variables:i.variables},headers:{...vi(gi(a)),...vi(i.requestHeaders)},fetch:o,method:s,fetchOptions:d,middleware:c});if(l&&await l(m,{operationName:p.operationName,variables:n,url:this.url}),m instanceof Error)throw m;return m};async request(e,...t){let[n,r]=t,i=ca(e,n,r),{headers:a,fetch:o=globalThis.fetch,method:s=`POST`,requestMiddleware:c,responseMiddleware:l,excludeOperationName:u,...d}=this.requestConfig,{url:f}=this;i.signal!==void 0&&(d.signal=i.signal);let p=Qi(i.document,u),m=await ea({url:f,request:{_tag:`Single`,document:p,variables:i.variables},headers:{...vi(gi(a)),...vi(i.requestHeaders)},fetch:o,method:s,fetchOptions:d,middleware:c});if(l&&await l(m,{operationName:p.operationName,variables:i.variables,url:this.url}),m instanceof Error)throw m;return m.data}async batchRequests(e,t){let n=Ti(e,t),{headers:r,excludeOperationName:i,...a}=this.requestConfig;n.signal!==void 0&&(a.signal=n.signal);let o=n.documents.map(({document:e})=>Qi(e,i)),s=o.map(({expression:e})=>e),c=o.some(({isMutation:e})=>e),l=n.documents.map(({variables:e})=>e),u=await ea({url:this.url,request:{_tag:`Batch`,operationName:void 0,query:s,hasMutations:c,variables:l},headers:{...vi(gi(r)),...vi(n.requestHeaders)},fetch:this.requestConfig.fetch??globalThis.fetch,method:this.requestConfig.method||`POST`,fetchOptions:a,middleware:this.requestConfig.requestMiddleware});if(this.requestConfig.responseMiddleware&&await this.requestConfig.responseMiddleware(u,{operationName:void 0,variables:l,url:this.url}),u instanceof Error)throw u;return u.data}setHeaders(e){return this.requestConfig.headers=e,this}setHeader(e,t){let{headers:n}=this.requestConfig;return n?n[e]=t:this.requestConfig.headers={[e]:t},this}setEndpoint(e){return this.url=e,this}};async function sa(e,t,...n){let r=la(e,t,...n);return new oa(r.url).request({...r})}var ca=(e,t,n)=>e.document?e:{document:e,variables:t,requestHeaders:n,signal:void 0},la=(e,t,...n)=>{let[r,i]=n;return typeof e==`string`?{url:e,document:t,variables:r,requestHeaders:i,signal:void 0}:e},ua=(e,...t)=>e.reduce((e,n,r)=>`${e}${n}${r in t?String(t[r]):``}`,``);ge.use(ve).init({resources:{en:{code:`en`,name:`English`,translation:{common:{cancel:`Cancel`,delete:`Delete`,continue:`Continue`,empty:`Empty`,create:`Create`,save:`Save`,export:`Export`,reload:`Reload`,reloadConnect:`Click here to reload Connect`},searchbar:{placeholder:`Search Powerhouse`,filterLabel:`File type`},folderView:{sections:{folders:{title:`Folders`,empty:`No folders 🗂️`},documents:{title:`Documents and files`,empty:`No documents or files 📄`}}},files:{options:{switchboardLink:`Switchboard Link`}},modals:{deleteItem:{folder:{header:`Delete “{{item}}” folder?`,body:`Are you sure you want to delete this folder? All files and subfolders within it will be removed.`},file:{header:`Delete “{{item}}” file?`,body:`Are you sure you want to delete this file?`}},deleteDrive:{title:`Delete "{{label}}" drive?`,body:`Are you sure you want to delete this drive? All files and subfolders within it will be removed. Do you want to proceed?`,inputPlaceholder:`Enter drive name...`},upgradeDrive:{header:`Upgrade to cloud drive`,body:`You are moving files from a private to a shared drive. These files will become accessible to others in the shared drive.Do you want to proceed?`},createDocument:{header:`Create a new document`,placeholder:`Document name`},connectSettings:{title:`Settings`,body:`These settings will apply to all drives.`,clearStorage:{button:`Clear Storage`,description:`Delete previous session data`,confirmation:{title:`Clear Storage`,body:`Are you sure you want to clear the storage? This will remove all previous session data.`,clearButton:`Clear Storage`}},enabledDocumentTypes:{title:`Document Models`,description:`Documents enabled`,allSelected:`All documents are selected`}},exportDocumentWithErrors:{title:`Your document contains errors`,body:`Your document contains structure errors. Do you want to export it anyway?`},disclaimer:{title:`Disclaimer`,body:`All content provided herein our website, hyperlinked sites, associated applications, forums, blogs, social media accounts and other platforms (“Site”) is for your general information only, procured from third party sources. We make no warranties of any kind in relation to our content, including but not limited to accuracy and updatedness. No part of the content that we provide constitutes financial advice, legal advice or any other form of advice meant for your specific reliance for any purpose. Any use or reliance on our content is solely at your own risk and discretion. You should conduct your own research, review, analyse and verify our content before relying on them. Trading is a highly risky activity that can lead to major losses, please therefore consult your financial advisor before making any decision. No content on our Site is meant to be a solicitation or offer.`},cookiesPolicy:{title:`Cookies Policy`,body:`<subtitle>Use of Cookies and Similar Technologies</subtitle><p>The Site is using cookies. Cookies are small text files that are placed on your computer by websites that you visit. They are widely used in order to make websites work, or work more efficiently, as well as to provide information to the owners of the site. Cookies are typically stored on your computer´s hard drive.Information collected from cookies is used by us to evaluate the effectiveness of our Site and analyze trends. The information collected from cookies allows us to determine such things as which parts of the Site are most visited and difficulties our visitors may experience in accessing the SIte. With this knowledge, we can improve the quality of your experience on the Site by recognizing and delivering more of the most desired features and information, as well as by resolving access difficulties.</p><p>We use third party service providers, to assist us in better understanding the use of our Site. Our service providers will place cookies on the hard drive of your computer (or use similar technologies) and will receive information that we select that will educate us on such things as how visitors navigate around our Site. This information is aggregated to provide statistical data about our users browsing actions and patterns, and does not personally identify individuals. This information may include:</p><p>Computer or mobile device information, Website usage information, such as:<list></p><bullet>Page views,</bullet><bullet>Button clicks,</bullet><bullet>Input form changes (without the values being entered),</bullet><bullet>Errors.</bullet></list><p>Our service providers analyses this information and provides us with aggregate reports. The information and analysis provided by our service providers will be used to assist us in better understanding our visitors interests in our Site and how to better serve those interests. If you want to avoid using cookies altogether, you can disable cookies in your browser. However, disabling cookies might make it impossible for you to use certain features of the Site. Your use of the Site with a browser that is configured to accept cookies constitutes an acceptance of our and third-party cookies.</p>`}},notifications:{deleteDriveSuccess:`Drive successfully deleted`,deleteFolderSuccess:`Folder deleted`,fileDeleteSuccess:`File deleted`,addDriveSuccess:`New drive successfully added`,driveSyncSuccess:`Drive synced successfully`,driveSyncError:`Error synchronizing drive {{drive}}`,driveSyncConflict:`Conflict error detected in {{drive}}`,reloadApp:`It seems like you're running an outdated version of the app. Please reload Connect to get the latest version.`},footer:{cookiePolicy:`Cookie Policy`,termsOfUse:`Terms of Use`,disclaimer:`Disclaimer`,builtWith:`Built with <icon /> Powerhouse`},cookieBanner:{message:`This website uses cookies for analytic purposes only. Cookies are anonymous and do not link to user data. We collect information to improve the user experience and validate UI changes. You can still use the page without cookies. For more information, please read our <a>cookies policy.</a>`,accept:`Accept configured cookies`,reject:`Reject all cookies`,cookies:{functional:`Functional cookies`,analytics:`Analytics cookies`}}}}},fallbackLng:`en`,debug:!1,interpolation:{escapeValue:!1}}).catch(e=>{console.error(e)});function q(){return q=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},q.apply(this,arguments)}var J;(function(e){e.Pop=`POP`,e.Push=`PUSH`,e.Replace=`REPLACE`})(J||={});var da=`popstate`;function fa(e){e===void 0&&(e={});function t(e,t){let{pathname:n,search:r,hash:i}=e.location;return ga(``,{pathname:n,search:r,hash:i},t.state&&t.state.usr||null,t.state&&t.state.key||`default`)}function n(e,t){return typeof t==`string`?t:_a(t)}return ya(t,n,null,e)}function Y(e,t){if(e===!1||e==null)throw Error(t)}function pa(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function ma(){return Math.random().toString(36).substr(2,8)}function ha(e,t){return{usr:e.state,key:e.key,idx:t}}function ga(e,t,n,r){return n===void 0&&(n=null),q({pathname:typeof e==`string`?e:e.pathname,search:``,hash:``},typeof t==`string`?va(t):t,{state:n,key:t&&t.key||r||ma()})}function _a(e){let{pathname:t=`/`,search:n=``,hash:r=``}=e;return n&&n!==`?`&&(t+=n.charAt(0)===`?`?n:`?`+n),r&&r!==`#`&&(t+=r.charAt(0)===`#`?r:`#`+r),t}function va(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function ya(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=J.Pop,c=null,l=u();l??(l=0,o.replaceState(q({},o.state,{idx:l}),``));function u(){return(o.state||{idx:null}).idx}function d(){s=J.Pop;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=J.Push;let r=ga(h.location,e,t);n&&n(r,e),l=u()+1;let d=ha(r,l),f=h.createHref(r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=J.Replace;let r=ga(h.location,e,t);n&&n(r,e),l=u();let i=ha(r,l),d=h.createHref(r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){let t=i.location.origin===`null`?i.location.href:i.location.origin,n=typeof e==`string`?e:_a(e);return n=n.replace(/ $/,`%20`),Y(t,`No window.location.(origin|href) available to create URL for href: `+n),new URL(n,t)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(da,d),c=e,()=>{i.removeEventListener(da,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}var X;(function(e){e.data=`data`,e.deferred=`deferred`,e.redirect=`redirect`,e.error=`error`})(X||={});var ba=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`children`]);function xa(e){return e.index===!0}function Sa(e,t,n,r){return n===void 0&&(n=[]),r===void 0&&(r={}),e.map((e,i)=>{let a=[...n,String(i)],o=typeof e.id==`string`?e.id:a.join(`-`);if(Y(e.index!==!0||!e.children,`Cannot specify children on an index route`),Y(!r[o],`Found a route id collision on id "`+o+`". Route id's must be globally unique within Data Router usages`),xa(e)){let n=q({},e,t(e),{id:o});return r[o]=n,n}else{let n=q({},e,t(e),{id:o,children:void 0});return r[o]=n,e.children&&(n.children=Sa(e.children,t,a,r)),n}})}function Ca(e,t,n){return n===void 0&&(n=`/`),wa(e,t,n,!1)}function wa(e,t,n,r){let i=Ha((typeof t==`string`?va(t):t).pathname||`/`,n);if(i==null)return null;let a=Ea(e);Oa(a);let o=null;for(let e=0;o==null&&e<a.length;++e){let t=Va(i);o=Ra(a[e],t,r)}return o}function Ta(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],handle:n.handle}}function Ea(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r=``);let i=(e,i,a)=>{let o={relativePath:a===void 0?e.path||``:a,caseSensitive:e.caseSensitive===!0,childrenIndex:i,route:e};o.relativePath.startsWith(`/`)&&(Y(o.relativePath.startsWith(r),`Absolute route path "`+o.relativePath+`" nested under path `+(`"`+r+`" is not valid. An absolute child route path `)+`must start with the combined path of all its parent routes.`),o.relativePath=o.relativePath.slice(r.length));let s=Za([r,o.relativePath]),c=n.concat(o);e.children&&e.children.length>0&&(Y(e.index!==!0,`Index routes must not have child routes. Please remove `+(`all child routes from route path "`+s+`".`)),Ea(e.children,t,c,s)),!(e.path==null&&!e.index)&&t.push({path:s,score:Ia(s,e.index),routesMeta:c})};return e.forEach((e,t)=>{var n;if(e.path===``||!((n=e.path)!=null&&n.includes(`?`)))i(e,t);else for(let n of Da(e.path))i(e,t,n)}),t}function Da(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=Da(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function Oa(e){e.sort((e,t)=>e.score===t.score?La(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var ka=/^:[\w-]+$/,Aa=3,ja=2,Ma=1,Na=10,Pa=-2,Fa=e=>e===`*`;function Ia(e,t){let n=e.split(`/`),r=n.length;return n.some(Fa)&&(r+=Pa),t&&(r+=ja),n.filter(e=>!Fa(e)).reduce((e,t)=>e+(ka.test(t)?Aa:t===``?Ma:Na),r)}function La(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function Ra(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u=za({path:s.relativePath,caseSensitive:s.caseSensitive,end:c},l),d=s.route;if(!u&&c&&n&&!r[r.length-1].route.index&&(u=za({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!u)return null;Object.assign(i,u.params),o.push({params:i,pathname:Za([a,u.pathname]),pathnameBase:Qa(Za([a,u.pathnameBase])),route:d}),u.pathnameBase!==`/`&&(a=Za([a,u.pathnameBase]))}return o}function za(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Ba(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,t,n)=>{let{paramName:r,isOptional:i}=t;if(r===`*`){let e=s[n]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let c=s[n];return i&&!c?e[r]=void 0:e[r]=(c||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function Ba(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),pa(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "`+e+`" will be treated as if it were `+(`"`+e.replace(/\*$/,`/*`)+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+(`please change the route path to "`+e.replace(/\*$/,`/*`)+`".`));let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n)=>(r.push({paramName:t,isOptional:n!=null}),n?`/?([^\\/]+)?`:`/([^\\/]+)`));return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function Va(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return pa(!1,`The URL path "`+e+`" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent `+(`encoding (`+t+`).`)),e}}function Ha(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}var Ua=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Wa=e=>Ua.test(e);function Ga(e,t){t===void 0&&(t=`/`);let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?va(e):e,a;if(n)if(Wa(n))a=n;else{if(n.includes(`//`)){let e=n;n=n.replace(/\/\/+/g,`/`),pa(!1,`Pathnames cannot have embedded double slashes - normalizing `+(e+` -> `+n))}a=n.startsWith(`/`)?Ka(n.substring(1),`/`):Ka(n,t)}else a=t;return{pathname:a,search:$a(r),hash:eo(i)}}function Ka(e,t){let n=t.replace(/\/+$/,``).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function qa(e,t,n,r){return`Cannot include a '`+e+`' character in a manually specified `+("`to."+t+"` field ["+JSON.stringify(r)+`]. Please separate it out to the `)+("`to."+n+"` field. Alternatively you may provide the full path as ")+`a string in <Link to="..."> and the router will parse it for you.`}function Ja(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function Ya(e,t){let n=Ja(e);return t?n.map((e,t)=>t===n.length-1?e.pathname:e.pathnameBase):n.map(e=>e.pathnameBase)}function Xa(e,t,n,r){r===void 0&&(r=!1);let i;typeof e==`string`?i=va(e):(i=q({},e),Y(!i.pathname||!i.pathname.includes(`?`),qa(`?`,`pathname`,`search`,i)),Y(!i.pathname||!i.pathname.includes(`#`),qa(`#`,`pathname`,`hash`,i)),Y(!i.search||!i.search.includes(`#`),qa(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=Ga(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var Za=e=>e.join(`/`).replace(/\/\/+/g,`/`),Qa=e=>e.replace(/\/+$/,``).replace(/^\/*/,`/`),$a=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,eo=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,to=class{constructor(e,t,n,r){r===void 0&&(r=!1),this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function no(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}var ro=[`post`,`put`,`patch`,`delete`],io=new Set(ro),ao=[`get`,...ro],oo=new Set(ao),so=new Set([301,302,303,307,308]),co=new Set([307,308]),lo={state:`idle`,location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},uo={state:`idle`,data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},fo={state:`unblocked`,proceed:void 0,reset:void 0,location:void 0},po=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,mo=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),ho=`remix-router-transitions`;function go(e){let t=e.window?e.window:typeof window<`u`?window:void 0,n=t!==void 0&&t.document!==void 0&&t.document.createElement!==void 0,r=!n;Y(e.routes.length>0,`You must provide a non-empty routes array to createRouter`);let i;if(e.mapRouteProperties)i=e.mapRouteProperties;else if(e.detectErrorBoundary){let t=e.detectErrorBoundary;i=e=>({hasErrorBoundary:t(e)})}else i=mo;let a={},o=Sa(e.routes,i,void 0,a),s,c=e.basename||`/`,l=e.dataStrategy||ko,u=e.patchRoutesOnNavigation,d=q({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),f=null,p=new Set,m=null,h=null,g=null,_=e.hydrationData!=null,v=Ca(o,e.history.location,c),y=!1,b=null;if(v==null&&!u){let t=Z(404,{pathname:e.history.location.pathname}),{matches:n,route:r}=Uo(o);v=n,b={[r.id]:t}}v&&!e.hydrationData&&We(v,o,e.history.location.pathname).active&&(v=null);let x;if(!v){if(x=!1,v=[],d.v7_partialHydration){let t=We(null,o,e.history.location.pathname);t.active&&t.matches&&(y=!0,v=t.matches)}}else if(v.some(e=>e.route.lazy))x=!1;else if(!v.some(e=>e.route.loader))x=!0;else if(d.v7_partialHydration){let t=e.hydrationData?e.hydrationData.loaderData:null,n=e.hydrationData?e.hydrationData.errors:null;if(n){let e=v.findIndex(e=>n[e.route.id]!==void 0);x=v.slice(0,e+1).every(e=>!So(e.route,t,n))}else x=v.every(e=>!So(e.route,t,n))}else x=e.hydrationData!=null;let S,C={historyAction:e.history.action,location:e.history.location,matches:v,initialized:x,navigation:lo,restoreScrollPosition:e.hydrationData==null?null:!1,preventScrollReset:!1,revalidation:`idle`,loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||b,fetchers:new Map,blockers:new Map},w=J.Pop,T=!1,E,D=!1,ee=new Map,O=null,k=!1,te=!1,ne=[],re=new Set,A=new Map,ie=0,ae=-1,oe=new Map,j=new Set,se=new Map,ce=new Map,M=new Set,le=new Map,N=new Map,P;function F(){if(f=e.history.listen(t=>{let{action:n,location:r,delta:i}=t;if(P){P(),P=void 0;return}pa(N.size===0||i!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let a=Le({currentLocation:C.location,nextLocation:r,historyAction:n});if(a&&i!=null){let t=new Promise(e=>{P=e});e.history.go(i*-1),Ie(a,{state:`blocked`,location:r,proceed(){Ie(a,{state:`proceeding`,proceed:void 0,reset:void 0,location:r}),t.then(()=>e.history.go(i))},reset(){let e=new Map(C.blockers);e.set(a,fo),I({blockers:e})}});return}return he(n,r)}),n){ds(t,ee);let e=()=>fs(t,ee);t.addEventListener(`pagehide`,e),O=()=>t.removeEventListener(`pagehide`,e)}return C.initialized||he(J.Pop,C.location,{initialHydration:!0}),S}function ue(){f&&f(),O&&O(),p.clear(),E&&E.abort(),C.fetchers.forEach((e,t)=>Oe(t)),C.blockers.forEach((e,t)=>Fe(t))}function de(e){return p.add(e),()=>p.delete(e)}function I(e,t){t===void 0&&(t={}),C=q({},C,e);let n=[],r=[];d.v7_fetcherPersist&&C.fetchers.forEach((e,t)=>{e.state===`idle`&&(M.has(t)?r.push(t):n.push(t))}),M.forEach(e=>{!C.fetchers.has(e)&&!A.has(e)&&r.push(e)}),[...p].forEach(e=>e(C,{deletedFetchers:r,viewTransitionOpts:t.viewTransitionOpts,flushSync:t.flushSync===!0})),d.v7_fetcherPersist?(n.forEach(e=>C.fetchers.delete(e)),r.forEach(e=>Oe(e))):r.forEach(e=>M.delete(e))}function fe(t,n,r){let{flushSync:i}=r===void 0?{}:r,a=C.actionData!=null&&C.navigation.formMethod!=null&&$(C.navigation.formMethod)&&C.navigation.state===`loading`&&t.state?._isRedirect!==!0,c;c=n.actionData?Object.keys(n.actionData).length>0?n.actionData:null:a?C.actionData:null;let l=n.loaderData?Bo(C.loaderData,n.loaderData,n.matches||[],n.errors):C.loaderData,u=C.blockers;u.size>0&&(u=new Map(u),u.forEach((e,t)=>u.set(t,fo)));let d=T===!0||C.navigation.formMethod!=null&&$(C.navigation.formMethod)&&t.state?._isRedirect!==!0;s&&=(o=s,void 0),k||w===J.Pop||(w===J.Push?e.history.push(t,t.state):w===J.Replace&&e.history.replace(t,t.state));let f;if(w===J.Pop){let e=ee.get(C.location.pathname);e&&e.has(t.pathname)?f={currentLocation:C.location,nextLocation:t}:ee.has(t.pathname)&&(f={currentLocation:t,nextLocation:C.location})}else if(D){let e=ee.get(C.location.pathname);e?e.add(t.pathname):(e=new Set([t.pathname]),ee.set(C.location.pathname,e)),f={currentLocation:C.location,nextLocation:t}}I(q({},n,{actionData:c,loaderData:l,historyAction:w,location:t,initialized:!0,navigation:lo,revalidation:`idle`,restoreScrollPosition:Ue(t,n.matches||C.matches),preventScrollReset:d,blockers:u}),{viewTransitionOpts:f,flushSync:i===!0}),w=J.Pop,T=!1,D=!1,k=!1,te=!1,ne=[]}async function pe(t,n){if(typeof t==`number`){e.history.go(t);return}let r=vo(C.location,C.matches,c,d.v7_prependBasename,t,d.v7_relativeSplatPath,n?.fromRouteId,n?.relative),{path:i,submission:a,error:o}=yo(d.v7_normalizeFormMethod,!1,r,n),s=C.location,l=ga(C.location,i,n&&n.state);l=q({},l,e.history.encodeLocation(l));let u=n&&n.replace!=null?n.replace:void 0,f=J.Push;u===!0?f=J.Replace:u===!1||a!=null&&$(a.formMethod)&&a.formAction===C.location.pathname+C.location.search&&(f=J.Replace);let p=n&&`preventScrollReset`in n?n.preventScrollReset===!0:void 0,m=(n&&n.flushSync)===!0,h=Le({currentLocation:s,nextLocation:l,historyAction:f});if(h){Ie(h,{state:`blocked`,location:l,proceed(){Ie(h,{state:`proceeding`,proceed:void 0,reset:void 0,location:l}),pe(t,n)},reset(){let e=new Map(C.blockers);e.set(h,fo),I({blockers:e})}});return}return await he(f,l,{submission:a,pendingError:o,preventScrollReset:p,replace:n&&n.replace,enableViewTransition:n&&n.viewTransition,flushSync:m})}function me(){if(we(),I({revalidation:`loading`}),C.navigation.state!==`submitting`){if(C.navigation.state===`idle`){he(C.historyAction,C.location,{startUninterruptedRevalidation:!0});return}he(w||C.historyAction,C.navigation.location,{overrideNavigation:C.navigation,enableViewTransition:D===!0})}}async function he(t,n,r){E&&E.abort(),E=null,w=t,k=(r&&r.startUninterruptedRevalidation)===!0,He(C.location,C.matches),T=(r&&r.preventScrollReset)===!0,D=(r&&r.enableViewTransition)===!0;let i=s||o,a=r&&r.overrideNavigation,l=r!=null&&r.initialHydration&&C.matches&&C.matches.length>0&&!y?C.matches:Ca(i,n,c),u=(r&&r.flushSync)===!0;if(l&&C.initialized&&!te&&Ko(C.location,n)&&!(r&&r.submission&&$(r.submission.formMethod))){fe(n,{matches:l},{flushSync:u});return}let d=We(l,i,n.pathname);if(d.active&&d.matches&&(l=d.matches),!l){let{error:e,notFoundMatches:t,route:r}=Re(n.pathname);fe(n,{matches:t,loaderData:{},errors:{[r.id]:e}},{flushSync:u});return}E=new AbortController;let f=Fo(e.history,n,E.signal,r&&r.submission),p;if(r&&r.pendingError)p=[Ho(l).route.id,{type:X.error,error:r.pendingError}];else if(r&&r.submission&&$(r.submission.formMethod)){let t=await ge(f,n,r.submission,l,d.active,{replace:r.replace,flushSync:u});if(t.shortCircuited)return;if(t.pendingActionResult){let[e,r]=t.pendingActionResult;if(Q(r)&&no(r.error)&&r.error.status===404){E=null,fe(n,{matches:t.matches,loaderData:{},errors:{[e]:r.error}});return}}l=t.matches||l,p=t.pendingActionResult,a=os(n,r.submission),u=!1,d.active=!1,f=Fo(e.history,f.url,f.signal)}let{shortCircuited:m,matches:h,loaderData:g,errors:_}=await _e(f,n,l,d.active,a,r&&r.submission,r&&r.fetcherSubmission,r&&r.replace,r&&r.initialHydration===!0,u,p);m||(E=null,fe(n,q({matches:h||l},Vo(p),{loaderData:g,errors:_})))}async function ge(t,n,r,i,a,o){if(o===void 0&&(o={}),we(),I({navigation:ss(n,r)},{flushSync:o.flushSync===!0}),a){let e=await Ge(i,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){let t=Ho(e.partialMatches).route.id;return{matches:e.partialMatches,pendingActionResult:[t,{type:X.error,error:e.error}]}}else if(e.matches)i=e.matches;else{let{notFoundMatches:e,error:t,route:r}=Re(n.pathname);return{matches:e,pendingActionResult:[r.id,{type:X.error,error:t}]}}}let s,l=is(i,n);if(!l.route.action&&!l.route.lazy)s={type:X.error,error:Z(405,{method:t.method,pathname:n.pathname,routeId:l.route.id})};else if(s=(await R(`action`,C,t,[l],i,null))[l.route.id],t.signal.aborted)return{shortCircuited:!0};if(Yo(s)){let n;return n=o&&o.replace!=null?o.replace:Po(s.response.headers.get(`Location`),new URL(t.url),c,e.history)===C.location.pathname+C.location.search,await L(t,s,!0,{submission:r,replace:n}),{shortCircuited:!0}}if(Jo(s))throw Z(400,{type:`defer-action`});if(Q(s)){let e=Ho(i,l.route.id);return(o&&o.replace)!==!0&&(w=J.Push),{matches:i,pendingActionResult:[e.route.id,s]}}return{matches:i,pendingActionResult:[l.route.id,s]}}async function _e(t,n,r,i,a,l,u,f,p,m,h){let g=a||os(n,l),_=l||u||as(g),v=!k&&(!d.v7_partialHydration||!p);if(i){if(v){let e=ve(h);I(q({navigation:g},e===void 0?{}:{actionData:e}),{flushSync:m})}let e=await Ge(r,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){let t=Ho(e.partialMatches).route.id;return{matches:e.partialMatches,loaderData:{},errors:{[t]:e.error}}}else if(e.matches)r=e.matches;else{let{error:e,notFoundMatches:t,route:r}=Re(n.pathname);return{matches:t,loaderData:{},errors:{[r.id]:e}}}}let y=s||o,[b,x]=xo(e.history,C,r,_,n,d.v7_partialHydration&&p===!0,d.v7_skipActionErrorRevalidation,te,ne,re,M,se,j,y,c,h);if(ze(e=>!(r&&r.some(t=>t.route.id===e))||b&&b.some(t=>t.route.id===e)),ae=++ie,b.length===0&&x.length===0){let e=Me();return fe(n,q({matches:r,loaderData:{},errors:h&&Q(h[1])?{[h[0]]:h[1].error}:null},Vo(h),e?{fetchers:new Map(C.fetchers)}:{}),{flushSync:m}),{shortCircuited:!0}}if(v){let e={};if(!i){e.navigation=g;let t=ve(h);t!==void 0&&(e.actionData=t)}x.length>0&&(e.fetchers=ye(x)),I(e,{flushSync:m})}x.forEach(e=>{Ae(e.key),e.controller&&A.set(e.key,e.controller)});let S=()=>x.forEach(e=>Ae(e.key));E&&E.signal.addEventListener(`abort`,S);let{loaderResults:w,fetcherResults:T}=await Ce(C,r,b,x,t);if(t.signal.aborted)return{shortCircuited:!0};E&&E.signal.removeEventListener(`abort`,S),x.forEach(e=>A.delete(e.key));let D=Wo(w);if(D)return await L(t,D.result,!0,{replace:f}),{shortCircuited:!0};if(D=Wo(T),D)return j.add(D.key),await L(t,D.result,!0,{replace:f}),{shortCircuited:!0};let{loaderData:ee,errors:O}=zo(C,r,w,h,x,T,le);le.forEach((e,t)=>{e.subscribe(n=>{(n||e.done)&&le.delete(t)})}),d.v7_partialHydration&&p&&C.errors&&(O=q({},C.errors,O));let oe=Me(),ce=Ne(ae),N=oe||ce||x.length>0;return q({matches:r,loaderData:ee,errors:O},N?{fetchers:new Map(C.fetchers)}:{})}function ve(e){if(e&&!Q(e[1]))return{[e[0]]:e[1].data};if(C.actionData)return Object.keys(C.actionData).length===0?null:C.actionData}function ye(e){return e.forEach(e=>{let t=C.fetchers.get(e.key),n=cs(void 0,t?t.data:void 0);C.fetchers.set(e.key,n)}),new Map(C.fetchers)}function be(e,t,n,i){if(r)throw Error(`router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.`);Ae(e);let a=(i&&i.flushSync)===!0,l=s||o,u=vo(C.location,C.matches,c,d.v7_prependBasename,n,d.v7_relativeSplatPath,t,i?.relative),f=Ca(l,u,c),p=We(f,l,u);if(p.active&&p.matches&&(f=p.matches),!f){Ee(e,t,Z(404,{pathname:u}),{flushSync:a});return}let{path:m,submission:h,error:g}=yo(d.v7_normalizeFormMethod,!0,u,i);if(g){Ee(e,t,g,{flushSync:a});return}let _=is(f,m),v=(i&&i.preventScrollReset)===!0;if(h&&$(h.formMethod)){xe(e,t,m,_,f,p.active,a,v,h);return}se.set(e,{routeId:t,path:m}),Se(e,t,m,_,f,p.active,a,v,h)}async function xe(t,n,r,i,a,l,u,f,p){we(),se.delete(t);function m(e){return!e.route.action&&!e.route.lazy?(Ee(t,n,Z(405,{method:p.formMethod,pathname:r,routeId:n}),{flushSync:u}),!0):!1}if(!l&&m(i))return;Te(t,ls(p,C.fetchers.get(t)),{flushSync:u});let h=new AbortController,g=Fo(e.history,r,h.signal,p);if(l){let e=await Ge(a,new URL(g.url).pathname,g.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){Ee(t,n,e.error,{flushSync:u});return}else if(!e.matches){Ee(t,n,Z(404,{pathname:r}),{flushSync:u});return}else if(a=e.matches,i=is(a,r),m(i))return}A.set(t,h);let _=ie,v=(await R(`action`,C,g,[i],a,t))[i.route.id];if(g.signal.aborted){A.get(t)===h&&A.delete(t);return}if(d.v7_fetcherPersist&&M.has(t)){if(Yo(v)||Q(v)){Te(t,us(void 0));return}}else{if(Yo(v))if(A.delete(t),ae>_){Te(t,us(void 0));return}else return j.add(t),Te(t,cs(p)),L(g,v,!1,{fetcherSubmission:p,preventScrollReset:f});if(Q(v)){Ee(t,n,v.error);return}}if(Jo(v))throw Z(400,{type:`defer-action`});let y=C.navigation.location||C.location,b=Fo(e.history,y,h.signal),x=s||o,S=C.navigation.state===`idle`?C.matches:Ca(x,C.navigation.location,c);Y(S,`Didn't find any matches after fetcher action`);let T=++ie;oe.set(t,T);let D=cs(p,v.data);C.fetchers.set(t,D);let[ee,O]=xo(e.history,C,S,p,y,!1,d.v7_skipActionErrorRevalidation,te,ne,re,M,se,j,x,c,[i.route.id,v]);O.filter(e=>e.key!==t).forEach(e=>{let t=e.key,n=C.fetchers.get(t),r=cs(void 0,n?n.data:void 0);C.fetchers.set(t,r),Ae(t),e.controller&&A.set(t,e.controller)}),I({fetchers:new Map(C.fetchers)});let k=()=>O.forEach(e=>Ae(e.key));h.signal.addEventListener(`abort`,k);let{loaderResults:ce,fetcherResults:N}=await Ce(C,S,ee,O,b);if(h.signal.aborted)return;h.signal.removeEventListener(`abort`,k),oe.delete(t),A.delete(t),O.forEach(e=>A.delete(e.key));let P=Wo(ce);if(P)return L(b,P.result,!1,{preventScrollReset:f});if(P=Wo(N),P)return j.add(P.key),L(b,P.result,!1,{preventScrollReset:f});let{loaderData:F,errors:ue}=zo(C,S,ce,void 0,O,N,le);if(C.fetchers.has(t)){let e=us(v.data);C.fetchers.set(t,e)}Ne(T),C.navigation.state===`loading`&&T>ae?(Y(w,`Expected pending action`),E&&E.abort(),fe(C.navigation.location,{matches:S,loaderData:F,errors:ue,fetchers:new Map(C.fetchers)})):(I({errors:ue,loaderData:Bo(C.loaderData,F,S,ue),fetchers:new Map(C.fetchers)}),te=!1)}async function Se(t,n,r,i,a,o,s,c,l){let u=C.fetchers.get(t);Te(t,cs(l,u?u.data:void 0),{flushSync:s});let d=new AbortController,f=Fo(e.history,r,d.signal);if(o){let e=await Ge(a,new URL(f.url).pathname,f.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){Ee(t,n,e.error,{flushSync:s});return}else if(e.matches)a=e.matches,i=is(a,r);else{Ee(t,n,Z(404,{pathname:r}),{flushSync:s});return}}A.set(t,d);let p=ie,m=(await R(`loader`,C,f,[i],a,t))[i.route.id];if(Jo(m)&&(m=await ns(m,f.signal,!0)||m),A.get(t)===d&&A.delete(t),!f.signal.aborted){if(M.has(t)){Te(t,us(void 0));return}if(Yo(m))if(ae>p){Te(t,us(void 0));return}else{j.add(t),await L(f,m,!1,{preventScrollReset:c});return}if(Q(m)){Ee(t,n,m.error);return}Y(!Jo(m),`Unhandled fetcher deferred data`),Te(t,us(m.data))}}async function L(r,i,a,o){let{submission:s,fetcherSubmission:l,preventScrollReset:u,replace:d}=o===void 0?{}:o;i.response.headers.has(`X-Remix-Revalidate`)&&(te=!0);let f=i.response.headers.get(`Location`);Y(f,`Expected a Location header on the redirect Response`),f=Po(f,new URL(r.url),c,e.history);let p=ga(C.location,f,{_isRedirect:!0});if(n){let n=!1;if(i.response.headers.has(`X-Remix-Reload-Document`))n=!0;else if(po.test(f)){let r=e.history.createURL(f);n=r.origin!==t.location.origin||Ha(r.pathname,c)==null}if(n){d?t.location.replace(f):t.location.assign(f);return}}E=null;let m=d===!0||i.response.headers.has(`X-Remix-Replace`)?J.Replace:J.Push,{formMethod:h,formAction:g,formEncType:_}=C.navigation;!s&&!l&&h&&g&&_&&(s=as(C.navigation));let v=s||l;co.has(i.response.status)&&v&&$(v.formMethod)?await he(m,p,{submission:q({},v,{formAction:f}),preventScrollReset:u||T,enableViewTransition:a?D:void 0}):await he(m,p,{overrideNavigation:os(p,s),fetcherSubmission:l,preventScrollReset:u||T,enableViewTransition:a?D:void 0})}async function R(e,t,n,r,o,s){let u,f={};try{u=await Ao(l,e,t,n,r,o,s,a,i)}catch(e){return r.forEach(t=>{f[t.route.id]={type:X.error,error:e}}),f}for(let[e,t]of Object.entries(u))if(qo(t)){let r=t.result;f[e]={type:X.redirect,response:No(r,n,e,o,c,d.v7_relativeSplatPath)}}else f[e]=await Mo(t);return f}async function Ce(t,n,r,i,a){let o=t.matches,s=R(`loader`,t,a,r,n,null),c=Promise.all(i.map(async n=>{if(n.matches&&n.match&&n.controller){let r=(await R(`loader`,t,Fo(e.history,n.path,n.controller.signal),[n.match],n.matches,n.key))[n.match.route.id];return{[n.key]:r}}else return Promise.resolve({[n.key]:{type:X.error,error:Z(404,{pathname:n.path})}})})),l=await s,u=(await c).reduce((e,t)=>Object.assign(e,t),{});return await Promise.all([es(n,l,a.signal,o,t.loaderData),ts(n,u,i)]),{loaderResults:l,fetcherResults:u}}function we(){te=!0,ne.push(...ze()),se.forEach((e,t)=>{A.has(t)&&re.add(t),Ae(t)})}function Te(e,t,n){n===void 0&&(n={}),C.fetchers.set(e,t),I({fetchers:new Map(C.fetchers)},{flushSync:(n&&n.flushSync)===!0})}function Ee(e,t,n,r){r===void 0&&(r={});let i=Ho(C.matches,t);Oe(e),I({errors:{[i.route.id]:n},fetchers:new Map(C.fetchers)},{flushSync:(r&&r.flushSync)===!0})}function De(e){return ce.set(e,(ce.get(e)||0)+1),M.has(e)&&M.delete(e),C.fetchers.get(e)||uo}function Oe(e){let t=C.fetchers.get(e);A.has(e)&&!(t&&t.state===`loading`&&oe.has(e))&&Ae(e),se.delete(e),oe.delete(e),j.delete(e),d.v7_fetcherPersist&&M.delete(e),re.delete(e),C.fetchers.delete(e)}function ke(e){let t=(ce.get(e)||0)-1;t<=0?(ce.delete(e),M.add(e),d.v7_fetcherPersist||Oe(e)):ce.set(e,t),I({fetchers:new Map(C.fetchers)})}function Ae(e){let t=A.get(e);t&&(t.abort(),A.delete(e))}function je(e){for(let t of e){let e=us(De(t).data);C.fetchers.set(t,e)}}function Me(){let e=[],t=!1;for(let n of j){let r=C.fetchers.get(n);Y(r,`Expected fetcher: `+n),r.state===`loading`&&(j.delete(n),e.push(n),t=!0)}return je(e),t}function Ne(e){let t=[];for(let[n,r]of oe)if(r<e){let e=C.fetchers.get(n);Y(e,`Expected fetcher: `+n),e.state===`loading`&&(Ae(n),oe.delete(n),t.push(n))}return je(t),t.length>0}function Pe(e,t){let n=C.blockers.get(e)||fo;return N.get(e)!==t&&N.set(e,t),n}function Fe(e){C.blockers.delete(e),N.delete(e)}function Ie(e,t){let n=C.blockers.get(e)||fo;Y(n.state===`unblocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`proceeding`||n.state===`blocked`&&t.state===`unblocked`||n.state===`proceeding`&&t.state===`unblocked`,`Invalid blocker state transition: `+n.state+` -> `+t.state);let r=new Map(C.blockers);r.set(e,t),I({blockers:r})}function Le(e){let{currentLocation:t,nextLocation:n,historyAction:r}=e;if(N.size===0)return;N.size>1&&pa(!1,`A router only supports one blocker at a time`);let i=Array.from(N.entries()),[a,o]=i[i.length-1],s=C.blockers.get(a);if(!(s&&s.state===`proceeding`)&&o({currentLocation:t,nextLocation:n,historyAction:r}))return a}function Re(e){let t=Z(404,{pathname:e}),{matches:n,route:r}=Uo(s||o);return ze(),{notFoundMatches:n,route:r,error:t}}function ze(e){let t=[];return le.forEach((n,r)=>{(!e||e(r))&&(n.cancel(),t.push(r),le.delete(r))}),t}function Be(e,t,n){if(m=e,g=t,h=n||null,!_&&C.navigation===lo){_=!0;let e=Ue(C.location,C.matches);e!=null&&I({restoreScrollPosition:e})}return()=>{m=null,g=null,h=null}}function Ve(e,t){return h&&h(e,t.map(e=>Ta(e,C.loaderData)))||e.key}function He(e,t){if(m&&g){let n=Ve(e,t);m[n]=g()}}function Ue(e,t){if(m){let n=Ve(e,t),r=m[n];if(typeof r==`number`)return r}return null}function We(e,t,n){if(u){if(!e)return{active:!0,matches:wa(t,n,c,!0)||[]};if(Object.keys(e[0].params).length>0)return{active:!0,matches:wa(t,n,c,!0)}}return{active:!1,matches:null}}async function Ge(e,t,n,r){if(!u)return{type:`success`,matches:e};let l=e;for(;;){let e=s==null,d=s||o,f=a;try{await u({signal:n,path:t,matches:l,fetcherKey:r,patch:(e,t)=>{n.aborted||Eo(e,t,d,f,i)}})}catch(e){return{type:`error`,error:e,partialMatches:l}}finally{e&&!n.aborted&&(o=[...o])}if(n.aborted)return{type:`aborted`};let p=Ca(d,t,c);if(p)return{type:`success`,matches:p};let m=wa(d,t,c,!0);if(!m||l.length===m.length&&l.every((e,t)=>e.route.id===m[t].route.id))return{type:`success`,matches:null};l=m}}function Ke(e){a={},s=Sa(e,i,void 0,a)}function qe(e,t){let n=s==null;Eo(e,t,s||o,a,i),n&&(o=[...o],I({}))}return S={get basename(){return c},get future(){return d},get state(){return C},get routes(){return o},get window(){return t},initialize:F,subscribe:de,enableScrollRestoration:Be,navigate:pe,fetch:be,revalidate:me,createHref:t=>e.history.createHref(t),encodeLocation:t=>e.history.encodeLocation(t),getFetcher:De,deleteFetcher:ke,dispose:ue,getBlocker:Pe,deleteBlocker:Fe,patchRoutes:qe,_internalFetchControllers:A,_internalActiveDeferreds:le,_internalSetRoutes:Ke},S}function _o(e){return e!=null&&(`formData`in e&&e.formData!=null||`body`in e&&e.body!==void 0)}function vo(e,t,n,r,i,a,o,s){let c,l;if(o){c=[];for(let e of t)if(c.push(e),e.route.id===o){l=e;break}}else c=t,l=t[t.length-1];let u=Xa(i||`.`,Ya(c,a),Ha(e.pathname,n)||e.pathname,s===`path`);if(i??(u.search=e.search,u.hash=e.hash),(i==null||i===``||i===`.`)&&l){let e=rs(u.search);if(l.route.index&&!e)u.search=u.search?u.search.replace(/^\?/,`?index&`):`?index`;else if(!l.route.index&&e){let e=new URLSearchParams(u.search),t=e.getAll(`index`);e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();u.search=n?`?`+n:``}}return r&&n!==`/`&&(u.pathname=u.pathname===`/`?n:Za([n,u.pathname])),_a(u)}function yo(e,t,n,r){if(!r||!_o(r))return{path:n};if(r.formMethod&&!$o(r.formMethod))return{path:n,error:Z(405,{method:r.formMethod})};let i=()=>({path:n,error:Z(400,{type:`invalid-body`})}),a=r.formMethod||`get`,o=e?a.toUpperCase():a.toLowerCase(),s=Go(n);if(r.body!==void 0){if(r.formEncType===`text/plain`){if(!$(o))return i();let e=typeof r.body==`string`?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((e,t)=>{let[n,r]=t;return``+e+n+`=`+r+`
|
|
36
|
+
`},``):String(r.body);return{path:n,submission:{formMethod:o,formAction:s,formEncType:r.formEncType,formData:void 0,json:void 0,text:e}}}else if(r.formEncType===`application/json`){if(!$(o))return i();try{let e=typeof r.body==`string`?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:o,formAction:s,formEncType:r.formEncType,formData:void 0,json:e,text:void 0}}}catch{return i()}}}Y(typeof FormData==`function`,`FormData is not available in this environment`);let c,l;if(r.formData)c=Io(r.formData),l=r.formData;else if(r.body instanceof FormData)c=Io(r.body),l=r.body;else if(r.body instanceof URLSearchParams)c=r.body,l=Lo(c);else if(r.body==null)c=new URLSearchParams,l=new FormData;else try{c=new URLSearchParams(r.body),l=Lo(c)}catch{return i()}let u={formMethod:o,formAction:s,formEncType:r&&r.formEncType||`application/x-www-form-urlencoded`,formData:l,json:void 0,text:void 0};if($(u.formMethod))return{path:n,submission:u};let d=va(n);return t&&d.search&&rs(d.search)&&c.append(`index`,``),d.search=`?`+c,{path:_a(d),submission:u}}function bo(e,t,n){n===void 0&&(n=!1);let r=e.findIndex(e=>e.route.id===t);return r>=0?e.slice(0,n?r+1:r):e}function xo(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h){let g=h?Q(h[1])?h[1].error:h[1].data:void 0,_=e.createURL(t.location),v=e.createURL(i),y=n;a&&t.errors?y=bo(n,Object.keys(t.errors)[0],!0):h&&Q(h[1])&&(y=bo(n,h[0]));let b=h?h[1].statusCode:void 0,x=o&&b&&b>=400,S=y.filter((e,n)=>{let{route:i}=e;if(i.lazy)return!0;if(i.loader==null)return!1;if(a)return So(i,t.loaderData,t.errors);if(Co(t.loaderData,t.matches[n],e)||c.some(t=>t===e.route.id))return!0;let o=t.matches[n],l=e;return To(e,q({currentUrl:_,currentParams:o.params,nextUrl:v,nextParams:l.params},r,{actionResult:g,actionStatus:b,defaultShouldRevalidate:x?!1:s||_.pathname+_.search===v.pathname+v.search||_.search!==v.search||wo(o,l)}))}),C=[];return d.forEach((e,i)=>{if(a||!n.some(t=>t.route.id===e.routeId)||u.has(i))return;let o=Ca(p,e.path,m);if(!o){C.push({key:i,routeId:e.routeId,path:e.path,matches:null,match:null,controller:null});return}let c=t.fetchers.get(i),d=is(o,e.path),h=!1;f.has(i)?h=!1:l.has(i)?(l.delete(i),h=!0):h=c&&c.state!==`idle`&&c.data===void 0?s:To(d,q({currentUrl:_,currentParams:t.matches[t.matches.length-1].params,nextUrl:v,nextParams:n[n.length-1].params},r,{actionResult:g,actionStatus:b,defaultShouldRevalidate:x?!1:s})),h&&C.push({key:i,routeId:e.routeId,path:e.path,matches:o,match:d,controller:new AbortController})}),[S,C]}function So(e,t,n){if(e.lazy)return!0;if(!e.loader)return!1;let r=t!=null&&t[e.id]!==void 0,i=n!=null&&n[e.id]!==void 0;return!r&&i?!1:typeof e.loader==`function`&&e.loader.hydrate===!0?!0:!r&&!i}function Co(e,t,n){let r=!t||n.route.id!==t.route.id,i=e[n.route.id]===void 0;return r||i}function wo(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith(`*`)&&e.params[`*`]!==t.params[`*`]}function To(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n==`boolean`)return n}return t.defaultShouldRevalidate}function Eo(e,t,n,r,i){let a;if(e){let t=r[e];Y(t,`No route found to patch children into: routeId = `+e),t.children||=[],a=t.children}else a=n;let o=Sa(t.filter(e=>!a.some(t=>Do(e,t))),i,[e||`_`,`patch`,String(a?.length||`0`)],r);a.push(...o)}function Do(e,t){return`id`in e&&`id`in t&&e.id===t.id?!0:e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive?(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children.every((e,n)=>t.children?.some(t=>Do(e,t))):!1}async function Oo(e,t,n){if(!e.lazy)return;let r=await e.lazy();if(!e.lazy)return;let i=n[e.id];Y(i,`No route found in manifest`);let a={};for(let e in r){let t=i[e]!==void 0&&e!==`hasErrorBoundary`;pa(!t,`Route "`+i.id+`" has a static property "`+e+`" defined but its lazy function is also returning a value for this property. `+(`The lazy route property "`+e+`" will be ignored.`)),!t&&!ba.has(e)&&(a[e]=r[e])}Object.assign(i,a),Object.assign(i,q({},t(i),{lazy:void 0}))}async function ko(e){let{matches:t}=e,n=t.filter(e=>e.shouldLoad);return(await Promise.all(n.map(e=>e.resolve()))).reduce((e,t,r)=>Object.assign(e,{[n[r].route.id]:t}),{})}async function Ao(e,t,n,r,i,a,o,s,c,l){let u=a.map(e=>e.route.lazy?Oo(e.route,c,s):void 0),d=await e({matches:a.map((e,n)=>{let a=u[n],o=i.some(t=>t.route.id===e.route.id);return q({},e,{shouldLoad:o,resolve:async n=>(n&&r.method===`GET`&&(e.route.lazy||e.route.loader)&&(o=!0),o?jo(t,r,e,a,n,l):Promise.resolve({type:X.data,result:void 0}))})}),request:r,params:a[0].params,fetcherKey:o,context:l});try{await Promise.all(u)}catch{}return d}async function jo(e,t,n,r,i,a){let o,s,c=r=>{let o,c=new Promise((e,t)=>o=t);s=()=>o(),t.signal.addEventListener(`abort`,s);let l=i=>typeof r==`function`?r({request:t,params:n.params,context:a},...i===void 0?[]:[i]):Promise.reject(Error(`You cannot call the handler for a route which defines a boolean `+(`"`+e+`" [routeId: `+n.route.id+`]`))),u=(async()=>{try{return{type:`data`,result:await(i?i(e=>l(e)):l())}}catch(e){return{type:`error`,result:e}}})();return Promise.race([u,c])};try{let i=n.route[e];if(r)if(i){let e,[t]=await Promise.all([c(i).catch(t=>{e=t}),r]);if(e!==void 0)throw e;o=t}else if(await r,i=n.route[e],i)o=await c(i);else if(e===`action`){let e=new URL(t.url),r=e.pathname+e.search;throw Z(405,{method:t.method,pathname:r,routeId:n.route.id})}else return{type:X.data,result:void 0};else if(i)o=await c(i);else{let e=new URL(t.url);throw Z(404,{pathname:e.pathname+e.search})}Y(o.result!==void 0,`You defined `+(e===`action`?`an action`:`a loader`)+` for route `+(`"`+n.route.id+`" but didn't return anything from your \``+e+"` ")+"function. Please return a value or `null`.")}catch(e){return{type:X.error,result:e}}finally{s&&t.signal.removeEventListener(`abort`,s)}return o}async function Mo(e){let{result:t,type:n}=e;if(Qo(t)){let e;try{let n=t.headers.get(`Content-Type`);e=n&&/\bapplication\/json\b/.test(n)?t.body==null?null:await t.json():await t.text()}catch(e){return{type:X.error,error:e}}return n===X.error?{type:X.error,error:new to(t.status,t.statusText,e),statusCode:t.status,headers:t.headers}:{type:X.data,data:e,statusCode:t.status,headers:t.headers}}if(n===X.error){if(Xo(t)){var r;if(t.data instanceof Error){var i;return{type:X.error,error:t.data,statusCode:t.init?.status,headers:(i=t.init)!=null&&i.headers?new Headers(t.init.headers):void 0}}return{type:X.error,error:new to(t.init?.status||500,void 0,t.data),statusCode:no(t)?t.status:void 0,headers:(r=t.init)!=null&&r.headers?new Headers(t.init.headers):void 0}}return{type:X.error,error:t,statusCode:no(t)?t.status:void 0}}if(Zo(t))return{type:X.deferred,deferredData:t,statusCode:t.init?.status,headers:t.init?.headers&&new Headers(t.init.headers)};if(Xo(t)){var a;return{type:X.data,data:t.data,statusCode:t.init?.status,headers:(a=t.init)!=null&&a.headers?new Headers(t.init.headers):void 0}}return{type:X.data,data:t}}function No(e,t,n,r,i,a){let o=e.headers.get(`Location`);if(Y(o,`Redirects returned/thrown from loaders/actions must have a Location header`),!po.test(o)){let s=r.slice(0,r.findIndex(e=>e.route.id===n)+1);o=vo(new URL(t.url),s,i,!0,o,a),e.headers.set(`Location`,o)}return e}function Po(e,t,n,r){let i=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];if(po.test(e)){let r=e,a=r.startsWith(`//`)?new URL(t.protocol+r):new URL(r);if(i.includes(a.protocol))throw Error(`Invalid redirect location`);let o=Ha(a.pathname,n)!=null;if(a.origin===t.origin&&o)return a.pathname+a.search+a.hash}try{let t=r.createURL(e);if(i.includes(t.protocol))throw Error(`Invalid redirect location`)}catch{}return e}function Fo(e,t,n,r){let i=e.createURL(Go(t)).toString(),a={signal:n};if(r&&$(r.formMethod)){let{formMethod:e,formEncType:t}=r;a.method=e.toUpperCase(),t===`application/json`?(a.headers=new Headers({"Content-Type":t}),a.body=JSON.stringify(r.json)):t===`text/plain`?a.body=r.text:t===`application/x-www-form-urlencoded`&&r.formData?a.body=Io(r.formData):a.body=r.formData}return new Request(i,a)}function Io(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r==`string`?r:r.name);return t}function Lo(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function Ro(e,t,n,r,i){let a={},o=null,s,c=!1,l={},u=n&&Q(n[1])?n[1].error:void 0;return e.forEach(n=>{if(!(n.route.id in t))return;let d=n.route.id,f=t[d];if(Y(!Yo(f),`Cannot handle redirect results in processLoaderData`),Q(f)){let t=f.error;if(u!==void 0&&(t=u,u=void 0),o||={},i)o[d]=t;else{let n=Ho(e,d);o[n.route.id]??(o[n.route.id]=t)}a[d]=void 0,c||(c=!0,s=no(f.error)?f.error.status:500),f.headers&&(l[d]=f.headers)}else Jo(f)?(r.set(d,f.deferredData),a[d]=f.deferredData.data,f.statusCode!=null&&f.statusCode!==200&&!c&&(s=f.statusCode),f.headers&&(l[d]=f.headers)):(a[d]=f.data,f.statusCode&&f.statusCode!==200&&!c&&(s=f.statusCode),f.headers&&(l[d]=f.headers))}),u!==void 0&&n&&(o={[n[0]]:u},a[n[0]]=void 0),{loaderData:a,errors:o,statusCode:s||200,loaderHeaders:l}}function zo(e,t,n,r,i,a,o){let{loaderData:s,errors:c}=Ro(t,n,r,o,!1);return i.forEach(t=>{let{key:n,match:r,controller:i}=t,o=a[n];if(Y(o,`Did not find corresponding fetcher result`),!(i&&i.signal.aborted))if(Q(o)){let t=Ho(e.matches,r?.route.id);c&&c[t.route.id]||(c=q({},c,{[t.route.id]:o.error})),e.fetchers.delete(n)}else if(Yo(o))Y(!1,`Unhandled fetcher revalidation redirect`);else if(Jo(o))Y(!1,`Unhandled fetcher deferred data`);else{let t=us(o.data);e.fetchers.set(n,t)}}),{loaderData:s,errors:c}}function Bo(e,t,n,r){let i=q({},t);for(let a of n){let n=a.route.id;if(t.hasOwnProperty(n)?t[n]!==void 0&&(i[n]=t[n]):e[n]!==void 0&&a.route.loader&&(i[n]=e[n]),r&&r.hasOwnProperty(n))break}return i}function Vo(e){return e?Q(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function Ho(e,t){return(t?e.slice(0,e.findIndex(e=>e.route.id===t)+1):[...e]).reverse().find(e=>e.route.hasErrorBoundary===!0)||e[0]}function Uo(e){let t=e.length===1?e[0]:e.find(e=>e.index||!e.path||e.path===`/`)||{id:`__shim-error-route__`};return{matches:[{params:{},pathname:``,pathnameBase:``,route:t}],route:t}}function Z(e,t){let{pathname:n,routeId:r,method:i,type:a,message:o}=t===void 0?{}:t,s=`Unknown Server Error`,c=`Unknown @remix-run/router error`;return e===400?(s=`Bad Request`,i&&n&&r?c=`You made a `+i+` request to "`+n+`" but `+('did not provide a `loader` for route "'+r+`", `)+`so there is no way to handle the request.`:a===`defer-action`?c=`defer() is not supported in actions`:a===`invalid-body`&&(c=`Unable to encode submission body`)):e===403?(s=`Forbidden`,c=`Route "`+r+`" does not match URL "`+n+`"`):e===404?(s=`Not Found`,c=`No route matches URL "`+n+`"`):e===405&&(s=`Method Not Allowed`,i&&n&&r?c=`You made a `+i.toUpperCase()+` request to "`+n+`" but `+('did not provide an `action` for route "'+r+`", `)+`so there is no way to handle the request.`:i&&(c=`Invalid request method "`+i.toUpperCase()+`"`)),new to(e||500,s,Error(c),!0)}function Wo(e){let t=Object.entries(e);for(let e=t.length-1;e>=0;e--){let[n,r]=t[e];if(Yo(r))return{key:n,result:r}}}function Go(e){let t=typeof e==`string`?va(e):e;return _a(q({},t,{hash:``}))}function Ko(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===``?t.hash!==``:e.hash===t.hash?!0:t.hash!==``}function qo(e){return Qo(e.result)&&so.has(e.result.status)}function Jo(e){return e.type===X.deferred}function Q(e){return e.type===X.error}function Yo(e){return(e&&e.type)===X.redirect}function Xo(e){return typeof e==`object`&&!!e&&`type`in e&&`data`in e&&`init`in e&&e.type===`DataWithResponseInit`}function Zo(e){let t=e;return t&&typeof t==`object`&&typeof t.data==`object`&&typeof t.subscribe==`function`&&typeof t.cancel==`function`&&typeof t.resolveData==`function`}function Qo(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.headers==`object`&&e.body!==void 0}function $o(e){return oo.has(e.toLowerCase())}function $(e){return io.has(e.toLowerCase())}async function es(e,t,n,r,i){let a=Object.entries(t);for(let o=0;o<a.length;o++){let[s,c]=a[o],l=e.find(e=>e?.route.id===s);if(!l)continue;let u=r.find(e=>e.route.id===l.route.id),d=u!=null&&!wo(u,l)&&(i&&i[l.route.id])!==void 0;Jo(c)&&d&&await ns(c,n,!1).then(e=>{e&&(t[s]=e)})}}async function ts(e,t,n){for(let r=0;r<n.length;r++){let{key:i,routeId:a,controller:o}=n[r],s=t[i];e.find(e=>e?.route.id===a)&&Jo(s)&&(Y(o,`Expected an AbortController for revalidating fetcher deferred result`),await ns(s,o.signal,!0).then(e=>{e&&(t[i]=e)}))}}async function ns(e,t,n){if(n===void 0&&(n=!1),!await e.deferredData.resolveData(t)){if(n)try{return{type:X.data,data:e.deferredData.unwrappedData}}catch(e){return{type:X.error,error:e}}return{type:X.data,data:e.deferredData.data}}}function rs(e){return new URLSearchParams(e).getAll(`index`).some(e=>e===``)}function is(e,t){let n=typeof t==`string`?va(t).search:t.search;if(e[e.length-1].route.index&&rs(n||``))return e[e.length-1];let r=Ja(e);return r[r.length-1]}function as(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:a,json:o}=e;if(!(!t||!n||!r)){if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(a!=null)return{formMethod:t,formAction:n,formEncType:r,formData:a,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function os(e,t){return t?{state:`loading`,location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:`loading`,location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function ss(e,t){return{state:`submitting`,location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function cs(e,t){return e?{state:`loading`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:`loading`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function ls(e,t){return{state:`submitting`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function us(e){return{state:`idle`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function ds(e,t){try{let n=e.sessionStorage.getItem(ho);if(n){let e=JSON.parse(n);for(let[n,r]of Object.entries(e||{}))r&&Array.isArray(r)&&t.set(n,new Set(r||[]))}}catch{}}function fs(e,t){if(t.size>0){let n={};for(let[e,r]of t)n[e]=[...r];try{e.sessionStorage.setItem(ho,JSON.stringify(n))}catch(e){pa(!1,`Failed to save applied view transitions in sessionStorage (`+e+`).`)}}}function ps(){return ps=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ps.apply(this,arguments)}var ms=z.createContext(null),hs=z.createContext(null),gs=z.createContext(null),_s=z.createContext(null),vs=z.createContext({outlet:null,matches:[],isDataRoute:!1}),ys=z.createContext(null);function bs(){return z.useContext(_s)!=null}function xs(){return!bs()&&Y(!1),z.useContext(_s).location}function Ss(){return z.useContext(_s).navigationType}function Cs(e){z.useContext(gs).static||z.useLayoutEffect(e)}function ws(){let{isDataRoute:e}=z.useContext(vs);return e?Hs():Ts()}function Ts(){!bs()&&Y(!1);let e=z.useContext(ms),{basename:t,future:n,navigator:r}=z.useContext(gs),{matches:i}=z.useContext(vs),{pathname:a}=xs(),o=JSON.stringify(Ya(i,n.v7_relativeSplatPath)),s=z.useRef(!1);return Cs(()=>{s.current=!0}),z.useCallback(function(n,i){if(i===void 0&&(i={}),!s.current)return;if(typeof n==`number`){r.go(n);return}let c=Xa(n,JSON.parse(o),a,i.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:Za([t,c.pathname])),(i.replace?r.replace:r.push)(c,i.state,i)},[t,r,o,a,e])}var Es=z.createContext(null);function Ds(e){let t=z.useContext(vs).outlet;return t&&z.createElement(Es.Provider,{value:e},t)}function Os(){let{matches:e}=z.useContext(vs),t=e[e.length-1];return t?t.params:{}}function ks(e,t,n,r){!bs()&&Y(!1);let{navigator:i}=z.useContext(gs),{matches:a}=z.useContext(vs),o=a[a.length-1],s=o?o.params:{};o&&o.pathname;let c=o?o.pathnameBase:`/`;o&&o.route;let l=xs(),u;if(t){let e=typeof t==`string`?va(t):t;!(c===`/`||e.pathname?.startsWith(c))&&Y(!1),u=e}else u=l;let d=u.pathname||`/`,f=d;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);f=`/`+d.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let p=Ca(e,{pathname:f}),m=Ps(p&&p.map(e=>Object.assign({},e,{params:Object.assign({},s,e.params),pathname:Za([c,i.encodeLocation?i.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:Za([c,i.encodeLocation?i.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])})),a,n,r);return t&&m?z.createElement(_s.Provider,{value:{location:ps({pathname:`/`,search:``,hash:``,state:null,key:`default`},u),navigationType:J.Pop}},m):m}function As(){let e=Vs(),t=no(e)?e.status+` `+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null;return z.createElement(z.Fragment,null,z.createElement(`h2`,null,`Unexpected Application Error!`),z.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?z.createElement(`pre`,{style:{padding:`0.5rem`,backgroundColor:`rgba(200,200,200, 0.5)`}},n):null,null)}var js=z.createElement(As,null),Ms=class extends z.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error(`React Router caught the following error during render`,e,t)}render(){return this.state.error===void 0?this.props.children:z.createElement(vs.Provider,{value:this.props.routeContext},z.createElement(ys.Provider,{value:this.state.error,children:this.props.component}))}};function Ns(e){let{routeContext:t,match:n,children:r}=e,i=z.useContext(ms);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),z.createElement(vs.Provider,{value:t},r)}function Ps(e,t,n,r){if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let a=e,o=n?.errors;if(o!=null){let e=a.findIndex(e=>e.route.id&&o?.[e.route.id]!==void 0);!(e>=0)&&Y(!1),a=a.slice(0,Math.min(a.length,e+1))}let s=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let e=0;e<a.length;e++){let t=a[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(c=e),t.route.id){let{loaderData:e,errors:r}=n,i=t.route.loader&&e[t.route.id]===void 0&&(!r||r[t.route.id]===void 0);if(t.route.lazy||i){s=!0,a=c>=0?a.slice(0,c+1):[a[0]];break}}}return a.reduceRight((e,r,i)=>{let l,u=!1,d=null,f=null;n&&(l=o&&r.route.id?o[r.route.id]:void 0,d=r.route.errorElement||js,s&&(c<0&&i===0?(Ws(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),u=!0,f=null):c===i&&(u=!0,f=r.route.hydrateFallbackElement||null)));let p=t.concat(a.slice(0,i+1)),m=()=>{let t;return t=l?d:u?f:r.route.Component?z.createElement(r.route.Component,null):r.route.element?r.route.element:e,z.createElement(Ns,{match:r,routeContext:{outlet:e,matches:p,isDataRoute:n!=null},children:t})};return n&&(r.route.ErrorBoundary||r.route.errorElement||i===0)?z.createElement(Ms,{location:n.location,revalidation:n.revalidation,component:d,error:l,children:m(),routeContext:{outlet:null,matches:p,isDataRoute:!0}}):m()},null)}var Fs=function(e){return e.UseBlocker=`useBlocker`,e.UseRevalidator=`useRevalidator`,e.UseNavigateStable=`useNavigate`,e}(Fs||{}),Is=function(e){return e.UseBlocker=`useBlocker`,e.UseLoaderData=`useLoaderData`,e.UseActionData=`useActionData`,e.UseRouteError=`useRouteError`,e.UseNavigation=`useNavigation`,e.UseRouteLoaderData=`useRouteLoaderData`,e.UseMatches=`useMatches`,e.UseRevalidator=`useRevalidator`,e.UseNavigateStable=`useNavigate`,e.UseRouteId=`useRouteId`,e}(Is||{});function Ls(e){let t=z.useContext(ms);return!t&&Y(!1),t}function Rs(e){let t=z.useContext(hs);return!t&&Y(!1),t}function zs(e){let t=z.useContext(vs);return!t&&Y(!1),t}function Bs(e){let t=zs(e),n=t.matches[t.matches.length-1];return!n.route.id&&Y(!1),n.route.id}function Vs(){let e=z.useContext(ys),t=Rs(Is.UseRouteError),n=Bs(Is.UseRouteError);return e===void 0?t.errors?.[n]:e}function Hs(){let{router:e}=Ls(Fs.UseNavigateStable),t=Bs(Is.UseNavigateStable),n=z.useRef(!1);return Cs(()=>{n.current=!0}),z.useCallback(function(r,i){i===void 0&&(i={}),n.current&&(typeof r==`number`?e.navigate(r):e.navigate(r,ps({fromRouteId:t},i)))},[e,t])}var Us={};function Ws(e,t,n){!t&&!Us[e]&&(Us[e]=!0)}var Gs=(e,t,n)=>(``+t+("You can use the `"+e+"` future flag to opt-in early. ")+(`For more information, see `+n+`.`),void 0);function Ks(e,t){e?.v7_startTransition===void 0&&Gs(`v7_startTransition`,"React Router will begin wrapping state updates in `React.startTransition` in v7",`https://reactrouter.com/v6/upgrading/future#v7_starttransition`),e?.v7_relativeSplatPath===void 0&&(!t||t.v7_relativeSplatPath===void 0)&&Gs(`v7_relativeSplatPath`,`Relative route resolution within Splat routes is changing in v7`,`https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath`),t&&(t.v7_fetcherPersist===void 0&&Gs(`v7_fetcherPersist`,`The persistence behavior of fetchers is changing in v7`,`https://reactrouter.com/v6/upgrading/future#v7_fetcherpersist`),t.v7_normalizeFormMethod===void 0&&Gs(`v7_normalizeFormMethod`,"Casing of `formMethod` fields is being normalized to uppercase in v7",`https://reactrouter.com/v6/upgrading/future#v7_normalizeformmethod`),t.v7_partialHydration===void 0&&Gs(`v7_partialHydration`,"`RouterProvider` hydration behavior is changing in v7",`https://reactrouter.com/v6/upgrading/future#v7_partialhydration`),t.v7_skipActionErrorRevalidation===void 0&&Gs(`v7_skipActionErrorRevalidation`,"The revalidation behavior after 4xx/5xx `action` responses is changing in v7",`https://reactrouter.com/v6/upgrading/future#v7_skipactionerrorrevalidation`))}z.startTransition;function qs(e){return Ds(e.context)}function Js(e){Y(!1)}function Ys(e){let{basename:t=`/`,children:n=null,location:r,navigationType:i=J.Pop,navigator:a,static:o=!1,future:s}=e;bs()&&Y(!1);let c=t.replace(/^\/*/,`/`),l=z.useMemo(()=>({basename:c,navigator:a,static:o,future:ps({v7_relativeSplatPath:!1},s)}),[c,s,a,o]);typeof r==`string`&&(r=va(r));let{pathname:u=`/`,search:d=``,hash:f=``,state:p=null,key:m=`default`}=r,h=z.useMemo(()=>{let e=Ha(u,c);return e==null?null:{location:{pathname:e,search:d,hash:f,state:p,key:m},navigationType:i}},[c,u,d,f,p,m,i]);return h==null?null:z.createElement(gs.Provider,{value:l},z.createElement(_s.Provider,{children:n,value:h}))}var Xs=function(e){return e[e.pending=0]=`pending`,e[e.success=1]=`success`,e[e.error=2]=`error`,e}(Xs||{});new Promise(()=>{}),z.Component;function Zs(e,t){t===void 0&&(t=[]);let n=[];return z.Children.forEach(e,(e,r)=>{if(!z.isValidElement(e))return;let i=[...t,r];if(e.type===z.Fragment){n.push.apply(n,Zs(e.props.children,i));return}e.type!==Js&&Y(!1),!(!e.props.index||!e.props.children)&&Y(!1);let a={id:e.props.id||i.join(`-`),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:e.props.ErrorBoundary!=null||e.props.errorElement!=null,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(a.children=Zs(e.props.children,i)),n.push(a)}),n}function Qs(e){let t={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(t,{element:z.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:z.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:z.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}function $s(){return $s=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$s.apply(this,arguments)}var ec=`6`;try{window.__reactRouterVersion=ec}catch{}function tc(e,t){return go({basename:t?.basename,future:$s({},t?.future,{v7_prependBasename:!0}),history:fa({window:t?.window}),hydrationData:t?.hydrationData||nc(),routes:e,mapRouteProperties:Qs,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window}).initialize()}function nc(){let e=window?.__staticRouterHydrationData;return e&&e.errors&&(e=$s({},e,{errors:rc(e.errors)})),e}function rc(e){if(!e)return null;let t=Object.entries(e),n={};for(let[e,r]of t)if(r&&r.__type===`RouteErrorResponse`)n[e]=new to(r.status,r.statusText,r.data,r.internal===!0);else if(r&&r.__type===`Error`){if(r.__subType){let t=window[r.__subType];if(typeof t==`function`)try{let i=new t(r.message);i.stack=``,n[e]=i}catch{}}if(n[e]==null){let t=Error(r.message);t.stack=``,n[e]=t}}else n[e]=r;return n}var ic=z.createContext({isTransitioning:!1}),ac=z.createContext(new Map),oc=z.startTransition,sc=fi.flushSync;z.useId;function cc(e){oc?oc(e):e()}function lc(e){sc?sc(e):e()}var uc=class{constructor(){this.status=`pending`,this.promise=new Promise((e,t)=>{this.resolve=t=>{this.status===`pending`&&(this.status=`resolved`,e(t))},this.reject=e=>{this.status===`pending`&&(this.status=`rejected`,t(e))}})}};function dc(e){let{fallbackElement:t,router:n,future:r}=e,[i,a]=z.useState(n.state),[o,s]=z.useState(),[c,l]=z.useState({isTransitioning:!1}),[u,d]=z.useState(),[f,p]=z.useState(),[m,h]=z.useState(),g=z.useRef(new Map),{v7_startTransition:_}=r||{},v=z.useCallback(e=>{_?cc(e):e()},[_]),y=z.useCallback((e,t)=>{let{deletedFetchers:r,flushSync:i,viewTransitionOpts:o}=t;e.fetchers.forEach((e,t)=>{e.data!==void 0&&g.current.set(t,e.data)}),r.forEach(e=>g.current.delete(e));let c=n.window==null||n.window.document==null||typeof n.window.document.startViewTransition!=`function`;if(!o||c){i?lc(()=>a(e)):v(()=>a(e));return}if(i){lc(()=>{f&&(u&&u.resolve(),f.skipTransition()),l({isTransitioning:!0,flushSync:!0,currentLocation:o.currentLocation,nextLocation:o.nextLocation})});let t=n.window.document.startViewTransition(()=>{lc(()=>a(e))});t.finished.finally(()=>{lc(()=>{d(void 0),p(void 0),s(void 0),l({isTransitioning:!1})})}),lc(()=>p(t));return}f?(u&&u.resolve(),f.skipTransition(),h({state:e,currentLocation:o.currentLocation,nextLocation:o.nextLocation})):(s(e),l({isTransitioning:!0,flushSync:!1,currentLocation:o.currentLocation,nextLocation:o.nextLocation}))},[n.window,f,u,g,v]);z.useLayoutEffect(()=>n.subscribe(y),[n,y]),z.useEffect(()=>{c.isTransitioning&&!c.flushSync&&d(new uc)},[c]),z.useEffect(()=>{if(u&&o&&n.window){let e=o,t=u.promise,r=n.window.document.startViewTransition(async()=>{v(()=>a(e)),await t});r.finished.finally(()=>{d(void 0),p(void 0),s(void 0),l({isTransitioning:!1})}),p(r)}},[v,o,u,n.window]),z.useEffect(()=>{u&&o&&i.location.key===o.location.key&&u.resolve()},[u,f,i.location,o]),z.useEffect(()=>{!c.isTransitioning&&m&&(s(m.state),l({isTransitioning:!0,flushSync:!1,currentLocation:m.currentLocation,nextLocation:m.nextLocation}),h(void 0))},[c.isTransitioning,m]),z.useEffect(()=>{},[]);let b=z.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:e=>n.navigate(e),push:(e,t,r)=>n.navigate(e,{state:t,preventScrollReset:r?.preventScrollReset}),replace:(e,t,r)=>n.navigate(e,{replace:!0,state:t,preventScrollReset:r?.preventScrollReset})}),[n]),x=n.basename||`/`,S=z.useMemo(()=>({router:n,navigator:b,static:!1,basename:x}),[n,b,x]),C=z.useMemo(()=>({v7_relativeSplatPath:n.future.v7_relativeSplatPath}),[n.future.v7_relativeSplatPath]);return z.useEffect(()=>Ks(r,n.future),[r,n.future]),z.createElement(z.Fragment,null,z.createElement(ms.Provider,{value:S},z.createElement(hs.Provider,{value:i},z.createElement(ac.Provider,{value:g.current},z.createElement(ic.Provider,{value:c},z.createElement(Ys,{basename:x,location:i.location,navigationType:i.historyAction,navigator:b,future:C},i.initialized||n.future.v7_partialHydration?z.createElement(fc,{routes:n.routes,future:n.future,state:i}):t))))),null)}var fc=z.memo(pc);function pc(e){let{routes:t,future:n,state:r}=e;return ks(t,void 0,r,n)}typeof window<`u`&&window.document!==void 0&&window.document.createElement;var mc;(function(e){e.UseScrollRestoration=`useScrollRestoration`,e.UseSubmit=`useSubmit`,e.UseSubmitFetcher=`useSubmitFetcher`,e.UseFetcher=`useFetcher`,e.useViewTransitionState=`useViewTransitionState`})(mc||={});var hc;(function(e){e.UseFetcher=`useFetcher`,e.UseFetchers=`useFetchers`,e.UseScrollRestoration=`useScrollRestoration`})(hc||={});function gc(){return gc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gc.apply(null,arguments)}var _c=[`shift`,`alt`,`meta`,`mod`,`ctrl`],vc={esc:`escape`,return:`enter`,".":`period`,",":`comma`,"-":`slash`," ":`space`,"`":`backquote`,"#":`backslash`,"+":`bracketright`,ShiftLeft:`shift`,ShiftRight:`shift`,AltLeft:`alt`,AltRight:`alt`,MetaLeft:`meta`,MetaRight:`meta`,OSLeft:`meta`,OSRight:`meta`,ControlLeft:`ctrl`,ControlRight:`ctrl`};function yc(e){return(e&&vc[e]||e||``).trim().toLowerCase().replace(/key|digit|numpad|arrow/,``)}function bc(e){return _c.includes(e)}function xc(e,t){return t===void 0&&(t=`,`),e.split(t)}function Sc(e,t,n){t===void 0&&(t=`+`);var r=e.toLocaleLowerCase().split(t).map(function(e){return yc(e)}),i={alt:r.includes(`alt`),ctrl:r.includes(`ctrl`)||r.includes(`control`),shift:r.includes(`shift`),meta:r.includes(`meta`),mod:r.includes(`mod`)},a=r.filter(function(e){return!_c.includes(e)});return gc({},i,{keys:a,description:n,hotkey:e})}(function(){typeof document<`u`&&(document.addEventListener(`keydown`,function(e){e.key!==void 0&&Ec([yc(e.key),yc(e.code)])}),document.addEventListener(`keyup`,function(e){e.key!==void 0&&Dc([yc(e.key),yc(e.code)])})),typeof window<`u`&&window.addEventListener(`blur`,function(){Cc.clear()})})();var Cc=new Set;function wc(e){return Array.isArray(e)}function Tc(e,t){return t===void 0&&(t=`,`),(wc(e)?e:e.split(t)).every(function(e){return Cc.has(e.trim().toLowerCase())})}function Ec(e){var t=Array.isArray(e)?e:[e];Cc.has(`meta`)&&Cc.forEach(function(e){return!bc(e)&&Cc.delete(e.toLowerCase())}),t.forEach(function(e){return Cc.add(e.toLowerCase())})}function Dc(e){e===`meta`?Cc.clear():(Array.isArray(e)?e:[e]).forEach(function(e){return Cc.delete(e.toLowerCase())})}function Oc(e,t,n){(typeof n==`function`&&n(e,t)||n===!0)&&e.preventDefault()}function kc(e,t,n){return typeof n==`function`?n(e,t):n===!0||n===void 0}function Ac(e){return jc(e,[`input`,`textarea`,`select`])}function jc(e,t){t===void 0&&(t=!1);var n=e.target,r=e.composed,i=null;return i=Mc(n)&&r?e.composedPath()[0]&&e.composedPath()[0].tagName:n&&n.tagName,wc(t)?!!(i&&t&&t.some(function(e){return e.toLowerCase()===i?.toLowerCase()})):!!(i&&t&&t)}function Mc(e){return!!e.tagName&&!e.tagName.startsWith(`-`)&&e.tagName.includes(`-`)}function Nc(e,t){return e.length===0&&t?(console.warn(`A hotkey has the "scopes" option set, however no active scopes were found. If you want to use the global scopes feature, you need to wrap your app in a <HotkeysProvider>`),!0):t?e.some(function(e){return t.includes(e)})||e.includes(`*`):!0}var Pc=function(e,t,n){n===void 0&&(n=!1);var r=t.alt,i=t.meta,a=t.mod,o=t.shift,s=t.ctrl,c=t.keys,l=e.key,u=e.code,d=e.ctrlKey,f=e.metaKey,p=e.shiftKey,m=e.altKey,h=yc(u),g=l.toLowerCase();if(!(c!=null&&c.includes(h))&&!(c!=null&&c.includes(g))&&![`ctrl`,`control`,`unknown`,`meta`,`alt`,`shift`,`os`].includes(h))return!1;if(!n){if(r===!m&&g!==`alt`||o===!p&&g!==`shift`)return!1;if(a){if(!f&&!d)return!1}else if(i===!f&&g!==`meta`&&g!==`os`||s===!d&&g!==`ctrl`&&g!==`control`)return!1}return c&&c.length===1&&(c.includes(g)||c.includes(h))?!0:c?Tc(c):!c},Fc=ni(void 0),Ic=function(){return ai(Fc)};function Lc(e,t){return e&&t&&typeof e==`object`&&typeof t==`object`?Object.keys(e).length===Object.keys(t).length&&Object.keys(e).reduce(function(n,r){return n&&Lc(e[r],t[r])},!0):e===t}var Rc=ni({hotkeys:[],enabledScopes:[],toggleScope:function(){},enableScope:function(){},disableScope:function(){}}),zc=function(){return ai(Rc)};function Bc(e){var t=ci(void 0);return Lc(t.current,e)||(t.current=e),t.current}var Vc=function(e){e.stopPropagation(),e.preventDefault(),e.stopImmediatePropagation()},Hc=typeof window<`u`?oi:V;function Uc(e,t,n,r){var i=li(null),a=i[0],o=i[1],s=ci(!1),c=n instanceof Array?r instanceof Array?void 0:r:n,l=wc(e)?e.join(c?.splitKey):e,u=n instanceof Array?n:r instanceof Array?r:void 0,d=ii(t,u??[]),f=ci(d);u?f.current=d:f.current=t;var p=Bc(c),m=zc().enabledScopes,h=Ic();return Hc(function(){if(!(p?.enabled===!1||!Nc(m,p?.scopes))){var e=function(e,t){var n;if(t===void 0&&(t=!1),!(Ac(e)&&!jc(e,p?.enableOnFormTags))){if(a!==null){var r=a.getRootNode();if((r instanceof Document||r instanceof ShadowRoot)&&r.activeElement!==a&&!a.contains(r.activeElement)){Vc(e);return}}(n=e.target)!=null&&n.isContentEditable&&!(p!=null&&p.enableOnContentEditable)||xc(l,p?.splitKey).forEach(function(n){var r,i=Sc(n,p?.combinationKey);if(Pc(e,i,p?.ignoreModifiers)||(r=i.keys)!=null&&r.includes(`*`)){if(p!=null&&p.ignoreEventWhen!=null&&p.ignoreEventWhen(e)||t&&s.current)return;if(Oc(e,i,p?.preventDefault),!kc(e,i,p?.enabled)){Vc(e);return}f.current(e,i),t||(s.current=!0)}})}},t=function(t){t.key!==void 0&&(Ec(yc(t.code)),(p?.keydown===void 0&&p?.keyup!==!0||p!=null&&p.keydown)&&e(t))},n=function(t){t.key!==void 0&&(Dc(yc(t.code)),s.current=!1,p!=null&&p.keyup&&e(t,!0))},r=a||c?.document||document;return r.addEventListener(`keyup`,n,c?.eventListenerOptions),r.addEventListener(`keydown`,t,c?.eventListenerOptions),h&&xc(l,p?.splitKey).forEach(function(e){return h.addHotkey(Sc(e,p?.combinationKey,p?.description))}),function(){r.removeEventListener(`keyup`,n,c?.eventListenerOptions),r.removeEventListener(`keydown`,t,c?.eventListenerOptions),h&&xc(l,p?.splitKey).forEach(function(e){return h.removeHotkey(Sc(e,p?.combinationKey,p?.description))})}}},[a,l,p,m]),o}var Wc=ni(null),Gc={didCatch:!1,error:null},Kc=class extends $r{constructor(e){super(e),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=Gc}static getDerivedStateFromError(e){return{didCatch:!0,error:e}}resetErrorBoundary(){let{error:e}=this.state;if(e!==null){var t,n,r=[...arguments];(t=(n=this.props).onReset)==null||t.call(n,{args:r,reason:`imperative-api`}),this.setState(Gc)}}componentDidCatch(e,t){var n,r;(n=(r=this.props).onError)==null||n.call(r,e,t)}componentDidUpdate(e,t){let{didCatch:n}=this.state,{resetKeys:r}=this.props;if(n&&t.error!==null&&qc(e.resetKeys,r)){var i,a;(i=(a=this.props).onReset)==null||i.call(a,{next:r,prev:e.resetKeys,reason:`keys`}),this.setState(Gc)}}render(){let{children:e,fallbackRender:t,FallbackComponent:n,fallback:r}=this.props,{didCatch:i,error:a}=this.state,o=e;if(i){let e={error:a,resetErrorBoundary:this.resetErrorBoundary};if(typeof t==`function`)o=t(e);else if(n)o=ri(n,e);else if(r!==void 0)o=r;else throw a}return ri(Wc.Provider,{value:{didCatch:i,error:a,resetErrorBoundary:this.resetErrorBoundary}},o)}};function qc(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e.length!==t.length||e.some((e,n)=>!Object.is(e,t[n]))}var Jc=`${I.routerBasename}:acceptedCookies`,Yc=new Set,Xc=Zc();function Zc(){try{let e=localStorage.getItem(Jc);return e?JSON.parse(e):{analytics:!1,marketing:!1,functional:!1}}catch{return{analytics:!1,marketing:!1,functional:!1}}}function Qc(){return Xc}function $c(e){Xc=e(Xc),localStorage.setItem(Jc,JSON.stringify(Xc)),Yc.forEach(e=>e())}function el(e){return Yc.add(e),()=>Yc.delete(e)}var tl=()=>[ui(el,Qc,Qc),$c],nl=[];function rl(){let e=M();return ui(t=>e?.subscribePending(t)??(()=>{}),()=>e?.getPendingInstallations()??nl)}var il=`${I.routerBasename}:display-cookie-banner`,al=new Set,ol=sl();function sl(){try{return localStorage.getItem(il)!==`false`}catch(e){return console.error(e),!0}}function cl(){return ol}function ll(e){ol=e,localStorage.setItem(il,JSON.stringify(e))}function ul(e){return al.add(e),()=>al.delete(e)}var dl=()=>[ui(ul,cl,cl),ll],fl=l([`sentry`]),pl=!1;async function ml(){return await F(()=>import(`./esm-C3z6RsQv.js`),__vite__mapDeps([0,1]))}async function hl(){I.sentry;let e=await ml(),t=[e.httpClientIntegration(),e.extraErrorDataIntegration({depth:5}),e.replayIntegration(),e.captureConsoleIntegration({levels:[`error`]})];I.sentry.tracing&&t.push(e.reactRouterV6BrowserTracingIntegration({useEffect:Qr.useEffect,useLocation:xs,useNavigationType:Ss,createRoutesFromChildren:Zs,matchRoutes:Ca})),e.init({release:I.sentry.release,dsn:I.sentry.dsn,environment:I.sentry.env,integrations:t,ignoreErrors:[`User is not allowed to create files`,`User is not allowed to move documents`,`The user aborted a request.`],sendDefaultPii:!0,tracesSampleRate:1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1,beforeSend(e,t){let n=t.originalException;return n instanceof TypeError&&n.message.includes(`Failed to fetch`)&&!navigator.onLine?null:e}}),pl=!0}async function gl(){if(pl)return(await ml()).getClient()?.close()}function _l(){let[e]=tl(),{analytics:t}=e;V(()=>{if(!t){gl().catch(e=>fl.error(`@error`,e));return}pl||!I.sentry.dsn||I.sentry.dsn===``||hl().catch(e=>fl.error(`@error`,e))},[t])}var vl=e=>{let{undo:t,redo:n,canRedo:r,canUndo:i}=e,a=window.navigator.userAgent.includes(`Mac`),o=`ctrl+z`,s=`ctrl+y`;a&&(o=`mod+z`,s=`mod+shift+z`),Uc(o,e=>{e.preventDefault(),i&&t()},{},[i,t]),Uc(s,e=>{e.preventDefault(),r&&n()},{},[r,n])};function yl(...e){window.dataLayer?.push(...e)}var bl=()=>{let e=I.gaTrackingId,[{analytics:t}]=tl(),n=e&&t;return V(()=>{if(n){let t=document.createElement(`script`);return t.src=`https://www.googletagmanager.com/gtag/js?id=${e}`,t.async=!0,document.head.appendChild(t),window.dataLayer=window.dataLayer||[],yl(`js`,new Date),yl(`config`,e),()=>{document.head.removeChild(t)}}},[n,e]),null};function xl(){let[e]=re(),t=se(e.header.id),n=ii(()=>{b(e).length?m({type:`exportDocumentWithErrors`,documentId:e.header.id}):ne(e).catch(e=>{console.error(e),me(`Failed to export document: ${e instanceof Error?e.message:JSON.stringify(e,null,1)}`)})},[e]),r=si(()=>async()=>{},[]),i=ii(()=>{_(t)},[t,_]);return H(`div`,{id:`document-editor-container`,className:`flex-1`,"data-document-type":e.header.documentType,children:H(Iu,{document:e,onClose:i,onExport:n,onOpenSwitchboardLink:r})})}function Sl(e){let[t,n]=li(!1);if(V(()=>{setTimeout(()=>{n(!0)},e.loadingTimeout??200)},[e]),!t)return null;let{customEditorLoader:r,...i}=e;return r?H(di,{children:r}):H(Le,{...i})}var Cl=l([`Connect`]);function wl(e){return`fallbackRender`in e}function Tl(){return null}function El({message:e=`Something went wrong`}){return H(`div`,{className:`text-center`,children:e})}function Dl({error:e,resetErrorBoundary:t}){let n=e instanceof Error?e.message:String(e),r=e instanceof Error?e.stack??String(e.cause):JSON.stringify(e,null,2);return H(`div`,{className:`z-10 mx-auto flex max-w-[80%] flex-1 items-center justify-center p-6`,children:U(`div`,{className:`w-full max-w-lg rounded-lg border border-gray-500 bg-white p-6 shadow-sm`,children:[U(`div`,{className:`mb-3 flex items-center gap-2`,children:[H(fe,{name:`Error`,className:`size-5 shrink-0`}),H(`h1`,{className:`text-lg font-semibold`,children:`Something went wrong`})]}),H(`p`,{className:`mb-4 text-sm text-gray-700`,children:n}),r!==`{}`&&U(`details`,{className:`group`,children:[H(`summary`,{className:`cursor-pointer select-none text-sm font-medium text-gray-700 underline hover:text-gray-700`,children:`Show details`}),H(`pre`,{className:`mt-2 max-h-48 overflow-auto rounded bg-gray-100 p-3 text-xs`,children:r})]}),H(pe,{type:`button`,onClick:t,className:`text-md mt-4 px-3 py-1.5 font-medium`,children:`Try again`})]})})}function Ol({error:e}){return H(`div`,{className:`flex size-full items-center justify-center`,children:H(`h3`,{className:`text-lg font-semibold`,children:e instanceof Error?e.message:String(e)})})}function kl(e,t){switch(e){case`silent`:return Tl;case`text`:return()=>H(El,{message:t});case`detailed`:return Dl;default:return Ol}}function Al(e){let{children:t,onError:n,resetKeys:r,loggerContext:i}=e;return H(Kc,{fallbackRender:wl(e)?e.fallbackRender:kl(e.variant,e.fallbackMessage),onError:(e,t)=>{if(e.message.includes(`Failed to fetch dynamically imported module`)&&e.message.includes(`node_modules/.vite`)){console.error(e),console.log(`Outdated chunk detected, reloading page...`),window.location.reload();return}(i?l(i):Cl).error(`@error @info`,e,t),n?.(e,t)},resetKeys:r,children:t})}function jl(){let[e]=j(),t=A(),n=y(e.header.meta?.preferredEditor),r=p(),i=n?.Component??r?.Component??Ee.Component;if(!i)throw Error(`No app component found`);return H(Al,{variant:`detailed`,resetKeys:[e.header.id],loggerContext:[`Connect`,`App`],children:H(ti,{fallback:H(Sl,{}),children:H(Ne,{className:`flex h-full flex-col overflow-auto`,children:H(i,{children:t?H(xl,{}):null})})})})}function Ml(){return typeof document>`u`?`/`:document.querySelector(`base`)?.getAttribute(`href`)||`/`}var Nl=null,Pl=new Set;function Fl(e){Nl=e;for(let e of Pl)e()}function Il(){return Nl}function Ll(e){return Pl.add(e),()=>{Pl.delete(e)}}var Rl=`ph-pglite-backup::`,zl=`ph:pglite-backups`,Bl=720*60*60*1e3,Vl={16:async()=>{let[{PGlite:e},{pgDump:t}]=await Promise.all([F(()=>import(`./dist-ClzcOFHf.js`),__vite__mapDeps([2,1,3,4,5,6,7])),F(()=>import(`./pg_dump-DpLFvU0N.js`),__vite__mapDeps([8,1,3]))]);return async n=>{let r=new e(`idb://${n.replace(/^\/pglite\//,``)}`);try{return await r.waitReady,await(await t({pg:r})).text()}finally{await r.close()}}}};function Hl(e,t=15e3){return new Promise((n,r)=>{let i=indexedDB.deleteDatabase(e),a=!1,o=e=>{a||(a=!0,e())},s=setTimeout(()=>o(()=>r(Error(`IDB delete timed out for ${e} after ${t}ms`))),t);i.onsuccess=()=>o(()=>{clearTimeout(s),n()}),i.onerror=()=>o(()=>{clearTimeout(s),r(be(i,`IDB delete failed for ${e}`))})})}async function Ul(e){let t=await xe(e,21,L);try{await new Promise((n,r)=>{let i=t.transaction(R,`readwrite`);i.oncomplete=()=>n(),i.onerror=()=>r(be(i,`FILE_DATA clear failed for ${e}`)),i.onabort=()=>r(be(i,`FILE_DATA clear aborted for ${e}`)),i.objectStore(R).clear()})}finally{t.close()}}async function Wl(e,t){let n=await xe(e,21,L);try{let r=await xe(t,21,L);try{let i=n.transaction(R,`readonly`).objectStore(R),a=await new Promise((t,n)=>{let r=[],a=i.openCursor();a.onerror=()=>n(be(a,`FILE_DATA read cursor failed for ${e}`)),a.onsuccess=()=>{let e=a.result;if(!e)return t(r);r.push({key:e.key,value:e.value}),e.continue()}});await new Promise((e,n)=>{let i=r.transaction(R,`readwrite`);i.oncomplete=()=>e(),i.onerror=()=>n(be(i,`FILE_DATA write failed for ${t}`)),i.onabort=()=>n(be(i,`FILE_DATA write aborted for ${t}`));let o=i.objectStore(R);o.clear();for(let{key:e,value:t}of a)o.put(t,e)})}finally{r.close()}}finally{n.close()}}function Gl(){try{let e=localStorage.getItem(zl);if(!e)return[];let t=JSON.parse(e);return Array.isArray(t)?t:[]}catch{return[]}}function Kl(e){try{localStorage.setItem(zl,JSON.stringify(e))}catch{}}function ql(e){Kl([...Gl(),e])}function Jl(e){Kl(Gl().filter(t=>t.name!==e))}async function Yl(){let e=Date.now()-Bl,t=[];for(let n of Gl()){if(n.createdAt>=e){t.push(n);continue}try{await Hl(n.name)}catch(e){console.warn(`Failed to delete expired pglite backup ${n.name}`,e),t.push(n)}}Kl(t)}function Xl(e,t){Fl({idbName:e,phase:t})}async function Zl(e){let t=await Ce(e);if(t===null||t===17)return;let n=Vl[t];if(!n)throw Error(`Unsupported legacy PGlite data dir: PG_VERSION=${t} for ${e}`);let r=`${Rl}${e}::${new Date().toISOString()}`,i={name:r,idbName:e,createdAt:Date.now()};Xl(e,`clone`),await Wl(e,r),ql(i);let a;try{Xl(e,`dump`),a=await(await n())(e)}catch(e){throw await Hl(r).catch(()=>{}),Jl(r),e}try{await Ul(e),Xl(e,`restore`);let t=new He(`idb://${e.replace(/^\/pglite\//,``)}`,{relaxedDurability:!1});try{await t.waitReady,console.info(`[pglite-migration] Dump preamble (first 500 chars):\n${a.slice(0,500)}`);try{await t.exec(`SET standard_conforming_strings = off;`)}catch(e){console.warn(`[pglite-migration] Could not force standard_conforming_strings=off`,e)}try{await t.exec(a)}catch(t){throw Ql(e,a,t),t}}finally{await t.close()}}catch(t){throw await $l(e,r,t),t}}function Ql(e,t,n){let r=n,i=typeof r.position==`string`?parseInt(r.position,10):typeof r.position==`number`?r.position:NaN;if(console.error(`[pglite-migration] Restore failed for ${e}`,{message:r.message,code:r.code,severity:r.severity,detail:r.detail,where:r.where,position:r.position,sqlLength:t.length}),Number.isFinite(i)&&i>0){let e=i-1,n=Math.max(0,e-200),r=Math.min(t.length,e+200),a=t.slice(n,e),o=t.slice(e,e+1),s=t.slice(e+1,r);console.error(`[pglite-migration] SQL context around position ${i}:\n${a}»${o}«${s}`);let c=t.lastIndexOf(`
|
|
37
37
|
`,e)+1,l=t.indexOf(`
|
|
38
|
-
`,e),u=t.slice(c,l===-1?t.length:l);console.error(`[pglite-migration] Failing line (truncated to 500 chars):\n${u.slice(0,500)}`)}else console.error(`[pglite-migration] No position info. First 2000 chars of dump:\n${t.slice(0,2e3)}`)}async function
|
|
38
|
+
`,e),u=t.slice(c,l===-1?t.length:l);console.error(`[pglite-migration] Failing line (truncated to 500 chars):\n${u.slice(0,500)}`)}else console.error(`[pglite-migration] No position info. First 2000 chars of dump:\n${t.slice(0,2e3)}`)}async function $l(e,t,n){try{await Ul(e).catch(()=>{}),await Wl(t,e)}catch(t){console.error(`PGlite migration failed AND rollback failed for ${e}. Primary error:`,n,`Rollback error:`,t);return}await Hl(t).catch(()=>{}),Jl(t)}async function eu(){for(let e of we)await Zl(e);Fl(null)}async function tu(){if(Yl().catch(e=>console.warn(`PGlite backup janitor failed`,e)),!(typeof navigator<`u`&&`locks`in navigator&&typeof navigator.locks.request==`function`)){await eu();return}await navigator.locks.request(`ph-pglite-migration`,{mode:`exclusive`},async()=>{await eu()})}var nu=250,ru={clone:`Backing up local database…`,dump:`Exporting data from previous version…`,restore:`Restoring data into the new database…`},iu=()=>{let e=ui(Ll,Il,()=>null);return e?H(`div`,{className:`absolute inset-0 z-20 flex items-center justify-center`,children:U(`div`,{className:`rounded-lg bg-white/90 px-6 py-4 text-sm text-gray-900 shadow-lg`,children:[H(`div`,{className:`font-medium`,children:`Upgrading local database…`}),H(`div`,{className:`text-gray-600`,children:ru[e.phase]})]})}):null},au=({delay:e=nu})=>{let t=typeof window>`u`,n=typeof document<`u`&&document.body.getAttribute(`data-show-loader`)===`true`,[r,i]=li(!e||n);return V(()=>{let t=setTimeout(()=>{i(!0)},e);return()=>clearTimeout(t)},[]),U(`div`,{className:`skeleton-loader absolute inset-0 z-10 flex items-center justify-center ${r?``:`hidden`}`,children:[H(`div`,{className:`animate-pulse overflow-hidden rounded-full shadow-lg`,children:H(Re,{})}),t?H(`script`,{dangerouslySetInnerHTML:{__html:`setTimeout(() => {
|
|
39
39
|
document.querySelector('.skeleton-loader')?.classList.remove('hidden');
|
|
40
40
|
document.body.setAttribute('data-show-loader', 'true');
|
|
41
|
-
}, ${e})`}}):null]})},
|
|
41
|
+
}, ${e})`}}):null]})},ou=e=>{let t=typeof window>`u`,n=!t&&window.location.pathname===Ml();return U(`div`,{className:`flex h-screen overflow-hidden`,children:[H(Fe,{className:`animate-pulse`,onLogin:void 0,onDisconnect:void 0,onClickSettings:void 0,address:void 0}),H(Ve,{containerClassName:t||!n?`hidden home-screen`:void 0,children:e.children??null}),t?H(`script`,{dangerouslySetInnerHTML:{__html:`
|
|
42
42
|
const baseEl = document.querySelector('base');
|
|
43
43
|
const href = baseEl?.getAttribute('href');
|
|
44
44
|
const basePath = href || '/';
|
|
45
45
|
if (window.location.pathname === basePath) {
|
|
46
46
|
document.querySelector('.home-screen')?.classList.remove('hidden')
|
|
47
|
-
}`}}):null,e.children?null:H(El,{}),H(Tl,{})]})},Ol=!1,kl=new Set;function Al(){for(let e of kl)e()}function jl(){Ol=!0,Al()}function Ml(e){return kl.add(e),()=>{kl.delete(e)}}function Nl(){return Ol}var Pl=()=>{let e=jr(Ml,Nl,()=>!1),t=jr(Se,Ee,()=>void 0),[n,r]=Ar(!1),[i,a]=Ar(null);return t==null||t===17||e?null:H(`div`,{className:`absolute inset-x-0 top-0 z-30 flex justify-center p-3`,children:U(`div`,{className:`flex max-w-3xl items-center gap-3 rounded-lg border border-yellow-500 bg-yellow-400 px-4 py-3 text-sm text-gray-900 shadow-lg`,children:[U(`div`,{className:`flex-1`,children:[U(`div`,{className:`font-semibold`,children:[`Your local database uses Postgres `,t,`.`]}),U(`div`,{className:`text-gray-800`,children:[`Migrate to Postgres `,17,` to pick up the latest features. Your data will be backed up first.`]}),i&&U(`div`,{className:`mt-2 font-medium text-red-900`,children:[`Migration failed: `,i]})]}),H(`button`,{type:`button`,disabled:n,onClick:()=>{a(null),r(!0),Sl().then(()=>{window.location.reload()}).catch(e=>{a(e instanceof Error?e.message:String(e)),r(!1)})},className:`rounded bg-gray-900 px-3 py-1 text-sm font-medium text-white hover:bg-gray-800 disabled:opacity-50`,children:n?`Migrating…`:`Migrate now`}),H(`button`,{type:`button`,disabled:n,onClick:jl,className:`rounded border border-gray-900 bg-transparent px-3 py-1 text-sm font-medium text-gray-900 hover:bg-gray-900/10 disabled:opacity-50`,children:`Dismiss`})]})})},Fl=B(()=>F(()=>import(`./AddDriveModal-CBbXwG8S-CMtP_pYy.js`).then(e=>({default:e.AddDriveModal})),__vite__mapDeps([9,10,1,3,11,12,13,14,15,16,17,18,19,20]))),Il=B(()=>F(()=>import(`./ClearStorageModal-DwiCY6Lt-BX6HLKHK.js`).then(e=>({default:e.ClearStorageModal})),__vite__mapDeps([21,10,1,3,11,12,13,14,15,16,17,18,22,23,24,19,25,26,27,28,29,30,31,32,33,34,35,36,37]))),Ll=B(()=>F(()=>import(`./CookiesPolicyModal-CTXUu4-8-CDv9A_Ye.js`).then(e=>({default:e.CookiesPolicyModal})),__vite__mapDeps([38,10,1,3,11,12,13,14,15,16,17,18,39,20,37]))),Rl=B(()=>F(()=>import(`./CreateDocumentModal-CAld-5pv-CgcRndoo.js`).then(e=>({default:e.CreateDocumentModal})),__vite__mapDeps([40,10,1,3,11,12,13,14,15,16,17,18]))),zl=B(()=>F(()=>import(`./DebugSettingsModal-DeZ-x8H3-kFKY1yIP.js`).then(e=>({default:e.DebugSettingsModal})),__vite__mapDeps([41,10,1,3,11,12,13,14,15,16,17,18,23,42]))),Bl=B(()=>F(()=>import(`./DeleteDriveModal-B7T2CVIX-Ij3dGsPx.js`).then(e=>({default:e.DeleteDriveModal})),__vite__mapDeps([43,10,1,3,11,12,13,14,15,16,17,18,19,37]))),Vl=B(()=>F(()=>import(`./DeleteItemModal-DJv71YQG-CVtPVgc9.js`).then(e=>({default:e.DeleteItemModal})),__vite__mapDeps([44,10,1,3,11,12,13,14,15,16,17,18,19,37]))),Hl=B(()=>F(()=>import(`./DisclaimerModal-Co13N7HH-DNe510Y-.js`).then(e=>({default:e.DisclaimerModal})),__vite__mapDeps([45,10,1,3,11,12,13,14,15,16,17,18,37]))),Ul=B(()=>F(()=>import(`./DriveSettingsModal-DmsUU0g3-CAC1UDo_.js`).then(e=>({default:e.DriveSettingsModal})),__vite__mapDeps([46,10,1,3,11,12,13,14,15,16,17,18]))),Wl=B(()=>F(()=>import(`./ExportDocumentWithErrorsModal-DOV_UVlM-CuR2gzWI.js`).then(e=>({default:e.ExportDocumentWithErrorsModal})),__vite__mapDeps([47,10,1,3,11,12,13,14,15,16,17,18,37]))),Gl=B(()=>F(()=>import(`./SettingsModal-BzvCwJLZ-YPWkTKes.js`).then(e=>({default:e.SettingsModal})),__vite__mapDeps([48,10,1,3,11,12,13,14,15,16,17,18,23,49,19,50,20]))),Kl=B(()=>F(()=>import(`./UpgradeDriveModal-BH4ecdCU-Ds9YPtnh.js`).then(e=>({default:e.UpgradeDriveModal})),__vite__mapDeps([51,10,1,3,11,12,13,14,15,16,17,18,37]))),ql={addDrive:Fl,clearStorage:Il,cookiesPolicy:Ll,createDocument:Rl,debugSettings:zl,deleteDrive:Bl,deleteItem:Vl,disclaimer:Hl,driveSettings:Ul,exportDocumentWithErrors:Wl,inspector:B(()=>F(()=>import(`./InspectorModal-NoO3f3U7-CJAiPdEE.js`).then(e=>({default:e.InspectorModal})),__vite__mapDeps([52,10,1,3,11,12,13,14,15,16,17,18,22,23,24,19,25,26,27,28,29,30,31,32,33,34,35,36,53]))),settings:Gl,upgradeDrive:Kl,missingPackage:B(()=>F(()=>import(`./MissingPackageModal-Df154H9n-CBAwY4mw.js`).then(e=>({default:e.ConnectMissingPackageModal})),__vite__mapDeps([54,10,1,3,11,12,13,14,15,16,17,18,50])))},Jl=B(async()=>({default:()=>{let e=O();if(!e?.type)return null;let t=ql[e.type];return t?H(Zc,{variant:`silent`,loggerContext:[`Connect`,`Modals`],children:H(Sr,{fallback:null,children:H(t,{})})}):null}})),Yl=e=>{let t=B(()=>F(()=>import(`./load-C0mYtbHx-C7vYfEJ_.js`).then(t=>t.loadComponent(e.localPackage)),__vite__mapDeps([55,13,1,3,11,14,22,23,17,24,19,12,25,26,27,28,29,30,31,32,33,34,35,36,49,53,0,37])));return H(xr,{children:U(Zc,{fallbackRender:e=>H(Dl,{children:H(Jc,{...e})}),resetKeys:[e.localPackage],loggerContext:[`Connect`],children:[H(Sr,{fallback:H(Dl,{}),name:`AppLoader`,children:H(t,{...e,children:H(Ql,{})})}),H(Sr,{name:`CookieBanner`,children:H(eu,{})}),H(Sr,{name:`ModalsContainer`,children:H(Jl,{})}),H(Pl,{})]})})},Xl=({children:e})=>(Rc(),e);function Zl(){let e=wc(),t=M();return!t||e.length===0?null:H(Ae,{pendingInstallations:e.flatMap(e=>e.packageNames.map(t=>({documentType:e.documentType,packageName:t}))),onInstall:e=>t.approveInstallation(e),onDismiss:e=>t.dismissInstallation(e)})}var Ql=()=>(V(()=>{let e=e=>{let t=e.payload,n=(t instanceof Error?t.message:String(t??``)).match(/https?:\/\/[^\s"']+/)?.[0];if(n&&!n.startsWith(window.location.origin)){console.debug(`[Connect] Skipping reload — vite:preloadError for off-origin URL: ${n}`);return}console.log(`Outdated chunks detected, reloading page...`),window.location.reload()};return window.addEventListener(`vite:preloadError`,e),()=>{window.removeEventListener(`vite:preloadError`,e)}},[]),V(()=>{De.registerServiceWorker(!1)},[]),U(Xl,{children:[H(he,{position:`bottom-right`}),H(_u,{}),H(Zl,{}),H(Vc,{})]})),$l=(e,t)=>e.some(e=>e.id===t&&e.value),eu=()=>{let{t:e}=ye(void 0,{useSuspense:!0,i18n:ge}),[t,n]=Mc(),[,r]=Sc(),i=[{id:`analytics-cookie`,label:e(`cookieBanner.cookies.analytics`),value:!0}];return t?U(`div`,{className:`absolute inset-0 z-[10000] backdrop-blur-sm`,children:[H(`div`,{className:`absolute inset-0 bg-black opacity-15`}),H(`div`,{className:`absolute inset-x-0 bottom-0 flex justify-center bg-white px-10 pb-16 pt-10 shadow-lg`,children:H(ze,{className:`max-w-[1024px]`,cookies:i,onSubmit:e=>{n(!1),$l(e,`analytics-cookie`)&&r(e=>({...e,analytics:!0}))},onReject:()=>{n(!1),r(()=>({analytics:!1,functional:!1,marketing:!1}))},submitLabel:e(`cookieBanner.accept`),rejectLabel:e(`cookieBanner.reject`),children:H(`p`,{className:`font-semibold text-gray-500`,children:H(_e,{i18nKey:`cookieBanner.message`,components:{a:H(`a`,{onClick:()=>m({type:`cookiesPolicy`}),className:`cursor-pointer text-gray-900 hover:underline`},`cookieBanner.message-link`)}},`cookieBanner.message`)})})})]}):null};function tu({drive:e}){let t=k(),n=Or(()=>e?t.some(t=>t.collectionId===i(`main`,e.header.id)):!1,[t,e]),r=e?.state.global.icon;return r?H(`img`,{src:r,alt:e.header.name,height:32,width:32}):n?H(fe,{name:`Server`,size:32}):H(fe,{name:`Hdd`,size:32})}function nu({message:e}){return H(`div`,{className:`flex size-full items-center justify-center`,children:H(`h3`,{className:`text-lg font-semibold`,children:e})})}var ru=e=>{let{document:t,onClose:n,onExport:r,onOpenSwitchboardLink:i}=e,a=N(),o=le(),[c,l]=g(t.header.id),u=c?.header.id??void 0,f=c?.header.name??void 0,p=c?.header.documentType??void 0,h=c?.header.meta?.preferredEditor??void 0,{globalOperations:_,localOperations:v,isLoading:y,refetch:b}=w(u);V(()=>{o&&b()},[o,b]);let x=c?.header.revision.global??0,S=c?.header.revision.local??0,E=C(p),ee=T(h),O=D(p),k=ee??O,te=!c,ne=k&&p&&!k.documentTypes.includes(p)&&!k.documentTypes.includes(`*`);zc({undo:()=>l(d()),redo:()=>l(s()),canUndo:x>0||S>0,canRedo:!!c?.clipboard.length}),V(()=>()=>{window.documentEditorDebugTools?.clear()},[]);let[re,A]=Ar(void 0);V(()=>{re&&re.documentId!==u&&A(void 0)},[re,u]);let ae=(e,t)=>{A({error:e,documentId:u,info:t})};if(ne)return H(Uc,{message:`Loading editor`});if(te)return H(Uc,{message:`Loading document`});if(!E)return H(nu,{message:U(`div`,{className:`text-center leading-10`,children:[U(`p`,{children:[`Unable to open the document because the document model "`,p,`" is not supported.`]}),U(`p`,{children:[`Go to the`,` `,H(`button`,{type:`button`,className:`cursor-pointer underline`,onClick:()=>{m({type:`settings`})},children:`package manager`}),` `,`to install this document model`]})]})});if(!k)return H(nu,{message:U(`div`,{className:`text-center leading-10`,children:[H(`p`,{children:`Unable to open the document because no editor has been found`}),U(`p`,{children:[`Go to the`,` `,H(`button`,{type:`button`,className:`cursor-pointer underline`,onClick:()=>{m({type:`settings`})},children:`package manager`}),` `,`an editor for the "$`,p,`" document type`]})]})});let j=k.Component;return H(`div`,{className:`relative h-full`,id:`document-editor-context`,"data-editor":k.config.id,"data-document-type":p,children:o?y?H(Uc,{message:`Loading operations`}):H(je,{documentTitle:f??``,documentId:u??``,globalOperations:_,localOperations:v,onClose:()=>oe(!1),documentState:c.state,onCopyState:()=>{me(`Copied document state to clipboard`,{type:`success`})},onCopyDocId:()=>{me(`Copied document ID to clipboard`,{type:`success`})}},u):H(Sr,{fallback:H(Uc,{message:`Loading editor`}),name:`EditorLoader`,children:H(Zc,{fallbackRender:Yc,resetKeys:[u],onError:ae,loggerContext:[`Connect`,`DocumentEditor`],children:!re?.error&&H(j,{context:{readMode:!!a,selectedTimelineRevision:ie(a?.startDate,a?.endDate,_)},documentId:c.header.id},u)})})})};function iu(){return H(`div`,{className:`h-screen`,children:H(`div`,{className:`flex h-screen items-stretch overflow-auto`,role:`presentation`,tabIndex:0,children:U(Sr,{name:`Root`,children:[H(vu,{}),H(`div`,{className:`relative flex-1 overflow-auto`,children:H(ms,{})})]})})})}function au(){let[e]=ae(),t=ee(),n=A();return V(()=>{n||f(de)},[n]),V(()=>{e||x(ue)},[e]),H(ou,{children:H(!n&&!e&&!t?cu:Qc,{})})}function ou({children:e}){return H(`div`,{className:`flex h-full flex-col overflow-auto`,id:`content-view`,children:e})}function su({drive:e}){let t=y(e.header.meta?.preferredEditor)?.config.name||`Drive Explorer App`;return H(Be,{title:e.state.global.name||e.header.name,description:t,icon:H(tu,{drive:e}),onClick:()=>h(e)},e.header.id)}function cu(){let e=E(),t=I;return U(Ve,{children:[e?.map(e=>H(su,{drive:e},e.header.id)),t.drives.addDriveEnabled&&H(Pe,{})]})}var lu=`https://apps.powerhouse.io/sky-atlas/staging/switchboard`,uu=2e3;function du(){let{search:e}=Ho();return Or(()=>{let t=new URLSearchParams(e).get(`reactorUrl`)??lu;return t.endsWith(`/`)?t:`${t}/`},[e])}async function fu(e,t){let n=ji`
|
|
47
|
+
}`}}):null,e.children?null:H(au,{}),H(iu,{})]})},su=!1,cu=new Set;function lu(){for(let e of cu)e()}function uu(){su=!0,lu()}function du(e){return cu.add(e),()=>{cu.delete(e)}}function fu(){return su}var pu=()=>{let e=ui(du,fu,()=>!1),t=ui(Se,Te,()=>void 0),[n,r]=li(!1),[i,a]=li(null);return t==null||t===17||e?null:H(`div`,{className:`absolute inset-x-0 top-0 z-30 flex justify-center p-3`,children:U(`div`,{className:`flex max-w-3xl items-center gap-3 rounded-lg border border-yellow-500 bg-yellow-400 px-4 py-3 text-sm text-gray-900 shadow-lg`,children:[U(`div`,{className:`flex-1`,children:[U(`div`,{className:`font-semibold`,children:[`Your local database uses Postgres `,t,`.`]}),U(`div`,{className:`text-gray-800`,children:[`Migrate to Postgres `,17,` to pick up the latest features. Your data will be backed up first.`]}),i&&U(`div`,{className:`mt-2 font-medium text-red-900`,children:[`Migration failed: `,i]})]}),H(`button`,{type:`button`,disabled:n,onClick:()=>{a(null),r(!0),tu().then(()=>{window.location.reload()}).catch(e=>{a(e instanceof Error?e.message:String(e)),r(!1)})},className:`rounded bg-gray-900 px-3 py-1 text-sm font-medium text-white hover:bg-gray-800 disabled:opacity-50`,children:n?`Migrating…`:`Migrate now`}),H(`button`,{type:`button`,disabled:n,onClick:uu,className:`rounded border border-gray-900 bg-transparent px-3 py-1 text-sm font-medium text-gray-900 hover:bg-gray-900/10 disabled:opacity-50`,children:`Dismiss`})]})})},mu=B(()=>F(()=>import(`./AddDriveModal-CBbXwG8S-CMtP_pYy.js`).then(e=>({default:e.AddDriveModal})),__vite__mapDeps([9,10,1,3,11,12,13,14,15,16,17,18,19,20]))),hu=B(()=>F(()=>import(`./ClearStorageModal-DwiCY6Lt-BX6HLKHK.js`).then(e=>({default:e.ClearStorageModal})),__vite__mapDeps([21,10,1,3,11,12,13,14,15,16,17,18,22,23,24,19,25,26,27,28,29,30,31,32,33,34,35,36,37]))),gu=B(()=>F(()=>import(`./CookiesPolicyModal-CTXUu4-8-CDv9A_Ye.js`).then(e=>({default:e.CookiesPolicyModal})),__vite__mapDeps([38,10,1,3,11,12,13,14,15,16,17,18,39,20,37]))),_u=B(()=>F(()=>import(`./CreateDocumentModal-CAld-5pv-CgcRndoo.js`).then(e=>({default:e.CreateDocumentModal})),__vite__mapDeps([40,10,1,3,11,12,13,14,15,16,17,18]))),vu=B(()=>F(()=>import(`./DebugSettingsModal-DeZ-x8H3-kFKY1yIP.js`).then(e=>({default:e.DebugSettingsModal})),__vite__mapDeps([41,10,1,3,11,12,13,14,15,16,17,18,23,42]))),yu=B(()=>F(()=>import(`./DeleteDriveModal-B7T2CVIX-Ij3dGsPx.js`).then(e=>({default:e.DeleteDriveModal})),__vite__mapDeps([43,10,1,3,11,12,13,14,15,16,17,18,19,37]))),bu=B(()=>F(()=>import(`./DeleteItemModal-DJv71YQG-CVtPVgc9.js`).then(e=>({default:e.DeleteItemModal})),__vite__mapDeps([44,10,1,3,11,12,13,14,15,16,17,18,19,37]))),xu=B(()=>F(()=>import(`./DisclaimerModal-Co13N7HH-DNe510Y-.js`).then(e=>({default:e.DisclaimerModal})),__vite__mapDeps([45,10,1,3,11,12,13,14,15,16,17,18,37]))),Su=B(()=>F(()=>import(`./DriveSettingsModal-DmsUU0g3-CAC1UDo_.js`).then(e=>({default:e.DriveSettingsModal})),__vite__mapDeps([46,10,1,3,11,12,13,14,15,16,17,18]))),Cu=B(()=>F(()=>import(`./ExportDocumentWithErrorsModal-DOV_UVlM-CuR2gzWI.js`).then(e=>({default:e.ExportDocumentWithErrorsModal})),__vite__mapDeps([47,10,1,3,11,12,13,14,15,16,17,18,37]))),wu=B(()=>F(()=>import(`./SettingsModal-BzvCwJLZ-YPWkTKes.js`).then(e=>({default:e.SettingsModal})),__vite__mapDeps([48,10,1,3,11,12,13,14,15,16,17,18,23,49,19,50,20]))),Tu=B(()=>F(()=>import(`./UpgradeDriveModal-BH4ecdCU-Ds9YPtnh.js`).then(e=>({default:e.UpgradeDriveModal})),__vite__mapDeps([51,10,1,3,11,12,13,14,15,16,17,18,37]))),Eu={addDrive:mu,clearStorage:hu,cookiesPolicy:gu,createDocument:_u,debugSettings:vu,deleteDrive:yu,deleteItem:bu,disclaimer:xu,driveSettings:Su,exportDocumentWithErrors:Cu,inspector:B(()=>F(()=>import(`./InspectorModal-NoO3f3U7-CJAiPdEE.js`).then(e=>({default:e.InspectorModal})),__vite__mapDeps([52,10,1,3,11,12,13,14,15,16,17,18,22,23,24,19,25,26,27,28,29,30,31,32,33,34,35,36,53]))),settings:wu,upgradeDrive:Tu,missingPackage:B(()=>F(()=>import(`./MissingPackageModal-Df154H9n-CBAwY4mw.js`).then(e=>({default:e.ConnectMissingPackageModal})),__vite__mapDeps([54,10,1,3,11,12,13,14,15,16,17,18,50])))},Du=B(async()=>({default:()=>{let e=O();if(!e?.type)return null;let t=Eu[e.type];return t?H(Al,{variant:`silent`,loggerContext:[`Connect`,`Modals`],children:H(ti,{fallback:null,children:H(t,{})})}):null}})),Ou=e=>{let t=B(()=>F(()=>import(`./load-C0mYtbHx-C7vYfEJ_.js`).then(t=>t.loadComponent(e.localPackage)),__vite__mapDeps([55,13,1,3,11,14,22,23,17,24,19,12,25,26,27,28,29,30,31,32,33,34,35,36,49,53,0,37])));return H(ei,{children:U(Al,{fallbackRender:e=>H(ou,{children:H(Dl,{...e})}),resetKeys:[e.localPackage],loggerContext:[`Connect`],children:[H(ti,{fallback:H(ou,{}),name:`AppLoader`,children:H(t,{...e,children:H(ju,{})})}),H(ti,{name:`CookieBanner`,children:H(Nu,{})}),H(ti,{name:`ModalsContainer`,children:H(Du,{})}),H(pu,{})]})})},ku=({children:e})=>(_l(),e);function Au(){let e=rl(),t=M();return!t||e.length===0?null:H(Ae,{pendingInstallations:e.flatMap(e=>e.packageNames.map(t=>({documentType:e.documentType,packageName:t}))),onInstall:e=>t.approveInstallation(e),onDismiss:e=>t.dismissInstallation(e)})}var ju=()=>(V(()=>{let e=e=>{let t=e.payload,n=(t instanceof Error?t.message:String(t??``)).match(/https?:\/\/[^\s"']+/)?.[0];if(n&&!n.startsWith(window.location.origin)){console.debug(`[Connect] Skipping reload — vite:preloadError for off-origin URL: ${n}`);return}console.log(`Outdated chunks detected, reloading page...`),window.location.reload()};return window.addEventListener(`vite:preloadError`,e),()=>{window.removeEventListener(`vite:preloadError`,e)}},[]),V(()=>{De.registerServiceWorker(!1)},[]),U(ku,{children:[H(he,{position:`bottom-right`}),H(Xu,{}),H(Au,{}),H(bl,{})]})),Mu=(e,t)=>e.some(e=>e.id===t&&e.value),Nu=()=>{let{t:e}=ye(void 0,{useSuspense:!0,i18n:ge}),[t,n]=dl(),[,r]=tl(),i=[{id:`analytics-cookie`,label:e(`cookieBanner.cookies.analytics`),value:!0}];return t?U(`div`,{className:`absolute inset-0 z-[10000] backdrop-blur-sm`,children:[H(`div`,{className:`absolute inset-0 bg-black opacity-15`}),H(`div`,{className:`absolute inset-x-0 bottom-0 flex justify-center bg-white px-10 pb-16 pt-10 shadow-lg`,children:H(ze,{className:`max-w-[1024px]`,cookies:i,onSubmit:e=>{n(!1),Mu(e,`analytics-cookie`)&&r(e=>({...e,analytics:!0}))},onReject:()=>{n(!1),r(()=>({analytics:!1,functional:!1,marketing:!1}))},submitLabel:e(`cookieBanner.accept`),rejectLabel:e(`cookieBanner.reject`),children:H(`p`,{className:`font-semibold text-gray-500`,children:H(_e,{i18nKey:`cookieBanner.message`,components:{a:H(`a`,{onClick:()=>m({type:`cookiesPolicy`}),className:`cursor-pointer text-gray-900 hover:underline`},`cookieBanner.message-link`)}},`cookieBanner.message`)})})})]}):null};function Pu({drive:e}){let t=k(),n=si(()=>e?t.some(t=>t.collectionId===i(`main`,e.header.id)):!1,[t,e]),r=e?.state.global.icon;return r?H(`img`,{src:r,alt:e.header.name,height:32,width:32}):n?H(fe,{name:`Server`,size:32}):H(fe,{name:`Hdd`,size:32})}function Fu({message:e}){return H(`div`,{className:`flex size-full items-center justify-center`,children:H(`h3`,{className:`text-lg font-semibold`,children:e})})}var Iu=e=>{let{document:t,onClose:n,onExport:r,onOpenSwitchboardLink:i}=e,a=N(),o=le(),[c,l]=g(t.header.id),u=c?.header.id??void 0,f=c?.header.name??void 0,p=c?.header.documentType??void 0,h=c?.header.meta?.preferredEditor??void 0,{globalOperations:_,localOperations:v,isLoading:y,refetch:b}=w(u);V(()=>{o&&b()},[o,b]);let x=c?.header.revision.global??0,S=c?.header.revision.local??0,E=C(p),ee=T(h),O=D(p),k=ee??O,te=!c,ne=k&&p&&!k.documentTypes.includes(p)&&!k.documentTypes.includes(`*`);vl({undo:()=>l(d()),redo:()=>l(s()),canUndo:x>0||S>0,canRedo:!!c?.clipboard.length}),V(()=>()=>{window.documentEditorDebugTools?.clear()},[]);let[re,A]=li(void 0);V(()=>{re&&re.documentId!==u&&A(void 0)},[re,u]);let ae=(e,t)=>{A({error:e,documentId:u,info:t})};if(ne)return H(Sl,{message:`Loading editor`});if(te)return H(Sl,{message:`Loading document`});if(!E)return H(Fu,{message:U(`div`,{className:`text-center leading-10`,children:[U(`p`,{children:[`Unable to open the document because the document model "`,p,`" is not supported.`]}),U(`p`,{children:[`Go to the`,` `,H(`button`,{type:`button`,className:`cursor-pointer underline`,onClick:()=>{m({type:`settings`})},children:`package manager`}),` `,`to install this document model`]})]})});if(!k)return H(Fu,{message:U(`div`,{className:`text-center leading-10`,children:[H(`p`,{children:`Unable to open the document because no editor has been found`}),U(`p`,{children:[`Go to the`,` `,H(`button`,{type:`button`,className:`cursor-pointer underline`,onClick:()=>{m({type:`settings`})},children:`package manager`}),` `,`an editor for the "$`,p,`" document type`]})]})});let j=k.Component;return H(`div`,{className:`relative h-full`,id:`document-editor-context`,"data-editor":k.config.id,"data-document-type":p,children:o?y?H(Sl,{message:`Loading operations`}):H(je,{documentTitle:f??``,documentId:u??``,globalOperations:_,localOperations:v,onClose:()=>oe(!1),documentState:c.state,onCopyState:()=>{me(`Copied document state to clipboard`,{type:`success`})},onCopyDocId:()=>{me(`Copied document ID to clipboard`,{type:`success`})}},u):H(ti,{fallback:H(Sl,{message:`Loading editor`}),name:`EditorLoader`,children:H(Al,{fallbackRender:Ol,resetKeys:[u],onError:ae,loggerContext:[`Connect`,`DocumentEditor`],children:!re?.error&&H(j,{context:{readMode:!!a,selectedTimelineRevision:ie(a?.startDate,a?.endDate,_)},documentId:c.header.id},u)})})})};function Lu(){return H(`div`,{className:`h-screen`,children:H(`div`,{className:`flex h-screen items-stretch overflow-auto`,role:`presentation`,tabIndex:0,children:U(ti,{name:`Root`,children:[H(Zu,{}),H(`div`,{className:`relative flex-1 overflow-auto`,children:H(qs,{})})]})})})}function Ru(){let[e]=ae(),t=ee(),n=A();return V(()=>{n||f(de)},[n]),V(()=>{e||x(ue)},[e]),H(zu,{children:H(!n&&!e&&!t?Vu:jl,{})})}function zu({children:e}){return H(`div`,{className:`flex h-full flex-col overflow-auto`,id:`content-view`,children:e})}function Bu({drive:e}){let t=y(e.header.meta?.preferredEditor)?.config.name||`Drive Explorer App`;return H(Be,{title:e.state.global.name||e.header.name,description:t,icon:H(Pu,{drive:e}),onClick:()=>h(e)},e.header.id)}function Vu(){let e=E(),t=I;return U(Ve,{children:[e?.map(e=>H(Bu,{drive:e},e.header.id)),t.drives.addDriveEnabled&&H(Pe,{})]})}var Hu=`https://apps.powerhouse.io/sky-atlas/staging/switchboard`,Uu=2e3;function Wu(){let{search:e}=xs();return si(()=>{let t=new URLSearchParams(e).get(`reactorUrl`)??Hu;return t.endsWith(`/`)?t:`${t}/`},[e])}async function Gu(e,t){let n=ua`
|
|
48
48
|
mutation ForkAtlas($docId: PHID) {
|
|
49
49
|
ForkAtlas(docId: $docId)
|
|
50
50
|
}
|
|
51
|
-
`;return await Oi(`${t}graphql`,n,{docId:e})}function pu(){let e=kr(`initial`),t=te(),{documentId:n}=Yo(),r=du(),i=Go(),[a,o]=Ar(void 0),[s,c]=Ar(void 0),[l,u]=Ar(!0),d=e.current===`error`;V(()=>{s&&(console.error(`Error forking Atlas:`,s),me(`Error forking Atlas`,{type:`error`}))},[s]);async function f(t){let n=(await fu(t,r)).ForkAtlas;e.current=`forked`,o(n)}let p=Tr(()=>{a&&!l&&i(`/d/${a}`,{replace:!0})},[a,i,l]),m=Tr(async t=>{console.log(`Adding remote drive:`,t);let n=`${r}d/${t}`;try{let t=await ce(n);e.current=`done`,console.log(`Added remote drive:`,t),setTimeout(()=>{u(!1)},uu)}catch(t){e.current=`error`,u(!1),c(t)}},[ce,i,r]);return V(()=>{!n||e.current!==`initial`||(e.current=`forking`,f(n).catch(t=>{e.current=`error`,c(t)}))},[n,e]),V(()=>{!a||!t||e.current!==`forked`||(e.current=`addingDrive`,new Promise(e=>{setTimeout(e,500)}).then(()=>m(a)).catch(t=>{e.current=`error`,c(t)}))},[a,t,e]),H(`div`,{className:`flex size-full justify-center gap-x-4 bg-gray-50`,children:U(`div`,{className:`w-full max-w-[850px] rounded-2xl bg-white p-6 drop-shadow-sm`,children:[H(`h1`,{className:`text-lg font-medium text-gray-900`,children:`Welcome to the Atlas Explorer`}),H(`div`,{className:`mt-4 rounded-xl border border-gray-200 bg-gray-50 p-6`,children:U(`div`,{className:`flex min-h-80 flex-col items-center justify-center rounded-2xl bg-slate-50`,children:[H(`div`,{children:U(`svg`,{width:`28`,height:`32`,viewBox:`0 0 28 32`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:[H(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M0.05092 23.7286L0.000163347 23.9993L0 23.9995L0.207853 24.067L27.6823 24.067L27.9995 23.9995L27.9161 23.6913L14.2182 0.209032L13.9998 0L13.749 0.246353L0.05092 23.7286ZM20.9994 11.9999L7.0003 11.9999L13.9998 23.999L20.9994 11.9999Z`,fill:`url(#paint0_radial_319_20865)`}),H(`path`,{d:`M14 0L0 23.9998V7.99993L14 0Z`,fill:`url(#paint1_linear_319_20865)`}),H(`path`,{d:`M28 24L7.82013e-05 24L14 31.9999L28 24Z`,fill:`url(#paint2_linear_319_20865)`}),H(`path`,{d:`M14 0L28 23.9998V7.99993L14 0Z`,fill:`url(#paint3_linear_319_20865)`}),U(`defs`,{children:[U(`radialGradient`,{id:`paint0_radial_319_20865`,cx:`0`,cy:`0`,r:`1`,gradientUnits:`userSpaceOnUse`,gradientTransform:`translate(13.9994 16.0344) rotate(-89.9988) scale(16.0344 16.201)`,children:[H(`stop`,{offset:`0.181008`,stopColor:`#FFCD6B`}),H(`stop`,{offset:`1`,stopColor:`#EB5EDF`})]}),U(`linearGradient`,{id:`paint1_linear_319_20865`,x1:`-0.031454`,y1:`24.041`,x2:`13.801`,y2:`-0.142908`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#4331E9`}),H(`stop`,{offset:`1`,stopColor:`#A273FF`})]}),U(`linearGradient`,{id:`paint2_linear_319_20865`,x1:`-0.0310093`,y1:`24`,x2:`28.0444`,y2:`24`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#A273FF`}),H(`stop`,{offset:`1`,stopColor:`#4331E9`})]}),U(`linearGradient`,{id:`paint3_linear_319_20865`,x1:`28.0315`,y1:`24.041`,x2:`14.199`,y2:`-0.142908`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#A273FF`}),H(`stop`,{offset:`1`,stopColor:`#4331E9`})]})]})]})}),d?H(`div`,{className:`mt-3 text-sm text-gray-800`,children:`Error forking Atlas scope. Please try again.`}):H(`div`,{className:`mt-3 text-sm text-gray-500`,children:`Forking Atlas scope...`}),H(pe,{onClick:d?window.location.reload.bind(window.location):p,size:`small`,color:`light`,className:`mt-4 h-9 border border-gray-200 bg-white px-3 text-gray-600`,children:d?`Retry`:l?U(Mr,{children:[U(`svg`,{className:`animate-spin`,width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:[H(`path`,{d:`M15.6867 8.03333C15.4933 7.83999 15.1733 7.83999 14.98 8.03333L14.6733 8.34001V8C14.6733 4.32 11.68 1.32666 7.99999 1.32666C5.96666 1.32666 4.06666 2.23999 2.79333 3.82666C2.61999 4.03999 2.65332 4.35999 2.87332 4.52665C3.08666 4.69999 3.40666 4.66666 3.57332 4.44666C4.65999 3.09332 6.27332 2.31999 7.99999 2.31999C11.1267 2.31999 13.6733 4.86666 13.6733 7.99333V8.32666L13.3667 8.02002C13.1733 7.82669 12.8533 7.82669 12.66 8.02002C12.4667 8.21335 12.4667 8.53335 12.66 8.72668L13.82 9.88668C13.8667 9.93334 13.92 9.96666 13.98 9.99333C14.04 10.02 14.1067 10.0333 14.1733 10.0333C14.24 10.0333 14.3 10.02 14.3667 9.99333C14.4267 9.96666 14.48 9.93334 14.5267 9.88668L15.6867 8.72668C15.88 8.54668 15.88 8.22666 15.6867 8.03333Z`,fill:`#6C7275`}),H(`path`,{d:`M13.1267 11.4666C12.9133 11.2933 12.5933 11.3266 12.4267 11.5466C11.34 12.9 9.72665 13.6733 7.99998 13.6733C4.87332 13.6733 2.32665 11.1266 2.32665 7.99996V7.66663L2.63332 7.97331C2.73332 8.07331 2.85999 8.11996 2.98665 8.11996C3.11332 8.11996 3.23999 8.07331 3.33999 7.97331C3.53332 7.77998 3.53332 7.45998 3.33999 7.26664L2.17998 6.10661C2.13332 6.05994 2.07998 6.02663 2.01998 5.99996C1.89998 5.94663 1.75998 5.94663 1.63998 5.99996C1.57998 6.02663 1.52665 6.05994 1.47999 6.10661L0.319988 7.26664C0.126654 7.45998 0.126654 7.77998 0.319988 7.97331C0.513321 8.16664 0.833319 8.16664 1.02665 7.97331L1.33332 7.66663V7.99996C1.33332 11.68 4.32665 14.6733 8.00665 14.6733C10.04 14.6733 11.94 13.76 13.2133 12.1733C13.38 11.96 13.3467 11.64 13.1267 11.4666Z`,fill:`#6C7275`})]}),`Loading`]}):`Continue`})]})})]})})}function mu(e){let t=I.routerBasename;return Ss(e,{basename:t,future:{v7_fetcherPersist:!0,v7_relativeSplatPath:!0}})}function hu(){return[{element:H(Sr,{name:`RouteRoot`,children:H(iu,{})}),children:[{index:!0,path:`d?/:driveId?/*?`,element:H(Sr,{name:`Drive`,children:H(au,{})})},{path:`import/:documentId`,element:H(Sr,{name:`AtlasImport`,children:H(pu,{})})}]}]}var gu=mu(hu()),_u=()=>H(Ms,{router:gu});function vu(){let e=v(),t=E(),[n]=ae(),r=localStorage.getItem(`CONNECT_DEBUG`)===`true`,i=e?.ens?.name||e?.profile?.username||void 0,a=e?.ens?.avatarUrl||e?.profile?.userImage||void 0,o=ke(a?void 0:e?.address),s=()=>{m({type:`settings`})},c=()=>{m({type:`addDrive`})},l=e?.address?`https://etherscan.io/address/${e.address}`:``;return H(Oe,{children:H(Fe,{id:`sidebar`,onClick:()=>h(void 0),onClickSettings:s,address:e?.address,onLogin:S,onDisconnect:P,ensName:i||o.data?.ens,avatarUrl:a||o.data?.avatar_small||o.data?.avatar_url||void 0,etherscanUrl:l,showDebug:r,onDebugClick:()=>m({type:`debugSettings`}),children:U(Zc,{variant:`text`,fallbackMessage:`There was an error loading drives`,loggerContext:[`Connect`,`Sidebar`],children:[t?.map((e,t)=>H(Ie,{title:e.header.name,onClick:()=>h(e),active:n?.header.id===e.header.id,icon:H(tu,{drive:e})},t)),I.drives.addDriveEnabled&&H(Me,{onClick:c})]})})})}function yu(e){window.ph?.vetraPackageManager?.updateLocalPackage(e)}function bu(e){return window.ph||(window.ph={}),Pr(document.getElementById(`root`)).render(H(Yl,{localPackage:e})),{updateLocalPackage:yu}}var xu={name:`ph-clint-app`,description:``,category:``,publisher:{name:``,url:``},documentModels:[{id:`powerhouse/ph-clint-project`,name:`PhClintProject`}],apps:[],editors:[{id:`ph-clint-project-editor`,name:`PhClintProjectEditor`,documentTypes:[`powerhouse/ph-clint-project`]}],processors:[],subgraphs:[],config:[]},Su=[Nn],Cu=[$n],wu=[{Component:B(()=>F(()=>import(`./editor-DgkuaKuV.js`),__vite__mapDeps([56,10,1,3,11,12,13,14,15,16,17,18,57]))),documentTypes:[`powerhouse/ph-clint-project`],config:{id:`ph-clint-project-editor`,name:`PhClintProjectEditor`}}],Tu=async e=>{let{processorFactoryBuilders:t}=e.processorApp===`connect`?await F(()=>import(`./connect-q2RMY-je.js`),[]):await F(()=>import(`./switchboard-BCPp_tNt.js`),[]),n=await Promise.all(t.map(async t=>await t(e)));return async t=>{let r=[];for(let i of n){let n=await i(t,e.processorApp);r.push(...n)}return r}},Eu=e({AddExternalSkillInputSchema:()=>ur,AddModelInputSchema:()=>It,AddPackageDocumentTypeInputSchema:()=>rt,AddPowerhousePackageInputSchema:()=>et,AddProfileInputSchema:()=>wt,AddSupportedResourceInputSchema:()=>kn,BumpVersionInputSchema:()=>Ke,ClearAgentImageInputSchema:()=>En,DisableMastraInputSchema:()=>yt,DisableRoutineInputSchema:()=>xt,EnableMastraInputSchema:()=>Et,EnableRoutineInputSchema:()=>at,ExternalSkillSchema:()=>dt,ImportModelInputSchema:()=>_t,ImportPackageInputSchema:()=>At,ImportProfileInputSchema:()=>vr,ImportSkillInputSchema:()=>Je,ImportSpecInputSchema:()=>Bt,PhClintAgentModelSchema:()=>lt,PhClintAgentProfileSchema:()=>Rt,PhClintDeploymentSchema:()=>Ht,PhClintFeaturesSchema:()=>st,PhClintMastraCommonSchema:()=>ht,PhClintMastraFeatureSchema:()=>Kn,PhClintProject:()=>Nn,PhClintProjectController:()=>Hn,PhClintProjectDocumentHeaderSchema:()=>ar,PhClintProjectDocumentSchema:()=>mr,PhClintProjectPHStateSchema:()=>tn,PhClintProjectStateSchema:()=>pt,PhClintRoutineFeatureSchema:()=>Kt,PowerhouseLevelSchema:()=>Wt,PowerhousePackageSchema:()=>Jt,PublishDevInputSchema:()=>Ot,PublishProductionInputSchema:()=>We,PublishRecordSchema:()=>dn,PublishStagingInputSchema:()=>er,PublishStatusSchema:()=>Ln,PublishTagSchema:()=>Jn,RemoveExternalSkillInputSchema:()=>Cn,RemoveModelInputSchema:()=>$t,RemovePackageDocumentTypeInputSchema:()=>Bn,RemovePowerhousePackageInputSchema:()=>Zn,RemoveProfileInputSchema:()=>on,RemoveSupportedResourceInputSchema:()=>jn,ReorderProfilesInputSchema:()=>rr,SetAgentDescriptionInputSchema:()=>ln,SetAgentIdInputSchema:()=>mn,SetAgentImageInputSchema:()=>Un,SetAgentNameInputSchema:()=>Pn,SetDefaultModelInputSchema:()=>bn,SetDescriptionInputSchema:()=>_n,SetEnableChatInputSchema:()=>Xt,SetExternalSkillGithubUrlInputSchema:()=>or,SetExternalSkillNameInputSchema:()=>hr,SetObservabilityEnabledInputSchema:()=>nn,SetPackageIdentifierInputSchema:()=>fr,SetPackageVersionInputSchema:()=>Mt,SetPowerhouseLevelInputSchema:()=>Xe,SetProxyEnabledInputSchema:()=>lr,SetPublishStatusInputSchema:()=>Ft,SetVersionInputSchema:()=>nt,UpdateProfileInputSchema:()=>$e,actions:()=>St,addExternalSkill:()=>Fn,addModel:()=>Dt,addPackageDocumentType:()=>it,addPowerhousePackage:()=>ut,addProfile:()=>Ue,addSupportedResource:()=>gr,assertIsPhClintProjectDocument:()=>dr,assertIsPhClintProjectState:()=>jt,bumpVersion:()=>Dn,clearAgentImage:()=>fn,createPhClintProjectDocument:()=>an,createState:()=>An,defaultGlobalState:()=>nr,defaultLocalState:()=>cn,defaultPHState:()=>pn,definedNonNullAnySchema:()=>Ct,disableMastra:()=>Rn,disableRoutine:()=>ft,documentModel:()=>Qe,documentModels:()=>Su,editors:()=>wu,enableMastra:()=>Yn,enableRoutine:()=>Gt,importSpec:()=>ct,initialGlobalState:()=>gn,initialLocalState:()=>Yt,isDefinedNonNullAny:()=>On,isPhClintProjectDocument:()=>Ye,isPhClintProjectState:()=>cr,latestVersion:()=>In,manifest:()=>Du,phClintProjectDeploymentActions:()=>rn,phClintProjectDocumentType:()=>Pt,phClintProjectExternalSkillsActions:()=>xn,phClintProjectFeaturesMastraActions:()=>tr,phClintProjectFeaturesPowerhouseActions:()=>Ut,phClintProjectFeaturesRoutineActions:()=>Gn,phClintProjectIdentityActions:()=>Lt,phClintProjectLifecycleActions:()=>zt,phClintProjectPowerhousePackagesActions:()=>gt,phClintProjectPublishingActions:()=>Ge,phClintProjectUpgradeManifest:()=>$n,processorFactory:()=>Tu,publishDev:()=>Tn,publishProduction:()=>vt,publishStaging:()=>bt,reducer:()=>tt,removeExternalSkill:()=>vn,removeModel:()=>wn,removePackageDocumentType:()=>kt,removePowerhousePackage:()=>_r,removeProfile:()=>en,removeSupportedResource:()=>pr,reorderProfiles:()=>Vn,setAgentDescription:()=>Qn,setAgentId:()=>sn,setAgentImage:()=>Mn,setAgentName:()=>ir,setDefaultModel:()=>un,setDescription:()=>Vt,setEnableChat:()=>hn,setExternalSkillGithubUrl:()=>Zt,setExternalSkillName:()=>sr,setObservabilityEnabled:()=>Nt,setPackageIdentifier:()=>ot,setPackageVersion:()=>qe,setPowerhouseLevel:()=>qt,setProxyEnabled:()=>Ze,setPublishStatus:()=>Tt,setVersion:()=>mt,supportedVersions:()=>qn,updateProfile:()=>Wn,upgradeManifests:()=>Cu,usePhClintProjectDocumentById:()=>Sn,usePhClintProjectDocumentsInSelectedDrive:()=>Qt,usePhClintProjectDocumentsInSelectedFolder:()=>zn,useSelectedPhClintProjectDocument:()=>Xn,utils:()=>yn}),Du=xu,{updateLocalPackage:Ou}=bu(Eu);
|
|
52
|
-
//# sourceMappingURL=index-
|
|
51
|
+
`;return await sa(`${t}graphql`,n,{docId:e})}function Ku(){let e=ci(`initial`),t=te(),{documentId:n}=Os(),r=Wu(),i=ws(),[a,o]=li(void 0),[s,c]=li(void 0),[l,u]=li(!0),d=e.current===`error`;V(()=>{s&&(console.error(`Error forking Atlas:`,s),me(`Error forking Atlas`,{type:`error`}))},[s]);async function f(t){let n=(await Gu(t,r)).ForkAtlas;e.current=`forked`,o(n)}let p=ii(()=>{a&&!l&&i(`/d/${a}`,{replace:!0})},[a,i,l]),m=ii(async t=>{console.log(`Adding remote drive:`,t);let n=`${r}d/${t}`;try{let t=await ce(n);e.current=`done`,console.log(`Added remote drive:`,t),setTimeout(()=>{u(!1)},Uu)}catch(t){e.current=`error`,u(!1),c(t)}},[ce,i,r]);return V(()=>{!n||e.current!==`initial`||(e.current=`forking`,f(n).catch(t=>{e.current=`error`,c(t)}))},[n,e]),V(()=>{!a||!t||e.current!==`forked`||(e.current=`addingDrive`,new Promise(e=>{setTimeout(e,500)}).then(()=>m(a)).catch(t=>{e.current=`error`,c(t)}))},[a,t,e]),H(`div`,{className:`flex size-full justify-center gap-x-4 bg-gray-50`,children:U(`div`,{className:`w-full max-w-[850px] rounded-2xl bg-white p-6 drop-shadow-sm`,children:[H(`h1`,{className:`text-lg font-medium text-gray-900`,children:`Welcome to the Atlas Explorer`}),H(`div`,{className:`mt-4 rounded-xl border border-gray-200 bg-gray-50 p-6`,children:U(`div`,{className:`flex min-h-80 flex-col items-center justify-center rounded-2xl bg-slate-50`,children:[H(`div`,{children:U(`svg`,{width:`28`,height:`32`,viewBox:`0 0 28 32`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:[H(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M0.05092 23.7286L0.000163347 23.9993L0 23.9995L0.207853 24.067L27.6823 24.067L27.9995 23.9995L27.9161 23.6913L14.2182 0.209032L13.9998 0L13.749 0.246353L0.05092 23.7286ZM20.9994 11.9999L7.0003 11.9999L13.9998 23.999L20.9994 11.9999Z`,fill:`url(#paint0_radial_319_20865)`}),H(`path`,{d:`M14 0L0 23.9998V7.99993L14 0Z`,fill:`url(#paint1_linear_319_20865)`}),H(`path`,{d:`M28 24L7.82013e-05 24L14 31.9999L28 24Z`,fill:`url(#paint2_linear_319_20865)`}),H(`path`,{d:`M14 0L28 23.9998V7.99993L14 0Z`,fill:`url(#paint3_linear_319_20865)`}),U(`defs`,{children:[U(`radialGradient`,{id:`paint0_radial_319_20865`,cx:`0`,cy:`0`,r:`1`,gradientUnits:`userSpaceOnUse`,gradientTransform:`translate(13.9994 16.0344) rotate(-89.9988) scale(16.0344 16.201)`,children:[H(`stop`,{offset:`0.181008`,stopColor:`#FFCD6B`}),H(`stop`,{offset:`1`,stopColor:`#EB5EDF`})]}),U(`linearGradient`,{id:`paint1_linear_319_20865`,x1:`-0.031454`,y1:`24.041`,x2:`13.801`,y2:`-0.142908`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#4331E9`}),H(`stop`,{offset:`1`,stopColor:`#A273FF`})]}),U(`linearGradient`,{id:`paint2_linear_319_20865`,x1:`-0.0310093`,y1:`24`,x2:`28.0444`,y2:`24`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#A273FF`}),H(`stop`,{offset:`1`,stopColor:`#4331E9`})]}),U(`linearGradient`,{id:`paint3_linear_319_20865`,x1:`28.0315`,y1:`24.041`,x2:`14.199`,y2:`-0.142908`,gradientUnits:`userSpaceOnUse`,children:[H(`stop`,{stopColor:`#A273FF`}),H(`stop`,{offset:`1`,stopColor:`#4331E9`})]})]})]})}),d?H(`div`,{className:`mt-3 text-sm text-gray-800`,children:`Error forking Atlas scope. Please try again.`}):H(`div`,{className:`mt-3 text-sm text-gray-500`,children:`Forking Atlas scope...`}),H(pe,{onClick:d?window.location.reload.bind(window.location):p,size:`small`,color:`light`,className:`mt-4 h-9 border border-gray-200 bg-white px-3 text-gray-600`,children:d?`Retry`:l?U(di,{children:[U(`svg`,{className:`animate-spin`,width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:[H(`path`,{d:`M15.6867 8.03333C15.4933 7.83999 15.1733 7.83999 14.98 8.03333L14.6733 8.34001V8C14.6733 4.32 11.68 1.32666 7.99999 1.32666C5.96666 1.32666 4.06666 2.23999 2.79333 3.82666C2.61999 4.03999 2.65332 4.35999 2.87332 4.52665C3.08666 4.69999 3.40666 4.66666 3.57332 4.44666C4.65999 3.09332 6.27332 2.31999 7.99999 2.31999C11.1267 2.31999 13.6733 4.86666 13.6733 7.99333V8.32666L13.3667 8.02002C13.1733 7.82669 12.8533 7.82669 12.66 8.02002C12.4667 8.21335 12.4667 8.53335 12.66 8.72668L13.82 9.88668C13.8667 9.93334 13.92 9.96666 13.98 9.99333C14.04 10.02 14.1067 10.0333 14.1733 10.0333C14.24 10.0333 14.3 10.02 14.3667 9.99333C14.4267 9.96666 14.48 9.93334 14.5267 9.88668L15.6867 8.72668C15.88 8.54668 15.88 8.22666 15.6867 8.03333Z`,fill:`#6C7275`}),H(`path`,{d:`M13.1267 11.4666C12.9133 11.2933 12.5933 11.3266 12.4267 11.5466C11.34 12.9 9.72665 13.6733 7.99998 13.6733C4.87332 13.6733 2.32665 11.1266 2.32665 7.99996V7.66663L2.63332 7.97331C2.73332 8.07331 2.85999 8.11996 2.98665 8.11996C3.11332 8.11996 3.23999 8.07331 3.33999 7.97331C3.53332 7.77998 3.53332 7.45998 3.33999 7.26664L2.17998 6.10661C2.13332 6.05994 2.07998 6.02663 2.01998 5.99996C1.89998 5.94663 1.75998 5.94663 1.63998 5.99996C1.57998 6.02663 1.52665 6.05994 1.47999 6.10661L0.319988 7.26664C0.126654 7.45998 0.126654 7.77998 0.319988 7.97331C0.513321 8.16664 0.833319 8.16664 1.02665 7.97331L1.33332 7.66663V7.99996C1.33332 11.68 4.32665 14.6733 8.00665 14.6733C10.04 14.6733 11.94 13.76 13.2133 12.1733C13.38 11.96 13.3467 11.64 13.1267 11.4666Z`,fill:`#6C7275`})]}),`Loading`]}):`Continue`})]})})]})})}function qu(e){let t=I.routerBasename;return tc(e,{basename:t,future:{v7_fetcherPersist:!0,v7_relativeSplatPath:!0}})}function Ju(){return[{element:H(ti,{name:`RouteRoot`,children:H(Lu,{})}),children:[{index:!0,path:`d?/:driveId?/*?`,element:H(ti,{name:`Drive`,children:H(Ru,{})})},{path:`import/:documentId`,element:H(ti,{name:`AtlasImport`,children:H(Ku,{})})}]}]}var Yu=qu(Ju()),Xu=()=>H(dc,{router:Yu});function Zu(){let e=v(),t=E(),[n]=ae(),r=localStorage.getItem(`CONNECT_DEBUG`)===`true`,i=e?.ens?.name||e?.profile?.username||void 0,a=e?.ens?.avatarUrl||e?.profile?.userImage||void 0,o=ke(a?void 0:e?.address),s=()=>{m({type:`settings`})},c=()=>{m({type:`addDrive`})},l=e?.address?`https://etherscan.io/address/${e.address}`:``;return H(Oe,{children:H(Fe,{id:`sidebar`,onClick:()=>h(void 0),onClickSettings:s,address:e?.address,onLogin:S,onDisconnect:P,ensName:i||o.data?.ens,avatarUrl:a||o.data?.avatar_small||o.data?.avatar_url||void 0,etherscanUrl:l,showDebug:r,onDebugClick:()=>m({type:`debugSettings`}),children:U(Al,{variant:`text`,fallbackMessage:`There was an error loading drives`,loggerContext:[`Connect`,`Sidebar`],children:[t?.map((e,t)=>H(Ie,{title:e.header.name,onClick:()=>h(e),active:n?.header.id===e.header.id,icon:H(Pu,{drive:e})},t)),I.drives.addDriveEnabled&&H(Me,{onClick:c})]})})})}function Qu(e){window.ph?.vetraPackageManager?.updateLocalPackage(e)}function $u(e){return window.ph||(window.ph={}),pi(document.getElementById(`root`)).render(H(Ou,{localPackage:e})),{updateLocalPackage:Qu}}var ed={name:`ph-clint-app`,description:``,category:``,publisher:{name:``,url:``},documentModels:[{id:`powerhouse/ph-clint-project`,name:`PhClintProject`}],apps:[],editors:[{id:`ph-clint-project-editor`,name:`PhClintProjectEditor`,documentTypes:[`powerhouse/ph-clint-project`]}],processors:[],subgraphs:[],config:[]},td=[ar],nd=[Ar],rd=[{Component:B(()=>F(()=>import(`./editor-CQqCB-3d.js`),__vite__mapDeps([56,10,1,3,11,12,13,14,15,16,17,18,57]))),documentTypes:[`powerhouse/ph-clint-project`],config:{id:`ph-clint-project-editor`,name:`PhClintProjectEditor`}}],id=async e=>{let{processorFactoryBuilders:t}=e.processorApp===`connect`?await F(()=>import(`./connect-q2RMY-je.js`),[]):await F(()=>import(`./switchboard-BCPp_tNt.js`),[]),n=await Promise.all(t.map(async t=>await t(e)));return async t=>{let r=[];for(let i of n){let n=await i(t,e.processorApp);r.push(...n)}return r}},ad=e({AddAgentProfileRefInputSchema:()=>rn,AddAgentSkillInputSchema:()=>ht,AddAgentToolPatternInputSchema:()=>en,AddExternalSkillInputSchema:()=>sn,AddModelInputSchema:()=>ft,AddPackageDocumentTypeInputSchema:()=>wt,AddPowerhousePackageInputSchema:()=>xr,AddProfileInputSchema:()=>xt,AddSubAgentInputSchema:()=>pn,AddSupportedResourceInputSchema:()=>un,BumpVersionInputSchema:()=>gn,ClearMainAgentDescriptionInputSchema:()=>Ht,ClearMainAgentImageInputSchema:()=>Ge,DisableMastraInputSchema:()=>Pn,DisableRoutineInputSchema:()=>jr,EnableMastraInputSchema:()=>lr,EnableRoutineInputSchema:()=>Cr,ExternalSkillSchema:()=>qn,ImportMainAgentInputSchema:()=>xn,ImportModelInputSchema:()=>pr,ImportPackageInputSchema:()=>Dr,ImportProfileInputSchema:()=>On,ImportSkillInputSchema:()=>rr,ImportSpecInputSchema:()=>Fr,ImportSubAgentInputSchema:()=>Mn,PhClintAgentModelSchema:()=>Rn,PhClintAgentProfileSchema:()=>_r,PhClintDeploymentSchema:()=>or,PhClintFeaturesSchema:()=>Wn,PhClintMainAgentSchema:()=>Vn,PhClintMastraCommonSchema:()=>vn,PhClintMastraFeatureSchema:()=>Rr,PhClintProject:()=>ar,PhClintProjectController:()=>gr,PhClintProjectDocumentHeaderSchema:()=>Lr,PhClintProjectDocumentSchema:()=>Kr,PhClintProjectPHStateSchema:()=>wn,PhClintProjectStateSchema:()=>qr,PhClintRoutineFeatureSchema:()=>Tn,PhClintSubAgentSchema:()=>Wr,PowerhouseLevelSchema:()=>qt,PowerhousePackageSchema:()=>$e,PublishDevInputSchema:()=>Vr,PublishProductionInputSchema:()=>Xt,PublishRecordSchema:()=>at,PublishStagingInputSchema:()=>nt,PublishStatusSchema:()=>Ft,PublishTagSchema:()=>er,RemoveAgentProfileRefInputSchema:()=>qe,RemoveAgentSkillInputSchema:()=>Zn,RemoveAgentToolPatternInputSchema:()=>kt,RemoveExternalSkillInputSchema:()=>Mt,RemoveModelInputSchema:()=>Rt,RemovePackageDocumentTypeInputSchema:()=>ct,RemovePowerhousePackageInputSchema:()=>_t,RemoveProfileInputSchema:()=>Et,RemoveSubAgentInputSchema:()=>Wt,RemoveSupportedResourceInputSchema:()=>Xr,ReorderAgentProfileRefsInputSchema:()=>Xe,ReorderProfilesInputSchema:()=>nn,SetAgentModelInputSchema:()=>mt,SetDefaultModelInputSchema:()=>$t,SetDescriptionInputSchema:()=>on,SetEnableChatInputSchema:()=>dt,SetExternalSkillGithubUrlInputSchema:()=>Ct,SetExternalSkillNameInputSchema:()=>br,SetMainAgentDescriptionInputSchema:()=>bt,SetMainAgentImageInputSchema:()=>fn,SetMainAgentNameInputSchema:()=>ln,SetObservabilityEnabledInputSchema:()=>hn,SetPackageIdentifierInputSchema:()=>Vt,SetPackageVersionInputSchema:()=>We,SetPowerhouseLevelInputSchema:()=>Fn,SetProxyEnabledInputSchema:()=>Mr,SetPublishStatusInputSchema:()=>ur,SetSubAgentDescriptionInputSchema:()=>wr,SetSubAgentNameInputSchema:()=>Jn,SetVersionInputSchema:()=>Sn,UpdateProfileInputSchema:()=>mr,actions:()=>Pt,addAgentProfileRef:()=>kr,addAgentSkill:()=>An,addAgentToolPattern:()=>ir,addExternalSkill:()=>Qn,addModel:()=>mn,addPackageDocumentType:()=>st,addPowerhousePackage:()=>gt,addProfile:()=>St,addSubAgent:()=>tn,addSupportedResource:()=>vt,assertIsPhClintProjectDocument:()=>Ur,assertIsPhClintProjectState:()=>Kt,bumpVersion:()=>$n,clearMainAgentDescription:()=>Nr,clearMainAgentImage:()=>dr,createPhClintProjectDocument:()=>Dn,createState:()=>nr,defaultGlobalState:()=>Pr,defaultLocalState:()=>jn,defaultPHState:()=>Ln,definedNonNullAnySchema:()=>Or,disableMastra:()=>It,disableRoutine:()=>et,documentModel:()=>tt,documentModels:()=>td,editors:()=>rd,enableMastra:()=>tr,enableRoutine:()=>Hr,importSpec:()=>yn,initialGlobalState:()=>Bn,initialLocalState:()=>_n,isDefinedNonNullAny:()=>kn,isPhClintProjectDocument:()=>Qe,isPhClintProjectState:()=>Br,latestVersion:()=>cr,manifest:()=>od,phClintProjectDeploymentActions:()=>Dt,phClintProjectDocumentType:()=>Yt,phClintProjectExternalSkillsActions:()=>At,phClintProjectFeaturesMastraActions:()=>rt,phClintProjectFeaturesPowerhouseActions:()=>Zt,phClintProjectFeaturesRoutineActions:()=>Jt,phClintProjectIdentityActions:()=>zr,phClintProjectLifecycleActions:()=>Hn,phClintProjectMastraAgentBindingsActions:()=>Ir,phClintProjectMastraMainAgentActions:()=>Tr,phClintProjectMastraModelsActions:()=>Bt,phClintProjectMastraProfilesActions:()=>yr,phClintProjectMastraSubAgentsActions:()=>pt,phClintProjectPowerhousePackagesActions:()=>Tt,phClintProjectPublishingActions:()=>Ke,phClintProjectUpgradeManifest:()=>Ar,processorFactory:()=>id,publishDev:()=>Xn,publishProduction:()=>Ot,publishStaging:()=>jt,reducer:()=>it,removeAgentProfileRef:()=>Nn,removeAgentSkill:()=>zn,removeAgentToolPattern:()=>vr,removeExternalSkill:()=>Nt,removeModel:()=>Ue,removePackageDocumentType:()=>Ut,removePowerhousePackage:()=>Yr,removeProfile:()=>yt,removeSubAgent:()=>Qt,removeSupportedResource:()=>Gt,reorderAgentProfileRefs:()=>sr,reorderProfiles:()=>dn,setAgentModel:()=>Gn,setDefaultModel:()=>In,setDescription:()=>Jr,setEnableChat:()=>Je,setExternalSkillGithubUrl:()=>zt,setExternalSkillName:()=>lt,setMainAgentDescription:()=>Yn,setMainAgentImage:()=>Cn,setMainAgentName:()=>hr,setObservabilityEnabled:()=>Zr,setPackageIdentifier:()=>En,setPackageVersion:()=>Ye,setPowerhouseLevel:()=>ot,setProxyEnabled:()=>Ze,setPublishStatus:()=>Lt,setSubAgentDescription:()=>an,setSubAgentName:()=>ut,setVersion:()=>Gr,supportedVersions:()=>Sr,updateProfile:()=>cn,upgradeManifests:()=>nd,usePhClintProjectDocumentById:()=>Kn,usePhClintProjectDocumentsInSelectedDrive:()=>bn,usePhClintProjectDocumentsInSelectedFolder:()=>fr,useSelectedPhClintProjectDocument:()=>Er,utils:()=>Un}),od=ed,{updateLocalPackage:sd}=$u(ad);
|
|
52
|
+
//# sourceMappingURL=index-DmrNLi1C.js.map
|