1import{j as e}from"./ui-vendor-Pu0cN9S7.js";import{ah as m,u,L as h,at as t,c as a,av as i,au as c,C as j,r as v,s as g,aw as p,b,ax as f}from"./index-DVqYXXq7.js";import{u as N}from"./usePublicContent-BfrQAWnI.js";function y(){const{contentId:o}=m(),[r]=u(),l=r.get("version")?parseInt(r.get("version")):void 0,{content:s,loading:d,error:n}=N(o,l);if(d)return e.jsx("div",{className:"flex items-center justify-center min-h-screen",children:e.jsxs("div",{className:"flex flex-col items-center gap-4",children:[e.jsx(h,{className:"h-8 w-8 animate-spin text-muted-foreground"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Loading content..."})]})});if(n)return e.jsx("div",{className:"container mx-auto max-w-4xl p-6 mt-8",children:e.jsxs(t,{variant:"destructive",children:[e.jsx(a,{className:"h-4 w-4"}),e.jsx(i,{children:"Error"}),e.jsx(c,{children:n})]})});if(!s)return e.jsx("div",{className:"container mx-auto max-w-4xl p-6 mt-8",children:e.jsxs(t,{children:[e.jsx(a,{className:"h-4 w-4"}),e.jsx(i,{children:"Content not found"}),e.jsx(c,{children:"The requested content could not be found or is not publicly available."})]})});const x={id:s.id,content_type:s.content_type,brand_id:s.brand_id,current_version:s.current_version,content_versions:[{content_json:s.content_json,version_number:s.current_version,is_current:!0}],metadata:s.metadata,status:s.status};return e.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-gray-900",children:[s.brand_css&&e.jsx("style",{dangerouslySetInnerHTML:{__html:s.brand_css}}),e.jsx("div",{className:"container mx-auto max-w-6xl py-8 px-4 sm:px-6 lg:px-8",children:e.jsxs(j,{className:"shadow-lg",children:[e.jsx(v,{className:"bg-white dark:bg-gray-800 border-b",children:e.jsxs(g,{className:"text-2xl flex items-center gap-3",children:[e.jsx(p,{className:"h-6 w-6"}),"Content Preview"]})}),e.jsx(b,{className:"p-0",children:e.jsx("div",{className:"bg-white dark:bg-gray-900",children:e.jsx(f,{content:x,versionNumber:s.current_version,showControls:!1})})})]})})]})}export{y as default}; 2//# sourceMappingURL=PublicContentView-De3RIqkd.js.map
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.