vite-hub 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -8
- package/dist/{access-BBHk9b5P.js → access-CUFHPi8T.js} +9 -133
- package/dist/{access-policy-CUbJLvlR.d.ts → access-DkBck8Vu.d.ts} +16 -16
- package/dist/{account-CoAO1F8G.d.ts → account-DNr8fHcQ.d.ts} +1 -1
- package/dist/{console/runtime/server → agent/console}/agents.get.d.ts +1 -1
- package/dist/{console/runtime/server → agent/console}/agents.get.js +3 -3
- package/dist/{console/runtime/server → agent/console}/channel-replay.d.ts +2 -2
- package/dist/{console/runtime/server → agent/console}/channel-replay.js +6 -6
- package/dist/{console/runtime/server → agent/console}/invocation-capabilities.get.js +4 -4
- package/dist/{console/runtime/server → agent/console}/invocation-workspace.get.d.ts +3 -3
- package/dist/{console/runtime/server → agent/console}/invocation-workspace.get.js +6 -6
- package/dist/{console/runtime/server → agent/console}/invocation.get.d.ts +4 -4
- package/dist/{console/runtime/server → agent/console}/invocation.get.js +8 -8
- package/dist/{console/runtime/server → agent/console}/invocations.get.js +5 -5
- package/dist/{console/runtime/server/usage.get.d.ts → agent/console/invocations.usage.d.ts} +2 -4
- package/dist/agent/console/invocations.usage.js +51 -0
- package/dist/agent/console/operations.d.ts +6 -0
- package/dist/agent/console/operations.js +247 -0
- package/dist/{console/runtime/server → agent/console}/status.get.d.ts +2 -2
- package/dist/{console/runtime/server → agent/console}/status.get.js +6 -6
- package/dist/{server-DsOEa4_A.js → agent-console-CHsLxKk_.js} +3 -2
- package/dist/agent-console-FmaYpVv-.d.ts +14 -0
- package/dist/{agent-invocations.post-BAC1aHnG.js → agent-invocations.post-CF5anHY6.js} +8 -8
- package/dist/{agents-BClUWOj7.js → agents-DBm_PJie.js} +1 -1
- package/dist/{agents-Cz_uhhov.js → agents-DXLHsE7x.js} +2 -2
- package/dist/auth/console/auth.d.ts +25 -0
- package/dist/{console/runtime/server → auth/console}/auth.js +11 -12
- package/dist/auth/console/operations.d.ts +3 -0
- package/dist/auth/console/operations.js +135 -0
- package/dist/{auth-operations-arLIY2_2.js → auth-operations-BKqoX8Ua.js} +3 -3
- package/dist/{auth-types-B4mq4YhK.d.ts → auth-types-Cotn7406.d.ts} +4 -17
- package/dist/bin.js +3 -3
- package/dist/blob/console/operations.d.ts +3 -0
- package/dist/blob/console/operations.js +44 -0
- package/dist/{blob-eH6j0AQj.js → blob-iw8pWQ6o.js} +2 -2
- package/dist/{blob-_TtxDb-t.d.ts → blob-uNin0_TV.d.ts} +1 -1
- package/dist/cache/operations.js +1 -1
- package/dist/console/auth-types.d.ts +2 -2
- package/dist/console/auth.d.ts +2 -2
- package/dist/console/runtime/auth-operations.d.ts +3 -3
- package/dist/console/runtime/auth-operations.js +1 -1
- package/dist/console/runtime/client/account.d.ts +1 -1
- package/dist/console/runtime/client/account.js +2 -2
- package/dist/console/runtime/client/auth-management.ts +6 -6
- package/dist/console/runtime/client/blob-media.js +2 -2
- package/dist/console/runtime/client/comment-thread.js +1 -1
- package/dist/console/runtime/client/content-heads.js +1 -1
- package/dist/console/runtime/client/documents.d.ts +1 -1
- package/dist/console/runtime/client/documents.js +1 -1
- package/dist/console/runtime/client/invocation.js +1 -1
- package/dist/console/runtime/client/live.d.ts +1 -1
- package/dist/console/runtime/client/mcp-client.d.ts +4 -4
- package/dist/console/runtime/client/mcp-client.js +4 -6
- package/dist/console/runtime/client/media-library.js +1 -1
- package/dist/console/runtime/client/media-uploads.js +1 -1
- package/dist/console/runtime/client/operation-view.js +1 -1
- package/dist/console/runtime/client/presence.d.ts +1 -1
- package/dist/console/runtime/client/problem.d.ts +1 -1
- package/dist/console/runtime/client/problem.js +2 -2
- package/dist/console/runtime/client/project-link.d.ts +1 -1
- package/dist/console/runtime/client/project-link.js +1 -1
- package/dist/console/runtime/client/project-session.d.ts +2 -2
- package/dist/console/runtime/client/project-session.js +1 -1
- package/dist/console/runtime/client/publish.d.ts +1 -1
- package/dist/console/runtime/client/rate-limit.js +1 -1
- package/dist/console/runtime/client/read-only.d.ts +1 -1
- package/dist/console/runtime/client/read-only.js +1 -1
- package/dist/console/runtime/client/request.d.ts +2 -2
- package/dist/console/runtime/client/request.js +1 -1
- package/dist/console/runtime/client/schedule-run.js +1 -1
- package/dist/console/runtime/client/sections.d.ts +1 -1
- package/dist/console/runtime/client/sections.js +1 -1
- package/dist/console/runtime/client/site-access.d.ts +48 -9
- package/dist/console/runtime/client/site-access.js +18 -11
- package/dist/console/runtime/client/site-link.d.ts +2 -0
- package/dist/console/runtime/client/site-link.js +1 -0
- package/dist/console/runtime/client/workflow.js +1 -1
- package/dist/console/runtime/components/console-auth-detail.vue +1 -1
- package/dist/console/runtime/components/console-auth-event-list.vue +1 -0
- package/dist/console/runtime/components/console-document-editor.vue +3 -4
- package/dist/console/runtime/components/console-usage.vue +2 -2
- package/dist/console/runtime/diagnostics.ts +14 -56
- package/dist/console/runtime/mcp-client.d.ts +2 -2
- package/dist/console/runtime/mcp-client.js +1 -1
- package/dist/console/runtime/operation-loader.d.ts +1 -0
- package/dist/console/runtime/operation-loader.js +10 -0
- package/dist/console/runtime/page-tool/page-tool.js +2 -2
- package/dist/console/runtime/sections.d.ts +2 -2
- package/dist/console/runtime/sections.js +1 -1
- package/dist/console/runtime/server/access-policy.d.ts +1 -1
- package/dist/console/runtime/server/agent-console.d.ts +2 -0
- package/dist/console/runtime/server/agent-console.js +1 -0
- package/dist/console/runtime/server/blob.d.ts +1 -1
- package/dist/console/runtime/server/blob.js +1 -1
- package/dist/console/runtime/server/database.d.ts +1 -1
- package/dist/console/runtime/server/definitions.get.d.ts +2 -2
- package/dist/console/runtime/server/definitions.get.js +2 -2
- package/dist/console/runtime/server/definitions.js +1 -1
- package/dist/console/runtime/server/documents.d.ts +2 -2
- package/dist/console/runtime/server/documents.js +2 -2
- package/dist/console/runtime/server/entry-site-access.d.ts +3 -0
- package/dist/console/runtime/server/entry-site-access.js +4 -0
- package/dist/console/runtime/server/entry.d.ts +3 -0
- package/dist/console/runtime/server/entry.js +4 -0
- package/dist/console/runtime/server/operation-contributions.d.ts +1 -1
- package/dist/console/runtime/server/operation-contributions.js +1 -1
- package/dist/console/runtime/server/pill.d.ts +45 -0
- package/dist/console/runtime/server/pill.js +62 -0
- package/dist/console/runtime/server/rpc.d.ts +5 -8
- package/dist/console/runtime/server/rpc.js +13 -20
- package/dist/console/runtime/server/runtime.d.ts +1 -1
- package/dist/console/runtime/server/runtime.js +1 -1
- package/dist/console/runtime/server/sections.d.ts +4 -4
- package/dist/console/runtime/server/sections.get.d.ts +1 -1
- package/dist/console/runtime/server/sections.get.js +4 -4
- package/dist/console/runtime/server/sections.js +3 -3
- package/dist/console/runtime/server/setup.d.ts +4 -4
- package/dist/console/runtime/server/setup.js +3 -3
- package/dist/console/runtime/server/site-access-operation.d.ts +7 -0
- package/dist/console/runtime/server/site-access-operation.js +36 -0
- package/dist/console/runtime/server/site-actions.d.ts +73 -0
- package/dist/console/runtime/server/site-actions.js +105 -0
- package/dist/console/runtime/server/site-entry.d.ts +16 -7
- package/dist/console/runtime/server/site-entry.js +59 -42
- package/dist/console/runtime/server/site-visitor.d.ts +17 -0
- package/dist/console/runtime/server/site-visitor.js +1 -0
- package/dist/console/runtime/server/site.d.ts +27 -0
- package/dist/console/runtime/server/site.js +1 -0
- package/dist/console/server.d.ts +7 -19
- package/dist/console/server.js +6 -6
- package/dist/console-signature--55DIKf2.js +237 -0
- package/dist/content/console/operations.d.ts +3 -0
- package/dist/content/console/operations.js +62 -0
- package/dist/{console/runtime/server → database/console}/database.get.d.ts +1 -1
- package/dist/{console/runtime/server → database/console}/database.get.js +4 -4
- package/dist/database/console/operations.d.ts +3 -0
- package/dist/database/console/operations.js +49 -0
- package/dist/{database-CPjZ3L0g.d.ts → database-yFezh5U1.d.ts} +1 -1
- package/dist/{definitions-M7i2p8SR.js → definitions-DGo2rNQ9.js} +1 -1
- package/dist/{dev-peer-DBq-isgi.js → dev-peer-CRYp01PE.js} +1 -219
- package/dist/dev-peer-CX5C9243.js +1 -0
- package/dist/{diagnostics-B2cqlCSz.js → diagnostics-DLHqjKGe.js} +2 -8
- package/dist/diagnostics-DgGKvWzF.d.ts +7 -0
- package/dist/doctor.js +2 -2
- package/dist/{documents-LtkKCxtu.d.ts → documents-A-7Ho0g0.d.ts} +11 -11
- package/dist/{documents-Ck_iub9w.js → documents-BduuZjm3.js} +3 -2
- package/dist/{documents-DxK0tdjA.d.ts → documents-CApMRd4o.d.ts} +2 -3
- package/dist/{documents-BOYwZ5g4.js → documents-D6ueeoUR.js} +12 -15
- package/dist/durability/operations.js +1 -1
- package/dist/{console/runtime/server → env/console}/env.get.d.ts +2 -2
- package/dist/{console/runtime/server → env/console}/env.get.js +7 -7
- package/dist/env/console/operations.d.ts +3 -0
- package/dist/env/console/operations.js +12 -0
- package/dist/env/vite.d.ts +1 -0
- package/dist/env/vite.js +2 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/{internal-CKocv79I.d.ts → internal-BRNf11h3.d.ts} +14 -4
- package/dist/{invocation-page-undo-BEi-rO0Q.js → invocation-page-undo-DHbXczWY.js} +6 -4
- package/dist/invocations-B60XWNES.js +45 -0
- package/dist/{console/runtime/server → logs/console}/logs.get.d.ts +3 -3
- package/dist/{console/runtime/server → logs/console}/logs.get.js +7 -7
- package/dist/logs/console/operations.d.ts +3 -0
- package/dist/logs/console/operations.js +23 -0
- package/dist/loopback-Bl9Cvj1k.js +139 -0
- package/dist/mcp/eval.d.ts +1 -0
- package/dist/mcp/eval.js +2 -0
- package/dist/{mcp-client-Q2XbUXuP.d.ts → mcp-client-uXVvS7RL.d.ts} +4 -6
- package/dist/{media-CAKz9yrp.js → media-CNwnh6CG.js} +5 -5
- package/dist/{media-library-BDX89xXA.js → media-library-DTC8TLsZ.js} +1 -1
- package/dist/nuxt.d.ts +1 -1
- package/dist/nuxt.js +108 -68
- package/dist/{operation-contributions-D10pjkJF.js → operation-contributions-BU10k2QS.js} +7 -6
- package/dist/{operation-contributions-BCcQVlGb.d.ts → operation-contributions-xwjDzj28.d.ts} +5 -4
- package/dist/{operation-definition-DTpNvLd8.js → operation-definition-D04Rdjbe.js} +2 -1
- package/dist/operation-modules-BUXlwjvd.js +1 -0
- package/dist/operation-modules-DHWkPcfS.js +139 -0
- package/dist/operations-D-7ljPqw.js +1 -0
- package/dist/{operations-CD_mu_Ww.js → operations-DksTrRMb.js} +1 -1
- package/dist/operations-byxiZ2R2.js +113 -0
- package/dist/{optional-owners-DAfShdgV.js → optional-owners-Cypch7V3.js} +0 -1
- package/dist/page-tools-BeZrtn4S.js +46 -0
- package/dist/page-tools-Chk8Gm9x.d.ts +23 -0
- package/dist/page-tools-shared-BLPidmCi.js +39 -0
- package/dist/{plugins-BpiTVULl.d.ts → plugins-BmkOoyIh.d.ts} +22 -9
- package/dist/{plugins-H6-MQrsn.js → plugins-DfXcUnzN.js} +248 -310
- package/dist/{project-DKBIHOf4.d.ts → project-B2qWt8on.d.ts} +2 -7
- package/dist/{project-BxyyclTE.js → project-_juMSuAS.js} +5 -7
- package/dist/{project-link-CeS0T8Pr.js → project-link-CJbCkOlC.js} +3 -3
- package/dist/{project-link-isfdRO3Q.d.ts → project-link-Ck3vuq9w.d.ts} +1 -1
- package/dist/{project-session--GN7MduT.js → project-session-8pN7pRo8.js} +4 -4
- package/dist/{request-CQ8TkHLh.js → request-D769eiBL.js} +2 -2
- package/dist/{request-BC_krbEr.d.ts → request-DYmjLTqP.d.ts} +1 -1
- package/dist/{request-CJCPyu2B.d.ts → request-DkoE0b2h.d.ts} +10 -2
- package/dist/{request-Cl68STwT.js → request-XFVx7CGC.js} +24 -2
- package/dist/routes-D02vxUSg.js +26 -0
- package/dist/{runtime-CyPZMiyK.js → runtime-DA7HJe10.js} +1 -1
- package/dist/{runtime-Cf8R1Ztr.d.ts → runtime-DGvimtvc.d.ts} +1 -1
- package/dist/{runtime-feature-guard-DpUn4Oxc.js → runtime-feature-guard-BKAMRZzM.js} +1 -1
- package/dist/search-jgMrZJXR.js +84 -0
- package/dist/{sections-BiCOk9qP.js → sections-AUGy9EkY.js} +1 -6
- package/dist/{sections-BTfWK14a.d.ts → sections-BMkFB3S-.d.ts} +1 -1
- package/dist/{sections-0qrBvGbf.d.ts → sections-DCoCa4nF.d.ts} +1 -4
- package/dist/{sections-DAtgYMVz.d.ts → sections-DjeAUX7o.d.ts} +4 -4
- package/dist/{sections-HLxb9MrG.js → sections-ZFAlI4JW.js} +2 -2
- package/dist/{sections.get-CGmtYmfu.d.ts → sections.get-BY5dClJY.d.ts} +1 -1
- package/dist/{setup-Ca7jtBLS.d.ts → setup-BBnZPziq.d.ts} +4 -7
- package/dist/{setup-DQz_i-ee.js → setup-yc3_WKNG.js} +1 -13
- package/dist/site-CZCIWsUQ.js +169 -0
- package/dist/site-link-Bvo2SxPo.js +58 -0
- package/dist/site-link-Dtw8MNVB.d.ts +18 -0
- package/dist/site-pages-B6J8U2Nq.js +66 -0
- package/dist/site-token-Wa7fhjwg.js +215 -0
- package/dist/site-visitor-BkhE2TA0.js +89 -0
- package/dist/skills/operations.js +2 -2
- package/dist/{skills.get-DAooGWy5.js → skills.get-CW8vc_Hf.js} +3 -3
- package/dist/task/operations.js +1 -1
- package/dist/usage-DBi7aOhx.js +33 -0
- package/dist/{version-CAhBr673.js → version-DUCd7Orc.js} +11 -5
- package/dist/workspace/console/operations.d.ts +3 -0
- package/dist/workspace/console/operations.js +22 -0
- package/dist/{console/runtime/server → workspace/console}/workspace-files.get.d.ts +3 -3
- package/dist/{console/runtime/server → workspace/console}/workspace-files.get.js +4 -4
- package/package.json +91 -82
- package/dist/auth-CeKxL2xp.d.ts +0 -116
- package/dist/cloudflare-env-lookup-DcN7pGlv.js +0 -15
- package/dist/console/runtime/client/ticket.d.ts +0 -2
- package/dist/console/runtime/client/ticket.js +0 -1
- package/dist/console/runtime/page/loader.js +0 -135
- package/dist/console/runtime/server/auth.d.ts +0 -2
- package/dist/console/runtime/server/mcp-client-operations.d.ts +0 -3
- package/dist/console/runtime/server/mcp-client-operations.js +0 -137
- package/dist/console/runtime/server/page-auth.d.ts +0 -16
- package/dist/console/runtime/server/page-auth.js +0 -43
- package/dist/console/runtime/server/page-tool.d.ts +0 -2
- package/dist/console/runtime/server/page-tool.js +0 -110
- package/dist/console/runtime/server/page-tools-route.d.ts +0 -2
- package/dist/console/runtime/server/page-tools-route.js +0 -4
- package/dist/console/runtime/server/search.get.d.ts +0 -2
- package/dist/console/runtime/server/search.get.js +0 -95
- package/dist/console/runtime/server/site-session.d.ts +0 -79
- package/dist/console/runtime/server/site-session.js +0 -1
- package/dist/console/runtime/server/tickets.d.ts +0 -2
- package/dist/console/runtime/server/tickets.js +0 -1
- package/dist/console/runtime/server/usage.get.js +0 -91
- package/dist/console/runtime/site-access.d.ts +0 -2
- package/dist/console/runtime/site-access.js +0 -1
- package/dist/diagnostics-BXxPggRw.d.ts +0 -9
- package/dist/invocations-8NThe8Bx.js +0 -85
- package/dist/mcp-client-Bkh-khvr.js +0 -9
- package/dist/mcp-client-DiObFpDS.js +0 -1037
- package/dist/operations-D7ENc68Y.js +0 -1
- package/dist/operations-vRLiH7dh.js +0 -852
- package/dist/page-tool-BUnUbuSy.d.ts +0 -67
- package/dist/page-tools-BQzwuAHD.js +0 -460
- package/dist/page-tools-UwsfvH-B.d.ts +0 -21
- package/dist/page-tools-shared-hJcG_xk8.js +0 -125
- package/dist/secret-D2KL_o2h.js +0 -43
- package/dist/site-access-1JIQjY11.js +0 -292
- package/dist/site-access-CUXIbbbR.d.ts +0 -53
- package/dist/site-access-CmaZ-oaL.js +0 -17
- package/dist/site-access-Cvmjb6aw.js +0 -1
- package/dist/site-session-D36fr7Wf.js +0 -297
- package/dist/skills/vitehub/SKILL.md +0 -142
- package/dist/skills/vitehub/agents/openai.yaml +0 -4
- package/dist/skills/vitehub/references/agent-definitions.md +0 -36
- package/dist/skills/vitehub/references/bundle.md +0 -57
- package/dist/skills/vitehub/references/capabilities-authority.md +0 -30
- package/dist/skills/vitehub/references/channels-triggers.md +0 -27
- package/dist/skills/vitehub/references/framework-composition.md +0 -29
- package/dist/skills/vitehub/references/preview-contract.md +0 -44
- package/dist/skills/vitehub/references/primitives/auth.md +0 -14
- package/dist/skills/vitehub/references/primitives/blob.md +0 -13
- package/dist/skills/vitehub/references/primitives/browser.md +0 -17
- package/dist/skills/vitehub/references/primitives/cache.md +0 -13
- package/dist/skills/vitehub/references/primitives/channels.md +0 -11
- package/dist/skills/vitehub/references/primitives/connections.md +0 -14
- package/dist/skills/vitehub/references/primitives/content.md +0 -13
- package/dist/skills/vitehub/references/primitives/database.md +0 -15
- package/dist/skills/vitehub/references/primitives/email.md +0 -11
- package/dist/skills/vitehub/references/primitives/env.md +0 -13
- package/dist/skills/vitehub/references/primitives/kv.md +0 -13
- package/dist/skills/vitehub/references/primitives/markdown-template.md +0 -13
- package/dist/skills/vitehub/references/primitives/queue.md +0 -14
- package/dist/skills/vitehub/references/primitives/rate-limit.md +0 -11
- package/dist/skills/vitehub/references/primitives/realtime.md +0 -19
- package/dist/skills/vitehub/references/primitives/sandbox-task.md +0 -11
- package/dist/skills/vitehub/references/primitives/sandbox.md +0 -13
- package/dist/skills/vitehub/references/primitives/schedule.md +0 -11
- package/dist/skills/vitehub/references/primitives/shell.md +0 -11
- package/dist/skills/vitehub/references/primitives/source.md +0 -11
- package/dist/skills/vitehub/references/primitives/workflow.md +0 -11
- package/dist/skills/vitehub/references/primitives/workspace.md +0 -11
- package/dist/skills/vitehub/references/project-patterns.md +0 -19
- package/dist/skills/vitehub/references/project-shapes.md +0 -81
- package/dist/skills/vitehub/references/proof-recovery.md +0 -31
- package/dist/skills/vitehub/references/sandboxes-hosts.md +0 -26
- package/dist/skills/vitehub/references/schedules-workflows-invocations.md +0 -28
- package/dist/skills/vitehub/references/server-primitives.md +0 -39
- package/dist/skills/vitehub/references/workspaces-sources-access.md +0 -26
- package/dist/ticket-BFWwevWN.d.ts +0 -12
- package/dist/ticket-BwsnryuU.js +0 -30
- package/dist/tickets-Cj9_y3gw.js +0 -356
- package/dist/usage-BduF04ks.d.ts +0 -20
- package/dist/usage-ZV3TBMzE.js +0 -570
- package/dist/usage-index-CR_xTrXO.js +0 -334
- /package/dist/{console/runtime/server → agent/console}/invocation-capabilities.get.d.ts +0 -0
- /package/dist/{console/runtime/server → agent/console}/invocations.get.d.ts +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/index.json +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/SKILL.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/agents/openai.yaml +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/agent-definitions.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/bundle.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/capabilities-authority.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/channels-triggers.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/framework-composition.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/preview-contract.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/auth.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/blob.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/browser.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/cache.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/channels.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/connections.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/content.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/database.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/email.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/env.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/kv.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/markdown-template.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/queue.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/rate-limit.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/realtime.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/sandbox-task.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/sandbox.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/schedule.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/shell.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/source.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/workflow.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/primitives/workspace.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/project-patterns.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/project-shapes.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/proof-recovery.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/sandboxes-hosts.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/schedules-workflows-invocations.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/server-primitives.md +0 -0
- /package/dist/{console/runtime/public/skills → console-skills}/vitehub/references/workspaces-sources-access.md +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as installConsoleRuntime, n as loadConsoleRuntime } from "../../../runtime-
|
|
1
|
+
export { t as installConsoleRuntime, n as loadConsoleRuntime } from "../../../runtime-DA7HJe10.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { a as consoleRealtimeAccess, i as ConsoleRealtimeUser, l as installConsoleAccess, r as ConsoleRealtimeAccess } from "../../../access-DkBck8Vu.js";
|
|
2
2
|
import { r as installConsoleDevelopment } from "../../../development-I40mfD7B.js";
|
|
3
|
-
import { t as installConsoleRuntime } from "../../../runtime-
|
|
4
|
-
import {
|
|
5
|
-
import { n as getConsoleProjectName, r as getConsoleSections, t as getConsoleBuild } from "../../../sections-
|
|
3
|
+
import { t as installConsoleRuntime } from "../../../runtime-DGvimtvc.js";
|
|
4
|
+
import { i as installConsoleVersion, n as installConsoleProjectName, r as installConsoleSections, t as installConsoleBuild } from "../../../setup-BBnZPziq.js";
|
|
5
|
+
import { n as getConsoleProjectName, r as getConsoleSections, t as getConsoleBuild } from "../../../sections-DjeAUX7o.js";
|
|
6
6
|
export { type ConsoleRealtimeAccess, type ConsoleRealtimeUser, consoleRealtimeAccess, getConsoleBuild, getConsoleProjectName, getConsoleSections, installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections, installConsoleVersion };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as listConsoleSections, t as ConsoleSectionsResponse } from "../../../sections.get-
|
|
1
|
+
import { n as listConsoleSections, t as ConsoleSectionsResponse } from "../../../sections.get-BY5dClJY.js";
|
|
2
2
|
export { ConsoleSectionsResponse, listConsoleSections };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { a as consoleAccessWrites, t as allowedConsoleSections } from "../../../access-
|
|
2
|
-
import { n as getConsoleContributedSections } from "../../../definitions-
|
|
1
|
+
import { a as consoleAccessWrites, t as allowedConsoleSections } from "../../../access-CUFHPi8T.js";
|
|
2
|
+
import { n as getConsoleContributedSections } from "../../../definitions-DGo2rNQ9.js";
|
|
3
3
|
import { n as consoleState } from "../../../internal-0C_CC601.js";
|
|
4
4
|
import { n as consoleSetupRoute } from "../../../development-DD567hhJ.js";
|
|
5
|
-
import { t as consoleOperationRegistry } from "../../../operation-contributions-
|
|
5
|
+
import { t as consoleOperationRegistry } from "../../../operation-contributions-BU10k2QS.js";
|
|
6
6
|
import { n as getConsoleProjectName, r as getConsoleSections } from "../../../sections-BNTdIEJw.js";
|
|
7
7
|
// src/console/runtime/server/sections.get.ts
|
|
8
8
|
/** Whether an Agent field such as `channels` lists at least one entry, as an array or a record. */
|
|
@@ -18,7 +18,7 @@ async function emptySections(sections) {
|
|
|
18
18
|
const empty = /* @__PURE__ */ new Set();
|
|
19
19
|
if (sections.includes("env") && !(await import("./env.js")).getConsoleEnv().entries.length) empty.add("env");
|
|
20
20
|
if (import.meta.viteHubConsoleAgents !== false && (sections.includes("skills") || sections.includes("channels"))) {
|
|
21
|
-
const { getConsoleAgentDefinition, getConsoleAgents } = await import("../../../agents-
|
|
21
|
+
const { getConsoleAgentDefinition, getConsoleAgents } = await import("../../../agents-DBm_PJie.js");
|
|
22
22
|
const definitions = getConsoleAgents().map((name) => getConsoleAgentDefinition(name, "inspect"));
|
|
23
23
|
if (sections.includes("channels") && !definitions.some((definition) => hasEntries(definition?.channels))) empty.add("channels");
|
|
24
24
|
if (sections.includes("skills")) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as installConsoleDevelopment } from "../../../development-DD567hhJ.js";
|
|
2
2
|
import { i as installConsoleAccess } from "../../../access-policy-BM48XstY.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { t as installConsoleRuntime } from "../../../runtime-DA7HJe10.js";
|
|
4
|
+
import { u as consoleRealtimeAccess } from "../../../access-CUFHPi8T.js";
|
|
5
|
+
import { i as installConsoleVersion, n as installConsoleProjectName, r as installConsoleSections, t as installConsoleBuild } from "../../../setup-yc3_WKNG.js";
|
|
6
6
|
import { n as getConsoleProjectName, r as getConsoleSections, t as getConsoleBuild } from "../../../sections-BNTdIEJw.js";
|
|
7
7
|
export { consoleRealtimeAccess, getConsoleBuild, getConsoleProjectName, getConsoleSections, installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections, installConsoleVersion };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { l as installConsoleAccess } from "../../../access-DkBck8Vu.js";
|
|
2
2
|
import { r as installConsoleDevelopment } from "../../../development-I40mfD7B.js";
|
|
3
|
-
import { t as installConsoleRuntime } from "../../../runtime-
|
|
4
|
-
import {
|
|
5
|
-
export { installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections,
|
|
3
|
+
import { t as installConsoleRuntime } from "../../../runtime-DGvimtvc.js";
|
|
4
|
+
import { i as installConsoleVersion, n as installConsoleProjectName, r as installConsoleSections, t as installConsoleBuild } from "../../../setup-BBnZPziq.js";
|
|
5
|
+
export { installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections, installConsoleVersion };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as installConsoleDevelopment } from "../../../development-DD567hhJ.js";
|
|
2
2
|
import { i as installConsoleAccess } from "../../../access-policy-BM48XstY.js";
|
|
3
|
-
import { t as installConsoleRuntime } from "../../../runtime-
|
|
4
|
-
import {
|
|
5
|
-
export { installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections,
|
|
3
|
+
import { t as installConsoleRuntime } from "../../../runtime-DA7HJe10.js";
|
|
4
|
+
import { i as installConsoleVersion, n as installConsoleProjectName, r as installConsoleSections, t as installConsoleBuild } from "../../../setup-yc3_WKNG.js";
|
|
5
|
+
export { installConsoleAccess, installConsoleBuild, installConsoleDevelopment, installConsoleProjectName, installConsoleRuntime, installConsoleSections, installConsoleVersion };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { n as AnyOperation } from "../../../operations-DgFhA1WE.js";
|
|
2
|
+
/**
|
|
3
|
+
* `site.access`: the Site access of the caller, which the ViteHub Console reads before it signs a Site access token.
|
|
4
|
+
* `write` follows write access to the `site` section, and `roles` are the `grants` of `console.authorize`, or every page
|
|
5
|
+
* tool role of the app. The Console registers it only when the app has the Site access section.
|
|
6
|
+
*/
|
|
7
|
+
export declare const siteAccessOperations: readonly AnyOperation[];
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { i as viteHubPageGrants } from "../../../page-tools-BeZrtn4S.js";
|
|
2
|
+
import { a as consoleAccessWrites, f as readConsoleAccessGrants } from "../../../access-CUFHPi8T.js";
|
|
3
|
+
import { i as defineConsoleOperation } from "../../../operations-byxiZ2R2.js";
|
|
4
|
+
import { r as consoleRequestError } from "../../../request-D769eiBL.js";
|
|
5
|
+
import * as v from "valibot";
|
|
6
|
+
/**
|
|
7
|
+
* `site.access`: the Site access of the caller, which the ViteHub Console reads before it signs a Site access token.
|
|
8
|
+
* `write` follows write access to the `site` section, and `roles` are the `grants` of `console.authorize`, or every page
|
|
9
|
+
* tool role of the app. The Console registers it only when the app has the Site access section.
|
|
10
|
+
*/
|
|
11
|
+
const siteAccessOperations = [defineConsoleOperation({
|
|
12
|
+
cli: false,
|
|
13
|
+
description: "Read the Site access of the caller: whether they may change it, and the page tool roles that they get and may give guests.",
|
|
14
|
+
input: v.strictObject({}),
|
|
15
|
+
kind: "read",
|
|
16
|
+
name: "site.access",
|
|
17
|
+
run: (_input, context) => {
|
|
18
|
+
const roles = viteHubPageGrants();
|
|
19
|
+
const grants = readConsoleAccessGrants(context.access);
|
|
20
|
+
if (grants) {
|
|
21
|
+
const known = new Set(roles.map((role) => role.id));
|
|
22
|
+
const unknown = grants.filter((grant) => !known.has(grant));
|
|
23
|
+
if (unknown.length) throw consoleRequestError(500, `console.authorize returned grants that no page tool of this app gives: ${unknown.join(", ")}.`);
|
|
24
|
+
}
|
|
25
|
+
return {
|
|
26
|
+
write: consoleAccessWrites(context.access, "site"),
|
|
27
|
+
roles: roles.filter((role) => !grants || grants.includes(role.id)).map(({ id, label, description }) => ({
|
|
28
|
+
id,
|
|
29
|
+
label,
|
|
30
|
+
...description ? { description } : {}
|
|
31
|
+
}))
|
|
32
|
+
};
|
|
33
|
+
},
|
|
34
|
+
section: "site"
|
|
35
|
+
})];
|
|
36
|
+
export { siteAccessOperations };
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { t as ConsoleRequestEvent } from "../../../request-DYmjLTqP.js";
|
|
2
|
+
/**
|
|
3
|
+
* Why the Console signed the token:
|
|
4
|
+
* - `site`: a member or a guest opens the site.
|
|
5
|
+
* - `impersonate`: a member opens the site as another person, to see what that person sees.
|
|
6
|
+
* - `preview`: a member opens a preview of the site.
|
|
7
|
+
*/
|
|
8
|
+
type SiteTokenKind = "site" | "impersonate" | "preview";
|
|
9
|
+
interface SiteCommentsAgent {
|
|
10
|
+
projectId: string;
|
|
11
|
+
teamId: string;
|
|
12
|
+
resolve: boolean;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* What an `impersonate` or `preview` token acts on, as short strings, such as `{ action: "start", userId: "u_1" }` or
|
|
16
|
+
* `{ section: "content", collection: "posts", id: "hello" }`. The app reads it only from a verified token.
|
|
17
|
+
*/
|
|
18
|
+
type SiteTokenTarget = Record<string, string>;
|
|
19
|
+
/** The person and the roles that a token signs in. */
|
|
20
|
+
interface SiteTokenClaims {
|
|
21
|
+
/** The URL of the app, its origin and base path without a trailing `/`, such as `https://app.example.com/portal`. */
|
|
22
|
+
aud: string;
|
|
23
|
+
/** The id of the person in the Console: the user id of a member, or the grant id of a guest. */
|
|
24
|
+
sub: string;
|
|
25
|
+
/** The name that the app shows, such as the author of a comment. */
|
|
26
|
+
name: string;
|
|
27
|
+
/** The email of a member. Guests have none. */
|
|
28
|
+
email?: string;
|
|
29
|
+
/** The image of a member. */
|
|
30
|
+
image?: string;
|
|
31
|
+
/** The roles of the person, such as `console` and `comments-write`. */
|
|
32
|
+
roles: string[];
|
|
33
|
+
commentsAgent?: SiteCommentsAgent;
|
|
34
|
+
kind: SiteTokenKind;
|
|
35
|
+
/** What an `impersonate` or `preview` token acts on. A `site` token has none. */
|
|
36
|
+
target?: SiteTokenTarget;
|
|
37
|
+
/** The path of the app to open after the sign-in, such as `/docs`. */
|
|
38
|
+
path: string;
|
|
39
|
+
/** The {@link siteStateHash} of the state cookie of the browser that started the visit. */
|
|
40
|
+
state: string;
|
|
41
|
+
/** Seconds since the epoch. */
|
|
42
|
+
iat: number;
|
|
43
|
+
/** Seconds since the epoch. */
|
|
44
|
+
exp: number;
|
|
45
|
+
}
|
|
46
|
+
interface SiteTokenMatch {
|
|
47
|
+
ok: true;
|
|
48
|
+
claims: SiteTokenClaims;
|
|
49
|
+
/** The `<NAME>` of the `VITEHUB_CONSOLE_KEY_<NAME>` that matched. */
|
|
50
|
+
key: string;
|
|
51
|
+
/** The URL of `claims.path` below the app URL, where the app sends the browser. */
|
|
52
|
+
destination: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Run the action of a checked `impersonate` or `preview` token of `/_vitehub/site`. The Console signs such a token for a
|
|
56
|
+
* member after the app allowed the signed operation of the kind, as that member. The app keeps no state for it: the
|
|
57
|
+
* token works for 60 seconds in the browser that started the visit, and only for its kind and target. `headers` carry
|
|
58
|
+
* the cookies of every answer.
|
|
59
|
+
*
|
|
60
|
+
* - `impersonate`: the browser's app session must belong to the email of the token, and Better Auth must let it
|
|
61
|
+
* impersonate. A stop ends only an impersonation that the person of the token started in this browser.
|
|
62
|
+
* - `preview`: the `preview` action of the document editor section runs as the person of the token, which checks that
|
|
63
|
+
* they may read the document, and a page of the app posts its frame token to the page. The Content preview plugin of
|
|
64
|
+
* the app renders the draft. Its frame form must come from the same origin, so the form leaves from here.
|
|
65
|
+
*/
|
|
66
|
+
export declare function openSiteAction(input: {
|
|
67
|
+
match: SiteTokenMatch;
|
|
68
|
+
request: Request;
|
|
69
|
+
event: ConsoleRequestEvent;
|
|
70
|
+
app: string;
|
|
71
|
+
headers: Headers;
|
|
72
|
+
}): Promise<Response>;
|
|
73
|
+
export {};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { o as consoleImpersonation } from "../../../access-CUFHPi8T.js";
|
|
2
|
+
import { r as consoleRequestError } from "../../../request-D769eiBL.js";
|
|
3
|
+
import { n as loadConsoleRuntime } from "../../../runtime-DA7HJe10.js";
|
|
4
|
+
import { r as getConsoleSections } from "../../../sections-BNTdIEJw.js";
|
|
5
|
+
import { a as sitePageHeaders, i as siteFailurePage, n as html, o as siteProblemPage, r as seeOther } from "../../../site-pages-B6J8U2Nq.js";
|
|
6
|
+
// src/console/runtime/server/site-actions.ts
|
|
7
|
+
async function authConsole(request, event) {
|
|
8
|
+
if (!getConsoleSections().includes("auth")) return void 0;
|
|
9
|
+
return (import.meta.viteHubConsoleAuth === false ? void 0 : await import("@vite-hub/auth/server"))?.getAuthConsoleForRequest(request, event, { impersonation: true });
|
|
10
|
+
}
|
|
11
|
+
async function authFailure(error) {
|
|
12
|
+
const auth = import.meta.viteHubConsoleAuth === false ? void 0 : await import("../../../auth/console/auth.js");
|
|
13
|
+
return auth ? auth.authConsoleFailure(error) : error;
|
|
14
|
+
}
|
|
15
|
+
function refused(message, headers) {
|
|
16
|
+
return siteProblemPage(401, "CONSOLE_SITE_TOKEN_REFUSED", message, void 0, headers);
|
|
17
|
+
}
|
|
18
|
+
async function impersonate(match, request, event, home, headers) {
|
|
19
|
+
if (!consoleImpersonation()) return siteFailurePage(consoleRequestError(404, "Impersonation is off. Set console.impersonation to true to enable it."), headers);
|
|
20
|
+
const api = await authConsole(request, event);
|
|
21
|
+
if (!api) return siteFailurePage(consoleRequestError(404, "The app has no Auth section."), headers);
|
|
22
|
+
const email = match.claims.email?.toLowerCase();
|
|
23
|
+
if (!email) return siteFailurePage(consoleRequestError(403, "Impersonation checks that the browser is signed in to the app with the email of your Console account, and the token has no email.", "CONSOLE_ACCESS_DENIED"), headers);
|
|
24
|
+
const [sessionError, session] = await api.session(request);
|
|
25
|
+
if (sessionError) throw sessionError;
|
|
26
|
+
if (!session) return siteProblemPage(403, "CONSOLE_SITE_ACCOUNT_MISMATCH", `Sign in to the app as ${email}, an account that may impersonate users, then start again from the Console.`, void 0, headers);
|
|
27
|
+
const { action, userId } = match.claims.target ?? {};
|
|
28
|
+
if (action === "stop") {
|
|
29
|
+
if (!session.impersonatedBy) return siteFailurePage(consoleRequestError(409, "This browser does not impersonate a user."), headers);
|
|
30
|
+
if (session.impersonatedBy.email.toLowerCase() !== email) return siteProblemPage(403, "CONSOLE_SITE_ACCOUNT_MISMATCH", `This browser impersonates for ${session.impersonatedBy.email || "another administrator"}, and the token was made for ${email}.`, void 0, headers);
|
|
31
|
+
const [error, response] = await api.stopImpersonating(request);
|
|
32
|
+
if (error) return siteFailurePage(await authFailure(error), headers);
|
|
33
|
+
return seeOther(home, mergeCookies(response.headers, headers));
|
|
34
|
+
}
|
|
35
|
+
if (action !== "start" || !userId) return refused("The impersonation token names no user.", headers);
|
|
36
|
+
if (session.user.email.toLowerCase() !== email) return siteProblemPage(403, "CONSOLE_SITE_ACCOUNT_MISMATCH", `This browser is signed in to the app as ${session.user.email}, and the token was made for ${email}. Sign in to the app as ${email}, then start again from the Console.`, void 0, headers);
|
|
37
|
+
const [error, response] = await api.execute({
|
|
38
|
+
action: "impersonate",
|
|
39
|
+
userId
|
|
40
|
+
}, request);
|
|
41
|
+
if (error) return siteFailurePage(await authFailure(error), headers);
|
|
42
|
+
return seeOther(home, mergeCookies(response.headers, headers));
|
|
43
|
+
}
|
|
44
|
+
function mergeCookies(first, second) {
|
|
45
|
+
const out = new Headers();
|
|
46
|
+
for (const cookie of [...first.getSetCookie(), ...second.getSetCookie()]) out.append("set-cookie", cookie);
|
|
47
|
+
return out;
|
|
48
|
+
}
|
|
49
|
+
async function sha256Base64(value) {
|
|
50
|
+
const digest = new Uint8Array(await crypto.subtle.digest("SHA-256", new TextEncoder().encode(value)));
|
|
51
|
+
return btoa(String.fromCharCode(...digest));
|
|
52
|
+
}
|
|
53
|
+
async function openPreview(match, headers) {
|
|
54
|
+
const { collection, id, section } = match.claims.target ?? {};
|
|
55
|
+
if (!collection || !id || !section) return refused("The preview token names no document.", headers);
|
|
56
|
+
const documents = await (import.meta.viteHubConsoleDocuments === false ? Promise.reject(consoleRequestError(404, "The Console document editor section is disabled.")) : import("./documents.js"));
|
|
57
|
+
const actions = await documents.loadConsoleDocumentActions(section);
|
|
58
|
+
const { claims } = match;
|
|
59
|
+
const user = {
|
|
60
|
+
id: claims.sub,
|
|
61
|
+
name: claims.name,
|
|
62
|
+
...claims.email ? { email: claims.email.toLowerCase() } : {},
|
|
63
|
+
...claims.image ? { image: claims.image } : {}
|
|
64
|
+
};
|
|
65
|
+
const preview = await documents.runConsoleDocumentAction(() => actions.preview({
|
|
66
|
+
collection,
|
|
67
|
+
id
|
|
68
|
+
}, { user }));
|
|
69
|
+
const parameter = Reflect.get(Object(preview), "parameter");
|
|
70
|
+
const token = Reflect.get(Object(preview), "token");
|
|
71
|
+
if (String(parameter) !== parameter || String(token) !== token) throw consoleRequestError(409, "The document editor returned no preview token.");
|
|
72
|
+
const page = new URL(match.destination);
|
|
73
|
+
page.searchParams.set(parameter, "");
|
|
74
|
+
const script = "document.forms[0].submit()";
|
|
75
|
+
const body = `<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="referrer" content="no-referrer"><title>Opening the preview</title></head><body><form method="post" action="${html(page.href)}"><input type="hidden" name="${html(parameter)}" value="${html(JSON.stringify({ token }))}"><noscript><button>Open the preview</button></noscript></form><script>${script}<\/script></body></html>`;
|
|
76
|
+
const out = new Headers({
|
|
77
|
+
...sitePageHeaders,
|
|
78
|
+
"content-security-policy": `default-src 'none'; script-src 'sha256-${await sha256Base64(script)}'; form-action 'self'; base-uri 'none'; frame-ancestors 'none'`
|
|
79
|
+
});
|
|
80
|
+
for (const cookie of headers.getSetCookie()) out.append("set-cookie", cookie);
|
|
81
|
+
return new Response(body, { headers: out });
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Run the action of a checked `impersonate` or `preview` token of `/_vitehub/site`. The Console signs such a token for a
|
|
85
|
+
* member after the app allowed the signed operation of the kind, as that member. The app keeps no state for it: the
|
|
86
|
+
* token works for 60 seconds in the browser that started the visit, and only for its kind and target. `headers` carry
|
|
87
|
+
* the cookies of every answer.
|
|
88
|
+
*
|
|
89
|
+
* - `impersonate`: the browser's app session must belong to the email of the token, and Better Auth must let it
|
|
90
|
+
* impersonate. A stop ends only an impersonation that the person of the token started in this browser.
|
|
91
|
+
* - `preview`: the `preview` action of the document editor section runs as the person of the token, which checks that
|
|
92
|
+
* they may read the document, and a page of the app posts its frame token to the page. The Content preview plugin of
|
|
93
|
+
* the app renders the draft. Its frame form must come from the same origin, so the form leaves from here.
|
|
94
|
+
*/
|
|
95
|
+
async function openSiteAction(input) {
|
|
96
|
+
const { match, headers } = input;
|
|
97
|
+
try {
|
|
98
|
+
await loadConsoleRuntime();
|
|
99
|
+
if (match.claims.kind === "preview") return await openPreview(match, headers);
|
|
100
|
+
return await impersonate(match, input.request, input.event, `${input.app}/`, headers);
|
|
101
|
+
} catch (error) {
|
|
102
|
+
return siteFailurePage(error, headers);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
export { openSiteAction };
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { n as ConsoleRoute } from "../../../request-
|
|
1
|
+
import { n as ConsoleRoute } from "../../../request-DYmjLTqP.js";
|
|
2
|
+
import "#vitehub/console/app";
|
|
2
3
|
/**
|
|
3
4
|
* The first path segments below `/_vitehub` that ViteHub serves itself, such as `/_vitehub/rpc` of the Console and
|
|
4
|
-
* `/_vitehub/blob-signed` of Blob. `/_vitehub/<name>/...` never goes back to a page: the route
|
|
5
|
-
* that no ViteHub route served. Open such a page and follow a link to `/_vitehub` from it.
|
|
5
|
+
* `/_vitehub/blob-signed` of Blob. In an app with the pill, `/_vitehub/<name>/...` never goes back to a page: the route
|
|
6
|
+
* answers 404 for a path that no ViteHub route served. Open such a page and follow a link to `/_vitehub` from it.
|
|
6
7
|
*/
|
|
7
8
|
export declare const siteEntryReservedNames: ReadonlySet<string>;
|
|
8
9
|
/**
|
|
@@ -11,12 +12,20 @@ export declare const siteEntryReservedNames: ReadonlySet<string>;
|
|
|
11
12
|
*/
|
|
12
13
|
export declare function siteEntryPage(value: string | null, base: string): string;
|
|
13
14
|
/**
|
|
14
|
-
* Where a `/_vitehub` request goes back to: the app `base` and the `page` below it, or
|
|
15
|
-
* such as `/_vitehub/rpc/x`. `origin` is the app origin, which a `Referer` must have.
|
|
15
|
+
* Where a `/_vitehub` request goes back to in an app with the pill: the app `base` and the `page` below it, or
|
|
16
|
+
* `undefined` for a reserved path, such as `/_vitehub/rpc/x`. `origin` is the app origin, which a `Referer` must have.
|
|
16
17
|
*/
|
|
17
18
|
export declare function siteEntryTarget(request: Request, origin: string): {
|
|
18
19
|
base: string;
|
|
19
20
|
page: string;
|
|
20
21
|
} | undefined;
|
|
21
|
-
|
|
22
|
-
|
|
22
|
+
/**
|
|
23
|
+
* The Console URL of a `/_vitehub` request in an app without the pill: the project is the app origin with the path
|
|
24
|
+
* before `/_vitehub`, and the Console page is the rest of the path with the query. `undefined` when the Console cannot
|
|
25
|
+
* open the app origin.
|
|
26
|
+
*/
|
|
27
|
+
export declare function siteEntryConsoleUrl(request: Request, origin: string): string | undefined;
|
|
28
|
+
/** `/_vitehub` in an app with Comments: the page of the app with the pill, through Site access when needed. */
|
|
29
|
+
export declare const siteEntryRoute: ConsoleRoute;
|
|
30
|
+
/** `/_vitehub` in an app without Comments: the page of the app in the ViteHub Console. */
|
|
31
|
+
export declare const consoleEntryRoute: ConsoleRoute;
|
|
@@ -1,41 +1,34 @@
|
|
|
1
|
-
import { s as viteHubPageToolAllows } from "../../../page-tools-BQzwuAHD.js";
|
|
2
1
|
import { n as matchesPublicOrigin } from "../../../request-origin-pzWr9UUu.js";
|
|
3
2
|
import { a as installedConsoleAccessPolicy } from "../../../access-policy-BM48XstY.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
3
|
+
import { o as consoleRoute, r as consoleRequestError, s as isConsoleDevelopmentRuntime } from "../../../request-D769eiBL.js";
|
|
4
|
+
import { t as isConsoleLoopbackRequest } from "../../../loopback-Bl9Cvj1k.js";
|
|
5
|
+
import { r as withPageTools } from "../../../site-CZCIWsUQ.js";
|
|
6
|
+
import { n as readConsoleSiteVisitor } from "../../../site-visitor-BkhE2TA0.js";
|
|
7
|
+
import { r as seeOther, t as appOrigin } from "../../../site-pages-B6J8U2Nq.js";
|
|
9
8
|
import { getStandardContext } from "@vite-hub/runtime/internal/h3";
|
|
10
|
-
import {
|
|
9
|
+
import { hostedConsoleUrl, normalizeConsoleProjectUrl } from "@vite-hub/runtime/internal/console";
|
|
10
|
+
import "#vitehub/console/app";
|
|
11
11
|
import { configuredPublicOrigins } from "@vite-hub/runtime/internal/public-url";
|
|
12
12
|
// src/console/runtime/server/site-entry.ts
|
|
13
13
|
/**
|
|
14
|
-
* `GET <base>/_vitehub` and `GET <base>/_vitehub/<page>`: the way
|
|
15
|
-
*
|
|
14
|
+
* `GET <base>/_vitehub` and `GET <base>/_vitehub/<page>`: the way into ViteHub from a page of the app. Where it goes
|
|
15
|
+
* depends on the pill of the app:
|
|
16
16
|
*
|
|
17
|
-
* -
|
|
18
|
-
*
|
|
19
|
-
* the
|
|
17
|
+
* - An app with Comments has the pill. The browser comes back to the page with `?vitehub`, which opens the pill. On a
|
|
18
|
+
* development server, and for a browser with a good site cookie, the route goes to the page at once. Another visitor
|
|
19
|
+
* goes to `<base>/_vitehub/site?return=<page>`, which sends the browser through the ViteHub Console for a Site access
|
|
20
|
+
* token. See `siteEntryRoute`.
|
|
21
|
+
* - An app without Comments has no pill. The browser goes to that page of the app in the ViteHub Console. See
|
|
22
|
+
* `consoleEntryRoute`.
|
|
20
23
|
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* one-time Site access link.
|
|
24
|
-
*
|
|
25
|
-
* Like the pill, the route answers only on the origins of `vitehub({ publicUrl })`, when it is set. Another hostname of
|
|
26
|
-
* the same deployment, such as a content origin, gets 404.
|
|
27
|
-
*
|
|
28
|
-
* The route sets a state cookie, and the Console passes the state to `site.link`. The link then works only in the
|
|
29
|
-
* browser that started here, so a link that someone else made cannot sign this browser in as them. The browser keeps
|
|
30
|
-
* one state for 10 minutes, for every tab.
|
|
24
|
+
* The route answers only on the origins of `vitehub({ publicUrl })`, when it is set. Another hostname of the same
|
|
25
|
+
* deployment, such as a content origin, gets 404.
|
|
31
26
|
*/
|
|
32
|
-
/** Seconds that the state cookie lives: long enough for a sign-in with GitHub or a passkey. */
|
|
33
|
-
const siteStateLifetime = 600;
|
|
34
27
|
const entrySegment = /\/_vitehub(?=\/|$)/;
|
|
35
28
|
/**
|
|
36
29
|
* The first path segments below `/_vitehub` that ViteHub serves itself, such as `/_vitehub/rpc` of the Console and
|
|
37
|
-
* `/_vitehub/blob-signed` of Blob. `/_vitehub/<name>/...` never goes back to a page: the route
|
|
38
|
-
* that no ViteHub route served. Open such a page and follow a link to `/_vitehub` from it.
|
|
30
|
+
* `/_vitehub/blob-signed` of Blob. In an app with the pill, `/_vitehub/<name>/...` never goes back to a page: the route
|
|
31
|
+
* answers 404 for a path that no ViteHub route served. Open such a page and follow a link to `/_vitehub` from it.
|
|
39
32
|
*/
|
|
40
33
|
const siteEntryReservedNames = /* @__PURE__ */ new Set([
|
|
41
34
|
".well-known",
|
|
@@ -57,12 +50,12 @@ const siteEntryReservedNames = /* @__PURE__ */ new Set([
|
|
|
57
50
|
"host",
|
|
58
51
|
"i",
|
|
59
52
|
"mcp",
|
|
60
|
-
"mcp-client",
|
|
61
53
|
"page",
|
|
62
54
|
"ready",
|
|
63
55
|
"realtime",
|
|
64
56
|
"rpc",
|
|
65
57
|
"schedule",
|
|
58
|
+
"site",
|
|
66
59
|
"sync",
|
|
67
60
|
"warm",
|
|
68
61
|
"webhook-queue"
|
|
@@ -86,8 +79,8 @@ function siteEntryPage(value, base) {
|
|
|
86
79
|
return `${path}${url.search}${url.hash}`;
|
|
87
80
|
}
|
|
88
81
|
/**
|
|
89
|
-
* Where a `/_vitehub` request goes back to: the app `base` and the `page` below it, or
|
|
90
|
-
* such as `/_vitehub/rpc/x`. `origin` is the app origin, which a `Referer` must have.
|
|
82
|
+
* Where a `/_vitehub` request goes back to in an app with the pill: the app `base` and the `page` below it, or
|
|
83
|
+
* `undefined` for a reserved path, such as `/_vitehub/rpc/x`. `origin` is the app origin, which a `Referer` must have.
|
|
91
84
|
*/
|
|
92
85
|
function siteEntryTarget(request, origin) {
|
|
93
86
|
const url = new URL(request.url);
|
|
@@ -118,7 +111,24 @@ function siteEntryTarget(request, origin) {
|
|
|
118
111
|
page: siteEntryPage(`${base}/${url.search}`, base)
|
|
119
112
|
};
|
|
120
113
|
}
|
|
121
|
-
|
|
114
|
+
/**
|
|
115
|
+
* The Console URL of a `/_vitehub` request in an app without the pill: the project is the app origin with the path
|
|
116
|
+
* before `/_vitehub`, and the Console page is the rest of the path with the query. `undefined` when the Console cannot
|
|
117
|
+
* open the app origin.
|
|
118
|
+
*/
|
|
119
|
+
function siteEntryConsoleUrl(request, origin) {
|
|
120
|
+
const url = new URL(request.url);
|
|
121
|
+
const at = entrySegment.exec(url.pathname);
|
|
122
|
+
const base = at ? url.pathname.slice(0, at.index) : "";
|
|
123
|
+
const page = at ? url.pathname.slice(at.index + at[0].length) : "";
|
|
124
|
+
if (!normalizeConsoleProjectUrl(`${origin}${base}`)) return void 0;
|
|
125
|
+
try {
|
|
126
|
+
return hostedConsoleUrl(`${origin}${base}`, `${page || "/"}${url.search}`);
|
|
127
|
+
} catch {
|
|
128
|
+
return;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
async function enterRequest(event) {
|
|
122
132
|
const { req: request, runtime } = getStandardContext(event);
|
|
123
133
|
const policy = installedConsoleAccessPolicy();
|
|
124
134
|
if (!policy) throw consoleRequestError(500, "Console access is not configured. The generated Console output did not install an access policy.", "CONSOLE_ACCESS_NOT_CONFIGURED");
|
|
@@ -132,19 +142,26 @@ const siteEntryRoute = consoleRoute(async (event) => {
|
|
|
132
142
|
}
|
|
133
143
|
const development = isConsoleDevelopmentRuntime();
|
|
134
144
|
if (!development && !matchesPublicOrigin(request, configuredPublicOrigins())) throw consoleRequestError(404, "ViteHub serves /_vitehub only on the public URL of the app.");
|
|
135
|
-
|
|
145
|
+
return {
|
|
146
|
+
development,
|
|
147
|
+
origin: development ? new URL(request.url).origin : appOrigin(request),
|
|
148
|
+
request
|
|
149
|
+
};
|
|
150
|
+
}
|
|
151
|
+
/** `/_vitehub` in an app with Comments: the page of the app with the pill, through Site access when needed. */
|
|
152
|
+
const siteEntryRoute = consoleRoute(async (event) => {
|
|
153
|
+
const { development, origin, request } = await enterRequest(event);
|
|
136
154
|
const target = siteEntryTarget(request, origin);
|
|
137
155
|
if (!target) throw consoleRequestError(404, "ViteHub serves this path itself, and nothing answered it. Open the page and follow a link to /_vitehub from it.");
|
|
138
156
|
const { base, page } = target;
|
|
139
|
-
if (development || await
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
return seeOther(location.href, headers);
|
|
157
|
+
if (development || await readConsoleSiteVisitor(request, base)) return seeOther(withPageTools(`${base}${page}`));
|
|
158
|
+
return seeOther(`${base}/_vitehub/site?${new URLSearchParams({ return: page })}`);
|
|
159
|
+
});
|
|
160
|
+
/** `/_vitehub` in an app without Comments: the page of the app in the ViteHub Console. */
|
|
161
|
+
const consoleEntryRoute = consoleRoute(async (event) => {
|
|
162
|
+
const { origin, request } = await enterRequest(event);
|
|
163
|
+
const location = siteEntryConsoleUrl(request, origin);
|
|
164
|
+
if (!location) throw consoleRequestError(404, "The ViteHub Console opens only apps on https:, or on http: at localhost. Open the app on such an origin.");
|
|
165
|
+
return seeOther(location);
|
|
149
166
|
});
|
|
150
|
-
export {
|
|
167
|
+
export { consoleEntryRoute, siteEntryConsoleUrl, siteEntryPage, siteEntryReservedNames, siteEntryRoute, siteEntryTarget };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { t as ViteHubSiteVisitor } from "../../../page-tools-Chk8Gm9x.js";
|
|
2
|
+
/** Seconds that a browser stays signed in after the Console signed its token. */
|
|
3
|
+
export declare const siteSessionLifetime: number;
|
|
4
|
+
/** The length of the state part of the site cookie. */
|
|
5
|
+
export declare const siteStateLength = 43;
|
|
6
|
+
export declare function siteCookieNames(base: string): Promise<{
|
|
7
|
+
session: string;
|
|
8
|
+
state: string;
|
|
9
|
+
}>;
|
|
10
|
+
/** The value of the cookie `name` of a request. */
|
|
11
|
+
export declare function cookieValue(request: Request, name: string): string | undefined;
|
|
12
|
+
/**
|
|
13
|
+
* The person of the site cookie of a request, or `undefined` without a cookie, or with one that the public keys of the
|
|
14
|
+
* app do not verify, that was made for another app, or that is older than 12 hours. `base` is the app base, such as
|
|
15
|
+
* `/portal/`. A development server checks the token against the request origin. Each Request is checked once.
|
|
16
|
+
*/
|
|
17
|
+
export declare function readConsoleSiteVisitor(request: Request, base?: string, development?: boolean): Promise<ViteHubSiteVisitor | undefined>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { t as cookieValue, n as readConsoleSiteVisitor, r as siteCookieNames, i as siteSessionLifetime, a as siteStateLength } from "../../../site-visitor-BkhE2TA0.js";
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { n as ConsoleRoute } from "../../../request-DYmjLTqP.js";
|
|
2
|
+
import "#vitehub/console/app";
|
|
3
|
+
/** A page with `?vitehub`, which opens the page tools pill. */
|
|
4
|
+
export declare function withPageTools(page: string): string;
|
|
5
|
+
/**
|
|
6
|
+
* `<base>/_vitehub/site` in an app with Comments: Site access in the app. The ViteHub Console decides who may open the
|
|
7
|
+
* site, and the app keeps no user, session, or link for it:
|
|
8
|
+
*
|
|
9
|
+
* - `GET ?return=/docs` sets the state cookie and sends the browser to the Console's `/visit`. The `project` and
|
|
10
|
+
* `intent` queries of the request go with it.
|
|
11
|
+
* - The Console checks the person and sends the browser back to `GET ?token=vst1.…` with a token that the key of the
|
|
12
|
+
* link signed for this app and this state. The route checks the token with the `VITEHUB_CONSOLE_KEY_<NAME>` public
|
|
13
|
+
* keys. A `site` token stays in the site cookie for 12 hours, and the page opens with the page tools. An
|
|
14
|
+
* `impersonate` or `preview` token runs its action once, in this request. See `site-actions.ts`.
|
|
15
|
+
* - `POST` signs the browser out of Site access. It needs `Sec-Fetch-Site: same-origin`, or, without that header, an
|
|
16
|
+
* `Origin` that is the app origin.
|
|
17
|
+
*
|
|
18
|
+
* After 12 hours, `/_vitehub` sends the browser through the Console again, which signs a new token while the person
|
|
19
|
+
* still has access.
|
|
20
|
+
*/
|
|
21
|
+
export declare const siteAccessRoute: ConsoleRoute;
|
|
22
|
+
/**
|
|
23
|
+
* `<base>/_vitehub/site` in an app without Comments. It takes only the `impersonate` and `preview` tokens that the
|
|
24
|
+
* Console starts with an `intent`. A visit without an `intent` gets 404: the app has no Site access.
|
|
25
|
+
*/
|
|
26
|
+
export declare const siteActionRoute: ConsoleRoute;
|
|
27
|
+
export { siteAccessRoute as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { t as default, t as siteAccessRoute, n as siteActionRoute, r as withPageTools } from "../../../site-CZCIWsUQ.js";
|
package/dist/console/server.d.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import "../usage-BduF04ks.js";
|
|
2
1
|
import { i as installConsoleAgents, n as getConsoleAgents, r as installConsoleAgentDefinitions } from "../agents-Gyw4VKPt.js";
|
|
3
|
-
import { n as getConsoleProjectName, r as getConsoleSections } from "../sections-
|
|
4
|
-
import { n as installConsoleBlob, t as getConsoleBlob } from "../blob-
|
|
2
|
+
import { n as getConsoleProjectName, r as getConsoleSections } from "../sections-DjeAUX7o.js";
|
|
3
|
+
import { n as installConsoleBlob, t as getConsoleBlob } from "../blob-uNin0_TV.js";
|
|
5
4
|
import { a as installConsoleDefinitions, r as getConsoleDefinitions } from "../definitions-DRkgHKmk.js";
|
|
6
|
-
import { n as
|
|
7
|
-
import { n as
|
|
5
|
+
import { n as installConsoleDatabase, t as getConsoleDatabase } from "../database-yFezh5U1.js";
|
|
6
|
+
import { n as installConsoleProjectName, r as installConsoleSections } from "../setup-BBnZPziq.js";
|
|
7
|
+
import { n as ConsoleRuntime, r as agentConsole, t as ConsoleInvocationLink } from "../agent-console-FmaYpVv-.js";
|
|
8
8
|
import { AgentInvocations } from "@vite-hub/agent";
|
|
9
|
-
import
|
|
10
|
-
import "@libsql/client";
|
|
9
|
+
import "@vite-hub/agent/usage";
|
|
11
10
|
export declare function getConsoleInvocations(): AgentInvocations;
|
|
12
11
|
/**
|
|
13
12
|
* Registers the journal that the Console reads: `configuredInvocations`, else the app-wide Agent journal.
|
|
@@ -15,15 +14,4 @@ export declare function getConsoleInvocations(): AgentInvocations;
|
|
|
15
14
|
* One server bundle serves one project, so the Console keeps one journal in its state, like its sections.
|
|
16
15
|
*/
|
|
17
16
|
export declare function installConsoleInvocations(projectRoot: string, configuredInvocations?: AgentInvocations): AgentInvocations;
|
|
18
|
-
export
|
|
19
|
-
agentName: string;
|
|
20
|
-
id: string;
|
|
21
|
-
}
|
|
22
|
-
/** The Console Runtime Capability. Read the Agent Invocation journal with `getAgentInvocations()` from `vite-hub/agent`. */
|
|
23
|
-
export interface ConsoleRuntime {
|
|
24
|
-
invocationUrl: (invocation: ConsoleInvocationLink | Record<string, unknown>) => string;
|
|
25
|
-
}
|
|
26
|
-
export declare const agentConsole: {
|
|
27
|
-
resolve(context: RuntimeHostContext<unknown>): ConsoleRuntime;
|
|
28
|
-
};
|
|
29
|
-
export { getConsoleAgents, getConsoleBlob, getConsoleDatabase, getConsoleDefinitions, getConsoleProjectName, getConsoleSections, installConsoleAgentDefinitions, installConsoleAgents, installConsoleBlob, installConsoleDatabase, installConsoleDefinitions, installConsoleProjectName, installConsoleSections };
|
|
17
|
+
export { type ConsoleInvocationLink, type ConsoleRuntime, agentConsole, getConsoleAgents, getConsoleBlob, getConsoleDatabase, getConsoleDefinitions, getConsoleProjectName, getConsoleSections, installConsoleAgentDefinitions, installConsoleAgents, installConsoleBlob, installConsoleDatabase, installConsoleDefinitions, installConsoleProjectName, installConsoleSections };
|
package/dist/console/server.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { n as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { n as installConsoleProjectName, r as installConsoleSections } from "../setup-DQz_i-ee.js";
|
|
1
|
+
import { n as installConsoleInvocations, t as getConsoleInvocations } from "../invocations-B60XWNES.js";
|
|
2
|
+
import { c as getConsoleAgents, l as installConsoleAgentDefinitions, u as installConsoleAgents } from "../agents-DXLHsE7x.js";
|
|
3
|
+
import { n as installConsoleProjectName, r as installConsoleSections } from "../setup-yc3_WKNG.js";
|
|
5
4
|
import { n as getConsoleProjectName, r as getConsoleSections } from "../sections-BNTdIEJw.js";
|
|
6
|
-
import {
|
|
5
|
+
import { n as installConsoleBlob, t as getConsoleBlob } from "../blob-iw8pWQ6o.js";
|
|
6
|
+
import { a as installConsoleDefinitions, r as getConsoleDefinitions } from "../definitions-DGo2rNQ9.js";
|
|
7
7
|
import { n as installConsoleDatabase, t as getConsoleDatabase } from "../database-CrgBUdIx.js";
|
|
8
|
-
import { t as agentConsole } from "../
|
|
8
|
+
import { t as agentConsole } from "../agent-console-CHsLxKk_.js";
|
|
9
9
|
export { agentConsole, getConsoleAgents, getConsoleBlob, getConsoleDatabase, getConsoleDefinitions, getConsoleInvocations, getConsoleProjectName, getConsoleSections, installConsoleAgentDefinitions, installConsoleAgents, installConsoleBlob, installConsoleDatabase, installConsoleDefinitions, installConsoleInvocations, installConsoleProjectName, installConsoleSections };
|