Skip to content

Commit 9b05608

Browse files
committed
Make the isRequired prop forward to the internal required prop
1 parent cf052e8 commit 9b05608

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/use-chakra-select-props.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ const useChakraSelectProps = <
1717
isDisabled,
1818
isInvalid,
1919
isReadOnly,
20+
required,
2021
isRequired,
2122
inputId,
2223
tagVariant,
@@ -90,6 +91,7 @@ const useChakraSelectProps = <
9091
isInvalid: !!inputProps["aria-invalid"],
9192
inputId: inputProps.id,
9293
isReadOnly: inputProps.readOnly,
94+
required: required ?? inputProps.required,
9395
menuIsOpen: realMenuIsOpen,
9496
...props,
9597
// aria-invalid can be passed to react-select, so we allow that to

0 commit comments

Comments
 (0)