File tree Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Original file line number Diff line number Diff line change 11import type { Metadata } from "next" ;
2+ import { SITE_NAME , SITE_URL , SITE_DESC } from "../../lib/constants" ;
23import { Inter , Noto_Sans_JP } from "next/font/google" ;
34import "./globals.css" ;
45import Footer from "@/components/footer" ;
5- import { SITE_NAME , SITE_URL , SITE_DESC } from "../../lib/constants " ;
6+ import Header from "@/components/header " ;
67
78const inter = Inter ( {
89 subsets : [ "latin" ] ,
@@ -42,8 +43,8 @@ export default function RootLayout({
4243} > ) {
4344 return (
4445 < html lang = "ja" >
45- < body className = { `${ inter . variable } ${ notojp . variable } ` } >
46- < header > ヘッダー </ header >
46+ < body className = { `${ inter . variable } ${ notojp . variable } ` } >
47+ < Header / >
4748 { children }
4849 < Footer />
4950 </ body >
Original file line number Diff line number Diff line change 1+ import Link from "next/link" ;
2+ import { SITE_NAME } from "../../lib/constants" ;
3+ import GitHubIcon from '@mui/icons-material/GitHub' ;
4+
5+ export default function Header ( ) {
6+ return (
7+ < header className = "py-6 backdrop-blur-sm fixed w-full" >
8+ < Link href = "/" >
9+ < h1 className = "inline text-red-600 text-xl font-bold ml-7 hover:opacity-70 transition" >
10+ < GitHubIcon fontSize = "large" className = "text-red-600 mr-4 -translate-y-0.5" />
11+ { SITE_NAME }
12+ </ h1 >
13+ </ Link >
14+ </ header >
15+ ) ;
16+ }
You can’t perform that action at this time.
0 commit comments