15 lines
384 B
Plaintext
15 lines
384 B
Plaintext
|
|
<FormControlLabel
|
||
|
|
control={<Switch checked={checked} onChange={handleChange} />}
|
||
|
|
label="Show"
|
||
|
|
/>
|
||
|
|
<Box sx={{ display: 'flex' }}>
|
||
|
|
<Grow in={checked}>{icon}</Grow>
|
||
|
|
{/* Conditionally applies the timeout prop to change the entry speed. */}
|
||
|
|
<Grow
|
||
|
|
in={checked}
|
||
|
|
style={{ transformOrigin: '0 0 0' }}
|
||
|
|
{...(checked ? { timeout: 1000 } : {})}
|
||
|
|
>
|
||
|
|
{icon}
|
||
|
|
</Grow>
|
||
|
|
</Box>
|