@jingyi0605/codingns4dsh 0.2.1-beta.7 → 0.2.1-beta.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +3 -3
- package/README.md +9 -3
- package/data/build/dist/bootstrap/dsh-peer-host-preboot-shim.d.ts.map +1 -1
- package/data/build/dist/bootstrap/dsh-peer-host-preboot-shim.js +26 -1
- package/data/build/dist/bootstrap/dsh-peer-host-preboot-shim.js.map +1 -1
- package/data/build/dist/client/account-bar.d.ts.map +1 -1
- package/data/build/dist/client/account-bar.js +33 -21
- package/data/build/dist/client/account-bar.js.map +1 -1
- package/data/build/dist/client/avatar/desktop-bridge.js +1 -1
- package/data/build/dist/client/avatar/desktop-bridge.js.map +1 -1
- package/data/build/dist/client/avatar/desktop-view.d.ts +6 -2
- package/data/build/dist/client/avatar/desktop-view.d.ts.map +1 -1
- package/data/build/dist/client/avatar/desktop-view.js +48 -13
- package/data/build/dist/client/avatar/desktop-view.js.map +1 -1
- package/data/build/dist/client/avatar/floating.d.ts +5 -2
- package/data/build/dist/client/avatar/floating.d.ts.map +1 -1
- package/data/build/dist/client/avatar/floating.js +16 -5
- package/data/build/dist/client/avatar/floating.js.map +1 -1
- package/data/build/dist/client/avatar/notification-bubble.d.ts +24 -5
- package/data/build/dist/client/avatar/notification-bubble.d.ts.map +1 -1
- package/data/build/dist/client/avatar/notification-bubble.js +253 -66
- package/data/build/dist/client/avatar/notification-bubble.js.map +1 -1
- package/data/build/dist/client/avatar/notification-surface.d.ts +16 -0
- package/data/build/dist/client/avatar/notification-surface.d.ts.map +1 -0
- package/data/build/dist/client/avatar/notification-surface.js +54 -0
- package/data/build/dist/client/avatar/notification-surface.js.map +1 -0
- package/data/build/dist/client/avatar/reaction-badge.d.ts.map +1 -1
- package/data/build/dist/client/avatar/reaction-badge.js +11 -2
- package/data/build/dist/client/avatar/reaction-badge.js.map +1 -1
- package/data/build/dist/client/bundle.js +2628 -566
- package/data/build/dist/client/bundle.js.map +1 -1
- package/data/build/dist/client/cli-slots.d.ts.map +1 -1
- package/data/build/dist/client/cli-slots.js +26 -2
- package/data/build/dist/client/cli-slots.js.map +1 -1
- package/data/build/dist/client/client.assistant-notifications.js.map +1 -1
- package/data/build/dist/client/client.assistant-workbench.js +235 -109
- package/data/build/dist/client/client.assistant-workbench.js.map +1 -1
- package/data/build/dist/client/client.delegate-command.js +6 -6
- package/data/build/dist/client/client.delegate-command.js.map +1 -1
- package/data/build/dist/client/client.manager.js +46 -9
- package/data/build/dist/client/client.manager.js.map +1 -1
- package/data/build/dist/client/client.native-workspace-store.js +39 -3
- package/data/build/dist/client/client.native-workspace-store.js.map +1 -1
- package/data/build/dist/client/client.session-translation.js +54 -0
- package/data/build/dist/client/client.session-translation.js.map +1 -0
- package/data/build/dist/client/client.theme.js +2 -0
- package/data/build/dist/client/client.theme.js.map +1 -1
- package/data/build/dist/client/client.transport.js +123 -11
- package/data/build/dist/client/client.transport.js.map +1 -1
- package/data/build/dist/client/desktop-assistant.js +57927 -387
- package/data/build/dist/client/features/assistant-conversation-message.d.ts +2 -1
- package/data/build/dist/client/features/assistant-conversation-message.d.ts.map +1 -1
- package/data/build/dist/client/features/assistant-conversation-message.js +59 -24
- package/data/build/dist/client/features/assistant-conversation-message.js.map +1 -1
- package/data/build/dist/client/features/assistant-notification-store.d.ts +8 -2
- package/data/build/dist/client/features/assistant-notification-store.d.ts.map +1 -1
- package/data/build/dist/client/features/assistant-notification-store.js +45 -1
- package/data/build/dist/client/features/assistant-notification-store.js.map +1 -1
- package/data/build/dist/client/features/assistant-record-style.js +11 -4
- package/data/build/dist/client/features/assistant-record-style.js.map +1 -1
- package/data/build/dist/client/features/assistant-workbench.d.ts +4 -0
- package/data/build/dist/client/features/assistant-workbench.d.ts.map +1 -1
- package/data/build/dist/client/features/assistant-workbench.js +27 -1
- package/data/build/dist/client/features/assistant-workbench.js.map +1 -1
- package/data/build/dist/client/features/global-voice-assistant.d.ts.map +1 -1
- package/data/build/dist/client/features/global-voice-assistant.js +46 -8
- package/data/build/dist/client/features/global-voice-assistant.js.map +1 -1
- package/data/build/dist/client/features/index.d.ts +1 -0
- package/data/build/dist/client/features/index.d.ts.map +1 -1
- package/data/build/dist/client/features/index.js +3 -0
- package/data/build/dist/client/features/index.js.map +1 -1
- package/data/build/dist/client/features/peer-host.d.ts.map +1 -1
- package/data/build/dist/client/features/peer-host.js +130 -17
- package/data/build/dist/client/features/peer-host.js.map +1 -1
- package/data/build/dist/client/features/session-translation.d.ts +3 -0
- package/data/build/dist/client/features/session-translation.d.ts.map +1 -0
- package/data/build/dist/client/features/session-translation.js +116 -0
- package/data/build/dist/client/features/session-translation.js.map +1 -0
- package/data/build/dist/client/index.d.ts.map +1 -1
- package/data/build/dist/client/index.js +6 -1
- package/data/build/dist/client/index.js.map +1 -1
- package/data/build/dist/client/locales/assistantWorkbench.d.ts +17 -3
- package/data/build/dist/client/locales/assistantWorkbench.d.ts.map +1 -1
- package/data/build/dist/client/locales/assistantWorkbench.js +15 -11
- package/data/build/dist/client/locales/assistantWorkbench.js.map +1 -1
- package/data/build/dist/client/locales/panels.d.ts.map +1 -1
- package/data/build/dist/client/locales/panels.js +62 -0
- package/data/build/dist/client/locales/panels.js.map +1 -1
- package/data/build/dist/client/peer-host-native-projection.d.ts +4 -0
- package/data/build/dist/client/peer-host-native-projection.d.ts.map +1 -1
- package/data/build/dist/client/peer-host-native-projection.js +40 -1
- package/data/build/dist/client/peer-host-native-projection.js.map +1 -1
- package/data/build/dist/client/peer-host-remote-events.d.ts +14 -0
- package/data/build/dist/client/peer-host-remote-events.d.ts.map +1 -1
- package/data/build/dist/client/peer-host-remote-events.js +92 -3
- package/data/build/dist/client/peer-host-remote-events.js.map +1 -1
- package/data/build/dist/client/session-file-links.d.ts +11 -0
- package/data/build/dist/client/session-file-links.d.ts.map +1 -0
- package/data/build/dist/client/{peer-host-file-links.js → session-file-links.js} +13 -3
- package/data/build/dist/client/session-file-links.js.map +1 -0
- package/data/build/dist/client/session-translation-chat.d.ts +6 -0
- package/data/build/dist/client/session-translation-chat.d.ts.map +1 -0
- package/data/build/dist/client/session-translation-chat.js +686 -0
- package/data/build/dist/client/session-translation-chat.js.map +1 -0
- package/data/build/dist/client/style.css +2561 -0
- package/data/build/dist/client/subscription-slot.d.ts.map +1 -1
- package/data/build/dist/client/subscription-slot.js +5 -1
- package/data/build/dist/client/subscription-slot.js.map +1 -1
- package/data/build/dist/client/theme.d.ts +2 -0
- package/data/build/dist/client/theme.d.ts.map +1 -1
- package/data/build/dist/client/theme.js +3 -0
- package/data/build/dist/client/theme.js.map +1 -1
- package/data/build/dist/client/workspace-session-visibility-dom.d.ts.map +1 -1
- package/data/build/dist/client/workspace-session-visibility-dom.js +43 -15
- package/data/build/dist/client/workspace-session-visibility-dom.js.map +1 -1
- package/data/build/dist/dsh-capabilities/client/assistant-session-navigation-adapter.d.ts +9 -1
- package/data/build/dist/dsh-capabilities/client/assistant-session-navigation-adapter.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/client/assistant-session-navigation-adapter.js +65 -0
- package/data/build/dist/dsh-capabilities/client/assistant-session-navigation-adapter.js.map +1 -1
- package/data/build/dist/host/cli-adapters/acp-cli-driver.d.ts +21 -0
- package/data/build/dist/host/cli-adapters/acp-cli-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/acp-cli-driver.js +100 -3
- package/data/build/dist/host/cli-adapters/acp-cli-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/codex-driver.d.ts +11 -1
- package/data/build/dist/host/cli-adapters/codex-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/codex-driver.js +80 -14
- package/data/build/dist/host/cli-adapters/codex-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/codex-file-citations.d.ts +13 -0
- package/data/build/dist/host/cli-adapters/codex-file-citations.d.ts.map +1 -0
- package/data/build/dist/host/cli-adapters/codex-file-citations.js +271 -0
- package/data/build/dist/host/cli-adapters/codex-file-citations.js.map +1 -0
- package/data/build/dist/host/cli-adapters/command-code-acp-loader.d.ts +8 -1
- package/data/build/dist/host/cli-adapters/command-code-acp-loader.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-acp-loader.js +45 -2
- package/data/build/dist/host/cli-adapters/command-code-acp-loader.js.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-driver.d.ts +8 -2
- package/data/build/dist/host/cli-adapters/command-code-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-driver.js +32 -3
- package/data/build/dist/host/cli-adapters/command-code-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-history.d.ts +27 -0
- package/data/build/dist/host/cli-adapters/command-code-history.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-history.js +131 -1
- package/data/build/dist/host/cli-adapters/command-code-history.js.map +1 -1
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.js +9 -9
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.js.map +1 -1
- package/data/build/dist/host/cli-adapters/dsh-message-projector.d.ts +13 -1
- package/data/build/dist/host/cli-adapters/dsh-message-projector.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/dsh-message-projector.js +95 -12
- package/data/build/dist/host/cli-adapters/dsh-message-projector.js.map +1 -1
- package/data/build/dist/host/cli-adapters/feature.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/feature.js +287 -19
- package/data/build/dist/host/cli-adapters/feature.js.map +1 -1
- package/data/build/dist/host/cli-adapters/grok-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/grok-driver.js +108 -47
- package/data/build/dist/host/cli-adapters/grok-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/legacy-session-settings.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/legacy-session-settings.js +7 -2
- package/data/build/dist/host/cli-adapters/legacy-session-settings.js.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-driver.d.ts +4 -2
- package/data/build/dist/host/cli-adapters/opencode-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-driver.js +78 -31
- package/data/build/dist/host/cli-adapters/opencode-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.d.ts +1 -1
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.js +83 -9
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.js.map +1 -1
- package/data/build/dist/host/cli-adapters/provider-subscription.d.ts +5 -1
- package/data/build/dist/host/cli-adapters/provider-subscription.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/provider-subscription.js +90 -25
- package/data/build/dist/host/cli-adapters/provider-subscription.js.map +1 -1
- package/data/build/dist/host/cli-adapters/registry.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/registry.js +22 -5
- package/data/build/dist/host/cli-adapters/registry.js.map +1 -1
- package/data/build/dist/host/cli-adapters/session-store.d.ts +1 -0
- package/data/build/dist/host/cli-adapters/session-store.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/session-store.js +3 -0
- package/data/build/dist/host/cli-adapters/session-store.js.map +1 -1
- package/data/build/dist/host/cli-bridge/bridge-server.js +2 -2
- package/data/build/dist/host/cli-bridge/bridge-server.js.map +1 -1
- package/data/build/dist/host/cli-bridge/command-code-mod.js +21 -21
- package/data/build/dist/host/cli-bridge/command-code-mod.js.map +1 -1
- package/data/build/dist/host/cli-bridge/dispatch.js +19 -19
- package/data/build/dist/host/cli-bridge/dispatch.js.map +1 -1
- package/data/build/dist/host/cli-bridge/injections.d.ts +32 -0
- package/data/build/dist/host/cli-bridge/injections.d.ts.map +1 -1
- package/data/build/dist/host/cli-bridge/injections.js +137 -1
- package/data/build/dist/host/cli-bridge/injections.js.map +1 -1
- package/data/build/dist/host/cli-bridge/mcp-stdio-entry.js +20 -20
- package/data/build/dist/host/cli-bridge/mcp-stdio-entry.js.map +1 -1
- package/data/build/dist/host/desktop-assistant/controller.d.ts +3 -0
- package/data/build/dist/host/desktop-assistant/controller.d.ts.map +1 -1
- package/data/build/dist/host/desktop-assistant/controller.js +49 -4
- package/data/build/dist/host/desktop-assistant/controller.js.map +1 -1
- package/data/build/dist/host/desktop-assistant/mac-agent.d.ts.map +1 -1
- package/data/build/dist/host/desktop-assistant/mac-agent.js +15 -3
- package/data/build/dist/host/desktop-assistant/mac-agent.js.map +1 -1
- package/data/build/dist/host/desktop-assistant/win-agent.d.ts.map +1 -1
- package/data/build/dist/host/desktop-assistant/win-agent.js +21 -3
- package/data/build/dist/host/desktop-assistant/win-agent.js.map +1 -1
- package/data/build/dist/host/features/assistant-management-tools.d.ts +2 -1
- package/data/build/dist/host/features/assistant-management-tools.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-management-tools.js +10 -3
- package/data/build/dist/host/features/assistant-management-tools.js.map +1 -1
- package/data/build/dist/host/features/assistant-notification-events.js +1 -1
- package/data/build/dist/host/features/assistant-notification-events.js.map +1 -1
- package/data/build/dist/host/features/assistant-notifications.d.ts +8 -1
- package/data/build/dist/host/features/assistant-notifications.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-notifications.js +114 -12
- package/data/build/dist/host/features/assistant-notifications.js.map +1 -1
- package/data/build/dist/host/features/global-voice-rpc.d.ts +2 -2
- package/data/build/dist/host/features/global-voice-rpc.d.ts.map +1 -1
- package/data/build/dist/host/features/global-voice-rpc.js +89 -2
- package/data/build/dist/host/features/global-voice-rpc.js.map +1 -1
- package/data/build/dist/host/features/index.d.ts +1 -0
- package/data/build/dist/host/features/index.d.ts.map +1 -1
- package/data/build/dist/host/features/index.js +3 -0
- package/data/build/dist/host/features/index.js.map +1 -1
- package/data/build/dist/host/features/peer-host.d.ts.map +1 -1
- package/data/build/dist/host/features/peer-host.js +41 -5
- package/data/build/dist/host/features/peer-host.js.map +1 -1
- package/data/build/dist/host/features/session-translation-service.d.ts +31 -0
- package/data/build/dist/host/features/session-translation-service.d.ts.map +1 -0
- package/data/build/dist/host/features/session-translation-service.js +451 -0
- package/data/build/dist/host/features/session-translation-service.js.map +1 -0
- package/data/build/dist/host/features/session-translation.d.ts +5 -0
- package/data/build/dist/host/features/session-translation.d.ts.map +1 -0
- package/data/build/dist/host/features/session-translation.js +37 -0
- package/data/build/dist/host/features/session-translation.js.map +1 -0
- package/data/build/dist/host/features/types.d.ts +6 -1
- package/data/build/dist/host/features/types.d.ts.map +1 -1
- package/data/build/dist/host/image-artifact-store.d.ts +21 -0
- package/data/build/dist/host/image-artifact-store.d.ts.map +1 -0
- package/data/build/dist/host/image-artifact-store.js +136 -0
- package/data/build/dist/host/image-artifact-store.js.map +1 -0
- package/data/build/dist/host/index.d.ts.map +1 -1
- package/data/build/dist/host/index.js +3 -0
- package/data/build/dist/host/index.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.d.ts +7 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.js +23 -4
- package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-protocol.d.ts +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-protocol.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-native-protocol.js +2 -0
- package/data/build/dist/host/modules/peer-host/peer-host-native-protocol.js.map +1 -1
- package/data/build/dist/host/native-session-bridge.d.ts +16 -1
- package/data/build/dist/host/native-session-bridge.d.ts.map +1 -1
- package/data/build/dist/host/native-session-bridge.js +69 -9
- package/data/build/dist/host/native-session-bridge.js.map +1 -1
- package/data/build/dist/host/rpc.js +4 -4
- package/data/build/dist/host/rpc.js.map +1 -1
- package/data/build/dist/host/session-changes.d.ts.map +1 -1
- package/data/build/dist/host/session-changes.js +196 -13
- package/data/build/dist/host/session-changes.js.map +1 -1
- package/data/build/dist/host/settings.d.ts.map +1 -1
- package/data/build/dist/host/settings.js +8 -0
- package/data/build/dist/host/settings.js.map +1 -1
- package/data/build/dist/shared/assistant-message-timeline.d.ts +11 -0
- package/data/build/dist/shared/assistant-message-timeline.d.ts.map +1 -1
- package/data/build/dist/shared/assistant-message-timeline.js +19 -0
- package/data/build/dist/shared/assistant-message-timeline.js.map +1 -1
- package/data/build/dist/shared/assistant-notifications.d.ts +35 -1
- package/data/build/dist/shared/assistant-notifications.d.ts.map +1 -1
- package/data/build/dist/shared/assistant-notifications.js +8 -0
- package/data/build/dist/shared/assistant-notifications.js.map +1 -1
- package/data/build/dist/shared/assistant-session-messages.d.ts +13 -0
- package/data/build/dist/shared/assistant-session-messages.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-session-messages.js +155 -0
- package/data/build/dist/shared/assistant-session-messages.js.map +1 -0
- package/data/build/dist/shared/contracts/assistant.d.ts +13 -0
- package/data/build/dist/shared/contracts/assistant.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/cli-adapter.d.ts +25 -2
- package/data/build/dist/shared/contracts/cli-adapter.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/config.d.ts +6 -0
- package/data/build/dist/shared/contracts/config.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/config.js +3 -0
- package/data/build/dist/shared/contracts/config.js.map +1 -1
- package/data/build/dist/shared/contracts/session-translation.d.ts +58 -0
- package/data/build/dist/shared/contracts/session-translation.d.ts.map +1 -0
- package/data/build/dist/shared/contracts/session-translation.js +23 -0
- package/data/build/dist/shared/contracts/session-translation.js.map +1 -0
- package/data/build/dist/shared/contracts/version.d.ts +1 -1
- package/data/build/dist/shared/contracts/version.js +1 -1
- package/data/build/dist/shared/delegation-carrier.js +6 -6
- package/data/build/dist/shared/delegation-carrier.js.map +1 -1
- package/data/build/dist/shared/desktop-assistant.d.ts +10 -3
- package/data/build/dist/shared/desktop-assistant.d.ts.map +1 -1
- package/data/build/dist/shared/desktop-assistant.js +46 -14
- package/data/build/dist/shared/desktop-assistant.js.map +1 -1
- package/data/build/dist/shared/index.d.ts +2 -1
- package/data/build/dist/shared/index.d.ts.map +1 -1
- package/data/build/dist/shared/index.js +2 -1
- package/data/build/dist/shared/index.js.map +1 -1
- package/package.json +17 -15
- package/profile/README.md +2 -2
- package/profile/package.json +2 -2
- package/profile/version.json +1 -1
- package/version.json +1 -1
- package/data/build/dist/client/peer-host-file-links.d.ts +0 -8
- package/data/build/dist/client/peer-host-file-links.d.ts.map +0 -1
- package/data/build/dist/client/peer-host-file-links.js.map +0 -1
|
@@ -1245,6 +1245,28 @@ window.__ModuleLoader__.load({
|
|
|
1245
1245
|
});
|
|
1246
1246
|
return parts;
|
|
1247
1247
|
}
|
|
1248
|
+
/** 将同一正文位置连续发生的工具归入一个 DSH 风格 step;正文仍保持原有穿插位置。 */
|
|
1249
|
+
function assistantMessageStepTimeline(text, calls = []) {
|
|
1250
|
+
const parts = assistantMessageTimeline(text, calls);
|
|
1251
|
+
const grouped = [];
|
|
1252
|
+
for (const part of parts) {
|
|
1253
|
+
if (part.kind === "text") {
|
|
1254
|
+
grouped.push(part);
|
|
1255
|
+
continue;
|
|
1256
|
+
}
|
|
1257
|
+
const previous = grouped.at(-1);
|
|
1258
|
+
if (previous?.kind === "tool-step") grouped[grouped.length - 1] = {
|
|
1259
|
+
...previous,
|
|
1260
|
+
calls: [...previous.calls, part.call]
|
|
1261
|
+
};
|
|
1262
|
+
else grouped.push({
|
|
1263
|
+
kind: "tool-step",
|
|
1264
|
+
key: `tool-step-${part.call.id}`,
|
|
1265
|
+
calls: [part.call]
|
|
1266
|
+
});
|
|
1267
|
+
}
|
|
1268
|
+
return grouped;
|
|
1269
|
+
}
|
|
1248
1270
|
//#endregion
|
|
1249
1271
|
//#region src/client/features/assistant-record-style.ts
|
|
1250
1272
|
/** 工具记录和通话记录共享交互反馈,选择器只作用于这两类组件。 */
|
|
@@ -1270,14 +1292,21 @@ window.__ModuleLoader__.load({
|
|
|
1270
1292
|
}, (0, react.createElement)("path", { d: "m9 5 7 7-7 7" }));
|
|
1271
1293
|
}
|
|
1272
1294
|
const recordCss = `
|
|
1273
|
-
.codingns-assistant-tool-summary{list-style:none;cursor:pointer
|
|
1295
|
+
.codingns-assistant-tool-summary{list-style:none;cursor:pointer}
|
|
1274
1296
|
.codingns-assistant-tool-summary::-webkit-details-marker{display:none}
|
|
1275
|
-
.codingns-assistant-tool-summary:hover,.codingns-assistant-record-button:hover{
|
|
1276
|
-
.codingns-assistant-tool-summary:active,.codingns-assistant-record-button:active{
|
|
1297
|
+
.codingns-assistant-tool-summary:hover,.codingns-assistant-record-button:hover{color:${require_theme.dshThemeColor.labelPrimary}!important}
|
|
1298
|
+
.codingns-assistant-tool-summary:active,.codingns-assistant-record-button:active{color:${require_theme.dshThemeColor.labelPrimary}!important}
|
|
1277
1299
|
.codingns-assistant-tool-summary:focus-visible,.codingns-assistant-record-button:focus-visible{outline:2px solid ${require_theme.dshThemeColor.accent};outline-offset:2px}
|
|
1278
|
-
.codingns-assistant-tool-details[open]>.codingns-assistant-tool-summary{border-radius:9px 9px 0 0}
|
|
1279
1300
|
.codingns-assistant-tool-details[open] .codingns-assistant-tool-name{white-space:normal!important;overflow-wrap:anywhere}
|
|
1280
1301
|
.codingns-assistant-tool-details[open]>.codingns-assistant-tool-summary .codingns-assistant-record-chevron{transform:rotate(90deg)}
|
|
1302
|
+
.codingns-assistant-tool-step-summary{list-style:none;cursor:pointer}
|
|
1303
|
+
.codingns-assistant-tool-step-summary::-webkit-details-marker{display:none}
|
|
1304
|
+
.codingns-assistant-tool-step-summary:hover{color:${require_theme.dshThemeColor.labelPrimary}!important}
|
|
1305
|
+
.codingns-assistant-tool-step-summary:active{color:${require_theme.dshThemeColor.labelPrimary}!important}
|
|
1306
|
+
.codingns-assistant-tool-step-summary:focus-visible{outline:2px solid ${require_theme.dshThemeColor.accent};outline-offset:2px}
|
|
1307
|
+
.codingns-assistant-tool-step-details[open]>.codingns-assistant-tool-step-summary .codingns-assistant-step-chevron{transform:rotate(180deg)}
|
|
1308
|
+
.codingns-assistant-tool-step-details[open] .codingns-assistant-tool-step-body{padding-inline:4px}
|
|
1309
|
+
.codingns-assistant-tool-step-details[open] .codingns-assistant-tool-step-preview{white-space:normal;overflow-wrap:anywhere}
|
|
1281
1310
|
.codingns-assistant-voice-dialog[open]{display:flex;flex-direction:column}
|
|
1282
1311
|
.codingns-assistant-voice-dialog::backdrop{background:${require_theme.dshThemeColor.overlay}}
|
|
1283
1312
|
`;
|
|
@@ -1336,9 +1365,9 @@ window.__ModuleLoader__.load({
|
|
|
1336
1365
|
}
|
|
1337
1366
|
/** 文字聊天、实时字幕与通话历史共用同一时间线,不额外生成工具汇总区。 */
|
|
1338
1367
|
function AssistantMessageContentView({ text, calls, t }) {
|
|
1339
|
-
return (0, react.createElement)(react.Fragment, null, ...
|
|
1368
|
+
return (0, react.createElement)(react.Fragment, null, ...assistantMessageStepTimeline(text, calls).map((part) => part.kind === "tool-step" ? (0, react.createElement)(AssistantToolStepView, {
|
|
1340
1369
|
key: part.key,
|
|
1341
|
-
calls:
|
|
1370
|
+
calls: part.calls,
|
|
1342
1371
|
t
|
|
1343
1372
|
}) : (0, react.createElement)("div", {
|
|
1344
1373
|
key: part.key,
|
|
@@ -1350,14 +1379,15 @@ window.__ModuleLoader__.load({
|
|
|
1350
1379
|
}, part.text)));
|
|
1351
1380
|
}
|
|
1352
1381
|
/** 工具信息单独展示,不拼入消息正文,字幕与语音合成都只使用原始 text。 */
|
|
1353
|
-
function AssistantToolCallsView({ calls, t }) {
|
|
1382
|
+
function AssistantToolCallsView({ calls, t, compact = false }) {
|
|
1354
1383
|
if (!calls?.length) return null;
|
|
1355
1384
|
return (0, react.createElement)("div", {
|
|
1356
1385
|
"data-codingns-assistant-tools": true,
|
|
1386
|
+
"data-codingns-assistant-tools-compact": compact,
|
|
1357
1387
|
style: {
|
|
1358
1388
|
display: "grid",
|
|
1359
|
-
gap:
|
|
1360
|
-
marginBlock: 6,
|
|
1389
|
+
gap: 2,
|
|
1390
|
+
marginBlock: compact ? 0 : 6,
|
|
1361
1391
|
textAlign: "left",
|
|
1362
1392
|
whiteSpace: "normal",
|
|
1363
1393
|
minWidth: 0
|
|
@@ -1365,26 +1395,113 @@ window.__ModuleLoader__.load({
|
|
|
1365
1395
|
}, (0, react.createElement)(AssistantRecordStyle), ...calls.map((call) => (0, react.createElement)(AssistantToolCallView, {
|
|
1366
1396
|
key: call.id,
|
|
1367
1397
|
call,
|
|
1368
|
-
t
|
|
1398
|
+
t,
|
|
1399
|
+
compact
|
|
1369
1400
|
})));
|
|
1370
1401
|
}
|
|
1402
|
+
/** 一个 step 只显示摘要;展开后才加载其中的工具调用明细。 */
|
|
1403
|
+
function AssistantToolStepView({ calls, t }) {
|
|
1404
|
+
if (calls.length === 0) return null;
|
|
1405
|
+
const running = calls.some((call) => call.state === "running");
|
|
1406
|
+
const failed = calls.some((call) => call.state === "failed");
|
|
1407
|
+
const status = running ? "running" : failed ? "failed" : calls.every((call) => call.state === "cancelled") ? "cancelled" : "completed";
|
|
1408
|
+
const latestCall = calls[calls.length - 1];
|
|
1409
|
+
const latestArguments = assistantToolArgumentPreview(latestCall, t);
|
|
1410
|
+
const summary = calls.map((call) => assistantToolStepPreview(call, t)).filter((value, index, all) => all.indexOf(value) === index).join(t("awb.call.separator"));
|
|
1411
|
+
return (0, react.createElement)("div", {
|
|
1412
|
+
"data-codingns-assistant-tool-step": true,
|
|
1413
|
+
style: {
|
|
1414
|
+
marginBlock: 6,
|
|
1415
|
+
textAlign: "left",
|
|
1416
|
+
whiteSpace: "normal",
|
|
1417
|
+
minWidth: 0,
|
|
1418
|
+
color: require_theme.dshThemeColor.labelSecondary,
|
|
1419
|
+
fontSize: require_theme.uiFontSize(13),
|
|
1420
|
+
lineHeight: 1.6
|
|
1421
|
+
}
|
|
1422
|
+
}, (0, react.createElement)(AssistantRecordStyle), (0, react.createElement)("details", { className: "codingns-assistant-tool-step-details" }, (0, react.createElement)("summary", {
|
|
1423
|
+
className: "codingns-assistant-tool-step-summary",
|
|
1424
|
+
title: t("awb.call.stepDetails"),
|
|
1425
|
+
"aria-label": `${t("awb.call.step")} · ${summary} · ${t(`awb.call.tool.${status}`)}`,
|
|
1426
|
+
style: {
|
|
1427
|
+
display: "flex",
|
|
1428
|
+
alignItems: "center",
|
|
1429
|
+
gap: 8,
|
|
1430
|
+
minWidth: 0,
|
|
1431
|
+
padding: "2px 0",
|
|
1432
|
+
color: require_theme.dshThemeColor.labelSecondary
|
|
1433
|
+
}
|
|
1434
|
+
}, (0, react.createElement)(AssistantStepChevron), (0, react.createElement)("span", {
|
|
1435
|
+
className: "codingns-assistant-tool-step-preview",
|
|
1436
|
+
"data-latest-tool": latestCall.name,
|
|
1437
|
+
title: latestCall.name,
|
|
1438
|
+
style: {
|
|
1439
|
+
minWidth: 0,
|
|
1440
|
+
overflow: "hidden",
|
|
1441
|
+
textOverflow: "ellipsis",
|
|
1442
|
+
whiteSpace: "nowrap"
|
|
1443
|
+
}
|
|
1444
|
+
}, summary, " · ", (0, react.createElement)("code", { style: {
|
|
1445
|
+
color: require_theme.dshThemeColor.labelPrimary,
|
|
1446
|
+
fontFamily: require_theme.dshThemeColor.codeFont,
|
|
1447
|
+
fontSize: "0.92em"
|
|
1448
|
+
} }, latestCall.name), latestArguments ? ` · ${latestArguments}` : "")), (0, react.createElement)("div", {
|
|
1449
|
+
className: "codingns-assistant-tool-step-body",
|
|
1450
|
+
style: {
|
|
1451
|
+
display: "grid",
|
|
1452
|
+
gap: 1,
|
|
1453
|
+
padding: "4px 0 5px 21px"
|
|
1454
|
+
}
|
|
1455
|
+
}, (0, react.createElement)(AssistantToolCallsView, {
|
|
1456
|
+
calls,
|
|
1457
|
+
t,
|
|
1458
|
+
compact: true
|
|
1459
|
+
}))));
|
|
1460
|
+
}
|
|
1461
|
+
function assistantToolStepPreview(call, t) {
|
|
1462
|
+
if (call.name.includes("read") || call.kind === "attachment") return t("awb.call.stepRead");
|
|
1463
|
+
if (call.name.includes("search") || call.kind === "web-search") return t("awb.call.stepSearch");
|
|
1464
|
+
if (call.name.includes("workspace") || call.kind === "workspace") return t("awb.call.stepWorkspace");
|
|
1465
|
+
return t("awb.call.stepTool");
|
|
1466
|
+
}
|
|
1467
|
+
function assistantToolArgumentPreview(call, t) {
|
|
1468
|
+
try {
|
|
1469
|
+
const args = JSON.parse(call.arguments);
|
|
1470
|
+
if (args === null || typeof args !== "object" || Array.isArray(args)) return "";
|
|
1471
|
+
const record = args;
|
|
1472
|
+
for (const key of [
|
|
1473
|
+
"query",
|
|
1474
|
+
"queries",
|
|
1475
|
+
"text",
|
|
1476
|
+
"url",
|
|
1477
|
+
"fileName",
|
|
1478
|
+
"filename",
|
|
1479
|
+
"file",
|
|
1480
|
+
"title",
|
|
1481
|
+
"message"
|
|
1482
|
+
]) {
|
|
1483
|
+
const value = record[key];
|
|
1484
|
+
const preview = typeof value === "string" ? value : Array.isArray(value) ? value.filter((item) => typeof item === "string").join(t("awb.call.separator")) : "";
|
|
1485
|
+
if (preview.trim()) return preview.trim().slice(0, 120);
|
|
1486
|
+
}
|
|
1487
|
+
} catch {}
|
|
1488
|
+
return "";
|
|
1489
|
+
}
|
|
1371
1490
|
/** 整个标题栏就是展开入口;实时状态更新不替换 details,保留用户的展开状态。 */
|
|
1372
|
-
function AssistantToolCallView({ call, t }) {
|
|
1491
|
+
function AssistantToolCallView({ call, t, compact = false }) {
|
|
1373
1492
|
const label = t(call.kind === "web-search" ? "awb.call.webSearch" : call.kind === "attachment" ? "awb.call.attachment" : "awb.call.workspace");
|
|
1374
1493
|
const status = t(`awb.call.tool.${call.state}`);
|
|
1375
|
-
const
|
|
1376
|
-
const
|
|
1377
|
-
return (0, react.createElement)("
|
|
1494
|
+
const argumentPreview = compact ? assistantToolArgumentPreview(call, t) : "";
|
|
1495
|
+
const rowColor = call.state === "failed" ? require_theme.dshThemeColor.error : require_theme.dshThemeColor.labelSecondary;
|
|
1496
|
+
return (0, react.createElement)("div", {
|
|
1497
|
+
"data-codingns-assistant-tool-row": call.name,
|
|
1378
1498
|
"data-codingns-assistant-tool": call.name,
|
|
1379
1499
|
"data-state": call.state,
|
|
1380
1500
|
style: {
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
fontSize: require_theme.uiFontSize(12),
|
|
1386
|
-
lineHeight: 1.4,
|
|
1387
|
-
minWidth: 0
|
|
1501
|
+
minWidth: 0,
|
|
1502
|
+
color: rowColor,
|
|
1503
|
+
fontSize: require_theme.uiFontSize(13),
|
|
1504
|
+
lineHeight: 1.65
|
|
1388
1505
|
}
|
|
1389
1506
|
}, (0, react.createElement)("details", { className: "codingns-assistant-tool-details" }, (0, react.createElement)("summary", {
|
|
1390
1507
|
className: "codingns-assistant-tool-summary",
|
|
@@ -1394,98 +1511,53 @@ window.__ModuleLoader__.load({
|
|
|
1394
1511
|
display: "flex",
|
|
1395
1512
|
alignItems: "center",
|
|
1396
1513
|
gap: 8,
|
|
1397
|
-
|
|
1398
|
-
|
|
1514
|
+
minWidth: 0,
|
|
1515
|
+
padding: "1px 0"
|
|
1399
1516
|
}
|
|
1400
|
-
}, (0, react.createElement)("span", { style: {
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
width: 28,
|
|
1405
|
-
height: 28,
|
|
1406
|
-
borderRadius: 8,
|
|
1407
|
-
color,
|
|
1408
|
-
background: `color-mix(in srgb, ${color} 9%, transparent)`
|
|
1409
|
-
} }, (0, react.createElement)(AssistantToolIcon, { kind: call.kind })), (0, react.createElement)("span", { style: {
|
|
1410
|
-
flex: "1 1 auto",
|
|
1411
|
-
minWidth: 0,
|
|
1412
|
-
display: "grid",
|
|
1413
|
-
gap: 1
|
|
1414
|
-
} }, (0, react.createElement)("strong", { style: {
|
|
1415
|
-
fontSize: require_theme.uiFontSize(12),
|
|
1416
|
-
fontWeight: 600
|
|
1417
|
-
} }, label), (0, react.createElement)("span", {
|
|
1418
|
-
className: "codingns-assistant-tool-name",
|
|
1517
|
+
}, (0, react.createElement)(AssistantRecordChevron), (0, react.createElement)("span", { style: { flexShrink: 0 } }, label), (0, react.createElement)("span", { style: {
|
|
1518
|
+
color: require_theme.dshThemeColor.labelTertiary,
|
|
1519
|
+
flexShrink: 0
|
|
1520
|
+
} }, "·"), (0, react.createElement)("span", {
|
|
1419
1521
|
title: call.name,
|
|
1420
1522
|
style: {
|
|
1421
|
-
|
|
1422
|
-
fontFamily: require_theme.dshThemeColor.codeFont,
|
|
1423
|
-
fontSize: require_theme.uiFontSize(11),
|
|
1523
|
+
minWidth: 0,
|
|
1424
1524
|
overflow: "hidden",
|
|
1425
1525
|
textOverflow: "ellipsis",
|
|
1426
|
-
whiteSpace: "nowrap"
|
|
1427
|
-
|
|
1428
|
-
}, call.name)), (0, react.createElement)("span", { style: {
|
|
1429
|
-
display: "grid",
|
|
1430
|
-
justifyItems: "end",
|
|
1431
|
-
gap: 3,
|
|
1432
|
-
flexShrink: 0
|
|
1433
|
-
} }, (0, react.createElement)("span", {
|
|
1434
|
-
role: "status",
|
|
1435
|
-
style: {
|
|
1436
|
-
display: "inline-flex",
|
|
1437
|
-
alignItems: "center",
|
|
1438
|
-
gap: 4,
|
|
1439
|
-
color,
|
|
1440
|
-
padding: "1px 6px",
|
|
1441
|
-
borderRadius: 5,
|
|
1442
|
-
background: `color-mix(in srgb, ${color} 9%, transparent)`,
|
|
1443
|
-
fontSize: require_theme.uiFontSize(11),
|
|
1444
|
-
whiteSpace: "nowrap"
|
|
1526
|
+
whiteSpace: "nowrap",
|
|
1527
|
+
fontFamily: require_theme.dshThemeColor.codeFont
|
|
1445
1528
|
}
|
|
1446
|
-
}, (0, react.createElement)("
|
|
1447
|
-
"
|
|
1529
|
+
}, call.name, argumentPreview ? ` · ${argumentPreview}` : "")), (0, react.createElement)("div", {
|
|
1530
|
+
className: "codingns-assistant-tool-body",
|
|
1448
1531
|
style: {
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1532
|
+
display: "grid",
|
|
1533
|
+
gap: 0,
|
|
1534
|
+
margin: "2px 0 4px 22px",
|
|
1535
|
+
border: `0.5px solid ${require_theme.dshThemeColor.border}`,
|
|
1536
|
+
borderRadius: 6,
|
|
1537
|
+
overflow: "hidden",
|
|
1538
|
+
minWidth: 0
|
|
1453
1539
|
}
|
|
1454
|
-
}),
|
|
1455
|
-
|
|
1456
|
-
title: startedAt.toLocaleString(),
|
|
1540
|
+
}, ...[[t("awb.call.arguments"), call.arguments], [t("awb.call.result"), call.result]].map(([heading, value], index) => (0, react.createElement)("div", {
|
|
1541
|
+
key: heading,
|
|
1457
1542
|
style: {
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1543
|
+
display: "grid",
|
|
1544
|
+
gridTemplateColumns: "max-content minmax(0, 1fr)",
|
|
1545
|
+
gap: 12,
|
|
1546
|
+
alignItems: "baseline",
|
|
1547
|
+
padding: "7px 10px",
|
|
1548
|
+
minWidth: 0,
|
|
1549
|
+
...index === 0 ? {} : { borderTop: `0.5px solid ${require_theme.dshThemeColor.border}` }
|
|
1462
1550
|
}
|
|
1463
|
-
}, startedAt.toLocaleTimeString([], {
|
|
1464
|
-
hour: "2-digit",
|
|
1465
|
-
minute: "2-digit",
|
|
1466
|
-
second: "2-digit",
|
|
1467
|
-
hour12: false
|
|
1468
|
-
}))), (0, react.createElement)(AssistantRecordChevron)), (0, react.createElement)("div", { style: {
|
|
1469
|
-
display: "grid",
|
|
1470
|
-
gap: 8,
|
|
1471
|
-
padding: "9px 10px 10px",
|
|
1472
|
-
borderTop: `1px solid ${require_theme.dshThemeColor.border}`,
|
|
1473
|
-
minWidth: 0
|
|
1474
|
-
} }, ...[[t("awb.call.arguments"), call.arguments], [t("awb.call.result"), call.result]].map(([heading, value]) => (0, react.createElement)("div", {
|
|
1475
|
-
key: heading,
|
|
1476
|
-
style: { minWidth: 0 }
|
|
1477
1551
|
}, (0, react.createElement)("small", { style: {
|
|
1478
|
-
color: require_theme.dshThemeColor.
|
|
1552
|
+
color: require_theme.dshThemeColor.labelTertiary,
|
|
1479
1553
|
fontSize: require_theme.uiFontSize(11),
|
|
1480
|
-
|
|
1554
|
+
whiteSpace: "nowrap"
|
|
1481
1555
|
} }, heading), (0, react.createElement)("pre", {
|
|
1482
1556
|
tabIndex: 0,
|
|
1483
1557
|
"aria-label": heading,
|
|
1484
1558
|
style: {
|
|
1485
|
-
margin:
|
|
1486
|
-
|
|
1487
|
-
borderRadius: 6,
|
|
1488
|
-
background: require_theme.dshThemeColor.cardBackground,
|
|
1559
|
+
margin: 0,
|
|
1560
|
+
color: require_theme.dshThemeColor.labelSecondary,
|
|
1489
1561
|
maxHeight: 160,
|
|
1490
1562
|
overflowY: "auto",
|
|
1491
1563
|
overscrollBehavior: "contain",
|
|
@@ -1498,18 +1570,23 @@ window.__ModuleLoader__.load({
|
|
|
1498
1570
|
}
|
|
1499
1571
|
}, value || "—"))))));
|
|
1500
1572
|
}
|
|
1501
|
-
function
|
|
1573
|
+
function AssistantStepChevron() {
|
|
1502
1574
|
return (0, react.createElement)("svg", {
|
|
1503
|
-
|
|
1504
|
-
|
|
1575
|
+
className: "codingns-assistant-step-chevron",
|
|
1576
|
+
width: 14,
|
|
1577
|
+
height: 14,
|
|
1505
1578
|
viewBox: "0 0 24 24",
|
|
1506
1579
|
fill: "none",
|
|
1507
1580
|
stroke: "currentColor",
|
|
1508
|
-
strokeWidth: 1.
|
|
1581
|
+
strokeWidth: 1.8,
|
|
1509
1582
|
strokeLinecap: "round",
|
|
1510
1583
|
strokeLinejoin: "round",
|
|
1511
|
-
"aria-hidden": true
|
|
1512
|
-
|
|
1584
|
+
"aria-hidden": true,
|
|
1585
|
+
style: {
|
|
1586
|
+
flexShrink: 0,
|
|
1587
|
+
color: require_theme.dshThemeColor.labelTertiary
|
|
1588
|
+
}
|
|
1589
|
+
}, (0, react.createElement)("path", { d: "m6 9 6 6 6-6" }));
|
|
1513
1590
|
}
|
|
1514
1591
|
//#endregion
|
|
1515
1592
|
//#region src/client/features/assistant-realtime-call.ts
|
|
@@ -2644,12 +2721,7 @@ window.__ModuleLoader__.load({
|
|
|
2644
2721
|
flexDirection: "column",
|
|
2645
2722
|
gap: configuring ? 11 : 16
|
|
2646
2723
|
}
|
|
2647
|
-
}, !loaded ? (0, react.createElement)("div", {
|
|
2648
|
-
role: "status",
|
|
2649
|
-
style: require_theme.dshSettingsHelpStyle
|
|
2650
|
-
}, t("awb.loading"), " ", button(t("awb.retry"), () => {
|
|
2651
|
-
refresh().catch((cause) => setError(message(cause)));
|
|
2652
|
-
})) : null, noticeText ? (0, react.createElement)("div", {
|
|
2724
|
+
}, !loaded ? (0, react.createElement)(AssistantLoadingView, { t }) : null, noticeText ? (0, react.createElement)("div", {
|
|
2653
2725
|
role: "alert",
|
|
2654
2726
|
style: {
|
|
2655
2727
|
color: require_theme.dshThemeColor.error,
|
|
@@ -2852,6 +2924,19 @@ window.__ModuleLoader__.load({
|
|
|
2852
2924
|
model
|
|
2853
2925
|
}));
|
|
2854
2926
|
}
|
|
2927
|
+
/** 首次读取期间使用居中的动态状态,避免把正常等待误显示成失败或重试入口。 */
|
|
2928
|
+
function AssistantLoadingView({ t }) {
|
|
2929
|
+
return (0, react.createElement)("div", {
|
|
2930
|
+
"data-codingns-assistant-loading": true,
|
|
2931
|
+
role: "status",
|
|
2932
|
+
"aria-live": "polite",
|
|
2933
|
+
"aria-label": t("awb.loading"),
|
|
2934
|
+
style: assistantLoadingStyle
|
|
2935
|
+
}, (0, react.createElement)("style", null, assistantLoadingCss), (0, react.createElement)("div", {
|
|
2936
|
+
"aria-hidden": true,
|
|
2937
|
+
style: assistantLoadingOrbStyle
|
|
2938
|
+
}, (0, react.createElement)("span", { className: "codingns-assistant-loading-ring" }), (0, react.createElement)("span", { className: "codingns-assistant-loading-core" }), (0, react.createElement)("span", { className: "codingns-assistant-loading-dot codingns-assistant-loading-dot-one" }), (0, react.createElement)("span", { className: "codingns-assistant-loading-dot codingns-assistant-loading-dot-two" }), (0, react.createElement)("span", { className: "codingns-assistant-loading-dot codingns-assistant-loading-dot-three" })), (0, react.createElement)("div", { style: assistantLoadingLabelStyle }, t("awb.loadingHint")));
|
|
2939
|
+
}
|
|
2855
2940
|
/** 内层菜单先消费 Escape,外层窗口只处理尚未消费的关闭按键。 */
|
|
2856
2941
|
function handleAssistantWorkbenchEscape(event, onClose) {
|
|
2857
2942
|
if (event.key !== "Escape" || event.defaultPrevented) return;
|
|
@@ -2886,6 +2971,47 @@ window.__ModuleLoader__.load({
|
|
|
2886
2971
|
gap: 8,
|
|
2887
2972
|
justifyItems: "center"
|
|
2888
2973
|
};
|
|
2974
|
+
const assistantLoadingStyle = {
|
|
2975
|
+
flex: "1 1 auto",
|
|
2976
|
+
minHeight: "min(420px, 45vh)",
|
|
2977
|
+
display: "flex",
|
|
2978
|
+
flexDirection: "column",
|
|
2979
|
+
alignItems: "center",
|
|
2980
|
+
justifyContent: "center",
|
|
2981
|
+
gap: 18,
|
|
2982
|
+
color: require_theme.dshThemeColor.labelSecondary
|
|
2983
|
+
};
|
|
2984
|
+
const assistantLoadingOrbStyle = {
|
|
2985
|
+
position: "relative",
|
|
2986
|
+
width: 76,
|
|
2987
|
+
height: 76,
|
|
2988
|
+
borderRadius: "50%",
|
|
2989
|
+
background: `radial-gradient(circle at 35% 28%, ${require_theme.dshThemeColor.accent}33, transparent 58%)`,
|
|
2990
|
+
boxShadow: `0 0 0 1px ${require_theme.dshThemeColor.border}, 0 0 42px ${require_theme.dshThemeColor.accent}24`
|
|
2991
|
+
};
|
|
2992
|
+
const assistantLoadingLabelStyle = {
|
|
2993
|
+
fontSize: require_theme.uiFontSize(13),
|
|
2994
|
+
letterSpacing: "0.04em"
|
|
2995
|
+
};
|
|
2996
|
+
const assistantLoadingCss = `
|
|
2997
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-ring,
|
|
2998
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-core,
|
|
2999
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot{position:absolute;display:block;border-radius:50%}
|
|
3000
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-ring{inset:7px;border:1px solid ${require_theme.dshThemeColor.accent}88;border-top-color:transparent;border-left-color:${require_theme.dshThemeColor.accent};animation:codingns-assistant-loading-spin 2.8s linear infinite}
|
|
3001
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-core{inset:22px;background:${require_theme.dshThemeColor.accent};box-shadow:0 0 18px ${require_theme.dshThemeColor.accent}aa;animation:codingns-assistant-loading-breathe 1.8s ease-in-out infinite}
|
|
3002
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot{width:6px;height:6px;background:${require_theme.dshThemeColor.labelPrimary};box-shadow:0 0 10px ${require_theme.dshThemeColor.accent};animation:codingns-assistant-loading-pulse 1.8s ease-in-out infinite}
|
|
3003
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot-one{top:4px;left:35px}
|
|
3004
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot-two{right:7px;bottom:20px;animation-delay:.22s}
|
|
3005
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot-three{left:7px;bottom:20px;animation-delay:.44s}
|
|
3006
|
+
@keyframes codingns-assistant-loading-spin{to{transform:rotate(360deg)}}
|
|
3007
|
+
@keyframes codingns-assistant-loading-breathe{0%,100%{transform:scale(.82);opacity:.72}50%{transform:scale(1.08);opacity:1}}
|
|
3008
|
+
@keyframes codingns-assistant-loading-pulse{0%,100%{transform:scale(.65);opacity:.36}50%{transform:scale(1.15);opacity:1}}
|
|
3009
|
+
@media (prefers-reduced-motion:reduce){
|
|
3010
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-ring,
|
|
3011
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-core,
|
|
3012
|
+
[data-codingns-assistant-loading] .codingns-assistant-loading-dot{animation:none}
|
|
3013
|
+
}
|
|
3014
|
+
`;
|
|
2889
3015
|
const backdrop = {
|
|
2890
3016
|
position: "fixed",
|
|
2891
3017
|
inset: 0,
|