Skip to content

Commit

Permalink
fix(nhsuk-frontend-react): pass table cell role to variations
Browse files Browse the repository at this point in the history
  • Loading branch information
rowellx68 committed Jan 20, 2025
1 parent 71409be commit dea2d48
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/flat-cobras-sparkle.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"nhsuk-frontend-react": patch
---

fix(nhsuk-frontend-react): pass table cell role to variations
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export const ThreeColumnWithFirstCellAsHeader: Story = {
</Table.Row>
</Table.Head>
<Table.Body>
<Table.Row>
<Table.Row role="none">
<Table.Cell>3-month</Table.Cell>
<Table.Cell variant="numeric">£31.25</Table.Cell>
<Table.Cell variant="numeric">£32.05</Table.Cell>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,7 @@ const TableCell = ({
}
: {
as: 'td',
role,
...(cellClassNames && { className: cellClassNames }),
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ exports[`should render a three column table with the first cell as a header 1`]
>
<tr
class="nhsuk-table__row"
role="row"
role="none"
>
<th
class="nhsuk-table__header"
Expand Down

0 comments on commit dea2d48

Please sign in to comment.