Skip to content

Instantly share code, notes, and snippets.

@sematgt
Created March 30, 2020 10:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sematgt/f61208ae98ff75f6f9013ce17a9316f3 to your computer and use it in GitHub Desktop.
Save sematgt/f61208ae98ff75f6f9013ce17a9316f3 to your computer and use it in GitHub Desktop.
Test syntax highlighting
import React from 'react';
import TextField from '@material-ui/core/TextField';
import Autocomplete from '@material-ui/lab/Autocomplete';
export default function ComboBox(props) {
return (
<Autocomplete
autoHighlight={props.autoHighlight}
onChange={props.handleChange}
clearText={props.clearText}
noOptionsText={props.noOptionsText}
id={props.label}
options={props.options}
getOptionLabel={option => option.name}
disableClearable={true}
style={{ width: 300 }}
renderInput={params => <TextField {...params} label={props.label} variant="outlined" />}
/>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment