@rikcodes/teamclaude 1.1.22-rik.1 → 1.1.22-rik.2

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/package.json +1 -1
  2. package/src/tui.js +9 -9
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rikcodes/teamclaude",
3
- "version": "1.1.22-rik.1",
3
+ "version": "1.1.22-rik.2",
4
4
  "description": "Multi-account proxy for Claude Code and Codex: pools Claude Max, ChatGPT/Codex, API-key and third-party backend accounts, and rotates on quota",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/tui.js CHANGED
@@ -265,8 +265,9 @@ const PROVIDER_ORDER = Object.keys(PROVIDERS);
265
265
  // Two provider pools side by side: the gutter between the panes.
266
266
  const PANE_GUTTER = ' │ ';
267
267
  // Pane bars: at least wide enough for `10h23m`, and past that only once every
268
- // name is whole.
269
- const PANE_BAR_MAX = 12;
268
+ // name is whole. From there they grow to BAR_MAX, as the list's bars do: a
269
+ // narrower cap left a 600-column terminal drawing 12-column bars beside
270
+ // hundreds of blank columns.
270
271
  const PANE_BAR_FLOOR = 8;
271
272
  // The narrowest a list draws both shared bars in, full width and in a pane.
272
273
  const LIST_MIN = 70;
@@ -2463,7 +2464,6 @@ export class TUI {
2463
2464
  // The type cell and the space after it, at the width the row pads it to.
2464
2465
  const typeCell = pane == null ? typeColumn(this.am.accounts).width + 1 : 0;
2465
2466
  const floor = pane == null ? LIST_MIN : PANE_MIN;
2466
- const barCap = pane == null ? BAR_MAX : PANE_BAR_MAX;
2467
2467
  // The columns every name needs past NAME_MIN to be whole.
2468
2468
  const longestName = Math.max(0, ...accts.map(a => vw(a.name)));
2469
2469
  const nameWant = Math.max(0, longestName - NAME_MIN);
@@ -2530,11 +2530,11 @@ export class TUI {
2530
2530
  const avail = barRoom(0);
2531
2531
  let bw = avail < BAR_MIN
2532
2532
  ? Math.max(1, avail)
2533
- : Math.min(barCap, avail);
2533
+ : Math.min(BAR_MAX, avail);
2534
2534
  // A pane gives names the columns before bars grow past the floor.
2535
2535
  if (pane != null && avail >= BAR_MIN) {
2536
2536
  const named = barRoom(nameWant);
2537
- bw = named >= PANE_BAR_FLOOR ? Math.min(barCap, named) : Math.min(PANE_BAR_FLOOR, avail);
2537
+ bw = named >= PANE_BAR_FLOOR ? Math.min(BAR_MAX, named) : Math.min(PANE_BAR_FLOOR, avail);
2538
2538
  }
2539
2539
  const slack = Math.max(0, W - fixed - 6 * (nbars - 1) - nbars * bw);
2540
2540
  const drawn = (shortBar ? 2 : 1) + families;
@@ -2542,7 +2542,7 @@ export class TUI {
2542
2542
  // width that reaches it draws every bar.
2543
2543
  const s1 = Math.max(floor, span(2 + families, BAR_MIN), span(drawn, PANE_BAR_FLOOR));
2544
2544
  const s2 = Math.max(s1, span(drawn, PANE_BAR_FLOOR) + nameWant);
2545
- const s3 = Math.max(s2, span(drawn, barCap) + nameWant);
2545
+ const s3 = Math.max(s2, span(drawn, BAR_MAX) + nameWant);
2546
2546
  return {
2547
2547
  bw, showBoth, showFamily, anyFable, anySonnet, slack, shortBar,
2548
2548
  complete: showBoth && (families === 0 || showFamily),
@@ -2601,7 +2601,9 @@ export class TUI {
2601
2601
  }
2602
2602
 
2603
2603
  /** Two pane layouts, or null when `W` cannot fit both. Width goes stage by stage,
2604
- * both panes reaching one before either starts the next, a partial one shared pro rata. */
2604
+ * both panes reaching one before either starts the next, a partial one shared pro rata.
2605
+ * Width past the last stage stays unused on the right: shared between the panes it
2606
+ * set the Codex pane mid-screen and the fleet panel at the far edge. */
2605
2607
  _splitLayout(/** @type {{ provider: string, indices: number[] }[]} */ groups, /** @type {number} */ W) {
2606
2608
  const [a, b] = groups;
2607
2609
  const avail = W - vw(PANE_GUTTER);
@@ -2624,8 +2626,6 @@ export class TUI {
2624
2626
  leftW += wantA;
2625
2627
  rightW += wantB;
2626
2628
  }
2627
- leftW += Math.floor((avail - leftW - rightW) / 2);
2628
- rightW = avail - leftW;
2629
2629
  const left = this._listLayout(a.indices, leftW, { pane: a.provider });
2630
2630
  const right = this._listLayout(b.indices, rightW, { pane: b.provider });
2631
2631
  return left.complete && right.complete ? { leftW, rightW, left, right } : null;