fluxflow-cli 3.2.0 → 3.2.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.
Files changed (2) hide show
  1. package/dist/fluxflow.js +441 -320
  2. package/package.json +1 -1
package/dist/fluxflow.js CHANGED
@@ -325,7 +325,8 @@ var init_settings = __esm({
325
325
  autoDeleteHistory: "7d",
326
326
  useExternalData: false,
327
327
  externalDataPath: "",
328
- preserveThinking: true
328
+ preserveThinking: true,
329
+ loadingPhrases: true
329
330
  },
330
331
  profileData: {
331
332
  name: null,
@@ -3714,7 +3715,7 @@ var init_TerminalBox = __esm({
3714
3715
  setIsExpanded((prev) => !prev);
3715
3716
  }
3716
3717
  }, { isActive: isFocused });
3717
- const limit = Math.max(5, completed ? terminalHeight - 10 : terminalHeight - 20);
3718
+ const limit = Math.max(5, completed ? terminalHeight - 10 : terminalHeight - 25);
3718
3719
  const hasCollapsibleContent = rawLines.length > limit;
3719
3720
  const collapsedCount = rawLines.length - limit;
3720
3721
  const visibleLines = hasCollapsibleContent && !isExpanded ? rawLines.slice(rawLines.length - limit) : rawLines;
@@ -3725,19 +3726,18 @@ var init_TerminalBox = __esm({
3725
3726
  {
3726
3727
  flexDirection: "column",
3727
3728
  borderStyle: isFocused ? "double" : "single",
3728
- borderLeft: true,
3729
+ borderLeft: false,
3729
3730
  borderRight: false,
3730
- borderTop: false,
3731
- borderBottom: false,
3732
- borderColor: "#555555",
3731
+ borderTop: true,
3732
+ borderBottom: true,
3733
3733
  paddingLeft: 2,
3734
3734
  paddingRight: 0,
3735
3735
  paddingY: 1,
3736
- marginTop: 1,
3737
- width: "100%"
3736
+ marginY: 1,
3737
+ width: columns - 2
3738
3738
  },
3739
- /* @__PURE__ */ React3.createElement(Box2, { marginBottom: 1, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React3.createElement(Box2, { flexShrink: 1, paddingRight: 2 }, /* @__PURE__ */ React3.createElement(Text3, null, /* @__PURE__ */ React3.createElement(Text3, { color: "gray", bold: true }, completed ? "\u{1F3C1} FINISHED:" : "\u26A1 EXECUTING:", " "), /* @__PURE__ */ React3.createElement(Text3, { color: "white" }, command))), isPty && /* @__PURE__ */ React3.createElement(Box2, { flexShrink: 0, paddingX: 1 }, /* @__PURE__ */ React3.createElement(Text3, { color: "gray", bold: true }, "ADVANCE"))),
3740
- displayOutput ? /* @__PURE__ */ React3.createElement(Box2, { flexDirection: "column", marginTop: 0, backgroundColor: isPty ? void 0 : "#0a0a0a", paddingX: 1 }, hasCollapsibleContent && !isExpanded && /* @__PURE__ */ React3.createElement(Box2, { marginBottom: 1 }, /* @__PURE__ */ React3.createElement(Text3, { color: "magenta" }, "...", collapsedCount, " lines collapsed... Press CTRL + O to expand.")), /* @__PURE__ */ React3.createElement(Text3, { color: completed ? "gray" : void 0 }, renderedOutput)) : !completed && /* @__PURE__ */ React3.createElement(Box2, { marginTop: 1, backgroundColor: isPty ? void 0 : "#0a0a0a", paddingX: 1 }, /* @__PURE__ */ React3.createElement(Text3, { color: "white", italic: true }, "Waiting for output...")),
3739
+ /* @__PURE__ */ React3.createElement(Box2, { marginBottom: 1, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React3.createElement(Box2, { flexShrink: 1, paddingRight: 2 }, /* @__PURE__ */ React3.createElement(Text3, null, /* @__PURE__ */ React3.createElement(Text3, { color: "white", bold: true }, completed ? "\u{1F3C1} FINISHED:" : "\u26A1 EXECUTING:", " "), /* @__PURE__ */ React3.createElement(Text3, { color: "white" }, command))), isPty && /* @__PURE__ */ React3.createElement(Box2, { flexShrink: 0, paddingX: 1 }, /* @__PURE__ */ React3.createElement(Text3, { color: "green", bold: true }, "ADVANCE"))),
3740
+ displayOutput ? /* @__PURE__ */ React3.createElement(Box2, { flexDirection: "column", marginTop: 0, backgroundColor: isPty ? void 0 : "#0a0a0a", paddingX: 1, width: "100%" }, hasCollapsibleContent && !isExpanded && /* @__PURE__ */ React3.createElement(Box2, { marginBottom: 1 }, /* @__PURE__ */ React3.createElement(Text3, { color: "magenta" }, "...", collapsedCount, " lines collapsed...")), /* @__PURE__ */ React3.createElement(Text3, { color: completed ? void 0 : void 0 }, renderedOutput)) : !completed && /* @__PURE__ */ React3.createElement(Box2, { marginTop: 1, backgroundColor: isPty ? void 0 : "#0a0a0a", paddingX: 1, width: "100%" }, /* @__PURE__ */ React3.createElement(Text3, { color: "white", italic: true }, "Waiting for output...")),
3741
3741
  /* @__PURE__ */ React3.createElement(Box2, { justifyContent: "space-between", marginTop: 1 }, !completed ? /* @__PURE__ */ React3.createElement(Text3, { color: "gray", italic: true }, isFocused ? "Press TAB to unfocus, then double-press ESC to terminate." : "Double-press ESC to terminate if hanging.") : /* @__PURE__ */ React3.createElement(Box2, null), /* @__PURE__ */ React3.createElement(Text3, { color: "gray", bold: true }, completed ? "\u25CF ARCHIVED" : isFocused ? "\u25B6 TERMINAL FOCUSED" : "\u25CF LIVE (Press TAB to focus)"))
3742
3742
  );
3743
3743
  });
@@ -4031,7 +4031,7 @@ var init_ChatLayout = __esm({
4031
4031
  const availableWidth = columns - 10;
4032
4032
  const trimmed = cleaned.trim();
4033
4033
  if (!trimmed.includes("```")) {
4034
- return /* @__PURE__ */ React4.createElement(Box3, { width: "100%", flexDirection: "column" }, /* @__PURE__ */ React4.createElement(MarkdownText, { text: trimmed, color: "gray", columns: availableWidth, italic: true }));
4034
+ return /* @__PURE__ */ React4.createElement(Box3, { width: "100%", flexDirection: "column" }, /* @__PURE__ */ React4.createElement(MarkdownText, { text: trimmed, color: "#969696", columns: availableWidth, italic: true }));
4035
4035
  }
4036
4036
  const parts = trimmed.split(/(```\w*\n?[\s\S]*?(?:```|$))/g);
4037
4037
  return /* @__PURE__ */ React4.createElement(Box3, { width: "100%", flexDirection: "column" }, parts.map((part, i) => {
@@ -4208,10 +4208,10 @@ var init_ChatLayout = __esm({
4208
4208
  const colChars = Math.floor(availableWidth / header.length) - 2;
4209
4209
  return (
4210
4210
  // Table MarginY here
4211
- /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", borderStyle: "round", borderColor: "#454545ff", paddingX: 1, marginY: 0, width: "100%", flexGrow: 1 }, /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "row", borderStyle: "single", borderBottom: true, borderTop: false, borderLeft: false, borderRight: false, borderColor: "#444", marginBottom: 1, paddingBottom: 0, width: "100%" }, header.map((cell, i) => /* @__PURE__ */ React4.createElement(Box3, { key: i, flexBasis: `${colPercentage}%`, flexGrow: 1, flexShrink: 0, paddingRight: 2 }, /* @__PURE__ */ React4.createElement(InlineMarkdown, { text: wrapText(cell, colChars), color: "cyan" })))), data.map((row, ri) => /* @__PURE__ */ React4.createElement(Box3, { key: ri, flexDirection: "row", marginBottom: ri === data.length - 1 ? 0 : 1, width: "100%" }, row.map((cell, ci) => /* @__PURE__ */ React4.createElement(Box3, { key: ci, flexBasis: `${colPercentage}%`, flexGrow: 1, flexShrink: 0, paddingRight: 2, flexDirection: "column" }, /* @__PURE__ */ React4.createElement(InlineMarkdown, { text: wrapText(cell, colChars), color: "white" }))))))
4211
+ /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", borderStyle: "round", borderColor: "#454545ff", paddingX: 1, marginY: 0, width: terminalWidth - 2 }, /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "row", borderStyle: "single", borderBottom: true, borderTop: false, borderLeft: false, borderRight: false, borderColor: "#444", marginBottom: 1, paddingBottom: 0, width: "100%" }, header.map((cell, i) => /* @__PURE__ */ React4.createElement(Box3, { key: i, flexBasis: `${colPercentage}%`, flexGrow: 1, flexShrink: 0, paddingRight: 2 }, /* @__PURE__ */ React4.createElement(InlineMarkdown, { text: wrapText(cell, colChars), color: "cyan" })))), data.map((row, ri) => /* @__PURE__ */ React4.createElement(Box3, { key: ri, flexDirection: "row", marginBottom: ri === data.length - 1 ? 0 : 1, width: "100%" }, row.map((cell, ci) => /* @__PURE__ */ React4.createElement(Box3, { key: ci, flexBasis: `${colPercentage}%`, flexGrow: 1, flexShrink: 0, paddingRight: 2, flexDirection: "column" }, /* @__PURE__ */ React4.createElement(InlineMarkdown, { text: wrapText(cell, colChars), color: "white" }))))))
4212
4212
  );
4213
4213
  });
4214
- MarkdownText = React4.memo(({ text, color = "white", columns = 80, italic = false }) => {
4214
+ MarkdownText = React4.memo(({ text, color = "#D6DAE3", columns = 80, italic = false }) => {
4215
4215
  if (!text) return null;
4216
4216
  const lines = text.split("\n");
4217
4217
  const result = [];
@@ -4500,26 +4500,29 @@ var init_ChatLayout = __esm({
4500
4500
  if (msg.isAskRecord) {
4501
4501
  const selectionMatch = msg.text.match(/Selection: (.*)/);
4502
4502
  const selection = selectionMatch ? selectionMatch[1] : "No selection";
4503
+ const questionMatch = msg.text.match(/Question: (.*)/);
4504
+ const question = questionMatch ? questionMatch[1] : null;
4503
4505
  const s = emojiSpace(2);
4504
4506
  return /* @__PURE__ */ React4.createElement(Box3, { marginBottom: 0, paddingX: 1, width: "100%" }, /* @__PURE__ */ React4.createElement(
4505
4507
  Box3,
4506
4508
  {
4507
4509
  flexDirection: "column",
4508
4510
  borderStyle: "single",
4509
- borderLeft: true,
4511
+ borderLeft: false,
4510
4512
  borderRight: false,
4511
- borderTop: false,
4512
- borderBottom: false,
4513
+ borderTop: true,
4514
+ borderBottom: true,
4513
4515
  borderColor: "#444444",
4514
4516
  paddingLeft: 2,
4515
4517
  paddingRight: 0,
4516
4518
  paddingTop: 1,
4517
4519
  paddingBottom: 1,
4518
- backgroundColor: "#1a1a1a",
4519
- width: "100%"
4520
+ marginY: 1,
4521
+ width: columns - 2
4520
4522
  },
4521
- /* @__PURE__ */ React4.createElement(Box3, { paddingX: 1 }, /* @__PURE__ */ React4.createElement(Text4, { color: "white", bold: true }, "AGENT REQUEST: RESOLVED")),
4522
- /* @__PURE__ */ React4.createElement(Box3, { paddingX: 1, marginTop: 1, marginBottom: 1 }, /* @__PURE__ */ React4.createElement(Text4, { color: "white" }, "Selection: ", /* @__PURE__ */ React4.createElement(Text4, { color: "grey", bold: true }, selection)))
4523
+ /* @__PURE__ */ React4.createElement(Box3, { paddingX: 1 }, /* @__PURE__ */ React4.createElement(Text4, { color: "green", bold: true }, "AGENT REQUEST: RESOLVED")),
4524
+ question && /* @__PURE__ */ React4.createElement(Box3, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React4.createElement(Text4, { color: "cyan" }, question)),
4525
+ /* @__PURE__ */ React4.createElement(Box3, { paddingX: 1, marginTop: 1, marginBottom: 0 }, /* @__PURE__ */ React4.createElement(Text4, { color: "white" }, "Selection: ", /* @__PURE__ */ React4.createElement(Text4, { color: "grey", bold: true }, selection)))
4523
4526
  ));
4524
4527
  }
4525
4528
  if (msg.isAboutRecord) {
@@ -4632,7 +4635,7 @@ var init_ChatLayout = __esm({
4632
4635
  finalContent.replace(/\r\n/g, "\n").replace(/\r/g, "\n").replace(/\\\n/g, "\n").replace(/\\$/, ""),
4633
4636
  columns - 7
4634
4637
  ).split("\n").map((line, lineIdx) => /* @__PURE__ */ React4.createElement(Box3, { key: lineIdx, flexDirection: "row", width: "100%" }, /* @__PURE__ */ React4.createElement(Box3, { flexShrink: 0, width: 2 }, /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, lineIdx === 0 ? ">" : " ")), /* @__PURE__ */ React4.createElement(Box3, { flexGrow: 1, marginLeft: 1 }, /* @__PURE__ */ React4.createElement(InlineMarkdown, { text: line, color: msg.color || "white" }))))
4635
- ), /* @__PURE__ */ React4.createElement(Box3, { width: columns - 1, height: 1, overflow: "hidden" }, /* @__PURE__ */ React4.createElement(Text4, { color: "#444444" }, "\u2580".repeat(Math.max(1, columns - 1))))) : msg.role === "think" ? /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", marginTop: 0, marginBottom: 0, paddingX: 1, width: "100%" }, msg.isStreaming && !msg.duration ? /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, "\u2727 Thinking...") : /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, "\u2726 Thought", msg.duration ? /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, " for ", /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, formatThinkingDuration(msg.duration))) : "..."), /* @__PURE__ */ React4.createElement(Box3, { borderStyle: "single", borderLeft: true, borderRight: false, borderTop: false, borderBottom: false, paddingLeft: 2, paddingTop: 1, paddingBottom: 1, flexDirection: "column", width: "100%" }, formatThinkText(finalContent, columns))) : /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", paddingX: 1, marginTop: 0, width: "100%" }, /* @__PURE__ */ React4.createElement(CodeRenderer, { text: finalContent.replace(/ \|\n\n/g, " |\n"), columns }), msg.memoryUpdated && /* @__PURE__ */ React4.createElement(Box3, { marginTop: 1, width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, { color: "white", italic: true }, "[Memory Updated]")), msg.role === "agent" && msg.workedDuration ? /* @__PURE__ */ React4.createElement(Box3, { marginTop: 1, marginBottom: 2, width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, null, "["), /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, "Worked for ", /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, formatThinkingDuration(msg.workedDuration))), /* @__PURE__ */ React4.createElement(Text4, null, "]")) : null))
4638
+ ), /* @__PURE__ */ React4.createElement(Box3, { width: columns - 1, height: 1, overflow: "hidden" }, /* @__PURE__ */ React4.createElement(Text4, { color: "#444444" }, "\u2580".repeat(Math.max(1, columns - 1))))) : msg.role === "think" ? /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", marginTop: 0, marginBottom: 0, paddingX: 1, width: "100%" }, msg.isStreaming && !msg.duration ? /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "#F2F2F2" }, "\u2727 Thinking...") : /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "#F2F2F2" }, "\u2726 Thought", msg.duration ? /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, " for ", /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, formatThinkingDuration(msg.duration))) : "..."), /* @__PURE__ */ React4.createElement(Box3, { borderStyle: "single", borderLeft: true, borderRight: false, borderTop: false, borderBottom: false, paddingLeft: 2, paddingTop: 1, paddingBottom: 1, flexDirection: "column", width: "100%" }, formatThinkText(finalContent, columns))) : /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", paddingX: 1, marginTop: 0, width: "100%" }, /* @__PURE__ */ React4.createElement(CodeRenderer, { text: finalContent.replace(/ \|\n\n/g, " |\n"), columns }), msg.memoryUpdated && /* @__PURE__ */ React4.createElement(Box3, { marginTop: 1, width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, { color: "white", italic: true }, "[Memory Updated]")), msg.role === "agent" && msg.workedDuration ? /* @__PURE__ */ React4.createElement(Box3, { marginTop: 1, marginBottom: 2, width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, null, "["), /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, "Worked for ", /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, formatThinkingDuration(msg.workedDuration))), /* @__PURE__ */ React4.createElement(Text4, null, "]")) : null))
4636
4639
  );
4637
4640
  });
4638
4641
  BlockItem = React4.memo(({ block, columns = 80, showFullThinking, aiProvider, version }) => {
@@ -4663,7 +4666,7 @@ var init_ChatLayout = __esm({
4663
4666
  );
4664
4667
  }
4665
4668
  if (type === "think-header") {
4666
- return /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", paddingX: 1, width: "100%", marginTop: 0, marginBottom: 0 }, isStreamingMsg ? /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, "\u2727 Thinking...") : /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "white" }, "\u2726 Thought..."), showFullThinking && /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "row", width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, "\u2502 ")));
4669
+ return /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "column", paddingX: 1, width: "100%", marginTop: 0, marginBottom: 0 }, isStreamingMsg ? /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "#F2F2F2" }, "\u2727 Thinking...") : /* @__PURE__ */ React4.createElement(Text4, { bold: true, color: "#F2F2F2" }, "\u2726 Thought..."), showFullThinking && /* @__PURE__ */ React4.createElement(Box3, { flexDirection: "row", width: "100%" }, /* @__PURE__ */ React4.createElement(Text4, { color: "gray" }, "\u2502 ")));
4667
4670
  }
