Skip to content

Commit e9b544e

Browse files
authored
chore: [IOBP-1186] Add accessibilityLabel prop to RadioItem type component (#421)
## Short description This PR adds the `accessibilityLabel` prop to the `RadioItem` type to handle a11y in the `RadioGroup` component ## List of changes proposed in this pull request - Added `accessibilityLabel` prop to the `RadioItem` type
1 parent e354c56 commit e9b544e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/components/radio/RadioGroup.tsx

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { ListItemRadio, ListItemRadioWithAmount } from "../listitems";
55
export type RadioItem<T> = {
66
id: T;
77
value: string;
8+
accessibilityLabel?: string;
89
description?: string | React.ReactNode;
910
disabled?: boolean;
1011
startImage?: ComponentProps<typeof ListItemRadio>["startImage"];
@@ -55,6 +56,7 @@ const RadioListItem = <T,>(props: RadioListItemProps<T>) => (
5556
testID={`RadioItemTestID_${item.id}`}
5657
value={item.value}
5758
description={item.description}
59+
accessibilityLabel={item.accessibilityLabel}
5860
startImage={item.startImage}
5961
disabled={item.disabled}
6062
loadingProps={item.loadingProps}

0 commit comments

Comments
 (0)