Skip to content

Commit 891c885

Browse files
committed
fix(RadioGroup): add forwardRef RadioGroup component
Signed-off-by: seniorliketocode <abhishek234543@gmail.com>
1 parent c5add03 commit 891c885

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

src/base/RadioGroup/RadioGroup.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@ import {
22
RadioGroup as MuiRadioGroup,
33
type RadioGroupProps as MuiRadioGroupProps
44
} from '@mui/material';
5+
import React from 'react';
56

6-
export function RadioGroup(props: MuiRadioGroupProps): JSX.Element {
7-
return <MuiRadioGroup {...props} />;
8-
}
7+
const RadioGroup = React.forwardRef<HTMLDivElement, MuiRadioGroupProps>((props, ref) => {
8+
return <MuiRadioGroup {...props} ref={ref} />;
9+
});
910

1011
export default RadioGroup;

0 commit comments

Comments
 (0)