@ariakit/test 0.3.14 → 0.3.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/cjs/__chunks/{7U3THWRS.cjs → 2PZMNP6W.cjs} +13 -11
- package/cjs/__chunks/{GIKCTITR.cjs → 7KITCMSC.cjs} +4 -4
- package/cjs/__chunks/{6OCVCOFL.cjs → DJWEA66K.cjs} +8 -8
- package/cjs/__chunks/{ISKAHQPC.cjs → IL4UOQ5U.cjs} +2 -2
- package/cjs/__chunks/{DWIHFDL3.cjs → IZ5UGCXW.cjs} +2 -2
- package/cjs/__chunks/{YH2W6C46.cjs → IZMYJH6V.cjs} +5 -2
- package/cjs/__chunks/{K2XRALNE.cjs → ZNASNKOZ.cjs} +2 -2
- package/cjs/blur.d.cts +1 -1
- package/cjs/blur.d.ts +1 -1
- package/cjs/click.cjs +4 -4
- package/cjs/focus.cjs +2 -2
- package/cjs/index.cjs +8 -8
- package/cjs/index.d.cts +14 -14
- package/cjs/index.d.ts +14 -14
- package/cjs/mouse-down.cjs +3 -3
- package/cjs/playwright.d.cts +1 -1
- package/cjs/playwright.d.ts +1 -1
- package/cjs/press.cjs +4 -4
- package/cjs/react.cjs +11 -11
- package/cjs/react.d.cts +2 -2
- package/cjs/react.d.ts +2 -2
- package/cjs/select.cjs +4 -4
- package/cjs/tap.cjs +5 -5
- package/cjs/type.cjs +3 -3
- package/cjs/type.d.cts +1 -1
- package/cjs/type.d.ts +1 -1
- package/esm/__chunks/{2TVULPB4.js → 64UIOMYC.js} +1 -1
- package/esm/__chunks/{HT6XK7H3.js → DMIPXMWG.js} +2 -2
- package/esm/__chunks/{SCOSW7X5.js → HKMYG3ZJ.js} +12 -10
- package/esm/__chunks/{AMV7YAJV.js → U5OPLWAZ.js} +1 -1
- package/esm/__chunks/{HZKYXBIJ.js → VD2VFA32.js} +5 -2
- package/esm/__chunks/{H2ALBSTH.js → VVYOYAEF.js} +1 -1
- package/esm/__chunks/{V6672LI4.js → YGSLLIRN.js} +2 -2
- package/esm/blur.d.ts +1 -1
- package/esm/click.js +3 -3
- package/esm/focus.js +1 -1
- package/esm/index.d.ts +14 -14
- package/esm/index.js +7 -7
- package/esm/mouse-down.js +2 -2
- package/esm/playwright.d.ts +1 -1
- package/esm/press.js +3 -3
- package/esm/react.d.ts +2 -2
- package/esm/react.js +8 -8
- package/esm/select.js +3 -3
- package/esm/tap.js +4 -4
- package/esm/type.d.ts +1 -1
- package/esm/type.js +2 -2
- package/package.json +6 -6
- package/.eslintignore +0 -6
package/CHANGELOG.md
CHANGED
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
var _QCXNVFD7cjs = require('./QCXNVFD7.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _7KITCMSCcjs = require('./7KITCMSC.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
var _UWCNB4SRcjs = require('./UWCNB4SR.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
13
|
+
var _IZMYJH6Vcjs = require('./IZMYJH6V.cjs');
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
var _VD3ERVOFcjs = require('./VD3ERVOF.cjs');
|
|
@@ -30,7 +30,7 @@ var _focus = require('@ariakit/core/utils/focus');
|
|
|
30
30
|
var _misc = require('@ariakit/core/utils/misc');
|
|
31
31
|
function getClosestLabel(element) {
|
|
32
32
|
if (!_focus.isFocusable.call(void 0, element)) {
|
|
33
|
-
return
|
|
33
|
+
return element.closest("label");
|
|
34
34
|
}
|
|
35
35
|
return null;
|
|
36
36
|
}
|
|
@@ -49,7 +49,7 @@ async function clickLabel(element, options) {
|
|
|
49
49
|
if (input) {
|
|
50
50
|
input.disabled = isInputDisabled;
|
|
51
51
|
if (defaultAllowed && _focus.isFocusable.call(void 0, input)) {
|
|
52
|
-
await
|
|
52
|
+
await _IZMYJH6Vcjs.focus.call(void 0, input);
|
|
53
53
|
await _VD3ERVOFcjs.dispatch.click(input);
|
|
54
54
|
}
|
|
55
55
|
}
|
|
@@ -59,23 +59,25 @@ function setSelected(element, selected) {
|
|
|
59
59
|
element.selected = selected;
|
|
60
60
|
}
|
|
61
61
|
async function clickOption(element, eventOptions) {
|
|
62
|
-
const select =
|
|
62
|
+
const select = element.closest("select");
|
|
63
63
|
if (!select) {
|
|
64
64
|
await _VD3ERVOFcjs.dispatch.click(element, eventOptions);
|
|
65
65
|
return;
|
|
66
66
|
}
|
|
67
67
|
if (select.multiple) {
|
|
68
68
|
const options = Array.from(select.options);
|
|
69
|
-
const resetOptions = () =>
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
const resetOptions = () => {
|
|
70
|
+
for (const option of options) {
|
|
71
|
+
setSelected(option, false);
|
|
72
|
+
}
|
|
73
|
+
};
|
|
72
74
|
const selectRange = (a, b) => {
|
|
73
75
|
const from = Math.min(a, b);
|
|
74
76
|
const to = Math.max(a, b) + 1;
|
|
75
77
|
const selectedOptions = options.slice(from, to);
|
|
76
|
-
|
|
78
|
+
for (const option of selectedOptions) {
|
|
77
79
|
setSelected(option, true);
|
|
78
|
-
}
|
|
80
|
+
}
|
|
79
81
|
};
|
|
80
82
|
if (eventOptions == null ? void 0 : eventOptions.shiftKey) {
|
|
81
83
|
const elementIndex = options.indexOf(element);
|
|
@@ -106,7 +108,7 @@ function click(element, options, tap = false) {
|
|
|
106
108
|
if (!_dom.isVisible.call(void 0, element))
|
|
107
109
|
return;
|
|
108
110
|
await _UWCNB4SRcjs.hover.call(void 0, element, options);
|
|
109
|
-
await
|
|
111
|
+
await _7KITCMSCcjs.mouseDown.call(void 0, element, options);
|
|
110
112
|
while (!_dom.isVisible.call(void 0, element)) {
|
|
111
113
|
if (!element.parentElement)
|
|
112
114
|
return;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
var _CYMYDRLScjs = require('./CYMYDRLS.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _IZMYJH6Vcjs = require('./IZMYJH6V.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
var _VD3ERVOFcjs = require('./VD3ERVOF.cjs');
|
|
@@ -33,18 +33,18 @@ function mouseDown(element, options) {
|
|
|
33
33
|
}
|
|
34
34
|
if (defaultAllowed) {
|
|
35
35
|
const selection = _dom.getDocument.call(void 0, element).getSelection();
|
|
36
|
-
if (selection
|
|
36
|
+
if (selection == null ? void 0 : selection.rangeCount) {
|
|
37
37
|
const range = selection.getRangeAt(0);
|
|
38
38
|
if (!range.collapsed) {
|
|
39
39
|
selection.removeAllRanges();
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
if (_focus.isFocusable.call(void 0, element) && getComputedStyle(element).pointerEvents !== "none") {
|
|
43
|
-
await
|
|
43
|
+
await _IZMYJH6Vcjs.focus.call(void 0, element);
|
|
44
44
|
} else if (element.parentElement) {
|
|
45
45
|
const closestFocusable = _focus.getClosestFocusable.call(void 0, element.parentElement);
|
|
46
46
|
if (closestFocusable) {
|
|
47
|
-
await
|
|
47
|
+
await _IZMYJH6Vcjs.focus.call(void 0, closestFocusable);
|
|
48
48
|
} else {
|
|
49
49
|
await _CYMYDRLScjs.blur.call(void 0, );
|
|
50
50
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _ZNASNKOZcjs = require('./ZNASNKOZ.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _CYMYDRLScjs = require('./CYMYDRLS.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _IZMYJH6Vcjs = require('./IZMYJH6V.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
var _VD3ERVOFcjs = require('./VD3ERVOF.cjs');
|
|
@@ -68,7 +68,7 @@ var keyDownMap = {
|
|
|
68
68
|
async Tab(_, { shiftKey }) {
|
|
69
69
|
const nextElement = shiftKey ? _focus.getPreviousTabbable.call(void 0, ) : _focus.getNextTabbable.call(void 0, );
|
|
70
70
|
if (nextElement) {
|
|
71
|
-
await
|
|
71
|
+
await _IZMYJH6Vcjs.focus.call(void 0, nextElement);
|
|
72
72
|
}
|
|
73
73
|
},
|
|
74
74
|
async Enter(element, options) {
|
|
@@ -183,20 +183,20 @@ function press(key, element, options = {}) {
|
|
|
183
183
|
return;
|
|
184
184
|
if (_dom.isTextField.call(void 0, element)) {
|
|
185
185
|
if (key.length === 1) {
|
|
186
|
-
return
|
|
186
|
+
return _ZNASNKOZcjs.type.call(void 0, key, element, options);
|
|
187
187
|
} else if (key === "Delete") {
|
|
188
|
-
return
|
|
188
|
+
return _ZNASNKOZcjs.type.call(void 0, "\x7F", element, options);
|
|
189
189
|
} else if (key === "Backspace") {
|
|
190
|
-
return
|
|
190
|
+
return _ZNASNKOZcjs.type.call(void 0, "\b", element, options);
|
|
191
191
|
} else if (key === "Enter" && element.tagName === "TEXTAREA") {
|
|
192
|
-
return
|
|
192
|
+
return _ZNASNKOZcjs.type.call(void 0, "\n", element, options);
|
|
193
193
|
}
|
|
194
194
|
}
|
|
195
195
|
if (((_a = element.ownerDocument) == null ? void 0 : _a.activeElement) !== element) {
|
|
196
196
|
if (element.tagName === "BODY") {
|
|
197
197
|
await _CYMYDRLScjs.blur.call(void 0, );
|
|
198
198
|
} else {
|
|
199
|
-
await
|
|
199
|
+
await _IZMYJH6Vcjs.focus.call(void 0, element);
|
|
200
200
|
}
|
|
201
201
|
}
|
|
202
202
|
await _HQ3KUD6Fcjs.sleep.call(void 0, );
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
var _QCXNVFD7cjs = require('./QCXNVFD7.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _7KITCMSCcjs = require('./7KITCMSC.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
var _UWCNB4SRcjs = require('./UWCNB4SR.cjs');
|
|
@@ -32,7 +32,7 @@ function select(text, element = document.body, options) {
|
|
|
32
32
|
return;
|
|
33
33
|
const document2 = element.ownerDocument;
|
|
34
34
|
await _UWCNB4SRcjs.hover.call(void 0, element, options);
|
|
35
|
-
await
|
|
35
|
+
await _7KITCMSCcjs.mouseDown.call(void 0, element, options);
|
|
36
36
|
await _VD3ERVOFcjs.dispatch.call(void 0,
|
|
37
37
|
element,
|
|
38
38
|
new Event("selectstart", {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _2PZMNP6Wcjs = require('./2PZMNP6W.cjs');
|
|
5
5
|
|
|
6
6
|
// src/tap.ts
|
|
7
7
|
function tap(element, options) {
|
|
8
|
-
return
|
|
8
|
+
return _2PZMNP6Wcjs.click.call(void 0, element, options, true);
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
|
|
@@ -18,12 +18,15 @@ function focus(element) {
|
|
|
18
18
|
return;
|
|
19
19
|
if (!_focus.isFocusable.call(void 0, element))
|
|
20
20
|
return;
|
|
21
|
-
const
|
|
21
|
+
const htmlElement = element;
|
|
22
|
+
const activeElement = _dom.getActiveElement.call(void 0,
|
|
23
|
+
htmlElement
|
|
24
|
+
);
|
|
22
25
|
if (activeElement == null ? void 0 : activeElement.dirty) {
|
|
23
26
|
await _VD3ERVOFcjs.dispatch.change(activeElement);
|
|
24
27
|
activeElement.dirty = false;
|
|
25
28
|
}
|
|
26
|
-
|
|
29
|
+
htmlElement.focus();
|
|
27
30
|
await _BXOTZFAKcjs.flushMicrotasks.call(void 0, );
|
|
28
31
|
});
|
|
29
32
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _IZMYJH6Vcjs = require('./IZMYJH6V.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _VD3ERVOFcjs = require('./VD3ERVOF.cjs');
|
|
@@ -49,7 +49,7 @@ function type(text, element, options = {}) {
|
|
|
49
49
|
return;
|
|
50
50
|
if (!_focus.isFocusable.call(void 0, element))
|
|
51
51
|
return;
|
|
52
|
-
await
|
|
52
|
+
await _IZMYJH6Vcjs.focus.call(void 0, element);
|
|
53
53
|
element.dirty = true;
|
|
54
54
|
const restoreEmailInput = workAroundEmailInput(element);
|
|
55
55
|
for (const char of text) {
|
package/cjs/blur.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function blur(element?: DirtiableElement | null): Promise<void>;
|
package/cjs/blur.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function blur(element?: DirtiableElement | null): Promise<void>;
|
package/cjs/click.cjs
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _2PZMNP6Wcjs = require('./__chunks/2PZMNP6W.cjs');
|
|
5
5
|
require('./__chunks/QCXNVFD7.cjs');
|
|
6
|
-
require('./__chunks/
|
|
6
|
+
require('./__chunks/7KITCMSC.cjs');
|
|
7
7
|
require('./__chunks/UWCNB4SR.cjs');
|
|
8
8
|
require('./__chunks/CYMYDRLS.cjs');
|
|
9
|
-
require('./__chunks/
|
|
9
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
10
10
|
require('./__chunks/VD3ERVOF.cjs');
|
|
11
11
|
require('./__chunks/HQ3KUD6F.cjs');
|
|
12
12
|
require('./__chunks/BXOTZFAK.cjs');
|
|
13
13
|
require('./__chunks/OVN5OYWK.cjs');
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
exports.click =
|
|
16
|
+
exports.click = _2PZMNP6Wcjs.click;
|
package/cjs/focus.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _IZMYJH6Vcjs = require('./__chunks/IZMYJH6V.cjs');
|
|
5
5
|
require('./__chunks/VD3ERVOF.cjs');
|
|
6
6
|
require('./__chunks/BXOTZFAK.cjs');
|
|
7
7
|
require('./__chunks/OVN5OYWK.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.focus =
|
|
10
|
+
exports.focus = _IZMYJH6Vcjs.focus;
|
package/cjs/index.cjs
CHANGED
|
@@ -5,19 +5,19 @@ require('./__chunks/I2BROIQW.cjs');
|
|
|
5
5
|
var _LG7B6NOGcjs = require('./__chunks/LG7B6NOG.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _IZ5UGCXWcjs = require('./__chunks/IZ5UGCXW.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _2PZMNP6Wcjs = require('./__chunks/2PZMNP6W.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _IL4UOQ5Ucjs = require('./__chunks/IL4UOQ5U.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
var _QCXNVFD7cjs = require('./__chunks/QCXNVFD7.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _7KITCMSCcjs = require('./__chunks/7KITCMSC.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
var _UWCNB4SRcjs = require('./__chunks/UWCNB4SR.cjs');
|
|
@@ -28,16 +28,16 @@ var _BIB7E6LNcjs = require('./__chunks/BIB7E6LN.cjs');
|
|
|
28
28
|
require('./__chunks/ERFCHS75.cjs');
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _DJWEA66Kcjs = require('./__chunks/DJWEA66K.cjs');
|
|
32
32
|
|
|
33
33
|
|
|
34
|
-
var
|
|
34
|
+
var _ZNASNKOZcjs = require('./__chunks/ZNASNKOZ.cjs');
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
var _CYMYDRLScjs = require('./__chunks/CYMYDRLS.cjs');
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
var
|
|
40
|
+
var _IZMYJH6Vcjs = require('./__chunks/IZMYJH6V.cjs');
|
|
41
41
|
|
|
42
42
|
|
|
43
43
|
var _VD3ERVOFcjs = require('./__chunks/VD3ERVOF.cjs');
|
|
@@ -62,4 +62,4 @@ require('./__chunks/OVN5OYWK.cjs');
|
|
|
62
62
|
|
|
63
63
|
|
|
64
64
|
|
|
65
|
-
exports.blur = _CYMYDRLScjs.blur; exports.click =
|
|
65
|
+
exports.blur = _CYMYDRLScjs.blur; exports.click = _2PZMNP6Wcjs.click; exports.dispatch = _VD3ERVOFcjs.dispatch; exports.focus = _IZMYJH6Vcjs.focus; exports.hover = _UWCNB4SRcjs.hover; exports.mouseDown = _7KITCMSCcjs.mouseDown; exports.mouseUp = _QCXNVFD7cjs.mouseUp; exports.press = _DJWEA66Kcjs.press; exports.q = _BIB7E6LNcjs.q; exports.query = _BIB7E6LNcjs.query; exports.select = _IL4UOQ5Ucjs.select; exports.sleep = _HQ3KUD6Fcjs.sleep; exports.tap = _IZ5UGCXWcjs.tap; exports.type = _ZNASNKOZcjs.type; exports.waitFor = _LG7B6NOGcjs.waitFor;
|
package/cjs/index.d.cts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
export * from "./blur.
|
|
2
|
-
export * from "./click.
|
|
3
|
-
export * from "./dispatch.
|
|
4
|
-
export * from "./focus.
|
|
5
|
-
export * from "./hover.
|
|
6
|
-
export * from "./mouse-down.
|
|
7
|
-
export * from "./mouse-up.
|
|
8
|
-
export * from "./press.
|
|
9
|
-
export * from "./query.
|
|
10
|
-
export * from "./select.
|
|
11
|
-
export * from "./sleep.
|
|
12
|
-
export * from "./tap.
|
|
13
|
-
export * from "./type.
|
|
14
|
-
export * from "./wait-for.
|
|
1
|
+
export * from "./blur.ts";
|
|
2
|
+
export * from "./click.ts";
|
|
3
|
+
export * from "./dispatch.ts";
|
|
4
|
+
export * from "./focus.ts";
|
|
5
|
+
export * from "./hover.ts";
|
|
6
|
+
export * from "./mouse-down.ts";
|
|
7
|
+
export * from "./mouse-up.ts";
|
|
8
|
+
export * from "./press.ts";
|
|
9
|
+
export * from "./query.ts";
|
|
10
|
+
export * from "./select.ts";
|
|
11
|
+
export * from "./sleep.ts";
|
|
12
|
+
export * from "./tap.ts";
|
|
13
|
+
export * from "./type.ts";
|
|
14
|
+
export * from "./wait-for.ts";
|
package/cjs/index.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
export * from "./blur.
|
|
2
|
-
export * from "./click.
|
|
3
|
-
export * from "./dispatch.
|
|
4
|
-
export * from "./focus.
|
|
5
|
-
export * from "./hover.
|
|
6
|
-
export * from "./mouse-down.
|
|
7
|
-
export * from "./mouse-up.
|
|
8
|
-
export * from "./press.
|
|
9
|
-
export * from "./query.
|
|
10
|
-
export * from "./select.
|
|
11
|
-
export * from "./sleep.
|
|
12
|
-
export * from "./tap.
|
|
13
|
-
export * from "./type.
|
|
14
|
-
export * from "./wait-for.
|
|
1
|
+
export * from "./blur.ts";
|
|
2
|
+
export * from "./click.ts";
|
|
3
|
+
export * from "./dispatch.ts";
|
|
4
|
+
export * from "./focus.ts";
|
|
5
|
+
export * from "./hover.ts";
|
|
6
|
+
export * from "./mouse-down.ts";
|
|
7
|
+
export * from "./mouse-up.ts";
|
|
8
|
+
export * from "./press.ts";
|
|
9
|
+
export * from "./query.ts";
|
|
10
|
+
export * from "./select.ts";
|
|
11
|
+
export * from "./sleep.ts";
|
|
12
|
+
export * from "./tap.ts";
|
|
13
|
+
export * from "./type.ts";
|
|
14
|
+
export * from "./wait-for.ts";
|
package/cjs/mouse-down.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _7KITCMSCcjs = require('./__chunks/7KITCMSC.cjs');
|
|
5
5
|
require('./__chunks/CYMYDRLS.cjs');
|
|
6
|
-
require('./__chunks/
|
|
6
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
7
7
|
require('./__chunks/VD3ERVOF.cjs');
|
|
8
8
|
require('./__chunks/BXOTZFAK.cjs');
|
|
9
9
|
require('./__chunks/OVN5OYWK.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
exports.mouseDown =
|
|
12
|
+
exports.mouseDown = _7KITCMSCcjs.mouseDown;
|
package/cjs/playwright.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { FrameLocator, Locator, Page } from "@playwright/test";
|
|
2
|
-
import type { AriaRole } from "./__aria-role.
|
|
2
|
+
import type { AriaRole } from "./__aria-role.ts";
|
|
3
3
|
type RoleQuery = (name?: string | RegExp, options?: Parameters<Page["getByRole"]>[1]) => Locator;
|
|
4
4
|
type RoleQueries = Record<AriaRole, RoleQuery>;
|
|
5
5
|
export declare function query(locator: Page | Locator | FrameLocator): RoleQueries;
|
package/cjs/playwright.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { FrameLocator, Locator, Page } from "@playwright/test";
|
|
2
|
-
import type { AriaRole } from "./__aria-role.
|
|
2
|
+
import type { AriaRole } from "./__aria-role.ts";
|
|
3
3
|
type RoleQuery = (name?: string | RegExp, options?: Parameters<Page["getByRole"]>[1]) => Locator;
|
|
4
4
|
type RoleQueries = Record<AriaRole, RoleQuery>;
|
|
5
5
|
export declare function query(locator: Page | Locator | FrameLocator): RoleQueries;
|
package/cjs/press.cjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./__chunks/
|
|
4
|
+
var _DJWEA66Kcjs = require('./__chunks/DJWEA66K.cjs');
|
|
5
|
+
require('./__chunks/ZNASNKOZ.cjs');
|
|
6
6
|
require('./__chunks/CYMYDRLS.cjs');
|
|
7
|
-
require('./__chunks/
|
|
7
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
8
8
|
require('./__chunks/VD3ERVOF.cjs');
|
|
9
9
|
require('./__chunks/HQ3KUD6F.cjs');
|
|
10
10
|
require('./__chunks/BXOTZFAK.cjs');
|
|
11
11
|
require('./__chunks/OVN5OYWK.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
exports.press =
|
|
14
|
+
exports.press = _DJWEA66Kcjs.press;
|
package/cjs/react.cjs
CHANGED
|
@@ -5,19 +5,19 @@ require('./__chunks/I2BROIQW.cjs');
|
|
|
5
5
|
var _LG7B6NOGcjs = require('./__chunks/LG7B6NOG.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _IZ5UGCXWcjs = require('./__chunks/IZ5UGCXW.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _2PZMNP6Wcjs = require('./__chunks/2PZMNP6W.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _IL4UOQ5Ucjs = require('./__chunks/IL4UOQ5U.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
var _QCXNVFD7cjs = require('./__chunks/QCXNVFD7.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _7KITCMSCcjs = require('./__chunks/7KITCMSC.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
var _UWCNB4SRcjs = require('./__chunks/UWCNB4SR.cjs');
|
|
@@ -28,16 +28,16 @@ var _BIB7E6LNcjs = require('./__chunks/BIB7E6LN.cjs');
|
|
|
28
28
|
require('./__chunks/ERFCHS75.cjs');
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _DJWEA66Kcjs = require('./__chunks/DJWEA66K.cjs');
|
|
32
32
|
|
|
33
33
|
|
|
34
|
-
var
|
|
34
|
+
var _ZNASNKOZcjs = require('./__chunks/ZNASNKOZ.cjs');
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
var _CYMYDRLScjs = require('./__chunks/CYMYDRLS.cjs');
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
var
|
|
40
|
+
var _IZMYJH6Vcjs = require('./__chunks/IZMYJH6V.cjs');
|
|
41
41
|
|
|
42
42
|
|
|
43
43
|
var _VD3ERVOFcjs = require('./__chunks/VD3ERVOF.cjs');
|
|
@@ -55,8 +55,8 @@ var _BXOTZFAKcjs = require('./__chunks/BXOTZFAK.cjs');
|
|
|
55
55
|
var _OVN5OYWKcjs = require('./__chunks/OVN5OYWK.cjs');
|
|
56
56
|
|
|
57
57
|
// src/react.tsx
|
|
58
|
-
var _react = require('react');
|
|
59
|
-
var
|
|
58
|
+
var _react = require('@testing-library/react'); var ReactTestingLibrary = _interopRequireWildcard(_react);
|
|
59
|
+
var _react2 = require('react');
|
|
60
60
|
var _jsxruntime = require('react/jsx-runtime');
|
|
61
61
|
async function render2(ui, options) {
|
|
62
62
|
const wrapper = (props) => {
|
|
@@ -64,7 +64,7 @@ async function render2(ui, options) {
|
|
|
64
64
|
const element = Wrapper ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Wrapper, _OVN5OYWKcjs.__spreadValues.call(void 0, {}, props)) : props.children;
|
|
65
65
|
if (!(options == null ? void 0 : options.strictMode))
|
|
66
66
|
return element;
|
|
67
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
67
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _react2.StrictMode, { children: element });
|
|
68
68
|
};
|
|
69
69
|
return _BXOTZFAKcjs.wrapAsync.call(void 0, async () => {
|
|
70
70
|
const { unmount } = ReactTestingLibrary.render(ui, _OVN5OYWKcjs.__spreadProps.call(void 0, _OVN5OYWKcjs.__spreadValues.call(void 0, {}, options), { wrapper }));
|
|
@@ -91,4 +91,4 @@ async function render2(ui, options) {
|
|
|
91
91
|
|
|
92
92
|
|
|
93
93
|
|
|
94
|
-
exports.blur = _CYMYDRLScjs.blur; exports.click =
|
|
94
|
+
exports.blur = _CYMYDRLScjs.blur; exports.click = _2PZMNP6Wcjs.click; exports.dispatch = _VD3ERVOFcjs.dispatch; exports.focus = _IZMYJH6Vcjs.focus; exports.hover = _UWCNB4SRcjs.hover; exports.mouseDown = _7KITCMSCcjs.mouseDown; exports.mouseUp = _QCXNVFD7cjs.mouseUp; exports.press = _DJWEA66Kcjs.press; exports.q = _BIB7E6LNcjs.q; exports.query = _BIB7E6LNcjs.query; exports.render = render2; exports.select = _IL4UOQ5Ucjs.select; exports.sleep = _HQ3KUD6Fcjs.sleep; exports.tap = _IZ5UGCXWcjs.tap; exports.type = _ZNASNKOZcjs.type; exports.waitFor = _LG7B6NOGcjs.waitFor;
|
package/cjs/react.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { ReactNode } from "react";
|
|
2
1
|
import * as ReactTestingLibrary from "@testing-library/react";
|
|
3
|
-
|
|
2
|
+
import type { ReactNode } from "react";
|
|
3
|
+
export * from "./index.ts";
|
|
4
4
|
export interface RenderOptions extends Omit<ReactTestingLibrary.RenderOptions, "queries"> {
|
|
5
5
|
strictMode?: boolean;
|
|
6
6
|
}
|
package/cjs/react.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { ReactNode } from "react";
|
|
2
1
|
import * as ReactTestingLibrary from "@testing-library/react";
|
|
3
|
-
|
|
2
|
+
import type { ReactNode } from "react";
|
|
3
|
+
export * from "./index.ts";
|
|
4
4
|
export interface RenderOptions extends Omit<ReactTestingLibrary.RenderOptions, "queries"> {
|
|
5
5
|
strictMode?: boolean;
|
|
6
6
|
}
|
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
|
|
4
|
+
var _IL4UOQ5Ucjs = require('./__chunks/IL4UOQ5U.cjs');
|
|
5
5
|
require('./__chunks/QCXNVFD7.cjs');
|
|
6
|
-
require('./__chunks/
|
|
6
|
+
require('./__chunks/7KITCMSC.cjs');
|
|
7
7
|
require('./__chunks/UWCNB4SR.cjs');
|
|
8
8
|
require('./__chunks/CYMYDRLS.cjs');
|
|
9
|
-
require('./__chunks/
|
|
9
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
10
10
|
require('./__chunks/VD3ERVOF.cjs');
|
|
11
11
|
require('./__chunks/HQ3KUD6F.cjs');
|
|
12
12
|
require('./__chunks/BXOTZFAK.cjs');
|
|
13
13
|
require('./__chunks/OVN5OYWK.cjs');
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
exports.select =
|
|
16
|
+
exports.select = _IL4UOQ5Ucjs.select;
|
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
|
|
5
|
-
require('./__chunks/
|
|
4
|
+
var _IZ5UGCXWcjs = require('./__chunks/IZ5UGCXW.cjs');
|
|
5
|
+
require('./__chunks/2PZMNP6W.cjs');
|
|
6
6
|
require('./__chunks/QCXNVFD7.cjs');
|
|
7
|
-
require('./__chunks/
|
|
7
|
+
require('./__chunks/7KITCMSC.cjs');
|
|
8
8
|
require('./__chunks/UWCNB4SR.cjs');
|
|
9
9
|
require('./__chunks/CYMYDRLS.cjs');
|
|
10
|
-
require('./__chunks/
|
|
10
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
11
11
|
require('./__chunks/VD3ERVOF.cjs');
|
|
12
12
|
require('./__chunks/HQ3KUD6F.cjs');
|
|
13
13
|
require('./__chunks/BXOTZFAK.cjs');
|
|
14
14
|
require('./__chunks/OVN5OYWK.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
exports.tap =
|
|
17
|
+
exports.tap = _IZ5UGCXWcjs.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
|
|
5
|
-
require('./__chunks/
|
|
4
|
+
var _ZNASNKOZcjs = require('./__chunks/ZNASNKOZ.cjs');
|
|
5
|
+
require('./__chunks/IZMYJH6V.cjs');
|
|
6
6
|
require('./__chunks/VD3ERVOF.cjs');
|
|
7
7
|
require('./__chunks/HQ3KUD6F.cjs');
|
|
8
8
|
require('./__chunks/BXOTZFAK.cjs');
|
|
9
9
|
require('./__chunks/OVN5OYWK.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
exports.type =
|
|
12
|
+
exports.type = _ZNASNKOZcjs.type;
|
package/cjs/type.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function type(text: string, element?: (DirtiableElement & HTMLElement) | null, options?: InputEventInit | KeyboardEventInit): Promise<void>;
|
package/cjs/type.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function type(text: string, element?: (DirtiableElement & HTMLElement) | null, options?: InputEventInit | KeyboardEventInit): Promise<void>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
type
|
|
4
|
-
} from "./
|
|
4
|
+
} from "./VVYOYAEF.js";
|
|
5
5
|
import {
|
|
6
6
|
blur
|
|
7
7
|
} from "./QE2YCTHV.js";
|
|
8
8
|
import {
|
|
9
9
|
focus
|
|
10
|
-
} from "./
|
|
10
|
+
} from "./VD2VFA32.js";
|
|
11
11
|
import {
|
|
12
12
|
dispatch
|
|
13
13
|
} from "./JIRMKL2I.js";
|
|
@@ -4,13 +4,13 @@ import {
|
|
|
4
4
|
} from "./V36IYEJN.js";
|
|
5
5
|
import {
|
|
6
6
|
mouseDown
|
|
7
|
-
} from "./
|
|
7
|
+
} from "./YGSLLIRN.js";
|
|
8
8
|
import {
|
|
9
9
|
hover
|
|
10
10
|
} from "./LRKW54RD.js";
|
|
11
11
|
import {
|
|
12
12
|
focus
|
|
13
|
-
} from "./
|
|
13
|
+
} from "./VD2VFA32.js";
|
|
14
14
|
import {
|
|
15
15
|
dispatch
|
|
16
16
|
} from "./JIRMKL2I.js";
|
|
@@ -25,12 +25,12 @@ import {
|
|
|
25
25
|
} from "./Q65FZOE2.js";
|
|
26
26
|
|
|
27
27
|
// src/click.ts
|
|
28
|
-
import {
|
|
28
|
+
import { isVisible } from "@ariakit/core/utils/dom";
|
|
29
29
|
import { isFocusable } from "@ariakit/core/utils/focus";
|
|
30
30
|
import { invariant } from "@ariakit/core/utils/misc";
|
|
31
31
|
function getClosestLabel(element) {
|
|
32
32
|
if (!isFocusable(element)) {
|
|
33
|
-
return closest(
|
|
33
|
+
return element.closest("label");
|
|
34
34
|
}
|
|
35
35
|
return null;
|
|
36
36
|
}
|
|
@@ -59,23 +59,25 @@ function setSelected(element, selected) {
|
|
|
59
59
|
element.selected = selected;
|
|
60
60
|
}
|
|
61
61
|
async function clickOption(element, eventOptions) {
|
|
62
|
-
const select = closest(
|
|
62
|
+
const select = element.closest("select");
|
|
63
63
|
if (!select) {
|
|
64
64
|
await dispatch.click(element, eventOptions);
|
|
65
65
|
return;
|
|
66
66
|
}
|
|
67
67
|
if (select.multiple) {
|
|
68
68
|
const options = Array.from(select.options);
|
|
69
|
-
const resetOptions = () =>
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
const resetOptions = () => {
|
|
70
|
+
for (const option of options) {
|
|
71
|
+
setSelected(option, false);
|
|
72
|
+
}
|
|
73
|
+
};
|
|
72
74
|
const selectRange = (a, b) => {
|
|
73
75
|
const from = Math.min(a, b);
|
|
74
76
|
const to = Math.max(a, b) + 1;
|
|
75
77
|
const selectedOptions = options.slice(from, to);
|
|
76
|
-
|
|
78
|
+
for (const option of selectedOptions) {
|
|
77
79
|
setSelected(option, true);
|
|
78
|
-
}
|
|
80
|
+
}
|
|
79
81
|
};
|
|
80
82
|
if (eventOptions == null ? void 0 : eventOptions.shiftKey) {
|
|
81
83
|
const elementIndex = options.indexOf(element);
|
|
@@ -18,12 +18,15 @@ function focus(element) {
|
|
|
18
18
|
return;
|
|
19
19
|
if (!isFocusable(element))
|
|
20
20
|
return;
|
|
21
|
-
const
|
|
21
|
+
const htmlElement = element;
|
|
22
|
+
const activeElement = getActiveElement(
|
|
23
|
+
htmlElement
|
|
24
|
+
);
|
|
22
25
|
if (activeElement == null ? void 0 : activeElement.dirty) {
|
|
23
26
|
await dispatch.change(activeElement);
|
|
24
27
|
activeElement.dirty = false;
|
|
25
28
|
}
|
|
26
|
-
|
|
29
|
+
htmlElement.focus();
|
|
27
30
|
await flushMicrotasks();
|
|
28
31
|
});
|
|
29
32
|
}
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./QE2YCTHV.js";
|
|
5
5
|
import {
|
|
6
6
|
focus
|
|
7
|
-
} from "./
|
|
7
|
+
} from "./VD2VFA32.js";
|
|
8
8
|
import {
|
|
9
9
|
dispatch
|
|
10
10
|
} from "./JIRMKL2I.js";
|
|
@@ -33,7 +33,7 @@ function mouseDown(element, options) {
|
|
|
33
33
|
}
|
|
34
34
|
if (defaultAllowed) {
|
|
35
35
|
const selection = getDocument(element).getSelection();
|
|
36
|
-
if (selection
|
|
36
|
+
if (selection == null ? void 0 : selection.rangeCount) {
|
|
37
37
|
const range = selection.getRangeAt(0);
|
|
38
38
|
if (!range.collapsed) {
|
|
39
39
|
selection.removeAllRanges();
|
package/esm/blur.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function blur(element?: DirtiableElement | null): Promise<void>;
|
package/esm/click.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
click
|
|
4
|
-
} from "./__chunks/
|
|
4
|
+
} from "./__chunks/HKMYG3ZJ.js";
|
|
5
5
|
import "./__chunks/V36IYEJN.js";
|
|
6
|
-
import "./__chunks/
|
|
6
|
+
import "./__chunks/YGSLLIRN.js";
|
|
7
7
|
import "./__chunks/LRKW54RD.js";
|
|
8
8
|
import "./__chunks/QE2YCTHV.js";
|
|
9
|
-
import "./__chunks/
|
|
9
|
+
import "./__chunks/VD2VFA32.js";
|
|
10
10
|
import "./__chunks/JIRMKL2I.js";
|
|
11
11
|
import "./__chunks/3EIGH73D.js";
|
|
12
12
|
import "./__chunks/7I2TICIC.js";
|
package/esm/focus.js
CHANGED
package/esm/index.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
export * from "./blur.
|
|
2
|
-
export * from "./click.
|
|
3
|
-
export * from "./dispatch.
|
|
4
|
-
export * from "./focus.
|
|
5
|
-
export * from "./hover.
|
|
6
|
-
export * from "./mouse-down.
|
|
7
|
-
export * from "./mouse-up.
|
|
8
|
-
export * from "./press.
|
|
9
|
-
export * from "./query.
|
|
10
|
-
export * from "./select.
|
|
11
|
-
export * from "./sleep.
|
|
12
|
-
export * from "./tap.
|
|
13
|
-
export * from "./type.
|
|
14
|
-
export * from "./wait-for.
|
|
1
|
+
export * from "./blur.ts";
|
|
2
|
+
export * from "./click.ts";
|
|
3
|
+
export * from "./dispatch.ts";
|
|
4
|
+
export * from "./focus.ts";
|
|
5
|
+
export * from "./hover.ts";
|
|
6
|
+
export * from "./mouse-down.ts";
|
|
7
|
+
export * from "./mouse-up.ts";
|
|
8
|
+
export * from "./press.ts";
|
|
9
|
+
export * from "./query.ts";
|
|
10
|
+
export * from "./select.ts";
|
|
11
|
+
export * from "./sleep.ts";
|
|
12
|
+
export * from "./tap.ts";
|
|
13
|
+
export * from "./type.ts";
|
|
14
|
+
export * from "./wait-for.ts";
|
package/esm/index.js
CHANGED
|
@@ -5,19 +5,19 @@ import {
|
|
|
5
5
|
} from "./__chunks/G2JU2LVB.js";
|
|
6
6
|
import {
|
|
7
7
|
tap
|
|
8
|
-
} from "./__chunks/
|
|
8
|
+
} from "./__chunks/64UIOMYC.js";
|
|
9
9
|
import {
|
|
10
10
|
click
|
|
11
|
-
} from "./__chunks/
|
|
11
|
+
} from "./__chunks/HKMYG3ZJ.js";
|
|
12
12
|
import {
|
|
13
13
|
select
|
|
14
|
-
} from "./__chunks/
|
|
14
|
+
} from "./__chunks/U5OPLWAZ.js";
|
|
15
15
|
import {
|
|
16
16
|
mouseUp
|
|
17
17
|
} from "./__chunks/V36IYEJN.js";
|
|
18
18
|
import {
|
|
19
19
|
mouseDown
|
|
20
|
-
} from "./__chunks/
|
|
20
|
+
} from "./__chunks/YGSLLIRN.js";
|
|
21
21
|
import {
|
|
22
22
|
hover
|
|
23
23
|
} from "./__chunks/LRKW54RD.js";
|
|
@@ -28,16 +28,16 @@ import {
|
|
|
28
28
|
import "./__chunks/CWTUOQ5Z.js";
|
|
29
29
|
import {
|
|
30
30
|
press
|
|
31
|
-
} from "./__chunks/
|
|
31
|
+
} from "./__chunks/DMIPXMWG.js";
|
|
32
32
|
import {
|
|
33
33
|
type
|
|
34
|
-
} from "./__chunks/
|
|
34
|
+
} from "./__chunks/VVYOYAEF.js";
|
|
35
35
|
import {
|
|
36
36
|
blur
|
|
37
37
|
} from "./__chunks/QE2YCTHV.js";
|
|
38
38
|
import {
|
|
39
39
|
focus
|
|
40
|
-
} from "./__chunks/
|
|
40
|
+
} from "./__chunks/VD2VFA32.js";
|
|
41
41
|
import {
|
|
42
42
|
dispatch
|
|
43
43
|
} from "./__chunks/JIRMKL2I.js";
|
package/esm/mouse-down.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
mouseDown
|
|
4
|
-
} from "./__chunks/
|
|
4
|
+
} from "./__chunks/YGSLLIRN.js";
|
|
5
5
|
import "./__chunks/QE2YCTHV.js";
|
|
6
|
-
import "./__chunks/
|
|
6
|
+
import "./__chunks/VD2VFA32.js";
|
|
7
7
|
import "./__chunks/JIRMKL2I.js";
|
|
8
8
|
import "./__chunks/7I2TICIC.js";
|
|
9
9
|
import "./__chunks/Q65FZOE2.js";
|
package/esm/playwright.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { FrameLocator, Locator, Page } from "@playwright/test";
|
|
2
|
-
import type { AriaRole } from "./__aria-role.
|
|
2
|
+
import type { AriaRole } from "./__aria-role.ts";
|
|
3
3
|
type RoleQuery = (name?: string | RegExp, options?: Parameters<Page["getByRole"]>[1]) => Locator;
|
|
4
4
|
type RoleQueries = Record<AriaRole, RoleQuery>;
|
|
5
5
|
export declare function query(locator: Page | Locator | FrameLocator): RoleQueries;
|
package/esm/press.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
press
|
|
4
|
-
} from "./__chunks/
|
|
5
|
-
import "./__chunks/
|
|
4
|
+
} from "./__chunks/DMIPXMWG.js";
|
|
5
|
+
import "./__chunks/VVYOYAEF.js";
|
|
6
6
|
import "./__chunks/QE2YCTHV.js";
|
|
7
|
-
import "./__chunks/
|
|
7
|
+
import "./__chunks/VD2VFA32.js";
|
|
8
8
|
import "./__chunks/JIRMKL2I.js";
|
|
9
9
|
import "./__chunks/3EIGH73D.js";
|
|
10
10
|
import "./__chunks/7I2TICIC.js";
|
package/esm/react.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { ReactNode } from "react";
|
|
2
1
|
import * as ReactTestingLibrary from "@testing-library/react";
|
|
3
|
-
|
|
2
|
+
import type { ReactNode } from "react";
|
|
3
|
+
export * from "./index.ts";
|
|
4
4
|
export interface RenderOptions extends Omit<ReactTestingLibrary.RenderOptions, "queries"> {
|
|
5
5
|
strictMode?: boolean;
|
|
6
6
|
}
|
package/esm/react.js
CHANGED
|
@@ -5,19 +5,19 @@ import {
|
|
|
5
5
|
} from "./__chunks/G2JU2LVB.js";
|
|
6
6
|
import {
|
|
7
7
|
tap
|
|
8
|
-
} from "./__chunks/
|
|
8
|
+
} from "./__chunks/64UIOMYC.js";
|
|
9
9
|
import {
|
|
10
10
|
click
|
|
11
|
-
} from "./__chunks/
|
|
11
|
+
} from "./__chunks/HKMYG3ZJ.js";
|
|
12
12
|
import {
|
|
13
13
|
select
|
|
14
|
-
} from "./__chunks/
|
|
14
|
+
} from "./__chunks/U5OPLWAZ.js";
|
|
15
15
|
import {
|
|
16
16
|
mouseUp
|
|
17
17
|
} from "./__chunks/V36IYEJN.js";
|
|
18
18
|
import {
|
|
19
19
|
mouseDown
|
|
20
|
-
} from "./__chunks/
|
|
20
|
+
} from "./__chunks/YGSLLIRN.js";
|
|
21
21
|
import {
|
|
22
22
|
hover
|
|
23
23
|
} from "./__chunks/LRKW54RD.js";
|
|
@@ -28,16 +28,16 @@ import {
|
|
|
28
28
|
import "./__chunks/CWTUOQ5Z.js";
|
|
29
29
|
import {
|
|
30
30
|
press
|
|
31
|
-
} from "./__chunks/
|
|
31
|
+
} from "./__chunks/DMIPXMWG.js";
|
|
32
32
|
import {
|
|
33
33
|
type
|
|
34
|
-
} from "./__chunks/
|
|
34
|
+
} from "./__chunks/VVYOYAEF.js";
|
|
35
35
|
import {
|
|
36
36
|
blur
|
|
37
37
|
} from "./__chunks/QE2YCTHV.js";
|
|
38
38
|
import {
|
|
39
39
|
focus
|
|
40
|
-
} from "./__chunks/
|
|
40
|
+
} from "./__chunks/VD2VFA32.js";
|
|
41
41
|
import {
|
|
42
42
|
dispatch
|
|
43
43
|
} from "./__chunks/JIRMKL2I.js";
|
|
@@ -55,8 +55,8 @@ import {
|
|
|
55
55
|
} from "./__chunks/Q65FZOE2.js";
|
|
56
56
|
|
|
57
57
|
// src/react.tsx
|
|
58
|
-
import { StrictMode } from "react";
|
|
59
58
|
import * as ReactTestingLibrary from "@testing-library/react";
|
|
59
|
+
import { StrictMode } from "react";
|
|
60
60
|
import { jsx } from "react/jsx-runtime";
|
|
61
61
|
async function render2(ui, options) {
|
|
62
62
|
const wrapper = (props) => {
|
package/esm/select.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
select
|
|
4
|
-
} from "./__chunks/
|
|
4
|
+
} from "./__chunks/U5OPLWAZ.js";
|
|
5
5
|
import "./__chunks/V36IYEJN.js";
|
|
6
|
-
import "./__chunks/
|
|
6
|
+
import "./__chunks/YGSLLIRN.js";
|
|
7
7
|
import "./__chunks/LRKW54RD.js";
|
|
8
8
|
import "./__chunks/QE2YCTHV.js";
|
|
9
|
-
import "./__chunks/
|
|
9
|
+
import "./__chunks/VD2VFA32.js";
|
|
10
10
|
import "./__chunks/JIRMKL2I.js";
|
|
11
11
|
import "./__chunks/3EIGH73D.js";
|
|
12
12
|
import "./__chunks/7I2TICIC.js";
|
package/esm/tap.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
tap
|
|
4
|
-
} from "./__chunks/
|
|
5
|
-
import "./__chunks/
|
|
4
|
+
} from "./__chunks/64UIOMYC.js";
|
|
5
|
+
import "./__chunks/HKMYG3ZJ.js";
|
|
6
6
|
import "./__chunks/V36IYEJN.js";
|
|
7
|
-
import "./__chunks/
|
|
7
|
+
import "./__chunks/YGSLLIRN.js";
|
|
8
8
|
import "./__chunks/LRKW54RD.js";
|
|
9
9
|
import "./__chunks/QE2YCTHV.js";
|
|
10
|
-
import "./__chunks/
|
|
10
|
+
import "./__chunks/VD2VFA32.js";
|
|
11
11
|
import "./__chunks/JIRMKL2I.js";
|
|
12
12
|
import "./__chunks/3EIGH73D.js";
|
|
13
13
|
import "./__chunks/7I2TICIC.js";
|
package/esm/type.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { DirtiableElement } from "./__utils.
|
|
1
|
+
import type { DirtiableElement } from "./__utils.ts";
|
|
2
2
|
export declare function type(text: string, element?: (DirtiableElement & HTMLElement) | null, options?: InputEventInit | KeyboardEventInit): Promise<void>;
|
package/esm/type.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
type
|
|
4
|
-
} from "./__chunks/
|
|
5
|
-
import "./__chunks/
|
|
4
|
+
} from "./__chunks/VVYOYAEF.js";
|
|
5
|
+
import "./__chunks/VD2VFA32.js";
|
|
6
6
|
import "./__chunks/JIRMKL2I.js";
|
|
7
7
|
import "./__chunks/3EIGH73D.js";
|
|
8
8
|
import "./__chunks/7I2TICIC.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ariakit/test",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.16",
|
|
4
4
|
"description": "Ariakit test utils",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"license": "MIT",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"url": "https://github.com/diegohaz"
|
|
21
21
|
},
|
|
22
22
|
"scripts": {
|
|
23
|
-
"lint": "
|
|
23
|
+
"lint": "biome check .",
|
|
24
24
|
"build": "node ../../scripts/build/build.js",
|
|
25
25
|
"clean": "node ../../scripts/build/clean.js"
|
|
26
26
|
},
|
|
@@ -29,13 +29,13 @@
|
|
|
29
29
|
"react"
|
|
30
30
|
],
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@ariakit/core": "0.4.
|
|
33
|
-
"@testing-library/dom": "^8.0.0 || ^9.0.0"
|
|
32
|
+
"@ariakit/core": "0.4.7",
|
|
33
|
+
"@testing-library/dom": "^8.0.0 || ^9.0.0 || ^10.0.0"
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|
|
36
36
|
"@playwright/test": "^1.27.0",
|
|
37
|
-
"@testing-library/react": "^12.0.0 || ^13.0.0 || ^14.0.0",
|
|
38
|
-
"react": "^17.0.0 || ^18.0.0"
|
|
37
|
+
"@testing-library/react": "^12.0.0 || ^13.0.0 || ^14.0.0 || ^15.0.0",
|
|
38
|
+
"react": "^17.0.0 || ^18.0.0 || ^19.0.0"
|
|
39
39
|
},
|
|
40
40
|
"peerDependenciesMeta": {
|
|
41
41
|
"@playwright/test": {
|