@danalazar/metro-ui 0.0.1 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist/assets/button.css +1 -1
  2. package/dist/assets/formField.css +1 -0
  3. package/dist/assets/input.css +1 -0
  4. package/dist/assets/inputWithAction.css +1 -0
  5. package/dist/assets/keypad.css +1 -0
  6. package/dist/assets/modal.css +1 -0
  7. package/dist/assets/select.css +1 -0
  8. package/dist/assets/spinner.css +1 -0
  9. package/dist/button-DTU9l2Gg.js +44 -0
  10. package/dist/clsx-ROFf4vs9.js +16 -0
  11. package/dist/components/button/button.d.ts +10 -5
  12. package/dist/components/button/button.js +2 -1
  13. package/dist/components/button/button.stories.d.ts +48 -0
  14. package/dist/components/button/button.stories.js +82 -0
  15. package/dist/components/button/button.test.d.ts +1 -0
  16. package/dist/components/button/button.test.js +42 -0
  17. package/dist/components/formField/formField.d.ts +8 -0
  18. package/dist/components/formField/formField.js +2 -0
  19. package/dist/components/formField/formField.stories.d.ts +15 -0
  20. package/dist/components/formField/formField.stories.js +77 -0
  21. package/dist/components/formField/formField.test.d.ts +1 -0
  22. package/dist/components/formField/formField.test.js +40 -0
  23. package/dist/components/input/input.d.ts +11 -0
  24. package/dist/components/input/input.js +2 -0
  25. package/dist/components/inputWithActions/inputWithAction.d.ts +5 -0
  26. package/dist/components/inputWithActions/inputWithAction.js +2 -0
  27. package/dist/components/inputWithActions/inputWithAction.stories.d.ts +9 -0
  28. package/dist/components/inputWithActions/inputWithAction.stories.js +83 -0
  29. package/dist/components/inputWithActions/inputWithAction.test.d.ts +1 -0
  30. package/dist/components/inputWithActions/inputWithAction.test.js +9 -0
  31. package/dist/components/keypad/keypad.d.ts +16 -0
  32. package/dist/components/keypad/keypad.js +4 -0
  33. package/dist/components/keypad/keypad.stories.d.ts +6 -0
  34. package/dist/components/keypad/keypad.stories.js +17 -0
  35. package/dist/components/keypad/keypad.test.d.ts +1 -0
  36. package/dist/components/keypad/keypad.test.js +31 -0
  37. package/dist/components/modal/modal.d.ts +9 -0
  38. package/dist/components/modal/modal.js +4 -0
  39. package/dist/components/modal/modal.stories.d.ts +32 -0
  40. package/dist/components/modal/modal.stories.js +78 -0
  41. package/dist/components/modal/modal.test.d.ts +1 -0
  42. package/dist/components/modal/modal.test.js +35 -0
  43. package/dist/components/select/select.d.ts +16 -0
  44. package/dist/components/select/select.js +2 -0
  45. package/dist/components/select/select.stories.d.ts +38 -0
  46. package/dist/components/select/select.stories.js +44 -0
  47. package/dist/components/select/select.test.d.ts +1 -0
  48. package/dist/components/select/select.test.js +36 -0
  49. package/dist/components/spinner/spinner.d.ts +6 -0
  50. package/dist/components/spinner/spinner.js +2 -0
  51. package/dist/components/spinner/spinner.stories.d.ts +30 -0
  52. package/dist/components/spinner/spinner.stories.js +32 -0
  53. package/dist/components/spinner/spinner.test.d.ts +1 -0
  54. package/dist/components/spinner/spinner.test.js +21 -0
  55. package/dist/formField-BdRLOA0x.js +30 -0
  56. package/dist/input-q5h2lA4L.js +20 -0
  57. package/dist/inputWithAction-VBlCurUV.js +8 -0
  58. package/dist/keypad-Bu5TjaRH.js +135 -0
  59. package/dist/lib-JrI87syO.js +5604 -0
  60. package/dist/magic-string.es-D07BpzB1.js +659 -0
  61. package/dist/main.d.ts +7 -0
  62. package/dist/main.js +9 -2
  63. package/dist/modal-mu0n0R19.js +48 -0
  64. package/dist/react.esm-CQZuoo0_.js +31060 -0
  65. package/dist/select-NHAc5xjZ.js +26 -0
  66. package/dist/spinner-Co2caOhH.js +19 -0
  67. package/dist/test/setup.d.ts +0 -0
  68. package/dist/test/setup.js +2002 -0
  69. package/package.json +40 -14
  70. package/dist/button-DU_N71pa.js +0 -6
