isometrik-chat 2.9.6-alpha → 2.9.6-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/index.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
module.exports=function(e){function t(t){for(var n,o,i=t[0],s=t[1],a=0,u=[];a<i.length;a++)o=i[a],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&u.push(r[o][0]),r[o]=0;for(n in s)Object.prototype.hasOwnProperty.call(s,n)&&(e[n]=s[n]);for(c&&c(t);u.length;)u.shift()()}var n={},r={0:0};function o(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,o),r.l=!0,r.exports}o.e=function(e){var t=[],n=r[e];if(0!==n)if(n)t.push(n[2]);else{var i=new Promise((function(t,o){n=r[e]=[t,o]}));t.push(n[2]=i);var s,a=document.createElement("script");a.charset="utf-8",a.timeout=120,o.nc&&a.setAttribute("nonce",o.nc),a.src=function(e){return o.p+""+({1:"pages-WhatsappMainBox",2:"vendors~pages-WhatsappMainBox"}[e]||e)+".js"}(e);var c=new Error;s=function(t){a.onerror=a.onload=null,clearTimeout(u);var n=r[e];if(0!==n){if(n){var o=t&&("load"===t.type?"missing":t.type),i=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+o+": "+i+")",c.name="ChunkLoadError",c.type=o,c.request=i,n[1](c)}r[e]=void 0}};var u=setTimeout((function(){s({type:"timeout",target:a})}),12e4);a.onerror=a.onload=s,document.head.appendChild(a)}return Promise.all(t)},o.m=e,o.c=n,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)o.d(n,r,function(t){return e[t]}.bind(null,r));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o.oe=function(e){throw console.error(e),e};var i=window.webpackJsonpisometrik_chat=window.webpackJsonpisometrik_chat||[],s=i.push.bind(i);i.push=t,i=i.slice();for(var a=0;a<i.length;a++)t(i[a]);var c=s;return o(o.s=33)}([function(e,t){e.exports=require("react")},function(e,t,n){"use strict";n.r(t);var r=n(11);t.default=function(){return r.default.getInstance()}},function(e,t,n){"use strict";e.exports=n(31)},function(e,t,n){"use strict";n.d(t,"c",(function(){return i})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return c}));var r=n(7),o=n.n(r),i=function(e,t){o.a.set(e,t)},s=function(e){o.a.remove(e,{expires:1})},a=function(){s("isometrikToken"),s("isometrikUserId"),window.location.href="/"},c=function(e){return u(e)},u=function(e){return o.a.get(e)}},function(e,t,n){"use strict";n.d(t,"q",(function(){return r})),n.d(t,"p",(function(){return o})),n.d(t,"m",(function(){return i})),n.d(t,"e",(function(){return s})),n.d(t,"b",(function(){return a})),n.d(t,"o",(function(){return c})),n.d(t,"t",(function(){return u})),n.d(t,"c",(function(){return l})),n.d(t,"a",(function(){return f})),n.d(t,"k",(function(){return h})),n.d(t,"l",(function(){return d})),n.d(t,"r",(function(){return p})),n.d(t,"g",(function(){return v})),n.d(t,"h",(function(){return g})),n.d(t,"f",(function(){return m})),n.d(t,"j",(function(){return y})),n.d(t,"i",(function(){return b})),n.d(t,"s",(function(){return w})),n.d(t,"n",(function(){return _})),n.d(t,"d",(function(){return S}));var r=25,o=1e3,i=60*o,s=60*i,a=24*s,c=30*a,u=12*c,l="deleteConversationLocally",f="clearConversation",h="messageDelivered",d="messageRead",p="User unblocked successfully.",v=5242880,g=52428800,m=52428800,y="messagesDeleteLocal",b="messagesDeleteForAll",w="userUnblockConversation",_=420,S="AIzaSyCD81udOzPUpOi14ZEo-7GzPwnClTROIeQ"},function(e,t,n){"use strict";function r(){return(r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";(function(e){n.d(t,"q",(function(){return v})),n.d(t,"w",(function(){return g})),n.d(t,"x",(function(){return m})),n.d(t,"E",(function(){return y})),n.d(t,"s",(function(){return b})),n.d(t,"d",(function(){return w})),n.d(t,"i",(function(){return _})),n.d(t,"F",(function(){return S})),n.d(t,"b",(function(){return E})),n.d(t,"B",(function(){return I})),n.d(t,"G",(function(){return A})),n.d(t,"l",(function(){return C})),n.d(t,"g",(function(){return k})),n.d(t,"c",(function(){return M})),n.d(t,"C",(function(){return O})),n.d(t,"D",(function(){return L})),n.d(t,"v",(function(){return T})),n.d(t,"k",(function(){return j})),n.d(t,"j",(function(){return x})),n.d(t,"p",(function(){return R})),n.d(t,"z",(function(){return P})),n.d(t,"A",(function(){return N})),n.d(t,"f",(function(){return D})),n.d(t,"o",(function(){return U})),n.d(t,"u",(function(){return V})),n.d(t,"a",(function(){return F})),n.d(t,"t",(function(){return Y})),n.d(t,"h",(function(){return B})),n.d(t,"n",(function(){return G})),n.d(t,"m",(function(){return W})),n.d(t,"e",(function(){return Z})),n.d(t,"r",(function(){return J})),n.d(t,"y",(function(){return q}));var r=n(25),o=n(1),i=n(4),s=n(21),a=n(22),c=n(23),u=n(3);function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function f(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */f=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},s=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",c=i.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:k(e,n,a)}),s}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p="suspendedStart",v="executing",g="completed",m={};function y(){}function b(){}function w(){}var _={};u(_,s,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,s)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,i,s,a){var c=d(e[o],e,i);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==l(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(f).then((function(e){u.value=e,s(u)}),(function(e){return n("throw",e,s,a)}))}a(c.arg)}var i;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return i=i?i.then(o,o):o()}})}function k(t,n,r){var o=p;return function(i,s){if(o===v)throw new Error("Generator is already running");if(o===g){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===m)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===p)throw o=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=v;var u=d(t,n,r);if("normal"===u.type){if(o=r.done?g:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=g,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var i=d(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,m;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,m):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(l(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=u(w,c,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,u(e,c,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),u(C.prototype,a,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(h(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),u(I,c,"Generator"),u(I,s,(function(){return this})),u(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),m}},t}function h(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function d(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){h(i,r,o,s,a,"next",e)}function a(e){h(i,r,o,s,a,"throw",e)}s(void 0)}))}}var p=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,v=function(){var e=d(f().mark((function e(){var t,n,o,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(n=Object(u.b)("deviceId")||(null===(t=window)||void 0===t?void 0:t.deviceId))){e.next=3;break}return e.abrupt("return",n);case 3:return e.next=5,r.a.load();case 5:return o=e.sent,e.next=8,o.get();case 8:return i=e.sent,e.abrupt("return",i.visitorId);case 10:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),g=function(){var e=d(f().mark((function e(t){var n,r,i,s;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.id,r=t.includeConversationStatusMessagesInUnreadMessagesCount,e.prev=1,e.next=4,null===(i=Object(o.default)())||void 0===i||null===(i=i.Conversation)||void 0===i?void 0:i.getConversations({ids:n,includeConversationStatusMessagesInUnreadMessagesCount:r});case 4:return s=e.sent,e.abrupt("return",s.conversations[0]);case 8:e.prev=8,e.t0=e.catch(1),console.log(e.t0,"error");case 11:case"end":return e.stop()}}),e,null,[[1,8]])})));return function(t){return e.apply(this,arguments)}}(),m=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(o.default)().Conversation.getConversations(t&&{searchTag:t});case 3:return n=e.sent,e.abrupt("return",n);case 7:e.prev=7,e.t0=e.catch(0),console.log(e.t0,"error");case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t){return e.apply(this,arguments)}}(),y=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,null===(n=Object(o.default)())||void 0===n||null===(n=n.user)||void 0===n?void 0:n.getPresignedurlUpdate({mediaExtension:t});case 2:return r=e.sent,e.abrupt("return",r);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),b=function(){var e=d(f().mark((function e(t,n,r){var o;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch(t,{method:"PUT",body:n,headers:{"Content-Type":r}});case 2:return o=e.sent,e.abrupt("return",o);case 4:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),w=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().Conversation.deleteConversationLocal({conversationId:t});case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),_=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().Conversation.deleteConversationClear({conversationId:t});case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),S="https://chat-storage.isometrik.io/60b1ef70ffcf750001d0440d/fc4bfc08-3243-420f-884d-1ce37d3f453b/Users/643f9aec09b87e00014625d2_1682328163954.png",E=function(e){return["image/png","image/jpg","image/jpeg","image/webp"].includes(null==e?void 0:e.type)?(null==e?void 0:e.size)>i.g?{valid:!1,error:"File size should be less than ".concat(i.g/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},I=function(e){var t="mp4"===e.type.split("/")[1]?i.h:i.g;return["image/png","image/jpg","image/jpeg","video/mp4","image/gif","image/webp","video/mov","video/wmv","video/flv","video/avi"].includes(e.type)?e.size>t?{valid:!1,error:"File size should be less than ".concat(t/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},A={pdf:"pdf",msword:"msword",csv:"csv",plain:"plain","vnd.ms-excel":"vns.ms-excel"},C=function(e){return["image/png","image/jpg","image/jpeg","video/mp4","image/gif","text/plain","application/vnd.ms-excel","text/csv","application/msword","application/pdf","image/webp","video/mov","video/wmv","video/flv","video/avi","audio/mp3","audio/wav"].includes(e.type)?e.size>i.f?{valid:!1,error:"File size should be less than ".concat(i.f/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},k=function(e,t){var n;return function(){var r=this,o=arguments;clearTimeout(n),n=setTimeout((function(){return e.apply(r,o)}),t)}},M=function(e){return e.charAt(0)===e.charAt(0).toUpperCase()},O=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,n={opponentId:t},e.next=4,Object(o.default)().user.postUserBlock(n);case 4:return r=e.sent,e.abrupt("return",r);case 8:e.prev=8,e.t0=e.catch(0),console.error("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t){return e.apply(this,arguments)}}(),L=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,n={opponentId:t},e.next=4,Object(o.default)().user.postUserUnblock(n);case 4:return r=e.sent,e.abrupt("return",r);case 8:e.prev=8,e.t0=e.catch(0),console.log("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t){return e.apply(this,arguments)}}(),T=function(e){return"".concat(e.getHours()%12||12,":").concat(e.getMinutes().toString().padStart(2,"0")," ").concat(e.getHours()<12?"AM":"PM")},j=function(){var e=d(f().mark((function e(t,n){var r,i,s,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,r={conversationId:t,messageIds:n},e.next=4,Object(o.default)().message.deleteMessageSelf(r);case 4:return i=e.sent,e.abrupt("return",i);case 8:e.prev=8,e.t0=e.catch(0),a=JSON.parse(JSON.stringify({error:e.t0})),console.error("error",null==a||null===(s=a.error)||void 0===s?void 0:s.errorMsg);case 12:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t,n){return e.apply(this,arguments)}}(),x=function(){var e=d(f().mark((function e(t,n){var r,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,r={conversationId:t,messageIds:n},e.next=4,Object(o.default)().message.deleteMessagesEveryone(r);case 4:return i=e.sent,e.abrupt("return",i);case 8:e.prev=8,e.t0=e.catch(0),console.log("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t,n){return e.apply(this,arguments)}}(),R=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().message.postMessagesPresignedurls(t);case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),P=function(e){return["jpg","jpeg","png","gif","webp"].includes(e.toLowerCase())},N=function(e){return["mp4","mov","wmv","flv","avi"].includes(e.toLowerCase())};function D(e,t){for(var n=e.split(","),r=n[0].match(/:(.*?);/)[1],o=atob(n[1]),i=o.length,s=new Uint8Array(i);i--;)s[i]=o.charCodeAt(i);return new File([s],t,{type:r})}var U=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"DD/MM/YYYY",n=new Date(e),r=new Date,o=new Date(r);if(o.setDate(o.getDate()-1),n.toDateString()===r.toDateString()){var i=n.toLocaleTimeString([],{hour:"numeric",minute:"2-digit",hour12:!0}).toUpperCase();return i}if(n.toDateString()===o.toDateString())return"Yesterday";var s=n.getDate().toString().padStart(2,"0"),a=(n.getMonth()+1).toString().padStart(2,"0"),c=n.getFullYear().toString();return"MM/DD/YYYY"===t?a+"/"+s+"/"+c:s+"/"+a+"/"+c};function V(e){var t=new Date(e).getMonth(),n=new Date(e).getFullYear(),r=((new Date).getDate(),(new Date).getMonth());return n===(new Date).getFullYear()&&t===r?"THIS MONTH":new Date(e).toLocaleString("default",{month:"long"}).toUpperCase()}var F=[{id:0,title:"Camera",imageUrl:s.a},{id:1,title:"Document",imageUrl:c.a},{id:2,title:"Photos & Videos",imageUrl:a.a}],Y=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"DD/MM/YYYY",n=new Date,r=new Date(e),o=[r.getDate(),r.getMonth(),r.getFullYear()],i=o[0],s=o[1],a=o[2];return n.getDate()===i&&n.getMonth()===s&&n.getFullYear()===a?"Today":n.getDate()-1===i&&n.getMonth()===s&&n.getFullYear()===a?"Yesterday":"MM/DD/YYYY"===t?"".concat(String(s+1).padStart("2",0),"/").concat(String(i).padStart("2",0),"/").concat(a):"".concat(String(i).padStart("2",0),"/").concat(String(s+1).padStart("2",0),"/").concat(a)},B=function(t){try{return p.test(t)?e.from(t,"base64").toString():t}catch(e){return t}},G=function(e){return e<1024?e+" b":e<1048576?(e/1024).toFixed(2)+" KB":(e/1048576).toFixed(2)+" MB"},W=function(t){try{return e.from(t).toString("base64")}catch(e){return t}},Z=function(e){try{var t=Math.floor(e/60),n=e%60;return t<10&&(t="0".concat(t)),n<10&&(n="0".concat(n)),"".concat(t,":").concat(n)}catch(e){}},J=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"100vh",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if("undefined"==typeof window)return t;var r=e.reduce((function(e,t){if(t)return e+t.offsetHeight}),n);return r="calc(".concat(t," - ").concat(r,"px)")};function q(){return"undefined"!=typeof window}}).call(this,n(27).Buffer)},function(e,t,n){var r,o;
|
|
1
|
+
module.exports=function(e){function t(t){for(var n,o,i=t[0],s=t[1],a=0,u=[];a<i.length;a++)o=i[a],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&u.push(r[o][0]),r[o]=0;for(n in s)Object.prototype.hasOwnProperty.call(s,n)&&(e[n]=s[n]);for(c&&c(t);u.length;)u.shift()()}var n={},r={0:0};function o(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,o),r.l=!0,r.exports}o.e=function(e){var t=[],n=r[e];if(0!==n)if(n)t.push(n[2]);else{var i=new Promise((function(t,o){n=r[e]=[t,o]}));t.push(n[2]=i);var s,a=document.createElement("script");a.charset="utf-8",a.timeout=120,o.nc&&a.setAttribute("nonce",o.nc),a.src=function(e){return o.p+""+({1:"pages-WhatsappMainBox",2:"vendors~pages-WhatsappMainBox"}[e]||e)+".js"}(e);var c=new Error;s=function(t){a.onerror=a.onload=null,clearTimeout(u);var n=r[e];if(0!==n){if(n){var o=t&&("load"===t.type?"missing":t.type),i=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+o+": "+i+")",c.name="ChunkLoadError",c.type=o,c.request=i,n[1](c)}r[e]=void 0}};var u=setTimeout((function(){s({type:"timeout",target:a})}),12e4);a.onerror=a.onload=s,document.head.appendChild(a)}return Promise.all(t)},o.m=e,o.c=n,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)o.d(n,r,function(t){return e[t]}.bind(null,r));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o.oe=function(e){throw console.error(e),e};var i=window.__LOADABLE_LOADED_CHUNKS__=window.__LOADABLE_LOADED_CHUNKS__||[],s=i.push.bind(i);i.push=t,i=i.slice();for(var a=0;a<i.length;a++)t(i[a]);var c=s;return o(o.s=33)}([function(e,t){e.exports=require("react")},function(e,t,n){"use strict";n.r(t);var r=n(11);t.default=function(){return r.default.getInstance()}},function(e,t,n){"use strict";e.exports=n(31)},function(e,t,n){"use strict";n.d(t,"c",(function(){return i})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return c}));var r=n(7),o=n.n(r),i=function(e,t){o.a.set(e,t)},s=function(e){o.a.remove(e,{expires:1})},a=function(){s("isometrikToken"),s("isometrikUserId"),window.location.href="/"},c=function(e){return u(e)},u=function(e){return o.a.get(e)}},function(e,t,n){"use strict";n.d(t,"q",(function(){return r})),n.d(t,"p",(function(){return o})),n.d(t,"m",(function(){return i})),n.d(t,"e",(function(){return s})),n.d(t,"b",(function(){return a})),n.d(t,"o",(function(){return c})),n.d(t,"t",(function(){return u})),n.d(t,"c",(function(){return l})),n.d(t,"a",(function(){return f})),n.d(t,"k",(function(){return h})),n.d(t,"l",(function(){return d})),n.d(t,"r",(function(){return p})),n.d(t,"g",(function(){return v})),n.d(t,"h",(function(){return g})),n.d(t,"f",(function(){return m})),n.d(t,"j",(function(){return y})),n.d(t,"i",(function(){return b})),n.d(t,"s",(function(){return w})),n.d(t,"n",(function(){return _})),n.d(t,"d",(function(){return S}));var r=25,o=1e3,i=60*o,s=60*i,a=24*s,c=30*a,u=12*c,l="deleteConversationLocally",f="clearConversation",h="messageDelivered",d="messageRead",p="User unblocked successfully.",v=5242880,g=52428800,m=52428800,y="messagesDeleteLocal",b="messagesDeleteForAll",w="userUnblockConversation",_=420,S="AIzaSyCD81udOzPUpOi14ZEo-7GzPwnClTROIeQ"},function(e,t,n){"use strict";function r(){return(r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";(function(e){n.d(t,"q",(function(){return v})),n.d(t,"w",(function(){return g})),n.d(t,"x",(function(){return m})),n.d(t,"E",(function(){return y})),n.d(t,"s",(function(){return b})),n.d(t,"d",(function(){return w})),n.d(t,"i",(function(){return _})),n.d(t,"F",(function(){return S})),n.d(t,"b",(function(){return E})),n.d(t,"B",(function(){return I})),n.d(t,"G",(function(){return A})),n.d(t,"l",(function(){return C})),n.d(t,"g",(function(){return O})),n.d(t,"c",(function(){return M})),n.d(t,"C",(function(){return k})),n.d(t,"D",(function(){return L})),n.d(t,"v",(function(){return T})),n.d(t,"k",(function(){return j})),n.d(t,"j",(function(){return x})),n.d(t,"p",(function(){return R})),n.d(t,"z",(function(){return P})),n.d(t,"A",(function(){return N})),n.d(t,"f",(function(){return D})),n.d(t,"o",(function(){return U})),n.d(t,"u",(function(){return V})),n.d(t,"a",(function(){return F})),n.d(t,"t",(function(){return B})),n.d(t,"h",(function(){return Y})),n.d(t,"n",(function(){return G})),n.d(t,"m",(function(){return W})),n.d(t,"e",(function(){return Z})),n.d(t,"r",(function(){return J})),n.d(t,"y",(function(){return q}));var r=n(25),o=n(1),i=n(4),s=n(21),a=n(22),c=n(23),u=n(3);function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function f(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */f=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},s=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",c=i.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:O(e,n,a)}),s}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p="suspendedStart",v="executing",g="completed",m={};function y(){}function b(){}function w(){}var _={};u(_,s,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,s)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,i,s,a){var c=d(e[o],e,i);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==l(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(f).then((function(e){u.value=e,s(u)}),(function(e){return n("throw",e,s,a)}))}a(c.arg)}var i;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return i=i?i.then(o,o):o()}})}function O(t,n,r){var o=p;return function(i,s){if(o===v)throw new Error("Generator is already running");if(o===g){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===m)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===p)throw o=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=v;var u=d(t,n,r);if("normal"===u.type){if(o=r.done?g:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=g,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var i=d(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,m;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,m):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(l(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=u(w,c,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,u(e,c,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),u(C.prototype,a,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(h(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),u(I,c,"Generator"),u(I,s,(function(){return this})),u(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),m}},t}function h(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function d(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){h(i,r,o,s,a,"next",e)}function a(e){h(i,r,o,s,a,"throw",e)}s(void 0)}))}}var p=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,v=function(){var e=d(f().mark((function e(){var t,n,o,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(n=Object(u.b)("deviceId")||(null===(t=window)||void 0===t?void 0:t.deviceId))){e.next=3;break}return e.abrupt("return",n);case 3:return e.next=5,r.a.load();case 5:return o=e.sent,e.next=8,o.get();case 8:return i=e.sent,e.abrupt("return",i.visitorId);case 10:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),g=function(){var e=d(f().mark((function e(t){var n,r,i,s;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.id,r=t.includeConversationStatusMessagesInUnreadMessagesCount,e.prev=1,e.next=4,null===(i=Object(o.default)())||void 0===i||null===(i=i.Conversation)||void 0===i?void 0:i.getConversations({ids:n,includeConversationStatusMessagesInUnreadMessagesCount:r});case 4:return s=e.sent,e.abrupt("return",s.conversations[0]);case 8:e.prev=8,e.t0=e.catch(1),console.log(e.t0,"error");case 11:case"end":return e.stop()}}),e,null,[[1,8]])})));return function(t){return e.apply(this,arguments)}}(),m=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(o.default)().Conversation.getConversations(t&&{searchTag:t});case 3:return n=e.sent,e.abrupt("return",n);case 7:e.prev=7,e.t0=e.catch(0),console.log(e.t0,"error");case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t){return e.apply(this,arguments)}}(),y=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,null===(n=Object(o.default)())||void 0===n||null===(n=n.user)||void 0===n?void 0:n.getPresignedurlUpdate({mediaExtension:t});case 2:return r=e.sent,e.abrupt("return",r);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),b=function(){var e=d(f().mark((function e(t,n,r){var o;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch(t,{method:"PUT",body:n,headers:{"Content-Type":r}});case 2:return o=e.sent,e.abrupt("return",o);case 4:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),w=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().Conversation.deleteConversationLocal({conversationId:t});case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),_=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().Conversation.deleteConversationClear({conversationId:t});case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),S="https://chat-storage.isometrik.io/60b1ef70ffcf750001d0440d/fc4bfc08-3243-420f-884d-1ce37d3f453b/Users/643f9aec09b87e00014625d2_1682328163954.png",E=function(e){return["image/png","image/jpg","image/jpeg","image/webp"].includes(null==e?void 0:e.type)?(null==e?void 0:e.size)>i.g?{valid:!1,error:"File size should be less than ".concat(i.g/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},I=function(e){var t="mp4"===e.type.split("/")[1]?i.h:i.g;return["image/png","image/jpg","image/jpeg","video/mp4","image/gif","image/webp","video/mov","video/wmv","video/flv","video/avi"].includes(e.type)?e.size>t?{valid:!1,error:"File size should be less than ".concat(t/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},A={pdf:"pdf",msword:"msword",csv:"csv",plain:"plain","vnd.ms-excel":"vns.ms-excel"},C=function(e){return["image/png","image/jpg","image/jpeg","video/mp4","image/gif","text/plain","application/vnd.ms-excel","text/csv","application/msword","application/pdf","image/webp","video/mov","video/wmv","video/flv","video/avi","audio/mp3","audio/wav"].includes(e.type)?e.size>i.f?{valid:!1,error:"File size should be less than ".concat(i.f/1024/1024,"MB")}:{valid:!0}:{valid:!1,error:"Invalid file type"}},O=function(e,t){var n;return function(){var r=this,o=arguments;clearTimeout(n),n=setTimeout((function(){return e.apply(r,o)}),t)}},M=function(e){return e.charAt(0)===e.charAt(0).toUpperCase()},k=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,n={opponentId:t},e.next=4,Object(o.default)().user.postUserBlock(n);case 4:return r=e.sent,e.abrupt("return",r);case 8:e.prev=8,e.t0=e.catch(0),console.error("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t){return e.apply(this,arguments)}}(),L=function(){var e=d(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,n={opponentId:t},e.next=4,Object(o.default)().user.postUserUnblock(n);case 4:return r=e.sent,e.abrupt("return",r);case 8:e.prev=8,e.t0=e.catch(0),console.log("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t){return e.apply(this,arguments)}}(),T=function(e){return"".concat(e.getHours()%12||12,":").concat(e.getMinutes().toString().padStart(2,"0")," ").concat(e.getHours()<12?"AM":"PM")},j=function(){var e=d(f().mark((function e(t,n){var r,i,s,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,r={conversationId:t,messageIds:n},e.next=4,Object(o.default)().message.deleteMessageSelf(r);case 4:return i=e.sent,e.abrupt("return",i);case 8:e.prev=8,e.t0=e.catch(0),a=JSON.parse(JSON.stringify({error:e.t0})),console.error("error",null==a||null===(s=a.error)||void 0===s?void 0:s.errorMsg);case 12:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t,n){return e.apply(this,arguments)}}(),x=function(){var e=d(f().mark((function e(t,n){var r,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,r={conversationId:t,messageIds:n},e.next=4,Object(o.default)().message.deleteMessagesEveryone(r);case 4:return i=e.sent,e.abrupt("return",i);case 8:e.prev=8,e.t0=e.catch(0),console.log("error",e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t,n){return e.apply(this,arguments)}}(),R=function(){var e=d(f().mark((function e(t){var n;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(o.default)().message.postMessagesPresignedurls(t);case 2:return n=e.sent,e.abrupt("return",n);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),P=function(e){return["jpg","jpeg","png","gif","webp"].includes(e.toLowerCase())},N=function(e){return["mp4","mov","wmv","flv","avi"].includes(e.toLowerCase())};function D(e,t){for(var n=e.split(","),r=n[0].match(/:(.*?);/)[1],o=atob(n[1]),i=o.length,s=new Uint8Array(i);i--;)s[i]=o.charCodeAt(i);return new File([s],t,{type:r})}var U=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"DD/MM/YYYY",n=new Date(e),r=new Date,o=new Date(r);if(o.setDate(o.getDate()-1),n.toDateString()===r.toDateString()){var i=n.toLocaleTimeString([],{hour:"numeric",minute:"2-digit",hour12:!0}).toUpperCase();return i}if(n.toDateString()===o.toDateString())return"Yesterday";var s=n.getDate().toString().padStart(2,"0"),a=(n.getMonth()+1).toString().padStart(2,"0"),c=n.getFullYear().toString();return"MM/DD/YYYY"===t?a+"/"+s+"/"+c:s+"/"+a+"/"+c};function V(e){var t=new Date(e).getMonth(),n=new Date(e).getFullYear(),r=((new Date).getDate(),(new Date).getMonth());return n===(new Date).getFullYear()&&t===r?"THIS MONTH":new Date(e).toLocaleString("default",{month:"long"}).toUpperCase()}var F=[{id:0,title:"Camera",imageUrl:s.a},{id:1,title:"Document",imageUrl:c.a},{id:2,title:"Photos & Videos",imageUrl:a.a}],B=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"DD/MM/YYYY",n=new Date,r=new Date(e),o=[r.getDate(),r.getMonth(),r.getFullYear()],i=o[0],s=o[1],a=o[2];return n.getDate()===i&&n.getMonth()===s&&n.getFullYear()===a?"Today":n.getDate()-1===i&&n.getMonth()===s&&n.getFullYear()===a?"Yesterday":"MM/DD/YYYY"===t?"".concat(String(s+1).padStart("2",0),"/").concat(String(i).padStart("2",0),"/").concat(a):"".concat(String(i).padStart("2",0),"/").concat(String(s+1).padStart("2",0),"/").concat(a)},Y=function(t){try{return p.test(t)?e.from(t,"base64").toString():t}catch(e){return t}},G=function(e){return e<1024?e+" b":e<1048576?(e/1024).toFixed(2)+" KB":(e/1048576).toFixed(2)+" MB"},W=function(t){try{return e.from(t).toString("base64")}catch(e){return t}},Z=function(e){try{var t=Math.floor(e/60),n=e%60;return t<10&&(t="0".concat(t)),n<10&&(n="0".concat(n)),"".concat(t,":").concat(n)}catch(e){}},J=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"100vh",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if("undefined"==typeof window)return t;var r=e.reduce((function(e,t){if(t)return e+t.offsetHeight}),n);return r="calc(".concat(t," - ").concat(r,"px)")};function q(){return"undefined"!=typeof window}}).call(this,n(27).Buffer)},function(e,t,n){var r,o;
|
|
2
2
|
/*!
|
|
3
3
|
* JavaScript Cookie v2.2.1
|
|
4
4
|
* https://github.com/js-cookie/js-cookie
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2006, 2015 Klaus Hartl & Fagner Brack
|
|
7
7
|
* Released under the MIT license
|
|
8
|
-
*/!function(i){if(void 0===(o="function"==typeof(r=i)?r.call(t,n,t,e):r)||(e.exports=o),!0,e.exports=i(),!!0){var s=window.Cookies,a=window.Cookies=i();a.noConflict=function(){return window.Cookies=s,a}}}((function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function o(){}function i(t,n,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},o.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var s=JSON.stringify(n);/^[\{\[]/.test(s)&&(n=s)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var a="";for(var c in i)i[c]&&(a+="; "+c,!0!==i[c]&&(a+="="+i[c].split(";")[0]));return document.cookie=t+"="+n+a}}function s(e,n){if("undefined"!=typeof document){for(var o={},i=document.cookie?document.cookie.split("; "):[],s=0;s<i.length;s++){var a=i[s].split("="),c=a.slice(1).join("=");n||'"'!==c.charAt(0)||(c=c.slice(1,-1));try{var u=t(a[0]);if(c=(r.read||r)(c,u)||t(c),n)try{c=JSON.parse(c)}catch(e){}if(o[u]=c,e===u)break}catch(e){}}return e?o[e]:o}}return o.set=i,o.get=function(e){return s(e,!1)},o.getJSON=function(e){return s(e,!0)},o.remove=function(t,n){i(t,"",e(n,{expires:-1}))},o.defaults={},o.withConverter=n,o}((function(){}))}))},function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return S})),n.d(t,"b",(function(){return E}));var r=n(0),o=n(3),i=n(6),s=n(15),a=n(2);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var u=["children","emojiIcon","notiFicationIcon","attachFileIcon","sendIcon","recordIcon","dateFormat","sortByCustomType","auth","allowMediaDownload","showStatusMessages","hideHiddenConversations","renderCustomMessage","onMessage","onConversationRead","chatTheme","manageProfile","onViewProfilleClick","manageMessage","baseImageUrl","renderCustomMessageSendForm","renderCustomChatMessageHeader","renderCustomChatListTile","renderChatMediaContainer","renderLastMessage","renderDeleteDialog","renderChatListFilter","showChatListFilter","documentUploadHandlerRef","chatMessageAction","isometrikCreds","isGroup"];function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){h(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function h(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==c(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===c(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e){return function(e){if(Array.isArray(e))return g(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||v(e)||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.")}()}function p(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],c=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);c=!0);}catch(e){u=!0,o=e}finally{try{if(!c&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return a}}(e,t)||v(e,t)||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.")}()}function v(e,t){if(e){if("string"==typeof e)return g(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?g(e,t):void 0}}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */m=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},s=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{l({},"")}catch(e){l=function(e,t,n){return e[t]=n}}function f(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:k(e,n,a)}),s}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=f;var d="suspendedStart",p="executing",v="completed",g={};function y(){}function b(){}function w(){}var _={};l(_,s,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,s)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){l(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,i,s,a){var u=h(e[o],e,i);if("throw"!==u.type){var l=u.arg,f=l.value;return f&&"object"==c(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(f).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,a)}))}a(u.arg)}var i;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return i=i?i.then(o,o):o()}})}function k(t,n,r){var o=d;return function(i,s){if(o===p)throw new Error("Generator is already running");if(o===v){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===g)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===d)throw o=v,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=p;var u=h(t,n,r);if("normal"===u.type){if(o=r.done?v:"suspendedYield",u.arg===g)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=v,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var i=h(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,g;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(c(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=l(w,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,l(e,u,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),l(C.prototype,a,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(f(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),l(I,u,"Generator"),l(I,s,(function(){return this})),l(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,g):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),g},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}function y(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function b(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){y(i,r,o,s,a,"next",e)}function a(e){y(i,r,o,s,a,"throw",e)}s(void 0)}))}}function w(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var _=Object(r.createContext)(),S=function(e){var t=e.children,c=e.emojiIcon,l=e.notiFicationIcon,v=e.attachFileIcon,g=e.sendIcon,y=e.recordIcon,S=e.dateFormat,E=void 0===S?"DD/MM/YYYY":S,I=e.sortByCustomType,A=void 0!==I&&I,C=e.auth,k=e.allowMediaDownload,M=e.showStatusMessages,O=void 0===M||M,L=e.hideHiddenConversations,T=void 0!==L&&L,j=e.renderCustomMessage,x=void 0===j?null:j,R=e.onMessage,P=void 0===R?function(){}:R,N=e.onConversationRead,D=void 0===N?function(){}:N,U=e.chatTheme,V=void 0===U?"light":U,F=e.manageProfile,Y=e.onViewProfilleClick,B=void 0===Y?function(){}:Y,G=e.manageMessage,W=e.baseImageUrl,Z=void 0===W?null:W,J=e.renderCustomMessageSendForm,q=void 0===J?null:J,z=e.renderCustomChatMessageHeader,H=void 0===z?null:z,X=e.renderCustomChatListTile,K=void 0===X?null:X,Q=e.renderChatMediaContainer,$=e.renderLastMessage,ee=e.renderDeleteDialog,te=e.renderChatListFilter,ne=e.showChatListFilter,re=void 0===ne||ne,oe=e.documentUploadHandlerRef,ie=e.chatMessageAction,se=e.isometrikCreds,ae=void 0===se?{}:se,ce=e.isGroup,ue=void 0!==ce&&ce,le=(w(e,u),Object(r.useRef)(!1)),fe=function(){var e=b(m().mark((function e(){var t,r;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.resolve().then(n.bind(null,11));case 2:t=e.sent.default,console.log("initttt mqtt"),r=Object(o.b)("isometrikToken"),t.initializeInstance({baseUrl:ae.baseUrl||"https://apis.isometrik.io",licenseKey:ae.licenseKey||"lic-IMKdwqAmUJGARMalVE3APneqSnEYreBqZfu",appSecret:ae.appSecret||"SFMyNTY.g3QAAAACZAAEZGF0YXQAAAADbQAAAAlhY2NvdW50SWRtAAAAGDY0M2VhMjk0MjBhYWY1MDAwMTA3MGFjN20AAAAIa2V5c2V0SWRtAAAAJDc1NzhmYjcxLWQyNjItNGMyZi1iNGRjLWNkMGMwNzQ5MDRhOG0AAAAJcHJvamVjdElkbQAAACQwNTg0Mzg0Zi0xOWJhLTRiODAtOWQyNS00NzQ1MDljZWIxZTdkAAZzaWduZWRuBgAQIq-UhwE.p_NXSuYWmYotKpLG733Ivi4_yVTDASNeHfLTXLxqD6g",userSecret:ae.userSecret||"SFMyNTY.g3QAAAACZAAEZGF0YXQAAAADbQAAAAlhY2NvdW50SWRtAAAAGDY0M2VhMjk0MjBhYWY1MDAwMTA3MGFjN20AAAAIa2V5c2V0SWRtAAAAJDc1NzhmYjcxLWQyNjItNGMyZi1iNGRjLWNkMGMwNzQ5MDRhOG0AAAAJcHJvamVjdElkbQAAACQwNTg0Mzg0Zi0xOWJhLTRiODAtOWQyNS00NzQ1MDljZWIxZTdkAAZzaWduZWRuBgAbIq-UhwE.5f_HqpUseV-zNWY3Bq0FKnpj2z6TVBmkHOx1gLxP3kY",userToken:ae.userToken||r}),le.current=!0;case 7:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();ae&&!le.current&&Object(i.y)()&&fe();Object(r.useRef)();var he=p(Object(r.useState)("dark"===V),2),de=he[0],pe=he[1],ve=p(Object(r.useState)(!0),2),ge=ve[0],me=ve[1],ye=p(Object(r.useState)(!1),2),be=ye[0],we=ye[1],_e=p(Object(r.useState)(),2),Se=_e[0],Ee=_e[1],Ie=p(Object(r.useState)(),2),Ae=Ie[0],Ce=Ie[1],ke=p(Object(r.useState)(!0),2),Me=ke[0],Oe=ke[1],Le=p(Object(r.useState)(!1),2),Te=Le[0],je=Le[1],xe=p(Object(r.useState)({}),2),Re=xe[0],Pe=xe[1],Ne=p(Object(r.useState)(),2),De=Ne[0],Ue=Ne[1],Ve=p(Object(r.useState)("ALL"),2),Fe=Ve[0],Ye=Ve[1],Be=p(Object(r.useState)({selectedConvId:"",messages:{},conversations:[],users:[]}),2),Ge=Be[0],We=Be[1],Ze=Object(o.b)("isometrikUserId");Object(r.useEffect)((function(){be&&qe(),C&&Je()}),[be,C]),Object(r.useEffect)((function(){Object(o.c)("theme","dark"===V);var e=Object(o.b)("theme");pe("true"===e)}),[V]);var Je=function(){var e=b(m().mark((function e(){var t,r,i;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Promise.resolve().then(n.bind(null,1));case 3:t=e.sent.default,(r=Object(o.b)("isometrikToken"))?(null===(i=t())||void 0===i||null===(i=i.user)||void 0===i||i.setUserToken(r),we(!0)):we(!1),me(!1),r&&t().user.getUserDetails().then((function(e){Ce(e)})),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(0),console.log("Errrroorrr -- ",e.t0);case 13:case"end":return e.stop()}}),e,null,[[0,10]])})));return function(){return e.apply(this,arguments)}}(),qe=function(){var e=b(m().mark((function e(){var t,r,s,a;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(i.q)();case 2:return t=e.sent,r=Object(o.b)("isometrikUserId"),e.next=6,Promise.resolve().then(n.bind(null,1));case 6:s=e.sent.default,console.log("clienttttttttttttt",s),console.log(r,t,ae,"mqtt connecting"),(a=s().initializeMqtt({hostUri:"wss://connections.isometrik.io:2053/mqtt",clientId:r,licenseKey:ae.licenseKey,projectId:ae.projectId,keysetId:ae.keysetId,accountId:ae.accountId,deviceId:t},(function(){Object(o.c)("chatMqttConnected","true")}))).on("MESSAGE_RECEIVED",function(){var e=b(m().mark((function e(t){var n,r,i,a;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(i=JSON.parse(null==t?void 0:t.payloadString),console.log("APPmessage",i,Ae),a=Object(o.b)("isometrikUserId"),"conversationCreated"!==(null==i?void 0:i.action)){e.next=15;break}return e.prev=4,e.next=7,s().Conversation.putConversationLastread({conversationId:null==i?void 0:i.conversationId,timestamp:Date.now()});case 7:Pe(i),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),Pe(i);case 13:e.next=16;break;case 15:"conversationDetailsUpdated"===(null==i?void 0:i.action)||"userBlockConversation"===(null==i?void 0:i.action)||"userUnblockConversation"===(null==i?void 0:i.action)||"messageDetailsUpdated"===(null==i?void 0:i.action)?(We((function(e){var t=e.conversations?d(e.conversations):[],n=t.findIndex((function(e){return e.conversationId===i.conversationId}));return-1!==n?(console.log(null==i?void 0:i.action,"message?.action"),"userBlockConversation"===(null==i?void 0:i.action)&&t.splice(n,1,f(f({},t[n]),{},{messagingDisabled:!0,updateBlockStatus:Date.now(),lastMessageDetails:f({},i)})),"userUnblockConversation"===(null==i?void 0:i.action)&&t.splice(n,1,f(f({},t[n]),{},{messagingDisabled:!1,updateBlockStatus:Date.now(),lastMessageDetails:f({},i)})),null!=i&&i.details&&t.splice(n,1,f(f(f({},t[n]),i.details),{},{lastMessageDetails:f({},i)})),f(f({},e),{},{conversations:t})):e})),null!=i&&i.details&&Pe(i)):Pe(i);case 16:"undefined"!=typeof window&&(null==i||null===(n=i.body)||void 0===n?void 0:n.length)>0&&(null==i?void 0:i.conversationId)!==(null===(r=window.location.search.split("="))||void 0===r?void 0:r[1])&&i.senderId!==a&&(s().message.putIndicateDelivered({messageId:i.messageId,conversationId:i.conversationId}),P(i,{state:Ge,setState:We})),We((function(e){if(null!=e&&e.messages&&Object.keys(null==e?void 0:e.messages).includes(null==i?void 0:i.conversationId)){var t;if((null==i||null===(t=i.body)||void 0===t?void 0:t.length)>0)return f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,[].concat(d(null==e?void 0:e.messages[null==i?void 0:i.conversationId]),[i])))});console.log(i,e.messages[null==i?void 0:i.conversationId]);var n=d(null==e?void 0:e.messages[null==i?void 0:i.conversationId]);return"multipleMessagesRead"!==(null==i?void 0:i.action)&&"messageRead"!==(null==i?void 0:i.action)||(n=n.map((function(e){if(e.userId!==e.senderId){var t=f({},e);return t.readBy=[{userId:i.userId,timestamp:i.lastReadAt}],t.readByAll=!0,t}return e}))),"messageDelivered"===(null==i?void 0:i.action)&&(n=n.map((function(e){if(e.userId!==e.senderId){var t=f({},e);return t.deliveredTo=[{userId:i.userId,timestamp:i.lastReadAt}],t.deliveredToAll=!0,t}return e}))),"messageDetailsUpdated"===(null==i?void 0:i.action)&&(n=n.map((function(e){if(i.messageId===e.messageId){var t=f(f({},e),i.details);return console.log("message details updated",i,e,t),t}return e}))),f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,d(n)))})}return f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,[i]))})}));case 18:case"end":return e.stop()}}),e,null,[[4,10]])})));return function(t){return e.apply(this,arguments)}}()),"undefined"!=typeof window&&(window.isoChatClient=a);case 12:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return Object(r.useEffect)((function(){var e;if(Object.keys(Re).length&&Re.body&&(null==Re?void 0:Re.senderId)!==Ze){var t="You have received a new message from ".concat(Re.senderName),n="".concat(null===(e=Object(i.h)(Re.body))||void 0===e?void 0:e.replace(/<br \/>/g,"")),r=l||s.a;try{!function(e,t,n){var r;null===(r=navigator)||void 0===r||null===(r=r.serviceWorker)||void 0===r||null===(r=r.ready)||void 0===r||null===(r=r.then((function(r){r.showNotification(e,{body:t,icon:n})})))||void 0===r||r.catch((function(e){return console.log("error while pushing notifications using sw - ",e)}))}(t,n,r)}catch(e){console.log("notify failed")}}}),[Re.body,l]),Object(r.useEffect)((function(){Object(o.c)("theme",de)}),[de]),Object(a.jsx)(_.Provider,{value:{theme:de,emojiIcon:c,attachFileIcon:v,sendIcon:g,recordIcon:y,dateFormat:E,showStatusMessages:O,hideHiddenConversations:T,sortByCustomType:A,allowMediaDownload:k,sidebarChatItem:Se,setSidebarChatItem:Ee,renderCustomMessage:x,onMessage:P,onConversationRead:D,onViewProfilleClick:B,fetchUserToken:Je,baseImageUrl:Z,manageProfile:F,manageMessage:G,setTheme:pe,isometrikCreds:ae,setLoading:me,loading:ge,setUserloggedIn:we,userloggedIn:be,setUserDetails:Ce,userDetails:Ae,setShowLoader:Oe,showLoader:Me,userId:Ze,findUserId:Re,setFindUserId:Pe,setState:We,currFilter:De,setCurrFilter:Ue,currChat:Fe,setCurrChat:Ye,setIsSearchLoading:je,isSearchLoading:Te,state:Ge,renderCustomMessageSendForm:q,renderCustomChatMessageHeader:H,renderCustomChatListTile:K,renderChatMediaContainer:Q,renderDeleteDialog:ee,renderChatListFilter:te,renderLastMessage:$,showChatListFilter:re,documentUploadHandlerRef:oe,chatMessageAction:ie,isGroup:ue},children:t})},E=function(){return Object(r.useContext)(_)}},function(e,t,n){"use strict";e.exports=n(32)},function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return L}));var r=n(19),o=n.n(r),i=n(20),s=n.n(i);function a(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,u(e,t)}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t,n){return(l=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}()?Reflect.construct.bind():function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&u(o,n.prototype),o}).apply(null,arguments)}function f(e){var t="function"==typeof Map?new Map:void 0;return(f=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return l(e,arguments,c(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),u(n,e)})(e)}function h(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var d=function(e){function t(n,r){var o;return(o=e.call(this,r)||this).statusCode=void 0,Object.setPrototypeOf(h(o),(this instanceof t?this.constructor:void 0).prototype),o.name=Error.name,o.statusCode=n,Error.captureStackTrace(h(o)),o}return a(t,e),t}(f(Error)),p=function(e){function t(t,n){var r;return(r=e.call(this,400,"Conversation not found or not allowed to fetch messages count")||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n||0,r}return a(t,e),t}(d),v=function(e){function t(t,n){var r;return(r=e.call(this,404,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),g=function(e){function t(t){var n;return(n=e.call(this,503,"Service Unavailable")||this).errorMsg=void 0,n.errorMsg=t,n}return a(t,e),t}(d),m=function(e){function t(t,n){var r;return(r=e.call(this,422,"Unprocessable entity")||this).errorProperties=void 0,r.errorCode=void 0,r.errorProperties=t,r.errorCode=n||0,r}return a(t,e),t}(d),y=function(e){function t(t,n){var r;return(r=e.call(this,t,"Unknown Error Caught")||this).errorMsg=void 0,r.errorMsg=n,r}return a(t,e),t}(d),b=function(e){function t(t,n){var r;return(r=e.call(this,403,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),w=function(e){function t(t,n){var r;return(r=e.call(this,403,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),_=function(e){function t(t,n){var r;return(r=e.call(this,400,"Conversation not found or not allowed to fetch messages count")||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n||0,r}return a(t,e),t}(d),S=function(){function e(e){this.baseUrl=void 0,this.licenseKey=void 0,this.appSecret=void 0,this.userSecret=void 0,this.userToken=void 0,this.baseUrl=e.baseUrl,this.licenseKey=e.licenseKey,this.appSecret=e.appSecret,this.userSecret=e.userSecret,this.userToken=e.userToken||void 0}var t=e.prototype;return t.updateUserToken=function(e){this.userToken=e},t.invoke=function(e,t){try{return Promise.resolve(function(n,r){try{var i=Promise.resolve(o()(e,t)).then((function(e){if(e.ok)return e.json();var t=new Error(e.statusText);throw t.response=e,t}))}catch(e){return r(e)}return i&&i.then?i.then(void 0,r):i}(0,(function(e){var t=e.response.status;return Promise.resolve(e.response.json()).then((function(e){switch(t){case 400:throw new p(e.error);case 401:throw new w(e.error,e.errorCode);case 403:throw new b(e.error,e.errorCode);case 404:throw new v(e.error,e.errorCode);case 409:throw new _(e.error,e.errorCode);case 422:throw new m(e.errors);case 503:throw new g(e.error);default:throw new y(t,e.error)}}))})))}catch(e){return Promise.reject(e)}},t.get=function(e,t){void 0===t&&(t=!1);var n=""+this.baseUrl+e,r={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};return t&&(r.userSecret=this.userSecret),this.invoke(n,{headers:r})},t.post=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"POST",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.put=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"PUT",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.patch=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"PATCH",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.delete=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"DELETE",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},e}(),E="chat/messages",I=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getMessagesForUser=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/user?"+t)},t.getMessagesForMentioned=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/user?"+t)},t.getMessagesCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/count?"+t)},t.getMessages=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"?"+t)},t.postMessages=function(e){return this.base.post("/chat/message",e)},t.patchMessages=function(e){return this.base.patch("/chat/message",e)},t.postMessagesPresignedurls=function(e){return this.base.post("/chat/messages/presignedurls",e)},t.getMessageReactionType=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/"+t+"?"+n)},t.postReaction=function(e){return this.base.post("/chat/reaction",e)},t.deleteReactionType=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/reaction/"+t+"?"+n)},t.postMessagesForward=function(e){return this.base.post("/chat/message/forward",e)},t.postMessagesbroadcast=function(e){return this.base.post("/chat/message/broadcast",e)},t.getStatus=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/status?"+t)},t.getStatusReadPending=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/read/pending?"+t)},t.getStatusRead=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/read?"+t)},t.getStatusDeliveryPending=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/delivery/pending?"+t)},t.getStatusDelivery=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/delivery?"+t)},t.postIndicateTyping=function(e){return this.base.post("/chat/indicator/typing",e)},t.putIndicateRead=function(e){return this.base.put("/chat/indicator/read",e)},t.putIndicateDelivered=function(e){return this.base.put("/chat/indicator/delivered",e)},t.getUnreadCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/unread/count?"+t)},t.getUnread=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/unread?"+t)},t.putRead=function(e){return this.base.put("/"+E+"/read",e)},t.deleteMessageSelf=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/"+E+"/self?"+t)},t.deleteMessagesEveryone=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/"+E+"/everyone?"+t)},e}(),A="chat/conversations",C=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getWatchers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/watchers?"+t)},t.getPublicOrOpen=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/watchers?"+t)},t.getConversationDetails=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/details/"+t+"?"+n)},t.getConversationCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/count?"+t)},t.getConversations=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"?"+t)},t.getUnreadConversations=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/unread?"+t)},t.getMessagingStatus=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/messaging/status?"+t)},t.postConversation=function(e){return this.base.post("/chat/conversation",e)},t.patchTitle=function(e){return this.base.patch("/chat/conversation/title",e)},t.patchSettings=function(e){return this.base.patch("/chat/conversation/settings",e)},t.patchImage=function(e){return this.base.patch("/chat/conversation/image",e)},t.patchDetails=function(e){return this.base.patch("/chat/conversation/details",e)},t.getConversationPresignedurl=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/presignedurl?"+t)},t.getStatusRead=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/status/read?"+t)},t.getObserver=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/members?"+t)},t.deleteObserverLeave=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/observer/leave?"+t)},t.putObserverJoin=function(e){return this.base.put("/chat/conversation/observer/join",e)},t.putMembers=function(e){return this.base.put("/chat/conversation/members",e)},t.getConversationMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/members?"+t)},t.deleteConversationMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/members?"+t)},t.getConversationMemberDetails=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/member/details?"+t)},t.getConversationEligibleMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/eligible/members?"+t)},t.deleteConversationLeave=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/leave?"+t)},t.putConversationJoin=function(e){return this.base.put("/chat/conversation/join",e)},t.putConversationAdmin=function(e){return this.base.put("/chat/conversation/admin",e)},t.deleteConversationAdmin=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/admin?"+t)},t.getConversationUnreadCount=function(){return this.base.get("/"+A+"/unread/count")},t.putConversationLastread=function(e){return this.base.put("/chat/conversation/lastread",e)},t.deleteConversationClear=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/local?"+t)},t.deleteConversationLocal=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/clear?"+t)},e}(),k=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getUsers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/users?"+t,!0)},t.getUserDetails=function(){return this.base.get("/chat/user/details")},t.postUserAuthenticate=function(e){var t=this,n=this.base.post("/chat/user/authenticate",e,!0);return n.then((function(e){t.base.updateUserToken(e.userToken)})),n},t.setUserToken=function(e){this.base.updateUserToken(e)},t.postUser=function(e){return this.base.post("/chat/user",e,!0)},t.patchUser=function(e){return this.base.patch("/chat/user",e)},t.deleteUser=function(){return this.base.delete("/chat/user")},t.postUserUnblock=function(e){return this.base.post("/chat/user/unblock",e)},t.getUserNonblock=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/nonblock?"+t)},t.getUserblockCount=function(){return this.base.get("/chat/user/block/count")},t.postUserBlock=function(e){return this.base.post("/chat/user/block",e)},t.getUserBlock=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/block?"+t)},t.getPresignedurlUpdate=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/presignedurl/update?"+t)},t.getPresignedurlCreate=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/presignedurl/update?"+t)},e}(),M=function(){function e(e){var t=this;this.hostUri=void 0,this.clientId=void 0,this.client=void 0,this.licenseKey=void 0,this.projectId=void 0,this.keysetId=void 0,this.accountId=void 0,this.deviceId=void 0,this.hostUri=e.hostUri,this.clientId=e.clientId,this.deviceId=e.deviceId,this.licenseKey=e.licenseKey,this.projectId=e.projectId,this.keysetId=e.keysetId,this.accountId=e.accountId,this.client=new s.a.Client(this.hostUri,this.clientId+this.deviceId),this.client.connect({userName:"2"+this.accountId+this.projectId,password:this.licenseKey+this.keysetId,useSSL:!0,mqttVersion:3,keepAliveInterval:30,cleanSession:!0,reconnect:!0,onFailure:function(e){console.log("Failed COnnection ---\x3e",e,"is the error"),console.log(t,"username","1"+t.accountId+t.projectId,"pass",t.licenseKey+t.keysetId)},onSuccess:function(e){console.log("Isometrick MQTT Connected !!",t.client);try{t.client.subscribe("/"+t.accountId+"/"+t.projectId+"/Message/"+t.clientId,{qos:0,onSuccess:function(e){console.log("Subscribed Successfully:: =>> Message",e)},onFailure:function(e){console.log("Subscribed Failed || >>",e)}}),t.client.subscribe("/"+t.accountId+"/"+t.projectId+"/Status/"+t.clientId,{qos:0,onSuccess:function(e){console.log("Subscribed Successfully:: =>> Status",e)},onFailure:function(e){console.log("Subscribed Failed || >>",e)}})}catch(e){console.error(e)}}})}var t=e.prototype;return t.on=function(e,t){switch(e){case"MESSAGE_RECEIVED":this.client.onMessageArrived=t;break;case"CONNECTION_LOST":this.client.onConnectionLost=t}},t.disconnect=function(){this.client.disconnect()},t.getInstance=function(){return this.client},e}(),O={BadRequestError:p,ConflictError:_,ForbiddenErrorRequest:b,NotFoundError:v,ServiceUnavailableError:g,UnauthorizedError:w,UnknownError:y,UnprocessableEntityError:m},L=function(){function e(e){this.message=void 0,this.Conversation=void 0,this.user=void 0,this.error=void 0,this.message=new I(e),this.Conversation=new C(e),this.user=new k(e),this.error=O}return e.getInstance=function(){if(null!==e.instance)return e.instance;throw new Error("Need to initialize instance first!")},e.initializeInstance=function(t){return null===e.instance&&(e.instance=new e(t)),e.instance},e.prototype.initializeMqtt=function(e){return new M(e)},e}();L.instance=null},function(e,t,n){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,"a",(function(){return r}))},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";var r=n(10),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},s={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};function c(e){return r.isMemo(e)?s:a[e.$$typeof]||o}a[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},a[r.Memo]=s;var u=Object.defineProperty,l=Object.getOwnPropertyNames,f=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var o=d(n);o&&o!==p&&e(t,o,r)}var s=l(n);f&&(s=s.concat(f(n)));for(var a=c(t),v=c(n),g=0;g<s.length;++g){var m=s[g];if(!(i[m]||r&&r[m]||v&&v[m]||a&&a[m])){var y=h(n,m);try{u(t,m,y)}catch(e){}}}}return t}},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/arrow_logo.svg"},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function o(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)}n.d(t,"a",(function(){return o}))},function(e,t,n){"use strict";n.r(t),t.default=function(e,t){return t=t||{},new Promise((function(n,r){var o=new XMLHttpRequest,i=[],s=[],a={},c=function(){return{ok:2==(o.status/100|0),statusText:o.statusText,status:o.status,url:o.responseURL,text:function(){return Promise.resolve(o.responseText)},json:function(){return Promise.resolve(o.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([o.response]))},clone:c,headers:{keys:function(){return i},entries:function(){return s},get:function(e){return a[e.toLowerCase()]},has:function(e){return e.toLowerCase()in a}}}};for(var u in o.open(t.method||"get",e,!0),o.onload=function(){o.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,t,n){i.push(t=t.toLowerCase()),s.push([t,n]),a[t]=a[t]?a[t]+","+n:n})),n(c())},o.onerror=r,o.withCredentials="include"==t.credentials,t.headers)o.setRequestHeader(u,t.headers[u]);o.send(t.body||null)}))}},function(e,t,n){"use strict";var r=n(0),o=n.n(r),i=n(24),s=n(2),a=n.n(s),c=Object(i.a)({resolved:{},chunkName:function(){return"pages-WhatsappMainBox"},isReady:function(e){var t=this.resolve(e);return!0===this.resolved[t]&&!!n.m[t]},importAsync:function(){return Promise.all([n.e(2),n.e(1)]).then(n.bind(null,26))},requireAsync:function(e){var t=this,n=this.resolve(e);return this.resolved[n]=!1,this.importAsync(e).then((function(e){return t.resolved[n]=!0,e}))},requireSync:function e(t){var r=this.resolve(t);return n(r)},resolve:function e(){return 26}}),u=function(e){var t=e.showSideBarSearch,n=void 0===t||t,r=e.attachMentPosition,o=void 0===r?"right":r,i=e.sortConversationList,a=e.renderSelfMoremenu,u=e.showSearchIcon,l=void 0===u||u,f=e.ChatFooterRightSlot,h=void 0===f?function(){return Object(s.jsx)(s.Fragment,{})}:f,d=e.customSendOptions,p=void 0!==d&&d,v=e.RenderCustomSendOptions,g=void 0===v?function(){return Object(s.jsx)(s.Fragment,{})}:v,m=e.showSideChatHeader,y=e.extraAttachmentOptions,b=void 0===y?[]:y,w=e.renderProfileBadge,_=void 0===w?function(e){return Object(s.jsx)(s.Fragment,{})}:w,S=e.customSend,E=void 0!==S&&S,I=e.handleCustomSend,A=void 0===I?function(){return!1}:I,C=e.sideBarHeaderSlot,k=e.chatHeaderRightSlot,M=e.chatHeaderMoreMenu,O=e.onChatChange,L=e.placeHolder,T=e.sideBarPlaceHolder,j=e.allowProfileClick,x=void 0===j||j,R=e.onNewConversation;return Object(s.jsx)(s.Fragment,{children:Object(s.jsx)("div",{className:"isoChat",children:Object(s.jsx)(c,{onNewConversation:R,showSideBarSearch:n,allowProfileClick:x,sortConversationList:i,renderSelfMoremenu:a,showSearchIcon:l,attachMentPosition:o,ChatFooterRightSlot:h,customSendOptions:p,RenderCustomSendOptions:g,extraAttachmentOptions:b,customSend:E,renderProfileBadge:_,handleCustomSend:A,sideBarHeaderSlot:C,chatHeaderRightSlot:k,chatHeaderMoreMenu:M,sideBarPlaceHolder:T,showSideChatHeader:m,onChatChange:O,placeHolder:L})})})};t.a=u},function(e,t,n){e.exports=self.fetch||(self.fetch=n(17).default||n(17))},function(e,t,n){(function(t){var n;n=function(){return function(e){var t,n=e.localStorage||(t={},{setItem:function(e,n){t[e]=n},getItem:function(e){return t[e]},removeItem:function(e){delete t[e]}}),r=1,o=2,i=3,s=4,a=5,c=6,u=7,l=8,f=9,h=10,d=11,p=12,v=13,g=14,m=function(e,t){for(var n in e)if(e.hasOwnProperty(n)){if(!t.hasOwnProperty(n)){var r="Unknown property, "+n+". Valid properties are:";for(var o in t)t.hasOwnProperty(o)&&(r=r+" "+o);throw new Error(r)}if(typeof e[n]!==t[n])throw new Error(_(b.INVALID_TYPE,[typeof e[n],n]))}},y=function(e,t){return function(){return e.apply(t,arguments)}},b={OK:{code:0,text:"AMQJSC0000I OK."},CONNECT_TIMEOUT:{code:1,text:"AMQJSC0001E Connect timed out."},SUBSCRIBE_TIMEOUT:{code:2,text:"AMQJS0002E Subscribe timed out."},UNSUBSCRIBE_TIMEOUT:{code:3,text:"AMQJS0003E Unsubscribe timed out."},PING_TIMEOUT:{code:4,text:"AMQJS0004E Ping timed out."},INTERNAL_ERROR:{code:5,text:"AMQJS0005E Internal error. Error Message: {0}, Stack trace: {1}"},CONNACK_RETURNCODE:{code:6,text:"AMQJS0006E Bad Connack return code:{0} {1}."},SOCKET_ERROR:{code:7,text:"AMQJS0007E Socket error:{0}."},SOCKET_CLOSE:{code:8,text:"AMQJS0008I Socket closed."},MALFORMED_UTF:{code:9,text:"AMQJS0009E Malformed UTF data:{0} {1} {2}."},UNSUPPORTED:{code:10,text:"AMQJS0010E {0} is not supported by this browser."},INVALID_STATE:{code:11,text:"AMQJS0011E Invalid state {0}."},INVALID_TYPE:{code:12,text:"AMQJS0012E Invalid type {0} for {1}."},INVALID_ARGUMENT:{code:13,text:"AMQJS0013E Invalid argument {0} for {1}."},UNSUPPORTED_OPERATION:{code:14,text:"AMQJS0014E Unsupported operation."},INVALID_STORED_DATA:{code:15,text:"AMQJS0015E Invalid data in local storage key={0} value={1}."},INVALID_MQTT_MESSAGE_TYPE:{code:16,text:"AMQJS0016E Invalid MQTT message type {0}."},MALFORMED_UNICODE:{code:17,text:"AMQJS0017E Malformed Unicode string:{0} {1}."},BUFFER_FULL:{code:18,text:"AMQJS0018E Message buffer is full, maximum buffer size: {0}."}},w={0:"Connection Accepted",1:"Connection Refused: unacceptable protocol version",2:"Connection Refused: identifier rejected",3:"Connection Refused: server unavailable",4:"Connection Refused: bad user name or password",5:"Connection Refused: not authorized"},_=function(e,t){var n=e.text;if(t)for(var r,o,i=0;i<t.length;i++)if(r="{"+i+"}",(o=n.indexOf(r))>0){var s=n.substring(0,o),a=n.substring(o+r.length);n=s+t[i]+a}return n},S=[0,6,77,81,73,115,100,112,3],E=[0,4,77,81,84,84,4],I=function(e,t){for(var n in this.type=e,t)t.hasOwnProperty(n)&&(this[n]=t[n])};function A(e,t){var n,r=t,l=e[t],h=l>>4,p=l&=15;t+=1;var v=0,g=1;do{if(t==e.length)return[null,r];v+=(127&(n=e[t++]))*g,g*=128}while(0!=(128&n));var m=t+v;if(m>e.length)return[null,r];var y=new I(h);switch(h){case o:1&e[t++]&&(y.sessionPresent=!0),y.returnCode=e[t++];break;case i:var b=p>>1&3,w=M(e,t),_=T(e,t+=2,w);t+=w,b>0&&(y.messageIdentifier=M(e,t),t+=2);var S=new P(e.subarray(t,m));1==(1&p)&&(S.retained=!0),8==(8&p)&&(S.duplicate=!0),S.qos=b,S.destinationName=_,y.payloadMessage=S;break;case s:case a:case c:case u:case d:y.messageIdentifier=M(e,t);break;case f:y.messageIdentifier=M(e,t),t+=2,y.returnCode=e.subarray(t,m)}return[y,m]}function C(e,t,n){return t[n++]=e>>8,t[n++]=e%256,n}function k(e,t,n,r){return L(e,n,r=C(t,n,r)),r+t}function M(e,t){return 256*e[t]+e[t+1]}function O(e){for(var t=0,n=0;n<e.length;n++){var r=e.charCodeAt(n);r>2047?(55296<=r&&r<=56319&&(n++,t++),t+=3):r>127?t+=2:t++}return t}function L(e,t,n){for(var r=n,o=0;o<e.length;o++){var i=e.charCodeAt(o);if(55296<=i&&i<=56319){var s=e.charCodeAt(++o);if(isNaN(s))throw new Error(_(b.MALFORMED_UNICODE,[i,s]));i=s-56320+(i-55296<<10)+65536}i<=127?t[r++]=i:i<=2047?(t[r++]=i>>6&31|192,t[r++]=63&i|128):i<=65535?(t[r++]=i>>12&15|224,t[r++]=i>>6&63|128,t[r++]=63&i|128):(t[r++]=i>>18&7|240,t[r++]=i>>12&63|128,t[r++]=i>>6&63|128,t[r++]=63&i|128)}return t}function T(e,t,n){for(var r,o="",i=t;i<t+n;){var s=e[i++];if(s<128)r=s;else{var a=e[i++]-128;if(a<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),""]));if(s<224)r=64*(s-192)+a;else{var c=e[i++]-128;if(c<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16)]));if(s<240)r=4096*(s-224)+64*a+c;else{var u=e[i++]-128;if(u<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16),u.toString(16)]));if(!(s<248))throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16),u.toString(16)]));r=262144*(s-240)+4096*a+64*c+u}}}r>65535&&(r-=65536,o+=String.fromCharCode(55296+(r>>10)),r=56320+(1023&r)),o+=String.fromCharCode(r)}return o}I.prototype.encode=function(){var e,t=(15&this.type)<<4,n=0,o=[],s=0;switch(void 0!==this.messageIdentifier&&(n+=2),this.type){case r:switch(this.mqttVersion){case 3:n+=S.length+3;break;case 4:n+=E.length+3}n+=O(this.clientId)+2,void 0!==this.willMessage&&(n+=O(this.willMessage.destinationName)+2,(e=this.willMessage.payloadBytes)instanceof Uint8Array||(e=new Uint8Array(u)),n+=e.byteLength+2),void 0!==this.userName&&(n+=O(this.userName)+2),void 0!==this.password&&(n+=O(this.password)+2);break;case l:t|=2;for(var a=0;a<this.topics.length;a++)o[a]=O(this.topics[a]),n+=o[a]+2;n+=this.requestedQos.length;break;case h:for(t|=2,a=0;a<this.topics.length;a++)o[a]=O(this.topics[a]),n+=o[a]+2;break;case c:t|=2;break;case i:this.payloadMessage.duplicate&&(t|=8),t=t|=this.payloadMessage.qos<<1,this.payloadMessage.retained&&(t|=1),n+=(s=O(this.payloadMessage.destinationName))+2;var u=this.payloadMessage.payloadBytes;n+=u.byteLength,u instanceof ArrayBuffer?u=new Uint8Array(u):u instanceof Uint8Array||(u=new Uint8Array(u.buffer))}var f=function(e){var t=new Array(1),n=0;do{var r=e%128;(e>>=7)>0&&(r|=128),t[n++]=r}while(e>0&&n<4);return t}(n),d=f.length+1,p=new ArrayBuffer(n+d),v=new Uint8Array(p);if(v[0]=t,v.set(f,1),this.type==i)d=k(this.payloadMessage.destinationName,s,v,d);else if(this.type==r){switch(this.mqttVersion){case 3:v.set(S,d),d+=S.length;break;case 4:v.set(E,d),d+=E.length}var g=0;this.cleanSession&&(g=2),void 0!==this.willMessage&&(g|=4,g|=this.willMessage.qos<<3,this.willMessage.retained&&(g|=32)),void 0!==this.userName&&(g|=128),void 0!==this.password&&(g|=64),v[d++]=g,d=C(this.keepAliveInterval,v,d)}switch(void 0!==this.messageIdentifier&&(d=C(this.messageIdentifier,v,d)),this.type){case r:d=k(this.clientId,O(this.clientId),v,d),void 0!==this.willMessage&&(d=k(this.willMessage.destinationName,O(this.willMessage.destinationName),v,d),d=C(e.byteLength,v,d),v.set(e,d),d+=e.byteLength),void 0!==this.userName&&(d=k(this.userName,O(this.userName),v,d)),void 0!==this.password&&(d=k(this.password,O(this.password),v,d));break;case i:v.set(u,d);break;case l:for(a=0;a<this.topics.length;a++)d=k(this.topics[a],o[a],v,d),v[d++]=this.requestedQos[a];break;case h:for(a=0;a<this.topics.length;a++)d=k(this.topics[a],o[a],v,d)}return p};var j=function(e,t){this._client=e,this._keepAliveInterval=1e3*t,this.isReset=!1;var n=new I(p).encode(),r=function(e){return function(){return o.apply(e)}},o=function(){this.isReset?(this.isReset=!1,this._client._trace("Pinger.doPing","send PINGREQ"),this._client.socket.send(n),this.timeout=setTimeout(r(this),this._keepAliveInterval)):(this._client._trace("Pinger.doPing","Timed out"),this._client._disconnected(b.PING_TIMEOUT.code,_(b.PING_TIMEOUT)))};this.reset=function(){this.isReset=!0,clearTimeout(this.timeout),this._keepAliveInterval>0&&(this.timeout=setTimeout(r(this),this._keepAliveInterval))},this.cancel=function(){clearTimeout(this.timeout)}},x=function(e,t,n,r){t||(t=30),this.timeout=setTimeout(function(e,t,n){return function(){return e.apply(t,n)}}(n,e,r),1e3*t),this.cancel=function(){clearTimeout(this.timeout)}},R=function(t,r,o,i,s){if(!("WebSocket"in e)||null===e.WebSocket)throw new Error(_(b.UNSUPPORTED,["WebSocket"]));if(!("ArrayBuffer"in e)||null===e.ArrayBuffer)throw new Error(_(b.UNSUPPORTED,["ArrayBuffer"]));for(var a in this._trace("Paho.Client",t,r,o,i,s),this.host=r,this.port=o,this.path=i,this.uri=t,this.clientId=s,this._wsuri=null,this._localKey=r+":"+o+("/mqtt"!=i?":"+i:"")+":"+s+":",this._msg_queue=[],this._buffered_msg_queue=[],this._sentMessages={},this._receivedMessages={},this._notify_msg_sent={},this._message_identifier=1,this._sequence=0,n)0!==a.indexOf("Sent:"+this._localKey)&&0!==a.indexOf("Received:"+this._localKey)||this.restore(a)};R.prototype.host=null,R.prototype.port=null,R.prototype.path=null,R.prototype.uri=null,R.prototype.clientId=null,R.prototype.socket=null,R.prototype.connected=!1,R.prototype.maxMessageIdentifier=65536,R.prototype.connectOptions=null,R.prototype.hostIndex=null,R.prototype.onConnected=null,R.prototype.onConnectionLost=null,R.prototype.onMessageDelivered=null,R.prototype.onMessageArrived=null,R.prototype.traceFunction=null,R.prototype._msg_queue=null,R.prototype._buffered_msg_queue=null,R.prototype._connectTimeout=null,R.prototype.sendPinger=null,R.prototype.receivePinger=null,R.prototype._reconnectInterval=1,R.prototype._reconnecting=!1,R.prototype._reconnectTimeout=null,R.prototype.disconnectedPublishing=!1,R.prototype.disconnectedBufferSize=5e3,R.prototype.receiveBuffer=null,R.prototype._traceBuffer=null,R.prototype._MAX_TRACE_ENTRIES=100,R.prototype.connect=function(e){var t=this._traceMask(e,"password");if(this._trace("Client.connect",t,this.socket,this.connected),this.connected)throw new Error(_(b.INVALID_STATE,["already connected"]));if(this.socket)throw new Error(_(b.INVALID_STATE,["already connected"]));this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),this.connectOptions=e,this._reconnectInterval=1,this._reconnecting=!1,e.uris?(this.hostIndex=0,this._doConnect(e.uris[0])):this._doConnect(this.uri)},R.prototype.subscribe=function(e,t){if(this._trace("Client.subscribe",e,t),!this.connected)throw new Error(_(b.INVALID_STATE,["not connected"]));var n=new I(l);n.topics=e.constructor===Array?e:[e],void 0===t.qos&&(t.qos=0),n.requestedQos=[];for(var r=0;r<n.topics.length;r++)n.requestedQos[r]=t.qos;t.onSuccess&&(n.onSuccess=function(e){t.onSuccess({invocationContext:t.invocationContext,grantedQos:e})}),t.onFailure&&(n.onFailure=function(e){t.onFailure({invocationContext:t.invocationContext,errorCode:e,errorMessage:_(e)})}),t.timeout&&(n.timeOut=new x(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:b.SUBSCRIBE_TIMEOUT.code,errorMessage:_(b.SUBSCRIBE_TIMEOUT)}])),this._requires_ack(n),this._schedule_message(n)},R.prototype.unsubscribe=function(e,t){if(this._trace("Client.unsubscribe",e,t),!this.connected)throw new Error(_(b.INVALID_STATE,["not connected"]));var n=new I(h);n.topics=e.constructor===Array?e:[e],t.onSuccess&&(n.callback=function(){t.onSuccess({invocationContext:t.invocationContext})}),t.timeout&&(n.timeOut=new x(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:b.UNSUBSCRIBE_TIMEOUT.code,errorMessage:_(b.UNSUBSCRIBE_TIMEOUT)}])),this._requires_ack(n),this._schedule_message(n)},R.prototype.send=function(e){this._trace("Client.send",e);var t=new I(i);if(t.payloadMessage=e,this.connected)e.qos>0?this._requires_ack(t):this.onMessageDelivered&&(this._notify_msg_sent[t]=this.onMessageDelivered(t.payloadMessage)),this._schedule_message(t);else{if(!this._reconnecting||!this.disconnectedPublishing)throw new Error(_(b.INVALID_STATE,["not connected"]));if(Object.keys(this._sentMessages).length+this._buffered_msg_queue.length>this.disconnectedBufferSize)throw new Error(_(b.BUFFER_FULL,[this.disconnectedBufferSize]));e.qos>0?this._requires_ack(t):(t.sequence=++this._sequence,this._buffered_msg_queue.unshift(t))}},R.prototype.disconnect=function(){if(this._trace("Client.disconnect"),this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),!this.socket)throw new Error(_(b.INVALID_STATE,["not connecting or connected"]));var e=new I(g);this._notify_msg_sent[e]=y(this._disconnected,this),this._schedule_message(e)},R.prototype.getTraceLog=function(){if(null!==this._traceBuffer){for(var e in this._trace("Client.getTraceLog",new Date),this._trace("Client.getTraceLog in flight messages",this._sentMessages.length),this._sentMessages)this._trace("_sentMessages ",e,this._sentMessages[e]);for(var e in this._receivedMessages)this._trace("_receivedMessages ",e,this._receivedMessages[e]);return this._traceBuffer}},R.prototype.startTrace=function(){null===this._traceBuffer&&(this._traceBuffer=[]),this._trace("Client.startTrace",new Date,"@VERSION@-@BUILDLEVEL@")},R.prototype.stopTrace=function(){delete this._traceBuffer},R.prototype._doConnect=function(e){if(this.connectOptions.useSSL){var t=e.split(":");t[0]="wss",e=t.join(":")}this._wsuri=e,this.connected=!1,this.connectOptions.mqttVersion<4?this.socket=new WebSocket(e,["mqttv3.1"]):this.socket=new WebSocket(e,["mqtt"]),this.socket.binaryType="arraybuffer",this.socket.onopen=y(this._on_socket_open,this),this.socket.onmessage=y(this._on_socket_message,this),this.socket.onerror=y(this._on_socket_error,this),this.socket.onclose=y(this._on_socket_close,this),this.sendPinger=new j(this,this.connectOptions.keepAliveInterval),this.receivePinger=new j(this,this.connectOptions.keepAliveInterval),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._connectTimeout=new x(this,this.connectOptions.timeout,this._disconnected,[b.CONNECT_TIMEOUT.code,_(b.CONNECT_TIMEOUT)])},R.prototype._schedule_message=function(e){this._msg_queue.unshift(e),this.connected&&this._process_queue()},R.prototype.store=function(e,t){var r={type:t.type,messageIdentifier:t.messageIdentifier,version:1};switch(t.type){case i:t.pubRecReceived&&(r.pubRecReceived=!0),r.payloadMessage={};for(var o="",s=t.payloadMessage.payloadBytes,a=0;a<s.length;a++)s[a]<=15?o=o+"0"+s[a].toString(16):o+=s[a].toString(16);r.payloadMessage.payloadHex=o,r.payloadMessage.qos=t.payloadMessage.qos,r.payloadMessage.destinationName=t.payloadMessage.destinationName,t.payloadMessage.duplicate&&(r.payloadMessage.duplicate=!0),t.payloadMessage.retained&&(r.payloadMessage.retained=!0),0===e.indexOf("Sent:")&&(void 0===t.sequence&&(t.sequence=++this._sequence),r.sequence=t.sequence);break;default:throw Error(_(b.INVALID_STORED_DATA,[e+this._localKey+t.messageIdentifier,r]))}n.setItem(e+this._localKey+t.messageIdentifier,JSON.stringify(r))},R.prototype.restore=function(e){var t=n.getItem(e),r=JSON.parse(t),o=new I(r.type,r);switch(r.type){case i:for(var s=r.payloadMessage.payloadHex,a=new ArrayBuffer(s.length/2),c=new Uint8Array(a),u=0;s.length>=2;){var l=parseInt(s.substring(0,2),16);s=s.substring(2,s.length),c[u++]=l}var f=new P(c);f.qos=r.payloadMessage.qos,f.destinationName=r.payloadMessage.destinationName,r.payloadMessage.duplicate&&(f.duplicate=!0),r.payloadMessage.retained&&(f.retained=!0),o.payloadMessage=f;break;default:throw Error(_(b.INVALID_STORED_DATA,[e,t]))}0===e.indexOf("Sent:"+this._localKey)?(o.payloadMessage.duplicate=!0,this._sentMessages[o.messageIdentifier]=o):0===e.indexOf("Received:"+this._localKey)&&(this._receivedMessages[o.messageIdentifier]=o)},R.prototype._process_queue=function(){for(var e=null;e=this._msg_queue.pop();)this._socket_send(e),this._notify_msg_sent[e]&&(this._notify_msg_sent[e](),delete this._notify_msg_sent[e])},R.prototype._requires_ack=function(e){var t=Object.keys(this._sentMessages).length;if(t>this.maxMessageIdentifier)throw Error("Too many messages:"+t);for(;void 0!==this._sentMessages[this._message_identifier];)this._message_identifier++;e.messageIdentifier=this._message_identifier,this._sentMessages[e.messageIdentifier]=e,e.type===i&&this.store("Sent:",e),this._message_identifier===this.maxMessageIdentifier&&(this._message_identifier=1)},R.prototype._on_socket_open=function(){var e=new I(r,this.connectOptions);e.clientId=this.clientId,this._socket_send(e)},R.prototype._on_socket_message=function(e){this._trace("Client._on_socket_message",e.data);for(var t=this._deframeMessages(e.data),n=0;n<t.length;n+=1)this._handleMessage(t[n])},R.prototype._deframeMessages=function(e){var t=new Uint8Array(e),n=[];if(this.receiveBuffer){var r=new Uint8Array(this.receiveBuffer.length+t.length);r.set(this.receiveBuffer),r.set(t,this.receiveBuffer.length),t=r,delete this.receiveBuffer}try{for(var o=0;o<t.length;){var i=A(t,o),s=i[0];if(o=i[1],null===s)break;n.push(s)}o<t.length&&(this.receiveBuffer=t.subarray(o))}catch(e){var a="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(b.INTERNAL_ERROR.code,_(b.INTERNAL_ERROR,[e.message,a]))}return n},R.prototype._handleMessage=function(e){this._trace("Client._handleMessage",e);try{switch(e.type){case o:if(this._connectTimeout.cancel(),this._reconnectTimeout&&this._reconnectTimeout.cancel(),this.connectOptions.cleanSession){for(var t in this._sentMessages){var r=this._sentMessages[t];n.removeItem("Sent:"+this._localKey+r.messageIdentifier)}for(var t in this._sentMessages={},this._receivedMessages){var l=this._receivedMessages[t];n.removeItem("Received:"+this._localKey+l.messageIdentifier)}this._receivedMessages={}}if(0!==e.returnCode){this._disconnected(b.CONNACK_RETURNCODE.code,_(b.CONNACK_RETURNCODE,[e.returnCode,w[e.returnCode]]));break}this.connected=!0,this.connectOptions.uris&&(this.hostIndex=this.connectOptions.uris.length);var h=[];for(var p in this._sentMessages)this._sentMessages.hasOwnProperty(p)&&h.push(this._sentMessages[p]);if(this._buffered_msg_queue.length>0)for(var m=null;m=this._buffered_msg_queue.pop();)h.push(m),this.onMessageDelivered&&(this._notify_msg_sent[m]=this.onMessageDelivered(m.payloadMessage));h=h.sort((function(e,t){return e.sequence-t.sequence}));for(var y=0,S=h.length;y<S;y++)if((r=h[y]).type==i&&r.pubRecReceived){var E=new I(c,{messageIdentifier:r.messageIdentifier});this._schedule_message(E)}else this._schedule_message(r);this.connectOptions.onSuccess&&this.connectOptions.onSuccess({invocationContext:this.connectOptions.invocationContext});var A=!1;this._reconnecting&&(A=!0,this._reconnectInterval=1,this._reconnecting=!1),this._connected(A,this._wsuri),this._process_queue();break;case i:this._receivePublish(e);break;case s:(r=this._sentMessages[e.messageIdentifier])&&(delete this._sentMessages[e.messageIdentifier],n.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(r.payloadMessage));break;case a:(r=this._sentMessages[e.messageIdentifier])&&(r.pubRecReceived=!0,E=new I(c,{messageIdentifier:e.messageIdentifier}),this.store("Sent:",r),this._schedule_message(E));break;case c:l=this._receivedMessages[e.messageIdentifier],n.removeItem("Received:"+this._localKey+e.messageIdentifier),l&&(this._receiveMessage(l),delete this._receivedMessages[e.messageIdentifier]);var C=new I(u,{messageIdentifier:e.messageIdentifier});this._schedule_message(C);break;case u:r=this._sentMessages[e.messageIdentifier],delete this._sentMessages[e.messageIdentifier],n.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(r.payloadMessage);break;case f:(r=this._sentMessages[e.messageIdentifier])&&(r.timeOut&&r.timeOut.cancel(),128===e.returnCode[0]?r.onFailure&&r.onFailure(e.returnCode):r.onSuccess&&r.onSuccess(e.returnCode),delete this._sentMessages[e.messageIdentifier]);break;case d:(r=this._sentMessages[e.messageIdentifier])&&(r.timeOut&&r.timeOut.cancel(),r.callback&&r.callback(),delete this._sentMessages[e.messageIdentifier]);break;case v:this.sendPinger.reset();break;case g:this._disconnected(b.INVALID_MQTT_MESSAGE_TYPE.code,_(b.INVALID_MQTT_MESSAGE_TYPE,[e.type]));break;default:this._disconnected(b.INVALID_MQTT_MESSAGE_TYPE.code,_(b.INVALID_MQTT_MESSAGE_TYPE,[e.type]))}}catch(e){var k="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(b.INTERNAL_ERROR.code,_(b.INTERNAL_ERROR,[e.message,k]))}},R.prototype._on_socket_error=function(e){this._reconnecting||this._disconnected(b.SOCKET_ERROR.code,_(b.SOCKET_ERROR,[e.data]))},R.prototype._on_socket_close=function(){this._reconnecting||this._disconnected(b.SOCKET_CLOSE.code,_(b.SOCKET_CLOSE))},R.prototype._socket_send=function(e){if(1==e.type){var t=this._traceMask(e,"password");this._trace("Client._socket_send",t)}else this._trace("Client._socket_send",e);this.socket.send(e.encode()),this.sendPinger.reset()},R.prototype._receivePublish=function(e){switch(e.payloadMessage.qos){case"undefined":case 0:this._receiveMessage(e);break;case 1:var t=new I(s,{messageIdentifier:e.messageIdentifier});this._schedule_message(t),this._receiveMessage(e);break;case 2:this._receivedMessages[e.messageIdentifier]=e,this.store("Received:",e);var n=new I(a,{messageIdentifier:e.messageIdentifier});this._schedule_message(n);break;default:throw Error("Invaild qos="+e.payloadMessage.qos)}},R.prototype._receiveMessage=function(e){this.onMessageArrived&&this.onMessageArrived(e.payloadMessage)},R.prototype._connected=function(e,t){this.onConnected&&this.onConnected(e,t)},R.prototype._reconnect=function(){this._trace("Client._reconnect"),this.connected||(this._reconnecting=!0,this.sendPinger.cancel(),this.receivePinger.cancel(),this._reconnectInterval<128&&(this._reconnectInterval=2*this._reconnectInterval),this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri))},R.prototype._disconnected=function(e,t){if(this._trace("Client._disconnected",e,t),void 0!==e&&this._reconnecting)this._reconnectTimeout=new x(this,this._reconnectInterval,this._reconnect);else if(this.sendPinger.cancel(),this.receivePinger.cancel(),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._msg_queue=[],this._buffered_msg_queue=[],this._notify_msg_sent={},this.socket&&(this.socket.onopen=null,this.socket.onmessage=null,this.socket.onerror=null,this.socket.onclose=null,1===this.socket.readyState&&this.socket.close(),delete this.socket),this.connectOptions.uris&&this.hostIndex<this.connectOptions.uris.length-1)this.hostIndex++,this._doConnect(this.connectOptions.uris[this.hostIndex]);else if(void 0===e&&(e=b.OK.code,t=_(b.OK)),this.connected){if(this.connected=!1,this.onConnectionLost&&this.onConnectionLost({errorCode:e,errorMessage:t,reconnect:this.connectOptions.reconnect,uri:this._wsuri}),e!==b.OK.code&&this.connectOptions.reconnect)return this._reconnectInterval=1,void this._reconnect()}else 4===this.connectOptions.mqttVersion&&!1===this.connectOptions.mqttVersionExplicit?(this._trace("Failed to connect V4, dropping back to V3"),this.connectOptions.mqttVersion=3,this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri)):this.connectOptions.onFailure&&this.connectOptions.onFailure({invocationContext:this.connectOptions.invocationContext,errorCode:e,errorMessage:t})},R.prototype._trace=function(){if(this.traceFunction){var e=Array.prototype.slice.call(arguments);for(var t in e)void 0!==e[t]&&e.splice(t,1,JSON.stringify(e[t]));var n=e.join("");this.traceFunction({severity:"Debug",message:n})}if(null!==this._traceBuffer){t=0;for(var r=arguments.length;t<r;t++)this._traceBuffer.length==this._MAX_TRACE_ENTRIES&&this._traceBuffer.shift(),0===t||void 0===arguments[t]?this._traceBuffer.push(arguments[t]):this._traceBuffer.push(" "+JSON.stringify(arguments[t]))}},R.prototype._traceMask=function(e,t){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]=r==t?"******":e[r]);return n};var P=function(e){var t,n;if(!("string"==typeof e||e instanceof ArrayBuffer||ArrayBuffer.isView(e)&&!(e instanceof DataView)))throw _(b.INVALID_ARGUMENT,[e,"newPayload"]);t=e;var r=0,o=!1,i=!1;Object.defineProperties(this,{payloadString:{enumerable:!0,get:function(){return"string"==typeof t?t:T(t,0,t.length)}},payloadBytes:{enumerable:!0,get:function(){if("string"==typeof t){var e=new ArrayBuffer(O(t)),n=new Uint8Array(e);return L(t,n,0),n}return t}},destinationName:{enumerable:!0,get:function(){return n},set:function(e){if("string"!=typeof e)throw new Error(_(b.INVALID_ARGUMENT,[e,"newDestinationName"]));n=e}},qos:{enumerable:!0,get:function(){return r},set:function(e){if(0!==e&&1!==e&&2!==e)throw new Error("Invalid argument:"+e);r=e}},retained:{enumerable:!0,get:function(){return o},set:function(e){if("boolean"!=typeof e)throw new Error(_(b.INVALID_ARGUMENT,[e,"newRetained"]));o=e}},topic:{enumerable:!0,get:function(){return n},set:function(e){n=e}},duplicate:{enumerable:!0,get:function(){return i},set:function(e){i=e}}})};return{Client:function(e,t,n,r){var o;if("string"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"host"]));if(2==arguments.length){r=t;var i=(o=e).match(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/);if(!i)throw new Error(_(b.INVALID_ARGUMENT,[e,"host"]));e=i[4]||i[2],t=parseInt(i[7]),n=i[8]}else{if(3==arguments.length&&(r=n,n="/mqtt"),"number"!=typeof t||t<0)throw new Error(_(b.INVALID_TYPE,[typeof t,"port"]));if("string"!=typeof n)throw new Error(_(b.INVALID_TYPE,[typeof n,"path"]));var s=-1!==e.indexOf(":")&&"["!==e.slice(0,1)&&"]"!==e.slice(-1);o="ws://"+(s?"["+e+"]":e)+":"+t+n}for(var a=0,c=0;c<r.length;c++){var u=r.charCodeAt(c);55296<=u&&u<=56319&&c++,a++}if("string"!=typeof r||a>65535)throw new Error(_(b.INVALID_ARGUMENT,[r,"clientId"]));var l=new R(o,e,t,n,r);Object.defineProperties(this,{host:{get:function(){return e},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},port:{get:function(){return t},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},path:{get:function(){return n},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},uri:{get:function(){return o},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},clientId:{get:function(){return l.clientId},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},onConnected:{get:function(){return l.onConnected},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onConnected"]));l.onConnected=e}},disconnectedPublishing:{get:function(){return l.disconnectedPublishing},set:function(e){l.disconnectedPublishing=e}},disconnectedBufferSize:{get:function(){return l.disconnectedBufferSize},set:function(e){l.disconnectedBufferSize=e}},onConnectionLost:{get:function(){return l.onConnectionLost},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onConnectionLost"]));l.onConnectionLost=e}},onMessageDelivered:{get:function(){return l.onMessageDelivered},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onMessageDelivered"]));l.onMessageDelivered=e}},onMessageArrived:{get:function(){return l.onMessageArrived},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onMessageArrived"]));l.onMessageArrived=e}},trace:{get:function(){return l.traceFunction},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onTrace"]));l.traceFunction=e}}}),this.connect=function(e){if(m(e=e||{},{timeout:"number",userName:"string",password:"string",willMessage:"object",keepAliveInterval:"number",cleanSession:"boolean",useSSL:"boolean",invocationContext:"object",onSuccess:"function",onFailure:"function",hosts:"object",ports:"object",reconnect:"boolean",mqttVersion:"number",mqttVersionExplicit:"boolean",uris:"object"}),void 0===e.keepAliveInterval&&(e.keepAliveInterval=60),e.mqttVersion>4||e.mqttVersion<3)throw new Error(_(b.INVALID_ARGUMENT,[e.mqttVersion,"connectOptions.mqttVersion"]));if(void 0===e.mqttVersion?(e.mqttVersionExplicit=!1,e.mqttVersion=4):e.mqttVersionExplicit=!0,void 0!==e.password&&void 0===e.userName)throw new Error(_(b.INVALID_ARGUMENT,[e.password,"connectOptions.password"]));if(e.willMessage){if(!(e.willMessage instanceof P))throw new Error(_(b.INVALID_TYPE,[e.willMessage,"connectOptions.willMessage"]));if(e.willMessage.stringPayload=null,void 0===e.willMessage.destinationName)throw new Error(_(b.INVALID_TYPE,[typeof e.willMessage.destinationName,"connectOptions.willMessage.destinationName"]))}if(void 0===e.cleanSession&&(e.cleanSession=!0),e.hosts){if(!(e.hosts instanceof Array))throw new Error(_(b.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));if(e.hosts.length<1)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));for(var t=!1,r=0;r<e.hosts.length;r++){if("string"!=typeof e.hosts[r])throw new Error(_(b.INVALID_TYPE,[typeof e.hosts[r],"connectOptions.hosts["+r+"]"]));if(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/.test(e.hosts[r])){if(0===r)t=!0;else if(!t)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}else if(t)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}if(t)e.uris=e.hosts;else{if(!e.ports)throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(!(e.ports instanceof Array))throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(e.hosts.length!==e.ports.length)throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));for(e.uris=[],r=0;r<e.hosts.length;r++){if("number"!=typeof e.ports[r]||e.ports[r]<0)throw new Error(_(b.INVALID_TYPE,[typeof e.ports[r],"connectOptions.ports["+r+"]"]));var i=e.hosts[r],s=e.ports[r],a=-1!==i.indexOf(":");o="ws://"+(a?"["+i+"]":i)+":"+s+n,e.uris.push(o)}}}l.connect(e)},this.subscribe=function(e,t){if("string"!=typeof e&&e.constructor!==Array)throw new Error("Invalid argument:"+e);if(m(t=t||{},{qos:"number",invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("subscribeOptions.timeout specified with no onFailure callback.");if(void 0!==t.qos&&0!==t.qos&&1!==t.qos&&2!==t.qos)throw new Error(_(b.INVALID_ARGUMENT,[t.qos,"subscribeOptions.qos"]));l.subscribe(e,t)},this.unsubscribe=function(e,t){if("string"!=typeof e&&e.constructor!==Array)throw new Error("Invalid argument:"+e);if(m(t=t||{},{invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("unsubscribeOptions.timeout specified with no onFailure callback.");l.unsubscribe(e,t)},this.send=function(e,t,n,r){var o;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof P)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(o=e).destinationName)throw new Error(_(b.INVALID_ARGUMENT,[o.destinationName,"Message.destinationName"]));l.send(o)}else(o=new P(t)).destinationName=e,arguments.length>=3&&(o.qos=n),arguments.length>=4&&(o.retained=r),l.send(o)},this.publish=function(e,t,n,r){var o;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof P)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(o=e).destinationName)throw new Error(_(b.INVALID_ARGUMENT,[o.destinationName,"Message.destinationName"]));l.send(o)}else(o=new P(t)).destinationName=e,arguments.length>=3&&(o.qos=n),arguments.length>=4&&(o.retained=r),l.send(o)},this.disconnect=function(){l.disconnect()},this.getTraceLog=function(){return l.getTraceLog()},this.startTrace=function(){l.startTrace()},this.stopTrace=function(){l.stopTrace()},this.isConnected=function(){return l.connected}},Message:P}}(void 0!==t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},e.exports=n()}).call(this,n(13))},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/camera.svg"},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/gallery.svg"},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/sticker.svg"},function(e,t,n){"use strict";var r=n(0),o=n.n(r),i=n(8),s=n(5),a=n(12),c=n(16),u=n(10),l=n(14),f=n.n(l);function h(e,t){if(!e){var n=new Error("loadable: "+t);throw n.framesToPop=1,n.name="Invariant Violation",n}}var d=o.a.createContext();var p={initialChunks:{}};var v=function(e){return e};function g(e){var t=e.defaultResolveComponent,n=void 0===t?v:t,r=e.render,l=e.onLoad;function g(e,t){void 0===t&&(t={});var v=function(e){return"function"==typeof e?{requireAsync:e,resolve:function(){},chunkName:function(){}}:e}(e),g={};function m(e){return t.cacheKey?t.cacheKey(e):v.resolve?v.resolve(e):"static"}function y(e,r,o){var i=t.resolveComponent?t.resolveComponent(e,r):n(e);if(t.resolveComponent&&!Object(u.isValidElementType)(i))throw new Error("resolveComponent returned something that is not a React component!");return f()(o,i,{preload:!0}),i}var b,w,_=function(e){var t=m(e),n=g[t];return n&&"REJECTED"!==n.status||((n=v.requireAsync(e)).status="PENDING",g[t]=n,n.then((function(){n.status="RESOLVED"}),(function(t){console.error("loadable-components: failed to asynchronously load component",{fileName:v.resolve(e),chunkName:v.chunkName(e),error:t?t.message:t}),n.status="REJECTED"}))),n},S=function(e){function n(n){var r;return(r=e.call(this,n)||this).state={result:null,error:null,loading:!0,cacheKey:m(n)},h(!n.__chunkExtractor||v.requireSync,"SSR requires `@loadable/babel-plugin`, please install it"),n.__chunkExtractor?(!1===t.ssr||(v.requireAsync(n).catch((function(){return null})),r.loadSync(),n.__chunkExtractor.addChunk(v.chunkName(n))),Object(a.a)(r)):(!1!==t.ssr&&(v.isReady&&v.isReady(n)||v.chunkName&&p.initialChunks[v.chunkName(n)])&&r.loadSync(),r)}Object(c.a)(n,e),n.getDerivedStateFromProps=function(e,t){var n=m(e);return Object(s.a)({},t,{cacheKey:n,loading:t.loading||t.cacheKey!==n})};var o=n.prototype;return o.componentDidMount=function(){this.mounted=!0;var e=this.getCache();e&&"REJECTED"===e.status&&this.setCache(),this.state.loading&&this.loadAsync()},o.componentDidUpdate=function(e,t){t.cacheKey!==this.state.cacheKey&&this.loadAsync()},o.componentWillUnmount=function(){this.mounted=!1},o.safeSetState=function(e,t){this.mounted&&this.setState(e,t)},o.getCacheKey=function(){return m(this.props)},o.getCache=function(){return g[this.getCacheKey()]},o.setCache=function(e){void 0===e&&(e=void 0),g[this.getCacheKey()]=e},o.triggerOnLoad=function(){var e=this;l&&setTimeout((function(){l(e.state.result,e.props)}))},o.loadSync=function(){if(this.state.loading)try{var e=y(v.requireSync(this.props),this.props,I);this.state.result=e,this.state.loading=!1}catch(e){console.error("loadable-components: failed to synchronously load component, which expected to be available",{fileName:v.resolve(this.props),chunkName:v.chunkName(this.props),error:e?e.message:e}),this.state.error=e}},o.loadAsync=function(){var e=this,t=this.resolveAsync();return t.then((function(t){var n=y(t,e.props,I);e.safeSetState({result:n,loading:!1},(function(){return e.triggerOnLoad()}))})).catch((function(t){return e.safeSetState({error:t,loading:!1})})),t},o.resolveAsync=function(){var e=this.props,t=(e.__chunkExtractor,e.forwardedRef,Object(i.a)(e,["__chunkExtractor","forwardedRef"]));return _(t)},o.render=function(){var e=this.props,n=e.forwardedRef,o=e.fallback,a=(e.__chunkExtractor,Object(i.a)(e,["forwardedRef","fallback","__chunkExtractor"])),c=this.state,u=c.error,l=c.loading,f=c.result;if(t.suspense&&"PENDING"===(this.getCache()||this.loadAsync()).status)throw this.loadAsync();if(u)throw u;var h=o||t.fallback||null;return l?h:r({fallback:h,result:f,options:t,props:Object(s.a)({},a,{ref:n})})},n}(o.a.Component),E=(w=function(e){return o.a.createElement(d.Consumer,null,(function(t){return o.a.createElement(b,Object.assign({__chunkExtractor:t},e))}))},(b=S).displayName&&(w.displayName=b.displayName+"WithChunkExtractor"),w),I=o.a.forwardRef((function(e,t){return o.a.createElement(E,Object.assign({forwardedRef:t},e))}));return I.displayName="Loadable",I.preload=function(e){I.load(e)},I.load=function(e){return _(e)},I}return{loadable:g,lazy:function(e,t){return g(e,Object(s.a)({},t,{suspense:!0}))}}}var m=g({defaultResolveComponent:function(e){return e.__esModule?e.default:e.default||e},render:function(e){var t=e.result,n=e.props;return o.a.createElement(t,n)}}),y=m.loadable,b=m.lazy,w=g({onLoad:function(e,t){e&&t.forwardedRef&&("function"==typeof t.forwardedRef?t.forwardedRef(e):t.forwardedRef.current=e)},render:function(e){var t=e.result,n=e.props;return n.children?n.children(t):null}}),_=w.loadable,S=w.lazy;var E=y;E.lib=_,b.lib=S;t.a=E},function(e,t,n){"use strict";n.d(t,"a",(function(){return ae}));var r=function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function o(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))}function i(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(a){return function(c){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,a[0]&&(s=0)),s;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return s.label++,{value:a[1],done:!1};case 5:s.label++,r=a[1],a=[0];continue;case 7:a=s.ops.pop(),s.trys.pop();continue;default:if(!(o=s.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){s=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){s.label=a[1];break}if(6===a[0]&&s.label<o[1]){s.label=o[1],o=a;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(a);break}o[2]&&s.ops.pop(),s.trys.pop();continue}a=t.call(e,s)}catch(e){a=[6,e],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,c])}}}Object.create;function s(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create;"function"==typeof SuppressedError&&SuppressedError;function a(e,t){return new Promise((function(n){return setTimeout(n,e,t)}))}function c(e){return!!e&&"function"==typeof e.then}function u(e,t){try{var n=e();c(n)?n.then((function(e){return t(!0,e)}),(function(e){return t(!1,e)})):t(!0,n)}catch(e){t(!1,e)}}function l(e,t,n){return void 0===n&&(n=16),o(this,void 0,void 0,(function(){var r,o,s,c;return i(this,(function(i){switch(i.label){case 0:r=Array(e.length),o=Date.now(),s=0,i.label=1;case 1:return s<e.length?(r[s]=t(e[s],s),(c=Date.now())>=o+n?(o=c,[4,a(0)]):[3,3]):[3,4];case 2:i.sent(),i.label=3;case 3:return++s,[3,1];case 4:return[2,r]}}))}))}function f(e){e.then(void 0,(function(){}))}function h(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]+t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]+t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]+t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]+t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function d(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]*t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]*t[3],n[1]+=n[2]>>>16,n[2]&=65535,n[2]+=e[3]*t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]*t[3],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[2]*t[2],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[3]*t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]*t[3]+e[1]*t[2]+e[2]*t[1]+e[3]*t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function p(e,t){return 32===(t%=64)?[e[1],e[0]]:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t|e[0]>>>32-t]:(t-=32,[e[1]<<t|e[0]>>>32-t,e[0]<<t|e[1]>>>32-t])}function v(e,t){return 0===(t%=64)?e:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t]:[e[1]<<t-32,0]}function g(e,t){return[e[0]^t[0],e[1]^t[1]]}function m(e){return e=g(e,[0,e[0]>>>1]),e=g(e=d(e,[4283543511,3981806797]),[0,e[0]>>>1]),e=g(e=d(e,[3301882366,444984403]),[0,e[0]>>>1])}function y(e,t){t=t||0;var n,r=(e=e||"").length%16,o=e.length-r,i=[0,t],s=[0,t],a=[0,0],c=[0,0],u=[2277735313,289559509],l=[1291169091,658871167];for(n=0;n<o;n+=16)a=[255&e.charCodeAt(n+4)|(255&e.charCodeAt(n+5))<<8|(255&e.charCodeAt(n+6))<<16|(255&e.charCodeAt(n+7))<<24,255&e.charCodeAt(n)|(255&e.charCodeAt(n+1))<<8|(255&e.charCodeAt(n+2))<<16|(255&e.charCodeAt(n+3))<<24],c=[255&e.charCodeAt(n+12)|(255&e.charCodeAt(n+13))<<8|(255&e.charCodeAt(n+14))<<16|(255&e.charCodeAt(n+15))<<24,255&e.charCodeAt(n+8)|(255&e.charCodeAt(n+9))<<8|(255&e.charCodeAt(n+10))<<16|(255&e.charCodeAt(n+11))<<24],a=p(a=d(a,u),31),i=h(i=p(i=g(i,a=d(a,l)),27),s),i=h(d(i,[0,5]),[0,1390208809]),c=p(c=d(c,l),33),s=h(s=p(s=g(s,c=d(c,u)),31),i),s=h(d(s,[0,5]),[0,944331445]);switch(a=[0,0],c=[0,0],r){case 15:c=g(c,v([0,e.charCodeAt(n+14)],48));case 14:c=g(c,v([0,e.charCodeAt(n+13)],40));case 13:c=g(c,v([0,e.charCodeAt(n+12)],32));case 12:c=g(c,v([0,e.charCodeAt(n+11)],24));case 11:c=g(c,v([0,e.charCodeAt(n+10)],16));case 10:c=g(c,v([0,e.charCodeAt(n+9)],8));case 9:c=d(c=g(c,[0,e.charCodeAt(n+8)]),l),s=g(s,c=d(c=p(c,33),u));case 8:a=g(a,v([0,e.charCodeAt(n+7)],56));case 7:a=g(a,v([0,e.charCodeAt(n+6)],48));case 6:a=g(a,v([0,e.charCodeAt(n+5)],40));case 5:a=g(a,v([0,e.charCodeAt(n+4)],32));case 4:a=g(a,v([0,e.charCodeAt(n+3)],24));case 3:a=g(a,v([0,e.charCodeAt(n+2)],16));case 2:a=g(a,v([0,e.charCodeAt(n+1)],8));case 1:a=d(a=g(a,[0,e.charCodeAt(n)]),u),i=g(i,a=d(a=p(a,31),l))}return i=h(i=g(i,[0,e.length]),s=g(s,[0,e.length])),s=h(s,i),i=h(i=m(i),s=m(s)),s=h(s,i),("00000000"+(i[0]>>>0).toString(16)).slice(-8)+("00000000"+(i[1]>>>0).toString(16)).slice(-8)+("00000000"+(s[0]>>>0).toString(16)).slice(-8)+("00000000"+(s[1]>>>0).toString(16)).slice(-8)}function b(e){return parseInt(e)}function w(e){return parseFloat(e)}function _(e,t){return"number"==typeof e&&isNaN(e)?t:e}function S(e){return e.reduce((function(e,t){return e+(t?1:0)}),0)}function E(e,t){if(void 0===t&&(t=1),Math.abs(t)>=1)return Math.round(e/t)*t;var n=1/t;return Math.round(e*n)/n}function I(e){return e&&"object"==typeof e&&"message"in e?e:{message:e}}function A(e){return"function"!=typeof e}function C(e,t,n){var r=Object.keys(e).filter((function(e){return!function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return!0;return!1}(n,e)})),s=l(r,(function(n){return function(e,t){var n=new Promise((function(n){var r=Date.now();u(e.bind(null,t),(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var o=Date.now()-r;if(!e[0])return n((function(){return{error:I(e[1]),duration:o}}));var i=e[1];if(A(i))return n((function(){return{value:i,duration:o}}));n((function(){return new Promise((function(e){var t=Date.now();u(i,(function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=o+Date.now()-t;if(!n[0])return e({error:I(n[1]),duration:i});e({value:n[1],duration:i})}))}))}))}))}));return f(n),function(){return n.then((function(e){return e()}))}}(e[n],t)}));return f(s),function(){return o(this,void 0,void 0,(function(){var e,t,n,o;return i(this,(function(i){switch(i.label){case 0:return[4,s];case 1:return[4,l(i.sent(),(function(e){var t=e();return f(t),t}))];case 2:return e=i.sent(),[4,Promise.all(e)];case 3:for(t=i.sent(),n={},o=0;o<r.length;++o)n[r[o]]=t[o];return[2,n]}}))}))}}function k(){var e=window,t=navigator;return S(["MSCSSMatrix"in e,"msSetImmediate"in e,"msIndexedDB"in e,"msMaxTouchPoints"in t,"msPointerEnabled"in t])>=4}function M(){var e=window,t=navigator;return S(["webkitPersistentStorage"in t,"webkitTemporaryStorage"in t,0===t.vendor.indexOf("Google"),"webkitResolveLocalFileSystemURL"in e,"BatteryManager"in e,"webkitMediaStream"in e,"webkitSpeechGrammar"in e])>=5}function O(){var e=window,t=navigator;return S(["ApplePayError"in e,"CSSPrimitiveValue"in e,"Counter"in e,0===t.vendor.indexOf("Apple"),"getStorageUpdates"in t,"WebKitMediaKeys"in e])>=4}function L(){var e=window;return S(["safari"in e,!("DeviceMotionEvent"in e),!("ongestureend"in e),!("standalone"in navigator)])>=3}function T(){var e=document;return(e.exitFullscreen||e.msExitFullscreen||e.mozCancelFullScreen||e.webkitExitFullscreen).call(e)}function j(){var e=M(),t=function(){var e,t,n=window;return S(["buildID"in navigator,"MozAppearance"in(null!==(t=null===(e=document.documentElement)||void 0===e?void 0:e.style)&&void 0!==t?t:{}),"onmozfullscreenchange"in n,"mozInnerScreenX"in n,"CSSMozDocumentRule"in n,"CanvasCaptureMediaStream"in n])>=4}();if(!e&&!t)return!1;var n=window;return S(["onorientationchange"in n,"orientation"in n,e&&!("SharedWorker"in n),t&&/android/i.test(navigator.appVersion)])>=2}function x(e){var t=new Error(e);return t.name=e,t}function R(e,t,n){var r,s,c;return void 0===n&&(n=50),o(this,void 0,void 0,(function(){var o,u;return i(this,(function(i){switch(i.label){case 0:o=document,i.label=1;case 1:return o.body?[3,3]:[4,a(n)];case 2:return i.sent(),[3,1];case 3:u=o.createElement("iframe"),i.label=4;case 4:return i.trys.push([4,,10,11]),[4,new Promise((function(e,n){var r=!1,i=function(){r=!0,e()};u.onload=i,u.onerror=function(e){r=!0,n(e)};var s=u.style;s.setProperty("display","block","important"),s.position="absolute",s.top="0",s.left="0",s.visibility="hidden",t&&"srcdoc"in u?u.srcdoc=t:u.src="about:blank",o.body.appendChild(u);var a=function(){var e,t;r||("complete"===(null===(t=null===(e=u.contentWindow)||void 0===e?void 0:e.document)||void 0===t?void 0:t.readyState)?i():setTimeout(a,10))};a()}))];case 5:i.sent(),i.label=6;case 6:return(null===(s=null===(r=u.contentWindow)||void 0===r?void 0:r.document)||void 0===s?void 0:s.body)?[3,8]:[4,a(n)];case 7:return i.sent(),[3,6];case 8:return[4,e(u,u.contentWindow)];case 9:return[2,i.sent()];case 10:return null===(c=u.parentNode)||void 0===c||c.removeChild(u),[7];case 11:return[2]}}))}))}function P(e){for(var t=function(e){for(var t,n,r="Unexpected syntax '".concat(e,"'"),o=/^\s*([a-z-]*)(.*)$/i.exec(e),i=o[1]||void 0,s={},a=/([.:#][\w-]+|\[.+?\])/gi,c=function(e,t){s[e]=s[e]||[],s[e].push(t)};;){var u=a.exec(o[2]);if(!u)break;var l=u[0];switch(l[0]){case".":c("class",l.slice(1));break;case"#":c("id",l.slice(1));break;case"[":var f=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(l);if(!f)throw new Error(r);c(f[1],null!==(n=null!==(t=f[4])&&void 0!==t?t:f[5])&&void 0!==n?n:"");break;default:throw new Error(r)}}return[i,s]}(e),n=t[0],r=t[1],o=document.createElement(null!=n?n:"div"),i=0,s=Object.keys(r);i<s.length;i++){var a=s[i],c=r[a].join(" ");"style"===a?N(o.style,c):o.setAttribute(a,c)}return o}function N(e,t){for(var n=0,r=t.split(";");n<r.length;n++){var o=r[n],i=/^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(o);if(i){var s=i[1],a=i[2],c=i[4];e.setProperty(s,a,c||"")}}}var D=["monospace","sans-serif","serif"],U=["sans-serif-thin","ARNO PRO","Agency FB","Arabic Typesetting","Arial Unicode MS","AvantGarde Bk BT","BankGothic Md BT","Batang","Bitstream Vera Sans Mono","Calibri","Century","Century Gothic","Clarendon","EUROSTILE","Franklin Gothic","Futura Bk BT","Futura Md BT","GOTHAM","Gill Sans","HELV","Haettenschweiler","Helvetica Neue","Humanst521 BT","Leelawadee","Letter Gothic","Levenim MT","Lucida Bright","Lucida Sans","Menlo","MS Mincho","MS Outlook","MS Reference Specialty","MS UI Gothic","MT Extra","MYRIAD PRO","Marlett","Meiryo UI","Microsoft Uighur","Minion Pro","Monotype Corsiva","PMingLiU","Pristina","SCRIPTINA","Segoe UI Light","Serifa","SimHei","Small Fonts","Staccato222 BT","TRAJAN PRO","Univers CE 55 Medium","Vrinda","ZWAdobeF"];function V(e){return e.toDataURL()}var F,Y;function B(){var e=this;return function(){if(void 0===Y){var e=function(){var t=G();W(t)?Y=setTimeout(e,2500):(F=t,Y=void 0)};e()}}(),function(){return o(e,void 0,void 0,(function(){var e;return i(this,(function(t){switch(t.label){case 0:return W(e=G())?F?[2,s([],F,!0)]:(n=document).fullscreenElement||n.msFullscreenElement||n.mozFullScreenElement||n.webkitFullscreenElement?[4,T()]:[3,2]:[3,2];case 1:t.sent(),e=G(),t.label=2;case 2:return W(e)||(F=e),[2,e]}var n}))}))}}function G(){var e=screen;return[_(w(e.availTop),null),_(w(e.width)-w(e.availWidth)-_(w(e.availLeft),0),null),_(w(e.height)-w(e.availHeight)-_(w(e.availTop),0),null),_(w(e.availLeft),null)]}function W(e){for(var t=0;t<4;++t)if(e[t])return!1;return!0}function Z(e){var t;return o(this,void 0,void 0,(function(){var n,r,o,s,c,u,l;return i(this,(function(i){switch(i.label){case 0:for(n=document,r=n.createElement("div"),o=new Array(e.length),s={},J(r),l=0;l<e.length;++l)"DIALOG"===(c=P(e[l])).tagName&&c.show(),J(u=n.createElement("div")),u.appendChild(c),r.appendChild(u),o[l]=c;i.label=1;case 1:return n.body?[3,3]:[4,a(50)];case 2:return i.sent(),[3,1];case 3:n.body.appendChild(r);try{for(l=0;l<e.length;++l)o[l].offsetParent||(s[e[l]]=!0)}finally{null===(t=r.parentNode)||void 0===t||t.removeChild(r)}return[2,s]}}))}))}function J(e){e.style.setProperty("display","block","important")}function q(e){return matchMedia("(inverted-colors: ".concat(e,")")).matches}function z(e){return matchMedia("(forced-colors: ".concat(e,")")).matches}function H(e){return matchMedia("(prefers-contrast: ".concat(e,")")).matches}function X(e){return matchMedia("(prefers-reduced-motion: ".concat(e,")")).matches}function K(e){return matchMedia("(dynamic-range: ".concat(e,")")).matches}var Q=Math,$=function(){return 0};var ee={default:[],apple:[{font:"-apple-system-body"}],serif:[{fontFamily:"serif"}],sans:[{fontFamily:"sans-serif"}],mono:[{fontFamily:"monospace"}],min:[{fontSize:"1px"}],system:[{fontFamily:"system-ui"}]};var te={fonts:function(){return R((function(e,t){var n=t.document,r=n.body;r.style.fontSize="48px";var o=n.createElement("div"),i={},s={},a=function(e){var t=n.createElement("span"),r=t.style;return r.position="absolute",r.top="0",r.left="0",r.fontFamily=e,t.textContent="mmMwWLliI0O&1",o.appendChild(t),t},c=D.map(a),u=function(){for(var e={},t=function(t){e[t]=D.map((function(e){return function(e,t){return a("'".concat(e,"',").concat(t))}(t,e)}))},n=0,r=U;n<r.length;n++){t(r[n])}return e}();r.appendChild(o);for(var l=0;l<D.length;l++)i[D[l]]=c[l].offsetWidth,s[D[l]]=c[l].offsetHeight;return U.filter((function(e){return t=u[e],D.some((function(e,n){return t[n].offsetWidth!==i[e]||t[n].offsetHeight!==s[e]}));var t}))}))},domBlockers:function(e){var t=(void 0===e?{}:e).debug;return o(this,void 0,void 0,(function(){var e,n,r,o,s;return i(this,(function(i){switch(i.label){case 0:return O()||j()?(a=atob,e={abpIndo:["#Iklan-Melayang","#Kolom-Iklan-728","#SidebarIklan-wrapper",'[title="ALIENBOLA" i]',a("I0JveC1CYW5uZXItYWRz")],abpvn:[".quangcao","#mobileCatfish",a("LmNsb3NlLWFkcw=="),'[id^="bn_bottom_fixed_"]',"#pmadv"],adBlockFinland:[".mainostila",a("LnNwb25zb3JpdA=="),".ylamainos",a("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")],adBlockPersian:["#navbar_notice_50",".kadr",'TABLE[width="140px"]',"#divAgahi",a("YVtocmVmXj0iaHR0cDovL2cxLnYuZndtcm0ubmV0L2FkLyJd")],adBlockWarningRemoval:["#adblock-honeypot",".adblocker-root",".wp_adblock_detect",a("LmhlYWRlci1ibG9ja2VkLWFk"),a("I2FkX2Jsb2NrZXI=")],adGuardAnnoyances:[".hs-sosyal","#cookieconsentdiv",'div[class^="app_gdpr"]',".as-oil",'[data-cypress="soft-push-notification-modal"]'],adGuardBase:[".BetterJsPopOverlay",a("I2FkXzMwMFgyNTA="),a("I2Jhbm5lcmZsb2F0MjI="),a("I2NhbXBhaWduLWJhbm5lcg=="),a("I0FkLUNvbnRlbnQ=")],adGuardChinese:[a("LlppX2FkX2FfSA=="),a("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),"#widget-quan",a("YVtocmVmKj0iLzg0OTkyMDIwLnh5eiJd"),a("YVtocmVmKj0iLjE5NTZobC5jb20vIl0=")],adGuardFrench:["#pavePub",a("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),".mobile_adhesion",".widgetadv",a("LmFkc19iYW4=")],adGuardGerman:['aside[data-portal-id="leaderboard"]'],adGuardJapanese:["#kauli_yad_1",a("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),a("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),a("LmFkZ29vZ2xl"),a("Ll9faXNib29zdFJldHVybkFk")],adGuardMobile:[a("YW1wLWF1dG8tYWRz"),a("LmFtcF9hZA=="),'amp-embed[type="24smi"]',"#mgid_iframe1",a("I2FkX2ludmlld19hcmVh")],adGuardRussian:[a("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),a("LnJlY2xhbWE="),'div[id^="smi2adblock"]',a("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),"#psyduckpockeball"],adGuardSocial:[a("YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="),a("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),".etsy-tweet","#inlineShare",".popup-social"],adGuardSpanishPortuguese:["#barraPublicidade","#Publicidade","#publiEspecial","#queTooltip",".cnt-publi"],adGuardTrackingProtection:["#qoo-counter",a("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),a("YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="),a("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),"#top100counter"],adGuardTurkish:["#backkapat",a("I3Jla2xhbWk="),a("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),a("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),a("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")],bulgarian:[a("dGQjZnJlZW5ldF90YWJsZV9hZHM="),"#ea_intext_div",".lapni-pop-over","#xenium_hot_offers"],easyList:[".yb-floorad",a("LndpZGdldF9wb19hZHNfd2lkZ2V0"),a("LnRyYWZmaWNqdW5reS1hZA=="),".textad_headline",a("LnNwb25zb3JlZC10ZXh0LWxpbmtz")],easyListChina:[a("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),a("LmZyb250cGFnZUFkdk0="),"#taotaole","#aafoot.top_box",".cfa_popup"],easyListCookie:[".ezmob-footer",".cc-CookieWarning","[data-cookie-number]",a("LmF3LWNvb2tpZS1iYW5uZXI="),".sygnal24-gdpr-modal-wrap"],easyListCzechSlovak:["#onlajny-stickers",a("I3Jla2xhbW5pLWJveA=="),a("LnJla2xhbWEtbWVnYWJvYXJk"),".sklik",a("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")],easyListDutch:[a("I2FkdmVydGVudGll"),a("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),".adstekst",a("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),"#semilo-lrectangle"],easyListGermany:["#SSpotIMPopSlider",a("LnNwb25zb3JsaW5rZ3J1ZW4="),a("I3dlcmJ1bmdza3k="),a("I3Jla2xhbWUtcmVjaHRzLW1pdHRl"),a("YVtocmVmXj0iaHR0cHM6Ly9iZDc0Mi5jb20vIl0=")],easyListItaly:[a("LmJveF9hZHZfYW5udW5jaQ=="),".sb-box-pubbliredazionale",a("YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ==")],easyListLithuania:[a("LnJla2xhbW9zX3RhcnBhcw=="),a("LnJla2xhbW9zX251b3JvZG9z"),a("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),a("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),a("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")],estonian:[a("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")],fanboyAnnoyances:["#ac-lre-player",".navigate-to-top","#subscribe_popup",".newsletter_holder","#back-top"],fanboyAntiFacebook:[".util-bar-module-firefly-visible"],fanboyEnhancedTrackers:[".open.pushModal","#issuem-leaky-paywall-articles-zero-remaining-nag","#sovrn_container",'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',".BlockNag__Card"],fanboySocial:["#FollowUs","#meteored_share","#social_follow",".article-sharer",".community__social-desc"],frellwitSwedish:[a("YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="),a("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),"article.category-samarbete",a("ZGl2LmhvbGlkQWRz"),"ul.adsmodern"],greekAdBlock:[a("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),a("QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="),a("QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"),"DIV.agores300","TABLE.advright"],hungarian:["#cemp_doboz",".optimonk-iframe-container",a("LmFkX19tYWlu"),a("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),"#hirdetesek_box"],iDontCareAboutCookies:['.alert-info[data-block-track*="CookieNotice"]',".ModuleTemplateCookieIndicator",".o--cookies--container","#cookies-policy-sticky","#stickyCookieBar"],icelandicAbp:[a("QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ==")],latvian:[a("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="),a("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ==")],listKr:[a("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),a("I2xpdmVyZUFkV3JhcHBlcg=="),a("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),a("aW5zLmZhc3R2aWV3LWFk"),".revenue_unit_item.dable"],listeAr:[a("LmdlbWluaUxCMUFk"),".right-and-left-sponsers",a("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),a("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),a("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")],listeFr:[a("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),a("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),a("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),".site-pub-interstitiel",'div[id^="crt-"][data-criteo-id]'],officialPolish:["#ceneo-placeholder-ceneo-12",a("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),a("YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="),a("YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="),a("ZGl2I3NrYXBpZWNfYWQ=")],ro:[a("YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"),a("YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="),a("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd"),'a[href^="/url/"]'],ruAd:[a("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),a("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),a("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),"#pgeldiz",".yandex-rtb-block"],thaiAds:["a[href*=macau-uta-popup]",a("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),a("LmFkczMwMHM="),".bumq",".img-kosana"],webAnnoyancesUltralist:["#mod-social-share-2","#social-tools",a("LmN0cGwtZnVsbGJhbm5lcg=="),".zergnet-recommend",".yt.btn-link.btn-md.btn"]},n=Object.keys(e),[4,Z((s=[]).concat.apply(s,n.map((function(t){return e[t]}))))]):[2,void 0];case 1:return r=i.sent(),t&&function(e,t){for(var n="DOM blockers debug:\n```",r=0,o=Object.keys(e);r<o.length;r++){var i=o[r];n+="\n".concat(i,":");for(var s=0,a=e[i];s<a.length;s++){var c=a[s];n+="\n ".concat(t[c]?"🚫":"➡️"," ").concat(c)}}console.log("".concat(n,"\n```"))}(e,r),(o=n.filter((function(t){var n=e[t];return S(n.map((function(e){return r[e]})))>.6*n.length}))).sort(),[2,o]}var a}))}))},fontPreferences:function(){return function(e,t){void 0===t&&(t=4e3);return R((function(n,r){var o=r.document,i=o.body,a=i.style;a.width="".concat(t,"px"),a.webkitTextSizeAdjust=a.textSizeAdjust="none",M()?i.style.zoom="".concat(1/r.devicePixelRatio):O()&&(i.style.zoom="reset");var c=o.createElement("div");return c.textContent=s([],Array(t/20<<0),!0).map((function(){return"word"})).join(" "),i.appendChild(c),e(o,i)}),'<!doctype html><html><head><meta name="viewport" content="width=device-width, initial-scale=1">')}((function(e,t){for(var n={},r={},o=0,i=Object.keys(ee);o<i.length;o++){var s=i[o],a=ee[s],c=a[0],u=void 0===c?{}:c,l=a[1],f=void 0===l?"mmMwWLliI0fiflO&1":l,h=e.createElement("span");h.textContent=f,h.style.whiteSpace="nowrap";for(var d=0,p=Object.keys(u);d<p.length;d++){var v=p[d],g=u[v];void 0!==g&&(h.style[v]=g)}n[s]=h,t.appendChild(e.createElement("br")),t.appendChild(h)}for(var m=0,y=Object.keys(ee);m<y.length;m++){r[s=y[m]]=n[s].getBoundingClientRect().width}return r}))},audio:function(){var e=window,t=e.OfflineAudioContext||e.webkitOfflineAudioContext;if(!t)return-2;if(O()&&!L()&&!function(){var e=window;return S(["DOMRectList"in e,"RTCPeerConnectionIceEvent"in e,"SVGGeometryElement"in e,"ontransitioncancel"in e])>=3}())return-1;var n=new t(1,5e3,44100),r=n.createOscillator();r.type="triangle",r.frequency.value=1e4;var o=n.createDynamicsCompressor();o.threshold.value=-50,o.knee.value=40,o.ratio.value=12,o.attack.value=0,o.release.value=.25,r.connect(o),o.connect(n.destination),r.start(0);var i=function(e){var t=function(){};return[new Promise((function(n,r){var o=!1,i=0,s=0;e.oncomplete=function(e){return n(e.renderedBuffer)};var a=function(){setTimeout((function(){return r(x("timeout"))}),Math.min(500,s+5e3-Date.now()))},u=function(){try{var t=e.startRendering();switch(c(t)&&f(t),e.state){case"running":s=Date.now(),o&&a();break;case"suspended":document.hidden||i++,o&&i>=3?r(x("suspended")):setTimeout(u,500)}}catch(e){r(e)}};u(),t=function(){o||(o=!0,s>0&&a())}})),t]}(n),s=i[0],a=i[1],u=s.then((function(e){return function(e){for(var t=0,n=0;n<e.length;++n)t+=Math.abs(e[n]);return t}(e.getChannelData(0).subarray(4500))}),(function(e){if("timeout"===e.name||"suspended"===e.name)return-3;throw e}));return f(u),function(){return a(),u}},screenFrame:function(){var e=this,t=B();return function(){return o(e,void 0,void 0,(function(){var e,n;return i(this,(function(r){switch(r.label){case 0:return[4,t()];case 1:return e=r.sent(),[2,[(n=function(e){return null===e?null:E(e,10)})(e[0]),n(e[1]),n(e[2]),n(e[3])]]}}))}))}},osCpu:function(){return navigator.oscpu},languages:function(){var e,t=navigator,n=[],r=t.language||t.userLanguage||t.browserLanguage||t.systemLanguage;if(void 0!==r&&n.push([r]),Array.isArray(t.languages))M()&&S([!("MediaSettingsRange"in(e=window)),"RTCEncodedAudioFrame"in e,""+e.Intl=="[object Intl]",""+e.Reflect=="[object Reflect]"])>=3||n.push(t.languages);else if("string"==typeof t.languages){var o=t.languages;o&&n.push(o.split(","))}return n},colorDepth:function(){return window.screen.colorDepth},deviceMemory:function(){return _(w(navigator.deviceMemory),void 0)},screenResolution:function(){var e=screen,t=function(e){return _(b(e),null)},n=[t(e.width),t(e.height)];return n.sort().reverse(),n},hardwareConcurrency:function(){return _(b(navigator.hardwareConcurrency),void 0)},timezone:function(){var e,t=null===(e=window.Intl)||void 0===e?void 0:e.DateTimeFormat;if(t){var n=(new t).resolvedOptions().timeZone;if(n)return n}var r,o=(r=(new Date).getFullYear(),-Math.max(w(new Date(r,0,1).getTimezoneOffset()),w(new Date(r,6,1).getTimezoneOffset())));return"UTC".concat(o>=0?"+":"").concat(Math.abs(o))},sessionStorage:function(){try{return!!window.sessionStorage}catch(e){return!0}},localStorage:function(){try{return!!window.localStorage}catch(e){return!0}},indexedDB:function(){var e,t;if(!(k()||(e=window,t=navigator,S(["msWriteProfilerMark"in e,"MSStream"in e,"msLaunchUri"in t,"msSaveBlob"in t])>=3&&!k())))try{return!!window.indexedDB}catch(e){return!0}},openDatabase:function(){return!!window.openDatabase},cpuClass:function(){return navigator.cpuClass},platform:function(){var e=navigator.platform;return"MacIntel"===e&&O()&&!L()?function(){if("iPad"===navigator.platform)return!0;var e=screen,t=e.width/e.height;return S(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,t>.65&&t<1.53])>=2}()?"iPad":"iPhone":e},plugins:function(){var e=navigator.plugins;if(e){for(var t=[],n=0;n<e.length;++n){var r=e[n];if(r){for(var o=[],i=0;i<r.length;++i){var s=r[i];o.push({type:s.type,suffixes:s.suffixes})}t.push({name:r.name,description:r.description,mimeTypes:o})}}return t}},canvas:function(){var e,t,n=!1,r=function(){var e=document.createElement("canvas");return e.width=1,e.height=1,[e,e.getContext("2d")]}(),o=r[0],i=r[1];if(function(e,t){return!(!t||!e.toDataURL)}(o,i)){n=function(e){return e.rect(0,0,10,10),e.rect(2,2,6,6),!e.isPointInPath(5,5,"evenodd")}(i),function(e,t){e.width=240,e.height=60,t.textBaseline="alphabetic",t.fillStyle="#f60",t.fillRect(100,1,62,20),t.fillStyle="#069",t.font='11pt "Times New Roman"';var n="Cwm fjordbank gly ".concat(String.fromCharCode(55357,56835));t.fillText(n,2,15),t.fillStyle="rgba(102, 204, 0, 0.2)",t.font="18pt Arial",t.fillText(n,4,45)}(o,i);var s=V(o);s!==V(o)?e=t="unstable":(t=s,function(e,t){e.width=122,e.height=110,t.globalCompositeOperation="multiply";for(var n=0,r=[["#f2f",40,40],["#2ff",80,40],["#ff2",60,80]];n<r.length;n++){var o=r[n],i=o[0],s=o[1],a=o[2];t.fillStyle=i,t.beginPath(),t.arc(s,a,40,0,2*Math.PI,!0),t.closePath(),t.fill()}t.fillStyle="#f9c",t.arc(60,60,60,0,2*Math.PI,!0),t.arc(60,60,20,0,2*Math.PI,!0),t.fill("evenodd")}(o,i),e=V(o))}else e=t="";return{winding:n,geometry:e,text:t}},touchSupport:function(){var e,t=navigator,n=0;void 0!==t.maxTouchPoints?n=b(t.maxTouchPoints):void 0!==t.msMaxTouchPoints&&(n=t.msMaxTouchPoints);try{document.createEvent("TouchEvent"),e=!0}catch(t){e=!1}return{maxTouchPoints:n,touchEvent:e,touchStart:"ontouchstart"in window}},vendor:function(){return navigator.vendor||""},vendorFlavors:function(){for(var e=[],t=0,n=["chrome","safari","__crWeb","__gCrWeb","yandex","__yb","__ybro","__firefox__","__edgeTrackingPreventionStatistics","webkit","oprt","samsungAr","ucweb","UCShellJava","puffinDevice"];t<n.length;t++){var r=n[t],o=window[r];o&&"object"==typeof o&&e.push(r)}return e.sort()},cookiesEnabled:function(){var e=document;try{e.cookie="cookietest=1; SameSite=Strict;";var t=-1!==e.cookie.indexOf("cookietest=");return e.cookie="cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT",t}catch(e){return!1}},colorGamut:function(){for(var e=0,t=["rec2020","p3","srgb"];e<t.length;e++){var n=t[e];if(matchMedia("(color-gamut: ".concat(n,")")).matches)return n}},invertedColors:function(){return!!q("inverted")||!q("none")&&void 0},forcedColors:function(){return!!z("active")||!z("none")&&void 0},monochrome:function(){if(matchMedia("(min-monochrome: 0)").matches){for(var e=0;e<=100;++e)if(matchMedia("(max-monochrome: ".concat(e,")")).matches)return e;throw new Error("Too high value")}},contrast:function(){return H("no-preference")?0:H("high")||H("more")?1:H("low")||H("less")?-1:H("forced")?10:void 0},reducedMotion:function(){return!!X("reduce")||!X("no-preference")&&void 0},hdr:function(){return!!K("high")||!K("standard")&&void 0},math:function(){var e,t=Q.acos||$,n=Q.acosh||$,r=Q.asin||$,o=Q.asinh||$,i=Q.atanh||$,s=Q.atan||$,a=Q.sin||$,c=Q.sinh||$,u=Q.cos||$,l=Q.cosh||$,f=Q.tan||$,h=Q.tanh||$,d=Q.exp||$,p=Q.expm1||$,v=Q.log1p||$;return{acos:t(.12312423423423424),acosh:n(1e308),acoshPf:(e=1e154,Q.log(e+Q.sqrt(e*e-1))),asin:r(.12312423423423424),asinh:o(1),asinhPf:function(e){return Q.log(e+Q.sqrt(e*e+1))}(1),atanh:i(.5),atanhPf:function(e){return Q.log((1+e)/(1-e))/2}(.5),atan:s(.5),sin:a(-1e300),sinh:c(1),sinhPf:function(e){return Q.exp(e)-1/Q.exp(e)/2}(1),cos:u(10.000000000123),cosh:l(1),coshPf:function(e){return(Q.exp(e)+1/Q.exp(e))/2}(1),tan:f(-1e300),tanh:h(1),tanhPf:function(e){return(Q.exp(2*e)-1)/(Q.exp(2*e)+1)}(1),exp:d(1),expm1:p(1),expm1Pf:function(e){return Q.exp(e)-1}(1),log1p:v(10),log1pPf:function(e){return Q.log(1+e)}(10),powPI:function(e){return Q.pow(Q.PI,e)}(-100)}},videoCard:function(){var e,t=document.createElement("canvas"),n=null!==(e=t.getContext("webgl"))&&void 0!==e?e:t.getContext("experimental-webgl");if(n&&"getExtension"in n){var r=n.getExtension("WEBGL_debug_renderer_info");if(r)return{vendor:(n.getParameter(r.UNMASKED_VENDOR_WEBGL)||"").toString(),renderer:(n.getParameter(r.UNMASKED_RENDERER_WEBGL)||"").toString()}}},pdfViewerEnabled:function(){return navigator.pdfViewerEnabled},architecture:function(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}};function ne(e){var t=function(e){if(j())return.4;if(O())return L()?.5:.3;var t=e.platform.value||"";if(/^Win/.test(t))return.6;if(/^Mac/.test(t))return.5;return.7}(e),n=function(e){return E(.99+.01*e,1e-4)}(t);return{score:t,comment:"$ if upgrade to Pro: https://fpjs.dev/pro".replace(/\$/g,"".concat(n))}}function re(e){return JSON.stringify(e,(function(e,t){return t instanceof Error?r({name:(n=t).name,message:n.message,stack:null===(o=n.stack)||void 0===o?void 0:o.split("\n")},n):t;var n,o}),2)}function oe(e){return y(function(e){for(var t="",n=0,r=Object.keys(e).sort();n<r.length;n++){var o=r[n],i=e[o],s=i.error?"error":JSON.stringify(i.value);t+="".concat(t?"|":"").concat(o.replace(/([:|\\])/g,"\\$1"),":").concat(s)}return t}(e))}function ie(e){return void 0===e&&(e=50),function(e,t){void 0===t&&(t=1/0);var n=window.requestIdleCallback;return n?new Promise((function(e){return n.call(window,(function(){return e()}),{timeout:t})})):a(Math.min(e,t))}(e,2*e)}function se(e,t){var n=Date.now();return{get:function(r){return o(this,void 0,void 0,(function(){var o,s,a;return i(this,(function(i){switch(i.label){case 0:return o=Date.now(),[4,e()];case 1:return s=i.sent(),a=function(e){var t;return{get visitorId(){return void 0===t&&(t=oe(this.components)),t},set visitorId(e){t=e},confidence:ne(e),components:e,version:"3.4.2"}}(s),(t||(null==r?void 0:r.debug))&&console.log("Copy the text below to get the debug data:\n\n```\nversion: ".concat(a.version,"\nuserAgent: ").concat(navigator.userAgent,"\ntimeBetweenLoadAndGet: ").concat(o-n,"\nvisitorId: ").concat(a.visitorId,"\ncomponents: ").concat(re(s),"\n```")),[2,a]}}))}))}}}var ae={load:function(e){var t=void 0===e?{}:e,n=t.delayFallback,r=t.debug,s=t.monitoring,a=void 0===s||s;return o(this,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return a&&function(){if(!(window.__fpjs_d_m||Math.random()>=.001))try{var e=new XMLHttpRequest;e.open("get","https://m1.openfpcdn.io/fingerprintjs/v".concat("3.4.2","/npm-monitoring"),!0),e.send()}catch(e){console.error(e)}}(),[4,ie(n)];case 1:return e.sent(),[2,se(C(te,{debug:r},[]),r)]}}))}))},hashComponents:oe,componentsToDebugString:re}},,function(e,t,n){"use strict";(function(e){
|
|
8
|
+
*/!function(i){if(void 0===(o="function"==typeof(r=i)?r.call(t,n,t,e):r)||(e.exports=o),!0,e.exports=i(),!!0){var s=window.Cookies,a=window.Cookies=i();a.noConflict=function(){return window.Cookies=s,a}}}((function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function o(){}function i(t,n,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},o.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var s=JSON.stringify(n);/^[\{\[]/.test(s)&&(n=s)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var a="";for(var c in i)i[c]&&(a+="; "+c,!0!==i[c]&&(a+="="+i[c].split(";")[0]));return document.cookie=t+"="+n+a}}function s(e,n){if("undefined"!=typeof document){for(var o={},i=document.cookie?document.cookie.split("; "):[],s=0;s<i.length;s++){var a=i[s].split("="),c=a.slice(1).join("=");n||'"'!==c.charAt(0)||(c=c.slice(1,-1));try{var u=t(a[0]);if(c=(r.read||r)(c,u)||t(c),n)try{c=JSON.parse(c)}catch(e){}if(o[u]=c,e===u)break}catch(e){}}return e?o[e]:o}}return o.set=i,o.get=function(e){return s(e,!1)},o.getJSON=function(e){return s(e,!0)},o.remove=function(t,n){i(t,"",e(n,{expires:-1}))},o.defaults={},o.withConverter=n,o}((function(){}))}))},function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return S})),n.d(t,"b",(function(){return E}));var r=n(0),o=n(3),i=n(6),s=n(15),a=n(2);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var u=["children","emojiIcon","notiFicationIcon","attachFileIcon","sendIcon","recordIcon","dateFormat","sortByCustomType","auth","allowMediaDownload","showStatusMessages","hideHiddenConversations","renderCustomMessage","onMessage","onConversationRead","chatTheme","manageProfile","onViewProfilleClick","manageMessage","baseImageUrl","renderCustomMessageSendForm","renderCustomChatMessageHeader","renderCustomChatListTile","renderChatMediaContainer","renderLastMessage","renderDeleteDialog","renderChatListFilter","showChatListFilter","documentUploadHandlerRef","chatMessageAction","isometrikCreds","isGroup"];function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){h(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function h(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==c(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===c(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e){return function(e){if(Array.isArray(e))return g(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||v(e)||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.")}()}function p(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],c=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);c=!0);}catch(e){u=!0,o=e}finally{try{if(!c&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return a}}(e,t)||v(e,t)||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.")}()}function v(e,t){if(e){if("string"==typeof e)return g(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?g(e,t):void 0}}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */m=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},s=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{l({},"")}catch(e){l=function(e,t,n){return e[t]=n}}function f(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:O(e,n,a)}),s}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=f;var d="suspendedStart",p="executing",v="completed",g={};function y(){}function b(){}function w(){}var _={};l(_,s,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,s)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){l(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,i,s,a){var u=h(e[o],e,i);if("throw"!==u.type){var l=u.arg,f=l.value;return f&&"object"==c(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(f).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,a)}))}a(u.arg)}var i;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return i=i?i.then(o,o):o()}})}function O(t,n,r){var o=d;return function(i,s){if(o===p)throw new Error("Generator is already running");if(o===v){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===g)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===d)throw o=v,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=p;var u=h(t,n,r);if("normal"===u.type){if(o=r.done?v:"suspendedYield",u.arg===g)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=v,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var i=h(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,g;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(c(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=l(w,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,l(e,u,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),l(C.prototype,a,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(f(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),l(I,u,"Generator"),l(I,s,(function(){return this})),l(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,g):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),g},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}function y(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function b(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){y(i,r,o,s,a,"next",e)}function a(e){y(i,r,o,s,a,"throw",e)}s(void 0)}))}}function w(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var _=Object(r.createContext)(),S=function(e){var t=e.children,c=e.emojiIcon,l=e.notiFicationIcon,v=e.attachFileIcon,g=e.sendIcon,y=e.recordIcon,S=e.dateFormat,E=void 0===S?"DD/MM/YYYY":S,I=e.sortByCustomType,A=void 0!==I&&I,C=e.auth,O=e.allowMediaDownload,M=e.showStatusMessages,k=void 0===M||M,L=e.hideHiddenConversations,T=void 0!==L&&L,j=e.renderCustomMessage,x=void 0===j?null:j,R=e.onMessage,P=void 0===R?function(){}:R,N=e.onConversationRead,D=void 0===N?function(){}:N,U=e.chatTheme,V=void 0===U?"light":U,F=e.manageProfile,B=e.onViewProfilleClick,Y=void 0===B?function(){}:B,G=e.manageMessage,W=e.baseImageUrl,Z=void 0===W?null:W,J=e.renderCustomMessageSendForm,q=void 0===J?null:J,z=e.renderCustomChatMessageHeader,H=void 0===z?null:z,X=e.renderCustomChatListTile,K=void 0===X?null:X,Q=e.renderChatMediaContainer,$=e.renderLastMessage,ee=e.renderDeleteDialog,te=e.renderChatListFilter,ne=e.showChatListFilter,re=void 0===ne||ne,oe=e.documentUploadHandlerRef,ie=e.chatMessageAction,se=e.isometrikCreds,ae=void 0===se?{}:se,ce=e.isGroup,ue=void 0!==ce&&ce,le=(w(e,u),Object(r.useRef)(!1)),fe=function(){var e=b(m().mark((function e(){var t,r;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.resolve().then(n.bind(null,11));case 2:t=e.sent.default,console.log("initttt mqtt"),r=Object(o.b)("isometrikToken"),t.initializeInstance({baseUrl:ae.baseUrl||"https://apis.isometrik.io",licenseKey:ae.licenseKey||"lic-IMKdwqAmUJGARMalVE3APneqSnEYreBqZfu",appSecret:ae.appSecret||"SFMyNTY.g3QAAAACZAAEZGF0YXQAAAADbQAAAAlhY2NvdW50SWRtAAAAGDY0M2VhMjk0MjBhYWY1MDAwMTA3MGFjN20AAAAIa2V5c2V0SWRtAAAAJDc1NzhmYjcxLWQyNjItNGMyZi1iNGRjLWNkMGMwNzQ5MDRhOG0AAAAJcHJvamVjdElkbQAAACQwNTg0Mzg0Zi0xOWJhLTRiODAtOWQyNS00NzQ1MDljZWIxZTdkAAZzaWduZWRuBgAQIq-UhwE.p_NXSuYWmYotKpLG733Ivi4_yVTDASNeHfLTXLxqD6g",userSecret:ae.userSecret||"SFMyNTY.g3QAAAACZAAEZGF0YXQAAAADbQAAAAlhY2NvdW50SWRtAAAAGDY0M2VhMjk0MjBhYWY1MDAwMTA3MGFjN20AAAAIa2V5c2V0SWRtAAAAJDc1NzhmYjcxLWQyNjItNGMyZi1iNGRjLWNkMGMwNzQ5MDRhOG0AAAAJcHJvamVjdElkbQAAACQwNTg0Mzg0Zi0xOWJhLTRiODAtOWQyNS00NzQ1MDljZWIxZTdkAAZzaWduZWRuBgAbIq-UhwE.5f_HqpUseV-zNWY3Bq0FKnpj2z6TVBmkHOx1gLxP3kY",userToken:ae.userToken||r}),le.current=!0;case 7:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();ae&&!le.current&&Object(i.y)()&&fe();Object(r.useRef)();var he=p(Object(r.useState)("dark"===V),2),de=he[0],pe=he[1],ve=p(Object(r.useState)(!0),2),ge=ve[0],me=ve[1],ye=p(Object(r.useState)(!1),2),be=ye[0],we=ye[1],_e=p(Object(r.useState)(),2),Se=_e[0],Ee=_e[1],Ie=p(Object(r.useState)(),2),Ae=Ie[0],Ce=Ie[1],Oe=p(Object(r.useState)(!0),2),Me=Oe[0],ke=Oe[1],Le=p(Object(r.useState)(!1),2),Te=Le[0],je=Le[1],xe=p(Object(r.useState)({}),2),Re=xe[0],Pe=xe[1],Ne=p(Object(r.useState)(),2),De=Ne[0],Ue=Ne[1],Ve=p(Object(r.useState)("ALL"),2),Fe=Ve[0],Be=Ve[1],Ye=p(Object(r.useState)({selectedConvId:"",messages:{},conversations:[],users:[]}),2),Ge=Ye[0],We=Ye[1],Ze=Object(o.b)("isometrikUserId");Object(r.useEffect)((function(){be&&qe(),C&&Je()}),[be,C]),Object(r.useEffect)((function(){Object(o.c)("theme","dark"===V);var e=Object(o.b)("theme");pe("true"===e)}),[V]);var Je=function(){var e=b(m().mark((function e(){var t,r,i;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Promise.resolve().then(n.bind(null,1));case 3:t=e.sent.default,(r=Object(o.b)("isometrikToken"))?(null===(i=t())||void 0===i||null===(i=i.user)||void 0===i||i.setUserToken(r),we(!0)):we(!1),me(!1),r&&t().user.getUserDetails().then((function(e){Ce(e)})),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(0),console.log("Errrroorrr -- ",e.t0);case 13:case"end":return e.stop()}}),e,null,[[0,10]])})));return function(){return e.apply(this,arguments)}}(),qe=function(){var e=b(m().mark((function e(){var t,r,s,a;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(i.q)();case 2:return t=e.sent,r=Object(o.b)("isometrikUserId"),e.next=6,Promise.resolve().then(n.bind(null,1));case 6:s=e.sent.default,console.log("clienttttttttttttt",s),console.log(r,t,ae,"mqtt connecting"),(a=s().initializeMqtt({hostUri:"wss://connections.isometrik.io:2053/mqtt",clientId:r,licenseKey:ae.licenseKey,projectId:ae.projectId,keysetId:ae.keysetId,accountId:ae.accountId,deviceId:t},(function(){Object(o.c)("chatMqttConnected","true")}))).on("MESSAGE_RECEIVED",function(){var e=b(m().mark((function e(t){var n,r,i,a;return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(i=JSON.parse(null==t?void 0:t.payloadString),console.log("APPmessage",i,Ae),a=Object(o.b)("isometrikUserId"),"conversationCreated"!==(null==i?void 0:i.action)){e.next=15;break}return e.prev=4,e.next=7,s().Conversation.putConversationLastread({conversationId:null==i?void 0:i.conversationId,timestamp:Date.now()});case 7:Pe(i),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),Pe(i);case 13:e.next=16;break;case 15:"conversationDetailsUpdated"===(null==i?void 0:i.action)||"userBlockConversation"===(null==i?void 0:i.action)||"userUnblockConversation"===(null==i?void 0:i.action)||"messageDetailsUpdated"===(null==i?void 0:i.action)?(We((function(e){var t=e.conversations?d(e.conversations):[],n=t.findIndex((function(e){return e.conversationId===i.conversationId}));return-1!==n?(console.log(null==i?void 0:i.action,"message?.action"),"userBlockConversation"===(null==i?void 0:i.action)&&t.splice(n,1,f(f({},t[n]),{},{messagingDisabled:!0,updateBlockStatus:Date.now(),lastMessageDetails:f({},i)})),"userUnblockConversation"===(null==i?void 0:i.action)&&t.splice(n,1,f(f({},t[n]),{},{messagingDisabled:!1,updateBlockStatus:Date.now(),lastMessageDetails:f({},i)})),null!=i&&i.details&&t.splice(n,1,f(f(f({},t[n]),i.details),{},{lastMessageDetails:f({},i)})),f(f({},e),{},{conversations:t})):e})),null!=i&&i.details&&Pe(i)):Pe(i);case 16:"undefined"!=typeof window&&(null==i||null===(n=i.body)||void 0===n?void 0:n.length)>0&&(null==i?void 0:i.conversationId)!==(null===(r=window.location.search.split("="))||void 0===r?void 0:r[1])&&i.senderId!==a&&(s().message.putIndicateDelivered({messageId:i.messageId,conversationId:i.conversationId}),P(i,{state:Ge,setState:We})),We((function(e){if(null!=e&&e.messages&&Object.keys(null==e?void 0:e.messages).includes(null==i?void 0:i.conversationId)){var t;if((null==i||null===(t=i.body)||void 0===t?void 0:t.length)>0)return f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,[].concat(d(null==e?void 0:e.messages[null==i?void 0:i.conversationId]),[i])))});console.log(i,e.messages[null==i?void 0:i.conversationId]);var n=d(null==e?void 0:e.messages[null==i?void 0:i.conversationId]);return"multipleMessagesRead"!==(null==i?void 0:i.action)&&"messageRead"!==(null==i?void 0:i.action)||(n=n.map((function(e){if(e.userId!==e.senderId){var t=f({},e);return t.readBy=[{userId:i.userId,timestamp:i.lastReadAt}],t.readByAll=!0,t}return e}))),"messageDelivered"===(null==i?void 0:i.action)&&(n=n.map((function(e){if(e.userId!==e.senderId){var t=f({},e);return t.deliveredTo=[{userId:i.userId,timestamp:i.lastReadAt}],t.deliveredToAll=!0,t}return e}))),"messageDetailsUpdated"===(null==i?void 0:i.action)&&(n=n.map((function(e){if(i.messageId===e.messageId){var t=f(f({},e),i.details);return console.log("message details updated",i,e,t),t}return e}))),f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,d(n)))})}return f(f({},e),{},{messages:f(f({},null==e?void 0:e.messages),{},h({},null==i?void 0:i.conversationId,[i]))})}));case 18:case"end":return e.stop()}}),e,null,[[4,10]])})));return function(t){return e.apply(this,arguments)}}()),"undefined"!=typeof window&&(window.isoChatClient=a);case 12:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return Object(r.useEffect)((function(){var e;if(Object.keys(Re).length&&Re.body&&(null==Re?void 0:Re.senderId)!==Ze){var t="You have received a new message from ".concat(Re.senderName),n="".concat(null===(e=Object(i.h)(Re.body))||void 0===e?void 0:e.replace(/<br \/>/g,"")),r=l||s.a;try{!function(e,t,n){var r;null===(r=navigator)||void 0===r||null===(r=r.serviceWorker)||void 0===r||null===(r=r.ready)||void 0===r||null===(r=r.then((function(r){r.showNotification(e,{body:t,icon:n})})))||void 0===r||r.catch((function(e){return console.log("error while pushing notifications using sw - ",e)}))}(t,n,r)}catch(e){console.log("notify failed")}}}),[Re.body,l]),Object(r.useEffect)((function(){Object(o.c)("theme",de)}),[de]),Object(a.jsx)(_.Provider,{value:{theme:de,emojiIcon:c,attachFileIcon:v,sendIcon:g,recordIcon:y,dateFormat:E,showStatusMessages:k,hideHiddenConversations:T,sortByCustomType:A,allowMediaDownload:O,sidebarChatItem:Se,setSidebarChatItem:Ee,renderCustomMessage:x,onMessage:P,onConversationRead:D,onViewProfilleClick:Y,fetchUserToken:Je,baseImageUrl:Z,manageProfile:F,manageMessage:G,setTheme:pe,isometrikCreds:ae,setLoading:me,loading:ge,setUserloggedIn:we,userloggedIn:be,setUserDetails:Ce,userDetails:Ae,setShowLoader:ke,showLoader:Me,userId:Ze,findUserId:Re,setFindUserId:Pe,setState:We,currFilter:De,setCurrFilter:Ue,currChat:Fe,setCurrChat:Be,setIsSearchLoading:je,isSearchLoading:Te,state:Ge,renderCustomMessageSendForm:q,renderCustomChatMessageHeader:H,renderCustomChatListTile:K,renderChatMediaContainer:Q,renderDeleteDialog:ee,renderChatListFilter:te,renderLastMessage:$,showChatListFilter:re,documentUploadHandlerRef:oe,chatMessageAction:ie,isGroup:ue},children:t})},E=function(){return Object(r.useContext)(_)}},function(e,t,n){"use strict";e.exports=n(32)},function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return L}));var r=n(19),o=n.n(r),i=n(20),s=n.n(i);function a(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,u(e,t)}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t,n){return(l=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}()?Reflect.construct.bind():function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&u(o,n.prototype),o}).apply(null,arguments)}function f(e){var t="function"==typeof Map?new Map:void 0;return(f=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return l(e,arguments,c(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),u(n,e)})(e)}function h(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var d=function(e){function t(n,r){var o;return(o=e.call(this,r)||this).statusCode=void 0,Object.setPrototypeOf(h(o),(this instanceof t?this.constructor:void 0).prototype),o.name=Error.name,o.statusCode=n,Error.captureStackTrace(h(o)),o}return a(t,e),t}(f(Error)),p=function(e){function t(t,n){var r;return(r=e.call(this,400,"Conversation not found or not allowed to fetch messages count")||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n||0,r}return a(t,e),t}(d),v=function(e){function t(t,n){var r;return(r=e.call(this,404,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),g=function(e){function t(t){var n;return(n=e.call(this,503,"Service Unavailable")||this).errorMsg=void 0,n.errorMsg=t,n}return a(t,e),t}(d),m=function(e){function t(t,n){var r;return(r=e.call(this,422,"Unprocessable entity")||this).errorProperties=void 0,r.errorCode=void 0,r.errorProperties=t,r.errorCode=n||0,r}return a(t,e),t}(d),y=function(e){function t(t,n){var r;return(r=e.call(this,t,"Unknown Error Caught")||this).errorMsg=void 0,r.errorMsg=n,r}return a(t,e),t}(d),b=function(e){function t(t,n){var r;return(r=e.call(this,403,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),w=function(e){function t(t,n){var r;return(r=e.call(this,403,t)||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n,r}return a(t,e),t}(d),_=function(e){function t(t,n){var r;return(r=e.call(this,400,"Conversation not found or not allowed to fetch messages count")||this).errorMsg=void 0,r.errorCode=void 0,r.errorMsg=t,r.errorCode=n||0,r}return a(t,e),t}(d),S=function(){function e(e){this.baseUrl=void 0,this.licenseKey=void 0,this.appSecret=void 0,this.userSecret=void 0,this.userToken=void 0,this.baseUrl=e.baseUrl,this.licenseKey=e.licenseKey,this.appSecret=e.appSecret,this.userSecret=e.userSecret,this.userToken=e.userToken||void 0}var t=e.prototype;return t.updateUserToken=function(e){this.userToken=e},t.invoke=function(e,t){try{return Promise.resolve(function(n,r){try{var i=Promise.resolve(o()(e,t)).then((function(e){if(e.ok)return e.json();var t=new Error(e.statusText);throw t.response=e,t}))}catch(e){return r(e)}return i&&i.then?i.then(void 0,r):i}(0,(function(e){var t=e.response.status;return Promise.resolve(e.response.json()).then((function(e){switch(t){case 400:throw new p(e.error);case 401:throw new w(e.error,e.errorCode);case 403:throw new b(e.error,e.errorCode);case 404:throw new v(e.error,e.errorCode);case 409:throw new _(e.error,e.errorCode);case 422:throw new m(e.errors);case 503:throw new g(e.error);default:throw new y(t,e.error)}}))})))}catch(e){return Promise.reject(e)}},t.get=function(e,t){void 0===t&&(t=!1);var n=""+this.baseUrl+e,r={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};return t&&(r.userSecret=this.userSecret),this.invoke(n,{headers:r})},t.post=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"POST",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.put=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"PUT",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.patch=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"PATCH",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},t.delete=function(e,t,n){void 0===n&&(n=!1);var r=""+this.baseUrl+e,o={"Content-type":"application/json",licenseKey:this.licenseKey,appSecret:this.appSecret,userToken:this.userToken};n&&(o.userSecret=this.userSecret);var i={method:"DELETE",body:JSON.stringify(t),headers:o};return this.invoke(r,i)},e}(),E="chat/messages",I=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getMessagesForUser=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/user?"+t)},t.getMessagesForMentioned=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/user?"+t)},t.getMessagesCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/count?"+t)},t.getMessages=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"?"+t)},t.postMessages=function(e){return this.base.post("/chat/message",e)},t.patchMessages=function(e){return this.base.patch("/chat/message",e)},t.postMessagesPresignedurls=function(e){return this.base.post("/chat/messages/presignedurls",e)},t.getMessageReactionType=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/"+t+"?"+n)},t.postReaction=function(e){return this.base.post("/chat/reaction",e)},t.deleteReactionType=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/reaction/"+t+"?"+n)},t.postMessagesForward=function(e){return this.base.post("/chat/message/forward",e)},t.postMessagesbroadcast=function(e){return this.base.post("/chat/message/broadcast",e)},t.getStatus=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/status?"+t)},t.getStatusReadPending=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/read/pending?"+t)},t.getStatusRead=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/read?"+t)},t.getStatusDeliveryPending=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/delivery/pending?"+t)},t.getStatusDelivery=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/message/status/delivery?"+t)},t.postIndicateTyping=function(e){return this.base.post("/chat/indicator/typing",e)},t.putIndicateRead=function(e){return this.base.put("/chat/indicator/read",e)},t.putIndicateDelivered=function(e){return this.base.put("/chat/indicator/delivered",e)},t.getUnreadCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/unread/count?"+t)},t.getUnread=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+E+"/unread?"+t)},t.putRead=function(e){return this.base.put("/"+E+"/read",e)},t.deleteMessageSelf=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/"+E+"/self?"+t)},t.deleteMessagesEveryone=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/"+E+"/everyone?"+t)},e}(),A="chat/conversations",C=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getWatchers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/watchers?"+t)},t.getPublicOrOpen=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/watchers?"+t)},t.getConversationDetails=function(e,t){var n=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/details/"+t+"?"+n)},t.getConversationCount=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/count?"+t)},t.getConversations=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"?"+t)},t.getUnreadConversations=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/"+A+"/unread?"+t)},t.getMessagingStatus=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/messaging/status?"+t)},t.postConversation=function(e){return this.base.post("/chat/conversation",e)},t.patchTitle=function(e){return this.base.patch("/chat/conversation/title",e)},t.patchSettings=function(e){return this.base.patch("/chat/conversation/settings",e)},t.patchImage=function(e){return this.base.patch("/chat/conversation/image",e)},t.patchDetails=function(e){return this.base.patch("/chat/conversation/details",e)},t.getConversationPresignedurl=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/presignedurl?"+t)},t.getStatusRead=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/status/read?"+t)},t.getObserver=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/members?"+t)},t.deleteObserverLeave=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/observer/leave?"+t)},t.putObserverJoin=function(e){return this.base.put("/chat/conversation/observer/join",e)},t.putMembers=function(e){return this.base.put("/chat/conversation/members",e)},t.getConversationMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/members?"+t)},t.deleteConversationMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/members?"+t)},t.getConversationMemberDetails=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/member/details?"+t)},t.getConversationEligibleMembers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/conversation/eligible/members?"+t)},t.deleteConversationLeave=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/leave?"+t)},t.putConversationJoin=function(e){return this.base.put("/chat/conversation/join",e)},t.putConversationAdmin=function(e){return this.base.put("/chat/conversation/admin",e)},t.deleteConversationAdmin=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/admin?"+t)},t.getConversationUnreadCount=function(){return this.base.get("/"+A+"/unread/count")},t.putConversationLastread=function(e){return this.base.put("/chat/conversation/lastread",e)},t.deleteConversationClear=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/local?"+t)},t.deleteConversationLocal=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.delete("/chat/conversation/clear?"+t)},e}(),O=function(){function e(e){this.base=void 0,this.base=new S(e)}var t=e.prototype;return t.getUsers=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/users?"+t,!0)},t.getUserDetails=function(){return this.base.get("/chat/user/details")},t.postUserAuthenticate=function(e){var t=this,n=this.base.post("/chat/user/authenticate",e,!0);return n.then((function(e){t.base.updateUserToken(e.userToken)})),n},t.setUserToken=function(e){this.base.updateUserToken(e)},t.postUser=function(e){return this.base.post("/chat/user",e,!0)},t.patchUser=function(e){return this.base.patch("/chat/user",e)},t.deleteUser=function(){return this.base.delete("/chat/user")},t.postUserUnblock=function(e){return this.base.post("/chat/user/unblock",e)},t.getUserNonblock=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/nonblock?"+t)},t.getUserblockCount=function(){return this.base.get("/chat/user/block/count")},t.postUserBlock=function(e){return this.base.post("/chat/user/block",e)},t.getUserBlock=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/block?"+t)},t.getPresignedurlUpdate=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/presignedurl/update?"+t)},t.getPresignedurlCreate=function(e){var t=e?Object.keys(e).map((function(t){return t+"="+e[t]})).join("&"):"";return this.base.get("/chat/user/presignedurl/update?"+t)},e}(),M=function(){function e(e){var t=this;this.hostUri=void 0,this.clientId=void 0,this.client=void 0,this.licenseKey=void 0,this.projectId=void 0,this.keysetId=void 0,this.accountId=void 0,this.deviceId=void 0,this.hostUri=e.hostUri,this.clientId=e.clientId,this.deviceId=e.deviceId,this.licenseKey=e.licenseKey,this.projectId=e.projectId,this.keysetId=e.keysetId,this.accountId=e.accountId,this.client=new s.a.Client(this.hostUri,this.clientId+this.deviceId),this.client.connect({userName:"2"+this.accountId+this.projectId,password:this.licenseKey+this.keysetId,useSSL:!0,mqttVersion:3,keepAliveInterval:30,cleanSession:!0,reconnect:!0,onFailure:function(e){console.log("Failed COnnection ---\x3e",e,"is the error"),console.log(t,"username","1"+t.accountId+t.projectId,"pass",t.licenseKey+t.keysetId)},onSuccess:function(e){console.log("Isometrick MQTT Connected !!",t.client);try{t.client.subscribe("/"+t.accountId+"/"+t.projectId+"/Message/"+t.clientId,{qos:0,onSuccess:function(e){console.log("Subscribed Successfully:: =>> Message",e)},onFailure:function(e){console.log("Subscribed Failed || >>",e)}}),t.client.subscribe("/"+t.accountId+"/"+t.projectId+"/Status/"+t.clientId,{qos:0,onSuccess:function(e){console.log("Subscribed Successfully:: =>> Status",e)},onFailure:function(e){console.log("Subscribed Failed || >>",e)}})}catch(e){console.error(e)}}})}var t=e.prototype;return t.on=function(e,t){switch(e){case"MESSAGE_RECEIVED":this.client.onMessageArrived=t;break;case"CONNECTION_LOST":this.client.onConnectionLost=t}},t.disconnect=function(){this.client.disconnect()},t.getInstance=function(){return this.client},e}(),k={BadRequestError:p,ConflictError:_,ForbiddenErrorRequest:b,NotFoundError:v,ServiceUnavailableError:g,UnauthorizedError:w,UnknownError:y,UnprocessableEntityError:m},L=function(){function e(e){this.message=void 0,this.Conversation=void 0,this.user=void 0,this.error=void 0,this.message=new I(e),this.Conversation=new C(e),this.user=new O(e),this.error=k}return e.getInstance=function(){if(null!==e.instance)return e.instance;throw new Error("Need to initialize instance first!")},e.initializeInstance=function(t){return null===e.instance&&(e.instance=new e(t)),e.instance},e.prototype.initializeMqtt=function(e){return new M(e)},e}();L.instance=null},function(e,t,n){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,"a",(function(){return r}))},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";var r=n(10),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},s={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};function c(e){return r.isMemo(e)?s:a[e.$$typeof]||o}a[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},a[r.Memo]=s;var u=Object.defineProperty,l=Object.getOwnPropertyNames,f=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var o=d(n);o&&o!==p&&e(t,o,r)}var s=l(n);f&&(s=s.concat(f(n)));for(var a=c(t),v=c(n),g=0;g<s.length;++g){var m=s[g];if(!(i[m]||r&&r[m]||v&&v[m]||a&&a[m])){var y=h(n,m);try{u(t,m,y)}catch(e){}}}}return t}},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/arrow_logo.svg"},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function o(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)}n.d(t,"a",(function(){return o}))},function(e,t,n){"use strict";n.r(t),t.default=function(e,t){return t=t||{},new Promise((function(n,r){var o=new XMLHttpRequest,i=[],s=[],a={},c=function(){return{ok:2==(o.status/100|0),statusText:o.statusText,status:o.status,url:o.responseURL,text:function(){return Promise.resolve(o.responseText)},json:function(){return Promise.resolve(o.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([o.response]))},clone:c,headers:{keys:function(){return i},entries:function(){return s},get:function(e){return a[e.toLowerCase()]},has:function(e){return e.toLowerCase()in a}}}};for(var u in o.open(t.method||"get",e,!0),o.onload=function(){o.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,t,n){i.push(t=t.toLowerCase()),s.push([t,n]),a[t]=a[t]?a[t]+","+n:n})),n(c())},o.onerror=r,o.withCredentials="include"==t.credentials,t.headers)o.setRequestHeader(u,t.headers[u]);o.send(t.body||null)}))}},function(e,t,n){"use strict";var r=n(0),o=n.n(r),i=n(24),s=n(2),a=n.n(s),c=Object(i.a)({resolved:{},chunkName:function(){return"pages-WhatsappMainBox"},isReady:function(e){var t=this.resolve(e);return!0===this.resolved[t]&&!!n.m[t]},importAsync:function(){return Promise.all([n.e(2),n.e(1)]).then(n.bind(null,26))},requireAsync:function(e){var t=this,n=this.resolve(e);return this.resolved[n]=!1,this.importAsync(e).then((function(e){return t.resolved[n]=!0,e}))},requireSync:function e(t){var r=this.resolve(t);return n(r)},resolve:function e(){return 26}}),u=function(e){var t=e.showSideBarSearch,n=void 0===t||t,r=e.attachMentPosition,o=void 0===r?"right":r,i=e.sortConversationList,a=e.renderSelfMoremenu,u=e.showSearchIcon,l=void 0===u||u,f=e.ChatFooterRightSlot,h=void 0===f?function(){return Object(s.jsx)(s.Fragment,{})}:f,d=e.customSendOptions,p=void 0!==d&&d,v=e.RenderCustomSendOptions,g=void 0===v?function(){return Object(s.jsx)(s.Fragment,{})}:v,m=e.showSideChatHeader,y=e.extraAttachmentOptions,b=void 0===y?[]:y,w=e.renderProfileBadge,_=void 0===w?function(e){return Object(s.jsx)(s.Fragment,{})}:w,S=e.customSend,E=void 0!==S&&S,I=e.handleCustomSend,A=void 0===I?function(){return!1}:I,C=e.sideBarHeaderSlot,O=e.chatHeaderRightSlot,M=e.chatHeaderMoreMenu,k=e.onChatChange,L=e.placeHolder,T=e.sideBarPlaceHolder,j=e.allowProfileClick,x=void 0===j||j,R=e.onNewConversation;return Object(s.jsx)(s.Fragment,{children:Object(s.jsx)("div",{className:"isoChat",children:Object(s.jsx)(c,{onNewConversation:R,showSideBarSearch:n,allowProfileClick:x,sortConversationList:i,renderSelfMoremenu:a,showSearchIcon:l,attachMentPosition:o,ChatFooterRightSlot:h,customSendOptions:p,RenderCustomSendOptions:g,extraAttachmentOptions:b,customSend:E,renderProfileBadge:_,handleCustomSend:A,sideBarHeaderSlot:C,chatHeaderRightSlot:O,chatHeaderMoreMenu:M,sideBarPlaceHolder:T,showSideChatHeader:m,onChatChange:k,placeHolder:L})})})};t.a=u},function(e,t,n){e.exports=self.fetch||(self.fetch=n(17).default||n(17))},function(e,t,n){(function(t){var n;n=function(){return function(e){var t,n=e.localStorage||(t={},{setItem:function(e,n){t[e]=n},getItem:function(e){return t[e]},removeItem:function(e){delete t[e]}}),r=1,o=2,i=3,s=4,a=5,c=6,u=7,l=8,f=9,h=10,d=11,p=12,v=13,g=14,m=function(e,t){for(var n in e)if(e.hasOwnProperty(n)){if(!t.hasOwnProperty(n)){var r="Unknown property, "+n+". Valid properties are:";for(var o in t)t.hasOwnProperty(o)&&(r=r+" "+o);throw new Error(r)}if(typeof e[n]!==t[n])throw new Error(_(b.INVALID_TYPE,[typeof e[n],n]))}},y=function(e,t){return function(){return e.apply(t,arguments)}},b={OK:{code:0,text:"AMQJSC0000I OK."},CONNECT_TIMEOUT:{code:1,text:"AMQJSC0001E Connect timed out."},SUBSCRIBE_TIMEOUT:{code:2,text:"AMQJS0002E Subscribe timed out."},UNSUBSCRIBE_TIMEOUT:{code:3,text:"AMQJS0003E Unsubscribe timed out."},PING_TIMEOUT:{code:4,text:"AMQJS0004E Ping timed out."},INTERNAL_ERROR:{code:5,text:"AMQJS0005E Internal error. Error Message: {0}, Stack trace: {1}"},CONNACK_RETURNCODE:{code:6,text:"AMQJS0006E Bad Connack return code:{0} {1}."},SOCKET_ERROR:{code:7,text:"AMQJS0007E Socket error:{0}."},SOCKET_CLOSE:{code:8,text:"AMQJS0008I Socket closed."},MALFORMED_UTF:{code:9,text:"AMQJS0009E Malformed UTF data:{0} {1} {2}."},UNSUPPORTED:{code:10,text:"AMQJS0010E {0} is not supported by this browser."},INVALID_STATE:{code:11,text:"AMQJS0011E Invalid state {0}."},INVALID_TYPE:{code:12,text:"AMQJS0012E Invalid type {0} for {1}."},INVALID_ARGUMENT:{code:13,text:"AMQJS0013E Invalid argument {0} for {1}."},UNSUPPORTED_OPERATION:{code:14,text:"AMQJS0014E Unsupported operation."},INVALID_STORED_DATA:{code:15,text:"AMQJS0015E Invalid data in local storage key={0} value={1}."},INVALID_MQTT_MESSAGE_TYPE:{code:16,text:"AMQJS0016E Invalid MQTT message type {0}."},MALFORMED_UNICODE:{code:17,text:"AMQJS0017E Malformed Unicode string:{0} {1}."},BUFFER_FULL:{code:18,text:"AMQJS0018E Message buffer is full, maximum buffer size: {0}."}},w={0:"Connection Accepted",1:"Connection Refused: unacceptable protocol version",2:"Connection Refused: identifier rejected",3:"Connection Refused: server unavailable",4:"Connection Refused: bad user name or password",5:"Connection Refused: not authorized"},_=function(e,t){var n=e.text;if(t)for(var r,o,i=0;i<t.length;i++)if(r="{"+i+"}",(o=n.indexOf(r))>0){var s=n.substring(0,o),a=n.substring(o+r.length);n=s+t[i]+a}return n},S=[0,6,77,81,73,115,100,112,3],E=[0,4,77,81,84,84,4],I=function(e,t){for(var n in this.type=e,t)t.hasOwnProperty(n)&&(this[n]=t[n])};function A(e,t){var n,r=t,l=e[t],h=l>>4,p=l&=15;t+=1;var v=0,g=1;do{if(t==e.length)return[null,r];v+=(127&(n=e[t++]))*g,g*=128}while(0!=(128&n));var m=t+v;if(m>e.length)return[null,r];var y=new I(h);switch(h){case o:1&e[t++]&&(y.sessionPresent=!0),y.returnCode=e[t++];break;case i:var b=p>>1&3,w=M(e,t),_=T(e,t+=2,w);t+=w,b>0&&(y.messageIdentifier=M(e,t),t+=2);var S=new P(e.subarray(t,m));1==(1&p)&&(S.retained=!0),8==(8&p)&&(S.duplicate=!0),S.qos=b,S.destinationName=_,y.payloadMessage=S;break;case s:case a:case c:case u:case d:y.messageIdentifier=M(e,t);break;case f:y.messageIdentifier=M(e,t),t+=2,y.returnCode=e.subarray(t,m)}return[y,m]}function C(e,t,n){return t[n++]=e>>8,t[n++]=e%256,n}function O(e,t,n,r){return L(e,n,r=C(t,n,r)),r+t}function M(e,t){return 256*e[t]+e[t+1]}function k(e){for(var t=0,n=0;n<e.length;n++){var r=e.charCodeAt(n);r>2047?(55296<=r&&r<=56319&&(n++,t++),t+=3):r>127?t+=2:t++}return t}function L(e,t,n){for(var r=n,o=0;o<e.length;o++){var i=e.charCodeAt(o);if(55296<=i&&i<=56319){var s=e.charCodeAt(++o);if(isNaN(s))throw new Error(_(b.MALFORMED_UNICODE,[i,s]));i=s-56320+(i-55296<<10)+65536}i<=127?t[r++]=i:i<=2047?(t[r++]=i>>6&31|192,t[r++]=63&i|128):i<=65535?(t[r++]=i>>12&15|224,t[r++]=i>>6&63|128,t[r++]=63&i|128):(t[r++]=i>>18&7|240,t[r++]=i>>12&63|128,t[r++]=i>>6&63|128,t[r++]=63&i|128)}return t}function T(e,t,n){for(var r,o="",i=t;i<t+n;){var s=e[i++];if(s<128)r=s;else{var a=e[i++]-128;if(a<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),""]));if(s<224)r=64*(s-192)+a;else{var c=e[i++]-128;if(c<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16)]));if(s<240)r=4096*(s-224)+64*a+c;else{var u=e[i++]-128;if(u<0)throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16),u.toString(16)]));if(!(s<248))throw new Error(_(b.MALFORMED_UTF,[s.toString(16),a.toString(16),c.toString(16),u.toString(16)]));r=262144*(s-240)+4096*a+64*c+u}}}r>65535&&(r-=65536,o+=String.fromCharCode(55296+(r>>10)),r=56320+(1023&r)),o+=String.fromCharCode(r)}return o}I.prototype.encode=function(){var e,t=(15&this.type)<<4,n=0,o=[],s=0;switch(void 0!==this.messageIdentifier&&(n+=2),this.type){case r:switch(this.mqttVersion){case 3:n+=S.length+3;break;case 4:n+=E.length+3}n+=k(this.clientId)+2,void 0!==this.willMessage&&(n+=k(this.willMessage.destinationName)+2,(e=this.willMessage.payloadBytes)instanceof Uint8Array||(e=new Uint8Array(u)),n+=e.byteLength+2),void 0!==this.userName&&(n+=k(this.userName)+2),void 0!==this.password&&(n+=k(this.password)+2);break;case l:t|=2;for(var a=0;a<this.topics.length;a++)o[a]=k(this.topics[a]),n+=o[a]+2;n+=this.requestedQos.length;break;case h:for(t|=2,a=0;a<this.topics.length;a++)o[a]=k(this.topics[a]),n+=o[a]+2;break;case c:t|=2;break;case i:this.payloadMessage.duplicate&&(t|=8),t=t|=this.payloadMessage.qos<<1,this.payloadMessage.retained&&(t|=1),n+=(s=k(this.payloadMessage.destinationName))+2;var u=this.payloadMessage.payloadBytes;n+=u.byteLength,u instanceof ArrayBuffer?u=new Uint8Array(u):u instanceof Uint8Array||(u=new Uint8Array(u.buffer))}var f=function(e){var t=new Array(1),n=0;do{var r=e%128;(e>>=7)>0&&(r|=128),t[n++]=r}while(e>0&&n<4);return t}(n),d=f.length+1,p=new ArrayBuffer(n+d),v=new Uint8Array(p);if(v[0]=t,v.set(f,1),this.type==i)d=O(this.payloadMessage.destinationName,s,v,d);else if(this.type==r){switch(this.mqttVersion){case 3:v.set(S,d),d+=S.length;break;case 4:v.set(E,d),d+=E.length}var g=0;this.cleanSession&&(g=2),void 0!==this.willMessage&&(g|=4,g|=this.willMessage.qos<<3,this.willMessage.retained&&(g|=32)),void 0!==this.userName&&(g|=128),void 0!==this.password&&(g|=64),v[d++]=g,d=C(this.keepAliveInterval,v,d)}switch(void 0!==this.messageIdentifier&&(d=C(this.messageIdentifier,v,d)),this.type){case r:d=O(this.clientId,k(this.clientId),v,d),void 0!==this.willMessage&&(d=O(this.willMessage.destinationName,k(this.willMessage.destinationName),v,d),d=C(e.byteLength,v,d),v.set(e,d),d+=e.byteLength),void 0!==this.userName&&(d=O(this.userName,k(this.userName),v,d)),void 0!==this.password&&(d=O(this.password,k(this.password),v,d));break;case i:v.set(u,d);break;case l:for(a=0;a<this.topics.length;a++)d=O(this.topics[a],o[a],v,d),v[d++]=this.requestedQos[a];break;case h:for(a=0;a<this.topics.length;a++)d=O(this.topics[a],o[a],v,d)}return p};var j=function(e,t){this._client=e,this._keepAliveInterval=1e3*t,this.isReset=!1;var n=new I(p).encode(),r=function(e){return function(){return o.apply(e)}},o=function(){this.isReset?(this.isReset=!1,this._client._trace("Pinger.doPing","send PINGREQ"),this._client.socket.send(n),this.timeout=setTimeout(r(this),this._keepAliveInterval)):(this._client._trace("Pinger.doPing","Timed out"),this._client._disconnected(b.PING_TIMEOUT.code,_(b.PING_TIMEOUT)))};this.reset=function(){this.isReset=!0,clearTimeout(this.timeout),this._keepAliveInterval>0&&(this.timeout=setTimeout(r(this),this._keepAliveInterval))},this.cancel=function(){clearTimeout(this.timeout)}},x=function(e,t,n,r){t||(t=30),this.timeout=setTimeout(function(e,t,n){return function(){return e.apply(t,n)}}(n,e,r),1e3*t),this.cancel=function(){clearTimeout(this.timeout)}},R=function(t,r,o,i,s){if(!("WebSocket"in e)||null===e.WebSocket)throw new Error(_(b.UNSUPPORTED,["WebSocket"]));if(!("ArrayBuffer"in e)||null===e.ArrayBuffer)throw new Error(_(b.UNSUPPORTED,["ArrayBuffer"]));for(var a in this._trace("Paho.Client",t,r,o,i,s),this.host=r,this.port=o,this.path=i,this.uri=t,this.clientId=s,this._wsuri=null,this._localKey=r+":"+o+("/mqtt"!=i?":"+i:"")+":"+s+":",this._msg_queue=[],this._buffered_msg_queue=[],this._sentMessages={},this._receivedMessages={},this._notify_msg_sent={},this._message_identifier=1,this._sequence=0,n)0!==a.indexOf("Sent:"+this._localKey)&&0!==a.indexOf("Received:"+this._localKey)||this.restore(a)};R.prototype.host=null,R.prototype.port=null,R.prototype.path=null,R.prototype.uri=null,R.prototype.clientId=null,R.prototype.socket=null,R.prototype.connected=!1,R.prototype.maxMessageIdentifier=65536,R.prototype.connectOptions=null,R.prototype.hostIndex=null,R.prototype.onConnected=null,R.prototype.onConnectionLost=null,R.prototype.onMessageDelivered=null,R.prototype.onMessageArrived=null,R.prototype.traceFunction=null,R.prototype._msg_queue=null,R.prototype._buffered_msg_queue=null,R.prototype._connectTimeout=null,R.prototype.sendPinger=null,R.prototype.receivePinger=null,R.prototype._reconnectInterval=1,R.prototype._reconnecting=!1,R.prototype._reconnectTimeout=null,R.prototype.disconnectedPublishing=!1,R.prototype.disconnectedBufferSize=5e3,R.prototype.receiveBuffer=null,R.prototype._traceBuffer=null,R.prototype._MAX_TRACE_ENTRIES=100,R.prototype.connect=function(e){var t=this._traceMask(e,"password");if(this._trace("Client.connect",t,this.socket,this.connected),this.connected)throw new Error(_(b.INVALID_STATE,["already connected"]));if(this.socket)throw new Error(_(b.INVALID_STATE,["already connected"]));this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),this.connectOptions=e,this._reconnectInterval=1,this._reconnecting=!1,e.uris?(this.hostIndex=0,this._doConnect(e.uris[0])):this._doConnect(this.uri)},R.prototype.subscribe=function(e,t){if(this._trace("Client.subscribe",e,t),!this.connected)throw new Error(_(b.INVALID_STATE,["not connected"]));var n=new I(l);n.topics=e.constructor===Array?e:[e],void 0===t.qos&&(t.qos=0),n.requestedQos=[];for(var r=0;r<n.topics.length;r++)n.requestedQos[r]=t.qos;t.onSuccess&&(n.onSuccess=function(e){t.onSuccess({invocationContext:t.invocationContext,grantedQos:e})}),t.onFailure&&(n.onFailure=function(e){t.onFailure({invocationContext:t.invocationContext,errorCode:e,errorMessage:_(e)})}),t.timeout&&(n.timeOut=new x(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:b.SUBSCRIBE_TIMEOUT.code,errorMessage:_(b.SUBSCRIBE_TIMEOUT)}])),this._requires_ack(n),this._schedule_message(n)},R.prototype.unsubscribe=function(e,t){if(this._trace("Client.unsubscribe",e,t),!this.connected)throw new Error(_(b.INVALID_STATE,["not connected"]));var n=new I(h);n.topics=e.constructor===Array?e:[e],t.onSuccess&&(n.callback=function(){t.onSuccess({invocationContext:t.invocationContext})}),t.timeout&&(n.timeOut=new x(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:b.UNSUBSCRIBE_TIMEOUT.code,errorMessage:_(b.UNSUBSCRIBE_TIMEOUT)}])),this._requires_ack(n),this._schedule_message(n)},R.prototype.send=function(e){this._trace("Client.send",e);var t=new I(i);if(t.payloadMessage=e,this.connected)e.qos>0?this._requires_ack(t):this.onMessageDelivered&&(this._notify_msg_sent[t]=this.onMessageDelivered(t.payloadMessage)),this._schedule_message(t);else{if(!this._reconnecting||!this.disconnectedPublishing)throw new Error(_(b.INVALID_STATE,["not connected"]));if(Object.keys(this._sentMessages).length+this._buffered_msg_queue.length>this.disconnectedBufferSize)throw new Error(_(b.BUFFER_FULL,[this.disconnectedBufferSize]));e.qos>0?this._requires_ack(t):(t.sequence=++this._sequence,this._buffered_msg_queue.unshift(t))}},R.prototype.disconnect=function(){if(this._trace("Client.disconnect"),this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),!this.socket)throw new Error(_(b.INVALID_STATE,["not connecting or connected"]));var e=new I(g);this._notify_msg_sent[e]=y(this._disconnected,this),this._schedule_message(e)},R.prototype.getTraceLog=function(){if(null!==this._traceBuffer){for(var e in this._trace("Client.getTraceLog",new Date),this._trace("Client.getTraceLog in flight messages",this._sentMessages.length),this._sentMessages)this._trace("_sentMessages ",e,this._sentMessages[e]);for(var e in this._receivedMessages)this._trace("_receivedMessages ",e,this._receivedMessages[e]);return this._traceBuffer}},R.prototype.startTrace=function(){null===this._traceBuffer&&(this._traceBuffer=[]),this._trace("Client.startTrace",new Date,"@VERSION@-@BUILDLEVEL@")},R.prototype.stopTrace=function(){delete this._traceBuffer},R.prototype._doConnect=function(e){if(this.connectOptions.useSSL){var t=e.split(":");t[0]="wss",e=t.join(":")}this._wsuri=e,this.connected=!1,this.connectOptions.mqttVersion<4?this.socket=new WebSocket(e,["mqttv3.1"]):this.socket=new WebSocket(e,["mqtt"]),this.socket.binaryType="arraybuffer",this.socket.onopen=y(this._on_socket_open,this),this.socket.onmessage=y(this._on_socket_message,this),this.socket.onerror=y(this._on_socket_error,this),this.socket.onclose=y(this._on_socket_close,this),this.sendPinger=new j(this,this.connectOptions.keepAliveInterval),this.receivePinger=new j(this,this.connectOptions.keepAliveInterval),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._connectTimeout=new x(this,this.connectOptions.timeout,this._disconnected,[b.CONNECT_TIMEOUT.code,_(b.CONNECT_TIMEOUT)])},R.prototype._schedule_message=function(e){this._msg_queue.unshift(e),this.connected&&this._process_queue()},R.prototype.store=function(e,t){var r={type:t.type,messageIdentifier:t.messageIdentifier,version:1};switch(t.type){case i:t.pubRecReceived&&(r.pubRecReceived=!0),r.payloadMessage={};for(var o="",s=t.payloadMessage.payloadBytes,a=0;a<s.length;a++)s[a]<=15?o=o+"0"+s[a].toString(16):o+=s[a].toString(16);r.payloadMessage.payloadHex=o,r.payloadMessage.qos=t.payloadMessage.qos,r.payloadMessage.destinationName=t.payloadMessage.destinationName,t.payloadMessage.duplicate&&(r.payloadMessage.duplicate=!0),t.payloadMessage.retained&&(r.payloadMessage.retained=!0),0===e.indexOf("Sent:")&&(void 0===t.sequence&&(t.sequence=++this._sequence),r.sequence=t.sequence);break;default:throw Error(_(b.INVALID_STORED_DATA,[e+this._localKey+t.messageIdentifier,r]))}n.setItem(e+this._localKey+t.messageIdentifier,JSON.stringify(r))},R.prototype.restore=function(e){var t=n.getItem(e),r=JSON.parse(t),o=new I(r.type,r);switch(r.type){case i:for(var s=r.payloadMessage.payloadHex,a=new ArrayBuffer(s.length/2),c=new Uint8Array(a),u=0;s.length>=2;){var l=parseInt(s.substring(0,2),16);s=s.substring(2,s.length),c[u++]=l}var f=new P(c);f.qos=r.payloadMessage.qos,f.destinationName=r.payloadMessage.destinationName,r.payloadMessage.duplicate&&(f.duplicate=!0),r.payloadMessage.retained&&(f.retained=!0),o.payloadMessage=f;break;default:throw Error(_(b.INVALID_STORED_DATA,[e,t]))}0===e.indexOf("Sent:"+this._localKey)?(o.payloadMessage.duplicate=!0,this._sentMessages[o.messageIdentifier]=o):0===e.indexOf("Received:"+this._localKey)&&(this._receivedMessages[o.messageIdentifier]=o)},R.prototype._process_queue=function(){for(var e=null;e=this._msg_queue.pop();)this._socket_send(e),this._notify_msg_sent[e]&&(this._notify_msg_sent[e](),delete this._notify_msg_sent[e])},R.prototype._requires_ack=function(e){var t=Object.keys(this._sentMessages).length;if(t>this.maxMessageIdentifier)throw Error("Too many messages:"+t);for(;void 0!==this._sentMessages[this._message_identifier];)this._message_identifier++;e.messageIdentifier=this._message_identifier,this._sentMessages[e.messageIdentifier]=e,e.type===i&&this.store("Sent:",e),this._message_identifier===this.maxMessageIdentifier&&(this._message_identifier=1)},R.prototype._on_socket_open=function(){var e=new I(r,this.connectOptions);e.clientId=this.clientId,this._socket_send(e)},R.prototype._on_socket_message=function(e){this._trace("Client._on_socket_message",e.data);for(var t=this._deframeMessages(e.data),n=0;n<t.length;n+=1)this._handleMessage(t[n])},R.prototype._deframeMessages=function(e){var t=new Uint8Array(e),n=[];if(this.receiveBuffer){var r=new Uint8Array(this.receiveBuffer.length+t.length);r.set(this.receiveBuffer),r.set(t,this.receiveBuffer.length),t=r,delete this.receiveBuffer}try{for(var o=0;o<t.length;){var i=A(t,o),s=i[0];if(o=i[1],null===s)break;n.push(s)}o<t.length&&(this.receiveBuffer=t.subarray(o))}catch(e){var a="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(b.INTERNAL_ERROR.code,_(b.INTERNAL_ERROR,[e.message,a]))}return n},R.prototype._handleMessage=function(e){this._trace("Client._handleMessage",e);try{switch(e.type){case o:if(this._connectTimeout.cancel(),this._reconnectTimeout&&this._reconnectTimeout.cancel(),this.connectOptions.cleanSession){for(var t in this._sentMessages){var r=this._sentMessages[t];n.removeItem("Sent:"+this._localKey+r.messageIdentifier)}for(var t in this._sentMessages={},this._receivedMessages){var l=this._receivedMessages[t];n.removeItem("Received:"+this._localKey+l.messageIdentifier)}this._receivedMessages={}}if(0!==e.returnCode){this._disconnected(b.CONNACK_RETURNCODE.code,_(b.CONNACK_RETURNCODE,[e.returnCode,w[e.returnCode]]));break}this.connected=!0,this.connectOptions.uris&&(this.hostIndex=this.connectOptions.uris.length);var h=[];for(var p in this._sentMessages)this._sentMessages.hasOwnProperty(p)&&h.push(this._sentMessages[p]);if(this._buffered_msg_queue.length>0)for(var m=null;m=this._buffered_msg_queue.pop();)h.push(m),this.onMessageDelivered&&(this._notify_msg_sent[m]=this.onMessageDelivered(m.payloadMessage));h=h.sort((function(e,t){return e.sequence-t.sequence}));for(var y=0,S=h.length;y<S;y++)if((r=h[y]).type==i&&r.pubRecReceived){var E=new I(c,{messageIdentifier:r.messageIdentifier});this._schedule_message(E)}else this._schedule_message(r);this.connectOptions.onSuccess&&this.connectOptions.onSuccess({invocationContext:this.connectOptions.invocationContext});var A=!1;this._reconnecting&&(A=!0,this._reconnectInterval=1,this._reconnecting=!1),this._connected(A,this._wsuri),this._process_queue();break;case i:this._receivePublish(e);break;case s:(r=this._sentMessages[e.messageIdentifier])&&(delete this._sentMessages[e.messageIdentifier],n.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(r.payloadMessage));break;case a:(r=this._sentMessages[e.messageIdentifier])&&(r.pubRecReceived=!0,E=new I(c,{messageIdentifier:e.messageIdentifier}),this.store("Sent:",r),this._schedule_message(E));break;case c:l=this._receivedMessages[e.messageIdentifier],n.removeItem("Received:"+this._localKey+e.messageIdentifier),l&&(this._receiveMessage(l),delete this._receivedMessages[e.messageIdentifier]);var C=new I(u,{messageIdentifier:e.messageIdentifier});this._schedule_message(C);break;case u:r=this._sentMessages[e.messageIdentifier],delete this._sentMessages[e.messageIdentifier],n.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(r.payloadMessage);break;case f:(r=this._sentMessages[e.messageIdentifier])&&(r.timeOut&&r.timeOut.cancel(),128===e.returnCode[0]?r.onFailure&&r.onFailure(e.returnCode):r.onSuccess&&r.onSuccess(e.returnCode),delete this._sentMessages[e.messageIdentifier]);break;case d:(r=this._sentMessages[e.messageIdentifier])&&(r.timeOut&&r.timeOut.cancel(),r.callback&&r.callback(),delete this._sentMessages[e.messageIdentifier]);break;case v:this.sendPinger.reset();break;case g:this._disconnected(b.INVALID_MQTT_MESSAGE_TYPE.code,_(b.INVALID_MQTT_MESSAGE_TYPE,[e.type]));break;default:this._disconnected(b.INVALID_MQTT_MESSAGE_TYPE.code,_(b.INVALID_MQTT_MESSAGE_TYPE,[e.type]))}}catch(e){var O="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(b.INTERNAL_ERROR.code,_(b.INTERNAL_ERROR,[e.message,O]))}},R.prototype._on_socket_error=function(e){this._reconnecting||this._disconnected(b.SOCKET_ERROR.code,_(b.SOCKET_ERROR,[e.data]))},R.prototype._on_socket_close=function(){this._reconnecting||this._disconnected(b.SOCKET_CLOSE.code,_(b.SOCKET_CLOSE))},R.prototype._socket_send=function(e){if(1==e.type){var t=this._traceMask(e,"password");this._trace("Client._socket_send",t)}else this._trace("Client._socket_send",e);this.socket.send(e.encode()),this.sendPinger.reset()},R.prototype._receivePublish=function(e){switch(e.payloadMessage.qos){case"undefined":case 0:this._receiveMessage(e);break;case 1:var t=new I(s,{messageIdentifier:e.messageIdentifier});this._schedule_message(t),this._receiveMessage(e);break;case 2:this._receivedMessages[e.messageIdentifier]=e,this.store("Received:",e);var n=new I(a,{messageIdentifier:e.messageIdentifier});this._schedule_message(n);break;default:throw Error("Invaild qos="+e.payloadMessage.qos)}},R.prototype._receiveMessage=function(e){this.onMessageArrived&&this.onMessageArrived(e.payloadMessage)},R.prototype._connected=function(e,t){this.onConnected&&this.onConnected(e,t)},R.prototype._reconnect=function(){this._trace("Client._reconnect"),this.connected||(this._reconnecting=!0,this.sendPinger.cancel(),this.receivePinger.cancel(),this._reconnectInterval<128&&(this._reconnectInterval=2*this._reconnectInterval),this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri))},R.prototype._disconnected=function(e,t){if(this._trace("Client._disconnected",e,t),void 0!==e&&this._reconnecting)this._reconnectTimeout=new x(this,this._reconnectInterval,this._reconnect);else if(this.sendPinger.cancel(),this.receivePinger.cancel(),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._msg_queue=[],this._buffered_msg_queue=[],this._notify_msg_sent={},this.socket&&(this.socket.onopen=null,this.socket.onmessage=null,this.socket.onerror=null,this.socket.onclose=null,1===this.socket.readyState&&this.socket.close(),delete this.socket),this.connectOptions.uris&&this.hostIndex<this.connectOptions.uris.length-1)this.hostIndex++,this._doConnect(this.connectOptions.uris[this.hostIndex]);else if(void 0===e&&(e=b.OK.code,t=_(b.OK)),this.connected){if(this.connected=!1,this.onConnectionLost&&this.onConnectionLost({errorCode:e,errorMessage:t,reconnect:this.connectOptions.reconnect,uri:this._wsuri}),e!==b.OK.code&&this.connectOptions.reconnect)return this._reconnectInterval=1,void this._reconnect()}else 4===this.connectOptions.mqttVersion&&!1===this.connectOptions.mqttVersionExplicit?(this._trace("Failed to connect V4, dropping back to V3"),this.connectOptions.mqttVersion=3,this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri)):this.connectOptions.onFailure&&this.connectOptions.onFailure({invocationContext:this.connectOptions.invocationContext,errorCode:e,errorMessage:t})},R.prototype._trace=function(){if(this.traceFunction){var e=Array.prototype.slice.call(arguments);for(var t in e)void 0!==e[t]&&e.splice(t,1,JSON.stringify(e[t]));var n=e.join("");this.traceFunction({severity:"Debug",message:n})}if(null!==this._traceBuffer){t=0;for(var r=arguments.length;t<r;t++)this._traceBuffer.length==this._MAX_TRACE_ENTRIES&&this._traceBuffer.shift(),0===t||void 0===arguments[t]?this._traceBuffer.push(arguments[t]):this._traceBuffer.push(" "+JSON.stringify(arguments[t]))}},R.prototype._traceMask=function(e,t){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]=r==t?"******":e[r]);return n};var P=function(e){var t,n;if(!("string"==typeof e||e instanceof ArrayBuffer||ArrayBuffer.isView(e)&&!(e instanceof DataView)))throw _(b.INVALID_ARGUMENT,[e,"newPayload"]);t=e;var r=0,o=!1,i=!1;Object.defineProperties(this,{payloadString:{enumerable:!0,get:function(){return"string"==typeof t?t:T(t,0,t.length)}},payloadBytes:{enumerable:!0,get:function(){if("string"==typeof t){var e=new ArrayBuffer(k(t)),n=new Uint8Array(e);return L(t,n,0),n}return t}},destinationName:{enumerable:!0,get:function(){return n},set:function(e){if("string"!=typeof e)throw new Error(_(b.INVALID_ARGUMENT,[e,"newDestinationName"]));n=e}},qos:{enumerable:!0,get:function(){return r},set:function(e){if(0!==e&&1!==e&&2!==e)throw new Error("Invalid argument:"+e);r=e}},retained:{enumerable:!0,get:function(){return o},set:function(e){if("boolean"!=typeof e)throw new Error(_(b.INVALID_ARGUMENT,[e,"newRetained"]));o=e}},topic:{enumerable:!0,get:function(){return n},set:function(e){n=e}},duplicate:{enumerable:!0,get:function(){return i},set:function(e){i=e}}})};return{Client:function(e,t,n,r){var o;if("string"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"host"]));if(2==arguments.length){r=t;var i=(o=e).match(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/);if(!i)throw new Error(_(b.INVALID_ARGUMENT,[e,"host"]));e=i[4]||i[2],t=parseInt(i[7]),n=i[8]}else{if(3==arguments.length&&(r=n,n="/mqtt"),"number"!=typeof t||t<0)throw new Error(_(b.INVALID_TYPE,[typeof t,"port"]));if("string"!=typeof n)throw new Error(_(b.INVALID_TYPE,[typeof n,"path"]));var s=-1!==e.indexOf(":")&&"["!==e.slice(0,1)&&"]"!==e.slice(-1);o="ws://"+(s?"["+e+"]":e)+":"+t+n}for(var a=0,c=0;c<r.length;c++){var u=r.charCodeAt(c);55296<=u&&u<=56319&&c++,a++}if("string"!=typeof r||a>65535)throw new Error(_(b.INVALID_ARGUMENT,[r,"clientId"]));var l=new R(o,e,t,n,r);Object.defineProperties(this,{host:{get:function(){return e},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},port:{get:function(){return t},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},path:{get:function(){return n},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},uri:{get:function(){return o},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},clientId:{get:function(){return l.clientId},set:function(){throw new Error(_(b.UNSUPPORTED_OPERATION))}},onConnected:{get:function(){return l.onConnected},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onConnected"]));l.onConnected=e}},disconnectedPublishing:{get:function(){return l.disconnectedPublishing},set:function(e){l.disconnectedPublishing=e}},disconnectedBufferSize:{get:function(){return l.disconnectedBufferSize},set:function(e){l.disconnectedBufferSize=e}},onConnectionLost:{get:function(){return l.onConnectionLost},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onConnectionLost"]));l.onConnectionLost=e}},onMessageDelivered:{get:function(){return l.onMessageDelivered},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onMessageDelivered"]));l.onMessageDelivered=e}},onMessageArrived:{get:function(){return l.onMessageArrived},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onMessageArrived"]));l.onMessageArrived=e}},trace:{get:function(){return l.traceFunction},set:function(e){if("function"!=typeof e)throw new Error(_(b.INVALID_TYPE,[typeof e,"onTrace"]));l.traceFunction=e}}}),this.connect=function(e){if(m(e=e||{},{timeout:"number",userName:"string",password:"string",willMessage:"object",keepAliveInterval:"number",cleanSession:"boolean",useSSL:"boolean",invocationContext:"object",onSuccess:"function",onFailure:"function",hosts:"object",ports:"object",reconnect:"boolean",mqttVersion:"number",mqttVersionExplicit:"boolean",uris:"object"}),void 0===e.keepAliveInterval&&(e.keepAliveInterval=60),e.mqttVersion>4||e.mqttVersion<3)throw new Error(_(b.INVALID_ARGUMENT,[e.mqttVersion,"connectOptions.mqttVersion"]));if(void 0===e.mqttVersion?(e.mqttVersionExplicit=!1,e.mqttVersion=4):e.mqttVersionExplicit=!0,void 0!==e.password&&void 0===e.userName)throw new Error(_(b.INVALID_ARGUMENT,[e.password,"connectOptions.password"]));if(e.willMessage){if(!(e.willMessage instanceof P))throw new Error(_(b.INVALID_TYPE,[e.willMessage,"connectOptions.willMessage"]));if(e.willMessage.stringPayload=null,void 0===e.willMessage.destinationName)throw new Error(_(b.INVALID_TYPE,[typeof e.willMessage.destinationName,"connectOptions.willMessage.destinationName"]))}if(void 0===e.cleanSession&&(e.cleanSession=!0),e.hosts){if(!(e.hosts instanceof Array))throw new Error(_(b.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));if(e.hosts.length<1)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));for(var t=!1,r=0;r<e.hosts.length;r++){if("string"!=typeof e.hosts[r])throw new Error(_(b.INVALID_TYPE,[typeof e.hosts[r],"connectOptions.hosts["+r+"]"]));if(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/.test(e.hosts[r])){if(0===r)t=!0;else if(!t)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}else if(t)throw new Error(_(b.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}if(t)e.uris=e.hosts;else{if(!e.ports)throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(!(e.ports instanceof Array))throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(e.hosts.length!==e.ports.length)throw new Error(_(b.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));for(e.uris=[],r=0;r<e.hosts.length;r++){if("number"!=typeof e.ports[r]||e.ports[r]<0)throw new Error(_(b.INVALID_TYPE,[typeof e.ports[r],"connectOptions.ports["+r+"]"]));var i=e.hosts[r],s=e.ports[r],a=-1!==i.indexOf(":");o="ws://"+(a?"["+i+"]":i)+":"+s+n,e.uris.push(o)}}}l.connect(e)},this.subscribe=function(e,t){if("string"!=typeof e&&e.constructor!==Array)throw new Error("Invalid argument:"+e);if(m(t=t||{},{qos:"number",invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("subscribeOptions.timeout specified with no onFailure callback.");if(void 0!==t.qos&&0!==t.qos&&1!==t.qos&&2!==t.qos)throw new Error(_(b.INVALID_ARGUMENT,[t.qos,"subscribeOptions.qos"]));l.subscribe(e,t)},this.unsubscribe=function(e,t){if("string"!=typeof e&&e.constructor!==Array)throw new Error("Invalid argument:"+e);if(m(t=t||{},{invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("unsubscribeOptions.timeout specified with no onFailure callback.");l.unsubscribe(e,t)},this.send=function(e,t,n,r){var o;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof P)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(o=e).destinationName)throw new Error(_(b.INVALID_ARGUMENT,[o.destinationName,"Message.destinationName"]));l.send(o)}else(o=new P(t)).destinationName=e,arguments.length>=3&&(o.qos=n),arguments.length>=4&&(o.retained=r),l.send(o)},this.publish=function(e,t,n,r){var o;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof P)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(o=e).destinationName)throw new Error(_(b.INVALID_ARGUMENT,[o.destinationName,"Message.destinationName"]));l.send(o)}else(o=new P(t)).destinationName=e,arguments.length>=3&&(o.qos=n),arguments.length>=4&&(o.retained=r),l.send(o)},this.disconnect=function(){l.disconnect()},this.getTraceLog=function(){return l.getTraceLog()},this.startTrace=function(){l.startTrace()},this.stopTrace=function(){l.stopTrace()},this.isConnected=function(){return l.connected}},Message:P}}(void 0!==t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},e.exports=n()}).call(this,n(13))},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/camera.svg"},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/gallery.svg"},function(e,t,n){"use strict";t.a="https://chat-storage.isometrik.io/web/chat-assets/icons/sticker.svg"},function(e,t,n){"use strict";var r=n(0),o=n.n(r),i=n(8),s=n(5),a=n(12),c=n(16),u=n(10),l=n(14),f=n.n(l);function h(e,t){if(!e){var n=new Error("loadable: "+t);throw n.framesToPop=1,n.name="Invariant Violation",n}}var d=o.a.createContext();var p={initialChunks:{}};var v=function(e){return e};function g(e){var t=e.defaultResolveComponent,n=void 0===t?v:t,r=e.render,l=e.onLoad;function g(e,t){void 0===t&&(t={});var v=function(e){return"function"==typeof e?{requireAsync:e,resolve:function(){},chunkName:function(){}}:e}(e),g={};function m(e){return t.cacheKey?t.cacheKey(e):v.resolve?v.resolve(e):"static"}function y(e,r,o){var i=t.resolveComponent?t.resolveComponent(e,r):n(e);if(t.resolveComponent&&!Object(u.isValidElementType)(i))throw new Error("resolveComponent returned something that is not a React component!");return f()(o,i,{preload:!0}),i}var b,w,_=function(e){var t=m(e),n=g[t];return n&&"REJECTED"!==n.status||((n=v.requireAsync(e)).status="PENDING",g[t]=n,n.then((function(){n.status="RESOLVED"}),(function(t){console.error("loadable-components: failed to asynchronously load component",{fileName:v.resolve(e),chunkName:v.chunkName(e),error:t?t.message:t}),n.status="REJECTED"}))),n},S=function(e){function n(n){var r;return(r=e.call(this,n)||this).state={result:null,error:null,loading:!0,cacheKey:m(n)},h(!n.__chunkExtractor||v.requireSync,"SSR requires `@loadable/babel-plugin`, please install it"),n.__chunkExtractor?(!1===t.ssr||(v.requireAsync(n).catch((function(){return null})),r.loadSync(),n.__chunkExtractor.addChunk(v.chunkName(n))),Object(a.a)(r)):(!1!==t.ssr&&(v.isReady&&v.isReady(n)||v.chunkName&&p.initialChunks[v.chunkName(n)])&&r.loadSync(),r)}Object(c.a)(n,e),n.getDerivedStateFromProps=function(e,t){var n=m(e);return Object(s.a)({},t,{cacheKey:n,loading:t.loading||t.cacheKey!==n})};var o=n.prototype;return o.componentDidMount=function(){this.mounted=!0;var e=this.getCache();e&&"REJECTED"===e.status&&this.setCache(),this.state.loading&&this.loadAsync()},o.componentDidUpdate=function(e,t){t.cacheKey!==this.state.cacheKey&&this.loadAsync()},o.componentWillUnmount=function(){this.mounted=!1},o.safeSetState=function(e,t){this.mounted&&this.setState(e,t)},o.getCacheKey=function(){return m(this.props)},o.getCache=function(){return g[this.getCacheKey()]},o.setCache=function(e){void 0===e&&(e=void 0),g[this.getCacheKey()]=e},o.triggerOnLoad=function(){var e=this;l&&setTimeout((function(){l(e.state.result,e.props)}))},o.loadSync=function(){if(this.state.loading)try{var e=y(v.requireSync(this.props),this.props,I);this.state.result=e,this.state.loading=!1}catch(e){console.error("loadable-components: failed to synchronously load component, which expected to be available",{fileName:v.resolve(this.props),chunkName:v.chunkName(this.props),error:e?e.message:e}),this.state.error=e}},o.loadAsync=function(){var e=this,t=this.resolveAsync();return t.then((function(t){var n=y(t,e.props,I);e.safeSetState({result:n,loading:!1},(function(){return e.triggerOnLoad()}))})).catch((function(t){return e.safeSetState({error:t,loading:!1})})),t},o.resolveAsync=function(){var e=this.props,t=(e.__chunkExtractor,e.forwardedRef,Object(i.a)(e,["__chunkExtractor","forwardedRef"]));return _(t)},o.render=function(){var e=this.props,n=e.forwardedRef,o=e.fallback,a=(e.__chunkExtractor,Object(i.a)(e,["forwardedRef","fallback","__chunkExtractor"])),c=this.state,u=c.error,l=c.loading,f=c.result;if(t.suspense&&"PENDING"===(this.getCache()||this.loadAsync()).status)throw this.loadAsync();if(u)throw u;var h=o||t.fallback||null;return l?h:r({fallback:h,result:f,options:t,props:Object(s.a)({},a,{ref:n})})},n}(o.a.Component),E=(w=function(e){return o.a.createElement(d.Consumer,null,(function(t){return o.a.createElement(b,Object.assign({__chunkExtractor:t},e))}))},(b=S).displayName&&(w.displayName=b.displayName+"WithChunkExtractor"),w),I=o.a.forwardRef((function(e,t){return o.a.createElement(E,Object.assign({forwardedRef:t},e))}));return I.displayName="Loadable",I.preload=function(e){I.load(e)},I.load=function(e){return _(e)},I}return{loadable:g,lazy:function(e,t){return g(e,Object(s.a)({},t,{suspense:!0}))}}}var m=g({defaultResolveComponent:function(e){return e.__esModule?e.default:e.default||e},render:function(e){var t=e.result,n=e.props;return o.a.createElement(t,n)}}),y=m.loadable,b=m.lazy,w=g({onLoad:function(e,t){e&&t.forwardedRef&&("function"==typeof t.forwardedRef?t.forwardedRef(e):t.forwardedRef.current=e)},render:function(e){var t=e.result,n=e.props;return n.children?n.children(t):null}}),_=w.loadable,S=w.lazy;var E=y;E.lib=_,b.lib=S;t.a=E},function(e,t,n){"use strict";n.d(t,"a",(function(){return ae}));var r=function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function o(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))}function i(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(a){return function(c){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,a[0]&&(s=0)),s;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return s.label++,{value:a[1],done:!1};case 5:s.label++,r=a[1],a=[0];continue;case 7:a=s.ops.pop(),s.trys.pop();continue;default:if(!(o=s.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){s=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){s.label=a[1];break}if(6===a[0]&&s.label<o[1]){s.label=o[1],o=a;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(a);break}o[2]&&s.ops.pop(),s.trys.pop();continue}a=t.call(e,s)}catch(e){a=[6,e],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,c])}}}Object.create;function s(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create;"function"==typeof SuppressedError&&SuppressedError;function a(e,t){return new Promise((function(n){return setTimeout(n,e,t)}))}function c(e){return!!e&&"function"==typeof e.then}function u(e,t){try{var n=e();c(n)?n.then((function(e){return t(!0,e)}),(function(e){return t(!1,e)})):t(!0,n)}catch(e){t(!1,e)}}function l(e,t,n){return void 0===n&&(n=16),o(this,void 0,void 0,(function(){var r,o,s,c;return i(this,(function(i){switch(i.label){case 0:r=Array(e.length),o=Date.now(),s=0,i.label=1;case 1:return s<e.length?(r[s]=t(e[s],s),(c=Date.now())>=o+n?(o=c,[4,a(0)]):[3,3]):[3,4];case 2:i.sent(),i.label=3;case 3:return++s,[3,1];case 4:return[2,r]}}))}))}function f(e){e.then(void 0,(function(){}))}function h(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]+t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]+t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]+t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]+t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function d(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]*t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]*t[3],n[1]+=n[2]>>>16,n[2]&=65535,n[2]+=e[3]*t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]*t[3],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[2]*t[2],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[3]*t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]*t[3]+e[1]*t[2]+e[2]*t[1]+e[3]*t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function p(e,t){return 32===(t%=64)?[e[1],e[0]]:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t|e[0]>>>32-t]:(t-=32,[e[1]<<t|e[0]>>>32-t,e[0]<<t|e[1]>>>32-t])}function v(e,t){return 0===(t%=64)?e:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t]:[e[1]<<t-32,0]}function g(e,t){return[e[0]^t[0],e[1]^t[1]]}function m(e){return e=g(e,[0,e[0]>>>1]),e=g(e=d(e,[4283543511,3981806797]),[0,e[0]>>>1]),e=g(e=d(e,[3301882366,444984403]),[0,e[0]>>>1])}function y(e,t){t=t||0;var n,r=(e=e||"").length%16,o=e.length-r,i=[0,t],s=[0,t],a=[0,0],c=[0,0],u=[2277735313,289559509],l=[1291169091,658871167];for(n=0;n<o;n+=16)a=[255&e.charCodeAt(n+4)|(255&e.charCodeAt(n+5))<<8|(255&e.charCodeAt(n+6))<<16|(255&e.charCodeAt(n+7))<<24,255&e.charCodeAt(n)|(255&e.charCodeAt(n+1))<<8|(255&e.charCodeAt(n+2))<<16|(255&e.charCodeAt(n+3))<<24],c=[255&e.charCodeAt(n+12)|(255&e.charCodeAt(n+13))<<8|(255&e.charCodeAt(n+14))<<16|(255&e.charCodeAt(n+15))<<24,255&e.charCodeAt(n+8)|(255&e.charCodeAt(n+9))<<8|(255&e.charCodeAt(n+10))<<16|(255&e.charCodeAt(n+11))<<24],a=p(a=d(a,u),31),i=h(i=p(i=g(i,a=d(a,l)),27),s),i=h(d(i,[0,5]),[0,1390208809]),c=p(c=d(c,l),33),s=h(s=p(s=g(s,c=d(c,u)),31),i),s=h(d(s,[0,5]),[0,944331445]);switch(a=[0,0],c=[0,0],r){case 15:c=g(c,v([0,e.charCodeAt(n+14)],48));case 14:c=g(c,v([0,e.charCodeAt(n+13)],40));case 13:c=g(c,v([0,e.charCodeAt(n+12)],32));case 12:c=g(c,v([0,e.charCodeAt(n+11)],24));case 11:c=g(c,v([0,e.charCodeAt(n+10)],16));case 10:c=g(c,v([0,e.charCodeAt(n+9)],8));case 9:c=d(c=g(c,[0,e.charCodeAt(n+8)]),l),s=g(s,c=d(c=p(c,33),u));case 8:a=g(a,v([0,e.charCodeAt(n+7)],56));case 7:a=g(a,v([0,e.charCodeAt(n+6)],48));case 6:a=g(a,v([0,e.charCodeAt(n+5)],40));case 5:a=g(a,v([0,e.charCodeAt(n+4)],32));case 4:a=g(a,v([0,e.charCodeAt(n+3)],24));case 3:a=g(a,v([0,e.charCodeAt(n+2)],16));case 2:a=g(a,v([0,e.charCodeAt(n+1)],8));case 1:a=d(a=g(a,[0,e.charCodeAt(n)]),u),i=g(i,a=d(a=p(a,31),l))}return i=h(i=g(i,[0,e.length]),s=g(s,[0,e.length])),s=h(s,i),i=h(i=m(i),s=m(s)),s=h(s,i),("00000000"+(i[0]>>>0).toString(16)).slice(-8)+("00000000"+(i[1]>>>0).toString(16)).slice(-8)+("00000000"+(s[0]>>>0).toString(16)).slice(-8)+("00000000"+(s[1]>>>0).toString(16)).slice(-8)}function b(e){return parseInt(e)}function w(e){return parseFloat(e)}function _(e,t){return"number"==typeof e&&isNaN(e)?t:e}function S(e){return e.reduce((function(e,t){return e+(t?1:0)}),0)}function E(e,t){if(void 0===t&&(t=1),Math.abs(t)>=1)return Math.round(e/t)*t;var n=1/t;return Math.round(e*n)/n}function I(e){return e&&"object"==typeof e&&"message"in e?e:{message:e}}function A(e){return"function"!=typeof e}function C(e,t,n){var r=Object.keys(e).filter((function(e){return!function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return!0;return!1}(n,e)})),s=l(r,(function(n){return function(e,t){var n=new Promise((function(n){var r=Date.now();u(e.bind(null,t),(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var o=Date.now()-r;if(!e[0])return n((function(){return{error:I(e[1]),duration:o}}));var i=e[1];if(A(i))return n((function(){return{value:i,duration:o}}));n((function(){return new Promise((function(e){var t=Date.now();u(i,(function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=o+Date.now()-t;if(!n[0])return e({error:I(n[1]),duration:i});e({value:n[1],duration:i})}))}))}))}))}));return f(n),function(){return n.then((function(e){return e()}))}}(e[n],t)}));return f(s),function(){return o(this,void 0,void 0,(function(){var e,t,n,o;return i(this,(function(i){switch(i.label){case 0:return[4,s];case 1:return[4,l(i.sent(),(function(e){var t=e();return f(t),t}))];case 2:return e=i.sent(),[4,Promise.all(e)];case 3:for(t=i.sent(),n={},o=0;o<r.length;++o)n[r[o]]=t[o];return[2,n]}}))}))}}function O(){var e=window,t=navigator;return S(["MSCSSMatrix"in e,"msSetImmediate"in e,"msIndexedDB"in e,"msMaxTouchPoints"in t,"msPointerEnabled"in t])>=4}function M(){var e=window,t=navigator;return S(["webkitPersistentStorage"in t,"webkitTemporaryStorage"in t,0===t.vendor.indexOf("Google"),"webkitResolveLocalFileSystemURL"in e,"BatteryManager"in e,"webkitMediaStream"in e,"webkitSpeechGrammar"in e])>=5}function k(){var e=window,t=navigator;return S(["ApplePayError"in e,"CSSPrimitiveValue"in e,"Counter"in e,0===t.vendor.indexOf("Apple"),"getStorageUpdates"in t,"WebKitMediaKeys"in e])>=4}function L(){var e=window;return S(["safari"in e,!("DeviceMotionEvent"in e),!("ongestureend"in e),!("standalone"in navigator)])>=3}function T(){var e=document;return(e.exitFullscreen||e.msExitFullscreen||e.mozCancelFullScreen||e.webkitExitFullscreen).call(e)}function j(){var e=M(),t=function(){var e,t,n=window;return S(["buildID"in navigator,"MozAppearance"in(null!==(t=null===(e=document.documentElement)||void 0===e?void 0:e.style)&&void 0!==t?t:{}),"onmozfullscreenchange"in n,"mozInnerScreenX"in n,"CSSMozDocumentRule"in n,"CanvasCaptureMediaStream"in n])>=4}();if(!e&&!t)return!1;var n=window;return S(["onorientationchange"in n,"orientation"in n,e&&!("SharedWorker"in n),t&&/android/i.test(navigator.appVersion)])>=2}function x(e){var t=new Error(e);return t.name=e,t}function R(e,t,n){var r,s,c;return void 0===n&&(n=50),o(this,void 0,void 0,(function(){var o,u;return i(this,(function(i){switch(i.label){case 0:o=document,i.label=1;case 1:return o.body?[3,3]:[4,a(n)];case 2:return i.sent(),[3,1];case 3:u=o.createElement("iframe"),i.label=4;case 4:return i.trys.push([4,,10,11]),[4,new Promise((function(e,n){var r=!1,i=function(){r=!0,e()};u.onload=i,u.onerror=function(e){r=!0,n(e)};var s=u.style;s.setProperty("display","block","important"),s.position="absolute",s.top="0",s.left="0",s.visibility="hidden",t&&"srcdoc"in u?u.srcdoc=t:u.src="about:blank",o.body.appendChild(u);var a=function(){var e,t;r||("complete"===(null===(t=null===(e=u.contentWindow)||void 0===e?void 0:e.document)||void 0===t?void 0:t.readyState)?i():setTimeout(a,10))};a()}))];case 5:i.sent(),i.label=6;case 6:return(null===(s=null===(r=u.contentWindow)||void 0===r?void 0:r.document)||void 0===s?void 0:s.body)?[3,8]:[4,a(n)];case 7:return i.sent(),[3,6];case 8:return[4,e(u,u.contentWindow)];case 9:return[2,i.sent()];case 10:return null===(c=u.parentNode)||void 0===c||c.removeChild(u),[7];case 11:return[2]}}))}))}function P(e){for(var t=function(e){for(var t,n,r="Unexpected syntax '".concat(e,"'"),o=/^\s*([a-z-]*)(.*)$/i.exec(e),i=o[1]||void 0,s={},a=/([.:#][\w-]+|\[.+?\])/gi,c=function(e,t){s[e]=s[e]||[],s[e].push(t)};;){var u=a.exec(o[2]);if(!u)break;var l=u[0];switch(l[0]){case".":c("class",l.slice(1));break;case"#":c("id",l.slice(1));break;case"[":var f=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(l);if(!f)throw new Error(r);c(f[1],null!==(n=null!==(t=f[4])&&void 0!==t?t:f[5])&&void 0!==n?n:"");break;default:throw new Error(r)}}return[i,s]}(e),n=t[0],r=t[1],o=document.createElement(null!=n?n:"div"),i=0,s=Object.keys(r);i<s.length;i++){var a=s[i],c=r[a].join(" ");"style"===a?N(o.style,c):o.setAttribute(a,c)}return o}function N(e,t){for(var n=0,r=t.split(";");n<r.length;n++){var o=r[n],i=/^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(o);if(i){var s=i[1],a=i[2],c=i[4];e.setProperty(s,a,c||"")}}}var D=["monospace","sans-serif","serif"],U=["sans-serif-thin","ARNO PRO","Agency FB","Arabic Typesetting","Arial Unicode MS","AvantGarde Bk BT","BankGothic Md BT","Batang","Bitstream Vera Sans Mono","Calibri","Century","Century Gothic","Clarendon","EUROSTILE","Franklin Gothic","Futura Bk BT","Futura Md BT","GOTHAM","Gill Sans","HELV","Haettenschweiler","Helvetica Neue","Humanst521 BT","Leelawadee","Letter Gothic","Levenim MT","Lucida Bright","Lucida Sans","Menlo","MS Mincho","MS Outlook","MS Reference Specialty","MS UI Gothic","MT Extra","MYRIAD PRO","Marlett","Meiryo UI","Microsoft Uighur","Minion Pro","Monotype Corsiva","PMingLiU","Pristina","SCRIPTINA","Segoe UI Light","Serifa","SimHei","Small Fonts","Staccato222 BT","TRAJAN PRO","Univers CE 55 Medium","Vrinda","ZWAdobeF"];function V(e){return e.toDataURL()}var F,B;function Y(){var e=this;return function(){if(void 0===B){var e=function(){var t=G();W(t)?B=setTimeout(e,2500):(F=t,B=void 0)};e()}}(),function(){return o(e,void 0,void 0,(function(){var e;return i(this,(function(t){switch(t.label){case 0:return W(e=G())?F?[2,s([],F,!0)]:(n=document).fullscreenElement||n.msFullscreenElement||n.mozFullScreenElement||n.webkitFullscreenElement?[4,T()]:[3,2]:[3,2];case 1:t.sent(),e=G(),t.label=2;case 2:return W(e)||(F=e),[2,e]}var n}))}))}}function G(){var e=screen;return[_(w(e.availTop),null),_(w(e.width)-w(e.availWidth)-_(w(e.availLeft),0),null),_(w(e.height)-w(e.availHeight)-_(w(e.availTop),0),null),_(w(e.availLeft),null)]}function W(e){for(var t=0;t<4;++t)if(e[t])return!1;return!0}function Z(e){var t;return o(this,void 0,void 0,(function(){var n,r,o,s,c,u,l;return i(this,(function(i){switch(i.label){case 0:for(n=document,r=n.createElement("div"),o=new Array(e.length),s={},J(r),l=0;l<e.length;++l)"DIALOG"===(c=P(e[l])).tagName&&c.show(),J(u=n.createElement("div")),u.appendChild(c),r.appendChild(u),o[l]=c;i.label=1;case 1:return n.body?[3,3]:[4,a(50)];case 2:return i.sent(),[3,1];case 3:n.body.appendChild(r);try{for(l=0;l<e.length;++l)o[l].offsetParent||(s[e[l]]=!0)}finally{null===(t=r.parentNode)||void 0===t||t.removeChild(r)}return[2,s]}}))}))}function J(e){e.style.setProperty("display","block","important")}function q(e){return matchMedia("(inverted-colors: ".concat(e,")")).matches}function z(e){return matchMedia("(forced-colors: ".concat(e,")")).matches}function H(e){return matchMedia("(prefers-contrast: ".concat(e,")")).matches}function X(e){return matchMedia("(prefers-reduced-motion: ".concat(e,")")).matches}function K(e){return matchMedia("(dynamic-range: ".concat(e,")")).matches}var Q=Math,$=function(){return 0};var ee={default:[],apple:[{font:"-apple-system-body"}],serif:[{fontFamily:"serif"}],sans:[{fontFamily:"sans-serif"}],mono:[{fontFamily:"monospace"}],min:[{fontSize:"1px"}],system:[{fontFamily:"system-ui"}]};var te={fonts:function(){return R((function(e,t){var n=t.document,r=n.body;r.style.fontSize="48px";var o=n.createElement("div"),i={},s={},a=function(e){var t=n.createElement("span"),r=t.style;return r.position="absolute",r.top="0",r.left="0",r.fontFamily=e,t.textContent="mmMwWLliI0O&1",o.appendChild(t),t},c=D.map(a),u=function(){for(var e={},t=function(t){e[t]=D.map((function(e){return function(e,t){return a("'".concat(e,"',").concat(t))}(t,e)}))},n=0,r=U;n<r.length;n++){t(r[n])}return e}();r.appendChild(o);for(var l=0;l<D.length;l++)i[D[l]]=c[l].offsetWidth,s[D[l]]=c[l].offsetHeight;return U.filter((function(e){return t=u[e],D.some((function(e,n){return t[n].offsetWidth!==i[e]||t[n].offsetHeight!==s[e]}));var t}))}))},domBlockers:function(e){var t=(void 0===e?{}:e).debug;return o(this,void 0,void 0,(function(){var e,n,r,o,s;return i(this,(function(i){switch(i.label){case 0:return k()||j()?(a=atob,e={abpIndo:["#Iklan-Melayang","#Kolom-Iklan-728","#SidebarIklan-wrapper",'[title="ALIENBOLA" i]',a("I0JveC1CYW5uZXItYWRz")],abpvn:[".quangcao","#mobileCatfish",a("LmNsb3NlLWFkcw=="),'[id^="bn_bottom_fixed_"]',"#pmadv"],adBlockFinland:[".mainostila",a("LnNwb25zb3JpdA=="),".ylamainos",a("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")],adBlockPersian:["#navbar_notice_50",".kadr",'TABLE[width="140px"]',"#divAgahi",a("YVtocmVmXj0iaHR0cDovL2cxLnYuZndtcm0ubmV0L2FkLyJd")],adBlockWarningRemoval:["#adblock-honeypot",".adblocker-root",".wp_adblock_detect",a("LmhlYWRlci1ibG9ja2VkLWFk"),a("I2FkX2Jsb2NrZXI=")],adGuardAnnoyances:[".hs-sosyal","#cookieconsentdiv",'div[class^="app_gdpr"]',".as-oil",'[data-cypress="soft-push-notification-modal"]'],adGuardBase:[".BetterJsPopOverlay",a("I2FkXzMwMFgyNTA="),a("I2Jhbm5lcmZsb2F0MjI="),a("I2NhbXBhaWduLWJhbm5lcg=="),a("I0FkLUNvbnRlbnQ=")],adGuardChinese:[a("LlppX2FkX2FfSA=="),a("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),"#widget-quan",a("YVtocmVmKj0iLzg0OTkyMDIwLnh5eiJd"),a("YVtocmVmKj0iLjE5NTZobC5jb20vIl0=")],adGuardFrench:["#pavePub",a("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),".mobile_adhesion",".widgetadv",a("LmFkc19iYW4=")],adGuardGerman:['aside[data-portal-id="leaderboard"]'],adGuardJapanese:["#kauli_yad_1",a("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),a("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),a("LmFkZ29vZ2xl"),a("Ll9faXNib29zdFJldHVybkFk")],adGuardMobile:[a("YW1wLWF1dG8tYWRz"),a("LmFtcF9hZA=="),'amp-embed[type="24smi"]',"#mgid_iframe1",a("I2FkX2ludmlld19hcmVh")],adGuardRussian:[a("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),a("LnJlY2xhbWE="),'div[id^="smi2adblock"]',a("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),"#psyduckpockeball"],adGuardSocial:[a("YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="),a("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),".etsy-tweet","#inlineShare",".popup-social"],adGuardSpanishPortuguese:["#barraPublicidade","#Publicidade","#publiEspecial","#queTooltip",".cnt-publi"],adGuardTrackingProtection:["#qoo-counter",a("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),a("YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="),a("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),"#top100counter"],adGuardTurkish:["#backkapat",a("I3Jla2xhbWk="),a("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),a("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),a("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")],bulgarian:[a("dGQjZnJlZW5ldF90YWJsZV9hZHM="),"#ea_intext_div",".lapni-pop-over","#xenium_hot_offers"],easyList:[".yb-floorad",a("LndpZGdldF9wb19hZHNfd2lkZ2V0"),a("LnRyYWZmaWNqdW5reS1hZA=="),".textad_headline",a("LnNwb25zb3JlZC10ZXh0LWxpbmtz")],easyListChina:[a("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),a("LmZyb250cGFnZUFkdk0="),"#taotaole","#aafoot.top_box",".cfa_popup"],easyListCookie:[".ezmob-footer",".cc-CookieWarning","[data-cookie-number]",a("LmF3LWNvb2tpZS1iYW5uZXI="),".sygnal24-gdpr-modal-wrap"],easyListCzechSlovak:["#onlajny-stickers",a("I3Jla2xhbW5pLWJveA=="),a("LnJla2xhbWEtbWVnYWJvYXJk"),".sklik",a("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")],easyListDutch:[a("I2FkdmVydGVudGll"),a("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),".adstekst",a("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),"#semilo-lrectangle"],easyListGermany:["#SSpotIMPopSlider",a("LnNwb25zb3JsaW5rZ3J1ZW4="),a("I3dlcmJ1bmdza3k="),a("I3Jla2xhbWUtcmVjaHRzLW1pdHRl"),a("YVtocmVmXj0iaHR0cHM6Ly9iZDc0Mi5jb20vIl0=")],easyListItaly:[a("LmJveF9hZHZfYW5udW5jaQ=="),".sb-box-pubbliredazionale",a("YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ==")],easyListLithuania:[a("LnJla2xhbW9zX3RhcnBhcw=="),a("LnJla2xhbW9zX251b3JvZG9z"),a("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),a("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),a("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")],estonian:[a("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")],fanboyAnnoyances:["#ac-lre-player",".navigate-to-top","#subscribe_popup",".newsletter_holder","#back-top"],fanboyAntiFacebook:[".util-bar-module-firefly-visible"],fanboyEnhancedTrackers:[".open.pushModal","#issuem-leaky-paywall-articles-zero-remaining-nag","#sovrn_container",'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',".BlockNag__Card"],fanboySocial:["#FollowUs","#meteored_share","#social_follow",".article-sharer",".community__social-desc"],frellwitSwedish:[a("YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="),a("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),"article.category-samarbete",a("ZGl2LmhvbGlkQWRz"),"ul.adsmodern"],greekAdBlock:[a("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),a("QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="),a("QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"),"DIV.agores300","TABLE.advright"],hungarian:["#cemp_doboz",".optimonk-iframe-container",a("LmFkX19tYWlu"),a("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),"#hirdetesek_box"],iDontCareAboutCookies:['.alert-info[data-block-track*="CookieNotice"]',".ModuleTemplateCookieIndicator",".o--cookies--container","#cookies-policy-sticky","#stickyCookieBar"],icelandicAbp:[a("QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ==")],latvian:[a("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="),a("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ==")],listKr:[a("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),a("I2xpdmVyZUFkV3JhcHBlcg=="),a("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),a("aW5zLmZhc3R2aWV3LWFk"),".revenue_unit_item.dable"],listeAr:[a("LmdlbWluaUxCMUFk"),".right-and-left-sponsers",a("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),a("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),a("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")],listeFr:[a("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),a("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),a("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),".site-pub-interstitiel",'div[id^="crt-"][data-criteo-id]'],officialPolish:["#ceneo-placeholder-ceneo-12",a("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),a("YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="),a("YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="),a("ZGl2I3NrYXBpZWNfYWQ=")],ro:[a("YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"),a("YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"),a("YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="),a("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd"),'a[href^="/url/"]'],ruAd:[a("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),a("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),a("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),"#pgeldiz",".yandex-rtb-block"],thaiAds:["a[href*=macau-uta-popup]",a("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),a("LmFkczMwMHM="),".bumq",".img-kosana"],webAnnoyancesUltralist:["#mod-social-share-2","#social-tools",a("LmN0cGwtZnVsbGJhbm5lcg=="),".zergnet-recommend",".yt.btn-link.btn-md.btn"]},n=Object.keys(e),[4,Z((s=[]).concat.apply(s,n.map((function(t){return e[t]}))))]):[2,void 0];case 1:return r=i.sent(),t&&function(e,t){for(var n="DOM blockers debug:\n```",r=0,o=Object.keys(e);r<o.length;r++){var i=o[r];n+="\n".concat(i,":");for(var s=0,a=e[i];s<a.length;s++){var c=a[s];n+="\n ".concat(t[c]?"🚫":"➡️"," ").concat(c)}}console.log("".concat(n,"\n```"))}(e,r),(o=n.filter((function(t){var n=e[t];return S(n.map((function(e){return r[e]})))>.6*n.length}))).sort(),[2,o]}var a}))}))},fontPreferences:function(){return function(e,t){void 0===t&&(t=4e3);return R((function(n,r){var o=r.document,i=o.body,a=i.style;a.width="".concat(t,"px"),a.webkitTextSizeAdjust=a.textSizeAdjust="none",M()?i.style.zoom="".concat(1/r.devicePixelRatio):k()&&(i.style.zoom="reset");var c=o.createElement("div");return c.textContent=s([],Array(t/20<<0),!0).map((function(){return"word"})).join(" "),i.appendChild(c),e(o,i)}),'<!doctype html><html><head><meta name="viewport" content="width=device-width, initial-scale=1">')}((function(e,t){for(var n={},r={},o=0,i=Object.keys(ee);o<i.length;o++){var s=i[o],a=ee[s],c=a[0],u=void 0===c?{}:c,l=a[1],f=void 0===l?"mmMwWLliI0fiflO&1":l,h=e.createElement("span");h.textContent=f,h.style.whiteSpace="nowrap";for(var d=0,p=Object.keys(u);d<p.length;d++){var v=p[d],g=u[v];void 0!==g&&(h.style[v]=g)}n[s]=h,t.appendChild(e.createElement("br")),t.appendChild(h)}for(var m=0,y=Object.keys(ee);m<y.length;m++){r[s=y[m]]=n[s].getBoundingClientRect().width}return r}))},audio:function(){var e=window,t=e.OfflineAudioContext||e.webkitOfflineAudioContext;if(!t)return-2;if(k()&&!L()&&!function(){var e=window;return S(["DOMRectList"in e,"RTCPeerConnectionIceEvent"in e,"SVGGeometryElement"in e,"ontransitioncancel"in e])>=3}())return-1;var n=new t(1,5e3,44100),r=n.createOscillator();r.type="triangle",r.frequency.value=1e4;var o=n.createDynamicsCompressor();o.threshold.value=-50,o.knee.value=40,o.ratio.value=12,o.attack.value=0,o.release.value=.25,r.connect(o),o.connect(n.destination),r.start(0);var i=function(e){var t=function(){};return[new Promise((function(n,r){var o=!1,i=0,s=0;e.oncomplete=function(e){return n(e.renderedBuffer)};var a=function(){setTimeout((function(){return r(x("timeout"))}),Math.min(500,s+5e3-Date.now()))},u=function(){try{var t=e.startRendering();switch(c(t)&&f(t),e.state){case"running":s=Date.now(),o&&a();break;case"suspended":document.hidden||i++,o&&i>=3?r(x("suspended")):setTimeout(u,500)}}catch(e){r(e)}};u(),t=function(){o||(o=!0,s>0&&a())}})),t]}(n),s=i[0],a=i[1],u=s.then((function(e){return function(e){for(var t=0,n=0;n<e.length;++n)t+=Math.abs(e[n]);return t}(e.getChannelData(0).subarray(4500))}),(function(e){if("timeout"===e.name||"suspended"===e.name)return-3;throw e}));return f(u),function(){return a(),u}},screenFrame:function(){var e=this,t=Y();return function(){return o(e,void 0,void 0,(function(){var e,n;return i(this,(function(r){switch(r.label){case 0:return[4,t()];case 1:return e=r.sent(),[2,[(n=function(e){return null===e?null:E(e,10)})(e[0]),n(e[1]),n(e[2]),n(e[3])]]}}))}))}},osCpu:function(){return navigator.oscpu},languages:function(){var e,t=navigator,n=[],r=t.language||t.userLanguage||t.browserLanguage||t.systemLanguage;if(void 0!==r&&n.push([r]),Array.isArray(t.languages))M()&&S([!("MediaSettingsRange"in(e=window)),"RTCEncodedAudioFrame"in e,""+e.Intl=="[object Intl]",""+e.Reflect=="[object Reflect]"])>=3||n.push(t.languages);else if("string"==typeof t.languages){var o=t.languages;o&&n.push(o.split(","))}return n},colorDepth:function(){return window.screen.colorDepth},deviceMemory:function(){return _(w(navigator.deviceMemory),void 0)},screenResolution:function(){var e=screen,t=function(e){return _(b(e),null)},n=[t(e.width),t(e.height)];return n.sort().reverse(),n},hardwareConcurrency:function(){return _(b(navigator.hardwareConcurrency),void 0)},timezone:function(){var e,t=null===(e=window.Intl)||void 0===e?void 0:e.DateTimeFormat;if(t){var n=(new t).resolvedOptions().timeZone;if(n)return n}var r,o=(r=(new Date).getFullYear(),-Math.max(w(new Date(r,0,1).getTimezoneOffset()),w(new Date(r,6,1).getTimezoneOffset())));return"UTC".concat(o>=0?"+":"").concat(Math.abs(o))},sessionStorage:function(){try{return!!window.sessionStorage}catch(e){return!0}},localStorage:function(){try{return!!window.localStorage}catch(e){return!0}},indexedDB:function(){var e,t;if(!(O()||(e=window,t=navigator,S(["msWriteProfilerMark"in e,"MSStream"in e,"msLaunchUri"in t,"msSaveBlob"in t])>=3&&!O())))try{return!!window.indexedDB}catch(e){return!0}},openDatabase:function(){return!!window.openDatabase},cpuClass:function(){return navigator.cpuClass},platform:function(){var e=navigator.platform;return"MacIntel"===e&&k()&&!L()?function(){if("iPad"===navigator.platform)return!0;var e=screen,t=e.width/e.height;return S(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,t>.65&&t<1.53])>=2}()?"iPad":"iPhone":e},plugins:function(){var e=navigator.plugins;if(e){for(var t=[],n=0;n<e.length;++n){var r=e[n];if(r){for(var o=[],i=0;i<r.length;++i){var s=r[i];o.push({type:s.type,suffixes:s.suffixes})}t.push({name:r.name,description:r.description,mimeTypes:o})}}return t}},canvas:function(){var e,t,n=!1,r=function(){var e=document.createElement("canvas");return e.width=1,e.height=1,[e,e.getContext("2d")]}(),o=r[0],i=r[1];if(function(e,t){return!(!t||!e.toDataURL)}(o,i)){n=function(e){return e.rect(0,0,10,10),e.rect(2,2,6,6),!e.isPointInPath(5,5,"evenodd")}(i),function(e,t){e.width=240,e.height=60,t.textBaseline="alphabetic",t.fillStyle="#f60",t.fillRect(100,1,62,20),t.fillStyle="#069",t.font='11pt "Times New Roman"';var n="Cwm fjordbank gly ".concat(String.fromCharCode(55357,56835));t.fillText(n,2,15),t.fillStyle="rgba(102, 204, 0, 0.2)",t.font="18pt Arial",t.fillText(n,4,45)}(o,i);var s=V(o);s!==V(o)?e=t="unstable":(t=s,function(e,t){e.width=122,e.height=110,t.globalCompositeOperation="multiply";for(var n=0,r=[["#f2f",40,40],["#2ff",80,40],["#ff2",60,80]];n<r.length;n++){var o=r[n],i=o[0],s=o[1],a=o[2];t.fillStyle=i,t.beginPath(),t.arc(s,a,40,0,2*Math.PI,!0),t.closePath(),t.fill()}t.fillStyle="#f9c",t.arc(60,60,60,0,2*Math.PI,!0),t.arc(60,60,20,0,2*Math.PI,!0),t.fill("evenodd")}(o,i),e=V(o))}else e=t="";return{winding:n,geometry:e,text:t}},touchSupport:function(){var e,t=navigator,n=0;void 0!==t.maxTouchPoints?n=b(t.maxTouchPoints):void 0!==t.msMaxTouchPoints&&(n=t.msMaxTouchPoints);try{document.createEvent("TouchEvent"),e=!0}catch(t){e=!1}return{maxTouchPoints:n,touchEvent:e,touchStart:"ontouchstart"in window}},vendor:function(){return navigator.vendor||""},vendorFlavors:function(){for(var e=[],t=0,n=["chrome","safari","__crWeb","__gCrWeb","yandex","__yb","__ybro","__firefox__","__edgeTrackingPreventionStatistics","webkit","oprt","samsungAr","ucweb","UCShellJava","puffinDevice"];t<n.length;t++){var r=n[t],o=window[r];o&&"object"==typeof o&&e.push(r)}return e.sort()},cookiesEnabled:function(){var e=document;try{e.cookie="cookietest=1; SameSite=Strict;";var t=-1!==e.cookie.indexOf("cookietest=");return e.cookie="cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT",t}catch(e){return!1}},colorGamut:function(){for(var e=0,t=["rec2020","p3","srgb"];e<t.length;e++){var n=t[e];if(matchMedia("(color-gamut: ".concat(n,")")).matches)return n}},invertedColors:function(){return!!q("inverted")||!q("none")&&void 0},forcedColors:function(){return!!z("active")||!z("none")&&void 0},monochrome:function(){if(matchMedia("(min-monochrome: 0)").matches){for(var e=0;e<=100;++e)if(matchMedia("(max-monochrome: ".concat(e,")")).matches)return e;throw new Error("Too high value")}},contrast:function(){return H("no-preference")?0:H("high")||H("more")?1:H("low")||H("less")?-1:H("forced")?10:void 0},reducedMotion:function(){return!!X("reduce")||!X("no-preference")&&void 0},hdr:function(){return!!K("high")||!K("standard")&&void 0},math:function(){var e,t=Q.acos||$,n=Q.acosh||$,r=Q.asin||$,o=Q.asinh||$,i=Q.atanh||$,s=Q.atan||$,a=Q.sin||$,c=Q.sinh||$,u=Q.cos||$,l=Q.cosh||$,f=Q.tan||$,h=Q.tanh||$,d=Q.exp||$,p=Q.expm1||$,v=Q.log1p||$;return{acos:t(.12312423423423424),acosh:n(1e308),acoshPf:(e=1e154,Q.log(e+Q.sqrt(e*e-1))),asin:r(.12312423423423424),asinh:o(1),asinhPf:function(e){return Q.log(e+Q.sqrt(e*e+1))}(1),atanh:i(.5),atanhPf:function(e){return Q.log((1+e)/(1-e))/2}(.5),atan:s(.5),sin:a(-1e300),sinh:c(1),sinhPf:function(e){return Q.exp(e)-1/Q.exp(e)/2}(1),cos:u(10.000000000123),cosh:l(1),coshPf:function(e){return(Q.exp(e)+1/Q.exp(e))/2}(1),tan:f(-1e300),tanh:h(1),tanhPf:function(e){return(Q.exp(2*e)-1)/(Q.exp(2*e)+1)}(1),exp:d(1),expm1:p(1),expm1Pf:function(e){return Q.exp(e)-1}(1),log1p:v(10),log1pPf:function(e){return Q.log(1+e)}(10),powPI:function(e){return Q.pow(Q.PI,e)}(-100)}},videoCard:function(){var e,t=document.createElement("canvas"),n=null!==(e=t.getContext("webgl"))&&void 0!==e?e:t.getContext("experimental-webgl");if(n&&"getExtension"in n){var r=n.getExtension("WEBGL_debug_renderer_info");if(r)return{vendor:(n.getParameter(r.UNMASKED_VENDOR_WEBGL)||"").toString(),renderer:(n.getParameter(r.UNMASKED_RENDERER_WEBGL)||"").toString()}}},pdfViewerEnabled:function(){return navigator.pdfViewerEnabled},architecture:function(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}};function ne(e){var t=function(e){if(j())return.4;if(k())return L()?.5:.3;var t=e.platform.value||"";if(/^Win/.test(t))return.6;if(/^Mac/.test(t))return.5;return.7}(e),n=function(e){return E(.99+.01*e,1e-4)}(t);return{score:t,comment:"$ if upgrade to Pro: https://fpjs.dev/pro".replace(/\$/g,"".concat(n))}}function re(e){return JSON.stringify(e,(function(e,t){return t instanceof Error?r({name:(n=t).name,message:n.message,stack:null===(o=n.stack)||void 0===o?void 0:o.split("\n")},n):t;var n,o}),2)}function oe(e){return y(function(e){for(var t="",n=0,r=Object.keys(e).sort();n<r.length;n++){var o=r[n],i=e[o],s=i.error?"error":JSON.stringify(i.value);t+="".concat(t?"|":"").concat(o.replace(/([:|\\])/g,"\\$1"),":").concat(s)}return t}(e))}function ie(e){return void 0===e&&(e=50),function(e,t){void 0===t&&(t=1/0);var n=window.requestIdleCallback;return n?new Promise((function(e){return n.call(window,(function(){return e()}),{timeout:t})})):a(Math.min(e,t))}(e,2*e)}function se(e,t){var n=Date.now();return{get:function(r){return o(this,void 0,void 0,(function(){var o,s,a;return i(this,(function(i){switch(i.label){case 0:return o=Date.now(),[4,e()];case 1:return s=i.sent(),a=function(e){var t;return{get visitorId(){return void 0===t&&(t=oe(this.components)),t},set visitorId(e){t=e},confidence:ne(e),components:e,version:"3.4.2"}}(s),(t||(null==r?void 0:r.debug))&&console.log("Copy the text below to get the debug data:\n\n```\nversion: ".concat(a.version,"\nuserAgent: ").concat(navigator.userAgent,"\ntimeBetweenLoadAndGet: ").concat(o-n,"\nvisitorId: ").concat(a.visitorId,"\ncomponents: ").concat(re(s),"\n```")),[2,a]}}))}))}}}var ae={load:function(e){var t=void 0===e?{}:e,n=t.delayFallback,r=t.debug,s=t.monitoring,a=void 0===s||s;return o(this,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return a&&function(){if(!(window.__fpjs_d_m||Math.random()>=.001))try{var e=new XMLHttpRequest;e.open("get","https://m1.openfpcdn.io/fingerprintjs/v".concat("3.4.2","/npm-monitoring"),!0),e.send()}catch(e){console.error(e)}}(),[4,ie(n)];case 1:return e.sent(),[2,se(C(te,{debug:r},[]),r)]}}))}))},hashComponents:oe,componentsToDebugString:re}},,function(e,t,n){"use strict";(function(e){
|
|
9
9
|
/*!
|
|
10
10
|
* The buffer module from node.js, for the browser.
|
|
11
11
|
*
|
|
12
12
|
* @author Feross Aboukhadijeh <http://feross.org>
|
|
13
13
|
* @license MIT
|
|
14
14
|
*/
|
|
15
|
-
var r=n(28),o=n(29),i=n(30);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|p(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|d(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(l(t),e=a(e,t<0?0:0|d(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|d(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function d(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function p(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return Y(e).length;default:if(r)return F(e).length;t=(""+t).toLowerCase(),r=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return O(this,t,n);case"utf8":case"utf-8":return C(this,t,n);case"ascii":return k(this,t,n);case"latin1":case"binary":return M(this,t,n);case"base64":return A(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:y(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):y(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function y(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var l=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===c)return l*s}else-1!==l&&(i-=i-l),l=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var f=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){f=!1;break}if(f)return i}return-1}function b(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return B(F(t,e.length-n),e,n,r)}function _(e,t,n,r){return B(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function S(e,t,n,r){return _(e,t,n,r)}function E(e,t,n,r){return B(Y(t),e,n,r)}function I(e,t,n,r){return B(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)n=e.charCodeAt(s),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function A(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function C(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],l=null,f=u>239?4:u>223?3:u>191?2:1;if(o+f<=n)switch(f){case 1:u<128&&(l=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(l=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(l=c)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return l(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=p,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?C(this,0,e):v.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),l=e.slice(t,n),f=0;f<a;++f)if(u[f]!==l[f]){i=u[f],s=l[f];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return _(this,e,t,n);case"latin1":case"binary":return S(this,e,t,n);case"base64":return E(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function k(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function M(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function O(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=V(e[i]);return o}function L(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function T(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function x(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function R(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function P(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function N(e,t,n,r,i){return i||P(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function D(e,t,n,r,i){return i||P(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||T(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||T(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||T(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||T(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||T(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||T(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||T(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||T(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||T(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||T(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||T(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||T(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||T(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||T(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):x(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):x(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):R(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):x(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):x(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):R(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return N(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return N(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return D(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return D(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:F(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var U=/[^+\/0-9A-Za-z-_]/g;function V(e){return e<16?"0"+e.toString(16):e.toString(16)}function F(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function Y(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(U,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function B(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(13))},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),l=0,f=a>0?s-4:s;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=0,a=n-o;s<a;s+=16383)i.push(l(e,s,s+16383>a?a:s+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){
|
|
15
|
+
var r=n(28),o=n(29),i=n(30);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|p(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|d(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(l(t),e=a(e,t<0?0:0|d(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|d(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function d(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function p(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return B(e).length;default:if(r)return F(e).length;t=(""+t).toLowerCase(),r=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return k(this,t,n);case"utf8":case"utf-8":return C(this,t,n);case"ascii":return O(this,t,n);case"latin1":case"binary":return M(this,t,n);case"base64":return A(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:y(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):y(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function y(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var l=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===c)return l*s}else-1!==l&&(i-=i-l),l=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var f=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){f=!1;break}if(f)return i}return-1}function b(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return Y(F(t,e.length-n),e,n,r)}function _(e,t,n,r){return Y(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function S(e,t,n,r){return _(e,t,n,r)}function E(e,t,n,r){return Y(B(t),e,n,r)}function I(e,t,n,r){return Y(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)n=e.charCodeAt(s),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function A(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function C(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],l=null,f=u>239?4:u>223?3:u>191?2:1;if(o+f<=n)switch(f){case 1:u<128&&(l=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(l=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(l=c)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return l(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=p,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?C(this,0,e):v.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),l=e.slice(t,n),f=0;f<a;++f)if(u[f]!==l[f]){i=u[f],s=l[f];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return _(this,e,t,n);case"latin1":case"binary":return S(this,e,t,n);case"base64":return E(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function O(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function M(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function k(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=V(e[i]);return o}function L(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function T(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function x(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function R(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function P(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function N(e,t,n,r,i){return i||P(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function D(e,t,n,r,i){return i||P(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||T(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||T(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||T(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||T(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||T(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||T(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||T(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||T(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||T(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||T(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||T(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||T(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||T(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||T(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||T(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):x(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):x(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):R(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):x(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):x(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):R(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return N(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return N(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return D(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return D(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:F(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var U=/[^+\/0-9A-Za-z-_]/g;function V(e){return e<16?"0"+e.toString(16):e.toString(16)}function F(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function B(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(U,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function Y(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(13))},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),l=0,f=a>0?s-4:s;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=0,a=n-o;s<a;s+=16383)i.push(l(e,s,s+16383>a?a:s+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){
|
|
16
16
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
17
17
|
t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,l=-7,f=n?o-1:0,h=n?-1:1,d=e[t+f];for(f+=h,i=d&(1<<-l)-1,d>>=-l,l+=a;l>0;i=256*i+e[t+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=r;l>0;s=256*s+e[t+f],f+=h,l-=8);if(0===i)i=1-u;else{if(i===c)return s?NaN:1/0*(d?-1:1);s+=Math.pow(2,r),i-=u}return(d?-1:1)*s*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var s,a,c,u=8*i-o-1,l=(1<<u)-1,f=l>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:i-1,p=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=l):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),(t+=s+f>=1?h/c:h*Math.pow(2,1-f))*c>=2&&(s++,c/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(t*c-1)*Math.pow(2,o),s+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,o),s=0));o>=8;e[n+d]=255&a,d+=p,a/=256,o-=8);for(s=s<<o|a,u+=o;u>0;e[n+d]=255&s,d+=p,s/=256,u-=8);e[n+d-p]|=128*v}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){"use strict";
|
|
18
18
|
/**
|
|
@@ -31,4 +31,4 @@ t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,l=-7,f=n?o-1:0,h=
|
|
|
31
31
|
*
|
|
32
32
|
* This source code is licensed under the MIT license found in the
|
|
33
33
|
* LICENSE file in the root directory of this source tree.
|
|
34
|
-
*/var r="function"==typeof Symbol&&Symbol.for,o=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,s=r?Symbol.for("react.fragment"):60107,a=r?Symbol.for("react.strict_mode"):60108,c=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,f=r?Symbol.for("react.async_mode"):60111,h=r?Symbol.for("react.concurrent_mode"):60111,d=r?Symbol.for("react.forward_ref"):60112,p=r?Symbol.for("react.suspense"):60113,v=r?Symbol.for("react.suspense_list"):60120,g=r?Symbol.for("react.memo"):60115,m=r?Symbol.for("react.lazy"):60116,y=r?Symbol.for("react.block"):60121,b=r?Symbol.for("react.fundamental"):60117,w=r?Symbol.for("react.responder"):60118,_=r?Symbol.for("react.scope"):60119;function S(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case o:switch(e=e.type){case f:case h:case s:case c:case a:case p:return e;default:switch(e=e&&e.$$typeof){case l:case d:case m:case g:case u:return e;default:return t}}case i:return t}}}function E(e){return S(e)===h}t.AsyncMode=f,t.ConcurrentMode=h,t.ContextConsumer=l,t.ContextProvider=u,t.Element=o,t.ForwardRef=d,t.Fragment=s,t.Lazy=m,t.Memo=g,t.Portal=i,t.Profiler=c,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return E(e)||S(e)===f},t.isConcurrentMode=E,t.isContextConsumer=function(e){return S(e)===l},t.isContextProvider=function(e){return S(e)===u},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o},t.isForwardRef=function(e){return S(e)===d},t.isFragment=function(e){return S(e)===s},t.isLazy=function(e){return S(e)===m},t.isMemo=function(e){return S(e)===g},t.isPortal=function(e){return S(e)===i},t.isProfiler=function(e){return S(e)===c},t.isStrictMode=function(e){return S(e)===a},t.isSuspense=function(e){return S(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===s||e===h||e===c||e===a||e===p||e===v||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===g||e.$$typeof===u||e.$$typeof===l||e.$$typeof===d||e.$$typeof===b||e.$$typeof===w||e.$$typeof===_||e.$$typeof===y)},t.typeOf=S},function(e,t,n){"use strict";n.r(t),n.d(t,"chatClient",(function(){return r.default})),n.d(t,"getTotalUnreadCount",(function(){return o})),n.d(t,"startConversation",(function(){return l})),n.d(t,"ChatContext",(function(){return f.a})),n.d(t,"ChatState",(function(){return f.b})),n.d(t,"IsometrikChat",(function(){return h.a}));var r=n(1);function o(){return Object(r.default)().Conversation.getConversationUnreadCount()}function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */s=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},c=a.iterator||"@@iterator",u=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function f(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(e){f=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:k(e,n,a)}),s}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p="suspendedStart",v="executing",g="completed",m={};function y(){}function b(){}function w(){}var _={};f(_,c,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,c)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,s,a,c){var u=d(e[o],e,s);if("throw"!==u.type){var l=u.arg,f=l.value;return f&&"object"==i(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,a,c)}),(function(e){n("throw",e,a,c)})):t.resolve(f).then((function(e){l.value=e,a(l)}),(function(e){return n("throw",e,a,c)}))}c(u.arg)}var s;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return s=s?s.then(o,o):o()}})}function k(t,n,r){var o=p;return function(i,s){if(o===v)throw new Error("Generator is already running");if(o===g){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===m)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===p)throw o=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=v;var u=d(t,n,r);if("normal"===u.type){if(o=r.done?g:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=g,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var i=d(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,m;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,m):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[c];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,s=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return s.next=s}}throw new TypeError(i(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=f(w,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,f(e,l,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),f(C.prototype,u,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(h(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),f(I,l,"Generator"),f(I,c,(function(){return this})),f(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),m}},t}function a(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e)||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.")}()}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function u(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}var l=function(){var e,t=(e=s().mark((function e(t){var n,o,i,c,u,l,f,h,d;return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.userId,o=t.userName,i=t.userProfileImage,c=void 0===i?"default-pic.png":i,u=t.searchableTags,l={conversationId:""},f={typingEvents:!0,readEvents:!0,pushNotifications:!0,metaData:{},members:[n],isGroup:!1,customType:"SingleChat",conversationType:0,conversationTitle:o,conversationImageUrl:c,searchableTags:a(void 0===u?[]:u)},e.prev=3,e.next=6,null===(h=Object(r.default)())||void 0===h||null===(h=h.Conversation)||void 0===h?void 0:h.postConversation(f);case 6:if(d=e.sent,l.conversationId=d.conversationId,!d.conversationId){e.next=10;break}return e.abrupt("return",d);case 10:return e.abrupt("return","something went wrong");case 13:e.prev=13,e.t0=e.catch(3),console.log(e.t0,"err");case 16:case"end":return e.stop()}}),e,null,[[3,13]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){u(i,r,o,s,a,"next",e)}function a(e){u(i,r,o,s,a,"throw",e)}s(void 0)}))});return function(e){return t.apply(this,arguments)}}(),f=n(9),h=n(18)},function(e,t){e.exports=require("react-dom")}]);
|
|
34
|
+
*/var r="function"==typeof Symbol&&Symbol.for,o=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,s=r?Symbol.for("react.fragment"):60107,a=r?Symbol.for("react.strict_mode"):60108,c=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,f=r?Symbol.for("react.async_mode"):60111,h=r?Symbol.for("react.concurrent_mode"):60111,d=r?Symbol.for("react.forward_ref"):60112,p=r?Symbol.for("react.suspense"):60113,v=r?Symbol.for("react.suspense_list"):60120,g=r?Symbol.for("react.memo"):60115,m=r?Symbol.for("react.lazy"):60116,y=r?Symbol.for("react.block"):60121,b=r?Symbol.for("react.fundamental"):60117,w=r?Symbol.for("react.responder"):60118,_=r?Symbol.for("react.scope"):60119;function S(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case o:switch(e=e.type){case f:case h:case s:case c:case a:case p:return e;default:switch(e=e&&e.$$typeof){case l:case d:case m:case g:case u:return e;default:return t}}case i:return t}}}function E(e){return S(e)===h}t.AsyncMode=f,t.ConcurrentMode=h,t.ContextConsumer=l,t.ContextProvider=u,t.Element=o,t.ForwardRef=d,t.Fragment=s,t.Lazy=m,t.Memo=g,t.Portal=i,t.Profiler=c,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return E(e)||S(e)===f},t.isConcurrentMode=E,t.isContextConsumer=function(e){return S(e)===l},t.isContextProvider=function(e){return S(e)===u},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o},t.isForwardRef=function(e){return S(e)===d},t.isFragment=function(e){return S(e)===s},t.isLazy=function(e){return S(e)===m},t.isMemo=function(e){return S(e)===g},t.isPortal=function(e){return S(e)===i},t.isProfiler=function(e){return S(e)===c},t.isStrictMode=function(e){return S(e)===a},t.isSuspense=function(e){return S(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===s||e===h||e===c||e===a||e===p||e===v||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===g||e.$$typeof===u||e.$$typeof===l||e.$$typeof===d||e.$$typeof===b||e.$$typeof===w||e.$$typeof===_||e.$$typeof===y)},t.typeOf=S},function(e,t,n){"use strict";n.r(t),n.d(t,"chatClient",(function(){return r.default})),n.d(t,"getTotalUnreadCount",(function(){return o})),n.d(t,"startConversation",(function(){return l})),n.d(t,"ChatContext",(function(){return f.a})),n.d(t,"ChatState",(function(){return f.b})),n.d(t,"IsometrikChat",(function(){return h.a}));var r=n(1);function o(){return Object(r.default)().Conversation.getConversationUnreadCount()}function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */s=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},c=a.iterator||"@@iterator",u=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function f(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(e){f=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof y?t:y,s=Object.create(i.prototype),a=new T(r||[]);return o(s,"_invoke",{value:O(e,n,a)}),s}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p="suspendedStart",v="executing",g="completed",m={};function y(){}function b(){}function w(){}var _={};f(_,c,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(j([])));E&&E!==n&&r.call(E,c)&&(_=E);var I=w.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function C(e,t){function n(o,s,a,c){var u=d(e[o],e,s);if("throw"!==u.type){var l=u.arg,f=l.value;return f&&"object"==i(f)&&r.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,a,c)}),(function(e){n("throw",e,a,c)})):t.resolve(f).then((function(e){l.value=e,a(l)}),(function(e){return n("throw",e,a,c)}))}c(u.arg)}var s;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return s=s?s.then(o,o):o()}})}function O(t,n,r){var o=p;return function(i,s){if(o===v)throw new Error("Generator is already running");if(o===g){if("throw"===i)throw s;return{value:e,done:!0}}for(r.method=i,r.arg=s;;){var a=r.delegate;if(a){var c=M(a,r);if(c){if(c===m)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===p)throw o=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=v;var u=d(t,n,r);if("normal"===u.type){if(o=r.done?g:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o=g,r.method="throw",r.arg=u.arg)}}}function M(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,M(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var i=d(o,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,m;var s=i.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,m):s:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[c];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,s=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return s.next=s}}throw new TypeError(i(t)+" is not iterable")}return b.prototype=w,o(I,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:b,configurable:!0}),b.displayName=f(w,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,f(e,l,"GeneratorFunction")),e.prototype=Object.create(I),e},t.awrap=function(e){return{__await:e}},A(C.prototype),f(C.prototype,u,(function(){return this})),t.AsyncIterator=C,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var s=new C(h(e,n,r,o),i);return t.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},A(I),f(I,l,"Generator"),f(I,c,(function(){return this})),f(I,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=j,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return a.type="throw",a.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var c=r.call(s,"catchLoc"),u=r.call(s,"finallyLoc");if(c&&u){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;L(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),m}},t}function a(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e)||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.")}()}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function u(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}var l=function(){var e,t=(e=s().mark((function e(t){var n,o,i,c,u,l,f,h,d;return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.userId,o=t.userName,i=t.userProfileImage,c=void 0===i?"default-pic.png":i,u=t.searchableTags,l={conversationId:""},f={typingEvents:!0,readEvents:!0,pushNotifications:!0,metaData:{},members:[n],isGroup:!1,customType:"SingleChat",conversationType:0,conversationTitle:o,conversationImageUrl:c,searchableTags:a(void 0===u?[]:u)},e.prev=3,e.next=6,null===(h=Object(r.default)())||void 0===h||null===(h=h.Conversation)||void 0===h?void 0:h.postConversation(f);case 6:if(d=e.sent,l.conversationId=d.conversationId,!d.conversationId){e.next=10;break}return e.abrupt("return",d);case 10:return e.abrupt("return","something went wrong");case 13:e.prev=13,e.t0=e.catch(3),console.log(e.t0,"err");case 16:case"end":return e.stop()}}),e,null,[[3,13]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){u(i,r,o,s,a,"next",e)}function a(e){u(i,r,o,s,a,"throw",e)}s(void 0)}))});return function(e){return t.apply(this,arguments)}}(),f=n(9),h=n(18)},function(e,t){e.exports=require("react-dom")}]);
|