storybook 10.1.0-beta.2 → 10.1.0-beta.4

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 (68) hide show
  1. package/dist/_browser-chunks/{chunk-L4RMQ7D7.js → chunk-BRX2HXH7.js} +75 -5
  2. package/dist/_node-chunks/{builder-manager-DE5CZGPU.js → builder-manager-T3A7QLUO.js} +26 -593
  3. package/dist/_node-chunks/{camelcase-3GPWEIYB.js → camelcase-WMMYRUH4.js} +7 -7
  4. package/dist/_node-chunks/{chunk-ZH4F5JWQ.js → chunk-3MVB5IZX.js} +28 -24
  5. package/dist/_node-chunks/{chunk-RZEXP6OF.js → chunk-5DEFF2GB.js} +7 -7
  6. package/dist/_node-chunks/{chunk-3GUEJ3O3.js → chunk-67VVNDJJ.js} +6 -6
  7. package/dist/_node-chunks/{chunk-RSFKUYLE.js → chunk-C6RLDV2P.js} +8 -8
  8. package/dist/_node-chunks/{chunk-77QRXLGA.js → chunk-CM44JL5Z.js} +6 -6
  9. package/dist/_node-chunks/{chunk-HGDN3STX.js → chunk-CSFSQ2I4.js} +7 -7
  10. package/dist/_node-chunks/{chunk-45XWOXXM.js → chunk-EFN4RLWH.js} +7 -7
  11. package/dist/_node-chunks/{chunk-D2CQN4LQ.js → chunk-EFTR6VSG.js} +9 -9
  12. package/dist/_node-chunks/{chunk-UWKUW2OJ.js → chunk-EJPOXNSG.js} +15 -15
  13. package/dist/_node-chunks/{chunk-6T6VTXDE.js → chunk-HDMHX5QM.js} +7 -7
  14. package/dist/_node-chunks/{chunk-EXJNST6P.js → chunk-HT32VUX7.js} +7 -7
  15. package/dist/_node-chunks/chunk-IQFN7VY4.js +23 -0
  16. package/dist/_node-chunks/{chunk-YZEOU7D5.js → chunk-JYAXWHGH.js} +9 -9
  17. package/dist/_node-chunks/chunk-K7U3BSTR.js +61 -0
  18. package/dist/_node-chunks/{chunk-NOLZUVQN.js → chunk-KAVR7KJP.js} +287 -281
  19. package/dist/_node-chunks/{chunk-HFPMBHAF.js → chunk-KI6KY2ZN.js} +13 -13
  20. package/dist/_node-chunks/{chunk-Z7F5CZXW.js → chunk-NORFPLB6.js} +7 -7
  21. package/dist/_node-chunks/{chunk-ODJGHT54.js → chunk-PMZEJJNX.js} +7 -7
  22. package/dist/_node-chunks/{chunk-F4HHDWJV.js → chunk-RSJK2D7X.js} +6 -6
  23. package/dist/_node-chunks/{chunk-PQF6TGKN.js → chunk-TBYOSPAV.js} +6 -6
  24. package/dist/_node-chunks/{chunk-KIW5GZKQ.js → chunk-TC7X5DN2.js} +10 -10
  25. package/dist/_node-chunks/{chunk-43AQPYQJ.js → chunk-TCLOOFNE.js} +7 -7
  26. package/dist/_node-chunks/{chunk-QAX2QIAO.js → chunk-VN7SAKM4.js} +6 -6
  27. package/dist/_node-chunks/{chunk-3FVKDIQ7.js → chunk-VW25O2YM.js} +6 -6
  28. package/dist/_node-chunks/{chunk-4CHMPSHM.js → chunk-WGBDDI6W.js} +642 -639
  29. package/dist/_node-chunks/chunk-YN3C74EA.js +18 -0
  30. package/dist/_node-chunks/{chunk-INMOMYVB.js → chunk-YTTOTUWC.js} +6 -6
  31. package/dist/_node-chunks/{chunk-PJAOEV2K.js → chunk-YZ3XRP4N.js} +6 -6
  32. package/dist/_node-chunks/{dist-RFQRGJD5.js → dist-L6XLFQOU.js} +9 -9
  33. package/dist/_node-chunks/{globby-WIMKMN5Q.js → globby-7IXLXFEA.js} +9 -9
  34. package/dist/_node-chunks/{lib-OBEY3MUM.js → lib-T5L2ZSAG.js} +7 -7
  35. package/dist/_node-chunks/{mdx-N42X6CFJ-7XA7LOVG.js → mdx-N42X6CFJ-GOOKUTSA.js} +8 -8
  36. package/dist/_node-chunks/{p-limit-VII3MYEU.js → p-limit-7GKATDEW.js} +7 -7
  37. package/dist/babel/index.js +10 -10
  38. package/dist/bin/core.js +12 -12
  39. package/dist/bin/dispatcher.js +11 -11
  40. package/dist/bin/loader.js +9 -9
  41. package/dist/cli/index.d.ts +1 -2
  42. package/dist/cli/index.js +18 -18
  43. package/dist/common/index.d.ts +553 -560
  44. package/dist/common/index.js +19 -21
  45. package/dist/components/index.js +35 -29
  46. package/dist/core-server/index.js +33 -33
  47. package/dist/core-server/presets/common-manager.js +74 -108
  48. package/dist/core-server/presets/common-override-preset.js +9 -9
  49. package/dist/core-server/presets/common-preset.js +25 -25
  50. package/dist/csf-tools/index.js +9 -9
  51. package/dist/manager/globals-runtime.js +142 -65
  52. package/dist/manager/runtime.js +139 -115
  53. package/dist/manager-api/index.js +1 -1
  54. package/dist/mocking-utils/index.js +8 -8
  55. package/dist/node-logger/index.d.ts +3 -1
  56. package/dist/node-logger/index.js +9 -9
  57. package/dist/preview-api/index.d.ts +68 -67
  58. package/dist/server-errors.js +11 -11
  59. package/dist/telemetry/index.js +23 -23
  60. package/dist/theming/create.d.ts +1 -1
  61. package/dist/theming/create.js +1 -1
  62. package/dist/theming/index.d.ts +65 -2
  63. package/dist/theming/index.js +6 -3
  64. package/dist/types/index.d.ts +1 -1
  65. package/package.json +2 -3
  66. package/dist/_node-chunks/chunk-CEFT3TLW.js +0 -18
  67. package/dist/_node-chunks/chunk-HG5BSY5V.js +0 -23
  68. package/dist/_node-chunks/chunk-Y35QWPHB.js +0 -61
@@ -1,23 +1,23 @@
1
- import CJS_COMPAT_NODE_URL_hgecnnw0nrt from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_hgecnnw0nrt from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_hgecnnw0nrt from "node:module";
1
+ import CJS_COMPAT_NODE_URL_a6gceaz3qeh from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_a6gceaz3qeh from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_a6gceaz3qeh from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_hgecnnw0nrt.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_hgecnnw0nrt.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_hgecnnw0nrt.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_a6gceaz3qeh.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_a6gceaz3qeh.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_a6gceaz3qeh.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
11
11
  // ------------------------------------------------------------
12
12
  import {
13
13
  require_picocolors
14
- } from "./chunk-43AQPYQJ.js";
14
+ } from "./chunk-TCLOOFNE.js";
15
15
  import {
16
16
  __commonJS,
17
17
  __export,
18
18
  __require,
19
19
  __toESM
20
- } from "./chunk-3FVKDIQ7.js";
20
+ } from "./chunk-VW25O2YM.js";
21
21
 
22
22
  // ../node_modules/are-we-there-yet/lib/tracker-base.js
