@hasna/coders 0.0.12 → 0.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.mjs CHANGED
@@ -17648,7 +17648,7 @@ var require_react_reconciler_development = __commonJS({
17648
17648
  var HostPortal = 4;
17649
17649
  var HostComponent = 5;
17650
17650
  var HostText = 6;
17651
- var Fragment = 7;
17651
+ var Fragment2 = 7;
17652
17652
  var Mode = 8;
17653
17653
  var ContextConsumer = 9;
17654
17654
  var ContextProvider = 10;
@@ -17788,7 +17788,7 @@ var require_react_reconciler_development = __commonJS({
17788
17788
  return "DehydratedFragment";
17789
17789
  case ForwardRef:
17790
17790
  return getWrappedName$1(type, type.render, "ForwardRef");
17791
- case Fragment:
17791
+ case Fragment2:
17792
17792
  return "Fragment";
17793
17793
  case HostComponent:
17794
17794
  return type;
@@ -20922,7 +20922,7 @@ var require_react_reconciler_development = __commonJS({
20922
20922
  }
20923
20923
  }
20924
20924
  function updateFragment2(returnFiber, current2, fragment, lanes, key) {
20925
- if (current2 === null || current2.tag !== Fragment) {
20925
+ if (current2 === null || current2.tag !== Fragment2) {
20926
20926
  var created = createFiberFromFragment(fragment, returnFiber.mode, lanes, key);
20927
20927
  created.return = returnFiber;
20928
20928
  return created;
@@ -21325,7 +21325,7 @@ var require_react_reconciler_development = __commonJS({
21325
21325
  if (child.key === key) {
21326
21326
  var elementType = element.type;
21327
21327
  if (elementType === REACT_FRAGMENT_TYPE) {
21328
- if (child.tag === Fragment) {
21328
+ if (child.tag === Fragment2) {
21329
21329
  deleteRemainingChildren(returnFiber, child.sibling);
21330
21330
  var existing = useFiber(child, element.props.children);
21331
21331
  existing.return = returnFiber;
@@ -26816,7 +26816,7 @@ var require_react_reconciler_development = __commonJS({
26816
26816
  var _resolvedProps2 = workInProgress2.elementType === type ? _unresolvedProps2 : resolveDefaultProps(type, _unresolvedProps2);
26817
26817
  return updateForwardRef(current2, workInProgress2, type, _resolvedProps2, renderLanes2);
26818
26818
  }
26819
- case Fragment:
26819
+ case Fragment2:
26820
26820
  return updateFragment(current2, workInProgress2, renderLanes2);
26821
26821
  case Mode:
26822
26822
  return updateMode(current2, workInProgress2, renderLanes2);
@@ -27253,7 +27253,7 @@ var require_react_reconciler_development = __commonJS({
27253
27253
  case SimpleMemoComponent:
27254
27254
  case FunctionComponent:
27255
27255
  case ForwardRef:
27256
- case Fragment:
27256
+ case Fragment2:
27257
27257
  case Mode:
27258
27258
  case Profiler:
27259
27259
  case ContextConsumer:
@@ -32021,7 +32021,7 @@ var require_react_reconciler_development = __commonJS({
32021
32021
  return fiber;
32022
32022
  }
32023
32023
  function createFiberFromFragment(elements, mode, lanes, key) {
32024
- var fiber = createFiber(Fragment, elements, key, mode);
32024
+ var fiber = createFiber(Fragment2, elements, key, mode);
32025
32025
  fiber.lanes = lanes;
32026
32026
  return fiber;
32027
32027
  }
@@ -47312,7 +47312,7 @@ var require_backend = __commonJS({
47312
47312
  var symbolOrNumber = renderer_typeof(type) === "object" && type !== null ? type.$$typeof : type;
47313
47313
  return renderer_typeof(symbolOrNumber) === "symbol" ? symbolOrNumber.toString() : symbolOrNumber;
47314
47314
  }
47315
- var _ReactTypeOfWork = ReactTypeOfWork, CacheComponent = _ReactTypeOfWork.CacheComponent, ClassComponent = _ReactTypeOfWork.ClassComponent, IncompleteClassComponent = _ReactTypeOfWork.IncompleteClassComponent, IncompleteFunctionComponent = _ReactTypeOfWork.IncompleteFunctionComponent, FunctionComponent = _ReactTypeOfWork.FunctionComponent, IndeterminateComponent = _ReactTypeOfWork.IndeterminateComponent, ForwardRef = _ReactTypeOfWork.ForwardRef, HostRoot = _ReactTypeOfWork.HostRoot, HostHoistable = _ReactTypeOfWork.HostHoistable, HostSingleton = _ReactTypeOfWork.HostSingleton, HostComponent = _ReactTypeOfWork.HostComponent, HostPortal = _ReactTypeOfWork.HostPortal, HostText = _ReactTypeOfWork.HostText, Fragment = _ReactTypeOfWork.Fragment, LazyComponent = _ReactTypeOfWork.LazyComponent, LegacyHiddenComponent = _ReactTypeOfWork.LegacyHiddenComponent, MemoComponent = _ReactTypeOfWork.MemoComponent, OffscreenComponent = _ReactTypeOfWork.OffscreenComponent, Profiler = _ReactTypeOfWork.Profiler, ScopeComponent = _ReactTypeOfWork.ScopeComponent, SimpleMemoComponent = _ReactTypeOfWork.SimpleMemoComponent, SuspenseComponent = _ReactTypeOfWork.SuspenseComponent, SuspenseListComponent = _ReactTypeOfWork.SuspenseListComponent, TracingMarkerComponent = _ReactTypeOfWork.TracingMarkerComponent, Throw = _ReactTypeOfWork.Throw, ViewTransitionComponent = _ReactTypeOfWork.ViewTransitionComponent, ActivityComponent = _ReactTypeOfWork.ActivityComponent;
47315
+ var _ReactTypeOfWork = ReactTypeOfWork, CacheComponent = _ReactTypeOfWork.CacheComponent, ClassComponent = _ReactTypeOfWork.ClassComponent, IncompleteClassComponent = _ReactTypeOfWork.IncompleteClassComponent, IncompleteFunctionComponent = _ReactTypeOfWork.IncompleteFunctionComponent, FunctionComponent = _ReactTypeOfWork.FunctionComponent, IndeterminateComponent = _ReactTypeOfWork.IndeterminateComponent, ForwardRef = _ReactTypeOfWork.ForwardRef, HostRoot = _ReactTypeOfWork.HostRoot, HostHoistable = _ReactTypeOfWork.HostHoistable, HostSingleton = _ReactTypeOfWork.HostSingleton, HostComponent = _ReactTypeOfWork.HostComponent, HostPortal = _ReactTypeOfWork.HostPortal, HostText = _ReactTypeOfWork.HostText, Fragment2 = _ReactTypeOfWork.Fragment, LazyComponent = _ReactTypeOfWork.LazyComponent, LegacyHiddenComponent = _ReactTypeOfWork.LegacyHiddenComponent, MemoComponent = _ReactTypeOfWork.MemoComponent, OffscreenComponent = _ReactTypeOfWork.OffscreenComponent, Profiler = _ReactTypeOfWork.Profiler, ScopeComponent = _ReactTypeOfWork.ScopeComponent, SimpleMemoComponent = _ReactTypeOfWork.SimpleMemoComponent, SuspenseComponent = _ReactTypeOfWork.SuspenseComponent, SuspenseListComponent = _ReactTypeOfWork.SuspenseListComponent, TracingMarkerComponent = _ReactTypeOfWork.TracingMarkerComponent, Throw = _ReactTypeOfWork.Throw, ViewTransitionComponent = _ReactTypeOfWork.ViewTransitionComponent, ActivityComponent = _ReactTypeOfWork.ActivityComponent;
47316
47316
  function resolveFiberType(type) {
47317
47317
  var typeSymbol = getTypeSymbol(type);
47318
47318
  switch (typeSymbol) {
@@ -47368,7 +47368,7 @@ var require_backend = __commonJS({
47368
47368
  case HostPortal:
47369
47369
  case HostText:
47370
47370
  return null;
47371
- case Fragment:
47371
+ case Fragment2:
47372
47372
  return "Fragment";
47373
47373
  case LazyComponent:
47374
47374
  return "Lazy";
@@ -47523,7 +47523,7 @@ var require_backend = __commonJS({
47523
47523
  function renderer_attach(hook, rendererID, renderer2, global2, shouldStartProfilingNow, profilingSettings) {
47524
47524
  var version = renderer2.reconcilerVersion || renderer2.version;
47525
47525
  var _getInternalReactCons = getInternalReactConstants(version), getDisplayNameForFiber = _getInternalReactCons.getDisplayNameForFiber, getTypeSymbol = _getInternalReactCons.getTypeSymbol, ReactPriorityLevels = _getInternalReactCons.ReactPriorityLevels, ReactTypeOfWork = _getInternalReactCons.ReactTypeOfWork, StrictModeBits = _getInternalReactCons.StrictModeBits, SuspenseyImagesMode = _getInternalReactCons.SuspenseyImagesMode;
47526
- var ActivityComponent = ReactTypeOfWork.ActivityComponent, ClassComponent = ReactTypeOfWork.ClassComponent, ContextConsumer = ReactTypeOfWork.ContextConsumer, DehydratedSuspenseComponent = ReactTypeOfWork.DehydratedSuspenseComponent, ForwardRef = ReactTypeOfWork.ForwardRef, Fragment = ReactTypeOfWork.Fragment, FunctionComponent = ReactTypeOfWork.FunctionComponent, HostRoot = ReactTypeOfWork.HostRoot, HostHoistable = ReactTypeOfWork.HostHoistable, HostSingleton = ReactTypeOfWork.HostSingleton, HostPortal = ReactTypeOfWork.HostPortal, HostComponent = ReactTypeOfWork.HostComponent, HostText = ReactTypeOfWork.HostText, IncompleteClassComponent = ReactTypeOfWork.IncompleteClassComponent, IncompleteFunctionComponent = ReactTypeOfWork.IncompleteFunctionComponent, IndeterminateComponent = ReactTypeOfWork.IndeterminateComponent, LegacyHiddenComponent = ReactTypeOfWork.LegacyHiddenComponent, MemoComponent = ReactTypeOfWork.MemoComponent, OffscreenComponent = ReactTypeOfWork.OffscreenComponent, SimpleMemoComponent = ReactTypeOfWork.SimpleMemoComponent, SuspenseComponent = ReactTypeOfWork.SuspenseComponent, SuspenseListComponent = ReactTypeOfWork.SuspenseListComponent, TracingMarkerComponent = ReactTypeOfWork.TracingMarkerComponent, Throw = ReactTypeOfWork.Throw, ViewTransitionComponent = ReactTypeOfWork.ViewTransitionComponent;
47526
+ var ActivityComponent = ReactTypeOfWork.ActivityComponent, ClassComponent = ReactTypeOfWork.ClassComponent, ContextConsumer = ReactTypeOfWork.ContextConsumer, DehydratedSuspenseComponent = ReactTypeOfWork.DehydratedSuspenseComponent, ForwardRef = ReactTypeOfWork.ForwardRef, Fragment2 = ReactTypeOfWork.Fragment, FunctionComponent = ReactTypeOfWork.FunctionComponent, HostRoot = ReactTypeOfWork.HostRoot, HostHoistable = ReactTypeOfWork.HostHoistable, HostSingleton = ReactTypeOfWork.HostSingleton, HostPortal = ReactTypeOfWork.HostPortal, HostComponent = ReactTypeOfWork.HostComponent, HostText = ReactTypeOfWork.HostText, IncompleteClassComponent = ReactTypeOfWork.IncompleteClassComponent, IncompleteFunctionComponent = ReactTypeOfWork.IncompleteFunctionComponent, IndeterminateComponent = ReactTypeOfWork.IndeterminateComponent, LegacyHiddenComponent = ReactTypeOfWork.LegacyHiddenComponent, MemoComponent = ReactTypeOfWork.MemoComponent, OffscreenComponent = ReactTypeOfWork.OffscreenComponent, SimpleMemoComponent = ReactTypeOfWork.SimpleMemoComponent, SuspenseComponent = ReactTypeOfWork.SuspenseComponent, SuspenseListComponent = ReactTypeOfWork.SuspenseListComponent, TracingMarkerComponent = ReactTypeOfWork.TracingMarkerComponent, Throw = ReactTypeOfWork.Throw, ViewTransitionComponent = ReactTypeOfWork.ViewTransitionComponent;
47527
47527
  var ImmediatePriority = ReactPriorityLevels.ImmediatePriority, UserBlockingPriority = ReactPriorityLevels.UserBlockingPriority, NormalPriority = ReactPriorityLevels.NormalPriority, LowPriority = ReactPriorityLevels.LowPriority, IdlePriority = ReactPriorityLevels.IdlePriority, NoPriority = ReactPriorityLevels.NoPriority;
47528
47528
  var getLaneLabelMap = renderer2.getLaneLabelMap, injectProfilingHooks = renderer2.injectProfilingHooks, overrideHookState = renderer2.overrideHookState, overrideHookStateDeletePath = renderer2.overrideHookStateDeletePath, overrideHookStateRenamePath = renderer2.overrideHookStateRenamePath, overrideProps = renderer2.overrideProps, overridePropsDeletePath = renderer2.overridePropsDeletePath, overridePropsRenamePath = renderer2.overridePropsRenamePath, scheduleRefresh = renderer2.scheduleRefresh, setErrorHandler = renderer2.setErrorHandler, setSuspenseHandler = renderer2.setSuspenseHandler, scheduleUpdate = renderer2.scheduleUpdate, scheduleRetry = renderer2.scheduleRetry, getCurrentFiber = renderer2.getCurrentFiber;
47529
47529
  var supportsTogglingError = typeof setErrorHandler === "function" && typeof scheduleUpdate === "function";
@@ -47884,7 +47884,7 @@ var require_backend = __commonJS({
47884
47884
  return true;
47885
47885
  case HostRoot:
47886
47886
  return false;
47887
- case Fragment:
47887
+ case Fragment2:
47888
47888
  return key === null;
47889
47889
  default:
47890
47890
  var typeSymbol = getTypeSymbol(type);
@@ -47958,7 +47958,7 @@ var require_backend = __commonJS({
47958
47958
  return ElementTypeHostComponent;
47959
47959
  case HostPortal:
47960
47960
  case HostText:
47961
- case Fragment:
47961
+ case Fragment2:
47962
47962
  return ElementTypeOtherOrUnknown;
47963
47963
  case MemoComponent:
47964
47964
  case SimpleMemoComponent:
@@ -57556,6 +57556,25 @@ var init_render = __esm({
57556
57556
  });
57557
57557
 
57558
57558
  // node_modules/ink/build/components/Static.js
57559
+ function Static(props) {
57560
+ const { items, children: render2, style: customStyle } = props;
57561
+ const [index, setIndex] = (0, import_react11.useState)(0);
57562
+ const itemsToRender = (0, import_react11.useMemo)(() => {
57563
+ return items.slice(index);
57564
+ }, [items, index]);
57565
+ (0, import_react11.useLayoutEffect)(() => {
57566
+ setIndex(items.length);
57567
+ }, [items.length]);
57568
+ const children = itemsToRender.map((item, itemIndex) => {
57569
+ return render2(item, index + itemIndex);
57570
+ });
57571
+ const style = (0, import_react11.useMemo)(() => ({
57572
+ position: "absolute",
57573
+ flexDirection: "column",
57574
+ ...customStyle
57575
+ }), [customStyle]);
57576
+ return import_react11.default.createElement("ink-box", { internal_static: true, style }, children);
57577
+ }
57559
57578
  var import_react11;
57560
57579
  var init_Static = __esm({
57561
57580
  "node_modules/ink/build/components/Static.js"() {
@@ -58419,7 +58438,7 @@ var init_client = __esm({
58419
58438
  "Content-Type": "application/json",
58420
58439
  "anthropic-version": "2023-06-01",
58421
58440
  "anthropic-beta": BETA_HEADERS.join(","),
58422
- "User-Agent": `coders/${"0.0.12"}`
58441
+ "User-Agent": `coders/${"0.0.14"}`
58423
58442
  };
58424
58443
  if (key.isOAuth) {
58425
58444
  headers["Authorization"] = `Bearer ${key.apiKey}`;
@@ -61492,7 +61511,6 @@ function getDb() {
61492
61511
  const BetterSqlite3 = __require("better-sqlite3");
61493
61512
  _db = new BetterSqlite3(dbPath);
61494
61513
  } catch {
61495
- console.warn("[db] No SQLite available \u2014 using in-memory fallback");
61496
61514
  _db = createInMemoryDb();
61497
61515
  initSchema(_db);
61498
61516
  return _db;
@@ -62464,6 +62482,9 @@ var init_read = __esm({
62464
62482
  return { behavior: "allow", updatedInput: input };
62465
62483
  },
62466
62484
  async call(input, context) {
62485
+ if (!input.file_path || typeof input.file_path !== "string") {
62486
+ return { data: { content: "Error: file_path is required", filePath: "", totalLines: 0, linesRead: 0, startLine: 0 } };
62487
+ }
62467
62488
  const resolved = resolvePath(input.file_path);
62468
62489
  const ext = extname(resolved).toLowerCase();
62469
62490
  markFileAsRead(resolved);
@@ -62673,6 +62694,12 @@ var init_edit = __esm({
62673
62694
  return { behavior: "passthrough" };
62674
62695
  },
62675
62696
  async call(input, context) {
62697
+ if (!input.file_path || typeof input.file_path !== "string") {
62698
+ return { data: { filePath: "", oldString: "", newString: "", replacements: 0, originalFile: "" } };
62699
+ }
62700
+ if (!input.old_string || typeof input.old_string !== "string") {
62701
+ return { data: { filePath: input.file_path, oldString: "", newString: "", replacements: 0, originalFile: "" } };
62702
+ }
62676
62703
  const resolved = resolvePath2(input.file_path);
62677
62704
  const originalContent = readFileSync4(resolved, "utf-8");
62678
62705
  let newContent;
@@ -62804,20 +62831,15 @@ var init_write = __esm({
62804
62831
  if (!input.file_path) {
62805
62832
  return { result: false, message: "file_path is required", errorCode: 1 };
62806
62833
  }
62807
- const resolved = resolvePath3(input.file_path);
62808
- if (existsSync7(resolved) && !hasFileBeenRead(resolved)) {
62809
- return {
62810
- result: false,
62811
- message: "This file already exists. You must Read it first before overwriting. Use the Read tool, then retry.",
62812
- errorCode: 2
62813
- };
62814
- }
62815
62834
  return { result: true };
62816
62835
  },
62817
62836
  async checkPermissions(input) {
62818
62837
  return { behavior: "passthrough" };
62819
62838
  },
62820
62839
  async call(input, context) {
62840
+ if (!input.file_path || typeof input.file_path !== "string") {
62841
+ return { data: { filePath: "", bytesWritten: 0, created: false } };
62842
+ }
62821
62843
  const resolved = resolvePath3(input.file_path);
62822
62844
  const created = !existsSync7(resolved);
62823
62845
  const dir = dirname2(resolved);
@@ -69759,19 +69781,6 @@ function SpinnerDot() {
69759
69781
  const f = useSpinner(true);
69760
69782
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "cyan", children: f });
69761
69783
  }
69762
- function Header({ model, mode }) {
69763
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { marginBottom: 1, children: [
69764
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { bold: true, color: "cyan", children: "@hasna/coders" }),
69765
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { dimColor: true, children: [
69766
- " v",
69767
- VERSION,
69768
- " \xB7 ",
69769
- model,
69770
- " \xB7 ",
69771
- mode
69772
- ] })
69773
- ] });
69774
- }
69775
69784
  function ToolItem({ tool }) {
69776
69785
  const f = useSpinner(tool.status === "running");
69777
69786
  const icon = tool.status === "running" ? "\xB7" : tool.status === "error" ? "\u25CF" : "\u25CF";
@@ -70064,56 +70073,37 @@ function App2({ model, mode, initialPrompt }) {
70064
70073
  } else if (key.escape) setInput("");
70065
70074
  else if (!key.ctrl && !key.meta && ch) setInput((p) => p + ch);
70066
70075
  });
70067
- const maxVisible = Math.max(2, Math.floor((rows - 5) / 3));
70068
- const visible = msgs.slice(-maxVisible);
70069
- const hiddenCount = msgs.length - visible.length;
70070
- const recentTools = activeTools.slice(-3);
70071
- const streamLines = streaming ? streaming.split("\n") : [];
70072
- const maxStreamLines = Math.max(3, rows - 12);
70073
- const truncatedStream = streamLines.length > maxStreamLines ? streamLines.slice(-maxStreamLines).join("\n") : streaming;
70076
+ const recentTools = activeTools.slice(-2);
70074
70077
  const cols = stdout?.columns ?? 80;
70075
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { flexDirection: "column", height: rows, children: [
70076
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Header, { model, mode }),
70077
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { flexDirection: "column", flexGrow: 1, overflow: "hidden", children: [
70078
- hiddenCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { dimColor: true, children: [
70079
- " \u2191 ",
70080
- hiddenCount,
70081
- " earlier message",
70082
- hiddenCount !== 1 ? "s" : ""
70083
- ] }) }),
70084
- visible.map((m) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageView, { msg: m }, m.id)),
70085
- busy && recentTools.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { flexDirection: "column", children: [
70086
- activeTools.length > 3 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { dimColor: true, children: [
70087
- " \u2026 +",
70088
- activeTools.length - 3,
70089
- " earlier tools"
70090
- ] }) }),
70091
- recentTools.map((t) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToolItem, { tool: t }, t.id))
70092
- ] }),
70093
- busy && truncatedStream && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70094
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "green", children: "\u25CF " }),
70095
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: truncatedStream })
70096
- ] }),
70097
- busy && !streaming && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70098
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SpinnerDot, {}),
70099
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { dimColor: true, children: [
70100
- " ",
70101
- recentTools.some((t) => t.status === "running") ? "Working" : "Thinking",
70102
- "..."
70103
- ] })
70078
+ const sep = "\u2500".repeat(Math.min(cols, 120));
70079
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
70080
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Static, { items: msgs, children: (msg) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "column", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageView, { msg }) }, msg.id) }),
70081
+ busy && recentTools.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "column", children: recentTools.map((t) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToolItem, { tool: t }, t.id)) }),
70082
+ busy && streaming && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70083
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "green", children: "\u25CF " }),
70084
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: streaming.split("\n").filter((l) => l.trim()).slice(-3).join("\n").slice(-200) })
70085
+ ] }),
70086
+ busy && !streaming && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70087
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SpinnerDot, {}),
70088
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { dimColor: true, children: [
70089
+ " ",
70090
+ recentTools.some((t) => t.status === "running") ? "Working" : "Thinking",
70091
+ "..."
70104
70092
  ] })
70105
70093
  ] }),
70106
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { dimColor: true, children: "\u2500".repeat(Math.min(cols, 120)) }) }),
70107
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70108
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { color: "cyan", bold: true, children: [
70109
- PROMPT,
70110
- " "
70094
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { flexDirection: "column", children: [
70095
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { dimColor: true, children: sep }),
70096
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box_default, { children: [
70097
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { color: "cyan", bold: true, children: [
70098
+ PROMPT,
70099
+ " "
70100
+ ] }),
70101
+ input.startsWith("/") ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "magenta", children: input }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: input }),
70102
+ !busy && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "gray", children: "\u258E" })
70111
70103
  ] }),
