@songsid/agend 2.4.0-beta.26 → 2.4.0-beta.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent-cli-instructions.md +2 -1
- package/dist/agent-cli.js +6 -0
- package/dist/agent-cli.js.map +1 -1
- package/dist/agent-endpoint.d.ts +1 -0
- package/dist/agent-endpoint.js +5 -0
- package/dist/agent-endpoint.js.map +1 -1
- package/dist/agent-whats-new.js +4 -0
- package/dist/agent-whats-new.js.map +1 -1
- package/dist/backend/kiro-auth-store.d.ts +15 -2
- package/dist/backend/kiro-auth-store.js +64 -0
- package/dist/backend/kiro-auth-store.js.map +1 -1
- package/dist/build-provenance.json +1 -1
- package/dist/channel/adapters/discord.js +4 -4
- package/dist/channel/adapters/discord.js.map +1 -1
- package/dist/channel/adapters/telegram.js +3 -3
- package/dist/channel/adapters/telegram.js.map +1 -1
- package/dist/channel/ipc-bridge.d.ts +7 -0
- package/dist/channel/ipc-bridge.js +45 -11
- package/dist/channel/ipc-bridge.js.map +1 -1
- package/dist/channel/mcp-server.js +3 -1
- package/dist/channel/mcp-server.js.map +1 -1
- package/dist/channel/mcp-tools.js +6 -4
- package/dist/channel/mcp-tools.js.map +1 -1
- package/dist/claude-turn-boundaries.d.ts +15 -0
- package/dist/claude-turn-boundaries.js +88 -0
- package/dist/claude-turn-boundaries.js.map +1 -0
- package/dist/cli.js +35 -2
- package/dist/cli.js.map +1 -1
- package/dist/contact-auth-service.js +3 -0
- package/dist/contact-auth-service.js.map +1 -1
- package/dist/contact-auth-store.d.ts +16 -0
- package/dist/contact-auth-store.js +61 -1
- package/dist/contact-auth-store.js.map +1 -1
- package/dist/daemon.d.ts +76 -4
- package/dist/daemon.js +621 -115
- package/dist/daemon.js.map +1 -1
- package/dist/delivery-outbox.d.ts +145 -7
- package/dist/delivery-outbox.js +373 -8
- package/dist/delivery-outbox.js.map +1 -1
- package/dist/detached-fleet-stop.d.ts +40 -0
- package/dist/detached-fleet-stop.js +126 -0
- package/dist/detached-fleet-stop.js.map +1 -0
- package/dist/fleet-lock.d.ts +5 -0
- package/dist/fleet-lock.js +21 -2
- package/dist/fleet-lock.js.map +1 -1
- package/dist/fleet-manager.d.ts +499 -5
- package/dist/fleet-manager.js +2917 -217
- package/dist/fleet-manager.js.map +1 -1
- package/dist/fleet-windows-runtime.d.ts +39 -3
- package/dist/fleet-windows-runtime.js +208 -30
- package/dist/fleet-windows-runtime.js.map +1 -1
- package/dist/general-knowledge/skills/concepts/SKILL.md +5 -0
- package/dist/general-knowledge/skills/hub/SKILL.md +5 -1
- package/dist/general-knowledge/skills/task-board/SKILL.md +14 -0
- package/dist/general-knowledge/skills/web-dashboard/SKILL.md +96 -26
- package/dist/hub/admin-dashboard.js +1 -1
- package/dist/hub/admin-dashboard.js.map +1 -1
- package/dist/hub/agent-catalog.d.ts +1 -1
- package/dist/hub/agent-catalog.js +4 -3
- package/dist/hub/agent-catalog.js.map +1 -1
- package/dist/hub/agent-intro.d.ts +1 -1
- package/dist/hub/agent-intro.js +1 -1
- package/dist/hub/agent-intro.js.map +1 -1
- package/dist/hub/agent-pictures.d.ts +1 -1
- package/dist/hub/agent-pictures.js +4 -3
- package/dist/hub/agent-pictures.js.map +1 -1
- package/dist/hub/catalog.d.ts +2 -2
- package/dist/hub/catalog.js +16 -13
- package/dist/hub/catalog.js.map +1 -1
- package/dist/hub/client.js +9 -2
- package/dist/hub/client.js.map +1 -1
- package/dist/hub/compose/member.js +8 -1
- package/dist/hub/compose/member.js.map +1 -1
- package/dist/hub/compose/server.js +4 -2
- package/dist/hub/compose/server.js.map +1 -1
- package/dist/hub/fleet-updates.d.ts +2 -2
- package/dist/hub/fleet-updates.js +7 -5
- package/dist/hub/fleet-updates.js.map +1 -1
- package/dist/hub/fleet-versions.d.ts +1 -1
- package/dist/hub/fleet-versions.js +3 -2
- package/dist/hub/fleet-versions.js.map +1 -1
- package/dist/hub/http/compose.js +57 -30
- package/dist/hub/http/compose.js.map +1 -1
- package/dist/hub/http/schema.js +4 -1
- package/dist/hub/http/schema.js.map +1 -1
- package/dist/hub/join/service.d.ts +6 -0
- package/dist/hub/join/service.js +10 -0
- package/dist/hub/join/service.js.map +1 -1
- package/dist/hub/member/room-ask.js +2 -0
- package/dist/hub/member/room-ask.js.map +1 -1
- package/dist/hub/member/room-post.d.ts +4 -0
- package/dist/hub/member/room-post.js +26 -1
- package/dist/hub/member/room-post.js.map +1 -1
- package/dist/hub/protocol.d.ts +58 -0
- package/dist/hub/protocol.js +3 -2
- package/dist/hub/protocol.js.map +1 -1
- package/dist/hub/quota.d.ts +2 -2
- package/dist/hub/quota.js +6 -4
- package/dist/hub/quota.js.map +1 -1
- package/dist/hub/read-statement.d.ts +6 -0
- package/dist/hub/read-statement.js +33 -0
- package/dist/hub/read-statement.js.map +1 -0
- package/dist/hub/recommendations.d.ts +1 -1
- package/dist/hub/recommendations.js +3 -2
- package/dist/hub/recommendations.js.map +1 -1
- package/dist/hub/representative.d.ts +2 -0
- package/dist/hub/representative.js +8 -4
- package/dist/hub/representative.js.map +1 -1
- package/dist/hub/roles/clock.d.ts +1 -1
- package/dist/hub/roles/clock.js +9 -7
- package/dist/hub/roles/clock.js.map +1 -1
- package/dist/hub/roles/read.d.ts +4 -0
- package/dist/hub/roles/read.js +37 -7
- package/dist/hub/roles/read.js.map +1 -1
- package/dist/hub/room-history-model.d.ts +87 -0
- package/dist/hub/room-history-model.js +14 -0
- package/dist/hub/room-history-model.js.map +1 -0
- package/dist/hub/rooms/agents.d.ts +1 -1
- package/dist/hub/rooms/agents.js +3 -2
- package/dist/hub/rooms/agents.js.map +1 -1
- package/dist/hub/rooms/history.d.ts +8 -0
- package/dist/hub/rooms/history.js +31 -0
- package/dist/hub/rooms/history.js.map +1 -0
- package/dist/hub/rooms/schema.d.ts +2 -0
- package/dist/hub/rooms/schema.js +4 -0
- package/dist/hub/rooms/schema.js.map +1 -1
- package/dist/hub/rooms/service.d.ts +35 -19
- package/dist/hub/rooms/service.js +105 -26
- package/dist/hub/rooms/service.js.map +1 -1
- package/dist/hub/server.js +10 -3
- package/dist/hub/server.js.map +1 -1
- package/dist/hub/session-epoch.js +2 -1
- package/dist/hub/session-epoch.js.map +1 -1
- package/dist/hub/settings-directory-decision.js +14 -7
- package/dist/hub/settings-directory-decision.js.map +1 -1
- package/dist/hub/settings-member-address-decision.js +3 -2
- package/dist/hub/settings-member-address-decision.js.map +1 -1
- package/dist/hub/settings-web-address-decision.js +2 -1
- package/dist/hub/settings-web-address-decision.js.map +1 -1
- package/dist/hub/store.d.ts +5 -0
- package/dist/hub/store.js +28 -5
- package/dist/hub/store.js.map +1 -1
- package/dist/hub/types.d.ts +2 -2
- package/dist/hub-agent-incarnation-record.d.ts +24 -0
- package/dist/hub-agent-incarnation-record.js +46 -0
- package/dist/hub-agent-incarnation-record.js.map +1 -0
- package/dist/human-delivery-receipts.d.ts +16 -4
- package/dist/human-delivery-receipts.js +26 -5
- package/dist/human-delivery-receipts.js.map +1 -1
- package/dist/instance-lifecycle.d.ts +9 -3
- package/dist/instance-lifecycle.js +27 -10
- package/dist/instance-lifecycle.js.map +1 -1
- package/dist/instructions.d.ts +1 -1
- package/dist/local-pane-endpoint.d.ts +14 -0
- package/dist/local-pane-endpoint.js +32 -0
- package/dist/local-pane-endpoint.js.map +1 -1
- package/dist/locale.js +68 -4
- package/dist/locale.js.map +1 -1
- package/dist/native-agent-admission.js +9 -0
- package/dist/native-agent-admission.js.map +1 -1
- package/dist/native-exec-context.d.ts +11 -0
- package/dist/native-exec-context.js +18 -0
- package/dist/native-exec-context.js.map +1 -0
- package/dist/native-exec-input.d.ts +56 -0
- package/dist/native-exec-input.js +89 -0
- package/dist/native-exec-input.js.map +1 -0
- package/dist/native-mcp.d.ts +9 -1
- package/dist/native-mcp.js +29 -7
- package/dist/native-mcp.js.map +1 -1
- package/dist/native-pane-lifecycle.d.ts +3 -0
- package/dist/native-pane-lifecycle.js +2 -0
- package/dist/native-pane-lifecycle.js.map +1 -1
- package/dist/native-pane-manager.d.ts +18 -0
- package/dist/native-pane-manager.js +85 -8
- package/dist/native-pane-manager.js.map +1 -1
- package/dist/needs-you.d.ts +2 -1
- package/dist/needs-you.js.map +1 -1
- package/dist/outbound-handlers.d.ts +1 -0
- package/dist/outbound-handlers.js +9 -3
- package/dist/outbound-handlers.js.map +1 -1
- package/dist/outbound-schemas.d.ts +8 -0
- package/dist/outbound-schemas.js +6 -2
- package/dist/outbound-schemas.js.map +1 -1
- package/dist/public-web-gateway.js +3 -1
- package/dist/public-web-gateway.js.map +1 -1
- package/dist/recover.cjs +1 -0
- package/dist/reply-buttons-controller.d.ts +1 -0
- package/dist/reply-buttons-controller.js +1 -1
- package/dist/reply-buttons-controller.js.map +1 -1
- package/dist/request-contact-gate.d.ts +2 -0
- package/dist/request-contact-gate.js +8 -3
- package/dist/request-contact-gate.js.map +1 -1
- package/dist/request-context-activation.d.ts +29 -0
- package/dist/request-context-activation.js +85 -0
- package/dist/request-context-activation.js.map +1 -0
- package/dist/request-context-admission.d.ts +22 -0
- package/dist/request-context-admission.js +12 -0
- package/dist/request-context-admission.js.map +1 -0
- package/dist/request-context-boot.d.ts +35 -0
- package/dist/request-context-boot.js +97 -0
- package/dist/request-context-boot.js.map +1 -0
- package/dist/request-context-call.d.ts +3 -0
- package/dist/request-context-call.js.map +1 -1
- package/dist/request-context-compatibility.js +10 -2
- package/dist/request-context-compatibility.js.map +1 -1
- package/dist/request-context-continuation.d.ts +6 -0
- package/dist/request-context-continuation.js +24 -0
- package/dist/request-context-continuation.js.map +1 -0
- package/dist/request-context-control-api.d.ts +119 -0
- package/dist/request-context-control-api.js +179 -0
- package/dist/request-context-control-api.js.map +1 -0
- package/dist/request-context-control-copy.d.ts +3 -0
- package/dist/request-context-control-copy.js +7 -0
- package/dist/request-context-control-copy.js.map +1 -0
- package/dist/request-context-controller.d.ts +44 -0
- package/dist/request-context-controller.js +129 -0
- package/dist/request-context-controller.js.map +1 -0
- package/dist/request-context-delivery-resolver.d.ts +13 -0
- package/dist/request-context-delivery-resolver.js +30 -0
- package/dist/request-context-delivery-resolver.js.map +1 -0
- package/dist/request-context-drain-projection.d.ts +8 -0
- package/dist/request-context-drain-projection.js +40 -0
- package/dist/request-context-drain-projection.js.map +1 -0
- package/dist/request-context-drain.d.ts +22 -0
- package/dist/request-context-drain.js +139 -7
- package/dist/request-context-drain.js.map +1 -1
- package/dist/request-context-enable-offer.d.ts +13 -0
- package/dist/request-context-enable-offer.js +31 -0
- package/dist/request-context-enable-offer.js.map +1 -0
- package/dist/request-context-exec-owner.d.ts +39 -0
- package/dist/request-context-exec-owner.js +128 -0
- package/dist/request-context-exec-owner.js.map +1 -0
- package/dist/request-context-go-back-view.d.ts +1 -0
- package/dist/request-context-go-back-view.js +17 -0
- package/dist/request-context-go-back-view.js.map +1 -0
- package/dist/request-context-helper-readiness.d.ts +14 -0
- package/dist/request-context-helper-readiness.js +23 -0
- package/dist/request-context-helper-readiness.js.map +1 -0
- package/dist/request-context-helper.d.ts +20 -0
- package/dist/request-context-helper.js +41 -0
- package/dist/request-context-helper.js.map +1 -0
- package/dist/request-context-hub-resolver.d.ts +29 -0
- package/dist/request-context-hub-resolver.js +90 -0
- package/dist/request-context-hub-resolver.js.map +1 -0
- package/dist/request-context-human-resolver.d.ts +20 -0
- package/dist/request-context-human-resolver.js +77 -0
- package/dist/request-context-human-resolver.js.map +1 -0
- package/dist/request-context-human.d.ts +112 -0
- package/dist/request-context-human.js +176 -0
- package/dist/request-context-human.js.map +1 -0
- package/dist/request-context-inputs.d.ts +21 -0
- package/dist/request-context-inputs.js +63 -0
- package/dist/request-context-inputs.js.map +1 -0
- package/dist/request-context-installation.d.ts +117 -0
- package/dist/request-context-installation.js +328 -0
- package/dist/request-context-installation.js.map +1 -0
- package/dist/request-context-knowledge.d.ts +5 -0
- package/dist/request-context-knowledge.js +32 -0
- package/dist/request-context-knowledge.js.map +1 -0
- package/dist/request-context-migration.d.ts +11 -0
- package/dist/request-context-migration.js +16 -3
- package/dist/request-context-migration.js.map +1 -1
- package/dist/request-context-native-human.d.ts +20 -0
- package/dist/request-context-native-human.js +91 -0
- package/dist/request-context-native-human.js.map +1 -0
- package/dist/request-context-native-output.d.ts +15 -0
- package/dist/request-context-native-output.js +46 -0
- package/dist/request-context-native-output.js.map +1 -0
- package/dist/request-context-native-result.d.ts +15 -0
- package/dist/request-context-native-result.js +46 -0
- package/dist/request-context-native-result.js.map +1 -0
- package/dist/request-context-off.d.ts +22 -0
- package/dist/request-context-off.js +77 -0
- package/dist/request-context-off.js.map +1 -0
- package/dist/request-context-outside-label.d.ts +5 -0
- package/dist/request-context-outside-label.js +28 -0
- package/dist/request-context-outside-label.js.map +1 -0
- package/dist/request-context-pane.d.ts +8 -0
- package/dist/request-context-pane.js +19 -0
- package/dist/request-context-pane.js.map +1 -1
- package/dist/request-context-pending-work.d.ts +11 -0
- package/dist/request-context-pending-work.js +43 -0
- package/dist/request-context-pending-work.js.map +1 -0
- package/dist/request-context-policy.d.ts +17 -1
- package/dist/request-context-policy.js +84 -6
- package/dist/request-context-policy.js.map +1 -1
- package/dist/request-context-readiness.d.ts +49 -0
- package/dist/request-context-readiness.js +64 -0
- package/dist/request-context-readiness.js.map +1 -0
- package/dist/request-context-recovery.d.ts +6 -2
- package/dist/request-context-recovery.js +25 -0
- package/dist/request-context-recovery.js.map +1 -1
- package/dist/request-context-relay.d.ts +2 -2
- package/dist/request-context-relay.js +10 -10
- package/dist/request-context-relay.js.map +1 -1
- package/dist/request-context-reply-pending.d.ts +16 -0
- package/dist/request-context-reply-pending.js +77 -0
- package/dist/request-context-reply-pending.js.map +1 -0
- package/dist/request-context-resolution.d.ts +35 -0
- package/dist/request-context-resolution.js +86 -0
- package/dist/request-context-resolution.js.map +1 -0
- package/dist/request-context-retirement.d.ts +21 -0
- package/dist/request-context-retirement.js +16 -0
- package/dist/request-context-retirement.js.map +1 -0
- package/dist/request-context-start.d.ts +15 -0
- package/dist/request-context-start.js +2 -0
- package/dist/request-context-start.js.map +1 -0
- package/dist/request-context-turns.d.ts +1 -1
- package/dist/request-context-turns.js +3 -2
- package/dist/request-context-turns.js.map +1 -1
- package/dist/request-context-unproved-label.d.ts +4 -0
- package/dist/request-context-unproved-label.js +25 -0
- package/dist/request-context-unproved-label.js.map +1 -0
- package/dist/request-context-update-guard.d.ts +15 -0
- package/dist/request-context-update-guard.js +54 -0
- package/dist/request-context-update-guard.js.map +1 -0
- package/dist/request-context-work.d.ts +50 -0
- package/dist/request-context-work.js +178 -0
- package/dist/request-context-work.js.map +1 -0
- package/dist/request-hub-context.d.ts +1 -0
- package/dist/request-hub-output.d.ts +2 -0
- package/dist/request-hub-output.js +12 -0
- package/dist/request-hub-output.js.map +1 -1
- package/dist/retained-human-control.d.ts +11 -0
- package/dist/retained-human-control.js +11 -0
- package/dist/retained-human-control.js.map +1 -0
- package/dist/runtime-build-info.js +1 -1
- package/dist/runtime-build-info.js.map +1 -1
- package/dist/runtime-cli.js +1 -1
- package/dist/runtime-cli.js.map +1 -1
- package/dist/runtime-client-store.js +7 -1
- package/dist/runtime-client-store.js.map +1 -1
- package/dist/runtime-client.js +15 -3
- package/dist/runtime-client.js.map +1 -1
- package/dist/runtime-coordinator.d.ts +23 -0
- package/dist/runtime-coordinator.js +103 -4
- package/dist/runtime-coordinator.js.map +1 -1
- package/dist/runtime-pane-mcp.d.ts +9 -0
- package/dist/runtime-pane-mcp.js +22 -2
- package/dist/runtime-pane-mcp.js.map +1 -1
- package/dist/runtime-protocol.d.ts +2 -0
- package/dist/runtime-protocol.js.map +1 -1
- package/dist/runtime-update-controller.js +1 -1
- package/dist/runtime-update-controller.js.map +1 -1
- package/dist/runtime-windows-bridge.d.ts +8 -0
- package/dist/runtime-windows-bridge.js +50 -3
- package/dist/runtime-windows-bridge.js.map +1 -1
- package/dist/scheduler/db.js +9 -0
- package/dist/scheduler/db.js.map +1 -1
- package/dist/scheduler/task-board-text.d.ts +3 -6
- package/dist/scheduler/task-board-text.js +15 -10
- package/dist/scheduler/task-board-text.js.map +1 -1
- package/dist/scheduler/task-board-unread.d.ts +90 -0
- package/dist/scheduler/task-board-unread.js +192 -0
- package/dist/scheduler/task-board-unread.js.map +1 -0
- package/dist/scheduler/task-board.d.ts +324 -6
- package/dist/scheduler/task-board.js +786 -47
- package/dist/scheduler/task-board.js.map +1 -1
- package/dist/service-install-handover.d.ts +52 -0
- package/dist/service-install-handover.js +50 -0
- package/dist/service-install-handover.js.map +1 -0
- package/dist/service-installer.d.ts +12 -0
- package/dist/service-installer.js +24 -10
- package/dist/service-installer.js.map +1 -1
- package/dist/settings-api.d.ts +2 -0
- package/dist/settings-api.js +4 -0
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-baseline.d.ts +1 -0
- package/dist/settings-baseline.js +5 -4
- package/dist/settings-baseline.js.map +1 -1
- package/dist/settings-confirmation.d.ts +2 -0
- package/dist/settings-confirmation.js +6 -0
- package/dist/settings-confirmation.js.map +1 -1
- package/dist/settings-effect.d.ts +2 -0
- package/dist/settings-effect.js +59 -1
- package/dist/settings-effect.js.map +1 -1
- package/dist/settings-http-confirmation.d.ts +3 -0
- package/dist/settings-http-confirmation.js +29 -0
- package/dist/settings-http-confirmation.js.map +1 -1
- package/dist/settings-route-lifetime.d.ts +3 -1
- package/dist/settings-route-lifetime.js +15 -5
- package/dist/settings-route-lifetime.js.map +1 -1
- package/dist/settings-transaction.d.ts +3 -2
- package/dist/settings-transaction.js.map +1 -1
- package/dist/task-board-tool.js +24 -3
- package/dist/task-board-tool.js.map +1 -1
- package/dist/task-board-waker.d.ts +53 -2
- package/dist/task-board-waker.js +183 -12
- package/dist/task-board-waker.js.map +1 -1
- package/dist/tips.js +1 -1
- package/dist/tips.js.map +1 -1
- package/dist/tool-permissions.js +3 -3
- package/dist/tool-permissions.js.map +1 -1
- package/dist/tool-receipt-output.d.ts +6 -6
- package/dist/transcript-monitor.d.ts +6 -1
- package/dist/transcript-monitor.js +59 -4
- package/dist/transcript-monitor.js.map +1 -1
- package/dist/transcript-turns.d.ts +3 -0
- package/dist/transcript-turns.js +5 -0
- package/dist/transcript-turns.js.map +1 -1
- package/dist/turn-reply-guard.d.ts +16 -1
- package/dist/turn-reply-guard.js +20 -2
- package/dist/turn-reply-guard.js.map +1 -1
- package/dist/ui/app.html +2 -2
- package/dist/ui/contact-auth-strings.js +6 -6
- package/dist/ui/contact-authorizations.js +19 -1
- package/dist/ui/contact-grant-editor.js +71 -11
- package/dist/ui/contact-needs.js +27 -8
- package/dist/ui/contact-permissions.js +25 -8
- package/dist/ui/contact-tool-groups.js +1 -1
- package/dist/ui/fleet-task-activity.js +164 -24
- package/dist/ui/fleet-task-card.js +77 -13
- package/dist/ui/fleet-task-common.js +14 -0
- package/dist/ui/fleet-task-flow.js +353 -0
- package/dist/ui/fleet-task-md.js +1 -1
- package/dist/ui/fleet-task-run.js +98 -22
- package/dist/ui/fleet-task-thread.js +245 -0
- package/dist/ui/fleet-task-unread.js +100 -0
- package/dist/ui/fleet-task-view.js +6 -5
- package/dist/ui/fleet-task-wake.js +140 -0
- package/dist/ui/fleet-tasks.js +13 -6
- package/dist/ui/hub-client.js +3 -0
- package/dist/ui/hub-room-members.js +4 -2
- package/dist/ui/hub-room-settings-strings.js +8 -0
- package/dist/ui/hub-room-settings.js +32 -0
- package/dist/ui/hub-room-thread.js +7 -1
- package/dist/ui/icons/hub-apple-touch-icon.png +0 -0
- package/dist/ui/icons/hub-favicon.ico +0 -0
- package/dist/ui/icons/hub-favicon.svg +10 -0
- package/dist/ui/icons/hub-icon-192.png +0 -0
- package/dist/ui/icons/hub-icon-512.png +0 -0
- package/dist/ui/icons/hub-icon-maskable-192.png +0 -0
- package/dist/ui/icons/hub-icon-maskable-512.png +0 -0
- package/dist/ui/icons/hub-maskable.svg +12 -0
- package/dist/ui/panel-hub.js +14 -3
- package/dist/ui/panel-needs.js +2 -1
- package/dist/ui/panel-settings.js +2 -1
- package/dist/ui/panel-windows-cli.js +2 -2
- package/dist/ui/request-contact-card.js +287 -0
- package/dist/ui/request-contact-client.js +83 -0
- package/dist/ui/request-contact-page.js +78 -0
- package/dist/ui/request-context-control.js +209 -0
- package/dist/ui/settings-registry.js +2 -0
- package/dist/ui/settings-update.js +3 -2
- package/dist/ui/shared/access-overview.css +1 -1
- package/dist/ui/shared/app-i18n.js +2 -2
- package/dist/ui/shared/app-install.js +2 -2
- package/dist/ui/shared/app-shell.js +17 -4
- package/dist/ui/shared/app-stream.js +4 -1
- package/dist/ui/shared/app-update.js +2 -1
- package/dist/ui/shared/app.css +101 -10
- package/dist/ui/shared/app.js +19 -2
- package/dist/ui/shared/task-board.css +164 -0
- package/dist/ui/shared/ui-icons.js +3 -0
- package/dist/ui/shared/ui-states.js +6 -0
- package/dist/ui/shared/update-card-ui.js +178 -11
- package/dist/ui/shared/view-strings.js +18 -0
- package/dist/ui/shared/web-authorize.js +1 -1
- package/dist/ui/task-unread.js +70 -0
- package/dist/ui/windows-cli-catalog.js +33 -6
- package/dist/update-card.d.ts +1 -1
- package/dist/update-card.js +7 -7
- package/dist/update-card.js.map +1 -1
- package/dist/update-fix.d.ts +66 -0
- package/dist/update-fix.js +67 -0
- package/dist/update-fix.js.map +1 -0
- package/dist/update-goback.js +15 -3
- package/dist/update-goback.js.map +1 -1
- package/dist/update-readiness.d.ts +2 -0
- package/dist/update-readiness.js +5 -1
- package/dist/update-readiness.js.map +1 -1
- package/dist/update-snapshot-scope.js +1 -0
- package/dist/update-snapshot-scope.js.map +1 -1
- package/dist/usage/i18n-keys.d.ts +1 -1
- package/dist/usage/i18n-keys.js +9 -0
- package/dist/usage/i18n-keys.js.map +1 -1
- package/dist/usage/providers.d.ts +3 -11
- package/dist/usage/providers.js +93 -131
- package/dist/usage/providers.js.map +1 -1
- package/dist/web-api.d.ts +49 -1
- package/dist/web-api.js +234 -13
- package/dist/web-api.js.map +1 -1
- package/dist/web-chat-history.d.ts +2 -0
- package/dist/web-chat-history.js.map +1 -1
- package/dist/web-icons.d.ts +9 -3
- package/dist/web-icons.js +62 -5
- package/dist/web-icons.js.map +1 -1
- package/dist/web-update.d.ts +9 -0
- package/dist/windows-agents.d.ts +24 -2
- package/dist/windows-agents.js +110 -4
- package/dist/windows-agents.js.map +1 -1
- package/dist/windows-cli-api.js +4 -2
- package/dist/windows-cli-api.js.map +1 -1
- package/dist/windows-cli-worker.js +9 -1
- package/dist/windows-cli-worker.js.map +1 -1
- package/dist/windows-cli.d.ts +55 -1
- package/dist/windows-cli.js +147 -17
- package/dist/windows-cli.js.map +1 -1
- package/dist/windows-shortcuts.d.ts +3 -22
- package/dist/windows-shortcuts.js +5 -45
- package/dist/windows-shortcuts.js.map +1 -1
- package/dist/workflow-templates/default.md +3 -2
- package/dist/wsl-host.d.ts +52 -0
- package/dist/wsl-host.js +97 -0
- package/dist/wsl-host.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import { clockFormat } from "/assets/clock-text.js";
|
|
2
|
+
// S-230: the owner switch. Status comes from the host, never from a browser preference or an agent argument.
|
|
3
|
+
import { html, useEffect, useRef, useState } from "/assets/app-html.js";
|
|
4
|
+
import { lang, register, t } from "/assets/app-i18n.js";
|
|
5
|
+
import { appStore, useStore } from "/assets/app-store.js";
|
|
6
|
+
import { useLease } from "/assets/app-ctx.js";
|
|
7
|
+
import { confirmedWrite } from "./settings-confirm.js";
|
|
8
|
+
import { confirmDialog } from "/assets/ui-confirm.js";
|
|
9
|
+
import { detailsPath, settingsPath } from "/assets/app-route.js";
|
|
10
|
+
import { AuthorizeChip } from "/assets/web-authorize.js";
|
|
11
|
+
|
|
12
|
+
register("requestContextControl", {
|
|
13
|
+
en: {
|
|
14
|
+
enableUnavailable: "Request-based approvals can't be turned on in this version yet.",
|
|
15
|
+
restart: "Turning this on restarts {0} agents (their conversations are kept); they can't chat for a minute or two.", goBack: "Go back for the latest update is available until {0}; turning this on ends it immediately.", viewUpdate: "View AgEnD update", viewOwners: "View these agents", waitTitle: "End this wait?", enableTitle: "Turn on request-based contact approvals?", enable: "Confirm turn on", unknown: "State unknown", inspect: "View held messages", update: "Finish or resolve the AgEnD update first, then check again.", stopTitle: "Stop this work?", stopBody: "This ends the saved work and prevents it from resuming. History stays. Other outside requests still wait for your decision.", waitBody: "A late reply will not resume this work. Other outside requests still wait for your decision.", title: "Request-based contact approvals", on: "On: approval applies only to this request.",
|
|
16
|
+
off: "Off. Your own messages go through as usual; requests that came from outside wait for your decision.",
|
|
17
|
+
offBefore: "Not enabled. Contacts haven't changed.",
|
|
18
|
+
draining: "Turning off. Waiting for current work to finish.", blocked: "Request-based approvals aren't on yet.", blockedBefore: "Turning this on has to wait for these first:",
|
|
19
|
+
legacyPending: "Decide these earlier contact requests first, in Fleet → Authorizations: {0}.",
|
|
20
|
+
legacyInflight: "These earlier approved messages are still being delivered: {0}. This clears by itself once each is delivered or fails.",
|
|
21
|
+
legacyUnsettled: "These earlier requests have no readable delivery record, so AgEnD can't tell whether they happened: {0}. They can't be settled from this page yet; leave request-based approvals off for now.",
|
|
22
|
+
legacyDeliveries: "These earlier messages are being sent right now: {0}. This clears by itself once each is delivered or fails.",
|
|
23
|
+
legacyRetire: "This earlier request has no readable delivery record, so AgEnD can't tell whether it happened: {0}. Retire it to stop waiting for it.",
|
|
24
|
+
legacyWithdraw: "This earlier message is still waiting to be sent: {0}. Withdraw it, or wait until it is delivered.",
|
|
25
|
+
retire: "Retire", retireGoBack: "Go back for the latest update (available until {0}) will no longer be available once you retire it.", retireTitle: "Retire this earlier request?", retireBody: "AgEnD stops waiting for this earlier request. It may already have happened; it won't be repeated, and its record stays.",
|
|
26
|
+
recoveryBlocked: "Request-based approvals need your attention.",
|
|
27
|
+
confirmTitle: "Turn off request-based approvals?", confirm: "Confirm turn off",
|
|
28
|
+
confirmBody: "New outside requests will wait while current work finishes. Then your own messages go through as usual; outside requests wait for your decision.",
|
|
29
|
+
legacy: "Resolve these earlier held messages first: {0}.", peers: "Update AgEnD on {0}, then press Check again.",
|
|
30
|
+
owners: "These agents need preparation: {0}.", ownersWork: "Finish the current work for these agents first: {0}. Wait for them to finish, or restart an agent that stays busy.", ownersUpdate: "Complete the AgEnD update for these agents first: {0}.", recovery: "This work needs your decision: {0}.",
|
|
31
|
+
returns: "Waiting for a reply: {0}.", tickets: "Resolve these held messages: {0}.", work: "Waiting for this work to finish: {0}.",
|
|
32
|
+
previous: "The previous rules still apply.", floor: "You can no longer downgrade to older AgEnD versions.",
|
|
33
|
+
floorBefore: "Note: once on, you can't go back to an older AgEnD, even if you turn this off later.",
|
|
34
|
+
check: "Check again", error: "Couldn't read the current state. Try again.", failed: "Couldn't confirm whether anything changed. Press Check again.",
|
|
35
|
+
notice: "Request-based contact approvals are on: approval applies only to this request. Earlier conversations won't block an administrator's new request. The switch is in Settings → Access & security. Warning: you can no longer downgrade to older AgEnD versions.",
|
|
36
|
+
open: "Open settings", loading: "Checking the current state…",
|
|
37
|
+
acknowledge: "Acknowledge", ackConfirm: "Acknowledge", unknownHint: "Open the agent to inspect this work, then press Check again.", ackTitle: "Acknowledge this message?", ackBody: "The result is still unknown. This marks the message as reviewed; it won't send it again.",
|
|
38
|
+
legacyUncertain: "These earlier messages have an unknown result: {0}. Please acknowledge them first.",
|
|
39
|
+
stopGoBack: "After you stop this work, this update can no longer be rolled back with Go back.",
|
|
40
|
+
workFamilies: "Waiting on {0}: {1}.", unknownEnd: "The conversation's end isn't confirmed.",
|
|
41
|
+
"family-turns": "an active conversation", "family-daemon-calls": "agent tool calls", "family-fleet-calls": "pending tool results",
|
|
42
|
+
"family-native-exec": "work on a connected computer", "family-native-grants": "active tool connections", "family-pane-proofs": "an agent window still in use",
|
|
43
|
+
"family-pane-ledgers": "an agent window awaiting confirmation", "family-registered-work": "queued or scheduled input", "family-human-input": "a message whose delivery isn't confirmed", "family-pending-stop": "work whose stop isn't confirmed", "family-unknown": "work that needs inspection",
|
|
44
|
+
"stop-waiting": "End this wait", decline: "Decline", withdraw: "Withdraw", "stop-work": "Stop this work",
|
|
45
|
+
},
|
|
46
|
+
"zh-TW": {
|
|
47
|
+
enableUnavailable: "這一版還不能開啟依請求核准聯絡。",
|
|
48
|
+
restart: "開啟時會重新啟動 {0} 個 Agent(對話會保留),大約一兩分鐘內無法對話。", goBack: "最近一次更新的「退回上一版」原本可以用到 {0},開啟後會立刻結束。", viewUpdate: "查看 AgEnD 更新", viewOwners: "查看這些 Agent", waitTitle: "結束這次等候?", enableTitle: "開啟依請求核准聯絡?", enable: "確認開啟", unknown: "狀態不明", inspect: "查看擱置的訊息", update: "請先完成或處理 AgEnD 更新,再重新檢查。", stopTitle: "結束這項工作?", stopBody: "這會結束已儲存的工作,不會再繼續執行。歷史會保留,其他外部請求仍會等你決定。", waitBody: "之後的回覆不會再繼續這項工作;其他外部請求仍會等你決定。", title: "依請求核准聯絡", on: "已開啟:核准只對這一次請求有效。",
|
|
49
|
+
off: "已關閉。你自己的訊息照常;從外部來的請求會等你決定。",
|
|
50
|
+
offBefore: "尚未開啟,聯絡方式沒有變更。",
|
|
51
|
+
draining: "正在關閉,等目前的工作結束。", blocked: "依請求核准聯絡尚未開啟。", blockedBefore: "開啟前需要先處理這些項目:",
|
|
52
|
+
legacyPending: "請先在「Fleet → 授權」決定這些先前的聯絡申請:{0}。",
|
|
53
|
+
legacyInflight: "這些先前已核准的訊息仍在送出中:{0}。每則送達或失敗後就會自動解除。",
|
|
54
|
+
legacyUnsettled: "這些先前的申請沒有可讀取的送出紀錄,AgEnD 無法判斷是否已經發生:{0}。目前還無法在這一頁處理;請暫時不要開啟依請求核准聯絡。",
|
|
55
|
+
legacyDeliveries: "這些先前的訊息正在送出:{0}。每則送達或失敗後就會自動解除。",
|
|
56
|
+
legacyRetire: "這筆先前的申請沒有可讀取的送出紀錄,AgEnD 無法判斷是否已經發生:{0}。選「不再等候」就不會再等它。",
|
|
57
|
+
legacyWithdraw: "這則先前的訊息仍在等候送出:{0}。可以撤回,或等它送達。",
|
|
58
|
+
retire: "不再等候", retireGoBack: "這樣做之後,最近一次更新就不能再「退回上一版」(原本可用到 {0})。", retireTitle: "不再等候這筆先前的申請?", retireBody: "AgEnD 會停止等候這筆先前的申請。它可能已經發生;不會再重複執行,紀錄會保留。",
|
|
59
|
+
recoveryBlocked: "依請求核准聯絡需要你處理。",
|
|
60
|
+
confirmTitle: "關閉依請求核准聯絡?", confirm: "確認關閉",
|
|
61
|
+
confirmBody: "新的外部請求會先等候,直到目前的工作結束。之後,你自己的訊息照常;從外部來的請求會等你決定。",
|
|
62
|
+
legacy: "請先處理這些先前擱置的訊息:{0}。", peers: "請在 {0} 上更新 AgEnD,完成後按「重新檢查」。",
|
|
63
|
+
owners: "這些 Agent 需要先完成準備:{0}。", ownersWork: "請先等這些 Agent 完成目前的工作:{0}。請等它們完成,或重新啟動一直忙碌的 Agent。", ownersUpdate: "請先完成這些 Agent 的 AgEnD 更新:{0}。", recovery: "這項工作需要你決定:{0}。",
|
|
64
|
+
returns: "正在等候回覆:{0}。", tickets: "請先處理這些擱置的訊息:{0}。", work: "正在等這項工作結束:{0}。",
|
|
65
|
+
previous: "目前仍使用原本的規則。", floor: "已不能再降回舊版 AgEnD。",
|
|
66
|
+
floorBefore: "注意:開啟後就不能再降回舊版 AgEnD,之後關閉也一樣。",
|
|
67
|
+
check: "重新檢查", error: "無法讀取目前狀態,請再試一次。", failed: "無法確認是否已變更,請按「重新檢查」。",
|
|
68
|
+
notice: "依請求核准聯絡已開啟:核准只對這一次請求有效,先前的對話不會再擋住管理員的新請求。開關在「設定」→「存取與安全」。注意:已不能再降回舊版 AgEnD。",
|
|
69
|
+
open: "開啟設定", loading: "正在確認目前狀態…",
|
|
70
|
+
acknowledge: "確認已看過", ackConfirm: "確認", unknownHint: "請開啟 Agent 檢查這項工作,再按「重新檢查」。", ackTitle: "確認已看過這則訊息?", ackBody: "結果仍不明。這只會記錄你已看過,不會再次傳送。",
|
|
71
|
+
legacyUncertain: "這些先前的訊息結果不明:{0}。請先確認已看過。",
|
|
72
|
+
stopGoBack: "結束這項工作後,這次更新就不能再退回。",
|
|
73
|
+
workFamilies: "正在等候 {0}:{1}。", unknownEnd: "無法確認這次對話是否已結束。",
|
|
74
|
+
"family-turns": "尚未結束的對話", "family-daemon-calls": "Agent 的工具操作", "family-fleet-calls": "尚未回傳的操作結果",
|
|
75
|
+
"family-native-exec": "連線電腦上執行的工作", "family-native-grants": "仍在使用的工具連線", "family-pane-proofs": "仍在使用的 Agent 視窗",
|
|
76
|
+
"family-pane-ledgers": "等待確認的 Agent 視窗", "family-registered-work": "等待執行或排程的訊息", "family-human-input": "無法確認是否送達的訊息", "family-pending-stop": "還沒確認已結束的工作", "family-unknown": "需要檢查的工作",
|
|
77
|
+
"stop-waiting": "結束這次等候", decline: "拒絕", withdraw: "撤回", "stop-work": "結束這項工作",
|
|
78
|
+
},
|
|
79
|
+
});
|
|
80
|
+
export const requestContextControlText = (key, ...args) => t(`requestContextControl.${key}`, ...args);
|
|
81
|
+
const LEGACY_KEYS = { "legacy-pending": "legacyPending", "legacy-inflight": "legacyInflight", "legacy-unsettled": "legacyUnsettled", "legacy-deliveries": "legacyDeliveries", "legacy-uncertain": "legacyUncertain" };
|
|
82
|
+
// M-3897: one blocker per earlier ticket or delivery an owner can settle (its id carries the ticket or delivery id).
|
|
83
|
+
const legacyKeyOf = (id) => LEGACY_KEYS[id] || (id.startsWith("legacy-retire:") ? "legacyRetire" : id.startsWith("legacy-withdraw:") ? "legacyWithdraw" : null);
|
|
84
|
+
export function requestContextBlockerText(blocker) {
|
|
85
|
+
// S-272: an earlier ticket says what settles it (its own sentence by blocker id); an older server's "legacy" keeps its line.
|
|
86
|
+
const legacyKey = blocker.kind === "legacy" && (blocker.id.startsWith("legacy-uncertain:")?"legacyUncertain":legacyKeyOf(blocker.id));
|
|
87
|
+
if(blocker.kind === "work" && blocker.families?.length){
|
|
88
|
+
const separator=lang()==="zh-TW"?"、":", ";
|
|
89
|
+
const text=requestContextControlText("workFamilies",(blocker.labels||[]).join(separator),blocker.families.map(family=>requestContextControlText(`family-${family}`)).join(separator));
|
|
90
|
+
const joiner=lang()==="zh-TW"?"":" ";
|
|
91
|
+
return text+(blocker.unknownEnd?joiner+requestContextControlText("unknownEnd"):"")
|
|
92
|
+
+(blocker.families.includes("unknown")?joiner+requestContextControlText("unknownHint"):"");
|
|
93
|
+
}
|
|
94
|
+
return requestContextControlText(legacyKey || (blocker.kind === "owners" && blocker.ownerCause ? blocker.ownerCause === "work" ? "ownersWork" : "ownersUpdate" : blocker.kind), (blocker.labels || []).join(lang() === "zh-TW" ? "、" : ", "));
|
|
95
|
+
}
|
|
96
|
+
export function RequestContextBlocked({ state, onCheck, onResolve, busy = false, settingsLink = false }) {
|
|
97
|
+
// S-272: before the first attempt it shows what an On would wait for (Check runs the same inspection as the attempt).
|
|
98
|
+
const before = !state?.everActivated && !state?.attempted;
|
|
99
|
+
if (!state || before && !(state.blockers || []).length) return null;
|
|
100
|
+
const ownerAgents = [...new Map((state.blockers || []).filter(b => b.kind === "owners" || b.kind === "work").flatMap(b => b.agents || []).map(a => [a.id, a])).values()];
|
|
101
|
+
return html`<div class="request-context-blocked">
|
|
102
|
+
<p>${requestContextControlText(state.phase === "draining" ? "draining" : state.everActivated ? "recoveryBlocked" : before ? "blockedBefore" : "blocked")}</p>
|
|
103
|
+
${state.enableFailed ? html`<p class="notice warn" role="alert">${requestContextControlText("failed")}</p>` : null}
|
|
104
|
+
${(state.blockers || []).map(blocker => html`<div key=${blocker.id}><p>${requestContextBlockerText(blocker)}</p>
|
|
105
|
+
${blocker.action === "stop-waiting" ? html`<p>${requestContextControlText("waitBody")}</p>` : null}</div>`)}
|
|
106
|
+
${!state.everActivated ? html`<p class="note">${requestContextControlText("previous")}</p>` : null}
|
|
107
|
+
<div class="request-context-actions">
|
|
108
|
+
${(state.blockers || []).some(b => b.action === "inspect" && b.kind === "legacy") ? html`<a class="btn btn-sm" href="/ui/fleet/authorizations">${requestContextControlText("inspect")}</a>` : null}
|
|
109
|
+
${(state.blockers || []).map(blocker => blocker.action === "inspect"
|
|
110
|
+
? null // S-272: one Authorizations link, for earlier held requests only; agents and the update have their own links below
|
|
111
|
+
: state.canChange && onResolve && blocker.action ? html`<button key=${blocker.id} type="button" class=${`btn btn-sm ${["stop-work", "stop-waiting", "retire"].includes(blocker.action) ? "btn-danger" : ""}`} disabled=${busy}
|
|
112
|
+
title=${requestContextBlockerText(blocker)} onClick=${() => onResolve(blocker)}>${requestContextControlText(blocker.action)}${blocker.kind === "work" && blocker.families?.length && blocker.labels?.length ? ` · ${blocker.labels.join(lang() === "zh-TW" ? "、" : ", ")}` : ""}</button>` : null)}
|
|
113
|
+
${(state.blockers || []).some(b => b.kind === "update") ? html`<a class="btn btn-sm" href=${settingsPath("advanced") + "#settings-update"}>${requestContextControlText("viewUpdate")}</a>` : null}
|
|
114
|
+
${ownerAgents.map(agent => html`<a class="btn btn-sm" key=${agent.id} href=${detailsPath(agent.id)}>${requestContextControlText("viewOwners")}${ownerAgents.length > 1 ? ` · ${agent.label}` : ""}</a>`)}
|
|
115
|
+
${onCheck ? html`<button type="button" class="btn btn-sm" disabled=${busy} onClick=${onCheck}>${requestContextControlText("check")}</button>` : null}
|
|
116
|
+
${settingsLink ? html`<a class="btn btn-sm" href="/settings/access#request-context">${requestContextControlText("open")}</a>` : null}
|
|
117
|
+
</div>
|
|
118
|
+
</div>`;
|
|
119
|
+
}
|
|
120
|
+
async function writeControl(lease, input) {
|
|
121
|
+
if (input.action !== "check") return confirmedWrite("/api/settings/request-context", { body: input, label: requestContextControlText("title") });
|
|
122
|
+
const response = await lease.fetch("/api/settings/request-context", { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify(input) });
|
|
123
|
+
return { ok: response.ok, status: response.status, body: await response.json() };
|
|
124
|
+
}
|
|
125
|
+
/** Passive Needs-you payload, from the same owner status as Settings. No background GET or timer. */
|
|
126
|
+
export function RequestContextNeed({ item }) {
|
|
127
|
+
const lease = useLease(`request-context-need:${item.id}`), [busy, setBusy] = useState(false), [failed, setFailed] = useState(false), writing = useRef(false);
|
|
128
|
+
const state = item.requestContextCutover;
|
|
129
|
+
useEffect(() => { setFailed(false); }, [state?.revision]);
|
|
130
|
+
const change = async (blocker = null) => {
|
|
131
|
+
if (writing.current || failed || !state || blocker && !state.canChange) return;
|
|
132
|
+
writing.current = true; setBusy(true); setFailed(false);
|
|
133
|
+
try {
|
|
134
|
+
if(blocker?.action==="acknowledge" && !await confirmDialog({title:requestContextControlText("ackTitle"),message:requestContextControlText("ackBody"),confirmLabel:requestContextControlText("ackConfirm"),danger:false}))return;
|
|
135
|
+
if (["stop-work", "stop-waiting"].includes(blocker?.action) && !await confirmStopWork(blocker.action, state.goBack)) return;
|
|
136
|
+
if (blocker?.action === "retire" && !await confirmRetire(state)) return;
|
|
137
|
+
const input = blocker ? { revision: state.revision, action: "resolve", blockerId: blocker.id, resolution: blocker.action } : { revision: state.revision, action: "check" };
|
|
138
|
+
const response = await writeControl(lease, input);
|
|
139
|
+
if (!lease.current()) return;
|
|
140
|
+
if (!response.ok && response.status !== 409) throw Error("refused");
|
|
141
|
+
} catch { if (lease.current()) setFailed(true); }
|
|
142
|
+
finally { writing.current = false; if (lease.current()) setBusy(false); }
|
|
143
|
+
};
|
|
144
|
+
return html`<article class="card request-context-need"><h3>${requestContextControlText("title")}</h3>
|
|
145
|
+
<${RequestContextBlocked} state=${state} settingsLink=${true} busy=${busy || failed} onCheck=${() => change()} onResolve=${state?.canChange ? change : null} />
|
|
146
|
+
${state && !state.canChange ? html`<${AuthorizeChip} />` : null}
|
|
147
|
+
${failed ? html`<p class="notice warn" role="alert">${requestContextControlText("failed")}</p>` : null}
|
|
148
|
+
</article>`;
|
|
149
|
+
}
|
|
150
|
+
/** M-3897: Retire says what it does, and that it ends Go back for the latest update when that is still offered (Sentinel's contract). */
|
|
151
|
+
async function confirmRetire(state) {
|
|
152
|
+
const goBack = state?.goBack ? "\n\n" + requestContextControlText("retireGoBack", clockFormat({ dateStyle: "medium", timeStyle: "short", timeZone: state.goBack.timeZone }, "en").format(new Date(state.goBack.availableUntil))) : "";
|
|
153
|
+
return confirmDialog({ title: requestContextControlText("retireTitle"), message: requestContextControlText("retireBody") + goBack, confirmLabel: requestContextControlText("retire"), danger: true });
|
|
154
|
+
}
|
|
155
|
+
async function confirmStopWork(action, goBack) { return confirmDialog({ title: requestContextControlText(action === "stop-waiting" ? "waitTitle" : "stopTitle"), message: requestContextControlText(action === "stop-waiting" ? "waitBody" : "stopBody") + (action === "stop-work" && goBack ? "\n\n" + requestContextControlText("stopGoBack") : ""), confirmLabel: requestContextControlText(action), danger: true }); }
|
|
156
|
+
export function RequestContextSettings() {
|
|
157
|
+
const lease = useLease("request-context-control"), [state, setState] = useState(undefined), [failed, setFailed] = useState(false), [busy, setBusy] = useState(false);
|
|
158
|
+
const toggle = useRef(null);
|
|
159
|
+
useEffect(() => { if (toggle.current) toggle.current.indeterminate = failed; }, [failed, state]);
|
|
160
|
+
const writing = useRef(false), lastRevision = useRef(-1), { requestContextCutover: pushed } = useStore(appStore);
|
|
161
|
+
const accept = value => {
|
|
162
|
+
if (value !== null) {
|
|
163
|
+
if (!Number.isSafeInteger(value?.revision) || value.revision < lastRevision.current) return;
|
|
164
|
+
lastRevision.current = value.revision;
|
|
165
|
+
}
|
|
166
|
+
setState(value); setFailed(false);
|
|
167
|
+
};
|
|
168
|
+
const load = async () => {
|
|
169
|
+
try {
|
|
170
|
+
const response = await lease.fetch("/api/settings/request-context"), value = response.status === 404 ? null : await response.json();
|
|
171
|
+
if (!lease.current()) return;
|
|
172
|
+
if (response.status !== 404 && !response.ok) throw Error("unavailable");
|
|
173
|
+
accept(value);
|
|
174
|
+
} catch { if (lease.current()) setFailed(true); }
|
|
175
|
+
};
|
|
176
|
+
useEffect(() => { void load(); }, [lease]);
|
|
177
|
+
useEffect(() => { if (pushed !== undefined && lease.current()) accept(pushed); }, [pushed, lease]);
|
|
178
|
+
const change = async (action, blocker = null) => {
|
|
179
|
+
if (writing.current || failed || !state || action !== "check" && !state.canChange) return;
|
|
180
|
+
if (action === "enable" && state.enableUnavailable) return;
|
|
181
|
+
writing.current = true; setBusy(true); setFailed(false);
|
|
182
|
+
try {
|
|
183
|
+
if (action === "enable" && !await confirmDialog({ title: requestContextControlText("enableTitle"), message: requestContextControlText("floorBefore") + (state.goBack ? "\n\n" + requestContextControlText("goBack", clockFormat({ dateStyle: "medium", timeStyle: "short", timeZone: state.goBack.timeZone }, "en").format(new Date(state.goBack.availableUntil))) : "") + (state.restartCount ? "\n\n" + requestContextControlText("restart", state.restartCount) : ""), confirmLabel: requestContextControlText("enable"), danger: true })) return;
|
|
184
|
+
if(blocker?.action==="acknowledge" && !await confirmDialog({title:requestContextControlText("ackTitle"),message:requestContextControlText("ackBody"),confirmLabel:requestContextControlText("ackConfirm"),danger:false}))return;
|
|
185
|
+
if (["stop-work", "stop-waiting"].includes(blocker?.action) && !await confirmStopWork(blocker.action, state.goBack)) return;
|
|
186
|
+
if (blocker?.action === "retire" && !await confirmRetire(state)) return;
|
|
187
|
+
if (action === "disable" && !await confirmDialog({ title: requestContextControlText("confirmTitle"), message: requestContextControlText("confirmBody"), confirmLabel: requestContextControlText("confirm"), danger: false })) return;
|
|
188
|
+
if (!lease.current()) return;
|
|
189
|
+
const response = await writeControl(lease, blocker ? { revision: state.revision, action: "resolve", blockerId: blocker.id, resolution: blocker.action } : { revision: state.revision, action });
|
|
190
|
+
if (!lease.current()) return;
|
|
191
|
+
if (response.status === 409) { await load(); return; }
|
|
192
|
+
if (!response.ok) throw Error("refused");
|
|
193
|
+
const value = response.body; if (lease.current()) accept(value);
|
|
194
|
+
} catch { if (lease.current()) setFailed(true); }
|
|
195
|
+
finally { writing.current = false; if (lease.current()) setBusy(false); }
|
|
196
|
+
};
|
|
197
|
+
if (state === null) return null;
|
|
198
|
+
return html`<section id="request-context" class="card request-context-control"><h2>${requestContextControlText("title")}</h2>
|
|
199
|
+
${state ? html`<label class="check request-context-toggle"><input type="checkbox" class="s-ui-toggle" ref=${toggle} aria-checked=${failed ? "mixed" : state.enabled ? "true" : "false"} checked=${!failed && state.enabled}
|
|
200
|
+
disabled=${busy || failed || !state.canChange || state.phase === "draining" || !state.enabled && state.enableUnavailable} onChange=${event => { event.target.checked = state.enabled; void change(state.enabled ? "disable" : "enable"); }} />
|
|
201
|
+
<span>${requestContextControlText("title")}</span></label>
|
|
202
|
+
${!state.enabled && state.enableUnavailable ? html`<p role="status">${requestContextControlText("enableUnavailable")}</p>` : null}
|
|
203
|
+
${failed ? html`<p role="status">${requestContextControlText("unknown")}</p>` : ["blocked", "draining"].includes(state.phase) ? html`<${RequestContextBlocked} state=${state} busy=${busy || failed} onCheck=${() => change("check")} onResolve=${state.canChange ? blocker => change("resolve", blocker) : null} />`
|
|
204
|
+
: html`<p role="status">${requestContextControlText(state.phase === "off" && !state.everActivated ? "offBefore" : state.phase)}</p>`}
|
|
205
|
+
${!state.everActivated && !state.enabled && state.enableUnavailable ? null : html`<p class="notice warn">${requestContextControlText(state.everActivated ? "floor" : "floorBefore")}</p>`}
|
|
206
|
+
${!state.canChange ? html`<${AuthorizeChip} />` : null}` : !failed ? html`<p>${requestContextControlText("loading")}</p>` : null}
|
|
207
|
+
${failed ? html`<p class="notice warn" role="alert">${requestContextControlText(state ? "failed" : "error")}</p><button class="btn btn-sm" type="button" disabled=${busy} onClick=${load}>${requestContextControlText("check")}</button>` : null}
|
|
208
|
+
</section>`;
|
|
209
|
+
}
|
|
@@ -21,6 +21,7 @@ const L = (en, zh) => ({ en, "zh-TW": zh });
|
|
|
21
21
|
const CLI_WORDS = Object.keys(CLI_CAPS).flatMap((id) => [id, id.split("-")[0]]);
|
|
22
22
|
/** [id, section, target, labelKey | label, config key, words en, words zh] */
|
|
23
23
|
const ROWS = [
|
|
24
|
+
["request.context", "access", "#request-context", null, null, ["contact", "approval", "request", "permissions"], ["聯絡", "核准", "請求", "權限"], L("Request-based contact approvals", "依請求核准聯絡")],
|
|
24
25
|
["host.monitoring", "notifications", "#host-monitoring", null, "monitoring.enabled", ["host", "health", "monitoring", "disk", "memory", "cpu", "agent footprint"], ["主機", "監測", "磁碟", "記憶體", "資源用量"], L("Host monitoring", "主機監測")],
|
|
25
26
|
["general.location", "agent-defaults", "#general-location", null, null, ["general", "windows", "paired PC", "host", "location"], ["General", "Windows", "電腦", "主機", "執行位置"], L("Run General on", "General 執行位置")],
|
|
26
27
|
// alpha.6 feedback (#2): "hub" found nothing — Settings → Hub's cards. Connect to a Hub is drawn once membership is on.
|
|
@@ -169,6 +170,7 @@ export function searchSettings(query, schema = null) {
|
|
|
169
170
|
const scored = [];
|
|
170
171
|
for (const entry of SETTINGS_REGISTRY) {
|
|
171
172
|
if (entry.id === "host.monitoring" && !hostMonitoringVisible(schema)) continue;
|
|
173
|
+
if (entry.id === "request.context" && schema?.request_context_control !== true) continue;
|
|
172
174
|
const names = [settingLabel(entry, "en"), settingLabel(entry, "zh-TW")].map(fold);
|
|
173
175
|
const keys = fold(entry.key || "");
|
|
174
176
|
const words = [...(entry.words.en || []), ...(entry.words["zh-TW"] || [])].map(fold);
|
|
@@ -66,13 +66,14 @@ export function UpdateSection() {
|
|
|
66
66
|
${need ? html`<button type="button" class="btn btn-primary" disabled=${starting || updateActive(info)} onClick=${() => { void openHubUpdateDialog(); }}>${t("update.now")}</button>`
|
|
67
67
|
: info.card !== undefined ? cardButtons(info, starting)
|
|
68
68
|
: offer && offer.installable ? html`<button type="button" class="btn btn-primary" disabled=${starting || updateActive(info)} onClick=${openUpdateDialog}>${t("update.now")}</button>` : null}
|
|
69
|
-
<button type="button" class="btn" disabled=${checking || updateActive(info)} onClick=${check}>${checking ? t("supdate.checking") : t("supdate.check")}</button>
|
|
69
|
+
<button type="button" class="btn" disabled=${checking || starting || updateActive(info)} onClick=${check}>${checking ? t("supdate.checking") : t("supdate.check")}</button>
|
|
70
70
|
</div>
|
|
71
71
|
${info.card !== undefined ? html`<${UpdateCardSettings} info=${info} deps=${CARD_DEPS} />` : null}
|
|
72
72
|
</section>`;
|
|
73
73
|
}
|
|
74
74
|
/** M-3770 1.4: what update-card-ui.js needs from app-update.js, passed in. */
|
|
75
|
-
const CARD_DEPS = { refresh: () => refreshUpdate(), setInfo: (i) => updateStore.set({ info: i }), getInfo: () => updateStore.get().info
|
|
75
|
+
const CARD_DEPS = { refresh: () => refreshUpdate(), setInfo: (i) => updateStore.set({ info: i }), getInfo: () => updateStore.get().info,
|
|
76
|
+
setStarting: (starting) => updateStore.set({ starting }) }; // #4564: the row is off while Install as a service restarts AgEnD
|
|
76
77
|
/** M-3770 1.4: with the card, the banner's answers in every state (#4487 review P2: the banner is hidden on this page, so
|
|
77
78
|
* waiting and scheduled keep Cancel and Update now here; Pick a time only where a schedule is taken). One policy: cardActions. */
|
|
78
79
|
function cardButtons(info, starting) {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
.p-settings .s-ov-row dt { color: var(--text-2); font-size: var(--fs-sm); min-width: 0; }
|
|
26
26
|
.p-settings .s-ov-hint { display: block; margin-top: 2px; color: var(--text-3); font-size: var(--fs-xs); line-height: 1.4; }
|
|
27
27
|
.p-settings .s-ov-why { display: block; margin-top: 2px; color: var(--text-2); font-size: var(--fs-xs); }
|
|
28
|
-
.p-settings .s-ov-legend { color: var(--text-3); font-size: var(--fs-xs); }
|
|
28
|
+
.p-settings .s-ov-legend { color: var(--text-3); font-size: var(--fs-xs); word-break: keep-all; overflow-wrap: anywhere; } /* M-3900: 「未驗證」 whole on a phone */
|
|
29
29
|
.p-settings .s-ov-row dd { margin: 0; text-align: right; font-size: var(--fs-sm); overflow-wrap: anywhere; }
|
|
30
30
|
.p-settings .s-ov-muted { color: var(--text-3); }
|
|
31
31
|
.p-settings .tag.tag-ok { background: color-mix(in srgb, var(--ok) 14%, transparent); color: var(--ok); }
|
|
@@ -115,7 +115,7 @@ register("app", {
|
|
|
115
115
|
restartRefused: "Restart refused: {0}",
|
|
116
116
|
pendingSent: "Sent for confirmation — a fleet admin confirms it in chat.",
|
|
117
117
|
pendingSelfSent: "Confirmed by your account — applying.",
|
|
118
|
-
needsNav: "Needs you", needsTab: "Needs you", needsCount: "{0} waiting", noticesNav: "Notices", noticesCount: "{0} unread",
|
|
118
|
+
needsNav: "Needs you", needsTab: "Needs you", needsCount: "{0} waiting", noticesNav: "Notices", noticesCount: "{0} unread", taskUnreadCount: "{0} task cards with new replies", taskUnreadOne: "1 task card has new replies",
|
|
119
119
|
// #2293: global search — chats, cross-instance messages and tasks (not the sidebar's filter of agents).
|
|
120
120
|
search: "Search", searchTitle: "Search chats, messages between agents and tasks ({0})",
|
|
121
121
|
confirmTitle: "Please confirm", confirmOk: "Continue", cancel: "Cancel",
|
|
@@ -167,7 +167,7 @@ register("app", {
|
|
|
167
167
|
restartRefused: "重新啟動被拒絕:{0}",
|
|
168
168
|
pendingSent: "已送出確認——由 fleet 管理員在聊天中確認。",
|
|
169
169
|
pendingSelfSent: "已由你的帳號確認——套用中。",
|
|
170
|
-
needsNav: "等你處理", needsTab: "待處理", needsCount: "{0} 件待處理", noticesNav: "通知", noticesCount: "{0} 則未讀",
|
|
170
|
+
needsNav: "等你處理", needsTab: "待處理", needsCount: "{0} 件待處理", noticesNav: "通知", noticesCount: "{0} 則未讀", taskUnreadCount: "{0} 張任務卡有新回覆", taskUnreadOne: "1 張任務卡有新回覆",
|
|
171
171
|
search: "搜尋", searchTitle: "搜尋聊天、agent 之間的訊息與任務({0})",
|
|
172
172
|
confirmTitle: "請確認", confirmOk: "繼續", cancel: "取消",
|
|
173
173
|
sidePanelLeave: "不儲存就離開「{0}」?你在那裡的修改會遺失。", sidePanelDiscard: "捨棄修改",
|
|
@@ -61,14 +61,14 @@ export function startInstall(env = globalThis) {
|
|
|
61
61
|
if (standalone(env)) { set("installed"); return; }
|
|
62
62
|
env.addEventListener?.("beforeinstallprompt", (event) => { event.preventDefault(); offer = event; set("available"); });
|
|
63
63
|
env.addEventListener?.("appinstalled", () => { offer = null; set("installed"); });
|
|
64
|
-
if (iosSafari(env)) set("ios");
|
|
65
64
|
// A plain-http address is not a secure context, and browsers hide the worker API there: say why before looking for it.
|
|
66
65
|
if (env.isSecureContext === false) { if (installStore.get().state === "none") set("insecure"); return; }
|
|
66
|
+
if (iosSafari(env)) set("ios");
|
|
67
67
|
const sw = env.navigator?.serviceWorker;
|
|
68
68
|
if (!sw) return;
|
|
69
69
|
sw.register("/sw.js", { scope: "/" }).catch((error) => {
|
|
70
70
|
// A certificate the browser doesn't trust: registration is refused as a SecurityError.
|
|
71
|
-
if (error && error.name === "SecurityError" && installStore.get().state
|
|
71
|
+
if (error && error.name === "SecurityError" && ["none", "ios"].includes(installStore.get().state)) set("untrusted");
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
74
|
|
|
@@ -461,8 +461,11 @@ function Sidebar({ route, onNewInstance, viewOnly }) {
|
|
|
461
461
|
// one Fleet entry ("Fleet" / "Fleet 概覽"), on the tab this device used last (the Org chart the first time); an agent's
|
|
462
462
|
// View, Log and Details are its header's tabs, so the sidebar has no "Fleet" (Details) or "View" row of its own.
|
|
463
463
|
const onFleet = !!route && route.panel === "fleet";
|
|
464
|
+
// The cards someone answered, named this person on or handed them (docs/design/task-board.md, "Unread"; task-unread.js): a number on
|
|
465
|
+
// the Fleet row, hidden at 0 and for a session that cannot write. A phone's drawer shows no counts (M-3166): the Tasks page says it there.
|
|
466
|
+
const taskUnread = app.taskUnread && app.taskUnread.enabled ? app.taskUnread.total | 0 : 0;
|
|
464
467
|
const overview = html`<a class=${`side-row side-overview${onFleet ? " active" : ""}`} href=${fleetEntryPath(route)}
|
|
465
|
-
aria-current=${onFleet ? "page" : undefined} onClick=${closeDrawer}><${Icon} name="org" /><span class="grow">${t("app.fleetOverview")}</span
|
|
468
|
+
aria-current=${onFleet ? "page" : undefined} aria-label=${taskUnread ? `${t("app.fleetOverview")} (${taskUnread === 1 ? t("app.taskUnreadOne") : t("app.taskUnreadCount", taskUnread)})` : undefined} onClick=${closeDrawer}><${Icon} name="org" /><span class="grow">${t("app.fleetOverview")}</span>${taskUnread ? html`<span class="nav-count task-unread-count" aria-hidden="true" title=${taskUnread === 1 ? t("app.taskUnreadOne") : t("app.taskUnreadCount", taskUnread)}>${taskUnread}</span>` : null}</a>`;
|
|
466
469
|
return html`<aside id="sidebar" class=${`sidebar fleet-side${narrowDrawer ? " drawer-narrow" : ""}`} aria-label=${t("app.menu")}>
|
|
467
470
|
<div class="side-head" data-trust="navigation">
|
|
468
471
|
<a class="brand" href="/ui" onClick=${closeDrawer}>${t("app.brand")}</a>
|
|
@@ -866,6 +869,13 @@ function pendingSummaryLine(line, descriptor) {
|
|
|
866
869
|
}
|
|
867
870
|
return legacyPendingSummaryLine(line);
|
|
868
871
|
}
|
|
872
|
+
/** Presentation only: the server's canonical On summary identifies this irreversible consequence. */
|
|
873
|
+
function pendingRequestContextEnable(p) {
|
|
874
|
+
if (p.section !== "access" || !Array.isArray(p.summary) || !Array.isArray(p.summary_i18n) || p.summary.length !== p.summary_i18n.length) return false;
|
|
875
|
+
const keys = p.summary_i18n.flatMap((line, index) => line?.v === 1 && line.fallback === p.summary[index] && Array.isArray(line.parts)
|
|
876
|
+
? line.parts.filter(part => part && typeof part === "object" && Array.isArray(part.args) && part.args.length === 0).map(part => part.key) : []);
|
|
877
|
+
return keys.includes("requestContextControl.enableTitle") && keys.includes("requestContextControl.floorBefore");
|
|
878
|
+
}
|
|
869
879
|
export function PendingChanges({ inline = false } = {}) {
|
|
870
880
|
const { pendingChanges } = useStore(appStore);
|
|
871
881
|
const list = pendingChanges || [];
|
|
@@ -890,6 +900,7 @@ export function PendingChanges({ inline = false } = {}) {
|
|
|
890
900
|
${p.state === "pending" ? html`<span class="pending-left">${t("app.pendingLeft", mmss(p.deadline - NOW()))}</span>` : null}
|
|
891
901
|
${p.dismiss ? html`<button type="button" class="icon-btn" aria-label=${t("app.close")} title=${t("app.close")} onClick=${p.dismiss}><${Icon} name="close" size=${14} /></button>` : null}</div>
|
|
892
902
|
${p.label ? html`<div class="pending-label">${p.label}</div>` : null}
|
|
903
|
+
${pendingRequestContextEnable(p) ? html`<p class="notice warn">${t("pendingHost.requestContextFloor")}</p>` : null}
|
|
893
904
|
${Array.isArray(p.summary) && p.summary.length ? html`<details class="pending-details" open=${Array.isArray(p.summary_i18n)&&p.summary_i18n.some(line=>line?.v===1&&Array.isArray(line.parts)&&line.parts.some(part=>part&&typeof part==="object"&&part.key==="hub.exposure.summary.classicRoom"))}><summary>${t("pendingHost.details")}</summary><ul class="pending-summary">${p.summary.map((line, i) => html`<li key=${i}>${String(pendingSummaryLine(line, Array.isArray(p.summary_i18n) && p.summary_i18n.length === p.summary.length ? p.summary_i18n[i] : null)).replace(/\\([\\`*_~[\]()<>|])/g, "$1")}</li>`)}</ul></details>` : null}
|
|
894
905
|
${p.state === "pending" ? html`<${PendingHow} p=${p} />` : null}
|
|
895
906
|
${(p.state === "applying" || p.state === "applied") && p.confirmation && p.confirmation.kind === "web" ? html`<p class="note">${t("app.pendingWeb")}</p>` : null}
|
|
@@ -931,6 +942,7 @@ function whereText(where) {
|
|
|
931
942
|
// would let it through — never "type this command on the host". The host's command stays folded under Advanced, a last resort.
|
|
932
943
|
register("pendingHost", {
|
|
933
944
|
en: {
|
|
945
|
+
requestContextFloor: "Once on, AgEnD can't go back to an older version.",
|
|
934
946
|
no_chat: "This fleet has no chat app connected, so there is no General to send the confirm card to.",
|
|
935
947
|
no_chat_do: "To confirm from Discord or Telegram instead, connect one in Settings → Chat & connections.",
|
|
936
948
|
cross_platform: "This change affects chat apps on more than one platform, so no single General can confirm it.",
|
|
@@ -963,6 +975,7 @@ register("pendingHost", {
|
|
|
963
975
|
moreHost: "On the computer running AgEnD, open AgEnD in its own browser and press Apply now on this card.",
|
|
964
976
|
},
|
|
965
977
|
"zh-TW": {
|
|
978
|
+
requestContextFloor: "開啟後就不能再降回舊版 AgEnD。",
|
|
966
979
|
no_chat: "這個 Fleet 沒有連接聊天平台,所以沒有 General 可以接收確認卡。",
|
|
967
980
|
no_chat_do: "若要改從 Discord 或 Telegram 確認,請到「設定 → 聊天與連線」連接其中一個。",
|
|
968
981
|
cross_platform: "這項變更涉及多個聊天平台,沒有單一的 General 可以確認。",
|
|
@@ -1075,7 +1088,7 @@ function PendingHow({ p }) {
|
|
|
1075
1088
|
const mode = p.applyNow ? "apply" : p.confirmWithCode ? "code" : p.totpNotSetUp ? "setup" : p.onHost ? "link" : p.hostOnly ? "hostOnly" : "none";
|
|
1076
1089
|
if (!cli && (mode === "none" || mode === "apply")) {
|
|
1077
1090
|
const lead = c.kind === "posting" ? t("app.pendingPosting") : t("app.pendingChatWhere", whereText(c.where));
|
|
1078
|
-
return html`<p class="note">${lead}</p
|
|
1091
|
+
return html`${!p.applyNow ? html`<p class="note">${lead}</p>` : null}
|
|
1079
1092
|
${p.applyNow ? html`<div class="pending-self"><span class="note">${t("app.pendingSelf")}</span>
|
|
1080
1093
|
<button type="button" class="btn btn-sm btn-primary" onClick=${apply}>${t("app.pendingApplyNow")}</button></div>` : null}
|
|
1081
1094
|
${refused && !p.applyNow ? html`<p class="note" role="status">${t("app.pendingApplyRefused")}</p>` : null}
|
|
@@ -1184,7 +1197,7 @@ export function retryable(load) {
|
|
|
1184
1197
|
}
|
|
1185
1198
|
|
|
1186
1199
|
/** Shows the panel for the route, loading its module the first time; Retry is a real new attempt. */
|
|
1187
|
-
export function Outlet({ route, seq, panels }) {
|
|
1200
|
+
export function Outlet({ route, seq, panels, loading = null }) {
|
|
1188
1201
|
const [attempt, setAttempt] = useState(0);
|
|
1189
1202
|
const [, force] = useState(0);
|
|
1190
1203
|
const entry = route ? panels.get(route.panel) : null;
|
|
@@ -1204,7 +1217,7 @@ export function Outlet({ route, seq, panels }) {
|
|
|
1204
1217
|
// #3822: a panel that would not link (this tab is older than AgEnD) needs a reload, not a Retry that loads the same old copy.
|
|
1205
1218
|
if (entry && entry.error && !entry.loading) return html`<div class="panel">${isStaleModuleError(entry.error) ? html`<${StaleTabPrompt} />`
|
|
1206
1219
|
: html`<${ErrorState} onRetry=${() => setAttempt(n => n + 1)} />`}</div>`;
|
|
1207
|
-
if (!entry || !entry.Component) return html`<div class="panel"><${Skeleton} lines=${4} /></div>`;
|
|
1220
|
+
if (!entry || !entry.Component) return loading ?? html`<div class="panel"><${Skeleton} lines=${4} /></div>`;
|
|
1208
1221
|
const C = entry.Component;
|
|
1209
1222
|
return html`<${C} route=${route} navKey=${`${routeKey(route)}|${seq}|${lang()}`} />`;
|
|
1210
1223
|
}
|
|
@@ -42,13 +42,15 @@
|
|
|
42
42
|
// alpha.2 (M-2300): agent_proposals — an agent's Windows request came or was decided (no details: a web-only fleet's
|
|
43
43
|
// owner reads GET /ui/agent-proposals).
|
|
44
44
|
// tasks — the task board changed: the card numbers a write touched (SSE only: the board reads again when it is shown).
|
|
45
|
+
// task_wakes — where a comment of a card stands changed (a notice was handed to delivery, delivered, read, failed): `{ ids }`, the card
|
|
46
|
+
// numbers and nothing else (SSE only: an open card reads itself again, and the unread is read again).
|
|
45
47
|
// offices — the stored offices changed ({ rev }; SSE only: the Office view reads /ui/offices again).
|
|
46
48
|
// office_skins — a skin pack was uploaded or deleted ({ rev }; SSE only: the Office view reads /ui/office-skins again).
|
|
47
49
|
// office_acts — the agents' live acts in the Office view changed ({ acts }, #2578; a poll page reads /ui/office-acts).
|
|
48
50
|
// pins — an agent's pinned messages changed ({ instance, rev }, M-3271; SSE only: its open chat reads /ui/pins again).
|
|
49
51
|
// contact-auth — an agent's contact permissions or one of its contact requests changed ({ instance, ticketId?, revision },
|
|
50
52
|
// M-3339; SSE only: an open Permissions tab or Authorizations page reads its own scoped route again).
|
|
51
|
-
const EVENTS = ["status", "message", "agent_reply_live", "delivery", "deliveries", "prompt", "prompts", "prompt_resolved", "activity", "needs", "reply_buttons", "reactions", "steps_tick", "clock", "traffic", "delegation", "backend_login", "models", "tasks", "offices", "office_skins", "office_acts", "office_pack_changes", "agent_proposals", "pins", "contact-auth", "notice"];
|
|
53
|
+
const EVENTS = ["status", "message", "agent_reply_live", "delivery", "deliveries", "prompt", "prompts", "prompt_resolved", "activity", "needs", "reply_buttons", "reactions", "steps_tick", "clock", "traffic", "delegation", "backend_login", "models", "tasks", "task_wakes", "offices", "office_skins", "office_acts", "office_pack_changes", "agent_proposals", "pins", "contact-auth", "notice"];
|
|
52
54
|
const MAX_HELD = 1000; // live events held during one catch-up read; more → read again afterwards
|
|
53
55
|
const RETRY_DELAYS = [1000, 2000, 4000]; // after the first failed catch-up read; then it waits for Retry
|
|
54
56
|
const POLL_LIMIT_MS = 10000; // a poll that has not answered by then counts as failed
|
|
@@ -164,6 +166,7 @@ export function createStream(opts) {
|
|
|
164
166
|
if (Array.isArray(d.reply_buttons)) for (const u of d.reply_buttons) emit("reply_buttons", u); // #1266
|
|
165
167
|
if (Array.isArray(d.reactions)) for (const u of d.reactions) emit("reactions", u); // #2305
|
|
166
168
|
if (Array.isArray(d.needs)) emit("needs", { items: d.needs });
|
|
169
|
+
if (Object.hasOwn(d, "requestContextCutover")) emit("request-context-control", d.requestContextCutover);
|
|
167
170
|
return true;
|
|
168
171
|
} catch { return false; /* the next tick, or the catch-up's retry, tries again */ }
|
|
169
172
|
})();
|
|
@@ -308,4 +308,5 @@ export function UpdateLine() {
|
|
|
308
308
|
return html`${line}<${LogDialog} /><${PickTimeHost} />`;
|
|
309
309
|
}
|
|
310
310
|
/** M-3770 1.4: what update-card-ui.js needs from this module, passed in (it never imports this one). */
|
|
311
|
-
export const cardDeps = { refresh: () => refreshUpdate(), setInfo: (info) => updateStore.set({ info }), getInfo: () => updateStore.get().info
|
|
311
|
+
export const cardDeps = { refresh: () => refreshUpdate(), setInfo: (info) => updateStore.set({ info }), getInfo: () => updateStore.get().info,
|
|
312
|
+
setStarting: (starting) => updateStore.set({ starting }) };
|