Create JwennSignal component

This commit is contained in:
Cédric FAMIBELLE-PRONZOLA
2021-07-30 22:15:09 +02:00
parent 3d0d6b200a
commit d70d75c41d
+33
View File
@@ -0,0 +1,33 @@
import {useState} from 'react'
import {Box, Button, Typography} from '@material-ui/core'
import {Signal} from '@icons-pack/react-simple-icons'
import SignalDialog from './signal-dialog'
export default function JwennSignal() {
const [ouve, meteOuve] = useState(false)
const handleClickOuve = () => {
meteOuve(true)
}
const handleFemen = () => {
meteOuve(false)
}
return (
<>
<Button style={{marginTop: 10}} variant='outlined' color='primary' onClick={handleClickOuve}>
<Box paddingTop={1}>
<Signal size={55} />
<Typography style={{fontWeight: 'bold'}} variant='h6' component='h1'>
Signal
</Typography>
</Box>
</Button>
{ouve && (
<SignalDialog ouve={ouve} handleFemen={handleFemen} />
)}
</>
)
}