@ariakit/test 0.3.5 → 0.3.7

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 (66) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/cjs/__chunks/{PJWPDIUX.cjs → 7U3THWRS.cjs} +21 -21
  3. package/cjs/__chunks/{ZMMVJ3OT.cjs → BXOTZFAK.cjs} +20 -0
  4. package/cjs/__chunks/{KVNENCXT.cjs → CYMYDRLS.cjs} +5 -5
  5. package/cjs/__chunks/{SDUGTL2N.cjs → DWIHFDL3.cjs} +2 -2
  6. package/cjs/__chunks/{T5KVOIJT.cjs → GIKCTITR.cjs} +10 -10
  7. package/cjs/__chunks/HQ3KUD6F.cjs +20 -0
  8. package/cjs/__chunks/{DAHHEUOU.cjs → ISKAHQPC.cjs} +15 -15
  9. package/cjs/__chunks/{VZINRVVH.cjs → K2XRALNE.cjs} +13 -13
  10. package/cjs/__chunks/{ESE7QHAQ.cjs → KFHFWZQN.cjs} +38 -24
  11. package/cjs/__chunks/{SEWCIANI.cjs → LG7B6NOG.cjs} +2 -2
  12. package/cjs/__chunks/{747HORQZ.cjs → QCXNVFD7.cjs} +5 -5
  13. package/cjs/__chunks/{LYOKT276.cjs → UWCNB4SR.cjs} +18 -18
  14. package/cjs/__chunks/VD3ERVOF.cjs +202 -0
  15. package/cjs/__chunks/{A5IFXY4J.cjs → YH2W6C46.cjs} +5 -5
  16. package/cjs/blur.cjs +4 -4
  17. package/cjs/click.cjs +10 -10
  18. package/cjs/dispatch.cjs +3 -3
  19. package/cjs/focus.cjs +4 -4
  20. package/cjs/hover.cjs +5 -5
  21. package/cjs/index.cjs +15 -15
  22. package/cjs/mouse-down.cjs +6 -6
  23. package/cjs/mouse-up.cjs +4 -4
  24. package/cjs/press.cjs +8 -8
  25. package/cjs/query.d.cts +10 -10
  26. package/cjs/query.d.ts +10 -10
  27. package/cjs/react.cjs +19 -19
  28. package/cjs/select.cjs +10 -10
  29. package/cjs/sleep.cjs +3 -3
  30. package/cjs/tap.cjs +11 -11
  31. package/cjs/type.cjs +6 -6
  32. package/cjs/wait-for.cjs +3 -3
  33. package/esm/__chunks/{MKNCAN2F.js → 2TVULPB4.js} +1 -1
  34. package/esm/__chunks/{YNAZUNNE.js → 3EIGH73D.js} +1 -1
  35. package/esm/__chunks/{LHKK7Y5F.js → 7I2TICIC.js} +20 -0
  36. package/esm/__chunks/{H3BXHZTZ.js → AMV7YAJV.js} +6 -6
  37. package/esm/__chunks/{WLDGXXGP.js → G2JU2LVB.js} +1 -1
  38. package/esm/__chunks/{HVRX3U4O.js → H2ALBSTH.js} +4 -4
  39. package/esm/__chunks/{WAYMNUAF.js → HZKYXBIJ.js} +2 -2
  40. package/esm/__chunks/JIRMKL2I.js +202 -0
  41. package/esm/__chunks/{ANPGABTJ.js → LRKW54RD.js} +3 -3
  42. package/esm/__chunks/{ZIWQZF7I.js → QE2YCTHV.js} +2 -2
  43. package/esm/__chunks/{5DPK2YAQ.js → SCOSW7X5.js} +7 -7
  44. package/esm/__chunks/{LSH2PT34.js → V36IYEJN.js} +2 -2
  45. package/esm/__chunks/{RG2JKALK.js → V6672LI4.js} +4 -4
  46. package/esm/__chunks/{UJCT5GXS.js → YRF6BLTM.js} +20 -6
  47. package/esm/blur.js +3 -3
  48. package/esm/click.js +9 -9
  49. package/esm/dispatch.js +2 -2
  50. package/esm/focus.js +3 -3
  51. package/esm/hover.js +4 -4
  52. package/esm/index.js +14 -14
  53. package/esm/mouse-down.js +5 -5
  54. package/esm/mouse-up.js +3 -3
  55. package/esm/press.js +7 -7
  56. package/esm/query.d.ts +10 -10
  57. package/esm/react.js +14 -14
  58. package/esm/select.js +9 -9
  59. package/esm/sleep.js +2 -2
  60. package/esm/tap.js +10 -10
  61. package/esm/type.js +5 -5
  62. package/esm/wait-for.js +2 -2
  63. package/package.json +2 -2
  64. package/cjs/__chunks/FU2U6RZL.cjs +0 -57
  65. package/cjs/__chunks/NIEATM7R.cjs +0 -20
  66. package/esm/__chunks/7JP5HWUW.js +0 -57