70112
- input.startsWith("/") ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "magenta", children: input }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: input }),
70113
- !busy && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { color: "gray", children: "\u258E" })
70114
- ] }),
70115
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { dimColor: true, children: "\u2500".repeat(Math.min(cols, 120)) }) }),
70116
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatusBar, { model, mode, cost, tokens })
70104
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { dimColor: true, children: sep }),
70105
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatusBar, { model, mode, cost, tokens })
70106
+ ] })
70117
70107
  ] });
70118
70108
  }
70119
70109
  function launchInkApp(opts = {}) {
@@ -70127,6 +70117,12 @@ function launchInkApp(opts = {}) {
70127
70117
  `);
70128
70118
  process.exit(1);
70129
70119
  }
70120
+ const origWarn = console.warn;
70121
+ const origError = console.error;
70122
+ console.warn = () => {
70123
+ };
70124
+ console.error = () => {
70125
+ };
70130
70126
  const { waitUntilExit } = render_default(
70131
70127
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(App2, { model, mode, initialPrompt: opts.initialPrompt }),
70132
70128
  { exitOnCtrlC: false }
@@ -70402,8 +70398,8 @@ async function bootstrap() {
70402
70398
  var VERSION, BUILD_TIME, PACKAGE_NAME2, ISSUES_URL2, startupTimestamps, originalCwd, RESET_TERMINAL, cleanupHandlers, earlyInput, earlyInputCapturing;
70403
70399
  var init_index = __esm({
70404
70400
  "src/cli/index.ts"() {
70405
- VERSION = "0.0.12";
70406
- BUILD_TIME = "2026-03-20T10:40:16.674Z";
70401
+ VERSION = "0.0.14";
70402
+ BUILD_TIME = "2026-03-20T11:07:02.137Z";
70407
70403
  PACKAGE_NAME2 = "@hasna/coders";
70408
70404
  ISSUES_URL2 = "https://github.com/hasnaxyz/open-coders/issues";
70409
70405
  startupTimestamps = {};