Skip to content

Commit 39a3bc2

Browse files
Add aria-hidden to InputLabel required asterisk (#1770)
* add aria-hidden * fix broken link * add changeset Co-authored-by: Siddharth Kshetrapal <[email protected]>
1 parent b604403 commit 39a3bc2

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

.changeset/breezy-coats-play.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@primer/react': patch
3+
---
4+
5+
Adds aria-hidden="true" to InputLabel required asterisk

docs/content/InputField.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ componentId: inputField
33
title: InputField
44
status: Alpha
55
description: The InputField component is used to render a labelled text input and, optionally, associated validation text and hint text.
6-
source: https://github.com/primer/react/blob/main/src/InputField.tsx
6+
source: https://github.com/primer/react/blob/main/src/InputField/InputField.tsx
77
storybook: '/react/storybook?path=/story/forms-inputfield--text-input-field'
88
---
99

src/_InputLabel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const InputLabel: React.FC<Props> = ({children, disabled, required, visuallyHidd
2525
{required ? (
2626
<Box display="flex" as="span">
2727
<Box mr={1}>{children}</Box>
28-
<span>*</span>
28+
<span aria-hidden="true">*</span>
2929
</Box>
3030
) : (
3131
children

0 commit comments

Comments
 (0)