@wrongstack/webui 0.318.0 → 0.319.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.
Files changed (86) hide show
  1. package/dist/assets/{AgentRosterView-C46rL23K.js → AgentRosterView-BVpIFQwi.js} +1 -1
  2. package/dist/assets/{AnalyticsDashboard-B8r_8kNv.js → AnalyticsDashboard-nqlWJi6M.js} +1 -1
  3. package/dist/assets/{AudienceMemoryPanel-Ciybycpn.js → AudienceMemoryPanel-BT6C4Jkw.js} +1 -1
  4. package/dist/assets/{ChangesView-BREfCsEq.js → ChangesView-CN7NWDeV.js} +1 -1
  5. package/dist/assets/{ChimeraReviewsView-aSYmQ8tC.js → ChimeraReviewsView-BNQE5kRx.js} +1 -1
  6. package/dist/assets/{ChronicleDashboard-bo2jv52s.js → ChronicleDashboard-BWMkG_hu.js} +1 -1
  7. package/dist/assets/{CodeEditor-C_KzNkIb.js → CodeEditor-DZ2k-Mz5.js} +1 -1
  8. package/dist/assets/{CodeMap-DA_k3u5g.js → CodeMap-CLOuNLqN.js} +1 -1
  9. package/dist/assets/{ConfirmModal-gukSikBD.js → ConfirmModal-B6BGiiN8.js} +1 -1
  10. package/dist/assets/{CronJobsPanel-D-43oYQ-.js → CronJobsPanel-CsMIoWVQ.js} +1 -1
  11. package/dist/assets/{DeadCodeScanPanel-VnMQatbH.js → DeadCodeScanPanel-DooqnEMF.js} +1 -1
  12. package/dist/assets/{DebugDashboard-DNDadwro.js → DebugDashboard-C0tmxxV8.js} +1 -1
  13. package/dist/assets/{DesignGalleryView-B9ZMJPOQ.js → DesignGalleryView-lc-XRmVG.js} +1 -1
  14. package/dist/assets/{GoalView-BkoCNN8l.js → GoalView-BuYUc4OB.js} +1 -1
  15. package/dist/assets/{KanbanView-nql6LkaS.js → KanbanView-DQK6adut.js} +1 -1
  16. package/dist/assets/{MailboxDetailView-CdHRfnNq.js → MailboxDetailView-CBV3-Hf2.js} +1 -1
  17. package/dist/assets/{MemoryDrawer-CfukdhlF.js → MemoryDrawer-rPf-1Ulk.js} +1 -1
  18. package/dist/assets/{MemoryManager-BD_VnFAu.js → MemoryManager-B_ZJhOqq.js} +1 -1
  19. package/dist/assets/{ModelPicker-C3r7IFfh.js → ModelPicker-CLs0qQgg.js} +1 -1
  20. package/dist/assets/{OfficeMapPanel-B47jfEHf.js → OfficeMapPanel-DnbdkXL1.js} +1 -1
  21. package/dist/assets/{ProcessMonitor-CvHdN8Bn.js → ProcessMonitor-CHNNqCk9.js} +1 -1
  22. package/dist/assets/{PromptJournalView-CXZ9notj.js → PromptJournalView-Biu4DknM.js} +1 -1
  23. package/dist/assets/{QueuePanel-DOcgHRH3.js → QueuePanel-CzTXq6j4.js} +1 -1
  24. package/dist/assets/{RefreshDebugView-BYmeORMQ.js → RefreshDebugView-d9iU3sFX.js} +1 -1
  25. package/dist/assets/{RequirementIntakeView-CFgVx_0T.js → RequirementIntakeView-g9dzUTVw.js} +1 -1
  26. package/dist/assets/{SageTabs-BRJG0fhZ.js → SageTabs-Bw6PDwy3.js} +2 -2
  27. package/dist/assets/{SddFlowGraph-BsfhxlDK.js → SddFlowGraph-Bj_Aqq5B.js} +1 -1
  28. package/dist/assets/{SddHub-Br1vyCgq.js → SddHub-Cdow0Exb.js} +1 -1
  29. package/dist/assets/{SessionInspectView-BSRjWErA.js → SessionInspectView-je_xLISf.js} +1 -1
  30. package/dist/assets/{SessionList-BkaI91oW.js → SessionList-4y1uuB-y.js} +1 -1
  31. package/dist/assets/{SessionsDashboard-BEQs4Div.js → SessionsDashboard-DkaNF5lx.js} +1 -1
  32. package/dist/assets/{SetupScreen-zY4541lT.js → SetupScreen-DWzbXvmU.js} +1 -1
  33. package/dist/assets/{SkillDetailView-DqxkOnb8.js → SkillDetailView-Bjq8GkDB.js} +1 -1
  34. package/dist/assets/{SpecsView-COS0-sxq.js → SpecsView-ok8HZ8ws.js} +1 -1
  35. package/dist/assets/{TechStackView-Dr8vI0hK.js → TechStackView-CQ9AdoBa.js} +1 -1
  36. package/dist/assets/{TerminalPanel-DlIyvxm6.js → TerminalPanel-cbM6oQWQ.js} +1 -1
  37. package/dist/assets/{activity-q85HXQNv.js → activity-BU6MNvBJ.js} +1 -1
  38. package/dist/assets/{activity-B2_Vr2oD.js → activity-C7dkJqBU.js} +1 -1
  39. package/dist/assets/{activity-DYMBKGt0.js → activity-C_18AaRY.js} +1 -1
  40. package/dist/assets/{activity-IxgYWPDt.js → activity-CpnSsE22.js} +1 -1
  41. package/dist/assets/{activity-BF1idM4Y.js → activity-CtTKsSX6.js} +1 -1
  42. package/dist/assets/{activity-C-kOJZXC.js → activity-D1rp3dH9.js} +1 -1
  43. package/dist/assets/{activity-DPpMW8BU.js → activity-hTPcI4q1.js} +1 -1
  44. package/dist/assets/{chat-DTI7lNDx.js → chat-6dE2AJNN.js} +1 -1
  45. package/dist/assets/{chat-BvKkSd09.js → chat-B3AJmhGD.js} +1 -1
  46. package/dist/assets/{chat-BNWqeV-N.js → chat-BHsbpaVt.js} +1 -1
  47. package/dist/assets/{chat-BlllxfpP.js → chat-BITJe8-v.js} +1 -1
  48. package/dist/assets/{chat-DlhXGxxi.js → chat-U-Jjb8_k.js} +1 -1
  49. package/dist/assets/{chat-B60h8Cji.js → chat-_Xp5fDnj.js} +1 -1
  50. package/dist/assets/{chat-B5a3cvps.js → chat-mSbSzPl5.js} +1 -1
  51. package/dist/assets/{chat-store-DIcs826A.js → chat-store-oW_-zcJP.js} +1 -1
  52. package/dist/assets/{i18n-Cv65b1SP.js → i18n-D06uU1PM.js} +2 -2
  53. package/dist/assets/index-CWYymMpa.css +1 -0
  54. package/dist/assets/index-Cwjer17r.js +144 -0
  55. package/dist/assets/{roster-ws-D5JW3IPJ.js → roster-ws-BQUI8QuW.js} +1 -1
  56. package/dist/assets/setup-B0D9CK3-.js +1 -0
  57. package/dist/assets/setup-B58YVaGU.js +1 -0
  58. package/dist/assets/setup-C2H9Uv0Q.js +1 -0
  59. package/dist/assets/setup-CzM4dkkU.js +1 -0
  60. package/dist/assets/setup-Di56FlHP.js +1 -0
  61. package/dist/assets/setup-Dwt58Mpz.js +1 -0
  62. package/dist/assets/setup-DznVdlJy.js +1 -0
  63. package/dist/assets/{stores-CNuMLG8X.js → stores-C7Vvce-6.js} +1 -1
  64. package/dist/assets/ui-store-Dm7ujR9u.js +1 -0
  65. package/dist/assets/useWebSocket-9lfOsI_r.js +27 -0
  66. package/dist/assets/{view-navigation-DPOY0lyt.js → view-navigation-wOKaM_Rf.js} +1 -1
  67. package/dist/assets/{ws-client-D-d32pHb.js → ws-client-DtTZLD8e.js} +2 -2
  68. package/dist/index.html +14 -14
  69. package/dist/index.js +1065 -543
  70. package/dist/lib/launch-builtin-round.d.ts +43 -0
  71. package/dist/lib/perf-run-message.d.ts +51 -0
  72. package/dist/stores/fleet-store.d.ts +4 -0
  73. package/dist/stores/types.d.ts +9 -0
  74. package/dist/stores/ui-store.d.ts +0 -2
  75. package/package.json +10 -10
  76. package/dist/assets/index-DSyVpLgL.css +0 -1
  77. package/dist/assets/index-DbprKWmG.js +0 -137
  78. package/dist/assets/setup-BQLPzL3N.js +0 -1
  79. package/dist/assets/setup-C9lrNwQF.js +0 -1
  80. package/dist/assets/setup-CcxP7cUl.js +0 -1
  81. package/dist/assets/setup-CtKKNpH9.js +0 -1
  82. package/dist/assets/setup-D4rp2jda.js +0 -1
  83. package/dist/assets/setup-MvmOtwNp.js +0 -1
  84. package/dist/assets/setup-blxUcxNU.js +0 -1
  85. package/dist/assets/ui-store-DpKUBLWd.js +0 -1
  86. package/dist/assets/useWebSocket-VIItbvVK.js +0 -27
