@digigov/ui 2.0.0-b15d5d44 → 2.0.0-b19b7fe2
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/cjs/feedback/ErrorSummary/ErrorSummary.stories/index.js +0 -3
- package/cjs/feedback/ErrorSummary/ErrorSummary.stories.js.map +2 -2
- package/cjs/registry/index.js +62 -64
- package/cjs/registry.js.map +2 -2
- package/cjs/utils/hooks/useScreen/index.js +1 -1
- package/cjs/utils/hooks/useScreen.js.map +2 -2
- package/feedback/ErrorSummary/ErrorSummary.stories/index.js +0 -2
- package/feedback/ErrorSummary/ErrorSummary.stories.d.ts +0 -1
- package/feedback/ErrorSummary/ErrorSummary.stories.js.map +2 -2
- package/index.js +1 -1
- package/package.json +5 -5
- package/registry/index.js +62 -64
- package/src/app/BannerContainer/index.test.tsx +11 -10
- package/src/app/Footer/index.test.tsx +32 -31
- package/src/app/Header/index.test.tsx +23 -22
- package/src/app/Loader/index.test.tsx +14 -13
- package/src/app/Masthead/index.test.tsx +20 -19
- package/src/app/Modal/index.test.tsx +26 -25
- package/src/app/NotFound/index.test.tsx +11 -10
- package/src/app/Panel/index.test.tsx +11 -10
- package/src/app/PhaseBannerHeader/index.test.tsx +11 -10
- package/src/app/QrCodeViewer/index.test.tsx +14 -13
- package/src/app/Skeleton/index.test.tsx +35 -34
- package/src/content/Accordion/index.test.tsx +20 -19
- package/src/content/Blockquote/index.test.tsx +14 -13
- package/src/content/Card/index.test.tsx +41 -40
- package/src/content/Chip/index.test.tsx +23 -22
- package/src/content/Details/index.test.tsx +11 -10
- package/src/content/List/index.test.tsx +26 -25
- package/src/content/Markdown/index.test.tsx +11 -10
- package/src/content/SafeHTML/index.test.tsx +11 -10
- package/src/content/StepNav/index.test.tsx +23 -22
- package/src/content/SummaryList/index.test.tsx +32 -31
- package/src/content/Table/index.test.tsx +63 -62
- package/src/content/TaskList/index.test.tsx +14 -13
- package/src/content/Timeline/index.test.tsx +14 -13
- package/src/feedback/CopyToClipboard/index.test.tsx +17 -16
- package/src/feedback/ErrorSummary/ErrorSummary.stories.js +0 -1
- package/src/feedback/ErrorSummary/index.test.tsx +26 -29
- package/src/feedback/NotificationBanner/index.test.tsx +17 -16
- package/src/feedback/PhaseBanner/index.test.tsx +14 -13
- package/src/feedback/WarningText/index.test.tsx +17 -16
- package/src/form/AutoComplete/index.test.tsx +38 -37
- package/src/form/Button/index.test.tsx +44 -43
- package/src/form/Checkbox/index.test.tsx +38 -37
- package/src/form/DateInputContainer/index.test.tsx +23 -22
- package/src/form/ErrorMessage/index.test.tsx +17 -16
- package/src/form/FileUpload/index.test.tsx +14 -13
- package/src/form/RadioContainer/index.test.tsx +38 -37
- package/src/form/SearchContainer/index.test.tsx +11 -10
- package/src/form/SelectContainer/index.test.tsx +20 -19
- package/src/form/SingleCharacterInputs/index.test.tsx +24 -20
- package/src/form/TextArea/index.test.tsx +32 -31
- package/src/form/TextInput/index.test.tsx +38 -37
- package/src/layouts/Basic/index.test.tsx +20 -19
- package/src/layouts/Grid/index.test.tsx +17 -16
- package/src/layouts/Screen/index.test.tsx +20 -19
- package/src/layouts/Stack/index.test.tsx +26 -25
- package/src/navigation/BackLink/index.test.tsx +11 -10
- package/src/navigation/BackToTopLink/index.test.tsx +14 -13
- package/src/navigation/Breadcrumbs/index.test.tsx +23 -22
- package/src/navigation/Drawer/index.test.tsx +17 -16
- package/src/navigation/Dropdown/index.test.tsx +41 -40
- package/src/navigation/Link/index.test.tsx +29 -28
- package/src/navigation/NavList/index.test.tsx +35 -34
- package/src/navigation/Pagination/index.test.tsx +29 -28
- package/src/navigation/SkipLink/index.test.tsx +11 -10
- package/src/navigation/Tabs/index.test.tsx +20 -19
- package/src/registry.js +62 -64
- package/src/typography/CodeBlock/index.test.tsx +20 -19
- package/src/typography/Heading/index.test.tsx +11 -10
- package/src/typography/HeadingCaption/index.test.tsx +14 -13
- package/src/typography/Hint/index.test.tsx +14 -13
- package/src/typography/NormalText/index.test.tsx +20 -19
- package/src/typography/Paragraph/index.test.tsx +23 -22
- package/src/utils/VisuallyHidden/index.test.tsx +11 -10
- package/src/utils/hooks/useScreen.ts +3 -2
- package/utils/hooks/useScreen/index.js +1 -1
- package/utils/hooks/useScreen.js.map +2 -2
- package/cjs/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput/index.js +0 -49
- package/cjs/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput.js.map +0 -7
- package/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput/index.js +0 -16
- package/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput/package.json +0 -6
- package/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput.d.ts +0 -3
- package/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput.js.map +0 -7
- package/src/feedback/ErrorSummary/__stories__/ErrorGroupLinkedToInput.tsx +0 -47
|
@@ -1,32 +1,33 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/app/Masthead/__stories__/Default';
|
|
5
4
|
import { Secondary } from '@digigov/ui/app/Masthead/__stories__/Secondary';
|
|
6
5
|
import { WithElements } from '@digigov/ui/app/Masthead/__stories__/WithElements';
|
|
7
6
|
import { WithLogo } from '@digigov/ui/app/Masthead/__stories__/WithLogo';
|
|
7
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
8
8
|
|
|
9
9
|
test('renders the All Masthead variants', async ({ mount, page }) => {
|
|
10
10
|
await mount(
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
</
|
|
25
|
-
|
|
26
|
-
)
|
|
11
|
+
<div>
|
|
12
|
+
<TestVariant title="Default">
|
|
13
|
+
<Default />
|
|
14
|
+
</TestVariant>
|
|
15
|
+
<TestVariant title="Secondary">
|
|
16
|
+
<Secondary />
|
|
17
|
+
</TestVariant>
|
|
18
|
+
<TestVariant title="WithElements">
|
|
19
|
+
<WithElements />
|
|
20
|
+
</TestVariant>
|
|
21
|
+
<TestVariant title="WithLogo">
|
|
22
|
+
<WithLogo />
|
|
23
|
+
</TestVariant>
|
|
24
|
+
</div>
|
|
25
|
+
);
|
|
27
26
|
await page.evaluate(() => document.fonts.ready);
|
|
28
27
|
|
|
29
|
-
const screenshot = await page.screenshot({
|
|
28
|
+
const screenshot = await page.screenshot({
|
|
29
|
+
fullPage: true,
|
|
30
|
+
animations: 'disabled',
|
|
31
|
+
});
|
|
30
32
|
expect(screenshot).toMatchSnapshot();
|
|
31
33
|
});
|
|
32
|
-
|
|
@@ -1,40 +1,41 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { AlertDialog } from '@digigov/ui/app/Modal/__stories__/AlertDialog';
|
|
5
4
|
import { Auto } from '@digigov/ui/app/Modal/__stories__/Auto';
|
|
6
5
|
import { Default } from '@digigov/ui/app/Modal/__stories__/Default';
|
|
7
6
|
import { Dense } from '@digigov/ui/app/Modal/__stories__/Dense';
|
|
8
7
|
import { WithHooks } from '@digigov/ui/app/Modal/__stories__/WithHooks';
|
|
9
8
|
import { WithoutModalGaps } from '@digigov/ui/app/Modal/__stories__/WithoutModalGaps';
|
|
9
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
10
10
|
|
|
11
11
|
test('renders the All Modal variants', async ({ mount, page }) => {
|
|
12
12
|
await mount(
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</
|
|
33
|
-
|
|
34
|
-
)
|
|
13
|
+
<div>
|
|
14
|
+
<TestVariant title="AlertDialog">
|
|
15
|
+
<AlertDialog />
|
|
16
|
+
</TestVariant>
|
|
17
|
+
<TestVariant title="Auto">
|
|
18
|
+
<Auto />
|
|
19
|
+
</TestVariant>
|
|
20
|
+
<TestVariant title="Default">
|
|
21
|
+
<Default />
|
|
22
|
+
</TestVariant>
|
|
23
|
+
<TestVariant title="Dense">
|
|
24
|
+
<Dense />
|
|
25
|
+
</TestVariant>
|
|
26
|
+
<TestVariant title="WithHooks">
|
|
27
|
+
<WithHooks />
|
|
28
|
+
</TestVariant>
|
|
29
|
+
<TestVariant title="WithoutModalGaps">
|
|
30
|
+
<WithoutModalGaps />
|
|
31
|
+
</TestVariant>
|
|
32
|
+
</div>
|
|
33
|
+
);
|
|
35
34
|
await page.evaluate(() => document.fonts.ready);
|
|
36
35
|
|
|
37
|
-
const screenshot = await page.screenshot({
|
|
36
|
+
const screenshot = await page.screenshot({
|
|
37
|
+
fullPage: true,
|
|
38
|
+
animations: 'disabled',
|
|
39
|
+
});
|
|
38
40
|
expect(screenshot).toMatchSnapshot();
|
|
39
41
|
});
|
|
40
|
-
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/app/NotFound/__stories__/Default';
|
|
4
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
5
5
|
|
|
6
6
|
test('renders the All NotFound variants', async ({ mount, page }) => {
|
|
7
7
|
await mount(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</
|
|
13
|
-
|
|
14
|
-
)
|
|
8
|
+
<div>
|
|
9
|
+
<TestVariant title="Default">
|
|
10
|
+
<Default />
|
|
11
|
+
</TestVariant>
|
|
12
|
+
</div>
|
|
13
|
+
);
|
|
15
14
|
await page.evaluate(() => document.fonts.ready);
|
|
16
15
|
|
|
17
|
-
const screenshot = await page.screenshot({
|
|
16
|
+
const screenshot = await page.screenshot({
|
|
17
|
+
fullPage: true,
|
|
18
|
+
animations: 'disabled',
|
|
19
|
+
});
|
|
18
20
|
expect(screenshot).toMatchSnapshot();
|
|
19
21
|
});
|
|
20
|
-
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/app/Panel/__stories__/Default';
|
|
4
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
5
5
|
|
|
6
6
|
test('renders the All Panel variants', async ({ mount, page }) => {
|
|
7
7
|
await mount(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</
|
|
13
|
-
|
|
14
|
-
)
|
|
8
|
+
<div>
|
|
9
|
+
<TestVariant title="Default">
|
|
10
|
+
<Default />
|
|
11
|
+
</TestVariant>
|
|
12
|
+
</div>
|
|
13
|
+
);
|
|
15
14
|
await page.evaluate(() => document.fonts.ready);
|
|
16
15
|
|
|
17
|
-
const screenshot = await page.screenshot({
|
|
16
|
+
const screenshot = await page.screenshot({
|
|
17
|
+
fullPage: true,
|
|
18
|
+
animations: 'disabled',
|
|
19
|
+
});
|
|
18
20
|
expect(screenshot).toMatchSnapshot();
|
|
19
21
|
});
|
|
20
|
-
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/app/PhaseBannerHeader/__stories__/Default';
|
|
4
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
5
5
|
|
|
6
6
|
test('renders the All PhaseBannerHeader variants', async ({ mount, page }) => {
|
|
7
7
|
await mount(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</
|
|
13
|
-
|
|
14
|
-
)
|
|
8
|
+
<div>
|
|
9
|
+
<TestVariant title="Default">
|
|
10
|
+
<Default />
|
|
11
|
+
</TestVariant>
|
|
12
|
+
</div>
|
|
13
|
+
);
|
|
15
14
|
await page.evaluate(() => document.fonts.ready);
|
|
16
15
|
|
|
17
|
-
const screenshot = await page.screenshot({
|
|
16
|
+
const screenshot = await page.screenshot({
|
|
17
|
+
fullPage: true,
|
|
18
|
+
animations: 'disabled',
|
|
19
|
+
});
|
|
18
20
|
expect(screenshot).toMatchSnapshot();
|
|
19
21
|
});
|
|
20
|
-
|
|
@@ -1,24 +1,25 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Custom } from '@digigov/ui/app/QrCodeViewer/__stories__/Custom';
|
|
5
4
|
import { Default } from '@digigov/ui/app/QrCodeViewer/__stories__/Default';
|
|
5
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
6
6
|
|
|
7
7
|
test('renders the All QrCodeViewer variants', async ({ mount, page }) => {
|
|
8
8
|
await mount(
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
</
|
|
17
|
-
|
|
18
|
-
)
|
|
9
|
+
<div>
|
|
10
|
+
<TestVariant title="Custom">
|
|
11
|
+
<Custom />
|
|
12
|
+
</TestVariant>
|
|
13
|
+
<TestVariant title="Default">
|
|
14
|
+
<Default />
|
|
15
|
+
</TestVariant>
|
|
16
|
+
</div>
|
|
17
|
+
);
|
|
19
18
|
await page.evaluate(() => document.fonts.ready);
|
|
20
19
|
|
|
21
|
-
const screenshot = await page.screenshot({
|
|
20
|
+
const screenshot = await page.screenshot({
|
|
21
|
+
fullPage: true,
|
|
22
|
+
animations: 'disabled',
|
|
23
|
+
});
|
|
22
24
|
expect(screenshot).toMatchSnapshot();
|
|
23
25
|
});
|
|
24
|
-
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Button } from '@digigov/ui/app/Skeleton/__stories__/Button';
|
|
5
4
|
import { Circular } from '@digigov/ui/app/Skeleton/__stories__/Circular';
|
|
6
5
|
import { Default } from '@digigov/ui/app/Skeleton/__stories__/Default';
|
|
@@ -10,43 +9,45 @@ import { SpecificWidthAndHeight } from '@digigov/ui/app/Skeleton/__stories__/Spe
|
|
|
10
9
|
import { TextSizes } from '@digigov/ui/app/Skeleton/__stories__/TextSizes';
|
|
11
10
|
import { UnderTypography } from '@digigov/ui/app/Skeleton/__stories__/UnderTypography';
|
|
12
11
|
import { WithChildren } from '@digigov/ui/app/Skeleton/__stories__/WithChildren';
|
|
12
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
13
13
|
|
|
14
14
|
test('renders the All Skeleton variants', async ({ mount, page }) => {
|
|
15
15
|
await mount(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
</
|
|
45
|
-
|
|
46
|
-
)
|
|
16
|
+
<div>
|
|
17
|
+
<TestVariant title="Button">
|
|
18
|
+
<Button />
|
|
19
|
+
</TestVariant>
|
|
20
|
+
<TestVariant title="Circular">
|
|
21
|
+
<Circular />
|
|
22
|
+
</TestVariant>
|
|
23
|
+
<TestVariant title="Default">
|
|
24
|
+
<Default />
|
|
25
|
+
</TestVariant>
|
|
26
|
+
<TestVariant title="NoAnimation">
|
|
27
|
+
<NoAnimation />
|
|
28
|
+
</TestVariant>
|
|
29
|
+
<TestVariant title="Rectangular">
|
|
30
|
+
<Rectangular />
|
|
31
|
+
</TestVariant>
|
|
32
|
+
<TestVariant title="SpecificWidthAndHeight">
|
|
33
|
+
<SpecificWidthAndHeight />
|
|
34
|
+
</TestVariant>
|
|
35
|
+
<TestVariant title="TextSizes">
|
|
36
|
+
<TextSizes />
|
|
37
|
+
</TestVariant>
|
|
38
|
+
<TestVariant title="UnderTypography">
|
|
39
|
+
<UnderTypography />
|
|
40
|
+
</TestVariant>
|
|
41
|
+
<TestVariant title="WithChildren">
|
|
42
|
+
<WithChildren />
|
|
43
|
+
</TestVariant>
|
|
44
|
+
</div>
|
|
45
|
+
);
|
|
47
46
|
await page.evaluate(() => document.fonts.ready);
|
|
48
47
|
|
|
49
|
-
const screenshot = await page.screenshot({
|
|
48
|
+
const screenshot = await page.screenshot({
|
|
49
|
+
fullPage: true,
|
|
50
|
+
animations: 'disabled',
|
|
51
|
+
});
|
|
50
52
|
expect(screenshot).toMatchSnapshot();
|
|
51
53
|
});
|
|
52
|
-
|
|
@@ -1,32 +1,33 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Auto } from '@digigov/ui/content/Accordion/__stories__/Auto';
|
|
5
4
|
import { Default } from '@digigov/ui/content/Accordion/__stories__/Default';
|
|
6
5
|
import { WithHints } from '@digigov/ui/content/Accordion/__stories__/WithHints';
|
|
7
6
|
import { WithHook } from '@digigov/ui/content/Accordion/__stories__/WithHook';
|
|
7
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
8
8
|
|
|
9
9
|
test('renders the All Accordion variants', async ({ mount, page }) => {
|
|
10
10
|
await mount(
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
</
|
|
25
|
-
|
|
26
|
-
)
|
|
11
|
+
<div>
|
|
12
|
+
<TestVariant title="Auto">
|
|
13
|
+
<Auto />
|
|
14
|
+
</TestVariant>
|
|
15
|
+
<TestVariant title="Default">
|
|
16
|
+
<Default />
|
|
17
|
+
</TestVariant>
|
|
18
|
+
<TestVariant title="WithHints">
|
|
19
|
+
<WithHints />
|
|
20
|
+
</TestVariant>
|
|
21
|
+
<TestVariant title="WithHook">
|
|
22
|
+
<WithHook />
|
|
23
|
+
</TestVariant>
|
|
24
|
+
</div>
|
|
25
|
+
);
|
|
27
26
|
await page.evaluate(() => document.fonts.ready);
|
|
28
27
|
|
|
29
|
-
const screenshot = await page.screenshot({
|
|
28
|
+
const screenshot = await page.screenshot({
|
|
29
|
+
fullPage: true,
|
|
30
|
+
animations: 'disabled',
|
|
31
|
+
});
|
|
30
32
|
expect(screenshot).toMatchSnapshot();
|
|
31
33
|
});
|
|
32
|
-
|
|
@@ -1,24 +1,25 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/content/Blockquote/__stories__/Default';
|
|
5
4
|
import { Dense } from '@digigov/ui/content/Blockquote/__stories__/Dense';
|
|
5
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
6
6
|
|
|
7
7
|
test('renders the All Blockquote variants', async ({ mount, page }) => {
|
|
8
8
|
await mount(
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
</
|
|
17
|
-
|
|
18
|
-
)
|
|
9
|
+
<div>
|
|
10
|
+
<TestVariant title="Default">
|
|
11
|
+
<Default />
|
|
12
|
+
</TestVariant>
|
|
13
|
+
<TestVariant title="Dense">
|
|
14
|
+
<Dense />
|
|
15
|
+
</TestVariant>
|
|
16
|
+
</div>
|
|
17
|
+
);
|
|
19
18
|
await page.evaluate(() => document.fonts.ready);
|
|
20
19
|
|
|
21
|
-
const screenshot = await page.screenshot({
|
|
20
|
+
const screenshot = await page.screenshot({
|
|
21
|
+
fullPage: true,
|
|
22
|
+
animations: 'disabled',
|
|
23
|
+
});
|
|
22
24
|
expect(screenshot).toMatchSnapshot();
|
|
23
25
|
});
|
|
24
|
-
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/content/Card/__stories__/Default';
|
|
5
4
|
import { Dense } from '@digigov/ui/content/Card/__stories__/Dense';
|
|
6
5
|
import { WithClickableContent } from '@digigov/ui/content/Card/__stories__/WithClickableContent';
|
|
@@ -12,49 +11,51 @@ import { WithGrayBorder } from '@digigov/ui/content/Card/__stories__/WithGrayBor
|
|
|
12
11
|
import { WithGrayTopBorder } from '@digigov/ui/content/Card/__stories__/WithGrayTopBorder';
|
|
13
12
|
import { WithGroupButton } from '@digigov/ui/content/Card/__stories__/WithGroupButton';
|
|
14
13
|
import { WithLink } from '@digigov/ui/content/Card/__stories__/WithLink';
|
|
14
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
15
15
|
|
|
16
16
|
test('renders the All Card variants', async ({ mount, page }) => {
|
|
17
17
|
await mount(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
</
|
|
53
|
-
|
|
54
|
-
)
|
|
18
|
+
<div>
|
|
19
|
+
<TestVariant title="Default">
|
|
20
|
+
<Default />
|
|
21
|
+
</TestVariant>
|
|
22
|
+
<TestVariant title="Dense">
|
|
23
|
+
<Dense />
|
|
24
|
+
</TestVariant>
|
|
25
|
+
<TestVariant title="WithClickableContent">
|
|
26
|
+
<WithClickableContent />
|
|
27
|
+
</TestVariant>
|
|
28
|
+
<TestVariant title="WithClickableLink">
|
|
29
|
+
<WithClickableLink />
|
|
30
|
+
</TestVariant>
|
|
31
|
+
<TestVariant title="WithDarkBorder">
|
|
32
|
+
<WithDarkBorder />
|
|
33
|
+
</TestVariant>
|
|
34
|
+
<TestVariant title="WithDarkTopBorder">
|
|
35
|
+
<WithDarkTopBorder />
|
|
36
|
+
</TestVariant>
|
|
37
|
+
<TestVariant title="WithDivider">
|
|
38
|
+
<WithDivider />
|
|
39
|
+
</TestVariant>
|
|
40
|
+
<TestVariant title="WithGrayBorder">
|
|
41
|
+
<WithGrayBorder />
|
|
42
|
+
</TestVariant>
|
|
43
|
+
<TestVariant title="WithGrayTopBorder">
|
|
44
|
+
<WithGrayTopBorder />
|
|
45
|
+
</TestVariant>
|
|
46
|
+
<TestVariant title="WithGroupButton">
|
|
47
|
+
<WithGroupButton />
|
|
48
|
+
</TestVariant>
|
|
49
|
+
<TestVariant title="WithLink">
|
|
50
|
+
<WithLink />
|
|
51
|
+
</TestVariant>
|
|
52
|
+
</div>
|
|
53
|
+
);
|
|
55
54
|
await page.evaluate(() => document.fonts.ready);
|
|
56
55
|
|
|
57
|
-
const screenshot = await page.screenshot({
|
|
56
|
+
const screenshot = await page.screenshot({
|
|
57
|
+
fullPage: true,
|
|
58
|
+
animations: 'disabled',
|
|
59
|
+
});
|
|
58
60
|
expect(screenshot).toMatchSnapshot();
|
|
59
61
|
});
|
|
60
|
-
|
|
@@ -1,36 +1,37 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { ClickableChip } from '@digigov/ui/content/Chip/__stories__/ClickableChip';
|
|
5
4
|
import { ClickableDeletableChip } from '@digigov/ui/content/Chip/__stories__/ClickableDeletableChip';
|
|
6
5
|
import { Default } from '@digigov/ui/content/Chip/__stories__/Default';
|
|
7
6
|
import { DeletableChip } from '@digigov/ui/content/Chip/__stories__/DeletableChip';
|
|
8
7
|
import { GroupOfChips } from '@digigov/ui/content/Chip/__stories__/GroupOfChips';
|
|
8
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
9
9
|
|
|
10
10
|
test('renders the All Chip variants', async ({ mount, page }) => {
|
|
11
11
|
await mount(
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</
|
|
29
|
-
|
|
30
|
-
)
|
|
12
|
+
<div>
|
|
13
|
+
<TestVariant title="ClickableChip">
|
|
14
|
+
<ClickableChip />
|
|
15
|
+
</TestVariant>
|
|
16
|
+
<TestVariant title="ClickableDeletableChip">
|
|
17
|
+
<ClickableDeletableChip />
|
|
18
|
+
</TestVariant>
|
|
19
|
+
<TestVariant title="Default">
|
|
20
|
+
<Default />
|
|
21
|
+
</TestVariant>
|
|
22
|
+
<TestVariant title="DeletableChip">
|
|
23
|
+
<DeletableChip />
|
|
24
|
+
</TestVariant>
|
|
25
|
+
<TestVariant title="GroupOfChips">
|
|
26
|
+
<GroupOfChips />
|
|
27
|
+
</TestVariant>
|
|
28
|
+
</div>
|
|
29
|
+
);
|
|
31
30
|
await page.evaluate(() => document.fonts.ready);
|
|
32
31
|
|
|
33
|
-
const screenshot = await page.screenshot({
|
|
32
|
+
const screenshot = await page.screenshot({
|
|
33
|
+
fullPage: true,
|
|
34
|
+
animations: 'disabled',
|
|
35
|
+
});
|
|
34
36
|
expect(screenshot).toMatchSnapshot();
|
|
35
37
|
});
|
|
36
|
-
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { test, expect } from '@playwright/experimental-ct-react';
|
|
3
|
-
import TestVariant from '@digigov/ui/utils/TestVariant'
|
|
4
3
|
import { Default } from '@digigov/ui/content/Details/__stories__/Default';
|
|
4
|
+
import TestVariant from '@digigov/ui/utils/TestVariant';
|
|
5
5
|
|
|
6
6
|
test('renders the All Details variants', async ({ mount, page }) => {
|
|
7
7
|
await mount(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</
|
|
13
|
-
|
|
14
|
-
)
|
|
8
|
+
<div>
|
|
9
|
+
<TestVariant title="Default">
|
|
10
|
+
<Default />
|
|
11
|
+
</TestVariant>
|
|
12
|
+
</div>
|
|
13
|
+
);
|
|
15
14
|
await page.evaluate(() => document.fonts.ready);
|
|
16
15
|
|
|
17
|
-
const screenshot = await page.screenshot({
|
|
16
|
+
const screenshot = await page.screenshot({
|
|
17
|
+
fullPage: true,
|
|
18
|
+
animations: 'disabled',
|
|
19
|
+
});
|
|
18
20
|
expect(screenshot).toMatchSnapshot();
|
|
19
21
|
});
|
|
20
|
-
|