@agimon-ai/po-web-dashboard 0.0.0-alpha.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/LICENSE +29 -0
- package/README.md +10 -0
- package/dist/_virtual/_rolldown/runtime.cjs +23 -0
- package/dist/core.cjs +222 -0
- package/dist/core.d.mts +21 -0
- package/dist/core.mjs +21 -0
- package/dist/index.cjs +546 -0
- package/dist/index.d.mts +81 -0
- package/dist/index.mjs +81 -0
- package/dist/testing.cjs +18 -0
- package/dist/testing.d.mts +6 -0
- package/dist/testing.mjs +6 -0
- package/dist/types/auth.cjs +20 -0
- package/dist/types/auth.cjs.map +1 -0
- package/dist/types/auth.d.mts +160 -0
- package/dist/types/auth.d.mts.map +1 -0
- package/dist/types/auth.mjs +19 -0
- package/dist/types/auth.mjs.map +1 -0
- package/dist/types/bridge.d.mts +18 -0
- package/dist/types/bridge.d.mts.map +1 -0
- package/dist/types/devProxy.cjs +41 -0
- package/dist/types/devProxy.cjs.map +1 -0
- package/dist/types/devProxy.d.mts +54 -0
- package/dist/types/devProxy.d.mts.map +1 -0
- package/dist/types/devProxy.mjs +39 -0
- package/dist/types/devProxy.mjs.map +1 -0
- package/dist/types/hub.cjs +220 -0
- package/dist/types/hub.cjs.map +1 -0
- package/dist/types/hub.d.mts +447 -0
- package/dist/types/hub.d.mts.map +1 -0
- package/dist/types/hub.mjs +179 -0
- package/dist/types/hub.mjs.map +1 -0
- package/dist/types/media.cjs +75 -0
- package/dist/types/media.cjs.map +1 -0
- package/dist/types/media.d.mts +22 -0
- package/dist/types/media.d.mts.map +1 -0
- package/dist/types/media.mjs +70 -0
- package/dist/types/media.mjs.map +1 -0
- package/dist/types/notification.cjs +19 -0
- package/dist/types/notification.cjs.map +1 -0
- package/dist/types/notification.d.mts +10 -0
- package/dist/types/notification.d.mts.map +1 -0
- package/dist/types/notification.mjs +19 -0
- package/dist/types/notification.mjs.map +1 -0
- package/dist/types/remoteAccess.cjs +92 -0
- package/dist/types/remoteAccess.cjs.map +1 -0
- package/dist/types/remoteAccess.d.mts +214 -0
- package/dist/types/remoteAccess.d.mts.map +1 -0
- package/dist/types/remoteAccess.mjs +68 -0
- package/dist/types/remoteAccess.mjs.map +1 -0
- package/dist/types/session.cjs +23 -0
- package/dist/types/session.cjs.map +1 -0
- package/dist/types/session.d.mts +29 -0
- package/dist/types/session.d.mts.map +1 -0
- package/dist/types/session.mjs +18 -0
- package/dist/types/session.mjs.map +1 -0
- package/dist/types/sessionMcp.d.mts +56 -0
- package/dist/types/sessionMcp.d.mts.map +1 -0
- package/dist/types/settings.cjs +18 -0
- package/dist/types/settings.cjs.map +1 -0
- package/dist/types/settings.d.mts +126 -0
- package/dist/types/settings.d.mts.map +1 -0
- package/dist/types/settings.mjs +12 -0
- package/dist/types/settings.mjs.map +1 -0
- package/dist/types.cjs +101 -0
- package/dist/types.d.mts +11 -0
- package/dist/types.mjs +9 -0
- package/dist/views.cjs +120 -0
- package/dist/views.d.mts +56 -0
- package/dist/views.mjs +56 -0
- package/dist/web/components/MascotMark.cjs +18 -0
- package/dist/web/components/MascotMark.cjs.map +1 -0
- package/dist/web/components/MascotMark.d.mts +9 -0
- package/dist/web/components/MascotMark.d.mts.map +1 -0
- package/dist/web/components/MascotMark.mjs +18 -0
- package/dist/web/components/MascotMark.mjs.map +1 -0
- package/dist/web/components/PluginSurface.cjs +15 -0
- package/dist/web/components/PluginSurface.cjs.map +1 -0
- package/dist/web/components/PluginSurface.d.mts +13 -0
- package/dist/web/components/PluginSurface.d.mts.map +1 -0
- package/dist/web/components/PluginSurface.mjs +15 -0
- package/dist/web/components/PluginSurface.mjs.map +1 -0
- package/dist/web/components/QrCode.cjs +37 -0
- package/dist/web/components/QrCode.cjs.map +1 -0
- package/dist/web/components/QrCode.d.mts +22 -0
- package/dist/web/components/QrCode.d.mts.map +1 -0
- package/dist/web/components/QrCode.mjs +37 -0
- package/dist/web/components/QrCode.mjs.map +1 -0
- package/dist/web/components/Remote.fixture.cjs +73 -0
- package/dist/web/components/Remote.fixture.cjs.map +1 -0
- package/dist/web/components/Remote.fixture.mjs +72 -0
- package/dist/web/components/Remote.fixture.mjs.map +1 -0
- package/dist/web/components/SessionMcp.cjs +279 -0
- package/dist/web/components/SessionMcp.cjs.map +1 -0
- package/dist/web/components/SessionMcp.d.mts +12 -0
- package/dist/web/components/SessionMcp.d.mts.map +1 -0
- package/dist/web/components/SessionMcp.mjs +278 -0
- package/dist/web/components/SessionMcp.mjs.map +1 -0
- package/dist/web/components/Story.fixture.cjs +124 -0
- package/dist/web/components/Story.fixture.cjs.map +1 -0
- package/dist/web/components/Story.fixture.d.mts +19 -0
- package/dist/web/components/Story.fixture.d.mts.map +1 -0
- package/dist/web/components/Story.fixture.mjs +119 -0
- package/dist/web/components/Story.fixture.mjs.map +1 -0
- package/dist/web/components/Template.fixture.cjs +67 -0
- package/dist/web/components/Template.fixture.cjs.map +1 -0
- package/dist/web/components/Template.fixture.d.mts +7 -0
- package/dist/web/components/Template.fixture.d.mts.map +1 -0
- package/dist/web/components/Template.fixture.mjs +65 -0
- package/dist/web/components/Template.fixture.mjs.map +1 -0
- package/dist/web/components/ToolRendererBoundary.cjs +23 -0
- package/dist/web/components/ToolRendererBoundary.cjs.map +1 -0
- package/dist/web/components/ToolRendererBoundary.d.mts +23 -0
- package/dist/web/components/ToolRendererBoundary.d.mts.map +1 -0
- package/dist/web/components/ToolRendererBoundary.mjs +23 -0
- package/dist/web/components/ToolRendererBoundary.mjs.map +1 -0
- package/dist/web/features/activity/ActivityDock.cjs +271 -0
- package/dist/web/features/activity/ActivityDock.cjs.map +1 -0
- package/dist/web/features/activity/ActivityDock.d.mts +22 -0
- package/dist/web/features/activity/ActivityDock.d.mts.map +1 -0
- package/dist/web/features/activity/ActivityDock.mjs +271 -0
- package/dist/web/features/activity/ActivityDock.mjs.map +1 -0
- package/dist/web/features/activity/ContextItemDialog.cjs +276 -0
- package/dist/web/features/activity/ContextItemDialog.cjs.map +1 -0
- package/dist/web/features/activity/ContextItemDialog.d.mts +16 -0
- package/dist/web/features/activity/ContextItemDialog.d.mts.map +1 -0
- package/dist/web/features/activity/ContextItemDialog.mjs +276 -0
- package/dist/web/features/activity/ContextItemDialog.mjs.map +1 -0
- package/dist/web/features/activity/ContextPanel.cjs +248 -0
- package/dist/web/features/activity/ContextPanel.cjs.map +1 -0
- package/dist/web/features/activity/ContextPanel.d.mts +4 -0
- package/dist/web/features/activity/ContextPanel.d.mts.map +1 -0
- package/dist/web/features/activity/ContextPanel.mjs +248 -0
- package/dist/web/features/activity/ContextPanel.mjs.map +1 -0
- package/dist/web/features/activity/DockTabs.cjs +47 -0
- package/dist/web/features/activity/DockTabs.cjs.map +1 -0
- package/dist/web/features/activity/DockTabs.d.mts +9 -0
- package/dist/web/features/activity/DockTabs.d.mts.map +1 -0
- package/dist/web/features/activity/DockTabs.mjs +47 -0
- package/dist/web/features/activity/DockTabs.mjs.map +1 -0
- package/dist/web/features/connection/RefusedCard.cjs +76 -0
- package/dist/web/features/connection/RefusedCard.cjs.map +1 -0
- package/dist/web/features/connection/RefusedCard.d.mts +5 -0
- package/dist/web/features/connection/RefusedCard.d.mts.map +1 -0
- package/dist/web/features/connection/RefusedCard.mjs +76 -0
- package/dist/web/features/connection/RefusedCard.mjs.map +1 -0
- package/dist/web/features/dialogs/DialogOverlay.cjs +164 -0
- package/dist/web/features/dialogs/DialogOverlay.cjs.map +1 -0
- package/dist/web/features/dialogs/DialogOverlay.d.mts +15 -0
- package/dist/web/features/dialogs/DialogOverlay.d.mts.map +1 -0
- package/dist/web/features/dialogs/DialogOverlay.mjs +164 -0
- package/dist/web/features/dialogs/DialogOverlay.mjs.map +1 -0
- package/dist/web/features/leader/CommandPalette.cjs +390 -0
- package/dist/web/features/leader/CommandPalette.cjs.map +1 -0
- package/dist/web/features/leader/CommandPalette.d.mts +14 -0
- package/dist/web/features/leader/CommandPalette.d.mts.map +1 -0
- package/dist/web/features/leader/CommandPalette.mjs +390 -0
- package/dist/web/features/leader/CommandPalette.mjs.map +1 -0
- package/dist/web/features/remote/DevProxyTargets.cjs +122 -0
- package/dist/web/features/remote/DevProxyTargets.cjs.map +1 -0
- package/dist/web/features/remote/DevProxyTargets.d.mts +15 -0
- package/dist/web/features/remote/DevProxyTargets.d.mts.map +1 -0
- package/dist/web/features/remote/DevProxyTargets.mjs +122 -0
- package/dist/web/features/remote/DevProxyTargets.mjs.map +1 -0
- package/dist/web/features/remote/HandoverProgress.cjs +28 -0
- package/dist/web/features/remote/HandoverProgress.cjs.map +1 -0
- package/dist/web/features/remote/HandoverProgress.d.mts +12 -0
- package/dist/web/features/remote/HandoverProgress.d.mts.map +1 -0
- package/dist/web/features/remote/HandoverProgress.mjs +28 -0
- package/dist/web/features/remote/HandoverProgress.mjs.map +1 -0
- package/dist/web/features/remote/PairedDeviceList.cjs +37 -0
- package/dist/web/features/remote/PairedDeviceList.cjs.map +1 -0
- package/dist/web/features/remote/PairedDeviceList.d.mts +5 -0
- package/dist/web/features/remote/PairedDeviceList.d.mts.map +1 -0
- package/dist/web/features/remote/PairedDeviceList.mjs +37 -0
- package/dist/web/features/remote/PairedDeviceList.mjs.map +1 -0
- package/dist/web/features/remote/PairingApprovalDialog.cjs +65 -0
- package/dist/web/features/remote/PairingApprovalDialog.cjs.map +1 -0
- package/dist/web/features/remote/PairingApprovalDialog.d.mts +11 -0
- package/dist/web/features/remote/PairingApprovalDialog.d.mts.map +1 -0
- package/dist/web/features/remote/PairingApprovalDialog.mjs +65 -0
- package/dist/web/features/remote/PairingApprovalDialog.mjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessDialog.cjs +83 -0
- package/dist/web/features/remote/RemoteAccessDialog.cjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessDialog.d.mts +11 -0
- package/dist/web/features/remote/RemoteAccessDialog.d.mts.map +1 -0
- package/dist/web/features/remote/RemoteAccessDialog.mjs +83 -0
- package/dist/web/features/remote/RemoteAccessDialog.mjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessOptions.cjs +154 -0
- package/dist/web/features/remote/RemoteAccessOptions.cjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessOptions.d.mts +11 -0
- package/dist/web/features/remote/RemoteAccessOptions.d.mts.map +1 -0
- package/dist/web/features/remote/RemoteAccessOptions.mjs +154 -0
- package/dist/web/features/remote/RemoteAccessOptions.mjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessPairing.cjs +93 -0
- package/dist/web/features/remote/RemoteAccessPairing.cjs.map +1 -0
- package/dist/web/features/remote/RemoteAccessPairing.d.mts +5 -0
- package/dist/web/features/remote/RemoteAccessPairing.d.mts.map +1 -0
- package/dist/web/features/remote/RemoteAccessPairing.mjs +93 -0
- package/dist/web/features/remote/RemoteAccessPairing.mjs.map +1 -0
- package/dist/web/features/remote/SandboxWorkspaces.cjs +87 -0
- package/dist/web/features/remote/SandboxWorkspaces.cjs.map +1 -0
- package/dist/web/features/remote/SandboxWorkspaces.d.mts +7 -0
- package/dist/web/features/remote/SandboxWorkspaces.d.mts.map +1 -0
- package/dist/web/features/remote/SandboxWorkspaces.mjs +87 -0
- package/dist/web/features/remote/SandboxWorkspaces.mjs.map +1 -0
- package/dist/web/features/remote/TrustedDeviceList.cjs +65 -0
- package/dist/web/features/remote/TrustedDeviceList.cjs.map +1 -0
- package/dist/web/features/remote/TrustedDeviceList.d.mts +13 -0
- package/dist/web/features/remote/TrustedDeviceList.d.mts.map +1 -0
- package/dist/web/features/remote/TrustedDeviceList.mjs +64 -0
- package/dist/web/features/remote/TrustedDeviceList.mjs.map +1 -0
- package/dist/web/features/selection/SelectionBar.cjs +401 -0
- package/dist/web/features/selection/SelectionBar.cjs.map +1 -0
- package/dist/web/features/selection/SelectionBar.d.mts +14 -0
- package/dist/web/features/selection/SelectionBar.d.mts.map +1 -0
- package/dist/web/features/selection/SelectionBar.mjs +400 -0
- package/dist/web/features/selection/SelectionBar.mjs.map +1 -0
- package/dist/web/features/session/AgentLockPanel.cjs +31 -0
- package/dist/web/features/session/AgentLockPanel.cjs.map +1 -0
- package/dist/web/features/session/AgentLockPanel.mjs +31 -0
- package/dist/web/features/session/AgentLockPanel.mjs.map +1 -0
- package/dist/web/features/session/Composer.cjs +808 -0
- package/dist/web/features/session/Composer.cjs.map +1 -0
- package/dist/web/features/session/Composer.d.mts +21 -0
- package/dist/web/features/session/Composer.d.mts.map +1 -0
- package/dist/web/features/session/Composer.mjs +806 -0
- package/dist/web/features/session/Composer.mjs.map +1 -0
- package/dist/web/features/session/ComposerPrompt.cjs +47 -0
- package/dist/web/features/session/ComposerPrompt.cjs.map +1 -0
- package/dist/web/features/session/ComposerPrompt.d.mts +16 -0
- package/dist/web/features/session/ComposerPrompt.d.mts.map +1 -0
- package/dist/web/features/session/ComposerPrompt.mjs +47 -0
- package/dist/web/features/session/ComposerPrompt.mjs.map +1 -0
- package/dist/web/features/session/DormantPanel.cjs +61 -0
- package/dist/web/features/session/DormantPanel.cjs.map +1 -0
- package/dist/web/features/session/DormantPanel.d.mts +8 -0
- package/dist/web/features/session/DormantPanel.d.mts.map +1 -0
- package/dist/web/features/session/DormantPanel.mjs +61 -0
- package/dist/web/features/session/DormantPanel.mjs.map +1 -0
- package/dist/web/features/session/MentionPreviews.cjs +128 -0
- package/dist/web/features/session/MentionPreviews.cjs.map +1 -0
- package/dist/web/features/session/MentionPreviews.d.mts +17 -0
- package/dist/web/features/session/MentionPreviews.d.mts.map +1 -0
- package/dist/web/features/session/MentionPreviews.mjs +127 -0
- package/dist/web/features/session/MentionPreviews.mjs.map +1 -0
- package/dist/web/features/session/MessageMarkdown.cjs +20 -0
- package/dist/web/features/session/MessageMarkdown.cjs.map +1 -0
- package/dist/web/features/session/MessageMarkdown.d.mts +19 -0
- package/dist/web/features/session/MessageMarkdown.d.mts.map +1 -0
- package/dist/web/features/session/MessageMarkdown.mjs +20 -0
- package/dist/web/features/session/MessageMarkdown.mjs.map +1 -0
- package/dist/web/features/session/QueueSheet.cjs +189 -0
- package/dist/web/features/session/QueueSheet.cjs.map +1 -0
- package/dist/web/features/session/QueueSheet.d.mts +16 -0
- package/dist/web/features/session/QueueSheet.d.mts.map +1 -0
- package/dist/web/features/session/QueueSheet.mjs +189 -0
- package/dist/web/features/session/QueueSheet.mjs.map +1 -0
- package/dist/web/features/session/SessionActivity.cjs +88 -0
- package/dist/web/features/session/SessionActivity.cjs.map +1 -0
- package/dist/web/features/session/SessionActivity.d.mts +16 -0
- package/dist/web/features/session/SessionActivity.d.mts.map +1 -0
- package/dist/web/features/session/SessionActivity.mjs +87 -0
- package/dist/web/features/session/SessionActivity.mjs.map +1 -0
- package/dist/web/features/session/SessionTranscriptView.cjs +34 -0
- package/dist/web/features/session/SessionTranscriptView.cjs.map +1 -0
- package/dist/web/features/session/SessionTranscriptView.d.mts +16 -0
- package/dist/web/features/session/SessionTranscriptView.d.mts.map +1 -0
- package/dist/web/features/session/SessionTranscriptView.mjs +34 -0
- package/dist/web/features/session/SessionTranscriptView.mjs.map +1 -0
- package/dist/web/features/session/ThreadView.cjs +40 -0
- package/dist/web/features/session/ThreadView.cjs.map +1 -0
- package/dist/web/features/session/ThreadView.d.mts +18 -0
- package/dist/web/features/session/ThreadView.d.mts.map +1 -0
- package/dist/web/features/session/ThreadView.mjs +40 -0
- package/dist/web/features/session/ThreadView.mjs.map +1 -0
- package/dist/web/features/session/Timeline.cjs +620 -0
- package/dist/web/features/session/Timeline.cjs.map +1 -0
- package/dist/web/features/session/Timeline.d.mts +28 -0
- package/dist/web/features/session/Timeline.d.mts.map +1 -0
- package/dist/web/features/session/Timeline.mjs +619 -0
- package/dist/web/features/session/Timeline.mjs.map +1 -0
- package/dist/web/features/session/ToolCard.cjs +210 -0
- package/dist/web/features/session/ToolCard.cjs.map +1 -0
- package/dist/web/features/session/ToolCard.d.mts +16 -0
- package/dist/web/features/session/ToolCard.d.mts.map +1 -0
- package/dist/web/features/session/ToolCard.mjs +210 -0
- package/dist/web/features/session/ToolCard.mjs.map +1 -0
- package/dist/web/features/session/session.fixture.cjs +76 -0
- package/dist/web/features/session/session.fixture.cjs.map +1 -0
- package/dist/web/features/session/session.fixture.d.mts +6 -0
- package/dist/web/features/session/session.fixture.d.mts.map +1 -0
- package/dist/web/features/session/session.fixture.mjs +74 -0
- package/dist/web/features/session/session.fixture.mjs.map +1 -0
- package/dist/web/features/sessions/NewSessionDialog.cjs +70 -0
- package/dist/web/features/sessions/NewSessionDialog.cjs.map +1 -0
- package/dist/web/features/sessions/NewSessionDialog.d.mts +9 -0
- package/dist/web/features/sessions/NewSessionDialog.d.mts.map +1 -0
- package/dist/web/features/sessions/NewSessionDialog.mjs +70 -0
- package/dist/web/features/sessions/NewSessionDialog.mjs.map +1 -0
- package/dist/web/features/sessions/ResumeSessionDialog.cjs +131 -0
- package/dist/web/features/sessions/ResumeSessionDialog.cjs.map +1 -0
- package/dist/web/features/sessions/ResumeSessionDialog.d.mts +14 -0
- package/dist/web/features/sessions/ResumeSessionDialog.d.mts.map +1 -0
- package/dist/web/features/sessions/ResumeSessionDialog.mjs +131 -0
- package/dist/web/features/sessions/ResumeSessionDialog.mjs.map +1 -0
- package/dist/web/features/sessions/SessionRailDialogs.cjs +62 -0
- package/dist/web/features/sessions/SessionRailDialogs.cjs.map +1 -0
- package/dist/web/features/sessions/SessionRailDialogs.d.mts +10 -0
- package/dist/web/features/sessions/SessionRailDialogs.d.mts.map +1 -0
- package/dist/web/features/sessions/SessionRailDialogs.mjs +62 -0
- package/dist/web/features/sessions/SessionRailDialogs.mjs.map +1 -0
- package/dist/web/features/sessions/WelcomePanel.cjs +42 -0
- package/dist/web/features/sessions/WelcomePanel.cjs.map +1 -0
- package/dist/web/features/sessions/WelcomePanel.d.mts +16 -0
- package/dist/web/features/sessions/WelcomePanel.d.mts.map +1 -0
- package/dist/web/features/sessions/WelcomePanel.mjs +42 -0
- package/dist/web/features/sessions/WelcomePanel.mjs.map +1 -0
- package/dist/web/features/sessions/useNewSessionActions.cjs +38 -0
- package/dist/web/features/sessions/useNewSessionActions.cjs.map +1 -0
- package/dist/web/features/sessions/useNewSessionActions.d.mts +12 -0
- package/dist/web/features/sessions/useNewSessionActions.d.mts.map +1 -0
- package/dist/web/features/sessions/useNewSessionActions.mjs +38 -0
- package/dist/web/features/sessions/useNewSessionActions.mjs.map +1 -0
- package/dist/web/features/sessions/useSessionRail.cjs +302 -0
- package/dist/web/features/sessions/useSessionRail.cjs.map +1 -0
- package/dist/web/features/sessions/useSessionRail.d.mts +14 -0
- package/dist/web/features/sessions/useSessionRail.d.mts.map +1 -0
- package/dist/web/features/sessions/useSessionRail.mjs +302 -0
- package/dist/web/features/sessions/useSessionRail.mjs.map +1 -0
- package/dist/web/features/settings/AppearanceSettings.cjs +126 -0
- package/dist/web/features/settings/AppearanceSettings.cjs.map +1 -0
- package/dist/web/features/settings/AppearanceSettings.d.mts +12 -0
- package/dist/web/features/settings/AppearanceSettings.d.mts.map +1 -0
- package/dist/web/features/settings/AppearanceSettings.mjs +126 -0
- package/dist/web/features/settings/AppearanceSettings.mjs.map +1 -0
- package/dist/web/features/settings/ContributedSettings.cjs +257 -0
- package/dist/web/features/settings/ContributedSettings.cjs.map +1 -0
- package/dist/web/features/settings/ContributedSettings.d.mts +14 -0
- package/dist/web/features/settings/ContributedSettings.d.mts.map +1 -0
- package/dist/web/features/settings/ContributedSettings.mjs +257 -0
- package/dist/web/features/settings/ContributedSettings.mjs.map +1 -0
- package/dist/web/features/settings/ImageSettings.cjs +146 -0
- package/dist/web/features/settings/ImageSettings.cjs.map +1 -0
- package/dist/web/features/settings/ImageSettings.d.mts +12 -0
- package/dist/web/features/settings/ImageSettings.d.mts.map +1 -0
- package/dist/web/features/settings/ImageSettings.mjs +146 -0
- package/dist/web/features/settings/ImageSettings.mjs.map +1 -0
- package/dist/web/features/settings/LoginFlowDialog.cjs +226 -0
- package/dist/web/features/settings/LoginFlowDialog.cjs.map +1 -0
- package/dist/web/features/settings/LoginFlowDialog.d.mts +15 -0
- package/dist/web/features/settings/LoginFlowDialog.d.mts.map +1 -0
- package/dist/web/features/settings/LoginFlowDialog.mjs +225 -0
- package/dist/web/features/settings/LoginFlowDialog.mjs.map +1 -0
- package/dist/web/features/settings/NotificationSettings.cjs +69 -0
- package/dist/web/features/settings/NotificationSettings.cjs.map +1 -0
- package/dist/web/features/settings/NotificationSettings.d.mts +5 -0
- package/dist/web/features/settings/NotificationSettings.d.mts.map +1 -0
- package/dist/web/features/settings/NotificationSettings.mjs +69 -0
- package/dist/web/features/settings/NotificationSettings.mjs.map +1 -0
- package/dist/web/features/settings/PluginSettings.cjs +106 -0
- package/dist/web/features/settings/PluginSettings.cjs.map +1 -0
- package/dist/web/features/settings/PluginSettings.d.mts +10 -0
- package/dist/web/features/settings/PluginSettings.d.mts.map +1 -0
- package/dist/web/features/settings/PluginSettings.mjs +106 -0
- package/dist/web/features/settings/PluginSettings.mjs.map +1 -0
- package/dist/web/features/settings/ProviderSettings.cjs +323 -0
- package/dist/web/features/settings/ProviderSettings.cjs.map +1 -0
- package/dist/web/features/settings/ProviderSettings.d.mts +9 -0
- package/dist/web/features/settings/ProviderSettings.d.mts.map +1 -0
- package/dist/web/features/settings/ProviderSettings.mjs +323 -0
- package/dist/web/features/settings/ProviderSettings.mjs.map +1 -0
- package/dist/web/features/settings/RemoteControlSettings.cjs +50 -0
- package/dist/web/features/settings/RemoteControlSettings.cjs.map +1 -0
- package/dist/web/features/settings/RemoteControlSettings.d.mts +5 -0
- package/dist/web/features/settings/RemoteControlSettings.d.mts.map +1 -0
- package/dist/web/features/settings/RemoteControlSettings.mjs +50 -0
- package/dist/web/features/settings/RemoteControlSettings.mjs.map +1 -0
- package/dist/web/features/settings/RepositorySettings.cjs +318 -0
- package/dist/web/features/settings/RepositorySettings.cjs.map +1 -0
- package/dist/web/features/settings/RepositorySettings.d.mts +7 -0
- package/dist/web/features/settings/RepositorySettings.d.mts.map +1 -0
- package/dist/web/features/settings/RepositorySettings.mjs +318 -0
- package/dist/web/features/settings/RepositorySettings.mjs.map +1 -0
- package/dist/web/features/settings/RepositoryWorkspace.cjs +160 -0
- package/dist/web/features/settings/RepositoryWorkspace.cjs.map +1 -0
- package/dist/web/features/settings/RepositoryWorkspace.d.mts +10 -0
- package/dist/web/features/settings/RepositoryWorkspace.d.mts.map +1 -0
- package/dist/web/features/settings/RepositoryWorkspace.mjs +160 -0
- package/dist/web/features/settings/RepositoryWorkspace.mjs.map +1 -0
- package/dist/web/features/settings/SessionMcpSettings.cjs +488 -0
- package/dist/web/features/settings/SessionMcpSettings.cjs.map +1 -0
- package/dist/web/features/settings/SessionMcpSettings.d.mts +5 -0
- package/dist/web/features/settings/SessionMcpSettings.d.mts.map +1 -0
- package/dist/web/features/settings/SessionMcpSettings.mjs +488 -0
- package/dist/web/features/settings/SessionMcpSettings.mjs.map +1 -0
- package/dist/web/features/settings/SettingsMenu.cjs +135 -0
- package/dist/web/features/settings/SettingsMenu.cjs.map +1 -0
- package/dist/web/features/settings/SettingsMenu.d.mts +9 -0
- package/dist/web/features/settings/SettingsMenu.d.mts.map +1 -0
- package/dist/web/features/settings/SettingsMenu.mjs +135 -0
- package/dist/web/features/settings/SettingsMenu.mjs.map +1 -0
- package/dist/web/features/settings/SettingsPanelHost.cjs +32 -0
- package/dist/web/features/settings/SettingsPanelHost.cjs.map +1 -0
- package/dist/web/features/settings/SettingsPanelHost.d.mts +8 -0
- package/dist/web/features/settings/SettingsPanelHost.d.mts.map +1 -0
- package/dist/web/features/settings/SettingsPanelHost.mjs +32 -0
- package/dist/web/features/settings/SettingsPanelHost.mjs.map +1 -0
- package/dist/web/features/settings/TemplateSettings.cjs +177 -0
- package/dist/web/features/settings/TemplateSettings.cjs.map +1 -0
- package/dist/web/features/settings/TemplateSettings.d.mts +8 -0
- package/dist/web/features/settings/TemplateSettings.d.mts.map +1 -0
- package/dist/web/features/settings/TemplateSettings.mjs +177 -0
- package/dist/web/features/settings/TemplateSettings.mjs.map +1 -0
- package/dist/web/features/settings/TunnelSettings.cjs +182 -0
- package/dist/web/features/settings/TunnelSettings.cjs.map +1 -0
- package/dist/web/features/settings/TunnelSettings.d.mts +8 -0
- package/dist/web/features/settings/TunnelSettings.d.mts.map +1 -0
- package/dist/web/features/settings/TunnelSettings.mjs +182 -0
- package/dist/web/features/settings/TunnelSettings.mjs.map +1 -0
- package/dist/web/features/settings/settings.fixture.cjs +230 -0
- package/dist/web/features/settings/settings.fixture.cjs.map +1 -0
- package/dist/web/features/settings/settings.fixture.d.mts +6 -0
- package/dist/web/features/settings/settings.fixture.d.mts.map +1 -0
- package/dist/web/features/settings/settings.fixture.mjs +223 -0
- package/dist/web/features/settings/settings.fixture.mjs.map +1 -0
- package/dist/web/features/status/TopBar.cjs +200 -0
- package/dist/web/features/status/TopBar.cjs.map +1 -0
- package/dist/web/features/status/TopBar.d.mts +11 -0
- package/dist/web/features/status/TopBar.d.mts.map +1 -0
- package/dist/web/features/status/TopBar.mjs +200 -0
- package/dist/web/features/status/TopBar.mjs.map +1 -0
- package/dist/web/lib/authApi.cjs +77 -0
- package/dist/web/lib/authApi.cjs.map +1 -0
- package/dist/web/lib/authApi.d.mts +28 -0
- package/dist/web/lib/authApi.d.mts.map +1 -0
- package/dist/web/lib/authApi.mjs +72 -0
- package/dist/web/lib/authApi.mjs.map +1 -0
- package/dist/web/lib/browserNotifications.cjs +37 -0
- package/dist/web/lib/browserNotifications.cjs.map +1 -0
- package/dist/web/lib/browserNotifications.d.mts +12 -0
- package/dist/web/lib/browserNotifications.d.mts.map +1 -0
- package/dist/web/lib/browserNotifications.mjs +35 -0
- package/dist/web/lib/browserNotifications.mjs.map +1 -0
- package/dist/web/lib/browserTelemetry.cjs +158 -0
- package/dist/web/lib/browserTelemetry.cjs.map +1 -0
- package/dist/web/lib/browserTelemetry.d.mts +28 -0
- package/dist/web/lib/browserTelemetry.d.mts.map +1 -0
- package/dist/web/lib/browserTelemetry.mjs +154 -0
- package/dist/web/lib/browserTelemetry.mjs.map +1 -0
- package/dist/web/lib/commands.cjs +176 -0
- package/dist/web/lib/commands.cjs.map +1 -0
- package/dist/web/lib/commands.d.mts +53 -0
- package/dist/web/lib/commands.d.mts.map +1 -0
- package/dist/web/lib/commands.mjs +153 -0
- package/dist/web/lib/commands.mjs.map +1 -0
- package/dist/web/lib/composerSubmissions.cjs +20 -0
- package/dist/web/lib/composerSubmissions.cjs.map +1 -0
- package/dist/web/lib/composerSubmissions.d.mts +7 -0
- package/dist/web/lib/composerSubmissions.d.mts.map +1 -0
- package/dist/web/lib/composerSubmissions.mjs +19 -0
- package/dist/web/lib/composerSubmissions.mjs.map +1 -0
- package/dist/web/lib/composition.cjs +403 -0
- package/dist/web/lib/composition.cjs.map +1 -0
- package/dist/web/lib/composition.d.mts +137 -0
- package/dist/web/lib/composition.d.mts.map +1 -0
- package/dist/web/lib/composition.mjs +392 -0
- package/dist/web/lib/composition.mjs.map +1 -0
- package/dist/web/lib/contextComposition.cjs +132 -0
- package/dist/web/lib/contextComposition.cjs.map +1 -0
- package/dist/web/lib/contextComposition.d.mts +75 -0
- package/dist/web/lib/contextComposition.d.mts.map +1 -0
- package/dist/web/lib/contextComposition.mjs +127 -0
- package/dist/web/lib/contextComposition.mjs.map +1 -0
- package/dist/web/lib/contextDetailApi.cjs +61 -0
- package/dist/web/lib/contextDetailApi.cjs.map +1 -0
- package/dist/web/lib/contextDetailApi.d.mts +12 -0
- package/dist/web/lib/contextDetailApi.d.mts.map +1 -0
- package/dist/web/lib/contextDetailApi.mjs +61 -0
- package/dist/web/lib/contextDetailApi.mjs.map +1 -0
- package/dist/web/lib/dashboardRenderers.cjs +9 -0
- package/dist/web/lib/dashboardRenderers.cjs.map +1 -0
- package/dist/web/lib/dashboardRenderers.d.mts +12 -0
- package/dist/web/lib/dashboardRenderers.d.mts.map +1 -0
- package/dist/web/lib/dashboardRenderers.mjs +9 -0
- package/dist/web/lib/dashboardRenderers.mjs.map +1 -0
- package/dist/web/lib/dashboardRoute.cjs +27 -0
- package/dist/web/lib/dashboardRoute.cjs.map +1 -0
- package/dist/web/lib/dashboardRoute.d.mts +29 -0
- package/dist/web/lib/dashboardRoute.d.mts.map +1 -0
- package/dist/web/lib/dashboardRoute.mjs +26 -0
- package/dist/web/lib/dashboardRoute.mjs.map +1 -0
- package/dist/web/lib/dashboardTranscript.cjs +15 -0
- package/dist/web/lib/dashboardTranscript.cjs.map +1 -0
- package/dist/web/lib/dashboardTranscript.d.mts +6 -0
- package/dist/web/lib/dashboardTranscript.d.mts.map +1 -0
- package/dist/web/lib/dashboardTranscript.mjs +14 -0
- package/dist/web/lib/dashboardTranscript.mjs.map +1 -0
- package/dist/web/lib/devProxyApi.cjs +74 -0
- package/dist/web/lib/devProxyApi.cjs.map +1 -0
- package/dist/web/lib/devProxyApi.d.mts +21 -0
- package/dist/web/lib/devProxyApi.d.mts.map +1 -0
- package/dist/web/lib/devProxyApi.mjs +72 -0
- package/dist/web/lib/devProxyApi.mjs.map +1 -0
- package/dist/web/lib/fileMentions.cjs +30 -0
- package/dist/web/lib/fileMentions.cjs.map +1 -0
- package/dist/web/lib/fileMentions.d.mts +13 -0
- package/dist/web/lib/fileMentions.d.mts.map +1 -0
- package/dist/web/lib/fileMentions.mjs +29 -0
- package/dist/web/lib/fileMentions.mjs.map +1 -0
- package/dist/web/lib/hubApi.cjs +283 -0
- package/dist/web/lib/hubApi.cjs.map +1 -0
- package/dist/web/lib/hubApi.d.mts +109 -0
- package/dist/web/lib/hubApi.d.mts.map +1 -0
- package/dist/web/lib/hubApi.mjs +268 -0
- package/dist/web/lib/hubApi.mjs.map +1 -0
- package/dist/web/lib/leaderTree.cjs +150 -0
- package/dist/web/lib/leaderTree.cjs.map +1 -0
- package/dist/web/lib/leaderTree.d.mts +41 -0
- package/dist/web/lib/leaderTree.d.mts.map +1 -0
- package/dist/web/lib/leaderTree.mjs +149 -0
- package/dist/web/lib/leaderTree.mjs.map +1 -0
- package/dist/web/lib/livePush.cjs +97 -0
- package/dist/web/lib/livePush.cjs.map +1 -0
- package/dist/web/lib/livePush.d.mts +10 -0
- package/dist/web/lib/livePush.d.mts.map +1 -0
- package/dist/web/lib/livePush.mjs +94 -0
- package/dist/web/lib/livePush.mjs.map +1 -0
- package/dist/web/lib/modelContextAdapter.cjs +63 -0
- package/dist/web/lib/modelContextAdapter.cjs.map +1 -0
- package/dist/web/lib/modelContextAdapter.d.mts +11 -0
- package/dist/web/lib/modelContextAdapter.d.mts.map +1 -0
- package/dist/web/lib/modelContextAdapter.mjs +62 -0
- package/dist/web/lib/modelContextAdapter.mjs.map +1 -0
- package/dist/web/lib/piTransport.cjs +103 -0
- package/dist/web/lib/piTransport.cjs.map +1 -0
- package/dist/web/lib/piTransport.d.mts +8 -0
- package/dist/web/lib/piTransport.d.mts.map +1 -0
- package/dist/web/lib/piTransport.mjs +102 -0
- package/dist/web/lib/piTransport.mjs.map +1 -0
- package/dist/web/lib/pluginCompositions.cjs +57 -0
- package/dist/web/lib/pluginCompositions.cjs.map +1 -0
- package/dist/web/lib/pluginCompositions.d.mts +37 -0
- package/dist/web/lib/pluginCompositions.d.mts.map +1 -0
- package/dist/web/lib/pluginCompositions.mjs +52 -0
- package/dist/web/lib/pluginCompositions.mjs.map +1 -0
- package/dist/web/lib/pluginRegistry.cjs +675 -0
- package/dist/web/lib/pluginRegistry.cjs.map +1 -0
- package/dist/web/lib/pluginRegistry.d.mts +155 -0
- package/dist/web/lib/pluginRegistry.d.mts.map +1 -0
- package/dist/web/lib/pluginRegistry.mjs +633 -0
- package/dist/web/lib/pluginRegistry.mjs.map +1 -0
- package/dist/web/lib/pluginScopes.cjs +48 -0
- package/dist/web/lib/pluginScopes.cjs.map +1 -0
- package/dist/web/lib/pluginScopes.d.mts +8 -0
- package/dist/web/lib/pluginScopes.d.mts.map +1 -0
- package/dist/web/lib/pluginScopes.mjs +47 -0
- package/dist/web/lib/pluginScopes.mjs.map +1 -0
- package/dist/web/lib/pluginSlotProps.cjs +83 -0
- package/dist/web/lib/pluginSlotProps.cjs.map +1 -0
- package/dist/web/lib/pluginSlotProps.d.mts +21 -0
- package/dist/web/lib/pluginSlotProps.d.mts.map +1 -0
- package/dist/web/lib/pluginSlotProps.mjs +82 -0
- package/dist/web/lib/pluginSlotProps.mjs.map +1 -0
- package/dist/web/lib/promptFocus.cjs +30 -0
- package/dist/web/lib/promptFocus.cjs.map +1 -0
- package/dist/web/lib/promptFocus.d.mts +7 -0
- package/dist/web/lib/promptFocus.d.mts.map +1 -0
- package/dist/web/lib/promptFocus.mjs +29 -0
- package/dist/web/lib/promptFocus.mjs.map +1 -0
- package/dist/web/lib/protocolHubSocket.cjs +107 -0
- package/dist/web/lib/protocolHubSocket.cjs.map +1 -0
- package/dist/web/lib/protocolHubSocket.d.mts +18 -0
- package/dist/web/lib/protocolHubSocket.d.mts.map +1 -0
- package/dist/web/lib/protocolHubSocket.mjs +107 -0
- package/dist/web/lib/protocolHubSocket.mjs.map +1 -0
- package/dist/web/lib/protocolTimeline.cjs +86 -0
- package/dist/web/lib/protocolTimeline.cjs.map +1 -0
- package/dist/web/lib/protocolTimeline.d.mts +9 -0
- package/dist/web/lib/protocolTimeline.d.mts.map +1 -0
- package/dist/web/lib/protocolTimeline.mjs +85 -0
- package/dist/web/lib/protocolTimeline.mjs.map +1 -0
- package/dist/web/lib/qrMatrix.cjs +37 -0
- package/dist/web/lib/qrMatrix.cjs.map +1 -0
- package/dist/web/lib/qrMatrix.d.mts +5 -0
- package/dist/web/lib/qrMatrix.d.mts.map +1 -0
- package/dist/web/lib/qrMatrix.mjs +35 -0
- package/dist/web/lib/qrMatrix.mjs.map +1 -0
- package/dist/web/lib/remoteApi.cjs +100 -0
- package/dist/web/lib/remoteApi.cjs.map +1 -0
- package/dist/web/lib/remoteApi.d.mts +45 -0
- package/dist/web/lib/remoteApi.d.mts.map +1 -0
- package/dist/web/lib/remoteApi.mjs +92 -0
- package/dist/web/lib/remoteApi.mjs.map +1 -0
- package/dist/web/lib/sealedSession.cjs +81 -0
- package/dist/web/lib/sealedSession.cjs.map +1 -0
- package/dist/web/lib/sealedSession.d.mts +24 -0
- package/dist/web/lib/sealedSession.d.mts.map +1 -0
- package/dist/web/lib/sealedSession.mjs +75 -0
- package/dist/web/lib/sealedSession.mjs.map +1 -0
- package/dist/web/lib/sessionActivityRenderer.cjs +19 -0
- package/dist/web/lib/sessionActivityRenderer.cjs.map +1 -0
- package/dist/web/lib/sessionActivityRenderer.d.mts +10 -0
- package/dist/web/lib/sessionActivityRenderer.d.mts.map +1 -0
- package/dist/web/lib/sessionActivityRenderer.mjs +17 -0
- package/dist/web/lib/sessionActivityRenderer.mjs.map +1 -0
- package/dist/web/lib/sessionAsset.cjs +45 -0
- package/dist/web/lib/sessionAsset.cjs.map +1 -0
- package/dist/web/lib/sessionAsset.d.mts +17 -0
- package/dist/web/lib/sessionAsset.d.mts.map +1 -0
- package/dist/web/lib/sessionAsset.mjs +44 -0
- package/dist/web/lib/sessionAsset.mjs.map +1 -0
- package/dist/web/lib/sessionAvatar.cjs +18 -0
- package/dist/web/lib/sessionAvatar.cjs.map +1 -0
- package/dist/web/lib/sessionAvatar.d.mts +10 -0
- package/dist/web/lib/sessionAvatar.d.mts.map +1 -0
- package/dist/web/lib/sessionAvatar.mjs +18 -0
- package/dist/web/lib/sessionAvatar.mjs.map +1 -0
- package/dist/web/lib/sessionMcpApi.cjs +120 -0
- package/dist/web/lib/sessionMcpApi.cjs.map +1 -0
- package/dist/web/lib/sessionMcpApi.d.mts +27 -0
- package/dist/web/lib/sessionMcpApi.d.mts.map +1 -0
- package/dist/web/lib/sessionMcpApi.mjs +114 -0
- package/dist/web/lib/sessionMcpApi.mjs.map +1 -0
- package/dist/web/lib/sessionMcpPrompt.cjs +24 -0
- package/dist/web/lib/sessionMcpPrompt.cjs.map +1 -0
- package/dist/web/lib/sessionMcpPrompt.mjs +23 -0
- package/dist/web/lib/sessionMcpPrompt.mjs.map +1 -0
- package/dist/web/lib/sessionModel.cjs +970 -0
- package/dist/web/lib/sessionModel.cjs.map +1 -0
- package/dist/web/lib/sessionModel.d.mts +254 -0
- package/dist/web/lib/sessionModel.d.mts.map +1 -0
- package/dist/web/lib/sessionModel.mjs +958 -0
- package/dist/web/lib/sessionModel.mjs.map +1 -0
- package/dist/web/lib/sessionProtocolCommands.cjs +196 -0
- package/dist/web/lib/sessionProtocolCommands.cjs.map +1 -0
- package/dist/web/lib/sessionProtocolCommands.d.mts +15 -0
- package/dist/web/lib/sessionProtocolCommands.d.mts.map +1 -0
- package/dist/web/lib/sessionProtocolCommands.mjs +193 -0
- package/dist/web/lib/sessionProtocolCommands.mjs.map +1 -0
- package/dist/web/lib/sessionRailModel.cjs +107 -0
- package/dist/web/lib/sessionRailModel.cjs.map +1 -0
- package/dist/web/lib/sessionRailModel.d.mts +38 -0
- package/dist/web/lib/sessionRailModel.d.mts.map +1 -0
- package/dist/web/lib/sessionRailModel.mjs +104 -0
- package/dist/web/lib/sessionRailModel.mjs.map +1 -0
- package/dist/web/lib/sessionSummary.cjs +58 -0
- package/dist/web/lib/sessionSummary.cjs.map +1 -0
- package/dist/web/lib/sessionSummary.d.mts +39 -0
- package/dist/web/lib/sessionSummary.d.mts.map +1 -0
- package/dist/web/lib/sessionSummary.mjs +54 -0
- package/dist/web/lib/sessionSummary.mjs.map +1 -0
- package/dist/web/lib/sessionTranscriptRenderer.cjs +19 -0
- package/dist/web/lib/sessionTranscriptRenderer.cjs.map +1 -0
- package/dist/web/lib/sessionTranscriptRenderer.d.mts +11 -0
- package/dist/web/lib/sessionTranscriptRenderer.d.mts.map +1 -0
- package/dist/web/lib/sessionTranscriptRenderer.mjs +17 -0
- package/dist/web/lib/sessionTranscriptRenderer.mjs.map +1 -0
- package/dist/web/lib/settingsApi.cjs +237 -0
- package/dist/web/lib/settingsApi.cjs.map +1 -0
- package/dist/web/lib/settingsApi.d.mts +57 -0
- package/dist/web/lib/settingsApi.d.mts.map +1 -0
- package/dist/web/lib/settingsApi.mjs +230 -0
- package/dist/web/lib/settingsApi.mjs.map +1 -0
- package/dist/web/lib/settingsDraft.cjs +48 -0
- package/dist/web/lib/settingsDraft.cjs.map +1 -0
- package/dist/web/lib/settingsDraft.d.mts +28 -0
- package/dist/web/lib/settingsDraft.d.mts.map +1 -0
- package/dist/web/lib/settingsDraft.mjs +45 -0
- package/dist/web/lib/settingsDraft.mjs.map +1 -0
- package/dist/web/lib/settingsSections.cjs +108 -0
- package/dist/web/lib/settingsSections.cjs.map +1 -0
- package/dist/web/lib/settingsSections.d.mts +36 -0
- package/dist/web/lib/settingsSections.d.mts.map +1 -0
- package/dist/web/lib/settingsSections.mjs +105 -0
- package/dist/web/lib/settingsSections.mjs.map +1 -0
- package/dist/web/lib/statusLine.cjs +82 -0
- package/dist/web/lib/statusLine.cjs.map +1 -0
- package/dist/web/lib/statusLine.d.mts +27 -0
- package/dist/web/lib/statusLine.d.mts.map +1 -0
- package/dist/web/lib/statusLine.mjs +79 -0
- package/dist/web/lib/statusLine.mjs.map +1 -0
- package/dist/web/lib/stepUp.cjs +41 -0
- package/dist/web/lib/stepUp.cjs.map +1 -0
- package/dist/web/lib/stepUp.d.mts +18 -0
- package/dist/web/lib/stepUp.d.mts.map +1 -0
- package/dist/web/lib/stepUp.mjs +41 -0
- package/dist/web/lib/stepUp.mjs.map +1 -0
- package/dist/web/lib/templateCatalog.cjs +123 -0
- package/dist/web/lib/templateCatalog.cjs.map +1 -0
- package/dist/web/lib/templateCatalog.d.mts +38 -0
- package/dist/web/lib/templateCatalog.d.mts.map +1 -0
- package/dist/web/lib/templateCatalog.mjs +118 -0
- package/dist/web/lib/templateCatalog.mjs.map +1 -0
- package/dist/web/lib/threadRenderer.cjs +25 -0
- package/dist/web/lib/threadRenderer.cjs.map +1 -0
- package/dist/web/lib/threadRenderer.d.mts +17 -0
- package/dist/web/lib/threadRenderer.d.mts.map +1 -0
- package/dist/web/lib/threadRenderer.mjs +23 -0
- package/dist/web/lib/threadRenderer.mjs.map +1 -0
- package/dist/web/lib/timelineGroups.cjs +83 -0
- package/dist/web/lib/timelineGroups.cjs.map +1 -0
- package/dist/web/lib/timelineGroups.d.mts +36 -0
- package/dist/web/lib/timelineGroups.d.mts.map +1 -0
- package/dist/web/lib/timelineGroups.mjs +81 -0
- package/dist/web/lib/timelineGroups.mjs.map +1 -0
- package/dist/web/lib/toolCompletionTabs.cjs +98 -0
- package/dist/web/lib/toolCompletionTabs.cjs.map +1 -0
- package/dist/web/lib/toolCompletionTabs.d.mts +14 -0
- package/dist/web/lib/toolCompletionTabs.d.mts.map +1 -0
- package/dist/web/lib/toolCompletionTabs.mjs +98 -0
- package/dist/web/lib/toolCompletionTabs.mjs.map +1 -0
- package/dist/web/lib/toolMessageProps.cjs +19 -0
- package/dist/web/lib/toolMessageProps.cjs.map +1 -0
- package/dist/web/lib/toolMessageProps.d.mts +7 -0
- package/dist/web/lib/toolMessageProps.d.mts.map +1 -0
- package/dist/web/lib/toolMessageProps.mjs +19 -0
- package/dist/web/lib/toolMessageProps.mjs.map +1 -0
- package/dist/web/lib/toolPrompt.cjs +44 -0
- package/dist/web/lib/toolPrompt.cjs.map +1 -0
- package/dist/web/lib/toolPrompt.d.mts +34 -0
- package/dist/web/lib/toolPrompt.d.mts.map +1 -0
- package/dist/web/lib/toolPrompt.mjs +44 -0
- package/dist/web/lib/toolPrompt.mjs.map +1 -0
- package/dist/web/lib/transport.cjs +57 -0
- package/dist/web/lib/transport.cjs.map +1 -0
- package/dist/web/lib/transport.d.mts +40 -0
- package/dist/web/lib/transport.d.mts.map +1 -0
- package/dist/web/lib/transport.mjs +50 -0
- package/dist/web/lib/transport.mjs.map +1 -0
- package/dist/web/lib/useSessionMcp.cjs +65 -0
- package/dist/web/lib/useSessionMcp.cjs.map +1 -0
- package/dist/web/lib/useSessionMcp.d.mts +15 -0
- package/dist/web/lib/useSessionMcp.d.mts.map +1 -0
- package/dist/web/lib/useSessionMcp.mjs +65 -0
- package/dist/web/lib/useSessionMcp.mjs.map +1 -0
- package/dist/web/lib/webauthnClient.cjs +110 -0
- package/dist/web/lib/webauthnClient.cjs.map +1 -0
- package/dist/web/lib/webauthnClient.d.mts +32 -0
- package/dist/web/lib/webauthnClient.d.mts.map +1 -0
- package/dist/web/lib/webauthnClient.mjs +106 -0
- package/dist/web/lib/webauthnClient.mjs.map +1 -0
- package/dist/web/lib/webmcpSimulator.cjs +105 -0
- package/dist/web/lib/webmcpSimulator.cjs.map +1 -0
- package/dist/web/lib/webmcpSimulator.mjs +105 -0
- package/dist/web/lib/webmcpSimulator.mjs.map +1 -0
- package/dist/web/stores/captureStore.cjs +137 -0
- package/dist/web/stores/captureStore.cjs.map +1 -0
- package/dist/web/stores/captureStore.d.mts +13 -0
- package/dist/web/stores/captureStore.d.mts.map +1 -0
- package/dist/web/stores/captureStore.mjs +133 -0
- package/dist/web/stores/captureStore.mjs.map +1 -0
- package/dist/web/stores/composerStore.cjs +390 -0
- package/dist/web/stores/composerStore.cjs.map +1 -0
- package/dist/web/stores/composerStore.d.mts +101 -0
- package/dist/web/stores/composerStore.d.mts.map +1 -0
- package/dist/web/stores/composerStore.mjs +370 -0
- package/dist/web/stores/composerStore.mjs.map +1 -0
- package/dist/web/stores/composerSubmissionStore.cjs +88 -0
- package/dist/web/stores/composerSubmissionStore.cjs.map +1 -0
- package/dist/web/stores/composerSubmissionStore.d.mts +11 -0
- package/dist/web/stores/composerSubmissionStore.d.mts.map +1 -0
- package/dist/web/stores/composerSubmissionStore.mjs +87 -0
- package/dist/web/stores/composerSubmissionStore.mjs.map +1 -0
- package/dist/web/stores/dashboardStateStore.cjs +35 -0
- package/dist/web/stores/dashboardStateStore.cjs.map +1 -0
- package/dist/web/stores/dashboardStateStore.d.mts +11 -0
- package/dist/web/stores/dashboardStateStore.d.mts.map +1 -0
- package/dist/web/stores/dashboardStateStore.mjs +33 -0
- package/dist/web/stores/dashboardStateStore.mjs.map +1 -0
- package/dist/web/stores/devProxyStore.cjs +76 -0
- package/dist/web/stores/devProxyStore.cjs.map +1 -0
- package/dist/web/stores/devProxyStore.d.mts +25 -0
- package/dist/web/stores/devProxyStore.d.mts.map +1 -0
- package/dist/web/stores/devProxyStore.mjs +73 -0
- package/dist/web/stores/devProxyStore.mjs.map +1 -0
- package/dist/web/stores/dialogDraftStore.cjs +38 -0
- package/dist/web/stores/dialogDraftStore.cjs.map +1 -0
- package/dist/web/stores/dialogDraftStore.d.mts +13 -0
- package/dist/web/stores/dialogDraftStore.d.mts.map +1 -0
- package/dist/web/stores/dialogDraftStore.mjs +36 -0
- package/dist/web/stores/dialogDraftStore.mjs.map +1 -0
- package/dist/web/stores/fileLinkModesStore.cjs +20 -0
- package/dist/web/stores/fileLinkModesStore.cjs.map +1 -0
- package/dist/web/stores/fileLinkModesStore.d.mts +5 -0
- package/dist/web/stores/fileLinkModesStore.d.mts.map +1 -0
- package/dist/web/stores/fileLinkModesStore.mjs +20 -0
- package/dist/web/stores/fileLinkModesStore.mjs.map +1 -0
- package/dist/web/stores/menuStore.cjs +85 -0
- package/dist/web/stores/menuStore.cjs.map +1 -0
- package/dist/web/stores/menuStore.d.mts +42 -0
- package/dist/web/stores/menuStore.d.mts.map +1 -0
- package/dist/web/stores/menuStore.mjs +79 -0
- package/dist/web/stores/menuStore.mjs.map +1 -0
- package/dist/web/stores/newSessionStore.cjs +93 -0
- package/dist/web/stores/newSessionStore.cjs.map +1 -0
- package/dist/web/stores/newSessionStore.d.mts +30 -0
- package/dist/web/stores/newSessionStore.d.mts.map +1 -0
- package/dist/web/stores/newSessionStore.mjs +86 -0
- package/dist/web/stores/newSessionStore.mjs.map +1 -0
- package/dist/web/stores/pagedTranscriptStore.cjs +235 -0
- package/dist/web/stores/pagedTranscriptStore.cjs.map +1 -0
- package/dist/web/stores/pagedTranscriptStore.d.mts +12 -0
- package/dist/web/stores/pagedTranscriptStore.d.mts.map +1 -0
- package/dist/web/stores/pagedTranscriptStore.mjs +235 -0
- package/dist/web/stores/pagedTranscriptStore.mjs.map +1 -0
- package/dist/web/stores/paletteStore.cjs +37 -0
- package/dist/web/stores/paletteStore.cjs.map +1 -0
- package/dist/web/stores/paletteStore.d.mts +14 -0
- package/dist/web/stores/paletteStore.d.mts.map +1 -0
- package/dist/web/stores/paletteStore.mjs +34 -0
- package/dist/web/stores/paletteStore.mjs.map +1 -0
- package/dist/web/stores/railDialogStore.cjs +105 -0
- package/dist/web/stores/railDialogStore.cjs.map +1 -0
- package/dist/web/stores/railDialogStore.d.mts +32 -0
- package/dist/web/stores/railDialogStore.d.mts.map +1 -0
- package/dist/web/stores/railDialogStore.mjs +97 -0
- package/dist/web/stores/railDialogStore.mjs.map +1 -0
- package/dist/web/stores/remoteAccessStore.cjs +216 -0
- package/dist/web/stores/remoteAccessStore.cjs.map +1 -0
- package/dist/web/stores/remoteAccessStore.d.mts +48 -0
- package/dist/web/stores/remoteAccessStore.d.mts.map +1 -0
- package/dist/web/stores/remoteAccessStore.mjs +202 -0
- package/dist/web/stores/remoteAccessStore.mjs.map +1 -0
- package/dist/web/stores/sessionChannelHoldsStore.cjs +43 -0
- package/dist/web/stores/sessionChannelHoldsStore.cjs.map +1 -0
- package/dist/web/stores/sessionChannelHoldsStore.d.mts +9 -0
- package/dist/web/stores/sessionChannelHoldsStore.d.mts.map +1 -0
- package/dist/web/stores/sessionChannelHoldsStore.mjs +42 -0
- package/dist/web/stores/sessionChannelHoldsStore.mjs.map +1 -0
- package/dist/web/stores/sessionStore.cjs +610 -0
- package/dist/web/stores/sessionStore.cjs.map +1 -0
- package/dist/web/stores/sessionStore.d.mts +116 -0
- package/dist/web/stores/sessionStore.d.mts.map +1 -0
- package/dist/web/stores/sessionStore.mjs +568 -0
- package/dist/web/stores/sessionStore.mjs.map +1 -0
- package/dist/web/stores/sessionsStore.cjs +272 -0
- package/dist/web/stores/sessionsStore.cjs.map +1 -0
- package/dist/web/stores/sessionsStore.d.mts +74 -0
- package/dist/web/stores/sessionsStore.d.mts.map +1 -0
- package/dist/web/stores/sessionsStore.mjs +257 -0
- package/dist/web/stores/sessionsStore.mjs.map +1 -0
- package/dist/web/stores/settingsDraftStore.cjs +138 -0
- package/dist/web/stores/settingsDraftStore.cjs.map +1 -0
- package/dist/web/stores/settingsDraftStore.d.mts +27 -0
- package/dist/web/stores/settingsDraftStore.d.mts.map +1 -0
- package/dist/web/stores/settingsDraftStore.mjs +132 -0
- package/dist/web/stores/settingsDraftStore.mjs.map +1 -0
- package/dist/web/stores/templateStore.cjs +136 -0
- package/dist/web/stores/templateStore.cjs.map +1 -0
- package/dist/web/stores/templateStore.d.mts +20 -0
- package/dist/web/stores/templateStore.d.mts.map +1 -0
- package/dist/web/stores/templateStore.mjs +131 -0
- package/dist/web/stores/templateStore.mjs.map +1 -0
- package/dist/web/stores/themeStore.cjs +42 -0
- package/dist/web/stores/themeStore.cjs.map +1 -0
- package/dist/web/stores/themeStore.d.mts +20 -0
- package/dist/web/stores/themeStore.d.mts.map +1 -0
- package/dist/web/stores/themeStore.mjs +39 -0
- package/dist/web/stores/themeStore.mjs.map +1 -0
- package/dist/web/stores/threadStore.cjs +122 -0
- package/dist/web/stores/threadStore.cjs.map +1 -0
- package/dist/web/stores/threadStore.d.mts +24 -0
- package/dist/web/stores/threadStore.d.mts.map +1 -0
- package/dist/web/stores/threadStore.mjs +114 -0
- package/dist/web/stores/threadStore.mjs.map +1 -0
- package/dist/web/stores/toolPromptStore.cjs +15 -0
- package/dist/web/stores/toolPromptStore.cjs.map +1 -0
- package/dist/web/stores/toolPromptStore.d.mts +23 -0
- package/dist/web/stores/toolPromptStore.d.mts.map +1 -0
- package/dist/web/stores/toolPromptStore.mjs +14 -0
- package/dist/web/stores/toolPromptStore.mjs.map +1 -0
- package/dist/web/stores/transientTabsStore.cjs +66 -0
- package/dist/web/stores/transientTabsStore.cjs.map +1 -0
- package/dist/web/stores/transientTabsStore.d.mts +21 -0
- package/dist/web/stores/transientTabsStore.d.mts.map +1 -0
- package/dist/web/stores/transientTabsStore.mjs +59 -0
- package/dist/web/stores/transientTabsStore.mjs.map +1 -0
- package/dist/web/stores/uiStore.cjs +47 -0
- package/dist/web/stores/uiStore.cjs.map +1 -0
- package/dist/web/stores/uiStore.d.mts +18 -0
- package/dist/web/stores/uiStore.d.mts.map +1 -0
- package/dist/web/stores/uiStore.mjs +45 -0
- package/dist/web/stores/uiStore.mjs.map +1 -0
- package/dist/web/stores/useOpenTab.cjs +31 -0
- package/dist/web/stores/useOpenTab.cjs.map +1 -0
- package/dist/web/stores/useOpenTab.d.mts +9 -0
- package/dist/web/stores/useOpenTab.d.mts.map +1 -0
- package/dist/web/stores/useOpenTab.mjs +31 -0
- package/dist/web/stores/useOpenTab.mjs.map +1 -0
- package/dist/web/stores/usePluginSlotProps.cjs +115 -0
- package/dist/web/stores/usePluginSlotProps.cjs.map +1 -0
- package/dist/web/stores/usePluginSlotProps.d.mts +6 -0
- package/dist/web/stores/usePluginSlotProps.d.mts.map +1 -0
- package/dist/web/stores/usePluginSlotProps.mjs +115 -0
- package/dist/web/stores/usePluginSlotProps.mjs.map +1 -0
- package/dist/web/stores/useToolPrompt.cjs +42 -0
- package/dist/web/stores/useToolPrompt.cjs.map +1 -0
- package/dist/web/stores/useToolPrompt.d.mts +14 -0
- package/dist/web/stores/useToolPrompt.d.mts.map +1 -0
- package/dist/web/stores/useToolPrompt.mjs +42 -0
- package/dist/web/stores/useToolPrompt.mjs.map +1 -0
- package/dist/web/stores/useWebPluginRegistry.cjs +11 -0
- package/dist/web/stores/useWebPluginRegistry.cjs.map +1 -0
- package/dist/web/stores/useWebPluginRegistry.d.mts +5 -0
- package/dist/web/stores/useWebPluginRegistry.d.mts.map +1 -0
- package/dist/web/stores/useWebPluginRegistry.mjs +11 -0
- package/dist/web/stores/useWebPluginRegistry.mjs.map +1 -0
- package/dist/web/stores/workspaceAdmissionStore.cjs +67 -0
- package/dist/web/stores/workspaceAdmissionStore.cjs.map +1 -0
- package/dist/web/stores/workspaceAdmissionStore.d.mts +24 -0
- package/dist/web/stores/workspaceAdmissionStore.d.mts.map +1 -0
- package/dist/web/stores/workspaceAdmissionStore.mjs +64 -0
- package/dist/web/stores/workspaceAdmissionStore.mjs.map +1 -0
- package/dist/web/stores/workspacesStore.cjs +83 -0
- package/dist/web/stores/workspacesStore.cjs.map +1 -0
- package/dist/web/stores/workspacesStore.d.mts +17 -0
- package/dist/web/stores/workspacesStore.d.mts.map +1 -0
- package/dist/web/stores/workspacesStore.mjs +78 -0
- package/dist/web/stores/workspacesStore.mjs.map +1 -0
- package/llms.txt +3 -0
- package/package.json +107 -0
- package/styles/dashboard.css +2 -0
- package/styles/preview.css +3 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
//#region src/web/lib/settingsDraft.ts
|
|
2
|
+
/**
|
|
3
|
+
* What a settings page does with pending edits, kept out of the component so it
|
|
4
|
+
* can be checked without a browser.
|
|
5
|
+
*
|
|
6
|
+
* The rules that matter are all here: a field is only editable at a scope the
|
|
7
|
+
* key is actually read from, a cleared field removes the key rather than
|
|
8
|
+
* writing an empty value the parser rejects, and numeric drafts retain their
|
|
9
|
+
* type when the page combines these edits into one atomic save.
|
|
10
|
+
*/
|
|
11
|
+
const KEY_SEPARATOR = ".";
|
|
12
|
+
function settingsKeyOf(field) {
|
|
13
|
+
return field.keyPath.join(KEY_SEPARATOR);
|
|
14
|
+
}
|
|
15
|
+
/** Why a field cannot be edited at the selected scope, or nothing. */
|
|
16
|
+
function settingsLockedReason(view, scope) {
|
|
17
|
+
if (view === void 0 || view.scope === "both" || view.scope === scope) return void 0;
|
|
18
|
+
return view.scope === "global" ? "global only" : "repository only";
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* The typed edits a save combines into one request with the file's read hash.
|
|
22
|
+
* Keeping contribution order makes the result predictable for callers.
|
|
23
|
+
*/
|
|
24
|
+
function plannedSettingsWrites(input) {
|
|
25
|
+
return input.fields.filter((field) => settingsKeyOf(field) in input.drafts).map((field) => {
|
|
26
|
+
const draft = input.drafts[settingsKeyOf(field)] ?? null;
|
|
27
|
+
const numeric = field.kind === "number" && draft !== null && draft.trim() !== "" ? Number(draft) : void 0;
|
|
28
|
+
return {
|
|
29
|
+
repoRoot: input.repoRoot,
|
|
30
|
+
scope: input.scope,
|
|
31
|
+
keyPath: field.keyPath,
|
|
32
|
+
value: numeric !== void 0 && Number.isFinite(numeric) ? numeric : draft,
|
|
33
|
+
expectedHash: input.startingHash
|
|
34
|
+
};
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
/** Whether a save can be attempted at all: something changed, and it can land somewhere. */
|
|
38
|
+
function canSaveSettings(input) {
|
|
39
|
+
if (input.dirty === 0) return false;
|
|
40
|
+
return input.scope === "global" || input.repoRoot !== "";
|
|
41
|
+
}
|
|
42
|
+
//#endregion
|
|
43
|
+
export { canSaveSettings, plannedSettingsWrites, settingsKeyOf, settingsLockedReason };
|
|
44
|
+
|
|
45
|
+
//# sourceMappingURL=settingsDraft.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settingsDraft.mjs","names":[],"sources":["../../../src/web/lib/settingsDraft.ts"],"sourcesContent":["import type { SettingsFieldContribution } from '@agimon-ai/po-core/web';\n\nimport type { SettingsScope, SettingsValueView, SettingsWriteRequest } from '../../types/settings';\n\n/**\n * What a settings page does with pending edits, kept out of the component so it\n * can be checked without a browser.\n *\n * The rules that matter are all here: a field is only editable at a scope the\n * key is actually read from, a cleared field removes the key rather than\n * writing an empty value the parser rejects, and numeric drafts retain their\n * type when the page combines these edits into one atomic save.\n */\n\nconst KEY_SEPARATOR = '.';\n\nexport function settingsKeyOf(field: SettingsFieldContribution): string {\n return field.keyPath.join(KEY_SEPARATOR);\n}\n\n/** Why a field cannot be edited at the selected scope, or nothing. */\nexport function settingsLockedReason(view: SettingsValueView | undefined, scope: SettingsScope): string | undefined {\n if (view === undefined || view.scope === 'both' || view.scope === scope) return undefined;\n return view.scope === 'global' ? 'global only' : 'repository only';\n}\n\nexport interface PlannedWritesInput {\n fields: readonly SettingsFieldContribution[];\n /** Pending edits by dotted key; null clears the key. */\n drafts: Readonly<Record<string, string | null>>;\n scope: SettingsScope;\n repoRoot: string;\n /** The target file's hash when the page last read it. */\n startingHash: string;\n}\n\n/**\n * The typed edits a save combines into one request with the file's read hash.\n * Keeping contribution order makes the result predictable for callers.\n */\nexport function plannedSettingsWrites(input: PlannedWritesInput): SettingsWriteRequest[] {\n return input.fields\n .filter((field) => settingsKeyOf(field) in input.drafts)\n .map((field) => {\n const draft = input.drafts[settingsKeyOf(field)] ?? null;\n const numeric = field.kind === 'number' && draft !== null && draft.trim() !== '' ? Number(draft) : undefined;\n return {\n repoRoot: input.repoRoot,\n scope: input.scope,\n keyPath: field.keyPath,\n value: numeric !== undefined && Number.isFinite(numeric) ? numeric : draft,\n expectedHash: input.startingHash,\n };\n });\n}\n\n/** Whether a save can be attempted at all: something changed, and it can land somewhere. */\nexport function canSaveSettings(input: { dirty: number; scope: SettingsScope; repoRoot: string }): boolean {\n if (input.dirty === 0) return false;\n // A repository write needs a repository; a global one never does.\n return input.scope === 'global' || input.repoRoot !== '';\n}\n"],"mappings":";;;;;;;;;;AAcA,MAAM,gBAAgB;AAEtB,SAAgB,cAAc,OAA0C;CACtE,OAAO,MAAM,QAAQ,KAAK,aAAa;AACzC;;AAGA,SAAgB,qBAAqB,MAAqC,OAA0C;CAClH,IAAI,SAAS,KAAA,KAAa,KAAK,UAAU,UAAU,KAAK,UAAU,OAAO,OAAO,KAAA;CAChF,OAAO,KAAK,UAAU,WAAW,gBAAgB;AACnD;;;;;AAgBA,SAAgB,sBAAsB,OAAmD;CACvF,OAAO,MAAM,OACV,QAAQ,UAAU,cAAc,KAAK,KAAK,MAAM,MAAM,CAAC,CACvD,KAAK,UAAU;EACd,MAAM,QAAQ,MAAM,OAAO,cAAc,KAAK,MAAM;EACpD,MAAM,UAAU,MAAM,SAAS,YAAY,UAAU,QAAQ,MAAM,KAAK,MAAM,KAAK,OAAO,KAAK,IAAI,KAAA;EACnG,OAAO;GACL,UAAU,MAAM;GAChB,OAAO,MAAM;GACb,SAAS,MAAM;GACf,OAAO,YAAY,KAAA,KAAa,OAAO,SAAS,OAAO,IAAI,UAAU;GACrE,cAAc,MAAM;EACtB;CACF,CAAC;AACL;;AAGA,SAAgB,gBAAgB,OAA2E;CACzG,IAAI,MAAM,UAAU,GAAG,OAAO;CAE9B,OAAO,MAAM,UAAU,YAAY,MAAM,aAAa;AACxD"}
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
const require_pluginRegistry = require("./pluginRegistry.cjs");
|
|
2
|
+
//#region src/web/lib/settingsSections.ts
|
|
3
|
+
const GENERAL_SETTINGS_SECTIONS = [
|
|
4
|
+
{
|
|
5
|
+
id: "providers",
|
|
6
|
+
label: "providers",
|
|
7
|
+
detail: "sign in to the model providers Pi can use",
|
|
8
|
+
workspace: "general"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
id: "appearance",
|
|
12
|
+
label: "appearance",
|
|
13
|
+
detail: "pick the theme the cockpit renders with",
|
|
14
|
+
workspace: "general"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
id: "notifications",
|
|
18
|
+
label: "notifications",
|
|
19
|
+
detail: "allow live session notifications in this browser",
|
|
20
|
+
workspace: "general"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
id: "images",
|
|
24
|
+
label: "images",
|
|
25
|
+
detail: "how large an image may be when it reaches a model",
|
|
26
|
+
workspace: "general"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
id: "remote",
|
|
30
|
+
label: "remote control",
|
|
31
|
+
detail: "save a named tunnel and expose live sessions to MCP clients",
|
|
32
|
+
workspace: "general"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
id: "plugins",
|
|
36
|
+
label: "plugins",
|
|
37
|
+
detail: "the web plugins this bundle carries and what their install resolved",
|
|
38
|
+
workspace: "general"
|
|
39
|
+
}
|
|
40
|
+
];
|
|
41
|
+
const REPOSITORY_DEFAULTS_SECTION = {
|
|
42
|
+
id: "repositories",
|
|
43
|
+
label: "defaults",
|
|
44
|
+
detail: "mode, domains, and profile",
|
|
45
|
+
workspace: "repository"
|
|
46
|
+
};
|
|
47
|
+
const DEFAULT_CONTRIBUTED_ORDER = 1e3;
|
|
48
|
+
/** Repository-workspace copies need their own route id, since the id is the route param. */
|
|
49
|
+
const REPOSITORY_SECTION_PREFIX = "repository-";
|
|
50
|
+
const DEFAULT_SETTINGS_SECTION = GENERAL_SETTINGS_SECTIONS[0].id;
|
|
51
|
+
const DEFAULT_REPOSITORY_SETTINGS_SECTION = REPOSITORY_DEFAULTS_SECTION.id;
|
|
52
|
+
function byMenuOrder(left, right) {
|
|
53
|
+
return (left.order ?? DEFAULT_CONTRIBUTED_ORDER) - (right.order ?? DEFAULT_CONTRIBUTED_ORDER) || left.id.localeCompare(right.id);
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Every page the menu offers. Read through a function rather than held in a
|
|
57
|
+
* const: plugins install before the first render, but a module-level array
|
|
58
|
+
* evaluated at import time would freeze the list before that happened.
|
|
59
|
+
*/
|
|
60
|
+
function settingsSections(workspace) {
|
|
61
|
+
const contributed = [...require_pluginRegistry.pluginSettingsSections()].sort(byMenuOrder).map((contribution) => ({
|
|
62
|
+
id: contribution.id,
|
|
63
|
+
label: contribution.label,
|
|
64
|
+
detail: contribution.detail,
|
|
65
|
+
workspace: "general",
|
|
66
|
+
contribution
|
|
67
|
+
}));
|
|
68
|
+
const contributedForRepository = [...require_pluginRegistry.pluginSettingsSections("workspace")].sort(byMenuOrder).map((contribution) => ({
|
|
69
|
+
id: `${REPOSITORY_SECTION_PREFIX}${contribution.id}`,
|
|
70
|
+
label: contribution.label,
|
|
71
|
+
detail: contribution.detail,
|
|
72
|
+
workspace: "repository",
|
|
73
|
+
contribution
|
|
74
|
+
}));
|
|
75
|
+
const panels = [...require_pluginRegistry.pluginSettingsPanels()].sort(byMenuOrder).map((panel) => ({
|
|
76
|
+
id: panel.id,
|
|
77
|
+
label: panel.label,
|
|
78
|
+
detail: panel.detail,
|
|
79
|
+
workspace: "general",
|
|
80
|
+
panel
|
|
81
|
+
}));
|
|
82
|
+
const repositoryPanels = require_pluginRegistry.pluginRepositorySettingsPanels().map((repositoryPanel) => ({
|
|
83
|
+
id: `${REPOSITORY_SECTION_PREFIX}${repositoryPanel.pluginId}`,
|
|
84
|
+
label: repositoryPanel.label,
|
|
85
|
+
detail: repositoryPanel.detail,
|
|
86
|
+
workspace: "repository",
|
|
87
|
+
repositoryPanel
|
|
88
|
+
}));
|
|
89
|
+
const all = [
|
|
90
|
+
...GENERAL_SETTINGS_SECTIONS,
|
|
91
|
+
...contributed,
|
|
92
|
+
...panels,
|
|
93
|
+
REPOSITORY_DEFAULTS_SECTION,
|
|
94
|
+
...repositoryPanels,
|
|
95
|
+
...contributedForRepository
|
|
96
|
+
];
|
|
97
|
+
return workspace === void 0 ? all : all.filter((section) => section.workspace === workspace);
|
|
98
|
+
}
|
|
99
|
+
function settingsSection(id) {
|
|
100
|
+
return settingsSections().find((section) => section.id === id);
|
|
101
|
+
}
|
|
102
|
+
//#endregion
|
|
103
|
+
exports.DEFAULT_REPOSITORY_SETTINGS_SECTION = DEFAULT_REPOSITORY_SETTINGS_SECTION;
|
|
104
|
+
exports.DEFAULT_SETTINGS_SECTION = DEFAULT_SETTINGS_SECTION;
|
|
105
|
+
exports.settingsSection = settingsSection;
|
|
106
|
+
exports.settingsSections = settingsSections;
|
|
107
|
+
|
|
108
|
+
//# sourceMappingURL=settingsSections.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settingsSections.cjs","names":["pluginSettingsSections","pluginSettingsPanels","pluginRepositorySettingsPanels"],"sources":["../../../src/web/lib/settingsSections.ts"],"sourcesContent":["import type { SettingsSectionContribution } from '@agimon-ai/po-core/web';\n\nimport {\n pluginRepositorySettingsPanels,\n pluginSettingsPanels,\n pluginSettingsSections,\n type InstalledRepositorySettingsPanel,\n type InstalledSettingsPanel,\n} from './pluginRegistry';\n\n/**\n * The settings menu, as data: the rail's gear and the settings page both\n * need to name a section, and neither feature may import the other.\n *\n * The host's own pages come first and keep fixed positions, because they\n * are about the cockpit itself rather than about a package. Contributed pages\n * sort after them, by their declared order and then their id, so the menu is\n * stable across syncs whatever order plugins install in.\n */\nexport type SettingsWorkspace = 'general' | 'repository';\n\nexport interface SettingsSection {\n id: string;\n label: string;\n detail: string;\n workspace: SettingsWorkspace;\n /** The fields a contributed page renders; absent on the host's own pages. */\n contribution?: SettingsSectionContribution;\n /** Package panel hosted inside the repository workspace. */\n repositoryPanel?: InstalledRepositorySettingsPanel;\n /** A page the contributing package draws itself, rather than fields the host renders. */\n panel?: InstalledSettingsPanel;\n}\n\nconst GENERAL_SETTINGS_SECTIONS: readonly SettingsSection[] = [\n {\n id: 'providers',\n label: 'providers',\n detail: 'sign in to the model providers Pi can use',\n workspace: 'general',\n },\n {\n id: 'appearance',\n label: 'appearance',\n detail: 'pick the theme the cockpit renders with',\n workspace: 'general',\n },\n {\n id: 'notifications',\n label: 'notifications',\n detail: 'allow live session notifications in this browser',\n workspace: 'general',\n },\n {\n id: 'images',\n label: 'images',\n detail: 'how large an image may be when it reaches a model',\n workspace: 'general',\n },\n {\n id: 'remote',\n label: 'remote control',\n detail: 'save a named tunnel and expose live sessions to MCP clients',\n workspace: 'general',\n },\n {\n id: 'plugins',\n label: 'plugins',\n detail: 'the web plugins this bundle carries and what their install resolved',\n workspace: 'general',\n },\n];\n\nconst REPOSITORY_DEFAULTS_SECTION: SettingsSection = {\n id: 'repositories',\n label: 'defaults',\n detail: 'mode, domains, and profile',\n workspace: 'repository',\n};\n\nconst DEFAULT_CONTRIBUTED_ORDER = 1000;\n\n/** Repository-workspace copies need their own route id, since the id is the route param. */\nconst REPOSITORY_SECTION_PREFIX = 'repository-';\n\nexport const DEFAULT_SETTINGS_SECTION = GENERAL_SETTINGS_SECTIONS[0]!.id;\nexport const DEFAULT_REPOSITORY_SETTINGS_SECTION = REPOSITORY_DEFAULTS_SECTION.id;\n\ninterface MenuOrdered {\n id: string;\n order?: number;\n}\n\nfunction byMenuOrder(left: MenuOrdered, right: MenuOrdered): number {\n return (\n (left.order ?? DEFAULT_CONTRIBUTED_ORDER) - (right.order ?? DEFAULT_CONTRIBUTED_ORDER) ||\n left.id.localeCompare(right.id)\n );\n}\n\n/**\n * Every page the menu offers. Read through a function rather than held in a\n * const: plugins install before the first render, but a module-level array\n * evaluated at import time would freeze the list before that happened.\n */\nexport function settingsSections(workspace?: SettingsWorkspace): readonly SettingsSection[] {\n const contributions = [...pluginSettingsSections()].sort(byMenuOrder);\n // The same page is offered in both workspaces. Scope comes from the workspace\n // the reader is in, so the general copy edits the global file and the\n // repository copy edits whichever repository the workspace picker holds.\n const contributed = contributions.map((contribution) => ({\n id: contribution.id,\n label: contribution.label,\n detail: contribution.detail,\n workspace: 'general' as const,\n contribution,\n }));\n const contributedForRepository = [...pluginSettingsSections('workspace')].sort(byMenuOrder).map((contribution) => ({\n id: `${REPOSITORY_SECTION_PREFIX}${contribution.id}`,\n label: contribution.label,\n detail: contribution.detail,\n workspace: 'repository' as const,\n contribution,\n }));\n // A self-drawn page has no scope to switch: it reports rather than writes,\n // so it appears once, in the general workspace, and not as a repository copy.\n const panels = [...pluginSettingsPanels()].sort(byMenuOrder).map((panel) => ({\n id: panel.id,\n label: panel.label,\n detail: panel.detail,\n workspace: 'general' as const,\n panel,\n }));\n const repositoryPanels = pluginRepositorySettingsPanels().map((repositoryPanel) => ({\n id: `${REPOSITORY_SECTION_PREFIX}${repositoryPanel.pluginId}`,\n label: repositoryPanel.label,\n detail: repositoryPanel.detail,\n workspace: 'repository' as const,\n repositoryPanel,\n }));\n const all = [\n ...GENERAL_SETTINGS_SECTIONS,\n ...contributed,\n ...panels,\n REPOSITORY_DEFAULTS_SECTION,\n ...repositoryPanels,\n ...contributedForRepository,\n ];\n return workspace === undefined ? all : all.filter((section) => section.workspace === workspace);\n}\n\nexport function settingsSection(id: string | undefined): SettingsSection | undefined {\n return settingsSections().find((section) => section.id === id);\n}\n"],"mappings":";;AAkCA,MAAM,4BAAwD;CAC5D;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;AACF;AAEA,MAAM,8BAA+C;CACnD,IAAI;CACJ,OAAO;CACP,QAAQ;CACR,WAAW;AACb;AAEA,MAAM,4BAA4B;;AAGlC,MAAM,4BAA4B;AAElC,MAAa,2BAA2B,0BAA0B,EAAE,CAAE;AACtE,MAAa,sCAAsC,4BAA4B;AAO/E,SAAS,YAAY,MAAmB,OAA4B;CAClE,QACG,KAAK,SAAS,8BAA8B,MAAM,SAAS,8BAC5D,KAAK,GAAG,cAAc,MAAM,EAAE;AAElC;;;;;;AAOA,SAAgB,iBAAiB,WAA2D;CAK1F,MAAM,cAJgB,CAAC,GAAGA,uBAAAA,uBAAuB,CAAC,CAAC,CAAC,KAAK,WAIzB,CAAC,CAAC,KAAK,kBAAkB;EACvD,IAAI,aAAa;EACjB,OAAO,aAAa;EACpB,QAAQ,aAAa;EACrB,WAAW;EACX;CACF,EAAE;CACF,MAAM,2BAA2B,CAAC,GAAGA,uBAAAA,uBAAuB,WAAW,CAAC,CAAC,CAAC,KAAK,WAAW,CAAC,CAAC,KAAK,kBAAkB;EACjH,IAAI,GAAG,4BAA4B,aAAa;EAChD,OAAO,aAAa;EACpB,QAAQ,aAAa;EACrB,WAAW;EACX;CACF,EAAE;CAGF,MAAM,SAAS,CAAC,GAAGC,uBAAAA,qBAAqB,CAAC,CAAC,CAAC,KAAK,WAAW,CAAC,CAAC,KAAK,WAAW;EAC3E,IAAI,MAAM;EACV,OAAO,MAAM;EACb,QAAQ,MAAM;EACd,WAAW;EACX;CACF,EAAE;CACF,MAAM,mBAAmBC,uBAAAA,+BAA+B,CAAC,CAAC,KAAK,qBAAqB;EAClF,IAAI,GAAG,4BAA4B,gBAAgB;EACnD,OAAO,gBAAgB;EACvB,QAAQ,gBAAgB;EACxB,WAAW;EACX;CACF,EAAE;CACF,MAAM,MAAM;EACV,GAAG;EACH,GAAG;EACH,GAAG;EACH;EACA,GAAG;EACH,GAAG;CACL;CACA,OAAO,cAAc,KAAA,IAAY,MAAM,IAAI,QAAQ,YAAY,QAAQ,cAAc,SAAS;AAChG;AAEA,SAAgB,gBAAgB,IAAqD;CACnF,OAAO,iBAAiB,CAAC,CAAC,MAAM,YAAY,QAAQ,OAAO,EAAE;AAC/D"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { InstalledRepositorySettingsPanel, InstalledSettingsPanel } from "./pluginRegistry.mjs";
|
|
2
|
+
import { SettingsSectionContribution } from "@agimon-ai/po-core/web";
|
|
3
|
+
//#region src/web/lib/settingsSections.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* The settings menu, as data: the rail's gear and the settings page both
|
|
6
|
+
* need to name a section, and neither feature may import the other.
|
|
7
|
+
*
|
|
8
|
+
* The host's own pages come first and keep fixed positions, because they
|
|
9
|
+
* are about the cockpit itself rather than about a package. Contributed pages
|
|
10
|
+
* sort after them, by their declared order and then their id, so the menu is
|
|
11
|
+
* stable across syncs whatever order plugins install in.
|
|
12
|
+
*/
|
|
13
|
+
export type SettingsWorkspace = 'general' | 'repository';
|
|
14
|
+
export interface SettingsSection {
|
|
15
|
+
id: string;
|
|
16
|
+
label: string;
|
|
17
|
+
detail: string;
|
|
18
|
+
workspace: SettingsWorkspace;
|
|
19
|
+
/** The fields a contributed page renders; absent on the host's own pages. */
|
|
20
|
+
contribution?: SettingsSectionContribution;
|
|
21
|
+
/** Package panel hosted inside the repository workspace. */
|
|
22
|
+
repositoryPanel?: InstalledRepositorySettingsPanel;
|
|
23
|
+
/** A page the contributing package draws itself, rather than fields the host renders. */
|
|
24
|
+
panel?: InstalledSettingsPanel;
|
|
25
|
+
}
|
|
26
|
+
export declare const DEFAULT_SETTINGS_SECTION: string;
|
|
27
|
+
export declare const DEFAULT_REPOSITORY_SETTINGS_SECTION: string;
|
|
28
|
+
/**
|
|
29
|
+
* Every page the menu offers. Read through a function rather than held in a
|
|
30
|
+
* const: plugins install before the first render, but a module-level array
|
|
31
|
+
* evaluated at import time would freeze the list before that happened.
|
|
32
|
+
*/
|
|
33
|
+
export declare function settingsSections(workspace?: SettingsWorkspace): readonly SettingsSection[];
|
|
34
|
+
export declare function settingsSection(id: string | undefined): SettingsSection | undefined;
|
|
35
|
+
//#endregion
|
|
36
|
+
//# sourceMappingURL=settingsSections.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settingsSections.d.mts","names":[],"sources":["../../../src/web/lib/settingsSections.ts"],"mappings":";;;;;;;;;;;;YAmBY;iBAEK;EACf;EACA;EACA;EACA,WAAW;;EAEX,eAAe;;EAEf,kBAAkB;;EAElB,QAAQ;;qBAsDG;qBACA;;;;;;wBAmBG,iBAAiB,YAAY,6BAA6B;wBA8C1D,gBAAgB,yBAAyB"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { pluginRepositorySettingsPanels, pluginSettingsPanels, pluginSettingsSections } from "./pluginRegistry.mjs";
|
|
2
|
+
//#region src/web/lib/settingsSections.ts
|
|
3
|
+
const GENERAL_SETTINGS_SECTIONS = [
|
|
4
|
+
{
|
|
5
|
+
id: "providers",
|
|
6
|
+
label: "providers",
|
|
7
|
+
detail: "sign in to the model providers Pi can use",
|
|
8
|
+
workspace: "general"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
id: "appearance",
|
|
12
|
+
label: "appearance",
|
|
13
|
+
detail: "pick the theme the cockpit renders with",
|
|
14
|
+
workspace: "general"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
id: "notifications",
|
|
18
|
+
label: "notifications",
|
|
19
|
+
detail: "allow live session notifications in this browser",
|
|
20
|
+
workspace: "general"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
id: "images",
|
|
24
|
+
label: "images",
|
|
25
|
+
detail: "how large an image may be when it reaches a model",
|
|
26
|
+
workspace: "general"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
id: "remote",
|
|
30
|
+
label: "remote control",
|
|
31
|
+
detail: "save a named tunnel and expose live sessions to MCP clients",
|
|
32
|
+
workspace: "general"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
id: "plugins",
|
|
36
|
+
label: "plugins",
|
|
37
|
+
detail: "the web plugins this bundle carries and what their install resolved",
|
|
38
|
+
workspace: "general"
|
|
39
|
+
}
|
|
40
|
+
];
|
|
41
|
+
const REPOSITORY_DEFAULTS_SECTION = {
|
|
42
|
+
id: "repositories",
|
|
43
|
+
label: "defaults",
|
|
44
|
+
detail: "mode, domains, and profile",
|
|
45
|
+
workspace: "repository"
|
|
46
|
+
};
|
|
47
|
+
const DEFAULT_CONTRIBUTED_ORDER = 1e3;
|
|
48
|
+
/** Repository-workspace copies need their own route id, since the id is the route param. */
|
|
49
|
+
const REPOSITORY_SECTION_PREFIX = "repository-";
|
|
50
|
+
const DEFAULT_SETTINGS_SECTION = GENERAL_SETTINGS_SECTIONS[0].id;
|
|
51
|
+
const DEFAULT_REPOSITORY_SETTINGS_SECTION = REPOSITORY_DEFAULTS_SECTION.id;
|
|
52
|
+
function byMenuOrder(left, right) {
|
|
53
|
+
return (left.order ?? DEFAULT_CONTRIBUTED_ORDER) - (right.order ?? DEFAULT_CONTRIBUTED_ORDER) || left.id.localeCompare(right.id);
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Every page the menu offers. Read through a function rather than held in a
|
|
57
|
+
* const: plugins install before the first render, but a module-level array
|
|
58
|
+
* evaluated at import time would freeze the list before that happened.
|
|
59
|
+
*/
|
|
60
|
+
function settingsSections(workspace) {
|
|
61
|
+
const contributed = [...pluginSettingsSections()].sort(byMenuOrder).map((contribution) => ({
|
|
62
|
+
id: contribution.id,
|
|
63
|
+
label: contribution.label,
|
|
64
|
+
detail: contribution.detail,
|
|
65
|
+
workspace: "general",
|
|
66
|
+
contribution
|
|
67
|
+
}));
|
|
68
|
+
const contributedForRepository = [...pluginSettingsSections("workspace")].sort(byMenuOrder).map((contribution) => ({
|
|
69
|
+
id: `${REPOSITORY_SECTION_PREFIX}${contribution.id}`,
|
|
70
|
+
label: contribution.label,
|
|
71
|
+
detail: contribution.detail,
|
|
72
|
+
workspace: "repository",
|
|
73
|
+
contribution
|
|
74
|
+
}));
|
|
75
|
+
const panels = [...pluginSettingsPanels()].sort(byMenuOrder).map((panel) => ({
|
|
76
|
+
id: panel.id,
|
|
77
|
+
label: panel.label,
|
|
78
|
+
detail: panel.detail,
|
|
79
|
+
workspace: "general",
|
|
80
|
+
panel
|
|
81
|
+
}));
|
|
82
|
+
const repositoryPanels = pluginRepositorySettingsPanels().map((repositoryPanel) => ({
|
|
83
|
+
id: `${REPOSITORY_SECTION_PREFIX}${repositoryPanel.pluginId}`,
|
|
84
|
+
label: repositoryPanel.label,
|
|
85
|
+
detail: repositoryPanel.detail,
|
|
86
|
+
workspace: "repository",
|
|
87
|
+
repositoryPanel
|
|
88
|
+
}));
|
|
89
|
+
const all = [
|
|
90
|
+
...GENERAL_SETTINGS_SECTIONS,
|
|
91
|
+
...contributed,
|
|
92
|
+
...panels,
|
|
93
|
+
REPOSITORY_DEFAULTS_SECTION,
|
|
94
|
+
...repositoryPanels,
|
|
95
|
+
...contributedForRepository
|
|
96
|
+
];
|
|
97
|
+
return workspace === void 0 ? all : all.filter((section) => section.workspace === workspace);
|
|
98
|
+
}
|
|
99
|
+
function settingsSection(id) {
|
|
100
|
+
return settingsSections().find((section) => section.id === id);
|
|
101
|
+
}
|
|
102
|
+
//#endregion
|
|
103
|
+
export { DEFAULT_REPOSITORY_SETTINGS_SECTION, DEFAULT_SETTINGS_SECTION, settingsSection, settingsSections };
|
|
104
|
+
|
|
105
|
+
//# sourceMappingURL=settingsSections.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settingsSections.mjs","names":[],"sources":["../../../src/web/lib/settingsSections.ts"],"sourcesContent":["import type { SettingsSectionContribution } from '@agimon-ai/po-core/web';\n\nimport {\n pluginRepositorySettingsPanels,\n pluginSettingsPanels,\n pluginSettingsSections,\n type InstalledRepositorySettingsPanel,\n type InstalledSettingsPanel,\n} from './pluginRegistry';\n\n/**\n * The settings menu, as data: the rail's gear and the settings page both\n * need to name a section, and neither feature may import the other.\n *\n * The host's own pages come first and keep fixed positions, because they\n * are about the cockpit itself rather than about a package. Contributed pages\n * sort after them, by their declared order and then their id, so the menu is\n * stable across syncs whatever order plugins install in.\n */\nexport type SettingsWorkspace = 'general' | 'repository';\n\nexport interface SettingsSection {\n id: string;\n label: string;\n detail: string;\n workspace: SettingsWorkspace;\n /** The fields a contributed page renders; absent on the host's own pages. */\n contribution?: SettingsSectionContribution;\n /** Package panel hosted inside the repository workspace. */\n repositoryPanel?: InstalledRepositorySettingsPanel;\n /** A page the contributing package draws itself, rather than fields the host renders. */\n panel?: InstalledSettingsPanel;\n}\n\nconst GENERAL_SETTINGS_SECTIONS: readonly SettingsSection[] = [\n {\n id: 'providers',\n label: 'providers',\n detail: 'sign in to the model providers Pi can use',\n workspace: 'general',\n },\n {\n id: 'appearance',\n label: 'appearance',\n detail: 'pick the theme the cockpit renders with',\n workspace: 'general',\n },\n {\n id: 'notifications',\n label: 'notifications',\n detail: 'allow live session notifications in this browser',\n workspace: 'general',\n },\n {\n id: 'images',\n label: 'images',\n detail: 'how large an image may be when it reaches a model',\n workspace: 'general',\n },\n {\n id: 'remote',\n label: 'remote control',\n detail: 'save a named tunnel and expose live sessions to MCP clients',\n workspace: 'general',\n },\n {\n id: 'plugins',\n label: 'plugins',\n detail: 'the web plugins this bundle carries and what their install resolved',\n workspace: 'general',\n },\n];\n\nconst REPOSITORY_DEFAULTS_SECTION: SettingsSection = {\n id: 'repositories',\n label: 'defaults',\n detail: 'mode, domains, and profile',\n workspace: 'repository',\n};\n\nconst DEFAULT_CONTRIBUTED_ORDER = 1000;\n\n/** Repository-workspace copies need their own route id, since the id is the route param. */\nconst REPOSITORY_SECTION_PREFIX = 'repository-';\n\nexport const DEFAULT_SETTINGS_SECTION = GENERAL_SETTINGS_SECTIONS[0]!.id;\nexport const DEFAULT_REPOSITORY_SETTINGS_SECTION = REPOSITORY_DEFAULTS_SECTION.id;\n\ninterface MenuOrdered {\n id: string;\n order?: number;\n}\n\nfunction byMenuOrder(left: MenuOrdered, right: MenuOrdered): number {\n return (\n (left.order ?? DEFAULT_CONTRIBUTED_ORDER) - (right.order ?? DEFAULT_CONTRIBUTED_ORDER) ||\n left.id.localeCompare(right.id)\n );\n}\n\n/**\n * Every page the menu offers. Read through a function rather than held in a\n * const: plugins install before the first render, but a module-level array\n * evaluated at import time would freeze the list before that happened.\n */\nexport function settingsSections(workspace?: SettingsWorkspace): readonly SettingsSection[] {\n const contributions = [...pluginSettingsSections()].sort(byMenuOrder);\n // The same page is offered in both workspaces. Scope comes from the workspace\n // the reader is in, so the general copy edits the global file and the\n // repository copy edits whichever repository the workspace picker holds.\n const contributed = contributions.map((contribution) => ({\n id: contribution.id,\n label: contribution.label,\n detail: contribution.detail,\n workspace: 'general' as const,\n contribution,\n }));\n const contributedForRepository = [...pluginSettingsSections('workspace')].sort(byMenuOrder).map((contribution) => ({\n id: `${REPOSITORY_SECTION_PREFIX}${contribution.id}`,\n label: contribution.label,\n detail: contribution.detail,\n workspace: 'repository' as const,\n contribution,\n }));\n // A self-drawn page has no scope to switch: it reports rather than writes,\n // so it appears once, in the general workspace, and not as a repository copy.\n const panels = [...pluginSettingsPanels()].sort(byMenuOrder).map((panel) => ({\n id: panel.id,\n label: panel.label,\n detail: panel.detail,\n workspace: 'general' as const,\n panel,\n }));\n const repositoryPanels = pluginRepositorySettingsPanels().map((repositoryPanel) => ({\n id: `${REPOSITORY_SECTION_PREFIX}${repositoryPanel.pluginId}`,\n label: repositoryPanel.label,\n detail: repositoryPanel.detail,\n workspace: 'repository' as const,\n repositoryPanel,\n }));\n const all = [\n ...GENERAL_SETTINGS_SECTIONS,\n ...contributed,\n ...panels,\n REPOSITORY_DEFAULTS_SECTION,\n ...repositoryPanels,\n ...contributedForRepository,\n ];\n return workspace === undefined ? all : all.filter((section) => section.workspace === workspace);\n}\n\nexport function settingsSection(id: string | undefined): SettingsSection | undefined {\n return settingsSections().find((section) => section.id === id);\n}\n"],"mappings":";;AAkCA,MAAM,4BAAwD;CAC5D;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;CACA;EACE,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,WAAW;CACb;AACF;AAEA,MAAM,8BAA+C;CACnD,IAAI;CACJ,OAAO;CACP,QAAQ;CACR,WAAW;AACb;AAEA,MAAM,4BAA4B;;AAGlC,MAAM,4BAA4B;AAElC,MAAa,2BAA2B,0BAA0B,EAAE,CAAE;AACtE,MAAa,sCAAsC,4BAA4B;AAO/E,SAAS,YAAY,MAAmB,OAA4B;CAClE,QACG,KAAK,SAAS,8BAA8B,MAAM,SAAS,8BAC5D,KAAK,GAAG,cAAc,MAAM,EAAE;AAElC;;;;;;AAOA,SAAgB,iBAAiB,WAA2D;CAK1F,MAAM,cAJgB,CAAC,GAAG,uBAAuB,CAAC,CAAC,CAAC,KAAK,WAIzB,CAAC,CAAC,KAAK,kBAAkB;EACvD,IAAI,aAAa;EACjB,OAAO,aAAa;EACpB,QAAQ,aAAa;EACrB,WAAW;EACX;CACF,EAAE;CACF,MAAM,2BAA2B,CAAC,GAAG,uBAAuB,WAAW,CAAC,CAAC,CAAC,KAAK,WAAW,CAAC,CAAC,KAAK,kBAAkB;EACjH,IAAI,GAAG,4BAA4B,aAAa;EAChD,OAAO,aAAa;EACpB,QAAQ,aAAa;EACrB,WAAW;EACX;CACF,EAAE;CAGF,MAAM,SAAS,CAAC,GAAG,qBAAqB,CAAC,CAAC,CAAC,KAAK,WAAW,CAAC,CAAC,KAAK,WAAW;EAC3E,IAAI,MAAM;EACV,OAAO,MAAM;EACb,QAAQ,MAAM;EACd,WAAW;EACX;CACF,EAAE;CACF,MAAM,mBAAmB,+BAA+B,CAAC,CAAC,KAAK,qBAAqB;EAClF,IAAI,GAAG,4BAA4B,gBAAgB;EACnD,OAAO,gBAAgB;EACvB,QAAQ,gBAAgB;EACxB,WAAW;EACX;CACF,EAAE;CACF,MAAM,MAAM;EACV,GAAG;EACH,GAAG;EACH,GAAG;EACH;EACA,GAAG;EACH,GAAG;CACL;CACA,OAAO,cAAc,KAAA,IAAY,MAAM,IAAI,QAAQ,YAAY,QAAQ,cAAc,SAAS;AAChG;AAEA,SAAgB,gBAAgB,IAAqD;CACnF,OAAO,iBAAiB,CAAC,CAAC,MAAM,YAAY,QAAQ,OAAO,EAAE;AAC/D"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
//#region src/web/lib/statusLine.ts
|
|
2
|
+
const emptySelection = {
|
|
3
|
+
profile: "",
|
|
4
|
+
majorMode: "",
|
|
5
|
+
domains: [],
|
|
6
|
+
pending: false
|
|
7
|
+
};
|
|
8
|
+
const SGR = /\u001B\[([0-9;]*)m/gu;
|
|
9
|
+
/** Splits an ANSI string into runs of text carrying the truecolor in force. */
|
|
10
|
+
function ansiSegments(input) {
|
|
11
|
+
const segments = [];
|
|
12
|
+
let current = null;
|
|
13
|
+
let index = 0;
|
|
14
|
+
SGR.lastIndex = 0;
|
|
15
|
+
for (let match = SGR.exec(input); match !== null; match = SGR.exec(input)) {
|
|
16
|
+
const text = input.slice(index, match.index);
|
|
17
|
+
if (text) segments.push({
|
|
18
|
+
text,
|
|
19
|
+
rgb: current
|
|
20
|
+
});
|
|
21
|
+
const codes = match[1].split(";").map((code) => Number.parseInt(code, 10));
|
|
22
|
+
if (codes[0] === 38 && codes[1] === 2) current = [
|
|
23
|
+
codes[2],
|
|
24
|
+
codes[3],
|
|
25
|
+
codes[4]
|
|
26
|
+
];
|
|
27
|
+
else if (codes[0] === 39 || codes[0] === 0 || Number.isNaN(codes[0])) current = null;
|
|
28
|
+
index = match.index + match[0].length;
|
|
29
|
+
}
|
|
30
|
+
const tail = input.slice(index);
|
|
31
|
+
if (tail) segments.push({
|
|
32
|
+
text: tail,
|
|
33
|
+
rgb: current
|
|
34
|
+
});
|
|
35
|
+
return segments;
|
|
36
|
+
}
|
|
37
|
+
function stripAnsi(input) {
|
|
38
|
+
return input.replace(SGR, "");
|
|
39
|
+
}
|
|
40
|
+
const WARNING = [
|
|
41
|
+
236,
|
|
42
|
+
190,
|
|
43
|
+
123
|
|
44
|
+
];
|
|
45
|
+
const ACCENT = [
|
|
46
|
+
81,
|
|
47
|
+
175,
|
|
48
|
+
239
|
|
49
|
+
];
|
|
50
|
+
function distance(a, b) {
|
|
51
|
+
return (a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2 + (a[2] - b[2]) ** 2;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Reads Po's footer status line.
|
|
55
|
+
*
|
|
56
|
+
* The line is the only place the session publishes its selection, so this
|
|
57
|
+
* parses the shape `*profile*:[major-mode]:domains` structurally and uses the
|
|
58
|
+
* colour of the mode segment solely to tell a pending switch from a settled one.
|
|
59
|
+
*/
|
|
60
|
+
function parseSelection(statusText) {
|
|
61
|
+
const segments = ansiSegments(statusText);
|
|
62
|
+
const plain = stripAnsi(statusText).trim();
|
|
63
|
+
if (!plain) return emptySelection;
|
|
64
|
+
const profileMatch = /\*([^*]+)\*/u.exec(plain);
|
|
65
|
+
const modeMatch = /\[([^\]]+)\]/u.exec(plain);
|
|
66
|
+
const domains = (modeMatch ? plain.slice(plain.indexOf(modeMatch[0]) + modeMatch[0].length) : "").replace(/^:/u, "").split(",").map((entry) => entry.trim()).filter(Boolean);
|
|
67
|
+
const modeSegment = segments.find((segment) => segment.text.includes("["));
|
|
68
|
+
const pending = modeSegment?.rgb !== void 0 && modeSegment?.rgb !== null ? distance(modeSegment.rgb, WARNING) < distance(modeSegment.rgb, ACCENT) : false;
|
|
69
|
+
return {
|
|
70
|
+
profile: profileMatch ? profileMatch[1] : "",
|
|
71
|
+
majorMode: modeMatch ? modeMatch[1] : "",
|
|
72
|
+
domains,
|
|
73
|
+
pending
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
//#endregion
|
|
77
|
+
exports.ansiSegments = ansiSegments;
|
|
78
|
+
exports.emptySelection = emptySelection;
|
|
79
|
+
exports.parseSelection = parseSelection;
|
|
80
|
+
exports.stripAnsi = stripAnsi;
|
|
81
|
+
|
|
82
|
+
//# sourceMappingURL=statusLine.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"statusLine.cjs","names":[],"sources":["../../../src/web/lib/statusLine.ts"],"sourcesContent":["export interface Selection {\n /** Empty when the session runs without a profile, which is a valid choice. */\n profile: string;\n majorMode: string;\n domains: string[];\n /** True while a mode switch is journaled but not yet applied. */\n pending: boolean;\n}\n\nexport const emptySelection: Selection = { profile: '', majorMode: '', domains: [], pending: false };\n\ninterface Segment {\n text: string;\n rgb: [number, number, number] | null;\n}\n\n// The escape is the point of this parser, so the control character is\n// deliberate; spelled as a Unicode escape to keep it readable.\n// oxlint-disable-next-line no-control-regex\nconst SGR = /\\u001B\\[([0-9;]*)m/gu;\n\n/** Splits an ANSI string into runs of text carrying the truecolor in force. */\nexport function ansiSegments(input: string): Segment[] {\n const segments: Segment[] = [];\n let current: [number, number, number] | null = null;\n let index = 0;\n\n SGR.lastIndex = 0;\n for (let match = SGR.exec(input); match !== null; match = SGR.exec(input)) {\n const text = input.slice(index, match.index);\n if (text) segments.push({ text, rgb: current });\n const codes = match[1].split(';').map((code) => Number.parseInt(code, 10));\n if (codes[0] === 38 && codes[1] === 2) current = [codes[2], codes[3], codes[4]];\n else if (codes[0] === 39 || codes[0] === 0 || Number.isNaN(codes[0])) current = null;\n index = match.index + match[0].length;\n }\n const tail = input.slice(index);\n if (tail) segments.push({ text: tail, rgb: current });\n return segments;\n}\n\nexport function stripAnsi(input: string): string {\n return input.replace(SGR, '');\n}\n\n// The values po-dark.json binds to `warning` and `accent`. Po ships one\n// theme, so comparing against both and taking the nearer one reports pending\n// accurately, and falls back to \"not pending\" when it cannot tell.\nconst WARNING: [number, number, number] = [236, 190, 123];\nconst ACCENT: [number, number, number] = [81, 175, 239];\n\nfunction distance(a: [number, number, number], b: [number, number, number]): number {\n return (a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2 + (a[2] - b[2]) ** 2;\n}\n\n/**\n * Reads Po's footer status line.\n *\n * The line is the only place the session publishes its selection, so this\n * parses the shape `*profile*:[major-mode]:domains` structurally and uses the\n * colour of the mode segment solely to tell a pending switch from a settled one.\n */\nexport function parseSelection(statusText: string): Selection {\n const segments = ansiSegments(statusText);\n const plain = stripAnsi(statusText).trim();\n if (!plain) return emptySelection;\n\n const profileMatch = /\\*([^*]+)\\*/u.exec(plain);\n const modeMatch = /\\[([^\\]]+)\\]/u.exec(plain);\n\n const afterMode = modeMatch ? plain.slice(plain.indexOf(modeMatch[0]) + modeMatch[0].length) : '';\n const domains = afterMode\n .replace(/^:/u, '')\n .split(',')\n .map((entry) => entry.trim())\n .filter(Boolean);\n\n const modeSegment = segments.find((segment) => segment.text.includes('['));\n const pending =\n modeSegment?.rgb !== undefined && modeSegment?.rgb !== null\n ? distance(modeSegment.rgb, WARNING) < distance(modeSegment.rgb, ACCENT)\n : false;\n\n return {\n profile: profileMatch ? profileMatch[1] : '',\n majorMode: modeMatch ? modeMatch[1] : '',\n domains,\n pending,\n };\n}\n"],"mappings":";AASA,MAAa,iBAA4B;CAAE,SAAS;CAAI,WAAW;CAAI,SAAS,CAAC;CAAG,SAAS;AAAM;AAUnG,MAAM,MAAM;;AAGZ,SAAgB,aAAa,OAA0B;CACrD,MAAM,WAAsB,CAAC;CAC7B,IAAI,UAA2C;CAC/C,IAAI,QAAQ;CAEZ,IAAI,YAAY;CAChB,KAAK,IAAI,QAAQ,IAAI,KAAK,KAAK,GAAG,UAAU,MAAM,QAAQ,IAAI,KAAK,KAAK,GAAG;EACzE,MAAM,OAAO,MAAM,MAAM,OAAO,MAAM,KAAK;EAC3C,IAAI,MAAM,SAAS,KAAK;GAAE;GAAM,KAAK;EAAQ,CAAC;EAC9C,MAAM,QAAQ,MAAM,EAAE,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,SAAS,OAAO,SAAS,MAAM,EAAE,CAAC;EACzE,IAAI,MAAM,OAAO,MAAM,MAAM,OAAO,GAAG,UAAU;GAAC,MAAM;GAAI,MAAM;GAAI,MAAM;EAAE;OACzE,IAAI,MAAM,OAAO,MAAM,MAAM,OAAO,KAAK,OAAO,MAAM,MAAM,EAAE,GAAG,UAAU;EAChF,QAAQ,MAAM,QAAQ,MAAM,EAAE,CAAC;CACjC;CACA,MAAM,OAAO,MAAM,MAAM,KAAK;CAC9B,IAAI,MAAM,SAAS,KAAK;EAAE,MAAM;EAAM,KAAK;CAAQ,CAAC;CACpD,OAAO;AACT;AAEA,SAAgB,UAAU,OAAuB;CAC/C,OAAO,MAAM,QAAQ,KAAK,EAAE;AAC9B;AAKA,MAAM,UAAoC;CAAC;CAAK;CAAK;AAAG;AACxD,MAAM,SAAmC;CAAC;CAAI;CAAK;AAAG;AAEtD,SAAS,SAAS,GAA6B,GAAqC;CAClF,QAAQ,EAAE,KAAK,EAAE,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO;AACpE;;;;;;;;AASA,SAAgB,eAAe,YAA+B;CAC5D,MAAM,WAAW,aAAa,UAAU;CACxC,MAAM,QAAQ,UAAU,UAAU,CAAC,CAAC,KAAK;CACzC,IAAI,CAAC,OAAO,OAAO;CAEnB,MAAM,eAAe,eAAe,KAAK,KAAK;CAC9C,MAAM,YAAY,gBAAgB,KAAK,KAAK;CAG5C,MAAM,WADY,YAAY,MAAM,MAAM,MAAM,QAAQ,UAAU,EAAE,IAAI,UAAU,EAAE,CAAC,MAAM,IAAI,GAAA,CAE5F,QAAQ,OAAO,EAAE,CAAC,CAClB,MAAM,GAAG,CAAC,CACV,KAAK,UAAU,MAAM,KAAK,CAAC,CAAC,CAC5B,OAAO,OAAO;CAEjB,MAAM,cAAc,SAAS,MAAM,YAAY,QAAQ,KAAK,SAAS,GAAG,CAAC;CACzE,MAAM,UACJ,aAAa,QAAQ,KAAA,KAAa,aAAa,QAAQ,OACnD,SAAS,YAAY,KAAK,OAAO,IAAI,SAAS,YAAY,KAAK,MAAM,IACrE;CAEN,OAAO;EACL,SAAS,eAAe,aAAa,KAAK;EAC1C,WAAW,YAAY,UAAU,KAAK;EACtC;EACA;CACF;AACF"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
//#region src/web/lib/statusLine.d.ts
|
|
2
|
+
export interface Selection {
|
|
3
|
+
/** Empty when the session runs without a profile, which is a valid choice. */
|
|
4
|
+
profile: string;
|
|
5
|
+
majorMode: string;
|
|
6
|
+
domains: string[];
|
|
7
|
+
/** True while a mode switch is journaled but not yet applied. */
|
|
8
|
+
pending: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare const emptySelection: Selection;
|
|
11
|
+
interface Segment {
|
|
12
|
+
text: string;
|
|
13
|
+
rgb: [number, number, number] | null;
|
|
14
|
+
}
|
|
15
|
+
/** Splits an ANSI string into runs of text carrying the truecolor in force. */
|
|
16
|
+
export declare function ansiSegments(input: string): Segment[];
|
|
17
|
+
export declare function stripAnsi(input: string): string;
|
|
18
|
+
/**
|
|
19
|
+
* Reads Po's footer status line.
|
|
20
|
+
*
|
|
21
|
+
* The line is the only place the session publishes its selection, so this
|
|
22
|
+
* parses the shape `*profile*:[major-mode]:domains` structurally and uses the
|
|
23
|
+
* colour of the mode segment solely to tell a pending switch from a settled one.
|
|
24
|
+
*/
|
|
25
|
+
export declare function parseSelection(statusText: string): Selection;
|
|
26
|
+
//#endregion
|
|
27
|
+
//# sourceMappingURL=statusLine.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"statusLine.d.mts","names":[],"sources":["../../../src/web/lib/statusLine.ts"],"mappings":";iBAAiB;;EAEf;EACA;EACA;;EAEA;;qBAGW,gBAAgB;UAEnB;EACR;EACA;;;wBASc,aAAa,gBAAgB;wBAmB7B,UAAU;;;;;;;;wBAqBV,eAAe,qBAAqB"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
//#region src/web/lib/statusLine.ts
|
|
2
|
+
const emptySelection = {
|
|
3
|
+
profile: "",
|
|
4
|
+
majorMode: "",
|
|
5
|
+
domains: [],
|
|
6
|
+
pending: false
|
|
7
|
+
};
|
|
8
|
+
const SGR = /\u001B\[([0-9;]*)m/gu;
|
|
9
|
+
/** Splits an ANSI string into runs of text carrying the truecolor in force. */
|
|
10
|
+
function ansiSegments(input) {
|
|
11
|
+
const segments = [];
|
|
12
|
+
let current = null;
|
|
13
|
+
let index = 0;
|
|
14
|
+
SGR.lastIndex = 0;
|
|
15
|
+
for (let match = SGR.exec(input); match !== null; match = SGR.exec(input)) {
|
|
16
|
+
const text = input.slice(index, match.index);
|
|
17
|
+
if (text) segments.push({
|
|
18
|
+
text,
|
|
19
|
+
rgb: current
|
|
20
|
+
});
|
|
21
|
+
const codes = match[1].split(";").map((code) => Number.parseInt(code, 10));
|
|
22
|
+
if (codes[0] === 38 && codes[1] === 2) current = [
|
|
23
|
+
codes[2],
|
|
24
|
+
codes[3],
|
|
25
|
+
codes[4]
|
|
26
|
+
];
|
|
27
|
+
else if (codes[0] === 39 || codes[0] === 0 || Number.isNaN(codes[0])) current = null;
|
|
28
|
+
index = match.index + match[0].length;
|
|
29
|
+
}
|
|
30
|
+
const tail = input.slice(index);
|
|
31
|
+
if (tail) segments.push({
|
|
32
|
+
text: tail,
|
|
33
|
+
rgb: current
|
|
34
|
+
});
|
|
35
|
+
return segments;
|
|
36
|
+
}
|
|
37
|
+
function stripAnsi(input) {
|
|
38
|
+
return input.replace(SGR, "");
|
|
39
|
+
}
|
|
40
|
+
const WARNING = [
|
|
41
|
+
236,
|
|
42
|
+
190,
|
|
43
|
+
123
|
|
44
|
+
];
|
|
45
|
+
const ACCENT = [
|
|
46
|
+
81,
|
|
47
|
+
175,
|
|
48
|
+
239
|
|
49
|
+
];
|
|
50
|
+
function distance(a, b) {
|
|
51
|
+
return (a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2 + (a[2] - b[2]) ** 2;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Reads Po's footer status line.
|
|
55
|
+
*
|
|
56
|
+
* The line is the only place the session publishes its selection, so this
|
|
57
|
+
* parses the shape `*profile*:[major-mode]:domains` structurally and uses the
|
|
58
|
+
* colour of the mode segment solely to tell a pending switch from a settled one.
|
|
59
|
+
*/
|
|
60
|
+
function parseSelection(statusText) {
|
|
61
|
+
const segments = ansiSegments(statusText);
|
|
62
|
+
const plain = stripAnsi(statusText).trim();
|
|
63
|
+
if (!plain) return emptySelection;
|
|
64
|
+
const profileMatch = /\*([^*]+)\*/u.exec(plain);
|
|
65
|
+
const modeMatch = /\[([^\]]+)\]/u.exec(plain);
|
|
66
|
+
const domains = (modeMatch ? plain.slice(plain.indexOf(modeMatch[0]) + modeMatch[0].length) : "").replace(/^:/u, "").split(",").map((entry) => entry.trim()).filter(Boolean);
|
|
67
|
+
const modeSegment = segments.find((segment) => segment.text.includes("["));
|
|
68
|
+
const pending = modeSegment?.rgb !== void 0 && modeSegment?.rgb !== null ? distance(modeSegment.rgb, WARNING) < distance(modeSegment.rgb, ACCENT) : false;
|
|
69
|
+
return {
|
|
70
|
+
profile: profileMatch ? profileMatch[1] : "",
|
|
71
|
+
majorMode: modeMatch ? modeMatch[1] : "",
|
|
72
|
+
domains,
|
|
73
|
+
pending
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
//#endregion
|
|
77
|
+
export { ansiSegments, emptySelection, parseSelection, stripAnsi };
|
|
78
|
+
|
|
79
|
+
//# sourceMappingURL=statusLine.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"statusLine.mjs","names":[],"sources":["../../../src/web/lib/statusLine.ts"],"sourcesContent":["export interface Selection {\n /** Empty when the session runs without a profile, which is a valid choice. */\n profile: string;\n majorMode: string;\n domains: string[];\n /** True while a mode switch is journaled but not yet applied. */\n pending: boolean;\n}\n\nexport const emptySelection: Selection = { profile: '', majorMode: '', domains: [], pending: false };\n\ninterface Segment {\n text: string;\n rgb: [number, number, number] | null;\n}\n\n// The escape is the point of this parser, so the control character is\n// deliberate; spelled as a Unicode escape to keep it readable.\n// oxlint-disable-next-line no-control-regex\nconst SGR = /\\u001B\\[([0-9;]*)m/gu;\n\n/** Splits an ANSI string into runs of text carrying the truecolor in force. */\nexport function ansiSegments(input: string): Segment[] {\n const segments: Segment[] = [];\n let current: [number, number, number] | null = null;\n let index = 0;\n\n SGR.lastIndex = 0;\n for (let match = SGR.exec(input); match !== null; match = SGR.exec(input)) {\n const text = input.slice(index, match.index);\n if (text) segments.push({ text, rgb: current });\n const codes = match[1].split(';').map((code) => Number.parseInt(code, 10));\n if (codes[0] === 38 && codes[1] === 2) current = [codes[2], codes[3], codes[4]];\n else if (codes[0] === 39 || codes[0] === 0 || Number.isNaN(codes[0])) current = null;\n index = match.index + match[0].length;\n }\n const tail = input.slice(index);\n if (tail) segments.push({ text: tail, rgb: current });\n return segments;\n}\n\nexport function stripAnsi(input: string): string {\n return input.replace(SGR, '');\n}\n\n// The values po-dark.json binds to `warning` and `accent`. Po ships one\n// theme, so comparing against both and taking the nearer one reports pending\n// accurately, and falls back to \"not pending\" when it cannot tell.\nconst WARNING: [number, number, number] = [236, 190, 123];\nconst ACCENT: [number, number, number] = [81, 175, 239];\n\nfunction distance(a: [number, number, number], b: [number, number, number]): number {\n return (a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2 + (a[2] - b[2]) ** 2;\n}\n\n/**\n * Reads Po's footer status line.\n *\n * The line is the only place the session publishes its selection, so this\n * parses the shape `*profile*:[major-mode]:domains` structurally and uses the\n * colour of the mode segment solely to tell a pending switch from a settled one.\n */\nexport function parseSelection(statusText: string): Selection {\n const segments = ansiSegments(statusText);\n const plain = stripAnsi(statusText).trim();\n if (!plain) return emptySelection;\n\n const profileMatch = /\\*([^*]+)\\*/u.exec(plain);\n const modeMatch = /\\[([^\\]]+)\\]/u.exec(plain);\n\n const afterMode = modeMatch ? plain.slice(plain.indexOf(modeMatch[0]) + modeMatch[0].length) : '';\n const domains = afterMode\n .replace(/^:/u, '')\n .split(',')\n .map((entry) => entry.trim())\n .filter(Boolean);\n\n const modeSegment = segments.find((segment) => segment.text.includes('['));\n const pending =\n modeSegment?.rgb !== undefined && modeSegment?.rgb !== null\n ? distance(modeSegment.rgb, WARNING) < distance(modeSegment.rgb, ACCENT)\n : false;\n\n return {\n profile: profileMatch ? profileMatch[1] : '',\n majorMode: modeMatch ? modeMatch[1] : '',\n domains,\n pending,\n };\n}\n"],"mappings":";AASA,MAAa,iBAA4B;CAAE,SAAS;CAAI,WAAW;CAAI,SAAS,CAAC;CAAG,SAAS;AAAM;AAUnG,MAAM,MAAM;;AAGZ,SAAgB,aAAa,OAA0B;CACrD,MAAM,WAAsB,CAAC;CAC7B,IAAI,UAA2C;CAC/C,IAAI,QAAQ;CAEZ,IAAI,YAAY;CAChB,KAAK,IAAI,QAAQ,IAAI,KAAK,KAAK,GAAG,UAAU,MAAM,QAAQ,IAAI,KAAK,KAAK,GAAG;EACzE,MAAM,OAAO,MAAM,MAAM,OAAO,MAAM,KAAK;EAC3C,IAAI,MAAM,SAAS,KAAK;GAAE;GAAM,KAAK;EAAQ,CAAC;EAC9C,MAAM,QAAQ,MAAM,EAAE,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,SAAS,OAAO,SAAS,MAAM,EAAE,CAAC;EACzE,IAAI,MAAM,OAAO,MAAM,MAAM,OAAO,GAAG,UAAU;GAAC,MAAM;GAAI,MAAM;GAAI,MAAM;EAAE;OACzE,IAAI,MAAM,OAAO,MAAM,MAAM,OAAO,KAAK,OAAO,MAAM,MAAM,EAAE,GAAG,UAAU;EAChF,QAAQ,MAAM,QAAQ,MAAM,EAAE,CAAC;CACjC;CACA,MAAM,OAAO,MAAM,MAAM,KAAK;CAC9B,IAAI,MAAM,SAAS,KAAK;EAAE,MAAM;EAAM,KAAK;CAAQ,CAAC;CACpD,OAAO;AACT;AAEA,SAAgB,UAAU,OAAuB;CAC/C,OAAO,MAAM,QAAQ,KAAK,EAAE;AAC9B;AAKA,MAAM,UAAoC;CAAC;CAAK;CAAK;AAAG;AACxD,MAAM,SAAmC;CAAC;CAAI;CAAK;AAAG;AAEtD,SAAS,SAAS,GAA6B,GAAqC;CAClF,QAAQ,EAAE,KAAK,EAAE,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO;AACpE;;;;;;;;AASA,SAAgB,eAAe,YAA+B;CAC5D,MAAM,WAAW,aAAa,UAAU;CACxC,MAAM,QAAQ,UAAU,UAAU,CAAC,CAAC,KAAK;CACzC,IAAI,CAAC,OAAO,OAAO;CAEnB,MAAM,eAAe,eAAe,KAAK,KAAK;CAC9C,MAAM,YAAY,gBAAgB,KAAK,KAAK;CAG5C,MAAM,WADY,YAAY,MAAM,MAAM,MAAM,QAAQ,UAAU,EAAE,IAAI,UAAU,EAAE,CAAC,MAAM,IAAI,GAAA,CAE5F,QAAQ,OAAO,EAAE,CAAC,CAClB,MAAM,GAAG,CAAC,CACV,KAAK,UAAU,MAAM,KAAK,CAAC,CAAC,CAC5B,OAAO,OAAO;CAEjB,MAAM,cAAc,SAAS,MAAM,YAAY,QAAQ,KAAK,SAAS,GAAG,CAAC;CACzE,MAAM,UACJ,aAAa,QAAQ,KAAA,KAAa,aAAa,QAAQ,OACnD,SAAS,YAAY,KAAK,OAAO,IAAI,SAAS,YAAY,KAAK,MAAM,IACrE;CAEN,OAAO;EACL,SAAS,eAAe,aAAa,KAAK;EAC1C,WAAW,YAAY,UAAU,KAAK;EACtC;EACA;CACF;AACF"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
const require_remoteAccess = require("../../types/remoteAccess.cjs");
|
|
2
|
+
const require_sealedSession = require("./sealedSession.cjs");
|
|
3
|
+
const require_webauthnClient = require("./webauthnClient.cjs");
|
|
4
|
+
//#region src/web/lib/stepUp.ts
|
|
5
|
+
const UNAUTHORIZED = 401;
|
|
6
|
+
/**
|
|
7
|
+
* Fetch that answers a step-up challenge once and retries.
|
|
8
|
+
*
|
|
9
|
+
* The server decides which actions need a gesture, not the client: it answers
|
|
10
|
+
* 401 naming the action, and this replays the identical request with an
|
|
11
|
+
* assertion attached. Keeping the decision server-side means a client that
|
|
12
|
+
* forgets to ask still cannot skip the gate, and it means adding a gated action
|
|
13
|
+
* needs no client change at all.
|
|
14
|
+
*
|
|
15
|
+
* Exactly one retry. A second 401 after a fresh gesture is a real refusal, and
|
|
16
|
+
* looping would turn a denied action into a biometric prompt that will not stop.
|
|
17
|
+
*/
|
|
18
|
+
async function fetchWithStepUp(input, init, requestAssertion = require_webauthnClient.assertionFor) {
|
|
19
|
+
const first = await require_sealedSession.sealedHttpSession.fetch(input, init);
|
|
20
|
+
if (first.status !== UNAUTHORIZED) return first;
|
|
21
|
+
let action;
|
|
22
|
+
try {
|
|
23
|
+
action = (await first.clone().json()).action;
|
|
24
|
+
} catch {
|
|
25
|
+
return first;
|
|
26
|
+
}
|
|
27
|
+
if (typeof action !== "string") return first;
|
|
28
|
+
const assertion = await requestAssertion(action);
|
|
29
|
+
if (assertion === void 0) return first;
|
|
30
|
+
return await require_sealedSession.sealedHttpSession.fetch(input, {
|
|
31
|
+
...init,
|
|
32
|
+
headers: {
|
|
33
|
+
...init?.headers,
|
|
34
|
+
[require_remoteAccess.STEP_UP_HEADER]: assertion
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
//#endregion
|
|
39
|
+
exports.fetchWithStepUp = fetchWithStepUp;
|
|
40
|
+
|
|
41
|
+
//# sourceMappingURL=stepUp.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stepUp.cjs","names":["assertionFor","sealedHttpSession","STEP_UP_HEADER"],"sources":["../../../src/web/lib/stepUp.ts"],"sourcesContent":["import { STEP_UP_HEADER } from '../../types/remoteAccess';\nimport { sealedHttpSession } from './sealedSession';\nimport { assertionFor } from './webauthnClient';\n\nconst UNAUTHORIZED = 401;\n\n/**\n * Fetch that answers a step-up challenge once and retries.\n *\n * The server decides which actions need a gesture, not the client: it answers\n * 401 naming the action, and this replays the identical request with an\n * assertion attached. Keeping the decision server-side means a client that\n * forgets to ask still cannot skip the gate, and it means adding a gated action\n * needs no client change at all.\n *\n * Exactly one retry. A second 401 after a fresh gesture is a real refusal, and\n * looping would turn a denied action into a biometric prompt that will not stop.\n */\nexport async function fetchWithStepUp(\n input: string,\n init?: RequestInit,\n /** Test seam, in the house style: the real one runs a WebAuthn ceremony. */\n requestAssertion: (action: string) => Promise<string | undefined> = assertionFor,\n): Promise<Response> {\n const first = await sealedHttpSession.fetch(input, init);\n if (first.status !== UNAUTHORIZED) return first;\n\n let action: unknown;\n try {\n action = ((await first.clone().json()) as { action?: unknown }).action;\n } catch {\n return first; // A 401 with no action is an ordinary refusal.\n }\n if (typeof action !== 'string') return first;\n\n const assertion = await requestAssertion(action);\n if (assertion === undefined) return first;\n\n return await sealedHttpSession.fetch(input, {\n ...init,\n headers: { ...(init?.headers as Record<string, string> | undefined), [STEP_UP_HEADER]: assertion },\n });\n}\n"],"mappings":";;;;AAIA,MAAM,eAAe;;;;;;;;;;;;;AAcrB,eAAsB,gBACpB,OACA,MAEA,mBAAoEA,uBAAAA,cACjD;CACnB,MAAM,QAAQ,MAAMC,sBAAAA,kBAAkB,MAAM,OAAO,IAAI;CACvD,IAAI,MAAM,WAAW,cAAc,OAAO;CAE1C,IAAI;CACJ,IAAI;EACF,UAAW,MAAM,MAAM,MAAM,CAAC,CAAC,KAAK,EAAA,CAA4B;CAClE,QAAQ;EACN,OAAO;CACT;CACA,IAAI,OAAO,WAAW,UAAU,OAAO;CAEvC,MAAM,YAAY,MAAM,iBAAiB,MAAM;CAC/C,IAAI,cAAc,KAAA,GAAW,OAAO;CAEpC,OAAO,MAAMA,sBAAAA,kBAAkB,MAAM,OAAO;EAC1C,GAAG;EACH,SAAS;GAAE,GAAI,MAAM;IAAiDC,qBAAAA,iBAAiB;EAAU;CACnG,CAAC;AACH"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
//#region src/web/lib/stepUp.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* Fetch that answers a step-up challenge once and retries.
|
|
4
|
+
*
|
|
5
|
+
* The server decides which actions need a gesture, not the client: it answers
|
|
6
|
+
* 401 naming the action, and this replays the identical request with an
|
|
7
|
+
* assertion attached. Keeping the decision server-side means a client that
|
|
8
|
+
* forgets to ask still cannot skip the gate, and it means adding a gated action
|
|
9
|
+
* needs no client change at all.
|
|
10
|
+
*
|
|
11
|
+
* Exactly one retry. A second 401 after a fresh gesture is a real refusal, and
|
|
12
|
+
* looping would turn a denied action into a biometric prompt that will not stop.
|
|
13
|
+
*/
|
|
14
|
+
export declare function fetchWithStepUp(input: string, init?: RequestInit,
|
|
15
|
+
/** Test seam, in the house style: the real one runs a WebAuthn ceremony. */
|
|
16
|
+
requestAssertion?: (action: string) => Promise<string | undefined>): Promise<Response>;
|
|
17
|
+
//#endregion
|
|
18
|
+
//# sourceMappingURL=stepUp.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stepUp.d.mts","names":[],"sources":["../../../src/web/lib/stepUp.ts"],"mappings":";;;;;;;;;;;;;wBAkBsB,gBACpB,eACA,OAAO,aAEP;;AAAA,oBAAmB,mBAAmB,8BACrC,QAAQ"}
|