2020-12-13 23:20:07 +01:00
|
|
|
import PropTypes from 'prop-types'
|
|
|
|
|
|
|
|
|
|
import {jwennTeks} from '../../lib/oki-api'
|
|
|
|
|
|
|
|
|
|
import TeksDrawer from '../../components/teks/teks-drawer'
|
2020-12-15 23:46:05 +01:00
|
|
|
import HeadLayout from '../../components/head-layout'
|
2020-12-13 23:20:07 +01:00
|
|
|
|
2020-12-18 22:08:34 +01:00
|
|
|
export default function Teks({teks}) {
|
2020-12-13 23:20:07 +01:00
|
|
|
return (
|
2022-02-07 16:20:23 +04:00
|
|
|
<HeadLayout title='Tèks - Paroles et Traductions' tab={1} slug='teks'>
|
2020-12-18 22:08:34 +01:00
|
|
|
<TeksDrawer teks={teks} />
|
2020-12-15 23:46:05 +01:00
|
|
|
</HeadLayout>
|
2020-12-13 23:20:07 +01:00
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function getServerSideProps() {
|
2020-12-18 22:08:34 +01:00
|
|
|
const teks = await jwennTeks()
|
2020-12-13 23:20:07 +01:00
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
props: {
|
2020-12-18 22:08:34 +01:00
|
|
|
teks
|
2020-12-13 23:20:07 +01:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Teks.propTypes = {
|
2020-12-18 22:08:34 +01:00
|
|
|
teks: PropTypes.array.isRequired
|
2020-12-13 23:20:07 +01:00
|
|
|
}
|