@uxf/e2e-playwright 15.2.1 → 15.3.1
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/package.json +3 -3
- package/ui/multi-select.e2e.js +17 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uxf/e2e-playwright",
|
|
3
|
-
"version": "15.
|
|
3
|
+
"version": "15.3.1",
|
|
4
4
|
"description": "UXF Playwright helpers",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -19,13 +19,13 @@
|
|
|
19
19
|
"devDependencies": {
|
|
20
20
|
"@playwright/test": "1.64.1",
|
|
21
21
|
"@uxf/core": "15.2.1",
|
|
22
|
-
"@uxf/ui": "15.
|
|
22
|
+
"@uxf/ui": "15.3.1",
|
|
23
23
|
"dayjs": "^1.11.23"
|
|
24
24
|
},
|
|
25
25
|
"peerDependencies": {
|
|
26
26
|
"@playwright/test": "1.64.1",
|
|
27
27
|
"@uxf/core": "15.2.1",
|
|
28
|
-
"@uxf/ui": "15.
|
|
28
|
+
"@uxf/ui": "15.3.1",
|
|
29
29
|
"dayjs": "^1.11.23"
|
|
30
30
|
}
|
|
31
31
|
}
|
package/ui/multi-select.e2e.js
CHANGED
|
@@ -19,3 +19,20 @@ const components_1 = require("../components");
|
|
|
19
19
|
await ui.multiSelect({ $name: "stav-partial" }).changeContainingText(["Otevřené"]);
|
|
20
20
|
await (0, test_1.expect)(page.getByTestId("selected-partial-value")).toHaveText("otevrene");
|
|
21
21
|
});
|
|
22
|
+
// FEB-585: with exactly two options selected and the dropdown opened before, a chip's close button
|
|
23
|
+
// removed the other option. The closed popup stays mounted, so removing a chip re-mounts its option
|
|
24
|
+
// and Base UI pruned a stale value against the list. jsdom unmounts the closed popup, so only a
|
|
25
|
+
// browser runs this path.
|
|
26
|
+
(0, test_1.test)("MultiSelect - chip close button removes its own option", async ({ page }) => {
|
|
27
|
+
const ui = (0, components_1.createUi)(page);
|
|
28
|
+
await page.goto("/examples/ui/multi-select/Default");
|
|
29
|
+
const multiSelect = ui.multiSelect({ $name: "default" });
|
|
30
|
+
await multiSelect.change(["Option red", "Option blue"]);
|
|
31
|
+
const chips = multiSelect.locator.locator(".uxf-multi-select__input-chip");
|
|
32
|
+
await (0, test_1.expect)(chips.locator(".uxf-chip__text")).toHaveText(["Option red", "Option blue"]);
|
|
33
|
+
await chips.filter({ hasText: "Option blue" }).locator(".uxf-chip__button").click();
|
|
34
|
+
await (0, test_1.expect)(chips.locator(".uxf-chip__text")).toHaveText(["Option red"]);
|
|
35
|
+
await multiSelect.change(["Option blue"]);
|
|
36
|
+
await chips.filter({ hasText: "Option red" }).locator(".uxf-chip__button").click();
|
|
37
|
+
await (0, test_1.expect)(chips.locator(".uxf-chip__text")).toHaveText(["Option blue"]);
|
|
38
|
+
});
|