sveltekit-temporal 0.1.0 → 0.3.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.
package/dist/index.js ADDED
@@ -0,0 +1,929 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __commonJS = (cb, mod) => function __require() {
8
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
19
+ // If the importer is in node compatibility mode or this is not an ESM
20
+ // file that has been converted to a CommonJS file using a Babel-
21
+ // compatible transform (i.e. "__esModule" has not been set), then set
22
+ // "default" to the CommonJS "module.exports" for node compatibility.
23
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
24
+ mod
25
+ ));
26
+
27
+ // node_modules/sisteransi/src/index.js
28
+ var require_src = __commonJS({
29
+ "node_modules/sisteransi/src/index.js"(exports, module) {
30
+ "use strict";
31
+ var ESC = "\x1B";
32
+ var CSI = `${ESC}[`;
33
+ var beep = "\x07";
34
+ var cursor = {
35
+ to(x3, y3) {
36
+ if (!y3) return `${CSI}${x3 + 1}G`;
37
+ return `${CSI}${y3 + 1};${x3 + 1}H`;
38
+ },
39
+ move(x3, y3) {
40
+ let ret = "";
41
+ if (x3 < 0) ret += `${CSI}${-x3}D`;
42
+ else if (x3 > 0) ret += `${CSI}${x3}C`;
43
+ if (y3 < 0) ret += `${CSI}${-y3}A`;
44
+ else if (y3 > 0) ret += `${CSI}${y3}B`;
45
+ return ret;
46
+ },
47
+ up: (count = 1) => `${CSI}${count}A`,
48
+ down: (count = 1) => `${CSI}${count}B`,
49
+ forward: (count = 1) => `${CSI}${count}C`,
50
+ backward: (count = 1) => `${CSI}${count}D`,
51
+ nextLine: (count = 1) => `${CSI}E`.repeat(count),
52
+ prevLine: (count = 1) => `${CSI}F`.repeat(count),
53
+ left: `${CSI}G`,
54
+ hide: `${CSI}?25l`,
55
+ show: `${CSI}?25h`,
56
+ save: `${ESC}7`,
57
+ restore: `${ESC}8`
58
+ };
59
+ var scroll = {
60
+ up: (count = 1) => `${CSI}S`.repeat(count),
61
+ down: (count = 1) => `${CSI}T`.repeat(count)
62
+ };
63
+ var erase = {
64
+ screen: `${CSI}2J`,
65
+ up: (count = 1) => `${CSI}1J`.repeat(count),
66
+ down: (count = 1) => `${CSI}J`.repeat(count),
67
+ line: `${CSI}2K`,
68
+ lineEnd: `${CSI}K`,
69
+ lineStart: `${CSI}1K`,
70
+ lines(count) {
71
+ let clear = "";
72
+ for (let i = 0; i < count; i++)
73
+ clear += this.line + (i < count - 1 ? cursor.up() : "");
74
+ if (count)
75
+ clear += cursor.left;
76
+ return clear;
77
+ }
78
+ };
79
+ module.exports = { cursor, scroll, erase, beep };
80
+ }
81
+ });
82
+
83
+ // node_modules/picocolors/picocolors.js
84
+ var require_picocolors = __commonJS({
85
+ "node_modules/picocolors/picocolors.js"(exports, module) {
86
+ var p = process || {};
87
+ var argv = p.argv || [];
88
+ var env = p.env || {};
89
+ var isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
90
+ var formatter = (open, close, replace = open) => (input) => {
91
+ let string = "" + input, index = string.indexOf(close, open.length);
92
+ return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
93
+ };
94
+ var replaceClose = (string, close, replace, index) => {
95
+ let result = "", cursor = 0;
96
+ do {
97
+ result += string.substring(cursor, index) + replace;
98
+ cursor = index + close.length;
99
+ index = string.indexOf(close, cursor);
100
+ } while (~index);
101
+ return result + string.substring(cursor);
102
+ };
103
+ var createColors = (enabled = isColorSupported) => {
104
+ let f3 = enabled ? formatter : () => String;
105
+ return {
106
+ isColorSupported: enabled,
107
+ reset: f3("\x1B[0m", "\x1B[0m"),
108
+ bold: f3("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"),
109
+ dim: f3("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"),
110
+ italic: f3("\x1B[3m", "\x1B[23m"),
111
+ underline: f3("\x1B[4m", "\x1B[24m"),
112
+ inverse: f3("\x1B[7m", "\x1B[27m"),
113
+ hidden: f3("\x1B[8m", "\x1B[28m"),
114
+ strikethrough: f3("\x1B[9m", "\x1B[29m"),
115
+ black: f3("\x1B[30m", "\x1B[39m"),
116
+ red: f3("\x1B[31m", "\x1B[39m"),
117
+ green: f3("\x1B[32m", "\x1B[39m"),
118
+ yellow: f3("\x1B[33m", "\x1B[39m"),
119
+ blue: f3("\x1B[34m", "\x1B[39m"),
120
+ magenta: f3("\x1B[35m", "\x1B[39m"),
121
+ cyan: f3("\x1B[36m", "\x1B[39m"),
122
+ white: f3("\x1B[37m", "\x1B[39m"),
123
+ gray: f3("\x1B[90m", "\x1B[39m"),
124
+ bgBlack: f3("\x1B[40m", "\x1B[49m"),
125
+ bgRed: f3("\x1B[41m", "\x1B[49m"),
126
+ bgGreen: f3("\x1B[42m", "\x1B[49m"),
127
+ bgYellow: f3("\x1B[43m", "\x1B[49m"),
128
+ bgBlue: f3("\x1B[44m", "\x1B[49m"),
129
+ bgMagenta: f3("\x1B[45m", "\x1B[49m"),
130
+ bgCyan: f3("\x1B[46m", "\x1B[49m"),
131
+ bgWhite: f3("\x1B[47m", "\x1B[49m"),
132
+ blackBright: f3("\x1B[90m", "\x1B[39m"),
133
+ redBright: f3("\x1B[91m", "\x1B[39m"),
134
+ greenBright: f3("\x1B[92m", "\x1B[39m"),
135
+ yellowBright: f3("\x1B[93m", "\x1B[39m"),
136
+ blueBright: f3("\x1B[94m", "\x1B[39m"),
137
+ magentaBright: f3("\x1B[95m", "\x1B[39m"),
138
+ cyanBright: f3("\x1B[96m", "\x1B[39m"),
139
+ whiteBright: f3("\x1B[97m", "\x1B[39m"),
140
+ bgBlackBright: f3("\x1B[100m", "\x1B[49m"),
141
+ bgRedBright: f3("\x1B[101m", "\x1B[49m"),
142
+ bgGreenBright: f3("\x1B[102m", "\x1B[49m"),
143
+ bgYellowBright: f3("\x1B[103m", "\x1B[49m"),
144
+ bgBlueBright: f3("\x1B[104m", "\x1B[49m"),
145
+ bgMagentaBright: f3("\x1B[105m", "\x1B[49m"),
146
+ bgCyanBright: f3("\x1B[106m", "\x1B[49m"),
147
+ bgWhiteBright: f3("\x1B[107m", "\x1B[49m")
148
+ };
149
+ };
150
+ module.exports = createColors();
151
+ module.exports.createColors = createColors;
152
+ }
153
+ });
154
+
155
+ // src/index.js
156
+ import { existsSync, readFileSync, writeFileSync, mkdirSync } from "node:fs";
157
+ import { join, dirname } from "node:path";
158
+ import { execSync } from "node:child_process";
159
+
160
+ // node_modules/@clack/core/dist/index.mjs
161
+ var import_sisteransi = __toESM(require_src(), 1);
162
+ import { stdin as $, stdout as k } from "node:process";
163
+ import * as f from "node:readline";
164
+ import _ from "node:readline";
165
+ import { WriteStream as U } from "node:tty";
166
+ function q({ onlyFirst: e2 = false } = {}) {
167
+ const F = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?(?:\\u0007|\\u001B\\u005C|\\u009C))", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
168
+ return new RegExp(F, e2 ? void 0 : "g");
169
+ }
170
+ var J = q();
171
+ function S(e2) {
172
+ if (typeof e2 != "string") throw new TypeError(`Expected a \`string\`, got \`${typeof e2}\``);
173
+ return e2.replace(J, "");
174
+ }
175
+ function T(e2) {
176
+ return e2 && e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
177
+ }
178
+ var j = { exports: {} };
179
+ (function(e2) {
180
+ var u = {};
181
+ e2.exports = u, u.eastAsianWidth = function(t) {
182
+ var s = t.charCodeAt(0), C2 = t.length == 2 ? t.charCodeAt(1) : 0, D = s;
183
+ return 55296 <= s && s <= 56319 && 56320 <= C2 && C2 <= 57343 && (s &= 1023, C2 &= 1023, D = s << 10 | C2, D += 65536), D == 12288 || 65281 <= D && D <= 65376 || 65504 <= D && D <= 65510 ? "F" : D == 8361 || 65377 <= D && D <= 65470 || 65474 <= D && D <= 65479 || 65482 <= D && D <= 65487 || 65490 <= D && D <= 65495 || 65498 <= D && D <= 65500 || 65512 <= D && D <= 65518 ? "H" : 4352 <= D && D <= 4447 || 4515 <= D && D <= 4519 || 4602 <= D && D <= 4607 || 9001 <= D && D <= 9002 || 11904 <= D && D <= 11929 || 11931 <= D && D <= 12019 || 12032 <= D && D <= 12245 || 12272 <= D && D <= 12283 || 12289 <= D && D <= 12350 || 12353 <= D && D <= 12438 || 12441 <= D && D <= 12543 || 12549 <= D && D <= 12589 || 12593 <= D && D <= 12686 || 12688 <= D && D <= 12730 || 12736 <= D && D <= 12771 || 12784 <= D && D <= 12830 || 12832 <= D && D <= 12871 || 12880 <= D && D <= 13054 || 13056 <= D && D <= 19903 || 19968 <= D && D <= 42124 || 42128 <= D && D <= 42182 || 43360 <= D && D <= 43388 || 44032 <= D && D <= 55203 || 55216 <= D && D <= 55238 || 55243 <= D && D <= 55291 || 63744 <= D && D <= 64255 || 65040 <= D && D <= 65049 || 65072 <= D && D <= 65106 || 65108 <= D && D <= 65126 || 65128 <= D && D <= 65131 || 110592 <= D && D <= 110593 || 127488 <= D && D <= 127490 || 127504 <= D && D <= 127546 || 127552 <= D && D <= 127560 || 127568 <= D && D <= 127569 || 131072 <= D && D <= 194367 || 177984 <= D && D <= 196605 || 196608 <= D && D <= 262141 ? "W" : 32 <= D && D <= 126 || 162 <= D && D <= 163 || 165 <= D && D <= 166 || D == 172 || D == 175 || 10214 <= D && D <= 10221 || 10629 <= D && D <= 10630 ? "Na" : D == 161 || D == 164 || 167 <= D && D <= 168 || D == 170 || 173 <= D && D <= 174 || 176 <= D && D <= 180 || 182 <= D && D <= 186 || 188 <= D && D <= 191 || D == 198 || D == 208 || 215 <= D && D <= 216 || 222 <= D && D <= 225 || D == 230 || 232 <= D && D <= 234 || 236 <= D && D <= 237 || D == 240 || 242 <= D && D <= 243 || 247 <= D && D <= 250 || D == 252 || D == 254 || D == 257 || D == 273 || D == 275 || D == 283 || 294 <= D && D <= 295 || D == 299 || 305 <= D && D <= 307 || D == 312 || 319 <= D && D <= 322 || D == 324 || 328 <= D && D <= 331 || D == 333 || 338 <= D && D <= 339 || 358 <= D && D <= 359 || D == 363 || D == 462 || D == 464 || D == 466 || D == 468 || D == 470 || D == 472 || D == 474 || D == 476 || D == 593 || D == 609 || D == 708 || D == 711 || 713 <= D && D <= 715 || D == 717 || D == 720 || 728 <= D && D <= 731 || D == 733 || D == 735 || 768 <= D && D <= 879 || 913 <= D && D <= 929 || 931 <= D && D <= 937 || 945 <= D && D <= 961 || 963 <= D && D <= 969 || D == 1025 || 1040 <= D && D <= 1103 || D == 1105 || D == 8208 || 8211 <= D && D <= 8214 || 8216 <= D && D <= 8217 || 8220 <= D && D <= 8221 || 8224 <= D && D <= 8226 || 8228 <= D && D <= 8231 || D == 8240 || 8242 <= D && D <= 8243 || D == 8245 || D == 8251 || D == 8254 || D == 8308 || D == 8319 || 8321 <= D && D <= 8324 || D == 8364 || D == 8451 || D == 8453 || D == 8457 || D == 8467 || D == 8470 || 8481 <= D && D <= 8482 || D == 8486 || D == 8491 || 8531 <= D && D <= 8532 || 8539 <= D && D <= 8542 || 8544 <= D && D <= 8555 || 8560 <= D && D <= 8569 || D == 8585 || 8592 <= D && D <= 8601 || 8632 <= D && D <= 8633 || D == 8658 || D == 8660 || D == 8679 || D == 8704 || 8706 <= D && D <= 8707 || 8711 <= D && D <= 8712 || D == 8715 || D == 8719 || D == 8721 || D == 8725 || D == 8730 || 8733 <= D && D <= 8736 || D == 8739 || D == 8741 || 8743 <= D && D <= 8748 || D == 8750 || 8756 <= D && D <= 8759 || 8764 <= D && D <= 8765 || D == 8776 || D == 8780 || D == 8786 || 8800 <= D && D <= 8801 || 8804 <= D && D <= 8807 || 8810 <= D && D <= 8811 || 8814 <= D && D <= 8815 || 8834 <= D && D <= 8835 || 8838 <= D && D <= 8839 || D == 8853 || D == 8857 || D == 8869 || D == 8895 || D == 8978 || 9312 <= D && D <= 9449 || 9451 <= D && D <= 9547 || 9552 <= D && D <= 9587 || 9600 <= D && D <= 9615 || 9618 <= D && D <= 9621 || 9632 <= D && D <= 9633 || 9635 <= D && D <= 9641 || 9650 <= D && D <= 9651 || 9654 <= D && D <= 9655 || 9660 <= D && D <= 9661 || 9664 <= D && D <= 9665 || 9670 <= D && D <= 9672 || D == 9675 || 9678 <= D && D <= 9681 || 9698 <= D && D <= 9701 || D == 9711 || 9733 <= D && D <= 9734 || D == 9737 || 9742 <= D && D <= 9743 || 9748 <= D && D <= 9749 || D == 9756 || D == 9758 || D == 9792 || D == 9794 || 9824 <= D && D <= 9825 || 9827 <= D && D <= 9829 || 9831 <= D && D <= 9834 || 9836 <= D && D <= 9837 || D == 9839 || 9886 <= D && D <= 9887 || 9918 <= D && D <= 9919 || 9924 <= D && D <= 9933 || 9935 <= D && D <= 9953 || D == 9955 || 9960 <= D && D <= 9983 || D == 10045 || D == 10071 || 10102 <= D && D <= 10111 || 11093 <= D && D <= 11097 || 12872 <= D && D <= 12879 || 57344 <= D && D <= 63743 || 65024 <= D && D <= 65039 || D == 65533 || 127232 <= D && D <= 127242 || 127248 <= D && D <= 127277 || 127280 <= D && D <= 127337 || 127344 <= D && D <= 127386 || 917760 <= D && D <= 917999 || 983040 <= D && D <= 1048573 || 1048576 <= D && D <= 1114109 ? "A" : "N";
184
+ }, u.characterLength = function(t) {
185
+ var s = this.eastAsianWidth(t);
186
+ return s == "F" || s == "W" || s == "A" ? 2 : 1;
187
+ };
188
+ function F(t) {
189
+ return t.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g) || [];
190
+ }
191
+ u.length = function(t) {
192
+ for (var s = F(t), C2 = 0, D = 0; D < s.length; D++) C2 = C2 + this.characterLength(s[D]);
193
+ return C2;
194
+ }, u.slice = function(t, s, C2) {
195
+ textLen = u.length(t), s = s || 0, C2 = C2 || 1, s < 0 && (s = textLen + s), C2 < 0 && (C2 = textLen + C2);
196
+ for (var D = "", i = 0, n = F(t), E2 = 0; E2 < n.length; E2++) {
197
+ var h2 = n[E2], o2 = u.length(h2);
198
+ if (i >= s - (o2 == 2 ? 1 : 0)) if (i + o2 <= C2) D += h2;
199
+ else break;
200
+ i += o2;
201
+ }
202
+ return D;
203
+ };
204
+ })(j);
205
+ var Q = j.exports;
206
+ var X = T(Q);
207
+ var DD = function() {
208
+ return /\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\uD83D[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])\uFE0F|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g;
209
+ };
210
+ var uD = T(DD);
211
+ function A(e2, u = {}) {
212
+ if (typeof e2 != "string" || e2.length === 0 || (u = { ambiguousIsNarrow: true, ...u }, e2 = S(e2), e2.length === 0)) return 0;
213
+ e2 = e2.replace(uD(), " ");
214
+ const F = u.ambiguousIsNarrow ? 1 : 2;
215
+ let t = 0;
216
+ for (const s of e2) {
217
+ const C2 = s.codePointAt(0);
218
+ if (C2 <= 31 || C2 >= 127 && C2 <= 159 || C2 >= 768 && C2 <= 879) continue;
219
+ switch (X.eastAsianWidth(s)) {
220
+ case "F":
221
+ case "W":
222
+ t += 2;
223
+ break;
224
+ case "A":
225
+ t += F;
226
+ break;
227
+ default:
228
+ t += 1;
229
+ }
230
+ }
231
+ return t;
232
+ }
233
+ var d = 10;
234
+ var M = (e2 = 0) => (u) => `\x1B[${u + e2}m`;
235
+ var P = (e2 = 0) => (u) => `\x1B[${38 + e2};5;${u}m`;
236
+ var W = (e2 = 0) => (u, F, t) => `\x1B[${38 + e2};2;${u};${F};${t}m`;
237
+ var r = { modifier: { reset: [0, 0], bold: [1, 22], dim: [2, 22], italic: [3, 23], underline: [4, 24], overline: [53, 55], inverse: [7, 27], hidden: [8, 28], strikethrough: [9, 29] }, color: { black: [30, 39], red: [31, 39], green: [32, 39], yellow: [33, 39], blue: [34, 39], magenta: [35, 39], cyan: [36, 39], white: [37, 39], blackBright: [90, 39], gray: [90, 39], grey: [90, 39], redBright: [91, 39], greenBright: [92, 39], yellowBright: [93, 39], blueBright: [94, 39], magentaBright: [95, 39], cyanBright: [96, 39], whiteBright: [97, 39] }, bgColor: { bgBlack: [40, 49], bgRed: [41, 49], bgGreen: [42, 49], bgYellow: [43, 49], bgBlue: [44, 49], bgMagenta: [45, 49], bgCyan: [46, 49], bgWhite: [47, 49], bgBlackBright: [100, 49], bgGray: [100, 49], bgGrey: [100, 49], bgRedBright: [101, 49], bgGreenBright: [102, 49], bgYellowBright: [103, 49], bgBlueBright: [104, 49], bgMagentaBright: [105, 49], bgCyanBright: [106, 49], bgWhiteBright: [107, 49] } };
238
+ Object.keys(r.modifier);
239
+ var FD = Object.keys(r.color);
240
+ var eD = Object.keys(r.bgColor);
241
+ [...FD, ...eD];
242
+ function tD() {
243
+ const e2 = /* @__PURE__ */ new Map();
244
+ for (const [u, F] of Object.entries(r)) {
245
+ for (const [t, s] of Object.entries(F)) r[t] = { open: `\x1B[${s[0]}m`, close: `\x1B[${s[1]}m` }, F[t] = r[t], e2.set(s[0], s[1]);
246
+ Object.defineProperty(r, u, { value: F, enumerable: false });
247
+ }
248
+ return Object.defineProperty(r, "codes", { value: e2, enumerable: false }), r.color.close = "\x1B[39m", r.bgColor.close = "\x1B[49m", r.color.ansi = M(), r.color.ansi256 = P(), r.color.ansi16m = W(), r.bgColor.ansi = M(d), r.bgColor.ansi256 = P(d), r.bgColor.ansi16m = W(d), Object.defineProperties(r, { rgbToAnsi256: { value: (u, F, t) => u === F && F === t ? u < 8 ? 16 : u > 248 ? 231 : Math.round((u - 8) / 247 * 24) + 232 : 16 + 36 * Math.round(u / 255 * 5) + 6 * Math.round(F / 255 * 5) + Math.round(t / 255 * 5), enumerable: false }, hexToRgb: { value: (u) => {
249
+ const F = /[a-f\d]{6}|[a-f\d]{3}/i.exec(u.toString(16));
250
+ if (!F) return [0, 0, 0];
251
+ let [t] = F;
252
+ t.length === 3 && (t = [...t].map((C2) => C2 + C2).join(""));
253
+ const s = Number.parseInt(t, 16);
254
+ return [s >> 16 & 255, s >> 8 & 255, s & 255];
255
+ }, enumerable: false }, hexToAnsi256: { value: (u) => r.rgbToAnsi256(...r.hexToRgb(u)), enumerable: false }, ansi256ToAnsi: { value: (u) => {
256
+ if (u < 8) return 30 + u;
257
+ if (u < 16) return 90 + (u - 8);
258
+ let F, t, s;
259
+ if (u >= 232) F = ((u - 232) * 10 + 8) / 255, t = F, s = F;
260
+ else {
261
+ u -= 16;
262
+ const i = u % 36;
263
+ F = Math.floor(u / 36) / 5, t = Math.floor(i / 6) / 5, s = i % 6 / 5;
264
+ }
265
+ const C2 = Math.max(F, t, s) * 2;
266
+ if (C2 === 0) return 30;
267
+ let D = 30 + (Math.round(s) << 2 | Math.round(t) << 1 | Math.round(F));
268
+ return C2 === 2 && (D += 60), D;
269
+ }, enumerable: false }, rgbToAnsi: { value: (u, F, t) => r.ansi256ToAnsi(r.rgbToAnsi256(u, F, t)), enumerable: false }, hexToAnsi: { value: (u) => r.ansi256ToAnsi(r.hexToAnsi256(u)), enumerable: false } }), r;
270
+ }
271
+ var sD = tD();
272
+ var g = /* @__PURE__ */ new Set(["\x1B", "\x9B"]);
273
+ var CD = 39;
274
+ var b = "\x07";
275
+ var O = "[";
276
+ var iD = "]";
277
+ var I = "m";
278
+ var w = `${iD}8;;`;
279
+ var N = (e2) => `${g.values().next().value}${O}${e2}${I}`;
280
+ var L = (e2) => `${g.values().next().value}${w}${e2}${b}`;
281
+ var rD = (e2) => e2.split(" ").map((u) => A(u));
282
+ var y = (e2, u, F) => {
283
+ const t = [...u];
284
+ let s = false, C2 = false, D = A(S(e2[e2.length - 1]));
285
+ for (const [i, n] of t.entries()) {
286
+ const E2 = A(n);
287
+ if (D + E2 <= F ? e2[e2.length - 1] += n : (e2.push(n), D = 0), g.has(n) && (s = true, C2 = t.slice(i + 1).join("").startsWith(w)), s) {
288
+ C2 ? n === b && (s = false, C2 = false) : n === I && (s = false);
289
+ continue;
290
+ }
291
+ D += E2, D === F && i < t.length - 1 && (e2.push(""), D = 0);
292
+ }
293
+ !D && e2[e2.length - 1].length > 0 && e2.length > 1 && (e2[e2.length - 2] += e2.pop());
294
+ };
295
+ var ED = (e2) => {
296
+ const u = e2.split(" ");
297
+ let F = u.length;
298
+ for (; F > 0 && !(A(u[F - 1]) > 0); ) F--;
299
+ return F === u.length ? e2 : u.slice(0, F).join(" ") + u.slice(F).join("");
300
+ };
301
+ var oD = (e2, u, F = {}) => {
302
+ if (F.trim !== false && e2.trim() === "") return "";
303
+ let t = "", s, C2;
304
+ const D = rD(e2);
305
+ let i = [""];
306
+ for (const [E2, h2] of e2.split(" ").entries()) {
307
+ F.trim !== false && (i[i.length - 1] = i[i.length - 1].trimStart());
308
+ let o2 = A(i[i.length - 1]);
309
+ if (E2 !== 0 && (o2 >= u && (F.wordWrap === false || F.trim === false) && (i.push(""), o2 = 0), (o2 > 0 || F.trim === false) && (i[i.length - 1] += " ", o2++)), F.hard && D[E2] > u) {
310
+ const B2 = u - o2, p = 1 + Math.floor((D[E2] - B2 - 1) / u);
311
+ Math.floor((D[E2] - 1) / u) < p && i.push(""), y(i, h2, u);
312
+ continue;
313
+ }
314
+ if (o2 + D[E2] > u && o2 > 0 && D[E2] > 0) {
315
+ if (F.wordWrap === false && o2 < u) {
316
+ y(i, h2, u);
317
+ continue;
318
+ }
319
+ i.push("");
320
+ }
321
+ if (o2 + D[E2] > u && F.wordWrap === false) {
322
+ y(i, h2, u);
323
+ continue;
324
+ }
325
+ i[i.length - 1] += h2;
326
+ }
327
+ F.trim !== false && (i = i.map((E2) => ED(E2)));
328
+ const n = [...i.join(`
329
+ `)];
330
+ for (const [E2, h2] of n.entries()) {
331
+ if (t += h2, g.has(h2)) {
332
+ const { groups: B2 } = new RegExp(`(?:\\${O}(?<code>\\d+)m|\\${w}(?<uri>.*)${b})`).exec(n.slice(E2).join("")) || { groups: {} };
333
+ if (B2.code !== void 0) {
334
+ const p = Number.parseFloat(B2.code);
335
+ s = p === CD ? void 0 : p;
336
+ } else B2.uri !== void 0 && (C2 = B2.uri.length === 0 ? void 0 : B2.uri);
337
+ }
338
+ const o2 = sD.codes.get(Number(s));
339
+ n[E2 + 1] === `
340
+ ` ? (C2 && (t += L("")), s && o2 && (t += N(o2))) : h2 === `
341
+ ` && (s && o2 && (t += N(s)), C2 && (t += L(C2)));
342
+ }
343
+ return t;
344
+ };
345
+ function R(e2, u, F) {
346
+ return String(e2).normalize().replace(/\r\n/g, `
347
+ `).split(`
348
+ `).map((t) => oD(t, u, F)).join(`
349
+ `);
350
+ }
351
+ var nD = Object.defineProperty;
352
+ var aD = (e2, u, F) => u in e2 ? nD(e2, u, { enumerable: true, configurable: true, writable: true, value: F }) : e2[u] = F;
353
+ var a = (e2, u, F) => (aD(e2, typeof u != "symbol" ? u + "" : u, F), F);
354
+ function hD(e2, u) {
355
+ if (e2 === u) return;
356
+ const F = e2.split(`
357
+ `), t = u.split(`
358
+ `), s = [];
359
+ for (let C2 = 0; C2 < Math.max(F.length, t.length); C2++) F[C2] !== t[C2] && s.push(C2);
360
+ return s;
361
+ }
362
+ var V = Symbol("clack:cancel");
363
+ function lD(e2) {
364
+ return e2 === V;
365
+ }
366
+ function v(e2, u) {
367
+ e2.isTTY && e2.setRawMode(u);
368
+ }
369
+ var z = /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"]]);
370
+ var xD = /* @__PURE__ */ new Set(["up", "down", "left", "right", "space", "enter"]);
371
+ var x = class {
372
+ constructor({ render: u, input: F = $, output: t = k, ...s }, C2 = true) {
373
+ a(this, "input"), a(this, "output"), a(this, "rl"), a(this, "opts"), a(this, "_track", false), a(this, "_render"), a(this, "_cursor", 0), a(this, "state", "initial"), a(this, "value"), a(this, "error", ""), a(this, "subscribers", /* @__PURE__ */ new Map()), a(this, "_prevFrame", ""), this.opts = s, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = u.bind(this), this._track = C2, this.input = F, this.output = t;
374
+ }
375
+ prompt() {
376
+ const u = new U(0);
377
+ return u._write = (F, t, s) => {
378
+ this._track && (this.value = this.rl.line.replace(/\t/g, ""), this._cursor = this.rl.cursor, this.emit("value", this.value)), s();
379
+ }, this.input.pipe(u), this.rl = _.createInterface({ input: this.input, output: u, tabSize: 2, prompt: "", escapeCodeTimeout: 50 }), _.emitKeypressEvents(this.input, this.rl), this.rl.prompt(), this.opts.initialValue !== void 0 && this._track && this.rl.write(this.opts.initialValue), this.input.on("keypress", this.onKeypress), v(this.input, true), this.output.on("resize", this.render), this.render(), new Promise((F, t) => {
380
+ this.once("submit", () => {
381
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v(this.input, false), F(this.value);
382
+ }), this.once("cancel", () => {
383
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v(this.input, false), F(V);
384
+ });
385
+ });
386
+ }
387
+ on(u, F) {
388
+ const t = this.subscribers.get(u) ?? [];
389
+ t.push({ cb: F }), this.subscribers.set(u, t);
390
+ }
391
+ once(u, F) {
392
+ const t = this.subscribers.get(u) ?? [];
393
+ t.push({ cb: F, once: true }), this.subscribers.set(u, t);
394
+ }
395
+ emit(u, ...F) {
396
+ const t = this.subscribers.get(u) ?? [], s = [];
397
+ for (const C2 of t) C2.cb(...F), C2.once && s.push(() => t.splice(t.indexOf(C2), 1));
398
+ for (const C2 of s) C2();
399
+ }
400
+ unsubscribe() {
401
+ this.subscribers.clear();
402
+ }
403
+ onKeypress(u, F) {
404
+ if (this.state === "error" && (this.state = "active"), F?.name && !this._track && z.has(F.name) && this.emit("cursor", z.get(F.name)), F?.name && xD.has(F.name) && this.emit("cursor", F.name), u && (u.toLowerCase() === "y" || u.toLowerCase() === "n") && this.emit("confirm", u.toLowerCase() === "y"), u === " " && this.opts.placeholder && (this.value || (this.rl.write(this.opts.placeholder), this.emit("value", this.opts.placeholder))), u && this.emit("key", u.toLowerCase()), F?.name === "return") {
405
+ if (this.opts.validate) {
406
+ const t = this.opts.validate(this.value);
407
+ t && (this.error = t, this.state = "error", this.rl.write(this.value));
408
+ }
409
+ this.state !== "error" && (this.state = "submit");
410
+ }
411
+ u === "" && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
412
+ }
413
+ close() {
414
+ this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
415
+ `), v(this.input, false), this.rl.close(), this.emit(`${this.state}`, this.value), this.unsubscribe();
416
+ }
417
+ restoreCursor() {
418
+ const u = R(this._prevFrame, process.stdout.columns, { hard: true }).split(`
419
+ `).length - 1;
420
+ this.output.write(import_sisteransi.cursor.move(-999, u * -1));
421
+ }
422
+ render() {
423
+ const u = R(this._render(this) ?? "", process.stdout.columns, { hard: true });
424
+ if (u !== this._prevFrame) {
425
+ if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
426
+ else {
427
+ const F = hD(this._prevFrame, u);
428
+ if (this.restoreCursor(), F && F?.length === 1) {
429
+ const t = F[0];
430
+ this.output.write(import_sisteransi.cursor.move(0, t)), this.output.write(import_sisteransi.erase.lines(1));
431
+ const s = u.split(`
432
+ `);
433
+ this.output.write(s[t]), this._prevFrame = u, this.output.write(import_sisteransi.cursor.move(0, s.length - t - 1));
434
+ return;
435
+ } else if (F && F?.length > 1) {
436
+ const t = F[0];
437
+ this.output.write(import_sisteransi.cursor.move(0, t)), this.output.write(import_sisteransi.erase.down());
438
+ const s = u.split(`
439
+ `).slice(t);
440
+ this.output.write(s.join(`
441
+ `)), this._prevFrame = u;
442
+ return;
443
+ }
444
+ this.output.write(import_sisteransi.erase.down());
445
+ }
446
+ this.output.write(u), this.state === "initial" && (this.state = "active"), this._prevFrame = u;
447
+ }
448
+ }
449
+ };
450
+ var wD = Object.defineProperty;
451
+ var yD = (e2, u, F) => u in e2 ? wD(e2, u, { enumerable: true, configurable: true, writable: true, value: F }) : e2[u] = F;
452
+ var Z = (e2, u, F) => (yD(e2, typeof u != "symbol" ? u + "" : u, F), F);
453
+ var $D = class extends x {
454
+ constructor(u) {
455
+ super(u, false), Z(this, "options"), Z(this, "cursor", 0), this.options = u.options, this.cursor = this.options.findIndex(({ value: F }) => F === u.initialValue), this.cursor === -1 && (this.cursor = 0), this.changeValue(), this.on("cursor", (F) => {
456
+ switch (F) {
457
+ case "left":
458
+ case "up":
459
+ this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
460
+ break;
461
+ case "down":
462
+ case "right":
463
+ this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
464
+ break;
465
+ }
466
+ this.changeValue();
467
+ });
468
+ }
469
+ get _value() {
470
+ return this.options[this.cursor];
471
+ }
472
+ changeValue() {
473
+ this.value = this._value.value;
474
+ }
475
+ };
476
+ var WD = globalThis.process.platform.startsWith("win");
477
+ function OD({ input: e2 = $, output: u = k, overwrite: F = true, hideCursor: t = true } = {}) {
478
+ const s = f.createInterface({ input: e2, output: u, prompt: "", tabSize: 1 });
479
+ f.emitKeypressEvents(e2, s), e2.isTTY && e2.setRawMode(true);
480
+ const C2 = (D, { name: i }) => {
481
+ if (String(D) === "") {
482
+ t && u.write(import_sisteransi.cursor.show), process.exit(0);
483
+ return;
484
+ }
485
+ if (!F) return;
486
+ let n = i === "return" ? 0 : -1, E2 = i === "return" ? -1 : 0;
487
+ f.moveCursor(u, n, E2, () => {
488
+ f.clearLine(u, 1, () => {
489
+ e2.once("keypress", C2);
490
+ });
491
+ });
492
+ };
493
+ return t && u.write(import_sisteransi.cursor.hide), e2.once("keypress", C2), () => {
494
+ e2.off("keypress", C2), t && u.write(import_sisteransi.cursor.show), e2.isTTY && !WD && e2.setRawMode(false), s.terminal = false, s.close();
495
+ };
496
+ }
497
+
498
+ // node_modules/@clack/prompts/dist/index.mjs
499
+ var import_picocolors = __toESM(require_picocolors(), 1);
500
+ var import_sisteransi2 = __toESM(require_src(), 1);
501
+ import h from "node:process";
502
+ function q2() {
503
+ return h.platform !== "win32" ? h.env.TERM !== "linux" : Boolean(h.env.CI) || Boolean(h.env.WT_SESSION) || Boolean(h.env.TERMINUS_SUBLIME) || h.env.ConEmuTask === "{cmd::Cmder}" || h.env.TERM_PROGRAM === "Terminus-Sublime" || h.env.TERM_PROGRAM === "vscode" || h.env.TERM === "xterm-256color" || h.env.TERM === "alacritty" || h.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
504
+ }
505
+ var _2 = q2();
506
+ var o = (r2, n) => _2 ? r2 : n;
507
+ var H = o("\u25C6", "*");
508
+ var I2 = o("\u25A0", "x");
509
+ var x2 = o("\u25B2", "x");
510
+ var S2 = o("\u25C7", "o");
511
+ var K = o("\u250C", "T");
512
+ var a2 = o("\u2502", "|");
513
+ var d2 = o("\u2514", "\u2014");
514
+ var b2 = o("\u25CF", ">");
515
+ var E = o("\u25CB", " ");
516
+ var C = o("\u25FB", "[\u2022]");
517
+ var w2 = o("\u25FC", "[+]");
518
+ var M2 = o("\u25FB", "[ ]");
519
+ var U2 = o("\u25AA", "\u2022");
520
+ var B = o("\u2500", "-");
521
+ var Z2 = o("\u256E", "+");
522
+ var z2 = o("\u251C", "+");
523
+ var X2 = o("\u256F", "+");
524
+ var J2 = o("\u25CF", "\u2022");
525
+ var Y = o("\u25C6", "*");
526
+ var Q2 = o("\u25B2", "!");
527
+ var ee = o("\u25A0", "x");
528
+ var y2 = (r2) => {
529
+ switch (r2) {
530
+ case "initial":
531
+ case "active":
532
+ return import_picocolors.default.cyan(H);
533
+ case "cancel":
534
+ return import_picocolors.default.red(I2);
535
+ case "error":
536
+ return import_picocolors.default.yellow(x2);
537
+ case "submit":
538
+ return import_picocolors.default.green(S2);
539
+ }
540
+ };
541
+ var ie = (r2) => {
542
+ const n = (t, s) => {
543
+ const c = t.label ?? String(t.value);
544
+ return s === "active" ? `${import_picocolors.default.green(b2)} ${c} ${t.hint ? import_picocolors.default.dim(`(${t.hint})`) : ""}` : s === "selected" ? `${import_picocolors.default.dim(c)}` : s === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(c))}` : `${import_picocolors.default.dim(E)} ${import_picocolors.default.dim(c)}`;
545
+ };
546
+ let i = 0;
547
+ return new $D({ options: r2.options, initialValue: r2.initialValue, render() {
548
+ const t = `${import_picocolors.default.gray(a2)}
549
+ ${y2(this.state)} ${r2.message}
550
+ `;
551
+ switch (this.state) {
552
+ case "submit":
553
+ return `${t}${import_picocolors.default.gray(a2)} ${n(this.options[this.cursor], "selected")}`;
554
+ case "cancel":
555
+ return `${t}${import_picocolors.default.gray(a2)} ${n(this.options[this.cursor], "cancelled")}
556
+ ${import_picocolors.default.gray(a2)}`;
557
+ default: {
558
+ const s = r2.maxItems === void 0 ? 1 / 0 : Math.max(r2.maxItems, 5);
559
+ this.cursor >= i + s - 3 ? i = Math.max(Math.min(this.cursor - s + 3, this.options.length - s), 0) : this.cursor < i + 2 && (i = Math.max(this.cursor - 2, 0));
560
+ const c = s < this.options.length && i > 0, l2 = s < this.options.length && i + s < this.options.length;
561
+ return `${t}${import_picocolors.default.cyan(a2)} ${this.options.slice(i, i + s).map((u, m2, $2) => m2 === 0 && c ? import_picocolors.default.dim("...") : m2 === $2.length - 1 && l2 ? import_picocolors.default.dim("...") : n(u, m2 + i === this.cursor ? "active" : "inactive")).join(`
562
+ ${import_picocolors.default.cyan(a2)} `)}
563
+ ${import_picocolors.default.cyan(d2)}
564
+ `;
565
+ }
566
+ }
567
+ } }).prompt();
568
+ };
569
+ var R2 = (r2) => r2.replace(me(), "");
570
+ var le = (r2 = "", n = "") => {
571
+ const i = `
572
+ ${r2}
573
+ `.split(`
574
+ `), t = R2(n).length, s = Math.max(i.reduce((l2, u) => (u = R2(u), u.length > l2 ? u.length : l2), 0), t) + 2, c = i.map((l2) => `${import_picocolors.default.gray(a2)} ${import_picocolors.default.dim(l2)}${" ".repeat(s - R2(l2).length)}${import_picocolors.default.gray(a2)}`).join(`
575
+ `);
576
+ process.stdout.write(`${import_picocolors.default.gray(a2)}
577
+ ${import_picocolors.default.green(S2)} ${import_picocolors.default.reset(n)} ${import_picocolors.default.gray(B.repeat(Math.max(s - t - 1, 1)) + Z2)}
578
+ ${c}
579
+ ${import_picocolors.default.gray(z2 + B.repeat(s + 2) + X2)}
580
+ `);
581
+ };
582
+ var ue = (r2 = "") => {
583
+ process.stdout.write(`${import_picocolors.default.gray(d2)} ${import_picocolors.default.red(r2)}
584
+
585
+ `);
586
+ };
587
+ var oe = (r2 = "") => {
588
+ process.stdout.write(`${import_picocolors.default.gray(K)} ${r2}
589
+ `);
590
+ };
591
+ var $e = (r2 = "") => {
592
+ process.stdout.write(`${import_picocolors.default.gray(a2)}
593
+ ${import_picocolors.default.gray(d2)} ${r2}
594
+
595
+ `);
596
+ };
597
+ var f2 = { message: (r2 = "", { symbol: n = import_picocolors.default.gray(a2) } = {}) => {
598
+ const i = [`${import_picocolors.default.gray(a2)}`];
599
+ if (r2) {
600
+ const [t, ...s] = r2.split(`
601
+ `);
602
+ i.push(`${n} ${t}`, ...s.map((c) => `${import_picocolors.default.gray(a2)} ${c}`));
603
+ }
604
+ process.stdout.write(`${i.join(`
605
+ `)}
606
+ `);
607
+ }, info: (r2) => {
608
+ f2.message(r2, { symbol: import_picocolors.default.blue(J2) });
609
+ }, success: (r2) => {
610
+ f2.message(r2, { symbol: import_picocolors.default.green(Y) });
611
+ }, step: (r2) => {
612
+ f2.message(r2, { symbol: import_picocolors.default.green(S2) });
613
+ }, warn: (r2) => {
614
+ f2.message(r2, { symbol: import_picocolors.default.yellow(Q2) });
615
+ }, warning: (r2) => {
616
+ f2.warn(r2);
617
+ }, error: (r2) => {
618
+ f2.message(r2, { symbol: import_picocolors.default.red(ee) });
619
+ } };
620
+ var de = () => {
621
+ const r2 = _2 ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"], n = _2 ? 80 : 120;
622
+ let i, t, s = false, c = "";
623
+ const l2 = (v2 = "") => {
624
+ s = true, i = OD(), c = v2.replace(/\.+$/, ""), process.stdout.write(`${import_picocolors.default.gray(a2)}
625
+ `);
626
+ let g2 = 0, p = 0;
627
+ t = setInterval(() => {
628
+ const O2 = import_picocolors.default.magenta(r2[g2]), P2 = ".".repeat(Math.floor(p)).slice(0, 3);
629
+ process.stdout.write(import_sisteransi2.cursor.move(-999, 0)), process.stdout.write(import_sisteransi2.erase.down(1)), process.stdout.write(`${O2} ${c}${P2}`), g2 = g2 + 1 < r2.length ? g2 + 1 : 0, p = p < r2.length ? p + 0.125 : 0;
630
+ }, n);
631
+ }, u = (v2 = "", g2 = 0) => {
632
+ c = v2 ?? c, s = false, clearInterval(t);
633
+ const p = g2 === 0 ? import_picocolors.default.green(S2) : g2 === 1 ? import_picocolors.default.red(I2) : import_picocolors.default.red(x2);
634
+ process.stdout.write(import_sisteransi2.cursor.move(-999, 0)), process.stdout.write(import_sisteransi2.erase.down(1)), process.stdout.write(`${p} ${c}
635
+ `), i();
636
+ }, m2 = (v2 = "") => {
637
+ c = v2 ?? c;
638
+ }, $2 = (v2) => {
639
+ const g2 = v2 > 1 ? "Something went wrong" : "Canceled";
640
+ s && u(g2, v2);
641
+ };
642
+ return process.on("uncaughtExceptionMonitor", () => $2(2)), process.on("unhandledRejection", () => $2(2)), process.on("SIGINT", () => $2(1)), process.on("SIGTERM", () => $2(1)), process.on("exit", $2), { start: l2, stop: u, message: m2 };
643
+ };
644
+ function me() {
645
+ const r2 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
646
+ return new RegExp(r2, "g");
647
+ }
648
+
649
+ // src/index.js
650
+ var import_picocolors2 = __toESM(require_picocolors(), 1);
651
+
652
+ // src/shared.js
653
+ var MARKER = "// sveltekit-temporal: managed block";
654
+ var END_MARKER = "// end sveltekit-temporal managed block";
655
+ function buildBootstrap(pkgName, isTypeScript) {
656
+ const tsLine1 = isTypeScript ? ` // @ts-expect-error - polyfilling globalThis
657
+ ` : "";
658
+ const tsLine2 = isTypeScript ? ` // @ts-expect-error - patching Date.prototype
659
+ ` : "";
660
+ return `${MARKER}
661
+ // Conditionally load the Temporal polyfill when the runtime lacks native support.
662
+ // Native (Chrome 144+, Firefox 139+) keeps zero overhead \u2014 the dynamic import is
663
+ // code-split by Vite and only fetched on browsers that need it.
664
+
665
+ if (typeof globalThis.Temporal === 'undefined') {
666
+ const { Temporal, toTemporalInstant } = await import('${pkgName}');
667
+ ${tsLine1} globalThis.Temporal = Temporal;
668
+ ${tsLine2} Date.prototype.toTemporalInstant = toTemporalInstant;
669
+ }
670
+
671
+ export {};
672
+ `;
673
+ }
674
+ function buildAppDtsBlock(pkgName) {
675
+ return `${MARKER}
676
+ import type { Temporal as TemporalNS } from '${pkgName}';
677
+
678
+ declare global {
679
+ const Temporal: typeof TemporalNS;
680
+
681
+ interface Date {
682
+ toTemporalInstant(): TemporalNS.Instant;
683
+ }
684
+ }
685
+ ${END_MARKER}`;
686
+ }
687
+ function buildNewAppDts(pkgName) {
688
+ return `// See https://svelte.dev/docs/kit/types#app.d.ts for information about these interfaces
689
+ declare global {
690
+ namespace App {
691
+ // interface Error {}
692
+ // interface Locals {}
693
+ // interface PageData {}
694
+ // interface PageState {}
695
+ // interface Platform {}
696
+ }
697
+ }
698
+
699
+ ${buildAppDtsBlock(pkgName)}
700
+
701
+ export {};
702
+ `;
703
+ }
704
+ function processAppDts(content, pkgName) {
705
+ const block = buildAppDtsBlock(pkgName);
706
+ if (content.includes(MARKER)) {
707
+ const pattern = new RegExp(
708
+ `${escapeRegex(MARKER)}[\\s\\S]*?${escapeRegex(END_MARKER)}\\n?`,
709
+ "m"
710
+ );
711
+ const replaced = content.replace(pattern, `${block}
712
+ `);
713
+ return replaced === content ? false : replaced;
714
+ }
715
+ const exportMatch = content.match(/\n\s*export\s*\{\s*\};?\s*$/);
716
+ if (exportMatch) {
717
+ return content.replace(exportMatch[0], `
718
+
719
+ ${block}
720
+ ${exportMatch[0]}`);
721
+ }
722
+ return `${content.trimEnd()}
723
+
724
+ ${block}
725
+
726
+ export {};
727
+ `;
728
+ }
729
+ function escapeRegex(s) {
730
+ return s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
731
+ }
732
+
733
+ // src/index.js
734
+ var POLYFILLS = {
735
+ official: {
736
+ pkg: "@js-temporal/polyfill",
737
+ label: "@js-temporal/polyfill",
738
+ hint: "Official TC39 polyfill, ~100KB gzipped, most spec-conservative"
739
+ },
740
+ small: {
741
+ pkg: "temporal-polyfill",
742
+ label: "temporal-polyfill",
743
+ hint: "Smaller alternative (~40KB gzipped) by Adam Shaw, same API surface"
744
+ }
745
+ };
746
+ async function run() {
747
+ console.log();
748
+ oe(import_picocolors2.default.bgCyan(import_picocolors2.default.black(" sveltekit-temporal ")));
749
+ const cwd = process.cwd();
750
+ const projectInfo = detectProject(cwd);
751
+ if (!projectInfo.ok) {
752
+ ue(projectInfo.reason);
753
+ process.exit(1);
754
+ }
755
+ const { isTypeScript, pkgJson, pkgManager } = projectInfo;
756
+ f2.info(
757
+ `Detected ${import_picocolors2.default.cyan("SvelteKit")} project ${isTypeScript ? import_picocolors2.default.dim("(TypeScript)") : import_picocolors2.default.dim("(JavaScript)")} using ${import_picocolors2.default.cyan(pkgManager)}`
758
+ );
759
+ const choice = await ie({
760
+ message: "Which Temporal polyfill would you like to use?",
761
+ options: [
762
+ {
763
+ value: "official",
764
+ label: POLYFILLS.official.label,
765
+ hint: POLYFILLS.official.hint
766
+ },
767
+ {
768
+ value: "small",
769
+ label: POLYFILLS.small.label,
770
+ hint: POLYFILLS.small.hint
771
+ }
772
+ ]
773
+ });
774
+ if (lD(choice)) {
775
+ ue("Cancelled.");
776
+ process.exit(0);
777
+ }
778
+ const polyfill = POLYFILLS[choice];
779
+ const alreadyInstalled = pkgJson.dependencies?.[polyfill.pkg] || pkgJson.devDependencies?.[polyfill.pkg];
780
+ if (!alreadyInstalled) {
781
+ const spin = de();
782
+ spin.start(`Installing ${polyfill.pkg}`);
783
+ try {
784
+ execSync(installCommand(pkgManager, polyfill.pkg), {
785
+ cwd,
786
+ stdio: "pipe"
787
+ });
788
+ spin.stop(`Installed ${import_picocolors2.default.green(polyfill.pkg)}`);
789
+ } catch (err) {
790
+ spin.stop(import_picocolors2.default.red(`Failed to install ${polyfill.pkg}`));
791
+ f2.error(err.message);
792
+ process.exit(1);
793
+ }
794
+ } else {
795
+ f2.info(`${polyfill.pkg} already in package.json \u2014 skipping install`);
796
+ }
797
+ const ext = isTypeScript ? "ts" : "js";
798
+ const created = [];
799
+ const updated = [];
800
+ const skipped = [];
801
+ const libDir = join(cwd, "src", "lib");
802
+ mkdirSync(libDir, { recursive: true });
803
+ const bootstrapPath = join(libDir, `temporal.${ext}`);
804
+ const bootstrapContents = buildBootstrap(polyfill.pkg, isTypeScript);
805
+ writeManaged(bootstrapPath, bootstrapContents, { created, updated, skipped });
806
+ const layoutPath = join(cwd, "src", "routes", `+layout.${ext}`);
807
+ ensureImportInFile(layoutPath, "import '$lib/temporal';", { created, updated, skipped });
808
+ const hooksPath = join(cwd, "src", `hooks.server.${ext}`);
809
+ ensureImportInFile(hooksPath, "import '$lib/temporal';", { created, updated, skipped });
810
+ if (isTypeScript) {
811
+ const dtsPath = join(cwd, "src", "app.d.ts");
812
+ updateAppDts(dtsPath, polyfill.pkg, { created, updated, skipped });
813
+ }
814
+ const summary = [];
815
+ if (created.length) summary.push(import_picocolors2.default.green("Created:") + "\n " + created.join("\n "));
816
+ if (updated.length) summary.push(import_picocolors2.default.yellow("Updated:") + "\n " + updated.join("\n "));
817
+ if (skipped.length)
818
+ summary.push(import_picocolors2.default.dim("Already configured:") + "\n " + skipped.join("\n "));
819
+ le(summary.join("\n\n") || "No changes needed.", "Summary");
820
+ $e(
821
+ `${import_picocolors2.default.green("\u2713")} Temporal is wired up. Reference ${import_picocolors2.default.cyan("Temporal")} anywhere in your app.`
822
+ );
823
+ }
824
+ function detectProject(cwd) {
825
+ const pkgPath = join(cwd, "package.json");
826
+ if (!existsSync(pkgPath)) {
827
+ return { ok: false, reason: "No package.json found in current directory." };
828
+ }
829
+ let pkgJson;
830
+ try {
831
+ pkgJson = JSON.parse(readFileSync(pkgPath, "utf8"));
832
+ } catch {
833
+ return { ok: false, reason: "Could not parse package.json." };
834
+ }
835
+ const allDeps = { ...pkgJson.dependencies, ...pkgJson.devDependencies };
836
+ const hasSvelte = !!allDeps.svelte;
837
+ const hasKit = !!allDeps["@sveltejs/kit"];
838
+ if (!hasSvelte) {
839
+ return {
840
+ ok: false,
841
+ reason: "This does not look like a Svelte project (svelte not in dependencies)."
842
+ };
843
+ }
844
+ if (!hasKit) {
845
+ return {
846
+ ok: false,
847
+ reason: "This script targets SvelteKit projects (@sveltejs/kit not found). For a plain Svelte app, the layout/hooks setup does not apply."
848
+ };
849
+ }
850
+ const isTypeScript = existsSync(join(cwd, "tsconfig.json")) || existsSync(join(cwd, "src", "app.d.ts"));
851
+ const pkgManager = detectPackageManager(cwd);
852
+ return { ok: true, isTypeScript, pkgJson, pkgManager };
853
+ }
854
+ function detectPackageManager(cwd) {
855
+ if (existsSync(join(cwd, "bun.lockb")) || existsSync(join(cwd, "bun.lock"))) return "bun";
856
+ if (existsSync(join(cwd, "pnpm-lock.yaml"))) return "pnpm";
857
+ if (existsSync(join(cwd, "yarn.lock"))) return "yarn";
858
+ return "npm";
859
+ }
860
+ function installCommand(pm, pkg) {
861
+ switch (pm) {
862
+ case "pnpm":
863
+ return `pnpm add ${pkg}`;
864
+ case "yarn":
865
+ return `yarn add ${pkg}`;
866
+ case "bun":
867
+ return `bun add ${pkg}`;
868
+ default:
869
+ return `npm install ${pkg}`;
870
+ }
871
+ }
872
+ function writeManaged(path, contents, log) {
873
+ if (existsSync(path)) {
874
+ const existing = readFileSync(path, "utf8");
875
+ if (existing.includes(MARKER)) {
876
+ if (existing.trim() === contents.trim()) {
877
+ log.skipped.push(rel(path));
878
+ return;
879
+ }
880
+ writeFileSync(path, contents);
881
+ log.updated.push(rel(path));
882
+ return;
883
+ }
884
+ log.skipped.push(`${rel(path)} ${import_picocolors2.default.dim("(exists, not managed \u2014 left alone)")}`);
885
+ return;
886
+ }
887
+ mkdirSync(dirname(path), { recursive: true });
888
+ writeFileSync(path, contents);
889
+ log.created.push(rel(path));
890
+ }
891
+ function ensureImportInFile(path, importLine, log) {
892
+ if (!existsSync(path)) {
893
+ mkdirSync(dirname(path), { recursive: true });
894
+ writeFileSync(path, `${importLine}
895
+ `);
896
+ log.created.push(rel(path));
897
+ return;
898
+ }
899
+ const existing = readFileSync(path, "utf8");
900
+ if (existing.includes(importLine)) {
901
+ log.skipped.push(rel(path));
902
+ return;
903
+ }
904
+ writeFileSync(path, `${importLine}
905
+ ${existing}`);
906
+ log.updated.push(rel(path));
907
+ }
908
+ function updateAppDts(path, pkgName, log) {
909
+ if (!existsSync(path)) {
910
+ mkdirSync(dirname(path), { recursive: true });
911
+ writeFileSync(path, buildNewAppDts(pkgName));
912
+ log.created.push(rel(path));
913
+ return;
914
+ }
915
+ const existing = readFileSync(path, "utf8");
916
+ const result = processAppDts(existing, pkgName);
917
+ if (result === false) {
918
+ log.skipped.push(rel(path));
919
+ return;
920
+ }
921
+ writeFileSync(path, result);
922
+ log.updated.push(rel(path));
923
+ }
924
+ function rel(absPath) {
925
+ return absPath.replace(process.cwd() + "/", "");
926
+ }
927
+ export {
928
+ run
929
+ };