Skip to content

Commit 7a41f76

Browse files
committed
updating snapshots
1 parent 8fbf348 commit 7a41f76

File tree

18 files changed

+130
-41
lines changed

18 files changed

+130
-41
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@
7373
"eslint-plugin-storybook": "9.1.3",
7474
"globals": "^16.4.0",
7575
"jest": "^30.1.3",
76+
"jest-axe": "^10.0.0",
7677
"jest-environment-jsdom": "^30.1.2",
7778
"less": "^4.4.1",
7879
"nhsuk-frontend": "^9.0.1",

src/components/content-presentation/table/components/TableRow.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const TableRow: FC<HTMLProps<HTMLTableRowElement>> = ({ className, children, ...
2121
return cloneElement(child, {
2222
_responsive: isResponsive,
2323
_responsiveHeading: `${headings[index] || ''} `,
24-
});
24+
} as any);
2525
}
2626
return child;
2727
});

src/components/form-elements/character-count/__tests__/__snapshots__/CharacterCount.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`Character Count Matches snapshot 1`] = `
44
<div>

src/components/form-elements/checkboxes/__tests__/__snapshots__/Checkboxes.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`Checkboxes Matches the snapshot with an exclusive checkbox 1`] = `
44
<div>

src/components/form-elements/date-input/__tests__/__snapshots__/DateInput.test.tsx.snap

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`DateInput matches snapshot 1`] = `
44
<div>
@@ -29,7 +29,6 @@ exports[`DateInput matches snapshot 1`] = `
2929
name="testInput-day"
3030
pattern="[0-9]*"
3131
type="text"
32-
value=""
3332
/>
3433
</div>
3534
</div>
@@ -53,7 +52,6 @@ exports[`DateInput matches snapshot 1`] = `
5352
name="testInput-month"
5453
pattern="[0-9]*"
5554
type="text"
56-
value=""
5755
/>
5856
</div>
5957
</div>
@@ -77,7 +75,6 @@ exports[`DateInput matches snapshot 1`] = `
7775
name="testInput-year"
7876
pattern="[0-9]*"
7977
type="text"
80-
value=""
8178
/>
8279
</div>
8380
</div>

src/components/form-elements/fieldset/__tests__/__snapshots__/Fieldset.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`Fieldset Fieldset.Legend matches snapshot: FieldsetLegend 1`] = `
44
<div>

src/components/form-elements/radios/__tests__/__snapshots__/Radios.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`Radios matches snapshot 1`] = `
44
<div>

src/components/form-elements/select/__tests__/__snapshots__/Select.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Jest Snapshot v1, https://goo.gl/fbAQLP
1+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
22

33
exports[`Select Matches the snapshot 1`] = `
44
<div>
Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,26 @@
11
import * as React from 'react';
22
import { FC } from 'react';
33
import classNames from 'classnames';
4+
import type { AsElementLink } from '@util/types/LinkTypes';
5+
import { ChevronLeft } from '@components/content-presentation/icons/individual/ChevronLeft';
46

5-
export interface BreadcrumbProps {
7+
export interface BackLinkProps extends AsElementLink<'a'> {
68
children: React.ReactNode;
79
className?: string;
810
}
911

10-
const Breadcrumb: FC<BreadcrumbProps> = ({ children, className }) => (
11-
<nav className={classNames('nhsuk-breadcrumb', className)} aria-label="Breadcrumb">
12-
<ol className="nhsuk-breadcrumb__list">
12+
const BackLink: FC<BackLinkProps> = ({
13+
children,
14+
className,
15+
asElement: Component = 'a',
16+
...rest
17+
}) => (
18+
<div className={classNames('nhsuk-back-link', className)}>
19+
<Component className="nhsuk-back-link__link" {...rest}>
20+
<ChevronLeft />
1321
{children}
14-
</ol>
15-
</nav>
22+
</Component>
23+
</div>
1624
);
1725

18-
export default Breadcrumb;
26+
export default BackLink;

src/components/navigation/back-link/__tests__/__snapshots__/BackLink.test.tsx.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ exports[`BackLink matches snapshot: BackLink 1`] = `
1212
<svg
1313
aria-hidden="true"
1414
class="nhsuk-icon nhsuk-icon__chevron-left"
15-
height="24"
15+
height="34"
1616
viewBox="0 0 24 24"
17-
width="24"
17+
width="34"
1818
xmlns="http://www.w3.org/2000/svg"
1919
>
2020
<path

0 commit comments

Comments
 (0)