Skip to content

Commit 3ca812f

Browse files
authored
Add footer to showcase and blog pages (#2042)
1 parent 262cfd7 commit 3ca812f

File tree

4 files changed

+17
-2
lines changed

4 files changed

+17
-2
lines changed

src/app/blog/[slug]/page.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import Image from "next/image";
55
import { NewsletterForm } from "@/components/newsletter-form";
66
import GridContainer from "@/components/grid-container";
77
import type { Metadata } from "next/types";
8+
import { FooterSitemap, FooterMeta } from "@/components/footer";
89

910
type Props = {
1011
params: Promise<{
@@ -97,7 +98,7 @@ export default async function DocPage(props: Props) {
9798
</div>
9899
</div>
99100

100-
<div className="mb-46 max-xl:mx-auto max-xl:mt-16 max-xl:w-full max-xl:max-w-(--breakpoint-md)">
101+
<div className="max-xl:mx-auto max-xl:mt-16 max-xl:w-full max-xl:max-w-(--breakpoint-md)">
101102
<GridContainer className="px-4 py-2 lg:px-2">
102103
<article className="prose prose-blog max-w-(--breakpoint-md)">
103104
<post.Component />
@@ -116,6 +117,10 @@ export default async function DocPage(props: Props) {
116117
</div>
117118
</section>
118119
</GridContainer>
120+
<GridContainer className="mt-46">
121+
<FooterSitemap className="*:first:border-l-0 *:last:border-r-0" />
122+
</GridContainer>
123+
<FooterMeta className="px-4 md:px-6 lg:px-8" />
119124
</div>
120125
</div>
121126
</>

src/app/blog/page.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import type { Metadata } from "next";
55
import Link from "next/link";
66
import { Fragment } from "react";
77
import { formatDate, getBlogPostBySlug, getBlogPostSlugs, nonNullable } from "./api";
8+
import { FooterSitemap, FooterMeta } from "@/components/footer";
89

910
export const metadata: Metadata = {
1011
title: "Blog",
@@ -80,6 +81,10 @@ export default async function Blog() {
8081
</Fragment>
8182
))}
8283
</div>
84+
<GridContainer>
85+
<FooterSitemap className="*:first:border-l-0 *:last:border-r-0" />
86+
</GridContainer>
87+
<FooterMeta className="px-4 md:px-6 lg:px-8" />
8388
</div>
8489
);
8590
}

src/app/showcase/page.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { FooterSitemap, FooterMeta } from "@/components/footer";
12
import GridContainer from "@/components/grid-container";
23
import ShowcaseThumbnail from "@/components/showcase-thumbnail";
34
import type { Metadata } from "next";
@@ -41,6 +42,10 @@ export default async function Showcase() {
4142
<ShowcaseThumbnail key={showcase.name} showcase={showcase} priority={siteIndex < 8} />
4243
))}
4344
</div>
45+
<GridContainer>
46+
<FooterSitemap className="*:first:border-l-0 *:last:border-r-0" />
47+
</GridContainer>
48+
<FooterMeta className="px-4 md:px-6 lg:px-8" />
4449
</div>
4550
);
4651
}

src/components/showcase-thumbnail.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export default function ShowcaseThumbnail({ showcase, priority = false }: { show
6767

6868
return (
6969
<div
70-
className="group dark:border-bg-white/10 relative border-x border-gray-950/5 transition-colors hover:bg-gray-950/5 max-sm:border-0 sm:max-lg:nth-[2n]:border-r-0 sm:max-lg:nth-[2n+1]:border-l-0 lg:max-xl:nth-[3n]:border-r-0 lg:max-xl:nth-[3n+1]:border-l-0 xl:nth-[4n]:border-r-0 xl:nth-[4n+1]:border-l-0"
70+
className="group dark:border-bg-white/10 relative isolate border-x border-gray-950/5 transition-colors hover:bg-gray-950/5 max-sm:border-0 sm:max-lg:nth-[2n]:border-r-0 sm:max-lg:nth-[2n+1]:border-l-0 lg:max-xl:nth-[3n]:border-r-0 lg:max-xl:nth-[3n+1]:border-l-0 xl:nth-[4n]:border-r-0 xl:nth-[4n+1]:border-l-0 dark:border-white/10 dark:hover:bg-white/2.5"
7171
onMouseEnter={() => {
7272
if (state.current === "idle") {
7373
state.current = "playing";

0 commit comments

Comments
 (0)