Skip to content

Commit

Permalink
fix(a11y): Match ids and for values on DateInput (#2859)
Browse files Browse the repository at this point in the history
  • Loading branch information
DafyddLlyr authored Mar 6, 2024
1 parent ddbc185 commit 92f2046
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions editor.planx.uk/src/ui/shared/DateInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export default function DateInput(props: Props): FCReturn {
</Typography>
)}
<Box sx={{ width: INPUT_DATE_WIDTH }}>
<Label variant="body1" htmlFor="day" component={"label"}>
<Label variant="body1" htmlFor={`${props.id}-day`} component={"label"}>
Day
</Label>
<Input
Expand All @@ -71,7 +71,7 @@ export default function DateInput(props: Props): FCReturn {
/>
</Box>
<Box sx={{ width: INPUT_DATE_WIDTH }}>
<Label variant="body1" htmlFor="month" component={"label"}>
<Label variant="body1" htmlFor={`${props.id}-month`} component={"label"}>
Month
</Label>
<Input
Expand All @@ -95,7 +95,7 @@ export default function DateInput(props: Props): FCReturn {
/>
</Box>
<Box sx={{ width: INPUT_YEAR_WIDTH }}>
<Label variant="body1" htmlFor="year" component={"label"}>
<Label variant="body1" htmlFor={`${props.id}-year`} component={"label"}>
Year
</Label>
<Input
Expand Down

0 comments on commit 92f2046

Please sign in to comment.