Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c6e4877

Browse files
remove breadcrumb titles and add carbon ads
1 parent b440655 commit c6e4877

File tree

14 files changed

+29
-52
lines changed

14 files changed

+29
-52
lines changed

app/(main)/(author)/author/[slug]/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,7 @@ export default async function AuthorPage({ params }: Props) {
5858
<div className="container px-5 mx-auto">
5959
<BreadcrumbLinks
6060
links={[
61-
{ title: "Authors", href: "/authors/page/1" },
62-
{ title: author.title },
61+
{ title: "Authors", href: "/authors/page/1" }
6362
]}
6463
/>
6564
<div className="w-full flex flex-col gap-4 md:gap-8">

app/(main)/(course)/course/[courseSlug]/page.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,7 @@ export default async function CoursePage({ params }: Props) {
6868
<ShowPro />
6969
<BreadcrumbLinks
7070
links={[
71-
{ title: "Courses", href: "/courses/page/1" },
72-
{ title: course.title },
71+
{ title: "Courses", href: "/courses/page/1" }
7372
]}
7473
/>
7574
<article>
@@ -102,7 +101,6 @@ export default async function CoursePage({ params }: Props) {
102101
<DateComponent dateString={course.date} />
103102
</div>
104103
</div>
105-
<CarbonAdBanner />
106104
{course?.stripeProduct && course?.title && (
107105
<section className="flex gap-2">
108106
<Buy stripeProduct={course.stripeProduct} title={course.title} />
@@ -111,13 +109,15 @@ export default async function CoursePage({ params }: Props) {
111109
)}
112110
</div>
113111
</div>
114-
115112
{course.content?.length && (
116113
<PortableText
117114
className="mx-auto prose-violet lg:prose-xl dark:prose-invert"
118115
value={course.content as PortableTextBlock[]}
119116
/>
120117
)}
118+
<div className="p-8 flex justify-end">
119+
<CarbonAdBanner />
120+
</div>
121121
</article>
122122
<Suspense>
123123
<Lessons courseSlug={params.courseSlug} />

app/(main)/(course)/courses/page.tsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import type { CoursesQueryResult } from "@/sanity.types";
1111
import { sanityFetch } from "@/sanity/lib/fetch";
1212
import { coursesQuery } from "@/sanity/lib/queries";
1313
import MoreHeader from "@/components/more-header";
14+
import CarbonAdBanner from "@/components/carbon-ad-banner";
1415

1516
function HeroCourse({
1617
title,
@@ -28,7 +29,7 @@ function HeroCourse({
2829
<Link className="block mb-8 group md:mb-16" href={`/course/${slug}`}>
2930
<CoverImage image={coverImage} priority />
3031
</Link>
31-
<div className="mb-20 md:mb-28 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
32+
<div className="mb-8 md:mb-16 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
3233
<div>
3334
<h3 className="mb-4 text-4xl leading-tight text-pretty lg:text-6xl">
3435
<Link href={`/course/${slug}`} className="hover:underline">
@@ -81,6 +82,7 @@ export default async function Page() {
8182
) : (
8283
<Onboarding />
8384
)}
85+
<CarbonAdBanner />
8486
{heroPost?._id && (
8587
<aside>
8688
<MoreHeader title="Latest Courses" href="/courses/page/1" />

app/(main)/(guest)/guest/[slug]/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,7 @@ export default async function GuestPage({ params }: Props) {
5959
<div className="container px-5 mx-auto">
6060
<BreadcrumbLinks
6161
links={[
62-
{ title: "Guests", href: "/guests/page/1" },
63-
{ title: guest.title },
62+
{ title: "Guests", href: "/guests/page/1" }
6463
]}
6564
/>
6665
<div className="w-full flex flex-col gap-4 md:gap-8">

app/(main)/(podcast)/podcast/[slug]/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,7 @@ export default async function PodcastPage({ params }: Props) {
7070
<div className="container px-5 mx-auto">
7171
<BreadcrumbLinks
7272
links={[
73-
{ title: "Podcasts", href: "/podcasts/page/1" },
74-
{ title: podcast.title },
73+
{ title: "Podcasts", href: "/podcasts/page/1" }
7574
]}
7675
/>
7776
<article>

app/(main)/(podcast)/podcasts/page.tsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import { podcastsQuery } from "@/sanity/lib/queries";
1313
import { Button } from "@/components/ui/button";
1414
import { Separator } from "@/components/ui/separator";
1515
import MoreHeader from "@/components/more-header";
16+
import CarbonAdBanner from "@/components/carbon-ad-banner";
1617

1718
function HeroPodcast({
1819
title,
@@ -31,7 +32,7 @@ function HeroPodcast({
3132
<Link className="block mb-8 group md:mb-16" href={`/podcast/${slug}`}>
3233
<CoverImage image={coverImage} priority />
3334
</Link>
34-
<div className="mb-20 md:mb-28 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
35+
<div className="mb-8 md:mb-16 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
3536
<div>
3637
<h3 className="mb-4 text-4xl leading-tight text-pretty lg:text-6xl">
3738
<Link href={`/podcast/${slug}`} className="hover:underline">
@@ -93,6 +94,7 @@ export default async function Page() {
9394
) : (
9495
<Onboarding />
9596
)}
97+
<CarbonAdBanner />
9698
{heroPost?._id && (
9799
<aside>
98100
<MoreHeader title="Latest Podcasts" href="/podcasts/page/1" />

app/(main)/(post)/blog/page.tsx

+10-27
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ import { sanityFetch } from "@/sanity/lib/fetch";
1212
import { blogQuery } from "@/sanity/lib/queries";
1313
import { Button, buttonVariants } from "@/components/ui/button";
1414
import { Separator } from "@/components/ui/separator";
15+
import CarbonAdBanner from "@/components/carbon-ad-banner";
16+
import MoreHeader from "@/components/more-header";
1517

1618
function HeroPost({
1719
title,
@@ -29,7 +31,7 @@ function HeroPost({
2931
<Link className="block mb-8 group md:mb-16" href={`/post/${slug}`}>
3032
<CoverImage image={coverImage} priority />
3133
</Link>
32-
<div className="mb-20 md:mb-28 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
34+
<div className="mb-8 md:mb-16 md:grid md:grid-cols-2 md:gap-x-16 lg:gap-x-8">
3335
<div>
3436
<h3 className="mb-4 text-4xl leading-tight text-pretty lg:text-6xl">
3537
<Link href={`/post/${slug}`} className="hover:underline">
@@ -82,33 +84,14 @@ export default async function Page() {
8284
) : (
8385
<Onboarding />
8486
)}
85-
87+
<CarbonAdBanner />
8688
{heroPost?._id && (
87-
<>
88-
<div className="mb-16">
89-
<Separator />
90-
</div>
91-
<aside>
92-
<div className="flex flex-col md:flex-row md:justify-between">
93-
<h2 className="mb-8 text-6xl font-bold leading-tight tracking-tighter md:text-7xl">
94-
Latest Posts
95-
</h2>
96-
<Button
97-
asChild
98-
className="mb-8 text-3xl font-bold md:text-4xl p-2 md:p-8"
99-
>
100-
<Link href="/blog/page/1">Read More</Link>
101-
</Button>
102-
</div>
103-
<Suspense fallback={<p>Loading feed...</p>}>
104-
<MoreContent
105-
type={heroPost._type}
106-
skip={heroPost._id}
107-
limit={4}
108-
/>
109-
</Suspense>
110-
</aside>
111-
</>
89+
<aside>
90+
<MoreHeader title="View More" href="/blog/page/1" />
91+
<Suspense fallback={<p>Loading feed...</p>}>
92+
<MoreContent type={heroPost._type} skip={heroPost._id} limit={4} />
93+
</Suspense>
94+
</aside>
11295
)}
11396
</div>
11497
);

app/(main)/(post)/post/[slug]/page.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ export default async function PostPage({ params }: Props) {
6868
return (
6969
<div className="container px-5 mx-auto">
7070
<BreadcrumbLinks
71-
links={[{ title: "Blog", href: "/blog/page/1" }, { title: post.title }]}
71+
links={[{ title: "Blog", href: "/blog/page/1" }]}
7272
/>
7373
<article>
7474
<h1 className="mb-12 text-4xl font-bold leading-tight tracking-tighter text-balance md:text-7xl md:leading-none lg:text-8xl">

app/(main)/(sponsor)/sponsor/[slug]/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,7 @@ export default async function SponsorPage({ params }: Props) {
5858
<div className="container px-5 mx-auto">
5959
<BreadcrumbLinks
6060
links={[
61-
{ title: "Sponsors", href: "/sponsors/page/1" },
62-
{ title: sponsor.title },
61+
{ title: "Sponsors", href: "/sponsors/page/1" }
6362
]}
6463
/>
6564
<div className="w-full flex flex-col gap-4 md:gap-8">

app/(main)/(top-level-pages)/[slug]/page.tsx

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { Metadata, ResolvingMetadata } from "next";
2-
import { groq, type PortableTextBlock } from "next-sanity";
2+
import { type PortableTextBlock } from "next-sanity";
33
import { notFound } from "next/navigation";
44

55
import PortableText from "@/components/portable-text";
@@ -8,7 +8,6 @@ import type { PageQueryResult } from "@/sanity.types";
88
import { sanityFetch } from "@/sanity/lib/fetch";
99
import { pageQuery } from "@/sanity/lib/queries";
1010
import { resolveOpenGraphImage } from "@/sanity/lib/utils";
11-
import { BreadcrumbLinks } from "@/components/breadrumb-links";
1211

1312
type Props = {
1413
params: { slug: string };
@@ -49,7 +48,6 @@ export default async function PagePage({ params }: Props) {
4948

5049
return (
5150
<div className="container px-5 mx-auto">
52-
<BreadcrumbLinks links={[{ title: page.title }]} />
5351
<div className="w-full flex flex-col gap-4 md:gap-8 my-8 md:my-12">
5452
<div className="flex flex-col gap-2 md:gap-">
5553
<h1 className="text-xl font-bold leading-tight tracking-tighter text-balance md:text-2xl md:leading-none lg:text-4xl">

app/(main)/(top-level-pages)/sponsorships/blog/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,7 @@ export default async function SponsorshipsPage() {
5555
<div className="container px-5 mx-auto">
5656
<BreadcrumbLinks
5757
links={[
58-
{ title: "Sponsorships", href: "/sponsorships" },
59-
{ title: page.title },
58+
{ title: "Sponsorships", href: "/sponsorships" }
6059
]}
6160
/>
6261
<section className="grid grid-cols-1 gap-2 mx-2 md:mx-8 md:gap-8 markdown">

app/(main)/(top-level-pages)/sponsorships/code-with-codingcatdev/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,7 @@ export default async function SponsorshipsPage() {
5858
<div className="container px-5 mx-auto">
5959
<BreadcrumbLinks
6060
links={[
61-
{ title: "Sponsorships", href: "/sponsorships" },
62-
{ title: page.title },
61+
{ title: "Sponsorships", href: "/sponsorships" }
6362
]}
6463
/>
6564
<section className="grid grid-cols-1 gap-2 md:mx-8 md:gap-8 mx-auto prose-violet lg:prose-xl dark:prose-invert">

app/(main)/(top-level-pages)/sponsorships/page.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ export default async function SponsorshipsPage() {
5555

5656
return (
5757
<div className="container px-5 mx-auto">
58-
<BreadcrumbLinks links={[{ title: page.title }]} />
5958
<div className="w-full flex flex-col gap-4 md:gap-8 my-8 md:my-12">
6059
<div className="flex flex-col gap-2 md:gap-">
6160
<h1 className="text-xl font-bold leading-tight tracking-tighter text-balance md:text-2xl md:leading-none lg:text-4xl">

app/(main)/(top-level-pages)/sponsorships/podcast/page.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,7 @@ export default async function SponsorshipsPodcastPage() {
7373
<div className="container px-5 mx-auto">
7474
<BreadcrumbLinks
7575
links={[
76-
{ title: "Sponsorships", href: "/sponsorships" },
77-
{ title: page.title },
76+
{ title: "Sponsorships", href: "/sponsorships" }
7877
]}
7978
/>
8079
<div className="w-full flex flex-col gap-4 md:gap-8 my-8 md:my-12">

0 commit comments

Comments
 (0)