@alipay/ams-checkout 2.0.20 → 2.0.21

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.
Files changed (51) hide show
  1. package/ams-checkout.js +3 -3
  2. package/dist/ams-checkout.min.js +1 -1
  3. package/esm/config/index.d.ts +7 -0
  4. package/esm/config/index.js +2 -2
  5. package/esm/constant/element.d.ts +2 -1
  6. package/esm/constant/element.js +1 -0
  7. package/esm/constant/index.d.ts +4 -21
  8. package/esm/core/component/element/elementController/index.d.ts +3 -3
  9. package/esm/core/component/element/elementController/index.js +66 -42
  10. package/esm/core/component/element/elementProcessor/paymentProcessor.js +13 -10
  11. package/esm/core/component/element/index.d.ts +4 -1
  12. package/esm/core/component/element/index.js +19 -4
  13. package/esm/core/component/element/mock.js +1 -1
  14. package/esm/core/component/element/modernElementController/adapter.d.ts +19 -0
  15. package/esm/core/component/element/modernElementController/adapter.js +79 -0
  16. package/esm/core/component/element/modernElementController/index.d.ts +155 -0
  17. package/esm/core/component/element/modernElementController/index.js +1780 -0
  18. package/esm/core/component/element/type.d.ts +16 -18
  19. package/esm/core/instance/index.d.ts +12 -4
  20. package/esm/core/instance/index.js +152 -26
  21. package/esm/foundation/service/event-center.js +1 -1
  22. package/esm/foundation/service/security/index.d.ts +9 -4
  23. package/esm/foundation/service/security/index.js +158 -35
  24. package/esm/foundation/service/security/security.d.ts +22 -1
  25. package/esm/foundation/service/security/security.js +150 -37
  26. package/esm/foundation/utils/preload_helper.d.ts +6 -3
  27. package/esm/foundation/utils/preload_helper.js +122 -32
  28. package/esm/main.js +4 -4
  29. package/esm/modern/global.d.ts +3 -0
  30. package/esm/modern/index.d.ts +5 -1
  31. package/esm/modern/index.js +1 -51
  32. package/esm/modern/tools.js +1 -0
  33. package/esm/plugin/component/channel.d.ts +2 -2
  34. package/esm/plugin/component/channel.js +18 -18
  35. package/esm/plugin/component/index.js +36 -29
  36. package/esm/tsdoc-metadata.json +1 -1
  37. package/esm/types/index.d.ts +1 -0
  38. package/esm/util/beforeConfirm.d.ts +4 -2
  39. package/esm/util/beforeConfirm.js +15 -14
  40. package/esm/util/jshield-apdid/apdid-loader.js +377 -0
  41. package/esm/util/jshield-apdid/index.js +21 -0
  42. package/esm/util/logger.js +1 -2
  43. package/esm/util/security-registry.d.ts +72 -0
  44. package/esm/util/security-registry.js +175 -0
  45. package/esm/util/security.d.ts +22 -1
  46. package/esm/util/security.js +150 -39
  47. package/package.json +15 -9
  48. package/types.d.ts +840 -1103
  49. package/types.untrimmed.d.ts +992 -1122
  50. package/esm/modern/stageName.d.ts +0 -3
  51. package/esm/modern/stageName.js +0 -1