package/cjs/query.d.ts CHANGED
@@ -48,7 +48,7 @@ export declare const query: {
48
48
  };
49
49
  };
50
50
  };
51
- article: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
51
+ button: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
52
52
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
53
53
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
54
54
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -72,7 +72,7 @@ export declare const query: {
72
72
  };
73
73
  };
74
74
  };
75
- blockquote: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
75
+ code: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
76
76
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
77
77
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
78
78
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -96,7 +96,7 @@ export declare const query: {
96
96
  };
97
97
  };
98
98
  };
99
- button: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
99
+ article: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
100
100
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
101
101
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
102
102
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -120,7 +120,7 @@ export declare const query: {
120
120
  };
121
121
  };
122
122
  };
123
- caption: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
123
+ blockquote: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
124
124
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
125
125
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
126
126
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -144,7 +144,7 @@ export declare const query: {
144
144
  };
145
145
  };
146
146
  };
147
- code: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
147
+ caption: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
148
148
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
149
149
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
150
150
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -2042,7 +2042,7 @@ export declare const q: {
2042
2042
  };
2043
2043
  };
2044
2044
  };
2045
- article: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2045
+ button: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2046
2046
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
2047
2047
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
2048
2048
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -2066,7 +2066,7 @@ export declare const q: {
2066
2066
  };
2067
2067
  };
2068
2068
  };
2069
- blockquote: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2069
+ code: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2070
2070
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
2071
2071
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
2072
2072
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -2090,7 +2090,7 @@ export declare const q: {
2090
2090
  };
2091
2091
  };
2092
2092
  };
2093
- button: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2093
+ article: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2094
2094
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
2095
2095
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
2096
2096
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -2114,7 +2114,7 @@ export declare const q: {
2114
2114
  };
2115
2115
  };
2116
2116
  };
2117
- caption: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2117
+ blockquote: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2118
2118
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
2119
2119
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
2120
2120
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
@@ -2138,7 +2138,7 @@ export declare const q: {
2138
2138
  };
2139
2139
  };
2140
2140
  };
