1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5021],{75021:function(e,t,n){n.d(t,{Vv:function(){return _},ch:function(){return I}});var r,a,o,i=n(67294);!function(e){e.INITIAL="initial",e.PENDING="pending",e.REJECTED="rejected",e.RESOLVED="resolved"}(r||(r={})),function(e){e.LOADING_STATUS="setLoadingStatus",e.RESET_OPTIONS="resetOptions",e.SET_BRAINTREE_INSTANCE="braintreeInstance"}(a||(a={})),function(e){e.NUMBER="number",e.CVV="cvv",e.EXPIRATION_DATE="expirationDate",e.EXPIRATION_MONTH="expirationMonth",e.EXPIRATION_YEAR="expirationYear",e.POSTAL_CODE="postalCode"}(o||(o={}));var c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},c.apply(this,arguments)};function s(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n}function u(e,t,n){if(n||2===arguments.length)for(var r,a=0,o=t.length;a<o;a++)!r&&a in t||(r||(r=Array.prototype.slice.call(t,0,a)),r[a]=t[a]);return e.concat(r||Array.prototype.slice.call(t))}"function"===typeof SuppressedError&&SuppressedError;var l="data-react-paypal-script-id",d="dataJsSdkLibrary",f="react-paypal-js",p="dataNamespace",v="dataSdkIntegrationSource",m="Failed to load the PayPal JS SDK script.",h="3.84.0",y=("https://js.braintreegateway.com/web/".concat(h,"/js/client.min.js"),"https://js.braintreegateway.com/web/".concat(h,"/js/paypal-checkout.min.js"),"paypal");function E(e){return void 0===e&&(e=y),window[e]}function b(e){var t=e.reactComponentName,n=e.sdkComponentKey,r=e.sdkRequestedComponents,a=void 0===r?"":r,o=e.sdkDataNamespace,i=void 0===o?y:o,c=n.charAt(0).toUpperCase().concat(n.substring(1)),s="Unable to render <".concat(t," /> because window.").concat(i,".").concat(c," is undefined."),u="string"===typeof a?a:a.join(",");if(!u.includes(n)){var l=[u,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(l,"'}}>`.")}return s}function N(e){var t=e,n=l;t[n];var r=s(t,[n+""]);return"react-paypal-js-".concat(function(e){for(var t="",n=0;n<e.length;n++){var r=e[n].charCodeAt(0)*n;e[n+1]&&(r+=e[n+1].charCodeAt(0)*(n-1)),t+=String.fromCharCode(97+Math.abs(r)%26)}return t}(JSON.stringify(r)))}function g(e,t){var n,o;switch(t.type){case a.LOADING_STATUS:return"object"===typeof t.value?c(c({},e),{loadingStatus:t.value.state,loadingStatusErrorMessage:t.value.message}):c(c({},e),{loadingStatus:t.value});case a.RESET_OPTIONS:return function(e){var t=self.document.querySelector("script[".concat(l,'="').concat(e,'"]'));(null===t||void 0===t?void 0:t.parentNode)&&t.parentNode.removeChild(t)}(e.options[l]),c(c({},e),{loadingStatus:r.PENDING,options:c(c((n={},n[v]=f,n),t.value),(o={},o[l]="".concat(N(t.value)),o))});case a.SET_BRAINTREE_INSTANCE:return c(c({},e),{braintreePayPalCheckoutInstance:t.value});default:return e}}var S=(0,i.createContext)(null);function w(e){if("function"===typeof(null===e||void 0===e?void 0:e.dispatch)&&0!==e.dispatch.length)return e;throw new Error("usePayPalScriptReducer must be used within a PayPalScriptProvider")}function P(){var e=w((0,i.useContext)(S));return[c(c({},e),{isInitial:e.loadingStatus===r.INITIAL,isPending:e.loadingStatus===r.PENDING,isResolved:e.loadingStatus===r.RESOLVED,isRejected:e.loadingStatus===r.REJECTED}),e.dispatch]}(0,i.createContext)({});var I=function(e){var t,n=e.className,r=void 0===n?"":n,a=e.disabled,o=void 0!==a&&a,l=e.children,d=e.forceReRender,f=void 0===d?[]:d,v=s(e,["className","disabled","children","forceReRender"]),m=o?{opacity:.38}:{},h="".concat(r," ").concat(o?"paypal-buttons-disabled":"").trim(),y=(0,i.useRef)(null),N=(0,i.useRef)(null),g=P()[0],S=g.isResolved,w=g.options,R=(0,i.useState)(null),T=R[0],k=R[1],C=(0,i.useState)(!0),O=C[0],j=C[1],A=(0,i.useState)(null)[1];function D(){null!==N.current&&N.current.close().catch((function(){}))}return(null===(t=N.current)||void 0===t?void 0:t.updateProps)&&N.current.updateProps({message:v.message}),(0,i.useEffect)((function(){if(!1===S)return D;var e=E(w.dataNamespace);if(void 0===e||void 0===e.Buttons)return A((function(){throw new Error(b({reactComponentName:I.displayName,sdkComponentKey:"buttons",sdkRequestedComponents:w.components,sdkDataNamespace:w[p]}
1))})),D;try{N.current=e.Buttons(c(c({},v),{onInit:function(e,t){k(t),"function"===typeof v.onInit&&v.onInit(e,t)}}))}catch(t){return A((function(){throw new Error("Failed to render <PayPalButtons /> component. Failed to initialize: ".concat(t))}))}return!1===N.current.isEligible()?(j(!1),D):y.current?(N.current.render(y.current).catch((function(e){null!==y.current&&0!==y.current.children.length&&A((function(){throw new Error("Failed to render <PayPalButtons /> component. ".concat(e))}))})),D):D}),u(u([S],f,!0),[v.fundingSource],!1)),(0,i.useEffect)((function(){null!==T&&(!0===o?T.disable().catch((function(){})):T.enable().catch((function(){})))}),[o,T]),i.createElement(i.Fragment,null,O?i.createElement("div",{ref:y,style:m,className:h}):l)};function R(e){var t="";return Object.keys(e).forEach((function(n){0!==t.length&&(t+="&"),t+=n+"="+e[n]})),t}function T(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 k(e,t){if(void 0===t&&(t=Promise),j(e,t),"undefined"===typeof document)return t.resolve(null);var n=function(e){var t="sandbox"===e.environment?"https://www.sandbox.paypal.com/sdk/js":"https://www.paypal.com/sdk/js";delete e.environment,e.sdkBaseUrl&&(t=e.sdkBaseUrl,delete e.sdkBaseUrl);var n=e,r=Object.keys(n).filter((function(e){return"undefined"!==typeof n[e]&&null!==n[e]&&""!==n[e]})).reduce((function(e,t){var r=n[t].toString();return"data"===(t=function(e){var t=function(e,t){return(t?"-":"")+e.toLowerCase()};return e.replace(/[A-Z]+(?![a-z])|[A-Z]/g,t)}(t)).substring(0,4)||"crossorigin"===t?e.attributes[t]=r:e.queryParams[t]=r,e}),{queryParams:{},attributes:{}}),a=r.queryParams,o=r.attributes;return a["merchant-id"]&&-1!==a["merchant-id"].indexOf(",")&&(o["data-merchant-id"]=a["merchant-id"],a["merchant-id"]="*"),{url:"".concat(t,"?").concat(R(a)),attributes:o}}(e),r=n.url,a=n.attributes,o=a["data-namespace"]||"paypal",i=O(o);return a["data-js-sdk-library"]||(a["data-js-sdk-library"]="paypal-js"),function(e,t){var n=document.querySelector('script[src="'.concat(e,'"]'));if(null===n)return null;var r=T(e,t),a=n.cloneNode();if(delete a.dataset.uidAuto,Object.keys(a.dataset).length!==Object.keys(r.dataset).length)return null;var o=!0;return Object.keys(a.dataset).forEach((function(e){a.dataset[e]!==r.dataset[e]&&(o=!1)})),o?n:null}(r,a)&&i?t.resolve(i):C({url:r,attributes:a},t).then((function(){var e=O(o);if(e)return e;throw new Error("The window.".concat(o," global variable is not available."))}))}function C(e,t){void 0===t&&(t=Promise),j(e,t);var n=e.url,r=e.attributes;if("string"!==typeof n||0===n.length)throw new Error("Invalid url.");if("undefined"!==typeof r&&"object"!==typeof r)throw new Error("Expected attributes to be an object.");return new t((function(e,t){if("undefined"===typeof document)return e();!function(e){var t=e.url,n=e.attributes,r=e.onSuccess,a=e.onError,o=T(t,n);o.onerror=a,o.onload=r,document.head.insertBefore(o,document.head.firstElementChild)}({url:n,attributes:r,onSuccess:function(){return e()},onError:function(){var e=new Error('The script "'.concat(n,'" failed to load. Check the HTTP status code and response body in DevTools to learn more.'));return t(e)}})}))}function O(e){return window[e]}function j(e,t){if("object"!==typeof e||null===e)throw new Error("Expected an options object.");var n=e.environment;if(n&&"production"!==n&&"sandbox"!==n)throw new Error('The `environment` option must be either "production" or "sandbox".');if("undefined"!==typeof t&&"function"!==typeof t)throw new Error("Expected PromisePonyfill to be a function.")}I.displayName="PayPalButtons";var A=function(e){var t=e.className,n=void 0===t?"":t,r=e.children,a=s(e,["className","children"]),o=P()[0],u=o.isResolved,l=o.options,d=(0,i.useRef)(null),f=(0,i.useState)(!0),v=f[0],m=f[1],h=(0,i.useState)(null)[1];return(0,i.useEffect)((function(){if(!1!==u){var e=E(l[p]);if(void 0===e||void 0===e.Marks)return h((function(){throw new Error(b({reactComponentName:A.dis
1playName,sdkComponentKey:"marks",sdkRequestedComponents:l.components,sdkDataNamespace:l[p]}))}));!function(e){var t=d.current;if(!t||!e.isEligible())return m(!1);t.firstChild&&t.removeChild(t.firstChild),e.render(t).catch((function(e){null!==t&&0!==t.children.length&&h((function(){throw new Error("Failed to render <PayPalMarks /> component. ".concat(e))}))}))}(e.Marks(c({},a)))}}),[u,a.fundingSource]),i.createElement(i.Fragment,null,v?i.createElement("div",{ref:d,className:n}):r)};A.displayName="PayPalMarks";var D=function(e){var t=e.className,n=void 0===t?"":t,r=e.forceReRender,a=void 0===r?[]:r,o=s(e,["className","forceReRender"]),l=P()[0],d=l.isResolved,f=l.options,v=(0,i.useRef)(null),m=(0,i.useRef)(null),h=(0,i.useState)(null)[1];return(0,i.useEffect)((function(){if(!1!==d){var e=E(f[p]);if(void 0===e||void 0===e.Messages)return h((function(){throw new Error(b({reactComponentName:D.displayName,sdkComponentKey:"messages",sdkRequestedComponents:f.components,sdkDataNamespace:f[p]}))}));m.current=e.Messages(c({},o)),m.current.render(v.current).catch((function(e){null!==v.current&&0!==v.current.children.length&&h((function(){throw new Error("Failed to render <PayPalMessages /> component. ".concat(e))}))}))}}),u([d],a,!0)),i.createElement("div",{ref:v,className:n})};D.displayName="PayPalMessages";var _=function(e){var t,n=e.options,o=void 0===n?{clientId:"test"}:n,s=e.children,u=e.deferLoading,p=void 0!==u&&u,h=(0,i.useReducer)(g,{options:c(c({},o),(t={},t[d]=f,t[v]=f,t[l]="".concat(N(o)),t)),loadingStatus:p?r.INITIAL:r.PENDING}),y=h[0],E=h[1];return(0,i.useEffect)((function(){if(!1===p&&y.loadingStatus===r.INITIAL)return E({type:a.LOADING_STATUS,value:r.PENDING});if(y.loadingStatus===r.PENDING){var e=!0;return k(y.options).then((function(){e&&E({type:a.LOADING_STATUS,value:r.RESOLVED})})).catch((function(t){console.error("".concat(m," ").concat(t)),e&&E({type:a.LOADING_STATUS,value:{state:r.REJECTED,message:String(t)}})})),function(){e=!1}}}),[y.options,p,y.loadingStatus]),i.createElement(S.Provider,{value:c(c({},y),{dispatch:E})},s)};function x(){}(0,i.createContext)({cardFieldsForm:null,fields:{},registerField:x,unregisterField:x})}}]);
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.