cascade-ai 0.12.19 → 0.12.21

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/dist/cli.js CHANGED
@@ -58,7 +58,7 @@ var __export = (target, all) => {
58
58
  var CASCADE_VERSION, CASCADE_CONFIG_FILE, CASCADE_DB_FILE, CASCADE_DASHBOARD_SECRET_FILE, GLOBAL_CONFIG_DIR, GLOBAL_DB_FILE, GLOBAL_KEYSTORE_FILE, GLOBAL_RUNTIME_DB_FILE, DEFAULT_DASHBOARD_PORT, DEFAULT_CONTEXT_LIMIT, DEFAULT_AUTO_SUMMARIZE_AT, MODELS, T1_MODEL_PRIORITY, T2_MODEL_PRIORITY, T3_MODEL_PRIORITY, VISION_MODEL_PRIORITY, COMPLEXITY_T2_COUNT, THEME_NAMES, DEFAULT_THEME, OLLAMA_BASE_URL, LM_STUDIO_BASE_URL, AZURE_BASE_URL_TEMPLATE, TOOL_NAMES, DEFAULT_APPROVAL_REQUIRED;
59
59
  var init_constants = __esm({
60
60
  "src/constants.ts"() {
61
- CASCADE_VERSION = "0.12.19";
61
+ CASCADE_VERSION = "0.12.21";
62
62
  CASCADE_CONFIG_FILE = ".cascade/config.json";
63
63
  CASCADE_DB_FILE = ".cascade/memory.db";
64
64
  CASCADE_DASHBOARD_SECRET_FILE = ".cascade/dashboard-secret";
@@ -1165,8 +1165,7 @@ var init_gemini = __esm({
1165
1165
  }
1166
1166
  });
1167
1167
  function preferIpv4Host(url) {
1168
- if (!url) return url;
1169
- return url.replace(/^(https?:\/\/)localhost(?=[:/]|$)/i, "$1127.0.0.1");
1168
+ return url;
1170
1169
  }
1171
1170
  async function nodeHttpFetch(input, init = {}, redirectCount = 0) {
1172
1171
  const urlStr = typeof input === "string" ? input : input instanceof URL ? input.href : input.url;
@@ -1471,7 +1470,7 @@ var init_openai_compatible = __esm({
1471
1470
  init_net();
1472
1471
  OpenAICompatibleProvider = class extends OpenAIProvider {
1473
1472
  constructor(config, model) {
1474
- super(config, model);
1473
+ super({ ...config, apiKey: config.apiKey ?? "not-required" }, model);
1475
1474
  this.client = new OpenAI({
1476
1475
  apiKey: config.apiKey ?? "not-required",
1477
1476
  baseURL: preferIpv4Host(config.baseUrl),
@@ -4115,10 +4114,10 @@ var CascadeRouter = class _CascadeRouter extends EventEmitter {
4115
4114
  if (availableProviders.has("ollama")) {
4116
4115
  await this.discoverOllamaModels(ollamaCfg);
4117
4116
  }
4118
- if (availableProviders.has("openai-compatible")) {
4119
- await Promise.all(
4120
- config.providers.filter((p) => p.type === "openai-compatible").map((cfg) => this.discoverOpenAICompatibleModels(cfg))
4121
- );
4117
+ const ocConfigs = config.providers.filter((p) => p.type === "openai-compatible" && p.baseUrl);
4118
+ if (ocConfigs.length > 0) {
4119
+ const results = await Promise.all(ocConfigs.map((cfg) => this.discoverOpenAICompatibleModels(cfg)));
4120
+ if (results.some(Boolean)) this.selector.markProviderAvailable("openai-compatible");
4122
4121
  }
4123
4122
  for (const tier of ["T1", "T2", "T3"]) {
4124
4123
  const override = tier === "T1" ? config.models.t1 : tier === "T2" ? config.models.t2 : config.models.t3;
@@ -4589,6 +4588,7 @@ var CascadeRouter = class _CascadeRouter extends EventEmitter {
4589
4588
  } catch {
4590
4589
  }
4591
4590
  }
4591
+ /** Returns true when at least one real model was discovered from the endpoint. */
4592
4592
  async discoverOpenAICompatibleModels(cfg) {
4593
4593
  try {
4594
4594
  const seed = {
@@ -4608,8 +4608,10 @@ var CascadeRouter = class _CascadeRouter extends EventEmitter {
4608
4608
  for (const m of models) {
4609
4609
  this.selector.addDynamicModel(m);
4610
4610
  }
4611
+ return models.length > 0;
4611
4612
  } catch (err) {
4612
4613
  console.warn("[router] OpenAI-compatible model discovery failed:", err instanceof Error ? err.message : err);
4614
+ return false;
4613
4615
  }
4614
4616
  }
4615
4617
  ensureProvider(model, configs) {
@@ -10967,135 +10969,126 @@ init_ollama();
10967
10969
  init_openai_compatible();
10968
10970
 
10969
10971
  // src/cli/themes/index.ts
10970
- var cascadeTheme = {
10971
- name: "cascade",
10972
- colors: {
10973
- primary: "#7C6AF7",
10974
- // Cascade violet
10975
- secondary: "#A78BFA",
10976
- accent: "#06B6D4",
10977
- // Cyan
10978
- success: "#10B981",
10979
- warning: "#F59E0B",
10980
- error: "#EF4444",
10981
- info: "#3B82F6",
10982
- muted: "#6B7280",
10983
- background: "#0F0F1A",
10984
- foreground: "#E2E8F0",
10985
- border: "#2D2B55",
10986
- t1Color: "#7C6AF7",
10987
- // Violet
10988
- t2Color: "#06B6D4",
10989
- // Cyan
10990
- t3Color: "#10B981"
10991
- // Green
10992
- }
10993
- };
10994
- var darkTheme = {
10995
- name: "dark",
10996
- colors: {
10997
- primary: "#60A5FA",
10998
- secondary: "#818CF8",
10999
- accent: "#34D399",
11000
- success: "#34D399",
11001
- warning: "#FBBF24",
11002
- error: "#F87171",
11003
- info: "#60A5FA",
11004
- muted: "#6B7280",
11005
- background: "#111827",
11006
- foreground: "#F9FAFB",
11007
- border: "#374151",
11008
- t1Color: "#60A5FA",
11009
- t2Color: "#818CF8",
11010
- t3Color: "#34D399"
11011
- }
11012
- };
11013
- var lightTheme = {
11014
- name: "light",
11015
- colors: {
11016
- primary: "#2563EB",
11017
- secondary: "#7C3AED",
11018
- accent: "#0891B2",
11019
- success: "#059669",
11020
- warning: "#D97706",
11021
- error: "#DC2626",
11022
- info: "#2563EB",
11023
- muted: "#6B7280",
11024
- background: "#FFFFFF",
11025
- foreground: "#111827",
11026
- border: "#E5E7EB",
11027
- t1Color: "#2563EB",
11028
- t2Color: "#7C3AED",
11029
- t3Color: "#059669"
11030
- }
11031
- };
11032
- var draculaTheme = {
11033
- name: "dracula",
11034
- colors: {
11035
- primary: "#BD93F9",
11036
- secondary: "#FF79C6",
11037
- accent: "#8BE9FD",
11038
- success: "#50FA7B",
11039
- warning: "#FFB86C",
11040
- error: "#FF5555",
11041
- info: "#8BE9FD",
11042
- muted: "#6272A4",
11043
- background: "#282A36",
11044
- foreground: "#F8F8F2",
11045
- border: "#44475A",
11046
- t1Color: "#BD93F9",
11047
- t2Color: "#FF79C6",
11048
- t3Color: "#50FA7B"
11049
- }
11050
- };
11051
- var nordTheme = {
11052
- name: "nord",
11053
- colors: {
11054
- primary: "#88C0D0",
11055
- secondary: "#81A1C1",
11056
- accent: "#A3BE8C",
11057
- success: "#A3BE8C",
11058
- warning: "#EBCB8B",
11059
- error: "#BF616A",
11060
- info: "#5E81AC",
11061
- muted: "#4C566A",
11062
- background: "#2E3440",
11063
- foreground: "#ECEFF4",
11064
- border: "#3B4252",
11065
- t1Color: "#88C0D0",
11066
- t2Color: "#81A1C1",
11067
- t3Color: "#A3BE8C"
11068
- }
10972
+ function defineTheme(name, colors) {
10973
+ return { name, colors };
10974
+ }
10975
+ var midnightTheme = defineTheme("midnight", {
10976
+ primary: "#8B7CF9",
10977
+ secondary: "#B7AEFF",
10978
+ accent: "#42D3E7",
10979
+ success: "#3DDC97",
10980
+ warning: "#F7B84B",
10981
+ error: "#FF6685",
10982
+ info: "#67A8FF",
10983
+ muted: "#7C819B",
10984
+ background: "#080A12",
10985
+ foreground: "#EDF0FA",
10986
+ border: "#292D42",
10987
+ t1Color: "#F7B84B",
10988
+ t2Color: "#A98BFF",
10989
+ t3Color: "#42D3E7"
10990
+ });
10991
+ var auroraTheme = defineTheme("aurora", {
10992
+ primary: "#6F8CFF",
10993
+ secondary: "#A78BFA",
10994
+ accent: "#45E0B8",
10995
+ success: "#45E0B8",
10996
+ warning: "#FFD166",
10997
+ error: "#FF6B8A",
10998
+ info: "#6FB7FF",
10999
+ muted: "#7890A8",
11000
+ background: "#071019",
11001
+ foreground: "#EAF7F5",
11002
+ border: "#20384A",
11003
+ t1Color: "#FFD166",
11004
+ t2Color: "#8B9CFF",
11005
+ t3Color: "#45E0B8"
11006
+ });
11007
+ var emberTheme = defineTheme("ember", {
11008
+ primary: "#FF8A5B",
11009
+ secondary: "#FFB36B",
11010
+ accent: "#F7C75B",
11011
+ success: "#72D69A",
11012
+ warning: "#F7C75B",
11013
+ error: "#FF647C",
11014
+ info: "#73B7FF",
11015
+ muted: "#9A8078",
11016
+ background: "#120C0B",
11017
+ foreground: "#FFF1E9",
11018
+ border: "#463027",
11019
+ t1Color: "#F7C75B",
11020
+ t2Color: "#FF8A5B",
11021
+ t3Color: "#72D69A"
11022
+ });
11023
+ var tideTheme = defineTheme("tide", {
11024
+ primary: "#4DA8FF",
11025
+ secondary: "#65C7F7",
11026
+ accent: "#51E1D4",
11027
+ success: "#63D9A5",
11028
+ warning: "#F2C879",
11029
+ error: "#F0718B",
11030
+ info: "#4DA8FF",
11031
+ muted: "#71899C",
11032
+ background: "#061017",
11033
+ foreground: "#E8F5FA",
11034
+ border: "#1C3947",
11035
+ t1Color: "#F2C879",
11036
+ t2Color: "#65A8F7",
11037
+ t3Color: "#51E1D4"
11038
+ });
11039
+ var bloomTheme = defineTheme("bloom", {
11040
+ primary: "#C084FC",
11041
+ secondary: "#F08BB4",
11042
+ accent: "#7DD3FC",
11043
+ success: "#6EE7B7",
11044
+ warning: "#FBCB78",
11045
+ error: "#FB7185",
11046
+ info: "#7DD3FC",
11047
+ muted: "#9B83A8",
11048
+ background: "#140D19",
11049
+ foreground: "#F8EEFC",
11050
+ border: "#412B4D",
11051
+ t1Color: "#FBCB78",
11052
+ t2Color: "#C084FC",
11053
+ t3Color: "#7DD3FC"
11054
+ });
11055
+ var daybreakTheme = defineTheme("daybreak", {
11056
+ primary: "#6857D9",
11057
+ secondary: "#826AE6",
11058
+ accent: "#087F91",
11059
+ success: "#087A55",
11060
+ warning: "#A86408",
11061
+ error: "#C83253",
11062
+ info: "#2563A8",
11063
+ muted: "#667085",
11064
+ background: "#F7F7FB",
11065
+ foreground: "#202336",
11066
+ border: "#D9DCE8",
11067
+ t1Color: "#A86408",
11068
+ t2Color: "#6857D9",
11069
+ t3Color: "#087F91"
11070
+ });
11071
+ var canonicalThemes = {
11072
+ midnight: midnightTheme,
11073
+ aurora: auroraTheme,
11074
+ ember: emberTheme,
11075
+ tide: tideTheme,
11076
+ bloom: bloomTheme,
11077
+ daybreak: daybreakTheme
11069
11078
  };
11070
- var solarizedTheme = {
11071
- name: "solarized",
11072
- colors: {
11073
- primary: "#268BD2",
11074
- secondary: "#2AA198",
11075
- accent: "#B58900",
11076
- success: "#859900",
11077
- warning: "#CB4B16",
11078
- error: "#DC322F",
11079
- info: "#268BD2",
11080
- muted: "#657B83",
11081
- background: "#002B36",
11082
- foreground: "#839496",
11083
- border: "#073642",
11084
- t1Color: "#268BD2",
11085
- t2Color: "#2AA198",
11086
- t3Color: "#859900"
11087
- }
11079
+ var THEME_ALIASES = {
11080
+ cascade: "midnight",
11081
+ dark: "aurora",
11082
+ light: "daybreak",
11083
+ dracula: "bloom",
11084
+ nord: "tide",
11085
+ solarized: "ember"
11088
11086
  };
11089
- var themes = /* @__PURE__ */ new Map([
11090
- ["cascade", cascadeTheme],
11091
- ["dark", darkTheme],
11092
- ["light", lightTheme],
11093
- ["dracula", draculaTheme],
11094
- ["nord", nordTheme],
11095
- ["solarized", solarizedTheme]
11096
- ]);
11087
+ function resolveThemeName(name) {
11088
+ return (name in canonicalThemes ? name : THEME_ALIASES[name]) || "midnight";
11089
+ }
11097
11090
  function getTheme(name) {
11098
- return themes.get(name) ?? cascadeTheme;
11091
+ return canonicalThemes[resolveThemeName(name)] ?? midnightTheme;
11099
11092
  }
11100
11093
 
11101
11094
  // src/cli/slash/index.ts
@@ -11349,6 +11342,13 @@ var FIXED_CHROME_ROWS = 1 + // StatusBar
11349
11342
  3;
11350
11343
  var STREAM_TAIL_ROWS = 9;
11351
11344
  var SLASH_PANEL_ROWS = 11;
11345
+ function computeAdaptiveLayoutMode(columns, rows) {
11346
+ const safeColumns = Number.isFinite(columns) && columns > 0 ? columns : 100;
11347
+ const safeRows = Number.isFinite(rows) && rows > 0 ? rows : 40;
11348
+ if (safeColumns < 80 || safeRows < 24) return "narrow";
11349
+ if (safeColumns < 120 || safeRows < 32) return "medium";
11350
+ return "wide";
11351
+ }
11352
11352
  var TREE_ROWS_FULL = 10;
11353
11353
  var TREE_ROWS_COMPACT = 4;
11354
11354
  var TIMELINE_ROWS = 4;
@@ -11608,7 +11608,7 @@ function formatTokens(n) {
11608
11608
  var StatusBar = React2.memo(StatusBarInternal);
11609
11609
  function HintBarInternal({ theme, isExecuting }) {
11610
11610
  if (isExecuting) return null;
11611
- return /* @__PURE__ */ jsx(Box, { paddingLeft: 1, children: /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, dimColor: true, children: "/help \xB7 /clear \xB7 /theme \xB7 /cost \xB7 /model \xB7 /export" }) });
11611
+ return /* @__PURE__ */ jsx(Box, { paddingLeft: 1, children: /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, dimColor: true, children: "/ commands \xB7 \u2191\u2193 history \xB7 Esc cancel \xB7 Ctrl+C exit" }) });
11612
11612
  }
11613
11613
  var HintBar = React2.memo(HintBarInternal);
11614
11614
  function ApprovalPrompt({ request, theme, onDecision }) {
@@ -11932,6 +11932,53 @@ function CostTracker({
11932
11932
  ] })
11933
11933
  ] });
11934
11934
  }
11935
+ function CompactStatus({ theme, activeT2Count, activeT3Count, currentAction, activeTool, isStreaming }) {
11936
+ const activeCount = activeT2Count + activeT3Count;
11937
+ const isActive = isStreaming || activeCount > 0;
11938
+ const rightHint = isActive ? /* @__PURE__ */ jsxs(Text, { color: theme.colors.muted, children: [
11939
+ "T2:",
11940
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, children: activeT2Count }),
11941
+ " T3:",
11942
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, children: activeT3Count })
11943
+ ] }) : /* @__PURE__ */ jsxs(Text, { color: theme.colors.muted, children: [
11944
+ "[",
11945
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, bold: true, children: "tree" }),
11946
+ "]"
11947
+ ] });
11948
+ return /* @__PURE__ */ jsxs(Box, { paddingX: 1, borderStyle: "single", borderTop: false, borderLeft: false, borderRight: false, borderColor: theme.colors.border, children: [
11949
+ /* @__PURE__ */ jsx(Box, { flexGrow: 1, children: isActive ? /* @__PURE__ */ jsxs(Fragment, { children: [
11950
+ /* @__PURE__ */ jsxs(Text, { color: theme.colors.accent, bold: true, children: [
11951
+ /* @__PURE__ */ jsx(Spinner, { type: "hamburger" }),
11952
+ " "
11953
+ ] }),
11954
+ activeTool ? (
11955
+ // Show active tool prominently
11956
+ /* @__PURE__ */ jsxs(Fragment, { children: [
11957
+ /* @__PURE__ */ jsxs(Text, { color: "yellow", bold: true, children: [
11958
+ "\u2699 ",
11959
+ activeTool
11960
+ ] }),
11961
+ currentAction && !currentAction.startsWith("Using tool:") && /* @__PURE__ */ jsxs(Text, { color: theme.colors.muted, children: [
11962
+ " \u2503 ",
11963
+ currentAction.length > 60 ? currentAction.slice(0, 57) + "..." : currentAction
11964
+ ] })
11965
+ ] })
11966
+ ) : /* @__PURE__ */ jsxs(Fragment, { children: [
11967
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, bold: true, children: activeCount > 0 ? `WORKING: ${activeCount} AGENTS` : "ORCHESTRATING" }),
11968
+ currentAction && /* @__PURE__ */ jsxs(Text, { color: theme.colors.muted, children: [
11969
+ " \u2503 ",
11970
+ currentAction.length > 80 ? currentAction.slice(0, 77) + "..." : currentAction
11971
+ ] })
11972
+ ] })
11973
+ ] }) : /* @__PURE__ */ jsxs(Box, { children: [
11974
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.muted, children: "\u25CF SYSTEM IDLE " }),
11975
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.muted, children: "\u2503 Press " }),
11976
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.accent, bold: true, children: "/" }),
11977
+ /* @__PURE__ */ jsx(Text, { color: theme.colors.muted, children: " for command palette" })
11978
+ ] }) }),
11979
+ /* @__PURE__ */ jsx(Box, { children: rightHint })
11980
+ ] });
11981
+ }
11935
11982
  function ChatMessage({ role, content, theme, timestamp, isStreaming }) {
11936
11983
  const { label, color, prefix } = getRoleStyle(role, theme);
11937
11984
  return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginY: 1, children: [
@@ -12236,6 +12283,19 @@ function tailLines(text, n) {
12236
12283
  const lines = text.split("\n");
12237
12284
  return lines.slice(-8);
12238
12285
  }
12286
+ function activeTierSummary(root) {
12287
+ const summary = { t2: 0, t3: 0 };
12288
+ const visit = (node) => {
12289
+ if (node.status === "ACTIVE") {
12290
+ if (node.role === "T2") summary.t2 += 1;
12291
+ if (node.role === "T3") summary.t3 += 1;
12292
+ summary.action ??= node.currentAction;
12293
+ }
12294
+ node.children?.forEach(visit);
12295
+ };
12296
+ if (root) visit(root);
12297
+ return summary;
12298
+ }
12239
12299
  function WelcomeBanner({ theme, config, workspacePath, sessionId }) {
12240
12300
  const t1 = config.models?.t1 ?? "auto";
12241
12301
  const t2 = config.models?.t2 ?? "auto";
@@ -13133,13 +13193,15 @@ ${lastUser.content}`;
13133
13193
  };
13134
13194
  }, [stdout]);
13135
13195
  const width = termSize.columns;
13196
+ const adaptiveMode = computeAdaptiveLayoutMode(termSize.columns, termSize.rows);
13136
13197
  const budgetOpts = {
13137
13198
  isTypingCommand,
13138
- showCost: state.showCost,
13139
- showDetails: state.showDetails,
13140
- showComms: state.showComms && state.peerEvents.length > 0
13199
+ showCost: state.showCost && adaptiveMode !== "narrow",
13200
+ showDetails: state.showDetails && adaptiveMode === "wide",
13201
+ showComms: state.showComms && state.peerEvents.length > 0 && adaptiveMode === "wide"
13141
13202
  };
13142
13203
  const liveBudget = computeLiveAreaBudget(termSize.rows, budgetOpts);
13204
+ const tierSummary = activeTierSummary(state.agentTree);
13143
13205
  const transcriptRows = altScreen ? computeTranscriptRows(termSize.rows, liveBudget, { ...budgetOpts, treeVisible: state.agentTree != null }) : 0;
13144
13206
  const transcriptLines = altScreen ? flattenTranscript(state.messages) : [];
13145
13207
  const transcript = altScreen ? windowTranscript(transcriptLines, historyOffset, transcriptRows) : null;
@@ -13229,10 +13291,28 @@ ${lastUser.content}`;
13229
13291
  onClose: () => setIsShowingModels(false)
13230
13292
  }
13231
13293
  ) }),
