@steerable/agent-shell-web 0.14.4 → 0.14.5

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.
@@ -0,0 +1,57 @@
1
+ /**
2
+ * Product-neutral registry for in-app deliverable preview handlers.
3
+ *
4
+ * Host packs register file matchers and side-panel openers here so
5
+ * `DeliverableCard` can render a first-class `Preview` button without
6
+ * coupling `@steerable/agent-shell-web` to specific document packs.
7
+ */
8
+
9
+ export interface DeliverablePreviewOpenInput {
10
+ chatId: string | null;
11
+ messageId?: string;
12
+ filePath: string;
13
+ }
14
+
15
+ export interface DeliverablePreviewHandler {
16
+ id: string;
17
+ canPreview: (filePath: string) => boolean;
18
+ openPreview: (input: DeliverablePreviewOpenInput) => void;
19
+ }
20
+
21
+ const handlers = new Map<string, DeliverablePreviewHandler>();
22
+ const listeners = new Set<() => void>();
23
+
24
+ function notify(): void {
25
+ for (const listener of listeners) listener();
26
+ }
27
+
28
+ export function registerDeliverablePreviewer(handler: DeliverablePreviewHandler): () => void {
29
+ handlers.set(handler.id, handler);
30
+ notify();
31
+ return () => {
32
+ if (handlers.get(handler.id) === handler) {
33
+ handlers.delete(handler.id);
34
+ notify();
35
+ }
36
+ };
37
+ }
38
+
39
+ export function findDeliverablePreviewer(filePath: string): DeliverablePreviewHandler | null {
40
+ if (!filePath) return null;
41
+ for (const handler of handlers.values()) {
42
+ if (handler.canPreview(filePath)) return handler;
43
+ }
44
+ return null;
45
+ }
46
+
47
+ export function subscribeDeliverablePreviewers(listener: () => void): () => void {
48
+ listeners.add(listener);
49
+ return () => {
50
+ listeners.delete(listener);
51
+ };
52
+ }
53
+
54
+ export function clearDeliverablePreviewersForTests(): void {
55
+ handlers.clear();
56
+ notify();
57
+ }
@@ -1759,6 +1759,8 @@ function AgentChatView({
1759
1759
  chatSlots={ctx.chatSlots}
1760
1760
  rightPanel={ctx.rightPanel}
1761
1761
  openPanelIds={ctx.openPanelIds}
1762
+ hiddenPanelCount={ctx.hiddenPanelCount}
1763
+ hiddenPanelTitle={ctx.hiddenPanelTitle}
1762
1764
  onOpenRightPanel={ctx.onOpenRightPanel}
1763
1765
  showProject={showProjectsChrome}
1764
1766
  project={chatProject}
@@ -1778,7 +1780,7 @@ function AgentChatView({
1778
1780
  : undefined
1779
1781
  }
1780
1782
  onEditUserMessage={hasHostBridge() ? handleEditUserMessage : undefined}
1781
- inputPlaceholder={t("Message the local Agent…")}
1783
+ inputPlaceholder={t("Message the Agent, type / for skills and commands…")}
1782
1784
  agents={ctx.agents}
1783
1785
  chats={ctx.chats}
1784
1786
  currentAgent={agent}
@@ -2107,8 +2109,9 @@ function EmptyChatGate() {
2107
2109
  placeholder={
2108
2110
  mode === "plan"
2109
2111
  ? t("Describe your goal. The Agent will make a plan first…")
2110
- : t("Message the local Agent…")
2112
+ : t("Ask anything, type / for skills and commands…")
2111
2113
  }
2114
+ layoutVariant="hero"
2112
2115
  currentAgent={selectedAgent}
2113
2116
  agents={ctx.agents}
2114
2117
  chats={ctx.chats}
@@ -2119,7 +2122,7 @@ function EmptyChatGate() {
2119
2122
  ? () => setLlmSettingsOpen(true)
2120
2123
  : undefined
2121
2124
  }
2122
- toolbarExtras={
2125
+ toolbarTrailing={
2123
2126
  <ModelPicker
2124
2127
  model={modelOverride}
2125
2128
  reasoningEffort={effortOverride}