-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
✨ Tags ページを追加
- Loading branch information
Showing
3 changed files
with
47 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import { Metadata, NextPage } from 'next'; | ||
import { ContentsLayout } from '@/components/Layout'; | ||
import { PagePath } from '@/lib/router'; | ||
import clsx from 'clsx'; | ||
import Link from 'next/link'; | ||
|
||
export const metadata: Metadata = { | ||
title: 'Tags | tatsutakein.jp', | ||
description: 'Ryo Takeuchi のポートフォリオサイトです。', | ||
}; | ||
|
||
interface PageProps { | ||
params: { slug: string[] }; | ||
searchParams: { [key: string]: string | string[] | undefined }; | ||
} | ||
|
||
const Tags: NextPage<PageProps> = ({ params: { slug } }) => { | ||
const tags = slug; | ||
|
||
return ( | ||
<ContentsLayout | ||
description='' | ||
pageType='blog' | ||
pageUrl={PagePath.tagResult(tags, true)} | ||
> | ||
<h1 className={clsx('text-4xl')}>Tags</h1> | ||
|
||
{/* Tags */} | ||
<div className={clsx('flex flex-wrap gap-4 text-sm', tags.length && 'mt-3')}> | ||
{tags.map((tag) => ( | ||
<Link | ||
key={tag} | ||
href={PagePath.tagResult([tag])} | ||
className='cursor-pointer hover:opacity-50' | ||
> | ||
# {tag} | ||
</Link> | ||
))} | ||
</div> | ||
</ContentsLayout> | ||
); | ||
}; | ||
|
||
export default Tags; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2cc3d90
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
tatsutakein-jp – ./
tatsutakein-jp-git-main-tatsutakein.vercel.app
tatsutakein-jp-tatsutakein.vercel.app
tatsutakein.jp
www.tatsutakein.jp