@@ -0,0 +1,2002 @@
1
+ import { i as e, n as t, t as n } from "../lib-JrI87syO.js";
2
+ //#region node_modules/min-indent/index.js
3
+ var r = /* @__PURE__ */ t(((e, t) => {
4
+ t.exports = (e) => {
5
+ let t = e.match(/^[ \t]*(?=\S)/gm);
6
+ return t ? t.reduce((e, t) => Math.min(e, t.length), Infinity) : 0;
7
+ };
8
+ })), i = /* @__PURE__ */ t(((e, t) => {
9
+ var n = r();
10
+ t.exports = (e) => {
11
+ let t = n(e);
12
+ if (t === 0) return e;
13
+ let r = RegExp(`^[ \\t]{${t}}`, "gm");
14
+ return e.replace(r, "");
15
+ };
16
+ })), a = /* @__PURE__ */ t(((e, t) => {
17
+ t.exports = (e, t = 1, n) => {
18
+ if (n = {
19
+ indent: " ",
20
+ includeEmptyLines: !1,
21
+ ...n
22
+ }, typeof e != "string") throw TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof e}\``);
23
+ if (typeof t != "number") throw TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof t}\``);
24
+ if (typeof n.indent != "string") throw TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof n.indent}\``);
25
+ if (t === 0) return e;
26
+ let r = n.includeEmptyLines ? /^/gm : /^(?!\s*$)/gm;
27
+ return e.replace(r, n.indent.repeat(t));
28
+ };
29
+ })), o = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
30
+ var n = i(), r = a();
31
+ t.exports = (e, t = 0, i) => r(n(e), t, i);
32
+ })))(), 1), s = class extends Error {
33
+ reason;
34
+ filename;
35
+ line;
36
+ column;
37
+ source;
38
+ constructor(e, t, n, r, i) {
39
+ super(`${e}:${n}:${r}: ${t}`), this.reason = t, this.filename = e, this.line = n, this.column = r, this.source = i;
40
+ }
41
+ }, c = class {
42
+ start;
43
+ end;
44
+ source;
45
+ constructor(e, t, n) {
46
+ this.start = e, this.end = t, this.source = n;
47
+ }
48
+ }, l;
49
+ (function(e) {
50
+ e.stylesheet = "stylesheet", e.rule = "rule", e.declaration = "declaration", e.comment = "comment", e.container = "container", e.charset = "charset", e.document = "document", e.customMedia = "custom-media", e.fontFace = "font-face", e.host = "host", e.import = "import", e.keyframes = "keyframes", e.keyframe = "keyframe", e.layer = "layer", e.media = "media", e.namespace = "namespace", e.page = "page", e.startingStyle = "starting-style", e.supports = "supports";
51
+ })(l ||= {});
52
+ var u = (e, t, n) => {
53
+ let r = n, i = 1e4;
54
+ do {
55
+ let n = t.map((t) => e.indexOf(t, r));
56
+ n.push(e.indexOf("\\", r));
57
+ let a = n.filter((e) => e !== -1);
58
+ if (a.length === 0) return -1;
59
+ let o = Math.min(...a);
60
+ if (e[o] !== "\\") return o;
61
+ r = o + 2, i--;
62
+ } while (i > 0);
63
+ throw Error("Too many escaping");
64
+ }, d = (e, t, n) => {
65
+ let r = n, i = 1e4;
66
+ do {
67
+ let n = t.map((t) => e.indexOf(t, r));
68
+ n.push(e.indexOf("(", r)), n.push(e.indexOf("\"", r)), n.push(e.indexOf("'", r)), n.push(e.indexOf("\\", r));
69
+ let a = n.filter((e) => e !== -1);
70
+ if (a.length === 0) return -1;
71
+ let o = Math.min(...a);
72
+ switch (e[o]) {
73
+ case "\\":
74
+ r = o + 2;
75
+ break;
76
+ case "(":
77
+ {
78
+ let t = d(e, [")"], o + 1);
79
+ if (t === -1) return -1;
80
+ r = t + 1;
81
+ }
82
+ break;
83
+ case "\"":
84
+ {
85
+ let t = u(e, ["\""], o + 1);
86
+ if (t === -1) return -1;
87
+ r = t + 1;
88
+ }
89
+ break;
90
+ case "'":
91
+ {
92
+ let t = u(e, ["'"], o + 1);
93
+ if (t === -1) return -1;
94
+ r = t + 1;
95
+ }
96
+ break;
97
+ default: return o;
98
+ }
99
+ i--;
100
+ } while (i > 0);
101
+ throw Error("Too many escaping");
102
+ }, f = /\/\*[^]*?(?:\*\/|$)/g;
103
+ function p(e) {
104
+ return e ? e.trim() : "";
105
+ }
106
+ function m(e, t) {
107
+ let n = e && typeof e.type == "string", r = n ? e : t;
108
+ for (let t in e) {
109
+ let n = e[t];
110
+ Array.isArray(n) ? n.forEach((e) => {
111
+ m(e, r);
112
+ }) : n && typeof n == "object" && m(n, r);
113
+ }
114
+ return n && Object.defineProperty(e, "parent", {
115
+ configurable: !0,
116
+ writable: !0,
117
+ enumerable: !1,
118
+ value: t || null
119
+ }), e;
120
+ }
121
+ var h = (e, t) => {
122
+ t ||= {};
123
+ let n = 1, r = 1;
124
+ function i() {
125
+ let e = {
126
+ line: n,
127
+ column: r
128
+ };
129
+ return (i) => (i.position = new c(e, {
130
+ line: n,
131
+ column: r
132
+ }, t?.source || ""), v(), i);
133
+ }
134
+ let a = [];
135
+ function o(i) {
136
+ let o = new s(t?.source || "", i, n, r, e);
137
+ if (!t?.silent) throw o;
138
+ a.push(o);
139
+ }
140
+ function u() {
141
+ let t = /^{\s*/.exec(e);
142
+ return !!t && (_(t), !0);
143
+ }
144
+ function h() {
145
+ let t = /^}/.exec(e);
146
+ return !!t && (_(t), !0);
147
+ }
148
+ function g() {
149
+ let t, n = [];
150
+ for (v(), y(n); e.length && e.charAt(0) !== "}" && (t = ne() || D(), t);) n.push(t), y(n);
151
+ return n;
152
+ }
153
+ function _(t) {
154
+ let i = t[0];
155
+ return function(e) {
156
+ let t = e.match(/\n/g);
157
+ t && (n += t.length);
158
+ let i = e.lastIndexOf("\n");
159
+ r = ~i ? e.length - i : r + e.length;
160
+ }(i), e = e.slice(i.length), t;
161
+ }
162
+ function v() {
163
+ let t = /^\s*/.exec(e);
164
+ t && _(t);
165
+ }
166
+ function y(e) {
167
+ e ||= [];
168
+ let t = b();
169
+ for (; t;) e.push(t), t = b();
170
+ return e;
171
+ }
172
+ function b() {
173
+ let t = i();
174
+ if (e.charAt(0) !== "/" || e.charAt(1) !== "*") return;
175
+ let n = /^\/\*[^]*?\*\//.exec(e);
176
+ return n ? (_(n), t({
177
+ type: l.comment,
178
+ comment: n[0].slice(2, -2)
179
+ })) : o("End of comment missing");
180
+ }
181
+ function x() {
182
+ let t = /^([^{]+)/.exec(e);
183
+ if (t) return _(t), ((e, t) => {
184
+ let n = [], r = 0;
185
+ for (; r < e.length;) {
186
+ let i = d(e, t, r);
187
+ if (i === -1) return n.push(e.substring(r)), n;
188
+ n.push(e.substring(r, i)), r = i + 1;
189
+ }
190
+ return n;
191
+ })(p(t[0]).replace(f, ""), [","]).map((e) => p(e));
192
+ }
193
+ function S() {
194
+ let t = i(), n = /^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/.exec(e);
195
+ if (!n) return;
196
+ _(n);
197
+ let r = p(n[0]), a = /^:\s*/.exec(e);
198
+ if (!a) return o("property missing ':'");
199
+ _(a);
200
+ let s = "", c = d(e, [";", "}"]);
201
+ c !== -1 && (s = e.substring(0, c), _([s]), s = p(s).replace(f, ""));
202
+ let u = t({
203
+ type: l.declaration,
204
+ property: r.replace(f, ""),
205
+ value: s
206
+ }), m = /^[;\s]*/.exec(e);
207
+ return m && _(m), u;
208
+ }
209
+ function C() {
210
+ let e = [];
211
+ if (!u()) return o("missing '{'");
212
+ y(e);
213
+ let t = S();
214
+ for (; t;) e.push(t), y(e), t = S();
215
+ return h() ? e : o("missing '}'");
216
+ }
217
+ function w() {
218
+ let t = [], n = i(), r = /^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/.exec(e);
219
+ for (; r;) {
220
+ let n = _(r);
221
+ t.push(n[1]);
222
+ let i = /^,\s*/.exec(e);
223
+ i && _(i), r = /^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/.exec(e);
224
+ }
225
+ if (t.length) return n({
226
+ type: l.keyframe,
227
+ values: t,
228
+ declarations: C() || []
229
+ });
230
+ }
231
+ let ee = E("import"), te = E("charset"), T = E("namespace");
232
+ function E(t) {
233
+ let n = RegExp("^@" + t + "\\s*((?::?[^;'\"]|\"(?:\\\\\"|[^\"])*?\"|'(?:\\\\'|[^'])*?')+)(?:;|$)");
234
+ return () => {
235
+ let r = i(), a = n.exec(e);
236
+ if (!a) return;
237
+ let o = _(a), s = { type: t };
238
+ return s[t] = o[1].trim(), r(s);
239
+ };
240
+ }
241
+ function ne() {
242
+ if (e[0] === "@") return function() {
243
+ let t = i(), n = /^@([-\w]+)?keyframes\s*/.exec(e);
244
+ if (!n) return;
245
+ let r = _(n)[1], a = /^([-\w]+)\s*/.exec(e);
246
+ if (!a) return o("@keyframes missing name");
247
+ let s = _(a)[1];
248
+ if (!u()) return o("@keyframes missing '{'");
249
+ let c = y(), d = w();
250
+ for (; d;) c.push(d), c = c.concat(y()), d = w();
251
+ return h() ? t({
252
+ type: l.keyframes,
253
+ name: s,
254
+ vendor: r,
255
+ keyframes: c
256
+ }) : o("@keyframes missing '}'");
257
+ }() || function() {
258
+ let t = i(), n = /^@media *([^{]+)/.exec(e);
259
+ if (!n) return;
260
+ let r = p(_(n)[1]);
261
+ if (!u()) return o("@media missing '{'");
262
+ let a = y().concat(g());
263
+ return h() ? t({
264
+ type: l.media,
265
+ media: r,
266
+ rules: a
267
+ }) : o("@media missing '}'");
268
+ }() || function() {
269
+ let t = i(), n = /^@custom-media\s+(--\S+)\s+([^{;\s][^{;]*);/.exec(e);
270
+ if (!n) return;
271
+ let r = _(n);
272
+ return t({
273
+ type: l.customMedia,
274
+ name: p(r[1]),
275
+ media: p(r[2])
276
+ });
277
+ }() || function() {
278
+ let t = i(), n = /^@supports *([^{]+)/.exec(e);
279
+ if (!n) return;
280
+ let r = p(_(n)[1]);
281
+ if (!u()) return o("@supports missing '{'");
282
+ let a = y().concat(g());
283
+ return h() ? t({
284
+ type: l.supports,
285
+ supports: r,
286
+ rules: a
287
+ }) : o("@supports missing '}'");
288
+ }() || ee() || te() || T() || function() {
289
+ let t = i(), n = /^@([-\w]+)?document *([^{]+)/.exec(e);
290
+ if (!n) return;
291
+ let r = _(n), a = p(r[1]), s = p(r[2]);
292
+ if (!u()) return o("@document missing '{'");
293
+ let c = y().concat(g());
294
+ return h() ? t({
295
+ type: l.document,
296
+ document: s,
297
+ vendor: a,
298
+ rules: c
299
+ }) : o("@document missing '}'");
300
+ }() || function() {
301
+ let t = i(), n = /^@page */.exec(e);
302
+ if (!n) return;
303
+ _(n);
304
+ let r = x() || [];
305
+ if (!u()) return o("@page missing '{'");
306
+ let a = y(), s = S();
307
+ for (; s;) a.push(s), a = a.concat(y()), s = S();
308
+ return h() ? t({
309
+ type: l.page,
310
+ selectors: r,
311
+ declarations: a
312
+ }) : o("@page missing '}'");
313
+ }() || function() {
314
+ let t = i(), n = /^@host\s*/.exec(e);
315
+ if (!n) return;
316
+ if (_(n), !u()) return o("@host missing '{'");
317
+ let r = y().concat(g());
318
+ return h() ? t({
319
+ type: l.host,
320
+ rules: r
321
+ }) : o("@host missing '}'");
322
+ }() || function() {
323
+ let t = i(), n = /^@font-face\s*/.exec(e);
324
+ if (!n) return;
325
+ if (_(n), !u()) return o("@font-face missing '{'");
326
+ let r = y(), a = S();
327
+ for (; a;) r.push(a), r = r.concat(y()), a = S();
328
+ return h() ? t({
329
+ type: l.fontFace,
330
+ declarations: r
331
+ }) : o("@font-face missing '}'");
332
+ }() || function() {
333
+ let t = i(), n = /^@container *([^{]+)/.exec(e);
334
+ if (!n) return;
335
+ let r = p(_(n)[1]);
336
+ if (!u()) return o("@container missing '{'");
337
+ let a = y().concat(g());
338
+ return h() ? t({
339
+ type: l.container,
340
+ container: r,
341
+ rules: a
342
+ }) : o("@container missing '}'");
343
+ }() || function() {
344
+ let t = i(), n = /^@starting-style\s*/.exec(e);
345
+ if (!n) return;
346
+ if (_(n), !u()) return o("@starting-style missing '{'");
347
+ let r = y().concat(g());
348
+ return h() ? t({
349
+ type: l.startingStyle,
350
+ rules: r
351
+ }) : o("@starting-style missing '}'");
352
+ }() || function() {
353
+ let t = i(), n = /^@layer *([^{;@]+)/.exec(e);
354
+ if (!n) return;
355
+ let r = p(_(n)[1]);
356
+ if (!u()) {
357
+ let n = /^[;\s]*/.exec(e);
358
+ return n && _(n), t({
359
+ type: l.layer,
360
+ layer: r
361
+ });
362
+ }
363
+ let a = y().concat(g());
364
+ return h() ? t({
365
+ type: l.layer,
366
+ layer: r,
367
+ rules: a
368
+ }) : o("@layer missing '}'");
369
+ }();
370
+ }
371
+ function D() {
372
+ let e = i(), t = x();
373
+ return t ? (y(), e({
374
+ type: l.rule,
375
+ selectors: t,
376
+ declarations: C() || []
377
+ })) : o("selector missing");
378
+ }
379
+ return m(function() {
380
+ let e = g();
381
+ return {
382
+ type: l.stylesheet,
383
+ stylesheet: {
384
+ source: t?.source,
385
+ rules: e,
386
+ parsingErrors: a
387
+ }
388
+ };
389
+ }());
390
+ }, g = Object.prototype.toString;
391
+ function _(e) {
392
+ return typeof e == "function" || g.call(e) === "[object Function]";
393
+ }
394
+ function v(e) {
395
+ var t = Number(e);
396
+ return isNaN(t) ? 0 : t === 0 || !isFinite(t) ? t : (t > 0 ? 1 : -1) * Math.floor(Math.abs(t));
397
+ }
398
+ var y = 2 ** 53 - 1;
399
+ function b(e) {
400
+ var t = v(e);
401
+ return Math.min(Math.max(t, 0), y);
402
+ }
403
+ function x(e, t) {
404
+ var n = Array, r = Object(e);
405
+ if (e == null) throw TypeError("Array.from requires an array-like object - not null or undefined");
406
+ if (t !== void 0 && !_(t)) throw TypeError("Array.from: when provided, the second argument must be a function");
407
+ for (var i = b(r.length), a = _(n) ? Object(new n(i)) : Array(i), o = 0, s; o < i;) s = r[o], t ? a[o] = t(s, o) : a[o] = s, o += 1;
408
+ return a.length = i, a;
409
+ }
410
+ //#endregion
411
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/polyfills/SetLike.mjs
412
+ function S(e) {
413
+ "@babel/helpers - typeof";
414
+ return S = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
415
+ return typeof e;
416
+ } : function(e) {
417
+ return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
418
+ }, S(e);
419
+ }
420
+ function C(e, t) {
421
+ if (!(e instanceof t)) throw TypeError("Cannot call a class as a function");
422
+ }
423
+ function w(e, t) {
424
+ for (var n = 0; n < t.length; n++) {
425
+ var r = t[n];
426
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, T(r.key), r);
427
+ }
428
+ }
429
+ function ee(e, t, n) {
430
+ return t && w(e.prototype, t), n && w(e, n), Object.defineProperty(e, "prototype", { writable: !1 }), e;
431
+ }
432
+ function te(e, t, n) {
433
+ return t = T(t), t in e ? Object.defineProperty(e, t, {
434
+ value: n,
435
+ enumerable: !0,
436
+ configurable: !0,
437
+ writable: !0
438
+ }) : e[t] = n, e;
439
+ }
440
+ function T(e) {
441
+ var t = E(e, "string");
442
+ return S(t) === "symbol" ? t : String(t);
443
+ }
444
+ function E(e, t) {
445
+ if (S(e) !== "object" || e === null) return e;
446
+ var n = e[Symbol.toPrimitive];
447
+ if (n !== void 0) {
448
+ var r = n.call(e, t || "default");
449
+ if (S(r) !== "object") return r;
450
+ throw TypeError("@@toPrimitive must return a primitive value.");
451
+ }
452
+ return (t === "string" ? String : Number)(e);
453
+ }
454
+ var ne = typeof Set > "u" ? Set : /* @__PURE__ */ function() {
455
+ function e() {
456
+ var t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [];
457
+ C(this, e), te(this, "items", void 0), this.items = t;
458
+ }
459
+ return ee(e, [
460
+ {
461
+ key: "add",
462
+ value: function(e) {
463
+ return this.has(e) === !1 && this.items.push(e), this;
464
+ }
465
+ },
466
+ {
467
+ key: "clear",
468
+ value: function() {
469
+ this.items = [];
470
+ }
471
+ },
472
+ {
473
+ key: "delete",
474
+ value: function(e) {
475
+ var t = this.items.length;
476
+ return this.items = this.items.filter(function(t) {
477
+ return t !== e;
478
+ }), t !== this.items.length;
479
+ }
480
+ },
481
+ {
482
+ key: "forEach",
483
+ value: function(e) {
484
+ var t = this;
485
+ this.items.forEach(function(n) {
486
+ e(n, n, t);
487
+ });
488
+ }
489
+ },
490
+ {
491
+ key: "has",
492
+ value: function(e) {
493
+ return this.items.indexOf(e) !== -1;
494
+ }
495
+ },
496
+ {
497
+ key: "size",
498
+ get: function() {
499
+ return this.items.length;
500
+ }
501
+ }
502
+ ]), e;
503
+ }();
504
+ //#endregion
505
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/getRole.mjs
506
+ function D(e) {
507
+ return e.localName ?? e.tagName.toLowerCase();
508
+ }
509
+ var re = {
510
+ article: "article",
511
+ aside: "complementary",
512
+ button: "button",
513
+ datalist: "listbox",
514
+ dd: "definition",
515
+ details: "group",
516
+ dialog: "dialog",
517
+ dt: "term",
518
+ fieldset: "group",
519
+ figure: "figure",
520
+ form: "form",
521
+ footer: "contentinfo",
522
+ h1: "heading",
523
+ h2: "heading",
524
+ h3: "heading",
525
+ h4: "heading",
526
+ h5: "heading",
527
+ h6: "heading",
528
+ header: "banner",
529
+ hr: "separator",
530
+ html: "document",
531
+ legend: "legend",
532
+ li: "listitem",
533
+ math: "math",
534
+ main: "main",
535
+ menu: "list",
536
+ nav: "navigation",
537
+ ol: "list",
538
+ optgroup: "group",
539
+ option: "option",
540
+ output: "status",
541
+ progress: "progressbar",
542
+ section: "region",
543
+ summary: "button",
544
+ table: "table",
545
+ tbody: "rowgroup",
546
+ textarea: "textbox",
547
+ tfoot: "rowgroup",
548
+ td: "cell",
549
+ th: "columnheader",
550
+ thead: "rowgroup",
551
+ tr: "row",
552
+ ul: "list"
553
+ }, ie = {
554
+ caption: new Set(["aria-label", "aria-labelledby"]),
555
+ code: new Set(["aria-label", "aria-labelledby"]),
556
+ deletion: new Set(["aria-label", "aria-labelledby"]),
557
+ emphasis: new Set(["aria-label", "aria-labelledby"]),
558
+ generic: new Set([
559
+ "aria-label",
560
+ "aria-labelledby",
561
+ "aria-roledescription"
562
+ ]),
563
+ insertion: new Set(["aria-label", "aria-labelledby"]),
564
+ none: new Set(["aria-label", "aria-labelledby"]),
565
+ paragraph: new Set(["aria-label", "aria-labelledby"]),
566
+ presentation: new Set(["aria-label", "aria-labelledby"]),
567
+ strong: new Set(["aria-label", "aria-labelledby"]),
568
+ subscript: new Set(["aria-label", "aria-labelledby"]),
569
+ superscript: new Set(["aria-label", "aria-labelledby"])
570
+ };
571
+ function ae(e, t) {
572
+ return [
573
+ "aria-atomic",
574
+ "aria-busy",
575
+ "aria-controls",
576
+ "aria-current",
577
+ "aria-description",
578
+ "aria-describedby",
579
+ "aria-details",
580
+ "aria-dropeffect",
581
+ "aria-flowto",
582
+ "aria-grabbed",
583
+ "aria-hidden",
584
+ "aria-keyshortcuts",
585
+ "aria-label",
586
+ "aria-labelledby",
587
+ "aria-live",
588
+ "aria-owns",
589
+ "aria-relevant",
590
+ "aria-roledescription"
591
+ ].some(function(n) {
592
+ var r;
593
+ return e.hasAttribute(n) && !((r = ie[t]) != null && r.has(n));
594
+ });
595
+ }
596
+ function oe(e, t) {
597
+ return ae(e, t);
598
+ }
599
+ function se(e) {
600
+ var t = le(e);
601
+ if (t === null || O.indexOf(t) !== -1) {
602
+ var n = ce(e);
603
+ if (O.indexOf(t || "") === -1 || oe(e, n || "")) return n;
604
+ }
605
+ return t;
606
+ }
607
+ function ce(e) {
608
+ var t = re[D(e)];
609
+ if (t !== void 0) return t;
610
+ switch (D(e)) {
611
+ case "a":
612
+ case "area":
613
+ case "link":
614
+ if (e.hasAttribute("href")) return "link";
615
+ break;
616
+ case "img": return e.getAttribute("alt") === "" && !oe(e, "img") ? "presentation" : "img";
617
+ case "input":
618
+ var n = e.type;
619
+ switch (n) {
620
+ case "button":
621
+ case "image":
622
+ case "reset":
623
+ case "submit": return "button";
624
+ case "checkbox":
625
+ case "radio": return n;
626
+ case "range": return "slider";
627
+ case "email":
628
+ case "tel":
629
+ case "text":
630
+ case "url": return e.hasAttribute("list") ? "combobox" : "textbox";
631
+ case "search": return e.hasAttribute("list") ? "combobox" : "searchbox";
632
+ case "number": return "spinbutton";
633
+ default: return null;
634
+ }
635
+ case "select": return e.hasAttribute("multiple") || e.size > 1 ? "listbox" : "combobox";
636
+ }
637
+ return null;
638
+ }
639
+ function le(e) {
640
+ var t = e.getAttribute("role");
641
+ if (t !== null) {
642
+ var n = t.trim().split(" ")[0];
643
+ if (n.length > 0) return n;
644
+ }
645
+ return null;
646
+ }
647
+ //#endregion
648
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/util.mjs
649
+ var O = ["presentation", "none"];
650
+ function k(e) {
651
+ return e !== null && e.nodeType === e.ELEMENT_NODE;
652
+ }
653
+ function ue(e) {
654
+ return k(e) && D(e) === "caption";
655
+ }
656
+ function A(e) {
657
+ return k(e) && D(e) === "input";
658
+ }
659
+ function de(e) {
660
+ return k(e) && D(e) === "optgroup";
661
+ }
662
+ function fe(e) {
663
+ return k(e) && D(e) === "select";
664
+ }
665
+ function pe(e) {
666
+ return k(e) && D(e) === "table";
667
+ }
668
+ function me(e) {
669
+ return k(e) && D(e) === "textarea";
670
+ }
671
+ function he(e) {
672
+ var t = (e.ownerDocument === null ? e : e.ownerDocument).defaultView;
673
+ if (t === null) throw TypeError("no window available");
674
+ return t;
675
+ }
676
+ function ge(e) {
677
+ return k(e) && D(e) === "fieldset";
678
+ }
679
+ function _e(e) {
680
+ return k(e) && D(e) === "legend";
681
+ }
682
+ function ve(e) {
683
+ return k(e) && D(e) === "slot";
684
+ }
685
+ function ye(e) {
686
+ return k(e) && e.ownerSVGElement !== void 0;
687
+ }
688
+ function be(e) {
689
+ return k(e) && D(e) === "svg";
690
+ }
691
+ function xe(e) {
692
+ return ye(e) && D(e) === "title";
693
+ }
694
+ function j(e, t) {
695
+ if (k(e) && e.hasAttribute(t)) {
696
+ var n = e.getAttribute(t).split(" "), r = e.getRootNode ? e.getRootNode() : e.ownerDocument;
697
+ return n.map(function(e) {
698
+ return r.getElementById(e);
699
+ }).filter(function(e) {
700
+ return e !== null;
701
+ });
702
+ }
703
+ return [];
704
+ }
705
+ function M(e, t) {
706
+ return k(e) ? t.indexOf(se(e)) !== -1 : !1;
707
+ }
708
+ //#endregion
709
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-name-and-description.mjs
710
+ function Se(e) {
711
+ return e.trim().replace(/\s\s+/g, " ");
712
+ }
713
+ function Ce(e, t) {
714
+ if (!k(e)) return !1;
715
+ if (e.hasAttribute("hidden") || e.getAttribute("aria-hidden") === "true") return !0;
716
+ var n = t(e);
717
+ return n.getPropertyValue("display") === "none" || n.getPropertyValue("visibility") === "hidden";
718
+ }
719
+ function we(e) {
720
+ return M(e, [
721
+ "button",
722
+ "combobox",
723
+ "listbox",
724
+ "textbox"
725
+ ]) || N(e, "range");
726
+ }
727
+ function N(e, t) {
728
+ if (!k(e)) return !1;
729
+ switch (t) {
730
+ case "range": return M(e, [
731
+ "meter",
732
+ "progressbar",
733
+ "scrollbar",
734
+ "slider",
735
+ "spinbutton"
736
+ ]);
737
+ default: throw TypeError(`No knowledge about abstract role '${t}'. This is likely a bug :(`);
738
+ }
739
+ }
740
+ function P(e, t) {
741
+ var n = x(e.querySelectorAll(t));
742
+ return j(e, "aria-owns").forEach(function(e) {
743
+ n.push.apply(n, x(e.querySelectorAll(t)));
744
+ }), n;
745
+ }
746
+ function Te(e) {
747
+ return fe(e) ? e.selectedOptions || P(e, "[selected]") : P(e, "[aria-selected=\"true\"]");
748
+ }
749
+ function Ee(e) {
750
+ return M(e, O);
751
+ }
752
+ function De(e) {
753
+ return ue(e);
754
+ }
755
+ function Oe(e) {
756
+ return M(e, [
757
+ "button",
758
+ "cell",
759
+ "checkbox",
760
+ "columnheader",
761
+ "gridcell",
762
+ "heading",
763
+ "label",
764
+ "legend",
765
+ "link",
766
+ "menuitem",
767
+ "menuitemcheckbox",
768
+ "menuitemradio",
769
+ "option",
770
+ "radio",
771
+ "row",
772
+ "rowheader",
773
+ "switch",
774
+ "tab",
775
+ "tooltip",
776
+ "treeitem"
777
+ ]);
778
+ }
779
+ function ke(e) {
780
+ return !1;
781
+ }
782
+ function Ae(e) {
783
+ return A(e) || me(e) ? e.value : e.textContent || "";
784
+ }
785
+ function F(e) {
786
+ var t = e.getPropertyValue("content");
787
+ return /^["'].*["']$/.test(t) ? t.slice(1, -1) : "";
788
+ }
789
+ function I(e) {
790
+ var t = D(e);
791
+ return t === "button" || t === "input" && e.getAttribute("type") !== "hidden" || t === "meter" || t === "output" || t === "progress" || t === "select" || t === "textarea";
792
+ }
793
+ function je(e) {
794
+ if (I(e)) return e;
795
+ var t = null;
796
+ return e.childNodes.forEach(function(e) {
797
+ if (t === null && k(e)) {
798
+ var n = je(e);
799
+ n !== null && (t = n);
800
+ }
801
+ }), t;
802
+ }
803
+ function Me(e) {
804
+ if (e.control !== void 0) return e.control;
805
+ var t = e.getAttribute("for");
806
+ return t === null ? je(e) : e.ownerDocument.getElementById(t);
807
+ }
808
+ function Ne(e) {
809
+ var t = e.labels;
810
+ if (t === null) return t;
811
+ if (t !== void 0) return x(t);
812
+ if (!I(e)) return null;
813
+ var n = e.ownerDocument;
814
+ return x(n.querySelectorAll("label")).filter(function(t) {
815
+ return Me(t) === e;
816
+ });
817
+ }
818
+ function Pe(e) {
819
+ var t = e.assignedNodes();
820
+ return t.length === 0 ? x(e.childNodes) : t;
821
+ }
822
+ function Fe(e) {
823
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = new ne(), r = he(e), i = t.compute, a = i === void 0 ? "name" : i, o = t.computedStyleSupportsPseudoElements, s = o === void 0 ? t.getComputedStyle !== void 0 : o, c = t.getComputedStyle, l = c === void 0 ? r.getComputedStyle.bind(r) : c, u = t.hidden, d = u === void 0 ? !1 : u;
824
+ function f(e, t) {
825
+ var n = "";
826
+ if (k(e) && s && (n = `${F(l(e, "::before"))} ${n}`), (ve(e) ? Pe(e) : x(e.childNodes).concat(j(e, "aria-owns"))).forEach(function(e) {
827
+ var r = g(e, {
828
+ isEmbeddedInLabel: t.isEmbeddedInLabel,
829
+ isReferenced: !1,
830
+ recursion: !0
831
+ }), i = (k(e) ? l(e).getPropertyValue("display") : "inline") === "inline" ? "" : " ";
832
+ n += `${i}${r}${i}`;
833
+ }), k(e) && s) {
834
+ var r = F(l(e, "::after"));
835
+ n = `${n} ${r}`;
836
+ }
837
+ return n.trim();
838
+ }
839
+ function p(e, t) {
840
+ var r = e.getAttributeNode(t);
841
+ return r !== null && !n.has(r) && r.value.trim() !== "" ? (n.add(r), r.value) : null;
842
+ }
843
+ function m(e) {
844
+ return k(e) ? p(e, "title") : null;
845
+ }
846
+ function h(e) {
847
+ if (!k(e)) return null;
848
+ if (ge(e)) {
849
+ n.add(e);
850
+ for (var t = x(e.childNodes), r = 0; r < t.length; r += 1) {
851
+ var i = t[r];
852
+ if (_e(i)) return g(i, {
853
+ isEmbeddedInLabel: !1,
854
+ isReferenced: !1,
855
+ recursion: !1
856
+ });
857
+ }
858
+ } else if (pe(e)) {
859
+ n.add(e);
860
+ for (var a = x(e.childNodes), o = 0; o < a.length; o += 1) {
861
+ var s = a[o];
862
+ if (ue(s)) return g(s, {
863
+ isEmbeddedInLabel: !1,
864
+ isReferenced: !1,
865
+ recursion: !1
866
+ });
867
+ }
868
+ } else if (be(e)) {
869
+ n.add(e);
870
+ for (var c = x(e.childNodes), l = 0; l < c.length; l += 1) {
871
+ var u = c[l];
872
+ if (xe(u)) return u.textContent;
873
+ }
874
+ return null;
875
+ } else if (D(e) === "img" || D(e) === "area") {
876
+ var d = p(e, "alt");
877
+ if (d !== null) return d;
878
+ } else if (de(e)) {
879
+ var m = p(e, "label");
880
+ if (m !== null) return m;
881
+ }
882
+ if (A(e) && (e.type === "button" || e.type === "submit" || e.type === "reset")) {
883
+ var h = p(e, "value");
884
+ if (h !== null) return h;
885
+ if (e.type === "submit") return "Submit";
886
+ if (e.type === "reset") return "Reset";
887
+ }
888
+ var _ = Ne(e);
889
+ if (_ !== null && _.length !== 0) return n.add(e), x(_).map(function(e) {
890
+ return g(e, {
891
+ isEmbeddedInLabel: !0,
892
+ isReferenced: !1,
893
+ recursion: !0
894
+ });
895
+ }).filter(function(e) {
896
+ return e.length > 0;
897
+ }).join(" ");
898
+ if (A(e) && e.type === "image") {
899
+ var v = p(e, "alt");
900
+ if (v !== null) return v;
901
+ var y = p(e, "title");
902
+ return y === null ? "Submit Query" : y;
903
+ }
904
+ if (M(e, ["button"])) {
905
+ var b = f(e, {
906
+ isEmbeddedInLabel: !1,
907
+ isReferenced: !1
908
+ });
909
+ if (b !== "") return b;
910
+ }
911
+ return null;
912
+ }
913
+ function g(e, t) {
914
+ if (n.has(e)) return "";
915
+ if (!d && Ce(e, l) && !t.isReferenced) return n.add(e), "";
916
+ var r = k(e) ? e.getAttributeNode("aria-labelledby") : null, i = r !== null && !n.has(r) ? j(e, "aria-labelledby") : [];
917
+ if (a === "name" && !t.isReferenced && i.length > 0) return n.add(r), i.map(function(e) {
918
+ return g(e, {
919
+ isEmbeddedInLabel: t.isEmbeddedInLabel,
920
+ isReferenced: !0,
921
+ recursion: !1
922
+ });
923
+ }).join(" ");
924
+ var o = t.recursion && we(e) && a === "name";
925
+ if (!o) {
926
+ var s = (k(e) && e.getAttribute("aria-label") || "").trim();
927
+ if (s !== "" && a === "name") return n.add(e), s;
928
+ if (!Ee(e)) {
929
+ var c = h(e);
930
+ if (c !== null) return n.add(e), c;
931
+ }
932
+ }
933
+ if (M(e, ["menu"])) return n.add(e), "";
934
+ if (o || t.isEmbeddedInLabel || t.isReferenced) {
935
+ if (M(e, ["combobox", "listbox"])) {
936
+ n.add(e);
937
+ var u = Te(e);
938
+ return u.length === 0 ? A(e) ? e.value : "" : x(u).map(function(e) {
939
+ return g(e, {
940
+ isEmbeddedInLabel: t.isEmbeddedInLabel,
941
+ isReferenced: !1,
942
+ recursion: !0
943
+ });
944
+ }).join(" ");
945
+ }
946
+ if (N(e, "range")) return n.add(e), e.hasAttribute("aria-valuetext") ? e.getAttribute("aria-valuetext") : e.hasAttribute("aria-valuenow") ? e.getAttribute("aria-valuenow") : e.getAttribute("value") || "";
947
+ if (M(e, ["textbox"])) return n.add(e), Ae(e);
948
+ }
949
+ if (Oe(e) || k(e) && t.isReferenced || De(e) || ke(e)) {
950
+ var p = f(e, {
951
+ isEmbeddedInLabel: t.isEmbeddedInLabel,
952
+ isReferenced: !1
953
+ });
954
+ if (p !== "") return n.add(e), p;
955
+ }
956
+ if (e.nodeType === e.TEXT_NODE) return n.add(e), e.textContent || "";
957
+ if (t.recursion) return n.add(e), f(e, {
958
+ isEmbeddedInLabel: t.isEmbeddedInLabel,
959
+ isReferenced: !1
960
+ });
961
+ var _ = m(e);
962
+ return _ === null ? (n.add(e), "") : (n.add(e), _);
963
+ }
964
+ return Se(g(e, {
965
+ isEmbeddedInLabel: !1,
966
+ isReferenced: a === "description",
967
+ recursion: !1
968
+ }));
969
+ }
970
+ //#endregion
971
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-description.mjs
972
+ function L(e) {
973
+ "@babel/helpers - typeof";
974
+ return L = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
975
+ return typeof e;
976
+ } : function(e) {
977
+ return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
978
+ }, L(e);
979
+ }
980
+ function Ie(e, t) {
981
+ var n = Object.keys(e);
982
+ if (Object.getOwnPropertySymbols) {
983
+ var r = Object.getOwnPropertySymbols(e);
984
+ t && (r = r.filter(function(t) {
985
+ return Object.getOwnPropertyDescriptor(e, t).enumerable;
986
+ })), n.push.apply(n, r);
987
+ }
988
+ return n;
989
+ }
990
+ function Le(e) {
991
+ for (var t = 1; t < arguments.length; t++) {
992
+ var n = arguments[t] == null ? {} : arguments[t];
993
+ t % 2 ? Ie(Object(n), !0).forEach(function(t) {
994
+ Re(e, t, n[t]);
995
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Ie(Object(n)).forEach(function(t) {
996
+ Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
997
+ });
998
+ }
999
+ return e;
1000
+ }
1001
+ function Re(e, t, n) {
1002
+ return t = ze(t), t in e ? Object.defineProperty(e, t, {
1003
+ value: n,
1004
+ enumerable: !0,
1005
+ configurable: !0,
1006
+ writable: !0
1007
+ }) : e[t] = n, e;
1008
+ }
1009
+ function ze(e) {
1010
+ var t = Be(e, "string");
1011
+ return L(t) === "symbol" ? t : String(t);
1012
+ }
1013
+ function Be(e, t) {
1014
+ if (L(e) !== "object" || e === null) return e;
1015
+ var n = e[Symbol.toPrimitive];
1016
+ if (n !== void 0) {
1017
+ var r = n.call(e, t || "default");
1018
+ if (L(r) !== "object") return r;
1019
+ throw TypeError("@@toPrimitive must return a primitive value.");
1020
+ }
1021
+ return (t === "string" ? String : Number)(e);
1022
+ }
1023
+ function Ve(e) {
1024
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = j(e, "aria-describedby").map(function(e) {
1025
+ return Fe(e, Le(Le({}, t), {}, { compute: "description" }));
1026
+ }).join(" ");
1027
+ if (n === "") {
1028
+ var r = e.getAttribute("aria-description");
1029
+ n = r === null ? "" : r;
1030
+ }
1031
+ if (n === "") {
1032
+ var i = e.getAttribute("title");
1033
+ n = i === null ? "" : i;
1034
+ }
1035
+ return n;
1036
+ }
1037
+ //#endregion
1038
+ //#region node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-name.mjs
1039
+ function He(e) {
1040
+ return M(e, [
1041
+ "caption",
1042
+ "code",
1043
+ "deletion",
1044
+ "emphasis",
1045
+ "generic",
1046
+ "insertion",
1047
+ "none",
1048
+ "paragraph",
1049
+ "presentation",
1050
+ "strong",
1051
+ "subscript",
1052
+ "superscript"
1053
+ ]);
1054
+ }
1055
+ function Ue(e) {
1056
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
1057
+ return He(e) ? "" : Fe(e, t);
1058
+ }
1059
+ //#endregion
1060
+ //#region node_modules/picocolors/picocolors.browser.js
1061
+ var We = /* @__PURE__ */ t(((e, t) => {
1062
+ var n = String, r = function() {
1063
+ return {
1064
+ isColorSupported: !1,
1065
+ reset: n,
1066
+ bold: n,
1067
+ dim: n,
1068
+ italic: n,
1069
+ underline: n,
1070
+ inverse: n,
1071
+ hidden: n,
1072
+ strikethrough: n,
1073
+ black: n,
1074
+ red: n,
1075
+ green: n,
1076
+ yellow: n,
1077
+ blue: n,
1078
+ magenta: n,
1079
+ cyan: n,
1080
+ white: n,
1081
+ gray: n,
1082
+ bgBlack: n,
1083
+ bgRed: n,
1084
+ bgGreen: n,
1085
+ bgYellow: n,
1086
+ bgBlue: n,
1087
+ bgMagenta: n,
1088
+ bgCyan: n,
1089
+ bgWhite: n,
1090
+ blackBright: n,
1091
+ redBright: n,
1092
+ greenBright: n,
1093
+ yellowBright: n,
1094
+ blueBright: n,
1095
+ magentaBright: n,
1096
+ cyanBright: n,
1097
+ whiteBright: n,
1098
+ bgBlackBright: n,
1099
+ bgRedBright: n,
1100
+ bgGreenBright: n,
1101
+ bgYellowBright: n,
1102
+ bgBlueBright: n,
1103
+ bgMagentaBright: n,
1104
+ bgCyanBright: n,
1105
+ bgWhiteBright: n
1106
+ };
1107
+ };
1108
+ t.exports = r(), t.exports.createColors = r;
1109
+ })), Ge = /* @__PURE__ */ t(((e, t) => {
1110
+ (function(n, r) {
1111
+ typeof e == "object" ? t.exports = r(n) : typeof define == "function" && define.amd ? define([], r.bind(n, n)) : r(n);
1112
+ })(typeof global < "u" ? global : e, function(e) {
1113
+ if (e.CSS && e.CSS.escape) return e.CSS.escape;
1114
+ var t = function(e) {
1115
+ if (arguments.length == 0) throw TypeError("`CSS.escape` requires an argument.");
1116
+ for (var t = String(e), n = t.length, r = -1, i, a = "", o = t.charCodeAt(0); ++r < n;) {
1117
+ if (i = t.charCodeAt(r), i == 0) {
1118
+ a += "�";
1119
+ continue;
1120
+ }
1121
+ if (i >= 1 && i <= 31 || i == 127 || r == 0 && i >= 48 && i <= 57 || r == 1 && i >= 48 && i <= 57 && o == 45) {
1122
+ a += "\\" + i.toString(16) + " ";
1123
+ continue;
1124
+ }
1125
+ if (r == 0 && n == 1 && i == 45) {
1126
+ a += "\\" + t.charAt(r);
1127
+ continue;
1128
+ }
1129
+ if (i >= 128 || i == 45 || i == 95 || i >= 48 && i <= 57 || i >= 65 && i <= 90 || i >= 97 && i <= 122) {
1130
+ a += t.charAt(r);
1131
+ continue;
1132
+ }
1133
+ a += "\\" + t.charAt(r);
1134
+ }
1135
+ return a;
1136
+ };
1137
+ return e.CSS ||= {}, e.CSS.escape = t, t;
1138
+ });
1139
+ })), R = n(), Ke = /* @__PURE__ */ e(We(), 1), qe = /* @__PURE__ */ e(Ge(), 1), Je = class extends Error {
1140
+ constructor(e, t, n, r) {
1141
+ /* istanbul ignore next */
1142
+ super(), Error.captureStackTrace && Error.captureStackTrace(this, n);
1143
+ let i = "";
1144
+ try {
1145
+ i = r.utils.printWithType("Received", t, r.utils.printReceived);
1146
+ } catch {}
1147
+ this.message = [
1148
+ r.utils.matcherHint(`${r.isNot ? ".not" : ""}.${n.name}`, "received", ""),
1149
+ "",
1150
+ `${r.utils.RECEIVED_COLOR("received")} value must ${e}.`,
1151
+ i
1152
+ ].join("\n");
1153
+ }
1154
+ }, Ye = class extends Je {
1155
+ constructor(...e) {
1156
+ super("be an HTMLElement or an SVGElement", ...e);
1157
+ }
1158
+ }, Xe = class extends Je {
1159
+ constructor(...e) {
1160
+ super("be a Node", ...e);
1161
+ }
1162
+ };
1163
+ function Ze(e, t, ...n) {
1164
+ if (!e || !e.ownerDocument || !e.ownerDocument.defaultView) throw new t(e, ...n);
1165
+ }
1166
+ function Qe(e, ...t) {
1167
+ if (Ze(e, Xe, ...t), !(e instanceof e.ownerDocument.defaultView.Node)) throw new Xe(e, ...t);
1168
+ }
1169
+ function z(e, ...t) {
1170
+ Ze(e, Ye, ...t);
1171
+ let n = e.ownerDocument.defaultView;
1172
+ if (!(e instanceof n.HTMLElement) && !(e instanceof n.SVGElement)) throw new Ye(e, ...t);
1173
+ }
1174
+ var $e = class extends Error {
1175
+ constructor(e, t, n) {
1176
+ super(), Error.captureStackTrace && Error.captureStackTrace(this, t), this.message = [
1177
+ e.message,
1178
+ "",
1179
+ n.utils.RECEIVED_COLOR("Failing css:"),
1180
+ n.utils.RECEIVED_COLOR(`${e.css}`)
1181
+ ].join("\n");
1182
+ }
1183
+ };
1184
+ function et(e, ...t) {
1185
+ let n = h(`selector { ${e} }`, { silent: !0 }).stylesheet;
1186
+ if (n.parsingErrors && n.parsingErrors.length > 0) {
1187
+ let { reason: r, line: i } = n.parsingErrors[0];
1188
+ throw new $e({
1189
+ css: e,
1190
+ message: `Syntax error parsing expected css: ${r} on line: ${i}`
1191
+ }, ...t);
1192
+ }
1193
+ return n.rules[0].declarations.filter((e) => e.type === "declaration").reduce((e, { property: t, value: n }) => Object.assign(e, { [t]: n }), {});
1194
+ }
1195
+ function tt(e, t) {
1196
+ return typeof t == "string" ? t : e.utils.stringify(t);
1197
+ }
1198
+ function B(e, t, n, r, i, a) {
1199
+ return [
1200
+ `${t}\n`,
1201
+ `${n}:\n${e.utils.EXPECTED_COLOR((0, o.default)(tt(e, r), 2))}`,
1202
+ `${i}:\n${e.utils.RECEIVED_COLOR((0, o.default)(tt(e, a), 2))}`
1203
+ ].join("\n");
1204
+ }
1205
+ function nt(e, t) {
1206
+ return t instanceof RegExp ? t.test(e) : e.includes(String(t));
1207
+ }
1208
+ function V(e, t) {
1209
+ console.warn(`Warning: ${e} has been deprecated and will be removed in future updates.`, t);
1210
+ }
1211
+ function H(e) {
1212
+ return e.replace(/\s+/g, " ").trim();
1213
+ }
1214
+ function U(e) {
1215
+ return e.tagName && e.tagName.toLowerCase();
1216
+ }
1217
+ function rt({ multiple: e, options: t }) {
1218
+ let n = [...t].filter((e) => e.selected);
1219
+ if (e) return [...n].map((e) => e.value);
1220
+ if (n.length !== 0) return n[0].value;
1221
+ }
1222
+ function it(e) {
1223
+ switch (e.type) {
1224
+ case "number": return e.value === "" ? null : Number(e.value);
1225
+ case "checkbox": return e.checked;
1226
+ default: return e.value;
1227
+ }
1228
+ }
1229
+ var at = [
1230
+ "meter",
1231
+ "progressbar",
1232
+ "slider",
1233
+ "spinbutton"
1234
+ ];
1235
+ function ot(e) {
1236
+ if (at.includes(e.getAttribute("role"))) return Number(e.getAttribute("aria-valuenow"));
1237
+ }
1238
+ function st(e) {
1239
+ if (e) switch (e.tagName.toLowerCase()) {
1240
+ case "input": return it(e);
1241
+ case "select": return rt(e);
1242
+ default: return e.value ?? ot(e);
1243
+ }
1244
+ }
1245
+ function ct(e, { wordConnector: t = ", ", lastWordConnector: n = " and " } = {}) {
1246
+ return [e.slice(0, -1).join(t), e[e.length - 1]].join(e.length > 1 ? n : "");
1247
+ }
1248
+ function W(e, t) {
1249
+ return Array.isArray(e) && Array.isArray(t) ? [...new Set(e)].every((e) => new Set(t).has(e)) : e === t;
1250
+ }
1251
+ function G(e, t) {
1252
+ return V("toBeInTheDOM", "Please use toBeInTheDocument for searching the entire document and toContainElement for searching a specific container."), e && z(e, G, this), t && z(t, G, this), {
1253
+ pass: t ? t.contains(e) : !!e,
1254
+ message: () => [
1255
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInTheDOM`, "element", ""),
1256
+ "",
1257
+ "Received:",
1258
+ ` ${this.utils.printReceived(e && e.cloneNode(!1))}`
1259
+ ].join("\n")
1260
+ };
1261
+ }
1262
+ function lt(e) {
1263
+ (e !== null || !this.isNot) && z(e, lt, this);
1264
+ let t = e === null ? !1 : e.ownerDocument === e.getRootNode({ composed: !0 }), n = () => `expected document not to contain element, found ${this.utils.stringify(e.cloneNode(!0))} instead`, r = () => "element could not be found in the document";
1265
+ return {
1266
+ pass: t,
1267
+ message: () => [
1268
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInTheDocument`, "element", ""),
1269
+ "",
1270
+ this.utils.RECEIVED_COLOR(this.isNot ? n() : r())
1271
+ ].join("\n")
1272
+ };
1273
+ }
1274
+ function ut(e) {
1275
+ return V("toBeEmpty", "Please use instead toBeEmptyDOMElement for finding empty nodes in the DOM."), z(e, ut, this), {
1276
+ pass: e.innerHTML === "",
1277
+ message: () => [
1278
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEmpty`, "element", ""),
1279
+ "",
1280
+ "Received:",
1281
+ ` ${this.utils.printReceived(e.innerHTML)}`
1282
+ ].join("\n")
1283
+ };
1284
+ }
1285
+ function dt(e) {
1286
+ return z(e, dt, this), {
1287
+ pass: ft(e),
1288
+ message: () => [
1289
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEmptyDOMElement`, "element", ""),
1290
+ "",
1291
+ "Received:",
1292
+ ` ${this.utils.printReceived(e.innerHTML)}`
1293
+ ].join("\n")
1294
+ };
1295
+ }
1296
+ function ft(e) {
1297
+ return [...e.childNodes].filter((e) => e.nodeType !== 8).length === 0;
1298
+ }
1299
+ function K(e, t) {
1300
+ return z(e, K, this), t !== null && z(t, K, this), {
1301
+ pass: e.contains(t),
1302
+ message: () => [
1303
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toContainElement`, "element", "element"),
1304
+ "",
1305
+ this.utils.RECEIVED_COLOR(`${this.utils.stringify(e.cloneNode(!1))} ${this.isNot ? "contains:" : "does not contain:"} ${this.utils.stringify(t && t.cloneNode(!1))}
1306
+ `)
1307
+ ].join("\n")
1308
+ };
1309
+ }
1310
+ function pt(e, t) {
1311
+ let n = e.ownerDocument.createElement("div");
1312
+ return n.innerHTML = t, n.innerHTML;
1313
+ }
1314
+ function mt(e, t) {
1315
+ if (z(e, mt, this), typeof t != "string") throw Error(`.toContainHTML() expects a string value, got ${t}`);
1316
+ return {
1317
+ pass: e.outerHTML.includes(pt(e, t)),
1318
+ message: () => [
1319
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toContainHTML`, "element", ""),
1320
+ "Expected:",
1321
+ ` ${this.utils.EXPECTED_COLOR(t)}`,
1322
+ "Received:",
1323
+ ` ${this.utils.printReceived(e.cloneNode(!0))}`
1324
+ ].join("\n")
1325
+ };
1326
+ }
1327
+ function ht(e, t, n = { normalizeWhitespace: !0 }) {
1328
+ Qe(e, ht, this);
1329
+ let r = n.normalizeWhitespace ? H(e.textContent) : e.textContent.replace(/\u00a0/g, " "), i = r !== "" && t === "";
1330
+ return {
1331
+ pass: !i && nt(r, t),
1332
+ message: () => {
1333
+ let e = this.isNot ? "not to" : "to";
1334
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveTextContent`, "element", ""), i ? "Checking with empty string will always match, use .toBeEmptyDOMElement() instead" : `Expected element ${e} have text content`, t, "Received", r);
1335
+ }
1336
+ };
1337
+ }
1338
+ function q(e, t) {
1339
+ z(e, q, this);
1340
+ let n = Ve(e), r = arguments.length === 1, i = !1;
1341
+ return i = r ? n !== "" : t instanceof RegExp ? t.test(n) : this.equals(n, t), {
1342
+ pass: i,
1343
+ message: () => {
1344
+ let e = this.isNot ? "not to" : "to";
1345
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${q.name}`, "element", ""), `Expected element ${e} have accessible description`, t, "Received", n);
1346
+ }
1347
+ };
1348
+ }
1349
+ var J = "aria-invalid", gt = ["false"];
1350
+ function _t(e, t) {
1351
+ z(e, _t, this);
1352
+ let n = this.isNot ? "not to" : "to", r = this.isNot ? ".not.toHaveAccessibleErrorMessage" : ".toHaveAccessibleErrorMessage", i = e.getAttribute("aria-errormessage");
1353
+ if (i && /\s+/.test(i)) return {
1354
+ pass: !1,
1355
+ message: () => B(this, this.utils.matcherHint(r, "element"), "Expected element's `aria-errormessage` attribute to be empty or a single, valid ID", "", "Received", `aria-errormessage="${i}"`)
1356
+ };
1357
+ let a = e.getAttribute(J);
1358
+ if (!e.hasAttribute(J) || gt.includes(a)) return {
1359
+ pass: !1,
1360
+ message: () => B(this, this.utils.matcherHint(r, "element"), "Expected element to be marked as invalid with attribute", `${J}="true"`, "Received", e.hasAttribute("aria-invalid") ? `${J}="${e.getAttribute(J)}` : null)
1361
+ };
1362
+ let o = H(e.ownerDocument.getElementById(i)?.textContent ?? "");
1363
+ return {
1364
+ pass: t === void 0 ? !!o : t instanceof RegExp ? t.test(o) : this.equals(o, t),
1365
+ message: () => B(this, this.utils.matcherHint(r, "element"), `Expected element ${n} have accessible error message`, t ?? "", "Received", o)
1366
+ };
1367
+ }
1368
+ var vt = xt(R.elementRoles);
1369
+ function Y(e, t) {
1370
+ z(e, Y, this);
1371
+ let n = yt(e);
1372
+ return {
1373
+ pass: n.some((e) => e === t),
1374
+ message: () => {
1375
+ let e = this.isNot ? "not to" : "to";
1376
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${Y.name}`, "element", ""), `Expected element ${e} have role`, t, "Received", n.join(", "));
1377
+ }
1378
+ };
1379
+ }
1380
+ function yt(e) {
1381
+ return e.hasAttribute("role") ? e.getAttribute("role").split(" ").filter(Boolean) : bt(e);
1382
+ }
1383
+ function bt(e) {
1384
+ for (let { match: t, roles: n } of vt) if (t(e)) return [...n];
1385
+ /* istanbul ignore next */
1386
+ return [];
1387
+ }
1388
+ function xt(e) {
1389
+ function t({ name: e, attributes: t }) {
1390
+ return `${e}${t.map(({ name: e, value: t, constraints: n = [] }) => n.indexOf("undefined") === -1 ? t ? `[${e}="${t}"]` : `[${e}]` : `:not([${e}])`).join("")}`;
1391
+ }
1392
+ function n({ attributes: e = [] }) {
1393
+ return e.length;
1394
+ }
1395
+ function r({ specificity: e }, { specificity: t }) {
1396
+ return t - e;
1397
+ }
1398
+ function i(e) {
1399
+ let { attributes: n = [] } = e, r = n.findIndex((e) => e.value && e.name === "type" && e.value === "text");
1400
+ r >= 0 && (n = [...n.slice(0, r), ...n.slice(r + 1)]);
1401
+ let i = t({
1402
+ ...e,
1403
+ attributes: n
1404
+ });
1405
+ return (e) => r >= 0 && e.type !== "text" ? !1 : e.matches(i);
1406
+ }
1407
+ let a = [];
1408
+ for (let [t, r] of e.entries()) a = [...a, {
1409
+ match: i(t),
1410
+ roles: Array.from(r),
1411
+ specificity: n(t)
1412
+ }];
1413
+ return a.sort(r);
1414
+ }
1415
+ function X(e, t) {
1416
+ z(e, X, this);
1417
+ let n = Ue(e), r = arguments.length === 1, i = !1;
1418
+ return i = r ? n !== "" : t instanceof RegExp ? t.test(n) : this.equals(n, t), {
1419
+ pass: i,
1420
+ message: () => {
1421
+ let e = this.isNot ? "not to" : "to";
1422
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${X.name}`, "element", ""), `Expected element ${e} have accessible name`, t, "Received", n);
1423
+ }
1424
+ };
1425
+ }
1426
+ function St(e, t, n) {
1427
+ return n === void 0 ? t : `${t}=${e(n)}`;
1428
+ }
1429
+ function Ct(e, t, n) {
1430
+ return n === void 0 ? `element.hasAttribute(${e(t)})` : `element.getAttribute(${e(t)}) === ${e(n)}`;
1431
+ }
1432
+ function wt(e, t, n) {
1433
+ z(e, wt, this);
1434
+ let r = n !== void 0, i = e.hasAttribute(t), a = e.getAttribute(t);
1435
+ return {
1436
+ pass: r ? i && this.equals(a, n) : i,
1437
+ message: () => {
1438
+ let e = this.isNot ? "not to" : "to", o = i ? St(this.utils.stringify, t, a) : null, s = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveAttribute`, "element", this.utils.printExpected(t), {
1439
+ secondArgument: r ? this.utils.printExpected(n) : void 0,
1440
+ comment: Ct(this.utils.stringify, t, n)
1441
+ });
1442
+ return B(this, s, `Expected the element ${e} have attribute`, St(this.utils.stringify, t, n), "Received", o);
1443
+ }
1444
+ };
1445
+ }
1446
+ function Tt(e) {
1447
+ let t = e.pop(), n, r;
1448
+ return typeof t == "object" && !(t instanceof RegExp) ? (n = e, r = t) : (n = e.concat(t), r = { exact: !1 }), {
1449
+ expectedClassNames: n,
1450
+ options: r
1451
+ };
1452
+ }
1453
+ function Et(e) {
1454
+ return e ? e.split(/\s+/).filter((e) => e.length > 0) : [];
1455
+ }
1456
+ function Dt(e, t) {
1457
+ return e.every((e) => typeof e == "string" ? t.includes(e) : t.some((t) => e.test(t)));
1458
+ }
1459
+ function Ot(e, ...t) {
1460
+ z(e, Ot, this);
1461
+ let { expectedClassNames: n, options: r } = Tt(t), i = Et(e.getAttribute("class")), a = n.reduce((e, t) => e.concat(typeof t == "string" || !t ? Et(t) : t), []), o = a.some((e) => e instanceof RegExp);
1462
+ if (r.exact && o) throw Error("Exact option does not support RegExp expected class names");
1463
+ return r.exact ? {
1464
+ pass: Dt(a, i) && a.length === i.length,
1465
+ message: () => {
1466
+ let e = this.isNot ? "not to" : "to";
1467
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveClass`, "element", this.utils.printExpected(a.join(" "))), `Expected the element ${e} have EXACTLY defined classes`, a.join(" "), "Received", i.join(" "));
1468
+ }
1469
+ } : a.length > 0 ? {
1470
+ pass: Dt(a, i),
1471
+ message: () => {
1472
+ let e = this.isNot ? "not to" : "to";
1473
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveClass`, "element", this.utils.printExpected(a.join(" "))), `Expected the element ${e} have class`, a.join(" "), "Received", i.join(" "));
1474
+ }
1475
+ } : {
1476
+ pass: this.isNot ? i.length > 0 : !1,
1477
+ message: () => this.isNot ? B(this, this.utils.matcherHint(".not.toHaveClass", "element", ""), "Expected the element to have classes", "(none)", "Received", i.join(" ")) : [this.utils.matcherHint(".toHaveClass", "element"), "At least one expected class must be provided."].join("\n")
1478
+ };
1479
+ }
1480
+ function kt(e, t) {
1481
+ let n = {}, r = e.createElement("div");
1482
+ return Object.keys(t).forEach((e) => {
1483
+ r.style[e] = t[e], n[e] = r.style[e];
1484
+ }), n;
1485
+ }
1486
+ function At(e, t) {
1487
+ return !!Object.keys(e).length && Object.entries(e).every(([e, n]) => {
1488
+ let r = e.startsWith("--"), i = [e];
1489
+ return r || i.push(e.toLowerCase()), i.some((e) => t[e] === n || t.getPropertyValue(e) === n);
1490
+ });
1491
+ }
1492
+ function jt(e) {
1493
+ return Object.keys(e).sort().map((t) => `${t}: ${e[t]};`).join("\n");
1494
+ }
1495
+ function Mt(e, t, n) {
1496
+ let r = Array.from(n).filter((e) => t[e] !== void 0).reduce((e, t) => Object.assign(e, { [t]: n.getPropertyValue(t) }), {});
1497
+ return e(jt(t), jt(r)).replace(`${Ke.default.red("+ Received")}\n`, "");
1498
+ }
1499
+ function Z(e, t) {
1500
+ z(e, Z, this);
1501
+ let n = typeof t == "object" ? t : et(t, Z, this), { getComputedStyle: r } = e.ownerDocument.defaultView, i = kt(e.ownerDocument, n), a = r(e);
1502
+ return {
1503
+ pass: At(i, a),
1504
+ message: () => {
1505
+ let e = `${this.isNot ? ".not" : ""}.toHaveStyle`;
1506
+ return [this.utils.matcherHint(e, "element", ""), Mt(this.utils.diff, i, a)].join("\n\n");
1507
+ }
1508
+ };
1509
+ }
1510
+ function Nt(e) {
1511
+ return z(e, Nt, this), {
1512
+ pass: e.ownerDocument.activeElement === e,
1513
+ message: () => [
1514
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveFocus`, "element", ""),
1515
+ "",
1516
+ ...this.isNot ? ["Received element is focused:", ` ${this.utils.printReceived(e)}`] : [
1517
+ "Expected element with focus:",
1518
+ ` ${this.utils.printExpected(e)}`,
1519
+ "Received element with focus:",
1520
+ ` ${this.utils.printReceived(e.ownerDocument.activeElement)}`
1521
+ ]
1522
+ ].join("\n")
1523
+ };
1524
+ }
1525
+ function Pt(e) {
1526
+ let t = [...new Set(e.map((e) => e.type))];
1527
+ if (t.length !== 1) throw Error("Multiple form elements with the same name must be of the same type");
1528
+ switch (t[0]) {
1529
+ case "radio": {
1530
+ let t = e.find((e) => e.checked);
1531
+ return t ? t.value : void 0;
1532
+ }
1533
+ case "checkbox": return e.filter((e) => e.checked).map((e) => e.value);
1534
+ default: return e.map((e) => e.value);
1535
+ }
1536
+ }
1537
+ function Ft(e, t) {
1538
+ let n = [...e.querySelectorAll(`[name="${(0, qe.default)(t)}"]`)];
1539
+ if (n.length !== 0) switch (n.length) {
1540
+ case 1: return st(n[0]);
1541
+ default: return Pt(n);
1542
+ }
1543
+ }
1544
+ function It(e) {
1545
+ return /\[\]$/.test(e) ? e.slice(0, -2) : e;
1546
+ }
1547
+ function Lt(e) {
1548
+ return Array.from(e.elements).map((e) => e.name).reduce((t, n) => ({
1549
+ ...t,
1550
+ [It(n)]: Ft(e, n)
1551
+ }), {});
1552
+ }
1553
+ function Rt(e, t) {
1554
+ if (z(e, Rt, this), !e.elements) throw Error("toHaveFormValues must be called on a form or a fieldset");
1555
+ let n = Lt(e);
1556
+ return {
1557
+ pass: Object.entries(t).every(([e, t]) => W(n[e], t)),
1558
+ message: () => {
1559
+ let e = this.isNot ? "not to" : "to", r = `${this.isNot ? ".not" : ""}.toHaveFormValues`, i = Object.keys(n).filter((e) => t.hasOwnProperty(e)).reduce((e, t) => ({
1560
+ ...e,
1561
+ [t]: n[t]
1562
+ }), {});
1563
+ return [
1564
+ this.utils.matcherHint(r, "element", ""),
1565
+ `Expected the element ${e} have form values`,
1566
+ this.utils.diff(t, i)
1567
+ ].join("\n\n");
1568
+ }
1569
+ };
1570
+ }
1571
+ function zt(e) {
1572
+ let { getComputedStyle: t } = e.ownerDocument.defaultView, { display: n, visibility: r, opacity: i } = t(e);
1573
+ return n !== "none" && r !== "hidden" && r !== "collapse" && i !== "0" && i !== 0;
1574
+ }
1575
+ function Bt(e, t) {
1576
+ let n;
1577
+ return n = t ? e.nodeName === "DETAILS" && t.nodeName !== "SUMMARY" ? e.hasAttribute("open") : !0 : e.nodeName === "DETAILS" ? e.hasAttribute("open") : !0, !e.hasAttribute("hidden") && n;
1578
+ }
1579
+ function Vt(e, t) {
1580
+ return zt(e) && Bt(e, t) && (!e.parentElement || Vt(e.parentElement, e));
1581
+ }
1582
+ function Ht(e) {
1583
+ z(e, Ht, this);
1584
+ let t = e.ownerDocument === e.getRootNode({ composed: !0 }), n = t && Vt(e);
1585
+ return {
1586
+ pass: n,
1587
+ message: () => {
1588
+ let r = n ? "is" : "is not";
1589
+ return [
1590
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeVisible`, "element", ""),
1591
+ "",
1592
+ `Received element ${r} visible${t ? "" : " (element is not in the document)"}:`,
1593
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1594
+ ].join("\n");
1595
+ }
1596
+ };
1597
+ }
1598
+ var Ut = [
1599
+ "fieldset",
1600
+ "input",
1601
+ "select",
1602
+ "optgroup",
1603
+ "option",
1604
+ "button",
1605
+ "textarea"
1606
+ ];
1607
+ function Wt(e, t) {
1608
+ return U(e) === "legend" && U(t) === "fieldset" && e.isSameNode(Array.from(t.children).find((e) => U(e) === "legend"));
1609
+ }
1610
+ function Gt(e, t) {
1611
+ return Jt(t) && !Wt(e, t);
1612
+ }
1613
+ function Kt(e) {
1614
+ return e.includes("-");
1615
+ }
1616
+ function qt(e) {
1617
+ let t = U(e);
1618
+ return Ut.includes(t) || Kt(t);
1619
+ }
1620
+ function Jt(e) {
1621
+ return qt(e) && e.hasAttribute("disabled");
1622
+ }
1623
+ function Yt(e) {
1624
+ let t = e.parentElement;
1625
+ return !!t && (Gt(e, t) || Yt(t));
1626
+ }
1627
+ function Xt(e) {
1628
+ return qt(e) && (Jt(e) || Yt(e));
1629
+ }
1630
+ function Zt(e) {
1631
+ z(e, Zt, this);
1632
+ let t = Xt(e);
1633
+ return {
1634
+ pass: t,
1635
+ message: () => {
1636
+ let n = t ? "is" : "is not";
1637
+ return [
1638
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeDisabled`, "element", ""),
1639
+ "",
1640
+ `Received element ${n} disabled:`,
1641
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1642
+ ].join("\n");
1643
+ }
1644
+ };
1645
+ }
1646
+ function Qt(e) {
1647
+ z(e, Qt, this);
1648
+ let t = !Xt(e);
1649
+ return {
1650
+ pass: t,
1651
+ message: () => {
1652
+ let n = t ? "is" : "is not";
1653
+ return [
1654
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEnabled`, "element", ""),
1655
+ "",
1656
+ `Received element ${n} enabled:`,
1657
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1658
+ ].join("\n");
1659
+ }
1660
+ };
1661
+ }
1662
+ var $t = ["select", "textarea"], en = [
1663
+ "input",
1664
+ "select",
1665
+ "textarea"
1666
+ ], tn = [
1667
+ "color",
1668
+ "hidden",
1669
+ "range",
1670
+ "submit",
1671
+ "image",
1672
+ "reset"
1673
+ ], nn = [
1674
+ "checkbox",
1675
+ "combobox",
1676
+ "gridcell",
1677
+ "listbox",
1678
+ "radiogroup",
1679
+ "spinbutton",
1680
+ "textbox",
1681
+ "tree"
1682
+ ];
1683
+ function rn(e) {
1684
+ return $t.includes(U(e)) && e.hasAttribute("required");
1685
+ }
1686
+ function an(e) {
1687
+ return U(e) === "input" && e.hasAttribute("required") && (e.hasAttribute("type") && !tn.includes(e.getAttribute("type")) || !e.hasAttribute("type"));
1688
+ }
1689
+ function on(e) {
1690
+ return e.hasAttribute("aria-required") && e.getAttribute("aria-required") === "true" && (en.includes(U(e)) || e.hasAttribute("role") && nn.includes(e.getAttribute("role")));
1691
+ }
1692
+ function sn(e) {
1693
+ z(e, sn, this);
1694
+ let t = rn(e) || an(e) || on(e);
1695
+ return {
1696
+ pass: t,
1697
+ message: () => {
1698
+ let n = t ? "is" : "is not";
1699
+ return [
1700
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeRequired`, "element", ""),
1701
+ "",
1702
+ `Received element ${n} required:`,
1703
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1704
+ ].join("\n");
1705
+ }
1706
+ };
1707
+ }
1708
+ var cn = [
1709
+ "form",
1710
+ "input",
1711
+ "select",
1712
+ "textarea"
1713
+ ];
1714
+ function ln(e) {
1715
+ return e.hasAttribute("aria-invalid") && e.getAttribute("aria-invalid") !== "false";
1716
+ }
1717
+ function un(e) {
1718
+ return cn.includes(U(e));
1719
+ }
1720
+ function dn(e) {
1721
+ let t = ln(e);
1722
+ return un(e) ? t || !e.checkValidity() : t;
1723
+ }
1724
+ function fn(e) {
1725
+ z(e, fn, this);
1726
+ let t = dn(e);
1727
+ return {
1728
+ pass: t,
1729
+ message: () => {
1730
+ let n = t ? "is" : "is not";
1731
+ return [
1732
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInvalid`, "element", ""),
1733
+ "",
1734
+ `Received element ${n} currently invalid:`,
1735
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1736
+ ].join("\n");
1737
+ }
1738
+ };
1739
+ }
1740
+ function pn(e) {
1741
+ z(e, pn, this);
1742
+ let t = !dn(e);
1743
+ return {
1744
+ pass: t,
1745
+ message: () => {
1746
+ let n = t ? "is" : "is not";
1747
+ return [
1748
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeValid`, "element", ""),
1749
+ "",
1750
+ `Received element ${n} currently valid:`,
1751
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1752
+ ].join("\n");
1753
+ }
1754
+ };
1755
+ }
1756
+ function mn(e, t) {
1757
+ if (z(e, mn, this), e.tagName.toLowerCase() === "input" && ["checkbox", "radio"].includes(e.type)) throw Error("input with type=checkbox or type=radio cannot be used with .toHaveValue(). Use .toBeChecked() for type=checkbox or .toHaveFormValues() instead");
1758
+ let n = st(e), r = t !== void 0, i = t, a = n;
1759
+ return t == n && t !== n && (i = `${t} (${typeof t})`, a = `${n} (${typeof n})`), {
1760
+ pass: r ? W(n, t) : !!n,
1761
+ message: () => {
1762
+ let e = this.isNot ? "not to" : "to", n = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveValue`, "element", t);
1763
+ return B(this, n, `Expected the element ${e} have value`, r ? i : "(any)", "Received", a);
1764
+ }
1765
+ };
1766
+ }
1767
+ function hn(e, t) {
1768
+ z(e, hn, this);
1769
+ let n = e.tagName.toLowerCase();
1770
+ if (![
1771
+ "select",
1772
+ "input",
1773
+ "textarea"
1774
+ ].includes(n)) throw Error(".toHaveDisplayValue() currently supports only input, textarea or select elements, try with another matcher instead.");
1775
+ if (n === "input" && ["radio", "checkbox"].includes(e.type)) throw Error(`.toHaveDisplayValue() currently does not support input[type="${e.type}"], try with another matcher instead.`);
1776
+ let r = gn(n, e), i = _n(t), a = i.filter((e) => r.some((t) => e instanceof RegExp ? e.test(t) : this.equals(t, String(e)))).length, o = a === r.length, s = a === i.length;
1777
+ return {
1778
+ pass: o && s,
1779
+ message: () => B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveDisplayValue`, "element", ""), `Expected element ${this.isNot ? "not " : ""}to have display value`, t, "Received", r)
1780
+ };
1781
+ }
1782
+ function gn(e, t) {
1783
+ return e === "select" ? Array.from(t).filter((e) => e.selected).map((e) => e.textContent) : [t.value];
1784
+ }
1785
+ function _n(e) {
1786
+ return e instanceof Array ? e : [e];
1787
+ }
1788
+ function vn(e) {
1789
+ z(e, vn, this);
1790
+ let t = () => e.tagName.toLowerCase() === "input" && ["checkbox", "radio"].includes(e.type);
1791
+ if (!t() && !(xn(e.getAttribute("role")) && ["true", "false"].includes(e.getAttribute("aria-checked")))) return {
1792
+ pass: !1,
1793
+ message: () => `only inputs with type="checkbox" or type="radio" or elements with ${yn()} and a valid aria-checked attribute can be used with .toBeChecked(). Use .toHaveValue() instead`
1794
+ };
1795
+ let n = () => t() ? e.checked : e.getAttribute("aria-checked") === "true";
1796
+ return {
1797
+ pass: n(),
1798
+ message: () => {
1799
+ let t = n() ? "is" : "is not";
1800
+ return [
1801
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeChecked`, "element", ""),
1802
+ "",
1803
+ `Received element ${t} checked:`,
1804
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1805
+ ].join("\n");
1806
+ }
1807
+ };
1808
+ }
1809
+ function yn() {
1810
+ return ct(bn().map((e) => `role="${e}"`), { lastWordConnector: " or " });
1811
+ }
1812
+ function bn() {
1813
+ return R.roles.keys().filter(xn);
1814
+ }
1815
+ function xn(e) {
1816
+ return R.roles.get(e)?.props["aria-checked"] !== void 0;
1817
+ }
1818
+ function Sn(e) {
1819
+ z(e, Sn, this);
1820
+ let t = () => e.tagName.toLowerCase() === "input" && e.type === "checkbox";
1821
+ if (!t() && e.getAttribute("role") !== "checkbox") return {
1822
+ pass: !1,
1823
+ message: () => "only inputs with type=\"checkbox\" or elements with role=\"checkbox\" and a valid aria-checked attribute can be used with .toBePartiallyChecked(). Use .toHaveValue() instead"
1824
+ };
1825
+ let n = () => {
1826
+ let n = e.getAttribute("aria-checked") === "mixed";
1827
+ return t() && e.indeterminate || n;
1828
+ };
1829
+ return {
1830
+ pass: n(),
1831
+ message: () => {
1832
+ let t = n() ? "is" : "is not";
1833
+ return [
1834
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePartiallyChecked`, "element", ""),
1835
+ "",
1836
+ `Received element ${t} partially checked:`,
1837
+ ` ${this.utils.printReceived(e.cloneNode(!1))}`
1838
+ ].join("\n");
1839
+ }
1840
+ };
1841
+ }
1842
+ function Cn(e, t) {
1843
+ V("toHaveDescription", "Please use toHaveAccessibleDescription."), z(e, Cn, this);
1844
+ let n = t !== void 0, r = (e.getAttribute("aria-describedby") || "").split(/\s+/).filter(Boolean), i = "";
1845
+ if (r.length > 0) {
1846
+ let t = e.ownerDocument;
1847
+ i = H(r.map((e) => t.getElementById(e)).filter(Boolean).map((e) => e.textContent).join(" "));
1848
+ }
1849
+ return {
1850
+ pass: n ? t instanceof RegExp ? t.test(i) : this.equals(i, t) : !!i,
1851
+ message: () => {
1852
+ let e = this.isNot ? "not to" : "to";
1853
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveDescription`, "element", ""), `Expected the element ${e} have description`, this.utils.printExpected(t), "Received", this.utils.printReceived(i));
1854
+ }
1855
+ };
1856
+ }
1857
+ function wn(e, t) {
1858
+ if (V("toHaveErrorMessage", "Please use toHaveAccessibleErrorMessage."), z(e, wn, this), !e.hasAttribute("aria-invalid") || e.getAttribute("aria-invalid") === "false") {
1859
+ let t = this.isNot ? ".not" : "";
1860
+ return {
1861
+ pass: !1,
1862
+ message: () => B(this, this.utils.matcherHint(`${t}.toHaveErrorMessage`, "element", ""), "Expected the element to have invalid state indicated by", "aria-invalid=\"true\"", "Received", e.hasAttribute("aria-invalid") ? `aria-invalid="${e.getAttribute("aria-invalid")}"` : this.utils.printReceived(""))
1863
+ };
1864
+ }
1865
+ let n = t !== void 0, r = (e.getAttribute("aria-errormessage") || "").split(/\s+/).filter(Boolean), i = "";
1866
+ if (r.length > 0) {
1867
+ let t = e.ownerDocument;
1868
+ i = H(r.map((e) => t.getElementById(e)).filter(Boolean).map((e) => e.textContent).join(" "));
1869
+ }
1870
+ return {
1871
+ pass: n ? t instanceof RegExp ? t.test(i) : this.equals(i, t) : !!i,
1872
+ message: () => {
1873
+ let e = this.isNot ? "not to" : "to";
1874
+ return B(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveErrorMessage`, "element", ""), `Expected the element ${e} have error message`, this.utils.printExpected(t), "Received", this.utils.printReceived(i));
1875
+ }
1876
+ };
1877
+ }
1878
+ function Tn(e) {
1879
+ let t = e.ownerDocument.getSelection();
1880
+ if (["input", "textarea"].includes(e.tagName.toLowerCase())) return ["radio", "checkbox"].includes(e.type) ? "" : e.value.toString().substring(e.selectionStart, e.selectionEnd);
1881
+ if (t.anchorNode === null || t.focusNode === null) return "";
1882
+ let n = t.getRangeAt(0), r = e.ownerDocument.createRange();
1883
+ if (t.containsNode(e, !1)) r.selectNodeContents(e), t.removeAllRanges(), t.addRange(r);
1884
+ else if (!(e.contains(t.anchorNode) && e.contains(t.focusNode))) {
1885
+ let i = e === n.startContainer || e.contains(n.startContainer), a = e === n.endContainer || e.contains(n.endContainer);
1886
+ t.removeAllRanges(), (i || a) && (r.selectNodeContents(e), i && r.setStart(n.startContainer, n.startOffset), a && r.setEnd(n.endContainer, n.endOffset), t.addRange(r));
1887
+ }
1888
+ let i = t.toString();
1889
+ return t.removeAllRanges(), t.addRange(n), i;
1890
+ }
1891
+ function En(e, t) {
1892
+ z(e, En, this);
1893
+ let n = t !== void 0;
1894
+ if (n && typeof t != "string") throw Error("expected selection must be a string or undefined");
1895
+ let r = Tn(e);
1896
+ return {
1897
+ pass: n ? W(r, t) : !!r,
1898
+ message: () => {
1899
+ let e = this.isNot ? "not to" : "to", i = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveSelection`, "element", t);
1900
+ return B(this, i, `Expected the element ${e} have selection`, n ? t : "(any)", "Received", r);
1901
+ }
1902
+ };
1903
+ }
1904
+ function Dn(e) {
1905
+ z(e, Dn, this);
1906
+ let t = (e.getAttribute("role") || "").split(" ").map((e) => e.trim()), n = e.tagName.toLowerCase() === "button" || e.tagName.toLowerCase() === "input" && e.type === "button" || t.includes("button"), r = e.getAttribute("aria-pressed");
1907
+ return !n || !(r === "true" || r === "false") ? {
1908
+ pass: !1,
1909
+ message: () => "Only button or input with type=\"button\" or element with role=\"button\" and a valid aria-pressed attribute can be used with .toBePressed()"
1910
+ } : {
1911
+ pass: n && r === "true",
1912
+ message: () => {
1913
+ let e = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePressed`, "element", "");
1914
+ return B(this, e, "Expected element to have", `aria-pressed="${this.isNot ? "false" : "true"}"`, "Received", `aria-pressed="${r}"`);
1915
+ }
1916
+ };
1917
+ }
1918
+ function Q(e) {
1919
+ z(e, Q, this);
1920
+ let t = (e.getAttribute("role") || "").split(" ").map((e) => e.trim()), n = e.tagName.toLowerCase() === "button" || e.tagName.toLowerCase() === "input" && e.type === "button" || t.includes("button"), r = e.getAttribute("aria-pressed");
1921
+ return !n || !(r === "true" || r === "false" || r === "mixed") ? {
1922
+ pass: !1,
1923
+ message: () => "Only button or input with type=\"button\" or element with role=\"button\" and a valid aria-pressed attribute can be used with .toBePartiallyPressed()"
1924
+ } : {
1925
+ pass: n && r === "mixed",
1926
+ message: () => {
1927
+ let e = this.isNot ? "not to" : "to", t = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePartiallyPressed`, "element", "");
1928
+ return B(this, t, `Expected element ${e} have`, "aria-pressed=\"mixed\"", "Received", `aria-pressed="${r}"`);
1929
+ }
1930
+ };
1931
+ }
1932
+ var On = 1, kn = 2, An = 4, jn = 8, Mn = 16, Nn = 32, Pn = {
1933
+ [On]: "Node.DOCUMENT_POSITION_DISCONNECTED",
1934
+ [kn]: "Node.DOCUMENT_POSITION_PRECEDING",
1935
+ [An]: "Node.DOCUMENT_POSITION_FOLLOWING",
1936
+ [jn]: "Node.DOCUMENT_POSITION_CONTAINS",
1937
+ [Mn]: "Node.DOCUMENT_POSITION_CONTAINED_BY",
1938
+ [Nn]: "Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC"
1939
+ };
1940
+ function Fn(e) {
1941
+ return e in Pn ? `${Pn[e]} (${e})` : `Unknown document position (${e})`;
1942
+ }
1943
+ function In(e, t) {
1944
+ return function(n, r) {
1945
+ z(n, $, this), z(r, $, this);
1946
+ let i = n.compareDocumentPosition(r);
1947
+ return {
1948
+ pass: i === t,
1949
+ message: () => [
1950
+ this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${e}`, "element", "secondElement"),
1951
+ "",
1952
+ `Received: ${Fn(i)}`
1953
+ ].join("\n")
1954
+ };
1955
+ };
1956
+ }
1957
+ function $(e, t) {
1958
+ return In("toAppearBefore", An).apply(this, [e, t]);
1959
+ }
1960
+ function Ln(e, t) {
1961
+ return In("toAppearAfter", kn).apply(this, [e, t]);
1962
+ }
1963
+ var Rn = /* @__PURE__ */ Object.freeze({
1964
+ __proto__: null,
1965
+ toAppearAfter: Ln,
1966
+ toAppearBefore: $,
1967
+ toBeChecked: vn,
1968
+ toBeDisabled: Zt,
1969
+ toBeEmpty: ut,
1970
+ toBeEmptyDOMElement: dt,
1971
+ toBeEnabled: Qt,
1972
+ toBeInTheDOM: G,
1973
+ toBeInTheDocument: lt,
1974
+ toBeInvalid: fn,
1975
+ toBePartiallyChecked: Sn,
1976
+ toBePartiallyPressed: Q,
1977
+ toBePressed: Dn,
1978
+ toBeRequired: sn,
1979
+ toBeValid: pn,
1980
+ toBeVisible: Ht,
1981
+ toContainElement: K,
1982
+ toContainHTML: mt,
1983
+ toHaveAccessibleDescription: q,
1984
+ toHaveAccessibleErrorMessage: _t,
1985
+ toHaveAccessibleName: X,
1986
+ toHaveAttribute: wt,
1987
+ toHaveClass: Ot,
1988
+ toHaveDescription: Cn,
1989
+ toHaveDisplayValue: hn,
1990
+ toHaveErrorMessage: wn,
1991
+ toHaveFocus: Nt,
1992
+ toHaveFormValues: Rt,
1993
+ toHaveRole: Y,
1994
+ toHaveSelection: En,
1995
+ toHaveStyle: Z,
1996
+ toHaveTextContent: ht,
1997
+ toHaveValue: mn
1998
+ });
1999
+ //#endregion
2000
+ //#region node_modules/@testing-library/jest-dom/dist/index.mjs
2001
+ expect.extend(Rn);
2002
+ //#endregion