@ashlr/hub 3.13.0 → 3.14.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/CHANGELOG.md +74 -0
- package/dist/authority-surface.json +204 -124
- package/dist/build-identity.json +2 -2
- package/dist/cli/authority.js +112 -18
- package/dist/cli/authority.js.map +1 -1
- package/dist/cli/comms.d.ts +33 -19
- package/dist/cli/comms.js +128 -151
- package/dist/cli/comms.js.map +1 -1
- package/dist/cli/completions.js +1 -1
- package/dist/cli/completions.js.map +1 -1
- package/dist/cli/daemon.js +29 -0
- package/dist/cli/daemon.js.map +1 -1
- package/dist/cli/director.d.ts +8 -12
- package/dist/cli/director.js +17 -52
- package/dist/cli/director.js.map +1 -1
- package/dist/cli/fleet.js +4 -1
- package/dist/cli/fleet.js.map +1 -1
- package/dist/cli/help.js +1 -0
- package/dist/cli/help.js.map +1 -1
- package/dist/cli/leader.d.ts +27 -3
- package/dist/cli/leader.js +253 -4
- package/dist/cli/leader.js.map +1 -1
- package/dist/core/authority/server-enforcement.d.ts +110 -0
- package/dist/core/authority/server-enforcement.js +260 -0
- package/dist/core/authority/server-enforcement.js.map +1 -0
- package/dist/core/authority/standing-grant.d.ts +24 -4
- package/dist/core/authority/standing-grant.js +19 -3
- package/dist/core/authority/standing-grant.js.map +1 -1
- package/dist/core/cloud/timeline.js +13 -7
- package/dist/core/cloud/timeline.js.map +1 -1
- package/dist/core/comms/change-digest.d.ts +130 -0
- package/dist/core/comms/change-digest.js +451 -0
- package/dist/core/comms/change-digest.js.map +1 -0
- package/dist/core/comms/director-prompt.d.ts +4 -5
- package/dist/core/comms/director-prompt.js +4 -71
- package/dist/core/comms/director-prompt.js.map +1 -1
- package/dist/core/comms/director.d.ts +24 -61
- package/dist/core/comms/director.js +29 -382
- package/dist/core/comms/director.js.map +1 -1
- package/dist/core/comms/dispatch.d.ts +37 -12
- package/dist/core/comms/dispatch.js +244 -177
- package/dist/core/comms/dispatch.js.map +1 -1
- package/dist/core/comms/elon-dialogue.d.ts +23 -15
- package/dist/core/comms/elon-dialogue.js +36 -307
- package/dist/core/comms/elon-dialogue.js.map +1 -1
- package/dist/core/comms/fleet-pulse.js +4 -7
- package/dist/core/comms/fleet-pulse.js.map +1 -1
- package/dist/core/comms/handlers.d.ts +10 -6
- package/dist/core/comms/handlers.js +14 -48
- package/dist/core/comms/handlers.js.map +1 -1
- package/dist/core/comms/migrations.d.ts +47 -0
- package/dist/core/comms/migrations.js +125 -0
- package/dist/core/comms/migrations.js.map +1 -0
- package/dist/core/comms/requests.d.ts +32 -5
- package/dist/core/comms/requests.js +101 -5
- package/dist/core/comms/requests.js.map +1 -1
- package/dist/core/comms/telegram-channel.d.ts +104 -0
- package/dist/core/comms/telegram-channel.js +622 -0
- package/dist/core/comms/telegram-channel.js.map +1 -0
- package/dist/core/comms/telegram-thread-map.d.ts +56 -0
- package/dist/core/comms/telegram-thread-map.js +144 -0
- package/dist/core/comms/telegram-thread-map.js.map +1 -0
- package/dist/core/daemon/capacity-publisher.d.ts +8 -1
- package/dist/core/daemon/capacity-publisher.js +40 -2
- package/dist/core/daemon/capacity-publisher.js.map +1 -1
- package/dist/core/daemon/loop.js +18 -4
- package/dist/core/daemon/loop.js.map +1 -1
- package/dist/core/daemon/tick-deadline.d.ts +44 -0
- package/dist/core/daemon/tick-deadline.js +83 -0
- package/dist/core/daemon/tick-deadline.js.map +1 -0
- package/dist/core/daemon/tick-hooks.d.ts +7 -0
- package/dist/core/daemon/tick-hooks.js.map +1 -1
- package/dist/core/daemon/tick-progress.d.ts +39 -0
- package/dist/core/daemon/tick-progress.js +194 -0
- package/dist/core/daemon/tick-progress.js.map +1 -0
- package/dist/core/dashboard.js +3 -1
- package/dist/core/dashboard.js.map +1 -1
- package/dist/core/fleet/fleet-merge-state.d.ts +6 -0
- package/dist/core/fleet/fleet-merge-state.js.map +1 -1
- package/dist/core/fleet/host-merge.d.ts +9 -0
- package/dist/core/fleet/host-merge.js +13 -2
- package/dist/core/fleet/host-merge.js.map +1 -1
- package/dist/core/fleet/merge-gates.d.ts +13 -0
- package/dist/core/fleet/merge-gates.js +14 -0
- package/dist/core/fleet/merge-gates.js.map +1 -1
- package/dist/core/fleet/mirrors.d.ts +162 -6
- package/dist/core/fleet/mirrors.js +1051 -49
- package/dist/core/fleet/mirrors.js.map +1 -1
- package/dist/core/fleet/standing-merge-pass.d.ts +8 -0
- package/dist/core/fleet/standing-merge-pass.js +72 -1
- package/dist/core/fleet/standing-merge-pass.js.map +1 -1
- package/dist/core/fleet/status.d.ts +17 -0
- package/dist/core/fleet/status.js +22 -0
- package/dist/core/fleet/status.js.map +1 -1
- package/dist/core/fleet/tick-hooks-live.d.ts +1 -1
- package/dist/core/fleet/tick-hooks-live.js +13 -3
- package/dist/core/fleet/tick-hooks-live.js.map +1 -1
- package/dist/core/git.d.ts +17 -0
- package/dist/core/git.js +124 -25
- package/dist/core/git.js.map +1 -1
- package/dist/core/goals/open-goals.d.ts +47 -0
- package/dist/core/goals/open-goals.js +33 -0
- package/dist/core/goals/open-goals.js.map +1 -0
- package/dist/core/inbox/merge.d.ts +5 -0
- package/dist/core/inbox/merge.js +58 -2
- package/dist/core/inbox/merge.js.map +1 -1
- package/dist/core/integrations/locus.d.ts +28 -0
- package/dist/core/integrations/locus.js +155 -30
- package/dist/core/integrations/locus.js.map +1 -1
- package/dist/core/integrations/telegram-format.d.ts +40 -0
- package/dist/core/integrations/telegram-format.js +123 -0
- package/dist/core/integrations/telegram-format.js.map +1 -0
- package/dist/core/integrations/telegram.d.ts +60 -4
- package/dist/core/integrations/telegram.js +161 -28
- package/dist/core/integrations/telegram.js.map +1 -1
- package/dist/core/mcp-registry.d.ts +12 -0
- package/dist/core/mcp-registry.js +70 -0
- package/dist/core/mcp-registry.js.map +1 -1
- package/dist/core/observability/rollup.d.ts +12 -10
- package/dist/core/observability/rollup.js +44 -17
- package/dist/core/observability/rollup.js.map +1 -1
- package/dist/core/resources/connection-monitor.d.ts +9 -0
- package/dist/core/resources/connection-monitor.js +19 -9
- package/dist/core/resources/connection-monitor.js.map +1 -1
- package/dist/core/resources/quota-refresh-lease.d.ts +17 -0
- package/dist/core/resources/quota-refresh-lease.js +34 -1
- package/dist/core/resources/quota-refresh-lease.js.map +1 -1
- package/dist/core/routing/budget-api.d.ts +7 -1
- package/dist/core/routing/budget-api.js +56 -2
- package/dist/core/routing/budget-api.js.map +1 -1
- package/dist/core/routing/readiness-types.d.ts +82 -0
- package/dist/core/routing/readiness-types.js +23 -0
- package/dist/core/routing/readiness-types.js.map +1 -0
- package/dist/core/routing/readiness.d.ts +103 -0
- package/dist/core/routing/readiness.js +480 -0
- package/dist/core/routing/readiness.js.map +1 -0
- package/dist/core/sandbox/confine.js +22 -1
- package/dist/core/sandbox/confine.js.map +1 -1
- package/dist/core/sandbox/policy.d.ts +23 -0
- package/dist/core/sandbox/policy.js +100 -0
- package/dist/core/sandbox/policy.js.map +1 -1
- package/dist/core/types.d.ts +13 -0
- package/dist/core/types.js.map +1 -1
- package/dist/core/universe/builtins/preparation/manifest.json +1 -1
- package/dist/core/universe/builtins/preparation/preparation-bridge.mjs +1204 -939
- package/dist/core/universe/builtins/preparation/preparation-verification-fixtures.mjs +1319 -1054
- package/dist/core/usage/frontier-usage.d.ts +20 -2
- package/dist/core/usage/frontier-usage.js +75 -17
- package/dist/core/usage/frontier-usage.js.map +1 -1
- package/dist/core/verse/accounts.d.ts +45 -0
- package/dist/core/verse/accounts.js +246 -17
- package/dist/core/verse/accounts.js.map +1 -1
- package/dist/core/verse/apps-api.js +23 -11
- package/dist/core/verse/apps-api.js.map +1 -1
- package/dist/core/verse/apps.d.ts +11 -9
- package/dist/core/verse/apps.js +2 -2
- package/dist/core/verse/apps.js.map +1 -1
- package/dist/core/verse/authority-api.d.ts +8 -2
- package/dist/core/verse/authority-api.js +40 -5
- package/dist/core/verse/authority-api.js.map +1 -1
- package/dist/core/verse/autonomy-ladder.d.ts +172 -0
- package/dist/core/verse/autonomy-ladder.js +251 -0
- package/dist/core/verse/autonomy-ladder.js.map +1 -0
- package/dist/core/verse/context-fit.js +7 -5
- package/dist/core/verse/context-fit.js.map +1 -1
- package/dist/core/verse/control-api.d.ts +23 -1
- package/dist/core/verse/control-api.js +117 -10
- package/dist/core/verse/control-api.js.map +1 -1
- package/dist/core/verse/fleet-live-api.js +13 -5
- package/dist/core/verse/fleet-live-api.js.map +1 -1
- package/dist/core/verse/folder-io.d.ts +50 -0
- package/dist/core/verse/folder-io.js +142 -0
- package/dist/core/verse/folder-io.js.map +1 -0
- package/dist/core/verse/git-api.js +5 -4
- package/dist/core/verse/git-api.js.map +1 -1
- package/dist/core/verse/git-ops.d.ts +10 -1
- package/dist/core/verse/git-ops.js +18 -2
- package/dist/core/verse/git-ops.js.map +1 -1
- package/dist/core/verse/github-api.d.ts +1 -1
- package/dist/core/verse/github-api.js +5 -4
- package/dist/core/verse/github-api.js.map +1 -1
- package/dist/core/verse/github-repo.js +118 -14
- package/dist/core/verse/github-repo.js.map +1 -1
- package/dist/core/verse/leader-api.d.ts +5 -4
- package/dist/core/verse/leader-api.js +237 -10
- package/dist/core/verse/leader-api.js.map +1 -1
- package/dist/core/verse/local-models.d.ts +10 -0
- package/dist/core/verse/local-models.js +10 -1
- package/dist/core/verse/local-models.js.map +1 -1
- package/dist/core/verse/login-path.d.ts +73 -0
- package/dist/core/verse/login-path.js +123 -14
- package/dist/core/verse/login-path.js.map +1 -1
- package/dist/core/verse/mcp-control-api.js +4 -4
- package/dist/core/verse/mcp-control-api.js.map +1 -1
- package/dist/core/verse/mcp-scope.d.ts +22 -0
- package/dist/core/verse/mcp-scope.js +41 -1
- package/dist/core/verse/mcp-scope.js.map +1 -1
- package/dist/core/verse/mcp-seat-view.d.ts +10 -0
- package/dist/core/verse/mcp-seat-view.js +30 -4
- package/dist/core/verse/mcp-seat-view.js.map +1 -1
- package/dist/core/verse/overnight-api.js +20 -2
- package/dist/core/verse/overnight-api.js.map +1 -1
- package/dist/core/verse/path-guard.d.ts +24 -0
- package/dist/core/verse/path-guard.js +91 -22
- package/dist/core/verse/path-guard.js.map +1 -1
- package/dist/core/verse/preview-api.js +22 -0
- package/dist/core/verse/preview-api.js.map +1 -1
- package/dist/core/verse/projects.d.ts +21 -0
- package/dist/core/verse/projects.js +82 -0
- package/dist/core/verse/projects.js.map +1 -1
- package/dist/core/verse/session-controls-api.js +5 -3
- package/dist/core/verse/session-controls-api.js.map +1 -1
- package/dist/core/verse/session-handoff.d.ts +26 -0
- package/dist/core/verse/session-handoff.js +90 -12
- package/dist/core/verse/session-handoff.js.map +1 -1
- package/dist/core/verse/terminal-api.js +7 -4
- package/dist/core/verse/terminal-api.js.map +1 -1
- package/dist/core/verse/terminal.js +9 -5
- package/dist/core/verse/terminal.js.map +1 -1
- package/dist/core/verse/verse-api.js +81 -27
- package/dist/core/verse/verse-api.js.map +1 -1
- package/dist/core/verse/workspaces.d.ts +51 -0
- package/dist/core/verse/workspaces.js +177 -47
- package/dist/core/verse/workspaces.js.map +1 -1
- package/dist/core/vision/leader-apply.d.ts +40 -0
- package/dist/core/vision/leader-apply.js +101 -30
- package/dist/core/vision/leader-apply.js.map +1 -1
- package/dist/core/vision/leader-cadence.d.ts +114 -0
- package/dist/core/vision/leader-cadence.js +127 -0
- package/dist/core/vision/leader-cadence.js.map +1 -0
- package/dist/core/vision/leader-goal-evidence.d.ts +25 -0
- package/dist/core/vision/leader-goal-evidence.js +36 -0
- package/dist/core/vision/leader-goal-evidence.js.map +1 -0
- package/dist/core/vision/leader-health.d.ts +53 -0
- package/dist/core/vision/leader-health.js +92 -0
- package/dist/core/vision/leader-health.js.map +1 -0
- package/dist/core/vision/leader-operator.d.ts +176 -0
- package/dist/core/vision/leader-operator.js +355 -0
- package/dist/core/vision/leader-operator.js.map +1 -0
- package/dist/core/vision/leader-run-chain.d.ts +41 -0
- package/dist/core/vision/leader-run-chain.js +54 -0
- package/dist/core/vision/leader-run-chain.js.map +1 -0
- package/dist/core/vision/leader-seat-plan.d.ts +68 -0
- package/dist/core/vision/leader-seat-plan.js +93 -0
- package/dist/core/vision/leader-seat-plan.js.map +1 -0
- package/dist/core/vision/leader-seat.d.ts +71 -5
- package/dist/core/vision/leader-seat.js +235 -33
- package/dist/core/vision/leader-seat.js.map +1 -1
- package/dist/core/vision/leader-thread-types.d.ts +104 -0
- package/dist/core/vision/leader-thread-types.js +9 -0
- package/dist/core/vision/leader-thread-types.js.map +1 -0
- package/dist/core/vision/leader-thread.d.ts +138 -0
- package/dist/core/vision/leader-thread.js +926 -0
- package/dist/core/vision/leader-thread.js.map +1 -0
- package/dist/core/vision/leader-types.d.ts +75 -1
- package/dist/core/vision/leader.d.ts +88 -18
- package/dist/core/vision/leader.js +269 -69
- package/dist/core/vision/leader.js.map +1 -1
- package/dist/core/web/public/next/assets/{ActionMenu-Dwjk6rUQ.js → ActionMenu-CIiX2X8w.js} +2 -2
- package/dist/core/web/public/next/assets/{ActionMenu-Dwjk6rUQ.js.map → ActionMenu-CIiX2X8w.js.map} +1 -1
- package/dist/core/web/public/next/assets/Advanced-DHsysoIL.js +2 -0
- package/dist/core/web/public/next/assets/{Advanced-cVYTAsfB.js.map → Advanced-DHsysoIL.js.map} +1 -1
- package/dist/core/web/public/next/assets/{App-IsaWDsdF.js → App-CMeAocmW.js} +5 -5
- package/dist/core/web/public/next/assets/{App-IsaWDsdF.js.map → App-CMeAocmW.js.map} +1 -1
- package/dist/core/web/public/next/assets/AppsSection-DISYnMnc.js +2 -0
- package/dist/core/web/public/next/assets/{AppsSection-DDqeSrty.js.map → AppsSection-DISYnMnc.js.map} +1 -1
- package/dist/core/web/public/next/assets/AreaTrend-DK2Y2TbZ.js +2 -0
- package/dist/core/web/public/next/assets/AreaTrend-DK2Y2TbZ.js.map +1 -0
- package/dist/core/web/public/next/assets/{AutonomyOffState-CpFYS3tQ.js → AutonomyOffState-CEPSZToP.js} +3 -3
- package/dist/core/web/public/next/assets/{AutonomyOffState-CpFYS3tQ.js.map → AutonomyOffState-CEPSZToP.js.map} +1 -1
- package/dist/core/web/public/next/assets/AutonomySection-DWc3ciAD.js +2 -0
- package/dist/core/web/public/next/assets/{AutonomySection-Dwn8UtOy.js.map → AutonomySection-DWc3ciAD.js.map} +1 -1
- package/dist/core/web/public/next/assets/AutonomyStatus-CYaHjJ9U.js +2 -0
- package/dist/core/web/public/next/assets/AutonomyStatus-CYaHjJ9U.js.map +1 -0
- package/dist/core/web/public/next/assets/{BranchBar-ISZ7xUCj.js → BranchBar-BxhdiIpx.js} +2 -2
- package/dist/core/web/public/next/assets/{BranchBar-ISZ7xUCj.js.map → BranchBar-BxhdiIpx.js.map} +1 -1
- package/dist/core/web/public/next/assets/{BudgetControl-BARVp-En.js → BudgetControl-C-0KhjRS.js} +2 -2
- package/dist/core/web/public/next/assets/{BudgetControl-BARVp-En.js.map → BudgetControl-C-0KhjRS.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Button-DtE0rlWD.js → Button-D90dzI_o.js} +2 -2
- package/dist/core/web/public/next/assets/{Button-DtE0rlWD.js.map → Button-D90dzI_o.js.map} +1 -1
- package/dist/core/web/public/next/assets/{CapacityStrip-DKbKA_Aa.js → CapacityStrip-qKDBC65C.js} +2 -2
- package/dist/core/web/public/next/assets/{CapacityStrip-DKbKA_Aa.js.map → CapacityStrip-qKDBC65C.js.map} +1 -1
- package/dist/core/web/public/next/assets/ChartFrame-DY-GVUb3.js +2 -0
- package/dist/core/web/public/next/assets/ChartFrame-DY-GVUb3.js.map +1 -0
- package/dist/core/web/public/next/assets/ChartFrame-DyjmyV8N.css +1 -0
- package/dist/core/web/public/next/assets/ChatSection-DlT4QU6a.js +3 -0
- package/dist/core/web/public/next/assets/{ChatSection-C9myY4ei.js.map → ChatSection-DlT4QU6a.js.map} +1 -1
- package/dist/core/web/public/next/assets/{CloudBudgetForm-CvjK4Oh6.js → CloudBudgetForm-BrNun_Yu.js} +2 -2
- package/dist/core/web/public/next/assets/{CloudBudgetForm-CvjK4Oh6.js.map → CloudBudgetForm-BrNun_Yu.js.map} +1 -1
- package/dist/core/web/public/next/assets/CommandPalette-C5lDDKN0.js +2 -0
- package/dist/core/web/public/next/assets/CommandPalette-C5lDDKN0.js.map +1 -0
- package/dist/core/web/public/next/assets/CommandSection-B0xuU-yZ.css +1 -0
- package/dist/core/web/public/next/assets/CommandSection-DXFvPgKp.js +3 -0
- package/dist/core/web/public/next/assets/CommandSection-DXFvPgKp.js.map +1 -0
- package/dist/core/web/public/next/assets/{ConfirmDialog-CLUhzaBj.js → ConfirmDialog-BR4nZQ2D.js} +2 -2
- package/dist/core/web/public/next/assets/{ConfirmDialog-CLUhzaBj.js.map → ConfirmDialog-BR4nZQ2D.js.map} +1 -1
- package/dist/core/web/public/next/assets/{DeleteChatDialog-C_eDhV8b.js → DeleteChatDialog-BCfP12GH.js} +2 -2
- package/dist/core/web/public/next/assets/{DeleteChatDialog-C_eDhV8b.js.map → DeleteChatDialog-BCfP12GH.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Dialog-BRd_B9OE.js → Dialog-D3msQlCj.js} +2 -2
- package/dist/core/web/public/next/assets/{Dialog-BRd_B9OE.js.map → Dialog-D3msQlCj.js.map} +1 -1
- package/dist/core/web/public/next/assets/{DiffPane-Cpr9soB2.js → DiffPane-Ix6hvXlY.js} +2 -2
- package/dist/core/web/public/next/assets/{DiffPane-Cpr9soB2.js.map → DiffPane-Ix6hvXlY.js.map} +1 -1
- package/dist/core/web/public/next/assets/{DiffViewer-CNwd0W3Q.js → DiffViewer-C4WKsCIe.js} +2 -2
- package/dist/core/web/public/next/assets/{DiffViewer-CNwd0W3Q.js.map → DiffViewer-C4WKsCIe.js.map} +1 -1
- package/dist/core/web/public/next/assets/DockHost-aWP7liri.js +2 -0
- package/dist/core/web/public/next/assets/{DockHost-BcEq2qaS.js.map → DockHost-aWP7liri.js.map} +1 -1
- package/dist/core/web/public/next/assets/{EmptyState-DsN1H6MC.js → EmptyState-D2IRy3Cg.js} +2 -2
- package/dist/core/web/public/next/assets/{EmptyState-DsN1H6MC.js.map → EmptyState-D2IRy3Cg.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Epistemic-fycQTBRO.js → Epistemic-DMr18muX.js} +2 -2
- package/dist/core/web/public/next/assets/{Epistemic-fycQTBRO.js.map → Epistemic-DMr18muX.js.map} +1 -1
- package/dist/core/web/public/next/assets/{EvidenceTimeline-sCCAdnBK.js → EvidenceTimeline-DXmmz6Fi.js} +2 -2
- package/dist/core/web/public/next/assets/{EvidenceTimeline-sCCAdnBK.js.map → EvidenceTimeline-DXmmz6Fi.js.map} +1 -1
- package/dist/core/web/public/next/assets/FleetSection-BfplcwFU.js +3 -0
- package/dist/core/web/public/next/assets/FleetSection-BfplcwFU.js.map +1 -0
- package/dist/core/web/public/next/assets/Funnel-Dh2yVHws.js +2 -0
- package/dist/core/web/public/next/assets/Funnel-Dh2yVHws.js.map +1 -0
- package/dist/core/web/public/next/assets/{GearTray-CpDt0xwj.js → GearTray-Dt-ee32-.js} +2 -2
- package/dist/core/web/public/next/assets/{GearTray-CpDt0xwj.js.map → GearTray-Dt-ee32-.js.map} +1 -1
- package/dist/core/web/public/next/assets/GrowthSection-P9EUfGeA.js +2 -0
- package/dist/core/web/public/next/assets/{GrowthSection-BvZezOsX.js.map → GrowthSection-P9EUfGeA.js.map} +1 -1
- package/dist/core/web/public/next/assets/{HandoffDialog-B1G6gQyk.js → HandoffDialog-CLJQLe7M.js} +2 -2
- package/dist/core/web/public/next/assets/{HandoffDialog-B1G6gQyk.js.map → HandoffDialog-CLJQLe7M.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Input-CI0yBHmn.js → Input-D_KRJA9V.js} +2 -2
- package/dist/core/web/public/next/assets/{Input-CI0yBHmn.js.map → Input-D_KRJA9V.js.map} +1 -1
- package/dist/core/web/public/next/assets/LeaderCard-D-7DlJuR.js +2 -0
- package/dist/core/web/public/next/assets/LeaderCard-D-7DlJuR.js.map +1 -0
- package/dist/core/web/public/next/assets/LeaderCard-DNsbLwY3.css +1 -0
- package/dist/core/web/public/next/assets/LeaderConversation-DGZjWI-E.js +2 -0
- package/dist/core/web/public/next/assets/LeaderConversation-DGZjWI-E.js.map +1 -0
- package/dist/core/web/public/next/assets/LeaderConversation-DPHUTq6W.css +1 -0
- package/dist/core/web/public/next/assets/MatrixHeatmap-C7BCG2d7.js +2 -0
- package/dist/core/web/public/next/assets/MatrixHeatmap-C7BCG2d7.js.map +1 -0
- package/dist/core/web/public/next/assets/McpSection-DGbRcyv8.js +2 -0
- package/dist/core/web/public/next/assets/{McpSection-nuXer4K-.js.map → McpSection-DGbRcyv8.js.map} +1 -1
- package/dist/core/web/public/next/assets/{MessageMarkdown-BCe4TsXk.js → MessageMarkdown-DFvk06qG.js} +3 -3
- package/dist/core/web/public/next/assets/{MessageMarkdown-BCe4TsXk.js.map → MessageMarkdown-DFvk06qG.js.map} +1 -1
- package/dist/core/web/public/next/assets/{MessageMarkdownRenderer-DL3LU5kL.js → MessageMarkdownRenderer-BAv4oEUf.js} +2 -2
- package/dist/core/web/public/next/assets/{MessageMarkdownRenderer-DL3LU5kL.js.map → MessageMarkdownRenderer-BAv4oEUf.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Meter-b69LM0mU.js → Meter-CMj-VafN.js} +2 -2
- package/dist/core/web/public/next/assets/{Meter-b69LM0mU.js.map → Meter-CMj-VafN.js.map} +1 -1
- package/dist/core/web/public/next/assets/MindSection-C6kLPIjt.js +3 -0
- package/dist/core/web/public/next/assets/MindSection-C6kLPIjt.js.map +1 -0
- package/dist/core/web/public/next/assets/{MutationTokenDialog-Bm34BNVV.js → MutationTokenDialog-DbnO8aYi.js} +2 -2
- package/dist/core/web/public/next/assets/{MutationTokenDialog-Bm34BNVV.js.map → MutationTokenDialog-DbnO8aYi.js.map} +1 -1
- package/dist/core/web/public/next/assets/NeedsYouDrawer-crsiX-Nc.js +3 -0
- package/dist/core/web/public/next/assets/NeedsYouDrawer-crsiX-Nc.js.map +1 -0
- package/dist/core/web/public/next/assets/{NeedsYouList-D5Kk549g.js → NeedsYouList-CCsijdWt.js} +2 -2
- package/dist/core/web/public/next/assets/{NeedsYouList-D5Kk549g.js.map → NeedsYouList-CCsijdWt.js.map} +1 -1
- package/dist/core/web/public/next/assets/NewChatDialog-BlCHtOIr.js +3 -0
- package/dist/core/web/public/next/assets/{NewChatDialog-BqFTWgHU.js.map → NewChatDialog-BlCHtOIr.js.map} +1 -1
- package/dist/core/web/public/next/assets/{OnboardingFlow-DcDsguAM.js → OnboardingFlow-Cy9BA9eR.js} +3 -3
- package/dist/core/web/public/next/assets/{OnboardingFlow-DcDsguAM.js.map → OnboardingFlow-Cy9BA9eR.js.map} +1 -1
- package/dist/core/web/public/next/assets/OnboardingGate-BXpNFoLt.js +3 -0
- package/dist/core/web/public/next/assets/{OnboardingGate-BZafM1Vf.js.map → OnboardingGate-BXpNFoLt.js.map} +1 -1
- package/dist/core/web/public/next/assets/PreviewPane-COid5A0f.js +2 -0
- package/dist/core/web/public/next/assets/{PreviewPane-zT3gK9TD.js.map → PreviewPane-COid5A0f.js.map} +1 -1
- package/dist/core/web/public/next/assets/{ProviderLogo-AwHn2sKm.js → ProviderLogo-Cq-CYIwT.js} +2 -2
- package/dist/core/web/public/next/assets/{ProviderLogo-AwHn2sKm.js.map → ProviderLogo-Cq-CYIwT.js.map} +1 -1
- package/dist/core/web/public/next/assets/{RailStatus-xHrovWvI.js → RailStatus-Co5UB6We.js} +2 -2
- package/dist/core/web/public/next/assets/{RailStatus-xHrovWvI.js.map → RailStatus-Co5UB6We.js.map} +1 -1
- package/dist/core/web/public/next/assets/{RefreshIndicator-SEFZlMB2.js → RefreshIndicator-DO9ibnSq.js} +2 -2
- package/dist/core/web/public/next/assets/{RefreshIndicator-SEFZlMB2.js.map → RefreshIndicator-DO9ibnSq.js.map} +1 -1
- package/dist/core/web/public/next/assets/ResourcePoolConsoleApp-Dr2WRgkq.js +7 -0
- package/dist/core/web/public/next/assets/{ResourcePoolConsoleApp-CAxPQ4sZ.js.map → ResourcePoolConsoleApp-Dr2WRgkq.js.map} +1 -1
- package/dist/core/web/public/next/assets/ResourcesChrome-CwMnbqI1.js +3 -0
- package/dist/core/web/public/next/assets/ResourcesChrome-CwMnbqI1.js.map +1 -0
- package/dist/core/web/public/next/assets/ResourcesDrawer-B_Xp_JNc.js +2 -0
- package/dist/core/web/public/next/assets/ResourcesDrawer-B_Xp_JNc.js.map +1 -0
- package/dist/core/web/public/next/assets/ResourcesDrawer-DrGoO8KG.css +1 -0
- package/dist/core/web/public/next/assets/{RouteErrorBoundary-C8WGiixc.js → RouteErrorBoundary-SkNhhUbt.js} +2 -2
- package/dist/core/web/public/next/assets/{RouteErrorBoundary-C8WGiixc.js.map → RouteErrorBoundary-SkNhhUbt.js.map} +1 -1
- package/dist/core/web/public/next/assets/{RunInCloudAction-1-IPLYhf.js → RunInCloudAction-BXPlZwJQ.js} +2 -2
- package/dist/core/web/public/next/assets/{RunInCloudAction-1-IPLYhf.js.map → RunInCloudAction-BXPlZwJQ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{SeatSelector-DpwNiX8F.js → SeatSelector-J5R3zDkB.js} +3 -3
- package/dist/core/web/public/next/assets/{SeatSelector-DpwNiX8F.js.map → SeatSelector-J5R3zDkB.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Segmented-Wt1ATod9.js → Segmented-CGh_-tBb.js} +2 -2
- package/dist/core/web/public/next/assets/{Segmented-Wt1ATod9.js.map → Segmented-CGh_-tBb.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Select-By-V9lMc.js → Select-CWnmUzs3.js} +2 -2
- package/dist/core/web/public/next/assets/{Select-By-V9lMc.js.map → Select-CWnmUzs3.js.map} +1 -1
- package/dist/core/web/public/next/assets/{SessionGate-WROS02tK.js → SessionGate-sp4KsnUo.js} +2 -2
- package/dist/core/web/public/next/assets/{SessionGate-WROS02tK.js.map → SessionGate-sp4KsnUo.js.map} +1 -1
- package/dist/core/web/public/next/assets/{SessionInsightChip-DNUcruwp.js → SessionInsightChip-DLFAzdbi.js} +2 -2
- package/dist/core/web/public/next/assets/{SessionInsightChip-DNUcruwp.js.map → SessionInsightChip-DLFAzdbi.js.map} +1 -1
- package/dist/core/web/public/next/assets/{SessionSearch-UHtt7a8f.js → SessionSearch-DbFjwR1h.js} +2 -2
- package/dist/core/web/public/next/assets/{SessionSearch-UHtt7a8f.js.map → SessionSearch-DbFjwR1h.js.map} +1 -1
- package/dist/core/web/public/next/assets/{SettingsSection-Bf74l0Gj.js → SettingsSection-Ch23msJ5.js} +2 -2
- package/dist/core/web/public/next/assets/SettingsSection-Ch23msJ5.js.map +1 -0
- package/dist/core/web/public/next/assets/{SetupChecklist-CzpEcfOl.js → SetupChecklist-Bd76MBAR.js} +2 -2
- package/dist/core/web/public/next/assets/{SetupChecklist-CzpEcfOl.js.map → SetupChecklist-Bd76MBAR.js.map} +1 -1
- package/dist/core/web/public/next/assets/ShadowDecisions-C5RAY91f.js +3 -0
- package/dist/core/web/public/next/assets/ShadowDecisions-C5RAY91f.js.map +1 -0
- package/dist/core/web/public/next/assets/{Sheet-HkBOBMTT.js → Sheet-BZ2AG4Eo.js} +2 -2
- package/dist/core/web/public/next/assets/{Sheet-HkBOBMTT.js.map → Sheet-BZ2AG4Eo.js.map} +1 -1
- package/dist/core/web/public/next/assets/{ShortcutsOverlay-DiigiT8H.js → ShortcutsOverlay-C8n8y3zf.js} +2 -2
- package/dist/core/web/public/next/assets/{ShortcutsOverlay-DiigiT8H.js.map → ShortcutsOverlay-C8n8y3zf.js.map} +1 -1
- package/dist/core/web/public/next/assets/Sidebar-DN--cPYN.js +3 -0
- package/dist/core/web/public/next/assets/{Sidebar-C9YtBYVZ.js.map → Sidebar-DN--cPYN.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Slider-DaEDws-b.js → Slider-KVoJLDD6.js} +2 -2
- package/dist/core/web/public/next/assets/{Slider-DaEDws-b.js.map → Slider-KVoJLDD6.js.map} +1 -1
- package/dist/core/web/public/next/assets/StatTile-C4KgjltA.js +2 -0
- package/dist/core/web/public/next/assets/StatTile-C4KgjltA.js.map +1 -0
- package/dist/core/web/public/next/assets/StatTile-CNCqDoPO.css +1 -0
- package/dist/core/web/public/next/assets/{StatusBadge-CXG3iNL4.js → StatusBadge-CXsYqmdU.js} +2 -2
- package/dist/core/web/public/next/assets/{StatusBadge-CXG3iNL4.js.map → StatusBadge-CXsYqmdU.js.map} +1 -1
- package/dist/core/web/public/next/assets/StepBand-BMtVOFpK.js +2 -0
- package/dist/core/web/public/next/assets/StepBand-BMtVOFpK.js.map +1 -0
- package/dist/core/web/public/next/assets/{Surface-5bNA08tK.js → Surface-BfDmQcKe.js} +2 -2
- package/dist/core/web/public/next/assets/{Surface-5bNA08tK.js.map → Surface-BfDmQcKe.js.map} +1 -1
- package/dist/core/web/public/next/assets/Swimlane-B9Exxekk.js +2 -0
- package/dist/core/web/public/next/assets/Swimlane-B9Exxekk.js.map +1 -0
- package/dist/core/web/public/next/assets/Swimlane-Bf4Rjoy9.css +1 -0
- package/dist/core/web/public/next/assets/{Switch-BmCzfFnu.js → Switch-9NtO_6Lj.js} +2 -2
- package/dist/core/web/public/next/assets/{Switch-BmCzfFnu.js.map → Switch-9NtO_6Lj.js.map} +1 -1
- package/dist/core/web/public/next/assets/{Tag-WSUIaMVy.js → Tag-DscCRFcN.js} +2 -2
- package/dist/core/web/public/next/assets/{Tag-WSUIaMVy.js.map → Tag-DscCRFcN.js.map} +1 -1
- package/dist/core/web/public/next/assets/{TerminalPane-BVFgYX6K.js → TerminalPane-B668-DJW.js} +5 -5
- package/dist/core/web/public/next/assets/{TerminalPane-BVFgYX6K.js.map → TerminalPane-B668-DJW.js.map} +1 -1
- package/dist/core/web/public/next/assets/UniverseConsoleApp-BUV_brY7.js +2 -0
- package/dist/core/web/public/next/assets/{UniverseConsoleApp-BpphLqoz.js.map → UniverseConsoleApp-BUV_brY7.js.map} +1 -1
- package/dist/core/web/public/next/assets/{UniverseView-DbpbSMwO.js → UniverseView-DG70zH0W.js} +4 -4
- package/dist/core/web/public/next/assets/{UniverseView-DbpbSMwO.js.map → UniverseView-DG70zH0W.js.map} +1 -1
- package/dist/core/web/public/next/assets/UsageSection-DY7uOTm1.js +3 -0
- package/dist/core/web/public/next/assets/UsageSection-DY7uOTm1.js.map +1 -0
- package/dist/core/web/public/next/assets/VerseConsoleApp-CWU6R3By.js +3 -0
- package/dist/core/web/public/next/assets/VerseConsoleApp-CWU6R3By.js.map +1 -0
- package/dist/core/web/public/next/assets/Workspace-D1nP9BhD.js +10 -0
- package/dist/core/web/public/next/assets/{Workspace-RXy0pqp6.js.map → Workspace-D1nP9BhD.js.map} +1 -1
- package/dist/core/web/public/next/assets/actions-CY-PjpGc.js +2 -0
- package/dist/core/web/public/next/assets/{actions-BZTidCXZ.js.map → actions-CY-PjpGc.js.map} +1 -1
- package/dist/core/web/public/next/assets/actions-DkWhhWIg.css +1 -0
- package/dist/core/web/public/next/assets/{apps-model-CHO133qt.js → apps-model-Du02KhAf.js} +2 -2
- package/dist/core/web/public/next/assets/{apps-model-CHO133qt.js.map → apps-model-Du02KhAf.js.map} +1 -1
- package/dist/core/web/public/next/assets/{authority-model-8NeAEwAF.js → authority-model-79SeuKlJ.js} +2 -2
- package/dist/core/web/public/next/assets/{authority-model-8NeAEwAF.js.map → authority-model-79SeuKlJ.js.map} +1 -1
- package/dist/core/web/public/next/assets/autonomy-ladder-BGWmZzP7.css +1 -0
- package/dist/core/web/public/next/assets/autonomy-ladder.module-ArDv4bkr.js +2 -0
- package/dist/core/web/public/next/assets/autonomy-ladder.module-ArDv4bkr.js.map +1 -0
- package/dist/core/web/public/next/assets/budget-queries-D8QV5XtH.js +2 -0
- package/dist/core/web/public/next/assets/{budget-queries-DFF-3ICg.js.map → budget-queries-D8QV5XtH.js.map} +1 -1
- package/dist/core/web/public/next/assets/{capacity-strip-model-5ViUgUlP.js → capacity-strip-model-BwZ1ZbkU.js} +2 -2
- package/dist/core/web/public/next/assets/{capacity-strip-model-5ViUgUlP.js.map → capacity-strip-model-BwZ1ZbkU.js.map} +1 -1
- package/dist/core/web/public/next/assets/charts-BZ50mZD_.js +2 -0
- package/dist/core/web/public/next/assets/charts-BZ50mZD_.js.map +1 -0
- package/dist/core/web/public/next/assets/charts-ClCB18la.css +1 -0
- package/dist/core/web/public/next/assets/{cloud-model-CfRydq8N.js → cloud-model-BDivRMqv.js} +2 -2
- package/dist/core/web/public/next/assets/{cloud-model-CfRydq8N.js.map → cloud-model-BDivRMqv.js.map} +1 -1
- package/dist/core/web/public/next/assets/{cloud-queries-DmptbjS8.js → cloud-queries-BPQQ5_pJ.js} +2 -2
- package/dist/core/web/public/next/assets/{cloud-queries-DmptbjS8.js.map → cloud-queries-BPQQ5_pJ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{colors-BZ3a9wFf.js → colors-DvK0wMHH.js} +2 -2
- package/dist/core/web/public/next/assets/{colors-BZ3a9wFf.js.map → colors-DvK0wMHH.js.map} +1 -1
- package/dist/core/web/public/next/assets/{command-catalog-ffCAijVY.js → command-catalog-BIntSa9l.js} +2 -2
- package/dist/core/web/public/next/assets/command-catalog-BIntSa9l.js.map +1 -0
- package/dist/core/web/public/next/assets/{context-model-CDeyP0cA.js → context-model-Br8t9jgG.js} +2 -2
- package/dist/core/web/public/next/assets/{context-model-CDeyP0cA.js.map → context-model-Br8t9jgG.js.map} +1 -1
- package/dist/core/web/public/next/assets/{context-model-Bb15chFt.js → context-model-CokrgEUq.js} +3 -3
- package/dist/core/web/public/next/assets/{context-model-Bb15chFt.js.map → context-model-CokrgEUq.js.map} +1 -1
- package/dist/core/web/public/next/assets/context-queries-eL3caKVG.js +2 -0
- package/dist/core/web/public/next/assets/{context-queries-_9bFWb9v.js.map → context-queries-eL3caKVG.js.map} +1 -1
- package/dist/core/web/public/next/assets/{control-queries-CXtmZZH6.js → control-queries-B9K-wmcB.js} +2 -2
- package/dist/core/web/public/next/assets/{control-queries-CXtmZZH6.js.map → control-queries-B9K-wmcB.js.map} +1 -1
- package/dist/core/web/public/next/assets/{copy-setup-BIp0iaiZ.js → copy-setup-XMgCC5f8.js} +2 -2
- package/dist/core/web/public/next/assets/{copy-setup-BIp0iaiZ.js.map → copy-setup-XMgCC5f8.js.map} +1 -1
- package/dist/core/web/public/next/assets/{dock-icons-Cc43W7r4.js → dock-icons-BJ6ZqB2t.js} +2 -2
- package/dist/core/web/public/next/assets/{dock-icons-Cc43W7r4.js.map → dock-icons-BJ6ZqB2t.js.map} +1 -1
- package/dist/core/web/public/next/assets/{fleet-model-DOK8ZtEt.js → fleet-model-BvDR3gjp.js} +2 -2
- package/dist/core/web/public/next/assets/{fleet-model-DOK8ZtEt.js.map → fleet-model-BvDR3gjp.js.map} +1 -1
- package/dist/core/web/public/next/assets/{fleet-queries-BeEAqD6y.js → fleet-queries-W2UFVMZJ.js} +2 -2
- package/dist/core/web/public/next/assets/{fleet-queries-BeEAqD6y.js.map → fleet-queries-W2UFVMZJ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{focus-trap-ChZ5EFfM.js → focus-trap-CtI1SlMX.js} +2 -2
- package/dist/core/web/public/next/assets/{focus-trap-ChZ5EFfM.js.map → focus-trap-CtI1SlMX.js.map} +1 -1
- package/dist/core/web/public/next/assets/{format-BmH2yWL6.js → format-CH4g_sl1.js} +2 -2
- package/dist/core/web/public/next/assets/{format-BmH2yWL6.js.map → format-CH4g_sl1.js.map} +1 -1
- package/dist/core/web/public/next/assets/{format-DKrNjdwD.js → format-D7nBg2bn.js} +2 -2
- package/dist/core/web/public/next/assets/{format-DKrNjdwD.js.map → format-D7nBg2bn.js.map} +1 -1
- package/dist/core/web/public/next/assets/{git-model-BFwAVbxF.js → git-model-Dnkd1TnK.js} +2 -2
- package/dist/core/web/public/next/assets/{git-model-BFwAVbxF.js.map → git-model-Dnkd1TnK.js.map} +1 -1
- package/dist/core/web/public/next/assets/global-CMNW_dqn.js +2 -0
- package/dist/core/web/public/next/assets/{global-y_exIyAP.js.map → global-CMNW_dqn.js.map} +1 -1
- package/dist/core/web/public/next/assets/guarded-runners-YeAc9wLQ.js +2 -0
- package/dist/core/web/public/next/assets/{guarded-runners-Cd4POBtI.js.map → guarded-runners-YeAc9wLQ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{icons-CygCEFWs.js → icons-D1sYbCTQ.js} +2 -2
- package/dist/core/web/public/next/assets/{icons-CygCEFWs.js.map → icons-D1sYbCTQ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{index-CyK31YRm.js → index-DZ-UQ7v8.js} +3 -3
- package/dist/core/web/public/next/assets/{index-CyK31YRm.js.map → index-DZ-UQ7v8.js.map} +1 -1
- package/dist/core/web/public/next/assets/leader-focus-BjeJv7CW.js +2 -0
- package/dist/core/web/public/next/assets/leader-focus-BjeJv7CW.js.map +1 -0
- package/dist/core/web/public/next/assets/leader-thread-types-CDb-VPPO.js +2 -0
- package/dist/core/web/public/next/assets/leader-thread-types-CDb-VPPO.js.map +1 -0
- package/dist/core/web/public/next/assets/{live-model-D7hilYFk.js → live-model-D_32RAOR.js} +2 -2
- package/dist/core/web/public/next/assets/{live-model-D7hilYFk.js.map → live-model-D_32RAOR.js.map} +1 -1
- package/dist/core/web/public/next/assets/{mind.module-B15k0Y9q.js → mind.module-7hA92hRg.js} +2 -2
- package/dist/core/web/public/next/assets/{mind.module-B15k0Y9q.js.map → mind.module-7hA92hRg.js.map} +1 -1
- package/dist/core/web/public/next/assets/mutations-DQPbFdRJ.js +2 -0
- package/dist/core/web/public/next/assets/{mutations-CWlxEMEm.js.map → mutations-DQPbFdRJ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{nav-mimleI0R.js → nav-0dOYe2rJ.js} +2 -2
- package/dist/core/web/public/next/assets/{nav-mimleI0R.js.map → nav-0dOYe2rJ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{overnight-queries-DJ4mZKSj.js → overnight-queries-C4wOnFtE.js} +2 -2
- package/dist/core/web/public/next/assets/{overnight-queries-DJ4mZKSj.js.map → overnight-queries-C4wOnFtE.js.map} +1 -1
- package/dist/core/web/public/next/assets/primitives-2A5Eq8FQ.js +1 -0
- package/dist/core/web/public/next/assets/{queries-Bw1McHTj.js → queries-BTXWdZzU.js} +2 -2
- package/dist/core/web/public/next/assets/{queries-Bw1McHTj.js.map → queries-BTXWdZzU.js.map} +1 -1
- package/dist/core/web/public/next/assets/{reasoning-pref-KkhI_5-j.js → reasoning-pref-Ca6lN6x_.js} +2 -2
- package/dist/core/web/public/next/assets/{reasoning-pref-KkhI_5-j.js.map → reasoning-pref-Ca6lN6x_.js.map} +1 -1
- package/dist/core/web/public/next/assets/{reveal-anchor-CCCx_kfT.js → reveal-anchor-DfNLgK_I.js} +2 -2
- package/dist/core/web/public/next/assets/{reveal-anchor-CCCx_kfT.js.map → reveal-anchor-DfNLgK_I.js.map} +1 -1
- package/dist/core/web/public/next/assets/seat-subscription-C5uPHBsN.js +2 -0
- package/dist/core/web/public/next/assets/{seat-subscription-BhUUz7VL.js.map → seat-subscription-C5uPHBsN.js.map} +1 -1
- package/dist/core/web/public/next/assets/{sidebar-model-Dcd437cf.js → sidebar-model-CLCdqwkR.js} +2 -2
- package/dist/core/web/public/next/assets/{sidebar-model-Dcd437cf.js.map → sidebar-model-CLCdqwkR.js.map} +1 -1
- package/dist/core/web/public/next/assets/{slots-BL_J5mmV.js → slots-C-qBeu-8.js} +3 -3
- package/dist/core/web/public/next/assets/{slots-BL_J5mmV.js.map → slots-C-qBeu-8.js.map} +1 -1
- package/dist/core/web/public/next/assets/{surface-data-C3UAQ4QX.js → surface-data-Dj71tdD-.js} +2 -2
- package/dist/core/web/public/next/assets/{surface-data-C3UAQ4QX.js.map → surface-data-Dj71tdD-.js.map} +1 -1
- package/dist/core/web/public/next/assets/surface-prefetch-B0WdJOJG.js +2 -0
- package/dist/core/web/public/next/assets/surface-prefetch-B0WdJOJG.js.map +1 -0
- package/dist/core/web/public/next/assets/{tasks-model-CzHvclVm.js → tasks-model-O8yR5YXp.js} +2 -2
- package/dist/core/web/public/next/assets/{tasks-model-CzHvclVm.js.map → tasks-model-O8yR5YXp.js.map} +1 -1
- package/dist/core/web/public/next/assets/{terminal-icons-BwgQTQP0.js → terminal-icons-CoRZq9iO.js} +2 -2
- package/dist/core/web/public/next/assets/{terminal-icons-BwgQTQP0.js.map → terminal-icons-CoRZq9iO.js.map} +1 -1
- package/dist/core/web/public/next/assets/thread-data-DQB_g66d.js +2 -0
- package/dist/core/web/public/next/assets/thread-data-DQB_g66d.js.map +1 -0
- package/dist/core/web/public/next/assets/{usage-queries-pXxvy54x.js → usage-queries-AdjEyEtn.js} +2 -2
- package/dist/core/web/public/next/assets/{usage-queries-pXxvy54x.js.map → usage-queries-AdjEyEtn.js.map} +1 -1
- package/dist/core/web/public/next/assets/{use-guarded-action-EgVWjM5c.js → use-guarded-action-CuuMHeDX.js} +2 -2
- package/dist/core/web/public/next/assets/{use-guarded-action-EgVWjM5c.js.map → use-guarded-action-CuuMHeDX.js.map} +1 -1
- package/dist/core/web/public/next/assets/{use-ticker-BoqFxRFG.js → use-ticker-BBcp02SZ.js} +2 -2
- package/dist/core/web/public/next/assets/{use-ticker-BoqFxRFG.js.map → use-ticker-BBcp02SZ.js.map} +1 -1
- package/dist/core/web/public/next/assets/{use-token-gate-DSNIIpI6.js → use-token-gate-CbXVYQYI.js} +2 -2
- package/dist/core/web/public/next/assets/{use-token-gate-DSNIIpI6.js.map → use-token-gate-CbXVYQYI.js.map} +1 -1
- package/dist/core/web/public/next/assets/{useOnboarding-Bk0VnkxQ.js → useOnboarding-C_Fpe_sH.js} +2 -2
- package/dist/core/web/public/next/assets/{useOnboarding-Bk0VnkxQ.js.map → useOnboarding-C_Fpe_sH.js.map} +1 -1
- package/dist/core/web/public/next/assets/{useSeatsRefresh-q7Id9RcW.js → useSeatsRefresh-Co1CnxLc.js} +2 -2
- package/dist/core/web/public/next/assets/{useSeatsRefresh-q7Id9RcW.js.map → useSeatsRefresh-Co1CnxLc.js.map} +1 -1
- package/dist/core/web/public/next/assets/{useVerseTranscript-CqH51rt9.js → useVerseTranscript-DgbigUlV.js} +2 -2
- package/dist/core/web/public/next/assets/{useVerseTranscript-CqH51rt9.js.map → useVerseTranscript-DgbigUlV.js.map} +1 -1
- package/dist/core/web/public/next/assets/{verse-icons-DsG1dOQx.js → verse-icons-S56hIiXS.js} +2 -2
- package/dist/core/web/public/next/assets/{verse-icons-DsG1dOQx.js.map → verse-icons-S56hIiXS.js.map} +1 -1
- package/dist/core/web/public/next/assets/verse-model-DAVevkNe.js +2 -0
- package/dist/core/web/public/next/assets/{verse-model-JTuvRBVK.js.map → verse-model-DAVevkNe.js.map} +1 -1
- package/dist/core/web/public/next/assets/{warmup-Bv1RumVq.js → warmup-B_RAtNZ_.js} +3 -3
- package/dist/core/web/public/next/assets/{warmup-Bv1RumVq.js.map → warmup-B_RAtNZ_.js.map} +1 -1
- package/dist/core/web/public/next/assets/{why-seat-model-Cau8qG6O.js → why-seat-model-M_r0wX3b.js} +2 -2
- package/dist/core/web/public/next/assets/{why-seat-model-Cau8qG6O.js.map → why-seat-model-M_r0wX3b.js.map} +1 -1
- package/dist/core/web/public/next/assets/{workspace-model-D-SLfads.js → workspace-model-dji5-Al3.js} +2 -2
- package/dist/core/web/public/next/assets/{workspace-model-D-SLfads.js.map → workspace-model-dji5-Al3.js.map} +1 -1
- package/dist/core/web/public/next/index.html +1 -1
- package/dist/core/web/read-projection-worker.js +2 -1
- package/dist/core/web/read-projection-worker.js.map +1 -1
- package/dist/core/web/read-projections.d.ts +3 -0
- package/dist/core/web/read-projections.js +2 -2
- package/dist/core/web/read-projections.js.map +1 -1
- package/dist/core/web/visibility.js +3 -4
- package/dist/core/web/visibility.js.map +1 -1
- package/dist/release-dependency-inventory.json +1 -1
- package/package.json +3 -2
- package/dist/core/web/public/next/assets/Advanced-cVYTAsfB.js +0 -2
- package/dist/core/web/public/next/assets/AppsSection-DDqeSrty.js +0 -2
- package/dist/core/web/public/next/assets/AreaTrend-C32rUaxm.js +0 -2
- package/dist/core/web/public/next/assets/AreaTrend-C32rUaxm.js.map +0 -1
- package/dist/core/web/public/next/assets/AutonomySection-Dwn8UtOy.js +0 -2
- package/dist/core/web/public/next/assets/ChartFrame-BVuBe6RP.css +0 -1
- package/dist/core/web/public/next/assets/ChartFrame-DK_BDXCt.js +0 -2
- package/dist/core/web/public/next/assets/ChartFrame-DK_BDXCt.js.map +0 -1
- package/dist/core/web/public/next/assets/ChatSection-C9myY4ei.js +0 -3
- package/dist/core/web/public/next/assets/CommandPalette-DzPsth0u.js +0 -2
- package/dist/core/web/public/next/assets/CommandPalette-DzPsth0u.js.map +0 -1
- package/dist/core/web/public/next/assets/CommandSection-Brp73iox.js +0 -3
- package/dist/core/web/public/next/assets/CommandSection-Brp73iox.js.map +0 -1
- package/dist/core/web/public/next/assets/CommandSection-CvAVd1w4.css +0 -1
- package/dist/core/web/public/next/assets/DockHost-BcEq2qaS.js +0 -2
- package/dist/core/web/public/next/assets/FleetSection-BG8iGraG.js +0 -3
- package/dist/core/web/public/next/assets/FleetSection-BG8iGraG.js.map +0 -1
- package/dist/core/web/public/next/assets/Funnel-B88_wpA4.js +0 -2
- package/dist/core/web/public/next/assets/Funnel-B88_wpA4.js.map +0 -1
- package/dist/core/web/public/next/assets/GrowthSection-BvZezOsX.js +0 -2
- package/dist/core/web/public/next/assets/LeaderCard-BxxiEg4e.js +0 -2
- package/dist/core/web/public/next/assets/LeaderCard-BxxiEg4e.js.map +0 -1
- package/dist/core/web/public/next/assets/MatrixHeatmap-iPFEU2Tv.js +0 -2
- package/dist/core/web/public/next/assets/MatrixHeatmap-iPFEU2Tv.js.map +0 -1
- package/dist/core/web/public/next/assets/McpSection-nuXer4K-.js +0 -2
- package/dist/core/web/public/next/assets/MindSection-Dc5v5rH3.js +0 -2
- package/dist/core/web/public/next/assets/MindSection-Dc5v5rH3.js.map +0 -1
- package/dist/core/web/public/next/assets/NeedsYouDrawer-N1cWJjpz.js +0 -3
- package/dist/core/web/public/next/assets/NeedsYouDrawer-N1cWJjpz.js.map +0 -1
- package/dist/core/web/public/next/assets/NewChatDialog-BqFTWgHU.js +0 -3
- package/dist/core/web/public/next/assets/OnboardingGate-BZafM1Vf.js +0 -3
- package/dist/core/web/public/next/assets/PreviewPane-zT3gK9TD.js +0 -2
- package/dist/core/web/public/next/assets/ResourcePoolConsoleApp-CAxPQ4sZ.js +0 -7
- package/dist/core/web/public/next/assets/ResourcesChrome-BnhnEdJe.js +0 -3
- package/dist/core/web/public/next/assets/ResourcesChrome-BnhnEdJe.js.map +0 -1
- package/dist/core/web/public/next/assets/ResourcesDrawer-BAFGodny.js +0 -2
- package/dist/core/web/public/next/assets/ResourcesDrawer-BAFGodny.js.map +0 -1
- package/dist/core/web/public/next/assets/ResourcesDrawer-BCFJ2Uq8.css +0 -1
- package/dist/core/web/public/next/assets/SettingsSection-Bf74l0Gj.js.map +0 -1
- package/dist/core/web/public/next/assets/Sidebar-C9YtBYVZ.js +0 -3
- package/dist/core/web/public/next/assets/StatTile-BuLMsJMx.css +0 -1
- package/dist/core/web/public/next/assets/StatTile-CTX41O6y.js +0 -2
- package/dist/core/web/public/next/assets/StatTile-CTX41O6y.js.map +0 -1
- package/dist/core/web/public/next/assets/StepBand-jJTqYIdX.js +0 -2
- package/dist/core/web/public/next/assets/StepBand-jJTqYIdX.js.map +0 -1
- package/dist/core/web/public/next/assets/Swimlane-LrslsGxw.js +0 -2
- package/dist/core/web/public/next/assets/Swimlane-LrslsGxw.js.map +0 -1
- package/dist/core/web/public/next/assets/Swimlane-o6_Zsrnr.css +0 -1
- package/dist/core/web/public/next/assets/UniverseConsoleApp-BpphLqoz.js +0 -2
- package/dist/core/web/public/next/assets/UsageSection-CUlaKtws.js +0 -3
- package/dist/core/web/public/next/assets/UsageSection-CUlaKtws.js.map +0 -1
- package/dist/core/web/public/next/assets/VerseConsoleApp-DXDv1aOi.js +0 -3
- package/dist/core/web/public/next/assets/VerseConsoleApp-DXDv1aOi.js.map +0 -1
- package/dist/core/web/public/next/assets/Workspace-RXy0pqp6.js +0 -10
- package/dist/core/web/public/next/assets/actions-BZTidCXZ.js +0 -2
- package/dist/core/web/public/next/assets/actions-BmIf9avl.css +0 -1
- package/dist/core/web/public/next/assets/budget-queries-DFF-3ICg.js +0 -2
- package/dist/core/web/public/next/assets/charts-CzxWrZn7.js +0 -2
- package/dist/core/web/public/next/assets/charts-CzxWrZn7.js.map +0 -1
- package/dist/core/web/public/next/assets/charts-DhKTrQLw.css +0 -1
- package/dist/core/web/public/next/assets/command-catalog-ffCAijVY.js.map +0 -1
- package/dist/core/web/public/next/assets/context-queries-_9bFWb9v.js +0 -2
- package/dist/core/web/public/next/assets/global-y_exIyAP.js +0 -2
- package/dist/core/web/public/next/assets/guarded-runners-Cd4POBtI.js +0 -2
- package/dist/core/web/public/next/assets/mutations-CWlxEMEm.js +0 -2
- package/dist/core/web/public/next/assets/primitives-DMijqcu0.js +0 -1
- package/dist/core/web/public/next/assets/seat-subscription-BhUUz7VL.js +0 -2
- package/dist/core/web/public/next/assets/surface-prefetch-BXKjPsV5.js +0 -2
- package/dist/core/web/public/next/assets/surface-prefetch-BXKjPsV5.js.map +0 -1
- package/dist/core/web/public/next/assets/verse-model-JTuvRBVK.js +0 -2
package/dist/core/web/public/next/assets/{surface-data-C3UAQ4QX.js → surface-data-Dj71tdD-.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
2
|
-
//# sourceMappingURL=surface-data-
|
|
1
|
+
import{I as e,O as t,W as n,l as r,o as i,u as a}from"./global-CMNW_dqn.js";import{F as o}from"./VerseConsoleApp-CWU6R3By.js";import{n as s}from"./control-queries-B9K-wmcB.js";var c=`/api/verse/authority`,l=`/api/verse/authority/draft`,u=`/api/verse/fleet/live`,d=`/api/verse/leader`,f=`/api/verse/learning`,p=`/api/verse/fleet/history?days=90`;function m(e=new Date){return`${p}&tz=${e.getTimezoneOffset()}`}var h=`/api/reasoning/digest?days=30`,g=`/api/verse/budget/history?days=8`,_=Object.freeze({authority:`verse-authority`,authorityDraft:`verse-authority-draft`,fleetLive:`verse-fleet-live`,leader:`verse-leader`,learning:`verse-learning`,fleetHistory:`verse-fleet-history-90d`,reasoningDigest:`verse-reasoning-digest-30d`,seatHistory:`verse-seat-history-8d`});function v(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var y={authority(e){return v(e)&&e.v===1&&typeof e.switch==`string`&&v(e.grant)?e:null},draft(e){return v(e)&&v(e.payload)&&typeof e.digest==`string`?e:null},fleetLive(e){return v(e)&&e.v===1&&Array.isArray(e.runs)&&Array.isArray(e.repos)&&Array.isArray(e.lanes)&&v(e.summary)?e:null},leader(e){return v(e)&&e.v===1&&Array.isArray(e.timeline)&&Array.isArray(e.actions)&&v(e.hitRate)?e:null},learning(e){return v(e)&&e.v===1&&Array.isArray(e.versions)&&Array.isArray(e.experiments)?e:null},activity(e){return v(e)&&Array.isArray(e.needsYou)&&Array.isArray(e.running)&&v(e.sources)?e:null},fleetHistory(e){return v(e)&&Array.isArray(e.days)&&v(e.sources)&&v(e.funnel)?e:null},reasoningDigest(e){return v(e)&&Array.isArray(e.insights)&&Array.isArray(e.trends)&&v(e.totals)?e:null},seatHistory(e){return v(e)&&e.v===1&&Array.isArray(e.series)?e:null}};function b(e,t){return t instanceof i?t.status===404?`${e} is not in this build yet, so this card has no source.`:t.status===503?`${e} failed to load on the server.`:t.detail&&t.status<500?/[.!?]$/.test(t.detail)?t.detail:`${t.detail}.`:`${e} answered HTTP ${t.status}.`:`${e} could not be reached.`}function x(e,t,n,a){return{key:e,fetch:async e=>{try{let n=a(await r(typeof t==`function`?t():t,e));return n===null?{value:null,available:!0,reason:`Unrecognized response — update Ashlr.`}:{value:n,available:!0,reason:null}}catch(e){if(e instanceof i&&e.status===401||e instanceof DOMException&&e.name===`AbortError`)throw e;return{value:null,available:!1,reason:b(n,e),code:e instanceof i?e.code:null}}}}}var S=x(_.authority,c,`The authority service`,y.authority),C=x(_.authorityDraft,l,`The grant draft`,y.draft),w=x(_.fleetLive,u,`The live fleet view`,y.fleetLive),T=x(_.leader,d,`The Leader`,y.leader),E=x(_.learning,f,`Self-improvement`,y.learning),D=x(_.fleetHistory,()=>m(),`Fleet history`,y.fleetHistory),O=x(_.reasoningDigest,h,`The reasoning digest`,y.reasoningDigest),k=x(_.seatHistory,g,`Seat history`,y.seatHistory);async function A(n,r){let i=t();if(!i)throw new s;let o=await a(n,r,i);return e(),o}async function j(e){let t=await A(c,e);return n(_.authority),n(_.fleetLive),o(),(e.action===`grant`||e.action===`re-approve`)&&n(_.authorityDraft),y.authority(t)}async function M(e){let t=await A(u,e);return n(_.fleetLive),o(),t}async function N(e){let t=await A(d,e);return n(_.leader),o(),t}async function P(e,t){if(!/^\/api\/[^\s\\]*$/.test(e)||e.startsWith(`//`)||e.includes(`..`))throw Error(`That action points outside this app, so it was not sent.`);let r=await A(e,t);return o(),n(_.fleetLive),n(_.leader),n(_.authority),r}export{w as a,x as c,N as d,P as f,D as i,j as l,k as m,C as n,T as o,O as p,S as r,E as s,_ as t,M as u};
|
|
2
|
+
//# sourceMappingURL=surface-data-Dj71tdD-.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surface-data-C3UAQ4QX.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/command/surface-data.ts"],"sourcesContent":["/**\n * routes/verse/command/surface-data.ts — every read and write behind the\n * four 3.10 surfaces (Command, Fleet, Growth, Mind), in one place (unit C7).\n *\n * GET /api/verse/authority AuthorityStatusV1 (B-U1)\n * GET /api/verse/authority/draft AuthorityGrantDraft (B-U1)\n * POST /api/verse/authority AuthorityActionRequest\n * GET /api/verse/fleet/live FleetLiveSnapshotV1 (B-U5)\n * POST /api/verse/fleet/live FleetLiveActionRequest\n * GET /api/verse/leader LeaderStateV1 (B-U8)\n * POST /api/verse/leader LeaderActionRequest\n * GET /api/verse/learning LearningStateV1 (B-U9)\n * GET /api/verse/activity VerseActivityResponse (C1 — read through\n * the shell's ONE useActivity poll, never a\n * second loop from here)\n * GET /api/verse/fleet/history FleetHistoryResponse (A8)\n * GET /api/reasoning/digest ReasoningDigest (A7)\n * GET /api/verse/budget BudgetView (A9 — budget-queries.ts)\n * GET /api/verse/budget/history CapacityHistoryResponse (3.10.1 — recorded\n * seat window history for the burn-downs)\n * GET /api/models per-model ROI (data/queries.ts)\n *\n * WHY every read is OPTIONAL: Track B's modules land in parallel with these\n * surfaces (SPEC-310BC-COORD), and C0's mount answers 404 for a family that\n * has not landed. A 404 is \"this card has no source yet\", never \"Command is\n * broken\" — so a read resolves to `{ value: null, available: false, reason }`\n * and the card renders a designed not-available state from `reason`. A body\n * this client cannot narrow is treated the same way (available, but nothing\n * shown rather than guessed). 401 and aborts still propagate: an expired\n * read session is the whole app's state, not one card's.\n *\n * Writes pull the held mutation token (VerseControlLockedError without one —\n * the surfaces route every write through useGuardedAction, which opens the\n * token dialog first) and invalidate exactly the keys they change.\n */\nimport { ApiError, apiGet, apiPost } from '../../../data/client.js';\nimport { getMutationToken, touchMutationHold } from '../../../data/auth-store.js';\nimport { invalidate } from '../../../data/cache.js';\nimport type { QueryDef } from '../../../data/queries.js';\nimport { VerseControlLockedError } from '../autonomy/control-queries.js';\nimport { refreshActivity } from '../shell/useActivity.js';\nimport type { OptionalFleetRead } from '../autonomy/fleet-contract.js';\nimport type {\n AuthorityActionRequest,\n AuthorityGrantDraft,\n AuthorityStatusV1,\n} from '../../../../core/authority/types.js';\nimport type { FleetLiveActionRequest, FleetLiveSnapshotV1 } from '../../../../core/fleet/fleet-types.js';\nimport type { LeaderActionRequest, LeaderStateV1 } from '../../../../core/vision/leader-types.js';\nimport type { LearningStateV1 } from '../../../../core/learn/harness-types.js';\nimport type { VerseActivityResponse } from '../../../../core/verse/workbench-types.js';\nimport type { FleetHistoryResponse } from '../../../../core/verse/fleet-history-types.js';\nimport type { ReasoningDigest } from '../../../../core/reasoning/types.js';\nimport type { CapacityHistoryResponse } from '../../../../core/routing/capacity-history-types.js';\n\n/** A read that is allowed to be absent (the autonomy folder's shape, reused). */\nexport type OptionalRead<T> = OptionalFleetRead<T>;\n\nexport const AUTHORITY_PATH = '/api/verse/authority';\nexport const AUTHORITY_DRAFT_PATH = '/api/verse/authority/draft';\nexport const FLEET_LIVE_PATH = '/api/verse/fleet/live';\nexport const LEADER_PATH = '/api/verse/leader';\nexport const LEARNING_PATH = '/api/verse/learning';\nexport const FLEET_HISTORY_PATH = '/api/verse/fleet/history?days=90';\n\n/**\n * FLEET_HISTORY_PATH plus the viewer's zone (`tz`, Date#getTimezoneOffset\n * minutes, which the route accepts). Without it the server bucketed runs by\n * the UTC day (tz defaults to 0), so a Sep 25 evening's runs sat in a\n * \"Sep 26\" column west of UTC. Read at fetch time, so a DST change between\n * polls is picked up.\n */\nexport function fleetHistoryPath(now: Date = new Date()): string {\n return `${FLEET_HISTORY_PATH}&tz=${now.getTimezoneOffset()}`;\n}\nexport const REASONING_DIGEST_PATH = '/api/reasoning/digest?days=30';\n/** Eight days: the whole weekly window plus the day before it opened. */\nexport const SEAT_HISTORY_PATH = '/api/verse/budget/history?days=8';\n\nexport const SURFACE_KEYS = Object.freeze({\n authority: 'verse-authority',\n authorityDraft: 'verse-authority-draft',\n fleetLive: 'verse-fleet-live',\n leader: 'verse-leader',\n learning: 'verse-learning',\n fleetHistory: 'verse-fleet-history-90d',\n reasoningDigest: 'verse-reasoning-digest-30d',\n seatHistory: 'verse-seat-history-8d',\n});\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return value !== null && typeof value === 'object' && !Array.isArray(value);\n}\n\n/**\n * Structural guards: just enough to know the body is the contract's shape\n * (version tag + the arrays the cards iterate), so a mismatched server can\n * never crash a render with `undefined.map`. Field-level honesty (null =\n * unknown) is the cards' job.\n */\nexport const narrow = {\n authority(raw: unknown): AuthorityStatusV1 | null {\n return isRecord(raw) && raw['v'] === 1 && typeof raw['switch'] === 'string' && isRecord(raw['grant']) ? (raw as unknown as AuthorityStatusV1) : null;\n },\n draft(raw: unknown): AuthorityGrantDraft | null {\n return isRecord(raw) && isRecord(raw['payload']) && typeof raw['digest'] === 'string' ? (raw as unknown as AuthorityGrantDraft) : null;\n },\n fleetLive(raw: unknown): FleetLiveSnapshotV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['runs']) && Array.isArray(raw['repos']) && Array.isArray(raw['lanes']) && isRecord(raw['summary'])\n ? (raw as unknown as FleetLiveSnapshotV1)\n : null;\n },\n leader(raw: unknown): LeaderStateV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['timeline']) && Array.isArray(raw['actions']) && isRecord(raw['hitRate'])\n ? (raw as unknown as LeaderStateV1)\n : null;\n },\n learning(raw: unknown): LearningStateV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['versions']) && Array.isArray(raw['experiments']) ? (raw as unknown as LearningStateV1) : null;\n },\n activity(raw: unknown): VerseActivityResponse | null {\n return isRecord(raw) && Array.isArray(raw['needsYou']) && Array.isArray(raw['running']) && isRecord(raw['sources']) ? (raw as unknown as VerseActivityResponse) : null;\n },\n fleetHistory(raw: unknown): FleetHistoryResponse | null {\n return isRecord(raw) && Array.isArray(raw['days']) && isRecord(raw['sources']) && isRecord(raw['funnel']) ? (raw as unknown as FleetHistoryResponse) : null;\n },\n reasoningDigest(raw: unknown): ReasoningDigest | null {\n return isRecord(raw) && Array.isArray(raw['insights']) && Array.isArray(raw['trends']) && isRecord(raw['totals']) ? (raw as unknown as ReasoningDigest) : null;\n },\n /** Series and points are re-checked one by one where they are merged (command-model mergeSeatHistory). */\n seatHistory(raw: unknown): CapacityHistoryResponse | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['series']) ? (raw as unknown as CapacityHistoryResponse) : null;\n },\n};\n\n/** Operator words for a source that did not answer (never a path, never a trace). */\nfunction absence(what: string, err: unknown): string {\n if (err instanceof ApiError) {\n if (err.status === 404) return `${what} is not in this build yet, so this card has no source.`;\n if (err.status === 503) return `${what} failed to load on the server.`;\n // A refusal the route explained (409 with a sentence): say it, not the status.\n if (err.detail && err.status < 500) return /[.!?]$/.test(err.detail) ? err.detail : `${err.detail}.`;\n return `${what} answered HTTP ${err.status}.`;\n }\n return `${what} could not be reached.`;\n}\n\n/** A QueryDef whose value is an OptionalRead: 404 / unreachable / unrecognised all resolve, never throw. */\nexport function optionalQuery<T>(key: string, path: string | (() => string), what: string, guard: (raw: unknown) => T | null): QueryDef<OptionalRead<T>> {\n return {\n key,\n fetch: async (signal) => {\n try {\n const raw = await apiGet<unknown>(typeof path === 'function' ? path() : path, signal);\n const value = guard(raw);\n if (value === null) {\n // Nothing is shown rather than guessed from an unknown shape.\n return { value: null, available: true, reason: 'Unrecognized response — update Ashlr.' };\n }\n return { value, available: true, reason: null };\n } catch (err) {\n if (err instanceof ApiError && err.status === 401) throw err;\n if (err instanceof DOMException && err.name === 'AbortError') throw err;\n return { value: null, available: false, reason: absence(what, err), code: err instanceof ApiError ? err.code : null };\n }\n },\n };\n}\n\nexport const authorityQuery = optionalQuery(SURFACE_KEYS.authority, AUTHORITY_PATH, 'The authority service', narrow.authority);\nexport const authorityDraftQuery = optionalQuery(SURFACE_KEYS.authorityDraft, AUTHORITY_DRAFT_PATH, 'The grant draft', narrow.draft);\nexport const fleetLiveQuery = optionalQuery(SURFACE_KEYS.fleetLive, FLEET_LIVE_PATH, 'The live fleet view', narrow.fleetLive);\nexport const leaderQuery = optionalQuery(SURFACE_KEYS.leader, LEADER_PATH, 'The Leader', narrow.leader);\nexport const learningQuery = optionalQuery(SURFACE_KEYS.learning, LEARNING_PATH, 'Self-improvement', narrow.learning);\nexport const fleetHistoryQuery = optionalQuery(SURFACE_KEYS.fleetHistory, () => fleetHistoryPath(), 'Fleet history', narrow.fleetHistory);\nexport const reasoningDigestQuery = optionalQuery(SURFACE_KEYS.reasoningDigest, REASONING_DIGEST_PATH, 'The reasoning digest', narrow.reasoningDigest);\n/** Optional like every surface read: a server without the route leaves the burn-downs on this page's own readings. */\nexport const seatHistoryQuery = optionalQuery(SURFACE_KEYS.seatHistory, SEAT_HISTORY_PATH, 'Seat history', narrow.seatHistory);\n\n// ---------------------------------------------------------------------------\n// Writes\n// ---------------------------------------------------------------------------\n\nasync function post<T>(path: string, body: unknown): Promise<T> {\n const token = getMutationToken();\n if (!token) throw new VerseControlLockedError();\n const result = await apiPost<T>(path, body, token);\n touchMutationHold();\n return result;\n}\n\n/**\n * One authority action. The server answers the new AuthorityStatusV1 for\n * every form; raising past the grant is its 409 `grant-required` (the page\n * opens the Touch ID sheet BEFORE ever sending that, but the server is the\n * authority — a stale page gets the refusal, not a raise).\n */\nexport async function postAuthority(action: AuthorityActionRequest): Promise<AuthorityStatusV1 | null> {\n const result = await post<unknown>(AUTHORITY_PATH, action);\n invalidate(SURFACE_KEYS.authority);\n invalidate(SURFACE_KEYS.fleetLive);\n void refreshActivity();\n if (action.action === 'grant' || action.action === 're-approve') invalidate(SURFACE_KEYS.authorityDraft);\n return narrow.authority(result);\n}\n\nexport async function postFleetLive(action: FleetLiveActionRequest): Promise<unknown> {\n const result = await post<unknown>(FLEET_LIVE_PATH, action);\n invalidate(SURFACE_KEYS.fleetLive);\n void refreshActivity();\n return result;\n}\n\nexport async function postLeader(action: LeaderActionRequest): Promise<unknown> {\n const result = await post<unknown>(LEADER_PATH, action);\n invalidate(SURFACE_KEYS.leader);\n void refreshActivity();\n return result;\n}\n\n/**\n * A Needs-you item's own action. `path` was validated by the producer\n * (isNeedsYouItem → isSafeApiRoute) and is re-checked here: the mutation\n * token must never be aimed anywhere but this origin's /api/.\n */\nexport async function postNeedsYouAction(path: string, body: Record<string, unknown>): Promise<unknown> {\n if (!/^\\/api\\/[^\\s\\\\]*$/.test(path) || path.startsWith('//') || path.includes('..')) {\n throw new Error('That action points outside this app, so it was not sent.');\n }\n const result = await post<unknown>(path, body);\n void refreshActivity();\n invalidate(SURFACE_KEYS.fleetLive);\n invalidate(SURFACE_KEYS.leader);\n invalidate(SURFACE_KEYS.authority);\n return result;\n}\n"],"mappings":"gLA0DA,IAA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,MAAM,EAC9B,EAAqB,EACd,CACT,CAOA,eAAsB,EAAmB,EAAc,EAAiD,CACtG,GAAI,CAAC,oBAAoB,KAAK,CAAI,GAAK,EAAK,WAAW,IAAI,GAAK,EAAK,SAAS,IAAI,EAChF,MAAU,MAAM,0DAA0D,EAE5E,IAAM,EAAS,MAAM,EAAc,EAAM,CAAI,EAK7C,OAJA,EAAqB,EACrB,EAAW,EAAa,SAAS,EACjC,EAAW,EAAa,MAAM,EAC9B,EAAW,EAAa,SAAS,EAC1B,CACT"}
|
|
1
|
+
{"version":3,"file":"surface-data-Dj71tdD-.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/command/surface-data.ts"],"sourcesContent":["/**\n * routes/verse/command/surface-data.ts — every read and write behind the\n * four 3.10 surfaces (Command, Fleet, Growth, Mind), in one place (unit C7).\n *\n * GET /api/verse/authority AuthorityStatusV1 (B-U1)\n * GET /api/verse/authority/draft AuthorityGrantDraft (B-U1)\n * POST /api/verse/authority AuthorityActionRequest\n * GET /api/verse/fleet/live FleetLiveSnapshotV1 (B-U5)\n * POST /api/verse/fleet/live FleetLiveActionRequest\n * GET /api/verse/leader LeaderStateV1 (B-U8)\n * POST /api/verse/leader LeaderActionRequest\n * GET /api/verse/learning LearningStateV1 (B-U9)\n * GET /api/verse/activity VerseActivityResponse (C1 — read through\n * the shell's ONE useActivity poll, never a\n * second loop from here)\n * GET /api/verse/fleet/history FleetHistoryResponse (A8)\n * GET /api/reasoning/digest ReasoningDigest (A7)\n * GET /api/verse/budget BudgetView (A9 — budget-queries.ts)\n * GET /api/verse/budget/history CapacityHistoryResponse (3.10.1 — recorded\n * seat window history for the burn-downs)\n * GET /api/models per-model ROI (data/queries.ts)\n *\n * WHY every read is OPTIONAL: Track B's modules land in parallel with these\n * surfaces (SPEC-310BC-COORD), and C0's mount answers 404 for a family that\n * has not landed. A 404 is \"this card has no source yet\", never \"Command is\n * broken\" — so a read resolves to `{ value: null, available: false, reason }`\n * and the card renders a designed not-available state from `reason`. A body\n * this client cannot narrow is treated the same way (available, but nothing\n * shown rather than guessed). 401 and aborts still propagate: an expired\n * read session is the whole app's state, not one card's.\n *\n * Writes pull the held mutation token (VerseControlLockedError without one —\n * the surfaces route every write through useGuardedAction, which opens the\n * token dialog first) and invalidate exactly the keys they change.\n */\nimport { ApiError, apiGet, apiPost } from '../../../data/client.js';\nimport { getMutationToken, touchMutationHold } from '../../../data/auth-store.js';\nimport { invalidate } from '../../../data/cache.js';\nimport type { QueryDef } from '../../../data/queries.js';\nimport { VerseControlLockedError } from '../autonomy/control-queries.js';\nimport { refreshActivity } from '../shell/useActivity.js';\nimport type { OptionalFleetRead } from '../autonomy/fleet-contract.js';\nimport type {\n AuthorityActionRequest,\n AuthorityGrantDraft,\n AuthorityStatusV1,\n} from '../../../../core/authority/types.js';\nimport type { FleetLiveActionRequest, FleetLiveSnapshotV1 } from '../../../../core/fleet/fleet-types.js';\nimport type { LeaderActionRequest, LeaderStateV1 } from '../../../../core/vision/leader-types.js';\nimport type { LearningStateV1 } from '../../../../core/learn/harness-types.js';\nimport type { VerseActivityResponse } from '../../../../core/verse/workbench-types.js';\nimport type { FleetHistoryResponse } from '../../../../core/verse/fleet-history-types.js';\nimport type { ReasoningDigest } from '../../../../core/reasoning/types.js';\nimport type { CapacityHistoryResponse } from '../../../../core/routing/capacity-history-types.js';\n\n/** A read that is allowed to be absent (the autonomy folder's shape, reused). */\nexport type OptionalRead<T> = OptionalFleetRead<T>;\n\nexport const AUTHORITY_PATH = '/api/verse/authority';\nexport const AUTHORITY_DRAFT_PATH = '/api/verse/authority/draft';\nexport const FLEET_LIVE_PATH = '/api/verse/fleet/live';\nexport const LEADER_PATH = '/api/verse/leader';\nexport const LEARNING_PATH = '/api/verse/learning';\nexport const FLEET_HISTORY_PATH = '/api/verse/fleet/history?days=90';\n\n/**\n * FLEET_HISTORY_PATH plus the viewer's zone (`tz`, Date#getTimezoneOffset\n * minutes, which the route accepts). Without it the server bucketed runs by\n * the UTC day (tz defaults to 0), so a Sep 25 evening's runs sat in a\n * \"Sep 26\" column west of UTC. Read at fetch time, so a DST change between\n * polls is picked up.\n */\nexport function fleetHistoryPath(now: Date = new Date()): string {\n return `${FLEET_HISTORY_PATH}&tz=${now.getTimezoneOffset()}`;\n}\nexport const REASONING_DIGEST_PATH = '/api/reasoning/digest?days=30';\n/** Eight days: the whole weekly window plus the day before it opened. */\nexport const SEAT_HISTORY_PATH = '/api/verse/budget/history?days=8';\n\nexport const SURFACE_KEYS = Object.freeze({\n authority: 'verse-authority',\n authorityDraft: 'verse-authority-draft',\n fleetLive: 'verse-fleet-live',\n leader: 'verse-leader',\n learning: 'verse-learning',\n fleetHistory: 'verse-fleet-history-90d',\n reasoningDigest: 'verse-reasoning-digest-30d',\n seatHistory: 'verse-seat-history-8d',\n});\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return value !== null && typeof value === 'object' && !Array.isArray(value);\n}\n\n/**\n * Structural guards: just enough to know the body is the contract's shape\n * (version tag + the arrays the cards iterate), so a mismatched server can\n * never crash a render with `undefined.map`. Field-level honesty (null =\n * unknown) is the cards' job.\n */\nexport const narrow = {\n authority(raw: unknown): AuthorityStatusV1 | null {\n return isRecord(raw) && raw['v'] === 1 && typeof raw['switch'] === 'string' && isRecord(raw['grant']) ? (raw as unknown as AuthorityStatusV1) : null;\n },\n draft(raw: unknown): AuthorityGrantDraft | null {\n return isRecord(raw) && isRecord(raw['payload']) && typeof raw['digest'] === 'string' ? (raw as unknown as AuthorityGrantDraft) : null;\n },\n fleetLive(raw: unknown): FleetLiveSnapshotV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['runs']) && Array.isArray(raw['repos']) && Array.isArray(raw['lanes']) && isRecord(raw['summary'])\n ? (raw as unknown as FleetLiveSnapshotV1)\n : null;\n },\n leader(raw: unknown): LeaderStateV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['timeline']) && Array.isArray(raw['actions']) && isRecord(raw['hitRate'])\n ? (raw as unknown as LeaderStateV1)\n : null;\n },\n learning(raw: unknown): LearningStateV1 | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['versions']) && Array.isArray(raw['experiments']) ? (raw as unknown as LearningStateV1) : null;\n },\n activity(raw: unknown): VerseActivityResponse | null {\n return isRecord(raw) && Array.isArray(raw['needsYou']) && Array.isArray(raw['running']) && isRecord(raw['sources']) ? (raw as unknown as VerseActivityResponse) : null;\n },\n fleetHistory(raw: unknown): FleetHistoryResponse | null {\n return isRecord(raw) && Array.isArray(raw['days']) && isRecord(raw['sources']) && isRecord(raw['funnel']) ? (raw as unknown as FleetHistoryResponse) : null;\n },\n reasoningDigest(raw: unknown): ReasoningDigest | null {\n return isRecord(raw) && Array.isArray(raw['insights']) && Array.isArray(raw['trends']) && isRecord(raw['totals']) ? (raw as unknown as ReasoningDigest) : null;\n },\n /** Series and points are re-checked one by one where they are merged (command-model mergeSeatHistory). */\n seatHistory(raw: unknown): CapacityHistoryResponse | null {\n return isRecord(raw) && raw['v'] === 1 && Array.isArray(raw['series']) ? (raw as unknown as CapacityHistoryResponse) : null;\n },\n};\n\n/** Operator words for a source that did not answer (never a path, never a trace). */\nfunction absence(what: string, err: unknown): string {\n if (err instanceof ApiError) {\n if (err.status === 404) return `${what} is not in this build yet, so this card has no source.`;\n if (err.status === 503) return `${what} failed to load on the server.`;\n // A refusal the route explained (409 with a sentence): say it, not the status.\n if (err.detail && err.status < 500) return /[.!?]$/.test(err.detail) ? err.detail : `${err.detail}.`;\n return `${what} answered HTTP ${err.status}.`;\n }\n return `${what} could not be reached.`;\n}\n\n/** A QueryDef whose value is an OptionalRead: 404 / unreachable / unrecognised all resolve, never throw. */\nexport function optionalQuery<T>(key: string, path: string | (() => string), what: string, guard: (raw: unknown) => T | null): QueryDef<OptionalRead<T>> {\n return {\n key,\n fetch: async (signal) => {\n try {\n const raw = await apiGet<unknown>(typeof path === 'function' ? path() : path, signal);\n const value = guard(raw);\n if (value === null) {\n // Nothing is shown rather than guessed from an unknown shape.\n return { value: null, available: true, reason: 'Unrecognized response — update Ashlr.' };\n }\n return { value, available: true, reason: null };\n } catch (err) {\n if (err instanceof ApiError && err.status === 401) throw err;\n if (err instanceof DOMException && err.name === 'AbortError') throw err;\n return { value: null, available: false, reason: absence(what, err), code: err instanceof ApiError ? err.code : null };\n }\n },\n };\n}\n\nexport const authorityQuery = optionalQuery(SURFACE_KEYS.authority, AUTHORITY_PATH, 'The authority service', narrow.authority);\nexport const authorityDraftQuery = optionalQuery(SURFACE_KEYS.authorityDraft, AUTHORITY_DRAFT_PATH, 'The grant draft', narrow.draft);\nexport const fleetLiveQuery = optionalQuery(SURFACE_KEYS.fleetLive, FLEET_LIVE_PATH, 'The live fleet view', narrow.fleetLive);\nexport const leaderQuery = optionalQuery(SURFACE_KEYS.leader, LEADER_PATH, 'The Leader', narrow.leader);\nexport const learningQuery = optionalQuery(SURFACE_KEYS.learning, LEARNING_PATH, 'Self-improvement', narrow.learning);\nexport const fleetHistoryQuery = optionalQuery(SURFACE_KEYS.fleetHistory, () => fleetHistoryPath(), 'Fleet history', narrow.fleetHistory);\nexport const reasoningDigestQuery = optionalQuery(SURFACE_KEYS.reasoningDigest, REASONING_DIGEST_PATH, 'The reasoning digest', narrow.reasoningDigest);\n/** Optional like every surface read: a server without the route leaves the burn-downs on this page's own readings. */\nexport const seatHistoryQuery = optionalQuery(SURFACE_KEYS.seatHistory, SEAT_HISTORY_PATH, 'Seat history', narrow.seatHistory);\n\n// ---------------------------------------------------------------------------\n// Writes\n// ---------------------------------------------------------------------------\n\nasync function post<T>(path: string, body: unknown): Promise<T> {\n const token = getMutationToken();\n if (!token) throw new VerseControlLockedError();\n const result = await apiPost<T>(path, body, token);\n touchMutationHold();\n return result;\n}\n\n/**\n * One authority action. The server answers the new AuthorityStatusV1 for\n * every form; raising past the grant is its 409 `grant-required` (the page\n * opens the Touch ID sheet BEFORE ever sending that, but the server is the\n * authority — a stale page gets the refusal, not a raise).\n */\nexport async function postAuthority(action: AuthorityActionRequest): Promise<AuthorityStatusV1 | null> {\n const result = await post<unknown>(AUTHORITY_PATH, action);\n invalidate(SURFACE_KEYS.authority);\n invalidate(SURFACE_KEYS.fleetLive);\n void refreshActivity();\n if (action.action === 'grant' || action.action === 're-approve') invalidate(SURFACE_KEYS.authorityDraft);\n return narrow.authority(result);\n}\n\nexport async function postFleetLive(action: FleetLiveActionRequest): Promise<unknown> {\n const result = await post<unknown>(FLEET_LIVE_PATH, action);\n invalidate(SURFACE_KEYS.fleetLive);\n void refreshActivity();\n return result;\n}\n\nexport async function postLeader(action: LeaderActionRequest): Promise<unknown> {\n const result = await post<unknown>(LEADER_PATH, action);\n invalidate(SURFACE_KEYS.leader);\n void refreshActivity();\n return result;\n}\n\n/**\n * A Needs-you item's own action. `path` was validated by the producer\n * (isNeedsYouItem → isSafeApiRoute) and is re-checked here: the mutation\n * token must never be aimed anywhere but this origin's /api/.\n */\nexport async function postNeedsYouAction(path: string, body: Record<string, unknown>): Promise<unknown> {\n if (!/^\\/api\\/[^\\s\\\\]*$/.test(path) || path.startsWith('//') || path.includes('..')) {\n throw new Error('That action points outside this app, so it was not sent.');\n }\n const result = await post<unknown>(path, body);\n void refreshActivity();\n invalidate(SURFACE_KEYS.fleetLive);\n invalidate(SURFACE_KEYS.leader);\n invalidate(SURFACE_KEYS.authority);\n return result;\n}\n"],"mappings":"gLA0DA,IAAa,EAAiB,uBACjB,EAAuB,6BACvB,EAAkB,wBAClB,EAAc,oBACd,EAAgB,sBAChB,EAAqB,mCASlC,SAAgB,EAAiB,EAAY,IAAI,KAAgB,CAC/D,MAAO,GAAG,EAAmB,MAAM,EAAI,kBAAkB,GAC3D,CACA,IAAa,EAAwB,gCAExB,EAAoB,mCAEpB,EAAe,OAAO,OAAO,CACxC,UAAW,kBACX,eAAgB,wBAChB,UAAW,mBACX,OAAQ,eACR,SAAU,iBACV,aAAc,0BACd,gBAAiB,6BACjB,YAAa,uBACf,CAAC,EAED,SAAS,EAAS,EAAk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{H as e}from"./global-CMNW_dqn.js";import{p as t}from"./queries-BTXWdZzU.js";import{E as n,S as r,T as i}from"./VerseConsoleApp-CWU6R3By.js";import{n as a,t as o}from"./budget-queries-D8QV5XtH.js";import{r as s}from"./cloud-queries-BPQQ5_pJ.js";import{a as c,i as l,o as u,p as d,r as f,s as p}from"./surface-data-Dj71tdD-.js";import{r as m}from"./overnight-queries-C4wOnFtE.js";import{a as h,o as g}from"./thread-data-DQB_g66d.js";var _={command:[f,c,u,p,l,a,s,g],fleet:[c,f,m,a,o],growth:[l,p,t(`30d`),f,c],mind:[u,g,h,d,r,n,f,c],chat:[r,i,n]},v=6e4;async function y(t,n={}){let r=n.ensure??e;for(let e of _[t]??[])try{if(n.beforeEach&&!await n.beforeEach())return;await r(e.key,()=>e.fetch(),v)}catch{}}export{v as PREFETCH_FRESH_MS,_ as SURFACE_PREFETCH,y as prefetchSurfaceData};
|
|
2
|
+
//# sourceMappingURL=surface-prefetch-B0WdJOJG.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"surface-prefetch-B0WdJOJG.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/shell/surface-prefetch.ts"],"sourcesContent":["/**\n * routes/verse/shell/surface-prefetch.ts — the reads each rail surface opens\n * with, so the shell can warm them while the operator is still reading chat\n * (shell/warmup.ts, once the operator is idle after first paint). A first\n * visit to Command, Fleet, Growth or Mind then paints from the cache instead\n * of a skeleton; the surface's own useQuery still refreshes whatever is older\n * than it accepts.\n *\n * LAZY ONLY. shell/warmup.ts loads this module with import(): these query\n * defs pull in the surfaces' data modules, none of which may cost chat\n * first-paint bytes (VerseApp.first-paint.test.ts pins it). The QueryDefs\n * themselves are the surfaces' own — same keys, same fetchers — so a warmed\n * entry IS the entry the surface reads.\n *\n * Keep each list in step with its surface's useQuery calls:\n * surface-prefetch.test.ts renders Command, Growth and Mind and fails when\n * they read something this table does not warm.\n */\nimport { ensureQuery } from '../../../data/cache.js';\nimport { modelsQuery, type QueryDef } from '../../../data/queries.js';\nimport { overnightQuery } from '../autonomy/overnight-queries.js';\nimport { budgetPreviewQuery, budgetQuery } from '../budget/budget-queries.js';\nimport { cloudQuery } from '../cloud/cloud-queries.js';\nimport {\n authorityQuery,\n fleetHistoryQuery,\n fleetLiveQuery,\n leaderQuery,\n learningQuery,\n reasoningDigestQuery,\n} from '../command/surface-data.js';\nimport { leaderDirectivesQuery, leaderThreadQuery } from '../leader/thread-data.js';\nimport { verseBootstrapQuery, verseSessionsQuery, verseWorkspacesQuery } from '../verse-queries.js';\nimport type { VerseSectionId } from '../verse-ui-store.js';\n\ntype AnyQuery = QueryDef<unknown>;\n\n/** What each rail surface reads the moment it mounts. */\nexport const SURFACE_PREFETCH: Readonly<Partial<Record<VerseSectionId, readonly AnyQuery[]>>> = {\n // No seat history: the burn-downs that drew it moved to Usage (audit 14);\n // Command's seat strip reads the budget and the rail's warm seat caches.\n // cloudQuery (3.11): the Cloud card's overview — without it a first visit\n // paints \"Reading the cloud lane…\" under the seat strip.\n // leaderThreadQuery: the Leader card's latest-message line (leader/LeaderLine).\n command: [authorityQuery, fleetLiveQuery, leaderQuery, learningQuery, fleetHistoryQuery, budgetQuery, cloudQuery, leaderThreadQuery],\n // authorityQuery + fleetLiveQuery on Fleet, Growth and Mind: the shared\n // \"Autonomy is off\" state (autonomy/AutonomyOffState) reads both.\n fleet: [fleetLiveQuery, authorityQuery, overnightQuery, budgetQuery, budgetPreviewQuery],\n growth: [fleetHistoryQuery, learningQuery, modelsQuery('30d'), authorityQuery, fleetLiveQuery],\n // The conversation (leader/LeaderConversation) reads the thread and the directives.\n mind: [leaderQuery, leaderThreadQuery, leaderDirectivesQuery, reasoningDigestQuery, verseBootstrapQuery, verseWorkspacesQuery, authorityQuery, fleetLiveQuery],\n chat: [verseBootstrapQuery, verseSessionsQuery, verseWorkspacesQuery],\n};\n\n/**\n * A cached answer younger than this is left alone. The surfaces accept 10–60 s\n * old data on mount, so anything fresher than a minute is already as good as\n * a warm-up can make it.\n */\nexport const PREFETCH_FRESH_MS = 60_000;\n\ntype Ensure = (key: string, fetcher: () => Promise<unknown>, maxAgeMs: number) => Promise<void>;\n\nexport interface PrefetchOptions {\n /** The cache's mount path (a seam for tests). */\n ensure?: Ensure;\n /**\n * Awaited before EACH read (the warm-up's idle gate). Resolving false stops\n * the warm-up there — the gate was cancelled.\n */\n beforeEach?: () => Promise<boolean> | boolean;\n}\n\n/**\n * Warm one surface's reads through the shared cache (joins an in-flight read,\n * skips a fresh one, and goes through the cache's concurrency gate).\n *\n * ONE AT A TIME: each read is awaited before the next is even considered, so\n * the warm-up never holds more than one of the gate's slots, and the operator\n * (who gets the other three, and whose reads the next `beforeEach` waits out)\n * is never queued behind a burst of it.\n *\n * Never rejects: a read that fails leaves the surface to load it as it always did.\n */\nexport async function prefetchSurfaceData(id: VerseSectionId, options: PrefetchOptions = {}): Promise<void> {\n const ensure = options.ensure ?? ensureQuery;\n for (const def of SURFACE_PREFETCH[id] ?? []) {\n try {\n if (options.beforeEach && !(await options.beforeEach())) return;\n await ensure(def.key, () => def.fetch(), PREFETCH_FRESH_MS);\n } catch {\n // A warm-up read that fails (or cannot even start) is not worth surfacing.\n }\n }\n}\n"],"mappings":"sbAsCA,IAAa,EAAmF,CAM9F,QAAS,CAAC,EAAgB,EAAgB,EAAa,EAAe,EAAmB,EAAa,EAAY,CAAiB,EAGnI,MAAO,CAAC,EAAgB,EAAgB,EAAgB,EAAa,CAAkB,EACvF,OAAQ,CAAC,EAAmB,EAAe,EAAY,KAAK,EAAG,EAAgB,CAAc,EAE7F,KAAM,CAAC,EAAa,EAAmB,EAAuB,EAAsB,EAAqB,EAAsB,EAAgB,CAAc,EAC7J,KAAM,CAAC,EAAqB,EAAoB,CAAoB,CACtE,EAOa,EAAoB,IAyBjC,eAAsB,EAAoB,EAAoB,EAA2B,CAAC,EAAkB,CAC1G,IAAM,EAAS,EAAQ,QAAU,EACjC,IAAK,IAAM,KAAO,EAAiB,IAAO,CAAC,EACzC,GAAI,CACF,GAAI,EAAQ,YAAc,CAAE,MAAM,EAAQ,WAAW,EAAI,OACzD,MAAM,EAAO,EAAI,QAAW,EAAI,MAAM,EAAG,CAAiB,CAC5D,MAAQ,CAER,CAEJ"}
|
package/dist/core/web/public/next/assets/{tasks-model-CzHvclVm.js → tasks-model-O8yR5YXp.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
2
|
-
//# sourceMappingURL=tasks-model-
|
|
1
|
+
import{T as e}from"./verse-model-DAVevkNe.js";import{n as t}from"./tool-semantics-GX8ScuSH.js";import{i as n}from"./sidebar-model-CLCdqwkR.js";function r(n){let r=0;for(let e=n.length-1;e>=0;--e)if(n[e].kind===`user`){r=e;break}let i=[],a=[];for(let o=r;o<n.length;o+=1){let r=n[o];if(r.kind!==`tool`)continue;let s={toolUseId:r.toolUseId,kind:t(r.name)===`task`?`subagent`:`tool`,name:r.name,detail:e(r.input)||r.name,startedAt:r.at,status:r.result===null?`running`:r.result.isError?`failed`:`done`,durationMs:r.durationMs};(s.status===`running`?i:a).push(s)}return[...i,...a.reverse()]}function i(e,t,r){let i=new Map;for(let e of t?.running??[])e.sessionId!==r&&i.set(e.sessionId,{sessionId:e.sessionId,title:e.title,engine:e.engine,startedAt:e.startedAt,live:n(e.live)});for(let t of e)t.id===r||t.status!==`running`||i.has(t.id)||i.set(t.id,{sessionId:t.id,title:t.title,engine:t.engine,startedAt:null,live:null});return[...i.values()]}function a(e,t){let n=e.filter(e=>e.status===`running`);return{turn:n.length,subagents:n.filter(e=>e.kind===`subagent`).length,chats:t.length,total:n.length+t.length}}function o(e){let t=`${e.total} running task${e.total===1?``:`s`}`,n=[];return e.turn>0&&n.push(`${e.turn} in this chat`),e.chats>0&&n.push(`${e.chats} other chat${e.chats===1?``:`s`}`),n.length>0?`${t}: ${n.join(`, `)}`:t}export{a as countTasks,r as currentTurnTasks,o as describeTaskCounts,i as otherRunningChats};
|
|
2
|
+
//# sourceMappingURL=tasks-model-O8yR5YXp.js.map
|
package/dist/core/web/public/next/assets/{tasks-model-CzHvclVm.js.map → tasks-model-O8yR5YXp.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tasks-model-
|
|
1
|
+
{"version":3,"file":"tasks-model-O8yR5YXp.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/chat/tasks-model.ts"],"sourcesContent":["/**\n * routes/verse/chat/tasks-model.ts — what is running right now, for the\n * \"◌ 3 running tasks\" chip and the dock's Tasks pane (SPEC-310C §2–§3, C2).\n *\n * Two kinds of task, because the operator is waiting on both:\n * - THIS TURN: the open chat's tool calls and subagents since its last ask\n * (a running `Task` is a subagent; everything else is a tool);\n * - OTHER CHATS: every other chat with a turn in flight, from activity\n * (C1) when it answers, else from the session list's `status`.\n *\n * Pure over transcript items and the session / activity lists.\n */\nimport type { VerseEngine, VerseSession } from '../../../data/api-types.js';\nimport type { VerseActivityResponse } from '../../../../core/verse/workbench-types.js';\nimport type { TranscriptItem } from '../verse-store.js';\nimport { summarizeToolInput } from '../verse-model.js';\nimport { liveLine } from './sidebar-model.js';\nimport { actionForName } from './tool-semantics.js';\n\nexport type TurnTaskStatus = 'running' | 'done' | 'failed';\n\nexport interface TurnTask {\n toolUseId: string;\n kind: 'subagent' | 'tool';\n /** Tool name as the CLI spelled it. */\n name: string;\n /** What it is doing: the command, the path, the subagent's description. */\n detail: string;\n /** ISO time the call started. */\n startedAt: string;\n status: TurnTaskStatus;\n durationMs: number | null;\n}\n\nexport interface ChatTask {\n sessionId: string;\n title: string;\n engine: VerseEngine;\n /** ISO start of the running turn when activity knows it; null = unknown. */\n startedAt: string | null;\n /** The muted \"what it is doing\" line; null when unknown. */\n live: string | null;\n}\n\n/** The last turn's tool calls, running first (in start order), then finished (newest first). */\nexport function currentTurnTasks(items: readonly TranscriptItem[]): TurnTask[] {\n let start = 0;\n for (let i = items.length - 1; i >= 0; i -= 1) {\n if (items[i]!.kind === 'user') {\n start = i;\n break;\n }\n }\n const running: TurnTask[] = [];\n const finished: TurnTask[] = [];\n for (let i = start; i < items.length; i += 1) {\n const item = items[i]!;\n if (item.kind !== 'tool') continue;\n const task: TurnTask = {\n toolUseId: item.toolUseId,\n kind: actionForName(item.name) === 'task' ? 'subagent' : 'tool',\n name: item.name,\n detail: summarizeToolInput(item.input) || item.name,\n startedAt: item.at,\n status: item.result === null ? 'running' : item.result.isError ? 'failed' : 'done',\n durationMs: item.durationMs,\n };\n (task.status === 'running' ? running : finished).push(task);\n }\n return [...running, ...finished.reverse()];\n}\n\nexport function otherRunningChats(\n sessions: readonly VerseSession[],\n activity: VerseActivityResponse | null,\n currentId: string | null,\n): ChatTask[] {\n const out = new Map<string, ChatTask>();\n for (const row of activity?.running ?? []) {\n if (row.sessionId === currentId) continue;\n out.set(row.sessionId, {\n sessionId: row.sessionId,\n title: row.title,\n engine: row.engine,\n startedAt: row.startedAt,\n live: liveLine(row.live),\n });\n }\n // The session list can know about a run activity has not reported (a\n // server without C1's route, or the few seconds between polls).\n for (const session of sessions) {\n if (session.id === currentId || session.status !== 'running' || out.has(session.id)) continue;\n out.set(session.id, { sessionId: session.id, title: session.title, engine: session.engine, startedAt: null, live: null });\n }\n return [...out.values()];\n}\n\nexport interface TaskCounts {\n /** Running calls in this turn. */\n turn: number;\n /** Of which subagents. */\n subagents: number;\n /** Other chats running. */\n chats: number;\n total: number;\n}\n\nexport function countTasks(turn: readonly TurnTask[], chats: readonly ChatTask[]): TaskCounts {\n const running = turn.filter((t) => t.status === 'running');\n return {\n turn: running.length,\n subagents: running.filter((t) => t.kind === 'subagent').length,\n chats: chats.length,\n total: running.length + chats.length,\n };\n}\n\n/** \"3 running tasks\" — and what they are, for the chip's accessible name. */\nexport function describeTaskCounts(counts: TaskCounts): string {\n const head = `${counts.total} running task${counts.total === 1 ? '' : 's'}`;\n const parts: string[] = [];\n if (counts.turn > 0) parts.push(`${counts.turn} in this chat`);\n if (counts.chats > 0) parts.push(`${counts.chats} other chat${counts.ch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Q,UAAW,KAAM,KAAM,IAAK,CAAC,EAE1H,MAAO,CAAC,GAAG,EAAI,OAAO,CAAC,CACzB,CAYA,SAAgB,EAAW,EAA2B,EAAwC,CAC5F,IAAM,EAAU,EAAK,OAAQ,GAAM,EAAE,SAAW,SAAS,EACzD,MAAO,CACL,KAAM,EAAQ,OACd,UAAW,EAAQ,OAAQ,GAAM,EAAE,OAAS,UAAU,CAAC,CAAC,OACxD,MAAO,EAAM,OACb,MAAO,EAAQ,OAAS,EAAM,MAChC,CACF,CAGA,SAAgB,EAAmB,EAA4B,CAC7D,IAAM,EAAO,GAAG,EAAO,MAAM,eAAe,EAAO,QAAU,EAAI,GAAK,MAChE,EAAkB,CAAC,EAGzB,OAFI,EAAO,KAAO,GAAG,EAAM,KAAK,GAAG,EAAO,KAAK,cAAc,EACzD,EAAO,MAAQ,GAAG,EAAM,KAAK,GAAG,EAAO,MAAM,aAAa,EAAO,QAAU,EAAI,GAAK,KAAK,EACtF,EAAM,OAAS,EAAI,GAAG,EAAK,IAAI,EAAM,KAAK,IAAI,IAAM,CAC7D"}
|
package/dist/core/web/public/next/assets/{terminal-icons-BwgQTQP0.js → terminal-icons-CoRZq9iO.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{n as e}from"./index-
|
|
2
|
-
//# sourceMappingURL=terminal-icons-
|
|
1
|
+
import{n as e}from"./index-DZ-UQ7v8.js";var t=e();function n({size:e=16,children:n,...r}){return(0,t.jsx)(`svg`,{width:e,height:e,viewBox:`0 0 16 16`,fill:`none`,stroke:`currentColor`,strokeWidth:1.5,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,focusable:`false`,...r,children:n})}function r(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`rect`,{x:`1.75`,y:`2.75`,width:`12.5`,height:`10.5`,rx:`1.5`}),(0,t.jsx)(`path`,{d:`m4.5 6.25 2 1.75-2 1.75M8.25 10h3`})]})}function i(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`rect`,{x:`1.75`,y:`2.75`,width:`12.5`,height:`10.5`,rx:`1.5`}),(0,t.jsx)(`path`,{d:`M1.75 5.75h12.5M4 4.25h.01M5.75 4.25h.01`})]})}function a(e){return(0,t.jsx)(n,{...e,children:(0,t.jsx)(`path`,{d:`m4.5 6.5 3.5 3.5 3.5-3.5`})})}function o(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`path`,{d:`M2.5 6v4h2.5l3.5 3V3L5 6H2.5Z`}),(0,t.jsx)(`path`,{d:`M11 5.5a3.5 3.5 0 0 1 0 5M12.75 3.75a6 6 0 0 1 0 8.5`})]})}function s(e){return(0,t.jsx)(n,{...e,children:(0,t.jsx)(`path`,{d:`M13 8H3.5M7.5 4 3.5 8l4 4`})})}function c(e){return(0,t.jsx)(n,{...e,children:(0,t.jsx)(`path`,{d:`M3 8h9.5M8.5 4l4 4-4 4`})})}function l(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`path`,{d:`M13 8a5 5 0 1 1-1.46-3.54`}),(0,t.jsx)(`path`,{d:`M13 2.75v2.5h-2.5`})]})}function u(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`rect`,{x:`1.75`,y:`2.75`,width:`12.5`,height:`8.5`,rx:`1.25`}),(0,t.jsx)(`path`,{d:`M6 13.75h4M8 11.25v2.5`})]})}function d(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`rect`,{x:`4.75`,y:`1.75`,width:`6.5`,height:`12.5`,rx:`1.5`}),(0,t.jsx)(`path`,{d:`M7.25 12h1.5`})]})}function f(e){return(0,t.jsx)(n,{...e,children:(0,t.jsx)(`path`,{d:`M5 3.5v9l7-4.5-7-4.5Z`})})}function p(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`path`,{d:`M9 1.75H4.25a1 1 0 0 0-1 1v10.5a1 1 0 0 0 1 1h7.5a1 1 0 0 0 1-1V5.5L9 1.75Z`}),(0,t.jsx)(`path`,{d:`M9 1.75V5.5h3.75`})]})}function m(e){return(0,t.jsxs)(n,{...e,children:[(0,t.jsx)(`rect`,{x:`2.25`,y:`2.25`,width:`11.5`,height:`4.5`,rx:`1`}),(0,t.jsx)(`rect`,{x:`2.25`,y:`9.25`,width:`11.5`,height:`4.5`,rx:`1`}),(0,t.jsx)(`path`,{d:`M4.75 4.5h.01M4.75 11.5h.01`})]})}export{p as a,i as c,m as d,r as f,u as i,l,c as n,d as o,a as r,f as s,s as t,o as u};
|
|
2
|
+
//# sourceMappingURL=terminal-icons-CoRZq9iO.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"terminal-icons-
|
|
1
|
+
{"version":3,"file":"terminal-icons-CoRZq9iO.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/dock/terminal/terminal-icons.tsx"],"sourcesContent":["/**\n * dock/terminal/terminal-icons.tsx — the Terminal / Preview panes' own 16px\n * glyphs (unit C4). Same grammar as components/primitives/icons.tsx (16-unit\n * box, 1.5 stroke, round caps, currentColor, decorative) so they sit beside\n * the shared set; kept here because the shared set is not this unit's file.\n */\nimport type { ReactNode, SVGProps } from 'react';\n\nexport interface GlyphProps extends Omit<SVGProps<SVGSVGElement>, 'children' | 'viewBox'> {\n size?: number;\n}\n\nfunction Glyph({ size = 16, children, ...rest }: GlyphProps & { children: ReactNode }) {\n return (\n <svg width={size} height={size} viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" strokeWidth={1.5}\n strokeLinecap=\"round\" strokeLinejoin=\"round\" aria-hidden=\"true\" focusable=\"false\" {...rest}>\n {children}\n </svg>\n );\n}\n\nexport function TerminalGlyph(p: GlyphProps) {\n return <Glyph {...p}><rect x=\"1.75\" y=\"2.75\" width=\"12.5\" height=\"10.5\" rx=\"1.5\" /><path d=\"m4.5 6.25 2 1.75-2 1.75M8.25 10h3\" /></Glyph>;\n}\n\nexport function PreviewGlyph(p: GlyphProps) {\n return <Glyph {...p}><rect x=\"1.75\" y=\"2.75\" width=\"12.5\" height=\"10.5\" rx=\"1.5\" /><path d=\"M1.75 5.75h12.5M4 4.25h.01M5.75 4.25h.01\" /></Glyph>;\n}\n\nexport function ChevronDownGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"m4.5 6.5 3.5 3.5 3.5-3.5\" /></Glyph>;\n}\n\n/** Screen-reader mode: a speaker with sound lines. */\nexport function ScreenReaderGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M2.5 6v4h2.5l3.5 3V3L5 6H2.5Z\" /><path d=\"M11 5.5a3.5 3.5 0 0 1 0 5M12.75 3.75a6 6 0 0 1 0 8.5\" /></Glyph>;\n}\n\nexport function ArrowLeftGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M13 8H3.5M7.5 4 3.5 8l4 4\" /></Glyph>;\n}\n\nexport function ArrowRightGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M3 8h9.5M8.5 4l4 4-4 4\" /></Glyph>;\n}\n\nexport function ReloadGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M13 8a5 5 0 1 1-1.46-3.54\" /><path d=\"M13 2.75v2.5h-2.5\" /></Glyph>;\n}\n\nexport function DesktopGlyph(p: GlyphProps) {\n return <Glyph {...p}><rect x=\"1.75\" y=\"2.75\" width=\"12.5\" height=\"8.5\" rx=\"1.25\" /><path d=\"M6 13.75h4M8 11.25v2.5\" /></Glyph>;\n}\n\nexport function PhoneGlyph(p: GlyphProps) {\n return <Glyph {...p}><rect x=\"4.75\" y=\"1.75\" width=\"6.5\" height=\"12.5\" rx=\"1.5\" /><path d=\"M7.25 12h1.5\" /></Glyph>;\n}\n\nexport function PlayGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M5 3.5v9l7-4.5-7-4.5Z\" /></Glyph>;\n}\n\nexport function FileGlyph(p: GlyphProps) {\n return <Glyph {...p}><path d=\"M9 1.75H4.25a1 1 0 0 0-1 1v10.5a1 1 0 0 0 1 1h7.5a1 1 0 0 0 1-1V5.5L9 1.75Z\" /><path d=\"M9 1.75V5.5h3.75\" /></Glyph>;\n}\n\nexport function ServerGlyph(p: GlyphProps) {\n return <Glyph {...p}><rect x=\"2.25\" y=\"2.25\" width=\"11.5\" height=\"4.5\" rx=\"1\" /><rect x=\"2.25\" y=\"9.25\" width=\"11.5\" height=\"4.5\" rx=\"1\" /><path d=\"M4.75 4.5h.01M4.75 11.5h.01\" /></Glyph>;\n}\n"],"mappings":"kDAYA,SAAS,EAAM,CAAE,OAAO,GAAI,WAAU,GAAG,GAA8C,CACrF,OACE,EAAA,EAAA,IAAA,CAAC,MAAD,CAAK,MAAO,EAAM,OAAQ,EAAM,QAAQ,YAAY,KAAK,OAAO,OAAO,eAAe,YAAa,IACjG,cAAc,QAAQ,eAAe,QAAQ,cAAY,OAAO,UAAU,QAAQ,GAAI,EACrF,UACE,CAAA,CAET,CAEA,SAAgB,EAAc,EAAe,CAC3C,OAAO,EAAA,EAAA,KAAA,CAAC,EAAD,CAAO,GAAI,EAAX,SAAA,EAAc,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,OAAO,EAAE,OAAO,MAAM,OAAO,OAAO,OAAO,GAAG,KAAO,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,mCAAqC,CAAA,CAAQ,GAC1I,CAEA,SAAgB,EAAa,EAAe,CAC1C,OAAO,EAAA,EAAA,KAAA,CAAC,EAAD,CAAO,GAAI,EAAX,SAAA,EAAc,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,OAAO,EAAE,OAAO,MAAM,OAAO,OAAO,OAAO,GAAG,KAAO,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,0CAA4C,CAAA,CAAQ,GACjJ,CAEA,SAAgB,EAAiB,EAAe,CAC9C,OAAO,EAAA,EAAA,IAAA,CAAC,EAAD,CAAO,GAAI,EAAG,UAAA,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,E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,CAAC,OAAD,CAAM,EAAE,OAAO,EAAE,OAAO,MAAM,MAAM,OAAO,OAAO,GAAG,KAAO,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,cAAgB,CAAA,CAAQ,GACpH,CAEA,SAAgB,EAAU,EAAe,CACvC,OAAO,EAAA,EAAA,IAAA,CAAC,EAAD,CAAO,GAAI,EAAG,UAAA,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,uBAAyB,CAAA,CAAQ,CAAA,CAChE,CAEA,SAAgB,EAAU,EAAe,CACvC,OAAO,EAAA,EAAA,KAAA,CAAC,EAAD,CAAO,GAAI,EAAX,SAAA,EAAc,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,6EAA+E,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,kBAAoB,CAAA,CAAQ,GACnJ,CAEA,SAAgB,EAAY,EAAe,CACzC,OAAO,EAAA,EAAA,KAAA,CAAC,EAAD,CAAO,GAAI,EAAX,SAAA,EAAc,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,OAAO,EAAE,OAAO,MAAM,OAAO,OAAO,MAAM,GAAG,GAAK,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,OAAO,EAAE,OAAO,MAAM,OAAO,OAAO,MAAM,GAAG,GAAK,CAAA,GAAC,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,EAAE,6BAA+B,CAAA,CAAQ,GAC5L"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{I as e,O as t,W as n,c as r,l as i,u as a}from"./global-CMNW_dqn.js";import{F as o}from"./VerseConsoleApp-CWU6R3By.js";import{n as s}from"./control-queries-B9K-wmcB.js";import{c,t as l}from"./surface-data-Dj71tdD-.js";import{a as u,i as d,n as f,o as p,r as m,s as h}from"./leader-thread-types-CDb-VPPO.js";function g(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var _=e=>typeof e==`string`&&e.length>0?e:null;function v(e){if(!g(e))return null;let{id:t,at:n,from:r,channel:i,kind:a,text:o}=e;if(typeof t!=`string`||t.length===0||typeof n!=`string`||!Number.isFinite(Date.parse(n))||r!==`mason`&&r!==`leader`||typeof o!=`string`)return null;let s={id:t,at:n,from:r,channel:f.includes(i)?i:`verse`,kind:m.includes(a)?a:`message`,text:o},c=_(e.replyTo),l=_(e.memoId),u=_(e.questionId);c&&(s.replyTo=c),l&&(s.memoId=l),u&&(s.questionId=u);let d=Array.isArray(e.actionIds)?e.actionIds.filter(e=>typeof e==`string`&&e.length>0):[];d.length&&(s.actionIds=d);let p=e.delivery;if(g(p)){let e=p.telegram;(e===`pending`||e===`sent`||e===`failed`)&&(s.delivery={telegram:e,..._(p.sentAt)?{sentAt:p.sentAt}:{}})}return s}function y(e){let t=Array.isArray(e)?e:g(e)&&Array.isArray(e.messages)?e.messages:null;return t?{messages:t.flatMap(e=>v(e)??[])}:null}function b(e){if(!g(e))return null;let{id:t,text:n}=e;if(typeof t!=`string`||t.length===0||typeof n!=`string`||n.trim().length===0||_(e.retiredAt)!==null)return null;let r=f.includes(e.channel)?e.channel:null;return{id:t,text:n.trim(),createdAt:_(e.createdAt),channel:r}}function x(e){let t=g(e)&&Array.isArray(e.directives)?e.directives:null;return t?t.flatMap(e=>b(e)??[]).sort((e,t)=>(Date.parse(e.createdAt??``)||0)-(Date.parse(t.createdAt??``)||0)):null}function S(e){if(!g(e))return null;let t=v(e.message);return t?{message:t,reply:v(e.reply),directive:b(e.directive)}:null}var C=12e4,w=e=>e.replace(/\s+/g,` `).trim();function T(e,t){return e.from!==`mason`||w(e.text)!==w(t.text)||t.kind===`answer`&&t.questionId&&e.questionId&&e.questionId!==t.questionId?!1:Date.parse(e.at)>=Date.parse(t.at)-C}var E=(e,t)=>Date.parse(e.at)-Date.parse(t.at)||0;function D(e,t=[],n=[]){let r=new Map;for(let e of t)r.set(e.id,e);for(let t of e)for(let e of t)r.set(e.id,e);let i=[...r.values()],a=new Set,o=[];for(let e of n){let t=e.state===`sending`?i.find(t=>!a.has(t.id)&&T(t,e)):void 0;t?a.add(t.id):o.push(e)}return[...i.map(e=>({type:`message`,key:e.id,at:e.at,message:e})),...o.map(e=>({type:`pending`,key:e.clientId,at:e.at,pending:e}))].map((e,t)=>({e,i:t})).sort((e,t)=>E(e.e,t.e)||e.i-t.i).map(({e})=>e)}function O(e){return e.type===`pending`?`mason`:e.message.from}function k(e){return e.type===`pending`?`verse`:e.message.channel}function A(e){return e.type===`message`&&(e.message.kind===`memo`||e.message.kind===`directive`)}function j(e){let t=new Date(e);return`${t.getFullYear()}-${t.getMonth()}-${t.getDate()}`}function M(e,t=Date.now()){let n=Date.parse(e);if(!Number.isFinite(n))return`—`;if(j(n)===j(t))return`Today`;if(j(n)===j(t-864e5))return`Yesterday`;let r=new Date(n),i=r.getFullYear()===new Date(t).getFullYear();return r.toLocaleDateString(`en-US`,{weekday:`short`,month:`short`,day:`numeric`,...i?{}:{year:`numeric`}})}function N(e,t=Date.now()){let n=[],r=null,i=null,a=0;for(let o of e){let e=Date.parse(o.at),s=j(e);if(s!==r&&(r=s,n.push({type:`day`,key:`day-${s}`,label:M(o.at,t)}),i=null),o.type===`message`&&o.message.channel===`system`){n.push({type:`system`,key:o.key,entry:o}),i=null;continue}let c=O(o),l=k(o);i!==null&&!A(o)&&!A(i.entries[i.entries.length-1])&&i.from===c&&i.channel===l&&e-a<=3e5&&i?i.entries.push(o):(i={type:`group`,key:`g-${o.key}`,from:c,channel:l,at:o.at,entries:[o]},n.push(i)),a=e}return n}function P(e){let t=e.filter(e=>e.kind===`question`),n=new Map;for(let r of e){if(r.from!==`mason`||r.kind!==`answer`&&!r.replyTo)continue;let e=t.find(e=>r.questionId&&e.questionId===r.questionId||r.replyTo&&e.id===r.replyTo);e&&!n.has(e.id)&&n.set(e.id,r)}return n}function F(e,t){return t.questionId?e.find(e=>e.kind===`question`&&e.questionId===t.questionId)??null:null}var I=18e4;function L(e,t,n=Date.now()){if(e.some(e=>e.type===`pending`&&e.pending.state===`sending`))return!0;for(let r=e.length-1;r>=0;--r){let i=e[r];if(i.type===`message`&&i.message.channel!==`system`){if(i.message.from===`leader`)return!1;if(t.has(i.message.id))return n-Date.parse(i.message.at)<I}}return!1}var R={verse:`Verse`,telegram:`Telegram`,cli:`CLI`,system:`System`};function z(e){let t=null;for(let n of e)n.from===`leader`&&n.channel!==`system`&&(!t||Date.parse(n.at)>=Date.parse(t.at))&&(t=n);return t}function B(e,t=140){let n=e.replace(/```[\s\S]*?(```|$)/g,` `).replace(/!?\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/^\s{0,3}(#{1,6}|>|[-*+]|\d+\.)\s+/gm,``).replace(/[*_`~]+/g,``).replace(/\s+/g,` `).trim();if(n.length<=t)return n;let r=n.slice(0,t-1),i=r.lastIndexOf(` `);return`${(i>t*.6?r.slice(0,i):r).replace(/[\s,.;:–—-]+$/,``)}…`}function V(e){let t=Date.parse(e);return Number.isFinite(t)?new Date(t).toLocaleTimeString(`en-US`,{hour:`numeric`,minute:`2-digit`}):``}var H=4e3,U=Object.freeze({thread:`verse-leader-thread`,directives:`verse-leader-directives`}),W=c(U.thread,`${h}?limit=50`,`The Leader conversation`,y),G=c(U.directives,u,`Leader directives`,x);async function K(e,t){return y(await i(`${h}?limit=50&before=${encodeURIComponent(e)}`,t))?.messages??[]}function q(e){return encodeURIComponent(e).replace(/%3A/gi,`:`)}function J(){let e=t();if(!e)throw new s;return e}async function Y(t,n){let r=await a(t,n,J());return e(),r}async function X(e,t=null){let r=S(await Y(h,t?{text:e,replyTo:t}:{text:e}));return r?.directive&&n(U.directives),r}async function Z(e,t){let n=S(await Y(`${p}/${q(e)}/answer`,{text:t}));return o(),n}async function Q(e){let t=await Y(`${d}/${q(e)}/approve`,{});return n(l.leader),n(U.thread),o(),t}async function $(e){let t=await Y(u,{text:e});return n(U.directives),n(U.thread),b(typeof t==`object`&&t&&`directive`in t?t.directive:t)}async function ee(t){await r(`${u}/${q(t)}`,J()),e(),n(U.directives),n(U.thread)}export{D as _,G as a,X as c,P as d,L as f,z as g,N as h,K as i,R as l,F as m,Z as n,W as o,V as p,Q as r,ee as s,$ as t,H as u,B as v};
|
|
2
|
+
//# sourceMappingURL=thread-data-DQB_g66d.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"thread-data-DQB_g66d.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/leader/thread-model.ts","../../../../../../src/web-ui/routes/verse/leader/thread-data.ts"],"sourcesContent":["/**\n * routes/verse/leader/thread-model.ts — pure helpers behind the Leader\n * conversation on Mind (and its one-line preview on Command).\n *\n * narrow* every body the page reads, checked field by field: a\n * message the page cannot read is dropped, never guessed;\n * mergeThread server pages + replies this tab already received + the\n * optimistic sends still in flight, in time order, each\n * message once (an optimistic send disappears as soon as its\n * server copy is in any of the lists);\n * groupThread day separators and runs of consecutive messages from one\n * sender on one channel (Linear-style: one header per run);\n * questions which question messages are answered, and which one a\n * Needs-you item means;\n * awaitingReply \"Leader is thinking…\" — honest: only for a message THIS\n * tab sent that the server said it would answer later.\n *\n * Framework-free; tested directly (thread-model.test.ts).\n */\nimport {\n LEADER_THREAD_CHANNELS,\n LEADER_THREAD_KINDS,\n type LeaderSendResult,\n type LeaderThreadChannel,\n type LeaderThreadKind,\n type LeaderThreadMessage,\n type LeaderThreadPage,\n type DirectiveChip,\n} from './thread-types.js';\n\n// ---------------------------------------------------------------------------\n// Narrowing\n// ---------------------------------------------------------------------------\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return value !== null && typeof value === 'object' && !Array.isArray(value);\n}\n\nconst optString = (v: unknown): string | null => (typeof v === 'string' && v.length > 0 ? v : null);\n\n/** One message, or null when a required field is missing or out of vocabulary. */\nexport function narrowMessage(raw: unknown): LeaderThreadMessage | null {\n if (!isRecord(raw)) return null;\n const { id, at, from, channel, kind, text } = raw;\n if (typeof id !== 'string' || id.length === 0) return null;\n if (typeof at !== 'string' || !Number.isFinite(Date.parse(at))) return null;\n if (from !== 'mason' && from !== 'leader') return null;\n if (typeof text !== 'string') return null;\n // An unknown channel or kind from a newer server still reads as a message.\n const ch = LEADER_THREAD_CHANNELS.includes(channel as LeaderThreadChannel) ? (channel as LeaderThreadChannel) : 'verse';\n const k = LEADER_THREAD_KINDS.includes(kind as LeaderThreadKind) ? (kind as LeaderThreadKind) : 'message';\n const out: LeaderThreadMessage = { id, at, from, channel: ch, kind: k, text };\n // Optional fields are present only when the server sent a usable value.\n const replyTo = optString(raw['replyTo']);\n const memoId = optString(raw['memoId']);\n const questionId = optString(raw['questionId']);\n if (replyTo) out.replyTo = replyTo;\n if (memoId) out.memoId = memoId;\n if (questionId) out.questionId = questionId;\n const actionIds = Array.isArray(raw['actionIds']) ? raw['actionIds'].filter((a): a is string => typeof a === 'string' && a.length > 0) : [];\n if (actionIds.length) out.actionIds = actionIds;\n const delivery = raw['delivery'];\n if (isRecord(delivery)) {\n const telegram = delivery['telegram'];\n if (telegram === 'pending' || telegram === 'sent' || telegram === 'failed') {\n out.delivery = { telegram, ...(optString(delivery['sentAt']) ? { sentAt: delivery['sentAt'] as string } : {}) };\n }\n }\n return out;\n}\n\n/** `{ messages: [...] }` (or a bare array); null when neither. Unreadable messages are dropped. */\nexport function narrowThreadPage(raw: unknown): LeaderThreadPage | null {\n const list = Array.isArray(raw) ? raw : isRecord(raw) && Array.isArray(raw['messages']) ? raw['messages'] : null;\n if (!list) return null;\n return { messages: list.flatMap((m) => narrowMessage(m) ?? []) };\n}\n\n/** An OperatorDirective in force, as a chip; null when unreadable or retired (`retiredAt` set). */\nexport function narrowDirective(raw: unknown): DirectiveChip | null {\n if (!isRecord(raw)) return null;\n const { id, text } = raw;\n if (typeof id !== 'string' || id.length === 0 || typeof text !== 'string' || text.trim().length === 0) return null;\n // A retired directive is history, not a chip.\n if (optString(raw['retiredAt']) !== null) return null;\n const channel = LEADER_THREAD_CHANNELS.includes(raw['channel'] as LeaderThreadChannel) ? (raw['channel'] as LeaderThreadChannel) : null;\n return { id, text: text.trim(), createdAt: optString(raw['createdAt']), channel };\n}\n\n/** GET /directives `{ directives, retired }` → the ones in force, oldest first (`retired` is history). */\nexport function narrowDirectives(raw: unknown): DirectiveChip[] | null {\n const list = isRecord(raw) && Array.isArray(raw['directives']) ? raw['directives'] : null;\n if (!list) return null;\n const out = list.flatMap((d) => narrowDirective(d) ?? []);\n return out.sort((a, b) => (Date.parse(a.createdAt ?? '') || 0) - (Date.parse(b.createdAt ?? '') || 0));\n}\n\nexport function narrowSendResult(raw: unknown): LeaderSendResult | null {\n if (!isRecord(raw)) return null;\n const message = narrowMessage(raw['message']);\n if (!message) return null;\n return { message, reply: narrowMessage(raw['reply']), directive: narrowDirective(raw['directive']) };\n}\n\n/**\n * POST /actions/<id>/approve → the approval's thread messages (Mason's\n * approval and the Leader's acknowledgement), readable ones only.\n */\nexport function narrowApprovalThread(raw: unknown): LeaderThreadMessage[] {\n if (!isRecord(raw) || !isRecord(raw['thread'])) return [];\n const t = raw['thread'];\n return [narrowMessage(t['message']), narrowMessage(t['reply'])].filter((m): m is LeaderThreadMessage => m !== null);\n}\n\n// ---------------------------------------------------------------------------\n// Optimistic sends and the merge\n// ---------------------------------------------------------------------------\n\nexport interface PendingMessage {\n /** Local id (\"local-3\"); never a server id. */\n clientId: string;\n kind: 'message' | 'answer';\n text: string;\n /** Local ISO time the send started. */\n at: string;\n replyTo: string | null;\n /** For an answer: the question it answers. */\n questionId: string | null;\n state: 'sending' | 'failed';\n /** Operator sentence for a failed send. */\n error: string | null;\n}\n\nexport type ThreadEntry =\n | { type: 'message'; key: string; at: string; message: LeaderThreadMessage }\n | { type: 'pending'; key: string; at: string; pending: PendingMessage };\n\n/**\n * A server message that is the delivered copy of an optimistic send: from\n * Mason, the same words, not older than the send (allowing CLOCK_SLACK_MS\n * for a server clock a little behind this tab's).\n */\nconst CLOCK_SLACK_MS = 2 * 60_000;\nconst norm = (t: string) => t.replace(/\\s+/g, ' ').trim();\n\nfunction isCopyOf(m: LeaderThreadMessage, p: PendingMessage): boolean {\n if (m.from !== 'mason') return false;\n if (norm(m.text) !== norm(p.text)) return false;\n if (p.kind === 'answer' && p.questionId && m.questionId && m.questionId !== p.questionId) return false;\n return Date.parse(m.at) >= Date.parse(p.at) - CLOCK_SLACK_MS;\n}\n\nconst byTime = (a: { at: string; key: string }, b: { at: string; key: string }) => Date.parse(a.at) - Date.parse(b.at) || 0;\n\n/**\n * Everything known, oldest first, each message once. `pages` are server\n * reads (newest page first or last — order does not matter); `received` are\n * messages this tab got back from a send (its own message and the reply)\n * before the next read; `pending` are sends still in flight or failed.\n */\nexport function mergeThread(\n pages: readonly (readonly LeaderThreadMessage[])[],\n received: readonly LeaderThreadMessage[] = [],\n pending: readonly PendingMessage[] = [],\n): ThreadEntry[] {\n const byId = new Map<string, LeaderThreadMessage>();\n // Server reads win over a send's echo: they are newer (a status may have moved).\n for (const m of received) byId.set(m.id, m);\n for (const page of pages) for (const m of page) byId.set(m.id, m);\n const messages = [...byId.values()];\n const claimed = new Set<string>();\n const live: PendingMessage[] = [];\n for (const p of pending) {\n // A failed send stays until retried or discarded: its words never arrived.\n const copy = p.state === 'sending' ? messages.find((m) => !claimed.has(m.id) && isCopyOf(m, p)) : undefined;\n if (copy) claimed.add(copy.id);\n else live.push(p);\n }\n // Stable: equal times keep server order, and pending sends sit after the messages of their instant.\n const entries: ThreadEntry[] = [\n ...messages.map((message) => ({ type: 'message' as const, key: message.id, at: message.at, message })),\n ...live.map((p) => ({ type: 'pending' as const, key: p.clientId, at: p.at, pending: p })),\n ];\n return entries.map((e, i) => ({ e, i })).sort((x, y) => byTime(x.e, y.e) || x.i - y.i).map(({ e }) => e);\n}\n\n// ---------------------------------------------------------------------------\n// Grouping\n// ---------------------------------------------------------------------------\n\nexport const GROUP_GAP_MS = 5 * 60_000;\n\nexport type ThreadRow =\n | { type: 'day'; key: string; label: string }\n | { type: 'group'; key: string; from: 'mason' | 'leader'; channel: LeaderThreadChannel; at: string; entries: ThreadEntry[] }\n /** A system line (a channel note, an update from `system`), centred and quiet. */\n | { type: 'system'; key: string; entry: ThreadEntry & { type: 'message' } };\n\nfunction entryFrom(e: ThreadEntry): 'mason' | 'leader' {\n return e.type === 'pending' ? 'mason' : e.message.from;\n}\nfunction entryChannel(e: ThreadEntry): LeaderThreadChannel {\n return e.type === 'pending' ? 'verse' : e.message.channel;\n}\n/** Memos and directives are cards and chips: each stands alone, never folded into a run. */\nfunction standsAlone(e: ThreadEntry): boolean {\n return e.type === 'message' && (e.message.kind === 'memo' || e.message.kind === 'directive');\n}\n\nfunction dayKey(t: number): string {\n const d = new Date(t);\n return `${d.getFullYear()}-${d.getMonth()}-${d.getDate()}`;\n}\n\n/** \"Today\", \"Yesterday\", \"Thu, Sep 24\" (local). */\nexport function dayLabel(iso: string, now: number = Date.now()): string {\n const t = Date.parse(iso);\n if (!Number.isFinite(t)) return '—';\n if (dayKey(t) === dayKey(now)) return 'Today';\n if (dayKey(t) === dayKey(now - 86_400_000)) return 'Yesterday';\n const d = new Date(t);\n const sameYear = d.getFullYear() === new Date(now).getFullYear();\n return d.toLocaleDateString('en-US', { weekday: 'short', month: 'short', day: 'numeric', ...(sameYear ? {} : { year: 'numeric' }) });\n}\n\nexport function groupThread(entries: readonly ThreadEntry[], now: number = Date.now()): ThreadRow[] {\n const rows: ThreadRow[] = [];\n let day: string | null = null;\n let run: Extract<ThreadRow, { type: 'group' }> | null = null;\n let lastAt = 0;\n for (const e of entries) {\n const t = Date.parse(e.at);\n const k = dayKey(t);\n if (k !== day) {\n day = k;\n rows.push({ type: 'day', key: `day-${k}`, label: dayLabel(e.at, now) });\n run = null;\n }\n if (e.type === 'message' && e.message.channel === 'system') {\n rows.push({ type: 'system', key: e.key, entry: e });\n run = null;\n continue;\n }\n const from = entryFrom(e);\n const channel = entryChannel(e);\n const joins = run !== null && !standsAlone(e) && !standsAlone(run.entries[run.entries.length - 1]!) && run.from === from && run.channel === channel && t - lastAt <= GROUP_GAP_MS;\n if (joins && run) run.entries.push(e);\n else {\n run = { type: 'group', key: `g-${e.key}`, from, channel, at: e.at, entries: [e] };\n rows.push(run);\n }\n lastAt = t;\n }\n return rows;\n}\n\n// ---------------------------------------------------------------------------\n// Questions\n// ---------------------------------------------------------------------------\n\n/** question message id → the answer that closed it. */\nexport function answeredQuestions(messages: readonly LeaderThreadMessage[]): Map<string, LeaderThreadMessage> {\n const questions = messages.filter((m) => m.kind === 'question');\n const out = new Map<string, LeaderThreadMessage>();\n for (const a of messages) {\n if (a.from !== 'mason' || (a.kind !== 'answer' && !a.replyTo)) continue;\n const q = questions.find((q) => (a.questionId && q.questionId === a.questionId) || (a.replyTo && q.id === a.replyTo));\n if (q && !out.has(q.id)) out.set(q.id, a);\n }\n return out;\n}\n\nexport interface QuestionTarget {\n /** The thread's questionId, `<memoId>:<index>` (question-id.ts derives it from a Needs-you item). */\n questionId: string | null;\n}\n\n/**\n * The question message a target means: the one whose questionId is exactly\n * the target's (the server keys both off `<memoId>:<index>`). Null when the\n * thread does not carry it — the caller then answers as a quoted message.\n */\nexport function findQuestion(messages: readonly LeaderThreadMessage[], target: QuestionTarget): LeaderThreadMessage | null {\n if (!target.questionId) return null;\n return messages.find((m) => m.kind === 'question' && m.questionId === target.questionId) ?? null;\n}\n\n// ---------------------------------------------------------------------------\n// Waiting, previews, words\n// ---------------------------------------------------------------------------\n\n/** How long \"Leader is thinking…\" may show for a send the server said it would answer later. */\nexport const AWAIT_REPLY_MS = 3 * 60_000;\n\n/**\n * True while a send is in flight, or while a message this tab sent (with no\n * inline reply) is still the newest thing Mason said and nothing from the\n * Leader has come after it — for at most AWAIT_REPLY_MS.\n */\nexport function awaitingReply(entries: readonly ThreadEntry[], awaiting: ReadonlySet<string>, now: number = Date.now()): boolean {\n if (entries.some((e) => e.type === 'pending' && e.pending.state === 'sending')) return true;\n for (let i = entries.length - 1; i >= 0; i -= 1) {\n const e = entries[i]!;\n if (e.type !== 'message' || e.message.channel === 'system') continue;\n if (e.message.from === 'leader') return false;\n if (awaiting.has(e.message.id)) return now - Date.parse(e.message.at) < AWAIT_REPLY_MS;\n }\n return false;\n}\n\nexport const CHANNEL_LABEL: Readonly<Record<LeaderThreadChannel, string>> = {\n verse: 'Verse',\n telegram: 'Telegram',\n cli: 'CLI',\n system: 'System',\n};\n\n/** The newest message from the Leader (Command's preview line). */\nexport function latestLeaderMessage(messages: readonly LeaderThreadMessage[]): LeaderThreadMessage | null {\n let best: LeaderThreadMessage | null = null;\n for (const m of messages) {\n if (m.from !== 'leader' || m.channel === 'system') continue;\n if (!best || Date.parse(m.at) >= Date.parse(best.at)) best = m;\n }\n return best;\n}\n\n/**\n * One line of plain text from a message that may be Markdown: fences, marks\n * and link targets dropped, whitespace collapsed, clipped on a word.\n */\nexport function previewText(text: string, max = 140): string {\n const plain = text\n .replace(/```[\\s\\S]*?(```|$)/g, ' ')\n .replace(/!?\\[([^\\]]*)\\]\\([^)]*\\)/g, '$1')\n .replace(/^\\s{0,3}(#{1,6}|>|[-*+]|\\d+\\.)\\s+/gm, '')\n .replace(/[*_`~]+/g, '')\n .replace(/\\s+/g, ' ')\n .trim();\n if (plain.length <= max) return plain;\n const cut = plain.slice(0, max - 1);\n const space = cut.lastIndexOf(' ');\n return `${(space > max * 0.6 ? cut.slice(0, space) : cut).replace(/[\\s,.;:–—-]+$/, '')}…`;\n}\n\n/** \"9:14 AM\" */\nexport function clockTime(iso: string): string {\n const t = Date.parse(iso);\n return Number.isFinite(t) ? new Date(t).toLocaleTimeString('en-US', { hour: 'numeric', minute: '2-digit' }) : '';\n}\n\n/** Longest message the composer sends (the server may cap lower and say so). */\nexport const LEADER_MESSAGE_MAX = 4_000;\n","/**\n * routes/verse/leader/thread-data.ts — every read and write behind the\n * Leader conversation (Mind) and its preview line (Command). Paths and\n * shapes: thread-types.ts.\n *\n * Reads are OPTIONAL reads (command/surface-data.ts optionalQuery): a server\n * without the conversation routes answers 404, which is \"not in this build\n * yet\" on the card — never a broken Mind. Writes pull the held mutation\n * token (VerseControlLockedError without one; the panel opens the token\n * dialog first) and invalidate exactly what they change.\n */\nimport { apiDelete, apiGet, apiPost } from '../../../data/client.js';\nimport { getMutationToken, touchMutationHold } from '../../../data/auth-store.js';\nimport { invalidate } from '../../../data/cache.js';\nimport { VerseControlLockedError } from '../autonomy/control-queries.js';\nimport { optionalQuery, SURFACE_KEYS } from '../command/surface-data.js';\nimport { refreshActivity } from '../shell/useActivity.js';\nimport { narrowDirective, narrowDirectives, narrowSendResult, narrowThreadPage } from './thread-model.js';\nimport {\n LEADER_ACTIONS_PATH,\n LEADER_DIRECTIVES_PATH,\n LEADER_QUESTIONS_PATH,\n LEADER_THREAD_PATH,\n type LeaderSendResult,\n type LeaderThreadMessage,\n type DirectiveChip,\n} from './thread-types.js';\n\n/** One page: enough for a day of conversation; older pages load on request. */\nexport const THREAD_PAGE_SIZE = 50;\n\nexport const LEADER_THREAD_KEYS = Object.freeze({\n thread: 'verse-leader-thread',\n directives: 'verse-leader-directives',\n});\n\nexport const leaderThreadQuery = optionalQuery(LEADER_THREAD_KEYS.thread, `${LEADER_THREAD_PATH}?limit=${THREAD_PAGE_SIZE}`, 'The Leader conversation', narrowThreadPage);\nexport const leaderDirectivesQuery = optionalQuery(LEADER_THREAD_KEYS.directives, LEADER_DIRECTIVES_PATH, 'Leader directives', narrowDirectives);\n\n/** The page before `beforeId` (the oldest message on screen). Throws like any read. */\nexport async function fetchOlderThread(beforeId: string, signal?: AbortSignal): Promise<LeaderThreadMessage[]> {\n const raw = await apiGet<unknown>(`${LEADER_THREAD_PATH}?limit=${THREAD_PAGE_SIZE}&before=${encodeURIComponent(beforeId)}`, signal);\n return narrowThreadPage(raw)?.messages ?? [];\n}\n\n/**\n * One path segment. The server matches ids on the RAW path (no decoding), so\n * a questionId's `:` (`<memoId>:<index>`) must go as-is — `:` is legal in a\n * path segment; anything else unusual is still escaped.\n */\nexport function pathSegment(id: string): string {\n return encodeURIComponent(id).replace(/%3A/gi, ':');\n}\n\nfunction token(): string {\n const t = getMutationToken();\n if (!t) throw new VerseControlLockedError();\n return t;\n}\n\nasync function post(path: string, body: unknown): Promise<unknown> {\n const result = await apiPost<unknown>(path, body, token());\n touchMutationHold();\n return result;\n}\n\n/**\n * A send the server accepted but answered in a shape this page cannot read\n * is still a send: the next read shows it. Null tells the caller \"refetch\".\n */\nexport async function sendLeaderMessage(text: string, replyTo: string | null = null): Promise<LeaderSendResult | null> {\n const result = narrowSendResult(await post(LEADER_THREAD_PATH, replyTo ? { text, replyTo } : { text }));\n if (result?.directive) invalidate(LEADER_THREAD_KEYS.directives);\n return result;\n}\n\nexport async function answerLeaderQuestion(questionId: string, text: string): Promise<LeaderSendResult | null> {\n const result = narrowSendResult(await post(`${LEADER_QUESTIONS_PATH}/${pathSegment(questionId)}/answer`, { text }));\n // The question's Needs-you row closes with its answer.\n void refreshActivity();\n return result;\n}\n\n/**\n * Approve a class-B action now (skip the window) or a class-C ask.\n * `{ ok, code, outcome, message, action, thread }`: a 409 (nothing to\n * approve, or refused now) throws with the server's `message` as its reason\n * (client.ts readRefusal); the approval and the Leader's acknowledgement\n * reach the conversation through the thread refetch.\n */\nexport async function approveLeaderAction(actionId: string): Promise<unknown> {\n const result = await post(`${LEADER_ACTIONS_PATH}/${pathSegment(actionId)}/approve`, {});\n invalidate(SURFACE_KEYS.leader);\n invalidate(LEADER_THREAD_KEYS.thread);\n void refreshActivity();\n return result;\n}\n\n/**\n * POST /directives → `{ directive, duplicate }` (201 new, 200 when the same\n * words are already in force — either way the chip is there after the refetch).\n */\nexport async function addLeaderDirective(text: string): Promise<DirectiveChip | null> {\n const raw = await post(LEADER_DIRECTIVES_PATH, { text });\n invalidate(LEADER_THREAD_KEYS.directives);\n invalidate(LEADER_THREAD_KEYS.thread);\n const record = raw !== null && typeof raw === 'object' && 'directive' in raw ? (raw as { directive: unknown }).directive : raw;\n return narrowDirective(record);\n}\n\n/** DELETE /directives/<id> → `{ directive }` (now retired). */\nexport async function retireLeaderDirective(id: string): Promise<void> {\n await apiDelete<unknown>(`${LEADER_DIRECTIVES_PATH}/${pathSegment(id)}`, token());\n touchMutationHold();\n invalidate(LEADER_THREAD_KEYS.directives);\n invalidate(LEADER_THREAD_KEYS.thread);\n}\n"],"mappings":"0TAkCA,SAAS,EAAS,EAAkD,CAClE,OAAyB,OAAO,GAAU,YAAnC,GAA+C,CAAC,MAAM,QAAQ,CAAK,CAC5E,CAEA,IAAM,EAAa,GAA+B,OAAO,GAAM,UAAY,EAAE,OAAS,EAAI,EAAI,KAG9F,SAAgB,EAAc,EAA0C,CACtE,GAAI,CAAC,EAAS,CAAG,EAAG,OAAO,KAC3B,GAAM,CAAE,KAAI,KAAI,OAAM,UAAS,OAAM,QAAS,EAI9C,GAHI,OAAO,GAAO,UAAY,EAAG,SAAW,GACxC,OAAO,GAAO,UAAY,CAAC,OAAO,SAAS,KAAK,MAAM,CAAE,CAAC,GACzD,IAAS,SAAW,IAAS,UAC7B,OAAO,GAAS,SAAU,OAAO,KAIrC,IAAM,EAA2B,CAAE,KAAI,KAAI,OAAM,QAFtC,EAAuB,SAAS,CAA8B,EAAK,EAAkC,QAElD,KADpD,EAAoB,SAAS,CAAwB,EAAK,EAA4B,UACzB,MAAK,EAEtE,EAAU,EAAU,EAAI,OAAU,EAClC,EAAS,EAAU,EAAI,MAAS,EAChC,EAAa,EAAU,EAAI,UAAa,EAC1C,IAAS,EAAI,QAAU,GACvB,IAAQ,EAAI,OAAS,GACrB,IAAY,EAAI,WAAa,GACjC,IAAM,EAAY,MAAM,QAAQ,EAAI,SAAY,EAAI,EAAI,UAAa,OAAQ,GAAmB,OAAO,GAAM,UAAY,EAAE,OAAS,CAAC,EAAI,CAAC,EACtI,EAAU,SAAQ,EAAI,UAAY,GACtC,IAAM,EAAW,EAAI,SACrB,GAAI,EAAS,CAAQ,EAAG,CACtB,IAAM,EAAW,EAAS,UACtB,IAAa,WAAa,IAAa,QAAU,IAAa,YAChE,EAAI,SAAW,CAAE,WAAU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CAAC,EAGlH,OADA,EAAqB,EACd,CACT,CASA,eAAsB,EAAoB,EAAoC,CAC5E,IAAM,EAAS,MAAM,EAAK,GAAG,EAAoB,GAAG,EAAY,CAAQ,EAAE,UAAW,CAAC,CAAC,EAIvF,OAHA,EAAW,EAAa,MAAM,EAC9B,EAAW,EAAmB,MAAM,EACpC,EAAqB,EACd,CACT,CAMA,eAAsB,EAAmB,EAA6C,CACpF,IAAM,EAAM,MAAM,EAAK,EAAwB,CAAE,MAAK,CAAC,EAIvD,OAHA,EAAW,EAAmB,UAAU,EACxC,EAAW,EAAmB,MAAM,EAE7B,EADwB,OAAO,GAAQ,UAA/B,GAA2C,cAAe,EAAO,EAA+B,UAAY,CAC9F,CAC/B,CAGA,eAAsB,GAAsB,EAA2B,CACrE,MAAM,EAAmB,GAAG,EAAuB,GAAG,EAAY,CAAE,IAAK,EAAM,CAAC,EAChF,EAAkB,EAClB,EAAW,EAAmB,UAAU,EACxC,EAAW,EAAmB,MAAM,CACtC"}
|
package/dist/core/web/public/next/assets/{usage-queries-pXxvy54x.js → usage-queries-AdjEyEtn.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
2
|
-
//# sourceMappingURL=usage-queries-
|
|
1
|
+
import{l as e,o as t}from"./global-CMNW_dqn.js";var n=`2.1.280`;function r(e){return typeof e==`object`&&e&&!Array.isArray(e)?e:null}function i(e,t){let n=e[t];return typeof n==`string`&&n.length>0?n:null}function a(e,t){let n=e[t];return typeof n==`number`&&Number.isFinite(n)?n:null}function o(e,t,n=!1){let r=e[t];return typeof r==`boolean`?r:n}function s(e){return Array.isArray(e)?e:[]}var c=/(launcher\.mjs|native-profiles|account-connections|console-startup|\/\.ashlr\b|Bearer\s|--token\b)/i;function l(e){if(typeof e!=`string`)return null;let t=e.trim();return t.length===0||t.length>200||c.test(t)||/[\r\n]/.test(t)?null:t}function u(e){return e===null?null:Math.max(0,Math.min(100,e))}function d(e){let t=r(e);if(!t)return null;let n=i(t,`id`)??i(t,`label`);if(n===null)return null;let s=r(t.nativeReport),c=o(t,`limitReached`)||o(t,`rateLimitReached`),l=t.measured;return{id:n,label:i(t,`label`),usedPercent:u(a(t,`usedPercent`)??a(t,`used_percent`)),resetsAt:i(t,`resetsAt`)??i(t,`resets_at`),resetDescription:(s?i(s,`resetDescription`):null)??i(t,`resetDescription`),limitReached:c,measured:typeof l==`boolean`?l:!c}}function f(e){let t=r(e);if(!t)return null;let n=i(t,`balance`),s=n===null?a(t,`balance`):Number.parseFloat(n);return{hasCredits:o(t,`hasCredits`)||o(t,`has_credits`),unlimited:o(t,`unlimited`),balance:n,balanceValue:typeof s==`number`&&Number.isFinite(s)?s:null}}var p=[`claude`,`codex`,`grok`];function m(e){let t=r(e);if(!t)return null;let n=i(t,`id`),a=i(t,`provider`);if(n===null||a===null||!p.includes(a))return null;let o=s(t.windows).map(d).filter(e=>e!==null),c=i(t,`state`),u=i(t,`authentication`),m=r(t.unsupported);return{id:n,label:i(t,`label`)??n,provider:a,state:c===`checking`||c===`observed`||c===`signed-out`||c===`unavailable`?c:`unavailable`,authentication:u===`signed-in`||u===`signed-out`?u:`unknown`,health:i(t,`health`),planType:i(t,`planType`)??i(t,`plan_type`),observedAt:i(t,`observedAt`),windows:o,binding:d(t.binding),credits:f(t.credits),reason:i(t,`reason`),unsupported:h(t,m),reconnectCommand:l(t.reconnectCommand),notes:s(t.notes).filter(e=>typeof e==`string`)}}function h(e,t){if(t)return{code:i(t,`code`)??`usage-version-unsupported`,pinnedVersion:i(t,`pinnedVersion`)??i(t,`version`)};let r=i(e,`reason`);return r===`usage-version-unsupported`?{code:r,pinnedVersion:n}:null}function g(e){let t=i(e,`collectorNote`);if(t)return t;let n=r(e.collector);return!n||i(n,`owner`)!==`another-collector`?null:i(n,`note`)??`Another collector process owns the quota-refresh lease, so these readings are read-only and may be staler than this server’s poll interval.`}function _(e){let t=r(e);if(!t)return null;let n=Array.isArray(t.accounts)?t.accounts:Array.isArray(e)?e:null;return n===null?null:{sampledAt:i(t,`sampledAt`),refreshing:o(t,`refreshing`),accounts:n.map(m).filter(e=>e!==null),collectorNote:g(t)}}function v(e){let t=r(e);if(!t)return null;let n=i(t,`day`);return n===null||!/^\d{4}-\d{2}-\d{2}$/.test(n)?null:{day:n,tokensIn:a(t,`tokensIn`)??0,tokensOut:a(t,`tokensOut`)??0,estCostUsd:a(t,`estCostUsd`)??0,sessions:a(t,`sessions`)??0,cacheRead:a(t,`cacheRead`),cacheWrite:a(t,`cacheWrite`),cacheHitRate:a(t,`cacheHitRate`)}}function y(e,t){let n=r(e),a=n?Array.isArray(n.byDay)?n.byDay:Array.isArray(n.days)?n.days:null:Array.isArray(e)?e:null;if(a===null)return null;let c=n?i(n,`window`):null;return{window:c===`7d`||c===`30d`?c:t,days:a.map(v).filter(e=>e!==null).sort((e,t)=>e.day.localeCompare(t.day)),generatedAt:n?i(n,`generatedAt`):null,estimated:!n||o(n,`estimated`,!0),caveats:n?s(n.caveats).filter(e=>typeof e==`string`):[]}}function b(e,t){let n=r(e);if(!n)return null;let s=i(n,`label`)??i(n,`id`)??i(n,`name`)??i(n,`model`);if(s===null)return null;let c=n.capabilities,l=i(n,`state`),d=n.supportsTools,f=a(n,`nativeContextLength`)??a(n,`nativeContext`),p=a(n,`contextLength`)??a(n,`configuredContext`),m=i(n,`placement`);return{name:s,runtime:t,loaded:l===null?o(n,`loaded`)||o(n,`resident`):l===`loaded`,sizeBytes:a(n,`sizeBytes`)??a(n,`size`),sizeVramBytes:a(n,`sizeVramBytes`)??a(n,`size_vram`),placement:m===`gpu`||m===`cpu`||m===`split`?m:`unknown`,gpuPercent:u(a(n,`gpuPercent`)),memoryPercent:u(a(n,`memoryPercent`)),family:i(n,`family`),arch:i(n,`arch`),expiresAt:i(n,`expiresAt`)??i(n,`expires_at`),parameterSize:i(n,`parameterSize`)??i(n,`parameter_size`),quantization:i(n,`quantization`)??i(n,`quantization_level`),nativeContext:f,configuredContext:p!==null&&f!==null&&p===f?null:p,capabilities:Array.isArray(c)?c.filter(e=>typeof e==`string`):null,supportsTools:typeof d==`boolean`?d:null}}function x(e,t){let n=r(e);if(!n)return null;let s=Array.isArray(n.models)?n.models:null;if(s===null)return null;let c=s.map(e=>b(e,t)).filter(e=>e!==null),l=o(n,`stale`);return{models:c,status:{runtime:t,reachable:o(n,`reachable`),reason:i(n,`reason`),stale:l,staleForMs:l?a(n,`staleForMs`):null,modelCount:c.length}}}function S(e){let t=r(e);if(!t)return null;let n=x(t.ollama,`ollama`),c=x(t.lmStudio??t.lmstudio,`lmstudio`);if(n!==null||c!==null){let e=[n,c].filter(e=>e!==null),o=e.some(e=>e.status.reachable),l=r(t.machine);return{reachable:o,models:e.flatMap(e=>e.models),memoryBudgetBytes:(l?a(l,`totalMemoryBytes`):null)??a(t,`memoryBudgetBytes`)??a(t,`memoryBudget`),freeMemoryBytes:l?a(l,`freeMemoryBytes`):null,reason:o?null:e.map(e=>e.status.reason).find(e=>e!==null)??null,runtimes:e.map(e=>e.status),notes:s(t.notes).filter(e=>typeof e==`string`),sampledAt:i(t,`sampledAt`)}}let l=Array.isArray(t.models)?t.models:null;return l===null?null:{reachable:o(t,`reachable`,!0),models:l.map(e=>b(e,null)).filter(e=>e!==null),memoryBudgetBytes:a(t,`memoryBudgetBytes`)??a(t,`memoryBudget`),freeMemoryBytes:a(t,`freeMemoryBytes`),reason:i(t,`reason`),runtimes:[],notes:s(t.notes).filter(e=>typeof e==`string`),sampledAt:i(t,`sampledAt`)}}var C=`verse-usage-frontier`,w=`verse-usage-control`,T={key:C,fetch:t=>e(`/api/usage`,t)};function E(e){return e instanceof t?e.status===404?`This server does not expose /api/verse/control, so configured caps and today’s spend are unavailable here.`:`Configured caps unavailable (HTTP ${e.status}).`:`Configured caps unavailable: the request failed.`}var D={key:w,fetch:async n=>{try{return{raw:await e(`/api/verse/control`,n),available:!0,reason:null}}catch(e){if(e instanceof t&&e.status===401||e instanceof DOMException&&e.name===`AbortError`)throw e;return{raw:null,available:!1,reason:E(e)}}}},O=`verse-usage-accounts`,k=`verse-usage-local-models`,A=`verse-usage-series`;function j(e,n){return n instanceof t?n.status===404?`This server does not expose ${e} yet, so this panel has no source.`:`${e} answered HTTP ${n.status}.`:`${e} could not be reached.`}function M(n){return async r=>{try{return{raw:await e(n,r),available:!0,reason:null}}catch(e){if(e instanceof t&&e.status===401||e instanceof DOMException&&e.name===`AbortError`)throw e;return{raw:null,available:!1,reason:j(n,e)}}}}var N={key:O,fetch:M(`/api/verse/accounts`)},P=[350,1200],F=M(`/api/verse/local-models`);function I(e){if(!e.available)return!1;let t=S(e.raw);return t!==null&&!t.reachable}function L(e,t){return new Promise((n,r)=>{if(t?.aborted){r(new DOMException(`Aborted`,`AbortError`));return}let i=()=>{clearTimeout(a),r(new DOMException(`Aborted`,`AbortError`))},a=setTimeout(()=>{t?.removeEventListener(`abort`,i),n()},e);t?.addEventListener(`abort`,i,{once:!0})})}var R={key:k,fetch:async e=>{let t=await F(e);for(let n of P){if(!I(t))return t;await L(n,e),t=await F(e)}return t}},z={"7d":{key:`${A}:7d`,fetch:M(`/api/verse/usage-series?window=7d`)},"30d":{key:`${A}:30d`,fetch:M(`/api/verse/usage-series?window=30d`)}};function B(e){return z[e]}export{R as a,y as c,D as i,B as n,_ as o,N as r,S as s,T as t};
|
|
2
|
+
//# sourceMappingURL=usage-queries-AdjEyEtn.js.map
|