@jetthai/cuora 1.0.160 → 1.0.162

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 (56) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/bundle.cjs +14309 -0
  3. package/package.json +5 -1
  4. package/rollup.config.js +14 -0
  5. package/src/machine/activity/activity.js +1 -1
  6. package/src/machine/activity/continue_deposit_activity.js +1 -1
  7. package/src/machine/activity/deposit_activity.js +1 -1
  8. package/src/machine/activity/diamond_shop_activity_fc.js +1 -1
  9. package/src/machine/activity/diamond_shop_activity_vn.js +1 -1
  10. package/src/machine/activity/fafafa_activity.js +4 -2
  11. package/src/machine/activity/invite_friends_activity.js +1 -1
  12. package/src/machine/activity/mini_game_activity.js +1 -1
  13. package/src/machine/activity/ranking_activity.js +1 -1
  14. package/src/machine/activity/return_bonus_activity.js +4 -2
  15. package/src/machine/activity/specify_bets_activity.js +1 -1
  16. package/src/machine/activity/specify_turnover_activity.js +1 -1
  17. package/src/machine/activity/time_bomb_activity.js +1 -1
  18. package/src/machine/auth.js +4 -2
  19. package/src/machine/auth_otp.js +1 -1
  20. package/src/machine/auth_otp_v2.js +1 -1
  21. package/src/machine/auth_otp_v3.js +1 -1
  22. package/src/machine/bank_binding.js +1 -1
  23. package/src/machine/bonus.js +1 -1
  24. package/src/machine/common.js +6 -3
  25. package/src/machine/deposit/crypto.js +4 -2
  26. package/src/machine/deposit/deposit_fc.js +4 -2
  27. package/src/machine/deposit/direct.js +1 -1
  28. package/src/machine/deposit/loadcard_vn.js +1 -1
  29. package/src/machine/deposit/manual_vn.js +1 -1
  30. package/src/machine/deposit/qrcode_v2.js +29 -8
  31. package/src/machine/deposit/qrcode_vn.js +1 -1
  32. package/src/machine/error.js +1 -1
  33. package/src/machine/game.js +4 -2
  34. package/src/machine/game_favorite.js +1 -1
  35. package/src/machine/game_hot_new.js +1 -1
  36. package/src/machine/game_search.js +1 -1
  37. package/src/machine/inbox.js +1 -1
  38. package/src/machine/leaderboard.js +1 -1
  39. package/src/machine/merge.js +1 -1
  40. package/src/machine/payment_data.js +1 -1
  41. package/src/machine/reward.js +1 -1
  42. package/src/machine/reward_fc.js +1 -1
  43. package/src/machine/setting.js +1 -1
  44. package/src/machine/side.js +1 -1
  45. package/src/machine/user_info.js +1 -1
  46. package/src/machine/user_reset_password.js +1 -1
  47. package/src/machine/user_sign_up.js +1 -1
  48. package/src/machine/vip_table.js +1 -1
  49. package/src/machine/welcome.js +1 -1
  50. package/src/machine/withdraw_crypto.js +4 -2
  51. package/src/machine/withdraw_fc.js +1 -1
  52. package/src/machine/withdraw_vn.js +4 -2
  53. package/src/request/config.js +3 -1
  54. package/src/request/request.js +3 -1
  55. package/dist/index.js +0 -2
  56. package/dist/index.js.LICENSE.txt +0 -30
