PageSourceSearch

https://vassud.com/assets/BlogPost-CW82nozu.js

js vassud.com collected 2026-10-04 03:20:00 UTC 3,685 bytes, 1 lines download raw bytes

1import{r as i,j as e}from"./vendor-react-DzisJYOk.js";import{u as g,N as x,L as r,F as m}from"./index-R5u9GzeS.js";import{z as l,x as j,w as b,I as w}from"./vendor-ui-BRczz9ZN.js";import{m as o}from"./vendor-motion-KhQRDn-T.js";function N(s){const n=s.replace(/<[^>]*>/g," ").trim().split(/\s+/).filter(Boolean).length;return Math.max(1,Math.ceil(n/200))}function L(){const s=g(),[t,n]=i.useState(null),[d,c]=i.useState(!0),[h,u]=i.useState(!1);if(i.useEffect(()=>{s.slug&&(c(!0),fetch(`/api/blogs/slug/${s.slug}`).then(a=>a.ok?a.json():(u(!0),null)).then(a=>{a&&n(a)}).finally(()=>c(!1)))},[s.slug]),d)return e.jsx("div",{className:"min-h-screen bg-[#161748] text-white flex items-center justify-center",children:e.jsx("div",{className:"w-10 h-10 border-2 border-[#f95d9b] border-t-transparent rounded-full animate-spin"})});if(h||!t)return e.jsxs("div",{className:"min-h-screen bg-[#161748] text-white",children:[e.jsx(x,{}),e.jsxs("div",{className:"flex flex-col items-center justify-center min-h-[60vh] gap-4",children:[e.jsx("h1",{className:"text-3xl font-serif",children:"Post not found"}),e.jsxs(r,{href:"/blogs",className:"text-[#fa8ab8] hover:text-white transition-colors flex items-center gap-2",children:[e.jsx(l,{size:16})," Back to Blog"]})]}),e.jsx(m,{})]});const p=N(t.content),f=t.publishedAt?new Date(t.publishedAt).toLocaleDateString("en-GB",{day:"numeric",month:"long",year:"numeric"}):new Date(t.createdAt).toLocaleDateString("en-GB",{day:"numeric",month:"long",year:"numeric"});return e.jsxs("div",{className:"min-h-screen bg-[#161748] text-white",children:[e.jsx(x,{}),e.jsxs("section",{className:"relative pt-28 pb-12 overflow-hidden",children:[e.jsx("div",{className:"absolute inset-0 bg-gradient-to-b from-[#0f1138] to-[#161748]"}),e.jsx("div",{className:"absolute top-0 right-0 w-96 h-96 bg-[#f95d9b]/10 rounded-full blur-3xl"}),e.jsx("div",{className:"relative max-w-3xl mx-auto px-4 sm:px-6",children:e.jsxs(o.div,{initial:{opacity:1},animate:{opacity:1},transition:{duration:.5},children:[e.jsxs(r,{href:"/blogs",className:"inline-flex items-center gap-2 text-[#fa8ab8] hover:text-white text-sm mb-6 transition-colors",children:[e.jsx(l,{size:14})," All Posts"]}),e.jsx("h1",{className:"text-3xl sm:text-5xl font-serif leading-tight text-white mb-4",children:t.title}),t.excerpt&&e.jsx("p",{className:"text-white/55 text-lg leading-relaxed mb-6",children:t.excerpt}),e.jsxs("div",{className:"flex flex-wrap items-center gap-4 text-sm text-white/40",children:[e.jsxs("span",{className:"flex items-center gap-1.5",children:[e.jsx(j,{size:13})," ",t.author]}),e.jsxs("span",{className:"flex items-center gap-1.5",children:[e.jsx(b,{size:13})," ",f]}),e.jsxs("span",{className:"flex items-center gap-1.5",children:[e.jsx(w,{size:13})," ",p," min read"]})]})]})})]}),t.coverImageUrl&&e.jsx("div",{className:"max-w-3xl mx-auto px-4 sm:px-6 mb-8",children:e.jsx(o.img,{initial:{opacity:1},animate:{opacity:1},transition:{duration:.5,delay:.1},src:t.coverImageUrl,alt:t.coverImageAlt||t.title,className:"w-full h-auto block rounded-2xl shadow-2xl"})}),e.jsx("article",{className:"max-w-3xl mx-auto px-4 sm:px-6 pb-20",children:e.jsx(o.div,{initial:{opacity:1},animate:{opacity:1},transition:{duration:.5,delay:.15},className:"rich-editor-content blog-post-content",dangerouslySetInnerHTML:{__html:t.content}})}),e.jsx("div",{className:"max-w-3xl mx-auto px-4 sm:px-6 pb-16",children:e.jsxs(r,{href:"/blogs",className:"inline-flex items-center gap-2 px-5 py-2.5 border border-white/15 text-white/55 hover:text-white hover:border-white/30 rounded-lg text-sm transition-all",children:[e.jsx(l,{size:14})," Back to all posts"]})}),e.jsx(m,{})]})}export{L as default};

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.