2141
- code: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2141
+ caption: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null) & {
2142
2142
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement | null;
2143
2143
  all: ((name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[]) & {
2144
2144
  includesHidden: (name?: string | RegExp, options?: ByRoleOptions) => HTMLElement[];
package/cjs/react.cjs CHANGED
@@ -2,52 +2,52 @@
2
2
  require('./__chunks/I2BROIQW.cjs');
3
3
 
4
4
 
5
- var _SEWCIANIcjs = require('./__chunks/SEWCIANI.cjs');
5
+ var _LG7B6NOGcjs = require('./__chunks/LG7B6NOG.cjs');
6
6
 
7
7
 
8
- var _SDUGTL2Ncjs = require('./__chunks/SDUGTL2N.cjs');
8
+ var _DWIHFDL3cjs = require('./__chunks/DWIHFDL3.cjs');
9
9
 
10
10
 
11
- var _PJWPDIUXcjs = require('./__chunks/PJWPDIUX.cjs');
11
+ var _7U3THWRScjs = require('./__chunks/7U3THWRS.cjs');
12
12
 
13
13
 
14
- var _DAHHEUOUcjs = require('./__chunks/DAHHEUOU.cjs');
14
+ var _ISKAHQPCcjs = require('./__chunks/ISKAHQPC.cjs');
15
15
 
16
16
 
17
- var _747HORQZcjs = require('./__chunks/747HORQZ.cjs');
17
+ var _QCXNVFD7cjs = require('./__chunks/QCXNVFD7.cjs');
18
18
 
19
19
 
20
- var _T5KVOIJTcjs = require('./__chunks/T5KVOIJT.cjs');
20
+ var _GIKCTITRcjs = require('./__chunks/GIKCTITR.cjs');
21
21
 
22
22
 
23
- var _LYOKT276cjs = require('./__chunks/LYOKT276.cjs');
23
+ var _UWCNB4SRcjs = require('./__chunks/UWCNB4SR.cjs');
24
24
 
25
25
 
26
26
 
27
27
  var _2KXSRUIVcjs = require('./__chunks/2KXSRUIV.cjs');
28
28
 
29
29
 
30
- var _ESE7QHAQcjs = require('./__chunks/ESE7QHAQ.cjs');
30
+ var _KFHFWZQNcjs = require('./__chunks/KFHFWZQN.cjs');
31
31
 
32
32
 
33
- var _VZINRVVHcjs = require('./__chunks/VZINRVVH.cjs');
33
+ var _K2XRALNEcjs = require('./__chunks/K2XRALNE.cjs');
34
34
 
35
35
 
36
- var _KVNENCXTcjs = require('./__chunks/KVNENCXT.cjs');
36
+ var _CYMYDRLScjs = require('./__chunks/CYMYDRLS.cjs');
37
37
 
38
38
 
39
- var _A5IFXY4Jcjs = require('./__chunks/A5IFXY4J.cjs');
39
+ var _YH2W6C46cjs = require('./__chunks/YH2W6C46.cjs');
40
40
 
41
41
 
42
- var _FU2U6RZLcjs = require('./__chunks/FU2U6RZL.cjs');
42
+ var _VD3ERVOFcjs = require('./__chunks/VD3ERVOF.cjs');
43
43
 
44
44
 
45
- var _NIEATM7Rcjs = require('./__chunks/NIEATM7R.cjs');
45
+ var _HQ3KUD6Fcjs = require('./__chunks/HQ3KUD6F.cjs');
46
46
 
47
47
 
48
48
 
49
49
 
50
- var _ZMMVJ3OTcjs = require('./__chunks/ZMMVJ3OT.cjs');
50
+ var _BXOTZFAKcjs = require('./__chunks/BXOTZFAK.cjs');
51
51
 
52
52
 
53
53
 
@@ -65,11 +65,11 @@ async function render2(ui, options) {
65
65
  return element;
66
66
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _react.StrictMode, { children: element });
67
67
  };
68
- return _ZMMVJ3OTcjs.wrapAsync.call(void 0, async () => {
68
+ return _BXOTZFAKcjs.wrapAsync.call(void 0, async () => {
69
69
  const { unmount } = ReactTestingLibrary.render(ui, _OVN5OYWKcjs.__spreadProps.call(void 0, _OVN5OYWKcjs.__spreadValues.call(void 0, {}, options), { wrapper }));
70
- await _ZMMVJ3OTcjs.flushMicrotasks.call(void 0, );
71
- await _ZMMVJ3OTcjs.nextFrame.call(void 0, );
72
- await _ZMMVJ3OTcjs.flushMicrotasks.call(void 0, );
70
+ await _BXOTZFAKcjs.flushMicrotasks.call(void 0, );
71
+ await _BXOTZFAKcjs.nextFrame.call(void 0, );
72
+ await _BXOTZFAKcjs.flushMicrotasks.call(void 0, );
73
73
  return unmount;
74
74
  });
75
75
  }
@@ -90,4 +90,4 @@ async function render2(ui, options) {
90
90
 
91
91
 
92
92
 
93
- exports.blur = _KVNENCXTcjs.blur; exports.click = _PJWPDIUXcjs.click; exports.dispatch = _FU2U6RZLcjs.dispatch; exports.focus = _A5IFXY4Jcjs.focus; exports.hover = _LYOKT276cjs.hover; exports.mouseDown = _T5KVOIJTcjs.mouseDown; exports.mouseUp = _747HORQZcjs.mouseUp; exports.press = _ESE7QHAQcjs.press; exports.q = _2KXSRUIVcjs.q; exports.query = _2KXSRUIVcjs.query; exports.render = render2; exports.select = _DAHHEUOUcjs.select; exports.sleep = _NIEATM7Rcjs.sleep; exports.tap = _SDUGTL2Ncjs.tap; exports.type = _VZINRVVHcjs.type; exports.waitFor = _SEWCIANIcjs.waitFor;
93
+ exports.blur = _CYMYDRLScjs.blur; exports.click = _7U3THWRScjs.click; exports.dispatch = _VD3ERVOFcjs.dispatch; exports.focus = _YH2W6C46cjs.focus; exports.hover = _UWCNB4SRcjs.hover; exports.mouseDown = _GIKCTITRcjs.mouseDown; exports.mouseUp = _QCXNVFD7cjs.mouseUp; exports.press = _KFHFWZQNcjs.press; exports.q = _2KXSRUIVcjs.q; exports.query = _2KXSRUIVcjs.query; exports.render = render2; exports.select = _ISKAHQPCcjs.select; exports.sleep = _HQ3KUD6Fcjs.sleep; exports.tap = _DWIHFDL3cjs.tap; exports.type = _K2XRALNEcjs.type; exports.waitFor = _LG7B6NOGcjs.waitFor;
package/cjs/select.cjs CHANGED
@@ -1,16 +1,16 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
- var _DAHHEUOUcjs = require('./__chunks/DAHHEUOU.cjs');
5
- require('./__chunks/747HORQZ.cjs');
6
- require('./__chunks/T5KVOIJT.cjs');
7
- require('./__chunks/LYOKT276.cjs');
8
- require('./__chunks/KVNENCXT.cjs');
9
- require('./__chunks/A5IFXY4J.cjs');
10
- require('./__chunks/FU2U6RZL.cjs');
11
- require('./__chunks/NIEATM7R.cjs');
12
- require('./__chunks/ZMMVJ3OT.cjs');
4
+ var _ISKAHQPCcjs = require('./__chunks/ISKAHQPC.cjs');
5
+ require('./__chunks/QCXNVFD7.cjs');
6
+ require('./__chunks/GIKCTITR.cjs');
7
+ require('./__chunks/UWCNB4SR.cjs');
8
+ require('./__chunks/CYMYDRLS.cjs');
9
+ require('./__chunks/YH2W6C46.cjs');
10
+ require('./__chunks/VD3ERVOF.cjs');
11
+ require('./__chunks/HQ3KUD6F.cjs');
12
+ require('./__chunks/BXOTZFAK.cjs');
13
13
  require('./__chunks/OVN5OYWK.cjs');
14
14
 
15
15
 
16
- exports.select = _DAHHEUOUcjs.select;
16
+ exports.select = _ISKAHQPCcjs.select;
package/cjs/sleep.cjs CHANGED
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
- var _NIEATM7Rcjs = require('./__chunks/NIEATM7R.cjs');
5
- require('./__chunks/ZMMVJ3OT.cjs');
4
+ var _HQ3KUD6Fcjs = require('./__chunks/HQ3KUD6F.cjs');
5
+ require('./__chunks/BXOTZFAK.cjs');
6
6
  require('./__chunks/OVN5OYWK.cjs');
7
7
 
8
8
 
9
- exports.sleep = _NIEATM7Rcjs.sleep;
9
+ exports.sleep = _HQ3KUD6Fcjs.sleep;
package/cjs/tap.cjs CHANGED
@@ -1,17 +1,17 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
- var _SDUGTL2Ncjs = require('./__chunks/SDUGTL2N.cjs');
5
- require('./__chunks/PJWPDIUX.cjs');
6
- require('./__chunks/747HORQZ.cjs');
7
- require('./__chunks/T5KVOIJT.cjs');
8
- require('./__chunks/LYOKT276.cjs');
9
- require('./__chunks/KVNENCXT.cjs');
10
- require('./__chunks/A5IFXY4J.cjs');
11
- require('./__chunks/FU2U6RZL.cjs');
12
- require('./__chunks/NIEATM7R.cjs');
13
- require('./__chunks/ZMMVJ3OT.cjs');
4
+ var _DWIHFDL3cjs = require('./__chunks/DWIHFDL3.cjs');
5
+ require('./__chunks/7U3THWRS.cjs');
6
+ require('./__chunks/QCXNVFD7.cjs');
7
+ require('./__chunks/GIKCTITR.cjs');
8
+ require('./__chunks/UWCNB4SR.cjs');
9
+ require('./__chunks/CYMYDRLS.cjs');
10
+ require('./__chunks/YH2W6C46.cjs');
11
+ require('./__chunks/VD3ERVOF.cjs');
12
+ require('./__chunks/HQ3KUD6F.cjs');
13
+ require('./__chunks/BXOTZFAK.cjs');
14
14
  require('./__chunks/OVN5OYWK.cjs');
15
15
 
16
16
 
17
- exports.tap = _SDUGTL2Ncjs.tap;
17
+ exports.tap = _DWIHFDL3cjs.tap;
package/cjs/type.cjs CHANGED
@@ -1,12 +1,12 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
- var _VZINRVVHcjs = require('./__chunks/VZINRVVH.cjs');
5
- require('./__chunks/A5IFXY4J.cjs');
6
- require('./__chunks/FU2U6RZL.cjs');
7
- require('./__chunks/NIEATM7R.cjs');
8
- require('./__chunks/ZMMVJ3OT.cjs');
4
+ var _K2XRALNEcjs = require('./__chunks/K2XRALNE.cjs');
5
+ require('./__chunks/YH2W6C46.cjs');
6
+ require('./__chunks/VD3ERVOF.cjs');
7
+ require('./__chunks/HQ3KUD6F.cjs');
8
+ require('./__chunks/BXOTZFAK.cjs');
9
9
  require('./__chunks/OVN5OYWK.cjs');
10
10
 
11
11
 
12
- exports.type = _VZINRVVHcjs.type;
12
+ exports.type = _K2XRALNEcjs.type;
package/cjs/wait-for.cjs CHANGED
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
- var _SEWCIANIcjs = require('./__chunks/SEWCIANI.cjs');
5
- require('./__chunks/ZMMVJ3OT.cjs');
4
+ var _LG7B6NOGcjs = require('./__chunks/LG7B6NOG.cjs');
5
+ require('./__chunks/BXOTZFAK.cjs');
6
6
  require('./__chunks/OVN5OYWK.cjs');
7
7
 
8
8
 
9
- exports.waitFor = _SEWCIANIcjs.waitFor;
9
+ exports.waitFor = _LG7B6NOGcjs.waitFor;
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  click
4
- } from "./5DPK2YAQ.js";
4
+ } from "./SCOSW7X5.js";
5
5
 
6
6
  // src/tap.ts
7
7
  function tap(element, options) {
@@ -3,7 +3,7 @@ import {
3
3
  isBrowser,
4
4
  nextFrame,
5
5
  wrapAsync
6
- } from "./LHKK7Y5F.js";
6
+ } from "./7I2TICIC.js";
7
7
 
8
8
  // src/sleep.ts
9
9
  var defaultMs = isBrowser ? 150 : 10;
@@ -48,6 +48,26 @@ function applyBrowserPolyfills() {
48
48
  return [];
49
49
  return [{ width: 1, height: 1 }];
50
50
  };
51
+ if (!Element.prototype.scrollIntoView) {
52
+ Element.prototype.scrollIntoView = noop;
53
+ }
54
+ if (!Element.prototype.hasPointerCapture) {
55
+ Element.prototype.hasPointerCapture = noop;
56
+ }
57
+ if (!Element.prototype.setPointerCapture) {
58
+ Element.prototype.setPointerCapture = noop;
59
+ }
60
+ if (!Element.prototype.releasePointerCapture) {
61
+ Element.prototype.releasePointerCapture = noop;
62
+ }
63
+ if (typeof window.ClipboardEvent === "undefined") {
64
+ window.ClipboardEvent = class ClipboardEvent extends Event {
65
+ };
66
+ }
67
+ if (typeof window.PointerEvent === "undefined") {
68
+ window.PointerEvent = class PointerEvent extends MouseEvent {
69
+ };
70
+ }
51
71
  return () => {
52
72
  HTMLElement.prototype.focus = originalFocus;
53
73
  Element.prototype.getClientRects = originalGetClientRects;
@@ -1,22 +1,22 @@
1
1
  "use client";
2
2
  import {
3
3
  mouseUp
4
- } from "./LSH2PT34.js";
4
+ } from "./V36IYEJN.js";
5
5
  import {
6
6
  mouseDown
7
- } from "./RG2JKALK.js";
7
+ } from "./V6672LI4.js";
8
8
  import {
9
9
  hover
10
- } from "./ANPGABTJ.js";
10
+ } from "./LRKW54RD.js";
11
11
  import {
12
12
  dispatch
13
- } from "./7JP5HWUW.js";
13
+ } from "./JIRMKL2I.js";
14
14
  import {
15
15
  sleep
16
- } from "./YNAZUNNE.js";
16
+ } from "./3EIGH73D.js";
17
17
  import {
18
18
  wrapAsync
19
- } from "./LHKK7Y5F.js";
19
+ } from "./7I2TICIC.js";
20
20
  import {
21
21
  __spreadValues
22
22
  } from "./Q65FZOE2.js";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  wrapAsync
