1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7844],{1920:(e,l,t)=>{t.d(l,{A:()=>r});var a=t(14232);let r=function(e,l){var t=(0,a.useState)(null),r=t[0],n=t[1];return(0,a.useEffect)(function(){if(e.current&&"function"==typeof IntersectionObserver){var t=new IntersectionObserver(function(e){n(e[0])},l);return t.observe(e.current),function(){n(null),t.disconnect()}}return function(){}},[e.current,l.threshold,l.root,l.rootMargin]),r}},17152:(e,l,t)=>{t.d(l,{A:()=>i});var a=t(37876),r=t(14232),n=t(39895);let s=0,i={image:e=>{let{node:l}=e;s+=1;let t=l.linkTo?(0,n.A)(l.linkTo):null,i=l.linkTo&&l.linkTo.target?{target:l.linkTo.target,rel:"noopener"}:{},o=[l.label||"","block-img"],c=(null==l?void 0:l.alt)||"Article image ".concat(s),d=(0,a.jsx)("img",{src:(null==l?void 0:l.url)||"",alt:c,copyright:(null==l?void 0:l.copyright)||""}),u={className:o.join(" ")},m=t?(0,a.jsx)("a",{href:t,...i,children:d}):d;return(0,r.createElement)("p",u,m)},embed:e=>{let{node:l}=e,t={"data-oembed":l.oembed.embed_url,"data-oembed-type":l.oembed.type,"data-oembed-provider":l.oembed.provider_name,className:"video-embed",dangerouslySetInnerHTML:{__html:l.oembed.html}};return(0,r.createElement)("div",t)},hyperlink:e=>{let{node:l,children:t}=e,a=l.data.target?{target:l.data.target,rel:"noopener"}:{},s=(0,n.A)(l.data);return(0,r.createElement)("a",{target:a,href:s},t)},label:e=>{var l;let{node:t,children:a}=e;if((null==t||null==(l=t.data)?void 0:l.label)==="blockquote")return(0,r.createElement)("blockquote",{},a);let n=t.data.label?{className:t.data.label}:{className:""};return(0,r.createElement)("span",n,a)},heading1:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h1",{},l):null},heading2:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h2",{},l):null},heading3:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h3",{},l):null},heading4:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h4",{},l):null},heading5:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h5",{},l):null},heading6:e=>{let{children:l}=e;return(null==l?void 0:l.some(e=>"string"==typeof e?e.trim():e))?(0,r.createElement)("h6",{},l):null}}},30574:(e,l,t)=>{t.d(l,{A:()=>i});var a=t(37876),r=t(46462),n=t(39895),s=t(17152);let i=function(e){let{content:l}=e;return(0,a.jsx)(r.$,{field:l,linkResolver:n.A,components:s.A})}},50333:(e,l,t)=>{t.d(l,{A:()=>r});var a=t(37876);function r(e){let{placeholder:l="Email",isFilled:t,id:r="email",register:n,required:s=!0,pattern:i={value:/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}$/i,message:"Oops, try again"},errors:o,disabled:c=!1,defaultValue:d=""}=e;return(0,a.jsxs)("div",{className:"flex-1 flex flex-col gap-y-2",children:[(0,a.jsxs)("div",{className:"form-control",children:[(0,a.jsx)("input",{className:"input ".concat(t?"is-filled":""),type:"email",autoComplete:"username",defaultValue:d,id:r,required:s,disabled:c,...!c&&{...n(r,{required:s,maxLength:200,pattern:i,disabled:c})}}),(0,a.jsx)("label",{htmlFor:r,className:"label",children:(0,a.jsx)("span",{className:"placeholder",children:l})})]}),o&&(0,a.jsx)("p",{className:"block py-0 error-message",children:o})]})}},57844:(e,l,t)=>{t.r(l),t.d(l,{default:()=>y});var a=t(37876),r=t(14232),n=t(10553),s=t(54587),i=t.n(s),o=t(48230),c=t.n(o),d=t(29260),u=t(29454),m=t
1(88992),h=t(1920),p=t(51211),g=t(28158),x=t(30574),f=t(50333),v=t(68636),b=t(12246);function y(e){var l,t,s,o;let y,j,{slice:N}=e,{primary:w}=N;(null==w?void 0:w.card_color)==="pastel purple"?y="bg-bbx-glow":(null==w?void 0:w.card_color)==="neon green"&&(y="bg-bbx-neon-green"),(null==w?void 0:w.logo_color)==="white"?j="fill-white":(null==w?void 0:w.logo_color)==="neon green"&&(j="fill-bbx-neon-green");let k=(0,d.Ay)(),{data:_}=(0,n.useSession)(),[A,E]=(0,r.useState)(!1),S=(0,r.useRef)(null),{isIntersecting:M}=(0,h.A)(S,{root:null,rootMargin:"0px",threshold:1})||{};(0,r.useEffect)(()=>{_||!1!==M||"true"===u.A.get("HAS_SHOWN_SIGNUP_MODAL")||(E(!0),u.A.set("HAS_SHOWN_SIGNUP_MODAL","true",{expires:365}))},[M,_]),(0,r.useEffect)(()=>{let e=e=>{"Escape"===e.key&&E(!1)};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[]);let{register:L,handleSubmit:O,watch:P}=(0,m.mN)({mode:"onChange",defaultValues:{acceptsMarketing:(0,g.bh)()}}),C=P("signUpModalEmail"),F=async e=>{let{signUpModalEmail:l,signUpModalPhone:t}=e;if(l&&t){let e=await fetch("/api/newsletter/sign-up",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:l,phone:t})});(await e.json()).success?(k("Success!","You're signed up to receive the latest deals, news, and more!"),E(!1)):k("Something went wrong","Please wait a few minutes, and try signing up again.")}};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"absolute top-0 invisible h-40","aria-hidden":"true",ref:S}),A&&(0,a.jsx)("div",{className:"fixed inset-0 z-40 flex items-center bg-bbx-style/50",children:(0,a.jsx)("div",{className:"container flex items-center justify-center mt-8",children:(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)("button",{type:"button",className:"absolute right-0 z-10 px-2 py-1 -top-10 lg:-top-16",onClick:()=>E(!1),children:(0,a.jsx)("i",{className:"text-2xl text-white fa-light fa-xmark"})}),(0,a.jsxs)("div",{className:"relative grid w-full max-w-screen-lg overflow-y-auto max-lg:max-h-[85vh] bg-white lg:overflow-y-visible lg:grid-cols-2",children:[(0,a.jsx)("div",{className:"absolute top-0 max-lg:h-[300px] lg:bottom-0 left-0 max-lg:right-0 lg:w-[364px] ".concat(y)}),(null==w||null==(l=w.card_image)?void 0:l.url)&&(0,a.jsxs)("div",{className:"relative flex justify-center max-lg:h-[400px] top-0 lg:-top-16 left-0 sm:left-20 lg:left-16 bottom-16 max-w-[400px] w-full",children:[(0,a.jsx)(i(),{src:w.card_image.url,alt:w.card_image.alt,layout:"fill",quality:100,priority:!0,objectFit:"cover"}),(0,a.jsx)(b.A,{className:"w-[230px] absolute bottom-16 ".concat(j)})]}),(0,a.jsxs)("div",{className:"sm:px-20 sm:pb-16 sm:pt-14 px-8 py-12 lg:max-h-[85vh] lg:overflow-y-auto",children:[(null==w||null==(t=w.card_title)?void 0:t[0])&&(0,a.jsx)("div",{className:"text-3xl font-bold uppercase sm:text-4xl lg:text-5xl",children:(0,a.jsx)(x.A,{content:w.card_title})}),(null==w||null==(s=w.card_description)?void 0:s[0])&&(0,a.jsx)("div",{className:"mt-6",children:(0,a.jsx)(x.A,{content:w.card_description})}),(0,a.jsxs)("form",{onSubmit:O(F),className:"mt-6 space-y-4",children:[(0,a.jsx)(f.A,{id:"signUpModalEmail",register:L,isFilled:!!C}),(0,a.jsx)(v.A,{id:"signUpModalPhone",register:L,placeholder:"Phone Number"}),(0,a.jsxs)("label",{htmlFor:"acceptsMarketing",className:"flex items-start mt-5 font-light text-gray-500 gap-x-5",children:[(0,a.jsx)("input",{type:"checkbox",id:"acceptsMarketing",className:"mt-1 accent-bbx-style shrink-0",required:!0,...L("acceptsMarketing",{required:!0})}),(0,a.jsx)("span",{className:"text-sm",children:(null==p||null==(o=p.footer)?void 0:o.privacy)&&(0,a.jsxs)(a.Fragment,{children:[p.footer.privacy[0]," ",!(0,g.bh)()&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c(),{legacyBehavior:!0,href:p.privacyHref,children:(0,a.jsx)("a",{className:"underline",children:p.footer.privacyLink})})," ",p.footer.privacy[1],(0,a.jsxs)("p",{children:[p.footer.privacy[2]," ",(0,a.jsx)(c(),{legacyBehavior:!0,href:p.privacyHref,children:(0,a.jsx)("a",{className:"underline",children:p.footer.privacyLink})})," "]})]})]})})]}),(0,a.jsx)("button",{type:"submit",className:"!mt-9 button button-primary",children:(null==w?void 0:w.submit_label)||"Submit"})]})]})]})]})})})]})}},68636:(e,l,t)=>{t.d(l,{A:()=>s,k:()=>n});var a=t(37876),r=t(78799);let n=e=>{if("en-us"===r.vV&&(e.startsWith("+1")&&(e=e.slice(2)),(e=e.replace(/\D/g,"")).length>3)){let l=e.slice(0,3),t=e.slice(3,6),a=e.slice(6,10);e="(".concat(l,") ").concat(t).concat(a?"-".concat(a):"")}return e};function s(e){let{register:l,placeholder:t="en-us"===r.vV?"Phone":"en-gb"===r.vV?"ex. +44 Phone":"ex. +34 Phone",id:s="phone",required:i=!0,errors:o}=e;return(0,a.jsxs)("div",{className:"flex-1 flex flex-col gap-y-2",children:[(0,a.jsxs)("div",{className:"form-control",children:[(0,a.jsx)("input",{className:"input ".concat(o?"error":""),type:"tel",autoComplete:"tel",required:i,id:s,maxLength:14,...l(s,{required:i,onChange:e=>{e.target.value=n(e.target.value)}})}),(0,a.jsx)("label",{htmlFor:s,className:"label",children:t})]}),o&&(0,a.jsx)("p",{className:"py-2 error-message",children:o})]})}}}]); 2//# sourceMappingURL=7844.a4aea2218202b7b7.js.map
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.