mixdog 0.8.0 → 0.8.1

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.
@@ -1451,7 +1451,6 @@ var CATEGORY_ORDER = [
1451
1451
  "Memory",
1452
1452
  "Explore",
1453
1453
  "Patch",
1454
- "Edit",
1455
1454
  "Shell",
1456
1455
  "Agent",
1457
1456
  "Channel",
@@ -1485,8 +1484,6 @@ var TOOL_CATEGORY = /* @__PURE__ */ new Map([
1485
1484
  ["memory", "Memory"],
1486
1485
  ["explore", "Explore"],
1487
1486
  ["apply_patch", "Patch"],
1488
- ["write", "Edit"],
1489
- ["edit", "Edit"],
1490
1487
  ["bash", "Shell"],
1491
1488
  ["shell", "Shell"],
1492
1489
  ["shell_command", "Shell"],
@@ -1535,7 +1532,6 @@ var CATEGORY_COPY = /* @__PURE__ */ new Map([
1535
1532
  ["Memory", { active: "Checking", done: "Checked", noun: "memory item" }],
1536
1533
  ["Explore", { active: "Exploring", done: "Explored", noun: "item" }],
1537
1534
  ["Patch", { active: "Editing", done: "Edited", noun: "item" }],
1538
- ["Edit", { active: "Editing", done: "Edited", noun: "item" }],
1539
1535
  ["Shell", { active: "Running", done: "Ran", noun: "command" }],
1540
1536
  ["Agent", { active: "Calling", done: "Called", noun: "agent" }],
1541
1537
  ["Channel", { active: "Sending", done: "Sent", noun: "message" }],
@@ -1655,6 +1651,7 @@ import { jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
1655
1651
  var MIN_RESULT_LINE_CHARS = 24;
1656
1652
  var SUMMARY_MAX_CHARS = 48;
1657
1653
  var TOOL_BLINK_MS = 500;
1654
+ var TOOL_BLINK_LIMIT_MS = 3e3;
1658
1655
  var TOOL_PENDING_SHOW_DELAY_MS = 1e3;
1659
1656
  var TOOL_HINT_DONE_COLOR = theme.subtle;
1660
1657
  var COUNT_TWEEN_MS = 700;
@@ -1840,8 +1837,6 @@ function statusCopy(normalizedName, label, count, doneCount, pending, isError) {
1840
1837
  case "view_image":
1841
1838
  case "read_mcp_resource":
1842
1839
  return copy("Reading", "Read", "file");
1843
- case "write":
1844
- case "edit":
1845
1840
  case "apply_patch":
1846
1841
  return copy("Editing", "Edited", "file");
1847
1842
  case "grep":
@@ -2082,7 +2077,7 @@ function progressDetail({ normalizedName, label, elapsed }) {
2082
2077
  if (n === "explore" || l === "explore") return `Exploring${suffix}`;
2083
2078
  if (n === "grep" || n === "glob" || n === "list" || n === "ls" || l === "search") return `Searching${suffix}`;
2084
2079
  if (n === "read" || n === "view_image" || n === "read_mcp_resource" || l === "read") return `Reading${suffix}`;
2085
- if (n === "write" || n === "edit" || n === "apply_patch" || l === "update") return `Editing${suffix}`;
2080
+ if (n === "apply_patch" || l === "update") return `Editing${suffix}`;
2086
2081
  if (n === "recall" || n === "recall_memory" || n === "search_memories" || l === "memory") return `Checking Memory${suffix}`;
2087
2082
  if (l === "setup") return `Setting Up${suffix}`;
2088
2083
  return `Working${suffix}`;
@@ -2117,6 +2112,7 @@ function toolStatusColor({ pending, groupCount, failedCount }) {
2117
2112
  }
2118
2113
  function ToolExecution({ name, args, result, rawResult, isError, errorCount, expanded, globalExpanded = false, columns = 80, attached = false, count = 1, completedCount = 0, startedAt = 0, completedAt = 0, aggregate = false, categories = {}, headerFinalized = true }) {
2119
2114
  const [blinkOn, setBlinkOn] = useState(true);
2115
+ const [blinkExpired, setBlinkExpired] = useState(false);
2120
2116
  const [pendingDelayElapsed, setPendingDelayElapsed] = useState(false);
2121
2117
  const groupCount = Math.max(1, Number(count || 1));
2122
2118
  const doneCount = Math.max(0, Math.min(groupCount, Number(completedCount || (result == null ? 0 : groupCount))));
@@ -2158,10 +2154,28 @@ function ToolExecution({ name, args, result, rawResult, isError, errorCount, exp
2158
2154
  return () => clearTimeout(timer);
2159
2155
  }, [pending, startedAt]);
2160
2156
  useEffect(() => {
2161
- if (!pending || !pendingDisplayReady) return void 0;
2157
+ if (!pending || !pendingDisplayReady || blinkExpired) {
2158
+ setBlinkOn(true);
2159
+ return void 0;
2160
+ }
2162
2161
  const timer = setInterval(() => setBlinkOn((on) => !on), TOOL_BLINK_MS);
2163
2162
  return () => clearInterval(timer);
2164
- }, [pending, pendingDisplayReady]);
2163
+ }, [pending, pendingDisplayReady, blinkExpired]);
2164
+ useEffect(() => {
2165
+ if (!pending || !pendingDisplayReady) {
2166
+ setBlinkExpired(false);
2167
+ return void 0;
2168
+ }
2169
+ const started = Number(startedAt || 0);
2170
+ const remaining = TOOL_BLINK_LIMIT_MS - (started ? Math.max(0, Date.now() - started) : 0);
2171
+ if (remaining <= 0) {
2172
+ setBlinkExpired(true);
2173
+ return void 0;
2174
+ }
2175
+ setBlinkExpired(false);
2176
+ const timer = setTimeout(() => setBlinkExpired(true), remaining);
2177
+ return () => clearTimeout(timer);
2178
+ }, [pending, pendingDisplayReady, startedAt]);
2165
2179
  if (pending && !pendingDisplayReady) return null;
2166
2180
  if (aggregate) {
2167
2181
  const headerOrder = Array.isArray(args?.categoryOrder) ? args.categoryOrder : null;
@@ -2175,7 +2189,7 @@ function ToolExecution({ name, args, result, rawResult, isError, errorCount, exp
2175
2189
  detailText = "";
2176
2190
  }
2177
2191
  const dotColor2 = statusColor;
2178
- const dotText2 = pending && !blinkOn ? " " : TURN_MARKER;
2192
+ const dotText2 = pending && !blinkExpired && !blinkOn ? " " : TURN_MARKER;
2179
2193
  const gutter2 = 2;
2180
2194
  const showHeaderExpandHint2 = hasRawResult;
2181
2195
  const hintLabel2 = showHeaderExpandHint2 ? `ctrl+o ${expanded ? "collapse" : "expand"}` : "";
@@ -2229,7 +2243,7 @@ function ToolExecution({ name, args, result, rawResult, isError, errorCount, exp
2229
2243
  const isAgentResponse = isAgentResult && hasAgentResponseResult(rt);
2230
2244
  const isAgentMetadataResult = isAgentResult && !isAgentResponse;
2231
2245
  const dotColor = statusColor;
2232
- const dotText = pending && !blinkOn ? " " : TURN_MARKER;
2246
+ const dotText = pending && !blinkExpired && !blinkOn ? " " : TURN_MARKER;
2233
2247
  let labelText;
2234
2248
  if (isAgentResponse) labelText = agentResponseTitle(parsedArgs);
2235
2249
  else if (isBackgroundResponse) labelText = backgroundTaskResultTitle(normalizedName, backgroundMeta || parsedArgs);
@@ -3845,32 +3859,55 @@ function ProgressBar({ value = 0, total = 0, width = 24 }) {
3845
3859
  function metricValue(parts) {
3846
3860
  return parts.filter(Boolean).join(" \xB7 ");
3847
3861
  }
3848
- function MetricCell({ label, value, width, tone }) {
3849
- const labelWidth = Math.min(12, Math.max(8, Math.floor(width * 0.34)));
3850
- const valueWidth = Math.max(0, width - labelWidth - 1);
3862
+ function DetailLine({ label, value, columns }) {
3863
+ const innerWidth = Math.max(24, Math.floor(columns || 80) - 4);
3864
+ const labelWidth = 10;
3865
+ const valueWidth = Math.max(0, innerWidth - labelWidth - 2);
3866
+ return /* @__PURE__ */ jsxs9(Box11, { flexDirection: "row", width: "100%", children: [
3867
+ /* @__PURE__ */ jsx13(Text13, { color: theme.subtle, children: padCells3(truncateText3(label, labelWidth), labelWidth) }),
3868
+ /* @__PURE__ */ jsx13(Text13, { color: theme.inactive, children: " " }),
3869
+ /* @__PURE__ */ jsx13(Text13, { color: theme.text, children: truncateText3(value, valueWidth) })
3870
+ ] });
3871
+ }
3872
+ function bucketTokens(map, names) {
3873
+ return names.reduce((sum, name) => sum + finiteNumber(map?.[name]?.tokens), 0);
3874
+ }
3875
+ function bucketCount(map, names) {
3876
+ return names.reduce((sum, name) => sum + finiteNumber(map?.[name]?.count), 0);
3877
+ }
3878
+ function semanticTokens(semantic, names) {
3879
+ return names.reduce((sum, name) => sum + finiteNumber(semantic?.[name]?.tokens), 0);
3880
+ }
3881
+ function CategoryItem({ label, tokens, total, width }) {
3882
+ const labelWidth = Math.min(11, Math.max(7, Math.floor(width * 0.22)));
3883
+ const pctWidth = 6;
3884
+ const tokenWidth = 7;
3885
+ const barWidth = Math.max(6, Math.min(20, width - labelWidth - pctWidth - tokenWidth - 4));
3886
+ const pct = percent(tokens, total);
3851
3887
  return /* @__PURE__ */ jsxs9(Box11, { flexDirection: "row", width, children: [
3852
- /* @__PURE__ */ jsxs9(Text13, { color: theme.subtle, children: [
3853
- padCells3(truncateText3(label, labelWidth), labelWidth),
3854
- " "
3855
- ] }),
3856
- /* @__PURE__ */ jsx13(Text13, { color: tone || theme.text, children: truncateText3(value, valueWidth) })
3888
+ /* @__PURE__ */ jsx13(Text13, { color: theme.subtle, children: padCells3(truncateText3(label, labelWidth), labelWidth) }),
3889
+ /* @__PURE__ */ jsx13(Text13, { color: theme.inactive, children: " " }),
3890
+ /* @__PURE__ */ jsx13(Text13, { color: usageColor(pct), children: padCells3(percentLabel(tokens, total), pctWidth) }),
3891
+ /* @__PURE__ */ jsx13(ProgressBar, { value: tokens, total, width: barWidth }),
3892
+ /* @__PURE__ */ jsx13(Text13, { color: theme.inactive, children: " " }),
3893
+ /* @__PURE__ */ jsx13(Text13, { color: theme.text, children: padCells3(formatTokens(tokens), tokenWidth) })
3857
3894
  ] });
3858
3895
  }
3859
- function MetricGrid({ cells, columns }) {
3896
+ function CategoryGrid({ categories, columns, total }) {
3860
3897
  const innerWidth = Math.max(24, Math.floor(columns || 80) - 4);
3861
- const twoColumns = innerWidth >= 76;
3898
+ const twoColumns = innerWidth >= 84;
3862
3899
  if (!twoColumns) {
3863
- return /* @__PURE__ */ jsx13(Box11, { flexDirection: "column", width: "100%", children: cells.map((cell) => /* @__PURE__ */ jsx13(MetricCell, { ...cell, width: innerWidth }, cell.label)) });
3900
+ return /* @__PURE__ */ jsx13(Box11, { flexDirection: "column", width: "100%", children: categories.map((category) => /* @__PURE__ */ jsx13(CategoryItem, { ...category, total, width: innerWidth }, category.label)) });
3864
3901
  }
3865
3902
  const gap = 4;
3866
3903
  const leftWidth = Math.floor((innerWidth - gap) / 2);
3867
3904
  const rightWidth = innerWidth - gap - leftWidth;
3868
3905
  const pairs = [];
3869
- for (let i = 0; i < cells.length; i += 2) pairs.push(cells.slice(i, i + 2));
3906
+ for (let i = 0; i < categories.length; i += 2) pairs.push(categories.slice(i, i + 2));
3870
3907
  return /* @__PURE__ */ jsx13(Box11, { flexDirection: "column", width: "100%", children: pairs.map((pair, index) => /* @__PURE__ */ jsxs9(Box11, { flexDirection: "row", width: "100%", children: [
3871
- /* @__PURE__ */ jsx13(MetricCell, { ...pair[0], width: leftWidth }),
3908
+ /* @__PURE__ */ jsx13(CategoryItem, { ...pair[0], total, width: leftWidth }),
3872
3909
  /* @__PURE__ */ jsx13(Text13, { children: " ".repeat(gap) }),
3873
- pair[1] ? /* @__PURE__ */ jsx13(MetricCell, { ...pair[1], width: rightWidth }) : null
3910
+ pair[1] ? /* @__PURE__ */ jsx13(CategoryItem, { ...pair[1], total, width: rightWidth }) : null
3874
3911
  ] }, index)) });
3875
3912
  }
3876
3913
  function ContextUsageView({ detail, columns }) {
@@ -3884,6 +3921,9 @@ function ContextUsageView({ detail, columns }) {
3884
3921
  const lastApi = detail?.lastApi || {};
3885
3922
  const cache = detail?.cache || {};
3886
3923
  const extensions = detail?.extensions || {};
3924
+ const mcp = detail?.mcp || {};
3925
+ const semantic = messages.semantic || {};
3926
+ const schema = request.toolSchemaBreakdown || {};
3887
3927
  const usedTokens = finiteNumber(usage.usedTokens);
3888
3928
  const windowTokens = finiteNumber(usage.windowTokens);
3889
3929
  const freeTokens = windowTokens ? Math.max(0, windowTokens - usedTokens) : finiteNumber(usage.freeTokens);
@@ -3891,25 +3931,34 @@ function ContextUsageView({ detail, columns }) {
3891
3931
  const summaryText = `${formatTokens(usedTokens)} / ${formatTokens(windowTokens)} \xB7 ${formatTokens(freeTokens)} free`;
3892
3932
  const pctText = `${percentLabel(usedTokens, windowTokens)} used`;
3893
3933
  const barWidth = Math.max(12, Math.min(34, innerWidth - stringWidth7(summaryText) - stringWidth7(pctText) - 5));
3934
+ const builtInToolTokens = bucketTokens(schema, ["code", "web", "mutation", "channels", "setup", "other"]);
3935
+ const builtInToolCount = bucketCount(schema, ["code", "web", "mutation", "channels", "setup", "other"]);
3936
+ const projectTokens = semanticTokens(semantic, ["project", "workspace", "environment", "other"]);
3894
3937
  const compactionLine = metricValue([
3895
- compaction.stage || "pending",
3938
+ compaction.stage && compaction.stage !== "pending" ? compaction.stage : "",
3896
3939
  compaction.state,
3897
- compaction.triggerTokens ? `trigger ${formatTokens(compaction.triggerTokens)}` : "",
3898
- compaction.boundaryTokens ? `boundary ${formatTokens(compaction.boundaryTokens)}` : ""
3940
+ compaction.triggerTokens ? `trigger ${formatTokens(compaction.triggerTokens)}` : ""
3899
3941
  ]);
3900
- const metaLine = metricValue([
3901
- usage.source || "estimated",
3902
- usage.effective ? "effective window" : "",
3942
+ const sourceLine = metricValue([
3943
+ usage.effective ? `effective ${formatTokens(windowTokens)}` : `window ${formatTokens(windowTokens)}`,
3903
3944
  usage.rawWindowTokens && usage.rawWindowTokens !== usage.windowTokens ? `raw ${formatTokens(usage.rawWindowTokens)}` : ""
3904
3945
  ]);
3905
- const cells = [
3906
- { label: "Messages", value: metricValue([`${formatTokens(messages.tokens)} tokens`, `${messages.count || 0} msgs`]) },
3907
- { label: "Tools", value: metricValue([`${formatTokens(tools.schemaTokens)} schema`, `${tools.active || 0}/${tools.count || 0} active`]) },
3908
- { label: "Tool I/O", value: metricValue([`${toolIo.calls || 0} calls`, `${toolIo.results || 0} results`]) },
3909
- { label: "Overhead", value: metricValue([`${formatTokens(request.overheadTokens)} frame`, `${formatTokens(request.reserveTokens)} reserve`]) },
3910
- { label: "Last API", value: metricValue([`${formatTokens(lastApi.contextTokens)} ctx`, `${formatTokens(lastApi.inputTokens)} in`, `${formatTokens(lastApi.outputTokens)} out`]) },
3911
- { label: "Cache", value: metricValue([`${cache.hitRate || "n/a"} hit`, `${formatTokens(cache.readTokens)} read`]) },
3912
- { label: "Extensions", value: metricValue([`${extensions.skills || 0} skills`, `${extensions.plugins || 0} plugins`]) }
3946
+ const apiLine = metricValue([
3947
+ `last ctx ${formatTokens(lastApi.contextTokens)}`,
3948
+ `in/out ${formatTokens(lastApi.inputTokens)}/${formatTokens(lastApi.outputTokens)}`,
3949
+ `cache ${cache.hitRate || "n/a"}`
3950
+ ]);
3951
+ const categories = [
3952
+ { label: "Messages", tokens: semanticTokens(semantic, ["chat", "assistant"]), meta: "" },
3953
+ { label: "Tools", tokens: builtInToolTokens, meta: `${tools.active || 0}/${tools.count || 0} active${builtInToolCount ? ` \xB7 ${builtInToolCount} defs` : ""}` },
3954
+ { label: "MCP", tokens: bucketTokens(schema, ["mcp"]), meta: `${mcp.connected || 0}/${mcp.configured || 0} servers` },
3955
+ { label: "Skills", tokens: bucketTokens(schema, ["skills"]), meta: `${extensions.skills || 0} skills` },
3956
+ { label: "Memory", tokens: semanticTokens(semantic, ["memory"]) + bucketTokens(schema, ["memory"]), meta: "core + recall tools" },
3957
+ { label: "Project", tokens: projectTokens, meta: "mixdog.md \xB7 workspace" },
3958
+ { label: "Workflow", tokens: semanticTokens(semantic, ["workflow"]) + bucketTokens(schema, ["agents"]), meta: "workflow \xB7 agents" },
3959
+ { label: "System", tokens: semanticTokens(semantic, ["system"]), meta: "rules \xB7 role catalog" },
3960
+ { label: "Overhead", tokens: finiteNumber(request.overheadTokens), meta: "request frame" },
3961
+ { label: "Tool I/O", tokens: semanticTokens(semantic, ["toolResults"]), meta: `${toolIo.calls || 0} calls \xB7 ${toolIo.results || 0} results` }
3913
3962
  ];
3914
3963
  return /* @__PURE__ */ jsxs9(Box11, { flexDirection: "column", width: "100%", children: [
3915
3964
  /* @__PURE__ */ jsxs9(Box11, { flexDirection: "row", width: "100%", children: [
@@ -3920,10 +3969,14 @@ function ContextUsageView({ detail, columns }) {
3920
3969
  /* @__PURE__ */ jsx13(Text13, { color: theme.text, children: truncateText3(summaryText, Math.max(0, innerWidth - Math.min(10, innerWidth) - barWidth - 3)) })
3921
3970
  ] }),
3922
3971
  /* @__PURE__ */ jsxs9(Box11, { marginTop: 1, flexDirection: "column", width: "100%", children: [
3923
- /* @__PURE__ */ jsx13(Text13, { color: theme.subtle, children: truncateText3(metaLine, innerWidth) }),
3924
- /* @__PURE__ */ jsx13(Text13, { color: theme.text, children: truncateText3(`Compaction ${compactionLine}`, innerWidth) })
3972
+ /* @__PURE__ */ jsx13(DetailLine, { label: "Source", value: sourceLine, columns }),
3973
+ /* @__PURE__ */ jsx13(DetailLine, { label: "Compaction", value: compactionLine, columns }),
3974
+ /* @__PURE__ */ jsx13(DetailLine, { label: "API/cache", value: apiLine, columns })
3925
3975
  ] }),
3926
- /* @__PURE__ */ jsx13(Box11, { marginTop: 1, flexDirection: "column", width: "100%", children: /* @__PURE__ */ jsx13(MetricGrid, { cells, columns }) })
3976
+ /* @__PURE__ */ jsxs9(Box11, { marginTop: 1, flexDirection: "column", width: "100%", children: [
3977
+ /* @__PURE__ */ jsx13(Text13, { color: theme.subtle, children: "Context mix" }),
3978
+ /* @__PURE__ */ jsx13(Box11, { marginTop: 1, flexDirection: "column", width: "100%", children: /* @__PURE__ */ jsx13(CategoryGrid, { categories, columns, total: windowTokens }) })
3979
+ ] })
3927
3980
  ] });
3928
3981
  }
3929
3982
  function ContextPanel({ rows, title = "Context Usage", columns = 80, fillHeight = false, detail = null }) {
@@ -6896,6 +6949,7 @@ ${model?.id || ""}`;
6896
6949
  };
6897
6950
  const openContextPicker = () => {
6898
6951
  const tools = store.toolsStatus?.() || { activeCount: 0, count: 0, activeTools: [] };
6952
+ const mcp = store.mcpStatus?.() || { connectedCount: 0, configuredCount: 0, failedCount: 0 };
6899
6953
  const skills = store.skillsStatus?.() || { count: 0 };
6900
6954
  const plugins = store.pluginsStatus?.() || { count: 0 };
6901
6955
  const context = store.contextStatus?.() || {};
@@ -7020,7 +7074,8 @@ ${model?.id || ""}`;
7020
7074
  },
7021
7075
  messages: {
7022
7076
  tokens: messages.estimatedTokens,
7023
- count: messages.count
7077
+ count: messages.count,
7078
+ semantic: messages.semantic
7024
7079
  },
7025
7080
  tools: {
7026
7081
  schemaTokens: request.toolSchemaTokens,
@@ -7032,6 +7087,7 @@ ${model?.id || ""}`;
7032
7087
  results: messages.toolResultCount
7033
7088
  },
7034
7089
  request: {
7090
+ toolSchemaBreakdown: request.toolSchemaBreakdown,
7035
7091
  overheadTokens: request.requestOverheadTokens,
7036
7092
  reserveTokens: request.reserveTokens
7037
7093
  },
@@ -7047,6 +7103,11 @@ ${model?.id || ""}`;
7047
7103
  extensions: {
7048
7104
  skills: skills.count,
7049
7105
  plugins: plugins.count
7106
+ },
7107
+ mcp: {
7108
+ connected: mcp.connectedCount,
7109
+ configured: mcp.configuredCount,
7110
+ failed: mcp.failedCount
7050
7111
  }
7051
7112
  },
7052
7113
  rows: contextRows
@@ -8912,7 +8973,7 @@ ${p.description}` : ""
8912
8973
  return;
8913
8974
  }
8914
8975
  if (r.changed === false) {
8915
- store.pushNotice("No changes.", "warn");
8976
+ store.pushNotice("nothing to compact", "warn");
8916
8977
  return;
8917
8978
  }
8918
8979
  store.pushNotice("Compact done.", "info");
@@ -9309,7 +9370,7 @@ ${p.description}` : ""
9309
9370
  const queuedRows = queuedVisible ? state.queued.length + 1 : 0;
9310
9371
  const baseReserve = WELCOME_ROWS + SCROLL_HINT_ROWS + LIVE_STATUS_ROWS + INPUT_BOX_ROWS + STATUSLINE_ROWS + queuedRows;
9311
9372
  const maxFloatingPanelRows = Math.max(0, resizeState.rows - baseReserve - 1);
9312
- const desiredFloatingPanelRows = picker ? picker.fillAvailable ? maxFloatingPanelRows : PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS : contextPanel ? PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS : usagePanel ? PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS : slashPaletteOpen ? PANEL_MAX_VISIBLE + 4 : hasTextEntryPrompt ? TEXT_ENTRY_ROWS + OPTION_PANEL_EXTRA_ROWS : 0;
9373
+ const desiredFloatingPanelRows = picker ? picker.fillAvailable ? maxFloatingPanelRows : PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS : contextPanel ? PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS + 3 : usagePanel ? PANEL_BASE_ROWS + OPTION_PANEL_EXTRA_ROWS : slashPaletteOpen ? PANEL_MAX_VISIBLE + 4 : hasTextEntryPrompt ? TEXT_ENTRY_ROWS + OPTION_PANEL_EXTRA_ROWS : 0;
9313
9374
  const floatingPanelRows = desiredFloatingPanelRows > 0 ? Math.min(desiredFloatingPanelRows, maxFloatingPanelRows) : 0;
9314
9375
  const pickerVisibleRows = picker ? Math.max(1, floatingPanelRows - PICKER_CHROME_ROWS - (picker.fillAvailable ? 0 : OPTION_PANEL_EXTRA_ROWS)) : PANEL_MAX_VISIBLE;
9315
9376
  const bottomReserve = baseReserve + floatingPanelRows;
@@ -3,7 +3,7 @@
3
3
  *
4
4
  * Replaces the raw `[tool: name]` line with a styled card that shows the tool
5
5
  * name plus a short, human-readable summary of its most relevant argument
6
- * (path for read/write/edit, command for shell, pattern for grep, etc.).
6
+ * (path for read/apply_patch, command for shell, pattern for grep, etc.).
7
7
  *
8
8
  * Pure formatting: returns a string, never touches stdout. Robust to missing or
9
9
  * malformed argument objects (the engine hands us `{ name, arguments, id }`).
@@ -15,9 +15,7 @@ const MAX_SUMMARY = 72;
15
15
  /** Map of tool name -> function deriving its one-line summary from args. */
16
16
  const SUMMARIZERS = {
17
17
  read: (a) => a.path ?? a.file,
18
- write: (a) => a.path,
19
18
  apply_patch: (a) => a.path ?? a.base_path ?? firstPatchPath(a.patch),
20
- edit: (a) => a.path ?? (Array.isArray(a.edits) ? a.edits[0]?.path : undefined),
21
19
  list: (a) => a.path ?? a.pattern,
22
20
  glob: (a) => joinMaybe(a.pattern) ?? a.path,
23
21
  grep: (a) => joinMaybe(a.pattern),