@steerable/agent-shell-web 0.6.17 → 0.6.19
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/package.json +12 -19
- package/src/brand.test.ts +22 -0
- package/src/components/AgentSidebar.test.tsx +791 -0
- package/src/components/AgentSidebar.tsx +5 -2
- package/src/components/ChatHeader.test.tsx +230 -0
- package/src/components/LocalLlmSettingsModal.test.tsx +372 -0
- package/src/components/chat/ApprovalModal.test.tsx +83 -0
- package/src/components/chat/AskUserModalHost.test.tsx +176 -0
- package/src/components/chat/AskUserQuestionMenu.test.tsx +190 -0
- package/src/components/chat/AssistantMessage.test.tsx +68 -0
- package/src/components/chat/ChatInput.test.tsx +609 -0
- package/src/components/chat/ExecPolicyPicker.test.tsx +26 -0
- package/src/components/chat/Markdown.test.tsx +170 -0
- package/src/components/chat/ModelPicker.test.tsx +149 -0
- package/src/components/chat/SessionTreeModal.test.tsx +161 -0
- package/src/components/chat/TaskOutcomeCards.test.tsx +97 -0
- package/src/components/chat/TaskPanelModal.test.tsx +198 -0
- package/src/components/chat/TaskProcessPanel.test.tsx +111 -0
- package/src/components/chat/TurnProcessGroup.test.tsx +161 -0
- package/src/components/chat/elapsed.test.ts +42 -0
- package/src/components/chat/executed-actions-model.test.ts +134 -0
- package/src/components/chat/orchestration-children-model.test.ts +115 -0
- package/src/components/chat/turn-timeline.test.ts +97 -0
- package/src/components/chat/useChatTasks.test.ts +136 -0
- package/src/components/settings/AgentsSettingsPanel.test.tsx +229 -0
- package/src/components/settings/InsightsSettingsPanel.test.tsx +132 -0
- package/src/components/settings/LlmSettingsPanel.test.tsx +461 -0
- package/src/components/settings/ModelIdCombobox.test.tsx +88 -0
- package/src/components/settings/SecuritySettingsPanel.test.tsx +122 -0
- package/src/components/settings/SkillsSettingsPanel.test.tsx +62 -0
- package/src/components/settings/WebSearchSettingsPanel.test.tsx +90 -0
- package/src/components/settings/compat-flags-model.test.ts +71 -0
- package/src/components/settings/llm-vendors.test.ts +171 -0
- package/src/components/settings/model-capabilities.test.ts +88 -0
- package/src/components/settings/preset-choice-model.test.ts +96 -0
- package/src/hooks/useChatsAndAgents.test.ts +165 -0
- package/src/lib/attachments.test.ts +127 -0
- package/src/lib/chat-title.test.ts +53 -0
- package/src/lib/chat-transport.test.ts +282 -0
- package/src/lib/chat-transport.ts +1 -2
- package/src/lib/date-groups.test.ts +62 -0
- package/src/lib/demo-flag.test.ts +17 -0
- package/src/lib/electron-bridge.test.ts +54 -0
- package/src/lib/electron-bridge.ts +2 -2
- package/src/lib/exec-policy.test.ts +71 -0
- package/src/lib/http-bridge.test.ts +283 -0
- package/src/lib/http-bridge.ts +18 -4
- package/src/lib/insights.test.ts +56 -0
- package/src/lib/local-api.test.ts +353 -0
- package/src/lib/pending-first-message.test.ts +17 -0
- package/src/lib/slash-sources.test.ts +161 -0
- package/src/pages/AgentPage.test.tsx +627 -0
- package/src/pages/SettingsPage.test.tsx +102 -0
- package/vite.base.ts +94 -0
- package/vite.base.d.ts +0 -7
- package/vite.base.js +0 -83
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@steerable/agent-shell-web",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.19",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Steerable framework — product-neutral renderer SPA source for @steerable/agent-shell (React + Vite). Consumed by product web entry points via the `@/` alias (anchored at this package's src/) and the createProductViteConfig factory. Published as a source package (src/ + vite.base.ts), not a build artifact.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -14,19 +14,13 @@
|
|
|
14
14
|
"url": "https://github.com/pathlyapp/steerable-framework/issues"
|
|
15
15
|
},
|
|
16
16
|
"exports": {
|
|
17
|
-
"./vite.base":
|
|
18
|
-
"types": "./vite.base.d.ts",
|
|
19
|
-
"default": "./vite.base.js"
|
|
20
|
-
},
|
|
17
|
+
"./vite.base": "./vite.base.ts",
|
|
21
18
|
"./package.json": "./package.json"
|
|
22
19
|
},
|
|
23
20
|
"files": [
|
|
24
21
|
"src",
|
|
25
|
-
"!src/**/*.test.ts",
|
|
26
|
-
"!src/**/*.test.tsx",
|
|
27
22
|
"public",
|
|
28
|
-
"vite.base.
|
|
29
|
-
"vite.base.d.ts",
|
|
23
|
+
"vite.base.ts",
|
|
30
24
|
"README.md"
|
|
31
25
|
],
|
|
32
26
|
"publishConfig": {
|
|
@@ -34,8 +28,6 @@
|
|
|
34
28
|
"provenance": true
|
|
35
29
|
},
|
|
36
30
|
"dependencies": {
|
|
37
|
-
"@tailwindcss/vite": "^4.3.0",
|
|
38
|
-
"@vitejs/plugin-react": "^4.7.0",
|
|
39
31
|
"@xterm/addon-fit": "^0.11.0",
|
|
40
32
|
"@xterm/addon-web-links": "^0.12.0",
|
|
41
33
|
"@xterm/xterm": "^6.0.0",
|
|
@@ -47,24 +39,25 @@
|
|
|
47
39
|
"react-router-dom": "^6.30.0",
|
|
48
40
|
"rehype-raw": "^7.0.0",
|
|
49
41
|
"remark-gfm": "^4.0.1",
|
|
50
|
-
"
|
|
51
|
-
"
|
|
52
|
-
"@steerable/agent-protocol": "0.6.17",
|
|
53
|
-
"@steerable/agent-ui": "0.6.17",
|
|
54
|
-
"@steerable/pack-sdk": "0.6.17"
|
|
42
|
+
"@steerable/agent-protocol": "0.6.19",
|
|
43
|
+
"@steerable/agent-ui": "0.6.19"
|
|
55
44
|
},
|
|
56
45
|
"devDependencies": {
|
|
46
|
+
"@tailwindcss/vite": "^4.3.0",
|
|
57
47
|
"@testing-library/react": "^16.1.0",
|
|
58
48
|
"@types/react": "^18.3.12",
|
|
59
49
|
"@types/react-dom": "^18.3.1",
|
|
50
|
+
"@vitejs/plugin-react": "^4.7.0",
|
|
60
51
|
"happy-dom": "^15.11.7",
|
|
52
|
+
"tailwindcss": "^4.3.0",
|
|
61
53
|
"typescript": "^5.8.3",
|
|
62
|
-
"
|
|
54
|
+
"vite": "^5.4.21",
|
|
55
|
+
"vitest": "^3.2.4",
|
|
56
|
+
"@steerable/pack-sdk": "0.6.19"
|
|
63
57
|
},
|
|
64
58
|
"scripts": {
|
|
65
59
|
"gen": "echo agent-shell-web",
|
|
66
|
-
"build": "tsc --noEmit
|
|
67
|
-
"build:vite-base": "tsc vite.base.ts --module esnext --target es2022 --moduleResolution bundler --declaration --skipLibCheck --outDir .",
|
|
60
|
+
"build": "tsc --noEmit",
|
|
68
61
|
"typecheck": "tsc --noEmit",
|
|
69
62
|
"test": "vitest run",
|
|
70
63
|
"lint": "tsc --noEmit",
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { describe, expect, it } from 'vitest';
|
|
2
|
+
import { LOCAL_ASSISTANT_AGENT_ID, pickDefaultAgentId } from './brand';
|
|
3
|
+
|
|
4
|
+
describe('pickDefaultAgentId', () => {
|
|
5
|
+
const catalog = [
|
|
6
|
+
{ id: LOCAL_ASSISTANT_AGENT_ID },
|
|
7
|
+
{ id: 'data-analyst' },
|
|
8
|
+
{ id: 'all-round-assistant' },
|
|
9
|
+
];
|
|
10
|
+
|
|
11
|
+
it('returns null when the catalog is empty', () => {
|
|
12
|
+
expect(pickDefaultAgentId([])).toBeNull();
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
it('prefers the build-time default (shell: 电脑操作员) even when it is not first', () => {
|
|
16
|
+
expect(pickDefaultAgentId(catalog)).toBe(LOCAL_ASSISTANT_AGENT_ID);
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
it('falls back to the first visible agent when the build default is absent', () => {
|
|
20
|
+
expect(pickDefaultAgentId([{ id: 'writer' }, { id: 'reader' }])).toBe('writer');
|
|
21
|
+
});
|
|
22
|
+
});
|