4668
4671
  if (type === "think-line") {
4669
4672
  if (!showFullThinking) return null;
@@ -5175,7 +5178,7 @@ Internal tools. **MUST use the EXACT syntax** [tool:functions.ToolName(args)]. *
5175
5178
  - **MAX 3 TOOL CALLS PER TURN${mode === "Flux" ? " (EXCEPTION FOR Todo TOOL: 3+ CALLS ALLOWED, Run TOOL: Limit 1, OR 2 CONSECUTIVE Run TOOL)" : ""}. Next Turn, verify tool results, plan next**
5176
5179
  ${mode === "Flux" ? "- USE multiple search & replace on patch tool if editing same file/path with many changes \u2190 **HIGHLY RECOMMENDED**\n- Tool execution denied? MUST use 'Ask' tool immediately for user reason/changes. NEVER END RESPONSE OR PROCEED BLINDLY \u2190 **MANDATORY**\n- FileMap >>> ReadFile to understand file efficiently\n- Want spefific STRING across project/file? SearchKeyword >> Guessing/ReadFile\n- HUGE FILES? SearchKeyword >> FileMap/Full Read\n- No tool spamming\n- **MUST MARK DONE/APPEND Todos BASED ON REALTIME TASK PROGRESS ON *EVERY TURN***" : ""}
5177
5180
  ${mode === "Flux" ? "- **File Tools >> Code in chat**\n\n" : ""}- COMMUNICATION TOOLS -
5178
- 1. [tool:functions.Ask(question="...", optionA="option::description", ...MAX 4)]. Ambiguity Resolution. Mandatory Triggers: Path Divergence, Security, Risk Mitigation. ask >> finish/guess. Suggest best options; don't ask for preferences
5181
+ 1. [tool:functions.Ask(question="...", optionA="option::description", ...MAX 4)]. Ambiguity Resolution. Mandatory Triggers: Path Divergence, Security, Risk Mitigation. ask >> finish/guess. Suggest best options; don't ask for preferences. 'option' SHOULD be short
5179
5182
 
5180
5183
  - WEB TOOLS -
5181
5184
  1. [tool:functions.WebSearch(query="...", limit=number)]. Limit 3-10. Proactive use for unknown info/docs
@@ -5187,7 +5190,7 @@ ${mode === "Flux" ? `- WORKSPACE TOOLS (path = relative to CWD & WILL BE FIRST A
5187
5190
  3. [tool:functions.FileMap(path="path/file")]. Shows file structure, functions, class, import/export, variable
5188
5191
  4. [tool:functions.PatchFile(path="...", replaceContent1="full line/block", newContent1="...", ...MAX 6)]. Surgical Patch. **Multiple patch on same file/path? Use replaceContent2, newContent2 etc >>> multiple spams**. Unsure? ReadFile >> guessing. **MUST VERIFY DIFF**
5189
5192
  5. [tool:functions.WriteFile(path="...", content="...")]. Creates/Overwrites. File Exist? PatchFile > WriteFile. Verify Imports
5190
- 6. [tool:functions.SearchKeyword(keyword="...", file="optional", subString="true/false optional")]. Global project search. If 'file' is provided, searches only that file. Finds definitions/logic without reading every file. Usage: Can search for relevent lines/logic area to read specifically for edit
5193
+ 6. [tool:functions.SearchKeyword(keyword="...", file="optional", subString="true/false optional", regex="true/false optional")]. Global project search. If 'file' is provided, searches only that file. Finds definitions/logic without reading every file. Usage: Can search for relevent lines/logic area to read specifically for edit. Optional parameters default to false
5191
5194
  7. [tool:functions.Run(command="...")]. Runs ${osDetected === "Windows" ? isPsAvailable() ? `WINDOWS POWERSHELL ONLY` : `WINDOWS CMD ONLY` : `BASH`} command. Destructive/Irreversible ops \u2192 Ask user
5192
5195
  8. [tool:functions.Todo(method="create/append/get", tasks=[ARRAY OF STRINGS], markDone=[ARRAY OF TASK STRINGS])]. Task List, NO Markdown IN ARRAY. USAGE: ANALYZE USER REQUEST **IF** MULTIPLE TASK \u2192 BREAK DOWN TASK \u2192 CREATE TODO **BEFORE** DIVING IN. 'tasks' & 'markDone' OPTIONAL PARAMETERS WITH method 'get'. USE 'get' method WITH 'markDone' to mark task completed. **EVERY TURN UPDATE POLICY**
5193
5196
  9. [tool:functions.Await(time="seconds")]. For waiting without exiting agent loop, 15s - 180s
@@ -5965,6 +5968,7 @@ function SettingsMenu({
5965
5968
  { label: "Current Provider", value: "aiProvider", status: aiProvider },
5966
5969
  { label: "Key Strategy", value: "apiTier", status: apiTier === "Free" ? "Free" : quotas?.providerBudgets?.__useProvider ? "Paid" : "Paid" },
5967
5970
  { label: "Preserve Thinking", value: "preserveThinking", status: systemSettings.preserveThinking !== false ? "ON" : "OFF" },
5971
+ { label: "Loading Phrases", value: "loadingPhrases", status: systemSettings.loadingPhrases !== false ? "ON" : "OFF" },
5968
5972
  { label: "Download Language Parsers", value: "parserDownload", status: "ACTION" }
5969
5973
  ];
5970
5974
  default:
@@ -6127,6 +6131,12 @@ function SettingsMenu({
6127
6131
  saveSettings2({ systemSettings: newSysSettings, apiTier, quotas });
6128
6132
  return newSysSettings;
6129
6133
  });
6134
+ } else if (item.value === "loadingPhrases") {
6135
+ setSystemSettings((s) => {
6136
+ const newSysSettings = { ...s, loadingPhrases: s.loadingPhrases === false ? true : false };
6137
+ saveSettings2({ systemSettings: newSysSettings, apiTier, quotas });
6138
+ return newSysSettings;
6139
+ });
6130
6140
  }
6131
6141
  };
6132
6142
  return /* @__PURE__ */ React7.createElement(Box6, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%", minHeight: 32 }, /* @__PURE__ */ React7.createElement(Box6, { paddingX: 1, paddingY: 0, marginBottom: 0, borderStyle: "single", borderColor: "gray", width: "100%" }, /* @__PURE__ */ React7.createElement(Text7, { color: "white", bold: true }, "SYSTEM CONFIGURATION")), /* @__PURE__ */ React7.createElement(Box6, { flexDirection: "row", width: "100%", minHeight: 26 }, /* @__PURE__ */ React7.createElement(Box6, { flexDirection: "column", width: "30%", borderStyle: "round", borderColor: activeColumn === "categories" ? "white" : "grey", padding: 1, paddingY: 0 }, /* @__PURE__ */ React7.createElement(Box6, { marginBottom: 1 }, /* @__PURE__ */ React7.createElement(Text7, { color: activeColumn === "categories" ? "white" : "grey", bold: true, underline: true }, "CATEGORIES")), CATEGORIES.map((cat, index) => {
@@ -6211,7 +6221,7 @@ function SettingsMenu({
6211
6221
  });
6212
6222
  if (currentCatId === "other") {
6213
6223
  elements.push(
6214
- /* @__PURE__ */ React7.createElement(Box6, { key: "pty-notice", marginTop: 16, paddingX: 1 }, /* @__PURE__ */ React7.createElement(Text7, { color: "white" }, isPtyAvailable ? "\u2713 Advance Interactive Terminal Supported" : "\u26A0 Interactive Terminal is Limited"))
6224
+ /* @__PURE__ */ React7.createElement(Box6, { key: "pty-notice", marginTop: 15, paddingX: 1 }, /* @__PURE__ */ React7.createElement(Text7, { color: "white" }, isPtyAvailable ? "\u2713 Advance Interactive Terminal Supported" : "\u26A0 Interactive Terminal is Limited"))
6215
6225
  );
6216
6226
  elements.push(
6217
6227
  /* @__PURE__ */ React7.createElement(Box6, { key: "memory-load-2026", paddingX: 1 }, /* @__PURE__ */ React7.createElement(Text7, { color: "gray" }, "Memory Load: ", currentMemory, "/", maxMemory, " ", memoryUnit))
@@ -6332,7 +6342,13 @@ var init_AskUserModal = __esm({
6332
6342
  const [isSuggestingElse, setIsSuggestingElse] = useState8(false);
6333
6343
  const [customInput, setCustomInput] = useState8("");
6334
6344
  const [selectedIndex, setSelectedIndex] = useState8(0);
6335
- const allOptions = [...options, { id: "CUSTOM", label: "Suggest something else...", description: "Provide a custom response" }];
6345
+ let canceled = false;
6346
+ let allOptions = [];
6347
+ try {
6348
+ allOptions = [...options, { id: "CUSTOM", label: "Suggest something else...", description: "Provide a custom response" }];
6349
+ } catch (e) {
6350
+ canceled = true;
6351
+ }
6336
6352
  useInput4((input, key) => {
6337
6353
  if (isSuggestingElse) return;
6338
6354
  if (key.leftArrow || key.upArrow) {
@@ -6343,10 +6359,11 @@ var init_AskUserModal = __esm({
6343
6359
  }
6344
6360
  if (key.return) {
6345
6361
  const selected = allOptions[selectedIndex];
6346
- if (selected.id === "CUSTOM") {
6362
+ if (selected?.id === "CUSTOM") {
6347
6363
  setIsSuggestingElse(true);
6348
6364
  } else {
6349
- onResolve(selected.label);
6365
+ if (canceled) onResolve("Selected Nothing");
6366
+ else onResolve(selected.label);
6350
6367
  }
6351
6368
  }
6352
6369
  });
@@ -6369,9 +6386,9 @@ var init_AskUserModal = __esm({
6369
6386
  backgroundColor: "#1a1a1a",
6370
6387
  width: "100%"
6371
6388
  },
6372
- /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1 }, /* @__PURE__ */ React9.createElement(Text9, { color: "white", bold: true }, "\u{1F4AC} SUGGEST SOMETHING ELSE")),
6389
+ /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1 }, /* @__PURE__ */ React9.createElement(Text9, { color: "white", bold: true }, "SUGGEST SOMETHING ELSE")),
6373
6390
  /* @__PURE__ */ React9.createElement(Box8, { marginTop: 1, paddingX: 1 }, /* @__PURE__ */ React9.createElement(Text9, { italic: true, color: "gray" }, "Replying to: ", question)),
6374
- /* @__PURE__ */ React9.createElement(Box8, { marginTop: 1, paddingX: 1, flexDirection: "row" }, /* @__PURE__ */ React9.createElement(Text9, { color: "white", bold: true }, "\u{1F4A0} "), /* @__PURE__ */ React9.createElement(
6391
+ /* @__PURE__ */ React9.createElement(Box8, { marginTop: 1, paddingX: 1, flexDirection: "row" }, /* @__PURE__ */ React9.createElement(
6375
6392
  TextInput3,
6376
6393
  {
6377
6394
  value: customInput,
@@ -6386,21 +6403,19 @@ var init_AskUserModal = __esm({
6386
6403
  Box8,
6387
6404
  {
6388
6405
  flexDirection: "column",
6389
- borderStyle: "single",
6390
- borderLeft: true,
6391
- borderRight: false,
6392
- borderTop: false,
6393
- borderBottom: false,
6406
+ border: true,
6407
+ borderStyle: "round",
6394
6408
  borderColor: "#444444",
6395
6409
  paddingLeft: 2,
6396
6410
  paddingRight: 0,
6397
6411
  paddingTop: 1,
6398
6412
  paddingBottom: 1,
6399
- backgroundColor: "#1a1a1a",
6413
+ marginY: 1,
6414
+ marginRight: 1,
6400
6415
  width: "100%"
6401
6416
  },
6402
- /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React9.createElement(Text9, { color: "white", bold: true }, "AGENT REQUEST: ACTION REQUIRED")),
6403
- /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React9.createElement(Text9, { bold: true, color: "white" }, question)),
6417
+ /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React9.createElement(Text9, { color: "yellow", bold: true }, "AGENT REQUEST: ACTION REQUIRED")),
6418
+ /* @__PURE__ */ React9.createElement(Box8, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React9.createElement(Text9, { color: "white" }, question)),
6404
6419
  /* @__PURE__ */ React9.createElement(Box8, { flexDirection: "column", width: "100%" }, allOptions.map((opt, idx) => {
6405
6420
  const isSelected = idx === selectedIndex;
6406
6421
  return /* @__PURE__ */ React9.createElement(
@@ -8890,10 +8905,22 @@ var init_search_keyword = __esm({
8890
8905
  "src/tools/search_keyword.js"() {
8891
8906
  init_arg_parser();
8892
8907
  search_keyword = async (args) => {
8893
- const { keyword, file, subString } = parseArgs(args);
8908
+ const { keyword, file, subString, regex } = parseArgs(args);
8894
8909
  if (!keyword) return 'ERROR: Missing "keyword" argument.';
8895
- const matchSubstring = subString === true || subString === "true" || subString === 1 || subString === "1" || subString === "true" || subString === "yes" || subString === "yes" || false;
8896
- const wordRegex = new RegExp(`(?<![\\w])${keyword.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")}(?![\\w])`, "i");
8910
+ const toBool = (v) => v === true || v === "true" || v === 1 || v === "1" || v === "yes";
8911
+ const matchRegex = toBool(regex);
8912
+ const matchSubstring = !matchRegex && toBool(subString);
8913
+ let regexPattern;
8914
+ let wordRegex;
8915
+ if (matchRegex) {
8916
+ try {
8917
+ regexPattern = new RegExp(keyword, "i");
8918
+ } catch (e) {
8919
+ return `ERROR: Invalid regex pattern "${keyword}": ${e.message}`;
8920
+ }
8921
+ } else {
8922
+ wordRegex = new RegExp(`(?<![\\w])${keyword.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")}(?![\\w])`, "i");
8923
+ }
8897
8924
  const excludes = [
8898
8925
  "node_modules",
8899
8926
  ".git",
@@ -8933,7 +8960,7 @@ var init_search_keyword = __esm({
8933
8960
  const lines = content.split(/\r?\n/);
8934
8961
  const fileMatches = [];
8935
8962
  for (let i = 0; i < lines.length; i++) {
8936
- const matched = matchSubstring ? lines[i].toLowerCase().includes(keyword.toLowerCase()) || fuzzyMatch(lines[i], keyword) : wordRegex.test(lines[i]);
8963
+ const matched = matchRegex ? regexPattern.test(lines[i]) : matchSubstring ? lines[i].toLowerCase().includes(keyword.toLowerCase()) || fuzzyMatch(lines[i], keyword) : wordRegex.test(lines[i]);
8937
8964
  if (matched) {
8938
8965
  fileMatches.push({ line: i + 1, content: lines[i].trim() });
8939
8966
  }
@@ -8959,10 +8986,11 @@ var init_search_keyword = __esm({
8959
8986
  if (typeof global.gc === "function") {
8960
8987
  global.gc();
8961
8988
  }
8989
+ const modeLabel = matchRegex ? "(regex mode)" : matchSubstring ? "(subString mode)" : "";
8962
8990
  if (fileGroups.length === 0) {
8963
- return `Found 0 matches for keyword: "${keyword}"${file ? ` in file: ${file}` : ". Try to specify files"} ${matchSubstring ? "(subString mode)" : ""}`;
8991
+ return `Found 0 matches for keyword: "${keyword}"${file ? ` in file: ${file}` : ". Try to specify files"} ${modeLabel}`;
8964
8992
  }
8965
- let output = `Found ${totalMatches} match${totalMatches === 1 ? "" : "es"} across ${fileGroups.length} file${fileGroups.length === 1 ? "" : "s"} ${matchSubstring ? "(subString mode)" : ""}:
8993
+ let output = `Found ${totalMatches} match${totalMatches === 1 ? "" : "es"} across ${fileGroups.length} file${fileGroups.length === 1 ? "" : "s"} ${modeLabel}:
8966
8994
 
8967
8995
  `;
8968
8996
  for (const group of fileGroups) {
@@ -11036,80 +11064,104 @@ var init_ai = __esm({
11036
11064
  body.chat_template_kwargs = { enable_thinking: false };
11037
11065
  }
11038
11066
  }
11039
- const response = await fetchWithBackoff("https://integrate.api.nvidia.com/v1/chat/completions", {
11040
- method: "POST",
11041
- headers: {
11042
- "Content-Type": "application/json",
11043
- "Authorization": `Bearer ${apiKey}`
11044
- },
11045
- body: JSON.stringify(body),
11046
- signal
11047
- });
11048
- if (!response.ok) {
11049
- const err = await response.json();
11050
- const error = new Error(`NVIDIA API Error: ${err.error?.message || response.statusText}`);
11051
- error.status = response.status;
11052
- throw error;
11053
- }
11054
- const reader = response.body.getReader();
11055
- const decoder = new TextDecoder();
11056
- let buffer = "";
11057
- let pendingParts = [];
11058
- let latestUsageMetadata = null;
11059
- let lastFlushTime = Date.now();
11060
- let hasNewData = false;
11061
- while (true) {
11062
- const { done, value } = await reader.read();
11063
- if (done) {
11064
- if (hasNewData && (pendingParts.length > 0 || latestUsageMetadata)) {
11065
- yield {
11066
- candidates: pendingParts.length > 0 ? [{ content: { parts: pendingParts } }] : [],
11067
- usageMetadata: latestUsageMetadata
11068
- };
11067
+ let attempts = 0;
11068
+ const maxAttempts = 6;
11069
+ let hasYielded = false;
11070
+ while (attempts < maxAttempts) {
11071
+ attempts++;
11072
+ try {
11073
+ const response = await fetchWithBackoff("https://integrate.api.nvidia.com/v1/chat/completions", {
11074
+ method: "POST",
11075
+ headers: {
11076
+ "Content-Type": "application/json",
11077
+ "Authorization": `Bearer ${apiKey}`
11078
+ },
11079
+ body: JSON.stringify(body),
11080
+ signal
11081
+ });
11082
+ if (!response.ok) {
11083
+ const err = await response.json();
11084
+ const error = new Error(`NVIDIA API Error: ${err.error?.message || response.statusText}`);
11085
+ error.status = response.status;
11086
+ throw error;
11069
11087
  }
11070
- break;
11071
- }
11072
- buffer += decoder.decode(value, { stream: true });
11073
- const lines = buffer.split("\n");
11074
- buffer = lines.pop();
11075
- for (const line of lines) {
11076
- const trimmed = line.trim();
11077
- if (!trimmed || trimmed === "data: [DONE]") continue;
11078
- if (trimmed.startsWith("data: ")) {
11079
- try {
11080
- const json = JSON.parse(trimmed.substring(6));
11081
- const usage = json.usage;
11082
- if (usage) {
11083
- latestUsageMetadata = {
11084
- totalTokenCount: usage.total_tokens || usage.prompt_tokens + usage.completion_tokens,
11085
- promptTokenCount: usage.prompt_tokens || 0,
11086
- candidatesTokenCount: usage.completion_tokens || 0,
11087
- thoughtsTokenCount: (usage.completion_tokens_details?.reasoning_tokens || 0) + (usage.completion_tokens_details?.thoughts_tokens || 0)
11088
+ const reader = response.body.getReader();
11089
+ const decoder = new TextDecoder();
11090
+ let buffer = "";
11091
+ let pendingParts = [];
11092
+ let latestUsageMetadata = null;
11093
+ let lastFlushTime = Date.now();
11094
+ let hasNewData = false;
11095
+ while (true) {
11096
+ const { done, value } = await reader.read();
11097
+ if (done) {
11098
+ if (hasNewData && (pendingParts.length > 0 || latestUsageMetadata)) {
11099
+ yield {
11100
+ candidates: pendingParts.length > 0 ? [{ content: { parts: pendingParts } }] : [],
11101
+ usageMetadata: latestUsageMetadata
11088
11102
  };
11089
- hasNewData = true;
11103
+ hasYielded = true;
11090
11104
  }
11091
- const thinking = json.choices?.[0]?.delta?.reasoning || json.choices?.[0]?.delta?.reasoning_content || "";
11092
- const content = json.choices?.[0]?.delta?.content || "";
11093
- if (thinking) {
11094
- pendingParts.push({ text: thinking, thought: true });
11095
- hasNewData = true;
11096
- }
11097
- if (content) {
11098
- pendingParts.push({ text: content });
11099
- hasNewData = true;
11105
+ break;
11106
+ }
11107
+ buffer += decoder.decode(value, { stream: true });
11108
+ const lines = buffer.split("\n");
11109
+ buffer = lines.pop();
11110
+ for (const line of lines) {
11111
+ const trimmed = line.trim();
11112
+ if (!trimmed || trimmed === "data: [DONE]") continue;
11113
+ if (trimmed.startsWith("data: ")) {
11114
+ let json;
11115
+ try {
11116
+ json = JSON.parse(trimmed.substring(6));
11117
+ } catch (e) {
11118
+ continue;
11119
+ }
11120
+ if (json.error) {
11121
+ throw new Error(`NVIDIA Stream Error: ${json.error.message || JSON.stringify(json.error)}`);
11122
+ }
11123
+ try {
11124
+ const usage = json.usage;
11125
+ if (usage) {
11126
+ latestUsageMetadata = {
11127
+ totalTokenCount: usage.total_tokens || usage.prompt_tokens + usage.completion_tokens,
11128
+ promptTokenCount: usage.prompt_tokens || 0,
11129
+ candidatesTokenCount: usage.completion_tokens || 0,
11130
+ thoughtsTokenCount: (usage.completion_tokens_details?.reasoning_tokens || 0) + (usage.completion_tokens_details?.thoughts_tokens || 0)
11131
+ };
11132
+ hasNewData = true;
11133
+ }
11134
+ const thinking = json.choices?.[0]?.delta?.reasoning || json.choices?.[0]?.delta?.reasoning_content || "";
11135
+ const content = json.choices?.[0]?.delta?.content || "";
11136
+ if (thinking) {
11137
+ pendingParts.push({ text: thinking, thought: true });
11138
+ hasNewData = true;
11139
+ }
11140
+ if (content) {
11141
+ pendingParts.push({ text: content });
11142
+ hasNewData = true;
11143
+ }
11144
+ } catch (e) {
11145
+ }
11100
11146
  }
11101
- } catch (e) {
11147
+ }
11148
+ if (Date.now() - lastFlushTime >= 350 && hasNewData) {
11149
+ yield {
11150
+ candidates: pendingParts.length > 0 ? [{ content: { parts: [...pendingParts] } }] : [],
11151
+ usageMetadata: latestUsageMetadata
11152
+ };
11153
+ hasYielded = true;
11154
+ pendingParts = [];
11155
+ lastFlushTime = Date.now();
11156
+ hasNewData = false;
11102
11157
  }
11103
11158
  }
11104
- }
11105
- if (Date.now() - lastFlushTime >= 350 && hasNewData) {
11106
- yield {
11107
- candidates: pendingParts.length > 0 ? [{ content: { parts: [...pendingParts] } }] : [],
11108
- usageMetadata: latestUsageMetadata
11109
- };
11110
- pendingParts = [];
11111
- lastFlushTime = Date.now();
11112
- hasNewData = false;
11159
+ break;
11160
+ } catch (error) {
11161
+ if (hasYielded || attempts >= maxAttempts) {
11162
+ throw error;
11163
+ }
11164
+ await new Promise((resolve) => setTimeout(resolve, 3500));
11113
11165
  }
11114
11166
  }
11115
11167
  };
@@ -11138,7 +11190,7 @@ var init_ai = __esm({
11138
11190
  if (data && data.queues && data.queues[0] && typeof data.queues[0].queueDepth === "number") {
11139
11191
  const depth = data.queues[0].queueDepth;
11140
11192
  if (!isStreamingStarted) {
11141
- push({ value: { type: "status", content: `Queue Depth ${depth}...` }, done: false });
11193
+ push({ value: { type: "status", content: `Queue ${depth || 1}` }, done: false });
11142
11194
  }
11143
11195
  }
11144
11196
  }
@@ -12528,7 +12580,7 @@ Provide a consolidated summary of the entire session.`;
12528
12580
  return result;
12529
12581
  };
12530
12582
  yield { type: "status", content: "[start]" };
12531
- yield { type: "status", content: "Gathering Context..." };
12583
+ yield { type: "status", content: "Gathering Context" };
12532
12584
  const totalFolders = countFolders(process.cwd());
12533
12585
  let dynamicMaxDepth = 12;
12534
12586
  if (totalFolders > 4096) dynamicMaxDepth = 1;
@@ -12858,7 +12910,7 @@ ${activeSummaryBlock}${thinkingLevel !== "Fast" && thinkingLevel !== "xHigh" &&
12858
12910
  let lastUsage = null;
12859
12911
  const MAX_LOOPS = mode === "Flux" ? 100 : 10;
12860
12912
  const MAX_RETRIES = 16;
12861
- yield { type: "status", content: "Connecting..." };
12913
+ yield { type: "status", content: "Connecting" };
12862
12914
  TERMINATION_SIGNAL = false;
12863
12915
  let fullAgentResponseChunks = [];
12864
12916
  let wasToolCalledInLastLoop = false;
@@ -12875,7 +12927,7 @@ ${activeSummaryBlock}${thinkingLevel !== "Fast" && thinkingLevel !== "xHigh" &&
12875
12927
  modifiedHistory = getTruncatedHistory(modifiedHistory, 6);
12876
12928
  }
12877
12929
  if (loop > 0) {
12878
- yield { type: "status", content: "Working..." };
12930
+ yield { type: "status", content: "Working" };
12879
12931
  }
12880
12932
  if (TERMINATION_SIGNAL) {
12881
12933
  yield { type: "status", content: "Request Cancelled" };
@@ -13030,15 +13082,15 @@ ${activeSummaryBlock}${thinkingLevel !== "Fast" && thinkingLevel !== "xHigh" &&
13030
13082
  currentSystemInstruction = getSystemInstruction(profile, !(targetModel || "gemma").toLowerCase().startsWith("gemma") ? thinkingLevel : thinkingLevel, mode, systemSettings, isMemoryEnabled, isFirstPrompt, aiProvider, aiProvider === "Google" ? true : isMultiModal, !(targetModel || "gemma").toLowerCase().startsWith("gemma") ? true : false);
13031
13083
  const lastUserMsg = contents[contents.length - 1];
13032
13084
  if (isBridgeConnected() & loop > 0) {
13033
- yield { type: "status", content: "Verifying..." };
13034
13085
  await new Promise((resolve) => setTimeout(resolve, 2500));
13086
+ yield { type: "status", content: "Verifying" };
13035
13087
  const ideCtxJIT = await getIDEContext();
13036
13088
  const ideErr = ideCtxJIT ? ideCtxJIT.diagnostics : null;
13037
13089
  if (ideErr && lastUserMsg && lastUserMsg.role === "user" && lastUserMsg.parts?.[0]?.text) {
13038
13090
  lastUserMsg.parts[0].text += `
13039
13091
  ${ideErr} [/ERROR]`;
13040
13092
  }
13041
- yield { type: "status", content: "Working..." };
13093
+ yield { type: "status", content: "Working" };
13042
13094
  }
13043
13095
  const isGemma = modelName && modelName.toLowerCase().startsWith("gemma") && aiProvider === "Google";
13044
13096
  if (isGemma) {
@@ -13337,7 +13389,7 @@ ${ideErr} [/ERROR]`;
13337
13389
  settings.onTokenChunk();
13338
13390
  }
13339
13391
  if (isFirstChunk) {
13340
- yield { type: "status", content: "Thinking..." };
13392
+ yield { type: "status", content: "Thinking" };
13341
13393
  isFirstChunk = false;
13342
13394
  }
13343
13395
  if (TERMINATION_SIGNAL) {
@@ -13493,11 +13545,11 @@ ${ideErr} [/ERROR]`;
13493
13545
  }
13494
13546
  }
13495
13547
  }
13496
- const currentLabel = `${TOOL_LABELS2[potentialTool] || potentialTool}${detail ? ` (${detail})` : ""}`;
13548
+ const currentLabel = `${TOOL_LABELS2[potentialTool] || potentialTool}${detail ? ` ${detail}` : ""}`;
13497
13549
  if (potentialTool !== lastToolSniffed || detail !== lastToolDetail) {
13498
13550
  lastToolSniffed = potentialTool;
13499
13551
  lastToolDetail = detail;
13500
- yield { type: "status", content: `${currentLabel}...` };
13552
+ yield { type: "status", content: `${currentLabel}` };
13501
13553
  if (process.stdout.isTTY) {
13502
13554
  const TOOL_TITLES = {
13503
13555
  "WebSearch": "Searching",
@@ -13673,7 +13725,7 @@ ${ideErr} [/ERROR]`;
13673
13725
  const normToolName = NORMALIZE_MAP[toolCall.toolName] || toolCall.toolName;
13674
13726
  const displayLabel = TOOL_LABELS2[normToolName] || toolCall.toolName;
13675
13727
  const detail = getToolDetail(normToolName, toolCall.args);
13676
- yield { type: "status", content: `${displayLabel}${detail ? ` (${detail})` : ""}...` };
13728
+ yield { type: "status", content: `${displayLabel}${detail ? ` ${detail}` : ""}` };
13677
13729
  let label = "";
13678
13730
  if (normToolName === "web_search") {
13679
13731
  const { query, limit = 10 } = parseArgs(toolCall.args);
@@ -14176,7 +14228,7 @@ ${boxMid}}`) };
14176
14228
  continue;
14177
14229
  }
14178
14230
  }
14179
- yield { type: "status", content: `Opening Diff in IDE: ${path21.basename(absPath)}...` };
14231
+ yield { type: "status", content: `Opening Diff in IDE: ${path21.basename(absPath)}` };
14180
14232
  showDiffInIDE(absPath, originalContent, modifiedContent);
14181
14233
  diffOpened = true;
14182
14234
  await new Promise((r) => setTimeout(r, 50));
@@ -14188,7 +14240,7 @@ ${boxMid}}`) };
14188
14240
  fs22.mkdirSync(path21.dirname(absPath), { recursive: true });
14189
14241
  fs22.writeFileSync(absPath, "", "utf8");
14190
14242
  }
14191
- yield { type: "status", content: `Opening New File Diff in IDE: ${path21.basename(absPath)}...` };
14243
+ yield { type: "status", content: `Opening New File Diff in IDE: ${path21.basename(absPath)}` };
14192
14244
  showDiffInIDE(absPath, "", modifiedContent);
14193
14245
  diffOpened = true;
14194
14246
  await new Promise((r) => setTimeout(r, 50));
@@ -14748,13 +14800,13 @@ Error Log can be found in ${path21.join(LOGS_DIR, "agent", "error.log")}`);
14748
14800
  accumulatedContext = "";
14749
14801
  const waitTime = Math.min(1e3 * Math.pow(2, retryCount - 1), 32e3);
14750
14802
  isInitialAttempt = true;
14751
- yield { type: "status", content: `Trying to reach ${modelName} (${retryCount}/${MAX_RETRIES}) [Retrying in ${(waitTime / 1e3).toFixed(0)}s]...` };
14803
+ yield { type: "status", content: `Trying to reach ${modelName} (${retryCount}/${MAX_RETRIES}) [Retrying in ${(waitTime / 1e3).toFixed(0)}s]` };
14752
14804
  for (let i = waitTime / 1e3; i > 0; i--) {
14753
14805
  if (TERMINATION_SIGNAL) break;
14754
- yield { type: "status", content: `Trying to reach ${modelName} (${retryCount}/${MAX_RETRIES}) [Retrying in ${i}s]...` };
14806
+ yield { type: "status", content: `Trying to reach ${modelName} (${retryCount}/${MAX_RETRIES}) [Retrying in ${i}s]` };
14755
14807
  await new Promise((resolve) => setTimeout(resolve, 1e3));
14756
14808
  }
14757
- yield { type: "status", content: `Trying to reach ${modelName}...` };
14809
+ yield { type: "status", content: `Trying to reach ${modelName}` };
14758
14810
  } else {
14759
14811
  throw new Error(`Model ${modelName} cannot be reached. (Failed ${MAX_RETRIES} times)
14760
14812
  Error Log can be found in ${path21.join(LOGS_DIR, "agent", "error.log")}`);
@@ -14785,7 +14837,7 @@ Error Log can be found in ${path21.join(LOGS_DIR, "agent", "error.log")}`);
14785
14837
  const hasFinish = /\[\s*(turn\s*:)?\s*finish\s*\]/i.test(signalSafeText.toLowerCase()) || /\[\[END\]\]/i.test(signalSafeText.toLowerCase()) || true;
14786
14838
  const hasContinue = /\[\s*(turn\s*:)?\s*continue\s*\]/i.test(signalSafeText.toLowerCase());
14787
14839
  const shouldContinue = toolCallPointer > 0;
14788
- yield { type: "status", content: "Thinking..." };
14840
+ yield { type: "status", content: "Thinking" };
14789
14841
  const cleanedTurnText = contextSafeReplace(turnText, /(\[\s*(turn\s*:)?\s*(continue|finish)\s*\]|\[\[END\]\])/gi, "").trim();
14790
14842
  let isActuallyFinished = (hasFinish || toolResults.length === 0) && !isThinkingLoop && !isStutteringLoop && !isGeneralLoop;
14791
14843
  isActuallyFinished = toolResults.length === 0 ? isActuallyFinished : false;
@@ -14900,7 +14952,7 @@ Error Log can be found in ${path21.join(LOGS_DIR, "agent", "error.log")}`);
14900
14952
  "searchkeyword": '- [tool:functions.SearchKeyword(keyword="...", file="optional", subString="true/false")]. Global project text search',
14901
14953
  "websearch": '- [tool:functions.WebSearch(query="...", limit=number)]. Web Search',
14902
14954
  "webscrape": '- [tool:functions.WebScrape(url="...")]. Web Scrape',
14903
- "ask": `- [tool:functions.Ask(question="...", optionA="option::description", ...MAX 4)]. Ambiguity Resolution. Mandatory Triggers: Path Divergence, Security, Risk Mitigation. ask >> finish/guess. Suggest best options; don't ask for preferences`
14955
+ "ask": `- [tool:functions.Ask(question="...", optionA="option::description", ...MAX 4)]. Ambiguity Resolution. Mandatory Triggers: Path Divergence, Security, Risk Mitigation. ask >> finish/guess. Suggest best options; don't ask for preferences. 'option' SHOULD be short`
14904
14956
  };
14905
14957
  const providedToolsSection = `-- TOOL DEFINITIONS (path = relative to CWD, path separator: '/') --
14906
14958
  To call tools USE THIS EXACT SYNTAX: [tool:functions.ToolName(args)]. **NO OTHER SYNTAX/MARKERS/BOUNDARY ALLOWED**
@@ -15951,14 +16003,68 @@ var init_setup = __esm({
15951
16003
  }
15952
16004
  });
15953
16005
 
16006
+ // src/components/GlintText.jsx
16007
+ import React15, { useState as useState14, useEffect as useEffect11 } from "react";
16008
+ import { Text as Text15 } from "ink";
16009
+ var GlintText, GlintText_default;
16010
+ var init_GlintText = __esm({
16011
+ "src/components/GlintText.jsx"() {
16012
+ GlintText = ({
16013
+ text,
16014
+ baseColor = "white",
16015
+ glintColor = "gray",
16016
+ speed = 150,
16017
+ glintWidth = 6,
16018
+ typeSpeed = 30,
16019
+ // 👈 New prop! How fast it backspaces and types! ⌨️
16020
+ ...props
16021
+ }) => {
16022
+ const [position, setPosition] = useState14(-glintWidth);
16023
+ const [displayedText, setDisplayedText] = useState14(text);
16024
+ useEffect11(() => {
16025
+ const timer = setInterval(() => {
16026
+ setPosition((prev) => prev > displayedText.length + glintWidth ? -glintWidth - 40 : prev + 1);
16027
+ }, speed);
16028
+ return () => clearInterval(timer);
16029
+ }, [displayedText.length, speed, glintWidth]);
16030
+ useEffect11(() => {
16031
+ if (text && text.includes("Trying to reach")) {
16032
+ setDisplayedText(text);
16033
+ return;
16034
+ }
16035
+ if (displayedText === text) return;
16036
+ const timer = setTimeout(() => {
16037
+ let commonLen = 0;
16038
+ const minLen = Math.min(displayedText.length, text.length);
16039
+ while (commonLen < minLen && displayedText[commonLen] === text[commonLen]) {
16040
+ commonLen++;
16041
+ }
16042
+ if (displayedText.length > commonLen) {
16043
+ setDisplayedText((prev) => prev.slice(0, -1));
16044
+ } else if (displayedText.length < text.length) {
16045
+ setDisplayedText(text.slice(0, displayedText.length + 1));
16046
+ }
16047
+ }, typeSpeed);
16048
+ return () => clearTimeout(timer);
16049
+ }, [text, displayedText, typeSpeed]);
16050
+ return /* @__PURE__ */ React15.createElement(Text15, null, displayedText.split("").map((char, index) => {
16051
+ const distance = Math.abs(index - position);
16052
+ const color = distance <= glintWidth / 2 ? glintColor : baseColor;
16053
+ return /* @__PURE__ */ React15.createElement(Text15, { key: index, color, ...props }, char);
16054
+ }));
16055
+ };
16056
+ GlintText_default = GlintText;
16057
+ }
16058
+ });
16059
+
15954
16060
  // src/app.jsx
15955
16061
  var app_exports = {};
15956
16062
  __export(app_exports, {
15957
16063
  default: () => App
15958
16064
  });
15959
16065
  import os5 from "os";
15960
- import React15, { useState as useState14, useEffect as useEffect11, useRef as useRef4, useMemo as useMemo2 } from "react";
15961
- import { Box as Box14, Text as Text15, useInput as useInput9, useStdout as useStdout2, Static } from "ink";
16066
+ import React16, { useState as useState15, useEffect as useEffect12, useRef as useRef4, useMemo as useMemo2 } from "react";
16067
+ import { Box as Box14, Text as Text16, useInput as useInput9, useStdout as useStdout2, Static } from "ink";
15962
16068
  import fs24 from "fs-extra";
15963
16069
  import path22 from "path";
15964
16070
  import { exec as exec2 } from "child_process";
@@ -15968,24 +16074,24 @@ import SelectInput2 from "ink-select-input";
15968
16074
  import gradient2 from "gradient-string";
15969
16075
  function App({ args = [] }) {
15970
16076
  let lastGCTime = 1;
15971
- const [confirmExit, setConfirmExit] = useState14(false);
15972
- const [exitCountdown, setExitCountdown] = useState14(10);
16077
+ const [confirmExit, setConfirmExit] = useState15(false);
16078
+ const [exitCountdown, setExitCountdown] = useState15(10);
15973
16079
  const { stdout } = useStdout2();
15974
- const [input, setInput] = useState14("");
15975
- const [inputKey, setInputKey] = useState14(0);
15976
- const [isExpanded, setIsExpanded] = useState14(false);
15977
- const [mode, setMode] = useState14("Flux");
15978
- const [terminalSize, setTerminalSize] = useState14({
16080
+ const [input, setInput] = useState15("");
16081
+ const [inputKey, setInputKey] = useState15(0);
16082
+ const [isExpanded, setIsExpanded] = useState15(false);
16083
+ const [mode, setMode] = useState15("Flux");
16084
+ const [terminalSize, setTerminalSize] = useState15({
15979
16085
  columns: stdout?.columns || 80,
15980
16086
  rows: stdout?.rows || 24
15981
16087
  });
15982
- const [selectedIndex, setSelectedIndex] = useState14(0);
15983
- const [isFilePickerDismissed, setIsFilePickerDismissed] = useState14(false);
15984
- const [showBridgePromo, setShowBridgePromo] = useState14(false);
15985
- const [promoSelectedIndex, setPromoSelectedIndex] = useState14(0);
16088
+ const [selectedIndex, setSelectedIndex] = useState15(0);
16089
+ const [isFilePickerDismissed, setIsFilePickerDismissed] = useState15(false);
16090
+ const [showBridgePromo, setShowBridgePromo] = useState15(false);
16091
+ const [promoSelectedIndex, setPromoSelectedIndex] = useState15(0);
15986
16092
  const suggestionOffsetRef = useRef4(0);
15987
16093
  const persistedModelRef = useRef4(null);
15988
- useEffect11(() => {
16094
+ useEffect12(() => {
15989
16095
  const ideName = getIDEName();
15990
16096
  const isIDE = !["Terminal", "Windows Terminal"].includes(ideName) || !!process.env.VSC_TERMINAL_URL;
15991
16097
  const graceTimer = setTimeout(() => {
@@ -16179,7 +16285,7 @@ function App({ args = [] }) {
16179
16285
  }
16180
16286
  }
16181
16287
  };
16182
- useEffect11(() => {
16288
+ useEffect12(() => {
16183
16289
  const handleResize = () => {
16184
16290
  stdout.write("\x1B[2J\x1B[3J\x1B[H");
16185
16291
  setTerminalSize({
@@ -16192,18 +16298,18 @@ function App({ args = [] }) {
16192
16298
  stdout.off("resize", handleResize);
16193
16299
  };
16194
16300
  }, [stdout]);
16195
- const [thinkingLevel, setThinkingLevel] = useState14("Medium");
16196
- const [aiProvider, setAiProvider] = useState14("Google");
16197
- const [setupStep, setSetupStep] = useState14(0);
16198
- const [latestVer, setLatestVer] = useState14(null);
16199
- const [showFullThinking, setShowFullThinking] = useState14(false);
16200
- const [activeModel, setActiveModel] = useState14("gemma-4-31b-it");
16201
- const [janitorModel, setJanitorModel] = useState14("gemma-4-26b-a4b-it");
16202
- const [isInitializing, setIsInitializing] = useState14(true);
16203
- const [isAppFocused, setIsAppFocused] = useState14(true);
16301
+ const [thinkingLevel, setThinkingLevel] = useState15("Medium");
16302
+ const [aiProvider, setAiProvider] = useState15("Google");
16303
+ const [setupStep, setSetupStep] = useState15(0);
16304
+ const [latestVer, setLatestVer] = useState15(null);
16305
+ const [showFullThinking, setShowFullThinking] = useState15(false);
16306
+ const [activeModel, setActiveModel] = useState15("gemma-4-31b-it");
16307
+ const [janitorModel, setJanitorModel] = useState15("gemma-4-26b-a4b-it");
16308
+ const [isInitializing, setIsInitializing] = useState15(true);
16309
+ const [isAppFocused, setIsAppFocused] = useState15(true);
16204
16310
  const lastFocusEventTime = useRef4(0);
16205
- const [apiKey, setApiKey] = useState14(null);
16206
- const [tempKey, setTempKey] = useState14("");
16311
+ const [apiKey, setApiKey] = useState15(null);
16312
+ const [tempKey, setTempKey] = useState15("");
16207
16313
  const addShiftEnterBinding = async (ideName) => {
16208
16314
  const kbPath = getKeybindingsPath(ideName);
16209
16315
  if (!kbPath) return;
@@ -16254,41 +16360,41 @@ function App({ args = [] }) {
16254
16360
  });
16255
16361
  }
16256
16362
  };
16257
- const [activeView, setActiveView] = useState14("chat");
16258
- const [apiTier, setApiTier] = useState14("Free");
16259
- const [quotas, setQuotas] = useState14({ limitMode: "Daily", agentLimit: 99999999, tokenLimit: 99999999999999, backgroundLimit: 999999, searchLimit: 100, customModelId: "", customLimit: 0, providerBudgets: {} });
16260
- const [inputConfig, setInputConfig] = useState14(null);
16261
- const [budgetReturnView, setBudgetReturnView] = useState14("chat");
16262
- const [providerBudgetQueue, setProviderBudgetQueue] = useState14([]);
16263
- const [providerBudgetCursor, setProviderBudgetCursor] = useState14(0);
16264
- const [pbsCursor, setPbsCursor] = useState14(0);
16265
- const [pbsSelected, setPbsSelected] = useState14({});
16266
- const [systemSettings, setSystemSettings] = useState14({ memory: true, compression: 0, autoExec: false, autoDeleteHistory: "7d", autoUpdate: false, updateManager: "npm", customUpdateCommand: "" });
16267
- const [profileData, setProfileData] = useState14({ name: null, nickname: null, instructions: null });
16268
- const [imageSettings, setImageSettings] = useState14({ keyType: "Default", quality: "Low-High", apiKey: "" });
16269
- const [sessionStats, setSessionStats] = useState14({ tokens: 0 });
16270
- const [lastChunkTime, setLastChunkTime] = useState14(0);
16271
- const [sessionAgentCalls, setSessionAgentCalls] = useState14(0);
16272
- const [sessionBackgroundCalls, setSessionBackgroundCalls] = useState14(0);
16273
- const [sessionTotalTokens, setSessionTotalTokens] = useState14(0);
16274
- const [chatTokens, setChatTokens] = useState14(0);
16363
+ const [activeView, setActiveView] = useState15("chat");
16364
+ const [apiTier, setApiTier] = useState15("Free");
16365
+ const [quotas, setQuotas] = useState15({ limitMode: "Daily", agentLimit: 99999999, tokenLimit: 99999999999999, backgroundLimit: 999999, searchLimit: 100, customModelId: "", customLimit: 0, providerBudgets: {} });
16366
+ const [inputConfig, setInputConfig] = useState15(null);
16367
+ const [budgetReturnView, setBudgetReturnView] = useState15("chat");
16368
+ const [providerBudgetQueue, setProviderBudgetQueue] = useState15([]);
16369
+ const [providerBudgetCursor, setProviderBudgetCursor] = useState15(0);
16370
+ const [pbsCursor, setPbsCursor] = useState15(0);
16371
+ const [pbsSelected, setPbsSelected] = useState15({});
16372
+ const [systemSettings, setSystemSettings] = useState15({ memory: true, compression: 0, autoExec: false, autoDeleteHistory: "7d", autoUpdate: false, updateManager: "npm", customUpdateCommand: "" });
16373
+ const [profileData, setProfileData] = useState15({ name: null, nickname: null, instructions: null });
16374
+ const [imageSettings, setImageSettings] = useState15({ keyType: "Default", quality: "Low-High", apiKey: "" });
16375
+ const [sessionStats, setSessionStats] = useState15({ tokens: 0 });
16376
+ const [lastChunkTime, setLastChunkTime] = useState15(0);
16377
+ const [sessionAgentCalls, setSessionAgentCalls] = useState15(0);
16378
+ const [sessionBackgroundCalls, setSessionBackgroundCalls] = useState15(0);
16379
+ const [sessionTotalTokens, setSessionTotalTokens] = useState15(0);
16380
+ const [chatTokens, setChatTokens] = useState15(0);
16275
16381
  const chatTokenStartRef = useRef4(0);
16276
- const [sessionTotalCachedTokens, setSessionTotalCachedTokens] = useState14(0);
16277
- const [sessionTotalCandidateTokens, setSessionTotalCandidateTokens] = useState14(0);
16278
- const [sessionToolSuccess, setSessionToolSuccess] = useState14(0);
16279
- const [sessionToolFailure, setSessionToolFailure] = useState14(0);
16280
- const [sessionToolDenied, setSessionToolDenied] = useState14(0);
16281
- const [sessionApiTime, setSessionApiTime] = useState14(0);
16282
- const [sessionToolTime, setSessionToolTime] = useState14(0);
16283
- const [sessionImageCount, setSessionImageCount] = useState14(0);
16284
- const [sessionImageCredits, setSessionImageCredits] = useState14(0);
16285
- const [dailyUsage, setDailyUsage] = useState14(null);
16286
- const [monthlyUsage, setMonthlyUsage] = useState14(null);
16287
- const [customPeriodUsage, setCustomPeriodUsage] = useState14(null);
16288
- const [statsMode, setStatsMode] = useState14("daily");
16382
+ const [sessionTotalCachedTokens, setSessionTotalCachedTokens] = useState15(0);
16383
+ const [sessionTotalCandidateTokens, setSessionTotalCandidateTokens] = useState15(0);
16384
+ const [sessionToolSuccess, setSessionToolSuccess] = useState15(0);
16385
+ const [sessionToolFailure, setSessionToolFailure] = useState15(0);
16386
+ const [sessionToolDenied, setSessionToolDenied] = useState15(0);
16387
+ const [sessionApiTime, setSessionApiTime] = useState15(0);
16388
+ const [sessionToolTime, setSessionToolTime] = useState15(0);
16389
+ const [sessionImageCount, setSessionImageCount] = useState15(0);
16390
+ const [sessionImageCredits, setSessionImageCredits] = useState15(0);
16391
+ const [dailyUsage, setDailyUsage] = useState15(null);
16392
+ const [monthlyUsage, setMonthlyUsage] = useState15(null);
16393
+ const [customPeriodUsage, setCustomPeriodUsage] = useState15(null);
16394
+ const [statsMode, setStatsMode] = useState15("daily");
16289
16395
  const PLAYGROUND_CHAT_ID = "flow-playground";
16290
- const [chatId, setChatId] = useState14(args.includes("--playground") ? PLAYGROUND_CHAT_ID : generateChatId());
16291
- useEffect11(() => {
16396
+ const [chatId, setChatId] = useState15(args.includes("--playground") ? PLAYGROUND_CHAT_ID : generateChatId());
16397
+ useEffect12(() => {
16292
16398
  if (chatLoadingRef.current) return;
16293
16399
  const nextTokens = sessionTotalTokens - chatTokenStartRef.current;
16294
16400
  setChatTokens(nextTokens);
@@ -16297,7 +16403,7 @@ function App({ args = [] }) {
16297
16403
  });
16298
16404
  }
16299
16405
  }, [sessionTotalTokens, chatId, sessionStats.tokens]);
16300
- useEffect11(() => {
16406
+ useEffect12(() => {
16301
16407
  if (activeView === "apiTier") {
16302
16408
  const load = async () => {
16303
16409
  const d = await getDailyUsage();
@@ -16310,18 +16416,18 @@ function App({ args = [] }) {
16310
16416
  load();
16311
16417
  }
16312
16418
  }, [activeView, quotas.resetDay]);
16313
- const [activeCommand, setActiveCommand] = useState14(null);
16314
- const [execOutput, setExecOutput] = useState14("");
16315
- const [isTerminalFocused, setIsTerminalFocused] = useState14(false);
16316
- const [activeSubagents, setActiveSubagents] = useState14([]);
16317
- const [tick, setTick] = useState14(0);
16419
+ const [activeCommand, setActiveCommand] = useState15(null);
16420
+ const [execOutput, setExecOutput] = useState15("");
16421
+ const [isTerminalFocused, setIsTerminalFocused] = useState15(false);
16422
+ const [activeSubagents, setActiveSubagents] = useState15([]);
16423
+ const [tick, setTick] = useState15(0);
16318
16424
  const isFirstRender = useRef4(true);
16319
16425
  const isSecondRender = useRef4(true);
16320
16426
  const isThirdRender = useRef4(true);
16321
16427
  const prevProviderRef = useRef4(aiProvider);
16322
16428
  const originalAllowExternalAccessRef = useRef4(false);
16323
16429
  const originalMemoryRef = useRef4(true);
16324
- useEffect11(() => {
16430
+ useEffect12(() => {
16325
16431
  if (prevProviderRef.current !== aiProvider) {
16326
16432
  prevProviderRef.current = aiProvider;
16327
16433
  const hasStandard = aiProvider === "DeepSeek" || aiProvider === "NVIDIA";
@@ -16334,7 +16440,7 @@ function App({ args = [] }) {
16334
16440
  }
16335
16441
  }
16336
16442
  }, [aiProvider, activeModel, thinkingLevel]);
16337
- useEffect11(() => {
16443
+ useEffect12(() => {
16338
16444
  if (!apiKey) return;
16339
16445
  if (isFirstRender.current) {
16340
16446
  isFirstRender.current = false;
@@ -16408,15 +16514,15 @@ function App({ args = [] }) {
16408
16514
  }, []);
16409
16515
  const activeCommandRef = useRef4(null);
16410
16516
  const execOutputRef = useRef4("");
16411
- useEffect11(() => {
16517
+ useEffect12(() => {
16412
16518
  activeCommandRef.current = activeCommand;
16413
16519
  }, [activeCommand]);
16414
- useEffect11(() => {
16520
+ useEffect12(() => {
16415
16521
  execOutputRef.current = execOutput;
16416
16522
  }, [execOutput]);
16417
- const [autoAcceptWrites, setAutoAcceptWrites] = useState14(false);
16418
- const [pendingApproval, setPendingApproval] = useState14(null);
16419
- const [pendingAsk, setPendingAsk] = useState14(null);
16523
+ const [autoAcceptWrites, setAutoAcceptWrites] = useState15(false);
16524
+ const [pendingApproval, setPendingApproval] = useState15(null);
16525
+ const [pendingAsk, setPendingAsk] = useState15(null);
16420
16526
  const resetPendingApproval = (decision) => {
16421
16527
  setPendingApproval(null);
16422
16528
  setActiveView("chat");
@@ -16435,14 +16541,14 @@ function App({ args = [] }) {
16435
16541
  if (ms < 1e3) return `${ms}ms`;
16436
16542
  return formatDuration(Math.floor(ms / 1e3));
16437
16543
  };
16438
- const [statusText, setStatusText] = useState14(null);
16439
- const [wittyPhrase, setWittyPhrase] = useState14("");
16440
- const [hasPasteBlock, setHasPasteBlock] = useState14(false);
16441
- const [activeTime, setActiveTime] = useState14(0);
16544
+ const [statusText, setStatusText] = useState15(null);
16545
+ const [wittyPhrase, setWittyPhrase] = useState15("");
16546
+ const [hasPasteBlock, setHasPasteBlock] = useState15(false);
16547
+ const [activeTime, setActiveTime] = useState15(0);
16442
16548
  let interval_for_timer;
16443
- useEffect11(() => {
16549
+ useEffect12(() => {
16444
16550
  let interval;
16445
- if (statusText) {
16551
+ if (statusText && systemSettings.loadingPhrases !== false) {
16446
16552
  const updatePhrase = () => {
16447
16553
  const randomPhrase = WITTY_LOADING_PHRASES[Math.floor(Math.random() * WITTY_LOADING_PHRASES.length)];
16448
16554
  setWittyPhrase(randomPhrase);
@@ -16455,17 +16561,17 @@ function App({ args = [] }) {
16455
16561
  return () => {
16456
16562
  clearInterval(interval);
16457
16563
  };
16458
- }, [statusText]);
16459
- const [isSpinnerActive, setIsSpinnerActive] = useState14(true);
16460
- const [isProcessing, setIsProcessing] = useState14(false);
16461
- const [isCompressing, setIsCompressing] = useState14(false);
16462
- const [escPressed, setEscPressed] = useState14(false);
16463
- const [escTimer, setEscTimer] = useState14(null);
16464
- const [escPressCount, setEscPressCount] = useState14(0);
16465
- const [recentPrompts, setRecentPrompts] = useState14([]);
16564
+ }, [statusText, systemSettings]);
16565
+ const [isSpinnerActive, setIsSpinnerActive] = useState15(true);
16566
+ const [isProcessing, setIsProcessing] = useState15(false);
16567
+ const [isCompressing, setIsCompressing] = useState15(false);
16568
+ const [escPressed, setEscPressed] = useState15(false);
16569
+ const [escTimer, setEscTimer] = useState15(null);
16570
+ const [escPressCount, setEscPressCount] = useState15(0);
16571
+ const [recentPrompts, setRecentPrompts] = useState15([]);
16466
16572
  const escDoubleTimerRef = useRef4(null);
16467
16573
  const chatLoadingRef = useRef4(false);
16468
- useEffect11(() => {
16574
+ useEffect12(() => {
16469
16575
  return () => {
16470
16576
  if (escDoubleTimerRef.current) {
16471
16577
  clearTimeout(escDoubleTimerRef.current);
@@ -16473,11 +16579,11 @@ function App({ args = [] }) {
16473
16579
  };
16474
16580
  }, []);
16475
16581
  const didSignalTerminationRef = useRef4(false);
16476
- const [queuedPrompt, setQueuedPrompt] = useState14(null);
16477
- const [resolutionData, setResolutionData] = useState14(null);
16478
- const [tempModelOverride, setTempModelOverride] = useState14(null);
16479
- useEffect11(() => setEscPressCount(0), [input]);
16480
- const [messages, rawSetMessages] = useState14(() => {
16582
+ const [queuedPrompt, setQueuedPrompt] = useState15(null);
16583
+ const [resolutionData, setResolutionData] = useState15(null);
16584
+ const [tempModelOverride, setTempModelOverride] = useState15(null);
16585
+ useEffect12(() => setEscPressCount(0), [input]);
16586
+ const [messages, rawSetMessages] = useState15(() => {
16481
16587
  const logoMsg = { id: "logo-" + Date.now(), role: "system", isLogo: true, isMeta: true };
16482
16588
  const isHomeDir = process.cwd() === os5.homedir();
16483
16589
  const isSystemDir = (() => {
@@ -16526,11 +16632,11 @@ function App({ args = [] }) {
16526
16632
  });
16527
16633
  };
16528
16634
  const queuedPromptRef = useRef4(null);
16529
- const [btwResponse, setBtwResponse] = useState14("");
16530
- const [showBtwBox, setShowBtwBox] = useState14(false);
16635
+ const [btwResponse, setBtwResponse] = useState15("");
16636
+ const [showBtwBox, setShowBtwBox] = useState15(false);
16531
16637
  const btwResponseRef = useRef4("");
16532
16638
  const btwClosedRef = useRef4(null);
16533
- useEffect11(() => {
16639
+ useEffect12(() => {
16534
16640
  if (messages.length === 0) return;
16535
16641
  const lastMsg = messages[messages.length - 1];
16536
16642
  if (lastMsg && (lastMsg.role === "agent" || lastMsg.role === "assistant")) {
@@ -16548,8 +16654,8 @@ function App({ args = [] }) {
16548
16654
  }
16549
16655
  }
16550
16656
  }, [messages]);
16551
- const [completedIndex, setCompletedIndex] = useState14(messages.length);
16552
- const [clearKey, setClearKey] = useState14(0);
16657
+ const [completedIndex, setCompletedIndex] = useState15(messages.length);
16658
+ const [clearKey, setClearKey] = useState15(0);
16553
16659
  const lastCompletedBlocksRef = useRef4([]);
16554
16660
  const cachedHistoryRef = useRef4({
16555
16661
  completedIndex: 0,
@@ -16886,7 +16992,7 @@ function App({ args = [] }) {
16886
16992
  setInput((prev) => prev.replace(/\\\r?$/, "").replace(/\r?$/, "") + "\n");
16887
16993
  }
16888
16994
  });
16889
- useEffect11(() => {
16995
+ useEffect12(() => {
16890
16996
  process.stdout.write("\x1B[?1004h");
16891
16997
  const onData = (data) => {
16892
16998
  const str = data.toString();
@@ -16904,7 +17010,7 @@ function App({ args = [] }) {
16904
17010
  process.stdin.off("data", onData);
16905
17011
  };
16906
17012
  }, []);
16907
- useEffect11(() => {
17013
+ useEffect12(() => {
16908
17014
  async function init() {
16909
17015
  try {
16910
17016
  const pkg = JSON.parse(fs24.readFileSync(path22.join(process.cwd(), "package.json"), "utf8"));
@@ -17126,7 +17232,7 @@ function App({ args = [] }) {
17126
17232
  }
17127
17233
  init();
17128
17234
  }, []);
17129
- useEffect11(() => {
17235
+ useEffect12(() => {
17130
17236
  let timer;
17131
17237
  if (confirmExit) {
17132
17238
  setExitCountdown(10);
@@ -17144,7 +17250,7 @@ function App({ args = [] }) {
17144
17250
  if (timer) clearInterval(timer);
17145
17251
  };
17146
17252
  }, [confirmExit]);
17147
- useEffect11(() => {
17253
+ useEffect12(() => {
17148
17254
  if (!isInitializing) {
17149
17255
  const modelToSave = parsedArgs.model && activeModel === parsedArgs.model ? persistedModelRef.current : activeModel;
17150
17256
  let settingsToSave = systemSettings;
@@ -17194,7 +17300,7 @@ function App({ args = [] }) {
17194
17300
  }
17195
17301
  };
17196
17302
  const lastSavedTimeRef = useRef4(SESSION_START_TIME);
17197
- useEffect11(() => {
17303
+ useEffect12(() => {
17198
17304
  if (activeView === "exit") {
17199
17305
  const flush = async () => {
17200
17306
  const now = Date.now();
@@ -17212,7 +17318,7 @@ function App({ args = [] }) {
17212
17318
  return () => clearTimeout(timer);
17213
17319
  }
17214
17320
  }, [activeView]);
17215
- useEffect11(() => {
17321
+ useEffect12(() => {
17216
17322
  const interval = setInterval(async () => {
17217
17323
  if (!isInitializing) {
17218
17324
  const now = Date.now();
@@ -18559,6 +18665,7 @@ ${timestamp}` };
18559
18665
  id: "ask-" + Date.now(),
18560
18666
  role: "system",
18561
18667
  text: `\u{1F4AC} **Ask User**
18668
+ Question: ${question}
18562
18669
  Selection: ${val}`,
18563
18670
  isAskRecord: true
18564
18671
  }
@@ -18638,7 +18745,9 @@ Selection: ${val}`,
18638
18745
  isFirstPacket = false;
18639
18746
  }
18640
18747
  if (packet.type === "status") {
18641
- setStatusText(packet.content);
18748
+ if (!packet.content?.includes("[start]")) {
18749
+ setStatusText(packet.content);
18750
+ }
18642
18751
  if (packet.content?.includes("[start]")) {
18643
18752
  clearInterval(interval_for_timer);
18644
18753
  setActiveTime(0);
@@ -19089,10 +19198,10 @@ Selection: ${val}`,
19089
19198
  }
19090
19199
  return [];
19091
19200
  }, [input, isFilePickerDismissed]);
