fix: autocomplete component rendering
This commit is contained in:
parent
0a42592cb0
commit
6bed841e79
2 changed files with 14 additions and 16 deletions
|
|
@ -81,8 +81,7 @@ const Autocomplete = ({
|
|||
clearOnEscape
|
||||
isOptionEqualToValue={R.eqProps(valueProp)}
|
||||
{...props}
|
||||
renderInput={params => {
|
||||
return (
|
||||
renderInput={params => (
|
||||
<TextInput
|
||||
{...params}
|
||||
autoFocus={autoFocus}
|
||||
|
|
@ -93,8 +92,7 @@ const Autocomplete = ({
|
|||
fullWidth={fullWidth}
|
||||
textAlign={textAlign}
|
||||
/>
|
||||
)
|
||||
}}
|
||||
)}
|
||||
renderOption={(iprops, props) => {
|
||||
if (!props.warning && !props.warningMessage)
|
||||
return <li {...iprops}>{R.path([labelProp])(props)}</li>
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ const TextInput = memo(
|
|||
size,
|
||||
bold,
|
||||
className,
|
||||
inputProps,
|
||||
InputProps,
|
||||
...props
|
||||
}) => {
|
||||
|
|
@ -63,8 +64,7 @@ const TextInput = memo(
|
|||
},
|
||||
...InputProps,
|
||||
},
|
||||
|
||||
htmlInput: { style: { textAlign } },
|
||||
htmlInput: { style: { textAlign }, ...inputProps },
|
||||
}}
|
||||
/>
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue