Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Autocomplete height adjust in materil ui

const useStyles = makeStyles(theme => ({
  inputRoot: {
    color: theme.palette.primary.contrastText,
  },
  popupIndicator: {
    color: theme.palette.primary.contrastText,
  },
  root: {
    padding: `0 ${theme.spacing(1)}px`,
  },
}))

const AutocompleteWrapper = ({
  value,
  onChange,
  options,
}) => {
  const classes = useStyles()

  return (
  <Autocomplete
    classes={classes}
    options={options}
    value={value}
    onChange={onChange}
    renderInput={(params) => <TextField {...params} variant="standard" size="small" />}
  />
  )
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Autocomplete #height #adjust #materil #ui
ADD COMMENT
Topic
Name
9+6 =