"use strict";(self.webpackChunkui=self.webpackChunkui||[]).push([[34],{324:(e,t,i)=>{i.r(t),i.d(t,{default:()=>r});const r={wrapper:"NF44PSwH",wrapperContainer:"PEFffiCz",wrapperInput:"dbbmSL84",wrapperFollowUs:"ZThAMNni",wrapperFollowUsTitle:"MyoinB_k",wrapperFollowUsSocialLinks:"CKDqhIVb"}},323:(e,t,i)=>{const r=i(139);(0,i(4).createEntrypoint)("newsletter",r.Newsletter)()},329:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.initialNewsletterData=void 0,t.initialNewsletterData={email:""}},72:function(e,t,i){var r=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))((function(s,l){function a(e){try{o(r.next(e))}catch(e){l(e)}}function n(e){try{o(r.throw(e))}catch(e){l(e)}}function o(e){var t;e.done?s(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,n)}o((r=r.apply(e,t||[])).next())}))},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.useNewsletter=void 0;const l=i(328),a=i(329),n=s(i(5));t.useNewsletter=e=>{const{state:t,setState:i,handleChangeState:s}=(0,l.useFillingInput)(a.initialNewsletterData);return{email:t.email,handleChangeState:s,handleSubmit:s=>r(void 0,void 0,void 0,(function*(){if(s.preventDefault(),!(t.email.length>0))return void n.default.fire({title:"Error",text:"Failed to subscribe, please enter a valid email address",icon:"error"});const r={data:{type:"profile-subscription-bulk-create-job",attributes:{profiles:{data:[{type:"profile",attributes:{email:t.email}}]}},relationships:{list:{data:{type:"list",id:"SUeqvv"}}}}};i(a.initialNewsletterData);try{const t=yield fetch(e,{method:"POST",body:JSON.stringify(r)});return"2"===t.status.toString()[0]?void n.default.fire({title:"Success",text:"Successfully subscribed to daily deals",icon:"success"}):void n.default.fire({title:"Error",text:"Failed to subscribe, please try it later",icon:"error"})}catch(e){return console.error(e),void n.default.fire({title:"Error",text:"Failed to subscribe, please try it later",icon:"error"})}}))}}},139:function(e,t,i){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Newsletter=void 0;const s=i(0),l=(i(1),r(i(324))),a=i(325),n=i(326),o=i(327),c=i(72),{wrapper:d,wrapperContainer:u,wrapperInput:h,wrapperFollowUs:p,wrapperFollowUsTitle:w,wrapperFollowUsSocialLinks:b}=l.default;t.Newsletter=({title:e,inputPlaceholder:t,subscribeButtonLabel:i,followUsLabel:r,twitterLink:l,facebookLink:v})=>{const{email:f,handleChangeState:j,handleSubmit:g}=(0,c.useNewsletter)("/_klaviyo/subscribe");return(0,s.jsx)("div",Object.assign({className:d},{children:(0,s.jsxs)("div",Object.assign({className:u},{children:[(0,s.jsx)("h3",{children:e}),(0,s.jsxs)("form",Object.assign({onSubmit:g},{children:[(0,s.jsxs)("div",Object.assign({className:h},{children:[(0,s.jsx)(a.MailSVG,{}),(0,s.jsx)("input",{type:"email",name:"email",value:f,onChange:j,placeholder:t})]})),(0,s.jsx)("button",Object.assign({type:"submit",height:"45px"},{children:i}))]})),(0,s.jsxs)("div",Object.assign({className:p},{children:[(0,s.jsx)("h2",Object.assign({className:w},{children:r})),(0,s.jsxs)("div",Object.assign({className:b},{children:[(0,s.jsx)("a",Object.assign({href:l,target:"__blank",title:"Twitter",rel:"noopener noreferrer","aria-label":"Twitter"},{children:(0,s.jsx)(n.TwitterSVG,{})})),(0,s.jsx)("a",Object.assign({href:v,target:"__blank",title:"Facebook",rel:"noopener noreferrer","aria-label":"Facebook"},{children:(0,s.jsx)(o.FacebookSVG,{})}))]}))]}))]}))}))}},327:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.FacebookSVG=void 0;const r=i(0);i(1),t.FacebookSVG=()=>(0,r.jsx)("svg",Object.assign({version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:"32",height:"32",viewBox:"0 0 32 32"},{children:(0,r.jsx)("path",{d:"M2.428 0.41c-0.936 0-1.695 0.753-1.695 1.682v27.112c0 0.929 0.759 1.682 1.695 1.682h14.709v-11.802h-4.002v-4.599h4.002v-3.392c0-3.936 2.423-6.080 5.961-6.080 1.695 0 3.152 0.125 3.576 0.181v4.114l-2.454 0.001c-1.924 0-2.297 0.907-2.297 2.239v2.937h4.59l-0.598 4.599h-3.992v11.802h7.826c0.936 0 1.695-0.753 1.695-1.682v-27.112c0-0.929-0.759-1.682-1.695-1.682h-27.321z"})}))},325:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.MailSVG=void 0;const r=i(0);i(1),t.MailSVG=()=>(0,r.jsxs)("svg",Object.assign({viewBox:"0 0 25 17",id:"icon-email"},{children:[" ",(0,r.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M3.87264 1.50693C2.53516 1.50693 1.47529 2.62219 1.47529 3.95568V14.1274C1.47529 14.8886 2.06709 15.4931 2.81227 15.4931H21.2995C22.0241 15.4931 22.6447 14.8598 22.6826 14.11V3.95568C22.6826 2.58952 21.5907 1.50693 20.2853 1.50693H3.87264ZM0 3.95568C0 1.8044 1.7063 0 3.87264 0H20.2853C22.3914 0 24.1579 1.74289 24.1579 3.95568V14.1431L24.1573 14.1588C24.0959 15.6633 22.8756 17 21.2995 17H2.81227C1.25231 17 0 15.7208 0 14.1274V3.95568Z",fill:"#095898"})," ",(0,r.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M10.219 10.9199L0.894531 2.90877L1.89883 1.78833L11.2264 9.80213C11.7475 10.2523 12.41 10.2523 12.9311 9.80213L12.9327 9.8008L22.2587 1.78833L23.263 2.90877L13.9385 10.9199C13.9383 10.9201 13.938 10.9203 13.9378 10.9205C12.8414 11.8671 11.3161 11.8671 10.2197 10.9205C10.2195 10.9203 10.2192 10.9201 10.219 10.9199Z",fill:"#095898"})," "]}))},326:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TwitterSVG=void 0;const r=i(0);i(1),t.TwitterSVG=()=>(0,r.jsx)("svg",Object.assign({version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:"43",height:"32",viewBox:"0 0 43 32"},{children:(0,r.jsx)("path",{d:"M36.575 5.229c1.756-0.952 3.105-2.46 3.74-4.257-1.644 0.882-3.464 1.522-5.402 1.867-1.551-1.495-3.762-2.429-6.209-2.429-4.697 0-8.506 3.445-8.506 7.694 0 0.603 0.075 1.19 0.22 1.753-7.069-0.321-13.337-3.384-17.532-8.039-0.732 1.136-1.152 2.458-1.152 3.868 0 2.669 1.502 5.024 3.784 6.404-1.394-0.040-2.706-0.386-3.853-0.962-0.001 0.032-0.001 0.064-0.001 0.097 0 3.728 2.932 6.837 6.823 7.544-0.714 0.176-1.465 0.27-2.241 0.27-0.548 0-1.081-0.048-1.6-0.138 1.083 3.057 4.224 5.281 7.946 5.343-2.911 2.064-6.579 3.294-10.564 3.294-0.687 0-1.364-0.036-2.029-0.108 3.764 2.183 8.235 3.457 13.039 3.457 15.646 0 24.202-11.724 24.202-21.891 0-0.334-0.008-0.665-0.025-0.995 1.662-1.085 3.104-2.439 4.244-3.982-1.525 0.612-3.165 1.025-4.885 1.211z"})}))},328:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.useFillingInput=void 0;const r=i(3);t.useFillingInput=e=>{const[t,i]=(0,r.useState)(e);return{state:t,setState:i,handleChangeState:e=>{i((t=>Object.assign(Object.assign({},t),{[e.currentTarget.name]:e.currentTarget.value})))}}}}},e=>{e.O(0,[1,2,4],(()=>(323,e(e.s=323)))),e.O()}]);