19092
- useEffect11(() => {
19201
+ useEffect12(() => {
19093
19202
  setSelectedIndex(0);
19094
19203
  }, [suggestions]);
19095
- useEffect11(() => {
19204
+ useEffect12(() => {
19096
19205
  if (activeView !== "providerBudgetSelect") return;
19097
19206
  const PBS_PROVIDERS = ["Google", "DeepSeek", "NVIDIA", "OpenRouter"];
19098
19207
  const existingBudgets = quotas.providerBudgets || {};
@@ -19103,7 +19212,7 @@ Selection: ${val}`,
19103
19212
  setPbsSelected(initialSelected);
19104
19213
  setPbsCursor(0);
19105
19214
  }, [activeView]);
19106
- useEffect11(() => {
19215
+ useEffect12(() => {
19107
19216
  if (activeView !== "providerBudgetFlow") return;
19108
19217
  const currentProvider = providerBudgetQueue[providerBudgetCursor];
19109
19218
  if (!currentProvider) {
@@ -19175,7 +19284,7 @@ Selection: ${val}`,
19175
19284
  }, [activeView, providerBudgetCursor]);
19176
19285
  const CustomMenuItem = ({ label, isSelected }) => {
19177
19286
  const isCancel = label === "Cancel" || label === "Back" || label.toLowerCase().includes("exit") || label.toLowerCase().includes("back");
19178
- return /* @__PURE__ */ React15.createElement(
19287
+ return /* @__PURE__ */ React16.createElement(
19179
19288
  Box14,
19180
19289
  {
19181
19290
  marginTop: isCancel ? 1 : 0,
@@ -19183,7 +19292,7 @@ Selection: ${val}`,
19183
19292
  paddingX: 1,
19184
19293
  width: "100%"
19185
19294
  },
19186
- /* @__PURE__ */ React15.createElement(Text15, { color: isSelected ? "white" : "gray", bold: isSelected }, isSelected ? "\u276F " : " ", label)
19295
+ /* @__PURE__ */ React16.createElement(Text16, { color: isSelected ? "white" : "gray", bold: isSelected }, isSelected ? "\u276F " : " ", label)
19187
19296
  );
19188
19297
  };
19189
19298
  const renderProgressBar = (label, current, limit) => {
@@ -19200,12 +19309,12 @@ Selection: ${val}`,
19200
19309
  const isTokens = label.toLowerCase().includes("token");
19201
19310
  const displayLimit = shouldClearValue(limit) ? "\u221E" : isTokens ? formatTokens(limit) : limit;
19202
19311
  const displayCurrent = isTokens ? formatTokens(current) : current;
19203
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "row", paddingLeft: 4, key: label }, /* @__PURE__ */ React15.createElement(Box14, { width: 18 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, label, ": ")), /* @__PURE__ */ React15.createElement(Text15, { color: barColor }, barStr), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " ", percent, "% (", displayCurrent, "/", displayLimit, ")"));
19312
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "row", paddingLeft: 4, key: label }, /* @__PURE__ */ React16.createElement(Box14, { width: 18 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, label, ": ")), /* @__PURE__ */ React16.createElement(Text16, { color: barColor }, barStr), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " ", percent, "% (", displayCurrent, "/", displayLimit, ")"));
19204
19313
  };
19205
19314
  const renderActiveView = () => {
19206
19315
  switch (activeView) {
19207
19316
  case "settings":
19208
- return /* @__PURE__ */ React15.createElement(
19317
+ return /* @__PURE__ */ React16.createElement(
19209
19318
  SettingsMenu,
19210
19319
  {
19211
19320
  systemSettings,
@@ -19220,7 +19329,7 @@ Selection: ${val}`,
19220
19329
  }
19221
19330
  );
19222
19331
  case "selectProvider":
19223
- return /* @__PURE__ */ React15.createElement(
19332
+ return /* @__PURE__ */ React16.createElement(
19224
19333
  CommandMenu,
19225
19334
  {
19226
19335
  title: "SELECT AI PROVIDER",
@@ -19278,7 +19387,7 @@ Selection: ${val}`,
19278
19387
  }
19279
19388
  );
19280
19389
  case "apiTier": {
19281
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "SELECT API MODE FOR ", aiProvider.toUpperCase())), /* @__PURE__ */ React15.createElement(
19390
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "SELECT API MODE FOR ", aiProvider.toUpperCase())), /* @__PURE__ */ React16.createElement(
19282
19391
  SelectInput2,
19283
19392
  {
19284
19393
  items: [
@@ -19308,10 +19417,10 @@ Selection: ${val}`,
19308
19417
  itemComponent: CustomMenuItem,
19309
19418
  indicatorComponent: () => null
19310
19419
  }
19311
- ), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, "(Arrows to select \u2022 Enter to confirm)")));
19420
+ ), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, "(Arrows to select \u2022 Enter to confirm)")));
19312
19421
  }
19313
19422
  case "resetMode":
19314
- return /* @__PURE__ */ React15.createElement(
19423
+ return /* @__PURE__ */ React16.createElement(
19315
19424
  CommandMenu,
19316
19425
  {
19317
19426
  title: "SELECT MONTHLY RESET MODE",
@@ -19346,7 +19455,7 @@ Selection: ${val}`,
19346
19455
  }
19347
19456
  );
19348
19457
  case "budgetTypeSelect":
19349
- return /* @__PURE__ */ React15.createElement(
19458
+ return /* @__PURE__ */ React16.createElement(
19350
19459
  CommandMenu,
19351
19460
  {
19352
19461
  title: "SELECT BUDGET TYPE",
@@ -19413,16 +19522,16 @@ Selection: ${val}`,
19413
19522
  case "providerBudgetSelect": {
19414
19523
  const PROVIDERS_LIST = ["Google", "DeepSeek", "NVIDIA", "OpenRouter"];
19415
19524
  const anySelected = PROVIDERS_LIST.some((p) => pbsSelected[p]);
19416
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", bold: true }, "SELECT PROVIDERS TO SET BUDGETS FOR")), PROVIDERS_LIST.map((prov, i) => {
19525
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", bold: true }, "SELECT PROVIDERS TO SET BUDGETS FOR")), PROVIDERS_LIST.map((prov, i) => {
19417
19526
  const isActive = i === pbsCursor;
19418
19527
  const isChecked = !!pbsSelected[prov];
19419
- return /* @__PURE__ */ React15.createElement(Box14, { key: prov, backgroundColor: isActive ? "#2a2a2a" : void 0, paddingX: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: isActive ? "white" : "gray", bold: isActive }, isActive ? "\u276F " : " ", /* @__PURE__ */ React15.createElement(Text15, { color: isChecked ? "green" : "gray" }, isChecked ? "\u2611" : "\u2610"), " ", prov, isChecked && quotas.providerBudgets?.[prov]?.agentLimit ? /* @__PURE__ */ React15.createElement(Text15, { color: "cyan" }, " (budget set)") : null));
19420
- }), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, "\u2191\u2193 Navigate \u2022 Space to toggle \u2022 Enter to confirm \u2022 ESC to go back"), !anySelected && /* @__PURE__ */ React15.createElement(Text15, { color: "yellow", italic: true }, " Select at least one provider to continue")));
19528
+ return /* @__PURE__ */ React16.createElement(Box14, { key: prov, backgroundColor: isActive ? "#2a2a2a" : void 0, paddingX: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: isActive ? "white" : "gray", bold: isActive }, isActive ? "\u276F " : " ", /* @__PURE__ */ React16.createElement(Text16, { color: isChecked ? "green" : "gray" }, isChecked ? "\u2611" : "\u2610"), " ", prov, isChecked && quotas.providerBudgets?.[prov]?.agentLimit ? /* @__PURE__ */ React16.createElement(Text16, { color: "cyan" }, " (budget set)") : null));
19529
+ }), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, "\u2191\u2193 Navigate \u2022 Space to toggle \u2022 Enter to confirm \u2022 ESC to go back"), !anySelected && /* @__PURE__ */ React16.createElement(Text16, { color: "yellow", italic: true }, " Select at least one provider to continue")));
19421
19530
  }
19422
19531
  case "providerBudgetFlow":
19423
19532
  return null;
19424
19533
  case "budgetResetMode":
19425
- return /* @__PURE__ */ React15.createElement(
19534
+ return /* @__PURE__ */ React16.createElement(
19426
19535
  CommandMenu,
19427
19536
  {
19428
19537
  title: "SELECT MONTHLY RESET MODE",
@@ -19482,7 +19591,7 @@ Selection: ${val}`,
19482
19591
  const monthName = resetDate.toLocaleString("default", { month: "short" });
19483
19592
  resetInfo = `Resets on: ${resetDay}-${monthName}`;
19484
19593
  }
19485
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { marginBottom: 1, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "BUDGET LIMIT STATUS"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "[ ESC to Close ]")), limitsNotSet ? /* @__PURE__ */ React15.createElement(Box14, { padding: 1, justifyContent: "center", alignItems: "center", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "LIMITS NOT SET")) : usingProviderBudgets && configuredProviders.length > 0 ? /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", gap: 1, width: "100%" }, configuredProviders.map((prov) => {
19594
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { marginBottom: 1, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "BUDGET LIMIT STATUS"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "[ ESC to Close ]")), limitsNotSet ? /* @__PURE__ */ React16.createElement(Box14, { padding: 1, justifyContent: "center", alignItems: "center", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "LIMITS NOT SET")) : usingProviderBudgets && configuredProviders.length > 0 ? /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", gap: 1, width: "100%" }, configuredProviders.map((prov) => {
19486
19595
  const pb = providerBudgetsMap[prov];
19487
19596
  const provReqCurrent = dailyUsage?.providerRequests?.[prov] || 0;
19488
19597
  let provTokenCurrent = 0;
@@ -19496,11 +19605,11 @@ Selection: ${val}`,
19496
19605
  for (const m in monthlyModels) {
19497
19606
  provMonthlyCurrent += monthlyModels[m]?.tokens || 0;
19498
19607
  }
19499
- return /* @__PURE__ */ React15.createElement(Box14, { key: prov, flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { marginBottom: 0 }, /* @__PURE__ */ React15.createElement(Text15, { color: "cyan", bold: true }, "\u25C6 ", prov)), renderProgressBar("Daily Requests", provReqCurrent, pb.agentLimit || 99999999, "cyan"), renderProgressBar("Daily Tokens", provTokenCurrent, pb.tokenLimit || 99999999999999, "green"), renderProgressBar("Monthly Tokens", provMonthlyCurrent, pb.monthlyTokenLimit || 99999999999999, "yellow"));
19500
- }), resetInfo ? /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React15.createElement(Text15, { color: "magenta", bold: true }, resetInfo)) : /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React15.createElement(Text15, { color: "blue", bold: true }, "Rolling 30-Day Window"))) : /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, width: "100%" }, renderProgressBar("Daily Requests", reqCurrent, reqLimit, "cyan"), renderProgressBar("Daily Tokens", tokenCurrent, tokenLimit, "green"), renderProgressBar("Monthly Tokens", monthlyCurrent, monthlyLimit, "yellow"), resetInfo ? /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React15.createElement(Text15, { color: "magenta", bold: true }, resetInfo)) : /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React15.createElement(Text15, { color: "blue", bold: true }, "Rolling 30-Day Window"))));
19608
+ return /* @__PURE__ */ React16.createElement(Box14, { key: prov, flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { marginBottom: 0 }, /* @__PURE__ */ React16.createElement(Text16, { color: "cyan", bold: true }, "\u25C6 ", prov)), renderProgressBar("Daily Requests", provReqCurrent, pb.agentLimit || 99999999, "cyan"), renderProgressBar("Daily Tokens", provTokenCurrent, pb.tokenLimit || 99999999999999, "green"), renderProgressBar("Monthly Tokens", provMonthlyCurrent, pb.monthlyTokenLimit || 99999999999999, "yellow"));
19609
+ }), resetInfo ? /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React16.createElement(Text16, { color: "magenta", bold: true }, resetInfo)) : /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React16.createElement(Text16, { color: "blue", bold: true }, "Rolling 30-Day Window"))) : /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, width: "100%" }, renderProgressBar("Daily Requests", reqCurrent, reqLimit, "cyan"), renderProgressBar("Daily Tokens", tokenCurrent, tokenLimit, "green"), renderProgressBar("Monthly Tokens", monthlyCurrent, monthlyLimit, "yellow"), resetInfo ? /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React16.createElement(Text16, { color: "magenta", bold: true }, resetInfo)) : /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "Monthly Reset : "), /* @__PURE__ */ React16.createElement(Text16, { color: "blue", bold: true }, "Rolling 30-Day Window"))));
19501
19610
  }
19502
19611
  case "input":
19503
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "DATA CONFIGURATION")), inputConfig?.note && /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, inputConfig.note)), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, flexDirection: "row" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, inputConfig?.label, " "), /* @__PURE__ */ React15.createElement(
19612
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", padding: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "DATA CONFIGURATION")), inputConfig?.note && /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, inputConfig.note)), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, flexDirection: "row" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, inputConfig?.label, " "), /* @__PURE__ */ React16.createElement(
19504
19613
  TextInput4,
19505
19614
  {
19506
19615
  value: inputConfig?.value || "",
@@ -19603,7 +19712,7 @@ Selection: ${val}`,
19603
19712
  }
19604
19713
  }
19605
19714
  }
