codeep 1.2.78 → 1.2.79

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.
@@ -1488,20 +1488,21 @@ export class App {
1488
1488
  this.screen.showCursor(false);
1489
1489
  return;
1490
1490
  }
1491
- // Build prompt prefix — show line count for multi-line buffers
1491
+ // Build prompt prefix
1492
1492
  const lines = inputValue.split('\n');
1493
1493
  const lineCount = lines.length;
1494
- const prompt = lineCount > 1 ? `[${lineCount}] > ` : this.isMultilineMode ? 'M> ' : '> ';
1495
- const maxInputWidth = width - prompt.length - 1;
1494
+ // for normal, ❯❯ for multiline, [n] for multi-line with count
1495
+ const promptSymbol = lineCount > 1 ? `[${lineCount}] ❯ ` : this.isMultilineMode ? '❯❯ ' : '❯ ';
1496
+ const maxInputWidth = width - promptSymbol.length - 1;
1496
1497
  // Show placeholder when input is empty
1497
1498
  if (!inputValue) {
1498
- this.screen.write(0, y, prompt, fg.green);
1499
+ this.screen.write(0, y, promptSymbol, PRIMARY_COLOR);
1499
1500
  const placeholder = this.isMultilineMode
1500
- ? 'Multi-line mode (Enter=newline, Esc=send)...'
1501
- : 'Type a message or /command...';
1502
- this.screen.write(prompt.length, y, placeholder, fg.gray);
1501
+ ? 'Multi-line mode Enter=newline · Esc=send'
1502
+ : 'Message or /command';
1503
+ this.screen.write(promptSymbol.length, y, placeholder, fg.gray + style.dim);
1503
1504
  if (!hideCursor) {
1504
- this.screen.setCursor(prompt.length, y);
1505
+ this.screen.setCursor(promptSymbol.length, y);
1505
1506
  this.screen.showCursor(true);
1506
1507
  }
1507
1508
  else {
@@ -1512,14 +1513,13 @@ export class App {
1512
1513
  // For multi-line content, show the last line being edited
1513
1514
  const lastLine = lines[lines.length - 1];
1514
1515
  const displayInput = lineCount > 1 ? lastLine : inputValue;
1515
- // Cursor position within the last line
1516
1516
  const charsBeforeLastLine = lineCount > 1 ? inputValue.lastIndexOf('\n') + 1 : 0;
1517
1517
  const cursorInLine = cursorPos - charsBeforeLastLine;
1518
1518
  let displayValue;
1519
1519
  let cursorX;
1520
1520
  if (displayInput.length <= maxInputWidth) {
1521
1521
  displayValue = displayInput;
1522
- cursorX = prompt.length + Math.max(0, cursorInLine);
1522
+ cursorX = promptSymbol.length + Math.max(0, cursorInLine);
1523
1523
  }
1524
1524
  else {
1525
1525
  const effectiveCursor = Math.max(0, cursorInLine);
@@ -1531,9 +1531,11 @@ export class App {
1531
1531
  else {
1532
1532
  displayValue = displayInput.slice(0, maxInputWidth);
1533
1533
  }
1534
- cursorX = prompt.length + (effectiveCursor - visibleStart);
1534
+ cursorX = promptSymbol.length + (effectiveCursor - visibleStart);
1535
1535
  }
1536
- this.screen.writeLine(y, prompt + displayValue, fg.green);
1536
+ // Prompt symbol in primary color, input text in white
1537
+ this.screen.write(0, y, promptSymbol, PRIMARY_COLOR);
1538
+ this.screen.write(promptSymbol.length, y, displayValue, fg.white);
1537
1539
  // Hide cursor when menu/settings is open
1538
1540
  if (hideCursor) {
1539
1541
  this.screen.showCursor(false);
@@ -2065,34 +2067,25 @@ export class App {
2065
2067
  }
2066
2068
  const status = this.options.getStatus();
2067
2069
  const stats = status.tokenStats;
2068
- const tokenInfo = stats && stats.totalTokens > 0
2069
- ? ` ${stats.totalTokens < 1000 ? stats.totalTokens : (stats.totalTokens / 1000).toFixed(1) + 'K'} tok`
2070
+ // Left segment: msg count · token count
2071
+ const msgCount = `${this.messages.length} msg`;
2072
+ const tokenStr = stats && stats.totalTokens > 0
2073
+ ? `${stats.totalTokens < 1000 ? stats.totalTokens : (stats.totalTokens / 1000).toFixed(1) + 'K'} tok`
2070
2074
  : '';
2071
- // Left: message count (gray) + token info (dim)
2072
- const msgPart = ` ${this.messages.length} msg`;
2073
- this.screen.write(0, y, msgPart, fg.gray);
2074
- if (tokenInfo) {
2075
- this.screen.write(msgPart.length, y, tokenInfo, fg.gray + style.dim);
2076
- }
2077
- // Center: model name with gradient
2075
+ const leftParts = [msgCount, tokenStr].filter(Boolean);
2076
+ const leftText = ' ' + leftParts.join(' · ');
2077
+ this.screen.write(0, y, leftText, fg.gray + style.dim);
2078
+ // Center: model name with gradient (only if it fits)
2078
2079
  const modelName = status.model || '';
2079
- if (modelName) {
2080
- const modelColored = gradientText(modelName, GRADIENT_STOPS);
2080
+ if (modelName && width > 40) {
2081
2081
  const modelX = Math.floor((width - modelName.length) / 2);
2082
- this.screen.write(modelX, y, modelColored);
2083
- }
2084
- // Right: context hint (gray)
2085
- let rightText;
2086
- if (this.isStreaming) {
2087
- rightText = 'Esc cancel ';
2082
+ this.screen.write(modelX, y, gradientText(modelName, GRADIENT_STOPS));
2088
2083
  }
2089
- else if (this.isLoading) {
2090
- rightText = 'working... ';
2091
- }
2092
- else {
2093
- rightText = '/help ';
2084
+ // Right: Esc hint only when active, nothing when idle
2085
+ if (this.isStreaming || this.isLoading) {
2086
+ const rightText = 'Esc ';
2087
+ this.screen.write(width - rightText.length, y, rightText, fg.gray + style.dim);
2094
2088
  }
2095
- this.screen.write(width - rightText.length, y, rightText, fg.gray);
2096
2089
  }
2097
2090
  /**
2098
2091
  * Get visible messages (including streaming)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeep",
3
- "version": "1.2.78",
3
+ "version": "1.2.79",
4
4
  "description": "AI-powered coding assistant built for the terminal. Multiple LLM providers, project-aware context, and a seamless development workflow.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",