package/dist/index.js DELETED
@@ -1,2 +0,0 @@
1
- /*! For license information please see index.js.LICENSE.txt */
2
- var t={1924:(t,e,r)=>{var n=r(210),i=r(5559),o=i(n("String.prototype.indexOf"));t.exports=function(t,e){var r=n(t,!!e);return"function"==typeof r&&o(t,".prototype.")>-1?i(r):r}},5559:(t,e,r)=>{var n=r(8612),i=r(210),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||n.call(a,o),c=i("%Object.getOwnPropertyDescriptor%",!0),u=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(u)try{u({},"a",{value:1})}catch(t){u=null}t.exports=function(t){var e=s(n,a,arguments);if(c&&u){var r=c(e,"length");r.configurable&&u(e,"length",{value:1+l(0,t.length-(arguments.length-1))})}return e};var f=function(){return s(n,o,arguments)};u?u(t.exports,"apply",{value:f}):t.exports.apply=f},6489:(t,e)=>{e.Q=function(t,e){if("string"!=typeof t)throw new TypeError("argument str must be a string");for(var n={},o=e||{},s=t.split(i),c=o.decode||r,u=0;u<s.length;u++){var l=s[u],f=l.indexOf("=");if(!(f<0)){var p=l.substr(0,f).trim(),d=l.substr(++f,l.length).trim();'"'==d[0]&&(d=d.slice(1,-1)),null==n[p]&&(n[p]=a(d,c))}}return n},e.q=function(t,e,r){var i=r||{},a=i.encode||n;if("function"!=typeof a)throw new TypeError("option encode is invalid");if(!o.test(t))throw new TypeError("argument name is invalid");var s=a(e);if(s&&!o.test(s))throw new TypeError("argument val is invalid");var c=t+"="+s;if(null!=i.maxAge){var u=i.maxAge-0;if(isNaN(u)||!isFinite(u))throw new TypeError("option maxAge is invalid");c+="; Max-Age="+Math.floor(u)}if(i.domain){if(!o.test(i.domain))throw new TypeError("option domain is invalid");c+="; Domain="+i.domain}if(i.path){if(!o.test(i.path))throw new TypeError("option path is invalid");c+="; Path="+i.path}if(i.expires){if("function"!=typeof i.expires.toUTCString)throw new TypeError("option expires is invalid");c+="; Expires="+i.expires.toUTCString()}if(i.httpOnly&&(c+="; HttpOnly"),i.secure&&(c+="; Secure"),i.sameSite)switch("string"==typeof i.sameSite?i.sameSite.toLowerCase():i.sameSite){case!0:case"strict":c+="; SameSite=Strict";break;case"lax":c+="; SameSite=Lax";break;case"none":c+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return c};var r=decodeURIComponent,n=encodeURIComponent,i=/; */,o=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;function a(t,e){try{return e(t)}catch(e){return t}}},7648:t=>{var e="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";t.exports=function(t){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(e+o);for(var a,s=r.call(arguments,1),c=function(){if(this instanceof a){var e=o.apply(this,s.concat(r.call(arguments)));return Object(e)===e?e:this}return o.apply(t,s.concat(r.call(arguments)))},u=Math.max(0,o.length-s.length),l=[],f=0;f<u;f++)l.push("$"+f);if(a=Function("binder","return function ("+l.join(",")+"){ return binder.apply(this,arguments); }")(c),o.prototype){var p=function(){};p.prototype=o.prototype,a.prototype=new p,p.prototype=null}return a}},8612:(t,e,r)=>{var n=r(7648);t.exports=Function.prototype.bind||n},210:(t,e,r)=>{var n,i=SyntaxError,o=Function,a=TypeError,s=function(t){try{return o('"use strict"; return ('+t+").constructor;")()}catch(t){}},c=Object.getOwnPropertyDescriptor;if(c)try{c({},"")}catch(t){c=null}var u=function(){throw new a},l=c?function(){try{return u}catch(t){try{return c(arguments,"callee").get}catch(t){return u}}}():u,f=r(1405)(),p=Object.getPrototypeOf||function(t){return t.__proto__},d={},v="undefined"==typeof Uint8Array?n:p(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f?p([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":d,"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":d,"%AsyncIteratorPrototype%":d,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":d,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":f?p(p([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f?p((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f?p((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f?p(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":l,"%TypedArray%":v,"%TypeError%":a,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},h=function t(e){var r;if("%AsyncFunction%"===e)r=s("async function () {}");else if("%GeneratorFunction%"===e)r=s("function* () {}");else if("%AsyncGeneratorFunction%"===e)r=s("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var i=t("%AsyncGenerator%");i&&(r=p(i.prototype))}return y[e]=r,r},g={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=r(8612),b=r(7642),w=m.call(Function.call,Array.prototype.concat),x=m.call(Function.apply,Array.prototype.splice),S=m.call(Function.call,String.prototype.replace),k=m.call(Function.call,String.prototype.slice),O=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,_=/\\(\\)?/g,E=function(t){var e=k(t,0,1),r=k(t,-1);if("%"===e&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==e)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return S(t,O,(function(t,e,r,i){n[n.length]=r?S(i,_,"$1"):e||t})),n},A=function(t,e){var r,n=t;if(b(g,n)&&(n="%"+(r=g[n])[0]+"%"),b(y,n)){var o=y[n];if(o===d&&(o=h(n)),void 0===o&&!e)throw new a("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new a("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new a('"allowMissing" argument must be a boolean');var r=E(t),n=r.length>0?r[0]:"",o=A("%"+n+"%",e),s=o.name,u=o.value,l=!1,f=o.alias;f&&(n=f[0],x(r,w([0,1],f)));for(var p=1,d=!0;p<r.length;p+=1){var v=r[p],h=k(v,0,1),g=k(v,-1);if(('"'===h||"'"===h||"`"===h||'"'===g||"'"===g||"`"===g)&&h!==g)throw new i("property names with quotes must have matching quotes");if("constructor"!==v&&d||(l=!0),b(y,s="%"+(n+="."+v)+"%"))u=y[s];else if(null!=u){if(!(v in u)){if(!e)throw new a("base intrinsic for "+t+" exists, but the property is not available.");return}if(c&&p+1>=r.length){var m=c(u,v);u=(d=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:u[v]}else d=b(u,v),u=u[v];d&&!l&&(y[s]=u)}}return u}},1405:(t,e,r)=>{var n="undefined"!=typeof Symbol&&Symbol,i=r(5419);t.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&i()}},5419:t=>{t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e)return!1;if("[object Symbol]"!==Object.prototype.toString.call(e))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(e in t[e]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var n=Object.getOwnPropertySymbols(t);if(1!==n.length||n[0]!==e)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},7642:(t,e,r)=>{var n=r(8612);t.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},8552:(t,e,r)=>{var n=r(852)(r(5639),"DataView");t.exports=n},1989:(t,e,r)=>{var n=r(1789),i=r(401),o=r(7667),a=r(1327),s=r(1866);function c(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}c.prototype.clear=n,c.prototype.delete=i,c.prototype.get=o,c.prototype.has=a,c.prototype.set=s,t.exports=c},8407:(t,e,r)=>{var n=r(7040),i=r(4125),o=r(2117),a=r(7518),s=r(4705);function c(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}c.prototype.clear=n,c.prototype.delete=i,c.prototype.get=o,c.prototype.has=a,c.prototype.set=s,t.exports=c},7071:(t,e,r)=>{var n=r(852)(r(5639),"Map");t.exports=n},3369:(t,e,r)=>{var n=r(4785),i=r(1285),o=r(6e3),a=r(9916),s=r(5265);function c(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}c.prototype.clear=n,c.prototype.delete=i,c.prototype.get=o,c.prototype.has=a,c.prototype.set=s,t.exports=c},3818:(t,e,r)=>{var n=r(852)(r(5639),"Promise");t.exports=n},8525:(t,e,r)=>{var n=r(852)(r(5639),"Set");t.exports=n},8668:(t,e,r)=>{var n=r(3369),i=r(619),o=r(2385);function a(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new n;++e<r;)this.add(t[e])}a.prototype.add=a.prototype.push=i,a.prototype.has=o,t.exports=a},6384:(t,e,r)=>{var n=r(8407),i=r(7465),o=r(3779),a=r(7599),s=r(4758),c=r(4309);function u(t){var e=this.__data__=new n(t);this.size=e.size}u.prototype.clear=i,u.prototype.delete=o,u.prototype.get=a,u.prototype.has=s,u.prototype.set=c,t.exports=u},2705:(t,e,r)=>{var n=r(5639).Symbol;t.exports=n},1149:(t,e,r)=>{var n=r(5639).Uint8Array;t.exports=n},577:(t,e,r)=>{var n=r(852)(r(5639),"WeakMap");t.exports=n},4963:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,i=0,o=[];++r<n;){var a=t[r];e(a,r,t)&&(o[i++]=a)}return o}},4636:(t,e,r)=>{var n=r(2545),i=r(5694),o=r(1469),a=r(4144),s=r(5776),c=r(6719),u=Object.prototype.hasOwnProperty;t.exports=function(t,e){var r=o(t),l=!r&&i(t),f=!r&&!l&&a(t),p=!r&&!l&&!f&&c(t),d=r||l||f||p,v=d?n(t.length,String):[],y=v.length;for(var h in t)!e&&!u.call(t,h)||d&&("length"==h||f&&("offset"==h||"parent"==h)||p&&("buffer"==h||"byteLength"==h||"byteOffset"==h)||s(h,y))||v.push(h);return v}},9932:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}},2488:t=>{t.exports=function(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}},2908:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}},4865:(t,e,r)=>{var n=r(9465),i=r(7813),o=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){var a=t[e];o.call(t,e)&&i(a,r)&&(void 0!==r||e in t)||n(t,e,r)}},8470:(t,e,r)=>{var n=r(7813);t.exports=function(t,e){for(var r=t.length;r--;)if(n(t[r][0],e))return r;return-1}},9465:(t,e,r)=>{var n=r(8777);t.exports=function(t,e,r){"__proto__"==e&&n?n(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}},1848:t=>{t.exports=function(t,e,r,n){for(var i=t.length,o=r+(n?1:-1);n?o--:++o<i;)if(e(t[o],o,t))return o;return-1}},7786:(t,e,r)=>{var n=r(1811),i=r(327);t.exports=function(t,e){for(var r=0,o=(e=n(e,t)).length;null!=t&&r<o;)t=t[i(e[r++])];return r&&r==o?t:void 0}},8866:(t,e,r)=>{var n=r(2488),i=r(1469);t.exports=function(t,e,r){var o=e(t);return i(t)?o:n(o,r(t))}},4239:(t,e,r)=>{var n=r(2705),i=r(9607),o=r(2333),a=n?n.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?i(t):o(t)}},13:t=>{t.exports=function(t,e){return null!=t&&e in Object(t)}},9454:(t,e,r)=>{var n=r(4239),i=r(7005);t.exports=function(t){return i(t)&&"[object Arguments]"==n(t)}},939:(t,e,r)=>{var n=r(2492),i=r(7005);t.exports=function t(e,r,o,a,s){return e===r||(null==e||null==r||!i(e)&&!i(r)?e!=e&&r!=r:n(e,r,o,a,t,s))}},2492:(t,e,r)=>{var n=r(6384),i=r(7114),o=r(8351),a=r(6096),s=r(4160),c=r(1469),u=r(4144),l=r(6719),f="[object Arguments]",p="[object Array]",d="[object Object]",v=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,y,h,g){var m=c(t),b=c(e),w=m?p:s(t),x=b?p:s(e),S=(w=w==f?d:w)==d,k=(x=x==f?d:x)==d,O=w==x;if(O&&u(t)){if(!u(e))return!1;m=!0,S=!1}if(O&&!S)return g||(g=new n),m||l(t)?i(t,e,r,y,h,g):o(t,e,w,r,y,h,g);if(!(1&r)){var _=S&&v.call(t,"__wrapped__"),E=k&&v.call(e,"__wrapped__");if(_||E){var A=_?t.value():t,R=E?e.value():e;return g||(g=new n),h(A,R,r,y,g)}}return!!O&&(g||(g=new n),a(t,e,r,y,h,g))}},2958:(t,e,r)=>{var n=r(6384),i=r(939);t.exports=function(t,e,r,o){var a=r.length,s=a,c=!o;if(null==t)return!s;for(t=Object(t);a--;){var u=r[a];if(c&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++a<s;){var l=(u=r[a])[0],f=t[l],p=u[1];if(c&&u[2]){if(void 0===f&&!(l in t))return!1}else{var d=new n;if(o)var v=o(f,p,l,t,e,d);if(!(void 0===v?i(p,f,3,o,d):v))return!1}}return!0}},8458:(t,e,r)=>{var n=r(3560),i=r(5346),o=r(3218),a=r(346),s=/^\[object .+?Constructor\]$/,c=Function.prototype,u=Object.prototype,l=c.toString,f=u.hasOwnProperty,p=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(t){return!(!o(t)||i(t))&&(n(t)?p:s).test(a(t))}},8749:(t,e,r)=>{var n=r(4239),i=r(1780),o=r(7005),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,t.exports=function(t){return o(t)&&i(t.length)&&!!a[n(t)]}},7206:(t,e,r)=>{var n=r(1573),i=r(6432),o=r(6557),a=r(1469),s=r(9601);t.exports=function(t){return"function"==typeof t?t:null==t?o:"object"==typeof t?a(t)?i(t[0],t[1]):n(t):s(t)}},280:(t,e,r)=>{var n=r(5726),i=r(6916),o=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return i(t);var e=[];for(var r in Object(t))o.call(t,r)&&"constructor"!=r&&e.push(r);return e}},313:(t,e,r)=>{var n=r(3218),i=r(5726),o=r(3498),a=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return o(t);var e=i(t),r=[];for(var s in t)("constructor"!=s||!e&&a.call(t,s))&&r.push(s);return r}},1573:(t,e,r)=>{var n=r(2958),i=r(1499),o=r(2634);t.exports=function(t){var e=i(t);return 1==e.length&&e[0][2]?o(e[0][0],e[0][1]):function(r){return r===t||n(r,t,e)}}},6432:(t,e,r)=>{var n=r(939),i=r(7361),o=r(9095),a=r(5403),s=r(9162),c=r(2634),u=r(327);t.exports=function(t,e){return a(t)&&s(e)?c(u(t),e):function(r){var a=i(r,t);return void 0===a&&a===e?o(r,t):n(e,a,3)}}},3012:(t,e,r)=>{var n=r(7786),i=r(611),o=r(1811);t.exports=function(t,e,r){for(var a=-1,s=e.length,c={};++a<s;){var u=e[a],l=n(t,u);r(l,u)&&i(c,o(u,t),l)}return c}},371:t=>{t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},9152:(t,e,r)=>{var n=r(7786);t.exports=function(t){return function(e){return n(e,t)}}},611:(t,e,r)=>{var n=r(4865),i=r(1811),o=r(5776),a=r(3218),s=r(327);t.exports=function(t,e,r,c){if(!a(t))return t;for(var u=-1,l=(e=i(e,t)).length,f=l-1,p=t;null!=p&&++u<l;){var d=s(e[u]),v=r;if("__proto__"===d||"constructor"===d||"prototype"===d)return t;if(u!=f){var y=p[d];void 0===(v=c?c(y,d,p):void 0)&&(v=a(y)?y:o(e[u+1])?[]:{})}n(p,d,v),p=p[d]}return t}},2545:t=>{t.exports=function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}},531:(t,e,r)=>{var n=r(2705),i=r(9932),o=r(1469),a=r(3448),s=n?n.prototype:void 0,c=s?s.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(o(e))return i(e,t)+"";if(a(e))return c?c.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r}},7561:(t,e,r)=>{var n=r(7990),i=/^\s+/;t.exports=function(t){return t?t.slice(0,n(t)+1).replace(i,""):t}},1717:t=>{t.exports=function(t){return function(e){return t(e)}}},4757:t=>{t.exports=function(t,e){return t.has(e)}},1811:(t,e,r)=>{var n=r(1469),i=r(5403),o=r(5514),a=r(9833);t.exports=function(t,e){return n(t)?t:i(t,e)?[t]:o(a(t))}},4429:(t,e,r)=>{var n=r(5639)["__core-js_shared__"];t.exports=n},8777:(t,e,r)=>{var n=r(852),i=function(){try{var t=n(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},7114:(t,e,r)=>{var n=r(8668),i=r(2908),o=r(4757);t.exports=function(t,e,r,a,s,c){var u=1&r,l=t.length,f=e.length;if(l!=f&&!(u&&f>l))return!1;var p=c.get(t),d=c.get(e);if(p&&d)return p==e&&d==t;var v=-1,y=!0,h=2&r?new n:void 0;for(c.set(t,e),c.set(e,t);++v<l;){var g=t[v],m=e[v];if(a)var b=u?a(m,g,v,e,t,c):a(g,m,v,t,e,c);if(void 0!==b){if(b)continue;y=!1;break}if(h){if(!i(e,(function(t,e){if(!o(h,e)&&(g===t||s(g,t,r,a,c)))return h.push(e)}))){y=!1;break}}else if(g!==m&&!s(g,m,r,a,c)){y=!1;break}}return c.delete(t),c.delete(e),y}},8351:(t,e,r)=>{var n=r(2705),i=r(1149),o=r(7813),a=r(7114),s=r(8776),c=r(1814),u=n?n.prototype:void 0,l=u?u.valueOf:void 0;t.exports=function(t,e,r,n,u,f,p){switch(r){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!f(new i(t),new i(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var d=s;case"[object Set]":var v=1&n;if(d||(d=c),t.size!=e.size&&!v)return!1;var y=p.get(t);if(y)return y==e;n|=2,p.set(t,e);var h=a(d(t),d(e),n,u,f,p);return p.delete(t),h;case"[object Symbol]":if(l)return l.call(t)==l.call(e)}return!1}},6096:(t,e,r)=>{var n=r(8234),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,o,a,s){var c=1&r,u=n(t),l=u.length;if(l!=n(e).length&&!c)return!1;for(var f=l;f--;){var p=u[f];if(!(c?p in e:i.call(e,p)))return!1}var d=s.get(t),v=s.get(e);if(d&&v)return d==e&&v==t;var y=!0;s.set(t,e),s.set(e,t);for(var h=c;++f<l;){var g=t[p=u[f]],m=e[p];if(o)var b=c?o(m,g,p,e,t,s):o(g,m,p,t,e,s);if(!(void 0===b?g===m||a(g,m,r,o,s):b)){y=!1;break}h||(h="constructor"==p)}if(y&&!h){var w=t.constructor,x=e.constructor;w==x||!("constructor"in t)||!("constructor"in e)||"function"==typeof w&&w instanceof w&&"function"==typeof x&&x instanceof x||(y=!1)}return s.delete(t),s.delete(e),y}},1957:(t,e,r)=>{var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;t.exports=n},8234:(t,e,r)=>{var n=r(8866),i=r(9551),o=r(3674);t.exports=function(t){return n(t,o,i)}},6904:(t,e,r)=>{var n=r(8866),i=r(1442),o=r(1704);t.exports=function(t){return n(t,o,i)}},5050:(t,e,r)=>{var n=r(7019);t.exports=function(t,e){var r=t.__data__;return n(e)?r["string"==typeof e?"string":"hash"]:r.map}},1499:(t,e,r)=>{var n=r(9162),i=r(3674);t.exports=function(t){for(var e=i(t),r=e.length;r--;){var o=e[r],a=t[o];e[r]=[o,a,n(a)]}return e}},852:(t,e,r)=>{var n=r(8458),i=r(7801);t.exports=function(t,e){var r=i(t,e);return n(r)?r:void 0}},5924:(t,e,r)=>{var n=r(5569)(Object.getPrototypeOf,Object);t.exports=n},9607:(t,e,r)=>{var n=r(2705),i=Object.prototype,o=i.hasOwnProperty,a=i.toString,s=n?n.toStringTag:void 0;t.exports=function(t){var e=o.call(t,s),r=t[s];try{t[s]=void 0;var n=!0}catch(t){}var i=a.call(t);return n&&(e?t[s]=r:delete t[s]),i}},9551:(t,e,r)=>{var n=r(4963),i=r(479),o=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(t){return null==t?[]:(t=Object(t),n(a(t),(function(e){return o.call(t,e)})))}:i;t.exports=s},1442:(t,e,r)=>{var n=r(2488),i=r(5924),o=r(9551),a=r(479),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)n(e,o(t)),t=i(t);return e}:a;t.exports=s},4160:(t,e,r)=>{var n=r(8552),i=r(7071),o=r(3818),a=r(8525),s=r(577),c=r(4239),u=r(346),l="[object Map]",f="[object Promise]",p="[object Set]",d="[object WeakMap]",v="[object DataView]",y=u(n),h=u(i),g=u(o),m=u(a),b=u(s),w=c;(n&&w(new n(new ArrayBuffer(1)))!=v||i&&w(new i)!=l||o&&w(o.resolve())!=f||a&&w(new a)!=p||s&&w(new s)!=d)&&(w=function(t){var e=c(t),r="[object Object]"==e?t.constructor:void 0,n=r?u(r):"";if(n)switch(n){case y:return v;case h:return l;case g:return f;case m:return p;case b:return d}return e}),t.exports=w},7801:t=>{t.exports=function(t,e){return null==t?void 0:t[e]}},222:(t,e,r)=>{var n=r(1811),i=r(5694),o=r(1469),a=r(5776),s=r(1780),c=r(327);t.exports=function(t,e,r){for(var u=-1,l=(e=n(e,t)).length,f=!1;++u<l;){var p=c(e[u]);if(!(f=null!=t&&r(t,p)))break;t=t[p]}return f||++u!=l?f:!!(l=null==t?0:t.length)&&s(l)&&a(p,l)&&(o(t)||i(t))}},1789:(t,e,r)=>{var n=r(4536);t.exports=function(){this.__data__=n?n(null):{},this.size=0}},401:t=>{t.exports=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}},7667:(t,e,r)=>{var n=r(4536),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;if(n){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return i.call(e,t)?e[t]:void 0}},1327:(t,e,r)=>{var n=r(4536),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;return n?void 0!==e[t]:i.call(e,t)}},1866:(t,e,r)=>{var n=r(4536);t.exports=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=n&&void 0===e?"__lodash_hash_undefined__":e,this}},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,r){var n=typeof t;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&e.test(t))&&t>-1&&t%1==0&&t<r}},5403:(t,e,r)=>{var n=r(1469),i=r(3448),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(n(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!i(t))||a.test(t)||!o.test(t)||null!=e&&t in Object(e)}},7019:t=>{t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},5346:(t,e,r)=>{var n,i=r(4429),o=(n=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";t.exports=function(t){return!!o&&o in t}},5726:t=>{var e=Object.prototype;t.exports=function(t){var r=t&&t.constructor;return t===("function"==typeof r&&r.prototype||e)}},9162:(t,e,r)=>{var n=r(3218);t.exports=function(t){return t==t&&!n(t)}},7040:t=>{t.exports=function(){this.__data__=[],this.size=0}},4125:(t,e,r)=>{var n=r(8470),i=Array.prototype.splice;t.exports=function(t){var e=this.__data__,r=n(e,t);return!(r<0||(r==e.length-1?e.pop():i.call(e,r,1),--this.size,0))}},2117:(t,e,r)=>{var n=r(8470);t.exports=function(t){var e=this.__data__,r=n(e,t);return r<0?void 0:e[r][1]}},7518:(t,e,r)=>{var n=r(8470);t.exports=function(t){return n(this.__data__,t)>-1}},4705:(t,e,r)=>{var n=r(8470);t.exports=function(t,e){var r=this.__data__,i=n(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this}},4785:(t,e,r)=>{var n=r(1989),i=r(8407),o=r(7071);t.exports=function(){this.size=0,this.__data__={hash:new n,map:new(o||i),string:new n}}},1285:(t,e,r)=>{var n=r(5050);t.exports=function(t){var e=n(this,t).delete(t);return this.size-=e?1:0,e}},6e3:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).get(t)}},9916:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).has(t)}},5265:(t,e,r)=>{var n=r(5050);t.exports=function(t,e){var r=n(this,t),i=r.size;return r.set(t,e),this.size+=r.size==i?0:1,this}},8776:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,n){r[++e]=[n,t]})),r}},2634:t=>{t.exports=function(t,e){return function(r){return null!=r&&r[t]===e&&(void 0!==e||t in Object(r))}}},4523:(t,e,r)=>{var n=r(8306);t.exports=function(t){var e=n(t,(function(t){return 500===r.size&&r.clear(),t})),r=e.cache;return e}},4536:(t,e,r)=>{var n=r(852)(Object,"create");t.exports=n},6916:(t,e,r)=>{var n=r(5569)(Object.keys,Object);t.exports=n},3498:t=>{t.exports=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}},1167:(t,e,r)=>{t=r.nmd(t);var n=r(1957),i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,a=o&&o.exports===i&&n.process,s=function(){try{return o&&o.require&&o.require("util").types||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=s},2333:t=>{var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},5569:t=>{t.exports=function(t,e){return function(r){return t(e(r))}}},5639:(t,e,r)=>{var n=r(1957),i="object"==typeof self&&self&&self.Object===Object&&self,o=n||i||Function("return this")();t.exports=o},619:t=>{t.exports=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this}},2385:t=>{t.exports=function(t){return this.__data__.has(t)}},1814:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r}},7465:(t,e,r)=>{var n=r(8407);t.exports=function(){this.__data__=new n,this.size=0}},3779:t=>{t.exports=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}},7599:t=>{t.exports=function(t){return this.__data__.get(t)}},4758:t=>{t.exports=function(t){return this.__data__.has(t)}},4309:(t,e,r)=>{var n=r(8407),i=r(7071),o=r(3369);t.exports=function(t,e){var r=this.__data__;if(r instanceof n){var a=r.__data__;if(!i||a.length<199)return a.push([t,e]),this.size=++r.size,this;r=this.__data__=new o(a)}return r.set(t,e),this.size=r.size,this}},5514:(t,e,r)=>{var n=r(4523),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,a=n((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(i,(function(t,r,n,i){e.push(n?i.replace(o,"$1"):r||t)})),e}));t.exports=a},327:(t,e,r)=>{var n=r(3448);t.exports=function(t){if("string"==typeof t||n(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},346:t=>{var e=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return e.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},7990:t=>{var e=/\s/;t.exports=function(t){for(var r=t.length;r--&&e.test(t.charAt(r)););return r}},7813:t=>{t.exports=function(t,e){return t===e||t!=t&&e!=e}},7436:(t,e,r)=>{var n=r(1848),i=r(7206),o=r(554),a=Math.max,s=Math.min;t.exports=function(t,e,r){var c=null==t?0:t.length;if(!c)return-1;var u=c-1;return void 0!==r&&(u=o(r),u=r<0?a(c+u,0):s(u,c-1)),n(t,i(e,3),u,!0)}},7361:(t,e,r)=>{var n=r(7786);t.exports=function(t,e,r){var i=null==t?void 0:n(t,e);return void 0===i?r:i}},9095:(t,e,r)=>{var n=r(13),i=r(222);t.exports=function(t,e){return null!=t&&i(t,e,n)}},6557:t=>{t.exports=function(t){return t}},5694:(t,e,r)=>{var n=r(9454),i=r(7005),o=Object.prototype,a=o.hasOwnProperty,s=o.propertyIsEnumerable,c=n(function(){return arguments}())?n:function(t){return i(t)&&a.call(t,"callee")&&!s.call(t,"callee")};t.exports=c},1469:t=>{var e=Array.isArray;t.exports=e},1240:(t,e,r)=>{var n=r(3560),i=r(1780);t.exports=function(t){return null!=t&&i(t.length)&&!n(t)}},4144:(t,e,r)=>{t=r.nmd(t);var n=r(5639),i=r(5062),o=e&&!e.nodeType&&e,a=o&&t&&!t.nodeType&&t,s=a&&a.exports===o?n.Buffer:void 0,c=(s?s.isBuffer:void 0)||i;t.exports=c},3560:(t,e,r)=>{var n=r(4239),i=r(3218);t.exports=function(t){if(!i(t))return!1;var e=n(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},1780:t=>{t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},3218:t=>{t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},7005:t=>{t.exports=function(t){return null!=t&&"object"==typeof t}},3448:(t,e,r)=>{var n=r(4239),i=r(7005);t.exports=function(t){return"symbol"==typeof t||i(t)&&"[object Symbol]"==n(t)}},6719:(t,e,r)=>{var n=r(8749),i=r(1717),o=r(1167),a=o&&o.isTypedArray,s=a?i(a):n;t.exports=s},3674:(t,e,r)=>{var n=r(4636),i=r(280),o=r(1240);t.exports=function(t){return o(t)?n(t):i(t)}},1704:(t,e,r)=>{var n=r(4636),i=r(313),o=r(1240);t.exports=function(t){return o(t)?n(t,!0):i(t)}},8306:(t,e,r)=>{var n=r(3369);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var a=t.apply(this,n);return r.cache=o.set(i,a)||o,a};return r.cache=new(i.Cache||n),r}i.Cache=n,t.exports=i},5937:(t,e,r)=>{var n=r(9932),i=r(7206),o=r(3012),a=r(6904);t.exports=function(t,e){if(null==t)return{};var r=n(a(t),(function(t){return[t]}));return e=i(e),o(t,r,(function(t,r){return e(t,r[0])}))}},9601:(t,e,r)=>{var n=r(371),i=r(9152),o=r(5403),a=r(327);t.exports=function(t){return o(t)?n(a(t)):i(t)}},479:t=>{t.exports=function(){return[]}},5062:t=>{t.exports=function(){return!1}},8601:(t,e,r)=>{var n=r(4841);t.exports=function(t){return t?Infinity===(t=n(t))||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},554:(t,e,r)=>{var n=r(8601);t.exports=function(t){var e=n(t),r=e%1;return e==e?r?e-r:e:0}},4841:(t,e,r)=>{var n=r(7561),i=r(3218),o=r(3448),a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,c=/^0o[0-7]+$/i,u=parseInt;t.exports=function(t){if("number"==typeof t)return t;if(o(t))return NaN;if(i(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=i(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=n(t);var r=s.test(t);return r||c.test(t)?u(t.slice(2),r?2:8):a.test(t)?NaN:+t}},9833:(t,e,r)=>{var n=r(531);t.exports=function(t){return null==t?"":n(t)}},631:(t,e,r)=>{var n="function"==typeof Map&&Map.prototype,i=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=n&&i&&"function"==typeof i.get?i.get:null,a=n&&Map.prototype.forEach,s="function"==typeof Set&&Set.prototype,c=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,u=s&&c&&"function"==typeof c.get?c.get:null,l=s&&Set.prototype.forEach,f="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,p="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,d="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,v=Boolean.prototype.valueOf,y=Object.prototype.toString,h=Function.prototype.toString,g=String.prototype.match,m="function"==typeof BigInt?BigInt.prototype.valueOf:null,b=Object.getOwnPropertySymbols,w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,x="function"==typeof Symbol&&"object"==typeof Symbol.iterator,S=Object.prototype.propertyIsEnumerable,k=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(t){return t.__proto__}:null),O=r(4654).custom,_=O&&j(O)?O:null,E="function"==typeof Symbol&&void 0!==Symbol.toStringTag?Symbol.toStringTag:null;function A(t,e,r){var n="double"===(r.quoteStyle||e)?'"':"'";return n+t+n}function R(t){return String(t).replace(/"/g,"&quot;")}function T(t){return!("[object Array]"!==N(t)||E&&"object"==typeof t&&E in t)}function j(t){if(x)return t&&"object"==typeof t&&t instanceof Symbol;if("symbol"==typeof t)return!0;if(!t||"object"!=typeof t||!w)return!1;try{return w.call(t),!0}catch(t){}return!1}t.exports=function t(e,r,n,i){var s=r||{};if(P(s,"quoteStyle")&&"single"!==s.quoteStyle&&"double"!==s.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(P(s,"maxStringLength")&&("number"==typeof s.maxStringLength?s.maxStringLength<0&&s.maxStringLength!==1/0:null!==s.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var c=!P(s,"customInspect")||s.customInspect;if("boolean"!=typeof c&&"symbol"!==c)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(P(s,"indent")&&null!==s.indent&&"\t"!==s.indent&&!(parseInt(s.indent,10)===s.indent&&s.indent>0))throw new TypeError('options "indent" must be "\\t", an integer > 0, or `null`');if(void 0===e)return"undefined";if(null===e)return"null";if("boolean"==typeof e)return e?"true":"false";if("string"==typeof e)return D(e,s);if("number"==typeof e)return 0===e?1/0/e>0?"0":"-0":String(e);if("bigint"==typeof e)return String(e)+"n";var y=void 0===s.depth?5:s.depth;if(void 0===n&&(n=0),n>=y&&y>0&&"object"==typeof e)return T(e)?"[Array]":"[Object]";var b,S=function(t,e){var r;if("\t"===t.indent)r="\t";else{if(!("number"==typeof t.indent&&t.indent>0))return null;r=Array(t.indent+1).join(" ")}return{base:r,prev:Array(e+1).join(r)}}(s,n);if(void 0===i)i=[];else if(C(i,e)>=0)return"[Circular]";function O(e,r,o){if(r&&(i=i.slice()).push(r),o){var a={depth:s.depth};return P(s,"quoteStyle")&&(a.quoteStyle=s.quoteStyle),t(e,a,n+1,i)}return t(e,s,n+1,i)}if("function"==typeof e){var I=function(t){if(t.name)return t.name;var e=g.call(h.call(t),/^function\s*([\w$]+)/);return e?e[1]:null}(e),L=G(e,O);return"[Function"+(I?": "+I:" (anonymous)")+"]"+(L.length>0?" { "+L.join(", ")+" }":"")}if(j(e)){var V=x?String(e).replace(/^(Symbol\(.*\))_[^)]*$/,"$1"):w.call(e);return"object"!=typeof e||x?V:M(V)}if((b=e)&&"object"==typeof b&&("undefined"!=typeof HTMLElement&&b instanceof HTMLElement||"string"==typeof b.nodeName&&"function"==typeof b.getAttribute)){for(var W="<"+String(e.nodeName).toLowerCase(),q=e.attributes||[],H=0;H<q.length;H++)W+=" "+q[H].name+"="+A(R(q[H].value),"double",s);return W+=">",e.childNodes&&e.childNodes.length&&(W+="..."),W+"</"+String(e.nodeName).toLowerCase()+">"}if(T(e)){if(0===e.length)return"[]";var z=G(e,O);return S&&!function(t){for(var e=0;e<t.length;e++)if(C(t[e],"\n")>=0)return!1;return!0}(z)?"["+B(z,S)+"]":"[ "+z.join(", ")+" ]"}if(function(t){return!("[object Error]"!==N(t)||E&&"object"==typeof t&&E in t)}(e)){var $=G(e,O);return 0===$.length?"["+String(e)+"]":"{ ["+String(e)+"] "+$.join(", ")+" }"}if("object"==typeof e&&c){if(_&&"function"==typeof e[_])return e[_]();if("symbol"!==c&&"function"==typeof e.inspect)return e.inspect()}if(function(t){if(!o||!t||"object"!=typeof t)return!1;try{o.call(t);try{u.call(t)}catch(t){return!0}return t instanceof Map}catch(t){}return!1}(e)){var Y=[];return a.call(e,(function(t,r){Y.push(O(r,e,!0)+" => "+O(t,e))})),F("Map",o.call(e),Y,S)}if(function(t){if(!u||!t||"object"!=typeof t)return!1;try{u.call(t);try{o.call(t)}catch(t){return!0}return t instanceof Set}catch(t){}return!1}(e)){var K=[];return l.call(e,(function(t){K.push(O(t,e))})),F("Set",u.call(e),K,S)}if(function(t){if(!f||!t||"object"!=typeof t)return!1;try{f.call(t,f);try{p.call(t,p)}catch(t){return!0}return t instanceof WeakMap}catch(t){}return!1}(e))return U("WeakMap");if(function(t){if(!p||!t||"object"!=typeof t)return!1;try{p.call(t,p);try{f.call(t,f)}catch(t){return!0}return t instanceof WeakSet}catch(t){}return!1}(e))return U("WeakSet");if(function(t){if(!d||!t||"object"!=typeof t)return!1;try{return d.call(t),!0}catch(t){}return!1}(e))return U("WeakRef");if(function(t){return!("[object Number]"!==N(t)||E&&"object"==typeof t&&E in t)}(e))return M(O(Number(e)));if(function(t){if(!t||"object"!=typeof t||!m)return!1;try{return m.call(t),!0}catch(t){}return!1}(e))return M(O(m.call(e)));if(function(t){return!("[object Boolean]"!==N(t)||E&&"object"==typeof t&&E in t)}(e))return M(v.call(e));if(function(t){return!("[object String]"!==N(t)||E&&"object"==typeof t&&E in t)}(e))return M(O(String(e)));if(!function(t){return!("[object Date]"!==N(t)||E&&"object"==typeof t&&E in t)}(e)&&!function(t){return!("[object RegExp]"!==N(t)||E&&"object"==typeof t&&E in t)}(e)){var J=G(e,O),Q=k?k(e)===Object.prototype:e instanceof Object||e.constructor===Object,X=e instanceof Object?"":"null prototype",Z=!Q&&E&&Object(e)===e&&E in e?N(e).slice(8,-1):X?"Object":"",tt=(Q||"function"!=typeof e.constructor?"":e.constructor.name?e.constructor.name+" ":"")+(Z||X?"["+[].concat(Z||[],X||[]).join(": ")+"] ":"");return 0===J.length?tt+"{}":S?tt+"{"+B(J,S)+"}":tt+"{ "+J.join(", ")+" }"}return String(e)};var I=Object.prototype.hasOwnProperty||function(t){return t in this};function P(t,e){return I.call(t,e)}function N(t){return y.call(t)}function C(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function D(t,e){if(t.length>e.maxStringLength){var r=t.length-e.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return D(t.slice(0,e.maxStringLength),e)+n}return A(t.replace(/(['\\])/g,"\\$1").replace(/[\x00-\x1f]/g,L),"single",e)}function L(t){var e=t.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[e];return r?"\\"+r:"\\x"+(e<16?"0":"")+e.toString(16).toUpperCase()}function M(t){return"Object("+t+")"}function U(t){return t+" { ? }"}function F(t,e,r,n){return t+" ("+e+") {"+(n?B(r,n):r.join(", "))+"}"}function B(t,e){if(0===t.length)return"";var r="\n"+e.prev+e.base;return r+t.join(","+r)+"\n"+e.prev}function G(t,e){var r=T(t),n=[];if(r){n.length=t.length;for(var i=0;i<t.length;i++)n[i]=P(t,i)?e(t[i],t):""}var o,a="function"==typeof b?b(t):[];if(x){o={};for(var s=0;s<a.length;s++)o["$"+a[s]]=a[s]}for(var c in t)P(t,c)&&(r&&String(Number(c))===c&&c<t.length||x&&o["$"+c]instanceof Symbol||(/[^\w$]/.test(c)?n.push(e(c,t)+": "+e(t[c],t)):n.push(c+": "+e(t[c],t))));if("function"==typeof b)for(var u=0;u<a.length;u++)S.call(t,a[u])&&n.push("["+e(a[u])+"]: "+e(t[a[u]],t));return n}},5798:t=>{var e=String.prototype.replace,r=/%20/g,n="RFC3986";t.exports={default:n,formatters:{RFC1738:function(t){return e.call(t,r,"+")},RFC3986:function(t){return String(t)}},RFC1738:"RFC1738",RFC3986:n}},129:(t,e,r)=>{var n=r(8261),i=r(5235),o=r(5798);t.exports={formats:o,parse:i,stringify:n}},5235:(t,e,r)=>{var n=r(2769),i=Object.prototype.hasOwnProperty,o=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},s=function(t){return t.replace(/&#(\d+);/g,(function(t,e){return String.fromCharCode(parseInt(e,10))}))},c=function(t,e){return t&&"string"==typeof t&&e.comma&&t.indexOf(",")>-1?t.split(","):t},u=function(t,e,r,n){if(t){var o=r.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,a=/(\[[^[\]]*])/g,s=r.depth>0&&/(\[[^[\]]*])/.exec(o),u=s?o.slice(0,s.index):o,l=[];if(u){if(!r.plainObjects&&i.call(Object.prototype,u)&&!r.allowPrototypes)return;l.push(u)}for(var f=0;r.depth>0&&null!==(s=a.exec(o))&&f<r.depth;){if(f+=1,!r.plainObjects&&i.call(Object.prototype,s[1].slice(1,-1))&&!r.allowPrototypes)return;l.push(s[1])}return s&&l.push("["+o.slice(s.index)+"]"),function(t,e,r,n){for(var i=n?e:c(e,r),o=t.length-1;o>=0;--o){var a,s=t[o];if("[]"===s&&r.parseArrays)a=[].concat(i);else{a=r.plainObjects?Object.create(null):{};var u="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(u,10);r.parseArrays||""!==u?!isNaN(l)&&s!==u&&String(l)===u&&l>=0&&r.parseArrays&&l<=r.arrayLimit?(a=[])[l]=i:a[u]=i:a={0:i}}i=a}return i}(l,e,r,n)}};t.exports=function(t,e){var r=function(t){if(!t)return a;if(null!==t.decoder&&void 0!==t.decoder&&"function"!=typeof t.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==t.charset&&"utf-8"!==t.charset&&"iso-8859-1"!==t.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var e=void 0===t.charset?a.charset:t.charset;return{allowDots:void 0===t.allowDots?a.allowDots:!!t.allowDots,allowPrototypes:"boolean"==typeof t.allowPrototypes?t.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"==typeof t.allowSparse?t.allowSparse:a.allowSparse,arrayLimit:"number"==typeof t.arrayLimit?t.arrayLimit:a.arrayLimit,charset:e,charsetSentinel:"boolean"==typeof t.charsetSentinel?t.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof t.comma?t.comma:a.comma,decoder:"function"==typeof t.decoder?t.decoder:a.decoder,delimiter:"string"==typeof t.delimiter||n.isRegExp(t.delimiter)?t.delimiter:a.delimiter,depth:"number"==typeof t.depth||!1===t.depth?+t.depth:a.depth,ignoreQueryPrefix:!0===t.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof t.interpretNumericEntities?t.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof t.parameterLimit?t.parameterLimit:a.parameterLimit,parseArrays:!1!==t.parseArrays,plainObjects:"boolean"==typeof t.plainObjects?t.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof t.strictNullHandling?t.strictNullHandling:a.strictNullHandling}}(e);if(""===t||null==t)return r.plainObjects?Object.create(null):{};for(var l="string"==typeof t?function(t,e){var r,u={},l=e.ignoreQueryPrefix?t.replace(/^\?/,""):t,f=e.parameterLimit===1/0?void 0:e.parameterLimit,p=l.split(e.delimiter,f),d=-1,v=e.charset;if(e.charsetSentinel)for(r=0;r<p.length;++r)0===p[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===p[r]?v="utf-8":"utf8=%26%2310003%3B"===p[r]&&(v="iso-8859-1"),d=r,r=p.length);for(r=0;r<p.length;++r)if(r!==d){var y,h,g=p[r],m=g.indexOf("]="),b=-1===m?g.indexOf("="):m+1;-1===b?(y=e.decoder(g,a.decoder,v,"key"),h=e.strictNullHandling?null:""):(y=e.decoder(g.slice(0,b),a.decoder,v,"key"),h=n.maybeMap(c(g.slice(b+1),e),(function(t){return e.decoder(t,a.decoder,v,"value")}))),h&&e.interpretNumericEntities&&"iso-8859-1"===v&&(h=s(h)),g.indexOf("[]=")>-1&&(h=o(h)?[h]:h),i.call(u,y)?u[y]=n.combine(u[y],h):u[y]=h}return u}(t,r):t,f=r.plainObjects?Object.create(null):{},p=Object.keys(l),d=0;d<p.length;++d){var v=p[d],y=u(v,l[v],r,"string"==typeof t);f=n.merge(f,y,r)}return!0===r.allowSparse?f:n.compact(f)}},8261:(t,e,r)=>{var n=r(7478),i=r(2769),o=r(5798),a=Object.prototype.hasOwnProperty,s={brackets:function(t){return t+"[]"},comma:"comma",indices:function(t,e){return t+"["+e+"]"},repeat:function(t){return t}},c=Array.isArray,u=Array.prototype.push,l=function(t,e){u.apply(t,c(e)?e:[e])},f=Date.prototype.toISOString,p=o.default,d={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:i.encode,encodeValuesOnly:!1,format:p,formatter:o.formatters[p],indices:!1,serializeDate:function(t){return f.call(t)},skipNulls:!1,strictNullHandling:!1},v=function t(e,r,o,a,s,u,f,p,v,y,h,g,m,b,w){var x,S=e;if(w.has(e))throw new RangeError("Cyclic object value");if("function"==typeof f?S=f(r,S):S instanceof Date?S=y(S):"comma"===o&&c(S)&&(S=i.maybeMap(S,(function(t){return t instanceof Date?y(t):t}))),null===S){if(a)return u&&!m?u(r,d.encoder,b,"key",h):r;S=""}if("string"==typeof(x=S)||"number"==typeof x||"boolean"==typeof x||"symbol"==typeof x||"bigint"==typeof x||i.isBuffer(S))return u?[g(m?r:u(r,d.encoder,b,"key",h))+"="+g(u(S,d.encoder,b,"value",h))]:[g(r)+"="+g(String(S))];var k,O=[];if(void 0===S)return O;if("comma"===o&&c(S))k=[{value:S.length>0?S.join(",")||null:void 0}];else if(c(f))k=f;else{var _=Object.keys(S);k=p?_.sort(p):_}for(var E=0;E<k.length;++E){var A=k[E],R="object"==typeof A&&void 0!==A.value?A.value:S[A];if(!s||null!==R){var T=c(S)?"function"==typeof o?o(r,A):r:r+(v?"."+A:"["+A+"]");w.set(e,!0);var j=n();l(O,t(R,T,o,a,s,u,f,p,v,y,h,g,m,b,j))}}return O};t.exports=function(t,e){var r,i=t,u=function(t){if(!t)return d;if(null!==t.encoder&&void 0!==t.encoder&&"function"!=typeof t.encoder)throw new TypeError("Encoder has to be a function.");var e=t.charset||d.charset;if(void 0!==t.charset&&"utf-8"!==t.charset&&"iso-8859-1"!==t.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=o.default;if(void 0!==t.format){if(!a.call(o.formatters,t.format))throw new TypeError("Unknown format option provided.");r=t.format}var n=o.formatters[r],i=d.filter;return("function"==typeof t.filter||c(t.filter))&&(i=t.filter),{addQueryPrefix:"boolean"==typeof t.addQueryPrefix?t.addQueryPrefix:d.addQueryPrefix,allowDots:void 0===t.allowDots?d.allowDots:!!t.allowDots,charset:e,charsetSentinel:"boolean"==typeof t.charsetSentinel?t.charsetSentinel:d.charsetSentinel,delimiter:void 0===t.delimiter?d.delimiter:t.delimiter,encode:"boolean"==typeof t.encode?t.encode:d.encode,encoder:"function"==typeof t.encoder?t.encoder:d.encoder,encodeValuesOnly:"boolean"==typeof t.encodeValuesOnly?t.encodeValuesOnly:d.encodeValuesOnly,filter:i,format:r,formatter:n,serializeDate:"function"==typeof t.serializeDate?t.serializeDate:d.serializeDate,skipNulls:"boolean"==typeof t.skipNulls?t.skipNulls:d.skipNulls,sort:"function"==typeof t.sort?t.sort:null,strictNullHandling:"boolean"==typeof t.strictNullHandling?t.strictNullHandling:d.strictNullHandling}}(e);"function"==typeof u.filter?i=(0,u.filter)("",i):c(u.filter)&&(r=u.filter);var f,p=[];if("object"!=typeof i||null===i)return"";f=e&&e.arrayFormat in s?e.arrayFormat:e&&"indices"in e?e.indices?"indices":"repeat":"indices";var y=s[f];r||(r=Object.keys(i)),u.sort&&r.sort(u.sort);for(var h=n(),g=0;g<r.length;++g){var m=r[g];u.skipNulls&&null===i[m]||l(p,v(i[m],m,y,u.strictNullHandling,u.skipNulls,u.encode?u.encoder:null,u.filter,u.sort,u.allowDots,u.serializeDate,u.format,u.formatter,u.encodeValuesOnly,u.charset,h))}var b=p.join(u.delimiter),w=!0===u.addQueryPrefix?"?":"";return u.charsetSentinel&&("iso-8859-1"===u.charset?w+="utf8=%26%2310003%3B&":w+="utf8=%E2%9C%93&"),b.length>0?w+b:""}},2769:(t,e,r)=>{var n=r(5798),i=Object.prototype.hasOwnProperty,o=Array.isArray,a=function(){for(var t=[],e=0;e<256;++e)t.push("%"+((e<16?"0":"")+e.toString(16)).toUpperCase());return t}(),s=function(t,e){for(var r=e&&e.plainObjects?Object.create(null):{},n=0;n<t.length;++n)void 0!==t[n]&&(r[n]=t[n]);return r};t.exports={arrayToObject:s,assign:function(t,e){return Object.keys(e).reduce((function(t,r){return t[r]=e[r],t}),t)},combine:function(t,e){return[].concat(t,e)},compact:function(t){for(var e=[{obj:{o:t},prop:"o"}],r=[],n=0;n<e.length;++n)for(var i=e[n],a=i.obj[i.prop],s=Object.keys(a),c=0;c<s.length;++c){var u=s[c],l=a[u];"object"==typeof l&&null!==l&&-1===r.indexOf(l)&&(e.push({obj:a,prop:u}),r.push(l))}return function(t){for(;t.length>1;){var e=t.pop(),r=e.obj[e.prop];if(o(r)){for(var n=[],i=0;i<r.length;++i)void 0!==r[i]&&n.push(r[i]);e.obj[e.prop]=n}}}(e),t},decode:function(t,e,r){var n=t.replace(/\+/g," ");if("iso-8859-1"===r)return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(t){return n}},encode:function(t,e,r,i,o){if(0===t.length)return t;var s=t;if("symbol"==typeof t?s=Symbol.prototype.toString.call(t):"string"!=typeof t&&(s=String(t)),"iso-8859-1"===r)return escape(s).replace(/%u[0-9a-f]{4}/gi,(function(t){return"%26%23"+parseInt(t.slice(2),16)+"%3B"}));for(var c="",u=0;u<s.length;++u){var l=s.charCodeAt(u);45===l||46===l||95===l||126===l||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||o===n.RFC1738&&(40===l||41===l)?c+=s.charAt(u):l<128?c+=a[l]:l<2048?c+=a[192|l>>6]+a[128|63&l]:l<55296||l>=57344?c+=a[224|l>>12]+a[128|l>>6&63]+a[128|63&l]:(u+=1,l=65536+((1023&l)<<10|1023&s.charCodeAt(u)),c+=a[240|l>>18]+a[128|l>>12&63]+a[128|l>>6&63]+a[128|63&l])}return c},isBuffer:function(t){return!(!t||"object"!=typeof t||!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t)))},isRegExp:function(t){return"[object RegExp]"===Object.prototype.toString.call(t)},maybeMap:function(t,e){if(o(t)){for(var r=[],n=0;n<t.length;n+=1)r.push(e(t[n]));return r}return e(t)},merge:function t(e,r,n){if(!r)return e;if("object"!=typeof r){if(o(e))e.push(r);else{if(!e||"object"!=typeof e)return[e,r];(n&&(n.plainObjects||n.allowPrototypes)||!i.call(Object.prototype,r))&&(e[r]=!0)}return e}if(!e||"object"!=typeof e)return[e].concat(r);var a=e;return o(e)&&!o(r)&&(a=s(e,n)),o(e)&&o(r)?(r.forEach((function(r,o){if(i.call(e,o)){var a=e[o];a&&"object"==typeof a&&r&&"object"==typeof r?e[o]=t(a,r,n):e.push(r)}else e[o]=r})),e):Object.keys(r).reduce((function(e,o){var a=r[o];return i.call(e,o)?e[o]=t(e[o],a,n):e[o]=a,e}),a)}}},7478:(t,e,r)=>{var n=r(210),i=r(1924),o=r(631),a=n("%TypeError%"),s=n("%WeakMap%",!0),c=n("%Map%",!0),u=i("WeakMap.prototype.get",!0),l=i("WeakMap.prototype.set",!0),f=i("WeakMap.prototype.has",!0),p=i("Map.prototype.get",!0),d=i("Map.prototype.set",!0),v=i("Map.prototype.has",!0),y=function(t,e){for(var r,n=t;null!==(r=n.next);n=r)if(r.key===e)return n.next=r.next,r.next=t.next,t.next=r,r};t.exports=function(){var t,e,r,n={assert:function(t){if(!n.has(t))throw new a("Side channel does not contain "+o(t))},get:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(t)return u(t,n)}else if(c){if(e)return p(e,n)}else if(r)return function(t,e){var r=y(t,e);return r&&r.value}(r,n)},has:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(t)return f(t,n)}else if(c){if(e)return v(e,n)}else if(r)return function(t,e){return!!y(t,e)}(r,n);return!1},set:function(n,i){s&&n&&("object"==typeof n||"function"==typeof n)?(t||(t=new s),l(t,n,i)):c?(e||(e=new c),d(e,n,i)):(r||(r={key:{},next:null}),function(t,e,r){var n=y(t,e);n?n.value=r:t.next={key:e,next:t.next,value:r}}(r,n,i))}};return n}},2238:function(t,e,r){var n;!function(i,o){var a="function",s="undefined",c="object",u="string",l="model",f="name",p="type",d="vendor",v="version",y="architecture",h="console",g="mobile",m="tablet",b="smarttv",w="wearable",x="embedded",S={extend:function(t,e){var r={};for(var n in t)e[n]&&e[n].length%2==0?r[n]=e[n].concat(t[n]):r[n]=t[n];return r},has:function(t,e){return typeof t===u&&-1!==e.toLowerCase().indexOf(t.toLowerCase())},lowerize:function(t){return t.toLowerCase()},major:function(t){return typeof t===u?t.replace(/[^\d\.]/g,"").split(".")[0]:o},trim:function(t,e){return t=t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),typeof e===s?t:t.substring(0,255)}},k={rgx:function(t,e){for(var r,n,i,s,u,l,f=0;f<e.length&&!u;){var p=e[f],d=e[f+1];for(r=n=0;r<p.length&&!u;)if(u=p[r++].exec(t))for(i=0;i<d.length;i++)l=u[++n],typeof(s=d[i])===c&&s.length>0?2==s.length?typeof s[1]==a?this[s[0]]=s[1].call(this,l):this[s[0]]=s[1]:3==s.length?typeof s[1]!==a||s[1].exec&&s[1].test?this[s[0]]=l?l.replace(s[1],s[2]):o:this[s[0]]=l?s[1].call(this,l,s[2]):o:4==s.length&&(this[s[0]]=l?s[3].call(this,l.replace(s[1],s[2])):o):this[s]=l||o;f+=2}},str:function(t,e){for(var r in e)if(typeof e[r]===c&&e[r].length>0){for(var n=0;n<e[r].length;n++)if(S.has(e[r][n],t))return"?"===r?o:r}else if(S.has(e[r],t))return"?"===r?o:r;return t}},O={browser:{oldSafari:{version:{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}},oldEdge:{version:{.1:"12.",21:"13.",31:"14.",39:"15.",41:"16.",42:"17.",44:"18."}}},os:{windows:{version:{ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"}}}},_={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[v,[f,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[v,[f,"Edge"]],[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]{3,6})\b.+version\/([\w\.-]+)/i,/(opera)(?:.+version\/|[\/\s]+)([\w\.]+)/i],[f,v],[/opios[\/\s]+([\w\.]+)/i],[v,[f,"Opera Mini"]],[/\sopr\/([\w\.]+)/i],[v,[f,"Opera"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]*)/i,/(avant\s|iemobile|slim)(?:browser)?[\/\s]?([\w\.]*)/i,/(ba?idubrowser)[\/\s]?([\w\.]+)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon)\/([\w\.-]+)/i,/(rekonq|puffin|brave|whale|qqbrowserlite|qq)\/([\w\.]+)/i,/(weibo)__([\d\.]+)/i],[f,v],[/(?:[\s\/]uc?\s?browser|(?:juc.+)ucweb)[\/\s]?([\w\.]+)/i],[v,[f,"UCBrowser"]],[/(?:windowswechat)?\sqbcore\/([\w\.]+)\b.*(?:windowswechat)?/i],[v,[f,"WeChat(Win) Desktop"]],[/micromessenger\/([\w\.]+)/i],[v,[f,"WeChat"]],[/konqueror\/([\w\.]+)/i],[v,[f,"Konqueror"]],[/trident.+rv[:\s]([\w\.]{1,9})\b.+like\sgecko/i],[v,[f,"IE"]],[/yabrowser\/([\w\.]+)/i],[v,[f,"Yandex"]],[/(avast|avg)\/([\w\.]+)/i],[[f,/(.+)/,"$1 Secure Browser"],v],[/focus\/([\w\.]+)/i],[v,[f,"Firefox Focus"]],[/opt\/([\w\.]+)/i],[v,[f,"Opera Touch"]],[/coc_coc_browser\/([\w\.]+)/i],[v,[f,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[v,[f,"Dolphin"]],[/coast\/([\w\.]+)/i],[v,[f,"Opera Coast"]],[/xiaomi\/miuibrowser\/([\w\.]+)/i],[v,[f,"MIUI Browser"]],[/fxios\/([\w\.-]+)/i],[v,[f,"Firefox"]],[/(qihu|qhbrowser|qihoobrowser|360browser)/i],[[f,"360 Browser"]],[/(oculus|samsung|sailfish)browser\/([\w\.]+)/i],[[f,/(.+)/,"$1 Browser"],v],[/(comodo_dragon)\/([\w\.]+)/i],[[f,/_/g," "],v],[/\s(electron)\/([\w\.]+)\ssafari/i,/(tesla)(?:\sqtcarbrowser|\/(20[12]\d\.[\w\.-]+))/i,/m?(qqbrowser|baiduboxapp|2345Explorer)[\/\s]?([\w\.]+)/i],[f,v],[/(MetaSr)[\/\s]?([\w\.]+)/i,/(LBBROWSER)/i],[f],[/;fbav\/([\w\.]+);/i],[v,[f,"Facebook"]],[/FBAN\/FBIOS|FB_IAB\/FB4A/i],[[f,"Facebook"]],[/safari\s(line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(chromium|instagram)[\/\s]([\w\.-]+)/i],[f,v],[/\bgsa\/([\w\.]+)\s.*safari\//i],[v,[f,"GSA"]],[/headlesschrome(?:\/([\w\.]+)|\s)/i],[v,[f,"Chrome Headless"]],[/\swv\).+(chrome)\/([\w\.]+)/i],[[f,"Chrome WebView"],v],[/droid.+\sversion\/([\w\.]+)\b.+(?:mobile\ssafari|safari)/i],[v,[f,"Android Browser"]],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i],[f,v],[/version\/([\w\.]+)\s.*mobile\/\w+\s(safari)/i],[v,[f,"Mobile Safari"]],[/version\/([\w\.]+)\s.*(mobile\s?safari|safari)/i],[v,f],[/webkit.+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[f,[v,k.str,O.browser.oldSafari.version]],[/(webkit|khtml)\/([\w\.]+)/i],[f,v],[/(navigator|netscape)\/([\w\.-]+)/i],[[f,"Netscape"],v],[/ile\svr;\srv:([\w\.]+)\).+firefox/i],[v,[f,"Firefox Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo\sbrowser|minimo|conkeror)[\/\s]?([\w\.\+]+)/i,/(firefox|seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([\w\.-]+)$/i,/(firefox)\/([\w\.]+)\s[\w\s\-]+\/[\w\.]+$/i,/(mozilla)\/([\w\.]+)\s.+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir)[\/\s]?([\w\.]+)/i,/(links)\s\(([\w\.]+)/i,/(gobrowser)\/?([\w\.]*)/i,/(ice\s?browser)\/v?([\w\._]+)/i,/(mosaic)[\/\s]([\w\.]+)/i],[f,v]],cpu:[[/(?:(amd|x(?:(?:86|64)[_-])?|wow|win)64)[;\)]/i],[[y,"amd64"]],[/(ia32(?=;))/i],[[y,S.lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[y,"ia32"]],[/\b(aarch64|armv?8e?l?)\b/i],[[y,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[y,"armhf"]],[/windows\s(ce|mobile);\sppc;/i],[[y,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?:\smac|;|\))/i],[[y,/ower/,"",S.lowerize]],[/(sun4\w)[;\)]/i],[[y,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?:64|(?=v(?:[1-7]|[5-7]1)l?|;|eabi))|(?=atmel\s)avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[y,S.lowerize]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[pt]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus\s10)/i],[l,[d,"Samsung"],[p,m]],[/\b((?:s[cgp]h|gt|sm)-\w+|galaxy\snexus)/i,/\ssamsung[\s-]([\w-]+)/i,/sec-(sgh\w+)/i],[l,[d,"Samsung"],[p,g]],[/\((ip(?:hone|od)[\s\w]*);/i],[l,[d,"Apple"],[p,g]],[/\((ipad);[\w\s\),;-]+apple/i,/applecoremedia\/[\w\.]+\s\((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[l,[d,"Apple"],[p,m]],[/\b((?:agr|ags[23]|bah2?|sht?)-a?[lw]\d{2})/i],[l,[d,"Huawei"],[p,m]],[/d\/huawei([\w\s-]+)[;\)]/i,/\b(nexus\s6p|vog-[at]?l\d\d|ane-[at]?l[x\d]\d|eml-a?l\d\da?|lya-[at]?l\d[\dc]|clt-a?l\d\di?|ele-l\d\d)/i,/\b(\w{2,4}-[atu][ln][01259][019])[;\)\s]/i],[l,[d,"Huawei"],[p,g]],[/\b(poco[\s\w]+)(?:\sbuild|\))/i,/\b;\s(\w+)\sbuild\/hm\1/i,/\b(hm[\s\-_]?note?[\s_]?(?:\d\w)?)\sbuild/i,/\b(redmi[\s\-_]?(?:note|k)?[\w\s_]+)(?:\sbuild|\))/i,/\b(mi[\s\-_]?(?:a\d|one|one[\s_]plus|note lte)?[\s_]?(?:\d?\w?)[\s_]?(?:plus)?)\sbuild/i],[[l,/_/g," "],[d,"Xiaomi"],[p,g]],[/\b(mi[\s\-_]?(?:pad)(?:[\w\s_]+))(?:\sbuild|\))/i],[[l,/_/g," "],[d,"Xiaomi"],[p,m]],[/;\s(\w+)\sbuild.+\soppo/i,/\s(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007)\b/i],[l,[d,"OPPO"],[p,g]],[/\svivo\s(\w+)(?:\sbuild|\))/i,/\s(v[12]\d{3}\w?[at])(?:\sbuild|;)/i],[l,[d,"Vivo"],[p,g]],[/\s(rmx[12]\d{3})(?:\sbuild|;)/i],[l,[d,"Realme"],[p,g]],[/\s(milestone|droid(?:[2-4x]|\s(?:bionic|x2|pro|razr))?:?(\s4g)?)\b[\w\s]+build\//i,/\smot(?:orola)?[\s-](\w*)/i,/((?:moto[\s\w\(\)]+|xt\d{3,4}|nexus\s6)(?=\sbuild|\)))/i],[l,[d,"Motorola"],[p,g]],[/\s(mz60\d|xoom[\s2]{0,2})\sbuild\//i],[l,[d,"Motorola"],[p,m]],[/((?=lg)?[vl]k\-?\d{3})\sbuild|\s3\.[\s\w;-]{10}lg?-([06cv9]{3,4})/i],[l,[d,"LG"],[p,m]],[/(lm-?f100[nv]?|nexus\s[45])/i,/lg[e;\s\/-]+((?!browser|netcast)\w+)/i,/\blg(\-?[\d\w]+)\sbuild/i],[l,[d,"LG"],[p,g]],[/(ideatab[\w\-\s]+)/i,/lenovo\s?(s(?:5000|6000)(?:[\w-]+)|tab(?:[\s\w]+)|yt[\d\w-]{6}|tb[\d\w-]{6})/i],[l,[d,"Lenovo"],[p,m]],[/(?:maemo|nokia).*(n900|lumia\s\d+)/i,/nokia[\s_-]?([\w\.-]*)/i],[[l,/_/g," "],[d,"Nokia"],[p,g]],[/droid.+;\s(pixel\sc)[\s)]/i],[l,[d,"Google"],[p,m]],[/droid.+;\s(pixel[\s\daxl]{0,6})(?:\sbuild|\))/i],[l,[d,"Google"],[p,g]],[/droid.+\s([c-g]\d{4}|so[-l]\w+|xq-a\w[4-7][12])(?=\sbuild\/|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[l,[d,"Sony"],[p,g]],[/sony\stablet\s[ps]\sbuild\//i,/(?:sony)?sgp\w+(?:\sbuild\/|\))/i],[[l,"Xperia Tablet"],[d,"Sony"],[p,m]],[/\s(kb2005|in20[12]5|be20[12][59])\b/i,/\ba000(1)\sbuild/i,/\boneplus\s(a\d{4})[\s)]/i],[l,[d,"OnePlus"],[p,g]],[/(alexa)webm/i,/(kf[a-z]{2}wi)(\sbuild\/|\))/i,/(kf[a-z]+)(\sbuild\/|\)).+silk\//i],[l,[d,"Amazon"],[p,m]],[/(sd|kf)[0349hijorstuw]+(\sbuild\/|\)).+silk\//i],[[l,"Fire Phone"],[d,"Amazon"],[p,g]],[/\((playbook);[\w\s\),;-]+(rim)/i],[l,d,[p,m]],[/((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10;\s(\w+)/i],[l,[d,"BlackBerry"],[p,g]],[/(?:\b|asus_)(transfo[prime\s]{4,10}\s\w+|eeepc|slider\s\w+|nexus\s7|padfone|p00[cj])/i],[l,[d,"ASUS"],[p,m]],[/\s(z[es]6[027][01][km][ls]|zenfone\s\d\w?)\b/i],[l,[d,"ASUS"],[p,g]],[/(nexus\s9)/i],[l,[d,"HTC"],[p,m]],[/(htc)[;_\s-]{1,2}([\w\s]+(?=\)|\sbuild)|\w+)/i,/(zte)-(\w*)/i,/(alcatel|geeksphone|nexian|panasonic|(?=;\s)sony)[_\s-]?([\w-]*)/i],[d,[l,/_/g," "],[p,g]],[/droid[x\d\.\s;]+\s([ab][1-7]\-?[0178a]\d\d?)/i],[l,[d,"Acer"],[p,m]],[/droid.+;\s(m[1-5]\snote)\sbuild/i,/\bmz-([\w-]{2,})/i],[l,[d,"Meizu"],[p,g]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[\s_-]?([\w-]*)/i,/(hp)\s([\w\s]+\w)/i,/(asus)-?(\w+)/i,/(microsoft);\s(lumia[\s\w]+)/i,/(lenovo)[_\s-]?([\w-]+)/i,/linux;.+(jolla);/i,/droid.+;\s(oppo)\s?([\w\s]+)\sbuild/i],[d,l,[p,g]],[/(archos)\s(gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/\s(nook)[\w\s]+build\/(\w+)/i,/(dell)\s(strea[kpr\s\d]*[\dko])/i,/[;\/]\s?(le[\s\-]+pan)[\s\-]+(\w{1,9})\sbuild/i,/[;\/]\s?(trinity)[\-\s]*(t\d{3})\sbuild/i,/\b(gigaset)[\s\-]+(q\w{1,9})\sbuild/i,/\b(vodafone)\s([\w\s]+)(?:\)|\sbuild)/i],[d,l,[p,m]],[/\s(surface\sduo)\s/i],[l,[d,"Microsoft"],[p,m]],[/droid\s[\d\.]+;\s(fp\du?)\sbuild/i],[l,[d,"Fairphone"],[p,g]],[/\s(u304aa)\sbuild/i],[l,[d,"AT&T"],[p,g]],[/sie-(\w*)/i],[l,[d,"Siemens"],[p,g]],[/[;\/]\s?(rct\w+)\sbuild/i],[l,[d,"RCA"],[p,m]],[/[;\/\s](venue[\d\s]{2,7})\sbuild/i],[l,[d,"Dell"],[p,m]],[/[;\/]\s?(q(?:mv|ta)\w+)\sbuild/i],[l,[d,"Verizon"],[p,m]],[/[;\/]\s(?:barnes[&\s]+noble\s|bn[rt])([\w\s\+]*)\sbuild/i],[l,[d,"Barnes & Noble"],[p,m]],[/[;\/]\s(tm\d{3}\w+)\sbuild/i],[l,[d,"NuVision"],[p,m]],[/;\s(k88)\sbuild/i],[l,[d,"ZTE"],[p,m]],[/;\s(nx\d{3}j)\sbuild/i],[l,[d,"ZTE"],[p,g]],[/[;\/]\s?(gen\d{3})\sbuild.*49h/i],[l,[d,"Swiss"],[p,g]],[/[;\/]\s?(zur\d{3})\sbuild/i],[l,[d,"Swiss"],[p,m]],[/[;\/]\s?((zeki)?tb.*\b)\sbuild/i],[l,[d,"Zeki"],[p,m]],[/[;\/]\s([yr]\d{2})\sbuild/i,/[;\/]\s(dragon[\-\s]+touch\s|dt)(\w{5})\sbuild/i],[[d,"Dragon Touch"],l,[p,m]],[/[;\/]\s?(ns-?\w{0,9})\sbuild/i],[l,[d,"Insignia"],[p,m]],[/[;\/]\s?((nxa|Next)-?\w{0,9})\sbuild/i],[l,[d,"NextBook"],[p,m]],[/[;\/]\s?(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05]))\sbuild/i],[[d,"Voice"],l,[p,g]],[/[;\/]\s?(lvtel\-)?(v1[12])\sbuild/i],[[d,"LvTel"],l,[p,g]],[/;\s(ph-1)\s/i],[l,[d,"Essential"],[p,g]],[/[;\/]\s?(v(100md|700na|7011|917g).*\b)\sbuild/i],[l,[d,"Envizen"],[p,m]],[/[;\/]\s?(trio[\s\w\-\.]+)\sbuild/i],[l,[d,"MachSpeed"],[p,m]],[/[;\/]\s?tu_(1491)\sbuild/i],[l,[d,"Rotor"],[p,m]],[/(shield[\w\s]+)\sbuild/i],[l,[d,"Nvidia"],[p,m]],[/(sprint)\s(\w+)/i],[d,l,[p,g]],[/(kin\.[onetw]{3})/i],[[l,/\./g," "],[d,"Microsoft"],[p,g]],[/droid\s[\d\.]+;\s(cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[l,[d,"Zebra"],[p,m]],[/droid\s[\d\.]+;\s(ec30|ps20|tc[2-8]\d[kx])\)/i],[l,[d,"Zebra"],[p,g]],[/\s(ouya)\s/i,/(nintendo)\s([wids3utch]+)/i],[d,l,[p,h]],[/droid.+;\s(shield)\sbuild/i],[l,[d,"Nvidia"],[p,h]],[/(playstation\s[345portablevi]+)/i],[l,[d,"Sony"],[p,h]],[/[\s\(;](xbox(?:\sone)?(?!;\sxbox))[\s\);]/i],[l,[d,"Microsoft"],[p,h]],[/smart-tv.+(samsung)/i],[d,[p,b]],[/hbbtv.+maple;(\d+)/i],[[l,/^/,"SmartTV"],[d,"Samsung"],[p,b]],[/(?:linux;\snetcast.+smarttv|lg\snetcast\.tv-201\d)/i],[[d,"LG"],[p,b]],[/(apple)\s?tv/i],[d,[l,"Apple TV"],[p,b]],[/crkey/i],[[l,"Chromecast"],[d,"Google"],[p,b]],[/droid.+aft([\w])(\sbuild\/|\))/i],[l,[d,"Amazon"],[p,b]],[/\(dtv[\);].+(aquos)/i],[l,[d,"Sharp"],[p,b]],[/hbbtv\/\d+\.\d+\.\d+\s+\([\w\s]*;\s*(\w[^;]*);([^;]*)/i],[[d,S.trim],[l,S.trim],[p,b]],[/[\s\/\(](android\s|smart[-\s]?|opera\s)tv[;\)\s]/i],[[p,b]],[/((pebble))app\/[\d\.]+\s/i],[d,l,[p,w]],[/droid.+;\s(glass)\s\d/i],[l,[d,"Google"],[p,w]],[/droid\s[\d\.]+;\s(wt63?0{2,3})\)/i],[l,[d,"Zebra"],[p,w]],[/(tesla)(?:\sqtcarbrowser|\/20[12]\d\.[\w\.-]+)/i],[d,[p,x]],[/droid .+?; ([^;]+?)(?: build|\) applewebkit).+? mobile safari/i],[l,[p,g]],[/droid .+?;\s([^;]+?)(?: build|\) applewebkit).+?(?! mobile) safari/i],[l,[p,m]],[/\s(tablet|tab)[;\/]/i,/\s(mobile)(?:[;\/]|\ssafari)/i],[[p,S.lowerize]],[/(android[\w\.\s\-]{0,9});.+build/i],[l,[d,"Generic"]],[/(phone)/i],[[p,g]]],engine:[[/windows.+\sedge\/([\w\.]+)/i],[v,[f,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[v,[f,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/\s]\(?([\w\.]+)/i,/(icab)[\/\s]([23]\.[\d\.]+)/i],[f,v],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[v,f]],os:[[/microsoft\s(windows)\s(vista|xp)/i],[f,v],[/(windows)\snt\s6\.2;\s(arm)/i,/(windows\sphone(?:\sos)*)[\s\/]?([\d\.\s\w]*)/i,/(windows\smobile|windows)[\s\/]?([ntce\d\.\s]+\w)(?!.+xbox)/i],[f,[v,k.str,O.os.windows.version]],[/(win(?=3|9|n)|win\s9x\s)([nt\d\.]+)/i],[[f,"Windows"],[v,k.str,O.os.windows.version]],[/ip[honead]{2,4}\b(?:.*os\s([\w]+)\slike\smac|;\sopera)/i,/cfnetwork\/.+darwin/i],[[v,/_/g,"."],[f,"iOS"]],[/(mac\sos\sx)\s?([\w\s\.]*)/i,/(macintosh|mac(?=_powerpc)\s)(?!.+haiku)/i],[[f,"Mac OS"],[v,/_/g,"."]],[/(android|webos|palm\sos|qnx|bada|rim\stablet\sos|meego|sailfish|contiki)[\/\s-]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/\s]([\w\.]+)/i,/\((series40);/i],[f,v],[/\(bb(10);/i],[v,[f,"BlackBerry"]],[/(?:symbian\s?os|symbos|s60(?=;)|series60)[\/\s-]?([\w\.]*)/i],[v,[f,"Symbian"]],[/mozilla.+\(mobile;.+gecko.+firefox/i],[[f,"Firefox OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[v,[f,"webOS"]],[/crkey\/([\d\.]+)/i],[v,[f,"Chromecast"]],[/(cros)\s[\w]+\s([\w\.]+\w)/i],[[f,"Chromium OS"],v],[/(nintendo|playstation)\s([wids345portablevuch]+)/i,/(xbox);\s+xbox\s([^\);]+)/i,/(mint)[\/\s\(\)]?(\w*)/i,/(mageia|vectorlinux)[;\s]/i,/(joli|[kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?=\slinux)|slackware|fedora|mandriva|centos|pclinuxos|redhat|zenwalk|linpus|raspbian)(?:\sgnu\/linux)?(?:\slinux)?[\/\s-]?(?!chrom|package)([\w\.-]*)/i,/(hurd|linux)\s?([\w\.]*)/i,/(gnu)\s?([\w\.]*)/i,/\s([frentopc-]{0,4}bsd|dragonfly)\s?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku)\s(\w+)/i],[f,v],[/(sunos)\s?([\w\.\d]*)/i],[[f,"Solaris"],v],[/((?:open)?solaris)[\/\s-]?([\w\.]*)/i,/(aix)\s((\d)(?=\.|\)|\s)[\w\.])*/i,/(plan\s9|minix|beos|os\/2|amigaos|morphos|risc\sos|openvms|fuchsia)/i,/(unix)\s?([\w\.]*)/i],[f,v]]},E=function(t,e){if("object"==typeof t&&(e=t,t=o),!(this instanceof E))return new E(t,e).getResult();var r=t||(void 0!==i&&i.navigator&&i.navigator.userAgent?i.navigator.userAgent:""),n=e?S.extend(_,e):_;return this.getBrowser=function(){var t={name:o,version:o};return k.rgx.call(t,r,n.browser),t.major=S.major(t.version),t},this.getCPU=function(){var t={architecture:o};return k.rgx.call(t,r,n.cpu),t},this.getDevice=function(){var t={vendor:o,model:o,type:o};return k.rgx.call(t,r,n.device),t},this.getEngine=function(){var t={name:o,version:o};return k.rgx.call(t,r,n.engine),t},this.getOS=function(){var t={name:o,version:o};return k.rgx.call(t,r,n.os),t},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return r},this.setUA=function(t){return r=typeof t===u&&t.length>255?S.trim(t,255):t,this},this.setUA(r),this};E.VERSION="0.7.28",E.BROWSER={NAME:f,MAJOR:"major",VERSION:v},E.CPU={ARCHITECTURE:y},E.DEVICE={MODEL:l,VENDOR:d,TYPE:p,CONSOLE:h,MOBILE:g,SMARTTV:b,TABLET:m,WEARABLE:w,EMBEDDED:x},E.ENGINE={NAME:f,VERSION:v},E.OS={NAME:f,VERSION:v},typeof e!==s?(t.exports&&(e=t.exports=E),e.UAParser=E):(n=function(){return E}.call(e,r,e,t))===o||(t.exports=n);var A=void 0!==i&&(i.jQuery||i.Zepto);if(A&&!A.ua){var R=new E;A.ua=R.getResult(),A.ua.get=function(){return R.getUA()},A.ua.set=function(t){R.setUA(t);var e=R.getResult();for(var r in e)A.ua[r]=e[r]}}}("object"==typeof window?window:this)},4078:function(t,e,r){var n,i,o;o=function(){function t(t){var e=[];if(0===t.length)return"";if("string"!=typeof t[0])throw new TypeError("Url must be a string. Received "+t[0]);if(t[0].match(/^[^/:]+:\/*$/)&&t.length>1){var r=t.shift();t[0]=r+t[0]}t[0].match(/^file:\/\/\//)?t[0]=t[0].replace(/^([^/:]+):\/*/,"$1:///"):t[0]=t[0].replace(/^([^/:]+):\/*/,"$1://");for(var n=0;n<t.length;n++){var i=t[n];if("string"!=typeof i)throw new TypeError("Url must be a string. Received "+i);""!==i&&(n>0&&(i=i.replace(/^[\/]+/,"")),i=n<t.length-1?i.replace(/[\/]+$/,""):i.replace(/[\/]+$/,"/"),e.push(i))}var o=e.join("/"),a=(o=o.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return a.shift()+(a.length>0?"?":"")+a.join("&")}return function(){return t("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},t.exports?t.exports=o():void 0===(i="function"==typeof(n=o)?n.call(e,r,e,t):n)||(t.exports=i)},4654:()=>{}},e={};function r(n){var i=e[n];if(void 0!==i)return i.exports;var o=e[n]={id:n,loaded:!1,exports:{}};return t[n].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var n={};(()=>{r.d(n,{De:()=>_r,Vj:()=>kr,cf:()=>xr,hi:()=>p,u_:()=>yr});const t={getActivityTypes:function(t){return{url:"activities/types",method:"get",params:{appSecret:t.appSecret}}},getActivityList:function(t){return{url:"activities/list",method:"get",params:{appSecret:t.appSecret,include:t.include}}},getActivityDetail:function(t){return{url:"activities",method:"get",params:{activityNo:t.activityNo,appSecret:t.appSecret}}},getAchievements:function(t){return{url:"activities/achievements",method:"get",params:{limit:t.limit,page:t.page,appSecret:t.appSecret}}},getAchievementsProgress:function(t){return{url:"activities/achievements/progress",method:"get",params:{achievementNo:t.achievementNo,appSecret:t.appSecret}}},getAchievementsIssued:function(){return{url:"activities/achievements/issue",method:"get"}},postPromoCode:function(t){return{url:"activities/promo",method:"post",params:{promoCode:t}}},sentAward:function(t){return{url:"activities/sentAward",method:"post",params:{activityNo:t.activityNo,gender:t.gender,email:t.email,score:t.score,suggest:t.suggest,uidSite:t.uidSite,affiliateCode:t.affiliateCode,appSecret:t.appSecret}}},getReward:function(t){return{url:"activities/rewards",method:"post",params:{activityNo:t.activityNo,receiveNo:t.receiveNo,appSecret:t.appSecret}}},getRewardList:function(t){return{url:"activities/rewards",method:"get",params:{count:t.count,appSecret:t.appSecret}}},exchange:function(t){return{url:"activities/exchange",method:"post",params:t}},collect:function(t){return{url:"activities/collect",method:"post",params:{appSecret:t.appSecret}}}},e={login:function(t){return{url:"login",method:"post",params:{username:t.username,password:t.password,provider:t.provider,countryCode:t.countryCode,phone:t.phone},isPublic:!0}},register:function(t){return{url:"register?channel=official&subchannel=pwa",method:"post",params:t,isPublic:!0}},logout:function(){return{url:"logout",method:"post"}}},i={getConfig:function(t){return{url:"getConfig",method:"get",params:{appSecret:t.appSecret},isPublic:!0}},feeds:function(t){return{url:"feeds",method:"get",params:{appSecret:t.appSecret},isPublic:!0}}},o={getGameSHA:function(){return{method:"get",url:"game/list/v2/sha"}},getOptionMap:function(t){return{method:"get",url:"game/list/v2/options",params:{code:t}}},getGameStatus:function(){return{method:"get",url:"game/list/v2/status"}},getGameCategory:function(t){return{method:"get",url:"game/list/v2/category",params:{id:t.id,first:t.first}}},addFavoriteGame:function(t){return{method:"post",url:"game/myfavorite/add",params:{games:[t]}}},removeFavoriteGame:function(t){return{method:"post",url:"game/myfavorite/remove",params:{games:[t]}}},getStatements:function(){return{url:"game/statements",method:"get"}},playGame:function(t){return{url:"game/play",method:"get",params:t}},logoutGame:function(t){return{url:"game/logout",method:"get",params:{uid_site:t.uid_site,provider_id:t.provider_id}}},getGameTags:function(t){return{url:"game/search",method:"get",params:{q:t.q}}},getGameSearchList:function(t){return{url:"game/search/list",method:"get",params:{id:t.id,index:t.index,q:t.q,click:t.click,clickDefault:t.clickDefault}}},setGameSearchTrace:function(t){return{url:"game/search/trace",method:"post",params:{traceId:t.traceId,tagId:t.tagId,tagIndex:t.tagIndex,gameCode:t.gameCode,gameCodeIndex:t.gameCodeIndex,query:t.query,click:t.click,clickDefault:t.clickDefault}}}},a={getMessageTypes:function(){return{url:"mailbox/getMessageTypes",method:"get"}},getMessageList:function(t){var e=t.type,r=t.limit;return{url:"mailbox/getMessageList?include=cl",method:"post",params:{type:e,limit:void 0===r?10:r,page:t.page}}},updateMessage:function(t){return{url:"mailbox/updateMessage",method:"post",params:{groupId:t.groupId,isRead:t.isRead}}},sendMessage:function(){return{url:"mailbox/sendMessage",method:"post"}},getMessage:function(t){var e=t.groupId,r=t.limit;return{url:"mailbox/getMessage",method:"post",params:{groupId:e,limit:void 0===r?10:r,pageIdx:t.pageIdx}}},deleteMessage:function(t){return{url:"mailbox/deleteMessage",method:"post",params:{mid:t.mid,isDelete:t.isDelete}}}};function s(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function c(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?s(Object(r),!0).forEach((function(e){u(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}const l={getPaymentHistory:function(t){return{url:"payment/v2/history",method:"post",params:{returnDays:t}}},getSpotMarket:function(){return{url:"payment/spotmarket",method:"get"}},getPaymentInfo:function(){return{url:"payment/paymentInfo",method:"get"}},updatePaymentInfo:function(t){return{url:"payment/updatePaymentInfo",method:"post",params:{bankCode:t.bankCode,bankAccount:t.bankAccount,firstNameTh:t.firstNameTh,lastNameTh:t.lastNameTh,firstNameEn:t.firstNameEn,lastNameEn:t.lastNameEn,bonus:t.bonus,paymentProvider:t.paymentProvider}}},getBankList:function(t){return{url:"payment/".concat(t,"/getBankList"),method:"get"}},makeTransaction:function(t){var e=t.type,r=t.payload,n=t.paymentMethod;return{url:"payment/".concat(n,"/transaction"),method:"post",params:c({transferType:e},r)}},checkTransaction:function(t){return{url:"payment/".concat(t,"/checkTransaction"),method:"post"}},setBonusSetting:function(t){return{url:"payment/setting",method:"post",params:{bonus:t.bonus}}},getCurrentWithdrawRule:function(){return{url:"payment/getCurrentWithdrawRule",method:"get"}},convertFreeCredit:function(t){return{url:"payment/convertFreeCredit",method:"post",params:{exchangeType:t.exchangeType,cryptoNetwork:t.cryptoNetwork,targetAddress:t.targetAddress}}},mergeWallet:function(){return{url:"payment/mergeWallet",method:"post"}},getPaymentDetail:function(t){return{url:"payment/v2/paymentDetail",method:"post",params:{transferType:t.transferType}}},getDepositExpectedResult:function(t){var e=t.method,r=t.amount,n=t.cryptoCurrency;return{url:"payment/v2/".concat(e,"/expected/result"),method:"post",params:{transferType:"DEPOSIT",amount:r,cryptoCurrency:n}}},getWithdrawExpectedResult:function(t){var e=t.method,r=t.amount,n=t.cryptoNetwork;return{url:"payment/v2/".concat(e,"/expected/result"),method:"post",params:{transferType:"WITHDRAW",amount:r,cryptoNetwork:n}}},submitDepositTransaction:function(t){var e=t.method,r=t.amount,n=t.cryptoCurrency,i=t.cryptoNetwork;return{url:"payment/v2/".concat(e,"/transaction"),method:"post",params:{transferType:"DEPOSIT",amount:r,cryptoCurrency:n,cryptoNetwork:i}}},submitWithdrawTransaction:function(t){var e=t.method,r=t.amount,n=t.cryptoCurrency,i=t.cryptoNetwork,o=t.targetAddress;return{url:"payment/v2/".concat(e,"/transaction"),method:"post",params:{transferType:"WITHDRAW",amount:r,cryptoCurrency:n,cryptoNetwork:i,targetAddress:o}}}},f={getUserInfo:function(){return{url:"self",method:"get"}},modifyUserInfo:function(t){return{url:"self",method:"post",params:t}},changePassword:function(t){return{url:"settings/password",method:"post",params:t}},setPreference:function(t){return{url:"settings/preference",method:"post",params:{defaultCategory:t.defaultCategory}}},resetOtp:function(t){return{url:"reset",method:"post",params:{requestId:t.requestId,number:t.number}}},getAffiliate:function(){return{url:"affiliate",method:"get"}},postAffiliate:function(t){return{url:"affiliate",method:"post",params:{affiliateCode:t.affiliateCode}}},passwordRecovery:function(t){return{url:"recovery",method:"post",params:t,isPublic:!0}},passwordAbandon:function(t){return{url:"recovery/abandon",method:"post",params:{number:t.number},isPublic:!0}},passwordAcknowledge:function(t){return{url:"recovery/acknowledge",method:"post",params:t,isPublic:!0}},verify:function(){return{url:"verify",method:"post"}},acknowledge:function(t){return{url:"acknowledge",method:"post",params:{requestId:t.requestId,code:t.code}}}},p={activity:t,auth:e,core:i,game:o,mailbox:a,payment:l,user:f};var d=function(){return d=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},d.apply(this,arguments)};function v(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(t);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i])&&(r[n[i]]=t[n[i]])}return r}function y(t){var e="function"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function h(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,i,o=r.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(t){i={error:t}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}function g(t,e){for(var r=0,n=e.length,i=t.length;r<n;r++,i++)t[i]=e[r];return t}var m={},b="xstate.guard";function w(t){return Object.keys(t)}function x(t,e,r){void 0===r&&(r=".");var n=O(t,r),i=O(e,r);return W(i)?!!W(n)&&i===n:W(n)?n in i:w(n).every((function(t){return t in i&&x(n[t],i[t])}))}function S(t){try{return W(t)||"number"==typeof t?""+t:t.type}catch(t){throw new Error("Events must be strings or objects with a string event.type property.")}}function k(t,e){try{return G(t)?t:t.toString().split(e)}catch(e){throw new Error("'"+t+"' is not a valid state path.")}}function O(t,e){return"object"==typeof(r=t)&&"value"in r&&"context"in r&&"event"in r&&"_event"in r?t.value:G(t)?_(t):"string"!=typeof t?t:_(k(t,e));var r}function _(t){if(1===t.length)return t[0];for(var e={},r=e,n=0;n<t.length-1;n++)n===t.length-2?r[t[n]]=t[n+1]:(r[t[n]]={},r=r[t[n]]);return e}function E(t,e){for(var r={},n=w(t),i=0;i<n.length;i++){var o=n[i];r[o]=e(t[o],o,t,i)}return r}function A(t,e,r){var n,i,o={};try{for(var a=y(w(t)),s=a.next();!s.done;s=a.next()){var c=s.value,u=t[c];r(u)&&(o[c]=e(u,c,t))}}catch(t){n={error:t}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}return o}var R=function(t){return function(e){var r,n,i=e;try{for(var o=y(t),a=o.next();!a.done;a=o.next())i=i[a.value]}catch(t){r={error:t}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return i}};function T(t){return t?W(t)?[[t]]:j(w(t).map((function(e){var r=t[e];return"string"==typeof r||r&&Object.keys(r).length?T(t[e]).map((function(t){return[e].concat(t)})):[[e]]}))):[[]]}function j(t){var e;return(e=[]).concat.apply(e,g([],h(t)))}function I(t){return G(t)?t:[t]}function P(t){return void 0===t?[]:I(t)}function N(t,e,r){var n,i;if(V(t))return t(e,r.data);var o={};try{for(var a=y(Object.keys(t)),s=a.next();!s.done;s=a.next()){var c=s.value,u=t[c];V(u)?o[c]=u(e,r.data):o[c]=u}}catch(t){n={error:t}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}return o}function C(t,e){var r,n,i=h([[],[]],2),o=i[0],a=i[1];try{for(var s=y(t),c=s.next();!c.done;c=s.next()){var u=c.value;e(u)?o.push(u):a.push(u)}}catch(t){r={error:t}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return[o,a]}function D(t,e){return E(t.states,(function(t,r){if(t){var n=(W(e)?void 0:e[r])||(t?t.current:void 0);if(n)return{current:n,states:D(t,n)}}}))}function L(t,e,r,n){return t?r.reduce((function(t,r){var i,o,a=r.assignment,s={state:n,action:r,_event:e},c={};if(V(a))c=a(t,e.data,s);else try{for(var u=y(w(a)),l=u.next();!l.done;l=u.next()){var f=l.value,p=a[f];c[f]=V(p)?p(t,e.data,s):p}}catch(t){i={error:t}}finally{try{l&&!l.done&&(o=u.return)&&o.call(u)}finally{if(i)throw i.error}}return Object.assign({},t,c)}),t):t}var M,U,F,B;function G(t){return Array.isArray(t)}function V(t){return"function"==typeof t}function W(t){return"string"==typeof t}function q(t,e){if(t)return W(t)?{type:b,name:t,predicate:e?e[t]:void 0}:V(t)?{type:b,name:t.name,predicate:t}:t}function H(t){try{return"__xstatenode"in t}catch(t){return!1}}function z(t,e){return W(t)||"number"==typeof t?d({type:t},e):t}function $(t,e){if(!W(t)&&"$$type"in t&&"scxml"===t.$$type)return t;var r=z(t);return d({name:r.type,data:r,$$type:"scxml",type:"external"},e)}function Y(t,e){return I(e).map((function(e){return void 0===e||"string"==typeof e||H(e)?{target:e,event:t}:d(d({},e),{event:t})}))}function K(t,e,r,n,i){var o=t.options.guards,a={state:i,cond:e,_event:n};if(e.type===b)return((null==o?void 0:o[e.name])||e.predicate)(r,n.data,a);var s=o[e.type];if(!s)throw new Error("Guard '"+e.type+"' is not implemented on machine '"+t.id+"'.");return s(r,n.data,a)}(B=M||(M={})).Start="xstate.start",B.Stop="xstate.stop",B.Raise="xstate.raise",B.Send="xstate.send",B.Cancel="xstate.cancel",B.NullEvent="",B.Assign="xstate.assign",B.After="xstate.after",B.DoneState="done.state",B.DoneInvoke="done.invoke",B.Log="xstate.log",B.Init="xstate.init",B.Invoke="xstate.invoke",B.ErrorExecution="error.execution",B.ErrorCommunication="error.communication",B.ErrorPlatform="error.platform",B.ErrorCustom="xstate.error",B.Update="xstate.update",B.Pure="xstate.pure",B.Choose="xstate.choose",(F=U||(U={})).Parent="#_parent",F.Internal="#_internal";var J=function(t){return"atomic"===t.type||"final"===t.type};function Q(t){return w(t.states).map((function(e){return t.states[e]}))}function X(t){var e=[t];return J(t)?e:e.concat(j(Q(t).map(X)))}function Z(t,e){var r,n,i,o,a,s,c,u,l=et(new Set(t)),f=new Set(e);try{for(var p=y(f),d=p.next();!d.done;d=p.next())for(var v=(O=d.value).parent;v&&!f.has(v);)f.add(v),v=v.parent}catch(t){r={error:t}}finally{try{d&&!d.done&&(n=p.return)&&n.call(p)}finally{if(r)throw r.error}}var h=et(f);try{for(var g=y(f),m=g.next();!m.done;m=g.next())if("compound"!==(O=m.value).type||h.get(O)&&h.get(O).length){if("parallel"===O.type)try{for(var b=(a=void 0,y(Q(O))),w=b.next();!w.done;w=b.next()){var x=w.value;"history"!==x.type&&(f.has(x)||(f.add(x),l.get(x)?l.get(x).forEach((function(t){return f.add(t)})):x.initialStateNodes.forEach((function(t){return f.add(t)}))))}}catch(t){a={error:t}}finally{try{w&&!w.done&&(s=b.return)&&s.call(b)}finally{if(a)throw a.error}}}else l.get(O)?l.get(O).forEach((function(t){return f.add(t)})):O.initialStateNodes.forEach((function(t){return f.add(t)}))}catch(t){i={error:t}}finally{try{m&&!m.done&&(o=g.return)&&o.call(g)}finally{if(i)throw i.error}}try{for(var S=y(f),k=S.next();!k.done;k=S.next()){var O;for(v=(O=k.value).parent;v&&!f.has(v);)f.add(v),v=v.parent}}catch(t){c={error:t}}finally{try{k&&!k.done&&(u=S.return)&&u.call(S)}finally{if(c)throw c.error}}return f}function tt(t,e){var r=e.get(t);if(!r)return{};if("compound"===t.type){var n=r[0];if(!n)return{};if(J(n))return n.key}var i={};return r.forEach((function(t){i[t.key]=tt(t,e)})),i}function et(t){var e,r,n=new Map;try{for(var i=y(t),o=i.next();!o.done;o=i.next()){var a=o.value;n.has(a)||n.set(a,[]),a.parent&&(n.has(a.parent)||n.set(a.parent,[]),n.get(a.parent).push(a))}}catch(t){e={error:t}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(e)throw e.error}}return n}function rt(t,e){return tt(t,et(Z([t],e)))}function nt(t,e){return Array.isArray(t)?t.some((function(t){return t===e})):t instanceof Set&&t.has(e)}function it(t,e){return"compound"===e.type?Q(e).some((function(e){return"final"===e.type&&nt(t,e)})):"parallel"===e.type&&Q(e).every((function(e){return it(t,e)}))}var ot=M.Start,at=M.Stop,st=M.Raise,ct=M.Send,ut=M.Cancel,lt=M.NullEvent,ft=M.Assign,pt=(M.After,M.DoneState,M.Log),dt=M.Init,vt=M.Invoke,yt=(M.ErrorExecution,M.ErrorPlatform,M.ErrorCustom,M.Update),ht=M.Choose,gt=M.Pure,mt=$({type:dt});function bt(t,e){return e&&e[t]||void 0}function wt(t,e){var r;if(W(t)||"number"==typeof t)r=V(n=bt(t,e))?{type:t,exec:n}:n||{type:t,exec:void 0};else if(V(t))r={type:t.name||t.toString(),exec:t};else{var n;if(V(n=bt(t.type,e)))r=d(d({},t),{exec:n});else if(n){var i=n.type||t.type;r=d(d(d({},n),t),{type:i})}else r=t}return r}var xt=function(t,e){return t?(G(t)?t:[t]).map((function(t){return wt(t,e)})):[]};function St(t){var e=wt(t);return d(d({id:W(t)?t:e.id},e),{type:e.type})}function kt(t){return W(t)?{type:st,event:t}:Ot(t,{to:U.Internal})}function Ot(t,e){return{to:e?e.to:void 0,type:ct,event:V(t)?t:z(t),delay:e?e.delay:void 0,id:e&&void 0!==e.id?e.id:V(t)?t.name:S(t)}}var _t=function(t){return{type:ft,assignment:t}};function Et(t,e){var r=M.DoneState+"."+t;return{type:r,data:e,toString:function(){return r}}}function At(t,e,r,n,i,o){void 0===o&&(o=!1);var a=h(o?[[],i]:C(i,(function(t){return t.type===ft})),2),s=a[0],c=a[1],u=s.length?L(r,n,s,e):r,l=o?[r]:void 0,f=j(c.map((function(r){var i;switch(r.type){case st:return{type:st,_event:$(r.event)};case ct:var a=function(t,e,r,n){var i,o={_event:r},a=$(V(t.event)?t.event(e,r.data,o):t.event);if(W(t.delay)){var s=n&&n[t.delay];i=V(s)?s(e,r.data,o):s}else i=V(t.delay)?t.delay(e,r.data,o):t.delay;var c=V(t.to)?t.to(e,r.data,o):t.to;return d(d({},t),{to:c,_event:a,event:a.data,delay:i})}(r,u,n,t.options.delays);return a;case pt:return function(t,e,r){return d(d({},t),{value:W(t.expr)?t.expr:t.expr(e,r.data,{_event:r})})}(r,u,n);case ht:if(!(p=null===(i=r.conds.find((function(r){var i=q(r.cond,t.options.guards);return!i||K(t,i,u,n,e)})))||void 0===i?void 0:i.actions))return[];var s=h(At(t,e,u,n,xt(P(p),t.options.actions),o),2),c=s[0],f=s[1];return u=f,null==l||l.push(u),c;case gt:var p;if(!(p=r.get(u,n.data)))return[];var v=h(At(t,e,u,n,xt(P(p),t.options.actions),o),2),y=v[0],m=v[1];return u=m,null==l||l.push(u),y;case at:return function(t,e,r){var n=V(t.activity)?t.activity(e,r.data):t.activity,i="string"==typeof n?{id:n}:n;return{type:M.Stop,activity:i}}(r,u,n);case ft:u=L(u,n,[r],e),null==l||l.push(u);break;default:var b=wt(r,t.options.actions),w=b.exec;if(w&&l){var x=l.length-1;b=d(d({},b),{exec:function(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];w.apply(void 0,g([l[x]],h(e)))}})}return b}})).filter((function(t){return!!t})));return[f,u]}function Rt(t,e){if(t===e)return!0;if(void 0===t||void 0===e)return!1;if(W(t)||W(e))return t===e;var r=w(t),n=w(e);return r.length===n.length&&r.every((function(r){return Rt(t[r],e[r])}))}var Tt=function(){function t(t){var e,r,n=this;this.actions=[],this.activities=m,this.meta={},this.events=[],this.value=t.value,this.context=t.context,this._event=t._event,this._sessionid=t._sessionid,this.event=this._event.data,this.historyValue=t.historyValue,this.history=t.history,this.actions=t.actions||[],this.activities=t.activities||m,this.meta=(void 0===(r=t.configuration)&&(r=[]),r.reduce((function(t,e){return void 0!==e.meta&&(t[e.id]=e.meta),t}),{})),this.events=t.events||[],this.matches=this.matches.bind(this),this.toStrings=this.toStrings.bind(this),this.configuration=t.configuration,this.transitions=t.transitions,this.children=t.children,this.done=!!t.done,this.tags=null!==(e=Array.isArray(t.tags)?new Set(t.tags):t.tags)&&void 0!==e?e:new Set,this.machine=t.machine,Object.defineProperty(this,"nextEvents",{get:function(){return function(t){return g([],h(new Set(j(g([],h(t.map((function(t){return t.ownEvents}))))))))}(n.configuration)}})}return t.from=function(e,r){return e instanceof t?e.context!==r?new t({value:e.value,context:r,_event:e._event,_sessionid:null,historyValue:e.historyValue,history:e.history,actions:[],activities:e.activities,meta:{},events:[],configuration:[],transitions:[],children:{}}):e:new t({value:e,context:r,_event:mt,_sessionid:null,historyValue:void 0,history:void 0,actions:[],activities:void 0,meta:void 0,events:[],configuration:[],transitions:[],children:{}})},t.create=function(e){return new t(e)},t.inert=function(e,r){if(e instanceof t){if(!e.actions.length)return e;var n=mt;return new t({value:e.value,context:r,_event:n,_sessionid:null,historyValue:e.historyValue,history:e.history,activities:e.activities,configuration:e.configuration,transitions:[],children:{}})}return t.from(e,r)},t.prototype.toStrings=function(t,e){var r=this;if(void 0===t&&(t=this.value),void 0===e&&(e="."),W(t))return[t];var n=w(t);return n.concat.apply(n,g([],h(n.map((function(n){return r.toStrings(t[n],e).map((function(t){return n+e+t}))})))))},t.prototype.toJSON=function(){var t=this,e=(t.configuration,t.transitions,t.tags),r=(t.machine,v(t,["configuration","transitions","tags","machine"]));return d(d({},r),{tags:Array.from(e)})},t.prototype.matches=function(t){return x(t,this.value)},t.prototype.hasTag=function(t){return this.tags.has(t)},t.prototype.can=function(t){var e;return this.machine,!!(null===(e=this.machine)||void 0===e?void 0:e.transition(this,t).changed)},t}(),jt=[];function It(t){return{id:t,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},getSnapshot:function(){},toJSON:function(){return{id:t}}}}function Pt(t,e,r,n){var i,o,a="string"==typeof(o=t.src)?{type:o}:o,s=null===(i=null==e?void 0:e.options.services)||void 0===i?void 0:i[a.type],c=t.data?N(t.data,r,n):void 0,u=s?function(t,e,r){var n=It(e);if(n.deferred=!0,H(t)){var i=n.state=function(e,n){jt.push(e);var i=(r?t.withContext(r):t).initialState;return jt.pop(),i}(void 0);n.getSnapshot=function(){return i}}return n}(s,t.id,c):It(t.id);return u.meta=t,u}function Nt(t){return d(d({type:vt},t),{toJSON:function(){t.onDone,t.onError;var e,r=v(t,["onDone","onError"]);return d(d({},r),{type:vt,src:(e=t.src,"string"==typeof e?{type:e,toString:function(){return e}}:e)})}})}var Ct={},Dt=function(t){return"#"===t[0]},Lt=function(){function t(e,r,n){var i,o=this;void 0===n&&(n="context"in e?e.context:void 0),this.config=e,this._context=n,this.order=-1,this.__xstatenode=!0,this.__cache={events:void 0,relativeValue:new Map,initialStateValue:void 0,initialState:void 0,on:void 0,transitions:void 0,candidates:{},delayedTransitions:void 0},this.idMap={},this.tags=[],this.options=Object.assign({actions:{},guards:{},services:{},activities:{},delays:{}},r),this.parent=this.options._parent,this.key=this.config.key||this.options._key||this.config.id||"(machine)",this.machine=this.parent?this.parent.machine:this,this.path=this.parent?this.parent.path.concat(this.key):[],this.delimiter=this.config.delimiter||(this.parent?this.parent.delimiter:"."),this.id=this.config.id||g([this.machine.key],h(this.path)).join(this.delimiter),this.version=this.parent?this.parent.version:this.config.version,this.type=this.config.type||(this.config.parallel?"parallel":this.config.states&&w(this.config.states).length?"compound":this.config.history?"history":"atomic"),this.schema=this.parent?this.machine.schema:null!==(i=this.config.schema)&&void 0!==i?i:{},this.initial=this.config.initial,this.states=this.config.states?E(this.config.states,(function(e,r){var n,i=new t(e,{_parent:o,_key:r});return Object.assign(o.idMap,d(((n={})[i.id]=i,n),i.idMap)),i})):Ct;var a=0;!function t(e){var r,n;e.order=a++;try{for(var i=y(Q(e)),o=i.next();!o.done;o=i.next())t(o.value)}catch(t){r={error:t}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}}(this),this.history=!0===this.config.history?"shallow":this.config.history||!1,this._transient=!!this.config.always||!!this.config.on&&(Array.isArray(this.config.on)?this.config.on.some((function(t){return""===t.event})):""in this.config.on),this.strict=!!this.config.strict,this.onEntry=P(this.config.entry||this.config.onEntry).map((function(t){return wt(t)})),this.onExit=P(this.config.exit||this.config.onExit).map((function(t){return wt(t)})),this.meta=this.config.meta,this.doneData="final"===this.type?this.config.data:void 0,this.invoke=P(this.config.invoke).map((function(t,e){var r,n;if(H(t))return o.machine.options.services=d(((r={})[t.id]=t,r),o.machine.options.services),Nt({src:t.id,id:t.id});if(W(t.src))return Nt(d(d({},t),{id:t.id||t.src,src:t.src}));if(H(t.src)||V(t.src)){var i=o.id+":invocation["+e+"]";return o.machine.options.services=d(((n={})[i]=t.src,n),o.machine.options.services),Nt(d(d({id:i},t),{src:i}))}var a=t.src;return Nt(d(d({id:a.type},t),{src:a}))})),this.activities=P(this.config.activities).concat(this.invoke).map((function(t){return St(t)})),this.transition=this.transition.bind(this),this.tags=P(this.config.tags)}return t.prototype._init=function(){this.__cache.transitions||X(this).forEach((function(t){return t.on}))},t.prototype.withConfig=function(e,r){var n=this.options,i=n.actions,o=n.activities,a=n.guards,s=n.services,c=n.delays;return new t(this.config,{actions:d(d({},i),e.actions),activities:d(d({},o),e.activities),guards:d(d({},a),e.guards),services:d(d({},s),e.services),delays:d(d({},c),e.delays)},null!=r?r:this.context)},t.prototype.withContext=function(e){return new t(this.config,this.options,e)},Object.defineProperty(t.prototype,"context",{get:function(){return V(this._context)?this._context():this._context},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"definition",{get:function(){return{id:this.id,key:this.key,version:this.version,context:this.context,type:this.type,initial:this.initial,history:this.history,states:E(this.states,(function(t){return t.definition})),on:this.on,transitions:this.transitions,entry:this.onEntry,exit:this.onExit,activities:this.activities||[],meta:this.meta,order:this.order||-1,data:this.doneData,invoke:this.invoke}},enumerable:!1,configurable:!0}),t.prototype.toJSON=function(){return this.definition},Object.defineProperty(t.prototype,"on",{get:function(){if(this.__cache.on)return this.__cache.on;var t=this.transitions;return this.__cache.on=t.reduce((function(t,e){return t[e.eventType]=t[e.eventType]||[],t[e.eventType].push(e),t}),{})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"after",{get:function(){return this.__cache.delayedTransitions||(this.__cache.delayedTransitions=this.getDelayedTransitions(),this.__cache.delayedTransitions)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"transitions",{get:function(){return this.__cache.transitions||(this.__cache.transitions=this.formatTransitions(),this.__cache.transitions)},enumerable:!1,configurable:!0}),t.prototype.getCandidates=function(t){if(this.__cache.candidates[t])return this.__cache.candidates[t];var e=""===t,r=this.transitions.filter((function(r){var n=r.eventType===t;return e?n:n||"*"===r.eventType}));return this.__cache.candidates[t]=r,r},t.prototype.getDelayedTransitions=function(){var t=this,e=this.config.after;if(!e)return[];var r=function(e,r){var n,i,o,a=(n=V(e)?t.id+":delay["+r+"]":e,i=t.id,o=i?"#"+i:"",M.After+"("+n+")"+o);return t.onEntry.push(Ot(a,{delay:e})),t.onExit.push({type:ut,sendId:a}),a};return(G(e)?e.map((function(t,e){var n=r(t.delay,e);return d(d({},t),{event:n})})):j(w(e).map((function(t,n){var i=e[t],o=W(i)?{target:i}:i,a=isNaN(+t)?t:+t,s=r(a,n);return P(o).map((function(t){return d(d({},t),{event:s,delay:a})}))})))).map((function(e){var r=e.delay;return d(d({},t.formatTransition(e)),{delay:r})}))},t.prototype.getStateNodes=function(t){var e,r=this;if(!t)return[];var n=t instanceof Tt?t.value:O(t,this.delimiter);if(W(n)){var i=this.getStateNode(n).initial;return void 0!==i?this.getStateNodes(((e={})[n]=i,e)):[this,this.states[n]]}var o=w(n),a=o.map((function(t){return r.getStateNode(t)}));return a.push(this),a.concat(o.reduce((function(t,e){var i=r.getStateNode(e).getStateNodes(n[e]);return t.concat(i)}),[]))},t.prototype.handles=function(t){var e=S(t);return this.events.includes(e)},t.prototype.resolveState=function(t){var e=Array.from(Z([],this.getStateNodes(t.value)));return new Tt(d(d({},t),{value:this.resolve(t.value),configuration:e,done:it(e,this)}))},t.prototype.transitionLeafNode=function(t,e,r){var n=this.getStateNode(t).next(e,r);return n&&n.transitions.length?n:this.next(e,r)},t.prototype.transitionCompoundNode=function(t,e,r){var n=w(t),i=this.getStateNode(n[0])._transition(t[n[0]],e,r);return i&&i.transitions.length?i:this.next(e,r)},t.prototype.transitionParallelNode=function(t,e,r){var n,i,o={};try{for(var a=y(w(t)),s=a.next();!s.done;s=a.next()){var c=s.value,u=t[c];if(u){var l=this.getStateNode(c)._transition(u,e,r);l&&(o[c]=l)}}}catch(t){n={error:t}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}var f=w(o).map((function(t){return o[t]})),p=j(f.map((function(t){return t.transitions})));if(!f.some((function(t){return t.transitions.length>0})))return this.next(e,r);var d=j(f.map((function(t){return t.entrySet}))),v=j(w(o).map((function(t){return o[t].configuration})));return{transitions:p,entrySet:d,exitSet:j(f.map((function(t){return t.exitSet}))),configuration:v,source:e,actions:j(w(o).map((function(t){return o[t].actions})))}},t.prototype._transition=function(t,e,r){return W(t)?this.transitionLeafNode(t,e,r):1===w(t).length?this.transitionCompoundNode(t,e,r):this.transitionParallelNode(t,e,r)},t.prototype.next=function(t,e){var r,n,i,o=this,a=e.name,s=[],c=[];try{for(var u=y(this.getCandidates(a)),l=u.next();!l.done;l=u.next()){var f=l.value,p=f.cond,d=f.in,v=t.context,m=!d||(W(d)&&Dt(d)?t.matches(O(this.getStateNodeById(d).path,this.delimiter)):x(O(d,this.delimiter),R(this.path.slice(0,-2))(t.value))),b=!1;try{b=!p||K(this.machine,p,v,e,t)}catch(t){throw new Error("Unable to evaluate guard '"+(p.name||p.type)+"' in transition for event '"+a+"' in state node '"+this.id+"':\n"+t.message)}if(b&&m){void 0!==f.target&&(c=f.target),s.push.apply(s,g([],h(f.actions))),i=f;break}}}catch(t){r={error:t}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(r)throw r.error}}if(i){if(!c.length)return{transitions:[i],entrySet:[],exitSet:[],configuration:t.value?[this]:[],source:t,actions:s};var w=j(c.map((function(e){return o.getRelativeStateNodes(e,t.historyValue)}))),S=!!i.internal;return{transitions:[i],entrySet:S?[]:j(w.map((function(t){return o.nodesFromChild(t)}))),exitSet:S?[]:[this],configuration:w,source:t,actions:s}}},t.prototype.nodesFromChild=function(t){if(t.escapes(this))return[];for(var e=[],r=t;r&&r!==this;)e.push(r),r=r.parent;return e.push(this),e},t.prototype.escapes=function(t){if(this===t)return!1;for(var e=this.parent;e;){if(e===t)return!1;e=e.parent}return!0},t.prototype.getActions=function(t,e,r,n){var i,o,a,s,c=Z([],n?this.getStateNodes(n.value):[this]),u=t.configuration.length?Z(c,t.configuration):c;try{for(var l=y(u),f=l.next();!f.done;f=l.next())nt(c,v=f.value)||t.entrySet.push(v)}catch(t){i={error:t}}finally{try{f&&!f.done&&(o=l.return)&&o.call(l)}finally{if(i)throw i.error}}try{for(var p=y(c),d=p.next();!d.done;d=p.next()){var v;nt(u,v=d.value)&&!nt(t.exitSet,v.parent)||t.exitSet.push(v)}}catch(t){a={error:t}}finally{try{d&&!d.done&&(s=p.return)&&s.call(p)}finally{if(a)throw a.error}}t.source||(t.exitSet=[],t.entrySet.push(this));var m=j(t.entrySet.map((function(n){var i=[];if("final"!==n.type)return i;var o=n.parent;if(!o.parent)return i;i.push(Et(n.id,n.doneData),Et(o.id,n.doneData?N(n.doneData,e,r):void 0));var a=o.parent;return"parallel"===a.type&&Q(a).every((function(e){return it(t.configuration,e)}))&&i.push(Et(a.id)),i})));t.exitSet.sort((function(t,e){return e.order-t.order})),t.entrySet.sort((function(t,e){return t.order-e.order}));var b=new Set(t.entrySet),w=new Set(t.exitSet),x=h([j(Array.from(b).map((function(t){return g(g([],h(t.activities.map((function(t){return function(t){var e=St(t);return{type:M.Start,activity:e,exec:void 0}}(t)})))),h(t.onEntry))}))).concat(m.map(kt)),j(Array.from(w).map((function(t){return g(g([],h(t.onExit)),h(t.activities.map((function(t){return function(t){var e=V(t)?t:St(t);return{type:M.Stop,activity:e,exec:void 0}}(t)}))))})))],2),S=x[0],k=x[1];return xt(k.concat(t.actions).concat(S),this.machine.options.actions)},t.prototype.transition=function(t,e,r){void 0===t&&(t=this.initialState);var n,i,o=$(e);if(t instanceof Tt)n=void 0===r?t:this.resolveState(Tt.from(t,r));else{var a=W(t)?this.resolve(_(this.getResolvedPath(t))):this.resolve(t),s=null!=r?r:this.machine.context;n=this.resolveState(Tt.from(a,s))}if(this.strict&&!this.events.includes(o.name)&&(i=o.name,!/^(done|error)\./.test(i)))throw new Error("Machine '"+this.id+"' does not accept event '"+o.name+"'");var c=this._transition(n.value,n,o)||{transitions:[],configuration:[],entrySet:[],exitSet:[],source:n,actions:[]},u=Z([],this.getStateNodes(n.value)),l=c.configuration.length?Z(u,c.configuration):u;return c.configuration=g([],h(l)),this.resolveTransition(c,n,o)},t.prototype.resolveRaisedTransition=function(t,e,r){var n,i=t.actions;return(t=this.transition(t,e))._event=r,t.event=r.data,(n=t.actions).unshift.apply(n,g([],h(i))),t},t.prototype.resolveTransition=function(t,e,r,n){var i,o,a=this;void 0===r&&(r=mt),void 0===n&&(n=this.machine.context);var s=t.configuration,c=!e||t.transitions.length>0,u=c?rt(this.machine,s):void 0,l=e?e.historyValue?e.historyValue:t.source?this.machine.historyValue(e.value):void 0:void 0,f=e?e.context:n,p=this.getActions(t,f,r,e),v=e?d({},e.activities):{};try{for(var g=y(p),m=g.next();!m.done;m=g.next()){var b=m.value;b.type===ot?v[b.activity.id||b.activity.type]=b:b.type===at&&(v[b.activity.id||b.activity.type]=!1)}}catch(t){i={error:t}}finally{try{m&&!m.done&&(o=g.return)&&o.call(g)}finally{if(i)throw i.error}}var w,x,S=h(At(this,e,f,r,p,this.machine.config.preserveActionOrder),2),k=S[0],O=S[1],_=h(C(k,(function(t){return t.type===st||t.type===ct&&t.to===U.Internal})),2),E=_[0],A=_[1],R=k.filter((function(t){var e;return t.type===ot&&(null===(e=t.activity)||void 0===e?void 0:e.type)===vt})),T=R.reduce((function(t,e){return t[e.activity.id]=Pt(e.activity,a.machine,O,r),t}),e?d({},e.children):{}),I=u?t.configuration:e?e.configuration:[],P=it(I,this),N=new Tt({value:u||e.value,context:O,_event:r,_sessionid:e?e._sessionid:null,historyValue:u?l?(w=l,x=u,{current:x,states:D(w,x)}):void 0:e?e.historyValue:void 0,history:!u||t.source?e:void 0,actions:u?A:[],activities:u?v:e?e.activities:{},events:[],configuration:I,transitions:t.transitions,children:T,done:P,tags:null==e?void 0:e.tags,machine:this}),L=f!==O;N.changed=r.name===yt||L;var M=N.history;M&&delete M.history;var F=!P&&(this._transient||s.some((function(t){return t._transient})));if(!(c||F&&""!==r.name))return N;var B=N;if(!P)for(F&&(B=this.resolveRaisedTransition(B,{type:lt},r));E.length;){var G=E.shift();B=this.resolveRaisedTransition(B,G._event,r)}var V=B.changed||(M?!!B.actions.length||L||typeof M.value!=typeof B.value||!Rt(B.value,M.value):void 0);return B.changed=V,B.history=M,B.tags=new Set(j(B.configuration.map((function(t){return t.tags})))),B},t.prototype.getStateNode=function(t){if(Dt(t))return this.machine.getStateNodeById(t);if(!this.states)throw new Error("Unable to retrieve child state '"+t+"' from '"+this.id+"'; no child states exist.");var e=this.states[t];if(!e)throw new Error("Child state '"+t+"' does not exist on '"+this.id+"'");return e},t.prototype.getStateNodeById=function(t){var e=Dt(t)?t.slice("#".length):t;if(e===this.id)return this;var r=this.machine.idMap[e];if(!r)throw new Error("Child state node '#"+e+"' does not exist on machine '"+this.id+"'");return r},t.prototype.getStateNodeByPath=function(t){if("string"==typeof t&&Dt(t))try{return this.getStateNodeById(t.slice(1))}catch(t){}for(var e=k(t,this.delimiter).slice(),r=this;e.length;){var n=e.shift();if(!n.length)break;r=r.getStateNode(n)}return r},t.prototype.resolve=function(t){var e,r=this;if(!t)return this.initialStateValue||Ct;switch(this.type){case"parallel":return E(this.initialStateValue,(function(e,n){return e?r.getStateNode(n).resolve(t[n]||e):Ct}));case"compound":if(W(t)){var n=this.getStateNode(t);return"parallel"===n.type||"compound"===n.type?((e={})[t]=n.initialStateValue,e):t}return w(t).length?E(t,(function(t,e){return t?r.getStateNode(e).resolve(t):Ct})):this.initialStateValue||{};default:return t||Ct}},t.prototype.getResolvedPath=function(t){if(Dt(t)){var e=this.machine.idMap[t.slice("#".length)];if(!e)throw new Error("Unable to find state node '"+t+"'");return e.path}return k(t,this.delimiter)},Object.defineProperty(t.prototype,"initialStateValue",{get:function(){var t,e;if(this.__cache.initialStateValue)return this.__cache.initialStateValue;if("parallel"===this.type)e=A(this.states,(function(t){return t.initialStateValue||Ct}),(function(t){return!("history"===t.type)}));else if(void 0!==this.initial){if(!this.states[this.initial])throw new Error("Initial state '"+this.initial+"' not found on '"+this.key+"'");e=J(this.states[this.initial])?this.initial:((t={})[this.initial]=this.states[this.initial].initialStateValue,t)}else e={};return this.__cache.initialStateValue=e,this.__cache.initialStateValue},enumerable:!1,configurable:!0}),t.prototype.getInitialState=function(t,e){var r=this.getStateNodes(t);return this.resolveTransition({configuration:r,entrySet:r,exitSet:[],transitions:[],source:void 0,actions:[]},void 0,void 0,e)},Object.defineProperty(t.prototype,"initialState",{get:function(){this._init();var t=this.initialStateValue;if(!t)throw new Error("Cannot retrieve initial state from simple state '"+this.id+"'.");return this.getInitialState(t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"target",{get:function(){var t;if("history"===this.type){var e=this.config;t=W(e.target)&&Dt(e.target)?_(this.machine.getStateNodeById(e.target).path.slice(this.path.length-1)):e.target}return t},enumerable:!1,configurable:!0}),t.prototype.getRelativeStateNodes=function(t,e,r){return void 0===r&&(r=!0),r?"history"===t.type?t.resolveHistory(e):t.initialStateNodes:[t]},Object.defineProperty(t.prototype,"initialStateNodes",{get:function(){var t=this;return J(this)?[this]:"compound"!==this.type||this.initial?j(T(this.initialStateValue).map((function(e){return t.getFromRelativePath(e)}))):[this]},enumerable:!1,configurable:!0}),t.prototype.getFromRelativePath=function(t){if(!t.length)return[this];var e=h(t),r=e[0],n=e.slice(1);if(!this.states)throw new Error("Cannot retrieve subPath '"+r+"' from node with no states");var i=this.getStateNode(r);if("history"===i.type)return i.resolveHistory();if(!this.states[r])throw new Error("Child state '"+r+"' does not exist on '"+this.id+"'");return this.states[r].getFromRelativePath(n)},t.prototype.historyValue=function(t){if(w(this.states).length)return{current:t||this.initialStateValue,states:A(this.states,(function(e,r){if(!t)return e.historyValue();var n=W(t)?void 0:t[r];return e.historyValue(n||e.initialStateValue)}),(function(t){return!t.history}))}},t.prototype.resolveHistory=function(t){var e=this;if("history"!==this.type)return[this];var r=this.parent;if(!t){var n=this.target;return n?j(T(n).map((function(t){return r.getFromRelativePath(t)}))):r.initialStateNodes}var i,o=(i=r.path,"states",function(t){var e,r,n=t;try{for(var o=y(i),a=o.next();!a.done;a=o.next()){var s=a.value;n=n.states[s]}}catch(t){e={error:t}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(e)throw e.error}}return n})(t).current;return W(o)?[r.getStateNode(o)]:j(T(o).map((function(t){return"deep"===e.history?r.getFromRelativePath(t):[r.states[t[0]]]})))},Object.defineProperty(t.prototype,"stateIds",{get:function(){var t=this,e=j(w(this.states).map((function(e){return t.states[e].stateIds})));return[this.id].concat(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"events",{get:function(){var t,e,r,n;if(this.__cache.events)return this.__cache.events;var i=this.states,o=new Set(this.ownEvents);if(i)try{for(var a=y(w(i)),s=a.next();!s.done;s=a.next()){var c=i[s.value];if(c.states)try{for(var u=(r=void 0,y(c.events)),l=u.next();!l.done;l=u.next()){var f=l.value;o.add(""+f)}}catch(t){r={error:t}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(r)throw r.error}}}}catch(e){t={error:e}}finally{try{s&&!s.done&&(e=a.return)&&e.call(a)}finally{if(t)throw t.error}}return this.__cache.events=Array.from(o)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"ownEvents",{get:function(){var t=new Set(this.transitions.filter((function(t){return!(!t.target&&!t.actions.length&&t.internal)})).map((function(t){return t.eventType})));return Array.from(t)},enumerable:!1,configurable:!0}),t.prototype.resolveTarget=function(t){var e=this;if(void 0!==t)return t.map((function(t){if(!W(t))return t;var r=t[0]===e.delimiter;if(r&&!e.parent)return e.getStateNodeByPath(t.slice(1));var n=r?e.key+t:t;if(!e.parent)return e.getStateNodeByPath(n);try{return e.parent.getStateNodeByPath(n)}catch(t){throw new Error("Invalid transition definition for state node '"+e.id+"':\n"+t.message)}}))},t.prototype.formatTransition=function(t){var e=this,r=function(t){if(void 0!==t&&""!==t)return P(t)}(t.target),n="internal"in t?t.internal:!r||r.some((function(t){return W(t)&&t[0]===e.delimiter})),i=this.machine.options.guards,o=this.resolveTarget(r),a=d(d({},t),{actions:xt(P(t.actions)),cond:q(t.cond,i),target:o,source:this,internal:n,eventType:t.event,toJSON:function(){return d(d({},a),{target:a.target?a.target.map((function(t){return"#"+t.id})):void 0,source:"#"+e.id})}});return a},t.prototype.formatTransitions=function(){var t,e,r,n=this;if(this.config.on)if(Array.isArray(this.config.on))r=this.config.on;else{var i=this.config.on,o=i["*"],a=void 0===o?[]:o,s=v(i,["*"]);r=j(w(s).map((function(t){return Y(t,s[t])})).concat(Y("*",a)))}else r=[];var c=this.config.always?Y("",this.config.always):[],u=this.config.onDone?Y(String(Et(this.id)),this.config.onDone):[],l=j(this.invoke.map((function(t){var e,r,n=[];return t.onDone&&n.push.apply(n,g([],h(Y(String((e=t.id,{type:r=M.DoneInvoke+"."+e,data:undefined,toString:function(){return r}})),t.onDone)))),t.onError&&n.push.apply(n,g([],h(Y(String(function(t,e){var r=M.ErrorPlatform+"."+t;return{type:r,data:void 0,toString:function(){return r}}}(t.id)),t.onError)))),n}))),f=this.after,p=j(g(g(g(g([],h(u)),h(l)),h(r)),h(c)).map((function(t){return P(t).map((function(t){return n.formatTransition(t)}))})));try{for(var d=y(f),m=d.next();!m.done;m=d.next()){var b=m.value;p.push(b)}}catch(e){t={error:e}}finally{try{m&&!m.done&&(e=d.return)&&e.call(d)}finally{if(t)throw t.error}}return p},t}();function Mt(t,e){return new Lt(t,e)}function Ut(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ft(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){Ut(o,n,i,a,s,"next",t)}function s(t){Ut(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Bt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Gt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Bt(Object(r),!0).forEach((function(e){Vt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Bt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Vt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Wt(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function qt(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ht(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){qt(o,n,i,a,s,"next",t)}function s(t){qt(o,n,i,a,s,"throw",t)}a(void 0)}))}}function zt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function $t(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Yt(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){$t(o,n,i,a,s,"next",t)}function s(t){$t(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Kt(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Jt(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){Kt(o,n,i,a,s,"next",t)}function s(t){Kt(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Qt(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Xt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Zt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Xt(Object(r),!0).forEach((function(e){te(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Xt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function te(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function ee(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function re(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){ee(o,n,i,a,s,"next",t)}function s(t){ee(o,n,i,a,s,"throw",t)}a(void 0)}))}}function ne(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function ie(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){ne(o,n,i,a,s,"next",t)}function s(t){ne(o,n,i,a,s,"throw",t)}a(void 0)}))}}function oe(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function ae(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}const se={continue_deposit_activity:function(e){var r,n,i=e.config.appSecret;return Mt({id:"continue_deposit_activity",context:{activityNo:null,activityDetail:null,stages:[],currentStage:{},receiveNo:null,rewardType:""},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"loaded",actions:["setActivityDetail","setProperties","setReceiveNo"]},onError:{target:"idle"}}},loaded:{always:[{target:"receivable",cond:"isReceivable"},{target:"received",cond:"isReceived"}]},receivable:{on:{RECEIVE_REWARD:{target:"receiving"}}},receiving:{invoke:{src:"receiveReward",onDone:{target:"animating"},onError:{target:"loading"}}},animating:{after:{0:{target:"received"}}},received:{}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setProperties:_t((function(t,e){var r=e.data,n=r.dayOfThePeriod,i=r.progress,o=r.policy,a=n-1,s=i.map((function(t,e){return Gt(Gt({},t),{},{deposit:t.achieve?t.target:Math.floor(t.deposit),percentage:t.achieve?100:Math.floor(t.deposit/t.target*100),day:e+1})}));return{currentStage:s[a],stages:s,rewardType:o}})),setReceiveNo:_t((function(t,e){return{receiveNo:e.data.receiveNo}}))},guards:{isReceivable:function(t,e){var r=t.activityDetail,n=r.receiveNo,i=r.receiveStatus;return n&&2===i},isReceived:function(t,e){return 1===t.activityDetail.receiveStatus}},services:{fetchActivityDetail:(n=Ft(regeneratorRuntime.mark((function r(n,o){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:i}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),receiveReward:(r=Ft(regeneratorRuntime.mark((function r(n,o){var a,s,c,u;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,s=n.receiveNo,r.next=3,e.send(t.getReward({activityNo:a,receiveNo:s,appSecret:i}));case 3:return c=r.sent,u=c.data,r.abrupt("return",u);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},deposit_activity:function(e){var r,n,i=e.config.appSecret;return Mt({id:"deposit_activity",context:{activityNo:null,activityDetail:null,duration:null},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"loaded",actions:"setActivityDetail"},onError:{target:"idle"}}},loaded:{entry:"setDuration",always:[{target:"expired",cond:"isNotAvailable"},{target:"expired",cond:"isExpired"}],after:{1e3:{target:"loaded"}}},expired:{}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setDuration:_t((function(t,e){var r;return{duration:(null==t||null===(r=t.activityDetail)||void 0===r?void 0:r.deadline)-(new Date).getTime()/1e3}}))},guards:{isExpired:function(t,e){return t.duration<=0},isNotAvailable:function(t,e){var r;return 1!==(null==t||null===(r=t.activityDetail)||void 0===r?void 0:r.achieveStatus)}},services:{fetchActivityDetail:(r=regeneratorRuntime.mark((function r(n,o){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:i}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)})),n=function(){var t=this,e=arguments;return new Promise((function(n,i){var o=r.apply(t,e);function a(t){Wt(o,n,i,a,s,"next",t)}function s(t){Wt(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return n.apply(this,arguments)})}})},diamond_shop_activity:function(e){var r,n,i,o=e.config.appSecret;return Mt({id:"diamond_shop_activity",context:{activityNo:null,activityDetail:null,awards:[],awardExchangeList:[],exchangeAward:0,exchangePoint:0},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"loaded",actions:["setActivityDetail","setAwardList"]},onError:{target:"idle"}}},loaded:{on:{EXCHANGE:{target:"exchanging"},ADD_TO_CART:{actions:["addProduct","count"]},CLEAR_CART:{actions:["clearCart","count"]},COLLECT:{target:"collecting",cond:"hasUnclaimedReward"}}},exchanging:{invoke:{src:"exchange",onDone:{target:"collecting",actions:["clearCart","count"]},onError:{target:"loaded"}}},collecting:{invoke:{src:"collect",onDone:{target:"collected"},onError:{target:"collected"}}},collected:{after:{0:{target:"loaded"}}}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setAwardList:_t((function(t,e){var r;return{awardList:(null===(r=e.data)||void 0===r?void 0:r.awards)||[]}})),addProduct:_t((function(t,e){return{awardExchangeList:[].concat((r=t.awardExchangeList,function(t){if(Array.isArray(t))return zt(t)}(r)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(r)||function(t,e){if(t){if("string"==typeof t)return zt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?zt(t,e):void 0}}(r)||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.data])};var r})),clearCart:_t((function(t,e){return{awardExchangeList:[]}})),count:_t((function(t,e){var r=t.awardExchangeList.reduce((function(t,e){var r=t.exchangeAward,n=t.exchangePoint;return{exchangeAward:r+e.award,exchangePoint:n+e.points}}),{exchangeAward:0,exchangePoint:0});return{exchangeAward:r.exchangeAward,exchangePoint:r.exchangePoint}}))},guards:{hasUnclaimedReward:function(t,e){var r,n;return(null===(r=t.activityDetail)||void 0===r||null===(n=r.unclaimedReward)||void 0===n?void 0:n.length)>0}},services:{fetchActivityDetail:(i=Ht(regeneratorRuntime.mark((function r(n,i){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:o}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return i.apply(this,arguments)}),exchange:(n=Ht(regeneratorRuntime.mark((function r(n,i){var o,a;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return o=n.activityNo,a=n.awardExchangeList,r.next=3,Promise.all(a.map((function(r){return e.send(t.exchange({exchangeType:1,activityNo:o,exchangeAward:r.award}))})));case 3:return r.abrupt("return",r.sent);case 4:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),collect:(r=Ht(regeneratorRuntime.mark((function r(n,i){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,e.send(t.collect({appSecret:o}));case 2:return r.abrupt("return",r.sent);case 3:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},fafafa_activity:function(e){var r,n,i,o=e.config.appSecret;return Mt({id:"fafafa_activity",context:{activityNo:null,activityDetail:null,receiveNo:null},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"loaded",actions:"setActivityDetail"},onError:{target:"idle"}}},loaded:{always:[{target:"awardable",cond:"isAwardable"}],on:{REFRESH_ACTIVITY:{target:"loading"}}},awardable:{on:{AWARD_PRIZE:{target:"awarding"}}},awarding:{invoke:{src:"awardPrize",onDone:{target:"receiving",actions:"setReceiveNo"},onError:{target:"loaded"}}},receiving:{invoke:{src:"receiveReward",onDone:{target:"animating"},onError:{target:"loading"}}},animating:{after:{0:{target:"loading"}}}},on:{CLEAR_ACTIVITY_NO:{target:".idle"}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setReceiveNo:_t((function(t,e){return{receiveNo:e.data.receiveNo}}))},guards:{isAwardable:function(t,e){var r;return 2===(null===(r=t.activityDetail)||void 0===r?void 0:r.receiveStatus)}},services:{fetchActivityDetail:(i=Yt(regeneratorRuntime.mark((function r(n,i){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:o}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return i.apply(this,arguments)}),awardPrize:(n=Yt(regeneratorRuntime.mark((function r(n,i){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.sentAward({activityNo:a,appSecret:o}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),receiveReward:(r=Yt(regeneratorRuntime.mark((function r(n,i){var a,s,c,u;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,s=n.receiveNo,r.next=3,e.send(t.getReward({activityNo:a,receiveNo:s,appSecret:o}));case 3:return c=r.sent,u=c.data,r.abrupt("return",u);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},invite_friends_activity:function(e){var r,n,i,o=e.config.appSecret;return Mt({id:"invite_friends_activity",context:{activityNo:null,bindingCode:null,uidSite:null,receiveNo:null,affiliateCode:null,downlineCount:0},initial:"idle",states:{idle:{on:{FETCH_AFFILIATE_CODE:{target:"fetching"},BIND_AFFILIATE_CODE:{target:"binding",actions:["setActivityNo","setBindingCode","setUidSite"]}}},fetching:{invoke:{src:"fetchAffiliate",onDone:{target:"idle",actions:"setAffiliateCode"},onError:{target:"idle"}}},binding:{invoke:{src:"postAffiliate",onDone:{target:"awarding"},onError:{target:"idle"}}},awarding:{invoke:{src:"awardPrize",onDone:{target:"bound"},onError:{target:"idle"}}},bound:{after:{0:{target:"idle"}}}}},{actions:{setAffiliateCode:_t((function(t,e){var r=e.data;return{affiliateCode:r.affiliateCode,downlineCount:r.downlineCount}})),setBindingCode:_t((function(t,e){return{bindingCode:e.data.bindingCode}})),setActivityNo:_t((function(t,e){return{activityNo:e.data.activityNo}})),setUidSite:_t((function(t,e){return{uidSite:e.data.uidSite}}))},services:{postAffiliate:(i=Jt(regeneratorRuntime.mark((function t(r,n){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.send(f.postAffiliate({affiliateCode:r.bindingCode}));case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)}))),function(t,e){return i.apply(this,arguments)}),fetchAffiliate:(n=Jt(regeneratorRuntime.mark((function t(r,n){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.send(f.getAffiliate());case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)}))),function(t,e){return n.apply(this,arguments)}),awardPrize:(r=Jt(regeneratorRuntime.mark((function r(n,i){var a,s,c,u,l;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,s=n.uidSite,c=n.bindingCode,r.next=3,e.send(t.sentAward({activityNo:a,uidSite:s,affiliateCode:c,appSecret:o}));case 3:return u=r.sent,l=u.data,r.abrupt("return",l);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},ranking_activity:function(e){var r,n,i=e.config.appSecret;return Mt({id:"ranking_activity",context:{activityNo:null,activityDetail:null,activityMap:{}},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"checking",actions:"setActivityNo"}}},checking:{always:[{target:"idle",actions:"setActivityDetail",cond:"isExist"},{target:"loading"}]},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"idle",actions:["setActivityMap","setActivityDetail"]},onError:{target:"idle"}}}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityMap:_t((function(t,e){var r=t.activityMap,n=t.activityNo;return{activityMap:Zt(Zt({},r),{},te({},n,e.data))}})),setActivityDetail:_t((function(t,e){return{activityDetail:t.activityMap[t.activityNo]}}))},guards:{isExist:function(t,e){return t.activityMap[t.activityNo]}},services:{fetchActivityDetail:(r=regeneratorRuntime.mark((function r(n,o){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:i}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)})),n=function(){var t=this,e=arguments;return new Promise((function(n,i){var o=r.apply(t,e);function a(t){Qt(o,n,i,a,s,"next",t)}function s(t){Qt(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return n.apply(this,arguments)})}})},return_bonus_activity:function(e){var r,n,i,o=e.config.appSecret;return Mt({id:"return_bonus_activity",context:{activityNo:null,activityDetail:null,receiveNo:null,rewardList:[]},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{initial:"detail",states:{detail:{invoke:{src:"fetchActivityDetail",onDone:{target:"rewardList",actions:"setActivityDetail"},onError:{target:"#return_bonus_activity.idle"}}},rewardList:{invoke:{src:"fetchRewardList",onDone:{target:"#return_bonus_activity.loaded",actions:"setRewardList"},onError:{target:"#return_bonus_activity.idle"}}}}},loaded:{always:[{target:"receivable",cond:"isReceivable"},{target:"notReceivableYet",cond:"isNotReceivableYet"},{target:"empty"}]},receivable:{on:{RECEIVE_REWARD:{target:"receiving"}}},notReceivableYet:{after:{2e4:{target:"loading"}}},empty:{after:{2e4:{target:"loading"}}},receiving:{invoke:{src:"receiveReward",onDone:{target:"animating"},onError:{target:"loading"}}},animating:{after:{0:{target:"loading"}}}},on:{CLEAR_ACTIVITY_NO:{target:".idle"}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setRewardList:_t((function(t,e){return{rewardList:e.data.filter((function(t){return 4===t.activityType&&0===t.receiveStatus}))}}))},guards:{isReceivable:function(t,e){var r;return(null===(r=t.rewardList)||void 0===r?void 0:r.length)>0},isNotReceivableYet:function(t,e){var r;return null===(r=t.activityDetail)||void 0===r?void 0:r.rebateAmount}},services:{fetchActivityDetail:(i=re(regeneratorRuntime.mark((function r(n,i){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:o}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return i.apply(this,arguments)}),receiveReward:(n=re(regeneratorRuntime.mark((function r(n,i){var a,s,c,u,l;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.rewardList[0],s=a.activityNo,c=a.receiveNo,r.next=3,e.send(t.getReward({activityNo:s,receiveNo:c,appSecret:o}));case 3:return u=r.sent,l=u.data,r.abrupt("return",l);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),fetchRewardList:(r=re(regeneratorRuntime.mark((function r(n,i){var a,s;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,e.send(t.getRewardList({appSecret:o,count:30}));case 2:return a=r.sent,s=a.data,r.abrupt("return",s);case 5:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},specify_bets_activity:function(e){var r,n,i=e.config.appSecret;return Mt({id:"specify_bets_activity",context:{activityNo:null,activityDetail:null,rewardType:null},initial:"idle",states:{idle:{on:{SET_ACTIVITY_NO:{target:"loading",actions:"setActivityNo"}}},loading:{invoke:{src:"fetchActivityDetail",onDone:{target:"loaded",actions:"setActivityDetail"},onError:{target:"idle"}}},loaded:{always:[{target:"ongoing",cond:"isOngoing"},{target:"received",cond:"isReceived"},{target:"receivable",cond:"isReceivable"}]},ongoing:{},received:{},receivable:{on:{RECEIVE_REWARD:{target:"receiving"}}},receiving:{invoke:{src:"receiveReward",onDone:{target:"animating",actions:"setRewardType"},onError:{target:"loaded"}}},animating:{after:{0:{target:"loading"}}}}},{actions:{setActivityNo:_t((function(t,e){return{activityNo:e.data}})),setActivityDetail:_t((function(t,e){return{activityDetail:e.data}})),setRewardType:_t((function(t,e){return{rewardType:e.data.type}}))},guards:{isReceivable:function(t,e){var r;return 2===(null===(r=t.activityDetail)||void 0===r?void 0:r.receiveStatus)},isReceived:function(t,e){var r;return 1===(null===(r=t.activityDetail)||void 0===r?void 0:r.receiveStatus)},isOngoing:function(t,e){var r;return 0===(null===(r=t.activityDetail)||void 0===r?void 0:r.receiveStatus)}},services:{fetchActivityDetail:(n=ie(regeneratorRuntime.mark((function r(n,o){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityNo,r.next=3,e.send(t.getActivityDetail({activityNo:a,appSecret:i}));case 3:return s=r.sent,c=s.data,r.abrupt("return",c);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),receiveReward:(r=ie(regeneratorRuntime.mark((function r(n,o){var a,s,c,u,l;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=n.activityDetail,s=a.activityNo,c=a.receiveNo,r.next=3,e.send(t.getReward({activityNo:s,receiveNo:c,appSecret:i}));case 3:return u=r.sent,l=u.data,r.abrupt("return",l);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},activity:function(e){var r,n,i=e.config.appSecret;return Mt({id:"activity",initial:"fetchingTimerDataList",context:{tick:2e3,activityList:[],activityMap:{},rewardList:[],tournamentList:[],refs:{}},states:{fetchingTimerDataList:{invoke:{src:"fetchTimerDataList",onDone:{target:"pending",actions:["setTimerDataList","setTournamentList"]},onError:{target:"pending"}}},pending:{after:{TIMEOUT:{target:"fetchingTimerDataList"}}}}},{actions:{setTournamentList:_t((function(t,e){return{tournamentList:e.data.activityList.filter((function(t){return 1===t.tournament}))}})),setTimerDataList:_t((function(t,e){var r=e.data;return{activityList:r.activityList,rewardList:r.rewardList}}))},delays:{TIMEOUT:function(t,e){return 10*t.tick}},services:{fetchTimerDataList:(r=regeneratorRuntime.mark((function r(n,o){var a,s,c,u;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,Promise.all([e.send(t.getActivityList({appSecret:i,include:"cl"})),e.send(t.getRewardList({count:30,appSecret:i}))]);case 2:return a=r.sent,o=2,s=function(t){if(Array.isArray(t))return t}(n=a)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o=[],a=!0,s=!1;try{for(r=r.call(t);!(a=(n=r.next()).done)&&(o.push(n.value),!e||o.length!==e);a=!0);}catch(t){s=!0,i=t}finally{try{a||null==r.return||r.return()}finally{if(s)throw i}}return o}}(n,o)||function(t,e){if(t){if("string"==typeof t)return oe(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?oe(t,e):void 0}}(n,o)||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.")}(),c=s[0].data,u=s[1].data,r.abrupt("return",{activityList:c,rewardList:u});case 7:case"end":return r.stop()}var n,o}),r)})),n=function(){var t=this,e=arguments;return new Promise((function(n,i){var o=r.apply(t,e);function a(t){ae(o,n,i,a,s,"next",t)}function s(t){ae(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return n.apply(this,arguments)})}})}};var ce=r(4078),ue=r.n(ce),le=r(6489);function fe(t,e){void 0===e&&(e={});var r=function(t){return t&&"j"===t[0]&&":"===t[1]?t.substr(2):t}(t);if(function(t,e){return void 0===e&&(e=!t||"{"!==t[0]&&"["!==t[0]&&'"'!==t[0]),!e}(r,e.doNotParse))try{return JSON.parse(r)}catch(t){}return t}var pe=function(){return pe=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},pe.apply(this,arguments)},de=function(){function t(t,e){var r=this;this.changeListeners=[],this.HAS_DOCUMENT_COOKIE=!1,this.cookies=function(t,e){return"string"==typeof t?le.Q(t,e):"object"==typeof t&&null!==t?t:{}}(t,e),new Promise((function(){r.HAS_DOCUMENT_COOKIE="object"==typeof document&&"string"==typeof document.cookie})).catch((function(){}))}return t.prototype._updateBrowserValues=function(t){this.HAS_DOCUMENT_COOKIE&&(this.cookies=le.Q(document.cookie,t))},t.prototype._emitChange=function(t){for(var e=0;e<this.changeListeners.length;++e)this.changeListeners[e](t)},t.prototype.get=function(t,e,r){return void 0===e&&(e={}),this._updateBrowserValues(r),fe(this.cookies[t],e)},t.prototype.getAll=function(t,e){void 0===t&&(t={}),this._updateBrowserValues(e);var r={};for(var n in this.cookies)r[n]=fe(this.cookies[n],t);return r},t.prototype.set=function(t,e,r){var n;"object"==typeof e&&(e=JSON.stringify(e)),this.cookies=pe(pe({},this.cookies),((n={})[t]=e,n)),this.HAS_DOCUMENT_COOKIE&&(document.cookie=le.q(t,e,r)),this._emitChange({name:t,value:e,options:r})},t.prototype.remove=function(t,e){var r=e=pe(pe({},e),{expires:new Date(1970,1,1,0,0,1),maxAge:0});this.cookies=pe({},this.cookies),delete this.cookies[t],this.HAS_DOCUMENT_COOKIE&&(document.cookie=le.q(t,"",r)),this._emitChange({name:t,value:void 0,options:e})},t.prototype.addChangeListener=function(t){this.changeListeners.push(t)},t.prototype.removeChangeListener=function(t){var e=this.changeListeners.indexOf(t);e>=0&&this.changeListeners.splice(e,1)},t}();const ve=de;var ye=r(129),he=r.n(ye);function ge(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function me(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){ge(o,n,i,a,s,"next",t)}function s(t){ge(o,n,i,a,s,"throw",t)}a(void 0)}))}}function be(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function we(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){be(o,n,i,a,s,"next",t)}function s(t){be(o,n,i,a,s,"throw",t)}a(void 0)}))}}function xe(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}var Se=new ve,ke=r(2238),Oe=r.n(ke);function _e(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ee(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){_e(o,n,i,a,s,"next",t)}function s(t){_e(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Ae(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Re(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Te(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Re(Object(r),!0).forEach((function(e){je(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Re(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function je(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Ie=r(4841),Pe=r.n(Ie);function Ne(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ce(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){Ne(o,n,i,a,s,"next",t)}function s(t){Ne(o,n,i,a,s,"throw",t)}a(void 0)}))}}function De(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Le(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){De(o,n,i,a,s,"next",t)}function s(t){De(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Me(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Ue(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Me(Object(r),!0).forEach((function(e){Fe(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Me(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Fe(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Be(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ge(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){Be(o,n,i,a,s,"next",t)}function s(t){Be(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Ve(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function We(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function qe(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){We(o,n,i,a,s,"next",t)}function s(t){We(o,n,i,a,s,"throw",t)}a(void 0)}))}}var He=["data"];function ze(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function $e(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function Ye(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){$e(o,n,i,a,s,"next",t)}function s(t){$e(o,n,i,a,s,"throw",t)}a(void 0)}))}}function Ke(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Je(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ke(Object(r),!0).forEach((function(e){Qe(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ke(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Qe(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Xe={initial:"idle",states:{idle:{initial:"hidden",states:{hidden:{},shown:{on:{HIDE_MESSAGE:{target:"hidden",actions:"hideMessage"}}}},on:{SHOW_MESSAGE:[{target:".shown",actions:"showMessage",cond:"isRead"},{target:"updating",actions:["showMessage","setMessageIsRead"]}]}},updating:{invoke:{src:"updateMessageIsRead",onDone:{target:"idle.shown"},onError:{target:"idle.shown"}}}}};function Ze(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function tr(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function er(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){tr(o,n,i,a,s,"next",t)}function s(t){tr(o,n,i,a,s,"throw",t)}a(void 0)}))}}function rr(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function nr(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){rr(o,n,i,a,s,"next",t)}function s(t){rr(o,n,i,a,s,"throw",t)}a(void 0)}))}}function ir(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function or(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function ar(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function sr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var cr=r(7436),ur=r.n(cr);function lr(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function fr(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){lr(o,n,i,a,s,"next",t)}function s(t){lr(o,n,i,a,s,"throw",t)}a(void 0)}))}}function pr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function dr(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?pr(Object(r),!0).forEach((function(e){vr(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):pr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function vr(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}const yr=dr(dr({},se),{},{auth:function(t){var r,n,i,o,a,s=t.config,c=s.fullURL,u=s.clientId,l="cuora_".concat(u),p=new ve;return Mt({id:"auth",initial:"idle",context:{token:null,tick:2e3,isPlaying:!1,userInfo:{},redirectURL:null},states:{idle:{entry:"fetchToken",always:[{target:"login",cond:"hasToken"}],on:{LOGIN_PHONE:{target:"authentication.phone"},LOGIN_LOCAL:{target:"authentication.local"},LOGIN_3PARTY:{actions:"redirectTo3Party"},LOGIN_TOKEN:{actions:"setToken"}}},authentication:{states:{phone:{invoke:{src:"authenticateByPhone",onDone:{target:"#auth.login",actions:"setToken"},onError:{target:"#auth.idle",actions:"removeToken"}}},local:{invoke:{src:"authenticateByUsername",onDone:{target:"#auth.login",actions:"setToken"},onError:{target:"#auth.idle",actions:"removeToken"}}}}},login:{type:"parallel",states:{schedule:{initial:"running",states:{running:{invoke:{src:"fetchUserInfo",onDone:{target:"pending",actions:["setUserInfo","extendToken"]},onError:{target:"#auth.logout"}}},pending:{after:{TIMEOUT:{target:"running"}},on:{FETCH_USER_INFO:{target:"running"}}}}},user:{initial:"idle",states:{idle:{on:{MODIFY_USER_INFO:{target:"modifyingUserInfo"}}},modifyingUserInfo:{invoke:{src:"modifyUserInfo",onDone:{target:"idle",actions:Ot({type:"FETCH_USER_INFO"})},onError:{target:"idle"}}}}}},on:{LOGOUT:{target:"#auth.logout"}}},logout:{invoke:{src:"logout",onDone:{target:"idle",actions:"removeToken"},onError:{target:"idle",actions:"removeToken"}}}}},{delays:{TIMEOUT:function(t,e){return t.tick*(t.isPlaying?5:1)}},guards:{hasToken:function(t,e){return t.token},isFirstLogin:function(t,e){var r=t.userInfo||{},n=r.bank_account,i=r.bank_setting_status;return!!n||1===i}},actions:{fetchToken:_t((function(t,e){return{token:p.get(l)}})),setToken:_t((function(t,e){return p.set(l,e.data,{path:"/",maxAge:300}),{token:e.data}})),removeToken:_t((function(t,e){return p.remove(l,{path:"/",maxAge:300}),{token:null}})),extendToken:_t((function(t,e){var r=p.get(l);return p.set(l,r,{path:"/",maxAge:300}),{token:r}})),redirectTo3Party:function(t,e){var r=ue()(c,"login?"+he().stringify({provider:e.data,redirectURI:"".concat(window.location.protocol,"//").concat(window.location.host),channel:"official",subchannel:"pwa"}));window.location.href=r},setUserInfo:_t((function(t,e){return{userInfo:e.data}}))},services:{authenticateByUsername:(a=me(regeneratorRuntime.mark((function r(n,i){var o,a,s,c,u;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return o=i.data,a=o.username,s=o.password,p.set("cuora_tempuser",a,{path:"/",maxAge:86400}),r.next=4,t.send(e.login({provider:"local",username:a,password:s}));case 4:return c=r.sent,u=c.token,r.abrupt("return",u);case 7:case"end":return r.stop()}}),r)}))),function(t,e){return a.apply(this,arguments)}),authenticateByPhone:(o=me(regeneratorRuntime.mark((function r(n,i){var o,a,s,c,u,l;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return o=i.data,a=o.countryCode,s=o.phone,c=o.password,r.next=3,t.send(e.login({provider:"phone",countryCode:a,phone:s,password:c}));case 3:return u=r.sent,l=u.token,r.abrupt("return",l);case 6:case"end":return r.stop()}}),r)}))),function(t,e){return o.apply(this,arguments)}),logout:(i=me(regeneratorRuntime.mark((function r(n,i){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,t.send(e.logout());case 2:return r.abrupt("return",r.sent);case 3:case"end":return r.stop()}}),r)}))),function(t,e){return i.apply(this,arguments)}),fetchUserInfo:(n=me(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(f.getUserInfo());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),modifyUserInfo:(r=me(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(f.modifyUserInfo(n.data));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)})}})},auth_otp:function(t){return Mt({id:"otp",initial:"idle",context:{userInfo:null,error:null,countryCode:null,phone:null,number:null,requestId:null,ttl:0},states:{idle:{always:[{target:"verified",cond:"isVerified"},{target:"notVerified",cond:"isNotVerified"}],on:{SET_USER_INFO:{actions:"setUserInfo"}}},notVerified:{initial:"checkingStatus",states:{checkingStatus:{invoke:{src:"verify",onDone:{target:"otp",actions:"setVerificationData"},onError:{target:"errorChecking",actions:"setError"}}},errorChecking:{always:[{target:"phone",cond:"hasNoPhone"},{target:"#otp.fail"}]},phone:{on:{SEND_PHONE:{target:"sendingPhone",actions:"setPhone"}}},sendingPhone:{invoke:{src:"sendPhone",onDone:{target:"checkingStatus"},onError:{target:"phone"}}},otp:{type:"parallel",states:{countdown:{after:{1e3:{target:"countdown",actions:"decreaseTtl",cond:function(t){return t.ttl>0}}}},verification:{initial:"idle",states:{idle:{on:{SEND_OTP:{target:"acknowledging"},RESET_OTP:{target:"reset"},RESEND_PHONE:{target:"#otp.notVerified.phone"}}},acknowledging:{invoke:{src:"acknowledge",onDone:{target:"#otp.verified"},onError:{target:"idle"}}},reset:{invoke:{src:"resetOtp",onDone:{target:"idle",actions:"setVerificationData"},onError:{target:"idle"}}}}}}}}},verified:{},fail:{}}},{actions:{setUserInfo:_t((function(t,e){return{userInfo:e.data}})),setVerificationData:_t((function(t,e){var r=e.data;return{number:r.number,requestId:r.requestId,ttl:r.ttl}})),decreaseTtl:_t((function(t,e){var r=t.ttl;return{ttl:Math.max(r-1e3,0)}})),setError:_t((function(t,e){return{error:e.data}})),setPhone:_t((function(t,e){var r=e.data;return{countryCode:r.countryCode,phone:r.phone}}))},guards:{isVerified:function(t,e){var r;return 1===(null===(r=t.userInfo)||void 0===r?void 0:r.verification_status)},isNotVerified:function(t,e){return t.userInfo&&1!==t.userInfo.verification_status},hasNoPhone:function(t,e){return"ERR_F106"===t.error.code}},services:{verify:(i=we(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(f.verify());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return i.apply(this,arguments)}),sendPhone:(n=we(regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.countryCode,o=r.phone,e.next=3,t.send(f.modifyUserInfo({countryCode:i,phone:o}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),resetOtp:(r=we(regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.requestId,o=r.number,e.next=3,t.send(f.resetOtp({requestId:i,number:o}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),acknowledge:(e=we(regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.requestId,o=n.data,e.next=4,t.send(f.acknowledge({requestId:i,code:o}));case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n,i},check:function(t){return Mt({id:"check",initial:"idle",context:{userInfo:null,bonus:null,gender:null},states:{idle:{},checking:{always:[{target:"inline",cond:"isInline"},{target:"inquiry",cond:"isInquiryIncomplete"},{target:"completed"}]},inline:{},inquiry:{initial:"inquiring",states:{inquiring:{on:{SET_BONUS:{actions:"setBonus"},SET_GENDER:{actions:"setGender"},SEND_INQUIRY_RESULT:{target:"submitting",cond:"isInquiryFilled"}}},submitting:{invoke:{src:"sendInquiryResult",onDone:{target:"#check.completed"},onError:{target:"#check.completed"}},exit:"setInfo"}}},completed:{}},on:{SET_USER_INFO:{target:"checking",actions:"setUserInfo"}}},{guards:{isInline:function(t,e){var r;return(null===(r=t.userInfo)||void 0===r?void 0:r.rank)>=0},isInquiryIncomplete:function(t,e){var r=t.userInfo||{},n=r.bank_account,i=r.bank_setting_status;return!(n||1===i||Se.get("welcome"))},isInquiryFilled:function(t,e){var r=t.bonus,n=t.gender;return null!==r&&null!==n}},actions:{setUserInfo:_t((function(t,e){return{userInfo:e.data}})),setInfo:function(t,e){Se.set("welcome","done",{path:"/",maxAge:31536e3})},setBonus:_t((function(t,e){return{bonus:e.data}})),setGender:_t((function(t,e){return{gender:e.data}}))},services:{sendInquiryResult:(e=regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.bonus,o=r.gender,e.next=3,Promise.all([t.send(l.setBonusSetting({bonus:i})),t.send(f.modifyUserInfo({gender:o}))]);case 3:case"end":return e.stop()}}),e)})),r=function(){var t=this,r=arguments;return new Promise((function(n,i){var o=e.apply(t,r);function a(t){xe(o,n,i,a,s,"next",t)}function s(t){xe(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return r.apply(this,arguments)})}});var e,r},common:function(t){var e,r,n=t.config.appSecret;return Mt({id:"common",type:"parallel",context:{tick:2e3,siteConfig:{cs:{lineat:null},loginMethods:{},forceValidation:"0",urls:{widget:null},competitionLab:{achievements:!1},paymentMethods:{}},ua:"",isMobile:!1,announcementList:null,broadcastList:null,mailBoxInfo:null,promotions:[],currentBroadcast:null,sentBroadcastList:[]},states:{config:{initial:"fetching",states:{idle:{on:{FETCH_SITE_CONFIG:{target:"fetching"}}},fetching:{entry:"setUA",invoke:{src:"fetchSiteConfig",onDone:{target:"idle",actions:"setSiteConfig"},onError:{target:"idle"}}}}},feed:{initial:"updating",states:{updating:{invoke:{src:"fetchFeeds",onDone:{target:"waiting",actions:"setFeeds"},onError:{target:"waiting"}}},waiting:{after:{TIMEOUT:{target:"updating"}}}}},broadcast:{initial:"idle",states:{idle:{on:{START_BROADCAST:{target:"picking"}}},picking:{after:{5e3:{target:"display",actions:"setBroadcast"}}},display:{after:{5e3:{target:"picking"}}}}}}},{delays:{TIMEOUT:function(t,e){return 10*t.tick}},actions:{setSiteConfig:_t((function(t,e){var r,n=(null===(r=e.data)||void 0===r?void 0:r.loginMethods)||{};return Object.keys(n).forEach((function(t){n[t]||delete n[t]})),{siteConfig:Te(Te({},e.data),{},{loginMethods:n})}})),setUA:_t((function(t,e){var r,n=(new(Oe())).getResult();return{ua:n,isMobile:null==n||null===(r=n.device)||void 0===r?void 0:r.type}})),setFeeds:_t((function(t,e){var r,n,i=e.data,o=i.announcementList;return{announcementList:o,broadcastList:i.broadcastList,mailBoxInfo:i.mailBoxInfo,promotions:(null==o||null===(r=o.announcements)||void 0===r||null===(n=r.filter)||void 0===n?void 0:n.call(r,(function(t){return 3===t.category})))||[]}})),setBroadcast:_t((function(t,e){var r,n,i=t.broadcastList,o=t.sentBroadcastList,a=t.currentBroadcast,s=o;return a&&(s=[].concat(function(t){if(Array.isArray(t))return Ae(t)}(n=o)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(n)||function(t,e){if(t){if("string"==typeof t)return Ae(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ae(t,e):void 0}}(n)||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.")}(),[a])),{currentBroadcast:null==i||null===(r=i.broadcasts)||void 0===r?void 0:r.find((function(t){return"1"===t.type&&!s.some((function(e){return e.broadcast_id===t.broadcast_id}))})),sentBroadcastList:s}}))},services:{fetchSiteConfig:(r=Ee(regeneratorRuntime.mark((function e(r,o){var a,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(i.getConfig({appSecret:n}));case 2:return a=e.sent,s=a.config,e.abrupt("return",JSON.parse(window.atob(s)));case 5:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),fetchFeeds:(e=Ee(regeneratorRuntime.mark((function e(r,o){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(i.feeds({appSecret:n}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}})},deposit:function(t){return Mt({id:"deposit",initial:"loading",context:{cryptos:[],networks:[],currentCrypto:null,currentNetwork:null,currentAmount:null,calculatedResult:null,submittedResult:null,bonus:null},states:{loading:{initial:"bonusStatus",states:{bonusStatus:{invoke:{src:"getPaymentInfo",onDone:{target:"fetchingPayments",actions:"setBonus"},onError:{target:"#deposit.loaded"}}},fetchingPayments:{invoke:{src:"fetchPayments",onDone:{target:"#deposit.loaded",actions:"setCryptos"},onError:{target:"#deposit.loaded"}}}}},loaded:{on:{SUBMIT:{target:"submitting",cond:"isSubmittable"}}},checking:{always:[{target:"debouncing",cond:"isCalculable"},{target:"loaded"}]},debouncing:{after:{1e3:{target:"calculating"}}},calculating:{invoke:{src:"fetchCalculation",onDone:{target:"loaded",actions:"setCalculatedResult"},onError:{target:"loaded"}}},submitting:{invoke:{src:"submitDeposit",onDone:{target:"#deposit.submitted",actions:"setSubmittedResult"},onError:{target:"loaded"}}},switchingBonus:{invoke:{src:"setBonusSetting",onDone:{target:"checking"},onError:{target:"loaded"}}},submitted:{}},on:{SET_CRYPTO:{target:"checking",actions:"setCrypto",cond:"hasCryptoOptions"},SET_NETWORK:{target:"checking",actions:"setNetwork",cond:"hasNetworkOptions"},SET_AMOUNT:{target:"checking",actions:"setAmount"},TOGGLE_BONUS:{target:"switchingBonus",actions:"toggleBonus"}}},{actions:{setCryptos:_t((function(t,e){return{cryptos:e.data}})),setCrypto:_t((function(t,e){var r,n=t.cryptos,i=t.currentNetwork,o=(null===(r=n.find((function(t){return t.channel===e.data})))||void 0===r?void 0:r.optional)||[],a={currentCrypto:e.data,networks:o};return o.includes(i)||(a.currentNetwork=null,a.currentAmount=null,a.calculatedResult=null),a})),setNetwork:_t((function(t,e){return{currentNetwork:e.data}})),setAmount:_t((function(t,e){return{currentAmount:e.data}})),setCalculatedResult:_t((function(t,e){return{calculatedResult:e.data}})),setSubmittedResult:_t((function(t,e){return{submittedResult:e.data}})),toggleBonus:_t((function(t,e){return{bonus:1===t.bonus?0:1}})),setBonus:_t((function(t,e){return{bonus:e.data}}))},guards:{hasCryptoOptions:function(t,e){return t.cryptos.length>0},hasNetworkOptions:function(t,e){return t.networks.length>0},isCalculable:function(t,e){var r=t.currentCrypto,n=t.currentNetwork,i=t.currentAmount;return r&&n&&Pe()(i)},isSubmittable:function(t,e){return t.calculatedResult},isBonusOff:function(t,e){return 1!==t.bonus}},services:{fetchPayments:(o=Ce(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getPaymentDetail({transferType:"DEPOSIT"}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return o.apply(this,arguments)}),fetchCalculation:(i=Ce(regeneratorRuntime.mark((function e(r,n){var i,o,a,s,c;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=r.cryptos,a=r.currentCrypto,s=r.currentAmount,c=null===(i=o.find((function(t){return t.channel===a})))||void 0===i?void 0:i.method,e.next=4,t.send(l.getDepositExpectedResult({method:c,amount:s,cryptoCurrency:a}));case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)}))),function(t,e){return i.apply(this,arguments)}),submitDeposit:(n=Ce(regeneratorRuntime.mark((function e(r,n){var i,o,a,s,c,u;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=r.cryptos,a=r.currentCrypto,s=r.currentNetwork,c=r.calculatedResult,u=null===(i=o.find((function(t){return t.channel===a})))||void 0===i?void 0:i.method,e.next=4,t.send(l.submitDepositTransaction({method:u,amount:c.actualAmount,cryptoCurrency:a,cryptoNetwork:s}));case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),setBonusSetting:(r=Ce(regeneratorRuntime.mark((function e(r,n){var i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.bonus,e.next=3,t.send(l.setBonusSetting({bonus:i}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),getPaymentInfo:(e=Ce(regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getPaymentInfo());case 2:return i=e.sent,o=i.bonus,e.abrupt("return",o);case 5:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n,i,o},error:function(){return Mt({id:"error",initial:"normal",context:{error:null,gameCode:null},states:{normal:{on:{SET_ERROR:{target:"error",actions:"setError"}}},error:{initial:"unknown",states:{unknown:{always:[{target:"logout",cond:"isLogout"},{target:"deposit",cond:"isNoBalance"},{target:"unfinishedGame",cond:"isUnfinishedGame",actions:"setUnfinishedGame"},{target:"hall"}]},logout:{},deposit:{},unfinishedGame:{},hall:{}}}},on:{SOLVE:{target:"normal",actions:"solveError"}}},{actions:{setError:_t((function(t,e){return{error:e.data}})),solveError:_t({error:null}),setUnfinishedGame:_t((function(t,e){return{gameCode:t.error.extend.split(/_(.+)/)[1]}}))},guards:{isLogout:function(t,e){return["ERR_A201","ERR_A204","ERR_A103","ERR_A104","ERR_A108","ERR_F108"].includes(t.error.code)},isNoBalance:function(t,e){return"ERR_G106"===t.error.code},isUnfinishedGame:function(t,e){var r,n;return null===(r=t.error.extend)||void 0===r||null===(n=r.includes)||void 0===n?void 0:n.call(r,"unfinished_")}},services:{}})},game:function(t){return Mt({id:"game",type:"parallel",context:{roomId:null,list:[],game:{provider:null,game_id:null,game_type:null,mapping_id:null},lang:"en_US",gameURL:null,tick:2e3,isMobile:!1,sha:{category:null,status:null},isCategoryChanged:!1,isStatusChanged:!1,statusMap:{},optionMap:{}},states:{flow:{initial:"idle",states:{idle:{enter:"clearGameInfo",on:{ENTER_ROOM:{target:"loading",actions:"setRoomId",cond:function(t,e){return t.roomId!==e.roomId}},ENTER_GAME:{target:"connecting",actions:["setGameInfo","setLang"],cond:function(t,e){return t.list.length>0}}}},loading:{invoke:{src:"getRoomItems",onDone:{target:"idle",actions:"setList"},onError:{target:"idle",actions:_t({list:[]})}}},connecting:{invoke:{src:"connectGame",onDone:{target:"playing",actions:"setGameURL"},onError:{target:"idle"}}},playing:{on:{EXIT_GAME:{target:"disconnect"}}},disconnect:{invoke:{src:"disconnectGame",onDone:{target:"idle"},onError:{target:"idle"}}}}},schedule:{initial:"fetchingGameSHA",states:{fetchingGameSHA:{invoke:{src:"fetchGameSHA",onDone:{target:"checking",actions:"setGameSHA"},onError:{}}},checking:{always:[{target:"updatingStatus",cond:"isStatusChanged"},{target:"updatingCategory",cond:"isCategoryChanged"},{target:"idle"}]},updatingStatus:{invoke:{src:"fetchStatus",onDone:{target:"updatingOption",actions:["setStatus"]},onError:{}}},updatingOption:{invoke:{src:"fetchOption",onDone:{target:"updatingCategory",actions:"mergeOption"}}},updatingCategory:{invoke:{src:"getRoomItems",onDone:{target:"idle",actions:"setList"},onError:{target:"idle"}}},idle:{after:{TIMEOUT:{target:"fetchingGameSHA"}}}}}},on:{SET_MOBILE:{actions:"setMobile"}}},{actions:{setRoomId:_t((function(t,e){return{roomId:e.roomId}})),setList:_t({list:function(t,e){return e.data.list}}),setGameURL:_t({gameURL:function(t,e){return e.data.gameURL}}),clearGameInfo:_t((function(t,e){return{game:{provider:null,game_id:null,game_type:null,mapping_id:null}}})),setGameInfo:_t((function(t,e){var r=e.data.game;return{game:{provider:r.provider,game_id:r.game_id,game_type:r.game_type,mapping_id:r.mapping_id}}})),setLang:_t((function(t,e){return{lang:e.data.locale.replace("-","_")}})),setMobile:_t((function(t,e){return{isMobile:e.data}})),setGameSHA:_t((function(t,e){var r=t.sha,n=e.data;return{sha:n,isCategoryChanged:n.category!==(r.category||"0"),isStatusChanged:n.status!==(r.status||"0")}})),setStatus:_t((function(t,e){return{statusMap:e.data}})),mergeOption:_t((function(t,e){return{optionMap:Ue(Ue({},t.optionMap),e.data)}}))},guards:{isCategoryChanged:function(t,e){return t.isCategoryChanged},isStatusChanged:function(t,e){return t.isStatusChanged}},delays:{TIMEOUT:function(t,e){return 10*t.tick}},services:{getRoomItems:(s=Le(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(o.getGameCategory({id:r.roomId}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return s.apply(this,arguments)}),connectGame:(a=Le(regeneratorRuntime.mark((function e(r,n){var i,a,s,c,u,l,f,p,d,v;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.lang,a=r.isMobile,s=r.game,c=s.provider,u=s.game_id,l=s.game_type,f=s.mapping_id,p={provider_id:c,game_id:u,gametype_id:l,mapping_id:f,is_demo:!1,is_mobile:a,lang:i,return_url:window.location.href},e.next=5,t.send(o.playGame(p));case 5:return d=e.sent,v=d.redirect_url,e.abrupt("return",{gameURL:v});case 8:case"end":return e.stop()}}),e)}))),function(t,e){return a.apply(this,arguments)}),disconnectGame:(i=Le(regeneratorRuntime.mark((function e(r,n){var i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=n.data,e.next=3,t.send(o.logoutGame({uid_site:i,provider_id:r.game.provider}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return i.apply(this,arguments)}),fetchOption:(n=Le(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r.optionIds,e.next=3,t.send(o.getOptionMap());case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),fetchGameSHA:(r=Le(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(o.getGameSHA());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),fetchStatus:(e=Le(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(o.getGameStatus());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n,i,a,s},game_favorite:function(t){return Mt({id:"favorite",type:"parallel",context:{list:[]},states:{fetching:{initial:"disable",states:{disable:{},enable:{invoke:{src:"fetchList",onDone:{actions:"setList"},onError:{actions:_t({list:[]})}}}}},adding:{initial:"disable",states:{disable:{},enable:{invoke:{src:"add",onDone:{},onError:{actions:"removeFromList"}}}}},removing:{initial:"disable",states:{disable:{},enable:{invoke:{src:"remove",onDone:{},onError:{actions:"addToList"}}}}}},on:{FETCH_LIST:{target:"fetching.enable"},ADD:{target:"adding.enable",actions:"addToList",cond:"isNotExist"},REMOVE:{target:"removing.enable",actions:"removeFromList",cond:"isExist"}}},{actions:{setList:_t((function(t,e){return{list:e.data}})),addToList:_t((function(t,e){return{list:[].concat((r=t.list,function(t){if(Array.isArray(t))return Ve(t)}(r)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(r)||function(t,e){if(t){if("string"==typeof t)return Ve(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ve(t,e):void 0}}(r)||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.data])};var r})),removeFromList:_t((function(t,e){return{list:t.list.filter((function(t){return t!==e.data}))}}))},guards:{isExist:function(t,e){return t.list.includes(e.data)},isNotExist:function(t,e){return!t.list.includes(e.data)}},services:{add:(n=Ge(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t.send(o.addFavoriteGame(n.data));case 3:return e.abrupt("return",e.sent);case 6:throw e.prev=6,e.t0=e.catch(0),n.data;case 9:case"end":return e.stop()}}),e,null,[[0,6]])}))),function(t,e){return n.apply(this,arguments)}),remove:(r=Ge(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t.send(o.removeFavoriteGame(n.data));case 3:return e.abrupt("return",e.sent);case 6:throw e.prev=6,e.t0=e.catch(0),n.data;case 9:case"end":return e.stop()}}),e,null,[[0,6]])}))),function(t,e){return r.apply(this,arguments)}),fetchList:(e=Ge(regeneratorRuntime.mark((function e(r,n){var i,a,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(o.getGameCategory({}));case 2:return i=e.sent,a=i.list.find((function(t){return"SYSTEM_MY_FAVORITE"===t.category})),e.next=6,t.send(o.getGameCategory({id:a.id}));case 6:return s=e.sent,e.abrupt("return",s.list.map((function(t){return t.g})));case 8:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n},game_search:function(t){return Mt({id:"game_search",initial:"preset",context:{keyword:"",tagId:null,mainTagList:[],tagList:[],gameList:[],tagIndex:null,click:null,clickDefault:null,traceId:null,gameCode:null},states:{preset:{invoke:{src:"fetchTags",onDone:{target:"loading",actions:["setMainTagList","setInitialTagId"]},onError:{target:"fail"}}},loading:{invoke:{src:"fetchGames",onDone:{target:"idle",actions:"setGames"},onError:{target:"#game_search.fail"}}},idle:{on:{SET_MAIN_TAG_ID:{target:"loading",actions:"setMainTagId"},PLAY_GAME:{target:"sendingTrace",actions:"setGameCode"},START_SEARCH:{target:"searching",actions:"clearKeyword"}}},searching:{initial:"debouncing",states:{debouncing:{after:{500:{target:"fetchingTagsByKeyword"}}},fetchingTagsByKeyword:{invoke:{src:"fetchTags",onDone:{actions:"setTagList"},onError:{target:"#game_search.fail"}}}},on:{SET_TAG_ID:{target:"loading",actions:"setTagId"},PRESS_ENTER:[{actions:Ot((function(t,e){return{type:"SET_TAG_ID",data:t.tagList[0].id}})),cond:"hasTagList"},{target:"sendingTrace",actions:"clearExceptKeyword"}],SET_KEYWORD:{target:"searching.debouncing",actions:"setKeyword"},STOP_SEARCH:{target:"loading",actions:"setInitialTagId"}}},sendingTrace:{invoke:{src:"sendTrace",onDone:{target:"idle"},onError:{target:"fail"}}},fail:{}}},{actions:{setMainTagList:_t((function(t,e){return{mainTagList:e.data}})),setInitialTagId:_t((function(t,e){return{tagId:t.mainTagList[0].id,tagIndex:0,keyword:""}})),setMainTagId:_t((function(t,e){var r=e.data,n=t.mainTagList.findIndex((function(t){return t.id===r}));return{keyword:"",tagId:r,tagIndex:n,click:null,clickDefault:null}})),setTagId:_t((function(t,e){var r=e.data,n=t.mainTagList,i=t.tagList;if(0===i.length){var o=n.findIndex((function(t){return t.id===r}));return{tagId:r,tagIndex:o,click:null,clickDefault:1}}var a=i.findIndex((function(t){return t.id===r}));return{tagId:r,tagIndex:a,click:1,clickDefault:null}})),setGames:_t((function(t,e){var r=e.data;return{traceId:r.traceId,gameList:r.result}})),setKeyword:_t((function(t,e){return{keyword:e.data}})),clearKeyword:_t((function(t,e){return{keyword:""}})),setTagList:_t((function(t,e){return{tagList:e.data}})),setGameCode:_t((function(t,e){var r=t.gameList,n=e.data,i=r.findIndex((function(t){return t===n}));return{gameCode:n,gameCodeIndex:i}})),clearExceptKeyword:_t((function(t,e){return{gameList:[],traceId:null,tagId:null,tagIndex:null,gameCode:null,gameCodeIndex:null,query:t.keyword,click:null,clickDefault:null}}))},guards:{hasMainTags:function(t,e){return t.mainTagList.length>0},hasTagList:function(t,e){return t.tagList.length>0}},services:{fetchTags:(n=qe(regeneratorRuntime.mark((function e(r,n){var i,a,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.keyword,e.next=3,t.send(o.getGameTags({q:i}));case 3:return a=e.sent,s=a.result,e.abrupt("return",s);case 6:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),fetchGames:(r=qe(regeneratorRuntime.mark((function e(r,n){var i,a,s,c,u,l,f,p;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.tagId,a=r.tagIndex,s=r.keyword,c=r.click,u=r.clickDefault,e.next=3,t.send(o.getGameSearchList({id:i,index:a,q:s,click:c,clickDefault:u}));case 3:return l=e.sent,f=l.traceId,p=l.result,e.abrupt("return",{traceId:f,result:p});case 7:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),sendTrace:(e=qe(regeneratorRuntime.mark((function e(r,n){var i,a,s,c,u,l,f,p;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.traceId,a=r.tagId,s=r.tagIndex,c=r.gameCode,u=r.gameCodeIndex,l=r.keyword,f=r.click,p=r.clickDefault,e.next=3,t.send(o.setGameSearchTrace({traceId:i,tagId:a,tagIndex:s,gameCode:c,gameCodeIndex:u,query:l,click:f,clickDefault:p}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n},inbox:function(e){var r,n,i,o=e.config.appSecret;return Mt({id:"inbox",initial:"loading",context:{tabs:[],currentTab:null,inbox:{},messageDetail:null},states:{loading:{invoke:{src:"fetchTabs",onDone:{target:"checking",actions:"setTabs"},onError:{target:"failed"}}},checking:{always:[{target:"end",cond:"isEnd"},{target:"loadingMessages"}]},loadingMessages:{invoke:{src:"fetchMessages",onDone:{target:"more",actions:"setInbox"},onError:{target:"end"}}},more:Je(Je({},Xe),{},{on:{LOAD_MESSAGES:{target:"checking"}}}),end:Je({},Xe),failed:{}},on:{SET_TAB:{target:".checking",actions:["setCurrentTab","hideMessage"],cond:"hasTabs"},PRESET_TAB:{actions:["setCurrentTab","hideMessage"]},RESET:{target:".loading",actions:"reset"}}},{guards:{hasTabs:function(t,e){return t.tabs.length>0},isEnd:function(t,e){var r=t.currentTab,n=t.inbox;if(n[r]){var i=n[r];return i.page+1>=i.totalPage}return!1},isRead:function(t,e){return e.data.isRead}},actions:{reset:_t((function(t,e){return{tabs:[],currentTab:null,inbox:{},messageDetail:null}})),setTabs:_t((function(t,e){var r,n=t.currentTab;return n||(n=null===(r=e.data)||void 0===r?void 0:r[0]),{tabs:e.data,currentTab:n}})),setCurrentTab:_t((function(t,e){return{currentTab:e.data}})),showMessage:_t((function(t,e){return{messageDetail:e.data}})),hideMessage:_t((function(t,e){return{messageDetail:null}})),setInbox:_t((function(t,e){return{inbox:e.data}})),setMessageIsRead:_t((function(t,e){var r=JSON.parse(JSON.stringify(t)),n=r.inbox,i=r.currentTab,o=n[i].data.map((function(t){return t.groupId===e.data.groupId&&(t.isRead=!0),t}));return n[i].data=o,{inbox:n}}))},services:{fetchTabs:(i=Ye(regeneratorRuntime.mark((function t(r,n){var i,o,s;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.send(a.getMessageTypes());case 2:return o=t.sent,s=(null===(i=o.data)||void 0===i?void 0:i.map((function(t){return t.type})))||[],t.abrupt("return",s);case 5:case"end":return t.stop()}}),t)}))),function(t,e){return i.apply(this,arguments)}),fetchMessages:(n=Ye(regeneratorRuntime.mark((function r(n,i){var s,c,u,l,f,p,d,v,y,h,g,m,b;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(s=JSON.parse(JSON.stringify(n)),c=s.currentTab,u=s.inbox,"REWARD"!==c){r.next=9;break}return r.next=4,e.send(t.getRewardList({count:30,appSecret:o}));case 4:l=r.sent,f=l.data,u[c]={data:f,page:0,totalPage:1},r.next=17;break;case 9:return y=(null===(p=u[c])||void 0===p?void 0:p.page)&&(null===(d=u[c])||void 0===d?void 0:d.page)+1,r.next=12,e.send(a.getMessageList({type:c,page:y}));case 12:h=r.sent,g=h.data,m=ze(h,He),b=(null===(v=u[c])||void 0===v?void 0:v.data)||[],u[c]=Je({data:b.concat(g)},m);case 17:return r.abrupt("return",u);case 18:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),updateMessageIsRead:(r=Ye(regeneratorRuntime.mark((function t(r,n){var i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=n.data,e.send(a.updateMessage({groupId:i.groupId,isRead:!0})),i.isRead=!0,t.abrupt("return",i);case 4:case"end":return t.stop()}}),t)}))),function(t,e){return r.apply(this,arguments)})}})},merge:function(t){return Mt({id:"merge",initial:"idle",context:{userInfo:null},states:{idle:{always:[{target:"mergeable",cond:"isMergeable"}]},mergeable:{on:{MERGE:{target:"merging"}}},merging:{invoke:{src:"mergeWallet",onDone:{target:"idle"},onError:{target:"idle"}}}},on:{SET_USER_INFO:{actions:"setUserInfo"}}},{actions:{setUserInfo:_t((function(t,e){return{userInfo:e.data}}))},guards:{isMergeable:function(t,e){var r=t.userInfo||{},n=r.retain,i=r.balance,o=r.withdraw_policy;return n>0&&(parseFloat(i)<=5||"FREE"===o)}},services:{mergeWallet:(e=regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.mergeWallet());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})),r=function(){var t=this,r=arguments;return new Promise((function(n,i){var o=e.apply(t,r);function a(t){Ze(o,n,i,a,s,"next",t)}function s(t){Ze(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return r.apply(this,arguments)})}});var e,r},payment_data:function(t){return Mt({id:"payment_data",initial:"idle",context:{transactionList:[],spotMarketTime:null,spotMarketList:[]},states:{idle:{},fetchingTransactionList:{invoke:{src:"fetchTransactionList",onDone:{target:"idle",actions:"setTransactionList"},onError:{}}},fetchingSpotMarket:{invoke:{src:"fetchSpotMarket",onDone:{target:"idle",actions:"setSpotMarket"},onError:{}}}},on:{GET_TRANSACTION_LIST:{target:"fetchingTransactionList"},GET_SPOT_MARKET:{target:"fetchingSpotMarket"}}},{actions:{setTransactionList:_t((function(t,e){var r={2:"pending",3:"success",4:"fail",6:"reject"};return{transactionList:e.data.map((function(t){return t.statusName=r[t.status],t}))}})),setSpotMarket:_t((function(t,e){var r=e.data;return{spotMarketTime:r.timestamp,spotMarketList:r.data.slice(0,100)}}))},services:{fetchTransactionList:(r=er(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getPaymentHistory(7));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),fetchSpotMarket:(e=er(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getSpotMarket());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r},reward:function(e){var r,n,i=e.config.appSecret;return Mt({id:"reward",initial:"loading",context:{rewardList:[]},states:{loading:{invoke:{src:"fetchRewardList",onDone:{target:"loaded",actions:"setRewardList"},onError:{target:"loaded"}}},loaded:{on:{RECEIVE_REWARD:{target:"receiving"}}},receiving:{invoke:{src:"receiveReward",onDone:{target:"animating"},onError:{target:"loading"}}},animating:{after:{0:{target:"loading"}}}}},{actions:{setRewardList:_t((function(t,e){return{rewardList:e.data}}))},services:{fetchRewardList:(n=nr(regeneratorRuntime.mark((function r(n,o){var a,s;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,e.send(t.getRewardList({count:30,appSecret:i}));case 2:return a=r.sent,s=a.data,r.abrupt("return",s);case 5:case"end":return r.stop()}}),r)}))),function(t,e){return n.apply(this,arguments)}),receiveReward:(r=nr(regeneratorRuntime.mark((function r(n,o){var a,s,c;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return a=o.data,s=a.activityNo,c=a.receiveNo,r.next=3,e.send(t.getReward({activityNo:s,receiveNo:c,appSecret:i}));case 3:return r.abrupt("return",r.sent);case 4:case"end":return r.stop()}}),r)}))),function(t,e){return r.apply(this,arguments)})}})},setting:function(){return Mt({id:"setting",initial:"idle",context:{sound:!1,music:!1,locale:"en-US"},entry:"fetchSetting",states:{idle:{}},on:{MODIFY_SETTING:{actions:"saveSetting"}}},{actions:{fetchSetting:_t((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ir(Object(r),!0).forEach((function(e){or(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ir(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({},JSON.parse(localStorage.getItem("setting"))||{sound:!0,music:!0})})),saveSetting:_t((function(t,e){var r=e.data,n=r.sound,i=r.music,o=r.locale;return localStorage.setItem("setting",JSON.stringify({sound:n,music:i,locale:o})),{sound:n,music:i,locale:o}}))}})},side:function(t){return Mt({id:"side",initial:"preparing",context:{menu:{},roomId:null,roomHistory:[]},states:{preparing:{invoke:{src:"getRoomItems",onDone:{target:"room",actions:"mapListToMenu"},onError:{target:"room"}}},room:{entry:"resetRoomHistory",initial:"home",states:{home:{entry:_t({roomId:function(t,e){return t.menu.home}})},favorite:{entry:_t({roomId:function(t,e){return t.menu.favorite}})},hot:{entry:_t({roomId:function(t,e){return t.menu.hot}})},new:{entry:_t({roomId:function(t,e){return t.menu.new}})},slot:{entry:_t({roomId:function(t,e){return t.menu.slot}})},fish:{entry:_t({roomId:function(t,e){return t.menu.fish}})},arcade:{entry:_t({roomId:function(t,e){return t.menu.arcade}})},table:{entry:_t({roomId:function(t,e){return t.menu.table}})},search:{},history:{type:"history"}}},feature:{on:{RETURN:{target:"room.history"},CLICK_HOT:{target:"room.hot"},CLICK_NEW:{target:"room.new"}}},category:{on:{RETURN:{target:"room.history"},CLICK_SLOT:{target:"room.slot"},CLICK_FISH:{target:"room.fish"},CLICK_ARCADE:{target:"room.arcade"},CLICK_TABLE:{target:"room.table"}}}},on:{CLICK_HOME:{target:"room.home"},CLICK_FAVORITE:{target:"room.favorite"},CLICK_FEATURE:{target:"feature"},CLICK_CATEGORY:{target:"category"},CLICK_SEARCH:{target:"room.search"},FORWARD_ROOM:{actions:"forwardRoom"},BACKWARD_ROOM:{actions:"backwardRoom"}}},{actions:{mapListToMenu:_t((function(t,e){var r=e.data.list,n=void 0===r?[]:r,i={home:["SYSTEM_PERSONAL","SYSTEM_INDEX_LIST"],favorite:"SYSTEM_MY_FAVORITE",hot:"SYSTEM_TOP_GAME",new:"SYSTEM_NEW_GAME",slot:"SYSTEM_BIG_CATEGORY_SLOT",fish:"SYSTEM_BIG_CATEGORY_FISHING",arcade:"SYSTEM_BIG_CATEGORY_ARCADE",table:"SYSTEM_BIG_CATEGORY_TABLECARD"},o={};return Object.keys(i).forEach((function(t){var e;Array.isArray(i[t])?i[t].some((function(e){var r,i=null===(r=n.find((function(t){return t.category===e})))||void 0===r?void 0:r.id;return!!i&&(o[t]=i,!0)})):o[t]=null===(e=n.find((function(e){return e.category===i[t]})))||void 0===e?void 0:e.id})),{menu:o}})),forwardRoom:_t((function(t,e){return{roomId:e.data,roomHistory:[].concat((r=t.roomHistory,function(t){if(Array.isArray(t))return sr(t)}(r)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(r)||function(t,e){if(t){if("string"==typeof t)return sr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?sr(t,e):void 0}}(r)||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.")}()),[t.roomId])};var r})),backwardRoom:_t((function(t,e){var r=t.roomHistory;return{roomId:r.slice(-1)[0],roomHistory:r.slice(0,-1)}})),resetRoomHistory:_t((function(t,e){return{roomHistory:[]}}))},services:{getRoomItems:(e=regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(o.getGameCategory({id:r.roomId}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})),r=function(){var t=this,r=arguments;return new Promise((function(n,i){var o=e.apply(t,r);function a(t){ar(o,n,i,a,s,"next",t)}function s(t){ar(o,n,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return r.apply(this,arguments)})}});var e,r},withdraw:function(t){return Mt({id:"withdraw",initial:"idle",context:{isTurnoverMode:!1,siteConfig:null,userInfo:null,crypto:null,networks:[],currentNetwork:"",currentAddress:"",withdrawMethods:[],withdrawRuleName:null,withdrawRules:[],withdrawLimit:null,withdrawAmount:null,withdrawLeft:null,tutorialUrls:[],balance:null,charge:null},states:{idle:{on:{PRESET:{target:"mode",actions:["setSiteConfig","setUserInfo","preset"]}}},mode:{always:[{target:"free",cond:"isFree"},{target:"cash"}]},free:{initial:"preparing",states:{preparing:{invoke:{src:"fetchWithdrawRules",onDone:{target:"convertible",actions:"updateWithdrawCondition"},onError:{target:"notConvertible"}}},notConvertible:{},convertible:{initial:"preparing",states:{preparing:{invoke:{src:"fetchPayments",onDone:{target:"operation",actions:"setCrypto"},onError:{target:"#withdraw.free.notConvertible"}}},operation:{on:{SET_NETWORK:{actions:"setNetwork"},SET_ADDRESS:{actions:"setAddress"},CALCULATE:{target:"calculating",cond:"isCalculable"},SUBMIT:{target:"#withdraw.free.converting"}}},calculating:{entry:"resetCharge",invoke:{src:"fetchCalculation",onDone:{target:"operation",actions:"setCalculatedResult"},onError:{target:"operation"}}}}},converting:{invoke:{src:"submitWithdrawFree",onDone:{target:"converted"},onError:{target:"convertible.operation"}}},converted:{}}},cash:{initial:"checking",states:{checking:{entry:"calculateCashLeft",always:[{target:"disable",cond:"isWithdrawDisable"},{target:"transferable",cond:"isTransferable"},{target:"notTransferable"}]},disable:{},notTransferable:{},transferable:{entry:"setBalanceToWithdrawAmount",initial:"preparing",states:{preparing:{invoke:{src:"fetchPayments",onDone:{target:"operation",actions:"setCrypto"},onError:{target:"#withdraw.cash.checking"}}},operation:{on:{SET_NETWORK:{actions:"setNetwork"},SET_ADDRESS:{actions:"setAddress"},CALCULATE:{target:"calculating",cond:"isCalculable"},SUBMIT:{target:"#withdraw.cash.transferring"}}},calculating:{entry:"resetCharge",invoke:{src:"fetchCalculation",onDone:{target:"operation",actions:"setCalculatedResult"},onError:{target:"operation"}}}}},transferring:{invoke:{src:"submitWithdraw",onDone:{target:"transferred"},onError:{target:"transferable.operation"}}},transferred:{}}}}},{actions:{setUserInfo:_t((function(t,e){return{userInfo:e.data.userInfo}})),setSiteConfig:_t((function(t,e){return{siteConfig:e.data.siteConfig}})),preset:_t((function(t,e){var r,n=e.data,i=n.userInfo,o=n.siteConfig,a=i||{},s=a.withdraw_rule,c=a.withdraw_limit,u=parseFloat(null==i?void 0:i.balance);return{balance:u,withdrawRuleName:s,withdrawLimit:((null==o||null===(r=o.paymentMethods)||void 0===r?void 0:r.withdraw)||[]).includes("amb")?-1*(c+u):-1*c}})),updateWithdrawCondition:_t((function(t,e){var r,n=e.data.rules.filter((function(t){return t.maxWithdrawAmount>0})),i=e.data.adUrl.map((function(t){return t.url})),o=t.balance,a=t.withdrawLimit,s=ur()(n,(function(t){return o>=t.greaterEqualThen})),c=0,u=0;if(s>-1)n[s].match=!0,u=n[s].maxWithdrawAmount,r=n[s].greaterEqualThen;else if(a){var l=a-o;r=a,l<0?u=o:c=l}else{var f,p;c=(null===(f=n[0])||void 0===f?void 0:f.greaterEqualThen)-o,r=null===(p=n[0])||void 0===p?void 0:p.greaterEqualThen}return{withdrawLeft:c,withdrawAmount:u,withdrawLimit:r,withdrawRules:n,tutorialUrls:i}})),setBalanceToWithdrawAmount:_t((function(t,e){return{withdrawAmount:t.balance}})),setCrypto:_t((function(t,e){var r,n,i;return{crypto:null===(r=e.data)||void 0===r?void 0:r[0],networks:(null===(n=e.data)||void 0===n||null===(i=n[0])||void 0===i?void 0:i.optional)||[]}})),setNetwork:_t((function(t,e){return{currentNetwork:e.data}})),setAddress:_t((function(t,e){return{currentAddress:e.data}})),setCalculatedResult:_t((function(t,e){return{charge:e.data.charge}})),resetCharge:_t((function(t,e){return{charge:null}})),calculateCashLeft:_t((function(t,e){var r=t.balance,n=t.withdrawLimit-r;return{withdrawLeft:Math.max(n,0)}}))},guards:{isFree:function(t,e){var r;return"FREE"===(null===(r=t.userInfo)||void 0===r?void 0:r.withdraw_policy)},isWithdrawDisable:function(t,e){var r,n=t.siteConfig;return 0===((null==n||null===(r=n.paymentMethods)||void 0===r?void 0:r.withdraw)||[]).length},isTransferable:function(t,e){var r=t.balance,n=t.withdrawLimit,i=t.isTurnoverMode;return 0!==r&&(i?0===n:r-n>=0)},isCalculable:function(t,e){var r=t.currentNetwork,n=t.balance;return r&&n}},services:{fetchWithdrawRules:(o=fr(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getCurrentWithdrawRule());case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return o.apply(this,arguments)}),fetchPayments:(i=fr(regeneratorRuntime.mark((function e(r,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.send(l.getPaymentDetail({transferType:"WITHDRAW"}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(t,e){return i.apply(this,arguments)}),submitWithdraw:(n=fr(regeneratorRuntime.mark((function e(r,n){var i,o,a,s,c;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.crypto,o=r.currentNetwork,a=r.currentAddress,s=r.withdrawAmount,c=i.method,e.next=4,t.send(l.submitWithdrawTransaction({method:c,amount:s,cryptoCurrency:i.channel,cryptoNetwork:o,targetAddress:a}));case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)}))),function(t,e){return n.apply(this,arguments)}),submitWithdrawFree:(r=fr(regeneratorRuntime.mark((function e(r,n){var i,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.currentNetwork,o=r.currentAddress,e.next=3,t.send(l.convertFreeCredit({exchangeType:1,cryptoNetwork:i,targetAddress:o}));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)}))),function(t,e){return r.apply(this,arguments)}),fetchCalculation:(e=fr(regeneratorRuntime.mark((function e(r,n){var i,o,a,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=r.crypto,o=r.currentNetwork,a=r.withdrawAmount,s=i.method,e.next=4,t.send(l.getWithdrawExpectedResult({method:s,amount:a,cryptoNetwork:o}));case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)}))),function(t,r){return e.apply(this,arguments)})}});var e,r,n,i,o}});var hr=r(5937),gr=r.n(hr);function mr(t,e,r,n,i,o,a){try{var s=t[o](a),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,i)}function br(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function wr(t){return null!=t}var xr=function(){function t(e,r,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.axios=e,this.source=e.CancelToken.source(),this.config=r,this.cookie=n,this.errorHandler=null,this.initialize()}var e,r,n,i;return e=t,r=[{key:"initialize",value:function(){var t=this;this.axios.interceptors.request.use((function(e){return e.headers["X-TH1GAMES-VERSION"]=t.config.version,e.headers["X-TH1GAMES-PLATFORM"]=t.config.platform,t.cookie.getToken()&&(e.headers.Authorization=t.cookie.getToken()),e})),this.axios.interceptors.response.use((function(t){return t.data.error?Promise.reject(t.data.error):Promise.resolve(t)}),(function(t){var e,r;return"Network Error"===t.message||"Request failed with status code 404"===t.message?Promise.reject({code:"ERR_998"}):Promise.reject((null===(e=t.response)||void 0===e||null===(r=e.data)||void 0===r?void 0:r.error)||t)}))}},{key:"setErrorHandler",value:function(t){this.errorHandler=t}},{key:"send",value:(n=regeneratorRuntime.mark((function t(e,r){var n,i,o,a;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,n=r||this.source.token,this._checkToken(e,this.cookie.getToken()),i=this._createConfig(e,n),t.next=6,this.axios.request(i);case 6:return o=t.sent,a=o.data,t.abrupt("return",a);case 11:throw t.prev=11,t.t0=t.catch(0),t.t0.code&&this.errorHandler&&this.errorHandler(t.t0),t.t0;case 15:case"end":return t.stop()}}),t,this,[[0,11]])})),i=function(){var t=this,e=arguments;return new Promise((function(r,i){var o=n.apply(t,e);function a(t){mr(o,r,i,a,s,"next",t)}function s(t){mr(o,r,i,a,s,"throw",t)}a(void 0)}))},function(t,e){return i.apply(this,arguments)})},{key:"sourceUpdate",value:function(){this.source.cancel("Requests Cancelled"),this.source=this.axios.CancelToken.source()}},{key:"sourceGenerate",value:function(){return this.axios.CancelToken.source()}},{key:"_createConfig",value:function(t,e){var r,n,i,o=t.method,a=t.url,s=t.params,c=t.isPublic;return r={baseURL:this.config.fullURL,method:o,url:a,cancelToken:e,isPublic:c},n="GET"===o.toUpperCase()?"params":"data",i=gr()(s,wr),n in r?Object.defineProperty(r,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):r[n]=i,r}},{key:"_checkToken",value:function(t,e){if(!t.isPublic&&!e)throw console.error(t),{code:"ERR_A103",url:t.url}}}],r&&br(e.prototype,r),t}();function Sr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var kr=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.cookies=new ve,this.tokenKey=e}var e,r;return e=t,r=[{key:"setToken",value:function(t){this.cookies.set(this.tokenKey,t,{path:"/",maxAge:300})}},{key:"prolongToken",value:function(){var t=this.getToken();t&&this.setToken(t)}},{key:"getToken",value:function(){return this.cookies.get(this.tokenKey)}},{key:"removeToken",value:function(){this.cookies.remove(this.tokenKey,{path:"/",maxAge:300})}},{key:"setUser",value:function(t){this.cookies.set("cuora_tempuser",t,{path:"/",maxAge:86400})}},{key:"getUser",value:function(){return this.cookies.get("cuora_tempuser")}},{key:"set",value:function(t,e,r){this.cookies.set(t,e,r)}},{key:"get",value:function(t,e){return this.cookies.get(t,e)}}],r&&Sr(e.prototype,r),t}();function Or(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var _r=function(){function t(e){var r=e.apiURL,n=e.apiVersion,i=e.clientId,o=e.appSecret,a=e.platform,s=e.version;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.apiURL=r,this.apiVersion=n,this.clientId=i,this.appSecret=o,this.platform=a,this.version=s,this.fullURL=ue()(this.apiURL,this.apiVersion,this.clientId)}var e,r;return e=t,(r=[{key:"setApiURL",value:function(t){this.apiURL=t,this.fullURL=ue()(this.apiURL,this.apiVersion,this.clientId)}}])&&Or(e.prototype,r),t}()})();var i=n.De,o=n.Vj,a=n.cf,s=n.hi,c=n.u_;export{i as Config,o as Cookie,a as Request,s as api,c as machine};
@@ -1,30 +0,0 @@
1
- /*!
2
- * cookie
3
- * Copyright(c) 2012-2014 Roman Shtylman
4
- * Copyright(c) 2015 Douglas Christopher Wilson
5
- * MIT Licensed
6
- */
7
-
8
- /*! *****************************************************************************
9
- Copyright (c) Microsoft Corporation.
10
-
11
- Permission to use, copy, modify, and/or distribute this software for any
12
- purpose with or without fee is hereby granted.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
15
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
16
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
17
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
18
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
19
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20
- PERFORMANCE OF THIS SOFTWARE.
21
- ***************************************************************************** */
22
-
23
- /*!@license
24
- * UAParser.js v0.7.28
25
- * Lightweight JavaScript-based User-Agent string parser
26
- * https://github.com/faisalman/ua-parser-js
27
- *
28
- * Copyright © 2012-2021 Faisal Salman <f@faisalman.com>
29
- * Licensed under MIT License
30
- */