From cbdf61073f288dbbf3db6281301ed145fedf0b4f Mon Sep 17 00:00:00 2001 From: Ryan Salazar Date: Fri, 29 May 2026 15:28:48 +0000 Subject: [PATCH] manufacturers: never-empty image cascade for coverage cards MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Recent Coverage cards used to show a gray box when an article had no featured_image (common for older WP imports). Now cascade: article.featured_image → company.logo_url → /assets/images/article-placeholder.svg so the card never goes blank. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/app/manufacturers/[slug]/page.tsx | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/app/manufacturers/[slug]/page.tsx b/src/app/manufacturers/[slug]/page.tsx index a7f27ef..e0a93a8 100644 --- a/src/app/manufacturers/[slug]/page.tsx +++ b/src/app/manufacturers/[slug]/page.tsx @@ -413,12 +413,16 @@ export default async function ManufacturerProfile({ href={`/news/${r.wp_slug}`} className="group bg-[#0d0d0d] border border-[#252525] rounded-md p-3 hover:border-[#3b82f6] hover:shadow-sm transition-all flex gap-3" > - {r.featured_image ? ( - /* eslint-disable-next-line @next/next/no-img-element */ - - ) : ( -
- )} + {/* Image fallback cascade — Ryan rule: never show an empty + gray box on a coverage card. Falls through: + article featured_image → company logo → static placeholder. */} + {/* eslint-disable-next-line @next/next/no-img-element */} +

{r.title}