Add Sign to index page
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
import {getServerSession} from 'next-auth'
|
||||
import {createDirectus, rest, readItems} from '@directus/sdk'
|
||||
import Container from '@mui/material/Container'
|
||||
import Box from '@mui/material/Box'
|
||||
import Typography from '@mui/material/Typography'
|
||||
import Konstitisyon from '@/components/konstitisyon/index.js'
|
||||
import Footer from '@/components/footer.js'
|
||||
import Sign from '@/components/session/sign.js'
|
||||
|
||||
const apiUrl = process.env.DIRECTUS_API_URL
|
||||
const appTitle = process.env.APP_TITLE
|
||||
@@ -42,6 +44,7 @@ async function getData() {
|
||||
}
|
||||
|
||||
export default async function Page() {
|
||||
const session = await getServerSession()
|
||||
const {titres, articles} = await getData()
|
||||
|
||||
return (
|
||||
@@ -53,6 +56,7 @@ export default async function Page() {
|
||||
>
|
||||
<Container maxWidth='sm'>
|
||||
<Typography mt={1} component='h1' textAlign='center' variant='h4'>{appTitle.toUpperCase()}</Typography>
|
||||
<Sign session={session} />
|
||||
<Konstitisyon titres={titres} articles={articles} />
|
||||
</Container>
|
||||
<Footer />
|
||||
|
||||
Reference in New Issue
Block a user