1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9206],{18725:function(e,n){n.M=void 0;let t="https://sdk.mercadopago.com/js/v2",o=/^https:\/\/sdk\.mercadopago\.com\/js\/v2\/?(\?.*)?$/,r="MercadoPago has already been initialized in your window, please remove the duplicate import",a=()=>{for(var e=document.querySelectorAll(`script[src^="${t}"`),n=0;n<e.length;n++){var r=e[n];if(o.test(r.src))return r}return null},c=()=>{let e=document.createElement("script");e.src=t;let n=document.head||document.body;if(!n)throw Error("Expected document.body or document.head not to be null. MercadoPago requires a <body> or a <head> element, please add on your project.");return n.appendChild(e),e},i=null;n.M=()=>null!==i?i:i=new Promise((e,n)=>{if("undefined"==typeof window){e(null);return}if(window.MercadoPago){console.warn(r),e(window.MercadoPago);return}try{let t=a();t?console.warn(r):t||(t=c()),t.addEventListener("load",()=>{window.MercadoPago?e(window.MercadoPago):n(Error("MercadoPago.js not available"))}),t.addEventListener("error",()=>{n(Error("Failed to load MercadoPago.js"))})}catch(e){n(e);return}})},49206:function(e,n,t){t.d(n,{Wg:function(){return h},R6:function(){return a}});var o=t(18725);class r{static getInstance(){var e,n,t,r;return e=this,n=void 0,t=void 0,r=function*(){if(this.publicKey)return this.loadedInstanceMercadoPago||(yield(0,o.M)(),this.loadedInstanceMercadoPago=!0),this.instanceMercadoPago||(this.instanceMercadoPago=new window.MercadoPago(this.publicKey,this.options)),this.instanceMercadoPago;console.error("Expected the PUBLIC_KEY to render the MercadoPago SDK React")},new(t||(t=Promise))(function(o,a){function c(e){try{d(r.next(e))}catch(e){a(e)}}function i(e){try{d(r.throw(e))}catch(e){a(e)}}function d(e){var n;e.done?o(e.value):((n=e.value)instanceof t?n:new t(function(e){e(n)})).then(c,i)}d((r=r.apply(e,n||[])).next())})}}r.publicKey=null,r.options={},r.instanceMercadoPago=void 0,r.loadedInstanceMercadoPago=!1;var a=(e,n)=>{let t=Object.assign(Object.assign({},n),{frontEndStack:"react"}),o=!function(e,n){let t=Object.keys(e).length===Object.keys(n).length&&Object.keys(e).every(t=>Object.prototype.hasOwnProperty.call(n,t)&&e[t]===n[t]);return t}(r.options,t);(e!==r.publicKey||o)&&(r.publicKey=e,r.options=t,r.instanceMercadoPago=void 0)},c=t(67294);let i=()=>{var e,n,t,o;return e=void 0,n=void 0,o=function*(){},new(t=void 0,t=Promise)(function(r,a){function c(e){try{d(o.next(e))}catch(e){a(e)}}function i(e){try{d(o.throw(e))}catch(e){a(e)}}function d(e){var n;e.done?r(e.value):((n=e.value)instanceof t?n:new t(function(e){e(n)})).then(c,i)}d((o=o.apply(e,n||[])).next())})},d=()=>{},l=e=>{console.error(e)},u=e=>{console.log(e)},s=e=>{var n,t,o,a;let{settings:c,name:i,containerId:d,controller:l}=e;return n=void 0,t=void 0,o=void 0,a=function*(){let e=yield r.getInstance(),n=null==e?void 0:e.bricks();window[l]=yield null==n?void 0:n.create(i,d,c)},new(o||(o=Promise))(function(e,r){function c(e){try{d(a.next(e))}catch(e){r(e)}}function i(e){try{d(a.throw(e))}catch(e){r(e)}}function d(n){var t;n.done?e(n.value):((t=n.value)instanceof o?t:new o(function(e){e(t)})).then(c,i)}d((a=a.apply(n,t||[])).next())})};var h=e=>{let{onReady:n=d,onError:t=l,onSubmit:o=i,onBinChange:r=u,initialization:a,customization:h,locale:v,id:f="cardPaymentBrick_container"}=e;return(0,c.useEffect)(()=>{let e={settings:{initialization:a,customization:h,callbacks:{onReady:n,onSubmit:o,onError:t,onBinChange:r},locale:v},name:"cardPayment",containerId:f,controller:"cardPaymentBrickController"},c=setTimeout(()=>{s(e)},200);return()=>{var e;clearTimeout(c),null===(e=window.cardPaymentBrickController)||void 0===e||e.unmount()}},[a,h,r,n,t,o]),c.createElement("div",{id:f})}}}]);
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.