PageSourceSearch

https://ervik.as/assets/news-C_GsVXr8.js

js ervik.as collected 2026-10-08 09:07:35 UTC 3,739 bytes, 1 lines download raw bytes

1import{E as c,u,a as h,j as e,P as y,v as b,n as f,L as i,X as j}from"./index-yGm7nZLB.js";import{getNewsArticles as N}from"./news.articles.functions-DxA1fgdy.js";import{f as m,i as v}from"./article-updates-yxdngIFL.js";import{A as w}from"./arrow-right-DX1Syn1Y.js";import{B as k}from"./book-open-BZacXvSq.js";import{N as A}from"./newspaper-BMb5pAxz.js";function I(){const s=c.useSearch(),x=c.useLoaderData(),p=u(N),{data:g,isLoading:o,isError:n,error:t}=h({queryKey:["news-articles"],queryFn:()=>p(),staleTime:300*1e3,initialData:x}),l=g?.articles??[],d=s.tag?l.filter(r=>r.tags.includes(s.tag)):l;return e.jsxs(y,{children:[e.jsx(b,{title:s.tag?`Tag: ${s.tag}`:"News",description:"Daily cybersecurity news coverage and in-depth weekly guides — written for security practitioners, covering AI cybersecurity, Agentic AI, Agentic SOC, cyber attacks, MDR, SOC, threat intelligence, vulnerability management, vulnerabilities, OT/ICS security, and the broader industry."}),e.jsx("section",{className:"mx-auto max-w-4xl px-6 pt-10",children:e.jsxs("a",{href:"/rss.xml",className:"mb-6 flex items-center justify-between gap-3 rounded-lg border border-primary/30 bg-primary/5 px-4 py-3 transition-colors hover:border-primary/50 hover:bg-primary/10",children:[e.jsxs("span",{className:"flex items-center gap-2 font-mono text-xs text-foreground/90",children:[e.jsx(f,{size:14,className:"shrink-0 text-primary"}),"Get every CVE, ransomware disclosure, and zero-day the moment it's published — subscribe via RSS"]}),e.jsx(w,{size:14,className:"shrink-0 text-primary"})]})}),e.jsxs("section",{className:"mx-auto max-w-4xl px-6 pb-10",children:[s.tag&&e.jsxs("div",{className:"mb-6 flex items-center gap-2 font-mono text-xs",children:[e.jsx("span",{className:"text-muted-foreground",children:"Filtering by:"}),e.jsxs("span",{className:"inline-flex items-center gap-1.5 rounded-full border border-primary/40 bg-primary/10 px-3 py-1 text-primary",children:[s.tag,e.jsx(i,{to:"/news",className:"text-primary hover:text-foreground",children:e.jsx(j,{size:12})})]})]}),o&&e.jsx("p",{className:"font-mono text-sm text-muted-foreground",children:"Loading articles…"}),n&&e.jsxs("p",{className:"rounded border border-red-500/40 bg-red-500/10 px-3 py-2 font-mono text-xs text-red-400",children:["Failed to load: ",t instanceof Error?t.message:String(t)]}),!o&&!n&&d.length===0&&e.jsx("p",{className:"font-mono text-sm text-muted-foreground",children:s.tag?`No articles tagged "${s.tag}".`:"No articles published yet."}),e.jsx("div",{className:"space-y-6",children:d.map(r=>e.jsxs("article",{className:"rounded-lg border border-border bg-card/40 p-6 backdrop-blur transition-colors hover:border-primary/40",children:[e.jsxs("div",{className:"flex items-center gap-2 font-mono text-[11px] uppercase tracking-widest text-primary",children:[r.category==="guide"?e.jsx(k,{size:12}):e.jsx(A,{size:12}),r.category==="guide"?"In-Depth Guide":"Daily News",e.jsxs("span",{className:"text-muted-foreground",children:["· ",m(r.published_at),v(r.published_at,r.updated_at)&&e.jsxs(e.Fragment,{children:[" · Updated ",m(r.updated_at)]})]})]}),e.jsxs(i,{to:"/news/$slug",params:{slug:r.slug},className:"block",children:[e.jsx("h2",{className:"mt-2 text-xl font-semibold leading-snug hover:text-primary",children:r.title}),e.jsx("p",{className:"mt-2 text-sm text-muted-foreground",children:r.dek})]}),r.tags.length>0&&e.jsx("div",{className:"mt-3 flex flex-wrap gap-2",children:r.tags.map(a=>e.jsx(i,{to:"/news",search:{tag:a},className:"rounded-full border border-border bg-secondary/40 px-2.5 py-0.5 font-mono text-[10px] text-muted-foreground transition-colors hover:border-primary/40 hover:text-primary",children:a},a))})]},r.slug))})]})]})}export{I as component};

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.