import * as React from 'react'; import Box from '@mui/material/Box'; import TextField from '@mui/material/TextField'; export default function StateTextFields() { const [name, setName] = React.useState('Cat in the Hat'); return ( :not(style)': { m: 1, width: '25ch' } }} noValidate autoComplete="off" > { setName(event.target.value); }} /> ); }