(window.webpackWcBlocksJsonp=window.webpackWcBlocksJsonp||[]).push([[54],{27:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var s=n(0),c=n(14),r=n.n(c);function o(e){const t=Object(s.useRef)(e);return r()(e,t.current)||(t.current=e),t.current}},317:function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return l}));var s=n(27),c=n(23),r=n(4),o=n(3);const a=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];const{paymentMethodsInitialized:t,expressPaymentMethodsInitialized:n,availablePaymentMethods:a,availableExpressPaymentMethods:i}=Object(r.useSelect)(e=>{const t=e(o.PAYMENT_STORE_KEY);return{paymentMethodsInitialized:t.paymentMethodsInitialized(),expressPaymentMethodsInitialized:t.expressPaymentMethodsInitialized(),availableExpressPaymentMethods:t.getAvailableExpressPaymentMethods(),availablePaymentMethods:t.getAvailablePaymentMethods()}}),l=Object.values(a).map(e=>{let{name:t}=e;return t}),d=Object.values(i).map(e=>{let{name:t}=e;return t}),u=Object(c.getPaymentMethods)(),b=Object(c.getExpressPaymentMethods)(),m=Object.keys(u).reduce((e,t)=>(l.includes(t)&&(e[t]=u[t]),e),{}),h=Object.keys(b).reduce((e,t)=>(d.includes(t)&&(e[t]=b[t]),e),{}),g=Object(s.a)(m),p=Object(s.a)(h);return{paymentMethods:e?p:g,isInitialized:e?n:t}},i=()=>a(!1),l=()=>a(!0)},452:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var s=n(3),c=n(4),r=n(77),o=n(317);const a=()=>{const{isCalculating:e,isBeforeProcessing:t,isProcessing:n,isAfterProcessing:a,isComplete:i,hasError:l}=Object(c.useSelect)(e=>{const t=e(s.CHECKOUT_STORE_KEY);return{isCalculating:t.isCalculating(),isBeforeProcessing:t.isBeforeProcessing(),isProcessing:t.isProcessing(),isAfterProcessing:t.isAfterProcessing(),isComplete:t.isComplete(),hasError:t.hasError()}}),{activePaymentMethod:d,isExpressPaymentMethodActive:u}=Object(c.useSelect)(e=>{const t=e(s.PAYMENT_STORE_KEY);return{activePaymentMethod:t.getActivePaymentMethod(),isExpressPaymentMethodActive:t.isExpressPaymentMethodActive()}}),{onSubmit:b}=Object(r.b)(),{paymentMethods:m={}}=Object(o.b)(),h=n||a||t,g=i&&!l;return{paymentMethodButtonLabel:(m[d]||{}).placeOrderButtonLabel,onSubmit:b,isCalculating:e,isDisabled:n||u,waitingForProcessing:h,waitingForRedirect:g}}},523:function(e,t,n){"use strict";n.r(t);var s=n(0),c=n(1),r=n(5),o=n.n(r),a=n(9),i=n(452),l=n(11),d=n(4),u=n(3),b=n(26);const m=b.l?`<a href="${b.l}" target="_blank">${Object(c.__)("Terms and Conditions","woocommerce")}</a>`:Object(c.__)("Terms and Conditions","woocommerce"),h=b.h?`<a href="${b.h}" target="_blank">${Object(c.__)("Privacy Policy","woocommerce")}</a>`:Object(c.__)("Privacy Policy","woocommerce"),g=Object(c.sprintf)(
/* translators: %1$s terms page link, %2$s privacy page link. */
Object(c.__)("By proceeding with your purchase you agree to our %1$s and %2$s","woocommerce"),m,h),p=Object(c.sprintf)(
/* translators: %1$s terms page link, %2$s privacy page link. */
Object(c.__)("You must accept our %1$s and %2$s to continue with your purchase.","woocommerce"),m,h);t.default=Object(l.withInstanceId)(e=>{let{text:t,checkbox:n,instanceId:r,className:l}=e;const[b,m]=Object(s.useState)(!1),{isDisabled:h}=Object(i.a)(),O="terms-and-conditions-"+r,{setValidationErrors:y,clearValidationError:j}=Object(d.useDispatch)(u.VALIDATION_STORE_KEY),P=Object(d.useSelect)(e=>e(u.VALIDATION_STORE_KEY).getValidationError(O)),_=!(null==P||!P.message||null!=P&&P.hidden);return Object(s.useEffect)(()=>{if(n)return b?j(O):y({[O]:{message:Object(c.__)("Please read and accept the terms and conditions.","woocommerce"),hidden:!0}}),()=>{j(O)}},[n,b,O,j,y]),Object(s.createElement)("div",{className:o()("wc-block-checkout__terms",{"wc-block-checkout__terms--disabled":h},l)},n?Object(s.createElement)(s.Fragment,null,Object(s.createElement)(a.CheckboxControl,{id:"terms-and-conditions",checked:b,onChange:()=>m(e=>!e),hasError:_,disabled:h},Object(s.createElement)("span",{dangerouslySetInnerHTML:{__html:t||p}}))):Object(s.createElement)("span",{dangerouslySetInnerHTML:{__html:t||g}}))})}}]);