-
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.
Merge pull request #8 from ashcolor/develop
seo
- Loading branch information
Showing
10 changed files
with
96 additions
and
66 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
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
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 was deleted.
Oops, something went wrong.
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,48 @@ | ||
<script setup lang="ts"> | ||
import { BLOG_TITLE } from "@/utils/const"; | ||
const route = useRoute(); | ||
const article = await queryContent(route.path) | ||
.findOne() | ||
.catch(() => null); | ||
useSeoMeta({ | ||
title: `${article?.title} | ${BLOG_TITLE}`, | ||
ogTitle: `${article?.title} | ${BLOG_TITLE}`, | ||
}); | ||
</script> | ||
|
||
<template> | ||
<NuxtLayout> | ||
<div v-if="article"> | ||
<ProseH1 class="text-center">{{ BLOG_TITLE }}</ProseH1> | ||
<div class="mb-8"> | ||
<ProseH1>{{ article.title }}</ProseH1> | ||
<p class="text-sm font-light">{{ article.createdAt }}</p> | ||
</div> | ||
<div class="grid grid-cols-12"> | ||
<div class="col-span-12 flex flex-col gap-4 lg:col-span-8"> | ||
<div v-if="article.thumbnail" class="mx-auto mb-8"> | ||
<img :src="article.thumbnail" /> | ||
</div> | ||
<div class="col-span-4 mb-8 block lg:hidden"> | ||
<PageToc></PageToc> | ||
</div> | ||
<ContentRenderer :value="article" /> | ||
</div> | ||
<div class="col-span-4 hidden px-4 lg:block"> | ||
<div class="sticky top-24 flex flex-col"> | ||
<PageToc></PageToc> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div v-else class="flex flex-col gap-4"> | ||
<div class="flex flex-col gap-4"> | ||
<h1 class="text-xl">お探しのページが見つかりませんでした</h1> | ||
<ProseA to="/">TOPへ</ProseA> | ||
</div> | ||
</div> | ||
</NuxtLayout> | ||
</template> |
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
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