4
- } from "./LHKK7Y5F.js";
4
+ } from "./7I2TICIC.js";
5
5
 
6
6
  // src/wait-for.ts
7
7
  import * as DOMTestingLibrary from "@testing-library/dom";
@@ -1,16 +1,16 @@
1
1
  "use client";
2
2
  import {
3
3
  focus
4
- } from "./WAYMNUAF.js";
4
+ } from "./HZKYXBIJ.js";
5
5
  import {
6
6
  dispatch
7
- } from "./7JP5HWUW.js";
7
+ } from "./JIRMKL2I.js";
8
8
  import {
9
9
  sleep
10
- } from "./YNAZUNNE.js";
10
+ } from "./3EIGH73D.js";
11
11
  import {
12
12
  wrapAsync
13
- } from "./LHKK7Y5F.js";
13
+ } from "./7I2TICIC.js";
14
14
  import {
15
15
  __spreadValues
16
16
  } from "./Q65FZOE2.js";
@@ -1,11 +1,11 @@
1
1
  "use client";
2
2
  import {
3
3
  dispatch
4
- } from "./7JP5HWUW.js";
4
+ } from "./JIRMKL2I.js";
5
5
  import {
6
6
  flushMicrotasks,
7
7
  wrapAsync
8
- } from "./LHKK7Y5F.js";
8
+ } from "./7I2TICIC.js";
9
9
 
