1import{r as e,j as t}from"./vendor-react-D0h46m16.js";import{L as s}from"./legacy-article-redirect-fp3isHR7.js";import{c as r,B as n}from"./button-CykUDgWQ.js";import{D as a,a as i,b as o,c as l,d as c}from"./Footer-C-QL4pp4.js";import{D as d,a as m,b as h,c as p,d as x}from"./drawer-D20VqtXW.js";import{g as u,f as g}from"./use-search-history-Boqjf0_n.js";import{o as f}from"./altTextGenerator-DWCIDCE5.js";import{a as b,s as j,b as w,N as k,i as v,A as N,G as y,c as C,d as _,h as A}from"./whatsNew--tlXZLzZ.js";import{ar as D,l as O,H as S,as as z,a1 as E,ak as R,at as P,M as T,au as B,av as I,U as q,aw as K,ax as L}from"./vendor-icons-BbYfpdOz.js";import"./vendor-radix-D7CZeoLk.js";import"./vendor-radix-core-BVUYVtAx.js";import"./vendor-api-B4hs_cPm.js";import"./weatherTime-Y9ihW93L.js";import"./vendor-query-Dr68jqlw.js";import"./use-profile-CuRxmWYi.js";import"./ScrollToTop-BbnbJAtN.js";import"./exports-cWTammwm.js";import"./index-DqZvI2U2.js";const V={vorlesen:L,reaktion:K,autor:q,hinweis:I,google:B,kommentar:T,forum:P,spende:R,abo:E,app:z,startbildschirm:S,push:O,wetter:D};function F({quelle:s,pathname:v,eingeloggt:N,abonnent:y,marketing:C,onRegistrieren:_,onClose:A,onAngezeigt:D}){const[O]=e.useState(()=>window.innerWidth<768),[S,z]=e.useState(0),E=e.useRef(Date.now()),R=e.useRef(!1),P=e.useCallback((e,t={})=>{const r=u();r&&g({visitor_id:r,event_type:e,metadata:{version:b,quelle:s,path:v,device:O?"mobile":"desktop",...t}})},[s,v,O]);e.useEffect(()=>{D?.()},[D]),e.useEffect(()=>{P("whatsnew_view",{step:0})},[P]);const T=e.useCallback(e=>{R.current||(R.current=!0,P("whatsnew_close",{step:S,reason:e,open_ms:Date.now()-E.current}),A())},[A,S,P]),B=e=>{e<0||e>=w.length||(P("whatsnew_step",{from:S,to:e}),z(e))},I=e=>{let t=null;"ArrowRight"===e.key&&(t=S+1),"ArrowLeft"===e.key&&(t=S-1),null===t||t<0||t>=w.length||(e.preventDefault(),B(t))},q=w[S]??w[0],K=S===w.length-1,L=j(q,{eingeloggt:N,abonnent:y}),V=()=>{T("done"),f()},F=t.jsx("ul",{className:r("grid gap-4",!O&&"sm:grid-cols-2"),"aria-label":q.titel,children:L.map(e=>t.jsx(G,{punkt:e,breit:!O&&Boolean(e.breit),marketing:C,onClick:e=>P("whatsnew_click",{item:e,step:S}),onRegistrieren:()=>{T("done"),_()},onNavigiert:()=>T("done"),onCookieEinstellungen:V},e.id))}),M=t.jsxs("div",{className:"flex flex-col-reverse gap-3 border-t border-border pt-4 sm:flex-row sm:items-center sm:justify-between",children:[t.jsx("div",{className:"flex items-center gap-1.5","aria-hidden":"true",children:w.map((e,s)=>t.jsx("span",{className:r("h-2 rounded-full transition-all",s===S?"w-5 bg-primary":"w-2 bg-border")},e.id))}),t.jsxs("div",{className:"flex items-center justify-end gap-2",children:[0===S?t.jsx(n,{type:"button",variant:"ghost",size:"sm",onClick:()=>T("skip"),children:k.ueberspringen}):t.jsx(n,{type:"button",variant:"ghost",size:"sm",onClick:()=>B(S-1),children:k.zurueck}),K?t.jsx(n,{type:"button",size:"sm",onClick:()=>T("done"),children:k.fertig}):t.jsx(n,{type:"button",size:"sm",onClick:()=>B(S+1),children:k.weiter})]})]}),H=t.jsxs("div",{className:"flex items-center gap-2",children:[t.jsx("span",{className:"inline-flex h-7 w-7 items-center justify-center rounded-full bg-white ring-1 ring-border","aria-hidden":"true",children:t.jsx("img",{src:"/favicon.svg",alt:"",width:20,height:20,className:"h-5 w-5"})}),t.jsx("span",{className:"text-xs font-semibold uppercase tracking-wider text-muted-foreground","aria-live":"polite",children:k.schrittVon(S+1,w.length)})]});return O?t.jsx(d,{open:!0,onOpenChange:e=>{e||T("x")},shouldScaleBackground:!1,children:t.jsxs(m,{className:"max-h-[92dvh] overflow-hidden",onKeyDown:I,"data-testid":"whatsnew-overlay","data-step":S,children:[t.jsxs(h,{className:"text-left",children:[H,t.jsx(p,{className:"text-xl",children:q.titel}),t.jsx(x,{children:q.text})]}),t.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto overflow-x-hidden px-4 pb-2",children:F}),t.jsx("div",{className:"px-4 pb-[calc(1rem+env(safe-area-inset-bottom))] pt-1",children:M})]})}):t.jsx(a,{open:!0,onOpenChange:e=>{e||T("x")},children:t.jsxs(i,{className:"max-h-[90vh] overflow-y-auto sm:max-w-2xl",onKeyDown:I,"data-testid":"whatsnew-overlay","data-step":S,children:[t.jsxs(o,{children:[H,t.jsx(l,{className:"text-2xl",children:q.titel}),t.jsx(c,{children:q.text})]}),F,t.jsx("div",{className:"mt-2",children:M})]})})}function G({punkt:n,breit:a,marketing:i,onClick:o,onRegistrieren:l,onNavigiert:c,onCookieEinstellungen:d}){const m=V[n.icon],[h,p]=e.useState(null),x=n.aktion&&!("installieren"===n.aktion.art&&v());return t.jsxs("li",{className:r("flex gap-3",a&&"sm:col-span-2"),"data-testid":`whatsnew-${n.id}`,children:[t.jsx("span",{className:"mt-0.5 inline-flex h-10 w-10 flex-none items-center justify-center rounded-md bg-primary/10 text-primary","aria-hidden":"true",children:t.jsx(m,{className:"h-5 w-5"})}),t.jsxs("div",{className:"min-w-0",children:[t.jsx("h3",{className:"text-[15px] font-bold leading-snug",children:n.titel}),t.jsx("p",{className:"mt-0.5 text-sm text-muted-foreground",children:n.text}),n.link&&(n.link.extern?t.jsx("a",{href:n.link.href,target:"_blank",rel:"noopener noreferrer",onClick:()=>
1o(n.id),className:"mt-1 inline-block border-b border-current text-sm font-semibold text-primary",children:n.link.label}):t.jsx(s,{to:n.link.href,onClick:()=>{o(n.id),c()},className:"mt-1 inline-block border-b border-current text-sm font-semibold text-primary",children:n.link.label})),x&&n.aktion&&t.jsx("button",{type:"button",onClick:()=>{if(n.aktion)if(o(n.aktion.art),"registrieren"!==n.aktion.art){if("push"===n.aktion.art){if(!i)return void p(k.pushOhneConsent);const e=window;e.CleverPush??(e.CleverPush=[]);const t=e.CleverPush;return"function"==typeof t.triggerOptIn?void t.triggerOptIn():"function"==typeof t.push?(t.push(["triggerOptIn"]),void p(k.pushNichtVerfuegbar)):void p(k.pushNichtVerfuegbar)}if("installieren"===n.aktion.art){const e=A();if(e)return void e.prompt().catch(()=>p(k.installNichtMoeglich));if(C())return void p(k.installIos);p(_()?k.installAndroid:k.installDesktop)}}else l()},className:"mt-1 inline-block border-b border-current text-sm font-semibold text-primary",children:n.aktion.label}),h&&t.jsxs("p",{className:"mt-1 text-xs text-muted-foreground",role:"status",children:[h,h===k.pushOhneConsent&&t.jsxs(t.Fragment,{children:[" ",t.jsx("button",{type:"button",onClick:d,className:"border-b border-current font-semibold text-primary",children:k.cookieEinstellungen})]})]}),n.badges&&t.jsxs("div",{className:"mt-2 flex flex-wrap items-center gap-2",children:[t.jsx("a",{href:N,target:"_blank",rel:"noopener noreferrer",onClick:()=>o("app_ios"),"aria-label":k.appStoreAlt,children:t.jsx("img",{src:"/badges/app-store-de.svg",alt:k.appStoreAlt,width:120,height:40,className:"h-10 w-auto"})}),t.jsx("a",{href:y,target:"_blank",rel:"noopener noreferrer",onClick:()=>o("app_android"),"aria-label":k.googlePlayAlt,children:t.jsx("span",{className:"inline-flex h-10 items-center overflow-hidden",children:t.jsx("img",{src:"/badges/google-play-de.png",alt:k.googlePlayAlt,width:135,height:52,className:"h-[52px] w-auto"})})})]})]})]})}export{F 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.