termkit 2.4.0 → 2.4.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.
package/README.md CHANGED
@@ -176,6 +176,8 @@ configure({
176
176
  })
177
177
  ```
178
178
 
179
+ `glyphs` is auto-detected at startup. TermKit disables Unicode glyphs and falls back to ASCII alternatives on legacy terminals: `TERM=dumb`, non-UTF-8 locales (`LANG`/`LC_ALL`), and Windows consoles that are not Windows Terminal, VS Code, or Hyper. Set `TERMKIT_ASCII=1` to force ASCII mode regardless of terminal detection.
180
+
179
181
  ### Input
180
182
 
181
183
  Interactive text prompt. Supports string, number, integer, boolean, and enum types with validation.
@@ -764,11 +766,13 @@ ANSI-aware string truncation. Measures visible length ignoring escape codes, and
764
766
  import { truncate } from 'termkit'
765
767
 
766
768
  truncate('The quick brown fox jumps over the lazy dog', 20)
767
- // 'The quick brown fox…'
769
+ // 'The quick brown fox…' (or '...' on legacy terminals)
768
770
 
769
771
  truncate(coloredString, 40, ' [more]')
770
772
  ```
771
773
 
774
+ The default suffix is `…` when glyphs are enabled and `...` on legacy terminals. Pass an explicit suffix to override.
775
+
772
776
  ### wrap
773
777
 