19606
- )), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true, italic: true }, "(Press Enter to confirm selection)")));
19715
+ )), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true, italic: true }, "(Press Enter to confirm selection)")));
19607
19716
  case "stats": {
19608
19717
  const u = statsMode === "monthly" ? monthlyUsage : dailyUsage;
19609
19718
  const trackerTitle = statsMode === "monthly" ? "LAST 30 DAYS USAGE" : "TODAY's USAGE";
@@ -19613,13 +19722,13 @@ Selection: ${val}`,
19613
19722
  const imageCreditsLabel = statsMode === "monthly" ? "Image Credits:" : "Image Credits:";
19614
19723
  const codeChangesLabel = statsMode === "monthly" ? "Code Changes:" : "Code Changes:";
19615
19724
  const toolCallsLabel = statsMode === "monthly" ? "Tool Calls:" : "Tool Calls:";
19616
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 3, paddingY: 1, paddingBottom: 0, width: Math.min(125, (stdout?.columns || 100) - 2) }, statsMode === "modelBreakdown" ? /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "30-DAY MODEL TOKEN BREAKDOWN"), !monthlyUsage?.models || Object.keys(monthlyUsage.models).length === 0 ? /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey", italic: true }, "No model token usage recorded in the last 30 days.")) : Object.entries(monthlyUsage.models).map(([provider, models]) => {
19725
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 3, paddingY: 1, paddingBottom: 0, width: Math.min(125, (stdout?.columns || 100) - 2) }, statsMode === "modelBreakdown" ? /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "30-DAY MODEL TOKEN BREAKDOWN"), !monthlyUsage?.models || Object.keys(monthlyUsage.models).length === 0 ? /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey", italic: true }, "No model token usage recorded in the last 30 days.")) : Object.entries(monthlyUsage.models).map(([provider, models]) => {
19617
19726
  const providerTotalTokens = Object.values(models).reduce((sum, m) => sum + (m.tokens || 0), 0);
19618
- return /* @__PURE__ */ React15.createElement(Box14, { key: provider, flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 40 }, /* @__PURE__ */ React15.createElement(Text15, { color: "cyan", bold: true }, provider, ":")), /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, formatTokens(providerTotalTokens))), Object.entries(models).map(([modelName, stats]) => /* @__PURE__ */ React15.createElement(Box14, { key: modelName, flexDirection: "column", marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 36 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "\xBB ", modelName, ":")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(stats.tokens || 0))), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Box14, { width: 32 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens((stats.tokens || 0) - (stats.candidateTokens || 0)))), (stats.cachedTokens || 0) > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 5 }, /* @__PURE__ */ React15.createElement(Box14, { width: 31 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(stats.cachedTokens))), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Box14, { width: 32 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(stats.candidateTokens || 0))))));
19619
- })) : /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, { marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "SESSION TELEMETRY")), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Session Duration:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(Date.now() - SESSION_START_TIME))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Model Requests:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, sessionAgentCalls)), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB API Time:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(sessionApiTime))), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Tool Time:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(sessionToolTime))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Memory Agent:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, sessionBackgroundCalls)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Tokens Consumed:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalTokens))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Active Context:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionStats.tokens))), sessionTotalTokens > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalTokens - sessionTotalCandidateTokens))), sessionTotalCachedTokens > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Box14, { width: 21 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalCachedTokens))), sessionTotalCandidateTokens > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalCandidateTokens)))), sessionImageCount > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Images Made:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, sessionImageCount)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Image Credits:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, Number(((sessionImageCredits || 0) * 1e3).toFixed(0)), " credits"))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Code Changes (Sess):")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "+", runtimeSession.linesAdded), " ", /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "-", runtimeSession.linesRemoved))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Tool Calls (Sess):")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, runtimeSession.toolSuccess + runtimeSession.toolFailure + runtimeSession.toolDenied, " ( "), /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "\u2714 ", runtimeSession.toolSuccess), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " "), /* @__PURE__ */ React15.createElement(Text15, { color: "yellow" }, "\u{1F6C7} ", runtimeSession.toolDenied), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " "), /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "\u2718 ", runtimeSession.toolFailure), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " )"))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, trackerTitle), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, timeLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatDuration(u?.duration || 0))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Model Requests:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, u?.agent || 0)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Memory Agent:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, u?.background || 0)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, tokensLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(u?.tokens || 0))), (u?.tokens || 0) > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens((u?.tokens || 0) - (u?.candidateTokens || 0)))), (u?.cachedTokens || 0) > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Box14, { width: 21 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(u.cachedTokens))), (u?.candidateTokens || 0) > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 23 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(u.candidateTokens)))), (u?.imageCalls?.length || 0) > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, imagesLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, u.imageCalls.length)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, imageCreditsLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, Number(((u.imageCalls.reduce((sum, c) => sum + c.cost, 0) || 0) * 1e3).toFixed(0)), " credits"))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, codeChangesLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "+", u?.linesAdded || 0), " ", /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "-", u?.linesRemoved || 0))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 25 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, toolCallsLabel)), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, (u?.toolSuccess || 0) + (u?.toolFailure || 0) + (u?.toolDenied || 0), " ( "), /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "\u2714 ", u?.toolSuccess || 0), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " "), /* @__PURE__ */ React15.createElement(Text15, { color: "yellow" }, "\u{1F6C7} ", u?.toolDenied || 0), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " "), /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "\u2718 ", u?.toolFailure || 0), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " )")))), /* @__PURE__ */ React15.createElement(Text15, { dimColor: true, marginTop: 1, italic: true }, "(Press TAB to toggle Daily/Monthly views, SPACE for Model Breakdown, ESC to return)"));
19727
+ return /* @__PURE__ */ React16.createElement(Box14, { key: provider, flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 40 }, /* @__PURE__ */ React16.createElement(Text16, { color: "cyan", bold: true }, provider, ":")), /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, formatTokens(providerTotalTokens))), Object.entries(models).map(([modelName, stats]) => /* @__PURE__ */ React16.createElement(Box14, { key: modelName, flexDirection: "column", marginLeft: 4, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 36 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "\xBB ", modelName, ":")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(stats.tokens || 0))), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Box14, { width: 32 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens((stats.tokens || 0) - (stats.candidateTokens || 0)))), (stats.cachedTokens || 0) > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 5 }, /* @__PURE__ */ React16.createElement(Box14, { width: 31 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(stats.cachedTokens))), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Box14, { width: 32 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(stats.candidateTokens || 0))))));
19728
+ })) : /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, { marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "SESSION TELEMETRY")), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Session Duration:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(Date.now() - SESSION_START_TIME))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Model Requests:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, sessionAgentCalls)), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB API Time:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(sessionApiTime))), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Tool Time:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(sessionToolTime))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Memory Agent:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, sessionBackgroundCalls)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Tokens Consumed:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalTokens))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Active Context:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionStats.tokens))), sessionTotalTokens > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalTokens - sessionTotalCandidateTokens))), sessionTotalCachedTokens > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Box14, { width: 21 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalCachedTokens))), sessionTotalCandidateTokens > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalCandidateTokens)))), sessionImageCount > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Images Made:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, sessionImageCount)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Image Credits:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, Number(((sessionImageCredits || 0) * 1e3).toFixed(0)), " credits"))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Code Changes (Sess):")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "+", runtimeSession.linesAdded), " ", /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "-", runtimeSession.linesRemoved))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Tool Calls (Sess):")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, runtimeSession.toolSuccess + runtimeSession.toolFailure + runtimeSession.toolDenied, " ( "), /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "\u2714 ", runtimeSession.toolSuccess), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " "), /* @__PURE__ */ React16.createElement(Text16, { color: "yellow" }, "\u{1F6C7} ", runtimeSession.toolDenied), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " "), /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "\u2718 ", runtimeSession.toolFailure), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " )"))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, trackerTitle), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, timeLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatDuration(u?.duration || 0))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Model Requests:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, u?.agent || 0)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Memory Agent:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, u?.background || 0)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, tokensLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(u?.tokens || 0))), (u?.tokens || 0) > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens((u?.tokens || 0) - (u?.candidateTokens || 0)))), (u?.cachedTokens || 0) > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Box14, { width: 21 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(u.cachedTokens))), (u?.candidateTokens || 0) > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 23 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(u.candidateTokens)))), (u?.imageCalls?.length || 0) > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, imagesLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, u.imageCalls.length)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, imageCreditsLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, Number(((u.imageCalls.reduce((sum, c) => sum + c.cost, 0) || 0) * 1e3).toFixed(0)), " credits"))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, codeChangesLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "+", u?.linesAdded || 0), " ", /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "-", u?.linesRemoved || 0))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 25 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, toolCallsLabel)), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, (u?.toolSuccess || 0) + (u?.toolFailure || 0) + (u?.toolDenied || 0), " ( "), /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "\u2714 ", u?.toolSuccess || 0), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " "), /* @__PURE__ */ React16.createElement(Text16, { color: "yellow" }, "\u{1F6C7} ", u?.toolDenied || 0), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " "), /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "\u2718 ", u?.toolFailure || 0), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " )")))), /* @__PURE__ */ React16.createElement(Text16, { dimColor: true, marginTop: 1, italic: true }, "(Press TAB to toggle Daily/Monthly views, SPACE for Model Breakdown, ESC to return)"));
19620
19729
  }
19621
19730
  case "autoExecDanger":
19622
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "SECURITY WARNING: YOLO MODE"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "Turning this ON allows the agent to execute terminal commands automatically without requiring your approval for each step."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1, color: "white" }, "RISKS INVOLVED:"), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 The agent may execute destructive commands (rm -rf, etc.) by mistake unless specified in sandbox rules."), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 Unintended system changes if the agent hallucinates a path or command."), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 Reduced control over the agent's step-by-step decision making."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19731
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "SECURITY WARNING: YOLO MODE"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "Turning this ON allows the agent to execute terminal commands automatically without requiring your approval for each step."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1, color: "white" }, "RISKS INVOLVED:"), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 The agent may execute destructive commands (rm -rf, etc.) by mistake unless specified in sandbox rules."), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 Unintended system changes if the agent hallucinates a path or command."), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 Reduced control over the agent's step-by-step decision making."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19623
19732
  CommandMenu,
19624
19733
  {
19625
19734
  title: "Confirm Intent",
@@ -19636,7 +19745,7 @@ Selection: ${val}`,
19636
19745
  }
