@bootpay/client-js 5.3.0-beta.2 → 5.3.0-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -861,7 +861,7 @@ class Ms extends Ws {
861
861
  }
862
862
  }
863
863
  }
864
- const $e = new Ms(), Ls = "@bootpay/client-js", qs = "5.3.0-beta.2", zs = "dist/index.mjs", js = {
864
+ const $e = new Ms(), Ls = "@bootpay/client-js", qs = "5.3.0-beta.3", zs = "dist/index.mjs", js = {
865
865
  ".": {
866
866
  import: "./dist/index.mjs",
867
867
  types: "./dist/index.d.ts"
@@ -8475,10 +8475,10 @@ class Jn extends Ce {
8475
8475
  this.createIFrame(e);
8476
8476
  }
8477
8477
  removeWallet(e) {
8478
- this.createIFrame(`brandpay/destroy/${this.$widgetStore.data.application_id}/${e}`);
8478
+ this.createIFrame(`brandpay/destroy/${this.$widgetStore.resolve_auth_credential}/${e}`);
8479
8479
  }
8480
8480
  showCardInterestInformation(e) {
8481
- this.createIFrame(`card/interest/${this.$widgetStore.data.application_id}`);
8481
+ this.createIFrame(`card/interest/${this.$widgetStore.resolve_auth_credential}`);
8482
8482
  }
8483
8483
  brandpayPreference(e) {
8484
8484
  var i, n;
@@ -8490,8 +8490,8 @@ class Jn extends Ce {
8490
8490
  height: ((n = e.size) == null ? void 0 : n.height) || 800
8491
8491
  }
8492
8492
  };
8493
- const s = `brandpay/${this.$widgetStore.data.application_id}/${this.$widgetStore.encryptParameters()}/edit`;
8494
- console.log("url", s), t || R.isMobile() ? window.open(R.toWidget(`${s}?__popup=true`), "widget-brandpay-environment-popup", `width=${e.size.width},height=${e.size.height},scrollbars=yes`).focus() : this.createIFrame(s);
8493
+ const s = `brandpay/${this.$widgetStore.resolve_auth_credential}/${this.$widgetStore.encryptParameters()}/edit`;
8494
+ t || R.isMobile() ? window.open(R.toWidget(`${s}?__popup=true`), "widget-brandpay-environment-popup", `width=${e.size.width},height=${e.size.height},scrollbars=yes`).focus() : this.createIFrame(s);
8495
8495
  }
8496
8496
  externalPassword({ popup: e, url: t }) {
8497
8497
  e || R.isMobile() ? window.open(R.toWidget(`${t}?__popup=true`), "widget-brandpay-external-password-popup", "width=500,height=800,scrollbars=yes").focus() : this.createIFrame(t);
package/dist/index.umd.js CHANGED
@@ -1,5 +1,5 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode(':root{--bootpay-progress-bg-overlay: rgba(0, 0, 0, .5);--bootpay-progress-card-bg: rgba(30, 30, 40, .85);--bootpay-progress-accent: #6266E5;--bootpay-progress-accent-light: rgba(98, 102, 229, .3);--bootpay-progress-accent-glow: rgba(98, 102, 229, .5);--bootpay-progress-text: rgba(255, 255, 255, .95);--bootpay-progress-text-sub: rgba(255, 255, 255, .6)}.bootpay-progress-background{position:fixed;display:flex!important;align-items:center;justify-content:center;background:var(--bootpay-progress-bg-overlay);left:0;right:0;top:0;bottom:0;width:100%;height:100%;z-index:200000;opacity:0;animation:bootpay-fade-in .25s ease-out forwards}.bootpay-progress-background.blur-off{background-color:transparent}.bootpay-progress-background .progress-message-window{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:32px}.bootpay-progress-background .progress-message-window .alfred-loading{position:relative;display:flex;align-items:center;justify-content:center;width:72px;height:72px}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .alfred-loading{width:80px;height:80px}}.bootpay-progress-background .progress-message-window .bootpay-spinner{position:relative;width:48px;height:48px}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .bootpay-spinner{width:56px;height:56px}}.bootpay-progress-background .progress-message-window .bootpay-spinner:before{content:"";position:absolute;top:50%;left:50%;width:16px;height:16px;margin:-8px 0 0 -8px;background:var(--bootpay-progress-accent);border-radius:50%;box-shadow:0 0 20px var(--bootpay-progress-accent-glow);animation:bootpay-pulse-core 1.5s ease-in-out infinite}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .bootpay-spinner:before{width:18px;height:18px;margin:-9px 0 0 -9px}}.bootpay-progress-background .progress-message-window .bootpay-spinner:after{content:"";position:absolute;top:0;left:0;width:100%;height:100%;border-radius:50%;border:3px solid var(--bootpay-progress-accent-light);border-top-color:var(--bootpay-progress-accent);animation:bootpay-spin 1s cubic-bezier(.4,0,.2,1) infinite}.bootpay-progress-background .progress-message-window .alfred-loading:before{content:"";position:absolute;top:50%;left:50%;width:48px;height:48px;margin:-24px 0 0 -24px;border-radius:50%;border:2px solid var(--bootpay-progress-accent);opacity:0;animation:bootpay-ripple 2s ease-out infinite}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .alfred-loading:before{width:56px;height:56px;margin:-28px 0 0 -28px}}.bootpay-progress-background .progress-message-window .alfred-loading:after{content:"";position:absolute;top:50%;left:50%;width:48px;height:48px;margin:-24px 0 0 -24px;border-radius:50%;border:2px solid var(--bootpay-progress-accent);opacity:0;animation:bootpay-ripple 2s ease-out infinite .6s}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .alfred-loading:after{width:56px;height:56px;margin:-28px 0 0 -28px}}.bootpay-progress-background .progress-message-window .alfred-text{margin-top:24px;text-align:center}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .alfred-text{margin-top:28px}}.bootpay-progress-background .progress-message-window .alfred-text span.alfred-inner-text{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:14px;font-weight:500;color:var(--bootpay-progress-text);letter-spacing:.01em;animation:bootpay-text-fade 2s ease-in-out infinite}@media (min-width: 600px){.bootpay-progress-background .progress-message-window .alfred-text span.alfred-inner-text{font-size:15px}}@keyframes bootpay-fade-in{0%{opacity:0}to{opacity:1}}@keyframes bootpay-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes bootpay-pulse-core{0%,to{transform:scale(1);box-shadow:0 0 20px var(--bootpay-progress-accent-glow)}50%{transform:scale(1.15);box-shadow:0 0 30px var(--bootpay-progress-accent-glow),0 0 50px var(--bootpay-progress-accent-light)}}@keyframes bootpay-ripple{0%{transform:scale(.8);opacity:.6}to{transform:scale(1.8);opacity:0}}@keyframes bootpay-text-fade{0%,to{opacity:.85}50%{opacity:1}}:root{--bootpay-popup-bottom: 72px;--bootpay-primary: #507cf3;--bootpay-primary-hover: #3f6be2;--bootpay-white: #ffffff;--bootpay-black: #000000;--bootpay-gray-dark: #333333;--bootpay-gray-light: #888888;--bootpay-gray-bg: #f2f2f2;--bootpay-overlay: rgba(0, 0, 0, .7);--bootpay-radius: 12px;--bootpay-radius-sm: 5px;--bootpay-radius-lg: 16px;--bootpay-radius-xl: 20px;--bootpay-radius-xxl: 24px;--bootpay-shadow: 0 0 10px rgba(0, 0, 0, .1);--bootpay-z-modal: 9999;--bootpay-z-spinner: 200000;--bootpay-z-close: 10001;--bootpay-blur: blur(5px)}body.bootpay-open{position:fixed!important;left:0;right:0;bottom:0;top:0;padding:0;margin:0;height:100vh!important;overflow:hidden!important;-webkit-overflow-scrolling:auto!important}body.bootpay-inherit .fade-in,body.bootpay-open .fade-in{animation:__bootpay-fade-in .1s linear}body.bootpay-inherit .fade-out,body.bootpay-open .fade-out{animation:__bootpay-fade-out .1s linear}body.bootpay-inherit .slide-up,body.bootpay-open .slide-up{animation:__bootpay-slide-up .3s cubic-bezier(.25,.46,.45,.94) forwards!important}@media (max-width: 600px){body.bootpay-inherit .slide-up,body.bootpay-open .slide-up{animation:__bootpay-slide-up-mobile .1s cubic-bezier(.25,.46,.45,.94) forwards!important}}body.bootpay-inherit .slide-static-up,body.bootpay-open .slide-static-up{animation:__bootpay-slide-up-mobile .1s cubic-bezier(.25,.46,.45,.94) forwards!important}body.bootpay-inherit .slide-down,body.bootpay-open .slide-down{animation:__bootpay-slide-down .1s ease-in forwards!important}@media (max-width: 600px){body.bootpay-inherit .slide-down,body.bootpay-open .slide-down{animation:__bootpay-slide-down-mobile .1s ease-in forwards!important}}body.bootpay-inherit .slide-static-down,body.bootpay-open .slide-static-down{animation:__bootpay-slide-down-mobile .1s ease-in forwards!important}body.bootpay-inherit.bootpay-mobile .bootpay-payment-background,body.bootpay-open.bootpay-mobile .bootpay-payment-background{background-color:transparent}@media (min-width: 600px){body.bootpay-inherit.bootpay-mobile .bootpay-payment-background,body.bootpay-open.bootpay-mobile .bootpay-payment-background{background-color:var(--bootpay-overlay)}}body.bootpay-inherit .bootpay-transparent-background,body.bootpay-open .bootpay-transparent-background{position:relative;height:100%;z-index:var(--bootpay-z-modal)}body.bootpay-inherit .bootpay-transparent-background.__overflow-y,body.bootpay-open .bootpay-transparent-background.__overflow-y{overflow-y:auto}body.bootpay-inherit .bootpay-transparent-background>.bootpay-payment-window,body.bootpay-open .bootpay-transparent-background>.bootpay-payment-window{position:relative;display:block;width:500px;height:auto}@media (max-width: 768px){body.bootpay-inherit .bootpay-transparent-background>.bootpay-payment-window,body.bootpay-open .bootpay-transparent-background>.bootpay-payment-window{width:100%}}body.bootpay-inherit .bootpay-transparent-background>.bootpay-payment-window.__mobile,body.bootpay-open .bootpay-transparent-background>.bootpay-payment-window.__mobile{max-width:470px;height:90%}body.bootpay-inherit .bootpay-transparent-background>.bootpay-payment-window>iframe,body.bootpay-open .bootpay-transparent-background>.bootpay-payment-window>iframe{width:100%!important;border-radius:0}body.bootpay-inherit .bootpay-transparent-background>.bootpay-payment-window>iframe.transparent,body.bootpay-open .bootpay-transparent-background>.bootpay-payment-window>iframe.transparent{background:transparent!important}body.bootpay-inherit .bootpay-payment-background,body.bootpay-open .bootpay-payment-background{position:fixed;left:0;right:0;top:0;bottom:0;display:block;text-align:center;background-color:var(--bootpay-overlay);z-index:var(--bootpay-z-modal);backdrop-filter:var(--bootpay-blur);-webkit-backdrop-filter:var(--bootpay-blur);overflow-y:auto}body.bootpay-inherit .bootpay-payment-background:before,body.bootpay-open .bootpay-payment-background:before{display:inline-block;vertical-align:middle;height:100%;content:" "}body.bootpay-inherit .bootpay-payment-background.__alert,body.bootpay-open .bootpay-payment-background.__alert{padding:1rem}body.bootpay-inherit .bootpay-payment-background.__alert:before,body.bootpay-open .bootpay-payment-background.__alert:before{display:inline-block;vertical-align:middle;height:100%;content:" "}body.bootpay-inherit .bootpay-payment-background.__alert>.slider-window,body.bootpay-open .bootpay-payment-background.__alert>.slider-window{max-width:480px;position:absolute;width:100%;background-color:var(--bootpay-white);border-radius:24px;left:50%;top:50%;transform:translate(-50%,-50%);overflow:hidden;box-shadow:0 10px 40px #00000014,0 4px 12px #0000000a;border:1px solid #f1f5f9}body.bootpay-inherit .bootpay-payment-background.__alert>.slider-window.__bootpay-hidden,body.bootpay-open .bootpay-payment-background.__alert>.slider-window.__bootpay-hidden{display:none}@media (max-width: 600px){body.bootpay-inherit .bootpay-payment-background.__alert>.slider-window,body.bootpay-open .bootpay-payment-background.__alert>.slider-window{left:0;right:0;bottom:0;width:100%;max-width:inherit;top:auto;border-bottom-left-radius:0;border-bottom-right-radius:0;transform:translateY(0) translate(0)}}body.bootpay-inherit .bootpay-payment-background.__alert>.bootpay-confirm-window,body.bootpay-open .bootpay-payment-background.__alert>.bootpay-confirm-window{position:absolute;max-width:400px;width:100%;background-color:var(--bootpay-white);border-radius:var(--bootpay-radius);left:50%;top:50%;transform:translate(-50%,-50%);overflow:hidden;box-shadow:var(--bootpay-shadow)}@media (max-width: 768px){body.bootpay-inherit .bootpay-payment-background.__alert>.bootpay-confirm-window,body.bootpay-open .bootpay-payment-background.__alert>.bootpay-confirm-window{left:1rem;right:1rem;width:auto;top:50%;transform:translateY(-50%)}}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header{padding:1.5rem 2rem 1rem;text-align:left;font-size:20px;font-weight:700;position:relative;background-color:var(--bootpay-white);border-bottom:1px solid #f1f5f9}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header.__text-center,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header.__text-center,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header.__text-center,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header.__text-center{text-align:center}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn{top:40%;transform:translateY(-50%);padding:0;right:1rem}@media (min-width: 600px){body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn{right:8px;top:50%;transform:translateY(-55%)}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn:before,body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn:after,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn:before,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn:after,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn:before,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-header>.bootpay-close-btn:after,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn:before,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-header>.bootpay-close-btn:after{background-color:var(--bootpay-gray-dark);width:1px}}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body{padding:.5rem 1rem 1.5rem;text-align:center;font-size:16px;color:var(--bootpay-gray-dark);line-height:1.5;background:transparent}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body.slider-body,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body.slider-body,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body.slider-body,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body.slider-body{padding:1.5rem 2rem 2rem;background:transparent}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button{display:inline-block;width:100%;padding:1rem 1.5rem;color:#64748b;font-size:16px;font-weight:500;border-radius:16px;outline:none;border:2px solid transparent;cursor:pointer;margin-top:1rem;background-color:#f8fafc;transition:all .3s cubic-bezier(.4,0,.2,1);position:relative}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button:first-child,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button:first-child,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button:first-child,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button:first-child{margin-top:0}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button:hover,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button:hover,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button:hover,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button:hover{border-color:var(--bootpay-primary);background-color:#f0f4ff;color:var(--bootpay-primary);transform:translateY(-2px);box-shadow:0 8px 25px #507cf326}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button.active,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button.active,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-body button.bootpay__slider-button.active,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-body button.bootpay__slider-button.active{background-color:var(--bootpay-primary);color:var(--bootpay-white);font-weight:600;border-color:var(--bootpay-primary);transform:translateY(-1px);box-shadow:0 12px 30px #507cf340,0 0 0 3px #507cf31a}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer{display:flex;justify-content:flex-end;border-top:1px solid var(--bootpay-gray-bg)}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close{flex:0 1 50%;padding:1rem;background-color:var(--bootpay-white);color:var(--bootpay-gray-dark);font-size:16px;cursor:pointer;border:0;outline:none}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.border-right,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.border-right,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.border-right,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.border-right{border-right:1px solid var(--bootpay-gray-bg)}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close:hover,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close:hover,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close:hover,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close:hover{background-color:#e0e0e0}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary{color:var(--bootpay-primary);font-weight:600}body.bootpay-inherit .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary:hover,body.bootpay-inherit .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary:hover,body.bootpay-open .bootpay-payment-background.__alert .bootpay-confirm-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary:hover,body.bootpay-open .bootpay-payment-background.__alert .slider-window>.bootpay__alert-footer>button.bootpay__alert-close.bootpay-primary:hover{color:var(--bootpay-primary-hover)}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window{position:relative;display:inline-block;vertical-align:middle}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.__mobile,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.__mobile{max-width:470px;height:90%}@media (max-width: 1120px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice{position:absolute;left:0;right:0;top:0;bottom:0;border-radius:0!important}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice>iframe{width:100%!important;height:100%!important;border-radius:0}}@media (max-height: 1020px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice{position:absolute;left:0;right:0;top:0;bottom:0;border-radius:0!important}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.bootpay-commerce-invoice>iframe{width:100%!important;height:100%!important;border-radius:0}}@media (max-width: 768px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window{position:absolute;left:0;right:0;top:0;bottom:0;border-radius:0!important}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window.__mobile,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window.__mobile{position:absolute;max-width:inherit;left:0;right:0;top:0;bottom:0;height:100%}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe{width:100%!important;height:100%!important;border-radius:0}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.transparent,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.transparent{background:transparent!important}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close{position:absolute;display:none;top:-32px;right:4px;color:var(--bootpay-white);font-size:32px;text-decoration:none;outline:none;box-shadow:none;border:0;background-color:transparent}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:before,body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:after,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:before,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:after{width:2px!important;background-color:var(--bootpay-white)!important}@media (max-width: 768px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close{top:1rem;right:16px;color:var(--bootpay-black);padding:0}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:before,body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:after,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:before,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>button.bootpay-payment-close:after{width:2px!important;background-color:var(--bootpay-black)!important}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window{position:relative;width:400px;height:600px;display:none;background-color:var(--bootpay-white);border-radius:var(--bootpay-radius-sm);overflow:hidden}@media (max-width: 768px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window{position:absolute;left:0;top:0;bottom:0;right:0;width:100%;height:100%;border-radius:0}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.header,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.header{position:absolute;left:0;right:0;top:0;height:50px;color:var(--bootpay-gray-dark);background-color:var(--bootpay-white);text-align:left}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body{position:absolute;left:0;right:0;top:50px;bottom:var(--bootpay-popup-bottom);padding:1rem;text-align:left;font-size:14px}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>#bootpay-item-name-id,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>#bootpay-item-name-id{font-size:16px;color:var(--bootpay-gray-light);font-weight:400!important;text-align:center}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>#bootpay-price-id,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>#bootpay-price-id{font-size:36px;color:var(--bootpay-gray-dark);font-weight:700;text-align:center;line-height:normal}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>.agree-text,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.body>.agree-text{position:absolute;bottom:1rem;left:0;right:0;color:var(--bootpay-gray-light);font-size:14px;text-align:center}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer{position:absolute;left:0;right:0;bottom:0;height:var(--bootpay-popup-bottom);padding:0 1rem;margin:0}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button{display:block;width:100%;padding:1rem;outline:none;border:none;background-color:var(--bootpay-primary);border-radius:var(--bootpay-radius-sm);color:#fff;font-size:16px}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button:hover,body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button:active,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button:hover,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-popup-window>.footer>button.bootpay-button:active{outline:none;box-shadow:none}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe{width:100%;height:100%;display:none;border:0!important;outline:0!important;border-radius:0;box-shadow:none}@media (max-width: 1100px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe{width:100%!important;height:100%!important;overflow-y:auto}}@media (min-width: 1100px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.bootpay-commerce-checkout-iframe{width:0;height:0;border:0;outline:0;border-radius:0;box-shadow:none!important}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe{width:100%;height:100%;display:none;border:0!important;outline:0!important;border-radius:0;box-shadow:none}@media (min-width: 600px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe{width:0;height:0;border:0;outline:0;border-radius:0;box-shadow:none!important}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.rounded-iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.rounded-iframe{border-radius:0}@media (min-width: 600px){body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>iframe.rounded-iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>iframe.rounded-iframe{width:0;height:0;border:0;outline:0;border-radius:var(--bootpay-radius-sm)!important;box-shadow:none!important}}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window #__bootpay-modal-iframe.slide-up,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window #__bootpay-modal-iframe.slide-up{animation:__bootpay-slide-up .3s linear}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window #__bootpay-modal-iframe.slide-down,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window #__bootpay-modal-iframe.slide-down{animation:__bootpay-slide-down .3s linear}body.bootpay-inherit .bootpay-payment-background>.bootpay-payment-window>.bootpay-confirm-window>iframe,body.bootpay-open .bootpay-payment-background>.bootpay-payment-window>.bootpay-confirm-window>iframe{display:none;width:1px;height:1px;background:transparent;border:0!important;outline:0!important}.bootpay-close-btn{position:absolute;box-shadow:none;background-color:transparent;outline:0;z-index:var(--bootpay-z-close);right:8px;top:8px;height:21px;width:21px;border:0!important;outline:none!important}@media (min-width: 600px){.bootpay-close-btn{right:4px;top:-32px;width:25px;height:25px;background:transparent;outline:none!important;border:0!important}}.bootpay-close-btn.active,.bootpay-close-btn:focus{outline:none!important;border:0!important}.bootpay-close-btn:before,.bootpay-close-btn:after{position:absolute;left:8px;top:2px;content:" ";height:24px;width:1px;background-color:var(--bootpay-gray-dark)}@media (min-width: 600px){.bootpay-close-btn:before,.bootpay-close-btn:after{height:23px;top:0;width:2px;background-color:var(--bootpay-white)}}.bootpay-close-btn:before{transform:rotate(45deg)}.bootpay-close-btn:after{transform:rotate(-45deg)}@keyframes __bootpay-slide-up{0%{transform:translate(-50%,150%);opacity:1}to{transform:translate(-50%,-50%);opacity:1}}@keyframes __bootpay-slide-down{0%{transform:translate(-50%,-50%);opacity:1}to{transform:translate(-50%,150%);opacity:1}}@keyframes __bootpay-slide-up-mobile{0%{transform:translateY(100%);opacity:1}to{transform:translateY(0);opacity:1}}@keyframes __bootpay-slide-down-mobile{0%{transform:translateY(0);opacity:1}to{transform:translateY(100%);opacity:1}}@keyframes __bootpay-fade-in{0%{opacity:0;scale:.9}to{opacity:1;scale:1}}@keyframes __bootpay-fade-out{0%{opacity:1;scale:1}to{opacity:0;scale:.9}}')),document.head.appendChild(o)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
2
- (function(me,Z){typeof exports=="object"&&typeof module<"u"?Z(exports):typeof define=="function"&&define.amd?define(["exports"],Z):(me=typeof globalThis<"u"?globalThis:me||self,Z(me.Bootpay={}))})(this,function(me){"use strict";const Z={PLATFORM:{JS:1,ANDROID:2,IOS:3,REST:4},STORAGE_PREFIX(r){return`__bootpay_track_${r}__`}},S0=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,r=>{let e=Math.random()*16|0;return(r=="x"?e:e&3|8).toString(16)}),se=r=>{let e=!1;return typeof r=="string"||Array.isArray(r)?e=r.length===0:e=r==null||ze(r,"object")&&r.constructor===Object&&Object.keys(r).length===0,e},q=r=>!se(r),ze=(r,e)=>typeof r===e,bs=(r,e=void 0)=>{if(q(e)){const t=typeof e!="string"?new URLSearchParams(JSON.parse(JSON.stringify(e))).toString():e;return/\?/.test(r)?`${r.replace(/&amp;/g,"&")}&${t}`:`${r.replace(/&amp;/g,"&")}?${t}`}else return r},mt=(r,e)=>{for(let t in e)e.hasOwnProperty(t)&&(r[t]=e[t]);return r};var N=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Te(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function _s(r){if(r.__esModule)return r;var e=r.default;if(typeof e=="function"){var t=function s(){return this instanceof s?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(r).forEach(function(s){var i=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(t,s,i.get?i:{enumerable:!0,get:function(){return r[s]}})}),t}var I0={exports:{}};function Cs(r){throw new Error('Could not dynamically require "'+r+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Et={exports:{}};const As=_s(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var T0;function L(){return T0||(T0=1,function(r,e){(function(t,s){r.exports=s()})(N,function(){var t=t||function(s,i){var n;if(typeof window<"u"&&window.crypto&&(n=window.crypto),typeof self<"u"&&self.crypto&&(n=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(n=globalThis.crypto),!n&&typeof window<"u"&&window.msCrypto&&(n=window.msCrypto),!n&&typeof N<"u"&&N.crypto&&(n=N.crypto),!n&&typeof Cs=="function")try{n=As}catch{}var m=function(){if(n){if(typeof n.getRandomValues=="function")try{return n.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof n.randomBytes=="function")try{return n.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},x=Object.create||function(){function d(){}return function(l){var v;return d.prototype=l,v=new d,d.prototype=null,v}}(),p={},a=p.lib={},c=a.Base=function(){return{extend:function(d){var l=x(this);return d&&l.mixIn(d),(!l.hasOwnProperty("init")||this.init===l.init)&&(l.init=function(){l.$super.init.apply(this,arguments)}),l.init.prototype=l,l.$super=this,l},create:function(){var d=this.extend();return d.init.apply(d,arguments),d},init:function(){},mixIn:function(d){for(var l in d)d.hasOwnProperty(l)&&(this[l]=d[l]);d.hasOwnProperty("toString")&&(this.toString=d.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),g=a.WordArray=c.extend({init:function(d,l){d=this.words=d||[],l!=i?this.sigBytes=l:this.sigBytes=d.length*4},toString:function(d){return(d||u).stringify(this)},concat:function(d){var l=this.words,v=d.words,E=this.sigBytes,_=d.sigBytes;if(this.clamp(),E%4)for(var A=0;A<_;A++){var w=v[A>>>2]>>>24-A%4*8&255;l[E+A>>>2]|=w<<24-(E+A)%4*8}else for(var I=0;I<_;I+=4)l[E+I>>>2]=v[I>>>2];return this.sigBytes+=_,this},clamp:function(){var d=this.words,l=this.sigBytes;d[l>>>2]&=4294967295<<32-l%4*8,d.length=s.ceil(l/4)},clone:function(){var d=c.clone.call(this);return d.words=this.words.slice(0),d},random:function(d){for(var l=[],v=0;v<d;v+=4)l.push(m());return new g.init(l,d)}}),o=p.enc={},u=o.Hex={stringify:function(d){for(var l=d.words,v=d.sigBytes,E=[],_=0;_<v;_++){var A=l[_>>>2]>>>24-_%4*8&255;E.push((A>>>4).toString(16)),E.push((A&15).toString(16))}return E.join("")},parse:function(d){for(var l=d.length,v=[],E=0;E<l;E+=2)v[E>>>3]|=parseInt(d.substr(E,2),16)<<24-E%8*4;return new g.init(v,l/2)}},h=o.Latin1={stringify:function(d){for(var l=d.words,v=d.sigBytes,E=[],_=0;_<v;_++){var A=l[_>>>2]>>>24-_%4*8&255;E.push(String.fromCharCode(A))}return E.join("")},parse:function(d){for(var l=d.length,v=[],E=0;E<l;E++)v[E>>>2]|=(d.charCodeAt(E)&255)<<24-E%4*8;return new g.init(v,l)}},y=o.Utf8={stringify:function(d){try{return decodeURIComponent(escape(h.stringify(d)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(d){return h.parse(unescape(encodeURIComponent(d)))}},f=a.BufferedBlockAlgorithm=c.extend({reset:function(){this._data=new g.init,this._nDataBytes=0},_append:function(d){typeof d=="string"&&(d=y.parse(d)),this._data.concat(d),this._nDataBytes+=d.sigBytes},_process:function(d){var l,v=this._data,E=v.words,_=v.sigBytes,A=this.blockSize,w=A*4,I=_/w;d?I=s.ceil(I):I=s.max((I|0)-this._minBufferSize,0);var B=I*A,C=s.min(B*4,_);if(B){for(var F=0;F<B;F+=A)this._doProcessBlock(E,F);l=E.splice(0,B),v.sigBytes-=C}return new g.init(l,C)},clone:function(){var d=c.clone.call(this);return d._data=this._data.clone(),d},_minBufferSize:0});a.Hasher=f.extend({cfg:c.extend(),init:function(d){this.cfg=this.cfg.extend(d),this.reset()},reset:function(){f.reset.call(this),this._doReset()},update:function(d){return this._append(d),this._process(),this},finalize:function(d){d&&this._append(d);var l=this._doFinalize();return l},blockSize:16,_createHelper:function(d){return function(l,v){return new d.init(v).finalize(l)}},_createHmacHelper:function(d){return function(l,v){return new b.HMAC.init(d,v).finalize(l)}}});var b=p.algo={};return p}(Math);return t})}(Et)),Et.exports}(function(r,e){(function(t,s){r.exports=s(L())})(N,function(t){return t.enc.Utf8})})(I0);var ws=I0.exports;const R0=Te(ws);var gt={exports:{}},O0;function Be(){return O0||(O0=1,function(r,e){(function(t,s){r.exports=s(L())})(N,function(t){return function(){var s=t,i=s.lib,n=i.WordArray,m=s.enc;m.Base64={stringify:function(p){var a=p.words,c=p.sigBytes,g=this._map;p.clamp();for(var o=[],u=0;u<c;u+=3)for(var h=a[u>>>2]>>>24-u%4*8&255,y=a[u+1>>>2]>>>24-(u+1)%4*8&255,f=a[u+2>>>2]>>>24-(u+2)%4*8&255,b=h<<16|y<<8|f,d=0;d<4&&u+d*.75<c;d++)o.push(g.charAt(b>>>6*(3-d)&63));var l=g.charAt(64);if(l)for(;o.length%4;)o.push(l);return o.join("")},parse:function(p){var a=p.length,c=this._map,g=this._reverseMap;if(!g){g=this._reverseMap=[];for(var o=0;o<c.length;o++)g[c.charCodeAt(o)]=o}var u=c.charAt(64);if(u){var h=p.indexOf(u);h!==-1&&(a=h)}return x(p,a,g)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function x(p,a,c){for(var g=[],o=0,u=0;u<a;u++)if(u%4){var h=c[p.charCodeAt(u-1)]<<u%4*2,y=c[p.charCodeAt(u)]>>>6-u%4*2,f=h|y;g[o>>>2]|=f<<24-o%4*8,o++}return n.create(g,o)}}(),t.enc.Base64})}(gt)),gt.exports}var Fs=Be();const Re=Te(Fs);class je{$blank(e){return se(e)}$present(e){return!this.$blank(e)}$type(e,t){return ze(e,t)}$uuid(){return S0()}$encrypt(e){return this.$type(e,"object")&&(e=JSON.stringify(e)),Re.stringify(R0.parse(e))}$decrypt(e){return R0.stringify(Re.parse(e))}getUserAgent(){return window.navigator.userAgent}}const Ke={debug:1,info:2,warning:3,error:4},H={level:Ke.warning,setLogLevel(r){this.level=r},messageStringify(r,e){try{return e=`${r}: ${ze(e,"object")?JSON.stringify(e):e}`}catch(t){console.error(`log parse error: ${t}`)}},debug(r,e){this.level<=Ke.debug&&console.log(this.messageStringify(r,e))},info(r,e){this.level<=Ke.info&&console.info(this.messageStringify(r,e))},warn(r,e){this.level<=Ke.warning&&console.warn(this.messageStringify(r,e))},error(r,e){this.level<=Ke.error&&console.error(this.messageStringify(r,e))}};class Ds extends je{constructor(){super(),this.$storage={}}get(e){let t="";try{t=window.localStorage.getItem(e)}catch{t=this.$storage[e]}return this.$present(t)?this.$decrypt(t):void 0}set(e,t){try{window.localStorage.setItem(e,this.$encrypt(t))}catch{this.$storage[e]=this.$encrypt(t)}return t}currentUserUUID(){const e=Z.STORAGE_PREFIX("uuid"),t=this.get(e);return this.$blank(t)?this.set(e,this.$uuid()):t}setUUID(e){const t=Z.STORAGE_PREFIX("uuid");return this.set(t,e)}getToJSON(e){const t=this.get(e);return this.$present(t)?this.caseMarshalToJson(t):t}setToJSON(e,t){return this.set(e,JSON.stringify(t)),t}caseMarshalToJson(e){try{return JSON.parse(e)}catch{return JSON.parse(e.replace(/\\\"/g,'"'))}}}class $s extends Ds{constructor(){super(),this.currentUserUUID()}currentSessionKey(){const e=Math.round(new Date().getTime()/1e3),t=Z.STORAGE_PREFIX("session"),s=this.getToJSON(t);return this.$blank(s)||s.time+1800<e?this.setToJSON(t,{time:e,term:this.$blank(s)?-1:e-s.time,uuid:`${this.$uuid()}-${e}`}).uuid:s.uuid}currentTimeTerm(){const e=Z.STORAGE_PREFIX("session"),t=this.getToJSON(e);return this.$blank(t.term)?-1:t.term}currentTime(){const e=Z.STORAGE_PREFIX("session"),t=this.getToJSON(e);return this.$blank(t.time)?-1:t.time}setTime(e){const t=Math.round(new Date().getTime()/1e3),s=Z.STORAGE_PREFIX("session"),i=this.getToJSON(s),n=this.$blank(i)?{time:e>0?e:t,term:e>0?t-e:-1,uuid:`${this.$uuid()}-${t}`}:i;n.time=e,this.setToJSON(s,n)}generateKey(){return`${this.$uuid()}-${new Date().getTime()}`}setUser(e){return this.set(Z.STORAGE_PREFIX("user"),e===void 0?void 0:JSON.stringify(e)),e}getUser(){try{return JSON.parse(this.get(Z.STORAGE_PREFIX("user")))}catch(e){H.error("User Storage",`사용자 정보를 추출하는데 실패하였습니다. [ ${e.message} ]`);return}}}const $e=new $s,ke={name:"@bootpay/client-js",version:"5.3.0-beta.2",main:"dist/index.mjs",exports:{".":{import:"./dist/index.mjs",types:"./dist/index.d.ts"}},styles:"dist/index.css",scripts:{test:'echo "Error: no test specified" && exit 1',build:"rm -rf ./dist && vite build",deploy:"NODE_ENV=production ./node_modules/.bin/webpack --output-path=./dist --mode=production && gzip -kf dist/*.min.js && ./webview.sh $npm_package_version"},dependencies:{typescript:"^5.5.4"},devDependencies:{"@types/ws":"^8.5.5","@types/node":"^18.15.3","@webpack-cli/serve":"^2.0.5","webpack-dev-server":"^4.15.1",webpack:"^5.87.0","webpack-cli":"^5.1.4",axios:"^0.27.2","crypto-js":"^4.1.1","@types/crypto-js":"^4.1.1","@babel/core":"^7.22.5","@babel/plugin-transform-regenerator":"^7.22.5","@babel/plugin-transform-runtime":"^7.22.5","@babel/plugin-transform-object-assign":"^7.22.5","@babel/plugin-proposal-class-properties":"^7.18.6","@babel/plugin-transform-destructuring":"^7.24.8","@babel/plugin-proposal-export-default-from":"^7.27.1","@babel/plugin-transform-class-properties":"^7.27.1","@babel/plugin-proposal-decorators":"^7.28.0","@babel/plugin-transform-private-methods":"^7.27.1","@babel/plugin-transform-typescript":"^7.28.0","@babel/preset-env":"^7.22.5","@babel/preset-typescript":"^7.22.5","@babel/runtime-corejs3":"^7.22.5","@babel/plugin-transform-classes":"^7.22.5","core-js":"^3.31.0","babel-loader":"^9.1.2","css-loader":"^6.8.1",sass:"^1.63.4","sass-loader":"^13.3.2","style-loader":"^3.3.3",vite:"^5.4.3","vite-plugin-dts":"^3.6.4","vite-plugin-tsconfig":"^1.0.4","vite-plugin-css-injected-by-js":"3.3.1"},resolutions:{"@webpack-cli/serve":"^1.3.1"},keywords:[],author:"",license:"ISC",description:""},R={mode:"production",locale:"ko",isSetLocale:!1,packageVersion:ke.version,applicationId:"",API_URL:{development:"https://dev-api.bootpay.co.kr/v2",stage:"https://stage-api.bootpay.co.kr/v2",production:"https://api.bootpay.co.kr/v2"},ANALYTICS_URL:{development:"https://dev-analytics.bootpay.co.kr",stage:"https://stage-analytics.bootpay.co.kr",production:"https://analytics.bootpay.co.kr"},DOOR_URL:{development:"https://door-dev.bootpay.co.kr",stage:"https://door-stage.bootpay.co.kr",production:"https://door.bootpay.co.kr"},WIDGET_URL:{development:"https://dev-widget.bootpay.co.kr",stage:"https://stage-widget.bootpay.co.kr",production:"https://widget.bootpay.co.kr"},sdkNames:{android:100,android_react_native:101,android_flutter:102,android_unity:103,ios:200,ios_react_native:201,ios_flutter:202,ios_unity:203,ios_objc:204,ios_swift_ui:205,mac_swift:206,mac_flutter:207},sdkVersion:"",sdkName:0,set(r){this.mode=r},setApplicationId(r){return this.applicationId=r,this.currentApplicationId(void 0)},setLocale(r){this.locale=r,this.isSetLocale=!0},currentApplicationId(r=void 0){return r===void 0?this.applicationId:r},setDevelopmentHost(r){this.API_URL.development=this.API_URL.development.replace(/dev-api.bootpay.co.kr\/v2/gi,r)},setVersion(r,e,t=void 0){this.sdkName=this.sdkNames[e]===void 0?0:this.sdkNames[e],this.sdkVersion=r,this.packageVersion=t===void 0||t===""?ke.version:t},toApi(r){return[this.API_URL[this.mode],r].join("/")},toDoor(r){return[this.DOOR_URL[this.mode],r].join("/")},toWidget(r){return[this.WIDGET_URL[this.mode],r].join("/")},isMobile(){if(typeof window>"u")return!1;const r=window.navigator.userAgent||window.navigator.vendor;return/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Silk-Accelerated|(hpw|web)OS|Fennec|Minimo|Opera M(obi|ini)|Blazer|Dolfin|Dolphin|Skyfire|Zune/.test(r)},isMobileSafari(){if(typeof window>"u")return!1;const r=window.navigator.userAgent;return(r.match(/iPad/i)||r.match(/iPhone/i))&&!r.match(/CriOS/i)},toAnalytics(r){return[this.ANALYTICS_URL[this.mode],r].join("/")}};class ae extends Error{constructor(e){super(),this.name="BootpayEventError",this.eventMessage=e}}const Pe={__BOOTPAY_NAMESPACE:{},isBind:!1,initialize(){this.isBind||(typeof window<"u"&&(window.addBootpayEventListener=this.on,window.removeBootpayEventListener=this.off,window.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),typeof document<"u"&&(document.addBootpayEventListener=this.on,document.removeBootpayEventListener=this.off,document.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),typeof Element<"u"&&(Element.prototype.addBootpayEventListener=this.on,Element.prototype.removeBootpayEventListener=this.off,Element.prototype.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),this.isBind=!0)},on(r,e,t=void 0){return se(Pe.__BOOTPAY_NAMESPACE)&&(Pe.__BOOTPAY_NAMESPACE={}),this.addEventListener(r.split(".")[0],e,t||!1),Pe.__BOOTPAY_NAMESPACE[r]=e,this},off(r){return q(Pe.__BOOTPAY_NAMESPACE)&&q(Pe.__BOOTPAY_NAMESPACE[r])&&this.removeEventListener(r.split(".")[0],Pe.__BOOTPAY_NAMESPACE[r]),this}};class Ge extends je{constructor(e){super(),this.$resolve=null,this.$reject=null,this.$messageEventName=(e==null?void 0:e.messageEventName)??"message.BootpayEvent",this.$eventHooks=(e==null?void 0:e.messageEventHooks)??{},this.afterBind=e==null?void 0:e.afterBind,this.$childInstance=null,Pe.initialize()}setChildInstance(e){this.$childInstance=e}bind(e,t){this.$messageEventName&&window.resetBootpayEventListener(this.$messageEventName,s=>{const i=this.parseEvent(s.data);if(H.debug("event received",JSON.stringify(i)),q(i)&&q(i.event)){const n=this.hookFunction(i.hook);if(q(n)&&q(n[i.event]))return n[i.event](i.data,this);H.debug("event",`${this.$messageEventName}: ${i.event} is not defined`)}}),this.afterBind&&this.afterBind(),this.setCallbackFunction(e,t)}hookFunction(e){return this.$eventHooks[e]}reject(e){q(this.$reject)&&this.$reject(e)}resolve(e){q(this.$resolve)&&this.$resolve(e)}setCallbackFunction(e,t){this.$resolve=e,this.$reject=t}parseEvent(e){let t={};if(this.$present(e)&&this.$type(e,"string")){try{t=JSON.parse(e)}catch(s){H.info("json parsing failed",`data: ${e}, message: ${Xe(s)} JSON 파싱 형태가 아닌 이벤트 입니다.`)}return t.bootpay_event?(delete t.bootpay_event,t):null}else return null}}const Xe=r=>typeof r=="string"?r.toUpperCase():r instanceof Error?r.message:r;class be extends je{constructor(e={}){super();const{iframeId:t="bootpay-iframe",template:s=this.defaultIframeHtml(),el:i=void 0}=e;this.el=i,this.$windowId=t,this.$template=s}defaultIframeHtml(){return`
2
+ (function(me,Z){typeof exports=="object"&&typeof module<"u"?Z(exports):typeof define=="function"&&define.amd?define(["exports"],Z):(me=typeof globalThis<"u"?globalThis:me||self,Z(me.Bootpay={}))})(this,function(me){"use strict";const Z={PLATFORM:{JS:1,ANDROID:2,IOS:3,REST:4},STORAGE_PREFIX(r){return`__bootpay_track_${r}__`}},S0=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,r=>{let e=Math.random()*16|0;return(r=="x"?e:e&3|8).toString(16)}),se=r=>{let e=!1;return typeof r=="string"||Array.isArray(r)?e=r.length===0:e=r==null||ze(r,"object")&&r.constructor===Object&&Object.keys(r).length===0,e},q=r=>!se(r),ze=(r,e)=>typeof r===e,bs=(r,e=void 0)=>{if(q(e)){const t=typeof e!="string"?new URLSearchParams(JSON.parse(JSON.stringify(e))).toString():e;return/\?/.test(r)?`${r.replace(/&amp;/g,"&")}&${t}`:`${r.replace(/&amp;/g,"&")}?${t}`}else return r},mt=(r,e)=>{for(let t in e)e.hasOwnProperty(t)&&(r[t]=e[t]);return r};var N=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Te(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function _s(r){if(r.__esModule)return r;var e=r.default;if(typeof e=="function"){var t=function s(){return this instanceof s?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(r).forEach(function(s){var i=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(t,s,i.get?i:{enumerable:!0,get:function(){return r[s]}})}),t}var I0={exports:{}};function Cs(r){throw new Error('Could not dynamically require "'+r+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Et={exports:{}};const As=_s(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var T0;function L(){return T0||(T0=1,function(r,e){(function(t,s){r.exports=s()})(N,function(){var t=t||function(s,i){var n;if(typeof window<"u"&&window.crypto&&(n=window.crypto),typeof self<"u"&&self.crypto&&(n=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(n=globalThis.crypto),!n&&typeof window<"u"&&window.msCrypto&&(n=window.msCrypto),!n&&typeof N<"u"&&N.crypto&&(n=N.crypto),!n&&typeof Cs=="function")try{n=As}catch{}var m=function(){if(n){if(typeof n.getRandomValues=="function")try{return n.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof n.randomBytes=="function")try{return n.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},x=Object.create||function(){function d(){}return function(l){var v;return d.prototype=l,v=new d,d.prototype=null,v}}(),p={},a=p.lib={},c=a.Base=function(){return{extend:function(d){var l=x(this);return d&&l.mixIn(d),(!l.hasOwnProperty("init")||this.init===l.init)&&(l.init=function(){l.$super.init.apply(this,arguments)}),l.init.prototype=l,l.$super=this,l},create:function(){var d=this.extend();return d.init.apply(d,arguments),d},init:function(){},mixIn:function(d){for(var l in d)d.hasOwnProperty(l)&&(this[l]=d[l]);d.hasOwnProperty("toString")&&(this.toString=d.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),g=a.WordArray=c.extend({init:function(d,l){d=this.words=d||[],l!=i?this.sigBytes=l:this.sigBytes=d.length*4},toString:function(d){return(d||u).stringify(this)},concat:function(d){var l=this.words,v=d.words,E=this.sigBytes,_=d.sigBytes;if(this.clamp(),E%4)for(var A=0;A<_;A++){var w=v[A>>>2]>>>24-A%4*8&255;l[E+A>>>2]|=w<<24-(E+A)%4*8}else for(var I=0;I<_;I+=4)l[E+I>>>2]=v[I>>>2];return this.sigBytes+=_,this},clamp:function(){var d=this.words,l=this.sigBytes;d[l>>>2]&=4294967295<<32-l%4*8,d.length=s.ceil(l/4)},clone:function(){var d=c.clone.call(this);return d.words=this.words.slice(0),d},random:function(d){for(var l=[],v=0;v<d;v+=4)l.push(m());return new g.init(l,d)}}),o=p.enc={},u=o.Hex={stringify:function(d){for(var l=d.words,v=d.sigBytes,E=[],_=0;_<v;_++){var A=l[_>>>2]>>>24-_%4*8&255;E.push((A>>>4).toString(16)),E.push((A&15).toString(16))}return E.join("")},parse:function(d){for(var l=d.length,v=[],E=0;E<l;E+=2)v[E>>>3]|=parseInt(d.substr(E,2),16)<<24-E%8*4;return new g.init(v,l/2)}},h=o.Latin1={stringify:function(d){for(var l=d.words,v=d.sigBytes,E=[],_=0;_<v;_++){var A=l[_>>>2]>>>24-_%4*8&255;E.push(String.fromCharCode(A))}return E.join("")},parse:function(d){for(var l=d.length,v=[],E=0;E<l;E++)v[E>>>2]|=(d.charCodeAt(E)&255)<<24-E%4*8;return new g.init(v,l)}},y=o.Utf8={stringify:function(d){try{return decodeURIComponent(escape(h.stringify(d)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(d){return h.parse(unescape(encodeURIComponent(d)))}},f=a.BufferedBlockAlgorithm=c.extend({reset:function(){this._data=new g.init,this._nDataBytes=0},_append:function(d){typeof d=="string"&&(d=y.parse(d)),this._data.concat(d),this._nDataBytes+=d.sigBytes},_process:function(d){var l,v=this._data,E=v.words,_=v.sigBytes,A=this.blockSize,w=A*4,I=_/w;d?I=s.ceil(I):I=s.max((I|0)-this._minBufferSize,0);var B=I*A,C=s.min(B*4,_);if(B){for(var F=0;F<B;F+=A)this._doProcessBlock(E,F);l=E.splice(0,B),v.sigBytes-=C}return new g.init(l,C)},clone:function(){var d=c.clone.call(this);return d._data=this._data.clone(),d},_minBufferSize:0});a.Hasher=f.extend({cfg:c.extend(),init:function(d){this.cfg=this.cfg.extend(d),this.reset()},reset:function(){f.reset.call(this),this._doReset()},update:function(d){return this._append(d),this._process(),this},finalize:function(d){d&&this._append(d);var l=this._doFinalize();return l},blockSize:16,_createHelper:function(d){return function(l,v){return new d.init(v).finalize(l)}},_createHmacHelper:function(d){return function(l,v){return new b.HMAC.init(d,v).finalize(l)}}});var b=p.algo={};return p}(Math);return t})}(Et)),Et.exports}(function(r,e){(function(t,s){r.exports=s(L())})(N,function(t){return t.enc.Utf8})})(I0);var ws=I0.exports;const R0=Te(ws);var gt={exports:{}},O0;function Be(){return O0||(O0=1,function(r,e){(function(t,s){r.exports=s(L())})(N,function(t){return function(){var s=t,i=s.lib,n=i.WordArray,m=s.enc;m.Base64={stringify:function(p){var a=p.words,c=p.sigBytes,g=this._map;p.clamp();for(var o=[],u=0;u<c;u+=3)for(var h=a[u>>>2]>>>24-u%4*8&255,y=a[u+1>>>2]>>>24-(u+1)%4*8&255,f=a[u+2>>>2]>>>24-(u+2)%4*8&255,b=h<<16|y<<8|f,d=0;d<4&&u+d*.75<c;d++)o.push(g.charAt(b>>>6*(3-d)&63));var l=g.charAt(64);if(l)for(;o.length%4;)o.push(l);return o.join("")},parse:function(p){var a=p.length,c=this._map,g=this._reverseMap;if(!g){g=this._reverseMap=[];for(var o=0;o<c.length;o++)g[c.charCodeAt(o)]=o}var u=c.charAt(64);if(u){var h=p.indexOf(u);h!==-1&&(a=h)}return x(p,a,g)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function x(p,a,c){for(var g=[],o=0,u=0;u<a;u++)if(u%4){var h=c[p.charCodeAt(u-1)]<<u%4*2,y=c[p.charCodeAt(u)]>>>6-u%4*2,f=h|y;g[o>>>2]|=f<<24-o%4*8,o++}return n.create(g,o)}}(),t.enc.Base64})}(gt)),gt.exports}var Fs=Be();const Re=Te(Fs);class je{$blank(e){return se(e)}$present(e){return!this.$blank(e)}$type(e,t){return ze(e,t)}$uuid(){return S0()}$encrypt(e){return this.$type(e,"object")&&(e=JSON.stringify(e)),Re.stringify(R0.parse(e))}$decrypt(e){return R0.stringify(Re.parse(e))}getUserAgent(){return window.navigator.userAgent}}const Ke={debug:1,info:2,warning:3,error:4},H={level:Ke.warning,setLogLevel(r){this.level=r},messageStringify(r,e){try{return e=`${r}: ${ze(e,"object")?JSON.stringify(e):e}`}catch(t){console.error(`log parse error: ${t}`)}},debug(r,e){this.level<=Ke.debug&&console.log(this.messageStringify(r,e))},info(r,e){this.level<=Ke.info&&console.info(this.messageStringify(r,e))},warn(r,e){this.level<=Ke.warning&&console.warn(this.messageStringify(r,e))},error(r,e){this.level<=Ke.error&&console.error(this.messageStringify(r,e))}};class Ds extends je{constructor(){super(),this.$storage={}}get(e){let t="";try{t=window.localStorage.getItem(e)}catch{t=this.$storage[e]}return this.$present(t)?this.$decrypt(t):void 0}set(e,t){try{window.localStorage.setItem(e,this.$encrypt(t))}catch{this.$storage[e]=this.$encrypt(t)}return t}currentUserUUID(){const e=Z.STORAGE_PREFIX("uuid"),t=this.get(e);return this.$blank(t)?this.set(e,this.$uuid()):t}setUUID(e){const t=Z.STORAGE_PREFIX("uuid");return this.set(t,e)}getToJSON(e){const t=this.get(e);return this.$present(t)?this.caseMarshalToJson(t):t}setToJSON(e,t){return this.set(e,JSON.stringify(t)),t}caseMarshalToJson(e){try{return JSON.parse(e)}catch{return JSON.parse(e.replace(/\\\"/g,'"'))}}}class $s extends Ds{constructor(){super(),this.currentUserUUID()}currentSessionKey(){const e=Math.round(new Date().getTime()/1e3),t=Z.STORAGE_PREFIX("session"),s=this.getToJSON(t);return this.$blank(s)||s.time+1800<e?this.setToJSON(t,{time:e,term:this.$blank(s)?-1:e-s.time,uuid:`${this.$uuid()}-${e}`}).uuid:s.uuid}currentTimeTerm(){const e=Z.STORAGE_PREFIX("session"),t=this.getToJSON(e);return this.$blank(t.term)?-1:t.term}currentTime(){const e=Z.STORAGE_PREFIX("session"),t=this.getToJSON(e);return this.$blank(t.time)?-1:t.time}setTime(e){const t=Math.round(new Date().getTime()/1e3),s=Z.STORAGE_PREFIX("session"),i=this.getToJSON(s),n=this.$blank(i)?{time:e>0?e:t,term:e>0?t-e:-1,uuid:`${this.$uuid()}-${t}`}:i;n.time=e,this.setToJSON(s,n)}generateKey(){return`${this.$uuid()}-${new Date().getTime()}`}setUser(e){return this.set(Z.STORAGE_PREFIX("user"),e===void 0?void 0:JSON.stringify(e)),e}getUser(){try{return JSON.parse(this.get(Z.STORAGE_PREFIX("user")))}catch(e){H.error("User Storage",`사용자 정보를 추출하는데 실패하였습니다. [ ${e.message} ]`);return}}}const $e=new $s,ke={name:"@bootpay/client-js",version:"5.3.0-beta.3",main:"dist/index.mjs",exports:{".":{import:"./dist/index.mjs",types:"./dist/index.d.ts"}},styles:"dist/index.css",scripts:{test:'echo "Error: no test specified" && exit 1',build:"rm -rf ./dist && vite build",deploy:"NODE_ENV=production ./node_modules/.bin/webpack --output-path=./dist --mode=production && gzip -kf dist/*.min.js && ./webview.sh $npm_package_version"},dependencies:{typescript:"^5.5.4"},devDependencies:{"@types/ws":"^8.5.5","@types/node":"^18.15.3","@webpack-cli/serve":"^2.0.5","webpack-dev-server":"^4.15.1",webpack:"^5.87.0","webpack-cli":"^5.1.4",axios:"^0.27.2","crypto-js":"^4.1.1","@types/crypto-js":"^4.1.1","@babel/core":"^7.22.5","@babel/plugin-transform-regenerator":"^7.22.5","@babel/plugin-transform-runtime":"^7.22.5","@babel/plugin-transform-object-assign":"^7.22.5","@babel/plugin-proposal-class-properties":"^7.18.6","@babel/plugin-transform-destructuring":"^7.24.8","@babel/plugin-proposal-export-default-from":"^7.27.1","@babel/plugin-transform-class-properties":"^7.27.1","@babel/plugin-proposal-decorators":"^7.28.0","@babel/plugin-transform-private-methods":"^7.27.1","@babel/plugin-transform-typescript":"^7.28.0","@babel/preset-env":"^7.22.5","@babel/preset-typescript":"^7.22.5","@babel/runtime-corejs3":"^7.22.5","@babel/plugin-transform-classes":"^7.22.5","core-js":"^3.31.0","babel-loader":"^9.1.2","css-loader":"^6.8.1",sass:"^1.63.4","sass-loader":"^13.3.2","style-loader":"^3.3.3",vite:"^5.4.3","vite-plugin-dts":"^3.6.4","vite-plugin-tsconfig":"^1.0.4","vite-plugin-css-injected-by-js":"3.3.1"},resolutions:{"@webpack-cli/serve":"^1.3.1"},keywords:[],author:"",license:"ISC",description:""},R={mode:"production",locale:"ko",isSetLocale:!1,packageVersion:ke.version,applicationId:"",API_URL:{development:"https://dev-api.bootpay.co.kr/v2",stage:"https://stage-api.bootpay.co.kr/v2",production:"https://api.bootpay.co.kr/v2"},ANALYTICS_URL:{development:"https://dev-analytics.bootpay.co.kr",stage:"https://stage-analytics.bootpay.co.kr",production:"https://analytics.bootpay.co.kr"},DOOR_URL:{development:"https://door-dev.bootpay.co.kr",stage:"https://door-stage.bootpay.co.kr",production:"https://door.bootpay.co.kr"},WIDGET_URL:{development:"https://dev-widget.bootpay.co.kr",stage:"https://stage-widget.bootpay.co.kr",production:"https://widget.bootpay.co.kr"},sdkNames:{android:100,android_react_native:101,android_flutter:102,android_unity:103,ios:200,ios_react_native:201,ios_flutter:202,ios_unity:203,ios_objc:204,ios_swift_ui:205,mac_swift:206,mac_flutter:207},sdkVersion:"",sdkName:0,set(r){this.mode=r},setApplicationId(r){return this.applicationId=r,this.currentApplicationId(void 0)},setLocale(r){this.locale=r,this.isSetLocale=!0},currentApplicationId(r=void 0){return r===void 0?this.applicationId:r},setDevelopmentHost(r){this.API_URL.development=this.API_URL.development.replace(/dev-api.bootpay.co.kr\/v2/gi,r)},setVersion(r,e,t=void 0){this.sdkName=this.sdkNames[e]===void 0?0:this.sdkNames[e],this.sdkVersion=r,this.packageVersion=t===void 0||t===""?ke.version:t},toApi(r){return[this.API_URL[this.mode],r].join("/")},toDoor(r){return[this.DOOR_URL[this.mode],r].join("/")},toWidget(r){return[this.WIDGET_URL[this.mode],r].join("/")},isMobile(){if(typeof window>"u")return!1;const r=window.navigator.userAgent||window.navigator.vendor;return/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Silk-Accelerated|(hpw|web)OS|Fennec|Minimo|Opera M(obi|ini)|Blazer|Dolfin|Dolphin|Skyfire|Zune/.test(r)},isMobileSafari(){if(typeof window>"u")return!1;const r=window.navigator.userAgent;return(r.match(/iPad/i)||r.match(/iPhone/i))&&!r.match(/CriOS/i)},toAnalytics(r){return[this.ANALYTICS_URL[this.mode],r].join("/")}};class ae extends Error{constructor(e){super(),this.name="BootpayEventError",this.eventMessage=e}}const Pe={__BOOTPAY_NAMESPACE:{},isBind:!1,initialize(){this.isBind||(typeof window<"u"&&(window.addBootpayEventListener=this.on,window.removeBootpayEventListener=this.off,window.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),typeof document<"u"&&(document.addBootpayEventListener=this.on,document.removeBootpayEventListener=this.off,document.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),typeof Element<"u"&&(Element.prototype.addBootpayEventListener=this.on,Element.prototype.removeBootpayEventListener=this.off,Element.prototype.resetBootpayEventListener=function(r,e,t){this.removeBootpayEventListener(r).addBootpayEventListener(r,e,t)}),this.isBind=!0)},on(r,e,t=void 0){return se(Pe.__BOOTPAY_NAMESPACE)&&(Pe.__BOOTPAY_NAMESPACE={}),this.addEventListener(r.split(".")[0],e,t||!1),Pe.__BOOTPAY_NAMESPACE[r]=e,this},off(r){return q(Pe.__BOOTPAY_NAMESPACE)&&q(Pe.__BOOTPAY_NAMESPACE[r])&&this.removeEventListener(r.split(".")[0],Pe.__BOOTPAY_NAMESPACE[r]),this}};class Ge extends je{constructor(e){super(),this.$resolve=null,this.$reject=null,this.$messageEventName=(e==null?void 0:e.messageEventName)??"message.BootpayEvent",this.$eventHooks=(e==null?void 0:e.messageEventHooks)??{},this.afterBind=e==null?void 0:e.afterBind,this.$childInstance=null,Pe.initialize()}setChildInstance(e){this.$childInstance=e}bind(e,t){this.$messageEventName&&window.resetBootpayEventListener(this.$messageEventName,s=>{const i=this.parseEvent(s.data);if(H.debug("event received",JSON.stringify(i)),q(i)&&q(i.event)){const n=this.hookFunction(i.hook);if(q(n)&&q(n[i.event]))return n[i.event](i.data,this);H.debug("event",`${this.$messageEventName}: ${i.event} is not defined`)}}),this.afterBind&&this.afterBind(),this.setCallbackFunction(e,t)}hookFunction(e){return this.$eventHooks[e]}reject(e){q(this.$reject)&&this.$reject(e)}resolve(e){q(this.$resolve)&&this.$resolve(e)}setCallbackFunction(e,t){this.$resolve=e,this.$reject=t}parseEvent(e){let t={};if(this.$present(e)&&this.$type(e,"string")){try{t=JSON.parse(e)}catch(s){H.info("json parsing failed",`data: ${e}, message: ${Xe(s)} JSON 파싱 형태가 아닌 이벤트 입니다.`)}return t.bootpay_event?(delete t.bootpay_event,t):null}else return null}}const Xe=r=>typeof r=="string"?r.toUpperCase():r instanceof Error?r.message:r;class be extends je{constructor(e={}){super();const{iframeId:t="bootpay-iframe",template:s=this.defaultIframeHtml(),el:i=void 0}=e;this.el=i,this.$windowId=t,this.$template=s}defaultIframeHtml(){return`
3
3
  <iframe id="${this.$iFrameId}" src="" frameborder="0" allowtransparency="true" scrolling="no" style="background: transparent; width: 100%; height: 100%;"></iframe>
4
4
  `}byId(e){return document.getElementById(e)}createTemplateHtml(){this.byId(this.$windowId)===null&&document.body.insertAdjacentHTML("beforeend",this.$template)}bodyOpen(e=void 0,t=!1){const s=document.querySelector("body");t||(this.$present(s.className)?s.className=`${s.className} bootpay-open`:s.className="bootpay-open"),this.$present(e)&&(s.className=`${s.className} ${e}`)}bodyClose(){const e=document.querySelector("body");e.className=e.className.replace("bootpay-open","")}templateResize(e,t){const s=this.byId(e);s!==void 0&&this.applyStylesToElement(s,t)}applyStylesToElement(e,t){if(t!==void 0)for(let s in Object.keys(t)){let i=Object.keys(t)[s],n=t[i];this.$present(n)&&!String(n).match(/%/)&&!String(n).match(/vh/)&&(i.match(/width/)||i.match(/Width/)||i.match(/height/)||i.match(/Height/))&&(n=`${String(t[i]).replace(/px/gi,"")}px`),e.style.setProperty(i,n)}}isRendered(){const e=document.getElementById(this.$iFrameId);return H.debug("isRendered",`iFrameElement: ${e}`),e!==null&&e.src!==null&&e.src!==""}postMessage(e,t=void 0){var i;const s=this.byId(this.$iFrameId);(i=s==null?void 0:s.contentWindow)==null||i.postMessage(JSON.stringify({bootpay_event:!0,event:e,data:t}),"*")}defaultRender(e){this.el=String(this.el).replace(/#/g,"");const t=document.getElementById(this.el);if(this.$blank(this.el)||t===null)throw new Error("렌더링할 DOM Element ID를 입력해주세요.");t.style.setProperty("height","0"),t.innerHTML=this.$template,this.byId(this.$iFrameId).setAttribute("src",e)}}class ks extends be{constructor(){super(),this.$alfredId="bootpay-alfred-progress-id",this.$alfredTextId="__alfred-text-message__"}template(e){return`
5
5
  <div class="bootpay-progress-background" id="${this.$alfredId}" style="display: none;">
@@ -71,7 +71,7 @@
71
71
  <iframe class="${this.$additionalClass}" id="${this.$iFrameId}" name="${this.$iFrameId}" frameborder="0"></iframe>
72
72
  </div>
73
73
  </div>
74
- `}createIFrame(e){this.createTemplateHtml();const t=document.getElementById(this.$iFrameId);t==null||t.setAttribute("src",R.toWidget(`${e}`)),t==null||t.style.setProperty("display","block"),this.bodyOpen("bootpay-mobile")}templateRender(e){this.$template=this.template({isBackground:!1});const t=document.getElementById(this.$widgetStore.el);t.innerHTML=this.$template;const s=this.byId(this.$iFrameId);s.setAttribute("src",R.toWidget(e)),s.setAttribute("style","border: 0; outline: 0;")}addWallet(e){this.createIFrame(e)}removeWallet(e){this.createIFrame(`brandpay/destroy/${this.$widgetStore.data.application_id}/${e}`)}showCardInterestInformation(e){this.createIFrame(`card/interest/${this.$widgetStore.data.application_id}`)}brandpayPreference(e){var i,n;const{popup:t}=e;this.$widgetStore.data.sdk_option={use_fixed_size:e.size!==void 0,size:{width:((i=e.size)==null?void 0:i.width)||500,height:((n=e.size)==null?void 0:n.height)||800}};const s=`brandpay/${this.$widgetStore.data.application_id}/${this.$widgetStore.encryptParameters()}/edit`;console.log("url",s),t||R.isMobile()?window.open(R.toWidget(`${s}?__popup=true`),"widget-brandpay-environment-popup",`width=${e.size.width},height=${e.size.height},scrollbars=yes`).focus():this.createIFrame(s)}externalPassword({popup:e,url:t}){e||R.isMobile()?window.open(R.toWidget(`${t}?__popup=true`),"widget-brandpay-external-password-popup","width=500,height=800,scrollbars=yes").focus():this.createIFrame(t)}destroy(){const e=document.getElementById(this.$windowId);e!==void 0&&(e.outerHTML="",e.remove()),this.bodyClose()}resize(e){this.templateResize(this.$iFrameId,e)}postMessage(e,t=void 0){var i;const s=this.byId(this.$iFrameId);(i=s==null?void 0:s.contentWindow)==null||i.postMessage(JSON.stringify({bootpay_event:!0,event:e,data:t}),"*")}}const ne=new wn;class Fn extends be{constructor(){super(),this.$windowId="__bootpay-modal-window-container",this.$modalWindowId="__bootpay-modal-window",this.$iFrameId="__bootpay-modal-iframe",this.$additionalClass=R.isMobile()?"":"rounded-iframe",this.$template=this.template()}template(){return`
74
+ `}createIFrame(e){this.createTemplateHtml();const t=document.getElementById(this.$iFrameId);t==null||t.setAttribute("src",R.toWidget(`${e}`)),t==null||t.style.setProperty("display","block"),this.bodyOpen("bootpay-mobile")}templateRender(e){this.$template=this.template({isBackground:!1});const t=document.getElementById(this.$widgetStore.el);t.innerHTML=this.$template;const s=this.byId(this.$iFrameId);s.setAttribute("src",R.toWidget(e)),s.setAttribute("style","border: 0; outline: 0;")}addWallet(e){this.createIFrame(e)}removeWallet(e){this.createIFrame(`brandpay/destroy/${this.$widgetStore.resolve_auth_credential}/${e}`)}showCardInterestInformation(e){this.createIFrame(`card/interest/${this.$widgetStore.resolve_auth_credential}`)}brandpayPreference(e){var i,n;const{popup:t}=e;this.$widgetStore.data.sdk_option={use_fixed_size:e.size!==void 0,size:{width:((i=e.size)==null?void 0:i.width)||500,height:((n=e.size)==null?void 0:n.height)||800}};const s=`brandpay/${this.$widgetStore.resolve_auth_credential}/${this.$widgetStore.encryptParameters()}/edit`;t||R.isMobile()?window.open(R.toWidget(`${s}?__popup=true`),"widget-brandpay-environment-popup",`width=${e.size.width},height=${e.size.height},scrollbars=yes`).focus():this.createIFrame(s)}externalPassword({popup:e,url:t}){e||R.isMobile()?window.open(R.toWidget(`${t}?__popup=true`),"widget-brandpay-external-password-popup","width=500,height=800,scrollbars=yes").focus():this.createIFrame(t)}destroy(){const e=document.getElementById(this.$windowId);e!==void 0&&(e.outerHTML="",e.remove()),this.bodyClose()}resize(e){this.templateResize(this.$iFrameId,e)}postMessage(e,t=void 0){var i;const s=this.byId(this.$iFrameId);(i=s==null?void 0:s.contentWindow)==null||i.postMessage(JSON.stringify({bootpay_event:!0,event:e,data:t}),"*")}}const ne=new wn;class Fn extends be{constructor(){super(),this.$windowId="__bootpay-modal-window-container",this.$modalWindowId="__bootpay-modal-window",this.$iFrameId="__bootpay-modal-iframe",this.$additionalClass=R.isMobile()?"":"rounded-iframe",this.$template=this.template()}template(){return`
75
75
  <div id="${this.$windowId}" class="bootpay-payment-background">
76
76
  <div class="bootpay-payment-window ${R.isMobile()?"__mobile":""}" id="${this.$modalWindowId}">
77
77
  <iframe class="${this.$additionalClass}" id="${this.$iFrameId}" name="${this.$iFrameId}"></iframe>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bootpay/client-js",
3
- "version": "5.3.0-beta.2",
3
+ "version": "5.3.0-beta.3",
4
4
  "main": "dist/index.mjs",
5
5
  "exports": {
6
6
  ".": {