1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9621],{8020:function(e,t,i){"use strict";i.r(t);var s=i(5893),a=i(7294),r=i(5820),n=i(2451),o=i(5517),l=i(3909),c=i(2007),d=i(727),u=i(4298),m=i.n(u);let h=e=>{let{posts:t,loading:i,postListId:u,render:h}=e,p=(0,a.useMemo)(()=>null!=h?h:void 0,[h]);return t&&0!==t.length||i?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(r.M,{children:i&&(0,s.jsx)(n.E.div,{initial:"initial",animate:"animate",exit:"initial",transition:{duration:.2},variants:o.I,className:"z-40 will-change-opacity",children:(0,s.jsx)(c.Z,{children:(0,s.jsx)(d.Z,{className:"w-10 h-10 text-secondaryColor-600 fill-accentColor-500"})})},"loading")}),(0,s.jsx)(r.M,{mode:"wait",initial:!1,children:!i&&(0,s.jsx)(n.E.div,{className:"grid gap-10 gap-y-12 md:grid-cols-2",initial:"initial",animate:"animate",exit:"initial",transition:{duration:.2},variants:o.I,children:null==t?void 0:t.map((e,i)=>(0,s.jsxs)(a.Fragment,{children:[(0,s.jsx)("article",{children:p?(0,s.jsx)(p,{title:e.name,url:e.url,image:e.image,categories:e.categories,publishDate:e.date,isRestricted:e.isRestricted}):(0,s.jsx)(l.Z,{title:e.name,url:e.url,image:e.image,categories:e.categories,publishDate:e.date,isRestricted:e.isRestricted})}),0===i&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{id:"rtbuzz_topmobile"}),(0,s.jsx)(m(),{id:"topmobilescript",dangerouslySetInnerHTML:{__html:'window.RTBuzz.cmd.push("topmobile");'}})]}),1===i&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{id:"rtbuzz_middlemobile"}),(0,s.jsx)(m(),{id:"middlemobilescript",dangerouslySetInnerHTML:{__html:'window.RTBuzz.cmd.push("middlemobile");'}})]}),i===t.length/2&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{id:"rtbuzz_bottommobile"}),(0,s.jsx)(m(),{id:"bottommobilescript",dangerouslySetInnerHTML:{__html:'window.RTBuzz.cmd.push("bottommobile");'}})]})]},e.slug))},u)})]}):(0,s.jsx)("div",{children:"Nessun post trovato"})};t.default=h},3909:function(e,t,i){"use strict";var s=i(5893),a=i(5675),r=i.n(a),n=i(7294),o=i(6909),l=i(1662),c=i(9663),d=i(3129),u=(i(6005),i(4991)),m=i.n(u);i(223);let h=e=>{let{image:t,title:i,url:a,excerpt:u,categories:h,publishDate:p,isRestricted:x}=e,g=((0,n.useContext)(c.Z),"".concat(o.n.images,"/radiosei-logo.png")),v=h&&h[0],f=[m().article,"relative",e.className],b=!!p&&"".concat((0,l.p6)(p,"it",{day:"2-digit",month:"long",year:"numeric"}).localeString,", ").concat((0,l.p6)(p,"it",{hour:"2-digit",minute:"2-digit"}).localeString);return(0,s.jsxs)("div",{className:f.join(" "),children:[!1,(0,s.jsxs)("a",{href:a||"",className:"".concat(m().link," min-h-[350px] flex gap-5 rounded-xl"),title:i,children:[t?(0,s.jsx)(r(),{src:t,width:800,height:400,alt:i,className:"object-cover"}):(0,s.jsx)(r(),{src:g,width:800,height:400,alt:i,className:"object-contain p-[100px]"}),(0,s.jsxs)("div",{className:m().caption,children:[(0,s.jsx)("span",{children:v&&v.name}),(0,s.jsx)("div",{className:"".concat(m().title," font-bold text-[1.5rem]"),children:i}),b&&(0,s.jsxs)("span",{className:"flex items-center gap-2 text-sm mt-4",children:[(0,s.jsx)(d.default,{})," ",b]})]}),e.children]})]})};t.Z=h},5921:function(e,t,i){"use strict";var s=i(5893),a=i(7294);let r=(0,a.forwardRef)((e,t)=>(0,s.jsx)("svg",{ref:t,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",strokeMiterlimit:10,...e}));r.displayName="BaseIcon",t.Z=r},3129:function(e,t,i){"use strict";i.r(t);var s=i(5893),a=i(5921);let r=e=>{let t=["h-6","w-6","icon","calendar__icon",e.className];return(0,s.jsx)(a.Z,{...e,className:t.join(" "),children:(0,s.jsx)("path",{d:"M6.75 3v2.25M17.25 3v2.25M3 18.75V7.5a2.25 2.25 0 012.25-2.25h13.5A2.25 2.25 0 0121 7.5v11.25m-18 0A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75m-18 0v-7.5A2.25 2.25 0 015.25 9h13.5A2.25 2.25 0 0121 11.25v7.5"})})};t.default=r},6005:function(e,t,i){"use strict";i.d(t,{Z:function(){return E}});var s=i(5893),a=i(259),r=i(2053),n=i(8567),o=i(4833);class l extends n.Z{constructor(e){super(e),this.actions=e.actions,this.type=o.Z.MODAL,this.preventScroll=void 0===e.preventScroll||e.preventScroll,this.backdrop=!("backdrop"in e)||e.backdrop,this.autoClose="autoClose"in e&&e.autoClose}}var c=i(7294);let d=async e=>{let t=await fetch("/api/auth/login",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}),i=await t.json();return i},u=async e=>{let t=await fetch("/api/auth/signup",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}),i=await t.json();return i};var m=i(1224),h=i(465),p=i(132),x=i(1662),g=i(1773),v=i(6364),f=i(3688),b=i(2007),j=i(727),w=i(9663),N=i(876);let y=e=>{let{onLogin:t,onSignUp:i}=e,[r,n]=(0,c.useState)(!0),[o,l]=(0,c.useState)(g.Y),{executeRecaptcha:y}=(0,a.xX)(),C=(0,c.useContext)(N.Z),I=(0,c.useContext)(w.Z),E=(0,p.Z)(),S={...e},_=["flex","flex-col","gap-10","mb-10",S.className],{submitting:k}=o,A=r?"Accesso avvenuto correttamente.":"Registrazione avvenuta correttamente!";k&&_.push("loading"),delete S.onLogin,delete S.onSignUp;let{value:O,isValid:T,isEmpty:R,hasError:Z,inputChangeHandler:P,inputBlurHandler:M,inputSubmit:z,inputReset:L}=(0,h.Z)(r?x.UE:x.vV),{value:D,isValid:B,isEmpty:F,hasError:U,inputChangeHandler:H,inputBlurHandler:G,inputSubmit:W,inputReset:K}=(0,h.Z)(r?x.UE:x.OU),V=null,q=null,Y=null;o.hasError&&o.feedback?V=(0,s.jsx)("p",{className:"my-2 error text-red-600",children:o.feedback}):!o.hasError&&o.submitted&&(V=(0,s.jsx)("p",{className:"my-2 text-green-600",children:o.feedback}
1)),Z&&!R&&(q="Inserisci un indirizzo mail valido."),Z&&R&&(q=r?"Inserisci il tuo username o la tua mail":"Inserisci l'indirizzo mail"),r||B||F||(Y="Inserisci una password pi\xf9 sicura."),U&&F&&(Y="Inserisci la tua password"),(0,c.useEffect)(()=>{l(e=>({...g.Y,submitted:e.submitted,feedback:e.feedback}))},[r]);let J=async e=>{if(e.preventDefault(),void 0===y){l(e=>({...e,hasError:!0,feedback:"Impossibile verificare il reCaptcha. Per favore, riprova pi\xf9 tardi."}));return}if(z(),W(),R||!T||F||!B){l({submitted:!1,submitting:!1,hasError:!0});return}l(e=>({...e,submitted:!1,submitting:!0,feedback:null}));let s=await y(r?"userLogin":"userSignUp"),a=null;try{let o={email:O,password:D,gReCaptchaToken:s};if(!(null==(a=r?await d(o):await u(o))?void 0:a.ok)){var c;switch(null==a?void 0:null===(c=a.error)||void 0===c?void 0:c.code){case m.Ad.EMPTY_EMAIL:throw Error("Per favore, inserisci il tuo indirizzo email.");case m.Ad.EXISTING_NAME:case m.Ad.EXISTING_EMAIL:throw Error("Questa mail \xe8 gi\xe0 registrata.");case m.Ad.WRONG_EMAIL:throw Error("Non esiste alcun account con l'username o la mail inserita.");case m.Ad.EMPTY_PASSWORD:throw Error("Per favore, inserisci la tua password.");case m.Ad.WRONG_PASSWORD:throw Error("Password errata.");default:throw Error("Si \xe8 verificato un errore. Per favore, riprova pi\xf9 tardi.")}}}catch(p){let h=p.message||"Si \xe8 verificato un errore durante l'invio del modulo.";return l({submitted:!1,submitting:!1,hasError:!0,feedback:h})}if(l({submitted:!0,submitting:!1,hasError:!1,feedback:A}),!r)return E("User sign up"),"function"==typeof i&&i(),n(!0);if(a.message.login.authToken){let x=new Date(new Date().getTime()+3e5);C.logIn(a.message.login.authToken,x.toISOString()),E("User login")}"function"==typeof t&&t(),I.hidePopUp()};return(0,s.jsxs)("div",{className:"relative",children:[(0,s.jsx)("h5",{className:"my-5 mb-10 text-2xl",children:r?"Accedi":"Registrati"}),(0,s.jsxs)("form",{...S,className:_.join(" "),onSubmit:J,children:[(0,s.jsx)(v.Z,{id:"userLogin",label:"Email",hiddenLabel:!0,error:q,attr:{type:r?"text":"email",placeholder:r?"Username o email":"La tua email",required:!0,value:O,onChange:P,onBlur:M}}),(0,s.jsx)(v.Z,{id:"userPassword",label:"Password",hiddenLabel:!0,error:Y,attr:{type:"password",placeholder:"La tua password",required:!0,value:D,onChange:H,onBlur:G},feedback:r?void 0:"Inserisci una password sicura. ( almeno 10 caratteri )"}),(0,s.jsx)(f.Z,{disabled:k,children:r?"Accedi":"Registrati"}),V]}),(0,s.jsxs)("p",{className:"text-center",children:[r&&(0,s.jsxs)(s.Fragment,{children:["Non hai ancora un account? ",(0,s.jsx)("button",{onClick:()=>n(!1),children:"Registrati"})]}),!r&&(0,s.jsxs)(s.Fragment,{children:["Hai gi\xe0 un account? ",(0,s.jsx)("button",{onClick:()=>n(!0),children:"Accedi"})]})]}),k&&(0,s.jsx)(b.Z,{children:(0,s.jsx)(j.Z,{className:"w-10 h-10 text-secondaryColor-600 fill-accentColor-500"})})]})},C=(0,s.jsx)(s.Fragment,{children:r.i.reCaptcha.siteKey?(0,s.jsx)(a.pm,{reCaptchaKey:r.i.reCaptcha.siteKey,scriptProps:{async:!1,defer:!0,appendTo:"head",nonce:void 0},children:(0,s.jsx)(y,{})}):(0,s.jsx)(y,{})}),I=new l({message:C,className:"text-center",position:{mobile:"bottom"}});var E=I},5517:function(e,t,i){"use strict";i.d(t,{I:function(){return s}});let s={initial:{opacity:0}
1,animate:{opacity:1}}},8567:function(e,t,i){"use strict";i.d(t,{E:function(){return a}});var s,a,r=i(4833);(s=a||(a={})).INFO="info",s.PENDING="pending",s.SUCCESS="success",s.WARNING="warning",s.ERROR="error";class n extends r.C{constructor(e){super(e),this.title=e.title,this.message=e.message,this.status=e.status,this.type=r.Z.NOTIFICATION,this.preventScroll=!1}}t.Z=n},4833:function(e,t,i){"use strict";var s,a;i.d(t,{Z:function(){return s}}),(a=s||(s={})).NOTIFICATION="notification",a.MODAL="modal",a.POPOVER="popover",a.SIDEBAR="sidebar",t.C=class{constructor(e){this.id=Math.random().toString(),this.autoClose=e.autoClose,this.dismissible=e.dismissible,this.children=e.children,this.type=e.type||s.NOTIFICATION,this.preventScroll=void 0===e.preventScroll||e.preventScroll,this.position=e.position,this.dismissText=e.dismissText||"Dismiss",this.className=e.className,this.animationDuration=void 0!==e.animationDuration?e.animationDuration:300}}},876:function(e,t,i){"use strict";var s=i(7294);let a=(0,s.createContext)({isLoggedIn:!1,logIn(e,t){},logOut(){}});t.Z=a},9663:function(e,t,i){"use strict";var s=i(7294);let a=(0,s.createContext)({popup:null,showPopUp(e){},hidePopUp(){}});t.Z=a},4991:function(e){e.exports={article:"OverlayPostCard_article__ZJ0T3",link:"OverlayPostCard_link__ByR0T",caption:"OverlayPostCard_caption__9fL9I",title:"OverlayPostCard_title__MlBKK"}},223:function(e){e.exports={requiresAuthOverlay:"PostCard_requiresAuthOverlay__sInMv"}}}]);
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.