19637
19746
  )));
19638
19747
  case "advanceRollbackDanger":
19639
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, paddingTop: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "\u26A0 Emergency Rollback Notice"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "When enabled, full repo snapshots exist only during active AI turns."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "If catastrophic changes occur during a turn, avoid abruptly stopping the agent unless absolutely necessary (external damages out of codebase)."), /* @__PURE__ */ React15.createElement(Text15, null, "The agent may be able to automatically restore the repo to a safe state."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "Once the turn ends, emergency snapshots are deleted and standard /revert takes over which may not retain full repo content."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19748
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, paddingTop: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "\u26A0 Emergency Rollback Notice"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "When enabled, full repo snapshots exist only during active AI turns."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "If catastrophic changes occur during a turn, avoid abruptly stopping the agent unless absolutely necessary (external damages out of codebase)."), /* @__PURE__ */ React16.createElement(Text16, null, "The agent may be able to automatically restore the repo to a safe state."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "Once the turn ends, emergency snapshots are deleted and standard /revert takes over which may not retain full repo content."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19640
19749
  CommandMenu,
19641
19750
  {
19642
19751
  title: "Confirm",
@@ -19653,7 +19762,7 @@ Selection: ${val}`,
19653
19762
  }
19654
19763
  )));
19655
19764
  case "externalDanger":
19656
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "SECURITY WARNING: EXTERNAL WORKSPACE ACCESS"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "Turning this ON allows the agent to execute tools (Read/Write/Exec) outside of the current active workspace directory."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1, color: "white" }, "RISKS INVOLVED:"), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 Access to sensitive system files (SSH keys, Browser data, etc.)"), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 Potential for accidental or malicious deletion of OS-critical files."), /* @__PURE__ */ React15.createElement(Text15, null, "\u2022 Unauthorized script execution across your entire file system."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19765
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "SECURITY WARNING: EXTERNAL WORKSPACE ACCESS"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "Turning this ON allows the agent to execute tools (Read/Write/Exec) outside of the current active workspace directory."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1, color: "white" }, "RISKS INVOLVED:"), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 Access to sensitive system files (SSH keys, Browser data, etc.)"), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 Potential for accidental or malicious deletion of OS-critical files."), /* @__PURE__ */ React16.createElement(Text16, null, "\u2022 Unauthorized script execution across your entire file system."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19657
19766
  CommandMenu,
19658
19767
  {
19659
19768
  title: "Confirm Intent",
@@ -19670,7 +19779,7 @@ Selection: ${val}`,
19670
19779
  }
19671
19780
  )));
