create-vue 3.22.1 → 3.22.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bundle.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- /*! create-vue v3.22.1 | MIT */
2
+ /*! create-vue v3.22.3 | MIT */
3
3
  import { createRequire } from "node:module";
4
4
  import * as fs from "node:fs";
5
5
  import "node:fs";
@@ -7,9 +7,9 @@ import * as path$1 from "node:path";
7
7
  import "node:path";
8
8
  import { fileURLToPath, pathToFileURL } from "node:url";
9
9
  import { parseArgs, stripVTControlCharacters, styleText } from "node:util";
10
- import N, { stdin, stdout } from "node:process";
10
+ import P, { stdin, stdout } from "node:process";
11
11
  import "node:readline";
12
- import ot from "node:readline";
12
+ import P$1 from "node:readline";
13
13
  import "node:tty";
14
14
  import * as path from "path";
15
15
  //#region \0rolldown/runtime.js
@@ -19,7 +19,7 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
19
19
  var __getOwnPropNames = Object.getOwnPropertyNames;
20
20
  var __getProtoOf = Object.getPrototypeOf;
21
21
  var __hasOwnProp = Object.prototype.hasOwnProperty;
22
- var __commonJSMin = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
22
+ var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
23
23
  var __copyProps = (to, from, except, desc) => {
24
24
  if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
25
25
  key = keys[i];
@@ -36,7 +36,327 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
36
36
  }) : target, mod));
37
37
  var __require = /* @__PURE__ */ createRequire(import.meta.url);
38
38
  //#endregion
39
- //#region node_modules/.pnpm/@clack+core@1.1.0/node_modules/@clack/core/dist/index.mjs
39
+ //#region node_modules/.pnpm/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/utils.js
40
+ const isAmbiguous = (x) => {
41
+ 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;
42
+ };
43
+ const isFullWidth = (x) => {
44
+ return x === 12288 || x >= 65281 && x <= 65376 || x >= 65504 && x <= 65510;
45
+ };
46
+ const isWide = (x) => {
47
+ 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 >= 9800 && x <= 9811 || x === 9855 || 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 <= 12771 || x >= 12783 && x <= 12830 || x >= 12832 && x <= 12871 || x >= 12880 && x <= 19903 || x >= 19968 && 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 >= 101632 && 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 === 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 <= 129672 || x >= 129680 && x <= 129725 || x >= 129727 && x <= 129733 || x >= 129742 && x <= 129755 || x >= 129760 && x <= 129768 || x >= 129776 && x <= 129784 || x >= 131072 && x <= 196605 || x >= 196608 && x <= 262141;
48
+ };
49
+ //#endregion
50
+ //#region node_modules/.pnpm/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/index.js
51
+ const ANSI_RE = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y;
52
+ const CONTROL_RE = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y;
53
+ const TAB_RE = /\t{1,1000}/y;
54
+ const EMOJI_RE = /[\u{1F1E6}-\u{1F1FF}]{2}|\u{1F3F4}[\u{E0061}-\u{E007A}]{2}[\u{E0030}-\u{E0039}\u{E0061}-\u{E007A}]{1,3}\u{E007F}|(?:\p{Emoji}\uFE0F\u20E3?|\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation})(?:\u200D(?:\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation}|\p{Emoji}\uFE0F\u20E3?))*/uy;
55
+ const LATIN_RE = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y;
56
+ const MODIFIER_RE = /\p{M}+/gu;
57
+ const NO_TRUNCATION$1 = {
58
+ limit: Infinity,
59
+ ellipsis: ""
60
+ };
61
+ const getStringTruncatedWidth = (input, truncationOptions = {}, widthOptions = {}) => {
62
+ const LIMIT = truncationOptions.limit ?? Infinity;
63
+ const ELLIPSIS = truncationOptions.ellipsis ?? "";
64
+ const ELLIPSIS_WIDTH = truncationOptions?.ellipsisWidth ?? (ELLIPSIS ? getStringTruncatedWidth(ELLIPSIS, NO_TRUNCATION$1, widthOptions).width : 0);
65
+ const ANSI_WIDTH = widthOptions.ansiWidth ?? 0;
66
+ const CONTROL_WIDTH = widthOptions.controlWidth ?? 0;
67
+ const TAB_WIDTH = widthOptions.tabWidth ?? 8;
68
+ const AMBIGUOUS_WIDTH = widthOptions.ambiguousWidth ?? 1;
69
+ const EMOJI_WIDTH = widthOptions.emojiWidth ?? 2;
70
+ const FULL_WIDTH_WIDTH = widthOptions.fullWidthWidth ?? 2;
71
+ const REGULAR_WIDTH = widthOptions.regularWidth ?? 1;
72
+ const WIDE_WIDTH = widthOptions.wideWidth ?? 2;
73
+ let indexPrev = 0;
74
+ let index = 0;
75
+ let length = input.length;
76
+ let lengthExtra = 0;
77
+ let truncationEnabled = false;
78
+ let truncationIndex = length;
79
+ let truncationLimit = Math.max(0, LIMIT - ELLIPSIS_WIDTH);
80
+ let unmatchedStart = 0;
81
+ let unmatchedEnd = 0;
82
+ let width = 0;
83
+ let widthExtra = 0;
84
+ outer: while (true) {
85
+ if (unmatchedEnd > unmatchedStart || index >= length && index > indexPrev) {
86
+ const unmatched = input.slice(unmatchedStart, unmatchedEnd) || input.slice(indexPrev, index);
87
+ lengthExtra = 0;
88
+ for (const char of unmatched.replaceAll(MODIFIER_RE, "")) {
89
+ const codePoint = char.codePointAt(0) || 0;
90
+ if (isFullWidth(codePoint)) widthExtra = FULL_WIDTH_WIDTH;
91
+ else if (isWide(codePoint)) widthExtra = WIDE_WIDTH;
92
+ else if (AMBIGUOUS_WIDTH !== REGULAR_WIDTH && isAmbiguous(codePoint)) widthExtra = AMBIGUOUS_WIDTH;
93
+ else widthExtra = REGULAR_WIDTH;
94
+ if (width + widthExtra > truncationLimit) truncationIndex = Math.min(truncationIndex, Math.max(unmatchedStart, indexPrev) + lengthExtra);
95
+ if (width + widthExtra > LIMIT) {
96
+ truncationEnabled = true;
97
+ break outer;
98
+ }
99
+ lengthExtra += char.length;
100
+ width += widthExtra;
101
+ }
102
+ unmatchedStart = unmatchedEnd = 0;
103
+ }
104
+ if (index >= length) break;
105
+ LATIN_RE.lastIndex = index;
106
+ if (LATIN_RE.test(input)) {
107
+ lengthExtra = LATIN_RE.lastIndex - index;
108
+ widthExtra = lengthExtra * REGULAR_WIDTH;
109
+ if (width + widthExtra > truncationLimit) truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / REGULAR_WIDTH));
110
+ if (width + widthExtra > LIMIT) {
111
+ truncationEnabled = true;
112
+ break;
113
+ }
114
+ width += widthExtra;
115
+ unmatchedStart = indexPrev;
116
+ unmatchedEnd = index;
117
+ index = indexPrev = LATIN_RE.lastIndex;
118
+ continue;
119
+ }
120
+ ANSI_RE.lastIndex = index;
121
+ if (ANSI_RE.test(input)) {
122
+ if (width + ANSI_WIDTH > truncationLimit) truncationIndex = Math.min(truncationIndex, index);
123
+ if (width + ANSI_WIDTH > LIMIT) {
124
+ truncationEnabled = true;
125
+ break;
126
+ }
127
+ width += ANSI_WIDTH;
128
+ unmatchedStart = indexPrev;
129
+ unmatchedEnd = index;
130
+ index = indexPrev = ANSI_RE.lastIndex;
131
+ continue;
132
+ }
133
+ CONTROL_RE.lastIndex = index;
134
+ if (CONTROL_RE.test(input)) {
135
+ lengthExtra = CONTROL_RE.lastIndex - index;
136
+ widthExtra = lengthExtra * CONTROL_WIDTH;
137
+ if (width + widthExtra > truncationLimit) truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / CONTROL_WIDTH));
138
+ if (width + widthExtra > LIMIT) {
139
+ truncationEnabled = true;
140
+ break;
141
+ }
142
+ width += widthExtra;
143
+ unmatchedStart = indexPrev;
144
+ unmatchedEnd = index;
145
+ index = indexPrev = CONTROL_RE.lastIndex;
146
+ continue;
147
+ }
148
+ TAB_RE.lastIndex = index;
149
+ if (TAB_RE.test(input)) {
150
+ lengthExtra = TAB_RE.lastIndex - index;
151
+ widthExtra = lengthExtra * TAB_WIDTH;
152
+ if (width + widthExtra > truncationLimit) truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / TAB_WIDTH));
153
+ if (width + widthExtra > LIMIT) {
154
+ truncationEnabled = true;
155
+ break;
156
+ }
157
+ width += widthExtra;
158
+ unmatchedStart = indexPrev;
159
+ unmatchedEnd = index;
160
+ index = indexPrev = TAB_RE.lastIndex;
161
+ continue;
162
+ }
163
+ EMOJI_RE.lastIndex = index;
164
+ if (EMOJI_RE.test(input)) {
165
+ if (width + EMOJI_WIDTH > truncationLimit) truncationIndex = Math.min(truncationIndex, index);
166
+ if (width + EMOJI_WIDTH > LIMIT) {
167
+ truncationEnabled = true;
168
+ break;
169
+ }
170
+ width += EMOJI_WIDTH;
171
+ unmatchedStart = indexPrev;
172
+ unmatchedEnd = index;
173
+ index = indexPrev = EMOJI_RE.lastIndex;
174
+ continue;
175
+ }
176
+ index += 1;
177
+ }
178
+ return {
179
+ width: truncationEnabled ? truncationLimit : width,
180
+ index: truncationEnabled ? truncationIndex : length,
181
+ truncated: truncationEnabled,
182
+ ellipsed: truncationEnabled && LIMIT >= ELLIPSIS_WIDTH
183
+ };
184
+ };
185
+ //#endregion
186
+ //#region node_modules/.pnpm/fast-string-width@1.1.0/node_modules/fast-string-width/dist/index.js
187
+ const NO_TRUNCATION = {
188
+ limit: Infinity,
189
+ ellipsis: "",
190
+ ellipsisWidth: 0
191
+ };
192
+ const fastStringWidth = (input, options = {}) => {
193
+ return getStringTruncatedWidth(input, NO_TRUNCATION, options).width;
194
+ };
195
+ //#endregion
196
+ //#region node_modules/.pnpm/fast-wrap-ansi@0.1.6/node_modules/fast-wrap-ansi/lib/main.js
197
+ const ESC = "\x1B";
198
+ const CSI = "›";
199
+ const END_CODE = 39;
200
+ const ANSI_ESCAPE_BELL = "\x07";
201
+ const ANSI_CSI = "[";
202
+ const ANSI_OSC = "]";
203
+ const ANSI_SGR_TERMINATOR = "m";
204
+ const ANSI_ESCAPE_LINK = `${ANSI_OSC}8;;`;
205
+ const GROUP_REGEX = new RegExp(`(?:\\${ANSI_CSI}(?<code>\\d+)m|\\${ANSI_ESCAPE_LINK}(?<uri>.*)${ANSI_ESCAPE_BELL})`, "y");
206
+ const getClosingCode = (openingCode) => {
207
+ if (openingCode >= 30 && openingCode <= 37) return 39;
208
+ if (openingCode >= 90 && openingCode <= 97) return 39;
209
+ if (openingCode >= 40 && openingCode <= 47) return 49;
210
+ if (openingCode >= 100 && openingCode <= 107) return 49;
211
+ if (openingCode === 1 || openingCode === 2) return 22;
212
+ if (openingCode === 3) return 23;
213
+ if (openingCode === 4) return 24;
214
+ if (openingCode === 7) return 27;
215
+ if (openingCode === 8) return 28;
216
+ if (openingCode === 9) return 29;
217
+ if (openingCode === 0) return 0;
218
+ };
219
+ const wrapAnsiCode = (code) => `${ESC}${ANSI_CSI}${code}${ANSI_SGR_TERMINATOR}`;
220
+ const wrapAnsiHyperlink = (url) => `${ESC}${ANSI_ESCAPE_LINK}${url}${ANSI_ESCAPE_BELL}`;
221
+ const wrapWord = (rows, word, columns) => {
222
+ const characters = word[Symbol.iterator]();
223
+ let isInsideEscape = false;
224
+ let isInsideLinkEscape = false;
225
+ let lastRow = rows.at(-1);
226
+ let visible = lastRow === void 0 ? 0 : fastStringWidth(lastRow);
227
+ let currentCharacter = characters.next();
228
+ let nextCharacter = characters.next();
229
+ let rawCharacterIndex = 0;
230
+ while (!currentCharacter.done) {
231
+ const character = currentCharacter.value;
232
+ const characterLength = fastStringWidth(character);
233
+ if (visible + characterLength <= columns) rows[rows.length - 1] += character;
234
+ else {
235
+ rows.push(character);
236
+ visible = 0;
237
+ }
238
+ if (character === ESC || character === CSI) {
239
+ isInsideEscape = true;
240
+ isInsideLinkEscape = word.startsWith(ANSI_ESCAPE_LINK, rawCharacterIndex + 1);
241
+ }
242
+ if (isInsideEscape) {
243
+ if (isInsideLinkEscape) {
244
+ if (character === ANSI_ESCAPE_BELL) {
245
+ isInsideEscape = false;
246
+ isInsideLinkEscape = false;
247
+ }
248
+ } else if (character === ANSI_SGR_TERMINATOR) isInsideEscape = false;
249
+ } else {
250
+ visible += characterLength;
251
+ if (visible === columns && !nextCharacter.done) {
252
+ rows.push("");
253
+ visible = 0;
254
+ }
255
+ }
256
+ currentCharacter = nextCharacter;
257
+ nextCharacter = characters.next();
258
+ rawCharacterIndex += character.length;
259
+ }
260
+ lastRow = rows.at(-1);
261
+ if (!visible && lastRow !== void 0 && lastRow.length && rows.length > 1) rows[rows.length - 2] += rows.pop();
262
+ };
263
+ const stringVisibleTrimSpacesRight = (string) => {
264
+ const words = string.split(" ");
265
+ let last = words.length;
266
+ while (last) {
267
+ if (fastStringWidth(words[last - 1])) break;
268
+ last--;
269
+ }
270
+ if (last === words.length) return string;
271
+ return words.slice(0, last).join(" ") + words.slice(last).join("");
272
+ };
273
+ const exec = (string, columns, options = {}) => {
274
+ if (options.trim !== false && string.trim() === "") return "";
275
+ let returnValue = "";
276
+ let escapeCode;
277
+ let escapeUrl;
278
+ const words = string.split(" ");
279
+ let rows = [""];
280
+ let rowLength = 0;
281
+ for (let index = 0; index < words.length; index++) {
282
+ const word = words[index];
283
+ if (options.trim !== false) {
284
+ const row = rows.at(-1) ?? "";
285
+ const trimmed = row.trimStart();
286
+ if (row.length !== trimmed.length) {
287
+ rows[rows.length - 1] = trimmed;
288
+ rowLength = fastStringWidth(trimmed);
289
+ }
290
+ }
291
+ if (index !== 0) {
292
+ if (rowLength >= columns && (options.wordWrap === false || options.trim === false)) {
293
+ rows.push("");
294
+ rowLength = 0;
295
+ }
296
+ if (rowLength || options.trim === false) {
297
+ rows[rows.length - 1] += " ";
298
+ rowLength++;
299
+ }
300
+ }
301
+ const wordLength = fastStringWidth(word);
302
+ if (options.hard && wordLength > columns) {
303
+ const remainingColumns = columns - rowLength;
304
+ const breaksStartingThisLine = 1 + Math.floor((wordLength - remainingColumns - 1) / columns);
305
+ if (Math.floor((wordLength - 1) / columns) < breaksStartingThisLine) rows.push("");
306
+ wrapWord(rows, word, columns);
307
+ rowLength = fastStringWidth(rows.at(-1) ?? "");
308
+ continue;
309
+ }
310
+ if (rowLength + wordLength > columns && rowLength && wordLength) {
311
+ if (options.wordWrap === false && rowLength < columns) {
312
+ wrapWord(rows, word, columns);
313
+ rowLength = fastStringWidth(rows.at(-1) ?? "");
314
+ continue;
315
+ }
316
+ rows.push("");
317
+ rowLength = 0;
318
+ }
319
+ if (rowLength + wordLength > columns && options.wordWrap === false) {
320
+ wrapWord(rows, word, columns);
321
+ rowLength = fastStringWidth(rows.at(-1) ?? "");
322
+ continue;
323
+ }
324
+ rows[rows.length - 1] += word;
325
+ rowLength += wordLength;
326
+ }
327
+ if (options.trim !== false) rows = rows.map((row) => stringVisibleTrimSpacesRight(row));
328
+ const preString = rows.join("\n");
329
+ let inSurrogate = false;
330
+ for (let i = 0; i < preString.length; i++) {
331
+ const character = preString[i];
332
+ returnValue += character;
333
+ if (!inSurrogate) inSurrogate = character >= "\ud800" && character <= "\udbff";
334
+ else continue;
335
+ if (character === ESC || character === CSI) {
336
+ GROUP_REGEX.lastIndex = i + 1;
337
+ const groups = GROUP_REGEX.exec(preString)?.groups;
338
+ if (groups?.code !== void 0) {
339
+ const code = Number.parseFloat(groups.code);
340
+ escapeCode = code === END_CODE ? void 0 : code;
341
+ } else if (groups?.uri !== void 0) escapeUrl = groups.uri.length === 0 ? void 0 : groups.uri;
342
+ }
343
+ if (preString[i + 1] === "\n") {
344
+ if (escapeUrl) returnValue += wrapAnsiHyperlink("");
345
+ const closingCode = escapeCode ? getClosingCode(escapeCode) : void 0;
346
+ if (escapeCode && closingCode) returnValue += wrapAnsiCode(closingCode);
347
+ } else if (character === "\n") {
348
+ if (escapeCode && getClosingCode(escapeCode)) returnValue += wrapAnsiCode(escapeCode);
349
+ if (escapeUrl) returnValue += wrapAnsiHyperlink(escapeUrl);
350
+ }
351
+ }
352
+ return returnValue;
353
+ };
354
+ const CRLF_OR_LF = /\r?\n/;
355
+ function wrapAnsi(string, columns, options) {
356
+ return String(string).normalize().split(CRLF_OR_LF).map((line) => exec(line, columns, options)).join("\n");
357
+ }
358
+ //#endregion
359
+ //#region node_modules/.pnpm/@clack+core@1.2.0/node_modules/@clack/core/dist/index.mjs
40
360
  var import_src = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
