0
0
mirror of https://github.com/yude-jp/yude.jp synced 2024-12-23 12:40:11 +09:00
yude.jp/pages/index.js

45 lines
2.4 KiB
JavaScript
Raw Normal View History

2021-02-06 02:38:26 +09:00
import Layout from "./components/Layout"
import Navbar from "./components/Navbar"
2021-02-06 02:31:04 +09:00
import Link from 'next/link'
2021-02-08 16:05:58 +09:00
import { ReactElement } from 'react'
2021-02-08 16:21:02 +09:00
import { faDiscord, faGit } from '@fortawesome/free-brands-svg-icons'
import { faBlog, faBook, faUser, faServer } from '@fortawesome/free-solid-svg-icons'
2021-02-08 16:05:58 +09:00
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
2021-02-06 02:31:04 +09:00
import Image from 'next/image'
2021-02-06 14:30:05 +09:00
import useTranslation from 'next-translate/useTranslation'
2021-02-06 14:05:36 +09:00
import { useRouter } from 'next/router'
2021-02-08 16:21:02 +09:00
2021-02-06 14:05:36 +09:00
export default function Index(props) {
2021-02-08 16:21:02 +09:00
// Translation
2021-02-06 14:05:36 +09:00
const router = useRouter()
const { locale, locales, defaultLocale, pathname } = router
2021-02-06 14:30:05 +09:00
const { t, lang } = useTranslation("index")
2021-02-08 17:01:35 +09:00
const home = t('home')
2021-02-07 17:40:43 +09:00
2021-02-06 14:05:36 +09:00
return (
2021-02-06 02:31:04 +09:00
2021-02-08 17:16:02 +09:00
<Layout title={home}>
<Navbar />
2021-02-06 09:36:00 +09:00
<div className="my-9">
2021-02-08 17:13:58 +09:00
<div className="m-10">
2021-02-08 16:05:58 +09:00
<Image
2021-02-06 02:46:15 +09:00
src = "/static/images/avatar.png"
alt = "yude's avatar"
width = {200}
height = {200}
unoptimized = {true}
2021-02-06 02:31:04 +09:00
/>
2021-02-07 17:40:43 +09:00
</div>
2021-02-09 17:46:31 +09:00
<span><Link href="/profile"><a><FontAwesomeIcon icon={faUser} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
<span className="ml-4"><Link href="https://blog.yude.jp"><a><FontAwesomeIcon icon={faBlog} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
<span className="ml-4"><Link href="https://wiki.yude.jp"><a><FontAwesomeIcon icon={faBook} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
<span className="ml-4"><Link href="https://discord.gg/X6srY7X"><a><FontAwesomeIcon icon={faDiscord} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
<span className="ml-4"><Link href="https://git.yude.jp"><a><FontAwesomeIcon icon={faGit} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
<span className="ml-4"><Link href="/status"><a><FontAwesomeIcon icon={faServer} className="w-10 h-10 inline transition duration-200 ease-in-out transform hover:-translate-y-1 hover:scale-110" /></a></Link></span>
2021-02-08 16:05:58 +09:00
<p></p>
2021-02-06 02:31:04 +09:00
</div>
2021-02-06 09:36:00 +09:00
2021-02-06 02:31:04 +09:00
</Layout>
)
2021-02-06 14:05:36 +09:00
}