1import{l as x,d as h,j as e,n as p,h as n}from"./index-ecIq6INl.js";import{C as g}from"./Card-Bwqgvsh8.js";import{E as u}from"./ErrorMessage-B8eV_cH6.js";import{S as j}from"./SEOHead-Mja30UMx.js";import{B as f}from"./Breadcrumbs-Pydnz40P.js";import{a as N}from"./useNews-qQXUOM22.js";import{f as b,g as w}from"./utils-fJxONHoi.js";import{b as v}from"./schema-BFz1mEix.js";import{C as y}from"./clock-CvqAKoa0.js";import{E as k}from"./eye-DTC_uWAj.js";import{E}from"./external-link-CiOG4VzC.js";import"./file-text-C--Bbtsp.js";import"./chevron-right-Cohh131o.js";function M(){const{slug:m}=x(),{article:a,loading:c,error:l}=N(m),{buildLink:i}=h();if(c)return e.jsx(p,{});if(l||!a)return e.jsx(u,{message:l||"Article not found"});const d=s=>w(s),t=`${window.location.origin}${i(`/news/${a.slug}`)}`,o=v(a);return e.jsxs(e.Fragment,{children:[e.jsx(j,{title:a.headline,description:a.summary,url:t,canonical:t,image:a.image_url,type:"article",schema:o}),e.jsx("div",{className:"bg-neutral-50 min-h-screen",children:e.jsxs("div",{className:"max-w-4xl mx-auto px-4 sm:px-6 lg:px-8 py-8",children:[e.jsx("div",{className:"mb-6",children:e.jsx(f,{items:[{label:"News",href:i("/news")},{label:a.headline}]})}),e.jsxs(g,{className:"overflow-hidden",children:[a.image_url&&e.jsx("div",{className:"aspect-video bg-neutral-200 overflow-hidden -mx-6 -mt-6 mb-6",children:e.jsx("img",{src:a.image_url,alt:a.headline,className:"w-full h-full object-cover"})}),e.jsxs("div",{className:"mb-6",children:[e.jsx(n,{variant:d(a.category),className:"mb-3 capitalize",children:a.category}),e.jsx("h1",{className:"heading-page text-neutral-900 mb-4",children:a.headline}),e.jsxs("div",{className:"flex flex-wrap gap-4 text-neutral-600 text-sm mb-4",children:[e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(y,{className:"w-4 h-4"}),b(a.published_date)]}),e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(k,{className:"w-4 h-4"}),a.views," views"]}),e.jsx("span",{children:a.source})]}),e.jsx("p",{className:"text-lg text-neutral-700 mb-6 font-medium",children:a.summary})]}),e.jsx("div",{className:"prose max-w-none mb-6",children:e.jsx("div",{className:"text-neutral-700 whitespace-pre-wrap leading-relaxed",children:a.body})}),a.tags&&a.tags.length>0&&e.jsx("div",{className:"pt-6 border-t border-neutral-200 mb-6",children:e.jsx("div",{className:"flex flex-wrap gap-2",children:a.tags.map((s,r)=>e.jsx(n,{variant:"default",className:"text-xs",children:s},r))})}),a.related_links&&a.related_links.length>0&&e.jsxs("div",{className:"pt-6 border-t border-neutral-200",children:[e.jsx("h3",{className:"heading-card mb-3",children:"Related Links"}),e.jsx("ul",{className:"space-y-2",children:a.related_links.map((s,r)=>e.jsx("li",{children:e.jsxs("a",{href:s,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 text-primary hover:text-primary-dark",children:[e.jsx(E,{className:"w-4 h-4"}),s]})},r))})]})]})]})})]})}export{M as NewsDetailPage};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.