10
10
  // src/focus.ts
11
11
  import { getActiveElement } from "@ariakit/core/utils/dom";
@@ -0,0 +1,202 @@
1
+ "use client";
2
+ import {
3
+ flushMicrotasks,
4
+ wrapAsync
5
+ } from "./7I2TICIC.js";
6
+
7
+ // src/dispatch.ts
8
+ import { getKeys, invariant } from "@ariakit/core/utils/misc";
9
+ import { createEvent, fireEvent } from "@testing-library/dom";
10
+ function assignProps(obj, props) {
11
+ for (const [key, value] of Object.entries(props)) {
12
+ Object.defineProperty(obj, key, { get: () => value != null ? value : null });
13
+ }
14
+ }
15
+ function sanitizeNumber(n) {
16
+ return Number(n != null ? n : 0);
17
+ }
18
+ function initClipboardEvent(event, { clipboardData }) {
19
+ assignProps(event, {
20
+ clipboardData
21
+ });
22
+ }
23
+ function initInputEvent(event, { data, inputType, isComposing }) {
24
+ assignProps(event, {
25
+ data,
26
+ isComposing: !!isComposing,
27
+ inputType: String(inputType)
28
+ });
29
+ }
30
+ function initUIEvent(event, { view, detail }) {
31
+ assignProps(event, {
32
+ view,
33
+ detail: sanitizeNumber(detail != null ? detail : 0)
34
+ });
35
+ }
36
+ function initUIEventModififiers(event, {
37
+ altKey,
38
+ ctrlKey,
39
+ metaKey,
40
+ shiftKey,
41
+ modifierAltGraph,
42
+ modifierCapsLock,
43
+ modifierFn,
44
+ modifierFnLock,
45
+ modifierNumLock,
46
+ modifierScrollLock,
47
+ modifierSymbol,
48
+ modifierSymbolLock
49
+ }) {
50
+ assignProps(event, {
51
+ altKey: !!altKey,
52
+ ctrlKey: !!ctrlKey,
53
+ metaKey: !!metaKey,
54
+ shiftKey: !!shiftKey,
55
+ getModifierState(k) {
56
+ return Boolean(
57
+ {
58
+ Alt: altKey,
59
+ AltGraph: modifierAltGraph,
60
+ CapsLock: modifierCapsLock,
61
+ Control: ctrlKey,
62
+ Fn: modifierFn,
63
+ FnLock: modifierFnLock,
64
+ Meta: metaKey,
65
+ NumLock: modifierNumLock,
66
+ ScrollLock: modifierScrollLock,
67
+ Shift: shiftKey,
68
+ Symbol: modifierSymbol,
69
+ SymbolLock: modifierSymbolLock
70
+ }[k]
71
+ );
72
+ }
73
+ });
74
+ }
75
+ function initKeyboardEvent(event, { key, code, location, repeat, isComposing }) {
76
+ assignProps(event, {
77
+ key: String(key),
78
+ code: String(code),
79
+ location: sanitizeNumber(location),
80
+ repeat: !!repeat,
81
+ isComposing: !!isComposing
82
+ });
83
+ }
84
+ function initMouseEvent(event, {
85
+ x,
86
+ y,
87
+ screenX,
88
+ screenY,
89
+ clientX = x,
90
+ clientY = y,
91
+ button,
92
+ buttons,
93
+ relatedTarget
94
+ }) {
95
+ assignProps(event, {
96
+ screenX: sanitizeNumber(screenX),
97
+ screenY: sanitizeNumber(screenY),
98
+ clientX: sanitizeNumber(clientX),
99
+ x: sanitizeNumber(clientX),
100
+ clientY: sanitizeNumber(clientY),
101
+ y: sanitizeNumber(clientY),
102
+ button: sanitizeNumber(button),
103
+ buttons: sanitizeNumber(buttons),
104
+ relatedTarget
105
+ });
106
+ }
107
+ function initPointerEvent(event, {
108
+ pointerId,
109
+ width,
110
+ height,
111
+ pressure,
112
+ tangentialPressure,
113
+ tiltX,
114
+ tiltY,
115
+ twist,
116
+ pointerType,
117
+ isPrimary
118
+ }) {
119
+ assignProps(event, {
120
+ pointerId: sanitizeNumber(pointerId),
121
+ width: sanitizeNumber(width),
122
+ height: sanitizeNumber(height),
123
+ pressure: sanitizeNumber(pressure),
124
+ tangentialPressure: sanitizeNumber(tangentialPressure),
125
+ tiltX: sanitizeNumber(tiltX),
126
+ tiltY: sanitizeNumber(tiltY),
127
+ twist: sanitizeNumber(twist),
128
+ pointerType: String(pointerType),
129
+ isPrimary: !!isPrimary
130
+ });
131
+ }
132
+ function initEvent(event, options = {}) {
133
+ if (event instanceof ClipboardEvent) {
134
+ initClipboardEvent(event, options);
135
+ }
136
+ if (event instanceof InputEvent) {
137
+ initInputEvent(event, options);
138
+ }
139
+ if (event instanceof UIEvent) {
140
+ initUIEvent(event, options);
141
+ }
142
+ if (event instanceof KeyboardEvent) {
143
+ initKeyboardEvent(event, options);
144
+ initUIEventModififiers(event, options);
145
+ }
146
+ if (event instanceof MouseEvent) {
147
+ initMouseEvent(event, options);
148
+ initUIEventModififiers(event, options);
149
+ }
150
+ if (event instanceof PointerEvent) {
151
+ initPointerEvent(event, options);
152
+ }
153
+ }
154
+ var pointerEvents = [
155
+ "mousemove",
156
+ "mouseover",
157
+ "mouseenter",
158
+ "mouseout",
159
+ "mouseleave",
160
+ "mousedown",
161
+ "mouseup",
162
+ "pointermove",
163
+ "pointerover",
164
+ "pointerenter",
165
+ "pointerout",
166
+ "pointerleave",
167
+ "pointerdown",
168
+ "pointerup",
169
+ "click"
170
+ ];
171
+ function baseDispatch(element, event) {
172
+ return wrapAsync(async () => {
173
+ invariant(element, `Unable to dispatch ${event.type} on null element`);
174
+ const eventName = event.type.toLowerCase();
175
+ if (pointerEvents.includes(eventName) && "classList" in element) {
176
+ const { pointerEvents: pointerEvents2 } = getComputedStyle(element);
177
+ if (pointerEvents2 === "none") {
178
+ if (element.parentElement) {
179
+ return baseDispatch(element.parentElement, event);
180
+ }
181
+ return true;
182
+ }
183
+ }
184
+ const defaultAllowed = fireEvent(element, event);
185
+ await flushMicrotasks();
186
+ return defaultAllowed;
187
+ });
188
+ }
189
+ var events = getKeys(fireEvent).reduce((events2, eventName) => {
190
+ events2[eventName] = (element, options) => {
191
+ invariant(element, `Unable to dispatch ${eventName} on null element`);
192
+ const event = createEvent[eventName](element, options);
193
+ initEvent(event, options);
194
+ return baseDispatch(element, event);
195
+ };
196
+ return events2;
197
+ }, {});
198
+ var dispatch = Object.assign(baseDispatch, events);
199
+
200
+ export {
201
+ dispatch
202
+ };
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import {
3
3
  dispatch
4
- } from "./7JP5HWUW.js";
4
+ } from "./JIRMKL2I.js";
5
5
  import {
6
6
  sleep
7
- } from "./YNAZUNNE.js";
7
+ } from "./3EIGH73D.js";
8
8
  import {
9
9
  wrapAsync
10
- } from "./LHKK7Y5F.js";
10
+ } from "./7I2TICIC.js";
11
11
  import {
12
12
  __spreadProps,
13
13
  __spreadValues
@@ -1,11 +1,11 @@
1
1
  "use client";
2
2
  import {
3
3
  dispatch
4
- } from "./7JP5HWUW.js";
4
+ } from "./JIRMKL2I.js";
5
5
  import {
6
6
  flushMicrotasks,
7
7
  wrapAsync
8
- } from "./LHKK7Y5F.js";
8
+ } from "./7I2TICIC.js";
9
9
 
10
10
  // src/blur.ts
11
11
  import { getActiveElement } from "@ariakit/core/utils/dom";