23
23
  var require_tracker_base = __commonJS({
@@ -205,8 +205,8 @@ var require_console_control_strings = __commonJS({
205
205
  exports.eraseLine = function() {
206
206
  return prefix + "K";
207
207
  };
208
- exports.goto = function(x2, y2) {
209
- return prefix + y2 + ";" + x2 + "H";
208
+ exports.goto = function(x3, y2) {
209
+ return prefix + y2 + ";" + x3 + "H";
210
210
  };
211
211
  exports.gotoSOL = function() {
212
212
  return "\r";
@@ -406,14 +406,14 @@ var require_aproba = __commonJS({
406
406
  }
407
407
  var types = {
408
408
  "*": { label: "any", check: () => !0 },
409
- A: { label: "array", check: (_) => Array.isArray(_) || isArguments(_) },
410
- S: { label: "string", check: (_) => typeof _ == "string" },
411
- N: { label: "number", check: (_) => typeof _ == "number" },
412
- F: { label: "function", check: (_) => typeof _ == "function" },
413
- O: { label: "object", check: (_) => typeof _ == "object" && _ != null && !types.A.check(_) && !types.E.check(_) },
414
- B: { label: "boolean", check: (_) => typeof _ == "boolean" },
415
- E: { label: "error", check: (_) => _ instanceof Error },
416
- Z: { label: "null", check: (_) => _ == null }
409
+ A: { label: "array", check: (_2) => Array.isArray(_2) || isArguments(_2) },
410
+ S: { label: "string", check: (_2) => typeof _2 == "string" },
411
+ N: { label: "number", check: (_2) => typeof _2 == "number" },
412
+ F: { label: "function", check: (_2) => typeof _2 == "function" },
413
+ O: { label: "object", check: (_2) => typeof _2 == "object" && _2 != null && !types.A.check(_2) && !types.E.check(_2) },
414
+ B: { label: "boolean", check: (_2) => typeof _2 == "boolean" },
415
+ E: { label: "error", check: (_2) => _2 instanceof Error },
416
+ Z: { label: "null", check: (_2) => _2 == null }
417
417
  };
418
418
  function addSchema(schema, arity) {
419
419
  let group = arity[schema.length] = arity[schema.length] || [];
@@ -443,7 +443,7 @@ var require_aproba = __commonJS({
443
443
  return typeCheck(args[ii]);
444
444
  });
445
445
  if (!newMatching.length) {
446
- let labels = matching.map((_) => types[_[ii]].label).filter((_) => _ != null);
446
+ let labels = matching.map((_2) => types[_2[ii]].label).filter((_2) => _2 != null);
447
447
  throw invalidType(ii, labels, args[ii]);
448
448
  }
449
449
  matching = newMatching;
@@ -829,7 +829,7 @@ var require_cjs = __commonJS({
829
829
  Object.defineProperty(exports, "signals", { enumerable: !0, get: function() {
830
830
  return signals_js_1.signals;
831
831
  } });
832
- var processOk = (process3) => !!process3 && typeof process3 == "object" && typeof process3.removeListener == "function" && typeof process3.emit == "function" && typeof process3.reallyExit == "function" && typeof process3.listeners == "function" && typeof process3.kill == "function" && typeof process3.pid == "number" && typeof process3.on == "function", kExitEmitter = Symbol.for("signal-exit emitter"), global2 = globalThis, ObjectDefineProperty = Object.defineProperty.bind(Object), Emitter = class {
832
+ var processOk = (process3) => !!process3 && typeof process3 == "object" && typeof process3.removeListener == "function" && typeof process3.emit == "function" && typeof process3.reallyExit == "function" && typeof process3.listeners == "function" && typeof process3.kill == "function" && typeof process3.pid == "number" && typeof process3.on == "function", kExitEmitter = Symbol.for("signal-exit emitter"), global = globalThis, ObjectDefineProperty = Object.defineProperty.bind(Object), Emitter = class {
833
833
  emitted = {
834
834
  afterExit: !1,
835
835
  exit: !1
@@ -841,9 +841,9 @@ var require_cjs = __commonJS({
841
841
  count = 0;
842
842
  id = Math.random();
843
843
  constructor() {
844
- if (global2[kExitEmitter])
845
- return global2[kExitEmitter];
846
- ObjectDefineProperty(global2, kExitEmitter, {
844
+ if (global[kExitEmitter])
845
+ return global[kExitEmitter];
846
+ ObjectDefineProperty(global, kExitEmitter, {
847
847
  value: this,
848
848
  writable: !1,
849
849
  enumerable: !1,
@@ -1434,8 +1434,8 @@ var require_log = __commonJS({
1434
1434
  log2.resume = function() {
1435
1435
  if (this._paused) {
1436
1436
  this._paused = !1;
1437
- var b2 = this._buffer;
1438
- this._buffer = [], b2.forEach(function(m) {
1437
+ var b = this._buffer;
1438
+ this._buffer = [], b.forEach(function(m) {
1439
1439
  this.emitLog(m);
1440
1440
  }, this), this.progressEnabled && this.gauge.enable();
1441
1441
  }
@@ -1557,12 +1557,12 @@ var require_src = __commonJS({
1557
1557
  "../node_modules/sisteransi/src/index.js"(exports, module) {
1558
1558
  "use strict";
1559
1559
  var cursor = {
1560
- to(x2, y2) {
1561
- return y2 ? `\x1B[${y2 + 1};${x2 + 1}H` : `\x1B[${x2 + 1}G`;
1560
+ to(x3, y2) {
1561
+ return y2 ? `\x1B[${y2 + 1};${x3 + 1}H` : `\x1B[${x3 + 1}G`;
1562
1562
  },
1563
- move(x2, y2) {
1563
+ move(x3, y2) {
1564
1564
  let ret = "";
1565
- return x2 < 0 ? ret += `\x1B[${-x2}D` : x2 > 0 && (ret += `\x1B[${x2}C`), y2 < 0 ? ret += `\x1B[${-y2}A` : y2 > 0 && (ret += `\x1B[${y2}B`), ret;
1565
+ return x3 < 0 ? ret += `\x1B[${-x3}D` : x3 > 0 && (ret += `\x1B[${x3}C`), y2 < 0 ? ret += `\x1B[${-y2}A` : y2 > 0 && (ret += `\x1B[${y2}B`), ret;
1566
1566
  },
1567
1567
  up: (count = 1) => `\x1B[${count}A`,
1568
1568
  down: (count = 1) => `\x1B[${count}B`,
@@ -1602,8 +1602,8 @@ var require_eastasianwidth = __commonJS({
1602
1602
  var eaw = {};
1603
1603
  typeof module > "u" ? window.eastasianwidth = eaw : module.exports = eaw;
1604
1604
  eaw.eastAsianWidth = function(character) {
1605
- var x2 = character.charCodeAt(0), y2 = character.length == 2 ? character.charCodeAt(1) : 0, codePoint = x2;
1606
- return 55296 <= x2 && x2 <= 56319 && 56320 <= y2 && y2 <= 57343 && (x2 &= 1023, y2 &= 1023, codePoint = x2 << 10 | y2, codePoint += 65536), codePoint == 12288 || 65281 <= codePoint && codePoint <= 65376 || 65504 <= codePoint && codePoint <= 65510 ? "F" : codePoint == 8361 || 65377 <= codePoint && codePoint <= 65470 || 65474 <= codePoint && codePoint <= 65479 || 65482 <= codePoint && codePoint <= 65487 || 65490 <= codePoint && codePoint <= 65495 || 65498 <= codePoint && codePoint <= 65500 || 65512 <= codePoint && codePoint <= 65518 ? "H" : 4352 <= codePoint && codePoint <= 4447 || 4515 <= codePoint && codePoint <= 4519 || 4602 <= codePoint && codePoint <= 4607 || 9001 <= codePoint && codePoint <= 9002 || 11904 <= codePoint && codePoint <= 11929 || 11931 <= codePoint && codePoint <= 12019 || 12032 <= codePoint && codePoint <= 12245 || 12272 <= codePoint && codePoint <= 12283 || 12289 <= codePoint && codePoint <= 12350 || 12353 <= codePoint && codePoint <= 12438 || 12441 <= codePoint && codePoint <= 12543 || 12549 <= codePoint && codePoint <= 12589 || 12593 <= codePoint && codePoint <= 12686 || 12688 <= codePoint && codePoint <= 12730 || 12736 <= codePoint && codePoint <= 12771 || 12784 <= codePoint && codePoint <= 12830 || 12832 <= codePoint && codePoint <= 12871 || 12880 <= codePoint && codePoint <= 13054 || 13056 <= codePoint && codePoint <= 19903 || 19968 <= codePoint && codePoint <= 42124 || 42128 <= codePoint && codePoint <= 42182 || 43360 <= codePoint && codePoint <= 43388 || 44032 <= codePoint && codePoint <= 55203 || 55216 <= codePoint && codePoint <= 55238 || 55243 <= codePoint && codePoint <= 55291 || 63744 <= codePoint && codePoint <= 64255 || 65040 <= codePoint && codePoint <= 65049 || 65072 <= codePoint && codePoint <= 65106 || 65108 <= codePoint && codePoint <= 65126 || 65128 <= codePoint && codePoint <= 65131 || 110592 <= codePoint && codePoint <= 110593 || 127488 <= codePoint && codePoint <= 127490 || 127504 <= codePoint && codePoint <= 127546 || 127552 <= codePoint && codePoint <= 127560 || 127568 <= codePoint && codePoint <= 127569 || 131072 <= codePoint && codePoint <= 194367 || 177984 <= codePoint && codePoint <= 196605 || 196608 <= codePoint && codePoint <= 262141 ? "W" : 32 <= codePoint && codePoint <= 126 || 162 <= codePoint && codePoint <= 163 || 165 <= codePoint && codePoint <= 166 || codePoint == 172 || codePoint == 175 || 10214 <= codePoint && codePoint <= 10221 || 10629 <= codePoint && codePoint <= 10630 ? "Na" : codePoint == 161 || codePoint == 164 || 167 <= codePoint && codePoint <= 168 || codePoint == 170 || 173 <= codePoint && codePoint <= 174 || 176 <= codePoint && codePoint <= 180 || 182 <= codePoint && codePoint <= 186 || 188 <= codePoint && codePoint <= 191 || codePoint == 198 || codePoint == 208 || 215 <= codePoint && codePoint <= 216 || 222 <= codePoint && codePoint <= 225 || codePoint == 230 || 232 <= codePoint && codePoint <= 234 || 236 <= codePoint && codePoint <= 237 || codePoint == 240 || 242 <= codePoint && codePoint <= 243 || 247 <= codePoint && codePoint <= 250 || codePoint == 252 || codePoint == 254 || codePoint == 257 || codePoint == 273 || codePoint == 275 || codePoint == 283 || 294 <= codePoint && codePoint <= 295 || codePoint == 299 || 305 <= codePoint && codePoint <= 307 || codePoint == 312 || 319 <= codePoint && codePoint <= 322 || codePoint == 324 || 328 <= codePoint && codePoint <= 331 || codePoint == 333 || 338 <= codePoint && codePoint <= 339 || 358 <= codePoint && codePoint <= 359 || codePoint == 363 || codePoint == 462 || codePoint == 464 || codePoint == 466 || codePoint == 468 || codePoint == 470 || codePoint == 472 || codePoint == 474 || codePoint == 476 || codePoint == 593 || codePoint == 609 || codePoint == 708 || codePoint == 711 || 713 <= codePoint && codePoint <= 715 || codePoint == 717 || codePoint == 720 || 728 <= codePoint && codePoint <= 731 || codePoint == 733 || codePoint == 735 || 768 <= codePoint && codePoint <= 879 || 913 <= codePoint && codePoint <= 929 || 931 <= codePoint && codePoint <= 937 || 945 <= codePoint && codePoint <= 961 || 963 <= codePoint && codePoint <= 969 || codePoint == 1025 || 1040 <= codePoint && codePoint <= 1103 || codePoint == 1105 || codePoint == 8208 || 8211 <= codePoint && codePoint <= 8214 || 8216 <= codePoint && codePoint <= 8217 || 8220 <= codePoint && codePoint <= 8221 || 8224 <= codePoint && codePoint <= 8226 || 8228 <= codePoint && codePoint <= 8231 || codePoint == 8240 || 8242 <= codePoint && codePoint <= 8243 || codePoint == 8245 || codePoint == 8251 || codePoint == 8254 || codePoint == 8308 || codePoint == 8319 || 8321 <= codePoint && codePoint <= 8324 || codePoint == 8364 || codePoint == 8451 || codePoint == 8453 || codePoint == 8457 || codePoint == 8467 || codePoint == 8470 || 8481 <= codePoint && codePoint <= 8482 || codePoint == 8486 || codePoint == 8491 || 8531 <= codePoint && codePoint <= 8532 || 8539 <= codePoint && codePoint <= 8542 || 8544 <= codePoint && codePoint <= 8555 || 8560 <= codePoint && codePoint <= 8569 || codePoint == 8585 || 8592 <= codePoint && codePoint <= 8601 || 8632 <= codePoint && codePoint <= 8633 || codePoint == 8658 || codePoint == 8660 || codePoint == 8679 || codePoint == 8704 || 8706 <= codePoint && codePoint <= 8707 || 8711 <= codePoint && codePoint <= 8712 || codePoint == 8715 || codePoint == 8719 || codePoint == 8721 || codePoint == 8725 || codePoint == 8730 || 8733 <= codePoint && codePoint <= 8736 || codePoint == 8739 || codePoint == 8741 || 8743 <= codePoint && codePoint <= 8748 || codePoint == 8750 || 8756 <= codePoint && codePoint <= 8759 || 8764 <= codePoint && codePoint <= 8765 || codePoint == 8776 || codePoint == 8780 || codePoint == 8786 || 8800 <= codePoint && codePoint <= 8801 || 8804 <= codePoint && codePoint <= 8807 || 8810 <= codePoint && codePoint <= 8811 || 8814 <= codePoint && codePoint <= 8815 || 8834 <= codePoint && codePoint <= 8835 || 8838 <= codePoint && codePoint <= 8839 || codePoint == 8853 || codePoint == 8857 || codePoint == 8869 || codePoint == 8895 || codePoint == 8978 || 9312 <= codePoint && codePoint <= 9449 || 9451 <= codePoint && codePoint <= 9547 || 9552 <= codePoint && codePoint <= 9587 || 9600 <= codePoint && codePoint <= 9615 || 9618 <= codePoint && codePoint <= 9621 || 9632 <= codePoint && codePoint <= 9633 || 9635 <= codePoint && codePoint <= 9641 || 9650 <= codePoint && codePoint <= 9651 || 9654 <= codePoint && codePoint <= 9655 || 9660 <= codePoint && codePoint <= 9661 || 9664 <= codePoint && codePoint <= 9665 || 9670 <= codePoint && codePoint <= 9672 || codePoint == 9675 || 9678 <= codePoint && codePoint <= 9681 || 9698 <= codePoint && codePoint <= 9701 || codePoint == 9711 || 9733 <= codePoint && codePoint <= 9734 || codePoint == 9737 || 9742 <= codePoint && codePoint <= 9743 || 9748 <= codePoint && codePoint <= 9749 || codePoint == 9756 || codePoint == 9758 || codePoint == 9792 || codePoint == 9794 || 9824 <= codePoint && codePoint <= 9825 || 9827 <= codePoint && codePoint <= 9829 || 9831 <= codePoint && codePoint <= 9834 || 9836 <= codePoint && codePoint <= 9837 || codePoint == 9839 || 9886 <= codePoint && codePoint <= 9887 || 9918 <= codePoint && codePoint <= 9919 || 9924 <= codePoint && codePoint <= 9933 || 9935 <= codePoint && codePoint <= 9953 || codePoint == 9955 || 9960 <= codePoint && codePoint <= 9983 || codePoint == 10045 || codePoint == 10071 || 10102 <= codePoint && codePoint <= 10111 || 11093 <= codePoint && codePoint <= 11097 || 12872 <= codePoint && codePoint <= 12879 || 57344 <= codePoint && codePoint <= 63743 || 65024 <= codePoint && codePoint <= 65039 || codePoint == 65533 || 127232 <= codePoint && codePoint <= 127242 || 127248 <= codePoint && codePoint <= 127277 || 127280 <= codePoint && codePoint <= 127337 || 127344 <= codePoint && codePoint <= 127386 || 917760 <= codePoint && codePoint <= 917999 || 983040 <= codePoint && codePoint <= 1048573 || 1048576 <= codePoint && codePoint <= 1114109 ? "A" : "N";
1605
+ var x3 = character.charCodeAt(0), y2 = character.length == 2 ? character.charCodeAt(1) : 0, codePoint = x3;
1606
+ return 55296 <= x3 && x3 <= 56319 && 56320 <= y2 && y2 <= 57343 && (x3 &= 1023, y2 &= 1023, codePoint = x3 << 10 | y2, codePoint += 65536), codePoint == 12288 || 65281 <= codePoint && codePoint <= 65376 || 65504 <= codePoint && codePoint <= 65510 ? "F" : codePoint == 8361 || 65377 <= codePoint && codePoint <= 65470 || 65474 <= codePoint && codePoint <= 65479 || 65482 <= codePoint && codePoint <= 65487 || 65490 <= codePoint && codePoint <= 65495 || 65498 <= codePoint && codePoint <= 65500 || 65512 <= codePoint && codePoint <= 65518 ? "H" : 4352 <= codePoint && codePoint <= 4447 || 4515 <= codePoint && codePoint <= 4519 || 4602 <= codePoint && codePoint <= 4607 || 9001 <= codePoint && codePoint <= 9002 || 11904 <= codePoint && codePoint <= 11929 || 11931 <= codePoint && codePoint <= 12019 || 12032 <= codePoint && codePoint <= 12245 || 12272 <= codePoint && codePoint <= 12283 || 12289 <= codePoint && codePoint <= 12350 || 12353 <= codePoint && codePoint <= 12438 || 12441 <= codePoint && codePoint <= 12543 || 12549 <= codePoint && codePoint <= 12589 || 12593 <= codePoint && codePoint <= 12686 || 12688 <= codePoint && codePoint <= 12730 || 12736 <= codePoint && codePoint <= 12771 || 12784 <= codePoint && codePoint <= 12830 || 12832 <= codePoint && codePoint <= 12871 || 12880 <= codePoint && codePoint <= 13054 || 13056 <= codePoint && codePoint <= 19903 || 19968 <= codePoint && codePoint <= 42124 || 42128 <= codePoint && codePoint <= 42182 || 43360 <= codePoint && codePoint <= 43388 || 44032 <= codePoint && codePoint <= 55203 || 55216 <= codePoint && codePoint <= 55238 || 55243 <= codePoint && codePoint <= 55291 || 63744 <= codePoint && codePoint <= 64255 || 65040 <= codePoint && codePoint <= 65049 || 65072 <= codePoint && codePoint <= 65106 || 65108 <= codePoint && codePoint <= 65126 || 65128 <= codePoint && codePoint <= 65131 || 110592 <= codePoint && codePoint <= 110593 || 127488 <= codePoint && codePoint <= 127490 || 127504 <= codePoint && codePoint <= 127546 || 127552 <= codePoint && codePoint <= 127560 || 127568 <= codePoint && codePoint <= 127569 || 131072 <= codePoint && codePoint <= 194367 || 177984 <= codePoint && codePoint <= 196605 || 196608 <= codePoint && codePoint <= 262141 ? "W" : 32 <= codePoint && codePoint <= 126 || 162 <= codePoint && codePoint <= 163 || 165 <= codePoint && codePoint <= 166 || codePoint == 172 || codePoint == 175 || 10214 <= codePoint && codePoint <= 10221 || 10629 <= codePoint && codePoint <= 10630 ? "Na" : codePoint == 161 || codePoint == 164 || 167 <= codePoint && codePoint <= 168 || codePoint == 170 || 173 <= codePoint && codePoint <= 174 || 176 <= codePoint && codePoint <= 180 || 182 <= codePoint && codePoint <= 186 || 188 <= codePoint && codePoint <= 191 || codePoint == 198 || codePoint == 208 || 215 <= codePoint && codePoint <= 216 || 222 <= codePoint && codePoint <= 225 || codePoint == 230 || 232 <= codePoint && codePoint <= 234 || 236 <= codePoint && codePoint <= 237 || codePoint == 240 || 242 <= codePoint && codePoint <= 243 || 247 <= codePoint && codePoint <= 250 || codePoint == 252 || codePoint == 254 || codePoint == 257 || codePoint == 273 || codePoint == 275 || codePoint == 283 || 294 <= codePoint && codePoint <= 295 || codePoint == 299 || 305 <= codePoint && codePoint <= 307 || codePoint == 312 || 319 <= codePoint && codePoint <= 322 || codePoint == 324 || 328 <= codePoint && codePoint <= 331 || codePoint == 333 || 338 <= codePoint && codePoint <= 339 || 358 <= codePoint && codePoint <= 359 || codePoint == 363 || codePoint == 462 || codePoint == 464 || codePoint == 466 || codePoint == 468 || codePoint == 470 || codePoint == 472 || codePoint == 474 || codePoint == 476 || codePoint == 593 || codePoint == 609 || codePoint == 708 || codePoint == 711 || 713 <= codePoint && codePoint <= 715 || codePoint == 717 || codePoint == 720 || 728 <= codePoint && codePoint <= 731 || codePoint == 733 || codePoint == 735 || 768 <= codePoint && codePoint <= 879 || 913 <= codePoint && codePoint <= 929 || 931 <= codePoint && codePoint <= 937 || 945 <= codePoint && codePoint <= 961 || 963 <= codePoint && codePoint <= 969 || codePoint == 1025 || 1040 <= codePoint && codePoint <= 1103 || codePoint == 1105 || codePoint == 8208 || 8211 <= codePoint && codePoint <= 8214 || 8216 <= codePoint && codePoint <= 8217 || 8220 <= codePoint && codePoint <= 8221 || 8224 <= codePoint && codePoint <= 8226 || 8228 <= codePoint && codePoint <= 8231 || codePoint == 8240 || 8242 <= codePoint && codePoint <= 8243 || codePoint == 8245 || codePoint == 8251 || codePoint == 8254 || codePoint == 8308 || codePoint == 8319 || 8321 <= codePoint && codePoint <= 8324 || codePoint == 8364 || codePoint == 8451 || codePoint == 8453 || codePoint == 8457 || codePoint == 8467 || codePoint == 8470 || 8481 <= codePoint && codePoint <= 8482 || codePoint == 8486 || codePoint == 8491 || 8531 <= codePoint && codePoint <= 8532 || 8539 <= codePoint && codePoint <= 8542 || 8544 <= codePoint && codePoint <= 8555 || 8560 <= codePoint && codePoint <= 8569 || codePoint == 8585 || 8592 <= codePoint && codePoint <= 8601 || 8632 <= codePoint && codePoint <= 8633 || codePoint == 8658 || codePoint == 8660 || codePoint == 8679 || codePoint == 8704 || 8706 <= codePoint && codePoint <= 8707 || 8711 <= codePoint && codePoint <= 8712 || codePoint == 8715 || codePoint == 8719 || codePoint == 8721 || codePoint == 8725 || codePoint == 8730 || 8733 <= codePoint && codePoint <= 8736 || codePoint == 8739 || codePoint == 8741 || 8743 <= codePoint && codePoint <= 8748 || codePoint == 8750 || 8756 <= codePoint && codePoint <= 8759 || 8764 <= codePoint && codePoint <= 8765 || codePoint == 8776 || codePoint == 8780 || codePoint == 8786 || 8800 <= codePoint && codePoint <= 8801 || 8804 <= codePoint && codePoint <= 8807 || 8810 <= codePoint && codePoint <= 8811 || 8814 <= codePoint && codePoint <= 8815 || 8834 <= codePoint && codePoint <= 8835 || 8838 <= codePoint && codePoint <= 8839 || codePoint == 8853 || codePoint == 8857 || codePoint == 8869 || codePoint == 8895 || codePoint == 8978 || 9312 <= codePoint && codePoint <= 9449 || 9451 <= codePoint && codePoint <= 9547 || 9552 <= codePoint && codePoint <= 9587 || 9600 <= codePoint && codePoint <= 9615 || 9618 <= codePoint && codePoint <= 9621 || 9632 <= codePoint && codePoint <= 9633 || 9635 <= codePoint && codePoint <= 9641 || 9650 <= codePoint && codePoint <= 9651 || 9654 <= codePoint && codePoint <= 9655 || 9660 <= codePoint && codePoint <= 9661 || 9664 <= codePoint && codePoint <= 9665 || 9670 <= codePoint && codePoint <= 9672 || codePoint == 9675 || 9678 <= codePoint && codePoint <= 9681 || 9698 <= codePoint && codePoint <= 9701 || codePoint == 9711 || 9733 <= codePoint && codePoint <= 9734 || codePoint == 9737 || 9742 <= codePoint && codePoint <= 9743 || 9748 <= codePoint && codePoint <= 9749 || codePoint == 9756 || codePoint == 9758 || codePoint == 9792 || codePoint == 9794 || 9824 <= codePoint && codePoint <= 9825 || 9827 <= codePoint && codePoint <= 9829 || 9831 <= codePoint && codePoint <= 9834 || 9836 <= codePoint && codePoint <= 9837 || codePoint == 9839 || 9886 <= codePoint && codePoint <= 9887 || 9918 <= codePoint && codePoint <= 9919 || 9924 <= codePoint && codePoint <= 9933 || 9935 <= codePoint && codePoint <= 9953 || codePoint == 9955 || 9960 <= codePoint && codePoint <= 9983 || codePoint == 10045 || codePoint == 10071 || 10102 <= codePoint && codePoint <= 10111 || 11093 <= codePoint && codePoint <= 11097 || 12872 <= codePoint && codePoint <= 12879 || 57344 <= codePoint && codePoint <= 63743 || 65024 <= codePoint && codePoint <= 65039 || codePoint == 65533 || 127232 <= codePoint && codePoint <= 127242 || 127248 <= codePoint && codePoint <= 127277 || 127280 <= codePoint && codePoint <= 127337 || 127344 <= codePoint && codePoint <= 127386 || 917760 <= codePoint && codePoint <= 917999 || 983040 <= codePoint && codePoint <= 1048573 || 1048576 <= codePoint && codePoint <= 1114109 ? "A" : "N";
1607
1607
  };
1608
1608
  eaw.characterLength = function(character) {
1609
1609
  var code = this.eastAsianWidth(character);
@@ -1667,71 +1667,71 @@ __export(logger_exports, {
1667
1667
 
1668
1668
  // ../node_modules/@clack/core/dist/index.mjs
1669
1669
  var import_picocolors = __toESM(require_picocolors(), 1), import_sisteransi = __toESM(require_src(), 1);
1670
- import { stdout as z, stdin as Y } from "node:process";
1670
+ import { stdout as R, stdin as q } from "node:process";
1671
1671
  import * as k from "node:readline";
1672
- import nt from "node:readline";
1673
- import { ReadStream as q } from "node:tty";
1674
- var ut = (t2) => t2 === 161 || t2 === 164 || t2 === 167 || t2 === 168 || t2 === 170 || t2 === 173 || t2 === 174 || t2 >= 176 && t2 <= 180 || t2 >= 182 && t2 <= 186 || t2 >= 188 && t2 <= 191 || t2 === 198 || t2 === 208 || t2 === 215 || t2 === 216 || t2 >= 222 && t2 <= 225 || t2 === 230 || t2 >= 232 && t2 <= 234 || t2 === 236 || t2 === 237 || t2 === 240 || t2 === 242 || t2 === 243 || t2 >= 247 && t2 <= 250 || t2 === 252 || t2 === 254 || t2 === 257 || t2 === 273 || t2 === 275 || t2 === 283 || t2 === 294 || t2 === 295 || t2 === 299 || t2 >= 305 && t2 <= 307 || t2 === 312 || t2 >= 319 && t2 <= 322 || t2 === 324 || t2 >= 328 && t2 <= 331 || t2 === 333 || t2 === 338 || t2 === 339 || t2 === 358 || t2 === 359 || t2 === 363 || t2 === 462 || t2 === 464 || t2 === 466 || t2 === 468 || t2 === 470 || t2 === 472 || t2 === 474 || t2 === 476 || t2 === 593 || t2 === 609 || t2 === 708 || t2 === 711 || t2 >= 713 && t2 <= 715 || t2 === 717 || t2 === 720 || t2 >= 728 && t2 <= 731 || t2 === 733 || t2 === 735 || t2 >= 768 && t2 <= 879 || t2 >= 913 && t2 <= 929 || t2 >= 931 && t2 <= 937 || t2 >= 945 && t2 <= 961 || t2 >= 963 && t2 <= 969 || t2 === 1025 || t2 >= 1040 && t2 <= 1103 || t2 === 1105 || t2 === 8208 || t2 >= 8211 && t2 <= 8214 || t2 === 8216 || t2 === 8217 || t2 === 8220 || t2 === 8221 || t2 >= 8224 && t2 <= 8226 || t2 >= 8228 && t2 <= 8231 || t2 === 8240 || t2 === 8242 || t2 === 8243 || t2 === 8245 || t2 === 8251 || t2 === 8254 || t2 === 8308 || t2 === 8319 || t2 >= 8321 && t2 <= 8324 || t2 === 8364 || t2 === 8451 || t2 === 8453 || t2 === 8457 || t2 === 8467 || t2 === 8470 || t2 === 8481 || t2 === 8482 || t2 === 8486 || t2 === 8491 || t2 === 8531 || t2 === 8532 || t2 >= 8539 && t2 <= 8542 || t2 >= 8544 && t2 <= 8555 || t2 >= 8560 && t2 <= 8569 || t2 === 8585 || t2 >= 8592 && t2 <= 8601 || t2 === 8632 || t2 === 8633 || t2 === 8658 || t2 === 8660 || t2 === 8679 || t2 === 8704 || t2 === 8706 || t2 === 8707 || t2 === 8711 || t2 === 8712 || t2 === 8715 || t2 === 8719 || t2 === 8721 || t2 === 8725 || t2 === 8730 || t2 >= 8733 && t2 <= 8736 || t2 === 8739 || t2 === 8741 || t2 >= 8743 && t2 <= 8748 || t2 === 8750 || t2 >= 8756 && t2 <= 8759 || t2 === 8764 || t2 === 8765 || t2 === 8776 || t2 === 8780 || t2 === 8786 || t2 === 8800 || t2 === 8801 || t2 >= 8804 && t2 <= 8807 || t2 === 8810 || t2 === 8811 || t2 === 8814 || t2 === 8815 || t2 === 8834 || t2 === 8835 || t2 === 8838 || t2 === 8839 || t2 === 8853 || t2 === 8857 || t2 === 8869 || t2 === 8895 || t2 === 8978 || t2 >= 9312 && t2 <= 9449 || t2 >= 9451 && t2 <= 9547 || t2 >= 9552 && t2 <= 9587 || t2 >= 9600 && t2 <= 9615 || t2 >= 9618 && t2 <= 9621 || t2 === 9632 || t2 === 9633 || t2 >= 9635 && t2 <= 9641 || t2 === 9650 || t2 === 9651 || t2 === 9654 || t2 === 9655 || t2 === 9660 || t2 === 9661 || t2 === 9664 || t2 === 9665 || t2 >= 9670 && t2 <= 9672 || t2 === 9675 || t2 >= 9678 && t2 <= 9681 || t2 >= 9698 && t2 <= 9701 || t2 === 9711 || t2 === 9733 || t2 === 9734 || t2 === 9737 || t2 === 9742 || t2 === 9743 || t2 === 9756 || t2 === 9758 || t2 === 9792 || t2 === 9794 || t2 === 9824 || t2 === 9825 || t2 >= 9827 && t2 <= 9829 || t2 >= 9831 && t2 <= 9834 || t2 === 9836 || t2 === 9837 || t2 === 9839 || t2 === 9886 || t2 === 9887 || t2 === 9919 || t2 >= 9926 && t2 <= 9933 || t2 >= 9935 && t2 <= 9939 || t2 >= 9941 && t2 <= 9953 || t2 === 9955 || t2 === 9960 || t2 === 9961 || t2 >= 9963 && t2 <= 9969 || t2 === 9972 || t2 >= 9974 && t2 <= 9977 || t2 === 9979 || t2 === 9980 || t2 === 9982 || t2 === 9983 || t2 === 10045 || t2 >= 10102 && t2 <= 10111 || t2 >= 11094 && t2 <= 11097 || t2 >= 12872 && t2 <= 12879 || t2 >= 57344 && t2 <= 63743 || t2 >= 65024 && t2 <= 65039 || t2 === 65533 || t2 >= 127232 && t2 <= 127242 || t2 >= 127248 && t2 <= 127277 || t2 >= 127280 && t2 <= 127337 || t2 >= 127344 && t2 <= 127373 || t2 === 127375 || t2 === 127376 || t2 >= 127387 && t2 <= 127404 || t2 >= 917760 && t2 <= 917999 || t2 >= 983040 && t2 <= 1048573 || t2 >= 1048576 && t2 <= 1114109, ot = (t2) => t2 === 12288 || t2 >= 65281 && t2 <= 65376 || t2 >= 65504 && t2 <= 65510, at = (t2) => t2 >= 4352 && t2 <= 4447 || t2 === 8986 || t2 === 8987 || t2 === 9001 || t2 === 9002 || t2 >= 9193 && t2 <= 9196 || t2 === 9200 || t2 === 9203 || t2 === 9725 || t2 === 9726 || t2 === 9748 || t2 === 9749 || t2 >= 9800 && t2 <= 9811 || t2 === 9855 || t2 === 9875 || t2 === 9889 || t2 === 9898 || t2 === 9899 || t2 === 9917 || t2 === 9918 || t2 === 9924 || t2 === 9925 || t2 === 9934 || t2 === 9940 || t2 === 9962 || t2 === 9970 || t2 === 9971 || t2 === 9973 || t2 === 9978 || t2 === 9981 || t2 === 9989 || t2 === 9994 || t2 === 9995 || t2 === 10024 || t2 === 10060 || t2 === 10062 || t2 >= 10067 && t2 <= 10069 || t2 === 10071 || t2 >= 10133 && t2 <= 10135 || t2 === 10160 || t2 === 10175 || t2 === 11035 || t2 === 11036 || t2 === 11088 || t2 === 11093 || t2 >= 11904 && t2 <= 11929 || t2 >= 11931 && t2 <= 12019 || t2 >= 12032 && t2 <= 12245 || t2 >= 12272 && t2 <= 12287 || t2 >= 12289 && t2 <= 12350 || t2 >= 12353 && t2 <= 12438 || t2 >= 12441 && t2 <= 12543 || t2 >= 12549 && t2 <= 12591 || t2 >= 12593 && t2 <= 12686 || t2 >= 12688 && t2 <= 12771 || t2 >= 12783 && t2 <= 12830 || t2 >= 12832 && t2 <= 12871 || t2 >= 12880 && t2 <= 19903 || t2 >= 19968 && t2 <= 42124 || t2 >= 42128 && t2 <= 42182 || t2 >= 43360 && t2 <= 43388 || t2 >= 44032 && t2 <= 55203 || t2 >= 63744 && t2 <= 64255 || t2 >= 65040 && t2 <= 65049 || t2 >= 65072 && t2 <= 65106 || t2 >= 65108 && t2 <= 65126 || t2 >= 65128 && t2 <= 65131 || t2 >= 94176 && t2 <= 94180 || t2 === 94192 || t2 === 94193 || t2 >= 94208 && t2 <= 100343 || t2 >= 100352 && t2 <= 101589 || t2 >= 101632 && t2 <= 101640 || t2 >= 110576 && t2 <= 110579 || t2 >= 110581 && t2 <= 110587 || t2 === 110589 || t2 === 110590 || t2 >= 110592 && t2 <= 110882 || t2 === 110898 || t2 >= 110928 && t2 <= 110930 || t2 === 110933 || t2 >= 110948 && t2 <= 110951 || t2 >= 110960 && t2 <= 111355 || t2 === 126980 || t2 === 127183 || t2 === 127374 || t2 >= 127377 && t2 <= 127386 || t2 >= 127488 && t2 <= 127490 || t2 >= 127504 && t2 <= 127547 || t2 >= 127552 && t2 <= 127560 || t2 === 127568 || t2 === 127569 || t2 >= 127584 && t2 <= 127589 || t2 >= 127744 && t2 <= 127776 || t2 >= 127789 && t2 <= 127797 || t2 >= 127799 && t2 <= 127868 || t2 >= 127870 && t2 <= 127891 || t2 >= 127904 && t2 <= 127946 || t2 >= 127951 && t2 <= 127955 || t2 >= 127968 && t2 <= 127984 || t2 === 127988 || t2 >= 127992 && t2 <= 128062 || t2 === 128064 || t2 >= 128066 && t2 <= 128252 || t2 >= 128255 && t2 <= 128317 || t2 >= 128331 && t2 <= 128334 || t2 >= 128336 && t2 <= 128359 || t2 === 128378 || t2 === 128405 || t2 === 128406 || t2 === 128420 || t2 >= 128507 && t2 <= 128591 || t2 >= 128640 && t2 <= 128709 || t2 === 128716 || t2 >= 128720 && t2 <= 128722 || t2 >= 128725 && t2 <= 128727 || t2 >= 128732 && t2 <= 128735 || t2 === 128747 || t2 === 128748 || t2 >= 128756 && t2 <= 128764 || t2 >= 128992 && t2 <= 129003 || t2 === 129008 || t2 >= 129292 && t2 <= 129338 || t2 >= 129340 && t2 <= 129349 || t2 >= 129351 && t2 <= 129535 || t2 >= 129648 && t2 <= 129660 || t2 >= 129664 && t2 <= 129672 || t2 >= 129680 && t2 <= 129725 || t2 >= 129727 && t2 <= 129733 || t2 >= 129742 && t2 <= 129755 || t2 >= 129760 && t2 <= 129768 || t2 >= 129776 && t2 <= 129784 || t2 >= 131072 && t2 <= 196605 || t2 >= 196608 && t2 <= 262141, N = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, y = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, M = /\t{1,1000}/y, O = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu"), L = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, lt = new RegExp("\\p{M}+", "gu"), ht = { limit: 1 / 0, ellipsis: "" }, J = (t2, s = {}, e = {}) => {
1675
- let i = s.limit ?? 1 / 0, r = s.ellipsis ?? "", n = s?.ellipsisWidth ?? (r ? J(r, ht, e).width : 0), F = e.ansiWidth ?? 0, l = e.controlWidth ?? 0, a = e.tabWidth ?? 8, v = e.ambiguousWidth ?? 1, g = e.emojiWidth ?? 2, m = e.fullWidthWidth ?? 2, A = e.regularWidth ?? 1, V = e.wideWidth ?? 2, o = 0, u = 0, p = t2.length, E = 0, f = !1, d2 = p, _ = Math.max(0, i - n), C = 0, x2 = 0, h = 0, c = 0;
1672
+ import ot from "node:readline";
1673
+ import { ReadStream as J } from "node:tty";
1674
+ var at = (t2) => t2 === 161 || t2 === 164 || t2 === 167 || t2 === 168 || t2 === 170 || t2 === 173 || t2 === 174 || t2 >= 176 && t2 <= 180 || t2 >= 182 && t2 <= 186 || t2 >= 188 && t2 <= 191 || t2 === 198 || t2 === 208 || t2 === 215 || t2 === 216 || t2 >= 222 && t2 <= 225 || t2 === 230 || t2 >= 232 && t2 <= 234 || t2 === 236 || t2 === 237 || t2 === 240 || t2 === 242 || t2 === 243 || t2 >= 247 && t2 <= 250 || t2 === 252 || t2 === 254 || t2 === 257 || t2 === 273 || t2 === 275 || t2 === 283 || t2 === 294 || t2 === 295 || t2 === 299 || t2 >= 305 && t2 <= 307 || t2 === 312 || t2 >= 319 && t2 <= 322 || t2 === 324 || t2 >= 328 && t2 <= 331 || t2 === 333 || t2 === 338 || t2 === 339 || t2 === 358 || t2 === 359 || t2 === 363 || t2 === 462 || t2 === 464 || t2 === 466 || t2 === 468 || t2 === 470 || t2 === 472 || t2 === 474 || t2 === 476 || t2 === 593 || t2 === 609 || t2 === 708 || t2 === 711 || t2 >= 713 && t2 <= 715 || t2 === 717 || t2 === 720 || t2 >= 728 && t2 <= 731 || t2 === 733 || t2 === 735 || t2 >= 768 && t2 <= 879 || t2 >= 913 && t2 <= 929 || t2 >= 931 && t2 <= 937 || t2 >= 945 && t2 <= 961 || t2 >= 963 && t2 <= 969 || t2 === 1025 || t2 >= 1040 && t2 <= 1103 || t2 === 1105 || t2 === 8208 || t2 >= 8211 && t2 <= 8214 || t2 === 8216 || t2 === 8217 || t2 === 8220 || t2 === 8221 || t2 >= 8224 && t2 <= 8226 || t2 >= 8228 && t2 <= 8231 || t2 === 8240 || t2 === 8242 || t2 === 8243 || t2 === 8245 || t2 === 8251 || t2 === 8254 || t2 === 8308 || t2 === 8319 || t2 >= 8321 && t2 <= 8324 || t2 === 8364 || t2 === 8451 || t2 === 8453 || t2 === 8457 || t2 === 8467 || t2 === 8470 || t2 === 8481 || t2 === 8482 || t2 === 8486 || t2 === 8491 || t2 === 8531 || t2 === 8532 || t2 >= 8539 && t2 <= 8542 || t2 >= 8544 && t2 <= 8555 || t2 >= 8560 && t2 <= 8569 || t2 === 8585 || t2 >= 8592 && t2 <= 8601 || t2 === 8632 || t2 === 8633 || t2 === 8658 || t2 === 8660 || t2 === 8679 || t2 === 8704 || t2 === 8706 || t2 === 8707 || t2 === 8711 || t2 === 8712 || t2 === 8715 || t2 === 8719 || t2 === 8721 || t2 === 8725 || t2 === 8730 || t2 >= 8733 && t2 <= 8736 || t2 === 8739 || t2 === 8741 || t2 >= 8743 && t2 <= 8748 || t2 === 8750 || t2 >= 8756 && t2 <= 8759 || t2 === 8764 || t2 === 8765 || t2 === 8776 || t2 === 8780 || t2 === 8786 || t2 === 8800 || t2 === 8801 || t2 >= 8804 && t2 <= 8807 || t2 === 8810 || t2 === 8811 || t2 === 8814 || t2 === 8815 || t2 === 8834 || t2 === 8835 || t2 === 8838 || t2 === 8839 || t2 === 8853 || t2 === 8857 || t2 === 8869 || t2 === 8895 || t2 === 8978 || t2 >= 9312 && t2 <= 9449 || t2 >= 9451 && t2 <= 9547 || t2 >= 9552 && t2 <= 9587 || t2 >= 9600 && t2 <= 9615 || t2 >= 9618 && t2 <= 9621 || t2 === 9632 || t2 === 9633 || t2 >= 9635 && t2 <= 9641 || t2 === 9650 || t2 === 9651 || t2 === 9654 || t2 === 9655 || t2 === 9660 || t2 === 9661 || t2 === 9664 || t2 === 9665 || t2 >= 9670 && t2 <= 9672 || t2 === 9675 || t2 >= 9678 && t2 <= 9681 || t2 >= 9698 && t2 <= 9701 || t2 === 9711 || t2 === 9733 || t2 === 9734 || t2 === 9737 || t2 === 9742 || t2 === 9743 || t2 === 9756 || t2 === 9758 || t2 === 9792 || t2 === 9794 || t2 === 9824 || t2 === 9825 || t2 >= 9827 && t2 <= 9829 || t2 >= 9831 && t2 <= 9834 || t2 === 9836 || t2 === 9837 || t2 === 9839 || t2 === 9886 || t2 === 9887 || t2 === 9919 || t2 >= 9926 && t2 <= 9933 || t2 >= 9935 && t2 <= 9939 || t2 >= 9941 && t2 <= 9953 || t2 === 9955 || t2 === 9960 || t2 === 9961 || t2 >= 9963 && t2 <= 9969 || t2 === 9972 || t2 >= 9974 && t2 <= 9977 || t2 === 9979 || t2 === 9980 || t2 === 9982 || t2 === 9983 || t2 === 10045 || t2 >= 10102 && t2 <= 10111 || t2 >= 11094 && t2 <= 11097 || t2 >= 12872 && t2 <= 12879 || t2 >= 57344 && t2 <= 63743 || t2 >= 65024 && t2 <= 65039 || t2 === 65533 || t2 >= 127232 && t2 <= 127242 || t2 >= 127248 && t2 <= 127277 || t2 >= 127280 && t2 <= 127337 || t2 >= 127344 && t2 <= 127373 || t2 === 127375 || t2 === 127376 || t2 >= 127387 && t2 <= 127404 || t2 >= 917760 && t2 <= 917999 || t2 >= 983040 && t2 <= 1048573 || t2 >= 1048576 && t2 <= 1114109, lt = (t2) => t2 === 12288 || t2 >= 65281 && t2 <= 65376 || t2 >= 65504 && t2 <= 65510, ht = (t2) => t2 >= 4352 && t2 <= 4447 || t2 === 8986 || t2 === 8987 || t2 === 9001 || t2 === 9002 || t2 >= 9193 && t2 <= 9196 || t2 === 9200 || t2 === 9203 || t2 === 9725 || t2 === 9726 || t2 === 9748 || t2 === 9749 || t2 >= 9800 && t2 <= 9811 || t2 === 9855 || t2 === 9875 || t2 === 9889 || t2 === 9898 || t2 === 9899 || t2 === 9917 || t2 === 9918 || t2 === 9924 || t2 === 9925 || t2 === 9934 || t2 === 9940 || t2 === 9962 || t2 === 9970 || t2 === 9971 || t2 === 9973 || t2 === 9978 || t2 === 9981 || t2 === 9989 || t2 === 9994 || t2 === 9995 || t2 === 10024 || t2 === 10060 || t2 === 10062 || t2 >= 10067 && t2 <= 10069 || t2 === 10071 || t2 >= 10133 && t2 <= 10135 || t2 === 10160 || t2 === 10175 || t2 === 11035 || t2 === 11036 || t2 === 11088 || t2 === 11093 || t2 >= 11904 && t2 <= 11929 || t2 >= 11931 && t2 <= 12019 || t2 >= 12032 && t2 <= 12245 || t2 >= 12272 && t2 <= 12287 || t2 >= 12289 && t2 <= 12350 || t2 >= 12353 && t2 <= 12438 || t2 >= 12441 && t2 <= 12543 || t2 >= 12549 && t2 <= 12591 || t2 >= 12593 && t2 <= 12686 || t2 >= 12688 && t2 <= 12771 || t2 >= 12783 && t2 <= 12830 || t2 >= 12832 && t2 <= 12871 || t2 >= 12880 && t2 <= 19903 || t2 >= 19968 && t2 <= 42124 || t2 >= 42128 && t2 <= 42182 || t2 >= 43360 && t2 <= 43388 || t2 >= 44032 && t2 <= 55203 || t2 >= 63744 && t2 <= 64255 || t2 >= 65040 && t2 <= 65049 || t2 >= 65072 && t2 <= 65106 || t2 >= 65108 && t2 <= 65126 || t2 >= 65128 && t2 <= 65131 || t2 >= 94176 && t2 <= 94180 || t2 === 94192 || t2 === 94193 || t2 >= 94208 && t2 <= 100343 || t2 >= 100352 && t2 <= 101589 || t2 >= 101632 && t2 <= 101640 || t2 >= 110576 && t2 <= 110579 || t2 >= 110581 && t2 <= 110587 || t2 === 110589 || t2 === 110590 || t2 >= 110592 && t2 <= 110882 || t2 === 110898 || t2 >= 110928 && t2 <= 110930 || t2 === 110933 || t2 >= 110948 && t2 <= 110951 || t2 >= 110960 && t2 <= 111355 || t2 === 126980 || t2 === 127183 || t2 === 127374 || t2 >= 127377 && t2 <= 127386 || t2 >= 127488 && t2 <= 127490 || t2 >= 127504 && t2 <= 127547 || t2 >= 127552 && t2 <= 127560 || t2 === 127568 || t2 === 127569 || t2 >= 127584 && t2 <= 127589 || t2 >= 127744 && t2 <= 127776 || t2 >= 127789 && t2 <= 127797 || t2 >= 127799 && t2 <= 127868 || t2 >= 127870 && t2 <= 127891 || t2 >= 127904 && t2 <= 127946 || t2 >= 127951 && t2 <= 127955 || t2 >= 127968 && t2 <= 127984 || t2 === 127988 || t2 >= 127992 && t2 <= 128062 || t2 === 128064 || t2 >= 128066 && t2 <= 128252 || t2 >= 128255 && t2 <= 128317 || t2 >= 128331 && t2 <= 128334 || t2 >= 128336 && t2 <= 128359 || t2 === 128378 || t2 === 128405 || t2 === 128406 || t2 === 128420 || t2 >= 128507 && t2 <= 128591 || t2 >= 128640 && t2 <= 128709 || t2 === 128716 || t2 >= 128720 && t2 <= 128722 || t2 >= 128725 && t2 <= 128727 || t2 >= 128732 && t2 <= 128735 || t2 === 128747 || t2 === 128748 || t2 >= 128756 && t2 <= 128764 || t2 >= 128992 && t2 <= 129003 || t2 === 129008 || t2 >= 129292 && t2 <= 129338 || t2 >= 129340 && t2 <= 129349 || t2 >= 129351 && t2 <= 129535 || t2 >= 129648 && t2 <= 129660 || t2 >= 129664 && t2 <= 129672 || t2 >= 129680 && t2 <= 129725 || t2 >= 129727 && t2 <= 129733 || t2 >= 129742 && t2 <= 129755 || t2 >= 129760 && t2 <= 129768 || t2 >= 129776 && t2 <= 129784 || t2 >= 131072 && t2 <= 196605 || t2 >= 196608 && t2 <= 262141, O = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, y = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, M = /\t{1,1000}/y, P = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu"), L = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, ct = new RegExp("\\p{M}+", "gu"), Ft = { limit: 1 / 0, ellipsis: "" }, X = (t2, e = {}, s = {}) => {
1675
+ let i = e.limit ?? 1 / 0, r = e.ellipsis ?? "", n = e?.ellipsisWidth ?? (r ? X(r, Ft, s).width : 0), o = s.ansiWidth ?? 0, a = s.controlWidth ?? 0, l = s.tabWidth ?? 8, E = s.ambiguousWidth ?? 1, g = s.emojiWidth ?? 2, m = s.fullWidthWidth ?? 2, A = s.regularWidth ?? 1, V2 = s.wideWidth ?? 2, h = 0, u = 0, f = t2.length, v = 0, p = !1, d2 = f, b = Math.max(0, i - n), C = 0, B = 0, c = 0, F = 0;
1676
1676
  t: for (; ; ) {
1677
- if (x2 > C || u >= p && u > o) {
1678
- let rt = t2.slice(C, x2) || t2.slice(o, u);
1679
- E = 0;
1680
- for (let H2 of rt.replaceAll(lt, "")) {
1681
- let R2 = H2.codePointAt(0) || 0;
1682
- if (ot(R2) ? c = m : at(R2) ? c = V : v !== A && ut(R2) ? c = v : c = A, h + c > _ && (d2 = Math.min(d2, Math.max(C, o) + E)), h + c > i) {
1683
- f = !0;
1677
+ if (B > C || u >= f && u > h) {
1678
+ let ut = t2.slice(C, B) || t2.slice(h, u);
1679
+ v = 0;
1680
+ for (let Y2 of ut.replaceAll(ct, "")) {
1681
+ let $ = Y2.codePointAt(0) || 0;
1682
+ if (lt($) ? F = m : ht($) ? F = V2 : E !== A && at($) ? F = E : F = A, c + F > b && (d2 = Math.min(d2, Math.max(C, h) + v)), c + F > i) {
1683
+ p = !0;
1684
1684
  break t;
1685
1685
  }
1686
- E += H2.length, h += c;
1686
+ v += Y2.length, c += F;
1687
1687
  }
1688
- C = x2 = 0;
1688
+ C = B = 0;
1689
1689
  }
1690
- if (u >= p) break;
1690
+ if (u >= f) break;
1691
1691
  if (L.lastIndex = u, L.test(t2)) {
1692
- if (E = L.lastIndex - u, c = E * A, h + c > _ && (d2 = Math.min(d2, u + Math.floor((_ - h) / A))), h + c > i) {
1693
- f = !0;
1692
+ if (v = L.lastIndex - u, F = v * A, c + F > b && (d2 = Math.min(d2, u + Math.floor((b - c) / A))), c + F > i) {
1693
+ p = !0;
1694
1694
  break;
1695
1695
  }
1696
- h += c, C = o, x2 = u, u = o = L.lastIndex;
1696
+ c += F, C = h, B = u, u = h = L.lastIndex;
1697
1697
  continue;
1698
1698
  }
1699
- if (N.lastIndex = u, N.test(t2)) {
1700
- if (h + F > _ && (d2 = Math.min(d2, u)), h + F > i) {
1701
- f = !0;
1699
+ if (O.lastIndex = u, O.test(t2)) {
1700
+ if (c + o > b && (d2 = Math.min(d2, u)), c + o > i) {
1701
+ p = !0;
1702
1702
  break;
1703
1703
  }
1704
- h += F, C = o, x2 = u, u = o = N.lastIndex;
1704
+ c += o, C = h, B = u, u = h = O.lastIndex;
1705
1705
  continue;
1706
1706
  }
1707
1707
  if (y.lastIndex = u, y.test(t2)) {
1708
- if (E = y.lastIndex - u, c = E * l, h + c > _ && (d2 = Math.min(d2, u + Math.floor((_ - h) / l))), h + c > i) {
1709
- f = !0;
1708
+ if (v = y.lastIndex - u, F = v * a, c + F > b && (d2 = Math.min(d2, u + Math.floor((b - c) / a))), c + F > i) {
1709
+ p = !0;
1710
1710
  break;
1711
1711
  }
1712
- h += c, C = o, x2 = u, u = o = y.lastIndex;
1712
+ c += F, C = h, B = u, u = h = y.lastIndex;
1713
1713
  continue;
1714
1714
  }
1715
1715
  if (M.lastIndex = u, M.test(t2)) {
1716
- if (E = M.lastIndex - u, c = E * a, h + c > _ && (d2 = Math.min(d2, u + Math.floor((_ - h) / a))), h + c > i) {
1717
- f = !0;
1716
+ if (v = M.lastIndex - u, F = v * l, c + F > b && (d2 = Math.min(d2, u + Math.floor((b - c) / l))), c + F > i) {
1717
+ p = !0;
1718
1718
  break;
1719
1719
  }
1720
- h += c, C = o, x2 = u, u = o = M.lastIndex;
1720
+ c += F, C = h, B = u, u = h = M.lastIndex;
1721
1721
  continue;
1722
1722
  }
1723
- if (O.lastIndex = u, O.test(t2)) {
1724
- if (h + g > _ && (d2 = Math.min(d2, u)), h + g > i) {
1725
- f = !0;
1723
+ if (P.lastIndex = u, P.test(t2)) {
1724
+ if (c + g > b && (d2 = Math.min(d2, u)), c + g > i) {
1725
+ p = !0;
1726
1726
  break;
1727
1727
  }
1728
- h += g, C = o, x2 = u, u = o = O.lastIndex;
1728
+ c += g, C = h, B = u, u = h = P.lastIndex;
1729
1729
  continue;
1730
1730
  }
1731
1731
  u += 1;
1732
1732
  }
1733
- return { width: f ? _ : h, index: f ? d2 : p, truncated: f, ellipsed: f && i >= n };
1734
- }, ct = { limit: 1 / 0, ellipsis: "", ellipsisWidth: 0 }, S = (t2, s = {}) => J(t2, ct, s).width, W = "\x1B", X = "\x9B", Ft = 39, P = "\x07", Z = "[", pt = "]", Q = "m", j = `${pt}8;;`, tt = new RegExp(`(?:\\${Z}(?<code>\\d+)m|\\${j}(?<uri>.*)${P})`, "y"), ft = (t2) => {
1733
+ return { width: p ? b : c, index: p ? d2 : f, truncated: p, ellipsed: p && i >= n };
1734
+ }, ft = { limit: 1 / 0, ellipsis: "", ellipsisWidth: 0 }, S = (t2, e = {}) => X(t2, ft, e).width, W = "\x1B", Z = "\x9B", pt = 39, j = "\x07", Q = "[", dt = "]", tt = "m", U = `${dt}8;;`, et = new RegExp(`(?:\\${Q}(?<code>\\d+)m|\\${U}(?<uri>.*)${j})`, "y"), mt = (t2) => {
1735
1735
  if (t2 >= 30 && t2 <= 37 || t2 >= 90 && t2 <= 97) return 39;
1736
1736
  if (t2 >= 40 && t2 <= 47 || t2 >= 100 && t2 <= 107) return 49;
1737
1737
  if (t2 === 1 || t2 === 2) return 22;
@@ -1741,111 +1741,118 @@ var ut = (t2) => t2 === 161 || t2 === 164 || t2 === 167 || t2 === 168 || t2 ===
1741
1741
  if (t2 === 8) return 28;
1742
1742
  if (t2 === 9) return 29;
1743
1743
  if (t2 === 0) return 0;
1744
- }, st = (t2) => `${W}${Z}${t2}${Q}`, et = (t2) => `${W}${j}${t2}${P}`, dt = (t2) => t2.map((s) => S(s)), U = (t2, s, e) => {
1745
- let i = s[Symbol.iterator](), r = !1, n = !1, F = t2.at(-1), l = F === void 0 ? 0 : S(F), a = i.next(), v = i.next(), g = 0;
1746
- for (; !a.done; ) {
1747
- let m = a.value, A = S(m);
1748
- l + A <= e ? t2[t2.length - 1] += m : (t2.push(m), l = 0), (m === W || m === X) && (r = !0, n = s.startsWith(j, g + 1)), r ? n ? m === P && (r = !1, n = !1) : m === Q && (r = !1) : (l += A, l === e && !v.done && (t2.push(""), l = 0)), a = v, v = i.next(), g += m.length;
1749
- }
1750
- F = t2.at(-1), !l && F !== void 0 && F.length > 0 && t2.length > 1 && (t2[t2.length - 2] += t2.pop());
1751
- }, mt = (t2) => {
1752
- let s = t2.split(" "), e = s.length;
1753
- for (; e > 0 && !(S(s[e - 1]) > 0); ) e--;
1754
- return e === s.length ? t2 : s.slice(0, e).join(" ") + s.slice(e).join("");
1755
- }, gt = (t2, s, e = {}) => {
1756
- if (e.trim !== !1 && t2.trim() === "") return "";
1757
- let i = "", r, n, F = t2.split(" "), l = dt(F), a = [""];
1758
- for (let [o, u] of F.entries()) {
1759
- e.trim !== !1 && (a[a.length - 1] = (a.at(-1) ?? "").trimStart());
1760
- let p = S(a.at(-1) ?? "");
1761
- if (o !== 0 && (p >= s && (e.wordWrap === !1 || e.trim === !1) && (a.push(""), p = 0), (p > 0 || e.trim === !1) && (a[a.length - 1] += " ", p++)), e.hard && l[o] > s) {
1762
- let E = s - p, f = 1 + Math.floor((l[o] - E - 1) / s);
1763
- Math.floor((l[o] - 1) / s) < f && a.push(""), U(a, u, s);
1744
+ }, st = (t2) => `${W}${Q}${t2}${tt}`, it = (t2) => `${W}${U}${t2}${j}`, gt = (t2) => t2.map((e) => S(e)), G = (t2, e, s) => {
1745
+ let i = e[Symbol.iterator](), r = !1, n = !1, o = t2.at(-1), a = o === void 0 ? 0 : S(o), l = i.next(), E = i.next(), g = 0;
1746
+ for (; !l.done; ) {
1747
+ let m = l.value, A = S(m);
1748
+ a + A <= s ? t2[t2.length - 1] += m : (t2.push(m), a = 0), (m === W || m === Z) && (r = !0, n = e.startsWith(U, g + 1)), r ? n ? m === j && (r = !1, n = !1) : m === tt && (r = !1) : (a += A, a === s && !E.done && (t2.push(""), a = 0)), l = E, E = i.next(), g += m.length;
1749
+ }
1750
+ o = t2.at(-1), !a && o !== void 0 && o.length > 0 && t2.length > 1 && (t2[t2.length - 2] += t2.pop());
1751
+ }, vt = (t2) => {
1752
+ let e = t2.split(" "), s = e.length;
1753
+ for (; s > 0 && !(S(e[s - 1]) > 0); ) s--;
1754
+ return s === e.length ? t2 : e.slice(0, s).join(" ") + e.slice(s).join("");
1755
+ }, Et = (t2, e, s = {}) => {
1756
+ if (s.trim !== !1 && t2.trim() === "") return "";
1757
+ let i = "", r, n, o = t2.split(" "), a = gt(o), l = [""];
1758
+ for (let [h, u] of o.entries()) {
1759
+ s.trim !== !1 && (l[l.length - 1] = (l.at(-1) ?? "").trimStart());
1760
+ let f = S(l.at(-1) ?? "");
1761
+ if (h !== 0 && (f >= e && (s.wordWrap === !1 || s.trim === !1) && (l.push(""), f = 0), (f > 0 || s.trim === !1) && (l[l.length - 1] += " ", f++)), s.hard && a[h] > e) {
1762
+ let v = e - f, p = 1 + Math.floor((a[h] - v - 1) / e);
1763
+ Math.floor((a[h] - 1) / e) < p && l.push(""), G(l, u, e);
1764
1764
  continue;
1765
1765
  }
1766
- if (p + l[o] > s && p > 0 && l[o] > 0) {
1767
- if (e.wordWrap === !1 && p < s) {
1768
- U(a, u, s);
1766
+ if (f + a[h] > e && f > 0 && a[h] > 0) {
1767
+ if (s.wordWrap === !1 && f < e) {
1768
+ G(l, u, e);
1769
1769
  continue;
1770
1770
  }
1771
- a.push("");
1771
+ l.push("");
1772
1772
  }
1773
- if (p + l[o] > s && e.wordWrap === !1) {
1774
- U(a, u, s);
1773
+ if (f + a[h] > e && s.wordWrap === !1) {
1774
+ G(l, u, e);
1775
1775
  continue;
1776
1776
  }
1777
- a[a.length - 1] += u;
1777
+ l[l.length - 1] += u;
1778
1778
  }
1779
- e.trim !== !1 && (a = a.map((o) => mt(o)));
1780
- let v = a.join(`
1781
- `), g = v[Symbol.iterator](), m = g.next(), A = g.next(), V = 0;
1779
+ s.trim !== !1 && (l = l.map((h) => vt(h)));
1780
+ let E = l.join(`
1781
+ `), g = E[Symbol.iterator](), m = g.next(), A = g.next(), V2 = 0;
1782
1782
  for (; !m.done; ) {
1783
- let o = m.value, u = A.value;
1784
- if (i += o, o === W || o === X) {
1785
- tt.lastIndex = V + 1;
1786
- let f = tt.exec(v)?.groups;
1787
- if (f?.code !== void 0) {
1788
- let d2 = Number.parseFloat(f.code);
1789
- r = d2 === Ft ? void 0 : d2;
1790
- } else f?.uri !== void 0 && (n = f.uri.length === 0 ? void 0 : f.uri);
1791
- }
1792
- let p = r ? ft(r) : void 0;
1783
+ let h = m.value, u = A.value;
1784
+ if (i += h, h === W || h === Z) {
1785
+ et.lastIndex = V2 + 1;
1786
+ let p = et.exec(E)?.groups;
1787
+ if (p?.code !== void 0) {
1788
+ let d2 = Number.parseFloat(p.code);
1789
+ r = d2 === pt ? void 0 : d2;
1790
+ } else p?.uri !== void 0 && (n = p.uri.length === 0 ? void 0 : p.uri);
1791
+ }
1792
+ let f = r ? mt(r) : void 0;
1793
1793
  u === `
1794
- ` ? (n && (i += et("")), r && p && (i += st(p))) : o === `
1795
- ` && (r && p && (i += st(r)), n && (i += et(n))), V += o.length, m = A, A = g.next();
1794
+ ` ? (n && (i += it("")), r && f && (i += st(f))) : h === `
1795
+ ` && (r && f && (i += st(r)), n && (i += it(n))), V2 += h.length, m = A, A = g.next();
1796
1796
  }
1797
1797
  return i;
1798
1798
  };
1799
- function it(t2, s, e) {
1799
+ function K(t2, e, s) {
1800
1800
  return String(t2).normalize().replaceAll(`\r
1801
1801
  `, `
1802
1802
  `).split(`
1803
- `).map((i) => gt(i, s, e)).join(`
1803
+ `).map((i) => Et(i, e, s)).join(`
1804
1804
  `);
1805
1805
  }
1806
- var Et = ["up", "down", "left", "right", "space", "enter", "cancel"], b = { actions: new Set(Et), aliases: /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" } };
1807
- function G(t2, s) {
1808
- if (typeof t2 == "string") return b.aliases.get(t2) === s;
1809
- for (let e of t2) if (e !== void 0 && G(e, s)) return !0;
1806
+ var At = ["up", "down", "left", "right", "space", "enter", "cancel"], _ = { actions: new Set(At), aliases: /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" }, withGuide: !0 };
1807
+ function H(t2, e) {
1808
+ if (typeof t2 == "string") return _.aliases.get(t2) === e;
1809
+ for (let s of t2) if (s !== void 0 && H(s, e)) return !0;
1810
1810
  return !1;
1811
1811
  }
1812
- function At(t2, s) {
1813
- if (t2 === s) return;
1814
- let e = t2.split(`
1815
- `), i = s.split(`
1816
- `), r = [];
1817
- for (let n = 0; n < Math.max(e.length, i.length); n++) e[n] !== i[n] && r.push(n);
1818
- return r;
1812
+ function _t(t2, e) {
1813
+ if (t2 === e) return;
1814
+ let s = t2.split(`
1815
+ `), i = e.split(`
1816
+ `), r = Math.max(s.length, i.length), n = [];
1817
+ for (let o = 0; o < r; o++) s[o] !== i[o] && n.push(o);
1818
+ return { lines: n, numLinesBefore: s.length, numLinesAfter: i.length, numLines: r };
1819
1819
  }
1820
- var It = globalThis.process.platform.startsWith("win"), K = Symbol("clack:cancel");
1821
- function _t(t2) {
1822
- return t2 === K;
1820
+ var bt = globalThis.process.platform.startsWith("win"), z = Symbol("clack:cancel");
1821
+ function Ct(t2) {
1822
+ return t2 === z;
1823
1823
  }
1824
- function T(t2, s) {
1825
- let e = t2;
1826
- e.isTTY && e.setRawMode(s);
1824
+ function T(t2, e) {
1825
+ let s = t2;
1826
+ s.isTTY && s.setRawMode(e);
1827
1827
  }
1828
- function bt({ input: t2 = Y, output: s = z, overwrite: e = !0, hideCursor: i = !0 } = {}) {
1829
- let r = k.createInterface({ input: t2, output: s, prompt: "", tabSize: 1 });
1830
- k.emitKeypressEvents(t2, r), t2 instanceof q && t2.isTTY && t2.setRawMode(!0);
1831
- let n = (F, { name: l, sequence: a }) => {
1832
- let v = String(F);
1833
- if (G([v, l, a], "cancel")) {
1834
- i && s.write(import_sisteransi.cursor.show), process.exit(0);
1828
+ function xt({ input: t2 = q, output: e = R, overwrite: s = !0, hideCursor: i = !0 } = {}) {
1829
+ let r = k.createInterface({ input: t2, output: e, prompt: "", tabSize: 1 });
1830
+ k.emitKeypressEvents(t2, r), t2 instanceof J && t2.isTTY && t2.setRawMode(!0);
1831
+ let n = (o, { name: a, sequence: l }) => {
1832
+ let E = String(o);
1833
+ if (H([E, a, l], "cancel")) {
1834
+ i && e.write(import_sisteransi.cursor.show), process.exit(0);
1835
1835
  return;
1836
1836
  }
1837
- if (!e) return;
1838
- k.moveCursor(s, l === "return" ? 0 : -1, l === "return" ? -1 : 0, () => {
1839
- k.clearLine(s, 1, () => {
1837
+ if (!s) return;
1838
+ k.moveCursor(e, a === "return" ? 0 : -1, a === "return" ? -1 : 0, () => {
1839
+ k.clearLine(e, 1, () => {
1840
1840
  t2.once("keypress", n);
1841
1841
  });
1842
1842
  });
1843
1843
  };
1844
- return i && s.write(import_sisteransi.cursor.hide), t2.once("keypress", n), () => {
1845
- t2.off("keypress", n), i && s.write(import_sisteransi.cursor.show), t2 instanceof q && t2.isTTY && !It && t2.setRawMode(!1), r.terminal = !1, r.close();
1844
+ return i && e.write(import_sisteransi.cursor.hide), t2.once("keypress", n), () => {
1845
+ t2.off("keypress", n), i && e.write(import_sisteransi.cursor.show), t2 instanceof J && t2.isTTY && !bt && t2.setRawMode(!1), r.terminal = !1, r.close();
1846
1846
  };
1847
1847
  }
1848
- var Ct = (t2) => "columns" in t2 && typeof t2.columns == "number" ? t2.columns : 80, Bt = (t2) => "rows" in t2 && typeof t2.rows == "number" ? t2.rows : 20, B = class {
1848
+ var rt = (t2) => "columns" in t2 && typeof t2.columns == "number" ? t2.columns : 80, nt = (t2) => "rows" in t2 && typeof t2.rows == "number" ? t2.rows : 20;
1849
+ function Bt(t2, e, s, i = s) {
1850
+ let r = rt(t2 ?? R);
1851
+ return K(e, r - s.length, { hard: !0, trim: !1 }).split(`
1852
+ `).map((n, o) => `${o === 0 ? i : s}${n}`).join(`
1853
+ `);
1854
+ }
1855
+ var x = class {
1849
1856
  input;
1850
1857
  output;
1851
1858
  _abortSignal;
@@ -1860,162 +1867,171 @@ var Ct = (t2) => "columns" in t2 && typeof t2.columns == "number" ? t2.columns :
1860
1867
  error = "";
1861
1868
  value;
1862
1869
  userInput = "";
1863
- constructor(s, e = !0) {
1864
- let { input: i = Y, output: r = z, render: n, signal: F, ...l } = s;
1865
- this.opts = l, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = e, this._abortSignal = F, this.input = i, this.output = r;
1870
+ constructor(e, s = !0) {
1871
+ let { input: i = q, output: r = R, render: n, signal: o, ...a } = e;
1872
+ this.opts = a, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = s, this._abortSignal = o, this.input = i, this.output = r;
1866
1873
  }
1867
1874
  unsubscribe() {
1868
1875
  this._subscribers.clear();
1869
1876
  }
1870
- setSubscriber(s, e) {
1871
- let i = this._subscribers.get(s) ?? [];
1872
- i.push(e), this._subscribers.set(s, i);
1877
+ setSubscriber(e, s) {
1878
+ let i = this._subscribers.get(e) ?? [];
1879
+ i.push(s), this._subscribers.set(e, i);
1873
1880
  }
1874
- on(s, e) {
1875
- this.setSubscriber(s, { cb: e });
1881
+ on(e, s) {
1882
+ this.setSubscriber(e, { cb: s });
1876
1883
  }
1877
- once(s, e) {
1878
- this.setSubscriber(s, { cb: e, once: !0 });
1884
+ once(e, s) {
1885
+ this.setSubscriber(e, { cb: s, once: !0 });
1879
1886
  }
1880
- emit(s, ...e) {
1881
- let i = this._subscribers.get(s) ?? [], r = [];
1882
- for (let n of i) n.cb(...e), n.once && r.push(() => i.splice(i.indexOf(n), 1));
1887
+ emit(e, ...s) {
1888
+ let i = this._subscribers.get(e) ?? [], r = [];
1889
+ for (let n of i) n.cb(...s), n.once && r.push(() => i.splice(i.indexOf(n), 1));
1883
1890
  for (let n of r) n();
1884
1891
  }
1885
1892
  prompt() {
1886
- return new Promise((s) => {
1893
+ return new Promise((e) => {
1887
1894
  if (this._abortSignal) {
1888
- if (this._abortSignal.aborted) return this.state = "cancel", this.close(), s(K);
1895
+ if (this._abortSignal.aborted) return this.state = "cancel", this.close(), e(z);
1889
1896
  this._abortSignal.addEventListener("abort", () => {
1890
1897
  this.state = "cancel", this.close();
1891
1898
  }, { once: !0 });
1892
1899
  }
1893
- this.rl = nt.createInterface({ input: this.input, tabSize: 2, prompt: "", escapeCodeTimeout: 50, terminal: !0 }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, !0), this.input.on("keypress", this.onKeypress), T(this.input, !0), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
1894
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), T(this.input, !1), s(this.value);
1900
+ this.rl = ot.createInterface({ input: this.input, tabSize: 2, prompt: "", escapeCodeTimeout: 50, terminal: !0 }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, !0), this.input.on("keypress", this.onKeypress), T(this.input, !0), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
1901
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), T(this.input, !1), e(this.value);
1895
1902
  }), this.once("cancel", () => {
1896
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), T(this.input, !1), s(K);
1903
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), T(this.input, !1), e(z);
1897
1904
  });
1898
1905
  });
1899
1906
  }
1900
- _isActionKey(s, e) {
1901
- return s === " ";
1907
+ _isActionKey(e, s) {
1908
+ return e === " ";
1902
1909
  }
1903
- _setValue(s) {
1904
- this.value = s, this.emit("value", this.value);
1910
+ _setValue(e) {
1911
+ this.value = e, this.emit("value", this.value);
1905
1912
  }
1906
- _setUserInput(s, e) {
1907
- this.userInput = s ?? "", this.emit("userInput", this.userInput), e && this._track && this.rl && (this.rl.write(this.userInput), this._cursor = this.rl.cursor);
1913
+ _setUserInput(e, s) {
1914
+ this.userInput = e ?? "", this.emit("userInput", this.userInput), s && this._track && this.rl && (this.rl.write(this.userInput), this._cursor = this.rl.cursor);
1908
1915
  }
1909
1916
  _clearUserInput() {
1910
1917
  this.rl?.write(null, { ctrl: !0, name: "u" }), this._setUserInput("");
1911
1918
  }
1912
- onKeypress(s, e) {
1913
- if (this._track && e.name !== "return" && (e.name && this._isActionKey(s, e) && this.rl?.write(null, { ctrl: !0, name: "h" }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && b.aliases.has(e.name) && this.emit("cursor", b.aliases.get(e.name)), b.actions.has(e.name) && this.emit("cursor", e.name)), s && (s.toLowerCase() === "y" || s.toLowerCase() === "n") && this.emit("confirm", s.toLowerCase() === "y"), this.emit("key", s?.toLowerCase(), e), e?.name === "return") {
1919
+ onKeypress(e, s) {
1920
+ if (this._track && s.name !== "return" && (s.name && this._isActionKey(e, s) && this.rl?.write(null, { ctrl: !0, name: "h" }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), s?.name && (!this._track && _.aliases.has(s.name) && this.emit("cursor", _.aliases.get(s.name)), _.actions.has(s.name) && this.emit("cursor", s.name)), e && (e.toLowerCase() === "y" || e.toLowerCase() === "n") && this.emit("confirm", e.toLowerCase() === "y"), this.emit("key", e?.toLowerCase(), s), s?.name === "return") {
1914
1921
  if (this.opts.validate) {
1915
1922
  let i = this.opts.validate(this.value);
1916
1923
  i && (this.error = i instanceof Error ? i.message : i, this.state = "error", this.rl?.write(this.userInput));
1917
1924
  }
1918
1925
  this.state !== "error" && (this.state = "submit");
1919
1926
  }
1920
- G([s, e?.name, e?.sequence], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
1927
+ H([e, s?.name, s?.sequence], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
1921
1928
  }
1922
1929
  close() {
1923
1930
  this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
1924
1931
  `), T(this.input, !1), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
1925
1932
  }
1926
1933
  restoreCursor() {
1927
- let s = it(this._prevFrame, process.stdout.columns, { hard: !0, trim: !1 }).split(`
1934
+ let e = K(this._prevFrame, process.stdout.columns, { hard: !0, trim: !1 }).split(`
1928
1935
  `).length - 1;
1929
- this.output.write(import_sisteransi.cursor.move(-999, s * -1));
1936
+ this.output.write(import_sisteransi.cursor.move(-999, e * -1));
1930
1937
  }
1931
1938
  render() {
1932
- let s = it(this._render(this) ?? "", process.stdout.columns, { hard: !0, trim: !1 });
1933
- if (s !== this._prevFrame) {
1939
+ let e = K(this._render(this) ?? "", process.stdout.columns, { hard: !0, trim: !1 });
1940
+ if (e !== this._prevFrame) {
1934
1941
  if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
1935
1942
  else {
1936
- let e = At(this._prevFrame, s);
1937
- if (this.restoreCursor(), e && e?.length === 1) {
1938
- let i = e[0];
1939
- this.output.write(import_sisteransi.cursor.move(0, i)), this.output.write(import_sisteransi.erase.lines(1));
1940
- let r = s.split(`
1943
+ let s = _t(this._prevFrame, e), i = nt(this.output);
1944
+ if (this.restoreCursor(), s) {
1945
+ let r = Math.max(0, s.numLinesAfter - i), n = Math.max(0, s.numLinesBefore - i), o = s.lines.find((a) => a >= r);
1946
+ if (o === void 0) {
1947
+ this._prevFrame = e;
1948
+ return;
1949
+ }
1950
+ if (s.lines.length === 1) {
1951
+ this.output.write(import_sisteransi.cursor.move(0, o - n)), this.output.write(import_sisteransi.erase.lines(1));
1952
+ let a = e.split(`
1941
1953
  `);
1942
- this.output.write(r[i]), this._prevFrame = s, this.output.write(import_sisteransi.cursor.move(0, r.length - i - 1));
1943
- return;
1944
- }
1945
- if (e && e?.length > 1) {
1946
- let i = e[0];
1947
- this.output.write(import_sisteransi.cursor.move(0, i)), this.output.write(import_sisteransi.erase.down());
1948
- let r = s.split(`
1949
- `).slice(i);
1950
- this.output.write(r.join(`
1951
- `)), this._prevFrame = s;
1952
- return;
1954
+ this.output.write(a[o]), this._prevFrame = e, this.output.write(import_sisteransi.cursor.move(0, a.length - o - 1));
1955
+ return;
1956
+ } else if (s.lines.length > 1) {
1957
+ if (r < n) o = r;
1958
+ else {
1959
+ let l = o - n;
1960
+ l > 0 && this.output.write(import_sisteransi.cursor.move(0, l));
1961
+ }
1962
+ this.output.write(import_sisteransi.erase.down());
1963
+ let a = e.split(`
1964
+ `).slice(o);
1965
+ this.output.write(a.join(`
1966
+ `)), this._prevFrame = e;
1967
+ return;
1968
+ }
1953
1969
  }
1954
1970
  this.output.write(import_sisteransi.erase.down());
1955
1971
  }
1956
- this.output.write(s), this.state === "initial" && (this.state = "active"), this._prevFrame = s;
1972
+ this.output.write(e), this.state === "initial" && (this.state = "active"), this._prevFrame = e;
1957
1973
  }
1958
1974
  }
1959
1975
  };
1960
- var Vt = class extends B {
1976
+ var kt = class extends x {
1961
1977
  get cursor() {
1962
1978
  return this.value ? 0 : 1;
1963
1979
  }
1964
1980
  get _value() {
1965
1981
  return this.cursor === 0;
1966
1982
  }
1967
- constructor(s) {
1968
- super(s, !1), this.value = !!s.initialValue, this.on("userInput", () => {
1983
+ constructor(e) {
1984
+ super(e, !1), this.value = !!e.initialValue, this.on("userInput", () => {
1969
1985
  this.value = this._value;
1970
- }), this.on("confirm", (e) => {
1971
- this.output.write(import_sisteransi.cursor.move(0, -1)), this.value = e, this.state = "submit", this.close();
1986
+ }), this.on("confirm", (s) => {
1987
+ this.output.write(import_sisteransi.cursor.move(0, -1)), this.value = s, this.state = "submit", this.close();
1972
1988
  }), this.on("cursor", () => {
1973
1989
  this.value = !this.value;
1974
1990
  });
1975
1991
  }
1976
1992
  };
1977
- function w(t2, s, e) {
1978
- let i = t2 + s, r = Math.max(e.length - 1, 0), n = i < 0 ? r : i > r ? 0 : i;
1979
- return e[n].disabled ? w(n, s < 0 ? -1 : 1, e) : n;
1993
+ function D(t2, e, s) {
1994
+ let i = t2 + e, r = Math.max(s.length - 1, 0), n = i < 0 ? r : i > r ? 0 : i;
1995
+ return s[n].disabled ? D(n, e < 0 ? -1 : 1, s) : n;
1980
1996
  }
1981
- var yt = class extends B {
1997
+ var Mt = class extends x {
1982
1998
  options;
1983
1999
  cursor = 0;
1984
2000
  get _value() {
1985
2001
  return this.options[this.cursor].value;
1986
2002
  }
1987
2003
  get _enabledOptions() {
1988
- return this.options.filter((s) => s.disabled !== !0);
2004
+ return this.options.filter((e) => e.disabled !== !0);
1989
2005
  }
1990
2006
  toggleAll() {
1991
- let s = this._enabledOptions, e = this.value !== void 0 && this.value.length === s.length;
1992
- this.value = e ? [] : s.map((i) => i.value);
2007
+ let e = this._enabledOptions, s = this.value !== void 0 && this.value.length === e.length;
2008
+ this.value = s ? [] : e.map((i) => i.value);
1993
2009
  }
1994
2010
  toggleInvert() {
1995
- let s = this.value;
1996
- if (!s) return;
1997
- let e = this._enabledOptions.filter((i) => !s.includes(i.value));
1998
- this.value = e.map((i) => i.value);
2011
+ let e = this.value;
2012
+ if (!e) return;
2013
+ let s = this._enabledOptions.filter((i) => !e.includes(i.value));
2014
+ this.value = s.map((i) => i.value);
1999
2015
  }
2000
2016
  toggleValue() {
2001
2017
  this.value === void 0 && (this.value = []);
2002
- let s = this.value.includes(this._value);
2003
- this.value = s ? this.value.filter((e) => e !== this._value) : [...this.value, this._value];
2018
+ let e = this.value.includes(this._value);
2019
+ this.value = e ? this.value.filter((s) => s !== this._value) : [...this.value, this._value];
2004
2020
  }
2005
- constructor(s) {
2006
- super(s, !1), this.options = s.options, this.value = [...s.initialValues ?? []];
2007
- let e = Math.max(this.options.findIndex(({ value: i }) => i === s.cursorAt), 0);
2008
- this.cursor = this.options[e].disabled ? w(e, 1, this.options) : e, this.on("key", (i) => {
2021
+ constructor(e) {
2022
+ super(e, !1), this.options = e.options, this.value = [...e.initialValues ?? []];
2023
+ let s = Math.max(this.options.findIndex(({ value: i }) => i === e.cursorAt), 0);
2024
+ this.cursor = this.options[s].disabled ? D(s, 1, this.options) : s, this.on("key", (i) => {
2009
2025
  i === "a" && this.toggleAll(), i === "i" && this.toggleInvert();
2010
2026
  }), this.on("cursor", (i) => {
2011
2027
  switch (i) {
2012
2028
  case "left":
2013
2029
  case "up":
2014
- this.cursor = w(this.cursor, -1, this.options);
2030
+ this.cursor = D(this.cursor, -1, this.options);
2015
2031
  break;
2016
2032
  case "down":
2017
2033
  case "right":
2018
- this.cursor = w(this.cursor, 1, this.options);
2034
+ this.cursor = D(this.cursor, 1, this.options);
2019
2035
  break;
2020
2036
  case "space":
2021
2037
  this.toggleValue();
@@ -2024,7 +2040,7 @@ var yt = class extends B {
2024
2040
  });
2025
2041
  }
2026
2042
  };
2027
- var Lt = class extends B {
2043
+ var Wt = class extends x {
2028
2044
  options;
2029
2045
  cursor = 0;
2030
2046
  get _selectedValue() {
@@ -2033,40 +2049,40 @@ var Lt = class extends B {
2033
2049
  changeValue() {
2034
2050
  this.value = this._selectedValue.value;
2035
2051
  }
2036
- constructor(s) {
2037
- super(s, !1), this.options = s.options;
2038
- let e = this.options.findIndex(({ value: r }) => r === s.initialValue), i = e === -1 ? 0 : e;
2039
- this.cursor = this.options[i].disabled ? w(i, 1, this.options) : i, this.changeValue(), this.on("cursor", (r) => {
2052
+ constructor(e) {
2053
+ super(e, !1), this.options = e.options;
2054
+ let s = this.options.findIndex(({ value: r }) => r === e.initialValue), i = s === -1 ? 0 : s;
2055
+ this.cursor = this.options[i].disabled ? D(i, 1, this.options) : i, this.changeValue(), this.on("cursor", (r) => {
2040
2056
  switch (r) {
2041
2057
  case "left":
2042
2058
  case "up":
2043
- this.cursor = w(this.cursor, -1, this.options);
2059
+ this.cursor = D(this.cursor, -1, this.options);
2044
2060
  break;
2045
2061
  case "down":
2046
2062
  case "right":
2047
- this.cursor = w(this.cursor, 1, this.options);
2063
+ this.cursor = D(this.cursor, 1, this.options);
2048
2064
  break;
2049
2065
  }
2050
2066
  this.changeValue();
2051
2067
  });
2052
2068
  }
2053
2069
  };
2054
- var Tt = class extends B {
2070
+ var $t = class extends x {
2055
2071
  get userInputWithCursor() {
2056
2072
  if (this.state === "submit") return this.userInput;
2057
- let s = this.userInput;
2058
- if (this.cursor >= s.length) return `${this.userInput}\u2588`;
2059
- let e = s.slice(0, this.cursor), [i, ...r] = s.slice(this.cursor);
2060
- return `${e}${import_picocolors.default.inverse(i)}${r.join("")}`;
2073
+ let e = this.userInput;
2074
+ if (this.cursor >= e.length) return `${this.userInput}\u2588`;
2075
+ let s = e.slice(0, this.cursor), [i, ...r] = e.slice(this.cursor);
2076
+ return `${s}${import_picocolors.default.inverse(i)}${r.join("")}`;
2061
2077
  }
2062
2078
  get cursor() {
2063
2079
  return this._cursor;
2064
2080
  }
2065
- constructor(s) {
2066
- super({ ...s, initialUserInput: s.initialUserInput ?? s.initialValue }), this.on("userInput", (e) => {
2067
- this._setValue(e);
2081
+ constructor(e) {
2082
+ super({ ...e, initialUserInput: e.initialUserInput ?? e.initialValue }), this.on("userInput", (s) => {
2083
+ this._setValue(s);
2068
2084
  }), this.on("finalize", () => {
2069
- this.value || (this.value = s.defaultValue), this.value === void 0 && (this.value = "");
2085
+ this.value || (this.value = e.defaultValue), this.value === void 0 && (this.value = "");
2070
2086
  });
2071
2087
  }
2072
2088
  };
@@ -2075,82 +2091,94 @@ var Tt = class extends B {
2075
2091
  var import_picocolors2 = __toESM(require_picocolors(), 1);
2076
2092
  import N2 from "node:process";
2077
2093
  var import_sisteransi2 = __toESM(require_src(), 1);
2078
- function ut2() {
2094
+ function ht2() {
2079
2095
  return N2.platform !== "win32" ? N2.env.TERM !== "linux" : !!N2.env.CI || !!N2.env.WT_SESSION || !!N2.env.TERMINUS_SUBLIME || N2.env.ConEmuTask === "{cmd::Cmder}" || N2.env.TERM_PROGRAM === "Terminus-Sublime" || N2.env.TERM_PROGRAM === "vscode" || N2.env.TERM === "xterm-256color" || N2.env.TERM === "alacritty" || N2.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
2080
2096
  }
2081
- var z2 = ut2(), ne = () => process.env.CI === "true", Be = (e) => e.isTTY === !0, I2 = (e, i) => z2 ? e : i, be = I2("\u25C6", "*"), ae = I2("\u25A0", "x"), oe = I2("\u25B2", "x"), W2 = I2("\u25C7", "o"), le = I2("\u250C", "T"), d = I2("\u2502", "|"), x = I2("\u2514", "\u2014"), xe = I2("\u2510", "T"), _e = I2("\u2518", "\u2014"), J2 = I2("\u25CF", ">"), H = I2("\u25CB", " "), Z2 = I2("\u25FB", "[\u2022]"), j2 = I2("\u25FC", "[+]"), X2 = I2("\u25FB", "[ ]"), De = I2("\u25AA", "\u2022"), Q2 = I2("\u2500", "-"), ue = I2("\u256E", "+"), Te = I2("\u251C", "+"), ce = I2("\u256F", "+"), Me = I2("\u2570", "+"), Re = I2("\u256D", "+"), de = I2("\u25CF", "\u2022"), $e = I2("\u25C6", "*"), he = I2("\u25B2", "!"), me = I2("\u25A0", "x"), L2 = (e) => {
2097
+ var ee = ht2(), ue = () => process.env.CI === "true", Te = (e) => e.isTTY === !0, I2 = (e, r) => ee ? e : r, Me = I2("\u25C6", "*"), ce = I2("\u25A0", "x"), de = I2("\u25B2", "x"), j2 = I2("\u25C7", "o"), $e = I2("\u250C", "T"), d = I2("\u2502", "|"), x2 = I2("\u2514", "\u2014"), Re = I2("\u2510", "T"), Oe = I2("\u2518", "\u2014"), Y = I2("\u25CF", ">"), K2 = I2("\u25CB", " "), te = I2("\u25FB", "[\u2022]"), V = I2("\u25FC", "[+]"), z2 = I2("\u25FB", "[ ]"), Ne = I2("\u25AA", "\u2022"), se = I2("\u2500", "-"), he = I2("\u256E", "+"), Pe = I2("\u251C", "+"), me = I2("\u256F", "+"), pe = I2("\u2570", "+"), We = I2("\u256D", "+"), ge = I2("\u25CF", "\u2022"), fe = I2("\u25C6", "*"), Fe = I2("\u25B2", "!"), ye = I2("\u25A0", "x"), W2 = (e) => {
2082
2098
  switch (e) {
2083
2099
  case "initial":
2084
2100
  case "active":
2085
- return import_picocolors2.default.cyan(be);
2101
+ return import_picocolors2.default.cyan(Me);
2086
2102
  case "cancel":
2087
- return import_picocolors2.default.red(ae);
2103
+ return import_picocolors2.default.red(ce);
2088
2104
  case "error":
2089
- return import_picocolors2.default.yellow(oe);
2105
+ return import_picocolors2.default.yellow(de);
2090
2106
  case "submit":
2091
- return import_picocolors2.default.green(W2);
2107
+ return import_picocolors2.default.green(j2);
2092
2108
  }
2093
- }, ct2 = (e) => e === 161 || e === 164 || e === 167 || e === 168 || e === 170 || e === 173 || e === 174 || e >= 176 && e <= 180 || e >= 182 && e <= 186 || e >= 188 && e <= 191 || e === 198 || e === 208 || e === 215 || e === 216 || e >= 222 && e <= 225 || e === 230 || e >= 232 && e <= 234 || e === 236 || e === 237 || e === 240 || e === 242 || e === 243 || e >= 247 && e <= 250 || e === 252 || e === 254 || e === 257 || e === 273 || e === 275 || e === 283 || e === 294 || e === 295 || e === 299 || e >= 305 && e <= 307 || e === 312 || e >= 319 && e <= 322 || e === 324 || e >= 328 && e <= 331 || e === 333 || e === 338 || e === 339 || e === 358 || e === 359 || e === 363 || e === 462 || e === 464 || e === 466 || e === 468 || e === 470 || e === 472 || e === 474 || e === 476 || e === 593 || e === 609 || e === 708 || e === 711 || e >= 713 && e <= 715 || e === 717 || e === 720 || e >= 728 && e <= 731 || e === 733 || e === 735 || e >= 768 && e <= 879 || e >= 913 && e <= 929 || e >= 931 && e <= 937 || e >= 945 && e <= 961 || e >= 963 && e <= 969 || e === 1025 || e >= 1040 && e <= 1103 || e === 1105 || e === 8208 || e >= 8211 && e <= 8214 || e === 8216 || e === 8217 || e === 8220 || e === 8221 || e >= 8224 && e <= 8226 || e >= 8228 && e <= 8231 || e === 8240 || e === 8242 || e === 8243 || e === 8245 || e === 8251 || e === 8254 || e === 8308 || e === 8319 || e >= 8321 && e <= 8324 || e === 8364 || e === 8451 || e === 8453 || e === 8457 || e === 8467 || e === 8470 || e === 8481 || e === 8482 || e === 8486 || e === 8491 || e === 8531 || e === 8532 || e >= 8539 && e <= 8542 || e >= 8544 && e <= 8555 || e >= 8560 && e <= 8569 || e === 8585 || e >= 8592 && e <= 8601 || e === 8632 || e === 8633 || e === 8658 || e === 8660 || e === 8679 || e === 8704 || e === 8706 || e === 8707 || e === 8711 || e === 8712 || e === 8715 || e === 8719 || e === 8721 || e === 8725 || e === 8730 || e >= 8733 && e <= 8736 || e === 8739 || e === 8741 || e >= 8743 && e <= 8748 || e === 8750 || e >= 8756 && e <= 8759 || e === 8764 || e === 8765 || e === 8776 || e === 8780 || e === 8786 || e === 8800 || e === 8801 || e >= 8804 && e <= 8807 || e === 8810 || e === 8811 || e === 8814 || e === 8815 || e === 8834 || e === 8835 || e === 8838 || e === 8839 || e === 8853 || e === 8857 || e === 8869 || e === 8895 || e === 8978 || e >= 9312 && e <= 9449 || e >= 9451 && e <= 9547 || e >= 9552 && e <= 9587 || e >= 9600 && e <= 9615 || e >= 9618 && e <= 9621 || e === 9632 || e === 9633 || e >= 9635 && e <= 9641 || e === 9650 || e === 9651 || e === 9654 || e === 9655 || e === 9660 || e === 9661 || e === 9664 || e === 9665 || e >= 9670 && e <= 9672 || e === 9675 || e >= 9678 && e <= 9681 || e >= 9698 && e <= 9701 || e === 9711 || e === 9733 || e === 9734 || e === 9737 || e === 9742 || e === 9743 || e === 9756 || e === 9758 || e === 9792 || e === 9794 || e === 9824 || e === 9825 || e >= 9827 && e <= 9829 || e >= 9831 && e <= 9834 || e === 9836 || e === 9837 || e === 9839 || e === 9886 || e === 9887 || e === 9919 || e >= 9926 && e <= 9933 || e >= 9935 && e <= 9939 || e >= 9941 && e <= 9953 || e === 9955 || e === 9960 || e === 9961 || e >= 9963 && e <= 9969 || e === 9972 || e >= 9974 && e <= 9977 || e === 9979 || e === 9980 || e === 9982 || e === 9983 || e === 10045 || e >= 10102 && e <= 10111 || e >= 11094 && e <= 11097 || e >= 12872 && e <= 12879 || e >= 57344 && e <= 63743 || e >= 65024 && e <= 65039 || e === 65533 || e >= 127232 && e <= 127242 || e >= 127248 && e <= 127277 || e >= 127280 && e <= 127337 || e >= 127344 && e <= 127373 || e === 127375 || e === 127376 || e >= 127387 && e <= 127404 || e >= 917760 && e <= 917999 || e >= 983040 && e <= 1048573 || e >= 1048576 && e <= 1114109, dt2 = (e) => e === 12288 || e >= 65281 && e <= 65376 || e >= 65504 && e <= 65510, $t = (e) => e >= 4352 && e <= 4447 || e === 8986 || e === 8987 || e === 9001 || e === 9002 || e >= 9193 && e <= 9196 || e === 9200 || e === 9203 || e === 9725 || e === 9726 || e === 9748 || e === 9749 || e >= 9800 && e <= 9811 || e === 9855 || e === 9875 || e === 9889 || e === 9898 || e === 9899 || e === 9917 || e === 9918 || e === 9924 || e === 9925 || e === 9934 || e === 9940 || e === 9962 || e === 9970 || e === 9971 || e === 9973 || e === 9978 || e === 9981 || e === 9989 || e === 9994 || e === 9995 || e === 10024 || e === 10060 || e === 10062 || e >= 10067 && e <= 10069 || e === 10071 || e >= 10133 && e <= 10135 || e === 10160 || e === 10175 || e === 11035 || e === 11036 || e === 11088 || e === 11093 || e >= 11904 && e <= 11929 || e >= 11931 && e <= 12019 || e >= 12032 && e <= 12245 || e >= 12272 && e <= 12287 || e >= 12289 && e <= 12350 || e >= 12353 && e <= 12438 || e >= 12441 && e <= 12543 || e >= 12549 && e <= 12591 || e >= 12593 && e <= 12686 || e >= 12688 && e <= 12771 || e >= 12783 && e <= 12830 || e >= 12832 && e <= 12871 || e >= 12880 && e <= 19903 || e >= 19968 && e <= 42124 || e >= 42128 && e <= 42182 || e >= 43360 && e <= 43388 || e >= 44032 && e <= 55203 || e >= 63744 && e <= 64255 || e >= 65040 && e <= 65049 || e >= 65072 && e <= 65106 || e >= 65108 && e <= 65126 || e >= 65128 && e <= 65131 || e >= 94176 && e <= 94180 || e === 94192 || e === 94193 || e >= 94208 && e <= 100343 || e >= 100352 && e <= 101589 || e >= 101632 && e <= 101640 || e >= 110576 && e <= 110579 || e >= 110581 && e <= 110587 || e === 110589 || e === 110590 || e >= 110592 && e <= 110882 || e === 110898 || e >= 110928 && e <= 110930 || e === 110933 || e >= 110948 && e <= 110951 || e >= 110960 && e <= 111355 || e === 126980 || e === 127183 || e === 127374 || e >= 127377 && e <= 127386 || e >= 127488 && e <= 127490 || e >= 127504 && e <= 127547 || e >= 127552 && e <= 127560 || e === 127568 || e === 127569 || e >= 127584 && e <= 127589 || e >= 127744 && e <= 127776 || e >= 127789 && e <= 127797 || e >= 127799 && e <= 127868 || e >= 127870 && e <= 127891 || e >= 127904 && e <= 127946 || e >= 127951 && e <= 127955 || e >= 127968 && e <= 127984 || e === 127988 || e >= 127992 && e <= 128062 || e === 128064 || e >= 128066 && e <= 128252 || e >= 128255 && e <= 128317 || e >= 128331 && e <= 128334 || e >= 128336 && e <= 128359 || e === 128378 || e === 128405 || e === 128406 || e === 128420 || e >= 128507 && e <= 128591 || e >= 128640 && e <= 128709 || e === 128716 || e >= 128720 && e <= 128722 || e >= 128725 && e <= 128727 || e >= 128732 && e <= 128735 || e === 128747 || e === 128748 || e >= 128756 && e <= 128764 || e >= 128992 && e <= 129003 || e === 129008 || e >= 129292 && e <= 129338 || e >= 129340 && e <= 129349 || e >= 129351 && e <= 129535 || e >= 129648 && e <= 129660 || e >= 129664 && e <= 129672 || e >= 129680 && e <= 129725 || e >= 129727 && e <= 129733 || e >= 129742 && e <= 129755 || e >= 129760 && e <= 129768 || e >= 129776 && e <= 129784 || e >= 131072 && e <= 196605 || e >= 196608 && e <= 262141, pe = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, ee = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, te = /\t{1,1000}/y, ge = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu"), se = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, ht2 = new RegExp("\\p{M}+", "gu"), mt2 = { limit: 1 / 0, ellipsis: "" }, Oe = (e, i = {}, s = {}) => {
2094
- let r = i.limit ?? 1 / 0, n = i.ellipsis ?? "", o = i?.ellipsisWidth ?? (n ? Oe(n, mt2, s).width : 0), l = s.ansiWidth ?? 0, u = s.controlWidth ?? 0, a = s.tabWidth ?? 8, h = s.ambiguousWidth ?? 1, y2 = s.emojiWidth ?? 2, E = s.fullWidthWidth ?? 2, f = s.regularWidth ?? 1, F = s.wideWidth ?? 2, c = 0, m = 0, $2 = e.length, p = 0, g = !1, v = $2, S2 = Math.max(0, r - o), w2 = 0, b2 = 0, A = 0, C = 0;
2109
+ }, Ee = (e) => {
2110
+ switch (e) {
2111
+ case "initial":
2112
+ case "active":
2113
+ return import_picocolors2.default.cyan(d);
2114
+ case "cancel":
2115
+ return import_picocolors2.default.red(d);
2116
+ case "error":
2117
+ return import_picocolors2.default.yellow(d);
2118
+ case "submit":
2119
+ return import_picocolors2.default.green(d);
2120
+ }
2121
+ }, mt2 = (e) => e === 161 || e === 164 || e === 167 || e === 168 || e === 170 || e === 173 || e === 174 || e >= 176 && e <= 180 || e >= 182 && e <= 186 || e >= 188 && e <= 191 || e === 198 || e === 208 || e === 215 || e === 216 || e >= 222 && e <= 225 || e === 230 || e >= 232 && e <= 234 || e === 236 || e === 237 || e === 240 || e === 242 || e === 243 || e >= 247 && e <= 250 || e === 252 || e === 254 || e === 257 || e === 273 || e === 275 || e === 283 || e === 294 || e === 295 || e === 299 || e >= 305 && e <= 307 || e === 312 || e >= 319 && e <= 322 || e === 324 || e >= 328 && e <= 331 || e === 333 || e === 338 || e === 339 || e === 358 || e === 359 || e === 363 || e === 462 || e === 464 || e === 466 || e === 468 || e === 470 || e === 472 || e === 474 || e === 476 || e === 593 || e === 609 || e === 708 || e === 711 || e >= 713 && e <= 715 || e === 717 || e === 720 || e >= 728 && e <= 731 || e === 733 || e === 735 || e >= 768 && e <= 879 || e >= 913 && e <= 929 || e >= 931 && e <= 937 || e >= 945 && e <= 961 || e >= 963 && e <= 969 || e === 1025 || e >= 1040 && e <= 1103 || e === 1105 || e === 8208 || e >= 8211 && e <= 8214 || e === 8216 || e === 8217 || e === 8220 || e === 8221 || e >= 8224 && e <= 8226 || e >= 8228 && e <= 8231 || e === 8240 || e === 8242 || e === 8243 || e === 8245 || e === 8251 || e === 8254 || e === 8308 || e === 8319 || e >= 8321 && e <= 8324 || e === 8364 || e === 8451 || e === 8453 || e === 8457 || e === 8467 || e === 8470 || e === 8481 || e === 8482 || e === 8486 || e === 8491 || e === 8531 || e === 8532 || e >= 8539 && e <= 8542 || e >= 8544 && e <= 8555 || e >= 8560 && e <= 8569 || e === 8585 || e >= 8592 && e <= 8601 || e === 8632 || e === 8633 || e === 8658 || e === 8660 || e === 8679 || e === 8704 || e === 8706 || e === 8707 || e === 8711 || e === 8712 || e === 8715 || e === 8719 || e === 8721 || e === 8725 || e === 8730 || e >= 8733 && e <= 8736 || e === 8739 || e === 8741 || e >= 8743 && e <= 8748 || e === 8750 || e >= 8756 && e <= 8759 || e === 8764 || e === 8765 || e === 8776 || e === 8780 || e === 8786 || e === 8800 || e === 8801 || e >= 8804 && e <= 8807 || e === 8810 || e === 8811 || e === 8814 || e === 8815 || e === 8834 || e === 8835 || e === 8838 || e === 8839 || e === 8853 || e === 8857 || e === 8869 || e === 8895 || e === 8978 || e >= 9312 && e <= 9449 || e >= 9451 && e <= 9547 || e >= 9552 && e <= 9587 || e >= 9600 && e <= 9615 || e >= 9618 && e <= 9621 || e === 9632 || e === 9633 || e >= 9635 && e <= 9641 || e === 9650 || e === 9651 || e === 9654 || e === 9655 || e === 9660 || e === 9661 || e === 9664 || e === 9665 || e >= 9670 && e <= 9672 || e === 9675 || e >= 9678 && e <= 9681 || e >= 9698 && e <= 9701 || e === 9711 || e === 9733 || e === 9734 || e === 9737 || e === 9742 || e === 9743 || e === 9756 || e === 9758 || e === 9792 || e === 9794 || e === 9824 || e === 9825 || e >= 9827 && e <= 9829 || e >= 9831 && e <= 9834 || e === 9836 || e === 9837 || e === 9839 || e === 9886 || e === 9887 || e === 9919 || e >= 9926 && e <= 9933 || e >= 9935 && e <= 9939 || e >= 9941 && e <= 9953 || e === 9955 || e === 9960 || e === 9961 || e >= 9963 && e <= 9969 || e === 9972 || e >= 9974 && e <= 9977 || e === 9979 || e === 9980 || e === 9982 || e === 9983 || e === 10045 || e >= 10102 && e <= 10111 || e >= 11094 && e <= 11097 || e >= 12872 && e <= 12879 || e >= 57344 && e <= 63743 || e >= 65024 && e <= 65039 || e === 65533 || e >= 127232 && e <= 127242 || e >= 127248 && e <= 127277 || e >= 127280 && e <= 127337 || e >= 127344 && e <= 127373 || e === 127375 || e === 127376 || e >= 127387 && e <= 127404 || e >= 917760 && e <= 917999 || e >= 983040 && e <= 1048573 || e >= 1048576 && e <= 1114109, pt2 = (e) => e === 12288 || e >= 65281 && e <= 65376 || e >= 65504 && e <= 65510, gt2 = (e) => e >= 4352 && e <= 4447 || e === 8986 || e === 8987 || e === 9001 || e === 9002 || e >= 9193 && e <= 9196 || e === 9200 || e === 9203 || e === 9725 || e === 9726 || e === 9748 || e === 9749 || e >= 9800 && e <= 9811 || e === 9855 || e === 9875 || e === 9889 || e === 9898 || e === 9899 || e === 9917 || e === 9918 || e === 9924 || e === 9925 || e === 9934 || e === 9940 || e === 9962 || e === 9970 || e === 9971 || e === 9973 || e === 9978 || e === 9981 || e === 9989 || e === 9994 || e === 9995 || e === 10024 || e === 10060 || e === 10062 || e >= 10067 && e <= 10069 || e === 10071 || e >= 10133 && e <= 10135 || e === 10160 || e === 10175 || e === 11035 || e === 11036 || e === 11088 || e === 11093 || e >= 11904 && e <= 11929 || e >= 11931 && e <= 12019 || e >= 12032 && e <= 12245 || e >= 12272 && e <= 12287 || e >= 12289 && e <= 12350 || e >= 12353 && e <= 12438 || e >= 12441 && e <= 12543 || e >= 12549 && e <= 12591 || e >= 12593 && e <= 12686 || e >= 12688 && e <= 12771 || e >= 12783 && e <= 12830 || e >= 12832 && e <= 12871 || e >= 12880 && e <= 19903 || e >= 19968 && e <= 42124 || e >= 42128 && e <= 42182 || e >= 43360 && e <= 43388 || e >= 44032 && e <= 55203 || e >= 63744 && e <= 64255 || e >= 65040 && e <= 65049 || e >= 65072 && e <= 65106 || e >= 65108 && e <= 65126 || e >= 65128 && e <= 65131 || e >= 94176 && e <= 94180 || e === 94192 || e === 94193 || e >= 94208 && e <= 100343 || e >= 100352 && e <= 101589 || e >= 101632 && e <= 101640 || e >= 110576 && e <= 110579 || e >= 110581 && e <= 110587 || e === 110589 || e === 110590 || e >= 110592 && e <= 110882 || e === 110898 || e >= 110928 && e <= 110930 || e === 110933 || e >= 110948 && e <= 110951 || e >= 110960 && e <= 111355 || e === 126980 || e === 127183 || e === 127374 || e >= 127377 && e <= 127386 || e >= 127488 && e <= 127490 || e >= 127504 && e <= 127547 || e >= 127552 && e <= 127560 || e === 127568 || e === 127569 || e >= 127584 && e <= 127589 || e >= 127744 && e <= 127776 || e >= 127789 && e <= 127797 || e >= 127799 && e <= 127868 || e >= 127870 && e <= 127891 || e >= 127904 && e <= 127946 || e >= 127951 && e <= 127955 || e >= 127968 && e <= 127984 || e === 127988 || e >= 127992 && e <= 128062 || e === 128064 || e >= 128066 && e <= 128252 || e >= 128255 && e <= 128317 || e >= 128331 && e <= 128334 || e >= 128336 && e <= 128359 || e === 128378 || e === 128405 || e === 128406 || e === 128420 || e >= 128507 && e <= 128591 || e >= 128640 && e <= 128709 || e === 128716 || e >= 128720 && e <= 128722 || e >= 128725 && e <= 128727 || e >= 128732 && e <= 128735 || e === 128747 || e === 128748 || e >= 128756 && e <= 128764 || e >= 128992 && e <= 129003 || e === 129008 || e >= 129292 && e <= 129338 || e >= 129340 && e <= 129349 || e >= 129351 && e <= 129535 || e >= 129648 && e <= 129660 || e >= 129664 && e <= 129672 || e >= 129680 && e <= 129725 || e >= 129727 && e <= 129733 || e >= 129742 && e <= 129755 || e >= 129760 && e <= 129768 || e >= 129776 && e <= 129784 || e >= 131072 && e <= 196605 || e >= 196608 && e <= 262141, ve = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, re = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, ie = /\t{1,1000}/y, Ae = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu"), ne = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, ft2 = new RegExp("\\p{M}+", "gu"), Ft2 = { limit: 1 / 0, ellipsis: "" }, Le = (e, r = {}, s = {}) => {
2122
+ let i = r.limit ?? 1 / 0, n = r.ellipsis ?? "", l = r?.ellipsisWidth ?? (n ? Le(n, Ft2, s).width : 0), u = s.ansiWidth ?? 0, a = s.controlWidth ?? 0, o = s.tabWidth ?? 8, $ = s.ambiguousWidth ?? 1, y2 = s.emojiWidth ?? 2, E = s.fullWidthWidth ?? 2, p = s.regularWidth ?? 1, f = s.wideWidth ?? 2, c = 0, m = 0, h = e.length, g = 0, F = !1, v = h, S2 = Math.max(0, i - l), B = 0, b = 0, A = 0, C = 0;
2095
2123
  e: for (; ; ) {
2096
- if (b2 > w2 || m >= $2 && m > c) {
2097
- let _ = e.slice(w2, b2) || e.slice(c, m);
2098
- p = 0;
2099
- for (let D2 of _.replaceAll(ht2, "")) {
2124
+ if (b > B || m >= h && m > c) {
2125
+ let _2 = e.slice(B, b) || e.slice(c, m);
2126
+ g = 0;
2127
+ for (let D2 of _2.replaceAll(ft2, "")) {
2100
2128
  let T2 = D2.codePointAt(0) || 0;
2101
- if (dt2(T2) ? C = E : $t(T2) ? C = F : h !== f && ct2(T2) ? C = h : C = f, A + C > S2 && (v = Math.min(v, Math.max(w2, c) + p)), A + C > r) {
2102
- g = !0;
2129
+ if (pt2(T2) ? C = E : gt2(T2) ? C = f : $ !== p && mt2(T2) ? C = $ : C = p, A + C > S2 && (v = Math.min(v, Math.max(B, c) + g)), A + C > i) {
2130
+ F = !0;
2103
2131
  break e;
2104
2132
  }
2105
- p += D2.length, A += C;
2133
+ g += D2.length, A += C;
2106
2134
  }
2107
- w2 = b2 = 0;
2135
+ B = b = 0;
2108
2136
  }
2109
- if (m >= $2) break;
2110
- if (se.lastIndex = m, se.test(e)) {
2111
- if (p = se.lastIndex - m, C = p * f, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / f))), A + C > r) {
2112
- g = !0;
2137
+ if (m >= h) break;
2138
+ if (ne.lastIndex = m, ne.test(e)) {
2139
+ if (g = ne.lastIndex - m, C = g * p, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / p))), A + C > i) {
2140
+ F = !0;
2113
2141
  break;
2114
2142
  }
2115
- A += C, w2 = c, b2 = m, m = c = se.lastIndex;
2143
+ A += C, B = c, b = m, m = c = ne.lastIndex;
2116
2144
  continue;
2117
2145
  }
2118
- if (pe.lastIndex = m, pe.test(e)) {
2119
- if (A + l > S2 && (v = Math.min(v, m)), A + l > r) {
2120
- g = !0;
2146
+ if (ve.lastIndex = m, ve.test(e)) {
2147
+ if (A + u > S2 && (v = Math.min(v, m)), A + u > i) {
2148
+ F = !0;
2121
2149
  break;
2122
2150
  }
2123
- A += l, w2 = c, b2 = m, m = c = pe.lastIndex;
2151
+ A += u, B = c, b = m, m = c = ve.lastIndex;
2124
2152
  continue;
2125
2153
  }
2126
- if (ee.lastIndex = m, ee.test(e)) {
2127
- if (p = ee.lastIndex - m, C = p * u, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / u))), A + C > r) {
2128
- g = !0;
2154
+ if (re.lastIndex = m, re.test(e)) {
2155
+ if (g = re.lastIndex - m, C = g * a, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / a))), A + C > i) {
2156
+ F = !0;
2129
2157
  break;
2130
2158
  }
2131
- A += C, w2 = c, b2 = m, m = c = ee.lastIndex;
2159
+ A += C, B = c, b = m, m = c = re.lastIndex;
2132
2160
  continue;
2133
2161
  }
2134
- if (te.lastIndex = m, te.test(e)) {
2135
- if (p = te.lastIndex - m, C = p * a, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / a))), A + C > r) {
2136
- g = !0;
2162
+ if (ie.lastIndex = m, ie.test(e)) {
2163
+ if (g = ie.lastIndex - m, C = g * o, A + C > S2 && (v = Math.min(v, m + Math.floor((S2 - A) / o))), A + C > i) {
2164
+ F = !0;
2137
2165
  break;
2138
2166
  }
2139
- A += C, w2 = c, b2 = m, m = c = te.lastIndex;
2167
+ A += C, B = c, b = m, m = c = ie.lastIndex;
2140
2168
  continue;
2141
2169
  }
2142
- if (ge.lastIndex = m, ge.test(e)) {
2143
- if (A + y2 > S2 && (v = Math.min(v, m)), A + y2 > r) {
2144
- g = !0;
2170
+ if (Ae.lastIndex = m, Ae.test(e)) {
2171
+ if (A + y2 > S2 && (v = Math.min(v, m)), A + y2 > i) {
2172
+ F = !0;
2145
2173
  break;
2146
2174
  }
2147
- A += y2, w2 = c, b2 = m, m = c = ge.lastIndex;
2175
+ A += y2, B = c, b = m, m = c = Ae.lastIndex;
2148
2176
  continue;
2149
2177
  }
2150
2178
  m += 1;
2151
2179
  }
2152
- return { width: g ? S2 : A, index: g ? v : $2, truncated: g, ellipsed: g && r >= o };
2153
- }, pt2 = { limit: 1 / 0, ellipsis: "", ellipsisWidth: 0 }, M2 = (e, i = {}) => Oe(e, pt2, i).width, re = "\x1B", Ne = "\x9B", gt2 = 39, fe = "\x07", Pe = "[", ft2 = "]", Le = "m", Fe = `${ft2}8;;`, We = new RegExp(`(?:\\${Pe}(?<code>\\d+)m|\\${Fe}(?<uri>.*)${fe})`, "y"), Ft2 = (e) => {
2180
+ return { width: F ? S2 : A, index: F ? v : h, truncated: F, ellipsed: F && i >= l };
2181
+ }, yt2 = { limit: 1 / 0, ellipsis: "", ellipsisWidth: 0 }, M2 = (e, r = {}) => Le(e, yt2, r).width, ae = "\x1B", je = "\x9B", Et2 = 39, Ce = "\x07", Ve = "[", vt2 = "]", ke = "m", Ie = `${vt2}8;;`, Ge = new RegExp(`(?:\\${Ve}(?<code>\\d+)m|\\${Ie}(?<uri>.*)${Ce})`, "y"), At2 = (e) => {
2154
2182
  if (e >= 30 && e <= 37 || e >= 90 && e <= 97) return 39;
2155
2183
  if (e >= 40 && e <= 47 || e >= 100 && e <= 107) return 49;
2156
2184
  if (e === 1 || e === 2) return 22;
@@ -2160,403 +2188,418 @@ var z2 = ut2(), ne = () => process.env.CI === "true", Be = (e) => e.isTTY === !0
2160
2188
  if (e === 8) return 28;
2161
2189
  if (e === 9) return 29;
2162
2190
  if (e === 0) return 0;
2163
- }, je = (e) => `${re}${Pe}${e}${Le}`, Ve = (e) => `${re}${Fe}${e}${fe}`, yt2 = (e) => e.map((i) => M2(i)), ye = (e, i, s) => {
2164
- let r = i[Symbol.iterator](), n = !1, o = !1, l = e.at(-1), u = l === void 0 ? 0 : M2(l), a = r.next(), h = r.next(), y2 = 0;
2165
- for (; !a.done; ) {
2166
- let E = a.value, f = M2(E);
2167
- u + f <= s ? e[e.length - 1] += E : (e.push(E), u = 0), (E === re || E === Ne) && (n = !0, o = i.startsWith(Fe, y2 + 1)), n ? o ? E === fe && (n = !1, o = !1) : E === Le && (n = !1) : (u += f, u === s && !h.done && (e.push(""), u = 0)), a = h, h = r.next(), y2 += E.length;
2168
- }
2169
- l = e.at(-1), !u && l !== void 0 && l.length > 0 && e.length > 1 && (e[e.length - 2] += e.pop());
2170
- }, Et2 = (e) => {
2171
- let i = e.split(" "), s = i.length;
2172
- for (; s > 0 && !(M2(i[s - 1]) > 0); ) s--;
2173
- return s === i.length ? e : i.slice(0, s).join(" ") + i.slice(s).join("");
2174
- }, vt2 = (e, i, s = {}) => {
2191
+ }, He = (e) => `${ae}${Ve}${e}${ke}`, Ue = (e) => `${ae}${Ie}${e}${Ce}`, Ct2 = (e) => e.map((r) => M2(r)), Se = (e, r, s) => {
2192
+ let i = r[Symbol.iterator](), n = !1, l = !1, u = e.at(-1), a = u === void 0 ? 0 : M2(u), o = i.next(), $ = i.next(), y2 = 0;
2193
+ for (; !o.done; ) {
2194
+ let E = o.value, p = M2(E);
2195
+ a + p <= s ? e[e.length - 1] += E : (e.push(E), a = 0), (E === ae || E === je) && (n = !0, l = r.startsWith(Ie, y2 + 1)), n ? l ? E === Ce && (n = !1, l = !1) : E === ke && (n = !1) : (a += p, a === s && !$.done && (e.push(""), a = 0)), o = $, $ = i.next(), y2 += E.length;
2196
+ }
2197
+ u = e.at(-1), !a && u !== void 0 && u.length > 0 && e.length > 1 && (e[e.length - 2] += e.pop());
2198
+ }, It2 = (e) => {
2199
+ let r = e.split(" "), s = r.length;
2200
+ for (; s > 0 && !(M2(r[s - 1]) > 0); ) s--;
2201
+ return s === r.length ? e : r.slice(0, s).join(" ") + r.slice(s).join("");
2202
+ }, St = (e, r, s = {}) => {
2175
2203
  if (s.trim !== !1 && e.trim() === "") return "";
2176
- let r = "", n, o, l = e.split(" "), u = yt2(l), a = [""];
2177
- for (let [c, m] of l.entries()) {
2178
- s.trim !== !1 && (a[a.length - 1] = (a.at(-1) ?? "").trimStart());
2179
- let $2 = M2(a.at(-1) ?? "");
2180
- if (c !== 0 && ($2 >= i && (s.wordWrap === !1 || s.trim === !1) && (a.push(""), $2 = 0), ($2 > 0 || s.trim === !1) && (a[a.length - 1] += " ", $2++)), s.hard && u[c] > i) {
2181
- let p = i - $2, g = 1 + Math.floor((u[c] - p - 1) / i);
2182
- Math.floor((u[c] - 1) / i) < g && a.push(""), ye(a, m, i);
2204
+ let i = "", n, l, u = e.split(" "), a = Ct2(u), o = [""];
2205
+ for (let [c, m] of u.entries()) {
2206
+ s.trim !== !1 && (o[o.length - 1] = (o.at(-1) ?? "").trimStart());
2207
+ let h = M2(o.at(-1) ?? "");
2208
+ if (c !== 0 && (h >= r && (s.wordWrap === !1 || s.trim === !1) && (o.push(""), h = 0), (h > 0 || s.trim === !1) && (o[o.length - 1] += " ", h++)), s.hard && a[c] > r) {
2209
+ let g = r - h, F = 1 + Math.floor((a[c] - g - 1) / r);
2210
+ Math.floor((a[c] - 1) / r) < F && o.push(""), Se(o, m, r);
2183
2211
  continue;
2184
2212
  }
2185
- if ($2 + u[c] > i && $2 > 0 && u[c] > 0) {
2186
- if (s.wordWrap === !1 && $2 < i) {
2187
- ye(a, m, i);
2213
+ if (h + a[c] > r && h > 0 && a[c] > 0) {
2214
+ if (s.wordWrap === !1 && h < r) {
2215
+ Se(o, m, r);
2188
2216
  continue;
2189
2217
  }
2190
- a.push("");
2218
+ o.push("");
2191
2219
  }
2192
- if ($2 + u[c] > i && s.wordWrap === !1) {
2193
- ye(a, m, i);
2220
+ if (h + a[c] > r && s.wordWrap === !1) {
2221
+ Se(o, m, r);
2194
2222
  continue;
2195
2223
  }
2196
- a[a.length - 1] += m;
2224
+ o[o.length - 1] += m;
2197
2225
  }
2198
- s.trim !== !1 && (a = a.map((c) => Et2(c)));
2199
- let h = a.join(`
2200
- `), y2 = h[Symbol.iterator](), E = y2.next(), f = y2.next(), F = 0;
2226
+ s.trim !== !1 && (o = o.map((c) => It2(c)));
2227
+ let $ = o.join(`
2228
+ `), y2 = $[Symbol.iterator](), E = y2.next(), p = y2.next(), f = 0;
2201
2229
  for (; !E.done; ) {
2202
- let c = E.value, m = f.value;
2203
- if (r += c, c === re || c === Ne) {
2204
- We.lastIndex = F + 1;
2205
- let g = We.exec(h)?.groups;
2206
- if (g?.code !== void 0) {
2207
- let v = Number.parseFloat(g.code);
2208
- n = v === gt2 ? void 0 : v;
2209
- } else g?.uri !== void 0 && (o = g.uri.length === 0 ? void 0 : g.uri);
2210
- }
2211
- let $2 = n ? Ft2(n) : void 0;
2230
+ let c = E.value, m = p.value;
2231
+ if (i += c, c === ae || c === je) {
2232
+ Ge.lastIndex = f + 1;
2233
+ let F = Ge.exec($)?.groups;
2234
+ if (F?.code !== void 0) {
2235
+ let v = Number.parseFloat(F.code);
2236
+ n = v === Et2 ? void 0 : v;
2237
+ } else F?.uri !== void 0 && (l = F.uri.length === 0 ? void 0 : F.uri);
2238
+ }
2239
+ let h = n ? At2(n) : void 0;
2212
2240
  m === `
2213
- ` ? (o && (r += Ve("")), n && $2 && (r += je($2))) : c === `
2214
- ` && (n && $2 && (r += je(n)), o && (r += Ve(o))), F += c.length, E = f, f = y2.next();
2241
+ ` ? (l && (i += Ue("")), n && h && (i += He(h))) : c === `
2242
+ ` && (n && h && (i += He(n)), l && (i += Ue(l))), f += c.length, E = p, p = y2.next();
2215
2243
  }
2216
- return r;
2244
+ return i;
2217
2245
  };
2218
- function U2(e, i, s) {
2246
+ function q2(e, r, s) {
2219
2247
  return String(e).normalize().replaceAll(`\r
2220
2248
  `, `
2221
2249
  `).split(`
2222
- `).map((r) => vt2(r, i, s)).join(`
2250
+ `).map((i) => St(i, r, s)).join(`
2223
2251
  `);
2224
2252
  }
2225
- var At2 = (e, i, s, r, n) => {
2226
- let o = i, l = 0;
2227
- for (let u = s; u < r; u++) {
2228
- let a = e[u];
2229
- if (o = o - a.length, l++, o <= n) break;
2230
- }
2231
- return { lineCount: o, removals: l };
2232
- }, K2 = (e) => {
2233
- let { cursor: i, options: s, style: r } = e, n = e.output ?? process.stdout, o = Ct(n), l = e.columnPadding ?? 0, u = e.rowPadding ?? 4, a = o - l, h = Bt(n), y2 = import_picocolors2.default.dim("..."), E = e.maxItems ?? Number.POSITIVE_INFINITY, f = Math.max(h - u, 0), F = Math.max(Math.min(E, f), 5), c = 0;
2234
- i >= F - 3 && (c = Math.max(Math.min(i - F + 3, s.length - F), 0));
2235
- let m = F < s.length && c > 0, $2 = F < s.length && c + F < s.length, p = Math.min(c + F, s.length), g = [], v = 0;
2236
- m && v++, $2 && v++;
2237
- let S2 = c + (m ? 1 : 0), w2 = p - ($2 ? 1 : 0);
2238
- for (let A = S2; A < w2; A++) {
2239
- let C = U2(r(s[A], A === i), a, { hard: !0, trim: !1 }).split(`
2253
+ var wt = (e, r, s, i, n) => {
2254
+ let l = r, u = 0;
2255
+ for (let a = s; a < i; a++) {
2256
+ let o = e[a];
2257
+ if (l = l - o.length, u++, l <= n) break;
2258
+ }
2259
+ return { lineCount: l, removals: u };
2260
+ }, J2 = (e) => {
2261
+ let { cursor: r, options: s, style: i } = e, n = e.output ?? process.stdout, l = rt(n), u = e.columnPadding ?? 0, a = e.rowPadding ?? 4, o = l - u, $ = nt(n), y2 = import_picocolors2.default.dim("..."), E = e.maxItems ?? Number.POSITIVE_INFINITY, p = Math.max($ - a, 0), f = Math.max(Math.min(E, p), 5), c = 0;
2262
+ r >= f - 3 && (c = Math.max(Math.min(r - f + 3, s.length - f), 0));
2263
+ let m = f < s.length && c > 0, h = f < s.length && c + f < s.length, g = Math.min(c + f, s.length), F = [], v = 0;
2264
+ m && v++, h && v++;
2265
+ let S2 = c + (m ? 1 : 0), B = g - (h ? 1 : 0);
2266
+ for (let A = S2; A < B; A++) {
2267
+ let C = q2(i(s[A], A === r), o, { hard: !0, trim: !1 }).split(`
2240
2268
  `);
2241
- g.push(C), v += C.length;
2269
+ F.push(C), v += C.length;
2242
2270
  }
2243
- if (v > f) {
2244
- let A = 0, C = 0, _ = v, D2 = i - S2, T2 = (k2, B2) => At2(g, _, k2, B2, f);
2245
- m ? ({ lineCount: _, removals: A } = T2(0, D2), _ > f && ({ lineCount: _, removals: C } = T2(D2 + 1, g.length))) : ({ lineCount: _, removals: C } = T2(D2 + 1, g.length), _ > f && ({ lineCount: _, removals: A } = T2(0, D2))), A > 0 && (m = !0, g.splice(0, A)), C > 0 && ($2 = !0, g.splice(g.length - C, C));
2271
+ if (v > p) {
2272
+ let A = 0, C = 0, _2 = v, D2 = r - S2, T2 = (L2, w2) => wt(F, _2, L2, w2, p);
2273
+ m ? ({ lineCount: _2, removals: A } = T2(0, D2), _2 > p && ({ lineCount: _2, removals: C } = T2(D2 + 1, F.length))) : ({ lineCount: _2, removals: C } = T2(D2 + 1, F.length), _2 > p && ({ lineCount: _2, removals: A } = T2(0, D2))), A > 0 && (m = !0, F.splice(0, A)), C > 0 && (h = !0, F.splice(F.length - C, C));
2246
2274
  }
2247
- let b2 = [];
2248
- m && b2.push(y2);
2249
- for (let A of g) for (let C of A) b2.push(C);
2250
- return $2 && b2.push(y2), b2;
2275
+ let b = [];
2276
+ m && b.push(y2);
2277
+ for (let A of F) for (let C of A) b.push(C);
2278
+ return h && b.push(y2), b;
2251
2279
  };
2252
- var St2 = [Re, ue, Me, ce], wt = [le, xe, x, _e];
2253
- function Ue(e, i, s, r) {
2254
- let n = s, o = s;
2255
- return r === "center" ? n = Math.floor((i - e) / 2) : r === "right" && (n = i - e - s), o = i - n - e, [n, o];
2280
+ var xt2 = [We, he, pe, me], _t2 = [$e, Re, x2, Oe];
2281
+ function Xe(e, r, s, i) {
2282
+ let n = s, l = s;
2283
+ return i === "center" ? n = Math.floor((r - e) / 2) : i === "right" && (n = r - e - s), l = r - n - e, [n, l];
2256
2284
  }
2257
- var Bt2 = (e) => e, bt2 = (e = "", i = "", s) => {
2258
- let r = s?.output ?? process.stdout, n = Ct(r), o = 2, l = s?.titlePadding ?? 1, u = s?.contentPadding ?? 2, a = s?.width === void 0 || s.width === "auto" ? 1 : Math.min(1, s.width), h = s?.includePrefix ? `${d} ` : "", y2 = s?.formatBorder ?? Bt2, E = (s?.rounded ? St2 : wt).map(y2), f = y2(Q2), F = y2(d), c = M2(h), m = M2(i), $2 = n - c, p = Math.floor(n * a) - c;
2285
+ var Dt = (e) => e, Tt2 = (e = "", r = "", s) => {
2286
+ let i = s?.output ?? process.stdout, n = rt(i), l = 2, u = s?.titlePadding ?? 1, a = s?.contentPadding ?? 2, o = s?.width === void 0 || s.width === "auto" ? 1 : Math.min(1, s.width), $ = (s?.withGuide ?? _.withGuide) !== !1 ? `${d} ` : "", y2 = s?.formatBorder ?? Dt, E = (s?.rounded ? xt2 : _t2).map(y2), p = y2(se), f = y2(d), c = M2($), m = M2(r), h = n - c, g = Math.floor(n * o) - c;
2259
2287
  if (s?.width === "auto") {
2260
- let _ = e.split(`
2261
- `), D2 = m + l * 2;
2262
- for (let k2 of _) {
2263
- let B2 = M2(k2) + u * 2;
2264
- B2 > D2 && (D2 = B2);
2265
- }
2266
- let T2 = D2 + o;
2267
- T2 < p && (p = T2);
2268
- }
2269
- p % 2 !== 0 && (p < $2 ? p++ : p--);
2270
- let g = p - o, v = g - l * 2, S2 = m > v ? `${i.slice(0, v - 3)}...` : i, [w2, b2] = Ue(M2(S2), g, l, s?.titleAlign), A = U2(e, g - u * 2, { hard: !0, trim: !1 });
2271
- r.write(`${h}${E[0]}${f.repeat(w2)}${S2}${f.repeat(b2)}${E[1]}
2288
+ let _2 = e.split(`
2289
+ `), D2 = m + u * 2;
2290
+ for (let L2 of _2) {
2291
+ let w2 = M2(L2) + a * 2;
2292
+ w2 > D2 && (D2 = w2);
2293
+ }
2294
+ let T2 = D2 + l;
2295
+ T2 < g && (g = T2);
2296
+ }
2297
+ g % 2 !== 0 && (g < h ? g++ : g--);
2298
+ let F = g - l, v = F - u * 2, S2 = m > v ? `${r.slice(0, v - 3)}...` : r, [B, b] = Xe(M2(S2), F, u, s?.titleAlign), A = q2(e, F - a * 2, { hard: !0, trim: !1 });
2299
+ i.write(`${$}${E[0]}${p.repeat(B)}${S2}${p.repeat(b)}${E[1]}
2272
2300
  `);
2273
2301
  let C = A.split(`
2274
2302
  `);
2275
- for (let _ of C) {
2276
- let [D2, T2] = Ue(M2(_), g, u, s?.contentAlign);
2277
- r.write(`${h}${F}${" ".repeat(D2)}${_}${" ".repeat(T2)}${F}
2303
+ for (let _2 of C) {
2304
+ let [D2, T2] = Xe(M2(_2), F, a, s?.contentAlign);
2305
+ i.write(`${$}${f}${" ".repeat(D2)}${_2}${" ".repeat(T2)}${f}
2278
2306
  `);
2279
2307
  }
2280
- r.write(`${h}${E[2]}${f.repeat(g)}${E[3]}
2308
+ i.write(`${$}${E[2]}${p.repeat(F)}${E[3]}
2281
2309
  `);
2282
- }, xt = (e) => {
2283
- let i = e.active ?? "Yes", s = e.inactive ?? "No";
2284
- return new Vt({ active: i, inactive: s, signal: e.signal, input: e.input, output: e.output, initialValue: e.initialValue ?? !0, render() {
2285
- let r = `${import_picocolors2.default.gray(d)}
2286
- ${L2(this.state)} ${e.message}
2287
- `, n = this.value ? i : s;
2310
+ }, Mt2 = (e) => {
2311
+ let r = e.active ?? "Yes", s = e.inactive ?? "No";
2312
+ return new kt({ active: r, inactive: s, signal: e.signal, input: e.input, output: e.output, initialValue: e.initialValue ?? !0, render() {
2313
+ let i = `${import_picocolors2.default.gray(d)}
2314
+ ${W2(this.state)} ${e.message}
2315
+ `, n = this.value ? r : s;
2288
2316
  switch (this.state) {
2289
2317
  case "submit":
2290
- return `${r}${import_picocolors2.default.gray(d)} ${import_picocolors2.default.dim(n)}`;
2318
+ return `${i}${import_picocolors2.default.gray(d)} ${import_picocolors2.default.dim(n)}`;
2291
2319
  case "cancel":
2292
- return `${r}${import_picocolors2.default.gray(d)} ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(n))}
2320
+ return `${i}${import_picocolors2.default.gray(d)} ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(n))}
2293
2321
  ${import_picocolors2.default.gray(d)}`;
2294
2322
  default:
2295
- return `${r}${import_picocolors2.default.cyan(d)} ${this.value ? `${import_picocolors2.default.green(J2)} ${i}` : `${import_picocolors2.default.dim(H)} ${import_picocolors2.default.dim(i)}`} ${import_picocolors2.default.dim("/")} ${this.value ? `${import_picocolors2.default.dim(H)} ${import_picocolors2.default.dim(s)}` : `${import_picocolors2.default.green(J2)} ${s}`}
2296
- ${import_picocolors2.default.cyan(x)}
2323
+ return `${i}${import_picocolors2.default.cyan(d)} ${this.value ? `${import_picocolors2.default.green(Y)} ${r}` : `${import_picocolors2.default.dim(K2)} ${import_picocolors2.default.dim(r)}`} ${import_picocolors2.default.dim("/")} ${this.value ? `${import_picocolors2.default.dim(K2)} ${import_picocolors2.default.dim(s)}` : `${import_picocolors2.default.green(Y)} ${s}`}
2324
+ ${import_picocolors2.default.cyan(x2)}
2297
2325
  `;
2298
2326
  }
2299
2327
  } }).prompt();
2300
2328
  };
2301
- var R = { message: (e = [], { symbol: i = import_picocolors2.default.gray(d), secondarySymbol: s = import_picocolors2.default.gray(d), output: r = process.stdout, spacing: n = 1 } = {}) => {
2302
- let o = [];
2303
- for (let u = 0; u < n; u++) o.push(`${s}`);
2304
- let l = Array.isArray(e) ? e : e.split(`
2329
+ var R2 = { message: (e = [], { symbol: r = import_picocolors2.default.gray(d), secondarySymbol: s = import_picocolors2.default.gray(d), output: i = process.stdout, spacing: n = 1, withGuide: l } = {}) => {
2330
+ let u = [], a = (l ?? _.withGuide) !== !1, o = a ? s : "", $ = a ? `${r} ` : "", y2 = a ? `${s} ` : "";
2331
+ for (let p = 0; p < n; p++) u.push(o);
2332
+ let E = Array.isArray(e) ? e : e.split(`
2305
2333
  `);
2306
- if (l.length > 0) {
2307
- let [u, ...a] = l;
2308
- u.length > 0 ? o.push(`${i} ${u}`) : o.push(i);
2309
- for (let h of a) h.length > 0 ? o.push(`${s} ${h}`) : o.push(s);
2334
+ if (E.length > 0) {
2335
+ let [p, ...f] = E;
2336
+ p.length > 0 ? u.push(`${$}${p}`) : u.push(a ? "" : r);
2337
+ for (let c of f) c.length > 0 ? u.push(`${y2}${c}`) : u.push(a ? "" : s);
2310
2338
  }
2311
- r.write(`${o.join(`
2339
+ i.write(`${u.join(`
2312
2340
  `)}
2313
2341
  `);
2314
- }, info: (e, i) => {
2315
- R.message(e, { ...i, symbol: import_picocolors2.default.blue(de) });
2316
- }, success: (e, i) => {
2317
- R.message(e, { ...i, symbol: import_picocolors2.default.green($e) });
2318
- }, step: (e, i) => {
2319
- R.message(e, { ...i, symbol: import_picocolors2.default.green(W2) });
2320
- }, warn: (e, i) => {
2321
- R.message(e, { ...i, symbol: import_picocolors2.default.yellow(he) });
2322
- }, warning: (e, i) => {
2323
- R.warn(e, i);
2324
- }, error: (e, i) => {
2325
- R.message(e, { ...i, symbol: import_picocolors2.default.red(me) });
2326
- } }, Tt2 = (e = "", i) => {
2327
- (i?.output ?? process.stdout).write(`${import_picocolors2.default.gray(x)} ${import_picocolors2.default.red(e)}
2342
+ }, info: (e, r) => {
2343
+ R2.message(e, { ...r, symbol: import_picocolors2.default.blue(ge) });
2344
+ }, success: (e, r) => {
2345
+ R2.message(e, { ...r, symbol: import_picocolors2.default.green(fe) });
2346
+ }, step: (e, r) => {
2347
+ R2.message(e, { ...r, symbol: import_picocolors2.default.green(j2) });
2348
+ }, warn: (e, r) => {
2349
+ R2.message(e, { ...r, symbol: import_picocolors2.default.yellow(Fe) });
2350
+ }, warning: (e, r) => {
2351
+ R2.warn(e, r);
2352
+ }, error: (e, r) => {
2353
+ R2.message(e, { ...r, symbol: import_picocolors2.default.red(ye) });
2354
+ } }, Nt = (e = "", r) => {
2355
+ (r?.output ?? process.stdout).write(`${import_picocolors2.default.gray(x2)} ${import_picocolors2.default.red(e)}
2328
2356
 
2329
2357
  `);
2330
- }, Mt2 = (e = "", i) => {
2331
- (i?.output ?? process.stdout).write(`${import_picocolors2.default.gray(le)} ${e}
2358
+ }, Pt = (e = "", r) => {
2359
+ (r?.output ?? process.stdout).write(`${import_picocolors2.default.gray($e)} ${e}
2332
2360
  `);
2333
- }, Rt = (e = "", i) => {
2334
- (i?.output ?? process.stdout).write(`${import_picocolors2.default.gray(d)}
2335
- ${import_picocolors2.default.gray(x)} ${e}
2361
+ }, Wt2 = (e = "", r) => {
2362
+ (r?.output ?? process.stdout).write(`${import_picocolors2.default.gray(d)}
2363
+ ${import_picocolors2.default.gray(x2)} ${e}
2336
2364
 
2337
2365
  `);
2338
- }, Ot = (e) => {
2339
- let i = (r, n) => {
2340
- let o = r.label ?? String(r.value);
2341
- return n === "disabled" ? `${import_picocolors2.default.gray(X2)} ${import_picocolors2.default.gray(o)}${r.hint ? ` ${import_picocolors2.default.dim(`(${r.hint ?? "disabled"})`)}` : ""}` : n === "active" ? `${import_picocolors2.default.cyan(Z2)} ${o}${r.hint ? ` ${import_picocolors2.default.dim(`(${r.hint})`)}` : ""}` : n === "selected" ? `${import_picocolors2.default.green(j2)} ${import_picocolors2.default.dim(o)}${r.hint ? ` ${import_picocolors2.default.dim(`(${r.hint})`)}` : ""}` : n === "cancelled" ? `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(o))}` : n === "active-selected" ? `${import_picocolors2.default.green(j2)} ${o}${r.hint ? ` ${import_picocolors2.default.dim(`(${r.hint})`)}` : ""}` : n === "submitted" ? `${import_picocolors2.default.dim(o)}` : `${import_picocolors2.default.dim(X2)} ${import_picocolors2.default.dim(o)}`;
2366
+ }, Q2 = (e, r) => e.split(`
2367
+ `).map((s) => r(s)).join(`
2368
+ `), Lt2 = (e) => {
2369
+ let r = (i, n) => {
2370
+ let l = i.label ?? String(i.value);
2371
+ return n === "disabled" ? `${import_picocolors2.default.gray(z2)} ${Q2(l, import_picocolors2.default.gray)}${i.hint ? ` ${import_picocolors2.default.dim(`(${i.hint ?? "disabled"})`)}` : ""}` : n === "active" ? `${import_picocolors2.default.cyan(te)} ${l}${i.hint ? ` ${import_picocolors2.default.dim(`(${i.hint})`)}` : ""}` : n === "selected" ? `${import_picocolors2.default.green(V)} ${Q2(l, import_picocolors2.default.dim)}${i.hint ? ` ${import_picocolors2.default.dim(`(${i.hint})`)}` : ""}` : n === "cancelled" ? `${Q2(l, (u) => import_picocolors2.default.strikethrough(import_picocolors2.default.dim(u)))}` : n === "active-selected" ? `${import_picocolors2.default.green(V)} ${l}${i.hint ? ` ${import_picocolors2.default.dim(`(${i.hint})`)}` : ""}` : n === "submitted" ? `${Q2(l, import_picocolors2.default.dim)}` : `${import_picocolors2.default.dim(z2)} ${Q2(l, import_picocolors2.default.dim)}`;
2342
2372
  }, s = e.required ?? !0;
2343
- return new yt({ options: e.options, signal: e.signal, input: e.input, output: e.output, initialValues: e.initialValues, required: s, cursorAt: e.cursorAt, validate(r) {
2344
- if (s && (r === void 0 || r.length === 0)) return `Please select at least one option.
2373
+ return new Mt({ options: e.options, signal: e.signal, input: e.input, output: e.output, initialValues: e.initialValues, required: s, cursorAt: e.cursorAt, validate(i) {
2374
+ if (s && (i === void 0 || i.length === 0)) return `Please select at least one option.
2345
2375
  ${import_picocolors2.default.reset(import_picocolors2.default.dim(`Press ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" space ")))} to select, ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" enter ")))} to submit`))}`;
2346
2376
  }, render() {
2347
- let r = `${import_picocolors2.default.gray(d)}
2348
- ${L2(this.state)} ${e.message}
2349
- `, n = this.value ?? [], o = (l, u) => {
2350
- if (l.disabled) return i(l, "disabled");
2351
- let a = n.includes(l.value);
2352
- return u && a ? i(l, "active-selected") : a ? i(l, "selected") : i(l, u ? "active" : "inactive");
2377
+ let i = Bt(e.output, e.message, `${Ee(this.state)} `, `${W2(this.state)} `), n = `${import_picocolors2.default.gray(d)}
2378
+ ${i}
2379
+ `, l = this.value ?? [], u = (a, o) => {
2380
+ if (a.disabled) return r(a, "disabled");
2381
+ let $ = l.includes(a.value);
2382
+ return o && $ ? r(a, "active-selected") : $ ? r(a, "selected") : r(a, o ? "active" : "inactive");
2353
2383
  };
2354
2384
  switch (this.state) {
2355
- case "submit":
2356
- return `${r}${import_picocolors2.default.gray(d)} ${this.options.filter(({ value: l }) => n.includes(l)).map((l) => i(l, "submitted")).join(import_picocolors2.default.dim(", ")) || import_picocolors2.default.dim("none")}`;
2385
+ case "submit": {
2386
+ let a = this.options.filter(({ value: $ }) => l.includes($)).map(($) => r($, "submitted")).join(import_picocolors2.default.dim(", ")) || import_picocolors2.default.dim("none"), o = Bt(e.output, a, `${import_picocolors2.default.gray(d)} `);
2387
+ return `${n}${o}`;
2388
+ }
2357
2389
  case "cancel": {
2358
- let l = this.options.filter(({ value: u }) => n.includes(u)).map((u) => i(u, "cancelled")).join(import_picocolors2.default.dim(", "));
2359
- return `${r}${import_picocolors2.default.gray(d)}${l.trim() ? ` ${l}
2360
- ${import_picocolors2.default.gray(d)}` : ""}`;
2390
+ let a = this.options.filter(({ value: $ }) => l.includes($)).map(($) => r($, "cancelled")).join(import_picocolors2.default.dim(", "));
2391
+ if (a.trim() === "") return `${n}${import_picocolors2.default.gray(d)}`;
2392
+ let o = Bt(e.output, a, `${import_picocolors2.default.gray(d)} `);
2393
+ return `${n}${o}
2394
+ ${import_picocolors2.default.gray(d)}`;
2361
2395
  }
2362
2396
  case "error": {
2363
- let l = `${import_picocolors2.default.yellow(d)} `, u = this.error.split(`
2364
- `).map((a, h) => h === 0 ? `${import_picocolors2.default.yellow(x)} ${import_picocolors2.default.yellow(a)}` : ` ${a}`).join(`
2397
+ let a = `${import_picocolors2.default.yellow(d)} `, o = this.error.split(`
2398
+ `).map(($, y2) => y2 === 0 ? `${import_picocolors2.default.yellow(x2)} ${import_picocolors2.default.yellow($)}` : ` ${$}`).join(`
2365
2399
  `);
2366
- return `${r}${l}${K2({ output: e.output, options: this.options, cursor: this.cursor, maxItems: e.maxItems, columnPadding: l.length, style: o }).join(`
2367
- ${l}`)}
2368
- ${u}
2400
+ return `${n}${a}${J2({ output: e.output, options: this.options, cursor: this.cursor, maxItems: e.maxItems, columnPadding: a.length, style: u }).join(`
2401
+ ${a}`)}
2402
+ ${o}
2369
2403
  `;
2370
2404
  }
2371
2405
  default: {
2372
- let l = `${import_picocolors2.default.cyan(d)} `;
2373
- return `${r}${l}${K2({ output: e.output, options: this.options, cursor: this.cursor, maxItems: e.maxItems, columnPadding: l.length, style: o }).join(`
2374
- ${l}`)}
2375
- ${import_picocolors2.default.cyan(x)}
2406
+ let a = `${import_picocolors2.default.cyan(d)} `;
2407
+ return `${n}${a}${J2({ output: e.output, options: this.options, cursor: this.cursor, maxItems: e.maxItems, columnPadding: a.length, style: u }).join(`
2408
+ ${a}`)}
2409
+ ${import_picocolors2.default.cyan(x2)}
2376
2410
  `;
2377
2411
  }
2378
2412
  }
2379
2413
  } }).prompt();
2380
2414
  };
2381
- var Vt2 = import_picocolors2.default.magenta, Ee = ({ indicator: e = "dots", onCancel: i, output: s = process.stdout, cancelMessage: r, errorMessage: n, frames: o = z2 ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"], delay: l = z2 ? 80 : 120, signal: u, ...a } = {}) => {
2382
- let h = ne(), y2, E, f = !1, F = !1, c = "", m, $2 = performance.now(), p = Ct(s), g = a?.styleFrame ?? Vt2, v = (B2) => {
2383
- let O2 = B2 > 1 ? n ?? b.messages.error : r ?? b.messages.cancel;
2384
- F = B2 === 1, f && (k2(O2, B2), F && typeof i == "function" && i());
2385
- }, S2 = () => v(2), w2 = () => v(1), b2 = () => {
2386
- process.on("uncaughtExceptionMonitor", S2), process.on("unhandledRejection", S2), process.on("SIGINT", w2), process.on("SIGTERM", w2), process.on("exit", v), u && u.addEventListener("abort", w2);
2415
+ var Ut = import_picocolors2.default.magenta, we = ({ indicator: e = "dots", onCancel: r, output: s = process.stdout, cancelMessage: i, errorMessage: n, frames: l = ee ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"], delay: u = ee ? 80 : 120, signal: a, ...o } = {}) => {
2416
+ let $ = ue(), y2, E, p = !1, f = !1, c = "", m, h = performance.now(), g = rt(s), F = o?.styleFrame ?? Ut, v = (w2) => {
2417
+ let O2 = w2 > 1 ? n ?? _.messages.error : i ?? _.messages.cancel;
2418
+ f = w2 === 1, p && (L2(O2, w2), f && typeof r == "function" && r());
2419
+ }, S2 = () => v(2), B = () => v(1), b = () => {
2420
+ process.on("uncaughtExceptionMonitor", S2), process.on("unhandledRejection", S2), process.on("SIGINT", B), process.on("SIGTERM", B), process.on("exit", v), a && a.addEventListener("abort", B);
2387
2421
  }, A = () => {
2388
- process.removeListener("uncaughtExceptionMonitor", S2), process.removeListener("unhandledRejection", S2), process.removeListener("SIGINT", w2), process.removeListener("SIGTERM", w2), process.removeListener("exit", v), u && u.removeEventListener("abort", w2);
2422
+ process.removeListener("uncaughtExceptionMonitor", S2), process.removeListener("unhandledRejection", S2), process.removeListener("SIGINT", B), process.removeListener("SIGTERM", B), process.removeListener("exit", v), a && a.removeEventListener("abort", B);
2389
2423
  }, C = () => {
2390
2424
  if (m === void 0) return;
2391
- h && s.write(`
2425
+ $ && s.write(`
2392
2426
  `);
2393
- let B2 = U2(m, p, { hard: !0, trim: !1 }).split(`
2427
+ let w2 = q2(m, g, { hard: !0, trim: !1 }).split(`
2394
2428
  `);
2395
- B2.length > 1 && s.write(import_sisteransi2.cursor.up(B2.length - 1)), s.write(import_sisteransi2.cursor.to(0)), s.write(import_sisteransi2.erase.down());
2396
- }, _ = (B2) => B2.replace(/\.+$/, ""), D2 = (B2) => {
2397
- let O2 = (performance.now() - B2) / 1e3, P2 = Math.floor(O2 / 60), G2 = Math.floor(O2 % 60);
2429
+ w2.length > 1 && s.write(import_sisteransi2.cursor.up(w2.length - 1)), s.write(import_sisteransi2.cursor.to(0)), s.write(import_sisteransi2.erase.down());
2430
+ }, _2 = (w2) => w2.replace(/\.+$/, ""), D2 = (w2) => {
2431
+ let O2 = (performance.now() - w2) / 1e3, P2 = Math.floor(O2 / 60), G2 = Math.floor(O2 % 60);
2398
2432
  return P2 > 0 ? `[${P2}m ${G2}s]` : `[${G2}s]`;
2399
- }, T2 = (B2 = "") => {
2400
- f = !0, y2 = bt({ output: s }), c = _(B2), $2 = performance.now(), s.write(`${import_picocolors2.default.gray(d)}
2433
+ }, T2 = (w2 = "") => {
2434
+ p = !0, y2 = xt({ output: s }), c = _2(w2), h = performance.now(), s.write(`${import_picocolors2.default.gray(d)}
2401
2435
  `);
2402
2436
  let O2 = 0, P2 = 0;
2403
- b2(), E = setInterval(() => {
2404
- if (h && c === m) return;
2437
+ b(), E = setInterval(() => {
2438
+ if ($ && c === m) return;
2405
2439
  C(), m = c;
2406
- let G2 = g(o[O2]), Y2;
2407
- if (h) Y2 = `${G2} ${c}...`;
2408
- else if (e === "timer") Y2 = `${G2} ${c} ${D2($2)}`;
2440
+ let G2 = F(l[O2]), Z2;
2441
+ if ($) Z2 = `${G2} ${c}...`;
2442
+ else if (e === "timer") Z2 = `${G2} ${c} ${D2(h)}`;
2409
2443
  else {
2410
- let Xe = ".".repeat(Math.floor(P2)).slice(0, 3);
2411
- Y2 = `${G2} ${c}${Xe}`;
2412
- }
2413
- let Je = U2(Y2, p, { hard: !0, trim: !1 });
2414
- s.write(Je), O2 = O2 + 1 < o.length ? O2 + 1 : 0, P2 = P2 < 4 ? P2 + 0.125 : 0;
2415
- }, l);
2416
- }, k2 = (B2 = "", O2 = 0) => {
2417
- if (!f) return;
2418
- f = !1, clearInterval(E), C();
2419
- let P2 = O2 === 0 ? import_picocolors2.default.green(W2) : O2 === 1 ? import_picocolors2.default.red(ae) : import_picocolors2.default.red(oe);
2420
- c = B2 ?? c, e === "timer" ? s.write(`${P2} ${c} ${D2($2)}
2444
+ let Ze = ".".repeat(Math.floor(P2)).slice(0, 3);
2445
+ Z2 = `${G2} ${c}${Ze}`;
2446
+ }
2447
+ let Qe = q2(Z2, g, { hard: !0, trim: !1 });
2448
+ s.write(Qe), O2 = O2 + 1 < l.length ? O2 + 1 : 0, P2 = P2 < 4 ? P2 + 0.125 : 0;
2449
+ }, u);
2450
+ }, L2 = (w2 = "", O2 = 0) => {
2451
+ if (!p) return;
2452
+ p = !1, clearInterval(E), C();
2453
+ let P2 = O2 === 0 ? import_picocolors2.default.green(j2) : O2 === 1 ? import_picocolors2.default.red(ce) : import_picocolors2.default.red(de);
2454
+ c = w2 ?? c, e === "timer" ? s.write(`${P2} ${c} ${D2(h)}
2421
2455
  `) : s.write(`${P2} ${c}
2422
2456
  `), A(), y2();
2423
2457
  };
2424
- return { start: T2, stop: k2, message: (B2 = "") => {
2425
- c = _(B2 ?? c);
2426
- }, get isCancelled() {
2427
- return F;
2458
+ return { start: T2, stop: (w2 = "") => L2(w2, 0), message: (w2 = "") => {
2459
+ c = _2(w2 ?? c);
2460
+ }, cancel: (w2 = "") => L2(w2, 1), error: (w2 = "") => L2(w2, 2), get isCancelled() {
2461
+ return f;
2428
2462
  } };
2429
- }, Ke = { light: I2("\u2500", "-"), heavy: I2("\u2501", "="), block: I2("\u2588", "#") };
2430
- var Gt = (e) => {
2431
- let i = (s, r) => {
2463
+ }, Ye = { light: I2("\u2500", "-"), heavy: I2("\u2501", "="), block: I2("\u2588", "#") };
2464
+ var oe = (e, r) => e.includes(`
2465
+ `) ? e.split(`
2466
+ `).map((s) => r(s)).join(`
2467
+ `) : r(e), qt = (e) => {
2468
+ let r = (s, i) => {
2432
2469
  let n = s.label ?? String(s.value);
2433
- switch (r) {
2470
+ switch (i) {
2434
2471
  case "disabled":
2435
- return `${import_picocolors2.default.gray(H)} ${import_picocolors2.default.gray(n)}${s.hint ? ` ${import_picocolors2.default.dim(`(${s.hint ?? "disabled"})`)}` : ""}`;
2472
+ return `${import_picocolors2.default.gray(K2)} ${oe(n, import_picocolors2.default.gray)}${s.hint ? ` ${import_picocolors2.default.dim(`(${s.hint ?? "disabled"})`)}` : ""}`;
2436
2473
  case "selected":
2437
- return `${import_picocolors2.default.dim(n)}`;
2474
+ return `${oe(n, import_picocolors2.default.dim)}`;
2438
2475
  case "active":
2439
- return `${import_picocolors2.default.green(J2)} ${n}${s.hint ? ` ${import_picocolors2.default.dim(`(${s.hint})`)}` : ""}`;
2476
+ return `${import_picocolors2.default.green(Y)} ${n}${s.hint ? ` ${import_picocolors2.default.dim(`(${s.hint})`)}` : ""}`;
2440
2477
  case "cancelled":
2441
- return `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(n))}`;
2478
+ return `${oe(n, (l) => import_picocolors2.default.strikethrough(import_picocolors2.default.dim(l)))}`;
2442
2479
  default:
2443
- return `${import_picocolors2.default.dim(H)} ${import_picocolors2.default.dim(n)}`;
2480
+ return `${import_picocolors2.default.dim(K2)} ${oe(n, import_picocolors2.default.dim)}`;
2444
2481
  }
2445
2482
  };
2446
- return new Lt({ options: e.options, signal: e.signal, input: e.input, output: e.output, initialValue: e.initialValue, render() {
2447
- let s = `${import_picocolors2.default.gray(d)}
2448
- ${L2(this.state)} ${e.message}
2483
+ return new Wt({ options: e.options, signal: e.signal, input: e.input, output: e.output, initialValue: e.initialValue, render() {
2484
+ let s = `${W2(this.state)} `, i = `${Ee(this.state)} `, n = Bt(e.output, e.message, i, s), l = `${import_picocolors2.default.gray(d)}
2485
+ ${n}
2449
2486
  `;
2450
2487
  switch (this.state) {
2451
- case "submit":
2452
- return `${s}${import_picocolors2.default.gray(d)} ${i(this.options[this.cursor], "selected")}`;
2453
- case "cancel":
2454
- return `${s}${import_picocolors2.default.gray(d)} ${i(this.options[this.cursor], "cancelled")}
2488
+ case "submit": {
2489
+ let u = `${import_picocolors2.default.gray(d)} `, a = Bt(e.output, r(this.options[this.cursor], "selected"), u);
2490
+ return `${l}${a}`;
2491
+ }
2492
+ case "cancel": {
2493
+ let u = `${import_picocolors2.default.gray(d)} `, a = Bt(e.output, r(this.options[this.cursor], "cancelled"), u);
2494
+ return `${l}${a}
2455
2495
  ${import_picocolors2.default.gray(d)}`;
2496
+ }
2456
2497
  default: {
2457
- let r = `${import_picocolors2.default.cyan(d)} `;
2458
- return `${s}${r}${K2({ output: e.output, cursor: this.cursor, options: this.options, maxItems: e.maxItems, columnPadding: r.length, style: (n, o) => i(n, n.disabled ? "disabled" : o ? "active" : "inactive") }).join(`
2459
- ${r}`)}
2460
- ${import_picocolors2.default.cyan(x)}
2498
+ let u = `${import_picocolors2.default.cyan(d)} `;
2499
+ return `${l}${u}${J2({ output: e.output, cursor: this.cursor, options: this.options, maxItems: e.maxItems, columnPadding: u.length, style: (a, o) => r(a, a.disabled ? "disabled" : o ? "active" : "inactive") }).join(`
2500
+ ${u}`)}
2501
+ ${import_picocolors2.default.cyan(x2)}
2461
2502
  `;
2462
2503
  }
2463
2504
  }
2464
2505
  } }).prompt();
2465
2506
  };
2466
- var qe = `${import_picocolors2.default.gray(d)} `;
2467
- var Kt = (e) => {
2468
- let i = e.output ?? process.stdout, s = Ct(i), r = import_picocolors2.default.gray(d), n = e.spacing ?? 1, o = 3, l = e.retainLog === !0, u = !ne() && Be(i);
2469
- i.write(`${r}
2470
- `), i.write(`${import_picocolors2.default.green(W2)} ${e.title}
2507
+ var ze = `${import_picocolors2.default.gray(d)} `;
2508
+ var Yt = (e) => e.replace(/\x1b\[(?:\d+;)*\d*[ABCDEFGHfJKSTsu]|\x1b\[(s|u)/g, ""), zt = (e) => {
2509
+ let r = e.output ?? process.stdout, s = rt(r), i = import_picocolors2.default.gray(d), n = e.spacing ?? 1, l = 3, u = e.retainLog === !0, a = !ue() && Te(r);
2510
+ r.write(`${i}
2511
+ `), r.write(`${import_picocolors2.default.green(j2)} ${e.title}
2471
2512
  `);
2472
- for (let $2 = 0; $2 < n; $2++) i.write(`${r}
2513
+ for (let h = 0; h < n; h++) r.write(`${i}
2473
2514
  `);
2474
- let a = [{ value: "", full: "" }], h = !1, y2 = ($2) => {
2475
- if (a.length === 0) return;
2476
- let p = 0;
2477
- $2 && (p += n + 2);
2478
- for (let g of a) {
2479
- let { value: v, result: S2 } = g, w2 = S2?.message ?? v;
2480
- if (w2.length === 0) continue;
2481
- S2 === void 0 && g.header !== void 0 && g.header !== "" && (w2 += `
2482
- ${g.header}`);
2483
- let b2 = w2.split(`
2484
- `).reduce((A, C) => C === "" ? A + 1 : A + Math.ceil((C.length + o) / s), 0);
2485
- p += b2;
2486
- }
2487
- p > 0 && (p += 1, i.write(import_sisteransi2.erase.lines(p)));
2488
- }, E = ($2, p, g) => {
2489
- let v = g ? `${$2.full}
2490
- ${$2.value}` : $2.value;
2491
- $2.header !== void 0 && $2.header !== "" && R.message($2.header.split(`
2492
- `).map(import_picocolors2.default.bold), { output: i, secondarySymbol: r, symbol: r, spacing: 0 }), R.message(v.split(`
2493
- `).map(import_picocolors2.default.dim), { output: i, secondarySymbol: r, symbol: r, spacing: p ?? n });
2494
- }, f = () => {
2495
- for (let $2 of a) {
2496
- let { header: p, value: g, full: v } = $2;
2497
- (p === void 0 || p.length === 0) && g.length === 0 || E($2, void 0, l === !0 && v.length > 0);
2498
- }
2499
- }, F = ($2, p, g) => {
2500
- if (y2(!1), (g?.raw !== !0 || !h) && $2.value !== "" && ($2.value += `
2501
- `), $2.value += p, h = g?.raw === !0, e.limit !== void 0) {
2502
- let v = $2.value.split(`
2515
+ let o = [{ value: "", full: "" }], $ = !1, y2 = (h) => {
2516
+ if (o.length === 0) return;
2517
+ let g = 0;
2518
+ h && (g += n + 2);
2519
+ for (let F of o) {
2520
+ let { value: v, result: S2 } = F, B = S2?.message ?? v;
2521
+ if (B.length === 0) continue;
2522
+ S2 === void 0 && F.header !== void 0 && F.header !== "" && (B += `
2523
+ ${F.header}`);
2524
+ let b = B.split(`
2525
+ `).reduce((A, C) => C === "" ? A + 1 : A + Math.ceil((C.length + l) / s), 0);
2526
+ g += b;
2527
+ }
2528
+ g > 0 && (g += 1, r.write(import_sisteransi2.erase.lines(g)));
2529
+ }, E = (h, g, F) => {
2530
+ let v = F ? `${h.full}
2531
+ ${h.value}` : h.value;
2532
+ h.header !== void 0 && h.header !== "" && R2.message(h.header.split(`
2533
+ `).map(import_picocolors2.default.bold), { output: r, secondarySymbol: i, symbol: i, spacing: 0 }), R2.message(v.split(`
2534
+ `).map(import_picocolors2.default.dim), { output: r, secondarySymbol: i, symbol: i, spacing: g ?? n });
2535
+ }, p = () => {
2536
+ for (let h of o) {
2537
+ let { header: g, value: F, full: v } = h;
2538
+ (g === void 0 || g.length === 0) && F.length === 0 || E(h, void 0, u === !0 && v.length > 0);
2539
+ }
2540
+ }, f = (h, g, F) => {
2541
+ if (y2(!1), (F?.raw !== !0 || !$) && h.value !== "" && (h.value += `
2542
+ `), h.value += Yt(g), $ = F?.raw === !0, e.limit !== void 0) {
2543
+ let v = h.value.split(`
2503
2544
  `), S2 = v.length - e.limit;
2504
2545
  if (S2 > 0) {
2505
- let w2 = v.splice(0, S2);
2506
- l && ($2.full += ($2.full === "" ? "" : `
2507
- `) + w2.join(`
2546
+ let B = v.splice(0, S2);
2547
+ u && (h.full += (h.full === "" ? "" : `
2548
+ `) + B.join(`
2508
2549
  `));
2509
2550
  }
2510
- $2.value = v.join(`
2551
+ h.value = v.join(`
2511
2552
  `);
2512
2553
  }
2513
- u && c();
2554
+ a && c();
2514
2555
  }, c = () => {
2515
- for (let $2 of a) $2.result ? $2.result.status === "error" ? R.error($2.result.message, { output: i, secondarySymbol: r, spacing: 0 }) : R.success($2.result.message, { output: i, secondarySymbol: r, spacing: 0 }) : $2.value !== "" && E($2, 0);
2516
- }, m = ($2, p) => {
2517
- y2(!1), $2.result = p, u && c();
2556
+ for (let h of o) h.result ? h.result.status === "error" ? R2.error(h.result.message, { output: r, secondarySymbol: i, spacing: 0 }) : R2.success(h.result.message, { output: r, secondarySymbol: i, spacing: 0 }) : h.value !== "" && E(h, 0);
2557
+ }, m = (h, g) => {
2558
+ y2(!1), h.result = g, a && c();
2518
2559
  };
2519
- return { message($2, p) {
2520
- F(a[0], $2, p);
2521
- }, group($2) {
2522
- let p = { header: $2, value: "", full: "" };
2523
- return a.push(p), { message(g, v) {
2524
- F(p, g, v);
2525
- }, error(g) {
2526
- m(p, { status: "error", message: g });
2527
- }, success(g) {
2528
- m(p, { status: "success", message: g });
2560
+ return { message(h, g) {
2561
+ f(o[0], h, g);
2562
+ }, group(h) {
2563
+ let g = { header: h, value: "", full: "" };
2564
+ return o.push(g), { message(F, v) {
2565
+ f(g, F, v);
2566
+ }, error(F) {
2567
+ m(g, { status: "error", message: F });
2568
+ }, success(F) {
2569
+ m(g, { status: "success", message: F });
2529
2570
  } };
2530
- }, error($2, p) {
2531
- y2(!0), R.error($2, { output: i, secondarySymbol: r, spacing: 1 }), p?.showLog !== !1 && f(), a.splice(1, a.length - 1), a[0].value = "", a[0].full = "";
2532
- }, success($2, p) {
2533
- y2(!0), R.success($2, { output: i, secondarySymbol: r, spacing: 1 }), p?.showLog === !0 && f(), a.splice(1, a.length - 1), a[0].value = "", a[0].full = "";
2571
+ }, error(h, g) {
2572
+ y2(!0), R2.error(h, { output: r, secondarySymbol: i, spacing: 1 }), g?.showLog !== !1 && p(), o.splice(1, o.length - 1), o[0].value = "", o[0].full = "";
2573
+ }, success(h, g) {
2574
+ y2(!0), R2.success(h, { output: r, secondarySymbol: i, spacing: 1 }), g?.showLog === !0 && p(), o.splice(1, o.length - 1), o[0].value = "", o[0].full = "";
2534
2575
  } };
2535
- }, qt = (e) => new Tt({ validate: e.validate, placeholder: e.placeholder, defaultValue: e.defaultValue, initialValue: e.initialValue, output: e.output, signal: e.signal, input: e.input, render() {
2536
- let i = `${import_picocolors2.default.gray(d)}
2537
- ${L2(this.state)} ${e.message}
2538
- `, s = e.placeholder ? import_picocolors2.default.inverse(e.placeholder[0]) + import_picocolors2.default.dim(e.placeholder.slice(1)) : import_picocolors2.default.inverse(import_picocolors2.default.hidden("_")), r = this.userInput ? this.userInputWithCursor : s, n = this.value ?? "";
2576
+ }, Qt = (e) => new $t({ validate: e.validate, placeholder: e.placeholder, defaultValue: e.defaultValue, initialValue: e.initialValue, output: e.output, signal: e.signal, input: e.input, render() {
2577
+ let r = (e?.withGuide ?? _.withGuide) !== !1, s = `${`${r ? `${import_picocolors2.default.gray(d)}
2578
+ ` : ""}${W2(this.state)} `}${e.message}
2579
+ `, i = e.placeholder ? import_picocolors2.default.inverse(e.placeholder[0]) + import_picocolors2.default.dim(e.placeholder.slice(1)) : import_picocolors2.default.inverse(import_picocolors2.default.hidden("_")), n = this.userInput ? this.userInputWithCursor : i, l = this.value ?? "";
2539
2580
  switch (this.state) {
2540
2581
  case "error": {
2541
- let o = this.error ? ` ${import_picocolors2.default.yellow(this.error)}` : "";
2542
- return `${i.trim()}
2543
- ${import_picocolors2.default.yellow(d)} ${r}
2544
- ${import_picocolors2.default.yellow(x)}${o}
2582
+ let u = this.error ? ` ${import_picocolors2.default.yellow(this.error)}` : "", a = r ? `${import_picocolors2.default.yellow(d)} ` : "", o = r ? import_picocolors2.default.yellow(x2) : "";
2583
+ return `${s.trim()}
2584
+ ${a}${n}
2585
+ ${o}${u}
2545
2586
  `;
2546
2587
  }
2547
2588
  case "submit": {
2548
- let o = n ? ` ${import_picocolors2.default.dim(n)}` : "";
2549
- return `${i}${import_picocolors2.default.gray(d)}${o}`;
2589
+ let u = l ? ` ${import_picocolors2.default.dim(l)}` : "", a = r ? import_picocolors2.default.gray(d) : "";
2590
+ return `${s}${a}${u}`;
2550
2591
  }
2551
2592
  case "cancel": {
2552
- let o = n ? ` ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(n))}` : "";
2553
- return `${i}${import_picocolors2.default.gray(d)}${o}${n.trim() ? `
2554
- ${import_picocolors2.default.gray(d)}` : ""}`;
2555
- }
2556
- default:
2557
- return `${i}${import_picocolors2.default.cyan(d)} ${r}
2558
- ${import_picocolors2.default.cyan(x)}
2593
+ let u = l ? ` ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(l))}` : "", a = r ? import_picocolors2.default.gray(d) : "";
2594
+ return `${s}${a}${u}${l.trim() ? `
2595
+ ${a}` : ""}`;
2596
+ }
2597
+ default: {
2598
+ let u = r ? `${import_picocolors2.default.cyan(d)} ` : "", a = r ? import_picocolors2.default.cyan(x2) : "";
2599
+ return `${s}${u}${n}
2600
+ ${a}
2559
2601
  `;
2602
+ }
2560
2603
  }
2561
2604
  } }).prompt();
2562
2605
 
@@ -3031,35 +3074,35 @@ var getCurrentTaskLog = () => globalThis.STORYBOOK_CURRENT_TASK_LOG ? globalThis
3031
3074
  globalThis.STORYBOOK_CURRENT_TASK_LOG && globalThis.STORYBOOK_CURRENT_TASK_LOG.pop();
3032
3075
  }, ClackPromptProvider = class extends PromptProvider {
3033
3076
  handleCancel(result, promptOptions) {
3034
- _t(result) && (promptOptions?.onCancel ? promptOptions.onCancel() : (Tt2("Operation canceled."), process.exit(0)));
3077
+ Ct(result) && (promptOptions?.onCancel ? promptOptions.onCancel() : (Nt("Operation canceled."), process.exit(0)));
3035
3078
  }
3036
3079
  async text(options, promptOptions) {
3037
- let result = await qt(options);
3080
+ let result = await Qt(options);
3038
3081
  return this.handleCancel(result, promptOptions), logTracker.addLog("prompt", options.message, { choice: result }), result.toString();
3039
3082
  }
3040
3083
  async confirm(options, promptOptions) {
3041
- let result = await xt({
3084
+ let result = await Mt2({
3042
3085
  ...options,
3043
3086
  message: wrapTextForClackHint(options.message, void 0, void 0, 2)
3044
3087
  });
3045
3088
  return this.handleCancel(result, promptOptions), logTracker.addLog("prompt", options.message, { choice: result }), !!result;
3046
3089
  }
3047
3090
  async select(options, promptOptions) {
3048
- let result = await Gt({
3091
+ let result = await qt({
3049
3092
  ...options,
3050
3093
  message: wrapTextForClackHint(options.message, void 0, void 0, 2)
3051
3094
  });
3052
3095
  return this.handleCancel(result, promptOptions), logTracker.addLog("prompt", options.message, { choice: result }), result;
3053
3096
  }
3054
3097
  async multiselect(options, promptOptions) {
3055
- let result = await Ot({
3098
+ let result = await Lt2({
3056
3099
  ...options,
3057
3100
  required: options.required
3058
3101
  });
3059
3102
  return this.handleCancel(result, promptOptions), logTracker.addLog("prompt", options.message, { choice: result }), result;
3060
3103
  }
3061
3104
  spinner(options) {
3062
- let task = Ee(), spinnerId = `${options.id}-spinner`;
3105
+ let task = we(), spinnerId = `${options.id}-spinner`;
3063
3106
  return {
3064
3107
  start: (message) => {
3065
3108
  logTracker.addLog("info", `${spinnerId}-start: ${message}`), task.start(message);
@@ -3069,11 +3112,17 @@ var getCurrentTaskLog = () => globalThis.STORYBOOK_CURRENT_TASK_LOG ? globalThis
3069
3112
  },
3070
3113
  stop: (message) => {
3071
3114
  logTracker.addLog("info", `${spinnerId}-stop: ${message}`), task.stop(message);
3115
+ },
3116
+ cancel: (message) => {
3117
+ logTracker.addLog("info", `${spinnerId}-cancel: ${message}`), task.cancel(message);
3118
+ },
3119
+ error: (message) => {
3120
+ logTracker.addLog("error", `${spinnerId}-error: ${message}`), task.error(message);
3072
3121
  }
3073
3122
  };
3074
3123
  }
3075
3124
  taskLog(options) {
3076
- let isCurrentTaskActive = !!getCurrentTaskLog(), task = getCurrentTaskLog() || Kt(options), taskId = `${options.id}-task`;
3125
+ let isCurrentTaskActive = !!getCurrentTaskLog(), task = getCurrentTaskLog() || zt(options), taskId = `${options.id}-task`;
3077
3126
  return logTracker.addLog("info", `${taskId}-start: ${options.title}`), isCurrentTaskActive || setCurrentTaskLog(task), {
3078
3127
  message: (message) => {
3079
3128
  logTracker.addLog("info", `${taskId}: ${message}`), task.message(message);
@@ -3130,13 +3179,13 @@ var createLogFunction = (clackFn, consoleFn, cliColors) => () => isClackEnabled(
3130
3179
  cliColors && typeof message == "string" ? cliColors(message) : message
3131
3180
  ) : typeof message == "string" ? clackFn(wrapTextForClack(message), ...rest) : clackFn(message, ...rest);
3132
3181
  } : consoleFn, LOG_FUNCTIONS = {
3133
- log: createLogFunction(R.message, console.log),
3134
- info: createLogFunction(R.info, console.log),
3135
- warn: createLogFunction(R.warn, console.warn, CLI_COLORS.warning),
3136
- error: createLogFunction(R.error, console.error, CLI_COLORS.error),
3137
- intro: createLogFunction(Mt2, console.log),
3138
- outro: createLogFunction(Rt, console.log),
3139
- step: createLogFunction(R.step, console.log)
3182
+ log: createLogFunction(R2.message, console.log),
3183
+ info: createLogFunction(R2.info, console.log),
3184
+ warn: createLogFunction(R2.warn, console.warn, CLI_COLORS.warning),
3185
+ error: createLogFunction(R2.error, console.error, CLI_COLORS.error),
3186
+ intro: createLogFunction(Pt, console.log),
3187
+ outro: createLogFunction(Wt2, console.log),
3188
+ step: createLogFunction(R2.step, console.log)
3140
3189
  }, LOG_LEVELS = {
3141
3190
  trace: 1,
3142
3191
  debug: 2,
@@ -3188,7 +3237,7 @@ var debug = createLogger(
3188
3237
  "error",
3189
3238
  (...args) => LOG_FUNCTIONS.error()(...args)
3190
3239
  ), logBox = (message, { title, ...options } = {}) => {
3191
- shouldLog("info") && (logTracker.addLog("info", message), isClackEnabled() ? bt2(message, title, {
3240
+ shouldLog("info") && (logTracker.addLog("info", message), isClackEnabled() ? Tt2(message, title, {
3192
3241
  ...options,
3193
3242
  width: options.width ?? "auto"
3194
3243
  }) : console.log(message));
@@ -3464,64 +3513,6 @@ __export(prompt_functions_exports, {
3464
3513
  taskLog: () => taskLog,
3465
3514
  text: () => text
3466
3515
  });
3467
-
3468
- // src/client-logger/index.ts
3469
- import { global } from "@storybook/global";
3470
- var { LOGLEVEL } = global, levels = {
3471
- trace: 1,
3472
- debug: 2,
3473
- info: 3,
3474
- warn: 4,
3475
- error: 5,
3476
- silent: 10
3477
- }, currentLogLevelString = LOGLEVEL, currentLogLevelNumber = levels[currentLogLevelString] || levels.info, logger = {
3478
- trace: (message, ...rest) => {
3479
- currentLogLevelNumber <= levels.trace && console.trace(message, ...rest);
3480
- },
3481
- debug: (message, ...rest) => {
3482
- currentLogLevelNumber <= levels.debug && console.debug(message, ...rest);
3483
- },
3484
- info: (message, ...rest) => {
3485
- currentLogLevelNumber <= levels.info && console.info(message, ...rest);
3486
- },
3487
- warn: (message, ...rest) => {
3488
- currentLogLevelNumber <= levels.warn && console.warn(message, ...rest);
3489
- },
3490
- error: (message, ...rest) => {
3491
- currentLogLevelNumber <= levels.error && console.error(message, ...rest);
3492
- },
3493
- log: (message, ...rest) => {
3494
- currentLogLevelNumber < levels.silent && console.log(message, ...rest);
3495
- }
3496
- }, logged = /* @__PURE__ */ new Set(), once = (type) => (message, ...rest) => {
3497
- if (!logged.has(message))
3498
- return logged.add(message), logger[type](message, ...rest);
3499
- };
3500
- once.clear = () => logged.clear();
3501
- once.trace = once("trace");
3502
- once.debug = once("debug");
3503
- once.info = once("info");
3504
- once.warn = once("warn");
3505
- once.error = once("error");
3506
- once.log = once("log");
3507
- var deprecate = once("warn"), pretty = (type) => (...args) => {
3508
- let argArray = [];
3509
- if (args.length) {
3510
- let startTagRe = /<span\s+style=(['"])([^'"]*)\1\s*>/gi, endTagRe = /<\/span>/gi, reResultArray;
3511
- for (argArray.push(args[0].replace(startTagRe, "%c").replace(endTagRe, "%c")); reResultArray = startTagRe.exec(args[0]); )
3512
- argArray.push(reResultArray[2]), argArray.push("");
3513
- for (let j3 = 1; j3 < args.length; j3++)
3514
- argArray.push(args[j3]);
3515
- }
3516
- logger[type].apply(logger, argArray);
3517
- };
3518
- pretty.trace = pretty("trace");
3519
- pretty.debug = pretty("debug");
3520
- pretty.info = pretty("info");
3521
- pretty.warn = pretty("warn");
3522
- pretty.error = pretty("error");
3523
-
3524
- // src/node-logger/prompts/prompt-functions.ts
3525
3516
  var activeSpinner = null, activeTaskLog = null, originalConsoleLog = null, isInteractiveTerminal = () => process.stdout.isTTY && process.stdin.isTTY && !process.env.CI, patchConsoleLog = () => {
3526
3517
  originalConsoleLog || (originalConsoleLog = console.log, console.log = (...args) => {
3527
3518
  let message = args.map((arg) => typeof arg == "string" ? arg : JSON.stringify(arg)).join(" ");
@@ -3547,13 +3538,19 @@ var activeSpinner = null, activeTaskLog = null, originalConsoleLog = null, isInt
3547
3538
  stop: (message) => {
3548
3539
  activeSpinner = null, restoreConsoleLog(), shouldLog("info") && spinnerInstance.stop(message);
3549
3540
  },
3541
+ cancel: (message) => {
3542
+ activeSpinner = null, restoreConsoleLog(), shouldLog("info") && spinnerInstance.cancel(message);
3543
+ },
3544
+ error: (message) => {
3545
+ activeSpinner = null, restoreConsoleLog(), shouldLog("error") && spinnerInstance.error(message);
3546
+ },
3550
3547
  message: (text2) => {
3551
3548
  shouldLog("info") && spinnerInstance.message(text2);
3552
3549
  }
3553
3550
  };
3554
3551
  return wrappedSpinner;
3555
3552
  } else {
3556
- let maybeLog = shouldLog("info") ? logger.log : (_) => {
3553
+ let maybeLog = shouldLog("info") ? log : (_2) => {
3557
3554
  };
3558
3555
  return {
3559
3556
  start: (message) => {
@@ -3562,6 +3559,12 @@ var activeSpinner = null, activeTaskLog = null, originalConsoleLog = null, isInt
3562
3559
  stop: (message) => {
3563
3560
  message && maybeLog(message);
3564
3561
  },
3562
+ cancel: (message) => {
3563
+ message && maybeLog(message);
3564
+ },
3565
+ error: (message) => {
3566
+ message && shouldLog("error") && error(message);
3567
+ },
3565
3568
  message: (message) => {
3566
3569
  maybeLog(message);
3567
3570
  }
@@ -3597,7 +3600,7 @@ ${title}
3597
3600
  };
3598
3601
  return activeTaskLog = wrappedTaskLog, patchConsoleLog(), wrappedTaskLog;
3599
3602
  } else {
3600
- let maybeLog = shouldLog("info") ? logger.log : (_) => {
3603
+ let maybeLog = shouldLog("info") ? log : (_2) => {
3601
3604
  };
3602
3605
  return {
3603
3606
  message: (message) => {
@@ -3701,11 +3704,11 @@ var executeTask = async (childProcessFactories, {
3701
3704
  logTracker.addLog("info", success), task.stop(success);
3702
3705
  } catch (err) {
3703
3706
  if (abortController?.signal.aborted || err.message?.includes("Command was killed with SIGINT") || err.message?.includes("The operation was aborted")) {
3704
- logTracker.addLog("info", `${intro2} aborted`), task.stop(CLI_COLORS.warning(`${intro2} aborted`));
3707
+ logTracker.addLog("info", `${intro2} aborted`), task.cancel(CLI_COLORS.warning(`${intro2} aborted`));
3705
3708
  return;
3706
3709
  }
3707
3710
  let errorMessage = err instanceof Error ? err.stack ?? err.message : String(err);
3708
- throw logTracker.addLog("error", error2, { error: errorMessage }), task.stop(CLI_COLORS.error(error2)), err;
3711
+ throw logTracker.addLog("error", error2, { error: errorMessage }), task.error(CLI_COLORS.error(error2)), err;
3709
3712
  } finally {
3710
3713
  cleanup?.();
3711
3714
  }
@@ -3725,8 +3728,8 @@ function hex(hexColor) {
3725
3728
  if (!/^#?[0-9A-Fa-f]{6}$/.test(hexColor))
3726
3729
  throw new Error("Invalid hex color. It must be a 6-character hex code.");
3727
3730
  hexColor.startsWith("#") && (hexColor = hexColor.slice(1));
3728
- let r = parseInt(hexColor.slice(0, 2), 16), g = parseInt(hexColor.slice(2, 4), 16), b2 = parseInt(hexColor.slice(4, 6), 16);
3729
- return (text2) => `\x1B[38;2;${r};${g};${b2}m${text2}\x1B[39m`;
3731
+ let r = parseInt(hexColor.slice(0, 2), 16), g = parseInt(hexColor.slice(2, 4), 16), b = parseInt(hexColor.slice(4, 6), 16);
3732
+ return (text2) => `\x1B[38;2;${r};${g};${b}m${text2}\x1B[39m`;
3730
3733
  }
3731
3734
  var colors = {
3732
3735
  pink: hex("#F1618C"),
@@ -3736,7 +3739,7 @@ var colors = {
3736
3739
  blue: hex("#6DABF5"),
3737
3740
  red: hex("#F16161"),
3738
3741
  gray: hex("#B8C2CC")
3739
- }, logger2 = {
3742
+ }, logger = {
3740
3743
  ...logger_exports,
3741
3744
  verbose: (message) => debug(message),
3742
3745
  line: (count = 1) => log(`${Array(count - 1).fill(`
@@ -3752,16 +3755,16 @@ var colors = {
3752
3755
  message instanceof Error && message.stack ? msg = message.stack.toString().replace(message.toString(), colors.red(message.toString())) : typeof message == "string" ? msg = message.toString() : msg = String(message), error(msg.replaceAll(process.cwd(), "."));
3753
3756
  }
3754
3757
  };
3755
- var logged2 = /* @__PURE__ */ new Set(), once2 = (type) => (message) => {
3756
- if (!logged2.has(message))
3757
- return logged2.add(message), logger2[type](message);
3758
+ var logged = /* @__PURE__ */ new Set(), once = (type) => (message) => {
3759
+ if (!logged.has(message))
3760
+ return logged.add(message), logger[type](message);
3758
3761
  };
3759
- once2.clear = () => logged2.clear();
3760
- once2.verbose = once2("verbose");
3761
- once2.info = once2("info");
3762
- once2.warn = once2("warn");
3763
- once2.error = once2("error");
3764
- var deprecate2 = once2("warn");
3762
+ once.clear = () => logged.clear();
3763
+ once.verbose = once("verbose");
3764
+ once.info = once("info");
3765
+ once.warn = once("warn");
3766
+ once.error = once("error");
3767
+ var deprecate = once("warn");
3765
3768
 
3766
3769
  export {
3767
3770
  require_pretty_hrtime,
@@ -3774,7 +3777,7 @@ export {
3774
3777
  prompt,
3775
3778
  import_npmlog,
3776
3779
  colors,
3777
- logger2 as logger,
3778
- once2 as once,
3779
- deprecate2 as deprecate
3780
+ logger,
3781
+ once,
3782
+ deprecate
3780
3783
  };