PageSourceSearch

https://wachmacher.at/assets/BlogPost-GCkiCDCC.js

js wachmacher.at collected 2026-10-04 01:36:23 UTC 4,524 bytes, 3 lines download raw bytes

1import{k as f,r as d,j as e,L as m,m as p,i as g,s as y}from"./index-AxlpuH9o.js";import{S as b}from"./SEOHead-BAfTHEVt.js";import{A as u}from"./arrow-left-B9dAPycI.js";import{C as j}from"./calendar-Do8tEmV5.js";const x=[.16,1,.3,1],N=n=>{const s=n.split(`
2`),a=[];let t=!1;for(const r of s){const i=r.trim();if(!i){t&&(a.push("</ul>"),t=!1);continue}if(i==="---"){t&&(a.push("</ul>"),t=!1),a.push('<hr class="my-8 border-border" />');continue}if(i.startsWith("### "))t&&(a.push("</ul>"),t=!1),a.push(`<h3 class="font-display text-xl font-bold text-primary mt-8 mb-3">${l(i.slice(4))}</h3>`);else if(i.startsWith("## "))t&&(a.push("</ul>"),t=!1),a.push(`<h2 class="font-display text-2xl font-bold text-primary mt-10 mb-4">${l(i.slice(3))}</h2>`);else if(/^[\-\*]\s/.test(i)||/^\d+\.\s/.test(i)){t||(a.push('<ul class="list-disc pl-6 space-y-2 my-4">'),t=!0);const o=i.replace(/^[\-\*]\s|^\d+\.\s/,"");a.push(`<li class="font-body text-muted-foreground leading-relaxed">${l(o)}</li>`)}else t&&(a.push("</ul>"),t=!1),a.push(`<p class="font-body text-muted-foreground leading-relaxed mb-4">${l(i)}</p>`)}return t&&a.push("</ul>"),a.join(`
3`)},l=n=>n.replace(/\[(.+?)\]\((.+?)\)/g,(s,a,t)=>{const r=t.startsWith("http");return`<a href="${t}" class="text-vitality underline underline-offset-2 hover:text-vitality/80 transition-colors"${r?' target="_blank" rel="noopener noreferrer"':""}>${a}${r?" ↗":""}</a>`}).replace(/\*\*(.+?)\*\*/g,'<strong class="text-primary font-semibold">$1</strong>'),L=()=>{const{slug:n}=f(),[s,a]=d.useState(null),[t,r]=d.useState(!0);d.useEffect(()=>{(async()=>{const{data:c}=await y.from("blog_posts").select("*").eq("slug",n).eq("published",!0).maybeSingle();a(c),r(!1)})()},[n]);const i=h=>{const c=h.split(/\s+/).length;return Math.max(1,Math.round(c/200))};if(t)return e.jsx("div",{className:"min-h-screen bg-background flex items-center justify-center",children:e.jsx("div",{className:"animate-pulse text-muted-foreground",children:"Laden..."})});if(!s)return e.jsxs("div",{className:"min-h-screen bg-background flex flex-col items-center justify-center gap-4",children:[e.jsx("h1",{className:"font-display text-2xl font-bold text-primary",children:"Artikel nicht gefunden"}),e.jsx(m,{to:"/blog",className:"text-vitality hover:underline",children:"Zurück zum Blog"})]});const o={"@context":"https://schema.org","@type":"Article",headline:s.title,description:s.meta_description||s.excerpt,datePublished:s.published_at,author:{"@type":"Person",name:"Felix Weinzinger"},publisher:{"@type":"Person",name:"Felix Weinzinger"},url:`https://wachmacher.at/blog/${s.slug}`};return e.jsxs("div",{className:"min-h-screen bg-background",children:[e.jsx(b,{title:`${s.title} | Der Wachmacher`,description:s.meta_description||s.excerpt,canonical:`/blog/${s.slug}`,ogType:"article",jsonLd:o}),e.jsxs("header",{className:"bg-midnight text-primary-foreground",children:[e.jsx("div",{className:"container mx-auto px-6 lg:px-12 py-6",children:e.jsxs(m,{to:"/blog",className:"inline-flex items-center gap-2 text-primary-foreground/60 hover:text-primary-foreground transition-colors text-sm font-body",children:[e.jsx(u,{className:"w-4 h-4"})," Alle Artikel"]})}),e.jsxs("div",{className:"container mx-auto px-6 lg:px-12 pb-16 pt-4 max-w-3xl",children:[e.jsxs(p.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.6,ease:x},className:"flex items-center gap-4 text-primary-foreground/50 text-xs font-body mb-6",children:[e.jsxs("span",{className:"flex items-center gap-1.5",children:[e.jsx(j,{className:"w-3.5 h-3.5"}),new Date(s.published_at).toLocaleDateString("de-DE",{day:"numeric",month:"long",year:"numeric"})]}),e.jsxs("span",{className:"flex items-center gap-1.5",children:[e.jsx(g,{className:"w-3.5 h-3.5"}),i(s.content)," Min. Lesezeit"]})]}),e.jsx(p.h1,{initial:{opacity:0,y:30},animate:{opacity:1,y:0},transition:{duration:.8,delay:.1,ease:x},className:"font-display text-3xl md:text-4xl lg:text-5xl font-bold leading-tight",children:s.title})]})]}),e.jsxs("main",{className:"container mx-auto px-6 lg:px-12 py-16 max-w-3xl",children:[e.jsx(p.article,{initial:{opacity:0,y:20}
3,animate:{opacity:1,y:0},transition:{duration:.6,delay:.2,ease:x},dangerouslySetInnerHTML:{__html:N(s.content)}}),e.jsx("div",{className:"mt-16 pt-8 border-t border-border",children:e.jsxs(m,{to:"/blog",className:"inline-flex items-center gap-2 text-vitality font-body font-semibold hover:gap-3 transition-all",children:[e.jsx(u,{className:"w-4 h-4"})," Alle Artikel"]})})]})]})};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.