1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[603],{8266:function(e,i,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/search",function(){return r(34908)}])},34908:function(e,i,r){"use strict";r.r(i),r.d(i,{__N_SSG:function(){return A},default:function(){return B}});var l=r(85893),n=r(60256),t=r(63426),s=r(66825),a=r(36031),o=r(98368),d=r(5943),c=r(1993),m=r(24894),p=r(14141);let u=p.ZP.div.withConfig({componentId:"sc-1b7c643c-0"})(["padding-top:16.8rem;position:relative;","{position:relative;}@media ","{padding-top:calc(16.8rem + ",");}@media ","{padding-top:13rem;}","{@media ","{padding:0;}}.responsiveGrid{max-height:calc(100vh - "," - 16.8vh);overflow:hidden;overflow-y:auto;min-width:45rem;margin-left:",";","{margin-right:",";width:100%;@media ","{margin-right:0px;}}","{width:calc(100% - ",");@media ","{width:100%;grid-column:span 2;&:nth-of-type(4n + 3){display:none;@media (max-width:550px){display:block;}}}@media (max-width:550px){grid-column:span 1;}}@media ","{padding:0 ",";max-height:none;overflow:visible;overflow-y:auto;display:grid;grid-template-columns:repeat(2,1fr);gap:0 ",";justify-content:space-between;margin-left:0;","{grid-column:span 2;}}@media (max-width:550px){z-index:1;margin-top:calc(100dvh - 18rem - 3.6rem);padding:0 ",";padding-top:",";background-color:",";min-width:unset;width:100%;grid-template-columns:1fr;","{grid-column:span 1;}&::before{content:'';position:absolute;top:1.6rem;right:calc(50% - (3.6rem / 2));display:inline-block;width:3.6rem;height:0.8rem;background-color:",";border-radius:99rem;}}}"],a.G,c.mq.desktopSmall,m.eL.tablet,c.mq.mobile,t.P,c.mq.desktopSmall,m.eL.desktop,c.W0.small,n.Sn,c.W0.small,c.mq.desktopSmall,s.I,c.W0.small,c.mq.desktopSmall,c.mq.desktopSmall,c.W0.medium,c.W0.small,n.Sn,c.W0.small,c.W0.medium,c.O9.grey25,n.Sn,c.O9.coolGrey100),x=p.ZP.div.withConfig({componentId:"sc-1b7c643c-1"})(["position:absolute;top:0;width:100vw;height:100vh;display:flex;justify-content:center;align-items:center;","{background-color:",";padding:",";}"],o.a,c.O9.grey25,c.W0.small),h=p.ZP.div.withConfig({componentId:"sc-1b7c643c-2"})(["","{font-weight:600;}"],d.q);var g=r(78567),j=r(12357),v=r(97323),f=r(21166),k=r(5580),w=r(68558),y=r(68236),b=r(78262),S=r(92631),z=r(83772),P=r(93480),C=r(1263),_=r(67294),T=r(23812),G=r(17023),N=r(35806),W=r(76951);let q=p.ZP.div.withConfig({componentId:"sc-41ae7f1e-0"})(["position:fixed;z-index:2;top:calc("," + (4rem * 2) + (1.2rem * 2));width:100%;pointer-events:none;","{display:flex;justify-content:flex-end;}","{max-width:12.8rem;pointer-events:all;}@media ","{top:calc("," + (4rem * 3) + (1.6rem * 2));}@media ","{top:calc("," + (4rem * 3) + 0.8rem);}@media ","{display:none;top:calc("," + (4rem * 2.5) + 1.2rem);","{max-width:unset;}}"],m.eL.desktop,t.P,W.nx,c.mq.desktopSmall,m.eL.desktop,c.mq.tablet,m.eL.desktop,c.mq.mobile,m.eL.desktop,W.nx);var D=r(47797);let L=e=>{let{sortingOptions:i,setSortingOptions:r,currentSorting:n}=e;return(0,l.jsx)(q,{children:(0,l.jsx)(g.W,{children:(0,l.jsx)(D.b,{title:"Sortering",children:(0,l.jsx)(N.P,{checkbox:!1,single:!0,selectedValues:n,setValues:r,options:i})})})})},O=[{title:"Nyeste f\xf8rst",value:0},{title:"\xc6ldste f\xf8rst",value:1},{title:"Billigst",value:2},{title:"Dyreste",value:3}],E=[(e,i)=>new Date(e.updated).getTime()-new Date(i.updated).getTime(),(e,i)=>new Date(i.updated).getTime()-new Date(e.updated).getTime(),(e,i)=>{var r,l;return(null!==(r=null==e?void 0:e.rent)&&void 0!==r?r:0)-(null!==(l=null==i?void 0:i.rent)&&void 0!==l?l:0)},(e,i)=>{var r,l;return(null!==(r=null==i?void 0:i.rent)&&void 0!==r?r:0)-(null!==(l=null==e?void 0:e.rent)&&void 0!==l?l:0)}],F=e=>{let{lang:i}=e,[r,n]=(0,_.useState)(),{properties:t,error:s,isLoading:a,hasMore:o,loadMore:d}=(0,f.l)({itemsPerPage:0,filters:r}),c=(0,_.useRef)(),[m,p]=(0,_.useState)(!1),[N,W]=(0,_.useState)([O[0]]),[q,D]=(0,_.useState)(0);return(0,_.useEffect)(()=>{t.length||a?(c.current&&clearTimeout(c.current),p(!1)):(c.current&&clearTimeout(c.current),c.current=setTimeout(()=>{p(!0)},1e3))},[t,a]),(0,_.useEffect)(()=>{var e;"number"==typeof(null===(e=N[0])||void 0===e?void 0:e.value)&&D(N[0].value)},[N]),(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(G.T,{color:"grey25"}),(0,l.jsx)(T.s,{filters:r,setFilters:n}),(0,l.jsx)(L,{sortingOptions:O,setSortingOptions:W,currentSorting:N}),(0,l.jsx)(g.W,{children:a&&(0,l.jsx)(v.r,{columns:12,gap:"small",children:(0,l.jsx)(v.P,{span:{column:4},children:(0,l.jsx)(y.k,{direction:"column",gap:"small",children:[...Array(10)].map((e,i)=>(0,l.jsx)(b.O,{type:"PropertyCardRow"},i))})})})}),(0,l.jsxs)(u,{children:[(0,l.jsxs)(y.k,{direction:"row",responsive:{desktopSmall:{direction:"column-reverse",gap:"small"}},children:[(0,l.jsxs)(y.k,{direction:"column",className:"responsiveGrid",gap:"small",children:[t.sort(E[q]).map(e=>{let{id:i}=e;return(0,l.jsxs)(_.Fragment,{children:[(0,l.jsx)(k.J,{property:e,layout:"row"}),(0,l.jsx)(j.i,{size:"xxSmall",border:!0,borderPosition:"middle",borderColor:"coolGrey100"})]},i)}),o&&(0,l.jsx)(w.z,{handleClick:()=>{d()},children:"Load more"})]}),(0,l.jsx)(C.Gi,{children:(0,l.jsx)(P.D,{properties:t,cluster:!0,isLoading:a})})]}),(0,l.jsx)(j.i,{size:"small"})]}),m||s?(0,l.jsx)(x,{children:(0,l.jsx)(v.r,{columns:12,gap:"xSmall",children:(0,l.jsx)(v.P,{place:{column:[6,9]},responsive:{desktopSmall:{place:{column:[5,10]}},mobile:{place:{column:[2,12]}}},children:(0,l.jsxs)(y.k,{justify:"center",direction:"column",children:[(0,l.jsx)(S.J,{icon:"face-frown",size:"4x"}),(0,l.jsx)(j.i,{size:"small"}),(0,l.jsx)(h,{children:(0,l.jsx)(z.x,{size:"bodySansSmall",noMargin:!0,children:"Der var desv\xe6rre ikke noget der matchede dine s\xf8gekriterier..."})}),(0,l.jsx)(z.x,{size:"bodySansSmall",children:"Pr\xf8v at justere dine s\xf8gekriterier for at f\xe5 flere resultater."}),(0,l.jsx)(w.z,{handleClick:()=>{n(null)},children:"Nulstil filtre"})]})})})}):null]})};
1var I=r(91738),J=r(62158),R=r(42225),Z=r(84090);let M=e=>{let{lang:i}=e,[r,n]=(0,_.useContext)(R.I),{vacantPremisesFilter:t}=r,{properties:s,error:a,isLoading:o,hasMore:d,loadMore:c}=(0,I.C)({paginate:!0,filters:t});return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(G.T,{color:"grey25"}),(0,l.jsx)(J.M,{isSearchResult:!0}),o&&(0,l.jsxs)(u,{children:[(0,l.jsx)(y.k,{direction:"row",responsive:{desktopSmall:{direction:"column-reverse",gap:"small"}},children:(0,l.jsx)(y.k,{direction:"column",className:"responsiveGrid",gap:"small",children:[...Array(8)].map((e,i)=>(0,l.jsx)(b.O,{type:"PropertyCardRow"},i))})}),(0,l.jsx)(C.Gi,{})]}),!o&&!a&&s&&s[0]?(0,l.jsx)(u,{children:(0,l.jsxs)(y.k,{direction:"row",responsive:{desktopSmall:{direction:"column-reverse",gap:"small"}},children:[(0,l.jsx)(y.k,{direction:"column",className:"responsiveGrid",children:(0,l.jsxs)(l.Fragment,{children:[s.map((e,i)=>{let{id:r}=e,n=0===i;return(0,l.jsxs)(_.Fragment,{children:[(0,l.jsx)(j.i,{size:n?"small":"large",border:!0,borderColor:"coolGrey100",borderPosition:n?"top":"middle"}),(0,l.jsx)(k.J,{property:e,layout:"row"})]},r)}),d&&(0,l.jsx)(w.z,{handleClick:()=>{c()},children:"Ladda fler"})]})}),(0,l.jsx)(C.Gi,{children:(0,l.jsx)(P.D,{properties:s})})]})}):(0,l.jsx)(u,{children:(0,l.jsx)(g.W,{children:(0,l.jsx)(v.r,{columns:13,gap:"xSmall",children:(0,l.jsx)(v.P,{place:{column:[6,9]},responsive:{desktopSmall:{place:{column:[5,10]}},mobile:{place:{column:[2,13]}}},children:(0,l.jsxs)(y.k,{justify:"center",direction:"column",children:[(0,l.jsx)(S.J,{icon:"face-frown",size:"4x"}),(0,l.jsx)(j.i,{size:"large"}),(0,l.jsx)(h,{children:(0,l.jsx)(z.x,{size:"bodySansSmall",noMargin:!0,children:"Tyv\xe4rr s\xe5 har vi inga lokaler som matchar din s\xf6kning."})}),(0,l.jsx)(j.i,{size:"xxSmall"}),(0,l.jsx)(z.x,{size:"bodySansSmall",children:"Tyv\xe4rr s\xe5 hade vi inga lokaler som matchade dina s\xf6kkriterier. G\xf6r en bredare s\xf6kning genom att ta bort en eller flera av de valda filterna eller zooma ut p\xe5 kartan. Du kan ocks\xe5 kontakta v\xe5ra r\xe5dgivare s\xe5 kan vi hj\xe4lpa dig med dina specifika behov. Till v\xe5r kontaktsida"}),(0,l.jsx)(w.z,{handleClick:()=>{n((0,Z.aw)())},children:"Byt filtrering"})]})})})})})]})};var A=!0,B=e=>(null==e?void 0:e.template)==="vacant-premises"?(0,l.jsx)(M,{...e}):(0,l.jsx)(F,{...e})}},function(e){e.O(0,[332,703,72,158,480,888,774,179],function(){return e(e.s=8266)}),_N_E=e.O()}]);
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.