@@ -0,0 +1 @@
1
+ !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var n=t();for(var r in n)("object"==typeof exports?exports:e)[r]=n[r]}}(self,(function(){return function(){var e={8306:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},i=this&&this.__generator||function(e,t){var n,r,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(u){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(n=1,r&&(i=2&s[0]?r.return:s[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,s[1])).done)return i;switch(r=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(i=o.trys,(i=i.length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{n=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.loadScript=void 0,t.createSingletonInstance=u,t.createInstance=c,t.createLoader=function(e){var t=this,n=e.sdkURL,s=e.globalName,l=e.timeout,h=void 0===l?2e4:l,f=e.onLoadComplete,p=e.onError,d=e.onLoadStart,g=e.onInitialized,v=e.single,m=void 0===v||v,y=e.namespace;return function(e){return r(t,void 0,void 0,(function(){var t,l,v=this;return i(this,(function(_){var b,E;return null==d||d(),t=Date.now(),o.tracker.log({code:"7988",msg:y,d1:"loadStart",d2:"无",d3:"无",d4:"无",d5:"npm",m1:0,m2:0}),b=function(){return(0,a.loadScriptClass)(n,s)},E=h,l=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Promise.race([new Promise((function(e,t){setTimeout((function(){t(new a.LoaderError("LOAD_TIMEOUT","Load timeout: ".concat(E)))}),E)})),b.apply(void 0,e)])},[2,l().then((function(n){return r(v,[n],void 0,(function(n){var r,l,h,p=n.variable,d=n.cache;return i(this,(function(n){switch(n.label){case 0:if(r=Date.now(),d||o.tracker.log({code:"7988",msg:y,d1:"loadComplete",d2:"无",d3:"无",d4:(null==p?void 0:p.version)||"无",d5:"npm",m1:Math.round(Date.now()-t),m2:0}),null==f||f(),!p)throw new a.LoaderError("NO_REMOTE_CLASS","No variables ".concat(s," were found. Cannot be initialized the Class ").concat(s));n.label=1;case 1:return n.trys.push([1,3,,4]),[4,(m?u:c)(p,e,void 0)];case 2:return l=n.sent(),o.tracker.log({code:"7988",msg:y,d1:"initialized",d2:"无",d3:"无",d4:l.version||"无版本号",d5:"npm",m1:Math.round(Date.now()-t),m2:Math.round(Date.now()-r)}),null==g||g(l,window.location.href),[2,l];case 3:throw h=n.sent(),new a.LoaderError("INIT_ERROR","Initialize Class ".concat(s," failed: ").concat(h.message));case 4:return[2]}}))}))})).catch((function(e){var n=a.LoaderError.unificationError(e);return o.tracker.log({code:"7988",msg:y,d1:"createError",d2:n.code,d3:n.message,d4:"无",d5:"npm",m1:Math.round(Date.now()-t),m2:0}),null==p||p(n),Promise.reject(e)}))]}))}))}};var o=n(2611),a=n(7880);Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return a.loadScript}});var s=null;function u(e,t,n){return s||(s=c(e,t,n))}function c(e,t,n){var r=new e(t),i=Date.now();return r.init().then((function(e){return n&&o.tracker.log({code:"7988",msg:n,d1:"initialized",d2:"无",d3:"无",d4:r.version||"无版本号",d5:"umd",m1:Math.round(Date.now()-i),m2:Math.round(Date.now()-i)}),e})).catch((function(e){var t=new a.LoaderError("INIT_ERROR","Initialize Class failed: ".concat(e.message));throw n&&o.tracker.log({code:"7988",msg:n,d1:"createError",d2:t.code,d3:t.message,d4:"无",d5:"umd",m1:Math.round(Date.now()-i),m2:0}),t}))}},2611:function(e,t,n){"use strict";var r,i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},i.apply(this,arguments)},o=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},a=this&&this.__generator||function(e,t){var n,r,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(u){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(n=1,r&&(i=2&s[0]?r.return:s[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,s[1])).done)return i;switch(r=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(i=o.trys,(i=i.length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{n=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.tracker=t.ScriptTracker=void 0;var s=n(7880),u=function(){function e(e){Object.defineProperty(this,"initOptions",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"tracker",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.initOptions=e}return Object.defineProperty(e.prototype,"loadTacker",{enumerable:!1,configurable:!0,writable:!0,value:function(){var e=this;return(0,s.loadScript)("https://cdn.marmot-cloud.com/tnpm-package/@antintl-intl-tracker/1.3.0/dist/common.min.js","CompatibleTrackerFull").then((function(t){var n=null==t?void 0:t.variable;if(n)return new n(i({compactExtraInfo:!0,appId:"180020050100012557"},e.initOptions))})).catch((function(){}))}}),Object.defineProperty(e.prototype,"getTracker",{enumerable:!1,configurable:!0,writable:!0,value:function(){return o(this,void 0,void 0,(function(){var e;return a(this,(function(t){switch(t.label){case 0:return this.tracker?[2,this.tracker]:[4,this.loadTacker()];case 1:return(e=t.sent())&&(e.set({keyFormat:"origin",userPathAuto:!1}),this.tracker=e),[2,e]}}))}))}}),Object.defineProperty(e.prototype,"safeCall",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return this.getTracker().then(e)}}),Object.defineProperty(e.prototype,"log",{enumerable:!1,configurable:!0,writable:!0,value:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.safeCall((function(t){return null==t?void 0:t.log.apply(t,e)}))}}),e}();t.ScriptTracker=u;var c=(null===(r="PROD")?void 0:r.toUpperCase())||"PROD",l=["DEV","SIT","PRE","PROD","LOCAL"].includes(c)?c:"PROD";t.tracker=new u({appId:"180020050100012557",env:l,server:"sg",performance:!1,error:!1})},7880:function(e,t){"use strict";var n,r=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.LoaderError=void 0,t.loadScriptClass=function(e,t){return o(e,t)},t.loadScript=o;var i=function(e){function t(t,n){var r=e.call(this,n)||this;return Object.defineProperty(r,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),r.name="LoaderError",r.code=t,r}return r(t,e),Object.defineProperty(t,"unificationError",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return e instanceof t||e instanceof Error&&"LoaderError"===e.name?e:new t("UNKNOWN_ERROR",e instanceof Error?e.message:"An unknown error occurred.")}}),t}(Error);function o(e,t){var n=function(){if("function"==typeof t)return t();var e=window[t];return(null==e?void 0:e.default)||e};return new Promise((function(t,r){var o=n();if(o)return t({cache:!0,variable:o});var a=document.querySelector('script[src="'.concat(e,'"]')),s=a||document.createElement("script");s.src=e,s.async=!0,s.addEventListener("load",(function(){t({cache:!1,variable:n()})})),s.addEventListener("error",(function(t){r(new i("LOAD_ERROR","Load script ".concat(e," failed: ").concat(t.message)))})),a||document.head.appendChild(s)}))}t.LoaderError=i},7861:function(e,t){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,o=u(e),a=o[0],s=o[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),l=0,h=s>0?a-4:a;for(n=0;n<h;n+=4)t=r[e.charCodeAt(n)]<<18|r[e.charCodeAt(n+1)]<<12|r[e.charCodeAt(n+2)]<<6|r[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===s&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,r=e.length,i=r%3,o=[],a=16383,s=0,u=r-i;s<u;s+=a)o.push(c(e,s,s+a>u?u:s+a));1===i?(t=e[r-1],o.push(n[t>>2]+n[t<<4&63]+"==")):2===i&&(t=(e[r-2]<<8)+e[r-1],o.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"="));return o.join("")};for(var n=[],r=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a<s;++a)n[a]=o[a],r[o.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function c(e,t,r){for(var i,o,a=[],s=t;s<r;s+=3)i=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(n[(o=i)>>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return a.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},6207:function(e,t,n){"use strict";var r=n(7861),i=n(9090),o=n(8736);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()<t)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=u.prototype:(null===e&&(e=new u(t)),e.length=t),e}function u(e,t,n){if(!(u.TYPED_ARRAY_SUPPORT||this instanceof u))return new u(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return h(this,e)}return c(this,e,t,n)}function c(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);u.TYPED_ARRAY_SUPPORT?(e=t).__proto__=u.prototype:e=f(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!u.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,n);e=s(e,r);var i=e.write(t,n);i!==r&&(e=e.slice(0,i));return e}(e,t,n):function(e,t){if(u.isBuffer(t)){var n=0|p(t.length);return 0===(e=s(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?s(e,0):f(e,t);if("Buffer"===t.type&&o(t.data))return f(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function h(e,t){if(l(t),e=s(e,t<0?0:0|p(t)),!u.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function f(e,t){var n=t.length<0?0:0|p(t.length);e=s(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function d(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return z(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return Y(e).length;default:if(r)return z(e).length;t=(""+t).toLowerCase(),r=!0}}function g(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return N(this,t,n);case"utf8":case"utf-8":return P(this,t,n);case"ascii":return k(this,t,n);case"latin1":case"binary":return L(this,t,n);case"base64":return T(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function v(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,i){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:y(e,t,n,r,i);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):y(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function y(e,t,n,r,i){var o,a=1,s=e.length,u=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var l=-1;for(o=n;o<s;o++)if(c(e,o)===c(t,-1===l?0:o-l)){if(-1===l&&(l=o),o-l+1===u)return l*a}else-1!==l&&(o-=o-l),l=-1}else for(n+u>s&&(n=s-u),o=n;o>=0;o--){for(var h=!0,f=0;f<u;f++)if(c(e,o+f)!==c(t,f)){h=!1;break}if(h)return o}return-1}function _(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r))>i&&(r=i):r=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a<r;++a){var s=parseInt(t.substr(2*a,2),16);if(isNaN(s))return a;e[n+a]=s}return a}function b(e,t,n,r){return G(z(t,e.length-n),e,n,r)}function E(e,t,n,r){return G(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function w(e,t,n,r){return E(e,t,n,r)}function S(e,t,n,r){return G(Y(t),e,n,r)}function A(e,t,n,r){return G(function(e,t){for(var n,r,i,o=[],a=0;a<e.length&&!((t-=2)<0);++a)r=(n=e.charCodeAt(a))>>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function T(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function P(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i<n;){var o,a,s,u,c=e[i],l=null,h=c>239?4:c>223?3:c>191?2:1;if(i+h<=n)switch(h){case 1:c<128&&(l=c);break;case 2:128==(192&(o=e[i+1]))&&(u=(31&c)<<6|63&o)>127&&(l=u);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(u=(15&c)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(u=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(l=u)}null===l?(l=65533,h=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),i+=h}return function(e){var t=e.length;if(t<=R)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=R));return n}(r)}t.lW=u,t.h2=50,u.TYPED_ARRAY_SUPPORT=void 0!==n.g.TYPED_ARRAY_SUPPORT?n.g.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),a(),u.poolSize=8192,u._augment=function(e){return e.__proto__=u.prototype,e},u.from=function(e,t,n){return c(null,e,t,n)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(e,t,n){return function(e,t,n,r){return l(t),t<=0?s(e,t):void 0!==n?"string"==typeof r?s(e,t).fill(n,r):s(e,t).fill(n):s(e,t)}(null,e,t,n)},u.allocUnsafe=function(e){return h(null,e)},u.allocUnsafeSlow=function(e){return h(null,e)},u.isBuffer=function(e){return!(null==e||!e._isBuffer)},u.compare=function(e,t){if(!u.isBuffer(e)||!u.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i<o;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0},u.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(e,t){if(!o(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return u.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=u.allocUnsafe(t),i=0;for(n=0;n<e.length;++n){var a=e[n];if(!u.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(r,i),i+=a.length}return r},u.byteLength=d,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)v(this,t,t+1);return this},u.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)v(this,t,t+3),v(this,t+1,t+2);return this},u.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)v(this,t,t+7),v(this,t+1,t+6),v(this,t+2,t+5),v(this,t+3,t+4);return this},u.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?P(this,0,e):g.apply(this,arguments)},u.prototype.equals=function(e){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===u.compare(this,e)},u.prototype.inspect=function(){var e="",n=t.h2;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},u.prototype.compare=function(e,t,n,r,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(o,a),c=this.slice(r,i),l=e.slice(t,n),h=0;h<s;++h)if(c[h]!==l[h]){o=c[h],a=l[h];break}return o<a?-1:a<o?1:0},u.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},u.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},u.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},u.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var i=this.length-t;if((void 0===n||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return _(this,e,t,n);case"utf8":case"utf-8":return b(this,e,t,n);case"ascii":return E(this,e,t,n);case"latin1":case"binary":return w(this,e,t,n);case"base64":return S(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var R=4096;function k(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(127&e[i]);return r}function L(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function N(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=t;o<n;++o)i+=j(e[o]);return i}function O(e,t,n){for(var r=e.slice(t,n),i="",o=0;o<r.length;o+=2)i+=String.fromCharCode(r[o]+256*r[o+1]);return i}function I(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,n,r,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function M(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i<o;++i)e[n+i]=(t&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function D(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i<o;++i)e[n+i]=t>>>8*(r?i:3-i)&255}function x(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function B(e,t,n,r,o){return o||x(e,0,n,4),i.write(e,t,n,r,23,4),n+4}function U(e,t,n,r,o){return o||x(e,0,n,8),i.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),u.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=u.prototype;else{var i=t-e;n=new u(i,void 0);for(var o=0;o<i;++o)n[o]=this[o+e]}return n},u.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=this[e],i=1,o=0;++o<t&&(i*=256);)r+=this[e+o]*i;return r},u.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},u.prototype.readUInt8=function(e,t){return t||I(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||I(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||I(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||I(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||I(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=this[e],i=1,o=0;++o<t&&(i*=256);)r+=this[e+o]*i;return r>=(i*=128)&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||I(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||I(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||I(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||I(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||I(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||I(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||I(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||I(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||I(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||C(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o<n&&(i*=256);)this[t+o]=e/i&255;return t+n},u.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||C(this,e,t,n,Math.pow(2,8*n)-1,0);var i=n-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):D(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);C(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o<n&&(a*=256);)e<0&&0===s&&0!==this[t+o-1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);C(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):D(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return B(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return B(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return U(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return U(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var i,o=r-n;if(this===e&&n<t&&t<r)for(i=o-1;i>=0;--i)e[i+t]=this[i+n];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)e[i+t]=this[i+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+o),t);return o},u.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var i=e.charCodeAt(0);i<256&&(e=i)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!u.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var o;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(o=t;o<n;++o)this[o]=e;else{var a=u.isBuffer(e)?e:z(new u(e,r).toString()),s=a.length;for(o=0;o<n-t;++o)this[o+t]=a[o%s]}return this};var H=/[^+\/0-9A-Za-z-_]/g;function j(e){return e<16?"0"+e.toString(16):e.toString(16)}function z(e,t){var n;t=t||1/0;for(var r=e.length,i=null,o=[],a=0;a<r;++a){if((n=e.charCodeAt(a))>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function Y(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(H,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function G(e,t,n,r){for(var i=0;i<r&&!(i+n>=t.length||i>=e.length);++i)t[i+n]=e[i];return i}},8736:function(e){var t={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==t.call(e)}},9090:function(e,t){t.read=function(e,t,n,r,i){var o,a,s=8*i-r-1,u=(1<<s)-1,c=u>>1,l=-7,h=n?i-1:0,f=n?-1:1,p=e[t+h];for(h+=f,o=p&(1<<-l)-1,p>>=-l,l+=s;l>0;o=256*o+e[t+h],h+=f,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=r;l>0;a=256*a+e[t+h],h+=f,l-=8);if(0===o)o=1-c;else{if(o===u)return a?NaN:1/0*(p?-1:1);a+=Math.pow(2,r),o-=c}return(p?-1:1)*a*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var a,s,u,c=8*o-i-1,l=(1<<c)-1,h=l>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,d=r?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+h>=1?f/u:f*Math.pow(2,1-h))*u>=2&&(a++,u/=2),a+h>=l?(s=0,a=l):a+h>=1?(s=(t*u-1)*Math.pow(2,i),a+=h):(s=t*Math.pow(2,h-1)*Math.pow(2,i),a=0));i>=8;e[n+p]=255&s,p+=d,s/=256,i-=8);for(a=a<<i|s,c+=i;c>0;e[n+p]=255&a,p+=d,a/=256,c-=8);e[n+p-d]|=128*g}},8098:function(e,t,n){var r=n(4944).default,i=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,s=/^0o[0-7]+$/i,u=parseInt,c="object"==(void 0===n.g?"undefined":r(n.g))&&n.g&&n.g.Object===Object&&n.g,l="object"==("undefined"==typeof self?"undefined":r(self))&&self&&self.Object===Object&&self,h=c||l||Function("return this")(),f=Object.prototype.toString,p=Math.max,d=Math.min,g=function(){return h.Date.now()};function v(e){var t=r(e);return!!e&&("object"==t||"function"==t)}function m(e){return"symbol"==r(e)||function(e){return!!e&&"object"==r(e)}(e)&&"[object Symbol]"==f.call(e)}function y(e){if("number"==typeof e)return e;if(m(e))return NaN;if(v(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=v(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(i,"");var n=a.test(e);return n||s.test(e)?u(e.slice(2),n?2:8):o.test(e)?NaN:+e}e.exports=function(e,t,n){var r,i,o,a,s,u,c=0,l=!1,h=!1,f=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function m(t){var n=r,o=i;return r=i=void 0,c=t,a=e.apply(o,n)}function _(e){return c=e,s=setTimeout(E,t),l?m(e):a}function b(e){var n=e-u;return void 0===u||n>=t||n<0||h&&e-c>=o}function E(){var e=g();if(b(e))return w(e);s=setTimeout(E,function(e){var n=t-(e-u);return h?d(n,o-(e-c)):n}(e))}function w(e){return s=void 0,f&&r?m(e):(r=i=void 0,a)}function S(){var e=g(),n=b(e);if(r=arguments,i=this,u=e,n){if(void 0===s)return _(u);if(h)return s=setTimeout(E,t),m(u)}return void 0===s&&(s=setTimeout(E,t)),a}return t=y(t)||0,v(n)&&(l=!!n.leading,o=(h="maxWait"in n)?p(y(n.maxWait)||0,t):o,f="trailing"in n?!!n.trailing:f),S.cancel=function(){void 0!==s&&clearTimeout(s),c=0,r=u=i=s=void 0},S.flush=function(){return void 0===s?a:w(g())},S}},9414:function(e,t,n){var r=n(4944).default,i="__lodash_hash_undefined__",o="[object Function]",a="[object GeneratorFunction]",s=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,u=/^\w*$/,c=/^\./,l=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,h=/\\(\\)?/g,f=/^\[object .+?Constructor\]$/,p="object"==(void 0===n.g?"undefined":r(n.g))&&n.g&&n.g.Object===Object&&n.g,d="object"==("undefined"==typeof self?"undefined":r(self))&&self&&self.Object===Object&&self,g=p||d||Function("return this")();var v,m=Array.prototype,y=Function.prototype,_=Object.prototype,b=g["__core-js_shared__"],E=(v=/[^.]+$/.exec(b&&b.keys&&b.keys.IE_PROTO||""))?"Symbol(src)_1."+v:"",w=y.toString,S=_.hasOwnProperty,A=_.toString,T=RegExp("^"+w.call(S).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),P=g.Symbol,R=m.splice,k=H(g,"Map"),L=H(Object,"create"),N=P?P.prototype:void 0,O=N?N.toString:void 0;function I(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function C(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function M(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function D(e,t){for(var n,r,i=e.length;i--;)if((n=e[i][0])===(r=t)||n!=n&&r!=r)return i;return-1}function x(e,t){var n;t=function(e,t){if(G(e))return!1;var n=r(e);if("number"==n||"symbol"==n||"boolean"==n||null==e||K(e))return!0;return u.test(e)||!s.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:G(n=t)?n:j(n);for(var i=0,o=t.length;null!=e&&i<o;)e=e[z(t[i++])];return i&&i==o?e:void 0}function B(e){if(!F(e)||(t=e,E&&E in t))return!1;var t,n=function(e){var t=F(e)?A.call(e):"";return t==o||t==a}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?T:f;return n.test(function(e){if(null!=e){try{return w.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}function U(e,t){var n,i,o=e.__data__;return("string"==(i=r(n=t))||"number"==i||"symbol"==i||"boolean"==i?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function H(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return B(n)?n:void 0}I.prototype.clear=function(){this.__data__=L?L(null):{}},I.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},I.prototype.get=function(e){var t=this.__data__;if(L){var n=t[e];return n===i?void 0:n}return S.call(t,e)?t[e]:void 0},I.prototype.has=function(e){var t=this.__data__;return L?void 0!==t[e]:S.call(t,e)},I.prototype.set=function(e,t){return this.__data__[e]=L&&void 0===t?i:t,this},C.prototype.clear=function(){this.__data__=[]},C.prototype.delete=function(e){var t=this.__data__,n=D(t,e);return!(n<0)&&(n==t.length-1?t.pop():R.call(t,n,1),!0)},C.prototype.get=function(e){var t=this.__data__,n=D(t,e);return n<0?void 0:t[n][1]},C.prototype.has=function(e){return D(this.__data__,e)>-1},C.prototype.set=function(e,t){var n=this.__data__,r=D(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},M.prototype.clear=function(){this.__data__={hash:new I,map:new(k||C),string:new I}},M.prototype.delete=function(e){return U(this,e).delete(e)},M.prototype.get=function(e){return U(this,e).get(e)},M.prototype.has=function(e){return U(this,e).has(e)},M.prototype.set=function(e,t){return U(this,e).set(e,t),this};var j=Y((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(K(e))return O?O.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return c.test(e)&&n.push(""),e.replace(l,(function(e,t,r,i){n.push(r?i.replace(h,"$1"):t||e)})),n}));function z(e){if("string"==typeof e||K(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Y(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function n(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a),a};return n.cache=new(Y.Cache||M),n}Y.Cache=M;var G=Array.isArray;function F(e){var t=r(e);return!!e&&("object"==t||"function"==t)}function K(e){return"symbol"==r(e)||function(e){return!!e&&"object"==r(e)}(e)&&"[object Symbol]"==A.call(e)}e.exports=function(e,t,n){var r=null==e?void 0:x(e,t);return void 0===r?n:r}},8994:function(e,t,n){e=n.nmd(e);var r=n(4944).default,i="__lodash_hash_undefined__",o=9007199254740991,a="[object Arguments]",s="[object Function]",u="[object Object]",c=/^\[object .+?Constructor\]$/,l=/^(?:0|[1-9]\d*)$/,h={};h["[object Float32Array]"]=h["[object Float64Array]"]=h["[object Int8Array]"]=h["[object Int16Array]"]=h["[object Int32Array]"]=h["[object Uint8Array]"]=h["[object Uint8ClampedArray]"]=h["[object Uint16Array]"]=h["[object Uint32Array]"]=!0,h[a]=h["[object Array]"]=h["[object ArrayBuffer]"]=h["[object Boolean]"]=h["[object DataView]"]=h["[object Date]"]=h["[object Error]"]=h[s]=h["[object Map]"]=h["[object Number]"]=h[u]=h["[object RegExp]"]=h["[object Set]"]=h["[object String]"]=h["[object WeakMap]"]=!1;var f="object"==(void 0===n.g?"undefined":r(n.g))&&n.g&&n.g.Object===Object&&n.g,p="object"==("undefined"==typeof self?"undefined":r(self))&&self&&self.Object===Object&&self,d=f||p||Function("return this")(),g="object"==r(t)&&t&&!t.nodeType&&t,v=g&&"object"==r(e)&&e&&!e.nodeType&&e,m=v&&v.exports===g,y=m&&f.process,_=function(){try{var e=v&&v.require&&v.require("util").types;return e||y&&y.binding&&y.binding("util")}catch(e){}}(),b=_&&_.isTypedArray;function E(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var w,S,A,T=Array.prototype,P=Function.prototype,R=Object.prototype,k=d["__core-js_shared__"],L=P.toString,N=R.hasOwnProperty,O=(w=/[^.]+$/.exec(k&&k.keys&&k.keys.IE_PROTO||""))?"Symbol(src)_1."+w:"",I=R.toString,C=L.call(Object),M=RegExp("^"+L.call(N).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),D=m?d.Buffer:void 0,x=d.Symbol,B=d.Uint8Array,U=D?D.allocUnsafe:void 0,H=(S=Object.getPrototypeOf,A=Object,function(e){return S(A(e))}),j=Object.create,z=R.propertyIsEnumerable,Y=T.splice,G=x?x.toStringTag:void 0,F=function(){try{var e=ve(Object,"defineProperty");return e({},"",{}),e}catch(e){}}(),K=D?D.isBuffer:void 0,V=Math.max,W=Date.now,q=ve(d,"Map"),J=ve(Object,"create"),X=function(){function e(){}return function(t){if(!ke(t))return{};if(j)return j(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Z(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Q(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function $(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ee(e){var t=this.__data__=new Q(e);this.size=t.size}function te(e,t){var n=Se(e),r=!n&&we(e),i=!n&&!r&&Te(e),o=!n&&!r&&!i&&Ne(e),a=n||r||i||o,s=a?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],u=s.length;for(var c in e)!t&&!N.call(e,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||me(c,u))||s.push(c);return s}function ne(e,t,n){(void 0!==n&&!Ee(e[t],n)||void 0===n&&!(t in e))&&oe(e,t,n)}function re(e,t,n){var r=e[t];N.call(e,t)&&Ee(r,n)&&(void 0!==n||t in e)||oe(e,t,n)}function ie(e,t){for(var n=e.length;n--;)if(Ee(e[n][0],t))return n;return-1}function oe(e,t,n){"__proto__"==t&&F?F(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}Z.prototype.clear=function(){this.__data__=J?J(null):{},this.size=0},Z.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Z.prototype.get=function(e){var t=this.__data__;if(J){var n=t[e];return n===i?void 0:n}return N.call(t,e)?t[e]:void 0},Z.prototype.has=function(e){var t=this.__data__;return J?void 0!==t[e]:N.call(t,e)},Z.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=J&&void 0===t?i:t,this},Q.prototype.clear=function(){this.__data__=[],this.size=0},Q.prototype.delete=function(e){var t=this.__data__,n=ie(t,e);return!(n<0)&&(n==t.length-1?t.pop():Y.call(t,n,1),--this.size,!0)},Q.prototype.get=function(e){var t=this.__data__,n=ie(t,e);return n<0?void 0:t[n][1]},Q.prototype.has=function(e){return ie(this.__data__,e)>-1},Q.prototype.set=function(e,t){var n=this.__data__,r=ie(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},$.prototype.clear=function(){this.size=0,this.__data__={hash:new Z,map:new(q||Q),string:new Z}},$.prototype.delete=function(e){var t=ge(this,e).delete(e);return this.size-=t?1:0,t},$.prototype.get=function(e){return ge(this,e).get(e)},$.prototype.has=function(e){return ge(this,e).has(e)},$.prototype.set=function(e,t){var n=ge(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},ee.prototype.clear=function(){this.__data__=new Q,this.size=0},ee.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},ee.prototype.get=function(e){return this.__data__.get(e)},ee.prototype.has=function(e){return this.__data__.has(e)},ee.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Q){var r=n.__data__;if(!q||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new $(r)}return n.set(e,t),this.size=n.size,this};var ae,se=function(e,t,n){for(var r=-1,i=Object(e),o=n(e),a=o.length;a--;){var s=o[ae?a:++r];if(!1===t(i[s],s,i))break}return e};function ue(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":G&&G in Object(e)?function(e){var t=N.call(e,G),n=e[G];try{e[G]=void 0;var r=!0}catch(e){}var i=I.call(e);r&&(t?e[G]=n:delete e[G]);return i}(e):function(e){return I.call(e)}(e)}function ce(e){return Le(e)&&ue(e)==a}function le(e){return!(!ke(e)||function(e){return!!O&&O in e}(e))&&(Pe(e)?M:c).test(function(e){if(null!=e){try{return L.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}function he(e){if(!ke(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=ye(e),n=[];for(var r in e)("constructor"!=r||!t&&N.call(e,r))&&n.push(r);return n}function fe(e,t,n,r,i){e!==t&&se(t,(function(o,a){if(i||(i=new ee),ke(o))!function(e,t,n,r,i,o,a){var s=_e(e,n),c=_e(t,n),l=a.get(c);if(l)return void ne(e,n,l);var h=o?o(s,c,n+"",e,t,a):void 0,f=void 0===h;if(f){var p=Se(c),d=!p&&Te(c),g=!p&&!d&&Ne(c);h=c,p||d||g?Se(s)?h=s:Le(b=s)&&Ae(b)?h=function(e,t){var n=-1,r=e.length;t||(t=Array(r));for(;++n<r;)t[n]=e[n];return t}(s):d?(f=!1,h=function(e,t){if(t)return e.slice();var n=e.length,r=U?U(n):new e.constructor(n);return e.copy(r),r}(c,!0)):g?(f=!1,v=c,m=!0?(y=v.buffer,_=new y.constructor(y.byteLength),new B(_).set(new B(y)),_):v.buffer,h=new v.constructor(m,v.byteOffset,v.length)):h=[]:function(e){if(!Le(e)||ue(e)!=u)return!1;var t=H(e);if(null===t)return!0;var n=N.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&L.call(n)==C}(c)||we(c)?(h=s,we(s)?h=function(e){return function(e,t,n,r){var i=!n;n||(n={});var o=-1,a=t.length;for(;++o<a;){var s=t[o],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),i?oe(n,s,u):re(n,s,u)}return n}(e,Oe(e))}(s):ke(s)&&!Pe(s)||(h=function(e){return"function"!=typeof e.constructor||ye(e)?{}:X(H(e))}(c))):f=!1}var v,m,y,_;var b;f&&(a.set(c,h),i(h,c,r,o,a),a.delete(c));ne(e,n,h)}(e,t,a,n,fe,r,i);else{var s=r?r(_e(e,a),o,a+"",e,t,i):void 0;void 0===s&&(s=o),ne(e,a,s)}}),Oe)}function pe(e,t){return be(function(e,t,n){return t=V(void 0===t?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=V(r.length-t,0),a=Array(o);++i<o;)a[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(a),E(e,this,s)}}(e,t,Me),e+"")}var de=F?function(e,t){return F(e,"toString",{configurable:!0,enumerable:!1,value:(n=t,function(){return n}),writable:!0});var n}:Me;function ge(e,t){var n,i,o=e.__data__;return("string"==(i=r(n=t))||"number"==i||"symbol"==i||"boolean"==i?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function ve(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return le(n)?n:void 0}function me(e,t){var n=r(e);return!!(t=null==t?o:t)&&("number"==n||"symbol"!=n&&l.test(e))&&e>-1&&e%1==0&&e<t}function ye(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||R)}function _e(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var be=function(e){var t=0,n=0;return function(){var r=W(),i=16-(r-n);if(n=r,i>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(de);function Ee(e,t){return e===t||e!=e&&t!=t}var we=ce(function(){return arguments}())?ce:function(e){return Le(e)&&N.call(e,"callee")&&!z.call(e,"callee")},Se=Array.isArray;function Ae(e){return null!=e&&Re(e.length)&&!Pe(e)}var Te=K||function(){return!1};function Pe(e){if(!ke(e))return!1;var t=ue(e);return t==s||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Re(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=o}function ke(e){var t=r(e);return null!=e&&("object"==t||"function"==t)}function Le(e){return null!=e&&"object"==r(e)}var Ne=b?function(e){return function(t){return e(t)}}(b):function(e){return Le(e)&&Re(e.length)&&!!h[ue(e)]};function Oe(e){return Ae(e)?te(e,!0):he(e)}var Ie,Ce=(Ie=function(e,t,n){fe(e,t,n)},pe((function(e,t){var n=-1,i=t.length,o=i>1?t[i-1]:void 0,a=i>2?t[2]:void 0;for(o=Ie.length>3&&"function"==typeof o?(i--,o):void 0,a&&function(e,t,n){if(!ke(n))return!1;var i=r(t);return!!("number"==i?Ae(n)&&me(t,n.length):"string"==i&&t in n)&&Ee(n[t],e)}(t[0],t[1],a)&&(o=i<3?void 0:o,i=1),e=Object(e);++n<i;){var s=t[n];s&&Ie(e,s,n,o)}return e})));function Me(e){return e}e.exports=Ce},3089:function(e){var t,n,r=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:i}catch(e){t=i}try{n="function"==typeof clearTimeout?clearTimeout:o}catch(e){n=o}}();var s,u=[],c=!1,l=-1;function h(){c&&s&&(c=!1,s.length?u=s.concat(u):l=-1,u.length&&f())}function f(){if(!c){var e=a(h);c=!0;for(var t=u.length;t;){for(s=u,u=[];++l<t;)s&&s[l].run();l=-1,t=u.length}s=null,c=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===o||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function d(){}r.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new p(e,t)),1!==u.length||c||a(f)},p.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=d,r.addListener=d,r.once=d,r.off=d,r.removeListener=d,r.removeAllListeners=d,r.emit=d,r.prependListener=d,r.prependOnceListener=d,r.listeners=function(e){return[]},r.binding=function(e){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(e){throw new Error("process.chdir is not supported")},r.umask=function(){return 0}},8319:function(e,t,n){var r=n(7652);function i(e){var t,n;function i(t,n){try{var a=e[t](n),s=a.value,u=s instanceof r;Promise.resolve(u?s.v:s).then((function(n){if(u){var r="return"===t?"return":"next";if(!s.k||n.done)return i(r,n);n=e[r](n).value}o(a.done?"return":"normal",n)}),(function(e){i("throw",e)}))}catch(e){o("throw",e)}}function o(e,r){switch(e){case"return":t.resolve({value:r,done:!0});break;case"throw":t.reject(r);break;default:t.resolve({value:r,done:!1})}(t=t.next)?i(t.key,t.arg):n=null}this._invoke=function(e,r){return new Promise((function(o,a){var s={key:e,arg:r,resolve:o,reject:a,next:null};n?n=n.next=s:(t=n=s,i(e,r))}))},"function"!=typeof e.return&&(this.return=void 0)}i.prototype["function"==typeof Symbol&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},i.prototype.next=function(e){return this._invoke("next",e)},i.prototype.throw=function(e){return this._invoke("throw",e)},i.prototype.return=function(e){return this._invoke("return",e)},e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},7652:function(e){e.exports=function(e,t){this.v=e,this.k=t},e.exports.__esModule=!0,e.exports.default=e.exports},3317:function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r},e.exports.__esModule=!0,e.exports.default=e.exports},4180:function(e){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},4786:function(e,t,n){var r=n(3317);e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.__esModule=!0,e.exports.default=e.exports},7374:function(e){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},4331:function(e,t,n){var r=n(7652);e.exports=function(e){var t={},n=!1;function i(t,i){return n=!0,i=new Promise((function(n){n(e[t](i))})),{done:!1,value:new r(i,1)}}return t["undefined"!=typeof Symbol&&Symbol.iterator||"@@iterator"]=function(){return this},t.next=function(e){return n?(n=!1,e):i("next",e)},"function"==typeof e.throw&&(t.throw=function(e){if(n)throw n=!1,e;return i("throw",e)}),"function"==typeof e.return&&(t.return=function(e){return n?(n=!1,e):i("return",e)}),t},e.exports.__esModule=!0,e.exports.default=e.exports},8193:function(e){function t(e){function n(e){if(Object(e)!==e)return Promise.reject(new TypeError(e+" is not an object."));var t=e.done;return Promise.resolve(e.value).then((function(e){return{value:e,done:t}}))}return t=function(e){this.s=e,this.n=e.next},t.prototype={s:null,n:null,next:function(){return n(this.n.apply(this.s,arguments))},return:function(e){var t=this.s.return;return void 0===t?Promise.resolve({value:e,done:!0}):n(t.apply(this.s,arguments))},throw:function(e){var t=this.s.return;return void 0===t?Promise.reject(e):n(t.apply(this.s,arguments))}},new t(e)}e.exports=function(e){var n,r,i,o=2;for("undefined"!=typeof Symbol&&(r=Symbol.asyncIterator,i=Symbol.iterator);o--;){if(r&&null!=(n=e[r]))return n.call(e);if(i&&null!=(n=e[i]))return new t(n.call(e));r="@@asyncIterator",i="@@iterator"}throw new TypeError("Object is not async iterable")},e.exports.__esModule=!0,e.exports.default=e.exports},1404:function(e){function t(e,t,n,r,i,o,a){try{var s=e[o](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,i)}e.exports=function(e){return function(){var n=this,r=arguments;return new Promise((function(i,o){var a=e.apply(n,r);function s(e){t(a,i,o,s,u,"next",e)}function u(e){t(a,i,o,s,u,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports.default=e.exports},8946:function(e,t,n){var r=n(7652);e.exports=function(e){return new r(e,0)},e.exports.__esModule=!0,e.exports.default=e.exports},5486:function(e){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},1486:function(e,t,n){var r=n(9687),i=n(2424);function o(t,n,a){return i()?(e.exports=o=Reflect.construct.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},e.exports.__esModule=!0,e.exports.default=e.exports),o.apply(null,arguments)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},702:function(e,t,n){var r=n(5281);function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}e.exports=function(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},9746:function(e,t,n){var r=n(5508);e.exports=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=r(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}},e.exports.__esModule=!0,e.exports.default=e.exports},3400:function(e,t,n){var r=n(2242),i=n(2424),o=n(1983);e.exports=function(e){var t=i();return function(){var n,i=r(e);if(t){var a=r(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return o(this,n)}},e.exports.__esModule=!0,e.exports.default=e.exports},4143:function(e,t,n){var r=n(5281);e.exports=function(e,t,n){return(t=r(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},5225:function(e,t,n){var r=n(3155);function i(){return"undefined"!=typeof Reflect&&Reflect.get?(e.exports=i=Reflect.get.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=i=function(e,t,n){var i=r(e,t);if(i){var o=Object.getOwnPropertyDescriptor(i,t);return o.get?o.get.call(arguments.length<3?e:n):o.value}},e.exports.__esModule=!0,e.exports.default=e.exports),i.apply(this,arguments)}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},2242:function(e){function t(n){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},5821:function(e,t,n){var r=n(9687);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},2185:function(e){e.exports=function(e){try{return-1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"==typeof e}},e.exports.__esModule=!0,e.exports.default=e.exports},2424:function(e){e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.__esModule=!0,e.exports.default=e.exports},4682:function(e){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports},7249:function(e){e.exports=function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){c=!0,i=e}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}},e.exports.__esModule=!0,e.exports.default=e.exports},20:function(e){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},114:function(e){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},5118:function(e,t,n){var r=n(4143);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}e.exports=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e},e.exports.__esModule=!0,e.exports.default=e.exports},4005:function(e,t,n){var r=n(5166);e.exports=function(e,t){if(null==e)return{};var n,i,o=r(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o},e.exports.__esModule=!0,e.exports.default=e.exports},5166:function(e){e.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i},e.exports.__esModule=!0,e.exports.default=e.exports},1983:function(e,t,n){var r=n(4944).default,i=n(7374);e.exports=function(e,t){if(t&&("object"===r(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},7662:function(e,t,n){var r=n(4944).default;function i(){"use strict";e.exports=i=function(){return n},e.exports.__esModule=!0,e.exports.default=e.exports;var t,n={},o=Object.prototype,a=o.hasOwnProperty,s=Object.defineProperty||function(e,t,n){e[t]=n.value},u="function"==typeof Symbol?Symbol:{},c=u.iterator||"@@iterator",l=u.asyncIterator||"@@asyncIterator",h=u.toStringTag||"@@toStringTag";function f(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(t){f=function(e,t,n){return e[t]=n}}function p(e,t,n,r){var i=t&&t.prototype instanceof _?t:_,o=Object.create(i.prototype),a=new I(r||[]);return s(o,"_invoke",{value:k(e,n,a)}),o}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}n.wrap=p;var g="suspendedStart",v="executing",m="completed",y={};function _(){}function b(){}function E(){}var w={};f(w,c,(function(){return this}));var S=Object.getPrototypeOf,A=S&&S(S(C([])));A&&A!==o&&a.call(A,c)&&(w=A);var T=E.prototype=_.prototype=Object.create(w);function P(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function R(e,t){function n(i,o,s,u){var c=d(e[i],e,o);if("throw"!==c.type){var l=c.arg,h=l.value;return h&&"object"==r(h)&&a.call(h,"__await")?t.resolve(h.__await).then((function(e){n("next",e,s,u)}),(function(e){n("throw",e,s,u)})):t.resolve(h).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,u)}))}u(c.arg)}var i;s(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,i){n(e,r,t,i)}))}return i=i?i.then(o,o):o()}})}function k(e,n,r){var i=g;return function(o,a){if(i===v)throw new Error("Generator is already running");if(i===m){if("throw"===o)throw a;return{value:t,done:!0}}for(r.method=o,r.arg=a;;){var s=r.delegate;if(s){var u=L(s,r);if(u){if(u===y)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===g)throw i=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=v;var c=d(e,n,r);if("normal"===c.type){if(i=r.done?m:"suspendedYield",c.arg===y)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=m,r.method="throw",r.arg=c.arg)}}}function L(e,n){var r=n.method,i=e.iterator[r];if(i===t)return n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=t,L(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),y;var o=d(i,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,y;var a=o.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,y):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,y)}function N(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(N,this),this.reset(!0)}function C(e){if(e||""===e){var n=e[c];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var i=-1,o=function n(){for(;++i<e.length;)if(a.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return o.next=o}}throw new TypeError(r(e)+" is not iterable")}return b.prototype=E,s(T,"constructor",{value:E,configurable:!0}),s(E,"constructor",{value:b,configurable:!0}),b.displayName=f(E,h,"GeneratorFunction"),n.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},n.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,E):(e.__proto__=E,f(e,h,"GeneratorFunction")),e.prototype=Object.create(T),e},n.awrap=function(e){return{__await:e}},P(R.prototype),f(R.prototype,l,(function(){return this})),n.AsyncIterator=R,n.async=function(e,t,r,i,o){void 0===o&&(o=Promise);var a=new R(p(e,t,r,i),o);return n.isGeneratorFunction(t)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},P(T),f(T,h,"Generator"),f(T,c,(function(){return this})),f(T,"toString",(function(){return"[object Generator]"})),n.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},n.values=C,I.prototype={constructor:I,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(O),!e)for(var n in this)"t"===n.charAt(0)&&a.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function r(r,i){return s.type="throw",s.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var u=a.call(o,"catchLoc"),c=a.call(o,"finallyLoc");if(u&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var i=r;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var o=i?i.completion:{};return o.type=e,o.arg=t,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),y},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),y}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;O(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:C(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),y}},n}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},9687:function(e){function t(n,r){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(n,r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},7925:function(e,t,n){var r=n(4180),i=n(7249),o=n(5508),a=n(20);e.exports=function(e,t){return r(e)||i(e,t)||o(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},3155:function(e,t,n){var r=n(2242);e.exports=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=r(e)););return e},e.exports.__esModule=!0,e.exports.default=e.exports},4044:function(e,t,n){var r=n(4786),i=n(4682),o=n(5508),a=n(114);e.exports=function(e){return r(e)||i(e)||o(e)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},224:function(e,t,n){var r=n(4944).default;e.exports=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},5281:function(e,t,n){var r=n(4944).default,i=n(224);e.exports=function(e){var t=i(e,"string");return"symbol"==r(t)?t:String(t)},e.exports.__esModule=!0,e.exports.default=e.exports},4944:function(e){function t(n){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},5508:function(e,t,n){var r=n(3317);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},3697:function(e,t,n){var r=n(8319);e.exports=function(e){return function(){return new r(e.apply(this,arguments))}},e.exports.__esModule=!0,e.exports.default=e.exports},907:function(e,t,n){var r=n(2242),i=n(9687),o=n(2185),a=n(1486);function s(t){var n="function"==typeof Map?new Map:void 0;return e.exports=s=function(e){if(null===e||!o(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==n){if(n.has(e))return n.get(e);n.set(e,t)}function t(){return a(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},e.exports.__esModule=!0,e.exports.default=e.exports,s(t)}e.exports=s,e.exports.__esModule=!0,e.exports.default=e.exports}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={id:r,loaded:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e};var r={};return function(){"use strict";n.r(r),n.d(r,{ApplePayHostService:function(){return Hs},MessageType:function(){return ne},OpenSDKError:function(){return O},SDKBridge:function(){return se},adjustSessionData:function(){return ts},awaitWrap:function(){return Os},buildPageUrl:function(){return t},checkSessionData:function(){return As},debug:function(){return gs},debugError:function(){return vs},getDevReqConfig:function(){return i},getLocaleFromRenderData:function(){return s},getMetaData:function(){return Qa},isElements2:function(){return ns},oneAccountQuery:function(){return Cs},openModal:function(){return Ns},parseHostSign:function(){return Vr},parseTrackerId:function(){return Kr},request:function(){return Ja},sdkQuery:function(){return Ds},sdkTracker:function(){return fe},themeColorMap:function(){return Ss}});var e={};function t(e,t){return function(e){return"https://checkout.antom.com/".concat(e?"elements2":"elements","/pages")}(t)+(e.startsWith("/")?e:"/".concat(e))}n.r(e),n.d(e,{hasBrowserEnv:function(){return Ao},hasStandardBrowserEnv:function(){return Po},hasStandardBrowserWebWorkerEnv:function(){return Ro},navigator:function(){return To},origin:function(){return ko}});function i(){}var o=n(9746),a=n.n(o);function s(e){var t,n=(null==e?void 0:e.supportedLanguages)||[],r=a()(n);try{for(r.s();!(t=r.n()).done;){var i=t.value;if(i.preferred&&i.locale)return i.locale}}catch(e){r.e(e)}finally{r.f()}}var u=n(5486),c=n.n(u),l=n(702),h=n.n(l),f=n(7374),p=n.n(f),d=n(5821),g=n.n(d),v=n(3400),m=n.n(v),y=n(4143),_=n.n(y),b=n(5118),E=n.n(b),w=n(7662),S=n.n(w),A=n(1404),T=n.n(A),P=n(7925),R=n(4944),k=n.n(R),L=n(907),N={i18nPrefix:"OPENSDK"},O=function(e){d(n,e);var t=v(n);function n(e,r,i,o){var a,s,c,l=!(arguments.length>4&&void 0!==arguments[4])||arguments[4];u(this,n);var h,p=o,d=void 0;return e&&"object"===R(e)?(h=e.message,d=e.params):h=e,c=t.call(this,!N.i18n||l&&"SERVER_API"===i?h:N.i18n.get({id:"".concat(N.i18nPrefix,".").concat(r),dm:(null===(a=(s=N).getDefaultMessage)||void 0===a?void 0:a.call(s))||h},d)),y(f(c),"code",void 0),y(f(c),"name","OpenSDKError"),y(f(c),"_openSDKErrorFlag","__OpenSDKErrorFlag__"),y(f(c),"source","SDK_INTERNAL"),y(f(c),"traceId",void 0),y(f(c),"reason",void 0),c.reason=h,c.code=r,c.source=i,c.traceId=p,c}return l(n,[{key:"toJSON",value:function(){var e={message:this.message,code:this.code,source:this.source,traceId:this.traceId,reason:this.reason,stack:this.stack};return JSON.parse(JSON.stringify(e))}}],[{key:"isError",value:function(e){return e instanceof n||e instanceof Error&&"__OpenSDKErrorFlag__"===e._openSDKErrorFlag}},{key:"unificationError",value:function(e){var t,r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"APP_RUNTIME";if(n.isError(e))return e;var o=new I(e instanceof Error?e.message:(null===(t=(r=N).getDefaultMessage)||void 0===t?void 0:t.call(r))||"An unknown error occurred.","UNKNOWN_ERROR",i);return o}},{key:"initConfig",value:function(e){N=b(b({},N),e)}}]),n}(L(Error)),I=function(e){d(n,e);var t=v(n);function n(){var e;u(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),y(f(e),"name","SDKBridgeError"),e}return l(n)}(O),C=n(4044),M=function(e){return C(new Set(e))},D=function(e,t){return e.filter((function(e){return!t.includes(e)}))},x=function(e,t){return e.filter((function(e){return t.includes(e)}))},B=function(e){return"bigint"==typeof e||!Number.isNaN(Number(e))&&Math.floor(Number(e))===e},U=function(e){return"bigint"==typeof e||e>=0&&Number.isSafeInteger(e)};function H(e,t){if(0===t.length)return e;for(var n,r=C(e),i=r.length-1,o=0,a=0;i>0;i--,o++){a+=n=t[o%=t.length].codePointAt(0);var s=(n+o+a)%i,u=r[i],c=r[s];r[s]=u,r[i]=c}return r}var j=function(e,t){return e.reduce((function(n,r){var i=t.indexOf(r);if(-1===i)throw new Error("The provided ID (".concat(e.join(""),") is invalid, as it contains characters that do not exist in the alphabet (").concat(t.join(""),")"));if("bigint"==typeof n)return n*BigInt(t.length)+BigInt(i);var o=n*t.length+i;return Number.isSafeInteger(o)?o:(V("Unable to decode the provided string, due to lack of support for BigInt numbers in the current environment"),BigInt(n)*BigInt(t.length)+BigInt(i))}),0)},z=/^\+?\d+$/,Y=function(e){if(!z.test(e))return Number.NaN;var t=Number.parseInt(e,10);return Number.isSafeInteger(t)?t:(V("Unable to encode the provided BigInt string without loss of information due to lack of support for BigInt type in the current environment"),BigInt(e))},G=function(e){return new RegExp(e.map((function(e){return K(e)})).sort((function(e,t){return t.length-e.length})).join("|"))},F=function(e){return new RegExp("^[".concat(e.map((function(e){return K(e)})).sort((function(e,t){return t.length-e.length})).join(""),"]+$"))},K=function(e){return e.replace(/[\s#$()*+,.?[\\\]^{|}-]/g,"\\$&")},V=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"BigInt is not available in this environment";if("function"!=typeof BigInt)throw new TypeError(e)},W=3.5,q=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"cfhistuCFHISTU";if(u(this,e),this.minLength=n,"number"!=typeof n)throw new TypeError("Hashids: Provided 'minLength' has to be a number (is ".concat(R(n),")"));if("string"!=typeof t)throw new TypeError("Hashids: Provided 'salt' has to be a string (is ".concat(R(t),")"));if("string"!=typeof r)throw new TypeError("Hashids: Provided alphabet has to be a string (is ".concat(R(r),")"));var o=Array.from(t),a=Array.from(r),s=Array.from(i);this.salt=o;var c=M(a);if(c.length<16)throw new Error("Hashids: alphabet must contain at least ".concat(16," unique characters, provided: ").concat(c.join("")));this.alphabet=D(c,s);var l,h,f,p=x(s,c);(this.seps=H(p,o),0===this.seps.length||this.alphabet.length/this.seps.length>W)&&((l=Math.ceil(this.alphabet.length/W))>this.seps.length&&(h=l-this.seps.length,(f=this.seps).push.apply(f,C(this.alphabet.slice(0,h))),this.alphabet=this.alphabet.slice(h)));this.alphabet=H(this.alphabet,o);var d=Math.ceil(this.alphabet.length/12);this.alphabet.length<3?(this.guards=this.seps.slice(0,d),this.seps=this.seps.slice(d)):(this.guards=this.alphabet.slice(0,d),this.alphabet=this.alphabet.slice(d)),this.guardsRegExp=G(this.guards),this.sepsRegExp=G(this.seps),this.allowedCharsRegExp=F([].concat(C(this.alphabet),C(this.guards),C(this.seps)))}return l(e,[{key:"encode",value:function(e){for(var t="",n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];var o=Array.isArray(e)?e:[].concat(C(null!=e?[e]:[]),r);return 0===o.length?t:(o.every(B)||(o=o.map((function(e){return"bigint"==typeof e||"number"==typeof e?e:Y(String(e))}))),o.every(U)?this._encode(o).join(""):t)}},{key:"decode",value:function(e){return e&&"string"==typeof e&&0!==e.length?this._decode(e):[]}},{key:"encodeHex",value:function(e){var t=e;switch(R(t)){case"bigint":t=t.toString(16);break;case"string":if(!/^[\dA-Fa-f]+$/.test(t))return"";break;default:throw new Error("Hashids: The provided value is neither a string, nor a BigInt (got: ".concat(R(t),")"))}var n,r,i,o=(n=t,r=12,i=function(e){return Number.parseInt("1".concat(e),16)},Array.from({length:Math.ceil(n.length/r)},(function(e,t){return i(n.slice(t*r,(t+1)*r))})));return this.encode(o)}},{key:"decodeHex",value:function(e){return this.decode(e).map((function(e){return e.toString(16).slice(1)})).join("")}},{key:"isValidId",value:function(e){return this.allowedCharsRegExp.test(e)}},{key:"_encode",value:function(e){var t=this,n=this.alphabet,r=e.reduce((function(e,t,n){return e+("bigint"==typeof t?Number(t%BigInt(n+100)):t%(n+100))}),0),i=[n[r%n.length]],o=C(i),a=this.seps,s=this.guards;if(e.forEach((function(r,s){var u,c=o.concat(t.salt,n),l=function(e,t){var n=[],r=e;if("bigint"==typeof r){var i=BigInt(t.length);do{n.unshift(t[Number(r%i)]),r/=i}while(r>BigInt(0))}else do{n.unshift(t[r%t.length]),r=Math.floor(r/t.length)}while(r>0);return n}(r,n=H(n,c));if((u=i).push.apply(u,C(l)),s+1<e.length){var h=l[0].codePointAt(0)+s,f="bigint"==typeof r?Number(r%BigInt(h)):r%h;i.push(a[f%a.length])}})),i.length<this.minLength){var u=(r+i[0].codePointAt(0))%s.length;if(i.unshift(s[u]),i.length<this.minLength){var c=(r+i[2].codePointAt(0))%s.length;i.push(s[c])}}for(var l=Math.floor(n.length/2);i.length<this.minLength;){var h,f;n=H(n,n),(h=i).unshift.apply(h,C(n.slice(l))),(f=i).push.apply(f,C(n.slice(0,l)));var p=i.length-this.minLength;if(p>0){var d=p/2;i=i.slice(d,d+this.minLength)}}return i}},{key:"_decode",value:function(e){if(!this.isValidId(e))throw new Error("The provided ID (".concat(e,") is invalid, as it contains characters that do not exist in the alphabet (").concat(this.guards.join("")).concat(this.seps.join("")).concat(this.alphabet.join(""),")"));var t=e.split(this.guardsRegExp),n=t[3===t.length||2===t.length?1:0];if(0===n.length)return[];var r,i=n[Symbol.iterator]().next().value,a=n.slice(i.length).split(this.sepsRegExp),s=this.alphabet,u=[],c=o(a);try{for(c.s();!(r=c.n()).done;){var l=r.value,h=H(s,[i].concat(C(this.salt),C(s)).slice(0,s.length));u.push(j(Array.from(l),h)),s=h}}catch(e){c.e(e)}finally{c.f()}return this._encode(u).join("")!==e?[]:u}}]),e}(),J=new q("intl-open-sdk",6);function X(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(){var r,i=new Promise((function(e,i){r=setTimeout((function(){n?i(n):e(void 0)}),t)}));return Promise.race([i,e.apply(void 0,arguments)]).finally((function(){return clearTimeout(r)}))}}var Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e+J.encode("".concat(Date.now()).concat(Math.ceil(100*Math.random())))};function Q(e){if("onpagehide"in self){var t=function(t){t.persisted||e("pagehide")};return self.addEventListener("pagehide",t),function(){return self.removeEventListener("pagehide",t)}}if("undefined"!=typeof document&&void 0!==document.visibilityState){var n=!1,r=function(){"hidden"!==document.visibilityState||n||(n=!0,e("visibilitychange"))};return document.addEventListener("visibilitychange",r),function(){return document.removeEventListener("visibilitychange",r)}}var i=self,o=function(){e("beforeunload")};return i.addEventListener("beforeunload",o),function(){return i.removeEventListener("beforeunload",o)}}var $=function(){function e(t,n){var r=this;u(this,e),y(this,"targetPort",void 0),y(this,"handlers",new Map),y(this,"debugCallback",void 0),y(this,"name",void 0),y(this,"initialized",!1),y(this,"recipientIsReady",!1),y(this,"handleMessage",(function(e){var t=e.data,n=t.type,i=t.payload,o=r.handlers.get(n);o&&(r.debugCallback&&r.debugCallback(b(b({},e.data),{},{type:"MODAL_PORT@"+e.data.type}),"IN"),o.forEach((function(e){e(i)})))})),this.targetPort=n,n.onmessage=this.handleMessage,this.name=t,this.once("ready",(function(){r.recipientIsReady=!0}))}return l(e,[{key:"setDebugCallback",value:function(e){this.debugCallback=e}},{key:"onData",value:function(e){return this.initialized||(this.send("ready"),this.initialized=!0),this.on("data",e)}},{key:"sendData",value:function(e){var t=this;this.recipientIsReady?this.send("data",e):this.once("ready",(function(){t.recipientIsReady=!0,t.send("data",e)}))}},{key:"onClose",value:function(e){var t=this;return new Promise((function(n,r){t.on("close",function(){var i=A(w().mark((function i(o){return w().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if(o.name!==t.name){i.next=10;break}return i.prev=1,i.next=4,e(o.manual);case 4:n(),i.next=10;break;case 7:i.prev=7,i.t0=i.catch(1),r(i.t0);case 10:case"end":return i.stop()}}),i,null,[[1,7]])})));return function(e){return i.apply(this,arguments)}}())}))}},{key:"close",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.send("close",{name:this.name,manual:e}),new Promise((function(){}))}},{key:"on",value:function(e,t){var n=this;return this.handlers.has(e)||this.handlers.set(e,new Set),this.handlers.get(e).add(t),function(){n.handlers.get(e).delete(t)}}},{key:"once",value:function(e,t){var n=this,r=function r(i){try{t(i)}finally{n.off(e,r)}};return this.on(e,r),function(){n.off(e,r)}}},{key:"off",value:function(e,t){var n=this.handlers.get(e);n&&n.delete(t)}},{key:"send",value:function(e,t){var n={id:Z("modal_port_"),type:e,payload:t};this.debugCallback&&this.debugCallback(b(b({},n),{},{type:"MODAL_PORT@"+n.type}),"OUT"),this.targetPort.postMessage(n)}}]),e}(),ee=function(){function e(t){u(this,e),y(this,"targetPorts",[]),y(this,"name",void 0),this.name=t}var t;return l(e,[{key:"addPort",value:function(e){var t;(t=this.targetPorts).push.apply(t,C(e))}},{key:"removePort",value:function(e){this.targetPorts=this.targetPorts.filter((function(t){return e!==t}))}},{key:"getValues",value:(t=A(w().mark((function e(t){var n,r,i=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=(null==t?void 0:t.timeout)||1e4,r=X((function(){return Promise.all(i.targetPorts.map((function(e){return new Promise((function(t,n){e.postMessage({id:Math.random()+"",type:"".concat(i.name,":START_COLLECT_VALUE")}),e.onmessage=function(e){var r=e.data;if(r&&r.type){var i=r.type.split(":"),o=P(i,2),a=o[0];"SEND_ELEMENT_VALUE"===o[1]&&t(y({},a,r.payload))}else n(new Error("collect error"))}}))}))).then((function(e){return e.reduce((function(e,t){return b(b({},e),t)}),{})}))}),n),e.abrupt("return",r());case 3:case"end":return e.stop()}}),e)}))),function(e){return t.apply(this,arguments)})}]),e}(),te=function(){function e(t,n){u(this,e),y(this,"targetPort",void 0),y(this,"name",void 0),this.targetPort=n,this.name=t}return l(e,[{key:"onSendRequest",value:function(e){this.targetPort.onmessage=function(){var t=A(w().mark((function t(n){var r,i,o;return w().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((r=n.data)&&r.type){t.next=3;break}return t.abrupt("return");case 3:i=r.type.split(":"),o=P(i,2),o[0],"START_COLLECT_VALUE"===o[1]&&e();case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()}},{key:"send",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={id:Math.random()+"",payload:e,type:"".concat(this.name,":SEND_ELEMENT_VALUE")};this.targetPort.postMessage(t)}}]),e}(),ne={HANDSHAKE:"OPENSDK@HANDSHAKE",READY_HANDSHAKE:"OPENSDK@READY_HANDSHAKE",UPDATE_CONFIG:"OPENSDK@UPDATE_CONFIG",UPDATE_CONFIG_REPLY:"OPENSDK@UPDATE_CONFIG_REPLY",SUBMIT:"OPENSDK@SUBMIT",SUBMIT_REPLY:"OPENSDK@SUBMIT_REPLY",REDIRECT:"OPENSDK@REDIRECT",OPEN_MODAL:"OPENSDK@OPEN_MODAL",OPEN_MODAL_ERROR:"OPENSDK@OPEN_MODAL_ERROR",CLOSE_MODAL:"OPENSDK@CLOSE_MODAL",ERROR:"OPENSDK@ERROR",HANDSHAKE_ACK:"OPENSDK@HANDSHAKE_ACK",TRANSFER_RECEIVE_PORT:"OPENSDK@TRANSFER_RECEIVE_PORT",MESSAGE:"OPENSDK@MESSAGE",TRANSFER_SEND_PORT:"OPENSDK@TRANSFER_SEND_PORT",TRANSFER_APP_PORT:"OPENSDK@TRANSFER_APP_PORT",TRANSFER_MODAL_PORT:"OPENSDK@TRANSFER_MODAL_PORT",TRANSFER_MODAL_APPEARANCE:"OPENSDK@TRANSFER_MODAL_APPEARANCE",TRANSFER_MODAL_INITIALDATA:"OPENSDK@TRANSFER_MODAL_INITIALDATA",HEIGHT_UPDATE:"OPENSDK@HEIGHT_UPDATE",DESTROY_ELEMENT:"OPENSDK@DESTROY_ELEMENT"},re=n(8098),ie=[ne.TRANSFER_RECEIVE_PORT,ne.TRANSFER_SEND_PORT,ne.TRANSFER_MODAL_PORT,ne.TRANSFER_MODAL_APPEARANCE,ne.TRANSFER_MODAL_INITIALDATA,ne.OPEN_MODAL_ERROR,ne.TRANSFER_APP_PORT,ne.CLOSE_MODAL,ne.OPEN_MODAL,ne.REDIRECT,ne.MESSAGE,ne.DESTROY_ELEMENT],oe="@@global",ae="@@native",se=function(){function e(t,n,r){var i,o,a=this;(u(this,e),y(this,"targetWindow",void 0),y(this,"currentWindow",void 0),y(this,"targetOrigin","*"),y(this,"scope",void 0),y(this,"handlers",new Map),y(this,"mode",void 0),y(this,"resizeObserver",void 0),y(this,"debugCallback",void 0),y(this,"receivePort",void 0),y(this,"openModalOff",void 0),y(this,"openModalPromise",void 0),y(this,"handleMessage",(function(e){var t=e.data;if(t&&t.type){var n=t.type.split(":"),r=P(n,2),i=r[0],o=r[1];if(a.scope!==ae){if(!["WEBAPP","HOST"].includes(o))return;if("*"!==a.targetOrigin&&e.origin!==a.targetOrigin)return;if(a.mode===o)return}var s=a.handlers.get(t.type);a.scope!==ae&&(s||t.type.endsWith(ne.ERROR)||t.type.endsWith(ne.MESSAGE))&&a.debugCallback&&a.scope===i&&a.debugCallback(t,"IN"),s&&new Set(s).forEach((function(n){n.length>=3?n(t.payload,e.ports,{origin:e.origin,source:e.source}):n(t.payload,e.ports)}))}})),this.mode=t,this.scope=n,this.currentWindow=r||window,"WEBAPP"===this.mode)&&(this.targetWindow=null===(o=this.currentWindow)||void 0===o?void 0:o.parent);null===(i=this.currentWindow)||void 0===i||i.addEventListener("message",this.handleMessage)}return l(e,[{key:"setTarget",value:function(e){this.targetWindow=e}},{key:"setOrigin",value:function(e){this.targetOrigin=e}},{key:"setDebugCallback",value:function(e){this.debugCallback=e}},{key:"destroy",value:function(){var e,t;null===(e=this.currentWindow)||void 0===e||e.removeEventListener("message",this.handleMessage),this.handlers.clear(),null===(t=this.resizeObserver)||void 0===t||t.disconnect()}},{key:"_addPort",value:function(e){var t;this._transferPort(ne.TRANSFER_RECEIVE_PORT,null===(t=this.receivePort)||void 0===t?void 0:t.name,e)}},{key:"_transferReceivePort",value:function(e){this._transferPort(ne.TRANSFER_RECEIVE_PORT,e.name,e.targetPorts)}},{key:"_transferSendPort",value:function(e){this._transferPort(ne.TRANSFER_SEND_PORT,e.name,[e.targetPort])}},{key:"send",value:function(e,t,n){var r;if(!this.targetWindow)return console.warn("[Bridge] Target window not set. Cannot send message:",e),void(null===(r=this.debugCallback)||void 0===r||r.call(this,{id:Z("bridge"),type:"SYSTEM_".concat(ne.ERROR),payload:{message:"Target window not set"}},"OUT"));var i={id:Z("bridge"),type:this.getOriginSendType(e),payload:t};this.debugCallback&&this.debugCallback(i,"OUT"),this.targetWindow.postMessage(i,this.targetOrigin,n)}},{key:"sendError",value:function(e){"WEBAPP"===this.mode&&this.send(ne.ERROR,e.toJSON())}},{key:"sendSubmit",value:function(e){"WEBAPP"===this.mode&&this.send(ne.SUBMIT_REPLY,e)}},{key:"sendMessage",value:function(e,t){"WEBAPP"===this.mode&&this.send(ne.MESSAGE,{type:e,message:t})}},{key:"sendRedirect",value:function(e){if("WEBAPP"===this.mode){if(!e.url)throw new I("url is required","INVALID_REDIRECT_URL","SDK_INTERNAL");try{new URL(e.url)}catch(e){throw new I("Invalid URL","INVALID_REDIRECT_URL","SDK_INTERNAL")}this.send(ne.REDIRECT,e)}}},{key:"redirect",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"redirect";if("WEBAPP"===this.mode){if(!e)throw new I("url is required","INVALID_REDIRECT_URL","SDK_INTERNAL");try{new URL(e)}catch(e){throw new I("Invalid URL","INVALID_REDIRECT_URL","SDK_INTERNAL")}this.send(ne.REDIRECT,{url:e,mode:t})}}},{key:"sendDestroyElement",value:function(e){e||(e=this.scope),"WEBAPP"===this.mode&&this.send(ne.DESTROY_ELEMENT,{elementKey:e})}},{key:"openModal",value:function(e,t){var n,r=this;if(this.openModalPromise)return this.openModalPromise;var i=Z("modal_");this.send(ne.OPEN_MODAL,b(b({},e),{},{scope:this.scope,initialData:t,modalId:i})),null===(n=this.openModalOff)||void 0===n||n.call(this);var o=new Promise((function(e,t){var n=function(){},i=function(){},o=function(){n(),i(),r.openModalOff=void 0,r.openModalPromise=void 0};n=r.once(ne.OPEN_MODAL_ERROR,(function(e){o(),t(new O(e.message,e.code,e.source))}));i=r.on(ne.TRANSFER_APP_PORT,(function(n,r){if(null==r||!r[0])return o(),void t(new I("No ports transferred for modal communication","NO_PORTS_ERROR","SDK_INTERNAL"));o(),e(new $(n,r[0]))})),r.openModalOff=o}));return this.openModalPromise=o,o}},{key:"closeModal",value:function(){var e;null===(e=this.openModalOff)||void 0===e||e.call(this),this.send(ne.CLOSE_MODAL)}},{key:"on",value:function(e,t){var n=this,r=this.getOriginListenType(e);return this.handlers.has(r)||this.handlers.set(r,new Set),this.handlers.get(r).add(t),function(){n.handlers.get(r).delete(t)}}},{key:"once",value:function(e,t){var n=this,r=function r(i,o,a){try{t(i,o,a)}finally{n.off(e,r)}};return this.on(e,r),function(){n.off(e,r)}}},{key:"off",value:function(e,t){var n=this.getOriginListenType(e),r=this.handlers.get(n);r&&r.delete(t)}},{key:"handsShake",value:function(e,t){var n=this;if("WEBAPP"!==this.mode)throw new I("handsShake can only be called in WEBAPP mode","UNKNOWN_ERROR","SDK_INTERNAL");var r=this.on(ne.HANDSHAKE,function(){var r=A(w().mark((function r(i){var o,a;return w().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:"GROUP"===(null==i?void 0:i.elementMode)?i.isMainElement?n.getReceivePort().then((function(e){t(i,e)})):n.getSendPort().then((function(e){t(i,e)})).catch((function(){t(i)})):t(i),o=0,a=re((function(e){(Math.abs(e-o)>10||Math.abs((e-o)/o)>.01)&&(o=e,n.send(ne.HEIGHT_UPDATE,e))}),400),n.resizeObserver=new ResizeObserver((function(e){var t,n=null==e||null===(t=e[0])||void 0===t?void 0:t.contentRect;n&&a(n.height)})),n.resizeObserver.observe(document.body),n.send(ne.HANDSHAKE_ACK,{version:e});case 6:case"end":return r.stop()}}),r)})));return function(e){return r.apply(this,arguments)}}());return this.send(ne.READY_HANDSHAKE),function(){var e;r(),null===(e=n.resizeObserver)||void 0===e||e.disconnect()}}},{key:"getOriginListenType",value:function(e){if("error"===e&&(e=ne.ERROR),this.scope===ae)return e;var t=ie.includes(e)?oe:this.scope;return"".concat(t,":").concat("WEBAPP"===this.mode?"HOST":"WEBAPP",":").concat(e)}},{key:"getOriginSendType",value:function(e){if("error"===e&&(e=ne.ERROR),this.scope===ae)return e;var t=ie.includes(e)?oe:this.scope;return"".concat(t,":").concat(this.mode,":").concat(e)}},{key:"_transferPort",value:function(e,t,n){this.targetWindow?"HOST"===this.mode&&this.targetWindow.postMessage({id:Z(),type:this.getOriginSendType(e),payload:t},this.targetOrigin,n):console.warn("[Bridge] Target window not set. Cannot send port")}},{key:"getReceivePort",value:function(){var e=this;return new Promise((function(t){e.on(ne.TRANSFER_RECEIVE_PORT,(function(n,r){e.receivePort||(e.receivePort=new ee(n)),r&&e.receivePort.addPort(r),t(e.receivePort)}))}))}},{key:"getSendPort",value:function(){var e=this;return new Promise((function(t,n){e.on(ne.TRANSFER_SEND_PORT,(function(e,r){if(r){var i=new te(e,r[0]);t(i)}else n(new Error("no ports transfer"))}))}))}}],[{key:"getGlobalBridge",value:function(t){return new e(t,oe)}},{key:"getNativeBridge",value:function(t){return new e("WEBAPP",ae,t)}},{key:"getBridge",value:function(t,n){if(n===ae||n===oe)throw new Error("Scope cannot be ".concat(ae," or ").concat(oe));return new e(t,n)}}]),e}(),ue=n(4005),ce=n(8306),le=["trackId","userPathAuto","keyFormat"],he=function(){function e(t){u(this,e),y(this,"options",void 0),y(this,"intlTrackerOptions",void 0),y(this,"tracker",void 0),y(this,"trackerInitPromise",void 0),y(this,"trackId",void 0),this.initialOptions(t)}var t;return l(e,[{key:"initialOptions",value:function(e){var t,n,r,i,o=e||{},a=(o.trackId,o.userPathAuto),s=o.keyFormat,u=ue(o,le);(this.options=b(b(b({env:"PROD",compactExtraInfo:!0},this.options),u),{},{appId:(null==e?void 0:e.appId)||(null===(t=this.options)||void 0===t?void 0:t.appId)||"180020050100012557",performance:!0===(null==e?void 0:e.performance)||!0===(null===(n=this.options)||void 0===n?void 0:n.performance),error:!0===(null==e?void 0:e.error)||!0===(null===(r=this.options)||void 0===r?void 0:r.error)}),this.intlTrackerOptions=b(b({},this.options),{},{userPathAuto:a,keyFormat:s}),e&&"trackId"in e)&&(this.trackId=e.trackId||"",this.options=b(b(b({},this.options),u),{},{mdata:b(b(b({},null===(i=this.options)||void 0===i?void 0:i.mdata),u.mdata),{},{trackId:this.trackId})}));return this.options}},{key:"loadTacker",value:function(e){var t=this,n=(0,ce.loadScript)("https://cdn.marmot-cloud.com/tnpm-package/@antintl-intl-tracker/1.3.0/dist/common.min.js","CompatibleTrackerFull");return n?n.then((function(n){var r=n.variable;if(r)return new r(t.initialOptions(e))})):Promise.resolve(void 0)}},{key:"initTracker",value:(t=A(w().mark((function e(t){var n,r=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.tracker||t){e.next=2;break}return e.abrupt("return",this.tracker);case 2:if(t||!this.trackerInitPromise){e.next=4;break}return e.abrupt("return",this.trackerInitPromise);case 4:if(n=this.loadTacker(t).then((function(e){var n,i,o,a,s,u;return e&&(e.set({keyFormat:null!==(n=null!==(i=null==t?void 0:t.keyFormat)&&void 0!==i?i:null===(o=r.intlTrackerOptions)||void 0===o?void 0:o.keyFormat)&&void 0!==n?n:"origin",userPathAuto:null!==(a=null!==(s=null==t?void 0:t.userPathAuto)&&void 0!==s?s:null===(u=r.intlTrackerOptions)||void 0===u?void 0:u.userPathAuto)&&void 0!==a&&a}),r.tracker=e),e})),t){e.next=8;break}return this.trackerInitPromise=n.finally((function(){r.trackerInitPromise=void 0})),e.abrupt("return",this.trackerInitPromise);case 8:return e.abrupt("return",n);case 9:case"end":return e.stop()}}),e,this)}))),function(e){return t.apply(this,arguments)})},{key:"safeCall",value:function(e){return this.initTracker().then(e)}},{key:"setTrackId",value:function(e){this.trackId=e,this.set({mdata:{trackId:e}})}},{key:"set",value:function(e){this.safeCall((function(t){return null==t?void 0:t.set(e)}))}},{key:"pv",value:function(){this.safeCall((function(e){return null==e?void 0:e.pv()}))}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.trackId&&(t[0].d18=this.trackId),this.safeCall((function(e){return null==e?void 0:e.log.apply(e,t)}))}},{key:"click",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.click.apply(e,t)}))}},{key:"expo",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.expo.apply(e,t)}))}},{key:"onSendData",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.onSendData.apply(e,t)}))}},{key:"offSendData",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.offSendData.apply(e,t)}))}},{key:"pageMonitor",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.pageMonitor.apply(e,t)}))}},{key:"reportCustomizedPerformance",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.safeCall((function(e){return null==e?void 0:e.reportCustomizedPerformance.apply(e,t)}))}}]),e}(),fe=new he;var pe;!function(e){e["ar-SA"]="ar-SA",e.kn="kn",e.as="as",e.bho="bho",e["pl-PL"]="pl-PL",e["ko-KR"]="ko-KR",e["da-DK"]="da-DK",e["de-DE"]="de-DE",e["ru-RU"]="ru-RU",e["fr-FR"]="fr-FR",e.gu="gu",e["nl-BE"]="nl-BE",e["nl-NL"]="nl-NL",e["cs-CZ"]="cs-CZ",e.ro="ro",e["lo-LA"]="lo-LA",e["my-MM"]="my-MM",e["bn-BD"]="bn-BD",e["bn-IN"]="bn-IN",e.mr="mr",e["ms-MY"]="ms-MY",e.ml="ml",e.mni="mni",e["ne-NP"]="ne-NP",e.or="or",e["pt-BR"]="pt-BR",e["pt-PT"]="pt-PT",e.pa="pa",e["sv-SE"]="sv-SE",e["ja-JP"]="ja-JP",e.sr="sr",e["si-LK"]="si-LK",e["sk-SK"]="sk-SK",e["tr-TR"]="tr-TR",e["tl-PH"]="tl-PH",e.te="te",e.ta="ta",e["th-TH"]="th-TH",e["ur-PK"]="ur-PK",e["ur-IN"]="ur-IN",e["uk-UA"]="uk-UA",e["iw-IL"]="iw-IL",e["es-ES"]="es-ES",e["es-MX"]="es-MX",e.hu="hu",e["it-IT"]="it-IT",e["in-ID"]="in-ID",e["hi-IN"]="hi-IN",e["vi-VN"]="vi-VN",e["en-PK"]="en-PK",e["en-PL"]="en-PL",e["en-FR"]="en-FR",e["en-PH"]="en-PH",e["en-CZ"]="en-CZ",e["en-CA"]="en-CA",e["en-MM"]="en-MM",e["en-US"]="en-US",e["en-BD"]="en-BD",e["en-MY"]="en-MY",e["en-NP"]="en-NP",e["en-LK"]="en-LK",e["en-TH"]="en-TH",e["en-ES"]="en-ES",e["en-SG"]="en-SG",e["en-HU"]="en-HU",e["en-ID"]="en-ID",e["en-GB"]="en-GB",e["en-VN"]="en-VN",e["en-HK"]="en-HK",e["en-KR"]="en-KR",e["zh-TW"]="zh-TW",e["zh-HK"]="zh-HK",e["zh-SG"]="zh-SG",e["zh-CN"]="zh-CN",e["ar-IQ"]="ar-IQ",e["ckb-IQ"]="ckb-IQ",e.ku="ku",e["kk-KZ"]="kk-KZ",e.af="af",e.am="am",e.az="az",e.be="be",e.bg="bg",e.bs="bs",e.ca="ca",e.cy="cy",e.el="el",e.eo="eo",e.et="et",e.eu="eu",e.fa="fa",e.fi="fi",e.gd="gd",e.gl="gl",e.ha="ha",e.haw="haw",e.hr="hr",e.ig="ig",e.is="is",e.ka="ka",e.km="km",e.ky="ky",e.lb="lb",e.ln="ln",e.lt="lt",e.lv="lv",e.mg="mg",e.mk="mk",e.mn="mn",e.mt="mt",e.om="om",e.ps="ps",e.qu="qu",e.rw="rw",e.sl="sl",e.so="so",e.sq="sq",e.sw="sw",e.tg="tg",e.ti="ti",e.ug="ug",e.uz="uz",e.yo="yo",e.zu="zu"}(pe||(pe={}));var de={};de[pe["ar-SA"]]="阿拉伯语 (沙特阿拉伯)",de[pe.kn]="埃纳德语",de[pe.as]="阿萨姆语",de[pe.bho]="博杰普尔语",de[pe["pl-PL"]]="波兰语 (波兰)",de[pe["ko-KR"]]="朝鲜语 (韩国)",de[pe["da-DK"]]="丹麦语 (丹麦)",de[pe["de-DE"]]="德语 (德国)",de[pe["ru-RU"]]="俄语 (俄罗斯)",de[pe["fr-FR"]]="法语 (法国)",de[pe.gu]="古加拉提语",de[pe["nl-BE"]]="荷兰语 (比利时)",de[pe["nl-NL"]]="荷兰语 (荷兰)",de[pe["cs-CZ"]]="捷克语 (捷克共和国)",de[pe.ro]="罗马尼亚语",de[pe["lo-LA"]]="老挝语 (老挝)",de[pe["my-MM"]]="缅甸语 (缅甸)",de[pe["bn-BD"]]="孟加拉语 (孟加拉)",de[pe["bn-IN"]]="孟加拉语 (印度)",de[pe.mr]="马拉地语",de[pe["ms-MY"]]="马来语 (马来西亚)",de[pe.ml]="马来亚拉姆语",de[pe.mni]="曼尼普里语",de[pe["ne-NP"]]="尼泊尔语 (尼泊尔)",de[pe.or]="欧里亚语",de[pe["pt-BR"]]="葡萄牙语 (巴西)",de[pe["pt-PT"]]="葡萄牙语 (葡萄牙)",de[pe.pa]="旁遮普语",de[pe["sv-SE"]]="瑞典语 (瑞典)",de[pe["ja-JP"]]="日语 (日本)",de[pe.sr]="塞尔维亚语",de[pe["si-LK"]]="僧伽罗语 (斯里兰卡)",de[pe["sk-SK"]]="斯洛伐克语 (斯洛伐克)",de[pe["tr-TR"]]="土耳其语 (土耳其)",de[pe["tl-PH"]]="塔加路族语 (菲律宾)",de[pe.te]="泰卢固语",de[pe.ta]="泰米尔语",de[pe["th-TH"]]="泰语 (泰国)",de[pe["ur-PK"]]="乌尔都语 (巴基斯坦)",de[pe["ur-IN"]]="乌尔都语 (印度)",de[pe["uk-UA"]]="乌克兰语 (乌克兰)",de[pe["iw-IL"]]="希伯来语 (以色列)",de[pe["es-ES"]]="西班牙语 (西班牙)",de[pe["es-MX"]]="西班牙语 (墨西哥)",de[pe.hu]="匈牙利语",de[pe["it-IT"]]="意大利语 (意大利)",de[pe["in-ID"]]="印度尼西亚语 (印度尼西亚)",de[pe["hi-IN"]]="印地语 (印度)",de[pe["vi-VN"]]="越南语 (越南)",de[pe["en-PK"]]="英语 (巴基斯坦)",de[pe["en-PL"]]="英语 (波兰)",de[pe["en-FR"]]="英语 (法国)",de[pe["en-PH"]]="英语 (菲律宾)",de[pe["en-CZ"]]="英语 (捷克共和国)",de[pe["en-CA"]]="英语 (加拿大)",de[pe["en-MM"]]="英语 (缅甸)",de[pe["en-US"]]="英语 (美国)",de[pe["en-BD"]]="英语 (孟加拉)",de[pe["en-MY"]]="英语 (马来西亚)",de[pe["en-NP"]]="英语 (尼泊尔)",de[pe["en-LK"]]="英语 (斯里兰卡)",de[pe["en-TH"]]="英语 (泰国)",de[pe["en-ES"]]="英语 (西班牙)",de[pe["en-SG"]]="英语 (新加坡)",de[pe["en-HU"]]="英语 (匈牙利)",de[pe["en-ID"]]="英语 (印度尼西亚)",de[pe["en-GB"]]="英语 (英国)",de[pe["en-VN"]]="英语 (越南)",de[pe["en-HK"]]="英语 (中国香港)",de[pe["en-KR"]]="英语 (韩国)",de[pe["zh-TW"]]="繁体中文 (中国台湾)",de[pe["zh-HK"]]="繁体中文 (中国香港)",de[pe["zh-SG"]]="简体中文 (新加坡)",de[pe["zh-CN"]]="简体中文 (中国)",de[pe["ar-IQ"]]="阿拉伯语 (伊拉克)",de[pe["ckb-IQ"]]="中库尔德语 (伊拉克)",de[pe.ku]="库尔德语",de[pe["kk-KZ"]]="哈萨克语",de[pe.af]="南非语",de[pe.am]="阿姆哈拉语",de[pe.az]="阿塞拜疆语",de[pe.be]="白俄罗斯语",de[pe.bg]="保加利亚语",de[pe.bs]="波斯尼亚语",de[pe.ca]="加泰罗尼亚语",de[pe.cy]="威尔士语",de[pe.el]="现代希腊语",de[pe.eo]="世界语",de[pe.et]="爱沙尼亚语",de[pe.eu]="巴斯克语",de[pe.fa]="波斯语",de[pe.fi]="芬兰语",de[pe.gd]="爱尔兰语",de[pe.gl]="加利西亚语",de[pe.ha]="豪萨语",de[pe.haw]="夏威夷语",de[pe.hr]="克罗地亚语",de[pe.ig]="伊博语",de[pe.is]="冰岛语",de[pe.ka]="格鲁吉亚语",de[pe.km]="高棉语",de[pe.ky]="吉尔吉斯语",de[pe.lb]="卢森堡语",de[pe.ln]="林格拉语",de[pe.lt]="立陶宛语",de[pe.lv]="拉脱维亚语",de[pe.mg]="马尔加什语",de[pe.mk]="马其顿语",de[pe.mn]="蒙古文",de[pe.mt]="马耳他语",de[pe.om]="奥罗莫语",de[pe.ps]="普什图语",de[pe.qu]="克丘亚语",de[pe.rw]="卢旺达语",de[pe.sl]="斯洛文尼亚语",de[pe.so]="索马里语",de[pe.sq]="阿尔巴尼亚语",de[pe.sw]="斯瓦希里语",de[pe.tg]="塔吉克语",de[pe.ti]="蒂格尼亚语",de[pe.ug]="维吾尔语",de[pe.uz]="乌兹别克语",de[pe.yo]="约鲁巴语",de[pe.zu]="祖鲁语";var ge,ve={};ve[pe["ar-SA"]]="Arabic (Saudi Arabia)",ve[pe.kn]="Kannada",ve[pe.as]="Assamese",ve[pe.bho]="Bhojpuri",ve[pe["pl-PL"]]="Polish (Poland)",ve[pe["ko-KR"]]="Korean (Korean)",ve[pe["da-DK"]]="Danish (Denmark)",ve[pe["de-DE"]]="German (Germany)",ve[pe["ru-RU"]]="Russian (Russia)",ve[pe["fr-FR"]]="French (France)",ve[pe.gu]="Gujarati",ve[pe["nl-BE"]]="Dutch (Belgium)",ve[pe["nl-NL"]]="Dutch (Netherlands)",ve[pe["cs-CZ"]]="Czech (Czech Republic)",ve[pe.ro]="Romanian",ve[pe["lo-LA"]]="Lao (Laos)",ve[pe["my-MM"]]="Burmese (Myanmar)",ve[pe["bn-BD"]]="Bengali (Bangladesh)",ve[pe["bn-IN"]]="Bengali (India)",ve[pe.mr]="Marathi",ve[pe["ms-MY"]]="Malay (Malaysia)",ve[pe.ml]="Malayalam",ve[pe.mni]="Manipuri",ve[pe["ne-NP"]]="Nepalese (Nepal)",ve[pe.or]="Odia (Oriya)",ve[pe["pt-BR"]]="Portuguese (Brazil)",ve[pe["pt-PT"]]="Portuguese (Portugal)",ve[pe.pa]="Punjabi",ve[pe["sv-SE"]]="Swedish (Sweden)",ve[pe["ja-JP"]]="Japanese (Japanese)",ve[pe.sr]="Serbian",ve[pe["si-LK"]]="Sinhala (Sri Lanka)",ve[pe["sk-SK"]]="Slovak (Slovakia)",ve[pe["tr-TR"]]="Turkish (Turkish)",ve[pe["tl-PH"]]="Tagalog (Philippines)",ve[pe.te]="Telugu",ve[pe.ta]="Tamil",ve[pe["th-TH"]]="Thai (Thailand)",ve[pe["ur-PK"]]="Ulduwen (Pakistan)",ve[pe["ur-IN"]]="Urduwen (India)",ve[pe["uk-UA"]]="Ukrainian (Ukraine)",ve[pe["iw-IL"]]="Hebrew (Israel)",ve[pe["es-ES"]]="Spanish (Spain)",ve[pe["es-MX"]]="Spanish (Mexico)",ve[pe.hu]="Hungarian",ve[pe["it-IT"]]="Italian (Italian)",ve[pe["in-ID"]]="Indonesian (Indonesia)",ve[pe["hi-IN"]]="Hindi (India)",ve[pe["vi-VN"]]="Vietnamese (Vietnam)",ve[pe["en-PK"]]="English (Pakistan)",ve[pe["en-PL"]]="English (Poland)",ve[pe["en-FR"]]="English (France)",ve[pe["en-PH"]]="English (Philippines)",ve[pe["en-CZ"]]="English (Czech Republic)",ve[pe["en-CA"]]="English (Canada)",ve[pe["en-MM"]]="English (Myanmar)",ve[pe["en-US"]]="English (US)",ve[pe["en-BD"]]="English (Bangladesh)",ve[pe["en-MY"]]="English (Malaysia)",ve[pe["en-NP"]]="English (Nepal)",ve[pe["en-LK"]]="English (Sri Lanka)",ve[pe["en-TH"]]="English (Thailand)",ve[pe["en-ES"]]="English (Spain)",ve[pe["en-SG"]]="English (Singapore)",ve[pe["en-HU"]]="English (Hungary)",ve[pe["en-ID"]]="English (Indonesia)",ve[pe["en-GB"]]="English (UK)",ve[pe["en-VN"]]="English (Vietnam)",ve[pe["en-HK"]]="English (Hong Kong)",ve[pe["en-KR"]]="English (Korean)",ve[pe["zh-TW"]]="Chinese Traditional (Taiwan)",ve[pe["zh-HK"]]="Chinese Traditional (Hong Kong)",ve[pe["zh-SG"]]="Chinese Simplified (Singapore)",ve[pe["zh-CN"]]="Chinese Simplified (China)",ve[pe["ar-IQ"]]="Arabic (Iraq)",ve[pe["ckb-IQ"]]="Central Kurdish (Iraq)",ve[pe.ku]="Kurdish",ve[pe["kk-KZ"]]="Kazakh",ve[pe.af]="Afrikaans",ve[pe.am]="Amharic",ve[pe.az]="Azerbaijani",ve[pe.be]="Belarusian",ve[pe.bg]="Bulgarian",ve[pe.bs]="Bosnian",ve[pe.ca]="Catalan",ve[pe.cy]="Welsh",ve[pe.el]="Greek",ve[pe.eo]="Esperanto",ve[pe.et]="Estonian",ve[pe.eu]="Basque",ve[pe.fa]="Persian",ve[pe.fi]="Finnish",ve[pe.gd]="Scots Gaelic",ve[pe.gl]="Galician",ve[pe.ha]="Hausa",ve[pe.haw]="Hawaiian",ve[pe.hr]="Croatian",ve[pe.ig]="Igbo",ve[pe.is]="Icelandic",ve[pe.ka]="Georgian",ve[pe.km]="Khmer",ve[pe.ky]="Kyrgyz",ve[pe.lb]="Luxembourgish",ve[pe.ln]="Lingala",ve[pe.lt]="Lithuanian",ve[pe.lv]="Latvian",ve[pe.mg]="Malagasy",ve[pe.mk]="Macedonian",ve[pe.mn]="Mongolian",ve[pe.mt]="Maltese",ve[pe.om]="Oromo",ve[pe.ps]="Pashto",ve[pe.qu]="Quechua",ve[pe.rw]="Kinyarwanda",ve[pe.sl]="Slovenian",ve[pe.so]="Somali",ve[pe.sq]="Albanian",ve[pe.sw]="Swahili",ve[pe.tg]="Tajik",ve[pe.ti]="Tigrinya",ve[pe.ug]="Uyghur",ve[pe.uz]="Uzbek",ve[pe.yo]="Yoruba",ve[pe.zu]="Zulu",function(e){e["ar-SA"]="Arabic",e.kn="kannada",e.as="assamese",e.bho="bhojpuri",e["pl-PL"]="Polish",e["ko-KR"]="Korean",e["da-DK"]="danish",e["de-DE"]="German",e["ru-RU"]="Russian",e["fr-FR"]="French",e.gu="gujarati",e["nl-BE"]="Dutch(Belgium)",e["nl-NL"]="Dutch",e["cs-CZ"]="czech",e.ro="romanian",e["lo-LA"]="Lao (Laos)",e["my-MM"]="Burmese",e["bn-BD"]="Bangadesh",e["bn-IN"]="bangadeshIndia",e.mr="marathi",e["ms-MY"]="Malay",e.ml="malayalam",e.mni="manipuri",e["ne-NP"]="NepaliNepal",e.or="oriya",e["pt-BR"]="portuguese (Brazil)",e["pt-PT"]="Portuguese",e.pa="panjabi",e["sv-SE"]="swedish",e["ja-JP"]="Japanese",e.sr="Serbian",e["si-LK"]="Sinhala",e["sk-SK"]="slovak",e["tr-TR"]="Turkish",e["tl-PH"]="Filipino",e.te="telugu",e.ta="tamil",e["th-TH"]="Thai",e["ur-PK"]="Urdu",e["ur-IN"]="urduIndia",e["uk-UA"]="Ukrainian",e["iw-IL"]="Hebrew",e["es-ES"]="Spanish",e["es-MX"]="Spanish (Mexico)",e.hu="hungarian",e["it-IT"]="Italian",e["in-ID"]="Indonesian",e["hi-IN"]="Hindi",e["vi-VN"]="Vietnamese",e["en-PK"]="Pakistan English",e["en-PL"]="Poland English",e["en-FR"]="English (France)",e["en-PH"]="Philippines English",e["en-CZ"]="Czech English",e["en-CA"]="Canadian English",e["en-MM"]="Myanmar English",e["en-US"]="English",e["en-BD"]="Bangladesh English",e["en-MY"]="Malaysia English",e["en-NP"]="Nepal English",e["en-LK"]="Srilanka English",e["en-TH"]="Thai English",e["en-ES"]="English (Spain)",e["en-SG"]="singapore english",e["en-HU"]="Hungarian English",e["en-ID"]="Indonesian English",e["en-GB"]="British English",e["en-VN"]="Vietnamese English",e["en-HK"]="Hong Kong English",e["en-KR"]="Korean English",e["zh-TW"]="Traditional Chinese",e["zh-HK"]="Traditional Chinese(HK)",e["zh-SG"]="Chinese (Singapore)",e["zh-CN"]="Simplified Chinese",e["ar-IQ"]="Arabic (Iraq)",e["ckb-IQ"]="Central Kurdish (Iraq)",e.ku="Kurdish",e["kk-KZ"]="Kazakh"}(ge||(ge={}));var me,ye,_e,be={"zh-hans":pe["zh-CN"],"zh-hant":pe["zh-TW"],ar:pe["ar-SA"],bn:pe["bn-BD"],cs:pe["cs-CZ"],da:pe["da-DK"],de:pe["de-DE"],en:pe["en-US"],es:pe["es-ES"],fr:pe["fr-FR"],hi:pe["hi-IN"],in:pe["in-ID"],it:pe["it-IT"],iw:pe["iw-IL"],ja:pe["ja-JP"],ko:pe["ko-KR"],lo:pe["lo-LA"],ms:pe["ms-MY"],my:pe["my-MM"],ne:pe["ne-NP"],nl:pe["nl-NL"],pl:pe["pl-PL"],pt:pe["pt-PT"],ru:pe["ru-RU"],si:pe["si-LK"],sk:pe["sk-SK"],sv:pe["sv-SE"],th:pe["th-TH"],tl:pe["tl-PH"],tr:pe["tr-TR"],uk:pe["uk-UA"],ur:pe["ur-PK"],vi:pe["vi-VN"],zh:pe["zh-CN"],kk:pe["kk-KZ"]},Ee={"zh-hant":pe["zh-TW"],"zh-hans":pe["zh-CN"]},we=function(e){return Object.keys(e||{}).map((function(t){return e[t]}))},Se=function(e,t){return-1!==e.indexOf(t)};!function(e){e.ar_EG="ar_EG",e.az_AZ="az_AZ",e.bg_BG="bg_BG",e.bn_BD="bn_BD",e.by_BY="by_BY",e.ca_ES="ca_ES",e.cs_CZ="cs_CZ",e.da_DK="da_DK",e.de_DE="de_DE",e.el_GR="el_GR",e.en_GB="en_GB",e.en_US="en_US",e.es_ES="es_ES",e.et_EE="et_EE",e.fa_IR="fa_IR",e.fi_FI="fi_FI",e.fr_BE="fr_BE",e.fr_CA="fr_CA",e.fr_FR="fr_FR",e.ga_IE="ga_IE",e.gl_ES="gl_ES",e.he_IL="he_IL",e.hi_IN="hi_IN",e.hr_HR="hr_HR",e.hu_HU="hu_HU",e.hy_AM="hy_AM",e.id_ID="id_ID",e.it_IT="it_IT",e.is_IS="is_IS",e.ja_JP="ja_JP",e.ka_GE="ka_GE",e.kmr_IQ="kmr_IQ",e.kn_IN="kn_IN",e.kk_KZ="kk_KZ",e.km_KH="km_KH",e.ko_KR="ko_KR",e.lt_LT="lt_LT",e.lv_LV="lv_LV",e.mk_MK="mk_MK",e.ml_IN="ml_IN",e.mn_MN="mn_MN",e.ms_MY="ms_MY",e.nb_NO="nb_NO",e.ne_NP="ne_NP",e.nl_BE="nl_BE",e.nl_NL="nl_NL",e.pl_PL="pl_PL",e.pt_BR="pt_BR",e.pt_PT="pt_PT",e.ro_RO="ro_RO",e.ru_RU="ru_RU",e.si_LK="si_LK",e.sk_SK="sk_SK",e.sr_RS="sr_RS",e.sl_SI="sl_SI",e.sv_SE="sv_SE",e.ta_IN="ta_IN",e.th_TH="th_TH",e.tr_TR="tr_TR",e.tk_TK="tk_TK",e.ur_PK="ur_PK",e.uk_UA="uk_UA",e.uz_UZ="uz_UZ",e.vi_VN="vi_VN",e.zh_CN="zh_CN",e.zh_HK="zh_HK",e.zh_TW="zh_TW"}(me||(me={})),we(me),function(e){e.af="af",e.am="am",e["ar-dz"]="ar-dz",e["ar-iq"]="ar-iq",e["ar-kw"]="ar-kw",e["ar-ly"]="ar-ly",e["ar-ma"]="ar-ma",e["ar-sa"]="ar-sa",e["ar-tn"]="ar-tn",e.ar="ar",e.az="az",e.be="be",e.bg="bg",e.bi="bi",e.bm="bm",e["bn-bd"]="bn-bd",e.bn="bn",e.bo="bo",e.br="br",e.bs="bs",e.ca="ca",e.cs="cs",e.cv="cv",e.cy="cy",e.da="da",e["de-at"]="de-at",e["de-ch"]="de-ch",e.de="de",e.dv="dv",e.el="el",e["en-au"]="en-au",e["en-ca"]="en-ca",e["en-gb"]="en-gb",e["en-ie"]="en-ie",e["en-il"]="en-il",e["en-in"]="en-in",e["en-nz"]="en-nz",e["en-sg"]="en-sg",e["en-tt"]="en-tt",e.en="en",e.eo="eo",e["es-do"]="es-do",e["es-mx"]="es-mx",e["es-PR"]="es-PR",e["es-us"]="es-us",e.es="es",e.et="et",e.eu="eu",e.fa="fa",e.fi="fi",e.fo="fo",e["fr-ca"]="fr-ca",e["fr-ch"]="fr-ch",e.fr="fr",e.fy="fy",e.ga="ga",e.gd="gd",e.gl="gl",e["gom-latn"]="gom-latn",e.gu="gu",e.he="he",e.hi="hi",e.hr="hr",e.ht="ht",e.hu="hu",e["hy-am"]="hy-am",e.id="id",e.is="is",e["it-ch"]="it-ch",e.it="it",e.ja="ja",e.jv="jv",e.ka="ka",e.kk="kk",e.km="km",e.kn="kn",e.ko="ko",e.ku="ku",e.ky="ky",e.lb="lb",e.lo="lo",e.lt="lt",e.lv="lv",e.me="me",e.mi="mi",e.mk="mk",e.ml="ml",e.mn="mn",e.mr="mr",e["ms-my"]="ms-my",e.ms="ms",e.mt="mt",e.my="my",e.nb="nb",e.ne="ne",e["nl-be"]="nl-be",e.nl="nl",e.nn="nn",e["oc-lnc"]="oc-lnc",e["pa-in"]="pa-in",e.pl="pl",e["pt-br"]="pt-br",e.pt="pt",e.rn="rn",e.ro="ro",e.ru="ru",e.rw="rw",e.sd="sd",e.se="se",e.si="si",e.sk="sk",e.sl="sl",e.sq="sq",e["sr-cyrl"]="sr-cyrl",e.sr="sr",e.ss="ss",e["sv-fi"]="sv-fi",e.sv="sv",e.sw="sw",e.ta="ta",e.te="te",e.tet="tet",e.tg="tg",e.th="th",e.tk="tk",e["tl-ph"]="tl-ph",e.tlh="tlh",e.tr="tr",e.tzl="tzl",e["tzm-latn"]="tzm-latn",e.tzm="tzm",e["ug-cn"]="ug-cn",e.uk="uk",e.ur="ur",e["uz-latn"]="uz-latn",e.uz="uz",e.vi="vi",e["x-pseudo"]="x-pseudo",e.yo="yo",e["zh-cn"]="zh-cn",e["zh-hk"]="zh-hk",e["zh-tw"]="zh-tw",e.zh="zh"}(ye||(ye={})),we(ye),function(e){e.af="af",e["ar-dz"]="ar-dz",e["ar-kw"]="ar-kw",e["ar-ly"]="ar-ly",e["ar-ma"]="ar-ma",e["ar-sa"]="ar-sa",e["ar-tn"]="ar-tn",e.ar="ar",e.az="az",e.be="be",e.bg="bg",e.bm="bm",e["bn-bd"]="bn-bd",e.bn="bn",e.bo="bo",e.br="br",e.bs="bs",e.ca="ca",e.cs="cs",e.cv="cv",e.cy="cy",e.da="da",e["de-at"]="de-at",e["de-ch"]="de-ch",e.de="de",e.dv="dv",e.el="el",e["en-au"]="en-au",e["en-ca"]="en-ca",e["en-gb"]="en-gb",e["en-ie"]="en-ie",e["en-il"]="en-il",e["en-in"]="en-in",e["en-nz"]="en-nz",e["en-sg"]="en-sg",e.eo="eo",e["es-do"]="es-do",e["es-mx"]="es-mx",e["es-us"]="es-us",e.es="es",e.et="et",e.eu="eu",e.fa="fa",e.fi="fi",e.fil="fil",e.fo="fo",e["fr-ca"]="fr-ca",e["fr-ch"]="fr-ch",e.fr="fr",e.fy="fy",e.ga="ga",e.gd="gd",e.gl="gl",e["gom-deva"]="gom-deva",e["gom-latn"]="gom-latn",e.gu="gu",e.he="he",e.hi="hi",e.hr="hr",e.hu="hu",e["hy-am"]="hy-am",e.id="id",e.is="is",e["it-ch"]="it-ch",e.it="it",e.ja="ja",e.jv="jv",e.ka="ka",e.kk="kk",e.km="km",e.kn="kn",e.ko="ko",e.ku="ku",e.ky="ky",e.lb="lb",e.lo="lo",e.lt="lt",e.lv="lv",e.me="me",e.mi="mi",e.mk="mk",e.ml="ml",e.mn="mn",e.mr="mr",e["ms-my"]="ms-my",e.ms="ms",e.mt="mt",e.my="my",e.nb="nb",e.ne="ne",e["nl-be"]="nl-be",e.nl="nl",e.nn="nn",e["oc-lnc"]="oc-lnc",e["pa-in"]="pa-in",e.pl="pl",e["pt-br"]="pt-br",e.pt="pt",e.ro="ro",e.ru="ru",e.sd="sd",e.se="se",e.si="si",e.sk="sk",e.sl="sl",e.sq="sq",e["sr-cyrl"]="sr-cyrl",e.sr="sr",e.ss="ss",e.sv="sv",e.sw="sw",e.ta="ta",e.te="te",e.tet="tet",e.tg="tg",e.th="th",e.tk="tk",e["tl-ph"]="tl-ph",e.tlh="tlh",e.tr="tr",e.tzl="tzl",e["tzm-latn"]="tzm-latn",e.tzm="tzm",e["ug-cn"]="ug-cn",e.uk="uk",e.ur="ur",e["uz-latn"]="uz-latn",e.uz="uz",e.vi="vi",e["x-pseudo"]="x-pseudo",e.yo="yo",e["zh-cn"]="zh-cn",e["zh-hk"]="zh-hk",e["zh-mo"]="zh-mo",e["zh-tw"]="zh-tw"}(_e||(_e={})),we(_e);var Ae,Te,Pe,Re,ke,Le,Ne,Oe,Ie,Ce,Me,De,xe,Be,Ue,He;pe["ar-IQ"],me.ar_EG,_e.ar,ye.ar,pe["ar-SA"],me.ar_EG,_e["ar-sa"],ye["ar-sa"],pe["bn-BD"],me.bn_BD,_e["bn-bd"],ye["bn-bd"],pe["bn-IN"],me.bn_BD,_e.bn,ye.bn,pe["cs-CZ"],me.cs_CZ,_e.cs,ye.cs,pe["da-DK"],me.da_DK,_e.da,ye.da,pe["de-DE"],me.de_DE,_e.de,ye.de,pe["en-BD"],me.en_US,_e["en-gb"],ye.en,pe["en-CA"],me.en_US,_e["en-ca"],ye["en-ca"],pe["en-CZ"],me.en_US,_e["en-gb"],ye.en,pe["en-ES"],me.en_US,_e["en-gb"],ye.en,pe["en-FR"],me.en_US,_e["en-gb"],ye.en,pe["en-GB"],me.en_GB,_e["en-gb"],ye["en-gb"],pe["en-HU"],me.en_US,_e["en-gb"],ye.en,pe["en-ID"],me.en_US,_e["en-gb"],ye.en,pe["en-LK"],me.en_US,_e["en-gb"],ye.en,pe["en-MM"],me.en_US,_e["en-gb"],ye.en,pe["en-MY"],me.en_US,_e["en-gb"],ye.en,pe["en-NP"],me.en_US,_e["en-gb"],ye.en,pe["en-PH"],me.en_US,_e["en-gb"],ye.en,pe["en-PK"],me.en_US,_e["en-gb"],ye.en,pe["en-PL"],me.en_US,_e["en-gb"],ye.en,pe["en-SG"],me.en_US,_e["en-sg"],ye.en,pe["en-TH"],me.en_US,_e["en-gb"],ye.en,pe["en-US"],me.en_US,_e["en-gb"],ye.en,pe["en-VN"],me.en_US,_e["en-gb"],ye.en,pe["en-HK"],me.en_US,_e["en-gb"],ye.en,pe["en-KR"],me.en_US,_e["en-gb"],ye.en,pe["es-ES"],me.es_ES,_e.es,ye.es,pe["es-MX"],me.es_ES,_e.es,ye.es,pe["fr-FR"],me.fr_FR,_e.fr,ye.fr,pe["hi-IN"],me.hi_IN,_e.hi,ye.hi,pe.hu,me.hu_HU,_e.hu,ye.hu,pe["in-ID"],me.id_ID,_e.id,ye.id,pe["it-IT"],me.it_IT,_e.it,ye.it,pe["ja-JP"],me.ja_JP,_e.ja,ye.ja,pe.kn,me.kn_IN,_e.kn,ye.kn,pe["ko-KR"],me.ko_KR,_e.ko,ye.ko,pe.ml,me.ml_IN,_e.ml,ye.ml,pe["ms-MY"],me.ms_MY,_e["ms-my"],ye["ms-my"],pe["ne-NP"],me.ne_NP,_e.ne,ye.ne,pe["nl-BE"],me.nl_BE,_e["nl-be"],ye["nl-be"],pe["nl-NL"],me.nl_NL,_e.nl,ye.nl,pe["pl-PL"],me.pl_PL,_e.pl,ye.pl,pe["pt-BR"],me.pt_BR,_e["pt-br"],ye["pt-br"],pe["pt-PT"],me.pt_PT,_e.pt,ye.pt,pe.ro,me.ro_RO,_e.ro,ye.ro,pe["ru-RU"],me.ru_RU,_e.ru,ye.ru,pe["si-LK"],me.si_LK,_e.si,ye.si,pe["sk-SK"],me.sk_SK,_e.sk,ye.sk,pe.sr,me.sr_RS,_e.sr,ye.sr,pe["sv-SE"],me.sv_SE,_e.sv,ye.sv,pe.ta,me.ta_IN,_e.ta,ye.ta,pe["th-TH"],me.th_TH,_e.th,ye.th,pe["tr-TR"],me.tr_TR,_e.tr,ye.tr,pe["uk-UA"],me.uk_UA,_e.uk,ye.uk,pe["ur-PK"],me.ur_PK,_e.ur,ye.ur,pe["vi-VN"],me.vi_VN,_e.vi,ye.vi,pe["zh-CN"],me.zh_CN,_e["zh-cn"],ye["zh-cn"],pe["zh-HK"],me.zh_HK,_e["zh-hk"],ye["zh-hk"],pe["zh-SG"],me.zh_HK,_e["zh-hk"],ye["zh-hk"],pe["zh-TW"],me.zh_TW,_e["zh-tw"],ye["zh-tw"],pe["kk-KZ"],me.kk_KZ,_e.kk,ye.kk;!function(e){e.ar_SA="ar_SA",e.kn="kn",e.as="as",e.bho="bho",e.pl_PL="pl_PL",e.ko_KR="ko_KR",e.da_DK="da_DK",e.de_DE="de_DE",e.ru_RU="ru_RU",e.fr_FR="fr_FR",e.gu="gu",e.nl_BE="nl_BE",e.nl_NL="nl_NL",e.cs_CZ="cs_CZ",e.ro="ro",e.lo_LA="lo_LA",e.my_MM="my_MM",e.bn_BD="bn_BD",e.bn_IN="bn_IN",e.mr="mr",e.ms_MY="ms_MY",e.ml="ml",e.mni="mni",e.ne_NP="ne_NP",e.or="or",e.pt_BR="pt_BR",e.pt_PT="pt_PT",e.pa="pa",e.sv_SE="sv_SE",e.ja_JP="ja_JP",e.sr="sr",e.si_LK="si_LK",e.sk_SK="sk_SK",e.tr_TR="tr_TR",e.tl_PH="tl_PH",e.te="te",e.ta="ta",e.th_TH="th_TH",e.ur_PK="ur_PK",e.ur_IN="ur_IN",e.uk_UA="uk_UA",e.iw_IL="iw_IL",e.es_ES="es_ES",e.es_MX="es_MX",e.hu="hu",e.it_IT="it_IT",e.in_ID="in_ID",e.hi_IN="hi_IN",e.vi_VN="vi_VN",e.en_PK="en_PK",e.en_PL="en_PL",e.en_FR="en_FR",e.en_PH="en_PH",e.en_CZ="en_CZ",e.en_CA="en_CA",e.en_MM="en_MM",e.en_US="en_US",e.en_BD="en_BD",e.en_MY="en_MY",e.en_NP="en_NP",e.en_LK="en_LK",e.en_TH="en_TH",e.en_ES="en_ES",e.en_SG="en_SG",e.en_HU="en_HU",e.en_ID="en_ID",e.en_GB="en_GB",e.en_VN="en_VN",e.en_HK="en_HK",e.en_KR="en_KR",e.zh_TW="zh_TW",e.zh_HK="zh_HK",e.zh_SG="zh_SG",e.zh_CN="zh_CN",e.ar_IQ="ar_IQ",e.ckb_IQ="ckb_IQ",e.ku="ku",e.kk_KZ="kk_KZ",e.af="af",e.am="am",e.az="az",e.be="be",e.bg="bg",e.bs="bs",e.ca="ca",e.cy="cy",e.el="el",e.eo="eo",e.et="et",e.eu="eu",e.fa="fa",e.fi="fi",e.gd="gd",e.gl="gl",e.ha="ha",e.haw="haw",e.hr="hr",e.ig="ig",e.is="is",e.ka="ka",e.km="km",e.ky="ky",e.lb="lb",e.ln="ln",e.lt="lt",e.lv="lv",e.mg="mg",e.mk="mk",e.mn="mn",e.mt="mt",e.om="om",e.ps="ps",e.qu="qu",e.rw="rw",e.sl="sl",e.so="so",e.sq="sq",e.sw="sw",e.tg="tg",e.ti="ti",e.ug="ug",e.uz="uz",e.yo="yo",e.zu="zu"}(He||(He={}));var je,ze,Ye=we(He),Ge={};Ge[He.kn]="AiNaDeYu",Ge[He.ar_SA]="ALaBoYu (ShaTeALaBo)",Ge[He.ar_IQ]="ALaBoYu (YiLaKe)",Ge[He.as]="ASaMuYu",Ge[He.bho]="BoJiePuErYu",Ge[He.pl_PL]="BoLanYu (BoLan)",Ge[He.ko_KR]="ChaoXianYu (HanGuo)",Ge[He.da_DK]="DanMaiYu (DanMai)",Ge[He.de_DE]="DeYu (DeGuo)",Ge[He.ru_RU]="EYu (ELuoSi)",Ge[He.fr_FR]="FaYu (FaGuo)",Ge[He.gu]="GuJiaLaTiYu",Ge[He.nl_BE]="HeLanYu (BiLiShi)",Ge[He.nl_NL]="HeLanYu (HeLan)",Ge[He.cs_CZ]="JieKeYu (JieKeGongHeGuo)",Ge[He.ku]="KuErDeYu",Ge[He.lo_LA]="LaoWoYu (LaoWo)",Ge[He.ro]="LuoMaNiYaYu",Ge[He.mr]="MaLaDiYu",Ge[He.ms_MY]="MaLaiYu (MaLaiXiYa)",Ge[He.ml]="MaLaiYaLaMuYu",Ge[He.mni]="ManNiPuLiYu",Ge[He.bn_BD]="MengJiaLaYu (MengJiaLa)",Ge[He.bn_IN]="MengJiaLaYu (YinDu)",Ge[He.my_MM]="MianDianYu (MianDian)",Ge[He.ne_NP]="NiBoErYu (NiBoEr)",Ge[He.or]="OuLiYaYu",Ge[He.pa]="PangZhePuYu",Ge[He.pt_BR]="PuTaoYaYu (BaXi)",Ge[He.pt_PT]="PuTaoYaYu (PuTaoYa)",Ge[He.ja_JP]="RiYu (RiBen)",Ge[He.sv_SE]="RuiDianYu (RuiDian)",Ge[He.sr]="SaiErWeiYaYu",Ge[He.si_LK]="SengJiaLuoYu (SiLiLanKa)",Ge[He.sk_SK]="SiLuoFaKeYu (SiLuoFaKe)",Ge[He.te]="TaiLuGuYu",Ge[He.ta]="TaiMiErYu",Ge[He.th_TH]="TaiYu (TaiGuo)",Ge[He.tl_PH]="TaJiaLuZuYu (FeiLvBin)",Ge[He.tr_TR]="TuErQiYu (TuErQi)",Ge[He.ur_PK]="WuErDuYu (BaJiSiTan)",Ge[He.ur_IN]="WuErDuYu (YinDu)",Ge[He.uk_UA]="WuKeLanYu (WuKeLan)",Ge[He.es_ES]="XiBanYaYu (XiBanYa)",Ge[He.es_MX]="XiBanYaYu (MoXiGe)",Ge[He.iw_IL]="XiBoLaiYu (YiSeLie)",Ge[He.hu]="XiongYaLiYu",Ge[He.it_IT]="YiDaLiYu (YiDaLi)",Ge[He.hi_IN]="YinDiYu (YinDu)",Ge[He.in_ID]="YinDuNiXiYaYu (YinDuNiXiYa)",Ge[He.en_PK]="YingYu (BaJiSiTan)",Ge[He.en_PL]="YingYu (BoLan)",Ge[He.en_FR]="YingYu (FaGuo)",Ge[He.en_PH]="YingYu (FeiLvBin)",Ge[He.en_CA]="YingYu (JiaNaDa)",Ge[He.en_CZ]="YingYu (JieKeGongHeGuo)",Ge[He.en_MY]="YingYu (MaLaiXiYa)",Ge[He.en_US]="YingYu (MeiGuo)",Ge[He.en_BD]="YingYu (MengJiaLa)",Ge[He.en_MM]="YingYu (MianDian)",Ge[He.en_NP]="YingYu (NiBoEr)",Ge[He.en_LK]="YingYu (SiLiLanKa)",Ge[He.en_TH]="YingYu (TaiGuo)",Ge[He.en_ES]="YingYu (XiBanYa)",Ge[He.en_SG]="YingYu (XinJiaPo)",Ge[He.en_HU]="YingYu (XiongYaLi)",Ge[He.en_ID]="YingYu (YinDuNiXiYa)",Ge[He.en_GB]="YingYu (YingGuo)",Ge[He.en_VN]="YingYu (YueNan)",Ge[He.en_HK]="YingYu (XiangGang)",Ge[He.en_KR]="YingYu (HanGuo)",Ge[He.vi_VN]="YueNanYu (YueNan)",Ge[He.ckb_IQ]="ZhongKuErDeYu (YiLaKe)",Ge[He.zh_TW]="ZhongWen (TaiWanDiQu)",Ge[He.zh_HK]="ZhongWen (XiangGang)",Ge[He.zh_SG]="ZhongWen (XinJiaPo)",Ge[He.zh_CN]="ZhongWen (ZhongGuo)",Ge[He.kk_KZ]="HaSaKeYu (HaSaKeSiTan)",Ge[He.af]="NanFeiYu",Ge[He.am]="AMuHaLaYu",Ge[He.az]="ASaiBaiJiangYu",Ge[He.be]="BaiErLuoSiYu",Ge[He.bg]="BaoJiaLiYaYu",Ge[He.bs]="BoSiNiYaYu",Ge[He.ca]="JiaTaiLuoNiYaYu",Ge[He.cy]="WeiErShiYu",Ge[He.el]="XianDaiXiLaYu",Ge[He.eo]="ShiJieYu",Ge[He.et]="AiShaNiYaYu",Ge[He.eu]="BaSiKeYu",Ge[He.fa]="BoSiYu",Ge[He.fi]="FenLanYu",Ge[He.gd]="AiErLanYu",Ge[He.gl]="JiaLiXiYaYu",Ge[He.ha]="HaoSaYu",Ge[He.haw]="XiaWeiYiYu",Ge[He.hr]="KeLuoDiYaYu",Ge[He.ig]="YiBoYu",Ge[He.is]="BingDaoYu",Ge[He.ka]="GeLuJiYaYu",Ge[He.km]="GaoMianYu",Ge[He.ky]="JiErJiSiYu",Ge[He.lb]="LuSenBaoYu",Ge[He.ln]="LinGeLaYu",Ge[He.lt]="LiTaoWanYu",Ge[He.lv]="LaTuoWeiYaYu",Ge[He.mg]="MaErJiaShiYu",Ge[He.mk]="MaQiDunYu",Ge[He.mn]="MengGuWen",Ge[He.mt]="MaErTaYu",Ge[He.om]="AoLuoMoYu",Ge[He.ps]="PuShiTuYu",Ge[He.qu]="KeQiuYaYu",Ge[He.rw]="LuWangDaYu",Ge[He.sl]="SiLuoWeiNiYaYu",Ge[He.so]="SuoMaLiYu",Ge[He.sq]="AErBaNiYaYu",Ge[He.sw]="SiWaXiLiYu",Ge[He.tg]="TaJiKeYu",Ge[He.ti]="DiGeNiYaYu",Ge[He.ug]="WeiWuErYu",Ge[He.uz]="WuZiBieKeYu",Ge[He.yo]="YueLuBaYu",Ge[He.zu]="ZuLuYu",function(e){e.AiSelected="AiSelected",e.Aliyun="Aliyun",e["ChatGPT3.5"]="ChatGPT3.5",e.Google="Google",e.Papago="Papago",e.DeepL="DeepL",e.Microsoft="Microsoft",e.Amazon="Amazon"}(je||(je={})),function(e){e.AiSelected="AiSelected",e.Aliyun="Aliyun",e["ChatGPT3.5"]="ChatGPT3.5",e.Google="Google",e.Papago="Papago",e.DeepL="DeepL",e.Microsoft="Microsoft",e.Amazon="Amazon"}(ze||(ze={})),we(ze);var Fe=Object.assign(Object.assign({},ze),{TranslationMemory:"TranslationMemory"}),Ke=(we(Fe),{aliyunSupportedLanguages:["ab","sq","ak","ar","an","am","as","az","ast","nch","ee","ay","ga","et","oj","oc","or","om","os","tpi","ba","eu","be","ber","bm","pag","bg","se","bem","byn","bi","bal","is","pl","bs","fa","bho","br","ch","cbk","cv","ts","tt","da","shn","tet","de","nds","sco","dv","kdx","dtp","ru","fo","fr","sa","fil","fj","fi","fur","fvr","kg","km","ngu","kl","ka","gos","gu","gn","kk","ht","ko","ha","nl","cnr","hup","gil","rn","quc","ky","gl","ca","cs","kab","kn","kr","csb","kha","kw","xh","co","mus","crh","tlh","hbs","qu","ks","ku","la","ltg","lv","lo","lt","li","ln","lg","lb","rue","rw","ro","rm","rom","jbo","mg","gv","mt","mr","ml","ms","chm","mk","mh","kek","mai","mfe","mi","mn","bn","my","hmn","umb","nv","af","ne","niu","no","pmn","pap","pa","pt","ps","ny","tw","chr","ja","sv","sm","sg","si","hsb","eo","sl","sw","so","sk","tl","tg","ty","te","ta","th","to","toi","ti","tvl","tyv","tr","tk","wa","war","cy","ve","vo","wo","udm","ur","uz","es","ie","fy","szl","he","hil","haw","el","lfn","sd","hu","sn","ceb","syr","su","hy","ace","iba","ig","io","ilo","iu","it","yi","ia","hi","id","inh","en","yo","vi","zza","jv","zh","zh-tw","yue","zu"],mapAliyunLanguage:function(e){if(e===He.zh_HK||e===He.zh_TW||e===He.zh_SG)return"zh-tw";if(e===He.in_ID)return"id";if(e===He.iw_IL)return"he";var t=e.split("_")[0];return Se(Ke.aliyunSupportedLanguages,t)?t:null},googleSupportedLanguages:["af","sq","am","ar","hy","as","ay","az","bm","eu","be","bn","bho","bs","bg","ca","ceb","zh","zh-CN","zh-TW","co","hr","cs","da","dv","doi","nl","en","eo","et","ee","fil","fi","fr","fy","gl","ka","de","el","gn","gu","ht","ha","haw","he","iw","hi","hmn","hu","is","ig","ilo","id","ga","it","ja","jv","jw","kn","kk","km","rw","gom","ko","kri","ku","ckb","ky","lo","la","lv","ln","lt","lg","lb","mk","mai","mg","ms","ml","mt","mi","mr","mni-Mtei","lus","mn","my","ne","no","ny","or","om","ps","fa","pl","pt","pa","qu","ro","ru","sm","sa","gd","nso","sr","st","sn","sd","si","sk","sl","so","es","su","sw","sv","tl","tg","ta","tt","te","th","ti","ts","tr","tk","ak","uk","ur","ug","uz","vi","cy","xh","yi","yo","zu"],mapGoogleLanguage:function(e){if(e===He.zh_HK||e===He.zh_TW||e===He.zh_SG)return"zh-TW";if(e===He.in_ID)return"id";if(e===He.mni)return"mni-Mtei";var t=e.split("_")[0];return Se(Ke.googleSupportedLanguages,t)?t:null},papagoSupportedLanguages:["ko","en","ja","zh-CN","zh-TW"],mapPapagoLanguage:function(e){if(e===He.zh_CN)return"zh-CN";if(e===He.zh_HK||e===He.zh_TW||e===He.zh_SG)return"zh-TW";var t=e.split("_")[0];return Se(Ke.papagoSupportedLanguages,t)?t:null},deepLSupportedSourceLanguages:["AR","BG","CS","DA","DE","EL","EN","ES","ET","FI","FR","HU","ID","IT","JA","KO","LT","LV","NB","NL","PL","PT","RO","RU","SK","SL","SV","TR","UK","ZH"],deepLSupportedLanguages:["AR","BG","CS","DA","DE","EL","EN-GB","EN-US","ES","ET","FI","FR","HU","ID","IT","JA","KO","LT","LV","NB","NL","PL","PT-BR","PT-PT","RO","RU","SK","SL","SV","TR","UK","ZH"],mapDeepLSourceLanguage:function(e){var t=e.toUpperCase();if(e===He.in_ID)return"ID";var n=t.split("_")[0];return Se(Ke.deepLSupportedSourceLanguages,n)?n:null},mapDeepLLanguage:function(e){var t=e.toUpperCase();if(e===He.zh_CN||e===He.zh_SG)return"ZH";if(e===He.zh_HK||e===He.zh_TW)return null;if(e===He.en_GB||e===He.en_US||e===He.pt_BR||e===He.pt_PT)return t.replace("_","-");if(e===He.in_ID)return"ID";var n=t.split("_")[0];return"EN"===n?"EN-US":Se(Ke.deepLSupportedLanguages,n)?n:null},microsoftSupportedLanguages:["af","sq","am","ar","hy","as","az","bn","ba","eu","bho","brx","bs","bg","yue","ca","lzh","zh-Hans","zh-Hant","sn","hr","cs","da","prs","dv","doi","nl","en","et","fo","fj","fil","fi","fr","fr-ca","gl","ka","de","el","gu","ht","ha","he","hi","mww","hu","is","ig","id","ikt","iu","iu-Latn","ga","it","ja","kn","ks","kk","km","rw","tlh-Latn","tlh-Piqd","gom","ko","ku","kmr","ky","lo","lv","lt","ln","dsb","lug","mk","mai","mg","ms","ml","mt","mi","mr","mn-Cyrl","mn-Mong","my","ne","nb","nya","or","ps","fa","pl","pt","pt-pt","pa","otq","ro","run","ru","sm","sr-Cyrl","sr-Latn","st","nso","tn","sd","si","sk","sl","so","es","sw","sv","ty","ta","tt","te","th","bo","ti","to","tr","tk","uk","hsb","ur","ug","uz","vi","cy","xh","yo","yua","zu"],mapMicrosoftLanguage:function(e){if(e===He.pt_PT)return"pt-pt";if(e===He.pt_BR)return"pt";if([He.zh_CN,He.zh_SG].includes(e))return"zh-Hans";if([He.zh_HK,He.zh_TW].includes(e))return"zh-Hant";if(e===He.iw_IL)return"he";if(e===He.in_ID)return"id";if(e===He.ckb_IQ)return"ku";var t=e.split("_")[0];return Se(Ke.microsoftSupportedLanguages,t)?t:null},amazonSupportedLanguages:["af","sq","am","ar","hy","az","bn","bs","bg","ca","zh","zh-TW","hr","cs","da","fa-AF","nl","en","et","fa","tl","fi","fr","fr-CA","ka","de","el","gu","ht","ha","he","hi","hu","is","id","ga","it","ja","kn","kk","ko","lv","lt","mk","ms","ml","mt","mr","mn","no","ps","pl","pt","pt-PT","pa","ro","ru","sr","si","sk","sl","so","es","es-MX","sw","sv","ta","te","th","tr","uk","ur","uz","vi","cy"],mapAmazonLanguage:function(e){if(e===He.pt_PT)return"pt-PT";if(e===He.pt_BR)return"pt";if(e===He.es_MX)return"es-MX";if(e===He.in_ID)return"id";if(e===He.zh_CN||e===He.zh_SG)return"zh";if(e===He.zh_HK||e===He.zh_TW)return"zh-TW";var t=e.split("_")[0];return Se(Ke.amazonSupportedLanguages,t)?t:null}}),Ve={};Ve[ze.AiSelected]=Ye,Ve[ze.Aliyun]=Ye.filter((function(e){return Boolean(Ke.mapAliyunLanguage(e))})),Ve[ze["ChatGPT3.5"]]=Ye,Ve[ze.Google]=Ye.filter((function(e){return Boolean(Ke.mapGoogleLanguage(e))})),Ve[ze.Papago]=Ye.filter((function(e){return Boolean(Ke.mapPapagoLanguage(e))})),Ve[ze.DeepL]=Ye.filter((function(e){return Boolean(Ke.mapDeepLLanguage(e))})),Ve[ze.Microsoft]=Ye.filter((function(e){return Boolean(Ke.mapMicrosoftLanguage(e))})),Ve[ze.Amazon]=Ye.filter((function(e){return Boolean(Ke.mapAmazonLanguage(e))}));var We={};We[ze.AiSelected]=Ye,We[ze.Aliyun]=Ye.filter((function(e){return Boolean(Ke.mapAliyunLanguage(e))})),We[ze["ChatGPT3.5"]]=Ye,We[ze.Google]=Ye.filter((function(e){return Boolean(Ke.mapGoogleLanguage(e))})),We[ze.Papago]=Ye.filter((function(e){return Boolean(Ke.mapPapagoLanguage(e))})),We[ze.DeepL]=Ye.filter((function(e){return Boolean(Ke.mapDeepLSourceLanguage(e))})),We[ze.Microsoft]=Ye.filter((function(e){return Boolean(Ke.mapMicrosoftLanguage(e))})),We[ze.Amazon]=Ye.filter((function(e){return Boolean(Ke.mapAmazonLanguage(e))})),qe=Ye.map((function(e){return[e,we(ze).filter((function(t){return Se(Ve[t],e)}))]})),Je={},Object.keys(qe||{}).forEach((function(e){var t=qe[e],n=t[0],r=t[1];Je[n]=r}));var qe,Je,Xe={};Xe[He.ar_SA]="العربية)السعودية)",Xe[He.kn]="ಕನ್ನಡ",Xe[He.as]="অসমীয়া",Xe[He.bho]="भोजपुरी",Xe[He.pl_PL]="Polski (Polska)",Xe[He.ko_KR]="한국어 (대한민국)",Xe[He.da_DK]="Dansk (Danmark)",Xe[He.de_DE]="Deutsch (Deutschland)",Xe[He.ru_RU]="Русский (Россия)",Xe[He.fr_FR]="Français (France)",Xe[He.gu]="ગુજરાતી",Xe[He.nl_BE]="Nederlands (Belgium)",Xe[He.nl_NL]="Nederlands (Nederland)",Xe[He.cs_CZ]="Čeština (Česká republika)",Xe[He.ro]="Română",Xe[He.lo_LA]="ລາວ (ລາວ)",Xe[He.my_MM]="မြန်မာဘာသာ (မြန်မာ)",Xe[He.bn_BD]="বাংলা (বাংলাদেশ)",Xe[He.bn_IN]="বাংলা (ভারত)",Xe[He.mr]="मराठी",Xe[He.ms_MY]="Bahasa Melayu (Malaysia)",Xe[He.ml]="മലയാളം",Xe[He.mni]="ꯃꯩꯇꯩꯂꯣꯟ",Xe[He.ne_NP]="नेपाली (नेपाल)\t",Xe[He.or]="ଓଡ଼ିଆ",Xe[He.pt_BR]="Português (Brasil)",Xe[He.pt_PT]="Português (Portugal)",Xe[He.pa]="پنجابی",Xe[He.sv_SE]="Svenska (Sverige)",Xe[He.ja_JP]="日本語",Xe[He.sr]="Српски",Xe[He.si_LK]="සිංහල (ශ්රී ලංකාව)",Xe[He.sk_SK]="Slovenčina (Slovensko)",Xe[He.tr_TR]="Türkçe (Türkiye)",Xe[He.tl_PH]="Wikang Tagalog (Philippines)",Xe[He.te]="తెలుగు",Xe[He.ta]="தமிழ்",Xe[He.th_TH]="ไทย (ประเทศไทย)",Xe[He.ur_PK]="اردو)پاکستان)",Xe[He.ur_IN]="اردو)بھارت)",Xe[He.uk_UA]="Українська (Україна)",Xe[He.iw_IL]="עִבְרִית (ישראל)",Xe[He.es_ES]="Español (España)",Xe[He.es_MX]="Español (México)",Xe[He.hu]="Magyar",Xe[He.it_IT]="Italiano (Italia)",Xe[He.in_ID]="Bahasa Indonesia (Indonesia)",Xe[He.hi_IN]="हिन्दी (भारत)",Xe[He.vi_VN]="Tiếng Việt (Việt Nam)",Xe[He.en_PK]="English (Pakistan)",Xe[He.en_PL]="English (Poland)",Xe[He.en_FR]="English (France)",Xe[He.en_PH]="English (Philippines)",Xe[He.en_CZ]="English (Czech Republic)",Xe[He.en_CA]="English (Canada)",Xe[He.en_MM]="English (Myanmar)",Xe[He.en_US]="English (United States)",Xe[He.en_BD]="English (Bangladesh)",Xe[He.en_MY]="English (Malaysia)",Xe[He.en_NP]="English (Nepal)",Xe[He.en_LK]="English (Sri Lanka)",Xe[He.en_TH]="English (Thailand)",Xe[He.en_ES]="English (Spain)",Xe[He.en_SG]="English (Singapore)",Xe[He.en_HU]="English (Hungary)",Xe[He.en_ID]="English (Indonesia)",Xe[He.en_GB]="English (Great Britain)",Xe[He.en_VN]="English (Vietnam)",Xe[He.en_HK]="English (Hong Kong)",Xe[He.en_KR]="English (Korea)",Xe[He.zh_TW]="繁体中文 (中國台灣)",Xe[He.zh_HK]="繁体中文 (中國香港)",Xe[He.zh_SG]="简体中文 (新加坡)",Xe[He.zh_CN]="简体中文",Xe[He.ar_IQ]="العربية (العراق)",Xe[He.ckb_IQ]="کوردیی ناوەندی (عێراق)",Xe[He.ku]="کورمانجی",Xe[He.kk_KZ]="قازاقشا ",Xe[He.af]="Afrikaans",Xe[He.am]="አማርኛ",Xe[He.az]="Azərbaycan",Xe[He.be]="беларуская мова",Xe[He.bg]="Български",Xe[He.bs]="босански",Xe[He.ca]="Català",Xe[He.cy]="Cymraeg",Xe[He.el]="Ελληνικά",Xe[He.eo]="Esperanto",Xe[He.et]="eesti keel",Xe[He.eu]="Euskara",Xe[He.fa]="فارسی",Xe[He.fi]="Suomi",Xe[He.gd]="Gaeilge",Xe[He.gl]="Galego",Xe[He.ha]="هَوُسَ",Xe[He.haw]="ʻŌlelo Hawaiʻi",Xe[He.hr]="Hrvatski",Xe[He.ig]="Asụsụ Igbo",Xe[He.is]="Íslenska",Xe[He.ka]="ქართული",Xe[He.km]="ភាសាខ្មែរ",Xe[He.ky]="кыргыз тили",Xe[He.lb]="Lëtzebuergesch",Xe[He.ln]="Lingála",Xe[He.lt]="lietuvių kalba",Xe[He.lv]="Latviešu valoda",Xe[He.mg]="malagasy",Xe[He.mk]="македонски",Xe[He.mn]="монгол хэл",Xe[He.mt]="Malti",Xe[He.om]="Oromoo",Xe[He.ps]="پښتو",Xe[He.qu]="Quechua",Xe[He.rw]="Ikinyarwanda",Xe[He.sl]="slovenščina",Xe[He.so]="Af-Soomaali",Xe[He.sq]="Gjuha shqipe",Xe[He.sw]="Kiswahili",Xe[He.tg]="тоҷикӣ",Xe[He.ti]="ትግርኛ",Xe[He.ug]="ئۇيغۇر تىلى",Xe[He.uz]="Ўзбек тили",Xe[He.yo]="Èdè Yorùbá",Xe[He.zu]="isiZulu",ze.AiSelected,(Ae={})[He.en_US]="AI Selected",Ae[He.zh_CN]="AI 精选",(Te={})[He.en_US]="AI selection of translations",Te[He.zh_CN]="多渠道翻译的 AI 精选",We.AiSelected,Ve.AiSelected,(Pe={})[He.en_US]="Use ChatGPT 4.0 to compare and select translation results from multiple sources.\nThe translated content will undergo risk control review and may return blank, please check carefully.",Pe[He.zh_CN]="利用 ChatGPT 4.0 进行多渠道翻译结果的对比和精选;\n翻译内容会经过风控审核,可能会返回空内容,请仔细检查;",(Re={})[He.en_US]="Use ChatGPT 4.0 to compare and select translation results from multiple sources.\nThe translated content will undergo risk control review and may return blank, please check carefully.",Re[He.zh_CN]="利用 ChatGPT 4.0 进行多渠道翻译结果的对比和精选;\n翻译内容会经过风控审核,可能会返回空内容,请仔细检查;",ze["ChatGPT3.5"],(ke={})[He.en_US]="GPT-3.5",ke[He.zh_CN]="GPT-3.5",(Le={})[He.en_US]="The translated content will undergo risk control review and may return blank, please check carefully.",Le[He.zh_CN]="翻译内容会经过风控审核,可能会返回空内容,请仔细检查",(Ne={})[He.en_US]="The translated content will undergo risk control review and may return blank, please check carefully.",Ne[He.zh_CN]="翻译内容会经过风控审核,可能会返回空内容,请仔细检查",We["ChatGPT3.5"],Ve["ChatGPT3.5"],ze.Aliyun,(Oe={})[He.en_US]="Alibaba",Oe[He.zh_CN]="阿里云",We.Aliyun,Ve.Aliyun,ze.Google,(Ie={})[He.en_US]="Google",Ie[He.zh_CN]="Google",We.Google,Ve.Google,ze.DeepL,(Ce={})[He.en_US]="DeepL",Ce[He.zh_CN]="DeepL",We.DeepL,Ve.DeepL,ze.Microsoft,(Me={})[He.en_US]="Azure AI",Me[He.zh_CN]="Azure AI",We.Microsoft,Ve.Microsoft,ze.Amazon,(De={})[He.en_US]="Amazon",De[He.zh_CN]="Amazon",We.Amazon,Ve.Amazon,ze.Papago,(xe={})[He.en_US]="Papago",xe[He.zh_CN]="Papago",(Be={})[He.en_US]="Papago does not support translating HTML and will automatically skip HTML content during batch translation.",Be[He.zh_CN]="Papago 不支持翻译 HTML,在批量翻译时会自动跳过 HTML 内容",(Ue={})[He.en_US]="Papago does not support HTML. Available locales are Chinese, Japanese, Korean, and English. Please check the translation results carefully.",Ue[He.zh_CN]="Papago 不支持翻译 HTML,仅支持翻译中、日、韩、英,请仔细检查翻译结果",We.Papago,Ve.Papago;var Ze=Object.keys(pe).map((function(e){return pe[e]})),Qe=/^##@@@(.+?)##(.+?)@@@##(.+?)@@@##$/,$e=function(e,t){return($e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function et(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}$e(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var tt,nt,rt,it=function(){return(it=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function ot(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}function at(e){return e.type===nt.literal}function st(e){return e.type===nt.argument}function ut(e){return e.type===nt.number}function ct(e){return e.type===nt.date}function lt(e){return e.type===nt.time}function ht(e){return e.type===nt.select}function ft(e){return e.type===nt.plural}function pt(e){return e.type===nt.pound}function dt(e){return e.type===nt.tag}function gt(e){return!(!e||"object"!=k()(e)||e.type!==rt.number)}function vt(e){return!(!e||"object"!=k()(e)||e.type!==rt.dateTime)}"function"==typeof SuppressedError&&SuppressedError,function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(tt||(tt={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(nt||(nt={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(rt||(rt={}));var mt=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,yt=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function _t(e){var t={};return e.replace(yt,(function(e){var n=e.length;switch(e[0]){case"G":t.era=4===n?"long":5===n?"narrow":"short";break;case"y":t.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][n-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===n?"short":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][n-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][n-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][n-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][n-1];break;case"s":t.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=n<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),t}var bt=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i,Et=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,wt=/^(@+)?(\+|#+)?[rs]?$/g,St=/(\*)(0+)|(#+)(0+)|(0+)/g,At=/^(0+)$/;function Tt(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(wt,(function(e,n,r){return"string"!=typeof r?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===r?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""})),t}function Pt(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function Rt(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if("+!"===n?(t.signDisplay="always",e=e.slice(2)):"+?"===n&&(t.signDisplay="exceptZero",e=e.slice(2)),!At.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function kt(e){return Pt(e)||{}}function Lt(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n];switch(i.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=i.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=i.options[0].replace(/^(.*?)-/,"");continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=it(it(it({},t),{notation:"scientific"}),i.options.reduce((function(e,t){return it(it({},e),kt(t))}),{}));continue;case"engineering":t=it(it(it({},t),{notation:"engineering"}),i.options.reduce((function(e,t){return it(it({},e),kt(t))}),{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(i.options[0]);continue;case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(St,(function(e,n,r,i,o,a){if(n)t.minimumIntegerDigits=r.length;else{if(i&&o)throw new Error("We currently do not support maximum integer digits");if(a)throw new Error("We currently do not support exact integer digits")}return""}));continue}if(At.test(i.stem))t.minimumIntegerDigits=i.stem.length;else if(Et.test(i.stem)){if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(Et,(function(e,n,r,i,o,a){return"*"===r?t.minimumFractionDigits=n.length:i&&"#"===i[0]?t.maximumFractionDigits=i.length:o&&a?(t.minimumFractionDigits=o.length,t.maximumFractionDigits=o.length+a.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""}));var o=i.options[0];"w"===o?t=it(it({},t),{trailingZeroDisplay:"stripIfInteger"}):o&&(t=it(it({},t),Tt(o)))}else if(wt.test(i.stem))t=it(it({},t),Tt(i.stem));else{var a=Pt(i.stem);a&&(t=it(it({},t),a));var s=Rt(i.stem);s&&(t=it(it({},t),s))}}return t}var Nt,Ot={"001":["H","h"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["H","h","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["H","hB","h","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["H","h","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["H","hB","h","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["H","h","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["H","h","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["H","h","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["H","h","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["H","hB","h","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["H","h","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["H","h","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["H","h","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function It(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n,r=e.language;return"root"!==r&&(n=e.maximize().region),(Ot[n||""]||Ot[r||""]||Ot["".concat(r,"-001")]||Ot["001"])[0]}var Ct=new RegExp("^".concat(mt.source,"*")),Mt=new RegExp("".concat(mt.source,"*$"));function Dt(e,t){return{start:e,end:t}}var xt=!!String.prototype.startsWith&&"_a".startsWith("a",1),Bt=!!String.fromCodePoint,Ut=!!Object.fromEntries,Ht=!!String.prototype.codePointAt,jt=!!String.prototype.trimStart,zt=!!String.prototype.trimEnd,Yt=Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},Gt=!0;try{Gt="a"===(null===(Nt=Zt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===Nt?void 0:Nt[0])}catch(pe){Gt=!1}var Ft,Kt=xt?function(e,t,n){return e.startsWith(t,n)}:function(e,t,n){return e.slice(n,n+t.length)===t},Vt=Bt?String.fromCodePoint:function(){for(var e=arguments,t=[],n=0;n<arguments.length;n++)t[n]=e[n];for(var r,i="",o=t.length,a=0;o>a;){if((r=t[a++])>1114111)throw RangeError(r+" is not a valid code point");i+=r<65536?String.fromCharCode(r):String.fromCharCode(55296+((r-=65536)>>10),r%1024+56320)}return i},Wt=Ut?Object.fromEntries:function(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n],o=i[0],a=i[1];t[o]=a}return t},qt=Ht?function(e,t){return e.codePointAt(t)}:function(e,t){var n=e.length;if(!(t<0||t>=n)){var r,i=e.charCodeAt(t);return i<55296||i>56319||t+1===n||(r=e.charCodeAt(t+1))<56320||r>57343?i:r-56320+(i-55296<<10)+65536}},Jt=jt?function(e){return e.trimStart()}:function(e){return e.replace(Ct,"")},Xt=zt?function(e){return e.trimEnd()}:function(e){return e.replace(Mt,"")};function Zt(e,t){return new RegExp(e,t)}if(Gt){var Qt=Zt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");Ft=function(e,t){var n;return Qt.lastIndex=t,null!==(n=Qt.exec(e)[1])&&void 0!==n?n:""}}else Ft=function(e,t){for(var n=[];;){var r=qt(e,t);if(void 0===r||tn(r)||nn(r))break;n.push(r),t+=r>=65536?2:1}return Vt.apply(void 0,n)};var $t=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,n){for(var r=[];!this.isEOF();){var i=this.char();if(123===i){if((o=this.parseArgument(e,n)).err)return o;r.push(o.val)}else{if(125===i&&e>0)break;if(35!==i||"plural"!==t&&"selectordinal"!==t){if(60===i&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(tt.UNMATCHED_CLOSING_TAG,Dt(this.clonePosition(),this.clonePosition()))}if(60===i&&!this.ignoreTag&&en(this.peek()||0)){if((o=this.parseTag(e,t)).err)return o;r.push(o.val)}else{var o;if((o=this.parseLiteral(e,t)).err)return o;r.push(o.val)}}else{var a=this.clonePosition();this.bump(),r.push({type:nt.pound,location:Dt(a,this.clonePosition())})}}}return{val:r,err:null}},e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();var r=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:nt.literal,value:"<".concat(r,"/>"),location:Dt(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var i=this.parseMessage(e+1,t,!0);if(i.err)return i;var o=i.val,a=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!en(this.char()))return this.error(tt.INVALID_TAG,Dt(a,this.clonePosition()));var s=this.clonePosition();return r!==this.parseTagName()?this.error(tt.UNMATCHED_CLOSING_TAG,Dt(s,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:nt.tag,value:r,children:o,location:Dt(n,this.clonePosition())},err:null}:this.error(tt.INVALID_TAG,Dt(a,this.clonePosition())))}return this.error(tt.UNCLOSED_TAG,Dt(n,this.clonePosition()))}return this.error(tt.INVALID_TAG,Dt(n,this.clonePosition()))},e.prototype.parseTagName=function(){var e,t=this.offset();for(this.bump();!this.isEOF()&&(45===(e=this.char())||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039);)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(e,t){for(var n=this.clonePosition(),r="";;){var i=this.tryParseQuote(t);if(i)r+=i;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var a=this.tryParseLeftAngleBracket();if(!a)break;r+=a}}}var s=Dt(n,this.clonePosition());return{val:{type:nt.literal,value:r,location:s},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(en(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(n);this.bump()}return Vt.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===t||"selectordinal"===t)||125===n&&e>0?null:(this.bump(),Vt(n))},e.prototype.parseArgument=function(e,t){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(tt.EMPTY_ARGUMENT,Dt(n,this.clonePosition()));var r=this.parseIdentifierIfPossible().value;if(!r)return this.error(tt.MALFORMED_ARGUMENT,Dt(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:nt.argument,value:r,location:Dt(n,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition())):this.parseArgumentOptions(e,t,r,n);default:return this.error(tt.MALFORMED_ARGUMENT,Dt(n,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=Ft(this.message,t),r=t+n.length;return this.bumpTo(r),{value:n,location:Dt(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,r){var i,o=this.clonePosition(),a=this.parseIdentifierIfPossible().value,s=this.clonePosition();switch(a){case"":return this.error(tt.EXPECT_ARGUMENT_TYPE,Dt(o,s));case"number":case"date":case"time":this.bumpSpace();var u=null;if(this.bumpIf(",")){this.bumpSpace();var c=this.clonePosition();if((m=this.parseSimpleArgStyleIfPossible()).err)return m;if(0===(p=Xt(m.val)).length)return this.error(tt.EXPECT_ARGUMENT_STYLE,Dt(this.clonePosition(),this.clonePosition()));u={style:p,styleLocation:Dt(c,this.clonePosition())}}if((y=this.tryParseArgumentClose(r)).err)return y;var l=Dt(r,this.clonePosition());if(u&&Kt(null==u?void 0:u.style,"::",0)){var h=Jt(u.style.slice(2));if("number"===a)return(m=this.parseNumberSkeletonFromString(h,u.styleLocation)).err?m:{val:{type:nt.number,value:n,location:l,style:m.val},err:null};if(0===h.length)return this.error(tt.EXPECT_DATE_TIME_SKELETON,l);var f=h;this.locale&&(f=function(e,t){for(var n="",r=0;r<e.length;r++){var i=e.charAt(r);if("j"===i){for(var o=0;r+1<e.length&&e.charAt(r+1)===i;)o++,r++;var a=1+(1&o),s=o<2?1:3+(o>>1),u=It(t);for("H"!=u&&"k"!=u||(s=0);s-- >0;)n+="a";for(;a-- >0;)n=u+n}else n+="J"===i?"H":i}return n}(h,this.locale));var p={type:rt.dateTime,pattern:f,location:u.styleLocation,parsedOptions:this.shouldParseSkeletons?_t(f):{}};return{val:{type:"date"===a?nt.date:nt.time,value:n,location:l,style:p},err:null}}return{val:{type:"number"===a?nt.number:"date"===a?nt.date:nt.time,value:n,location:l,style:null!==(i=null==u?void 0:u.style)&&void 0!==i?i:null},err:null};case"plural":case"selectordinal":case"select":var d=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(tt.EXPECT_SELECT_ARGUMENT_OPTIONS,Dt(d,it({},d)));this.bumpSpace();var g=this.parseIdentifierIfPossible(),v=0;if("select"!==a&&"offset"===g.value){if(!this.bumpIf(":"))return this.error(tt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,Dt(this.clonePosition(),this.clonePosition()));var m;if(this.bumpSpace(),(m=this.tryParseDecimalInteger(tt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,tt.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return m;this.bumpSpace(),g=this.parseIdentifierIfPossible(),v=m.val}var y,_=this.tryParsePluralOrSelectOptions(e,a,t,g);if(_.err)return _;if((y=this.tryParseArgumentClose(r)).err)return y;var b=Dt(r,this.clonePosition());return"select"===a?{val:{type:nt.select,value:n,options:Wt(_.val),location:b},err:null}:{val:{type:nt.plural,value:n,options:Wt(_.val),offset:v,pluralType:"plural"===a?"cardinal":"ordinal",location:b},err:null};default:return this.error(tt.INVALID_ARGUMENT_TYPE,Dt(o,s))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();)switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(tt.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,Dt(n,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var n=[];try{n=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],n=0,r=e.split(bt).filter((function(e){return e.length>0}));n<r.length;n++){var i=r[n].split("/");if(0===i.length)throw new Error("Invalid number skeleton");for(var o=i[0],a=i.slice(1),s=0,u=a;s<u.length;s++)if(0===u[s].length)throw new Error("Invalid number skeleton");t.push({stem:o,options:a})}return t}(e)}catch(e){return this.error(tt.INVALID_NUMBER_SKELETON,t)}return{val:{type:rt.number,tokens:n,location:t,parsedOptions:this.shouldParseSkeletons?Lt(n):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,n,r){for(var i,o=!1,a=[],s=new Set,u=r.value,c=r.location;;){if(0===u.length){var l=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var h=this.tryParseDecimalInteger(tt.EXPECT_PLURAL_ARGUMENT_SELECTOR,tt.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;c=Dt(l,this.clonePosition()),u=this.message.slice(l.offset,this.offset())}if(s.has(u))return this.error("select"===t?tt.DUPLICATE_SELECT_ARGUMENT_SELECTOR:tt.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,c);"other"===u&&(o=!0),this.bumpSpace();var f=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?tt.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:tt.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,Dt(this.clonePosition(),this.clonePosition()));var p=this.parseMessage(e+1,t,n);if(p.err)return p;var d=this.tryParseArgumentClose(f);if(d.err)return d;a.push([u,{value:p.val,location:Dt(f,this.clonePosition())}]),s.add(u),this.bumpSpace(),u=(i=this.parseIdentifierIfPossible()).value,c=i.location}return 0===a.length?this.error("select"===t?tt.EXPECT_SELECT_ARGUMENT_SELECTOR:tt.EXPECT_PLURAL_ARGUMENT_SELECTOR,Dt(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(tt.MISSING_OTHER_CLAUSE,Dt(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var n=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var i=!1,o=0;!this.isEOF();){var a=this.char();if(!(a>=48&&a<=57))break;i=!0,o=10*o+(a-48),this.bump()}var s=Dt(r,this.clonePosition());return i?Yt(o*=n)?{val:o,err:null}:this.error(t,s):this.error(e,s)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=qt(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if(Kt(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),n=this.message.indexOf(e,t);return n>=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&tn(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),n=this.message.charCodeAt(t+(e>=65536?2:1));return null!=n?n:null},e}();function en(e){return e>=97&&e<=122||e>=65&&e<=90}function tn(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function nn(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function rn(e,t){void 0===t&&(t={}),t=it({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new $t(e,t).parse();if(n.err){var r=SyntaxError(tt[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return(null==t?void 0:t.captureLocation)||function e(t){t.forEach((function(t){if(delete t.location,ht(t)||ft(t))for(var n in t.options)delete t.options[n].location,e(t.options[n].value);else ut(t)&&gt(t.style)||(ct(t)||lt(t))&&vt(t.style)?delete t.style.location:dt(t)&&e(t.children)}))}(n.val),n.val}function on(e,t){var n=t&&t.cache?t.cache:pn,r=t&&t.serializer?t.serializer:ln;return(t&&t.strategy?t.strategy:cn)(e,{cache:n,serializer:r})}function an(e,t,n,r){var i=function(e){return null==e||"number"==typeof e||"boolean"==typeof e}(r)?r:n(r),o=t.get(i);return void 0===o&&(o=e.call(this,r),t.set(i,o)),o}function sn(e,t,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),o=t.get(i);return void 0===o&&(o=e.apply(this,r),t.set(i,o)),o}function un(e,t,n,r,i){return n.bind(t,e,r,i)}function cn(e,t){return un(e,this,1===e.length?an:sn,t.cache.create(),t.serializer)}var ln=function(){return JSON.stringify(arguments)};function hn(){this.cache=Object.create(null)}hn.prototype.get=function(e){return this.cache[e]},hn.prototype.set=function(e,t){this.cache[e]=t};var fn,pn={create:function(){return new hn}},dn={variadic:function(e,t){return un(e,this,sn,t.cache.create(),t.serializer)},monadic:function(e,t){return un(e,this,an,t.cache.create(),t.serializer)}};!function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"}(fn||(fn={}));var gn,vn=function(e){function t(t,n,r){var i=e.call(this,t)||this;return i.code=n,i.originalMessage=r,i}return et(t,e),t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),mn=function(e){function t(t,n,r,i){return e.call(this,'Invalid values for "'.concat(t,'": "').concat(n,'". Options are "').concat(Object.keys(r).join('", "'),'"'),fn.INVALID_VALUE,i)||this}return et(t,e),t}(vn),yn=function(e){function t(t,n,r){return e.call(this,'Value for "'.concat(t,'" must be of type ').concat(n),fn.INVALID_VALUE,r)||this}return et(t,e),t}(vn),_n=function(e){function t(t,n){return e.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(n,'"'),fn.MISSING_VALUE,n)||this}return et(t,e),t}(vn);function bn(e){return"function"==typeof e}function En(e,t,n,r,i,o,a){if(1===e.length&&at(e[0]))return[{type:gn.literal,value:e[0].value}];for(var s=[],u=0,c=e;u<c.length;u++){var l=c[u];if(at(l))s.push({type:gn.literal,value:l.value});else if(pt(l))"number"==typeof o&&s.push({type:gn.literal,value:n.getNumberFormat(t).format(o)});else{var h=l.value;if(!i||!(h in i))throw new _n(h,a);var f=i[h];if(st(l))f&&"string"!=typeof f&&"number"!=typeof f||(f="string"==typeof f||"number"==typeof f?String(f):""),s.push({type:"string"==typeof f?gn.literal:gn.object,value:f});else if(ct(l)){var p="string"==typeof l.style?r.date[l.style]:vt(l.style)?l.style.parsedOptions:void 0;s.push({type:gn.literal,value:n.getDateTimeFormat(t,p).format(f)})}else if(lt(l))p="string"==typeof l.style?r.time[l.style]:vt(l.style)?l.style.parsedOptions:r.time.medium,s.push({type:gn.literal,value:n.getDateTimeFormat(t,p).format(f)});else if(ut(l))(p="string"==typeof l.style?r.number[l.style]:gt(l.style)?l.style.parsedOptions:void 0)&&p.scale&&(f*=p.scale||1),s.push({type:gn.literal,value:n.getNumberFormat(t,p).format(f)});else{if(dt(l)){var d=l.children,g=l.value,v=i[g];if(!bn(v))throw new yn(g,"function",a);var m=v(En(d,t,n,r,i,o).map((function(e){return e.value})));Array.isArray(m)||(m=[m]),s.push.apply(s,m.map((function(e){return{type:"string"==typeof e?gn.literal:gn.object,value:e}})))}if(ht(l)){if(!(y=l.options[f]||l.options.other))throw new mn(l.value,f,Object.keys(l.options),a);s.push.apply(s,En(y.value,t,n,r,i))}else if(ft(l)){var y;if(!(y=l.options["=".concat(f)])){if(!Intl.PluralRules)throw new vn('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',fn.MISSING_INTL_API,a);var _=n.getPluralRules(t,{type:l.pluralType}).select(f-(l.offset||0));y=l.options[_]||l.options.other}if(!y)throw new mn(l.value,f,Object.keys(l.options),a);s.push.apply(s,En(y.value,t,n,r,i,f-(l.offset||0)))}}}}return function(e){return e.length<2?e:e.reduce((function(e,t){var n=e[e.length-1];return n&&n.type===gn.literal&&t.type===gn.literal?n.value+=t.value:e.push(t),e}),[])}(s)}function wn(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}!function(e){e[e.literal=0]="literal",e[e.object=1]="object"}(gn||(gn={}));var Sn=function(){function e(t,n,r,i){void 0===n&&(n=e.defaultLocale);var o,a=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(e){var t=a.formatToParts(e);if(1===t.length)return t[0].value;var n=t.reduce((function(e,t){return e.length&&t.type===gn.literal&&"string"==typeof e[e.length-1]?e[e.length-1]+=t.value:e.push(t.value),e}),[]);return n.length<=1?n[0]||"":n},this.formatToParts=function(e){return En(a.ast,a.locales,a.formatters,a.formats,e,void 0,a.message)},this.resolvedOptions=function(){var e;return{locale:(null===(e=a.resolvedLocale)||void 0===e?void 0:e.toString())||Intl.NumberFormat.supportedLocalesOf(a.locales)[0]}},this.getAst=function(){return a.ast},this.locales=n,this.resolvedLocale=e.resolveLocale(n),"string"==typeof t){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var s=i||{},u=(s.formatters,function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}(s,["formatters"]));this.ast=e.__parse(t,it(it({},u),{locale:this.resolvedLocale}))}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=function(e,t){return t?Object.keys(e).reduce((function(n,r){var i,o;return n[r]=(i=e[r],(o=t[r])?it(it(it({},i||{}),o||{}),Object.keys(i).reduce((function(e,t){return e[t]=it(it({},i[t]),o[t]||{}),e}),{})):i),n}),it({},e)):e}(e.formats,r),this.formatters=i&&i.formatters||(void 0===(o=this.formatterCache)&&(o={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:on((function(){for(var e,t=arguments,n=[],r=0;r<arguments.length;r++)n[r]=t[r];return new((e=Intl.NumberFormat).bind.apply(e,ot([void 0],n,!1)))}),{cache:wn(o.number),strategy:dn.variadic}),getDateTimeFormat:on((function(){for(var e,t=arguments,n=[],r=0;r<arguments.length;r++)n[r]=t[r];return new((e=Intl.DateTimeFormat).bind.apply(e,ot([void 0],n,!1)))}),{cache:wn(o.dateTime),strategy:dn.variadic}),getPluralRules:on((function(){for(var e,t=arguments,n=[],r=0;r<arguments.length;r++)n[r]=t[r];return new((e=Intl.PluralRules).bind.apply(e,ot([void 0],n,!1)))}),{cache:wn(o.pluralRules),strategy:dn.variadic})})}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=(new Intl.NumberFormat).resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.resolveLocale=function(e){if(void 0!==Intl.Locale){var t=Intl.NumberFormat.supportedLocalesOf(e);return t.length>0?new Intl.Locale(t[0]):new Intl.Locale("string"==typeof e?e:e[0])}},e.__parse=rn,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}();function An(e){for(var t=arguments,n=1;n<arguments.length;n++){var r=t[n];for(var i in r)e[i]=r[i]}return e}var Tn=function e(t,n){function r(e,r,i){if("undefined"!=typeof document){"number"==typeof(i=An({},n,i)).expires&&(i.expires=new Date(Date.now()+864e5*i.expires)),i.expires&&(i.expires=i.expires.toUTCString()),e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var o="";for(var a in i)i[a]&&(o+="; "+a,!0!==i[a]&&(o+="="+i[a].split(";")[0]));return document.cookie=e+"="+t.write(r,e)+o}}return Object.create({set:r,get:function(e){if("undefined"!=typeof document&&(!arguments.length||e)){for(var n=document.cookie?document.cookie.split("; "):[],r={},i=0;i<n.length;i++){var o=n[i].split("="),a=o.slice(1).join("=");try{var s=decodeURIComponent(o[0]);if(r[s]=t.read(a,s),e===s)break}catch(e){}}return e?r[e]:r}},remove:function(e,t){r(e,"",An({},t,{expires:-1}))},withAttributes:function(t){return e(this.converter,An({},this.attributes,t))},withConverter:function(t){return e(An({},this.converter,t),this.attributes)}},{attributes:{value:Object.freeze(n)},converter:{value:Object.freeze(t)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"}),Pn=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];console.warn.apply(console,e)},Rn=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];console.error.apply(console,e)},kn=function(){return"object"==("undefined"==typeof ac?"undefined":k()(ac))&&"function"==typeof ac.call},Ln=function(){return"undefined"!=typeof my&&void 0!==my.canIUse&&!kn()},Nn=function(){return"object"==("undefined"==typeof window?"undefined":k()(window))},On=function(){return function(){var e;return!!Nn()&&((null===(e=window.navigator)||void 0===e?void 0:e.userAgent)||"").toLowerCase().indexOf("alipayclient")>-1}()||Nn()&&"undefined"!=typeof AlipayJSBridge},In=function(){return"undefined"!=typeof wx&&void 0!==wx.canIUse},Cn=function(){return!(void 0===n.g||Nn()||Ln()||In()||kn())},Mn="bailingualLocaleChange",Dn="bailingualDataChange",xn="bailingualError";function Bn(e){void 0===e&&(e="");for(var t=(function(e){if("object"==("undefined"==typeof document?"undefined":k()(document)))try{return Tn.get(e)||Tn.get("_CHIPS-"+e)}catch(e){return Pn("[bailingual-sdk-glue] readCookie fail: "+e),""}}(e)||"").split("&"),n=0,r=t.length;n<r;n++){var i=t[n].split("="),o=i[0],a=i[1];if("lang"===o)return a}}var Un,Hn=function(e){if(void 0===e&&(e=""),e=e.replace("_","-"),On()||Ln()||kn()){var t=Ee[e.toLowerCase()];t&&(e=t)}var n=e.split("-"),r=n[0],i=n[1];return i&&(e=r.toLowerCase()+"-"+i.toUpperCase()),be[e.toLowerCase()]&&(e=be[e.toLowerCase()]),er(Ze,e)?e:""};function jn(e){return void 0===e&&(e=!0),Hn(function(e){return void 0===e&&(e=!0),Ln()||kn()?my.env&&my.env.language||my.getSystemInfoSync().language:In()?wx.getSystemInfoSync().language:Cn()?n.g.BAILINGUAL_LOCALE:!!e&&function(){var e=Bn("x-hng")||Bn("hng");if(e)return e}()||function(){var e;if("object"==("undefined"==typeof document?"undefined":k()(document))){var t=null===(e=document.documentElement)||void 0===e?void 0:e.lang;if(t)return t}}()||function(){var e;if(Nn()){var t=(null===(e=window.navigator)||void 0===e?void 0:e.userAgent)||"",n=(/Language\/([^\s]*)/i.exec(t)||[]).pop();if(n)return n}}()||function(){var e;if(Nn()&&window.navigator){var t=window.navigator,n=(null===(e=t.languages)||void 0===e?void 0:e[0])||t.language||t.userLanguage||t.browserLanguage;if(n)return n}}()}(e)||"")}function zn(e,t,n){void 0===n&&(n={});try{"object"==("undefined"==typeof document?"undefined":k()(document))&&Tn.set(e,t,n)}catch(e){Pn("[bailingual-sdk-glue] writeCookie fail: "+e)}}function Yn(e,t){void 0===t&&(t={});try{"object"==("undefined"==typeof document?"undefined":k()(document))&&Tn.remove(e,t)}catch(e){Pn("[bailingual-sdk-glue] writeCookie fail: "+e)}}function Gn(){"object"==("undefined"==typeof document?"undefined":k()(document))&&"object"==("undefined"==typeof location?"undefined":k()(location))&&(Yn("x-hng",{path:"/",domain:location.hostname}),Yn("x-hng",{path:"/",domain:location.hostname,SameSite:"None",Secure:!0}),Yn("_CHIPS-x-hng",{path:"/",domain:location.hostname,SameSite:"None",Secure:!0,Partitioned:!0}),Yn("x-hng",{path:"/"}),Yn("x-hng",{path:"/",SameSite:"None",Secure:!0}),Yn("_CHIPS-x-hng",{path:"/",SameSite:"None",Secure:!0,Partitioned:!0}))}!function(e){e.FORMAT_ERROR="FORMAT_ERROR",e.MISSING_PARAM="MISSING_PARAM"}(Un||(Un={}));var Fn,Kn,Vn,Wn,qn,Jn,Xn,Zn,Qn=function(e){var t=e.code,n=e.message,r=e.err,i=e.textKey;this.code=t,this.message=n||(null==r?void 0:r.message)||"unknown error",this.stack=(null==r?void 0:r.stack)||r,this.textKey=i},$n=function(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];return t.forEach((function(t){Object.keys(t||{}).forEach((function(n){e[n]=t[n]}))})),e},er=function(e,t){return e.indexOf(t)>-1};function tr(e){var t,n;try{return Kn?(null===(t=Kn.getItem)||void 0===t?void 0:t.call(Kn,e))||"":Ln()||kn()?(null===(n=my.getStorageSync({key:e}))||void 0===n?void 0:n.data)||"":In()?wx.getStorageSync(e)||"":"object"==("undefined"==typeof localStorage?"undefined":k()(localStorage))&&localStorage.getItem(e)||""}catch(e){return""}}function nr(e,t){var n;try{if(t=(t||"").toString(),Kn)return void(null===(n=Kn.setItem)||void 0===n||n.call(Kn,e,t));if(Ln()||kn())return void my.setStorage({key:e,data:t});if(In())return void wx.setStorage({key:e,data:t});"object"==("undefined"==typeof localStorage?"undefined":k()(localStorage))&&localStorage.setItem(e,t)}catch(e){}}function rr(e,t){return void 0===t&&(t=3),new Promise((function(n,r){var i,o,a,s;function u(){var e=s()[0];return e++,c.bind(this,e)}function c(e){if(s=function(){return[e]},!(e<t))return[1];var i=function(e){try{return u}catch(e){return r(e)}};try{var a;return o().then((function(e){try{return(a=e)?n(a):function(){try{return u}catch(e){return r(e)}}()}catch(e){return i()}}),i)}catch(e){i()}}return i=function(e){if(e.length&&"{"!==e[0]){var t=e.indexOf("{");t>-1&&(e=e.slice(t))}return e},o=function(){return new Promise((function(t,n){var r;return function(e){return Fn?Fn(e):kn()?new Promise((function(t,n){my.request({url:e,success:function(e){t(e.data)},fail:function(){n()}})})):Ln()?new Promise((function(t,n){my.call("httpRequest",{url:e},(function(e){!e||e.error?n():t(e.data)}))})):In()?new Promise((function(t,n){wx.request({url:e,dataType:"text",success:function(e){t(e.data)},fail:function(e){n(e)}})})):"function"==typeof fetch?fetch(e).then((function(e){return e.text()})):"undefined"!=typeof XMLHttpRequest?new Promise((function(t,n){var r=new XMLHttpRequest;r.open("GET",e,!0),r.onreadystatechange=function(){4===r.readyState&&(200===r.status?t(r.responseText):n())},r.send()})):void 0}(e).then((function(e){try{return r=e,t(JSON.parse(i(r||"")))}catch(e){return n(e)}}),n)}))},(a=function(e){for(;e;){if(e.then)return void e.then(a,r);try{if(e.pop){if(e.length)return e.pop()?l.call(this):e;e=u}else e=e.call(this)}catch(e){return r(e)}}}.bind(this))(c.bind(this,0));function l(){return n()}}))}!function(e){e.DAILY="DAILY",e.PROD="PROD"}(Xn||(Xn={})),function(e){e.INTERNET="INTERNET",e.INTRANET="INTRANET"}(Zn||(Zn={}));var ir={ANTINTL:(Vn={},Vn[Xn.DAILY]="https://bailingual-daily.marmot-cloud.com/manifest/",Vn[Xn.PROD]="https://bailingual.marmot-cloud.com/manifest/",Vn),ALIPAY:(Wn={},Wn[Xn.DAILY]="https://bailingual-assets-daily.alipay.com/manifest/",Wn[Xn.PROD]="https://bailingual-assets.alipay.com/manifest/",Wn)},or={};or[Zn.INTERNET]=((qn={})[Xn.DAILY]=function(e,t,n){var r;return""+(n?null===(r=ir[n])||void 0===r?void 0:r[Xn.DAILY]:"")+e+"/"+e+(t?"_"+t:"")+".json"},qn[Xn.PROD]=function(e,t,n){var r;return""+(n?null===(r=ir[n])||void 0===r?void 0:r[Xn.PROD]:"")+e+"/"+e+(t?"_"+t:"")+".json"},qn),or[Zn.INTRANET]=((Jn={})[Xn.DAILY]=function(e,t){return"https://bailingual-assets.antgroup-inc.cn/daily/manifest/"+e+"/"+e+(t?"_"+t:"")+".json"},Jn[Xn.PROD]=function(e,t){return"https://bailingual-assets.antgroup-inc.cn/prod/manifest/"+e+"/"+e+(t?"_"+t:"")+".json"},Jn);var ar;function sr(){return"true"===tr("__BAILINGUAL_IN_CONTEXT__")}function ur(){if(!(Ln()||In()||kn())){var e=tr("BAILINGUAL_IN_CONTEXT_CONFIG")||"{}",t=!1;try{t=JSON.parse(e).enableExtension}catch(e){Pn("[bailingual-sdk-glue] JSON.parse data fail: "+e)}ar=sr()&&t}}function cr(){return void 0===ar&&ur(),ar}function lr(){nr("__BAILINGUAL_IN_CONTEXT__","true"),ur(),new Promise((function(e,t){if(Ln()||In()||kn())return e();var n;if("undefined"!=typeof document&&!document.querySelector("._BAILINGUAL_IN_CONTEXT_script"))return rr("https://render.alipay.com/p/yuyan/bailingual-in-context_bailingual-in-context-version/zh_CN.json").then(function(e){try{return(null==(n=e)?void 0:n.version)&&function(e){if(e&&!document.querySelector("._BAILINGUAL_IN_CONTEXT_script")){var t=document.createElement("script");t.setAttribute("class","_BAILINGUAL_IN_CONTEXT_script"),t.setAttribute("src",e),document.body.appendChild(t)}}("https://unpkg.alipay.com/@alipay/bailingual-in-context@"+n.version+"/public/dist/index.js"),r.call(this)}catch(e){return t(e)}}.bind(this),t);function r(){return e()}return r.call(this)}))}function hr(e,t,n){return"##@@@"+t+"##"+e+"@@@##"+n+"@@@##"}function fr(e){var t=[];return e.forEach((function(e){var n=e.key,r=e.count;if(n&&r){var i=-1!==n.indexOf("&")?encodeURIComponent(n):n;t.push(i+"&"+r)}})),t.join(";")}function pr(e,t){var n=function(e){switch(e){case"CN":default:return"https://collect.alipay.com/yuyan/?biztype=yuyanmonitorl";case"SG":return"https://imdap-sea.alipay.com/loggw/dwcookieLogGet.do";case"US":return"https://imdap.alipay.com/loggw/dwcookieLogGet.do"}}(e);if(kn())my.request({method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:t,url:n});else if(Ln())my.call("httpRequest",{url:n,method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:t});else if(In())wx.request({url:n,method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:t});else if("undefined"!=typeof navigator&&"function"==typeof navigator.sendBeacon&&"function"==typeof Blob){var r=new Blob([t],{type:"application/x-www-form-urlencoded"});navigator.sendBeacon(n,r)}else if(Nn()&&"undefined"!=typeof XMLHttpRequest){var i=new XMLHttpRequest;i.open("POST",n,!0),i.setRequestHeader("Content-type","application/x-www-form-urlencoded"),i.send(t)}else"function"==typeof fetch?fetch(n,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:t}):console.error("No supported method to send data",e,t)}!function(){if(!(Ln()||In()||kn()))try{var e=function(e){if(!e)return{};var t={};return e.slice(1).split("&").forEach((function(e){var n=e.split("="),r=n[0],i=n[1];t[r]=i})),t}("undefined"!=typeof location?location.search:"");if(sr()||e.hasOwnProperty("SML_DEV")||e.hasOwnProperty("BAILINGUAL_IN_CONTEXT")||e.hasOwnProperty("BLG_RIC"))return void lr();if("undefined"==typeof document)return;if(On()){var t=0,n=0;document.addEventListener("titleClick",(function(){if(!cr()){if(7==++n)return lr(),n=0,clearTimeout(t),void(t=null);clearTimeout(t),t=setTimeout((function(){n=0,t=null}),1500)}}))}document.addEventListener("__BAILINGUAL_IN_CONTEXT_DISABLE__",(function(){nr("__BAILINGUAL_IN_CONTEXT__","false"),ur()}))}catch(e){Pn("[bailingual-sdk-glue] initBailingualInContext fail: "+e)}}();var dr=function(e){return e<10?"0"+e:""+e};function gr(){var e=new Date;return e.getFullYear()+"-"+dr(e.getMonth()+1)+"-"+dr(e.getDate())+" "+dr(e.getHours())+":"+dr(e.getMinutes())+":"+dr(e.getSeconds())+":"+e.getMilliseconds()}function vr(e,t){void 0===t&&(t="^");var n=[];if(e instanceof Array)n=e;else if(e instanceof Object)for(var r in e)e.hasOwnProperty(r)&&n.push(r+"="+(e[r]||""));return n.join(t)}function mr(e,t){var n,r,i;if(!t||!t.appName||!t.keyCounts.length)return"";var o=[];switch(e){case"CN":default:o=["D-AE",gr(),"","","2","","","","1000","102023","H5behavior","2","","","","","","","","","","","","","","","","","","","","","","","","",vr({code:"1000",msg:"",d1:t.appName,d3:(null===(n=t.textLocale)||void 0===n?void 0:n.replace(/-/g,"_"))||"",d4:t.sdkName||"",d5:t.sdkVersion||"",env:t.env||"PROD",c1:fr(t.keyCounts),sampleRate:"1",yuyan_id:"180020010101313281",fullURL:"-",s_c:"true"})];break;case"SG":o=["D-AE",gr(),"","","2","","","","1000","bailingualTextUsage","H5behavior","2","","","","","","","","","","","","","","","","","","","","","","","","",vr({code:"1000",msg:"",d1:t.appName,d3:(null===(r=t.textLocale)||void 0===r?void 0:r.replace(/-/g,"_"))||"",d4:t.sdkName||"",d5:t.sdkVersion||"",env:t.env||"PROD",c1:fr(t.keyCounts)})];break;case"US":o=["D-VM",gr(),"","","4","-","-","-","exposure","-","-","-","-","-","-","bailingualTextUsage","2","H5behavior","c","-","-","-",vr({appName:t.appName,textLocale:(null===(i=t.textLocale)||void 0===i?void 0:i.replace(/-/g,"_"))||"",sdkName:t.sdkName||"",sdkVersion:t.sdkVersion||"",env:t.env||"PROD",c1:fr(t.keyCounts)}),"-","-","-","-","-","-","-","-","-","1000","-","-","UNKNOWN","-","-","zh-cn","-","-","-","-","-","-","-","-",Date.now().toString()+"-"+(100*Math.random()).toFixed(0),"-","-"]}return"data="+function(e){return e?encodeURIComponent(e).replace(/'/g,"%27"):e}(o.join())+"&time="+(new Date).getTime()}var yr=function(e){var t=e.region;this.queue=[],this.region=t,this.startTimer()};yr.prototype.startTimer=function(){var e,t,n=this;this.region?(this.timer=setTimeout((function(){n._report()}),5e3),Nn()&&(null===(t=null===(e=window.document)||void 0===e?void 0:e.addEventListener)||void 0===t||t.call(e,"beforeunload",(function(){n._report()})))):clearTimeout(this.timer)},yr.prototype._report=function(){if(clearTimeout(this.timer),this.region&&this.queue.length){var e=new Map;this.queue.forEach((function(t){var n=t.appName+"-"+t.textKey+"-"+t.env,r=e.get(n);r?r.textUsedCount+=t.textUsedCount:e.set(n,t)}));var t=Array.from(e.values());!function(e,t){if(!e)throw new Error("No Region");if(0!==t.length)try{var n=new Map;t.forEach((function(e){var t=e.appName+"-"+e.textLocale+"-"+e.env;n.has(t)||n.set(t,{appName:e.appName,textLocale:e.textLocale,sdkName:e.sdkName,sdkVersion:e.sdkVersion,env:e.env,keyCounts:[]}),n.get(t).keyCounts.push({key:e.textKey,count:e.textUsedCount})})),n.forEach((function(t){for(var n=t.keyCounts,r=0;r<n.length;r+=200){var i=n.slice(r,r+200),o=mr(e,{appName:t.appName,textLocale:t.textLocale,sdkName:t.sdkName,sdkVersion:t.sdkVersion,env:t.env,keyCounts:i});pr(e,o)}}))}catch(n){console.error("reportUsageRequest error with",e,t)}else console.error("empty data")}(this.region,t),this.queue=[]}this.startTimer()},yr.prototype.getRegion=function(){return this.region},yr.prototype.setRegion=function(e){this.region=e,this.startTimer()},yr.prototype.report=function(e){this.region&&this.queue.push(e)};var _r=function(){this.originStrings={},this.availableLocales=[],this.langPkgsNoPatch={},this.i18nText={},this.eventHandler={},this.intlMessages={},this.intlPDKVMessages={},this.appName="",this.canUsePatchedData=!0,this.canStoreCurrentLocaleToCookie=!0,this.canReadLocaleFromCookie=!0},br={usageReportRegion:{configurable:!0}};_r.setCustomizedGetSystemLocale=function(e){this.customizedGetSystemLocale=e},_r.customizeGetSystemLocale=function(e){this.customizedGetSystemLocale=e},_r.customizeStorage=function(e){return function(e){Kn=e}(e)},_r.getDataFromStorage=function(e){return tr(e)},_r.setDataToStorage=function(e,t){return nr(e,t)},_r.customizeFetch=function(e){Fn=e},br.usageReportRegion.get=function(){var e;return null===(e=this.usageReporter)||void 0===e?void 0:e.getRegion()},br.usageReportRegion.set=function(e){var t;this.usageReporter||(this.usageReporter=new yr({region:e})),e&&(null===(t=this.usageReporter)||void 0===t||t.setRegion(e))},_r.prototype.init=function(e,t){var n,r;this.initBailingualData(e),this.changeLocale(t||(null===(r=(n=this.constructor).customizedGetSystemLocale)||void 0===r?void 0:r.call(n))||jn(this.canReadLocaleFromCookie))},_r.prototype.getPatchI18nKey=function(){return this.appName?this.tag?this.appName+"+"+this.tag:this.appName:""},_r.prototype.initData=function(e){var t,n;this.initBailingualData(e||this.getServerSideFallbackData()),this.changeLocale((null===(n=(t=this.constructor).customizedGetSystemLocale)||void 0===n?void 0:n.call(t))||jn(this.canReadLocaleFromCookie))},_r.prototype.getServerSideFallbackData=function(){if(Cn()){var e=n.g.BAILINGUAL_FALLBACK;return e||(Pn("[bailingual-sdk-glue] [Server] no fallback data found."),e={}),e}},_r.prototype.initBailingualData=function(e){var t=this;this.originStrings=e,this.availableLocales=[],this.langPkgsNoPatch={},this.i18nText={},this.eventHandler={},this.intlMessages={},this.intlPDKVMessages={},this.appName=e.appName||"",this.currentLocale=void 0,this.bizEnv=e.bizEnv,this.usageReportRegion=e.usageReportRegion,this.usageReporter=new yr({region:this.usageReportRegion}),this.tag=e.tag||"",Object.keys(e).forEach((function(n){if("object"==k()(e[n])){var r=Hn(n);if(!r)return void Rn("[bailingual-sdk-glue] "+n+" is not a valid locale code");t.langPkgsNoPatch[r]=$n({},e[n]),t.i18nText[r]=$n({},e[n])}})),this.handlePatchedData(),this.availableLocales=Object.keys(this.i18nText);var n=e.defaultLocale||this.availableLocales[0];!e.defaultLocale&&n&&Pn("[bailingual-sdk-glue] no defaultLocale specified, use first locale code '"+n+"' instead."),this.defaultLocale=this.judgeLocaleCode(n),this.defaultLocale||Rn("[bailingual-sdk-glue] defaultLocale '"+n+"' is invalid.")},_r.prototype.handlePatchedData=function(){var e,t=this,n=this.getPatchI18nKey();if(this.canUsePatchedData){var r=function(e){if(void 0===e&&(e=""),!e)return{};try{var t=tr("BAILINGUAL_PATCH_I18N_DELETED-"+e);return t?JSON.parse(t):{}}catch(e){return Rn("[bailingual-sdk-glue] fail to get local deleted data, error detail: "+e),{}}}(n),i=function(e){if(void 0===e&&(e=""),!e)return{};try{var t=tr("BAILINGUAL_PATCH_I18N-"+e);return t?JSON.parse(t):{}}catch(e){return Rn("[bailingual-sdk-glue] fail to get local patch data, error detail: "+e),{}}}(n);Object.keys(i).forEach((function(e){er(Ze,e)&&(t.i18nText[e]||Pn("[bailingual-sdk-glue] locale '"+e+"' is not exist in init data, but found in patch data."),t.i18nText[e]=t.i18nText[e]||{},$n(t.i18nText[e],i[e]))})),null===(e=r.removedLocales)||void 0===e||e.forEach((function(e){e=Hn(e),er(Ze,e)&&delete t.i18nText[e]})),Object.keys(r.removedKeys||{}).forEach((function(e){if(e=Hn(e),er(Ze,e)){var n=t.i18nText[e],i=r.removedKeys[e];n&&Array.isArray(i)&&i.forEach((function(e){delete n[e]}))}}))}else n&&function(e){if(e)try{nr("BAILINGUAL_PATCH_I18N-"+e,""),nr("BAILINGUAL_PATCH_I18N_DELETED-"+e,"")}catch(e){Rn("[bailingual-sdk-glue] fail to remove local patch data, error detail: "+e)}}(n)},_r.prototype.setLocale=function(e){this.currentLocale!==e&&(this.currentLocale=e,this.canStoreCurrentLocaleToCookie&&function(e){"object"!=("undefined"==typeof document?"undefined":k()(document))||"object"!=("undefined"==typeof location?"undefined":k()(location))||On()||Ln()||kn()||In()||(Gn(),zn("x-hng","lang="+e,{path:"/",expires:180}),zn("_CHIPS-x-hng","lang="+e,{path:"/",expires:180,SameSite:"None",Partitioned:!0,Secure:!0}))}(e),this.emit(Mn,e))},_r.prototype.getIntlMessageWithPDKVFormat=function(e,t,n){var r=t.id;this.intlPDKVMessages[e]=this.intlPDKVMessages[e]||{};var i=this.intlPDKVMessages[e][r];if(!i){var o=n[r];o.match(Qe)||(o=hr(this.appName,r,o)),i=this.createIntlMessageFormat(o,e),this.intlPDKVMessages[e][r]=i}return i},_r.prototype.getIntlMessageWithNormalFormat=function(e,t,n){var r=t.id,i=(null==n?void 0:n[r])||t.dm||t.defaultMessage||"";if(null==n?void 0:n[r]){this.intlMessages[e]=this.intlMessages[e]||{};var o=this.intlMessages[e][r];return o||(o=this.createIntlMessageFormat(i,e),this.intlMessages[e][r]=o),o}return this.createIntlMessageFormat(i,e)},_r.prototype.formatByLocaleCode=function(e,t,n){var r,i=this,o=this.i18nText[n];try{r=cr()&&e.id&&(null==o?void 0:o[e.id])?this.getIntlMessageWithPDKVFormat(n,e,o):this.getIntlMessageWithNormalFormat(n,e,o)}catch(t){var a=(null==o?void 0:o[e.id])||e.dm||e.defaultMessage||"",s="[bailingual-sdk-glue] fail to create IntlMessageFormat instance, return original string: "+a;return Pn(s),Pn("[bailingual-sdk-glue] error detail:",t),this.emit(xn,new Qn({code:Un.FORMAT_ERROR,message:s,err:t,textKey:e.id})),a}if(!r)return"";try{var u=t&&Object.keys(t)||[],c=this.normalizeIntlMessageVariable(r,t);return Object.keys(c).forEach((function(t){er(u,t)||i.emit(xn,new Qn({code:Un.MISSING_PARAM,message:"["+e.id+"] missing param: "+t,textKey:e.id}))})),r.format(c)}catch(n){var l="[bailingual-sdk-glue] format error with key: "+e.id+", value [%s], params: "+t;return Pn(l),Pn("[bailingual-sdk-glue] error detail:",n),this.emit(xn,new Qn({code:Un.FORMAT_ERROR,message:l,err:n,textKey:e.id})),""}},_r.prototype.format=function(e,t,n){void 0===t&&(t={});var r=n;return r&&((r=Hn(r))||Rn("[bailingual-sdk-glue] "+n+" is not a valid locale code, use default locale instead.")),r||(r=this.currentLocale),r||Rn("[bailingual-sdk-glue] no locale code found!"),this.formatByLocaleCode(e,t,r)},_r.prototype.get=function(e,t,n){return"string"==typeof e?(this.reportUsageData({id:e,localeCode:n}),this.format({id:e},t,n)):(this.reportUsageData({id:e.id,localeCode:n}),this.format(e,t,n))},_r.prototype.judgeLocaleCode=function(e){if(void 0===e&&(e=""),e=Hn(e),er(this.availableLocales,e))return e},_r.prototype.changeLocale=function(e){var t=this.judgeLocaleCode(e);t||this.currentLocale||(t=this.defaultLocale),t?this.setLocale(t):Rn("[bailingual-sdk-glue] '"+e+"' is not a vaid locale code")},_r.prototype.unsafeChangeLocale=function(e){void 0===e&&(e=""),this.setLocale(e)},_r.prototype.getAllData=function(e){var t=this;if(this.i18nText&&e&&cr()){var n={};return Object.keys(this.i18nText).forEach((function(e){n[e]=t.buildPDKVLocaleText(t.i18nText[e])})),n}return this.i18nText},_r.prototype.buildPDKVLocaleText=function(e){var t=this,n={};return Object.keys(e||{}).forEach((function(r){var i=e[r];i.match(Qe)||(i=hr(t.appName,r,i)),n[r]=i})),n},_r.prototype.getDataWithLocale=function(e,t){e||Pn("[bailingual-sdk-glue] no locale code specified, use default locale ("+this.defaultLocale+") instead.");var n=this.i18nText[Hn(e||this.defaultLocale)];return n&&t&&cr()?this.buildPDKVLocaleText(n):n},_r.prototype.getDataFromCurrentLocale=function(e){if(this.currentLocale)return this.getDataWithLocale(this.currentLocale,e);Rn("[bailingual-sdk-glue] error occured: no 'currentLocale' found, please check if you have called 'initData' or 'changeLocale' method before.")},_r.prototype.getCurrentLocale=function(){return this.currentLocale||""},_r.prototype.getDefaultLocale=function(){return this.defaultLocale},_r.prototype.formatLocaleCode=function(e){return Hn(e)},_r.prototype.patchI18n=function(e,t){return new Promise(function(n,r){var i,o,a,s;if(!(t=t||{}).isIntranet&&!t.buIdentifier)return Rn('[bailingual-sdk-glue] no "env.buIdentifier" param, patchI18n will not work.'),this.emit(xn,new Qn({code:Un.MISSING_PARAM,message:'[bailingual-sdk-glue] no "env.buIdentifier" param, patchI18n will not work.'})),n();if(!Array.isArray(e)){if(!e.appName){if(!this.appName)return Rn("[bailingual-sdk-glue] no appName found, patchI18n will not work."),n();e.appName=this.appName}e.tag||(e.tag=this.tag),e=[e]}return(e=e.filter((function(e){return!!(null==e?void 0:e.appName)||(Rn("[bailingual-sdk-glue] no appName found, skip: "+e),!1)}))).length?function(e,t,n){return new Promise((function(r,i){return function(e,t){return new Promise((function(n,r){var i,o,a,s;return i=t&&"buIdentifier"in t?t.buIdentifier:void 0,(o=e.map((function(e){return rr(function(e,t,n,r,i){var o,a;return null===(a=null===(o=or[t])||void 0===o?void 0:o[e])||void 0===a?void 0:a.call(o,n,r,i)}(t.isDaily?Xn.DAILY:Xn.PROD,t.isIntranet?Zn.INTRANET:Zn.INTERNET,e.appName,e.tag,i)).then((function(e){return e?rr(e.url):void 0})).then((function(e){return e||{}}))})),a=[],s=0,new Promise((function(e){o.forEach((function(t,n){t.then((function(t){a[n]=t,++s===o.length&&e(a)}))}))}))).then((function(e){try{return n(e)}catch(e){return r(e)}}),r)}))}(t,n).then((function(t){try{return r(function(e,t){var n={};t.forEach((function(e){e=e||{},Object.keys(e).forEach((function(t){if("object"==k()(e[t])){var r=Hn(t);r&&(n[r]=n[r]||{},$n(n[r],e[t]))}}))}));var r=Object.keys(n),i=Object.keys(e);r.sort().toString()!==i.sort().toString()&&Pn("[bailingual-sdk-glue] locales in local data '"+i+"' is different from cdn data '"+r+"'");var o={removedKeys:{},removedLocales:i.filter((function(e){return!er(r,e)}))},a={},s={};return r.forEach((function(t){var r=n[t]||{},i=e[t]||{};a[t]=a[t]||{};var o=a[t];Object.keys(r).forEach((function(e){Object.prototype.hasOwnProperty.call(r,e)&&r[e]!==i[e]&&(o[e]=r[e])})),s[t]=$n({},i,r)})),i.forEach((function(t){if(!er(o.removedLocales,t)){var r=e[t]||{},i=n[t]||{},a=s[t]||{};Object.keys(r).forEach((function(e){Object.prototype.hasOwnProperty.call(i,e)||(delete a[e],o.removedKeys[t]=o.removedKeys[t]||[],er(o.removedKeys[t],e)||o.removedKeys[t].push(e))}))}})),{newI18nData:s,patchedData:a,deletedData:o}}(e,t))}catch(e){return i(e)}}),i)}))}(this.langPkgsNoPatch,e,t).then(function(e){var t;try{return i=(t=e).newI18nData,o=t.patchedData,a=t.deletedData,s=this.getPatchI18nKey(),this.updateData(i)&&s&&(nr("BAILINGUAL_PATCH_I18N-"+s,JSON.stringify(o)),nr("BAILINGUAL_PATCH_I18N_DELETED-"+s,JSON.stringify(a))),n()}catch(e){return r(e)}}.bind(this),r):(Rn("[bailingual-sdk-glue] no bailingual packages found, stop patch"),n())}.bind(this))},_r.prototype.updateData=function(e){var t=Object.keys(e).filter((function(e){return er(Ze,e)}));return this.defaultLocale&&!er(t,this.defaultLocale)?(Rn("[bailingual-sdk-glue] default locale "+this.defaultLocale+" is not exist in new data, can't update data."),!1):(this.i18nText=e,this.intlMessages={},this.intlPDKVMessages={},this.availableLocales=t,this.emit(Dn,e),this.currentLocale&&!er(t,this.currentLocale)&&(Pn("[bailingual-sdk-glue] current locale "+this.currentLocale+" is not available, use default locale ("+this.defaultLocale+") instead."),this.changeLocale(this.defaultLocale)),!0)},_r.prototype.on=function(e,t){this.eventHandler[e]=this.eventHandler[e]||[],this.eventHandler[e].push(t)},_r.prototype.off=function(e,t){var n,r=this;null===(n=this.eventHandler[e])||void 0===n||n.forEach((function(n,i){n===t&&(r.eventHandler[e][i]=null)}))},_r.prototype.onDataChange=function(e){this.on(Dn,e)},_r.prototype.offDataChange=function(e){this.off(Dn,e)},_r.prototype.onLocaleChange=function(e){this.on(Mn,e)},_r.prototype.offLocaleChange=function(e){this.off(Mn,e)},_r.prototype.onError=function(e){this.on(xn,e)},_r.prototype.offError=function(e){this.off(xn,e)},_r.prototype.emit=function(e,t){var n,r;null===(r=null===(n=this.eventHandler[e])||void 0===n?void 0:n.forEach)||void 0===r||r.call(n,(function(e){null==e||e(t)}))},_r.prototype.stopPatchI18n=function(){this.canUsePatchedData=!1},_r.prototype.setAutoStoreCurrentLocaleToCookie=function(e){this.canStoreCurrentLocaleToCookie=!!e},_r.prototype.setAutoReadLocaleFromCookie=function(e){this.canReadLocaleFromCookie=!!e},_r.prototype.getAllLocales=function(){return[].concat(this.availableLocales)},_r.prototype.changeUsageReportRegion=function(e){this.usageReportRegion=e},_r.prototype.changeBizEnv=function(e){this.bizEnv=e},_r.prototype.reportUsageData=function(e){var t=e.id,n=e.count;void 0===n&&(n=1);var r,i=e.localeCode;void 0===i&&(i=this.currentLocale),null===(r=this.usageReporter)||void 0===r||r.report({appName:this.appName,textKey:t,textLocale:i,textUsedCount:n,sdkName:"bailingual-sdk-glue",env:this.bizEnv||"PROD"})},_r.prototype.removeBailingualCookie=function(){Gn()},Object.defineProperties(_r.prototype,br),_r.customizedGetSystemLocale=void 0;var Er=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.normalizeIntlMessageVariable=function(e,t){var n=e.getAst(),r=t||{};return n.forEach((function(e){er([nt.argument,nt.number,nt.date,nt.time,nt.select,nt.plural],e.type)&&"value"in e&&void 0===r[e.value]&&(r[e.value]="")})),r},t.prototype.createIntlMessageFormat=function(e,t){return new Sn(e,t,{},{ignoreTag:!0})},t}(_r),wr=(new Er,"antom-language-storage-key"),Sr="en_US",Ar=new Er;function Tr(e){if(e)return Pr(e);try{var t=window._amsSdkLanguage||window.sessionStorage.getItem(wr)||window.localStorage.getItem(wr);if(t)return Pr(t)}catch(e){}if(navigator.language){var n=!/[-,_]/.test(navigator.language),r=Ar.getAllLocales().find((function(e){return n?e.startsWith(navigator.language):Pr(e)===Pr(navigator.language)}))||Sr;if(r)return r=Pr(r)}return Sr}function Pr(e){var t=e;t||(t=Sr);var n=t.split(/[-,_]/),r=P(n,2),i=r[0],o=r[1];return i||(i="en"),o?"".concat(i.toLowerCase(),"_").concat(o.toUpperCase()):i.toLowerCase()}"true"==={NODE_ENV:"production",PUBLIC_PATH:"/"}.ANTOM_CORE_UNIT_TEST&&Ar.initData(window.bailingual_ckp||{});var Rr={API_MISS_PARAMS:"API_MISS_PARAMS",API_GATEWAY_TIMEOUT:"API_GATEWAY_TIMEOUT",API_SYSTEM_ERROR:"API_SYSTEM_ERROR",API_TIMEOUT:"API_TIMEOUT",API_NOT_LOGIN:"API_NOT_LOGIN",API_GATEWAY_ERROR:"API_GATEWAY_ERROR"},kr=b(b({},{UNKNOWN_ERROR:"UNKNOWN_ERROR",NO_PORTS_ERROR:"NO_PORTS_ERROR",INVALID_REDIRECT_URL:"INVALID_REDIRECT_URL"}),Rr);O.initConfig({i18n:Ar,i18nPrefix:"ANTOMSDK",getDefaultMessage:function(){return Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"})}});var Lr=function(e){d(n,e);var t=v(n);function n(){var e;u(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),y(f(e),"name","AntomError"),y(f(e),"response",void 0),e}return l(n,null,[{key:"isError",value:function(e){return O.isError(e)}},{key:"unificationError",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"APP_RUNTIME";return O.unificationError(e,t)}}]),n}(O),Nr=function(e){d(n,e);var t=v(n);function n(){var e;u(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),y(f(e),"name","AntomCoreError"),e}return l(n)}(Lr),Or=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"defaultRequestScope";return e?{success:function(n,r,i){e.log({code:"11",msg:n,d1:i||"无traceId",d2:t,d3:Math.round(r),d5:"是",m1:1})},error:function(n,r,i,o,a){e.log({code:"11",msg:n,d1:a||"无traceId",d2:t,d3:Math.round(r),d4:"".concat(o,"-").concat(i),d5:"否",m1:0})}}:{success:function(){},error:function(){}}},Ir=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"defaultJsErrorScope";return function(n){e&&e.log({code:"12",msg:(null==n?void 0:n.message)||"上报未知的异常信息",d1:(null==n?void 0:n.stack)||"无stack信息",d2:t})}},Cr=(window||{}).navigator,Mr=Cr.userAgent,Dr=function(){var e=/OpenHarmony/i.test(Cr.userAgent),t=/Phone/i.test(Cr.userAgent),n=/Tablet/i.test(Cr.userAgent);return e&&(t||n)},xr=/iPhone|iPad|iPod/i.test(Mr)||"MacIntel"===Cr.platform&&Cr.maxTouchPoints>1,Br=/Android/i.test(Mr),Ur=(/\bMacintosh\b/.test(Mr),/Windows NT/.test(Mr),function(){return/Android|iPhone|iPad|iPod|Mobile|SymbianOS|Windows Phone/.test(Mr)||Dr()}),Hr=xr,jr=Br,zr=!!Ur(),Yr=!Ur();Dr();var Gr=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];try{if(!e){if(t)throw t;return}return JSON.parse(e)}catch(e){if(t)throw t;return}},Fr=function(e){var t=e.split("&&")[3];if(t){var n=function(e){try{if(!e)return;var t=atob(e),n=Uint8Array.from(t,(function(e){return e.codePointAt(0)}));return(new TextDecoder).decode(n)}catch(e){return}}(t);if(n)return Gr(n)}},Kr=function(e){return(null==e?void 0:e.split("&&").slice(0,2).join("&&"))||"无trackId"},Vr=function(e){return e.split("&&")[1]||"SG"};function Wr(e,t){return function(){return e.apply(t,arguments)}}var qr,Jr,Xr=n(3089),Zr=Object.prototype.toString,Qr=Object.getPrototypeOf,$r=Symbol.iterator,ei=Symbol.toStringTag,ti=(qr=Object.prototype.hasOwnProperty,function(e,t){return qr.call(e,t)}),ni=function(e,t){for(var n=e,r=[];null!=n&&n!==Object.prototype;){if(-1!==r.indexOf(n))return!1;if(r.push(n),ti(n,t))return!0;n=Qr(n)}return!1},ri=(Jr=Object.create(null),function(e){var t=Zr.call(e);return Jr[t]||(Jr[t]=t.slice(8,-1).toLowerCase())}),ii=function(e){return e=e.toLowerCase(),function(t){return ri(t)===e}},oi=function(e){return function(t){return R(t)===e}},ai=Array.isArray,si=oi("undefined");function ui(e){return null!==e&&!si(e)&&null!==e.constructor&&!si(e.constructor)&&hi(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}var ci=ii("ArrayBuffer");var li=oi("string"),hi=oi("function"),fi=oi("number"),pi=function(e){return null!==e&&"object"===R(e)},di=function(e){if(!pi(e))return!1;var t=Qr(e);return!(null!==t&&t!==Object.prototype&&null!==Qr(t)||ni(e,ei)||ni(e,$r))},gi=ii("Date"),vi=ii("File"),mi=ii("Blob"),yi=ii("FileList");var _i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},bi=void 0!==_i.FormData?_i.FormData:void 0,Ei=ii("URLSearchParams"),wi=["ReadableStream","Request","Response","Headers"].map(ii),Si=P(wi,4),Ai=Si[0],Ti=Si[1],Pi=Si[2],Ri=Si[3];function ki(e,t){var n,r,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=i.allOwnKeys,a=void 0!==o&&o;if(null!=e)if("object"!==R(e)&&(e=[e]),ai(e))for(n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else{if(ui(e))return;var s,u=a?Object.getOwnPropertyNames(e):Object.keys(e),c=u.length;for(n=0;n<c;n++)s=u[n],t.call(null,e[s],s,e)}}function Li(e,t){if(ui(e))return null;t=t.toLowerCase();for(var n,r=Object.keys(e),i=r.length;i-- >0;)if(t===(n=r[i]).toLowerCase())return n;return null}var Ni="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,Oi=function(e){return!si(e)&&e!==Ni};var Ii,Ci=(Ii="undefined"!=typeof Uint8Array&&Qr(Uint8Array),function(e){return Ii&&e instanceof Ii}),Mi=ii("HTMLFormElement"),Di=Object.prototype.propertyIsEnumerable,xi=ii("RegExp"),Bi=function(e,t){var n=Object.getOwnPropertyDescriptors(e),r={};ki(n,(function(n,i){var o;!1!==(o=t(n,i,e))&&(r[i]=o||n)})),Object.defineProperties(e,r)};var Ui,Hi,ji,zi,Yi=ii("AsyncFunction"),Gi=(Ui="function"==typeof setImmediate,Hi=hi(Ni.postMessage),Ui?setImmediate:Hi?(ji="axios@".concat(Math.random()),zi=[],Ni.addEventListener("message",(function(e){var t=e.source,n=e.data;t===Ni&&n===ji&&zi.length&&zi.shift()()}),!1),function(e){zi.push(e),Ni.postMessage(ji,"*")}):function(e){return setTimeout(e)}),Fi="undefined"!=typeof queueMicrotask?queueMicrotask.bind(Ni):void 0!==Xr&&Xr.nextTick||Gi,Ki=function(e){return null!=e&&hi(e[$r])},Vi={isArray:ai,isArrayBuffer:ci,isBuffer:ui,isFormData:function(e){if(!e)return!1;if(bi&&e instanceof bi)return!0;var t=Qr(e);if(!t||t===Object.prototype)return!1;if(!hi(e.append))return!1;var n=ri(e);return"formdata"===n||"object"===n&&hi(e.toString)&&"[object FormData]"===e.toString()},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&ci(e.buffer)},isString:li,isNumber:fi,isBoolean:function(e){return!0===e||!1===e},isObject:pi,isPlainObject:di,isEmptyObject:function(e){if(!pi(e)||ui(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(e){return!1}},isReadableStream:Ai,isRequest:Ti,isResponse:Pi,isHeaders:Ri,isUndefined:si,isDate:gi,isFile:vi,isReactNativeBlob:function(e){return!(!e||void 0===e.uri)},isReactNative:function(e){return e&&void 0!==e.getParts},isBlob:mi,isRegExp:xi,isFunction:hi,isStream:function(e){return pi(e)&&hi(e.pipe)},isURLSearchParams:Ei,isTypedArray:Ci,isFileList:yi,forEach:ki,merge:function e(){for(var t=Oi(this)&&this||{},n=t.caseless,r=t.skipUndefined,i={},o=function(t,o){if("__proto__"!==o&&"constructor"!==o&&"prototype"!==o){var a=n&&"string"==typeof o&&Li(i,o)||o,s=ti(i,a)?i[a]:void 0;di(s)&&di(t)?i[a]=e(s,t):di(t)?i[a]=e({},t):ai(t)?i[a]=t.slice():r&&si(t)||(i[a]=t)}},a=0,s=arguments.length;a<s;a++){var u=a<0||arguments.length<=a?void 0:arguments[a];if(u&&!ui(u)&&(ki(u,o),"object"===R(u)&&!ai(u)))for(var c=Object.getOwnPropertySymbols(u),l=0;l<c.length;l++){var h=c[l];Di.call(u,h)&&o(u[h],h)}}return i},extend:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=r.allOwnKeys;return ki(t,(function(t,r){n&&hi(t)?Object.defineProperty(e,r,{__proto__:null,value:Wr(t,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,r,{__proto__:null,value:t,writable:!0,enumerable:!0,configurable:!0})}),{allOwnKeys:i}),e},trim:function(e){return e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e},inherits:function(e,t,n,r){e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:function(e,t,n,r){var i,o,a,s={};if(t=t||{},null==e)return t;do{for(o=(i=Object.getOwnPropertyNames(e)).length;o-- >0;)a=i[o],r&&!r(a,e,t)||s[a]||(t[a]=e[a],s[a]=!0);e=!1!==n&&Qr(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:ri,kindOfTest:ii,endsWith:function(e,t,n){e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;var r=e.indexOf(t,n);return-1!==r&&r===n},toArray:function(e){if(!e)return null;if(ai(e))return e;var t=e.length;if(!fi(t))return null;for(var n=new Array(t);t-- >0;)n[t]=e[t];return n},forEachEntry:function(e,t){for(var n,r=(e&&e[$r]).call(e);(n=r.next())&&!n.done;){var i=n.value;t.call(e,i[0],i[1])}},matchAll:function(e,t){for(var n,r=[];null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:Mi,hasOwnProperty:ti,hasOwnProp:ti,hasOwnInPrototypeChain:ni,getSafeProp:function(e,t){return null!=e&&ni(e,t)?e[t]:void 0},reduceDescriptors:Bi,freezeMethods:function(e){Bi(e,(function(t,n){if(hi(e)&&["arguments","caller","callee"].includes(n))return!1;var r=e[n];hi(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=function(){throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:function(e,t){var n={},r=function(e){e.forEach((function(e){n[e]=!0}))};return ai(e)?r(e):r(String(e).split(t)),n},toCamelCase:function(e){return e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n}))},noop:function(){},toFiniteNumber:function(e,t){return null!=e&&Number.isFinite(e=+e)?e:t},findKey:Li,global:Ni,isContextDefined:Oi,isSpecCompliantForm:function(e){return!!(e&&hi(e.append)&&"FormData"===e[ei]&&e[$r])},toJSONObject:function(e){var t=new WeakSet;return function e(n){if(pi(n)){if(t.has(n))return;if(ui(n))return n;if(!("toJSON"in n)){t.add(n);var r=ai(n)?[]:{};return ki(n,(function(t,n){var i=e(t);!si(i)&&(r[n]=i)})),t.delete(n),r}}return n}(e)},isAsyncFn:Yi,isThenable:function(e){return e&&(pi(e)||hi(e))&&hi(e.then)&&hi(e.catch)},setImmediate:Gi,asap:Fi,isIterable:Ki,isSafeIterable:function(e){return null!=e&&ni(e,$r)&&Ki(e)}},Wi=Vi.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]);var qi=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),Ji=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Xi(e,t){return Vi.isArray(e)?e.map((function(e){return Xi(e,t)})):function(e){for(var t=0,n=e.length;t<n;){var r=e.charCodeAt(t);if(9!==r&&32!==r)break;t+=1}for(;n>t;){var i=e.charCodeAt(n-1);if(9!==i&&32!==i)break;n-=1}return 0===t&&n===e.length?e:e.slice(t,n)}(String(e).replace(t,""))}function Zi(e){var t=Object.create(null);return Vi.forEach(e.toJSON(),(function(e,n){t[n]=function(e){return Xi(e,Ji)}(e)})),t}var Qi=Symbol("internals");function $i(e){return e&&String(e).trim().toLowerCase()}function eo(e){return!1===e||null==e?e:Vi.isArray(e)?e.map(eo):function(e){return Xi(e,qi)}(String(e))}function to(e,t,n,r,i){return Vi.isFunction(r)?r.call(this,t,n):(i&&(t=n),Vi.isString(t)?Vi.isString(r)?-1!==t.indexOf(r):Vi.isRegExp(r)?r.test(t):void 0:void 0)}var no=function(e,t){function n(e){u(this,n),e&&this.set(e)}return l(n,[{key:"set",value:function(e,t,n){var r=this;function i(e,t,n){var i=$i(t);if(i){var o=Vi.findKey(r,i);(!o||void 0===r[o]||!0===n||void 0===n&&!1!==r[o])&&(r[o||t]=eo(e))}}var a=function(e,t){return Vi.forEach(e,(function(e,n){return i(e,n,t)}))};if(Vi.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(Vi.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))a(function(e){var t,n,r,i={};return e&&e.split("\n").forEach((function(e){r=e.indexOf(":"),t=e.substring(0,r).trim().toLowerCase(),n=e.substring(r+1).trim(),!t||i[t]&&Wi[t]||("set-cookie"===t?i[t]?i[t].push(n):i[t]=[n]:i[t]=i[t]?i[t]+", "+n:n)})),i}(e),t);else if(Vi.isObject(e)&&Vi.isSafeIterable(e)){var s,u,c,l=Object.create(null),h=o(e);try{for(h.s();!(c=h.n()).done;){var f=c.value;if(!Vi.isArray(f))throw new TypeError("Object iterator must return a key-value pair");u=f[0],Vi.hasOwnProp(l,u)?(s=l[u],l[u]=Vi.isArray(s)?[].concat(C(s),[f[1]]):[s,f[1]]):l[u]=f[1]}}catch(e){h.e(e)}finally{h.f()}a(l,t)}else null!=e&&i(t,e,n);return this}},{key:"get",value:function(e,t){if(e=$i(e)){var n=Vi.findKey(this,e);if(n){var r=this[n];if(!t)return r;if(!0===t)return function(e){for(var t,n=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;t=r.exec(e);)n[t[1]]=t[2];return n}(r);if(Vi.isFunction(t))return t.call(this,r,n);if(Vi.isRegExp(t))return t.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}},{key:"has",value:function(e,t){if(e=$i(e)){var n=Vi.findKey(this,e);return!(!n||void 0===this[n]||t&&!to(0,this[n],n,t))}return!1}},{key:"delete",value:function(e,t){var n=this,r=!1;function i(e){if(e=$i(e)){var i=Vi.findKey(n,e);!i||t&&!to(0,n[i],i,t)||(delete n[i],r=!0)}}return Vi.isArray(e)?e.forEach(i):i(e),r}},{key:"clear",value:function(e){for(var t=Object.keys(this),n=t.length,r=!1;n--;){var i=t[n];e&&!to(0,this[i],i,e,!0)||(delete this[i],r=!0)}return r}},{key:"normalize",value:function(e){var t=this,n={};return Vi.forEach(this,(function(r,i){var o=Vi.findKey(n,i);if(o)return t[o]=eo(r),void delete t[i];var a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n}))}(i):String(i).trim();a!==i&&delete t[i],t[a]=eo(r),n[a]=!0})),this}},{key:"concat",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=this.constructor).concat.apply(e,[this].concat(n))}},{key:"toJSON",value:function(e){var t=Object.create(null);return Vi.forEach(this,(function(n,r){null!=n&&!1!==n&&(t[r]=e&&Vi.isArray(n)?n.join(", "):n)})),t}},{key:e,value:function(){return Object.entries(this.toJSON())[Symbol.iterator]()}},{key:"toString",value:function(){return Object.entries(this.toJSON()).map((function(e){var t=P(e,2);return t[0]+": "+t[1]})).join("\n")}},{key:"getSetCookie",value:function(){return this.get("set-cookie")||[]}},{key:t,get:function(){return"AxiosHeaders"}}],[{key:"from",value:function(e){return e instanceof this?e:new this(e)}},{key:"concat",value:function(e){for(var t=new this(e),n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return r.forEach((function(e){return t.set(e)})),t}},{key:"accessor",value:function(e){var t=(this[Qi]=this[Qi]={accessors:{}}).accessors,n=this.prototype;function r(e){var r=$i(e);t[r]||(!function(e,t){var n=Vi.toCamelCase(" "+t);["get","set","has"].forEach((function(r){Object.defineProperty(e,r+n,{__proto__:null,value:function(e,n,i){return this[r].call(this,t,e,n,i)},configurable:!0})}))}(n,e),t[r]=!0)}return Vi.isArray(e)?e.forEach(r):r(e),this}}]),n}(Symbol.iterator,Symbol.toStringTag);no.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Vi.reduceDescriptors(no.prototype,(function(e,t){var n=e.value,r=t[0].toUpperCase()+t.slice(1);return{get:function(){return n},set:function(e){this[r]=e}}})),Vi.freezeMethods(no);var ro=no;function io(e,t){var n=new Set(t.map((function(e){return String(e).toLowerCase()}))),r=[];return function e(t){if(null===t||"object"!==R(t))return t;if(Vi.isBuffer(t))return t;if(-1===r.indexOf(t)){var i;if(t instanceof ro&&(t=t.toJSON()),r.push(t),Vi.isArray(t))i=[],t.forEach((function(t,n){var r=e(t);Vi.isUndefined(r)||(i[n]=r)}));else{if(!Vi.isPlainObject(t)&&function(e){if(Vi.hasOwnProp(e,"toJSON"))return!0;for(var t=Object.getPrototypeOf(e);t&&t!==Object.prototype;){if(Vi.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}(t))return r.pop(),t;i=Object.create(null);for(var o=0,a=Object.entries(t);o<a.length;o++){var s=P(a[o],2),u=s[0],c=s[1],l=n.has(u.toLowerCase())?"[REDACTED ****]":e(c);Vi.isUndefined(l)||(i[u]=l)}}return r.pop(),i}}(e)}var oo=function(e){d(n,e);var t=v(n);function n(e,r,i,o,a){var s;return u(this,n),s=t.call(this,e),Object.defineProperty(f(s),"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),s.name="AxiosError",s.isAxiosError=!0,r&&(s.code=r),i&&(s.config=i),o&&(s.request=o),a&&(s.response=a,s.status=a.status),s}return l(n,[{key:"toJSON",value:function(){var e=this.config,t=e&&Vi.hasOwnProp(e,"redact")?e.redact:void 0,n=Vi.isArray(t)&&t.length>0?io(e,t):Vi.toJSONObject(e);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:n,code:this.code,status:this.status}}}],[{key:"from",value:function(e,t,r,i,o,a){var s=new n(e.message,t||e.code,r,i,o);return Object.defineProperty(s,"cause",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),s.name=e.name,null!=e.status&&null==s.status&&(s.status=e.status),a&&Object.assign(s,a),s}}]),n}(L(Error));oo.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",oo.ERR_BAD_OPTION="ERR_BAD_OPTION",oo.ECONNABORTED="ECONNABORTED",oo.ETIMEDOUT="ETIMEDOUT",oo.ECONNREFUSED="ECONNREFUSED",oo.ERR_NETWORK="ERR_NETWORK",oo.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",oo.ERR_DEPRECATED="ERR_DEPRECATED",oo.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",oo.ERR_BAD_REQUEST="ERR_BAD_REQUEST",oo.ERR_CANCELED="ERR_CANCELED",oo.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",oo.ERR_INVALID_URL="ERR_INVALID_URL",oo.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";var ao=oo,so=n(6207).lW;function uo(e){return Vi.isPlainObject(e)||Vi.isArray(e)}function co(e){return Vi.endsWith(e,"[]")?e.slice(0,-2):e}function lo(e,t,n){return e?e.concat(t).map((function(e,t){return e=co(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}var ho=Vi.toFlatObject(Vi,{},null,(function(e){return/^is[A-Z]/.test(e)}));var fo=function(e,t,n){if(!Vi.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;var r=(n=Vi.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!Vi.isUndefined(t[e])}))).metaTokens,i=n.visitor||p,o=n.dots,a=n.indexes,s=n.Blob||"undefined"!=typeof Blob&&Blob,u=void 0===n.maxDepth?100:n.maxDepth,c=s&&Vi.isSpecCompliantForm(t),l=[];if(!Vi.isFunction(i))throw new TypeError("visitor must be a function");function h(e){if(null===e)return"";if(Vi.isDate(e))return e.toISOString();if(Vi.isBoolean(e))return e.toString();if(!c&&Vi.isBlob(e))throw new ao("Blob is not supported. Use a Buffer instead.");if(Vi.isArrayBuffer(e)||Vi.isTypedArray(e)){if(c&&"function"==typeof s)return new s([e]);if(void 0!==so)return so.from(e);throw new ao("Blob is not supported. Use a Buffer instead.",ao.ERR_NOT_SUPPORT)}return e}function f(e){if(e>u)throw new ao("Object is too deeply nested ("+e+" levels). Max depth: "+u,ao.ERR_FORM_DATA_DEPTH_EXCEEDED)}function p(e,n,i){var s=e;if(Vi.isReactNative(t)&&Vi.isReactNativeBlob(e))return t.append(lo(i,n,o),h(e)),!1;if(e&&!i&&"object"===R(e))if(Vi.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=function(e,t){if(u===1/0)return JSON.stringify(e);var n=[];return JSON.stringify(e,(function(e,r){if(!Vi.isObject(r))return r;for(;n.length&&n[n.length-1]!==this;)n.pop();return n.push(r),f(t+n.length-1),r}))}(e,1);else if(Vi.isArray(e)&&function(e){return Vi.isArray(e)&&!e.some(uo)}(e)||(Vi.isFileList(e)||Vi.endsWith(n,"[]"))&&(s=Vi.toArray(e)))return n=co(n),s.forEach((function(e,r){!Vi.isUndefined(e)&&null!==e&&t.append(!0===a?lo([n],r,o):null===a?n:n+"[]",h(e))})),!1;return!!uo(e)||(t.append(lo(i,n,o),h(e)),!1)}var d=Object.assign(ho,{defaultVisitor:p,convertValue:h,isVisitable:uo});if(!Vi.isObject(e))throw new TypeError("data must be an object");return function e(n,r){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(!Vi.isUndefined(n)){if(f(o),-1!==l.indexOf(n))throw new Error("Circular reference detected in "+r.join("."));l.push(n),Vi.forEach(n,(function(n,a){!0===(!(Vi.isUndefined(n)||null===n)&&i.call(t,n,Vi.isString(a)?a.trim():a,r,d))&&e(n,r?r.concat(a):[a],o+1)})),l.pop()}}(e),t};function po(e){var t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,(function(e){return t[e]}))}function go(e,t){this._pairs=[],e&&fo(e,this,t)}var vo=go.prototype;vo.append=function(e,t){this._pairs.push([e,t])},vo.toString=function(e){var t=this,n=e?function(n){return e.call(t,n,po)}:po;return this._pairs.map((function(e){return n(e[0])+"="+n(e[1])}),"").join("&")};var mo=go;function yo(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function _o(e,t,n){if(!t)return e;e=e||"";var r,i=Vi.isFunction(n)?{serialize:n}:n,o=Vi.getSafeProp(i,"encode")||yo,a=Vi.getSafeProp(i,"serialize");if(r=a?a(t,i):Vi.isURLSearchParams(t)?t.toString():new mo(t,i).toString(o)){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+r}return e}var bo=function(){function e(){u(this,e),this.handlers=[]}return l(e,[{key:"use",value:function(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}},{key:"eject",value:function(e){this.handlers[e]&&(this.handlers[e]=null)}},{key:"clear",value:function(){this.handlers&&(this.handlers=[])}},{key:"forEach",value:function(e){Vi.forEach(this.handlers,(function(t){null!==t&&e(t)}))}}]),e}(),Eo=bo,wo={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0},So={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:mo,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]},Ao="undefined"!=typeof window&&"undefined"!=typeof document,To="object"===("undefined"==typeof navigator?"undefined":R(navigator))&&navigator||void 0,Po=Ao&&(!To||["ReactNative","NativeScript","NS"].indexOf(To.product)<0),Ro="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,ko=Ao&&window.location.href||"http://localhost",Lo=b(b({},e),So);function No(e){if(e>100)throw new ao("FormData field is too deeply nested ("+e+" levels). Max depth: 100",ao.ERR_FORM_DATA_DEPTH_EXCEEDED)}var Oo=function(e){function t(e,n,r,i){No(i);var o=e[i++];if("__proto__"===o)return!0;var a=Number.isFinite(+o),s=i>=e.length;return o=!o&&Vi.isArray(r)?r.length:o,s?(Vi.hasOwnProp(r,o)?r[o]=Vi.isArray(r[o])?r[o].concat(n):[r[o],n]:r[o]=n,!a):(Vi.hasOwnProp(r,o)&&Vi.isObject(r[o])||(r[o]=[]),t(e,n,r[o],i)&&Vi.isArray(r[o])&&(r[o]=function(e){var t,n,r={},i=Object.keys(e),o=i.length;for(t=0;t<o;t++)r[n=i[t]]=e[n];return r}(r[o])),!a)}if(Vi.isFormData(e)&&Vi.isFunction(e.entries)){var n={};return Vi.forEachEntry(e,(function(e,r){t(function(e){for(var t,n=[],r=/\w+|\[(\w*)]/g;null!==(t=r.exec(e));)No(n.length),n.push("[]"===t[0]?"":t[1]||t[0]);return n}(e),r,n,0)})),n}return null},Io=function(e,t){return null!=e&&Vi.hasOwnProp(e,t)?e[t]:void 0};var Co={transitional:wo,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){var n,r=t.getContentType()||"",i=r.indexOf("application/json")>-1,o=Vi.isObject(e);if(o&&Vi.isHTMLForm(e)&&(e=new FormData(e)),Vi.isFormData(e))return i?JSON.stringify(Oo(e)):e;if(Vi.isArrayBuffer(e)||Vi.isBuffer(e)||Vi.isStream(e)||Vi.isFile(e)||Vi.isBlob(e)||Vi.isReadableStream(e))return e;if(Vi.isArrayBufferView(e))return e.buffer;if(Vi.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();if(o){var a=Io(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return fo(e,new Lo.classes.URLSearchParams,b({visitor:function(e,t,n,r){return Lo.isNode&&Vi.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,a).toString();if((n=Vi.isFileList(e))||r.indexOf("multipart/form-data")>-1){var s=Io(this,"env"),u=s&&s.FormData;return fo(n?{"files[]":e}:e,u&&new u,a)}}return o||i?(t.setContentType("application/json",!1),function(e,t,n){if(Vi.isString(e))try{return(t||JSON.parse)(e),Vi.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){var t=Io(this,"transitional")||Co.transitional,n=t&&t.forcedJSONParsing,r=Io(this,"responseType"),i="json"===r;if(Vi.isResponse(e)||Vi.isReadableStream(e))return e;if(e&&Vi.isString(e)&&(n&&!r||i)){var o=!(t&&t.silentJSONParsing)&&i;try{return JSON.parse(e,Io(this,"parseReviver"))}catch(e){if(o){if("SyntaxError"===e.name)throw ao.from(e,ao.ERR_BAD_RESPONSE,this,null,Io(this,"response"));throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Lo.classes.FormData,Blob:Lo.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Vi.forEach(["delete","get","head","post","put","patch","query"],(function(e){Co.headers[e]={}}));var Mo=Co;function Do(e,t){var n=this||Mo,r=t||n,i=ro.from(r.headers),o=r.data;return Vi.forEach(e,(function(e){o=e.call(n,o,i.normalize(),t?t.status:void 0)})),i.normalize(),o}function xo(e){return!(!e||!e.__CANCEL__)}var Bo=function(e){d(n,e);var t=v(n);function n(e,r,i){var o;return u(this,n),(o=t.call(this,null==e?"canceled":e,ao.ERR_CANCELED,r,i)).name="CanceledError",o.__CANCEL__=!0,o}return l(n)}(ao);function Uo(e,t,n){var r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new ao("Request failed with status code "+n.status,n.status>=400&&n.status<500?ao.ERR_BAD_REQUEST:ao.ERR_BAD_RESPONSE,n.config,n.request,n)):e(n)}var Ho=function(e,t){e=e||10;var n,r=new Array(e),i=new Array(e),o=0,a=0;return t=void 0!==t?t:1e3,function(s){var u=Date.now(),c=i[a];n||(n=u),r[o]=s,i[o]=u;for(var l=a,h=0;l!==o;)h+=r[l++],l%=e;if((o=(o+1)%e)===a&&(a=(a+1)%e),!(u-n<t)){var f=c&&u-c;return f?Math.round(1e3*h/f):void 0}}};var jo=function(e,t){var n,r,i=0,o=1e3/t,a=function(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Date.now();i=o,n=null,r&&(clearTimeout(r),r=null),e.apply(void 0,C(t))};return[function(){for(var e=Date.now(),t=e-i,s=arguments.length,u=new Array(s),c=0;c<s;c++)u[c]=arguments[c];t>=o?a(u,e):(n=u,r||(r=setTimeout((function(){r=null,a(n)}),o-t)))},function(){return n&&a(n)}]},zo=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3,r=0,i=Ho(50,250);return jo((function(n){if(n&&"number"==typeof n.loaded){var o=n.loaded,a=n.lengthComputable?n.total:void 0,s=null!=a?Math.min(o,a):o,u=Math.max(0,s-r),c=i(u);r=Math.max(r,s);var l=y({loaded:s,total:a,progress:a?s/a:void 0,bytes:u,rate:c||void 0,estimated:c&&a?(a-s)/c:void 0,event:n,lengthComputable:null!=a},t?"download":"upload",!0);e(l)}}),n)},Yo=function(e,t){var n=null!=e;return[function(r){return t[0]({lengthComputable:n,total:e,loaded:r})},t[1]]},Go=function(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return Vi.asap((function(){return e.apply(void 0,n)}))}},Fo=Lo.hasStandardBrowserEnv?function(e,t){return function(n){return n=new URL(n,Lo.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)}}(new URL(Lo.origin),Lo.navigator&&/(msie|trident)/i.test(Lo.navigator.userAgent)):function(){return!0},Ko=Lo.hasStandardBrowserEnv?{write:function(e,t,n,r,i,o,a){if("undefined"!=typeof document){var s=["".concat(e,"=").concat(encodeURIComponent(t))];Vi.isNumber(n)&&s.push("expires=".concat(new Date(n).toUTCString())),Vi.isString(r)&&s.push("path=".concat(r)),Vi.isString(i)&&s.push("domain=".concat(i)),!0===o&&s.push("secure"),Vi.isString(a)&&s.push("SameSite=".concat(a)),document.cookie=s.join("; ")}},read:function(e){if("undefined"==typeof document)return null;for(var t=document.cookie.split(";"),n=0;n<t.length;n++){var r=t[n].replace(/^\s+/,""),i=r.indexOf("=");if(-1!==i&&r.slice(0,i)===e)try{return decodeURIComponent(r.slice(i+1))}catch(e){return r.slice(i+1)}}return null},remove:function(e){this.write(e,"",Date.now()-864e5,"/")}}:{write:function(){},read:function(){return null},remove:function(){}};var Vo=/^https?:(?!\/\/)/i,Wo=/[\t\n\r]/g;function qo(e,t){if("string"==typeof e&&Vo.test(function(e){return function(e){for(var t=0;t<e.length&&e.charCodeAt(t)<=32;)t++;return e.slice(t)}(e).replace(Wo,"")}(e)))throw new ao('Invalid URL: missing "//" after protocol',ao.ERR_INVALID_URL,t)}function Jo(e,t,n,r){qo(t,r);var i,o=!("string"==typeof(i=t)&&/^([a-z][a-z\d+\-.]*:)?\/\//i.test(i));return e&&(o||!1===n)?(qo(e,r),function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t)):t}var Xo=function(e){return e instanceof ro?b({},e):e};function Zo(e,t){e=e||{},t=t||{};var n=Object.create(null);function r(e,t,n,r){return Vi.isPlainObject(e)&&Vi.isPlainObject(t)?Vi.merge.call({caseless:r},e,t):Vi.isPlainObject(t)?Vi.merge({},t):Vi.isArray(t)?t.slice():t}function i(e,t,n,i){return Vi.isUndefined(t)?Vi.isUndefined(e)?void 0:r(void 0,e,0,i):r(e,t,0,i)}function o(e,t){if(!Vi.isUndefined(t))return r(void 0,t)}function a(e,t){return Vi.isUndefined(t)?Vi.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function s(n,i,o){return Vi.hasOwnProp(t,o)?r(n,i):Vi.hasOwnProp(e,o)?r(void 0,n):void 0}Object.defineProperty(n,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});var u={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,allowedSocketPaths:a,responseEncoding:a,validateStatus:s,headers:function(e,t,n){return i(Xo(e),Xo(t),0,!0)}};return Vi.forEach(Object.keys(b(b({},e),t)),(function(r){if("__proto__"!==r&&"constructor"!==r&&"prototype"!==r){var o=Vi.hasOwnProp(u,r)?u[r]:i,a=o(Vi.hasOwnProp(e,r)?e[r]:void 0,Vi.hasOwnProp(t,r)?t[r]:void 0,r);Vi.isUndefined(a)&&o!==s||(n[r]=a)}})),Vi.hasOwnProp(t,"validateStatus")&&Vi.isUndefined(t.validateStatus)&&!1===function(n){var r=Vi.hasOwnProp(t,"transitional")?t.transitional:void 0;if(!Vi.isUndefined(r)){if(!Vi.isPlainObject(r))return;if(Vi.hasOwnProp(r,n))return r[n]}var i=Vi.hasOwnProp(e,"transitional")?e.transitional:void 0;if(Vi.isPlainObject(i)&&Vi.hasOwnProp(i,n))return i[n]}("validateStatusUndefinedResolves")&&(Vi.hasOwnProp(e,"validateStatus")?n.validateStatus=r(void 0,e.validateStatus):delete n.validateStatus),n}var Qo=["content-type","content-length"];var $o=function(e){var t=Zo({},e),n=function(e){return Vi.hasOwnProp(t,e)?t[e]:void 0},r=n("data"),i=n("withXSRFToken"),o=n("xsrfHeaderName"),a=n("xsrfCookieName"),s=n("headers"),u=n("auth"),c=n("baseURL"),l=n("allowAbsoluteUrls"),h=n("url");if(t.headers=s=ro.from(s),t.url=_o(Jo(c,h,l,t),n("params"),n("paramsSerializer")),u){var f=Vi.getSafeProp(u,"username")||"",p=Vi.getSafeProp(u,"password")||"";try{s.set("Authorization","Basic "+btoa(f+":"+(p?encodeURIComponent(p).replace(/%([0-9A-F]{2})/gi,(function(e,t){return String.fromCharCode(parseInt(t,16))})):"")))}catch(t){throw ao.from(t,ao.ERR_BAD_OPTION_VALUE,e)}}if(Vi.isFormData(r)&&(Lo.hasStandardBrowserEnv||Lo.hasStandardBrowserWebWorkerEnv||Vi.isReactNative(r)?s.setContentType(void 0):Vi.isFunction(r.getHeaders)&&function(e,t,n){"content-only"===n?Object.entries(t||{}).forEach((function(t){var n=P(t,2),r=n[0],i=n[1];Qo.includes(r.toLowerCase())&&e.set(r,i)})):e.set(t)}(s,r.getHeaders(),n("formDataHeaderPolicy"))),Lo.hasStandardBrowserEnv&&(Vi.isFunction(i)&&(i=i(t)),!0===i||null==i&&Fo(t.url))){var d=o&&a&&Ko.read(a);d&&s.set(o,d)}return t},ea="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){var r,i,o,a,s,u=$o(e),c=u.data,l=ro.from(u.headers).normalize(),h=u.responseType,f=u.onUploadProgress,p=u.onDownloadProgress;function d(){a&&a(),s&&s(),u.cancelToken&&u.cancelToken.unsubscribe(r),u.signal&&u.signal.removeEventListener("abort",r)}var g=new XMLHttpRequest;function v(){if(g){var r=ro.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders());Uo((function(e){t(e),d()}),(function(e){n(e),d()}),{data:h&&"text"!==h&&"json"!==h?g.response:g.responseText,status:g.status,statusText:g.statusText,headers:r,config:e,request:g}),g=null}}if(g.open(u.method.toUpperCase(),u.url,!0),g.timeout=u.timeout,"onloadend"in g?g.onloadend=v:g.onreadystatechange=function(){g&&4===g.readyState&&(0!==g.status||g.responseURL&&g.responseURL.startsWith("file:"))&&setTimeout(v)},g.onabort=function(){g&&(n(new ao("Request aborted",ao.ECONNABORTED,e,g)),d(),g=null)},g.onerror=function(t){var r=t&&t.message?t.message:"Network Error",i=new ao(r,ao.ERR_NETWORK,e,g);i.event=t||null,n(i),d(),g=null},g.ontimeout=function(){var t=u.timeout?"timeout of "+u.timeout+"ms exceeded":"timeout exceeded",r=u.transitional||wo;u.timeoutErrorMessage&&(t=u.timeoutErrorMessage),n(new ao(t,r.clarifyTimeoutError?ao.ETIMEDOUT:ao.ECONNABORTED,e,g)),d(),g=null},void 0===c&&l.setContentType(null),"setRequestHeader"in g&&Vi.forEach(Zi(l),(function(e,t){g.setRequestHeader(t,e)})),Vi.isUndefined(u.withCredentials)||(g.withCredentials=!!u.withCredentials),h&&"json"!==h&&(g.responseType=u.responseType),p){var m=zo(p,!0),y=P(m,2);o=y[0],s=y[1],g.addEventListener("progress",o)}if(f&&g.upload){var _=zo(f),b=P(_,2);i=b[0],a=b[1],g.upload.addEventListener("progress",i),g.upload.addEventListener("loadend",a)}(u.cancelToken||u.signal)&&(r=function(t){g&&(n(!t||t.type?new Bo(null,e,g):t),g.abort(),d(),g=null)},u.cancelToken&&u.cancelToken.subscribe(r),u.signal&&(u.signal.aborted?r():u.signal.addEventListener("abort",r)));var E,w,S=(E=u.url,(w=/^([-+\w]{1,25}):(?:\/\/)?/.exec(E))&&w[1]||"");if(S&&!Lo.protocols.includes(S))return n(new ao("Unsupported protocol "+S+":",ao.ERR_BAD_REQUEST,e)),void d();g.send(c||null)}))},ta=function(e,t){if(e=e?e.filter(Boolean):[],t||e.length){var n=new AbortController,r=!1,i=function(e){if(!r){r=!0,a();var t=e instanceof Error?e:this.reason;n.abort(t instanceof ao?t:new Bo(t instanceof Error?t.message:t))}},o=t&&setTimeout((function(){o=null,i(new ao("timeout of ".concat(t,"ms exceeded"),ao.ETIMEDOUT))}),t),a=function(){e&&(o&&clearTimeout(o),o=null,e.forEach((function(e){e.unsubscribe?e.unsubscribe(i):e.removeEventListener("abort",i)})),e=null)};e.forEach((function(e){return e.addEventListener("abort",i,{once:!0})}));var s=n.signal;return s.unsubscribe=function(){return Vi.asap(a)},s}},na=n(3697),ra=n(8946),ia=n(4331),oa=n(8193),aa=w().mark((function e(t,n){var r,i,o;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=t.byteLength,n&&!(r<n)){e.next=5;break}return e.next=4,t;case 4:return e.abrupt("return");case 5:i=0;case 6:if(!(i<r)){e.next=13;break}return o=i+n,e.next=10,t.slice(i,o);case 10:i=o,e.next=6;break;case 13:case"end":return e.stop()}}),e)})),sa=function(){var e=na(w().mark((function e(t,n){var r,i,o,a,s,u;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=!1,i=!1,e.prev=2,a=oa(ua(t));case 4:return e.next=6,ra(a.next());case 6:if(!(r=!(s=e.sent).done)){e.next=12;break}return u=s.value,e.delegateYield(ia(oa(aa(u,n)),ra),"t0",9);case 9:r=!1,e.next=4;break;case 12:e.next=18;break;case 14:e.prev=14,e.t1=e.catch(2),i=!0,o=e.t1;case 18:if(e.prev=18,e.prev=19,!r||null==a.return){e.next=23;break}return e.next=23,ra(a.return());case 23:if(e.prev=23,!i){e.next=26;break}throw o;case 26:return e.finish(23);case 27:return e.finish(18);case 28:case"end":return e.stop()}}),e,null,[[2,14,18,28],[19,,23,27]])})));return function(t,n){return e.apply(this,arguments)}}(),ua=function(){var e=na(w().mark((function e(t){var n,r,i,o;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!t[Symbol.asyncIterator]){e.next=3;break}return e.delegateYield(ia(oa(t),ra),"t0",2);case 2:return e.abrupt("return");case 3:n=t.getReader(),e.prev=4;case 5:return e.next=7,ra(n.read());case 7:if(r=e.sent,i=r.done,o=r.value,!i){e.next=12;break}return e.abrupt("break",16);case 12:return e.next=14,o;case 14:e.next=5;break;case 16:return e.prev=16,e.next=19,ra(n.cancel());case 19:return e.finish(16);case 20:case"end":return e.stop()}}),e,null,[[4,,16,20]])})));return function(t){return e.apply(this,arguments)}}(),ca=function(e,t,n,r){var i,o=sa(e,t),a=0,s=function(e){i||(i=!0,r&&r(e))};return new ReadableStream({pull:function(e){return A(w().mark((function t(){var r,i,u,c,l;return w().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.next();case 3:if(r=t.sent,i=r.done,u=r.value,!i){t.next=10;break}return s(),e.close(),t.abrupt("return");case 10:c=u.byteLength,n&&(l=a+=c,n(l)),e.enqueue(new Uint8Array(u)),t.next=19;break;case 15:throw t.prev=15,t.t0=t.catch(0),s(t.t0),t.t0;case 19:case"end":return t.stop()}}),t,null,[[0,15]])})))()},cancel:function(e){return s(e),o.return()}},{highWaterMark:2})},la=function(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102},ha=function(e,t,n){return t+2<n&&la(e.charCodeAt(t+1))&&la(e.charCodeAt(t+2))};function fa(e){if(!e||"string"!=typeof e)return 0;if(!e.startsWith("data:"))return 0;var t=e.indexOf(",");if(t<0)return 0;var n=e.slice(5,t),r=e.slice(t+1);if(/;base64/i.test(n)){for(var i=r.length,o=r.length,a=0;a<o;a++)if(37===r.charCodeAt(a)&&a+2<o){var s=r.charCodeAt(a+1),u=r.charCodeAt(a+2);la(s)&&la(u)&&(i-=2,a+=2)}var c=0,l=o-1,h=function(e){return e>=2&&37===r.charCodeAt(e-2)&&51===r.charCodeAt(e-1)&&(68===r.charCodeAt(e)||100===r.charCodeAt(e))};l>=0&&(61===r.charCodeAt(l)?(c++,l--):h(l)&&(c++,l-=3)),1===c&&l>=0&&(61===r.charCodeAt(l)||h(l))&&c++;var f=3*Math.floor(i/4)-(c||0);return f>0?f:0}for(var p=0,d=0,g=r.length;d<g;d++){var v=r.charCodeAt(d);if(37===v&&ha(r,d,g))p+=1,d+=2;else if(v<128)p+=1;else if(v<2048)p+=2;else if(v>=55296&&v<=56319&&d+1<g){var m=r.charCodeAt(d+1);m>=56320&&m<=57343?(p+=4,d++):p+=3}else p+=3}return p}var pa="1.18.1",da=Vi.isFunction,ga=function(e){if(!Vi.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},va=function(e){try{for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return!!e.apply(void 0,n)}catch(e){return!1}},ma=function(e){var t=e.indexOf("://"),n=e;return-1!==t&&(n=n.slice(t+3)),n.includes("@")||n.includes(":")},ya=function(e){var t=void 0!==Vi.global&&null!==Vi.global?Vi.global:globalThis,n=t.ReadableStream,r=t.TextEncoder,i=e=Vi.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e),o=i.fetch,a=i.Request,s=i.Response,u=o?da(o):"function"==typeof fetch,c=da(a),l=da(s);if(!u)return!1;var h,f=u&&da(n),p=u&&("function"==typeof r?(h=new r,function(e){return h.encode(e)}):function(){var e=A(w().mark((function e(t){return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.t0=Uint8Array,e.next=3,new a(t).arrayBuffer();case 3:return e.t1=e.sent,e.abrupt("return",new e.t0(e.t1));case 5:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),d=c&&f&&va((function(){var e=!1,t=new a(Lo.origin,{body:new n,method:"POST",get duplex(){return e=!0,"half"}}),r=t.headers.has("Content-Type");return null!=t.body&&t.body.cancel(),e&&!r})),g=l&&f&&va((function(){return Vi.isReadableStream(new s("").body)})),v={stream:g&&function(e){return e.body}};u&&["text","arrayBuffer","blob","formData","stream"].forEach((function(e){!v[e]&&(v[e]=function(t,n){var r=t&&t[e];if(r)return r.call(t);throw new ao("Response type '".concat(e,"' is not supported"),ao.ERR_NOT_SUPPORT,n)})}));var m=function(){var e=A(w().mark((function e(t){var n;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=t){e.next=2;break}return e.abrupt("return",0);case 2:if(!Vi.isBlob(t)){e.next=4;break}return e.abrupt("return",t.size);case 4:if(!Vi.isSpecCompliantForm(t)){e.next=9;break}return n=new a(Lo.origin,{method:"POST",body:t}),e.next=8,n.arrayBuffer();case 8:case 15:return e.abrupt("return",e.sent.byteLength);case 9:if(!Vi.isArrayBufferView(t)&&!Vi.isArrayBuffer(t)){e.next=11;break}return e.abrupt("return",t.byteLength);case 11:if(Vi.isURLSearchParams(t)&&(t+=""),!Vi.isString(t)){e.next=16;break}return e.next=15,p(t);case 16:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),y=function(){var e=A(w().mark((function e(t,n){var r;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=Vi.toFiniteNumber(t.getContentLength()),e.abrupt("return",null==r?m(n):r);case 2:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}();return function(){var e=A(w().mark((function e(t){var n,i,u,l,h,p,_,E,S,A,T,R,k,L,N,O,I,C,M,D,x,B,U,H,j,z,Y,G,F,K,V,W,q,J,X,Z,Q,$,ee,te,ne,re,ie,oe,ae,se,ue,ce,le,he,fe,pe,de,ge,ve,me,ye,_e,be,Ee;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=$o(t),i=n.url,u=n.method,l=n.data,h=n.signal,p=n.cancelToken,_=n.timeout,E=n.onDownloadProgress,S=n.onUploadProgress,A=n.responseType,T=n.headers,R=n.withCredentials,k=void 0===R?"same-origin":R,L=n.fetchOptions,N=n.maxContentLength,O=n.maxBodyLength,I=Vi.isNumber(N)&&N>-1,C=Vi.isNumber(O)&&O>-1,M=function(e){return Vi.hasOwnProp(t,e)?t[e]:void 0},D=o||fetch,A=A?(A+"").toLowerCase():"text",x=ta([h,p&&p.toAbortSignal()],_),B=null,U=x&&x.unsubscribe&&function(){x.unsubscribe()},j=null,z=function(){return new ao("Request body larger than maxBodyLength limit",ao.ERR_BAD_REQUEST,t,B)},e.prev=11,Y=void 0,(G=M("auth"))&&(F=Vi.getSafeProp(G,"username")||"",K=Vi.getSafeProp(G,"password")||"",Y={username:F,password:K}),ma(i)&&(V=new URL(i,Lo.origin),Y||!V.username&&!V.password||(W=ga(V.username),q=ga(V.password),Y={username:W,password:q}),(V.username||V.password)&&(V.username="",V.password="",i=V.href)),Y&&(T.delete("authorization"),T.set("Authorization","Basic "+btoa((w=(Y.username||"")+":"+(Y.password||""),encodeURIComponent(w).replace(/%([0-9A-F]{2})/gi,(function(e,t){return String.fromCharCode(parseInt(t,16))})))))),!I||"string"!=typeof i||!i.startsWith("data:")){e.next=21;break}if(!(fa(i)>N)){e.next=21;break}throw new ao("maxContentLength size of "+N+" exceeded",ao.ERR_BAD_RESPONSE,t,B);case 21:if(!C||"get"===u||"head"===u){e.next=29;break}return e.next=24,m(l);case 24:if("number"!=typeof(J=e.sent)||!isFinite(J)){e.next=29;break}if(H=J,!(J>O)){e.next=29;break}throw z();case 29:if(X=C&&(Vi.isReadableStream(l)||Vi.isStream(l)),Z=function(e,t,n){return ca(e,65536,(function(e){if(C&&e>O)throw j=z();t&&t(e)}),n)},!d||"get"===u||"head"===u||!S&&!X){e.next=43;break}if(null!=H){e.next=38;break}return e.next=35,y(T,l);case 35:e.t0=e.sent,e.next=39;break;case 38:e.t0=H;case 39:(0!==(H=e.t0)||X)&&(Q=new a(i,{method:"POST",body:l,duplex:"half"}),Vi.isFormData(l)&&($=Q.headers.get("content-type"))&&T.setContentType($),Q.body&&(ee=S&&Yo(H,zo(Go(S)))||[],te=P(ee,2),ne=te[0],re=te[1],l=Z(Q.body,ne,re))),e.next=49;break;case 43:if(!X||c||!f||"get"===u||"head"===u){e.next=47;break}l=Z(l),e.next=49;break;case 47:if(!X||!c||d||"get"===u||"head"===u){e.next=49;break}throw new ao("Stream request bodies are not supported by the current fetch implementation",ao.ERR_NOT_SUPPORT,t,B);case 49:return Vi.isString(k)||(k=k?"include":"omit"),ie=c&&"credentials"in a.prototype,Vi.isFormData(l)&&(oe=T.getContentType())&&/^multipart\/form-data/i.test(oe)&&!/boundary=/i.test(oe)&&T.delete("content-type"),T.set("User-Agent","axios/"+pa,!1),ae=b(b({},L),{},{signal:x,method:u.toUpperCase(),headers:Zi(T.normalize()),body:l,duplex:"half",credentials:ie?k:void 0}),B=c&&new a(i,ae),e.next=57,c?D(B,L):D(i,ae);case 57:if(se=e.sent,ue=ro.from(se.headers),!I){e.next=63;break}if(!(null!=(ce=Vi.toFiniteNumber(ue.getContentLength()))&&ce>N)){e.next=63;break}throw new ao("maxContentLength size of "+N+" exceeded",ao.ERR_BAD_RESPONSE,t,B);case 63:return le=g&&("stream"===A||"response"===A),g&&se.body&&(E||I||le&&U)&&(he={},["status","statusText","headers"].forEach((function(e){he[e]=se[e]})),fe=Vi.toFiniteNumber(ue.getContentLength()),pe=E&&Yo(fe,zo(Go(E),!0))||[],de=P(pe,2),ge=de[0],ve=de[1],0,me=function(e){if(I&&e>N)throw new ao("maxContentLength size of "+N+" exceeded",ao.ERR_BAD_RESPONSE,t,B);ge&&ge(e)},se=new s(ca(se.body,65536,me,(function(){ve&&ve(),U&&U()})),he)),A=A||"text",e.next=68,v[Vi.findKey(v,A)||"text"](se,t);case 68:if(ye=e.sent,!I||g||le){e.next=73;break}if(null!=ye&&("number"==typeof ye.byteLength?_e=ye.byteLength:"number"==typeof ye.size?_e=ye.size:"string"==typeof ye&&(_e="function"==typeof r?(new r).encode(ye).byteLength:ye.length)),!("number"==typeof _e&&_e>N)){e.next=73;break}throw new ao("maxContentLength size of "+N+" exceeded",ao.ERR_BAD_RESPONSE,t,B);case 73:return!le&&U&&U(),e.next=76,new Promise((function(e,n){Uo(e,n,{data:ye,headers:ro.from(se.headers),status:se.status,statusText:se.statusText,config:t,request:B})}));case 76:return e.abrupt("return",e.sent);case 79:if(e.prev=79,e.t1=e.catch(11),U&&U(),!(x&&x.aborted&&x.reason instanceof ao)){e.next=88;break}throw(be=x.reason).config=t,B&&(be.request=B),e.t1!==be&&Object.defineProperty(be,"cause",{__proto__:null,value:e.t1,writable:!0,enumerable:!1,configurable:!0}),be;case 88:if(!j){e.next=91;break}throw B&&!j.request&&(j.request=B),j;case 91:if(!(e.t1 instanceof ao)){e.next=94;break}throw B&&!e.t1.request&&(e.t1.request=B),e.t1;case 94:if(!e.t1||"TypeError"!==e.t1.name||!/Load failed|fetch/i.test(e.t1.message)){e.next=98;break}throw Ee=new ao("Network Error",ao.ERR_NETWORK,t,B,e.t1&&e.t1.response),Object.defineProperty(Ee,"cause",{__proto__:null,value:e.t1.cause||e.t1,writable:!0,enumerable:!1,configurable:!0}),Ee;case 98:throw ao.from(e.t1,e.t1&&e.t1.code,t,B,e.t1&&e.t1.response);case 99:case"end":return e.stop()}var w}),e,null,[[11,79]])})));return function(t){return e.apply(this,arguments)}}()},_a=new Map,ba=function(e){for(var t,n,r=e&&e.env||{},i=r.fetch,o=[r.Request,r.Response,i],a=o.length,s=_a;a--;)t=o[a],void 0===(n=s.get(t))&&s.set(t,n=a?new Map:ya(r)),s=n;return n},Ea=(ba(),{http:null,xhr:ea,fetch:{get:ba}});Vi.forEach(Ea,(function(e,t){if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(e){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}}));var wa=function(e){return"- ".concat(e)},Sa=function(e){return Vi.isFunction(e)||null===e||!1===e};var Aa={getAdapter:function(e,t){for(var n,r,i=(e=Vi.isArray(e)?e:[e]).length,o={},a=0;a<i;a++){var s=void 0;if(r=n=e[a],!Sa(n)&&void 0===(r=Ea[(s=String(n)).toLowerCase()]))throw new ao("Unknown adapter '".concat(s,"'"));if(r&&(Vi.isFunction(r)||(r=r.get(t))))break;o[s||"#"+a]=r}if(!r){var u=Object.entries(o).map((function(e){var t=P(e,2),n=t[0],r=t[1];return"adapter ".concat(n," ")+(!1===r?"is not supported by the environment":"is not available in the build")})),c=i?u.length>1?"since :\n"+u.map(wa).join("\n"):" "+wa(u[0]):"as no adapter specified";throw new ao("There is no suitable adapter to dispatch the request "+c,ao.ERR_NOT_SUPPORT)}return r},adapters:Ea};function Ta(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Bo(null,e)}function Pa(e){return Ta(e),e.headers=ro.from(e.headers),e.data=Do.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Aa.getAdapter(e.adapter||Mo.adapter,e)(e).then((function(t){Ta(e),e.response=t;try{t.data=Do.call(e,e.transformResponse,t)}finally{delete e.response}return t.headers=ro.from(t.headers),t}),(function(t){if(!xo(t)&&(Ta(e),t&&t.response)){e.response=t.response;try{t.response.data=Do.call(e,e.transformResponse,t.response)}finally{delete e.response}t.response.headers=ro.from(t.response.headers)}return Promise.reject(t)}))}var Ra={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){Ra[e]=function(n){return R(n)===e||"a"+(t<1?"n ":" ")+e}}));var ka={};Ra.transitional=function(e,t,n){function r(e,t){return"[Axios v"+pa+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return function(n,i,o){if(!1===e)throw new ao(r(i," has been removed"+(t?" in "+t:"")),ao.ERR_DEPRECATED);return t&&!ka[i]&&(ka[i]=!0,console.warn(r(i," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,i,o)}},Ra.spelling=function(e){return function(t,n){return console.warn("".concat(n," is likely a misspelling of ").concat(e)),!0}};var La={assertOptions:function(e,t,n){if("object"!==R(e)||null===e)throw new ao("options must be an object",ao.ERR_BAD_OPTION_VALUE);for(var r=Object.keys(e),i=r.length;i-- >0;){var o=r[i],a=Object.prototype.hasOwnProperty.call(t,o)?t[o]:void 0;if(a){var s=e[o],u=void 0===s||a(s,o,e);if(!0!==u)throw new ao("option "+o+" must be "+u,ao.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new ao("Unknown option "+o,ao.ERR_BAD_OPTION)}},validators:Ra},Na=La.validators,Oa=function(){function e(t){u(this,e),this.defaults=t||{},this.interceptors={request:new Eo,response:new Eo}}var t;return l(e,[{key:"request",value:(t=A(w().mark((function e(t,n){var r,i,o,a,s;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this._request(t,n);case 3:return e.abrupt("return",e.sent);case 6:if(e.prev=6,e.t0=e.catch(0),e.t0 instanceof Error){r={},Error.captureStackTrace?Error.captureStackTrace(r):r=new Error,i=function(){if(!r.stack)return"";var e=r.stack.indexOf("\n");return-1===e?"":r.stack.slice(e+1)}();try{e.t0.stack?i&&(o=i.indexOf("\n"),a=-1===o?-1:i.indexOf("\n",o+1),s=-1===a?"":i.slice(a+1),String(e.t0.stack).endsWith(s)||(e.t0.stack+="\n"+i)):e.t0.stack=i}catch(e){}}throw e.t0;case 10:case"end":return e.stop()}}),e,this,[[0,6]])}))),function(e,n){return t.apply(this,arguments)})},{key:"_request",value:function(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{};var n=t=Zo(this.defaults,t),r=n.transitional,i=n.paramsSerializer,o=n.headers;void 0!==r&&La.assertOptions(r,{silentJSONParsing:Na.transitional(Na.boolean),forcedJSONParsing:Na.transitional(Na.boolean),clarifyTimeoutError:Na.transitional(Na.boolean),legacyInterceptorReqResOrdering:Na.transitional(Na.boolean),advertiseZstdAcceptEncoding:Na.transitional(Na.boolean),validateStatusUndefinedResolves:Na.transitional(Na.boolean)},!1),null!=i&&(Vi.isFunction(i)?t.paramsSerializer={serialize:i}:La.assertOptions(i,{encode:Na.function,serialize:Na.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),La.assertOptions(t,{baseUrl:Na.spelling("baseURL"),withXsrfToken:Na.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();var a=o&&Vi.merge(o.common,o[t.method]);o&&Vi.forEach(["delete","get","head","post","put","patch","query","common"],(function(e){delete o[e]})),t.headers=ro.concat(a,o);var s=[],u=!0;this.interceptors.request.forEach((function(e){if("function"!=typeof e.runWhen||!1!==e.runWhen(t)){u=u&&e.synchronous;var n=t.transitional||wo;n&&n.legacyInterceptorReqResOrdering?s.unshift(e.fulfilled,e.rejected):s.push(e.fulfilled,e.rejected)}}));var c,l=[];this.interceptors.response.forEach((function(e){l.push(e.fulfilled,e.rejected)}));var h,f=0;if(!u){var p=[Pa.bind(this),void 0];for(p.unshift.apply(p,s),p.push.apply(p,l),h=p.length,c=Promise.resolve(t);f<h;)c=c.then(p[f++],p[f++]);return c}h=s.length;for(var d=t;f<h;){var g=s[f++],v=s[f++];try{d=g(d)}catch(e){v.call(this,e);break}}try{c=Pa.call(this,d)}catch(e){return Promise.reject(e)}for(f=0,h=l.length;f<h;)c=c.then(l[f++],l[f++]);return c}},{key:"getUri",value:function(e){return _o(Jo((e=Zo(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls,e),e.params,e.paramsSerializer)}}]),e}();Vi.forEach(["delete","get","head","options"],(function(e){Oa.prototype[e]=function(t,n){return this.request(Zo(n||{},{method:e,url:t,data:n&&Vi.hasOwnProp(n,"data")?n.data:void 0}))}})),Vi.forEach(["post","put","patch","query"],(function(e){function t(t){return function(n,r,i){return this.request(Zo(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}Oa.prototype[e]=t(),"query"!==e&&(Oa.prototype[e+"Form"]=t(!0))}));var Ia=Oa,Ca=function(){function e(t){if(u(this,e),"function"!=typeof t)throw new TypeError("executor must be a function.");var n;this.promise=new Promise((function(e){n=e}));var r=this;this.promise.then((function(e){if(r._listeners){for(var t=r._listeners.length;t-- >0;)r._listeners[t](e);r._listeners=null}})),this.promise.then=function(e){var t,n=new Promise((function(e){r.subscribe(e),t=e})).then(e);return n.cancel=function(){r.unsubscribe(t)},n},t((function(e,t,i){r.reason||(r.reason=new Bo(e,t,i),n(r.reason))}))}return l(e,[{key:"throwIfRequested",value:function(){if(this.reason)throw this.reason}},{key:"subscribe",value:function(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}},{key:"unsubscribe",value:function(e){if(this._listeners){var t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}}},{key:"toAbortSignal",value:function(){var e=this,t=new AbortController,n=function(e){t.abort(e)};return this.subscribe(n),t.signal.unsubscribe=function(){return e.unsubscribe(n)},t.signal}}],[{key:"source",value:function(){var t,n=new e((function(e){t=e}));return{token:n,cancel:t}}}]),e}(),Ma=Ca;var Da={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Da).forEach((function(e){var t=P(e,2),n=t[0],r=t[1];Da[r]=n}));var xa=Da;var Ba=function e(t){var n=new Ia(t),r=Wr(Ia.prototype.request,n);return Vi.extend(r,Ia.prototype,n,{allOwnKeys:!0}),Vi.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(Zo(t,n))},r}(Mo);Ba.Axios=Ia,Ba.CanceledError=Bo,Ba.CancelToken=Ma,Ba.isCancel=xo,Ba.VERSION=pa,Ba.toFormData=fo,Ba.AxiosError=ao,Ba.Cancel=Ba.CanceledError,Ba.all=function(e){return Promise.all(e)},Ba.spread=function(e){return function(t){return e.apply(null,t)}},Ba.isAxiosError=function(e){return Vi.isObject(e)&&!0===e.isAxiosError},Ba.mergeConfig=Zo,Ba.AxiosHeaders=ro,Ba.formToJSON=function(e){return Oo(Vi.isHTMLForm(e)?new FormData(e):e)},Ba.getAdapter=Aa.getAdapter,Ba.HttpStatusCode=xa,Ba.default=Ba;var Ua=Ba,Ha=n(9414),ja=function(){try{var e;return(null===(e=navigator)||void 0===e?void 0:e.javaEnabled())||!1}catch(e){}return!1},za={local:"http://imgs-63.sggz00b.dev.alipay.net/mgw.htm",dev:"http://imgs-63.sggz00b.dev.alipay.net/mgw.htm",sit:"http://imgs-9.sggz00a.test.alipay.net/mgw.htm",light_sandbox:"https://imgs-sea-global.alipay.com/mgw.htm",pre:"https://imgs-sea-pre.alipay.com/mgw.htm",prod:"https://imgs-sea-global.alipay.com/mgw.htm",sandbox:"https://imgs-sea-global.alipay.com/mgw.htm"},Ya="ANTOM_PAYMENT_WEB",Ga=(function(e){var t={};(e||(e=window.location.href),"undefined"==typeof URL)?e.replace(/([^?=&#]+)(=([^&#]*))?/g,(function(e,n,r,i){return void 0===i?"":(t[n]=decodeURIComponent(i).replace(/\+/g," "),t[n])})):new URL(e).searchParams.forEach((function(e,n){t[n]=e}));return t}()||{}).instanceId;function Fa(){return new Promise((function(e){window&&window.AlipayJSBridge?e():document.addEventListener("AlipayJSBridgeReady",(function(){return e()}),!1)}))}var Ka=function(){function e(t){u(this,e),y(this,"baseUrl",void 0),y(this,"headers",void 0),y(this,"method",void 0),y(this,"timeout",void 0),this.baseUrl=t.baseURL,this.headers=t.headers,this.method=t.method,this.timeout=t.timeout,this.request=this.request.bind(this)}return l(e,[{key:"request",value:function(e){var t=this;return new Promise((function(n,r){var i,o,a={url:e.url?t.baseUrl+e.url:t.baseUrl,method:null!==(i=e.method)&&void 0!==i?i:t.method,headers:b(b({},t.headers),e.headers),timeout:null!==(o=e.timeout)&&void 0!==o?o:t.timeout};e.data&&(a.data=function(e,t){try{var n=new WeakSet;return JSON.stringify(e,(function(e,t){if("object"===R(t)&&null!==t){if(n.has(t))return;n.add(t)}return t}))||t}catch(e){return t}}(e.data,"")),function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new Promise((function(t){Fa().then((function(){var r;(r=window.AlipayJSBridge).call.apply(r,[e].concat(n,[function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t([].concat(n))}]))}))}))}("httpRequest",b({instanceId:Ga},a)).then((function(e){var t=Array.isArray(e)?e.length>0?e[0]:null:e;if(!t)return r(new Error("timeout"));if(0!==t.status)return r(new Error("timeout"));var i={status:t.httpCode,data:Gr(t.data),headers:Va(t.headers)};n(i)}))}))}}]),e}();function Va(e){if(!e)return e;var t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];t[n]=Array.isArray(r)?r.length>0?r[0]:void 0:r}return t}var Wa=function(e){var t=Ha(e,"Result-Status")||Ha(e,"result-status","");if(!t)return null;if(2e3==+t)return{success:!1,errorCode:Rr.API_NOT_LOGIN,errorMessage:Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"}),resultStatus:t};if(4001==+t)return{success:!1,errorCode:Rr.API_GATEWAY_TIMEOUT,errorMessage:Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"}),resultStatus:t};if(1e3!=+t){var n=Ha(e,"Tips")||Ha(e,"tips","");return{success:!1,errorCode:Rr.API_GATEWAY_ERROR,errorMessage:n?decodeURIComponent(n):Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"}),resultStatus:t}}return null},qa={};function Ja(e,t,n){return Xa.apply(this,arguments)}function Xa(){return(Xa=A(w().mark((function e(t,n,r){var i,o,a,s,u,c,l,h,f,p,d,g,v,m,y,_,E,S,A,T,P,R,k;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(o=b(b(b({},qa),r),{},{envInfo:b(b({},qa.envInfo),null==r?void 0:r.envInfo),headers:b(b({},qa.headers),null==r?void 0:r.headers)}),a=Or(o.tracker,o.scope),s=Ir(o.tracker,o.scope),o.hostSign){e.next=10;break}e.next=8;break;case 8:console.warn("[Antom SDK] request hostSign is missing, please set hostSign in request options or global options.");case 9:o.hostSign="SG";case 10:return"WAP"===(u=b(b({terminalType:zr?"WAP":"WEB",browserInfo:{browserJavaScriptEnabled:!0,browserJavaEnabled:ja(),browserLanguage:navigator.language,browserUserAgent:navigator.userAgent,browserColorDepth:screen.colorDepth},deviceLanguage:navigator.language,screenWidth:screen.width,screenHeight:screen.height,timeZoneOffset:(new Date).getTimezoneOffset()},null==o?void 0:o.envInfo),{},{locale:Tr((null==o?void 0:o.locale)||(null==o||null===(i=o.envInfo)||void 0===i?void 0:i.locale))})).terminalType&&(u.osType=Hr?"IOS":"ANDROID"),c=[b(b({},n),{},{envInfo:u,extParams:b(b({},null==n?void 0:n.extParams),{},{refUrl:window.location.href})})],l=performance.now(),e.prev=14,h=Za(t,o),e.next=18,h({data:c});case 18:if(f=e.sent,p=f.data,d=f.headers,g=p||{},v=Ha(d,"Mgw-TraceId")||Ha(d,"mgw-traceid",""),g.traceId=v,!(m=Wa(d))){e.next=29;break}throw y=m.errorMessage,_=m.errorCode,new Nr(y,_,"SERVER_API","".concat(v," (").concat(t,")"));case 29:if(g.success){e.next=36;break}throw A=g.errorMessage||g.resultMessage||Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"}),T=g.errorCode||(null===(E=g.errorContext)||void 0===E||null===(E=E.errorStack)||void 0===E||null===(E=E[0])||void 0===E?void 0:E.errorName)||"API_SYSTEM_ERROR","true"!==(null===(S=g.extendInfo)||void 0===S?void 0:S.mulityLanguageMapping)&&(A=Ar.get({id:"server.".concat(T),defaultMessage:Ar.get({id:"event.callback.code.${errorCode}",defaultMessage:Ar.get({id:"ckp.paymentError.${errorCode}",defaultMessage:Ar.get({id:"page.wrong.error.message",defaultMessage:"System error, please retry later"})})})})),(P=new Lr(A,T,"SERVER_API","".concat(v," (").concat(t,")"))).response=g,P;case 36:return a.success(t,performance.now()-l,v),e.abrupt("return",g);case 40:if(e.prev=40,e.t0=e.catch(14),!Nr.isError(e.t0)){e.next=45;break}return a.error(t,performance.now()-l,e.t0.message,e.t0.code,e.t0.traceId),e.abrupt("return",Promise.reject(e.t0));case 45:return k=e.t0,s(k),e.abrupt("return",Promise.reject(new Nr(k.message,null!==(R=k.message)&&void 0!==R&&R.includes("timeout")?"API_TIMEOUT":"API_SYSTEM_ERROR","SYSTEM","WithoutTraceId (".concat(t,")"))));case 48:case"end":return e.stop()}}),e,null,[[14,40]])})))).apply(this,arguments)}function Za(e,t){var n,r=new Date,i=r.getTime()+60*r.getTimezoneOffset()*1e3,o=(null==t?void 0:t.env)||"prod",a=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n={"com.ipay.iexpcashier.sdkAction.query":"com.ipay.iopensandbox.sdk.paymentSession.query"},r="SDK_MOCK_SANDBOX";if(n[e]&&"light_sandbox"===t)return{appId:r,operationType:n[e]}}(e,o),s=(null==t?void 0:t.baseURL)||function(e,t){var n;return"pre"===t||"sandbox"===t&&"pre"===(null===(n=window)||void 0===n||null===(n=n.marmotInjectInfo)||void 0===n||null===(n=n.env)||void 0===n?void 0:n.toLocaleLowerCase())?{SG:"https://imgs-sea-pre.alipay.com/mgw.htm",US:"https://imgs-pre.alipay.com/mgw.htm",DE:"https://imgs-de-pre.alipay.com/mgw.htm",QK:"https://iopengw-qkgz99p.alipay.com/mgw.htm",ID:"https://imgs-id-pre.alipay.com/mgw.htm",SA:"https://imgs-sa-pre.alipay.com/mgw.htm"}[e||"SG"]:"prod"===t||"light_sandbox"===t||"sandbox"===t?{SG:"https://imgs-sea-global.alipay.com/mgw.htm",US:"https://imgs-na-global.alipay.com/mgw.htm",DE:"https://imgs-de-global.alipay.com/mgw.htm",QK:"https://imgs-qk.alipay.com/mgw.htm",ID:"https://imgs-id.alipay.com/mgw.htm",SA:"https://imgs-sa.alipay.com/mgw.htm"}[e||"SG"]:void 0}(null==t?void 0:t.hostSign,o)||za[o],u=b(y(y(y(y(y(y(y(y({appId:(null==t?void 0:t.appId)||(null==a?void 0:a.appId)||Ya,workspaceId:"pre"===(null==t?void 0:t.env)?"pre":"default"},"x-cors-".concat(Ya.toLowerCase(),"-default"),"1"),"version","2.0"),"sofa-group-name",null==t?void 0:t.groupId),"Operation-Type",(null==a?void 0:a.operationType)||e),"Client-Time",i),"tntInstId","ALIPW3SG"),"x-mago-timeout",(null==t?void 0:t.timeout)||15e3),"sdk-version",(null==t?void 0:t.sdkVersion)||"2.0.21"),null==t?void 0:t.headers);"dev"!==o&&delete u["sofa-group-name"],"sandbox"===o&&(u["load-test"]=!0,u.sofaPenAttrs="instMock=O&loadMode=2");var c,l=null!==(n=null==t?void 0:t.timeout)&&void 0!==n?n:15e3,h=Object.entries(u).filter((function(e){return void 0!==e[1]&&null!==e[1]&&"object"!==R(e[1])})).reduce((function(e,t){var n=P(t,2),r=n[0],i=n[1];return e[r]=String(i),e}),{}),f={baseURL:s,timeout:l,headers:u},p=null;"app"===qa.appType?p=new Ka({baseURL:s,method:"POST",timeout:l,headers:h}):p=Ua.create(b(b({},f),{},{withCredentials:null===(c=null==t?void 0:t.withCredentials)||void 0===c||c,method:(null==t?void 0:t.method)||"POST"}));return p.request}Ja.setGlobalOptions=function(e){Object.assign(qa,e)};"".concat(window.location.origin,"/elements/src/pages");var Qa=Fr,$a=function(){try{return"undefined"!=typeof window&&"true"===window.localStorage.getItem("antom-web-checkout-v2_modern_web")}catch(e){return!1}},es=function(e){var t;if(!e)return{modernWeb:!1};var n=Qa(e),r=!(null==n||null===(t=n.flowSwitchTags)||void 0===t||!t.split(",").includes("elementV3"));return{modernWeb:r||$a()}};function ts(e){return e}var ns=function(e){return es(e).modernWeb},rs=n(5225),is=n(2242),os=n(8994);function as(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return os.apply(void 0,[{},e].concat(n))}var ss=new he({appId:"180020050100012557",performance:!1,error:!1,env:"PROD",compactExtraInfo:!0}),us="7981",cs=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return function(t){ss.log(b({code:"".concat(us).concat(e)},t))}},ls=cs(),hs=cs("event"),fs=cs("mount"),ps=cs("handshake"),ds=cs("merchant"),gs=(cs("element"),function(e,t,n,r){var i;if("ERROR"===e){var o=r||{};ls({msg:o.code||n,d1:t,d2:o.reason,d3:o.stack,d4:o.traceId,d5:o.operationType,d6:n})}else{if(n.includes(":HOST:")||n.includes(":WEBAPP:")){var a=n.split(":"),s=P(a,3),u=s[0],c=s[1],l=s[2];hs({msg:l,d1:t,d2:u,d3:c,d4:JSON.stringify(r),d5:"无",d6:e})}}null===(i=window.sdkDebugger)||void 0===i||i.log(e,t,n,r)}),vs=function(e){if(e){var t=function(e){var t=e.message,n=e.traceId,r=e.code,i=e.source,o=e.stack,a=e.reason;if("SERVER_API"===e.source){var s=(null==n?void 0:n.match(/([a-z0-9\sA-Z]*)(\s*\(([a-zA-Z0-9\.]*)\))?/))||[],u=P(s,4),c=(u[0],u[1]),l=(u[2],{code:r,source:i,message:t,operationType:u[3],traceId:(null==c?void 0:c.replace(/\s/g,""))||"无traceID",stack:o,reason:a});return JSON.parse(JSON.stringify(l))}return e}(O.isError(e)?e.toJSON():e);gs("ERROR",t.source,t.operationType||t.message||"Unknown Error",t)}},ms=function(e){d(n,e);var t=v(n);function n(){var e;u(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),y(f(e),"name","SDKInternalError"),e}return l(n)}(O),ys=function(e){d(n,e);var t=v(n);function n(e){return u(this,n),t.call(this,"HOST",e)}return l(n,[{key:"_transferReceivePort",value:function(e){rs(is(n.prototype),"_transferReceivePort",this).call(this,e)}},{key:"_addPort",value:function(e){rs(is(n.prototype),"_addPort",this).call(this,e)}},{key:"_transferSendPort",value:function(e){rs(is(n.prototype),"_transferSendPort",this).call(this,e)}},{key:"setTarget",value:function(e){rs(is(n.prototype),"setTarget",this).call(this,e)}},{key:"setDebugCallback",value:function(){for(var e,t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];(e=rs(is(n.prototype),"setDebugCallback",this)).call.apply(e,[this].concat(r))}}],[{key:"getGlobalBridge",value:function(){return se.getGlobalBridge("HOST")}}]),n}(se),_s=function(e){d(n,e);var t=v(n);function n(e,r,i){var o;return u(this,n),o=t.call(this,e,r,i||"SDK_USAGE"),y(f(o),"name","MountError"),o}return l(n)}(ms),bs=function(e){return new ms("Element destroyed, previous status: ".concat(e),"ELEMENT_INSTANCE_DESTROYED","SDK_USAGE")},Es=function(){function e(t,n){u(this,e),y(this,"name",void 0),y(this,"_elementMode",void 0),y(this,"_isMainElement",void 0),y(this,"config",void 0),y(this,"bridge",void 0),y(this,"hooks",{}),y(this,"iframe",null),y(this,"status",void 0),y(this,"cachedSend",[]),y(this,"submitPromise",void 0),this.config=n,this._isMainElement=n.isMainElement,this._elementMode=n.elementMode,this.name=t,this.bridge=new ys(t),this.bridge.setOrigin(n.targetOrigin),n.trackId&&ss.setTrackId(n.trackId),this.config.debug&&this.bridge.setDebugCallback((function(e,t){var n,r;e.type.endsWith(ne.UPDATE_CONFIG)||e.type.endsWith(ne.HEIGHT_UPDATE)||(e.type.endsWith(ne.MESSAGE)?gs(null===(n=e.payload)||void 0===n?void 0:n.type,"APP_RUNTIME",e.type,null===(r=e.payload)||void 0===r?void 0:r.message):e.type.endsWith(ne.ERROR)&&"IN"===t?vs(e.payload):gs("INFO","OUT"===t?"SDK_INTERNAL":"APP_RUNTIME",e.type,e.payload))})),this.status="initialized"}var t,n,r,i,o;return l(e,[{key:"submit",value:function(e){throw new ms("This element not support submit","NOT_SUPPORT_SUBMIT","SDK_USAGE")}},{key:"setup",value:(o=A(w().mark((function e(){return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",void 0);case 1:case"end":return e.stop()}}),e)}))),function(){return o.apply(this,arguments)})},{key:"_setup",value:(i=A(w().mark((function e(){var t,n,r,i,o=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(t=function(){return"destroyed"===o.status})()){e.next=3;break}return e.abrupt("return");case 3:return n=function(){},r=new Promise((function(e,t){n=o._addHook("ondestroy",(function(e){return t(bs(e))}))})),i=Promise.resolve().then(A(w().mark((function e(){var n;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!t()){e.next=2;break}return e.abrupt("return");case 2:return e.next=4,o.setup();case 4:return n=e.sent,e.abrupt("return",t()?void 0:n);case 6:case"end":return e.stop()}}),e)})))),e.prev=6,e.next=9,Promise.race([i,r]);case 9:return e.abrupt("return",e.sent);case 10:return e.prev=10,t()||n(),e.finish(10);case 13:case"end":return e.stop()}}),e,null,[[6,,10,13]])}))),function(){return i.apply(this,arguments)})},{key:"is",value:function(e){return this.name.startsWith(e.elementType)}},{key:"mount",value:(r=A(w().mark((function e(t){var n,r,i,o,a=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if("initialized"===this.status||"unmounted"===this.status){e.next=4;break}throw n=new _s({message:"element status is ".concat(this.status,", can not mount again"),params:{status:this.status}},"MOUNT_NOT_SUPPORT"),vs(n),n;case 4:return r=Date.now(),i=X((function(){return Promise.all([a._setup(),a._mount(t)])}),15e3,new _s("Mount timeout","MOUNT_TIMEOUT","SYSTEM")),o=Q((function(){fs({msg:a.name,d1:"用户退出页面",m1:0,m2:Math.round(Date.now()-r),m3:a.isMainElement?1:0,m4:a.isSingleMode?1:0})})),e.abrupt("return",i().then((function(e){var t=P(e,1)[0];ds({msg:a.name,d1:(null==t?void 0:t.merchantId)||"未配置的商户"}),fs({msg:a.name,d1:"挂载成功",m1:1,m2:Math.round(Date.now()-r),m3:a.isMainElement?1:0,m4:a.isSingleMode?1:0}),a.bridge.send(ne.HANDSHAKE,as(a.config.appConfig,t||{}))})).catch((function(e){"destroyed"!==a.status&&a.unmount();var t=ms.unificationError(e);throw fs({msg:a.name,d1:"挂载失败",d2:t.code,d3:t.reason,m1:0,m2:Math.round(Date.now()-r),m3:a.isMainElement?1:0,m4:a.isSingleMode?1:0}),vs(t),t})).finally((function(){o()})));case 8:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})},{key:"_mount",value:(n=A(w().mark((function e(t){var n=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise(function(){var e=A(w().mark((function e(r,i){var o,a,s,u,c,l,h,f,p;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n.isMainElement||!n.isSingleMode){e.next=2;break}return e.abrupt("return",i(new _s({message:"".concat(n.name," element can not be used with single mode"),params:{elementName:n.name}},"MOUNT_NOT_MAINELEMENT_WITH_SINGLE_MODE")));case 2:if(e.prev=2,t){e.next=5;break}return e.abrupt("return",i(new _s("container missing","MOUNT_MISSING_CONTAINER")));case 5:o=n.config.appUrl,a=new URL(n.config.appUrl),s=[["origin",window.location.origin],["locale",n.config.locale]].concat(C(n.config.trackId?[["track_id",n.config.trackId]]:[]));try{s.forEach((function(e){var t=P(e,2),n=t[0],r=t[1];return a.searchParams.set(n,r)})),o=a.toString()}catch(e){u=o.includes("?")?"&":"?",c=s.map((function(e){var t=P(e,2),n=t[0],r=t[1];return"".concat(n,"=").concat(encodeURIComponent(r))})).join("&"),o="".concat(o).concat(u).concat(c)}(l=t.querySelector("#sdk-loading"))&&(l.style.display=""),n.status="mounting",n.iframe||(n.iframe=document.createElement("iframe"),n.iframe.src=o,n.iframe.style.width="100%",n.iframe.style.border="none",n.iframe.style.height="0",n.iframe.style.borderRadius="inherit",n.iframe.style.transition="height 0.3s ease",n.iframe.style.colorScheme=null!==(h=n.config.colorScheme)&&void 0!==h?h:"light dark",n.iframe.allow="payment",n.bridge.on(ne.HEIGHT_UPDATE,(function(e){n.iframe&&(n.iframe.style.height="".concat(e,"px"))}))),f=Date.now(),p=n._addHook("ondestroy",(function(e){i(bs(e))})),n.bridge.once(ne.READY_HANDSHAKE,(function(){var e;if(l&&(l.style.display="none"),"mounted"!==n.status&&"ready"!==n.status){if(null===(e=n.iframe)||void 0===e||!e.contentWindow)return r();gs("INFO","SYSTEM","Iframe ".concat(n.name," loaded, initiating handshake...")),n.status="mounted",n.bridge.setTarget(n.iframe.contentWindow);var t=Date.now();n.bridge.once(ne.HANDSHAKE_ACK,(function(e){n.status="ready",n.cachedSend.length&&(n.cachedSend.forEach((function(e){var t=e.type,r=e.payload;n.bridge.send(t,r)})),n.cachedSend=[]),ps({msg:n.name,d1:(null==e?void 0:e.version)||"未知版本",m1:Math.round(Date.now()-t),m2:1,m3:Math.round(Date.now()-f)})})),p(),r()}else p()})),n.iframe.onerror=function(e){i(new _s("Iframe load error: ".concat(e),"MOUNT_IFRAME_LOAD_ERROR","SYSTEM"))},t.appendChild(n.iframe),e.next=24;break;case 21:e.prev=21,e.t0=e.catch(2),i(new _s("Initialization crashed: ".concat(e.t0.message),"MOUNT_INITIAL_FAILED","SDK_INTERNAL"));case 24:case"end":return e.stop()}}),e,null,[[2,21]])})));return function(t,n){return e.apply(this,arguments)}}()));case 1:case"end":return e.stop()}}),e)}))),function(e){return n.apply(this,arguments)})},{key:"updateConfig",value:(t=A(w().mark((function e(t){var n,r,i,o=this;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,"destroyed"!==this.status){e.next=3;break}throw new ms("Element already destroyed, cannot update destroyed SDK instance","ELEMENT_INSTANCE_DESTROYED","SDK_USAGE");case 3:if("ready"===this.status){e.next=5;break}throw new ms({message:"Element is { status }, it is not ready, cannot update config",params:{status:this.status}},"UPDATE_CONFIG_NOT_READY","SDK_USAGE");case 5:return this.config.appConfig=as(this.config.appConfig,t),gs("INFO","SDK_USAGE","Updating configuration via API",t),n=function(){},r=X((function(){return new Promise((function(e){n=o.bridge.once(ne.UPDATE_CONFIG_REPLY,(function(t){e(t)})),o.bridge.send(ne.UPDATE_CONFIG,{merged:o.config.appConfig,updated:t})}))}),3e3,new ms("Update config timeout","UPDATE_CONFIG_TIMEOUT","SYSTEM")),e.abrupt("return",r().catch((function(e){return n(),{error:ms.unificationError(e).toJSON()}})));case 12:return e.prev=12,e.t0=e.catch(0),i=ms.unificationError(e.t0),e.abrupt("return",Promise.resolve({error:i.toJSON()}));case 16:case"end":return e.stop()}}),e,this,[[0,12]])}))),function(e){return t.apply(this,arguments)})},{key:"unmount",value:function(){"mounted"===this.status||"ready"===this.status?(this.status="unmounted",this.iframe&&this.iframe.parentNode&&(this.iframe.style.height="0",this.iframe.parentNode.removeChild(this.iframe))):gs("WARN","SDK_USAGE","element status is ".concat(this.status,", can not unmount, please check the usage. only mounted or ready status can unmount"))}},{key:"isSingleMode",get:function(){return"SINGLE"===this._elementMode}},{key:"on",value:function(e,t){this.bridge.on(e,t)}},{key:"send",value:function(e,t){"destroyed"!==this.status?"ready"===this.status?this.bridge.send(e,t):this.cachedSend.push({type:e,payload:t}):vs(new ms("element status is ".concat(this.status,", can not send message"),"ELEMENT_INSTANCE_DESTROYED","SDK_USAGE"))}},{key:"_addPort",value:function(e){!this.isSingleMode&&this.isMainElement&&this.bridge._addPort(e)}},{key:"_transferReceivePort",value:function(e){!this.isSingleMode&&this.isMainElement&&this.bridge._transferReceivePort(e)}},{key:"_transferSendPort",value:function(e){this.isSingleMode||this.isMainElement||this.bridge._transferSendPort(e)}},{key:"_submit",value:function(e){var t=this;return"HOST"!==this.bridge.mode?Promise.reject(new Error("submit method only available in HOST mode")):(this.submitPromise||(this.submitPromise=new Promise((function(n){t.send(ne.SUBMIT,e),t.bridge.once(ne.SUBMIT_REPLY,(function(e){n(e)}))})).finally((function(){t.submitPromise=void 0}))),this.submitPromise)}},{key:"destroy",value:function(){var e,t=this;if("destroyed"!==this.status){if(null===(e=this.hooks.ondestroy)||void 0===e||e.forEach((function(e){return e(t.status)})),this.hooks={},this.bridge.destroy(),"mounted"===this.status||"ready"===this.status)this.unmount();else{var n,r=null===(n=this.iframe)||void 0===n?void 0:n.parentNode;r&&r.removeChild(this.iframe)}this.status="destroyed"}else gs("WARN","SDK_USAGE","element status is ".concat(this.status,", can not destroy, please check the usage. only mounted or ready status can destroy"))}},{key:"isMainElement",get:function(){return this._isMainElement}},{key:"_addHook",value:function(e,t){var n,r=this;return this.hooks[e]||(this.hooks[e]=[]),null===(n=this.hooks[e])||void 0===n||n.push(t),function(){var n;r.hooks[e]=null===(n=r.hooks[e])||void 0===n?void 0:n.filter((function(e){return e!==t}))}}}]),e}();y(Es,"elementType",void 0);E()(E()(E()({},kr),{GENERATE_ELEMENT_KEY_FAILED:"GENERATE_ELEMENT_KEY_FAILED",ELEMENT_INIT_FAILED:"ELEMENT_INIT_FAILED",MOUNT_TIMEOUT:"MOUNT_TIMEOUT",MOUNT_MISSING_CONTAINER:"MOUNT_MISSING_CONTAINER",MOUNT_IFRAME_LOAD_ERROR:"MOUNT_IFRAME_LOAD_ERROR",MOUNT_NOT_MAINELEMENT_WITH_SINGLE_MODE:"MOUNT_NOT_MAINELEMENT_WITH_SINGLE_MODE",MOUNT_NOT_SUPPORT:"MOUNT_NOT_SUPPORT",MOUNT_INITIAL_FAILED:"MOUNT_INITIAL_FAILED",ELEMENT_INSTANCE_DESTROYED:"ELEMENT_INSTANCE_DESTROYED",ELEMENT_DEFINE_ERROR:"ELEMENT_DEFINE_ERROR",ELEMENT_ALREADY_REGISTERED:"ELEMENT_ALREADY_REGISTERED",CANNOT_CREATE_SAME_ELEMENT_TWICE:"CANNOT_CREATE_SAME_ELEMENT_TWICE",GROUPS_ONLY_ONE_MAIN_ELEMENT:"GROUPS_ONLY_ONE_MAIN_ELEMENT",GROUPS_NOT_FOUND_MAIN_ELEMENT:"GROUPS_NOT_FOUND_MAIN_ELEMENT",NOT_SUPPORT_ELEMENT:"NOT_SUPPORT_ELEMENT",NOT_SUPPORT_SUBMIT:"NOT_SUPPORT_SUBMIT",UPDATE_CONFIG_TIMEOUT:"UPDATE_CONFIG_TIMEOUT",UPDATE_CONFIG_NOT_READY:"UPDATE_CONFIG_NOT_READY",INVALID_MODAL_URL:"INVALID_MODAL_URL",LOAD_DEBUGGER_FAILED:"LOAD_DEBUGGER_FAILED"}),{},{NOT_FIND_MAINELEMENT:"NOT_FIND_MAINELEMENT",SESSION_DATA_INVALID:"SESSION_DATA_INVALID",SDK_LAUNCH_PAYMENT_APP_ERROR:"SDK_LAUNCH_PAYMENT_APP_ERROR",PARAM_INVALID:"PARAM_INVALID",CHANNEL_CLIENT_ID_QUERY_TIMEOUT:"CHANNEL_CLIENT_ID_QUERY_TIMEOUT",CHANNEL_CLIENT_ID_MISSING:"CHANNEL_CLIENT_ID_MISSING",CHANNEL_CLIENT_ID_QUERY_FAILED:"CHANNEL_CLIENT_ID_QUERY_FAILED",CHANNEL_CLIENT_ID_QUERY_ERROR:"CHANNEL_CLIENT_ID_QUERY_ERROR",CHECKOUT_NOT_READY:"CHECKOUT_NOT_READY",PAYMENT_IN_PROGRESS:"PAYMENT_IN_PROGRESS",AMOUNT_VALUE_EMPTY:"AMOUNT_VALUE_EMPTY",AMOUNT_VALUE_INVALID:"AMOUNT_VALUE_INVALID"});var ws=function(e){g()(n,e);var t=m()(n);function n(){var e;c()(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),_()(p()(e),"name","AntomSDKError"),e}return h()(n)}(Lr),Ss={default:{theme:"light",backgroundColor:"#ffffff"},light:{theme:"light",backgroundColor:"#ffffff"},night:{theme:"dark",backgroundColor:"#141935"},agateGreen:{theme:"dark",backgroundColor:"#344343"},nostalgicGray:{theme:"light",backgroundColor:"#e8e8e8"},gamingPurple:{theme:"dark",backgroundColor:"#070b29"},cherryBlossomPink:{theme:"light",backgroundColor:"#FFFCFD"}};function As(e,t){var n;if(!e)throw new ws("sessionData is required","SESSION_DATA_INVALID","SDK_USAGE");gs("INFO","SDK_USAGE","Setup called with sessionData:",{sessionData:e});var r=Qa(e);if(!r)throw new ws("Failed to parse sessionData, please check the sessionData","SESSION_DATA_INVALID","SDK_USAGE");var i=null===(n=r.paymentSessionConfig)||void 0===n?void 0:n.productScene;if(t&&i!==t)throw new ws("Invalid productScene in sessionData, expected ".concat(t,", but get ").concat(i,", please check the sessionData is correct?"),"SESSION_DATA_INVALID","SDK_USAGE");return r}var Ts="ams-popup",Ps=300,Rs="ams-component-popup-loading",ks="\n .".concat(Ts,"modal {\n /* 添加弹窗样式 */\n background-color: #fff;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 9999; /* 设置弹窗的层级为 9999 */\n overflow: hidden;\n }\n .").concat(Ts,"modal-mobile{\n background-color: #fff;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\n position: fixed;\n bottom: 0;\n left: 0%;\n z-index: 9999; /* 设置弹窗的层级为 9999 */\n overflow: hidden;\n }\n\n .").concat(Ts,"overlay {\n /* 添加蒙层样式 */\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0.4);\n z-index: 999;\n }\n\n .").concat(Ts,"fadeIn {\n /* 添加淡入动画 */\n animation: fadeIn ").concat(Ps,"ms;\n animation-fill-mode: forwards;\n }\n\n .").concat(Ts,"fadeOut {\n /* 添加淡出动画 */\n animation: fadeOut ").concat(Ps,"ms;\n animation-fill-mode: forwards;\n }\n\n .").concat(Ts,"-drawer-enter {\n animation: slideIn ").concat(Ps,"ms forwards;\n }\n\n @keyframes slideIn {\n from {\n transform: translateY(100%); /* 滑入时在视口底部外 */\n opacity: 0; /* 初始透明度为 0 */\n }\n to {\n transform: translateY(0); /* 滑入结束时在原位置 */\n opacity: 1; /* 结束时透明度为 1 */\n }\n }\n\n /* 抽屉从底部滑出 */\n .").concat(Ts,"-drawer-exit {\n animation: slideOut ").concat(Ps,'ms forwards;\n }\n\n @keyframes slideOut {\n from {\n transform: translateY(0); /* 滑出时从当前位置开始 */\n opacity: 1; /* 初始透明度为 1 */\n }\n to {\n transform: translateY(100%); /* 滑出结束时在视口底部外 */\n opacity: 0; /* 结束时透明度为 0 */\n }\n }\n\n /* 定义淡入动画 */\n @keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n\n @-webkit-keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n\n @-moz-keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n\n /* 定义淡出动画 */\n @keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n }\n\n @-webkit-keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n }\n\n @-moz-keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n }\n\n\n.ams-component-popup-loading {\n width: 0.8em;\n height:0.8em;\n border-radius: 8px;\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 1001;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n}\n\n.ams-component-popup-loading .line {\n width: 40px;\n height: 40px;\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n.ams-component-popup-loading .line div {\n position: absolute;\n left: 17.67px;\n top: 0;\n width: 5.33px;\n height: 40px;\n}\n\n.ams-component-popup-loading .line div:before,\n.ams-component-popup-loading .line div:after {\n content: \'\';\n display: block;\n height: 13.33px;\n background: black;\n border-radius: 5.3px;\n}\n.ams-component-popup-loading .line div:after {\n margin-top: 13.33px;\n}\n\n.ams-component-popup-loading .line div:nth-child(2) {\n -webkit-transform: rotate(45deg);\n}\n\n.ams-component-popup-loading .line div:nth-child(3) {\n -webkit-transform: rotate(90deg);\n}\n\n.ams-component-popup-loading .line div:nth-child(4) {\n -webkit-transform: rotate(135deg);\n}\n\n/** 加载动画 **/\n@-webkit-keyframes load {\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(4):before {\n -webkit-animation: load 1s linear 0s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(3):before {\n -webkit-animation: load 1s linear 0.125s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(2):before {\n -webkit-animation: load 1s linear 0.25s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(1):before {\n -webkit-animation: load 1s linear 0.375s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(4):after {\n -webkit-animation: load 1s linear 0.5s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(3):after {\n -webkit-animation: load 1s linear 0.675s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(2):after {\n -webkit-animation: load 1s linear 0.75s infinite;\n}\n\n[dir="rtl"] .ams-component-popup-loading .line div:nth-child(1):after {\n -webkit-animation: load 1s linear 0.875s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(1):before {\n -webkit-animation: load 1s linear 0s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(2):before {\n -webkit-animation: load 1s linear 0.125s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(3):before {\n -webkit-animation: load 1s linear 0.25s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(4):before {\n -webkit-animation: load 1s linear 0.375s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(1):after {\n -webkit-animation: load 1s linear 0.5s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(2):after {\n -webkit-animation: load 1s linear 0.675s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(3):after {\n -webkit-animation: load 1s linear 0.75s infinite;\n}\n\n.ams-component-popup-loading .line div:nth-child(4):after {\n -webkit-animation: load 1s linear 0.875s infinite;\n}\n\n.ams-component-popup-loading-logo {\n width: 0.44em;\n height: 0.44em;\n -webkit-transform:rotate(360deg);\n transform:rotate(360deg);\n -webkit-transition:-webkit-transform 1s linear;\n transition:transform 1s linear;\n animation: ams-component-loading-logo 1s linear infinite;\n}\n'),Ls=function(e,t){!function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light",t="\n .ams-component-popup-loading .line div:before,\n .ams-component-popup-loading .line div:after {\n background: ".concat("light"===e?"#000000":"#ffffff"," !important;\n }"),n=document.createElement("style");n.innerHTML=t,document.head.appendChild(n)}(e);var n=document.createElement("div");return null==n||n.classList.add(Rs),n.id=Rs,n.innerHTML='<div class="line"><div></div><div></div><div></div><div></div></div><span id="text" style="font-size: 16px;position:absolute;bottom: 0;white-space: nowrap">'.concat(t||"","</span>"),n.style.fontSize="".concat(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:390,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:130,n=document.documentElement.clientWidth,r=Yr?t:100*n/e;return Math.min(r,t)}(),"px"),n};var Ns=function(e){var t=e.mode,n=e.url,r=e.loadingConfig,i=e.showClose,o=void 0===i||i,a=e.hideCloseWhenLoaded,s=void 0===a||a,u=e.onClose,c=e.textDirection,l=void 0===c?"ltr":c,h=e.showLoading,f=void 0===h||h,p=document.createElement("div");p.classList.add("".concat(Ts,"overlay"),"".concat(Ts,"fadeIn"));var d=document.createElement("div");"desktop"===t?(d.classList.add("".concat(Ts,"modal"),"".concat(Ts,"fadeIn")),d.style.width="656px",d.style.height="620px",d.style.borderRadius="12px"):(d.classList.add("".concat(Ts,"modal-mobile"),"".concat(Ts,"-drawer-enter")),d.style.width="100%",d.style.height="80vh",d.style.borderRadius="12px 12px 0 0"),d.setAttribute("dir",l);var g=function(e,t,n){return function(){t&&(t.classList.remove("".concat(Ts,"fadeIn")),t.classList.add("".concat(Ts,"fadeOut")),"desktop"===e?(n.classList.remove("".concat(Ts,"fadeIn")),n.classList.add("".concat(Ts,"fadeOut"))):(n.classList.remove("".concat(Ts,"-drawer-enter")),n.classList.add("".concat(Ts,"-drawer-exit"))),setTimeout((function(){var e,r;null===(e=t.parentNode)||void 0===e||e.removeChild(t),null===(r=n.parentNode)||void 0===r||r.removeChild(n)}),Ps))}}(t,p,d),v=document.createElement("iframe");v.src=n,v.style.border="none",v.style.width="100%",v.style.height="100%";var m,y=r||{},_=y.theme,b=void 0===_?"light":_,E=y.backgroundColor,w=void 0===E?"#ffffff":E,A=Ls(b);if(v.addEventListener("load",(function e(){d.removeChild(A),v.removeEventListener("load",e)})),o){var P=function(e){var t=e.onClose,n=e.textDirection,r=document.createElement("div");r.style.position="absolute","rtl"===n?r.style.left="16px":r.style.right="16px",r.style.top="23px",r.style.cursor="pointer";var i=document.createElementNS("http://www.w3.org/2000/svg","svg");i.setAttribute("width","16"),i.setAttribute("height","16"),i.setAttribute("viewBox","0 0 16 16"),i.setAttribute("fill","none");var o=document.createElementNS("http://www.w3.org/2000/svg","path");return o.setAttribute("fill-rule","evenodd"),o.setAttribute("clip-rule","evenodd"),o.setAttribute("d","M13.0449 2.99894L12.9494 2.91165L12.8685 2.85222L12.7802 2.7996C12.3611 2.57499 11.8556 2.64328 11.5228 2.9763L7.99909 6.50088L4.48854 2.99028L4.44701 2.95034C4.0098 2.57169 3.38048 2.57202 2.99838 2.9525L2.92363 3.03297L2.85175 3.12897L2.79916 3.21735C2.57471 3.63642 2.64292 4.14198 2.9757 4.47491L6.50186 8.00046L2.95226 11.5518C2.57141 11.9917 2.57173 12.6211 2.95197 13.0033L3.0324 13.078L3.12837 13.15L3.21674 13.2026C3.63573 13.4272 4.14123 13.3589 4.47407 13.0259L7.99909 9.49935L11.5474 13.0494C11.9944 13.4368 12.6238 13.4235 13.0212 13.0259L13.0922 12.9471L13.1559 12.8595C13.4298 12.4403 13.3789 11.8852 13.0211 11.5272L9.497 8.00115L13.0052 4.4915L13.07 4.4225C13.4304 4.00477 13.4199 3.37582 13.0449 2.99894Z"),o.setAttribute("fill","#ABB9CC"),i.appendChild(o),r.appendChild(i),r.onclick=t,r}({onClose:(m=!1,T()(S()().mark((function e(){var t,n;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!m){e.next=2;break}return e.abrupt("return");case 2:return null===(t=A.parentNode)||void 0===t||t.removeChild(A),d.removeChild(v),n=Ls(b,Ar.get({defaultMessage:"closing",id:"antom.common.closing"})),d.appendChild(n),m=!0,e.prev=7,e.next=10,null==u?void 0:u();case 10:return e.prev=10,m=!1,e.finish(10);case 13:g();case 14:case"end":return e.stop()}}),e,null,[[7,,10,13]])})))),textDirection:l});s&&v.addEventListener("load",(function e(){d.removeChild(P),v.removeEventListener("load",e)})),d.appendChild(P)}if(f){d.style.backgroundColor=w,v.style.backgroundColor=w;v.addEventListener("load",(function e(){var t;null===(t=A.parentNode)||void 0===t||t.removeChild(A),v.removeEventListener("load",e)})),d.appendChild(A)}d.appendChild(v);var R,k=document.getElementsByTagName("body")[0];return(R=document.createElement("style")).innerHTML=ks,document.head.appendChild(R),k.appendChild(p),k.appendChild(d),{iframe:v,destroy:g}};function Os(e){return Is.apply(this,arguments)}function Is(){return(Is=T()(S()().mark((function e(t){var n;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t;case 3:return n=e.sent,e.abrupt("return",{error:void 0,data:n});case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",{error:ws.unificationError(e.t0).toJSON(),data:void 0});case 10:case"end":return e.stop()}}),e,null,[[0,7]])})))).apply(this,arguments)}function Cs(e,t){return Ms.apply(this,arguments)}function Ms(){return(Ms=T()(S()().mark((function e(t,n){return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Ja("com.ipay.iexpfront.one.account.query",t,n));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Ds(e,t){return xs.apply(this,arguments)}function xs(){return(xs=T()(S()().mark((function e(t,n){return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Ja("com.ipay.iexpcashier.sdkAction.query",t,n));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var Bs="https://applepay.cdn-apple.com/jsapi/1.latest/apple-pay-sdk.js",Us=null;var Hs=function(){function e(t){c()(this,e),_()(this,"opts",void 0),_()(this,"session",null),_()(this,"settled",!1),_()(this,"phase","idle"),_()(this,"cancelReason",null),_()(this,"modalCloseHandler",null),_()(this,"_activePay",null),this.opts=t}var t,n;return h()(e,[{key:"startPay",value:(n=T()(S()().mark((function e(){var t=this;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._activePay){e.next=2;break}return e.abrupt("return",this._activePay);case 2:return this._activePay=this._startPayInternal().finally((function(){t._activePay=null})),e.abrupt("return",this._activePay);case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"_startPayInternal",value:(t=T()(S()().mark((function e(){var t,n,r,i,o,a,s,u=this;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this.settled=!1,this.phase="idle",this.cancelReason=null,(o=this.opts.paymentRequest).version&&Array.isArray(o.supportedNetworks)&&0!==o.supportedNetworks.length&&Array.isArray(o.merchantCapabilities)&&0!==o.merchantCapabilities.length&&o.countryCode&&o.currencyCode&&null!==(t=o.total)&&void 0!==t&&t.label&&null!==(n=o.total)&&void 0!==n&&n.amount){e.next=8;break}throw console.warn("[ApplePay] Required Apple Pay fields are missing"),{errorCode:"APPLE_PAY_MISSING_DATA"};case 8:return e.next=10,Us||(Us=new Promise((function(e){if(jr)return e(!1);if(window.ApplePaySession)return e(!0);var t=function(t){clearTimeout(n),t||(Us=null),e(t)},n=setTimeout((function(){console.warn("[ApplePay] Apple Pay SDK load timed out, will retry on next call"),t(!1)}),1e4),r=document.querySelector('script[src="'.concat(Bs,'"]'));if(r)return window.ApplePaySession?void t(!0):(r.addEventListener("load",(function(){return t(!0)})),void r.addEventListener("error",(function(){return t(!1)})));var i=document.createElement("script");i.src=Bs,i.onload=function(){return t(!0)},i.onerror=function(){return t(!1)},document.head.appendChild(i)})),Us);case 10:if(a=e.sent,s=window.ApplePaySession,a&&s){e.next=16;break}throw console.warn("[ApplePay] Apple Pay SDK not available on host"),{errorCode:"APPLE_PAY_NOT_SUPPORTED"};case 16:if(null!==(r=s.canMakePayments)&&void 0!==r&&r.call(s)&&null!==(i=s.supportsVersion)&&void 0!==i&&i.call(s,o.version)){e.next=20;break}throw console.warn("[ApplePay] canMakePayments=false (version=".concat(o.version,")")),{errorCode:"APPLE_PAY_NOT_SUPPORTED"};case 20:e.prev=20,this.session=new s(o.version,this.buildSessionParams()),e.next=29;break;case 24:throw e.prev=24,e.t0=e.catch(20),console.warn("[ApplePay] ApplePaySession constructor failed:",e.t0),{errorCode:"APPLE_PAY_NOT_SUPPORTED"};case 29:return e.abrupt("return",new Promise((function(e,t){var n=function(n){u.settled||(u.settled=!0,u.clearModalCloseListener(),n?t(n):e())};u.session.onvalidatemerchant=function(){var e=T()(S()().mark((function e(t){var r,i;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return u.phase="validating",e.prev=1,e.next=4,u.opts.callbacks.validateMerchant(null==t?void 0:t.validationURL);case 4:if(r=e.sent){e.next=7;break}throw{errorCode:"APPLE_PAY_PAYMENT_SESSION_REQUEST_FAILED"};case 7:u.phase="validated",u.session.completeMerchantValidation(r),e.next=21;break;case 11:if(e.prev=11,e.t0=e.catch(1),u.phase="idle",!u.settled){e.next=17;break}return u.safeAbort(),e.abrupt("return");case 17:i=(null===e.t0||void 0===e.t0?void 0:e.t0.errorCode)||"APPLE_PAY_PAYMENT_SESSION_REQUEST_FAILED",console.warn("[ApplePay] validateMerchant failed:",e.t0),n({errorCode:i}),u.safeAbort();case 21:case"end":return e.stop()}}),e,null,[[1,11]])})));return function(t){return e.apply(this,arguments)}}(),u.session.onpaymentauthorized=function(){var e=T()(S()().mark((function e(t){var r,i,o,a,c,l,h;return S()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(u.phase="authorizing",r=(null==t?void 0:t.payment)||{},i=r.token,o=r.billingContact,a=r.shippingContact,i){e.next=7;break}return u.safeComplete(s.STATUS_FAILURE),n({errorCode:"APPLE_PAY_TOKEN_ERROR"}),e.abrupt("return");case 7:return e.prev=7,e.next=10,u.opts.callbacks.onAuthorized({token:i,billingContact:o,shippingContact:a});case 10:(c=e.sent).success?(u.safeComplete(s.STATUS_SUCCESS),n()):("MERCHANT_CONFIRM_ABORT"===c.errorCode&&(u.cancelReason="MERCHANT_ABORT"),u.safeComplete(s.STATUS_FAILURE),l=c.errorCode||"APPLE_PAY_PAYMENT_SESSION_REQUEST_FAILED",c.errorMessage&&console.warn("[ApplePay] onAuthorized returned failure:",c.errorMessage),n({errorCode:l})),e.next=20;break;case 14:e.prev=14,e.t0=e.catch(7),u.safeComplete(s.STATUS_FAILURE),h=(null===e.t0||void 0===e.t0?void 0:e.t0.errorCode)||"APPLE_PAY_PAYMENT_SESSION_REQUEST_FAILED",console.warn("[ApplePay] onAuthorized threw:",e.t0),n({errorCode:h});case 20:case"end":return e.stop()}}),e,null,[[7,14]])})));return function(t){return e.apply(this,arguments)}}(),u.session.oncancel=function(){return"MERCHANT_ABORT"===u.cancelReason?(u.phase="idle",void n({errorCode:"MERCHANT_CONFIRM_ABORT"})):"validating"===u.phase?(u.phase="idle",void n({errorCode:"APPLE_PAY_PAYMENT_SESSION_REQUEST_FAILED"})):(u.phase,u.phase="idle",void n({errorCode:"APPLE_PAY_CANCEL"}))};try{u.session.begin()}catch(e){return console.warn("[ApplePay] ApplePaySession.begin() failed:",e),void n({errorCode:"APPLE_PAY_NOT_SUPPORTED"})}u.opts.enableModalCloseListener&&u.attachModalCloseListener((function(){u.safeAbort(),n({errorCode:"APPLE_PAY_CANCEL"})}))})));case 30:case"end":return e.stop()}}),e,this,[[20,24]])}))),function(){return t.apply(this,arguments)})},{key:"buildSessionParams",value:function(){var e=this.opts.paymentRequest,t={countryCode:e.countryCode,currencyCode:e.currencyCode,merchantCapabilities:e.merchantCapabilities,supportedNetworks:e.supportedNetworks,requiredBillingContactFields:e.requiredBillingContactFields,requiredShippingContactFields:e.requiredShippingContactFields,total:e.total};return e.lineItems&&e.lineItems.length>0&&(t.lineItems=e.lineItems),e.recurringPaymentRequest&&(t.recurringPaymentRequest=e.recurringPaymentRequest),t}},{key:"safeAbort",value:function(){try{var e,t;null===(e=this.session)||void 0===e||null===(t=e.abort)||void 0===t||t.call(e)}catch(e){}}},{key:"safeComplete",value:function(e){try{var t,n;null===(t=this.session)||void 0===t||null===(n=t.completePayment)||void 0===n||n.call(t,e)}catch(e){}}},{key:"attachModalCloseListener",value:function(e){var t,n=document.querySelector("apple-pay-modal"),r=(null==n||null===(t=n.shadowRoot)||void 0===t?void 0:t.querySelector(".modal-close-button"))||null;if(r){var i=function(){e()};r.addEventListener("click",i,{once:!0}),this.modalCloseHandler={el:r,fn:i}}}},{key:"clearModalCloseListener",value:function(){this.modalCloseHandler&&(this.modalCloseHandler.el.removeEventListener("click",this.modalCloseHandler.fn),this.modalCloseHandler=null)}}]),e}()}(),r}()}));