Skip to content

Commit 37ea54e

Browse files
HeyItsGilbertclaude
andcommitted
fix(podcast): make embed visible and show thumbnails on author pages
The click-to-load facade relied on Tailwind's `aspect-video` utility, which does not exist in the theme's Tailwind v2 CDN build — once the poster image was swapped for the iframe the container collapsed to zero height. Set the aspect ratio via the CSS `aspect-ratio` property instead. Also apply the YouTube-thumbnail-with-icon-fallback to the episode cards on author profile pages, which were always rendering the podcast icon. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 78997d7 commit 37ea54e

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

themes/powershell-community/layouts/_default/single.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,8 @@ <h3 class="font-semibold text-gray-900">Listen to this Episode</h3>
104104
<div class="mb-8">
105105
<div id="yt-facade" data-id="{{ . }}"
106106
role="button" tabindex="0" aria-label="Play video on YouTube"
107-
class="relative aspect-video rounded-xl overflow-hidden cursor-pointer group bg-black">
107+
style="aspect-ratio: 16 / 9;"
108+
class="relative rounded-xl overflow-hidden cursor-pointer group bg-black">
108109
<img src="https://img.youtube.com/vi/{{ . }}/maxresdefault.jpg"
109110
onerror="this.onerror=null;this.src='https://img.youtube.com/vi/{{ . }}/hqdefault.jpg';"
110111
alt="Watch this episode on YouTube" loading="lazy"

themes/powershell-community/layouts/taxonomy/author.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,19 @@ <h2 class="text-3xl font-bold text-gray-900">{{ $display }}</h2>
6969
<!-- Podcast Episode Layout -->
7070
<div class="lg:flex">
7171
<div class="lg:w-1/3 p-6 lg:pr-0">
72+
{{ $title := .Title }}
73+
{{ with .Params.youtube }}
74+
<div class="aspect-square rounded-lg overflow-hidden bg-gray-900">
75+
<img src="https://img.youtube.com/vi/{{ . }}/maxresdefault.jpg"
76+
onerror="this.onerror=null;this.src='https://img.youtube.com/vi/{{ . }}/hqdefault.jpg';"
77+
alt="{{ $title }}" loading="lazy"
78+
class="w-full h-full object-cover">
79+
</div>
80+
{{ else }}
7281
<div class="aspect-square bg-gradient-to-br from-purple-400 to-purple-600 rounded-lg flex items-center justify-center">
7382
<i class="fas fa-podcast text-4xl text-white"></i>
7483
</div>
84+
{{ end }}
7585
</div>
7686
<div class="lg:w-2/3 p-6 lg:pl-8">
7787
<div class="flex items-center text-purple-600 text-sm font-medium mb-3">

0 commit comments

Comments
 (0)