From f8cdbb5cfe5708537059e7c17403fc0655f3b885 Mon Sep 17 00:00:00 2001 From: Le Minh Tri Date: Sat, 25 Feb 2023 22:07:54 +0700 Subject: [PATCH 1/3] fix(layout): add field `keywords` to AppLayout --- src/layouts/AppLayout.astro | 1 + 1 file changed, 1 insertion(+) diff --git a/src/layouts/AppLayout.astro b/src/layouts/AppLayout.astro index bef74a21..6a7d42ab 100644 --- a/src/layouts/AppLayout.astro +++ b/src/layouts/AppLayout.astro @@ -11,6 +11,7 @@ export interface Props { description: string author: string headerCssClasses?: string + keywords?: string[] } const { title, description = '', author, headerCssClasses = '' } = Astro.props From dfcd6d3a943035f0267249be32f81d3792f1c2d5 Mon Sep 17 00:00:00 2001 From: Le Minh Tri Date: Sat, 25 Feb 2023 22:08:31 +0700 Subject: [PATCH 2/3] fix(component): adjust padding and margin-bottom for PostHeader --- src/components/post/PostHeader.astro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/post/PostHeader.astro b/src/components/post/PostHeader.astro index 26604aa9..69a7e574 100644 --- a/src/components/post/PostHeader.astro +++ b/src/components/post/PostHeader.astro @@ -47,6 +47,6 @@ const formattedDate = formatDate(pubDate) From c7078f3b62e9974746ea4343b75c911de8f00db0 Mon Sep 17 00:00:00 2001 From: Le Minh Tri Date: Sat, 25 Feb 2023 22:09:04 +0700 Subject: [PATCH 3/3] feat(layout): add layout PostLayout --- src/layouts/PostLayout.astro | 40 ++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 src/layouts/PostLayout.astro diff --git a/src/layouts/PostLayout.astro b/src/layouts/PostLayout.astro new file mode 100644 index 00000000..cf3789c3 --- /dev/null +++ b/src/layouts/PostLayout.astro @@ -0,0 +1,40 @@ +--- +import type { CollectionEntry } from 'astro:content' + +import Breadcrumb from '@/components/Breadcrumb.astro' +import PostHeader from '@/components/post/PostHeader.astro' +import siteConfig from '@/configs/site' +import AppLayout from '@/layouts/AppLayout.astro' + +interface Props { + frontmatter: CollectionEntry<'leetcode-solutions'>['data'] +} + +const { frontmatter } = Astro.props +const { author } = siteConfig +--- + + +
+ + +
+ +
+
+
+ +