Skip to content

Commit b3aeac1

Browse files
committed
style: lint
1 parent 7e86b42 commit b3aeac1

File tree

2 files changed

+20
-9
lines changed

2 files changed

+20
-9
lines changed

core/src/components/checkbox/test/bottom-content/checkbox.e2e.ts

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83,9 +83,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
8383

8484
await expect(input).not.toHaveAttribute('aria-invalid');
8585
});
86-
test('input should not have aria-describedby attribute when no hint or error text is present', async ({
87-
page,
88-
}) => {
86+
test('input should not have aria-describedby attribute when no hint or error text is present', async ({ page }) => {
8987
await page.setContent(`<ion-checkbox>Label</ion-checkbox>`, config);
9088

9189
const input = page.locator('ion-checkbox input[type=checkbox]');
@@ -107,19 +105,30 @@ configs({ modes: ['ios', 'md'], directions: ['ltr'] }).forEach(({ title, screens
107105
await expect(bottomEl).toHaveScreenshot(screenshot(`checkbox-bottom-content-helper`));
108106
});
109107
test('should not have visual regressions when rendering helper text with wrapping text', async ({ page }) => {
110-
await page.setContent(`<ion-checkbox helper-text="Helper text helper text helper text helper text helper text helper text helper text helper text helper text">Label</ion-checkbox>`, config);
108+
await page.setContent(
109+
`<ion-checkbox helper-text="Helper text helper text helper text helper text helper text helper text helper text helper text helper text">Label</ion-checkbox>`,
110+
config
111+
);
111112

112113
const bottomEl = page.locator('ion-checkbox');
113114
await expect(bottomEl).toHaveScreenshot(screenshot(`checkbox-bottom-content-helper-wrapping`));
114115
});
115116
test('should not have visual regressions when rendering helper text with a stacked label', async ({ page }) => {
116-
await page.setContent(`<ion-checkbox label-placement="stacked" helper-text="Helper text">Label</ion-checkbox>`, config);
117+
await page.setContent(
118+
`<ion-checkbox label-placement="stacked" helper-text="Helper text">Label</ion-checkbox>`,
119+
config
120+
);
117121

118122
const bottomEl = page.locator('ion-checkbox');
119123
await expect(bottomEl).toHaveScreenshot(screenshot(`checkbox-bottom-content-helper-label-stacked`));
120124
});
121-
test('should not have visual regressions when rendering helper text with a stacked label and wrapping text', async ({ page }) => {
122-
await page.setContent(`<ion-checkbox label-placement="stacked" helper-text="Helper text helper text helper text helper text helper text helper text helper text helper text helper text">Label</ion-checkbox>`, config);
125+
test('should not have visual regressions when rendering helper text with a stacked label and wrapping text', async ({
126+
page,
127+
}) => {
128+
await page.setContent(
129+
`<ion-checkbox label-placement="stacked" helper-text="Helper text helper text helper text helper text helper text helper text helper text helper text helper text">Label</ion-checkbox>`,
130+
config
131+
);
123132

124133
const bottomEl = page.locator('ion-checkbox');
125134
await expect(bottomEl).toHaveScreenshot(screenshot(`checkbox-bottom-content-helper-label-stacked-wrapping`));

core/src/components/checkbox/test/bottom-content/index.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,9 @@ <h2>Helper & Error Text: Label End</h2>
105105

106106
<div class="grid-item">
107107
<h2>Helper & Error Text: Label Stacked</h2>
108-
<ion-checkbox label-placement="stacked" helper-text="Helper text" error-text="Error text">Label</ion-checkbox>
108+
<ion-checkbox label-placement="stacked" helper-text="Helper text" error-text="Error text"
109+
>Label</ion-checkbox
110+
>
109111
</div>
110112

111113
<div class="grid-item">
@@ -120,7 +122,7 @@ <h2>Helper & Error Text: Label Fixed</h2>
120122
const checkboxes = document.querySelectorAll('ion-checkbox');
121123

122124
function toggleValid() {
123-
checkboxes.forEach(checkbox => {
125+
checkboxes.forEach((checkbox) => {
124126
checkbox.classList.toggle('ion-invalid');
125127
checkbox.classList.toggle('ion-touched');
126128
});

0 commit comments

Comments
 (0)