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AA,EAC/BjJ,KAAA,CAAA/E,CAAA,CAAAA,CAAA,IAAAyE,CAAA,GACKuB,QAAA,CAAAA,CAAA,CACF,EACH,CAAAW,CAAA,EACA,CA4RqW","sources":["webpack://_N_E/./node_modules/.pnpm/@paypal+react-paypal-js@8.1.0_react-dom@18.2.0_react@18.2.0/node_modules/@paypal/react-paypal-js/dist/esm/react-paypal-js.js","webpack://_N_E/"],"sourcesContent":["/*!\n * react-paypal-js v8.1.0 (2023-07-03T21:16:30.798Z)\n * Copyright 2020-present, PayPal, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport React, { createContext, useContext, useRef, useState, useEffect, useReducer } from 'react';\n/**\n * Enum for the SDK script resolve status,\n *\n * @enum {string}\n */\n\nvar SCRIPT_LOADING_STATE;\n\n(function (SCRIPT_LOADING_STATE) {\n SCRIPT_LOADING_STATE[\"INITIAL\"] = \"initial\";\n SCRIPT_LOADING_STATE[\"PENDING\"] = \"pending\";\n SCRIPT_LOADING_STATE[\"REJECTED\"] = \"rejected\";\n SCRIPT_LOADING_STATE[\"RESOLVED\"] = \"resolved\";\n})(SCRIPT_LOADING_STATE || (SCRIPT_LOADING_STATE = {}));\n/**\n * Enum for the PayPalScriptProvider context dispatch actions\n *\n * @enum {string}\n */\n\n\nvar DISPATCH_ACTION;\n\n(function (DISPATCH_ACTION) {\n DISPATCH_ACTION[\"LOADING_STATUS\"] = \"setLoadingStatus\";\n DISPATCH_ACTION[\"RESET_OPTIONS\"] = \"resetOptions\";\n DISPATCH_ACTION[\"SET_BRAINTREE_INSTANCE\"] = \"braintreeInstance\";\n})(DISPATCH_ACTION || (DISPATCH_ACTION = {}));\n/**\n * Enum for all the available hosted fields\n *\n * @enum {string}\n */\n\n\nvar PAYPAL_HOSTED_FIELDS_TYPES;\n\n(function (PAYPAL_HOSTED_FIELDS_TYPES) {\n PAYPAL_HOSTED_FIELDS_TYPES[\"NUMBER\"] = \"number\";\n PAYPAL_HOSTED_FIELDS_TYPES[\"CVV\"] = \"cvv\";\n PAYPAL_HOSTED_FIELDS_TYPES[\"EXPIRATION_DATE\"] = \"expirationDate\";\n PAYPAL_HOSTED_FIELDS_TYPES[\"EXPIRATION_MONTH\"] = \"expirationMonth\";\n PAYPAL_HOSTED_FIELDS_TYPES[\"EXPIRATION_YEAR\"] = \"expirationYear\";\n PAYPAL_HOSTED_FIELDS_TYPES[\"POSTAL_CODE\"] = \"postalCode\";\n})(PAYPAL_HOSTED_FIELDS_TYPES || (PAYPAL_HOSTED_FIELDS_TYPES = {}));\n\nvar __assign = function () {\n __assign = Object.assign || function __assign(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\n }\n\n return t;\n };\n\n return __assign.apply(this, arguments);\n};\n\nfunction __rest(s, e) {\n var t = {};\n\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n}\n\nfunction __spreadArray(to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n}\n/*********************************************\n * Common reference to the script identifier *\n *********************************************/\n// keep this script id value in kebab-case format\n\n\nvar SCRIPT_ID = \"data-react-paypal-script-id\";\nvar SDK_SETTINGS = {\n DATA_CLIENT_TOKEN: \"dataClientToken\",\n DATA_USER_ID_TOKEN: \"dataUserIdToken\",\n DATA_SDK_INTEGRATION_SOURCE: \"dataSdkIntegrationSource\",\n DATA_SDK_INTEGRATION_SOURCE_VALUE: \"react-paypal-js\",\n DATA_NAMESPACE: \"dataNamespace\"\n};\nvar LOAD_SCRIPT_ERROR = \"Failed to load the PayPal JS SDK script.\";\n/****************************\n * Braintree error messages *\n ****************************/\n\nvar EMPTY_BRAINTREE_AUTHORIZATION_ERROR_MESSAGE = \"Invalid authorization data. Use dataClientToken or dataUserIdToken to authorize.\";\nvar braintreeVersion = \"3.84.0\";\nvar BRAINTREE_SOURCE = \"https://js.braintreegateway.com/web/\".concat(braintreeVersion, \"/js/client.min.js\");\nvar BRAINTREE_PAYPAL_CHECKOUT_SOURCE = \"https://js.braintreegateway.com/web/\".concat(braintreeVersion, \"/js/paypal-checkout.min.js\");\n/*********************\n * PayPal namespaces *\n *********************/\n\nvar DEFAULT_PAYPAL_NAMESPACE = \"paypal\";\nvar DEFAULT_BRAINTREE_NAMESPACE = \"braintree\";\n/*****************\n * Hosted Fields *\n *****************/\n\nvar HOSTED_FIELDS_CHILDREN_ERROR = \"To use HostedFields you must use it with at least 3 children with types: [number, cvv, expirationDate] includes\";\nvar HOSTED_FIELDS_DUPLICATE_CHILDREN_ERROR = \"Cannot use duplicate HostedFields as children\";\n/*******************\n * Script Provider *\n *******************/\n\nvar SCRIPT_PROVIDER_REDUCER_ERROR = \"usePayPalScriptReducer must be used within a PayPalScriptProvider\";\n/**\n * Get the namespace from the window in the browser\n * this is useful to get the paypal object from window\n * after load PayPal SDK script\n *\n * @param namespace the name space to return\n * @returns the namespace if exists or undefined otherwise\n */\n\nfunction getPayPalWindowNamespace$1(namespace) {\n if (namespace === void 0) {\n namespace = DEFAULT_PAYPAL_NAMESPACE;\n } // eslint-disable-next-line @typescript-eslint/no-explicit-any\n\n\n return window[namespace];\n}\n/**\n * Get a namespace from the window in the browser\n * this is useful to get the braintree from window\n * after load Braintree script\n *\n * @param namespace the name space to return\n * @returns the namespace if exists or undefined otherwise\n */\n\n\nfunction getBraintreeWindowNamespace(namespace) {\n if (namespace === void 0) {\n namespace = DEFAULT_BRAINTREE_NAMESPACE;\n } // eslint-disable-next-line @typescript-eslint/no-explicit-any\n\n\n return window[namespace];\n}\n/**\n * Creates a string hash code based on the string argument\n *\n * @param str the source input string to hash\n * @returns string hash code\n */\n\n\nfunction hashStr(str) {\n var hash = \"\";\n\n for (var i = 0; i < str.length; i++) {\n var total = str[i].charCodeAt(0) * i;\n\n if (str[i + 1]) {\n total += str[i + 1].charCodeAt(0) * (i - 1);\n }\n\n hash += String.fromCharCode(97 + Math.abs(total) % 26);\n }\n\n return hash;\n}\n\nfunction generateErrorMessage(_a) {\n var reactComponentName = _a.reactComponentName,\n sdkComponentKey = _a.sdkComponentKey,\n _b = _a.sdkRequestedComponents,\n sdkRequestedComponents = _b === void 0 ? \"\" : _b,\n _c = _a.sdkDataNamespace,\n sdkDataNamespace = _c === void 0 ? DEFAULT_PAYPAL_NAMESPACE : _c;\n var requiredOptionCapitalized = sdkComponentKey.charAt(0).toUpperCase().concat(sdkComponentKey.substring(1));\n var errorMessage = \"Unable to render <\".concat(reactComponentName, \" /> because window.\").concat(sdkDataNamespace, \".\").concat(requiredOptionCapitalized, \" is undefined.\"); // The JS SDK only loads the buttons component by default.\n // All other components like messages and marks must be requested using the \"components\" query parameter\n\n if (!sdkRequestedComponents.includes(sdkComponentKey)) {\n var expectedComponents = [sdkRequestedComponents, sdkComponentKey].filter(Boolean).join();\n errorMessage += \"\\nTo fix the issue, add '\".concat(sdkComponentKey, \"' to the list of components passed to the parent PayPalScriptProvider:\") + \"\\n``.\");\n }\n\n return errorMessage;\n}\n/**\n * Generate a new random identifier for react-paypal-js\n *\n * @returns the {@code string} containing the random library name\n */\n\n\nfunction getScriptID(options) {\n // exclude the data-react-paypal-script-id value from the options hash\n var _a = options,\n _b = SCRIPT_ID;\n _a[_b];\n\n var paypalScriptOptions = __rest(_a, [_b + \"\"]);\n\n return \"react-paypal-js-\".concat(hashStr(JSON.stringify(paypalScriptOptions)));\n}\n/**\n * Destroy the PayPal SDK from the document page\n *\n * @param reactPayPalScriptID the script identifier\n */\n\n\nfunction destroySDKScript(reactPayPalScriptID) {\n var scriptNode = self.document.querySelector(\"script[\".concat(SCRIPT_ID, \"=\\\"\").concat(reactPayPalScriptID, \"\\\"]\"));\n\n if (scriptNode === null || scriptNode === void 0 ? void 0 : scriptNode.parentNode) {\n scriptNode.parentNode.removeChild(scriptNode);\n }\n}\n/**\n * Reducer function to handle complex state changes on the context\n *\n * @param state the current state on the context object\n * @param action the action to be executed on the previous state\n * @returns a the same state if the action wasn't found, or a new state otherwise\n */\n\n\nfunction scriptReducer(state, action) {\n var _a;\n\n switch (action.type) {\n case DISPATCH_ACTION.LOADING_STATUS:\n if (typeof action.value === \"object\") {\n return __assign(__assign({}, state), {\n loadingStatus: action.value.state,\n loadingStatusErrorMessage: action.value.message\n });\n }\n\n return __assign(__assign({}, state), {\n loadingStatus: action.value\n });\n\n case DISPATCH_ACTION.RESET_OPTIONS:\n // destroy existing script to make sure only one script loads at a time\n destroySDKScript(state.options[SCRIPT_ID]);\n return __assign(__assign({}, state), {\n loadingStatus: SCRIPT_LOADING_STATE.PENDING,\n options: __assign(__assign({}, action.value), (_a = {}, _a[SCRIPT_ID] = \"\".concat(getScriptID(action.value)), _a[SDK_SETTINGS.DATA_SDK_INTEGRATION_SOURCE] = SDK_SETTINGS.DATA_SDK_INTEGRATION_SOURCE_VALUE, _a))\n });\n\n case DISPATCH_ACTION.SET_BRAINTREE_INSTANCE:\n return __assign(__assign({}, state), {\n braintreePayPalCheckoutInstance: action.value\n });\n\n default:\n {\n return state;\n }\n }\n} // Create the React context to use in the script provider component\n\n\nvar ScriptContext = createContext(null);\n/**\n * Check if the context is valid and ready to dispatch actions.\n *\n * @param scriptContext the result of connecting to the context provider\n * @returns strict context avoiding null values in the type\n */\n\nfunction validateReducer(scriptContext) {\n if (typeof (scriptContext === null || scriptContext === void 0 ? void 0 : scriptContext.dispatch) === \"function\" && scriptContext.dispatch.length !== 0) {\n return scriptContext;\n }\n\n throw new Error(SCRIPT_PROVIDER_REDUCER_ERROR);\n}\n/**\n * Check if the dataClientToken or the dataUserIdToken are\n * set in the options of the context.\n * @type dataClientToken is use to pass a client token\n * @type dataUserIdToken is use to pass a client tokenization key\n *\n * @param scriptContext the result of connecting to the context provider\n * @throws an {@link Error} if both dataClientToken and the dataUserIdToken keys are null or undefined\n * @returns strict context if one of the keys are defined\n */\n\n\nvar validateBraintreeAuthorizationData = function (scriptContext) {\n var _a, _b;\n\n if (!((_a = scriptContext === null || scriptContext === void 0 ? void 0 : scriptContext.options) === null || _a === void 0 ? void 0 : _a[SDK_SETTINGS.DATA_CLIENT_TOKEN]) && !((_b = scriptContext === null || scriptContext === void 0 ? void 0 : scriptContext.options) === null || _b === void 0 ? void 0 : _b[SDK_SETTINGS.DATA_USER_ID_TOKEN])) {\n throw new Error(EMPTY_BRAINTREE_AUTHORIZATION_ERROR_MESSAGE);\n }\n\n return scriptContext;\n};\n/**\n * Custom hook to get access to the Script context and\n * dispatch actions to modify the state on the {@link ScriptProvider} component\n *\n * @returns a tuple containing the state of the context and\n * a dispatch function to modify the state\n */\n\n\nfunction usePayPalScriptReducer() {\n var scriptContext = validateReducer(useContext(ScriptContext));\n\n var derivedStatusContext = __assign(__assign({}, scriptContext), {\n isInitial: scriptContext.loadingStatus === SCRIPT_LOADING_STATE.INITIAL,\n isPending: scriptContext.loadingStatus === SCRIPT_LOADING_STATE.PENDING,\n isResolved: scriptContext.loadingStatus === SCRIPT_LOADING_STATE.RESOLVED,\n isRejected: scriptContext.loadingStatus === SCRIPT_LOADING_STATE.REJECTED\n });\n\n return [derivedStatusContext, scriptContext.dispatch];\n}\n/**\n * Custom hook to get access to the ScriptProvider context\n *\n * @returns the latest state of the context\n */\n\n\nfunction useScriptProviderContext() {\n var scriptContext = validateBraintreeAuthorizationData(validateReducer(useContext(ScriptContext)));\n return [scriptContext, scriptContext.dispatch];\n} // Create the React context to use in the PayPal hosted fields provider\n\n\nvar PayPalHostedFieldsContext = createContext({});\n/**\n * Custom hook to get access to the PayPal Hosted Fields instance.\n * The instance represent the returned object after the render process\n * With this object a user can submit the fields and dynamically modify the cards\n *\n * @returns the hosted fields instance if is available in the component\n */\n\nfunction usePayPalHostedFields() {\n return useContext(PayPalHostedFieldsContext);\n}\n/**\nThis `` component supports rendering [buttons](https://developer.paypal.com/docs/business/javascript-sdk/javascript-sdk-reference/#buttons) for PayPal, Venmo, and alternative payment methods.\nIt relies on the `` parent component for managing state related to loading the JS SDK script.\n*/\n\n\nvar PayPalButtons = function (_a) {\n var _b = _a.className,\n className = _b === void 0 ? \"\" : _b,\n _c = _a.disabled,\n disabled = _c === void 0 ? false : _c,\n children = _a.children,\n _d = _a.forceReRender,\n forceReRender = _d === void 0 ? [] : _d,\n buttonProps = __rest(_a, [\"className\", \"disabled\", \"children\", \"forceReRender\"]);\n\n var isDisabledStyle = disabled ? {\n opacity: 0.38\n } : {};\n var classNames = \"\".concat(className, \" \").concat(disabled ? \"paypal-buttons-disabled\" : \"\").trim();\n var buttonsContainerRef = useRef(null);\n var buttons = useRef(null);\n var _e = usePayPalScriptReducer()[0],\n isResolved = _e.isResolved,\n options = _e.options;\n\n var _f = useState(null),\n initActions = _f[0],\n setInitActions = _f[1];\n\n var _g = useState(true),\n isEligible = _g[0],\n setIsEligible = _g[1];\n\n var _h = useState(null),\n setErrorState = _h[1];\n\n function closeButtonsComponent() {\n if (buttons.current !== null) {\n buttons.current.close().catch(function () {// ignore errors when closing the component\n });\n }\n } // useEffect hook for rendering the buttons\n\n\n useEffect(function () {\n // verify the sdk script has successfully loaded\n if (isResolved === false) {\n return closeButtonsComponent;\n }\n\n var paypalWindowNamespace = getPayPalWindowNamespace$1(options.dataNamespace); // verify dependency on window object\n\n if (paypalWindowNamespace === undefined || paypalWindowNamespace.Buttons === undefined) {\n setErrorState(function () {\n throw new Error(generateErrorMessage({\n reactComponentName: PayPalButtons.displayName,\n sdkComponentKey: \"buttons\",\n sdkRequestedComponents: options.components,\n sdkDataNamespace: options[SDK_SETTINGS.DATA_NAMESPACE]\n }));\n });\n return closeButtonsComponent;\n }\n\n var decoratedOnInit = function (data, actions) {\n setInitActions(actions);\n\n if (typeof buttonProps.onInit === \"function\") {\n buttonProps.onInit(data, actions);\n }\n };\n\n try {\n buttons.current = paypalWindowNamespace.Buttons(__assign(__assign({}, buttonProps), {\n onInit: decoratedOnInit\n }));\n } catch (err) {\n return setErrorState(function () {\n throw new Error(\"Failed to render component. Failed to initialize: \".concat(err));\n });\n } // only render the button when eligible\n\n\n if (buttons.current.isEligible() === false) {\n setIsEligible(false);\n return closeButtonsComponent;\n }\n\n if (!buttonsContainerRef.current) {\n return closeButtonsComponent;\n }\n\n buttons.current.render(buttonsContainerRef.current).catch(function (err) {\n // component failed to render, possibly because it was closed or destroyed.\n if (buttonsContainerRef.current === null || buttonsContainerRef.current.children.length === 0) {\n // paypal buttons container is no longer in the DOM, we can safely ignore the error\n return;\n } // paypal buttons container is still in the DOM\n\n\n setErrorState(function () {\n throw new Error(\"Failed to render component. \".concat(err));\n });\n });\n return closeButtonsComponent; // eslint-disable-next-line react-hooks/exhaustive-deps\n }, __spreadArray(__spreadArray([isResolved], forceReRender, true), [buttonProps.fundingSource], false)); // useEffect hook for managing disabled state\n\n useEffect(function () {\n if (initActions === null) {\n return;\n }\n\n if (disabled === true) {\n initActions.disable().catch(function () {// ignore errors when disabling the component\n });\n } else {\n initActions.enable().catch(function () {// ignore errors when enabling the component\n });\n }\n }, [disabled, initActions]);\n return React.createElement(React.Fragment, null, isEligible ? React.createElement(\"div\", {\n ref: buttonsContainerRef,\n style: isDisabledStyle,\n className: classNames\n }) : children);\n};\n\nPayPalButtons.displayName = \"PayPalButtons\";\n\nfunction findScript(url, attributes) {\n var currentScript = document.querySelector(\"script[src=\\\"\".concat(url, \"\\\"]\"));\n if (currentScript === null) return null;\n var nextScript = createScriptElement(url, attributes);\n var currentScriptClone = currentScript.cloneNode();\n delete currentScriptClone.dataset.uidAuto;\n\n if (Object.keys(currentScriptClone.dataset).length !== Object.keys(nextScript.dataset).length) {\n return null;\n }\n\n var isExactMatch = true;\n Object.keys(currentScriptClone.dataset).forEach(function (key) {\n if (currentScriptClone.dataset[key] !== nextScript.dataset[key]) {\n isExactMatch = false;\n }\n });\n return isExactMatch ? currentScript : null;\n}\n\nfunction insertScriptElement(_a) {\n var url = _a.url,\n attributes = _a.attributes,\n onSuccess = _a.onSuccess,\n onError = _a.onError;\n var newScript = createScriptElement(url, attributes);\n newScript.onerror = onError;\n newScript.onload = onSuccess;\n document.head.insertBefore(newScript, document.head.firstElementChild);\n}\n\nfunction processOptions(options) {\n var sdkBaseUrl = \"https://www.paypal.com/sdk/js\";\n\n if (options.sdkBaseUrl) {\n sdkBaseUrl = options.sdkBaseUrl;\n delete options.sdkBaseUrl;\n }\n\n var optionsWithStringIndex = options;\n\n var _a = Object.keys(optionsWithStringIndex).filter(function (key) {\n return typeof optionsWithStringIndex[key] !== \"undefined\" && optionsWithStringIndex[key] !== null && optionsWithStringIndex[key] !== \"\";\n }).reduce(function (accumulator, key) {\n var value = optionsWithStringIndex[key].toString();\n key = camelCaseToKebabCase(key);\n\n if (key.substring(0, 4) === \"data\") {\n accumulator.dataAttributes[key] = value;\n } else {\n accumulator.queryParams[key] = value;\n }\n\n return accumulator;\n }, {\n queryParams: {},\n dataAttributes: {}\n }),\n queryParams = _a.queryParams,\n dataAttributes = _a.dataAttributes;\n\n if (queryParams[\"merchant-id\"] && queryParams[\"merchant-id\"].indexOf(\",\") !== -1) {\n dataAttributes[\"data-merchant-id\"] = queryParams[\"merchant-id\"];\n queryParams[\"merchant-id\"] = \"*\";\n }\n\n return {\n url: \"\".concat(sdkBaseUrl, \"?\").concat(objectToQueryString(queryParams)),\n dataAttributes: dataAttributes\n };\n}\n\nfunction camelCaseToKebabCase(str) {\n var replacer = function (match, indexOfMatch) {\n return (indexOfMatch ? \"-\" : \"\") + match.toLowerCase();\n };\n\n return str.replace(/[A-Z]+(?![a-z])|[A-Z]/g, replacer);\n}\n\nfunction objectToQueryString(params) {\n var queryString = \"\";\n Object.keys(params).forEach(function (key) {\n if (queryString.length !== 0) queryString += \"&\";\n queryString += key + \"=\" + params[key];\n });\n return queryString;\n}\n\nfunction parseErrorMessage(message) {\n var originalErrorText = message.split(\"/* Original Error:\")[1];\n return originalErrorText ? originalErrorText.replace(/\\n/g, \"\").replace(\"*/\", \"\").trim() : message;\n}\n\nfunction createScriptElement(url, attributes) {\n if (attributes === void 0) {\n attributes = {};\n }\n\n var newScript = document.createElement(\"script\");\n newScript.src = url;\n Object.keys(attributes).forEach(function (key) {\n newScript.setAttribute(key, attributes[key]);\n\n if (key === \"data-csp-nonce\") {\n newScript.setAttribute(\"nonce\", attributes[\"data-csp-nonce\"]);\n }\n });\n return newScript;\n}\n\nfunction loadScript(options, PromisePonyfill) {\n if (PromisePonyfill === void 0) {\n PromisePonyfill = Promise;\n }\n\n validateArguments(options, PromisePonyfill);\n if (typeof document === \"undefined\") return PromisePonyfill.resolve(null);\n\n var _a = processOptions(options),\n url = _a.url,\n dataAttributes = _a.dataAttributes;\n\n var namespace = dataAttributes[\"data-namespace\"] || \"paypal\";\n var existingWindowNamespace = getPayPalWindowNamespace(namespace);\n\n if (findScript(url, dataAttributes) && existingWindowNamespace) {\n return PromisePonyfill.resolve(existingWindowNamespace);\n }\n\n return loadCustomScript({\n url: url,\n attributes: dataAttributes\n }, PromisePonyfill).then(function () {\n var newWindowNamespace = getPayPalWindowNamespace(namespace);\n\n if (newWindowNamespace) {\n return newWindowNamespace;\n }\n\n throw new Error(\"The window.\".concat(namespace, \" global variable is not available.\"));\n });\n}\n\nfunction loadCustomScript(options, PromisePonyfill) {\n if (PromisePonyfill === void 0) {\n PromisePonyfill = Promise;\n }\n\n validateArguments(options, PromisePonyfill);\n var url = options.url,\n attributes = options.attributes;\n\n if (typeof url !== \"string\" || url.length === 0) {\n throw new Error(\"Invalid url.\");\n }\n\n if (typeof attributes !== \"undefined\" && typeof attributes !== \"object\") {\n throw new Error(\"Expected attributes to be an object.\");\n }\n\n return new PromisePonyfill(function (resolve, reject) {\n if (typeof document === \"undefined\") return resolve();\n insertScriptElement({\n url: url,\n attributes: attributes,\n onSuccess: function () {\n return resolve();\n },\n onError: function () {\n var defaultError = new Error(\"The script \\\"\".concat(url, \"\\\" failed to load.\"));\n\n if (!window.fetch) {\n return reject(defaultError);\n }\n\n return fetch(url).then(function (response) {\n if (response.status === 200) {\n reject(defaultError);\n }\n\n return response.text();\n }).then(function (message) {\n var parseMessage = parseErrorMessage(message);\n reject(new Error(parseMessage));\n }).catch(function (err) {\n reject(err);\n });\n }\n });\n });\n}\n\nfunction getPayPalWindowNamespace(namespace) {\n return window[namespace];\n}\n\nfunction validateArguments(options, PromisePonyfill) {\n if (typeof options !== \"object\" || options === null) {\n throw new Error(\"Expected an options object.\");\n }\n\n if (typeof PromisePonyfill !== \"undefined\" && typeof PromisePonyfill !== \"function\") {\n throw new Error(\"Expected PromisePonyfill to be a function.\");\n }\n}\n/**\n * Simple check to determine if the Braintree is a valid namespace.\n *\n * @param braintreeSource the source {@link BraintreeNamespace}\n * @returns a boolean representing if the namespace is valid.\n */\n\n\nvar isValidBraintreeNamespace = function (braintreeSource) {\n var _a, _b;\n\n if (typeof ((_a = braintreeSource === null || braintreeSource === void 0 ? void 0 : braintreeSource.client) === null || _a === void 0 ? void 0 : _a.create) !== \"function\" && typeof ((_b = braintreeSource === null || braintreeSource === void 0 ? void 0 : braintreeSource.paypalCheckout) === null || _b === void 0 ? void 0 : _b.create) !== \"function\") {\n throw new Error(\"The braintreeNamespace property is not a valid BraintreeNamespace type.\");\n }\n\n return true;\n};\n/**\n * Use `actions.braintree` to provide an interface for the paypalCheckoutInstance\n * through the createOrder, createBillingAgreement and onApprove callbacks\n *\n * @param braintreeButtonProps the component button options\n * @returns a new copy of the component button options casted as {@link PayPalButtonsComponentProps}\n */\n\n\nvar decorateActions = function (buttonProps, payPalCheckoutInstance) {\n var createOrderRef = buttonProps.createOrder;\n var createBillingAgreementRef = buttonProps.createBillingAgreement;\n var onApproveRef = buttonProps.onApprove;\n\n if (typeof createOrderRef === \"function\") {\n buttonProps.createOrder = function (data, actions) {\n return createOrderRef(data, __assign(__assign({}, actions), {\n braintree: payPalCheckoutInstance\n }));\n };\n }\n\n if (typeof createBillingAgreementRef === \"function\") {\n buttonProps.createBillingAgreement = function (data, actions) {\n return createBillingAgreementRef(data, __assign(__assign({}, actions), {\n braintree: payPalCheckoutInstance\n }));\n };\n }\n\n if (typeof onApproveRef === \"function\") {\n buttonProps.onApprove = function (data, actions) {\n return onApproveRef(data, __assign(__assign({}, actions), {\n braintree: payPalCheckoutInstance\n }));\n };\n }\n\n return __assign({}, buttonProps);\n};\n/**\n * Get the Braintree namespace from the component props.\n * If the prop `braintreeNamespace` is undefined will try to load it from the CDN.\n * This function allows users to set the braintree manually on the `BraintreePayPalButtons` component.\n *\n * Use case can be for example legacy sites using AMD/UMD modules,\n * trying to integrate the `BraintreePayPalButtons` component.\n * If we attempt to load the Braintree from the CDN won't define the braintree namespace.\n * This happens because the braintree script is an UMD module.\n * After detecting the AMD on the global scope will create an anonymous module using `define`\n * and the `BraintreePayPalButtons` won't be able to get access to the `window.braintree` namespace\n * from the global context.\n *\n * @param braintreeSource the source {@link BraintreeNamespace}\n * @returns the {@link BraintreeNamespace}\n */\n\n\nvar getBraintreeNamespace = function (braintreeSource) {\n if (braintreeSource && isValidBraintreeNamespace(braintreeSource)) {\n return Promise.resolve(braintreeSource);\n }\n\n return Promise.all([loadCustomScript({\n url: BRAINTREE_SOURCE\n }), loadCustomScript({\n url: BRAINTREE_PAYPAL_CHECKOUT_SOURCE\n })]).then(function () {\n return getBraintreeWindowNamespace();\n });\n};\n/**\nThis `` component renders the [Braintree PayPal Buttons](https://developer.paypal.com/braintree/docs/guides/paypal/overview) for Braintree Merchants.\nIt relies on the `` parent component for managing state related to loading the JS SDK script.\n\nNote: You are able to make your integration using the client token or using the tokenization key.\n\n- To use the client token integration set the key `dataClientToken` in the `PayPayScriptProvider` component's options.\n- To use the tokenization key integration set the key `dataUserIdToken` in the `PayPayScriptProvider` component's options.\n*/\n\n\nvar BraintreePayPalButtons = function (_a) {\n var _b = _a.className,\n className = _b === void 0 ? \"\" : _b,\n _c = _a.disabled,\n disabled = _c === void 0 ? false : _c,\n children = _a.children,\n _d = _a.forceReRender,\n forceReRender = _d === void 0 ? [] : _d,\n braintreeNamespace = _a.braintreeNamespace,\n merchantAccountId = _a.merchantAccountId,\n buttonProps = __rest(_a, [\"className\", \"disabled\", \"children\", \"forceReRender\", \"braintreeNamespace\", \"merchantAccountId\"]);\n\n var _e = useState(null),\n setErrorState = _e[1];\n\n var _f = useScriptProviderContext(),\n providerContext = _f[0],\n dispatch = _f[1];\n\n useEffect(function () {\n getBraintreeNamespace(braintreeNamespace).then(function (braintree) {\n var clientTokenizationKey = providerContext.options[SDK_SETTINGS.DATA_USER_ID_TOKEN];\n var clientToken = providerContext.options[SDK_SETTINGS.DATA_CLIENT_TOKEN];\n return braintree.client.create({\n authorization: clientTokenizationKey || clientToken\n }).then(function (clientInstance) {\n var merchantProp = merchantAccountId ? {\n merchantAccountId: merchantAccountId\n } : {};\n return braintree.paypalCheckout.create(__assign(__assign({}, merchantProp), {\n client: clientInstance\n }));\n }).then(function (paypalCheckoutInstance) {\n dispatch({\n type: DISPATCH_ACTION.SET_BRAINTREE_INSTANCE,\n value: paypalCheckoutInstance\n });\n });\n }).catch(function (err) {\n setErrorState(function () {\n throw new Error(\"\".concat(LOAD_SCRIPT_ERROR, \" \").concat(err));\n });\n }); // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [providerContext.options]);\n return React.createElement(React.Fragment, null, providerContext.braintreePayPalCheckoutInstance && React.createElement(PayPalButtons, __assign({\n className: className,\n disabled: disabled,\n forceReRender: forceReRender\n }, decorateActions(buttonProps, providerContext.braintreePayPalCheckoutInstance)), children));\n};\n/**\nThe `` component is used for conditionally rendering different payment options using radio buttons.\nThe [Display PayPal Buttons with other Payment Methods guide](https://developer.paypal.com/docs/business/checkout/add-capabilities/buyer-experience/#display-paypal-buttons-with-other-payment-methods) describes this style of integration in detail.\nIt relies on the `` parent component for managing state related to loading the JS SDK script.\n\nThis component can also be configured to use a single funding source similar to the [standalone buttons](https://developer.paypal.com/docs/business/checkout/configure-payments/standalone-buttons/) approach.\nA `FUNDING` object is exported by this library which has a key for every available funding source option.\n*/\n\n\nvar PayPalMarks = function (_a) {\n var _b = _a.className,\n className = _b === void 0 ? \"\" : _b,\n children = _a.children,\n markProps = __rest(_a, [\"className\", \"children\"]);\n\n var _c = usePayPalScriptReducer()[0],\n isResolved = _c.isResolved,\n options = _c.options;\n var markContainerRef = useRef(null);\n\n var _d = useState(true),\n isEligible = _d[0],\n setIsEligible = _d[1];\n\n var _e = useState(null),\n setErrorState = _e[1];\n /**\n * Render PayPal Mark into the DOM\n */\n\n\n var renderPayPalMark = function (mark) {\n var current = markContainerRef.current; // only render the mark when eligible\n\n if (!current || !mark.isEligible()) {\n return setIsEligible(false);\n } // Remove any children before render it again\n\n\n if (current.firstChild) {\n current.removeChild(current.firstChild);\n }\n\n mark.render(current).catch(function (err) {\n // component failed to render, possibly because it was closed or destroyed.\n if (current === null || current.children.length === 0) {\n // paypal marks container is no longer in the DOM, we can safely ignore the error\n return;\n } // paypal marks container is still in the DOM\n\n\n setErrorState(function () {\n throw new Error(\"Failed to render component. \".concat(err));\n });\n });\n };\n\n useEffect(function () {\n // verify the sdk script has successfully loaded\n if (isResolved === false) {\n return;\n }\n\n var paypalWindowNamespace = getPayPalWindowNamespace$1(options[SDK_SETTINGS.DATA_NAMESPACE]); // verify dependency on window object\n\n if (paypalWindowNamespace === undefined || paypalWindowNamespace.Marks === undefined) {\n return setErrorState(function () {\n throw new Error(generateErrorMessage({\n reactComponentName: PayPalMarks.displayName,\n sdkComponentKey: \"marks\",\n sdkRequestedComponents: options.components,\n sdkDataNamespace: options[SDK_SETTINGS.DATA_NAMESPACE]\n }));\n });\n }\n\n renderPayPalMark(paypalWindowNamespace.Marks(__assign({}, markProps))); // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isResolved, markProps.fundingSource]);\n return React.createElement(React.Fragment, null, isEligible ? React.createElement(\"div\", {\n ref: markContainerRef,\n className: className\n }) : children);\n};\n\nPayPalMarks.displayName = \"PayPalMarks\";\n/**\nThis `` messages component renders a credit messaging on upstream merchant sites.\nIt relies on the `` parent component for managing state related to loading the JS SDK script.\n*/\n\nvar PayPalMessages = function (_a) {\n var _b = _a.className,\n className = _b === void 0 ? \"\" : _b,\n _c = _a.forceReRender,\n forceReRender = _c === void 0 ? [] : _c,\n messageProps = __rest(_a, [\"className\", \"forceReRender\"]);\n\n var _d = usePayPalScriptReducer()[0],\n isResolved = _d.isResolved,\n options = _d.options;\n var messagesContainerRef = useRef(null);\n var messages = useRef(null);\n\n var _e = useState(null),\n setErrorState = _e[1];\n\n useEffect(function () {\n // verify the sdk script has successfully loaded\n if (isResolved === false) {\n return;\n }\n\n var paypalWindowNamespace = getPayPalWindowNamespace$1(options[SDK_SETTINGS.DATA_NAMESPACE]); // verify dependency on window object\n\n if (paypalWindowNamespace === undefined || paypalWindowNamespace.Messages === undefined) {\n return setErrorState(function () {\n throw new Error(generateErrorMessage({\n reactComponentName: PayPalMessages.displayName,\n sdkComponentKey: \"messages\",\n sdkRequestedComponents: options.components,\n sdkDataNamespace: options[SDK_SETTINGS.DATA_NAMESPACE]\n }));\n });\n }\n\n messages.current = paypalWindowNamespace.Messages(__assign({}, messageProps));\n messages.current.render(messagesContainerRef.current).catch(function (err) {\n // component failed to render, possibly because it was closed or destroyed.\n if (messagesContainerRef.current === null || messagesContainerRef.current.children.length === 0) {\n // paypal messages container is no longer in the DOM, we can safely ignore the error\n return;\n } // paypal messages container is still in the DOM\n\n\n setErrorState(function () {\n throw new Error(\"Failed to render component. \".concat(err));\n });\n }); // eslint-disable-next-line react-hooks/exhaustive-deps\n }, __spreadArray([isResolved], forceReRender, true));\n return React.createElement(\"div\", {\n ref: messagesContainerRef,\n className: className\n });\n};\n\nPayPalMessages.displayName = \"PayPalMessages\";\n/**\nThis `` component takes care of loading the JS SDK `