Create JwennSesyon component

This commit is contained in:
Cédric FAMIBELLE-PRONZOLA
2021-07-22 00:59:53 +02:00
parent 3c98a14b2f
commit e1a3a91295
+37
View File
@@ -0,0 +1,37 @@
import {useState} from 'react'
import {Box, Button, Typography} from '@material-ui/core'
import Image from 'next/image'
import SesyonDialog from './sesyon-dialog'
export default function JwennSesyon() {
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}>
<Image
src='/session-logo-50.png'
width={50}
height={55}
/>
<Typography style={{fontWeight: 'bold'}} variant='h6' component='h1'>
Session
</Typography>
</Box>
</Button>
{ouve && (
<SesyonDialog ouve={ouve} handleFemen={handleFemen} />
)}
</>
)
}