@vue/devtools-kit 7.0.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.mjs ADDED
@@ -0,0 +1,4197 @@
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 __esm = (fn, res) => function __init() {
8
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
9
+ };
10
+ var __commonJS = (cb, mod) => function __require() {
11
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
12
+ };
13
+ var __copyProps = (to, from, except, desc) => {
14
+ if (from && typeof from === "object" || typeof from === "function") {
15
+ for (let key of __getOwnPropNames(from))
16
+ if (!__hasOwnProp.call(to, key) && key !== except)
17
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
+ }
19
+ return to;
20
+ };
21
+ var __toESM = (mod, isNodeMode, target8) => (target8 = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
+ // If the importer is in node compatibility mode or this is not an ESM
23
+ // file that has been converted to a CommonJS file using a Babel-
24
+ // compatible transform (i.e. "__esModule" has not been set), then set
25
+ // "default" to the CommonJS "module.exports" for node compatibility.
26
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target8, "default", { value: mod, enumerable: true }) : target8,
27
+ mod
28
+ ));
29
+
30
+ // ../../node_modules/.pnpm/tsup@8.0.1_postcss@8.4.32_typescript@5.3.3/node_modules/tsup/assets/esm_shims.js
31
+ var init_esm_shims = __esm({
32
+ "../../node_modules/.pnpm/tsup@8.0.1_postcss@8.4.32_typescript@5.3.3/node_modules/tsup/assets/esm_shims.js"() {
33
+ "use strict";
34
+ }
35
+ });
36
+
37
+ // ../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/lib/speakingurl.js
38
+ var require_speakingurl = __commonJS({
39
+ "../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/lib/speakingurl.js"(exports, module) {
40
+ "use strict";
41
+ init_esm_shims();
42
+ (function(root) {
43
+ "use strict";
44
+ var charMap = {
45
+ // latin
46
+ "\xC0": "A",
47
+ "\xC1": "A",
48
+ "\xC2": "A",
49
+ "\xC3": "A",
50
+ "\xC4": "Ae",
51
+ "\xC5": "A",
52
+ "\xC6": "AE",
53
+ "\xC7": "C",
54
+ "\xC8": "E",
55
+ "\xC9": "E",
56
+ "\xCA": "E",
57
+ "\xCB": "E",
58
+ "\xCC": "I",
59
+ "\xCD": "I",
60
+ "\xCE": "I",
61
+ "\xCF": "I",
62
+ "\xD0": "D",
63
+ "\xD1": "N",
64
+ "\xD2": "O",
65
+ "\xD3": "O",
66
+ "\xD4": "O",
67
+ "\xD5": "O",
68
+ "\xD6": "Oe",
69
+ "\u0150": "O",
70
+ "\xD8": "O",
71
+ "\xD9": "U",
72
+ "\xDA": "U",
73
+ "\xDB": "U",
74
+ "\xDC": "Ue",
75
+ "\u0170": "U",
76
+ "\xDD": "Y",
77
+ "\xDE": "TH",
78
+ "\xDF": "ss",
79
+ "\xE0": "a",
80
+ "\xE1": "a",
81
+ "\xE2": "a",
82
+ "\xE3": "a",
83
+ "\xE4": "ae",
84
+ "\xE5": "a",
85
+ "\xE6": "ae",
86
+ "\xE7": "c",
87
+ "\xE8": "e",
88
+ "\xE9": "e",
89
+ "\xEA": "e",
90
+ "\xEB": "e",
91
+ "\xEC": "i",
92
+ "\xED": "i",
93
+ "\xEE": "i",
94
+ "\xEF": "i",
95
+ "\xF0": "d",
96
+ "\xF1": "n",
97
+ "\xF2": "o",
98
+ "\xF3": "o",
99
+ "\xF4": "o",
100
+ "\xF5": "o",
101
+ "\xF6": "oe",
102
+ "\u0151": "o",
103
+ "\xF8": "o",
104
+ "\xF9": "u",
105
+ "\xFA": "u",
106
+ "\xFB": "u",
107
+ "\xFC": "ue",
108
+ "\u0171": "u",
109
+ "\xFD": "y",
110
+ "\xFE": "th",
111
+ "\xFF": "y",
112
+ "\u1E9E": "SS",
113
+ // language specific
114
+ // Arabic
115
+ "\u0627": "a",
116
+ "\u0623": "a",
117
+ "\u0625": "i",
118
+ "\u0622": "aa",
119
+ "\u0624": "u",
120
+ "\u0626": "e",
121
+ "\u0621": "a",
122
+ "\u0628": "b",
123
+ "\u062A": "t",
124
+ "\u062B": "th",
125
+ "\u062C": "j",
126
+ "\u062D": "h",
127
+ "\u062E": "kh",
128
+ "\u062F": "d",
129
+ "\u0630": "th",
130
+ "\u0631": "r",
131
+ "\u0632": "z",
132
+ "\u0633": "s",
133
+ "\u0634": "sh",
134
+ "\u0635": "s",
135
+ "\u0636": "dh",
136
+ "\u0637": "t",
137
+ "\u0638": "z",
138
+ "\u0639": "a",
139
+ "\u063A": "gh",
140
+ "\u0641": "f",
141
+ "\u0642": "q",
142
+ "\u0643": "k",
143
+ "\u0644": "l",
144
+ "\u0645": "m",
145
+ "\u0646": "n",
146
+ "\u0647": "h",
147
+ "\u0648": "w",
148
+ "\u064A": "y",
149
+ "\u0649": "a",
150
+ "\u0629": "h",
151
+ "\uFEFB": "la",
152
+ "\uFEF7": "laa",
153
+ "\uFEF9": "lai",
154
+ "\uFEF5": "laa",
155
+ // Persian additional characters than Arabic
156
+ "\u06AF": "g",
157
+ "\u0686": "ch",
158
+ "\u067E": "p",
159
+ "\u0698": "zh",
160
+ "\u06A9": "k",
161
+ "\u06CC": "y",
162
+ // Arabic diactrics
163
+ "\u064E": "a",
164
+ "\u064B": "an",
165
+ "\u0650": "e",
166
+ "\u064D": "en",
167
+ "\u064F": "u",
168
+ "\u064C": "on",
169
+ "\u0652": "",
170
+ // Arabic numbers
171
+ "\u0660": "0",
172
+ "\u0661": "1",
173
+ "\u0662": "2",
174
+ "\u0663": "3",
175
+ "\u0664": "4",
176
+ "\u0665": "5",
177
+ "\u0666": "6",
178
+ "\u0667": "7",
179
+ "\u0668": "8",
180
+ "\u0669": "9",
181
+ // Persian numbers
182
+ "\u06F0": "0",
183
+ "\u06F1": "1",
184
+ "\u06F2": "2",
185
+ "\u06F3": "3",
186
+ "\u06F4": "4",
187
+ "\u06F5": "5",
188
+ "\u06F6": "6",
189
+ "\u06F7": "7",
190
+ "\u06F8": "8",
191
+ "\u06F9": "9",
192
+ // Burmese consonants
193
+ "\u1000": "k",
194
+ "\u1001": "kh",
195
+ "\u1002": "g",
196
+ "\u1003": "ga",
197
+ "\u1004": "ng",
198
+ "\u1005": "s",
199
+ "\u1006": "sa",
200
+ "\u1007": "z",
201
+ "\u1005\u103B": "za",
202
+ "\u100A": "ny",
203
+ "\u100B": "t",
204
+ "\u100C": "ta",
205
+ "\u100D": "d",
206
+ "\u100E": "da",
207
+ "\u100F": "na",
208
+ "\u1010": "t",
209
+ "\u1011": "ta",
210
+ "\u1012": "d",
211
+ "\u1013": "da",
212
+ "\u1014": "n",
213
+ "\u1015": "p",
214
+ "\u1016": "pa",
215
+ "\u1017": "b",
216
+ "\u1018": "ba",
217
+ "\u1019": "m",
218
+ "\u101A": "y",
219
+ "\u101B": "ya",
220
+ "\u101C": "l",
221
+ "\u101D": "w",
222
+ "\u101E": "th",
223
+ "\u101F": "h",
224
+ "\u1020": "la",
225
+ "\u1021": "a",
226
+ // consonant character combos
227
+ "\u103C": "y",
228
+ "\u103B": "ya",
229
+ "\u103D": "w",
230
+ "\u103C\u103D": "yw",
231
+ "\u103B\u103D": "ywa",
232
+ "\u103E": "h",
233
+ // independent vowels
234
+ "\u1027": "e",
235
+ "\u104F": "-e",
236
+ "\u1023": "i",
237
+ "\u1024": "-i",
238
+ "\u1009": "u",
239
+ "\u1026": "-u",
240
+ "\u1029": "aw",
241
+ "\u101E\u103C\u1031\u102C": "aw",
242
+ "\u102A": "aw",
243
+ // numbers
244
+ "\u1040": "0",
245
+ "\u1041": "1",
246
+ "\u1042": "2",
247
+ "\u1043": "3",
248
+ "\u1044": "4",
249
+ "\u1045": "5",
250
+ "\u1046": "6",
251
+ "\u1047": "7",
252
+ "\u1048": "8",
253
+ "\u1049": "9",
254
+ // virama and tone marks which are silent in transliteration
255
+ "\u1039": "",
256
+ "\u1037": "",
257
+ "\u1038": "",
258
+ // Czech
259
+ "\u010D": "c",
260
+ "\u010F": "d",
261
+ "\u011B": "e",
262
+ "\u0148": "n",
263
+ "\u0159": "r",
264
+ "\u0161": "s",
265
+ "\u0165": "t",
266
+ "\u016F": "u",
267
+ "\u017E": "z",
268
+ "\u010C": "C",
269
+ "\u010E": "D",
270
+ "\u011A": "E",
271
+ "\u0147": "N",
272
+ "\u0158": "R",
273
+ "\u0160": "S",
274
+ "\u0164": "T",
275
+ "\u016E": "U",
276
+ "\u017D": "Z",
277
+ // Dhivehi
278
+ "\u0780": "h",
279
+ "\u0781": "sh",
280
+ "\u0782": "n",
281
+ "\u0783": "r",
282
+ "\u0784": "b",
283
+ "\u0785": "lh",
284
+ "\u0786": "k",
285
+ "\u0787": "a",
286
+ "\u0788": "v",
287
+ "\u0789": "m",
288
+ "\u078A": "f",
289
+ "\u078B": "dh",
290
+ "\u078C": "th",
291
+ "\u078D": "l",
292
+ "\u078E": "g",
293
+ "\u078F": "gn",
294
+ "\u0790": "s",
295
+ "\u0791": "d",
296
+ "\u0792": "z",
297
+ "\u0793": "t",
298
+ "\u0794": "y",
299
+ "\u0795": "p",
300
+ "\u0796": "j",
301
+ "\u0797": "ch",
302
+ "\u0798": "tt",
303
+ "\u0799": "hh",
304
+ "\u079A": "kh",
305
+ "\u079B": "th",
306
+ "\u079C": "z",
307
+ "\u079D": "sh",
308
+ "\u079E": "s",
309
+ "\u079F": "d",
310
+ "\u07A0": "t",
311
+ "\u07A1": "z",
312
+ "\u07A2": "a",
313
+ "\u07A3": "gh",
314
+ "\u07A4": "q",
315
+ "\u07A5": "w",
316
+ "\u07A6": "a",
317
+ "\u07A7": "aa",
318
+ "\u07A8": "i",
319
+ "\u07A9": "ee",
320
+ "\u07AA": "u",
321
+ "\u07AB": "oo",
322
+ "\u07AC": "e",
323
+ "\u07AD": "ey",
324
+ "\u07AE": "o",
325
+ "\u07AF": "oa",
326
+ "\u07B0": "",
327
+ // Georgian https://en.wikipedia.org/wiki/Romanization_of_Georgian
328
+ // National system (2002)
329
+ "\u10D0": "a",
330
+ "\u10D1": "b",
331
+ "\u10D2": "g",
332
+ "\u10D3": "d",
333
+ "\u10D4": "e",
334
+ "\u10D5": "v",
335
+ "\u10D6": "z",
336
+ "\u10D7": "t",
337
+ "\u10D8": "i",
338
+ "\u10D9": "k",
339
+ "\u10DA": "l",
340
+ "\u10DB": "m",
341
+ "\u10DC": "n",
342
+ "\u10DD": "o",
343
+ "\u10DE": "p",
344
+ "\u10DF": "zh",
345
+ "\u10E0": "r",
346
+ "\u10E1": "s",
347
+ "\u10E2": "t",
348
+ "\u10E3": "u",
349
+ "\u10E4": "p",
350
+ "\u10E5": "k",
351
+ "\u10E6": "gh",
352
+ "\u10E7": "q",
353
+ "\u10E8": "sh",
354
+ "\u10E9": "ch",
355
+ "\u10EA": "ts",
356
+ "\u10EB": "dz",
357
+ "\u10EC": "ts",
358
+ "\u10ED": "ch",
359
+ "\u10EE": "kh",
360
+ "\u10EF": "j",
361
+ "\u10F0": "h",
362
+ // Greek
363
+ "\u03B1": "a",
364
+ "\u03B2": "v",
365
+ "\u03B3": "g",
366
+ "\u03B4": "d",
367
+ "\u03B5": "e",
368
+ "\u03B6": "z",
369
+ "\u03B7": "i",
370
+ "\u03B8": "th",
371
+ "\u03B9": "i",
372
+ "\u03BA": "k",
373
+ "\u03BB": "l",
374
+ "\u03BC": "m",
375
+ "\u03BD": "n",
376
+ "\u03BE": "ks",
377
+ "\u03BF": "o",
378
+ "\u03C0": "p",
379
+ "\u03C1": "r",
380
+ "\u03C3": "s",
381
+ "\u03C4": "t",
382
+ "\u03C5": "y",
383
+ "\u03C6": "f",
384
+ "\u03C7": "x",
385
+ "\u03C8": "ps",
386
+ "\u03C9": "o",
387
+ "\u03AC": "a",
388
+ "\u03AD": "e",
389
+ "\u03AF": "i",
390
+ "\u03CC": "o",
391
+ "\u03CD": "y",
392
+ "\u03AE": "i",
393
+ "\u03CE": "o",
394
+ "\u03C2": "s",
395
+ "\u03CA": "i",
396
+ "\u03B0": "y",
397
+ "\u03CB": "y",
398
+ "\u0390": "i",
399
+ "\u0391": "A",
400
+ "\u0392": "B",
401
+ "\u0393": "G",
402
+ "\u0394": "D",
403
+ "\u0395": "E",
404
+ "\u0396": "Z",
405
+ "\u0397": "I",
406
+ "\u0398": "TH",
407
+ "\u0399": "I",
408
+ "\u039A": "K",
409
+ "\u039B": "L",
410
+ "\u039C": "M",
411
+ "\u039D": "N",
412
+ "\u039E": "KS",
413
+ "\u039F": "O",
414
+ "\u03A0": "P",
415
+ "\u03A1": "R",
416
+ "\u03A3": "S",
417
+ "\u03A4": "T",
418
+ "\u03A5": "Y",
419
+ "\u03A6": "F",
420
+ "\u03A7": "X",
421
+ "\u03A8": "PS",
422
+ "\u03A9": "O",
423
+ "\u0386": "A",
424
+ "\u0388": "E",
425
+ "\u038A": "I",
426
+ "\u038C": "O",
427
+ "\u038E": "Y",
428
+ "\u0389": "I",
429
+ "\u038F": "O",
430
+ "\u03AA": "I",
431
+ "\u03AB": "Y",
432
+ // Latvian
433
+ "\u0101": "a",
434
+ // 'č': 'c', // duplicate
435
+ "\u0113": "e",
436
+ "\u0123": "g",
437
+ "\u012B": "i",
438
+ "\u0137": "k",
439
+ "\u013C": "l",
440
+ "\u0146": "n",
441
+ // 'š': 's', // duplicate
442
+ "\u016B": "u",
443
+ // 'ž': 'z', // duplicate
444
+ "\u0100": "A",
445
+ // 'Č': 'C', // duplicate
446
+ "\u0112": "E",
447
+ "\u0122": "G",
448
+ "\u012A": "I",
449
+ "\u0136": "k",
450
+ "\u013B": "L",
451
+ "\u0145": "N",
452
+ // 'Š': 'S', // duplicate
453
+ "\u016A": "U",
454
+ // 'Ž': 'Z', // duplicate
455
+ // Macedonian
456
+ "\u040C": "Kj",
457
+ "\u045C": "kj",
458
+ "\u0409": "Lj",
459
+ "\u0459": "lj",
460
+ "\u040A": "Nj",
461
+ "\u045A": "nj",
462
+ "\u0422\u0441": "Ts",
463
+ "\u0442\u0441": "ts",
464
+ // Polish
465
+ "\u0105": "a",
466
+ "\u0107": "c",
467
+ "\u0119": "e",
468
+ "\u0142": "l",
469
+ "\u0144": "n",
470
+ // 'ó': 'o', // duplicate
471
+ "\u015B": "s",
472
+ "\u017A": "z",
473
+ "\u017C": "z",
474
+ "\u0104": "A",
475
+ "\u0106": "C",
476
+ "\u0118": "E",
477
+ "\u0141": "L",
478
+ "\u0143": "N",
479
+ "\u015A": "S",
480
+ "\u0179": "Z",
481
+ "\u017B": "Z",
482
+ // Ukranian
483
+ "\u0404": "Ye",
484
+ "\u0406": "I",
485
+ "\u0407": "Yi",
486
+ "\u0490": "G",
487
+ "\u0454": "ye",
488
+ "\u0456": "i",
489
+ "\u0457": "yi",
490
+ "\u0491": "g",
491
+ // Romanian
492
+ "\u0103": "a",
493
+ "\u0102": "A",
494
+ "\u0219": "s",
495
+ "\u0218": "S",
496
+ // 'ş': 's', // duplicate
497
+ // 'Ş': 'S', // duplicate
498
+ "\u021B": "t",
499
+ "\u021A": "T",
500
+ "\u0163": "t",
501
+ "\u0162": "T",
502
+ // Russian https://en.wikipedia.org/wiki/Romanization_of_Russian
503
+ // ICAO
504
+ "\u0430": "a",
505
+ "\u0431": "b",
506
+ "\u0432": "v",
507
+ "\u0433": "g",
508
+ "\u0434": "d",
509
+ "\u0435": "e",
510
+ "\u0451": "yo",
511
+ "\u0436": "zh",
512
+ "\u0437": "z",
513
+ "\u0438": "i",
514
+ "\u0439": "i",
515
+ "\u043A": "k",
516
+ "\u043B": "l",
517
+ "\u043C": "m",
518
+ "\u043D": "n",
519
+ "\u043E": "o",
520
+ "\u043F": "p",
521
+ "\u0440": "r",
522
+ "\u0441": "s",
523
+ "\u0442": "t",
524
+ "\u0443": "u",
525
+ "\u0444": "f",
526
+ "\u0445": "kh",
527
+ "\u0446": "c",
528
+ "\u0447": "ch",
529
+ "\u0448": "sh",
530
+ "\u0449": "sh",
531
+ "\u044A": "",
532
+ "\u044B": "y",
533
+ "\u044C": "",
534
+ "\u044D": "e",
535
+ "\u044E": "yu",
536
+ "\u044F": "ya",
537
+ "\u0410": "A",
538
+ "\u0411": "B",
539
+ "\u0412": "V",
540
+ "\u0413": "G",
541
+ "\u0414": "D",
542
+ "\u0415": "E",
543
+ "\u0401": "Yo",
544
+ "\u0416": "Zh",
545
+ "\u0417": "Z",
546
+ "\u0418": "I",
547
+ "\u0419": "I",
548
+ "\u041A": "K",
549
+ "\u041B": "L",
550
+ "\u041C": "M",
551
+ "\u041D": "N",
552
+ "\u041E": "O",
553
+ "\u041F": "P",
554
+ "\u0420": "R",
555
+ "\u0421": "S",
556
+ "\u0422": "T",
557
+ "\u0423": "U",
558
+ "\u0424": "F",
559
+ "\u0425": "Kh",
560
+ "\u0426": "C",
561
+ "\u0427": "Ch",
562
+ "\u0428": "Sh",
563
+ "\u0429": "Sh",
564
+ "\u042A": "",
565
+ "\u042B": "Y",
566
+ "\u042C": "",
567
+ "\u042D": "E",
568
+ "\u042E": "Yu",
569
+ "\u042F": "Ya",
570
+ // Serbian
571
+ "\u0452": "dj",
572
+ "\u0458": "j",
573
+ // 'љ': 'lj', // duplicate
574
+ // 'њ': 'nj', // duplicate
575
+ "\u045B": "c",
576
+ "\u045F": "dz",
577
+ "\u0402": "Dj",
578
+ "\u0408": "j",
579
+ // 'Љ': 'Lj', // duplicate
580
+ // 'Њ': 'Nj', // duplicate
581
+ "\u040B": "C",
582
+ "\u040F": "Dz",
583
+ // Slovak
584
+ "\u013E": "l",
585
+ "\u013A": "l",
586
+ "\u0155": "r",
587
+ "\u013D": "L",
588
+ "\u0139": "L",
589
+ "\u0154": "R",
590
+ // Turkish
591
+ "\u015F": "s",
592
+ "\u015E": "S",
593
+ "\u0131": "i",
594
+ "\u0130": "I",
595
+ // 'ç': 'c', // duplicate
596
+ // 'Ç': 'C', // duplicate
597
+ // 'ü': 'u', // duplicate, see langCharMap
598
+ // 'Ü': 'U', // duplicate, see langCharMap
599
+ // 'ö': 'o', // duplicate, see langCharMap
600
+ // 'Ö': 'O', // duplicate, see langCharMap
601
+ "\u011F": "g",
602
+ "\u011E": "G",
603
+ // Vietnamese
604
+ "\u1EA3": "a",
605
+ "\u1EA2": "A",
606
+ "\u1EB3": "a",
607
+ "\u1EB2": "A",
608
+ "\u1EA9": "a",
609
+ "\u1EA8": "A",
610
+ "\u0111": "d",
611
+ "\u0110": "D",
612
+ "\u1EB9": "e",
613
+ "\u1EB8": "E",
614
+ "\u1EBD": "e",
615
+ "\u1EBC": "E",
616
+ "\u1EBB": "e",
617
+ "\u1EBA": "E",
618
+ "\u1EBF": "e",
619
+ "\u1EBE": "E",
620
+ "\u1EC1": "e",
621
+ "\u1EC0": "E",
622
+ "\u1EC7": "e",
623
+ "\u1EC6": "E",
624
+ "\u1EC5": "e",
625
+ "\u1EC4": "E",
626
+ "\u1EC3": "e",
627
+ "\u1EC2": "E",
628
+ "\u1ECF": "o",
629
+ "\u1ECD": "o",
630
+ "\u1ECC": "o",
631
+ "\u1ED1": "o",
632
+ "\u1ED0": "O",
633
+ "\u1ED3": "o",
634
+ "\u1ED2": "O",
635
+ "\u1ED5": "o",
636
+ "\u1ED4": "O",
637
+ "\u1ED9": "o",
638
+ "\u1ED8": "O",
639
+ "\u1ED7": "o",
640
+ "\u1ED6": "O",
641
+ "\u01A1": "o",
642
+ "\u01A0": "O",
643
+ "\u1EDB": "o",
644
+ "\u1EDA": "O",
645
+ "\u1EDD": "o",
646
+ "\u1EDC": "O",
647
+ "\u1EE3": "o",
648
+ "\u1EE2": "O",
649
+ "\u1EE1": "o",
650
+ "\u1EE0": "O",
651
+ "\u1EDE": "o",
652
+ "\u1EDF": "o",
653
+ "\u1ECB": "i",
654
+ "\u1ECA": "I",
655
+ "\u0129": "i",
656
+ "\u0128": "I",
657
+ "\u1EC9": "i",
658
+ "\u1EC8": "i",
659
+ "\u1EE7": "u",
660
+ "\u1EE6": "U",
661
+ "\u1EE5": "u",
662
+ "\u1EE4": "U",
663
+ "\u0169": "u",
664
+ "\u0168": "U",
665
+ "\u01B0": "u",
666
+ "\u01AF": "U",
667
+ "\u1EE9": "u",
668
+ "\u1EE8": "U",
669
+ "\u1EEB": "u",
670
+ "\u1EEA": "U",
671
+ "\u1EF1": "u",
672
+ "\u1EF0": "U",
673
+ "\u1EEF": "u",
674
+ "\u1EEE": "U",
675
+ "\u1EED": "u",
676
+ "\u1EEC": "\u01B0",
677
+ "\u1EF7": "y",
678
+ "\u1EF6": "y",
679
+ "\u1EF3": "y",
680
+ "\u1EF2": "Y",
681
+ "\u1EF5": "y",
682
+ "\u1EF4": "Y",
683
+ "\u1EF9": "y",
684
+ "\u1EF8": "Y",
685
+ "\u1EA1": "a",
686
+ "\u1EA0": "A",
687
+ "\u1EA5": "a",
688
+ "\u1EA4": "A",
689
+ "\u1EA7": "a",
690
+ "\u1EA6": "A",
691
+ "\u1EAD": "a",
692
+ "\u1EAC": "A",
693
+ "\u1EAB": "a",
694
+ "\u1EAA": "A",
695
+ // 'ă': 'a', // duplicate
696
+ // 'Ă': 'A', // duplicate
697
+ "\u1EAF": "a",
698
+ "\u1EAE": "A",
699
+ "\u1EB1": "a",
700
+ "\u1EB0": "A",
701
+ "\u1EB7": "a",
702
+ "\u1EB6": "A",
703
+ "\u1EB5": "a",
704
+ "\u1EB4": "A",
705
+ "\u24EA": "0",
706
+ "\u2460": "1",
707
+ "\u2461": "2",
708
+ "\u2462": "3",
709
+ "\u2463": "4",
710
+ "\u2464": "5",
711
+ "\u2465": "6",
712
+ "\u2466": "7",
713
+ "\u2467": "8",
714
+ "\u2468": "9",
715
+ "\u2469": "10",
716
+ "\u246A": "11",
717
+ "\u246B": "12",
718
+ "\u246C": "13",
719
+ "\u246D": "14",
720
+ "\u246E": "15",
721
+ "\u246F": "16",
722
+ "\u2470": "17",
723
+ "\u2471": "18",
724
+ "\u2472": "18",
725
+ "\u2473": "18",
726
+ "\u24F5": "1",
727
+ "\u24F6": "2",
728
+ "\u24F7": "3",
729
+ "\u24F8": "4",
730
+ "\u24F9": "5",
731
+ "\u24FA": "6",
732
+ "\u24FB": "7",
733
+ "\u24FC": "8",
734
+ "\u24FD": "9",
735
+ "\u24FE": "10",
736
+ "\u24FF": "0",
737
+ "\u24EB": "11",
738
+ "\u24EC": "12",
739
+ "\u24ED": "13",
740
+ "\u24EE": "14",
741
+ "\u24EF": "15",
742
+ "\u24F0": "16",
743
+ "\u24F1": "17",
744
+ "\u24F2": "18",
745
+ "\u24F3": "19",
746
+ "\u24F4": "20",
747
+ "\u24B6": "A",
748
+ "\u24B7": "B",
749
+ "\u24B8": "C",
750
+ "\u24B9": "D",
751
+ "\u24BA": "E",
752
+ "\u24BB": "F",
753
+ "\u24BC": "G",
754
+ "\u24BD": "H",
755
+ "\u24BE": "I",
756
+ "\u24BF": "J",
757
+ "\u24C0": "K",
758
+ "\u24C1": "L",
759
+ "\u24C2": "M",
760
+ "\u24C3": "N",
761
+ "\u24C4": "O",
762
+ "\u24C5": "P",
763
+ "\u24C6": "Q",
764
+ "\u24C7": "R",
765
+ "\u24C8": "S",
766
+ "\u24C9": "T",
767
+ "\u24CA": "U",
768
+ "\u24CB": "V",
769
+ "\u24CC": "W",
770
+ "\u24CD": "X",
771
+ "\u24CE": "Y",
772
+ "\u24CF": "Z",
773
+ "\u24D0": "a",
774
+ "\u24D1": "b",
775
+ "\u24D2": "c",
776
+ "\u24D3": "d",
777
+ "\u24D4": "e",
778
+ "\u24D5": "f",
779
+ "\u24D6": "g",
780
+ "\u24D7": "h",
781
+ "\u24D8": "i",
782
+ "\u24D9": "j",
783
+ "\u24DA": "k",
784
+ "\u24DB": "l",
785
+ "\u24DC": "m",
786
+ "\u24DD": "n",
787
+ "\u24DE": "o",
788
+ "\u24DF": "p",
789
+ "\u24E0": "q",
790
+ "\u24E1": "r",
791
+ "\u24E2": "s",
792
+ "\u24E3": "t",
793
+ "\u24E4": "u",
794
+ "\u24E6": "v",
795
+ "\u24E5": "w",
796
+ "\u24E7": "x",
797
+ "\u24E8": "y",
798
+ "\u24E9": "z",
799
+ // symbols
800
+ "\u201C": '"',
801
+ "\u201D": '"',
802
+ "\u2018": "'",
803
+ "\u2019": "'",
804
+ "\u2202": "d",
805
+ "\u0192": "f",
806
+ "\u2122": "(TM)",
807
+ "\xA9": "(C)",
808
+ "\u0153": "oe",
809
+ "\u0152": "OE",
810
+ "\xAE": "(R)",
811
+ "\u2020": "+",
812
+ "\u2120": "(SM)",
813
+ "\u2026": "...",
814
+ "\u02DA": "o",
815
+ "\xBA": "o",
816
+ "\xAA": "a",
817
+ "\u2022": "*",
818
+ "\u104A": ",",
819
+ "\u104B": ".",
820
+ // currency
821
+ "$": "USD",
822
+ "\u20AC": "EUR",
823
+ "\u20A2": "BRN",
824
+ "\u20A3": "FRF",
825
+ "\xA3": "GBP",
826
+ "\u20A4": "ITL",
827
+ "\u20A6": "NGN",
828
+ "\u20A7": "ESP",
829
+ "\u20A9": "KRW",
830
+ "\u20AA": "ILS",
831
+ "\u20AB": "VND",
832
+ "\u20AD": "LAK",
833
+ "\u20AE": "MNT",
834
+ "\u20AF": "GRD",
835
+ "\u20B1": "ARS",
836
+ "\u20B2": "PYG",
837
+ "\u20B3": "ARA",
838
+ "\u20B4": "UAH",
839
+ "\u20B5": "GHS",
840
+ "\xA2": "cent",
841
+ "\xA5": "CNY",
842
+ "\u5143": "CNY",
843
+ "\u5186": "YEN",
844
+ "\uFDFC": "IRR",
845
+ "\u20A0": "EWE",
846
+ "\u0E3F": "THB",
847
+ "\u20A8": "INR",
848
+ "\u20B9": "INR",
849
+ "\u20B0": "PF",
850
+ "\u20BA": "TRY",
851
+ "\u060B": "AFN",
852
+ "\u20BC": "AZN",
853
+ "\u043B\u0432": "BGN",
854
+ "\u17DB": "KHR",
855
+ "\u20A1": "CRC",
856
+ "\u20B8": "KZT",
857
+ "\u0434\u0435\u043D": "MKD",
858
+ "z\u0142": "PLN",
859
+ "\u20BD": "RUB",
860
+ "\u20BE": "GEL"
861
+ };
862
+ var lookAheadCharArray = [
863
+ // burmese
864
+ "\u103A",
865
+ // Dhivehi
866
+ "\u07B0"
867
+ ];
868
+ var diatricMap = {
869
+ // Burmese
870
+ // dependent vowels
871
+ "\u102C": "a",
872
+ "\u102B": "a",
873
+ "\u1031": "e",
874
+ "\u1032": "e",
875
+ "\u102D": "i",
876
+ "\u102E": "i",
877
+ "\u102D\u102F": "o",
878
+ "\u102F": "u",
879
+ "\u1030": "u",
880
+ "\u1031\u102B\u1004\u103A": "aung",
881
+ "\u1031\u102C": "aw",
882
+ "\u1031\u102C\u103A": "aw",
883
+ "\u1031\u102B": "aw",
884
+ "\u1031\u102B\u103A": "aw",
885
+ "\u103A": "\u103A",
886
+ // this is special case but the character will be converted to latin in the code
887
+ "\u1000\u103A": "et",
888
+ "\u102D\u102F\u1000\u103A": "aik",
889
+ "\u1031\u102C\u1000\u103A": "auk",
890
+ "\u1004\u103A": "in",
891
+ "\u102D\u102F\u1004\u103A": "aing",
892
+ "\u1031\u102C\u1004\u103A": "aung",
893
+ "\u1005\u103A": "it",
894
+ "\u100A\u103A": "i",
895
+ "\u1010\u103A": "at",
896
+ "\u102D\u1010\u103A": "eik",
897
+ "\u102F\u1010\u103A": "ok",
898
+ "\u103D\u1010\u103A": "ut",
899
+ "\u1031\u1010\u103A": "it",
900
+ "\u1012\u103A": "d",
901
+ "\u102D\u102F\u1012\u103A": "ok",
902
+ "\u102F\u1012\u103A": "ait",
903
+ "\u1014\u103A": "an",
904
+ "\u102C\u1014\u103A": "an",
905
+ "\u102D\u1014\u103A": "ein",
906
+ "\u102F\u1014\u103A": "on",
907
+ "\u103D\u1014\u103A": "un",
908
+ "\u1015\u103A": "at",
909
+ "\u102D\u1015\u103A": "eik",
910
+ "\u102F\u1015\u103A": "ok",
911
+ "\u103D\u1015\u103A": "ut",
912
+ "\u1014\u103A\u102F\u1015\u103A": "nub",
913
+ "\u1019\u103A": "an",
914
+ "\u102D\u1019\u103A": "ein",
915
+ "\u102F\u1019\u103A": "on",
916
+ "\u103D\u1019\u103A": "un",
917
+ "\u101A\u103A": "e",
918
+ "\u102D\u102F\u101C\u103A": "ol",
919
+ "\u1009\u103A": "in",
920
+ "\u1036": "an",
921
+ "\u102D\u1036": "ein",
922
+ "\u102F\u1036": "on",
923
+ // Dhivehi
924
+ "\u07A6\u0787\u07B0": "ah",
925
+ "\u07A6\u0781\u07B0": "ah"
926
+ };
927
+ var langCharMap = {
928
+ "en": {},
929
+ // default language
930
+ "az": {
931
+ // Azerbaijani
932
+ "\xE7": "c",
933
+ "\u0259": "e",
934
+ "\u011F": "g",
935
+ "\u0131": "i",
936
+ "\xF6": "o",
937
+ "\u015F": "s",
938
+ "\xFC": "u",
939
+ "\xC7": "C",
940
+ "\u018F": "E",
941
+ "\u011E": "G",
942
+ "\u0130": "I",
943
+ "\xD6": "O",
944
+ "\u015E": "S",
945
+ "\xDC": "U"
946
+ },
947
+ "cs": {
948
+ // Czech
949
+ "\u010D": "c",
950
+ "\u010F": "d",
951
+ "\u011B": "e",
952
+ "\u0148": "n",
953
+ "\u0159": "r",
954
+ "\u0161": "s",
955
+ "\u0165": "t",
956
+ "\u016F": "u",
957
+ "\u017E": "z",
958
+ "\u010C": "C",
959
+ "\u010E": "D",
960
+ "\u011A": "E",
961
+ "\u0147": "N",
962
+ "\u0158": "R",
963
+ "\u0160": "S",
964
+ "\u0164": "T",
965
+ "\u016E": "U",
966
+ "\u017D": "Z"
967
+ },
968
+ "fi": {
969
+ // Finnish
970
+ // 'å': 'a', duplicate see charMap/latin
971
+ // 'Å': 'A', duplicate see charMap/latin
972
+ "\xE4": "a",
973
+ // ok
974
+ "\xC4": "A",
975
+ // ok
976
+ "\xF6": "o",
977
+ // ok
978
+ "\xD6": "O"
979
+ // ok
980
+ },
981
+ "hu": {
982
+ // Hungarian
983
+ "\xE4": "a",
984
+ // ok
985
+ "\xC4": "A",
986
+ // ok
987
+ // 'á': 'a', duplicate see charMap/latin
988
+ // 'Á': 'A', duplicate see charMap/latin
989
+ "\xF6": "o",
990
+ // ok
991
+ "\xD6": "O",
992
+ // ok
993
+ // 'ő': 'o', duplicate see charMap/latin
994
+ // 'Ő': 'O', duplicate see charMap/latin
995
+ "\xFC": "u",
996
+ "\xDC": "U",
997
+ "\u0171": "u",
998
+ "\u0170": "U"
999
+ },
1000
+ "lt": {
1001
+ // Lithuanian
1002
+ "\u0105": "a",
1003
+ "\u010D": "c",
1004
+ "\u0119": "e",
1005
+ "\u0117": "e",
1006
+ "\u012F": "i",
1007
+ "\u0161": "s",
1008
+ "\u0173": "u",
1009
+ "\u016B": "u",
1010
+ "\u017E": "z",
1011
+ "\u0104": "A",
1012
+ "\u010C": "C",
1013
+ "\u0118": "E",
1014
+ "\u0116": "E",
1015
+ "\u012E": "I",
1016
+ "\u0160": "S",
1017
+ "\u0172": "U",
1018
+ "\u016A": "U"
1019
+ },
1020
+ "lv": {
1021
+ // Latvian
1022
+ "\u0101": "a",
1023
+ "\u010D": "c",
1024
+ "\u0113": "e",
1025
+ "\u0123": "g",
1026
+ "\u012B": "i",
1027
+ "\u0137": "k",
1028
+ "\u013C": "l",
1029
+ "\u0146": "n",
1030
+ "\u0161": "s",
1031
+ "\u016B": "u",
1032
+ "\u017E": "z",
1033
+ "\u0100": "A",
1034
+ "\u010C": "C",
1035
+ "\u0112": "E",
1036
+ "\u0122": "G",
1037
+ "\u012A": "i",
1038
+ "\u0136": "k",
1039
+ "\u013B": "L",
1040
+ "\u0145": "N",
1041
+ "\u0160": "S",
1042
+ "\u016A": "u",
1043
+ "\u017D": "Z"
1044
+ },
1045
+ "pl": {
1046
+ // Polish
1047
+ "\u0105": "a",
1048
+ "\u0107": "c",
1049
+ "\u0119": "e",
1050
+ "\u0142": "l",
1051
+ "\u0144": "n",
1052
+ "\xF3": "o",
1053
+ "\u015B": "s",
1054
+ "\u017A": "z",
1055
+ "\u017C": "z",
1056
+ "\u0104": "A",
1057
+ "\u0106": "C",
1058
+ "\u0118": "e",
1059
+ "\u0141": "L",
1060
+ "\u0143": "N",
1061
+ "\xD3": "O",
1062
+ "\u015A": "S",
1063
+ "\u0179": "Z",
1064
+ "\u017B": "Z"
1065
+ },
1066
+ "sv": {
1067
+ // Swedish
1068
+ // 'å': 'a', duplicate see charMap/latin
1069
+ // 'Å': 'A', duplicate see charMap/latin
1070
+ "\xE4": "a",
1071
+ // ok
1072
+ "\xC4": "A",
1073
+ // ok
1074
+ "\xF6": "o",
1075
+ // ok
1076
+ "\xD6": "O"
1077
+ // ok
1078
+ },
1079
+ "sk": {
1080
+ // Slovak
1081
+ "\xE4": "a",
1082
+ "\xC4": "A"
1083
+ },
1084
+ "sr": {
1085
+ // Serbian
1086
+ "\u0459": "lj",
1087
+ "\u045A": "nj",
1088
+ "\u0409": "Lj",
1089
+ "\u040A": "Nj",
1090
+ "\u0111": "dj",
1091
+ "\u0110": "Dj"
1092
+ },
1093
+ "tr": {
1094
+ // Turkish
1095
+ "\xDC": "U",
1096
+ "\xD6": "O",
1097
+ "\xFC": "u",
1098
+ "\xF6": "o"
1099
+ }
1100
+ };
1101
+ var symbolMap = {
1102
+ "ar": {
1103
+ "\u2206": "delta",
1104
+ "\u221E": "la-nihaya",
1105
+ "\u2665": "hob",
1106
+ "&": "wa",
1107
+ "|": "aw",
1108
+ "<": "aqal-men",
1109
+ ">": "akbar-men",
1110
+ "\u2211": "majmou",
1111
+ "\xA4": "omla"
1112
+ },
1113
+ "az": {},
1114
+ "ca": {
1115
+ "\u2206": "delta",
1116
+ "\u221E": "infinit",
1117
+ "\u2665": "amor",
1118
+ "&": "i",
1119
+ "|": "o",
1120
+ "<": "menys que",
1121
+ ">": "mes que",
1122
+ "\u2211": "suma dels",
1123
+ "\xA4": "moneda"
1124
+ },
1125
+ "cs": {
1126
+ "\u2206": "delta",
1127
+ "\u221E": "nekonecno",
1128
+ "\u2665": "laska",
1129
+ "&": "a",
1130
+ "|": "nebo",
1131
+ "<": "mensi nez",
1132
+ ">": "vetsi nez",
1133
+ "\u2211": "soucet",
1134
+ "\xA4": "mena"
1135
+ },
1136
+ "de": {
1137
+ "\u2206": "delta",
1138
+ "\u221E": "unendlich",
1139
+ "\u2665": "Liebe",
1140
+ "&": "und",
1141
+ "|": "oder",
1142
+ "<": "kleiner als",
1143
+ ">": "groesser als",
1144
+ "\u2211": "Summe von",
1145
+ "\xA4": "Waehrung"
1146
+ },
1147
+ "dv": {
1148
+ "\u2206": "delta",
1149
+ "\u221E": "kolunulaa",
1150
+ "\u2665": "loabi",
1151
+ "&": "aai",
1152
+ "|": "noonee",
1153
+ "<": "ah vure kuda",
1154
+ ">": "ah vure bodu",
1155
+ "\u2211": "jumula",
1156
+ "\xA4": "faisaa"
1157
+ },
1158
+ "en": {
1159
+ "\u2206": "delta",
1160
+ "\u221E": "infinity",
1161
+ "\u2665": "love",
1162
+ "&": "and",
1163
+ "|": "or",
1164
+ "<": "less than",
1165
+ ">": "greater than",
1166
+ "\u2211": "sum",
1167
+ "\xA4": "currency"
1168
+ },
1169
+ "es": {
1170
+ "\u2206": "delta",
1171
+ "\u221E": "infinito",
1172
+ "\u2665": "amor",
1173
+ "&": "y",
1174
+ "|": "u",
1175
+ "<": "menos que",
1176
+ ">": "mas que",
1177
+ "\u2211": "suma de los",
1178
+ "\xA4": "moneda"
1179
+ },
1180
+ "fa": {
1181
+ "\u2206": "delta",
1182
+ "\u221E": "bi-nahayat",
1183
+ "\u2665": "eshgh",
1184
+ "&": "va",
1185
+ "|": "ya",
1186
+ "<": "kamtar-az",
1187
+ ">": "bishtar-az",
1188
+ "\u2211": "majmooe",
1189
+ "\xA4": "vahed"
1190
+ },
1191
+ "fi": {
1192
+ "\u2206": "delta",
1193
+ "\u221E": "aarettomyys",
1194
+ "\u2665": "rakkaus",
1195
+ "&": "ja",
1196
+ "|": "tai",
1197
+ "<": "pienempi kuin",
1198
+ ">": "suurempi kuin",
1199
+ "\u2211": "summa",
1200
+ "\xA4": "valuutta"
1201
+ },
1202
+ "fr": {
1203
+ "\u2206": "delta",
1204
+ "\u221E": "infiniment",
1205
+ "\u2665": "Amour",
1206
+ "&": "et",
1207
+ "|": "ou",
1208
+ "<": "moins que",
1209
+ ">": "superieure a",
1210
+ "\u2211": "somme des",
1211
+ "\xA4": "monnaie"
1212
+ },
1213
+ "ge": {
1214
+ "\u2206": "delta",
1215
+ "\u221E": "usasruloba",
1216
+ "\u2665": "siqvaruli",
1217
+ "&": "da",
1218
+ "|": "an",
1219
+ "<": "naklebi",
1220
+ ">": "meti",
1221
+ "\u2211": "jami",
1222
+ "\xA4": "valuta"
1223
+ },
1224
+ "gr": {},
1225
+ "hu": {
1226
+ "\u2206": "delta",
1227
+ "\u221E": "vegtelen",
1228
+ "\u2665": "szerelem",
1229
+ "&": "es",
1230
+ "|": "vagy",
1231
+ "<": "kisebb mint",
1232
+ ">": "nagyobb mint",
1233
+ "\u2211": "szumma",
1234
+ "\xA4": "penznem"
1235
+ },
1236
+ "it": {
1237
+ "\u2206": "delta",
1238
+ "\u221E": "infinito",
1239
+ "\u2665": "amore",
1240
+ "&": "e",
1241
+ "|": "o",
1242
+ "<": "minore di",
1243
+ ">": "maggiore di",
1244
+ "\u2211": "somma",
1245
+ "\xA4": "moneta"
1246
+ },
1247
+ "lt": {
1248
+ "\u2206": "delta",
1249
+ "\u221E": "begalybe",
1250
+ "\u2665": "meile",
1251
+ "&": "ir",
1252
+ "|": "ar",
1253
+ "<": "maziau nei",
1254
+ ">": "daugiau nei",
1255
+ "\u2211": "suma",
1256
+ "\xA4": "valiuta"
1257
+ },
1258
+ "lv": {
1259
+ "\u2206": "delta",
1260
+ "\u221E": "bezgaliba",
1261
+ "\u2665": "milestiba",
1262
+ "&": "un",
1263
+ "|": "vai",
1264
+ "<": "mazak neka",
1265
+ ">": "lielaks neka",
1266
+ "\u2211": "summa",
1267
+ "\xA4": "valuta"
1268
+ },
1269
+ "my": {
1270
+ "\u2206": "kwahkhyaet",
1271
+ "\u221E": "asaonasme",
1272
+ "\u2665": "akhyait",
1273
+ "&": "nhin",
1274
+ "|": "tho",
1275
+ "<": "ngethaw",
1276
+ ">": "kyithaw",
1277
+ "\u2211": "paungld",
1278
+ "\xA4": "ngwekye"
1279
+ },
1280
+ "mk": {},
1281
+ "nl": {
1282
+ "\u2206": "delta",
1283
+ "\u221E": "oneindig",
1284
+ "\u2665": "liefde",
1285
+ "&": "en",
1286
+ "|": "of",
1287
+ "<": "kleiner dan",
1288
+ ">": "groter dan",
1289
+ "\u2211": "som",
1290
+ "\xA4": "valuta"
1291
+ },
1292
+ "pl": {
1293
+ "\u2206": "delta",
1294
+ "\u221E": "nieskonczonosc",
1295
+ "\u2665": "milosc",
1296
+ "&": "i",
1297
+ "|": "lub",
1298
+ "<": "mniejsze niz",
1299
+ ">": "wieksze niz",
1300
+ "\u2211": "suma",
1301
+ "\xA4": "waluta"
1302
+ },
1303
+ "pt": {
1304
+ "\u2206": "delta",
1305
+ "\u221E": "infinito",
1306
+ "\u2665": "amor",
1307
+ "&": "e",
1308
+ "|": "ou",
1309
+ "<": "menor que",
1310
+ ">": "maior que",
1311
+ "\u2211": "soma",
1312
+ "\xA4": "moeda"
1313
+ },
1314
+ "ro": {
1315
+ "\u2206": "delta",
1316
+ "\u221E": "infinit",
1317
+ "\u2665": "dragoste",
1318
+ "&": "si",
1319
+ "|": "sau",
1320
+ "<": "mai mic ca",
1321
+ ">": "mai mare ca",
1322
+ "\u2211": "suma",
1323
+ "\xA4": "valuta"
1324
+ },
1325
+ "ru": {
1326
+ "\u2206": "delta",
1327
+ "\u221E": "beskonechno",
1328
+ "\u2665": "lubov",
1329
+ "&": "i",
1330
+ "|": "ili",
1331
+ "<": "menshe",
1332
+ ">": "bolshe",
1333
+ "\u2211": "summa",
1334
+ "\xA4": "valjuta"
1335
+ },
1336
+ "sk": {
1337
+ "\u2206": "delta",
1338
+ "\u221E": "nekonecno",
1339
+ "\u2665": "laska",
1340
+ "&": "a",
1341
+ "|": "alebo",
1342
+ "<": "menej ako",
1343
+ ">": "viac ako",
1344
+ "\u2211": "sucet",
1345
+ "\xA4": "mena"
1346
+ },
1347
+ "sr": {},
1348
+ "tr": {
1349
+ "\u2206": "delta",
1350
+ "\u221E": "sonsuzluk",
1351
+ "\u2665": "ask",
1352
+ "&": "ve",
1353
+ "|": "veya",
1354
+ "<": "kucuktur",
1355
+ ">": "buyuktur",
1356
+ "\u2211": "toplam",
1357
+ "\xA4": "para birimi"
1358
+ },
1359
+ "uk": {
1360
+ "\u2206": "delta",
1361
+ "\u221E": "bezkinechnist",
1362
+ "\u2665": "lubov",
1363
+ "&": "i",
1364
+ "|": "abo",
1365
+ "<": "menshe",
1366
+ ">": "bilshe",
1367
+ "\u2211": "suma",
1368
+ "\xA4": "valjuta"
1369
+ },
1370
+ "vn": {
1371
+ "\u2206": "delta",
1372
+ "\u221E": "vo cuc",
1373
+ "\u2665": "yeu",
1374
+ "&": "va",
1375
+ "|": "hoac",
1376
+ "<": "nho hon",
1377
+ ">": "lon hon",
1378
+ "\u2211": "tong",
1379
+ "\xA4": "tien te"
1380
+ }
1381
+ };
1382
+ var uricChars = [";", "?", ":", "@", "&", "=", "+", "$", ",", "/"].join("");
1383
+ var uricNoSlashChars = [";", "?", ":", "@", "&", "=", "+", "$", ","].join("");
1384
+ var markChars = [".", "!", "~", "*", "'", "(", ")"].join("");
1385
+ var getSlug = function getSlug2(input, opts) {
1386
+ var separator = "-";
1387
+ var result = "";
1388
+ var diatricString = "";
1389
+ var convertSymbols = true;
1390
+ var customReplacements = {};
1391
+ var maintainCase;
1392
+ var titleCase;
1393
+ var truncate;
1394
+ var uricFlag;
1395
+ var uricNoSlashFlag;
1396
+ var markFlag;
1397
+ var symbol;
1398
+ var langChar;
1399
+ var lucky;
1400
+ var i;
1401
+ var ch;
1402
+ var l;
1403
+ var lastCharWasSymbol;
1404
+ var lastCharWasDiatric;
1405
+ var allowedChars = "";
1406
+ if (typeof input !== "string") {
1407
+ return "";
1408
+ }
1409
+ if (typeof opts === "string") {
1410
+ separator = opts;
1411
+ }
1412
+ symbol = symbolMap.en;
1413
+ langChar = langCharMap.en;
1414
+ if (typeof opts === "object") {
1415
+ maintainCase = opts.maintainCase || false;
1416
+ customReplacements = opts.custom && typeof opts.custom === "object" ? opts.custom : customReplacements;
1417
+ truncate = +opts.truncate > 1 && opts.truncate || false;
1418
+ uricFlag = opts.uric || false;
1419
+ uricNoSlashFlag = opts.uricNoSlash || false;
1420
+ markFlag = opts.mark || false;
1421
+ convertSymbols = opts.symbols === false || opts.lang === false ? false : true;
1422
+ separator = opts.separator || separator;
1423
+ if (uricFlag) {
1424
+ allowedChars += uricChars;
1425
+ }
1426
+ if (uricNoSlashFlag) {
1427
+ allowedChars += uricNoSlashChars;
1428
+ }
1429
+ if (markFlag) {
1430
+ allowedChars += markChars;
1431
+ }
1432
+ symbol = opts.lang && symbolMap[opts.lang] && convertSymbols ? symbolMap[opts.lang] : convertSymbols ? symbolMap.en : {};
1433
+ langChar = opts.lang && langCharMap[opts.lang] ? langCharMap[opts.lang] : opts.lang === false || opts.lang === true ? {} : langCharMap.en;
1434
+ if (opts.titleCase && typeof opts.titleCase.length === "number" && Array.prototype.toString.call(opts.titleCase)) {
1435
+ opts.titleCase.forEach(function(v) {
1436
+ customReplacements[v + ""] = v + "";
1437
+ });
1438
+ titleCase = true;
1439
+ } else {
1440
+ titleCase = !!opts.titleCase;
1441
+ }
1442
+ if (opts.custom && typeof opts.custom.length === "number" && Array.prototype.toString.call(opts.custom)) {
1443
+ opts.custom.forEach(function(v) {
1444
+ customReplacements[v + ""] = v + "";
1445
+ });
1446
+ }
1447
+ Object.keys(customReplacements).forEach(function(v) {
1448
+ var r;
1449
+ if (v.length > 1) {
1450
+ r = new RegExp("\\b" + escapeChars(v) + "\\b", "gi");
1451
+ } else {
1452
+ r = new RegExp(escapeChars(v), "gi");
1453
+ }
1454
+ input = input.replace(r, customReplacements[v]);
1455
+ });
1456
+ for (ch in customReplacements) {
1457
+ allowedChars += ch;
1458
+ }
1459
+ }
1460
+ allowedChars += separator;
1461
+ allowedChars = escapeChars(allowedChars);
1462
+ input = input.replace(/(^\s+|\s+$)/g, "");
1463
+ lastCharWasSymbol = false;
1464
+ lastCharWasDiatric = false;
1465
+ for (i = 0, l = input.length; i < l; i++) {
1466
+ ch = input[i];
1467
+ if (isReplacedCustomChar(ch, customReplacements)) {
1468
+ lastCharWasSymbol = false;
1469
+ } else if (langChar[ch]) {
1470
+ ch = lastCharWasSymbol && langChar[ch].match(/[A-Za-z0-9]/) ? " " + langChar[ch] : langChar[ch];
1471
+ lastCharWasSymbol = false;
1472
+ } else if (ch in charMap) {
1473
+ if (i + 1 < l && lookAheadCharArray.indexOf(input[i + 1]) >= 0) {
1474
+ diatricString += ch;
1475
+ ch = "";
1476
+ } else if (lastCharWasDiatric === true) {
1477
+ ch = diatricMap[diatricString] + charMap[ch];
1478
+ diatricString = "";
1479
+ } else {
1480
+ ch = lastCharWasSymbol && charMap[ch].match(/[A-Za-z0-9]/) ? " " + charMap[ch] : charMap[ch];
1481
+ }
1482
+ lastCharWasSymbol = false;
1483
+ lastCharWasDiatric = false;
1484
+ } else if (ch in diatricMap) {
1485
+ diatricString += ch;
1486
+ ch = "";
1487
+ if (i === l - 1) {
1488
+ ch = diatricMap[diatricString];
1489
+ }
1490
+ lastCharWasDiatric = true;
1491
+ } else if (
1492
+ // process symbol chars
1493
+ symbol[ch] && !(uricFlag && uricChars.indexOf(ch) !== -1) && !(uricNoSlashFlag && uricNoSlashChars.indexOf(ch) !== -1)
1494
+ ) {
1495
+ ch = lastCharWasSymbol || result.substr(-1).match(/[A-Za-z0-9]/) ? separator + symbol[ch] : symbol[ch];
1496
+ ch += input[i + 1] !== void 0 && input[i + 1].match(/[A-Za-z0-9]/) ? separator : "";
1497
+ lastCharWasSymbol = true;
1498
+ } else {
1499
+ if (lastCharWasDiatric === true) {
1500
+ ch = diatricMap[diatricString] + ch;
1501
+ diatricString = "";
1502
+ lastCharWasDiatric = false;
1503
+ } else if (lastCharWasSymbol && (/[A-Za-z0-9]/.test(ch) || result.substr(-1).match(/A-Za-z0-9]/))) {
1504
+ ch = " " + ch;
1505
+ }
1506
+ lastCharWasSymbol = false;
1507
+ }
1508
+ result += ch.replace(new RegExp("[^\\w\\s" + allowedChars + "_-]", "g"), separator);
1509
+ }
1510
+ if (titleCase) {
1511
+ result = result.replace(/(\w)(\S*)/g, function(_, i2, r) {
1512
+ var j = i2.toUpperCase() + (r !== null ? r : "");
1513
+ return Object.keys(customReplacements).indexOf(j.toLowerCase()) < 0 ? j : j.toLowerCase();
1514
+ });
1515
+ }
1516
+ result = result.replace(/\s+/g, separator).replace(new RegExp("\\" + separator + "+", "g"), separator).replace(new RegExp("(^\\" + separator + "+|\\" + separator + "+$)", "g"), "");
1517
+ if (truncate && result.length > truncate) {
1518
+ lucky = result.charAt(truncate) === separator;
1519
+ result = result.slice(0, truncate);
1520
+ if (!lucky) {
1521
+ result = result.slice(0, result.lastIndexOf(separator));
1522
+ }
1523
+ }
1524
+ if (!maintainCase && !titleCase) {
1525
+ result = result.toLowerCase();
1526
+ }
1527
+ return result;
1528
+ };
1529
+ var createSlug = function createSlug2(opts) {
1530
+ return function getSlugWithConfig(input) {
1531
+ return getSlug(input, opts);
1532
+ };
1533
+ };
1534
+ var escapeChars = function escapeChars2(input) {
1535
+ return input.replace(/[-\\^$*+?.()|[\]{}\/]/g, "\\$&");
1536
+ };
1537
+ var isReplacedCustomChar = function(ch, customReplacements) {
1538
+ for (var c in customReplacements) {
1539
+ if (customReplacements[c] === ch) {
1540
+ return true;
1541
+ }
1542
+ }
1543
+ };
1544
+ if (typeof module !== "undefined" && module.exports) {
1545
+ module.exports = getSlug;
1546
+ module.exports.createSlug = createSlug;
1547
+ } else if (typeof define !== "undefined" && define.amd) {
1548
+ define([], function() {
1549
+ return getSlug;
1550
+ });
1551
+ } else {
1552
+ try {
1553
+ if (root.getSlug || root.createSlug) {
1554
+ throw "speakingurl: globals exists /(getSlug|createSlug)/";
1555
+ } else {
1556
+ root.getSlug = getSlug;
1557
+ root.createSlug = createSlug;
1558
+ }
1559
+ } catch (e) {
1560
+ }
1561
+ }
1562
+ })(exports);
1563
+ }
1564
+ });
1565
+
1566
+ // ../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/index.js
1567
+ var require_speakingurl2 = __commonJS({
1568
+ "../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/index.js"(exports, module) {
1569
+ "use strict";
1570
+ init_esm_shims();
1571
+ module.exports = require_speakingurl();
1572
+ }
1573
+ });
1574
+
1575
+ // src/index.ts
1576
+ init_esm_shims();
1577
+
1578
+ // src/core/general/index.ts
1579
+ init_esm_shims();
1580
+ import { target as target7 } from "@vue/devtools-shared";
1581
+ import { DevToolsHooks as DevToolsHooks3 } from "@vue/devtools-schema";
1582
+
1583
+ // src/api/index.ts
1584
+ init_esm_shims();
1585
+
1586
+ // src/core/general/state.ts
1587
+ init_esm_shims();
1588
+ import { deepClone as deepClone2, target as global2 } from "@vue/devtools-shared";
1589
+ import { debounce as debounce2 } from "perfect-debounce";
1590
+
1591
+ // src/core/router/index.ts
1592
+ init_esm_shims();
1593
+ import { deepClone, target as global } from "@vue/devtools-shared";
1594
+ import { debounce } from "perfect-debounce";
1595
+
1596
+ // src/core/general/hook.ts
1597
+ init_esm_shims();
1598
+ import { DevToolsHooks } from "@vue/devtools-schema";
1599
+ import { target } from "@vue/devtools-shared";
1600
+ import { createHooks } from "hookable";
1601
+ var _a, _b;
1602
+ var devtoolsHooks = (_b = (_a = target).__VUE_DEVTOOLS_HOOK) != null ? _b : _a.__VUE_DEVTOOLS_HOOK = createHooks();
1603
+ var on = {
1604
+ vueAppInit(fn) {
1605
+ devtoolsHooks.hook(DevToolsHooks.APP_INIT, fn);
1606
+ },
1607
+ vueAppConnected(fn) {
1608
+ devtoolsHooks.hook(DevToolsHooks.APP_CONNECTED, fn);
1609
+ },
1610
+ componentAdded(fn) {
1611
+ return devtoolsHooks.hook(DevToolsHooks.COMPONENT_ADDED, fn);
1612
+ },
1613
+ componentUpdated(fn) {
1614
+ return devtoolsHooks.hook(DevToolsHooks.COMPONENT_UPDATED, fn);
1615
+ },
1616
+ componentRemoved(fn) {
1617
+ return devtoolsHooks.hook(DevToolsHooks.COMPONENT_REMOVED, fn);
1618
+ },
1619
+ setupDevtoolsPlugin(fn) {
1620
+ devtoolsHooks.hook(DevToolsHooks.SETUP_DEVTOOLS_PLUGIN, fn);
1621
+ }
1622
+ };
1623
+ function createDevToolsHook() {
1624
+ return {
1625
+ id: "vue-devtools-next",
1626
+ enabled: false,
1627
+ appRecords: [],
1628
+ apps: {},
1629
+ events: /* @__PURE__ */ new Map(),
1630
+ on(event, fn) {
1631
+ var _a8;
1632
+ if (!this.events.has(event))
1633
+ this.events.set(event, []);
1634
+ (_a8 = this.events.get(event)) == null ? void 0 : _a8.push(fn);
1635
+ return () => this.off(event, fn);
1636
+ },
1637
+ once(event, fn) {
1638
+ const onceFn = (...args) => {
1639
+ this.off(event, onceFn);
1640
+ fn(...args);
1641
+ };
1642
+ this.on(event, onceFn);
1643
+ return [event, onceFn];
1644
+ },
1645
+ off(event, fn) {
1646
+ if (this.events.has(event)) {
1647
+ const eventCallbacks = this.events.get(event);
1648
+ const index = eventCallbacks.indexOf(fn);
1649
+ if (index !== -1)
1650
+ eventCallbacks.splice(index, 1);
1651
+ }
1652
+ },
1653
+ emit(event, ...payload) {
1654
+ if (this.events.has(event))
1655
+ this.events.get(event).forEach((fn) => fn(...payload));
1656
+ }
1657
+ };
1658
+ }
1659
+ function subscribeDevToolsHook() {
1660
+ const hook2 = target.__VUE_DEVTOOLS_GLOBAL_HOOK__;
1661
+ hook2.on(DevToolsHooks.APP_INIT, (app, version) => {
1662
+ var _a8, _b8, _c;
1663
+ if ((_c = (_b8 = (_a8 = app == null ? void 0 : app._instance) == null ? void 0 : _a8.type) == null ? void 0 : _b8.devtools) == null ? void 0 : _c.hide)
1664
+ return;
1665
+ devtoolsHooks.callHook(DevToolsHooks.APP_INIT, app, version);
1666
+ });
1667
+ hook2.on(DevToolsHooks.COMPONENT_ADDED, async (app, uid, parentUid, component) => {
1668
+ var _a8, _b8, _c;
1669
+ if ((_c = (_b8 = (_a8 = app == null ? void 0 : app._instance) == null ? void 0 : _a8.type) == null ? void 0 : _b8.devtools) == null ? void 0 : _c.hide)
1670
+ return;
1671
+ if (!app || typeof uid !== "number" && !uid || !component)
1672
+ return;
1673
+ devtoolsHooks.callHook(DevToolsHooks.COMPONENT_ADDED, app, uid, parentUid, component);
1674
+ });
1675
+ hook2.on(DevToolsHooks.COMPONENT_UPDATED, (app, uid, parentUid, component) => {
1676
+ if (!app || typeof uid !== "number" && !uid || !component)
1677
+ return;
1678
+ devtoolsHooks.callHook(DevToolsHooks.COMPONENT_UPDATED, app, uid, parentUid, component);
1679
+ });
1680
+ hook2.on(DevToolsHooks.COMPONENT_REMOVED, async (app, uid, parentUid, component) => {
1681
+ if (!app || typeof uid !== "number" && !uid || !component)
1682
+ return;
1683
+ devtoolsHooks.callHook(DevToolsHooks.COMPONENT_REMOVED, app, uid, parentUid, component);
1684
+ });
1685
+ hook2.on(DevToolsHooks.SETUP_DEVTOOLS_PLUGIN, (pluginDescriptor, setupFn) => {
1686
+ devtoolsHooks.callHook(DevToolsHooks.SETUP_DEVTOOLS_PLUGIN, pluginDescriptor, setupFn);
1687
+ });
1688
+ }
1689
+ var hook = {
1690
+ on
1691
+ };
1692
+
1693
+ // src/core/router/index.ts
1694
+ var RouterInfoKey = "__VUE_DEVTOOLS_ROUTER_INFO__";
1695
+ var RouterKey = "__VUE_DEVTOOLS_ROUTER__";
1696
+ var _a2, _b2;
1697
+ (_b2 = (_a2 = global)[RouterInfoKey]) != null ? _b2 : _a2[RouterInfoKey] = {
1698
+ currentRoute: null,
1699
+ routes: [],
1700
+ router: null
1701
+ };
1702
+ var _a3, _b3;
1703
+ (_b3 = (_a3 = global)[RouterKey]) != null ? _b3 : _a3[RouterKey] = null;
1704
+ var devtoolsRouterInfo = new Proxy(global[RouterInfoKey], {
1705
+ get(target8, property) {
1706
+ return global[RouterInfoKey][property];
1707
+ }
1708
+ });
1709
+ function normalizeRouterInfo(appRecord) {
1710
+ const getRoutes = (router) => {
1711
+ const routesMap = /* @__PURE__ */ new Map();
1712
+ return ((router == null ? void 0 : router.getRoutes()) || []).filter((i) => !routesMap.has(i.path) && routesMap.set(i.path, 1));
1713
+ };
1714
+ function init() {
1715
+ var _a8;
1716
+ const router = (_a8 = appRecord.app) == null ? void 0 : _a8.config.globalProperties.$router;
1717
+ const currentRoute = router == null ? void 0 : router.currentRoute.value;
1718
+ const routes = getRoutes(router).map((item) => {
1719
+ const { path, name, children } = item;
1720
+ return {
1721
+ path,
1722
+ name,
1723
+ children
1724
+ };
1725
+ });
1726
+ const c = console.warn;
1727
+ console.warn = () => {
1728
+ };
1729
+ global[RouterInfoKey] = {
1730
+ currentRoute: currentRoute ? deepClone(currentRoute) : {},
1731
+ routes: deepClone(routes)
1732
+ };
1733
+ global[RouterKey] = router;
1734
+ console.warn = c;
1735
+ }
1736
+ init();
1737
+ hook.on.componentUpdated(debounce(() => {
1738
+ init();
1739
+ apiHooks.callHook("router-info:updated" /* ROUTER_INFO_UPDATED */, global[RouterInfoKey]);
1740
+ }, 200));
1741
+ }
1742
+ function getRouterDevToolsId(id) {
1743
+ return id.replace(/\D/g, "") || "0";
1744
+ }
1745
+
1746
+ // src/core/general/state.ts
1747
+ var StateKey = "__VUE_DEVTOOLS_GLOBAL_STATE__";
1748
+ var ContextKey = "__VUE_DEVTOOLS_CONTEXT__";
1749
+ var DefaultContext = {
1750
+ appRecord: null,
1751
+ api: null,
1752
+ inspector: [],
1753
+ timelineLayer: [],
1754
+ routerInfo: {},
1755
+ router: null,
1756
+ activeInspectorTreeId: "",
1757
+ componentPluginHookBuffer: []
1758
+ };
1759
+ var _a4, _b4;
1760
+ (_b4 = (_a4 = global2)[StateKey]) != null ? _b4 : _a4[StateKey] = {
1761
+ connected: false,
1762
+ clientConnected: false,
1763
+ appRecords: [],
1764
+ activeAppRecord: null,
1765
+ selectedComponentId: null,
1766
+ pluginBuffer: [],
1767
+ tabs: [],
1768
+ commands: [],
1769
+ vitePluginDetected: false,
1770
+ activeAppRecordId: null
1771
+ };
1772
+ var _a5, _b5;
1773
+ (_b5 = (_a5 = global2)[ContextKey]) != null ? _b5 : _a5[ContextKey] = deepClone2(DefaultContext);
1774
+ var callStateUpdatedHook = debounce2((state, oldState) => {
1775
+ apiHooks.callHook("devtools:state-updated" /* DEVTOOLS_STATE_UPDATED */, state, oldState);
1776
+ }, 80);
1777
+ var callConnectedUpdatedHook = debounce2((state, oldState) => {
1778
+ apiHooks.callHook("devtools:connected-updated" /* DEVTOOLS_CONNECTED_UPDATED */, state, oldState);
1779
+ }, 80);
1780
+ var devtoolsState = new Proxy(global2[StateKey], {
1781
+ get(target8, property) {
1782
+ return global2[StateKey][property];
1783
+ },
1784
+ set(target8, property, value) {
1785
+ var _a8;
1786
+ const oldState = { ...global2[StateKey] };
1787
+ target8[property] = value;
1788
+ global2[StateKey][property] = value;
1789
+ if (property === "activeAppRecord") {
1790
+ global2[ContextKey].appRecord = value;
1791
+ global2[ContextKey].api = value.api;
1792
+ global2[ContextKey].inspector = (_a8 = value.inspector) != null ? _a8 : [];
1793
+ normalizeRouterInfo(value);
1794
+ global2[ContextKey].routerInfo = devtoolsRouterInfo;
1795
+ }
1796
+ callStateUpdatedHook(global2[StateKey], oldState);
1797
+ if (["connected", "clientConnected"].includes(property.toString()) && oldState[property] !== value)
1798
+ callConnectedUpdatedHook(global2[StateKey], oldState);
1799
+ return true;
1800
+ },
1801
+ deleteProperty(target8, property) {
1802
+ delete target8[property];
1803
+ return true;
1804
+ }
1805
+ });
1806
+ Object.defineProperty(devtoolsState.tabs, "push", {
1807
+ configurable: true,
1808
+ value(...items) {
1809
+ const result = Array.prototype.push.apply(this, items);
1810
+ devtoolsState.tabs = this;
1811
+ apiHooks.callHook("custom-tabs:updated" /* CUSTOM_TABS_UPDATED */, this);
1812
+ return result;
1813
+ }
1814
+ });
1815
+ ["push", "splice"].forEach((method) => {
1816
+ Object.defineProperty(devtoolsState.commands, method, {
1817
+ configurable: true,
1818
+ value(...args) {
1819
+ const result = Array.prototype[method].apply(this, args);
1820
+ devtoolsState.commands = this;
1821
+ apiHooks.callHook("custom-commands:updated" /* CUSTOM_COMMANDS_UPDATED */, this);
1822
+ return result;
1823
+ }
1824
+ });
1825
+ });
1826
+ var devtoolsContext = new Proxy(global2[ContextKey], {
1827
+ get(target8, property) {
1828
+ if (property === "router")
1829
+ return global2[RouterKey];
1830
+ else if (property === "clear")
1831
+ return clearDevToolsContext;
1832
+ return global2[ContextKey][property];
1833
+ },
1834
+ set(target8, property, value) {
1835
+ if (property === "componentPluginHookBuffer")
1836
+ global2[ContextKey][property] = value;
1837
+ return true;
1838
+ }
1839
+ });
1840
+ function clearDevToolsContext() {
1841
+ global2[ContextKey] = deepClone2(DefaultContext);
1842
+ }
1843
+
1844
+ // src/shared/index.ts
1845
+ init_esm_shims();
1846
+
1847
+ // src/shared/util.ts
1848
+ init_esm_shims();
1849
+
1850
+ // src/core/component/state/format.ts
1851
+ init_esm_shims();
1852
+
1853
+ // src/core/component/state/constants.ts
1854
+ init_esm_shims();
1855
+ var vueBuiltins = [
1856
+ "nextTick",
1857
+ "defineComponent",
1858
+ "defineAsyncComponent",
1859
+ "defineCustomElement",
1860
+ "ref",
1861
+ "computed",
1862
+ "reactive",
1863
+ "readonly",
1864
+ "watchEffect",
1865
+ "watchPostEffect",
1866
+ "watchSyncEffect",
1867
+ "watch",
1868
+ "isRef",
1869
+ "unref",
1870
+ "toRef",
1871
+ "toRefs",
1872
+ "isProxy",
1873
+ "isReactive",
1874
+ "isReadonly",
1875
+ "shallowRef",
1876
+ "triggerRef",
1877
+ "customRef",
1878
+ "shallowReactive",
1879
+ "shallowReadonly",
1880
+ "toRaw",
1881
+ "markRaw",
1882
+ "effectScope",
1883
+ "getCurrentScope",
1884
+ "onScopeDispose",
1885
+ "onMounted",
1886
+ "onUpdated",
1887
+ "onUnmounted",
1888
+ "onBeforeMount",
1889
+ "onBeforeUpdate",
1890
+ "onBeforeUnmount",
1891
+ "onErrorCaptured",
1892
+ "onRenderTracked",
1893
+ "onRenderTriggered",
1894
+ "onActivated",
1895
+ "onDeactivated",
1896
+ "onServerPrefetch",
1897
+ "provide",
1898
+ "inject",
1899
+ "h",
1900
+ "mergeProps",
1901
+ "cloneVNode",
1902
+ "isVNode",
1903
+ "resolveComponent",
1904
+ "resolveDirective",
1905
+ "withDirectives",
1906
+ "withModifiers"
1907
+ ];
1908
+ var symbolRE = /^\[native Symbol Symbol\((.*)\)\]$/;
1909
+ var rawTypeRE = /^\[object (\w+)]$/;
1910
+ var specialTypeRE = /^\[native (\w+) (.*?)(<>((.|\s)*))?\]$/;
1911
+ var fnTypeRE = /^(?:function|class) (\w+)/;
1912
+ var MAX_STRING_SIZE = 1e4;
1913
+ var MAX_ARRAY_SIZE = 5e3;
1914
+ var UNDEFINED = "__vue_devtool_undefined__";
1915
+ var INFINITY = "__vue_devtool_infinity__";
1916
+ var NEGATIVE_INFINITY = "__vue_devtool_negative_infinity__";
1917
+ var NAN = "__vue_devtool_nan__";
1918
+ var ESC = {
1919
+ "<": "&lt;",
1920
+ ">": "&gt;",
1921
+ '"': "&quot;",
1922
+ "&": "&amp;"
1923
+ };
1924
+
1925
+ // src/core/component/state/is.ts
1926
+ init_esm_shims();
1927
+ function isVueInstance(value) {
1928
+ return value._ && Object.keys(value._).includes("vnode");
1929
+ }
1930
+ function isPlainObject(obj) {
1931
+ return Object.prototype.toString.call(obj) === "[object Object]";
1932
+ }
1933
+ function isPrimitive(data) {
1934
+ if (data == null)
1935
+ return true;
1936
+ const type = typeof data;
1937
+ return type === "string" || type === "number" || type === "boolean";
1938
+ }
1939
+ function isRef(raw) {
1940
+ return !!raw.__v_isRef;
1941
+ }
1942
+ function isComputed(raw) {
1943
+ return isRef(raw) && !!raw.effect;
1944
+ }
1945
+ function isReactive(raw) {
1946
+ return !!raw.__v_isReactive;
1947
+ }
1948
+ function isReadOnly(raw) {
1949
+ return !!raw.__v_isReadonly;
1950
+ }
1951
+
1952
+ // src/core/component/state/util.ts
1953
+ init_esm_shims();
1954
+ function internalStateTokenToString(value) {
1955
+ if (value === null)
1956
+ return "null";
1957
+ else if (value === UNDEFINED)
1958
+ return "undefined";
1959
+ else if (value === NAN)
1960
+ return "NaN";
1961
+ else if (value === INFINITY)
1962
+ return "Infinity";
1963
+ else if (value === NEGATIVE_INFINITY)
1964
+ return "-Infinity";
1965
+ return false;
1966
+ }
1967
+ function getPropType(type) {
1968
+ if (Array.isArray(type))
1969
+ return type.map((t) => getPropType(t)).join(" or ");
1970
+ if (type == null)
1971
+ return "null";
1972
+ const match = type.toString().match(fnTypeRE);
1973
+ return typeof type === "function" ? match && match[1] || "any" : "any";
1974
+ }
1975
+ function sanitize(data) {
1976
+ if (!isPrimitive(data) && !Array.isArray(data) && !isPlainObject(data)) {
1977
+ return Object.prototype.toString.call(data);
1978
+ } else {
1979
+ return data;
1980
+ }
1981
+ }
1982
+ function getSetupStateType(raw) {
1983
+ return {
1984
+ ref: isRef(raw),
1985
+ computed: isComputed(raw),
1986
+ reactive: isReactive(raw),
1987
+ readonly: isReadOnly(raw)
1988
+ };
1989
+ }
1990
+ function toRaw(value) {
1991
+ if (value == null ? void 0 : value.__v_raw)
1992
+ return value.__v_raw;
1993
+ return value;
1994
+ }
1995
+ function escape(s) {
1996
+ return s.replace(/[<>"&]/g, (s2) => {
1997
+ return ESC[s2] || s2;
1998
+ });
1999
+ }
2000
+
2001
+ // src/core/component/state/format.ts
2002
+ function getInspectorStateValueType(value, raw = true) {
2003
+ const type = typeof value;
2004
+ if (value == null || value === UNDEFINED) {
2005
+ return "null";
2006
+ } else if (type === "boolean" || type === "number" || value === INFINITY || value === NEGATIVE_INFINITY || value === NAN) {
2007
+ return "literal";
2008
+ } else if (value == null ? void 0 : value._custom) {
2009
+ if (raw || value._custom.display != null || value._custom.displayText != null)
2010
+ return "custom";
2011
+ else
2012
+ return getInspectorStateValueType(value._custom.value);
2013
+ } else if (typeof value === "string") {
2014
+ const typeMatch = specialTypeRE.exec(value);
2015
+ if (typeMatch) {
2016
+ const [, type2] = typeMatch;
2017
+ return `native ${type2}`;
2018
+ } else {
2019
+ return "string";
2020
+ }
2021
+ } else if (Array.isArray(value) || (value == null ? void 0 : value._isArray)) {
2022
+ return "array";
2023
+ } else if (isPlainObject(value)) {
2024
+ return "plain-object";
2025
+ } else {
2026
+ return "unknown";
2027
+ }
2028
+ }
2029
+ function formatInspectorStateValue(value, quotes = false) {
2030
+ var _a8, _b8;
2031
+ let result;
2032
+ const type = getInspectorStateValueType(value, false);
2033
+ if (type !== "custom" && (value == null ? void 0 : value._custom))
2034
+ value = value._custom.value;
2035
+ if (result = internalStateTokenToString(value)) {
2036
+ return result;
2037
+ } else if (type === "custom") {
2038
+ return (_a8 = value._custom.displayText) != null ? _a8 : value._custom.display;
2039
+ } else if (type === "array") {
2040
+ return `Array[${value.length}]`;
2041
+ } else if (type === "plain-object") {
2042
+ return `Object${Object.keys(value).length ? "" : " (empty)"}`;
2043
+ } else if (type == null ? void 0 : type.includes("native")) {
2044
+ return escape((_b8 = specialTypeRE.exec(value)) == null ? void 0 : _b8[2]);
2045
+ } else if (typeof value === "string") {
2046
+ const typeMatch = value.match(rawTypeRE);
2047
+ if (typeMatch)
2048
+ value = escape(typeMatch[1]);
2049
+ else if (quotes)
2050
+ value = `<span>"</span>${escape(value)}<span>"</span>`;
2051
+ else
2052
+ value = escape(value);
2053
+ value = value.replace(/ /g, "&nbsp;").replace(/\n/g, "<span>\\n</span>");
2054
+ }
2055
+ return value;
2056
+ }
2057
+
2058
+ // src/core/component/state/replacer.ts
2059
+ init_esm_shims();
2060
+
2061
+ // src/core/component/state/custom.ts
2062
+ init_esm_shims();
2063
+
2064
+ // src/core/component/general/util.ts
2065
+ init_esm_shims();
2066
+ import { basename, classify } from "@vue/devtools-shared";
2067
+ import { Fragment } from "vue";
2068
+ function getComponentTypeName(options) {
2069
+ return options.name || options._componentTag || options.__VUE_DEVTOOLS_COMPONENT_GUSSED_NAME__ || options.__name;
2070
+ }
2071
+ function getComponentFileName(options) {
2072
+ const file = options.__file;
2073
+ if (file)
2074
+ return classify(basename(file, ".vue"));
2075
+ }
2076
+ function getComponentName(options) {
2077
+ const name = options.displayName || options.name || options._componentTag;
2078
+ if (name)
2079
+ return name;
2080
+ return getComponentFileName(options);
2081
+ }
2082
+ function saveComponentGussedName(instance, name) {
2083
+ instance.type.__VUE_DEVTOOLS_COMPONENT_GUSSED_NAME__ = name;
2084
+ return name;
2085
+ }
2086
+ function getAppRecord(instance) {
2087
+ if (instance.__VUE_DEVTOOLS_APP_RECORD__)
2088
+ return instance.__VUE_DEVTOOLS_APP_RECORD__;
2089
+ else if (instance.root)
2090
+ return instance.appContext.app.__VUE_DEVTOOLS_APP_RECORD__;
2091
+ }
2092
+ async function getComponentId(options) {
2093
+ const { app, uid, instance } = options;
2094
+ try {
2095
+ if (instance.__VUE_DEVTOOLS_UID__)
2096
+ return instance.__VUE_DEVTOOLS_UID__;
2097
+ const appRecord = await getAppRecord(app);
2098
+ if (!appRecord)
2099
+ return null;
2100
+ const isRoot = appRecord.rootInstance === instance;
2101
+ return `${appRecord.id}:${isRoot ? "root" : uid}`;
2102
+ } catch (e) {
2103
+ }
2104
+ }
2105
+ function isFragment(instance) {
2106
+ var _a8;
2107
+ const subTreeType = (_a8 = instance.subTree) == null ? void 0 : _a8.type;
2108
+ return subTreeType === Fragment;
2109
+ }
2110
+ function isBeingDestroyed(instance) {
2111
+ return instance._isBeingDestroyed || instance.isUnmounted;
2112
+ }
2113
+ function getInstanceName(instance) {
2114
+ var _a8, _b8, _c;
2115
+ const name = getComponentTypeName(instance.type || {});
2116
+ if (name)
2117
+ return name;
2118
+ if (instance.root === instance)
2119
+ return "Root";
2120
+ for (const key in (_b8 = (_a8 = instance.parent) == null ? void 0 : _a8.type) == null ? void 0 : _b8.components) {
2121
+ if (instance.parent.type.components[key] === instance.type)
2122
+ return saveComponentGussedName(instance, key);
2123
+ }
2124
+ for (const key in (_c = instance.appContext) == null ? void 0 : _c.components) {
2125
+ if (instance.appContext.components[key] === instance.type)
2126
+ return saveComponentGussedName(instance, key);
2127
+ }
2128
+ const fileName = getComponentFileName(instance.type || {});
2129
+ if (fileName)
2130
+ return fileName;
2131
+ return "Anonymous Component";
2132
+ }
2133
+ function getUniqueComponentId(instance) {
2134
+ var _a8, _b8, _c;
2135
+ const appId = (_c = (_b8 = (_a8 = instance == null ? void 0 : instance.appContext) == null ? void 0 : _a8.app) == null ? void 0 : _b8.__VUE_DEVTOOLS_APP_RECORD_ID__) != null ? _c : 0;
2136
+ const instanceId = instance === instance.root ? "root" : instance.uid;
2137
+ return `${appId}:${instanceId}`;
2138
+ }
2139
+ function getRenderKey(value) {
2140
+ if (value == null)
2141
+ return "";
2142
+ if (typeof value === "number")
2143
+ return value;
2144
+ else if (typeof value === "string")
2145
+ return `'${value}'`;
2146
+ else if (Array.isArray(value))
2147
+ return "Array";
2148
+ else
2149
+ return "Object";
2150
+ }
2151
+ function returnError(cb) {
2152
+ try {
2153
+ return cb();
2154
+ } catch (e) {
2155
+ return e;
2156
+ }
2157
+ }
2158
+ function getComponentInstance(appRecord, instanceId) {
2159
+ instanceId = instanceId || `${appRecord.id}:root`;
2160
+ const instance = appRecord.instanceMap.get(instanceId);
2161
+ return instance || appRecord.instanceMap.get(":root");
2162
+ }
2163
+
2164
+ // src/core/component/state/process.ts
2165
+ init_esm_shims();
2166
+ import { camelize } from "@vue/devtools-shared";
2167
+ function mergeOptions(to, from, instance) {
2168
+ if (typeof from === "function")
2169
+ from = from.options;
2170
+ if (!from)
2171
+ return to;
2172
+ const { mixins, extends: extendsOptions } = from;
2173
+ extendsOptions && mergeOptions(to, extendsOptions, instance);
2174
+ mixins && mixins.forEach(
2175
+ (m) => mergeOptions(to, m, instance)
2176
+ );
2177
+ for (const key of ["computed", "inject"]) {
2178
+ if (Object.prototype.hasOwnProperty.call(from, key)) {
2179
+ if (!to[key])
2180
+ to[key] = from[key];
2181
+ else
2182
+ Object.assign(to[key], from[key]);
2183
+ }
2184
+ }
2185
+ return to;
2186
+ }
2187
+ function resolveMergedOptions(instance) {
2188
+ const raw = instance.type;
2189
+ const { mixins, extends: extendsOptions } = raw;
2190
+ const globalMixins = instance.appContext.mixins;
2191
+ if (!globalMixins.length && !mixins && !extendsOptions)
2192
+ return raw;
2193
+ const options = {};
2194
+ globalMixins.forEach((m) => mergeOptions(options, m, instance));
2195
+ mergeOptions(options, raw, instance);
2196
+ return options;
2197
+ }
2198
+ function processProps(instance) {
2199
+ const props = [];
2200
+ const propDefinitions = instance.type.props;
2201
+ for (const key in instance.props) {
2202
+ const propDefinition = propDefinitions ? propDefinitions[key] : null;
2203
+ const camelizeKey = camelize(key);
2204
+ props.push({
2205
+ type: "props",
2206
+ key: camelizeKey,
2207
+ value: returnError(() => instance.props[key]),
2208
+ meta: propDefinition ? {
2209
+ type: propDefinition.type ? getPropType(propDefinition.type) : "any",
2210
+ required: !!propDefinition.required,
2211
+ ...propDefinition.default ? {
2212
+ default: propDefinition.default.toString()
2213
+ } : {}
2214
+ } : { type: "invalid" }
2215
+ });
2216
+ }
2217
+ return props;
2218
+ }
2219
+ function processState(instance) {
2220
+ const type = instance.type;
2221
+ const props = type.props;
2222
+ const getters = type.vuex && type.vuex.getters;
2223
+ const computedDefs = type.computed;
2224
+ const data = {
2225
+ ...instance.data,
2226
+ ...instance.renderContext
2227
+ };
2228
+ return Object.keys(data).filter((key) => !(props && key in props) && !(getters && key in getters) && !(computedDefs && key in computedDefs)).map((key) => ({
2229
+ key,
2230
+ type: "data",
2231
+ value: returnError(() => data[key]),
2232
+ editable: true
2233
+ }));
2234
+ }
2235
+ function getStateTypeAndName(info) {
2236
+ const stateType = info.computed ? "computed" : info.ref ? "ref" : info.reactive ? "reactive" : null;
2237
+ const stateTypeName = stateType ? `${stateType.charAt(0).toUpperCase()}${stateType.slice(1)}` : null;
2238
+ return {
2239
+ stateType,
2240
+ stateTypeName
2241
+ };
2242
+ }
2243
+ function processSetupState(instance) {
2244
+ const raw = instance.devtoolsRawSetupState || {};
2245
+ return Object.keys(instance.setupState).filter((key) => !vueBuiltins.includes(key) && key.split(/(?=[A-Z])/)[0] !== "use").map((key) => {
2246
+ var _a8, _b8, _c, _d;
2247
+ const value = returnError(() => toRaw(instance.setupState[key]));
2248
+ const rawData = raw[key];
2249
+ let result;
2250
+ let isOtherType = typeof value === "function" || typeof (value == null ? void 0 : value.render) === "function" || typeof (value == null ? void 0 : value.__asyncLoader) === "function";
2251
+ if (rawData) {
2252
+ const info = getSetupStateType(rawData);
2253
+ const { stateType, stateTypeName } = getStateTypeAndName(info);
2254
+ const isState = info.ref || info.computed || info.reactive;
2255
+ const raw2 = ((_b8 = (_a8 = rawData.effect) == null ? void 0 : _a8.raw) == null ? void 0 : _b8.toString()) || ((_d = (_c = rawData.effect) == null ? void 0 : _c.fn) == null ? void 0 : _d.toString());
2256
+ if (stateType)
2257
+ isOtherType = false;
2258
+ result = {
2259
+ ...stateType ? { stateType, stateTypeName } : {},
2260
+ ...raw2 ? { raw: raw2 } : {},
2261
+ editable: isState && !info.readonly
2262
+ };
2263
+ }
2264
+ const type = isOtherType ? "setup (other)" : "setup";
2265
+ return {
2266
+ key,
2267
+ value,
2268
+ type,
2269
+ // @ts-expect-error ignore
2270
+ ...result
2271
+ };
2272
+ });
2273
+ }
2274
+ function processComputed(instance, mergedType) {
2275
+ const type = mergedType;
2276
+ const computed = [];
2277
+ const defs = type.computed || {};
2278
+ for (const key in defs) {
2279
+ const def = defs[key];
2280
+ const type2 = typeof def === "function" && def.vuex ? "vuex bindings" : "computed";
2281
+ computed.push({
2282
+ type: type2,
2283
+ key,
2284
+ value: returnError(() => {
2285
+ var _a8;
2286
+ return (_a8 = instance == null ? void 0 : instance.proxy) == null ? void 0 : _a8[key];
2287
+ }),
2288
+ editable: typeof def.set === "function"
2289
+ });
2290
+ }
2291
+ return computed;
2292
+ }
2293
+ function processAttrs(instance) {
2294
+ return Object.keys(instance.attrs).map((key) => ({
2295
+ type: "attrs",
2296
+ key,
2297
+ value: returnError(() => instance.attrs[key])
2298
+ }));
2299
+ }
2300
+ function processProvide(instance) {
2301
+ return Reflect.ownKeys(instance.provides).map((key) => ({
2302
+ type: "provided",
2303
+ key: key.toString(),
2304
+ value: returnError(() => instance.provides[key])
2305
+ }));
2306
+ }
2307
+ function processInject(instance, mergedType) {
2308
+ if (!(mergedType == null ? void 0 : mergedType.inject))
2309
+ return [];
2310
+ let keys = [];
2311
+ let defaultValue;
2312
+ if (Array.isArray(mergedType.inject)) {
2313
+ keys = mergedType.inject.map((key) => ({
2314
+ key,
2315
+ originalKey: key
2316
+ }));
2317
+ } else {
2318
+ keys = Reflect.ownKeys(mergedType.inject).map((key) => {
2319
+ const value = mergedType.inject[key];
2320
+ let originalKey;
2321
+ if (typeof value === "string" || typeof value === "symbol") {
2322
+ originalKey = value;
2323
+ } else {
2324
+ originalKey = value.from;
2325
+ defaultValue = value.default;
2326
+ }
2327
+ return {
2328
+ key,
2329
+ originalKey
2330
+ };
2331
+ });
2332
+ }
2333
+ return keys.map(({ key, originalKey }) => ({
2334
+ type: "injected",
2335
+ key: originalKey && key !== originalKey ? `${originalKey.toString()} \u279E ${key.toString()}` : key.toString(),
2336
+ // eslint-disable-next-line no-prototype-builtins
2337
+ value: returnError(() => instance.ctx.hasOwnProperty(key) ? instance.ctx[key] : instance.provides.hasOwnProperty(originalKey) ? instance.provides[originalKey] : defaultValue)
2338
+ }));
2339
+ }
2340
+ function processRefs(instance) {
2341
+ return Object.keys(instance.refs).map((key) => ({
2342
+ type: "refs",
2343
+ key,
2344
+ value: returnError(() => instance.refs[key])
2345
+ }));
2346
+ }
2347
+ function processEventListeners(instance) {
2348
+ var _a8;
2349
+ const emitsDefinition = instance.type.emits;
2350
+ const declaredEmits = Array.isArray(emitsDefinition) ? emitsDefinition : Object.keys(emitsDefinition != null ? emitsDefinition : {});
2351
+ const keys = Object.keys((_a8 = instance.vnode.props) != null ? _a8 : {});
2352
+ const result = [];
2353
+ for (const key of keys) {
2354
+ const [prefix, ...eventNameParts] = key.split(/(?=[A-Z])/);
2355
+ if (prefix === "on") {
2356
+ const eventName = eventNameParts.join("-").toLowerCase();
2357
+ const isDeclared = declaredEmits.includes(eventName);
2358
+ result.push({
2359
+ type: "event listeners",
2360
+ key: eventName,
2361
+ value: {
2362
+ _custom: {
2363
+ displayText: isDeclared ? "\u2705 Declared" : "\u26A0\uFE0F Not declared",
2364
+ key: isDeclared ? "\u2705 Declared" : "\u26A0\uFE0F Not declared",
2365
+ value: isDeclared ? "\u2705 Declared" : "\u26A0\uFE0F Not declared",
2366
+ tooltipText: !isDeclared ? `The event <code>${eventName}</code> is not declared in the <code>emits</code> option. It will leak into the component's attributes (<code>$attrs</code>).` : null
2367
+ }
2368
+ }
2369
+ });
2370
+ }
2371
+ }
2372
+ return result;
2373
+ }
2374
+ function processInstanceState(instance) {
2375
+ const mergedType = resolveMergedOptions(instance);
2376
+ return processProps(instance).concat(
2377
+ processState(instance),
2378
+ processSetupState(instance),
2379
+ processComputed(instance, mergedType),
2380
+ processAttrs(instance),
2381
+ processProvide(instance),
2382
+ processInject(instance, mergedType),
2383
+ processRefs(instance),
2384
+ processEventListeners(instance)
2385
+ );
2386
+ }
2387
+
2388
+ // src/core/component/state/custom.ts
2389
+ function getFunctionDetails(func) {
2390
+ let string = "";
2391
+ let matches = null;
2392
+ try {
2393
+ string = Function.prototype.toString.call(func);
2394
+ matches = String.prototype.match.call(string, /\([\s\S]*?\)/);
2395
+ } catch (e) {
2396
+ }
2397
+ const match = matches && matches[0];
2398
+ const args = typeof match === "string" ? match : "(?)";
2399
+ const name = typeof func.name === "string" ? func.name : "";
2400
+ return {
2401
+ _custom: {
2402
+ type: "function",
2403
+ displayText: `<span style="opacity:.5;">function</span> ${escape(name)}${args}`,
2404
+ tooltipText: string.trim() ? `<pre>${string}</pre>` : null
2405
+ }
2406
+ };
2407
+ }
2408
+ function getBigIntDetails(val) {
2409
+ const stringifiedBigInt = BigInt.prototype.toString.call(val);
2410
+ return {
2411
+ _custom: {
2412
+ type: "bigint",
2413
+ displayText: `BigInt(${stringifiedBigInt})`,
2414
+ value: stringifiedBigInt
2415
+ }
2416
+ };
2417
+ }
2418
+ function getMapDetails(val) {
2419
+ const list = [];
2420
+ val.forEach(
2421
+ (value, key) => list.push({
2422
+ key,
2423
+ value
2424
+ })
2425
+ );
2426
+ return {
2427
+ _custom: {
2428
+ type: "map",
2429
+ displayText: "Map",
2430
+ value: list,
2431
+ readOnly: true,
2432
+ fields: {
2433
+ abstract: true
2434
+ }
2435
+ }
2436
+ };
2437
+ }
2438
+ function getSetDetails(val) {
2439
+ const list = Array.from(val);
2440
+ return {
2441
+ _custom: {
2442
+ type: "set",
2443
+ displayText: `Set[${list.length}]`,
2444
+ value: list,
2445
+ readOnly: true
2446
+ }
2447
+ };
2448
+ }
2449
+ function getCatchedGetters(store) {
2450
+ const getters = {};
2451
+ const origGetters = store.getters || {};
2452
+ const keys = Object.keys(origGetters);
2453
+ for (let i = 0; i < keys.length; i++) {
2454
+ const key = keys[i];
2455
+ Object.defineProperty(getters, key, {
2456
+ enumerable: true,
2457
+ get: () => {
2458
+ try {
2459
+ return origGetters[key];
2460
+ } catch (e) {
2461
+ return e;
2462
+ }
2463
+ }
2464
+ });
2465
+ }
2466
+ return getters;
2467
+ }
2468
+ function reduceStateList(list) {
2469
+ if (!list.length)
2470
+ return void 0;
2471
+ return list.reduce((map, item) => {
2472
+ const key = item.type || "data";
2473
+ const obj = map[key] = map[key] || {};
2474
+ obj[item.key] = item.value;
2475
+ return map;
2476
+ }, {});
2477
+ }
2478
+ function namedNodeMapToObject(map) {
2479
+ const result = {};
2480
+ const l = map.length;
2481
+ for (let i = 0; i < l; i++) {
2482
+ const node = map.item(i);
2483
+ result[node.name] = node.value;
2484
+ }
2485
+ return result;
2486
+ }
2487
+ function getStoreDetails(store) {
2488
+ return {
2489
+ _custom: {
2490
+ type: "store",
2491
+ displayText: "Store",
2492
+ value: {
2493
+ state: store.state,
2494
+ getters: getCatchedGetters(store)
2495
+ },
2496
+ fields: {
2497
+ abstract: true
2498
+ }
2499
+ }
2500
+ };
2501
+ }
2502
+ function getRouterDetails(router) {
2503
+ return {
2504
+ _custom: {
2505
+ type: "router",
2506
+ displayText: "VueRouter",
2507
+ value: {
2508
+ options: router.options,
2509
+ currentRoute: router.currentRoute
2510
+ },
2511
+ fields: {
2512
+ abstract: true
2513
+ }
2514
+ }
2515
+ };
2516
+ }
2517
+ function getInstanceDetails(instance) {
2518
+ if (instance._)
2519
+ instance = instance._;
2520
+ const state = processInstanceState(instance);
2521
+ return {
2522
+ _custom: {
2523
+ type: "component",
2524
+ id: instance.__VUE_DEVTOOLS_UID__,
2525
+ displayText: getInstanceName(instance),
2526
+ tooltipText: "Component instance",
2527
+ value: reduceStateList(state),
2528
+ fields: {
2529
+ abstract: true
2530
+ }
2531
+ }
2532
+ };
2533
+ }
2534
+ function getComponentDefinitionDetails(definition) {
2535
+ let display = getComponentName(definition);
2536
+ if (display) {
2537
+ if (definition.name && definition.__file)
2538
+ display += ` <span>(${definition.__file})</span>`;
2539
+ } else {
2540
+ display = "<i>Unknown Component</i>";
2541
+ }
2542
+ return {
2543
+ _custom: {
2544
+ type: "component-definition",
2545
+ displayText: display,
2546
+ tooltipText: "Component definition",
2547
+ ...definition.__file ? {
2548
+ file: definition.__file
2549
+ } : {}
2550
+ }
2551
+ };
2552
+ }
2553
+ function getHTMLElementDetails(value) {
2554
+ try {
2555
+ return {
2556
+ _custom: {
2557
+ type: "HTMLElement",
2558
+ displayText: `<span class="opacity-30">&lt;</span><span class="text-blue-500">${value.tagName.toLowerCase()}</span><span class="opacity-30">&gt;</span>`,
2559
+ value: namedNodeMapToObject(value.attributes)
2560
+ }
2561
+ };
2562
+ } catch (e) {
2563
+ return {
2564
+ _custom: {
2565
+ type: "HTMLElement",
2566
+ displayText: `<span class="text-blue-500">${String(value)}</span>`
2567
+ }
2568
+ };
2569
+ }
2570
+ }
2571
+ function getObjectDetails(object) {
2572
+ var _a8, _b8, _c, _d;
2573
+ const info = getSetupStateType(object);
2574
+ const isState = info.ref || info.computed || info.reactive;
2575
+ if (isState) {
2576
+ const stateTypeName = info.computed ? "Computed" : info.ref ? "Ref" : info.reactive ? "Reactive" : null;
2577
+ const value = toRaw(info.reactive ? object : object._value);
2578
+ const raw = ((_b8 = (_a8 = object.effect) == null ? void 0 : _a8.raw) == null ? void 0 : _b8.toString()) || ((_d = (_c = object.effect) == null ? void 0 : _c.fn) == null ? void 0 : _d.toString());
2579
+ return {
2580
+ _custom: {
2581
+ type: stateTypeName == null ? void 0 : stateTypeName.toLowerCase(),
2582
+ stateTypeName,
2583
+ value,
2584
+ ...raw ? { tooltipText: `<span class="font-mono">${raw}</span>` } : {}
2585
+ }
2586
+ };
2587
+ }
2588
+ if (typeof object.__asyncLoader === "function") {
2589
+ return {
2590
+ _custom: {
2591
+ type: "component-definition",
2592
+ display: "Async component definition"
2593
+ }
2594
+ };
2595
+ }
2596
+ }
2597
+
2598
+ // src/core/component/state/replacer.ts
2599
+ function stringifyReplacer(key) {
2600
+ var _a8;
2601
+ if (key === "compilerOptions")
2602
+ return;
2603
+ const val = this[key];
2604
+ const type = typeof val;
2605
+ if (Array.isArray(val)) {
2606
+ const l = val.length;
2607
+ if (l > MAX_ARRAY_SIZE) {
2608
+ return {
2609
+ _isArray: true,
2610
+ length: l,
2611
+ items: val.slice(0, MAX_ARRAY_SIZE)
2612
+ };
2613
+ }
2614
+ return val;
2615
+ } else if (typeof val === "string") {
2616
+ if (val.length > MAX_STRING_SIZE)
2617
+ return `${val.substring(0, MAX_STRING_SIZE)}... (${val.length} total length)`;
2618
+ else
2619
+ return val;
2620
+ } else if (type === "undefined") {
2621
+ return UNDEFINED;
2622
+ } else if (val === Number.POSITIVE_INFINITY) {
2623
+ return INFINITY;
2624
+ } else if (val === Number.NEGATIVE_INFINITY) {
2625
+ return NEGATIVE_INFINITY;
2626
+ } else if (typeof val === "function") {
2627
+ return getFunctionDetails(val);
2628
+ } else if (type === "symbol") {
2629
+ return `[native Symbol ${Symbol.prototype.toString.call(val)}]`;
2630
+ } else if (typeof val === "bigint") {
2631
+ return getBigIntDetails(val);
2632
+ } else if (val !== null && typeof val === "object") {
2633
+ const proto = Object.prototype.toString.call(val);
2634
+ if (proto === "[object Map]") {
2635
+ return getMapDetails(val);
2636
+ } else if (proto === "[object Set]") {
2637
+ return getSetDetails(val);
2638
+ } else if (proto === "[object RegExp]") {
2639
+ return `[native RegExp ${RegExp.prototype.toString.call(val)}]`;
2640
+ } else if (proto === "[object Date]") {
2641
+ return `[native Date ${Date.prototype.toString.call(val)}]`;
2642
+ } else if (proto === "[object Error]") {
2643
+ return `[native Error ${val.message}<>${val.stack}]`;
2644
+ } else if (val.state && val._vm) {
2645
+ return getStoreDetails(val);
2646
+ } else if (val.constructor && val.constructor.name === "VueRouter") {
2647
+ return getRouterDetails(val);
2648
+ } else if (isVueInstance(val)) {
2649
+ return getInstanceDetails(val);
2650
+ } else if (typeof val.render === "function") {
2651
+ return getComponentDefinitionDetails(val);
2652
+ } else if (val.constructor && val.constructor.name === "VNode") {
2653
+ return `[native VNode <${val.tag}>]`;
2654
+ } else if (typeof HTMLElement !== "undefined" && val instanceof HTMLElement) {
2655
+ return getHTMLElementDetails(val);
2656
+ } else if (((_a8 = val.constructor) == null ? void 0 : _a8.name) === "Store" && val._wrappedGetters) {
2657
+ return "[object Store]";
2658
+ } else if (val.currentRoute) {
2659
+ return "[object Router]";
2660
+ }
2661
+ const customDetails = getObjectDetails(val);
2662
+ if (customDetails != null)
2663
+ return customDetails;
2664
+ } else if (Number.isNaN(val)) {
2665
+ return NAN;
2666
+ }
2667
+ return sanitize(val);
2668
+ }
2669
+
2670
+ // src/core/component/state/reviver.ts
2671
+ init_esm_shims();
2672
+ import { target as target2 } from "@vue/devtools-shared";
2673
+ function reviveSet(val) {
2674
+ const result = /* @__PURE__ */ new Set();
2675
+ const list = val._custom.value;
2676
+ for (let i = 0; i < list.length; i++) {
2677
+ const value = list[i];
2678
+ result.add(revive(value));
2679
+ }
2680
+ return result;
2681
+ }
2682
+ function reviveMap(val) {
2683
+ const result = /* @__PURE__ */ new Map();
2684
+ const list = val._custom.value;
2685
+ for (let i = 0; i < list.length; i++) {
2686
+ const { key, value } = list[i];
2687
+ result.set(key, revive(value));
2688
+ }
2689
+ return result;
2690
+ }
2691
+ function revive(val) {
2692
+ var _a8;
2693
+ if (val === UNDEFINED) {
2694
+ return void 0;
2695
+ } else if (val === INFINITY) {
2696
+ return Number.POSITIVE_INFINITY;
2697
+ } else if (val === NEGATIVE_INFINITY) {
2698
+ return Number.NEGATIVE_INFINITY;
2699
+ } else if (val === NAN) {
2700
+ return Number.NaN;
2701
+ } else if (val && val._custom) {
2702
+ const { _custom: custom } = val;
2703
+ if (custom.type === "component")
2704
+ return (_a8 = devtoolsContext.appRecord) == null ? void 0 : _a8.instanceMap.get(custom.id);
2705
+ else if (custom.type === "map")
2706
+ return reviveMap(val);
2707
+ else if (custom.type === "set")
2708
+ return reviveSet(val);
2709
+ else if (custom.type === "bigint")
2710
+ return BigInt(custom.value);
2711
+ else
2712
+ return revive(custom.value);
2713
+ } else if (symbolRE.test(val)) {
2714
+ const [, string] = symbolRE.exec(val);
2715
+ return Symbol.for(string);
2716
+ } else if (specialTypeRE.test(val)) {
2717
+ const [, type, string, , details] = specialTypeRE.exec(val);
2718
+ const result = new target2[type](string);
2719
+ if (type === "Error" && details)
2720
+ result.stack = details;
2721
+ return result;
2722
+ } else {
2723
+ return val;
2724
+ }
2725
+ }
2726
+ function reviver(key, value) {
2727
+ return revive(value);
2728
+ }
2729
+
2730
+ // src/shared/transfer.ts
2731
+ init_esm_shims();
2732
+ var MAX_SERIALIZED_SIZE = 512 * 1024;
2733
+ function encode(data, replacer, list, seen) {
2734
+ let stored, key, value, i, l;
2735
+ const seenIndex = seen.get(data);
2736
+ if (seenIndex != null)
2737
+ return seenIndex;
2738
+ const index = list.length;
2739
+ const proto = Object.prototype.toString.call(data);
2740
+ if (proto === "[object Object]") {
2741
+ stored = {};
2742
+ seen.set(data, index);
2743
+ list.push(stored);
2744
+ const keys = Object.keys(data);
2745
+ for (i = 0, l = keys.length; i < l; i++) {
2746
+ key = keys[i];
2747
+ try {
2748
+ if (key === "compilerOptions")
2749
+ return;
2750
+ value = data[key];
2751
+ if (replacer)
2752
+ value = replacer.call(data, key, value);
2753
+ } catch (e) {
2754
+ value = e;
2755
+ }
2756
+ stored[key] = encode(value, replacer, list, seen);
2757
+ }
2758
+ } else if (proto === "[object Array]") {
2759
+ stored = [];
2760
+ seen.set(data, index);
2761
+ list.push(stored);
2762
+ for (i = 0, l = data.length; i < l; i++) {
2763
+ try {
2764
+ value = data[i];
2765
+ if (replacer)
2766
+ value = replacer.call(data, i, value);
2767
+ } catch (e) {
2768
+ value = e;
2769
+ }
2770
+ stored[i] = encode(value, replacer, list, seen);
2771
+ }
2772
+ } else {
2773
+ list.push(data);
2774
+ }
2775
+ return index;
2776
+ }
2777
+ function decode(list, reviver2 = null) {
2778
+ let i = list.length;
2779
+ let j, k, data, key, value, proto;
2780
+ while (i--) {
2781
+ data = list[i];
2782
+ proto = Object.prototype.toString.call(data);
2783
+ if (proto === "[object Object]") {
2784
+ const keys = Object.keys(data);
2785
+ for (j = 0, k = keys.length; j < k; j++) {
2786
+ key = keys[j];
2787
+ value = list[data[key]];
2788
+ if (reviver2)
2789
+ value = reviver2.call(data, key, value);
2790
+ data[key] = value;
2791
+ }
2792
+ } else if (proto === "[object Array]") {
2793
+ for (j = 0, k = data.length; j < k; j++) {
2794
+ value = list[data[j]];
2795
+ if (reviver2)
2796
+ value = reviver2.call(data, j, value);
2797
+ data[j] = value;
2798
+ }
2799
+ }
2800
+ }
2801
+ }
2802
+ function stringifyCircularAutoChunks(data, replacer = null, space = null) {
2803
+ let result;
2804
+ try {
2805
+ result = arguments.length === 1 ? JSON.stringify(data) : JSON.stringify(data, replacer, space);
2806
+ } catch (e) {
2807
+ result = stringifyStrictCircularAutoChunks(data, replacer, space);
2808
+ }
2809
+ if (result.length > MAX_SERIALIZED_SIZE) {
2810
+ const chunkCount = Math.ceil(result.length / MAX_SERIALIZED_SIZE);
2811
+ const chunks = [];
2812
+ for (let i = 0; i < chunkCount; i++)
2813
+ chunks.push(result.slice(i * MAX_SERIALIZED_SIZE, (i + 1) * MAX_SERIALIZED_SIZE));
2814
+ return chunks;
2815
+ }
2816
+ return result;
2817
+ }
2818
+ function stringifyStrictCircularAutoChunks(data, replacer = null, space = null) {
2819
+ const list = [];
2820
+ encode(data, replacer, list, /* @__PURE__ */ new Map());
2821
+ return space ? ` ${JSON.stringify(list, null, space)}` : ` ${JSON.stringify(list)}`;
2822
+ }
2823
+ function parseCircularAutoChunks(data, reviver2 = null) {
2824
+ if (Array.isArray(data))
2825
+ data = data.join("");
2826
+ const hasCircular = /^\s/.test(data);
2827
+ if (!hasCircular) {
2828
+ return arguments.length === 1 ? JSON.parse(data) : JSON.parse(data, reviver2);
2829
+ } else {
2830
+ const list = JSON.parse(data);
2831
+ decode(list, reviver2);
2832
+ return list[0];
2833
+ }
2834
+ }
2835
+
2836
+ // src/shared/util.ts
2837
+ function stringify(data) {
2838
+ return stringifyCircularAutoChunks(data, stringifyReplacer);
2839
+ }
2840
+ function parse(data, revive2 = false) {
2841
+ if (!data)
2842
+ return {};
2843
+ return revive2 ? parseCircularAutoChunks(data, reviver) : parseCircularAutoChunks(data);
2844
+ }
2845
+
2846
+ // src/shared/time.ts
2847
+ init_esm_shims();
2848
+ function now() {
2849
+ return Date.now();
2850
+ }
2851
+
2852
+ // src/shared/env.ts
2853
+ init_esm_shims();
2854
+
2855
+ // src/core/general/inspector.ts
2856
+ init_esm_shims();
2857
+ function addInspector(payload) {
2858
+ devtoolsContext.inspector.push(payload);
2859
+ }
2860
+ function getInspector(inspectorId) {
2861
+ return devtoolsContext.inspector.find((inspector) => inspector.id === inspectorId);
2862
+ }
2863
+ function updateInspector(inspectorId, payload) {
2864
+ const inspector = getInspector(inspectorId);
2865
+ inspector && Object.assign(inspector, payload);
2866
+ }
2867
+
2868
+ // src/core/timeline/index.ts
2869
+ init_esm_shims();
2870
+ function addTimelineLayer(payload) {
2871
+ devtoolsContext.timelineLayer.push(payload);
2872
+ }
2873
+
2874
+ // src/core/component/state/editor.ts
2875
+ init_esm_shims();
2876
+ import { isReactive as isReactive2, isRef as isRef2 } from "vue";
2877
+
2878
+ // src/core/component/general/index.ts
2879
+ init_esm_shims();
2880
+
2881
+ // src/core/component/state/editor.ts
2882
+ var StateEditor = class {
2883
+ constructor() {
2884
+ this.refEditor = new RefStateEditor();
2885
+ }
2886
+ set(object, path, value, cb) {
2887
+ const sections = Array.isArray(path) ? path : path.split(".");
2888
+ const markRef = false;
2889
+ while (sections.length > 1) {
2890
+ const section = sections.shift();
2891
+ object = object[section];
2892
+ if (this.refEditor.isRef(object))
2893
+ object = this.refEditor.get(object);
2894
+ }
2895
+ const field = sections[0];
2896
+ const item = this.refEditor.get(object)[field];
2897
+ if (cb) {
2898
+ cb(object, field, value);
2899
+ } else {
2900
+ if (this.refEditor.isRef(item))
2901
+ this.refEditor.set(item, value);
2902
+ else if (markRef)
2903
+ object[field] = value;
2904
+ else
2905
+ object[field] = value;
2906
+ }
2907
+ }
2908
+ get(object, path) {
2909
+ const sections = Array.isArray(path) ? path : path.split(".");
2910
+ for (let i = 0; i < sections.length; i++) {
2911
+ object = object[sections[i]];
2912
+ if (this.refEditor.isRef(object))
2913
+ object = this.refEditor.get(object);
2914
+ if (!object)
2915
+ return void 0;
2916
+ }
2917
+ return object;
2918
+ }
2919
+ has(object, path, parent = false) {
2920
+ if (typeof object === "undefined")
2921
+ return false;
2922
+ const sections = Array.isArray(path) ? path.slice() : path.split(".");
2923
+ const size = !parent ? 1 : 2;
2924
+ while (object && sections.length > size) {
2925
+ const section = sections.shift();
2926
+ object = object[section];
2927
+ if (this.refEditor.isRef(object))
2928
+ object = this.refEditor.get(object);
2929
+ }
2930
+ return object != null && Object.prototype.hasOwnProperty.call(object, sections[0]);
2931
+ }
2932
+ createDefaultSetCallback(state) {
2933
+ return (object, field, value) => {
2934
+ if (state.remove || state.newKey) {
2935
+ if (Array.isArray(object))
2936
+ object.splice(field, 1);
2937
+ else
2938
+ Reflect.deleteProperty(object, field);
2939
+ }
2940
+ if (!state.remove) {
2941
+ const target8 = object[state.newKey || field];
2942
+ if (this.refEditor.isRef(target8))
2943
+ this.refEditor.set(target8, value);
2944
+ else
2945
+ object[state.newKey || field] = value;
2946
+ }
2947
+ };
2948
+ }
2949
+ };
2950
+ var RefStateEditor = class {
2951
+ set(ref, value) {
2952
+ if (isRef2(ref)) {
2953
+ ref.value = value;
2954
+ } else {
2955
+ const obj = JSON.parse(value);
2956
+ const previousKeys = Object.keys(ref);
2957
+ const currentKeys = Object.keys(obj);
2958
+ if (previousKeys.length > currentKeys.length) {
2959
+ const diffKeys = previousKeys.filter((key) => !currentKeys.includes(key));
2960
+ diffKeys.forEach((key) => Reflect.deleteProperty(ref, key));
2961
+ }
2962
+ currentKeys.forEach((key) => {
2963
+ Reflect.set(ref, key, Reflect.get(obj, key));
2964
+ });
2965
+ }
2966
+ }
2967
+ get(ref) {
2968
+ return isRef2(ref) ? ref.value : ref;
2969
+ }
2970
+ isRef(ref) {
2971
+ return isRef2(ref) || isReactive2(ref);
2972
+ }
2973
+ };
2974
+ async function editComponentState(payload, stateEditor2) {
2975
+ const { path, nodeId, state, type } = payload;
2976
+ const instance = getComponentInstance(devtoolsContext.appRecord, nodeId);
2977
+ if (!instance)
2978
+ return;
2979
+ const targetPath = path.slice();
2980
+ let target8;
2981
+ if (instance.devtoolsRawSetupState && Object.keys(instance.devtoolsRawSetupState).includes(path[0])) {
2982
+ target8 = instance.devtoolsRawSetupState;
2983
+ }
2984
+ if (target8 && targetPath) {
2985
+ if (state.type === "object" && type === "reactive") {
2986
+ }
2987
+ stateEditor2.set(target8, targetPath, state.value, stateEditor2.createDefaultSetCallback(state));
2988
+ }
2989
+ }
2990
+ var stateEditor = new StateEditor();
2991
+ async function editState(payload) {
2992
+ editComponentState(payload, stateEditor);
2993
+ }
2994
+
2995
+ // src/core/open-in-editor/index.ts
2996
+ init_esm_shims();
2997
+ import { target as target3 } from "@vue/devtools-shared";
2998
+ function openInEditor(options = {}) {
2999
+ const { file, line = 0, column = 0 } = options;
3000
+ if (file) {
3001
+ const baseUrl = window.location.origin;
3002
+ if (target3.__VUE_DEVTOOLS_VITE_PLUGIN_DETECTED__) {
3003
+ target3.__VUE_INSPECTOR__.openInEditor(baseUrl, file, line, column);
3004
+ } else {
3005
+ }
3006
+ }
3007
+ }
3008
+
3009
+ // src/core/general/app-record.ts
3010
+ init_esm_shims();
3011
+
3012
+ // src/core/plugins/index.ts
3013
+ init_esm_shims();
3014
+
3015
+ // src/core/plugins/components.ts
3016
+ init_esm_shims();
3017
+
3018
+ // src/api/plugin.ts
3019
+ init_esm_shims();
3020
+ import { DevToolsHooks as DevToolsHooks2 } from "@vue/devtools-schema";
3021
+ function collectRegisteredPlugin(pluginDescriptor, setupFn) {
3022
+ devtoolsState.pluginBuffer.push([pluginDescriptor, setupFn]);
3023
+ }
3024
+ async function registerPlugin(options) {
3025
+ const { app, api } = options;
3026
+ const plugins = devtoolsState.pluginBuffer.filter(([plugin]) => plugin.app === app);
3027
+ plugins.forEach(async ([plugin, setupFn]) => {
3028
+ const appRecord = await getAppRecord(plugin.app);
3029
+ if (plugin.packageName === "vue-router") {
3030
+ const id = getRouterDevToolsId(`${plugin.id}`);
3031
+ if (plugin.app === app) {
3032
+ devtoolsState.appRecords = devtoolsState.appRecords.map((item) => ({
3033
+ ...item,
3034
+ routerId: id
3035
+ }));
3036
+ }
3037
+ }
3038
+ setupFn(api);
3039
+ });
3040
+ devtoolsState.appRecords = devtoolsState.appRecords.map((record) => {
3041
+ var _a8, _b8;
3042
+ const globalProperties = (_b8 = (_a8 = record.app) == null ? void 0 : _a8.config) == null ? void 0 : _b8.globalProperties;
3043
+ if (!globalProperties)
3044
+ return record;
3045
+ return {
3046
+ ...record,
3047
+ moduleDetectives: {
3048
+ vueRouter: !!globalProperties.$router,
3049
+ pinia: !!globalProperties.$pinia
3050
+ }
3051
+ };
3052
+ });
3053
+ }
3054
+ function setupDevToolsPlugin(pluginDescriptor, setupFn) {
3055
+ return devtoolsHooks.callHook(DevToolsHooks2.SETUP_DEVTOOLS_PLUGIN, pluginDescriptor, setupFn);
3056
+ }
3057
+
3058
+ // src/core/component/tree/walker.ts
3059
+ init_esm_shims();
3060
+
3061
+ // src/core/component/tree/el.ts
3062
+ init_esm_shims();
3063
+ function getRootElementsFromComponentInstance(instance) {
3064
+ if (isFragment(instance))
3065
+ return getFragmentRootElements(instance.subTree);
3066
+ if (!instance.subTree)
3067
+ return [];
3068
+ return [instance.subTree.el];
3069
+ }
3070
+ function getFragmentRootElements(vnode) {
3071
+ if (!vnode.children)
3072
+ return [];
3073
+ const list = [];
3074
+ vnode.children.forEach((childVnode) => {
3075
+ if (childVnode.component)
3076
+ list.push(...getRootElementsFromComponentInstance(childVnode.component));
3077
+ else if (childVnode == null ? void 0 : childVnode.el)
3078
+ list.push(childVnode.el);
3079
+ });
3080
+ return list;
3081
+ }
3082
+
3083
+ // src/core/component/tree/filter.ts
3084
+ init_esm_shims();
3085
+ import { classify as classify2, kebabize } from "@vue/devtools-shared";
3086
+ var ComponentFilter = class {
3087
+ constructor(filter) {
3088
+ this.filter = filter || "";
3089
+ }
3090
+ /**
3091
+ * Check if an instance is qualified.
3092
+ *
3093
+ * @param {Vue|Vnode} instance
3094
+ * @return {boolean}
3095
+ */
3096
+ isQualified(instance) {
3097
+ const name = getInstanceName(instance);
3098
+ return classify2(name).toLowerCase().includes(this.filter) || kebabize(name).toLowerCase().includes(this.filter);
3099
+ }
3100
+ };
3101
+ function createComponentFilter(filterText) {
3102
+ return new ComponentFilter(filterText);
3103
+ }
3104
+
3105
+ // src/core/component/tree/walker.ts
3106
+ var ComponentWalker = class {
3107
+ constructor(options) {
3108
+ // Dedupe instances (Some instances may be both on a component and on a child abstract/functional component)
3109
+ this.captureIds = /* @__PURE__ */ new Map();
3110
+ const { filterText = "", maxDepth, recursively } = options;
3111
+ this.componentFilter = createComponentFilter(filterText);
3112
+ this.maxDepth = maxDepth;
3113
+ this.recursively = recursively;
3114
+ }
3115
+ getComponentTree(instance) {
3116
+ this.captureIds = /* @__PURE__ */ new Map();
3117
+ return this.findQualifiedChildren(instance, 0);
3118
+ }
3119
+ getComponentParents(instance) {
3120
+ this.captureIds = /* @__PURE__ */ new Map();
3121
+ const parents = [];
3122
+ this.captureId(instance);
3123
+ let parent = instance;
3124
+ while (parent = parent.parent) {
3125
+ this.captureId(parent);
3126
+ parents.push(parent);
3127
+ }
3128
+ return parents;
3129
+ }
3130
+ captureId(instance) {
3131
+ if (!instance)
3132
+ return null;
3133
+ const id = instance.__VUE_DEVTOOLS_UID__ != null ? instance.__VUE_DEVTOOLS_UID__ : getUniqueComponentId(instance);
3134
+ instance.__VUE_DEVTOOLS_UID__ = id;
3135
+ if (this.captureIds.has(id))
3136
+ return null;
3137
+ else
3138
+ this.captureIds.set(id, void 0);
3139
+ this.mark(instance);
3140
+ return id;
3141
+ }
3142
+ /**
3143
+ * Capture the meta information of an instance. (recursive)
3144
+ *
3145
+ * @param {Vue} instance
3146
+ * @return {object}
3147
+ */
3148
+ async capture(instance, depth) {
3149
+ var _a8;
3150
+ if (!instance)
3151
+ return null;
3152
+ const id = this.captureId(instance);
3153
+ const name = getInstanceName(instance);
3154
+ const children = this.getInternalInstanceChildren(instance.subTree).filter((child) => !isBeingDestroyed(child));
3155
+ const parents = this.getComponentParents(instance) || [];
3156
+ const inactive = !!instance.isDeactivated || parents.some((parent) => parent.isDeactivated);
3157
+ const treeNode = {
3158
+ uid: instance.uid,
3159
+ id,
3160
+ name,
3161
+ renderKey: getRenderKey(instance.vnode ? instance.vnode.key : null),
3162
+ inactive,
3163
+ children: [],
3164
+ isFragment: isFragment(instance),
3165
+ tags: typeof instance.type !== "function" ? [] : [
3166
+ {
3167
+ label: "functional",
3168
+ textColor: 5592405,
3169
+ backgroundColor: 15658734
3170
+ }
3171
+ ],
3172
+ autoOpen: this.recursively,
3173
+ file: instance.type.__file || ""
3174
+ };
3175
+ if (depth < this.maxDepth || instance.type.__isKeepAlive || parents.some((parent) => parent.type.__isKeepAlive)) {
3176
+ treeNode.children = await Promise.all(children.map((child) => this.capture(child, depth + 1)).filter(Boolean));
3177
+ }
3178
+ if (this.isKeepAlive(instance)) {
3179
+ const cachedComponents = this.getKeepAliveCachedInstances(instance);
3180
+ const childrenIds = children.map((child) => child.__VUE_DEVTOOLS_UID__);
3181
+ for (const cachedChild of cachedComponents) {
3182
+ if (!childrenIds.includes(cachedChild.__VUE_DEVTOOLS_UID__)) {
3183
+ const node = await this.capture({ ...cachedChild, isDeactivated: true }, depth + 1);
3184
+ if (node)
3185
+ treeNode.children.push(node);
3186
+ }
3187
+ }
3188
+ }
3189
+ const rootElements = getRootElementsFromComponentInstance(instance);
3190
+ const firstElement = rootElements[0];
3191
+ if (firstElement == null ? void 0 : firstElement.parentElement) {
3192
+ const parentInstance = instance.parent;
3193
+ const parentRootElements = parentInstance ? getRootElementsFromComponentInstance(parentInstance) : [];
3194
+ let el = firstElement;
3195
+ const indexList = [];
3196
+ do {
3197
+ indexList.push(Array.from(el.parentElement.childNodes).indexOf(el));
3198
+ el = el.parentElement;
3199
+ } while (el.parentElement && parentRootElements.length && !parentRootElements.includes(el));
3200
+ treeNode.domOrder = indexList.reverse();
3201
+ } else {
3202
+ treeNode.domOrder = [-1];
3203
+ }
3204
+ if ((_a8 = instance.suspense) == null ? void 0 : _a8.suspenseKey) {
3205
+ treeNode.tags.push({
3206
+ label: instance.suspense.suspenseKey,
3207
+ backgroundColor: 14979812,
3208
+ textColor: 16777215
3209
+ });
3210
+ this.mark(instance, true);
3211
+ }
3212
+ devtoolsContext.api.visitComponentTree({
3213
+ treeNode,
3214
+ componentInstance: instance,
3215
+ app: instance.appContext.app,
3216
+ filter: this.componentFilter.filter
3217
+ });
3218
+ return treeNode;
3219
+ }
3220
+ /**
3221
+ * Find qualified children from a single instance.
3222
+ * If the instance itself is qualified, just return itself.
3223
+ * This is ok because [].concat works in both cases.
3224
+ *
3225
+ * @param {Vue|Vnode} instance
3226
+ * @return {Vue|Array}
3227
+ */
3228
+ async findQualifiedChildren(instance, depth) {
3229
+ var _a8;
3230
+ if (this.componentFilter.isQualified(instance) && !((_a8 = instance.type.devtools) == null ? void 0 : _a8.hide)) {
3231
+ return [await this.capture(instance, depth)];
3232
+ } else if (instance.subTree) {
3233
+ const list = this.isKeepAlive(instance) ? this.getKeepAliveCachedInstances(instance) : this.getInternalInstanceChildren(instance.subTree);
3234
+ return this.findQualifiedChildrenFromList(list, depth);
3235
+ } else {
3236
+ return [];
3237
+ }
3238
+ }
3239
+ /**
3240
+ * Iterate through an array of instances and flatten it into
3241
+ * an array of qualified instances. This is a depth-first
3242
+ * traversal - e.g. if an instance is not matched, we will
3243
+ * recursively go deeper until a qualified child is found.
3244
+ *
3245
+ * @param {Array} instances
3246
+ * @return {Array}
3247
+ */
3248
+ async findQualifiedChildrenFromList(instances, depth) {
3249
+ instances = instances.filter((child) => {
3250
+ var _a8;
3251
+ return !isBeingDestroyed(child) && !((_a8 = child.type.devtools) == null ? void 0 : _a8.hide);
3252
+ });
3253
+ if (!this.componentFilter.filter)
3254
+ return Promise.all(instances.map((child) => this.capture(child, depth)));
3255
+ else
3256
+ return Array.prototype.concat.apply([], await Promise.all(instances.map((i) => this.findQualifiedChildren(i, depth))));
3257
+ }
3258
+ /**
3259
+ * Get children from a component instance.
3260
+ */
3261
+ getInternalInstanceChildren(subTree, suspense = null) {
3262
+ const list = [];
3263
+ if (subTree) {
3264
+ if (subTree.component) {
3265
+ !suspense ? list.push(subTree.component) : list.push({ ...subTree.component, suspense });
3266
+ } else if (subTree.suspense) {
3267
+ const suspenseKey = !subTree.suspense.isInFallback ? "suspense default" : "suspense fallback";
3268
+ list.push(...this.getInternalInstanceChildren(subTree.suspense.activeBranch, { ...subTree.suspense, suspenseKey }));
3269
+ } else if (Array.isArray(subTree.children)) {
3270
+ subTree.children.forEach((childSubTree) => {
3271
+ if (childSubTree.component)
3272
+ !suspense ? list.push(childSubTree.component) : list.push({ ...childSubTree.component, suspense });
3273
+ else
3274
+ list.push(...this.getInternalInstanceChildren(childSubTree, suspense));
3275
+ });
3276
+ }
3277
+ }
3278
+ return list.filter((child) => {
3279
+ var _a8;
3280
+ return !isBeingDestroyed(child) && !((_a8 = child.type.devtools) == null ? void 0 : _a8.hide);
3281
+ });
3282
+ }
3283
+ /**
3284
+ * Mark an instance as captured and store it in the instance map.
3285
+ *
3286
+ * @param {Vue} instance
3287
+ */
3288
+ mark(instance, force = false) {
3289
+ const instanceMap = getAppRecord(instance).instanceMap;
3290
+ if (force || !instanceMap.has(instance.__VUE_DEVTOOLS_UID__))
3291
+ instanceMap.set(instance.__VUE_DEVTOOLS_UID__, instance);
3292
+ }
3293
+ isKeepAlive(instance) {
3294
+ return instance.type.__isKeepAlive && instance.__v_cache;
3295
+ }
3296
+ getKeepAliveCachedInstances(instance) {
3297
+ return Array.from(instance.__v_cache.values()).map((vnode) => vnode.component).filter(Boolean);
3298
+ }
3299
+ };
3300
+
3301
+ // src/core/component/state/index.ts
3302
+ init_esm_shims();
3303
+ function getInstanceState(params) {
3304
+ var _a8;
3305
+ const instance = getComponentInstance(devtoolsContext.appRecord, params.instanceId);
3306
+ const id = getUniqueComponentId(instance);
3307
+ const name = getInstanceName(instance);
3308
+ const file = (_a8 = instance == null ? void 0 : instance.type) == null ? void 0 : _a8.__file;
3309
+ const state = processInstanceState(instance);
3310
+ return {
3311
+ id,
3312
+ name,
3313
+ file,
3314
+ state,
3315
+ instance
3316
+ };
3317
+ }
3318
+
3319
+ // src/core/component/state/bounding-rect.ts
3320
+ init_esm_shims();
3321
+ function createRect() {
3322
+ const rect = {
3323
+ top: 0,
3324
+ bottom: 0,
3325
+ left: 0,
3326
+ right: 0,
3327
+ get width() {
3328
+ return rect.right - rect.left;
3329
+ },
3330
+ get height() {
3331
+ return rect.bottom - rect.top;
3332
+ }
3333
+ };
3334
+ return rect;
3335
+ }
3336
+ var range;
3337
+ function getTextRect(node) {
3338
+ if (!range)
3339
+ range = document.createRange();
3340
+ range.selectNode(node);
3341
+ return range.getBoundingClientRect();
3342
+ }
3343
+ function getFragmentRect(vnode) {
3344
+ const rect = createRect();
3345
+ if (!vnode.children)
3346
+ return rect;
3347
+ for (let i = 0, l = vnode.children.length; i < l; i++) {
3348
+ const childVnode = vnode.children[i];
3349
+ let childRect;
3350
+ if (childVnode.component) {
3351
+ childRect = getComponentBoundingRect(childVnode.component);
3352
+ } else if (childVnode.el) {
3353
+ const el = childVnode.el;
3354
+ if (el.nodeType === 1 || el.getBoundingClientRect)
3355
+ childRect = el.getBoundingClientRect();
3356
+ else if (el.nodeType === 3 && el.data.trim())
3357
+ childRect = getTextRect(el);
3358
+ }
3359
+ if (childRect)
3360
+ mergeRects(rect, childRect);
3361
+ }
3362
+ return rect;
3363
+ }
3364
+ function mergeRects(a, b) {
3365
+ if (!a.top || b.top < a.top)
3366
+ a.top = b.top;
3367
+ if (!a.bottom || b.bottom > a.bottom)
3368
+ a.bottom = b.bottom;
3369
+ if (!a.left || b.left < a.left)
3370
+ a.left = b.left;
3371
+ if (!a.right || b.right > a.right)
3372
+ a.right = b.right;
3373
+ return a;
3374
+ }
3375
+ var DEFAULT_RECT = {
3376
+ top: 0,
3377
+ left: 0,
3378
+ right: 0,
3379
+ bottom: 0,
3380
+ width: 0,
3381
+ height: 0
3382
+ };
3383
+ function getComponentBoundingRect(instance) {
3384
+ const el = instance.subTree.el;
3385
+ if (typeof window === "undefined") {
3386
+ return DEFAULT_RECT;
3387
+ }
3388
+ if (isFragment(instance))
3389
+ return getFragmentRect(instance.subTree);
3390
+ else if ((el == null ? void 0 : el.nodeType) === 1)
3391
+ return el == null ? void 0 : el.getBoundingClientRect();
3392
+ else if (instance.subTree.component)
3393
+ return getComponentBoundingRect(instance.subTree.component);
3394
+ else
3395
+ return DEFAULT_RECT;
3396
+ }
3397
+
3398
+ // src/api/on.ts
3399
+ init_esm_shims();
3400
+ import { target as target4 } from "@vue/devtools-shared";
3401
+ import { createHooks as createHooks2 } from "hookable";
3402
+ var _a6, _b6;
3403
+ var apiHooks = (_b6 = (_a6 = target4).__VUE_DEVTOOLS_API_HOOK) != null ? _b6 : _a6.__VUE_DEVTOOLS_API_HOOK = createHooks2();
3404
+ var on2 = {
3405
+ devtoolsStateUpdated(fn) {
3406
+ apiHooks.hook("devtools:state-updated" /* DEVTOOLS_STATE_UPDATED */, fn);
3407
+ },
3408
+ routerInfoUpdated(fn) {
3409
+ apiHooks.hook("router-info:updated" /* ROUTER_INFO_UPDATED */, fn);
3410
+ },
3411
+ getComponentBoundingRect(fn) {
3412
+ apiHooks.hook("component-bounding-rect:get" /* GET_COMPONENT_BOUNDING_RECT */, fn);
3413
+ },
3414
+ // compatible
3415
+ inspectComponent(fn) {
3416
+ apiHooks.hook("component-state:inspect" /* COMPONENT_STATE_INSPECT */, fn);
3417
+ },
3418
+ visitComponentTree(fn) {
3419
+ apiHooks.hook("component-tree:visit" /* VISIT_COMPONENT_TREE */, fn);
3420
+ },
3421
+ getInspectorTree(fn) {
3422
+ apiHooks.hook("inspector-tree:get" /* GET_INSPECTOR_TREE */, fn);
3423
+ },
3424
+ getInspectorState(fn) {
3425
+ apiHooks.hook("inspector-state:get" /* GET_INSPECTOR_STATE */, fn);
3426
+ },
3427
+ // private
3428
+ sendInspectorTree(fn) {
3429
+ apiHooks.hook("inspector-tree:send" /* SEND_INSPECTOR_TREE */, fn);
3430
+ },
3431
+ sendInspectorState(fn) {
3432
+ apiHooks.hook("inspector-state:send" /* SEND_INSPECTOR_STATE */, fn);
3433
+ },
3434
+ addTimelineEvent(fn) {
3435
+ apiHooks.hook("timeline:add-event" /* ADD_TIMELINE_EVENT */, fn);
3436
+ },
3437
+ editInspectorState(fn) {
3438
+ apiHooks.hook("inspector-state:edit" /* EDIT_INSPECTOR_STATE */, fn);
3439
+ },
3440
+ editComponentState() {
3441
+ },
3442
+ customTabsUpdated(fn) {
3443
+ apiHooks.hook("custom-tabs:updated" /* CUSTOM_TABS_UPDATED */, fn);
3444
+ },
3445
+ customCommandsUpdated(fn) {
3446
+ apiHooks.hook("custom-commands:updated" /* CUSTOM_COMMANDS_UPDATED */, fn);
3447
+ }
3448
+ };
3449
+
3450
+ // src/core/plugins/components.ts
3451
+ var INSPECTOR_ID = "components";
3452
+ function registerComponentsDevTools(app) {
3453
+ setupDevToolsPlugin({
3454
+ id: INSPECTOR_ID,
3455
+ label: "Components",
3456
+ app
3457
+ }, (api) => {
3458
+ api.addInspector({
3459
+ id: INSPECTOR_ID,
3460
+ label: "Components",
3461
+ treeFilterPlaceholder: "Search components"
3462
+ });
3463
+ api.on.getComponentBoundingRect((payload) => {
3464
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
3465
+ const instance = getComponentInstance(devtoolsContext.appRecord, payload.instanceId);
3466
+ if (instance) {
3467
+ payload.rect = getComponentBoundingRect(instance);
3468
+ if (payload.rect instanceof DOMRect) {
3469
+ payload.rect = {
3470
+ top: payload.rect.top,
3471
+ left: payload.rect.left,
3472
+ right: payload.rect.right,
3473
+ bottom: payload.rect.bottom,
3474
+ width: payload.rect.width,
3475
+ height: payload.rect.height
3476
+ };
3477
+ }
3478
+ }
3479
+ }
3480
+ });
3481
+ api.on.getInspectorTree(async (payload) => {
3482
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
3483
+ const instance = getComponentInstance(devtoolsContext.appRecord, payload.instanceId);
3484
+ if (instance) {
3485
+ const walker = new ComponentWalker({
3486
+ filterText: payload.filter,
3487
+ // @TODO: should make this configurable?
3488
+ maxDepth: 100,
3489
+ recursively: false
3490
+ });
3491
+ payload.rootNodes = await walker.getComponentTree(instance);
3492
+ }
3493
+ }
3494
+ });
3495
+ api.on.getInspectorState(async (payload) => {
3496
+ var _a8;
3497
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
3498
+ const result = getInstanceState({
3499
+ instanceId: payload.nodeId
3500
+ });
3501
+ const componentInstance = result.instance;
3502
+ const app2 = (_a8 = result.instance) == null ? void 0 : _a8.appContext.app;
3503
+ const _payload = {
3504
+ componentInstance,
3505
+ app: app2,
3506
+ instanceData: result
3507
+ };
3508
+ apiHooks.callHookWith((callbacks) => {
3509
+ callbacks.forEach((cb) => cb(_payload));
3510
+ }, "component-state:inspect" /* COMPONENT_STATE_INSPECT */);
3511
+ payload.state = result;
3512
+ }
3513
+ });
3514
+ api.on.editInspectorState(async (payload) => {
3515
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
3516
+ editState(payload);
3517
+ await api.sendInspectorState("components");
3518
+ }
3519
+ });
3520
+ const componentAddedCleanup = hook.on.componentAdded(async (app2, uid, parentUid, component) => {
3521
+ var _a8, _b8, _c;
3522
+ if ((_c = (_b8 = (_a8 = app2 == null ? void 0 : app2._instance) == null ? void 0 : _a8.type) == null ? void 0 : _b8.devtools) == null ? void 0 : _c.hide)
3523
+ return;
3524
+ if (!app2 || typeof uid !== "number" && !uid || !component)
3525
+ return;
3526
+ const id = await getComponentId({
3527
+ app: app2,
3528
+ uid,
3529
+ instance: component
3530
+ });
3531
+ const appRecord = await getAppRecord(app2);
3532
+ if (component) {
3533
+ if (component.__VUE_DEVTOOLS_UID__ == null)
3534
+ component.__VUE_DEVTOOLS_UID__ = id;
3535
+ if (!(appRecord == null ? void 0 : appRecord.instanceMap.has(id)))
3536
+ appRecord == null ? void 0 : appRecord.instanceMap.set(id, component);
3537
+ }
3538
+ if (!appRecord)
3539
+ return;
3540
+ api.sendInspectorTree(INSPECTOR_ID);
3541
+ });
3542
+ const componentUpdatedCleanup = hook.on.componentUpdated(async (app2, uid, parentUid, component) => {
3543
+ var _a8, _b8, _c;
3544
+ if ((_c = (_b8 = (_a8 = app2 == null ? void 0 : app2._instance) == null ? void 0 : _a8.type) == null ? void 0 : _b8.devtools) == null ? void 0 : _c.hide)
3545
+ return;
3546
+ if (!app2 || typeof uid !== "number" && !uid || !component)
3547
+ return;
3548
+ const id = await getComponentId({
3549
+ app: app2,
3550
+ uid,
3551
+ instance: component
3552
+ });
3553
+ const appRecord = await getAppRecord(app2);
3554
+ if (component) {
3555
+ if (component.__VUE_DEVTOOLS_UID__ == null)
3556
+ component.__VUE_DEVTOOLS_UID__ = id;
3557
+ if (!(appRecord == null ? void 0 : appRecord.instanceMap.has(id)))
3558
+ appRecord == null ? void 0 : appRecord.instanceMap.set(id, component);
3559
+ }
3560
+ if (!appRecord)
3561
+ return;
3562
+ api.sendInspectorTree(INSPECTOR_ID);
3563
+ api.sendInspectorState(INSPECTOR_ID);
3564
+ });
3565
+ const componentRemovedCleanup = hook.on.componentRemoved(async (app2, uid, parentUid, component) => {
3566
+ var _a8, _b8, _c;
3567
+ if ((_c = (_b8 = (_a8 = app2 == null ? void 0 : app2._instance) == null ? void 0 : _a8.type) == null ? void 0 : _b8.devtools) == null ? void 0 : _c.hide)
3568
+ return;
3569
+ if (!app2 || typeof uid !== "number" && !uid || !component)
3570
+ return;
3571
+ const appRecord = await getAppRecord(app2);
3572
+ if (!appRecord)
3573
+ return;
3574
+ const id = await getComponentId({
3575
+ app: app2,
3576
+ uid,
3577
+ instance: component
3578
+ });
3579
+ appRecord == null ? void 0 : appRecord.instanceMap.delete(id);
3580
+ api.sendInspectorTree(INSPECTOR_ID);
3581
+ });
3582
+ devtoolsContext.componentPluginHookBuffer = [
3583
+ componentAddedCleanup,
3584
+ componentUpdatedCleanup,
3585
+ componentRemovedCleanup
3586
+ ];
3587
+ });
3588
+ }
3589
+
3590
+ // src/core/general/app-record.ts
3591
+ async function setActiveAppRecord(appRecord) {
3592
+ await registerComponentsDevTools(appRecord.app);
3593
+ devtoolsState.activeAppRecord = appRecord;
3594
+ devtoolsState.activeAppRecordId = `${appRecord.id}`;
3595
+ registerPlugin({
3596
+ app: appRecord.app,
3597
+ api: appRecord.api
3598
+ });
3599
+ }
3600
+ async function toggleAppRecord(id) {
3601
+ devtoolsContext.componentPluginHookBuffer.forEach((cleanup) => cleanup());
3602
+ devtoolsContext.api.clear();
3603
+ devtoolsContext.clear();
3604
+ const appRecord = devtoolsState.appRecords.find((record) => record.id === id);
3605
+ if (appRecord) {
3606
+ devtoolsState.pluginBuffer = devtoolsState.pluginBuffer.filter(([plugin]) => plugin.id !== "components");
3607
+ const api = new DevToolsPluginApi();
3608
+ appRecord.api = api;
3609
+ setActiveAppRecord(appRecord);
3610
+ window.postMessage({
3611
+ event: "toggle-app-record",
3612
+ target: "vue-devtools"
3613
+ });
3614
+ }
3615
+ }
3616
+
3617
+ // src/core/custom-tab/index.ts
3618
+ init_esm_shims();
3619
+ function addCustomTab(tab) {
3620
+ if (devtoolsState.tabs.some((t) => t.name === tab.name))
3621
+ return;
3622
+ devtoolsState.tabs.push(tab);
3623
+ }
3624
+
3625
+ // src/core/custom-command/index.ts
3626
+ init_esm_shims();
3627
+ function addCustomCommand(action) {
3628
+ if (devtoolsState.commands.some((t) => t.id === action.id))
3629
+ return;
3630
+ devtoolsState.commands.push(action);
3631
+ }
3632
+ function removeCustomCommand(actionId) {
3633
+ const index = devtoolsState.commands.findIndex((t) => t.id === actionId);
3634
+ if (index === -1)
3635
+ return;
3636
+ devtoolsState.commands.splice(index, 1);
3637
+ }
3638
+
3639
+ // src/core/vue-inspector/index.ts
3640
+ init_esm_shims();
3641
+ import { target as target5 } from "@vue/devtools-shared";
3642
+ function waitForInspectorInit(cb) {
3643
+ let total = 0;
3644
+ const timer = setInterval(() => {
3645
+ if (target5.__VUE_INSPECTOR__) {
3646
+ clearInterval(timer);
3647
+ total += 30;
3648
+ cb();
3649
+ }
3650
+ if (total >= /* 5s */
3651
+ 5e3)
3652
+ clearInterval(timer);
3653
+ }, 30);
3654
+ }
3655
+ function setupInspector() {
3656
+ const inspector = target5.__VUE_INSPECTOR__;
3657
+ const _openInEditor = inspector.openInEditor;
3658
+ inspector.openInEditor = async (...params) => {
3659
+ inspector.disable();
3660
+ _openInEditor(...params);
3661
+ };
3662
+ }
3663
+ function getVueInspector() {
3664
+ return new Promise((resolve) => {
3665
+ function setup() {
3666
+ setupInspector();
3667
+ resolve(target5.__VUE_INSPECTOR__);
3668
+ }
3669
+ if (!target5.__VUE_INSPECTOR__) {
3670
+ waitForInspectorInit(() => {
3671
+ setup();
3672
+ });
3673
+ } else {
3674
+ setup();
3675
+ }
3676
+ });
3677
+ }
3678
+
3679
+ // src/core/component-inspector/index.ts
3680
+ init_esm_shims();
3681
+ var CONTAINER_ELEMENT_ID = "__vue-devtools-component-inspector__";
3682
+ var CARD_ELEMENT_ID = "__vue-devtools-component-inspector__card__";
3683
+ var COMPONENT_NAME_ELEMENT_ID = "__vue-devtools-component-inspector__name__";
3684
+ var INDICATOR_ELEMENT_ID = "__vue-devtools-component-inspector__indicator__";
3685
+ var containerStyles = {
3686
+ display: "block",
3687
+ zIndex: 2147483640,
3688
+ position: "fixed",
3689
+ backgroundColor: "#42b88325",
3690
+ border: "1px solid #42b88350",
3691
+ borderRadius: "5px",
3692
+ transition: "all 0.1s ease-in",
3693
+ pointerEvents: "none"
3694
+ };
3695
+ var cardStyles = {
3696
+ fontFamily: "Arial, Helvetica, sans-serif",
3697
+ padding: "5px 8px",
3698
+ borderRadius: "4px",
3699
+ textAlign: "left",
3700
+ position: "absolute",
3701
+ left: 0,
3702
+ color: "#e9e9e9",
3703
+ fontSize: "14px",
3704
+ fontWeight: 600,
3705
+ lineHeight: "24px",
3706
+ backgroundColor: "#42b883",
3707
+ boxShadow: "0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1)"
3708
+ };
3709
+ var indicatorStyles = {
3710
+ display: "inline-block",
3711
+ fontWeight: 400,
3712
+ fontStyle: "normal",
3713
+ fontSize: "12px",
3714
+ opacity: 0.7
3715
+ };
3716
+ function getCotainerElement() {
3717
+ return document.getElementById(CONTAINER_ELEMENT_ID);
3718
+ }
3719
+ function getCardElement() {
3720
+ return document.getElementById(CARD_ELEMENT_ID);
3721
+ }
3722
+ function getIndicatorElement() {
3723
+ return document.getElementById(INDICATOR_ELEMENT_ID);
3724
+ }
3725
+ function getNameElement() {
3726
+ return document.getElementById(COMPONENT_NAME_ELEMENT_ID);
3727
+ }
3728
+ function getStyles(bounds) {
3729
+ return {
3730
+ left: `${Math.round(bounds.left * 100) / 100}px`,
3731
+ top: `${Math.round(bounds.top * 100) / 100}px`,
3732
+ width: `${Math.round(bounds.width * 100) / 100}px`,
3733
+ height: `${Math.round(bounds.height * 100) / 100}px`
3734
+ };
3735
+ }
3736
+ function create(options) {
3737
+ var _a8;
3738
+ const containerEl = document.createElement("div");
3739
+ containerEl.id = (_a8 = options.elementId) != null ? _a8 : CONTAINER_ELEMENT_ID;
3740
+ Object.assign(containerEl.style, {
3741
+ ...containerStyles,
3742
+ ...getStyles(options.bounds),
3743
+ ...options.style
3744
+ });
3745
+ const cardEl = document.createElement("span");
3746
+ cardEl.id = CARD_ELEMENT_ID;
3747
+ Object.assign(cardEl.style, {
3748
+ ...cardStyles,
3749
+ top: options.bounds.top < 35 ? 0 : "-35px"
3750
+ });
3751
+ const nameEl = document.createElement("span");
3752
+ nameEl.id = COMPONENT_NAME_ELEMENT_ID;
3753
+ nameEl.innerHTML = `&lt;${options.name}&gt;&nbsp;&nbsp;`;
3754
+ const indicatorEl = document.createElement("i");
3755
+ indicatorEl.id = INDICATOR_ELEMENT_ID;
3756
+ indicatorEl.innerHTML = `${Math.round(options.bounds.width * 100) / 100} x ${Math.round(options.bounds.height * 100) / 100}`;
3757
+ Object.assign(indicatorEl.style, indicatorStyles);
3758
+ cardEl.appendChild(nameEl);
3759
+ cardEl.appendChild(indicatorEl);
3760
+ containerEl.appendChild(cardEl);
3761
+ document.body.appendChild(containerEl);
3762
+ return containerEl;
3763
+ }
3764
+ function update(options) {
3765
+ const containerEl = getCotainerElement();
3766
+ const cardEl = getCardElement();
3767
+ const nameEl = getNameElement();
3768
+ const indicatorEl = getIndicatorElement();
3769
+ if (containerEl) {
3770
+ Object.assign(containerEl.style, {
3771
+ ...containerStyles,
3772
+ ...getStyles(options.bounds)
3773
+ });
3774
+ Object.assign(cardEl.style, {
3775
+ top: options.bounds.top < 35 ? 0 : "-35px"
3776
+ });
3777
+ nameEl.innerHTML = `&lt;${options.name}&gt;&nbsp;&nbsp;`;
3778
+ indicatorEl.innerHTML = `${Math.round(options.bounds.width * 100) / 100} x ${Math.round(options.bounds.height * 100) / 100}`;
3779
+ }
3780
+ }
3781
+ function toggleComponentInspector(options) {
3782
+ if (options.visible) {
3783
+ const instance = getComponentInstance(devtoolsContext.appRecord, options.id);
3784
+ if (instance && (options.bounds.width || options.bounds.height)) {
3785
+ const name = getInstanceName(instance);
3786
+ const el = getCotainerElement();
3787
+ el ? update({ ...options, name }) : create({ ...options, name });
3788
+ }
3789
+ } else {
3790
+ const el = getCotainerElement();
3791
+ if (el)
3792
+ el.style.display = "none";
3793
+ }
3794
+ }
3795
+ var inspectInstance = null;
3796
+ function inspectFn(e) {
3797
+ const target8 = e.target;
3798
+ if (target8) {
3799
+ const instance = target8.__vueParentComponent;
3800
+ if (instance) {
3801
+ inspectInstance = instance;
3802
+ const el = instance.vnode.el;
3803
+ if (el && el.nodeType === Node.ELEMENT_NODE) {
3804
+ const bounds = el.getBoundingClientRect();
3805
+ const name = getInstanceName(instance);
3806
+ const container = getCotainerElement();
3807
+ container ? update({ bounds, name }) : create({ bounds, name });
3808
+ }
3809
+ }
3810
+ }
3811
+ }
3812
+ function selectComponentFn(e, cb) {
3813
+ var _a8;
3814
+ e.preventDefault();
3815
+ e.stopPropagation();
3816
+ if (inspectInstance) {
3817
+ const app = (_a8 = devtoolsContext.appRecord) == null ? void 0 : _a8.app;
3818
+ getComponentId({
3819
+ app,
3820
+ uid: app.uid,
3821
+ instance: inspectInstance
3822
+ }).then((id) => {
3823
+ cb(id);
3824
+ });
3825
+ }
3826
+ }
3827
+ function inspectComponentInspector() {
3828
+ window.addEventListener("mouseover", inspectFn);
3829
+ return new Promise((resolve) => {
3830
+ function onSelect(e) {
3831
+ e.preventDefault();
3832
+ e.stopPropagation();
3833
+ selectComponentFn(e, (id) => {
3834
+ window.removeEventListener("click", onSelect);
3835
+ window.removeEventListener("mouseover", inspectFn);
3836
+ const el = getCotainerElement();
3837
+ if (el)
3838
+ el.style.display = "none";
3839
+ resolve(JSON.stringify({ id }));
3840
+ });
3841
+ }
3842
+ window.addEventListener("click", onSelect);
3843
+ });
3844
+ }
3845
+ function scrollToComponent(options) {
3846
+ const instance = getComponentInstance(devtoolsContext.appRecord, options.id);
3847
+ if (instance) {
3848
+ const [el] = getRootElementsFromComponentInstance(instance);
3849
+ if (typeof el.scrollIntoView === "function") {
3850
+ el.scrollIntoView({
3851
+ behavior: "smooth"
3852
+ });
3853
+ } else {
3854
+ const bounds = getComponentBoundingRect(instance);
3855
+ const scrollTarget = document.createElement("div");
3856
+ const styles = {
3857
+ ...getStyles(bounds),
3858
+ position: "absolute"
3859
+ };
3860
+ Object.assign(scrollTarget.style, styles);
3861
+ document.body.appendChild(scrollTarget);
3862
+ scrollTarget.scrollIntoView({
3863
+ behavior: "smooth"
3864
+ });
3865
+ setTimeout(() => {
3866
+ document.body.removeChild(scrollTarget);
3867
+ }, 2e3);
3868
+ }
3869
+ setTimeout(() => {
3870
+ const bounds = getComponentBoundingRect(instance);
3871
+ if (bounds.width || bounds.height) {
3872
+ const name = getInstanceName(instance);
3873
+ const el2 = getCotainerElement();
3874
+ el2 ? update({ ...options, name, bounds }) : create({ ...options, name, bounds });
3875
+ setTimeout(() => {
3876
+ if (el2)
3877
+ el2.style.display = "none";
3878
+ }, 1500);
3879
+ }
3880
+ }, 1200);
3881
+ }
3882
+ }
3883
+
3884
+ // src/api/off.ts
3885
+ init_esm_shims();
3886
+ function clear() {
3887
+ apiHooks.removeAllHooks();
3888
+ }
3889
+
3890
+ // src/api/index.ts
3891
+ var DevToolsPluginApi = class {
3892
+ constructor() {
3893
+ this.on = on2;
3894
+ this.clear = clear;
3895
+ }
3896
+ toggleApp(id) {
3897
+ return toggleAppRecord(id);
3898
+ }
3899
+ addTimelineEvent(payload) {
3900
+ apiHooks.callHook("timeline:add-event" /* ADD_TIMELINE_EVENT */, payload);
3901
+ }
3902
+ toggleComponentInspector(payload) {
3903
+ return toggleComponentInspector(payload);
3904
+ }
3905
+ inspectComponentInspector() {
3906
+ return inspectComponentInspector();
3907
+ }
3908
+ scrollToComponent(payload) {
3909
+ return scrollToComponent(payload);
3910
+ }
3911
+ getComponentBoundingRect(payload) {
3912
+ const { inspectorId, instanceId = "" } = payload;
3913
+ const _payload = {
3914
+ app: devtoolsContext.appRecord.app,
3915
+ inspectorId,
3916
+ instanceId,
3917
+ rect: {
3918
+ top: 0,
3919
+ left: 0,
3920
+ width: 0,
3921
+ height: 0
3922
+ }
3923
+ };
3924
+ apiHooks.callHookWith((callbacks) => {
3925
+ callbacks.map((cb) => cb(_payload));
3926
+ }, "component-bounding-rect:get" /* GET_COMPONENT_BOUNDING_RECT */);
3927
+ return stringify(_payload.rect);
3928
+ }
3929
+ async getInspectorTree(payload = {}) {
3930
+ const { inspectorId, filter = "", instanceId = "" } = payload;
3931
+ const _payload = {
3932
+ app: devtoolsContext.appRecord.app,
3933
+ inspectorId,
3934
+ instanceId,
3935
+ filter,
3936
+ rootNodes: []
3937
+ };
3938
+ updateInspector(inspectorId, {
3939
+ filter
3940
+ });
3941
+ await new Promise((resolve) => {
3942
+ apiHooks.callHookWith(async (callbacks) => {
3943
+ await Promise.all(callbacks.map((cb) => cb(_payload)));
3944
+ resolve();
3945
+ }, "inspector-tree:get" /* GET_INSPECTOR_TREE */);
3946
+ });
3947
+ return stringify(_payload.rootNodes);
3948
+ }
3949
+ getInspectorState(payload = {}) {
3950
+ const { inspectorId, nodeId } = payload;
3951
+ const _payload = {
3952
+ app: devtoolsContext.appRecord.app,
3953
+ inspectorId,
3954
+ nodeId
3955
+ };
3956
+ updateInspector(inspectorId, {
3957
+ nodeId
3958
+ });
3959
+ apiHooks.callHookWith((callbacks) => {
3960
+ callbacks.forEach((cb) => cb(_payload));
3961
+ }, "inspector-state:get" /* GET_INSPECTOR_STATE */);
3962
+ const state = _payload.state;
3963
+ delete state.instance;
3964
+ return stringify(state);
3965
+ }
3966
+ async editInspectorState(payload) {
3967
+ const stateEditor2 = new StateEditor();
3968
+ apiHooks.callHook("inspector-state:edit" /* EDIT_INSPECTOR_STATE */, {
3969
+ ...payload,
3970
+ app: devtoolsContext.appRecord.app,
3971
+ set: (obj, path = payload.path, value = payload.state.value, cb) => {
3972
+ stateEditor2.set(obj, path, value, cb || stateEditor2.createDefaultSetCallback(payload.state));
3973
+ }
3974
+ });
3975
+ }
3976
+ async sendInspectorTree(inspectorId) {
3977
+ const inspector = getInspector(inspectorId);
3978
+ if (inspector) {
3979
+ const res = await this.getInspectorTree({
3980
+ inspectorId
3981
+ });
3982
+ apiHooks.callHook("inspector-tree:send" /* SEND_INSPECTOR_TREE */, stringify({
3983
+ inspectorId,
3984
+ data: parse(res)
3985
+ }));
3986
+ }
3987
+ }
3988
+ async sendInspectorState(inspectorId) {
3989
+ const inspector = getInspector(inspectorId);
3990
+ if (inspector && inspector.nodeId) {
3991
+ const res = await this.getInspectorState({
3992
+ inspectorId,
3993
+ nodeId: inspector.nodeId
3994
+ });
3995
+ apiHooks.callHook("inspector-state:send" /* SEND_INSPECTOR_STATE */, stringify({ ...parse(res), inspectorId }));
3996
+ }
3997
+ }
3998
+ addCustomTab(tab) {
3999
+ addCustomTab(tab);
4000
+ }
4001
+ addCustomCommand(action) {
4002
+ addCustomCommand(action);
4003
+ }
4004
+ removeCustomCommand(actionId) {
4005
+ removeCustomCommand(actionId);
4006
+ }
4007
+ addInspector(payload) {
4008
+ var _a8;
4009
+ addInspector({
4010
+ id: payload.id,
4011
+ nodeId: "",
4012
+ filter: "",
4013
+ treeFilterPlaceholder: (_a8 = payload.treeFilterPlaceholder) != null ? _a8 : ""
4014
+ });
4015
+ }
4016
+ openInEditor(payload) {
4017
+ openInEditor(payload);
4018
+ }
4019
+ // Vite only
4020
+ getVueInspector() {
4021
+ return getVueInspector();
4022
+ }
4023
+ visitComponentTree(payload) {
4024
+ apiHooks.callHook("component-tree:visit" /* VISIT_COMPONENT_TREE */, payload);
4025
+ }
4026
+ addTimelineLayer(payload) {
4027
+ addTimelineLayer(payload);
4028
+ }
4029
+ notifyComponentUpdate() {
4030
+ }
4031
+ now() {
4032
+ return now();
4033
+ }
4034
+ getSettings() {
4035
+ return {
4036
+ logStoreChanges: null
4037
+ };
4038
+ }
4039
+ };
4040
+
4041
+ // src/core/general/app.ts
4042
+ init_esm_shims();
4043
+ var import_speakingurl = __toESM(require_speakingurl2(), 1);
4044
+ import { target as target6 } from "@vue/devtools-shared";
4045
+ var _a7, _b7;
4046
+ var appRecordInfo = (_b7 = (_a7 = target6).__VUE_DEVTOOLS_APP_RECROD_INFO__) != null ? _b7 : _a7.__VUE_DEVTOOLS_APP_RECROD_INFO__ = {
4047
+ id: 0,
4048
+ appIds: /* @__PURE__ */ new Set()
4049
+ };
4050
+ function getAppRecordName(app, fallbackName) {
4051
+ var _a8;
4052
+ return ((_a8 = app == null ? void 0 : app._component) == null ? void 0 : _a8.name) || `App ${fallbackName}`;
4053
+ }
4054
+ function getAppRootInstance(app) {
4055
+ var _a8, _b8, _c, _d;
4056
+ if (app._instance)
4057
+ return app._instance;
4058
+ else if ((_b8 = (_a8 = app._container) == null ? void 0 : _a8._vnode) == null ? void 0 : _b8.component)
4059
+ return (_d = (_c = app._container) == null ? void 0 : _c._vnode) == null ? void 0 : _d.component;
4060
+ }
4061
+ function getAppRecordId(app, defaultId) {
4062
+ if (app.__VUE_DEVTOOLS_APP_RECORD_ID__ != null)
4063
+ return app.__VUE_DEVTOOLS_APP_RECORD_ID__;
4064
+ let id = defaultId != null ? defaultId : (appRecordInfo.id++).toString();
4065
+ if (defaultId && appRecordInfo.appIds.has(id)) {
4066
+ let count = 1;
4067
+ while (appRecordInfo.appIds.has(`${defaultId}_${count}`))
4068
+ count++;
4069
+ id = `${defaultId}_${count}`;
4070
+ }
4071
+ appRecordInfo.appIds.add(id);
4072
+ app.__VUE_DEVTOOLS_APP_RECORD_ID__ = id;
4073
+ return id;
4074
+ }
4075
+ function createAppRecord(app) {
4076
+ const rootInstance = getAppRootInstance(app);
4077
+ if (rootInstance) {
4078
+ appRecordInfo.id++;
4079
+ const name = getAppRecordName(app, appRecordInfo.id.toString());
4080
+ const id = getAppRecordId(app, (0, import_speakingurl.default)(name));
4081
+ const record = {
4082
+ id,
4083
+ name,
4084
+ instanceMap: /* @__PURE__ */ new Map(),
4085
+ rootInstance
4086
+ };
4087
+ app.__VUE_DEVTOOLS_APP_RECORD__ = record;
4088
+ const rootId = `${record.id}:root`;
4089
+ record.instanceMap.set(rootId, record.rootInstance);
4090
+ record.rootInstance.__VUE_DEVTOOLS_UID__ = rootId;
4091
+ return record;
4092
+ } else {
4093
+ return {};
4094
+ }
4095
+ }
4096
+
4097
+ // src/core/general/index.ts
4098
+ function initDevTools() {
4099
+ var _a8, _b8, _c;
4100
+ devtoolsState.vitePluginDetected = !!target7.__VUE_DEVTOOLS_VITE_PLUGIN_DETECTED__;
4101
+ const isNewDevTools = ((_a8 = target7.__VUE_DEVTOOLS_GLOBAL_HOOK__) == null ? void 0 : _a8.id) === "vue-devtools-next";
4102
+ if (target7.__VUE_DEVTOOLS_GLOBAL_HOOK__ && isNewDevTools)
4103
+ return;
4104
+ if (target7.__VUE_DEVTOOLS_GLOBAL_HOOK__)
4105
+ Object.assign(__VUE_DEVTOOLS_GLOBAL_HOOK__, createDevToolsHook());
4106
+ else
4107
+ target7.__VUE_DEVTOOLS_GLOBAL_HOOK__ = createDevToolsHook();
4108
+ (_c = (_b8 = target7).__VUE_DEVTOOLS_APP_RECORDS__) != null ? _c : _b8.__VUE_DEVTOOLS_APP_RECORDS__ = [];
4109
+ hook.on.setupDevtoolsPlugin(collectRegisteredPlugin);
4110
+ hook.on.vueAppInit(async (app, version) => {
4111
+ var _a9;
4112
+ const record = createAppRecord(app);
4113
+ const api = new DevToolsPluginApi();
4114
+ devtoolsState.appRecords = [
4115
+ ...(_a9 = devtoolsState.appRecords) != null ? _a9 : [],
4116
+ {
4117
+ ...record,
4118
+ app,
4119
+ version,
4120
+ api
4121
+ }
4122
+ ];
4123
+ if (devtoolsState.appRecords.length === 1) {
4124
+ await setActiveAppRecord(devtoolsState.appRecords[0]);
4125
+ devtoolsState.connected = true;
4126
+ devtoolsHooks.callHook(DevToolsHooks3.APP_CONNECTED);
4127
+ }
4128
+ });
4129
+ subscribeDevToolsHook();
4130
+ }
4131
+ function onDevToolsConnected(fn) {
4132
+ return new Promise((resolve) => {
4133
+ if (devtoolsState.connected) {
4134
+ fn();
4135
+ resolve();
4136
+ return;
4137
+ }
4138
+ apiHooks.hook("devtools:connected-updated" /* DEVTOOLS_CONNECTED_UPDATED */, (state) => {
4139
+ if (state.connected) {
4140
+ fn();
4141
+ resolve();
4142
+ }
4143
+ });
4144
+ });
4145
+ }
4146
+ function onDevToolsClientConnected(fn) {
4147
+ return new Promise((resolve) => {
4148
+ if (devtoolsState.connected && devtoolsState.clientConnected) {
4149
+ fn();
4150
+ resolve();
4151
+ return;
4152
+ }
4153
+ apiHooks.hook("devtools:connected-updated" /* DEVTOOLS_CONNECTED_UPDATED */, (state) => {
4154
+ if (state.connected && state.clientConnected) {
4155
+ fn();
4156
+ resolve();
4157
+ }
4158
+ });
4159
+ });
4160
+ }
4161
+
4162
+ // src/index.ts
4163
+ var devtools = {
4164
+ state: devtoolsState,
4165
+ context: devtoolsContext,
4166
+ init: initDevTools,
4167
+ hook,
4168
+ get api() {
4169
+ return devtoolsContext.api;
4170
+ }
4171
+ };
4172
+ export {
4173
+ ESC,
4174
+ INFINITY,
4175
+ MAX_ARRAY_SIZE,
4176
+ MAX_STRING_SIZE,
4177
+ NAN,
4178
+ NEGATIVE_INFINITY,
4179
+ UNDEFINED,
4180
+ addCustomCommand,
4181
+ addCustomTab,
4182
+ devtools,
4183
+ fnTypeRE,
4184
+ formatInspectorStateValue,
4185
+ getInspectorStateValueType,
4186
+ now,
4187
+ onDevToolsClientConnected,
4188
+ onDevToolsConnected,
4189
+ parse,
4190
+ rawTypeRE,
4191
+ removeCustomCommand,
4192
+ setupDevToolsPlugin,
4193
+ specialTypeRE,
4194
+ stringify,
4195
+ symbolRE,
4196
+ vueBuiltins
4197
+ };