13232
- /* @__PURE__ */ jsx(AgentTree, { root: state.agentTree, theme, scrollOffset: treeScrollOffset, maxRows: liveBudget.treeMaxRows }),
13233
- state.showComms && liveBudget.commsMaxEvents > 0 && /* @__PURE__ */ jsx(PeerFeed, { events: state.peerEvents, theme, maxRows: liveBudget.commsMaxEvents }),
13234
- state.showDetails && liveBudget.showTimeline && /* @__PURE__ */ jsx(TimelinePanel, { nodes: [...treeNodesRef.current.values()], theme, currentIndex: timelineIndex, onChangeIndex: setTimelineIndex }),
13235
- state.showCost && /* @__PURE__ */ jsx(CostTracker, { theme, totalTokens: state.totalTokens, totalCostUsd: state.totalCostUsd, callsByProvider: state.callsByProvider, callsByTier: state.callsByTier, costByTier: state.costByTier, tokensByTier: state.tokensByTier, compact: liveBudget.costCompact, savedUsd: state.savedUsd, savedPct: state.savedPct }),
13294
+ adaptiveMode === "narrow" && state.agentTree ? /* @__PURE__ */ jsx(
13295
+ CompactStatus,
13296
+ {
13297
+ theme,
13298
+ activeT2Count: tierSummary.t2,
13299
+ activeT3Count: tierSummary.t3,
13300
+ currentAction: tierSummary.action ?? state.agentTree.currentAction,
13301
+ activeTool: state.activeTool,
13302
+ isStreaming: state.isStreaming
13303
+ }
13304
+ ) : /* @__PURE__ */ jsx(
13305
+ AgentTree,
13306
+ {
13307
+ root: state.agentTree,
13308
+ theme,
13309
+ scrollOffset: treeScrollOffset,
13310
+ maxRows: adaptiveMode === "medium" ? Math.min(4, liveBudget.treeMaxRows) : liveBudget.treeMaxRows
13311
+ }
13312
+ ),
13313
+ adaptiveMode === "wide" && state.showComms && liveBudget.commsMaxEvents > 0 && /* @__PURE__ */ jsx(PeerFeed, { events: state.peerEvents, theme, maxRows: liveBudget.commsMaxEvents }),
13314
+ adaptiveMode === "wide" && state.showDetails && liveBudget.showTimeline && /* @__PURE__ */ jsx(TimelinePanel, { nodes: [...treeNodesRef.current.values()], theme, currentIndex: timelineIndex, onChangeIndex: setTimelineIndex }),
13315
+ adaptiveMode !== "narrow" && state.showCost && /* @__PURE__ */ jsx(CostTracker, { theme, totalTokens: state.totalTokens, totalCostUsd: state.totalCostUsd, callsByProvider: state.callsByProvider, callsByTier: state.callsByTier, costByTier: state.costByTier, tokensByTier: state.tokensByTier, compact: liveBudget.costCompact, savedUsd: state.savedUsd, savedPct: state.savedPct }),
13236
13316
  liveBudget.collapsed && (state.showCost || state.showDetails || state.agentTree != null) && /* @__PURE__ */ jsx(Text, { color: theme.colors.muted, dimColor: true, children: " \u25B8 panels collapsed (small terminal)" }),
13237
13317
  state.approvalRequest && /* @__PURE__ */ jsx(ApprovalPrompt, { request: state.approvalRequest, theme, onDecision: (decision) => {
13238
13318
  dispatch({ type: "SET_APPROVAL", request: null });