(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[278],{7755:function(e,l,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/suche",function(){return s(8739)}])},5966:function(e,l,s){"use strict";s.d(l,{r:function(){return WebsiteSEO}});var n=s(2322),t=s(9008),i=s.n(t),a=s(9762);let WebsiteSEO=e=>{let{seo:l}=e,{title:s="Hessen Kassel Heritage",description:t,og_image:c,og_title:r,og_description:o,twitter_description:x,twitter_title:u,twitter_image:d}=l;return l?(0,n.jsxs)(i(),{children:[(0,n.jsx)("link",{rel:"icon",href:"/icons/favicon.ico"}),(0,n.jsx)("link",{rel:"icon",type:"image/png",sizes:"16x16",href:"/icons/favicon-16x16.png"}),(0,n.jsx)("link",{rel:"icon",type:"image/png",sizes:"32x32",href:"/icons/favicon-32x32.png"}),(0,n.jsx)("link",{rel:"manifest",href:"/icons/site.webmanifest"}),(0,n.jsx)("link",{rel:"apple-touch-icon",href:"/icons/apple-touch-icon.png"}),(0,n.jsx)("link",{rel:"icon",type:"image/png",sizes:"192x192",href:"/icons/android-chrome-192x192.png"}),(0,n.jsx)("link",{rel:"icon",type:"image/png",sizes:"512x512",href:"/icons/android-chrome-512x512.png"}),(0,n.jsx)("meta",{name:"theme-color",content:"#FAFAFA"}),(0,n.jsx)("meta",{name:"msapplication-TileColor",content:"#FAFAFA"}),(0,n.jsx)("meta",{name:"msapplication-navbutton-color",content:"#FAFAFA"}),(0,n.jsx)("meta",{name:"apple-mobile-web-app-status-bar-style",content:"#FAFAFA"}),(0,n.jsx)("title",{children:s}),(0,n.jsx)("meta",{name:"description",content:t}),(0,n.jsx)("meta",{property:"og:title",content:r||s}),(0,n.jsx)("meta",{property:"og:description",content:o||t}),(0,n.jsx)("meta",{property:"og:image",content:(0,a.Y$)(c||d,null,"1280x0")}),(0,n.jsx)("meta",{property:"og:type",content:"website"}),(0,n.jsx)("meta",{name:"twitter:card",content:"summary_large_image"}),(0,n.jsx)("meta",{name:"twitter:title",content:u||r||s}),(0,n.jsx)("meta",{name:"twitter:description",content:x||o||t}),(0,n.jsx)("meta",{name:"twitter:image",content:(0,a.Y$)(d||c,null,"1280x0")})]}):null}},3481:function(e,l,s){"use strict";s.d(l,{Z:function(){return SearchPage}});var n=s(2322),t=s(9036),i=s(1163),a=s(2784),c=s(2530),r=s(1),o=s(9520),x=s(7951),u=s(5675),d=s.n(u),h=s(6979);let SearchResultsSectionItem=e=>{var l,s,t,i,a,o,x,u;let{result:p}=e,m=p.full_slug.includes("standort"),{name:f}=p,{t:g}=(0,c.$G)("common");return(0,n.jsx)("div",{className:"text-20 w-full py-[30px]",children:(0,n.jsxs)("div",{className:" flex w-full flex-col space-y-[20px] lg:flex-row lg:space-x-[30px] lg:space-y-0",children:[(null===(l=p.content.thumbnail)||void 0===l?void 0:l.filename)&&(0,n.jsx)("div",{className:"relative flex aspect-[4/3] h-full w-full lg:w-96",children:(0,n.jsx)(d(),{src:null===(s=p.content.thumbnail)||void 0===s?void 0:s.filename,fill:!0,sizes:"(max-width: 768px) 768px,",className:"rounded-base h-full w-full object-cover object-center",alt:(null===(t=p.content.thumbnail)||void 0===t?void 0:t.filename)||f})}),m?(0,n.jsxs)("div",{className:"flex flex-col space-y-[10px]",children:[(0,n.jsx)("span",{children:g("location")}),(0,n.jsx)(h.sg,{item:p,children:(0,n.jsxs)(r.s,{level:1,children:[(0,n.jsx)("strong",{children:f}),(0,n.jsx)("br",{}),(0,n.jsx)("span",{className:"font-normal",children:null===(i=p.content)||void 0===i?void 0:i.subTitle})]})})]}):(0,n.jsxs)("div",{className:"flex w-full flex-col space-y-[10px]",children:[(0,n.jsx)(r.s,{level:2,children:(0,n.jsxs)("p",{className:"flex w-full space-x-[10px]",children:[(0,n.jsx)("strong",{className:"w-full",children:(0,n.jsx)("u",{children:(0,n.jsx)(h.pR,{item:p})})}),(0,n.jsx)("i",{className:"fa-light fa-link"})]})}),(null===(a=p.content)||void 0===a?void 0:a.subTitle)&&(0,n.jsx)("p",{children:null===(o=p.content)||void 0===o?void 0:o.subTitle}),(null===(x=p.content)||void 0===x?void 0:x.category)&&(0,n.jsxs)("p",{children:[(0,n.jsx)("strong",{children:null===(u=p.content)||void 0===u?void 0:u.category}),(0,n.jsx)("br",{})]})]})]})})},SearchResultsSection=e=>{let{results:l}=e,{t:s}=(0,c.$G)("common");return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(r.s,{level:1,children:(0,n.jsx)("strong",{children:s("Results")})}),(0,n.jsx)("div",{className:"flex w-full flex-col divide-y divide-black border-t border-black",children:l.map((e,l)=>(0,n.jsx)(SearchResultsSectionItem,{result:e},"searchitem-".concat(l)))})]})};var p=s(8253),m=s(5966),f=s(8309);let SearchPage=e=>{let{navigation:l,footer:s,seo:u}=e,[d,h]=(0,a.useState)(""),[g,j]=(0,a.useState)(null),[v,b]=(0,a.useState)(null),{locale:w}=(0,i.useRouter)(),{t:y}=(0,c.$G)("common"),N={version:"published",language:w,search_term:d,starts_with:"webseite/",filter_query:{component:{in:"WebsitePage,WebsiteExhibitionPage"}}};return(0,a.useEffect)(()=>{d.length>4&&async function(){let e=(0,t.bS)(),{data:l}=await e.get("cdn/stories/",N);b(l.stories)}()},[d]),(0,a.useEffect)(()=>{let e=null==v?void 0:v.filter(e=>!e.name.includes("Webseite Social Media")),l=null==e?void 0:e.sort((e,l)=>e.full_slug.includes("veranstaltungen")?1:l.full_slug.includes("veranstaltungen")||e.full_slug.includes("standort")?-1:l.full_slug.includes("standort")?1:0);l&&j([...l])},[v]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(m.r,{seo:u}),(0,n.jsx)(p.Q,{}),(0,n.jsx)(x.I,{navigation:l,footer:s,children:(0,n.jsxs)("div",{className:"grid w-full gap-[16px] lg:grid-cols-12 lg:gap-[30px]",children:[(0,n.jsx)("div",{className:"lg:text-20 text-14 flex flex-col space-y-[30px] lg:col-span-4 lg:space-y-[120px]",children:(0,n.jsxs)("div",{className:"flex flex-col space-y-[20px] lg:space-y-[30px]",children:[(0,n.jsx)(r.s,{level:1,children:(0,n.jsx)("strong",{children:y("search")})}),(0,n.jsxs)("form",{id:"search",role:"search","aria-label":y("ariaSearchInput"),className:"flex space-x-[10px] text-[16px]",onKeyDown:e=>{"Enter"===e.key&&e.preventDefault()},children:[(0,n.jsxs)("label",{htmlFor:"search",className:"sr-only",children:[y("search")," "]}),(0,n.jsx)(o.I,{placeholder:y("searchTerm"),variant:"border",type:"search",onKeyPress:e=>{e.preventDefault(),h(e.target.value)},onChange:e=>{h(e.target.value)}}),(0,n.jsx)(f.k,{type:"submit",variant:"borderInvert",onClick:e=>{e.preventDefault(),h(d)},children:y("search")})]}),d.length>=4&&(null==g?void 0:g.length)?(0,n.jsxs)("p",{className:"w-full whitespace-pre-line md:w-72",children:[y("searchAfter")," ",(0,n.jsxs)("strong",{children:[" ",d]})," ",y("gave")," ",g.length," ",y("hits"),"."]}):null]})}),(0,n.jsx)("div",{className:"relative flex w-full flex-col space-y-[20px] lg:col-span-8 lg:space-y-[30px]",children:d.length>=4?(0,n.jsx)(n.Fragment,{children:(null==g?void 0:g.length)?(0,n.jsx)(SearchResultsSection,{results:g}):(0,n.jsx)(r.s,{level:1,children:y("noResults")})}):(0,n.jsx)(r.s,{level:1,children:(0,n.jsx)("strong",{children:y("fillInSearchTerm")})})})]})})]})}},8739:function(e,l,s){"use strict";s.r(l),s.d(l,{__N_SSG:function(){return r}});var n=s(2322),t=s(2784),i=s(3481),a=s(1433),c=s(5966),r=!0;l.default=e=>{let{navigation:l,footer:s,seo:r}=e,[o,x]=(0,t.useState)(!1);return((0,t.useEffect)(()=>(a.kN.setState({intlRoutes:{de:"suche",en:"/search"},intlNames:{de:"Suche",en:"Search"}}),x(!0),()=>{a.kN.setState({intlRoutes:null,intlNames:null}),x(!1)}),[]),o)?(0,n.jsx)(i.Z,{navigation:l,footer:s,seo:r}):(0,n.jsx)(c.r,{seo:r})}}},function(e){e.O(0,[774,888,179],function(){return e(e.s=7755)}),_N_E=e.O()}]);