{article.title}
{images.length > 0 && ({p}
))}--- import type { RawArticle } from "@/lib/data" import Breadcrumb from "@/components/Breadcrumb.astro" import { getI18n } from "@/i18n/utils" import { href, ROUTES } from '@/lib/routes' import { ssrBase } from "@/lib/api" interface Props { article: RawArticle | null error?: "missing" | "failed" | null } const { article, error = null } = Astro.props const { locale, t } = getI18n(Astro) const full = (u: string): string => { if (!u) return "" if (/^https?:\/\//i.test(u)) return u return ssrBase().replace(/\/$/, "") + u } const images = (article?.images ?? []) .map((im) => ({ id: im.id, url: full(im.image || ""), name: im.name || "", })) .filter((im) => im.url) const descParas = (article?.description || "") .split(/\n\n+/) .map((s) => s.trim()) .filter(Boolean) const homeHref = href(locale, ROUTES.home) const archiveHref = href(locale, ROUTES.shows) const crumbs: { label: string; href: string }[] = [ // { // label: t("Runway looks"), // href: archiveHref, // }, ] if (article?.brand_id) { crumbs.push({ label: article.brand_name || "Brand", href: `${archiveHref}?brand_id=${article.brand_id}`, }) } ---
{p}
))}{error === "missing" ? t('No article ID specified') : t('Failed to load article. Please refresh or try later.')}
← {t('Back to Index')}