Skip to content

Commit 2117900

Browse files
committed
feat: add support for border radius config in select picker
1 parent 04ae570 commit 2117900

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Shared/Components/SelectPicker/SelectPicker.component.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ import { SelectPickerOptionType, SelectPickerProps, SelectPickerVariantType } fr
4545
import { GenericSectionErrorState } from '../GenericSectionErrorState'
4646
import FormFieldWrapper from '../FormFieldWrapper/FormFieldWrapper'
4747
import { getFormFieldAriaAttributes } from '../FormFieldWrapper'
48+
import { getFormFieldBorderClassName } from '../FormFieldWrapper/utils'
4849

4950
/**
5051
* Generic component for select picker
@@ -382,7 +383,6 @@ const SelectPicker = <OptionValue, IsMulti extends boolean>({
382383
required={required}
383384
fullWidth={fullWidth}
384385
ariaLabel={ariaLabel}
385-
// TODO: Add support for custom border radius with Select refactoring
386386
borderRadiusConfig={borderRadiusConfig}
387387
labelTippyCustomizedConfig={labelTippyCustomizedConfig}
388388
labelTooltipConfig={labelTooltipConfig}
@@ -399,6 +399,9 @@ const SelectPicker = <OptionValue, IsMulti extends boolean>({
399399
error,
400400
helperText,
401401
})}
402+
classNames={{
403+
control: () => getFormFieldBorderClassName(borderRadiusConfig),
404+
}}
402405
name={name || inputId}
403406
classNamePrefix={classNamePrefix || inputId}
404407
isSearchable={isSelectSearchable}

0 commit comments

Comments
 (0)