@socketsecurity/lib 5.3.0 → 5.4.1

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 (48) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/dist/cover/code.js +12 -4
  3. package/dist/dlx/cache.js +10 -2
  4. package/dist/dlx/manifest.js +45 -41
  5. package/dist/env/rewire.js +10 -2
  6. package/dist/external/@inquirer/checkbox.js +4 -2528
  7. package/dist/external/@inquirer/confirm.js +4 -2371
  8. package/dist/external/@inquirer/input.js +4 -2395
  9. package/dist/external/@inquirer/password.js +4 -2503
  10. package/dist/external/@inquirer/search.js +4 -2500
  11. package/dist/external/@inquirer/select.js +4 -2617
  12. package/dist/external/@npmcli/package-json.js +11 -7
  13. package/dist/external/debug.js +670 -15
  14. package/dist/external/del.js +4 -7139
  15. package/dist/external/external-pack.js +4795 -0
  16. package/dist/external/fast-glob.js +4 -5776
  17. package/dist/external/has-flag.js +6 -0
  18. package/dist/external/libnpmexec.js +2 -2
  19. package/dist/external/normalize-package-data.js +2 -2
  20. package/dist/external/npm-pack.js +1698 -3337
  21. package/dist/external/npm-package-arg.js +2 -2
  22. package/dist/external/pico-pack.js +7162 -0
  23. package/dist/external/picomatch.js +4 -1523
  24. package/dist/external/semver.js +2 -2
  25. package/dist/external/signal-exit.js +5 -0
  26. package/dist/external/spdx-correct.js +4 -1384
  27. package/dist/external/spdx-expression-parse.js +4 -1047
  28. package/dist/external/spdx-pack.js +1640 -0
  29. package/dist/external/supports-color.js +8 -0
  30. package/dist/external/validate-npm-package-name.js +4 -104
  31. package/dist/external/yoctocolors-cjs.js +5 -92
  32. package/dist/http-request.js +10 -2
  33. package/dist/ipc.js +53 -29
  34. package/dist/packages/isolation.js +45 -23
  35. package/dist/packages/licenses.js +10 -2
  36. package/dist/paths/socket.d.ts +2 -2
  37. package/dist/paths/socket.js +27 -21
  38. package/dist/process-lock.js +23 -14
  39. package/dist/releases/github.d.ts +67 -41
  40. package/dist/releases/github.js +142 -100
  41. package/dist/releases/socket-btm.d.ts +40 -33
  42. package/dist/releases/socket-btm.js +45 -5
  43. package/dist/spawn.js +10 -3
  44. package/dist/stdio/mask.d.ts +6 -21
  45. package/dist/stdio/mask.js +18 -14
  46. package/dist/themes/context.js +10 -2
  47. package/package.json +16 -3
  48. package/dist/external/npm-core.js +0 -6588