@@ -0,0 +1,43 @@
1
+ import type { WrongStackWebSocketClient } from '@/lib/ws-client';
2
+ /**
3
+ * Shared launcher for the one-click built-in rounds (Bug Hunter, Performance
4
+ * Ratchet).
5
+ *
6
+ * Both cards do the same four-step dance: optionally flip the session to solo,
7
+ * ask the server for a builtin prompt body, compose the message, and send it —
8
+ * with a single timeout and a single settle path so a half-finished launch can
9
+ * never leave the button spinning forever. Extracting it means a fix to the
10
+ * settle logic lands for both cards instead of one.
11
+ */
12
+ /**
13
+ * The slice of the WS client these launchers use.
14
+ *
15
+ * Derived from the real client rather than restated structurally: `send` takes
16
+ * a discriminated union of message shapes, and a hand-written `{type: string}`
17
+ * signature would silently accept a message type the server does not handle.
18
+ */
19
+ export type RoundLauncherClient = Pick<WrongStackWebSocketClient, 'isConnected' | 'on' | 'send' | 'sendMessage'>;
20
+ export interface LaunchBuiltinRoundOptions {
21
+ client: RoundLauncherClient;
22
+ /** Builtin prompt slug to fetch. */
23
+ slug: string;
24
+ /**
25
+ * Force the session solo before starting. A round that attributes one
26
+ * outcome to one change cannot be fanned out across subagents.
27
+ */
28
+ requireSoloSession: boolean;
29
+ subagentsAllowed: boolean;
30
+ sessionId?: string | undefined;
31
+ setPrefs(patch: {
32
+ subagentsAllowed: boolean;
33
+ }): void;
34
+ /** Wrap the fetched prompt body into the message that gets sent. */
35
+ compose(content: string): string;
36
+ /** Called with the sent message id and text, to mirror it into the transcript. */
37
+ onSent(id: string, text: string): void;
38
+ onSettle(state: 'idle' | 'error'): void;
39
+ /** Defaults to 8s — long enough for a cold prompt store, short enough to notice. */
40
+ timeoutMs?: number;
41
+ }
42
+ export declare function launchBuiltinRound(options: LaunchBuiltinRoundOptions): void;
43
+ //# sourceMappingURL=launch-builtin-round.d.ts.map
@@ -0,0 +1,51 @@
1
+ /**
2
+ * Durable display metadata for a one-click performance round.
3
+ *
4
+ * The agent receives the full prompt; the transcript shows a two-line card. The
5
+ * marker is an HTML comment so it survives a session reload without a parallel
6
+ * sidecar store, and so a replayed round still renders as a round rather than
7
+ * as a wall of pasted instructions.
8
+ *
9
+ * Mirrors `bug-hunt-message.ts` — same shape, same guarantees.
10
+ */
11
+ /** Keep in sync with `PERF_MODE_IDS` in `@wrongstack/core/performance`. */
12
+ export declare const PERF_RUN_MODES: readonly ['ratchet', 'audit', 'triage', 'memory', 'io', 'cpu', 'guard', 'contract'];
13
+ export type PerfRunMode = (typeof PERF_RUN_MODES)[number];
14
+ /** Keep in sync with `PERF_METRIC_IDS` in `@wrongstack/core/performance`. */
15
+ export declare const PERF_RUN_METRICS: readonly ['wall-ms', 'p99-latency-ms', 'peak-rss-bytes', 'throughput-ops', 'allocs-per-op', 'cold-start-ms', 'bundle-bytes'];
16
+ export type PerfRunMetric = (typeof PERF_RUN_METRICS)[number];
17
+ export interface PerfRunSummary {
18
+ scope: string;
19
+ mode: PerfRunMode;
20
+ /** Empty string means "whichever metric the workload actually feels". */
21
+ metric: PerfRunMetric | '';
22
+ }
23
+ /**
24
+ * Card labels for the transcript chip.
25
+ *
26
+ * Kept next to the mode list rather than in the i18n catalog, matching the
27
+ * sibling Bug Hunter card: these are the names of built-in modes, and a
28
+ * translated mode name would not match the `/perf <mode>` the user types.
29
+ */
30
+ export declare const PERF_RUN_MODE_LABELS: Record<PerfRunMode, string>;
31
+ export declare const PERF_RUN_METRIC_LABELS: Record<PerfRunMetric, string>;
32
+ /**
33
+ * Mode → builtin prompt slug.
34
+ *
35
+ * Mirrors `PERF_MODES` in `@wrongstack/core/performance`. `perf-run-message.test.ts`
36
+ * pins the two together, so a mode added on one side cannot silently 404 here.
37
+ */
38
+ export declare const PERF_MODE_SLUGS: Record<PerfRunMode, string>;
39
+ /**
40
+ * Modes that may change production code, and therefore run solo.
41
+ *
42
+ * A read-only mode must NOT flip the user's subagent policy: silently
43
+ * disabling their fleet to produce a report is a side effect they did not ask
44
+ * for, and the policy locks after the first message.
45
+ */
46
+ export declare const PERF_MUTATING_MODES: ReadonlySet<PerfRunMode>;
47
+ /** Adds durable display metadata without changing the instruction sent to the agent. */
48
+ export declare function buildPerfRunMessage(instruction: string, summary: PerfRunSummary): string;
49
+ /** Recognizes a persisted performance round and recovers its compact display data. */
50
+ export declare function parsePerfRunMessage(content: string): PerfRunSummary | undefined;
51
+ //# sourceMappingURL=perf-run-message.d.ts.map
@@ -46,6 +46,10 @@ export interface FleetState {
46
46
  * roster. Scoped: only agents belonging to `sessionId` are removed, so a
47
47
  * panel in one tab never drops another tab's finished agents. */
48
48
  clearFinishedAgents: (sessionId: string | null) => void;
49
+ /** Remove ONE agent from the roster (AgentTabs close affordance). Same
50
+ * cleanup path as clearFinishedAgents — transcripts, timelines, token
51
+ * totals and the leader pointer all follow the agent out. */
52
+ removeAgent: (subagentId: string) => void;
49
53
  }
