1/*! For license information please see 2.b61e17d0.chunk.js.LICENSE.txt */ 2(this["webpackJsonpsyl-aucoin-project-5"]=this["webpackJsonpsyl-aucoin-project-5"]||[]).push([[2],[function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return y})),n.d(t,"b",(function(){return C})),n.d(t,"c",(function(){return A})),n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return l})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return f})),n.d(t,"h",(function(){return I})),n.d(t,"i",(function(){return F})),n.d(t,"j",(function(){return d})),n.d(t,"k",(function(){return p})),n.d(t,"l",(function(){return z})),n.d(t,"m",(function(){return P})),n.d(t,"n",(function(){return _})),n.d(t,"o",(function(){return D})),n.d(t,"p",(function(){return g})),n.d(t,"q",(function(){return m})),n.d(t,"r",(function(){return w})),n.d(t,"s",(function(){return b})),n.d(t,"t",(function(){return N})),n.d(t,"u",(function(){return T})),n.d(t,"v",(function(){return j})),n.d(t,"w",(function(){return L})),n.d(t,"x",(function(){return R})),n.d(t,"y",(function(){return Q})),n.d(t,"z",(function(){return V})),n.d(t,"A",(function(){return k})),n.d(t,"B",(function(){return W})),n.d(t,"C",(function(){return B})),n.d(t,"D",(function(){return q}));var r=n(2),i=!1,o=!1,a="${JSCORE_VERSION}",s=function(e,t){if(!e)throw l(t)},l=function(e){return new Error("Firebase Database ("+a+") INTERNAL ASSERT FAILED: "+e)},u=function(e){for(var t=[],n=0,r=0;r<e.length;r++){var i=e.charCodeAt(r);i<128?t[n++]=i:i<2048?(t[n++]=i>>6|192,t[n++]=63&i|128):55296===(64512&i)&&r+1<e.length&&56320===(64512&e.charCodeAt(r+1))?(i=65536+((1023&i)<<10)+(1023&e.charCodeAt(++r)),t[n++]=i>>18|240,t[n++]=i>>12&63|128,t[n++]=i>>6&63|128,t[n++]=63&i|128):(t[n++]=i>>12|224,t[n++]=i>>6&63|128,t[n++]=63&i|128)}return t},c={byteToCharMap_:null,charToByteMap_:null,byteToCharMapWebSafe_:null,charToByteMapWebSafe_:null,ENCODED_VALS_BASE:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",get ENCODED_VALS(){return this.ENCODED_VALS_BASE+"+/="},get ENCODED_VALS_WEBSAFE(){return this.ENCODED_VALS_BASE+"-_."},HAS_NATIVE_SUPPORT:"function"===typeof atob,encodeByteArray:function(e,t){if(!Array.isArray(e))throw Error("encodeByteArray takes an array as a parameter");this.init_();for(var n=t?this.byteToCharMapWebSafe_:this.byteToCharMap_,r=[],i=0;i<e.length;i+=3){var o=e[i],a=i+1<e.length,s=a?e[i+1]:0,l=i+2<e.length,u=l?e[i+2]:0,c=o>>2,f=(3&o)<<4|s>>4,h=(15&s)<<2|u>>6,d=63&u;l||(d=64,a||(h=64)),r.push(n[c],n[f],n[h],n[d])}return r.join("")},encodeString:function(e,t){return this.HAS_NATIVE_SUPPORT&&!t?btoa(e):this.encodeByteArray(u(e),t)},decodeString:function(e,t){return this.HAS_NATIVE_SUPPORT&&!t?atob(e):function(e){for(var t=[],n=0,r=0;n<e.length;){var i=e[n++];if(i<128)t[r++]=String.fromCharCode(i);else if(i>191&&i<224){var o=e[n++];t[r++]=String.fromCharCode((31&i)<<6|63&o)}else if(i>239&&i<365){var a=((7&i)<<18|(63&(o=e[n++]))<<12|(63&(s=e[n++]))<<6|63&e[n++])-65536;t[r++]=String.fromCharCode(55296+(a>>10)),t[r++]=String.fromCharCode(56320+(1023&a))}else{o=e[n++];var s=e[n++];t[r++]=String.fromCharCode((15&i)<<12|(63&o)<<6|63&s)}}return t.join("")}(this.decodeStringToByteArray(e,t))},decodeStringToByteArray:function(e,t){this.init_();for(var n=t?this.charToByteMapWebSafe_:this.charToByteMap_,r=[],i=0;i<e.length;){var o=n[e.charAt(i++)],a=i<e.length?n[e.charAt(i)]:0,s=++i<e.length?n[e.charAt(i)]:64,l=++i<e.length?n[e.charAt(i)]:64;if(++i,null==o||null==a||null==s||null==l)throw Error();var u=o<<2|a>>4;if(r.push(u),64!==s){var c=a<<4&240|s>>2;if(r.push(c),64!==l){var f=s<<6&192|l;r.push(f)}}}return r},init_:function(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(var e=0;e<this.ENCODED_VALS.length;e++)this.byteToCharMap_[e]=this.ENCODED_VALS.charAt(e),this.charToByteMap_[this.byteToCharMap_[e]]=e,this.byteToCharMapWebSafe_[e]=this.ENCODED_VALS_WEBSAFE.charAt(e),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[e]]=e,e>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(e)]=e,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(e)]=e)}}},f=function(e){var t=u(e);return c.encodeByteArray(t,!0)},h=function(e){try{return c.decodeString(e,!0)}catch(t){console.error("base64Decode failed: ",t)}return null};function d(e){return p(void 0,e)}function p(e,t){if(!(t instanceof Object))return t;switch(t.constructor){case Date:return new Date(t.getTime());case Object:void 0===e&&(e={});break;case Array:e=[];break;default:return t}for(var n in t)t.hasOwnProperty(n)&&"__proto__"!==n&&(e[n]=p(e[n],t[n]));return e}var y=function(){function e(){var e=this;this.reject=function(){},this.resolve=function(){},this.promise=new Promise((function(t,n){e.resolve=t,e.reject=n}))}return e.prototype.wrapCallback=function(e){var t=this;return function(n,r){n?t.reject(n):t.resolve(r),"function"===typeof e&&(t.promise.catch((function(){})),1===e.length?e(n):e(n,r))}},e}();function v(){return"undefined"!==typeof navigator&&"string"===typeof navigator.userAgent?navigator.userAgent:""}function g(){return"undefined"!==typeof window&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(v())}function m(){try{return"[object process]"===Object.prototype.toString.call(e.process)}catch(t){return!1}}function _(){return"object"===typeof self&&self.self===self}function b(){return"object"===typeof navigator&&"ReactNative"===navigator.product}function w(){return!0===i||!0===o}var E=function(e){function t(n,r,i){var o=e.call(this,r)||this;return o.code=n,o.customData=i,o.name="FirebaseError",Object.setPrototypeOf(o,t.prototype),Error.captureStackTrace&&Error.captureStackTrace(o,C.prototype.create),o}return Object(r.c)(t,e),t}(Error),C=function(){function e(e,t,n){this.service=e,this.serviceName=t,this.errors=n}return e.prototype.create=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=t[0]||{},i=this.service+"/"+e,o=this.errors[e],a=o?S(o,r):"Error",s=this.serviceName+": "+a+" ("+i+").",l=new E(i,s,r);return l},e}();function S(e,t){return e.replace(O,(function(e,n){var r=t[n];return null!=r?String(r):"<"+n+"?>"}))}var O=/\{\$([^}]+)}/g;function T(e){return JSON.parse(e)}function k(e){return JSON.stringify(e)}var x=function(e){var t={},n={},r={},i="";try{var o=e.split(".");t=T(h(o[0])||""),n=T(h(o[1])||""),i=o[2],r=n.d||{},delete n.d}catch(a){}return{header:t,claims:n,data:r,signature:i}},N=function(e){var t=x(e).claims;return!!t&&"object"===typeof t&&t.hasOwnProperty("iat")},P=function(e){var t=x(e).claims;return"object"===typeof t&&!0===t.admin};function I(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function R(e,t){return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0}function D(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))return!1;return!0}function j(e,t,n){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(r[i]=t.call(n,e[i],i,e));return r}function L(e){for(var t=[],n=function(e,n){Array.isArray(n)?n.forEac
2h((function(n){t.push(encodeURIComponent(e)+"="+encodeURIComponent(n))})):t.push(encodeURIComponent(e)+"="+encodeURIComponent(n))},r=0,i=Object.entries(e);r<i.length;r++){var o=i[r];n(o[0],o[1])}return t.length?"&"+t.join("&"):""}var A=function(){function e(){this.chain_=[],this.buf_=[],this.W_=[],this.pad_=[],this.inbuf_=0,this.total_=0,this.blockSize=64,this.pad_[0]=128;for(var e=1;e<this.blockSize;++e)this.pad_[e]=0;this.reset()}return e.prototype.reset=function(){this.chain_[0]=1732584193,this.chain_[1]=4023233417,this.chain_[2]=2562383102,this.chain_[3]=271733878,this.chain_[4]=3285377520,this.inbuf_=0,this.total_=0},e.prototype.compress_=function(e,t){t||(t=0);var n=this.W_;if("string"===typeof e)for(var r=0;r<16;r++)n[r]=e.charCodeAt(t)<<24|e.charCodeAt(t+1)<<16|e.charCodeAt(t+2)<<8|e.charCodeAt(t+3),t+=4;else for(r=0;r<16;r++)n[r]=e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3],t+=4;for(r=16;r<80;r++){var i=n[r-3]^n[r-8]^n[r-14]^n[r-16];n[r]=4294967295&(i<<1|i>>>31)}var o,a,s=this.chain_[0],l=this.chain_[1],u=this.chain_[2],c=this.chain_[3],f=this.chain_[4];for(r=0;r<80;r++){r<40?r<20?(o=c^l&(u^c),a=1518500249):(o=l^u^c,a=1859775393):r<60?(o=l&u|c&(l|u),a=2400959708):(o=l^u^c,a=3395469782);i=(s<<5|s>>>27)+o+f+a+n[r]&4294967295;f=c,c=u,u=4294967295&(l<<30|l>>>2),l=s,s=i}this.chain_[0]=this.chain_[0]+s&4294967295,this.chain_[1]=this.chain_[1]+l&4294967295,this.chain_[2]=this.chain_[2]+u&4294967295,this.chain_[3]=this.chain_[3]+c&4294967295,this.chain_[4]=this.chain_[4]+f&4294967295},e.prototype.update=function(e,t){if(null!=e){void 0===t&&(t=e.length);for(var n=t-this.blockSize,r=0,i=this.buf_,o=this.inbuf_;r<t;){if(0===o)for(;r<=n;)this.compress_(e,r),r+=this.blockSize;if("string"===typeof e){for(;r<t;)if(i[o]=e.charCodeAt(r),++r,++o===this.blockSize){this.compress_(i),o=0;break}}else for(;r<t;)if(i[o]=e[r],++r,++o===this.blockSize){this.compress_(i),o=0;break}}this.inbuf_=o,this.total_+=t}},e.prototype.digest=function(){var e=[],t=8*this.total_;this.inbuf_<56?this.update(this.pad_,56-this.inbuf_):this.update(this.pad_,this.blockSize-(this.inbuf_-56));for(var n=this.blockSize-1;n>=56;n--)this.buf_[n]=255&t,t/=256;this.compress_(this.buf_);var r=0;for(n=0;n<5;n++)for(var i=24;i>=0;i-=8)e[r]=this.chain_[n]>>i&255,++r;return e},e}();function F(e,t){var n=new M(e,t);return n.subscribe.bind(n)}var M=function(){function e(e,t){var n=this;this.observers=[],this.unsubscribes=[],this.observerCount=0,this.task=Promise.resolve(),this.finalized=!1,this.onNoObservers=t,this.task.then((function(){e(n)})).catch((function(e){n.error(e)}))}return e.prototype.next=function(e){this.forEachObserver((function(t){t.next(e)}))},e.prototype.error=function(e){this.forEachObserver((function(t){t.error(e)})),this.close(e)},e.prototype.complete=function(){this.forEachObserver((function(e){e.complete()})),this.close()},e.prototype.subscribe=function(e,t,n){var r,i=this;if(void 0===e&&void 0===t&&void 0===n)throw new Error("Missing Observer.");void 0===(r=function(e,t){if("object"!==typeof e||null===e)return!1;for(var n=0,r=t;n<r.length;n++){var i=r[n];if(i in e&&"function"===typeof e[i])return!0}return!1}(e,["next","error","complete"])?e:{next:e,error:t,complete:n}).next&&(r.next=U),void 0===r.error&&(r.error=U),void 0===r.complete&&(r.complete=U);var o=this.unsubscribeOne.bind(this,this.observers.length);return this.finalized&&this.task.then((function(){try{i.finalError?r.error(i.finalError):r.complete()}catch(e){}})),this.observers.push(r),o},e.prototype.unsubscribeOne=function(e){void 0!==this.observers&&void 0!==this.observers[e]&&(delete this.observers[e],this.observerCount-=1,0===this.observerCount&&void 0!==this.onNoObservers&&this.onNoObservers(this))},e.prototype.forEachObserver=function(e){if(!this.finalized)for(var t=0;t<this.observers.length;t++)this.sendOne(t,e)},e.prototype.sendOne=function(e,t){var n=this;this.task.then((function(){if(void 0!==n.observers&&void 0!==n.observers[e])try{t(n.observers[e])}catch(r){"undefined"!==typeof console&&console.error&&console.error(r)}}))},e.prototype.close=function(e){var t=this;this.finalized||(this.finalized=!0,void 0!==e&&(this.finalError=e),this.task.then((function(){t.observers=void 0,t.onNoObservers=void 0})))},e}();function U(){}var W=function(e,t,n,r){var i;if(r<t?i="at least "+t:r>n&&(i=0===n?"none":"no more than "+n),i)throw new Error(e+" failed: Was called with "+r+(1===r?" argument.":" arguments.")+" Expects "+i+".")};function z(e,t,n){var r="";switch(t){case 1:r=n?"first":"First";break;case 2:r=n?"second":"Second";break;case 3:r=n?"third":"Third";break;case 4:r=n?"fourth":"Fourth";break;default:throw new Error("errorPrefix called with argumentNumber > 4. Need to update it?")}var i=e+" failed: ";return i+=r+" argument "}function B(e,t,n,r){if((!r||n)&&"function"!==typeof n)throw new Error(z(e,t,r)+"must be a valid function.")}function q(e,t,n,r){if((!r||n)&&("object"!==typeof n||null===n))throw new Error(z(e,t,r)+"must be a valid context object.")}var V=function(e){for(var t=[],n=0,r=0;r<e.length;r++){var i=e.charCodeAt(r);if(i>=55296&&i<=56319){var o=i-55296;r++,s(r<e.length,"Surrogate pair missing trail surrogate."),i=65536+(o<<10)+(e.charCodeAt(r)-56320)}i<128?t[n++]=i:i<2048?(t[n++]=i>>6|192,t[n++]=63&i|128):i<65536?(t[n++]=i>>12|224,t[n++]=i>>6&63|128,t[n++]=63&i|128):(t[n++]=i>>18|240,t[n++]=i>>12&63|128,t[n++]=i>>6&63|128,t[n++]=63&i|128)}return t},Q=function(e){for(var t=0,n=0;n<e.length;n++){var r=e.charCodeAt(n);r<128?t++:r<2048?t+=2:r>=55296&&r<=56319?(t+=4,n++):t+=3}return t}}
2).call(this,n(60))},function(e,t,n){"use strict";e.exports=n(30)},function(e,t,n){"use strict";n.d(t,"c",(function(){return i})),n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return a})),n.d(t,"d",(function(){return s})),n.d(t,"g",(function(){return l})),n.d(t,"e",(function(){return u})),n.d(t,"f",(function(){return c}));var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function i(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function a(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{l(r.next(e))}catch(t){o(t)}}function s(e){try{l(r.throw(e))}catch(t){o(t)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))}function s(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(s){o=[6,s],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}function l(e){var t="function"===typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"===typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function u(e,t){var n="function"===typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(s){i={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function c(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(u(arguments[t]));return e}},function(e,t,n){"use strict";e.exports=n(31)},function(e,t,n){"use strict";var r=n(15),i=Object.prototype.toString;function o(e){return"[object Array]"===i.call(e)}function a(e){return"undefined"===typeof e}function s(e){return null!==e&&"object"===typeof e}function l(e){if("[object Object]"!==i.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function u(e){return"[object Function]"===i.call(e)}function c(e,t){if(null!==e&&"undefined"!==typeof e)if("object"!==typeof e&&(e=[e]),o(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.call(null,e[i],i,e)}e.exports={isArray:o,isArrayBuffer:function(e){return"[object ArrayBuffer]"===i.call(e)},isBuffer:function(e){return null!==e&&!a(e)&&null!==e.constructor&&!a(e.constructor)&&"function"===typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)},isFormData:function(e){return"undefined"!==typeof FormData&&e instanceof FormData},isArrayBufferView:function(e){return"undefined"!==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer},isString:function(e){return"string"===typeof e},isNumber:function(e){return"number"===typeof e},isObject:s,isPlainObject:l,isUndefined:a,isDate:function(e){return"[object Date]"===i.call(e)},isFile:function(e){return"[object File]"===i.call(e)},isBlob:function(e){return"[object Blob]"===i.call(e)},isFunction:u,isStream:function(e){return s(e)&&u(e.pipe)},isURLSearchParams:function(e){return"undefined"!==typeof URLSearchParams&&e instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"===typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!==typeof window&&"undefined"!==typeof document)}
2,forEach:c,merge:function e(){var t={};function n(n,r){l(t[r])&&l(n)?t[r]=e(t[r],n):l(n)?t[r]=e({},n):o(n)?t[r]=n.slice():t[r]=n}for(var r=0,i=arguments.length;r<i;r++)c(arguments[r],n);return t},extend:function(e,t,n){return c(t,(function(t,i){e[i]=n&&"function"===typeof t?r(t,n):t})),e},trim:function(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e}}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}n.d(t,"a",(function(){return i}))},function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}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 o(e,t){return!t||"object"!==i(t)&&"function"!==typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function a(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=r(e);if(t){var a=r(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return o(this,n)}}n.d(t,"a",(function(){return a}))},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function i(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}n.d(t,"a",(function(){return i}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return l})),n.d(t,"c",(function(){return s}));var r=n(2),i=n(0),o=function(){function e(e,t,n){this.name=e,this.instanceFactory=t,this.type=n,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY"}return e.prototype.setInstantiationMode=function(e){return this.instantiationMode=e,this},e.prototype.setMultipleInstances=function(e){return this.multipleInstances=e,this},e.prototype.setServiceProps=function(e){return this.serviceProps=e,this},e}(),a="[DEFAULT]",s=function(){function e(e,t){this.name=e,this.container=t,this.component=null,this.instances=new Map,this.instancesDeferred=new Map}return e.prototype.get=function(e){void 0===e&&(e=a);var t=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(t)){var n=new i.a;this.instancesDeferred.set(t,n);try{var r=this.getOrInitializeService(t);r&&n.resolve(r)}catch(o){}}return this.instancesDeferred.get(t).promise},e.prototype.getImmediate=function(e){var t=Object(r.a)({identifier:a,optional:!1},e),n=t.identifier,i=t.optional,o=this.normalizeInstanceIdentifier(n);try{var s=this.getOrInitializeService(o);if(!s){if(i)return null;throw Error("Service "+this.name+" is not available")}return s}catch(l){if(i)return null;throw l}},e.prototype.getComponent=function(){return this.component},e.prototype.setComponent=function(e){var t,n;if(e.name!==this.name)throw Error("Mismatching Component "+e.name+" for Provider "+this.name+".");if(this.component)throw Error("Component for "+this.name+" has already been provided");if(this.component=e,function(e){return"EAGER"===e.instantiationMode}(e))try{this.getOrInitializeService(a)}catch(h){}try{for(var i=Object(r.g)(this.instancesDeferred.entries()),o=i.next();!o.done;o=i.next()){var s=Object(r.e)(o.value,2),l=s[0],u=s[1],c=this.normalizeInstanceIdentifier(l);try{var f=this.getOrInitializeService(c);u.resolve(f)}catch(h){}}}catch(d){t={error:d}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}},e.prototype.clearInstance=function(e){void 0===e&&(e=a),this.instancesDeferred.delete(e),this.instances.delete(e)},e.prototype.delete=function(){return Object(r.b)(this,void 0,void 0,(function(){var e;return Object(r.d)(this,(function(t){switch(t.label){case 0:return e=Array.from(this.instances.values()),[4,Promise.all(Object(r.f)(e.filter((function(e){return"INTERNAL"in e})).map((function(e){return e.INTERNAL.delete()})),e.filter((function(e){return"_delete"in e})).map((function(e){return e._delete()}))))];case 1:return t.sent(),[2]}}))}))},e.prototype.isComponentSet=function(){return null!=this.component},e.prototype.getOrInitializeService=function(e){var t=this.instances.get(e);return!t&&this.component&&(t=this.component.instanceFactory(this.container,function(e){return e===a?void 0:e}(e)),this.instances.set(e,t)),t||null},e.prototype.normalizeInstanceIdentifier=function(e){return this.component?this.component.multipleInstances?e:a:e},e}();var l=function(){function e(e){this.name=e,this.providers=new Map}return e.prototype.addComponent=function(e){var t=this.getProvider(e.name);if(t.isComponentSet())throw new Error("Component "+e.name+" has already been registered with "+this.name);t.setComponent(e)},e.prototype.addOrOverwriteComponent=function(e){this.getProvider(e.name).isComponentSet()&&this.providers.delete(e.name),this.addComponent(e)},e.prototype.getProvider=function(e){if(this.providers.has(e))return this.providers.get(e);var t=new s(e,this);return this.providers.set(e,t),t},e.prototype.getProviders=function(){return Array.from(this.providers.values())},e}()},function(e,t,n){"use strict";function r(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r}var i;n.d(t,"a",(function(){return o}
2)),n.d(t,"b",(function(){return f})),n.d(t,"c",(function(){return h})),n.d(t,"d",(function(){return d}));var o,a=[];!function(e){e[e.DEBUG=0]="DEBUG",e[e.VERBOSE=1]="VERBOSE",e[e.INFO=2]="INFO",e[e.WARN=3]="WARN",e[e.ERROR=4]="ERROR",e[e.SILENT=5]="SILENT"}(o||(o={}));var s={debug:o.DEBUG,verbose:o.VERBOSE,info:o.INFO,warn:o.WARN,error:o.ERROR,silent:o.SILENT},l=o.INFO,u=((i={})[o.DEBUG]="log",i[o.VERBOSE]="log",i[o.INFO]="info",i[o.WARN]="warn",i[o.ERROR]="error",i),c=function(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];if(!(t<e.logLevel)){var o=(new Date).toISOString(),a=u[t];if(!a)throw new Error("Attempted to log a message with an invalid logType (value: "+t+")");console[a].apply(console,r(["["+o+"] "+e.name+":"],n))}},f=function(){function e(e){this.name=e,this._logLevel=l,this._logHandler=c,this._userLogHandler=null,a.push(this)}return Object.defineProperty(e.prototype,"logLevel",{get:function(){return this._logLevel},set:function(e){if(!(e in o))throw new TypeError('Invalid value "'+e+'" assigned to `logLevel`');this._logLevel=e},enumerable:!1,configurable:!0}),e.prototype.setLogLevel=function(e){this._logLevel="string"===typeof e?s[e]:e},Object.defineProperty(e.prototype,"logHandler",{get:function(){return this._logHandler},set:function(e){if("function"!==typeof e)throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"userLogHandler",{get:function(){return this._userLogHandler},set:function(e){this._userLogHandler=e},enumerable:!1,configurable:!0}),e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._userLogHandler&&this._userLogHandler.apply(this,r([this,o.DEBUG],e)),this._logHandler.apply(this,r([this,o.DEBUG],e))},e.prototype.log=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._userLogHandler&&this._userLogHandler.apply(this,r([this,o.VERBOSE],e)),this._logHandler.apply(this,r([this,o.VERBOSE],e))},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._userLogHandler&&this._userLogHandler.apply(this,r([this,o.INFO],e)),this._logHandler.apply(this,r([this,o.INFO],e))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._userLogHandler&&this._userLogHandler.apply(this,r([this,o.WARN],e)),this._logHandler.apply(this,r([this,o.WARN],e))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._userLogHandler&&this._userLogHandler.apply(this,r([this,o.ERROR],e)),this._logHandler.apply(this,r([this,o.ERROR],e))},e}();function h(e){a.forEach((function(t){t.setLogLevel(e)}))}function d(e,t){for(var n=function(n){var r=null;t&&t.level&&(r=s[t.level]),n.userLogHandler=null===e?null:function(t,n){for(var i=[],a=2;a<arguments.length;a++)i[a-2]=arguments[a];var s=i.map((function(e){if(null==e)return null;if("string"===typeof e)return e;if("number"===typeof e||"boolean"===typeof e)return e.toString();if(e instanceof Error)return e.message;try{return JSON.stringify(e)}catch(t){return null}})).filter((function(e){return e})).join(" ");n>=(null!==r&&void 0!==r?r:t.logLevel)&&e({level:o[n].toLowerCase(),message:s,args:i,type:t.name})}},r=0,i=a;r<i.length;r++){n(i[r])}}},function(e,t,n){"use strict";var r,i,o=n(2),a=n(0),s=n(9),l=n(10),u=((r={})["no-app"]="No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",r["bad-app-name"]="Illegal App name: '{$appName}",r["duplicate-app"]="Firebase App named '{$appName}' already exists",r["app-deleted"]="Firebase App named '{$appName}' already deleted",r["invalid-app-argument"]="firebase.{$appName}() takes either no argument or a Firebase App instance.",r["invalid-log-argument"]="First argument to `onLog` must be null or a function.",r),c=new a.b("app","Firebase",u),f="@firebase/app",h="[DEFAULT]",d=((i={})[f]="fire-core",i["@firebase/analytics"]="fire-analytics",i["@firebase/auth"]="fire-auth",i["@firebase/database"]="fire-rtdb",i["@firebase/functions"]="fire-fn",i["@firebase/installations"]="fire-iid",i["@firebase/messaging"]="fire-fcm",i["@firebase/performance"]="fire-perf",i["@firebase/remote-config"]="fire-rc",i["@firebase/storage"]="fire-g
2cs",i["@firebase/firestore"]="fire-fst",i["fire-js"]="fire-js",i["firebase-wrapper"]="fire-js-all",i),p=new l.b("@firebase/app"),y=function(){function e(e,t,n){var r,i,l=this;this.firebase_=n,this.isDeleted_=!1,this.name_=t.name,this.automaticDataCollectionEnabled_=t.automaticDataCollectionEnabled||!1,this.options_=Object(a.j)(e),this.container=new s.b(t.name),this._addComponent(new s.a("app",(function(){return l}),"PUBLIC"));try{for(var u=Object(o.g)(this.firebase_.INTERNAL.components.values()),c=u.next();!c.done;c=u.next()){var f=c.value;this._addComponent(f)}}catch(h){r={error:h}}finally{try{c&&!c.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}}return Object.defineProperty(e.prototype,"automaticDataCollectionEnabled",{get:function(){return this.checkDestroyed_(),this.automaticDataCollectionEnabled_},set:function(e){this.checkDestroyed_(),this.automaticDataCollectionEnabled_=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"name",{get:function(){return this.checkDestroyed_(),this.name_},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"options",{get:function(){return this.checkDestroyed_(),this.options_},enumerable:!1,configurable:!0}),e.prototype.delete=function(){var e=this;return new Promise((function(t){e.checkDestroyed_(),t()})).then((function(){return e.firebase_.INTERNAL.removeApp(e.name_),Promise.all(e.container.getProviders().map((function(e){return e.delete()})))})).then((function(){e.isDeleted_=!0}))},e.prototype._getService=function(e,t){return void 0===t&&(t=h),this.checkDestroyed_(),this.container.getProvider(e).getImmediate({identifier:t})},e.prototype._removeServiceInstance=function(e,t){void 0===t&&(t=h),this.container.getProvider(e).clearInstance(t)},e.prototype._addComponent=function(e){try{this.container.addComponent(e)}catch(t){p.debug("Component "+e.name+" failed to register with FirebaseApp "+this.name,t)}},e.prototype._addOrOverwriteComponent=function(e){this.container.addOrOverwriteComponent(e)},e.prototype.checkDestroyed_=function(){if(this.isDeleted_)throw c.create("app-deleted",{appName:this.name_})},e}();y.prototype.name&&y.prototype.options||y.prototype.delete||console.log("dc");var v=function e(){var t=function(e){var t={},n=new Map,r={__esModule:!0,initializeApp:function(n,i){void 0===i&&(i={}),"object"===typeof i&&null!==i||(i={name:i});var o=i;void 0===o.name&&(o.name=h);var s=o.name;if("string"!==typeof s||!s)throw c.create("bad-app-name",{appName:String(s)});if(Object(a.h)(t,s))throw c.create("duplicate-app",{appName:s});var l=new e(n,o,r);return t[s]=l,l},app:i,registerVersion:function(e,t,n){var r,i=null!==(r=d[e])&&void 0!==r?r:e;n&&(i+="-"+n);var o=i.match(/\s|\//),a=t.match(/\s|\//);if(o||a){var l=['Unable to register library "'+i+'" with version "'+t+'":'];return o&&l.push('library name "'+i+'" contains illegal characters (whitespace or "/")'),o&&a&&l.push("and"),a&&l.push('version name "'+t+'" contains illegal characters (whitespace or "/")'),void p.warn(l.join(" "))}u(new s.a(i+"-version",(function(){return{library:i,version:t}}),"VERSION"))},setLogLevel:l.c,onLog:function(e,t){if(null!==e&&"function"!==typeof e)throw c.create("invalid-log-argument",{appName:name});Object(l.d)(e,t)},apps:null,SDK_VERSION:"8.0.1",INTERNAL:{registerComponent:u,removeApp:function(e){delete t[e]},components:n,useAsService:function(e,t){return"serverAuth"===t?null:t}}};function i(e){if(e=e||h,!Object(a.h)(t,e))throw c.create("no-app",{appName:e});return t[e]}function u(s){var l,u,f=s.name;if(n.has(f))return p.debug("There were multiple attempts to register component "+f+"."),"PUBLIC"===s.type?r[f]:null;if(n.set(f,s),"PUBLIC"===s.type){var h=function(e){if(void 0===e&&(e=i()),"function"!==typeof e[f])throw c.create("invalid-app-argument",{appName:f});return e[f]()};void 0!==s.serviceProps&&Object(a.k)(h,s.serviceProps),r[f]=h,e.prototype[f]=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return this._getService.bind(this,f).apply(this,s.multipleInstances?e:[])}}try{for(var d=Object(o.g)(Object.keys(t)),y=d.next();!y.done;y=d.next()){var v=y.value;t[v]._addComponent(s)}}catch(g){l={error:g}}finally{try{y&&!y.done&&(u=d.return)&&u.call(d)}finally{if(l)throw l.error}}return"PUBLIC"===s.type?r[f]:null}return r.default=r,Object.defineProperty(r,"apps",{get:function(){return Object.keys(t).map((function(e){return t[e]}))}}),i.App=e,r}(y);return t.INTERNAL=Object(o.a)(Object(o.a)({},t.INTERNAL),{createFirebaseNamespace:e,extendNamespace:function(e){Object(a.k)(t,e)},createSubscribe:a.i,ErrorFactory:a.b,deepExtend:a.k}),t}(),g=function(){function e(e){this.container=e}return e.prototype.getPlatformInfoString=function(){return this.container.getProviders().map((function(e){if(function(e){var t=e.getComponent();return"VERSION"===(null===t||void 0===t?void 0:t.type)}(e)){var t=e.getImmediate();return t.library+"/"+t.version}return null})).filter((function(e){return e})).join(" ")},e}();if(Object(a.n)()&&void 0!==self.firebase){p.warn("\n Warning: Firebase is already defined in the global scope. Please make sure\n Firebase library is only loaded once.\n ");var m=self.firebase.SDK_VERSION;m&&m.indexOf("LITE")>=0&&p.warn("\n Warning: You are trying to load Firebase while using Firebase Performance standalone script.\n You should load Firebase Performance with this instance of Firebase to avoid loading duplicate code.\n ")}var _=v.initializeApp;v.initializeApp=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Object(a.q)()&&p.warn('\n Warning: This is a browser-targeted Firebase bundle but it appears it is being\n run in a Node environment. If running in a Node environment, make sure you\n are using the bundle specified by the "main" field in package.json.\n \n If you are using Webpack, you can specify "main" as the first item in\n "resolve.mainFields":\n https://webpack.js.org/configuration/resolve/#resolvemainfields\n \n If using Rollup, use the @rollup/plugin-node-resolve plugin and specify "main"\n as the first item in "mainFields", e.g. [\'main\', \'module\'].\n https://github.com/rollup/@rollup/plugin-node-resolve\n '),_.apply(void 0,e)};var b=v;!function(e,t){e.INTERNAL.registerComponent(new s.a("platform-logger",(function(e){return new g(e)}),"PRIVATE")),e.registerVersion(f,"0.6.13",t),e.registerVersion("fire-js","")}(b),t.a=b},function(e,t,n){"use strict";n.d(t,"c",(function(){return h})),n.d(t,"a",(function(){return d})),n.d(t,"b",(function(){return p}));var r=n(3),i=n.n(r),o={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},a=i.a.createContext&&i.a.createContext(o),s=function(){return(s=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},l=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};function u(e){return e&&e.map((function(e,t){return i.a.createElement(e.tag,s({key:t},e.attr),u(e.child))}))}function c(e){return function(t){return i.a.createElement(f,s({attr:s({},e.attr)},t),u(e.child))}}function f(e){var t=function(t){var n,r=e.attr,o=e.size,a=e.title,u=l(e,["attr","size","title"]),c=o||t.size||"1em";return t.className&&(n=t.className),e.className&&(n=(n?n+" ":"")+e.className),i.a.createElement("svg",s({stroke:"currentColor",fill:"
2currentColor",strokeWidth:"0"},t.attr,r,u,{className:n,style:s(s({color:e.color||t.color},t.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&i.a.createElement("title",null,a),e.children)};return void 0!==a?i.a.createElement(a.Consumer,null,(function(e){return t(e)})):t(o)}function h(e){return c({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M459.37 151.716c.325 4.548.325 9.097.325 13.645 0 138.72-105.583 298.558-298.558 298.558-59.452 0-114.68-17.219-161.137-47.106 8.447.974 16.568 1.299 25.34 1.299 49.055 0 94.213-16.568 130.274-44.832-46.132-.975-84.792-31.188-98.112-72.772 6.498.974 12.995 1.624 19.818 1.624 9.421 0 18.843-1.3 27.614-3.573-48.081-9.747-84.143-51.98-84.143-102.985v-1.299c13.969 7.797 30.214 12.67 47.431 13.319-28.264-18.843-46.781-51.005-46.781-87.391 0-19.492 5.197-37.36 14.294-52.954 51.655 63.675 129.3 105.258 216.365 109.807-1.624-7.797-2.599-15.918-2.599-24.04 0-57.828 46.782-104.934 104.934-104.934 30.213 0 57.502 12.67 76.67 33.137 23.715-4.548 46.456-13.32 66.599-25.34-7.798 24.366-24.366 44.833-46.132 57.827 21.117-2.273 41.584-8.122 60.426-16.243-14.292 20.791-32.161 39.308-52.628 54.253z"}}]})(e)}function d(e){return c({tag:"svg",attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M16 132h416c8.837 0 16-7.163 16-16V76c0-8.837-7.163-16-16-16H16C7.163 60 0 67.163 0 76v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16z"}}]})(e)}function p(e){return c({tag:"svg",attr:{viewBox:"0 0 352 512"},child:[{tag:"path",attr:{d:"M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"}}]})(e)}},function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var n,s,l=a(e),u=1;u<arguments.length;u++){for(var c in n=Object(arguments[u]))i.call(n,c)&&(l[c]=n[c]);if(r){s=r(n);for(var f=0;f<s.length;f++)o.call(n,s[f])&&(l[s[f]]=n[s[f]])}}return l}},function(e,t,n){"use strict";var r=n(11);n.d(t,"a",(function(){return r.a}));r.a.registerVersion("firebase","8.1.1","app")},function(e,t,n){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}}},function(e,t,n){"use strict";var r=n(4);function i(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,n){if(!t)return e;var o;if(n)o=n(t);else if(r.isURLSearchParams(t))o=t.toString();else{var a=[];r.forEach(t,(function(e,t){null!==e&&"undefined"!==typeof e&&(r.isArray(e)?t+="[]":e=[e],r.forEach(e,(function(e){r.isDate(e)?e=e.toISOString():r.isObject(e)&&(e=JSON.stringify(e)),a.push(i(t)+"="+i(e))})))})),o=a.join("&")}if(o){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}},function(e,t,n){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},function(e,t,n){"use strict";(function(t){var r=n(4),i=n(41),o={"Content-Type":"application/x-www-form-urlencoded"};function a(e,t){!r.isUndefined(e)&&r.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var s={adapter:function(){var e;return("undefined"!==typeof XMLHttpRequest||"undefined"!==typeof t&&"[object process]"===Object.prototype.toString.call(t))&&(e=n(20)),e}(),transformRequest:[function(e,t){return i(t,"Accept"),i(t,"Content-Type"),r.isFormData(e)||r.isArrayBuffer(e)||r.isBuffer(e)||r.isStream(e)||r.isFile(e)||r.isBlob(e)?e:r.isArrayBufferView(e)?e.buffer:r.isURLSearchParams(e)?(a(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):r.isObject(e)?(a(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"===typeof e)try{e=JSON.parse(e)}catch(t){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(e){s.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){s.headers[e]=r.merge(o)})),e.exports=s}).call(this,n(19))},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"===typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"===typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var l,u=[],c=!1,f=-1;function h(){c&&l&&(c=!1,l.length?u=l.concat(u):f=-1,u.length&&d())}function d(){if(!c){var e=s(h);c=!0;for(var t=u.length;t;){for(l=u,u=[];++f<t;)l&&l[f].run();f=-1,t=u.length}l=null,c=!1,function(e){if(r===clearTimeout)return clearTimeout(e);
vendor: 4,239 bytes, line 2
2if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function y(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new p(e,t)),1!==u.length||c||s(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=y,i.addListener=y,i.once=y,i.off=y,i.removeListener=y,i.removeAllListeners=y,i.emit=y,i.prependListener=y,i.prependOnceListener=y,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,n){"use strict";var r=n(4),i=n(42),o=n(44),a=n(16),s=n(45),l=n(48),u=n(49),c=n(21);e.exports=function(e){return new Promise((function(t,n){var f=e.data,h=e.headers;r.isFormData(f)&&delete h["Content-Type"];var d=new XMLHttpRequest;if(e.auth){var p=e.auth.username||"",y=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";h.Authorization="Basic "+btoa(p+":"+y)}var v=s(e.baseURL,e.url);if(d.open(e.method.toUpperCase(),a(v,e.params,e.paramsSerializer),!0),d.timeout=e.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in d?l(d.getAllResponseHeaders()):null,o={data:e.responseType&&"text"!==e.responseType?d.response:d.responseText,status:d.status,statusText:d.statusText,headers:r,config:e,request:d};i(t,n,o),d=null}},d.onabort=function(){d&&(n(c("Request aborted",e,"ECONNABORTED",d)),d=null)},d.onerror=function(){n(c("Network Error",e,null,d)),d=null},d.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(c(t,e,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var g=(e.withCredentials||u(v))&&e.xsrfCookieName?o.read(e.xsrfCookieName):void 0;g&&(h[e.xsrfHeaderName]=g)}if("setRequestHeader"in d&&r.forEach(h,(function(e,t){"undefined"===typeof f&&"content-type"===t.toLowerCase()?delete h[t]:d.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(d.withCredentials=!!e.withCredentials),e.responseType)try{d.responseType=e.responseType}catch(m){if("json"!==e.responseType)throw m}"function"===typeof e.onDownloadProgress&&d.addEventListener("progress",e.onDownloadProgress),"function"===typeof e.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then((function(e){d&&(d.abort(),n(e),d=null)})),f||(f=null),d.send(f)}))}},function(e,t,n){"use strict";var r=n(43);e.exports=function(e,t,n,i,o){var a=new Error(e);return r(a,t,n,i,o)}},function(e,t,n){"use strict";var r=n(4);e.exports=function(e,t){t=t||{};var n={},i=["url","method","data"],o=["headers","auth","proxy","params"],a=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],s=["validateStatus"];function l(e,t){return r.isPlainObject(e)&&r.isPlainObject(t)?r.merge(e,t):r.isPlainObject(t)?r.merge({},t):r.isArray(t)?t.slice():t}function u(i){r.isUndefined(t[i])?r.isUndefined(e[i])||(n[i]=l(void 0,e[i])):n[i]=l(e[i],t[i])}r.forEach(i,(function(e){r.isUndefined(t[e])||(n[e]=l(void 0,t[e]))})),r.forEach(o,u),r.forEach(a,(function(i){r.isUndefined(t[i])?r.isUndefined(e[i])||(n[i]=l(void 0,e[i])):n[i]=l(void 0,t[i])})),r.forEach(s,(function(r){r in t?n[r]=l(e[r],t[r]):r in e&&(n[r]=l(void 0,e[r]))}));var c=i.concat(o).concat(a).concat(s),f=Object.keys(e).concat(Object.keys(t)).filter((function(e){return-1===c.indexOf(e)}));return r.forEach(f,u),n}},function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")}
2,r.prototype.__CANCEL__=!0,e.exports=r},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}},function(e,t,n){var r=n(24);e.exports=function(e,t){if(e){if("string"===typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}},function(e,t,n){"use strict";!function e(){if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"===typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}(),e.exports=n(32)},function(e,t,n){e.exports=n(36)},function(e,t,n){"use strict";var r=n(52),i=n(56);Object.defineProperty(t,"__esModule",{value:!0});var o=n(3),a=function(e){var t=e.duration,n=void 0===t?.3:t,r=e.delay,i=void 0===r?0:r,o=e.overlay;return n+i-(void 0===o?0:o)||0},s=function(e){return void 0===e};function l(e,t,n){return s(t)&&s(e)?n||0:e&&e>=0?e:t||0}var u=.3,c="linear",f="normal",h="none",d="running",p="all",y=o.createContext({animationStates:{},register:function(e){}});var v=function(e){return 1e3*(e||0)};function g(e){var t=e.keyframes,n=e.animationName;return"@keyframes ".concat(n," {").concat(function(e){var t=e.length;return e.reduce((function(e,n,r){var i=2===t?100*r:parseFloat((100/(t-1)).toFixed(2))*r;if("string"===typeof n)return"".concat(e," ").concat(i,"% {").concat(n,"}");var o=Object.keys(n);if(o.length&&isNaN(+o[0])){var a=o.reduce((function(e,t){return"".concat(e," ").concat((r=t,r?r.replace(/[A-Z]/g,(function(e){return"-".concat(e.toLowerCase())})):""),": ").concat(n[t],";");var r}),"");return"".concat(e," ").concat(i,"% {").concat(a,"}")}return"".concat(e," ").concat(Object.keys(n)[0],"% {").concat(Object.values(n)[0],"}")}),"")}(t),"}")}function m(e){var t,n=e.keyframes,r=e.animationName,i=document.querySelector("style[data-id=rsi]");i||((i=document.createElement("style")).setAttribute("data-id","rsi"),document.head.appendChild(i));try{t=i.sheet.cssRules.length}catch(o){t=0}try{i.sheet.insertRule(g({keyframes:n,animationName:r}),t)}catch(o){console.error("react simple animate, error found during insert style ",o)}return{styleTag:i,index:t}}var _=function(e,t){var n=Object.values(e.cssRules).findIndex((function(e){return e.name===t}));n>=0&&e.deleteRule(n)},b=function(){return"RSI-".concat(Math.random().toString(36).substr(2,9))},w=function(e){return e?"paused":d};t.Animate=function(e){var t=e.play,n=e.children,r=e.render,a=e.start,f=e.end,h=e.complete,d=void 0===h?"":h,g=e.onComplete,m=e.delay,_=void 0===m?0:m,b=e.duration,w=void 0===b?u:b,E=e.easeType,C=void 0===E?c:E,S=e.sequenceId,O=e.sequenceIndex,T=o.useRef(),k=o.useState(a||{}),x=i(k,2),N=x[0],P=x[1],I=o.useContext(y),R=I.register,D=I.animationStates,j=void 0===D?{}:D,L=l(O,S);return o.useEffect((function(){(!s(O)&&O>=0||S)&&R(e)}),[]),o.useEffect((function(){var e=j[L]||{};return P(Object.assign(Object.assign({},t||e.play?f:a),{transition:"".concat(p," ").concat(w,"s ").concat(C," ").concat(parseFloat(e.delay||_),"s")})),t&&(d||g)&&(T.current=setTimeout((function(){d&&P(d),g&&g()}),v(parseFloat(e.delay||_)+w))),function(){return T.current&&clearTimeout(T.current)}}),[L,j,t,w,C,_,g,a,f,d]),r?r({style:N}):o.createElement("div",{style:N},n)},t.AnimateGroup=function(e){var t=e.play,n=e.sequences,c=void 0===n?[]:n,f=e.children,h=o.useState({}),d=i(h,2),p=d[0],v=d[1],g=o.useRef({}),m=o.useCallback((function(e){var t=e.sequenceIndex,n=e.sequenceId;s(n)&&s(t)||(g.current[l(t,n)]=e)}),[]);return o.useEffect((function(){var e=Array.isArray(c)&&c.length?c:Object.values(g.current),n={};(t?e:r(e).reverse()).reduce((function(e,r,i){var o=r.sequenceId,s=r.sequenceIndex,c=r.duration,f=void 0===c?u:c,h=r.delay,d=r.overlay,p=l(s,o,i),y=a({duration:f,delay:h,overlay:d})+e;return n[p]={play:t,pause:!t,delay:0===i?h||0:h?e+h:e,controlled:!0},y}),0),v(n)}),[t]),o.createElement(y.Provider,{value:{animationStates:p,register:m}},f)},t.AnimateKeyframes=function(e){var t,n=e.children,r=e.play,a=void 0!==r&&r,s=e.pause,d=void 0!==s&&s,p=e.render,v=e.duration,g=void 0===v?u:v,E=e.delay,C=void 0===E?0:E,S=e.easeType,O=void 0===S?c:S,T=e.direction,k=void 0===T?f:T,x=e.fillMode,N=void 0===x?h:x,P=e.iterationCount,I=void 0===P?1:P,R=e.sequenceIndex,D=e.keyframes,j=e.sequenceId,L=o.useRef({forward:"",reverse:""}),A=o.useRef(!1),F=o.useRef({forward:{sheet:{}},reverse:{sheet:{}}}),M=l(R,j),U=o.useContext(y),W=U.register,z=U.animationStates,B=(void 0===z?{}:z)[M]||{},q=o.useState(!1),V=i(q,2)[1];o.useEffect((function(){var t=F.current,n=L.current;L.current.forward=b();var r=m({animationName:L.current.forward,keyframes:D});return L.current.reverse=b(),F.current.forward=r.styleTag,r=m({animationName:L.current.reverse,keyframes:D.reverse()}),F.current.reverse=r.styleTag,W(e),a&&V(!0),function(){_(t.forward.sheet,n.forward),_(t.reverse.sheet,n.reverse)}}),[]),B.controlled&&!A.current?(t=B.pause,B.pause||(A.current=!0)):t=d;var Q={animation:"".concat(g,"s ").concat(O," ").concat(B.delay||C,"s ").concat(I," ").concat(k," ").concat(N," ").concat(w(t)," ").concat(((B.controlled?B.play:a)?L.current.forward:L.current.reverse)||"")};return p?p({style:Q}):o.createElement("div",{style:Q||{}},n)},t.useAnimate=function(e){var t=e.start,n=e.end,r=e.complete,a=e.onComplete,s=e.delay,l=void 0===s?0:s,f=e.duration,h=void 0===f?u:f,d=e.easeType,y=void 0===d?c:d,g=o.useMemo((function(){return"".concat(p," ").concat(h,"s ").concat(y," ").concat(l,"s")}),[h,y,l]),m=o.useState({isPlaying:!1,style:Object.assign(Object.assign({},t),{transition:g})}),_=i(m,2),b=_[0],w=_[1],E=b.isPlaying,C=b.style,S=o.useRef();
2return o.useEffect((function(){return(S.current||r)&&E&&(S.current=setTimeout((function(){a&&a(),r&&w(Object.assign(Object.assign({},b),{style:r}))}),v(l+h))),function(){return S.current&&clearTimeout(S.current)}}),[E]),{isPlaying:E,style:C,play:o.useCallback((function(e){w(Object.assign(Object.assign({},b),{style:Object.assign(Object.assign({},e?n:t),{transition:g}),isPlaying:e}))}),[])}},t.useAnimateGroup=function(e){var t,n=e.sequences,s=void 0===n?[]:n,l=(t=s.length,Array.from({length:t},(function(){return null}))).map((function(t,n){return e.sequences[n].start})),y=o.useState(l),v=i(y,2),g=v[0],w=v[1],E=o.useState(!1),C=i(E,2),S=C[0],O=C[1],T=o.useRef([]),k=o.useRef([]),x=o.useRef();return o.useEffect((function(){return s.forEach((function(e,t){var n=e.keyframes,r=void 0!==n&&n;if(Array.isArray(r)){T.current[t]||(T.current[t]={},k.current[t]={}),T.current[t].forward=b();var i=m({animationName:T.current[t].forward,keyframes:r});k.current[t].forward=i.styleTag,T.current[t].reverse=b(),i=m({animationName:T.current[t].reverse,keyframes:r.reverse()}),k.current[t].reverse=i.styleTag}})),function(){return Object.values(T).forEach((function(e,t){var n=e.forward,r=e.reverse;k[t]&&(_(k[t].sheet,n),_(k[t].sheet,r))}))}}),[]),x.current=x.current?x.current:function(e){var t=0,n=e?T.current:r(T.current).reverse(),i=(e?s:r(s).reverse()).map((function(r,i){var o=r.duration,s=void 0===o?u:o,l=r.delay,y=void 0===l?0:l,v=r.overlay,g=r.keyframes,m=r.iterationCount,_=void 0===m?1:m,b=r.easeType,w=void 0===b?c:b,E=r.direction,C=void 0===E?f:E,S=r.fillMode,O=void 0===S?h:S,T=r.end,k=void 0===T?{}:T,x=r.start,N=void 0===x?{}:x,P=0===i?y:t,I="".concat(p," ").concat(s,"s ").concat(w," ").concat(P,"s");return t=a({duration:s,delay:y,overlay:v})+t,g?{animation:"".concat(s,"s ").concat(w," ").concat(P,"s ").concat(_," ").concat(C," ").concat(O," ").concat(d," ").concat(e?n[i].forward:n[i].reverse)}:Object.assign(Object.assign({},e?k:N),{transition:I})}));w(e?i:r(i).reverse()),O(!S)},{styles:g,play:x.current,isPlaying:S}},t.useAnimateKeyframes=function(e){var t=e.duration,n=void 0===t?u:t,r=e.delay,a=void 0===r?0:r,s=e.easeType,l=void 0===s?c:s,d=e.direction,p=void 0===d?f:d,v=e.fillMode,g=void 0===v?h:v,E=e.iterationCount,C=void 0===E?1:E,S=e.keyframes,O=o.useRef({forward:"",reverse:""}),T=o.useRef({forward:{sheet:{}},reverse:{sheet:{}}}),k=o.useContext(y).register,x=o.useState(!0),N=i(x,2),P=N[0],I=N[1],R=o.useState(!1),D=i(R,2),j=D[0],L=D[1],A=o.useRef();return o.useEffect((function(){var t=T.current,n=O.current;O.current.forward=b();var r=m({animationName:O.current.forward,keyframes:S});return T.current.forward=r.styleTag,O.current.reverse=b(),r=m({animationName:O.current.reverse,keyframes:S.reverse()}),T.current.reverse=r.styleTag,k(e),function(){_(t.forward.sheet,n.forward),_(t.reverse.sheet,n.reverse)}}),[]),A.current=A.current?A.current:function(e){return I(e)},{style:{animation:"".concat(n,"s ").concat(l," ").concat(a,"s ").concat(C," ").concat(p," ").concat(g," ").concat(w(j)," ").concat((P?O.current.forward:O.current.reverse)||"")},play:A.current,pause:L,isPlaying:P}}},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n(13);var r=n(3),i=60103;if(t.Fragment=60107,"function"===typeof Symbol&&Symbol.for){var o=Symbol.for;i=o("react.element"),t.Fragment=o("react.fragment")}var a=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s=Object.prototype.hasOwnProperty,l={key:!0,ref:!0,__self:!0,__source:!0};function u(e,t,n){var r,o={},u=null,c=null;for(r in void 0!==n&&(u=""+n),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(c=t.ref),t)s.call(t,r)&&!l.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===o[r]&&(o[r]=t[r]);return{$$typeof:i,type:e,key:u,ref:c,props:o,_owner:a.current}}t.jsx=u,t.jsxs=u},function(e,t,n){"use strict";var r=n(13),i=60103,o=60106;t.Fragment=60107,t.StrictMode=60108,t.Profiler=60114;var a=60109,s=60110,l=60112;t.Suspense=60113;var u=60115,c=60116;if("function"===typeof Symbol&&Symbol.for){var f=Symbol.for;i=f("react.element"),o=f("react.portal"),t.Fragment=f("react.fragment"),t.StrictMode=f("react.strict_mode"),t.Profiler=f("react.profiler"),a=f("react.provider"),s=f("react.context"),l=f("react.forward_ref"),t.Suspense=f("react.suspense"),u=f("react.memo"),
vendor: 8,555 bytes, line 2
2c=f("react.lazy")}var h="function"===typeof Symbol&&Symbol.iterator;function d(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},y={};function v(e,t,n){this.props=e,this.context=t,this.refs=y,this.updater=n||p}function g(){}function m(e,t,n){this.props=e,this.context=t,this.refs=y,this.updater=n||p}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if("object"!==typeof e&&"function"!==typeof e&&null!=e)throw Error(d(85));this.updater.enqueueSetState(this,e,t,"setState")},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},g.prototype=v.prototype;var _=m.prototype=new g;_.constructor=m,r(_,v.prototype),_.isPureReactComponent=!0;var b={current:null},w=Object.prototype.hasOwnProperty,E={key:!0,ref:!0,__self:!0,__source:!0};function C(e,t,n){var r,o={},a=null,s=null;if(null!=t)for(r in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(a=""+t.key),t)w.call(t,r)&&!E.hasOwnProperty(r)&&(o[r]=t[r]);var l=arguments.length-2;if(1===l)o.children=n;else if(1<l){for(var u=Array(l),c=0;c<l;c++)u[c]=arguments[c+2];o.children=u}if(e&&e.defaultProps)for(r in l=e.defaultProps)void 0===o[r]&&(o[r]=l[r]);return{$$typeof:i,type:e,key:a,ref:s,props:o,_owner:b.current}}function S(e){return"object"===typeof e&&null!==e&&e.$$typeof===i}var O=/\/+/g;function T(e,t){return"object"===typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function k(e,t,n,r,a){var s=typeof e;"undefined"!==s&&"boolean"!==s||(e=null);var l=!1;if(null===e)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(e.$$typeof){case i:case o:l=!0}}if(l)return a=a(l=e),e=""===r?"."+T(l,0):r,Array.isArray(a)?(n="",null!=e&&(n=e.replace(O,"$&/")+"/"),k(a,t,n,"",(function(e){return e}))):null!=a&&(S(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,n+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(O,"$&/")+"/")+e)),t.push(a)),1;if(l=0,r=""===r?".":r+":",Array.isArray(e))for(var u=0;u<e.length;u++){var c=r+T(s=e[u],u);l+=k(s,t,n,c,a)}else if("function"===typeof(c=function(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=h&&e[h]||e["@@iterator"])?e:null}(e)))for(e=c.call(e),u=0;!(s=e.next()).done;)l+=k(s=s.value,t,n,c=r+T(s,u++),a);else if("object"===s)throw t=""+e,Error(d(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return l}function x(e,t,n){if(null==e)return e;var r=[],i=0;return k(e,r,"","",(function(e){return t.call(n,e,i++)})),r}function N(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var P={current:null};function I(){var e=P.current;if(null===e)throw Error(d(321));return e}var R={ReactCurrentDispatcher:P,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:b,IsSomeRendererActing:{current:!1},assign:r};t.Children={map:x,forEach:function(e,t,n){x(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return x(e,(function(){t++})),t},toArray:function(e){return x(e,(function(e){return e}))||[]},only:function(e){if(!S(e))throw Error(d(143));return e}},t.Component=v,t.PureComponent=m,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,t.cloneElement=function(e,t,n){if(null===e||void 0===e)throw Error(d(267,e));var o=r({},e.props),a=e.key,s=e.ref,l=e._owner;if(null!=t){if(void 0!==t.ref&&(s=t.ref,l=b.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var u=e.type.defaultProps;for(c in t)w.call(t,c)&&!E.hasOwnProperty(c)&&(o[c]=void 0===t[c]&&void 0!==u?u[c]:t[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){u=Array(c);for(var f=0;f<c;f++)u[f]=arguments[f+2];o.children=u}return{$$typeof:i,type:e.type,key:a,ref:s,props:o,_owner:l}},t.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:s,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},t.createElement=C,t.createFactory=function(e){var t=C.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:l,render:e}},t.isValidElement=S,t.lazy=function(e){return{$$typeof:c,_payload:{_status:-1,_result:e},_init:N}},t.memo=function(e,t){return{$$typeof:u,type:e,compare:void 0===t?null:t}},t.useCallback=function(e,t){return I().useCallback(e,t)},t.useContext=function(e,t){return I().useContext(e,t)},t.useDebugValue=function(){},t.useEffect=function(e,t){return I().useEffect(e,t)},t.useImperativeHandle=function(e,t,n){return I().useImperativeHandle(e,t,n)},t.useLayoutEffect=function(e,t){return I().useLayoutEffect(e,t)},t.useMemo=function(e,t){return I().useMemo(e,t)},t.useReducer=function(e,t,n){return I().useReducer(e,t,n)},t.useRef=function(e){return I().useRef(e)},t.useState=function(e){return I().useState(e)},t.version="17.0.1"},function(e,t,n){"use strict";var r=n(3),i=n(13),o=n(33);function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!r)throw Error(a(227));var s=new Set,l={};function u(e,t){c(e,t),c(e+"Capture",t)}function c(e,t){for(l[e]=t,e=0;e<t.length;e++)s.add(t[e])}var f=!("undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement),h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d=Object.prototype.hasOwnProperty,p={},y={};function v(e,t,n,r,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var g={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){g[e]=new v(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];g[t]=new v(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){g[e]=new v(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){g[e]=new v(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){g[e]=new v(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){g[e]=new v(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){g[e]=new v(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){g[e]=new v(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){g[e]=new v(e,5,!1,e.toLowerCase(),null,!1,!1)}));var m=/[\-:]([a-z])/g;function _(e){return e[1].toUpperCase()}function b(e,t,n,r){var i=g.hasOwnProperty(t)?g[t]:null;(null!==i?0===i.type:!r&&(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])))||(function(e,t,n,r){if(null===t||"undefined"===typeof t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;
vendor: 7,707 bytes, line 2
2if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,i,r)&&(n=null),r||null===i?function(e){return!!d.call(y,e)||!d.call(p,e)&&(h.test(e)?y[e]=!0:(p[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=null===n?3!==i.type&&"":n:(t=i.attributeName,r=i.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(i=i.type)||4===i&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(m,_);g[t]=new v(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(m,_);g[t]=new v(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(m,_);g[t]=new v(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){g[e]=new v(e,1,!1,e.toLowerCase(),null,!1,!1)})),g.xlinkHref=new v("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){g[e]=new v(e,1,!1,e.toLowerCase(),null,!0,!0)}));var w=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,E=60103,C=60106,S=60107,O=60108,T=60114,k=60109,x=60110,N=60112,P=60113,I=60120,R=60115,D=60116,j=60121,L=60128,A=60129,F=60130,M=60131;if("function"===typeof Symbol&&Symbol.for){var U=Symbol.for;E=U("react.element"),C=U("react.portal"),S=U("react.fragment"),O=U("react.strict_mode"),T=U("react.profiler"),k=U("react.provider"),x=U("react.context"),N=U("react.forward_ref"),P=U("react.suspense"),I=U("react.suspense_list"),R=U("react.memo"),D=U("react.lazy"),j=U("react.block"),U("react.scope"),L=U("react.opaque.id"),A=U("react.debug_trace_mode"),F=U("react.offscreen"),M=U("react.legacy_hidden")}var W,z="function"===typeof Symbol&&Symbol.iterator;function B(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=z&&e[z]||e["@@iterator"])?e:null}function q(e){if(void 0===W)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);W=t&&t[1]||""}return"\n"+W+e}var V=!1;function Q(e,t){if(!e||V)return"";V=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"===typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(l){var r=l}Reflect.construct(e,[],t)}else{try{t.call()}catch(l){r=l}e.call(t.prototype)}else{try{throw Error()}catch(l){r=l}e()}}catch(l){if(l&&r&&"string"===typeof l.stack){for(var i=l.stack.split("\n"),o=r.stack.split("\n"),a=i.length-1,s=o.length-1;1<=a&&0<=s&&i[a]!==o[s];)s--;for(;1<=a&&0<=s;a--,s--)if(i[a]!==o[s]){if(1!==a||1!==s)do{if(a--,0>--s||i[a]!==o[s])return"\n"+i[a].replace(" at new "," at ")}while(1<=a&&0<=s);break}}}finally{V=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?q(e):""}function H(e){switch(e.tag){case 5:return q(e.type);case 16:return q("Lazy");case 13:return q("Suspense");case 19:return q("SuspenseList");case 0:case 2:case 15:return e=Q(e.type,!1);case 11:return e=Q(e.type.render,!1);case 22:return e=Q(e.type._render,!1);case 1:return e=Q(e.type,!0);default:return""}}function K(e){if(null==e)return null;if("function"===typeof e)return e.displayName||e.name||null;if("string"===typeof e)return e;switch(e){case S:return"Fragment";case C:return"Portal";case T:return"Profiler";case O:return"StrictMode";case P:return"Suspense";case I:return"SuspenseList"}if("object"===typeof e)switch(e.$$typeof){case x:return(e.displayName||"Context")+".Consumer";case k:return(e._context.displayName||"Context")+".Provider";case N:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case R:return K(e.type);case j:return K(e._render);case D:t=e._payload,e=e._init;try{return K(e(t))}catch(n){}}return null}function Y(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function $(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function G(e){e._valueTracker||(e._valueTracker=function(e){var t=$(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&"undefined"!==typeof n&&"function"===typeof n.get&&"function"===typeof n.set){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){r=""+e,o.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function X(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=$(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function J(e){if("undefined"===typeof(e=e||("undefined"!==typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Z(e,t){var n=t.checked;return i({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function ee(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=Y(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function te(e,t){null!=(t=t.checked)&&b(e,"checked",t,!1)}function ne(e,t){te(e,t);var n=Y(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?ie(e,t.type,n):t.hasOwnProperty("defaultValue")&&ie(e,t.type,Y(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function re(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function ie(e,t,n){"number"===t&&J(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function oe(e,t){return e=i({children:void 0},t),(t=function(e){var t="";
vendor: 4,117 bytes, line 2
2return r.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(t.children))&&(e.children=t),e}function ae(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Y(n),t=null,i=0;i<e.length;i++){if(e[i].value===n)return e[i].selected=!0,void(r&&(e[i].defaultSelected=!0));null!==t||e[i].disabled||(t=e[i])}null!==t&&(t.selected=!0)}}function se(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(a(91));return i({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function le(e,t){var n=t.value;if(null==n){if(n=t.children,t=t.defaultValue,null!=n){if(null!=t)throw Error(a(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(a(93));n=n[0]}t=n}null==t&&(t=""),n=t}e._wrapperState={initialValue:Y(n)}}function ue(e,t){var n=Y(t.value),r=Y(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function ce(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}var fe="http://www.w3.org/1999/xhtml",he="http://www.w3.org/2000/svg";function de(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function pe(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?de(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var ye,ve,ge=(ve=function(e,t){if(e.namespaceURI!==he||"innerHTML"in e)e.innerHTML=t;else{for((ye=ye||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ye.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,n,r){MSApp.execUnsafeLocalFunction((function(){return ve(e,t)}))}:ve);function me(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var _e={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},be=["Webkit","ms","Moz","O"];function we(e,t,n){return null==t||"boolean"===typeof t||""===t?"":n||"number"!==typeof t||0===t||_e.hasOwnProperty(e)&&_e[e]?(""+t).trim():t+"px"}function Ee(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),i=we(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}Object.keys(_e).forEach((function(e){be.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),_e[t]=_e[e]}))}));var Ce=i({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Se(e,t){if(t){if(Ce[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(a(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(a(60));if("object"!==typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(null!=t.style&&"object"!==typeof t.style)throw Error(a(62))}}function Oe(e,t){if(-1===e.indexOf("-"))return"string"===typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Te(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.n
vendor: 3,897 bytes, line 2
2odeType?e.parentNode:e}var ke=null,xe=null,Ne=null;function Pe(e){if(e=ei(e)){if("function"!==typeof ke)throw Error(a(280));var t=e.stateNode;t&&(t=ni(t),ke(e.stateNode,e.type,t))}}function Ie(e){xe?Ne?Ne.push(e):Ne=[e]:xe=e}function Re(){if(xe){var e=xe,t=Ne;if(Ne=xe=null,Pe(e),t)for(e=0;e<t.length;e++)Pe(t[e])}}function De(e,t){return e(t)}function je(e,t,n,r,i){return e(t,n,r,i)}function Le(){}var Ae=De,Fe=!1,Me=!1;function Ue(){null===xe&&null===Ne||(Le(),Re())}function We(e,t){var n=e.stateNode;if(null===n)return null;var r=ni(n);if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!==typeof n)throw Error(a(231,t,typeof n));return n}var ze=!1;if(f)try{var Be={};Object.defineProperty(Be,"passive",{get:function(){ze=!0}}),window.addEventListener("test",Be,Be),window.removeEventListener("test",Be,Be)}catch(ve){ze=!1}function qe(e,t,n,r,i,o,a,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var Ve=!1,Qe=null,He=!1,Ke=null,Ye={onError:function(e){Ve=!0,Qe=e}};function $e(e,t,n,r,i,o,a,s,l){Ve=!1,Qe=null,qe.apply(Ye,arguments)}function Ge(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!==(1026&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Xe(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Je(e){if(Ge(e)!==e)throw Error(a(188))}function Ze(e){if(!(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ge(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(null===i)break;var o=i.alternate;if(null===o){if(null!==(r=i.return)){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return Je(i),e;if(o===r)return Je(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var s=!1,l=i.child;l;){if(l===n){s=!0,n=i,r=o;break}if(l===r){s=!0,r=i,n=o;break}l=l.sibling}if(!s){for(l=o.child;l;){if(l===n){s=!0,n=o,r=i;break}if(l===r){s=!0,r=o,n=i;break}l=l.sibling}if(!s)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(e)))return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function et(e,t){for(var n=e.alternate;null!==t;){if(t===e||t===n)return!0;t=t.return}return!1}var tt,nt,rt,it,ot=!1,at=[],st=null,lt=null,ut=null,ct=new Map,ft=new Map,ht=[],dt="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function pt(e,t,n,r,i){return{blockedOn:e,domEventName:t,eventSystemFlags:16|n,nativeEvent:i,targetContainers:[r]}}function yt(e,t){switch(e){case"focusin":case"focusout":st=null;break;case"dragenter":case"dragleave":lt=null;break;case"mouseover":case"mouseout":ut=null;break;case"pointerover":case"pointerout":ct.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":ft.delete(t.pointerId)}}function vt(e,t,n,r,i,o){return null===e||e.nativeEvent!==o?(e=pt(t,n,r,i,o),null!==t&&(null!==(t=ei(t))&&nt(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==i&&-1===t.indexOf(i)&&t.push(i),e)}function gt(e){var t=Zr(e.target);if(null!==t){var n=Ge(t);
vendor: 26,922 bytes, line 2
2if(null!==n)if(13===(t=n.tag)){if(null!==(t=Xe(n)))return e.blockedOn=t,void it(e.lanePriority,(function(){o.unstable_runWithPriority(e.priority,(function(){rt(n)}))}))}else if(3===t&&n.stateNode.hydrate)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function mt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=ei(n))&&nt(t),e.blockedOn=n,!1;t.shift()}return!0}function _t(e,t,n){mt(e)&&n.delete(t)}function bt(){for(ot=!1;0<at.length;){var e=at[0];if(null!==e.blockedOn){null!==(e=ei(e.blockedOn))&&tt(e);break}for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n){e.blockedOn=n;break}t.shift()}null===e.blockedOn&&at.shift()}null!==st&&mt(st)&&(st=null),null!==lt&&mt(lt)&&(lt=null),null!==ut&&mt(ut)&&(ut=null),ct.forEach(_t),ft.forEach(_t)}function wt(e,t){e.blockedOn===t&&(e.blockedOn=null,ot||(ot=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,bt)))}function Et(e){function t(t){return wt(t,e)}if(0<at.length){wt(at[0],e);for(var n=1;n<at.length;n++){var r=at[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==st&&wt(st,e),null!==lt&&wt(lt,e),null!==ut&&wt(ut,e),ct.forEach(t),ft.forEach(t),n=0;n<ht.length;n++)(r=ht[n]).blockedOn===e&&(r.blockedOn=null);for(;0<ht.length&&null===(n=ht[0]).blockedOn;)gt(n),null===n.blockedOn&&ht.shift()}function Ct(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var St={animationend:Ct("Animation","AnimationEnd"),animationiteration:Ct("Animation","AnimationIteration"),animationstart:Ct("Animation","AnimationStart"),transitionend:Ct("Transition","TransitionEnd")},Ot={},Tt={};function kt(e){if(Ot[e])return Ot[e];if(!St[e])return e;var t,n=St[e];for(t in n)if(n.hasOwnProperty(t)&&t in Tt)return Ot[e]=n[t];return e}f&&(Tt=document.createElement("div").style,"AnimationEvent"in window||(delete St.animationend.animation,delete St.animationiteration.animation,delete St.animationstart.animation),"TransitionEvent"in window||delete St.transitionend.transition);var xt=kt("animationend"),Nt=kt("animationiteration"),Pt=kt("animationstart"),It=kt("transitionend"),Rt=new Map,Dt=new Map,jt=["abort","abort",xt,"animationEnd",Nt,"animationIteration",Pt,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",It,"transitionEnd","waiting","waiting"];function Lt(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],i=e[n+1];i="on"+(i[0].toUpperCase()+i.slice(1)),Dt.set(r,t),Rt.set(r,i),u(i,[r])}}(0,o.unstable_now)();var At=8;function Ft(e){if(0!==(1&e))return At=15,1;if(0!==(2&e))return At=14,2;if(0!==(4&e))return At=13,4;var t=24&e;return 0!==t?(At=12,t):0!==(32&e)?(At=11,32):0!==(t=192&e)?(At=10,t):0!==(256&e)?(At=9,256):0!==(t=3584&e)?(At=8,t):0!==(4096&e)?(At=7,4096):0!==(t=4186112&e)?(At=6,t):0!==(t=62914560&e)?(At=5,t):67108864&e?(At=4,67108864):0!==(134217728&e)?(At=3,134217728):0!==(t=805306368&e)?(At=2,t):0!==(1073741824&e)?(At=1,1073741824):(At=8,e)}function Mt(e,t){var n=e.pendingLanes;if(0===n)return At=0;var r=0,i=0,o=e.expiredLanes,a=e.suspendedLanes,s=e.pingedLanes;if(0!==o)r=o,i=At=15;else if(0!==(o=134217727&n)){var l=o&~a;0!==l?(r=Ft(l),i=At):0!==(s&=o)&&(r=Ft(s),i=At)}else 0!==(o=n&~a)?(r=Ft(o),i=At):0!==s&&(r=Ft(s),i=At);if(0===r)return 0;if(r=n&((0>(r=31-Vt(r))?0:1<<r)<<1)-1,0!==t&&t!==r&&0===(t&a)){if(Ft(t),i<=At)return t;At=i}if(0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)i=1<<(n=31-Vt(t)),r|=e[n],t&=~i;return r}function Ut(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function Wt(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return 0===(e=zt(24&~t))?Wt(10,t):e;case 10:return 0===(e=zt(192&~t))?Wt(8,t):e;case 8:return 0===(e=zt(3584&~t))&&(0===(e=zt(4186112&~t))&&(e=512)),e;case 2:return 0===(t=zt(805306368&~t))&&(t=268435456),t}throw Error(a(358,e))}function zt(e){return e&-e}function Bt(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function qt(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,(e=e.eventTimes)[t=31-Vt(t)]=n}var Vt=Math.clz32?Math.clz32:function(e){return 0===e?32:31-(Qt(e)/Ht|0)|0},Qt=Math.log,Ht=Math.LN2;var Kt=o.unstable_UserBlockingPriority,Yt=o.unstable_runWithPriority,$t=!0;function Gt(e,t,n,r){Fe||Le();var i=Jt,o=Fe;Fe=!0;try{je(i,e,t,n,r)}finally{(Fe=o)||Ue()}}function Xt(e,t,n,r){Yt(Kt,Jt.bind(null,e,t,n,r))}function Jt(e,t,n,r){var i;if($t)if((i=0===(4&t))&&0<at.length&&-1<dt.indexOf(e))e=pt(null,e,t,n,r),at.push(e);else{var o=Zt(e,t,n,r);if(null===o)i&&yt(e,r);else{if(i){if(-1<dt.indexOf(e))return e=pt(o,e,t,n,r),void at.push(e);if(function(e,t,n,r,i){switch(t){case"focusin":return st=vt(st,e,t,n,r,i),!0;case"dragenter":return lt=vt(lt,e,t,n,r,i),!0;case"mouseover":return ut=vt(ut,e,t,n,r,i),!0;case"pointerover":var o=i.pointerId;return ct.set(o,vt(ct.get(o)||null,e,t,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,ft.set(o,vt(ft.get(o)||null,e,t,n,r,i)),!0}return!1}(o,e,t,n,r))return;yt(e,r)}Rr(e,t,r,null,n)}}}function Zt(e,t,n,r){var i=Te(r);if(null!==(i=Zr(i))){var o=Ge(i);if(null===o)i=null;else{var a=o.tag;if(13===a){if(null!==(i=Xe(o)))return i;i=null}else if(3===a){if(o.stateNode.hydrate)return 3===o.tag?o.stateNode.containerInfo:null;i=null}else o!==i&&(i=null)}}return Rr(e,t,r,i,n),null}var en=null,tn=null,nn=null;function rn(){if(nn)return nn;var e,t,n=tn,r=n.length,i="value"in en?en.value:en.textContent,o=i.length;for(e=0;e<r&&n[e]===i[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===i[o-t];t++);return nn=i.slice(e,1<t?1-t:void 0)}function on(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function an(){return!0}function sn(){return!1}function ln(e){function t(t,n,r,i,o){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(i):i[a]);return this.isDefaultPrevented=(null!=i.defaultPrevented?i.defaultPrevented:!1===i.returnValue)?an:sn,this.isPropagationStopped=sn,this}return i(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!==typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=an)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!==typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=an)},persist:function(){},isPersistent:an}),t}var un,cn,fn,hn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},dn=ln(hn),pn=i({},hn,{view:0,detail:0}),yn=ln(pn),vn=i({},pn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:kn,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==fn&&(fn&&"mousemove"===e.type?(un=e.screenX-fn.screenX,cn=e.screenY-fn.screenY):cn=un=0,fn=e),un)},movementY:function(e){return"movementY"in e?e.movementY:cn}}),gn=ln(vn),mn=ln(i({},vn,{dataTransfer:0})),_n=ln(i({},pn,{relatedTarget:0})),bn=ln(i({},hn,{animationName:0,elapsedTime:0,pseudoElement:0})),wn=ln(i({},hn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}})),En=ln(i({},hn,{data:0})),Cn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Sn={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},On={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Tn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=On[e])&&!!t[e]}function kn(){return Tn}var xn=ln(i({},pn,{key:function(e){if(e.key){var t=Cn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=on(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?Sn[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:kn,charCode:function(e){return"keypress"===e.type?on(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?on(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}})),Nn=ln(i({},vn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Pn=ln(i({},pn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:kn})),In=ln(i({},hn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Rn=ln(i({},vn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Dn=[9,13,27,32],jn=f&&"CompositionEvent"in window,Ln=null;f&&"documentMode"in document&&(Ln=document.documentMode);var An=f&&"TextEvent"in window&&!Ln,Fn=f&&(!jn||Ln&&8<Ln&&11>=Ln),Mn=String.fromCharCode(32),Un=!1;function Wn(e,t){switch(e){case"keyup":return-1!==Dn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function zn(e){return"object"===typeof(e=e.detail)&&"data"in e?e.data:null}var Bn=!1;var qn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!qn[e.type]:"textarea"===t}function Qn(e,t,n,r){Ie(r),0<(t=jr(t,"onChange")).length&&(n=new dn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Hn=null,Kn=null;function Yn(e){Tr(e,0)}function $n(e){if(X(ti(e)))return e}function Gn(e,t){if("change"===e)return t}var Xn=!1;if(f){var Jn;if(f){var Zn="oninput"in document;if(!Zn){var er=document.createElement("div");er.setAttribute("oninput","return;"),Zn="function"===typeof er.oninput}Jn=Zn}else Jn=!1;Xn=Jn&&(!document.documentMode||9<document.documentMode)}function tr(){Hn&&(Hn.detachEvent("onpropertychange",nr),Kn=Hn=null)}function nr(e){if("value"===e.propertyName&&$n(Kn)){var t=[];if(Qn(t,Kn,e,Te(e)),e=Yn,Fe)e(t);else{Fe=!0;try{De(e,t)}finally{Fe=!1,Ue()}}}}function rr(e,t,n){"focusin"===e?(tr(),Kn=n,(Hn=t).attachEvent("onpropertychange",nr)):"focusout"===e&&tr()}function ir(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return $n(Kn)}function or(e,t){if("click"===e)return $n(t)}function ar(e,t){if("input"===e||"change"===e)return $n(t)}var sr="function"===typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e===1/t)||e!==e&&t!==t},lr=Object.prototype.hasOwnProperty;function ur(e,t){if(sr(e,t))return!0;if("object"!==typeof e||null===e||"object"!==typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!lr.call(t,n[r])||!sr(e[n[r]],t[n[r]]))return!1;return!0}function cr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function fr(e,t){var n,r=cr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=cr(r)}}function hr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?hr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function dr(){for(var e=window,t=J();t instanceof e.HTMLIFrameElement;){try{var n="string"===typeof t.contentWindow.location.href}catch(r){n=!1}if(!n)break;t=J((e=t.contentWindow).document)}return t}function pr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var yr=f&&"documentMode"in document&&11>=document.documentMode,vr=null,gr=null,mr=null,_r=!1;function br(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;_r||null==vr||vr!==J(r)||("selectionStart"in(r=vr)&&pr(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},mr&&ur(mr,r)||(mr=r,0<(r=jr(gr,"onSelect")).length&&(t=new dn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=vr)))}Lt("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0),Lt("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1),Lt(jt,2);for(var wr="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),Er=0;Er<wr.length;Er++)Dt.set(wr[Er],0);c("onMouseEnter",["mouseout","mouseover"]),c("onMouseLeave",["mouseout","mouseover"]),c("onPointerEnter",["pointerout","pointerover"]),c("onPointerLeave",["pointerout","pointerover"]),u("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),u("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),u("onBeforeInput",["compositionend","keypress","textInput","paste"]),u("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Cr="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Sr=new Set("cancel close invalid load scroll toggle".split(" ").concat(Cr));function Or(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,function(e,t,n,r,i,o,s,l,u){if($e.apply(this,arguments),Ve){if(!Ve)throw Error(a(198));var c=Qe;Ve=!1,Qe=null,He||(He=!0,Ke=c)}}(r,t,void 0,e),e.currentTarget=null}function Tr(e,t){t=0!==(4&t);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==o&&i.isPropagationStopped())break e;Or(i,s,u),o=l}else for(a=0;a<r.length;a++){if(l=(s=r[a]).instance,u=s.currentTarget,s=s.listener,l!==o&&i.isPropagationStopped())break e;Or(i,s,u),o=l}}}if(He)throw e=Ke,He=!1,Ke=null,e}function kr(e,t){var n=ri(t),r=e+"__bubble";n.has(r)||(Ir(t,e,2,!1),n.add(r))}var xr="_reactListening"+Math.random().toString(36).slice(2);function Nr(e){e[xr]||(e[xr]=!0,s.forEach((function(t){Sr.has(t)||Pr(t,!1,e,null),Pr(t,!0,e,null)})))}function Pr(e,t,n,r){var i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=n;if("selectionchange"===e&&9!==n.nodeType&&(o=n.ownerDocument),null!==r&&!t&&Sr.has(e)){if("scroll"!==e)return;i|=2,o=r}var a=ri(o),s=e+"__"+(t?"capture":"bubble");a.has(s)||(t&&(i|=4),Ir(o,e,i,t),a.add(s))}function Ir(e,t,n,r){var i=Dt.get(t);switch(void 0===i?2:i){case 0:i=Gt;break;case 1:i=Xt;break;default:i=Jt}n=i.bind(null,t,n,e),i=void 0,!ze||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(i=!0),r?void 0!==i?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):void 0!==i?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function Rr(e,t,n,r,i){var o=r;if(0===(1&t)&&0===(2&t)&&null!==r)e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var s=r.stateNode.containerInfo;if(s===i||8===s.nodeType&&s.parentNode===i)break;if(4===a)for(a=r.return;null!==a;){var l=a.tag;if((3===l||4===l)&&((l=a.stateNode.containerInfo)===i||8===l.nodeType&&l.parentNode===i))return;a=a.return}for(;null!==s;){if(null===(a=Zr(s)))return;if(5===(l=a.tag)||6===l){r=o=a;continue e}s=s.parentNode}}r=r.return}!function(e,t,n){if(Me)return e(t,n);Me=!0;try{Ae(e,t,n)}finally{Me=!1,Ue()}}((function(){var r=o,i=Te(n),a=[];e:{var s=Rt.get(e);if(void 0!==s){var l=dn,u=e;switch(e){case"keypress":if(0===on(n))break e;case"keydown":case"keyup":l=xn;break;case"focusin":u="focus",l=_n;break;case"focusout":u="blur",l=_n;break;case"beforeblur":case"afterblur":l=_n;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":l=gn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":l=mn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":l=Pn;break;case xt:case Nt:case Pt:l=bn;break;case It:l=In;break;case"scroll":l=yn;break;case"wheel":l=Rn;break;case"copy":case"cut":case"paste":l=wn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":l=Nn}var c=0!==(4&t),f=!c&&"scroll"===e,h=c?null!==s?s+"Capture":null:s;c=[];for(var d,p=r;null!==p;){var y=(d=p).stateNode;if(5===d.tag&&null!==y&&(d=y,null!==h&&(null!=(y=We(p,h))&&c.push(Dr(p,y,d)))),f)break;p=p.return}0<c.length&&(s=new l(s,u,null,n,i),a.push({event:s,listeners:c}))}}if(0===(7&t)){if(l="mouseout"===e||"pointerout"===e,(!(s="mouseover"===e||"pointerover"===e)||0!==(16&t)||!(u=n.relatedTarget||n.fromElement)||!Zr(u)&&!u[Xr])&&(l||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,l?(l=r,null!==(u=(u=n.relatedTarget||n.toElement)?Zr(u):null)&&(u!==(f=Ge(u))||5!==u.tag&&6!==u.tag)&&(u=null)):(l=null,u=r),l!==u)){if(c=gn,y="onMouseLeave",h="onMouseEnter",p="mouse","pointerout"!==e&&"pointerover"!==e||(c=Nn,y="onPointerLeave",h="onPointerEnter",p="pointer"),f=null==l?s:ti(l),d=null==u?s:ti(u),(s=new c(y,p+"leave",l,n,i)).target=f,s.relatedTarget=d,y=null,Zr(i)===r&&((c=new c(h,p+"enter",u,n,i)).target=d,c.relatedTarget=f,y=c),f=y,l&&u)e:{for(h=u,p=0,d=c=l;d;d=Lr(d))p++;for(d=0,y=h;y;y=Lr(y))d++;for(;0<p-d;)c=Lr(c),p--;for(;0<d-p;)h=Lr(h),d--;for(;p--;){if(c===h||null!==h&&c===h.alternate)break e;c=Lr(c),h=Lr(h)}c=null}else c=null;null!==l&&Ar(a,s,l,c,!1),null!==u&&null!==f&&Ar(a,f,u,c,!0)}if("select"===(l=(s=r?ti(r):window).nodeName&&s.nodeName.toLowerCase())||"input"===l&&"file"===s.type)var v=Gn;else if(Vn(s))if(Xn)v=ar;else{v=ir;var g=rr}else(l=s.nodeName)&&"input"===l.toLowerCase()&&("checkbox"===s.type||"radio"===s.type)&&(v=or);switch(v&&(v=v(e,r))?Qn(a,v,n,i):(g&&g(e,s,r),"focusout"===e&&(g=s._wrapperState)&&g.controlled&&"number"===s.type&&ie(s,"number",s.value)),g=r?ti(r):window,e){case"focusin":(Vn(g)||"true"===g.contentEditable)&&(vr=g,gr=r,mr=null);break;case"focusout":mr=gr=vr=null;break;case"mousedown":_r=!0;break;case"contextmenu":case"mouseup":case"dragend":_r=!1,br(a,n,i);break;case"selectionchange":if(yr)break;case"keydown":case"keyup":br(a,n,i)}var m;if(jn)e:{switch(e){case"compositionstart":var _="onCompositionStart";break e;case"compositionend":_="onCompositionEnd";break e;case"compositionupdate":_="onCompositionUpdate";break e}_=void 0}else Bn?Wn(e,n)&&(_="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(_="onCompositionStart");_&&(Fn&&"ko"!==n.locale&&(Bn||"onCompositionStart"!==_?"onCompositionEnd"===_&&Bn&&(m=rn()):(tn="value"in(en=i)?en.value:en.textContent,Bn=!0)),0<(g=jr(r,_)).length&&(_=new En(_,e,null,n,i),a.push({event:_,listeners:g}),m?_.data=m:null!==(m=zn(n))&&(_.data=m))),(m=An?function(e,t){switch(e){case"compositionend":return zn(t);case"keypress":return 32!==t.which?null:(Un=!0,Mn);case"textInput":return(e=t.data)===Mn&&Un?null:e;default:return null}}(e,n):function(e,t){if(Bn)return"compositionend"===e||!jn&&Wn(e,t)?(e=rn(),nn=tn=en=null,Bn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Fn&&"ko"!==t.locale?null:t.data;default:return null}}(e,n))&&(0<(r=jr(r,"onBeforeInput")).length&&(i=new En("onBeforeInput","beforeinput",null,n,i),a.push({event:i,listeners:r}),i.data=m))}Tr(a,t)}))}function Dr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function jr(e,t){for(var n=t+"Capture",r=[];null!==e;){var i=e,o=i.stateNode;5===i.tag&&null!==o&&(i=o,null!=(o=We(e,n))&&r.unshift(Dr(e,o,i)),null!=(o=We(e,t))&&r.push(Dr(e,o,i))),e=e.return}return r}function Lr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Ar(e,t,n,r,i){for(var o=t._reactName,a=[];null!==n&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(null!==l&&l===r)break;5===s.tag&&null!==u&&(s=u,i?null!=(l=We(n,o))&&a.unshift(Dr(n,l,s)):i||null!=(l=We(n,o))&&a.push(Dr(n,l,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}function Fr(){}var Mr=null,Ur=null;function Wr(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function zr(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"===typeof t.children||"number"===typeof t.children||"object"===typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var Br="function"===typeof setTimeout?setTimeout:void 0,qr="function"===typeof clearTimeout?clearTimeout:void 0;function Vr(e){1===e.nodeType?e.textContent="":9===e.nodeType&&(null!=(e=e.body)&&(e.textContent=""))}function Qr(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Hr(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var Kr=0;var Yr=Math.random().toString(36).slice(2),$r="__reactFiber$"+Yr,Gr="__reactProps$"+Yr,Xr="__reactContainer$"+Yr,Jr="__reactEvents$"+Yr;function Zr(e){var t=e[$r];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Xr]||n[$r]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Hr(e);null!==e;){if(n=e[$r])return n;e=Hr(e)}return t}n=(e=n).parentNode}return null}function ei(e){return!(e=e[$r]||e[Xr])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function ti(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(a(33))}function ni(e){return e[Gr]||null}function ri(e){var t=e[Jr];return void 0===t&&(t=e[Jr]=new Set),t}var ii=[],oi=-1;function ai(e){return{current:e}}function si(e){0>oi||(e.current=ii[oi],ii[oi]=null,oi--)}function li(e,t){oi++,ii[oi]=e.current,e.current=t}var ui={},ci=ai(ui),fi=ai(!1),hi=ui;function di(e,t){var n=e.type.contextTypes;if(!n)return ui;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i,o={};for(i in n)o[i]=t[i];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function pi(e){return null!==(e=e.childContextTypes)&&void 0!==e}function yi(){si(fi),si(ci)}function vi(e,t,n){if(ci.current!==ui)throw Error(a(168));li(ci,t),li(fi,n)}function gi(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,"function"!==typeof r.getChildContext)return n;for(var o in r=r.getChildContext())if(!(o in e))throw Error(a(108,K(t)||"Unknown",o));return i({},n,r)}function mi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||ui,hi=ci.current,li(ci,e),li(fi,fi.current),!0}function _i(e,t,n){var r=e.stateNode;if(!r)throw Error(a(169));n?(e=gi(e,t,hi),r.__reactInternalMemoizedMergedChildContext=e,si(fi),si(ci),li(ci,e)):si(fi),li(fi,n)}var bi=null,wi=null,Ei=o.unstable_runWithPriority,Ci=o.unstable_scheduleCallback,Si=o.unstable_cancelCallback,Oi=o.unstable_shouldYield,Ti=o.unstable_requestPaint,ki=o.unstable_now,xi=o.unstable_getCurrentPriorityLevel,Ni=o.unstable_ImmediatePriority,Pi=o.unstable_UserBlockingPriority,Ii=o.unstable_NormalPriority,Ri=o.unstable_LowPriority,Di=o.unstable_IdlePriority,ji={},Li=void 0!==Ti?Ti:function(){},Ai=null,Fi=null,Mi=!1,Ui=ki(),Wi=1e4>Ui?ki:function(){return ki()-Ui};function zi(){switch(xi()){case Ni:return 99;case Pi:return 98;case Ii:return 97;case Ri:return 96;case Di:return 95;default:throw Error(a(332))}}function Bi(e){switch(e){case 99:return Ni;case 98:return Pi;case 97:return Ii;case 96:return Ri;case 95:return Di;default:throw Error(a(332))}}function qi(e,t){return e=Bi(e),Ei(e,t)}function Vi(e,t,n){return e=Bi(e),Ci(e,t,n)}function Qi(){if(null!==Fi){var e=Fi;Fi=null,Si(e)}Hi()}function Hi(){if(!Mi&&null!==Ai){Mi=!0;var e=0;try{var t=Ai;qi(99,(function(){for(;e<t.length;e++){var n=t[e];do{n=n(!0)}while(null!==n)}})),Ai=null}catch(n){throw null!==Ai&&(Ai=Ai.slice(e+1)),Ci(Ni,Qi),n}finally{Mi=!1}}}var Ki=w.ReactCurrentBatchConfig;function Yi(e,t){if(e&&e.defaultProps){for(var n in t=i({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}var $i=ai(null),Gi=null,Xi=null,Ji=null;function Zi(){Ji=Xi=Gi=null}function eo(e){var t=$i.current;si($i),e.type._context._currentValue=t}function to(e,t){for(;null!==e;){var n=e.alternate;if((e.childLanes&t)===t){if(null===n||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,null!==n&&(n.childLanes|=t);e=e.return}}
2function no(e,t){Gi=e,Ji=Xi=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(ja=!0),e.firstContext=null)}function ro(e,t){if(Ji!==e&&!1!==t&&0!==t)if("number"===typeof t&&1073741823!==t||(Ji=e,t=1073741823),t={context:e,observedBits:t,next:null},null===Xi){if(null===Gi)throw Error(a(308));Xi=t,Gi.dependencies={lanes:0,firstContext:t,responders:null}}else Xi=Xi.next=t;return e._currentValue}var io=!1;function oo(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function ao(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function so(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function lo(e,t){if(null!==(e=e.updateQueue)){var n=(e=e.shared).pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function uo(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var i=null,o=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===o?i=o=a:o=o.next=a,n=n.next}while(null!==n);null===o?i=o=t:o=o.next=t}else i=o=t;return n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function co(e,t,n,r){var o=e.updateQueue;io=!1;var a=o.firstBaseUpdate,s=o.lastBaseUpdate,l=o.shared.pending;if(null!==l){o.shared.pending=null;var u=l,c=u.next;u.next=null,null===s?a=c:s.next=c,s=u;var f=e.alternate;if(null!==f){var h=(f=f.updateQueue).lastBaseUpdate;h!==s&&(null===h?f.firstBaseUpdate=c:h.next=c,f.lastBaseUpdate=u)}}if(null!==a){for(h=o.baseState,s=0,f=c=u=null;;){l=a.lane;var d=a.eventTime;if((r&l)===l){null!==f&&(f=f.next={eventTime:d,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var p=e,y=a;switch(l=t,d=n,y.tag){case 1:if("function"===typeof(p=y.payload)){h=p.call(d,h,l);break e}h=p;break e;case 3:p.flags=-4097&p.flags|64;case 0:if(null===(l="function"===typeof(p=y.payload)?p.call(d,h,l):p)||void 0===l)break e;h=i({},h,l);break e;case 2:io=!0}}null!==a.callback&&(e.flags|=32,null===(l=o.effects)?o.effects=[a]:l.push(a))}else d={eventTime:d,lane:l,tag:a.tag,payload:a.payload,callback:a.callback,next:null},null===f?(c=f=d,u=h):f=f.next=d,s|=l;if(null===(a=a.next)){if(null===(l=o.shared.pending))break;a=l.next,l.next=null,o.lastBaseUpdate=l,o.shared.pending=null}}null===f&&(u=h),o.baseState=u,o.firstBaseUpdate=c,o.lastBaseUpdate=f,Ms|=s,e.lanes=s,e.memoizedState=h}}function fo(e,t,n){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(null!==i){if(r.callback=null,r=n,"function"!==typeof i)throw Error(a(191,i));i.call(r)}}}var ho=(new r.Component).refs;function po(e,t,n,r){n=null===(n=n(r,t=e.memoizedState))||void 0===n?t:i({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var yo={isMounted:function(e){return!!(e=e._reactInternals)&&Ge(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ul(),i=cl(e),o=so(r,i);o.payload=t,void 0!==n&&null!==n&&(o.callback=n),lo(e,o),fl(e,i,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ul(),i=cl(e),o=so(r,i);o.tag=1,o.payload=t,void 0!==n&&null!==n&&(o.callback=n),lo(e,o),fl(e,i,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ul(),r=cl(e),i=so(n,r);i.tag=2,void 0!==t&&null!==t&&(i.callback=t),lo(e,i),fl(e,r,n)}};function vo(e,t,n,r,i,o,a){return"function"===typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,o,a):!t.prototype||!t.prototype.isPureReactComponent||(!ur(n,r)||!ur(i,o))}function go(e,t,n){var r=!1,i=ui,o=t.contextType;return"object"===typeof o&&null!==o?o=ro(o):(i=pi(t)?hi:ci.current,o=(r=null!==(r=t.contextTypes)&&void 0!==r)?di(e,i):ui),t=new t(n,o),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=yo,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function mo(e,t,n,r){e=t.state,"function"===typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"===typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&yo.enqueueReplaceState(t,t.state,null)}function _o(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs=ho,oo(e);var o=t.contextType;"object"===typeof o&&null!==o?i.context=ro(o):(o=pi(t)?hi:ci.current,i.context=di(e,o)),c
2o(e,n,i,r),i.state=e.memoizedState,"function"===typeof(o=t.getDerivedStateFromProps)&&(po(e,t,o,n),i.state=e.memoizedState),"function"===typeof t.getDerivedStateFromProps||"function"===typeof i.getSnapshotBeforeUpdate||"function"!==typeof i.UNSAFE_componentWillMount&&"function"!==typeof i.componentWillMount||(t=i.state,"function"===typeof i.componentWillMount&&i.componentWillMount(),"function"===typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),t!==i.state&&yo.enqueueReplaceState(i,i.state,null),co(e,n,i,r),i.state=e.memoizedState),"function"===typeof i.componentDidMount&&(e.flags|=4)}var bo=Array.isArray;function wo(e,t,n){if(null!==(e=n.ref)&&"function"!==typeof e&&"object"!==typeof e){if(n._owner){if(n=n._owner){if(1!==n.tag)throw Error(a(309));var r=n.stateNode}if(!r)throw Error(a(147,e));var i=""+e;return null!==t&&null!==t.ref&&"function"===typeof t.ref&&t.ref._stringRef===i?t.ref:((t=function(e){var t=r.refs;t===ho&&(t=r.refs={}),null===e?delete t[i]:t[i]=e})._stringRef=i,t)}if("string"!==typeof e)throw Error(a(284));if(!n._owner)throw Error(a(290,e))}return e}function Eo(e,t){if("textarea"!==e.type)throw Error(a(31,"[object Object]"===Object.prototype.toString.call(t)?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function Co(e){function t(t,n){if(e){var r=t.lastEffect;null!==r?(r.nextEffect=n,t.lastEffect=n):t.firstEffect=t.lastEffect=n,n.nextEffect=null,n.flags=8}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=ql(e,t)).index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags=2,n):r:(t.flags=2,n):n}function s(t){return e&&null===t.alternate&&(t.flags=2),t}function l(e,t,n,r){return null===t||6!==t.tag?((t=Kl(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function u(e,t,n,r){return null!==t&&t.elementType===n.type?((r=i(t,n.props)).ref=wo(e,t,n),r.return=e,r):((r=Vl(n.type,n.key,n.props,null,e.mode,r)).ref=wo(e,t,n),r.return=e,r)}function c(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Yl(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function f(e,t,n,r,o){return null===t||7!==t.tag?((t=Ql(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function h(e,t,n){if("string"===typeof t||"number"===typeof t)return(t=Kl(""+t,e.mode,n)).return=e,t;if("object"===typeof t&&null!==t){switch(t.$$typeof){case E:return(n=Vl(t.type,t.key,t.props,null,e.mode,n)).ref=wo(e,null,t),n.return=e,n;case C:return(t=Yl(t,e.mode,n)).return=e,t}if(bo(t)||B(t))return(t=Ql(t,e.mode,n,null)).return=e,t;Eo(e,t)}return null}function d(e,t,n,r){var i=null!==t?t.key:null;if("string"===typeof n||"number"===typeof n)return null!==i?null:l(e,t,""+n,r);if("object"===typeof n&&null!==n){switch(n.$$typeof){case E:return n.key===i?n.type===S?f(e,t,n.props.children,r,i):u(e,t,n,r):null;case C:return n.key===i?c(e,t,n,r):null}if(bo(n)||B(n))return null!==i?null:f(e,t,n,r,null);Eo(e,n)}return null}function p(e,t,n,r,i){if("string"===typeof r||"number"===typeof r)return l(t,e=e.get(n)||null,""+r,i);if("object"===typeof r&&null!==r){switch(r.$$typeof){case E:return e=e.get(null===r.key?n:r.key)||null,r.type===S?f(t,e,r.props.children,i,r.key):u(t,e,r,i);case C:return c(t,e=e.get(null===r.key?n:r.key)||null,r,i)}if(bo(r)||B(r))return f(t,e=e.get(n)||null,r,i,null);Eo(t,r)}return null}function y(i,a,s,l){for(var u=null,c=null,f=a,y=a=0,v=null;null!==f&&y<s.length;y++){f.index>y?(v=f,f=null):v=f.sibling;var g=d(i,f,s[y],l);if(null===g){null===f&&(f=v);break}e&&f&&null===g.alternate&&t(i,f),a=o(g,a,y),null===c?u=g:c.sibling=g,c=g,f=v}if(y===s.length)return n(i,f),u;if(null===f){for(;y<s.length;y++)null!==(f=h(i,s[y],l))&&(a=o(f,a,y),null===c?u=f:c.sibling=f,c=f);return u}for(f=r(i,f);y<s.length;y++)null!==(v=p(f,i,y,s[y],l))&&(e&&null!==v.alternate&&f.delete(null===v.key?y:v.key),a=o(v,a,y),null===c?u=v:c.sibling=v,c=v);return e&&f.forEach((function(e){return t(i,e)})),u}function v(i,s,l,u){var c=B(l);if("function"!==typeof c)throw Error(a(150));if(null==(l=c.call(l)))throw Error(a(151));for(var f=c=null,y=s,v=s=0,g=null,m=l.next();null!==y&&!m.done;v++,m=l.next()){y.index>v?(g=y,y=null):g=y.sibling;var _=d(i,y,m.value,u);if(null===_){null===y&&(y=g);break}e&&y&&null===_.alternate&&t(i,y),s=o(_,s,v),null===f?c=_:f.sibling=_,f=_,y=g}if(m.done)return n(i,y),c;if(null===y){for(;!m.done;v++,m=l.next())null!==(m=h(i,m.value,u))&&(s=o(m,s,v),null===f?c=m
vendor: 4,344 bytes, line 2
2:f.sibling=m,f=m);return c}for(y=r(i,y);!m.done;v++,m=l.next())null!==(m=p(y,i,v,m.value,u))&&(e&&null!==m.alternate&&y.delete(null===m.key?v:m.key),s=o(m,s,v),null===f?c=m:f.sibling=m,f=m);return e&&y.forEach((function(e){return t(i,e)})),c}return function(e,r,o,l){var u="object"===typeof o&&null!==o&&o.type===S&&null===o.key;u&&(o=o.props.children);var c="object"===typeof o&&null!==o;if(c)switch(o.$$typeof){case E:e:{for(c=o.key,u=r;null!==u;){if(u.key===c){switch(u.tag){case 7:if(o.type===S){n(e,u.sibling),(r=i(u,o.props.children)).return=e,e=r;break e}break;default:if(u.elementType===o.type){n(e,u.sibling),(r=i(u,o.props)).ref=wo(e,u,o),r.return=e,e=r;break e}}n(e,u);break}t(e,u),u=u.sibling}o.type===S?((r=Ql(o.props.children,e.mode,l,o.key)).return=e,e=r):((l=Vl(o.type,o.key,o.props,null,e.mode,l)).ref=wo(e,r,o),l.return=e,e=l)}return s(e);case C:e:{for(u=o.key;null!==r;){if(r.key===u){if(4===r.tag&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),(r=i(r,o.children||[])).return=e,e=r;break e}n(e,r);break}t(e,r),r=r.sibling}(r=Yl(o,e.mode,l)).return=e,e=r}return s(e)}if("string"===typeof o||"number"===typeof o)return o=""+o,null!==r&&6===r.tag?(n(e,r.sibling),(r=i(r,o)).return=e,e=r):(n(e,r),(r=Kl(o,e.mode,l)).return=e,e=r),s(e);if(bo(o))return y(e,r,o,l);if(B(o))return v(e,r,o,l);if(c&&Eo(e,o),"undefined"===typeof o&&!u)switch(e.tag){case 1:case 22:case 0:case 11:case 15:throw Error(a(152,K(e.type)||"Component"))}return n(e,r)}}var So=Co(!0),Oo=Co(!1),To={},ko=ai(To),xo=ai(To),No=ai(To);function Po(e){if(e===To)throw Error(a(174));return e}function Io(e,t){switch(li(No,t),li(xo,e),li(ko,To),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:pe(null,"");break;default:t=pe(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}si(ko),li(ko,t)}function Ro(){si(ko),si(xo),si(No)}function Do(e){Po(No.current);var t=Po(ko.current),n=pe(t,e.type);t!==n&&(li(xo,e),li(ko,n))}function jo(e){xo.current===e&&(si(ko),si(xo))}var Lo=ai(0);function Ao(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!==(64&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Fo=null,Mo=null,Uo=!1;function Wo(e,t){var n=zl(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,null!==e.lastEffect?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function zo(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,!0);case 13:default:return!1}}function Bo(e){if(Uo){var t=Mo;if(t){var n=t;if(!zo(e,t)){if(!(t=Qr(n.nextSibling))||!zo(e,t))return e.flags=-1025&e.flags|2,Uo=!1,void(Fo=e);Wo(Fo,n)}Fo=e,Mo=Qr(t.firstChild)}else e.flags=-1025&e.flags|2,Uo=!1,Fo=e}}function qo(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;Fo=e}function Vo(e){if(e!==Fo)return!1;if(!Uo)return qo(e),Uo=!0,!1;var t=e.type;if(5!==e.tag||"head"!==t&&"body"!==t&&!zr(t,e.memoizedProps))for(t=Mo;t;)Wo(e,t),t=Qr(t.nextSibling);if(qo(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n){if(0===t){Mo=Qr(e.nextSibling);break e}t--}else"$"!==n&&"$!"!==n&&"$?"!==n||t++}e=e.nextSibling}Mo=null}}else Mo=Fo?Qr(e.stateNode.nextSibling):null;return!0}function Qo(){Mo=Fo=null,Uo=!1}var Ho=[];function Ko(){for(var e=0;e<Ho.length;e++)Ho[e]._workInProgressVersionPrimary=null;Ho.length=0}var Yo=w.ReactCurrentDispatcher,$o=w.ReactCurrentBatchConfig,Go=0,Xo=null,Jo=null,Zo=null,ea=!1,ta=!1;function na(){throw Error(a(321))}function ra(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!sr(e[n],t[n]))return!1;return!0}function ia(e,t,n,r,i,o){if(Go=o,Xo=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Yo.current=null===e||null===e.memoizedState?Pa:Ia,e=n(r,i),ta){o=0;
vendor: 9,948 bytes, line 2
2do{if(ta=!1,!(25>o))throw Error(a(301));o+=1,Zo=Jo=null,t.updateQueue=null,Yo.current=Ra,e=n(r,i)}while(ta)}if(Yo.current=Na,t=null!==Jo&&null!==Jo.next,Go=0,Zo=Jo=Xo=null,ea=!1,t)throw Error(a(300));return e}function oa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===Zo?Xo.memoizedState=Zo=e:Zo=Zo.next=e,Zo}function aa(){if(null===Jo){var e=Xo.alternate;e=null!==e?e.memoizedState:null}else e=Jo.next;var t=null===Zo?Xo.memoizedState:Zo.next;if(null!==t)Zo=t,Jo=e;else{if(null===e)throw Error(a(310));e={memoizedState:(Jo=e).memoizedState,baseState:Jo.baseState,baseQueue:Jo.baseQueue,queue:Jo.queue,next:null},null===Zo?Xo.memoizedState=Zo=e:Zo=Zo.next=e}return Zo}function sa(e,t){return"function"===typeof t?t(e):t}function la(e){var t=aa(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=Jo,i=r.baseQueue,o=n.pending;if(null!==o){if(null!==i){var s=i.next;i.next=o.next,o.next=s}r.baseQueue=i=o,n.pending=null}if(null!==i){i=i.next,r=r.baseState;var l=s=o=null,u=i;do{var c=u.lane;if((Go&c)===c)null!==l&&(l=l.next={lane:0,action:u.action,eagerReducer:u.eagerReducer,eagerState:u.eagerState,next:null}),r=u.eagerReducer===e?u.eagerState:e(r,u.action);else{var f={lane:c,action:u.action,eagerReducer:u.eagerReducer,eagerState:u.eagerState,next:null};null===l?(s=l=f,o=r):l=l.next=f,Xo.lanes|=c,Ms|=c}u=u.next}while(null!==u&&u!==i);null===l?o=r:l.next=s,sr(r,t.memoizedState)||(ja=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=l,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function ua(e){var t=aa(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(null!==i){n.pending=null;var s=i=i.next;do{o=e(o,s.action),s=s.next}while(s!==i);sr(o,t.memoizedState)||(ja=!0),t.memoizedState=o,null===t.baseQueue&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function ca(e,t,n){var r=t._getVersion;r=r(t._source);var i=t._workInProgressVersionPrimary;if(null!==i?e=i===r:(e=e.mutableReadLanes,(e=(Go&e)===e)&&(t._workInProgressVersionPrimary=r,Ho.push(t))),e)return n(t._source);throw Ho.push(t),Error(a(350))}function fa(e,t,n,r){var i=Ps;if(null===i)throw Error(a(349));var o=t._getVersion,s=o(t._source),l=Yo.current,u=l.useState((function(){return ca(i,t,n)})),c=u[1],f=u[0];u=Zo;var h=e.memoizedState,d=h.refs,p=d.getSnapshot,y=h.source;h=h.subscribe;var v=Xo;return e.memoizedState={refs:d,source:t,subscribe:r},l.useEffect((function(){d.getSnapshot=n,d.setSnapshot=c;var e=o(t._source);if(!sr(s,e)){e=n(t._source),sr(f,e)||(c(e),e=cl(v),i.mutableReadLanes|=e&i.pendingLanes),e=i.mutableReadLanes,i.entangledLanes|=e;for(var r=i.entanglements,a=e;0<a;){var l=31-Vt(a),u=1<<l;r[l]|=e,a&=~u}}}),[n,t,r]),l.useEffect((function(){return r(t._source,(function(){var e=d.getSnapshot,n=d.setSnapshot;try{n(e(t._source));var r=cl(v);i.mutableReadLanes|=r&i.pendingLanes}catch(o){n((function(){throw o}))}}))}),[t,r]),sr(p,n)&&sr(y,t)&&sr(h,r)||((e={pending:null,dispatch:null,lastRenderedReducer:sa,lastRenderedState:f}).dispatch=c=xa.bind(null,Xo,e),u.queue=e,u.baseQueue=null,f=ca(i,t,n),u.memoizedState=u.baseState=f),f}function ha(e,t,n){return fa(aa(),e,t,n)}function da(e){var t=oa();return"function"===typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=(e=t.queue={pending:null,dispatch:null,lastRenderedReducer:sa,lastRenderedState:e}).dispatch=xa.bind(null,Xo,e),[t.memoizedState,e]}function pa(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=Xo.updateQueue)?(t={lastEffect:null},Xo.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ya(e){return e={current:e},oa().memoizedState=e}function va(){return aa().memoizedState}function ga(e,t,n,r){var i=oa();Xo.flags|=e,i.memoizedState=pa(1|t,n,void 0,void 0===r?null:r)}function ma(e,t,n,r){var i=aa();r=void 0===r?null:r;var o=void 0;if(null!==Jo){var a=Jo.memoizedState;if(o=a.destroy,null!==r&&ra(r,a.deps))return void pa(t,n,o,r)}Xo.flags|=e,i.memoizedState=pa(1|t,n,o,r)}function _a(e,t){return ga(516,4,e,t)}function ba(e,t){return ma(516,4,e,t)}function wa(e,t){return ma(4,2,e,t)}function Ea(e,t){return"function"===typeof t?(e=e(),t(e),function(){t(null)}):null!==t&&void 0!==t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Ca(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,ma(4,2,Ea.bind(null,t,e),n)}function Sa(){}function Oa(e,t){var n=aa();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ra(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ta(e,t){var n=aa();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ra(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function ka(e,t){var n=zi();qi(98>n?98:n,(function(){e(!0)})),qi(97<n?97:n,(function(){var n=$o.transition;$o.transition=1;try{e(!1),t()}finally{$o.transition=n}}))}function xa(e,t,n){var r=ul(),i=cl(e),o={lane:i,action:n,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(null===a?o.next=o:(o.next=a.next,a.next=o),t.pending=o,a=e.alternate,e===Xo||null!==a&&a===Xo)ta=ea=!0;else{if(0===e.lanes&&(null===a||0===a.lanes)&&null!==(a=t.lastRenderedReducer))try{var s=t.lastRenderedState,l=a(s,n);if(o.eagerReducer=a,o.eagerState=l,sr(l,s))return}catch(u){}fl(e,i,r)}}var Na={readContext:ro,useCallback:na,useContext:na,useEffect:na,useImperativeHandle:na,useLayoutEffect:na,useMemo:na,useReducer:na,useRef:na,useState:na,useDebugValue:na,useDeferredValue:na,useTransition:na,useMutableSource:na,useOpaqueIdentifier:na,unstable_isNewReconciler:!1},Pa={readContext:ro,useCallback:function(e,t){return oa().memoizedState=[e,void 0===t?null:t],e},useContext:ro,useEffect:_a,useImperativeHandle:function(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,ga(4,2,Ea.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ga(4,2,e,t)},useMemo:function(e,t){var n=oa();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=oa();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e=(e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t}).dispatch=xa.bind(null,Xo,e),[r.memoizedState,e]},useRef:ya,useState:da,useDebugValue:Sa,useDeferredValue:function(e){var t=da(e),n=t[0],r=t[1];return _a((function(){var t=$o.transition;$o.transition=1;try{r(e)}finally{$o.transition=t}}),[e]),n},useTransition:function(){var e=da(!1),t=e[0];return ya(e=ka.bind(null,e[1])),[e,t]},useMutableSource:function(e,t,n){var r=oa();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},fa(r,e,t,n)},useOpaqueIdentifier:function(){if(Uo){var e=!1,t=function(e){return{$$typeof:L,toString:e,valueOf:e}}((function(){throw e||(e=!0,n("r:"+(Kr++).toString(36))),Error(a(355))})),n=da(t)[1];return 0===(2&Xo.mode)&&(Xo.flags|=516,pa(5,(function(){n("r:"+(Kr++).toString(36))}),void 0,null)),t}return da(t="r:"+(Kr++).toString(36)),t},unstable_isNewReconciler:!1},Ia={readContext:ro,useCallback:Oa,useContext:ro,useEffect:ba,useImperativeHandle:Ca,useLayoutEffect:wa,useMemo:Ta,useReducer:la,useRef:va,useState:function(){return la(sa)},useDebugValue:Sa,useDeferredValue:function(e){var t=la(sa),n=t[0],r=t[1];return ba((function(){var t=$o.transition;$o.transition=1;try{r(e)}finally{$o.transition=t}}),[e]),n},useTransition:function(){var e=la(sa)[0];return[va().current,e]},useMutableSource:ha,useOpaqueIdentifier:function(){return la(sa)[0]},unstable_isNewReconciler:!1},Ra={readContext:ro,useCallback:Oa,useContext:ro,useEffect:ba,useImperativeHandle:Ca,useLayoutEffect:wa,useMemo:Ta,useReducer:ua,useRef:va,useState:function(){return ua(sa)},useDebugValue:Sa,useDeferredValue:function(e){var t=ua(sa),n=t[0],r=t[1];return ba((function(){var t=$o.transition;$o.transition=1;try{r(e)}finally{$o.transition=t}}),[e]),n},useTransition:function(){var e=ua(sa)[0];return[va().current,e]},useMutableSource:ha,useOpaqueIdentifier:function(){return ua(sa)[0]},unstable_isNewReconciler:!1},Da=w.ReactCurrentOwner,ja=!1;function La(e,t,n,r){t.child=null===e?Oo(t,null,n,r):So(t,e.child,n,r)}function Aa(e,t,n,r,i){n=n.render;var o=t.ref;return no(t,i),r=ia(e,t,n,r,o,i),null===e||ja?(t.flags|=1,La(e,t,r,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ns(e,t,i))}function Fa(e,t,n,r,i,o){if(null===e){var a=n.type;return"function"!==typeof a||Bl(a)||void 0!==a.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=Vl(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=a,Ma(e,t,a,r,i,o))}return a=e.child,0===(i&o)&&(i=a.memoizedProps,(n=null!==(n=n.compare)?n:ur)(i,r)&&e.ref===t.ref)?ns(e,t,o):(t.flags|=1,(e=ql(a,r)).ref=t.ref,e.return=t,t.child=e)}function Ma(e,t,n,r,i,o){if(null!==e&&ur(e.memoizedProps,r)&&e.ref===t.ref){if(ja=!1,0===(o&i))return t.lanes=e.lanes,ns(e,t,o);0!==(16384&e.flags)&&(ja=!0)}return za(e,t,n,r,o)}function Ua(e,t,n){var r=t.pendingProps,i=r.children,o=null!==e?e.memoizedState:null;if("hidden"===r.mode||"unstable-defer-without-hiding"===r.mode)if(0===(4&t.mode))t.memoizedState={baseLanes:0},_l(t,n);else{if(0===(1073741824&n))return e=null!==o?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},_l(t,e),null;t.memoizedState={baseLanes:0},_l(t,null!==o?o.baseLanes:n)}else null!==o?(r=o.baseLanes|n,t.memoizedState=null):r=n,_l(t,r);return La(e,t,i,n),t.child}function Wa(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=128)}function za(e,t,n,r,i){var o=pi(n)?hi:ci.current;return o=di(t,o),no(t,i),n=ia(e,t,n,r,o,i),null===e||ja?(t.flags|=1,La(e,t,n,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ns(e,t,i))}function Ba(e,t,n,r,i){if(pi(n)){var o=!0;mi(t)}else o=!1;if(no(t,i),null===t.stateNode)null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),go(t,n,r),_o(t,n,r,i),r=!0;else if(null===e){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,u=n.contextType;
2"object"===typeof u&&null!==u?u=ro(u):u=di(t,u=pi(n)?hi:ci.current);var c=n.getDerivedStateFromProps,f="function"===typeof c||"function"===typeof a.getSnapshotBeforeUpdate;f||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(s!==r||l!==u)&&mo(t,a,r,u),io=!1;var h=t.memoizedState;a.state=h,co(t,r,a,i),l=t.memoizedState,s!==r||h!==l||fi.current||io?("function"===typeof c&&(po(t,n,c,r),l=t.memoizedState),(s=io||vo(t,n,s,r,h,l,u))?(f||"function"!==typeof a.UNSAFE_componentWillMount&&"function"!==typeof a.componentWillMount||("function"===typeof a.componentWillMount&&a.componentWillMount(),"function"===typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"===typeof a.componentDidMount&&(t.flags|=4)):("function"===typeof a.componentDidMount&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):("function"===typeof a.componentDidMount&&(t.flags|=4),r=!1)}else{a=t.stateNode,ao(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:Yi(t.type,s),a.props=u,f=t.pendingProps,h=a.context,"object"===typeof(l=n.contextType)&&null!==l?l=ro(l):l=di(t,l=pi(n)?hi:ci.current);var d=n.getDerivedStateFromProps;(c="function"===typeof d||"function"===typeof a.getSnapshotBeforeUpdate)||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(s!==f||h!==l)&&mo(t,a,r,l),io=!1,h=t.memoizedState,a.state=h,co(t,r,a,i);var p=t.memoizedState;s!==f||h!==p||fi.current||io?("function"===typeof d&&(po(t,n,d,r),p=t.memoizedState),(u=io||vo(t,n,u,r,h,p,l))?(c||"function"!==typeof a.UNSAFE_componentWillUpdate&&"function"!==typeof a.componentWillUpdate||("function"===typeof a.componentWillUpdate&&a.componentWillUpdate(r,p,l),"function"===typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,p,l)),"function"===typeof a.componentDidUpdate&&(t.flags|=4),"function"===typeof a.getSnapshotBeforeUpdate&&(t.flags|=256)):("function"!==typeof a.componentDidUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=l,r=u):("function"!==typeof a.componentDidUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),r=!1)}return qa(e,t,n,r,o,i)}function qa(e,t,n,r,i,o){Wa(e,t);var a=0!==(64&t.flags);if(!r&&!a)return i&&_i(t,n,!1),ns(e,t,o);r=t.stateNode,Da.current=t;var s=a&&"function"!==typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=So(t,e.child,null,o),t.child=So(t,null,s,o)):La(e,t,s,o),t.memoizedState=r.state,i&&_i(t,n,!0),t.child}function Va(e){var t=e.stateNode;t.pendingContext?vi(0,t.pendingContext,t.pendingContext!==t.context):t.context&&vi(0,t.context,!1),Io(e,t.containerInfo)}var Qa,Ha,Ka,Ya={dehydrated:null,retryLane:0};function $a(e,t,n){var r,i=t.pendingProps,o=Lo.current,a=!1;return(r=0!==(64&t.flags))||(r=(null===e||null!==e.memoizedState)&&0!==(2&o)),r?(a=!0,t.flags&=-65):null!==e&&null===e.memoizedState||void 0===i.fallback||!0===i.unstable_avoidThisFallback||(o|=1),li(Lo,1&o),null===e?(void 0!==i.fallback&&Bo(t),e=i.children,o=i.fallback,a?(e=Ga(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ya,e):"number"===typeof i.unstable_expectedLoadTime?(e=Ga(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ya,t.lanes=33554432,e):((n=Hl({mode:"visible",children:e},t.mode,n,null)).return=t,t.child=n)):(e.memoizedState,a?(i=Ja(e,t,i.children,i.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=null===o?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Ya,i):(n=Xa(e,t,i.children,n),t.memoizedState=null,n))}function Ga(e,t,n,r){var i=e.mode,o=e.child;return t={mode:"hidden",children:t},0===(2&i)&&null!==o?(o.childLanes=0,o.pendingProps=t):o=Hl(t,i,0,null),n=Ql(n,i,r,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n}function Xa(e,t,n,r){var i=e.child;return e=i.sibling,n=ql(i,{mode:"visible",children:n}),0===(2&t.mode)&&(n.lanes=r),n.return=t,n.sibling=null,null!==e&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function Ja(e,t,n,r,i){var o=t.mode,a=e.child;e=a.sibling;var s={mode:"hidden",children:n};return 0===(2&o)&&t.child!==a?((n=t.child).childLanes=0,n.pendingProps=s,null!==(a=n.lastEffect)?(t.firstEffect=n.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):n=ql(a,s),null!==e?r=ql(e,r):(r=Ql(r,o,i,null)).flags|=2,r.return=t,n.return=t,n.sibling=r,t.child=n,r}function Za(e,t){e.lanes|=t;var n=e.alternate;null!==n&&(n.lanes|=t),to(e.return,t)}function es(e,t,n,r,i,o){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,lastEffect:o}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=i,a.lastEffect=o)}function ts(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(La(e,t,r.children,n),0!==(2&(r=Lo.current)))r=1&r|2,t.flags|=64;else{if(null!==e&&0!==(64&e.flags))e:for(e=t.child;null!==e;
vendor: 11,170 bytes, line 2
2){if(13===e.tag)null!==e.memoizedState&&Za(e,n);else if(19===e.tag)Za(e,n);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(li(Lo,r),0===(2&t.mode))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;null!==n;)null!==(e=n.alternate)&&null===Ao(e)&&(i=n),n=n.sibling;null===(n=i)?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),es(t,!1,i,n,o,t.lastEffect);break;case"backwards":for(n=null,i=t.child,t.child=null;null!==i;){if(null!==(e=i.alternate)&&null===Ao(e)){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}es(t,!0,n,null,o,t.lastEffect);break;case"together":es(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function ns(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),Ms|=t.lanes,0!==(n&t.childLanes)){if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=ql(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=ql(e,e.pendingProps)).return=t;n.sibling=null}return t.child}return null}function rs(e,t){if(!Uo)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function is(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return pi(t.type)&&yi(),null;case 3:return Ro(),si(fi),si(ci),Ko(),(r=t.stateNode).pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),null!==e&&null!==e.child||(Vo(t)?t.flags|=4:r.hydrate||(t.flags|=256)),null;case 5:jo(t);var o=Po(No.current);if(n=t.type,null!==e&&null!=t.stateNode)Ha(e,t,n,r),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(null===t.stateNode)throw Error(a(166));return null}if(e=Po(ko.current),Vo(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[$r]=t,r[Gr]=s,n){case"dialog":kr("cancel",r),kr("close",r);break;case"iframe":case"object":case"embed":kr("load",r);break;case"video":case"audio":for(e=0;e<Cr.length;e++)kr(Cr[e],r);break;case"source":kr("error",r);break;case"img":case"image":case"link":kr("error",r),kr("load",r);break;case"details":kr("toggle",r);break;case"input":ee(r,s),kr("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},kr("invalid",r);break;case"textarea":le(r,s),kr("invalid",r)}for(var u in Se(n,s),e=null,s)s.hasOwnProperty(u)&&(o=s[u],"children"===u?"string"===typeof o?r.textContent!==o&&(e=["children",o]):"number"===typeof o&&r.textContent!==""+o&&(e=["children",""+o]):l.hasOwnProperty(u)&&null!=o&&"onScroll"===u&&kr("scroll",r));switch(n){case"input":G(r),re(r,s,!0);break;case"textarea":G(r),ce(r);break;case"select":case"option":break;default:"function"===typeof s.onClick&&(r.onclick=Fr)}r=e,t.updateQueue=r,null!==r&&(t.flags|=4)}else{switch(u=9===o.nodeType?o:o.ownerDocument,e===fe&&(e=de(n)),e===fe?"script"===n?((e=u.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"===typeof r.is?e=u.createElement(n,{is:r.is}):(e=u.createElement(n),"select"===n&&(u=e,r.multiple?u.multiple=!0:r.size&&(u.size=r.size))):e=u.createElementNS(e,n),e[$r]=t,e[Gr]=r,Qa(e,t),t.stateNode=e,u=Oe(n,r),n){case"dialog":kr("cancel",e),kr("close",e),o=r;break;case"iframe":case"object":case"embed":kr("load",e),o=r;break;case"video":case"audio":for(o=0;o<Cr.length;o++)kr(Cr[o],e);o=r;break;case"source":kr("error",e),o=r;break;case"img":case"image":case"link":kr("error",e),kr("load",e),o=r;break;case"details":kr("toggle",e),o=r;break;case"input":ee(e,r),o=Z(e,r),kr("invalid",e);break;case"option":o=oe(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=i({},r,{value:void 0}),kr("invalid",e);break;case"textarea":le(e,r),o=se(e,r),kr("invalid",e);break;default:o=r}Se(n,o);var c=o;for(s in c)if(c.hasOwnProperty(s)){var f=c[s];"style"===s?Ee(e,f):"dangerouslySetInnerHTML"===s?null!=(f=f?f.__html:void 0)&&ge(e,f):"children"===s?"string"===typeof f?("textarea"!==n||""!==f)&&me(e,f):"number"===typeof f&&me(e,""+f):"suppressContentEditableWarning"!==s&&"suppressHydrationWarning"!==s&&"autoFocus"!==s&&(l.hasOwnProperty(s)?null!=f&&"onScroll"===s&&kr("scroll",e):null!=f&&b(e,s,f,u))}switch(n){case"input":G(e),re(e,r,!1);break;case"textarea":G(e),ce(e);break;case"option":null!=r.value&&e.setAttribute("value",""+Y(r.value));break;case"select":e.multiple=!!r.multiple,null!=(s=r.value)?ae(e,!!r.multiple,s,!1):null!=r.defaultValue&&ae(e,!!r.multiple,r.defaultValue,!0);break;default:"function"===typeof o.onClick&&(e.onclick=Fr)}Wr(n,r)&&(t.flags|=4)}null!==t.ref&&(t.flags|=128)}return null;case 6:if(e&&null!=t.stateNode)Ka(0,t,e.memoizedProps,r);else{if("string"!==typeof r&&null===t.stateNode)throw Error(a(166));n=Po(No.current),Po(ko.current),Vo(t)?(r=t.stateNode,n=t.memoizedProps,r[$r]=t,r.nodeValue!==n&&(t.flags|=4)):((r=(9===n.nodeType?n:n.ownerDocument).createTextNode(r))[$r]=t,t.stateNode=r)}return null;case 13:return si(Lo),r=t.memoizedState,0!==(64&t.flags)?(t.lanes=n,t):(r=null!==r,n=!1,null===e?void 0!==t.memoizedProps.fallback&&Vo(t):n=null!==e.memoizedState,r&&!n&&0!==(2&t.mode)&&(null===e&&!0!==t.memoizedProps.unstable_avoidThisFallback||0!==(1&Lo.current)?0===Ls&&(Ls=3):(0!==Ls&&3!==Ls||(Ls=4),null===Ps||0===(134217727&Ms)&&0===(134217727&Us)||yl(Ps,Rs))),(r||n)&&(t.flags|=4),null);case 4:return Ro(),null===e&&Nr(t.stateNode.containerInfo),null;case 10:return eo(t),null;case 17:return pi(t.type)&&yi(),null;case 19:if(si(Lo),null===(r=t.memoizedState))return null;if(s=0!==(64&t.flags),null===(u=r.rendering))if(s)rs(r,!1);else{if(0!==Ls||null!==e&&0!==(64&e.flags))for(e=t.child;null!==e;){if(null!==(u=Ao(e))){for(t.flags|=64,rs(r,!1),null!==(s=u.updateQueue)&&(t.updateQueue=s,t.flags|=4),null===r.lastEffect&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;null!==n;)e=r,(s=n).flags&=2,s.nextEffect=null,s.firstEffect=null,s.lastEffect=null,null===(u=s.alternate)?(s.childLanes=0,s.lanes=e,s.child=null,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=u.childLanes,s.lanes=u.lanes,s.child=u.child,s.memoizedProps=u.memoizedProps,s.memoizedState=u.memoizedState,s.updateQueue=u.updateQueue,s.type=u.type,e=u.dependencies,s.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return li(Lo,1&Lo.current|2),t.child}e=e.sibling}null!==r.tail&&Wi()>qs&&(t.flags|=64,s=!0,rs(r,!1),t.lanes=33554432)}else{if(!s)if(null!==(e=Ao(u))){if(t.flags|=64,s=!0,null!==(n=e.updateQueue)&&(t.updateQueue=n,t.flags|=4),rs(r,!0),null===r.tail&&"hidden"===r.tailMode&&!u.alternate&&!Uo)return null!==(t=t.lastEffect=r.lastEffect)&&(t.nextEffect=null),null}else 2*Wi()-r.renderingStartTime>qs&&1073741824!==n&&(t.flags|=64,s=!0,rs(r,!1),t.lanes=33554432);r.isBackwards?(u.sibling=t.child,t.child=u):(null!==(n=r.last)?n.sibling=u:t.child=u,r.last=u)}return null!==r.tail?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=Wi(),n.sibling=null,t=Lo.current,li(Lo,s?1&t|2:1&t),n):null;case 23:case 24:return bl(),null!==e&&null!==e.memoizedState!==(null!==t.memoizedState)&&"unstable-defer-without-hiding"!==r.mode&&(t.flags|=4),null}throw Error(a(156,t.tag))}function os(e){switch(e.tag){case 1:pi(e.type)&&yi();var t=e.flags;return 4096&t?(e.flags=-4097&t|64,e):null;case 3:if(Ro(),si(fi),si(ci),Ko(),0!==(64&(t=e.flags)))throw Error(a(285));return e.flags=-4097&t|64,e;case 5:return jo(e),null;case 13:return si(Lo),4096&(t=e.flags)?(e.flags=-4097&t|64,e):null;case 19:return si(Lo),null;case 4:return Ro(),null;case 10:return eo(e),null;case 23:case 24:return bl(),null;default:return null}}function as(e,t){try{var n="",r=t;do{n+=H(r),r=r.return}while(r);var i=n}catch(o){i="\nError generating stack: "+o.message+"\n"+o.stack}return{value:e,source:t,stack:i}}function ss(e,t){try{console.error(t.value)}catch(n){setTimeout((function(){throw n}))}}Qa=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Ha=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Po(ko.current);var a,s=null;switch(n){case"input":o=Z(e,o),r=Z(e,r),s=[];break;case"option":o=oe(e,o),r=oe(e,r),s=[];break;case"select":o=i({},o,{value:void 0}),r=i({},r,{value:void 0}),s=[];break;case"textarea":o=se(e,o),r=se(e,r),s=[];break;default:"function"!==typeof o.onClick&&"function"===typeof r.onClick&&(e.onclick=Fr)}for(f in Se(n,r),n=null,o)if(!r.hasOwnProperty(f)&&o.hasOwnProperty(f)&&null!=o[f])if("style"===f){var u=o[f];for(a in u)u.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==f&&"children"!==f&&"suppressContentEditableWarning"!==f&&"suppressHydrationWarning"!==f&&"autoFocus"!==f&&(l.hasOwnProperty(f)?s||(s=[]):(s=s||[]).push(f,null));for(f in r){var c=r[f];if(u=null!=o?o[f]:void 0,r.hasOwnProperty(f)&&c!==u&&(null!=c||null!=u))if("style"===f)if(u){for(a in u)!u.hasOwnProperty(a)||c&&c.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in c)c.hasOwnProperty(a)&&u[a]!==c[a]&&(n||(n={}),n[a]=c[a])}else n||(s||(s=[]),s.push(f,n)),n=c;else"dangerouslySetInnerHTML"===f?(c=c?c.__html:void 0,u=u?u.__html:void 0,null!=c&&u!==c&&(s=s||[]).push(f,c)):"children"===f?"string"!==typeof c&&"number"!==typeof c||(s=s||[]).push(f,""+c):"suppressContentEditableWarning"!==f&&"suppressHydrationWarning"!==f&&(l.hasOwnProperty(f)?(null!=c&&"onScroll"===f&&kr("scroll",e),s||u===c||(s=[])):"object"===typeof c&&null!==c&&c.$$typeof===L?c.toString():(s=s||[]).push(f,c))}n&&(s=s||[]).push("style",n);var f=s;(t.updateQueue=f)&&(t.flags|=4)}},Ka=function(e,t,n,r){n!==r&&(t.flags|=4)};var ls="function"===typeof WeakMap?WeakMap:Map;function us(e,t,n){(n=so(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Ks||(Ks=!0,Ys=r),ss(0,t)},n}function cs(e,t,n){(n=so(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"===typeof r){var i=t.value;n.payload=function(){return ss(0,t),r(i)}}var o=e.stateNode;return null!==o&&"function"===typeof o.componentDidCatch&&(n.callback=function(){"function"!==typeof r&&(null===$s?$s=new Set([this]):$s.add(this),ss(0,t));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}var fs="function"===typeof WeakSet?WeakSet:Set;function hs(e){var t=e.ref;if(null!==t)if("function"===typeof t)try{t(null)}catch(n){Fl(e,n)}else t.current=null}function ds(e,t){switch(t.tag){case 0:case 11:case 15:case 22:return;case 1:if(256&t.flags&&null!==e){var n=e.memoizedProps,r=e.memoizedState;t=(e=t.stateNode).getSnapshotBeforeUpdate(t.elementType===t.type?n:Yi(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:return void(256&t.flags&&Vr(t.stateNode.containerInfo));
vendor: 4,942 bytes, line 2
2case 5:case 6:case 4:case 17:return}throw Error(a(163))}function ps(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{if(3===(3&e.tag)){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{var i=e;r=i.next,0!==(4&(i=i.tag))&&0!==(1&i)&&(jl(n,e),Dl(n,e)),e=r}while(e!==t)}return;case 1:return e=n.stateNode,4&n.flags&&(null===t?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:Yi(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),void(null!==(t=n.updateQueue)&&fo(n,t,e));case 3:if(null!==(t=n.updateQueue)){if(e=null,null!==n.child)switch(n.child.tag){case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}fo(n,t,e)}return;case 5:return e=n.stateNode,void(null===t&&4&n.flags&&Wr(n.type,n.memoizedProps)&&e.focus());case 6:case 4:case 12:return;case 13:return void(null===n.memoizedState&&(n=n.alternate,null!==n&&(n=n.memoizedState,null!==n&&(n=n.dehydrated,null!==n&&Et(n)))));case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(a(163))}function ys(e,t){for(var n=e;;){if(5===n.tag){var r=n.stateNode;if(t)"function"===typeof(r=r.style).setProperty?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var i=n.memoizedProps.style;i=void 0!==i&&null!==i&&i.hasOwnProperty("display")?i.display:null,r.style.display=we("display",i)}}else if(6===n.tag)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((23!==n.tag&&24!==n.tag||null===n.memoizedState||n===e)&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===e)break;for(;null===n.sibling;){if(null===n.return||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function vs(e,t){if(wi&&"function"===typeof wi.onCommitFiberUnmount)try{wi.onCommitFiberUnmount(bi,t)}catch(o){}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(null!==(e=t.updateQueue)&&null!==(e=e.lastEffect)){var n=e=e.next;do{var r=n,i=r.destroy;if(r=r.tag,void 0!==i)if(0!==(4&r))jl(t,n);else{r=t;try{i()}catch(o){Fl(r,o)}}n=n.next}while(n!==e)}break;case 1:if(hs(t),"function"===typeof(e=t.stateNode).componentWillUnmount)try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(o){Fl(t,o)}break;case 5:hs(t);break;case 4:Es(e,t)}}function gs(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function ms(e){return 5===e.tag||3===e.tag||4===e.tag}function _s(e){e:{for(var t=e.return;null!==t;){if(ms(t))break e;t=t.return}throw Error(a(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:case 4:t=t.containerInfo,r=!0;break;default:throw Error(a(161))}16&n.flags&&(me(t,""),n.flags&=-17);e:t:for(n=e;;){for(;null===n.sibling;){if(null===n.return||ms(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;5!==n.tag&&6!==n.tag&&18!==n.tag;){if(2&n.flags)continue t;if(null===n.child||4===n.tag)continue t;n.child.return=n,n=n.child}if(!(2&n.flags)){n=n.stateNode;break e}}r?bs(e,n,t):ws(e,n,t)}function bs(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?8===n.nodeType?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(8===n.nodeType?(t=n.parentNode).insertBefore(e,n):(t=n).appendChild(e),null!==(n=n._reactRootContainer)&&void 0!==n||null!==t.onclick||(t.onclick=Fr));else if(4!==r&&null!==(e=e.child))for(bs(e,t,n),e=e.sibling;null!==e;)bs(e,t,n),e=e.sibling}function ws(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&null!==(e=e.child))for(ws(e,t,n),e=e.sibling;null!==e;)ws(e,t,n),e=e.sibling}function Es(e,t){for(var n,r,i=t,o=!1;;){if(!o){o=i.return;e:for(;;){if(null===o)throw Error(a(160));switch(n=o.stateNode,o.tag){case 5:r=!1;break e;case 3:case 4:n=n.containerInfo,r=!0;break e}o=o.return}o=!0}if(5===i.tag||6===i.tag){e:for(var s=e,l=i,u=l;;)if(vs(s,u),null!==u.child&&4!==u.tag)u.child.return=u,u=u.child;else{if(u===l)break e;for(;null===u.sibling;){if(null===u.return||u.return===l)break e;u=u.return}u.sibling.return=u.return,u=u.sibling}r?(s=n,l=i.stateNode,8===s.nodeType?s.parentNode.removeChild(l):s.removeChild(l)):n.removeChild(i.stateNode)}else if(4===i.tag){if(null!==i.child){n=i.stateNode.containerInfo,r=!0,i.child.return=i,i=i.child;continue}}else if(vs(e,i),null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;4===(i=i.return).tag&&(o=!1)}i.sibling.return=i.return,i=i.sibling}}function Cs(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(null!==(n=null!==n?n.lastEffect:null)){var r=n=n.next;do{3===(3&r.tag)&&(e=r.destroy,r.destroy=void 0,void 0!==e&&e()),r=r.next}
vendor: 6,239 bytes, line 2
2while(r!==n)}return;case 1:return;case 5:if(null!=(n=t.stateNode)){r=t.memoizedProps;var i=null!==e?e.memoizedProps:r;e=t.type;var o=t.updateQueue;if(t.updateQueue=null,null!==o){for(n[Gr]=r,"input"===e&&"radio"===r.type&&null!=r.name&&te(n,r),Oe(e,i),t=Oe(e,r),i=0;i<o.length;i+=2){var s=o[i],l=o[i+1];"style"===s?Ee(n,l):"dangerouslySetInnerHTML"===s?ge(n,l):"children"===s?me(n,l):b(n,s,l,t)}switch(e){case"input":ne(n,r);break;case"textarea":ue(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,null!=(o=r.value)?ae(n,!!r.multiple,o,!1):e!==!!r.multiple&&(null!=r.defaultValue?ae(n,!!r.multiple,r.defaultValue,!0):ae(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(null===t.stateNode)throw Error(a(162));return void(t.stateNode.nodeValue=t.memoizedProps);case 3:return void((n=t.stateNode).hydrate&&(n.hydrate=!1,Et(n.containerInfo)));case 12:return;case 13:return null!==t.memoizedState&&(Bs=Wi(),ys(t.child,!0)),void Ss(t);case 19:return void Ss(t);case 17:return;case 23:case 24:return void ys(t,null!==t.memoizedState)}throw Error(a(163))}function Ss(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new fs),t.forEach((function(t){var r=Ul.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))}))}}function Os(e,t){return null!==e&&(null===(e=e.memoizedState)||null!==e.dehydrated)&&(null!==(t=t.memoizedState)&&null===t.dehydrated)}var Ts=Math.ceil,ks=w.ReactCurrentDispatcher,xs=w.ReactCurrentOwner,Ns=0,Ps=null,Is=null,Rs=0,Ds=0,js=ai(0),Ls=0,As=null,Fs=0,Ms=0,Us=0,Ws=0,zs=null,Bs=0,qs=1/0;function Vs(){qs=Wi()+500}var Qs,Hs=null,Ks=!1,Ys=null,$s=null,Gs=!1,Xs=null,Js=90,Zs=[],el=[],tl=null,nl=0,rl=null,il=-1,ol=0,al=0,sl=null,ll=!1;function ul(){return 0!==(48&Ns)?Wi():-1!==il?il:il=Wi()}function cl(e){if(0===(2&(e=e.mode)))return 1;if(0===(4&e))return 99===zi()?1:2;if(0===ol&&(ol=Fs),0!==Ki.transition){0!==al&&(al=null!==zs?zs.pendingLanes:0),e=ol;var t=4186112&~al;return 0===(t&=-t)&&(0===(t=(e=4186112&~e)&-e)&&(t=8192)),t}return e=zi(),0!==(4&Ns)&&98===e?e=Wt(12,ol):e=Wt(e=function(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}(e),ol),e}function fl(e,t,n){if(50<nl)throw nl=0,rl=null,Error(a(185));if(null===(e=hl(e,t)))return null;qt(e,t,n),e===Ps&&(Us|=t,4===Ls&&yl(e,Rs));var r=zi();1===t?0!==(8&Ns)&&0===(48&Ns)?vl(e):(dl(e,n),0===Ns&&(Vs(),Qi())):(0===(4&Ns)||98!==r&&99!==r||(null===tl?tl=new Set([e]):tl.add(e)),dl(e,n)),zs=e}function hl(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}function dl(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,i=e.pingedLanes,o=e.expirationTimes,s=e.pendingLanes;0<s;){var l=31-Vt(s),u=1<<l,c=o[l];if(-1===c){if(0===(u&r)||0!==(u&i)){c=t,Ft(u);var f=At;o[l]=10<=f?c+250:6<=f?c+5e3:-1}}else c<=t&&(e.expiredLanes|=u);s&=~u}if(r=Mt(e,e===Ps?Rs:0),t=At,0===r)null!==n&&(n!==ji&&Si(n),e.callbackNode=null,e.callbackPriority=0);else{if(null!==n){if(e.callbackPriority===t)return;n!==ji&&Si(n)}15===t?(n=vl.bind(null,e),null===Ai?(Ai=[n],Fi=Ci(Ni,Hi)):Ai.push(n),n=ji):14===t?n=Vi(99,vl.bind(null,e)):n=Vi(n=function(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(a(358,e))}}(t),pl.bind(null,e)),e.callbackPriority=t,e.callbackNode=n}}function pl(e){if(il=-1,al=ol=0,0!==(48&Ns))throw Error(a(327));var t=e.callbackNode;if(Rl()&&e.callbackNode!==t)return null;var n=Mt(e,e===Ps?Rs:0);if(0===n)return null;var r=n,i=Ns;Ns|=16;var o=Cl();for(Ps===e&&Rs===r||(Vs(),wl(e,r));;)try{Tl();break}catch(l){El(e,l)}if(Zi(),ks.current=o,Ns=i,null!==Is?r=0:(Ps=null,Rs=0,r=Ls),0!==(Fs&Us))wl(e,0);else if(0!==r){if(2===r&&(Ns|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(n=Ut(e))&&(r=Sl(e,n))),1===r)throw t=As,wl(e,0),yl(e,n),dl(e,Wi()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(a(345));case 2:Nl(e);break;case 3:if(yl(e,n),(62914560&n)===n&&10<(r=Bs+500-Wi())){if(0!==Mt(e,0))break;if(((i=e.suspendedLanes)&n)!==n){ul(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Br(Nl.bind(null,e),r);break}Nl(e);break;case 4:if(yl(e,n),(4186112&n)===n)break;for(r=e.eventTimes,i=-1;0<n;){var s=31-Vt(n);o=1<<s,(s=r[s])>i&&(i=s),n&=~o}if(n=i,10<(n=(120>(n=Wi()-n)?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*Ts(n/1960))-n)){e.timeoutHandle=Br(Nl.bind(null,e),n);break}Nl(e);break;case 5:Nl(e);break;default:throw Error(a(329))}}return dl(e,Wi()),e.callbackNode===t?pl.bind(null,e):null}function yl(e,t){for(t&=~Ws,t&=~Us,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Vt(t),r=1<<n;e[n]=-1,t&=~r}}function vl(e){if(0!==(48&Ns))throw Error(a(327));if(Rl(),e===Ps&&0!==(e.expiredLanes&Rs)){var t=Rs,n=Sl(e,t);0!==(Fs&Us)&&(n=Sl(e,t=Mt(e,t)))}else n=Sl(e,t=Mt(e,0));if(0!==e.tag&&2===n&&(Ns|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(t=Ut(e))&&(n=Sl(e,t))),1===n)throw n=As,wl(e,0),yl(e,t),dl(e,Wi()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,Nl(e),dl(e,Wi()),null}function gl(e,t){var n=Ns;Ns|=1;try{return e(t)}finally{0===(Ns=n)&&(Vs(),Qi())}}function ml(e,t){var n=Ns;Ns&=-2,Ns|=8;try{return e(t)}finally{0===(Ns=n)&&(Vs(),Qi())}}function _l(e,t){li(js,Ds),Ds|=t,Fs|=t}function bl(){Ds=js.current,si(js)}function wl(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,qr(n)),null!==Is)for(n=Is.return;null!==n;){var r=n;switch(r.tag){case 1:null!==(r=r.type.childContextTypes)&&void 0!==r&&yi();break;case 3:Ro(),si(fi),si(ci),Ko();break;case 5:jo(r);break;case 4:Ro();break;case 13:case 19:si(Lo);break;case 10:eo(r);break;case 23:case 24:bl()}n=n.return}Ps=e,Is=ql(e.current,null),Rs=Ds=Fs=t,Ls=0,As=null,Ws=Us=Ms=0}function El(e,t){for(;;){var n=Is;try{if(Zi(),Yo.current=Na,ea){for(var r=Xo.memoizedState;null!==r;){var i=r.queue;null!==i&&(i.pending=null),r=r.next}ea=!1}if(Go=0,Zo=Jo=Xo=null,ta=!1,xs.current=null,null===n||null===n.return){
vendor: 4,069 bytes, line 2
2Ls=1,As=t,Is=null;break}e:{var o=e,a=n.return,s=n,l=t;if(t=Rs,s.flags|=2048,s.firstEffect=s.lastEffect=null,null!==l&&"object"===typeof l&&"function"===typeof l.then){var u=l;if(0===(2&s.mode)){var c=s.alternate;c?(s.updateQueue=c.updateQueue,s.memoizedState=c.memoizedState,s.lanes=c.lanes):(s.updateQueue=null,s.memoizedState=null)}var f=0!==(1&Lo.current),h=a;do{var d;if(d=13===h.tag){var p=h.memoizedState;if(null!==p)d=null!==p.dehydrated;else{var y=h.memoizedProps;d=void 0!==y.fallback&&(!0!==y.unstable_avoidThisFallback||!f)}}if(d){var v=h.updateQueue;if(null===v){var g=new Set;g.add(u),h.updateQueue=g}else v.add(u);if(0===(2&h.mode)){if(h.flags|=64,s.flags|=16384,s.flags&=-2981,1===s.tag)if(null===s.alternate)s.tag=17;else{var m=so(-1,1);m.tag=2,lo(s,m)}s.lanes|=1;break e}l=void 0,s=t;var _=o.pingCache;if(null===_?(_=o.pingCache=new ls,l=new Set,_.set(u,l)):void 0===(l=_.get(u))&&(l=new Set,_.set(u,l)),!l.has(s)){l.add(s);var b=Ml.bind(null,o,u,s);u.then(b,b)}h.flags|=4096,h.lanes=t;break e}h=h.return}while(null!==h);l=Error((K(s.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==Ls&&(Ls=2),l=as(l,s),h=a;do{switch(h.tag){case 3:o=l,h.flags|=4096,t&=-t,h.lanes|=t,uo(h,us(0,o,t));break e;case 1:o=l;var w=h.type,E=h.stateNode;if(0===(64&h.flags)&&("function"===typeof w.getDerivedStateFromError||null!==E&&"function"===typeof E.componentDidCatch&&(null===$s||!$s.has(E)))){h.flags|=4096,t&=-t,h.lanes|=t,uo(h,cs(h,o,t));break e}}h=h.return}while(null!==h)}xl(n)}catch(C){t=C,Is===n&&null!==n&&(Is=n=n.return);continue}break}}function Cl(){var e=ks.current;return ks.current=Na,null===e?Na:e}function Sl(e,t){var n=Ns;Ns|=16;var r=Cl();for(Ps===e&&Rs===t||wl(e,t);;)try{Ol();break}catch(i){El(e,i)}if(Zi(),Ns=n,ks.current=r,null!==Is)throw Error(a(261));return Ps=null,Rs=0,Ls}function Ol(){for(;null!==Is;)kl(Is)}function Tl(){for(;null!==Is&&!Oi();)kl(Is)}function kl(e){var t=Qs(e.alternate,e,Ds);e.memoizedProps=e.pendingProps,null===t?xl(e):Is=t,xs.current=null}function xl(e){var t=e;do{var n=t.alternate;if(e=t.return,0===(2048&t.flags)){if(null!==(n=is(n,t,Ds)))return void(Is=n);if(24!==(n=t).tag&&23!==n.tag||null===n.memoizedState||0!==(1073741824&Ds)||0===(4&n.mode)){for(var r=0,i=n.child;null!==i;)r|=i.lanes|i.childLanes,i=i.sibling;n.childLanes=r}null!==e&&0===(2048&e.flags)&&(null===e.firstEffect&&(e.firstEffect=t.firstEffect),null!==t.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(null!==e.lastEffect?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}else{if(null!==(n=os(t)))return n.flags&=2047,void(Is=n);null!==e&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}if(null!==(t=t.sibling))return void(Is=t);Is=t=e}while(null!==t);0===Ls&&(Ls=5)}function Nl(e){var t=zi();return qi(99,Pl.bind(null,e,t)),null}function Pl(e,t){do{Rl()}while(null!==Xs);if(0!==(48&Ns))throw Error(a(327));var n=e.finishedWork;if(null===n)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(a(177));e.callbackNode=null;var r=n.lanes|n.childLanes,i=r,o=e.pendingLanes&~i;e.pendingLanes=i,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=i,e.mutableReadLanes&=i,e.entangledLanes&=i,i=e.entanglements;for(var s=e.eventTimes,l=e.expirationTimes;0<o;){var u=31-Vt(o),c=1<<u;i[u]=0,s[u]=-1,l[u]=-1,o&=~c}if(null!==tl&&0===(24&r)&&tl.has(e)&&tl.delete(e),e===Ps&&(Is=Ps=null,Rs=0),1<n.flags?null!==n.lastEffect?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,null!==r){if(i=Ns,Ns|=32,xs.current=null,Mr=$t,pr(s=dr())){if("selectionStart"in s)l={start:s.selectionStart,end:s.selectionEnd};else e:if(l=(l=s.ownerDocument)&&l.defaultView||window,(c=l.getSelection&&l.getSelection())&&0!==c.rangeCount){l=c.anchorNode,o=c.anchorOffset,u=c.focusNode,c=c.focusOffset;try{l.nodeType,u.nodeType}catch(T){l=null;break e}var f=0,h=-1,d=-1,p=0,y=0,v=s,g=null;t:for(;;){for(var m;
2v!==l||0!==o&&3!==v.nodeType||(h=f+o),v!==u||0!==c&&3!==v.nodeType||(d=f+c),3===v.nodeType&&(f+=v.nodeValue.length),null!==(m=v.firstChild);)g=v,v=m;for(;;){if(v===s)break t;if(g===l&&++p===o&&(h=f),g===u&&++y===c&&(d=f),null!==(m=v.nextSibling))break;g=(v=g).parentNode}v=m}l=-1===h||-1===d?null:{start:h,end:d}}else l=null;l=l||{start:0,end:0}}else l=null;Ur={focusedElem:s,selectionRange:l},$t=!1,sl=null,ll=!1,Hs=r;do{try{Il()}catch(T){if(null===Hs)throw Error(a(330));Fl(Hs,T),Hs=Hs.nextEffect}}while(null!==Hs);sl=null,Hs=r;do{try{for(s=e;null!==Hs;){var _=Hs.flags;if(16&_&&me(Hs.stateNode,""),128&_){var b=Hs.alternate;if(null!==b){var w=b.ref;null!==w&&("function"===typeof w?w(null):w.current=null)}}switch(1038&_){case 2:_s(Hs),Hs.flags&=-3;break;case 6:_s(Hs),Hs.flags&=-3,Cs(Hs.alternate,Hs);break;case 1024:Hs.flags&=-1025;break;case 1028:Hs.flags&=-1025,Cs(Hs.alternate,Hs);break;case 4:Cs(Hs.alternate,Hs);break;case 8:Es(s,l=Hs);var E=l.alternate;gs(l),null!==E&&gs(E)}Hs=Hs.nextEffect}}catch(T){if(null===Hs)throw Error(a(330));Fl(Hs,T),Hs=Hs.nextEffect}}while(null!==Hs);if(w=Ur,b=dr(),_=w.focusedElem,s=w.selectionRange,b!==_&&_&&_.ownerDocument&&hr(_.ownerDocument.documentElement,_)){null!==s&&pr(_)&&(b=s.start,void 0===(w=s.end)&&(w=b),"selectionStart"in _?(_.selectionStart=b,_.selectionEnd=Math.min(w,_.value.length)):(w=(b=_.ownerDocument||document)&&b.defaultView||window).getSelection&&(w=w.getSelection(),l=_.textContent.length,E=Math.min(s.start,l),s=void 0===s.end?E:Math.min(s.end,l),!w.extend&&E>s&&(l=s,s=E,E=l),l=fr(_,E),o=fr(_,s),l&&o&&(1!==w.rangeCount||w.anchorNode!==l.node||w.anchorOffset!==l.offset||w.focusNode!==o.node||w.focusOffset!==o.offset)&&((b=b.createRange()).setStart(l.node,l.offset),w.removeAllRanges(),E>s?(w.addRange(b),w.extend(o.node,o.offset)):(b.setEnd(o.node,o.offset),w.addRange(b))))),b=[];for(w=_;w=w.parentNode;)1===w.nodeType&&b.push({element:w,left:w.scrollLeft,top:w.scrollTop});for("function"===typeof _.focus&&_.focus(),_=0;_<b.length;_++)(w=b[_]).element.scrollLeft=w.left,w.element.scrollTop=w.top}$t=!!Mr,Ur=Mr=null,e.current=n,Hs=r;do{try{for(_=e;null!==Hs;){var C=Hs.flags;if(36&C&&ps(_,Hs.alternate,Hs),128&C){b=void 0;var S=Hs.ref;if(null!==S){var O=Hs.stateNode;switch(Hs.tag){case 5:b=O;break;default:b=O}"function"===typeof S?S(b):S.current=b}}Hs=Hs.nextEffect}}catch(T){if(null===Hs)throw Error(a(330));Fl(Hs,T),Hs=Hs.nextEffect}}while(null!==Hs);Hs=null,Li(),Ns=i}else e.current=n;if(Gs)Gs=!1,Xs=e,Js=t;else for(Hs=r;null!==Hs;)t=Hs.nextEffect,Hs.nextEffect=null,8&Hs.flags&&((C=Hs).sibling=null,C.stateNode=null),Hs=t;if(0===(r=e.pendingLanes)&&($s=null),1===r?e===rl?nl++:(nl=0,rl=e):nl=0,n=n.stateNode,wi&&"function"===typeof wi.onCommitFiberRoot)try{wi.onCommitFiberRoot(bi,n,void 0,64===(64&n.current.flags))}catch(T){}if(dl(e,Wi()),Ks)throw Ks=!1,e=Ys,Ys=null,e;return 0!==(8&Ns)||Qi(),null}function Il(){for(;null!==Hs;){var e=Hs.alternate;ll||null===sl||(0!==(8&Hs.flags)?et(Hs,sl)&&(ll=!0):13===Hs.tag&&Os(e,Hs)&&et(Hs,sl)&&(ll=!0));var t=Hs.flags;0!==(256&t)&&ds(e,Hs),0===(512&t)||Gs||(Gs=!0,Vi(97,(function(){return Rl(),null}))),Hs=Hs.nextEffect}}function Rl(){if(90!==Js){var e=97<Js?97:Js;return Js=90,qi(e,Ll)}return!1}function Dl(e,t){Zs.push(t,e),Gs||(Gs=!0,Vi(97,(function(){return Rl(),null})))}function jl(e,t){el.push(t,e),Gs||(Gs=!0,Vi(97,(function(){return Rl(),null})))}function Ll(){if(null===Xs)return!1;var e=Xs;if(Xs=null,0!==(48&Ns))throw Error(a(331));var t=Ns;Ns|=32;var n=el;el=[];for(var r=0;r<n.length;r+=2){var i=n[r],o=n[r+1],s=i.destroy;if(i.destroy=void 0,"function"===typeof s)try{s()}catch(u){if(null===o)throw Error(a(330));Fl(o,u)}}for(n=Zs,Zs=[],r=0;r<n.length;r+=2){i=n[r],o=n[r+1];try{var l=i.create;i.destroy=l()}catch(u){if(null===o)throw Error(a(330));Fl(o,u)}}for(l=e.current.firstEffect;null!==l;)e=l.nextEffect,l.nextEffect=null,8&l.flags&&(l.sibling=null,l.stateNode=null),l=e;return Ns=t,Qi(),!0}function Al(e,t,n){lo(e,t=us(0,t=as(n,t),1)),t=ul(),null!==(e=hl(e,1))&&(qt(e,1,t),dl(e,t))}function Fl(e,t){if(3===e.tag)Al(e,e,t);else for(var n=e.return;null!==n;){if(3===n.tag){Al(n,e,t);break}if(1===n.tag){var r=n.stateNode;if("function"===typeof n.type.getDerivedStateFromError||"function"===typeof r.componentDidCatch&&(null===$s||!$s.has(r))){var i=cs(n,e=as(t,e),1);if(lo(n,i),i=ul(),null!==(n=hl(n,1)))qt(n,1,i),dl(n,i);else if("function"===typeof r.componentDidCatch&&(null===$s||!$s.has(r)))try{r.componentDidCatch(t,e)}catch(o){}break}}n=n.return}}function Ml(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ul(),e.pingedLanes|=e.suspendedLanes&n,Ps===e&&(Rs&n)===n&&(4===Ls||3===Ls&&(62914560&Rs)===Rs&&500>Wi()-Bs?wl(e,0):Ws|=n),dl(e,t)}function Ul(e,t){var n=e.stateNode;null!==n&&n.delete(t),0===(t=0)&&(0===(2&(t=e.mode))?t=1:0===(4&t)?t=99===zi()?1:2:(0===ol&&(ol=Fs),0===(t=zt(62914560&~ol))&&(t=4194304))),n=ul(),null!==(e=hl(e,t))&&(qt(e,t,n),dl(e,n))}function Wl(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.t
vendor: 4,637 bytes, line 2
2ype=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function zl(e,t,n,r){return new Wl(e,t,n,r)}function Bl(e){return!(!(e=e.prototype)||!e.isReactComponent)}function ql(e,t){var n=e.alternate;return null===n?((n=zl(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Vl(e,t,n,r,i,o){var s=2;if(r=e,"function"===typeof e)Bl(e)&&(s=1);else if("string"===typeof e)s=5;else e:switch(e){case S:return Ql(n.children,i,o,t);case A:s=8,i|=16;break;case O:s=8,i|=1;break;case T:return(e=zl(12,n,t,8|i)).elementType=T,e.type=T,e.lanes=o,e;case P:return(e=zl(13,n,t,i)).type=P,e.elementType=P,e.lanes=o,e;case I:return(e=zl(19,n,t,i)).elementType=I,e.lanes=o,e;case F:return Hl(n,i,o,t);case M:return(e=zl(24,n,t,i)).elementType=M,e.lanes=o,e;default:if("object"===typeof e&&null!==e)switch(e.$$typeof){case k:s=10;break e;case x:s=9;break e;case N:s=11;break e;case R:s=14;break e;case D:s=16,r=null;break e;case j:s=22;break e}throw Error(a(130,null==e?e:typeof e,""))}return(t=zl(s,n,t,i)).elementType=e,t.type=r,t.lanes=o,t}function Ql(e,t,n,r){return(e=zl(7,e,r,t)).lanes=n,e}function Hl(e,t,n,r){return(e=zl(23,e,r,t)).elementType=F,e.lanes=n,e}function Kl(e,t,n){return(e=zl(6,e,null,t)).lanes=n,e}function Yl(e,t,n){return(t=zl(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function $l(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=Bt(0),this.expirationTimes=Bt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Bt(0),this.mutableSourceEagerHydrationData=null}function Gl(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:C,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}function Xl(e,t,n,r){var i=t.current,o=ul(),s=cl(i);e:if(n){t:{if(Ge(n=n._reactInternals)!==n||1!==n.tag)throw Error(a(170));var l=n;do{switch(l.tag){case 3:l=l.stateNode.context;break t;case 1:if(pi(l.type)){l=l.stateNode.__reactInternalMemoizedMergedChildContext;break t}}l=l.return}while(null!==l);throw Error(a(171))}if(1===n.tag){var u=n.type;if(pi(u)){n=gi(n,u,l);break e}}n=l}else n=ui;return null===t.context?t.context=n:t.pendingContext=n,(t=so(o,s)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),lo(i,t),fl(i,s,o),s}function Jl(e){if(!(e=e.current).child)return null;switch(e.child.tag){case 5:default:return e.child.stateNode}}function Zl(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function eu(e,t){Zl(e,t),(e=e.alternate)&&Zl(e,t)}function tu(e,t,n){var r=null!=n&&null!=n.hydrationOptions&&n.hydrationOptions.mutableSources||null;if(n=new $l(e,t,null!=n&&!0===n.hydrate),t=zl(3,null,null,2===t?7:1===t?3:0),n.current=t,t.stateNode=n,oo(t),e[Xr]=n.current,Nr(8===e.nodeType?e.parentNode:e),r)for(e=0;e<r.length;e++){var i=(t=r[e])._getVersion;i=i(t._source),null==n.mutableSourceEagerHydrationData?n.mutableSourceEagerHydrationData=[t,i]:n.mutableSourceEagerHydrationData.push(t,i)}this._internalRoot=n}function nu(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function ru(e,t,n,r,i){var o=n._reactRootContainer;if(o){var a=o._internalRoot;if("function"===typeof i){var s=i;i=function(){var e=Jl(a);s.call(e)}}Xl(t,a,e,i)}else{if(o=n._reactRootContainer=function(e,t){if(t||(t=!(!(t=e?9===e.nodeType?e.documentElement:e.firstChild:null)||1!==t.nodeType||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new tu(e,0,t?{hydrate:!0}:void 0)}(n,r),a=o._internalRoot,"function"===typeof i){var l=i;
vendor: 6,926 bytes, line 2
2i=function(){var e=Jl(a);l.call(e)}}ml((function(){Xl(t,a,e,i)}))}return Jl(a)}function iu(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!nu(t))throw Error(a(200));return Gl(e,t,null,n)}Qs=function(e,t,n){var r=t.lanes;if(null!==e)if(e.memoizedProps!==t.pendingProps||fi.current)ja=!0;else{if(0===(n&r)){switch(ja=!1,t.tag){case 3:Va(t),Qo();break;case 5:Do(t);break;case 1:pi(t.type)&&mi(t);break;case 4:Io(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var i=t.type._context;li($i,i._currentValue),i._currentValue=r;break;case 13:if(null!==t.memoizedState)return 0!==(n&t.child.childLanes)?$a(e,t,n):(li(Lo,1&Lo.current),null!==(t=ns(e,t,n))?t.sibling:null);li(Lo,1&Lo.current);break;case 19:if(r=0!==(n&t.childLanes),0!==(64&e.flags)){if(r)return ts(e,t,n);t.flags|=64}if(null!==(i=t.memoizedState)&&(i.rendering=null,i.tail=null,i.lastEffect=null),li(Lo,Lo.current),r)break;return null;case 23:case 24:return t.lanes=0,Ua(e,t,n)}return ns(e,t,n)}ja=0!==(16384&e.flags)}else ja=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=di(t,ci.current),no(t,n),i=ia(null,t,r,e,i,n),t.flags|=1,"object"===typeof i&&null!==i&&"function"===typeof i.render&&void 0===i.$$typeof){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,pi(r)){var o=!0;mi(t)}else o=!1;t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,oo(t);var s=r.getDerivedStateFromProps;"function"===typeof s&&po(t,r,s,e),i.updater=yo,t.stateNode=i,i._reactInternals=t,_o(t,r,e,n),t=qa(null,t,r,!0,o,n)}else t.tag=0,La(null,t,i,n),t=t.child;return t;case 16:i=t.elementType;e:{switch(null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=(o=i._init)(i._payload),t.type=i,o=t.tag=function(e){if("function"===typeof e)return Bl(e)?1:0;if(void 0!==e&&null!==e){if((e=e.$$typeof)===N)return 11;if(e===R)return 14}return 2}(i),e=Yi(i,e),o){case 0:t=za(null,t,i,e,n);break e;case 1:t=Ba(null,t,i,e,n);break e;case 11:t=Aa(null,t,i,e,n);break e;case 14:t=Fa(null,t,i,Yi(i.type,e),r,n);break e}throw Error(a(306,i,""))}return t;case 0:return r=t.type,i=t.pendingProps,za(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 1:return r=t.type,i=t.pendingProps,Ba(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 3:if(Va(t),r=t.updateQueue,null===e||null===r)throw Error(a(282));if(r=t.pendingProps,i=null!==(i=t.memoizedState)?i.element:null,ao(e,t),co(t,r,null,n),(r=t.memoizedState.element)===i)Qo(),t=ns(e,t,n);else{if((o=(i=t.stateNode).hydrate)&&(Mo=Qr(t.stateNode.containerInfo.firstChild),Fo=t,o=Uo=!0),o){if(null!=(e=i.mutableSourceEagerHydrationData))for(i=0;i<e.length;i+=2)(o=e[i])._workInProgressVersionPrimary=e[i+1],Ho.push(o);for(n=Oo(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|1024,n=n.sibling}else La(e,t,r,n),Qo();t=t.child}return t;case 5:return Do(t),null===e&&Bo(t),r=t.type,i=t.pendingProps,o=null!==e?e.memoizedProps:null,s=i.children,zr(r,i)?s=null:null!==o&&zr(r,o)&&(t.flags|=16),Wa(e,t),La(e,t,s,n),t.child;case 6:return null===e&&Bo(t),null;case 13:return $a(e,t,n);case 4:return Io(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=So(t,null,r,n):La(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,Aa(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 7:return La(e,t,t.pendingProps,n),t.child;case 8:case 12:return La(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value;var l=t.type._context;if(li($i,l._currentValue),l._currentValue=o,null!==s)if(l=s.value,0===(o=sr(l,o)?0:0|("function"===typeof r._calculateChangedBits?r._calculateChangedBits(l,o):1073741823))){if(s.children===i.children&&!fi.current){t=ns(e,t,n);break e}}else for(null!==(l=t.child)&&(l.return=t);null!==l;){var u=l.dependencies;if(null!==u){s=l.child;for(var c=u.firstContext;null!==c;){if(c.context===r&&0!==(c.observedBits&o)){1===l.tag&&((c=so(-1,n&-n)).tag=2,lo(l,c)),l.lanes|=n,null!==(c=l.alternate)&&(c.lanes|=n),to(l.return,n),u.lanes|=n;break}c=c.next}}else s=10===l.tag&&l.type===t.type?null:l.child;if(null!==s)s.return=l;else for(s=l;null!==s;){if(s===t){s=null;break}if(null!==(l=s.sibling)){l.return=s.return,s=l;break}s=s.return}l=s}La(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=(o=t.pendingProps).children,no(t,n),r=r(i=ro(i,o.unstable_observedBits)),t.flags|=1,La(e,t,r,n),t.child;case 14:return o=Yi(i=t.type,t.pendingProps),Fa(e,t,i,o=Yi(i.type,o),r,n);case 15:return Ma(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Yi(r,i),null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,pi(r)?(e=!0,mi(t)):e=!1,no(t,n),go(t,r,i),_o(t,r,i,n),qa(null,t,r,!0,e,n);case 19:return ts(e,t,n);case 23:case 24:return Ua(e,t,n)}throw Error(a(156,t.tag))},tu.prototype.render=function(e){Xl(e,this._internalRoot,null,null)},tu.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;Xl(null,e,null,(function(){t[Xr]=null}))},tt=function(e){13===e.tag&&(fl(e,4,ul()),eu(e,4))},nt=function(e){13===e.tag&&(fl(e,67108864,ul()),eu(e,67108864))},rt=function(e){if(13===e.tag){var t=ul(),n=cl(e);fl(e,n,t),eu(e,n)}},it=function(e,t){return t()},ke=function(e,t,n){switch(t){case"input":if(ne(e,n),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=ni(r);if(!i)throw Error(a(90));X(r),ne(r,i)}}}break;case"textarea":ue(e,n);break;case"select":null!=(t=n.value)&&ae(e,!!n.multiple,t,!1)}},De=gl,je=function(e,t,n,r,i){var o=Ns;Ns|=4;try{return qi(98,e.bind(null,t,n,r,i))}finally{0===(Ns=o)&&(Vs(),Qi())}},Le=function(){0===(49&Ns)&&(function(){if(null!==tl){var e=tl;tl=null,e.forEach((function(e){e.expiredLanes|=24&e.pendingLanes,dl(e,Wi())}))}Qi()}(),Rl())},Ae=function(e,t){var n=Ns;Ns|=2;try{return e(t)}finally{0===(Ns=n)&&(Vs(),Qi())}};var ou={Events:[ei,ti,ni,Ie,Re,Rl,{current:!1}]},au={findFiberByHostInstance:Zr,bundleType:0,version:"17.0.1",rendererPackageName:"react-dom"},su={bundleType:au.bundleType,version:au.version,rendererPackageName:au.rendererPackageName,rendererConfig:au.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:w.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Ze(e))?null:e.stateNode},findFiberByHostInstance:au.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var lu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!lu.isDisabled&&lu.supportsFiber)try{bi=lu.inject(su),wi=lu}catch(ve){}}
2t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ou,t.createPortal=iu,t.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"===typeof e.render)throw Error(a(188));throw Error(a(268,Object.keys(e)))}return e=null===(e=Ze(t))?null:e.stateNode},t.flushSync=function(e,t){var n=Ns;if(0!==(48&n))return e(t);Ns|=1;try{if(e)return qi(99,e.bind(null,t))}finally{Ns=n,Qi()}},t.hydrate=function(e,t,n){if(!nu(t))throw Error(a(200));return ru(null,e,t,!0,n)},t.render=function(e,t,n){if(!nu(t))throw Error(a(200));return ru(null,e,t,!1,n)},t.unmountComponentAtNode=function(e){if(!nu(e))throw Error(a(40));return!!e._reactRootContainer&&(ml((function(){ru(null,null,e,!1,(function(){e._reactRootContainer=null,e[Xr]=null}))})),!0)},t.unstable_batchedUpdates=gl,t.unstable_createPortal=function(e,t){return iu(e,t,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)},t.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!nu(n))throw Error(a(200));if(null==e||void 0===e._reactInternals)throw Error(a(38));return ru(e,t,n,!1,r)},t.version="17.0.1"},function(e,t,n){"use strict";e.exports=n(34)},function(e,t,n){"use strict";var r,i,o,a;if("object"===typeof performance&&"function"===typeof performance.now){var s=performance;t.unstable_now=function(){return s.now()}}else{var l=Date,u=l.now();t.unstable_now=function(){return l.now()-u}}if("undefined"===typeof window||"function"!==typeof MessageChannel){var c=null,f=null,h=function e(){if(null!==c)try{var n=t.unstable_now();c(!0,n),c=null}catch(r){throw setTimeout(e,0),r}};r=function(e){null!==c?setTimeout(r,0,e):(c=e,setTimeout(h,0))},i=function(e,t){f=setTimeout(e,t)},o=function(){clearTimeout(f)},t.unstable_shouldYield=function(){return!1},a=t.unstable_forceFrameRate=function(){}}else{var d=window.setTimeout,p=window.clearTimeout;if("undefined"!==typeof console){var y=window.cancelAnimationFrame;"function"!==typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),"function"!==typeof y&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var v=!1,g=null,m=-1,_=5,b=0;t.unstable_shouldYield=function(){return t.unstable_now()>=b},a=function(){},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):_=0<e?Math.floor(1e3/e):5};var w=new MessageChannel,E=w.port2;w.port1.onmessage=function(){if(null!==g){var e=t.unstable_now();b=e+_;try{g(!0,e)?E.postMessage(null):(v=!1,g=null)}catch(n){throw E.postMessage(null),n}}else v=!1},r=function(e){g=e,v||(v=!0,E.postMessage(null))},i=function(e,n){m=d((function(){e(t.unstable_now())}),n)},o=function(){p(m),m=-1}}function C(e,t){var n=e.length;e.push(t);e:for(;;){var r=n-1>>>1,i=e[r];if(!(void 0!==i&&0<T(i,t)))break e;e[r]=t,e[n]=i,n=r}}function S(e){return void 0===(e=e[0])?null:e}function O(e){var t=e[0];if(void 0!==t){var n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length;r<i;){var o=2*(r+1)-1,a=e[o],s=o+1,l=e[s];if(void 0!==a&&0>T(a,n))void 0!==l&&0>T(l,a)?(e[r]=l,e[s]=n,r=s):(e[r]=a,e[o]=n,r=o);else{if(!(void 0!==l&&0>T(l,n)))break e;e[r]=l,e[s]=n,r=s}}}return t}return null}function T(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}var k=[],x=[],N=1,P=null,I=3,R=!1,D=!1,j=!1;function L(e){for(var t=S(x);null!==t;){if(null===t.callback)O(x);else{if(!(t.startTime<=e))break;O(x),t.sortIndex=t.expirationTime,C(k,t)}t=S(x)}}function A(e){if(j=!1,L(e),!D)if(null!==S(k))D=!0,r(F);else{var t=S(x);null!==t&&i(A,t.startTime-e)}}function F(e,n){D=!1,j&&(j=!1,o()),R=!0;var r=I;try{for(L(n),P=S(k);null!==P&&(!(P.expirationTime>n)||e&&!t.unstable_shouldYield());){var a=P.callback;if("function"===typeof a){P.callback=null,I=P.priorityLevel;var s=a(P.expirationTime<=n);n=t.unstable_now(),"function"===typeof s?P.callback=s:P===S(k)&&O(k),L(n)}else O(k);P=S(k)}if(null!==P)var l=!0;else{var u=S(x);null!==u&&i(A,u.startTime-n),l=!1}return l}finally{P=null,I=r,R=!1}}var M=a;t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){D||R||(D=!0,r(F))},t.unstable_getCurrentPriorityLevel=function(){return I},t.unstable_getFirstCallbackNode=function(){return S(k)},t.unstable_next=function(e){switch(I){case 1:case 2:case 3:var t=3;break;default:t=I}var n=I;I=t;try{return e()}finally{I=n}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=M,t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=I;I=e;try{return t()}finally{I=n}},t.unstable_scheduleCallback=function(e,n,a){var s=t.unstable_now();switch("object"===typeof a&&null!==a?a="number"===typeof(a=a.delay)&&0<a?s+a:s:a=s,e){case 1:var l=-1;break;case 2:l=250;break;case 5:l=1073741823;break;case 4:l=1e4;break;default:l=5e3}return e={id:N++,callback:n,priorityLevel:e,startTime:a,expirationTime:l=a+l,sortIndex:-1},a>s?(e.sortIndex=a,C(x,e),null===S(k)&&e===S(x)&&(j?o():j=!0,i(A,a-s))):(e.sortIndex=l,C(k,e),D||R||(D=!0,r(F))),e},t.unstable_wrapCallback=function(e){var t=I;return function(){var n=I;I=t;try{return e.apply(this,arguments)}finally{I=n}}}},,function(e,t,n){"use strict";var r=n(4),i=n(15),o=n(37),a=n(22);function s(e){var t=new o(e),n=i(o.prototype.request,t);return r.extend(n,o.prototype,t),r.extend(n,t),n}var l=s(n(18));l.Axios=o,l.create=function(e){return s(a(l.defaults,e))},l.Cancel=n(23),l.CancelToken=n(50),l.isCancel=n(17),l.all=function(e){return Promise.all(e)},l.spread=n(51),e.exports=l,e.exports.default=l},function(e,t,n){"use strict";var r=n(4),i=n(16),o=n(38),a=n(39),s=n(22);function l(e){this.defaults=e,this.interceptors={request:new o,response:new o}}l.prototype.request=function(e){"string"===typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=s(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var t=[a,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach((function(e){t.unshift(e.fulfilled,e.rejected)})),this.interceptors.response.forEach((function(e){t.push(e.fulfilled,e.rejected)}));t.length;)n=n.then(t.shift(),t.shift());return n},l.prototype.getUri=function(e){return e=s(this.defaults,e),i(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(e){l.prototype[e]=function(t,n){return this.request(s(n||{},{method:e,url:t,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(e){l.prototype[e]=function(t,n,r){return this.request(s(r||{},{method:e,url:t,data:n}))}})),e.exports=l},function(e,t,n){"use strict";var r=n(4);function i(){this.handlers=[]}i.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},i.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},i.prototype.forEach=function(e){r.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=i},function(e,t,n){"use strict";var r=n(4),i=n(40),o=n(17),a=n(18);function s(e){e.cancelToken&&e.cancelToken.throwIfRequested()}e.exports=function(e){return s(e),e.headers=e.headers||{},e.data=i(e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||a.adapter)(e).then((function(t){return s(e),t.data=i(t.data,t.headers,e.transformResponse),t}),(function(t){return o(t)||(s(e),t&&t.response&&(t.response.data=i(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},function(e,t,n){"use strict";var r=n(4);e.exports=function(e,t,n){return r.forEach(n,(function(n){e=n(e,t)})),e}},function(e,t,n){"use strict";var r=n(4);e.exports=function(e,t){r.forEach(e,(function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])}))}},function(e,t,n){"use strict";var r=n(21);e.exports=function(e,t,n){var i=n.config.validateStatus;
2n.status&&i&&!i(n.status)?t(r("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}},function(e,t,n){"use strict";e.exports=function(e,t,n,r,i){return e.config=t,n&&(e.code=n),e.request=r,e.response=i,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}},function(e,t,n){"use strict";var r=n(4);e.exports=r.isStandardBrowserEnv()?{write:function(e,t,n,i,o,a){var s=[];s.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),r.isString(i)&&s.push("path="+i),r.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(e,t,n){"use strict";var r=n(46),i=n(47);e.exports=function(e,t){return e&&!r(t)?i(e,t):t}},function(e,t,n){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t,n){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e,t,n){"use strict";var r=n(4),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,o,a={};return e?(r.forEach(e.split("\n"),(function(e){if(o=e.indexOf(":"),t=r.trim(e.substr(0,o)).toLowerCase(),n=r.trim(e.substr(o+1)),t){if(a[t]&&i.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([n]):a[t]?a[t]+", "+n:n}})),a):a}},function(e,t,n){"use strict";var r=n(4);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=i(window.location.href),function(t){var n=r.isString(t)?i(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0}},function(e,t,n){"use strict";var r=n(23);function i(e){if("function"!==typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.source=function(){var e;return{token:new i((function(t){e=t})),cancel:e}},e.exports=i},function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},function(e,t,n){var r=n(53),i=n(54),o=n(25),a=n(55);e.exports=function(e){return r(e)||i(e)||o(e)||a()}},function(e,t,n){var r=n(24);e.exports=function(e){if(Array.isArray(e))return r(e)}},function(e,t){e.exports=function(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},function(e,t,n){var r=n(57),i=n(58),o=n(25),a=n(59);e.exports=function(e,t){return r(e)||i(e,t)||o(e,t)||a()}},function(e,t){e.exports=function(e){if(Array.isArray(e))return e}},function(e,t){e.exports=function(e,t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to de
2structure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";n(62)},function(e,t,n){"use strict";(function(e,t){var r=n(11),i=n(2),o=n(0),a=n(10),s=n(9),l=function(){function e(e){this.domStorage_=e,this.prefix_="firebase:"}return e.prototype.set=function(e,t){null==t?this.domStorage_.removeItem(this.prefixedName_(e)):this.domStorage_.setItem(this.prefixedName_(e),Object(o.A)(t))},e.prototype.get=function(e){var t=this.domStorage_.getItem(this.prefixedName_(e));return null==t?null:Object(o.u)(t)},e.prototype.remove=function(e){this.domStorage_.removeItem(this.prefixedName_(e))},e.prototype.prefixedName_=function(e){return this.prefix_+e},e.prototype.toString=function(){return this.domStorage_.toString()},e}(),u=function(){function e(){this.cache_={},this.isInMemoryStorage=!0}return e.prototype.set=function(e,t){null==t?delete this.cache_[e]:this.cache_[e]=t},e.prototype.get=function(e){return Object(o.h)(this.cache_,e)?this.cache_[e]:null},e.prototype.remove=function(e){delete this.cache_[e]},e}(),c=function(e){try{if("undefined"!==typeof window&&"undefined"!==typeof window[e]){var t=window[e];return t.setItem("firebase:sentinel","cache"),t.removeItem("firebase:sentinel"),new l(t)}}catch(n){}return new u},f=c("localStorage"),h=c("sessionStorage"),d=new a.b("@firebase/database"),p=function(){var e=1;return function(){return e++}}(),y=function(e){var t=Object(o.z)(e),n=new o.c;n.update(t);var r=n.digest();return o.f.encodeByteArray(r)},v=function e(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r="",i=0;i<t.length;i++){var a=t[i];Array.isArray(a)||a&&"object"===typeof a&&"number"===typeof a.length?r+=e.apply(null,a):r+="object"===typeof a?Object(o.A)(a):a,r+=" "}return r},g=null,m=!0,_=function(e,t){Object(o.d)(!t||!0===e||!1===e,"Can't turn on custom loggers persistently."),!0===e?(d.logLevel=a.a.VERBOSE,g=d.log.bind(d),t&&h.set("logging_enabled",!0)):"function"===typeof e?g=e:(g=null,h.remove("logging_enabled"))},b=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(!0===m&&(m=!1,null===g&&!0===h.get("logging_enabled")&&_(!0)),g){var n=v.apply(null,e);g(n)}},w=function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];b.apply(void 0,Object(i.f)([e],t))}},E=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n="FIREBASE INTERNAL ERROR: "+v.apply(void 0,Object(i.f)(e));d.error(n)},C=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n="FIREBASE FATAL ERROR: "+v.apply(void 0,Object(i.f)(e));throw d.error(n),new Error(n)},S=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n="FIREBASE WARNING: "+v.apply(void 0,Object(i.f)(e));d.warn(n)},O=function(e){return"number"===typeof e&&(e!==e||e===Number.POSITIVE_INFINITY||e===Number.NEGATIVE_INFINITY)},T="[MIN_NAME]",k="[MAX_NAME]",x=function(e,t){if(e===t)return 0;if(e===T||t===k)return-1;if(t===T||e===k)return 1;var n=A(e),r=A(t);return null!==n?null!==r?n-r===0?e.length-t.length:n-r:-1:null!==r?1:e<t?-1:1},N=function(e,t){return e===t?0:e<t?-1:1},P=function(e,t){if(t&&e in t)return t[e];throw new Error("Missing required key ("+e+") in object: "+Object(o.A)(t))},I=function e(t){if("object"!==typeof t||null===t)return Object(o.A)(t);var n=[];for(var r in t)n.push(r);n.sort();for(var i="{",a=0;a<n.length;a++)0!==a&&(i+=","),i+=Object(o.A)(n[a]),i+=":",i+=e(t[n[a]]);return i+="}"},R=function(e,t){var n=e.length;if(n<=t)return[e];for(var r=[],i=0;i<n;i+=t)i+t>n?r.push(e.substring(i,n)):r.push(e.substring(i,i+t));return r};function D(e,t){for(var n in e)e.hasOwnProperty(n)&&t(n,e[n])}var j=function(e){Object(o.d)(!O(e),"Invalid JSON number");var t,n,r,i,a,s=1023;0===e?(n=0,r=0,t=1/e===-1/0?1:0):(t=e<0,(e=Math.abs(e))>=Math.pow(2,-1022)?(n=(i=Math.min(Math.floor(Math.log(e)/Math.LN2),s))+s,r=Math.round(e*Math.pow(2,52-i)-Math.pow(2,52))):(n=0,r=Math.round(e/Math.pow(2,-1074))));var l=[];for(a=52;a;a-=1)l.push(r%2?1:0),r=Math.floor(r/2);for(a=11;a;a-=1)l.push(n%2?1:0),n=Math.floor(n/2);l.push(t?1:0),l.reverse();var u=l.join(""),c="";for(a=0;a<64;a+=8){var f=parseInt(u.substr(a,8),2).toString(16);1===f.length&&(f="0"+f),c+=f}return c.toLowerCase()},L=new RegExp("^-?(0*)\\d{1,10}$"),A=function(e){if(L.test(e)){var t=Number(e);if(t>=-2147483648&&t<=2147483647)return t}return null},F=function(e){try{e()}catch(t){setTimeout((function(){var e=t.stack||"";throw S("Exception was thrown by user callback.",e),t}),Math.floor(0))}},M=function(e,t){var n=setTimeout(e,t);return"object"===typeof n&&n.unref&&n.unref(),n},U=function(){function e(e,t){if(void 0===t){this.pieces_=e.split("/");for(var n=0,r=0;r<this.pieces_.length;r++)this.pieces_[r].length>0&&(this.pieces_[n]=this.pieces_[r],n++);this.pieces_.length=n,this.pieceNum_=0}else this.pieces_=e,this.pieceNum_=t}return Object.defineProperty(e,"Empty",{get:function(){return new e("")}
2,enumerable:!1,configurable:!0}),e.prototype.getFront=function(){return this.pieceNum_>=this.pieces_.length?null:this.pieces_[this.pieceNum_]},e.prototype.getLength=function(){return this.pieces_.length-this.pieceNum_},e.prototype.popFront=function(){var t=this.pieceNum_;return t<this.pieces_.length&&t++,new e(this.pieces_,t)},e.prototype.getBack=function(){return this.pieceNum_<this.pieces_.length?this.pieces_[this.pieces_.length-1]:null},e.prototype.toString=function(){for(var e="",t=this.pieceNum_;t<this.pieces_.length;t++)""!==this.pieces_[t]&&(e+="/"+this.pieces_[t]);return e||"/"},e.prototype.toUrlEncodedString=function(){for(var e="",t=this.pieceNum_;t<this.pieces_.length;t++)""!==this.pieces_[t]&&(e+="/"+encodeURIComponent(String(this.pieces_[t])));return e||"/"},e.prototype.slice=function(e){return void 0===e&&(e=0),this.pieces_.slice(this.pieceNum_+e)},e.prototype.parent=function(){if(this.pieceNum_>=this.pieces_.length)return null;for(var t=[],n=this.pieceNum_;n<this.pieces_.length-1;n++)t.push(this.pieces_[n]);return new e(t,0)},e.prototype.child=function(t){for(var n=[],r=this.pieceNum_;r<this.pieces_.length;r++)n.push(this.pieces_[r]);if(t instanceof e)for(r=t.pieceNum_;r<t.pieces_.length;r++)n.push(t.pieces_[r]);else{var i=t.split("/");for(r=0;r<i.length;r++)i[r].length>0&&n.push(i[r])}return new e(n,0)},e.prototype.isEmpty=function(){return this.pieceNum_>=this.pieces_.length},e.relativePath=function(t,n){var r=t.getFront(),i=n.getFront();if(null===r)return n;if(r===i)return e.relativePath(t.popFront(),n.popFront());throw new Error("INTERNAL ERROR: innerPath ("+n+") is not within outerPath ("+t+")")},e.comparePaths=function(e,t){for(var n=e.slice(),r=t.slice(),i=0;i<n.length&&i<r.length;i++){var o=x(n[i],r[i]);if(0!==o)return o}return n.length===r.length?0:n.length<r.length?-1:1},e.prototype.equals=function(e){if(this.getLength()!==e.getLength())return!1;for(var t=this.pieceNum_,n=e.pieceNum_;t<=this.pieces_.length;t++,n++)if(this.pieces_[t]!==e.pieces_[n])return!1;return!0},e.prototype.contains=function(e){var t=this.pieceNum_,n=e.pieceNum_;if(this.getLength()>e.getLength())return!1;for(;t<this.pieces_.length;){if(this.pieces_[t]!==e.pieces_[n])return!1;++t,++n}return!0},e}(),W=function(){function e(e,t){this.errorPrefix_=t,this.parts_=e.slice(),this.byteLength_=Math.max(1,this.parts_.length);for(var n=0;n<this.parts_.length;n++)this.byteLength_+=Object(o.y)(this.parts_[n]);this.checkValid_()}return Object.defineProperty(e,"MAX_PATH_DEPTH",{get:function(){return 32},enumerable:!1,configurable:!0}),Object.defineProperty(e,"MAX_PATH_LENGTH_BYTES",{get:function(){return 768},enumerable:!1,configurable:!0}),e.prototype.push=function(e){this.parts_.length>0&&(this.byteLength_+=1),this.parts_.push(e),this.byteLength_+=Object(o.y)(e),this.checkValid_()},e.prototype.pop=function(){var e=this.parts_.pop();this.byteLength_-=Object(o.y)(e),this.parts_.length>0&&(this.byteLength_-=1)},e.prototype.checkValid_=function(){if(this.byteLength_>e.MAX_PATH_LENGTH_BYTES)throw new Error(this.errorPrefix_+"has a key path longer than "+e.MAX_PATH_LENGTH_BYTES+" bytes ("+this.byteLength_+").");if(this.parts_.length>e.MAX_PATH_DEPTH)throw new Error(this.errorPrefix_+"path specified exceeds the maximum depth that can be written ("+e.MAX_PATH_DEPTH+") or object contains a cycle "+this.toErrorString())},e.prototype.toErrorString=function(){return 0===this.parts_.length?"":"in property '"+this.parts_.join(".")+"'"},e}(),z="5",B="firebaseio.com",q="websocket",V="long_polling",Q=function(){function e(e,t,n,r,i,o,a){void 0===i&&(i=!1),void 0===o&&(o=""),void 0===a&&(a=!1),this.secure=t,this.namespace=n,this.webSocketOnly=r,this.nodeAdmin=i,this.persistenceKey=o,this.includeNamespaceInQueryParams=a,this.host=e.toLowerCase(),this.domain=this.host.substr(this.host.indexOf(".")+1),this.internalHost=f.get("host:"+e)||this.host}return e.prototype.needsQueryParam=function(){return this.host!==this.internalHost||this.isCustomHost()||this.includeNamespaceInQueryParams},e.prototype.isCacheableHost=function(){return"s-"===this.internalHost.substr(0,2)},e.prototype.isDemoHost=function(){return"firebaseio-demo.com"===this.domain},e.prototype.isCustomHost=function(){return"firebaseio.com"!==this.domain&&"firebaseio-demo.com"!==this.domain},e.prototype.updateHost=function(e){e!==this.internalHost&&(this.internalHost=e,this.isCacheableHost()&&f.set("host:"+this.host,this.internalHost))},e.prototype.connectionURL=function(e,t){var n;if(Object(o.d)("string"===typeof e,"typeof type must == string"),Object(o.d)("object"===typeof t,"typeof params must == object"),e===q)n=(this.secure?"wss://":"ws://")+this.internalHost+"/.ws?";else{if(e!==V)throw new Error("Unknown connection type: "+e);n=(this.secure?"https://":"http://")+this.internalHost+"/.lp?"}this.needsQueryParam()&&(t.ns=this.namespace);var r=[];return D(t,(function(e,t){r.push(e+"="+t)}
2)),n+r.join("&")},e.prototype.toString=function(){var e=this.toURLString();return this.persistenceKey&&(e+="<"+this.persistenceKey+">"),e},e.prototype.toURLString=function(){return(this.secure?"https://":"http://")+this.host},e}();var H,K,Y=function(e,t){var n=$(e),r=n.namespace;"firebase.com"===n.domain&&C(n.host+" is no longer supported. Please use <YOUR FIREBASE>.firebaseio.com instead"),r&&"undefined"!==r||"localhost"===n.domain||C("Cannot parse Firebase url. Please use https://<YOUR FIREBASE>.firebaseio.com"),n.secure||"undefined"!==typeof window&&window.location&&window.location.protocol&&-1!==window.location.protocol.indexOf("https:")&&S("Insecure Firebase access from a secure page. Please use https in calls to new Firebase().");var i="ws"===n.scheme||"wss"===n.scheme;return{repoInfo:new Q(n.host,n.secure,r,t,i,"",r!==n.subdomain),path:new U(n.pathString)}},$=function(e){var t="",n="",r="",o="",a="",s=!0,l="https",u=443;if("string"===typeof e){var c=e.indexOf("//");c>=0&&(l=e.substring(0,c-1),e=e.substring(c+2));var f=e.indexOf("/");-1===f&&(f=e.length);var h=e.indexOf("?");-1===h&&(h=e.length),t=e.substring(0,Math.min(f,h)),f<h&&(o=function(e){for(var t="",n=e.split("/"),r=0;r<n.length;r++)if(n[r].length>0){var i=n[r];try{i=decodeURIComponent(i.replace(/\+/g," "))}catch(o){}t+="/"+i}return t}(e.substring(f,h)));var d=function(e){var t,n,r={};"?"===e.charAt(0)&&(e=e.substring(1));try{for(var o=Object(i.g)(e.split("&")),a=o.next();!a.done;a=o.next()){var s=a.value;if(0!==s.length){var l=s.split("=");2===l.length?r[decodeURIComponent(l[0])]=decodeURIComponent(l[1]):S("Invalid query segment '"+s+"' in query '"+e+"'")}}}catch(u){t={error:u}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}(e.substring(Math.min(e.length,h)));(c=t.indexOf(":"))>=0?(s="https"===l||"wss"===l,u=parseInt(t.substring(c+1),10)):c=t.length;var p=t.slice(0,c);if("localhost"===p.toLowerCase())n="localhost";else if(p.split(".").length<=2)n=p;else{var y=t.indexOf(".");r=t.substring(0,y).toLowerCase(),n=t.substring(y+1),a=r}"ns"in d&&(a=d.ns)}return{host:t,port:u,domain:n,subdomain:r,secure:s,scheme:l,pathString:o,namespace:a}},G=/[\[\].#$\/\u0000-\u001F\u007F]/,X=/[\[\].#$\u0000-\u001F\u007F]/,J=10485760,Z=function(e){return"string"===typeof e&&0!==e.length&&!G.test(e)},ee=function(e){return"string"===typeof e&&0!==e.length&&!X.test(e)},te=function(e){return null===e||"string"===typeof e||"number"===typeof e&&!O(e)||e&&"object"===typeof e&&Object(o.h)(e,".sv")},ne=function(e,t,n,r,i){i&&void 0===n||re(Object(o.l)(e,t,i),n,r)},re=function e(t,n,r){var i=r instanceof U?new W(r,t):r;if(void 0===n)throw new Error(t+"contains undefined "+i.toErrorString());if("function"===typeof n)throw new Error(t+"contains a function "+i.toErrorString()+" with contents = "+n.toString());if(O(n))throw new Error(t+"contains "+n.toString()+" "+i.toErrorString());if("string"===typeof n&&n.length>J/3&&Object(o.y)(n)>J)throw new Error(t+"contains a string greater than "+"10485760 utf8 bytes "+i.toErrorString()+" ('"+n.substring(0,50)+"...')");if(n&&"object"===typeof n){var a=!1,s=!1;if(D(n,(function(n,r){if(".value"===n)a=!0;else if(".priority"!==n&&".sv"!==n&&(s=!0,!Z(n)))throw new Error(t+" contains an invalid key ("+n+") "+i.toErrorString()+'. Keys must be non-empty strings and can\'t contain ".", "#", "$", "/", "[", or "]"');i.push(n),e(t,r,i),i.pop()})),a&&s)throw new Error(t+' contains ".value" child '+i.toErrorString()+" in addition to actual children.")}},ie=function(e,t,n,r,i){if(!i||void 0!==n){var a=Object(o.l)(e,t,i);if(!n||"object"!==typeof n||Array.isArray(n))throw new Error(a+" must be an object containing the children to replace.");var s=[];D(n,(function(e,t){var n=new U(e);if(re(a,t,r.child(n)),".priority"===n.getBack()&&!te(t))throw new Error(a+"contains an invalid value for '"+n.toString()+"', which must be a valid Firebase priority (a string, finite number, server value, or null).");s.push(n)})),function(e,t){var n,r;for(n=0;n<t.length;n++)for(var i=(r=t[n]).slice(),o=0;o<i.length;o++)if(".priority"===i[o]&&o===i.length-1);
2else if(!Z(i[o]))throw new Error(e+"contains an invalid key ("+i[o]+") in path "+r.toString()+'. Keys must be non-empty strings and can\'t contain ".", "#", "$", "/", "[", or "]"');t.sort(U.comparePaths);var a=null;for(n=0;n<t.length;n++){if(r=t[n],null!==a&&a.contains(r))throw new Error(e+"contains a path "+a.toString()+" that is ancestor of another path "+r.toString());a=r}}(a,s)}},oe=function(e,t,n,r){if(!r||void 0!==n){if(O(n))throw new Error(Object(o.l)(e,t,r)+"is "+n.toString()+", but must be a valid Firebase priority (a string, finite number, server value, or null).");if(!te(n))throw new Error(Object(o.l)(e,t,r)+"must be a valid Firebase priority (a string, finite number, server value, or null).")}},ae=function(e,t,n,r){if(!r||void 0!==n)switch(n){case"value":case"child_added":case"child_removed":case"child_changed":case"child_moved":break;default:throw new Error(Object(o.l)(e,t,r)+'must be a valid event type = "value", "child_added", "child_removed", "child_changed", or "child_moved".')}},se=function(e,t,n,r){if((!r||void 0!==n)&&!Z(n))throw new Error(Object(o.l)(e,t,r)+'was an invalid key = "'+n+'". Firebase keys must be non-empty strings and can\'t contain ".", "#", "$", "/", "[", or "]").')},le=function(e,t,n,r){if((!r||void 0!==n)&&!ee(n))throw new Error(Object(o.l)(e,t,r)+'was an invalid path = "'+n+'". Paths must be non-empty strings and can\'t contain ".", "#", "$", "[", or "]"')},ue=function(e,t,n,r){n&&(n=n.replace(/^\/*\.info(\/|$)/,"/")),le(e,t,n,r)},ce=function(e,t){if(".info"===t.getFront())throw new Error(e+" failed = Can't modify data under /.info/")},fe=function(e,t,n){var r=n.path.toString();if("string"!==typeof n.repoInfo.host||0===n.repoInfo.host.length||!Z(n.repoInfo.namespace)&&"localhost"!==n.repoInfo.host.split(":")[0]||0!==r.length&&!function(e){return e&&(e=e.replace(/^\/*\.info(\/|$)/,"/")),ee(e)}(r))throw new Error(Object(o.l)(e,t,!1)+'must be a valid firebase URL and the path can\'t contain ".", "#", "$", "[", or "]".')},he=function(e,t,n,r){if((!r||void 0!==n)&&"boolean"!==typeof n)throw new Error(Object(o.l)(e,t,r)+"must be a boolean.")},de=function(){function e(e,t){this.repo_=e,this.path_=t}return e.prototype.cancel=function(e){Object(o.B)("OnDisconnect.cancel",0,1,arguments.length),Object(o.C)("OnDisconnect.cancel",1,e,!0);var t=new o.a;return this.repo_.onDisconnectCancel(this.path_,t.wrapCallback(e)),t.promise},e.prototype.remove=function(e){Object(o.B)("OnDisconnect.remove",0,1,arguments.length),ce("OnDisconnect.remove",this.path_),Object(o.C)("OnDisconnect.remove",1,e,!0);var t=new o.a;return this.repo_.onDisconnectSet(this.path_,null,t.wrapCallback(e)),t.promise},e.prototype.set=function(e,t){Object(o.B)("OnDisconnect.set",1,2,arguments.length),ce("OnDisconnect.set",this.path_),ne("OnDisconnect.set",1,e,this.path_,!1),Object(o.C)("OnDisconnect.set",2,t,!0);var n=new o.a;return this.repo_.onDisconnectSet(this.path_,e,n.wrapCallback(t)),n.promise},e.prototype.setWithPriority=function(e,t,n){Object(o.B)("OnDisconnect.setWithPriority",2,3,arguments.length),ce("OnDisconnect.setWithPriority",this.path_),ne("OnDisconnect.setWithPriority",1,e,this.path_,!1),oe("OnDisconnect.setWithPriority",2,t,!1),Object(o.C)("OnDisconnect.setWithPriority",3,n,!0);var r=new o.a;return this.repo_.onDisconnectSetWithPriority(this.path_,e,t,r.wrapCallback(n)),r.promise},e.prototype.update=function(e,t){if(Object(o.B)("OnDisconnect.update",1,2,arguments.length),ce("OnDisconnect.update",this.path_),Array.isArray(e)){for(var n={},r=0;r<e.length;++r)n[""+r]=e[r];e=n,S("Passing an Array to firebase.database.onDisconnect().update() is deprecated. Use set() if you want to overwrite the existing data, or an Object with integer keys if you really do want to only update some of the children.")}ie("OnDisconnect.update",1,e,this.path_,!1),Object(o.C)("OnDisconnect.update",2,t,!0);var i=new o.a;return this.repo_.onDisconnectUpdate(this.path_,e,i.wrapCallback(t)),i.promise},e}(),pe=function(){function e(e,t){this.committed=e,this.snapshot=t}return e.prototype.toJSON=function(){return Object(o.B)("TransactionResult.toJSON",0,1,arguments.length),{committed:this.committed,snapshot:this.snapshot.toJSON()}},e}(),ye=function(){var e="-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz",t=0,n=[];return function(r){var i,a=r===t;t=r;var s=new Array(8);for(i=7;i>=0;i--)s[i]=e.charAt(r%64),r=Math.floor(r/64);Object(o.d)(0===r,"Cannot push at time == 0");var l=s.join("");if(a){for(i=11;i>=0&&63===n[i];i--)n[i]=0;n[i]++}else for(i=0;i<12;i++)n[i]=Math.floor(64*Math.random());for(i=0;i<12;i++)l+=e.charAt(n[i]);return Object(o.d)(20===l.length,"nextPushId: Length should be 20."),l}}(),ve=function(){function e(e,t){this.name=e,this.node=t}return e.Wrap=function(t,n){return new e(t,n)},e}(),ge=function(){function e(){}return e.prototype.getCompare=function(){return this.compare.bind(this)},e.prototype.indexedValueChanged=function(e,t){var n=new ve(T,e),r=new ve(T,t);return 0!==this.compare(n,r)},e.prototype.minPost=function(){return ve.MIN},e}(),me=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(i.c)(t,e),Object.defineProperty(t,"__EMPTY_NODE",{get:function(){return H},set:function(e){H=e}
2,enumerable:!1,configurable:!0}),t.prototype.compare=function(e,t){return x(e.name,t.name)},t.prototype.isDefinedOn=function(e){throw Object(o.e)("KeyIndex.isDefinedOn not expected to be called.")},t.prototype.indexedValueChanged=function(e,t){return!1},t.prototype.minPost=function(){return ve.MIN},t.prototype.maxPost=function(){return new ve(k,H)},t.prototype.makePost=function(e,t){return Object(o.d)("string"===typeof e,"KeyIndex indexValue must always be a string."),new ve(e,H)},t.prototype.toString=function(){return".key"},t}(ge),_e=new me;var be,we,Ee,Ce=function(e){return"number"===typeof e?"number:"+j(e):"string:"+e},Se=function(e){if(e.isLeafNode()){var t=e.val();Object(o.d)("string"===typeof t||"number"===typeof t||"object"===typeof t&&Object(o.h)(t,".sv"),"Priority must be a string or number.")}else Object(o.d)(e===K||e.isEmpty(),"priority of unexpected type.");Object(o.d)(e===K||e.getPriority().isEmpty(),"Priority nodes can't have a priority of their own.")},Oe=function(){function e(t,n){void 0===n&&(n=e.__childrenNodeConstructor.EMPTY_NODE),this.value_=t,this.priorityNode_=n,this.lazyHash_=null,Object(o.d)(void 0!==this.value_&&null!==this.value_,"LeafNode shouldn't be created with null/undefined value."),Se(this.priorityNode_)}return Object.defineProperty(e,"__childrenNodeConstructor",{get:function(){return be},set:function(e){be=e},enumerable:!1,configurable:!0}),e.prototype.isLeafNode=function(){return!0},e.prototype.getPriority=function(){return this.priorityNode_},e.prototype.updatePriority=function(t){return new e(this.value_,t)},e.prototype.getImmediateChild=function(t){return".priority"===t?this.priorityNode_:e.__childrenNodeConstructor.EMPTY_NODE},e.prototype.getChild=function(t){return t.isEmpty()?this:".priority"===t.getFront()?this.priorityNode_:e.__childrenNodeConstructor.EMPTY_NODE},e.prototype.hasChild=function(){return!1},e.prototype.getPredecessorChildName=function(e,t){return null},e.prototype.updateImmediateChild=function(t,n){return".priority"===t?this.updatePriority(n):n.isEmpty()&&".priority"!==t?this:e.__childrenNodeConstructor.EMPTY_NODE.updateImmediateChild(t,n).updatePriority(this.priorityNode_)},e.prototype.updateChild=function(t,n){var r=t.getFront();return null===r?n:n.isEmpty()&&".priority"!==r?this:(Object(o.d)(".priority"!==r||1===t.getLength(),".priority must be the last token in a path"),this.updateImmediateChild(r,e.__childrenNodeConstructor.EMPTY_NODE.updateChild(t.popFront(),n)))},e.prototype.isEmpty=function(){return!1},e.prototype.numChildren=function(){return 0},e.prototype.forEachChild=function(e,t){return!1},e.prototype.val=function(e){return e&&!this.getPriority().isEmpty()?{".value":this.getValue(),".priority":this.getPriority().val()}:this.getValue()},e.prototype.hash=function(){if(null===this.lazyHash_){var e="";this.priorityNode_.isEmpty()||(e+="priority:"+Ce(this.priorityNode_.val())+":");var t=typeof this.value_;e+=t+":",e+="number"===t?j(this.value_):this.value_,this.lazyHash_=y(e)}return this.lazyHash_},e.prototype.getValue=function(){return this.value_},e.prototype.compareTo=function(t){return t===e.__childrenNodeConstructor.EMPTY_NODE?1:t instanceof e.__childrenNodeConstructor?-1:(Object(o.d)(t.isLeafNode(),"Unknown node type"),this.compareToLeafNode_(t))},e.prototype.compareToLeafNode_=function(t){var n=typeof t.value_,r=typeof this.value_,i=e.VALUE_TYPE_ORDER.indexOf(n),a=e.VALUE_TYPE_ORDER.indexOf(r);return Object(o.d)(i>=0,"Unknown leaf type: "+n),Object(o.d)(a>=0,"Unknown leaf type: "+r),i===a?"object"===r?0:this.value_<t.value_?-1:this.value_===t.value_?0:1:a-i},e.prototype.withIndex=function(){return this},e.prototype.isIndexed=function(){return!0},e.prototype.equals=function(e){if(e===this)return!0;if(e.isLeafNode()){var t=e;return this.value_===t.value_&&this.priorityNode_.equals(t.priorityNode_)}return!1},e.VALUE_TYPE_ORDER=["object","boolean","number","string"],e}();var Te,ke,xe=new(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(i.c)(t,e),t.prototype.compare=function(e,t){var n=e.node.getPriority(),r=t.node.getPriority(),i=n.compareTo(r);return 0===i?x(e.name,t.name):i},t.prototype.isDefinedOn=function(e){return!e.getPriority().isEmpty()},t.prototype.indexedValueChanged=function(e,t){return!e.getPriority().equals(t.getPriority())},t.prototype.minPost=function(){return ve.MIN},t.prototype.maxPost=function(){return new ve(k,new Oe("[PRIORITY-POST]",Ee))},t.prototype.makePost=function(e,t){var n=we(e);return new ve(t,new Oe("[PRIORITY-POST]",n))},t.prototype.toString=function(){return".priority"},t}(ge)),Ne=function(){function e(e,t,n,r,i){void 0===i&&(i=null),this.isReverse_=r,this.resultGenerator_=i,this.nodeStack_=[];for(var o=1;!e.isEmpty();)if(e=e,o=t?n(e.key,t):1,r&&(o*=-1),o<0)e=this.isReverse_?e.left:e.right;else{if(0===o){this.nodeStack_.push(e);break}this.nodeStack_.push(e),e=this.isReverse_?e.right:e.left}}return e.prototype.getNext=function(){if(0===this.nodeStack_.length)return null;var e,t=this.nodeStack_.pop();if(e=this.resultGenerator_?this.resultGenerator_(t.key,t.value):{key:t.key,value:t.value},this.isReverse_)for(t=t.left;!t.isEmpty();)this.nodeStack_.push(t),t=t.right;else for(t=t.right;!t.isEmpty();)this.nodeStack_.push(t),t=t.left;return e},e.prototype.hasNext=function(){return this.nodeStack_.length>0},e.prototype.peek=function(){if(0===this.nodeStack_.length)return null;var e=this.nodeStack_[this.nodeStack_.length-1];return this.resultGenerator_?this.resultGenerator_(e.key,e.value):{key:e.key,value:e.value}},e}(),Pe=function(){function e(t,n,r,i,o){this.key=t,this.value=n,this.color=null!=r?r:e.RED,this.left=null!=i?i:Re.EMPTY_NODE,this.right=null!=o?o:Re.EMPTY_NODE}return e.prototype.copy=function(t,n,r,i,o){return new e(null!=t?t:this.key,null!=n?n:this.value,
2null!=r?r:this.color,null!=i?i:this.left,null!=o?o:this.right)},e.prototype.count=function(){return this.left.count()+1+this.right.count()},e.prototype.isEmpty=function(){return!1},e.prototype.inorderTraversal=function(e){return this.left.inorderTraversal(e)||!!e(this.key,this.value)||this.right.inorderTraversal(e)},e.prototype.reverseTraversal=function(e){return this.right.reverseTraversal(e)||e(this.key,this.value)||this.left.reverseTraversal(e)},e.prototype.min_=function(){return this.left.isEmpty()?this:this.left.min_()},e.prototype.minKey=function(){return this.min_().key},e.prototype.maxKey=function(){return this.right.isEmpty()?this.key:this.right.maxKey()},e.prototype.insert=function(e,t,n){var r=this,i=n(e,r.key);return(r=i<0?r.copy(null,null,null,r.left.insert(e,t,n),null):0===i?r.copy(null,t,null,null,null):r.copy(null,null,null,null,r.right.insert(e,t,n))).fixUp_()},e.prototype.removeMin_=function(){if(this.left.isEmpty())return Re.EMPTY_NODE;var e=this;return e.left.isRed_()||e.left.left.isRed_()||(e=e.moveRedLeft_()),(e=e.copy(null,null,null,e.left.removeMin_(),null)).fixUp_()},e.prototype.remove=function(e,t){var n,r;if(t(e,(n=this).key)<0)n.left.isEmpty()||n.left.isRed_()||n.left.left.isRed_()||(n=n.moveRedLeft_()),n=n.copy(null,null,null,n.left.remove(e,t),null);else{if(n.left.isRed_()&&(n=n.rotateRight_()),n.right.isEmpty()||n.right.isRed_()||n.right.left.isRed_()||(n=n.moveRedRight_()),0===t(e,n.key)){if(n.right.isEmpty())return Re.EMPTY_NODE;r=n.right.min_(),n=n.copy(r.key,r.value,null,null,n.right.removeMin_())}n=n.copy(null,null,null,null,n.right.remove(e,t))}return n.fixUp_()},e.prototype.isRed_=function(){return this.color},e.prototype.fixUp_=function(){var e=this;return e.right.isRed_()&&!e.left.isRed_()&&(e=e.rotateLeft_()),e.left.isRed_()&&e.left.left.isRed_()&&(e=e.rotateRight_()),e.left.isRed_()&&e.right.isRed_()&&(e=e.colorFlip_()),e},e.prototype.moveRedLeft_=function(){var e=this.colorFlip_();return e.right.left.isRed_()&&(e=(e=(e=e.copy(null,null,null,null,e.right.rotateRight_())).rotateLeft_()).colorFlip_()),e},e.prototype.moveRedRight_=function(){var e=this.colorFlip_();return e.left.left.isRed_()&&(e=(e=e.rotateRight_()).colorFlip_()),e},e.prototype.rotateLeft_=function(){var t=this.copy(null,null,e.RED,null,this.right.left);return this.right.copy(null,null,this.color,t,null)},e.prototype.rotateRight_=function(){var t=this.copy(null,null,e.RED,this.left.right,null);return this.left.copy(null,null,this.color,null,t)},e.prototype.colorFlip_=function(){var e=this.left.copy(null,null,!this.left.color,null,null),t=this.right.copy(null,null,!this.right.color,null,null);return this.copy(null,null,!this.color,e,t)},e.prototype.checkMaxDepth_=function(){var e=this.check_();return Math.pow(2,e)<=this.count()+1},e.prototype.check_=function(){if(this.isRed_()&&this.left.isRed_())throw new Error("Red node has red child("+this.key+","+this.value+")");
2if(this.right.isRed_())throw new Error("Right child of ("+this.key+","+this.value+") is red");var e=this.left.check_();if(e!==this.right.check_())throw new Error("Black depths differ");return e+(this.isRed_()?0:1)},e.RED=!0,e.BLACK=!1,e}(),Ie=function(){function e(){}return e.prototype.copy=function(e,t,n,r,i){return this},e.prototype.insert=function(e,t,n){return new Pe(e,t,null)},e.prototype.remove=function(e,t){return this},e.prototype.count=function(){return 0},e.prototype.isEmpty=function(){return!0},e.prototype.inorderTraversal=function(e){return!1},e.prototype.reverseTraversal=function(e){return!1},e.prototype.minKey=function(){return null},e.prototype.maxKey=function(){return null},e.prototype.check_=function(){return 0},e.prototype.isRed_=function(){return!1},e}(),Re=function(){function e(t,n){void 0===n&&(n=e.EMPTY_NODE),this.comparator_=t,this.root_=n}return e.prototype.insert=function(t,n){return new e(this.comparator_,this.root_.insert(t,n,this.comparator_).copy(null,null,Pe.BLACK,null,null))},e.prototype.remove=function(t){return new e(this.comparator_,this.root_.remove(t,this.comparator_).copy(null,null,Pe.BLACK,null,null))},e.prototype.get=function(e){for(var t,n=this.root_;!n.isEmpty();){if(0===(t=this.comparator_(e,n.key)))return n.value;t<0?n=n.left:t>0&&(n=n.right)}return null},e.prototype.getPredecessorKey=function(e){for(var t,n=this.root_,r=null;!n.isEmpty();){if(0===(t=this.comparator_(e,n.key))){if(n.left.isEmpty())return r?r.key:null;for(n=n.left;!n.right.isEmpty();)n=n.right;return n.key}t<0?n=n.left:t>0&&(r=n,n=n.right)}throw new Error("Attempted to find predecessor key for a nonexistent key. What gives?")},e.prototype.isEmpty=function(){return this.root_.isEmpty()},e.prototype.count=function(){return this.root_.count()},e.prototype.minKey=function(){return this.root_.minKey()},e.prototype.maxKey=function(){return this.root_.maxKey()},e.prototype.inorderTraversal=function(e){return this.root_.inorderTraversal(e)},e.prototype.reverseTraversal=function(e){return this.root_.reverseTraversal(e)},e.prototype.getIterator=function(e){return new Ne(this.root_,null,this.comparator_,!1,e)},e.prototype.getIteratorFrom=function(e,t){return new Ne(this.root_,e,this.comparator_,!1,t)},e.prototype.getReverseIteratorFrom=function(e,t){return new Ne(this.root_,e,this.comparator_,!0,t)},e.prototype.getReverseIterator=function(e){return new Ne(this.root_,null,this.comparator_,!0,e)},e.EMPTY_NODE=new Ie,e}(),De=Math.log(2),je=function(){function e(e){var t;this.count=(t=e+1,parseInt(Math.log(t)/De,10)),this.current_=this.count-1;var n,r=(n=this.count,parseInt(Array(n+1).join("1"),2));this.bits_=e+1&r}return e.prototype.nextBitIsOne=function(){var e=!(this.bits_&1<<this.current_);return this.current_--,e},e}(),Le=function(e,t,n,r){e.sort(t);var i=function t(r,i){var o,a,s=i-r;if(0===s)return null;if(1===s)return o=e[r],a=n?n(o):o,new Pe(a,o.node,Pe.BLACK,null,null);var l=parseInt(s/2,10)+r,u=t(r,l),c=t(l+1,i);return o=e[l],a=n?n(o):o,new Pe(a,o.node,Pe.BLACK,u,c)},o=function(t){for(var r=null,o=null,a=e.length,s=function(t,r){var o=a-t,s=a;a-=t;var u=i(o+1,s),c=e[o],f=n?n(c):c;l(new Pe(f,c.node,r,null,u))},l=function(e){r?(r.left=e,r=e):(o=e,r=e)},u=0;u<t.count;++u){var c=t.nextBitIsOne(),f=Math.pow(2,t.count-(u+1));c?s(f,Pe.BLACK):(s(f,Pe.BLACK),s(f,Pe.RED))}return o}(new je(e.length));return new Re(r||t,o)},Ae={},Fe=function(){function e(e,t){this.indexes_=e,this.indexSet_=t}return Object.defineProperty(e,"Default",{get:function(){return Object(o.d)(Ae&&xe,"ChildrenNode.ts has not been loaded"),Te=Te||new e({".priority":Ae},{".priority":xe})},enumerable:!1,configurable:!0}),e.prototype.get=function(e){var t=Object(o.x)(this.indexes_,e);if(!t)throw new Error("No index defined for "+e);return t instanceof Re?t:null},e.prototype.hasIndex=function(e){return Object(o.h)(this.indexSet_,e.toString())},e.prototype.addIndex=function(t,n){Object(o.d)(t!==_e,"KeyIndex always exists and isn't meant to be added to the IndexMap.");for(var r,a=[],s=!1,l=n.getIterator(ve.Wrap),u=l.getNext();u;)s=s||t.isDefinedOn(u.node),a.push(u),u=l.getNext();r=s?Le(a,t.getCompare()):Ae;var c=t.toString(),f=Object(i.a)({},this.indexSet_);f[c]=t;var h=Object(i.a)({},this.indexes_);return h[c]=r,new e(h,f)},e.prototype.addToIndexes=function(t,n){var r=this;return new e(Object(o.v)(this.indexes_,(function(e,i){var a=Object(o.x)(r.indexSet_,i);if(Object(o.d)(a,"Missing index implementation for "+i),e===Ae){if(a.isDefinedOn(t.node)){for(var s=[],l=n.getIterator(ve.Wrap),u=l.getNext();u;)u.name!==t.name&&s.push(u),u=l.getNext();return s.push(t),Le(s,a.getCompare())}return Ae}var c=n.get(t.name),f=e;return c&&(f=f.remove(new ve(t.name,c))),f.insert(t,t.node)})),this.indexSet_)}
2,e.prototype.removeFromIndexes=function(t,n){return new e(Object(o.v)(this.indexes_,(function(e){if(e===Ae)return e;var r=n.get(t.name);return r?e.remove(new ve(t.name,r)):e})),this.indexSet_)},e}();function Me(e,t){return x(e.name,t.name)}function Ue(e,t){return x(e,t)}var We=function(){function e(e,t,n){this.children_=e,this.priorityNode_=t,this.indexMap_=n,this.lazyHash_=null,this.priorityNode_&&Se(this.priorityNode_),this.children_.isEmpty()&&Object(o.d)(!this.priorityNode_||this.priorityNode_.isEmpty(),"An empty node cannot have a priority")}return Object.defineProperty(e,"EMPTY_NODE",{get:function(){return ke||(ke=new e(new Re(Ue),null,Fe.Default))},enumerable:!1,configurable:!0}),e.prototype.isLeafNode=function(){return!1},e.prototype.getPriority=function(){return this.priorityNode_||ke},e.prototype.updatePriority=function(t){return this.children_.isEmpty()?this:new e(this.children_,t,this.indexMap_)},e.prototype.getImmediateChild=function(e){if(".priority"===e)return this.getPriority();var t=this.children_.get(e);return null===t?ke:t},e.prototype.getChild=function(e){var t=e.getFront();return null===t?this:this.getImmediateChild(t).getChild(e.popFront())},e.prototype.hasChild=function(e){return null!==this.children_.get(e)},e.prototype.updateImmediateChild=function(t,n){if(Object(o.d)(n,"We should always be passing snapshot nodes"),".priority"===t)return this.updatePriority(n);var r=new ve(t,n),i=void 0,a=void 0;n.isEmpty()?(i=this.children_.remove(t),a=this.indexMap_.removeFromIndexes(r,this.children_)):(i=this.children_.insert(t,n),a=this.indexMap_.addToIndexes(r,this.children_));var s=i.isEmpty()?ke:this.priorityNode_;return new e(i,s,a)},e.prototype.updateChild=function(e,t){var n=e.getFront();if(null===n)return t;Object(o.d)(".priority"!==e.getFront()||1===e.getLength(),".priority must be the last token in a path");var r=this.getImmediateChild(n).updateChild(e.popFront(),t);return this.updateImmediateChild(n,r)},e.prototype.isEmpty=function(){return this.children_.isEmpty()},e.prototype.numChildren=function(){return this.children_.count()},e.prototype.val=function(t){if(this.isEmpty())return null;var n={},r=0,i=0,o=!0;if(this.forEachChild(xe,(function(a,s){n[a]=s.val(t),r++,o&&e.INTEGER_REGEXP_.test(a)?i=Math.max(i,Number(a)):o=!1})),!t&&o&&i<2*r){var a=[];for(var s in n)a[s]=n[s];return a}return t&&!this.getPriority().isEmpty()&&(n[".priority"]=this.getPriority().val()),n},e.prototype.hash=function(){if(null===this.lazyHash_){var e="";this.getPriority().isEmpty()||(e+="priority:"+Ce(this.getPriority().val())+":"),this.forEachChild(xe,(function(t,n){var r=n.hash();""!==r&&(e+=":"+t+":"+r)})),this.lazyHash_=""===e?"":y(e)}return this.lazyHash_},e.prototype.getPredecessorChildName=function(e,t,n){var r=this.resolveIndex_(n);if(r){var i=r.getPredecessorKey(new ve(e,t));return i?i.name:null}return this.children_.getPredecessorKey(e)},e.prototype.getFirstChildName=function(e){var t=this.resolveIndex_(e);if(t){var n=t.minKey();return n&&n.name}return this.children_.minKey()},e.prototype.getFirstChild=function(e){var t=this.getFirstChildName(e);return t?new ve(t,this.children_.get(t)):null},e.prototype.getLastChildName=function(e){var t=this.resolveIndex_(e);if(t){var n=t.maxKey();return n&&n.name}return this.children_.maxKey()},e.prototype.getLastChild=function(e){var t=this.getLastChildName(e);return t?new ve(t,this.children_.get(t)):null},e.prototype.forEachChild=function(e,t){var n=this.resolveIndex_(e);return n?n.inorderTraversal((function(e){return t(e.name,e.node)})):this.children_.inorderTraversal(t)},e.prototype.getIterator=function(e){return this.getIteratorFrom(e.minPost(),e)},e.prototype.getIteratorFrom=function(e,t){var n=this.resolveIndex_(t);if(n)return n.getIteratorFrom(e,(function(e){return e}));for(var r=this.children_.getIteratorFrom(e.name,ve.Wrap),i=r.peek();null!=i&&t.compare(i,e)<0;)r.getNext(),i=r.peek();return r},e.prototype.getReverseIterator=function(e){return this.getReverseIteratorFrom(e.maxPost(),e)},e.prototype.getReverseIteratorFrom=function(e,t){var n=this.resolveIndex_(t);if(n)return n.getReverseIteratorFrom(e,(function(e){return e}));for(var r=this.children_.getReverseIteratorFrom(e.name,ve.Wrap),i=r.peek();null!=i&&t.compare(i,e)>0;)r.getNext(),i=r.peek();return r},e.prototype.compareTo=function(e){return this.isEmpty()?e.isEmpty()?0:-1:e.isLeafNode()||e.isEmpty()?1:e===ze?-1:0},e.prototype.withIndex=function(t){if(t===_e||this.indexMap_.hasIndex(t))return this;var n=this.indexMap_.addIndex(t,this.children_);return new e(this.children_,this.priorityNode_,n)},e.prototype.isIndexed=function(e){return e===_e||this.indexMap_.hasIndex(e)},e.prototype.equals=function(e){if(e===this)return!0;
2if(e.isLeafNode())return!1;var t=e;if(this.getPriority().equals(t.getPriority())){if(this.children_.count()===t.children_.count()){for(var n=this.getIterator(xe),r=t.getIterator(xe),i=n.getNext(),o=r.getNext();i&&o;){if(i.name!==o.name||!i.node.equals(o.node))return!1;i=n.getNext(),o=r.getNext()}return null===i&&null===o}return!1}return!1},e.prototype.resolveIndex_=function(e){return e===_e?null:this.indexMap_.get(e.toString())},e.INTEGER_REGEXP_=/^(0|[1-9]\d*)$/,e}(),ze=new(function(e){function t(){return e.call(this,new Re(Ue),We.EMPTY_NODE,Fe.Default)||this}return Object(i.c)(t,e),t.prototype.compareTo=function(e){return e===this?0:1},t.prototype.equals=function(e){return e===this},t.prototype.getPriority=function(){return this},t.prototype.getImmediateChild=function(e){return We.EMPTY_NODE},t.prototype.isEmpty=function(){return!1},t}(We));Object.defineProperties(ve,{MIN:{value:new ve(T,We.EMPTY_NODE)},MAX:{value:new ve(k,ze)}}),me.__EMPTY_NODE=We.EMPTY_NODE,Oe.__childrenNodeConstructor=We,K=ze,function(e){Ee=e}(ze);function Be(e,t){if(void 0===t&&(t=null),null===e)return We.EMPTY_NODE;if("object"===typeof e&&".priority"in e&&(t=e[".priority"]),Object(o.d)(null===t||"string"===typeof t||"number"===typeof t||"object"===typeof t&&".sv"in t,"Invalid priority type found: "+typeof t),"object"===typeof e&&".value"in e&&null!==e[".value"]&&(e=e[".value"]),"object"!==typeof e||".sv"in e)return new Oe(e,Be(t));if(e instanceof Array){var n=We.EMPTY_NODE;return D(e,(function(t,r){if(Object(o.h)(e,t)&&"."!==t.substring(0,1)){var i=Be(r);!i.isLeafNode()&&i.isEmpty()||(n=n.updateImmediateChild(t,i))}})),n.updatePriority(Be(t))}var r=[],i=!1;if(D(e,(function(e,t){if("."!==e.substring(0,1)){var n=Be(t);n.isEmpty()||(i=i||!n.getPriority().isEmpty(),r.push(new ve(e,n)))}})),0===r.length)return We.EMPTY_NODE;var a=Le(r,Me,(function(e){return e.name}),Ue);if(i){var s=Le(r,xe.getCompare());return new We(a,Be(t),new Fe({".priority":s},{".priority":xe}))}return new We(a,Be(t),Fe.Default)}!function(e){we=e}(Be);var qe,Ve=new(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(i.c)(t,e),t.prototype.compare=function(e,t){var n=e.node.compareTo(t.node);return 0===n?x(e.name,t.name):n},t.prototype.isDefinedOn=function(e){return!0},t.prototype.indexedValueChanged=function(e,t){return!e.equals(t)},t.prototype.minPost=function(){return ve.MIN},t.prototype.maxPost=function(){return ve.MAX},t.prototype.makePost=function(e,t){var n=Be(e);return new ve(t,n)},t.prototype.toString=function(){return".value"},t}(ge)),Qe=function(e){function t(t){var n=e.call(this)||this;return n.indexPath_=t,Object(o.d)(!t.isEmpty()&&".priority"!==t.getFront(),"Can't create PathIndex with empty path or .priority key"),n}return Object(i.c)(t,e),t.prototype.extractChild=function(e){return e.getChild(this.indexPath_)},t.prototype.isDefinedOn=function(e){return!e.getChild(this.indexPath_).isEmpty()},t.prototype.compare=function(e,t){var n=this.extractChild(e.node),r=this.extractChild(t.node),i=n.compareTo(r);return 0===i?x(e.name,t.name):i},t.prototype.makePost=function(e,t){var n=Be(e),r=We.EMPTY_NODE.updateChild(this.indexPath_,n);return new ve(t,r)},t.prototype.maxPost=function(){var e=We.EMPTY_NODE.updateChild(this.indexPath_,ze);return new ve(k,e)},t.prototype.toString=function(){return this.indexPath_.slice().join("/")},t}(ge),He=function(){function e(e,t,n){this.node_=e,this.ref_=t,this.index_=n}return e.prototype.val=function(){return Object(o.B)("DataSnapshot.val",0,0,arguments.length),this.node_.val()},e.prototype.exportVal=function(){return Object(o.B)("DataSnapshot.exportVal",0,0,arguments.length),this.node_.val(!0)},e.prototype.toJSON=function(){return Object(o.B)("DataSnapshot.toJSON",0,1,arguments.length),this.exportVal()},e.prototype.exists=function(){return Object(o.B)("DataSnapshot.exists",0,0,arguments.length),!this.node_.isEmpty()},e.prototype.child=function(t){Object(o.B)("DataSnapshot.child",0,1,arguments.length),t=String(t),le("DataSnapshot.child",1,t,!1);var n=new U(t),r=this.ref_.child(n);return new e(this.node_.getChild(n),r,xe)},e.prototype.hasChild=function(e){Object(o.B)("DataSnapshot.hasChild",1,1,arguments.length),le("DataSnapshot.hasChild",1,e,!1);var t=new U(e);return!this.node_.getChild(t).isEmpty()},e.prototype.getPriority=function(){return Object(o.B)("DataSnapshot.getPriority",0,0,arguments.length),this.node_.getPriority().val()},e.prototype.forEach=function(t){var n=this;if(Object(o.B)("DataSnapshot.forEach",1,1,arguments.length),Object(o.C)("DataSnapshot.forEach",1,t,!1),this.node_.isLeafNode())return!1;var r=this.node_;return!!r.forEachChild(this.index_,(function(r,i){return t(new e(i,n.ref_.child(r),xe))}))},e.prototype.hasChildren=function(){return Object(o.B)("DataSnapshot.hasChildren",0,0,arguments.length),!this.node_.isLeafNode()&&!this.node_.isEmpty()},Object.defineProperty(e.prototype,"key",{get:function(){return this.ref_.getKey()}
2,enumerable:!1,configurable:!0}),e.prototype.numChildren=function(){return Object(o.B)("DataSnapshot.numChildren",0,0,arguments.length),this.node_.numChildren()},e.prototype.getRef=function(){return Object(o.B)("DataSnapshot.ref",0,0,arguments.length),this.ref_},Object.defineProperty(e.prototype,"ref",{get:function(){return this.getRef()},enumerable:!1,configurable:!0}),e}(),Ke=function(){function e(e,t,n,r){this.eventType=e,this.eventRegistration=t,this.snapshot=n,this.prevName=r}return e.prototype.getPath=function(){var e=this.snapshot.getRef();return"value"===this.eventType?e.path:e.getParent().path},e.prototype.getEventType=function(){return this.eventType},e.prototype.getEventRunner=function(){return this.eventRegistration.getEventRunner(this)},e.prototype.toString=function(){return this.getPath().toString()+":"+this.eventType+":"+Object(o.A)(this.snapshot.exportVal())},e}(),Ye=function(){function e(e,t,n){this.eventRegistration=e,this.error=t,this.path=n}return e.prototype.getPath=function(){return this.path},e.prototype.getEventType=function(){return"cancel"},e.prototype.getEventRunner=function(){return this.eventRegistration.getEventRunner(this)},e.prototype.toString=function(){return this.path.toString()+":cancel"},e}(),$e=function(){function e(e,t,n){this.callback_=e,this.cancelCallback_=t,this.context_=n}return e.prototype.respondsTo=function(e){return"value"===e},e.prototype.createEvent=function(e,t){var n=t.getQueryParams().getIndex();return new Ke("value",this,new He(e.snapshotNode,t.getRef(),n))},e.prototype.getEventRunner=function(e){var t=this.context_;if("cancel"===e.getEventType()){Object(o.d)(this.cancelCallback_,"Raising a cancel event on a listener with no cancel callback");var n=this.cancelCallback_;return function(){n.call(t,e.error)}}var r=this.callback_;return function(){r.call(t,e.snapshot)}},e.prototype.createCancelEvent=function(e,t){return this.cancelCallback_?new Ye(this,e,t):null},e.prototype.matches=function(t){return t instanceof e&&(!t.callback_||!this.callback_||t.callback_===this.callback_&&t.context_===this.context_)},e.prototype.hasAnyCallback=function(){return null!==this.callback_},e}(),Ge=function(){function e(e,t,n){this.callbacks_=e,this.cancelCallback_=t,this.context_=n}return e.prototype.respondsTo=function(e){var t="children_added"===e?"child_added":e;return t="children_removed"===t?"child_removed":t,Object(o.h)(this.callbacks_,t)},e.prototype.createCancelEvent=function(e,t){return this.cancelCallback_?new Ye(this,e,t):null},e.prototype.createEvent=function(e,t){Object(o.d)(null!=e.childName,"Child events should have a childName.");var n=t.getRef().child(e.childName),r=t.getQueryParams().getIndex();return new Ke(e.type,this,new He(e.snapshotNode,n,r),e.prevName)},e.prototype.getEventRunner=function(e){var t=this.context_;if("cancel"===e.getEventType()){Object(o.d)(this.cancelCallback_,"Raising a cancel event on a listener with no cancel callback");var n=this.cancelCallback_;return function(){n.call(t,e.error)}}var r=this.callbacks_[e.eventType];return function(){r.call(t,e.snapshot,e.prevName)}},e.prototype.matches=function(t){var n=this;if(t instanceof e){if(!this.callbacks_||!t.callbacks_)return!0;if(this.context_===t.context_){var r=Object.keys(t.callbacks_),i=Object.keys(this.callbacks_),o=r.length;if(o===i.length){if(1===o){var a=r[0],s=i[0];return s===a&&(!t.callbacks_[a]||!this.callbacks_[s]||t.callbacks_[a]===this.callbacks_[s])}return i.every((function(e){return t.callbacks_[e]===n.callbacks_[e]}))}}}return!1},e.prototype.hasAnyCallback=function(){return null!==this.callbacks_},e}(),Xe=function(){function e(e,t,n,r){this.repo=e,this.path=t,this.queryParams_=n,this.orderByCalled_=r}return Object.defineProperty(e,"__referenceConstructor",{get:function(){return Object(o.d)(qe,"Reference.ts has not been loaded"),qe},set:function(e){qe=e},enumerable:!1,configurable:!0}),e.validateQueryEndpoints_=function(e){var t=null,n=null;if(e.hasStart()&&(t=e.getIndexStartValue()),e.hasEnd()&&(n=e.getIndexEndValue()),e.getIndex()===_e){var r="Query: When ordering by key, you may only pass one argument to startAt(), endAt(), or equalTo().",i="Query: When ordering by key, the argument passed to startAt(), endAt(),or equalTo() must be a string.";if(e.hasStart()){if(e.getIndexStartName()!==T)throw new Error(r);if("string"!==typeof t)throw new Error(i)}if(e.hasEnd()){if(e.getIndexEndName()!==k)throw new Error(r);if("string"!==typeof n)throw new Error(i)}}else if(e.getIndex()===xe){if(null!=t&&!te(t)||null!=n&&!te(n))throw new Error("Query: When ordering by priority, the first argument passed to startAt(), endAt(), or equalTo() must be a valid priority value (null, a number, or a string).")}else if(Object(o.d)(e.getIndex()instanceof Qe||e.getIndex()===Ve,"unknown index type."),null!=t&&"object"===typeof t||null!=n&&"object"===typeof n)throw new Error("Query: First argument passed to startAt(), endAt(), or equalTo() cannot be an object.")},e.validateLimit_=function(e){if(e.hasStart()&&e.hasEnd()&&e.hasLimit()&&!e.hasAnchoredLimit())throw new Error("Query: Can't combine startAt(), endAt(), and limit(). Use limitToFirst() or limitToLast() instead.")},e.prototype.validateNoPreviousOrderByCall_=function(e){if(!0===this.orderByCalled_)throw new Error(e+": You can't combine multiple orderBy calls.")},e.prototype.getQueryParams=function(){return this.queryParams_},e.prototype.getRef=function(){return Object(o.B)("Query.ref",0,0,arguments.length),new e.__referenceConstructor(this.repo,this.path)},e.prototype.on=function(t,n,r,i){Object(o.B)("Query.on",2,4,arguments.length),ae("Query.on",1,t,!1),Object(o.C)("Query.on",2,n,!1);var a=e.getCancelAndContextArgs_("Query.on",r,i);if("value"===t)this.onValueEvent(n,a.cancel,a.context);else{var s={};s[t]=n,this.onChildEvent(s,a.cancel,a.context)}return n},e.prototype.onValueEvent=function(e,t,n){var r=new $e(e,t||null,n||null);this.repo.addEventCallbackForQuery(this,r)},e.prototype.onChildEvent=function(e,t,n){var r=new Ge(e,t,n);this.repo.addEventCallbackForQuery(this,r)},e.prototype.off=function(e,t,n){Object(o.B)("Query.off",0,3,arguments.length),ae("Query.off",1,e,!0),Object(o.C)("Query.off",2,t,!0),Object(o.D)("Query.off",3,n,!0);var r=null,i=null;if("value"===e){var a=t||null;r=new $e(a,null,n||null)}else e&&(t&&((i={}
2)[e]=t),r=new Ge(i,null,n||null));this.repo.removeEventCallbackForQuery(this,r)},e.prototype.get=function(){return this.repo.getValue(this)},e.prototype.once=function(t,n,r,i){var a=this;Object(o.B)("Query.once",1,4,arguments.length),ae("Query.once",1,t,!1),Object(o.C)("Query.once",2,n,!0);var s=e.getCancelAndContextArgs_("Query.once",r,i),l=!0,u=new o.a;u.promise.catch((function(){}));var c=function e(r){l&&(l=!1,a.off(t,e),n&&n.bind(s.context)(r),u.resolve(r))};return this.on(t,c,(function(e){a.off(t,c),s.cancel&&s.cancel.bind(s.context)(e),u.reject(e)})),u.promise},e.prototype.limitToFirst=function(t){if(Object(o.B)("Query.limitToFirst",1,1,arguments.length),"number"!==typeof t||Math.floor(t)!==t||t<=0)throw new Error("Query.limitToFirst: First argument must be a positive integer.");if(this.queryParams_.hasLimit())throw new Error("Query.limitToFirst: Limit was already set (by another call to limit, limitToFirst, or limitToLast).");return new e(this.repo,this.path,this.queryParams_.limitToFirst(t),this.orderByCalled_)},e.prototype.limitToLast=function(t){if(Object(o.B)("Query.limitToLast",1,1,arguments.length),"number"!==typeof t||Math.floor(t)!==t||t<=0)throw new Error("Query.limitToLast: First argument must be a positive integer.");if(this.queryParams_.hasLimit())throw new Error("Query.limitToLast: Limit was already set (by another call to limit, limitToFirst, or limitToLast).");return new e(this.repo,this.path,this.queryParams_.limitToLast(t),this.orderByCalled_)},e.prototype.orderByChild=function(t){if(Object(o.B)("Query.orderByChild",1,1,arguments.length),"$key"===t)throw new Error('Query.orderByChild: "$key" is invalid. Use Query.orderByKey() instead.');if("$priority"===t)throw new Error('Query.orderByChild: "$priority" is invalid. Use Query.orderByPriority() instead.');if("$value"===t)throw new Error('Query.orderByChild: "$value" is invalid. Use Query.orderByValue() instead.');le("Query.orderByChild",1,t,!1),this.validateNoPreviousOrderByCall_("Query.orderByChild");var n=new U(t);if(n.isEmpty())throw new Error("Query.orderByChild: cannot pass in empty path. Use Query.orderByValue() instead.");var r=new Qe(n),i=this.queryParams_.orderBy(r);return e.validateQueryEndpoints_(i),new e(this.repo,this.path,i,!0)},e.prototype.orderByKey=function(){Object(o.B)("Query.orderByKey",0,0,arguments.length),this.validateNoPreviousOrderByCall_("Query.orderByKey");var t=this.queryParams_.orderBy(_e);return e.validateQueryEndpoints_(t),new e(this.repo,this.path,t,!0)},e.prototype.orderByPriority=function(){Object(o.B)("Query.orderByPriority",0,0,arguments.length),this.validateNoPreviousOrderByCall_("Query.orderByPriority");var t=this.queryParams_.orderBy(xe);return e.validateQueryEndpoints_(t),new e(this.repo,this.path,t,!0)},e.prototype.orderByValue=function(){Object(o.B)("Query.orderByValue",0,0,arguments.length),this.validateNoPreviousOrderByCall_("Query.orderByValue");var t=this.queryParams_.orderBy(Ve);return e.validateQueryEndpoints_(t),new e(this.repo,this.path,t,!0)},e.prototype.startAt=function(t,n){void 0===t&&(t=null),Object(o.B)("Query.startAt",0,2,arguments.length),ne("Query.startAt",1,t,this.path,!0),se("Query.startAt",2,n,!0);var r=this.queryParams_.startAt(t,n);if(e.validateLimit_(r),e.validateQueryEndpoints_(r),this.queryParams_.hasStart())throw new Error("Query.startAt: Starting point was already set (by another call to startAt or equalTo).");return void 0===t&&(t=null,n=null),new e(this.repo,this.path,r,this.orderByCalled_)},e.prototype.endAt=function(t,n){void 0===t&&(t=null),Object(o.B)("Query.endAt",0,2,arguments.length),ne("Query.endAt",1,t,this.path,!0),se("Query.endAt",2,n,!0);var r=this.queryParams_.endAt(t,n);if(e.validateLimit_(r),e.validateQueryEndpoints_(r),this.queryParams_.hasEnd())throw new Error("Query.endAt: Ending point was already set (by another call to endAt or equalTo).");return new e(this.repo,this.path,r,this.orderByCalled_)},e.prototype.equalTo=function(e,t){if(Object(o.B)("Query.equalTo",1,2,arguments.length),ne("Query.equalTo",1,e,this.path,!1),se("Query.equalTo",2,t,!0),this.queryParams_.hasStart())throw new Error("Query.equalTo: Starting point was already set
2(by another call to startAt or equalTo).");if(this.queryParams_.hasEnd())throw new Error("Query.equalTo: Ending point was already set (by another call to endAt or equalTo).");return this.startAt(e,t).endAt(e,t)},e.prototype.toString=function(){return Object(o.B)("Query.toString",0,0,arguments.length),this.repo.toString()+this.path.toUrlEncodedString()},e.prototype.toJSON=function(){return Object(o.B)("Query.toJSON",0,1,arguments.length),this.toString()},e.prototype.queryObject=function(){return this.queryParams_.getQueryObject()},e.prototype.queryIdentifier=function(){var e=this.queryObject(),t=I(e);return"{}"===t?"default":t},e.prototype.isEqual=function(t){if(Object(o.B)("Query.isEqual",1,1,arguments.length),!(t instanceof e)){var n="Query.isEqual failed: First argument must be an instance of firebase.database.Query.";throw new Error(n)}var r=this.repo===t.repo,i=this.path.equals(t.path),a=this.queryIdentifier()===t.queryIdentifier();return r&&i&&a},e.getCancelAndContextArgs_=function(e,t,n){var r={cancel:null,context:null};if(t&&n)r.cancel=t,Object(o.C)(e,3,r.cancel,!0),r.context=n,Object(o.D)(e,4,r.context,!0);else if(t)if("object"===typeof t&&null!==t)r.context=t;else{if("function"!==typeof t)throw new Error(Object(o.l)(e,3,!0)+" must either be a cancel callback or a context object.");r.cancel=t}return r},Object.defineProperty(e.prototype,"ref",{get:function(){return this.getRef()},enumerable:!1,configurable:!0}),e}(),Je=function(){function e(e){this.node_=e}return e.prototype.getImmediateChild=function(t){return new e(this.node_.getImmediateChild(t))},e.prototype.node=function(){return this.node_},e}(),Ze=function(){function e(e,t){this.syncTree_=e,this.path_=t}return e.prototype.getImmediateChild=function(t){var n=this.path_.child(t);return new e(this.syncTree_,n)},e.prototype.node=function(){return this.syncTree_.calcCompleteEventCache(this.path_)},e}(),et=function(e,t,n){return e&&"object"===typeof e?(Object(o.d)(".sv"in e,"Unexpected leaf node or priority contents"),"string"===typeof e[".sv"]?tt(e[".sv"],t,n):"object"===typeof e[".sv"]?nt(e[".sv"],t):void Object(o.d)(!1,"Unexpected server value: "+JSON.stringify(e,null,2))):e},tt=function(e,t,n){switch(e){case"timestamp":return n.timestamp;default:Object(o.d)(!1,"Unexpected server value: "+e)}},nt=function(e,t,n){e.hasOwnProperty("increment")||Object(o.d)(!1,"Unexpected server value: "+JSON.stringify(e,null,2));var r=e.increment;"number"!==typeof r&&Object(o.d)(!1,"Unexpected increment value: "+r);var i=t.node();if(Object(o.d)(null!==i&&"undefined"!==typeof i,"Expected ChildrenNode.EMPTY_NODE for nulls"),!i.isLeafNode())return r;var a=i.getValue();return"number"!==typeof a?r:a+r},rt=function(e,t,n,r){return ot(t,new Ze(n,e),r)},it=function(e,t,n){return ot(e,new Je(t),n)};function ot(e,t,n){var r,i=e.getPriority().val(),o=et(i,t.getImmediateChild(".priority"),n);if(e.isLeafNode()){var a=e,s=et(a.getValue(),t,n);return s!==a.getValue()||o!==a.getPriority().val()?new Oe(s,Be(o)):e}var l=e;return r=l,o!==l.getPriority().val()&&(r=r.updatePriority(new Oe(o))),l.forEachChild(xe,(function(e,i){var o=ot(i,t.getImmediateChild(e),n);o!==i&&(r=r.updateImmediateChild(e,o))})),r}var at,st=function(){function e(){this.value=null,this.children=new Map}return e.prototype.find=function(e){if(null!=this.value)return this.value.getChild(e);if(!e.isEmpty()&&this.children.size>0){var t=e.getFront();return e=e.popFront(),this.children.has(t)?this.children.get(t).find(e):null}return null},e.prototype.remember=function(t,n){if(t.isEmpty())this.value=n,this.children.clear();else if(null!==this.value)this.value=this.value.updateChild(t,n);else{var r=t.getFront();this.children.has(r)||this.children.set(r,new e);var i=this.children.get(r);t=t.popFront(),i.remember(t,n)}},e.prototype.forget=function(e){if(e.isEmpty())return this.value=null,this.children.clear(),!0;if(null!==this.value){if(this.value.isLeafNode())return!1;var t=this.value;this.value=null;var n=this;return t.forEachChild(xe,(function(e,t){n.remember(new U(e),t)})),this.forget(e)}if(this.children.size>0){var r=e.getFront();if(e=e.popFront(),this.children.has(r))this.children.get(r).forget(e)&&this.children.delete(r);return 0===this.children.size}return!0},e.prototype.forEachTree=function(e,t){null!==this.value?t(e,this.value):this.forEachChild((function(n,r){var i=new U(e.toString()+"/"+n);r.forEachTree(i,t)}))}
2,e.prototype.forEachChild=function(e){this.children.forEach((function(t,n){e(n,t)}))},e}();!function(e){e[e.OVERWRITE=0]="OVERWRITE",e[e.MERGE=1]="MERGE",e[e.ACK_USER_WRITE=2]="ACK_USER_WRITE",e[e.LISTEN_COMPLETE=3]="LISTEN_COMPLETE"}(at||(at={}));var lt,ut,ct=function(){function e(e,t,n,r){this.fromUser=e,this.fromServer=t,this.queryId=n,this.tagged=r,Object(o.d)(!r||t,"Tagged queries must be from server.")}return e.User=new e(!0,!1,null,!1),e.Server=new e(!1,!0,null,!1),e.forServerTaggedQuery=function(t){return new e(!1,!0,t,!0)},e}(),ft=function(){function e(e,t,n){this.path=e,this.affectedTree=t,this.revert=n,this.type=at.ACK_USER_WRITE,this.source=ct.User}return e.prototype.operationForChild=function(t){if(this.path.isEmpty()){if(null!=this.affectedTree.value)return Object(o.d)(this.affectedTree.children.isEmpty(),"affectedTree should not have overlapping affected paths."),this;var n=this.affectedTree.subtree(new U(t));return new e(U.Empty,n,this.revert)}return Object(o.d)(this.path.getFront()===t,"operationForChild called for unrelated child."),new e(this.path.popFront(),this.affectedTree,this.revert)},e}(),ht=function(){function e(e,t){void 0===t&&(lt||(lt=new Re(N)),t=lt),this.value=e,this.children=t}return e.fromObject=function(t){var n=e.Empty;return D(t,(function(e,t){n=n.set(new U(e),t)})),n},e.prototype.isEmpty=function(){return null===this.value&&this.children.isEmpty()},e.prototype.findRootMostMatchingPathAndValue=function(e,t){if(null!=this.value&&t(this.value))return{path:U.Empty,value:this.value};if(e.isEmpty())return null;var n=e.getFront(),r=this.children.get(n);if(null!==r){var i=r.findRootMostMatchingPathAndValue(e.popFront(),t);return null!=i?{path:new U(n).child(i.path),value:i.value}:null}return null},e.prototype.findRootMostValueAndPath=function(e){return this.findRootMostMatchingPathAndValue(e,(function(){return!0}))},e.prototype.subtree=function(t){if(t.isEmpty())return this;var n=t.getFront(),r=this.children.get(n);return null!==r?r.subtree(t.popFront()):e.Empty},e.prototype.set=function(t,n){if(t.isEmpty())return new e(n,this.children);var r=t.getFront(),i=(this.children.get(r)||e.Empty).set(t.popFront(),n),o=this.children.insert(r,i);return new e(this.value,o)},e.prototype.remove=function(t){if(t.isEmpty())return this.children.isEmpty()?e.Empty:new e(null,this.children);var n=t.getFront(),r=this.children.get(n);if(r){var i=r.remove(t.popFront()),o=void 0;return o=i.isEmpty()?this.children.remove(n):this.children.insert(n,i),null===this.value&&o.isEmpty()?e.Empty:new e(this.value,o)}return this},e.prototype.get=function(e){if(e.isEmpty())return this.value;var t=e.getFront(),n=this.children.get(t);return n?n.get(e.popFront()):null},e.prototype.setTree=function(t,n){if(t.isEmpty())return n;var r=t.getFront(),i=(this.children.get(r)||e.Empty).setTree(t.popFront(),n),o=void 0;return o=i.isEmpty()?this.children.remove(r):this.children.insert(r,i),new e(this.value,o)},e.prototype.fold=function(e){return this.fold_(U.Empty,e)},e.prototype.fold_=function(e,t){var n={};return this.children.inorderTraversal((function(r,i){n[r]=i.fold_(e.child(r),t)})),t(e,this.value,n)},e.prototype.findOnPath=function(e,t){return this.findOnPath_(e,U.Empty,t)},e.prototype.findOnPath_=function(e,t,n){var r=!!this.value&&n(t,this.value);if(r)return r;if(e.isEmpty())return null;var i=e.getFront(),o=this.children.get(i);return o?o.findOnPath_(e.popFront(),t.child(i),n):null},e.prototype.foreachOnPath=function(e,t){return this.foreachOnPath_(e,U.Empty,t)},e.prototype.foreachOnPath_=function(t,n,r){if(t.isEmpty())return this;this.value&&r(n,this.value);var i=t.getFront(),o=this.children.get(i);return o?o.foreachOnPath_(t.popFront(),n.child(i),r):e.Empty},e.prototype.foreach=function(e){this.foreach_(U.Empty,e)},e.prototype.foreach_=function(e,t){this.children.inorderTraversal((function(n,r){r.foreach_(e.child(n),t)})),this.value&&t(e,this.value)},e.prototype.foreachChild=function(e){this.children.inorderTraversal((function(t,n){n.value&&e(t,n.value)}))},e.Empty=new e(null),e}(),dt=function(){function e(e,t){this.source=e,this.path=t,this.type=at.LISTEN_COMPLETE}return e.prototype.operationForChild=function(t){return this.path.isEmpty()?new e(this.source,U.Empty):new e(this.source,this.path.popFront())},e}(),pt=function(){function e(e,t,n){this.source=e,this.path=t,this.snap=n,this.type=at.OVERWRITE}return e.prototype.operationForChild=function(t){return this.path.isEmpty()?new e(this.source,U.Empty,this.snap.getImmediateChild(t)):new e(this.source,this.path.popFront(),this.snap)},e}(),yt=function(){function e(e,t,n){this.source=e,this.path=t,this.children=n,this.type=at.MERGE}return e.prototype.operationForChild=function(t){if(this.path.isEmpty()){var n=this.children.subtree(new U(t));return n.isEmpty()?null:n.value?new pt(this.source,U.Empty,n.value):new e(this.source,U.Empty,n)}return Object(o.d)(this.path.getFront()===t,"Can't get a merge for a child not on the path of the operation"),new e(this.source,this.path.popFront(),this.children)},e.prototype.toString=function(){return"Operation("+this.path+": "+this.source.toString()+" merge: "+this.children.toString()+")"},e}(),vt=function(){function e(e,t,n){this.node_=e,this.fullyInitialized_=t,this.filtered_=n}return e.prototype.isFullyInitialized=function(){return this.fullyInitialized_},e.prototype.isFiltered=function(){return this.filtered_},e.prototype.isCompleteForPath=function(e){if(e.isEmpty())return this.isFullyInitialized()&&!this.filtered_;var t=e.getFront();return this.isCompleteForChild(t)},e.prototype.isCompleteForChild=function(e){return this.isFullyInitialized()&&!this.filtered_||this.node_.hasChild(e)},e.prototype.getNode=function(){return this.node_},e}(),gt=function(){function e(e,t){this.eventCache_=e,this.serverCache_=t}return e.prototype.updateEventSnap=function(t,n,r){return new e(new vt(t,n,r),this.serverCache_)},e.prototype.updateServerSnap=function(t,n,r){return new e(this.eventCache_,new vt(t,n,r))},e.prototype.getEventCache=function(){return this.eventCache_},e.prototype.getCompleteEventSnap=function(){return this.eventCache_.isFullyInitialized()?this.eventCache_.getNode():null},e.prototype.getServerCache=function(){return this.serverCache_},e.prototype.getCompleteServerSnap=function(){return this.serverCache_.isFullyInitialized()?this.serverCache_.getNode():null},e.Empty=new e(new vt(We.EMPTY_NODE,!1,!1),new vt(We.EMPTY_NODE,!1,!1)),e}(),mt=function(){function e(e,t,n,r,i){this.type=e,this.snapshotNode=t,this.childName=n,this.oldSnap=r,this.prevName=i}return e.valueChange=function(t){return new e(e.VALUE,t)},e.childAddedChange=function(t,n){return new e(e.CHILD_ADDED,n,t)},e.childRemovedChange=function(t,n){return new e(e.CHILD_REMOVED,n,t)},e.childChangedChange=function(t,n,r){return new e(e.CHILD_CHANGED,n,t,r)},e.childMovedChange=function(t,n){return new e(e.CHILD_MOVED,n,t)},e.CHILD_ADDED="child_added",e.CHILD_REMOVED="child_removed",e.CHILD_CHANGED="child_changed",e.CHILD_MOVED="child_moved",e.VALUE="value",e}(),_t=function(){function e(e){this.index_=e}return e.prototype.updateChild=function(e,t,n,r,i,a){Object(o.d)(e.isIndexed(this.index_),"A node must be indexed if only a child is updated");var s=e.getImmediateChild(t);return s.getChild(r).equals(n.getChild(r))&&s.isEmpty()===n.isEmpty()?e:(null!=a&&(n.isEmpty()?e.hasChild(t)?a.trackChildChange(mt.childRemovedChange(t,s)):Object(o.d)(e.isLeafNode(),"A child remove without an old child only makes sense on a leaf node"):s.isEmpty()?a.trackChildChange(mt.childAddedChange(t,n)):a.trackChildChange(mt.childChangedChange(t,n,s))),e.isLeafNode()&&n.isEmpty()?e:e.updateImmediateChild(t,n).withIndex(this.index_))},e.prototype.updateFullNode=function(e,t,n){return null!=n&&(e.isLeafNode()||e.forEachChild(xe,(function(e,r){t.hasChild(e)||n.trackChildChange(mt.childRemovedChange(e,r))})),t.isLeafNode()||t.forEachChild(xe,(function(t,r){if(e.hasChild(t)){var i=e.getImmediateChild(t);i.equals(r)||n.trackChildChange(mt.childChangedChange(t,r,i))}else n.trackChildChange(mt.childAddedChange(t,r))}))),t.withIndex(this.index_)},e.prototype.updatePriority=function(e,t){return e.isEmpty()?We.EMPTY_NODE:e.updatePriority(t)},e.prototype.filtersNodes=function(){return!1},e.prototype.getIndexedFilter=function(){return this},e.prototype.getIndex=function(){return this.index_},e}(),bt=function(){function e(){this.changeMap=new Map}return e.prototype.trackChildChange=function(e){var t=e.type,n=e.childName;Object(o.d)(t===mt.CHILD_ADDED||t===mt.CHILD_CHANGED||t===mt.CHILD_REMOVED,"Only child changes supported for tracking"),Object(o.d)(".priority"!==n,"Only non-priority child changes can be tracked.");var r=this.changeMap.get(n);if(r){var i=r.type;if(t===mt.CHILD_ADDED&&i===mt.CHILD_REMOVED)this.changeMap.set(n,mt.childChangedChange(n,e.snapshotNode,r.snapshotNode));else if(t===mt.CHILD_REMOVED&&i===mt.CHILD_ADDED)this.changeMap.delete(n);else if(t===mt.CHILD_REMOVED&&i===mt.CHILD_CHANGED)this.changeMap.set(n,mt.childRemovedChange(n,r.oldSnap));else if(t===mt.CHILD_CHANGED&&i===mt.CHILD_ADDED)this.changeMap.set(n,mt.childAddedChange(n,e.snapshotNode));else{if(t!==mt.CHILD_CHANGED||i!==mt.CHILD_CHANGED)throw Object(o.e)("Illegal combination of changes: "+e+" occurred after "+r);this.changeMap.set(n,mt.childChangedChange(n,e.snapshotNode,r.oldSnap))}}else this.changeMap.set(n,e)},e.prototype.getChanges=function(){return Array.from(this.changeMap.values())},e}(),wt=new(function(){function e(){}return e.prototype.getCompleteChild=function(e){return null},e.prototype.getChildAfterChild=function(e,t,n){return null},e}()),Et=function(){function e(e,t,n){void 0===n&&(n=null),this.writes_=e,this.viewCache_=t,this.optCompleteServerCache_=n}return e.prototype.getCompleteChild=function(e){var t=this.viewCache_.getEventCache();if(t.isCompleteForChild(e))return t.getNode().getImmediateChild(e);var n=null!=this.optCompleteServerCache_?new vt(this.optCompleteServerCache_,!0,!1):this.viewCache_.getServerCache();return this.writes_.calcCompleteChild(e,n)},e.prototype.getChildAfterChild=function(e,t,n){var r=null!=this.optCompleteServerCache_?this.optCompleteServerCache_:this.viewCache_.getCompleteServerSnap(),i=this.writes_.calcIndexedSlice(r,t,1,n,e);return 0===i.length?null:i[0]},e}(),Ct=function(e,t){this.viewCache=e,this.changes=t},St=function(){function e(e){this.filter_=e}return e.prototype.assertIndexed=function(e){Object(o.d)(e.getEventCache().getNode().isIndexed(this.filter_.getIndex()),"Event snap not indexed"),Object(o.d)(e.getServerCache().getNode().isIndexed(this.filter_.getIndex()),"Server snap not indexed")},e.prototype.applyOperation=function(t,n,r,i){var a,s,l=new bt;if(n.type===at.OVERWRITE){var u=n;u.source.fromUser?a=this.applyUserOverwrite_(t,u.path,u.snap,r,i,l):(Object(o.d)(u.source.fromServer,"Unknown source."),s=u.source.tagged||t.getServerCache().isFiltered()&&!u.path.isEmpty(),a=this.applyServerOverwrite_(t,u.path,u.snap,r,i,s,l))}else if(n.type===at.MERGE){var c=n;c.source.fromUser?a=this.applyUserMerge_(t,c.path,c.children,r,i,l):(Object(o.d)(c.source.fromServer,"Unknown source."),s=c.source.tagged||t.getServerCache().isFiltered(),a=this.applyServerMerge_(t,c.path,c.children,r,i,s,l))}else if(n.type===at.ACK_USER_WRITE){var f=n;a=f.revert?this.revertUserWrite_(t,f.path,r,i,l):this.ackUserWrite_(t,f.path,f.affectedTree,r,i,l)}else{if(n.type!==at.LISTEN_COMPLETE)throw Object(o.e)("Unknown operation type: "+n.type);a=this.listenComplete_(t,n.path,r,l)}var h=l.getChanges();return e.maybeAddValueEvent_(t,a,h),new Ct(a,h)},e.maybeAddValueEvent_=function(e,t,n){var r=t.getEventCache();if(r.isFullyInitialized()){var i=r.getNode().isLeafNode()||r.getNode().isEmpty(),o=e.getCompleteEventSnap();(n.length>
20||!e.getEventCache().isFullyInitialized()||i&&!r.getNode().equals(o)||!r.getNode().getPriority().equals(o.getPriority()))&&n.push(mt.valueChange(t.getCompleteEventSnap()))}},e.prototype.generateEventCacheAfterServerEvent_=function(e,t,n,r,i){var a=e.getEventCache();if(null!=n.shadowingWrite(t))return e;var s=void 0,l=void 0;if(t.isEmpty())if(Object(o.d)(e.getServerCache().isFullyInitialized(),"If change path is empty, we must have complete server data"),e.getServerCache().isFiltered()){var u=e.getCompleteServerSnap(),c=u instanceof We?u:We.EMPTY_NODE,f=n.calcCompleteEventChildren(c);s=this.filter_.updateFullNode(e.getEventCache().getNode(),f,i)}else{var h=n.calcCompleteEventCache(e.getCompleteServerSnap());s=this.filter_.updateFullNode(e.getEventCache().getNode(),h,i)}else{var d=t.getFront();if(".priority"===d){Object(o.d)(1===t.getLength(),"Can't have a priority with additional path components");var p=a.getNode();l=e.getServerCache().getNode();var y=n.calcEventCacheAfterServerOverwrite(t,p,l);s=null!=y?this.filter_.updatePriority(p,y):a.getNode()}else{var v=t.popFront(),g=void 0;if(a.isCompleteForChild(d)){l=e.getServerCache().getNode();var m=n.calcEventCacheAfterServerOverwrite(t,a.getNode(),l);g=null!=m?a.getNode().getImmediateChild(d).updateChild(v,m):a.getNode().getImmediateChild(d)}else g=n.calcCompleteChild(d,e.getServerCache());s=null!=g?this.filter_.updateChild(a.getNode(),d,g,v,r,i):a.getNode()}}return e.updateEventSnap(s,a.isFullyInitialized()||t.isEmpty(),this.filter_.filtersNodes())},e.prototype.applyServerOverwrite_=function(e,t,n,r,i,o,a){var s,l=e.getServerCache(),u=o?this.filter_:this.filter_.getIndexedFilter();if(t.isEmpty())s=u.updateFullNode(l.getNode(),n,null);else if(u.filtersNodes()&&!l.isFiltered()){var c=l.getNode().updateChild(t,n);s=u.updateFullNode(l.getNode(),c,null)}else{var f=t.getFront();if(!l.isCompleteForPath(t)&&t.getLength()>1)return e;var h=t.popFront(),d=l.getNode().getImmediateChild(f).updateChild(h,n);s=".priority"===f?u.updatePriority(l.getNode(),d):u.updateChild(l.getNode(),f,d,h,wt,null)}var p=e.updateServerSnap(s,l.isFullyInitialized()||t.isEmpty(),u.filtersNodes()),y=new Et(r,p,i);return this.generateEventCacheAfterServerEvent_(p,t,r,y,a)},e.prototype.applyUserOverwrite_=function(e,t,n,r,i,o){var a,s,l=e.getEventCache(),u=new Et(r,e,i);if(t.isEmpty())s=this.filter_.updateFullNode(e.getEventCache().getNode(),n,o),a=e.updateEventSnap(s,!0,this.filter_.filtersNodes());else{var c=t.getFront();if(".priority"===c)s=this.filter_.updatePriority(e.getEventCache().getNode(),n),a=e.updateEventSnap(s,l.isFullyInitialized(),l.isFiltered());else{var f=t.popFront(),h=l.getNode().getImmediateChild(c),d=void 0;if(f.isEmpty())d=n;else{var p=u.getCompleteChild(c);d=null!=p?".priority"===f.getBack()&&p.getChild(f.parent()).isEmpty()?p:p.updateChild(f,n):We.EMPTY_NODE}if(h.equals(d))a=e;else{var y=this.filter_.updateChild(l.getNode(),c,d,f,u,o);a=e.updateEventSnap(y,l.isFullyInitialized(),this.filter_.filtersNodes())}}}return a},e.cacheHasChild_=function(e,t){return e.getEventCache().isCompleteForChild(t)},e.prototype.applyUserMerge_=function(t,n,r,i,o,a){var s=this,l=t;return r.foreach((function(r,u){var c=n.child(r);e.cacheHasChild_(t,c.getFront())&&(l=s.applyUserOverwrite_(l,c,u,i,o,a))})),r.foreach((function(r,u){var c=n.child(r);e.cacheHasChild_(t,c.getFront())||(l=s.applyUserOverwrite_(l,c,u,i,o,a))})),l},e.prototype.applyMerge_=function(e,t){return t.foreach((function(t,n){e=e.updateChild(t,n)})),e},e.prototype.applyServerMerge_=function(e,t,n,r,i,o,a){var s=this;if(e.getServerCache().getNode().isEmpty()&&!e.getServerCache().isFullyInitialized())return e;var l,u=e;l=t.isEmpty()?n:ht.Empty.setTree(t,n);var c=e.getServerCache().getNode();return l.children.inorderTraversal((function(t,n){if(c.hasChild(t)){var l=e.getServerCache().getNode().getImmediateChild(t),f=s.applyMerge_(l,n);u=s.applyServerOverwrite_(u,new U(t),f,r,i,o,a)}})),l.children.inorderTraversal((function(t,n){var l=!e.getServerCache().isCompleteForChild(t)&&null==n.value;if(!c.hasChild(t)&&!l){var f=e.getServerCache().getNode().getImmediateChild(t),h=s.applyMerge_(f,n);u=s.applyServerOverwrite_(u,new U(t),h,r,i,o,a)}})),u},e.prototype.ackUserWrite_=function(e,t,n,r,i,o){if(null!=r.shadowingWrite(t))return e;var a=e.getServerCache().isFiltered(),s=e.getServerCache();if(null!=n.value){if(t.isEmpty()&&s.isFullyInitialized()||s.isCompleteForPath(t))return this.applyServerOverwrite_(e,t,s.getNode().getChild(t),r,i,a,o);if(t.isEmpty()){var l=ht.Empty;
2return s.getNode().forEachChild(_e,(function(e,t){l=l.set(new U(e),t)})),this.applyServerMerge_(e,t,l,r,i,a,o)}return e}var u=ht.Empty;return n.foreach((function(e,n){var r=t.child(e);s.isCompleteForPath(r)&&(u=u.set(e,s.getNode().getChild(r)))})),this.applyServerMerge_(e,t,u,r,i,a,o)},e.prototype.listenComplete_=function(e,t,n,r){var i=e.getServerCache(),o=e.updateServerSnap(i.getNode(),i.isFullyInitialized()||t.isEmpty(),i.isFiltered());return this.generateEventCacheAfterServerEvent_(o,t,n,wt,r)},e.prototype.revertUserWrite_=function(e,t,n,r,i){var a;if(null!=n.shadowingWrite(t))return e;var s=new Et(n,e,r),l=e.getEventCache().getNode(),u=void 0;if(t.isEmpty()||".priority"===t.getFront()){var c=void 0;if(e.getServerCache().isFullyInitialized())c=n.calcCompleteEventCache(e.getCompleteServerSnap());else{var f=e.getServerCache().getNode();Object(o.d)(f instanceof We,"serverChildren would be complete if leaf node"),c=n.calcCompleteEventChildren(f)}c=c,u=this.filter_.updateFullNode(l,c,i)}else{var h=t.getFront(),d=n.calcCompleteChild(h,e.getServerCache());null==d&&e.getServerCache().isCompleteForChild(h)&&(d=l.getImmediateChild(h)),(u=null!=d?this.filter_.updateChild(l,h,d,t.popFront(),s,i):e.getEventCache().getNode().hasChild(h)?this.filter_.updateChild(l,h,We.EMPTY_NODE,t.popFront(),s,i):l).isEmpty()&&e.getServerCache().isFullyInitialized()&&(a=n.calcCompleteEventCache(e.getCompleteServerSnap())).isLeafNode()&&(u=this.filter_.updateFullNode(u,a,i))}return a=e.getServerCache().isFullyInitialized()||null!=n.shadowingWrite(U.Empty),e.updateEventSnap(u,a,this.filter_.filtersNodes())},e}(),Ot=function(){function e(e){this.query_=e,this.index_=this.query_.getQueryParams().getIndex()}return e.prototype.generateEventsForChanges=function(e,t,n){var r=this,i=[],o=[];return e.forEach((function(e){e.type===mt.CHILD_CHANGED&&r.index_.indexedValueChanged(e.oldSnap,e.snapshotNode)&&o.push(mt.childMovedChange(e.childName,e.snapshotNode))})),this.generateEventsForType_(i,mt.CHILD_REMOVED,e,n,t),this.generateEventsForType_(i,mt.CHILD_ADDED,e,n,t),this.generateEventsForType_(i,mt.CHILD_MOVED,o,n,t),this.generateEventsForType_(i,mt.CHILD_CHANGED,e,n,t),this.generateEventsForType_(i,mt.VALUE,e,n,t),i},e.prototype.generateEventsForType_=function(e,t,n,r,i){var o=this,a=n.filter((function(e){return e.type===t}));a.sort(this.compareChanges_.bind(this)),a.forEach((function(t){var n=o.materializeSingleChange_(t,i);r.forEach((function(r){r.respondsTo(t.type)&&e.push(r.createEvent(n,o.query_))}))}))},e.prototype.materializeSingleChange_=function(e,t){return"value"===e.type||"child_removed"===e.type||(e.prevName=t.getPredecessorChildName(e.childName,e.snapshotNode,this.index_)),e},e.prototype.compareChanges_=function(e,t){if(null==e.childName||null==t.childName)throw Object(o.e)("Should only compare child_ events.");var n=new ve(e.childName,e.snapshotNode),r=new ve(t.childName,t.snapshotNode);return this.index_.compare(n,r)},e}(),Tt=function(){function e(e,t){this.query_=e,this.eventRegistrations_=[];var n=this.query_.getQueryParams(),r=new _t(n.getIndex()),i=n.getNodeFilter();this.processor_=new St(i);var o=t.getServerCache(),a=t.getEventCache(),s=r.updateFullNode(We.EMPTY_NODE,o.getNode(),null),l=i.updateFullNode(We.EMPTY_NODE,a.getNode(),null),u=new vt(s,o.isFullyInitialized(),r.filtersNodes()),c=new vt(l,a.isFullyInitialized(),i.filtersNodes());this.viewCache_=new gt(c,u),this.eventGenerator_=new Ot(this.query_)}return e.prototype.getQuery=function(){return this.query_},e.prototype.getServerCache=function(){return this.viewCache_.getServerCache().getNode()},e.prototype.getCompleteServerCache=function(e){var t=this.viewCache_.getCompleteServerSnap();return t&&(this.query_.getQueryParams().loadsAllData()||!e.isEmpty()&&!t.getImmediateChild(e.getFront()).isEmpty())?t.getChild(e):null},e.prototype.isEmpty=function(){return 0===this.eventRegistrations_.length},e.prototype.addEventRegistration=function(e){this.eventRegistrations_.push(e)},e.prototype.removeEventRegistration=function(e,t){var n=[];if(t){Object(o.d)(null==e,"A cancel should cancel all event registrations.");var r=this.query_.path;this.eventRegistrations_.forEach((function(e){t=t;var i=e.createCancelEvent(t,r);i&&n.push(i)}))}if(e){for(var i=[],a=0;a<this.eventRegistrations_.length;++a){var s=this.eventRegistrations_[a];if(s.matches(e)){if(e.hasAnyCallback()){i=i.concat(this.eventRegistrations_.slice(a+1));break}}else i.push(s)}this.eventRegistrations_=i}else this.eventRegistrations_=[];return n},e.prototype.applyOperation=function(e,t,n){e.type===at.MERGE&&null!==e.source.queryId&&(Object(o.d)(this.viewCache_.getCompleteServerSnap(),"We should always have a full c
2ache before handling merges"),Object(o.d)(this.viewCache_.getCompleteEventSnap(),"Missing event cache, even though we have a server cache"));var r=this.viewCache_,i=this.processor_.applyOperation(r,e,t,n);return this.processor_.assertIndexed(i.viewCache),Object(o.d)(i.viewCache.getServerCache().isFullyInitialized()||!r.getServerCache().isFullyInitialized(),"Once a server snap is complete, it should never go back"),this.viewCache_=i.viewCache,this.generateEventsForChanges_(i.changes,i.viewCache.getEventCache().getNode(),null)},e.prototype.getInitialEvents=function(e){var t=this.viewCache_.getEventCache(),n=[];t.getNode().isLeafNode()||t.getNode().forEachChild(xe,(function(e,t){n.push(mt.childAddedChange(e,t))}));return t.isFullyInitialized()&&n.push(mt.valueChange(t.getNode())),this.generateEventsForChanges_(n,t.getNode(),e)},e.prototype.generateEventsForChanges_=function(e,t,n){var r=n?[n]:this.eventRegistrations_;return this.eventGenerator_.generateEventsForChanges(e,t,r)},e}(),kt=function(){function e(){this.views=new Map}return Object.defineProperty(e,"__referenceConstructor",{get:function(){return Object(o.d)(ut,"Reference.ts has not been loaded"),ut},set:function(e){Object(o.d)(!ut,"__referenceConstructor has already been defined"),ut=e},enumerable:!1,configurable:!0}),e.prototype.isEmpty=function(){return 0===this.views.size},e.prototype.applyOperation=function(e,t,n){var r,a,s=e.source.queryId;if(null!==s){var l=this.views.get(s);return Object(o.d)(null!=l,"SyncTree gave us an op for an invalid query."),l.applyOperation(e,t,n)}var u=[];try{for(var c=Object(i.g)(this.views.values()),f=c.next();!f.done;f=c.next()){l=f.value;u=u.concat(l.applyOperation(e,t,n))}}catch(h){r={error:h}}finally{try{f&&!f.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return u},e.prototype.addEventRegistration=function(e,t,n,r,i){var o=e.queryIdentifier(),a=this.views.get(o);if(!a){var s=n.calcCompleteEventCache(i?r:null),l=!1;s?l=!0:r instanceof We?(s=n.calcCompleteEventChildren(r),l=!1):(s=We.EMPTY_NODE,l=!1);var u=new gt(new vt(s,l,!1),new vt(r,i,!1));a=new Tt(e,u),this.views.set(o,a)}return a.addEventRegistration(t),a.getInitialEvents(t)},e.prototype.removeEventRegistration=function(t,n,r){var o,a,s=t.queryIdentifier(),l=[],u=[],c=this.hasCompleteView();if("default"===s)try{for(var f=Object(i.g)(this.views.entries()),h=f.next();!h.done;h=f.next()){var d=Object(i.e)(h.value,2),p=d[0],y=d[1];u=u.concat(y.removeEventRegistration(n,r)),y.isEmpty()&&(this.views.delete(p),y.getQuery().getQueryParams().loadsAllData()||l.push(y.getQuery()))}}catch(v){o={error:v}}finally{try{h&&!h.done&&(a=f.return)&&a.call(f)}finally{if(o)throw o.error}}else(y=this.views.get(s))&&(u=u.concat(y.removeEventRegistration(n,r)),y.isEmpty()&&(this.views.delete(s),y.getQuery().getQueryParams().loadsAllData()||l.push(y.getQuery())));return c&&!this.hasCompleteView()&&l.push(new e.__referenceConstructor(t.repo,t.path)),{removed:l,events:u}},e.prototype.getQueryViews=function(){var e,t,n=[];try{for(var r=Object(i.g)(this.views.values()),o=r.next();!o.done;o=r.next()){var a=o.value;a.getQuery().getQueryParams().loadsAllData()||n.push(a)}}catch(s){e={error:s}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return n},e.prototype.getCompleteServerCache=function(e){var t,n,r=null;try{for(var o=Object(i.g)(this.views.values()),a=o.next();!a.done;a=o.next()){var s=a.value;r=r||s.getCompleteServerCache(e)}}
2catch(l){t={error:l}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r},e.prototype.viewForQuery=function(e){if(e.getQueryParams().loadsAllData())return this.getCompleteView();var t=e.queryIdentifier();return this.views.get(t)},e.prototype.viewExistsForQuery=function(e){return null!=this.viewForQuery(e)},e.prototype.hasCompleteView=function(){return null!=this.getCompleteView()},e.prototype.getCompleteView=function(){var e,t;try{for(var n=Object(i.g)(this.views.values()),r=n.next();!r.done;r=n.next()){var o=r.value;if(o.getQuery().getQueryParams().loadsAllData())return o}}catch(a){e={error:a}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return null},e}(),xt=function(){function e(e){this.writeTree_=e}return e.prototype.addWrite=function(t,n){if(t.isEmpty())return new e(new ht(n));var r=this.writeTree_.findRootMostValueAndPath(t);if(null!=r){var i=r.path,o=r.value,a=U.relativePath(i,t);return o=o.updateChild(a,n),new e(this.writeTree_.set(i,o))}var s=new ht(n);return new e(this.writeTree_.setTree(t,s))},e.prototype.addWrites=function(e,t){var n=this;return D(t,(function(t,r){n=n.addWrite(e.child(t),r)})),n},e.prototype.removeWrite=function(t){return t.isEmpty()?e.Empty:new e(this.writeTree_.setTree(t,ht.Empty))},e.prototype.hasCompleteWrite=function(e){return null!=this.getCompleteNode(e)},e.prototype.getCompleteNode=function(e){var t=this.writeTree_.findRootMostValueAndPath(e);return null!=t?this.writeTree_.get(t.path).getChild(U.relativePath(t.path,e)):null},e.prototype.getCompleteChildren=function(){var e=[],t=this.writeTree_.value;return null!=t?t.isLeafNode()||t.forEachChild(xe,(function(t,n){e.push(new ve(t,n))})):this.writeTree_.children.inorderTraversal((function(t,n){null!=n.value&&e.push(new ve(t,n.value))})),e},e.prototype.childCompoundWrite=function(t){if(t.isEmpty())return this;var n=this.getCompleteNode(t);return new e(null!=n?new ht(n):this.writeTree_.subtree(t))},e.prototype.isEmpty=function(){return this.writeTree_.isEmpty()},e.prototype.apply=function(e){return Nt(U.Empty,this.writeTree_,e)},e.Empty=new e(new ht(null)),e}();function Nt(e,t,n){if(null!=t.value)return n.updateChild(e,t.value);var r=null;return t.children.inorderTraversal((function(t,i){".priority"===t?(Object(o.d)(null!==i.value,"Priority writes must always be leaf nodes"),r=i.value):n=Nt(e.child(t),i,n)})),n.getChild(e).isEmpty()||null===r||(n=n.updateChild(e.child(".priority"),r)),n}var Pt=function(){function e(){this.visibleWrites_=xt.Empty,this.allWrites_=[],this.lastWriteId_=-1}return e.prototype.childWrites=function(e){return new It(e,this)},e.prototype.addOverwrite=function(e,t,n,r){Object(o.d)(n>this.lastWriteId_,"Stacking an older write on top of newer ones"),void 0===r&&(r=!0),this.allWrites_.push({path:e,snap:t,writeId:n,visible:r}),r&&(this.visibleWrites_=this.visibleWrites_.addWrite(e,t)),this.lastWriteId_=n},e.prototype.addMerge=function(e,t,n){Object(o.d)(n>this.lastWriteId_,"Stacking an older merge on top of newer ones"),this.allWrites_.push({path:e,children:t,writeId:n,visible:!0}),this.visibleWrites_=this.visibleWrites_.addWrites(e,t),this.lastWriteId_=n},e.prototype.getWrite=function(e){for(var t=0;t<this.allWrites_.length;t++){var n=this.allWrites_[t];if(n.writeId===e)return n}return null},e.prototype.removeWrite=function(e){var t=this,n=this.allWrites_.findIndex((function(t){return t.writeId===e}));Object(o.d)(n>=0,"removeWrite called with nonexistent writeId.");var r=this.allWrites_[n];this.allWrites_.splice(n,1);for(var i=r.visible,a=!1,s=this.allWrites_.length-1;i&&s>=0;){var l=this.allWrites_[s];l.visible&&(s>=n&&this.recordContainsPath_(l,r.path)?i=!1:r.path.contains(l.path)&&(a=!0)),s--}if(i){if(a)return this.resetTree_(),!0;r.snap?this.visibleWrites_=this.visibleWrites_.removeWrite(r.path):D(r.children,(function(e){t.visibleWrites_=t.visibleWrites_.removeWrite(r.path.child(e))}));return!0}return!1},e.prototype.getCompleteWriteData=function(e){return this.visibleWrites_.getCompleteNode(e)},e.prototype.calcCompleteEventCache=function(t,n,r,i){if(r||i){var o=this.visibleWrites_.childCompoundWrite(t);if(!i&&o.isEmpty())return n;if(i||null!=n||o.hasCompleteWrite(U.Empty)){var a=e.layerTree_(this.allWrites_,(function(e){return(e.visible||i)&&(!r||!~r.indexOf(e.writeId))&&(e.path.contains(t)||t.contains(e.path))}),t);u=n||We.EMPTY_NODE;return a.apply(u)}return null}var s=this.visibleWrites_.getCompleteNode(t);if(null!=s)return s;var l=this.visibleWrites_.childCompoundWrite(t);if(l.isEmpty())return n;if(null!=n||l.hasCompleteWrite(U.Empty)){var u=n||We.EMPTY_NODE;return l.apply(u)}return null},e.prototype.calcCompleteEventChildren=function(e,t){var n=We.EMPTY_NODE,r=this.visibleWrites_.getCompleteNode(e);if(r)return r.isLeafNode()||r.forEachChild(xe,(function(e,t){n=n.updateImmediateChild(e,t)})),n;if(t){var i=this.visibleWrites_.childCompoundWrite(e);return t.forEachChild(xe,(function(e,t){var r=i.childCompoundWrite(new U(e)).apply(t);n=n.updateImmediateChild(e,r)}
2)),i.getCompleteChildren().forEach((function(e){n=n.updateImmediateChild(e.name,e.node)})),n}return this.visibleWrites_.childCompoundWrite(e).getCompleteChildren().forEach((function(e){n=n.updateImmediateChild(e.name,e.node)})),n},e.prototype.calcEventCacheAfterServerOverwrite=function(e,t,n,r){Object(o.d)(n||r,"Either existingEventSnap or existingServerSnap must exist");var i=e.child(t);if(this.visibleWrites_.hasCompleteWrite(i))return null;var a=this.visibleWrites_.childCompoundWrite(i);return a.isEmpty()?r.getChild(t):a.apply(r.getChild(t))},e.prototype.calcCompleteChild=function(e,t,n){var r=e.child(t),i=this.visibleWrites_.getCompleteNode(r);return null!=i?i:n.isCompleteForChild(t)?this.visibleWrites_.childCompoundWrite(r).apply(n.getNode().getImmediateChild(t)):null},e.prototype.shadowingWrite=function(e){return this.visibleWrites_.getCompleteNode(e)},e.prototype.calcIndexedSlice=function(e,t,n,r,i,o){var a,s=this.visibleWrites_.childCompoundWrite(e),l=s.getCompleteNode(U.Empty);if(null!=l)a=l;else{if(null==t)return[];a=s.apply(t)}if((a=a.withIndex(o)).isEmpty()||a.isLeafNode())return[];for(var u=[],c=o.getCompare(),f=i?a.getReverseIteratorFrom(n,o):a.getIteratorFrom(n,o),h=f.getNext();h&&u.length<r;)0!==c(h,n)&&u.push(h),h=f.getNext();return u},e.prototype.recordContainsPath_=function(e,t){if(e.snap)return e.path.contains(t);for(var n in e.children)if(e.children.hasOwnProperty(n)&&e.path.child(n).contains(t))return!0;return!1},e.prototype.resetTree_=function(){this.visibleWrites_=e.layerTree_(this.allWrites_,e.DefaultFilter_,U.Empty),this.allWrites_.length>0?this.lastWriteId_=this.allWrites_[this.allWrites_.length-1].writeId:this.lastWriteId_=-1},e.DefaultFilter_=function(e){return e.visible},e.layerTree_=function(e,t,n){for(var r=xt.Empty,i=0;i<e.length;++i){var a=e[i];if(t(a)){var s=a.path,l=void 0;if(a.snap)n.contains(s)?(l=U.relativePath(n,s),r=r.addWrite(l,a.snap)):s.contains(n)&&(l=U.relativePath(s,n),r=r.addWrite(U.Empty,a.snap.getChild(l)));else{if(!a.children)throw Object(o.e)("WriteRecord should have .snap or .children");if(n.contains(s))l=U.relativePath(n,s),r=r.addWrites(l,a.children);else if(s.contains(n))if((l=U.relativePath(s,n)).isEmpty())r=r.addWrites(U.Empty,a.children);else{var u=Object(o.x)(a.children,l.getFront());if(u){var c=u.getChild(l.popFront());r=r.addWrite(U.Empty,c)}}}}}return r},e}(),It=function(){function e(e,t){this.treePath_=e,this.writeTree_=t}return e.prototype.calcCompleteEventCache=function(e,t,n){return this.writeTree_.calcCompleteEventCache(this.treePath_,e,t,n)},e.prototype.calcCompleteEventChildren=function(e){return this.writeTree_.calcCompleteEventChildren(this.treePath_,e)},e.prototype.calcEventCacheAfterServerOverwrite=function(e,t,n){return this.writeTree_.calcEventCacheAfterServerOverwrite(this.treePath_,e,t,n)},e.prototype.shadowingWrite=function(e){return this.writeTree_.shadowingWrite(this.treePath_.child(e))},e.prototype.calcIndexedSlice=function(e,t,n,r,i){return this.writeTree_.calcIndexedSlice(this.treePath_,e,t,n,r,i)},e.prototype.calcCompleteChild=function(e,t){return this.writeTree_.calcCompleteChild(this.treePath_,e,t)},e.prototype.child=function(t){return new e(this.treePath_.child(t),this.writeTree_)},e}(),Rt=function(){function e(e){this.listenProvider_=e,this.syncPointTree_=ht.Empty,this.pendingWriteTree_=new Pt,this.tagToQueryMap=new Map,this.queryToTagMap=new Map}return e.prototype.applyUserOverwrite=function(e,t,n,r){return this.pendingWriteTree_.addOverwrite(e,t,n,r),r?this.applyOperationToSyncPoints_(new pt(ct.User,e,t)):[]},e.prototype.applyUserMerge=function(e,t,n){this.pendingWriteTree_.addMerge(e,t,n);var r=ht.fromObject(t);return this.applyOperationToSyncPoints_(new yt(ct.User,e,r))},e.prototype.ackUserWrite=function(e,t){void 0===t&&(t=!1);var n=this.pendingWriteTree_.getWrite(e);if(this.pendingWriteTree_.removeWrite(e)){var r=ht.Empty;return null!=n.snap?r=r.set(U.Empty,!0):D(n.children,(function(e,t){r=r.set(new U(e),t)})),this.applyOperationToSyncPoints_(new ft(n.path,r,t))}return[]},e.prototype.applyServerOverwrite=function(e,t){return this.applyOperationToSyncPoints_(new pt(ct.Server,e,t))},e.prototype.applyServerMerge=function(e,t){var n=ht.fromObject(t);return this.applyOperationToSyncPoints_(new yt(ct.Server,e,n))},e.prototype.applyListenComplete=function(e){return this.applyOperationToSyncPoints_(new dt(ct.Server,e))},e.prototype.applyTaggedQueryOverwrite=function(t,n,r){var i=this.queryKeyForTag_(r);if(null!=i){var o=e.parseQueryKey_(i),a=o.path,s=o.queryId,l=U.relativePath(a,t),u=new pt(ct.forServerTaggedQuery(s),l,n);return this.applyTaggedOperation_(a,u)}return[]},e.prototype.applyTaggedQueryMerge=function(t,n,r){var i=this.queryKeyForTag_(r);if(i){var o=e.parseQueryKey_(i),a=o.path,s=o.queryId,l=U.relativePath(a,t),u=ht.fromObject(n),c=new yt(ct.forServerTaggedQuery(s),l,u);return this.applyTaggedOperation_(a,c)}return[]},e.prototype.applyTaggedListenComplete=function(t,n){var r=this.queryKeyForTag_(n);if(r){var i=e.parseQueryKey_(r),o=i.path,a=i.queryId,s=U.relativePath(o,t),l=new dt(ct.forServerTaggedQuery(a),s);return this.applyTaggedOperation_(o,l)}return[]},e.prototype.addEventRegistration=function(t,n){var r=t.path,i=null,a=!1;this.syncPointTree_.foreachOnPath(r,(function(e,t){var n=U.relativePath(e,r);i=i||t.getCompleteServerCache(n),a=a||t.hasCompleteView()}));var s,l=this.syncPointTree_.get(r);(l?(a=a||l.hasCompleteView(),i=i||l.getCompleteServerCache(U.Empty)):(l=new kt,this.syncPointTree_=this.syncPointTree_.set(r,l)),null!=i)?s=!0:(s=!1,i=We.EMPTY_NODE,this.syncPointTree_.subtree(r).foreachChild((function(e,t){var n=t.getCompleteServerCache(U.Empty);n&&(i=i.updateImmediateChild(e,n))})));var u=l.viewExistsForQuery(t);if(!u&&!t.getQueryParams().loadsAllData()){var c=e.makeQueryKey_(t);Object(o.d)(!this.queryToTagMap.has(c),"View does not exist, but we have a tag");var f=e.getNextQueryTag_();this.queryToTagMap.set(c,f),this.tagToQueryMap.set(f,c)}var h=this.pendingWriteTree_.childWrites(r),d=l.addEventRegistration(t,n,h,i,s);if(!u&&!a){var p=l.viewForQuery(t);d=d.concat(this.setupListener_(t,p))}return d},e.prototype.removeEventRegistration=function(t,n,r){var i=this,o=t.path,a=this.syncPointTree_.get(o),s=[];
2if(a&&("default"===t.queryIdentifier()||a.viewExistsForQuery(t))){var l=a.removeEventRegistration(t,n,r);a.isEmpty()&&(this.syncPointTree_=this.syncPointTree_.remove(o));var u=l.removed;s=l.events;var c=-1!==u.findIndex((function(e){return e.getQueryParams().loadsAllData()})),f=this.syncPointTree_.findOnPath(o,(function(e,t){return t.hasCompleteView()}));if(c&&!f){var h=this.syncPointTree_.subtree(o);if(!h.isEmpty())for(var d=this.collectDistinctViewsForSubTree_(h),p=0;p<d.length;++p){var y=d[p],v=y.getQuery(),g=this.createListenerForView_(y);this.listenProvider_.startListening(e.queryForListening_(v),this.tagForQuery_(v),g.hashFn,g.onComplete)}}if(!f&&u.length>0&&!r)if(c){this.listenProvider_.stopListening(e.queryForListening_(t),null)}else u.forEach((function(t){var n=i.queryToTagMap.get(e.makeQueryKey_(t));i.listenProvider_.stopListening(e.queryForListening_(t),n)}));this.removeTags_(u)}return s},e.prototype.calcCompleteEventCache=function(e,t){var n=this.pendingWriteTree_,r=this.syncPointTree_.findOnPath(e,(function(t,n){var r=U.relativePath(t,e),i=n.getCompleteServerCache(r);if(i)return i}));return n.calcCompleteEventCache(e,r,t,!0)},e.prototype.collectDistinctViewsForSubTree_=function(e){return e.fold((function(e,t,n){if(t&&t.hasCompleteView())return[t.getCompleteView()];var r=[];return t&&(r=t.getQueryViews()),D(n,(function(e,t){r=r.concat(t)})),r}))},e.prototype.removeTags_=function(t){for(var n=0;n<t.length;++n){var r=t[n];if(!r.getQueryParams().loadsAllData()){var i=e.makeQueryKey_(r),o=this.queryToTagMap.get(i);this.queryToTagMap.delete(i),this.tagToQueryMap.delete(o)}}},e.queryForListening_=function(e){return e.getQueryParams().loadsAllData()&&
2!e.getQueryParams().isDefault()?e.getRef():e},e.prototype.setupListener_=function(t,n){var r=t.path,i=this.tagForQuery_(t),a=this.createListenerForView_(n),s=this.listenProvider_.startListening(e.queryForListening_(t),i,a.hashFn,a.onComplete),l=this.syncPointTree_.subtree(r);if(i)Object(o.d)(!l.value.hasCompleteView(),"If we're adding a query, it shouldn't be shadowed");else for(var u=l.fold((function(e,t,n){if(!e.isEmpty()&&t&&t.hasCompleteView())return[t.getCompleteView().getQuery()];var r=[];return t&&(r=r.concat(t.getQueryViews().map((function(e){return e.getQuery()})))),D(n,(function(e,t){r=r.concat(t)})),r})),c=0;c<u.length;++c){var f=u[c];this.listenProvider_.stopListening(e.queryForListening_(f),this.tagForQuery_(f))}return s},e.prototype.createListenerForView_=function(e){var t=this,n=e.getQuery(),r=this.tagForQuery_(n);return{hashFn:function(){return(e.getServerCache()||We.EMPTY_NODE).hash()},onComplete:function(e){if("ok"===e)return r?t.applyTaggedListenComplete(n.path,r):t.applyListenComplete(n.path);var i=function(e,t){var n="Unknown Error";"too_big"===e?n="The data requested exceeds the maximum size that can be accessed with a single request.":"permission_denied"===e?n="Client doesn't have permission to access the desired data.":"unavailable"===e&&(n="The service is unavailable");var r=new Error(e+" at "+t.path.toString()+": "+n);return r.code=e.toUpperCase(),r}(e,n);return t.removeEventRegistration(n,null,i)}}},e.makeQueryKey_=function(e){return e.path.toString()+"$"+e.queryIdentifier()},e.parseQueryKey_=function(e){var t=e.indexOf("$");return Object(o.d)(-1!==t&&t<e.length-1,"Bad queryKey."),{queryId:e.substr(t+1),path:new U(e.substr(0,t))}},e.prototype.queryKeyForTag_=function(e){return this.tagToQueryMap.get(e)},e.prototype.tagForQuery_=function(t){var n=e.makeQueryKey_(t);return this.queryToTagMap.get(n)},e.getNextQueryTag_=function(){return e.nextQueryTag_++},e.prototype.applyTaggedOperation_=function(e,t){var n=this.syncPointTree_.get(e);Object(o.d)(n,"Missing sync point for query tag that we're tracking");var r=this.pendingWriteTree_.childWrites(e);return n.applyOperation(t,r,null)},e.prototype.applyOperationToSyncPoints_=function(e){return this.applyOperationHelper_(e,this.syncPointTree_,null,this.pendingWriteTree_.childWrites(U.Empty))},e.prototype.applyOperationHelper_=function(e,t,n,r){if(e.path.isEmpty())return this.applyOperationDescendantsHelper_(e,t,n,r);var i=t.get(U.Empty);null==n&&null!=i&&(n=i.getCompleteServerCache(U.Empty));var o=[],a=e.path.getFront(),s=e.operationForChild(a),l=t.children.get(a);if(l&&s){var u=n?n.getImmediateChild(a):null,c=r.child(a);o=o.concat(this.applyOperationHelper_(s,l,u,c))}return i&&(o=o.concat(i.applyOperation(e,r,n))),o},e.prototype.applyOperationDescendantsHelper_=function(e,t,n,r){var i=this,o=t.get(U.Empty);null==n&&null!=o&&(n=o.getCompleteServerCache(U.Empty));var a=[];return t.children.inorderTraversal((function(t,o){var s=n?n.getImmediateChild(t):null,l=r.child(t),u=e.operationForChild(t);u&&(a=a.concat(i.applyOperationDescendantsHelper_(u,o,s,l)))})),o&&(a=a.concat(o.applyOperation(e,r,n))),a},e.nextQueryTag_=1,e}(),Dt=function(){function e(){this.rootNode_=We.EMPTY_NODE}return e.prototype.getNode=function(e){return this.rootNode_.getChild(e)},e.prototype.updateSnapshot=function(e,t){this.rootNode_=this.rootNode_.updateChild(e,t)},e}(),jt=function(){function e(){this.counters_={}}return e.prototype.incrementCounter=function(e,t){void 0===t&&(t=1),Object(o.h)(this.counters_,e)||(this.counters_[e]=0),this.counters_[e]+=t},e.prototype.get=function(){return Object(o.j)(this.counters_)},e}(),Lt=function(){function e(){}return e.getCollection=function(e){var t=e.toString();return this.collections_[t]||(this.collections_[t]=new jt),this.collections_[t]},e.getOrCreateReporter=function(e,t){var n=e.toString();return this.reporters_[n]||(this.reporters_[n]=t()),this.reporters_[n]},e.collections_={},e.reporters_={},e}(),At=function(){function e(e){this.collection_=e,this.last_=null}return e.prototype.get=function(){var e=this.collection_.get(),t=Object(i.a)({},e);return this.last_&&D(this.last_,(function(e,n){t[e]=t[e]-n})),this.last_=e,t},e}(),Ft=function(){function e(e,t){this.server_=t,this.statsToReport_={},this.statsListener_=new At(e);var n=1e4+2e4*Math.random();M(this.reportStats_.bind(this),Math.floor(n))}return e.prototype.includeStat=function(e){this.statsToReport_[e]=!0},e.prototype.reportStats_=function(){var e=this,t=this.statsListener_.get(),n={},r=!1;D(t,(function(t,i){i>0&&Object(o.h)(e.statsToReport_,t)&&(n[t]=i,r=!0)})),r&&this.server_.reportStats(n),M(this.reportStats_.bind(this),Math.floor(2*Math.random()*3e5))},e}(),Mt=function(){function e(){this.eventLists_=[],this.recursionDepth_=0}return e.prototype.queueEvents=function(e){for(var t=null,n=0;n<e.length;n++){var r=e[n],i=r.getPath();null===t||i.equals(t.getPath())||(this.eventLists_.push(t),t=null),null===t&&(t=new Ut(i)),t.add(r)}t&&this.eventLists_.push(t)},e.prototype.raiseEventsAtPath=function(e,t){this.queueEvents(t),this.raiseQueuedEventsMatchingPredicate_((function(t){return t.equals(e)}))},e.prototype.raiseEventsForChangedPath=function(e,t){this.queueEvents(t),this.raiseQueuedEventsMatchingPredicate_((function(t){return t.contains(e)||e.contains(t)}))},e.prototype.raiseQueuedEventsMatchingPredicate_=function(e){this.recursionDepth_++;for(var t=!0,n=0;n<this.eventLists_.length;n++){var r=this.eventLists_[n];if(r)e(r.getPath())?(this.eventLists_[n].raise(),this.eventLists_[n]=null):t=!1}t&&(this.eventLists_=[]),this.recursionDepth_--},e}(),Ut=function(){function e(e){this.path_=e,this.events_=[]}
2return e.prototype.add=function(e){this.events_.push(e)},e.prototype.raise=function(){for(var e=0;e<this.events_.length;e++){var t=this.events_[e];if(null!==t){this.events_[e]=null;var n=t.getEventRunner();g&&b("event: "+t.toString()),F(n)}}},e.prototype.getPath=function(){return this.path_},e}(),Wt=function(){function e(e){this.allowedEvents_=e,this.listeners_={},Object(o.d)(Array.isArray(e)&&e.length>0,"Requires a non-empty array")}return e.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(Array.isArray(this.listeners_[e]))for(var r=Object(i.f)(this.listeners_[e]),o=0;o<r.length;o++)r[o].callback.apply(r[o].context,t)},e.prototype.on=function(e,t,n){this.validateEventType_(e),this.listeners_[e]=this.listeners_[e]||[],this.listeners_[e].push({callback:t,context:n});var r=this.getInitialEvent(e);r&&t.apply(n,r)},e.prototype.off=function(e,t,n){this.validateEventType_(e);for(var r=this.listeners_[e]||[],i=0;i<r.length;i++)if(r[i].callback===t&&(!n||n===r[i].context))return void r.splice(i,1)},e.prototype.validateEventType_=function(e){Object(o.d)(this.allowedEvents_.find((function(t){return t===e})),"Unknown event: "+e)},e}(),zt=function(e){function t(){var t,n,r=e.call(this,["visible"])||this;return"undefined"!==typeof document&&"undefined"!==typeof document.addEventListener&&("undefined"!==typeof document.hidden?(n="visibilitychange",t="hidden"):"undefined"!==typeof document.mozHidden?(n="mozvisibilitychange",t="mozHidden"):"undefined"!==typeof document.msHidden?(n="msvisibilitychange",t="msHidden"):"undefined"!==typeof document.webkitHidden&&(n="webkitvisibilitychange",t="webkitHidden")),r.visible_=!0,n&&document.addEventListener(n,(function(){var e=!document[t];e!==r.visible_&&(r.visible_=e,r.trigger("visible",e))}),!1),r}return Object(i.c)(t,e),t.getInstance=function(){return new t},t.prototype.getInitialEvent=function(e){return Object(o.d)("visible"===e,"Unknown event type: "+e),[this.visible_]},t}(Wt),Bt=function(e){function t(){var t=e.call(this,["online"])||this;return t.online_=!0,"undefined"===typeof window||"undefined"===typeof window.addEventListener||Object(o.p)()||(window.addEventListener("online",(function(){t.online_||(t.online_=!0,t.trigger("online",!0))}),!1),window.addEventListener("offline",(function(){t.online_&&(t.online_=!1,t.trigger("online",!1))}),!1)),t}return Object(i.c)(t,e),t.getInstance=function(){return new t},t.prototype.getInitialEvent=function(e){return Object(o.d)("online"===e,"Unknown event type: "+e),[this.online_]},t.prototype.currentlyOnline=function(){return this.online_},t}(Wt),qt=function(){function e(e){this.onMessage_=e,this.pendingResponses=[],this.currentResponseNum=0,this.closeAfterResponse=-1,this.onClose=null}return e.prototype.closeAfter=function(e,t){this.closeAfterResponse=e,this.onClose=t,this.closeAfterResponse<this.currentResponseNum&&(this.onClose(),this.onClose=null)},e.prototype.handleResponse=function(e,t){var n=this;this.pendingResponses[e]=t;for(var r=function(){var e=i.pendingResponses[i.currentResponseNum];delete i.pendingResponses[i.currentResponseNum];for(var t=function(t){e[t]&&F((function(){n.onMessage_(e[t])}))},r=0;r<e.length;++r)t(r);if(i.currentResponseNum===i.closeAfterResponse)return i.onClose&&(i.onClose(),i.onClose=null),"break";i.currentResponseNum++},i=this;this.pendingResponses[this.currentResponseNum];){if("break"===r())break}},e}(),Vt="start",Qt="close",Ht=function(){function e(e,t,n,r,i){this.connId=e,this.repoInfo=t,this.applicationId=n,this.transportSessionId=r,this.lastSessionId=i,this.bytesSent=0,this.bytesReceived=0,this.everConnected_=!1,this.log_=w(e),this.stats_=Lt.getCollection(t),this.urlFn=function(e){return t.connectionURL(V,e)}}return e.prototype.open=function(e,t){var n=this;this.curSegmentNum=0,this.onDisconnect_=t,this.myPacketOrderer=new qt(e),this.isClosed_=!1,this.connectTimeoutTimer_=setTimeout((function(){n.log_("Timed out trying to connect."),n.onClosed_(),n.connectTimeoutTimer_=null}),Math.floor(3e4)),function(e){if(Object(o.r)()||"complete"===document.readyState)e();else{var t=!1,n=function n(){document.body?t||(t=!0,e()):setTimeout(n,Math.floor(10))};document.addEventListener?(document.addEventListener("DOMContentLoaded",n,!1),window.addEventListener("load",n,!1)):document.attachEvent&&(document.attachEvent("onreadystatechange",(function(){"complete"===document.readyState&&n()})),window.attachEvent("onload",n))}}((function(){if(!n.isClosed_){n.scriptTagHolder=new Kt((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=Object(i.e)(e,5),o=r[0],a=r[1],s=r[2];r[3],r[4];if(n.incrementIncomingBytes_(e),n.scriptTagHolder)if(n.connectTimeoutTimer_&&(clearTimeout(n.connectTimeoutTimer_),n.connectTimeoutTimer_=null),n.everConnected_=!0,o===Vt)n.id=a,n.password=s;else{if(o!==Qt)throw new Error("Unrecognized command received: "+o);a?(n.scriptTagHolder.sendNewPolls=!1,n.myPacketOrderer.closeAfter(a,(function(){n.onClosed_()}))):n.onClosed_()}}),(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=Object(i.e)(e,2),o=r[0],a=r[1];n.incrementIncomingBytes_(e),n.myPacketOrderer.handleResponse(o,a)}),(function(){n.onClosed_()}),n.urlFn);var e={start:"t"};e.ser=Math.floor(1e8*Math.random()),n.scriptTagHolder.uniqueCallbackIdentifier&&(e.cb=n.scriptTagHolder.uniqueCallbackIdentifier),e.v=z,n.transportSessionId&&(e.s=n.transportSessionId),n.lastSessionId&&(e.ls=n.lastSessionId),n.applicationId&&(e.p=n.applicationId),"undefined"!==typeof location&&location.href&&-1!==location.href.indexOf(B)&&(e.r="f");var t=n.urlFn(e);n.log_("Connecting via long-poll to "+t),n.scriptTagHolder.addTag(t,(function(){}))}}))},e.prototype.start=function(){this.scriptTagHolder.startLongPoll(this.id,this.password),this.addDisconnectPingFrame(this.id,this.password)},e.forceAllow=function(){e.forceAllow_=!0},e.forceDisallow=function(){e.forceDisallow_=!0},e.isAvailable=function(){return!Object(o.r)()&&(!!e.forceAllow_||!e.forceDisallow_&&"undefined"!==typeof document&&null!=document.createElement&&!("object"===typeof window&&window.chrome&&window.chrome.extension&&!/^chrome/.test(window.location.href))&&!("object"===typeof Windows&&"object"===typeof Windows.UI))},e.prototype.markConnectionHealthy=function(){},e.prototype.shutdown_=function(){this.isClosed_=!0,this.scriptTagHolder&&(this.scriptTagHolder.close(),this.scriptTagHolder=null),this.myDisconnFrame&&(document.body.removeChild(this.myDisconnFrame),this.myDisconnFrame=null),this.connectTimeoutTimer_&&(clearTimeout(this.connectTimeoutTimer_),this.connectTimeoutTimer_=null)},e.prototype.onClosed_=function(){this.isClosed_||(this.log_("Longpoll is closing itself"),this.shutdown_(),this.onDisconnect_&&(this.onDisconnect_(this.everConnected_),this.onDisconnect_=null))},e.prototype.close=function(){this.isClosed_||(this.log_("Longpoll is being closed."),this.shutdown_())},e.prototype.send=function(e){var t=Object(o.A)(e);this.bytesSent+=t.length,this.stats_.incrementCounter("bytes_sent",t.length);for(var n=Object(o.g)(t),r=R(n,1840),i=0;i<r.length;i++)this.scriptTagHolder.enqueueSegment(this.curSegmentNum,r.length,r[i]),this.curSegmentNum++},e.prototype.addDisconnectPingFrame=function(e,t){if(!Object(o.r)()){this.myDisconnFrame=document.createElement("iframe");var n={dframe:"t"};n.id=e,n.pw=t,this.myDisconnFrame.src=this.urlFn(n),this.myDisconnFrame.style.display="none",document.body.appendChild(this.myDisconnFrame)}},e.prototype.incrementIncomingBytes_=function(e){var t=Object(o.A)(e).length;this.bytesReceived+=t,this.stats_.incrementCounter("bytes_received",t)},e}(),Kt=function(){function e(t,n,r,i){if(this.onDisconnect=r,this.urlFn=i,this.outstandingRequests=new Set,this.pendingSegs=[],this.currentSerial=Math.floor(1e8*Math.random()),this.sendNewPolls=!0,Object(o.r)())this.commandCB=t,this.onMessageCB=n;else{this.uniqueCallbackIdentifier=p(),window["pLPCommand"+this.uniqueCallbackIdentifier]=t,window["pRTLPCB"+this.uniqueCallbackIdentifier]=n,this.myIFrame=e.createI
2Frame_();var a="";if(this.myIFrame.src&&"javascript:"===this.myIFrame.src.substr(0,"javascript:".length))a='<script>document.domain="'+document.domain+'";<\/script>';var s="<html><body>"+a+"</body></html>";try{this.myIFrame.doc.open(),this.myIFrame.doc.write(s),this.myIFrame.doc.close()}catch(l){b("frame writing exception"),l.stack&&b(l.stack),b(l)}}}return e.createIFrame_=function(){var e=document.createElement("iframe");if(e.style.display="none",!document.body)throw"Document body has not initialized. Wait to initialize Firebase until after the document is ready.";document.body.appendChild(e);try{e.contentWindow.document||b("No IE domain setting required")}catch(n){var t=document.domain;e.src="javascript:void((function(){document.open();document.domain='"+t+"';document.close();})())"}return e.contentDocument?e.doc=e.contentDocument:e.contentWindow?e.doc=e.contentWindow.document:e.document&&(e.doc=e.document),e},e.prototype.close=function(){var e=this;this.alive=!1,this.myIFrame&&(this.myIFrame.doc.body.innerHTML="",setTimeout((function(){null!==e.myIFrame&&(document.body.removeChild(e.myIFrame),e.myIFrame=null)}),Math.floor(0)));var t=this.onDisconnect;t&&(this.onDisconnect=null,t())},e.prototype.startLongPoll=function(e,t){for(this.myID=e,this.myPW=t,this.alive=!0;this.newRequest_(););},e.prototype.newRequest_=function(){if(this.alive&&this.sendNewPolls&&this.outstandingRequests.size<(this.pendingSegs.length>0?2:1)){this.currentSerial++;var e={};e.id=this.myID,e.pw=this.myPW,e.ser=this.currentSerial;for(var t=this.urlFn(e),n="",r=0;this.pendingSegs.length>0;){if(!(this.pendingSegs[0].d.length+30+n.length<=1870))break;var i=this.pendingSegs.shift();n=n+"&seg"+r+"="+i.seg+"&ts"+r+"="+i.ts+"&d"+r+"="+i.d,r++}return t+=n,this.addLongPollTag_(t,this.currentSerial),!0}return!1},e.prototype.enqueueSegment=function(e,t,n){this.pendingSegs.push({seg:e,ts:t,d:n}),this.alive&&this.newRequest_()},e.prototype.addLongPollTag_=function(e,t){var n=this;this.outstandingRequests.add(t);var r=function(){n.outstandingRequests.delete(t),n.newRequest_()},i=setTimeout(r,Math.floor(25e3));this.addTag(e,(function(){clearTimeout(i),r()}))},e.prototype.addTag=function(e,t){var n=this;Object(o.r)()?this.doNodeLongPoll(e,t):setTimeout((function(){try{if(!n.sendNewPolls)return;var r=n.myIFrame.doc.createElement("script");r.type="text/javascript",r.async=!0,r.src=e,r.onload=r.onreadystatechange=function(){var e=r.readyState;e&&"loaded"!==e&&"complete"!==e||(r.onload=r.onreadystatechange=null,r.parentNode&&r.parentNode.removeChild(r),t())},r.onerror=function(){b("Long-poll script failed to load: "+e),n.sendNewPolls=!1,n.close()},n.myIFrame.doc.body.appendChild(r)}catch(i){}}),Math.floor(1))},e}(),Yt="";function $t(e){Yt=e}var Gt=null;"undefined"!==typeof MozWebSocket?Gt=MozWebSocket:"undefined"!==typeof WebSocket&&(Gt=WebSocket);var Xt=function(){function t(e,n,r,i,o){this.connId=e,this.applicationId=r,this.keepaliveTimer=null,this.frames=null,this.totalFrames=0,this.bytesSent=0,this.bytesReceived=0,this.log_=w(this.connId),this.stats_=Lt.getCollection(n),this.connURL=t.connectionURL_(n,i,o),this.nodeAdmin=n.nodeAdmin}return t.connectionURL_=function(e,t,n){var r={};return r.v=z,!Object(o.r)()&&"undefined"!==typeof location&&location.href&&-1!==location.href.indexOf(B)&&(r.r="f"),t&&(r.s=t),n&&(r.ls=n),e.connectionURL(q,r)},t.prototype.open=function(t,n){var r=this;this.onDisconnect=n,this.onMessage=t,this.log_("Websocket connecting to "+this.connURL),this.everConnected_=!1,f.set("previous_websocket_failure",!0);try{if(Object(o.r)()){var i=this.nodeAdmin?"AdminNode":"Node",a={headers:{"User-Agent":"Firebase/5/"+Yt+"/"+e.platform+"/"+i,"X-Firebase-GMPID":this.applicationId||""}},s=Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0,FAST_REFRESH:!0}),l=0===this.connURL.indexOf("wss://")?s.HTTPS_PROXY||s.https_proxy:s.HTTP_PROXY||s.http_proxy;l&&(a.proxy={origin:l}),this.mySock=new Gt(this.connURL,[],a)}else{a={headers:{"X-Firebase-GMPID":this.applicationId||""}};this.mySock=new Gt(this.connURL,[],a)}}catch(c){this.log_("Error instantiating WebSocket.");var u=c.message||c.data;return u&&this.log_(u),void this.onClosed_()}this.mySock.onopen=function(){r.log_("Websocket connected."),r.everConnected_=!0}
2,this.mySock.onclose=function(){r.log_("Websocket connection was disconnected."),r.mySock=null,r.onClosed_()},this.mySock.onmessage=function(e){r.handleIncomingFrame(e)},this.mySock.onerror=function(e){r.log_("WebSocket error. Closing connection.");var t=e.message||e.data;t&&r.log_(t),r.onClosed_()}},t.prototype.start=function(){},t.forceDisallow=function(){t.forceDisallow_=!0},t.isAvailable=function(){var e=!1;if("undefined"!==typeof navigator&&navigator.userAgent){var n=navigator.userAgent.match(/Android ([0-9]{0,}\.[0-9]{0,})/);n&&n.length>1&&parseFloat(n[1])<4.4&&(e=!0)}return!e&&null!==Gt&&!t.forceDisallow_},t.previouslyFailed=function(){return f.isInMemoryStorage||!0===f.get("previous_websocket_failure")},t.prototype.markConnectionHealthy=function(){f.remove("previous_websocket_failure")},t.prototype.appendFrame_=function(e){if(this.frames.push(e),this.frames.length===this.totalFrames){var t=this.frames.join("");this.frames=null;var n=Object(o.u)(t);this.onMessage(n)}},t.prototype.handleNewFrameCount_=function(e){this.totalFrames=e,this.frames=[]},t.prototype.extractFrameCount_=function(e){if(Object(o.d)(null===this.frames,"We already have a frame buffer"),e.length<=6){var t=Number(e);if(!isNaN(t))return this.handleNewFrameCount_(t),null}return this.handleNewFrameCount_(1),e},t.prototype.handleIncomingFrame=function(e){if(null!==this.mySock){var t=e.data;if(this.bytesReceived+=t.length,this.stats_.incrementCounter("bytes_received",t.length),this.resetKeepAlive(),null!==this.frames)this.appendFrame_(t);else{var n=this.extractFrameCount_(t);null!==n&&this.appendFrame_(n)}}},t.prototype.send=function(e){this.resetKeepAlive();var t=Object(o.A)(e);this.bytesSent+=t.length,this.stats_.incrementCounter("bytes_sent",t.length);var n=R(t,16384);n.length>1&&this.sendString_(String(n.length));for(var r=0;r<n.length;r++)this.sendString_(n[r])},t.prototype.shutdown_=function(){this.isClosed_=!0,this.keepaliveTimer&&(clearInterval(this.keepaliveTimer),this.keepaliveTimer=null),this.mySock&&(this.mySock.close(),this.mySock=null)},t.prototype.onClosed_=function(){this.isClosed_||(this.log_("WebSocket is closing itself"),this.shutdown_(),this.onDisconnect&&(this.onDisconnect(this.everConnected_),this.onDisconnect=null))},t.prototype.close=function(){this.isClosed_||(this.log_("WebSocket is being closed"),this.shutdown_())},t.prototype.resetKeepAlive=function(){var e=this;clearInterval(this.keepaliveTimer),this.keepaliveTimer=setInterval((function(){e.mySock&&e.sendString_("0"),e.resetKeepAlive()}),Math.floor(45e3))},t.prototype.sendString_=function(e){try{this.mySock.send(e)}catch(t){this.log_("Exception thrown from WebSocket.send():",t.message||t.data,"Closing connection."),setTimeout(this.onClosed_.bind(this),0)}},t.responsesRequiredToBeHealthy=2,t.healthyTimeout=3e4,t}(),Jt=function(){function e(e){this.initTransports_(e)}return Object.defineProperty(e,"ALL_TRANSPORTS",{get:function(){return[Ht,Xt]},enumerable:!1,configurable:!0}),e.prototype.initTransports_=function(t){var n,r,o=Xt&&Xt.isAvailable(),a=o&&!Xt.previouslyFailed();if(t.webSocketOnly&&(o||S("wss:// URL used, but browser isn't known to support websockets. Trying anyway."),a=!0),a)this.transports_=[Xt];else{var s=this.transports_=[];try{for(var l=Object(i.g)(e.ALL_TRANSPORTS),u=l.next();!u.done;u=l.next()){var c=u.value;c&&c.isAvailable()&&s.push(c)}}catch(f){n={error:f}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}},e.prototype.initialTransport=function(){if(this.transports_.length>0)return this.transports_[0];throw new Error("No transports available")},e.prototype.upgradeTransport=function(){return this.transports_.length>1?this.transports_[1]:null},e}(),Zt=function(){function e(e,t,n,r,i,o,a,s){this.id=e,this.repoInfo_=t,this.applicationId_=n,this.onMessage_=r,this.onReady_=i,this.onDisconnect_=o,this.onKill_=a,this.lastSessionId=s,this.connectionCount=0,this.pendingDataMessages=[],this.state_=0,this.log_=w("c:"+this.id+":"),this.transportManager_=new Jt(t),this.log_("Connection created"),this.start_()}return e.prototype.start_=function(){var e=this,t=this.transportManager_.initialTransport();this.conn_=new t(this.nextTransportId_(),this.repoInfo_,this.applicationId_,void 0,this.lastSessionId),this.primaryResponsesRequired_=t.responsesRequiredToBeHealthy||0;var n=this.connReceiver_(this.conn_),r=this.disconnReceiver_(this.conn_);this.tx_=this.conn_,this.rx_=this.conn_,this.secondaryConn_=null,this.isHealthy_=!1,setTimeout((function(){e.conn_&&e.conn_.open(n,r)}),Math.floor(0));var i=t.healthyTimeout||0;i>0&&(this.healthyTimeout_=M((function(){e.healthyTimeout_=null,e.isHealthy_||(e.conn_&&e.conn_.bytesReceived>
2102400?(e.log_("Connection exceeded healthy timeout but has received "+e.conn_.bytesReceived+" bytes. Marking connection healthy."),e.isHealthy_=!0,e.conn_.markConnectionHealthy()):e.conn_&&e.conn_.bytesSent>10240?e.log_("Connection exceeded healthy timeout but has sent "+e.conn_.bytesSent+" bytes. Leaving connection alive."):(e.log_("Closing unhealthy connection after timeout."),e.close()))}),Math.floor(i)))},e.prototype.nextTransportId_=function(){return"c:"+this.id+":"+this.connectionCount++},e.prototype.disconnReceiver_=function(e){var t=this;return function(n){e===t.conn_?t.onConnectionLost_(n):e===t.secondaryConn_?(t.log_("Secondary connection lost."),t.onSecondaryConnectionLost_()):t.log_("closing an old connection")}},e.prototype.connReceiver_=function(e){var t=this;return function(n){2!==t.state_&&(e===t.rx_?t.onPrimaryMessageReceived_(n):e===t.secondaryConn_?t.onSecondaryMessageReceived_(n):t.log_("message on old connection"))}},e.prototype.sendRequest=function(e){var t={t:"d",d:e};this.sendData_(t)},e.prototype.tryCleanupConnection=function(){this.tx_===this.secondaryConn_&&this.rx_===this.secondaryConn_&&(this.log_("cleaning up and promoting a connection: "+this.secondaryConn_.connId),this.conn_=this.secondaryConn_,this.secondaryConn_=null)},e.prototype.onSecondaryControl_=function(e){if("t"in e){var t=e.t;"a"===t?this.upgradeIfSecondaryHealthy_():"r"===t?(this.log_("Got a reset on secondary, closing it"),this.secondaryConn_.close(),this.tx_!==this.secondaryConn_&&this.rx_!==this.secondaryConn_||this.close()):"o"===t&&(this.log_("got pong on secondary."),this.secondaryResponsesRequired_--,this.upgradeIfSecondaryHealthy_())}},e.prototype.onSecondaryMessageReceived_=function(e){var t=P("t",e),n=P("d",e);if("c"===t)this.onSecondaryControl_(n);else{if("d"!==t)throw new Error("Unknown protocol layer: "+t);this.pendingDataMessages.push(n)}},e.prototype.upgradeIfSecondaryHealthy_=function(){this.secondaryResponsesRequired_<=0?(this.log_("Secondary connection is healthy."),this.isHealthy_=!0,this.secondaryConn_.markConnectionHealthy(),this.proceedWithUpgrade_()):(this.log_("sending ping on secondary."),this.secondaryConn_.send({t:"c",d:{t:"p",d:{}}}))},e.prototype.proceedWithUpgrade_=function(){this.secondaryConn_.start(),this.log_("sending client ack on secondary"),this.secondaryConn_.send({t:"c",d:{t:"a",d:{}}}),this.log_("Ending transmission on primary"),this.conn_.send({t:"c",d:{t:"n",d:{}}}),this.tx_=this.secondaryConn_,this.tryCleanupConnection()},e.prototype.onPrimaryMessageReceived_=function(e){var t=P("t",e),n=P("d",e);"c"===t?this.onControl_(n):"d"===t&&this.onDataMessage_(n)},e.prototype.onDataMessage_=function(e){this.onPrimaryResponse_(),this.onMessage_(e)},e.prototype.onPrimaryResponse_=function(){this.isHealthy_||(this.primaryResponsesRequired_--,this.primaryResponsesRequired_<=0&&(this.log_("Primary connection is healthy."),this.isHealthy_=!0,this.conn_.markConnectionHealthy()))},e.prototype.onControl_=function(e){var t=P("t",e);if("d"in e){var n=e.d;if("h"===t)this.onHandshake_(n);else if("n"===t){this.log_("recvd end transmission on primary"),this.rx_=this.secondaryConn_;for(var r=0;r<this.pendingDataMessages.length;++r)this.onDataMessage_(this.pendingDataMessages[r]);this.pendingDataMessages=[],this.tryCleanupConnection()}else"s"===t?this.onConnectionShutdown_(n):"r"===t?this.onReset_(n):"e"===t?E("Server Error: "+n):"o"===t?(this.log_("got pong on primary."),this.onPrimaryResponse_(),this.sendPingOnPrimaryIfNecessary_()):E("Unknown control packet command: "+t)}},e.prototype.onHandshake_=function(e){var t=e.ts,n=e.v,r=e.h;this.sessionId=e.s,this.repoInfo_.updateHost(r),0===this.state_&&(this.conn_.start(),this.onConnectionEstablished_(this.conn_,t),z!==n&&S("Protocol version mismatch detected"),this.tryStartUpgrade_())},e.prototype.tryStartUpgrade_=function(){var e=this.transportManager_.upgradeTransport();e&&this.startUpgrade_(e)},e.prototype.startUpgrade_=function(e){var t=this;this.secondaryConn_=new e(this.nextTransportId_(),this.repoInfo_,this.applicationId_,this.sessionId),this.secondaryResponsesRequired_=e.responsesRequiredToBeHealthy||0;var n=this.connReceiver_(this.secondaryConn_),r=this.disconnReceiver_(this.secondaryConn_);this.secondaryConn_.open(n,r),M((function(){t.secondaryConn_&&(t.log_("Timed out trying to upgrade."),t.secondaryConn_.close())}),Math.floor(6e4))},e.prototype.onReset_=function(e){this.log_("Reset packet received. New host: "+e),this.repoInfo_.updateHost(e),1===this.state_?this.close():(this.closeConnections_(),this.start_())},e.prototype.onConnectionEstablished_=function(e,t){var n=this;this.log_("Realtime connection established."),this.conn_=e,this.state_=1,this.onReady_&&(this.onReady_(t,this.sessionId),this.onReady_=null),0===this.primaryResponsesRequired_?(this.log_("Primary connection is healthy."),this.isHealthy_=!0):M((function(){n.sendPingOnPrimaryIfNecessary_()}),Math.floor(5e3))},e.prototype.sendPingOnPrimaryIfNecessary_=function(){this.isHealthy_||1!==this.state_||(this.log_("sending ping on primary."),this.sendData_({t:"c",d:{t:"p",d:{}}}))},e.prototype.onSecondaryConnectionLost_=function(){var e=this.secondaryConn_;this.secondaryConn_=null,this.tx_!==e&&this.rx_!==e||this.close()},e.prototype.onConnectionLost_=function(e){this.conn_=null,e||0!==this.state_?1===this.state_&&this.log_("Realtime connection lost."):(this.log_("Realtime connection failed."),this.repoInfo_.isCacheableHost()&&(f.remove("host:"+this.repoInfo_.host),this.repoInfo_.internalHost=this.repoInfo_.host)),this.close()},e.prototype.onConnectionShutdown_=function(e){this.log_("Connection shutdown command received. Shutting down..."),this.onKill_&&(this.onKill_(e),this.onKill_=null),this.onDisconnect_=null,this.close()},e.prototype.sendData_=function(e){if(1!==this.state_)throw"Connection is not connected";this.tx_.send(e)},e.prototype.close=function(){2!==this.state_&&(this.log_("Closing realtime connection."),this.state_=2,this.closeConnections_(),this.onDisconnect_&&(this.onDisconnect_(),this.onDisconnect_=null))},e.prototype.closeConnections_=function(){this.log_("Shutting down all connections"),this.conn_&&(this.conn_.close(),this.conn_=null),this.secondaryConn_&&(this.secondaryConn_.close(),this.secondaryConn_=null),this.healthyTimeout_&&(clearTimeout(this.healthyTimeout_),this.healthyTimeout_=null)},e}(),en=function(){function e(){}return e.prototype.put=function(e,t,n,r){},e.prototype.merge=function(e,t,n,r){},e.prototype.refreshAuthToken=function(e){},e.prototype.onDisconnectPut=function(e,t,n){},e.prototype.onDisconnectMerge=function(e,t,n){},e.prototype.onDisconnectCancel=function(e,t){},e.prototype.reportStats=function(e){},e}(),tn=1e3,nn=function(e){function t(n,r,i,a,s,l,u){var c=e.call(this)||this;if(c.repoInfo_=n,c.applicationId_=r,c.onDataUpdate_=i,c.onConnectStatus_=a,c.onServerInfoUpdate_=s,c.authTokenProvider_=l,c.authOverride_=u,c.id=t.nextPersistentConnectionId_++,c.log_=w("p:"+c.id+":"),c.interruptReasons_={},c.listens=new Map,c.outstandingPuts_=[],c.outstandingGets_=[],c.outstandingPutCount_=0,c.outstandingGetCount_=0,c.onDisconnectRequestQueue_=[],c.connected_=!1,c.reconnectDelay_=tn,c.maxReconnectDelay_=3e5,c.securityDebugCallback_=null,c.lastSessionId=null,c.establishConnectionTimer_=null,c.visible_=!1,
2c.requestCBHash_={},c.requestNumber_=0,c.realtime_=null,c.authToken_=null,c.forceTokenRefresh_=!1,c.invalidAuthTokenCount_=0,c.firstConnection_=!0,c.lastConnectionAttemptTime_=null,c.lastConnectionEstablishedTime_=null,u&&!Object(o.r)())throw new Error("Auth override specified in options, but not supported on non Node.js platforms");return c.scheduleConnect_(0),zt.getInstance().on("visible",c.onVisible_,c),-1===n.host.indexOf("fblocal")&&Bt.getInstance().on("online",c.onOnline_,c),c}return Object(i.c)(t,e),t.prototype.sendRequest=function(e,t,n){var r=++this.requestNumber_,i={r:r,a:e,b:t};this.log_(Object(o.A)(i)),Object(o.d)(this.connected_,"sendRequest call when we're not connected not allowed."),this.realtime_.sendRequest(i),n&&(this.requestCBHash_[r]=n)},t.prototype.get=function(e){var t=this,n=new o.a,r={p:e.path.toString(),q:e.queryObject()},i={action:"g",request:r,onComplete:function(e){var i=e.d;"ok"===e.s?(t.onDataUpdate_(r.p,i,!1,null),n.resolve(i)):n.reject(i)}};this.outstandingGets_.push(i),this.outstandingGetCount_++;var a=this.outstandingGets_.length-1;return this.connected_||setTimeout((function(){var e=t.outstandingGets_[a];void 0!==e&&i===e&&(delete t.outstandingGets_[a],t.outstandingGetCount_--,0===t.outstandingGetCount_&&(t.outstandingGets_=[]),t.log_("get "+a+" timed out on connection"),n.reject(new Error("Client is offline.")))}),3e3),this.connected_&&this.sendGet_(a),n.promise},t.prototype.listen=function(e,t,n,r){var i=e.queryIdentifier(),a=e.path.toString();this.log_("Listen called for "+a+" "+i),this.listens.has(a)||this.listens.set(a,new Map),Object(o.d)(e.getQueryParams().isDefault()||!e.getQueryParams().loadsAllData(),"listen() called for non-default but complete query"),Object(o.d)(!this.listens.get(a).has(i),"listen() called twice for same path/queryId.");var s={onComplete:r,hashFn:t,query:e,tag:n};this.listens.get(a).set(i,s),this.connected_&&this.sendListen_(s)},t.prototype.sendGet_=function(e){var t=this,n=this.outstandingGets_[e];this.sendRequest("g",n.request,(function(r){delete t.outstandingGets_[e],t.outstandingGetCount_--,0===t.outstandingGetCount_&&(t.outstandingGets_=[]),n.onComplete&&n.onComplete(r)}))},t.prototype.sendListen_=function(e){var n=this,r=e.query,i=r.path.toString(),o=r.queryIdentifier();this.log_("Listen on "+i+" for "+o);var a={p:i};e.tag&&(a.q=r.queryObject(),a.t=e.tag),a.h=e.hashFn(),this.sendRequest("q",a,(function(a){var s=a.d,l=a.s;t.warnOnListenWarnings_(s,r),(n.listens.get(i)&&n.listens.get(i).get(o))===e&&(n.log_("listen response",a),"ok"!==l&&n.removeListen_(i,o),e.onComplete&&e.onComplete(l,s))}))},t.warnOnListenWarnings_=function(e,t){if(e&&"object"===typeof e&&Object(o.h)(e,"w")){var n=Object(o.x)(e,"w");if(Array.isArray(n)&&~n.indexOf("no_index")){var r='".indexOn": "'+t.getQueryParams().getIndex().toString()+'"',i=t.path.toString();S("Using an unspecified index. Your data will be downloaded and filtered on the client. Consider adding "+r+" at "+i+" to your security rules for better performance.")}}},t.prototype.refreshAuthToken=function(e){this.authToken_=e,this.log_("Auth token refreshed"),this.authToken_?this.tryAuth():this.connected_&&this.sendRequest("unauth",{},(function(){})),this.reduceReconnectDelayIfAdminCredential_(e)},t.prototype.reduceReconnectDelayIfAdminCredential_=function(e){(e&&40===e.length||Object(o.m)(e))&&(this.log_("Admin auth credential detected. Reducing max reconnect time."),this.maxReconnectDelay_=3e4)},t.prototype.tryAuth=function(){var e=this;if(this.connected_&&this.authToken_){var t=this.authToken_,n=Object(o.t)(t)?"auth":"gauth",r={cred:t};null===this.authOverride_?r.noauth=!0:"object"===typeof this.authOverride_&&(r.authvar=this.authOverride_),this.sendRequest(n,r,(function(n){var r=n.s,i=n.d||"error";e.authToken_===t&&("ok"===r?e.invalidAuthTokenCount_=0:e.onAuthRevoked_(r,i))}))}},t.prototype.unlisten=function(e,t){var n=e.path.toString(),r=e.queryIdentifier();this.log_("Unlisten called for "+n+" "+r),Object(o.d)(e.getQueryParams().isDefault()||!e.getQueryParams().loadsAllData(),"unlisten() called for non-default but complete query"),this.removeListen_(n,r)&&this.connected_&&this.sendUnlisten_(n,r,e.queryObject(),t)},t.prototype.sendUnlisten_=function(e,t,n,r){this.log_("Unlisten on "+e+" for "+t);var i={p:e};r&&(i.q=n,i.t=r),this.sendRequest("n",i)},t.prototype.onDisconnectPut=function(e,t,n){this.connected_?this.sendOnDisconnect_("o",e,t,n):this.onDisconnectRequestQueue_.push({pathString:e,action:"o",data:t,onComplete:n})},t.prototype.onDisconnectMerge=function(e,t,n){this.connected_?this.sendOnDisconnect_("om",e,t,n):this.onDisconnectRequestQueue_.push({pathString:e,action:"om",data:t,onComplete:n})},t.prototype.onDisconnectCancel=function(e,t){this.connected_?this.sendOnDisconnect_("oc",e,null,t):this.onDisconnectRequestQueue_.push({pathString:e,action:"oc",data:null,onComplete:t})},t.prototype.sendOnDisconnect_=function(e,t,n,r){var i={p:t,d:n};this.log_("onDisconnect "+e,i),this.sendRequest(e,i,(function(e){r&&setTimeout((function(){r(e.s,e.d)}),Math.floor(0))}))},t.prototype.put=function(e,t,n,r){this.putInternal("p",e,t,n,r)},t.prototype.merge=function(e,t,n,r){this.putInternal("m",e,t,n,r)},t.prototype.putInternal=function(e,t,n,r,i){var o={p:t,d:n};void 0!==i&&(o.h=i),this.outstandingPuts_.push({action:e,request:o,onComplete:r}),this.outstandingPutCount_++;var a=this.outstandingPuts_.length-1;this.connected_?this.sendPut_(a):this.log_("Buffering put: "+t)},t.prototype.sendPut_=function(e){var t=this,n=this.outstandingPuts_[e].action,r=this.outstandingPuts_[e].request,i=this.outstandingPuts_[e].onComplete;this.outstandingPuts_[e].queued=this.connected_,this.sendRequest(n,r,(function(r){t.log_(n+" response",r),delete t.outstandingPuts_[e],t.outstandingPutCount_--,0===t.outstandingPutCount_&&(t.outstandingPuts_=[]),i&&i(r.s,r.d)}))},t.prototype.reportStats=function(e){var t=this;if(this.connected_){var n={c:e};this.log_("reportStats",n),this.sendRequest("s",n,(function(e){if("ok"!==e.s){var n=e.d;t.log_("reportStats","Error sending stats: "+n)}}))}},t.prototype.onDataMessage_=function(e){if("r"in e){this.log_("from server: "+Object(o.A)(e));var t=e.r,n=this.requestCBHash_[t];n&&(delete this.requestCBHash_[t],n(e.b))}else{if("error"in e)throw"A server-side error has occurred: "+e.error;"a"in e&&this.onDataPush_(e.a,e.b)}},t.prototype.onDataPush_=function(e,t){this.log_("handleServerMessage",e,t),"d"===e?this.onDataUpdate_(t.p,t.d,!1,t.t):"m"===e?this.onDataUpdate_(t.p,t.d,!0,t.t):"c"===e?this.onListenRevoked_(t.p,t.q):"ac"===e?this.onAuthRevoked_(t.s,t.d):"sd"===e?this.onSecurityDebugPacket_(t):E("Unrecognized action received from server: "+Object(o.A)(e)+"\nAre you using the latest client?")},t.prototype.onReady_=function(e,t){this.log_("connection ready"),this.connected_=!0,this.lastConnectionEstablishedTime_=(new Date).getTime(),this.handleTimestamp_(e),this.lastSessionId=t,this.firstConnection_&&this.sendConnectStats_(),this.restoreState_(),this.firstConnection_=!1,this.onConnectStatus_(!0)},t.prototype.scheduleConnect_=function(e){var t=this;Object(o.d)(!this.realtime_,"Scheduling a connect when we're already connected/ing?"),this.establishConnectionTimer_&&clearTimeout(this.establishConnectionTimer_),this.establishConnectionTimer_=setTimeout((function(){t.establishConnectionTimer_=null,t.establishConnection_()}),Math.floor(e))},t.prototype.onVisible_=function(e){e&&!this.visible_&&this.reconnectDelay_===this.maxReconnectDelay_&&(this.log_("Window became visible. Reducing delay."),this.reconnectDelay_=tn,this.realtime_||this.scheduleConnect_(0)),this.visible_=e},t.prototype.onOnline_=function(e){e?(this.log_("Browser went online."),this.reconnectDelay_=tn,this.realtime_||this.scheduleConnect_(0)):(this.log_("Browser went offline. Killing connection."),this.realtime_&&this.realtime_.close())},t.prototype.onRealtimeDisconnect_=function(){if(this.log_("data client disconnected"),this.connected_=!1,this.realtime_=null,this.cancelSentTransactions_(),this.requestCBHash_={},this.shouldReconnect_()){if(this.visible_){if(this.lastConnectionEstablishedTime_){(new Date).getTime()-this.lastConnectionEstablishedTime_>3e4&&(this.reconnectDelay_=tn),this.lastConnectionEstablishedTime_=null}}else this.log_("Window isn't visible. Delaying reconnect."),this.reconnectDelay_=this.maxReconnectDelay_,this.lastConnectionAttemptTime_=(new Date).getTime();var e=(new Date).getTime()-this.lastConnectionAttemptTime_,t=Math.max(0,this.reconnectDelay_-e);
2t=Math.random()*t,this.log_("Trying to reconnect in "+t+"ms"),this.scheduleConnect_(t),this.reconnectDelay_=Math.min(this.maxReconnectDelay_,1.3*this.reconnectDelay_)}this.onConnectStatus_(!1)},t.prototype.establishConnection_=function(){var e=this;if(this.shouldReconnect_()){this.log_("Making a connection attempt"),this.lastConnectionAttemptTime_=(new Date).getTime(),this.lastConnectionEstablishedTime_=null;var n=this.onDataMessage_.bind(this),r=this.onReady_.bind(this),i=this.onRealtimeDisconnect_.bind(this),a=this.id+":"+t.nextConnectionId_++,s=this,l=this.lastSessionId,u=!1,c=null,f=function(){c?c.close():(u=!0,i())};this.realtime_={close:f,sendRequest:function(e){Object(o.d)(c,"sendRequest call when we're not connected not allowed."),c.sendRequest(e)}};var h=this.forceTokenRefresh_;this.forceTokenRefresh_=!1,this.authTokenProvider_.getToken(h).then((function(e){u?b("getToken() completed but was canceled"):(b("getToken() completed. Creating connection."),s.authToken_=e&&e.accessToken,c=new Zt(a,s.repoInfo_,s.applicationId_,n,r,i,(function(e){S(e+" ("+s.repoInfo_.toString()+")"),s.interrupt("server_kill")}),l))})).then(null,(function(t){s.log_("Failed to get token: "+t),u||(e.repoInfo_.nodeAdmin&&S(t),f())}))}},t.prototype.interrupt=function(e){b("Interrupting connection for reason: "+e),this.interruptReasons_[e]=!0,this.realtime_?this.realtime_.close():(this.establishConnectionTimer_&&(clearTimeout(this.establishConnectionTimer_),this.establishConnectionTimer_=null),this.connected_&&this.onRealtimeDisconnect_())},t.prototype.resume=function(e){b("Resuming connection for reason: "+e),delete this.interruptReasons_[e],Object(o.o)(this.interruptReasons_)&&(this.reconnectDelay_=tn,this.realtime_||this.scheduleConnect_(0))},t.prototype.handleTimestamp_=function(e){var t=e-(new Date).getTime();this.onServerInfoUpdate_({serverTimeOffset:t})},t.prototype.cancelSentTransactions_=function(){for(var e=0;e<this.outstandingPuts_.length;e++){var t=this.outstandingPuts_[e];t&&"h"in t.request&&t.queued&&(t.onComplete&&t.onComplete("disconnect"),delete this.outstandingPuts_[e],this.outstandingPutCount_--)}0===this.outstandingPutCount_&&(this.outstandingPuts_=[])},t.prototype.onListenRevoked_=function(e,t){var n;n=t?t.map((function(e){return I(e)})).join("$"):"default";var r=this.removeListen_(e,n);r&&r.onComplete&&r.onComplete("permission_denied")},t.prototype.removeListen_=function(e,t){var n,r=new U(e).toString();if(this.listens.has(r)){var i=this.listens.get(r);n=i.get(t),i.delete(t),0===i.size&&this.listens.delete(r)}else n=void 0;return n},t.prototype.onAuthRevoked_=function(e,t){b("Auth token revoked: "+e+"/"+t),this.authToken_=null,this.forceTokenRefresh_=!0,this.realtime_.close(),"invalid_token"!==e&&"permission_denied"!==e||(this.invalidAuthTokenCount_++,this.invalidAuthTokenCount_>=3&&(this.reconnectDelay_=3e4,this.authTokenProvider_.notifyForInvalidToken()))},t.prototype.onSecurityDebugPacket_=function(e){this.securityDebugCallback_?this.securityDebugCallback_(e):"msg"in e&&console.log("FIREBASE: "+e.msg.replace("\n","\nFIREBASE: "))},t.prototype.restoreState_=function(){var e,t,n,r;this.tryAuth();try{for(var o=Object(i.g)(this.listens.values()),a=o.next();!a.done;a=o.next()){var s=a.value;try{for(var l=(n=void 0,Object(i.g)(s.values())),u=l.next();!u.done;u=l.next()){var c=u.value;this.sendListen_(c)}}catch(d){n={error:d}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}}catch(p){e={error:p}}finally{try{a&&!a.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}for(var f=0;f<this.outstandingPuts_.length;f++)this.outstandingPuts_[f]&&this.sendPut_(f);for(;this.onDisconnectRequestQueue_.length;){var h=this.onDisconnectRequestQueue_.shift();this.sendOnDisconnect_(h.action,h.pathString,h.data,h.onComplete)}for(f=0;f<this.outstandingGets_.length;f++)this.outstandingGets_[f]&&this.sendGet_(f)},t.prototype.sendConnectStats_=function(){var e={},t="js";Object(o.r)()&&(t=this.repoInfo_.nodeAdmin?"admin_node":"node"),e["sdk."+t+"."+Yt.replace(/\./g,"-")]=1,Object(o.p)()?e["framework.cordova"]=1:Object(o.s)()&&(e["framework.reactnative"]=1),this.reportStats(e)},t.prototype.shouldReconnect_=function(){var e=Bt.getInstance().currentlyOnline();return Object(o.o)(this.interruptReasons_)&&e},t.nextPersistentConnectionId_=0,t.nextConnectionId_=0,t}
2(en),rn=function(e){function t(t,n,r){var i=e.call(this)||this;return i.repoInfo_=t,i.onDataUpdate_=n,i.authTokenProvider_=r,i.log_=w("p:rest:"),i.listens_={},i}return Object(i.c)(t,e),t.prototype.reportStats=function(e){throw new Error("Method not implemented.")},t.getListenId_=function(e,t){return void 0!==t?"tag$"+t:(Object(o.d)(e.getQueryParams().isDefault(),"should have a tag if it's not a default query."),e.path.toString())},t.prototype.listen=function(e,n,r,i){var a=this,s=e.path.toString();this.log_("Listen called for "+s+" "+e.queryIdentifier());var l=t.getListenId_(e,r),u={};this.listens_[l]=u;var c=e.getQueryParams().toRestQueryStringParameters();this.restRequest_(s+".json",c,(function(e,t){var n=t;(404===e&&(n=null,e=null),null===e&&a.onDataUpdate_(s,n,!1,r),Object(o.x)(a.listens_,l)===u)&&i(e?401===e?"permission_denied":"rest_error:"+e:"ok",null)}))},t.prototype.unlisten=function(e,n){var r=t.getListenId_(e,n);delete this.listens_[r]},t.prototype.get=function(e){var t=this,n=e.getQueryParams().toRestQueryStringParameters(),r=e.path.toString(),i=new o.a;return this.restRequest_(r+".json",n,(function(e,n){var o=n;404===e&&(o=null,e=null),null===e?(t.onDataUpdate_(r,o,!1,null),i.resolve(o)):i.reject(new Error(o))})),i.promise},t.prototype.refreshAuthToken=function(e){},t.prototype.restRequest_=function(e,t,n){var r=this;void 0===t&&(t={}),t.format="export",this.authTokenProvider_.getToken(!1).then((function(i){var a=i&&i.accessToken;a&&(t.auth=a);var s=(r.repoInfo_.secure?"https://":"http://")+r.repoInfo_.host+e+"?ns="+r.repoInfo_.namespace+Object(o.w)(t);r.log_("Sending REST request for "+s);var l=new XMLHttpRequest;l.onreadystatechange=function(){if(n&&4===l.readyState){r.log_("REST Response for "+s+" received. status:",l.status,"response:",l.responseText);var e=null;if(l.status>=200&&l.status<300){try{e=Object(o.u)(l.responseText)}catch(t){S("Failed to parse JSON response for "+s+": "+l.responseText)}n(null,e)}else 401!==l.status&&404!==l.status&&S("Got unsuccessful REST response for "+s+" Status: "+l.status),n(l.status);n=null}},l.open("GET",s,!0),l.send()}))},t}(en),on="repo_interrupt",an=function(){function e(e,t,n,r){this.repoInfo_=e,this.forceRestClient_=t,this.app=n,this.authTokenProvider_=r,this.dataUpdateCount=0,this.statsListener_=null,this.eventQueue_=new Mt,this.nextWriteId_=1,this.interceptServerDataCallback_=null,this.onDisconnect_=new st,this.persistentConnection_=null,this.key=this.repoInfo_.toURLString()}return e.prototype.start=function(){var e=this;if(this.stats_=Lt.getCollection(this.repoInfo_),this.forceRestClient_||("object"===typeof window&&window.navigator&&window.navigator.userAgent||"").search(/googlebot|google webmaster tools|bingbot|yahoo! slurp|baiduspider|yandexbot|duckduckbot/i)>=0)this.server_=new rn(this.repoInfo_,this.onDataUpdate_.bind(this),this.authTokenProvider_),setTimeout(this.onConnectStatus_.bind(this,!0),0);else{var t=this.app.options.databaseAuthVariableOverride;if("undefined"!==typeof t&&null!==t){if("object"!==typeof t)throw new Error("Only objects are supported for option databaseAuthVariableOverride");try{Object(o.A)(t)}catch(n){throw new Error("Invalid authOverride provided: "+n)}}this.persistentConnection_=new nn(this.repoInfo_,this.app.options.appId,this.onDataUpdate_.bind(this),this.onConnectStatus_.bind(this),this.onServerInfoUpdate_.bind(this),this.authTokenProvider_,t),this.server_=this.persistentConnection_}this.authTokenProvider_.addTokenChangeListener((function(t){e.server_.refreshAuthToken(t)})),this.statsReporter_=Lt.getOrCreateReporter(this.repoInfo_,(function(){return new Ft(e.stats_,e.server_)})),this.transactionsInit_(),this.infoData_=new Dt,this.infoSyncTree_=new Rt({startListening:function(t,n,r,i){var o=[],a=e.infoData_.getNode(t.path);return a.isEmpty()||(o=e.infoSyncTree_.applyServerOverwrite(t.path,a),setTimeout((function(){i("ok")}),0)),o},stopListening:function(){}}),this.updateInfo_("connected",!1),this.serverSyncTree_=new Rt({startListening:function(t,n,r,i){return e.server_.listen(t,r,n,(function(n,r){var o=i(n,r);e.eventQueue_.raiseEventsForChangedPath(t.path,o)})),[]},stopListening:function(t,n){e.server_.unlisten(t,n)}})},e.prototype.toString=function(){return(this.repoInfo_.secure?"https://":"http://")+this.repoInfo_.host},e.prototype.name=function(){return this.repoInfo_.namespace},e.prototype.serverTime=function(){var e=this.infoData_.getNode(new U(".info/serverTimeOffset")).val()||0;return(new Date).getTime()+e}
2,e.prototype.generateServerValues=function(){return(e=(e={timestamp:this.serverTime()})||{}).timestamp=e.timestamp||(new Date).getTime(),e;var e},e.prototype.onDataUpdate_=function(e,t,n,r){this.dataUpdateCount++;var i=new U(e);t=this.interceptServerDataCallback_?this.interceptServerDataCallback_(e,t):t;var a=[];if(r)if(n){var s=Object(o.v)(t,(function(e){return Be(e)}));a=this.serverSyncTree_.applyTaggedQueryMerge(i,s,r)}else{var l=Be(t);a=this.serverSyncTree_.applyTaggedQueryOverwrite(i,l,r)}else if(n){var u=Object(o.v)(t,(function(e){return Be(e)}));a=this.serverSyncTree_.applyServerMerge(i,u)}else{var c=Be(t);a=this.serverSyncTree_.applyServerOverwrite(i,c)}var f=i;a.length>0&&(f=this.rerunTransactions_(i)),this.eventQueue_.raiseEventsForChangedPath(f,a)},e.prototype.interceptServerData_=function(e){this.interceptServerDataCallback_=e},e.prototype.onConnectStatus_=function(e){this.updateInfo_("connected",e),!1===e&&this.runOnDisconnectEvents_()},e.prototype.onServerInfoUpdate_=function(e){var t=this;D(e,(function(e,n){t.updateInfo_(e,n)}))},e.prototype.updateInfo_=function(e,t){var n=new U("/.info/"+e),r=Be(t);this.infoData_.updateSnapshot(n,r);var i=this.infoSyncTree_.applyServerOverwrite(n,r);this.eventQueue_.raiseEventsForChangedPath(n,i)},e.prototype.getNextWriteId_=function(){return this.nextWriteId_++},e.prototype.getValue=function(e){var t=this;return this.server_.get(e).then((function(n){var r=Be(n),i=t.serverSyncTree_.applyServerOverwrite(e.path,r);return t.eventQueue_.raiseEventsAtPath(e.path,i),Promise.resolve(new He(r,e.getRef(),e.getQueryParams().getIndex()))}),(function(n){t.log_("get for query "+Object(o.A)(e)+" falling back to cache after error: "+n);var r=t.serverSyncTree_.calcCompleteEventCache(e.path);return r.isEmpty()?Promise.reject(new Error(n)):Promise.resolve(new He(r,e.getRef(),e.getQueryParams().getIndex()))}))},e.prototype.setWithPriority=function(e,t,n,r){var i=this;this.log_("set",{path:e.toString(),value:t,priority:n});var o=this.generateServerValues(),a=Be(t,n),s=this.serverSyncTree_.calcCompleteEventCache(e),l=it(a,s,o),u=this.getNextWriteId_(),c=this.serverSyncTree_.applyUserOverwrite(e,l,u,!0);this.eventQueue_.queueEvents(c),this.server_.put(e.toString(),a.val(!0),(function(t,n){var o="ok"===t;o||S("set at "+e+" failed: "+t);var a=i.serverSyncTree_.ackUserWrite(u,!o);i.eventQueue_.raiseEventsForChangedPath(e,a),i.callOnCompleteCallback(r,t,n)}));var f=this.abortTransactions_(e);this.rerunTransactions_(f),this.eventQueue_.raiseEventsForChangedPath(f,[])},e.prototype.update=function(e,t,n){var r=this;this.log_("update",{path:e.toString(),value:t});var i=!0,o=this.generateServerValues(),a={};if(D(t,(function(t,n){i=!1,a[t]=rt(e.child(t),Be(n),r.serverSyncTree_,o)})),i)b("update() called with empty data. Don't do anything."),this.callOnCompleteCallback(n,"ok");else{var s=this.getNextWriteId_(),l=this.serverSyncTree_.applyUserMerge(e,a,s);this.eventQueue_.queueEvents(l),this.server_.merge(e.toString(),t,(function(t,i){var o="ok"===t;o||S("update at "+e+" failed: "+t);var a=r.serverSyncTree_.ackUserWrite(s,!o),l=a.length>0?r.rerunTransactions_(e):e;r.eventQueue_.raiseEventsForChangedPath(l,a),r.callOnCompleteCallback(n,t,i)})),D(t,(function(t){var n=r.abortTransactions_(e.child(t));r.rerunTransactions_(n)})),this.eventQueue_.raiseEventsForChangedPath(e,[])}},e.prototype.runOnDisconnectEvents_=function(){var e=this;this.log_("onDisconnectEvents");var t=this.generateServerValues(),n=new st;this.onDisconnect_.forEachTree(U.Empty,(function(r,i){var o=rt(r,i,e.serverSyncTree_,t);n.remember(r,o)}));var r=[];n.forEachTree(U.Empty,(function(t,n){r=r.concat(e.serverSyncTree_.applyServerOverwrite(t,n));var i=e.abortTransactions_(t);e.rerunTransactions_(i)})),this.onDisconnect_=new st,this.eventQueue_.raiseEventsForChangedPath(U.Empty,r)},e.prototype.onDisconnectCancel=function(e,t){var n=this;this.server_.onDisconnectCancel(e.toString(),(function(r,i){"ok"===r&&n.onDisconnect_.forget(e),n.callOnCompleteCallback(t,r,i)}))},e.prototype.onDisconnectSet=function(e,t,n){var r=this,i=Be(t);this.server_.onDisconnectPut(e.toString(),i.val(!0),(function(t,o){"ok"===t&&r.onDisconnect_.remember(e,i
2),r.callOnCompleteCallback(n,t,o)}))},e.prototype.onDisconnectSetWithPriority=function(e,t,n,r){var i=this,o=Be(t,n);this.server_.onDisconnectPut(e.toString(),o.val(!0),(function(t,n){"ok"===t&&i.onDisconnect_.remember(e,o),i.callOnCompleteCallback(r,t,n)}))},e.prototype.onDisconnectUpdate=function(e,t,n){var r=this;if(Object(o.o)(t))return b("onDisconnect().update() called with empty data. Don't do anything."),void this.callOnCompleteCallback(n,"ok");this.server_.onDisconnectMerge(e.toString(),t,(function(i,o){"ok"===i&&D(t,(function(t,n){var i=Be(n);r.onDisconnect_.remember(e.child(t),i)})),r.callOnCompleteCallback(n,i,o)}))},e.prototype.addEventCallbackForQuery=function(e,t){var n;n=".info"===e.path.getFront()?this.infoSyncTree_.addEventRegistration(e,t):this.serverSyncTree_.addEventRegistration(e,t),this.eventQueue_.raiseEventsAtPath(e.path,n)},e.prototype.removeEventCallbackForQuery=function(e,t){var n;n=".info"===e.path.getFront()?this.infoSyncTree_.removeEventRegistration(e,t):this.serverSyncTree_.removeEventRegistration(e,t),this.eventQueue_.raiseEventsAtPath(e.path,n)},e.prototype.interrupt=function(){this.persistentConnection_&&this.persistentConnection_.interrupt(on)},e.prototype.resume=function(){this.persistentConnection_&&this.persistentConnection_.resume(on)},e.prototype.stats=function(e){if(void 0===e&&(e=!1),"undefined"!==typeof console){var t;e?(this.statsListener_||(this.statsListener_=new At(this.stats_)),t=this.statsListener_.get()):t=this.stats_.get();var n=Object.keys(t).reduce((function(e,t){return Math.max(t.length,e)}),0);D(t,(function(e,t){for(var r=e,i=e.length;i<n+2;i++)r+=" ";console.log(r+t)}))}},e.prototype.statsIncrementCounter=function(e){this.stats_.incrementCounter(e),this.statsReporter_.includeStat(e)},e.prototype.log_=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n="";this.persistentConnection_&&(n=this.persistentConnection_.id+":"),b.apply(void 0,Object(i.f)([n],e))},e.prototype.callOnCompleteCallback=function(e,t,n){e&&F((function(){if("ok"===t)e(null);else{var r=(t||"error").toUpperCase(),i=r;n&&(i+=": "+n);var o=new Error(i);o.code=r,e(o)}}))},Object.defineProperty(e.prototype,"database",{get:function(){return this.__database||(this.__database=new mn(this))},enumerable:!1,configurable:!0}),e}(),sn=function(){function e(t){this.indexedFilter_=new _t(t.getIndex()),this.index_=t.getIndex(),this.startPost_=e.getStartPost_(t),this.endPost_=e.getEndPost_(t)}return e.prototype.getStartPost=function(){return this.startPost_},e.prototype.getEndPost=function(){return this.endPost_},e.prototype.matches=function(e){return this.index_.compare(this.getStartPost(),e)<=0&&this.index_.compare(e,this.getEndPost())<=0},e.prototype.updateChild=function(e,t,n,r,i,o){return this.matches(new ve(t,n))||(n=We.EMPTY_NODE),this.indexedFilter_.updateChild(e,t,n,r,i,o)},e.prototype.updateFullNode=function(e,t,n){t.isLeafNode()&&(t=We.EMPTY_NODE);var r=t.withIndex(this.index_);r=r.updatePriority(We.EMPTY_NODE);var i=this;return t.forEachChild(xe,(function(e,t){i.matches(new ve(e,t))||(r=r.updateImmediateChild(e,We.EMPTY_NODE))})),this.indexedFilter_.updateFullNode(e,r,n)},e.prototype.updatePriority=function(e,t){return e},e.prototype.filtersNodes=function(){return!0},e.prototype.getIndexedFilter=function(){return this.indexedFilter_},e.prototype.getIndex=function(){return this.index_},e.getStartPost_=function(e){if(e.hasStart()){var t=e.getIndexStartName();return e.getIndex().makePost(e.getIndexStartValue(),t)}return e.getIndex().minPost()},e.getEndPost_=function(e){if(e.hasEnd()){var t=e.getIndexEndName();return e.getIndex().makePost(e.getIndexEndValue(),t)}return e.getIndex().maxPost()},e}(),ln=function(){function e(e){this.rangedFilter_=new sn(e),this.index_=e.getIndex(),this.limit_=e.getLimit(),this.reverse_=!e.isViewFromLeft()}return e.prototype.updateChild=function(e,t,n,r,i,o){return this.rangedFilter_.matches(new ve(t,n))||(n=We.EMPTY_NODE),e.getImmediateChild(t).equals(n)?e:e.numChildren()<this.limit_?this.rangedFilter_.getIndexedFilter().updateChild(e,t,n,r,i,o):this.fullLimitUpdate
2Child_(e,t,n,i,o)},e.prototype.updateFullNode=function(e,t,n){var r;if(t.isLeafNode()||t.isEmpty())r=We.EMPTY_NODE.withIndex(this.index_);else if(2*this.limit_<t.numChildren()&&t.isIndexed(this.index_)){r=We.EMPTY_NODE.withIndex(this.index_);var i=void 0;i=this.reverse_?t.getReverseIteratorFrom(this.rangedFilter_.getEndPost(),this.index_):t.getIteratorFrom(this.rangedFilter_.getStartPost(),this.index_);for(var o=0;i.hasNext()&&o<this.limit_;){var a=i.getNext();if(!(this.reverse_?this.index_.compare(this.rangedFilter_.getStartPost(),a)<=0:this.index_.compare(a,this.rangedFilter_.getEndPost())<=0))break;r=r.updateImmediateChild(a.name,a.node),o++}}else{r=(r=t.withIndex(this.index_)).updatePriority(We.EMPTY_NODE);var s=void 0,l=void 0,u=void 0;i=void 0;if(this.reverse_){i=r.getReverseIterator(this.index_),s=this.rangedFilter_.getEndPost(),l=this.rangedFilter_.getStartPost();var c=this.index_.getCompare();u=function(e,t){return c(t,e)}}else i=r.getIterator(this.index_),s=this.rangedFilter_.getStartPost(),l=this.rangedFilter_.getEndPost(),u=this.index_.getCompare();o=0;for(var f=!1;i.hasNext();){a=i.getNext();!f&&u(s,a)<=0&&(f=!0),f&&o<this.limit_&&u(a,l)<=0?o++:r=r.updateImmediateChild(a.name,We.EMPTY_NODE)}}return this.rangedFilter_.getIndexedFilter().updateFullNode(e,r,n)},e.prototype.updatePriority=function(e,t){return e},e.prototype.filtersNodes=function(){return!0},e.prototype.getIndexedFilter=function(){return this.rangedFilter_.getIndexedFilter()},e.prototype.getIndex=function(){return this.index_},e.prototype.fullLimitUpdateChild_=function(e,t,n,r,i){var a;if(this.reverse_){var s=this.index_.getCompare();a=function(e,t){return s(t,e)}}else a=this.index_.getCompare();var l=e;Object(o.d)(l.numChildren()===this.limit_,"");var u=new ve(t,n),c=this.reverse_?l.getFirstChild(this.index_):l.getLastChild(this.index_),f=this.rangedFilter_.matches(u);if(l.hasChild(t)){for(var h=l.getImmediateChild(t),d=r.getChildAfterChild(this.index_,c,this.reverse_);null!=d&&(d.name===t||l.hasChild(d.name));)d=r.getChildAfterChild(this.index_,d,this.reverse_);var p=null==d?1:a(d,u);if(f&&!n.isEmpty()&&p>=0)return null!=i&&i.trackChildChange(mt.childChangedChange(t,n,h)),l.updateImmediateChild(t,n);null!=i&&i.trackChildChange(mt.childRemovedChange(t,h));var y=l.updateImmediateChild(t,We.EMPTY_NODE);return null!=d&&this.rangedFilter_.matches(d)?(null!=i&&i.trackChildChange(mt.childAddedChange(d.name,d.node)),y.updateImmediateChild(d.name,d.node)):y}return n.isEmpty()?e:f&&a(c,u)>=0?(null!=i&&(i.trackChildChange(mt.childRemovedChange(c.name,c.node)),i.trackChildChange(mt.childAddedChange(t,n))),l.updateImmediateChild(t,n).updateImmediateChild(c.name,We.EMPTY_NODE)):e},e}(),un=function(){function e(){this.limitSet_=!1,this.startSet_=!1,this.startNameSet_=!1,this.endSet_=!1,this.endNameSet_=!1,this.limit_=0,this.viewFrom_="",this.indexStartValue_=null,this.indexStartName_="",this.indexEndValue_=null,this.indexEndName_="",this.index_=xe}return e.prototype.hasStart=function(){return this.startSet_},e.prototype.isViewFromLeft=function(){return""===this.viewFrom_?this.startSet_:this.viewFrom_===e.WIRE_PROTOCOL_CONSTANTS_.VIEW_FROM_LEFT},e.prototype.getIndexStartValue=function(){return Object(o.d)(this.startSet_,"Only valid if start has been set"),this.indexStartValue_},e.prototype.getIndexStartName=function(){return Object(o.d)(this.startSet_,"Only valid if start has been set"),this.startNameSet_?this.indexStartName_:T},e.prototype.hasEnd=function(){return this.endSet_},e.prototype.getIndexEndValue=function(){return Object(o.d)(this.endSet_,"Only valid if end has been set"),this.indexEndValue_},e.prototype.getIndexEndName=function(){return Object(o.d)(this.endSet_,"Only valid if end has been set"),this.endNameSet_?this.indexEndName_:k},e.prototype.hasLimit=function(){return this.limitSet_},e.prototype.hasAnchoredLimit=function(){return this.limitSet_&&""!==this.viewFrom_},e.prototype.getLimit=function(){return Object(o.d)(this.limitSet_,"Only valid if limit has been set"),this.limit_},e.prototype.getIndex=function(){return this.index_},e.prototype.copy_=function(){var t=new e;return t.limitSet_=this.limitSet_,t.limit_=this.limit_,t.startSet_=this.startSet_,t.indexStartValue_=this.indexStartValue_,t.startNameSet_=this.startNameSet_,t.indexStartName_=this.indexStartName_,t.endSet_=this.endSet_,t.indexEndValue_=this.indexEndValue_,t.endNameSet_=this.endNameSet_,t.indexEndName_=this.indexEndName_,t.index_
2=this.index_,t.viewFrom_=this.viewFrom_,t},e.prototype.limit=function(e){var t=this.copy_();return t.limitSet_=!0,t.limit_=e,t.viewFrom_="",t},e.prototype.limitToFirst=function(t){var n=this.copy_();return n.limitSet_=!0,n.limit_=t,n.viewFrom_=e.WIRE_PROTOCOL_CONSTANTS_.VIEW_FROM_LEFT,n},e.prototype.limitToLast=function(t){var n=this.copy_();return n.limitSet_=!0,n.limit_=t,n.viewFrom_=e.WIRE_PROTOCOL_CONSTANTS_.VIEW_FROM_RIGHT,n},e.prototype.startAt=function(e,t){var n=this.copy_();return n.startSet_=!0,void 0===e&&(e=null),n.indexStartValue_=e,null!=t?(n.startNameSet_=!0,n.indexStartName_=t):(n.startNameSet_=!1,n.indexStartName_=""),n},e.prototype.endAt=function(e,t){var n=this.copy_();return n.endSet_=!0,void 0===e&&(e=null),n.indexEndValue_=e,void 0!==t?(n.endNameSet_=!0,n.indexEndName_=t):(n.endNameSet_=!1,n.indexEndName_=""),n},e.prototype.orderBy=function(e){var t=this.copy_();return t.index_=e,t},e.prototype.getQueryObject=function(){var t=e.WIRE_PROTOCOL_CONSTANTS_,n={};if(this.startSet_&&(n[t.INDEX_START_VALUE]=this.indexStartValue_,this.startNameSet_&&(n[t.INDEX_START_NAME]=this.indexStartName_)),this.endSet_&&(n[t.INDEX_END_VALUE]=this.indexEndValue_,this.endNameSet_&&(n[t.INDEX_END_NAME]=this.indexEndName_)),this.limitSet_){n[t.LIMIT]=this.limit_;var r=this.viewFrom_;""===r&&(r=this.isViewFromLeft()?t.VIEW_FROM_LEFT:t.VIEW_FROM_RIGHT),n[t.VIEW_FROM]=r}return this.index_!==xe&&(n[t.INDEX]=this.index_.toString()),n},e.prototype.loadsAllData=function(){return!(this.startSet_||this.endSet_||this.limitSet_)},e.prototype.isDefault=function(){return this.loadsAllData()&&this.index_===xe},e.prototype.getNodeFilter=function(){return this.loadsAllData()?new _t(this.getIndex()):this.hasLimit()?new ln(this):new sn(this)},e.prototype.toRestQueryStringParameters=function(){var t,n=e.REST_QUERY_CONSTANTS_,r={};return this.isDefault()||(this.index_===xe?t=n.PRIORITY_INDEX:this.index_===Ve?t=n.VALUE_INDEX:this.index_===_e?t=n.KEY_INDEX:(Object(o.d)(this.index_ instanceof Qe,"Unrecognized index type!"),t=this.index_.toString()),r[n.ORDER_BY]=Object(o.A)(t),this.startSet_&&(r[n.START_AT]=Object(o.A)(this.indexStartValue_),this.startNameSet_&&(r[n.START_AT]+=","+Object(o.A)(this.indexStartName_))),this.endSet_&&(r[n.END_AT]=Object(o.A)(this.indexEndValue_),this.endNameSet_&&(r[n.END_AT]+=","+Object(o.A)(this.indexEndName_))),this.limitSet_&&(this.isViewFromLeft()?r[n.LIMIT_TO_FIRST]=this.limit_:r[n.LIMIT_TO_LAST]=this.limit_)),r},e.WIRE_PROTOCOL_CONSTANTS_={INDEX_START_VALUE:"sp",INDEX_START_NAME:"sn",INDEX_END_VALUE:"ep",INDEX_END_NAME:"en",LIMIT:"l",VIEW_FROM:"vf",VIEW_FROM_LEFT:"l",VIEW_FROM_RIGHT:"r",INDEX:"i"},e.REST_QUERY_CONSTANTS_={ORDER_BY:"orderBy",PRIORITY_INDEX:"$priority",VALUE_INDEX:"$value",KEY_INDEX:"$key",START_AT:"startAt",END_AT:"endAt",LIMIT_TO_FIRST:"limitToFirst",LIMIT_TO_LAST:"limitToLast"},e.DEFAULT=new e,e}(),cn=function(e){function t(t,n){if(!(t instanceof an))throw new Error("new Reference() no longer supported - use app.database().");return e.call(this,t,n,un.DEFAULT,!1)||this}return Object(i.c)(t,e),t.prototype.getKey=function(){return Object(o.B)("Reference.key",0,0,arguments.length),this.path.isEmpty()?null:this.path.getBack()},t.prototype.child=function(e){return Object(o.B)("Reference.child",1,1,arguments.length),"number"===typeof e?e=String(e):e instanceof U||(null===this.path.getFront()?ue("Reference.child",1,e,!1):le("Reference.child",1,e,!1)),new t(this.repo,this.path.child(e))},t.prototype.getParent=function(){Object(o.B)("Reference.parent",0,0,arguments.length);var e=this.path.parent();return null===e?null:new t(this.repo,e)},t.prototype.getRoot=function(){Object(o.B)("Reference.root",0,0,arguments.length);for(var e=this;null!==e.getParent();)e=e.getParent();return e},t.prototype.databaseProp=function(){return this.repo.database},t.prototype.set=function(e,t){Object(o.B)("Reference.set",1,2,arguments.length),ce("Reference.set",this.path),ne("Reference.set",1,e,this.path,!1),Object(o.C)("Reference.set",2,t,!0);var n=new o.a;return this.repo.setWithPriority(this.path,e,null,n.wrapCallback(t)),n.promise},t.prototype.update=function(e,t){if(Object(o.B)("Reference.update",1,2,arguments.length),ce("Reference.update",this.path),Array.isArray(e)){for(var n={},r=0;r<e.length;++r)n[""+r]=e[r];
2e=n,S("Passing an Array to Firebase.update() is deprecated. Use set() if you want to overwrite the existing data, or an Object with integer keys if you really do want to only update some of the children.")}ie("Reference.update",1,e,this.path,!1),Object(o.C)("Reference.update",2,t,!0);var i=new o.a;return this.repo.update(this.path,e,i.wrapCallback(t)),i.promise},t.prototype.setWithPriority=function(e,t,n){if(Object(o.B)("Reference.setWithPriority",2,3,arguments.length),ce("Reference.setWithPriority",this.path),ne("Reference.setWithPriority",1,e,this.path,!1),oe("Reference.setWithPriority",2,t,!1),Object(o.C)("Reference.setWithPriority",3,n,!0),".length"===this.getKey()||".keys"===this.getKey())throw"Reference.setWithPriority failed: "+this.getKey()+" is a read-only object.";var r=new o.a;return this.repo.setWithPriority(this.path,e,t,r.wrapCallback(n)),r.promise},t.prototype.remove=function(e){return Object(o.B)("Reference.remove",0,1,arguments.length),ce("Reference.remove",this.path),Object(o.C)("Reference.remove",1,e,!0),this.set(null,e)},t.prototype.transaction=function(e,t,n){if(Object(o.B)("Reference.transaction",1,3,arguments.length),ce("Reference.transaction",this.path),Object(o.C)("Reference.transaction",1,e,!1),Object(o.C)("Reference.transaction",2,t,!0),he("Reference.transaction",3,n,!0),".length"===this.getKey()||".keys"===this.getKey())throw"Reference.transaction failed: "+this.getKey()+" is a read-only object.";void 0===n&&(n=!0);var r=new o.a;"function"===typeof t&&r.promise.catch((function(){}));var i=function(e,n,i){e?r.reject(e):r.resolve(new pe(n,i)),"function"===typeof t&&t(e,n,i)};return this.repo.startTransaction(this.path,e,i,n),r.promise},t.prototype.setPriority=function(e,t){Object(o.B)("Reference.setPriority",1,2,arguments.length),ce("Reference.setPriority",this.path),oe("Reference.setPriority",1,e,!1),Object(o.C)("Reference.setPriority",2,t,!0);var n=new o.a;return this.repo.setWithPriority(this.path.child(".priority"),e,null,n.wrapCallback(t)),n.promise},t.prototype.push=function(e,t){Object(o.B)("Reference.push",0,2,arguments.length),ce("Reference.push",this.path),ne("Reference.push",1,e,this.path,!0),Object(o.C)("Reference.push",2,t,!0);var n,r=this.repo.serverTime(),i=ye(r),a=this.child(i),s=this.child(i);return n=null!=e?a.set(e,t).then((function(){return s})):Promise.resolve(s),a.then=n.then.bind(n),a.catch=n.then.bind(n,void 0),"function"===typeof t&&n.catch((function(){})),a},t.prototype.onDisconnect=function(){return ce("Reference.onDisconnect",this.path),new de(this.repo,this.path)},Object.defineProperty(t.prototype,"database",{get:function(){return this.databaseProp()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"key",{get:function(){return this.getKey()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parent",{get:function(){return this.getParent()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"root",{get:function(){return this.getRoot()},enumerable:!1,configurable:!0}),t}(Xe);Xe.__referenceConstructor=cn,kt.__referenceConstructor=cn;var fn,hn=function(){this.children={},this.childCount=0,this.value=null},dn=function(){function e(e,t,n){void 0===e&&(e=""),void 0===t&&(t=null),void 0===n&&(n=new hn),this.name_=e,this.parent_=t,this.node_=n}return e.prototype.subTree=function(t){for(var n=t instanceof U?t:new U(t),r=this,i=n.getFront();null!==i;){r=new e(i,r,Object(o.x)(r.node_.children,i)||new hn),i=(n=n.popFront()).getFront()}return r},e.prototype.getValue=function(){return this.node_.value},e.prototype.setValue=function(e){Object(o.d)("undefined"!==typeof e,"Cannot set value to undefined"),this.node_.value=e,this.updateParents_()},e.prototype.clear=function(){this.node_.value=null,this.node_.children={},this.node_.childCount=0,this.updateParents_()},e.prototype.hasChildren=function(){return this.node_.childCount>0},e.prototype.isEmpty=function(){return null===this.getValue()&&!this.hasChildren()},e.prototype.forEachChild=function(t){var n=this;D(this.node_.children,(function(r,i){t(new e(r,n,i))}))},e.prototype.forEachDescendant=function(e,t,n){t&&!n&&e(this),this.forEachChild((function(t){t.forEachDescendant(e,!0,n)})),t&&n&&e(this)},e.prototype.forEachAncestor=function(e,t){for(var n=t?this:this.parent();null!==n;){if(e(n))return!0;n=n.parent()}return!1},e.prototype.forEachImmediateDescendantWithValue=function(e){this.forEachChild((function(t){null!==t.getValue()?e(t):t.forEachImmediateDescendantWithValue(e)}))},e.prototype.path=function(){return new U(null===this.parent_?this.name_:this.parent_.path()+"/"+this.name_)},e.prototype.name=function(){return this.name_},e.prototype.parent=function(){return this.parent_},e.prototype.updateParents_=function(){null!==this.parent_&&this.parent_.updateChild_(this.name_,this)},e.prototype.updateChild_=function(e,t){var n=t.isEmpty(),r=Object(o.h)(this.node_.children,e);n&&r?(delete this.node_.children[e],this.node_.childCount--,this.updateParents_()):n||r||(this.node_.children[e]=t.node_,this.node_.childCount++,this.updateParents_())},e}();!function(e){e[e.RUN=0]="RUN",e[e.SENT=1]="SENT",e[e.COMPLETED=2]="COMPLETED",e[e.SENT_NEEDS_ABORT=3]="SENT_NEEDS_ABORT",e[e.NEEDS_ABORT=4]="NEEDS_ABORT"}(fn||(fn={})),an.MAX_TRANSACTION_RETRIES_=25,an.prototype.transactionsInit_=function(){this.transactionQueueTree_=new dn},an.prototype.startTransaction=function(e,t,n,r){this.log_("transaction on "+e);var i=function(){},a=new cn(this,e);a.on("value",i);var s={path:e,update:t,onComplete:n,status:null,order:p(),applyLocally:r,retryCount:0,unwatcher:function(){a.off("value",i)},abortReason:null,currentWriteId:null,currentInputSnapshot:null,currentOutputSnapshotRaw:null,currentOutputSnapshotResolved:null},l=this.getLatestState_(e);s.currentInputSnapshot=l;var u=s.update(l.val());if(void 0===u){if(s.unwatcher(),s.currentOutputSnapshotRaw=null,s.currentOutputSnapshotResolved=null,s.onComplete){var c=new He(s.currentInputSnapshot,new cn(this,s.path),xe);s.onComplete(null,!1,c)}}else{re("transaction failed: Data returned ",u,s.path),s.status=fn.RUN;var f=this.transactionQueueTree_.subTree(e),h=f.getValue()||[];h.push(s),f.setValue(h);var d=void 0;if("object"===typeof u&&null!==u&&Object(o.h)(u,".priority"))d=Object(o.x)(u,".priority"),Object(o.d)(te(d),"Invalid priority returned by transaction. Priority must be a valid string, finite number, server value, or null.");else d=(this.serverSyncTree_.calcCompleteEventCache(e)||We.EMPTY_NODE).getPriority().val();d=d;var y=this.generateServerValues(),v=Be(u,d),g=it(v,l,y);s.currentOutputSnapshotRaw=v,s.currentOutputSnapshotResolved=g,s.currentWriteId=this.getNextWriteId_();var m=this.serverSyncTree_.applyUserOverwrite(e,g,s.currentWriteId,s.applyLocally);this.eventQueue_.raiseEventsForChangedPath(e,m),this.sendReadyTransactions_()}},an.prototype.getLatestState_=function(e,t){return this.serverSyncTree_.calcCompleteEventCache(e,t)||We.EMPTY_NODE},an.prototype.sendReadyTransactions_=function(e){var t=this;if(void 0===e&&(e=this.transactionQueueTree_),e||this.pruneCompletedTransactionsBelowNode_(e),null!==e.getValue()){var n=this.buildTransactionQueue_(e);Object(o.d)(n.length>0,"Sending zero length transaction queue"),n.every((function(e){return e.status===fn.RUN}))&&this.sendTransactionQueue_(e.path(),n)}else e.hasChildren()&&e.forEachChild((function(e){t.sendReadyTransactions_(e)}))},an.prototype.sendTransactionQueue_=function(e,t){for(var n=this,r=t.map((function(e){return e.currentWriteId})),i=this.getLatestState_(e,r),a=i,s=i.hash(),l=0;l<t.length;l++){var u=t[l];Object(o.d)(u.status===fn.RUN,"tryToSendTransactionQueue_: items in queue should all be run."),u.status=fn.SENT,u.retryCount++;var c=U.relativePath(e,u.path);a=a.updateChild(c,u.currentOutputSnapshotRaw)}var f=a.val(!0),h=e;this.server_.put(h.toString(),f,(function(r){n.log_("transaction put response",{path:h.toString(),status:r});var i=[];if("ok"===r){for(var o=[],a=0;a<t.length;
2a++){if(t[a].status=fn.COMPLETED,i=i.concat(n.serverSyncTree_.ackUserWrite(t[a].currentWriteId)),t[a].onComplete){var s=t[a].currentOutputSnapshotResolved,l=new cn(n,t[a].path),u=new He(s,l,xe);o.push(t[a].onComplete.bind(null,null,!0,u))}t[a].unwatcher()}n.pruneCompletedTransactionsBelowNode_(n.transactionQueueTree_.subTree(e)),n.sendReadyTransactions_(),n.eventQueue_.raiseEventsForChangedPath(e,i);for(a=0;a<o.length;a++)F(o[a])}else{if("datastale"===r)for(a=0;a<t.length;a++)t[a].status===fn.SENT_NEEDS_ABORT?t[a].status=fn.NEEDS_ABORT:t[a].status=fn.RUN;else{S("transaction at "+h.toString()+" failed: "+r);for(a=0;a<t.length;a++)t[a].status=fn.NEEDS_ABORT,t[a].abortReason=r}n.rerunTransactions_(e)}}),s)},an.prototype.rerunTransactions_=function(e){var t=this.getAncestorTransactionNode_(e),n=t.path(),r=this.buildTransactionQueue_(t);return this.rerunTransactionQueue_(r,n),n},an.prototype.rerunTransactionQueue_=function(e,t){if(0!==e.length){for(var n,r=[],i=[],a=e.filter((function(e){return e.status===fn.RUN})).map((function(e){return e.currentWriteId})),s=0;s<e.length;s++){var l=e[s],u=U.relativePath(t,l.path),c=!1,f=void 0;if(Object(o.d)(null!==u,"rerunTransactionsUnderNode_: relativePath should not be null."),l.status===fn.NEEDS_ABORT)c=!0,f=l.abortReason,i=i.concat(this.serverSyncTree_.ackUserWrite(l.currentWriteId,!0));else if(l.status===fn.RUN)if(l.retryCount>=an.MAX_TRANSACTION_RETRIES_)c=!0,f="maxretry",i=i.concat(this.serverSyncTree_.ackUserWrite(l.currentWriteId,!0));else{var h=this.getLatestState_(l.path,a);l.currentInputSnapshot=h;var d=e[s].update(h.val());if(void 0!==d){re("transaction failed: Data returned ",d,l.path);var p=Be(d);"object"===typeof d&&null!=d&&Object(o.h)(d,".priority")||(p=p.updatePriority(h.getPriority()));var y=l.currentWriteId,v=this.generateServerValues(),g=it(p,h,v);l.currentOutputSnapshotRaw=p,l.currentOutputSnapshotResolved=g,l.currentWriteId=this.getNextWriteId_(),a.splice(a.indexOf(y),1),i=(i=i.concat(this.serverSyncTree_.applyUserOverwrite(l.path,g,l.currentWriteId,l.applyLocally))).concat(this.serverSyncTree_.ackUserWrite(y,!0))}else c=!0,f="nodata",i=i.concat(this.serverSyncTree_.ackUserWrite(l.currentWriteId,!0))}if(this.eventQueue_.raiseEventsForChangedPath(t,i),i=[],c&&(e[s].status=fn.COMPLETED,n=e[s].unwatcher,setTimeout(n,Math.floor(0)),e[s].onComplete))if("nodata"===f){var m=new cn(this,e[s].path),_=e[s].currentInputSnapshot,b=new He(_,m,xe);r.push(e[s].onComplete.bind(null,null,!1,b))}else r.push(e[s].onComplete.bind(null,new Error(f),!1,null))}this.pruneCompletedTransactionsBelowNode_(this.transactionQueueTree_);for(s=0;s<r.length;s++)F(r[s]);this.sendReadyTransactions_()}},an.prototype.getAncestorTransactionNode_=function(e){var t,n=this.transactionQueueTree_;for(t=e.getFront();null!==t&&null===n.getValue();)n=n.subTree(t),t=(e=e.popFront()).getFront();return n},an.prototype.buildTransactionQueue_=function(e){var t=[];return this.aggregateTransactionQueuesForNode_(e,t),t.sort((function(e,t){return e.order-t.order})),t},an.prototype.aggregateTransactionQueuesForNode_=function(e,t){var n=this,r=e.getValue();if(null!==r)for(var i=0;i<r.length;i++)t.push(r[i]);e.forEachChild((function(e){n.aggregateTransactionQueuesForNode_(e,t)}))},an.prototype.pruneCompletedTransactionsBelowNode_=function(e){var t=this,n=e.getValue();if(n){for(var r=0,i=0;i<n.length;i++)n[i].status!==fn.COMPLETED&&(n[r]=n[i],r++);n.length=r,e.setValue(n.length>0?n:null)}e.forEachChild((function(e){t.pruneCompletedTransactionsBelowNode_(e)}))},an.prototype.abortTransactions_=function(e){var t=this,n=this.getAncestorTransactionNode_(e).path(),r=this.transactionQueueTree_.subTree(e);return r.forEachAncestor((function(e){t.abortTransactionsOnNode_(e)})),this.abortTransactionsOnNode_(r),r.forEachDescendant((function(e){t.abortTransactionsOnNode_(e)})),n},an.prototype.abortTransactionsOnNode_=function(e){var t=e.getValue();if(null!==t){for(var n=[],r=[],i=-1,a=0;a<t.length;a++)if(t[a].status===fn.SENT_NEEDS_ABORT);else if(t[a].status===fn.SENT)Object(o.d)(i===a-1,"All SENT items should be at beginning of queue."),i=a,t[a].status=fn.SENT_NEEDS_ABORT,t[a].abortReason="set";else if(Object(o.d)(t[a].status===fn.RUN,"Unexpected transaction status in abort"),t[a].unwatcher(),r
2=r.concat(this.serverSyncTree_.ackUserWrite(t[a].currentWriteId,!0)),t[a].onComplete){n.push(t[a].onComplete.bind(null,new Error("set"),!1,null))}-1===i?e.setValue(null):t.length=i+1,this.eventQueue_.raiseEventsForChangedPath(e.path(),r);for(a=0;a<n.length;a++)F(n[a])}};var pn,yn=function(){function e(e,t){var n=this;this.app_=e,this.authProvider_=t,this.auth_=null,this.auth_=t.getImmediate({optional:!0}),this.auth_||t.get().then((function(e){return n.auth_=e}))}return e.prototype.getToken=function(e){return this.auth_?this.auth_.getToken(e).catch((function(e){return e&&"auth/token-not-initialized"===e.code?(b("Got auth/token-not-initialized error. Treating as null token."),null):Promise.reject(e)})):Promise.resolve(null)},e.prototype.addTokenChangeListener=function(e){this.auth_?this.auth_.addAuthTokenListener(e):(setTimeout((function(){return e(null)}),0),this.authProvider_.get().then((function(t){return t.addAuthTokenListener(e)})))},e.prototype.removeTokenChangeListener=function(e){this.authProvider_.get().then((function(t){return t.removeAuthTokenListener(e)}))},e.prototype.notifyForInvalidToken=function(){var e='Provided authentication credentials for the app named "'+this.app_.name+'" are invalid. This usually indicates your app was not initialized correctly. ';"credential"in this.app_.options?e+='Make sure the "credential" property provided to initializeApp() is authorized to access the specified "databaseURL" and is from the correct project.':"serviceAccount"in this.app_.options?e+='Make sure the "serviceAccount" property provided to initializeApp() is authorized to access the specified "databaseURL" and is from the correct project.':e+='Make sure the "apiKey" and "databaseURL" properties provided to initializeApp() match the values provided for your app at https://console.firebase.google.com/.',S(e)},e}(),vn=function(){function e(){}return e.prototype.getToken=function(t){return Promise.resolve({accessToken:e.EMULATOR_AUTH_TOKEN})},e.prototype.addTokenChangeListener=function(t){t(e.EMULATOR_AUTH_TOKEN)},e.prototype.removeTokenChangeListener=function(e){},e.prototype.notifyForInvalidToken=function(){},e.EMULATOR_AUTH_TOKEN="owner",e}(),gn=function(){function t(){this.repos_={},this.useRestClient_=!1}return t.getInstance=function(){return pn||(pn=new t),pn},t.prototype.interrupt=function(){var e,t,n,r;try{for(var o=Object(i.g)(Object.keys(this.repos_)),a=o.next();!a.done;a=o.next()){var s=a.value;try{for(var l=(n=void 0,Object(i.g)(Object.keys(this.repos_[s]))),u=l.next();!u.done;u=l.next()){var c=u.value;this.repos_[s][c].interrupt()}}catch(f){n={error:f}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}}catch(h){e={error:h}}finally{try{a&&!a.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}},t.prototype.resume=function(){var e,t,n,r;try{for(var o=Object(i.g)(Object.keys(this.repos_)),a=o.next();!a.done;a=o.next()){var s=a.value;try{for(var l=(n=void 0,Object(i.g)(Object.keys(this.repos_[s]))),u=l.next();!u.done;u=l.next()){var c=u.value;this.repos_[s][c].resume()}}catch(f){n={error:f}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}}catch(h){e={error:h}}finally{try{a&&!a.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}},t.prototype.applyEmulatorSettings=function(e,t,n){e.repoInfo_=new Q(t+":"+n,!1,e.repoInfo_.namespace,e.repoInfo_.webSocketOnly,e.repoInfo_.nodeAdmin,e.repoInfo_.persistenceKey,e.repoInfo_.includeNamespaceInQueryParams),e.repoInfo_.nodeAdmin&&(e.authTokenProvider_=new vn)},t.prototype.databaseFromApp=function(t,n,r,i){var o=r||t.options.databaseURL;void 0===o&&(t.options.projectId||C("Can't determine Firebase Database URL. Be sure to include a Project ID when calling firebase.initializeApp()."),b("Using default host for project ",t.options.projectId),o=t.options.projectId+"-default-rtdb.firebaseio.com");var a,s=Y(o,i),l=s.repoInfo,u=void 0;"undefined"!==typeof e&&(u=Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0,FAST_REFRESH:!0}).FIREBASE_DATABASE_EMULATOR_HOST),u?(a=!0,o="http://"+u+"?ns="+l.namespace,l=(s=Y(o,i)
2).repoInfo):a=!s.repoInfo.secure;var c=i&&a?new vn:new yn(t,n);return fe("Invalid Firebase Database URL",1,s),s.path.isEmpty()||C("Database URL must point to the root of a Firebase Database (not including a child path)."),this.createRepo(l,t,c).database},t.prototype.deleteRepo=function(e){var t=Object(o.x)(this.repos_,e.app.name);t&&Object(o.x)(t,e.key)===e||C("Database "+e.app.name+"("+e.repoInfo_+") has already been deleted."),e.interrupt(),delete t[e.key]},t.prototype.createRepo=function(e,t,n){var r=Object(o.x)(this.repos_,t.name);r||(r={},this.repos_[t.name]=r);var i=Object(o.x)(r,e.toURLString());return i&&C("Database initialized multiple times. Please make sure the format of the database URL matches with each database() call."),i=new an(e,this.useRestClient_,t,n),r[e.toURLString()]=i,i},t.prototype.forceRestClient=function(e){this.useRestClient_=e},t}(),mn=function(){function e(e){var t=this;this.repoInternal_=e,this.instanceStarted_=!1,this.INTERNAL={delete:function(){return Object(i.b)(t,void 0,void 0,(function(){return Object(i.d)(this,(function(e){return this.checkDeleted_("delete"),gn.getInstance().deleteRepo(this.repo_),this.repoInternal_=null,this.rootInternal_=null,[2]}))}))}},e instanceof an||C("Don't call new Database() directly - please use firebase.database().")}return Object.defineProperty(e.prototype,"repo_",{get:function(){return this.instanceStarted_||(this.repoInternal_.start(),this.instanceStarted_=!0),this.repoInternal_},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"root_",{get:function(){return this.rootInternal_||(this.rootInternal_=new cn(this.repo_,U.Empty)),this.rootInternal_},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"app",{get:function(){return this.repo_.app},enumerable:!1,configurable:!0}),e.prototype.useEmulator=function(e,t){this.checkDeleted_("useEmulator"),this.instanceStarted_?C("Cannot call useEmulator() after instance has already been initialized."):gn.getInstance().applyEmulatorSettings(this.repoInternal_,e,t)},e.prototype.ref=function(e){return this.checkDeleted_("ref"),Object(o.B)("database.ref",0,1,arguments.length),e instanceof cn?this.refFromURL(e.toString()):void 0!==e?this.root_.child(e):this.root_},e.prototype.refFromURL=function(e){var t="database.refFromURL";this.checkDeleted_(t),Object(o.B)(t,1,1,arguments.length);var n=Y(e,this.repo_.repoInfo_.nodeAdmin);fe(t,1,n);var r=n.repoInfo;return r.isCustomHost()||r.host===this.repo_.repoInfo_.host||C(t+": Host name does not match the current database: (found "+r.host+" but expected "+this.repo_.repoInfo_.host+")"),this.ref(n.path.toString())},e.prototype.checkDeleted_=function(e){null===this.repoInternal_&&C("Cannot call "+e+" on a deleted database.")},e.prototype.goOffline=function(){Object(o.B)("database.goOffline",0,0,arguments.length),this.checkDeleted_("goOffline"),this.repo_.interrupt()},e.prototype.goOnline=function(){Object(o.B)("database.goOnline",0,0,arguments.length),this.checkDeleted_("goOnline"),this.repo_.resume()},e.ServerValue={TIMESTAMP:{".sv":"timestamp"},increment:function(e){return{".sv":{increment:e}}}},e}();var _n=Object.freeze({__proto__:null,forceLongPolling:function(){Xt.forceDisallow(),Ht.forceAllow()},forceWebSockets:function(){Ht.forceDisallow()},isWebSocketsAvailable:function(){return Xt.isAvailable()},setSecurityDebugCallback:function(e,t){e.repo.persistentConnection_.securityDebugCallback_=t},stats:function(e,t){e.repo.stats(t)},statsIncrementCounter:function(e,t){e.repo.statsIncrementCounter(t)},dataUpdateCount:function(e){return e.repo.dataUpdateCount},interceptServerData:function(e,t){return e.repo.interceptServerData_(t)},initStandalone:function(e){var t=e.app,n=e.url,r=e.version,i=e.customAuthImpl,o=e.namespace,a=e.nodeAdmin,l=void 0!==a&&a;$t(r);var u=new s.c("auth-internal",new s.b("database-standalone"));return u.setComponent(new s.a("auth-internal",(function(){return i}),"PRIVATE")),{instance:gn.getInstance().databaseFromApp(t,u,n,l),namespace:o}}}),bn=nn;nn.prototype.simpleListen=function(e,t){this.sendRequest("q",{p:e},t)},nn.prototype.echo=function(e,t){this.sendRequest("echo",{d:e},t)};var wn=Zt,En=Q,Cn=Object.freeze({__proto__:null,DataConnection:bn,RealTimeConnection:wn,hijackHash:function(e){var t=nn.prototype.put;return nn.prototype.put=function(n,r,i,o){void 0!==o&&(o=e()),t.call(this,n,r,i,o)},function(){nn.prototype.put=t}},ConnectionTarget:En,queryIdentifier:function(e){return e.queryIdentifier()},forceRestClient:function(e){gn.getInstance().forceRestClient(e)}}),Sn=mn.ServerValue;!function(e){$t(e.SDK_VERSION);var n=e.INTERNAL.registerComponent(new s.a("database",(function(e,t){var n=e.getProvider("app").getImmediate(),r=e.getProvider("auth-internal");return gn.getInstance().databaseFromApp(n,r,t)}),"PUBLIC").setServiceProps({Reference:cn,Query:Xe,Database:mn,DataSnapshot:He,enableLogging:_,INTERNAL:_n,ServerValue:Sn,TEST_ACCESS:Cn}).setMultipleInstances(!0));e.registerVersion("@firebase/database","0.8.1"),Object(o.r)()&&(t.exports=n)}(r.a)}).call(this,n(19),n(63)(e))},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}}]]); 3//# sourceMappingURL=2.b61e17d0.chunk.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.