@@ -0,0 +1,4795 @@
1
+ "use strict";
2
+ /**
3
+ * Bundled from external-pack
4
+ * This is a zero-dependency bundle created by esbuild.
5
+ */
6
+ "use strict";
7
+ var __create = Object.create;
8
+ var __defProp = Object.defineProperty;
9
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
10
+ var __getOwnPropNames = Object.getOwnPropertyNames;
11
+ var __getProtoOf = Object.getPrototypeOf;
12
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
13
+ var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
14
+ var __esm = (fn, res) => function __init() {
15
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
16
+ };
17
+ var __commonJS = (cb, mod) => function __require() {
18
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
19
+ };
20
+ var __export = (target, all) => {
21
+ for (var name in all)
22
+ __defProp(target, name, { get: all[name], enumerable: true });
23
+ };
24
+ var __copyProps = (to, from, except, desc) => {
25
+ if (from && typeof from === "object" || typeof from === "function") {
26
+ for (let key of __getOwnPropNames(from))
27
+ if (!__hasOwnProp.call(to, key) && key !== except)
28
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
29
+ }
30
+ return to;
31
+ };
32
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
33
+ // If the importer is in node compatibility mode or this is not an ESM
34
+ // file that has been converted to a CommonJS file using a Babel-
35
+ // compatible transform (i.e. "__esModule" has not been set), then set
36
+ // "default" to the CommonJS "module.exports" for node compatibility.
37
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
38
+ mod
39
+ ));
40
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
41
+
42
+ // node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/cjs/signals.js
43
+ var require_signals = __commonJS({
44
+ "node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/cjs/signals.js"(exports2) {
45
+ "use strict";
46
+ Object.defineProperty(exports2, "__esModule", { value: true });
47
+ exports2.signals = void 0;
48
+ exports2.signals = [];
49
+ exports2.signals.push("SIGHUP", "SIGINT", "SIGTERM");
50
+ if (process.platform !== "win32") {
51
+ exports2.signals.push(
52
+ "SIGALRM",
53
+ "SIGABRT",
54
+ "SIGVTALRM",
55
+ "SIGXCPU",
56
+ "SIGXFSZ",
57
+ "SIGUSR2",
58
+ "SIGTRAP",
59
+ "SIGSYS",
60
+ "SIGQUIT",
61
+ "SIGIOT"
62
+ // should detect profiler and enable/disable accordingly.
63
+ // see #21
64
+ // 'SIGPROF'
65
+ );
66
+ }
67
+ if (process.platform === "linux") {
68
+ exports2.signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");
69
+ }
70
+ }
71
+ });
72
+
73
+ // node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/cjs/index.js
74
+ var require_cjs = __commonJS({
75
+ "node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/cjs/index.js"(exports2) {
76
+ "use strict";
77
+ var _a;
78
+ Object.defineProperty(exports2, "__esModule", { value: true });
79
+ exports2.unload = exports2.load = exports2.onExit = exports2.signals = void 0;
80
+ var signals_js_1 = require_signals();
81
+ Object.defineProperty(exports2, "signals", { enumerable: true, get: /* @__PURE__ */ __name(function() {
82
+ return signals_js_1.signals;
83
+ }, "get") });
84
+ var processOk = /* @__PURE__ */ __name((process5) => !!process5 && typeof process5 === "object" && typeof process5.removeListener === "function" && typeof process5.emit === "function" && typeof process5.reallyExit === "function" && typeof process5.listeners === "function" && typeof process5.kill === "function" && typeof process5.pid === "number" && typeof process5.on === "function", "processOk");
85
+ var kExitEmitter = Symbol.for("signal-exit emitter");
86
+ var global = globalThis;
87
+ var ObjectDefineProperty = Object.defineProperty.bind(Object);
88
+ var Emitter = class {
89
+ static {
90
+ __name(this, "Emitter");
91
+ }
92
+ emitted = {
93
+ afterExit: false,
94
+ exit: false
95
+ };
96
+ listeners = {
97
+ afterExit: [],
98
+ exit: []
99
+ };
100
+ count = 0;
101
+ id = Math.random();
102
+ constructor() {
103
+ if (global[kExitEmitter]) {
104
+ return global[kExitEmitter];
105
+ }
106
+ ObjectDefineProperty(global, kExitEmitter, {
107
+ value: this,
108
+ writable: false,
109
+ enumerable: false,
110
+ configurable: false
111
+ });
112
+ }
113
+ on(ev, fn) {
114
+ this.listeners[ev].push(fn);
115
+ }
116
+ removeListener(ev, fn) {
117
+ const list = this.listeners[ev];
118
+ const i = list.indexOf(fn);
119
+ if (i === -1) {
120
+ return;
121
+ }
122
+ if (i === 0 && list.length === 1) {
123
+ list.length = 0;
124
+ } else {
125
+ list.splice(i, 1);
126
+ }
127
+ }
128
+ emit(ev, code, signal) {
129
+ if (this.emitted[ev]) {
130
+ return false;
131
+ }
132
+ this.emitted[ev] = true;
133
+ let ret = false;
134
+ for (const fn of this.listeners[ev]) {
135
+ ret = fn(code, signal) === true || ret;
136
+ }
137
+ if (ev === "exit") {
138
+ ret = this.emit("afterExit", code, signal) || ret;
139
+ }
140
+ return ret;
141
+ }
142
+ };
143
+ var SignalExitBase = class {
144
+ static {
145
+ __name(this, "SignalExitBase");
146
+ }
147
+ };
148
+ var signalExitWrap = /* @__PURE__ */ __name((handler) => {
149
+ return {
150
+ onExit(cb, opts) {
151
+ return handler.onExit(cb, opts);
152
+ },
153
+ load() {
154
+ return handler.load();
155
+ },
156
+ unload() {
157
+ return handler.unload();
158
+ }
159
+ };
160
+ }, "signalExitWrap");
161
+ var SignalExitFallback = class extends SignalExitBase {
162
+ static {
163
+ __name(this, "SignalExitFallback");
164
+ }
165
+ onExit() {
166
+ return () => {
167
+ };
168
+ }
169
+ load() {
170
+ }
171
+ unload() {
172
+ }
173
+ };
174
+ var SignalExit = class extends SignalExitBase {
175
+ static {
176
+ __name(this, "SignalExit");
177
+ }
178
+ // "SIGHUP" throws an `ENOSYS` error on Windows,
179
+ // so use a supported signal instead
180
+ /* c8 ignore start */
181
+ #hupSig = process4.platform === "win32" ? "SIGINT" : "SIGHUP";
182
+ /* c8 ignore stop */
183
+ #emitter = new Emitter();
184
+ #process;
185
+ #originalProcessEmit;
186
+ #originalProcessReallyExit;
187
+ #sigListeners = {};
188
+ #loaded = false;
189
+ constructor(process5) {
190
+ super();
191
+ this.#process = process5;
192
+ this.#sigListeners = {};
193
+ for (const sig of signals_js_1.signals) {
194
+ this.#sigListeners[sig] = () => {
195
+ const listeners = this.#process.listeners(sig);
196
+ let { count } = this.#emitter;
197
+ const p = process5;
198
+ if (typeof p.__signal_exit_emitter__ === "object" && typeof p.__signal_exit_emitter__.count === "number") {
199
+ count += p.__signal_exit_emitter__.count;
200
+ }
201
+ if (listeners.length === count) {
202
+ this.unload();
203
+ const ret = this.#emitter.emit("exit", null, sig);
204
+ const s = sig === "SIGHUP" ? this.#hupSig : sig;
205
+ if (!ret)
206
+ process5.kill(process5.pid, s);
207
+ }
208
+ };
209
+ }
210
+ this.#originalProcessReallyExit = process5.reallyExit;
211
+ this.#originalProcessEmit = process5.emit;
212
+ }
213
+ onExit(cb, opts) {
214
+ if (!processOk(this.#process)) {
215
+ return () => {
216
+ };
217
+ }
218
+ if (this.#loaded === false) {
219
+ this.load();
220
+ }
221
+ const ev = opts?.alwaysLast ? "afterExit" : "exit";
222
+ this.#emitter.on(ev, cb);
223
+ return () => {
224
+ this.#emitter.removeListener(ev, cb);
225
+ if (this.#emitter.listeners["exit"].length === 0 && this.#emitter.listeners["afterExit"].length === 0) {
226
+ this.unload();
227
+ }
228
+ };
229
+ }
230
+ load() {
231
+ if (this.#loaded) {
232
+ return;
233
+ }
234
+ this.#loaded = true;
235
+ this.#emitter.count += 1;
236
+ for (const sig of signals_js_1.signals) {
237
+ try {
238
+ const fn = this.#sigListeners[sig];
239
+ if (fn)
240
+ this.#process.on(sig, fn);
241
+ } catch (_) {
242
+ }
243
+ }
244
+ this.#process.emit = (ev, ...a) => {
245
+ return this.#processEmit(ev, ...a);
246
+ };
247
+ this.#process.reallyExit = (code) => {
248
+ return this.#processReallyExit(code);
249
+ };
250
+ }
251
+ unload() {
252
+ if (!this.#loaded) {
253
+ return;
254
+ }
255
+ this.#loaded = false;
256
+ signals_js_1.signals.forEach((sig) => {
257
+ const listener = this.#sigListeners[sig];
258
+ if (!listener) {
259
+ throw new Error("Listener not defined for signal: " + sig);
260
+ }
261
+ try {
262
+ this.#process.removeListener(sig, listener);
263
+ } catch (_) {
264
+ }
265
+ });
266
+ this.#process.emit = this.#originalProcessEmit;
267
+ this.#process.reallyExit = this.#originalProcessReallyExit;
268
+ this.#emitter.count -= 1;
269
+ }
270
+ #processReallyExit(code) {
271
+ if (!processOk(this.#process)) {
272
+ return 0;
273
+ }
274
+ this.#process.exitCode = code || 0;
275
+ this.#emitter.emit("exit", this.#process.exitCode, null);
276
+ return this.#originalProcessReallyExit.call(this.#process, this.#process.exitCode);
277
+ }
278
+ #processEmit(ev, ...args) {
279
+ const og = this.#originalProcessEmit;
280
+ if (ev === "exit" && processOk(this.#process)) {
281
+ if (typeof args[0] === "number") {
282
+ this.#process.exitCode = args[0];
283
+ }
284
+ const ret = og.call(this.#process, ev, ...args);
285
+ this.#emitter.emit("exit", this.#process.exitCode, null);
286
+ return ret;
287
+ } else {
288
+ return og.call(this.#process, ev, ...args);
289
+ }
290
+ }
291
+ };
292
+ var process4 = globalThis.process;
293
+ _a = signalExitWrap(processOk(process4) ? new SignalExit(process4) : new SignalExitFallback()), /**
294
+ * Called when the process is exiting, whether via signal, explicit
295
+ * exit, or running out of stuff to do.
296
+ *
297
+ * If the global process object is not suitable for instrumentation,
298
+ * then this will be a no-op.
299
+ *
300
+ * Returns a function that may be used to unload signal-exit.
301
+ */
302
+ exports2.onExit = _a.onExit, /**
303
+ * Load the listeners. Likely you never need to call this, unless
304
+ * doing a rather deep integration with signal-exit functionality.
305
+ * Mostly exposed for the benefit of testing.
306
+ *
307
+ * @internal
308
+ */
309
+ exports2.load = _a.load, /**
310
+ * Unload the listeners. Likely you never need to call this, unless
311
+ * doing a rather deep integration with signal-exit functionality.
312
+ * Mostly exposed for the benefit of testing.
313
+ *
314
+ * @internal
315
+ */
316
+ exports2.unload = _a.unload;
317
+ }
318
+ });
319
+
320
+ // node_modules/.pnpm/supports-color@10.0.0/node_modules/supports-color/index.js
321
+ var supports_color_exports = {};
322
+ __export(supports_color_exports, {
323
+ createSupportsColor: () => createSupportsColor,
324
+ default: () => supports_color_default
325
+ });
326
+ function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : import_node_process.default.argv) {
327
+ const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
328
+ const position = argv.indexOf(prefix + flag);
329
+ const terminatorPosition = argv.indexOf("--");
330
+ return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
331
+ }
332
+ function envForceColor() {
333
+ if (!("FORCE_COLOR" in env)) {
334
+ return;
335
+ }
336
+ if (env.FORCE_COLOR === "true") {
337
+ return 1;
338
+ }
339
+ if (env.FORCE_COLOR === "false") {
340
+ return 0;
341
+ }
342
+ if (env.FORCE_COLOR.length === 0) {
343
+ return 1;
344
+ }
345
+ const level = Math.min(Number.parseInt(env.FORCE_COLOR, 10), 3);
346
+ if (![0, 1, 2, 3].includes(level)) {
347
+ return;
348
+ }
349
+ return level;
350
+ }
351
+ function translateLevel(level) {
352
+ if (level === 0) {
353
+ return false;
354
+ }
355
+ return {
356
+ level,
357
+ hasBasic: true,
358
+ has256: level >= 2,
359
+ has16m: level >= 3
360
+ };
361
+ }
362
+ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
363
+ const noFlagForceColor = envForceColor();
364
+ if (noFlagForceColor !== void 0) {
365
+ flagForceColor = noFlagForceColor;
366
+ }
367
+ const forceColor = sniffFlags ? flagForceColor : noFlagForceColor;
368
+ if (forceColor === 0) {
369
+ return 0;
370
+ }
371
+ if (sniffFlags) {
372
+ if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) {
373
+ return 3;
374
+ }
375
+ if (hasFlag("color=256")) {
376
+ return 2;
377
+ }
378
+ }
379
+ if ("TF_BUILD" in env && "AGENT_NAME" in env) {
380
+ return 1;
381
+ }
382
+ if (haveStream && !streamIsTTY && forceColor === void 0) {
383
+ return 0;
384
+ }
385
+ const min = forceColor || 0;
386
+ if (env.TERM === "dumb") {
387
+ return min;
388
+ }
389
+ if (import_node_process.default.platform === "win32") {
390
+ const osRelease = import_node_os.default.release().split(".");
391
+ if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
392
+ return Number(osRelease[2]) >= 14931 ? 3 : 2;
393
+ }
394
+ return 1;
395
+ }
396
+ if ("CI" in env) {
397
+ if (["GITHUB_ACTIONS", "GITEA_ACTIONS", "CIRCLECI"].some((key) => key in env)) {
398
+ return 3;
399
+ }
400
+ if (["TRAVIS", "APPVEYOR", "GITLAB_CI", "BUILDKITE", "DRONE"].some((sign) => sign in env) || env.CI_NAME === "codeship") {
401
+ return 1;
402
+ }
403
+ return min;
404
+ }
405
+ if ("TEAMCITY_VERSION" in env) {
406
+ return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
407
+ }
408
+ if (env.COLORTERM === "truecolor") {
409
+ return 3;
410
+ }
411
+ if (env.TERM === "xterm-kitty") {
412
+ return 3;
413
+ }
414
+ if ("TERM_PROGRAM" in env) {
415
+ const version = Number.parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
416
+ switch (env.TERM_PROGRAM) {
417
+ case "iTerm.app": {
418
+ return version >= 3 ? 3 : 2;
419
+ }
420
+ case "Apple_Terminal": {
421
+ return 2;
422
+ }
423
+ }
424
+ }
425
+ if (/-256(color)?$/i.test(env.TERM)) {
426
+ return 2;
427
+ }
428
+ if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {
429
+ return 1;
430
+ }
431
+ if ("COLORTERM" in env) {
432
+ return 1;
433
+ }
434
+ return min;
435
+ }
436
+ function createSupportsColor(stream, options = {}) {
437
+ const level = _supportsColor(stream, {
438
+ streamIsTTY: stream && stream.isTTY,
439
+ ...options
440
+ });
441
+ return translateLevel(level);
442
+ }
443
+ var import_node_process, import_node_os, import_node_tty, env, flagForceColor, supportsColor, supports_color_default;
444
+ var init_supports_color = __esm({
445
+ "node_modules/.pnpm/supports-color@10.0.0/node_modules/supports-color/index.js"() {
446
+ import_node_process = __toESM(require("node:process"), 1);
447
+ import_node_os = __toESM(require("node:os"), 1);
448
+ import_node_tty = __toESM(require("node:tty"), 1);
449
+ __name(hasFlag, "hasFlag");
450
+ ({ env } = import_node_process.default);
451
+ if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) {
452
+ flagForceColor = 0;
453
+ } else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) {
454
+ flagForceColor = 1;
455
+ }
456
+ __name(envForceColor, "envForceColor");
457
+ __name(translateLevel, "translateLevel");
458
+ __name(_supportsColor, "_supportsColor");
459
+ __name(createSupportsColor, "createSupportsColor");
460
+ supportsColor = {
461
+ stdout: createSupportsColor({ isTTY: import_node_tty.default.isatty(1) }),
462
+ stderr: createSupportsColor({ isTTY: import_node_tty.default.isatty(2) })
463
+ };
464
+ supports_color_default = supportsColor;
465
+ }
466
+ });
467
+
468
+ // node_modules/.pnpm/has-flag@5.0.1/node_modules/has-flag/index.js
469
+ var has_flag_exports = {};
470
+ __export(has_flag_exports, {
471
+ default: () => hasFlag2
472
+ });
473
+ function hasFlag2(flag, argv = import_process.default.argv) {
474
+ const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
475
+ const position = argv.indexOf(prefix + flag);
476
+ const terminatorPosition = argv.indexOf("--");
477
+ return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
478
+ }
479
+ var import_process;
480
+ var init_has_flag = __esm({
481
+ "node_modules/.pnpm/has-flag@5.0.1/node_modules/has-flag/index.js"() {
482
+ import_process = __toESM(require("process"), 1);
483
+ __name(hasFlag2, "hasFlag");
484
+ }
485
+ });
486
+
487
+ // node_modules/.pnpm/yoctocolors-cjs@2.1.3/node_modules/yoctocolors-cjs/index.js
488
+ var require_yoctocolors_cjs = __commonJS({
489
+ "node_modules/.pnpm/yoctocolors-cjs@2.1.3/node_modules/yoctocolors-cjs/index.js"(exports2, module2) {
490
+ var tty2 = require("node:tty");
491
+ var hasColors = tty2?.WriteStream?.prototype?.hasColors?.() ?? false;
492
+ var format = /* @__PURE__ */ __name((open, close) => {
493
+ if (!hasColors) {
494
+ return (input2) => input2;
495
+ }
496
+ const openCode = `\x1B[${open}m`;
497
+ const closeCode = `\x1B[${close}m`;
498
+ return (input2) => {
499
+ const string = input2 + "";
500
+ let index = string.indexOf(closeCode);
501
+ if (index === -1) {
502
+ return openCode + string + closeCode;
503
+ }
504
+ let result = openCode;
505
+ let lastIndex = 0;
506
+ const reopenOnNestedClose = close === 22;
507
+ const replaceCode = (reopenOnNestedClose ? closeCode : "") + openCode;
508
+ while (index !== -1) {
509
+ result += string.slice(lastIndex, index) + replaceCode;
510
+ lastIndex = index + closeCode.length;
511
+ index = string.indexOf(closeCode, lastIndex);
512
+ }
513
+ result += string.slice(lastIndex) + closeCode;
514
+ return result;
515
+ };
516
+ }, "format");
517
+ var colors = {};
518
+ colors.reset = format(0, 0);
519
+ colors.bold = format(1, 22);
520
+ colors.dim = format(2, 22);
521
+ colors.italic = format(3, 23);
522
+ colors.underline = format(4, 24);
523
+ colors.overline = format(53, 55);
524
+ colors.inverse = format(7, 27);
525
+ colors.hidden = format(8, 28);
526
+ colors.strikethrough = format(9, 29);
527
+ colors.black = format(30, 39);
528
+ colors.red = format(31, 39);
529
+ colors.green = format(32, 39);
530
+ colors.yellow = format(33, 39);
531
+ colors.blue = format(34, 39);
532
+ colors.magenta = format(35, 39);
533
+ colors.cyan = format(36, 39);
534
+ colors.white = format(37, 39);
535
+ colors.gray = format(90, 39);
536
+ colors.bgBlack = format(40, 49);
537
+ colors.bgRed = format(41, 49);
538
+ colors.bgGreen = format(42, 49);
539
+ colors.bgYellow = format(43, 49);
540
+ colors.bgBlue = format(44, 49);
541
+ colors.bgMagenta = format(45, 49);
542
+ colors.bgCyan = format(46, 49);
543
+ colors.bgWhite = format(47, 49);
544
+ colors.bgGray = format(100, 49);
545
+ colors.redBright = format(91, 39);
546
+ colors.greenBright = format(92, 39);
547
+ colors.yellowBright = format(93, 39);
548
+ colors.blueBright = format(94, 39);
549
+ colors.magentaBright = format(95, 39);
550
+ colors.cyanBright = format(96, 39);
551
+ colors.whiteBright = format(97, 39);
552
+ colors.bgRedBright = format(101, 49);
553
+ colors.bgGreenBright = format(102, 49);
554
+ colors.bgYellowBright = format(103, 49);
555
+ colors.bgBlueBright = format(104, 49);
556
+ colors.bgMagentaBright = format(105, 49);
557
+ colors.bgCyanBright = format(106, 49);
558
+ colors.bgWhiteBright = format(107, 49);
559
+ module2.exports = colors;
560
+ }
561
+ });
562
+
563
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/key.js
564
+ var require_key = __commonJS({
565
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/key.js"(exports2) {
566
+ "use strict";
567
+ Object.defineProperty(exports2, "__esModule", { value: true });
568
+ exports2.isEnterKey = exports2.isNumberKey = exports2.isTabKey = exports2.isBackspaceKey = exports2.isSpaceKey = exports2.isDownKey = exports2.isUpKey = void 0;
569
+ var isUpKey = /* @__PURE__ */ __name((key, keybindings = []) => (
570
+ // The up key
571
+ key.name === "up" || // Vim keybinding: hjkl keys map to left/down/up/right
572
+ keybindings.includes("vim") && key.name === "k" || // Emacs keybinding: Ctrl+P means "previous" in Emacs navigation conventions
573
+ keybindings.includes("emacs") && key.ctrl && key.name === "p"
574
+ ), "isUpKey");
575
+ exports2.isUpKey = isUpKey;
576
+ var isDownKey = /* @__PURE__ */ __name((key, keybindings = []) => (
577
+ // The down key
578
+ key.name === "down" || // Vim keybinding: hjkl keys map to left/down/up/right
579
+ keybindings.includes("vim") && key.name === "j" || // Emacs keybinding: Ctrl+N means "next" in Emacs navigation conventions
580
+ keybindings.includes("emacs") && key.ctrl && key.name === "n"
581
+ ), "isDownKey");
582
+ exports2.isDownKey = isDownKey;
583
+ var isSpaceKey = /* @__PURE__ */ __name((key) => key.name === "space", "isSpaceKey");
584
+ exports2.isSpaceKey = isSpaceKey;
585
+ var isBackspaceKey = /* @__PURE__ */ __name((key) => key.name === "backspace", "isBackspaceKey");
586
+ exports2.isBackspaceKey = isBackspaceKey;
587
+ var isTabKey = /* @__PURE__ */ __name((key) => key.name === "tab", "isTabKey");
588
+ exports2.isTabKey = isTabKey;
589
+ var isNumberKey = /* @__PURE__ */ __name((key) => "1234567890".includes(key.name), "isNumberKey");
590
+ exports2.isNumberKey = isNumberKey;
591
+ var isEnterKey = /* @__PURE__ */ __name((key) => key.name === "enter" || key.name === "return", "isEnterKey");
592
+ exports2.isEnterKey = isEnterKey;
593
+ }
594
+ });
595
+
596
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/errors.js
597
+ var require_errors = __commonJS({
598
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/errors.js"(exports2) {
599
+ "use strict";
600
+ Object.defineProperty(exports2, "__esModule", { value: true });
601
+ exports2.ValidationError = exports2.HookError = exports2.ExitPromptError = exports2.CancelPromptError = exports2.AbortPromptError = void 0;
602
+ var AbortPromptError = class extends Error {
603
+ static {
604
+ __name(this, "AbortPromptError");
605
+ }
606
+ name = "AbortPromptError";
607
+ message = "Prompt was aborted";
608
+ constructor(options) {
609
+ super();
610
+ this.cause = options?.cause;
611
+ }
612
+ };
613
+ exports2.AbortPromptError = AbortPromptError;
614
+ var CancelPromptError = class extends Error {
615
+ static {
616
+ __name(this, "CancelPromptError");
617
+ }
618
+ name = "CancelPromptError";
619
+ message = "Prompt was canceled";
620
+ };
621
+ exports2.CancelPromptError = CancelPromptError;
622
+ var ExitPromptError = class extends Error {
623
+ static {
624
+ __name(this, "ExitPromptError");
625
+ }
626
+ name = "ExitPromptError";
627
+ };
628
+ exports2.ExitPromptError = ExitPromptError;
629
+ var HookError = class extends Error {
630
+ static {
631
+ __name(this, "HookError");
632
+ }
633
+ name = "HookError";
634
+ };
635
+ exports2.HookError = HookError;
636
+ var ValidationError = class extends Error {
637
+ static {
638
+ __name(this, "ValidationError");
639
+ }
640
+ name = "ValidationError";
641
+ };
642
+ exports2.ValidationError = ValidationError;
643
+ }
644
+ });
645
+
646
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/hook-engine.js
647
+ var require_hook_engine = __commonJS({
648
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/hook-engine.js"(exports2) {
649
+ "use strict";
650
+ Object.defineProperty(exports2, "__esModule", { value: true });
651
+ exports2.effectScheduler = void 0;
652
+ exports2.withHooks = withHooks;
653
+ exports2.readline = readline;
654
+ exports2.withUpdates = withUpdates;
655
+ exports2.withPointer = withPointer;
656
+ exports2.handleChange = handleChange;
657
+ var node_async_hooks_1 = require("node:async_hooks");
658
+ var errors_ts_1 = require_errors();
659
+ var hookStorage = new node_async_hooks_1.AsyncLocalStorage();
660
+ function createStore(rl) {
661
+ const store = {
662
+ rl,
663
+ hooks: [],
664
+ hooksCleanup: [],
665
+ hooksEffect: [],
666
+ index: 0,
667
+ handleChange() {
668
+ }
669
+ };
670
+ return store;
671
+ }
672
+ __name(createStore, "createStore");
673
+ function withHooks(rl, cb) {
674
+ const store = createStore(rl);
675
+ return hookStorage.run(store, () => {
676
+ function cycle(render) {
677
+ store.handleChange = () => {
678
+ store.index = 0;
679
+ render();
680
+ };
681
+ store.handleChange();
682
+ }
683
+ __name(cycle, "cycle");
684
+ return cb(cycle);
685
+ });
686
+ }
687
+ __name(withHooks, "withHooks");
688
+ function getStore() {
689
+ const store = hookStorage.getStore();
690
+ if (!store) {
691
+ throw new errors_ts_1.HookError("[Inquirer] Hook functions can only be called from within a prompt");
692
+ }
693
+ return store;
694
+ }
695
+ __name(getStore, "getStore");
696
+ function readline() {
697
+ return getStore().rl;
698
+ }
699
+ __name(readline, "readline");
700
+ function withUpdates(fn) {
701
+ const wrapped = /* @__PURE__ */ __name((...args) => {
702
+ const store = getStore();
703
+ let shouldUpdate = false;
704
+ const oldHandleChange = store.handleChange;
705
+ store.handleChange = () => {
706
+ shouldUpdate = true;
707
+ };
708
+ const returnValue = fn(...args);
709
+ if (shouldUpdate) {
710
+ oldHandleChange();
711
+ }
712
+ store.handleChange = oldHandleChange;
713
+ return returnValue;
714
+ }, "wrapped");
715
+ return node_async_hooks_1.AsyncResource.bind(wrapped);
716
+ }
717
+ __name(withUpdates, "withUpdates");
718
+ function withPointer(cb) {
719
+ const store = getStore();
720
+ const { index } = store;
721
+ const pointer = {
722
+ get() {
723
+ return store.hooks[index];
724
+ },
725
+ set(value) {
726
+ store.hooks[index] = value;
727
+ },
728
+ initialized: index in store.hooks
729
+ };
730
+ const returnValue = cb(pointer);
731
+ store.index++;
732
+ return returnValue;
733
+ }
734
+ __name(withPointer, "withPointer");
735
+ function handleChange() {
736
+ getStore().handleChange();
737
+ }
738
+ __name(handleChange, "handleChange");
739
+ exports2.effectScheduler = {
740
+ queue(cb) {
741
+ const store = getStore();
742
+ const { index } = store;
743
+ store.hooksEffect.push(() => {
744
+ store.hooksCleanup[index]?.();
745
+ const cleanFn = cb(readline());
746
+ if (cleanFn != null && typeof cleanFn !== "function") {
747
+ throw new errors_ts_1.ValidationError("useEffect return value must be a cleanup function or nothing.");
748
+ }
749
+ store.hooksCleanup[index] = cleanFn;
750
+ });
751
+ },
752
+ run() {
753
+ const store = getStore();
754
+ withUpdates(() => {
755
+ store.hooksEffect.forEach((effect) => {
756
+ effect();
757
+ });
758
+ store.hooksEffect.length = 0;
759
+ })();
760
+ },
761
+ clearAll() {
762
+ const store = getStore();
763
+ store.hooksCleanup.forEach((cleanFn) => {
764
+ cleanFn?.();
765
+ });
766
+ store.hooksEffect.length = 0;
767
+ store.hooksCleanup.length = 0;
768
+ }
769
+ };
770
+ }
771
+ });
772
+
773
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-state.js
774
+ var require_use_state = __commonJS({
775
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-state.js"(exports2) {
776
+ "use strict";
777
+ Object.defineProperty(exports2, "__esModule", { value: true });
778
+ exports2.useState = useState;
779
+ var node_async_hooks_1 = require("node:async_hooks");
780
+ var hook_engine_ts_1 = require_hook_engine();
781
+ function useState(defaultValue) {
782
+ return (0, hook_engine_ts_1.withPointer)((pointer) => {
783
+ const setState = node_async_hooks_1.AsyncResource.bind(/* @__PURE__ */ __name(function setState2(newValue) {
784
+ if (pointer.get() !== newValue) {
785
+ pointer.set(newValue);
786
+ (0, hook_engine_ts_1.handleChange)();
787
+ }
788
+ }, "setState"));
789
+ if (pointer.initialized) {
790
+ return [pointer.get(), setState];
791
+ }
792
+ const value = typeof defaultValue === "function" ? defaultValue() : defaultValue;
793
+ pointer.set(value);
794
+ return [value, setState];
795
+ });
796
+ }
797
+ __name(useState, "useState");
798
+ }
799
+ });
800
+
801
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-effect.js
802
+ var require_use_effect = __commonJS({
803
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-effect.js"(exports2) {
804
+ "use strict";
805
+ Object.defineProperty(exports2, "__esModule", { value: true });
806
+ exports2.useEffect = useEffect;
807
+ var hook_engine_ts_1 = require_hook_engine();
808
+ function useEffect(cb, depArray) {
809
+ (0, hook_engine_ts_1.withPointer)((pointer) => {
810
+ const oldDeps = pointer.get();
811
+ const hasChanged = !Array.isArray(oldDeps) || depArray.some((dep, i) => !Object.is(dep, oldDeps[i]));
812
+ if (hasChanged) {
813
+ hook_engine_ts_1.effectScheduler.queue(cb);
814
+ }
815
+ pointer.set(depArray);
816
+ });
817
+ }
818
+ __name(useEffect, "useEffect");
819
+ }
820
+ });
821
+
822
+ // node_modules/.pnpm/@inquirer+figures@1.0.15/node_modules/@inquirer/figures/dist/commonjs/index.js
823
+ var require_commonjs = __commonJS({
824
+ "node_modules/.pnpm/@inquirer+figures@1.0.15/node_modules/@inquirer/figures/dist/commonjs/index.js"(exports2) {
825
+ "use strict";
826
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
827
+ return mod && mod.__esModule ? mod : { "default": mod };
828
+ };
829
+ Object.defineProperty(exports2, "__esModule", { value: true });
830
+ exports2.replaceSymbols = exports2.fallbackSymbols = exports2.mainSymbols = void 0;
831
+ var node_process_1 = __importDefault(require("node:process"));
832
+ function isUnicodeSupported() {
833
+ if (node_process_1.default.platform !== "win32") {
834
+ return node_process_1.default.env["TERM"] !== "linux";
835
+ }
836
+ return Boolean(node_process_1.default.env["WT_SESSION"]) || // Windows Terminal
837
+ Boolean(node_process_1.default.env["TERMINUS_SUBLIME"]) || // Terminus (<0.2.27)
838
+ node_process_1.default.env["ConEmuTask"] === "{cmd::Cmder}" || // ConEmu and cmder
839
+ node_process_1.default.env["TERM_PROGRAM"] === "Terminus-Sublime" || node_process_1.default.env["TERM_PROGRAM"] === "vscode" || node_process_1.default.env["TERM"] === "xterm-256color" || node_process_1.default.env["TERM"] === "alacritty" || node_process_1.default.env["TERMINAL_EMULATOR"] === "JetBrains-JediTerm";
840
+ }
841
+ __name(isUnicodeSupported, "isUnicodeSupported");
842
+ var common = {
843
+ circleQuestionMark: "(?)",
844
+ questionMarkPrefix: "(?)",
845
+ square: "█",
846
+ squareDarkShade: "▓",
847
+ squareMediumShade: "▒",
848
+ squareLightShade: "░",
849
+ squareTop: "▀",
850
+ squareBottom: "▄",
851
+ squareLeft: "▌",
852
+ squareRight: "▐",
853
+ squareCenter: "■",
854
+ bullet: "●",
855
+ dot: "․",
856
+ ellipsis: "…",
857
+ pointerSmall: "›",
858
+ triangleUp: "▲",
859
+ triangleUpSmall: "▴",
860
+ triangleDown: "▼",
861
+ triangleDownSmall: "▾",
862
+ triangleLeftSmall: "◂",
863
+ triangleRightSmall: "▸",
864
+ home: "⌂",
865
+ heart: "♥",
866
+ musicNote: "♪",
867
+ musicNoteBeamed: "♫",
868
+ arrowUp: "↑",
869
+ arrowDown: "↓",
870
+ arrowLeft: "←",
871
+ arrowRight: "→",
872
+ arrowLeftRight: "↔",
873
+ arrowUpDown: "↕",
874
+ almostEqual: "≈",
875
+ notEqual: "≠",
876
+ lessOrEqual: "≤",
877
+ greaterOrEqual: "≥",
878
+ identical: "≡",
879
+ infinity: "∞",
880
+ subscriptZero: "₀",
881
+ subscriptOne: "₁",
882
+ subscriptTwo: "₂",
883
+ subscriptThree: "₃",
884
+ subscriptFour: "₄",
885
+ subscriptFive: "₅",
886
+ subscriptSix: "₆",
887
+ subscriptSeven: "₇",
888
+ subscriptEight: "₈",
889
+ subscriptNine: "₉",
890
+ oneHalf: "½",
891
+ oneThird: "⅓",
892
+ oneQuarter: "¼",
893
+ oneFifth: "⅕",
894
+ oneSixth: "⅙",
895
+ oneEighth: "⅛",
896
+ twoThirds: "⅔",
897
+ twoFifths: "⅖",
898
+ threeQuarters: "¾",
899
+ threeFifths: "⅗",
900
+ threeEighths: "⅜",
901
+ fourFifths: "⅘",
902
+ fiveSixths: "⅚",
903
+ fiveEighths: "⅝",
904
+ sevenEighths: "⅞",
905
+ line: "─",
906
+ lineBold: "━",
907
+ lineDouble: "═",
908
+ lineDashed0: "┄",
909
+ lineDashed1: "┅",
910
+ lineDashed2: "┈",
911
+ lineDashed3: "┉",
912
+ lineDashed4: "╌",
913
+ lineDashed5: "╍",
914
+ lineDashed6: "╴",
915
+ lineDashed7: "╶",
916
+ lineDashed8: "╸",
917
+ lineDashed9: "╺",
918
+ lineDashed10: "╼",
919
+ lineDashed11: "╾",
920
+ lineDashed12: "−",
921
+ lineDashed13: "–",
922
+ lineDashed14: "‐",
923
+ lineDashed15: "⁃",
924
+ lineVertical: "│",
925
+ lineVerticalBold: "┃",
926
+ lineVerticalDouble: "║",
927
+ lineVerticalDashed0: "┆",
928
+ lineVerticalDashed1: "┇",
929
+ lineVerticalDashed2: "┊",
930
+ lineVerticalDashed3: "┋",
931
+ lineVerticalDashed4: "╎",
932
+ lineVerticalDashed5: "╏",
933
+ lineVerticalDashed6: "╵",
934
+ lineVerticalDashed7: "╷",
935
+ lineVerticalDashed8: "╹",
936
+ lineVerticalDashed9: "╻",
937
+ lineVerticalDashed10: "╽",
938
+ lineVerticalDashed11: "╿",
939
+ lineDownLeft: "┐",
940
+ lineDownLeftArc: "╮",
941
+ lineDownBoldLeftBold: "┓",
942
+ lineDownBoldLeft: "┒",
943
+ lineDownLeftBold: "┑",
944
+ lineDownDoubleLeftDouble: "╗",
945
+ lineDownDoubleLeft: "╖",
946
+ lineDownLeftDouble: "╕",
947
+ lineDownRight: "┌",
948
+ lineDownRightArc: "╭",
949
+ lineDownBoldRightBold: "┏",
950
+ lineDownBoldRight: "┎",
951
+ lineDownRightBold: "┍",
952
+ lineDownDoubleRightDouble: "╔",
953
+ lineDownDoubleRight: "╓",
954
+ lineDownRightDouble: "╒",
955
+ lineUpLeft: "┘",
956
+ lineUpLeftArc: "╯",
957
+ lineUpBoldLeftBold: "┛",
958
+ lineUpBoldLeft: "┚",
959
+ lineUpLeftBold: "┙",
960
+ lineUpDoubleLeftDouble: "╝",
961
+ lineUpDoubleLeft: "╜",
962
+ lineUpLeftDouble: "╛",
963
+ lineUpRight: "└",
964
+ lineUpRightArc: "╰",
965
+ lineUpBoldRightBold: "┗",
966
+ lineUpBoldRight: "┖",
967
+ lineUpRightBold: "┕",
968
+ lineUpDoubleRightDouble: "╚",
969
+ lineUpDoubleRight: "╙",
970
+ lineUpRightDouble: "╘",
971
+ lineUpDownLeft: "┤",
972
+ lineUpBoldDownBoldLeftBold: "┫",
973
+ lineUpBoldDownBoldLeft: "┨",
974
+ lineUpDownLeftBold: "┥",
975
+ lineUpBoldDownLeftBold: "┩",
976
+ lineUpDownBoldLeftBold: "┪",
977
+ lineUpDownBoldLeft: "┧",
978
+ lineUpBoldDownLeft: "┦",
979
+ lineUpDoubleDownDoubleLeftDouble: "╣",
980
+ lineUpDoubleDownDoubleLeft: "╢",
981
+ lineUpDownLeftDouble: "╡",
982
+ lineUpDownRight: "├",
983
+ lineUpBoldDownBoldRightBold: "┣",
984
+ lineUpBoldDownBoldRight: "┠",
985
+ lineUpDownRightBold: "┝",
986
+ lineUpBoldDownRightBold: "┡",
987
+ lineUpDownBoldRightBold: "┢",
988
+ lineUpDownBoldRight: "┟",
989
+ lineUpBoldDownRight: "┞",
990
+ lineUpDoubleDownDoubleRightDouble: "╠",
991
+ lineUpDoubleDownDoubleRight: "╟",
992
+ lineUpDownRightDouble: "╞",
993
+ lineDownLeftRight: "┬",
994
+ lineDownBoldLeftBoldRightBold: "┳",
995
+ lineDownLeftBoldRightBold: "┯",
996
+ lineDownBoldLeftRight: "┰",
997
+ lineDownBoldLeftBoldRight: "┱",
998
+ lineDownBoldLeftRightBold: "┲",
999
+ lineDownLeftRightBold: "┮",
1000
+ lineDownLeftBoldRight: "┭",
1001
+ lineDownDoubleLeftDoubleRightDouble: "╦",
1002
+ lineDownDoubleLeftRight: "╥",
1003
+ lineDownLeftDoubleRightDouble: "╤",
1004
+ lineUpLeftRight: "┴",
1005
+ lineUpBoldLeftBoldRightBold: "┻",
1006
+ lineUpLeftBoldRightBold: "┷",
1007
+ lineUpBoldLeftRight: "┸",
1008
+ lineUpBoldLeftBoldRight: "┹",
1009
+ lineUpBoldLeftRightBold: "┺",
1010
+ lineUpLeftRightBold: "┶",
1011
+ lineUpLeftBoldRight: "┵",
1012
+ lineUpDoubleLeftDoubleRightDouble: "╩",
1013
+ lineUpDoubleLeftRight: "╨",
1014
+ lineUpLeftDoubleRightDouble: "╧",
1015
+ lineUpDownLeftRight: "┼",
1016
+ lineUpBoldDownBoldLeftBoldRightBold: "╋",
1017
+ lineUpDownBoldLeftBoldRightBold: "╈",
1018
+ lineUpBoldDownLeftBoldRightBold: "╇",
1019
+ lineUpBoldDownBoldLeftRightBold: "╊",
1020
+ lineUpBoldDownBoldLeftBoldRight: "╉",
1021
+ lineUpBoldDownLeftRight: "╀",
1022
+ lineUpDownBoldLeftRight: "╁",
1023
+ lineUpDownLeftBoldRight: "┽",
1024
+ lineUpDownLeftRightBold: "┾",
1025
+ lineUpBoldDownBoldLeftRight: "╂",
1026
+ lineUpDownLeftBoldRightBold: "┿",
1027
+ lineUpBoldDownLeftBoldRight: "╃",
1028
+ lineUpBoldDownLeftRightBold: "╄",
1029
+ lineUpDownBoldLeftBoldRight: "╅",
1030
+ lineUpDownBoldLeftRightBold: "╆",
1031
+ lineUpDoubleDownDoubleLeftDoubleRightDouble: "╬",
1032
+ lineUpDoubleDownDoubleLeftRight: "╫",
1033
+ lineUpDownLeftDoubleRightDouble: "╪",
1034
+ lineCross: "╳",
1035
+ lineBackslash: "╲",
1036
+ lineSlash: "╱"
1037
+ };
1038
+ var specialMainSymbols = {
1039
+ tick: "✔",
1040
+ info: "ℹ",
1041
+ warning: "⚠",
1042
+ cross: "✘",
1043
+ squareSmall: "◻",
1044
+ squareSmallFilled: "◼",
1045
+ circle: "◯",
1046
+ circleFilled: "◉",
1047
+ circleDotted: "◌",
1048
+ circleDouble: "◎",
1049
+ circleCircle: "ⓞ",
1050
+ circleCross: "ⓧ",
1051
+ circlePipe: "Ⓘ",
1052
+ radioOn: "◉",
1053
+ radioOff: "◯",
1054
+ checkboxOn: "☒",
1055
+ checkboxOff: "☐",
1056
+ checkboxCircleOn: "ⓧ",
1057
+ checkboxCircleOff: "Ⓘ",
1058
+ pointer: "❯",
1059
+ triangleUpOutline: "△",
1060
+ triangleLeft: "◀",
1061
+ triangleRight: "▶",
1062
+ lozenge: "◆",
1063
+ lozengeOutline: "◇",
1064
+ hamburger: "☰",
1065
+ smiley: "㋡",
1066
+ mustache: "෴",
1067
+ star: "★",
1068
+ play: "▶",
1069
+ nodejs: "⬢",
1070
+ oneSeventh: "⅐",
1071
+ oneNinth: "⅑",
1072
+ oneTenth: "⅒"
1073
+ };
1074
+ var specialFallbackSymbols = {
1075
+ tick: "√",
1076
+ info: "i",
1077
+ warning: "‼",
1078
+ cross: "×",
1079
+ squareSmall: "□",
1080
+ squareSmallFilled: "■",
1081
+ circle: "( )",
1082
+ circleFilled: "(*)",
1083
+ circleDotted: "( )",
1084
+ circleDouble: "( )",
1085
+ circleCircle: "(○)",
1086
+ circleCross: "(×)",
1087
+ circlePipe: "(│)",
1088
+ radioOn: "(*)",
1089
+ radioOff: "( )",
1090
+ checkboxOn: "[×]",
1091
+ checkboxOff: "[ ]",
1092
+ checkboxCircleOn: "(×)",
1093
+ checkboxCircleOff: "( )",
1094
+ pointer: ">",
1095
+ triangleUpOutline: "∆",
1096
+ triangleLeft: "◄",
1097
+ triangleRight: "►",
1098
+ lozenge: "♦",
1099
+ lozengeOutline: "◊",
1100
+ hamburger: "≡",
1101
+ smiley: "☺",
1102
+ mustache: "┌─┐",
1103
+ star: "✶",
1104
+ play: "►",
1105
+ nodejs: "♦",
1106
+ oneSeventh: "1/7",
1107
+ oneNinth: "1/9",
1108
+ oneTenth: "1/10"
1109
+ };
1110
+ exports2.mainSymbols = {
1111
+ ...common,
1112
+ ...specialMainSymbols
1113
+ };
1114
+ exports2.fallbackSymbols = {
1115
+ ...common,
1116
+ ...specialFallbackSymbols
1117
+ };
1118
+ var shouldUseMain = isUnicodeSupported();
1119
+ var figures = shouldUseMain ? exports2.mainSymbols : exports2.fallbackSymbols;
1120
+ exports2.default = figures;
1121
+ var replacements = Object.entries(specialMainSymbols);
1122
+ var replaceSymbols = /* @__PURE__ */ __name((string, { useFallback = !shouldUseMain } = {}) => {
1123
+ if (useFallback) {
1124
+ for (const [key, mainSymbol] of replacements) {
1125
+ const fallbackSymbol = exports2.fallbackSymbols[key];
1126
+ if (!fallbackSymbol) {
1127
+ throw new Error(`Unable to find fallback for ${key}`);
1128
+ }
1129
+ string = string.replaceAll(mainSymbol, fallbackSymbol);
1130
+ }
1131
+ }
1132
+ return string;
1133
+ }, "replaceSymbols");
1134
+ exports2.replaceSymbols = replaceSymbols;
1135
+ }
1136
+ });
1137
+
1138
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/theme.js
1139
+ var require_theme = __commonJS({
1140
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/theme.js"(exports2) {
1141
+ "use strict";
1142
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
1143
+ return mod && mod.__esModule ? mod : { "default": mod };
1144
+ };
1145
+ Object.defineProperty(exports2, "__esModule", { value: true });
1146
+ exports2.defaultTheme = void 0;
1147
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
1148
+ var figures_1 = __importDefault(require_commonjs());
1149
+ exports2.defaultTheme = {
1150
+ prefix: {
1151
+ idle: yoctocolors_cjs_1.default.blue("?"),
1152
+ done: yoctocolors_cjs_1.default.green(figures_1.default.tick)
1153
+ },
1154
+ spinner: {
1155
+ interval: 80,
1156
+ frames: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"].map((frame) => yoctocolors_cjs_1.default.yellow(frame))
1157
+ },
1158
+ style: {
1159
+ answer: yoctocolors_cjs_1.default.cyan,
1160
+ message: yoctocolors_cjs_1.default.bold,
1161
+ error: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.red(`> ${text}`), "error"),
1162
+ defaultAnswer: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.dim(`(${text})`), "defaultAnswer"),
1163
+ help: yoctocolors_cjs_1.default.dim,
1164
+ highlight: yoctocolors_cjs_1.default.cyan,
1165
+ key: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(yoctocolors_cjs_1.default.bold(`<${text}>`)), "key")
1166
+ }
1167
+ };
1168
+ }
1169
+ });
1170
+
1171
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/make-theme.js
1172
+ var require_make_theme = __commonJS({
1173
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/make-theme.js"(exports2) {
1174
+ "use strict";
1175
+ Object.defineProperty(exports2, "__esModule", { value: true });
1176
+ exports2.makeTheme = makeTheme;
1177
+ var theme_ts_1 = require_theme();
1178
+ function isPlainObject(value) {
1179
+ if (typeof value !== "object" || value === null)
1180
+ return false;
1181
+ let proto = value;
1182
+ while (Object.getPrototypeOf(proto) !== null) {
1183
+ proto = Object.getPrototypeOf(proto);
1184
+ }
1185
+ return Object.getPrototypeOf(value) === proto;
1186
+ }
1187
+ __name(isPlainObject, "isPlainObject");
1188
+ function deepMerge(...objects) {
1189
+ const output = {};
1190
+ for (const obj of objects) {
1191
+ for (const [key, value] of Object.entries(obj)) {
1192
+ const prevValue = output[key];
1193
+ output[key] = isPlainObject(prevValue) && isPlainObject(value) ? deepMerge(prevValue, value) : value;
1194
+ }
1195
+ }
1196
+ return output;
1197
+ }
1198
+ __name(deepMerge, "deepMerge");
1199
+ function makeTheme(...themes) {
1200
+ const themesToMerge = [
1201
+ theme_ts_1.defaultTheme,
1202
+ ...themes.filter((theme) => theme != null)
1203
+ ];
1204
+ return deepMerge(...themesToMerge);
1205
+ }
1206
+ __name(makeTheme, "makeTheme");
1207
+ }
1208
+ });
1209
+
1210
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-prefix.js
1211
+ var require_use_prefix = __commonJS({
1212
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-prefix.js"(exports2) {
1213
+ "use strict";
1214
+ Object.defineProperty(exports2, "__esModule", { value: true });
1215
+ exports2.usePrefix = usePrefix;
1216
+ var use_state_ts_1 = require_use_state();
1217
+ var use_effect_ts_1 = require_use_effect();
1218
+ var make_theme_ts_1 = require_make_theme();
1219
+ function usePrefix({ status = "idle", theme }) {
1220
+ const [showLoader, setShowLoader] = (0, use_state_ts_1.useState)(false);
1221
+ const [tick, setTick] = (0, use_state_ts_1.useState)(0);
1222
+ const { prefix, spinner } = (0, make_theme_ts_1.makeTheme)(theme);
1223
+ (0, use_effect_ts_1.useEffect)(() => {
1224
+ if (status === "loading") {
1225
+ let tickInterval;
1226
+ let inc = -1;
1227
+ const delayTimeout = setTimeout(() => {
1228
+ setShowLoader(true);
1229
+ tickInterval = setInterval(() => {
1230
+ inc = inc + 1;
1231
+ setTick(inc % spinner.frames.length);
1232
+ }, spinner.interval);
1233
+ }, 300);
1234
+ return () => {
1235
+ clearTimeout(delayTimeout);
1236
+ clearInterval(tickInterval);
1237
+ };
1238
+ } else {
1239
+ setShowLoader(false);
1240
+ }
1241
+ }, [status]);
1242
+ if (showLoader) {
1243
+ return spinner.frames[tick];
1244
+ }
1245
+ const iconName = status === "loading" ? "idle" : status;
1246
+ return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
1247
+ }
1248
+ __name(usePrefix, "usePrefix");
1249
+ }
1250
+ });
1251
+
1252
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-memo.js
1253
+ var require_use_memo = __commonJS({
1254
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-memo.js"(exports2) {
1255
+ "use strict";
1256
+ Object.defineProperty(exports2, "__esModule", { value: true });
1257
+ exports2.useMemo = useMemo;
1258
+ var hook_engine_ts_1 = require_hook_engine();
1259
+ function useMemo(fn, dependencies) {
1260
+ return (0, hook_engine_ts_1.withPointer)((pointer) => {
1261
+ const prev = pointer.get();
1262
+ if (!prev || prev.dependencies.length !== dependencies.length || prev.dependencies.some((dep, i) => dep !== dependencies[i])) {
1263
+ const value = fn();
1264
+ pointer.set({ value, dependencies });
1265
+ return value;
1266
+ }
1267
+ return prev.value;
1268
+ });
1269
+ }
1270
+ __name(useMemo, "useMemo");
1271
+ }
1272
+ });
1273
+
1274
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-ref.js
1275
+ var require_use_ref = __commonJS({
1276
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-ref.js"(exports2) {
1277
+ "use strict";
1278
+ Object.defineProperty(exports2, "__esModule", { value: true });
1279
+ exports2.useRef = useRef;
1280
+ var use_state_ts_1 = require_use_state();
1281
+ function useRef(val) {
1282
+ return (0, use_state_ts_1.useState)({ current: val })[0];
1283
+ }
1284
+ __name(useRef, "useRef");
1285
+ }
1286
+ });
1287
+
1288
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-keypress.js
1289
+ var require_use_keypress = __commonJS({
1290
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-keypress.js"(exports2) {
1291
+ "use strict";
1292
+ Object.defineProperty(exports2, "__esModule", { value: true });
1293
+ exports2.useKeypress = useKeypress;
1294
+ var use_ref_ts_1 = require_use_ref();
1295
+ var use_effect_ts_1 = require_use_effect();
1296
+ var hook_engine_ts_1 = require_hook_engine();
1297
+ function useKeypress(userHandler) {
1298
+ const signal = (0, use_ref_ts_1.useRef)(userHandler);
1299
+ signal.current = userHandler;
1300
+ (0, use_effect_ts_1.useEffect)((rl) => {
1301
+ let ignore = false;
1302
+ const handler = (0, hook_engine_ts_1.withUpdates)((_input, event) => {
1303
+ if (ignore)
1304
+ return;
1305
+ void signal.current(event, rl);
1306
+ });
1307
+ rl.input.on("keypress", handler);
1308
+ return () => {
1309
+ ignore = true;
1310
+ rl.input.removeListener("keypress", handler);
1311
+ };
1312
+ }, []);
1313
+ }
1314
+ __name(useKeypress, "useKeypress");
1315
+ }
1316
+ });
1317
+
1318
+ // node_modules/.pnpm/cli-width@4.1.0/node_modules/cli-width/index.js
1319
+ var require_cli_width = __commonJS({
1320
+ "node_modules/.pnpm/cli-width@4.1.0/node_modules/cli-width/index.js"(exports2, module2) {
1321
+ "use strict";
1322
+ module2.exports = cliWidth;
1323
+ function normalizeOpts(options) {
1324
+ const defaultOpts = {
1325
+ defaultWidth: 0,
1326
+ output: process.stdout,
1327
+ tty: require("tty")
1328
+ };
1329
+ if (!options) {
1330
+ return defaultOpts;
1331
+ }
1332
+ Object.keys(defaultOpts).forEach(function(key) {
1333
+ if (!options[key]) {
1334
+ options[key] = defaultOpts[key];
1335
+ }
1336
+ });
1337
+ return options;
1338
+ }
1339
+ __name(normalizeOpts, "normalizeOpts");
1340
+ function cliWidth(options) {
1341
+ const opts = normalizeOpts(options);
1342
+ if (opts.output.getWindowSize) {
1343
+ return opts.output.getWindowSize()[0] || opts.defaultWidth;
1344
+ }
1345
+ if (opts.tty.getWindowSize) {
1346
+ return opts.tty.getWindowSize()[1] || opts.defaultWidth;
1347
+ }
1348
+ if (opts.output.columns) {
1349
+ return opts.output.columns;
1350
+ }
1351
+ if (process.env.CLI_WIDTH) {
1352
+ const width = parseInt(process.env.CLI_WIDTH, 10);
1353
+ if (!isNaN(width) && width !== 0) {
1354
+ return width;
1355
+ }
1356
+ }
1357
+ return opts.defaultWidth;
1358
+ }
1359
+ __name(cliWidth, "cliWidth");
1360
+ }
1361
+ });
1362
+
1363
+ // node_modules/.pnpm/ansi-regex@6.2.2/node_modules/ansi-regex/index.js
1364
+ function ansiRegex({ onlyFirst = false } = {}) {
1365
+ const ST = "(?:\\u0007|\\u001B\\u005C|\\u009C)";
1366
+ const osc = `(?:\\u001B\\][\\s\\S]*?${ST})`;
1367
+ const csi = "[\\u001B\\u009B][[\\]()#;?]*(?:\\d{1,4}(?:[;:]\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]";
1368
+ const pattern = `${osc}|${csi}`;
1369
+ return new RegExp(pattern, onlyFirst ? void 0 : "g");
1370
+ }
1371
+ var init_ansi_regex = __esm({
1372
+ "node_modules/.pnpm/ansi-regex@6.2.2/node_modules/ansi-regex/index.js"() {
1373
+ __name(ansiRegex, "ansiRegex");
1374
+ }
1375
+ });
1376
+
1377
+ // node_modules/.pnpm/strip-ansi@7.1.2/node_modules/strip-ansi/index.js
1378
+ function stripAnsi(string) {
1379
+ if (typeof string !== "string") {
1380
+ throw new TypeError(`Expected a \`string\`, got \`${typeof string}\``);
1381
+ }
1382
+ return string.replace(regex, "");
1383
+ }
1384
+ var regex;
1385
+ var init_strip_ansi = __esm({
1386
+ "node_modules/.pnpm/strip-ansi@7.1.2/node_modules/strip-ansi/index.js"() {
1387
+ init_ansi_regex();
1388
+ regex = ansiRegex();
1389
+ __name(stripAnsi, "stripAnsi");
1390
+ }
1391
+ });
1392
+
1393
+ // node_modules/.pnpm/get-east-asian-width@1.3.0/node_modules/get-east-asian-width/lookup.js
1394
+ function isAmbiguous(x) {
1395
+ return x === 161 || x === 164 || x === 167 || x === 168 || x === 170 || x === 173 || x === 174 || x >= 176 && x <= 180 || x >= 182 && x <= 186 || x >= 188 && x <= 191 || x === 198 || x === 208 || x === 215 || x === 216 || x >= 222 && x <= 225 || x === 230 || x >= 232 && x <= 234 || x === 236 || x === 237 || x === 240 || x === 242 || x === 243 || x >= 247 && x <= 250 || x === 252 || x === 254 || x === 257 || x === 273 || x === 275 || x === 283 || x === 294 || x === 295 || x === 299 || x >= 305 && x <= 307 || x === 312 || x >= 319 && x <= 322 || x === 324 || x >= 328 && x <= 331 || x === 333 || x === 338 || x === 339 || x === 358 || x === 359 || x === 363 || x === 462 || x === 464 || x === 466 || x === 468 || x === 470 || x === 472 || x === 474 || x === 476 || x === 593 || x === 609 || x === 708 || x === 711 || x >= 713 && x <= 715 || x === 717 || x === 720 || x >= 728 && x <= 731 || x === 733 || x === 735 || x >= 768 && x <= 879 || x >= 913 && x <= 929 || x >= 931 && x <= 937 || x >= 945 && x <= 961 || x >= 963 && x <= 969 || x === 1025 || x >= 1040 && x <= 1103 || x === 1105 || x === 8208 || x >= 8211 && x <= 8214 || x === 8216 || x === 8217 || x === 8220 || x === 8221 || x >= 8224 && x <= 8226 || x >= 8228 && x <= 8231 || x === 8240 || x === 8242 || x === 8243 || x === 8245 || x === 8251 || x === 8254 || x === 8308 || x === 8319 || x >= 8321 && x <= 8324 || x === 8364 || x === 8451 || x === 8453 || x === 8457 || x === 8467 || x === 8470 || x === 8481 || x === 8482 || x === 8486 || x === 8491 || x === 8531 || x === 8532 || x >= 8539 && x <= 8542 || x >= 8544 && x <= 8555 || x >= 8560 && x <= 8569 || x === 8585 || x >= 8592 && x <= 8601 || x === 8632 || x === 8633 || x === 8658 || x === 8660 || x === 8679 || x === 8704 || x === 8706 || x === 8707 || x === 8711 || x === 8712 || x === 8715 || x === 8719 || x === 8721 || x === 8725 || x === 8730 || x >= 8733 && x <= 8736 || x === 8739 || x === 8741 || x >= 8743 && x <= 8748 || x === 8750 || x >= 8756 && x <= 8759 || x === 8764 || x === 8765 || x === 8776 || x === 8780 || x === 8786 || x === 8800 || x === 8801 || x >= 8804 && x <= 8807 || x === 8810 || x === 8811 || x === 8814 || x === 8815 || x === 8834 || x === 8835 || x === 8838 || x === 8839 || x === 8853 || x === 8857 || x === 8869 || x === 8895 || x === 8978 || x >= 9312 && x <= 9449 || x >= 9451 && x <= 9547 || x >= 9552 && x <= 9587 || x >= 9600 && x <= 9615 || x >= 9618 && x <= 9621 || x === 9632 || x === 9633 || x >= 9635 && x <= 9641 || x === 9650 || x === 9651 || x === 9654 || x === 9655 || x === 9660 || x === 9661 || x === 9664 || x === 9665 || x >= 9670 && x <= 9672 || x === 9675 || x >= 9678 && x <= 9681 || x >= 9698 && x <= 9701 || x === 9711 || x === 9733 || x === 9734 || x === 9737 || x === 9742 || x === 9743 || x === 9756 || x === 9758 || x === 9792 || x === 9794 || x === 9824 || x === 9825 || x >= 9827 && x <= 9829 || x >= 9831 && x <= 9834 || x === 9836 || x === 9837 || x === 9839 || x === 9886 || x === 9887 || x === 9919 || x >= 9926 && x <= 9933 || x >= 9935 && x <= 9939 || x >= 9941 && x <= 9953 || x === 9955 || x === 9960 || x === 9961 || x >= 9963 && x <= 9969 || x === 9972 || x >= 9974 && x <= 9977 || x === 9979 || x === 9980 || x === 9982 || x === 9983 || x === 10045 || x >= 10102 && x <= 10111 || x >= 11094 && x <= 11097 || x >= 12872 && x <= 12879 || x >= 57344 && x <= 63743 || x >= 65024 && x <= 65039 || x === 65533 || x >= 127232 && x <= 127242 || x >= 127248 && x <= 127277 || x >= 127280 && x <= 127337 || x >= 127344 && x <= 127373 || x === 127375 || x === 127376 || x >= 127387 && x <= 127404 || x >= 917760 && x <= 917999 || x >= 983040 && x <= 1048573 || x >= 1048576 && x <= 1114109;
1396
+ }
1397
+ function isFullWidth(x) {
1398
+ return x === 12288 || x >= 65281 && x <= 65376 || x >= 65504 && x <= 65510;
1399
+ }
1400
+ function isWide(x) {
1401
+ return x >= 4352 && x <= 4447 || x === 8986 || x === 8987 || x === 9001 || x === 9002 || x >= 9193 && x <= 9196 || x === 9200 || x === 9203 || x === 9725 || x === 9726 || x === 9748 || x === 9749 || x >= 9776 && x <= 9783 || x >= 9800 && x <= 9811 || x === 9855 || x >= 9866 && x <= 9871 || x === 9875 || x === 9889 || x === 9898 || x === 9899 || x === 9917 || x === 9918 || x === 9924 || x === 9925 || x === 9934 || x === 9940 || x === 9962 || x === 9970 || x === 9971 || x === 9973 || x === 9978 || x === 9981 || x === 9989 || x === 9994 || x === 9995 || x === 10024 || x === 10060 || x === 10062 || x >= 10067 && x <= 10069 || x === 10071 || x >= 10133 && x <= 10135 || x === 10160 || x === 10175 || x === 11035 || x === 11036 || x === 11088 || x === 11093 || x >= 11904 && x <= 11929 || x >= 11931 && x <= 12019 || x >= 12032 && x <= 12245 || x >= 12272 && x <= 12287 || x >= 12289 && x <= 12350 || x >= 12353 && x <= 12438 || x >= 12441 && x <= 12543 || x >= 12549 && x <= 12591 || x >= 12593 && x <= 12686 || x >= 12688 && x <= 12773 || x >= 12783 && x <= 12830 || x >= 12832 && x <= 12871 || x >= 12880 && x <= 42124 || x >= 42128 && x <= 42182 || x >= 43360 && x <= 43388 || x >= 44032 && x <= 55203 || x >= 63744 && x <= 64255 || x >= 65040 && x <= 65049 || x >= 65072 && x <= 65106 || x >= 65108 && x <= 65126 || x >= 65128 && x <= 65131 || x >= 94176 && x <= 94180 || x === 94192 || x === 94193 || x >= 94208 && x <= 100343 || x >= 100352 && x <= 101589 || x >= 101631 && x <= 101640 || x >= 110576 && x <= 110579 || x >= 110581 && x <= 110587 || x === 110589 || x === 110590 || x >= 110592 && x <= 110882 || x === 110898 || x >= 110928 && x <= 110930 || x === 110933 || x >= 110948 && x <= 110951 || x >= 110960 && x <= 111355 || x >= 119552 && x <= 119638 || x >= 119648 && x <= 119670 || x === 126980 || x === 127183 || x === 127374 || x >= 127377 && x <= 127386 || x >= 127488 && x <= 127490 || x >= 127504 && x <= 127547 || x >= 127552 && x <= 127560 || x === 127568 || x === 127569 || x >= 127584 && x <= 127589 || x >= 127744 && x <= 127776 || x >= 127789 && x <= 127797 || x >= 127799 && x <= 127868 || x >= 127870 && x <= 127891 || x >= 127904 && x <= 127946 || x >= 127951 && x <= 127955 || x >= 127968 && x <= 127984 || x === 127988 || x >= 127992 && x <= 128062 || x === 128064 || x >= 128066 && x <= 128252 || x >= 128255 && x <= 128317 || x >= 128331 && x <= 128334 || x >= 128336 && x <= 128359 || x === 128378 || x === 128405 || x === 128406 || x === 128420 || x >= 128507 && x <= 128591 || x >= 128640 && x <= 128709 || x === 128716 || x >= 128720 && x <= 128722 || x >= 128725 && x <= 128727 || x >= 128732 && x <= 128735 || x === 128747 || x === 128748 || x >= 128756 && x <= 128764 || x >= 128992 && x <= 129003 || x === 129008 || x >= 129292 && x <= 129338 || x >= 129340 && x <= 129349 || x >= 129351 && x <= 129535 || x >= 129648 && x <= 129660 || x >= 129664 && x <= 129673 || x >= 129679 && x <= 129734 || x >= 129742 && x <= 129756 || x >= 129759 && x <= 129769 || x >= 129776 && x <= 129784 || x >= 131072 && x <= 196605 || x >= 196608 && x <= 262141;
1402
+ }
1403
+ var init_lookup = __esm({
1404
+ "node_modules/.pnpm/get-east-asian-width@1.3.0/node_modules/get-east-asian-width/lookup.js"() {
1405
+ __name(isAmbiguous, "isAmbiguous");
1406
+ __name(isFullWidth, "isFullWidth");
1407
+ __name(isWide, "isWide");
1408
+ }
1409
+ });
1410
+
1411
+ // node_modules/.pnpm/get-east-asian-width@1.3.0/node_modules/get-east-asian-width/index.js
1412
+ function validate(codePoint) {
1413
+ if (!Number.isSafeInteger(codePoint)) {
1414
+ throw new TypeError(`Expected a code point, got \`${typeof codePoint}\`.`);
1415
+ }
1416
+ }
1417
+ function eastAsianWidth(codePoint, { ambiguousAsWide = false } = {}) {
1418
+ validate(codePoint);
1419
+ if (isFullWidth(codePoint) || isWide(codePoint) || ambiguousAsWide && isAmbiguous(codePoint)) {
1420
+ return 2;
1421
+ }
1422
+ return 1;
1423
+ }
1424
+ var init_get_east_asian_width = __esm({
1425
+ "node_modules/.pnpm/get-east-asian-width@1.3.0/node_modules/get-east-asian-width/index.js"() {
1426
+ init_lookup();
1427
+ __name(validate, "validate");
1428
+ __name(eastAsianWidth, "eastAsianWidth");
1429
+ }
1430
+ });
1431
+
1432
+ // node_modules/.pnpm/string-width@8.1.0/node_modules/string-width/index.js
1433
+ function baseVisible(segment) {
1434
+ return segment.replace(leadingNonPrintingRegex, "");
1435
+ }
1436
+ function isZeroWidthCluster(segment) {
1437
+ return zeroWidthClusterRegex.test(segment);
1438
+ }
1439
+ function trailingHalfwidthWidth(segment, eastAsianWidthOptions) {
1440
+ let extra = 0;
1441
+ if (segment.length > 1) {
1442
+ for (const char of segment.slice(1)) {
1443
+ if (char >= "＀" && char <= "￯") {
1444
+ extra += eastAsianWidth(char.codePointAt(0), eastAsianWidthOptions);
1445
+ }
1446
+ }
1447
+ }
1448
+ return extra;
1449
+ }
1450
+ function stringWidth(input2, options = {}) {
1451
+ if (typeof input2 !== "string" || input2.length === 0) {
1452
+ return 0;
1453
+ }
1454
+ const {
1455
+ ambiguousIsNarrow = true,
1456
+ countAnsiEscapeCodes = false
1457
+ } = options;
1458
+ let string = input2;
1459
+ if (!countAnsiEscapeCodes) {
1460
+ string = stripAnsi(string);
1461
+ }
1462
+ if (string.length === 0) {
1463
+ return 0;
1464
+ }
1465
+ let width = 0;
1466
+ const eastAsianWidthOptions = { ambiguousAsWide: !ambiguousIsNarrow };
1467
+ for (const { segment } of segmenter.segment(string)) {
1468
+ if (isZeroWidthCluster(segment)) {
1469
+ continue;
1470
+ }
1471
+ if (rgiEmojiRegex.test(segment)) {
1472
+ width += 2;
1473
+ continue;
1474
+ }
1475
+ const codePoint = baseVisible(segment).codePointAt(0);
1476
+ width += eastAsianWidth(codePoint, eastAsianWidthOptions);
1477
+ width += trailingHalfwidthWidth(segment, eastAsianWidthOptions);
1478
+ }
1479
+ return width;
1480
+ }
1481
+ var segmenter, zeroWidthClusterRegex, leadingNonPrintingRegex, rgiEmojiRegex;
1482
+ var init_string_width = __esm({
1483
+ "node_modules/.pnpm/string-width@8.1.0/node_modules/string-width/index.js"() {
1484
+ init_strip_ansi();
1485
+ init_get_east_asian_width();
1486
+ segmenter = new Intl.Segmenter();
1487
+ zeroWidthClusterRegex = new RegExp("^(?:\\p{Default_Ignorable_Code_Point}|\\p{Control}|\\p{Mark}|\\p{Surrogate})+$", "v");
1488
+ leadingNonPrintingRegex = new RegExp("^[\\p{Default_Ignorable_Code_Point}\\p{Control}\\p{Format}\\p{Mark}\\p{Surrogate}]+", "v");
1489
+ rgiEmojiRegex = new RegExp("^\\p{RGI_Emoji}$", "v");
1490
+ __name(baseVisible, "baseVisible");
1491
+ __name(isZeroWidthCluster, "isZeroWidthCluster");
1492
+ __name(trailingHalfwidthWidth, "trailingHalfwidthWidth");
1493
+ __name(stringWidth, "stringWidth");
1494
+ }
1495
+ });
1496
+
1497
+ // node_modules/.pnpm/ansi-styles@6.2.3/node_modules/ansi-styles/index.js
1498
+ function assembleStyles() {
1499
+ const codes = /* @__PURE__ */ new Map();
1500
+ for (const [groupName, group] of Object.entries(styles)) {
1501
+ for (const [styleName, style] of Object.entries(group)) {
1502
+ styles[styleName] = {
1503
+ open: `\x1B[${style[0]}m`,
1504
+ close: `\x1B[${style[1]}m`
1505
+ };
1506
+ group[styleName] = styles[styleName];
1507
+ codes.set(style[0], style[1]);
1508
+ }
1509
+ Object.defineProperty(styles, groupName, {
1510
+ value: group,
1511
+ enumerable: false
1512
+ });
1513
+ }
1514
+ Object.defineProperty(styles, "codes", {
1515
+ value: codes,
1516
+ enumerable: false
1517
+ });
1518
+ styles.color.close = "\x1B[39m";
1519
+ styles.bgColor.close = "\x1B[49m";
1520
+ styles.color.ansi = wrapAnsi16();
1521
+ styles.color.ansi256 = wrapAnsi256();
1522
+ styles.color.ansi16m = wrapAnsi16m();
1523
+ styles.bgColor.ansi = wrapAnsi16(ANSI_BACKGROUND_OFFSET);
1524
+ styles.bgColor.ansi256 = wrapAnsi256(ANSI_BACKGROUND_OFFSET);
1525
+ styles.bgColor.ansi16m = wrapAnsi16m(ANSI_BACKGROUND_OFFSET);
1526
+ Object.defineProperties(styles, {
1527
+ rgbToAnsi256: {
1528
+ value(red, green, blue) {
1529
+ if (red === green && green === blue) {
1530
+ if (red < 8) {
1531
+ return 16;
1532
+ }
1533
+ if (red > 248) {
1534
+ return 231;
1535
+ }
1536
+ return Math.round((red - 8) / 247 * 24) + 232;
1537
+ }
1538
+ return 16 + 36 * Math.round(red / 255 * 5) + 6 * Math.round(green / 255 * 5) + Math.round(blue / 255 * 5);
1539
+ },
1540
+ enumerable: false
1541
+ },
1542
+ hexToRgb: {
1543
+ value(hex) {
1544
+ const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
1545
+ if (!matches) {
1546
+ return [0, 0, 0];
1547
+ }
1548
+ let [colorString] = matches;
1549
+ if (colorString.length === 3) {
1550
+ colorString = [...colorString].map((character) => character + character).join("");
1551
+ }
1552
+ const integer = Number.parseInt(colorString, 16);
1553
+ return [
1554
+ /* eslint-disable no-bitwise */
1555
+ integer >> 16 & 255,
1556
+ integer >> 8 & 255,
1557
+ integer & 255
1558
+ /* eslint-enable no-bitwise */
1559
+ ];
1560
+ },
1561
+ enumerable: false
1562
+ },
1563
+ hexToAnsi256: {
1564
+ value: /* @__PURE__ */ __name((hex) => styles.rgbToAnsi256(...styles.hexToRgb(hex)), "value"),
1565
+ enumerable: false
1566
+ },
1567
+ ansi256ToAnsi: {
1568
+ value(code) {
1569
+ if (code < 8) {
1570
+ return 30 + code;
1571
+ }
1572
+ if (code < 16) {
1573
+ return 90 + (code - 8);
1574
+ }
1575
+ let red;
1576
+ let green;
1577
+ let blue;
1578
+ if (code >= 232) {
1579
+ red = ((code - 232) * 10 + 8) / 255;
1580
+ green = red;
1581
+ blue = red;
1582
+ } else {
1583
+ code -= 16;
1584
+ const remainder = code % 36;
1585
+ red = Math.floor(code / 36) / 5;
1586
+ green = Math.floor(remainder / 6) / 5;
1587
+ blue = remainder % 6 / 5;
1588
+ }
1589
+ const value = Math.max(red, green, blue) * 2;
1590
+ if (value === 0) {
1591
+ return 30;
1592
+ }
1593
+ let result = 30 + (Math.round(blue) << 2 | Math.round(green) << 1 | Math.round(red));
1594
+ if (value === 2) {
1595
+ result += 60;
1596
+ }
1597
+ return result;
1598
+ },
1599
+ enumerable: false
1600
+ },
1601
+ rgbToAnsi: {
1602
+ value: /* @__PURE__ */ __name((red, green, blue) => styles.ansi256ToAnsi(styles.rgbToAnsi256(red, green, blue)), "value"),
1603
+ enumerable: false
1604
+ },
1605
+ hexToAnsi: {
1606
+ value: /* @__PURE__ */ __name((hex) => styles.ansi256ToAnsi(styles.hexToAnsi256(hex)), "value"),
1607
+ enumerable: false
1608
+ }
1609
+ });
1610
+ return styles;
1611
+ }
1612
+ var ANSI_BACKGROUND_OFFSET, wrapAnsi16, wrapAnsi256, wrapAnsi16m, styles, modifierNames, foregroundColorNames, backgroundColorNames, colorNames, ansiStyles, ansi_styles_default;
1613
+ var init_ansi_styles = __esm({
1614
+ "node_modules/.pnpm/ansi-styles@6.2.3/node_modules/ansi-styles/index.js"() {
1615
+ ANSI_BACKGROUND_OFFSET = 10;
1616
+ wrapAnsi16 = /* @__PURE__ */ __name((offset = 0) => (code) => `\x1B[${code + offset}m`, "wrapAnsi16");
1617
+ wrapAnsi256 = /* @__PURE__ */ __name((offset = 0) => (code) => `\x1B[${38 + offset};5;${code}m`, "wrapAnsi256");
1618
+ wrapAnsi16m = /* @__PURE__ */ __name((offset = 0) => (red, green, blue) => `\x1B[${38 + offset};2;${red};${green};${blue}m`, "wrapAnsi16m");
1619
+ styles = {
1620
+ modifier: {
1621
+ reset: [0, 0],
1622
+ // 21 isn't widely supported and 22 does the same thing
1623
+ bold: [1, 22],
1624
+ dim: [2, 22],
1625
+ italic: [3, 23],
1626
+ underline: [4, 24],
1627
+ overline: [53, 55],
1628
+ inverse: [7, 27],
1629
+ hidden: [8, 28],
1630
+ strikethrough: [9, 29]
1631
+ },
1632
+ color: {
1633
+ black: [30, 39],
1634
+ red: [31, 39],
1635
+ green: [32, 39],
1636
+ yellow: [33, 39],
1637
+ blue: [34, 39],
1638
+ magenta: [35, 39],
1639
+ cyan: [36, 39],
1640
+ white: [37, 39],
1641
+ // Bright color
1642
+ blackBright: [90, 39],
1643
+ gray: [90, 39],
1644
+ // Alias of `blackBright`
1645
+ grey: [90, 39],
1646
+ // Alias of `blackBright`
1647
+ redBright: [91, 39],
1648
+ greenBright: [92, 39],
1649
+ yellowBright: [93, 39],
1650
+ blueBright: [94, 39],
1651
+ magentaBright: [95, 39],
1652
+ cyanBright: [96, 39],
1653
+ whiteBright: [97, 39]
1654
+ },
1655
+ bgColor: {
1656
+ bgBlack: [40, 49],
1657
+ bgRed: [41, 49],
1658
+ bgGreen: [42, 49],
1659
+ bgYellow: [43, 49],
1660
+ bgBlue: [44, 49],
1661
+ bgMagenta: [45, 49],
1662
+ bgCyan: [46, 49],
1663
+ bgWhite: [47, 49],
1664
+ // Bright color
1665
+ bgBlackBright: [100, 49],
1666
+ bgGray: [100, 49],
1667
+ // Alias of `bgBlackBright`
1668
+ bgGrey: [100, 49],
1669
+ // Alias of `bgBlackBright`
1670
+ bgRedBright: [101, 49],
1671
+ bgGreenBright: [102, 49],
1672
+ bgYellowBright: [103, 49],
1673
+ bgBlueBright: [104, 49],
1674
+ bgMagentaBright: [105, 49],
1675
+ bgCyanBright: [106, 49],
1676
+ bgWhiteBright: [107, 49]
1677
+ }
1678
+ };
1679
+ modifierNames = Object.keys(styles.modifier);
1680
+ foregroundColorNames = Object.keys(styles.color);
1681
+ backgroundColorNames = Object.keys(styles.bgColor);
1682
+ colorNames = [...foregroundColorNames, ...backgroundColorNames];
1683
+ __name(assembleStyles, "assembleStyles");
1684
+ ansiStyles = assembleStyles();
1685
+ ansi_styles_default = ansiStyles;
1686
+ }
1687
+ });
1688
+
1689
+ // node_modules/.pnpm/wrap-ansi@9.0.2/node_modules/wrap-ansi/index.js
1690
+ var wrap_ansi_exports = {};
1691
+ __export(wrap_ansi_exports, {
1692
+ default: () => wrapAnsi
1693
+ });
1694
+ function wrapAnsi(string, columns, options) {
1695
+ return String(string).normalize().replaceAll("\r\n", "\n").split("\n").map((line) => exec(line, columns, options)).join("\n");
1696
+ }
1697
+ var ESCAPES, END_CODE, ANSI_ESCAPE_BELL, ANSI_CSI, ANSI_OSC, ANSI_SGR_TERMINATOR, ANSI_ESCAPE_LINK, wrapAnsiCode, wrapAnsiHyperlink, wordLengths, wrapWord, stringVisibleTrimSpacesRight, exec;
1698
+ var init_wrap_ansi = __esm({
1699
+ "node_modules/.pnpm/wrap-ansi@9.0.2/node_modules/wrap-ansi/index.js"() {
1700
+ init_string_width();
1701
+ init_strip_ansi();
1702
+ init_ansi_styles();
1703
+ ESCAPES = /* @__PURE__ */ new Set([
1704
+ "\x1B",
1705
+ "›"
1706
+ ]);
1707
+ END_CODE = 39;
1708
+ ANSI_ESCAPE_BELL = "\x07";
1709
+ ANSI_CSI = "[";
1710
+ ANSI_OSC = "]";
1711
+ ANSI_SGR_TERMINATOR = "m";
1712
+ ANSI_ESCAPE_LINK = `${ANSI_OSC}8;;`;
1713
+ wrapAnsiCode = /* @__PURE__ */ __name((code) => `${ESCAPES.values().next().value}${ANSI_CSI}${code}${ANSI_SGR_TERMINATOR}`, "wrapAnsiCode");
1714
+ wrapAnsiHyperlink = /* @__PURE__ */ __name((url) => `${ESCAPES.values().next().value}${ANSI_ESCAPE_LINK}${url}${ANSI_ESCAPE_BELL}`, "wrapAnsiHyperlink");
1715
+ wordLengths = /* @__PURE__ */ __name((string) => string.split(" ").map((character) => stringWidth(character)), "wordLengths");
1716
+ wrapWord = /* @__PURE__ */ __name((rows, word, columns) => {
1717
+ const characters = [...word];
1718
+ let isInsideEscape = false;
1719
+ let isInsideLinkEscape = false;
1720
+ let visible = stringWidth(stripAnsi(rows.at(-1)));
1721
+ for (const [index, character] of characters.entries()) {
1722
+ const characterLength = stringWidth(character);
1723
+ if (visible + characterLength <= columns) {
1724
+ rows[rows.length - 1] += character;
1725
+ } else {
1726
+ rows.push(character);
1727
+ visible = 0;
1728
+ }
1729
+ if (ESCAPES.has(character)) {
1730
+ isInsideEscape = true;
1731
+ const ansiEscapeLinkCandidate = characters.slice(index + 1, index + 1 + ANSI_ESCAPE_LINK.length).join("");
1732
+ isInsideLinkEscape = ansiEscapeLinkCandidate === ANSI_ESCAPE_LINK;
1733
+ }
1734
+ if (isInsideEscape) {
1735
+ if (isInsideLinkEscape) {
1736
+ if (character === ANSI_ESCAPE_BELL) {
1737
+ isInsideEscape = false;
1738
+ isInsideLinkEscape = false;
1739
+ }
1740
+ } else if (character === ANSI_SGR_TERMINATOR) {
1741
+ isInsideEscape = false;
1742
+ }
1743
+ continue;
1744
+ }
1745
+ visible += characterLength;
1746
+ if (visible === columns && index < characters.length - 1) {
1747
+ rows.push("");
1748
+ visible = 0;
1749
+ }
1750
+ }
1751
+ if (!visible && rows.at(-1).length > 0 && rows.length > 1) {
1752
+ rows[rows.length - 2] += rows.pop();
1753
+ }
1754
+ }, "wrapWord");
1755
+ stringVisibleTrimSpacesRight = /* @__PURE__ */ __name((string) => {
1756
+ const words = string.split(" ");
1757
+ let last = words.length;
1758
+ while (last > 0) {
1759
+ if (stringWidth(words[last - 1]) > 0) {
1760
+ break;
1761
+ }
1762
+ last--;
1763
+ }
1764
+ if (last === words.length) {
1765
+ return string;
1766
+ }
1767
+ return words.slice(0, last).join(" ") + words.slice(last).join("");
1768
+ }, "stringVisibleTrimSpacesRight");
1769
+ exec = /* @__PURE__ */ __name((string, columns, options = {}) => {
1770
+ if (options.trim !== false && string.trim() === "") {
1771
+ return "";
1772
+ }
1773
+ let returnValue = "";
1774
+ let escapeCode;
1775
+ let escapeUrl;
1776
+ const lengths = wordLengths(string);
1777
+ let rows = [""];
1778
+ for (const [index, word] of string.split(" ").entries()) {
1779
+ if (options.trim !== false) {
1780
+ rows[rows.length - 1] = rows.at(-1).trimStart();
1781
+ }
1782
+ let rowLength = stringWidth(rows.at(-1));
1783
+ if (index !== 0) {
1784
+ if (rowLength >= columns && (options.wordWrap === false || options.trim === false)) {
1785
+ rows.push("");
1786
+ rowLength = 0;
1787
+ }
1788
+ if (rowLength > 0 || options.trim === false) {
1789
+ rows[rows.length - 1] += " ";
1790
+ rowLength++;
1791
+ }
1792
+ }
1793
+ if (options.hard && lengths[index] > columns) {
1794
+ const remainingColumns = columns - rowLength;
1795
+ const breaksStartingThisLine = 1 + Math.floor((lengths[index] - remainingColumns - 1) / columns);
1796
+ const breaksStartingNextLine = Math.floor((lengths[index] - 1) / columns);
1797
+ if (breaksStartingNextLine < breaksStartingThisLine) {
1798
+ rows.push("");
1799
+ }
1800
+ wrapWord(rows, word, columns);
1801
+ continue;
1802
+ }
1803
+ if (rowLength + lengths[index] > columns && rowLength > 0 && lengths[index] > 0) {
1804
+ if (options.wordWrap === false && rowLength < columns) {
1805
+ wrapWord(rows, word, columns);
1806
+ continue;
1807
+ }
1808
+ rows.push("");
1809
+ }
1810
+ if (rowLength + lengths[index] > columns && options.wordWrap === false) {
1811
+ wrapWord(rows, word, columns);
1812
+ continue;
1813
+ }
1814
+ rows[rows.length - 1] += word;
1815
+ }
1816
+ if (options.trim !== false) {
1817
+ rows = rows.map((row) => stringVisibleTrimSpacesRight(row));
1818
+ }
1819
+ const preString = rows.join("\n");
1820
+ const pre = [...preString];
1821
+ let preStringIndex = 0;
1822
+ for (const [index, character] of pre.entries()) {
1823
+ returnValue += character;
1824
+ if (ESCAPES.has(character)) {
1825
+ const { groups } = new RegExp(`(?:\\${ANSI_CSI}(?<code>\\d+)m|\\${ANSI_ESCAPE_LINK}(?<uri>.*)${ANSI_ESCAPE_BELL})`).exec(preString.slice(preStringIndex)) || { groups: {} };
1826
+ if (groups.code !== void 0) {
1827
+ const code2 = Number.parseFloat(groups.code);
1828
+ escapeCode = code2 === END_CODE ? void 0 : code2;
1829
+ } else if (groups.uri !== void 0) {
1830
+ escapeUrl = groups.uri.length === 0 ? void 0 : groups.uri;
1831
+ }
1832
+ }
1833
+ const code = ansi_styles_default.codes.get(Number(escapeCode));
1834
+ if (pre[index + 1] === "\n") {
1835
+ if (escapeUrl) {
1836
+ returnValue += wrapAnsiHyperlink("");
1837
+ }
1838
+ if (escapeCode && code) {
1839
+ returnValue += wrapAnsiCode(code);
1840
+ }
1841
+ } else if (character === "\n") {
1842
+ if (escapeCode && code) {
1843
+ returnValue += wrapAnsiCode(escapeCode);
1844
+ }
1845
+ if (escapeUrl) {
1846
+ returnValue += wrapAnsiHyperlink(escapeUrl);
1847
+ }
1848
+ }
1849
+ preStringIndex += character.length;
1850
+ }
1851
+ return returnValue;
1852
+ }, "exec");
1853
+ __name(wrapAnsi, "wrapAnsi");
1854
+ }
1855
+ });
1856
+
1857
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/utils.js
1858
+ var require_utils = __commonJS({
1859
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/utils.js"(exports2) {
1860
+ "use strict";
1861
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
1862
+ return mod && mod.__esModule ? mod : { "default": mod };
1863
+ };
1864
+ Object.defineProperty(exports2, "__esModule", { value: true });
1865
+ exports2.breakLines = breakLines;
1866
+ exports2.readlineWidth = readlineWidth;
1867
+ var cli_width_1 = __importDefault(require_cli_width());
1868
+ var wrap_ansi_1 = __importDefault((init_wrap_ansi(), __toCommonJS(wrap_ansi_exports)));
1869
+ var hook_engine_ts_1 = require_hook_engine();
1870
+ function breakLines(content, width) {
1871
+ return content.split("\n").flatMap((line) => (0, wrap_ansi_1.default)(line, width, { trim: false, hard: true }).split("\n").map((str) => str.trimEnd())).join("\n");
1872
+ }
1873
+ __name(breakLines, "breakLines");
1874
+ function readlineWidth() {
1875
+ return (0, cli_width_1.default)({ defaultWidth: 80, output: (0, hook_engine_ts_1.readline)().output });
1876
+ }
1877
+ __name(readlineWidth, "readlineWidth");
1878
+ }
1879
+ });
1880
+
1881
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/pagination/use-pagination.js
1882
+ var require_use_pagination = __commonJS({
1883
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/pagination/use-pagination.js"(exports2) {
1884
+ "use strict";
1885
+ Object.defineProperty(exports2, "__esModule", { value: true });
1886
+ exports2.usePagination = usePagination;
1887
+ var use_ref_ts_1 = require_use_ref();
1888
+ var utils_ts_1 = require_utils();
1889
+ function usePointerPosition({ active, renderedItems, pageSize, loop }) {
1890
+ const state = (0, use_ref_ts_1.useRef)({
1891
+ lastPointer: active,
1892
+ lastActive: void 0
1893
+ });
1894
+ const { lastPointer, lastActive } = state.current;
1895
+ const middle = Math.floor(pageSize / 2);
1896
+ const renderedLength = renderedItems.reduce((acc, item) => acc + item.length, 0);
1897
+ const defaultPointerPosition = renderedItems.slice(0, active).reduce((acc, item) => acc + item.length, 0);
1898
+ let pointer = defaultPointerPosition;
1899
+ if (renderedLength > pageSize) {
1900
+ if (loop) {
1901
+ pointer = lastPointer;
1902
+ if (
1903
+ // First render, skip this logic.
1904
+ lastActive != null && // Only move the pointer down when the user moves down.
1905
+ lastActive < active && // Check user didn't move up across page boundary.
1906
+ active - lastActive < pageSize
1907
+ ) {
1908
+ pointer = Math.min(
1909
+ // Furthest allowed position for the pointer is the middle of the list
1910
+ middle,
1911
+ Math.abs(active - lastActive) === 1 ? Math.min(
1912
+ // Move the pointer at most the height of the last active item.
1913
+ lastPointer + (renderedItems[lastActive]?.length ?? 0),
1914
+ // If the user moved by one item, move the pointer to the natural position of the active item as
1915
+ // long as it doesn't move the cursor up.
1916
+ Math.max(defaultPointerPosition, lastPointer)
1917
+ ) : (
1918
+ // Otherwise, move the pointer down by the difference between the active and last active item.
1919
+ lastPointer + active - lastActive
1920
+ )
1921
+ );
1922
+ }
1923
+ } else {
1924
+ const spaceUnderActive = renderedItems.slice(active).reduce((acc, item) => acc + item.length, 0);
1925
+ pointer = spaceUnderActive < pageSize - middle ? (
1926
+ // If the active item is near the end of the list, progressively move the cursor towards the end.
1927
+ pageSize - spaceUnderActive
1928
+ ) : (
1929
+ // Otherwise, progressively move the pointer to the middle of the list.
1930
+ Math.min(defaultPointerPosition, middle)
1931
+ );
1932
+ }
1933
+ }
1934
+ state.current.lastPointer = pointer;
1935
+ state.current.lastActive = active;
1936
+ return pointer;
1937
+ }
1938
+ __name(usePointerPosition, "usePointerPosition");
1939
+ function usePagination({ items, active, renderItem, pageSize, loop = true }) {
1940
+ const width = (0, utils_ts_1.readlineWidth)();
1941
+ const bound = /* @__PURE__ */ __name((num) => (num % items.length + items.length) % items.length, "bound");
1942
+ const renderedItems = items.map((item, index) => {
1943
+ if (item == null)
1944
+ return [];
1945
+ return (0, utils_ts_1.breakLines)(renderItem({ item, index, isActive: index === active }), width).split("\n");
1946
+ });
1947
+ const renderedLength = renderedItems.reduce((acc, item) => acc + item.length, 0);
1948
+ const renderItemAtIndex = /* @__PURE__ */ __name((index) => renderedItems[index] ?? [], "renderItemAtIndex");
1949
+ const pointer = usePointerPosition({ active, renderedItems, pageSize, loop });
1950
+ const activeItem = renderItemAtIndex(active).slice(0, pageSize);
1951
+ const activeItemPosition = pointer + activeItem.length <= pageSize ? pointer : pageSize - activeItem.length;
1952
+ const pageBuffer = Array.from({ length: pageSize });
1953
+ pageBuffer.splice(activeItemPosition, activeItem.length, ...activeItem);
1954
+ const itemVisited = /* @__PURE__ */ new Set([active]);
1955
+ let bufferPointer = activeItemPosition + activeItem.length;
1956
+ let itemPointer = bound(active + 1);
1957
+ while (bufferPointer < pageSize && !itemVisited.has(itemPointer) && (loop && renderedLength > pageSize ? itemPointer !== active : itemPointer > active)) {
1958
+ const lines = renderItemAtIndex(itemPointer);
1959
+ const linesToAdd = lines.slice(0, pageSize - bufferPointer);
1960
+ pageBuffer.splice(bufferPointer, linesToAdd.length, ...linesToAdd);
1961
+ itemVisited.add(itemPointer);
1962
+ bufferPointer += linesToAdd.length;
1963
+ itemPointer = bound(itemPointer + 1);
1964
+ }
1965
+ bufferPointer = activeItemPosition - 1;
1966
+ itemPointer = bound(active - 1);
1967
+ while (bufferPointer >= 0 && !itemVisited.has(itemPointer) && (loop && renderedLength > pageSize ? itemPointer !== active : itemPointer < active)) {
1968
+ const lines = renderItemAtIndex(itemPointer);
1969
+ const linesToAdd = lines.slice(Math.max(0, lines.length - bufferPointer - 1));
1970
+ pageBuffer.splice(bufferPointer - linesToAdd.length + 1, linesToAdd.length, ...linesToAdd);
1971
+ itemVisited.add(itemPointer);
1972
+ bufferPointer -= linesToAdd.length;
1973
+ itemPointer = bound(itemPointer - 1);
1974
+ }
1975
+ return pageBuffer.filter((line) => typeof line === "string").join("\n");
1976
+ }
1977
+ __name(usePagination, "usePagination");
1978
+ }
1979
+ });
1980
+
1981
+ // node_modules/.pnpm/mute-stream@3.0.0/node_modules/mute-stream/lib/index.js
1982
+ var require_lib = __commonJS({
1983
+ "node_modules/.pnpm/mute-stream@3.0.0/node_modules/mute-stream/lib/index.js"(exports2, module2) {
1984
+ var Stream = require("stream");
1985
+ var MuteStream = class extends Stream {
1986
+ static {
1987
+ __name(this, "MuteStream");
1988
+ }
1989
+ #isTTY = null;
1990
+ constructor(opts = {}) {
1991
+ super(opts);
1992
+ this.writable = this.readable = true;
1993
+ this.muted = false;
1994
+ this.on("pipe", this._onpipe);
1995
+ this.replace = opts.replace;
1996
+ this._prompt = opts.prompt || null;
1997
+ this._hadControl = false;
1998
+ }
1999
+ #destSrc(key, def) {
2000
+ if (this._dest) {
2001
+ return this._dest[key];
2002
+ }
2003
+ if (this._src) {
2004
+ return this._src[key];
2005
+ }
2006
+ return def;
2007
+ }
2008
+ #proxy(method, ...args) {
2009
+ if (typeof this._dest?.[method] === "function") {
2010
+ this._dest[method](...args);
2011
+ }
2012
+ if (typeof this._src?.[method] === "function") {
2013
+ this._src[method](...args);
2014
+ }
2015
+ }
2016
+ get isTTY() {
2017
+ if (this.#isTTY !== null) {
2018
+ return this.#isTTY;
2019
+ }
2020
+ return this.#destSrc("isTTY", false);
2021
+ }
2022
+ // basically just get replace the getter/setter with a regular value
2023
+ set isTTY(val) {
2024
+ this.#isTTY = val;
2025
+ }
2026
+ get rows() {
2027
+ return this.#destSrc("rows");
2028
+ }
2029
+ get columns() {
2030
+ return this.#destSrc("columns");
2031
+ }
2032
+ mute() {
2033
+ this.muted = true;
2034
+ }
2035
+ unmute() {
2036
+ this.muted = false;
2037
+ }
2038
+ _onpipe(src) {
2039
+ this._src = src;
2040
+ }
2041
+ pipe(dest, options) {
2042
+ this._dest = dest;
2043
+ return super.pipe(dest, options);
2044
+ }
2045
+ pause() {
2046
+ if (this._src) {
2047
+ return this._src.pause();
2048
+ }
2049
+ }
2050
+ resume() {
2051
+ if (this._src) {
2052
+ return this._src.resume();
2053
+ }
2054
+ }
2055
+ write(c) {
2056
+ if (this.muted) {
2057
+ if (!this.replace) {
2058
+ return true;
2059
+ }
2060
+ if (c.match(/^\u001b/)) {
2061
+ if (c.indexOf(this._prompt) === 0) {
2062
+ c = c.slice(this._prompt.length);
2063
+ c = c.replace(/./g, this.replace);
2064
+ c = this._prompt + c;
2065
+ }
2066
+ this._hadControl = true;
2067
+ return this.emit("data", c);
2068
+ } else {
2069
+ if (this._prompt && this._hadControl && c.indexOf(this._prompt) === 0) {
2070
+ this._hadControl = false;
2071
+ this.emit("data", this._prompt);
2072
+ c = c.slice(this._prompt.length);
2073
+ }
2074
+ c = c.toString().replace(/./g, this.replace);
2075
+ }
2076
+ }
2077
+ this.emit("data", c);
2078
+ }
2079
+ end(c) {
2080
+ if (this.muted) {
2081
+ if (c && this.replace) {
2082
+ c = c.toString().replace(/./g, this.replace);
2083
+ } else {
2084
+ c = null;
2085
+ }
2086
+ }
2087
+ if (c) {
2088
+ this.emit("data", c);
2089
+ }
2090
+ this.emit("end");
2091
+ }
2092
+ destroy(...args) {
2093
+ return this.#proxy("destroy", ...args);
2094
+ }
2095
+ destroySoon(...args) {
2096
+ return this.#proxy("destroySoon", ...args);
2097
+ }
2098
+ close(...args) {
2099
+ return this.#proxy("close", ...args);
2100
+ }
2101
+ };
2102
+ module2.exports = MuteStream;
2103
+ }
2104
+ });
2105
+
2106
+ // node_modules/.pnpm/@inquirer+ansi@1.0.2/node_modules/@inquirer/ansi/dist/commonjs/index.js
2107
+ var require_commonjs2 = __commonJS({
2108
+ "node_modules/.pnpm/@inquirer+ansi@1.0.2/node_modules/@inquirer/ansi/dist/commonjs/index.js"(exports2) {
2109
+ "use strict";
2110
+ Object.defineProperty(exports2, "__esModule", { value: true });
2111
+ exports2.eraseLines = exports2.cursorTo = exports2.cursorDown = exports2.cursorUp = exports2.cursorShow = exports2.cursorHide = exports2.cursorLeft = void 0;
2112
+ var ESC = "\x1B[";
2113
+ exports2.cursorLeft = ESC + "G";
2114
+ exports2.cursorHide = ESC + "?25l";
2115
+ exports2.cursorShow = ESC + "?25h";
2116
+ var cursorUp = /* @__PURE__ */ __name((rows = 1) => rows > 0 ? `${ESC}${rows}A` : "", "cursorUp");
2117
+ exports2.cursorUp = cursorUp;
2118
+ var cursorDown = /* @__PURE__ */ __name((rows = 1) => rows > 0 ? `${ESC}${rows}B` : "", "cursorDown");
2119
+ exports2.cursorDown = cursorDown;
2120
+ var cursorTo = /* @__PURE__ */ __name((x, y) => {
2121
+ if (typeof y === "number" && !Number.isNaN(y)) {
2122
+ return `${ESC}${y + 1};${x + 1}H`;
2123
+ }
2124
+ return `${ESC}${x + 1}G`;
2125
+ }, "cursorTo");
2126
+ exports2.cursorTo = cursorTo;
2127
+ var eraseLine = ESC + "2K";
2128
+ var eraseLines = /* @__PURE__ */ __name((lines) => lines > 0 ? (eraseLine + (0, exports2.cursorUp)(1)).repeat(lines - 1) + eraseLine + exports2.cursorLeft : "", "eraseLines");
2129
+ exports2.eraseLines = eraseLines;
2130
+ }
2131
+ });
2132
+
2133
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/screen-manager.js
2134
+ var require_screen_manager = __commonJS({
2135
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/screen-manager.js"(exports2) {
2136
+ "use strict";
2137
+ Object.defineProperty(exports2, "__esModule", { value: true });
2138
+ var node_util_1 = require("node:util");
2139
+ var utils_ts_1 = require_utils();
2140
+ var ansi_1 = require_commonjs2();
2141
+ var height = /* @__PURE__ */ __name((content) => content.split("\n").length, "height");
2142
+ var lastLine = /* @__PURE__ */ __name((content) => content.split("\n").pop() ?? "", "lastLine");
2143
+ var ScreenManager = class {
2144
+ static {
2145
+ __name(this, "ScreenManager");
2146
+ }
2147
+ // These variables are keeping information to allow correct prompt re-rendering
2148
+ height = 0;
2149
+ extraLinesUnderPrompt = 0;
2150
+ cursorPos;
2151
+ rl;
2152
+ constructor(rl) {
2153
+ this.rl = rl;
2154
+ this.cursorPos = rl.getCursorPos();
2155
+ }
2156
+ write(content) {
2157
+ this.rl.output.unmute();
2158
+ this.rl.output.write(content);
2159
+ this.rl.output.mute();
2160
+ }
2161
+ render(content, bottomContent = "") {
2162
+ const promptLine = lastLine(content);
2163
+ const rawPromptLine = (0, node_util_1.stripVTControlCharacters)(promptLine);
2164
+ let prompt = rawPromptLine;
2165
+ if (this.rl.line.length > 0) {
2166
+ prompt = prompt.slice(0, -this.rl.line.length);
2167
+ }
2168
+ this.rl.setPrompt(prompt);
2169
+ this.cursorPos = this.rl.getCursorPos();
2170
+ const width = (0, utils_ts_1.readlineWidth)();
2171
+ content = (0, utils_ts_1.breakLines)(content, width);
2172
+ bottomContent = (0, utils_ts_1.breakLines)(bottomContent, width);
2173
+ if (rawPromptLine.length % width === 0) {
2174
+ content += "\n";
2175
+ }
2176
+ let output = content + (bottomContent ? "\n" + bottomContent : "");
2177
+ const promptLineUpDiff = Math.floor(rawPromptLine.length / width) - this.cursorPos.rows;
2178
+ const bottomContentHeight = promptLineUpDiff + (bottomContent ? height(bottomContent) : 0);
2179
+ if (bottomContentHeight > 0)
2180
+ output += (0, ansi_1.cursorUp)(bottomContentHeight);
2181
+ output += (0, ansi_1.cursorTo)(this.cursorPos.cols);
2182
+ this.write((0, ansi_1.cursorDown)(this.extraLinesUnderPrompt) + (0, ansi_1.eraseLines)(this.height) + output);
2183
+ this.extraLinesUnderPrompt = bottomContentHeight;
2184
+ this.height = height(output);
2185
+ }
2186
+ checkCursorPos() {
2187
+ const cursorPos = this.rl.getCursorPos();
2188
+ if (cursorPos.cols !== this.cursorPos.cols) {
2189
+ this.write((0, ansi_1.cursorTo)(cursorPos.cols));
2190
+ this.cursorPos = cursorPos;
2191
+ }
2192
+ }
2193
+ done({ clearContent }) {
2194
+ this.rl.setPrompt("");
2195
+ let output = (0, ansi_1.cursorDown)(this.extraLinesUnderPrompt);
2196
+ output += clearContent ? (0, ansi_1.eraseLines)(this.height) : "\n";
2197
+ output += ansi_1.cursorShow;
2198
+ this.write(output);
2199
+ this.rl.close();
2200
+ }
2201
+ };
2202
+ exports2.default = ScreenManager;
2203
+ }
2204
+ });
2205
+
2206
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/promise-polyfill.js
2207
+ var require_promise_polyfill = __commonJS({
2208
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/promise-polyfill.js"(exports2) {
2209
+ "use strict";
2210
+ Object.defineProperty(exports2, "__esModule", { value: true });
2211
+ exports2.PromisePolyfill = void 0;
2212
+ var PromisePolyfill = class extends Promise {
2213
+ static {
2214
+ __name(this, "PromisePolyfill");
2215
+ }
2216
+ // Available starting from Node 22
2217
+ // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/withResolvers
2218
+ static withResolver() {
2219
+ let resolve;
2220
+ let reject;
2221
+ const promise = new Promise((res, rej) => {
2222
+ resolve = res;
2223
+ reject = rej;
2224
+ });
2225
+ return { promise, resolve, reject };
2226
+ }
2227
+ };
2228
+ exports2.PromisePolyfill = PromisePolyfill;
2229
+ }
2230
+ });
2231
+
2232
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/create-prompt.js
2233
+ var require_create_prompt = __commonJS({
2234
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/create-prompt.js"(exports2) {
2235
+ "use strict";
2236
+ var __createBinding = exports2 && exports2.__createBinding || (Object.create ? (function(o, m, k, k2) {
2237
+ if (k2 === void 0) k2 = k;
2238
+ var desc = Object.getOwnPropertyDescriptor(m, k);
2239
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
2240
+ desc = { enumerable: true, get: /* @__PURE__ */ __name(function() {
2241
+ return m[k];
2242
+ }, "get") };
2243
+ }
2244
+ Object.defineProperty(o, k2, desc);
2245
+ }) : (function(o, m, k, k2) {
2246
+ if (k2 === void 0) k2 = k;
2247
+ o[k2] = m[k];
2248
+ }));
2249
+ var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? (function(o, v) {
2250
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
2251
+ }) : function(o, v) {
2252
+ o["default"] = v;
2253
+ });
2254
+ var __importStar = exports2 && exports2.__importStar || /* @__PURE__ */ (function() {
2255
+ var ownKeys = /* @__PURE__ */ __name(function(o) {
2256
+ ownKeys = Object.getOwnPropertyNames || function(o2) {
2257
+ var ar = [];
2258
+ for (var k in o2) if (Object.prototype.hasOwnProperty.call(o2, k)) ar[ar.length] = k;
2259
+ return ar;
2260
+ };
2261
+ return ownKeys(o);
2262
+ }, "ownKeys");
2263
+ return function(mod) {
2264
+ if (mod && mod.__esModule) return mod;
2265
+ var result = {};
2266
+ if (mod != null) {
2267
+ for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
2268
+ }
2269
+ __setModuleDefault(result, mod);
2270
+ return result;
2271
+ };
2272
+ })();
2273
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
2274
+ return mod && mod.__esModule ? mod : { "default": mod };
2275
+ };
2276
+ Object.defineProperty(exports2, "__esModule", { value: true });
2277
+ exports2.createPrompt = createPrompt;
2278
+ var readline = __importStar(require("node:readline"));
2279
+ var node_async_hooks_1 = require("node:async_hooks");
2280
+ var mute_stream_1 = __importDefault(require_lib());
2281
+ var signal_exit_1 = require_cjs();
2282
+ var screen_manager_ts_1 = __importDefault(require_screen_manager());
2283
+ var promise_polyfill_ts_1 = require_promise_polyfill();
2284
+ var hook_engine_ts_1 = require_hook_engine();
2285
+ var errors_ts_1 = require_errors();
2286
+ function getCallSites() {
2287
+ const _prepareStackTrace = Error.prepareStackTrace;
2288
+ let result = [];
2289
+ try {
2290
+ Error.prepareStackTrace = (_, callSites) => {
2291
+ const callSitesWithoutCurrent = callSites.slice(1);
2292
+ result = callSitesWithoutCurrent;
2293
+ return callSitesWithoutCurrent;
2294
+ };
2295
+ new Error().stack;
2296
+ } catch {
2297
+ return result;
2298
+ }
2299
+ Error.prepareStackTrace = _prepareStackTrace;
2300
+ return result;
2301
+ }
2302
+ __name(getCallSites, "getCallSites");
2303
+ function createPrompt(view) {
2304
+ const callSites = getCallSites();
2305
+ const prompt = /* @__PURE__ */ __name((config, context = {}) => {
2306
+ const { input: input2 = process.stdin, signal } = context;
2307
+ const cleanups = /* @__PURE__ */ new Set();
2308
+ const output = new mute_stream_1.default();
2309
+ output.pipe(context.output ?? process.stdout);
2310
+ const rl = readline.createInterface({
2311
+ terminal: true,
2312
+ input: input2,
2313
+ output
2314
+ });
2315
+ const screen = new screen_manager_ts_1.default(rl);
2316
+ const { promise, resolve, reject } = promise_polyfill_ts_1.PromisePolyfill.withResolver();
2317
+ const cancel = /* @__PURE__ */ __name(() => reject(new errors_ts_1.CancelPromptError()), "cancel");
2318
+ if (signal) {
2319
+ const abort = /* @__PURE__ */ __name(() => reject(new errors_ts_1.AbortPromptError({ cause: signal.reason })), "abort");
2320
+ if (signal.aborted) {
2321
+ abort();
2322
+ return Object.assign(promise, { cancel });
2323
+ }
2324
+ signal.addEventListener("abort", abort);
2325
+ cleanups.add(() => signal.removeEventListener("abort", abort));
2326
+ }
2327
+ cleanups.add((0, signal_exit_1.onExit)((code, signal2) => {
2328
+ reject(new errors_ts_1.ExitPromptError(`User force closed the prompt with ${code} ${signal2}`));
2329
+ }));
2330
+ const sigint = /* @__PURE__ */ __name(() => reject(new errors_ts_1.ExitPromptError(`User force closed the prompt with SIGINT`)), "sigint");
2331
+ rl.on("SIGINT", sigint);
2332
+ cleanups.add(() => rl.removeListener("SIGINT", sigint));
2333
+ const checkCursorPos = /* @__PURE__ */ __name(() => screen.checkCursorPos(), "checkCursorPos");
2334
+ rl.input.on("keypress", checkCursorPos);
2335
+ cleanups.add(() => rl.input.removeListener("keypress", checkCursorPos));
2336
+ return (0, hook_engine_ts_1.withHooks)(rl, (cycle) => {
2337
+ const hooksCleanup = node_async_hooks_1.AsyncResource.bind(() => hook_engine_ts_1.effectScheduler.clearAll());
2338
+ rl.on("close", hooksCleanup);
2339
+ cleanups.add(() => rl.removeListener("close", hooksCleanup));
2340
+ cycle(() => {
2341
+ try {
2342
+ const nextView = view(config, (value) => {
2343
+ setImmediate(() => resolve(value));
2344
+ });
2345
+ if (nextView === void 0) {
2346
+ const callerFilename = callSites[1]?.getFileName();
2347
+ throw new Error(`Prompt functions must return a string.
2348
+ at ${callerFilename}`);
2349
+ }
2350
+ const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
2351
+ screen.render(content, bottomContent);
2352
+ hook_engine_ts_1.effectScheduler.run();
2353
+ } catch (error) {
2354
+ reject(error);
2355
+ }
2356
+ });
2357
+ return Object.assign(promise.then((answer) => {
2358
+ hook_engine_ts_1.effectScheduler.clearAll();
2359
+ return answer;
2360
+ }, (error) => {
2361
+ hook_engine_ts_1.effectScheduler.clearAll();
2362
+ throw error;
2363
+ }).finally(() => {
2364
+ cleanups.forEach((cleanup) => cleanup());
2365
+ screen.done({ clearContent: Boolean(context.clearPromptOnDone) });
2366
+ output.end();
2367
+ }).then(() => promise), { cancel });
2368
+ });
2369
+ }, "prompt");
2370
+ return prompt;
2371
+ }
2372
+ __name(createPrompt, "createPrompt");
2373
+ }
2374
+ });
2375
+
2376
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/Separator.js
2377
+ var require_Separator = __commonJS({
2378
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/Separator.js"(exports2) {
2379
+ "use strict";
2380
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
2381
+ return mod && mod.__esModule ? mod : { "default": mod };
2382
+ };
2383
+ Object.defineProperty(exports2, "__esModule", { value: true });
2384
+ exports2.Separator = void 0;
2385
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
2386
+ var figures_1 = __importDefault(require_commonjs());
2387
+ var Separator = class {
2388
+ static {
2389
+ __name(this, "Separator");
2390
+ }
2391
+ separator = yoctocolors_cjs_1.default.dim(Array.from({ length: 15 }).join(figures_1.default.line));
2392
+ type = "separator";
2393
+ constructor(separator) {
2394
+ if (separator) {
2395
+ this.separator = separator;
2396
+ }
2397
+ }
2398
+ static isSeparator(choice) {
2399
+ return Boolean(choice && typeof choice === "object" && "type" in choice && choice.type === "separator");
2400
+ }
2401
+ };
2402
+ exports2.Separator = Separator;
2403
+ }
2404
+ });
2405
+
2406
+ // node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/index.js
2407
+ var require_commonjs3 = __commonJS({
2408
+ "node_modules/.pnpm/@inquirer+core@10.3.1_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/index.js"(exports2) {
2409
+ "use strict";
2410
+ var __createBinding = exports2 && exports2.__createBinding || (Object.create ? (function(o, m, k, k2) {
2411
+ if (k2 === void 0) k2 = k;
2412
+ var desc = Object.getOwnPropertyDescriptor(m, k);
2413
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
2414
+ desc = { enumerable: true, get: /* @__PURE__ */ __name(function() {
2415
+ return m[k];
2416
+ }, "get") };
2417
+ }
2418
+ Object.defineProperty(o, k2, desc);
2419
+ }) : (function(o, m, k, k2) {
2420
+ if (k2 === void 0) k2 = k;
2421
+ o[k2] = m[k];
2422
+ }));
2423
+ var __exportStar = exports2 && exports2.__exportStar || function(m, exports3) {
2424
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports3, p)) __createBinding(exports3, m, p);
2425
+ };
2426
+ Object.defineProperty(exports2, "__esModule", { value: true });
2427
+ exports2.Separator = exports2.createPrompt = exports2.usePagination = exports2.makeTheme = exports2.useKeypress = exports2.useRef = exports2.useMemo = exports2.useEffect = exports2.useState = exports2.usePrefix = exports2.isEnterKey = exports2.isNumberKey = exports2.isTabKey = exports2.isBackspaceKey = exports2.isSpaceKey = exports2.isDownKey = exports2.isUpKey = void 0;
2428
+ var key_ts_1 = require_key();
2429
+ Object.defineProperty(exports2, "isUpKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2430
+ return key_ts_1.isUpKey;
2431
+ }, "get") });
2432
+ Object.defineProperty(exports2, "isDownKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2433
+ return key_ts_1.isDownKey;
2434
+ }, "get") });
2435
+ Object.defineProperty(exports2, "isSpaceKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2436
+ return key_ts_1.isSpaceKey;
2437
+ }, "get") });
2438
+ Object.defineProperty(exports2, "isBackspaceKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2439
+ return key_ts_1.isBackspaceKey;
2440
+ }, "get") });
2441
+ Object.defineProperty(exports2, "isTabKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2442
+ return key_ts_1.isTabKey;
2443
+ }, "get") });
2444
+ Object.defineProperty(exports2, "isNumberKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2445
+ return key_ts_1.isNumberKey;
2446
+ }, "get") });
2447
+ Object.defineProperty(exports2, "isEnterKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2448
+ return key_ts_1.isEnterKey;
2449
+ }, "get") });
2450
+ __exportStar(require_errors(), exports2);
2451
+ var use_prefix_ts_1 = require_use_prefix();
2452
+ Object.defineProperty(exports2, "usePrefix", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2453
+ return use_prefix_ts_1.usePrefix;
2454
+ }, "get") });
2455
+ var use_state_ts_1 = require_use_state();
2456
+ Object.defineProperty(exports2, "useState", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2457
+ return use_state_ts_1.useState;
2458
+ }, "get") });
2459
+ var use_effect_ts_1 = require_use_effect();
2460
+ Object.defineProperty(exports2, "useEffect", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2461
+ return use_effect_ts_1.useEffect;
2462
+ }, "get") });
2463
+ var use_memo_ts_1 = require_use_memo();
2464
+ Object.defineProperty(exports2, "useMemo", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2465
+ return use_memo_ts_1.useMemo;
2466
+ }, "get") });
2467
+ var use_ref_ts_1 = require_use_ref();
2468
+ Object.defineProperty(exports2, "useRef", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2469
+ return use_ref_ts_1.useRef;
2470
+ }, "get") });
2471
+ var use_keypress_ts_1 = require_use_keypress();
2472
+ Object.defineProperty(exports2, "useKeypress", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2473
+ return use_keypress_ts_1.useKeypress;
2474
+ }, "get") });
2475
+ var make_theme_ts_1 = require_make_theme();
2476
+ Object.defineProperty(exports2, "makeTheme", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2477
+ return make_theme_ts_1.makeTheme;
2478
+ }, "get") });
2479
+ var use_pagination_ts_1 = require_use_pagination();
2480
+ Object.defineProperty(exports2, "usePagination", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2481
+ return use_pagination_ts_1.usePagination;
2482
+ }, "get") });
2483
+ var create_prompt_ts_1 = require_create_prompt();
2484
+ Object.defineProperty(exports2, "createPrompt", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2485
+ return create_prompt_ts_1.createPrompt;
2486
+ }, "get") });
2487
+ var Separator_ts_1 = require_Separator();
2488
+ Object.defineProperty(exports2, "Separator", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2489
+ return Separator_ts_1.Separator;
2490
+ }, "get") });
2491
+ }
2492
+ });
2493
+
2494
+ // node_modules/.pnpm/@inquirer+checkbox@4.3.1_@types+node@24.9.2/node_modules/@inquirer/checkbox/dist/commonjs/index.js
2495
+ var require_commonjs4 = __commonJS({
2496
+ "node_modules/.pnpm/@inquirer+checkbox@4.3.1_@types+node@24.9.2/node_modules/@inquirer/checkbox/dist/commonjs/index.js"(exports2) {
2497
+ "use strict";
2498
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
2499
+ return mod && mod.__esModule ? mod : { "default": mod };
2500
+ };
2501
+ Object.defineProperty(exports2, "__esModule", { value: true });
2502
+ exports2.Separator = void 0;
2503
+ var core_1 = require_commonjs3();
2504
+ var ansi_1 = require_commonjs2();
2505
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
2506
+ var figures_1 = __importDefault(require_commonjs());
2507
+ var checkboxTheme = {
2508
+ icon: {
2509
+ checked: yoctocolors_cjs_1.default.green(figures_1.default.circleFilled),
2510
+ unchecked: figures_1.default.circle,
2511
+ cursor: figures_1.default.pointer
2512
+ },
2513
+ style: {
2514
+ disabledChoice: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.dim(`- ${text}`), "disabledChoice"),
2515
+ renderSelectedChoices: /* @__PURE__ */ __name((selectedChoices) => selectedChoices.map((choice) => choice.short).join(", "), "renderSelectedChoices"),
2516
+ description: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(text), "description"),
2517
+ keysHelpTip: /* @__PURE__ */ __name((keys) => keys.map(([key, action]) => `${yoctocolors_cjs_1.default.bold(key)} ${yoctocolors_cjs_1.default.dim(action)}`).join(yoctocolors_cjs_1.default.dim(" • ")), "keysHelpTip")
2518
+ },
2519
+ helpMode: "always",
2520
+ keybindings: []
2521
+ };
2522
+ function isSelectable(item) {
2523
+ return !core_1.Separator.isSeparator(item) && !item.disabled;
2524
+ }
2525
+ __name(isSelectable, "isSelectable");
2526
+ function isChecked(item) {
2527
+ return isSelectable(item) && item.checked;
2528
+ }
2529
+ __name(isChecked, "isChecked");
2530
+ function toggle(item) {
2531
+ return isSelectable(item) ? { ...item, checked: !item.checked } : item;
2532
+ }
2533
+ __name(toggle, "toggle");
2534
+ function check(checked) {
2535
+ return function(item) {
2536
+ return isSelectable(item) ? { ...item, checked } : item;
2537
+ };
2538
+ }
2539
+ __name(check, "check");
2540
+ function normalizeChoices(choices) {
2541
+ return choices.map((choice) => {
2542
+ if (core_1.Separator.isSeparator(choice))
2543
+ return choice;
2544
+ if (typeof choice === "string") {
2545
+ return {
2546
+ value: choice,
2547
+ name: choice,
2548
+ short: choice,
2549
+ checkedName: choice,
2550
+ disabled: false,
2551
+ checked: false
2552
+ };
2553
+ }
2554
+ const name = choice.name ?? String(choice.value);
2555
+ const normalizedChoice = {
2556
+ value: choice.value,
2557
+ name,
2558
+ short: choice.short ?? name,
2559
+ checkedName: choice.checkedName ?? name,
2560
+ disabled: choice.disabled ?? false,
2561
+ checked: choice.checked ?? false
2562
+ };
2563
+ if (choice.description) {
2564
+ normalizedChoice.description = choice.description;
2565
+ }
2566
+ return normalizedChoice;
2567
+ });
2568
+ }
2569
+ __name(normalizeChoices, "normalizeChoices");
2570
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
2571
+ const {
2572
+ // eslint-disable-next-line @typescript-eslint/no-deprecated
2573
+ instructions,
2574
+ pageSize = 7,
2575
+ loop = true,
2576
+ required,
2577
+ validate: validate2 = /* @__PURE__ */ __name(() => true, "validate")
2578
+ } = config;
2579
+ const shortcuts = { all: "a", invert: "i", ...config.shortcuts };
2580
+ const theme = (0, core_1.makeTheme)(checkboxTheme, config.theme);
2581
+ const { keybindings } = theme;
2582
+ const [status, setStatus] = (0, core_1.useState)("idle");
2583
+ const prefix = (0, core_1.usePrefix)({ status, theme });
2584
+ const [items, setItems] = (0, core_1.useState)(normalizeChoices(config.choices));
2585
+ const bounds = (0, core_1.useMemo)(() => {
2586
+ const first = items.findIndex(isSelectable);
2587
+ const last = items.findLastIndex(isSelectable);
2588
+ if (first === -1) {
2589
+ throw new core_1.ValidationError("[checkbox prompt] No selectable choices. All choices are disabled.");
2590
+ }
2591
+ return { first, last };
2592
+ }, [items]);
2593
+ const [active, setActive] = (0, core_1.useState)(bounds.first);
2594
+ const [errorMsg, setError] = (0, core_1.useState)();
2595
+ (0, core_1.useKeypress)(async (key) => {
2596
+ if ((0, core_1.isEnterKey)(key)) {
2597
+ const selection = items.filter(isChecked);
2598
+ const isValid = await validate2([...selection]);
2599
+ if (required && !items.some(isChecked)) {
2600
+ setError("At least one choice must be selected");
2601
+ } else if (isValid === true) {
2602
+ setStatus("done");
2603
+ done(selection.map((choice) => choice.value));
2604
+ } else {
2605
+ setError(isValid || "You must select a valid value");
2606
+ }
2607
+ } else if ((0, core_1.isUpKey)(key, keybindings) || (0, core_1.isDownKey)(key, keybindings)) {
2608
+ if (loop || (0, core_1.isUpKey)(key, keybindings) && active !== bounds.first || (0, core_1.isDownKey)(key, keybindings) && active !== bounds.last) {
2609
+ const offset = (0, core_1.isUpKey)(key, keybindings) ? -1 : 1;
2610
+ let next = active;
2611
+ do {
2612
+ next = (next + offset + items.length) % items.length;
2613
+ } while (!isSelectable(items[next]));
2614
+ setActive(next);
2615
+ }
2616
+ } else if ((0, core_1.isSpaceKey)(key)) {
2617
+ setError(void 0);
2618
+ setItems(items.map((choice, i) => i === active ? toggle(choice) : choice));
2619
+ } else if (key.name === shortcuts.all) {
2620
+ const selectAll = items.some((choice) => isSelectable(choice) && !choice.checked);
2621
+ setItems(items.map(check(selectAll)));
2622
+ } else if (key.name === shortcuts.invert) {
2623
+ setItems(items.map(toggle));
2624
+ } else if ((0, core_1.isNumberKey)(key)) {
2625
+ const selectedIndex = Number(key.name) - 1;
2626
+ let selectableIndex = -1;
2627
+ const position = items.findIndex((item) => {
2628
+ if (core_1.Separator.isSeparator(item))
2629
+ return false;
2630
+ selectableIndex++;
2631
+ return selectableIndex === selectedIndex;
2632
+ });
2633
+ const selectedItem = items[position];
2634
+ if (selectedItem && isSelectable(selectedItem)) {
2635
+ setActive(position);
2636
+ setItems(items.map((choice, i) => i === position ? toggle(choice) : choice));
2637
+ }
2638
+ }
2639
+ });
2640
+ const message = theme.style.message(config.message, status);
2641
+ let description;
2642
+ const page = (0, core_1.usePagination)({
2643
+ items,
2644
+ active,
2645
+ renderItem({ item, isActive }) {
2646
+ if (core_1.Separator.isSeparator(item)) {
2647
+ return ` ${item.separator}`;
2648
+ }
2649
+ if (item.disabled) {
2650
+ const disabledLabel = typeof item.disabled === "string" ? item.disabled : "(disabled)";
2651
+ return theme.style.disabledChoice(`${item.name} ${disabledLabel}`);
2652
+ }
2653
+ if (isActive) {
2654
+ description = item.description;
2655
+ }
2656
+ const checkbox2 = item.checked ? theme.icon.checked : theme.icon.unchecked;
2657
+ const name = item.checked ? item.checkedName : item.name;
2658
+ const color = isActive ? theme.style.highlight : (x) => x;
2659
+ const cursor = isActive ? theme.icon.cursor : " ";
2660
+ return color(`${cursor}${checkbox2} ${name}`);
2661
+ },
2662
+ pageSize,
2663
+ loop
2664
+ });
2665
+ if (status === "done") {
2666
+ const selection = items.filter(isChecked);
2667
+ const answer = theme.style.answer(theme.style.renderSelectedChoices(selection, items));
2668
+ return [prefix, message, answer].filter(Boolean).join(" ");
2669
+ }
2670
+ let helpLine;
2671
+ if (theme.helpMode !== "never" && instructions !== false) {
2672
+ if (typeof instructions === "string") {
2673
+ helpLine = instructions;
2674
+ } else {
2675
+ const keys = [
2676
+ ["↑↓", "navigate"],
2677
+ ["space", "select"]
2678
+ ];
2679
+ if (shortcuts.all)
2680
+ keys.push([shortcuts.all, "all"]);
2681
+ if (shortcuts.invert)
2682
+ keys.push([shortcuts.invert, "invert"]);
2683
+ keys.push(["⏎", "submit"]);
2684
+ helpLine = theme.style.keysHelpTip(keys);
2685
+ }
2686
+ }
2687
+ const lines = [
2688
+ [prefix, message].filter(Boolean).join(" "),
2689
+ page,
2690
+ " ",
2691
+ description ? theme.style.description(description) : "",
2692
+ errorMsg ? theme.style.error(errorMsg) : "",
2693
+ helpLine
2694
+ ].filter(Boolean).join("\n").trimEnd();
2695
+ return `${lines}${ansi_1.cursorHide}`;
2696
+ });
2697
+ var core_2 = require_commonjs3();
2698
+ Object.defineProperty(exports2, "Separator", { enumerable: true, get: /* @__PURE__ */ __name(function() {
2699
+ return core_2.Separator;
2700
+ }, "get") });
2701
+ }
2702
+ });
2703
+
2704
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/key.js
2705
+ var require_key2 = __commonJS({
2706
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/key.js"(exports2) {
2707
+ "use strict";
2708
+ Object.defineProperty(exports2, "__esModule", { value: true });
2709
+ exports2.isEnterKey = exports2.isNumberKey = exports2.isTabKey = exports2.isBackspaceKey = exports2.isSpaceKey = exports2.isDownKey = exports2.isUpKey = void 0;
2710
+ var isUpKey = /* @__PURE__ */ __name((key, keybindings = []) => (
2711
+ // The up key
2712
+ key.name === "up" || // Vim keybinding: hjkl keys map to left/down/up/right
2713
+ keybindings.includes("vim") && key.name === "k" || // Emacs keybinding: Ctrl+P means "previous" in Emacs navigation conventions
2714
+ keybindings.includes("emacs") && key.ctrl && key.name === "p"
2715
+ ), "isUpKey");
2716
+ exports2.isUpKey = isUpKey;
2717
+ var isDownKey = /* @__PURE__ */ __name((key, keybindings = []) => (
2718
+ // The down key
2719
+ key.name === "down" || // Vim keybinding: hjkl keys map to left/down/up/right
2720
+ keybindings.includes("vim") && key.name === "j" || // Emacs keybinding: Ctrl+N means "next" in Emacs navigation conventions
2721
+ keybindings.includes("emacs") && key.ctrl && key.name === "n"
2722
+ ), "isDownKey");
2723
+ exports2.isDownKey = isDownKey;
2724
+ var isSpaceKey = /* @__PURE__ */ __name((key) => key.name === "space", "isSpaceKey");
2725
+ exports2.isSpaceKey = isSpaceKey;
2726
+ var isBackspaceKey = /* @__PURE__ */ __name((key) => key.name === "backspace", "isBackspaceKey");
2727
+ exports2.isBackspaceKey = isBackspaceKey;
2728
+ var isTabKey = /* @__PURE__ */ __name((key) => key.name === "tab", "isTabKey");
2729
+ exports2.isTabKey = isTabKey;
2730
+ var isNumberKey = /* @__PURE__ */ __name((key) => "1234567890".includes(key.name), "isNumberKey");
2731
+ exports2.isNumberKey = isNumberKey;
2732
+ var isEnterKey = /* @__PURE__ */ __name((key) => key.name === "enter" || key.name === "return", "isEnterKey");
2733
+ exports2.isEnterKey = isEnterKey;
2734
+ }
2735
+ });
2736
+
2737
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/errors.js
2738
+ var require_errors2 = __commonJS({
2739
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/errors.js"(exports2) {
2740
+ "use strict";
2741
+ Object.defineProperty(exports2, "__esModule", { value: true });
2742
+ exports2.ValidationError = exports2.HookError = exports2.ExitPromptError = exports2.CancelPromptError = exports2.AbortPromptError = void 0;
2743
+ var AbortPromptError = class extends Error {
2744
+ static {
2745
+ __name(this, "AbortPromptError");
2746
+ }
2747
+ name = "AbortPromptError";
2748
+ message = "Prompt was aborted";
2749
+ constructor(options) {
2750
+ super();
2751
+ this.cause = options?.cause;
2752
+ }
2753
+ };
2754
+ exports2.AbortPromptError = AbortPromptError;
2755
+ var CancelPromptError = class extends Error {
2756
+ static {
2757
+ __name(this, "CancelPromptError");
2758
+ }
2759
+ name = "CancelPromptError";
2760
+ message = "Prompt was canceled";
2761
+ };
2762
+ exports2.CancelPromptError = CancelPromptError;
2763
+ var ExitPromptError = class extends Error {
2764
+ static {
2765
+ __name(this, "ExitPromptError");
2766
+ }
2767
+ name = "ExitPromptError";
2768
+ };
2769
+ exports2.ExitPromptError = ExitPromptError;
2770
+ var HookError = class extends Error {
2771
+ static {
2772
+ __name(this, "HookError");
2773
+ }
2774
+ name = "HookError";
2775
+ };
2776
+ exports2.HookError = HookError;
2777
+ var ValidationError = class extends Error {
2778
+ static {
2779
+ __name(this, "ValidationError");
2780
+ }
2781
+ name = "ValidationError";
2782
+ };
2783
+ exports2.ValidationError = ValidationError;
2784
+ }
2785
+ });
2786
+
2787
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/hook-engine.js
2788
+ var require_hook_engine2 = __commonJS({
2789
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/hook-engine.js"(exports2) {
2790
+ "use strict";
2791
+ Object.defineProperty(exports2, "__esModule", { value: true });
2792
+ exports2.effectScheduler = void 0;
2793
+ exports2.withHooks = withHooks;
2794
+ exports2.readline = readline;
2795
+ exports2.withUpdates = withUpdates;
2796
+ exports2.withPointer = withPointer;
2797
+ exports2.handleChange = handleChange;
2798
+ var node_async_hooks_1 = require("node:async_hooks");
2799
+ var errors_ts_1 = require_errors2();
2800
+ var hookStorage = new node_async_hooks_1.AsyncLocalStorage();
2801
+ function createStore(rl) {
2802
+ const store = {
2803
+ rl,
2804
+ hooks: [],
2805
+ hooksCleanup: [],
2806
+ hooksEffect: [],
2807
+ index: 0,
2808
+ handleChange() {
2809
+ }
2810
+ };
2811
+ return store;
2812
+ }
2813
+ __name(createStore, "createStore");
2814
+ function withHooks(rl, cb) {
2815
+ const store = createStore(rl);
2816
+ return hookStorage.run(store, () => {
2817
+ function cycle(render) {
2818
+ store.handleChange = () => {
2819
+ store.index = 0;
2820
+ render();
2821
+ };
2822
+ store.handleChange();
2823
+ }
2824
+ __name(cycle, "cycle");
2825
+ return cb(cycle);
2826
+ });
2827
+ }
2828
+ __name(withHooks, "withHooks");
2829
+ function getStore() {
2830
+ const store = hookStorage.getStore();
2831
+ if (!store) {
2832
+ throw new errors_ts_1.HookError("[Inquirer] Hook functions can only be called from within a prompt");
2833
+ }
2834
+ return store;
2835
+ }
2836
+ __name(getStore, "getStore");
2837
+ function readline() {
2838
+ return getStore().rl;
2839
+ }
2840
+ __name(readline, "readline");
2841
+ function withUpdates(fn) {
2842
+ const wrapped = /* @__PURE__ */ __name((...args) => {
2843
+ const store = getStore();
2844
+ let shouldUpdate = false;
2845
+ const oldHandleChange = store.handleChange;
2846
+ store.handleChange = () => {
2847
+ shouldUpdate = true;
2848
+ };
2849
+ const returnValue = fn(...args);
2850
+ if (shouldUpdate) {
2851
+ oldHandleChange();
2852
+ }
2853
+ store.handleChange = oldHandleChange;
2854
+ return returnValue;
2855
+ }, "wrapped");
2856
+ return node_async_hooks_1.AsyncResource.bind(wrapped);
2857
+ }
2858
+ __name(withUpdates, "withUpdates");
2859
+ function withPointer(cb) {
2860
+ const store = getStore();
2861
+ const { index } = store;
2862
+ const pointer = {
2863
+ get() {
2864
+ return store.hooks[index];
2865
+ },
2866
+ set(value) {
2867
+ store.hooks[index] = value;
2868
+ },
2869
+ initialized: index in store.hooks
2870
+ };
2871
+ const returnValue = cb(pointer);
2872
+ store.index++;
2873
+ return returnValue;
2874
+ }
2875
+ __name(withPointer, "withPointer");
2876
+ function handleChange() {
2877
+ getStore().handleChange();
2878
+ }
2879
+ __name(handleChange, "handleChange");
2880
+ exports2.effectScheduler = {
2881
+ queue(cb) {
2882
+ const store = getStore();
2883
+ const { index } = store;
2884
+ store.hooksEffect.push(() => {
2885
+ store.hooksCleanup[index]?.();
2886
+ const cleanFn = cb(readline());
2887
+ if (cleanFn != null && typeof cleanFn !== "function") {
2888
+ throw new errors_ts_1.ValidationError("useEffect return value must be a cleanup function or nothing.");
2889
+ }
2890
+ store.hooksCleanup[index] = cleanFn;
2891
+ });
2892
+ },
2893
+ run() {
2894
+ const store = getStore();
2895
+ withUpdates(() => {
2896
+ store.hooksEffect.forEach((effect) => {
2897
+ effect();
2898
+ });
2899
+ store.hooksEffect.length = 0;
2900
+ })();
2901
+ },
2902
+ clearAll() {
2903
+ const store = getStore();
2904
+ store.hooksCleanup.forEach((cleanFn) => {
2905
+ cleanFn?.();
2906
+ });
2907
+ store.hooksEffect.length = 0;
2908
+ store.hooksCleanup.length = 0;
2909
+ }
2910
+ };
2911
+ }
2912
+ });
2913
+
2914
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-state.js
2915
+ var require_use_state2 = __commonJS({
2916
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-state.js"(exports2) {
2917
+ "use strict";
2918
+ Object.defineProperty(exports2, "__esModule", { value: true });
2919
+ exports2.useState = useState;
2920
+ var node_async_hooks_1 = require("node:async_hooks");
2921
+ var hook_engine_ts_1 = require_hook_engine2();
2922
+ function useState(defaultValue) {
2923
+ return (0, hook_engine_ts_1.withPointer)((pointer) => {
2924
+ const setState = node_async_hooks_1.AsyncResource.bind(/* @__PURE__ */ __name(function setState2(newValue) {
2925
+ if (pointer.get() !== newValue) {
2926
+ pointer.set(newValue);
2927
+ (0, hook_engine_ts_1.handleChange)();
2928
+ }
2929
+ }, "setState"));
2930
+ if (pointer.initialized) {
2931
+ return [pointer.get(), setState];
2932
+ }
2933
+ const value = typeof defaultValue === "function" ? defaultValue() : defaultValue;
2934
+ pointer.set(value);
2935
+ return [value, setState];
2936
+ });
2937
+ }
2938
+ __name(useState, "useState");
2939
+ }
2940
+ });
2941
+
2942
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-effect.js
2943
+ var require_use_effect2 = __commonJS({
2944
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-effect.js"(exports2) {
2945
+ "use strict";
2946
+ Object.defineProperty(exports2, "__esModule", { value: true });
2947
+ exports2.useEffect = useEffect;
2948
+ var hook_engine_ts_1 = require_hook_engine2();
2949
+ function useEffect(cb, depArray) {
2950
+ (0, hook_engine_ts_1.withPointer)((pointer) => {
2951
+ const oldDeps = pointer.get();
2952
+ const hasChanged = !Array.isArray(oldDeps) || depArray.some((dep, i) => !Object.is(dep, oldDeps[i]));
2953
+ if (hasChanged) {
2954
+ hook_engine_ts_1.effectScheduler.queue(cb);
2955
+ }
2956
+ pointer.set(depArray);
2957
+ });
2958
+ }
2959
+ __name(useEffect, "useEffect");
2960
+ }
2961
+ });
2962
+
2963
+ // node_modules/.pnpm/@inquirer+figures@1.0.14/node_modules/@inquirer/figures/dist/commonjs/index.js
2964
+ var require_commonjs5 = __commonJS({
2965
+ "node_modules/.pnpm/@inquirer+figures@1.0.14/node_modules/@inquirer/figures/dist/commonjs/index.js"(exports2) {
2966
+ "use strict";
2967
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
2968
+ return mod && mod.__esModule ? mod : { "default": mod };
2969
+ };
2970
+ Object.defineProperty(exports2, "__esModule", { value: true });
2971
+ exports2.replaceSymbols = exports2.fallbackSymbols = exports2.mainSymbols = void 0;
2972
+ var node_process_1 = __importDefault(require("node:process"));
2973
+ function isUnicodeSupported() {
2974
+ if (node_process_1.default.platform !== "win32") {
2975
+ return node_process_1.default.env["TERM"] !== "linux";
2976
+ }
2977
+ return Boolean(node_process_1.default.env["WT_SESSION"]) || // Windows Terminal
2978
+ Boolean(node_process_1.default.env["TERMINUS_SUBLIME"]) || // Terminus (<0.2.27)
2979
+ node_process_1.default.env["ConEmuTask"] === "{cmd::Cmder}" || // ConEmu and cmder
2980
+ node_process_1.default.env["TERM_PROGRAM"] === "Terminus-Sublime" || node_process_1.default.env["TERM_PROGRAM"] === "vscode" || node_process_1.default.env["TERM"] === "xterm-256color" || node_process_1.default.env["TERM"] === "alacritty" || node_process_1.default.env["TERMINAL_EMULATOR"] === "JetBrains-JediTerm";
2981
+ }
2982
+ __name(isUnicodeSupported, "isUnicodeSupported");
2983
+ var common = {
2984
+ circleQuestionMark: "(?)",
2985
+ questionMarkPrefix: "(?)",
2986
+ square: "█",
2987
+ squareDarkShade: "▓",
2988
+ squareMediumShade: "▒",
2989
+ squareLightShade: "░",
2990
+ squareTop: "▀",
2991
+ squareBottom: "▄",
2992
+ squareLeft: "▌",
2993
+ squareRight: "▐",
2994
+ squareCenter: "■",
2995
+ bullet: "●",
2996
+ dot: "․",
2997
+ ellipsis: "…",
2998
+ pointerSmall: "›",
2999
+ triangleUp: "▲",
3000
+ triangleUpSmall: "▴",
3001
+ triangleDown: "▼",
3002
+ triangleDownSmall: "▾",
3003
+ triangleLeftSmall: "◂",
3004
+ triangleRightSmall: "▸",
3005
+ home: "⌂",
3006
+ heart: "♥",
3007
+ musicNote: "♪",
3008
+ musicNoteBeamed: "♫",
3009
+ arrowUp: "↑",
3010
+ arrowDown: "↓",
3011
+ arrowLeft: "←",
3012
+ arrowRight: "→",
3013
+ arrowLeftRight: "↔",
3014
+ arrowUpDown: "↕",
3015
+ almostEqual: "≈",
3016
+ notEqual: "≠",
3017
+ lessOrEqual: "≤",
3018
+ greaterOrEqual: "≥",
3019
+ identical: "≡",
3020
+ infinity: "∞",
3021
+ subscriptZero: "₀",
3022
+ subscriptOne: "₁",
3023
+ subscriptTwo: "₂",
3024
+ subscriptThree: "₃",
3025
+ subscriptFour: "₄",
3026
+ subscriptFive: "₅",
3027
+ subscriptSix: "₆",
3028
+ subscriptSeven: "₇",
3029
+ subscriptEight: "₈",
3030
+ subscriptNine: "₉",
3031
+ oneHalf: "½",
3032
+ oneThird: "⅓",
3033
+ oneQuarter: "¼",
3034
+ oneFifth: "⅕",
3035
+ oneSixth: "⅙",
3036
+ oneEighth: "⅛",
3037
+ twoThirds: "⅔",
3038
+ twoFifths: "⅖",
3039
+ threeQuarters: "¾",
3040
+ threeFifths: "⅗",
3041
+ threeEighths: "⅜",
3042
+ fourFifths: "⅘",
3043
+ fiveSixths: "⅚",
3044
+ fiveEighths: "⅝",
3045
+ sevenEighths: "⅞",
3046
+ line: "─",
3047
+ lineBold: "━",
3048
+ lineDouble: "═",
3049
+ lineDashed0: "┄",
3050
+ lineDashed1: "┅",
3051
+ lineDashed2: "┈",
3052
+ lineDashed3: "┉",
3053
+ lineDashed4: "╌",
3054
+ lineDashed5: "╍",
3055
+ lineDashed6: "╴",
3056
+ lineDashed7: "╶",
3057
+ lineDashed8: "╸",
3058
+ lineDashed9: "╺",
3059
+ lineDashed10: "╼",
3060
+ lineDashed11: "╾",
3061
+ lineDashed12: "−",
3062
+ lineDashed13: "–",
3063
+ lineDashed14: "‐",
3064
+ lineDashed15: "⁃",
3065
+ lineVertical: "│",
3066
+ lineVerticalBold: "┃",
3067
+ lineVerticalDouble: "║",
3068
+ lineVerticalDashed0: "┆",
3069
+ lineVerticalDashed1: "┇",
3070
+ lineVerticalDashed2: "┊",
3071
+ lineVerticalDashed3: "┋",
3072
+ lineVerticalDashed4: "╎",
3073
+ lineVerticalDashed5: "╏",
3074
+ lineVerticalDashed6: "╵",
3075
+ lineVerticalDashed7: "╷",
3076
+ lineVerticalDashed8: "╹",
3077
+ lineVerticalDashed9: "╻",
3078
+ lineVerticalDashed10: "╽",
3079
+ lineVerticalDashed11: "╿",
3080
+ lineDownLeft: "┐",
3081
+ lineDownLeftArc: "╮",
3082
+ lineDownBoldLeftBold: "┓",
3083
+ lineDownBoldLeft: "┒",
3084
+ lineDownLeftBold: "┑",
3085
+ lineDownDoubleLeftDouble: "╗",
3086
+ lineDownDoubleLeft: "╖",
3087
+ lineDownLeftDouble: "╕",
3088
+ lineDownRight: "┌",
3089
+ lineDownRightArc: "╭",
3090
+ lineDownBoldRightBold: "┏",
3091
+ lineDownBoldRight: "┎",
3092
+ lineDownRightBold: "┍",
3093
+ lineDownDoubleRightDouble: "╔",
3094
+ lineDownDoubleRight: "╓",
3095
+ lineDownRightDouble: "╒",
3096
+ lineUpLeft: "┘",
3097
+ lineUpLeftArc: "╯",
3098
+ lineUpBoldLeftBold: "┛",
3099
+ lineUpBoldLeft: "┚",
3100
+ lineUpLeftBold: "┙",
3101
+ lineUpDoubleLeftDouble: "╝",
3102
+ lineUpDoubleLeft: "╜",
3103
+ lineUpLeftDouble: "╛",
3104
+ lineUpRight: "└",
3105
+ lineUpRightArc: "╰",
3106
+ lineUpBoldRightBold: "┗",
3107
+ lineUpBoldRight: "┖",
3108
+ lineUpRightBold: "┕",
3109
+ lineUpDoubleRightDouble: "╚",
3110
+ lineUpDoubleRight: "╙",
3111
+ lineUpRightDouble: "╘",
3112
+ lineUpDownLeft: "┤",
3113
+ lineUpBoldDownBoldLeftBold: "┫",
3114
+ lineUpBoldDownBoldLeft: "┨",
3115
+ lineUpDownLeftBold: "┥",
3116
+ lineUpBoldDownLeftBold: "┩",
3117
+ lineUpDownBoldLeftBold: "┪",
3118
+ lineUpDownBoldLeft: "┧",
3119
+ lineUpBoldDownLeft: "┦",
3120
+ lineUpDoubleDownDoubleLeftDouble: "╣",
3121
+ lineUpDoubleDownDoubleLeft: "╢",
3122
+ lineUpDownLeftDouble: "╡",
3123
+ lineUpDownRight: "├",
3124
+ lineUpBoldDownBoldRightBold: "┣",
3125
+ lineUpBoldDownBoldRight: "┠",
3126
+ lineUpDownRightBold: "┝",
3127
+ lineUpBoldDownRightBold: "┡",
3128
+ lineUpDownBoldRightBold: "┢",
3129
+ lineUpDownBoldRight: "┟",
3130
+ lineUpBoldDownRight: "┞",
3131
+ lineUpDoubleDownDoubleRightDouble: "╠",
3132
+ lineUpDoubleDownDoubleRight: "╟",
3133
+ lineUpDownRightDouble: "╞",
3134
+ lineDownLeftRight: "┬",
3135
+ lineDownBoldLeftBoldRightBold: "┳",
3136
+ lineDownLeftBoldRightBold: "┯",
3137
+ lineDownBoldLeftRight: "┰",
3138
+ lineDownBoldLeftBoldRight: "┱",
3139
+ lineDownBoldLeftRightBold: "┲",
3140
+ lineDownLeftRightBold: "┮",
3141
+ lineDownLeftBoldRight: "┭",
3142
+ lineDownDoubleLeftDoubleRightDouble: "╦",
3143
+ lineDownDoubleLeftRight: "╥",
3144
+ lineDownLeftDoubleRightDouble: "╤",
3145
+ lineUpLeftRight: "┴",
3146
+ lineUpBoldLeftBoldRightBold: "┻",
3147
+ lineUpLeftBoldRightBold: "┷",
3148
+ lineUpBoldLeftRight: "┸",
3149
+ lineUpBoldLeftBoldRight: "┹",
3150
+ lineUpBoldLeftRightBold: "┺",
3151
+ lineUpLeftRightBold: "┶",
3152
+ lineUpLeftBoldRight: "┵",
3153
+ lineUpDoubleLeftDoubleRightDouble: "╩",
3154
+ lineUpDoubleLeftRight: "╨",
3155
+ lineUpLeftDoubleRightDouble: "╧",
3156
+ lineUpDownLeftRight: "┼",
3157
+ lineUpBoldDownBoldLeftBoldRightBold: "╋",
3158
+ lineUpDownBoldLeftBoldRightBold: "╈",
3159
+ lineUpBoldDownLeftBoldRightBold: "╇",
3160
+ lineUpBoldDownBoldLeftRightBold: "╊",
3161
+ lineUpBoldDownBoldLeftBoldRight: "╉",
3162
+ lineUpBoldDownLeftRight: "╀",
3163
+ lineUpDownBoldLeftRight: "╁",
3164
+ lineUpDownLeftBoldRight: "┽",
3165
+ lineUpDownLeftRightBold: "┾",
3166
+ lineUpBoldDownBoldLeftRight: "╂",
3167
+ lineUpDownLeftBoldRightBold: "┿",
3168
+ lineUpBoldDownLeftBoldRight: "╃",
3169
+ lineUpBoldDownLeftRightBold: "╄",
3170
+ lineUpDownBoldLeftBoldRight: "╅",
3171
+ lineUpDownBoldLeftRightBold: "╆",
3172
+ lineUpDoubleDownDoubleLeftDoubleRightDouble: "╬",
3173
+ lineUpDoubleDownDoubleLeftRight: "╫",
3174
+ lineUpDownLeftDoubleRightDouble: "╪",
3175
+ lineCross: "╳",
3176
+ lineBackslash: "╲",
3177
+ lineSlash: "╱"
3178
+ };
3179
+ var specialMainSymbols = {
3180
+ tick: "✔",
3181
+ info: "ℹ",
3182
+ warning: "⚠",
3183
+ cross: "✘",
3184
+ squareSmall: "◻",
3185
+ squareSmallFilled: "◼",
3186
+ circle: "◯",
3187
+ circleFilled: "◉",
3188
+ circleDotted: "◌",
3189
+ circleDouble: "◎",
3190
+ circleCircle: "ⓞ",
3191
+ circleCross: "ⓧ",
3192
+ circlePipe: "Ⓘ",
3193
+ radioOn: "◉",
3194
+ radioOff: "◯",
3195
+ checkboxOn: "☒",
3196
+ checkboxOff: "☐",
3197
+ checkboxCircleOn: "ⓧ",
3198
+ checkboxCircleOff: "Ⓘ",
3199
+ pointer: "❯",
3200
+ triangleUpOutline: "△",
3201
+ triangleLeft: "◀",
3202
+ triangleRight: "▶",
3203
+ lozenge: "◆",
3204
+ lozengeOutline: "◇",
3205
+ hamburger: "☰",
3206
+ smiley: "㋡",
3207
+ mustache: "෴",
3208
+ star: "★",
3209
+ play: "▶",
3210
+ nodejs: "⬢",
3211
+ oneSeventh: "⅐",
3212
+ oneNinth: "⅑",
3213
+ oneTenth: "⅒"
3214
+ };
3215
+ var specialFallbackSymbols = {
3216
+ tick: "√",
3217
+ info: "i",
3218
+ warning: "‼",
3219
+ cross: "×",
3220
+ squareSmall: "□",
3221
+ squareSmallFilled: "■",
3222
+ circle: "( )",
3223
+ circleFilled: "(*)",
3224
+ circleDotted: "( )",
3225
+ circleDouble: "( )",
3226
+ circleCircle: "(○)",
3227
+ circleCross: "(×)",
3228
+ circlePipe: "(│)",
3229
+ radioOn: "(*)",
3230
+ radioOff: "( )",
3231
+ checkboxOn: "[×]",
3232
+ checkboxOff: "[ ]",
3233
+ checkboxCircleOn: "(×)",
3234
+ checkboxCircleOff: "( )",
3235
+ pointer: ">",
3236
+ triangleUpOutline: "∆",
3237
+ triangleLeft: "◄",
3238
+ triangleRight: "►",
3239
+ lozenge: "♦",
3240
+ lozengeOutline: "◊",
3241
+ hamburger: "≡",
3242
+ smiley: "☺",
3243
+ mustache: "┌─┐",
3244
+ star: "✶",
3245
+ play: "►",
3246
+ nodejs: "♦",
3247
+ oneSeventh: "1/7",
3248
+ oneNinth: "1/9",
3249
+ oneTenth: "1/10"
3250
+ };
3251
+ exports2.mainSymbols = { ...common, ...specialMainSymbols };
3252
+ exports2.fallbackSymbols = {
3253
+ ...common,
3254
+ ...specialFallbackSymbols
3255
+ };
3256
+ var shouldUseMain = isUnicodeSupported();
3257
+ var figures = shouldUseMain ? exports2.mainSymbols : exports2.fallbackSymbols;
3258
+ exports2.default = figures;
3259
+ var replacements = Object.entries(specialMainSymbols);
3260
+ var replaceSymbols = /* @__PURE__ */ __name((string, { useFallback = !shouldUseMain } = {}) => {
3261
+ if (useFallback) {
3262
+ for (const [key, mainSymbol] of replacements) {
3263
+ const fallbackSymbol = exports2.fallbackSymbols[key];
3264
+ if (!fallbackSymbol) {
3265
+ throw new Error(`Unable to find fallback for ${key}`);
3266
+ }
3267
+ string = string.replaceAll(mainSymbol, fallbackSymbol);
3268
+ }
3269
+ }
3270
+ return string;
3271
+ }, "replaceSymbols");
3272
+ exports2.replaceSymbols = replaceSymbols;
3273
+ }
3274
+ });
3275
+
3276
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/theme.js
3277
+ var require_theme2 = __commonJS({
3278
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/theme.js"(exports2) {
3279
+ "use strict";
3280
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
3281
+ return mod && mod.__esModule ? mod : { "default": mod };
3282
+ };
3283
+ Object.defineProperty(exports2, "__esModule", { value: true });
3284
+ exports2.defaultTheme = void 0;
3285
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
3286
+ var figures_1 = __importDefault(require_commonjs5());
3287
+ exports2.defaultTheme = {
3288
+ prefix: {
3289
+ idle: yoctocolors_cjs_1.default.blue("?"),
3290
+ // TODO: use figure
3291
+ done: yoctocolors_cjs_1.default.green(figures_1.default.tick)
3292
+ },
3293
+ spinner: {
3294
+ interval: 80,
3295
+ frames: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"].map((frame) => yoctocolors_cjs_1.default.yellow(frame))
3296
+ },
3297
+ style: {
3298
+ answer: yoctocolors_cjs_1.default.cyan,
3299
+ message: yoctocolors_cjs_1.default.bold,
3300
+ error: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.red(`> ${text}`), "error"),
3301
+ defaultAnswer: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.dim(`(${text})`), "defaultAnswer"),
3302
+ help: yoctocolors_cjs_1.default.dim,
3303
+ highlight: yoctocolors_cjs_1.default.cyan,
3304
+ key: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(yoctocolors_cjs_1.default.bold(`<${text}>`)), "key")
3305
+ }
3306
+ };
3307
+ }
3308
+ });
3309
+
3310
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/make-theme.js
3311
+ var require_make_theme2 = __commonJS({
3312
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/make-theme.js"(exports2) {
3313
+ "use strict";
3314
+ Object.defineProperty(exports2, "__esModule", { value: true });
3315
+ exports2.makeTheme = makeTheme;
3316
+ var theme_ts_1 = require_theme2();
3317
+ function isPlainObject(value) {
3318
+ if (typeof value !== "object" || value === null)
3319
+ return false;
3320
+ let proto = value;
3321
+ while (Object.getPrototypeOf(proto) !== null) {
3322
+ proto = Object.getPrototypeOf(proto);
3323
+ }
3324
+ return Object.getPrototypeOf(value) === proto;
3325
+ }
3326
+ __name(isPlainObject, "isPlainObject");
3327
+ function deepMerge(...objects) {
3328
+ const output = {};
3329
+ for (const obj of objects) {
3330
+ for (const [key, value] of Object.entries(obj)) {
3331
+ const prevValue = output[key];
3332
+ output[key] = isPlainObject(prevValue) && isPlainObject(value) ? deepMerge(prevValue, value) : value;
3333
+ }
3334
+ }
3335
+ return output;
3336
+ }
3337
+ __name(deepMerge, "deepMerge");
3338
+ function makeTheme(...themes) {
3339
+ const themesToMerge = [
3340
+ theme_ts_1.defaultTheme,
3341
+ ...themes.filter((theme) => theme != null)
3342
+ ];
3343
+ return deepMerge(...themesToMerge);
3344
+ }
3345
+ __name(makeTheme, "makeTheme");
3346
+ }
3347
+ });
3348
+
3349
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-prefix.js
3350
+ var require_use_prefix2 = __commonJS({
3351
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-prefix.js"(exports2) {
3352
+ "use strict";
3353
+ Object.defineProperty(exports2, "__esModule", { value: true });
3354
+ exports2.usePrefix = usePrefix;
3355
+ var use_state_ts_1 = require_use_state2();
3356
+ var use_effect_ts_1 = require_use_effect2();
3357
+ var make_theme_ts_1 = require_make_theme2();
3358
+ function usePrefix({ status = "idle", theme }) {
3359
+ const [showLoader, setShowLoader] = (0, use_state_ts_1.useState)(false);
3360
+ const [tick, setTick] = (0, use_state_ts_1.useState)(0);
3361
+ const { prefix, spinner } = (0, make_theme_ts_1.makeTheme)(theme);
3362
+ (0, use_effect_ts_1.useEffect)(() => {
3363
+ if (status === "loading") {
3364
+ let tickInterval;
3365
+ let inc = -1;
3366
+ const delayTimeout = setTimeout(() => {
3367
+ setShowLoader(true);
3368
+ tickInterval = setInterval(() => {
3369
+ inc = inc + 1;
3370
+ setTick(inc % spinner.frames.length);
3371
+ }, spinner.interval);
3372
+ }, 300);
3373
+ return () => {
3374
+ clearTimeout(delayTimeout);
3375
+ clearInterval(tickInterval);
3376
+ };
3377
+ } else {
3378
+ setShowLoader(false);
3379
+ }
3380
+ }, [status]);
3381
+ if (showLoader) {
3382
+ return spinner.frames[tick];
3383
+ }
3384
+ const iconName = status === "loading" ? "idle" : status;
3385
+ return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
3386
+ }
3387
+ __name(usePrefix, "usePrefix");
3388
+ }
3389
+ });
3390
+
3391
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-memo.js
3392
+ var require_use_memo2 = __commonJS({
3393
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-memo.js"(exports2) {
3394
+ "use strict";
3395
+ Object.defineProperty(exports2, "__esModule", { value: true });
3396
+ exports2.useMemo = useMemo;
3397
+ var hook_engine_ts_1 = require_hook_engine2();
3398
+ function useMemo(fn, dependencies) {
3399
+ return (0, hook_engine_ts_1.withPointer)((pointer) => {
3400
+ const prev = pointer.get();
3401
+ if (!prev || prev.dependencies.length !== dependencies.length || prev.dependencies.some((dep, i) => dep !== dependencies[i])) {
3402
+ const value = fn();
3403
+ pointer.set({ value, dependencies });
3404
+ return value;
3405
+ }
3406
+ return prev.value;
3407
+ });
3408
+ }
3409
+ __name(useMemo, "useMemo");
3410
+ }
3411
+ });
3412
+
3413
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-ref.js
3414
+ var require_use_ref2 = __commonJS({
3415
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-ref.js"(exports2) {
3416
+ "use strict";
3417
+ Object.defineProperty(exports2, "__esModule", { value: true });
3418
+ exports2.useRef = useRef;
3419
+ var use_state_ts_1 = require_use_state2();
3420
+ function useRef(val) {
3421
+ return (0, use_state_ts_1.useState)({ current: val })[0];
3422
+ }
3423
+ __name(useRef, "useRef");
3424
+ }
3425
+ });
3426
+
3427
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-keypress.js
3428
+ var require_use_keypress2 = __commonJS({
3429
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/use-keypress.js"(exports2) {
3430
+ "use strict";
3431
+ Object.defineProperty(exports2, "__esModule", { value: true });
3432
+ exports2.useKeypress = useKeypress;
3433
+ var use_ref_ts_1 = require_use_ref2();
3434
+ var use_effect_ts_1 = require_use_effect2();
3435
+ var hook_engine_ts_1 = require_hook_engine2();
3436
+ function useKeypress(userHandler) {
3437
+ const signal = (0, use_ref_ts_1.useRef)(userHandler);
3438
+ signal.current = userHandler;
3439
+ (0, use_effect_ts_1.useEffect)((rl) => {
3440
+ let ignore = false;
3441
+ const handler = (0, hook_engine_ts_1.withUpdates)((_input, event) => {
3442
+ if (ignore)
3443
+ return;
3444
+ void signal.current(event, rl);
3445
+ });
3446
+ rl.input.on("keypress", handler);
3447
+ return () => {
3448
+ ignore = true;
3449
+ rl.input.removeListener("keypress", handler);
3450
+ };
3451
+ }, []);
3452
+ }
3453
+ __name(useKeypress, "useKeypress");
3454
+ }
3455
+ });
3456
+
3457
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/utils.js
3458
+ var require_utils2 = __commonJS({
3459
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/utils.js"(exports2) {
3460
+ "use strict";
3461
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
3462
+ return mod && mod.__esModule ? mod : { "default": mod };
3463
+ };
3464
+ Object.defineProperty(exports2, "__esModule", { value: true });
3465
+ exports2.breakLines = breakLines;
3466
+ exports2.readlineWidth = readlineWidth;
3467
+ var cli_width_1 = __importDefault(require_cli_width());
3468
+ var wrap_ansi_1 = __importDefault((init_wrap_ansi(), __toCommonJS(wrap_ansi_exports)));
3469
+ var hook_engine_ts_1 = require_hook_engine2();
3470
+ function breakLines(content, width) {
3471
+ return content.split("\n").flatMap((line) => (0, wrap_ansi_1.default)(line, width, { trim: false, hard: true }).split("\n").map((str) => str.trimEnd())).join("\n");
3472
+ }
3473
+ __name(breakLines, "breakLines");
3474
+ function readlineWidth() {
3475
+ return (0, cli_width_1.default)({ defaultWidth: 80, output: (0, hook_engine_ts_1.readline)().output });
3476
+ }
3477
+ __name(readlineWidth, "readlineWidth");
3478
+ }
3479
+ });
3480
+
3481
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/pagination/use-pagination.js
3482
+ var require_use_pagination2 = __commonJS({
3483
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/pagination/use-pagination.js"(exports2) {
3484
+ "use strict";
3485
+ Object.defineProperty(exports2, "__esModule", { value: true });
3486
+ exports2.usePagination = usePagination;
3487
+ var use_ref_ts_1 = require_use_ref2();
3488
+ var utils_ts_1 = require_utils2();
3489
+ function usePointerPosition({ active, renderedItems, pageSize, loop }) {
3490
+ const state = (0, use_ref_ts_1.useRef)({
3491
+ lastPointer: active,
3492
+ lastActive: void 0
3493
+ });
3494
+ const { lastPointer, lastActive } = state.current;
3495
+ const middle = Math.floor(pageSize / 2);
3496
+ const renderedLength = renderedItems.reduce((acc, item) => acc + item.length, 0);
3497
+ const defaultPointerPosition = renderedItems.slice(0, active).reduce((acc, item) => acc + item.length, 0);
3498
+ let pointer = defaultPointerPosition;
3499
+ if (renderedLength > pageSize) {
3500
+ if (loop) {
3501
+ pointer = lastPointer;
3502
+ if (
3503
+ // First render, skip this logic.
3504
+ lastActive != null && // Only move the pointer down when the user moves down.
3505
+ lastActive < active && // Check user didn't move up across page boundary.
3506
+ active - lastActive < pageSize
3507
+ ) {
3508
+ pointer = Math.min(
3509
+ // Furthest allowed position for the pointer is the middle of the list
3510
+ middle,
3511
+ Math.abs(active - lastActive) === 1 ? Math.min(
3512
+ // Move the pointer at most the height of the last active item.
3513
+ lastPointer + (renderedItems[lastActive]?.length ?? 0),
3514
+ // If the user moved by one item, move the pointer to the natural position of the active item as
3515
+ // long as it doesn't move the cursor up.
3516
+ Math.max(defaultPointerPosition, lastPointer)
3517
+ ) : (
3518
+ // Otherwise, move the pointer down by the difference between the active and last active item.
3519
+ lastPointer + active - lastActive
3520
+ )
3521
+ );
3522
+ }
3523
+ } else {
3524
+ const spaceUnderActive = renderedItems.slice(active).reduce((acc, item) => acc + item.length, 0);
3525
+ pointer = spaceUnderActive < pageSize - middle ? (
3526
+ // If the active item is near the end of the list, progressively move the cursor towards the end.
3527
+ pageSize - spaceUnderActive
3528
+ ) : (
3529
+ // Otherwise, progressively move the pointer to the middle of the list.
3530
+ Math.min(defaultPointerPosition, middle)
3531
+ );
3532
+ }
3533
+ }
3534
+ state.current.lastPointer = pointer;
3535
+ state.current.lastActive = active;
3536
+ return pointer;
3537
+ }
3538
+ __name(usePointerPosition, "usePointerPosition");
3539
+ function usePagination({ items, active, renderItem, pageSize, loop = true }) {
3540
+ const width = (0, utils_ts_1.readlineWidth)();
3541
+ const bound = /* @__PURE__ */ __name((num) => (num % items.length + items.length) % items.length, "bound");
3542
+ const renderedItems = items.map((item, index) => {
3543
+ if (item == null)
3544
+ return [];
3545
+ return (0, utils_ts_1.breakLines)(renderItem({ item, index, isActive: index === active }), width).split("\n");
3546
+ });
3547
+ const renderedLength = renderedItems.reduce((acc, item) => acc + item.length, 0);
3548
+ const renderItemAtIndex = /* @__PURE__ */ __name((index) => renderedItems[index] ?? [], "renderItemAtIndex");
3549
+ const pointer = usePointerPosition({ active, renderedItems, pageSize, loop });
3550
+ const activeItem = renderItemAtIndex(active).slice(0, pageSize);
3551
+ const activeItemPosition = pointer + activeItem.length <= pageSize ? pointer : pageSize - activeItem.length;
3552
+ const pageBuffer = Array.from({ length: pageSize });
3553
+ pageBuffer.splice(activeItemPosition, activeItem.length, ...activeItem);
3554
+ const itemVisited = /* @__PURE__ */ new Set([active]);
3555
+ let bufferPointer = activeItemPosition + activeItem.length;
3556
+ let itemPointer = bound(active + 1);
3557
+ while (bufferPointer < pageSize && !itemVisited.has(itemPointer) && (loop && renderedLength > pageSize ? itemPointer !== active : itemPointer > active)) {
3558
+ const lines = renderItemAtIndex(itemPointer);
3559
+ const linesToAdd = lines.slice(0, pageSize - bufferPointer);
3560
+ pageBuffer.splice(bufferPointer, linesToAdd.length, ...linesToAdd);
3561
+ itemVisited.add(itemPointer);
3562
+ bufferPointer += linesToAdd.length;
3563
+ itemPointer = bound(itemPointer + 1);
3564
+ }
3565
+ bufferPointer = activeItemPosition - 1;
3566
+ itemPointer = bound(active - 1);
3567
+ while (bufferPointer >= 0 && !itemVisited.has(itemPointer) && (loop && renderedLength > pageSize ? itemPointer !== active : itemPointer < active)) {
3568
+ const lines = renderItemAtIndex(itemPointer);
3569
+ const linesToAdd = lines.slice(Math.max(0, lines.length - bufferPointer - 1));
3570
+ pageBuffer.splice(bufferPointer - linesToAdd.length + 1, linesToAdd.length, ...linesToAdd);
3571
+ itemVisited.add(itemPointer);
3572
+ bufferPointer -= linesToAdd.length;
3573
+ itemPointer = bound(itemPointer - 1);
3574
+ }
3575
+ return pageBuffer.filter((line) => typeof line === "string").join("\n");
3576
+ }
3577
+ __name(usePagination, "usePagination");
3578
+ }
3579
+ });
3580
+
3581
+ // node_modules/.pnpm/mute-stream@2.0.0/node_modules/mute-stream/lib/index.js
3582
+ var require_lib2 = __commonJS({
3583
+ "node_modules/.pnpm/mute-stream@2.0.0/node_modules/mute-stream/lib/index.js"(exports2, module2) {
3584
+ var Stream = require("stream");
3585
+ var MuteStream = class extends Stream {
3586
+ static {
3587
+ __name(this, "MuteStream");
3588
+ }
3589
+ #isTTY = null;
3590
+ constructor(opts = {}) {
3591
+ super(opts);
3592
+ this.writable = this.readable = true;
3593
+ this.muted = false;
3594
+ this.on("pipe", this._onpipe);
3595
+ this.replace = opts.replace;
3596
+ this._prompt = opts.prompt || null;
3597
+ this._hadControl = false;
3598
+ }
3599
+ #destSrc(key, def) {
3600
+ if (this._dest) {
3601
+ return this._dest[key];
3602
+ }
3603
+ if (this._src) {
3604
+ return this._src[key];
3605
+ }
3606
+ return def;
3607
+ }
3608
+ #proxy(method, ...args) {
3609
+ if (typeof this._dest?.[method] === "function") {
3610
+ this._dest[method](...args);
3611
+ }
3612
+ if (typeof this._src?.[method] === "function") {
3613
+ this._src[method](...args);
3614
+ }
3615
+ }
3616
+ get isTTY() {
3617
+ if (this.#isTTY !== null) {
3618
+ return this.#isTTY;
3619
+ }
3620
+ return this.#destSrc("isTTY", false);
3621
+ }
3622
+ // basically just get replace the getter/setter with a regular value
3623
+ set isTTY(val) {
3624
+ this.#isTTY = val;
3625
+ }
3626
+ get rows() {
3627
+ return this.#destSrc("rows");
3628
+ }
3629
+ get columns() {
3630
+ return this.#destSrc("columns");
3631
+ }
3632
+ mute() {
3633
+ this.muted = true;
3634
+ }
3635
+ unmute() {
3636
+ this.muted = false;
3637
+ }
3638
+ _onpipe(src) {
3639
+ this._src = src;
3640
+ }
3641
+ pipe(dest, options) {
3642
+ this._dest = dest;
3643
+ return super.pipe(dest, options);
3644
+ }
3645
+ pause() {
3646
+ if (this._src) {
3647
+ return this._src.pause();
3648
+ }
3649
+ }
3650
+ resume() {
3651
+ if (this._src) {
3652
+ return this._src.resume();
3653
+ }
3654
+ }
3655
+ write(c) {
3656
+ if (this.muted) {
3657
+ if (!this.replace) {
3658
+ return true;
3659
+ }
3660
+ if (c.match(/^\u001b/)) {
3661
+ if (c.indexOf(this._prompt) === 0) {
3662
+ c = c.slice(this._prompt.length);
3663
+ c = c.replace(/./g, this.replace);
3664
+ c = this._prompt + c;
3665
+ }
3666
+ this._hadControl = true;
3667
+ return this.emit("data", c);
3668
+ } else {
3669
+ if (this._prompt && this._hadControl && c.indexOf(this._prompt) === 0) {
3670
+ this._hadControl = false;
3671
+ this.emit("data", this._prompt);
3672
+ c = c.slice(this._prompt.length);
3673
+ }
3674
+ c = c.toString().replace(/./g, this.replace);
3675
+ }
3676
+ }
3677
+ this.emit("data", c);
3678
+ }
3679
+ end(c) {
3680
+ if (this.muted) {
3681
+ if (c && this.replace) {
3682
+ c = c.toString().replace(/./g, this.replace);
3683
+ } else {
3684
+ c = null;
3685
+ }
3686
+ }
3687
+ if (c) {
3688
+ this.emit("data", c);
3689
+ }
3690
+ this.emit("end");
3691
+ }
3692
+ destroy(...args) {
3693
+ return this.#proxy("destroy", ...args);
3694
+ }
3695
+ destroySoon(...args) {
3696
+ return this.#proxy("destroySoon", ...args);
3697
+ }
3698
+ close(...args) {
3699
+ return this.#proxy("close", ...args);
3700
+ }
3701
+ };
3702
+ module2.exports = MuteStream;
3703
+ }
3704
+ });
3705
+
3706
+ // node_modules/.pnpm/@inquirer+ansi@1.0.1/node_modules/@inquirer/ansi/dist/commonjs/index.js
3707
+ var require_commonjs6 = __commonJS({
3708
+ "node_modules/.pnpm/@inquirer+ansi@1.0.1/node_modules/@inquirer/ansi/dist/commonjs/index.js"(exports2) {
3709
+ "use strict";
3710
+ Object.defineProperty(exports2, "__esModule", { value: true });
3711
+ exports2.eraseLines = exports2.cursorTo = exports2.cursorDown = exports2.cursorUp = exports2.cursorShow = exports2.cursorHide = exports2.cursorLeft = void 0;
3712
+ var ESC = "\x1B[";
3713
+ exports2.cursorLeft = ESC + "G";
3714
+ exports2.cursorHide = ESC + "?25l";
3715
+ exports2.cursorShow = ESC + "?25h";
3716
+ var cursorUp = /* @__PURE__ */ __name((rows = 1) => rows > 0 ? `${ESC}${rows}A` : "", "cursorUp");
3717
+ exports2.cursorUp = cursorUp;
3718
+ var cursorDown = /* @__PURE__ */ __name((rows = 1) => rows > 0 ? `${ESC}${rows}B` : "", "cursorDown");
3719
+ exports2.cursorDown = cursorDown;
3720
+ var cursorTo = /* @__PURE__ */ __name((x, y) => {
3721
+ if (typeof y === "number" && !Number.isNaN(y)) {
3722
+ return `${ESC}${y + 1};${x + 1}H`;
3723
+ }
3724
+ return `${ESC}${x + 1}G`;
3725
+ }, "cursorTo");
3726
+ exports2.cursorTo = cursorTo;
3727
+ var eraseLine = ESC + "2K";
3728
+ var eraseLines = /* @__PURE__ */ __name((lines) => lines > 0 ? (eraseLine + (0, exports2.cursorUp)(1)).repeat(lines - 1) + eraseLine + exports2.cursorLeft : "", "eraseLines");
3729
+ exports2.eraseLines = eraseLines;
3730
+ }
3731
+ });
3732
+
3733
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/screen-manager.js
3734
+ var require_screen_manager2 = __commonJS({
3735
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/screen-manager.js"(exports2) {
3736
+ "use strict";
3737
+ Object.defineProperty(exports2, "__esModule", { value: true });
3738
+ var node_util_1 = require("node:util");
3739
+ var utils_ts_1 = require_utils2();
3740
+ var ansi_1 = require_commonjs6();
3741
+ var height = /* @__PURE__ */ __name((content) => content.split("\n").length, "height");
3742
+ var lastLine = /* @__PURE__ */ __name((content) => content.split("\n").pop() ?? "", "lastLine");
3743
+ var ScreenManager = class {
3744
+ static {
3745
+ __name(this, "ScreenManager");
3746
+ }
3747
+ // These variables are keeping information to allow correct prompt re-rendering
3748
+ height = 0;
3749
+ extraLinesUnderPrompt = 0;
3750
+ cursorPos;
3751
+ rl;
3752
+ constructor(rl) {
3753
+ this.rl = rl;
3754
+ this.cursorPos = rl.getCursorPos();
3755
+ }
3756
+ write(content) {
3757
+ this.rl.output.unmute();
3758
+ this.rl.output.write(content);
3759
+ this.rl.output.mute();
3760
+ }
3761
+ render(content, bottomContent = "") {
3762
+ const promptLine = lastLine(content);
3763
+ const rawPromptLine = (0, node_util_1.stripVTControlCharacters)(promptLine);
3764
+ let prompt = rawPromptLine;
3765
+ if (this.rl.line.length > 0) {
3766
+ prompt = prompt.slice(0, -this.rl.line.length);
3767
+ }
3768
+ this.rl.setPrompt(prompt);
3769
+ this.cursorPos = this.rl.getCursorPos();
3770
+ const width = (0, utils_ts_1.readlineWidth)();
3771
+ content = (0, utils_ts_1.breakLines)(content, width);
3772
+ bottomContent = (0, utils_ts_1.breakLines)(bottomContent, width);
3773
+ if (rawPromptLine.length % width === 0) {
3774
+ content += "\n";
3775
+ }
3776
+ let output = content + (bottomContent ? "\n" + bottomContent : "");
3777
+ const promptLineUpDiff = Math.floor(rawPromptLine.length / width) - this.cursorPos.rows;
3778
+ const bottomContentHeight = promptLineUpDiff + (bottomContent ? height(bottomContent) : 0);
3779
+ if (bottomContentHeight > 0)
3780
+ output += (0, ansi_1.cursorUp)(bottomContentHeight);
3781
+ output += (0, ansi_1.cursorTo)(this.cursorPos.cols);
3782
+ this.write((0, ansi_1.cursorDown)(this.extraLinesUnderPrompt) + (0, ansi_1.eraseLines)(this.height) + output);
3783
+ this.extraLinesUnderPrompt = bottomContentHeight;
3784
+ this.height = height(output);
3785
+ }
3786
+ checkCursorPos() {
3787
+ const cursorPos = this.rl.getCursorPos();
3788
+ if (cursorPos.cols !== this.cursorPos.cols) {
3789
+ this.write((0, ansi_1.cursorTo)(cursorPos.cols));
3790
+ this.cursorPos = cursorPos;
3791
+ }
3792
+ }
3793
+ done({ clearContent }) {
3794
+ this.rl.setPrompt("");
3795
+ let output = (0, ansi_1.cursorDown)(this.extraLinesUnderPrompt);
3796
+ output += clearContent ? (0, ansi_1.eraseLines)(this.height) : "\n";
3797
+ output += ansi_1.cursorShow;
3798
+ this.write(output);
3799
+ this.rl.close();
3800
+ }
3801
+ };
3802
+ exports2.default = ScreenManager;
3803
+ }
3804
+ });
3805
+
3806
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/promise-polyfill.js
3807
+ var require_promise_polyfill2 = __commonJS({
3808
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/promise-polyfill.js"(exports2) {
3809
+ "use strict";
3810
+ Object.defineProperty(exports2, "__esModule", { value: true });
3811
+ exports2.PromisePolyfill = void 0;
3812
+ var PromisePolyfill = class extends Promise {
3813
+ static {
3814
+ __name(this, "PromisePolyfill");
3815
+ }
3816
+ // Available starting from Node 22
3817
+ // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/withResolvers
3818
+ static withResolver() {
3819
+ let resolve;
3820
+ let reject;
3821
+ const promise = new Promise((res, rej) => {
3822
+ resolve = res;
3823
+ reject = rej;
3824
+ });
3825
+ return { promise, resolve, reject };
3826
+ }
3827
+ };
3828
+ exports2.PromisePolyfill = PromisePolyfill;
3829
+ }
3830
+ });
3831
+
3832
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/create-prompt.js
3833
+ var require_create_prompt2 = __commonJS({
3834
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/create-prompt.js"(exports2) {
3835
+ "use strict";
3836
+ var __createBinding = exports2 && exports2.__createBinding || (Object.create ? (function(o, m, k, k2) {
3837
+ if (k2 === void 0) k2 = k;
3838
+ var desc = Object.getOwnPropertyDescriptor(m, k);
3839
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
3840
+ desc = { enumerable: true, get: /* @__PURE__ */ __name(function() {
3841
+ return m[k];
3842
+ }, "get") };
3843
+ }
3844
+ Object.defineProperty(o, k2, desc);
3845
+ }) : (function(o, m, k, k2) {
3846
+ if (k2 === void 0) k2 = k;
3847
+ o[k2] = m[k];
3848
+ }));
3849
+ var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? (function(o, v) {
3850
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
3851
+ }) : function(o, v) {
3852
+ o["default"] = v;
3853
+ });
3854
+ var __importStar = exports2 && exports2.__importStar || /* @__PURE__ */ (function() {
3855
+ var ownKeys = /* @__PURE__ */ __name(function(o) {
3856
+ ownKeys = Object.getOwnPropertyNames || function(o2) {
3857
+ var ar = [];
3858
+ for (var k in o2) if (Object.prototype.hasOwnProperty.call(o2, k)) ar[ar.length] = k;
3859
+ return ar;
3860
+ };
3861
+ return ownKeys(o);
3862
+ }, "ownKeys");
3863
+ return function(mod) {
3864
+ if (mod && mod.__esModule) return mod;
3865
+ var result = {};
3866
+ if (mod != null) {
3867
+ for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
3868
+ }
3869
+ __setModuleDefault(result, mod);
3870
+ return result;
3871
+ };
3872
+ })();
3873
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
3874
+ return mod && mod.__esModule ? mod : { "default": mod };
3875
+ };
3876
+ Object.defineProperty(exports2, "__esModule", { value: true });
3877
+ exports2.createPrompt = createPrompt;
3878
+ var readline = __importStar(require("node:readline"));
3879
+ var node_async_hooks_1 = require("node:async_hooks");
3880
+ var mute_stream_1 = __importDefault(require_lib2());
3881
+ var signal_exit_1 = require_cjs();
3882
+ var screen_manager_ts_1 = __importDefault(require_screen_manager2());
3883
+ var promise_polyfill_ts_1 = require_promise_polyfill2();
3884
+ var hook_engine_ts_1 = require_hook_engine2();
3885
+ var errors_ts_1 = require_errors2();
3886
+ function getCallSites() {
3887
+ const _prepareStackTrace = Error.prepareStackTrace;
3888
+ let result = [];
3889
+ try {
3890
+ Error.prepareStackTrace = (_, callSites) => {
3891
+ const callSitesWithoutCurrent = callSites.slice(1);
3892
+ result = callSitesWithoutCurrent;
3893
+ return callSitesWithoutCurrent;
3894
+ };
3895
+ new Error().stack;
3896
+ } catch {
3897
+ return result;
3898
+ }
3899
+ Error.prepareStackTrace = _prepareStackTrace;
3900
+ return result;
3901
+ }
3902
+ __name(getCallSites, "getCallSites");
3903
+ function createPrompt(view) {
3904
+ const callSites = getCallSites();
3905
+ const prompt = /* @__PURE__ */ __name((config, context = {}) => {
3906
+ const { input: input2 = process.stdin, signal } = context;
3907
+ const cleanups = /* @__PURE__ */ new Set();
3908
+ const output = new mute_stream_1.default();
3909
+ output.pipe(context.output ?? process.stdout);
3910
+ const rl = readline.createInterface({
3911
+ terminal: true,
3912
+ input: input2,
3913
+ output
3914
+ });
3915
+ const screen = new screen_manager_ts_1.default(rl);
3916
+ const { promise, resolve, reject } = promise_polyfill_ts_1.PromisePolyfill.withResolver();
3917
+ const cancel = /* @__PURE__ */ __name(() => reject(new errors_ts_1.CancelPromptError()), "cancel");
3918
+ if (signal) {
3919
+ const abort = /* @__PURE__ */ __name(() => reject(new errors_ts_1.AbortPromptError({ cause: signal.reason })), "abort");
3920
+ if (signal.aborted) {
3921
+ abort();
3922
+ return Object.assign(promise, { cancel });
3923
+ }
3924
+ signal.addEventListener("abort", abort);
3925
+ cleanups.add(() => signal.removeEventListener("abort", abort));
3926
+ }
3927
+ cleanups.add((0, signal_exit_1.onExit)((code, signal2) => {
3928
+ reject(new errors_ts_1.ExitPromptError(`User force closed the prompt with ${code} ${signal2}`));
3929
+ }));
3930
+ const sigint = /* @__PURE__ */ __name(() => reject(new errors_ts_1.ExitPromptError(`User force closed the prompt with SIGINT`)), "sigint");
3931
+ rl.on("SIGINT", sigint);
3932
+ cleanups.add(() => rl.removeListener("SIGINT", sigint));
3933
+ const checkCursorPos = /* @__PURE__ */ __name(() => screen.checkCursorPos(), "checkCursorPos");
3934
+ rl.input.on("keypress", checkCursorPos);
3935
+ cleanups.add(() => rl.input.removeListener("keypress", checkCursorPos));
3936
+ return (0, hook_engine_ts_1.withHooks)(rl, (cycle) => {
3937
+ const hooksCleanup = node_async_hooks_1.AsyncResource.bind(() => hook_engine_ts_1.effectScheduler.clearAll());
3938
+ rl.on("close", hooksCleanup);
3939
+ cleanups.add(() => rl.removeListener("close", hooksCleanup));
3940
+ cycle(() => {
3941
+ try {
3942
+ const nextView = view(config, (value) => {
3943
+ setImmediate(() => resolve(value));
3944
+ });
3945
+ if (nextView === void 0) {
3946
+ const callerFilename = callSites[1]?.getFileName();
3947
+ throw new Error(`Prompt functions must return a string.
3948
+ at ${callerFilename}`);
3949
+ }
3950
+ const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
3951
+ screen.render(content, bottomContent);
3952
+ hook_engine_ts_1.effectScheduler.run();
3953
+ } catch (error) {
3954
+ reject(error);
3955
+ }
3956
+ });
3957
+ return Object.assign(promise.then((answer) => {
3958
+ hook_engine_ts_1.effectScheduler.clearAll();
3959
+ return answer;
3960
+ }, (error) => {
3961
+ hook_engine_ts_1.effectScheduler.clearAll();
3962
+ throw error;
3963
+ }).finally(() => {
3964
+ cleanups.forEach((cleanup) => cleanup());
3965
+ screen.done({ clearContent: Boolean(context.clearPromptOnDone) });
3966
+ output.end();
3967
+ }).then(() => promise), { cancel });
3968
+ });
3969
+ }, "prompt");
3970
+ return prompt;
3971
+ }
3972
+ __name(createPrompt, "createPrompt");
3973
+ }
3974
+ });
3975
+
3976
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/Separator.js
3977
+ var require_Separator2 = __commonJS({
3978
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/lib/Separator.js"(exports2) {
3979
+ "use strict";
3980
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
3981
+ return mod && mod.__esModule ? mod : { "default": mod };
3982
+ };
3983
+ Object.defineProperty(exports2, "__esModule", { value: true });
3984
+ exports2.Separator = void 0;
3985
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
3986
+ var figures_1 = __importDefault(require_commonjs5());
3987
+ var Separator = class {
3988
+ static {
3989
+ __name(this, "Separator");
3990
+ }
3991
+ separator = yoctocolors_cjs_1.default.dim(Array.from({ length: 15 }).join(figures_1.default.line));
3992
+ type = "separator";
3993
+ constructor(separator) {
3994
+ if (separator) {
3995
+ this.separator = separator;
3996
+ }
3997
+ }
3998
+ static isSeparator(choice) {
3999
+ return Boolean(choice && typeof choice === "object" && "type" in choice && choice.type === "separator");
4000
+ }
4001
+ };
4002
+ exports2.Separator = Separator;
4003
+ }
4004
+ });
4005
+
4006
+ // node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/index.js
4007
+ var require_commonjs7 = __commonJS({
4008
+ "node_modules/.pnpm/@inquirer+core@10.3.0_@types+node@24.9.2/node_modules/@inquirer/core/dist/commonjs/index.js"(exports2) {
4009
+ "use strict";
4010
+ var __createBinding = exports2 && exports2.__createBinding || (Object.create ? (function(o, m, k, k2) {
4011
+ if (k2 === void 0) k2 = k;
4012
+ var desc = Object.getOwnPropertyDescriptor(m, k);
4013
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
4014
+ desc = { enumerable: true, get: /* @__PURE__ */ __name(function() {
4015
+ return m[k];
4016
+ }, "get") };
4017
+ }
4018
+ Object.defineProperty(o, k2, desc);
4019
+ }) : (function(o, m, k, k2) {
4020
+ if (k2 === void 0) k2 = k;
4021
+ o[k2] = m[k];
4022
+ }));
4023
+ var __exportStar = exports2 && exports2.__exportStar || function(m, exports3) {
4024
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports3, p)) __createBinding(exports3, m, p);
4025
+ };
4026
+ Object.defineProperty(exports2, "__esModule", { value: true });
4027
+ exports2.Separator = exports2.createPrompt = exports2.usePagination = exports2.makeTheme = exports2.useKeypress = exports2.useRef = exports2.useMemo = exports2.useEffect = exports2.useState = exports2.usePrefix = exports2.isEnterKey = exports2.isNumberKey = exports2.isTabKey = exports2.isBackspaceKey = exports2.isSpaceKey = exports2.isDownKey = exports2.isUpKey = void 0;
4028
+ var key_ts_1 = require_key2();
4029
+ Object.defineProperty(exports2, "isUpKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4030
+ return key_ts_1.isUpKey;
4031
+ }, "get") });
4032
+ Object.defineProperty(exports2, "isDownKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4033
+ return key_ts_1.isDownKey;
4034
+ }, "get") });
4035
+ Object.defineProperty(exports2, "isSpaceKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4036
+ return key_ts_1.isSpaceKey;
4037
+ }, "get") });
4038
+ Object.defineProperty(exports2, "isBackspaceKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4039
+ return key_ts_1.isBackspaceKey;
4040
+ }, "get") });
4041
+ Object.defineProperty(exports2, "isTabKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4042
+ return key_ts_1.isTabKey;
4043
+ }, "get") });
4044
+ Object.defineProperty(exports2, "isNumberKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4045
+ return key_ts_1.isNumberKey;
4046
+ }, "get") });
4047
+ Object.defineProperty(exports2, "isEnterKey", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4048
+ return key_ts_1.isEnterKey;
4049
+ }, "get") });
4050
+ __exportStar(require_errors2(), exports2);
4051
+ var use_prefix_ts_1 = require_use_prefix2();
4052
+ Object.defineProperty(exports2, "usePrefix", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4053
+ return use_prefix_ts_1.usePrefix;
4054
+ }, "get") });
4055
+ var use_state_ts_1 = require_use_state2();
4056
+ Object.defineProperty(exports2, "useState", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4057
+ return use_state_ts_1.useState;
4058
+ }, "get") });
4059
+ var use_effect_ts_1 = require_use_effect2();
4060
+ Object.defineProperty(exports2, "useEffect", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4061
+ return use_effect_ts_1.useEffect;
4062
+ }, "get") });
4063
+ var use_memo_ts_1 = require_use_memo2();
4064
+ Object.defineProperty(exports2, "useMemo", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4065
+ return use_memo_ts_1.useMemo;
4066
+ }, "get") });
4067
+ var use_ref_ts_1 = require_use_ref2();
4068
+ Object.defineProperty(exports2, "useRef", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4069
+ return use_ref_ts_1.useRef;
4070
+ }, "get") });
4071
+ var use_keypress_ts_1 = require_use_keypress2();
4072
+ Object.defineProperty(exports2, "useKeypress", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4073
+ return use_keypress_ts_1.useKeypress;
4074
+ }, "get") });
4075
+ var make_theme_ts_1 = require_make_theme2();
4076
+ Object.defineProperty(exports2, "makeTheme", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4077
+ return make_theme_ts_1.makeTheme;
4078
+ }, "get") });
4079
+ var use_pagination_ts_1 = require_use_pagination2();
4080
+ Object.defineProperty(exports2, "usePagination", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4081
+ return use_pagination_ts_1.usePagination;
4082
+ }, "get") });
4083
+ var create_prompt_ts_1 = require_create_prompt2();
4084
+ Object.defineProperty(exports2, "createPrompt", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4085
+ return create_prompt_ts_1.createPrompt;
4086
+ }, "get") });
4087
+ var Separator_ts_1 = require_Separator2();
4088
+ Object.defineProperty(exports2, "Separator", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4089
+ return Separator_ts_1.Separator;
4090
+ }, "get") });
4091
+ }
4092
+ });
4093
+
4094
+ // node_modules/.pnpm/@inquirer+confirm@5.1.16_@types+node@24.9.2/node_modules/@inquirer/confirm/dist/commonjs/index.js
4095
+ var require_commonjs8 = __commonJS({
4096
+ "node_modules/.pnpm/@inquirer+confirm@5.1.16_@types+node@24.9.2/node_modules/@inquirer/confirm/dist/commonjs/index.js"(exports2) {
4097
+ "use strict";
4098
+ Object.defineProperty(exports2, "__esModule", { value: true });
4099
+ var core_1 = require_commonjs7();
4100
+ function getBooleanValue(value, defaultValue) {
4101
+ let answer = defaultValue !== false;
4102
+ if (/^(y|yes)/i.test(value))
4103
+ answer = true;
4104
+ else if (/^(n|no)/i.test(value))
4105
+ answer = false;
4106
+ return answer;
4107
+ }
4108
+ __name(getBooleanValue, "getBooleanValue");
4109
+ function boolToString(value) {
4110
+ return value ? "Yes" : "No";
4111
+ }
4112
+ __name(boolToString, "boolToString");
4113
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
4114
+ const { transformer = boolToString } = config;
4115
+ const [status, setStatus] = (0, core_1.useState)("idle");
4116
+ const [value, setValue] = (0, core_1.useState)("");
4117
+ const theme = (0, core_1.makeTheme)(config.theme);
4118
+ const prefix = (0, core_1.usePrefix)({ status, theme });
4119
+ (0, core_1.useKeypress)((key, rl) => {
4120
+ if (status !== "idle")
4121
+ return;
4122
+ if ((0, core_1.isEnterKey)(key)) {
4123
+ const answer = getBooleanValue(value, config.default);
4124
+ setValue(transformer(answer));
4125
+ setStatus("done");
4126
+ done(answer);
4127
+ } else if ((0, core_1.isTabKey)(key)) {
4128
+ const answer = boolToString(!getBooleanValue(value, config.default));
4129
+ rl.clearLine(0);
4130
+ rl.write(answer);
4131
+ setValue(answer);
4132
+ } else {
4133
+ setValue(rl.line);
4134
+ }
4135
+ });
4136
+ let formattedValue = value;
4137
+ let defaultValue = "";
4138
+ if (status === "done") {
4139
+ formattedValue = theme.style.answer(value);
4140
+ } else {
4141
+ defaultValue = ` ${theme.style.defaultAnswer(config.default === false ? "y/N" : "Y/n")}`;
4142
+ }
4143
+ const message = theme.style.message(config.message, status);
4144
+ return `${prefix} ${message}${defaultValue} ${formattedValue}`;
4145
+ });
4146
+ }
4147
+ });
4148
+
4149
+ // node_modules/.pnpm/@inquirer+input@4.2.2_@types+node@24.9.2/node_modules/@inquirer/input/dist/commonjs/index.js
4150
+ var require_commonjs9 = __commonJS({
4151
+ "node_modules/.pnpm/@inquirer+input@4.2.2_@types+node@24.9.2/node_modules/@inquirer/input/dist/commonjs/index.js"(exports2) {
4152
+ "use strict";
4153
+ Object.defineProperty(exports2, "__esModule", { value: true });
4154
+ var core_1 = require_commonjs7();
4155
+ var inputTheme = {
4156
+ validationFailureMode: "keep"
4157
+ };
4158
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
4159
+ const { required, validate: validate2 = /* @__PURE__ */ __name(() => true, "validate"), prefill = "tab" } = config;
4160
+ const theme = (0, core_1.makeTheme)(inputTheme, config.theme);
4161
+ const [status, setStatus] = (0, core_1.useState)("idle");
4162
+ const [defaultValue = "", setDefaultValue] = (0, core_1.useState)(config.default);
4163
+ const [errorMsg, setError] = (0, core_1.useState)();
4164
+ const [value, setValue] = (0, core_1.useState)("");
4165
+ const prefix = (0, core_1.usePrefix)({ status, theme });
4166
+ (0, core_1.useKeypress)(async (key, rl) => {
4167
+ if (status !== "idle") {
4168
+ return;
4169
+ }
4170
+ if ((0, core_1.isEnterKey)(key)) {
4171
+ const answer = value || defaultValue;
4172
+ setStatus("loading");
4173
+ const isValid = required && !answer ? "You must provide a value" : await validate2(answer);
4174
+ if (isValid === true) {
4175
+ setValue(answer);
4176
+ setStatus("done");
4177
+ done(answer);
4178
+ } else {
4179
+ if (theme.validationFailureMode === "clear") {
4180
+ setValue("");
4181
+ } else {
4182
+ rl.write(value);
4183
+ }
4184
+ setError(isValid || "You must provide a valid value");
4185
+ setStatus("idle");
4186
+ }
4187
+ } else if ((0, core_1.isBackspaceKey)(key) && !value) {
4188
+ setDefaultValue(void 0);
4189
+ } else if ((0, core_1.isTabKey)(key) && !value) {
4190
+ setDefaultValue(void 0);
4191
+ rl.clearLine(0);
4192
+ rl.write(defaultValue);
4193
+ setValue(defaultValue);
4194
+ } else {
4195
+ setValue(rl.line);
4196
+ setError(void 0);
4197
+ }
4198
+ });
4199
+ (0, core_1.useEffect)((rl) => {
4200
+ if (prefill === "editable" && defaultValue) {
4201
+ rl.write(defaultValue);
4202
+ setValue(defaultValue);
4203
+ }
4204
+ }, []);
4205
+ const message = theme.style.message(config.message, status);
4206
+ let formattedValue = value;
4207
+ if (typeof config.transformer === "function") {
4208
+ formattedValue = config.transformer(value, { isFinal: status === "done" });
4209
+ } else if (status === "done") {
4210
+ formattedValue = theme.style.answer(value);
4211
+ }
4212
+ let defaultStr;
4213
+ if (defaultValue && status !== "done" && !value) {
4214
+ defaultStr = theme.style.defaultAnswer(defaultValue);
4215
+ }
4216
+ let error = "";
4217
+ if (errorMsg) {
4218
+ error = theme.style.error(errorMsg);
4219
+ }
4220
+ return [
4221
+ [prefix, message, defaultStr, formattedValue].filter((v) => v !== void 0).join(" "),
4222
+ error
4223
+ ];
4224
+ });
4225
+ }
4226
+ });
4227
+
4228
+ // node_modules/.pnpm/ansi-escapes@4.3.2/node_modules/ansi-escapes/index.js
4229
+ var require_ansi_escapes = __commonJS({
4230
+ "node_modules/.pnpm/ansi-escapes@4.3.2/node_modules/ansi-escapes/index.js"(exports2, module2) {
4231
+ "use strict";
4232
+ var ansiEscapes = module2.exports;
4233
+ module2.exports.default = ansiEscapes;
4234
+ var ESC = "\x1B[";
4235
+ var OSC = "\x1B]";
4236
+ var BEL = "\x07";
4237
+ var SEP = ";";
4238
+ var isTerminalApp = process.env.TERM_PROGRAM === "Apple_Terminal";
4239
+ ansiEscapes.cursorTo = (x, y) => {
4240
+ if (typeof x !== "number") {
4241
+ throw new TypeError("The `x` argument is required");
4242
+ }
4243
+ if (typeof y !== "number") {
4244
+ return ESC + (x + 1) + "G";
4245
+ }
4246
+ return ESC + (y + 1) + ";" + (x + 1) + "H";
4247
+ };
4248
+ ansiEscapes.cursorMove = (x, y) => {
4249
+ if (typeof x !== "number") {
4250
+ throw new TypeError("The `x` argument is required");
4251
+ }
4252
+ let ret = "";
4253
+ if (x < 0) {
4254
+ ret += ESC + -x + "D";
4255
+ } else if (x > 0) {
4256
+ ret += ESC + x + "C";
4257
+ }
4258
+ if (y < 0) {
4259
+ ret += ESC + -y + "A";
4260
+ } else if (y > 0) {
4261
+ ret += ESC + y + "B";
4262
+ }
4263
+ return ret;
4264
+ };
4265
+ ansiEscapes.cursorUp = (count = 1) => ESC + count + "A";
4266
+ ansiEscapes.cursorDown = (count = 1) => ESC + count + "B";
4267
+ ansiEscapes.cursorForward = (count = 1) => ESC + count + "C";
4268
+ ansiEscapes.cursorBackward = (count = 1) => ESC + count + "D";
4269
+ ansiEscapes.cursorLeft = ESC + "G";
4270
+ ansiEscapes.cursorSavePosition = isTerminalApp ? "\x1B7" : ESC + "s";
4271
+ ansiEscapes.cursorRestorePosition = isTerminalApp ? "\x1B8" : ESC + "u";
4272
+ ansiEscapes.cursorGetPosition = ESC + "6n";
4273
+ ansiEscapes.cursorNextLine = ESC + "E";
4274
+ ansiEscapes.cursorPrevLine = ESC + "F";
4275
+ ansiEscapes.cursorHide = ESC + "?25l";
4276
+ ansiEscapes.cursorShow = ESC + "?25h";
4277
+ ansiEscapes.eraseLines = (count) => {
4278
+ let clear = "";
4279
+ for (let i = 0; i < count; i++) {
4280
+ clear += ansiEscapes.eraseLine + (i < count - 1 ? ansiEscapes.cursorUp() : "");
4281
+ }
4282
+ if (count) {
4283
+ clear += ansiEscapes.cursorLeft;
4284
+ }
4285
+ return clear;
4286
+ };
4287
+ ansiEscapes.eraseEndLine = ESC + "K";
4288
+ ansiEscapes.eraseStartLine = ESC + "1K";
4289
+ ansiEscapes.eraseLine = ESC + "2K";
4290
+ ansiEscapes.eraseDown = ESC + "J";
4291
+ ansiEscapes.eraseUp = ESC + "1J";
4292
+ ansiEscapes.eraseScreen = ESC + "2J";
4293
+ ansiEscapes.scrollUp = ESC + "S";
4294
+ ansiEscapes.scrollDown = ESC + "T";
4295
+ ansiEscapes.clearScreen = "\x1Bc";
4296
+ ansiEscapes.clearTerminal = process.platform === "win32" ? `${ansiEscapes.eraseScreen}${ESC}0f` : (
4297
+ // 1. Erases the screen (Only done in case `2` is not supported)
4298
+ // 2. Erases the whole screen including scrollback buffer
4299
+ // 3. Moves cursor to the top-left position
4300
+ // More info: https://www.real-world-systems.com/docs/ANSIcode.html
4301
+ `${ansiEscapes.eraseScreen}${ESC}3J${ESC}H`
4302
+ );
4303
+ ansiEscapes.beep = BEL;
4304
+ ansiEscapes.link = (text, url) => {
4305
+ return [
4306
+ OSC,
4307
+ "8",
4308
+ SEP,
4309
+ SEP,
4310
+ url,
4311
+ BEL,
4312
+ text,
4313
+ OSC,
4314
+ "8",
4315
+ SEP,
4316
+ SEP,
4317
+ BEL
4318
+ ].join("");
4319
+ };
4320
+ ansiEscapes.image = (buffer, options = {}) => {
4321
+ let ret = `${OSC}1337;File=inline=1`;
4322
+ if (options.width) {
4323
+ ret += `;width=${options.width}`;
4324
+ }
4325
+ if (options.height) {
4326
+ ret += `;height=${options.height}`;
4327
+ }
4328
+ if (options.preserveAspectRatio === false) {
4329
+ ret += ";preserveAspectRatio=0";
4330
+ }
4331
+ return ret + ":" + buffer.toString("base64") + BEL;
4332
+ };
4333
+ ansiEscapes.iTerm = {
4334
+ setCwd: /* @__PURE__ */ __name((cwd = process.cwd()) => `${OSC}50;CurrentDir=${cwd}${BEL}`, "setCwd"),
4335
+ annotation: /* @__PURE__ */ __name((message, options = {}) => {
4336
+ let ret = `${OSC}1337;`;
4337
+ const hasX = typeof options.x !== "undefined";
4338
+ const hasY = typeof options.y !== "undefined";
4339
+ if ((hasX || hasY) && !(hasX && hasY && typeof options.length !== "undefined")) {
4340
+ throw new Error("`x`, `y` and `length` must be defined when `x` or `y` is defined");
4341
+ }
4342
+ message = message.replace(/\|/g, "");
4343
+ ret += options.isHidden ? "AddHiddenAnnotation=" : "AddAnnotation=";
4344
+ if (options.length > 0) {
4345
+ ret += (hasX ? [message, options.length, options.x, options.y] : [options.length, message]).join("|");
4346
+ } else {
4347
+ ret += message;
4348
+ }
4349
+ return ret + BEL;
4350
+ }, "annotation")
4351
+ };
4352
+ }
4353
+ });
4354
+
4355
+ // node_modules/.pnpm/@inquirer+password@4.0.18_@types+node@24.9.2/node_modules/@inquirer/password/dist/commonjs/index.js
4356
+ var require_commonjs10 = __commonJS({
4357
+ "node_modules/.pnpm/@inquirer+password@4.0.18_@types+node@24.9.2/node_modules/@inquirer/password/dist/commonjs/index.js"(exports2) {
4358
+ "use strict";
4359
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
4360
+ return mod && mod.__esModule ? mod : { "default": mod };
4361
+ };
4362
+ Object.defineProperty(exports2, "__esModule", { value: true });
4363
+ var core_1 = require_commonjs7();
4364
+ var ansi_escapes_1 = __importDefault(require_ansi_escapes());
4365
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
4366
+ const { validate: validate2 = /* @__PURE__ */ __name(() => true, "validate") } = config;
4367
+ const theme = (0, core_1.makeTheme)(config.theme);
4368
+ const [status, setStatus] = (0, core_1.useState)("idle");
4369
+ const [errorMsg, setError] = (0, core_1.useState)();
4370
+ const [value, setValue] = (0, core_1.useState)("");
4371
+ const prefix = (0, core_1.usePrefix)({ status, theme });
4372
+ (0, core_1.useKeypress)(async (key, rl) => {
4373
+ if (status !== "idle") {
4374
+ return;
4375
+ }
4376
+ if ((0, core_1.isEnterKey)(key)) {
4377
+ const answer = value;
4378
+ setStatus("loading");
4379
+ const isValid = await validate2(answer);
4380
+ if (isValid === true) {
4381
+ setValue(answer);
4382
+ setStatus("done");
4383
+ done(answer);
4384
+ } else {
4385
+ rl.write(value);
4386
+ setError(isValid || "You must provide a valid value");
4387
+ setStatus("idle");
4388
+ }
4389
+ } else {
4390
+ setValue(rl.line);
4391
+ setError(void 0);
4392
+ }
4393
+ });
4394
+ const message = theme.style.message(config.message, status);
4395
+ let formattedValue = "";
4396
+ let helpTip;
4397
+ if (config.mask) {
4398
+ const maskChar = typeof config.mask === "string" ? config.mask : "*";
4399
+ formattedValue = maskChar.repeat(value.length);
4400
+ } else if (status !== "done") {
4401
+ helpTip = `${theme.style.help("[input is masked]")}${ansi_escapes_1.default.cursorHide}`;
4402
+ }
4403
+ if (status === "done") {
4404
+ formattedValue = theme.style.answer(formattedValue);
4405
+ }
4406
+ let error = "";
4407
+ if (errorMsg) {
4408
+ error = theme.style.error(errorMsg);
4409
+ }
4410
+ return [[prefix, message, config.mask ? formattedValue : helpTip].join(" "), error];
4411
+ });
4412
+ }
4413
+ });
4414
+
4415
+ // node_modules/.pnpm/@inquirer+search@3.1.1_@types+node@24.9.2/node_modules/@inquirer/search/dist/commonjs/index.js
4416
+ var require_commonjs11 = __commonJS({
4417
+ "node_modules/.pnpm/@inquirer+search@3.1.1_@types+node@24.9.2/node_modules/@inquirer/search/dist/commonjs/index.js"(exports2) {
4418
+ "use strict";
4419
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
4420
+ return mod && mod.__esModule ? mod : { "default": mod };
4421
+ };
4422
+ Object.defineProperty(exports2, "__esModule", { value: true });
4423
+ exports2.Separator = void 0;
4424
+ var core_1 = require_commonjs7();
4425
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
4426
+ var figures_1 = __importDefault(require_commonjs5());
4427
+ var searchTheme = {
4428
+ icon: { cursor: figures_1.default.pointer },
4429
+ style: {
4430
+ disabled: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.dim(`- ${text}`), "disabled"),
4431
+ searchTerm: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(text), "searchTerm"),
4432
+ description: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(text), "description")
4433
+ },
4434
+ helpMode: "auto"
4435
+ };
4436
+ function isSelectable(item) {
4437
+ return !core_1.Separator.isSeparator(item) && !item.disabled;
4438
+ }
4439
+ __name(isSelectable, "isSelectable");
4440
+ function normalizeChoices(choices) {
4441
+ return choices.map((choice) => {
4442
+ if (core_1.Separator.isSeparator(choice))
4443
+ return choice;
4444
+ if (typeof choice === "string") {
4445
+ return {
4446
+ value: choice,
4447
+ name: choice,
4448
+ short: choice,
4449
+ disabled: false
4450
+ };
4451
+ }
4452
+ const name = choice.name ?? String(choice.value);
4453
+ const normalizedChoice = {
4454
+ value: choice.value,
4455
+ name,
4456
+ short: choice.short ?? name,
4457
+ disabled: choice.disabled ?? false
4458
+ };
4459
+ if (choice.description) {
4460
+ normalizedChoice.description = choice.description;
4461
+ }
4462
+ return normalizedChoice;
4463
+ });
4464
+ }
4465
+ __name(normalizeChoices, "normalizeChoices");
4466
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
4467
+ const { pageSize = 7, validate: validate2 = /* @__PURE__ */ __name(() => true, "validate") } = config;
4468
+ const theme = (0, core_1.makeTheme)(searchTheme, config.theme);
4469
+ const firstRender = (0, core_1.useRef)(true);
4470
+ const [status, setStatus] = (0, core_1.useState)("loading");
4471
+ const [searchTerm, setSearchTerm] = (0, core_1.useState)("");
4472
+ const [searchResults, setSearchResults] = (0, core_1.useState)([]);
4473
+ const [searchError, setSearchError] = (0, core_1.useState)();
4474
+ const prefix = (0, core_1.usePrefix)({ status, theme });
4475
+ const bounds = (0, core_1.useMemo)(() => {
4476
+ const first = searchResults.findIndex(isSelectable);
4477
+ const last = searchResults.findLastIndex(isSelectable);
4478
+ return { first, last };
4479
+ }, [searchResults]);
4480
+ const [active = bounds.first, setActive] = (0, core_1.useState)();
4481
+ (0, core_1.useEffect)(() => {
4482
+ const controller = new AbortController();
4483
+ setStatus("loading");
4484
+ setSearchError(void 0);
4485
+ const fetchResults = /* @__PURE__ */ __name(async () => {
4486
+ try {
4487
+ const results = await config.source(searchTerm || void 0, {
4488
+ signal: controller.signal
4489
+ });
4490
+ if (!controller.signal.aborted) {
4491
+ setActive(void 0);
4492
+ setSearchError(void 0);
4493
+ setSearchResults(normalizeChoices(results));
4494
+ setStatus("idle");
4495
+ }
4496
+ } catch (error2) {
4497
+ if (!controller.signal.aborted && error2 instanceof Error) {
4498
+ setSearchError(error2.message);
4499
+ }
4500
+ }
4501
+ }, "fetchResults");
4502
+ void fetchResults();
4503
+ return () => {
4504
+ controller.abort();
4505
+ };
4506
+ }, [searchTerm]);
4507
+ const selectedChoice = searchResults[active];
4508
+ (0, core_1.useKeypress)(async (key, rl) => {
4509
+ if ((0, core_1.isEnterKey)(key)) {
4510
+ if (selectedChoice) {
4511
+ setStatus("loading");
4512
+ const isValid = await validate2(selectedChoice.value);
4513
+ setStatus("idle");
4514
+ if (isValid === true) {
4515
+ setStatus("done");
4516
+ done(selectedChoice.value);
4517
+ } else if (selectedChoice.name === searchTerm) {
4518
+ setSearchError(isValid || "You must provide a valid value");
4519
+ } else {
4520
+ rl.write(selectedChoice.name);
4521
+ setSearchTerm(selectedChoice.name);
4522
+ }
4523
+ } else {
4524
+ rl.write(searchTerm);
4525
+ }
4526
+ } else if ((0, core_1.isTabKey)(key) && selectedChoice) {
4527
+ rl.clearLine(0);
4528
+ rl.write(selectedChoice.name);
4529
+ setSearchTerm(selectedChoice.name);
4530
+ } else if (status !== "loading" && ((0, core_1.isUpKey)(key) || (0, core_1.isDownKey)(key))) {
4531
+ rl.clearLine(0);
4532
+ if ((0, core_1.isUpKey)(key) && active !== bounds.first || (0, core_1.isDownKey)(key) && active !== bounds.last) {
4533
+ const offset = (0, core_1.isUpKey)(key) ? -1 : 1;
4534
+ let next = active;
4535
+ do {
4536
+ next = (next + offset + searchResults.length) % searchResults.length;
4537
+ } while (!isSelectable(searchResults[next]));
4538
+ setActive(next);
4539
+ }
4540
+ } else {
4541
+ setSearchTerm(rl.line);
4542
+ }
4543
+ });
4544
+ const message = theme.style.message(config.message, status);
4545
+ if (active > 0) {
4546
+ firstRender.current = false;
4547
+ }
4548
+ let helpTip = "";
4549
+ if (searchResults.length > 1 && (theme.helpMode === "always" || theme.helpMode === "auto" && firstRender.current)) {
4550
+ helpTip = searchResults.length > pageSize ? `
4551
+ ${theme.style.help(`(${config.instructions?.pager ?? "Use arrow keys to reveal more choices"})`)}` : `
4552
+ ${theme.style.help(`(${config.instructions?.navigation ?? "Use arrow keys"})`)}`;
4553
+ }
4554
+ const page = (0, core_1.usePagination)({
4555
+ items: searchResults,
4556
+ active,
4557
+ renderItem({ item, isActive }) {
4558
+ if (core_1.Separator.isSeparator(item)) {
4559
+ return ` ${item.separator}`;
4560
+ }
4561
+ if (item.disabled) {
4562
+ const disabledLabel = typeof item.disabled === "string" ? item.disabled : "(disabled)";
4563
+ return theme.style.disabled(`${item.name} ${disabledLabel}`);
4564
+ }
4565
+ const color = isActive ? theme.style.highlight : (x) => x;
4566
+ const cursor = isActive ? theme.icon.cursor : ` `;
4567
+ return color(`${cursor} ${item.name}`);
4568
+ },
4569
+ pageSize,
4570
+ loop: false
4571
+ });
4572
+ let error;
4573
+ if (searchError) {
4574
+ error = theme.style.error(searchError);
4575
+ } else if (searchResults.length === 0 && searchTerm !== "" && status === "idle") {
4576
+ error = theme.style.error("No results found");
4577
+ }
4578
+ let searchStr;
4579
+ if (status === "done" && selectedChoice) {
4580
+ const answer = selectedChoice.short;
4581
+ return `${prefix} ${message} ${theme.style.answer(answer)}`;
4582
+ } else {
4583
+ searchStr = theme.style.searchTerm(searchTerm);
4584
+ }
4585
+ const choiceDescription = selectedChoice?.description ? `
4586
+ ${theme.style.description(selectedChoice.description)}` : ``;
4587
+ return [
4588
+ [prefix, message, searchStr].filter(Boolean).join(" "),
4589
+ `${error ?? page}${helpTip}${choiceDescription}`
4590
+ ];
4591
+ });
4592
+ var core_2 = require_commonjs7();
4593
+ Object.defineProperty(exports2, "Separator", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4594
+ return core_2.Separator;
4595
+ }, "get") });
4596
+ }
4597
+ });
4598
+
4599
+ // node_modules/.pnpm/@inquirer+select@4.3.2_@types+node@24.9.2/node_modules/@inquirer/select/dist/commonjs/index.js
4600
+ var require_commonjs12 = __commonJS({
4601
+ "node_modules/.pnpm/@inquirer+select@4.3.2_@types+node@24.9.2/node_modules/@inquirer/select/dist/commonjs/index.js"(exports2) {
4602
+ "use strict";
4603
+ var __importDefault = exports2 && exports2.__importDefault || function(mod) {
4604
+ return mod && mod.__esModule ? mod : { "default": mod };
4605
+ };
4606
+ Object.defineProperty(exports2, "__esModule", { value: true });
4607
+ exports2.Separator = void 0;
4608
+ var core_1 = require_commonjs7();
4609
+ var yoctocolors_cjs_1 = __importDefault(require_yoctocolors_cjs());
4610
+ var figures_1 = __importDefault(require_commonjs5());
4611
+ var ansi_escapes_1 = __importDefault(require_ansi_escapes());
4612
+ var selectTheme = {
4613
+ icon: { cursor: figures_1.default.pointer },
4614
+ style: {
4615
+ disabled: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.dim(`- ${text}`), "disabled"),
4616
+ description: /* @__PURE__ */ __name((text) => yoctocolors_cjs_1.default.cyan(text), "description")
4617
+ },
4618
+ helpMode: "auto",
4619
+ indexMode: "hidden"
4620
+ };
4621
+ function isSelectable(item) {
4622
+ return !core_1.Separator.isSeparator(item) && !item.disabled;
4623
+ }
4624
+ __name(isSelectable, "isSelectable");
4625
+ function normalizeChoices(choices) {
4626
+ return choices.map((choice) => {
4627
+ if (core_1.Separator.isSeparator(choice))
4628
+ return choice;
4629
+ if (typeof choice === "string") {
4630
+ return {
4631
+ value: choice,
4632
+ name: choice,
4633
+ short: choice,
4634
+ disabled: false
4635
+ };
4636
+ }
4637
+ const name = choice.name ?? String(choice.value);
4638
+ const normalizedChoice = {
4639
+ value: choice.value,
4640
+ name,
4641
+ short: choice.short ?? name,
4642
+ disabled: choice.disabled ?? false
4643
+ };
4644
+ if (choice.description) {
4645
+ normalizedChoice.description = choice.description;
4646
+ }
4647
+ return normalizedChoice;
4648
+ });
4649
+ }
4650
+ __name(normalizeChoices, "normalizeChoices");
4651
+ exports2.default = (0, core_1.createPrompt)((config, done) => {
4652
+ const { loop = true, pageSize = 7 } = config;
4653
+ const firstRender = (0, core_1.useRef)(true);
4654
+ const theme = (0, core_1.makeTheme)(selectTheme, config.theme);
4655
+ const [status, setStatus] = (0, core_1.useState)("idle");
4656
+ const prefix = (0, core_1.usePrefix)({ status, theme });
4657
+ const searchTimeoutRef = (0, core_1.useRef)();
4658
+ const items = (0, core_1.useMemo)(() => normalizeChoices(config.choices), [config.choices]);
4659
+ const bounds = (0, core_1.useMemo)(() => {
4660
+ const first = items.findIndex(isSelectable);
4661
+ const last = items.findLastIndex(isSelectable);
4662
+ if (first === -1) {
4663
+ throw new core_1.ValidationError("[select prompt] No selectable choices. All choices are disabled.");
4664
+ }
4665
+ return { first, last };
4666
+ }, [items]);
4667
+ const defaultItemIndex = (0, core_1.useMemo)(() => {
4668
+ if (!("default" in config))
4669
+ return -1;
4670
+ return items.findIndex((item) => isSelectable(item) && item.value === config.default);
4671
+ }, [config.default, items]);
4672
+ const [active, setActive] = (0, core_1.useState)(defaultItemIndex === -1 ? bounds.first : defaultItemIndex);
4673
+ const selectedChoice = items[active];
4674
+ (0, core_1.useKeypress)((key, rl) => {
4675
+ clearTimeout(searchTimeoutRef.current);
4676
+ if ((0, core_1.isEnterKey)(key)) {
4677
+ setStatus("done");
4678
+ done(selectedChoice.value);
4679
+ } else if ((0, core_1.isUpKey)(key) || (0, core_1.isDownKey)(key)) {
4680
+ rl.clearLine(0);
4681
+ if (loop || (0, core_1.isUpKey)(key) && active !== bounds.first || (0, core_1.isDownKey)(key) && active !== bounds.last) {
4682
+ const offset = (0, core_1.isUpKey)(key) ? -1 : 1;
4683
+ let next = active;
4684
+ do {
4685
+ next = (next + offset + items.length) % items.length;
4686
+ } while (!isSelectable(items[next]));
4687
+ setActive(next);
4688
+ }
4689
+ } else if ((0, core_1.isNumberKey)(key) && !Number.isNaN(Number(rl.line))) {
4690
+ const selectedIndex = Number(rl.line) - 1;
4691
+ let selectableIndex = -1;
4692
+ const position = items.findIndex((item2) => {
4693
+ if (core_1.Separator.isSeparator(item2))
4694
+ return false;
4695
+ selectableIndex++;
4696
+ return selectableIndex === selectedIndex;
4697
+ });
4698
+ const item = items[position];
4699
+ if (item != null && isSelectable(item)) {
4700
+ setActive(position);
4701
+ }
4702
+ searchTimeoutRef.current = setTimeout(() => {
4703
+ rl.clearLine(0);
4704
+ }, 700);
4705
+ } else if ((0, core_1.isBackspaceKey)(key)) {
4706
+ rl.clearLine(0);
4707
+ } else {
4708
+ const searchTerm = rl.line.toLowerCase();
4709
+ const matchIndex = items.findIndex((item) => {
4710
+ if (core_1.Separator.isSeparator(item) || !isSelectable(item))
4711
+ return false;
4712
+ return item.name.toLowerCase().startsWith(searchTerm);
4713
+ });
4714
+ if (matchIndex !== -1) {
4715
+ setActive(matchIndex);
4716
+ }
4717
+ searchTimeoutRef.current = setTimeout(() => {
4718
+ rl.clearLine(0);
4719
+ }, 700);
4720
+ }
4721
+ });
4722
+ (0, core_1.useEffect)(() => () => {
4723
+ clearTimeout(searchTimeoutRef.current);
4724
+ }, []);
4725
+ const message = theme.style.message(config.message, status);
4726
+ let helpTipTop = "";
4727
+ let helpTipBottom = "";
4728
+ if (theme.helpMode === "always" || theme.helpMode === "auto" && firstRender.current) {
4729
+ firstRender.current = false;
4730
+ if (items.length > pageSize) {
4731
+ helpTipBottom = `
4732
+ ${theme.style.help(`(${config.instructions?.pager ?? "Use arrow keys to reveal more choices"})`)}`;
4733
+ } else {
4734
+ helpTipTop = theme.style.help(`(${config.instructions?.navigation ?? "Use arrow keys"})`);
4735
+ }
4736
+ }
4737
+ let separatorCount = 0;
4738
+ const page = (0, core_1.usePagination)({
4739
+ items,
4740
+ active,
4741
+ renderItem({ item, isActive, index }) {
4742
+ if (core_1.Separator.isSeparator(item)) {
4743
+ separatorCount++;
4744
+ return ` ${item.separator}`;
4745
+ }
4746
+ const indexLabel = theme.indexMode === "number" ? `${index + 1 - separatorCount}. ` : "";
4747
+ if (item.disabled) {
4748
+ const disabledLabel = typeof item.disabled === "string" ? item.disabled : "(disabled)";
4749
+ return theme.style.disabled(`${indexLabel}${item.name} ${disabledLabel}`);
4750
+ }
4751
+ const color = isActive ? theme.style.highlight : (x) => x;
4752
+ const cursor = isActive ? theme.icon.cursor : ` `;
4753
+ return color(`${cursor} ${indexLabel}${item.name}`);
4754
+ },
4755
+ pageSize,
4756
+ loop
4757
+ });
4758
+ if (status === "done") {
4759
+ return `${prefix} ${message} ${theme.style.answer(selectedChoice.short)}`;
4760
+ }
4761
+ const choiceDescription = selectedChoice.description ? `
4762
+ ${theme.style.description(selectedChoice.description)}` : ``;
4763
+ return `${[prefix, message, helpTipTop].filter(Boolean).join(" ")}
4764
+ ${page}${helpTipBottom}${choiceDescription}${ansi_escapes_1.default.cursorHide}`;
4765
+ });
4766
+ var core_2 = require_commonjs7();
4767
+ Object.defineProperty(exports2, "Separator", { enumerable: true, get: /* @__PURE__ */ __name(function() {
4768
+ return core_2.Separator;
4769
+ }, "get") });
4770
+ }
4771
+ });
4772
+
4773
+ // src/external/external-pack.js
4774
+ var signalExit = require_cjs();
4775
+ var supportsColor2 = (init_supports_color(), __toCommonJS(supports_color_exports));
4776
+ var hasFlag3 = (init_has_flag(), __toCommonJS(has_flag_exports));
4777
+ var yoctocolorsCjs = require_yoctocolors_cjs();
4778
+ var checkbox = require_commonjs4();
4779
+ var confirm = require_commonjs8();
4780
+ var input = require_commonjs9();
4781
+ var password = require_commonjs10();
4782
+ var search = require_commonjs11();
4783
+ var select = require_commonjs12();
4784
+ module.exports = {
4785
+ checkbox,
4786
+ confirm,
4787
+ hasFlag: hasFlag3,
4788
+ input,
4789
+ password,
4790
+ search,
4791
+ select,
4792
+ signalExit,
4793
+ supportsColor: supportsColor2,
4794
+ yoctocolorsCjs
4795
+ };