Skip to content

Commit 572f732

Browse files
Merge branch 'next' into ROU-11728
2 parents f302477 + a7233c2 commit 572f732

File tree

34 files changed

+55
-3
lines changed

34 files changed

+55
-3
lines changed

core/src/components/input/input.ionic.scss

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,6 @@
6565

6666
// Cursor should match the native input when hovering over the target area.
6767
cursor: text;
68-
69-
z-index: 1;
7068
}
7169

7270
::slotted([slot="start"]),

core/src/components/input/test/basic/input.e2e.ts

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ configs().forEach(({ title, screenshot, config }) => {
2929
await expect(input).toHaveScreenshot(screenshot(`input-with-placeholder`));
3030
});
3131
});
32-
3332
test.describe('input with clear button', () => {
3433
test('should not have visual regressions with default label', async ({ page }) => {
3534
await page.setContent(
@@ -63,6 +62,43 @@ configs().forEach(({ title, screenshot, config }) => {
6362
await expect(input).toHaveScreenshot(screenshot(`input-with-clear-button-stacked`));
6463
});
6564
});
65+
test.describe('input click behaviors', () => {
66+
test('should not have visual regressions when user double clicks', async ({ page }) => {
67+
await page.setContent(
68+
`
69+
<ion-input
70+
label="Label"
71+
clear-input="true"
72+
value="Text"
73+
></ion-input>
74+
`,
75+
config
76+
);
77+
const input = page.locator('ion-input');
78+
const nativeInput = input.locator('input');
79+
await nativeInput.dblclick();
80+
// Validates the display of an input with a clear button.
81+
await expect(input).toHaveScreenshot(screenshot(`input-dbclick`));
82+
});
83+
test('should not have visual regressions with stacked label when user double clicks', async ({ page }) => {
84+
await page.setContent(
85+
`
86+
<ion-input
87+
label="Label"
88+
label-placement="stacked"
89+
clear-input="true"
90+
value="Text"
91+
></ion-input>
92+
`,
93+
config
94+
);
95+
const input = page.locator('ion-input');
96+
const nativeInput = input.locator('input');
97+
await nativeInput.dblclick();
98+
// Validates the display of an input with a clear button.
99+
await expect(input).toHaveScreenshot(screenshot(`input-dbclick-stacked`));
100+
});
101+
});
66102
});
67103
});
68104

@@ -185,6 +221,24 @@ configs({ modes: ['ionic-md'] }).forEach(({ title, screenshot, config }) => {
185221
const container = page.locator('#container');
186222
await expect(container).toHaveScreenshot(screenshot(`input-clear-button-focused`));
187223
});
224+
225+
test('should not have visual regressions when user double clicks', async ({ page }) => {
226+
await page.setContent(
227+
`
228+
<ion-input
229+
label="Label"
230+
label-placement="stacked"
231+
clear-input="true"
232+
value="Text"
233+
></ion-input>
234+
`,
235+
config
236+
);
237+
const input = page.locator('ion-input');
238+
const nativeInput = input.locator('input');
239+
await nativeInput.dblclick();
240+
await expect(input).toHaveScreenshot(screenshot(`input-dbclick`));
241+
});
188242
});
189243
});
190244

2.67 KB
Loading
3.22 KB
Loading
2.85 KB
Loading
2.67 KB
Loading
3.2 KB
Loading
2.87 KB
Loading
2.34 KB
Loading
2.51 KB
Loading

0 commit comments

Comments
 (0)