}
+ {(() => {
+ const previewUrl = card.imageUrl || card.extraMedia?.[0]?.url || '';
+ if (!previewUrl) {
+ return
;
+ }
+ return isVideoUrl(previewUrl)
+ ?
{card.title}
{card.cardType}
diff --git a/components/PublicGrid.tsx b/components/PublicGrid.tsx
index 5cb852f..3f07362 100644
--- a/components/PublicGrid.tsx
+++ b/components/PublicGrid.tsx
@@ -453,6 +453,9 @@ export default function PublicGrid({ cards, maxCols = 5 }: { cards: Card[], maxC
{cards.map((card) => {
const galleryCount = (card.extraMedia?.length || 0) + (card.imageUrl ? 1 : 0);
+ // Fall back to the first gallery item when no explicit cover is set.
+ const previewUrl = card.imageUrl || card.extraMedia?.[0]?.url || '';
+ const previewIsVideo = !!previewUrl && isVideoUrl(previewUrl);
return (
- {card.imageUrl ? (
-

+ {previewUrl ? (
+ previewIsVideo ? (
+
+ ) : (
+

+ )
) : (
No Image
)}