mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-09 23:15:58 -06:00
Fix select dropdown border issue. #5661
This commit is contained in:
parent
1c705cf9be
commit
42220b1cb2
@ -774,6 +774,16 @@ OptionView.propTypes = {
|
||||
label: PropTypes.string,
|
||||
};
|
||||
|
||||
function CustomSelectInput(props) {
|
||||
const { maxLength } = props.selectProps;
|
||||
return (
|
||||
<RSComponents.Input {...props} maxLength={maxLength} />
|
||||
);
|
||||
}
|
||||
CustomSelectInput.propTypes = {
|
||||
selectProps: PropTypes.object,
|
||||
};
|
||||
|
||||
function CustomSelectOption(props) {
|
||||
return (
|
||||
<RSComponents.Option {...props}>
|
||||
@ -918,9 +928,9 @@ export const InputSelect = forwardRef(({
|
||||
components: {
|
||||
Option: CustomSelectOption,
|
||||
SingleValue: CustomSelectSingleValue,
|
||||
IndicatorSeparator: (props) => controlProps.noDropdown ? null: <RSComponents.IndicatorSeparator {...props} />,
|
||||
DropdownIndicator: (props) => controlProps.noDropdown ? null: <RSComponents.DropdownIndicator {...props} />,
|
||||
Input: props => <RSComponents.Input {...props} maxLength={controlProps.maxLength} />
|
||||
IndicatorSeparator: controlProps.noDropdown ? null: RSComponents.IndicatorSeparator,
|
||||
DropdownIndicator: controlProps.noDropdown ? null: RSComponents.DropdownIndicator,
|
||||
Input: CustomSelectInput,
|
||||
},
|
||||
isMulti: Boolean(controlProps.multiple),
|
||||
openMenuOnClick: !readonly,
|
||||
@ -932,6 +942,7 @@ export const InputSelect = forwardRef(({
|
||||
styles: styles,
|
||||
inputId: cid,
|
||||
placeholder: (readonly || disabled) ? '' : controlProps.placeholder || gettext('Select an item...'),
|
||||
maxLength: controlProps.maxLength,
|
||||
...otherProps,
|
||||
...props,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user