Skip to content

Commit 926bc18

Browse files
committed
add podmatch
1 parent 46de64f commit 926bc18

3 files changed

Lines changed: 95 additions & 8 deletions

File tree

app/(main)/(podcast)/podcast/Podcast.tsx

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ import PodcastOpenSpotify from "@/components/podcast-open-spotify";
1717
import PodcastOpenApple from "@/components/podcast-open-apple";
1818
import PodcastOpenYouTube from "@/components/podcast-open-youtube";
1919
import CarbonAdBanner from "@/components/carbon-ad-banner";
20+
import PodmatchBadge from "@/components/podmatch-badge";
2021

2122
export default async function Podcast({ podcast }: { podcast: NonNullable<PodcastQueryResult> }) {
2223

@@ -70,7 +71,10 @@ export default async function Podcast({ podcast }: { podcast: NonNullable<Podcas
7071
<DateComponent dateString={podcast.date} />
7172
</div>
7273
</div>
73-
<CarbonAdBanner />
74+
<div className="flex m-2 md:m-8 justify-center">
75+
76+
<PodmatchBadge />
77+
</div>
7478
</div>
7579

7680
{src && (
@@ -98,14 +102,18 @@ export default async function Podcast({ podcast }: { podcast: NonNullable<Podcas
98102
<hr className="border-accent-2" />
99103
</section>
100104
)}
101-
102-
{podcast?.content?.length && (
103-
<PortableText
104-
className="mx-auto prose-violet lg:prose-xl dark:prose-invert"
105-
value={podcast.content as PortableTextBlock[]}
106-
/>
107-
)}
105+
<div className="my-2 md:my-8">
106+
{podcast?.content?.length && (
107+
<PortableText
108+
className="mx-auto prose-violet lg:prose-xl dark:prose-invert"
109+
value={podcast.content as PortableTextBlock[]}
110+
/>
111+
)}
112+
</div>
108113
</article>
114+
<div className="flex m-2 md:m-8 justify-center">
115+
<PodmatchBadge />
116+
</div>
109117
{podcast?.pick?.length && (
110118
<>
111119
<hr className="mb-8 sm:mb-24 border-accent-2 mt-8 sm:mt-28" />

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

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import { Button } from "@/components/ui/button";
1414
import { Separator } from "@/components/ui/separator";
1515
import MoreHeader from "@/components/more-header";
1616
import CarbonAdBanner from "@/components/carbon-ad-banner";
17+
import PodmatchBadge from "@/components/podmatch-badge";
1718

1819
function HeroPodcast({
1920
title,
@@ -99,6 +100,9 @@ export default async function Page() {
99100
<Onboarding />
100101
)}
101102
<CarbonAdBanner />
103+
<div className="flex m-2 md:m-8 justify-center">
104+
<PodmatchBadge />
105+
</div>
102106
{heroPost?._id && (
103107
<aside>
104108
<MoreHeader title="Latest Podcasts" href="/podcasts/page/1" />

components/podmatch-badge.tsx

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
'use client';
2+
3+
export default function PodmatchBadge() {
4+
return (
5+
<div style={{ minWidth: 160, maxWidth: 400 }}>
6+
<a
7+
href="https://www.podmatch.com/member/codingcatdev"
8+
style={{ textDecoration: "none", color: "inherit", display: "block" }}
9+
target="_blank"
10+
>
11+
<div
12+
style={{
13+
display: "flex",
14+
alignItems: "center",
15+
padding: 15,
16+
overflow: "hidden",
17+
border: "solid 1px #ccc",
18+
borderRadius: 10,
19+
}}
20+
>
21+
<div
22+
style={{
23+
flexShrink: 0,
24+
marginRight: 15,
25+
padding: 0,
26+
background: "none",
27+
}}
28+
>
29+
<img
30+
onError={(e) => {
31+
const target = e.target as HTMLImageElement;
32+
target.src = "https://podmatch.com/assets/img/waveform_img.png";
33+
}}
34+
alt="Cover Art"
35+
style={{ height: 85 }}
36+
src="https://img.rephonic.com/artwork/purrfectdev.jpg?width=600&height=600&quality=95"
37+
/>
38+
</div>
39+
<div
40+
style={{
41+
whiteSpace: "nowrap",
42+
overflow: "hidden",
43+
textOverflow: "ellipsis",
44+
textAlign: "left",
45+
}}
46+
>
47+
<span style={{ display: "block", marginBottom: 3 }}>
48+
<img
49+
src="https://podmatch.com/assets/img/PodMatch_Logo.png"
50+
alt="PodMatch Logo"
51+
style={{ width: 80 }}
52+
/>
53+
</span>
54+
<span
55+
style={{
56+
display: "block",
57+
fontSize: 16,
58+
fontWeight: 600,
59+
marginBottom: 2,
60+
overflow: "hidden",
61+
textOverflow: "ellipsis",
62+
}}
63+
>
64+
CodingCat.dev Podcast
65+
</span>
66+
<span style={{ display: "block", fontSize: 12, marginBottom: 2 }}>
67+
<u>Become a guest</u> on my podcast
68+
</span>
69+
<span style={{ marginRight: 10, fontSize: 11 }}></span>
70+
</div>
71+
</div>
72+
</a>
73+
</div>
74+
);
75+
}

0 commit comments

Comments
 (0)