41
361
  const ESC = "\x1B";
42
362
  const CSI = `${ESC}[`;
@@ -89,162 +409,12 @@ var import_src = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
89
409
  beep
90
410
  };
91
411
  })))();
92
- function x$1(t, e, s) {
93
- if (!s.some((u) => !u.disabled)) return t;
94
- const i = t + e, r = Math.max(s.length - 1, 0), n = i < 0 ? r : i > r ? 0 : i;
95
- return s[n].disabled ? x$1(n, e < 0 ? -1 : 1, s) : n;
412
+ function d$1(r, t, e) {
413
+ if (!e.some((o) => !o.disabled)) return r;
414
+ const s = r + t, i = Math.max(e.length - 1, 0), n = s < 0 ? i : s > i ? 0 : s;
415
+ return e[n].disabled ? d$1(n, t < 0 ? -1 : 1, e) : n;
96
416
  }
97
- const at = (t) => t === 161 || t === 164 || t === 167 || t === 168 || t === 170 || t === 173 || t === 174 || t >= 176 && t <= 180 || t >= 182 && t <= 186 || t >= 188 && t <= 191 || t === 198 || t === 208 || t === 215 || t === 216 || t >= 222 && t <= 225 || t === 230 || t >= 232 && t <= 234 || t === 236 || t === 237 || t === 240 || t === 242 || t === 243 || t >= 247 && t <= 250 || t === 252 || t === 254 || t === 257 || t === 273 || t === 275 || t === 283 || t === 294 || t === 295 || t === 299 || t >= 305 && t <= 307 || t === 312 || t >= 319 && t <= 322 || t === 324 || t >= 328 && t <= 331 || t === 333 || t === 338 || t === 339 || t === 358 || t === 359 || t === 363 || t === 462 || t === 464 || t === 466 || t === 468 || t === 470 || t === 472 || t === 474 || t === 476 || t === 593 || t === 609 || t === 708 || t === 711 || t >= 713 && t <= 715 || t === 717 || t === 720 || t >= 728 && t <= 731 || t === 733 || t === 735 || t >= 768 && t <= 879 || t >= 913 && t <= 929 || t >= 931 && t <= 937 || t >= 945 && t <= 961 || t >= 963 && t <= 969 || t === 1025 || t >= 1040 && t <= 1103 || t === 1105 || t === 8208 || t >= 8211 && t <= 8214 || t === 8216 || t === 8217 || t === 8220 || t === 8221 || t >= 8224 && t <= 8226 || t >= 8228 && t <= 8231 || t === 8240 || t === 8242 || t === 8243 || t === 8245 || t === 8251 || t === 8254 || t === 8308 || t === 8319 || t >= 8321 && t <= 8324 || t === 8364 || t === 8451 || t === 8453 || t === 8457 || t === 8467 || t === 8470 || t === 8481 || t === 8482 || t === 8486 || t === 8491 || t === 8531 || t === 8532 || t >= 8539 && t <= 8542 || t >= 8544 && t <= 8555 || t >= 8560 && t <= 8569 || t === 8585 || t >= 8592 && t <= 8601 || t === 8632 || t === 8633 || t === 8658 || t === 8660 || t === 8679 || t === 8704 || t === 8706 || t === 8707 || t === 8711 || t === 8712 || t === 8715 || t === 8719 || t === 8721 || t === 8725 || t === 8730 || t >= 8733 && t <= 8736 || t === 8739 || t === 8741 || t >= 8743 && t <= 8748 || t === 8750 || t >= 8756 && t <= 8759 || t === 8764 || t === 8765 || t === 8776 || t === 8780 || t === 8786 || t === 8800 || t === 8801 || t >= 8804 && t <= 8807 || t === 8810 || t === 8811 || t === 8814 || t === 8815 || t === 8834 || t === 8835 || t === 8838 || t === 8839 || t === 8853 || t === 8857 || t === 8869 || t === 8895 || t === 8978 || t >= 9312 && t <= 9449 || t >= 9451 && t <= 9547 || t >= 9552 && t <= 9587 || t >= 9600 && t <= 9615 || t >= 9618 && t <= 9621 || t === 9632 || t === 9633 || t >= 9635 && t <= 9641 || t === 9650 || t === 9651 || t === 9654 || t === 9655 || t === 9660 || t === 9661 || t === 9664 || t === 9665 || t >= 9670 && t <= 9672 || t === 9675 || t >= 9678 && t <= 9681 || t >= 9698 && t <= 9701 || t === 9711 || t === 9733 || t === 9734 || t === 9737 || t === 9742 || t === 9743 || t === 9756 || t === 9758 || t === 9792 || t === 9794 || t === 9824 || t === 9825 || t >= 9827 && t <= 9829 || t >= 9831 && t <= 9834 || t === 9836 || t === 9837 || t === 9839 || t === 9886 || t === 9887 || t === 9919 || t >= 9926 && t <= 9933 || t >= 9935 && t <= 9939 || t >= 9941 && t <= 9953 || t === 9955 || t === 9960 || t === 9961 || t >= 9963 && t <= 9969 || t === 9972 || t >= 9974 && t <= 9977 || t === 9979 || t === 9980 || t === 9982 || t === 9983 || t === 10045 || t >= 10102 && t <= 10111 || t >= 11094 && t <= 11097 || t >= 12872 && t <= 12879 || t >= 57344 && t <= 63743 || t >= 65024 && t <= 65039 || t === 65533 || t >= 127232 && t <= 127242 || t >= 127248 && t <= 127277 || t >= 127280 && t <= 127337 || t >= 127344 && t <= 127373 || t === 127375 || t === 127376 || t >= 127387 && t <= 127404 || t >= 917760 && t <= 917999 || t >= 983040 && t <= 1048573 || t >= 1048576 && t <= 1114109, lt = (t) => t === 12288 || t >= 65281 && t <= 65376 || t >= 65504 && t <= 65510, ht = (t) => t >= 4352 && t <= 4447 || t === 8986 || t === 8987 || t === 9001 || t === 9002 || t >= 9193 && t <= 9196 || t === 9200 || t === 9203 || t === 9725 || t === 9726 || t === 9748 || t === 9749 || t >= 9800 && t <= 9811 || t === 9855 || t === 9875 || t === 9889 || t === 9898 || t === 9899 || t === 9917 || t === 9918 || t === 9924 || t === 9925 || t === 9934 || t === 9940 || t === 9962 || t === 9970 || t === 9971 || t === 9973 || t === 9978 || t === 9981 || t === 9989 || t === 9994 || t === 9995 || t === 10024 || t === 10060 || t === 10062 || t >= 10067 && t <= 10069 || t === 10071 || t >= 10133 && t <= 10135 || t === 10160 || t === 10175 || t === 11035 || t === 11036 || t === 11088 || t === 11093 || t >= 11904 && t <= 11929 || t >= 11931 && t <= 12019 || t >= 12032 && t <= 12245 || t >= 12272 && t <= 12287 || t >= 12289 && t <= 12350 || t >= 12353 && t <= 12438 || t >= 12441 && t <= 12543 || t >= 12549 && t <= 12591 || t >= 12593 && t <= 12686 || t >= 12688 && t <= 12771 || t >= 12783 && t <= 12830 || t >= 12832 && t <= 12871 || t >= 12880 && t <= 19903 || t >= 19968 && t <= 42124 || t >= 42128 && t <= 42182 || t >= 43360 && t <= 43388 || t >= 44032 && t <= 55203 || t >= 63744 && t <= 64255 || t >= 65040 && t <= 65049 || t >= 65072 && t <= 65106 || t >= 65108 && t <= 65126 || t >= 65128 && t <= 65131 || t >= 94176 && t <= 94180 || t === 94192 || t === 94193 || t >= 94208 && t <= 100343 || t >= 100352 && t <= 101589 || t >= 101632 && t <= 101640 || t >= 110576 && t <= 110579 || t >= 110581 && t <= 110587 || t === 110589 || t === 110590 || t >= 110592 && t <= 110882 || t === 110898 || t >= 110928 && t <= 110930 || t === 110933 || t >= 110948 && t <= 110951 || t >= 110960 && t <= 111355 || t === 126980 || t === 127183 || t === 127374 || t >= 127377 && t <= 127386 || t >= 127488 && t <= 127490 || t >= 127504 && t <= 127547 || t >= 127552 && t <= 127560 || t === 127568 || t === 127569 || t >= 127584 && t <= 127589 || t >= 127744 && t <= 127776 || t >= 127789 && t <= 127797 || t >= 127799 && t <= 127868 || t >= 127870 && t <= 127891 || t >= 127904 && t <= 127946 || t >= 127951 && t <= 127955 || t >= 127968 && t <= 127984 || t === 127988 || t >= 127992 && t <= 128062 || t === 128064 || t >= 128066 && t <= 128252 || t >= 128255 && t <= 128317 || t >= 128331 && t <= 128334 || t >= 128336 && t <= 128359 || t === 128378 || t === 128405 || t === 128406 || t === 128420 || t >= 128507 && t <= 128591 || t >= 128640 && t <= 128709 || t === 128716 || t >= 128720 && t <= 128722 || t >= 128725 && t <= 128727 || t >= 128732 && t <= 128735 || t === 128747 || t === 128748 || t >= 128756 && t <= 128764 || t >= 128992 && t <= 129003 || t === 129008 || t >= 129292 && t <= 129338 || t >= 129340 && t <= 129349 || t >= 129351 && t <= 129535 || t >= 129648 && t <= 129660 || t >= 129664 && t <= 129672 || t >= 129680 && t <= 129725 || t >= 129727 && t <= 129733 || t >= 129742 && t <= 129755 || t >= 129760 && t <= 129768 || t >= 129776 && t <= 129784 || t >= 131072 && t <= 196605 || t >= 196608 && t <= 262141, O = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, y = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, L = /\t{1,1000}/y, P = /[\u{1F1E6}-\u{1F1FF}]{2}|\u{1F3F4}[\u{E0061}-\u{E007A}]{2}[\u{E0030}-\u{E0039}\u{E0061}-\u{E007A}]{1,3}\u{E007F}|(?:\p{Emoji}\uFE0F\u20E3?|\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation})(?:\u200D(?:\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation}|\p{Emoji}\uFE0F\u20E3?))*/uy, M = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, ct = /\p{M}+/gu, ft$1 = {
98
- limit: Infinity,
99
- ellipsis: ""
100
- }, X$1 = (t, e = {}, s = {}) => {
101
- const i = e.limit ?? Infinity, r = e.ellipsis ?? "", n = e?.ellipsisWidth ?? (r ? X$1(r, ft$1, s).width : 0), u = s.ansiWidth ?? 0, a = s.controlWidth ?? 0, l = s.tabWidth ?? 8, E = s.ambiguousWidth ?? 1, g = s.emojiWidth ?? 2, m = s.fullWidthWidth ?? 2, A = s.regularWidth ?? 1, V = s.wideWidth ?? 2;
102
- let h = 0, o = 0, p = t.length, v = 0, F = !1, d = p, b = Math.max(0, i - n), C = 0, w = 0, c = 0, f = 0;
103
- t: for (;;) {
104
- if (w > C || o >= p && o > h) {
105
- const ut = t.slice(C, w) || t.slice(h, o);
106
- v = 0;
107
- for (const Y of ut.replaceAll(ct, "")) {
108
- const $ = Y.codePointAt(0) || 0;
109
- if (lt($) ? f = m : ht($) ? f = V : E !== A && at($) ? f = E : f = A, c + f > b && (d = Math.min(d, Math.max(C, h) + v)), c + f > i) {
110
- F = !0;
111
- break t;
112
- }
113
- v += Y.length, c += f;
114
- }
115
- C = w = 0;
116
- }
117
- if (o >= p) break;
118
- if (M.lastIndex = o, M.test(t)) {
119
- if (v = M.lastIndex - o, f = v * A, c + f > b && (d = Math.min(d, o + Math.floor((b - c) / A))), c + f > i) {
120
- F = !0;
121
- break;
122
- }
123
- c += f, C = h, w = o, o = h = M.lastIndex;
124
- continue;
125
- }
126
- if (O.lastIndex = o, O.test(t)) {
127
- if (c + u > b && (d = Math.min(d, o)), c + u > i) {
128
- F = !0;
129
- break;
130
- }
131
- c += u, C = h, w = o, o = h = O.lastIndex;
132
- continue;
133
- }
134
- if (y.lastIndex = o, y.test(t)) {
135
- if (v = y.lastIndex - o, f = v * a, c + f > b && (d = Math.min(d, o + Math.floor((b - c) / a))), c + f > i) {
136
- F = !0;
137
- break;
138
- }
139
- c += f, C = h, w = o, o = h = y.lastIndex;
140
- continue;
141
- }
142
- if (L.lastIndex = o, L.test(t)) {
143
- if (v = L.lastIndex - o, f = v * l, c + f > b && (d = Math.min(d, o + Math.floor((b - c) / l))), c + f > i) {
144
- F = !0;
145
- break;
146
- }
147
- c += f, C = h, w = o, o = h = L.lastIndex;
148
- continue;
149
- }
150
- if (P.lastIndex = o, P.test(t)) {
151
- if (c + g > b && (d = Math.min(d, o)), c + g > i) {
152
- F = !0;
153
- break;
154
- }
155
- c += g, C = h, w = o, o = h = P.lastIndex;
156
- continue;
157
- }
158
- o += 1;
159
- }
160
- return {
161
- width: F ? b : c,
162
- index: F ? d : p,
163
- truncated: F,
164
- ellipsed: F && i >= n
165
- };
166
- }, pt$1 = {
167
- limit: Infinity,
168
- ellipsis: "",
169
- ellipsisWidth: 0
170
- }, S = (t, e = {}) => X$1(t, pt$1, e).width, T = "\x1B", Z = "›", Ft$1 = 39, j = "\x07", Q$1 = "[", dt = "]", tt = "m", U$1 = `${dt}8;;`, et = new RegExp(`(?:\\${Q$1}(?<code>\\d+)m|\\${U$1}(?<uri>.*)${j})`, "y"), mt$1 = (t) => {
171
- if (t >= 30 && t <= 37 || t >= 90 && t <= 97) return 39;
172
- if (t >= 40 && t <= 47 || t >= 100 && t <= 107) return 49;
173
- if (t === 1 || t === 2) return 22;
174
- if (t === 3) return 23;
175
- if (t === 4) return 24;
176
- if (t === 7) return 27;
177
- if (t === 8) return 28;
178
- if (t === 9) return 29;
179
- if (t === 0) return 0;
180
- }, st = (t) => `${T}${Q$1}${t}${tt}`, it = (t) => `${T}${U$1}${t}${j}`, gt$1 = (t) => t.map((e) => S(e)), G = (t, e, s) => {
181
- const i = e[Symbol.iterator]();
182
- let r = !1, n = !1, u = t.at(-1), a = u === void 0 ? 0 : S(u), l = i.next(), E = i.next(), g = 0;
183
- for (; !l.done;) {
184
- const m = l.value, A = S(m);
185
- a + A <= s ? t[t.length - 1] += m : (t.push(m), a = 0), (m === T || m === Z) && (r = !0, n = e.startsWith(U$1, g + 1)), r ? n ? m === j && (r = !1, n = !1) : m === tt && (r = !1) : (a += A, a === s && !E.done && (t.push(""), a = 0)), l = E, E = i.next(), g += m.length;
186
- }
187
- u = t.at(-1), !a && u !== void 0 && u.length > 0 && t.length > 1 && (t[t.length - 2] += t.pop());
188
- }, vt$1 = (t) => {
189
- const e = t.split(" ");
190
- let s = e.length;
191
- for (; s > 0 && !(S(e[s - 1]) > 0);) s--;
192
- return s === e.length ? t : e.slice(0, s).join(" ") + e.slice(s).join("");
193
- }, Et$1 = (t, e, s = {}) => {
194
- if (s.trim !== !1 && t.trim() === "") return "";
195
- let i = "", r, n;
196
- const u = t.split(" "), a = gt$1(u);
197
- let l = [""];
198
- for (const [h, o] of u.entries()) {
199
- s.trim !== !1 && (l[l.length - 1] = (l.at(-1) ?? "").trimStart());
200
- let p = S(l.at(-1) ?? "");
201
- if (h !== 0 && (p >= e && (s.wordWrap === !1 || s.trim === !1) && (l.push(""), p = 0), (p > 0 || s.trim === !1) && (l[l.length - 1] += " ", p++)), s.hard && a[h] > e) {
202
- const v = e - p, F = 1 + Math.floor((a[h] - v - 1) / e);
203
- Math.floor((a[h] - 1) / e) < F && l.push(""), G(l, o, e);
204
- continue;
205
- }
206
- if (p + a[h] > e && p > 0 && a[h] > 0) {
207
- if (s.wordWrap === !1 && p < e) {
208
- G(l, o, e);
209
- continue;
210
- }
211
- l.push("");
212
- }
213
- if (p + a[h] > e && s.wordWrap === !1) {
214
- G(l, o, e);
215
- continue;
216
- }
217
- l[l.length - 1] += o;
218
- }
219
- s.trim !== !1 && (l = l.map((h) => vt$1(h)));
220
- const E = l.join(`
221
- `), g = E[Symbol.iterator]();
222
- let m = g.next(), A = g.next(), V = 0;
223
- for (; !m.done;) {
224
- const h = m.value, o = A.value;
225
- if (i += h, h === T || h === Z) {
226
- et.lastIndex = V + 1;
227
- const F = et.exec(E)?.groups;
228
- if (F?.code !== void 0) {
229
- const d = Number.parseFloat(F.code);
230
- r = d === Ft$1 ? void 0 : d;
231
- } else F?.uri !== void 0 && (n = F.uri.length === 0 ? void 0 : F.uri);
232
- }
233
- const p = r ? mt$1(r) : void 0;
234
- o === `
235
- ` ? (n && (i += it("")), r && p && (i += st(p))) : h === `
236
- ` && (r && p && (i += st(r)), n && (i += it(n))), V += h.length, m = A, A = g.next();
237
- }
238
- return i;
239
- };
240
- function K$1(t, e, s) {
241
- return String(t).normalize().replaceAll(`\r
242
- `, `
243
- `).split(`
244
- `).map((i) => Et$1(i, e, s)).join(`
245
- `);
246
- }
247
- const _ = {
417
+ const u = {
248
418
  actions: new Set([
249
419
  "up",
250
420
  "down",
@@ -266,45 +436,68 @@ const _ = {
266
436
  cancel: "Canceled",
267
437
  error: "Something went wrong"
268
438
  },
269
- withGuide: !0
439
+ withGuide: !0,
440
+ date: {
441
+ monthNames: [...[
442
+ "January",
443
+ "February",
444
+ "March",
445
+ "April",
446
+ "May",
447
+ "June",
448
+ "July",
449
+ "August",
450
+ "September",
451
+ "October",
452
+ "November",
453
+ "December"
454
+ ]],
455
+ messages: {
456
+ required: "Please enter a valid date",
457
+ invalidMonth: "There are only 12 months in a year",
458
+ invalidDay: (r, t) => `There are only ${r} days in ${t}`,
459
+ afterMin: (r) => `Date must be on or after ${r.toISOString().slice(0, 10)}`,
460
+ beforeMax: (r) => `Date must be on or before ${r.toISOString().slice(0, 10)}`
461
+ }
462
+ }
270
463
  };
271
- function H$1(t, e) {
272
- if (typeof t == "string") return _.aliases.get(t) === e;
273
- for (const s of t) if (s !== void 0 && H$1(s, e)) return !0;
464
+ function V$1(r, t) {
465
+ if (typeof r == "string") return u.aliases.get(r) === t;
466
+ for (const e of r) if (e !== void 0 && V$1(e, t)) return !0;
274
467
  return !1;
275
468
  }
276
- function _t$1(t, e) {
277
- if (t === e) return;
278
- const s = t.split(`
279
- `), i = e.split(`
280
- `), r = Math.max(s.length, i.length), n = [];
281
- for (let u = 0; u < r; u++) s[u] !== i[u] && n.push(u);
469
+ function j(r, t) {
470
+ if (r === t) return;
471
+ const e = r.split(`
472
+ `), s = t.split(`
473
+ `), i = Math.max(e.length, s.length), n = [];
474
+ for (let o = 0; o < i; o++) e[o] !== s[o] && n.push(o);
282
475
  return {
283
476
  lines: n,
284
- numLinesBefore: s.length,
285
- numLinesAfter: i.length,
286
- numLines: r
477
+ numLinesBefore: e.length,
478
+ numLinesAfter: s.length,
479
+ numLines: i
287
480
  };
288
481
  }
289
482
  globalThis.process.platform.startsWith("win");
290
- const z$1 = Symbol("clack:cancel");
291
- function Ct$1(t) {
292
- return t === z$1;
483
+ const C = Symbol("clack:cancel");
484
+ function q(r) {
485
+ return r === C;
293
486
  }
294
- function W$1(t, e) {
295
- const s = t;
296
- s.isTTY && s.setRawMode(e);
487
+ function w$1(r, t) {
488
+ const e = r;
489
+ e.isTTY && e.setRawMode(t);
297
490
  }
298
- const rt = (t) => "columns" in t && typeof t.columns == "number" ? t.columns : 80, nt = (t) => "rows" in t && typeof t.rows == "number" ? t.rows : 20;
299
- function Bt$1(t, e, s, i = s) {
300
- return K$1(e, rt(t ?? stdout) - s.length, {
491
+ const O$1 = (r) => "columns" in r && typeof r.columns == "number" ? r.columns : 80, A = (r) => "rows" in r && typeof r.rows == "number" ? r.rows : 20;
492
+ function R(r, t, e, s = e) {
493
+ return wrapAnsi(t, O$1(r ?? stdout) - e.length, {
301
494
  hard: !0,
302
495
  trim: !1
303
496
  }).split(`
304
- `).map((n, u) => `${u === 0 ? i : s}${n}`).join(`
497
+ `).map((n, o) => `${o === 0 ? s : e}${n}`).join(`
305
498
  `);
306
499
  }
307
- var B = class {
500
+ let p = class {
308
501
  input;
309
502
  output;
310
503
  _abortSignal;
@@ -319,60 +512,60 @@ var B = class {
319
512
  error = "";
320
513
  value;
321
514
  userInput = "";
322
- constructor(e, s = !0) {
323
- const { input: i = stdin, output: r = stdout, render: n, signal: u, ...a } = e;
324
- this.opts = a, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = s, this._abortSignal = u, this.input = i, this.output = r;
515
+ constructor(t, e = !0) {
516
+ const { input: s = stdin, output: i = stdout, render: n, signal: o, ...a } = t;
517
+ this.opts = a, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = e, this._abortSignal = o, this.input = s, this.output = i;
325
518
  }
326
519
  unsubscribe() {
327
520
  this._subscribers.clear();
328
521
  }
329
- setSubscriber(e, s) {
330
- const i = this._subscribers.get(e) ?? [];
331
- i.push(s), this._subscribers.set(e, i);
522
+ setSubscriber(t, e) {
523
+ const s = this._subscribers.get(t) ?? [];
524
+ s.push(e), this._subscribers.set(t, s);
332
525
  }
333
- on(e, s) {
334
- this.setSubscriber(e, { cb: s });
526
+ on(t, e) {
527
+ this.setSubscriber(t, { cb: e });
335
528
  }
336
- once(e, s) {
337
- this.setSubscriber(e, {
338
- cb: s,
529
+ once(t, e) {
530
+ this.setSubscriber(t, {
531
+ cb: e,
339
532
  once: !0
340
533
  });
341
534
  }
342
- emit(e, ...s) {
343
- const i = this._subscribers.get(e) ?? [], r = [];
344
- for (const n of i) n.cb(...s), n.once && r.push(() => i.splice(i.indexOf(n), 1));
345
- for (const n of r) n();
535
+ emit(t, ...e) {
536
+ const s = this._subscribers.get(t) ?? [], i = [];
537
+ for (const n of s) n.cb(...e), n.once && i.push(() => s.splice(s.indexOf(n), 1));
538
+ for (const n of i) n();
346
539
  }
347
540
  prompt() {
348
- return new Promise((e) => {
541
+ return new Promise((t) => {
349
542
  if (this._abortSignal) {
350
- if (this._abortSignal.aborted) return this.state = "cancel", this.close(), e(z$1);
543
+ if (this._abortSignal.aborted) return this.state = "cancel", this.close(), t(C);
351
544
  this._abortSignal.addEventListener("abort", () => {
352
545
  this.state = "cancel", this.close();
353
546
  }, { once: !0 });
354
547
  }
355
- this.rl = ot.createInterface({
548
+ this.rl = P$1.createInterface({
356
549
  input: this.input,
357
550
  tabSize: 2,
358
551
  prompt: "",
359
552
  escapeCodeTimeout: 50,
360
553
  terminal: !0
361
- }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, !0), this.input.on("keypress", this.onKeypress), W$1(this.input, !0), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
362
- this.output.write(import_src.cursor.show), this.output.off("resize", this.render), W$1(this.input, !1), e(this.value);
554
+ }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, !0), this.input.on("keypress", this.onKeypress), w$1(this.input, !0), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
555
+ this.output.write(import_src.cursor.show), this.output.off("resize", this.render), w$1(this.input, !1), t(this.value);
363
556
  }), this.once("cancel", () => {
364
- this.output.write(import_src.cursor.show), this.output.off("resize", this.render), W$1(this.input, !1), e(z$1);
557
+ this.output.write(import_src.cursor.show), this.output.off("resize", this.render), w$1(this.input, !1), t(C);
365
558
  });
366
559
  });
367
560
  }
368
- _isActionKey(e, s) {
369
- return e === " ";
561
+ _isActionKey(t, e) {
562
+ return t === " ";
370
563
  }
371
- _setValue(e) {
372
- this.value = e, this.emit("value", this.value);
564
+ _setValue(t) {
565
+ this.value = t, this.emit("value", this.value);
373
566
  }
374
- _setUserInput(e, s) {
375
- this.userInput = e ?? "", this.emit("userInput", this.userInput), s && this._track && this.rl && (this.rl.write(this.userInput), this._cursor = this.rl.cursor);
567
+ _setUserInput(t, e) {
568
+ this.userInput = t ?? "", this.emit("userInput", this.userInput), e && this._track && this.rl && (this.rl.write(this.userInput), this._cursor = this.rl.cursor);
376
569
  }
377
570
  _clearUserInput() {
378
571
  this.rl?.write(null, {
@@ -380,130 +573,132 @@ var B = class {
380
573
  name: "u"
381
574
  }), this._setUserInput("");
382
575
  }
383
- onKeypress(e, s) {
384
- if (this._track && s.name !== "return" && (s.name && this._isActionKey(e, s) && this.rl?.write(null, {
576
+ onKeypress(t, e) {
577
+ if (this._track && e.name !== "return" && (e.name && this._isActionKey(t, e) && this.rl?.write(null, {
385
578
  ctrl: !0,
386
579
  name: "h"
387
- }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), s?.name && (!this._track && _.aliases.has(s.name) && this.emit("cursor", _.aliases.get(s.name)), _.actions.has(s.name) && this.emit("cursor", s.name)), e && (e.toLowerCase() === "y" || e.toLowerCase() === "n") && this.emit("confirm", e.toLowerCase() === "y"), this.emit("key", e?.toLowerCase(), s), s?.name === "return") {
580
+ }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && u.aliases.has(e.name) && this.emit("cursor", u.aliases.get(e.name)), u.actions.has(e.name) && this.emit("cursor", e.name)), t && (t.toLowerCase() === "y" || t.toLowerCase() === "n") && this.emit("confirm", t.toLowerCase() === "y"), this.emit("key", t?.toLowerCase(), e), e?.name === "return") {
388
581
  if (this.opts.validate) {
389
- const i = this.opts.validate(this.value);
390
- i && (this.error = i instanceof Error ? i.message : i, this.state = "error", this.rl?.write(this.userInput));
582
+ const s = this.opts.validate(this.value);
583
+ s && (this.error = s instanceof Error ? s.message : s, this.state = "error", this.rl?.write(this.userInput));
391
584
  }
392
585
  this.state !== "error" && (this.state = "submit");
393
586
  }
394
- H$1([
395
- e,
396
- s?.name,
397
- s?.sequence
587
+ V$1([
588
+ t,
589
+ e?.name,
590
+ e?.sequence
398
591
  ], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
399
592
  }
400
593
  close() {
401
594
  this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
402
- `), W$1(this.input, !1), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
595
+ `), w$1(this.input, !1), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
403
596
  }
404
597
  restoreCursor() {
405
- const e = K$1(this._prevFrame, process.stdout.columns, {
598
+ const t = wrapAnsi(this._prevFrame, process.stdout.columns, {
406
599
  hard: !0,
407
600
  trim: !1
408
601
  }).split(`
409
602
  `).length - 1;
410
- this.output.write(import_src.cursor.move(-999, e * -1));
603
+ this.output.write(import_src.cursor.move(-999, t * -1));
411
604
  }
412
605
  render() {
413
- const e = K$1(this._render(this) ?? "", process.stdout.columns, {
606
+ const t = wrapAnsi(this._render(this) ?? "", process.stdout.columns, {
414
607
  hard: !0,
415
608
  trim: !1
416
609
  });
417
- if (e !== this._prevFrame) {
610
+ if (t !== this._prevFrame) {
418
611
  if (this.state === "initial") this.output.write(import_src.cursor.hide);
419
612
  else {
420
- const s = _t$1(this._prevFrame, e), i = nt(this.output);
421
- if (this.restoreCursor(), s) {
422
- const r = Math.max(0, s.numLinesAfter - i), n = Math.max(0, s.numLinesBefore - i);
423
- let u = s.lines.find((a) => a >= r);
424
- if (u === void 0) {
425
- this._prevFrame = e;
613
+ const e = j(this._prevFrame, t), s = A(this.output);
614
+ if (this.restoreCursor(), e) {
615
+ const i = Math.max(0, e.numLinesAfter - s), n = Math.max(0, e.numLinesBefore - s);
616
+ let o = e.lines.find((a) => a >= i);
617
+ if (o === void 0) {
618
+ this._prevFrame = t;
426
619
  return;
427
620
  }
428
- if (s.lines.length === 1) {
429
- this.output.write(import_src.cursor.move(0, u - n)), this.output.write(import_src.erase.lines(1));
430
- const a = e.split(`
621
+ if (e.lines.length === 1) {
622
+ this.output.write(import_src.cursor.move(0, o - n)), this.output.write(import_src.erase.lines(1));
623
+ const a = t.split(`
431
624
  `);
432
- this.output.write(a[u]), this._prevFrame = e, this.output.write(import_src.cursor.move(0, a.length - u - 1));
625
+ this.output.write(a[o]), this._prevFrame = t, this.output.write(import_src.cursor.move(0, a.length - o - 1));
433
626
  return;
434
- } else if (s.lines.length > 1) {
435
- if (r < n) u = r;
627
+ } else if (e.lines.length > 1) {
628
+ if (i < n) o = i;
436
629
  else {
437
- const l = u - n;
438
- l > 0 && this.output.write(import_src.cursor.move(0, l));
630
+ const h = o - n;
631
+ h > 0 && this.output.write(import_src.cursor.move(0, h));
439
632
  }
440
633
  this.output.write(import_src.erase.down());
441
- const a = e.split(`
442
- `).slice(u);
634
+ const a = t.split(`
635
+ `).slice(o);
443
636
  this.output.write(a.join(`
444
- `)), this._prevFrame = e;
637
+ `)), this._prevFrame = t;
445
638
  return;
446
639
  }
447
640
  }
448
641
  this.output.write(import_src.erase.down());
449
642
  }
450
- this.output.write(e), this.state === "initial" && (this.state = "active"), this._prevFrame = e;
643
+ this.output.write(t), this.state === "initial" && (this.state = "active"), this._prevFrame = t;
451
644
  }
452
645
  }
453
646
  };
454
- var kt$1 = class extends B {
647
+ var Q$1 = class extends p {
455
648
  get cursor() {
456
649
  return this.value ? 0 : 1;
457
650
  }
458
651
  get _value() {
459
652
  return this.cursor === 0;
460
653
  }
461
- constructor(e) {
462
- super(e, !1), this.value = !!e.initialValue, this.on("userInput", () => {
654
+ constructor(t) {
655
+ super(t, !1), this.value = !!t.initialValue, this.on("userInput", () => {
463
656
  this.value = this._value;
464
- }), this.on("confirm", (s) => {
465
- this.output.write(import_src.cursor.move(0, -1)), this.value = s, this.state = "submit", this.close();
657
+ }), this.on("confirm", (e) => {
658
+ this.output.write(import_src.cursor.move(0, -1)), this.value = e, this.state = "submit", this.close();
466
659
  }), this.on("cursor", () => {
467
660
  this.value = !this.value;
468
661
  });
469
662
  }
470
663
  };
471
- let Lt$1 = class extends B {
664
+ let it$1 = class extends p {
472
665
  options;
473
666
  cursor = 0;
474
667
  get _value() {
475
668
  return this.options[this.cursor].value;
476
669
  }
477
670
  get _enabledOptions() {
478
- return this.options.filter((e) => e.disabled !== !0);
671
+ return this.options.filter((t) => t.disabled !== !0);
479
672
  }
480
673
  toggleAll() {
481
- const e = this._enabledOptions;
482
- this.value = this.value !== void 0 && this.value.length === e.length ? [] : e.map((i) => i.value);
674
+ const t = this._enabledOptions, e = this.value !== void 0 && this.value.length === t.length;
675
+ this.value = e ? [] : t.map((s) => s.value);
483
676
  }
484
677
  toggleInvert() {
485
- const e = this.value;
486
- if (!e) return;
487
- this.value = this._enabledOptions.filter((i) => !e.includes(i.value)).map((i) => i.value);
678
+ const t = this.value;
679
+ if (!t) return;
680
+ const e = this._enabledOptions.filter((s) => !t.includes(s.value));
681
+ this.value = e.map((s) => s.value);
488
682
  }
489
683
  toggleValue() {
490
684
  this.value === void 0 && (this.value = []);
491
- this.value = this.value.includes(this._value) ? this.value.filter((s) => s !== this._value) : [...this.value, this._value];
492
- }
493
- constructor(e) {
494
- super(e, !1), this.options = e.options, this.value = [...e.initialValues ?? []];
495
- const s = Math.max(this.options.findIndex(({ value: i }) => i === e.cursorAt), 0);
496
- this.cursor = this.options[s].disabled ? x$1(s, 1, this.options) : s, this.on("key", (i) => {
497
- i === "a" && this.toggleAll(), i === "i" && this.toggleInvert();
498
- }), this.on("cursor", (i) => {
499
- switch (i) {
685
+ const t = this.value.includes(this._value);
686
+ this.value = t ? this.value.filter((e) => e !== this._value) : [...this.value, this._value];
687
+ }
688
+ constructor(t) {
689
+ super(t, !1), this.options = t.options, this.value = [...t.initialValues ?? []];
690
+ const e = Math.max(this.options.findIndex(({ value: s }) => s === t.cursorAt), 0);
691
+ this.cursor = this.options[e].disabled ? d$1(e, 1, this.options) : e, this.on("key", (s) => {
692
+ s === "a" && this.toggleAll(), s === "i" && this.toggleInvert();
693
+ }), this.on("cursor", (s) => {
694
+ switch (s) {
500
695
  case "left":
501
696
  case "up":
502
- this.cursor = x$1(this.cursor, -1, this.options);
697
+ this.cursor = d$1(this.cursor, -1, this.options);
503
698
  break;
504
699
  case "down":
505
700
  case "right":
506
- this.cursor = x$1(this.cursor, 1, this.options);
701
+ this.cursor = d$1(this.cursor, 1, this.options);
507
702
  break;
508
703
  case "space":
509
704
  this.toggleValue();
@@ -512,7 +707,7 @@ let Lt$1 = class extends B {
512
707
  });
513
708
  }
514
709
  };
515
- var Tt$1 = class extends B {
710
+ var nt$1 = class extends p {
516
711
  options;
517
712
  cursor = 0;
518
713
  get _selectedValue() {
@@ -521,363 +716,214 @@ var Tt$1 = class extends B {
521
716
  changeValue() {
522
717
  this.value = this._selectedValue.value;
523
718
  }
524
- constructor(e) {
525
- super(e, !1), this.options = e.options;
526
- const s = this.options.findIndex(({ value: r }) => r === e.initialValue), i = s === -1 ? 0 : s;
527
- this.cursor = this.options[i].disabled ? x$1(i, 1, this.options) : i, this.changeValue(), this.on("cursor", (r) => {
528
- switch (r) {
719
+ constructor(t) {
720
+ super(t, !1), this.options = t.options;
721
+ const e = this.options.findIndex(({ value: i }) => i === t.initialValue), s = e === -1 ? 0 : e;
722
+ this.cursor = this.options[s].disabled ? d$1(s, 1, this.options) : s, this.changeValue(), this.on("cursor", (i) => {
723
+ switch (i) {
529
724
  case "left":
530
725
  case "up":
531
- this.cursor = x$1(this.cursor, -1, this.options);
726
+ this.cursor = d$1(this.cursor, -1, this.options);
532
727
  break;
533
728
  case "down":
534
729
  case "right":
535
- this.cursor = x$1(this.cursor, 1, this.options);
730
+ this.cursor = d$1(this.cursor, 1, this.options);
536
731
  break;
537
732
  }
538
733
  this.changeValue();
539
734
  });
540
735
  }
541
736
  };
542
- var $t = class extends B {
737
+ var at$1 = class extends p {
543
738
  get userInputWithCursor() {
544
739
  if (this.state === "submit") return this.userInput;
545
- const e = this.userInput;
546
- if (this.cursor >= e.length) return `${this.userInput}\u2588`;
547
- const s = e.slice(0, this.cursor), [i, ...r] = e.slice(this.cursor);
548
- return `${s}${styleText("inverse", i)}${r.join("")}`;
740
+ const t = this.userInput;
741
+ if (this.cursor >= t.length) return `${this.userInput}\u2588`;
742
+ const e = t.slice(0, this.cursor), [s, ...i] = t.slice(this.cursor);
743
+ return `${e}${styleText("inverse", s)}${i.join("")}`;
549
744
  }
550
745
  get cursor() {
551
746
  return this._cursor;
552
747
  }
553
- constructor(e) {
748
+ constructor(t) {
554
749
  super({
555
- ...e,
556
- initialUserInput: e.initialUserInput ?? e.initialValue
557
- }), this.on("userInput", (s) => {
558
- this._setValue(s);
750
+ ...t,
751
+ initialUserInput: t.initialUserInput ?? t.initialValue
752
+ }), this.on("userInput", (e) => {
753
+ this._setValue(e);
559
754
  }), this.on("finalize", () => {
560
- this.value || (this.value = e.defaultValue), this.value === void 0 && (this.value = "");
755
+ this.value || (this.value = t.defaultValue), this.value === void 0 && (this.value = "");
561
756
  });
562
757
  }
563
758
  };
564
759
  //#endregion
565
- //#region node_modules/.pnpm/@clack+prompts@1.1.0/node_modules/@clack/prompts/dist/index.mjs
566
- function pt() {
567
- return N.platform !== "win32" ? N.env.TERM !== "linux" : !!N.env.CI || !!N.env.WT_SESSION || !!N.env.TERMINUS_SUBLIME || N.env.ConEmuTask === "{cmd::Cmder}" || N.env.TERM_PROGRAM === "Terminus-Sublime" || N.env.TERM_PROGRAM === "vscode" || N.env.TERM === "xterm-256color" || N.env.TERM === "alacritty" || N.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
760
+ //#region node_modules/.pnpm/@clack+prompts@1.2.0/node_modules/@clack/prompts/dist/index.mjs
761
+ function Ze() {
762
+ return P.platform !== "win32" ? P.env.TERM !== "linux" : !!P.env.CI || !!P.env.WT_SESSION || !!P.env.TERMINUS_SUBLIME || P.env.ConEmuTask === "{cmd::Cmder}" || P.env.TERM_PROGRAM === "Terminus-Sublime" || P.env.TERM_PROGRAM === "vscode" || P.env.TERM === "xterm-256color" || P.env.TERM === "alacritty" || P.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
568
763
  }
569
- const ee = pt(), I = (e, r) => ee ? e : r, Re = I("◆", "*"), $e = I("■", "x"), de = I("▲", "x"), V = I("◇", "o"), he = I("┌", "T"), h = I("│", "|"), x = I("└", "—");
570
- I("┐", "T");
571
- I("┘", "—");
572
- const z = I("●", ">"), H = I("○", " "), te = I("◻", "[•]"), U = I("◼", "[+]"), q = I("◻", "[ ]");
573
- I("▪", "•");
574
- I("─", "-");
575
- I("╮", "+");
576
- I("├", "+");
577
- I("╯", "+");
578
- I("╰", "+");
579
- I("╭", "+");
580
- const fe = I("●", "•"), Fe = I("◆", "*"), ye = I("▲", "!"), Ee = I("■", "x"), W = (e) => {
764
+ const ee = Ze(), w = (e, i) => ee ? e : i, _e = w("◆", "*"), oe = w("■", "x"), ue = w("▲", "x"), F = w("◇", "o"), le = w("┌", "T"), d = w("│", "|"), E = w("└", "—");
765
+ w("┐", "T");
766
+ w("┘", "—");
767
+ const z = w("●", ">"), H = w("○", " "), te = w("◻", "[•]"), U = w("◼", "[+]"), J = w("◻", "[ ]");
768
+ w("▪", "•");
769
+ w("─", "-");
770
+ w("╮", "+");
771
+ w("├", "+");
772
+ w("╯", "+");
773
+ w("╰", "+");
774
+ w("╭", "+");
775
+ const he = w("●", "•"), pe = w("◆", "*"), me = w("▲", "!"), ge = w("■", "x"), V = (e) => {
581
776
  switch (e) {
582
777
  case "initial":
583
- case "active": return styleText("cyan", Re);
584
- case "cancel": return styleText("red", $e);
585
- case "error": return styleText("yellow", de);
586
- case "submit": return styleText("green", V);
778
+ case "active": return styleText("cyan", _e);
779
+ case "cancel": return styleText("red", oe);
780
+ case "error": return styleText("yellow", ue);
781
+ case "submit": return styleText("green", F);
587
782
  }
588
- }, ve = (e) => {
783
+ }, ye = (e) => {
589
784
  switch (e) {
590
785
  case "initial":
591
- case "active": return styleText("cyan", h);
592
- case "cancel": return styleText("red", h);
593
- case "error": return styleText("yellow", h);
594
- case "submit": return styleText("green", h);
595
- }
596
- }, mt = (e) => e === 161 || e === 164 || e === 167 || e === 168 || e === 170 || e === 173 || e === 174 || e >= 176 && e <= 180 || e >= 182 && e <= 186 || e >= 188 && e <= 191 || e === 198 || e === 208 || e === 215 || e === 216 || e >= 222 && e <= 225 || e === 230 || e >= 232 && e <= 234 || e === 236 || e === 237 || e === 240 || e === 242 || e === 243 || e >= 247 && e <= 250 || e === 252 || e === 254 || e === 257 || e === 273 || e === 275 || e === 283 || e === 294 || e === 295 || e === 299 || e >= 305 && e <= 307 || e === 312 || e >= 319 && e <= 322 || e === 324 || e >= 328 && e <= 331 || e === 333 || e === 338 || e === 339 || e === 358 || e === 359 || e === 363 || e === 462 || e === 464 || e === 466 || e === 468 || e === 470 || e === 472 || e === 474 || e === 476 || e === 593 || e === 609 || e === 708 || e === 711 || e >= 713 && e <= 715 || e === 717 || e === 720 || e >= 728 && e <= 731 || e === 733 || e === 735 || e >= 768 && e <= 879 || e >= 913 && e <= 929 || e >= 931 && e <= 937 || e >= 945 && e <= 961 || e >= 963 && e <= 969 || e === 1025 || e >= 1040 && e <= 1103 || e === 1105 || e === 8208 || e >= 8211 && e <= 8214 || e === 8216 || e === 8217 || e === 8220 || e === 8221 || e >= 8224 && e <= 8226 || e >= 8228 && e <= 8231 || e === 8240 || e === 8242 || e === 8243 || e === 8245 || e === 8251 || e === 8254 || e === 8308 || e === 8319 || e >= 8321 && e <= 8324 || e === 8364 || e === 8451 || e === 8453 || e === 8457 || e === 8467 || e === 8470 || e === 8481 || e === 8482 || e === 8486 || e === 8491 || e === 8531 || e === 8532 || e >= 8539 && e <= 8542 || e >= 8544 && e <= 8555 || e >= 8560 && e <= 8569 || e === 8585 || e >= 8592 && e <= 8601 || e === 8632 || e === 8633 || e === 8658 || e === 8660 || e === 8679 || e === 8704 || e === 8706 || e === 8707 || e === 8711 || e === 8712 || e === 8715 || e === 8719 || e === 8721 || e === 8725 || e === 8730 || e >= 8733 && e <= 8736 || e === 8739 || e === 8741 || e >= 8743 && e <= 8748 || e === 8750 || e >= 8756 && e <= 8759 || e === 8764 || e === 8765 || e === 8776 || e === 8780 || e === 8786 || e === 8800 || e === 8801 || e >= 8804 && e <= 8807 || e === 8810 || e === 8811 || e === 8814 || e === 8815 || e === 8834 || e === 8835 || e === 8838 || e === 8839 || e === 8853 || e === 8857 || e === 8869 || e === 8895 || e === 8978 || e >= 9312 && e <= 9449 || e >= 9451 && e <= 9547 || e >= 9552 && e <= 9587 || e >= 9600 && e <= 9615 || e >= 9618 && e <= 9621 || e === 9632 || e === 9633 || e >= 9635 && e <= 9641 || e === 9650 || e === 9651 || e === 9654 || e === 9655 || e === 9660 || e === 9661 || e === 9664 || e === 9665 || e >= 9670 && e <= 9672 || e === 9675 || e >= 9678 && e <= 9681 || e >= 9698 && e <= 9701 || e === 9711 || e === 9733 || e === 9734 || e === 9737 || e === 9742 || e === 9743 || e === 9756 || e === 9758 || e === 9792 || e === 9794 || e === 9824 || e === 9825 || e >= 9827 && e <= 9829 || e >= 9831 && e <= 9834 || e === 9836 || e === 9837 || e === 9839 || e === 9886 || e === 9887 || e === 9919 || e >= 9926 && e <= 9933 || e >= 9935 && e <= 9939 || e >= 9941 && e <= 9953 || e === 9955 || e === 9960 || e === 9961 || e >= 9963 && e <= 9969 || e === 9972 || e >= 9974 && e <= 9977 || e === 9979 || e === 9980 || e === 9982 || e === 9983 || e === 10045 || e >= 10102 && e <= 10111 || e >= 11094 && e <= 11097 || e >= 12872 && e <= 12879 || e >= 57344 && e <= 63743 || e >= 65024 && e <= 65039 || e === 65533 || e >= 127232 && e <= 127242 || e >= 127248 && e <= 127277 || e >= 127280 && e <= 127337 || e >= 127344 && e <= 127373 || e === 127375 || e === 127376 || e >= 127387 && e <= 127404 || e >= 917760 && e <= 917999 || e >= 983040 && e <= 1048573 || e >= 1048576 && e <= 1114109, gt = (e) => e === 12288 || e >= 65281 && e <= 65376 || e >= 65504 && e <= 65510, ft = (e) => e >= 4352 && e <= 4447 || e === 8986 || e === 8987 || e === 9001 || e === 9002 || e >= 9193 && e <= 9196 || e === 9200 || e === 9203 || e === 9725 || e === 9726 || e === 9748 || e === 9749 || e >= 9800 && e <= 9811 || e === 9855 || e === 9875 || e === 9889 || e === 9898 || e === 9899 || e === 9917 || e === 9918 || e === 9924 || e === 9925 || e === 9934 || e === 9940 || e === 9962 || e === 9970 || e === 9971 || e === 9973 || e === 9978 || e === 9981 || e === 9989 || e === 9994 || e === 9995 || e === 10024 || e === 10060 || e === 10062 || e >= 10067 && e <= 10069 || e === 10071 || e >= 10133 && e <= 10135 || e === 10160 || e === 10175 || e === 11035 || e === 11036 || e === 11088 || e === 11093 || e >= 11904 && e <= 11929 || e >= 11931 && e <= 12019 || e >= 12032 && e <= 12245 || e >= 12272 && e <= 12287 || e >= 12289 && e <= 12350 || e >= 12353 && e <= 12438 || e >= 12441 && e <= 12543 || e >= 12549 && e <= 12591 || e >= 12593 && e <= 12686 || e >= 12688 && e <= 12771 || e >= 12783 && e <= 12830 || e >= 12832 && e <= 12871 || e >= 12880 && e <= 19903 || e >= 19968 && e <= 42124 || e >= 42128 && e <= 42182 || e >= 43360 && e <= 43388 || e >= 44032 && e <= 55203 || e >= 63744 && e <= 64255 || e >= 65040 && e <= 65049 || e >= 65072 && e <= 65106 || e >= 65108 && e <= 65126 || e >= 65128 && e <= 65131 || e >= 94176 && e <= 94180 || e === 94192 || e === 94193 || e >= 94208 && e <= 100343 || e >= 100352 && e <= 101589 || e >= 101632 && e <= 101640 || e >= 110576 && e <= 110579 || e >= 110581 && e <= 110587 || e === 110589 || e === 110590 || e >= 110592 && e <= 110882 || e === 110898 || e >= 110928 && e <= 110930 || e === 110933 || e >= 110948 && e <= 110951 || e >= 110960 && e <= 111355 || e === 126980 || e === 127183 || e === 127374 || e >= 127377 && e <= 127386 || e >= 127488 && e <= 127490 || e >= 127504 && e <= 127547 || e >= 127552 && e <= 127560 || e === 127568 || e === 127569 || e >= 127584 && e <= 127589 || e >= 127744 && e <= 127776 || e >= 127789 && e <= 127797 || e >= 127799 && e <= 127868 || e >= 127870 && e <= 127891 || e >= 127904 && e <= 127946 || e >= 127951 && e <= 127955 || e >= 127968 && e <= 127984 || e === 127988 || e >= 127992 && e <= 128062 || e === 128064 || e >= 128066 && e <= 128252 || e >= 128255 && e <= 128317 || e >= 128331 && e <= 128334 || e >= 128336 && e <= 128359 || e === 128378 || e === 128405 || e === 128406 || e === 128420 || e >= 128507 && e <= 128591 || e >= 128640 && e <= 128709 || e === 128716 || e >= 128720 && e <= 128722 || e >= 128725 && e <= 128727 || e >= 128732 && e <= 128735 || e === 128747 || e === 128748 || e >= 128756 && e <= 128764 || e >= 128992 && e <= 129003 || e === 129008 || e >= 129292 && e <= 129338 || e >= 129340 && e <= 129349 || e >= 129351 && e <= 129535 || e >= 129648 && e <= 129660 || e >= 129664 && e <= 129672 || e >= 129680 && e <= 129725 || e >= 129727 && e <= 129733 || e >= 129742 && e <= 129755 || e >= 129760 && e <= 129768 || e >= 129776 && e <= 129784 || e >= 131072 && e <= 196605 || e >= 196608 && e <= 262141, we = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y, re = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y, ie = /\t{1,1000}/y, Ae = /[\u{1F1E6}-\u{1F1FF}]{2}|\u{1F3F4}[\u{E0061}-\u{E007A}]{2}[\u{E0030}-\u{E0039}\u{E0061}-\u{E007A}]{1,3}\u{E007F}|(?:\p{Emoji}\uFE0F\u20E3?|\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation})(?:\u200D(?:\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation}|\p{Emoji}\uFE0F\u20E3?))*/uy, ne = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y, Ft = /\p{M}+/gu, yt = {
597
- limit: Infinity,
598
- ellipsis: ""
599
- }, Le = (e, r = {}, s = {}) => {
600
- const i = r.limit ?? Infinity, a = r.ellipsis ?? "", o = r?.ellipsisWidth ?? (a ? Le(a, yt, s).width : 0), u = s.ansiWidth ?? 0, l = s.controlWidth ?? 0, n = s.tabWidth ?? 8, c = s.ambiguousWidth ?? 1, p = s.emojiWidth ?? 2, f = s.fullWidthWidth ?? 2, g = s.regularWidth ?? 1, E = s.wideWidth ?? 2;
601
- let $ = 0, m = 0, d = e.length, F = 0, y = !1, v = d, C = Math.max(0, i - o), A = 0, b = 0, w = 0, S = 0;
602
- e: for (;;) {
603
- if (b > A || m >= d && m > $) {
604
- const T = e.slice(A, b) || e.slice($, m);
605
- F = 0;
606
- for (const M of T.replaceAll(Ft, "")) {
607
- const O = M.codePointAt(0) || 0;
608
- if (gt(O) ? S = f : ft(O) ? S = E : c !== g && mt(O) ? S = c : S = g, w + S > C && (v = Math.min(v, Math.max(A, $) + F)), w + S > i) {
609
- y = !0;
610
- break e;
611
- }
612
- F += M.length, w += S;
613
- }
614
- A = b = 0;
615
- }
616
- if (m >= d) break;
617
- if (ne.lastIndex = m, ne.test(e)) {
618
- if (F = ne.lastIndex - m, S = F * g, w + S > C && (v = Math.min(v, m + Math.floor((C - w) / g))), w + S > i) {
619
- y = !0;
620
- break;
621
- }
622
- w += S, A = $, b = m, m = $ = ne.lastIndex;
623
- continue;
624
- }
625
- if (we.lastIndex = m, we.test(e)) {
626
- if (w + u > C && (v = Math.min(v, m)), w + u > i) {
627
- y = !0;
628
- break;
629
- }
630
- w += u, A = $, b = m, m = $ = we.lastIndex;
631
- continue;
632
- }
633
- if (re.lastIndex = m, re.test(e)) {
634
- if (F = re.lastIndex - m, S = F * l, w + S > C && (v = Math.min(v, m + Math.floor((C - w) / l))), w + S > i) {
635
- y = !0;
636
- break;
637
- }
638
- w += S, A = $, b = m, m = $ = re.lastIndex;
639
- continue;
640
- }
641
- if (ie.lastIndex = m, ie.test(e)) {
642
- if (F = ie.lastIndex - m, S = F * n, w + S > C && (v = Math.min(v, m + Math.floor((C - w) / n))), w + S > i) {
643
- y = !0;
644
- break;
645
- }
646
- w += S, A = $, b = m, m = $ = ie.lastIndex;
647
- continue;
648
- }
649
- if (Ae.lastIndex = m, Ae.test(e)) {
650
- if (w + p > C && (v = Math.min(v, m)), w + p > i) {
651
- y = !0;
652
- break;
653
- }
654
- w += p, A = $, b = m, m = $ = Ae.lastIndex;
655
- continue;
656
- }
657
- m += 1;
658
- }
659
- return {
660
- width: y ? C : w,
661
- index: y ? v : d,
662
- truncated: y,
663
- ellipsed: y && i >= o
664
- };
665
- }, Et = {
666
- limit: Infinity,
667
- ellipsis: "",
668
- ellipsisWidth: 0
669
- }, D = (e, r = {}) => Le(e, Et, r).width, ae = "\x1B", je = "›", vt = 39, Ce = "\x07", ke = "[", wt = "]", Ve = "m", Se = `${wt}8;;`, He = new RegExp(`(?:\\${ke}(?<code>\\d+)m|\\${Se}(?<uri>.*)${Ce})`, "y"), At = (e) => {
670
- if (e >= 30 && e <= 37 || e >= 90 && e <= 97) return 39;
671
- if (e >= 40 && e <= 47 || e >= 100 && e <= 107) return 49;
672
- if (e === 1 || e === 2) return 22;
673
- if (e === 3) return 23;
674
- if (e === 4) return 24;
675
- if (e === 7) return 27;
676
- if (e === 8) return 28;
677
- if (e === 9) return 29;
678
- if (e === 0) return 0;
679
- }, Ue = (e) => `${ae}${ke}${e}${Ve}`, Ke = (e) => `${ae}${Se}${e}${Ce}`, Ct = (e) => e.map((r) => D(r)), Ie = (e, r, s) => {
680
- const i = r[Symbol.iterator]();
681
- let a = !1, o = !1, u = e.at(-1), l = u === void 0 ? 0 : D(u), n = i.next(), c = i.next(), p = 0;
682
- for (; !n.done;) {
683
- const f = n.value, g = D(f);
684
- l + g <= s ? e[e.length - 1] += f : (e.push(f), l = 0), (f === ae || f === je) && (a = !0, o = r.startsWith(Se, p + 1)), a ? o ? f === Ce && (a = !1, o = !1) : f === Ve && (a = !1) : (l += g, l === s && !c.done && (e.push(""), l = 0)), n = c, c = i.next(), p += f.length;
685
- }
686
- u = e.at(-1), !l && u !== void 0 && u.length > 0 && e.length > 1 && (e[e.length - 2] += e.pop());
687
- }, St = (e) => {
688
- const r = e.split(" ");
689
- let s = r.length;
690
- for (; s > 0 && !(D(r[s - 1]) > 0);) s--;
691
- return s === r.length ? e : r.slice(0, s).join(" ") + r.slice(s).join("");
692
- }, It = (e, r, s = {}) => {
693
- if (s.trim !== !1 && e.trim() === "") return "";
694
- let i = "", a, o;
695
- const u = e.split(" "), l = Ct(u);
696
- let n = [""];
697
- for (const [$, m] of u.entries()) {
698
- s.trim !== !1 && (n[n.length - 1] = (n.at(-1) ?? "").trimStart());
699
- let d = D(n.at(-1) ?? "");
700
- if ($ !== 0 && (d >= r && (s.wordWrap === !1 || s.trim === !1) && (n.push(""), d = 0), (d > 0 || s.trim === !1) && (n[n.length - 1] += " ", d++)), s.hard && l[$] > r) {
701
- const F = r - d, y = 1 + Math.floor((l[$] - F - 1) / r);
702
- Math.floor((l[$] - 1) / r) < y && n.push(""), Ie(n, m, r);
703
- continue;
704
- }
705
- if (d + l[$] > r && d > 0 && l[$] > 0) {
706
- if (s.wordWrap === !1 && d < r) {
707
- Ie(n, m, r);
708
- continue;
709
- }
710
- n.push("");
711
- }
712
- if (d + l[$] > r && s.wordWrap === !1) {
713
- Ie(n, m, r);
714
- continue;
715
- }
716
- n[n.length - 1] += m;
717
- }
718
- s.trim !== !1 && (n = n.map(($) => St($)));
719
- const c = n.join(`
720
- `), p = c[Symbol.iterator]();
721
- let f = p.next(), g = p.next(), E = 0;
722
- for (; !f.done;) {
723
- const $ = f.value, m = g.value;
724
- if (i += $, $ === ae || $ === je) {
725
- He.lastIndex = E + 1;
726
- const y = He.exec(c)?.groups;
727
- if (y?.code !== void 0) {
728
- const v = Number.parseFloat(y.code);
729
- a = v === vt ? void 0 : v;
730
- } else y?.uri !== void 0 && (o = y.uri.length === 0 ? void 0 : y.uri);
731
- }
732
- const d = a ? At(a) : void 0;
733
- m === `
734
- ` ? (o && (i += Ke("")), a && d && (i += Ue(d))) : $ === `
735
- ` && (a && d && (i += Ue(a)), o && (i += Ke(o))), E += $.length, f = g, g = p.next();
786
+ case "active": return styleText("cyan", d);
787
+ case "cancel": return styleText("red", d);
788
+ case "error": return styleText("yellow", d);
789
+ case "submit": return styleText("green", d);
736
790
  }
737
- return i;
738
- };
739
- function J(e, r, s) {
740
- return String(e).normalize().replaceAll(`\r
741
- `, `
742
- `).split(`
743
- `).map((i) => It(i, r, s)).join(`
744
- `);
745
- }
746
- const bt = (e, r, s, i, a) => {
747
- let o = r, u = 0;
748
- for (let l = s; l < i; l++) {
749
- const n = e[l];
750
- if (o = o - n.length, u++, o <= a) break;
791
+ }, et = (e, i, s, r, u) => {
792
+ let n = i, o = 0;
793
+ for (let c = s; c < r; c++) {
794
+ const a = e[c];
795
+ if (n = n - a.length, o++, n <= u) break;
751
796
  }
752
797
  return {
753
- lineCount: o,
754
- removals: u
798
+ lineCount: n,
799
+ removals: o
755
800
  };
756
- }, X = ({ cursor: e, options: r, style: s, output: i = process.stdout, maxItems: a = Number.POSITIVE_INFINITY, columnPadding: o = 0, rowPadding: u = 4 }) => {
757
- const l = rt(i) - o, n = nt(i), c = styleText("dim", "..."), p = Math.max(n - u, 0), f = Math.max(Math.min(a, p), 5);
758
- let g = 0;
759
- e >= f - 3 && (g = Math.max(Math.min(e - f + 3, r.length - f), 0));
760
- let E = f < r.length && g > 0, $ = f < r.length && g + f < r.length;
761
- const m = Math.min(g + f, r.length), d = [];
762
- let F = 0;
763
- E && F++, $ && F++;
764
- const y = g + (E ? 1 : 0), v = m - ($ ? 1 : 0);
765
- for (let A = y; A < v; A++) {
766
- const b = J(s(r[A], A === e), l, {
801
+ }, Y = ({ cursor: e, options: i, style: s, output: r = process.stdout, maxItems: u = Number.POSITIVE_INFINITY, columnPadding: n = 0, rowPadding: o = 4 }) => {
802
+ const c = O$1(r) - n, a = A(r), l = styleText("dim", "..."), $ = Math.max(a - o, 0), y = Math.max(Math.min(u, $), 5);
803
+ let p = 0;
804
+ e >= y - 3 && (p = Math.max(Math.min(e - y + 3, i.length - y), 0));
805
+ let m = y < i.length && p > 0, g = y < i.length && p + y < i.length;
806
+ const S = Math.min(p + y, i.length), h = [];
807
+ let f = 0;
808
+ m && f++, g && f++;
809
+ const v = p + (m ? 1 : 0), T = S - (g ? 1 : 0);
810
+ for (let b = v; b < T; b++) {
811
+ const x = wrapAnsi(s(i[b], b === e), c, {
767
812
  hard: !0,
768
813
  trim: !1
769
814
  }).split(`
770
815
  `);
771
- d.push(b), F += b.length;
816
+ h.push(x), f += x.length;
772
817
  }
773
- if (F > p) {
774
- let A = 0, b = 0, w = F;
775
- const S = e - y, T = (M, O) => bt(d, w, M, O, p);
776
- E ? ({lineCount: w, removals: A} = T(0, S), w > p && ({lineCount: w, removals: b} = T(S + 1, d.length))) : ({lineCount: w, removals: b} = T(S + 1, d.length), w > p && ({lineCount: w, removals: A} = T(0, S))), A > 0 && (E = !0, d.splice(0, A)), b > 0 && ($ = !0, d.splice(d.length - b, b));
818
+ if (f > $) {
819
+ let b = 0, x = 0, G = f;
820
+ const M = e - v, R = (j, D) => et(h, G, j, D, $);
821
+ m ? ({lineCount: G, removals: b} = R(0, M), G > $ && ({lineCount: G, removals: x} = R(M + 1, h.length))) : ({lineCount: G, removals: x} = R(M + 1, h.length), G > $ && ({lineCount: G, removals: b} = R(0, M))), b > 0 && (m = !0, h.splice(0, b)), x > 0 && (g = !0, h.splice(h.length - x, x));
777
822
  }
778
823
  const C = [];
779
- E && C.push(c);
780
- for (const A of d) for (const b of A) C.push(b);
781
- return $ && C.push(c), C;
782
- }, Rt = (e) => {
783
- const r = e.active ?? "Yes", s = e.inactive ?? "No";
784
- return new kt$1({
785
- active: r,
824
+ m && C.push(l);
825
+ for (const b of h) for (const x of b) C.push(x);
826
+ return g && C.push(l), C;
827
+ };
828
+ const ot = (e) => {
829
+ const i = e.active ?? "Yes", s = e.inactive ?? "No";
830
+ return new Q$1({
831
+ active: i,
786
832
  inactive: s,
787
833
  signal: e.signal,
788
834
  input: e.input,
789
835
  output: e.output,
790
836
  initialValue: e.initialValue ?? !0,
791
837
  render() {
792
- const i = e.withGuide ?? _.withGuide, a = `${i ? `${styleText("gray", h)}
793
- ` : ""}${W(this.state)} ${e.message}
794
- `, o = this.value ? r : s;
838
+ const r = e.withGuide ?? u.withGuide, u$4 = `${V(this.state)} `, n = r ? `${styleText("gray", d)} ` : "", o = R(e.output, e.message, n, u$4), c = `${r ? `${styleText("gray", d)}
839
+ ` : ""}${o}
840
+ `, a = this.value ? i : s;
795
841
  switch (this.state) {
796
- case "submit": return `${a}${i ? `${styleText("gray", h)} ` : ""}${styleText("dim", o)}`;
797
- case "cancel": return `${a}${i ? `${styleText("gray", h)} ` : ""}${styleText(["strikethrough", "dim"], o)}${i ? `
798
- ${styleText("gray", h)}` : ""}`;
842
+ case "submit": return `${c}${r ? `${styleText("gray", d)} ` : ""}${styleText("dim", a)}`;
843
+ case "cancel": return `${c}${r ? `${styleText("gray", d)} ` : ""}${styleText(["strikethrough", "dim"], a)}${r ? `
844
+ ${styleText("gray", d)}` : ""}`;
799
845
  default: {
800
- const u = i ? `${styleText("cyan", h)} ` : "", l = i ? styleText("cyan", x) : "";
801
- return `${a}${u}${this.value ? `${styleText("green", z)} ${r}` : `${styleText("dim", H)} ${styleText("dim", r)}`}${e.vertical ? i ? `
802
- ${styleText("cyan", h)} ` : `
846
+ const l = r ? `${styleText("cyan", d)} ` : "", $ = r ? styleText("cyan", E) : "";
847
+ return `${c}${l}${this.value ? `${styleText("green", z)} ${i}` : `${styleText("dim", H)} ${styleText("dim", i)}`}${e.vertical ? r ? `
848
+ ${styleText("cyan", d)} ` : `
803
849
  ` : ` ${styleText("dim", "/")} `}${this.value ? `${styleText("dim", H)} ${styleText("dim", s)}` : `${styleText("green", z)} ${s}`}
804
- ${l}
850
+ ${$}
805
851
  `;
806
852
  }
807
853
  }
808
854
  }
809
855
  }).prompt();
810
- }, R = {
811
- message: (e = [], { symbol: r = styleText("gray", h), secondarySymbol: s = styleText("gray", h), output: i = process.stdout, spacing: a = 1, withGuide: o } = {}) => {
812
- const u = [], l = o ?? _.withGuide, n = l ? s : "", c = l ? `${r} ` : "", p = l ? `${s} ` : "";
813
- for (let g = 0; g < a; g++) u.push(n);
814
- const f = Array.isArray(e) ? e : e.split(`
856
+ }, O = {
857
+ message: (e = [], { symbol: i = styleText("gray", d), secondarySymbol: s = styleText("gray", d), output: r = process.stdout, spacing: u$7 = 1, withGuide: n } = {}) => {
858
+ const o = [], c = n ?? u.withGuide, a = c ? s : "", l = c ? `${i} ` : "", $ = c ? `${s} ` : "";
859
+ for (let p = 0; p < u$7; p++) o.push(a);
860
+ const y = Array.isArray(e) ? e : e.split(`
815
861
  `);
816
- if (f.length > 0) {
817
- const [g, ...E] = f;
818
- g.length > 0 ? u.push(`${c}${g}`) : u.push(l ? r : "");
819
- for (const $ of E) $.length > 0 ? u.push(`${p}${$}`) : u.push(l ? s : "");
862
+ if (y.length > 0) {
863
+ const [p, ...m] = y;
864
+ p.length > 0 ? o.push(`${l}${p}`) : o.push(c ? i : "");
865
+ for (const g of m) g.length > 0 ? o.push(`${$}${g}`) : o.push(c ? s : "");
820
866
  }
821
- i.write(`${u.join(`
867
+ r.write(`${o.join(`
822
868
  `)}
823
869
  `);
824
870
  },
825
- info: (e, r) => {
826
- R.message(e, {
827
- ...r,
828
- symbol: styleText("blue", fe)
871
+ info: (e, i) => {
872
+ O.message(e, {
873
+ ...i,
874
+ symbol: styleText("blue", he)
829
875
  });
830
876
  },
831
- success: (e, r) => {
832
- R.message(e, {
833
- ...r,
834
- symbol: styleText("green", Fe)
877
+ success: (e, i) => {
878
+ O.message(e, {
879
+ ...i,
880
+ symbol: styleText("green", pe)
835
881
  });
836
882
  },
837
- step: (e, r) => {
838
- R.message(e, {
839
- ...r,
840
- symbol: styleText("green", V)
883
+ step: (e, i) => {
884
+ O.message(e, {
885
+ ...i,
886
+ symbol: styleText("green", F)
841
887
  });
842
888
  },
843
- warn: (e, r) => {
844
- R.message(e, {
845
- ...r,
846
- symbol: styleText("yellow", ye)
889
+ warn: (e, i) => {
890
+ O.message(e, {
891
+ ...i,
892
+ symbol: styleText("yellow", me)
847
893
  });
848
894
  },
849
- warning: (e, r) => {
850
- R.warn(e, r);
895
+ warning: (e, i) => {
896
+ O.warn(e, i);
851
897
  },
852
- error: (e, r) => {
853
- R.message(e, {
854
- ...r,
855
- symbol: styleText("red", Ee)
898
+ error: (e, i) => {
899
+ O.message(e, {
900
+ ...i,
901
+ symbol: styleText("red", ge)
856
902
  });
857
903
  }
858
- }, Nt = (e = "", r) => {
859
- const s = r?.output ?? process.stdout, i = r?.withGuide ?? _.withGuide ? `${styleText("gray", x)} ` : "";
860
- s.write(`${i}${styleText("red", e)}
904
+ }, pt = (e = "", i) => {
905
+ const s = i?.output ?? process.stdout, r = i?.withGuide ?? u.withGuide ? `${styleText("gray", E)} ` : "";
906
+ s.write(`${r}${styleText("red", e)}
861
907
 
862
908
  `);
863
- }, Wt = (e = "", r) => {
864
- const s = r?.output ?? process.stdout, i = r?.withGuide ?? _.withGuide ? `${styleText("gray", he)} ` : "";
865
- s.write(`${i}${e}
909
+ }, mt = (e = "", i) => {
910
+ const s = i?.output ?? process.stdout, r = i?.withGuide ?? u.withGuide ? `${styleText("gray", le)} ` : "";
911
+ s.write(`${r}${e}
866
912
  `);
867
- }, Gt = (e = "", r) => {
868
- const s = r?.output ?? process.stdout, i = r?.withGuide ?? _.withGuide ? `${styleText("gray", h)}
869
- ${styleText("gray", x)} ` : "";
870
- s.write(`${i}${e}
913
+ }, gt = (e = "", i) => {
914
+ const s = i?.output ?? process.stdout, r = i?.withGuide ?? u.withGuide ? `${styleText("gray", d)}
915
+ ${styleText("gray", E)} ` : "";
916
+ s.write(`${r}${e}
871
917
 
872
918
  `);
873
- }, Q = (e, r) => e.split(`
874
- `).map((s) => r(s)).join(`
875
- `), Lt = (e) => {
876
- const r = (i, a) => {
877
- const o = i.label ?? String(i.value);
878
- return a === "disabled" ? `${styleText("gray", q)} ${Q(o, (u) => styleText(["strikethrough", "gray"], u))}${i.hint ? ` ${styleText("dim", `(${i.hint ?? "disabled"})`)}` : ""}` : a === "active" ? `${styleText("cyan", te)} ${o}${i.hint ? ` ${styleText("dim", `(${i.hint})`)}` : ""}` : a === "selected" ? `${styleText("green", U)} ${Q(o, (u) => styleText("dim", u))}${i.hint ? ` ${styleText("dim", `(${i.hint})`)}` : ""}` : a === "cancelled" ? `${Q(o, (u) => styleText(["strikethrough", "dim"], u))}` : a === "active-selected" ? `${styleText("green", U)} ${o}${i.hint ? ` ${styleText("dim", `(${i.hint})`)}` : ""}` : a === "submitted" ? `${Q(o, (u) => styleText("dim", u))}` : `${styleText("dim", q)} ${Q(o, (u) => styleText("dim", u))}`;
919
+ }, Q = (e, i) => e.split(`
920
+ `).map((s) => i(s)).join(`
921
+ `), yt = (e) => {
922
+ const i = (r, u) => {
923
+ const n = r.label ?? String(r.value);
924
+ return u === "disabled" ? `${styleText("gray", J)} ${Q(n, (o) => styleText(["strikethrough", "gray"], o))}${r.hint ? ` ${styleText("dim", `(${r.hint ?? "disabled"})`)}` : ""}` : u === "active" ? `${styleText("cyan", te)} ${n}${r.hint ? ` ${styleText("dim", `(${r.hint})`)}` : ""}` : u === "selected" ? `${styleText("green", U)} ${Q(n, (o) => styleText("dim", o))}${r.hint ? ` ${styleText("dim", `(${r.hint})`)}` : ""}` : u === "cancelled" ? `${Q(n, (o) => styleText(["strikethrough", "dim"], o))}` : u === "active-selected" ? `${styleText("green", U)} ${n}${r.hint ? ` ${styleText("dim", `(${r.hint})`)}` : ""}` : u === "submitted" ? `${Q(n, (o) => styleText("dim", o))}` : `${styleText("dim", J)} ${Q(n, (o) => styleText("dim", o))}`;
879
925
  }, s = e.required ?? !0;
880
- return new Lt$1({
926
+ return new it$1({
881
927
  options: e.options,
882
928
  signal: e.signal,
883
929
  input: e.input,
@@ -885,8 +931,8 @@ ${styleText("gray", x)} ` : "";
885
931
  initialValues: e.initialValues,
886
932
  required: s,
887
933
  cursorAt: e.cursorAt,
888
- validate(i) {
889
- if (s && (i === void 0 || i.length === 0)) return `Please select at least one option.
934
+ validate(r) {
935
+ if (s && (r === void 0 || r.length === 0)) return `Please select at least one option.
890
936
  ${styleText("reset", styleText("dim", `Press ${styleText([
891
937
  "gray",
892
938
  "bgWhite",
@@ -894,141 +940,141 @@ ${styleText("reset", styleText("dim", `Press ${styleText([
894
940
  ], " space ")} to select, ${styleText("gray", styleText("bgWhite", styleText("inverse", " enter ")))} to submit`))}`;
895
941
  },
896
942
  render() {
897
- const i = Bt$1(e.output, e.message, `${ve(this.state)} `, `${W(this.state)} `), a = `${styleText("gray", h)}
898
- ${i}
899
- `, o = this.value ?? [], u = (l, n) => {
900
- if (l.disabled) return r(l, "disabled");
901
- const c = o.includes(l.value);
902
- return n && c ? r(l, "active-selected") : c ? r(l, "selected") : r(l, n ? "active" : "inactive");
943
+ const r = e.withGuide ?? u.withGuide, u$8 = R(e.output, e.message, r ? `${ye(this.state)} ` : "", `${V(this.state)} `), n = `${r ? `${styleText("gray", d)}
944
+ ` : ""}${u$8}
945
+ `, o = this.value ?? [], c = (a, l) => {
946
+ if (a.disabled) return i(a, "disabled");
947
+ const $ = o.includes(a.value);
948
+ return l && $ ? i(a, "active-selected") : $ ? i(a, "selected") : i(a, l ? "active" : "inactive");
903
949
  };
904
950
  switch (this.state) {
905
951
  case "submit": {
906
- const l = this.options.filter(({ value: c }) => o.includes(c)).map((c) => r(c, "submitted")).join(styleText("dim", ", ")) || styleText("dim", "none");
907
- return `${a}${Bt$1(e.output, l, `${styleText("gray", h)} `)}`;
952
+ const a = this.options.filter(({ value: $ }) => o.includes($)).map(($) => i($, "submitted")).join(styleText("dim", ", ")) || styleText("dim", "none");
953
+ return `${n}${R(e.output, a, r ? `${styleText("gray", d)} ` : "")}`;
908
954
  }
909
955
  case "cancel": {
910
- const l = this.options.filter(({ value: c }) => o.includes(c)).map((c) => r(c, "cancelled")).join(styleText("dim", ", "));
911
- if (l.trim() === "") return `${a}${styleText("gray", h)}`;
912
- return `${a}${Bt$1(e.output, l, `${styleText("gray", h)} `)}
913
- ${styleText("gray", h)}`;
956
+ const a = this.options.filter(({ value: $ }) => o.includes($)).map(($) => i($, "cancelled")).join(styleText("dim", ", "));
957
+ if (a.trim() === "") return `${n}${styleText("gray", d)}`;
958
+ return `${n}${R(e.output, a, r ? `${styleText("gray", d)} ` : "")}${r ? `
959
+ ${styleText("gray", d)}` : ""}`;
914
960
  }
915
961
  case "error": {
916
- const l = `${styleText("yellow", h)} `, n = this.error.split(`
917
- `).map((f, g) => g === 0 ? `${styleText("yellow", x)} ${styleText("yellow", f)}` : ` ${f}`).join(`
918
- `), c = a.split(`
919
- `).length, p = n.split(`
962
+ const a = r ? `${styleText("yellow", d)} ` : "", l = this.error.split(`
963
+ `).map((p, m) => m === 0 ? `${r ? `${styleText("yellow", E)} ` : ""}${styleText("yellow", p)}` : ` ${p}`).join(`
964
+ `), $ = n.split(`
965
+ `).length, y = l.split(`
920
966
  `).length + 1;
921
- return `${a}${l}${X({
967
+ return `${n}${a}${Y({
922
968
  output: e.output,
923
969
  options: this.options,
924
970
  cursor: this.cursor,
925
971
  maxItems: e.maxItems,
926
- columnPadding: l.length,
927
- rowPadding: c + p,
928
- style: u
972
+ columnPadding: a.length,
973
+ rowPadding: $ + y,
974
+ style: c
929
975
  }).join(`
930
- ${l}`)}
931
- ${n}
976
+ ${a}`)}
977
+ ${l}
932
978
  `;
933
979
  }
934
980
  default: {
935
- const l = `${styleText("cyan", h)} `, n = a.split(`
936
- `).length;
937
- return `${a}${l}${X({
981
+ const a = r ? `${styleText("cyan", d)} ` : "", l = n.split(`
982
+ `).length, $ = r ? 2 : 1;
983
+ return `${n}${a}${Y({
938
984
  output: e.output,
939
985
  options: this.options,
940
986
  cursor: this.cursor,
941
987
  maxItems: e.maxItems,
942
- columnPadding: l.length,
943
- rowPadding: n + 2,
944
- style: u
988
+ columnPadding: a.length,
989
+ rowPadding: l + $,
990
+ style: c
945
991
  }).join(`
946
- ${l}`)}
947
- ${styleText("cyan", x)}
992
+ ${a}`)}
993
+ ${r ? styleText("cyan", E) : ""}
948
994
  `;
949
995
  }
950
996
  }
951
997
  }
952
998
  }).prompt();
953
999
  };
954
- I("─", "-"), I("━", "="), I("█", "#");
955
- const oe = (e, r) => e.includes(`
1000
+ w("─", "-"), w("━", "="), w("█", "#");
1001
+ const re = (e, i) => e.includes(`
956
1002
  `) ? e.split(`
957
- `).map((s) => r(s)).join(`
958
- `) : r(e), Jt = (e) => {
959
- const r = (s, i) => {
960
- const a = s.label ?? String(s.value);
961
- switch (i) {
962
- case "disabled": return `${styleText("gray", H)} ${oe(a, (o) => styleText("gray", o))}${s.hint ? ` ${styleText("dim", `(${s.hint ?? "disabled"})`)}` : ""}`;
963
- case "selected": return `${oe(a, (o) => styleText("dim", o))}`;
964
- case "active": return `${styleText("green", z)} ${a}${s.hint ? ` ${styleText("dim", `(${s.hint})`)}` : ""}`;
965
- case "cancelled": return `${oe(a, (o) => styleText(["strikethrough", "dim"], o))}`;
966
- default: return `${styleText("dim", H)} ${oe(a, (o) => styleText("dim", o))}`;
1003
+ `).map((s) => i(s)).join(`
1004
+ `) : i(e), _t = (e) => {
1005
+ const i = (s, r) => {
1006
+ const u = s.label ?? String(s.value);
1007
+ switch (r) {
1008
+ case "disabled": return `${styleText("gray", H)} ${re(u, (n) => styleText("gray", n))}${s.hint ? ` ${styleText("dim", `(${s.hint ?? "disabled"})`)}` : ""}`;
1009
+ case "selected": return `${re(u, (n) => styleText("dim", n))}`;
1010
+ case "active": return `${styleText("green", z)} ${u}${s.hint ? ` ${styleText("dim", `(${s.hint})`)}` : ""}`;
1011
+ case "cancelled": return `${re(u, (n) => styleText(["strikethrough", "dim"], n))}`;
1012
+ default: return `${styleText("dim", H)} ${re(u, (n) => styleText("dim", n))}`;
967
1013
  }
968
1014
  };
969
- return new Tt$1({
1015
+ return new nt$1({
970
1016
  options: e.options,
971
1017
  signal: e.signal,
972
1018
  input: e.input,
973
1019
  output: e.output,
974
1020
  initialValue: e.initialValue,
975
1021
  render() {
976
- const s = e.withGuide ?? _.withGuide, i = `${W(this.state)} `, a = `${ve(this.state)} `, o = Bt$1(e.output, e.message, a, i), u = `${s ? `${styleText("gray", h)}
977
- ` : ""}${o}
1022
+ const s = e.withGuide ?? u.withGuide, r = `${V(this.state)} `, u$12 = `${ye(this.state)} `, n = R(e.output, e.message, u$12, r), o = `${s ? `${styleText("gray", d)}
1023
+ ` : ""}${n}
978
1024
  `;
979
1025
  switch (this.state) {
980
1026
  case "submit": {
981
- const l = s ? `${styleText("gray", h)} ` : "";
982
- return `${u}${Bt$1(e.output, r(this.options[this.cursor], "selected"), l)}`;
1027
+ const c = s ? `${styleText("gray", d)} ` : "";
1028
+ return `${o}${R(e.output, i(this.options[this.cursor], "selected"), c)}`;
983
1029
  }
984
1030
  case "cancel": {
985
- const l = s ? `${styleText("gray", h)} ` : "";
986
- return `${u}${Bt$1(e.output, r(this.options[this.cursor], "cancelled"), l)}${s ? `
987
- ${styleText("gray", h)}` : ""}`;
1031
+ const c = s ? `${styleText("gray", d)} ` : "";
1032
+ return `${o}${R(e.output, i(this.options[this.cursor], "cancelled"), c)}${s ? `
1033
+ ${styleText("gray", d)}` : ""}`;
988
1034
  }
989
1035
  default: {
990
- const l = s ? `${styleText("cyan", h)} ` : "", n = s ? styleText("cyan", x) : "", c = u.split(`
991
- `).length, p = s ? 2 : 1;
992
- return `${u}${l}${X({
1036
+ const c = s ? `${styleText("cyan", d)} ` : "", a = s ? styleText("cyan", E) : "", l = o.split(`
1037
+ `).length, $ = s ? 2 : 1;
1038
+ return `${o}${c}${Y({
993
1039
  output: e.output,
994
1040
  cursor: this.cursor,
995
1041
  options: this.options,
996
1042
  maxItems: e.maxItems,
997
- columnPadding: l.length,
998
- rowPadding: c + p,
999
- style: (f, g) => r(f, f.disabled ? "disabled" : g ? "active" : "inactive")
1043
+ columnPadding: c.length,
1044
+ rowPadding: l + $,
1045
+ style: (y, p) => i(y, y.disabled ? "disabled" : p ? "active" : "inactive")
1000
1046
  }).join(`
1001
- ${l}`)}
1002
- ${n}
1047
+ ${c}`)}
1048
+ ${a}
1003
1049
  `;
1004
1050
  }
1005
1051
  }
1006
1052
  }
1007
1053
  }).prompt();
1008
- }, Qe = `${styleText("gray", h)} `, K = {
1009
- message: async (e, { symbol: r = styleText("gray", h) } = {}) => {
1010
- process.stdout.write(`${styleText("gray", h)}
1011
- ${r} `);
1054
+ }, je = `${styleText("gray", d)} `, K = {
1055
+ message: async (e, { symbol: i = styleText("gray", d) } = {}) => {
1056
+ process.stdout.write(`${styleText("gray", d)}
1057
+ ${i} `);
1012
1058
  let s = 3;
1013
- for await (let i of e) {
1014
- i = i.replace(/\n/g, `
1015
- ${Qe}`), i.includes(`
1016
- `) && (s = 3 + stripVTControlCharacters(i.slice(i.lastIndexOf(`
1059
+ for await (let r of e) {
1060
+ r = r.replace(/\n/g, `
1061
+ ${je}`), r.includes(`
1062
+ `) && (s = 3 + stripVTControlCharacters(r.slice(r.lastIndexOf(`
1017
1063
  `))).length);
1018
- const a = stripVTControlCharacters(i).length;
1019
- s + a < process.stdout.columns ? (s += a, process.stdout.write(i)) : (process.stdout.write(`
1020
- ${Qe}${i.trimStart()}`), s = 3 + stripVTControlCharacters(i.trimStart()).length);
1064
+ const u = stripVTControlCharacters(r).length;
1065
+ s + u < process.stdout.columns ? (s += u, process.stdout.write(r)) : (process.stdout.write(`
1066
+ ${je}${r.trimStart()}`), s = 3 + stripVTControlCharacters(r.trimStart()).length);
1021
1067
  }
1022
1068
  process.stdout.write(`
1023
1069
  `);
1024
1070
  },
1025
- info: (e) => K.message(e, { symbol: styleText("blue", fe) }),
1026
- success: (e) => K.message(e, { symbol: styleText("green", Fe) }),
1027
- step: (e) => K.message(e, { symbol: styleText("green", V) }),
1028
- warn: (e) => K.message(e, { symbol: styleText("yellow", ye) }),
1071
+ info: (e) => K.message(e, { symbol: styleText("blue", he) }),
1072
+ success: (e) => K.message(e, { symbol: styleText("green", pe) }),
1073
+ step: (e) => K.message(e, { symbol: styleText("green", F) }),
1074
+ warn: (e) => K.message(e, { symbol: styleText("yellow", me) }),
1029
1075
  warning: (e) => K.warn(e),
1030
- error: (e) => K.message(e, { symbol: styleText("red", Ee) })
1031
- }, Zt = (e) => new $t({
1076
+ error: (e) => K.message(e, { symbol: styleText("red", ge) })
1077
+ }, Ot = (e) => new at$1({
1032
1078
  validate: e.validate,
1033
1079
  placeholder: e.placeholder,
1034
1080
  defaultValue: e.defaultValue,
@@ -1037,28 +1083,28 @@ ${Qe}${i.trimStart()}`), s = 3 + stripVTControlCharacters(i.trimStart()).length)
1037
1083
  signal: e.signal,
1038
1084
  input: e.input,
1039
1085
  render() {
1040
- const r = e?.withGuide ?? _.withGuide, s = `${`${r ? `${styleText("gray", h)}
1041
- ` : ""}${W(this.state)} `}${e.message}
1042
- `, i = e.placeholder ? styleText("inverse", e.placeholder[0]) + styleText("dim", e.placeholder.slice(1)) : styleText(["inverse", "hidden"], "_"), a = this.userInput ? this.userInputWithCursor : i, o = this.value ?? "";
1086
+ const i = e?.withGuide ?? u.withGuide, s = `${`${i ? `${styleText("gray", d)}
1087
+ ` : ""}${V(this.state)} `}${e.message}
1088
+ `, r = e.placeholder ? styleText("inverse", e.placeholder[0]) + styleText("dim", e.placeholder.slice(1)) : styleText(["inverse", "hidden"], "_"), u$13 = this.userInput ? this.userInputWithCursor : r, n = this.value ?? "";
1043
1089
  switch (this.state) {
1044
1090
  case "error": {
1045
- const u = this.error ? ` ${styleText("yellow", this.error)}` : "", l = r ? `${styleText("yellow", h)} ` : "", n = r ? styleText("yellow", x) : "";
1091
+ const o = this.error ? ` ${styleText("yellow", this.error)}` : "", c = i ? `${styleText("yellow", d)} ` : "", a = i ? styleText("yellow", E) : "";
1046
1092
  return `${s.trim()}
1047
- ${l}${a}
1048
- ${n}${u}
1093
+ ${c}${u$13}
1094
+ ${a}${o}
1049
1095
  `;
1050
1096
  }
1051
1097
  case "submit": {
1052
- const u = o ? ` ${styleText("dim", o)}` : "";
1053
- return `${s}${r ? styleText("gray", h) : ""}${u}`;
1098
+ const o = n ? ` ${styleText("dim", n)}` : "";
1099
+ return `${s}${i ? styleText("gray", d) : ""}${o}`;
1054
1100
  }
1055
1101
  case "cancel": {
1056
- const u = o ? ` ${styleText(["strikethrough", "dim"], o)}` : "", l = r ? styleText("gray", h) : "";
1057
- return `${s}${l}${u}${o.trim() ? `
1058
- ${l}` : ""}`;
1102
+ const o = n ? ` ${styleText(["strikethrough", "dim"], n)}` : "", c = i ? styleText("gray", d) : "";
1103
+ return `${s}${c}${o}${n.trim() ? `
1104
+ ${c}` : ""}`;
1059
1105
  }
1060
- default: return `${s}${r ? `${styleText("cyan", h)} ` : ""}${a}
1061
- ${r ? styleText("cyan", x) : ""}
1106
+ default: return `${s}${i ? `${styleText("cyan", d)} ` : ""}${u$13}
1107
+ ${i ? styleText("cyan", E) : ""}
1062
1108
  `;
1063
1109
  }
1064
1110
  }
@@ -1346,8 +1392,8 @@ var require_package = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1346
1392
  };
1347
1393
  }));
1348
1394
  //#endregion
1349
- //#region utils/banners.ts
1350
- var import_ejs = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((exports) => {
1395
+ //#region node_modules/.pnpm/ejs@3.1.10/node_modules/ejs/lib/ejs.js
1396
+ var require_ejs = /* @__PURE__ */ __commonJSMin(((exports) => {
1351
1397
  /**
1352
1398
  * @file Embedded JavaScript templating engine. {@link http://ejs.co}
1353
1399
  * @author Matthew Eernisse <mde@fleegix.org>
@@ -2011,8 +2057,11 @@ var import_ejs = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((export
2011
2057
  exports.name = _NAME;
2012
2058
  /* istanbul ignore if */
2013
2059
  if (typeof window != "undefined") window.ejs = exports;
2014
- })))(), 1);
2060
+ }));
2061
+ //#endregion
2062
+ //#region utils/banners.ts
2015
2063
  var import_picocolors = require_picocolors();
2064
+ var import_ejs = /* @__PURE__ */ __toESM(require_ejs(), 1);
2016
2065
  const defaultBanner = "Vue.js - The Progressive JavaScript Framework";
2017
2066
  const gradientBanner = "\x1B[38;2;66;211;146mV\x1B[39m\x1B[38;2;66;211;146mu\x1B[39m\x1B[38;2;66;211;146me\x1B[39m\x1B[38;2;66;211;146m.\x1B[39m\x1B[38;2;66;211;146mj\x1B[39m\x1B[38;2;67;209;149ms\x1B[39m \x1B[38;2;68;206;152m-\x1B[39m \x1B[38;2;69;204;155mT\x1B[39m\x1B[38;2;70;201;158mh\x1B[39m\x1B[38;2;71;199;162me\x1B[39m \x1B[38;2;72;196;165mP\x1B[39m\x1B[38;2;73;194;168mr\x1B[39m\x1B[38;2;74;192;171mo\x1B[39m\x1B[38;2;75;189;174mg\x1B[39m\x1B[38;2;76;187;177mr\x1B[39m\x1B[38;2;77;184;180me\x1B[39m\x1B[38;2;78;182;183ms\x1B[39m\x1B[38;2;79;179;186ms\x1B[39m\x1B[38;2;80;177;190mi\x1B[39m\x1B[38;2;81;175;193mv\x1B[39m\x1B[38;2;82;172;196me\x1B[39m \x1B[38;2;83;170;199mJ\x1B[39m\x1B[38;2;83;167;202ma\x1B[39m\x1B[38;2;84;165;205mv\x1B[39m\x1B[38;2;85;162;208ma\x1B[39m\x1B[38;2;86;160;211mS\x1B[39m\x1B[38;2;87;158;215mc\x1B[39m\x1B[38;2;88;155;218mr\x1B[39m\x1B[38;2;89;153;221mi\x1B[39m\x1B[38;2;90;150;224mp\x1B[39m\x1B[38;2;91;148;227mt\x1B[39m \x1B[38;2;92;145;230mF\x1B[39m\x1B[38;2;93;143;233mr\x1B[39m\x1B[38;2;94;141;236ma\x1B[39m\x1B[38;2;95;138;239mm\x1B[39m\x1B[38;2;96;136;243me\x1B[39m\x1B[38;2;97;133;246mw\x1B[39m\x1B[38;2;98;131;249mo\x1B[39m\x1B[38;2;99;128;252mr\x1B[39m\x1B[38;2;100;126;255mk\x1B[39m";
2018
2067
  //#endregion
@@ -2409,7 +2458,7 @@ function getPackageManagerOptions(preferred) {
2409
2458
  //#endregion
2410
2459
  //#region package.json
2411
2460
  var name = "create-vue";
2412
- var version = "3.22.1";
2461
+ var version = "3.22.3";
2413
2462
  //#endregion
2414
2463
  //#region index.ts
2415
2464
  const language = await getLanguage(fileURLToPath(new URL("./locales", import.meta.url)));
@@ -2431,7 +2480,6 @@ const FEATURE_FLAGS = [
2431
2480
  "eslint-with-prettier",
2432
2481
  "oxlint",
2433
2482
  "oxfmt",
2434
- "vite-beta",
2435
2483
  "vue-beta"
2436
2484
  ];
2437
2485
  const FEATURE_OPTIONS = [
@@ -2464,20 +2512,13 @@ const FEATURE_OPTIONS = [
2464
2512
  label: language.needsPrettier.message
2465
2513
  }
2466
2514
  ];
2467
- const EXPERIMENTAL_FEATURE_OPTIONS = [
2468
- {
2469
- value: "oxfmt",
2470
- label: language.needsOxfmt.message
2471
- },
2472
- {
2473
- value: "vite-beta",
2474
- label: language.needsViteBeta.message
2475
- },
2476
- {
2477
- value: "vue-beta",
2478
- label: language.needsVueBeta.message
2479
- }
2480
- ];
2515
+ const EXPERIMENTAL_FEATURE_OPTIONS = [{
2516
+ value: "oxfmt",
2517
+ label: language.needsOxfmt.message
2518
+ }, {
2519
+ value: "vue-beta",
2520
+ label: language.needsVueBeta.message
2521
+ }];
2481
2522
  function isValidPackageName(projectName) {
2482
2523
  return /^(?:@[a-z0-9-*~][a-z0-9-*._~]*\/)?[a-z0-9-~][a-z0-9-._~]*$/.test(projectName);
2483
2524
  }
@@ -2500,8 +2541,8 @@ function emptyDir(dir) {
2500
2541
  }
2501
2542
  async function unwrapPrompt(maybeCancelPromise) {
2502
2543
  const result = await maybeCancelPromise;
2503
- if (Ct$1(result)) {
2504
- Nt((0, import_picocolors.red)("✖") + ` ${language.errors.operationCancelled}`);
2544
+ if (q(result)) {
2545
+ pt((0, import_picocolors.red)("✖") + ` ${language.errors.operationCancelled}`);
2505
2546
  process.exit(0);
2506
2547
  }
2507
2548
  return result;
@@ -2546,8 +2587,6 @@ Available feature flags:
2546
2587
  Add Prettier for code formatting.
2547
2588
  --oxfmt
2548
2589
  Add Oxfmt for code formatting.
2549
- --vite-beta
2550
- Use Vite 8 Beta instead of Vite for building the project.
2551
2590
  --vue-beta
2552
2591
  Use Vue 3.6 Beta. Requires specifying a package manager in interactive mode.
2553
2592
 
@@ -2561,8 +2600,6 @@ Deprecated feature flags:
2561
2600
  Please use ${(0, import_picocolors.cyan)("--eslint --prettier")} instead.
2562
2601
  --oxlint
2563
2602
  Oxlint is now always included when ESLint is selected.
2564
- --rolldown-vite
2565
- Please use ${(0, import_picocolors.cyan)("--vite-beta")} instead.
2566
2603
  `;
2567
2604
  async function init() {
2568
2605
  const cwd = process.cwd();
@@ -2602,41 +2639,41 @@ async function init() {
2602
2639
  experimentFeatures: [],
2603
2640
  needsBareboneTemplates: false
2604
2641
  };
2605
- Wt(process.stdout.isTTY && process.stdout.getColorDepth() > 8 ? gradientBanner : defaultBanner);
2606
- if (!targetDir) targetDir = result.projectName = result.packageName = (await unwrapPrompt(Zt({
2642
+ mt(process.stdout.isTTY && process.stdout.getColorDepth() > 8 ? gradientBanner : defaultBanner);
2643
+ if (!targetDir) targetDir = result.projectName = result.packageName = (await unwrapPrompt(Ot({
2607
2644
  message: language.projectName.message,
2608
2645
  placeholder: defaultProjectName,
2609
2646
  defaultValue: defaultProjectName,
2610
2647
  validate: (value) => !value || value.trim().length > 0 ? void 0 : language.projectName.invalidMessage
2611
2648
  })))?.trim() || defaultProjectName;
2612
2649
  if (!canSkipEmptying(targetDir) && !forceOverwrite) {
2613
- result.shouldOverwrite = await unwrapPrompt(Rt({
2650
+ result.shouldOverwrite = await unwrapPrompt(ot({
2614
2651
  message: `${targetDir === "." ? language.shouldOverwrite.dirForPrompts.current : `${language.shouldOverwrite.dirForPrompts.target} "${targetDir}"`} ${language.shouldOverwrite.message}`,
2615
2652
  initialValue: false
2616
2653
  }));
2617
2654
  if (!result.shouldOverwrite) {
2618
- Nt((0, import_picocolors.red)("✖") + ` ${language.errors.operationCancelled}`);
2655
+ pt((0, import_picocolors.red)("✖") + ` ${language.errors.operationCancelled}`);
2619
2656
  process.exit(0);
2620
2657
  }
2621
2658
  }
2622
- if (!isValidPackageName(targetDir)) result.packageName = await unwrapPrompt(Zt({
2659
+ if (!isValidPackageName(targetDir)) result.packageName = await unwrapPrompt(Ot({
2623
2660
  message: language.packageName.message,
2624
2661
  initialValue: toValidPackageName(targetDir),
2625
2662
  validate: (value) => isValidPackageName(value) ? void 0 : language.packageName.invalidMessage
2626
2663
  }));
2627
2664
  if (!isFeatureFlagsUsed) {
2628
- result.needsTypeScript = await unwrapPrompt(Rt({
2665
+ result.needsTypeScript = await unwrapPrompt(ot({
2629
2666
  message: language.needsTypeScript.message,
2630
2667
  initialValue: true
2631
2668
  }));
2632
- result.features = await unwrapPrompt(Lt({
2669
+ result.features = await unwrapPrompt(yt({
2633
2670
  message: `${language.featureSelection.message} ${(0, import_picocolors.dim)(language.featureSelection.hint)}`,
2634
2671
  options: FEATURE_OPTIONS,
2635
2672
  required: false
2636
2673
  }));
2637
2674
  if (result.features.includes("e2e")) {
2638
2675
  const hasVitest = result.features.includes("vitest");
2639
- result.e2eFramework = await unwrapPrompt(Jt({
2676
+ result.e2eFramework = await unwrapPrompt(_t({
2640
2677
  message: `${language.e2eSelection.message} ${(0, import_picocolors.dim)(language.e2eSelection.hint)}`,
2641
2678
  options: [{
2642
2679
  value: "playwright",
@@ -2649,7 +2686,7 @@ async function init() {
2649
2686
  }]
2650
2687
  }));
2651
2688
  }
2652
- result.experimentFeatures = await unwrapPrompt(Lt({
2689
+ result.experimentFeatures = await unwrapPrompt(yt({
2653
2690
  message: `${language.needsExperimentalFeatures.message} ${(0, import_picocolors.dim)(language.needsExperimentalFeatures.hint)}`,
2654
2691
  options: EXPERIMENTAL_FEATURE_OPTIONS,
2655
2692
  required: false
@@ -2659,14 +2696,14 @@ async function init() {
2659
2696
  value: pm,
2660
2697
  label: pm
2661
2698
  }));
2662
- result.packageManager = await unwrapPrompt(Jt({
2699
+ result.packageManager = await unwrapPrompt(_t({
2663
2700
  message: `${language.packageManagerSelection.message} ${(0, import_picocolors.dim)(language.packageManagerSelection.hint)}`,
2664
2701
  options: packageManagerOptions
2665
2702
  }));
2666
2703
  }
2667
2704
  }
2668
2705
  if (argv.bare) result.needsBareboneTemplates = true;
2669
- else if (!isFeatureFlagsUsed) result.needsBareboneTemplates = await unwrapPrompt(Rt({
2706
+ else if (!isFeatureFlagsUsed) result.needsBareboneTemplates = await unwrapPrompt(ot({
2670
2707
  message: language.needsBareboneTemplates.message,
2671
2708
  initialValue: false
2672
2709
  }));
@@ -2679,7 +2716,6 @@ async function init() {
2679
2716
  const needsEslint = argv.eslint || argv["eslint-with-prettier"] || features.includes("eslint");
2680
2717
  const needsPrettier = argv.prettier || argv["eslint-with-prettier"] || features.includes("prettier");
2681
2718
  const needsOxfmt = experimentFeatures.includes("oxfmt") || argv["oxfmt"];
2682
- const needsViteBeta = experimentFeatures.includes("vite-beta") || argv["vite-beta"] || argv["rolldown-vite"];
2683
2719
  const needsVueBeta = experimentFeatures.includes("vue-beta") || argv["vue-beta"];
2684
2720
  const { e2eFramework } = result;
2685
2721
  const needsCypress = argv.cypress || argv.tests || argv["with-tests"] || e2eFramework === "cypress";
@@ -2699,12 +2735,6 @@ async function init() {
2699
2735
  const render = function render(templateName) {
2700
2736
  renderTemplate(path$1.resolve(templateRoot, templateName), root, callbacks);
2701
2737
  };
2702
- const replaceVite = () => {
2703
- const content = fs.readFileSync(path$1.resolve(root, "package.json"), "utf-8");
2704
- const json = JSON.parse(content);
2705
- json.devDependencies.vite = "beta";
2706
- fs.writeFileSync(path$1.resolve(root, "package.json"), JSON.stringify(json, null, 2));
2707
- };
2708
2738
  render("base");
2709
2739
  if (needsJsx) render("config/jsx");
2710
2740
  if (needsRouter) render("config/router");
@@ -2752,7 +2782,6 @@ async function init() {
2752
2782
  }
2753
2783
  if (needsOxfmt) render("formatting/oxfmt");
2754
2784
  else if (needsPrettier) render("formatting/prettier");
2755
- if (needsViteBeta) replaceVite();
2756
2785
  render(`code/${(needsTypeScript ? "typescript-" : "") + (needsRouter ? "router" : "default")}`);
2757
2786
  if (needsPinia && needsRouter) render("entry/router-and-pinia");
2758
2787
  else if (needsPinia) render("entry/pinia");
@@ -2823,7 +2852,7 @@ async function init() {
2823
2852
  ${(0, import_picocolors.dim)("|")} ${language.infos.optionalGitCommand}
2824
2853
 
2825
2854
  ${(0, import_picocolors.bold)((0, import_picocolors.green)("git init && git add -A && git commit -m \"initial commit\""))}`;
2826
- Gt(outroMessage);
2855
+ gt(outroMessage);
2827
2856
  }
2828
2857
  init().catch((e) => {
2829
2858
  console.error(e);