mirror of
https://github.com/yude-jp/yude.jp
synced 2024-11-17 02:52:38 +09:00
27 lines
855 B
JavaScript
27 lines
855 B
JavaScript
import Layout from "./components/Layout"
|
|
import useTranslation from 'next-translate/useTranslation'
|
|
import { useRouter } from 'next/router'
|
|
import React from "react"
|
|
import ReactMarkdown from "react-markdown"
|
|
import gfm from 'remark-gfm';
|
|
import ja from '../docs/hcunews/ja.md'
|
|
import en from '../docs/hcunews/en.md'
|
|
|
|
export default function Tos(props) {
|
|
const router = useRouter()
|
|
const { locale, locales, defaultLocale, pathname } = router
|
|
const { t, lang } = useTranslation("hcunews")
|
|
const hcunews = t('hcunews')
|
|
return(
|
|
<Layout title={hcunews}>
|
|
<div>
|
|
<h1>{hcunews}</h1>
|
|
{lang === 'ja' ? (
|
|
<ReactMarkdown plugins={[gfm]} children={ja} />
|
|
) : (
|
|
<ReactMarkdown plugins={[gfm]} children={en} />
|
|
)}
|
|
</div>
|
|
</Layout>
|
|
)
|
|
} |