File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -61,12 +61,12 @@ const SelectComponent = <T extends GenericOption<DefaultOptionValue>[]>(
6161 } = props ;
6262
6363 assert < Equals < keyof typeof rest , never > > ( ) ;
64-
64+ const selectIdExplicitelyProvided = nativeSelectProps ?. id ;
6565 const { selectId, stateDescriptionId } = ( function useClosure ( ) {
6666 const elementId = useId ( ) ;
67- const selectId = nativeSelectProps ?. id ?? `select-${ elementId } ` ;
68- const stateDescriptionId = nativeSelectProps ?. id
69- ? `${ nativeSelectProps ?. id } -desc`
67+ const selectId = selectIdExplicitelyProvided ?? `select-${ elementId } ` ;
68+ const stateDescriptionId = selectIdExplicitelyProvided
69+ ? `${ selectIdExplicitelyProvided } -desc`
7070 : `select-${ elementId } -desc` ;
7171
7272 return { selectId, stateDescriptionId } ;
You can’t perform that action at this time.
0 commit comments