50
54
  export declare const useFleetStore: import("zustand").UseBoundStore<import("zustand").StoreApi<FleetState>>;
51
55
  /** Pre-computed fleet-wide summary statistics. */
@@ -1,4 +1,5 @@
1
1
  import type { Usage } from '@wrongstack/core/types';
2
+ import type { PerfRunMetric, PerfRunMode } from '@/lib/perf-run-message';
2
3
  export type CouncilVoteStatus = 'valid' | 'invalid' | 'failed' | 'cancelled';
3
4
  /** One council seat's observable vote. No hidden chain-of-thought is retained. */
4
5
  export interface CouncilSeatVote {
@@ -52,6 +53,14 @@ export interface ChatMessage {
52
53
  scope: string;
53
54
  maxBugs: 1 | 2 | 3;
54
55
  } | undefined;
56
+ /** The same treatment for a built-in performance ratchet round: the full
57
+ * prompt goes to the agent, the transcript shows the mode, scope, and the
58
+ * metric the round is optimising. */
59
+ perfRun?: {
60
+ scope: string;
61
+ mode: PerfRunMode;
62
+ metric: PerfRunMetric | '';
63
+ } | undefined;
55
64
  role: 'user' | 'assistant' | 'system' | 'tool';
56
65
  toolName?: string | undefined;
57
66
  toolInput?: unknown | undefined;
@@ -154,8 +154,6 @@ interface UIState {
154
154
  subagentChatFocusId: string | null;
155
155
  /** Which session the flat `subagentChatFocusId` describes. */
156
156
  subagentChatFocusSessionId: string | null;
157
- /** Per-tab subagent focus, so switching tabs restores what each was showing. */
158
- subagentChatFocusBySession: Record<string, string | null>;
159
157
  /** Process Monitor overlay — triggered by /kill slash command. */
160
158
  processMonitorOpen: boolean;
161
159
  /** Queue Panel overlay — triggered by /queue slash command. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wrongstack/webui",
3
- "version": "0.318.0",
3
+ "version": "0.319.0",
4
4
  "license": "MIT",
5
5
  "description": "Browser-based WebUI for WrongStack — React + Vite frontend. The WebSocket backend lives in the separate @wrongstack/webui-server package (extracted in PR #018b to remove the CLI -> @wrongstack/webui/server cross-package edge).",
6
6
  "keywords": [
@@ -57,13 +57,13 @@
57
57
  "@radix-ui/react-tabs": "^1.1.21",
58
58
  "@tanstack/react-virtual": "^3.14.10",
59
59
  "@uiw/react-textarea-code-editor": "^3.1.1",
60
- "@wrongstack/core": "0.318.0",
61
- "@wrongstack/kanban": "0.318.0",
62
- "@wrongstack/plugins": "0.318.0",
63
- "@wrongstack/providers": "0.318.0",
64
- "@wrongstack/tools": "0.318.0",
65
- "@wrongstack/webui-protocol": "0.318.0",
66
- "@wrongstack/webui-server": "0.318.0",
60
+ "@wrongstack/core": "0.319.0",
61
+ "@wrongstack/kanban": "0.319.0",
62
+ "@wrongstack/plugins": "0.319.0",
63
+ "@wrongstack/providers": "0.319.0",
64
+ "@wrongstack/tools": "0.319.0",
65
+ "@wrongstack/webui-protocol": "0.319.0",
66
+ "@wrongstack/webui-server": "0.319.0",
67
67
  "@xterm/addon-fit": "^0.11.0",
68
68
  "@xterm/xterm": "^6.0.0",
69
69
  "@xyflow/react": "^12.11.3",
@@ -85,7 +85,7 @@
85
85
  "zustand": "^5.0.15"
86
86
  },
87
87
  "optionalDependencies": {
88
- "node-pty": "1.2.0-beta.14"
88
+ "node-pty": "1.1.0"
89
89
  },
90
90
  "devDependencies": {
91
91
  "@playwright/test": "^1.62.1",
@@ -99,7 +99,7 @@
99
99
  "@types/ws": "^8.18.1",
100
100
  "@vitejs/plugin-react": "^6.1.0",
101
101
  "@vitest/coverage-v8": "^4.1.11",
102
- "@wrongstack/sdd": "0.318.0",
102
+ "@wrongstack/sdd": "0.319.0",
103
103
  "jsdom": "^30.0.1",
104
104
  "tailwindcss": "^4.3.3",
105
105
  "typescript": "^7.0.2",