Files
pawol.nu/pages/index.js
T

55 lines
1.6 KiB
JavaScript
Raw Normal View History

import PropTypes from 'prop-types'
import {Container, Typography, Box} from '@mui/material'
2020-12-17 09:08:18 +01:00
2020-12-15 23:46:05 +01:00
import HeadLayout from '../components/head-layout'
2021-06-14 23:30:00 +02:00
import Footer from '../components/footer'
import RezoDialog from '../components/rezo/rezo-dialog'
import DenyeTeks from '../components/teks/denye-teks'
import {jwennDenyeTeks} from '../lib/oki-api'
2020-12-17 22:36:27 +01:00
export default function Home({teks}) {
2020-12-04 20:16:24 +01:00
return (
2020-12-15 23:46:05 +01:00
<HeadLayout tab={0}>
2022-01-20 18:01:52 +04:00
<Box sx={{display: 'flex', flexDirection: 'column', minHeight: '100vh'}}>
<Box sx={{flexGrow: 1, marginBottom: 3}}>
2022-02-01 20:59:38 +04:00
<Container sx={{marginBottom: 3}} align='center'>
<Typography sx={{fontWeight: 'bold'}} variant='h6' component='h1'>
2022-01-22 12:31:55 +04:00
#OKi
</Typography>
2022-02-01 20:59:38 +04:00
<Typography sx={{fontWeight: 'bold'}} variant='h6' component='h2'>
2022-01-20 18:01:52 +04:00
Organisation KA Internationale
</Typography>
2022-02-01 23:44:18 +04:00
<Typography sx={{fontStyle: 'italic'}} variant='caption' component='h3'>
2022-02-07 23:20:35 +04:00
Paroles, traductions et actualités
2022-02-01 20:59:38 +04:00
</Typography>
</Container>
<Container align='center'>
<RezoDialog />
2022-01-20 18:01:52 +04:00
</Container>
</Box>
<Container align='center'>
<Typography sx={{fontWeight: 'bold'}} variant='h6' component='h2'>
Derniers textes publiés
</Typography>
</Container>
<DenyeTeks {...teks} />
2021-06-14 23:30:00 +02:00
<Footer />
2022-01-20 18:01:52 +04:00
</Box>
2020-12-15 23:46:05 +01:00
</HeadLayout>
2020-12-04 20:16:24 +01:00
)
}
export async function getServerSideProps() {
const denyeTeks = await jwennDenyeTeks()
return {
props: {
teks: denyeTeks
}
}
}
Home.propTypes = {
teks: PropTypes.array.isRequired
}