1(function(){try{var y=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},E=new y.Error().stack;E&&(y._sentryDebugIds=y._sentryDebugIds||{},y._sentryDebugIds[E]="7ddc3a23-0952-46a9-9a0f-55ae4fc4e463",y._sentryDebugIdIdentifier="sentry-dbid-7ddc3a23-0952-46a9-9a0f-55ae4fc4e463")}catch{}})();var _global=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};_global.SENTRY_RELEASE={id:"6b3b5bcd49ac3ca4e22832378da81add8169a867"},(self.webpackChunk_maestro_io_client=self.webpackChunk_maestro_io_client||[]).push([[8159],{581567:(y,E,f)=>{var b;/*! 2 Copyright (c) 2015 Jed Watson. 3 Based on code that is Copyright 2013-2015, Facebook, Inc. 4 All rights reserved. 5*/(function(){"use strict";var _=!!(typeof window<"u"&&window.document&&window.document.createElement),m={canUseDOM:_,canUseWorkers:typeof Worker<"u",canUseEventListeners:_&&!!(window.addEventListener||window.attachEvent),canUseViewport:_&&!!window.screen};b=function(){return m}.call(E,f,E,y),b!==void 0&&(y.exports=b)})()},62563:y=>{var E=function(){if(typeof self=="object"&&self)return self;if(typeof window=="object"&&window)return window;throw new Error("Unable to resolve global `this`")};y.exports=function(){if(this)return this;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch{return E()}try{return __global__||E()}finally{delete Object.prototype.__global__}}()},432861:(y,E,f)=>{"use strict";y.exports=f(764004)()?globalThis:f(62563)},764004:y=>{"use strict";y.exports=function(){return typeof globalThis!="object"||!globalThis?!1:globalThis.Array===Array}},162757:y=>{"use strict";y.exports=function E(f,b){if(f===b)return!0;if(f&&b&&typeof f=="object"&&typeof b=="object"){if(f.constructor!==b.constructor)return!1;var _,m,B;if(Array.isArray(f)){if(_=f.length,_!=b.length)return!1;for(m=_;m--!==0;)if(!E(f[m],b[m]))return!1;return!0}if(f.constructor===RegExp)return f.source===b.source&&f.flags===b.flags;if(f.valueOf!==Object.prototype.valueOf)return f.valueOf()===b.valueOf();if(f.toString!==Object.prototype.toString)return f.toString()===b.toString();if(B=Object.keys(f),_=B.length,_!==Object.keys(b).length)return!1;for(m=_;m--!==0;)if(!Object.prototype.hasOwnProperty.call(b,B[m]))return!1;for(m=_;m--!==0;){var j=B[m];if(!E(f[j],b[j]))return!1}return!0}return f!==f&&b!==b}},329833:(y,E,f)=>{"use strict";f.d(E,{A:()=>it});var b=f(80247),_=f(288538);/** 6 * @license 7 * Copyright 2017 Google LLC 8 * 9 * Licensed under the Apache License, Version 2.0 (the "License"); 10 * you may not use this file except in compliance with the License. 11 * You may obtain a copy of the License at 12 * 13 * http://www.apache.org/licenses/LICENSE-2.0 14 * 15 * Unless required by applicable law or agreed to in writing, software 16 * distributed under the License is distributed on an "AS IS" BASIS, 17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 * See the License for the specific language governing permissions and 19 * limitations under the License. 20 */const m={NODE_CLIENT:!1,NODE_ADMIN:!1,SDK_VERSION:"${JSCORE_VERSION}"};/** 21 * @license 22 * Copyright 2017 Google LLC 23 * 24 * Licensed under the Apache License, Version 2.0 (the "License"); 25 * you may not use this file except in compliance with the License. 26 * You may obtain a copy of the License at 27 * 28 * http://www.apache.org/licenses/LICENSE-2.0 29 * 30 * Unless required by applicable law or agreed to in writing, software 31 * distributed under the License is distributed on an "AS IS" BASIS, 32 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 33 * See the License for the specific language governing permissions and 34 * limitations under the License. 35 */const B=function(t,e){if(!t)throw j(e)},j=function(t){return new Error("Firebase Database ("+m.SDK_VERSION+") INTERNAL ASSERT FAILED: "+t)};/** 36 * @license 37 * Copyright 2017 Google LLC 38 * 39 * Licensed under the Apache License, Version 2.0 (the "License"); 40 * you may not use this file except in compliance with the License. 41 * You may obtain a copy of the License at 42 * 43 * http://www.apache.org/licenses/LICENSE-2.0 44 * 45 * Unless required by applicable law or agreed to in writing, softw
45are 46 * distributed under the License is distributed on an "AS IS" BASIS, 47 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 48 * See the License for the specific language governing permissions and 49 * limitations under the License. 50 */const G=function(t){const e=[];let n=0;for(let i=0;i<t.length;i++){let r=t.charCodeAt(i);r<128?e[n++]=r:r<2048?(e[n++]=r>>6|192,e[n++]=r&63|128):(r&64512)===55296&&i+1<t.length&&(t.charCodeAt(i+1)&64512)===56320?(r=65536+((r&1023)<<10)+(t.charCodeAt(++i)&1023),e[n++]=r>>18|240,e[n++]=r>>12&63|128,e[n++]=r>>6&63|128,e[n++]=r&63|128):(e[n++]=r>>12|224,e[n++]=r>>6&63|128,e[n++]=r&63|128)}return e},H=function(t){const e=[];let n=0,i=0;for(;n<t.length;){const r=t[n++];if(r<128)e[i++]=String.fromCharCode(r);else if(r>191&&r<224){const s=t[n++];e[i++]=String.fromCharCode((r&31)<<6|s&63)}else if(r>239&&r<365){const s=t[n++],l=t[n++],g=t[n++],D=((r&7)<<18|(s&63)<<12|(l&63)<<6|g&63)-65536;e[i++]=String.fromCharCode(55296+(D>>10)),e[i++]=String.fromCharCode(56320+(D&1023))}else{const s=t[n++],l=t[n++];e[i++]=String.fromCharCode((r&15)<<12|(s&63)<<6|l&63)}}return e.join("")},W={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:typeof atob=="function",encodeByteArray(t,e){if(!Array.isArray(t))throw Error("encodeByteArray takes an array as a parameter");this.init_();const n=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,i=[];for(let r=0;r<t.length;r+=3){const s=t[r],l=r+1<t.length,g=l?t[r+1]:0,D=r+2<t.length,p=D?t[r+2]:0,A=s>>2,u=(s&3)<<4|g>>4;let S=(g&15)<<2|p>>6,N=p&63;D||(N=64,l||(S=64)),i.push(n[A],n[u],n[S],n[N])}return i.join("")},encodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(t):this.encodeByteArray(G(t),e)},decodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(t):H(this.decodeStringToByteArray(t,e))},decodeStringToByteArray(t,e){this.init_();const n=e?this.charToByteMapWebSafe_:this.charToByteMap_,i=[];for(let r=0;r<t.length;){const s=n[t.charAt(r++)],g=r<t.length?n[t.charAt(r)]:0;++r;const p=r<t.length?n[t.charAt(r)]:64;++r;const u=r<t.length?n[t.charAt(r)]:64;if(++r,s==null||g==null||p==null||u==null)throw Error();const S=s<<2|g>>4;if(i.push(S),p!==64){const N=g<<4&240|p>>2;if(i.push(N),u!==64){const Je=p<<6&192|u;i.push(Je)}}}return i},init_(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(let t=0;t<this.ENCODED_VALS.length;t++)this.byteToCharMap_[t]=this.ENCODED_VALS.charAt(t),this.charToByteMap_[this.byteToCharMap_[t]]=t,this.byteToCharMapWebSafe_[t]=this.ENCODED_VALS_WEBSAFE.charAt(t),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[t]]=t,t>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(t)]=t,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(t)]=t)}}},x=function(t){const e=G(t);return W.encodeByteArray(e,!0)},X=function(t){return x(t).replace(/\./g,"")},z=function(t){try{return W.decodeString(t,!0)}catch(e){b.error("base64Decode failed: ",e)}return null};/** 51 * @license 52 * Copyright 2017 Google LLC 53 * 54 * Licensed under the Apache License, Version 2.0 (the "License"); 55 * you may not use this file except in compliance with the License. 56 * You may obtain a copy of the License at 57 * 58 * http://www.apache.org/licenses/LICENSE-2.0 59 * 60 * Unless required by applicable law or agreed to in writing, software 61 * distributed under the License is distributed on an "AS IS" BASIS, 62 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 63 * See the License for the specific language governing permissions and 64 * limitations under the License. 65 */function Ae(t){return M(void 0,t)}function M(t,e){if(!(e instanceof Object))return e;switch(e.constructor){case Date:const n=e;return new Date(n.getTime());case Object:t===void 0&&(t={});break;case Array:t=[];break;default:return e}for(const n in e)!e.hasOwnProperty(n)||!ne(n)||(t[n]=M(t[n],e[n]));return t}function ne(t){return t!=="__proto__"}/** 66 * @license 67 * Copyright 2017 Google LLC 68 * 69 * Licensed under the Apache License, Version 2.0 (the "License");
70 * you may not use this file except in compliance with the License. 71 * You may obtain a copy of the License at 72 * 73 * http://www.apache.org/licenses/LICENSE-2.0 74 * 75 * Unless required by applicable law or agreed to in writing, software 76 * distributed under the License is distributed on an "AS IS" BASIS, 77 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 78 * See the License for the specific language governing permissions and 79 * limitations under the License. 80 */function L(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function we(){return typeof window<"u"&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(L())}function re(){try{return Object.prototype.toString.call(f.g.process)==="[object process]"}catch{return!1}}function ie(){return typeof self=="object"&&self.self===self}function Se(){const t=typeof chrome=="object"?chrome.runtime:typeof browser=="object"?browser.runtime:void 0;return typeof t=="object"&&t.id!==void 0}function De(){return typeof navigator=="object"&&navigator.product==="ReactNative"}function Ce(){return L().indexOf("Electron/")>=0}function Oe(){const t=L();return t.indexOf("MSIE ")>=0||t.indexOf("Trident/")>=0}function xe(){return L().indexOf("MSAppHost/")>=0}function Te(){return m.NODE_CLIENT===!0||m.NODE_ADMIN===!0}function Ie(){return!re()&&navigator.userAgent.includes("Safari")&&!navigator.userAgent.includes("Chrome")}function Ne(){return typeof indexedDB=="object"}function Be(){return new Promise((t,e)=>{try{let n=!0;const i="validate-browser-context-for-indexeddb-analytics-module",r=self.indexedDB.open(i);r.onsuccess=()=>{r.result.close(),n||self.indexedDB.deleteDatabase(i),t(!0)},r.onupgradeneeded=()=>{n=!1},r.onerror=()=>{var s;e(((s=r.error)===null||s===void 0?void 0:s.message)||"")}}catch(n){e(n)}})}function Pe(){return!(typeof navigator>"u"||!navigator.cookieEnabled)}function oe(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof f.g<"u")return f.g;throw new Error("Unable to locate global object.")}/** 81 * @license 82 * Copyright 2022 Google LLC 83 * 84 * Licensed under the Apache License, Version 2.0 (the "License"); 85 * you may not use this file except in compliance with the License. 86 * You may obtain a copy of the License at 87 * 88 * http://www.apache.org/licenses/LICENSE-2.0 89 * 90 * Unless required by applicable law or agreed to in writing, software 91 * distributed under the License is distributed on an "AS IS" BASIS, 92 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 93 * See the License for the specific language governing permissions and 94 * limitations under the License. 95 */const ae=()=>oe().__FIREBASE_DEFAULTS__,se=()=>{if(typeof _>"u"||typeof _.env>"u")return;const t=_.env.__FIREBASE_DEFAULTS__;if(t)return JSON.parse(t)},ce=()=>{if(typeof document>"u")return;let t;try{t=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}const e=t&&z(t[1]);return e&&JSON.parse(e)},K=()=>{try{return ae()||se()||ce()}catch(t){b.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${t}`);return}},fe=t=>{var e,n;return(n=(e=K())===null||e===void 0?void 0:e.emulatorHosts)===null||n===void 0?void 0:n[t]},F=t=>{const e=fe(t);if(!e)return;const n=e.lastIndexOf(":");if(n<=0||n+1===e.length)throw new Error(`Invalid host ${e} with no separate hostname and port!`);const i=parseInt(e.substring(n+1),10);return e[0]==="["?[e.substring(1,n-1),i]:[e.substring(0,n),i]},Me=()=>{var t;return(t=K())===null||t===void 0?void 0:t.config},T=t=>{var e;return(e=K())===null||e===void 0?void 0:e[`_${t}`]};/** 96 * @license 97 * Copyright 2017 Google LLC 98 * 99 * Licensed under the Apache License, Version 2.0 (the "License"); 100 * you may not use this file except in compliance with the License. 101 * You may obtain a copy of the License at 102 * 103 * http://www.apache.org/licenses/LICENSE-2.0 104 * 105 * Unless required by applicable law or agreed to in writing, software 106 * distributed under the License is distributed on an "AS IS" BASIS, 107 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 108 * See the License for the specific language governing permissions and 109 * limitations under the License. 110 */class R{constructor(){this.reject=()=>{},this.resolve=()=>{}
110,this.promise=new Promise((e,n)=>{this.resolve=e,this.reject=n})}wrapCallback(e){return(n,i)=>{n?this.reject(n):this.resolve(i),typeof e=="function"&&(this.promise.catch(()=>{}),e.length===1?e(n):e(n,i))}}}/** 111 * @license 112 * Copyright 2021 Google LLC 113 * 114 * Licensed under the Apache License, Version 2.0 (the "License"); 115 * you may not use this file except in compliance with the License. 116 * You may obtain a copy of the License at 117 * 118 * http://www.apache.org/licenses/LICENSE-2.0 119 * 120 * Unless required by applicable law or agreed to in writing, software 121 * distributed under the License is distributed on an "AS IS" BASIS, 122 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 123 * See the License for the specific language governing permissions and 124 * limitations under the License. 125 */function le(t,e){if(t.uid)throw new Error('The "uid" field is no longer supported by mockUserToken. Please use "sub" instead for Firebase Auth User ID.');const n={alg:"none",type:"JWT"},i=e||"demo-project",r=t.iat||0,s=t.sub||t.user_id;if(!s)throw new Error("mockUserToken must contain 'sub' or 'user_id' field!");const l=Object.assign({iss:`https://securetoken.google.com/${i}`,aud:i,iat:r,exp:r+3600,auth_time:r,sub:s,user_id:s,firebase:{sign_in_provider:"custom",identities:{}}},t),g="";return[X(JSON.stringify(n)),X(JSON.stringify(l)),g].join(".")}/** 126 * @license 127 * Copyright 2017 Google LLC 128 * 129 * Licensed under the Apache License, Version 2.0 (the "License"); 130 * you may not use this file except in compliance with the License. 131 * You may obtain a copy of the License at 132 * 133 * http://www.apache.org/licenses/LICENSE-2.0 134 * 135 * Unless required by applicable law or agreed to in writing, software 136 * distributed under the License is distributed on an "AS IS" BASIS, 137 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 138 * See the License for the specific language governing permissions and 139 * limitations under the License. 140 */const ue="FirebaseError";class P extends Error{constructor(e,n,i){super(n),this.code=e,this.customData=i,this.name=ue,Object.setPrototypeOf(this,P.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,$.prototype.create)}}class ${constructor(e,n,i){this.service=e,this.serviceName=n,this.errors=i}create(e,...n){const i=n[0]||{},r=`${this.service}/${e}`,s=this.errors[e],l=s?de(s,i):"Error",g=`${this.serviceName}: ${l} (${r}).`;return new P(r,g,i)}}function de(t,e){return t.replace(he,(n,i)=>{const r=e[i];return r!=null?String(r):`<${i}?>`})}const he=/\{\$([^}]+)}/g;/** 141 * @license 142 * Copyright 2017 Google LLC 143 * 144 * Licensed under the Apache License, Version 2.0 (the "License"); 145 * you may not use this file except in compliance with the License. 146 * You may obtain a copy of the License at 147 * 148 * http://www.apache.org/licenses/LICENSE-2.0 149 * 150 * Unless required by applicable law or agreed to in writing, software 151 * distributed under the License is distributed on an "AS IS" BASIS, 152 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 153 * See the License for the specific language governing permissions and 154 * limitations under the License. 155 */function Q(t){return JSON.parse(t)}function O(t){return JSON.stringify(t)}/** 156 * @license 157 * Copyright 2017 Google LLC 158 * 159 * Licensed under the Apache License, Version 2.0 (the "License"); 160 * you may not use this file except in compliance with the License. 161 * You may obtain a copy of the License at 162 * 163 * http://www.apache.org/licenses/LICENSE-2.0 164 * 165 * Unless required by applicable law or agreed to in writing, software 166 * distributed under the License is distributed on an "AS IS" BASIS, 167 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 168 * See the License for the specific language governing permissions and 169 * limitations under the License. 170 */const U=function(t){let e={},n={},i={},r="";try{const s=t.split(".");e=Q(z(s[0])||""),n=Q(z(s[1])||""),r=s[2],i=n.d||{},delete n.d}catch{}return{header:e,claims:n,data:i,signature:r}},Re=function(t){const e=U(t).claims,n=Math.floor(new Date().getTime()/1e3);let i=0,r=0;return typeof e=="object"&&(e.hasOwnProperty("nbf")?i=e.nbf:e.hasOwnProperty("iat")&&(i=e.iat),e.hasOwnProperty("exp")?r=e.exp:r=i+86400),!!n&&!!i&&!!r&&n>=i&&n<=r},pe=function(t){const e=U(t).claims;return typeof e=="object"&&e.hasOwnProperty("iat")?e.iat:null},je=function(t){const e=U(t),n=e.claims;return!!n&&typeof n=="object"&&n.hasOwnProperty("iat")},Le=function(t){const e=U(t).claims;return typeof e=="object"&&e.admin===!0};/** 171 * @license 172 * Copyright 2017 Google LLC 173 * 174 * Licensed under the Apache License, Version 2.0 (the "License");
175 * you may not use this file except in compliance with the License. 176 * You may obtain a copy of the License at 177 * 178 * http://www.apache.org/licenses/LICENSE-2.0 179 * 180 * Unless required by applicable law or agreed to in writing, software 181 * distributed under the License is distributed on an "AS IS" BASIS, 182 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 183 * See the License for the specific language governing permissions and 184 * limitations under the License. 185 */function Z(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function J(t,e){if(Object.prototype.hasOwnProperty.call(t,e))return t[e]}function Fe(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}function $e(t,e,n){const i={};for(const r in t)Object.prototype.hasOwnProperty.call(t,r)&&(i[r]=e.call(n,t[r],r,t));return i}function be(t,e){if(t===e)return!0;const n=Object.keys(t),i=Object.keys(e);for(const r of n){if(!i.includes(r))return!1;const s=t[r],l=e[r];if(q(s)&&q(l)){if(!be(s,l))return!1}else if(s!==l)return!1}for(const r of i)if(!n.includes(r))return!1;return!0}function q(t){return t!==null&&typeof t=="object"}/** 186 * @license 187 * Copyright 2022 Google LLC 188 * 189 * Licensed under the Apache License, Version 2.0 (the "License"); 190 * you may not use this file except in compliance with the License. 191 * You may obtain a copy of the License at 192 * 193 * http://www.apache.org/licenses/LICENSE-2.0 194 * 195 * Unless required by applicable law or agreed to in writing, software 196 * distributed under the License is distributed on an "AS IS" BASIS, 197 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 198 * See the License for the specific language governing permissions and 199 * limitations under the License. 200 */function k(t,e=2e3){const n=new R;return setTimeout(()=>n.reject("timeout!"),e),t.then(n.resolve,n.reject),n.promise}/** 201 * @license 202 * Copyright 2017 Google LLC 203 * 204 * Licensed under the Apache License, Version 2.0 (the "License"); 205 * you may not use this file except in compliance with the License. 206 * You may obtain a copy of the License at 207 * 208 * http://www.apache.org/licenses/LICENSE-2.0 209 * 210 * Unless required by applicable law or agreed to in writing, software 211 * distributed under the License is distributed on an "AS IS" BASIS, 212 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 213 * See the License for the specific language governing permissions and 214 * limitations under the License. 215 */function ee(t){const e=[];for(const[n,i]of Object.entries(t))Array.isArray(i)?i.forEach(r=>{e.push(encodeURIComponent(n)+"="+encodeURIComponent(r))}):e.push(encodeURIComponent(n)+"="+encodeURIComponent(i));return e.length?"&"+e.join("&"):""}function me(t){const e={};return t.replace(/^\?/,"").split("&").forEach(i=>{if(i){const[r,s]=i.split("=");e[decodeURIComponent(r)]=decodeURIComponent(s)}}),e}function Ue(t){const e=t.indexOf("?");if(!e)return"";const n=t.indexOf("#",e);return t.substring(e,n>0?n:void 0)}/** 216 * @license 217 * Copyright 2017 Google LLC 218 * 219 * Licensed under the Apache License, Version 2.0 (the "License"); 220 * you may not use this file except in compliance with the License. 221 * You may obtain a copy of the License at 222 * 223 * http://www.apache.org/licenses/LICENSE-2.0 224 * 225 * Unless required by applicable law or agreed to in writing, software 226 * distributed under the License is distributed on an "AS IS" BASIS, 227 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 228 * See the License for the specific language governing permissions and 229 * limitations under the License. 230 */class ge{constructor(){this.chain_=[],this.buf_=[],this.W_=[],this.pad_=[],this.inbuf_=0,this.total_=0,this.blockSize=512/8,this.pad_[0]=128;for(let e=1;e<this.blockSize;++e)this.pad_[e]=0;this.reset()}reset(){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}compress_(e,n){n||(n=0);const i=this.W_;if(typeof e=="string")for(let u=0;u<16;u++)i[u]=e.charCodeAt(n)<<24|e.charCodeAt(n+1)<<16|e.charCodeAt(n+2)<<8|e.charCodeAt(n+3),n+=4;else for(let u=0;u<16;u++)i[u]=e[n]<<24|e[n+1]<<16|e[n+2]<<8|e[n+3],n+=4;for(let u=16;u<80;u++){const S=i[u-3]^i[u-8]^i[u-14]^i[u-16];i[u]=(S<<1|S>>>31)&4294967295}let r=this.chain_[0],s=this.chain_[1],l=this.chain_[2],g=this.chain_[3],D=this.chain_[4],p,A;
230for(let u=0;u<80;u++){u<40?u<20?(p=g^s&(l^g),A=1518500249):(p=s^l^g,A=1859775393):u<60?(p=s&l|g&(s|l),A=2400959708):(p=s^l^g,A=3395469782);const S=(r<<5|r>>>27)+p+D+A+i[u]&4294967295;D=g,g=l,l=(s<<30|s>>>2)&4294967295,s=r,r=S}this.chain_[0]=this.chain_[0]+r&4294967295,this.chain_[1]=this.chain_[1]+s&4294967295,this.chain_[2]=this.chain_[2]+l&4294967295,this.chain_[3]=this.chain_[3]+g&4294967295,this.chain_[4]=this.chain_[4]+D&4294967295}update(e,n){if(e==null)return;n===void 0&&(n=e.length);const i=n-this.blockSize;let r=0;const s=this.buf_;let l=this.inbuf_;for(;r<n;){if(l===0)for(;r<=i;)this.compress_(e,r),r+=this.blockSize;if(typeof e=="string"){for(;r<n;)if(s[l]=e.charCodeAt(r),++l,++r,l===this.blockSize){this.compress_(s),l=0;break}}else for(;r<n;)if(s[l]=e[r],++l,++r,l===this.blockSize){this.compress_(s),l=0;break}}this.inbuf_=l,this.total_+=n}digest(){const e=[];let n=this.total_*8;this.inbuf_<56?this.update(this.pad_,56-this.inbuf_):this.update(this.pad_,this.blockSize-(this.inbuf_-56));for(let r=this.blockSize-1;r>=56;r--)this.buf_[r]=n&255,n/=256;this.compress_(this.buf_);let i=0;for(let r=0;r<5;r++)for(let s=24;s>=0;s-=8)e[i]=this.chain_[r]>>s&255,++i;return e}}function te(t,e){const n=new _e(t,e);return n.subscribe.bind(n)}class _e{constructor(e,n){this.observers=[],this.unsubscribes=[],this.observerCount=0,this.task=Promise.resolve(),this.finalized=!1,this.onNoObservers=n,this.task.then(()=>{e(this)}).catch(i=>{this.error(i)})}next(e){this.forEachObserver(n=>{n.next(e)})}error(e){this.forEachObserver(n=>{n.error(e)}),this.close(e)}complete(){this.forEachObserver(e=>{e.complete()}),this.close()}subscribe(e,n,i){let r;if(e===void 0&&n===void 0&&i===void 0)throw new Error("Missing Observer.");ye(e,["next","error","complete"])?r=e:r={next:e,error:n,complete:i},r.next===void 0&&(r.next=V),r.error===void 0&&(r.error=V),r.complete===void 0&&(r.complete=V);const s=this.unsubscribeOne.bind(this,this.observers.length);return this.finalized&&this.task.then(()=>{try{this.finalError?r.error(this.finalError):r.complete()}catch{}}),this.observers.push(r),s}unsubscribeOne(e){this.observers===void 0||this.observers[e]===void 0||(delete this.observers[e],this.observerCount-=1,this.observerCount===0&&this.onNoObservers!==void 0&&this.onNoObservers(this))}forEachObserver(e){if(!this.finalized)for(let n=0;n<this.observers.length;n++)this.sendOne(n,e)}sendOne(e,n){this.task.then(()=>{if(this.observers!==void 0&&this.observers[e]!==void 0)try{n(this.observers[e])}catch(i){typeof b<"u"&&b.error&&b.error(i)}})}close(e){this.finalized||(this.finalized=!0,e!==void 0&&(this.finalError=e),this.task.then(()=>{this.observers=void 0,this.onNoObservers=void 0}))}}function ke(t,e){return(...n)=>{Promise.resolve(!0).then(()=>{t(...n)}).catch(i=>{e&&e(i)})}}function ye(t,e){if(typeof t!="object"||t===null)return!1;for(const n of e)if(n in t&&typeof t[n]=="function")return!0;return!1}function V(){}/** 231 * @license 232 * Copyright 2017 Google LLC 233 * 234 * Licensed under the Apache License, Version 2.0 (the "License"); 235 * you may not use this file except in compliance with the License. 236 * You may obtain a copy of the License at 237 * 238 * http://www.apache.org/licenses/LICENSE-2.0 239 * 240 * Unless required by applicable law or agreed to in writing, software 241 * distributed under the License is distributed on an "AS IS" BASIS, 242 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 243 * See the License for the specific language governing permissions and 244 * limitations under the License. 245 */const Ve=function(t,e,n,i){let r;if(i<e?r="at least "+e:i>n&&(r=n===0?"none":"no more than "+n),r){const s=t+" failed: Was called with "+i+(i===1?" argument.":" arguments.")+" Expects "+r+".";throw new Error(s)}};function Y(t,e){return`${t} failed: ${e} argument `}function Ee(t,e,n){if(!(n&&!e)&&typeof e!="string")throw new Error(Y(t,"namespace")+"must be a valid firebase namespace.")}function He(t,e,n,i){if(!(i&&!n)&&typeof n!="function")throw new Error(Y(t,e)+"must be a valid function.")}function c(t,e,n,i){if(!(i&&!n)&&(typeof n!="object"||n===null))throw new Error(Y(t,e)+"must be a valid context object.")}/** 246 * @license 247 * Copyright 2017 Google LLC 248 * 249 * Licensed under the Apache License, Version 2.0 (the "License");
250 * you may not use this file except in compliance with the License. 251 * You may obtain a copy of the License at 252 * 253 * http://www.apache.org/licenses/LICENSE-2.0 254 * 255 * Unless required by applicable law or agreed to in writing, software 256 * distributed under the License is distributed on an "AS IS" BASIS, 257 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 258 * See the License for the specific language governing permissions and 259 * limitations under the License. 260 */const o=function(t){const e=[];let n=0;for(let i=0;i<t.length;i++){let r=t.charCodeAt(i);if(r>=55296&&r<=56319){const s=r-55296;i++,B(i<t.length,"Surrogate pair missing trail surrogate.");const l=t.charCodeAt(i)-56320;r=65536+(s<<10)+l}r<128?e[n++]=r:r<2048?(e[n++]=r>>6|192,e[n++]=r&63|128):r<65536?(e[n++]=r>>12|224,e[n++]=r>>6&63|128,e[n++]=r&63|128):(e[n++]=r>>18|240,e[n++]=r>>12&63|128,e[n++]=r>>6&63|128,e[n++]=r&63|128)}return e},a=function(t){let e=0;for(let n=0;n<t.length;n++){const i=t.charCodeAt(n);i<128?e++:i<2048?e+=2:i>=55296&&i<=56319?(e+=4,n++):e+=3}return e};/** 261 * @license 262 * Copyright 2022 Google LLC 263 * 264 * Licensed under the Apache License, Version 2.0 (the "License"); 265 * you may not use this file except in compliance with the License. 266 * You may obtain a copy of the License at 267 * 268 * http://www.apache.org/licenses/LICENSE-2.0 269 * 270 * Unless required by applicable law or agreed to in writing, software 271 * distributed under the License is distributed on an "AS IS" BASIS, 272 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 273 * See the License for the specific language governing permissions and 274 * limitations under the License. 275 */const h=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const e=Math.random()*16|0;return(t==="x"?e:e&3|8).toString(16)})};/** 276 * @license 277 * Copyright 2019 Google LLC 278 * 279 * Licensed under the Apache License, Version 2.0 (the "License"); 280 * you may not use this file except in compliance with the License. 281 * You may obtain a copy of the License at 282 * 283 * http://www.apache.org/licenses/LICENSE-2.0 284 * 285 * Unless required by applicable law or agreed to in writing, software 286 * distributed under the License is distributed on an "AS IS" BASIS, 287 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 288 * See the License for the specific language governing permissions and 289 * limitations under the License. 290 */const d=1e3,v=2,C=null,I=.5;function ve(t,e=d,n=v){const i=e*Math.pow(n,t),r=Math.round(I*i*(Math.random()-.5)*2);return Math.min(C,i+r)}/** 291 * @license 292 * Copyright 2020 Google LLC 293 * 294 * Licensed under the Apache License, Version 2.0 (the "License"); 295 * you may not use this file except in compliance with the License. 296 * You may obtain a copy of the License at 297 * 298 * http://www.apache.org/licenses/LICENSE-2.0 299 * 300 * Unless required by applicable law or agreed to in writing, software 301 * distributed under the License is distributed on an "AS IS" BASIS, 302 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 303 * See the License for the specific language governing permissions and 304 * limitations under the License. 305 */function ot(t){return Number.isFinite(t)?t+Ye(t):`${t}`}function Ye(t){t=Math.abs(t);const e=t%100;if(e>=10&&e<=20)return"th";const n=t%10;return n===1?"st":n===2?"nd":n===3?"rd":"th"}/** 306 * @license 307 * Copyright 2021 Google LLC 308 * 309 * Licensed under the Apache License, Version 2.0 (the "License"); 310 * you may not use this file except in compliance with the License. 311 * You may obtain a copy of the License at 312 * 313 * http://www.apache.org/licenses/LICENSE-2.0 314 * 315 * Unless required by applicable law or agreed to in writing, software 316 * distributed under the License is distributed on an "AS IS" BASIS, 317 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 318 * See the License for the specific language governing permissions and 319 * limitations under the License. 320 */function at(t){return t&&t._delegate?t._delegate:t}var Ge=f(700134),w=f(569971),Xe=f(790938);/** 321 * @license 322 * Copyright 2020 Google LLC 323 * 324 * Licensed under the Apache License, Version 2.0 (the "License");
325 * you may not use this file except in compliance with the License. 326 * You may obtain a copy of the License at 327 * 328 * http://www.apache.org/licenses/LICENSE-2.0 329 * 330 * Unless required by applicable law or agreed to in writing, software 331 * distributed under the License is distributed on an "AS IS" BASIS, 332 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 333 * See the License for the specific language governing permissions and 334 * limitations under the License. 335 */class Qe{constructor(e,n){this._delegate=e,this.firebase=n,(0,w._addComponent)(e,new Ge.uA("app-compat",()=>this,"PUBLIC")),this.container=e.container}get automaticDataCollectionEnabled(){return this._delegate.automaticDataCollectionEnabled}set automaticDataCollectionEnabled(e){this._delegate.automaticDataCollectionEnabled=e}get name(){return this._delegate.name}get options(){return this._delegate.options}delete(){return new Promise(e=>{this._delegate.checkDestroyed(),e()}).then(()=>(this.firebase.INTERNAL.removeApp(this.name),(0,w.deleteApp)(this._delegate)))}_getService(e,n=w._DEFAULT_ENTRY_NAME){var i;this._delegate.checkDestroyed();const r=this._delegate.container.getProvider(e);return!r.isInitialized()&&((i=r.getComponent())===null||i===void 0?void 0:i.instantiationMode)==="EXPLICIT"&&r.initialize(),r.getImmediate({identifier:n})}_removeServiceInstance(e,n=w._DEFAULT_ENTRY_NAME){this._delegate.container.getProvider(e).clearInstance(n)}_addComponent(e){(0,w._addComponent)(this._delegate,e)}_addOrOverwriteComponent(e){(0,w._addOrOverwriteComponent)(this._delegate,e)}toJSON(){return{name:this.name,automaticDataCollectionEnabled:this.automaticDataCollectionEnabled,options:this.options}}}/** 336 * @license 337 * Copyright 2019 Google LLC 338 * 339 * Licensed under the Apache License, Version 2.0 (the "License"); 340 * you may not use this file except in compliance with the License. 341 * You may obtain a copy of the License at 342 * 343 * http://www.apache.org/licenses/LICENSE-2.0 344 * 345 * Unless required by applicable law or agreed to in writing, software 346 * distributed under the License is distributed on an "AS IS" BASIS, 347 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 348 * See the License for the specific language governing permissions and 349 * limitations under the License. 350 */const Ze={["no-app"]:"No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",["invalid-app-argument"]:"firebase.{$appName}() takes either no argument or a Firebase App instance."},We=new $("app-compat","Firebase",Ze);/** 351 * @license 352 * Copyright 2019 Google LLC 353 * 354 * Licensed under the Apache License, Version 2.0 (the "License"); 355 * you may not use this file except in compliance with the License. 356 * You may obtain a copy of the License at 357 * 358 * http://www.apache.org/licenses/LICENSE-2.0 359 * 360 * Unless required by applicable law or agreed to in writing, software 361 * distributed under the License is distributed on an "AS IS" BASIS, 362 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 363 * See the License for the specific language governing permissions and 364 * limitations under the License. 365 */function qe(t){const e={},n={__esModule:!0,initializeApp:s,app:r,registerVersion:w.registerVersion,setLogLevel:w.setLogLevel,onLog:w.onLog,apps:null,SDK_VERSION:w.SDK_VERSION,INTERNAL:{registerComponent:g,removeApp:i,useAsService:D,modularAPIs:w}};n.default=n,Object.defineProperty(n,"apps",{get:l});function i(p){delete e[p]}function r(p){if(p=p||w._DEFAULT_ENTRY_NAME,!Z(e,p))throw We.create("no-app",{appName:p});return e[p]}r.App=t;function s(p,A={}){const u=w.initializeApp(p,A);if(Z(e,u.name))return e[u.name];const S=new t(u,n);return e[u.name]=S,S}function l(){return Object.keys(e).map(p=>e[p])}function g(p){const A=p.name,u=A.replace("-compat","");if(w._registerComponent(p)&&p.type==="PUBLIC"){const S=(N=r())=>{if(typeof N[u]!="function")throw We.create("invalid-app-argument",{appName:A});return N[u]()};p.serviceProps!==void 0&&M(S,p.serviceProps),n[u]=S,t.prototype[u]=function(...N){return this._getService.bind(this,A).apply(this,p.multipleInstances?N:[])}}return p.type==="PUBLIC"?n[u]:null}function D(p,A){return A==="serverAuth"?null:A}return n}/** 366 * @license 367 * Copyright 2019 Google LLC 368 * 369 * Licensed under the Apache License, Version 2.0 (the "License");
370 * you may not use this file except in compliance with the License. 371 * You may obtain a copy of the License at 372 * 373 * http://www.apache.org/licenses/LICENSE-2.0 374 * 375 * Unless required by applicable law or agreed to in writing, software 376 * distributed under the License is distributed on an "AS IS" BASIS, 377 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 378 * See the License for the specific language governing permissions and 379 * limitations under the License. 380 */function ze(){const t=qe(Qe);t.INTERNAL=Object.assign(Object.assign({},t.INTERNAL),{createFirebaseNamespace:ze,extendNamespace:e,createSubscribe:te,ErrorFactory:$,deepExtend:M});function e(n){M(t,n)}return t}const et=ze();/** 381 * @license 382 * Copyright 2019 Google LLC 383 * 384 * Licensed under the Apache License, Version 2.0 (the "License"); 385 * you may not use this file except in compliance with the License. 386 * You may obtain a copy of the License at 387 * 388 * http://www.apache.org/licenses/LICENSE-2.0 389 * 390 * Unless required by applicable law or agreed to in writing, software 391 * distributed under the License is distributed on an "AS IS" BASIS, 392 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 393 * See the License for the specific language governing permissions and 394 * limitations under the License. 395 */const Ke=new Xe.Vy("@firebase/app-compat"),tt="@firebase/app-compat",nt="0.1.38";/** 396 * @license 397 * Copyright 2019 Google LLC 398 * 399 * Licensed under the Apache License, Version 2.0 (the "License"); 400 * you may not use this file except in compliance with the License. 401 * You may obtain a copy of the License at 402 * 403 * http://www.apache.org/licenses/LICENSE-2.0 404 * 405 * Unless required by applicable law or agreed to in writing, software 406 * distributed under the License is distributed on an "AS IS" BASIS, 407 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 408 * See the License for the specific language governing permissions and 409 * limitations under the License. 410 */function rt(t){(0,w.registerVersion)(tt,nt,t)}/** 411 * @license 412 * Copyright 2020 Google LLC 413 * 414 * Licensed under the Apache License, Version 2.0 (the "License"); 415 * you may not use this file except in compliance with the License. 416 * You may obtain a copy of the License at 417 * 418 * http://www.apache.org/licenses/LICENSE-2.0 419 * 420 * Unless required by applicable law or agreed to in writing, software 421 * distributed under the License is distributed on an "AS IS" BASIS, 422 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 423 * See the License for the specific language governing permissions and 424 * limitations under the License. 425 */if(ie()&&self.firebase!==void 0){Ke.warn(` 426 Warning: Firebase is already defined in the global scope. Please make sure 427 Firebase library is only loaded once. 428 `);const t=self.firebase.SDK_VERSION;t&&t.indexOf("LITE")>=0&&Ke.warn(` 429 Warning: You are trying to load Firebase while using Firebase Performance standalone script. 430 You should load Firebase Performance with this instance of Firebase to avoid loading duplicate code. 431 `)}const it=et;rt()},569971:(y,E,f)=>{"use strict";f.r(E),f.d(E,{FirebaseError:()=>m.g,SDK_VERSION:()=>Re,_DEFAULT_ENTRY_NAME:()=>F,_addComponent:()=>le,_addOrOverwriteComponent:()=>ue,_apps:()=>T,_clearComponents:()=>he,_components:()=>R,_getProvider:()=>$,_registerComponent:()=>P,_removeServiceInstance:()=>de,deleteApp:()=>Z,getApp:()=>je,getApps:()=>Le,initializeApp:()=>pe,onLog:()=>Fe,registerVersion:()=>J,setLogLevel:()=>$e});var b=f(700134),_=f(790938),m=f(676010),B=f(138674);/** 432 * @license 433 * Copyright 2019 Google LLC 434 * 435 * Licensed under the Apache License, Version 2.0 (the "License"); 436 * you may not use this file except in compliance with the License. 437 * You may obtain a copy of the License at 438 * 439 * http://www.apache.org/licenses/LICENSE-2.0 440 * 441 * Unless required by applicable law or agreed to in writing, software 442 * distributed under the License is distributed on an "AS IS" BASIS, 443 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 444 * See the License for the specific language governing permissions and 445 * limitations under the License. 446 */class j{constructor(o){this.container=o}getPlatformInfoString(){return this.container.getProviders().map(a=>{if(G(a)){const h=a.getImmediate();return`${h.library}/${h.version}`}else return null}).filter(a=>a).join(" ")}}function G(c){const o=c.getComponent();return o?.type==="VERSION"}const H="@firebase/app",W="0.8.3";/** 447 * @license 448 * Copyright 2019 Google LLC 449 * 450 * Licensed under the Apache License, Version 2.0 (the "License");
451 * you may not use this file except in compliance with the License. 452 * You may obtain a copy of the License at 453 * 454 * http://www.apache.org/licenses/LICENSE-2.0 455 * 456 * Unless required by applicable law or agreed to in writing, software 457 * distributed under the License is distributed on an "AS IS" BASIS, 458 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 459 * See the License for the specific language governing permissions and 460 * limitations under the License. 461 */const x=new _.Vy("@firebase/app"),X="@firebase/app-compat",z="@firebase/analytics-compat",Ae="@firebase/analytics",M="@firebase/app-check-compat",ne="@firebase/app-check",L="@firebase/auth",we="@firebase/auth-compat",re="@firebase/database",ie="@firebase/database-compat",Se="@firebase/functions",De="@firebase/functions-compat",Ce="@firebase/installations",Oe="@firebase/installations-compat",xe="@firebase/messaging",Te="@firebase/messaging-compat",Ie="@firebase/performance",Ne="@firebase/performance-compat",Be="@firebase/remote-config",Pe="@firebase/remote-config-compat",oe="@firebase/storage",ae="@firebase/storage-compat",se="@firebase/firestore",ce="@firebase/firestore-compat",K="firebase",fe="9.13.0";/** 462 * @license 463 * Copyright 2019 Google LLC 464 * 465 * Licensed under the Apache License, Version 2.0 (the "License"); 466 * you may not use this file except in compliance with the License. 467 * You may obtain a copy of the License at 468 * 469 * http://www.apache.org/licenses/LICENSE-2.0 470 * 471 * Unless required by applicable law or agreed to in writing, software 472 * distributed under the License is distributed on an "AS IS" BASIS, 473 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 474 * See the License for the specific language governing permissions and 475 * limitations under the License. 476 */const F="[DEFAULT]",Me={[H]:"fire-core",[X]:"fire-core-compat",[Ae]:"fire-analytics",[z]:"fire-analytics-compat",[ne]:"fire-app-check",[M]:"fire-app-check-compat",[L]:"fire-auth",[we]:"fire-auth-compat",[re]:"fire-rtdb",[ie]:"fire-rtdb-compat",[Se]:"fire-fn",[De]:"fire-fn-compat",[Ce]:"fire-iid",[Oe]:"fire-iid-compat",[xe]:"fire-fcm",[Te]:"fire-fcm-compat",[Ie]:"fire-perf",[Ne]:"fire-perf-compat",[Be]:"fire-rc",[Pe]:"fire-rc-compat",[oe]:"fire-gcs",[ae]:"fire-gcs-compat",[se]:"fire-fst",[ce]:"fire-fst-compat","fire-js":"fire-js",[K]:"fire-js-all"};/** 477 * @license 478 * Copyright 2019 Google LLC 479 * 480 * Licensed under the Apache License, Version 2.0 (the "License"); 481 * you may not use this file except in compliance with the License. 482 * You may obtain a copy of the License at 483 * 484 * http://www.apache.org/licenses/LICENSE-2.0 485 * 486 * Unless required by applicable law or agreed to in writing, software 487 * distributed under the License is distributed on an "AS IS" BASIS, 488 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 489 * See the License for the specific language governing permissions and 490 * limitations under the License. 491 */const T=new Map,R=new Map;function le(c,o){try{c.container.addComponent(o)}catch(a){x.debug(`Component ${o.name} failed to register with FirebaseApp ${c.name}`,a)}}function ue(c,o){c.container.addOrOverwriteComponent(o)}function P(c){const o=c.name;if(R.has(o))return x.debug(`There were multiple attempts to register component ${o}.`),!1;R.set(o,c);for(const a of T.values())le(a,c);return!0}function $(c,o){const a=c.container.getProvider("heartbeat").getImmediate({optional:!0});return a&&a.triggerHeartbeat(),c.container.getProvider(o)}function de(c,o,a=F){$(c,o).clearInstance(a)}function he(){R.clear()}/** 492 * @license 493 * Copyright 2019 Google LLC 494 * 495 * Licensed under the Apache License, Version 2.0 (the "License"); 496 * you may not use this file except in compliance with the License. 497 * You may obtain a copy of the License at 498 * 499 * http://www.apache.org/licenses/LICENSE-2.0 500 * 501 * Unless required by applicable law or agreed to in writing, software 502 * distributed under the License is distributed on an "AS IS" BASIS, 503 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 504 * See the License for the specific language governing permissions and 505 * limitations under the License. 506 */const Q={["no-app"]:"No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",["bad-app-name"]:"Illegal App name: '{$appName}",["duplicate-app"]:"Firebase App named '{$appName}' already exists with different options or config",["app-deleted"]:"Firebase App named '{$appName}' already deleted",["no-options"]:"Need to provide options, when not being deployed to hosting via source.",["invali
506d-app-argument"]:"firebase.{$appName}() takes either no argument or a Firebase App instance.",["invalid-log-argument"]:"First argument to `onLog` must be null or a function.",["idb-open"]:"Error thrown when opening IndexedDB. Original error: {$originalErrorMessage}.",["idb-get"]:"Error thrown when reading from IndexedDB. Original error: {$originalErrorMessage}.",["idb-set"]:"Error thrown when writing to IndexedDB. Original error: {$originalErrorMessage}.",["idb-delete"]:"Error thrown when deleting from IndexedDB. Original error: {$originalErrorMessage}."},O=new m.FA("app","Firebase",Q);/** 507 * @license 508 * Copyright 2019 Google LLC 509 * 510 * Licensed under the Apache License, Version 2.0 (the "License"); 511 * you may not use this file except in compliance with the License. 512 * You may obtain a copy of the License at 513 * 514 * http://www.apache.org/licenses/LICENSE-2.0 515 * 516 * Unless required by applicable law or agreed to in writing, software 517 * distributed under the License is distributed on an "AS IS" BASIS, 518 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 519 * See the License for the specific language governing permissions and 520 * limitations under the License. 521 */class U{constructor(o,a,h){this._isDeleted=!1,this._options=Object.assign({},o),this._config=Object.assign({},a),this._name=a.name,this._automaticDataCollectionEnabled=a.automaticDataCollectionEnabled,this._container=h,this.container.addComponent(new b.uA("app",()=>this,"PUBLIC"))}get automaticDataCollectionEnabled(){return this.checkDestroyed(),this._automaticDataCollectionEnabled}set automaticDataCollectionEnabled(o){this.checkDestroyed(),this._automaticDataCollectionEnabled=o}get name(){return this.checkDestroyed(),this._name}get options(){return this.checkDestroyed(),this._options}get config(){return this.checkDestroyed(),this._config}get container(){return this._container}get isDeleted(){return this._isDeleted}set isDeleted(o){this._isDeleted=o}checkDestroyed(){if(this.isDeleted)throw O.create("app-deleted",{appName:this._name})}}/** 522 * @license 523 * Copyright 2019 Google LLC 524 * 525 * Licensed under the Apache License, Version 2.0 (the "License"); 526 * you may not use this file except in compliance with the License. 527 * You may obtain a copy of the License at 528 * 529 * http://www.apache.org/licenses/LICENSE-2.0 530 * 531 * Unless required by applicable law or agreed to in writing, software 532 * distributed under the License is distributed on an "AS IS" BASIS, 533 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 534 * See the License for the specific language governing permissions and 535 * limitations under the License. 536 */const Re=fe;function pe(c,o={}){let a=c;typeof o!="object"&&(o={name:o});const h=Object.assign({name:F,automaticDataCollectionEnabled:!1},o),d=h.name;if(typeof d!="string"||!d)throw O.create("bad-app-name",{appName:String(d)});if(a||(a=(0,m.T9)()),!a)throw O.create("no-options");const v=T.get(d);if(v){if((0,m.bD)(a,v.options)&&(0,m.bD)(h,v.config))return v;throw O.create("duplicate-app",{appName:d})}const C=new b.h1(d);for(const ve of R.values())C.addComponent(ve);const I=new U(a,h,C);return T.set(d,I),I}function je(c=F){const o=T.get(c);if(!o&&c===F)return pe();if(!o)throw O.create("no-app",{appName:c});return o}function Le(){return Array.from(T.values())}async function Z(c){const o=c.name;T.has(o)&&(T.delete(o),await Promise.all(c.container.getProviders().map(a=>a.delete())),c.isDeleted=!0)}function J(c,o,a){var h;let d=(h=Me[c])!==null&&h!==void 0?h:c;a&&(d+=`-${a}`);const v=d.match(/\s|\//),C=o.match(/\s|\//);if(v||C){const I=[`Unable to register library "${d}" with version "${o}":`];v&&I.push(`library name "${d}" contains illegal characters (whitespace or "/")`),v&&C&&I.push("and"),C&&I.push(`version name "${o}" contains illegal characters (whitespace or "/")`),x.warn(I.join(" "));return}P(new b.uA(`${d}-version`,()=>({library:d,version:o}),"VERSION"))}function Fe(c,o){if(c!==null&&typeof c!="function")throw O.create("invalid-log-argument");(0,_.Ey)(c,o)}function $e(c){(0,_.He)(c)}/** 537 * @license 538 * Copyright 2021 Google LLC 539 * 540 * Licensed under the Apache License, Version 2.0 (the "License");
541 * you may not use this file except in compliance with the License. 542 * You may obtain a copy of the License at 543 * 544 * http://www.apache.org/licenses/LICENSE-2.0 545 * 546 * Unless required by applicable law or agreed to in writing, software 547 * distributed under the License is distributed on an "AS IS" BASIS, 548 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 549 * See the License for the specific language governing permissions and 550 * limitations under the License. 551 */const be="firebase-heartbeat-database",q=1,k="firebase-heartbeat-store";let ee=null;function me(){return ee||(ee=(0,B.P2)(be,q,{upgrade:(c,o)=>{switch(o){case 0:c.createObjectStore(k)}}}).catch(c=>{throw O.create("idb-open",{originalErrorMessage:c.message})})),ee}async function Ue(c){var o;try{return(await me()).transaction(k).objectStore(k).get(te(c))}catch(a){if(a instanceof m.g)x.warn(a.message);else{const h=O.create("idb-get",{originalErrorMessage:(o=a)===null||o===void 0?void 0:o.message});x.warn(h.message)}}}async function ge(c,o){var a;try{const d=(await me()).transaction(k,"readwrite");return await d.objectStore(k).put(o,te(c)),d.done}catch(h){if(h instanceof m.g)x.warn(h.message);else{const d=O.create("idb-set",{originalErrorMessage:(a=h)===null||a===void 0?void 0:a.message});x.warn(d.message)}}}function te(c){return`${c.name}!${c.options.appId}`}/** 552 * @license 553 * Copyright 2021 Google LLC 554 * 555 * Licensed under the Apache License, Version 2.0 (the "License"); 556 * you may not use this file except in compliance with the License. 557 * You may obtain a copy of the License at 558 * 559 * http://www.apache.org/licenses/LICENSE-2.0 560 * 561 * Unless required by applicable law or agreed to in writing, software 562 * distributed under the License is distributed on an "AS IS" BASIS, 563 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 564 * See the License for the specific language governing permissions and 565 * limitations under the License. 566 */const _e=1024,ke=30*24*60*60*1e3;class ye{constructor(o){this.container=o,this._heartbeatsCache=null;const a=this.container.getProvider("app").getImmediate();this._storage=new Y(a),this._heartbeatsCachePromise=this._storage.read().then(h=>(this._heartbeatsCache=h,h))}async triggerHeartbeat(){const a=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),h=V();if(this._heartbeatsCache===null&&(this._heartbeatsCache=await this._heartbeatsCachePromise),!(this._heartbeatsCache.lastSentHeartbeatDate===h||this._heartbeatsCache.heartbeats.some(d=>d.date===h)))return this._heartbeatsCache.heartbeats.push({date:h,agent:a}),this._heartbeatsCache.heartbeats=this._heartbeatsCache.heartbeats.filter(d=>{const v=new Date(d.date).valueOf();return Date.now()-v<=ke}),this._storage.overwrite(this._heartbeatsCache)}async getHeartbeatsHeader(){if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,this._heartbeatsCache===null||this._heartbeatsCache.heartbeats.length===0)return"";const o=V(),{heartbeatsToSend:a,unsentEntries:h}=Ve(this._heartbeatsCache.heartbeats),d=(0,m.Uj)(JSON.stringify({version:2,heartbeats:a}));return this._heartbeatsCache.lastSentHeartbeatDate=o,h.length>0?(this._heartbeatsCache.heartbeats=h,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),d}}function V(){return new Date().toISOString().substring(0,10)}function Ve(c,o=_e){const a=[];let h=c.slice();for(const d of c){const v=a.find(C=>C.agent===d.agent);if(v){if(v.dates.push(d.date),Ee(a)>o){v.dates.pop();break}}else if(a.push({agent:d.agent,dates:[d.date]}),Ee(a)>o){a.pop();break}h=h.slice(1)}return{heartbeatsToSend:a,unsentEntries:h}}class Y{constructor(o){this.app=o,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return(0,m.zW)()?(0,m.eX)().then(()=>!0).catch(()=>!1):!1}async read(){return await this._canUseIndexedDBPromise?await Ue(this.app)||{heartbeats:[]}:{heartbeats:[]}}async overwrite(o){var a;if(await this._canUseIndexedDBPromise){const d=await this.read();return ge(this.app,{lastSentHeartbeatDate:(a=o.lastSentHeartbeatDate)!==null&&a!==void 0?a:d.lastSentHeartbeatDate,heartbeats:o.heartbeats})}else return}async add(o){var a;if(await this._canUseIndexedDBPromise){const d=await this.read();return ge(this.app,{lastSentHeartbeatDate:(a=o.lastSentHeartbeatDate)!==null&&a!==void 0?a:d.lastSentHeartbeatDate,heartbeats:[...d.heartbeats,...o.heartbeats]})}else return}}function Ee(c){return(0,m.Uj)(JSON.stringify({version:2,heartbeats:c})).length}/** 567 * @license 568 * Copyright 2019 Google LLC 569 * 570 * Licensed under the Apache License, Version 2.0 (the "License");
571 * you may not use this file except in compliance with the License. 572 * You may obtain a copy of the License at 573 * 574 * http://www.apache.org/licenses/LICENSE-2.0 575 * 576 * Unless required by applicable law or agreed to in writing, software 577 * distributed under the License is distributed on an "AS IS" BASIS, 578 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 579 * See the License for the specific language governing permissions and 580 * limitations under the License. 581 */function He(c){P(new b.uA("platform-logger",o=>new j(o),"PRIVATE")),P(new b.uA("heartbeat",o=>new ye(o),"PRIVATE")),J(H,W,c),J(H,W,"esm2017"),J("fire-js","")}He("")}}]);
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.