774
778
  ANSI-aware word wrap. Breaks at spaces to keep each line within a given column width.
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,GAAG,IAAI,MAAM,EAAE,CAAA;AAI5H,UAAU,aAAa;IACrB,KAAK,EAAE,SAAS,CAAA;IAChB,WAAW,EAAE,MAAM,EAAE,CAAA;IACrB,MAAM,EAAE,OAAO,CAAA;IACf,WAAW,EAAE,OAAO,CAAA;CACrB;AAED,eAAO,MAAM,MAAM,EAAE,aAKpB,CAAA;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,OAAO,CAAC,aAAa,CAAC,GAAG,IAAI,CAK5D"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,GAAG,IAAI,MAAM,EAAE,CAAA;AAO5H,UAAU,aAAa;IACrB,KAAK,EAAE,SAAS,CAAA;IAChB,WAAW,EAAE,MAAM,EAAE,CAAA;IACrB,MAAM,EAAE,OAAO,CAAA;IACf,WAAW,EAAE,OAAO,CAAA;CACrB;AAED,eAAO,MAAM,MAAM,EAAE,aAKpB,CAAA;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,OAAO,CAAC,aAAa,CAAC,GAAG,IAAI,CAK5D"}
package/dist/index.js CHANGED
@@ -66,7 +66,9 @@ __export(index_exports, {
66
66
  module.exports = __toCommonJS(index_exports);
67
67
 
68
68
  // src/config.ts
69
- var isLegacyTerminal = process.env.TERM === "dumb" || process.platform === "win32" && !process.env.WT_SESSION && process.env.TERM_PROGRAM !== "vscode" && process.env.TERM_PROGRAM !== "Hyper";
69
+ var locale = process.env.LC_ALL ?? process.env.LANG ?? "";
70
+ var isNonUtf8Locale = locale !== "" && !/utf-?8/i.test(locale);
71
+ var isLegacyTerminal = !!process.env.TERMKIT_ASCII || process.env.TERM === "dumb" || isNonUtf8Locale || process.platform === "win32" && !process.env.WT_SESSION && process.env.TERM_PROGRAM !== "vscode" && process.env.TERM_PROGRAM !== "Hyper";
70
72
  var config = {
71
73
  color: "cyan",
72
74
  pulseColors: ["#06b6d4", "#67e8f9"],
@@ -639,7 +641,7 @@ var Select = class {
639
641
  process.stdin.removeListener("data", onKey);
640
642
  process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
641
643
  });
642
- const cleanup = () => {
644
+ const cleanup = (selectedLabel) => {
643
645
  deregisterCleanup();
644
646
  if (timer) {
645
647
  clearInterval(timer);
@@ -648,7 +650,12 @@ var Select = class {
648
650
  process.stdin.setRawMode(false);
649
651
  process.stdin.pause();
650
652
  process.stdin.removeListener("data", onKey);
651
- process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
653
+ process.stdout.write(CURSOR_UP(lastDrawnLines + 1));
654
+ process.stdout.write("\r\x1B[0J");
655
+ process.stdout.write(ENABLE_WRAP);
656
+ process.stdout.write(`${glyph}${prompt}: ${selectedLabel ?? this.skipLabel}
657
+ `);
658
+ process.stdout.write(SHOW_CURSOR);
652
659
  };
653
660
  if (this._parsedColors.length >= 2) {
654
661
  timer = setInterval(() => {
@@ -670,10 +677,19 @@ var Select = class {
670
677
  selectedIndex = (selectedIndex + 1) % allItems.length;
671
678
  renderList(true);
672
679
  } else if (str === "\r" || str === "\n") {
673
- cleanup();
674
- resolve(selectedIndex === filtered.length ? null : filtered[selectedIndex] ?? null);
680
+ const result = selectedIndex === filtered.length ? null : filtered[selectedIndex] ?? null;
681
+ cleanup(result?.label ?? null);
682
+ resolve(result);
675
683
  } else if (str === "") {
676
- cleanup();
684
+ deregisterCleanup();
685
+ if (timer) {
686
+ clearInterval(timer);
687
+ timer = null;
688
+ }
689
+ process.stdin.setRawMode(false);
690
+ process.stdin.pause();
691
+ process.stdin.removeListener("data", onKey);
692
+ process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
677
693
  process.exit(130);
678
694
  } else if (this.searchEnabled) {
679
695
  if (str === "\x7F" || str === "\b") {
@@ -1321,7 +1337,7 @@ var _Bar = class _Bar {
1321
1337
  this._failColor = opts.failColor ?? RED;
1322
1338
  this._warnColor = opts.warnColor ?? YELLOW;
1323
1339
  this._infoColor = opts.infoColor ?? BLUE;
1324
- this._glyphs = opts.glyphs ?? true;
1340
+ this._glyphs = opts.glyphs ?? config.glyphs;
1325
1341
  this._showRate = opts.showRate ?? false;
1326
1342
  this._showEta = opts.showEta ?? false;
1327
1343
  this._rateUnit = opts.rateUnit ?? "";
@@ -1473,9 +1489,9 @@ var _Bar = class _Bar {
1473
1489
  succeed(string) {
1474
1490
  this.running = false;
1475
1491
  if (_Bar.current === this) _Bar.current = null;
1492
+ const g = this._glyphs ? "\u2714" : "+";
1476
1493
  if (this._isManaged) {
1477
- const glyph = this._glyphs ? colorText(this._successColor, "\u2714") + " " : "";
1478
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1494
+ this._managedFinalLine = `${colorText(this._successColor, g)}${string ? ` ${string}` : ""}`;
1479
1495
  return this;
1480
1496
  }
1481
1497
  this._cleanupDeregister?.();
@@ -1486,10 +1502,10 @@ var _Bar = class _Bar {
1486
1502
  this._resizeListener = null;
1487
1503
  }
1488
1504
  this.clear();
1489
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._successColor, "\u2714")}${string ? ` ${string}` : ""}
1505
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._successColor, g)}${string ? ` ${string}` : ""}
1490
1506
  `);
1491
1507
  } else {
1492
- process.stdout.write(`${this._glyphs ? `\u2714${string ? ` ${string}` : ""}` : string ?? ""}
1508
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1493
1509
  `);
1494
1510
  }
1495
1511
  return this;
@@ -1497,9 +1513,9 @@ var _Bar = class _Bar {
1497
1513
  fail(string) {
1498
1514
  this.running = false;
1499
1515
  if (_Bar.current === this) _Bar.current = null;
1516
+ const g = this._glyphs ? "\u2716" : "X";
1500
1517
  if (this._isManaged) {
1501
- const glyph = this._glyphs ? colorText(this._failColor, "\u2716") + " " : "";
1502
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1518
+ this._managedFinalLine = `${colorText(this._failColor, g)}${string ? ` ${string}` : ""}`;
1503
1519
  return this;
1504
1520
  }
1505
1521
  this._cleanupDeregister?.();
@@ -1510,10 +1526,10 @@ var _Bar = class _Bar {
1510
1526
  this._resizeListener = null;
1511
1527
  }
1512
1528
  this.clear();
1513
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._failColor, "\u2716")}${string ? ` ${string}` : ""}
1529
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._failColor, g)}${string ? ` ${string}` : ""}
1514
1530
  `);
1515
1531
  } else {
1516
- process.stdout.write(`${this._glyphs ? `\u2716${string ? ` ${string}` : ""}` : string ?? ""}
1532
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1517
1533
  `);
1518
1534
  }
1519
1535
  return this;
@@ -1521,9 +1537,9 @@ var _Bar = class _Bar {
1521
1537
  warn(string) {
1522
1538
  this.running = false;
1523
1539
  if (_Bar.current === this) _Bar.current = null;
1540
+ const g = this._glyphs ? "\u26A0" : "!";
1524
1541
  if (this._isManaged) {
1525
- const glyph = this._glyphs ? colorText(this._warnColor, "\u26A0") + " " : "";
1526
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1542
+ this._managedFinalLine = `${colorText(this._warnColor, g)}${string ? ` ${string}` : ""}`;
1527
1543
  return this;
1528
1544
  }
1529
1545
  this._cleanupDeregister?.();
@@ -1534,10 +1550,10 @@ var _Bar = class _Bar {
1534
1550
  this._resizeListener = null;
1535
1551
  }
1536
1552
  this.clear();
1537
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._warnColor, "\u26A0")}${string ? ` ${string}` : ""}
1553
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._warnColor, g)}${string ? ` ${string}` : ""}
1538
1554
  `);
1539
1555
  } else {
1540
- process.stdout.write(`${this._glyphs ? `\u26A0${string ? ` ${string}` : ""}` : string ?? ""}
1556
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1541
1557
  `);
1542
1558
  }
1543
1559
  return this;
@@ -1545,9 +1561,9 @@ var _Bar = class _Bar {
1545
1561
  info(string) {
1546
1562
  this.running = false;
1547
1563
  if (_Bar.current === this) _Bar.current = null;
1564
+ const g = this._glyphs ? "\u2139" : "i";
1548
1565
  if (this._isManaged) {
1549
- const glyph = this._glyphs ? colorText(this._infoColor, "\u2139") + " " : "";
1550
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1566
+ this._managedFinalLine = `${colorText(this._infoColor, g)}${string ? ` ${string}` : ""}`;
1551
1567
  return this;
1552
1568
  }
1553
1569
  this._cleanupDeregister?.();
@@ -1558,10 +1574,10 @@ var _Bar = class _Bar {
1558
1574
  this._resizeListener = null;
1559
1575
  }
1560
1576
  this.clear();
1561
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._infoColor, "\u2139")}${string ? ` ${string}` : ""}
1577
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._infoColor, g)}${string ? ` ${string}` : ""}
1562
1578
  `);
1563
1579
  } else {
1564
- process.stdout.write(`${this._glyphs ? `\u2139${string ? ` ${string}` : ""}` : string ?? ""}
1580
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1565
1581
  `);
1566
1582
  }
1567
1583
  return this;
@@ -2204,28 +2220,29 @@ var Log = class {
2204
2220
  this._failColor = options.failColor ?? RED;
2205
2221
  this._warnColor = options.warnColor ?? YELLOW;
2206
2222
  this._infoColor = options.infoColor ?? BLUE;
2207
- this._glyphs = options.glyphs ?? true;
2223
+ this._glyphs = options.glyphs ?? config.glyphs;
2208
2224
  }
2209
- write(glyph, color, message) {
2225
+ write(unicode, ascii, color, message) {
2226
+ const glyph = this._glyphs ? unicode : ascii;
2210
2227
  if (process.stdout.isTTY) {
2211
2228
  process.stdout.write(`${colorText(color, glyph)}${message ? ` ${message}` : ""}
2212
2229
  `);
2213
2230
  } else {
2214
- process.stdout.write(`${this._glyphs ? `${glyph}${message ? ` ${message}` : ""}` : message ?? ""}
2231
+ process.stdout.write(`${glyph}${message ? ` ${message}` : ""}
2215
2232
  `);
2216
2233
  }
2217
2234
  }
2218
2235
  succeed(message) {
2219
- this.write("\u2714", this._successColor, message);
2236
+ this.write("\u2714", "+", this._successColor, message);
2220
2237
  }
2221
2238
  fail(message) {
2222
- this.write("\u2716", this._failColor, message);
2239
+ this.write("\u2716", "X", this._failColor, message);
2223
2240
  }
2224
2241
  warn(message) {
2225
- this.write("\u26A0", this._warnColor, message);
2242
+ this.write("\u26A0", "!", this._warnColor, message);
2226
2243
  }
2227
2244
  info(message) {
2228
- this.write("\u2139", this._infoColor, message);
2245
+ this.write("\u2139", "i", this._infoColor, message);
2229
2246
  }
2230
2247
  data(value, options) {
2231
2248
  process.stdout.write(`${markup(value, options)}
@@ -2302,7 +2319,6 @@ var MultiBar = class {
2302
2319
  };
2303
2320
 
2304
2321
  // src/models/MultiSelect.ts
2305
- var CLEAR_LINE2 = "\x1B[2K";
2306
2322
  var CURSOR_UP3 = (n) => `\x1B[${n}A`;
2307
2323
  var DIM2 = "\x1B[2m";
2308
2324
  var MultiSelect = class {
@@ -2425,21 +2441,17 @@ var MultiSelect = class {
2425
2441
  clearInterval(timer);
2426
2442
  timer = null;
2427
2443
  }
2428
- if (lastDrawnLines > 0) process.stdout.write(CURSOR_UP3(lastDrawnLines));
2429
- process.stdout.write("\x1B[0J");
2444
+ process.stdout.write(CURSOR_UP3(lastDrawnLines + 1));
2445
+ process.stdout.write("\r\x1B[0J");
2430
2446
  process.stdout.write(ENABLE_WRAP);
2431
- const bulletWidth = stringLength(this.checkedPrefix) + 1;
2432
- for (let i = 0; i < items.length; i++) {
2433
- const item = items[i];
2434
- const bullet = checked.has(i) ? `${colorText(this.promptColor, this.checkedPrefix)} ` : " ".repeat(bulletWidth);
2435
- process.stdout.write(`\r${indent}${bullet}${item.label}
2447
+ const selectedItems = items.filter((_, i) => checked.has(i));
2448
+ const display = result !== null && selectedItems.length > 0 ? selectedItems.map((i) => i.label).join(", ") : "\u2014";
2449
+ process.stdout.write(`${glyph}${prompt}: ${display}
2436
2450
  `);
2437
- }
2438
- process.stdout.write(`\r${CLEAR_LINE2}`);
2439
2451
  process.stdin.setRawMode(false);
2440
2452
  process.stdin.pause();
2441
2453
  process.stdin.removeListener("data", onKey);
2442
- process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
2454
+ process.stdout.write(SHOW_CURSOR);
2443
2455
  resolve(result);
2444
2456
  };
2445
2457
  if (this._parsedColors.length >= 2) {
@@ -2566,7 +2578,7 @@ async function multiSelect(prompt, items, options) {
2566
2578
  // src/utils/truncate.ts
2567
2579
  var ANSI_RE = /\x1b\[[0-9;]*[A-Za-z]/g;
2568
2580
  var RESET2 = "\x1B[0m";
2569
- function truncate(str, maxLength, suffix = "\u2026") {
2581
+ function truncate(str, maxLength, suffix = config.glyphs ? "\u2026" : "...") {
2570
2582
  if (stringLength(str) <= maxLength) return str;
2571
2583
  const hasAnsi = ANSI_RE.test(str);
2572
2584
  ANSI_RE.lastIndex = 0;
package/dist/index.mjs CHANGED
@@ -5,7 +5,9 @@ var __export = (target, all) => {
5
5
  };
6
6
 
7
7
  // src/config.ts
8
- var isLegacyTerminal = process.env.TERM === "dumb" || process.platform === "win32" && !process.env.WT_SESSION && process.env.TERM_PROGRAM !== "vscode" && process.env.TERM_PROGRAM !== "Hyper";
8
+ var locale = process.env.LC_ALL ?? process.env.LANG ?? "";
9
+ var isNonUtf8Locale = locale !== "" && !/utf-?8/i.test(locale);
10
+ var isLegacyTerminal = !!process.env.TERMKIT_ASCII || process.env.TERM === "dumb" || isNonUtf8Locale || process.platform === "win32" && !process.env.WT_SESSION && process.env.TERM_PROGRAM !== "vscode" && process.env.TERM_PROGRAM !== "Hyper";
9
11
  var config = {
10
12
  color: "cyan",
11
13
  pulseColors: ["#06b6d4", "#67e8f9"],
@@ -578,7 +580,7 @@ var Select = class {
578
580
  process.stdin.removeListener("data", onKey);
579
581
  process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
580
582
  });
581
- const cleanup = () => {
583
+ const cleanup = (selectedLabel) => {
582
584
  deregisterCleanup();
583
585
  if (timer) {
584
586
  clearInterval(timer);
@@ -587,7 +589,12 @@ var Select = class {
587
589
  process.stdin.setRawMode(false);
588
590
  process.stdin.pause();
589
591
  process.stdin.removeListener("data", onKey);
590
- process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
592
+ process.stdout.write(CURSOR_UP(lastDrawnLines + 1));
593
+ process.stdout.write("\r\x1B[0J");
594
+ process.stdout.write(ENABLE_WRAP);
595
+ process.stdout.write(`${glyph}${prompt}: ${selectedLabel ?? this.skipLabel}
596
+ `);
597
+ process.stdout.write(SHOW_CURSOR);
591
598
  };
592
599
  if (this._parsedColors.length >= 2) {
593
600
  timer = setInterval(() => {
@@ -609,10 +616,19 @@ var Select = class {
609
616
  selectedIndex = (selectedIndex + 1) % allItems.length;
610
617
  renderList(true);
611
618
  } else if (str === "\r" || str === "\n") {
612
- cleanup();
613
- resolve(selectedIndex === filtered.length ? null : filtered[selectedIndex] ?? null);
619
+ const result = selectedIndex === filtered.length ? null : filtered[selectedIndex] ?? null;
620
+ cleanup(result?.label ?? null);
621
+ resolve(result);
614
622
  } else if (str === "") {
615
- cleanup();
623
+ deregisterCleanup();
624
+ if (timer) {
625
+ clearInterval(timer);
626
+ timer = null;
627
+ }
628
+ process.stdin.setRawMode(false);
629
+ process.stdin.pause();
630
+ process.stdin.removeListener("data", onKey);
631
+ process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
616
632
  process.exit(130);
617
633
  } else if (this.searchEnabled) {
618
634
  if (str === "\x7F" || str === "\b") {
@@ -1260,7 +1276,7 @@ var _Bar = class _Bar {
1260
1276
  this._failColor = opts.failColor ?? RED;
1261
1277
  this._warnColor = opts.warnColor ?? YELLOW;
1262
1278
  this._infoColor = opts.infoColor ?? BLUE;
1263
- this._glyphs = opts.glyphs ?? true;
1279
+ this._glyphs = opts.glyphs ?? config.glyphs;
1264
1280
  this._showRate = opts.showRate ?? false;
1265
1281
  this._showEta = opts.showEta ?? false;
1266
1282
  this._rateUnit = opts.rateUnit ?? "";
@@ -1412,9 +1428,9 @@ var _Bar = class _Bar {
1412
1428
  succeed(string) {
1413
1429
  this.running = false;
1414
1430
  if (_Bar.current === this) _Bar.current = null;
1431
+ const g = this._glyphs ? "\u2714" : "+";
1415
1432
  if (this._isManaged) {
1416
- const glyph = this._glyphs ? colorText(this._successColor, "\u2714") + " " : "";
1417
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1433
+ this._managedFinalLine = `${colorText(this._successColor, g)}${string ? ` ${string}` : ""}`;
1418
1434
  return this;
1419
1435
  }
1420
1436
  this._cleanupDeregister?.();
@@ -1425,10 +1441,10 @@ var _Bar = class _Bar {
1425
1441
  this._resizeListener = null;
1426
1442
  }
1427
1443
  this.clear();
1428
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._successColor, "\u2714")}${string ? ` ${string}` : ""}
1444
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._successColor, g)}${string ? ` ${string}` : ""}
1429
1445
  `);
1430
1446
  } else {
1431
- process.stdout.write(`${this._glyphs ? `\u2714${string ? ` ${string}` : ""}` : string ?? ""}
1447
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1432
1448
  `);
1433
1449
  }
1434
1450
  return this;
@@ -1436,9 +1452,9 @@ var _Bar = class _Bar {
1436
1452
  fail(string) {
1437
1453
  this.running = false;
1438
1454
  if (_Bar.current === this) _Bar.current = null;
1455
+ const g = this._glyphs ? "\u2716" : "X";
1439
1456
  if (this._isManaged) {
1440
- const glyph = this._glyphs ? colorText(this._failColor, "\u2716") + " " : "";
1441
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1457
+ this._managedFinalLine = `${colorText(this._failColor, g)}${string ? ` ${string}` : ""}`;
1442
1458
  return this;
1443
1459
  }
1444
1460
  this._cleanupDeregister?.();
@@ -1449,10 +1465,10 @@ var _Bar = class _Bar {
1449
1465
  this._resizeListener = null;
1450
1466
  }
1451
1467
  this.clear();
1452
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._failColor, "\u2716")}${string ? ` ${string}` : ""}
1468
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._failColor, g)}${string ? ` ${string}` : ""}
1453
1469
  `);
1454
1470
  } else {
1455
- process.stdout.write(`${this._glyphs ? `\u2716${string ? ` ${string}` : ""}` : string ?? ""}
1471
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1456
1472
  `);
1457
1473
  }
1458
1474
  return this;
@@ -1460,9 +1476,9 @@ var _Bar = class _Bar {
1460
1476
  warn(string) {
1461
1477
  this.running = false;
1462
1478
  if (_Bar.current === this) _Bar.current = null;
1479
+ const g = this._glyphs ? "\u26A0" : "!";
1463
1480
  if (this._isManaged) {
1464
- const glyph = this._glyphs ? colorText(this._warnColor, "\u26A0") + " " : "";
1465
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1481
+ this._managedFinalLine = `${colorText(this._warnColor, g)}${string ? ` ${string}` : ""}`;
1466
1482
  return this;
1467
1483
  }
1468
1484
  this._cleanupDeregister?.();
@@ -1473,10 +1489,10 @@ var _Bar = class _Bar {
1473
1489
  this._resizeListener = null;
1474
1490
  }
1475
1491
  this.clear();
1476
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._warnColor, "\u26A0")}${string ? ` ${string}` : ""}
1492
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._warnColor, g)}${string ? ` ${string}` : ""}
1477
1493
  `);
1478
1494
  } else {
1479
- process.stdout.write(`${this._glyphs ? `\u26A0${string ? ` ${string}` : ""}` : string ?? ""}
1495
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1480
1496
  `);
1481
1497
  }
1482
1498
  return this;
@@ -1484,9 +1500,9 @@ var _Bar = class _Bar {
1484
1500
  info(string) {
1485
1501
  this.running = false;
1486
1502
  if (_Bar.current === this) _Bar.current = null;
1503
+ const g = this._glyphs ? "\u2139" : "i";
1487
1504
  if (this._isManaged) {
1488
- const glyph = this._glyphs ? colorText(this._infoColor, "\u2139") + " " : "";
1489
- this._managedFinalLine = `${glyph}${string ?? ""}`;
1505
+ this._managedFinalLine = `${colorText(this._infoColor, g)}${string ? ` ${string}` : ""}`;
1490
1506
  return this;
1491
1507
  }
1492
1508
  this._cleanupDeregister?.();
@@ -1497,10 +1513,10 @@ var _Bar = class _Bar {
1497
1513
  this._resizeListener = null;
1498
1514
  }
1499
1515
  this.clear();
1500
- process.stdout.write(`${SHOW_CURSOR}${colorText(this._infoColor, "\u2139")}${string ? ` ${string}` : ""}
1516
+ process.stdout.write(`${SHOW_CURSOR}${colorText(this._infoColor, g)}${string ? ` ${string}` : ""}
1501
1517
  `);
1502
1518
  } else {
1503
- process.stdout.write(`${this._glyphs ? `\u2139${string ? ` ${string}` : ""}` : string ?? ""}
1519
+ process.stdout.write(`${g}${string ? ` ${string}` : ""}
1504
1520
  `);
1505
1521
  }
1506
1522
  return this;
@@ -2143,28 +2159,29 @@ var Log = class {
2143
2159
  this._failColor = options.failColor ?? RED;
2144
2160
  this._warnColor = options.warnColor ?? YELLOW;
2145
2161
  this._infoColor = options.infoColor ?? BLUE;
2146
- this._glyphs = options.glyphs ?? true;
2162
+ this._glyphs = options.glyphs ?? config.glyphs;
2147
2163
  }
2148
- write(glyph, color, message) {
2164
+ write(unicode, ascii, color, message) {
2165
+ const glyph = this._glyphs ? unicode : ascii;
2149
2166
  if (process.stdout.isTTY) {
2150
2167
  process.stdout.write(`${colorText(color, glyph)}${message ? ` ${message}` : ""}
2151
2168
  `);
2152
2169
  } else {
2153
- process.stdout.write(`${this._glyphs ? `${glyph}${message ? ` ${message}` : ""}` : message ?? ""}
2170
+ process.stdout.write(`${glyph}${message ? ` ${message}` : ""}
2154
2171
  `);
2155
2172
  }
2156
2173
  }
2157
2174
  succeed(message) {
2158
- this.write("\u2714", this._successColor, message);
2175
+ this.write("\u2714", "+", this._successColor, message);
2159
2176
  }
2160
2177
  fail(message) {
2161
- this.write("\u2716", this._failColor, message);
2178
+ this.write("\u2716", "X", this._failColor, message);
2162
2179
  }
2163
2180
  warn(message) {
2164
- this.write("\u26A0", this._warnColor, message);
2181
+ this.write("\u26A0", "!", this._warnColor, message);
2165
2182
  }
2166
2183
  info(message) {
2167
- this.write("\u2139", this._infoColor, message);
2184
+ this.write("\u2139", "i", this._infoColor, message);
2168
2185
  }
2169
2186
  data(value, options) {
2170
2187
  process.stdout.write(`${markup(value, options)}
@@ -2241,7 +2258,6 @@ var MultiBar = class {
2241
2258
  };
2242
2259
 
2243
2260
  // src/models/MultiSelect.ts
2244
- var CLEAR_LINE2 = "\x1B[2K";
2245
2261
  var CURSOR_UP3 = (n) => `\x1B[${n}A`;
2246
2262
  var DIM2 = "\x1B[2m";
2247
2263
  var MultiSelect = class {
@@ -2364,21 +2380,17 @@ var MultiSelect = class {
2364
2380
  clearInterval(timer);
2365
2381
  timer = null;
2366
2382
  }
2367
- if (lastDrawnLines > 0) process.stdout.write(CURSOR_UP3(lastDrawnLines));
2368
- process.stdout.write("\x1B[0J");
2383
+ process.stdout.write(CURSOR_UP3(lastDrawnLines + 1));
2384
+ process.stdout.write("\r\x1B[0J");
2369
2385
  process.stdout.write(ENABLE_WRAP);
2370
- const bulletWidth = stringLength(this.checkedPrefix) + 1;
2371
- for (let i = 0; i < items.length; i++) {
2372
- const item = items[i];
2373
- const bullet = checked.has(i) ? `${colorText(this.promptColor, this.checkedPrefix)} ` : " ".repeat(bulletWidth);
2374
- process.stdout.write(`\r${indent}${bullet}${item.label}
2386
+ const selectedItems = items.filter((_, i) => checked.has(i));
2387
+ const display = result !== null && selectedItems.length > 0 ? selectedItems.map((i) => i.label).join(", ") : "\u2014";
2388
+ process.stdout.write(`${glyph}${prompt}: ${display}
2375
2389
  `);
2376
- }
2377
- process.stdout.write(`\r${CLEAR_LINE2}`);
2378
2390
  process.stdin.setRawMode(false);
2379
2391
  process.stdin.pause();
2380
2392
  process.stdin.removeListener("data", onKey);
2381
- process.stdout.write(ENABLE_WRAP + SHOW_CURSOR);
2393
+ process.stdout.write(SHOW_CURSOR);
2382
2394
  resolve(result);
2383
2395
  };
2384
2396
  if (this._parsedColors.length >= 2) {
@@ -2505,7 +2517,7 @@ async function multiSelect(prompt, items, options) {
2505
2517
  // src/utils/truncate.ts
2506
2518
  var ANSI_RE = /\x1b\[[0-9;]*[A-Za-z]/g;
2507
2519
  var RESET2 = "\x1B[0m";
2508
- function truncate(str, maxLength, suffix = "\u2026") {
2520
+ function truncate(str, maxLength, suffix = config.glyphs ? "\u2026" : "...") {
2509
2521
  if (stringLength(str) <= maxLength) return str;
2510
2522
  const hasAnsi = ANSI_RE.test(str);
2511
2523
  ANSI_RE.lastIndex = 0;
@@ -1 +1 @@
1
- {"version":3,"file":"Bar.d.ts","sourceRoot":"","sources":["../../src/models/Bar.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAA8K,MAAM,eAAe,CAAA;AAGrN,MAAM,MAAM,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,cAAc,CAAA;AAExD,MAAM,WAAW,UAAU;IACzB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,MAAM,CAAC,EAAE,MAAM,EAAE,CAAA;IACjB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAA;IACnB,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,UAAU,CAAC,EAAE,MAAM,IAAI,CAAA;IACvB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;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G,IAAI;IAI5B,IAAI,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI5B,IAAI,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI5B,IAAI,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,IAAI;CAGrD;AAED,eAAO,MAAM,GAAG,KAAY,CAAA"}
1
+ {"version":3,"file":"Log.d.ts","sourceRoot":"","sources":["../../src/models/Log.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,KAAK,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAG5D,MAAM,WAAW,UAAU;IACzB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,OAAO,CAAA;CACjB;AAED,qBAAa,GAAG;IACd,OAAO,CAAC,aAAa,CAAQ;IAC7B,OAAO,CAAC,UAAU,CAAQ;IAC1B,OAAO,CAAC,UAAU,CAAQ;IAC1B,OAAO,CAAC,UAAU,CAAQ;IAC1B,OAAO,CAAC,OAAO,CAAS;gBAEZ,OAAO,GAAE,UAAe;IAQpC,OAAO,CAAC,KAAK;IASb,OAAO,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI/B,IAAI,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI5B,IAAI,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI5B,IAAI,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI;IAI5B,IAAI,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,IAAI;CAGrD;AAED,eAAO,MAAM,GAAG,KAAY,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"MultiSelect.d.ts","sourceRoot":"","sources":["../../src/models/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AM,CAAC,CAAC,SAAS,UAAU,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,CAEzH"}
@@ -1 +1 @@
1
- {"version":3,"file":"truncate.d.ts","sourceRoot":"","sources":["../../src/utils/truncate.ts"],"names":[],"mappings":"AAKA,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,SAAM,GAAG,MAAM,CAsB7E"}
1
+ {"version":3,"file":"truncate.d.ts","sourceRoot":"","sources":["../../src/utils/truncate.ts"],"names":[],"mappings":"AAOA,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,SAA8B,GAAG,MAAM,CAsBrG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "termkit",
3
- "version": "2.4.0",
3
+ "version": "2.4.2",
4
4
  "description": "Node.js terminal toolkit with CLI commands, progress bars, charts, tables, styled markup, prompts, and text utilities",
5
5
  "keywords": [
6
6
  "animation",