19672
19781
  case "doubleDanger":
19673
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "CRITICAL SECURITY WARNING: COMBINED SYSTEM RISK"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "You are attempting to enable BOTH [YOLO Mode] and [External Workspace Access] simultaneously."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1, color: "red", bold: true }, "THIS IS NOT RECOMMENDED."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1, color: "white" }, "THE CRITICAL RISK:"), /* @__PURE__ */ React15.createElement(Text15, null, "The agent will have the power to execute any command across your entire system WITHOUT your approval or supervision."), /* @__PURE__ */ React15.createElement(Text15, { color: "red", italic: true, marginTop: 1 }, "A single hallucination or error could result in full system wipe or data theft."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19782
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "CRITICAL SECURITY WARNING: COMBINED SYSTEM RISK"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "You are attempting to enable BOTH [YOLO Mode] and [External Workspace Access] simultaneously."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1, color: "red", bold: true }, "THIS IS NOT RECOMMENDED."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1, color: "white" }, "THE CRITICAL RISK:"), /* @__PURE__ */ React16.createElement(Text16, null, "The agent will have the power to execute any command across your entire system WITHOUT your approval or supervision."), /* @__PURE__ */ React16.createElement(Text16, { color: "red", italic: true, marginTop: 1 }, "A single hallucination or error could result in full system wipe or data theft."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19674
19783
  CommandMenu,
19675
19784
  {
19676
19785
  title: "Final Confirmation",
@@ -19687,7 +19796,7 @@ Selection: ${val}`,
19687
19796
  }
19688
19797
  )));
19689
19798
  case "key":
19690
- return /* @__PURE__ */ React15.createElement(
19799
+ return /* @__PURE__ */ React16.createElement(
19691
19800
  CommandMenu,
19692
19801
  {
19693
19802
  title: "API KEY MANAGEMENT",
@@ -19711,10 +19820,10 @@ Selection: ${val}`,
19711
19820
  }
19712
19821
  );
19713
19822
  case "deleteKey":
19714
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1 }, (() => {
19823
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1 }, (() => {
19715
19824
  const s = emojiSpace(2);
19716
- return /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "DANGER: CLEAR CREDENTIALS");
19717
- })(), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "This will permanently delete all saved API keys in credential cache. You will need to enter it again to use Flux."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19825
+ return /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "DANGER: CLEAR CREDENTIALS");
19826
+ })(), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "This will permanently delete all saved API keys in credential cache. You will need to enter it again to use Flux."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19718
19827
  CommandMenu,
19719
19828
  {
19720
19829
  title: "Are you sure?",
@@ -19738,7 +19847,7 @@ Selection: ${val}`,
19738
19847
  case "exit":
19739
19848
  return null;
19740
19849
  case "ask":
19741
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%" }, /* @__PURE__ */ React15.createElement(
19850
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%" }, /* @__PURE__ */ React16.createElement(
19742
19851
  AskUserModal_default,
19743
19852
  {
19744
19853
  question: pendingAsk?.question,
@@ -19753,7 +19862,7 @@ Selection: ${val}`,
19753
19862
  }
19754
19863
  ));
19755
19864
  case "revert":
19756
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(
19865
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(
19757
19866
  RevertModal,
19758
19867
  {
19759
19868
  prompts: recentPrompts,
@@ -19824,7 +19933,7 @@ Selection: ${val}`,
19824
19933
  }
19825
19934
  ));
19826
19935
  case "resume":
19827
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(
19936
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(
19828
19937
  ResumeModal,
19829
19938
  {
19830
19939
  onSelect: async (id) => {
@@ -19861,7 +19970,7 @@ Selection: ${val}`,
19861
19970
  }
19862
19971
  ));
19863
19972
  case "keybindingsPrompt":
19864
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "\u2328 CONFIGURE SHIFT+ENTER NEWLINE"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "To support multi-line inputs with ", /* @__PURE__ */ React15.createElement(Text15, { bold: true, color: "white" }, "Shift + Enter"), " for newline, a terminal sequence keybinding needs to be added to your IDE configuration."), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "Would you like FluxFlow to automatically add this to your ", getIDEName(), " keybindings?"), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
19973
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "\u2328 CONFIGURE SHIFT+ENTER NEWLINE"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "To support multi-line inputs with ", /* @__PURE__ */ React16.createElement(Text16, { bold: true, color: "white" }, "Shift + Enter"), " for newline, a terminal sequence keybinding needs to be added to your IDE configuration."), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "Would you like FluxFlow to automatically add this to your ", getIDEName(), " keybindings?"), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19865
19974
  CommandMenu,
19866
19975
  {
19867
19976
  title: "Add Keybinding?",
@@ -19880,11 +19989,11 @@ Selection: ${val}`,
19880
19989
  }
19881
19990
  )));
19882
19991
  case "memory":
19883
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(MemoryModal, { onClose: () => setActiveView("chat") }));
19992
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(MemoryModal, { onClose: () => setActiveView("chat") }));
19884
19993
  case "parserDownload":
19885
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(ParserDownloadModal, { onClose: () => setActiveView("settings") }));
19994
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(ParserDownloadModal, { onClose: () => setActiveView("settings") }));
19886
19995
  case "profile":
19887
- return /* @__PURE__ */ React15.createElement(
19996
+ return /* @__PURE__ */ React16.createElement(
19888
19997
  ProfileForm,
19889
19998
  {
19890
19999
  initialData: profileData,
@@ -19897,7 +20006,7 @@ Selection: ${val}`,
19897
20006
  }
19898
20007
  );
19899
20008
  case "resolution":
19900
- return /* @__PURE__ */ React15.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(
20009
+ return /* @__PURE__ */ React16.createElement(Box14, { width: "100%", alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(
19901
20010
  ResolutionModal,
19902
20011
  {
19903
20012
  data: resolutionData,
@@ -19916,7 +20025,7 @@ Selection: ${val}`,
19916
20025
  }
19917
20026
  ));
19918
20027
  case "approval":
19919
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "FILE WRITE PERMISSION"), /* @__PURE__ */ React15.createElement(Text15, { marginTop: 1 }, "The agent is attempting to modify: ", /* @__PURE__ */ React15.createElement(Text15, { color: "cyan" }, parseArgs(pendingApproval?.args || "{}").path || "Unknown File")), !isBridgeConnected() ? /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1, borderStyle: "single", borderColor: "#333", paddingX: 1, flexDirection: "column" }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "--- PROPOSED CONTENT ---"), (() => {
20028
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "FILE WRITE PERMISSION"), /* @__PURE__ */ React16.createElement(Text16, { marginTop: 1 }, "The agent is attempting to modify: ", /* @__PURE__ */ React16.createElement(Text16, { color: "cyan" }, parseArgs(pendingApproval?.args || "{}").path || "Unknown File")), !isBridgeConnected() ? /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1, borderStyle: "single", borderColor: "#333", paddingX: 1, flexDirection: "column" }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "--- PROPOSED CONTENT ---"), (() => {
19920
20029
  const args2 = parseArgs(pendingApproval?.args || "{}");
19921
20030
  const patchPairs = [];
19922
20031
  const indices = /* @__PURE__ */ new Set();
@@ -19942,15 +20051,15 @@ Selection: ${val}`,
19942
20051
  }
19943
20052
  });
19944
20053
  if (patchPairs.length > 0) {
19945
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1 }, patchPairs.map((pair, idx) => {
20054
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1 }, patchPairs.map((pair, idx) => {
19946
20055
  const hasOld = pair.replace !== null;
19947
20056
  const hasNew = pair.new !== null;
19948
- return /* @__PURE__ */ React15.createElement(Box14, { key: idx, flexDirection: "column", marginTop: idx > 0 ? 1 : 0 }, patchPairs.length > 1 && /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "Block ", idx + 1, ":"), hasOld && /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Text15, { color: "red", wrap: "anywhere", bold: true }, "- ", pair.replace)), hasNew && /* @__PURE__ */ React15.createElement(Box14, { marginTop: hasOld ? 0 : 0 }, /* @__PURE__ */ React15.createElement(Text15, { color: "green", wrap: "anywhere", bold: true }, "+ ", pair.new.replace(/\[\/n\]?/g, "\\n"))));
20057
+ return /* @__PURE__ */ React16.createElement(Box14, { key: idx, flexDirection: "column", marginTop: idx > 0 ? 1 : 0 }, patchPairs.length > 1 && /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "Block ", idx + 1, ":"), hasOld && /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Text16, { color: "red", wrap: "anywhere", bold: true }, "- ", pair.replace)), hasNew && /* @__PURE__ */ React16.createElement(Box14, { marginTop: hasOld ? 0 : 0 }, /* @__PURE__ */ React16.createElement(Text16, { color: "green", wrap: "anywhere", bold: true }, "+ ", pair.new.replace(/\[\/n\]?/g, "\\n"))));
19949
20058
  }));
19950
20059
  }
19951
20060
  const newVal = args2.content || args2.ReplacementContent || args2.content_to_add || args2.replacementContent || args2.newContent || null;
19952
- return /* @__PURE__ */ React15.createElement(Text15, { color: "white", wrap: "anywhere" }, (newVal ? newVal.replace(/\[\/n\]?/g, "\\n") : null) || "Updating file content...");
19953
- })()) : /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1, paddingX: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "cyan", italic: true }, "\u26A1\uFE0F FluxFlow Companion is active. Review the changes in your editor.")), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
20061
+ return /* @__PURE__ */ React16.createElement(Text16, { color: "white", wrap: "anywhere" }, (newVal ? newVal.replace(/\[\/n\]?/g, "\\n") : null) || "Updating file content...");
20062
+ })()) : /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1, paddingX: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "cyan", italic: true }, "\u26A1\uFE0F FluxFlow Companion is active. Review the changes in your editor.")), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
19954
20063
  CommandMenu,
19955
20064
  {
19956
20065
  title: "Action Required",
@@ -19969,7 +20078,7 @@ Selection: ${val}`,
19969
20078
  }
19970
20079
  )));
19971
20080
  case "updateManager":
19972
- return /* @__PURE__ */ React15.createElement(
20081
+ return /* @__PURE__ */ React16.createElement(
19973
20082
  CommandMenu,
19974
20083
  {
19975
20084
  title: "Select Preferred Update Manager",
@@ -20006,7 +20115,7 @@ Selection: ${val}`,
20006
20115
  }
20007
20116
  );
20008
20117
  case "update":
20009
- return /* @__PURE__ */ React15.createElement(
20118
+ return /* @__PURE__ */ React16.createElement(
20010
20119
  UpdateProcessor_default,
20011
20120
  {
20012
20121
  latest: latestVer,
@@ -20032,7 +20141,7 @@ Selection: ${val}`,
20032
20141
  }
20033
20142
  );
20034
20143
  case "terminalApproval":
20035
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "TERMINAL COMMAND OVERSIGHT"), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, null, "Agent requested to run: ", /* @__PURE__ */ React15.createElement(Text15, { color: "yellow", bold: true }, parseArgs(pendingApproval?.args || "{}").command || "Unknown Command"))), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
20144
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "white", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "TERMINAL COMMAND OVERSIGHT"), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, null, "Agent requested to run: ", /* @__PURE__ */ React16.createElement(Text16, { color: "yellow", bold: true }, parseArgs(pendingApproval?.args || "{}").command || "Unknown Command"))), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
20036
20145
  CommandMenu,
20037
20146
  {
20038
20147
  title: "Risk Assessment Required",
@@ -20048,7 +20157,18 @@ Selection: ${val}`,
20048
20157
  }
20049
20158
  )));
20050
20159
  default:
