1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[52069],{27286:(e,t,n)=>{"use strict";n.d(t,{S:()=>l,l:()=>s});var o=n(55729),r=n(4308),a=n(95913),i=n(93251);function s(e,t){let n=(0,i.jE)(t);return l({filters:{...e,status:"pending"}},n).length}function c(e,t){return e.findAll(t.filters).map(e=>t.select?t.select(e):e.state)}function l(e={},t){let n=(0,i.jE)(t).getMutationCache(),s=o.useRef(e),u=o.useRef(null);return null===u.current&&(u.current=c(n,e)),o.useEffect(()=>{s.current=e}),o.useSyncExternalStore(o.useCallback(e=>n.subscribe(()=>{let t=(0,r.BH)(u.current,c(n,s.current));u.current!==t&&(u.current=t,a.jG.schedule(e))}),[n]),()=>u.current,()=>u.current)}},50619:(e,t,n)=>{"use strict";n.d(t,{JV:()=>C,ag:()=>M});var o,r,a,i,s,c,l=n(55729);(o=i||(i={})).INITIAL="initial",o.PENDING="pending",o.REJECTED="rejected",o.RESOLVED="resolved",(r=s||(s={})).LOADING_STATUS="setLoadingStatus",r.RESET_OPTIONS="resetOptions",r.SET_BRAINTREE_INSTANCE="braintreeInstance",(a=c||(c={})).NUMBER="number",a.CVV="cvv",a.EXPIRATION_DATE="expirationDate",a.EXPIRATION_MONTH="expirationMonth",a.EXPIRATION_YEAR="expirationYear",a.POSTAL_CODE="postalCode";var u="data-react-paypal-script-id",d="data-sdk-integration-source",f="react-paypal-js",h="data-namespace",p="paypal",m=function(){return(m=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function y(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&0>t.indexOf(o)&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)0>t.indexOf(o[r])&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function v(e,t,n){if(n||2==arguments.length)for(var o,r=0,a=t.length;r<a;r++)!o&&r in t||(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}function g(e){return void 0===e&&(e=p),window[e]}function E(e){var t=e.reactComponentName,n=e.sdkComponentKey,o=e.sdkRequestedComponents,r=void 0===o?"":o,a=e.sdkDataNamespace,i=n.charAt(0).toUpperCase().concat(n.substring(1)),s="Unable to render <".concat(t," /> because window.").concat(void 0===a?p:a,".").concat(i," is undefined.");if(!r.includes(n)){var c=[r,n].filter(Boolean).join();s+="\nTo fix the issue, add '".concat(n,"' to the list of components passed to the parent PayPalScriptProvider:")+"\n`<PayPalScriptProvider options={{ components: '".concat(c,"'}}>`.")}return s}function P(e){return"react-paypal-js-".concat(function(e){for(var t="",n=0;n<e.length;n++){var o=e[n].charCodeAt(0)*n;e[n+1]&&(o+=e[n+1].charCodeAt(0)*(n-1)),t+=String.fromCharCode(97+Math.abs(o)%26)}return t}(JSON.stringify(e)))}function b(e,t){var n,o,r;switch(t.type){case s.LOADING_STATUS:return m(m({},e),{loadingStatus:t.value});case s.RESET_OPTIONS:return o=e.options[u],(null==(r=self.document.querySelector("script[".concat(u,'="').concat(o,'"]')))?void 0:r.parentNode)&&r.parentNode.removeChild(r),delete t.value[u],m(m({},e),{loadingStatus:i.PENDING,options:m(m({},t.value),((n={})[u]="".concat(P(t.value)),n[d]=f,n))});case s.SET_BRAINTREE_INSTANCE:return m(m({},e),{braintreePayPalCheckoutInstance:t.value});default:return e}}var R=(0,l.createContext)(null);function N(){var e=function(e){if("function"==typeof(null==e?void 0:e.dispatch)&&0!==e.dispatch.length)return e;throw Error("usePayPalScriptReducer must be used within a PayPalScriptProvider")}((0,l.useContext)(R));return[m(m({},e),{isInitial:e.loadingStatus===i.INITIAL,isPending:e.loadingStatus===i.PENDING,isResolved:e.loadingStatus===i.RESOLVED,isRejected:e.loadingStatus===i.REJECTED}),e.dispatch]}(0,l.createContext)({});var C=function(e){var t=e.className,n=e.disabled,o=void 0!==n&&n,r=e.children,a=e.forceReRender,i=y(e,["className","disabled","children","forceReRender"]),s="".concat(void 0===t?"":t," ").concat(o?"paypal-buttons-disabled":"").trim(),c=(0,l.useRef)(null),u=(0,l.useRef)(null),d=N()[0],f=d.isResolved,p=d.options,P=(0,l.useState)(null),b=P[0],R=P[1],I=(0,l.useState)(!0),S=I[0],w=I[1],T=(0,l.useState)(null)[1];function A(){null!==u.current&&u.current.close().catch(function(){})}return(0,l.useEffect)(function(){if(!1===f)return A;var e=g(p[h]);if(void 0===e||void 0===e.Buttons)return T(function(){throw Error(E({reactComponentName:C.displayName,sdkComponentKey:"buttons",sdkRequestedComponents:p.components,sdkDataNamespace:p[h]}))}),A;try{u.current=e.Buttons(m(m({},i),{onInit:function(e,t){R(t),"function"==typeof i.onInit&&i.onInit(e,t)}}))}catch(e){return T(function(){throw Error("Failed to render <PayPalButtons /> component. Failed to initialize: ".concat(e))})}return!1===u.current.isEligible()?w(!1):c.current&&u.current.render(c.current).catch(function(e){null!==c.current&&0!==c.current.children.length&&T(function(){throw Error("Failed to render <PayPalButtons /> component. ".concat(e))})}),A},v(v([f],void 0===a?[]:a,!0),[i.fundingSource],!1)),(0,l.useEffect)(function(){null!==b&&(!0===o?b.disable().catch(function(){}):b.enable().catch(function(){}))},[o,b]),l.createElement(l.Fragment,null,S?l.createElement("div",{ref:c,style:o?{opacity:.38}:{},className:s}):r)};function I(e,t){void 0===t&&(t={});var n=document.createElement("script");return n.src=e,Object.keys(t).forEach(function(e){n.setAttribute(e,t[e]),"data-csp-nonce"===e&&n.setAttribute("nonce",t["data-csp-nonce"])}),n}function S(){if("u"<typeof Promise)throw Error("Promise is undefined. To resolve the issue, use a Promise polyfill.");return Promise}C.displayName="PayPalButtons";function w(e,t){if("object"!=typeof e||null===e)throw Error("Expected an options object.");if(void 0!==t&&"function"!=typeof t)throw Error("Expected PromisePonyfill to be a function.")}var T=function(e){var t=e.className,n=e.children,o=y(e,["className","children"]),r=N()[0],a=r.isResolved,i=r.options,s=(0,l.useRef)(null),c=(0,l.useState)(!0),u=c[0],d=c[1],f=(0,l.useState)(null)[1],p=function(e){var t=s.current;if(!t||!e.isEligible())return d(!1);t.firstChild&&t.removeChild(t.firstChild),e.render(t).catch(function(e){null!==t&&0!==t.children.length&&f(function(){throw Error("Failed to render <PayPalMarks /> component. ".concat(e))})})};return(0,l.useEffect)(function(){if(!1!==a){var e=g(i[h]);if(void 0===e||void 0===e.Marks)return f(function(){throw Error(E({reactComponentName:T.dis
1playName,sdkComponentKey:"marks",sdkRequestedComponents:i.components,sdkDataNamespace:i[h]}))});p(e.Marks(m({},o)))}},[a,o.fundingSource]),l.createElement(l.Fragment,null,u?l.createElement("div",{ref:s,className:void 0===t?"":t}):n)};T.displayName="PayPalMarks";var A=function(e){var t=e.className,n=e.forceReRender,o=y(e,["className","forceReRender"]),r=N()[0],a=r.isResolved,i=r.options,s=(0,l.useRef)(null),c=(0,l.useRef)(null),u=(0,l.useState)(null)[1];return(0,l.useEffect)(function(){if(!1!==a){var e=g(i[h]);if(void 0===e||void 0===e.Messages)return u(function(){throw Error(E({reactComponentName:A.displayName,sdkComponentKey:"messages",sdkRequestedComponents:i.components,sdkDataNamespace:i[h]}))});c.current=e.Messages(m({},o)),c.current.render(s.current).catch(function(e){null!==s.current&&0!==s.current.children.length&&u(function(){throw Error("Failed to render <PayPalMessages /> component. ".concat(e))})})}},v([a],void 0===n?[]:n,!0)),l.createElement("div",{ref:s,className:void 0===t?"":t})};A.displayName="PayPalMessages";var M=function(e){var t,n=e.options,o=void 0===n?{"client-id":"test"}:n,r=e.children,a=e.deferLoading,c=void 0!==a&&a,h=(0,l.useReducer)(b,{options:m(m({},o),((t={})[u]="".concat(P(o)),t[d]=f,t)),loadingStatus:c?i.INITIAL:i.PENDING}),p=h[0],y=h[1];return(0,l.useEffect)(function(){if(!1===c&&p.loadingStatus===i.INITIAL)return y({type:s.LOADING_STATUS,value:i.PENDING});if(p.loadingStatus===i.PENDING){var e=!0;return(function(e,t){if(void 0===t&&(t=S()),w(e,t),"u"<typeof window)return t.resolve(null);var n,o,r,a,i,s,c,l,u,d,f,h,p=(u="https://www.paypal.com/sdk/js",e.sdkBaseURL&&(u=e.sdkBaseURL,delete e.sdkBaseURL),o=(n=e)["merchant-id"],r=n["data-merchant-id"],a="",i="",Array.isArray(o)?o.length>1?(a="*",i=o.toString()):a=o.toString():"string"==typeof o&&o.length>0?a=o:"string"==typeof r&&r.length>0&&(a="*",i=r),n["merchant-id"]=a,n["data-merchant-id"]=i,f=(d=Object.keys(e).filter(function(t){return void 0!==e[t]&&null!==e[t]&&""!==e[t]}).reduce(function(t,n){var o=e[n].toString();return"data-"===n.substring(0,5)?t.dataAttributes[n]=o:t.queryParams[n]=o,t},{queryParams:{},dataAttributes:{}})).queryParams,h=d.dataAttributes,{url:"".concat(u,"?").concat((c="",Object.keys(s=f).forEach(function(e){0!==c.length&&(c+="&"),c+=e+"="+s[e]}),c)),dataAttributes:h}),m=p.url,y=p.dataAttributes,v=y["data-namespace"]||"paypal",g=(l=v,window[l]);return function(e,t){var n=document.querySelector('script[src="'.concat(e,'"]'));if(null===n)return null;var o=I(e,t),r=n.cloneNode();if(delete r.dataset.uidAuto,Object.keys(r.dataset).length!==Object.keys(o.dataset).length)return null;var a=!0;return Object.keys(r.dataset).forEach(function(e){r.dataset[e]!==o.dataset[e]&&(a=!1)}),a?n:null}(m,y)&&g?t.resolve(g):(function(e,t){void 0===t&&(t=S()),w(e,t);var n=e.url,o=e.attributes;if("string"!=typeof n||0===n.length)throw Error("Invalid url.");if(void 0!==o&&"object"!=typeof o)throw Error("Expected attributes to be an object.");return new t(function(e,t){var r,a,i,s,c,l;if("u"<typeof window)return e();a=(r={url:n,attributes:o,onSuccess:function(){return e()},onError:function(){var e=Error('The script "'.concat(n,'" failed to load.'));return window.fetch?fetch(n).then(function(n){return 200===n.status&&t(e),n.text()}).then(function(e){var n;t(Error((n=e.split("/* Original Error:")[1])?n.replace(/\n/g,"").replace("*/","").trim():e))}).catch(function(e){t(e)}):t(e)}}).url,i=r.attributes,s=r.onSuccess,c=r.onError,(l=I(a,i)).onerror=c,l.onload=s,document.head.insertBefore(l,document.head.firstElementChild)})})({url:m,attributes:y},t).then(function(){var e,t=(e=v,window[e]);if(t)return t;throw Error("The window.".concat(v," global variable is not available."))})})(p.options).then(function(){e&&y({type:s.LOADING_STATUS,value:i.RESOLVED})}).catch(function(t){console.error("".concat("Failed to load the PayPal JS SDK script."," ").concat(t)),e&&y({type:s.LOADING_STATUS,value:i.REJECTED})}),function(){e=!1}}},[p.options,c,p.loadingStatus]),l.createElement(R.Provider,{value:m(m({},p),{dispatch:y})},r)}},52860:function(e,t,n){e.exports=function(e){"use strict";var t=e&&"object"==typeof e&&"default"in e?e:{default:e};
1function o(e,t,n,o){return new(n||(n=Promise))(function(r,a){function i(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?r(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(i,s)}c((o=o.apply(e,t||[])).next())})}let r={};class a{constructor(e){this.handleClick=e=>o(this,void 0,void 0,function*(){let t=this.config;if(!t)throw Error("google-pay-button: Missing configuration");let n=this.createLoadPaymentDataRequest(t);try{if(t.onClick&&t.onClick(e),e.defaultPrevented)return;let o=yield this.client.loadPaymentData(n);t.onLoadPaymentData&&t.onLoadPaymentData(o)}catch(e){"CANCELED"===e.statusCode?t.onCancel&&t.onCancel(e):t.onError?t.onError(e):console.error(e)}}),this.options=e}getElement(){return this.element}isGooglePayLoaded(){var e,t;return"google"in(window||n.g)&&!!(null==(t=null==(e=null==google?void 0:google.payments)?void 0:e.api)?void 0:t.PaymentsClient)}mount(e){var t;return o(this,void 0,void 0,function*(){if(!this.isGooglePayLoaded())try{yield function(e){let t=r[e];if(t)return t;let n=new Promise((t,n)=>{let o=document.createElement("script");o.src=e,o.async=!0;let a=()=>{t()},i=()=>{o.removeEventListener("load",a),o.removeEventListener("error",i),delete r[e],o.remove(),n(Error(`Unable to load script ${e}`))};o.addEventListener("load",a),o.addEventListener("error",i),document.body.appendChild(o)});return r[e]=n,n}("https://pay.google.com/gp/p/js/pay.js")}catch(e){return void((null==(t=this.config)?void 0:t.onError)?this.config.onError(e):console.error(e))}this.element=e,e&&(this.appendStyles(),this.config&&this.updateElement())})}unmount(){this.element=void 0}configure(e){let t;return this.config=e,this.oldInvalidationValues&&!this.isClientInvalidated(e)||(t=this.updateElement()),this.oldInvalidationValues=this.getInvalidationValues(e),null!=t?t:Promise.resolve()}createClientOptions(e){let t={environment:e.environment,merchantInfo:this.createMerchantInfo(e)};return(e.onPaymentDataChanged||e.onPaymentAuthorized)&&(t.paymentDataCallbacks={},e.onPaymentDataChanged&&(t.paymentDataCallbacks.onPaymentDataChanged=t=>e.onPaymentDataChanged(t)||{}),e.onPaymentAuthorized&&(t.paymentDataCallbacks.onPaymentAuthorized=t=>e.onPaymentAuthorized(t)||{})),t}createIsReadyToPayRequest(e){let t=e.paymentRequest;return{apiVersion:t.apiVersion,apiVersionMinor:t.apiVersionMinor,allowedPaymentMethods:t.allowedPaymentMethods,existingPaymentMethodRequired:e.existingPaymentMethodRequired}}createLoadPaymentDataRequest(e){return Object.assign(Object.assign({},e.paymentRequest),{merchantInfo:this.createMerchantInfo(e)})}createMerchantInfo(e){let t=Object.assign({},e.paymentRequest.merchantInfo);return t.softwareInfo||(t.softwareInfo={id:this.options.softwareInfoId,version:this.options.softwareInfoVersion}),t}isMounted(){return null!=this.element&&!1!==this.element.isConnected}removeButton(){if(this.element instanceof ShadowRoot||this.element instanceof Element)for(let e of Array.from(this.element.children))"STYLE"!==e.tagName&&e.remove()}updateElement(){return o(this,void 0,void 0,function*(){if(!this.isMounted())return;let e=this.getElement();if(!this.config)throw Error("google-pay-button: Missing configuration");this.removeButton();try{this.client=new google.payments.api.PaymentsClient(this.createClientOptions(this.config))}catch(e){return void(this.config.onError?this.config.onError(e):console.error(e))}let t={buttonType:this.config.buttonType,buttonColor:this.config.buttonColor,buttonRadius:this.config.buttonRadius,buttonSizeMode:this.config.buttonSizeMode,buttonLocale:this.config.buttonLocale,onClick:this.handleClick,allowedPaymentMethods:this.config.paymentRequest.allowedPaymentMethods},n=e.getRootNode();n instanceof ShadowRoot&&(t.buttonRootNode=n);let o=this.client.createButton(t);this.setClassName(e,[e.className,"not-ready"]),e.appendChild(o);let r,a=!1;try{a=(r=yield this.client.isReadyToPay(this.createIsReadyToPayRequest(this.config))).result&&!this.config.existingPaymentMethodRequired||r.result&&r.paymentMethodPresent&&this.config.existingPaymentMethodRequired||!1}catch(e){this.config.onError?this.config.onError(e):console.error(e)}
1if(this.isMounted()){if(a){try{this.client.prefetchPaymentData(this.createLoadPaymentDataRequest(this.config))}catch(e){console.log("Error with prefetch",e)}this.setClassName(e,(e.className||"").split(" ").filter(e=>e&&"not-ready"!==e))}if((this.isReadyToPay!==(null==r?void 0:r.result)||this.paymentMethodPresent!==(null==r?void 0:r.paymentMethodPresent))&&(this.isReadyToPay=!!(null==r?void 0:r.result),this.paymentMethodPresent=null==r?void 0:r.paymentMethodPresent,this.config.onReadyToPayChange)){let e={isButtonVisible:a,isReadyToPay:this.isReadyToPay};this.paymentMethodPresent&&(e.paymentMethodPresent=this.paymentMethodPresent),this.config.onReadyToPayChange(e)}}})}setClassName(e,t){let n=t.filter(e=>e).join(" ");n?e.className=n:e.removeAttribute("class")}appendStyles(){var e,t,n;if("u"<typeof document)return;let o=null==(e=this.element)?void 0:e.getRootNode(),r=`default-google-style-${this.options.cssSelector.replace(/[^\w-]+/g,"")}-${null==(t=this.config)?void 0:t.buttonLocale}`;if(o&&!(null==(n=o.getElementById)?void 0:n.call(o,r))){let e=document.createElement("style");e.id=r,e.type="text/css",e.innerHTML=` 2 ${this.options.cssSelector} { 3 display: inline-block; 4 } 5 ${this.options.cssSelector}.not-ready { 6 width: 0; 7 height: 0; 8 overflow: hidden; 9 } 10 `,o instanceof Document&&o.head?o.head.appendChild(e):o.appendChild(e)}}isClientInvalidated(e){return!this.oldInvalidationValues||this.getInvalidationValues(e).some((e,t)=>JSON.stringify(e)!==JSON.stringify(this.oldInvalidationValues[t]))}getInvalidationValues(e){var t,n;return[e.environment,e.existingPaymentMethodRequired,!!e.onPaymentDataChanged,!!e.onPaymentAuthorized,e.buttonType,e.buttonColor,e.buttonRadius,e.buttonLocale,e.buttonSizeMode,e.paymentRequest.merchantInfo.merchantId,e.paymentRequest.merchantInfo.merchantName,null==(t=e.paymentRequest.merchantInfo.softwareInfo)?void 0:t.id,null==(n=e.paymentRequest.merchantInfo.softwareInfo)?void 0:n.version,e.paymentRequest.allowedPaymentMethods]}}let i="google-pay-button-container";class s extends t.default.Component{constructor(){super(...arguments),this.manager=new a({cssSelector:`.${i}`,softwareInfoId:"@google-pay/button-react",softwareInfoVersion:"3.1.0"}),this.elementRef=t.default.createRef()}componentDidMount(){return o(this,void 0,void 0,function*(){let e=this.elementRef.current;e&&(yield this.manager.configure(this.props),yield this.manager.mount(e))})}componentWillUnmount(){this.manager.unmount()}componentDidUpdate(){this.manager.configure(this.props)}render(){return t.default.createElement("div",{ref:this.elementRef,className:[i,this.props.className].filter(e=>e).join(" "),style:this.props.style})}}return s}(n(55729))}}]);
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.