@clubnet/seedclub 0.2.24 → 0.2.25

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.
@@ -69,8 +69,8 @@ function truncateDebugText(value: string): string {
69
69
  return `${lines.slice(0, MAX_DEBUG_TEXT_LINES).join("\n")}\n...[truncated ${lines.length - MAX_DEBUG_TEXT_LINES} lines]`;
70
70
  }
71
71
 
72
- function getDebugText(result: any): string | null {
73
- if (!isUiDebugEnabled()) return null;
72
+ function getDebugText(result: any, expanded: boolean): string | null {
73
+ if (!isUiDebugEnabled() && !expanded) return null;
74
74
  const details = result?.details == null ? null : truncateDebugText(JSON.stringify(result.details, null, 2));
75
75
  const toolText =
76
76
  typeof result?.content?.[0]?.text === "string" ? truncateDebugText(String(result.content[0].text)) : "";
@@ -146,14 +146,14 @@ export function makeProgressResultRenderer(
146
146
  if (result?.isError) {
147
147
  const line = firstTextLine(result?.content) ?? "Request failed";
148
148
  let text = `${theme.fg("error", "✕")} ${theme.fg("error", line)}`;
149
- const debugText = getDebugText(result);
149
+ const debugText = getDebugText(result, options?.expanded === true);
150
150
  if (debugText) text += `\n${theme.fg("dim", debugText)}`;
151
151
  return new Text(text, 0, 0);
152
152
  }
153
153
  const detailText = summary?.(result?.details, context?.args) ?? summarizeDetails(result?.details);
154
154
  let text = `${theme.fg("success", "✓")} ${theme.fg("muted", successLabel)}`;
155
155
  if (detailText) text += theme.fg("dim", ` · ${detailText}`);
156
- const debugText = getDebugText(result);
156
+ const debugText = getDebugText(result, options?.expanded === true);
157
157
  if (debugText) text += `\n${theme.fg("dim", debugText)}`;
158
158
  return new Text(text, 0, 0);
159
159
  };
@@ -92,7 +92,9 @@ let lastCtx: ExtensionContext | undefined;
92
92
  state.contextDisplay = live.contextDisplay;
93
93
  state.costLine = live.costLine;
94
94
  }
95
- state.userLine = footerData.getExtensionStatuses().get("seed") ?? "";
95
+ const seedStatus = footerData.getExtensionStatuses().get("seed") ?? "";
96
+ const viewStatus = footerData.getExtensionStatuses().get("seed-view") ?? "";
97
+ state.userLine = [seedStatus, viewStatus].filter(Boolean).join(" • ");
96
98
  const topRight = theme.fg("dim", `${state.costLine} • ${state.contextDisplay}`);
97
99
  const top = theme.fg("dim", truncateToWidth(state.modelLine, usableWidth));
98
100
  const topAligned = joinLeftRight(top, topRight, usableWidth);
@@ -4,6 +4,31 @@ import { getToolCallLabel } from "../seedclub/ui-copy.js";
4
4
  export default function toolProgressExtension(pi: ExtensionAPI) {
5
5
  let activeTools = 0;
6
6
 
7
+ const applyViewStatus = (ctx: { hasUI: boolean; ui: { getToolsExpanded: () => boolean; setStatus: (key: string, text: string | undefined) => void } }) => {
8
+ if (!ctx.hasUI) return;
9
+ const mode = ctx.ui.getToolsExpanded() ? "advanced" : "standard";
10
+ ctx.ui.setStatus("seed-view", `view: ${mode}`);
11
+ };
12
+
13
+ pi.registerShortcut("alt+o", {
14
+ description: "Toggle advanced tool detail view",
15
+ handler: (ctx) => {
16
+ if (!ctx.hasUI) return;
17
+ const next = !ctx.ui.getToolsExpanded();
18
+ ctx.ui.setToolsExpanded(next);
19
+ applyViewStatus(ctx);
20
+ ctx.ui.notify(next ? "Advanced tool view: on" : "Advanced tool view: off", "info");
21
+ },
22
+ });
23
+
24
+ pi.on("session_start", (_event, ctx) => {
25
+ applyViewStatus(ctx);
26
+ });
27
+
28
+ pi.on("session_switch", (_event, ctx) => {
29
+ applyViewStatus(ctx);
30
+ });
31
+
7
32
  pi.on("tool_execution_start", (event, ctx) => {
8
33
  if (!ctx.hasUI) return;
9
34
  activeTools += 1;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clubnet/seedclub",
3
- "version": "0.2.24",
3
+ "version": "0.2.25",
4
4
  "description": "A branded command-line agent wrapper around pi, with integrated Seed Club commands, tools, and app actions",
5
5
  "license": "MIT",
6
6
  "repository": {