zefiro 0.1.8 → 0.2.0

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.
@@ -0,0 +1,601 @@
1
+ // ../../node_modules/.bun/chalk@5.6.2/node_modules/chalk/source/vendor/ansi-styles/index.js
2
+ var ANSI_BACKGROUND_OFFSET = 10;
3
+ var wrapAnsi16 = (offset = 0) => (code) => `\x1B[${code + offset}m`;
4
+ var wrapAnsi256 = (offset = 0) => (code) => `\x1B[${38 + offset};5;${code}m`;
5
+ var wrapAnsi16m = (offset = 0) => (red, green, blue) => `\x1B[${38 + offset};2;${red};${green};${blue}m`;
6
+ var styles = {
7
+ modifier: {
8
+ reset: [0, 0],
9
+ bold: [1, 22],
10
+ dim: [2, 22],
11
+ italic: [3, 23],
12
+ underline: [4, 24],
13
+ overline: [53, 55],
14
+ inverse: [7, 27],
15
+ hidden: [8, 28],
16
+ strikethrough: [9, 29]
17
+ },
18
+ color: {
19
+ black: [30, 39],
20
+ red: [31, 39],
21
+ green: [32, 39],
22
+ yellow: [33, 39],
23
+ blue: [34, 39],
24
+ magenta: [35, 39],
25
+ cyan: [36, 39],
26
+ white: [37, 39],
27
+ blackBright: [90, 39],
28
+ gray: [90, 39],
29
+ grey: [90, 39],
30
+ redBright: [91, 39],
31
+ greenBright: [92, 39],
32
+ yellowBright: [93, 39],
33
+ blueBright: [94, 39],
34
+ magentaBright: [95, 39],
35
+ cyanBright: [96, 39],
36
+ whiteBright: [97, 39]
37
+ },
38
+ bgColor: {
39
+ bgBlack: [40, 49],
40
+ bgRed: [41, 49],
41
+ bgGreen: [42, 49],
42
+ bgYellow: [43, 49],
43
+ bgBlue: [44, 49],
44
+ bgMagenta: [45, 49],
45
+ bgCyan: [46, 49],
46
+ bgWhite: [47, 49],
47
+ bgBlackBright: [100, 49],
48
+ bgGray: [100, 49],
49
+ bgGrey: [100, 49],
50
+ bgRedBright: [101, 49],
51
+ bgGreenBright: [102, 49],
52
+ bgYellowBright: [103, 49],
53
+ bgBlueBright: [104, 49],
54
+ bgMagentaBright: [105, 49],
55
+ bgCyanBright: [106, 49],
56
+ bgWhiteBright: [107, 49]
57
+ }
58
+ };
59
+ var modifierNames = Object.keys(styles.modifier);
60
+ var foregroundColorNames = Object.keys(styles.color);
61
+ var backgroundColorNames = Object.keys(styles.bgColor);
62
+ var colorNames = [...foregroundColorNames, ...backgroundColorNames];
63
+ function assembleStyles() {
64
+ const codes = new Map;
65
+ for (const [groupName, group] of Object.entries(styles)) {
66
+ for (const [styleName, style] of Object.entries(group)) {
67
+ styles[styleName] = {
68
+ open: `\x1B[${style[0]}m`,
69
+ close: `\x1B[${style[1]}m`
70
+ };
71
+ group[styleName] = styles[styleName];
72
+ codes.set(style[0], style[1]);
73
+ }
74
+ Object.defineProperty(styles, groupName, {
75
+ value: group,
76
+ enumerable: false
77
+ });
78
+ }
79
+ Object.defineProperty(styles, "codes", {
80
+ value: codes,
81
+ enumerable: false
82
+ });
83
+ styles.color.close = "\x1B[39m";
84
+ styles.bgColor.close = "\x1B[49m";
85
+ styles.color.ansi = wrapAnsi16();
86
+ styles.color.ansi256 = wrapAnsi256();
87
+ styles.color.ansi16m = wrapAnsi16m();
88
+ styles.bgColor.ansi = wrapAnsi16(ANSI_BACKGROUND_OFFSET);
89
+ styles.bgColor.ansi256 = wrapAnsi256(ANSI_BACKGROUND_OFFSET);
90
+ styles.bgColor.ansi16m = wrapAnsi16m(ANSI_BACKGROUND_OFFSET);
91
+ Object.defineProperties(styles, {
92
+ rgbToAnsi256: {
93
+ value(red, green, blue) {
94
+ if (red === green && green === blue) {
95
+ if (red < 8) {
96
+ return 16;
97
+ }
98
+ if (red > 248) {
99
+ return 231;
100
+ }
101
+ return Math.round((red - 8) / 247 * 24) + 232;
102
+ }
103
+ return 16 + 36 * Math.round(red / 255 * 5) + 6 * Math.round(green / 255 * 5) + Math.round(blue / 255 * 5);
104
+ },
105
+ enumerable: false
106
+ },
107
+ hexToRgb: {
108
+ value(hex) {
109
+ const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
110
+ if (!matches) {
111
+ return [0, 0, 0];
112
+ }
113
+ let [colorString] = matches;
114
+ if (colorString.length === 3) {
115
+ colorString = [...colorString].map((character) => character + character).join("");
116
+ }
117
+ const integer = Number.parseInt(colorString, 16);
118
+ return [
119
+ integer >> 16 & 255,
120
+ integer >> 8 & 255,
121
+ integer & 255
122
+ ];
123
+ },
124
+ enumerable: false
125
+ },
126
+ hexToAnsi256: {
127
+ value: (hex) => styles.rgbToAnsi256(...styles.hexToRgb(hex)),
128
+ enumerable: false
129
+ },
130
+ ansi256ToAnsi: {
131
+ value(code) {
132
+ if (code < 8) {
133
+ return 30 + code;
134
+ }
135
+ if (code < 16) {
136
+ return 90 + (code - 8);
137
+ }
138
+ let red;
139
+ let green;
140
+ let blue;
141
+ if (code >= 232) {
142
+ red = ((code - 232) * 10 + 8) / 255;
143
+ green = red;
144
+ blue = red;
145
+ } else {
146
+ code -= 16;
147
+ const remainder = code % 36;
148
+ red = Math.floor(code / 36) / 5;
149
+ green = Math.floor(remainder / 6) / 5;
150
+ blue = remainder % 6 / 5;
151
+ }
152
+ const value = Math.max(red, green, blue) * 2;
153
+ if (value === 0) {
154
+ return 30;
155
+ }
156
+ let result = 30 + (Math.round(blue) << 2 | Math.round(green) << 1 | Math.round(red));
157
+ if (value === 2) {
158
+ result += 60;
159
+ }
160
+ return result;
161
+ },
162
+ enumerable: false
163
+ },
164
+ rgbToAnsi: {
165
+ value: (red, green, blue) => styles.ansi256ToAnsi(styles.rgbToAnsi256(red, green, blue)),
166
+ enumerable: false
167
+ },
168
+ hexToAnsi: {
169
+ value: (hex) => styles.ansi256ToAnsi(styles.hexToAnsi256(hex)),
170
+ enumerable: false
171
+ }
172
+ });
173
+ return styles;
174
+ }
175
+ var ansiStyles = assembleStyles();
176
+ var ansi_styles_default = ansiStyles;
177
+
178
+ // ../../node_modules/.bun/chalk@5.6.2/node_modules/chalk/source/vendor/supports-color/index.js
179
+ import process from "node:process";
180
+ import os from "node:os";
181
+ import tty from "node:tty";
182
+ function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : process.argv) {
183
+ const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
184
+ const position = argv.indexOf(prefix + flag);
185
+ const terminatorPosition = argv.indexOf("--");
186
+ return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
187
+ }
188
+ var { env } = process;
189
+ var flagForceColor;
190
+ if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) {
191
+ flagForceColor = 0;
192
+ } else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) {
193
+ flagForceColor = 1;
194
+ }
195
+ function envForceColor() {
196
+ if ("FORCE_COLOR" in env) {
197
+ if (env.FORCE_COLOR === "true") {
198
+ return 1;
199
+ }
200
+ if (env.FORCE_COLOR === "false") {
201
+ return 0;
202
+ }
203
+ return env.FORCE_COLOR.length === 0 ? 1 : Math.min(Number.parseInt(env.FORCE_COLOR, 10), 3);
204
+ }
205
+ }
206
+ function translateLevel(level) {
207
+ if (level === 0) {
208
+ return false;
209
+ }
210
+ return {
211
+ level,
212
+ hasBasic: true,
213
+ has256: level >= 2,
214
+ has16m: level >= 3
215
+ };
216
+ }
217
+ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
218
+ const noFlagForceColor = envForceColor();
219
+ if (noFlagForceColor !== undefined) {
220
+ flagForceColor = noFlagForceColor;
221
+ }
222
+ const forceColor = sniffFlags ? flagForceColor : noFlagForceColor;
223
+ if (forceColor === 0) {
224
+ return 0;
225
+ }
226
+ if (sniffFlags) {
227
+ if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) {
228
+ return 3;
229
+ }
230
+ if (hasFlag("color=256")) {
231
+ return 2;
232
+ }
233
+ }
234
+ if ("TF_BUILD" in env && "AGENT_NAME" in env) {
235
+ return 1;
236
+ }
237
+ if (haveStream && !streamIsTTY && forceColor === undefined) {
238
+ return 0;
239
+ }
240
+ const min = forceColor || 0;
241
+ if (env.TERM === "dumb") {
242
+ return min;
243
+ }
244
+ if (process.platform === "win32") {
245
+ const osRelease = os.release().split(".");
246
+ if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
247
+ return Number(osRelease[2]) >= 14931 ? 3 : 2;
248
+ }
249
+ return 1;
250
+ }
251
+ if ("CI" in env) {
252
+ if (["GITHUB_ACTIONS", "GITEA_ACTIONS", "CIRCLECI"].some((key) => (key in env))) {
253
+ return 3;
254
+ }
255
+ if (["TRAVIS", "APPVEYOR", "GITLAB_CI", "BUILDKITE", "DRONE"].some((sign) => (sign in env)) || env.CI_NAME === "codeship") {
256
+ return 1;
257
+ }
258
+ return min;
259
+ }
260
+ if ("TEAMCITY_VERSION" in env) {
261
+ return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
262
+ }
263
+ if (env.COLORTERM === "truecolor") {
264
+ return 3;
265
+ }
266
+ if (env.TERM === "xterm-kitty") {
267
+ return 3;
268
+ }
269
+ if (env.TERM === "xterm-ghostty") {
270
+ return 3;
271
+ }
272
+ if (env.TERM === "wezterm") {
273
+ return 3;
274
+ }
275
+ if ("TERM_PROGRAM" in env) {
276
+ const version = Number.parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
277
+ switch (env.TERM_PROGRAM) {
278
+ case "iTerm.app": {
279
+ return version >= 3 ? 3 : 2;
280
+ }
281
+ case "Apple_Terminal": {
282
+ return 2;
283
+ }
284
+ }
285
+ }
286
+ if (/-256(color)?$/i.test(env.TERM)) {
287
+ return 2;
288
+ }
289
+ if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {
290
+ return 1;
291
+ }
292
+ if ("COLORTERM" in env) {
293
+ return 1;
294
+ }
295
+ return min;
296
+ }
297
+ function createSupportsColor(stream, options = {}) {
298
+ const level = _supportsColor(stream, {
299
+ streamIsTTY: stream && stream.isTTY,
300
+ ...options
301
+ });
302
+ return translateLevel(level);
303
+ }
304
+ var supportsColor = {
305
+ stdout: createSupportsColor({ isTTY: tty.isatty(1) }),
306
+ stderr: createSupportsColor({ isTTY: tty.isatty(2) })
307
+ };
308
+ var supports_color_default = supportsColor;
309
+
310
+ // ../../node_modules/.bun/chalk@5.6.2/node_modules/chalk/source/utilities.js
311
+ function stringReplaceAll(string, substring, replacer) {
312
+ let index = string.indexOf(substring);
313
+ if (index === -1) {
314
+ return string;
315
+ }
316
+ const substringLength = substring.length;
317
+ let endIndex = 0;
318
+ let returnValue = "";
319
+ do {
320
+ returnValue += string.slice(endIndex, index) + substring + replacer;
321
+ endIndex = index + substringLength;
322
+ index = string.indexOf(substring, endIndex);
323
+ } while (index !== -1);
324
+ returnValue += string.slice(endIndex);
325
+ return returnValue;
326
+ }
327
+ function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
328
+ let endIndex = 0;
329
+ let returnValue = "";
330
+ do {
331
+ const gotCR = string[index - 1] === "\r";
332
+ returnValue += string.slice(endIndex, gotCR ? index - 1 : index) + prefix + (gotCR ? `\r
333
+ ` : `
334
+ `) + postfix;
335
+ endIndex = index + 1;
336
+ index = string.indexOf(`
337
+ `, endIndex);
338
+ } while (index !== -1);
339
+ returnValue += string.slice(endIndex);
340
+ return returnValue;
341
+ }
342
+
343
+ // ../../node_modules/.bun/chalk@5.6.2/node_modules/chalk/source/index.js
344
+ var { stdout: stdoutColor, stderr: stderrColor } = supports_color_default;
345
+ var GENERATOR = Symbol("GENERATOR");
346
+ var STYLER = Symbol("STYLER");
347
+ var IS_EMPTY = Symbol("IS_EMPTY");
348
+ var levelMapping = [
349
+ "ansi",
350
+ "ansi",
351
+ "ansi256",
352
+ "ansi16m"
353
+ ];
354
+ var styles2 = Object.create(null);
355
+ var applyOptions = (object, options = {}) => {
356
+ if (options.level && !(Number.isInteger(options.level) && options.level >= 0 && options.level <= 3)) {
357
+ throw new Error("The `level` option should be an integer from 0 to 3");
358
+ }
359
+ const colorLevel = stdoutColor ? stdoutColor.level : 0;
360
+ object.level = options.level === undefined ? colorLevel : options.level;
361
+ };
362
+ var chalkFactory = (options) => {
363
+ const chalk = (...strings) => strings.join(" ");
364
+ applyOptions(chalk, options);
365
+ Object.setPrototypeOf(chalk, createChalk.prototype);
366
+ return chalk;
367
+ };
368
+ function createChalk(options) {
369
+ return chalkFactory(options);
370
+ }
371
+ Object.setPrototypeOf(createChalk.prototype, Function.prototype);
372
+ for (const [styleName, style] of Object.entries(ansi_styles_default)) {
373
+ styles2[styleName] = {
374
+ get() {
375
+ const builder = createBuilder(this, createStyler(style.open, style.close, this[STYLER]), this[IS_EMPTY]);
376
+ Object.defineProperty(this, styleName, { value: builder });
377
+ return builder;
378
+ }
379
+ };
380
+ }
381
+ styles2.visible = {
382
+ get() {
383
+ const builder = createBuilder(this, this[STYLER], true);
384
+ Object.defineProperty(this, "visible", { value: builder });
385
+ return builder;
386
+ }
387
+ };
388
+ var getModelAnsi = (model, level, type, ...arguments_) => {
389
+ if (model === "rgb") {
390
+ if (level === "ansi16m") {
391
+ return ansi_styles_default[type].ansi16m(...arguments_);
392
+ }
393
+ if (level === "ansi256") {
394
+ return ansi_styles_default[type].ansi256(ansi_styles_default.rgbToAnsi256(...arguments_));
395
+ }
396
+ return ansi_styles_default[type].ansi(ansi_styles_default.rgbToAnsi(...arguments_));
397
+ }
398
+ if (model === "hex") {
399
+ return getModelAnsi("rgb", level, type, ...ansi_styles_default.hexToRgb(...arguments_));
400
+ }
401
+ return ansi_styles_default[type][model](...arguments_);
402
+ };
403
+ var usedModels = ["rgb", "hex", "ansi256"];
404
+ for (const model of usedModels) {
405
+ styles2[model] = {
406
+ get() {
407
+ const { level } = this;
408
+ return function(...arguments_) {
409
+ const styler = createStyler(getModelAnsi(model, levelMapping[level], "color", ...arguments_), ansi_styles_default.color.close, this[STYLER]);
410
+ return createBuilder(this, styler, this[IS_EMPTY]);
411
+ };
412
+ }
413
+ };
414
+ const bgModel = "bg" + model[0].toUpperCase() + model.slice(1);
415
+ styles2[bgModel] = {
416
+ get() {
417
+ const { level } = this;
418
+ return function(...arguments_) {
419
+ const styler = createStyler(getModelAnsi(model, levelMapping[level], "bgColor", ...arguments_), ansi_styles_default.bgColor.close, this[STYLER]);
420
+ return createBuilder(this, styler, this[IS_EMPTY]);
421
+ };
422
+ }
423
+ };
424
+ }
425
+ var proto = Object.defineProperties(() => {}, {
426
+ ...styles2,
427
+ level: {
428
+ enumerable: true,
429
+ get() {
430
+ return this[GENERATOR].level;
431
+ },
432
+ set(level) {
433
+ this[GENERATOR].level = level;
434
+ }
435
+ }
436
+ });
437
+ var createStyler = (open, close, parent) => {
438
+ let openAll;
439
+ let closeAll;
440
+ if (parent === undefined) {
441
+ openAll = open;
442
+ closeAll = close;
443
+ } else {
444
+ openAll = parent.openAll + open;
445
+ closeAll = close + parent.closeAll;
446
+ }
447
+ return {
448
+ open,
449
+ close,
450
+ openAll,
451
+ closeAll,
452
+ parent
453
+ };
454
+ };
455
+ var createBuilder = (self, _styler, _isEmpty) => {
456
+ const builder = (...arguments_) => applyStyle(builder, arguments_.length === 1 ? "" + arguments_[0] : arguments_.join(" "));
457
+ Object.setPrototypeOf(builder, proto);
458
+ builder[GENERATOR] = self;
459
+ builder[STYLER] = _styler;
460
+ builder[IS_EMPTY] = _isEmpty;
461
+ return builder;
462
+ };
463
+ var applyStyle = (self, string) => {
464
+ if (self.level <= 0 || !string) {
465
+ return self[IS_EMPTY] ? "" : string;
466
+ }
467
+ let styler = self[STYLER];
468
+ if (styler === undefined) {
469
+ return string;
470
+ }
471
+ const { openAll, closeAll } = styler;
472
+ if (string.includes("\x1B")) {
473
+ while (styler !== undefined) {
474
+ string = stringReplaceAll(string, styler.close, styler.open);
475
+ styler = styler.parent;
476
+ }
477
+ }
478
+ const lfIndex = string.indexOf(`
479
+ `);
480
+ if (lfIndex !== -1) {
481
+ string = stringEncaseCRLFWithFirstIndex(string, closeAll, openAll, lfIndex);
482
+ }
483
+ return openAll + string + closeAll;
484
+ };
485
+ Object.defineProperties(createChalk.prototype, styles2);
486
+ var chalk = createChalk();
487
+ var chalkStderr = createChalk({ level: stderrColor ? stderrColor.level : 0 });
488
+ var source_default = chalk;
489
+
490
+ // ../../node_modules/.bun/ansi-regex@6.2.2/node_modules/ansi-regex/index.js
491
+ function ansiRegex({ onlyFirst = false } = {}) {
492
+ const ST = "(?:\\u0007|\\u001B\\u005C|\\u009C)";
493
+ const osc = `(?:\\u001B\\][\\s\\S]*?${ST})`;
494
+ const csi = "[\\u001B\\u009B][[\\]()#;?]*(?:\\d{1,4}(?:[;:]\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]";
495
+ const pattern = `${osc}|${csi}`;
496
+ return new RegExp(pattern, onlyFirst ? undefined : "g");
497
+ }
498
+
499
+ // ../../node_modules/.bun/strip-ansi@7.2.0/node_modules/strip-ansi/index.js
500
+ var regex = ansiRegex();
501
+ function stripAnsi(string) {
502
+ if (typeof string !== "string") {
503
+ throw new TypeError(`Expected a \`string\`, got \`${typeof string}\``);
504
+ }
505
+ if (!string.includes("\x1B") && !string.includes("›")) {
506
+ return string;
507
+ }
508
+ return string.replace(regex, "");
509
+ }
510
+
511
+ // ../../node_modules/.bun/get-east-asian-width@1.5.0/node_modules/get-east-asian-width/lookup-data.js
512
+ var ambiguousRanges = [161, 161, 164, 164, 167, 168, 170, 170, 173, 174, 176, 180, 182, 186, 188, 191, 198, 198, 208, 208, 215, 216, 222, 225, 230, 230, 232, 234, 236, 237, 240, 240, 242, 243, 247, 250, 252, 252, 254, 254, 257, 257, 273, 273, 275, 275, 283, 283, 294, 295, 299, 299, 305, 307, 312, 312, 319, 322, 324, 324, 328, 331, 333, 333, 338, 339, 358, 359, 363, 363, 462, 462, 464, 464, 466, 466, 468, 468, 470, 470, 472, 472, 474, 474, 476, 476, 593, 593, 609, 609, 708, 708, 711, 711, 713, 715, 717, 717, 720, 720, 728, 731, 733, 733, 735, 735, 768, 879, 913, 929, 931, 937, 945, 961, 963, 969, 1025, 1025, 1040, 1103, 1105, 1105, 8208, 8208, 8211, 8214, 8216, 8217, 8220, 8221, 8224, 8226, 8228, 8231, 8240, 8240, 8242, 8243, 8245, 8245, 8251, 8251, 8254, 8254, 8308, 8308, 8319, 8319, 8321, 8324, 8364, 8364, 8451, 8451, 8453, 8453, 8457, 8457, 8467, 8467, 8470, 8470, 8481, 8482, 8486, 8486, 8491, 8491, 8531, 8532, 8539, 8542, 8544, 8555, 8560, 8569, 8585, 8585, 8592, 8601, 8632, 8633, 8658, 8658, 8660, 8660, 8679, 8679, 8704, 8704, 8706, 8707, 8711, 8712, 8715, 8715, 8719, 8719, 8721, 8721, 8725, 8725, 8730, 8730, 8733, 8736, 8739, 8739, 8741, 8741, 8743, 8748, 8750, 8750, 8756, 8759, 8764, 8765, 8776, 8776, 8780, 8780, 8786, 8786, 8800, 8801, 8804, 8807, 8810, 8811, 8814, 8815, 8834, 8835, 8838, 8839, 8853, 8853, 8857, 8857, 8869, 8869, 8895, 8895, 8978, 8978, 9312, 9449, 9451, 9547, 9552, 9587, 9600, 9615, 9618, 9621, 9632, 9633, 9635, 9641, 9650, 9651, 9654, 9655, 9660, 9661, 9664, 9665, 9670, 9672, 9675, 9675, 9678, 9681, 9698, 9701, 9711, 9711, 9733, 9734, 9737, 9737, 9742, 9743, 9756, 9756, 9758, 9758, 9792, 9792, 9794, 9794, 9824, 9825, 9827, 9829, 9831, 9834, 9836, 9837, 9839, 9839, 9886, 9887, 9919, 9919, 9926, 9933, 9935, 9939, 9941, 9953, 9955, 9955, 9960, 9961, 9963, 9969, 9972, 9972, 9974, 9977, 9979, 9980, 9982, 9983, 10045, 10045, 10102, 10111, 11094, 11097, 12872, 12879, 57344, 63743, 65024, 65039, 65533, 65533, 127232, 127242, 127248, 127277, 127280, 127337, 127344, 127373, 127375, 127376, 127387, 127404, 917760, 917999, 983040, 1048573, 1048576, 1114109];
513
+ var fullwidthRanges = [12288, 12288, 65281, 65376, 65504, 65510];
514
+ var halfwidthRanges = [8361, 8361, 65377, 65470, 65474, 65479, 65482, 65487, 65490, 65495, 65498, 65500, 65512, 65518];
515
+ var narrowRanges = [32, 126, 162, 163, 165, 166, 172, 172, 175, 175, 10214, 10221, 10629, 10630];
516
+ var wideRanges = [4352, 4447, 8986, 8987, 9001, 9002, 9193, 9196, 9200, 9200, 9203, 9203, 9725, 9726, 9748, 9749, 9776, 9783, 9800, 9811, 9855, 9855, 9866, 9871, 9875, 9875, 9889, 9889, 9898, 9899, 9917, 9918, 9924, 9925, 9934, 9934, 9940, 9940, 9962, 9962, 9970, 9971, 9973, 9973, 9978, 9978, 9981, 9981, 9989, 9989, 9994, 9995, 10024, 10024, 10060, 10060, 10062, 10062, 10067, 10069, 10071, 10071, 10133, 10135, 10160, 10160, 10175, 10175, 11035, 11036, 11088, 11088, 11093, 11093, 11904, 11929, 11931, 12019, 12032, 12245, 12272, 12287, 12289, 12350, 12353, 12438, 12441, 12543, 12549, 12591, 12593, 12686, 12688, 12773, 12783, 12830, 12832, 12871, 12880, 42124, 42128, 42182, 43360, 43388, 44032, 55203, 63744, 64255, 65040, 65049, 65072, 65106, 65108, 65126, 65128, 65131, 94176, 94180, 94192, 94198, 94208, 101589, 101631, 101662, 101760, 101874, 110576, 110579, 110581, 110587, 110589, 110590, 110592, 110882, 110898, 110898, 110928, 110930, 110933, 110933, 110948, 110951, 110960, 111355, 119552, 119638, 119648, 119670, 126980, 126980, 127183, 127183, 127374, 127374, 127377, 127386, 127488, 127490, 127504, 127547, 127552, 127560, 127568, 127569, 127584, 127589, 127744, 127776, 127789, 127797, 127799, 127868, 127870, 127891, 127904, 127946, 127951, 127955, 127968, 127984, 127988, 127988, 127992, 128062, 128064, 128064, 128066, 128252, 128255, 128317, 128331, 128334, 128336, 128359, 128378, 128378, 128405, 128406, 128420, 128420, 128507, 128591, 128640, 128709, 128716, 128716, 128720, 128722, 128725, 128728, 128732, 128735, 128747, 128748, 128756, 128764, 128992, 129003, 129008, 129008, 129292, 129338, 129340, 129349, 129351, 129535, 129648, 129660, 129664, 129674, 129678, 129734, 129736, 129736, 129741, 129756, 129759, 129770, 129775, 129784, 131072, 196605, 196608, 262141];
517
+
518
+ // ../../node_modules/.bun/get-east-asian-width@1.5.0/node_modules/get-east-asian-width/utilities.js
519
+ var isInRange = (ranges, codePoint) => {
520
+ let low = 0;
521
+ let high = Math.floor(ranges.length / 2) - 1;
522
+ while (low <= high) {
523
+ const mid = Math.floor((low + high) / 2);
524
+ const i = mid * 2;
525
+ if (codePoint < ranges[i]) {
526
+ high = mid - 1;
527
+ } else if (codePoint > ranges[i + 1]) {
528
+ low = mid + 1;
529
+ } else {
530
+ return true;
531
+ }
532
+ }
533
+ return false;
534
+ };
535
+
536
+ // ../../node_modules/.bun/get-east-asian-width@1.5.0/node_modules/get-east-asian-width/lookup.js
537
+ var minimumAmbiguousCodePoint = ambiguousRanges[0];
538
+ var maximumAmbiguousCodePoint = ambiguousRanges.at(-1);
539
+ var minimumFullWidthCodePoint = fullwidthRanges[0];
540
+ var maximumFullWidthCodePoint = fullwidthRanges.at(-1);
541
+ var minimumHalfWidthCodePoint = halfwidthRanges[0];
542
+ var maximumHalfWidthCodePoint = halfwidthRanges.at(-1);
543
+ var minimumNarrowCodePoint = narrowRanges[0];
544
+ var maximumNarrowCodePoint = narrowRanges.at(-1);
545
+ var minimumWideCodePoint = wideRanges[0];
546
+ var maximumWideCodePoint = wideRanges.at(-1);
547
+ var commonCjkCodePoint = 19968;
548
+ var [wideFastPathStart, wideFastPathEnd] = findWideFastPathRange(wideRanges);
549
+ function findWideFastPathRange(ranges) {
550
+ let fastPathStart = ranges[0];
551
+ let fastPathEnd = ranges[1];
552
+ for (let index = 0;index < ranges.length; index += 2) {
553
+ const start = ranges[index];
554
+ const end = ranges[index + 1];
555
+ if (commonCjkCodePoint >= start && commonCjkCodePoint <= end) {
556
+ return [start, end];
557
+ }
558
+ if (end - start > fastPathEnd - fastPathStart) {
559
+ fastPathStart = start;
560
+ fastPathEnd = end;
561
+ }
562
+ }
563
+ return [fastPathStart, fastPathEnd];
564
+ }
565
+ var isAmbiguous = (codePoint) => {
566
+ if (codePoint < minimumAmbiguousCodePoint || codePoint > maximumAmbiguousCodePoint) {
567
+ return false;
568
+ }
569
+ return isInRange(ambiguousRanges, codePoint);
570
+ };
571
+ var isFullWidth = (codePoint) => {
572
+ if (codePoint < minimumFullWidthCodePoint || codePoint > maximumFullWidthCodePoint) {
573
+ return false;
574
+ }
575
+ return isInRange(fullwidthRanges, codePoint);
576
+ };
577
+ var isWide = (codePoint) => {
578
+ if (codePoint >= wideFastPathStart && codePoint <= wideFastPathEnd) {
579
+ return true;
580
+ }
581
+ if (codePoint < minimumWideCodePoint || codePoint > maximumWideCodePoint) {
582
+ return false;
583
+ }
584
+ return isInRange(wideRanges, codePoint);
585
+ };
586
+
587
+ // ../../node_modules/.bun/get-east-asian-width@1.5.0/node_modules/get-east-asian-width/index.js
588
+ function validate(codePoint) {
589
+ if (!Number.isSafeInteger(codePoint)) {
590
+ throw new TypeError(`Expected a code point, got \`${typeof codePoint}\`.`);
591
+ }
592
+ }
593
+ function eastAsianWidth(codePoint, { ambiguousAsWide = false } = {}) {
594
+ validate(codePoint);
595
+ if (isFullWidth(codePoint) || isWide(codePoint) || ambiguousAsWide && isAmbiguous(codePoint)) {
596
+ return 2;
597
+ }
598
+ return 1;
599
+ }
600
+
601
+ export { source_default, stripAnsi, isFullWidth, isWide, eastAsianWidth };