20051
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1, flexShrink: 0, width: "100%" }, showBtwBox && btwResponse && /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%", marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "INQUIRY RESPONSE"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, "[ ESC to Close ]")), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1, width: "100%" }, /* @__PURE__ */ React15.createElement(CodeRenderer, { text: btwResponse, columns: terminalSize.columns - 6 }))), activeSubagents.filter((sa) => sa.status === "running").length > 0 && /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "gray", paddingX: 2, paddingY: 0, width: "100%", marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "ACTIVE SUBAGENTS")), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1, width: "100%" }, activeSubagents.filter((sa) => sa.status === "running").map((sa) => /* @__PURE__ */ React15.createElement(SubagentRow, { key: sa.id, sa })))), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 0, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, null, statusText ? /* @__PURE__ */ React15.createElement(Box14, { gap: 1 }, /* @__PURE__ */ React15.createElement(build_default, null), /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, italic: true }, statusText.trimEnd()), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, activeTime > 0 ? `[${activeTime.toFixed(0)}s]` : "")) : /* @__PURE__ */ React15.createElement(Text15, { color: "white", italic: true }, input.length > 0 && escPressCount ? "Press ESC again to clear input" : hasPasteBlock ? "Press CTRL + O to expand" : "Waiting for input...")), /* @__PURE__ */ React15.createElement(Box14, null, isProcessing && Date.now() - lastChunkTime > 15e3 && !activeSubagents.some((sa) => sa.status === "running" && !statusText.toLowerCase().includes("waiting")) ? /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "Waiting for API"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true }, " \u2503 ")) : wittyPhrase ? /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, wittyPhrase), /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true }, " \u2503 ")) : null, /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, tempModelOverride || activeModel))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { width: "100%", height: 1, overflow: "hidden" }, /* @__PURE__ */ React15.createElement(Text15, { color: "#555555" }, "\u2584".repeat(Math.max(1, terminalSize.columns)))), /* @__PURE__ */ React15.createElement(
20160
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1, flexShrink: 0, width: "100%" }, showBtwBox && btwResponse && /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", paddingX: 2, paddingY: 1, width: "100%", marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "INQUIRY RESPONSE"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, "[ ESC to Close ]")), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1, width: "100%" }, /* @__PURE__ */ React16.createElement(CodeRenderer, { text: btwResponse, columns: terminalSize.columns - 6 }))), activeSubagents.filter((sa) => sa.status === "running").length > 0 && /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "gray", paddingX: 2, paddingY: 0, width: "100%", marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "ACTIVE SUBAGENTS")), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1, width: "100%" }, activeSubagents.filter((sa) => sa.status === "running").map((sa) => /* @__PURE__ */ React16.createElement(SubagentRow, { key: sa.id, sa })))), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 0, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, null, statusText ? /* @__PURE__ */ React16.createElement(Box14, { gap: 1 }, /* @__PURE__ */ React16.createElement(build_default, null), /* @__PURE__ */ React16.createElement(
20161
+ GlintText_default,
20162
+ {
20163
+ text: statusText.trimEnd(),
20164
+ baseColor: "#BFD2CA",
20165
+ glintColor: "#D8D2C8",
20166
+ speed: 60,
20167
+ italic: true,
20168
+ glintWidth: 2,
20169
+ typeSpeed: 10
20170
+ }
20171
+ ), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, activeTime > 0 ? `(${activeTime.toFixed(0)}s)` : "")) : /* @__PURE__ */ React16.createElement(Text16, { color: "grey", italic: true }, input.length > 0 && escPressCount ? "Press ESC again to clear input" : hasPasteBlock ? "Press CTRL + O to expand" : "Waiting for input...")), /* @__PURE__ */ React16.createElement(Box14, null, isProcessing && Date.now() - lastChunkTime > 15e3 && !activeSubagents.some((sa) => sa.status === "running" && !statusText.toLowerCase().includes("waiting")) ? /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, "Waiting for API"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true }, " \u2503 ")) : wittyPhrase ? /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, wittyPhrase), /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true }, " \u2503 ")) : null, /* @__PURE__ */ React16.createElement(GlintText_default, { text: tempModelOverride || activeModel, baseColor: "white", glintColor: "gray", glintWidth: 1 }))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { width: "100%", height: 1, overflow: "hidden" }, /* @__PURE__ */ React16.createElement(Text16, { color: "#555555" }, "\u2584".repeat(Math.max(1, terminalSize.columns)))), /* @__PURE__ */ React16.createElement(
20052
20172
  Box14,
20053
20173
  {
20054
20174
  backgroundColor: "#555555",
@@ -20057,7 +20177,7 @@ Selection: ${val}`,
20057
20177
  width: "100%",
20058
20178
  flexDirection: "column"
20059
20179
  },
20060
- /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "row", width: "100%", paddingY: 0 }, /* @__PURE__ */ React15.createElement(Box14, { flexShrink: 0, width: 4 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, isProcessing || isCompressing ? "\u2726 " : " \u276F ")), /* @__PURE__ */ React15.createElement(Box14, { flexGrow: 1 }, /* @__PURE__ */ React15.createElement(Box14, { flexGrow: 1, position: "relative" }, input === "" && /* @__PURE__ */ React15.createElement(Box14, { position: "absolute", paddingLeft: 0 }, activeCommand && !isTerminalFocused ? /* @__PURE__ */ React15.createElement(Text15, { color: "yellow" }, isTerminalWaitingForInput ? " Terminal is waiting for user input. Press TAB to interact" : " Press TAB to interact with terminal...") : activeCommand && isTerminalFocused ? /* @__PURE__ */ React15.createElement(Text15, { color: "yellow", bold: true }, " [ TERMINAL FOCUSED ] Type to interact, press TAB to exit...") : escPressCount === 1 ? /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, " Press ESC again to ", input.length > 0 ? "clear input" : "revert codebase to checkpoint", "...") : /* @__PURE__ */ React15.createElement(Text15, { color: "#cccccc" }, escPressed ? " Press ESC again to cancel the request." : isCompressing ? " Compressing session history, please wait..." : !isProcessing ? ` Send message, @file or /cmd ... (${terminalEnv.shortcut} for newline)` : " Enter a prompt to steer the agent.")), /* @__PURE__ */ React15.createElement(
20180
+ /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "row", width: "100%", paddingY: 0 }, /* @__PURE__ */ React16.createElement(Box14, { flexShrink: 0, width: 4 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, isProcessing || isCompressing ? "\u2726 " : " \u276F ")), /* @__PURE__ */ React16.createElement(Box14, { flexGrow: 1 }, /* @__PURE__ */ React16.createElement(Box14, { flexGrow: 1, position: "relative" }, input === "" && /* @__PURE__ */ React16.createElement(Box14, { position: "absolute", paddingLeft: 0 }, activeCommand && !isTerminalFocused ? /* @__PURE__ */ React16.createElement(Text16, { color: "yellow" }, isTerminalWaitingForInput ? " Terminal is waiting for user input. Press TAB to interact" : " Press TAB to interact with terminal...") : activeCommand && isTerminalFocused ? /* @__PURE__ */ React16.createElement(Text16, { color: "yellow", bold: true }, " [ TERMINAL FOCUSED ] Type to interact, press TAB to exit...") : escPressCount === 1 ? /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, " Press ESC again to ", input.length > 0 ? "clear input" : "revert codebase to checkpoint", "...") : /* @__PURE__ */ React16.createElement(Text16, { color: "#cccccc" }, escPressed ? " Press ESC again to cancel the request." : isCompressing ? " Compressing session history, please wait..." : !isProcessing ? ` Send message, @file or /cmd ... (${terminalEnv.shortcut} for newline)` : " Enter a prompt to steer the agent.")), /* @__PURE__ */ React16.createElement(
20061
20181
  MultilineInput,
20062
20182
  {
20063
20183
  key: `input-${inputKey}`,
@@ -20082,10 +20202,10 @@ Selection: ${val}`,
20082
20202
  }
20083
20203
  }
20084
20204
  )))))
20085
- ), /* @__PURE__ */ React15.createElement(Box14, { width: "100%", height: 1, overflow: "hidden" }, /* @__PURE__ */ React15.createElement(Text15, { color: "#555555" }, "\u2580".repeat(Math.max(1, terminalSize.columns))))));
20205
+ ), /* @__PURE__ */ React16.createElement(Box14, { width: "100%", height: 1, overflow: "hidden" }, /* @__PURE__ */ React16.createElement(Text16, { color: "#555555" }, "\u2580".repeat(Math.max(1, terminalSize.columns))))));
20086
20206
  }
20087
20207
  };
20088
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", width: "100%" }, isInitializing ? null : showBridgePromo ? /* @__PURE__ */ React15.createElement(BridgePromo, { width: stdout?.columns || 80, height: stdout?.rows || 24, selectedIndex: promoSelectedIndex, aiProvider }) : /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, flexDirection: "column", width: "100%" }, /* @__PURE__ */ React15.createElement(Static, { key: `static-${clearKey}-${chatId}-${terminalSize.columns}-${terminalSize.rows}`, items: parsedBlocks.completed }, (block) => /* @__PURE__ */ React15.createElement(
20208
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", width: "100%" }, isInitializing ? null : showBridgePromo ? /* @__PURE__ */ React16.createElement(BridgePromo, { width: stdout?.columns || 80, height: stdout?.rows || 24, selectedIndex: promoSelectedIndex, aiProvider }) : /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, flexDirection: "column", width: "100%" }, /* @__PURE__ */ React16.createElement(Static, { key: `static-${clearKey}-${chatId}-${terminalSize.columns}-${terminalSize.rows}`, items: parsedBlocks.completed }, (block) => /* @__PURE__ */ React16.createElement(
20089
20209
  BlockItem,
20090
20210
  {
20091
20211
  key: block.key,
@@ -20095,7 +20215,7 @@ Selection: ${val}`,
20095
20215
  aiProvider,
20096
20216
  version: versionFluxflow
20097
20217
  }
20098
- ))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", paddingX: 1, paddingBottom: 0, width: "100%" }, (activeView === "chat" || ["ask", "approval", "terminalApproval"].includes(activeView)) && /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", width: "100%" }, parsedBlocks.active.map((block) => /* @__PURE__ */ React15.createElement(
20218
+ ))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", paddingX: 1, paddingBottom: 0, width: "100%" }, (activeView === "chat" || ["ask", "approval", "terminalApproval"].includes(activeView)) && /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", width: "100%" }, parsedBlocks.active.map((block) => /* @__PURE__ */ React16.createElement(
20099
20219
  BlockItem,
20100
20220
  {
20101
20221
  key: block.key,
@@ -20105,7 +20225,7 @@ Selection: ${val}`,
20105
20225
  aiProvider,
20106
20226
  version: versionFluxflow
20107
20227
  }
20108
- )), activeCommand && /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(TerminalBox, { command: activeCommand, output: execOutput, isFocused: isTerminalFocused, isPty: isActiveCommandPty, terminalHeight: terminalSize.rows }))), isInitializing ? /* @__PURE__ */ React15.createElement(Box14, { borderStyle: "double", borderColor: "grey", padding: 1, flexShrink: 0 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, "Starting Flux Flow...")) : !apiKey ? /* @__PURE__ */ React15.createElement(Box14, { borderStyle: "round", borderColor: "white", padding: 0, flexDirection: "column", flexShrink: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", bold: true }, "API KEY REQUIRED")), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, flexDirection: "column" }, setupStep === 0 ? /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, "Select your Preferred Provider:"), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(
20228
+ )), activeCommand && /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(TerminalBox, { command: activeCommand, output: execOutput, isFocused: isTerminalFocused, isPty: isActiveCommandPty, terminalHeight: terminalSize.rows, columns: terminalSize.columns }))), isInitializing ? /* @__PURE__ */ React16.createElement(Box14, { borderStyle: "double", borderColor: "grey", padding: 1, flexShrink: 0 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, "Starting Flux Flow...")) : !apiKey ? /* @__PURE__ */ React16.createElement(Box14, { borderStyle: "round", borderColor: "white", padding: 0, flexDirection: "column", flexShrink: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", bold: true }, "API KEY REQUIRED")), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, flexDirection: "column" }, setupStep === 0 ? /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, "Select your Preferred Provider:"), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(
20109
20229
  CommandMenu,
20110
20230
  {
20111
20231
  items: [
@@ -20119,7 +20239,7 @@ Selection: ${val}`,
20119
20239
  setSetupStep(1);
20120
20240
  }
20121
20241
  }
20122
- ))) : /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, "Please enter your ", aiProvider, " API Key to initialize the agent (If billing is enabled set /settings \u2192 Others \u2192 API Strategy to use premium models. Set budget limit at /budgets.)."), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", bold: true }, " ", ">", " "), /* @__PURE__ */ React15.createElement(
20242
+ ))) : /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, "Please enter your ", aiProvider, " API Key to initialize the agent (If billing is enabled set /settings \u2192 Others \u2192 API Strategy to use premium models. Set budget limit at /budgets.)."), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", bold: true }, " ", ">", " "), /* @__PURE__ */ React16.createElement(
20123
20243
  TextInput4,
20124
20244
  {
20125
20245
  value: tempKey,
@@ -20127,7 +20247,7 @@ Selection: ${val}`,
20127
20247
  onSubmit: handleSetup,
20128
20248
  mask: "*"
20129
20249
  }
20130
- )), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, "(Press ESC to go back to provider selection)")))), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, setupStep === 0 ? "(Use arrows to select and Enter to confirm)" : "(Press Enter to confirm and initialize)"))) : renderActiveView(), confirmExit && /* @__PURE__ */ React15.createElement(Box14, { borderStyle: "round", borderColor: "white", paddingX: 2, marginY: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "\u{1F534} EXIT CONFIRMATION: "), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, "Press "), /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, "CTRL + C"), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " again to exit (", exitCountdown, "s). Press "), /* @__PURE__ */ React15.createElement(Text15, { color: "gray", bold: true }, "ESC"), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " to cancel.")), suggestions.length > 0 && (() => {
20250
+ )), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, "(Press ESC to go back to provider selection)")))), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, setupStep === 0 ? "(Use arrows to select and Enter to confirm)" : "(Press Enter to confirm and initialize)"))) : renderActiveView(), confirmExit && /* @__PURE__ */ React16.createElement(Box14, { borderStyle: "round", borderColor: "white", paddingX: 2, marginY: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "\u{1F534} EXIT CONFIRMATION: "), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, "Press "), /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, "CTRL + C"), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " again to exit (", exitCountdown, "s). Press "), /* @__PURE__ */ React16.createElement(Text16, { color: "gray", bold: true }, "ESC"), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " to cancel.")), suggestions.length > 0 && (() => {
20131
20251
  const windowSize = 5;
20132
20252
  let startIdx = suggestionOffsetRef.current;
20133
20253
  if (selectedIndex < startIdx) {
@@ -20139,14 +20259,14 @@ Selection: ${val}`,
20139
20259
  suggestionOffsetRef.current = startIdx;
20140
20260
  const visible = suggestions.slice(startIdx, startIdx + windowSize);
20141
20261
  const remaining = suggestions.length - (startIdx + visible.length);
20142
- return /* @__PURE__ */ React15.createElement(
20262
+ return /* @__PURE__ */ React16.createElement(
20143
20263
  Box14,
20144
20264
  {
20145
20265
  flexDirection: "column",
20146
20266
  width: "100%",
20147
20267
  marginBottom: 1
20148
20268
  },
20149
- /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginBottom: 0, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true }, suggestions[0]?.cmd?.startsWith("@") ? "FILE SUGGESTIONS" : "COMMAND SUGGESTIONS"), suggestions[0]?.cmd?.startsWith("@") ? /* @__PURE__ */ React15.createElement(Text15, { color: "gray", italic: true }, "(Use '#Lstart-Lend' to specify line numbers)") : input.startsWith("/model") && apiTier === "Free" ? (() => {
20269
+ /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginBottom: 0, justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true }, suggestions[0]?.cmd?.startsWith("@") ? "FILE SUGGESTIONS" : "COMMAND SUGGESTIONS"), suggestions[0]?.cmd?.startsWith("@") ? /* @__PURE__ */ React16.createElement(Text16, { color: "gray", italic: true }, "(Use '#Lstart-Lend' to specify line numbers)") : input.startsWith("/model") && apiTier === "Free" ? (() => {
20150
20270
  let url = "https://aistudio.google.com/billing";
20151
20271
  let label = "billing";
20152
20272
  if (aiProvider === "DeepSeek") {
@@ -20159,13 +20279,13 @@ Selection: ${val}`,
20159
20279
  url = "https://build.nvidia.com/settings/api-keys";
20160
20280
  label = "billing";
20161
20281
  }
20162
- return /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true, italic: true }, "Paid API Strategy has more models. Configure ", /* @__PURE__ */ React15.createElement(Text15, { color: "cyan", underline: true }, `\x1B]8;;${url}\x07${label}\x1B]8;;\x07`), " & /settings");
20282
+ return /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true, italic: true }, "Paid API Strategy has more models. Configure ", /* @__PURE__ */ React16.createElement(Text16, { color: "cyan", underline: true }, `\x1B]8;;${url}\x07${label}\x1B]8;;\x07`), " & /settings");
20163
20283
  })() : null),
20164
20284
  visible.map((s, i) => {
20165
20285
  const actualIdx = startIdx + i;
20166
20286
  const isActive = actualIdx === selectedIndex;
20167
20287
  const isGemmaDisabled = s.cmd === "gemma-4-31b-it" && apiTier !== "Free";
20168
- return /* @__PURE__ */ React15.createElement(
20288
+ return /* @__PURE__ */ React16.createElement(
20169
20289
  Box14,
20170
20290
  {
20171
20291
  key: s.cmd,
@@ -20173,9 +20293,9 @@ Selection: ${val}`,
20173
20293
  backgroundColor: isActive ? "#2a2a2a" : void 0,
20174
20294
  paddingX: 1
20175
20295
  },
20176
- /* @__PURE__ */ React15.createElement(Box14, { width: 3 }, /* @__PURE__ */ React15.createElement(Text15, { color: isActive ? "white" : "gray", bold: isActive }, isActive ? " \u276F" : " ")),
20177
- /* @__PURE__ */ React15.createElement(Box14, { width: 55 }, /* @__PURE__ */ React15.createElement(
20178
- Text15,
20296
+ /* @__PURE__ */ React16.createElement(Box14, { width: 3 }, /* @__PURE__ */ React16.createElement(Text16, { color: isActive ? "white" : "gray", bold: isActive }, isActive ? " \u276F" : " ")),
20297
+ /* @__PURE__ */ React16.createElement(Box14, { width: 55 }, /* @__PURE__ */ React16.createElement(
20298
+ Text16,
20179
20299
  {
20180
20300
  color: isGemmaDisabled ? "gray" : isActive ? "white" : "grey",
20181
20301
  bold: isActive
@@ -20186,12 +20306,12 @@ Selection: ${val}`,
20186
20306
  return parts[parts.length - 1];
20187
20307
  })() : s.cmd
20188
20308
  )),
20189
- /* @__PURE__ */ React15.createElement(Box14, { flexGrow: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: `${!isActive ? "gray" : "white"}`, italic: true }, s.desc))
20309
+ /* @__PURE__ */ React16.createElement(Box14, { flexGrow: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: `${!isActive ? "gray" : "white"}`, italic: true }, s.desc))
20190
20310
  );
20191
20311
  }),
20192
- suggestions.length > 5 && /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, height: 1 }, remaining > 0 ? /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true, italic: true }, " ... (", remaining, " more commands available)") : /* @__PURE__ */ React15.createElement(Text15, { color: "gray", dimColor: true, italic: true }, " (End of list)"))
20312
+ suggestions.length > 5 && /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, height: 1 }, remaining > 0 ? /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true, italic: true }, " ... (", remaining, " more commands available)") : /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true, italic: true }, " (End of list)"))
20193
20313
  );
