"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[7599],{85688:function(t,e,n){var r,o=this&&this.__extends||(r=function(t,e){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},r(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.TtWid=void 0;var i=function(t){function e(e){return e.needFid=!1,t.call(this,e)||this}return o(e,t),e}(n(99192).TtWidCore);e.TtWid=i},99192:function(t,e,n){var r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,r=arguments.length;n0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]1001))return[3,11];_=h.migrate_info,i.label=5;case 5:return i.trys.push([5,10,,11]),this.options.union?[4,this.registerUnionWebId({migrate_info:_,fid:s})]:[3,7];case 6:return v=i.sent(),p=v,[3,9];case 7:return[4,this.registerOpenWebId({migrate_info:_,fid:s})];case 8:v=i.sent(),p=v,i.label=9;case 9:return[3,11];case 10:return b=i.sent(),console.error("ttwid register error",b,b.message),[2,h||d];case 11:return[2,p];case 12:throw i.sent();case 13:return[2]}}))}))},t.prototype.checkWebIdFromTea=function(){return o(this,void 0,void 0,(function(){var t,e,n,r,o;return i(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),t=localStorage&&localStorage.getItem("__tea_cache_tokens_".concat(this.options.aid))||"",e=t&&JSON.parse(t)||{},n=e.web_id,(r=void 0===n?"":n)&&(o=new Date(Date.now()+864e5).toUTCString(),document.cookie="_tea_web_id=".concat(r,"; expires=").concat(o,"; path=/;")),[4,this.checkWebId(u.CookieReadConfigEnum.COOKIE_READ_TEA_PRIOR)];case 1:return[2,i.sent()];case 2:throw i.sent();case 3:return[2]}}))}))},t.prototype.registerUnionWebId=function(t,e){return o(this,void 0,void 0,(function(){var n,o,s,u,l,d,f,h,p,_,v,b;return i(this,(function(i){switch(i.label){case 0:return i.trys.push([0,6,,7]),n=this.options,o=n.unionHost,s=void 0===o?"":o,u=n.cbUrlProtocol,l=void 0===u?"":u,[4,a.default.post("".concat(s,"/ttwid/union/register/"),r(r({},this.options),t),c)];case 1:if(d=i.sent(),f=d.data,!(h=void 0===f?null:f)||!h.redirect_url)return[3,5];i.label=2;case 2:return i.trys.push([2,4,,5]),p=h.redirect_url,l&&p&&(p=p.replace(/^https?/,l)),[4,a.default.get(p,c)];case 3:return _=i.sent(),e?[2,e(null,_.data||{})]:[2,_.data||{}];case 4:return v=i.sent(),e?[2,e(v,h||{})]:[2,h];case 5:if(e)return[2,e(new Error("ttwid union register error"))];throw new Error("ttwid union register error");case 6:if(b=i.sent(),e)return[2,e(b)];throw b;case 7:return[2]}}))}))},t.prototype.registerOpenWebId=function(t){return o(this,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return e.trys.push([0,2,,3]),[4,a.default.post("".concat(this.host,"/ttwid/register/"),r(r({},this.options),t),c)];case 1:return[2,e.sent().data];case 2:throw e.sent();case 3:return[2]}}))}))},t.prototype.getInstanceId=function(){var t;return o(this,void 0,void 0,(function(){return i(this,(function(e){return[2,(null===(t=this.firebaseClient)||void 0===t?void 0:t.getInstanceId())||""]}))}))},t.prototype.deleteInstallation=function(){var t;return o(this,void 0,void 0,(function(){return i(this,(function(e){return[2,null===(t=this.firebaseClient)||void 0===t?void 0:t.deleteInstallation()]}))}))},t}();e.TtWidCore=l},62412:(t,e)=>{var n;Object.defineProperty(e,"__esModule",{value:!0}),e.CookieReadConfigEnum=void 0,(n=e.CookieReadConfigEnum||(e.CookieReadConfigEnum={}))[n.COOKIE_READ_DEFAULT=0]="COOKIE_READ_DEFAULT",n[n.COOKIE_READ_TEA_PRIOR=1]="COOKIE_READ_TEA_PRIOR"}}]);