I'm currently delving into learning Material UI and am faced with the task of enlarging the text field on my webpage. Despite embedding styles along with the field, the height, width, and other properties change except for the size. Here's the snippet of my code:
const styles = {
container: {
display: 'flex',
flexWrap: 'wrap',
},
textField: {
// marginLeft: theme.spacing.unit,
// marginRight: theme.spacing.unit,
width: 300,
margin: 100,
fontSize: 50 //??? Doesnt work
}
}
Below is the stateless React component:
const Searchbox = (props) => {
const { classes } = props;
return (
<TextField
onKeyDown={props.onKeyDown}
id="with-placeholder"
label="Add ID"
placeholder="ID"
className={classes.textField}
margin="normal"
autoFocus={true}
helperText={"Add an existing ID or select "}
/>
);
};
export default withStyles(styles)(Searchbox);
I understand that applying styles in this CSS-in-JS approach should be straightforward.
However, I'm facing difficulty overriding the base font size for my text field. Any assistance would be greatly appreciated.