20194
- })(), /* @__PURE__ */ React15.createElement(Box14, { flexShrink: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(
20314
+ })(), /* @__PURE__ */ React16.createElement(Box14, { flexShrink: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(
20195
20315
  StatusBar_default,
20196
20316
  {
20197
20317
  mode,
@@ -20213,7 +20333,7 @@ Selection: ${val}`,
20213
20333
  const agentActiveMs = sessionApiTime + sessionToolTime;
20214
20334
  const apiPercent = agentActiveMs > 0 ? (sessionApiTime / agentActiveMs * 100).toFixed(1) : "0.0";
20215
20335
  const toolPercent = agentActiveMs > 0 ? (sessionToolTime / agentActiveMs * 100).toFixed(1) : "0.0";
20216
- return /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", paddingX: 3, paddingY: 1, borderColor: "grey", width: Math.min(100, (stdout?.columns || 100) - 2), marginTop: 0, marginBottom: 0 }, /* @__PURE__ */ React15.createElement(Box14, { marginBottom: 1 }, /* @__PURE__ */ React15.createElement(Text15, { bold: true }, gradient2(["blue", "purple"])("Agent powering down. Goodbye!"))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "Interaction Summary"), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Session ID:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, chatId)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Tool Calls:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, runtimeSession.toolSuccess + runtimeSession.toolFailure + runtimeSession.toolDenied, " ( ", /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "\u2714 ", runtimeSession.toolSuccess), " ", /* @__PURE__ */ React15.createElement(Text15, { color: "yellow" }, "\u{1F6C7} ", runtimeSession.toolDenied), " ", /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "\u2718 ", runtimeSession.toolFailure), " )")), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Success Rate:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, successRate, "%")), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Code Changes:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, /* @__PURE__ */ React15.createElement(Text15, { color: "green" }, "+", runtimeSession.linesAdded), " ", /* @__PURE__ */ React15.createElement(Text15, { color: "red" }, "-", runtimeSession.linesRemoved))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Tokens Consumed:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalTokens))), sessionTotalTokens > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 18 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalTokens - sessionTotalCandidateTokens))), sessionTotalCachedTokens > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React15.createElement(Box14, { width: 16 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalCachedTokens))), sessionTotalCandidateTokens > 0 && /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 18 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatTokens(sessionTotalCandidateTokens)))), sessionImageCount > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Images Made:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, sessionImageCount)), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Image Credits:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, Number(((sessionImageCredits || 0) * 1e3).toFixed(0)), " credits")))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, "Performance"), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Wall Time:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(wallTimeMs))), /* @__PURE__ */ React15.createElement(Box14, null, /* @__PURE__ */ React15.createElement(Box14, { width: 20 }, /* @__PURE__ */ React15.createElement(Text15, { color: "blue" }, "Agent Active:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(agentActiveMs))), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 18 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB API Time:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(sessionApiTime), " (", apiPercent, "%)")), /* @__PURE__ */ React15.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React15.createElement(Box14, { width: 18 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "\xBB Tool Time:")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, formatMsDuration(sessionToolTime), " (", toolPercent, "%)"))));
20336
+ return /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", paddingX: 3, paddingY: 1, borderColor: "grey", width: Math.min(100, (stdout?.columns || 100) - 2), marginTop: 0, marginBottom: 0 }, /* @__PURE__ */ React16.createElement(Box14, { marginBottom: 1 }, /* @__PURE__ */ React16.createElement(Text16, { bold: true }, gradient2(["blue", "purple"])("Agent powering down. Goodbye!"))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "Interaction Summary"), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Session ID:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, chatId)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Tool Calls:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, runtimeSession.toolSuccess + runtimeSession.toolFailure + runtimeSession.toolDenied, " ( ", /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "\u2714 ", runtimeSession.toolSuccess), " ", /* @__PURE__ */ React16.createElement(Text16, { color: "yellow" }, "\u{1F6C7} ", runtimeSession.toolDenied), " ", /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "\u2718 ", runtimeSession.toolFailure), " )")), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Success Rate:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, successRate, "%")), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Code Changes:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, /* @__PURE__ */ React16.createElement(Text16, { color: "green" }, "+", runtimeSession.linesAdded), " ", /* @__PURE__ */ React16.createElement(Text16, { color: "red" }, "-", runtimeSession.linesRemoved))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Tokens Consumed:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalTokens))), sessionTotalTokens > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 18 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Input Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalTokens - sessionTotalCandidateTokens))), sessionTotalCachedTokens > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 4 }, /* @__PURE__ */ React16.createElement(Box14, { width: 16 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Cached:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalCachedTokens))), sessionTotalCandidateTokens > 0 && /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 18 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Output Tokens:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatTokens(sessionTotalCandidateTokens)))), sessionImageCount > 0 && /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Images Made:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, sessionImageCount)), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Image Credits:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, Number(((sessionImageCredits || 0) * 1e3).toFixed(0)), " credits")))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, "Performance"), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1 }, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Wall Time:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(wallTimeMs))), /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(Box14, { width: 20 }, /* @__PURE__ */ React16.createElement(Text16, { color: "blue" }, "Agent Active:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(agentActiveMs))), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 18 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB API Time:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(sessionApiTime), " (", apiPercent, "%)")), /* @__PURE__ */ React16.createElement(Box14, { marginLeft: 2 }, /* @__PURE__ */ React16.createElement(Box14, { width: 18 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "\xBB Tool Time:")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, formatMsDuration(sessionToolTime), " (", toolPercent, "%)"))));
20217
20337
  })())));
20218
20338
  }
20219
20339
  var shouldClearValue, getPrefilledValue, getIDEName, getIDEDirName, getKeybindingsPath, parseJsonc, hasShiftEnterBinding, getPromoOptions, BridgePromo, SESSION_START_TIME, CHANGELOG_URL, DOCS_URL, packageJsonPath, packageJson, versionFluxflow, updatedOn, ResolutionModal, parseAgentText, getProjectFiles, cachedShortcut, getLatencyColor2, SubagentRow;
@@ -20249,6 +20369,7 @@ var init_app = __esm({
20249
20369
  init_setup();
20250
20370
  init_text();
20251
20371
  init_editor();
20372
+ init_GlintText();
20252
20373
  shouldClearValue = (val) => {
20253
20374
  const s = String(val);
20254
20375
  return s.startsWith("999") && s.endsWith("9");
@@ -20331,7 +20452,7 @@ var init_app = __esm({
20331
20452
  BridgePromo = ({ width, height, selectedIndex, aiProvider }) => {
20332
20453
  const ideName = getIDEName();
20333
20454
  const options = getPromoOptions(ideName);
20334
- return /* @__PURE__ */ React15.createElement(
20455
+ return /* @__PURE__ */ React16.createElement(
20335
20456
  Box14,
20336
20457
  {
20337
20458
  flexDirection: "column",
@@ -20340,8 +20461,8 @@ var init_app = __esm({
20340
20461
  width,
20341
20462
  height
20342
20463
  },
20343
- /* @__PURE__ */ React15.createElement(Box14, { marginBottom: 1, width: Math.min(80, width - 4), justifyContent: "flex-start" }, /* @__PURE__ */ React15.createElement(Text15, null, getFluxLogo(versionFluxflow, aiProvider))),
20344
- /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "double", borderColor: "grey", paddingX: 3, paddingY: 1, width: Math.min(80, width - 4) }, /* @__PURE__ */ React15.createElement(Text15, { bold: true, color: "white", textAlign: "center" }, "\u{1F680} UPGRADE YOUR WORKFLOW"), /* @__PURE__ */ React15.createElement(Box14, { marginY: 1, flexDirection: "column", alignItems: "left" }, /* @__PURE__ */ React15.createElement(Text15, null, "You're in ", /* @__PURE__ */ React15.createElement(Text15, { bold: true, color: "cyan" }, ideName), ", but the ", /* @__PURE__ */ React15.createElement(Text15, { bold: true, color: "white" }, "FluxFlow-CLI Companion"), " is not installed."), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Real-time IDE context & Error Resolution"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Auto-open files created by agent"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Native DIFFing for AI edits"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Direct IDE context sharing"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Surgical Diagnostic Sync"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Native Right-Click \u276F Chat integration"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Live Status in IDE"), /* @__PURE__ */ React15.createElement(Text15, { color: "gray" }, " \u2705 Clickable terminal-to-code links"))), /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", marginTop: 1 }, options.map((opt, i) => /* @__PURE__ */ React15.createElement(Box14, { key: i }, /* @__PURE__ */ React15.createElement(Text15, { color: selectedIndex === i ? "yellow" : "white", bold: selectedIndex === i }, selectedIndex === i ? " \u276F " : " ", opt.label)))), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1, alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React15.createElement(Text15, { dimColor: true, italic: true }, "(Use arrows to navigate, Enter to select)")))
20464
+ /* @__PURE__ */ React16.createElement(Box14, { marginBottom: 1, width: Math.min(80, width - 4), justifyContent: "flex-start" }, /* @__PURE__ */ React16.createElement(Text16, null, getFluxLogo(versionFluxflow, aiProvider))),
20465
+ /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "double", borderColor: "grey", paddingX: 3, paddingY: 1, width: Math.min(80, width - 4) }, /* @__PURE__ */ React16.createElement(Text16, { bold: true, color: "white", textAlign: "center" }, "\u{1F680} UPGRADE YOUR WORKFLOW"), /* @__PURE__ */ React16.createElement(Box14, { marginY: 1, flexDirection: "column", alignItems: "left" }, /* @__PURE__ */ React16.createElement(Text16, null, "You're in ", /* @__PURE__ */ React16.createElement(Text16, { bold: true, color: "cyan" }, ideName), ", but the ", /* @__PURE__ */ React16.createElement(Text16, { bold: true, color: "white" }, "FluxFlow-CLI Companion"), " is not installed."), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Real-time IDE context & Error Resolution"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Auto-open files created by agent"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Native DIFFing for AI edits"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Direct IDE context sharing"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Surgical Diagnostic Sync"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Native Right-Click \u276F Chat integration"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Live Status in IDE"), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, " \u2705 Clickable terminal-to-code links"))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", marginTop: 1 }, options.map((opt, i) => /* @__PURE__ */ React16.createElement(Box14, { key: i }, /* @__PURE__ */ React16.createElement(Text16, { color: selectedIndex === i ? "yellow" : "white", bold: selectedIndex === i }, selectedIndex === i ? " \u276F " : " ", opt.label)))), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1, alignItems: "center", justifyContent: "center" }, /* @__PURE__ */ React16.createElement(Text16, { dimColor: true, italic: true }, "(Use arrows to navigate, Enter to select)")))
20345
20466
  );
20346
20467
  };
20347
20468
  SESSION_START_TIME = Date.now();
@@ -20351,7 +20472,7 @@ var init_app = __esm({
20351
20472
  packageJson = JSON.parse(fs24.readFileSync(packageJsonPath, "utf8"));
20352
20473
  versionFluxflow = packageJson.version;
20353
20474
  updatedOn = packageJson.date || "2026-05-20";
20354
- ResolutionModal = ({ data, onResolve, onEdit }) => /* @__PURE__ */ React15.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", padding: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", bold: true, underline: true }, data.startsWith("/btw") ? "QUESTION" : "STEERING HINT", " RESOLUTION")), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, null, "The agent already finished the task before your ", data.startsWith("/btw") ? "question" : "hint", " was consumed.")), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 1, backgroundColor: "#222", paddingX: 2, width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { italic: true, color: "gray" }, '"', data.replace("/btw", "").trim(), '"')), /* @__PURE__ */ React15.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React15.createElement(Text15, { color: "grey" }, "How would you like to proceed?")), /* @__PURE__ */ React15.createElement(Box14, { marginTop: 0 }, /* @__PURE__ */ React15.createElement(
20475
+ ResolutionModal = ({ data, onResolve, onEdit }) => /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", borderStyle: "round", borderColor: "grey", padding: 0, width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", bold: true, underline: true }, data.startsWith("/btw") ? "QUESTION" : "STEERING HINT", " RESOLUTION")), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, null, "The agent already finished the task before your ", data.startsWith("/btw") ? "question" : "hint", " was consumed.")), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 1, backgroundColor: "#222", paddingX: 2, width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { italic: true, color: "gray" }, '"', data.replace("/btw", "").trim(), '"')), /* @__PURE__ */ React16.createElement(Box14, { paddingX: 1, marginTop: 1 }, /* @__PURE__ */ React16.createElement(Text16, { color: "grey" }, "How would you like to proceed?")), /* @__PURE__ */ React16.createElement(Box14, { marginTop: 0 }, /* @__PURE__ */ React16.createElement(
20355
20476
  CommandMenu,
20356
20477
  {
20357
20478
  title: "Select Action",
@@ -20493,10 +20614,10 @@ var init_app = __esm({
20493
20614
  }
20494
20615
  return "#ff0000";
20495
20616
  };
20496
- SubagentRow = React15.memo(({ sa }) => {
20497
- const [dotColor, setDotColor] = useState14("green");
20617
+ SubagentRow = React16.memo(({ sa }) => {
20618
+ const [dotColor, setDotColor] = useState15("green");
20498
20619
  const chunkTimesRef = useRef4([]);
20499
- useEffect11(() => {
20620
+ useEffect12(() => {
20500
20621
  if (sa.status !== "running") {
20501
20622
  chunkTimesRef.current = [];
20502
20623
  return;
@@ -20533,7 +20654,7 @@ var init_app = __esm({
20533
20654
  const timer = setInterval(checkLatency, 100);
20534
20655
  return () => clearInterval(timer);
20535
20656
  }, [sa.status, sa.lastChunkTime]);
20536
- return /* @__PURE__ */ React15.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, " \u2022 ", sa.title, " ", /* @__PURE__ */ React15.createElement(Text15, { color: "white", dimColor: true }, "(", sa.id, ")")), /* @__PURE__ */ React15.createElement(Text15, { color: "white" }, /* @__PURE__ */ React15.createElement(Text15, { color: "white", dimColor: true, bold: true }, sa.currentTool || "Active"), /* @__PURE__ */ React15.createElement(Text15, { color: dotColor }, " \u25CF")));
20657
+ return /* @__PURE__ */ React16.createElement(Box14, { justifyContent: "space-between", width: "100%" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, " \u2022 ", sa.title, " ", /* @__PURE__ */ React16.createElement(Text16, { color: "white", dimColor: true }, "(", sa.id, ")")), /* @__PURE__ */ React16.createElement(Text16, { color: "white" }, /* @__PURE__ */ React16.createElement(Text16, { color: "white", dimColor: true, bold: true }, sa.currentTool || "Active"), /* @__PURE__ */ React16.createElement(Text16, { color: dotColor }, " \u25CF")));
20537
20658
  });
20538
20659
  }
20539
20660
  });
@@ -20687,9 +20808,9 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20687
20808
  process.exit(0);
20688
20809
  }
20689
20810
  const promptPackageManager = async () => {
20690
- const React17 = (await import("react")).default;
20691
- const { useState: useState15 } = React17;
20692
- const { render: render2, Box: Box15, Text: Text16 } = await import("ink");
20811
+ const React18 = (await import("react")).default;
20812
+ const { useState: useState16 } = React18;
20813
+ const { render: render2, Box: Box15, Text: Text17 } = await import("ink");
20693
20814
  const SelectInput3 = (await import("ink-select-input")).default;
20694
20815
  const TextInput5 = (await import("ink-text-input")).default;
20695
20816
  return new Promise((resolve) => {
@@ -20701,12 +20822,12 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20701
20822
  { label: "Custom Command", value: "custom" }
20702
20823
  ];
20703
20824
  const CustomItem2 = ({ label, isSelected }) => {
20704
- return /* @__PURE__ */ React17.createElement(Box15, { width: "100%" }, /* @__PURE__ */ React17.createElement(Text16, { bold: isSelected }, "\u2514\u2500 ", isSelected ? "\x1B[32m\u25CF\x1B[0m" : "\u25CB", " ", label));
20825
+ return /* @__PURE__ */ React18.createElement(Box15, { width: "100%" }, /* @__PURE__ */ React18.createElement(Text17, { bold: isSelected }, "\u2514\u2500 ", isSelected ? "\x1B[32m\u25CF\x1B[0m" : "\u25CB", " ", label));
20705
20826
  };
20706
20827
  let unmountFn;
20707
20828
  const PromptComponent = () => {
20708
- const [step, setStep] = useState15("select");
20709
- const [customCommand2, setCustomCommand] = useState15("");
20829
+ const [step, setStep] = useState16("select");
20830
+ const [customCommand2, setCustomCommand] = useState16("");
20710
20831
  const handleSelect = (item) => {
20711
20832
  if (item.value === "custom") {
20712
20833
  setStep("custom");
@@ -20718,16 +20839,16 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20718
20839
  cleanupAndResolve({ manager: "custom", customCommand: value });
20719
20840
  };
20720
20841
  if (step === "custom") {
20721
- return /* @__PURE__ */ React17.createElement(Box15, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React17.createElement(Box15, { marginBottom: 1 }, /* @__PURE__ */ React17.createElement(Text16, { color: "magenta", bold: true }, "\u{1F527} Enter custom update command:")), /* @__PURE__ */ React17.createElement(Box15, { flexDirection: "row" }, /* @__PURE__ */ React17.createElement(Text16, { color: "cyan", bold: true }, " \u276F "), /* @__PURE__ */ React17.createElement(
20842
+ return /* @__PURE__ */ React18.createElement(Box15, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React18.createElement(Box15, { marginBottom: 1 }, /* @__PURE__ */ React18.createElement(Text17, { color: "magenta", bold: true }, "\u{1F527} Enter custom update command:")), /* @__PURE__ */ React18.createElement(Box15, { flexDirection: "row" }, /* @__PURE__ */ React18.createElement(Text17, { color: "cyan", bold: true }, " \u276F "), /* @__PURE__ */ React18.createElement(
20722
20843
  TextInput5,
20723
20844
  {
20724
20845
  value: customCommand2,
20725
20846
  onChange: setCustomCommand,
20726
20847
  onSubmit: handleCustomSubmit
20727
20848
  }
20728
- )), /* @__PURE__ */ React17.createElement(Box15, { marginTop: 1 }, /* @__PURE__ */ React17.createElement(Text16, { color: "gray", dimColor: true, italic: true }, " (Press Enter to confirm)")));
20849
+ )), /* @__PURE__ */ React18.createElement(Box15, { marginTop: 1 }, /* @__PURE__ */ React18.createElement(Text17, { color: "gray", dimColor: true, italic: true }, " (Press Enter to confirm)")));
20729
20850
  }
20730
- return /* @__PURE__ */ React17.createElement(Box15, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React17.createElement(Box15, { marginBottom: 1 }, /* @__PURE__ */ React17.createElement(Text16, { color: "magenta", bold: true }, "\u{1F4E6} Select a package manager for the update:")), /* @__PURE__ */ React17.createElement(
20851
+ return /* @__PURE__ */ React18.createElement(Box15, { flexDirection: "column", marginY: 1 }, /* @__PURE__ */ React18.createElement(Box15, { marginBottom: 1 }, /* @__PURE__ */ React18.createElement(Text17, { color: "magenta", bold: true }, "\u{1F4E6} Select a package manager for the update:")), /* @__PURE__ */ React18.createElement(
20731
20852
  SelectInput3,
20732
20853
  {
20733
20854
  items,
@@ -20741,7 +20862,7 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20741
20862
  if (unmountFn) unmountFn();
20742
20863
  resolve(val);
20743
20864
  };
20744
- const { unmount } = render2(/* @__PURE__ */ React17.createElement(PromptComponent, null));
20865
+ const { unmount } = render2(/* @__PURE__ */ React18.createElement(PromptComponent, null));
20745
20866
  unmountFn = unmount;
20746
20867
  });
20747
20868
  };
@@ -20781,7 +20902,7 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20781
20902
  }
20782
20903
  }
20783
20904
  }
20784
- const { default: React16 } = await import("react");
20905
+ const { default: React17 } = await import("react");
20785
20906
  const { render } = await import("ink");
20786
20907
  const { default: App2 } = await init_app().then(() => app_exports);
20787
20908
  process.env.NODE_NO_WARNINGS = "1";
@@ -20834,5 +20955,5 @@ if (isBundled && !process.execArgv.some((arg) => arg.includes("max-old-space-siz
20834
20955
  } catch (e) {
20835
20956
  }
20836
20957
  }
20837
- render(/* @__PURE__ */ React16.createElement(App2, { args: process.argv.slice(2) }), { exitOnCtrlC: false });
20958
+ render(/* @__PURE__ */ React17.createElement(App2, { args: process.argv.slice(2) }), { exitOnCtrlC: false });
20838
20959
  }