(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[83],{1914:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/family",function(){return a(8902)}])},7305:function(e,t,a){"use strict";var s=a(5893),l=a(7294),n=a(4805);t.Z=e=>{let{familyListAPI:t,className:a="",bgColor:o="#FFF",onFamilyHover:i=!1,...r}=e,c=e=>{"ontouchstart"in window||document.querySelectorAll(".family-card").forEach((t,a)=>{t.getAttribute("data-store")===e&&t.classList.add("show")})},d=e=>{document.querySelectorAll(".family-card").forEach((e,t)=>{e.classList.remove("show")})},[u,m]=(0,l.useState)(!1);return(0,l.useEffect)(()=>(m("ontouchstart"in window),()=>{}),[]),(0,s.jsxs)("div",{className:"sticky max-sm:hidden top-20 z-40 max-w-5xl mx-auto flex flex-wrap mb-12 items-stretch ".concat(a),id:"family-menu",...r,children:[t.map((e,t)=>(0,s.jsxs)(n.Z,{destination:"/family/".concat(e.slug.current),onMouseEnter:()=>i&&c(e.slug.current),onMouseLeave:()=>i&&d(0),className:"group relative text-center uppercase overflow-hidden text-grayFont text-sm py-1 px-4 border border-black rounded-full",style:{backgroundColor:"".concat(o)},children:[(0,s.jsx)("div",{className:"relative z-2",children:e.title}),(0,s.jsx)("div",{className:"absolute top-0 left-0 w-full h-full z-0 ".concat(u?"opacity-100":" opacity-0 betterhover:group-hover:opacity-100"),style:{backgroundColor:e.bgColor.hex}})]},t)),[...Array((()=>{let e=t.length;return 3*Math.ceil(e/3)-e})())].map((e,t)=>(0,s.jsx)("div",{className:"relative rounded-full border border-black overflow-hidden",style:{backgroundColor:"".concat(o)},children:(0,s.jsx)("div",{className:"block w-full h-full bg-neutral-600 opacity-30"})},t))]})}},150:function(e,t,a){"use strict";var s=a(5893),l=a(7294),n=a(2353),o=a(4805),i=a(798);t.Z=e=>{let{familyListAPI:t,familyAPI:a,className:r,collapse:c=!1,onFamilyHover:d=!1,...u}=e,m=e=>{"ontouchstart"in window||document.querySelectorAll(".family-card").forEach((t,a)=>{t.getAttribute("data-store")===e&&t.classList.add("show")})},f=e=>{document.querySelectorAll(".family-card").forEach((e,t)=>{e.classList.remove("show")})},[h,x]=(0,l.useState)(!1),[v,p]=(0,l.useState)(!0),[w,b]=(0,l.useState)(!1),g=(0,l.useRef)(),j=(0,l.useRef)(),y=e=>{!g.current||g.current.contains(e.target)||w||(p(!0),document.removeEventListener("mousedown",y))},L=()=>{j.current&&(j.current.getBoundingClientRect().top-(window.innerHeight+-100)<0?(p(!1),b(!0)):(p(!0),b(!1),document.removeEventListener("mousedown",y)))};return(0,l.useEffect)(()=>(x("ontouchstart"in window),document.addEventListener("scroll",L,!1),()=>{document.removeEventListener("mousedown",y),document.removeEventListener("scroll",L,!1)}),[]),(0,s.jsx)(s.Fragment,{children:(0,n.a)("(max-width: 600px)")&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"h-1 w-full block",ref:j}),(0,s.jsx)(i.E.nav,{className:"group sticky bottom-[-2px] left-0 w-full z-40 hidden max-md:flex flex-col justify-center items-center pt-10 overflow-hidden",...u,ref:g,onClick:()=>{h&&(v?(document.addEventListener("mousedown",y),p(!1)):(document.removeEventListener("mousedown",y),p(!0)))},initial:"initial",animate:"enter",exit:"exit",variants:{initial:{y:"150%"},enter:{y:"0%",transition:{duration:2,ease:[.83,0,.17,1],delay:0}},exit:{opacity:0,transition:{duration:.5,ease:[.83,0,.17,1]}}},children:t.map((e,l)=>{if(c&&e._id!==a[0]._id||!c)return(0,s.jsxs)(o.Z,{destination:"/family/".concat(e.slug.current),onMouseEnter:()=>{d&&m(e.slug.current)},onMouseLeave:()=>{d&&f(0)},className:"group relative  text-center w-full h-full rounded-t-2xl bg-locavore pt-2 pb-7 px-2 font-bold uppercase block betterhover:hover:shadow-base last:pb-9 last:pb-9-safe transition-[transform,box-shadow,margin] duration-300 betterhover:hover:-translate-y-3 ".concat(c?"".concat(h?"".concat(v?"-mb-12 last:-mb-14 !pointer-events-none":"-mb-6 last:-mb-7"):"-mb-12 last:-mb-14 betterhover:group-hover:-mb-6  betterhover:group-hover:last:-mb-7 ".concat(w?"-mb-6 last:-mb-7":"")):"-mb-6 last:-mb-7"," "),style:{backgroundColor:e.bgColor.hex},children:[c&&t.length-1===l&&(0,s.jsx)("div",{className:"w-full betterhover:group-hover:h-0 transition-[height] ".concat(v?"h-2":" h-0")}),e.title]},l)})})]})})}},7126:function(e,t,a){"use strict";a.d(t,{Z:function(){return m}});var s=a(5893),l=a(7294),n=a(4711),o=a(8275),i=a(6139),r=e=>{let{status:t,message:a,onValidated:n,className:r="",subText:c,...d}=e,[u,m]=(0,l.useState)(!1),[f,h]=(0,l.useState)(!1),[x,v]=(0,l.useState)(null),[p,w]=(0,l.useState)("EMAIL"),b=(0,l.useRef)(null),g=()=>(b.current.blur(),m(!0),x&&x.indexOf("@")>-1&&n({EMAIL:x})),j=e=>{13===e.keyCode&&(e.preventDefault(),g())},y=null,L=()=>{clearTimeout(y),y=setTimeout(()=>{m(!1),h(!1),w("EMAIL")},4e3)};return(0,l.useEffect)(()=>{"success"===t?(h(!1),b.current.value="",w("Got it!"),L()):"error"===t?(b.current.value="",a.includes("cannot be added")?(h(!0),w("That's an invalid email.")):a.includes("is already subscribed")?w("You are already on the list!"):(h(!0),w("Error ".concat(a))),L()):"sending"===t?clearTimeout(y):(h(!1),m(!1))},[t]),(0,s.jsxs)("div",{className:"flex w-full max-w-sm max-md:max-w-lg flex-col justify-between ".concat(r),...d,children:[(0,s.jsx)("label",{className:"text-xl font-normal",children:c}),(0,s.jsxs)("div",{className:"relative mt-5 w-full border-white pb-2.5 border-b flex h-10 ".concat(u?"pointer-events-none":""),children:[(0,s.jsx)("input",{className:"w-full text-sm tracking-wide placeholder-white outline-none bg-transparent !select-all ".concat(f?" placeholder-red-500":""),type:"email",placeholder:p,onChange:e=>{var t,a;return v(null!==(a=null==e?void 0:null===(t=e.target)||void 0===t?void 0:t.value)&&void 0!==a?a:"")},onKeyUp:e=>j(e),ref:b}),(0,s.jsx)("button",{onClick:g,className:"h-full w-10 ".concat(o.e.fade),children:(0,s.jsx)(i.Z,{position:"right",className:"absolute right-0 top-2",fill:"white"})})]})]})},c=a(6846),d=a(4805),u=a(7703),m=e=>{let{className:t="",footer:a,mailchimp:i=""}=e,[m,f]=(0,l.useState)(new Date);return(0,l.useEffect)(()=>{let e=setInterval(()=>{f(new Date)},5e3);return()=>{clearInterval(e)}},[]),(0,s.jsx)("footer",{className:"w-full h-auto max-md:h-full flex bg-offBlack text-white px-0 py-14 max-md:py-10 no-select-all ".concat(t),children:(0,s.jsxs)(c.Z,{className:"flex max-md:flex-col max-md:px-6",children:[(0,s.jsxs)("div",{className:"h-full w-full max-md:w-full flex flex-col",children:[(0,s.jsx)("div",{className:"w-full mb-8",children:(0,s.jsxs)("span",{className:"text-sm",children:["UBUD"," ",new Intl.DateTimeFormat("sv-SE",{hour:"2-digit",minute:"2-digit",timeZone:"Asia/Makassar"}).format(m)]})}),(0,s.jsx)(n.Z,{url:i,render:e=>{let{subscribe:t,status:l,message:n}=e;return(0,s.jsx)(r,{status:l,message:n,subText:a.subscription,onValidated:e=>t(e)})}})]}),(0,s.jsxs)("div",{className:"w-full h-full max-md:mt-10 flex flex-col justify-between relative -right-3 max-md:right-0 max-md:-left-3",children:[a.show_socmed&&(0,s.jsxs)("div",{className:"w-auto h-full space-x-4 flex justify-end max-md:justify-start",children:[a.footerLink&&a.footerLink.email&&(0,s.jsx)(d.Z,{destination:"mailto:".concat(a.footerLink.email),className:"relative w-10 h-10 setflex-center ".concat(o.e.fade),children:(0,s.jsx)(u.Mh,{fill:"#fff",className:"w-4 h-4"})}),a.footerLink&&a.footerLink.instagram&&(0,s.jsx)(d.Z,{destination:a.footerLink.instagram,blank:!0,className:"relative w-10 h-10 setflex-center ".concat(o.e.fade),children:(0,s.jsx)(u.mr,{fill:"#FFF",className:"w-4 h-4"})}),a.footerLink&&a.footerLink.facebook&&(0,s.jsx)(d.Z,{destination:a.footerLink.facebook,blank:!0,className:"relative w-10 h-10 setflex-center ".concat(o.e.fade),children:(0,s.jsx)(u.s1,{fill:"#FFF",className:"w-4 h-4"})}),a.footerLink&&a.footerLink.youtube&&(0,s.jsx)(d.Z,{destination:a.footerLink.youtube,blank:!0,className:"relative w-10 h-10 setflex-center ".concat(o.e.fade),children:(0,s.jsx)(u.hx,{fill:"#FFF",className:"w-4 h-4"})}),a.footerLink&&a.footerLink.linkedin&&(0,s.jsx)(d.Z,{destination:a.footerLink.linkedin,blank:!0,className:"relative w-10 h-10 setflex-center  ".concat(o.e.fade),children:(0,s.jsx)(u.n6,{fill:"#FFF",className:"w-4 h-4"})})]}),(0,s.jsx)("div",{className:"w-full h-full max-md:mt-8 flex justify-end max-md:justify-start items-end max-md:items-start pr-3 max-md:pr-0 max-md:pl-3",children:(0,s.jsx)("span",{className:"text-sm",children:a.creditText})})]})]})})}},5548:function(e,t,a){"use strict";var s=a(5893);a(7294),t.Z=e=>{let{className:t=""}=e;return(0,s.jsx)("div",{className:"w-full h-header ".concat(t)})}},7117:function(e,t,a){"use strict";a.d(t,{Z:function(){return i}});var s=a(5893),l=a(7294),n=a(6941),o=a(1163);function i(e){let{children:t}=e,a=(0,n.b)(),[i,r]=(0,l.useState)(!1),c=(0,o.useRouter)();return(0,l.useEffect)(()=>{a.setHistory([...a.history,c.asPath])},[c.asPath]),(0,l.useEffect)(()=>{let{innerWidth:e,innerHeight:t}=window;(a.mobileMenu||a.isOpenBook)&&e<=850?r(!0):r(!1)},[a.mobileMenu,a.isOpenBook]),(0,s.jsx)("div",{className:"".concat(i?"pointer-events-none":""),children:t})}},6139:function(e,t,a){"use strict";var s=a(5893);t.Z=e=>{let{className:t,position:a,fill:l,sizeTop:n="24",sizeLeftRight:o="11"}=e;return(0,s.jsx)(s.Fragment,{children:"top"===a?(0,s.jsx)("svg",{width:n,height:n,viewBox:"0 0 24 24",fill:"none",className:"arrow ".concat(t),children:(0,s.jsx)("path",{d:"M23.857 11.9123C14.9607 7.26895 13.0441 1.1507 13.0441 1.09607L13.0155 0.986818L11.0417 0.986818L11.0131 1.09607C10.9845 1.1507 9.09654 7.26895 0.200238 11.9123L-5.65369e-07 11.9942L2.66031 14.9168L2.77473 14.8621C2.83194 14.8075 8.38141 11.3387 11.1561 5.79402C11.1275 6.80462 11.0131 8.71658 10.6698 10.0823C10.2122 12.0215 10.2694 15.2992 10.2694 15.3265L10.2694 23.7937L13.7306 23.7937L13.7306 15.3538C13.7306 15.3265 13.7878 12.0488 13.3302 10.1096C13.0155 8.74389 12.9011 6.80462 12.8439 5.82133C15.6186 11.366 21.1681 14.8348 21.2253 14.8895L21.3397 14.9441L24 12.0215L23.857 11.9123Z",fill:"black"})}):(0,s.jsx)("svg",{width:o,height:o,viewBox:"0 0 11 11",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"arrow ".concat(t),children:"left"===a?(0,s.jsx)("path",{d:"M5.26946 10.9344C3.02994 6.85697 0.0790415 5.97855 0.0526943 5.97855L0 5.96544L0 5.06079L0.0526943 5.04768C0.0790415 5.03456 3.02994 4.16925 5.26946 0.0917759L5.30898 0L6.71856 1.21931L6.69222 1.27175C6.66587 1.29797 4.99281 3.84148 2.31856 5.11323C2.80599 5.10012 3.72814 5.04768 4.38683 4.89035C5.32216 4.68057 6.90299 4.70679 6.91617 4.70679L11 4.70679L11 6.29321L6.92934 6.29321C6.91617 6.29321 5.33533 6.31943 4.4 6.10965C3.74132 5.96544 2.80599 5.91299 2.33174 5.88677C5.00599 7.15852 6.67904 9.70203 6.70539 9.72825L6.73174 9.78069L5.32216 11L5.26946 10.9344Z",fill:l||"#676767"}):"right"===a?(0,s.jsx)("path",{d:"M5.73054 10.9344C7.97006 6.85697 10.921 5.97855 10.9473 5.97855L11 5.96544L11 5.06079L10.9473 5.04768C10.921 5.03456 7.97006 4.16925 5.73054 0.0917759L5.69102 0L4.28144 1.21931L4.30778 1.27175C4.33413 1.29797 6.00719 3.84148 8.68144 5.11323C8.19401 5.10012 7.27186 5.04768 6.61317 4.89035C5.67784 4.68057 4.09701 4.70679 4.08383 4.70679L0 4.70679L0 6.29321L4.07066 6.29321C4.08383 6.29321 5.66467 6.31943 6.6 6.10965C7.25868 5.96544 8.19401 5.91299 8.66826 5.88677C5.99401 7.15852 4.32096 9.70203 4.29461 9.72825L4.26826 9.78069L5.67784 11L5.73054 10.9344Z",fill:l||"#676767"}):null})})}},1642:function(e,t,a){"use strict";a.d(t,{Z:function(){return l}});var s=a(5893);function l(e){let{children:t,className:a,...l}=e;return(0,s.jsx)("div",{className:"mb-4 min-h-[200px] px-8 py-10 setflex-center ".concat(a),...l,children:(0,s.jsx)("h1",{className:"titlestyle",children:t})})}a(7294)},6587:function(e,t,a){"use strict";var s=a(5893);a(7294);var l=a(2962),n=a(9008),o=a.n(n),i=a(2827);t.Z=e=>{let{inputSEO:t="",defaultSEO:a="",webTitle:n="",title:r="Locavore",pagelink:c="https://locavorenext.com"}=e,d=void 0!==t&&void 0!==t.seo_description&&t.seo_description?t.seo_description:void 0!==a&&void 0!==a.seo_description&&a.seo_description?a.seo_description:"",u=void 0!==t&&void 0!==t.seo_image&&void 0!==t.seo_image.asset&&t.seo_image?(0,i.Z)(t.seo_image).format("jpg").quality(80).width(1200).url():void 0!==a&&void 0!==a.seo_image&&void 0!==a.seo_image.asset&&a.seo_image?(0,i.Z)(a.seo_image).format("jpg").quality(80).width(1200).url():"",m=void 0!==t&&void 0!==t.seo_image&&void 0!==t.seo_image.name&&t.seo_image.name?t.seo_image.name:void 0!==a&&void 0!==a.seo_image&&a.seo_image.name?a.seo_image.name:"",f=void 0!==t&&void 0!==t.seo_keywords&&t.seo_keywords?t.seo_keywords:void 0!==a&&void 0!==a.seo_keywords&&a.seo_keywords?a.seo_keywords:"",h=r&&n?"".concat(r," • ").concat(n):"Locavore\xae",x="https://locavorenext.com".concat(c?"".concat(c.startsWith("/")?"":"/").concat(c):"");return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(l.PB,{title:h,description:d,canonical:x,openGraph:{url:x,title:h,description:d,type:"website",images:[{url:u,alt:m,width:1200,height:628}],site_name:"Locavore"},twitter:{site:"Locavore",cardType:"summary_large_image"}}),(0,s.jsx)(o(),{children:(0,s.jsx)("meta",{name:"keywords",content:f})})]})}},7231:function(e,t,a){"use strict";a.d(t,{U:function(){return s}});let s={initial:{opacity:0},enter:{opacity:1,transition:{duration:.5,ease:[.83,0,.17,1],delay:.15}},exit:{opacity:0,transition:{duration:.5,ease:[.83,0,.17,1]}}}},8902:function(e,t,a){"use strict";a.r(t),a.d(t,{__N_SSG:function(){return j},default:function(){return y}});var s=a(5893),l=a(7294),n=a(1163),o=a(7117),i=a(7126),r=a(5548),c=a(798),d=a(5675),u=a.n(d),m=a(4805),f=a(2827),h=e=>{let{store:t,src:a,alt:n,position:o="",name:i=""}=e;function r(e){var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:null}let c=(0,l.useRef)(null);return(0,s.jsxs)(m.Z,{"data-store":t.slug.current,destination:"/family/".concat(t.slug.current),className:"family-card",ref:c,onMouseEnter:e=>{"ontouchstart"in window||c.current.classList.add("show")},onMouseLeave:e=>{c.current.classList.remove("show")},style:{backgroundColor:"rgba(".concat(r(t.bgColor.hex?t.bgColor.hex:"#D0D0D0"),", 1)")},children:[(0,s.jsx)("div",{className:"w-full h-full top-0 left-0",children:(0,s.jsx)(u(),{src:(0,f.Z)(a).format("webp").width(750).url(),alt:n,placeholder:"blur",fill:!0,style:{objectFit:"cover",objectPosition:"center top"},blurDataURL:(0,f.Z)(a).blur(2).format("webp").saturation(-100).width(100).url()})}),(0,s.jsxs)("div",{className:"absolute w-full h-full top-0 left-0 flex flex-col items-center text-center justify-center p-4 z-1",children:[""!==o&&""!==i?(0,s.jsx)("span",{className:"relative z-1 mb-auto font-serif text-sm font-bold",children:i}):"",(0,s.jsx)("span",{className:"font-bold text-lg leading-none text-center relative z-2",children:t.title}),""!==o&&""!==i?(0,s.jsx)("span",{className:"relative z-1 mt-auto font-serif text-sm ",children:o}):"",(0,s.jsx)("div",{className:"absolute w-full h-full top-0 left-0 z-0 ",style:{backgroundColor:"rgba(".concat(r(t.bgColor.hex?t.bgColor.hex:"#FFFFFF"),", .9)")}})]})]})},x=a(6587),v=a(7305),p=a(150),w=a(1642);let b={mobile:850,tablet:1200};var g=a(7231),j=!0;function y(e){let{seoAPI:t,familyAPI:a,familyListAPI:d,memberListAPI:u,footerAPI:m}=e,f=(0,n.useRouter)(),[j]=t,[y]=a,[L]=m,k=[];u.map(e=>{d.find(t=>t.slug.current===e.family.slug.current)&&k.push({...e,storeID:d.findIndex(t=>t.slug.current===e.family.slug.current)})});let N=e=>{let t=e.length,a;for(;0!=t;)a=Math.floor(Math.random()*t),t--,[e[t],e[a]]=[e[a],e[t]];return e},[_,C]=(0,l.useState)([]),E="none",Z={mobile:5,tablet:4,desktop:5},F=()=>{let e=!1,t=8,a=Z.desktop;if(window.innerWidth<b.mobile?"mobile"!==E&&(E="mobile",e=!0,t=3,a=Z.mobile):window.innerWidth>=b.mobile&&window.innerWidth<b.tablet?"tablet"!==E&&(E="tablet",t=5,a=Z.tablet,e=!0):"desktop"!==E&&(E="desktop",t=8,a=Z.desktop,e=!0),e){e=!1;let s=[...k],l=t*a;if(s.length<=l||s.length%t!=0){let e=l-s.length;s.length>=l&&(e=Math.ceil(s.length/t)*t-s.length);for(let t=0;t<=e-1;t++){let e=t,a=Math.floor(t/k.length);e>=k.length&&(e=t-k.length*a),s.push(k[e])}}C(N(s))}};return(0,l.useEffect)(()=>(F(),window.addEventListener("resize",F),window.scroll(0,0),()=>{window.removeEventListener("resize",F)}),[]),(0,s.jsxs)(o.Z,{children:[(0,s.jsx)(x.Z,{title:"Family",pagelink:f.pathname,inputSEO:y.seo,defaultSEO:void 0!==j&&j.seo,webTitle:void 0!==j&&j.webTitle}),(0,s.jsxs)(c.E.main,{initial:"initial",animate:"enter",exit:"exit",variants:g.U,className:"no-select-all",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)(r.Z,{}),(0,s.jsxs)(w.Z,{className:"sticky text-center z-1",style:{top:"60px"},children:[(0,s.jsx)("span",{className:"sub",children:"The"}),"Locavore Family"]}),(0,s.jsx)(v.Z,{familyListAPI:d,onFamilyHover:!0}),(0,s.jsx)("section",{className:"w-full h-full flex flex-col relative z-[10]",children:(0,s.jsx)("div",{className:"relative w-full h-auto flex flex-wrap  ",id:"family-image",children:_!==[]&&_.map((e,t)=>(0,s.jsx)(h,{store:d[e.storeID],position:e.hideNamePosition&&e.position||"",name:e.hideNamePosition&&e.name||"",src:e.image,alt:e.image.name},t))})})]}),(0,s.jsx)(p.Z,{familyListAPI:d,familyAPI:a,collapse:!1}),(0,s.jsx)(i.Z,{footer:L,mailchimp:j.mailchimpID})]})]})}}},function(e){e.O(0,[711,675,888,774,179],function(){return e(e.s=1914)}),_N_E=e.O()}]);