@blinkk/root-cms 2.1.1 → 2.1.2-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ui/signin.js CHANGED
@@ -1,7 +1,21 @@
1
- "use strict";(()=>{var Cn=function(n){let e=[],t=0;for(let r=0;r<n.length;r++){let i=n.charCodeAt(r);i<128?e[t++]=i:i<2048?(e[t++]=i>>6|192,e[t++]=i&63|128):(i&64512)===55296&&r+1<n.length&&(n.charCodeAt(r+1)&64512)===56320?(i=65536+((i&1023)<<10)+(n.charCodeAt(++r)&1023),e[t++]=i>>18|240,e[t++]=i>>12&63|128,e[t++]=i>>6&63|128,e[t++]=i&63|128):(e[t++]=i>>12|224,e[t++]=i>>6&63|128,e[t++]=i&63|128)}return e},Ei=function(n){let e=[],t=0,r=0;for(;t<n.length;){let i=n[t++];if(i<128)e[r++]=String.fromCharCode(i);else if(i>191&&i<224){let s=n[t++];e[r++]=String.fromCharCode((i&31)<<6|s&63)}else if(i>239&&i<365){let s=n[t++],o=n[t++],c=n[t++],a=((i&7)<<18|(s&63)<<12|(o&63)<<6|c&63)-65536;e[r++]=String.fromCharCode(55296+(a>>10)),e[r++]=String.fromCharCode(56320+(a&1023))}else{let s=n[t++],o=n[t++];e[r++]=String.fromCharCode((i&15)<<12|(s&63)<<6|o&63)}}return e.join("")},Nn={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(n,e){if(!Array.isArray(n))throw Error("encodeByteArray takes an array as a parameter");this.init_();let t=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,r=[];for(let i=0;i<n.length;i+=3){let s=n[i],o=i+1<n.length,c=o?n[i+1]:0,a=i+2<n.length,l=a?n[i+2]:0,d=s>>2,u=(s&3)<<4|c>>4,_=(c&15)<<2|l>>6,h=l&63;a||(h=64,o||(_=64)),r.push(t[d],t[u],t[_],t[h])}return r.join("")},encodeString(n,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(n):this.encodeByteArray(Cn(n),e)},decodeString(n,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(n):Ei(this.decodeStringToByteArray(n,e))},decodeStringToByteArray(n,e){this.init_();let t=e?this.charToByteMapWebSafe_:this.charToByteMap_,r=[];for(let i=0;i<n.length;){let s=t[n.charAt(i++)],c=i<n.length?t[n.charAt(i)]:0;++i;let l=i<n.length?t[n.charAt(i)]:64;++i;let u=i<n.length?t[n.charAt(i)]:64;if(++i,s==null||c==null||l==null||u==null)throw new Tt;let _=s<<2|c>>4;if(r.push(_),l!==64){let h=c<<4&240|l>>2;if(r.push(h),u!==64){let v=l<<6&192|u;r.push(v)}}}return r},init_(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(let n=0;n<this.ENCODED_VALS.length;n++)this.byteToCharMap_[n]=this.ENCODED_VALS.charAt(n),this.charToByteMap_[this.byteToCharMap_[n]]=n,this.byteToCharMapWebSafe_[n]=this.ENCODED_VALS_WEBSAFE.charAt(n),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[n]]=n,n>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(n)]=n,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(n)]=n)}}},Tt=class extends Error{constructor(){super(...arguments),this.name="DecodeBase64StringError"}},wi=function(n){let e=Cn(n);return Nn.encodeByteArray(e,!0)},St=function(n){return wi(n).replace(/\./g,"")},Rt=function(n){try{return Nn.decodeString(n,!0)}catch(e){console.error("base64Decode failed: ",e)}return null};function bi(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("Unable to locate global object.")}var Ti=()=>bi().__FIREBASE_DEFAULTS__,Ai=()=>{if(typeof process>"u"||typeof process.env>"u")return;let n=process.env.__FIREBASE_DEFAULTS__;if(n)return JSON.parse(n)},Si=()=>{if(typeof document>"u")return;let n;try{n=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}let e=n&&Rt(n[1]);return e&&JSON.parse(e)},kt=()=>{try{return Ti()||Ai()||Si()}catch(n){console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${n}`);return}},Dn=n=>{var e,t;return(t=(e=kt())===null||e===void 0?void 0:e.emulatorHosts)===null||t===void 0?void 0:t[n]};var Ot=()=>{var n;return(n=kt())===null||n===void 0?void 0:n.config},Pt=n=>{var e;return(e=kt())===null||e===void 0?void 0:e[`_${n}`]};var Le=class{constructor(){this.reject=()=>{},this.resolve=()=>{},this.promise=new Promise((e,t)=>{this.resolve=e,this.reject=t})}wrapCallback(e){return(t,r)=>{t?this.reject(t):this.resolve(r),typeof e=="function"&&(this.promise.catch(()=>{}),e.length===1?e(t):e(t,r))}}};function b(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function Ln(){return typeof window<"u"&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(b())}function Mn(){let n=typeof chrome=="object"?chrome.runtime:typeof browser=="object"?browser.runtime:void 0;return typeof n=="object"&&n.id!==void 0}function xn(){return typeof navigator=="object"&&navigator.product==="ReactNative"}function Un(){let n=b();return n.indexOf("MSIE ")>=0||n.indexOf("Trident/")>=0}function Fn(){try{return typeof indexedDB=="object"}catch{return!1}}function Vn(){return new Promise((n,e)=>{try{let t=!0,r="validate-browser-context-for-indexeddb-analytics-module",i=self.indexedDB.open(r);i.onsuccess=()=>{i.result.close(),t||self.indexedDB.deleteDatabase(r),n(!0)},i.onupgradeneeded=()=>{t=!1},i.onerror=()=>{var s;e(((s=i.error)===null||s===void 0?void 0:s.message)||"")}}catch(t){e(t)}})}var Ri="FirebaseError",P=class n extends Error{constructor(e,t,r){super(t),this.code=e,this.customData=r,this.name=Ri,Object.setPrototypeOf(this,n.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,x.prototype.create)}},x=class{constructor(e,t,r){this.service=e,this.serviceName=t,this.errors=r}create(e,...t){let r=t[0]||{},i=`${this.service}/${e}`,s=this.errors[e],o=s?ki(s,r):"Error",c=`${this.serviceName}: ${o} (${i}).`;return new P(i,c,r)}};function ki(n,e){return n.replace(Oi,(t,r)=>{let i=e[r];return i!=null?String(i):`<${r}?>`})}var Oi=/\{\$([^}]+)}/g;function Hn(n){for(let e in n)if(Object.prototype.hasOwnProperty.call(n,e))return!1;return!0}function se(n,e){if(n===e)return!0;let t=Object.keys(n),r=Object.keys(e);for(let i of t){if(!r.includes(i))return!1;let s=n[i],o=e[i];if(Pn(s)&&Pn(o)){if(!se(s,o))return!1}else if(s!==o)return!1}for(let i of r)if(!t.includes(i))return!1;return!0}function Pn(n){return n!==null&&typeof n=="object"}function oe(n){let e=[];for(let[t,r]of Object.entries(n))Array.isArray(r)?r.forEach(i=>{e.push(encodeURIComponent(t)+"="+encodeURIComponent(i))}):e.push(encodeURIComponent(t)+"="+encodeURIComponent(r));return e.length?"&"+e.join("&"):""}function ae(n){let e={};return n.replace(/^\?/,"").split("&").forEach(r=>{if(r){let[i,s]=r.split("=");e[decodeURIComponent(i)]=decodeURIComponent(s)}}),e}function ce(n){let e=n.indexOf("?");if(!e)return"";let t=n.indexOf("#",e);return n.substring(e,t>0?t:void 0)}function Wn(n,e){let t=new At(n,e);return t.subscribe.bind(t)}var At=class{constructor(e,t){this.observers=[],this.unsubscribes=[],this.observerCount=0,this.task=Promise.resolve(),this.finalized=!1,this.onNoObservers=t,this.task.then(()=>{e(this)}).catch(r=>{this.error(r)})}next(e){this.forEachObserver(t=>{t.next(e)})}error(e){this.forEachObserver(t=>{t.error(e)}),this.close(e)}complete(){this.forEachObserver(e=>{e.complete()}),this.close()}subscribe(e,t,r){let i;if(e===void 0&&t===void 0&&r===void 0)throw new Error("Missing Observer.");Pi(e,["next","error","complete"])?i=e:i={next:e,error:t,complete:r},i.next===void 0&&(i.next=bt),i.error===void 0&&(i.error=bt),i.complete===void 0&&(i.complete=bt);let s=this.unsubscribeOne.bind(this,this.observers.length);return this.finalized&&this.task.then(()=>{try{this.finalError?i.error(this.finalError):i.complete()}catch{}}),this.observers.push(i),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 t=0;t<this.observers.length;t++)this.sendOne(t,e)}sendOne(e,t){this.task.then(()=>{if(this.observers!==void 0&&this.observers[e]!==void 0)try{t(this.observers[e])}catch(r){typeof console<"u"&&console.error&&console.error(r)}})}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 Pi(n,e){if(typeof n!="object"||n===null)return!1;for(let t of e)if(t in n&&typeof n[t]=="function")return!0;return!1}function bt(){}var Ka=4*60*60*1e3;function H(n){return n&&n._delegate?n._delegate:n}var C=class{constructor(e,t,r){this.name=e,this.instanceFactory=t,this.type=r,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}setInstantiationMode(e){return this.instantiationMode=e,this}setMultipleInstances(e){return this.multipleInstances=e,this}setServiceProps(e){return this.serviceProps=e,this}setInstanceCreatedCallback(e){return this.onInstanceCreated=e,this}};var G="[DEFAULT]";var Ct=class{constructor(e,t){this.name=e,this.container=t,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}get(e){let t=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(t)){let r=new Le;if(this.instancesDeferred.set(t,r),this.isInitialized(t)||this.shouldAutoInitialize())try{let i=this.getOrInitializeService({instanceIdentifier:t});i&&r.resolve(i)}catch{}}return this.instancesDeferred.get(t).promise}getImmediate(e){var t;let r=this.normalizeInstanceIdentifier(e?.identifier),i=(t=e?.optional)!==null&&t!==void 0?t:!1;if(this.isInitialized(r)||this.shouldAutoInitialize())try{return this.getOrInitializeService({instanceIdentifier:r})}catch(s){if(i)return null;throw s}else{if(i)return null;throw Error(`Service ${this.name} is not available`)}}getComponent(){return this.component}setComponent(e){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,!!this.shouldAutoInitialize()){if(Ni(e))try{this.getOrInitializeService({instanceIdentifier:G})}catch{}for(let[t,r]of this.instancesDeferred.entries()){let i=this.normalizeInstanceIdentifier(t);try{let s=this.getOrInitializeService({instanceIdentifier:i});r.resolve(s)}catch{}}}}clearInstance(e=G){this.instancesDeferred.delete(e),this.instancesOptions.delete(e),this.instances.delete(e)}async delete(){let e=Array.from(this.instances.values());await Promise.all([...e.filter(t=>"INTERNAL"in t).map(t=>t.INTERNAL.delete()),...e.filter(t=>"_delete"in t).map(t=>t._delete())])}isComponentSet(){return this.component!=null}isInitialized(e=G){return this.instances.has(e)}getOptions(e=G){return this.instancesOptions.get(e)||{}}initialize(e={}){let{options:t={}}=e,r=this.normalizeInstanceIdentifier(e.instanceIdentifier);if(this.isInitialized(r))throw Error(`${this.name}(${r}) has already been initialized`);if(!this.isComponentSet())throw Error(`Component ${this.name} has not been registered yet`);let i=this.getOrInitializeService({instanceIdentifier:r,options:t});for(let[s,o]of this.instancesDeferred.entries()){let c=this.normalizeInstanceIdentifier(s);r===c&&o.resolve(i)}return i}onInit(e,t){var r;let i=this.normalizeInstanceIdentifier(t),s=(r=this.onInitCallbacks.get(i))!==null&&r!==void 0?r:new Set;s.add(e),this.onInitCallbacks.set(i,s);let o=this.instances.get(i);return o&&e(o,i),()=>{s.delete(e)}}invokeOnInitCallbacks(e,t){let r=this.onInitCallbacks.get(t);if(r)for(let i of r)try{i(e,t)}catch{}}getOrInitializeService({instanceIdentifier:e,options:t={}}){let r=this.instances.get(e);if(!r&&this.component&&(r=this.component.instanceFactory(this.container,{instanceIdentifier:Ci(e),options:t}),this.instances.set(e,r),this.instancesOptions.set(e,t),this.invokeOnInitCallbacks(r,e),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,e,r)}catch{}return r||null}normalizeInstanceIdentifier(e=G){return this.component?this.component.multipleInstances?e:G:e}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}};function Ci(n){return n===G?void 0:n}function Ni(n){return n.instantiationMode==="EAGER"}var Me=class{constructor(e){this.name=e,this.providers=new Map}addComponent(e){let t=this.getProvider(e.name);if(t.isComponentSet())throw new Error(`Component ${e.name} has already been registered with ${this.name}`);t.setComponent(e)}addOrOverwriteComponent(e){this.getProvider(e.name).isComponentSet()&&this.providers.delete(e.name),this.addComponent(e)}getProvider(e){if(this.providers.has(e))return this.providers.get(e);let t=new Ct(e,this);return this.providers.set(e,t),t}getProviders(){return Array.from(this.providers.values())}};var Di=[],m;(function(n){n[n.DEBUG=0]="DEBUG",n[n.VERBOSE=1]="VERBOSE",n[n.INFO=2]="INFO",n[n.WARN=3]="WARN",n[n.ERROR=4]="ERROR",n[n.SILENT=5]="SILENT"})(m||(m={}));var Li={debug:m.DEBUG,verbose:m.VERBOSE,info:m.INFO,warn:m.WARN,error:m.ERROR,silent:m.SILENT},Mi=m.INFO,xi={[m.DEBUG]:"log",[m.VERBOSE]:"log",[m.INFO]:"info",[m.WARN]:"warn",[m.ERROR]:"error"},Ui=(n,e,...t)=>{if(e<n.logLevel)return;let r=new Date().toISOString(),i=xi[e];if(i)console[i](`[${r}] ${n.name}:`,...t);else throw new Error(`Attempted to log a message with an invalid logType (value: ${e})`)},ue=class{constructor(e){this.name=e,this._logLevel=Mi,this._logHandler=Ui,this._userLogHandler=null,Di.push(this)}get logLevel(){return this._logLevel}set logLevel(e){if(!(e in m))throw new TypeError(`Invalid value "${e}" assigned to \`logLevel\``);this._logLevel=e}setLogLevel(e){this._logLevel=typeof e=="string"?Li[e]:e}get logHandler(){return this._logHandler}set logHandler(e){if(typeof e!="function")throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=e}get userLogHandler(){return this._userLogHandler}set userLogHandler(e){this._userLogHandler=e}debug(...e){this._userLogHandler&&this._userLogHandler(this,m.DEBUG,...e),this._logHandler(this,m.DEBUG,...e)}log(...e){this._userLogHandler&&this._userLogHandler(this,m.VERBOSE,...e),this._logHandler(this,m.VERBOSE,...e)}info(...e){this._userLogHandler&&this._userLogHandler(this,m.INFO,...e),this._logHandler(this,m.INFO,...e)}warn(...e){this._userLogHandler&&this._userLogHandler(this,m.WARN,...e),this._logHandler(this,m.WARN,...e)}error(...e){this._userLogHandler&&this._userLogHandler(this,m.ERROR,...e),this._logHandler(this,m.ERROR,...e)}};var Fi=(n,e)=>e.some(t=>n instanceof t),Bn,jn;function Vi(){return Bn||(Bn=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function Hi(){return jn||(jn=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}var $n=new WeakMap,Dt=new WeakMap,zn=new WeakMap,Nt=new WeakMap,Mt=new WeakMap;function Wi(n){let e=new Promise((t,r)=>{let i=()=>{n.removeEventListener("success",s),n.removeEventListener("error",o)},s=()=>{t(N(n.result)),i()},o=()=>{r(n.error),i()};n.addEventListener("success",s),n.addEventListener("error",o)});return e.then(t=>{t instanceof IDBCursor&&$n.set(t,n)}).catch(()=>{}),Mt.set(e,n),e}function Bi(n){if(Dt.has(n))return;let e=new Promise((t,r)=>{let i=()=>{n.removeEventListener("complete",s),n.removeEventListener("error",o),n.removeEventListener("abort",o)},s=()=>{t(),i()},o=()=>{r(n.error||new DOMException("AbortError","AbortError")),i()};n.addEventListener("complete",s),n.addEventListener("error",o),n.addEventListener("abort",o)});Dt.set(n,e)}var Lt={get(n,e,t){if(n instanceof IDBTransaction){if(e==="done")return Dt.get(n);if(e==="objectStoreNames")return n.objectStoreNames||zn.get(n);if(e==="store")return t.objectStoreNames[1]?void 0:t.objectStore(t.objectStoreNames[0])}return N(n[e])},set(n,e,t){return n[e]=t,!0},has(n,e){return n instanceof IDBTransaction&&(e==="done"||e==="store")?!0:e in n}};function qn(n){Lt=n(Lt)}function ji(n){return n===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(e,...t){let r=n.call(xe(this),e,...t);return zn.set(r,e.sort?e.sort():[e]),N(r)}:Hi().includes(n)?function(...e){return n.apply(xe(this),e),N($n.get(this))}:function(...e){return N(n.apply(xe(this),e))}}function $i(n){return typeof n=="function"?ji(n):(n instanceof IDBTransaction&&Bi(n),Fi(n,Vi())?new Proxy(n,Lt):n)}function N(n){if(n instanceof IDBRequest)return Wi(n);if(Nt.has(n))return Nt.get(n);let e=$i(n);return e!==n&&(Nt.set(n,e),Mt.set(e,n)),e}var xe=n=>Mt.get(n);function Kn(n,e,{blocked:t,upgrade:r,blocking:i,terminated:s}={}){let o=indexedDB.open(n,e),c=N(o);return r&&o.addEventListener("upgradeneeded",a=>{r(N(o.result),a.oldVersion,a.newVersion,N(o.transaction),a)}),t&&o.addEventListener("blocked",a=>t(a.oldVersion,a.newVersion,a)),c.then(a=>{s&&a.addEventListener("close",()=>s()),i&&a.addEventListener("versionchange",l=>i(l.oldVersion,l.newVersion,l))}).catch(()=>{}),c}var zi=["get","getKey","getAll","getAllKeys","count"],qi=["put","add","delete","clear"],xt=new Map;function Gn(n,e){if(!(n instanceof IDBDatabase&&!(e in n)&&typeof e=="string"))return;if(xt.get(e))return xt.get(e);let t=e.replace(/FromIndex$/,""),r=e!==t,i=qi.includes(t);if(!(t in(r?IDBIndex:IDBObjectStore).prototype)||!(i||zi.includes(t)))return;let s=async function(o,...c){let a=this.transaction(o,i?"readwrite":"readonly"),l=a.store;return r&&(l=l.index(c.shift())),(await Promise.all([l[t](...c),i&&a.done]))[0]};return xt.set(e,s),s}qn(n=>({...n,get:(e,t,r)=>Gn(e,t)||n.get(e,t,r),has:(e,t)=>!!Gn(e,t)||n.has(e,t)}));var Ft=class{constructor(e){this.container=e}getPlatformInfoString(){return this.container.getProviders().map(t=>{if(Gi(t)){let r=t.getImmediate();return`${r.library}/${r.version}`}else return null}).filter(t=>t).join(" ")}};function Gi(n){let e=n.getComponent();return e?.type==="VERSION"}var Vt="@firebase/app",Jn="0.9.22";var K=new ue("@firebase/app"),Ki="@firebase/app-compat",Ji="@firebase/analytics-compat",Yi="@firebase/analytics",Xi="@firebase/app-check-compat",Qi="@firebase/app-check",Zi="@firebase/auth",es="@firebase/auth-compat",ts="@firebase/database",ns="@firebase/database-compat",rs="@firebase/functions",is="@firebase/functions-compat",ss="@firebase/installations",os="@firebase/installations-compat",as="@firebase/messaging",cs="@firebase/messaging-compat",us="@firebase/performance",ls="@firebase/performance-compat",ds="@firebase/remote-config",hs="@firebase/remote-config-compat",fs="@firebase/storage",ps="@firebase/storage-compat",_s="@firebase/firestore",ms="@firebase/firestore-compat",gs="firebase",vs="10.5.2";var Ht="[DEFAULT]",Is={[Vt]:"fire-core",[Ki]:"fire-core-compat",[Yi]:"fire-analytics",[Ji]:"fire-analytics-compat",[Qi]:"fire-app-check",[Xi]:"fire-app-check-compat",[Zi]:"fire-auth",[es]:"fire-auth-compat",[ts]:"fire-rtdb",[ns]:"fire-rtdb-compat",[rs]:"fire-fn",[is]:"fire-fn-compat",[ss]:"fire-iid",[os]:"fire-iid-compat",[as]:"fire-fcm",[cs]:"fire-fcm-compat",[us]:"fire-perf",[ls]:"fire-perf-compat",[ds]:"fire-rc",[hs]:"fire-rc-compat",[fs]:"fire-gcs",[ps]:"fire-gcs-compat",[_s]:"fire-fst",[ms]:"fire-fst-compat","fire-js":"fire-js",[gs]:"fire-js-all"};var Ue=new Map,Wt=new Map;function ys(n,e){try{n.container.addComponent(e)}catch(t){K.debug(`Component ${e.name} failed to register with FirebaseApp ${n.name}`,t)}}function le(n){let e=n.name;if(Wt.has(e))return K.debug(`There were multiple attempts to register component ${e}.`),!1;Wt.set(e,n);for(let t of Ue.values())ys(t,n);return!0}function zt(n,e){let t=n.container.getProvider("heartbeat").getImmediate({optional:!0});return t&&t.triggerHeartbeat(),n.container.getProvider(e)}var Es={"no-app":"No Firebase App '{$appName}' has been created - call initializeApp() first","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.","invalid-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}."},W=new x("app","Firebase",Es);var Bt=class{constructor(e,t,r){this._isDeleted=!1,this._options=Object.assign({},e),this._config=Object.assign({},t),this._name=t.name,this._automaticDataCollectionEnabled=t.automaticDataCollectionEnabled,this._container=r,this.container.addComponent(new C("app",()=>this,"PUBLIC"))}get automaticDataCollectionEnabled(){return this.checkDestroyed(),this._automaticDataCollectionEnabled}set automaticDataCollectionEnabled(e){this.checkDestroyed(),this._automaticDataCollectionEnabled=e}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(e){this._isDeleted=e}checkDestroyed(){if(this.isDeleted)throw W.create("app-deleted",{appName:this._name})}};var de=vs;function qt(n,e={}){let t=n;typeof e!="object"&&(e={name:e});let r=Object.assign({name:Ht,automaticDataCollectionEnabled:!1},e),i=r.name;if(typeof i!="string"||!i)throw W.create("bad-app-name",{appName:String(i)});if(t||(t=Ot()),!t)throw W.create("no-options");let s=Ue.get(i);if(s){if(se(t,s.options)&&se(r,s.config))return s;throw W.create("duplicate-app",{appName:i})}let o=new Me(i);for(let a of Wt.values())o.addComponent(a);let c=new Bt(t,r,o);return Ue.set(i,c),c}function Zn(n=Ht){let e=Ue.get(n);if(!e&&n===Ht&&Ot())return qt();if(!e)throw W.create("no-app",{appName:n});return e}function B(n,e,t){var r;let i=(r=Is[n])!==null&&r!==void 0?r:n;t&&(i+=`-${t}`);let s=i.match(/\s|\//),o=e.match(/\s|\//);if(s||o){let c=[`Unable to register library "${i}" with version "${e}":`];s&&c.push(`library name "${i}" contains illegal characters (whitespace or "/")`),s&&o&&c.push("and"),o&&c.push(`version name "${e}" contains illegal characters (whitespace or "/")`),K.warn(c.join(" "));return}le(new C(`${i}-version`,()=>({library:i,version:e}),"VERSION"))}var ws="firebase-heartbeat-database",bs=1,ve="firebase-heartbeat-store",Ut=null;function er(){return Ut||(Ut=Kn(ws,bs,{upgrade:(n,e)=>{switch(e){case 0:n.createObjectStore(ve)}}}).catch(n=>{throw W.create("idb-open",{originalErrorMessage:n.message})})),Ut}async function Ts(n){try{return await(await er()).transaction(ve).objectStore(ve).get(tr(n))}catch(e){if(e instanceof P)K.warn(e.message);else{let t=W.create("idb-get",{originalErrorMessage:e?.message});K.warn(t.message)}}}async function Yn(n,e){try{let r=(await er()).transaction(ve,"readwrite");await r.objectStore(ve).put(e,tr(n)),await r.done}catch(t){if(t instanceof P)K.warn(t.message);else{let r=W.create("idb-set",{originalErrorMessage:t?.message});K.warn(r.message)}}}function tr(n){return`${n.name}!${n.options.appId}`}var As=1024,Ss=30*24*60*60*1e3,jt=class{constructor(e){this.container=e,this._heartbeatsCache=null;let t=this.container.getProvider("app").getImmediate();this._storage=new $t(t),this._heartbeatsCachePromise=this._storage.read().then(r=>(this._heartbeatsCache=r,r))}async triggerHeartbeat(){let t=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),r=Xn();if(this._heartbeatsCache===null&&(this._heartbeatsCache=await this._heartbeatsCachePromise),!(this._heartbeatsCache.lastSentHeartbeatDate===r||this._heartbeatsCache.heartbeats.some(i=>i.date===r)))return this._heartbeatsCache.heartbeats.push({date:r,agent:t}),this._heartbeatsCache.heartbeats=this._heartbeatsCache.heartbeats.filter(i=>{let s=new Date(i.date).valueOf();return Date.now()-s<=Ss}),this._storage.overwrite(this._heartbeatsCache)}async getHeartbeatsHeader(){if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,this._heartbeatsCache===null||this._heartbeatsCache.heartbeats.length===0)return"";let e=Xn(),{heartbeatsToSend:t,unsentEntries:r}=Rs(this._heartbeatsCache.heartbeats),i=St(JSON.stringify({version:2,heartbeats:t}));return this._heartbeatsCache.lastSentHeartbeatDate=e,r.length>0?(this._heartbeatsCache.heartbeats=r,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),i}};function Xn(){return new Date().toISOString().substring(0,10)}function Rs(n,e=As){let t=[],r=n.slice();for(let i of n){let s=t.find(o=>o.agent===i.agent);if(s){if(s.dates.push(i.date),Qn(t)>e){s.dates.pop();break}}else if(t.push({agent:i.agent,dates:[i.date]}),Qn(t)>e){t.pop();break}r=r.slice(1)}return{heartbeatsToSend:t,unsentEntries:r}}var $t=class{constructor(e){this.app=e,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return Fn()?Vn().then(()=>!0).catch(()=>!1):!1}async read(){return await this._canUseIndexedDBPromise?await Ts(this.app)||{heartbeats:[]}:{heartbeats:[]}}async overwrite(e){var t;if(await this._canUseIndexedDBPromise){let i=await this.read();return Yn(this.app,{lastSentHeartbeatDate:(t=e.lastSentHeartbeatDate)!==null&&t!==void 0?t:i.lastSentHeartbeatDate,heartbeats:e.heartbeats})}else return}async add(e){var t;if(await this._canUseIndexedDBPromise){let i=await this.read();return Yn(this.app,{lastSentHeartbeatDate:(t=e.lastSentHeartbeatDate)!==null&&t!==void 0?t:i.lastSentHeartbeatDate,heartbeats:[...i.heartbeats,...e.heartbeats]})}else return}};function Qn(n){return St(JSON.stringify({version:2,heartbeats:n})).length}function ks(n){le(new C("platform-logger",e=>new Ft(e),"PRIVATE")),le(new C("heartbeat",e=>new jt(e),"PRIVATE")),B(Vt,Jn,n),B(Vt,Jn,"esm2017"),B("fire-js","")}ks("");var Os="firebase",Ps="10.5.2";B(Os,Ps,"app");function Fe(n,e){var t={};for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&e.indexOf(r)<0&&(t[r]=n[r]);if(n!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(n);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(n,r[i])&&(t[r[i]]=n[r[i]]);return t}function gr(){return{"dependent-sdk-initialized-before-auth":"Another Firebase SDK was initialized and is trying to use Auth before Auth is initialized. Please be sure to call `initializeAuth` or `getAuth` before starting any other Firebase SDK."}}var vr=gr,Ir=new x("auth","Firebase",gr());var $e=new ue("@firebase/auth");function Cs(n,...e){$e.logLevel<=m.WARN&&$e.warn(`Auth (${de}): ${n}`,...e)}function He(n,...e){$e.logLevel<=m.ERROR&&$e.error(`Auth (${de}): ${n}`,...e)}function O(n,...e){throw fn(n,...e)}function L(n,...e){return fn(n,...e)}function yr(n,e,t){let r=Object.assign(Object.assign({},vr()),{[e]:t});return new x("auth","Firebase",r).create(e,{appName:n.name})}function Ns(n,e,t){let r=t;if(!(e instanceof r))throw r.name!==e.constructor.name&&O(n,"argument-error"),yr(n,"argument-error",`Type of ${e.constructor.name} does not match expected instance.Did you pass a reference from a different Auth SDK?`)}function fn(n,...e){if(typeof n!="string"){let t=e[0],r=[...e.slice(1)];return r[0]&&(r[0].appName=n.name),n._errorFactory.create(t,...r)}return Ir.create(n,...e)}function f(n,e,...t){if(!n)throw fn(e,...t)}function D(n){let e="INTERNAL ASSERTION FAILED: "+n;throw He(e),new Error(e)}function F(n,e){n||D(e)}function Jt(){var n;return typeof self<"u"&&((n=self.location)===null||n===void 0?void 0:n.href)||""}function Ds(){return nr()==="http:"||nr()==="https:"}function nr(){var n;return typeof self<"u"&&((n=self.location)===null||n===void 0?void 0:n.protocol)||null}function Ls(){return typeof navigator<"u"&&navigator&&"onLine"in navigator&&typeof navigator.onLine=="boolean"&&(Ds()||Mn()||"connection"in navigator)?navigator.onLine:!0}function Ms(){if(typeof navigator>"u")return null;let n=navigator;return n.languages&&n.languages[0]||n.language||null}var J=class{constructor(e,t){this.shortDelay=e,this.longDelay=t,F(t>e,"Short delay should be less than long delay!"),this.isMobile=Ln()||xn()}get(){return Ls()?this.isMobile?this.longDelay:this.shortDelay:Math.min(5e3,this.shortDelay)}};function pn(n,e){F(n.emulator,"Emulator should always be set here");let{url:t}=n.emulator;return e?`${t}${e.startsWith("/")?e.slice(1):e}`:t}var ze=class{static initialize(e,t,r){this.fetchImpl=e,t&&(this.headersImpl=t),r&&(this.responseImpl=r)}static fetch(){if(this.fetchImpl)return this.fetchImpl;if(typeof self<"u"&&"fetch"in self)return self.fetch;if(typeof globalThis<"u"&&globalThis.fetch)return globalThis.fetch;if(typeof fetch<"u")return fetch;D("Could not find fetch implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static headers(){if(this.headersImpl)return this.headersImpl;if(typeof self<"u"&&"Headers"in self)return self.Headers;if(typeof globalThis<"u"&&globalThis.Headers)return globalThis.Headers;if(typeof Headers<"u")return Headers;D("Could not find Headers implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static response(){if(this.responseImpl)return this.responseImpl;if(typeof self<"u"&&"Response"in self)return self.Response;if(typeof globalThis<"u"&&globalThis.Response)return globalThis.Response;if(typeof Response<"u")return Response;D("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}};var xs={CREDENTIAL_MISMATCH:"custom-token-mismatch",MISSING_CUSTOM_TOKEN:"internal-error",INVALID_IDENTIFIER:"invalid-email",MISSING_CONTINUE_URI:"internal-error",INVALID_PASSWORD:"wrong-password",MISSING_PASSWORD:"missing-password",EMAIL_EXISTS:"email-already-in-use",PASSWORD_LOGIN_DISABLED:"operation-not-allowed",INVALID_IDP_RESPONSE:"invalid-credential",INVALID_PENDING_TOKEN:"invalid-credential",FEDERATED_USER_ID_ALREADY_LINKED:"credential-already-in-use",MISSING_REQ_TYPE:"internal-error",EMAIL_NOT_FOUND:"user-not-found",RESET_PASSWORD_EXCEED_LIMIT:"too-many-requests",EXPIRED_OOB_CODE:"expired-action-code",INVALID_OOB_CODE:"invalid-action-code",MISSING_OOB_CODE:"internal-error",CREDENTIAL_TOO_OLD_LOGIN_AGAIN:"requires-recent-login",INVALID_ID_TOKEN:"invalid-user-token",TOKEN_EXPIRED:"user-token-expired",USER_NOT_FOUND:"user-token-expired",TOO_MANY_ATTEMPTS_TRY_LATER:"too-many-requests",PASSWORD_DOES_NOT_MEET_REQUIREMENTS:"password-does-not-meet-requirements",INVALID_CODE:"invalid-verification-code",INVALID_SESSION_INFO:"invalid-verification-id",INVALID_TEMPORARY_PROOF:"invalid-credential",MISSING_SESSION_INFO:"missing-verification-id",SESSION_EXPIRED:"code-expired",MISSING_ANDROID_PACKAGE_NAME:"missing-android-pkg-name",UNAUTHORIZED_DOMAIN:"unauthorized-continue-uri",INVALID_OAUTH_CLIENT_ID:"invalid-oauth-client-id",ADMIN_ONLY_OPERATION:"admin-restricted-operation",INVALID_MFA_PENDING_CREDENTIAL:"invalid-multi-factor-session",MFA_ENROLLMENT_NOT_FOUND:"multi-factor-info-not-found",MISSING_MFA_ENROLLMENT_ID:"missing-multi-factor-info",MISSING_MFA_PENDING_CREDENTIAL:"missing-multi-factor-session",SECOND_FACTOR_EXISTS:"second-factor-already-in-use",SECOND_FACTOR_LIMIT_EXCEEDED:"maximum-second-factor-count-exceeded",BLOCKING_FUNCTION_ERROR_RESPONSE:"internal-error",RECAPTCHA_NOT_ENABLED:"recaptcha-not-enabled",MISSING_RECAPTCHA_TOKEN:"missing-recaptcha-token",INVALID_RECAPTCHA_TOKEN:"invalid-recaptcha-token",INVALID_RECAPTCHA_ACTION:"invalid-recaptcha-action",MISSING_CLIENT_TYPE:"missing-client-type",MISSING_RECAPTCHA_VERSION:"missing-recaptcha-version",INVALID_RECAPTCHA_VERSION:"invalid-recaptcha-version",INVALID_REQ_TYPE:"invalid-req-type"};var Us=new J(3e4,6e4);function T(n,e){return n.tenantId&&!e.tenantId?Object.assign(Object.assign({},e),{tenantId:n.tenantId}):e}async function S(n,e,t,r,i={}){return Er(n,i,async()=>{let s={},o={};r&&(e==="GET"?o=r:s={body:JSON.stringify(r)});let c=oe(Object.assign({key:n.config.apiKey},o)).slice(1),a=await n._getAdditionalHeaders();return a["Content-Type"]="application/json",n.languageCode&&(a["X-Firebase-Locale"]=n.languageCode),ze.fetch()(wr(n,n.config.apiHost,t,c),Object.assign({method:e,headers:a,referrerPolicy:"no-referrer"},s))})}async function Er(n,e,t){n._canInitEmulator=!1;let r=Object.assign(Object.assign({},xs),e);try{let i=new Yt(n),s=await Promise.race([t(),i.promise]);i.clearNetworkTimeout();let o=await s.json();if("needConfirmation"in o)throw Ie(n,"account-exists-with-different-credential",o);if(s.ok&&!("errorMessage"in o))return o;{let c=s.ok?o.errorMessage:o.error.message,[a,l]=c.split(" : ");if(a==="FEDERATED_USER_ID_ALREADY_LINKED")throw Ie(n,"credential-already-in-use",o);if(a==="EMAIL_EXISTS")throw Ie(n,"email-already-in-use",o);if(a==="USER_DISABLED")throw Ie(n,"user-disabled",o);let d=r[a]||a.toLowerCase().replace(/[_\s]+/g,"-");if(l)throw yr(n,d,l);O(n,d)}}catch(i){if(i instanceof P)throw i;O(n,"network-request-failed",{message:String(i)})}}async function te(n,e,t,r,i={}){let s=await S(n,e,t,r,i);return"mfaPendingCredential"in s&&O(n,"multi-factor-auth-required",{_serverResponse:s}),s}function wr(n,e,t,r){let i=`${e}${t}?${r}`;return n.config.emulator?pn(n.config,i):`${n.config.apiScheme}://${i}`}function Fs(n){switch(n){case"ENFORCE":return"ENFORCE";case"AUDIT":return"AUDIT";case"OFF":return"OFF";default:return"ENFORCEMENT_STATE_UNSPECIFIED"}}var Yt=class{constructor(e){this.auth=e,this.timer=null,this.promise=new Promise((t,r)=>{this.timer=setTimeout(()=>r(L(this.auth,"network-request-failed")),Us.get())})}clearNetworkTimeout(){clearTimeout(this.timer)}};function Ie(n,e,t){let r={appName:n.name};t.email&&(r.email=t.email),t.phoneNumber&&(r.phoneNumber=t.phoneNumber);let i=L(n,e,r);return i.customData._tokenResponse=t,i}function rr(n){return n!==void 0&&n.enterprise!==void 0}var Xt=class{constructor(e){if(this.siteKey="",this.recaptchaEnforcementState=[],e.recaptchaKey===void 0)throw new Error("recaptchaKey undefined");this.siteKey=e.recaptchaKey.split("/")[3],this.recaptchaEnforcementState=e.recaptchaEnforcementState}getProviderEnforcementState(e){if(!this.recaptchaEnforcementState||this.recaptchaEnforcementState.length===0)return null;for(let t of this.recaptchaEnforcementState)if(t.provider&&t.provider===e)return Fs(t.enforcementState);return null}isProviderEnabled(e){return this.getProviderEnforcementState(e)==="ENFORCE"||this.getProviderEnforcementState(e)==="AUDIT"}};async function Vs(n,e){return S(n,"GET","/v2/recaptchaConfig",T(n,e))}async function Hs(n,e){return S(n,"POST","/v1/accounts:delete",e)}async function Ws(n,e){return S(n,"POST","/v1/accounts:lookup",e)}function ye(n){if(n)try{let e=new Date(Number(n));if(!isNaN(e.getTime()))return e.toUTCString()}catch{}}async function br(n,e=!1){let t=H(n),r=await t.getIdToken(e),i=_n(r);f(i&&i.exp&&i.auth_time&&i.iat,t.auth,"internal-error");let s=typeof i.firebase=="object"?i.firebase:void 0,o=s?.sign_in_provider;return{claims:i,token:r,authTime:ye(Gt(i.auth_time)),issuedAtTime:ye(Gt(i.iat)),expirationTime:ye(Gt(i.exp)),signInProvider:o||null,signInSecondFactor:s?.sign_in_second_factor||null}}function Gt(n){return Number(n)*1e3}function _n(n){let[e,t,r]=n.split(".");if(e===void 0||t===void 0||r===void 0)return He("JWT malformed, contained fewer than 3 sections"),null;try{let i=Rt(t);return i?JSON.parse(i):(He("Failed to decode base64 JWT payload"),null)}catch(i){return He("Caught error parsing JWT payload as JSON",i?.toString()),null}}function Bs(n){let e=_n(n);return f(e,"internal-error"),f(typeof e.exp<"u","internal-error"),f(typeof e.iat<"u","internal-error"),Number(e.exp)-Number(e.iat)}async function Ee(n,e,t=!1){if(t)return e;try{return await e}catch(r){throw r instanceof P&&js(r)&&n.auth.currentUser===n&&await n.auth.signOut(),r}}function js({code:n}){return n==="auth/user-disabled"||n==="auth/user-token-expired"}var Qt=class{constructor(e){this.user=e,this.isRunning=!1,this.timerId=null,this.errorBackoff=3e4}_start(){this.isRunning||(this.isRunning=!0,this.schedule())}_stop(){this.isRunning&&(this.isRunning=!1,this.timerId!==null&&clearTimeout(this.timerId))}getInterval(e){var t;if(e){let r=this.errorBackoff;return this.errorBackoff=Math.min(this.errorBackoff*2,96e4),r}else{this.errorBackoff=3e4;let i=((t=this.user.stsTokenManager.expirationTime)!==null&&t!==void 0?t:0)-Date.now()-3e5;return Math.max(0,i)}}schedule(e=!1){if(!this.isRunning)return;let t=this.getInterval(e);this.timerId=setTimeout(async()=>{await this.iteration()},t)}async iteration(){try{await this.user.getIdToken(!0)}catch(e){e?.code==="auth/network-request-failed"&&this.schedule(!0);return}this.schedule()}};var qe=class{constructor(e,t){this.createdAt=e,this.lastLoginAt=t,this._initializeTime()}_initializeTime(){this.lastSignInTime=ye(this.lastLoginAt),this.creationTime=ye(this.createdAt)}_copy(e){this.createdAt=e.createdAt,this.lastLoginAt=e.lastLoginAt,this._initializeTime()}toJSON(){return{createdAt:this.createdAt,lastLoginAt:this.lastLoginAt}}};async function Ge(n){var e;let t=n.auth,r=await n.getIdToken(),i=await Ee(n,Ws(t,{idToken:r}));f(i?.users.length,t,"internal-error");let s=i.users[0];n._notifyReloadListener(s);let o=!((e=s.providerUserInfo)===null||e===void 0)&&e.length?zs(s.providerUserInfo):[],c=$s(n.providerData,o),a=n.isAnonymous,l=!(n.email&&s.passwordHash)&&!c?.length,d=a?l:!1,u={uid:s.localId,displayName:s.displayName||null,photoURL:s.photoUrl||null,email:s.email||null,emailVerified:s.emailVerified||!1,phoneNumber:s.phoneNumber||null,tenantId:s.tenantId||null,providerData:c,metadata:new qe(s.createdAt,s.lastLoginAt),isAnonymous:d};Object.assign(n,u)}async function Tr(n){let e=H(n);await Ge(e),await e.auth._persistUserIfCurrent(e),e.auth._notifyListenersIfCurrent(e)}function $s(n,e){return[...n.filter(r=>!e.some(i=>i.providerId===r.providerId)),...e]}function zs(n){return n.map(e=>{var{providerId:t}=e,r=Fe(e,["providerId"]);return{providerId:t,uid:r.rawId||"",displayName:r.displayName||null,email:r.email||null,phoneNumber:r.phoneNumber||null,photoURL:r.photoUrl||null}})}async function qs(n,e){let t=await Er(n,{},async()=>{let r=oe({grant_type:"refresh_token",refresh_token:e}).slice(1),{tokenApiHost:i,apiKey:s}=n.config,o=wr(n,i,"/v1/token",`key=${s}`),c=await n._getAdditionalHeaders();return c["Content-Type"]="application/x-www-form-urlencoded",ze.fetch()(o,{method:"POST",headers:c,body:r})});return{accessToken:t.access_token,expiresIn:t.expires_in,refreshToken:t.refresh_token}}var Ke=class n{constructor(){this.refreshToken=null,this.accessToken=null,this.expirationTime=null}get isExpired(){return!this.expirationTime||Date.now()>this.expirationTime-3e4}updateFromServerResponse(e){f(e.idToken,"internal-error"),f(typeof e.idToken<"u","internal-error"),f(typeof e.refreshToken<"u","internal-error");let t="expiresIn"in e&&typeof e.expiresIn<"u"?Number(e.expiresIn):Bs(e.idToken);this.updateTokensAndExpiration(e.idToken,e.refreshToken,t)}async getToken(e,t=!1){return f(!this.accessToken||this.refreshToken,e,"user-token-expired"),!t&&this.accessToken&&!this.isExpired?this.accessToken:this.refreshToken?(await this.refresh(e,this.refreshToken),this.accessToken):null}clearRefreshToken(){this.refreshToken=null}async refresh(e,t){let{accessToken:r,refreshToken:i,expiresIn:s}=await qs(e,t);this.updateTokensAndExpiration(r,i,Number(s))}updateTokensAndExpiration(e,t,r){this.refreshToken=t||null,this.accessToken=e||null,this.expirationTime=Date.now()+r*1e3}static fromJSON(e,t){let{refreshToken:r,accessToken:i,expirationTime:s}=t,o=new n;return r&&(f(typeof r=="string","internal-error",{appName:e}),o.refreshToken=r),i&&(f(typeof i=="string","internal-error",{appName:e}),o.accessToken=i),s&&(f(typeof s=="number","internal-error",{appName:e}),o.expirationTime=s),o}toJSON(){return{refreshToken:this.refreshToken,accessToken:this.accessToken,expirationTime:this.expirationTime}}_assign(e){this.accessToken=e.accessToken,this.refreshToken=e.refreshToken,this.expirationTime=e.expirationTime}_clone(){return Object.assign(new n,this.toJSON())}_performRefresh(){return D("not implemented")}};function j(n,e){f(typeof n=="string"||typeof n>"u","internal-error",{appName:e})}var we=class n{constructor(e){var{uid:t,auth:r,stsTokenManager:i}=e,s=Fe(e,["uid","auth","stsTokenManager"]);this.providerId="firebase",this.proactiveRefresh=new Qt(this),this.reloadUserInfo=null,this.reloadListener=null,this.uid=t,this.auth=r,this.stsTokenManager=i,this.accessToken=i.accessToken,this.displayName=s.displayName||null,this.email=s.email||null,this.emailVerified=s.emailVerified||!1,this.phoneNumber=s.phoneNumber||null,this.photoURL=s.photoURL||null,this.isAnonymous=s.isAnonymous||!1,this.tenantId=s.tenantId||null,this.providerData=s.providerData?[...s.providerData]:[],this.metadata=new qe(s.createdAt||void 0,s.lastLoginAt||void 0)}async getIdToken(e){let t=await Ee(this,this.stsTokenManager.getToken(this.auth,e));return f(t,this.auth,"internal-error"),this.accessToken!==t&&(this.accessToken=t,await this.auth._persistUserIfCurrent(this),this.auth._notifyListenersIfCurrent(this)),t}getIdTokenResult(e){return br(this,e)}reload(){return Tr(this)}_assign(e){this!==e&&(f(this.uid===e.uid,this.auth,"internal-error"),this.displayName=e.displayName,this.photoURL=e.photoURL,this.email=e.email,this.emailVerified=e.emailVerified,this.phoneNumber=e.phoneNumber,this.isAnonymous=e.isAnonymous,this.tenantId=e.tenantId,this.providerData=e.providerData.map(t=>Object.assign({},t)),this.metadata._copy(e.metadata),this.stsTokenManager._assign(e.stsTokenManager))}_clone(e){let t=new n(Object.assign(Object.assign({},this),{auth:e,stsTokenManager:this.stsTokenManager._clone()}));return t.metadata._copy(this.metadata),t}_onReload(e){f(!this.reloadListener,this.auth,"internal-error"),this.reloadListener=e,this.reloadUserInfo&&(this._notifyReloadListener(this.reloadUserInfo),this.reloadUserInfo=null)}_notifyReloadListener(e){this.reloadListener?this.reloadListener(e):this.reloadUserInfo=e}_startProactiveRefresh(){this.proactiveRefresh._start()}_stopProactiveRefresh(){this.proactiveRefresh._stop()}async _updateTokensIfNecessary(e,t=!1){let r=!1;e.idToken&&e.idToken!==this.stsTokenManager.accessToken&&(this.stsTokenManager.updateFromServerResponse(e),r=!0),t&&await Ge(this),await this.auth._persistUserIfCurrent(this),r&&this.auth._notifyListenersIfCurrent(this)}async delete(){let e=await this.getIdToken();return await Ee(this,Hs(this.auth,{idToken:e})),this.stsTokenManager.clearRefreshToken(),this.auth.signOut()}toJSON(){return Object.assign(Object.assign({uid:this.uid,email:this.email||void 0,emailVerified:this.emailVerified,displayName:this.displayName||void 0,isAnonymous:this.isAnonymous,photoURL:this.photoURL||void 0,phoneNumber:this.phoneNumber||void 0,tenantId:this.tenantId||void 0,providerData:this.providerData.map(e=>Object.assign({},e)),stsTokenManager:this.stsTokenManager.toJSON(),_redirectEventId:this._redirectEventId},this.metadata.toJSON()),{apiKey:this.auth.config.apiKey,appName:this.auth.name})}get refreshToken(){return this.stsTokenManager.refreshToken||""}static _fromJSON(e,t){var r,i,s,o,c,a,l,d;let u=(r=t.displayName)!==null&&r!==void 0?r:void 0,_=(i=t.email)!==null&&i!==void 0?i:void 0,h=(s=t.phoneNumber)!==null&&s!==void 0?s:void 0,v=(o=t.photoURL)!==null&&o!==void 0?o:void 0,R=(c=t.tenantId)!==null&&c!==void 0?c:void 0,I=(a=t._redirectEventId)!==null&&a!==void 0?a:void 0,g=(l=t.createdAt)!==null&&l!==void 0?l:void 0,y=(d=t.lastLoginAt)!==null&&d!==void 0?d:void 0,{uid:k,emailVerified:z,isAnonymous:V,providerData:re,stsTokenManager:q}=t;f(k&&q,e,"internal-error");let ge=Ke.fromJSON(this.name,q);f(typeof k=="string",e,"internal-error"),j(u,e.name),j(_,e.name),f(typeof z=="boolean",e,"internal-error"),f(typeof V=="boolean",e,"internal-error"),j(h,e.name),j(v,e.name),j(R,e.name),j(I,e.name),j(g,e.name),j(y,e.name);let A=new n({uid:k,auth:e,email:_,emailVerified:z,displayName:u,isAnonymous:V,photoURL:v,phoneNumber:h,tenantId:R,stsTokenManager:ge,createdAt:g,lastLoginAt:y});return re&&Array.isArray(re)&&(A.providerData=re.map(ie=>Object.assign({},ie))),I&&(A._redirectEventId=I),A}static async _fromIdTokenResponse(e,t,r=!1){let i=new Ke;i.updateFromServerResponse(t);let s=new n({uid:t.localId,auth:e,stsTokenManager:i,isAnonymous:r});return await Ge(s),s}};var ir=new Map;function U(n){F(n instanceof Function,"Expected a class definition");let e=ir.get(n);return e?(F(e instanceof n,"Instance stored in cache mismatched with class"),e):(e=new n,ir.set(n,e),e)}var Je=class{constructor(){this.type="NONE",this.storage={}}async _isAvailable(){return!0}async _set(e,t){this.storage[e]=t}async _get(e){let t=this.storage[e];return t===void 0?null:t}async _remove(e){delete this.storage[e]}_addListener(e,t){}_removeListener(e,t){}};Je.type="NONE";var Zt=Je;function We(n,e,t){return`firebase:${n}:${e}:${t}`}var Ye=class n{constructor(e,t,r){this.persistence=e,this.auth=t,this.userKey=r;let{config:i,name:s}=this.auth;this.fullUserKey=We(this.userKey,i.apiKey,s),this.fullPersistenceKey=We("persistence",i.apiKey,s),this.boundEventHandler=t._onStorageEvent.bind(t),this.persistence._addListener(this.fullUserKey,this.boundEventHandler)}setCurrentUser(e){return this.persistence._set(this.fullUserKey,e.toJSON())}async getCurrentUser(){let e=await this.persistence._get(this.fullUserKey);return e?we._fromJSON(this.auth,e):null}removeCurrentUser(){return this.persistence._remove(this.fullUserKey)}savePersistenceForRedirect(){return this.persistence._set(this.fullPersistenceKey,this.persistence.type)}async setPersistence(e){if(this.persistence===e)return;let t=await this.getCurrentUser();if(await this.removeCurrentUser(),this.persistence=e,t)return this.setCurrentUser(t)}delete(){this.persistence._removeListener(this.fullUserKey,this.boundEventHandler)}static async create(e,t,r="authUser"){if(!t.length)return new n(U(Zt),e,r);let i=(await Promise.all(t.map(async l=>{if(await l._isAvailable())return l}))).filter(l=>l),s=i[0]||U(Zt),o=We(r,e.config.apiKey,e.name),c=null;for(let l of t)try{let d=await l._get(o);if(d){let u=we._fromJSON(e,d);l!==s&&(c=u),s=l;break}}catch{}let a=i.filter(l=>l._shouldAllowMigration);return!s._shouldAllowMigration||!a.length?new n(s,e,r):(s=a[0],c&&await s._set(o,c.toJSON()),await Promise.all(t.map(async l=>{if(l!==s)try{await l._remove(o)}catch{}})),new n(s,e,r))}};function sr(n){let e=n.toLowerCase();if(e.includes("opera/")||e.includes("opr/")||e.includes("opios/"))return"Opera";if(Rr(e))return"IEMobile";if(e.includes("msie")||e.includes("trident/"))return"IE";if(e.includes("edge/"))return"Edge";if(Ar(e))return"Firefox";if(e.includes("silk/"))return"Silk";if(Or(e))return"Blackberry";if(Pr(e))return"Webos";if(mn(e))return"Safari";if((e.includes("chrome/")||Sr(e))&&!e.includes("edge/"))return"Chrome";if(kr(e))return"Android";{let t=/([a-zA-Z\d\.]+)\/[a-zA-Z\d\.]*$/,r=n.match(t);if(r?.length===2)return r[1]}return"Other"}function Ar(n=b()){return/firefox\//i.test(n)}function mn(n=b()){let e=n.toLowerCase();return e.includes("safari/")&&!e.includes("chrome/")&&!e.includes("crios/")&&!e.includes("android")}function Sr(n=b()){return/crios\//i.test(n)}function Rr(n=b()){return/iemobile/i.test(n)}function kr(n=b()){return/android/i.test(n)}function Or(n=b()){return/blackberry/i.test(n)}function Pr(n=b()){return/webos/i.test(n)}function pt(n=b()){return/iphone|ipad|ipod/i.test(n)||/macintosh/i.test(n)&&/mobile/i.test(n)}function Gs(n=b()){var e;return pt(n)&&!!(!((e=window.navigator)===null||e===void 0)&&e.standalone)}function Ks(){return Un()&&document.documentMode===10}function Cr(n=b()){return pt(n)||kr(n)||Pr(n)||Or(n)||/windows phone/i.test(n)||Rr(n)}function Js(){try{return!!(window&&window!==window.top)}catch{return!1}}function Nr(n,e=[]){let t;switch(n){case"Browser":t=sr(b());break;case"Worker":t=`${sr(b())}-${n}`;break;default:t=n}let r=e.length?e.join(","):"FirebaseCore-web";return`${t}/JsCore/${de}/${r}`}var en=class{constructor(e){this.auth=e,this.queue=[]}pushCallback(e,t){let r=s=>new Promise((o,c)=>{try{let a=e(s);o(a)}catch(a){c(a)}});r.onAbort=t,this.queue.push(r);let i=this.queue.length-1;return()=>{this.queue[i]=()=>Promise.resolve()}}async runMiddleware(e){if(this.auth.currentUser===e)return;let t=[];try{for(let r of this.queue)await r(e),r.onAbort&&t.push(r.onAbort)}catch(r){t.reverse();for(let i of t)try{i()}catch{}throw this.auth._errorFactory.create("login-blocked",{originalMessage:r?.message})}}};async function Ys(n,e={}){return S(n,"GET","/v2/passwordPolicy",T(n,e))}var Xs=6,tn=class{constructor(e){var t,r,i,s;let o=e.customStrengthOptions;this.customStrengthOptions={},this.customStrengthOptions.minPasswordLength=(t=o.minPasswordLength)!==null&&t!==void 0?t:Xs,o.maxPasswordLength&&(this.customStrengthOptions.maxPasswordLength=o.maxPasswordLength),o.containsLowercaseCharacter!==void 0&&(this.customStrengthOptions.containsLowercaseLetter=o.containsLowercaseCharacter),o.containsUppercaseCharacter!==void 0&&(this.customStrengthOptions.containsUppercaseLetter=o.containsUppercaseCharacter),o.containsNumericCharacter!==void 0&&(this.customStrengthOptions.containsNumericCharacter=o.containsNumericCharacter),o.containsNonAlphanumericCharacter!==void 0&&(this.customStrengthOptions.containsNonAlphanumericCharacter=o.containsNonAlphanumericCharacter),this.enforcementState=e.enforcementState,this.enforcementState==="ENFORCEMENT_STATE_UNSPECIFIED"&&(this.enforcementState="OFF"),this.allowedNonAlphanumericCharacters=(i=(r=e.allowedNonAlphanumericCharacters)===null||r===void 0?void 0:r.join(""))!==null&&i!==void 0?i:"",this.forceUpgradeOnSignin=(s=e.forceUpgradeOnSignin)!==null&&s!==void 0?s:!1,this.schemaVersion=e.schemaVersion}validatePassword(e){var t,r,i,s,o,c;let a={isValid:!0,passwordPolicy:this};return this.validatePasswordLengthOptions(e,a),this.validatePasswordCharacterOptions(e,a),a.isValid&&(a.isValid=(t=a.meetsMinPasswordLength)!==null&&t!==void 0?t:!0),a.isValid&&(a.isValid=(r=a.meetsMaxPasswordLength)!==null&&r!==void 0?r:!0),a.isValid&&(a.isValid=(i=a.containsLowercaseLetter)!==null&&i!==void 0?i:!0),a.isValid&&(a.isValid=(s=a.containsUppercaseLetter)!==null&&s!==void 0?s:!0),a.isValid&&(a.isValid=(o=a.containsNumericCharacter)!==null&&o!==void 0?o:!0),a.isValid&&(a.isValid=(c=a.containsNonAlphanumericCharacter)!==null&&c!==void 0?c:!0),a}validatePasswordLengthOptions(e,t){let r=this.customStrengthOptions.minPasswordLength,i=this.customStrengthOptions.maxPasswordLength;r&&(t.meetsMinPasswordLength=e.length>=r),i&&(t.meetsMaxPasswordLength=e.length<=i)}validatePasswordCharacterOptions(e,t){this.updatePasswordCharacterOptionsStatuses(t,!1,!1,!1,!1);let r;for(let i=0;i<e.length;i++)r=e.charAt(i),this.updatePasswordCharacterOptionsStatuses(t,r>="a"&&r<="z",r>="A"&&r<="Z",r>="0"&&r<="9",this.allowedNonAlphanumericCharacters.includes(r))}updatePasswordCharacterOptionsStatuses(e,t,r,i,s){this.customStrengthOptions.containsLowercaseLetter&&(e.containsLowercaseLetter||(e.containsLowercaseLetter=t)),this.customStrengthOptions.containsUppercaseLetter&&(e.containsUppercaseLetter||(e.containsUppercaseLetter=r)),this.customStrengthOptions.containsNumericCharacter&&(e.containsNumericCharacter||(e.containsNumericCharacter=i)),this.customStrengthOptions.containsNonAlphanumericCharacter&&(e.containsNonAlphanumericCharacter||(e.containsNonAlphanumericCharacter=s))}};var nn=class{constructor(e,t,r,i){this.app=e,this.heartbeatServiceProvider=t,this.appCheckServiceProvider=r,this.config=i,this.currentUser=null,this.emulatorConfig=null,this.operations=Promise.resolve(),this.authStateSubscription=new Xe(this),this.idTokenSubscription=new Xe(this),this.beforeStateQueue=new en(this),this.redirectUser=null,this.isProactiveRefreshEnabled=!1,this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION=1,this._canInitEmulator=!0,this._isInitialized=!1,this._deleted=!1,this._initializationPromise=null,this._popupRedirectResolver=null,this._errorFactory=Ir,this._agentRecaptchaConfig=null,this._tenantRecaptchaConfigs={},this._projectPasswordPolicy=null,this._tenantPasswordPolicies={},this.lastNotifiedUid=void 0,this.languageCode=null,this.tenantId=null,this.settings={appVerificationDisabledForTesting:!1},this.frameworks=[],this.name=e.name,this.clientVersion=i.sdkClientVersion}_initializeWithPersistence(e,t){return t&&(this._popupRedirectResolver=U(t)),this._initializationPromise=this.queue(async()=>{var r,i;if(!this._deleted&&(this.persistenceManager=await Ye.create(this,e),!this._deleted)){if(!((r=this._popupRedirectResolver)===null||r===void 0)&&r._shouldInitProactively)try{await this._popupRedirectResolver._initialize(this)}catch{}await this.initializeCurrentUser(t),this.lastNotifiedUid=((i=this.currentUser)===null||i===void 0?void 0:i.uid)||null,!this._deleted&&(this._isInitialized=!0)}}),this._initializationPromise}async _onStorageEvent(){if(this._deleted)return;let e=await this.assertedPersistence.getCurrentUser();if(!(!this.currentUser&&!e)){if(this.currentUser&&e&&this.currentUser.uid===e.uid){this._currentUser._assign(e),await this.currentUser.getIdToken();return}await this._updateCurrentUser(e,!0)}}async initializeCurrentUser(e){var t;let r=await this.assertedPersistence.getCurrentUser(),i=r,s=!1;if(e&&this.config.authDomain){await this.getOrInitRedirectPersistenceManager();let o=(t=this.redirectUser)===null||t===void 0?void 0:t._redirectEventId,c=i?._redirectEventId,a=await this.tryRedirectSignIn(e);(!o||o===c)&&a?.user&&(i=a.user,s=!0)}if(!i)return this.directlySetCurrentUser(null);if(!i._redirectEventId){if(s)try{await this.beforeStateQueue.runMiddleware(i)}catch(o){i=r,this._popupRedirectResolver._overrideRedirectResult(this,()=>Promise.reject(o))}return i?this.reloadAndSetCurrentUserOrClear(i):this.directlySetCurrentUser(null)}return f(this._popupRedirectResolver,this,"argument-error"),await this.getOrInitRedirectPersistenceManager(),this.redirectUser&&this.redirectUser._redirectEventId===i._redirectEventId?this.directlySetCurrentUser(i):this.reloadAndSetCurrentUserOrClear(i)}async tryRedirectSignIn(e){let t=null;try{t=await this._popupRedirectResolver._completeRedirectFn(this,e,!0)}catch{await this._setRedirectUser(null)}return t}async reloadAndSetCurrentUserOrClear(e){try{await Ge(e)}catch(t){if(t?.code!=="auth/network-request-failed")return this.directlySetCurrentUser(null)}return this.directlySetCurrentUser(e)}useDeviceLanguage(){this.languageCode=Ms()}async _delete(){this._deleted=!0}async updateCurrentUser(e){let t=e?H(e):null;return t&&f(t.auth.config.apiKey===this.config.apiKey,this,"invalid-user-token"),this._updateCurrentUser(t&&t._clone(this))}async _updateCurrentUser(e,t=!1){if(!this._deleted)return e&&f(this.tenantId===e.tenantId,this,"tenant-id-mismatch"),t||await this.beforeStateQueue.runMiddleware(e),this.queue(async()=>{await this.directlySetCurrentUser(e),this.notifyAuthListeners()})}async signOut(){return await this.beforeStateQueue.runMiddleware(null),(this.redirectPersistenceManager||this._popupRedirectResolver)&&await this._setRedirectUser(null),this._updateCurrentUser(null,!0)}setPersistence(e){return this.queue(async()=>{await this.assertedPersistence.setPersistence(U(e))})}_getRecaptchaConfig(){return this.tenantId==null?this._agentRecaptchaConfig:this._tenantRecaptchaConfigs[this.tenantId]}async validatePassword(e){this._getPasswordPolicyInternal()||await this._updatePasswordPolicy();let t=this._getPasswordPolicyInternal();return t.schemaVersion!==this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION?Promise.reject(this._errorFactory.create("unsupported-password-policy-schema-version",{})):t.validatePassword(e)}_getPasswordPolicyInternal(){return this.tenantId===null?this._projectPasswordPolicy:this._tenantPasswordPolicies[this.tenantId]}async _updatePasswordPolicy(){let e=await Ys(this),t=new tn(e);this.tenantId===null?this._projectPasswordPolicy=t:this._tenantPasswordPolicies[this.tenantId]=t}_getPersistence(){return this.assertedPersistence.persistence.type}_updateErrorMap(e){this._errorFactory=new x("auth","Firebase",e())}onAuthStateChanged(e,t,r){return this.registerStateListener(this.authStateSubscription,e,t,r)}beforeAuthStateChanged(e,t){return this.beforeStateQueue.pushCallback(e,t)}onIdTokenChanged(e,t,r){return this.registerStateListener(this.idTokenSubscription,e,t,r)}authStateReady(){return new Promise((e,t)=>{if(this.currentUser)e();else{let r=this.onAuthStateChanged(()=>{r(),e()},t)}})}toJSON(){var e;return{apiKey:this.config.apiKey,authDomain:this.config.authDomain,appName:this.name,currentUser:(e=this._currentUser)===null||e===void 0?void 0:e.toJSON()}}async _setRedirectUser(e,t){let r=await this.getOrInitRedirectPersistenceManager(t);return e===null?r.removeCurrentUser():r.setCurrentUser(e)}async getOrInitRedirectPersistenceManager(e){if(!this.redirectPersistenceManager){let t=e&&U(e)||this._popupRedirectResolver;f(t,this,"argument-error"),this.redirectPersistenceManager=await Ye.create(this,[U(t._redirectPersistence)],"redirectUser"),this.redirectUser=await this.redirectPersistenceManager.getCurrentUser()}return this.redirectPersistenceManager}async _redirectUserForId(e){var t,r;return this._isInitialized&&await this.queue(async()=>{}),((t=this._currentUser)===null||t===void 0?void 0:t._redirectEventId)===e?this._currentUser:((r=this.redirectUser)===null||r===void 0?void 0:r._redirectEventId)===e?this.redirectUser:null}async _persistUserIfCurrent(e){if(e===this.currentUser)return this.queue(async()=>this.directlySetCurrentUser(e))}_notifyListenersIfCurrent(e){e===this.currentUser&&this.notifyAuthListeners()}_key(){return`${this.config.authDomain}:${this.config.apiKey}:${this.name}`}_startProactiveRefresh(){this.isProactiveRefreshEnabled=!0,this.currentUser&&this._currentUser._startProactiveRefresh()}_stopProactiveRefresh(){this.isProactiveRefreshEnabled=!1,this.currentUser&&this._currentUser._stopProactiveRefresh()}get _currentUser(){return this.currentUser}notifyAuthListeners(){var e,t;if(!this._isInitialized)return;this.idTokenSubscription.next(this.currentUser);let r=(t=(e=this.currentUser)===null||e===void 0?void 0:e.uid)!==null&&t!==void 0?t:null;this.lastNotifiedUid!==r&&(this.lastNotifiedUid=r,this.authStateSubscription.next(this.currentUser))}registerStateListener(e,t,r,i){if(this._deleted)return()=>{};let s=typeof t=="function"?t:t.next.bind(t),o=!1,c=this._isInitialized?Promise.resolve():this._initializationPromise;if(f(c,this,"internal-error"),c.then(()=>{o||s(this.currentUser)}),typeof t=="function"){let a=e.addObserver(t,r,i);return()=>{o=!0,a()}}else{let a=e.addObserver(t);return()=>{o=!0,a()}}}async directlySetCurrentUser(e){this.currentUser&&this.currentUser!==e&&this._currentUser._stopProactiveRefresh(),e&&this.isProactiveRefreshEnabled&&e._startProactiveRefresh(),this.currentUser=e,e?await this.assertedPersistence.setCurrentUser(e):await this.assertedPersistence.removeCurrentUser()}queue(e){return this.operations=this.operations.then(e,e),this.operations}get assertedPersistence(){return f(this.persistenceManager,this,"internal-error"),this.persistenceManager}_logFramework(e){!e||this.frameworks.includes(e)||(this.frameworks.push(e),this.frameworks.sort(),this.clientVersion=Nr(this.config.clientPlatform,this._getFrameworks()))}_getFrameworks(){return this.frameworks}async _getAdditionalHeaders(){var e;let t={"X-Client-Version":this.clientVersion};this.app.options.appId&&(t["X-Firebase-gmpid"]=this.app.options.appId);let r=await((e=this.heartbeatServiceProvider.getImmediate({optional:!0}))===null||e===void 0?void 0:e.getHeartbeatsHeader());r&&(t["X-Firebase-Client"]=r);let i=await this._getAppCheckToken();return i&&(t["X-Firebase-AppCheck"]=i),t}async _getAppCheckToken(){var e;let t=await((e=this.appCheckServiceProvider.getImmediate({optional:!0}))===null||e===void 0?void 0:e.getToken());return t?.error&&Cs(`Error while retrieving App Check token: ${t.error}`),t?.token}};function pe(n){return H(n)}var Xe=class{constructor(e){this.auth=e,this.observer=null,this.addObserver=Wn(t=>this.observer=t)}get next(){return f(this.observer,this.auth,"internal-error"),this.observer.next.bind(this.observer)}};function Qs(){var n,e;return(e=(n=document.getElementsByTagName("head"))===null||n===void 0?void 0:n[0])!==null&&e!==void 0?e:document}function Dr(n){return new Promise((e,t)=>{let r=document.createElement("script");r.setAttribute("src",n),r.onload=e,r.onerror=i=>{let s=L("internal-error");s.customData=i,t(s)},r.type="text/javascript",r.charset="UTF-8",Qs().appendChild(r)})}function Lr(n){return`__${n}${Math.floor(Math.random()*1e6)}`}var Zs="https://www.google.com/recaptcha/enterprise.js?render=",eo="recaptcha-enterprise",to="NO_RECAPTCHA",rn=class{constructor(e){this.type=eo,this.auth=pe(e)}async verify(e="verify",t=!1){async function r(s){if(!t){if(s.tenantId==null&&s._agentRecaptchaConfig!=null)return s._agentRecaptchaConfig.siteKey;if(s.tenantId!=null&&s._tenantRecaptchaConfigs[s.tenantId]!==void 0)return s._tenantRecaptchaConfigs[s.tenantId].siteKey}return new Promise(async(o,c)=>{Vs(s,{clientType:"CLIENT_TYPE_WEB",version:"RECAPTCHA_ENTERPRISE"}).then(a=>{if(a.recaptchaKey===void 0)c(new Error("recaptcha Enterprise site key undefined"));else{let l=new Xt(a);return s.tenantId==null?s._agentRecaptchaConfig=l:s._tenantRecaptchaConfigs[s.tenantId]=l,o(l.siteKey)}}).catch(a=>{c(a)})})}function i(s,o,c){let a=window.grecaptcha;rr(a)?a.enterprise.ready(()=>{a.enterprise.execute(s,{action:e}).then(l=>{o(l)}).catch(()=>{o(to)})}):c(Error("No reCAPTCHA enterprise script loaded."))}return new Promise((s,o)=>{r(this.auth).then(c=>{if(!t&&rr(window.grecaptcha))i(c,s,o);else{if(typeof window>"u"){o(new Error("RecaptchaVerifier is only supported in browser"));return}Dr(Zs+c).then(()=>{i(c,s,o)}).catch(a=>{o(a)})}}).catch(c=>{o(c)})})}};async function or(n,e,t,r=!1){let i=new rn(n),s;try{s=await i.verify(t)}catch{s=await i.verify(t,!0)}let o=Object.assign({},e);return r?Object.assign(o,{captchaResp:s}):Object.assign(o,{captchaResponse:s}),Object.assign(o,{clientType:"CLIENT_TYPE_WEB"}),Object.assign(o,{recaptchaVersion:"RECAPTCHA_ENTERPRISE"}),o}async function no(n,e,t,r){var i;if(!((i=n._getRecaptchaConfig())===null||i===void 0)&&i.isProviderEnabled("EMAIL_PASSWORD_PROVIDER")){let s=await or(n,e,t,t==="getOobCode");return r(n,s)}else return r(n,e).catch(async s=>{if(s.code==="auth/missing-recaptcha-token"){console.log(`${t} is protected by reCAPTCHA Enterprise for this project. Automatically triggering the reCAPTCHA flow and restarting the flow.`);let o=await or(n,e,t,t==="getOobCode");return r(n,o)}else return Promise.reject(s)})}function Mr(n,e){let t=zt(n,"auth");if(t.isInitialized()){let i=t.getImmediate(),s=t.getOptions();if(se(s,e??{}))return i;O(i,"already-initialized")}return t.initialize({options:e})}function ro(n,e){let t=e?.persistence||[],r=(Array.isArray(t)?t:[t]).map(U);e?.errorMap&&n._updateErrorMap(e.errorMap),n._initializeWithPersistence(r,e?.popupRedirectResolver)}function xr(n,e,t){let r=pe(n);f(r._canInitEmulator,r,"emulator-config-failed"),f(/^https?:\/\//.test(e),r,"invalid-emulator-scheme");let i=!!t?.disableWarnings,s=Ur(e),{host:o,port:c}=io(e),a=c===null?"":`:${c}`;r.config.emulator={url:`${s}//${o}${a}/`},r.settings.appVerificationDisabledForTesting=!0,r.emulatorConfig=Object.freeze({host:o,port:c,protocol:s.replace(":",""),options:Object.freeze({disableWarnings:i})}),i||so()}function Ur(n){let e=n.indexOf(":");return e<0?"":n.substr(0,e+1)}function io(n){let e=Ur(n),t=/(\/\/)?([^?#/]+)/.exec(n.substr(e.length));if(!t)return{host:"",port:null};let r=t[2].split("@").pop()||"",i=/^(\[[^\]]+\])(:|$)/.exec(r);if(i){let s=i[1];return{host:s,port:ar(r.substr(s.length+1))}}else{let[s,o]=r.split(":");return{host:s,port:ar(o)}}}function ar(n){if(!n)return null;let e=Number(n);return isNaN(e)?null:e}function so(){function n(){let e=document.createElement("p"),t=e.style;e.innerText="Running in emulator mode. Do not use with production credentials.",t.position="fixed",t.width="100%",t.backgroundColor="#ffffff",t.border=".1em solid #000000",t.color="#b50000",t.bottom="0px",t.left="0px",t.margin="0px",t.zIndex="10000",t.textAlign="center",e.classList.add("firebase-emulator-warning"),document.body.appendChild(e)}typeof console<"u"&&typeof console.info=="function"&&console.info("WARNING: You are using the Auth Emulator, which is intended for local testing only. Do not use with production credentials."),typeof window<"u"&&typeof document<"u"&&(document.readyState==="loading"?window.addEventListener("DOMContentLoaded",n):n())}var Y=class{constructor(e,t){this.providerId=e,this.signInMethod=t}toJSON(){return D("not implemented")}_getIdTokenResponse(e){return D("not implemented")}_linkToIdToken(e,t){return D("not implemented")}_getReauthenticationResolver(e){return D("not implemented")}};async function oo(n,e){return S(n,"POST","/v1/accounts:update",e)}async function ao(n,e){return te(n,"POST","/v1/accounts:signInWithPassword",T(n,e))}async function co(n,e){return te(n,"POST","/v1/accounts:signInWithEmailLink",T(n,e))}async function uo(n,e){return te(n,"POST","/v1/accounts:signInWithEmailLink",T(n,e))}var be=class n extends Y{constructor(e,t,r,i=null){super("password",r),this._email=e,this._password=t,this._tenantId=i}static _fromEmailAndPassword(e,t){return new n(e,t,"password")}static _fromEmailAndCode(e,t,r=null){return new n(e,t,"emailLink",r)}toJSON(){return{email:this._email,password:this._password,signInMethod:this.signInMethod,tenantId:this._tenantId}}static fromJSON(e){let t=typeof e=="string"?JSON.parse(e):e;if(t?.email&&t?.password){if(t.signInMethod==="password")return this._fromEmailAndPassword(t.email,t.password);if(t.signInMethod==="emailLink")return this._fromEmailAndCode(t.email,t.password,t.tenantId)}return null}async _getIdTokenResponse(e){switch(this.signInMethod){case"password":let t={returnSecureToken:!0,email:this._email,password:this._password,clientType:"CLIENT_TYPE_WEB"};return no(e,t,"signInWithPassword",ao);case"emailLink":return co(e,{email:this._email,oobCode:this._password});default:O(e,"internal-error")}}async _linkToIdToken(e,t){switch(this.signInMethod){case"password":return oo(e,{idToken:t,returnSecureToken:!0,email:this._email,password:this._password});case"emailLink":return uo(e,{idToken:t,email:this._email,oobCode:this._password});default:O(e,"internal-error")}}_getReauthenticationResolver(e){return this._getIdTokenResponse(e)}};async function he(n,e){return te(n,"POST","/v1/accounts:signInWithIdp",T(n,e))}var lo="http://localhost",X=class n extends Y{constructor(){super(...arguments),this.pendingToken=null}static _fromParams(e){let t=new n(e.providerId,e.signInMethod);return e.idToken||e.accessToken?(e.idToken&&(t.idToken=e.idToken),e.accessToken&&(t.accessToken=e.accessToken),e.nonce&&!e.pendingToken&&(t.nonce=e.nonce),e.pendingToken&&(t.pendingToken=e.pendingToken)):e.oauthToken&&e.oauthTokenSecret?(t.accessToken=e.oauthToken,t.secret=e.oauthTokenSecret):O("argument-error"),t}toJSON(){return{idToken:this.idToken,accessToken:this.accessToken,secret:this.secret,nonce:this.nonce,pendingToken:this.pendingToken,providerId:this.providerId,signInMethod:this.signInMethod}}static fromJSON(e){let t=typeof e=="string"?JSON.parse(e):e,{providerId:r,signInMethod:i}=t,s=Fe(t,["providerId","signInMethod"]);if(!r||!i)return null;let o=new n(r,i);return o.idToken=s.idToken||void 0,o.accessToken=s.accessToken||void 0,o.secret=s.secret,o.nonce=s.nonce,o.pendingToken=s.pendingToken||null,o}_getIdTokenResponse(e){let t=this.buildRequest();return he(e,t)}_linkToIdToken(e,t){let r=this.buildRequest();return r.idToken=t,he(e,r)}_getReauthenticationResolver(e){let t=this.buildRequest();return t.autoCreate=!1,he(e,t)}buildRequest(){let e={requestUri:lo,returnSecureToken:!0};if(this.pendingToken)e.pendingToken=this.pendingToken;else{let t={};this.idToken&&(t.id_token=this.idToken),this.accessToken&&(t.access_token=this.accessToken),this.secret&&(t.oauth_token_secret=this.secret),t.providerId=this.providerId,this.nonce&&!this.pendingToken&&(t.nonce=this.nonce),e.postBody=oe(t)}return e}};async function ho(n,e){return S(n,"POST","/v1/accounts:sendVerificationCode",T(n,e))}async function fo(n,e){return te(n,"POST","/v1/accounts:signInWithPhoneNumber",T(n,e))}async function po(n,e){let t=await te(n,"POST","/v1/accounts:signInWithPhoneNumber",T(n,e));if(t.temporaryProof)throw Ie(n,"account-exists-with-different-credential",t);return t}var _o={USER_NOT_FOUND:"user-not-found"};async function mo(n,e){let t=Object.assign(Object.assign({},e),{operation:"REAUTH"});return te(n,"POST","/v1/accounts:signInWithPhoneNumber",T(n,t),_o)}var Te=class n extends Y{constructor(e){super("phone","phone"),this.params=e}static _fromVerification(e,t){return new n({verificationId:e,verificationCode:t})}static _fromTokenResponse(e,t){return new n({phoneNumber:e,temporaryProof:t})}_getIdTokenResponse(e){return fo(e,this._makeVerificationRequest())}_linkToIdToken(e,t){return po(e,Object.assign({idToken:t},this._makeVerificationRequest()))}_getReauthenticationResolver(e){return mo(e,this._makeVerificationRequest())}_makeVerificationRequest(){let{temporaryProof:e,phoneNumber:t,verificationId:r,verificationCode:i}=this.params;return e&&t?{temporaryProof:e,phoneNumber:t}:{sessionInfo:r,code:i}}toJSON(){let e={providerId:this.providerId};return this.params.phoneNumber&&(e.phoneNumber=this.params.phoneNumber),this.params.temporaryProof&&(e.temporaryProof=this.params.temporaryProof),this.params.verificationCode&&(e.verificationCode=this.params.verificationCode),this.params.verificationId&&(e.verificationId=this.params.verificationId),e}static fromJSON(e){typeof e=="string"&&(e=JSON.parse(e));let{verificationId:t,verificationCode:r,phoneNumber:i,temporaryProof:s}=e;return!r&&!t&&!i&&!s?null:new n({verificationId:t,verificationCode:r,phoneNumber:i,temporaryProof:s})}};function go(n){switch(n){case"recoverEmail":return"RECOVER_EMAIL";case"resetPassword":return"PASSWORD_RESET";case"signIn":return"EMAIL_SIGNIN";case"verifyEmail":return"VERIFY_EMAIL";case"verifyAndChangeEmail":return"VERIFY_AND_CHANGE_EMAIL";case"revertSecondFactorAddition":return"REVERT_SECOND_FACTOR_ADDITION";default:return null}}function vo(n){let e=ae(ce(n)).link,t=e?ae(ce(e)).deep_link_id:null,r=ae(ce(n)).deep_link_id;return(r?ae(ce(r)).link:null)||r||t||e||n}var Qe=class n{constructor(e){var t,r,i,s,o,c;let a=ae(ce(e)),l=(t=a.apiKey)!==null&&t!==void 0?t:null,d=(r=a.oobCode)!==null&&r!==void 0?r:null,u=go((i=a.mode)!==null&&i!==void 0?i:null);f(l&&d&&u,"argument-error"),this.apiKey=l,this.operation=u,this.code=d,this.continueUrl=(s=a.continueUrl)!==null&&s!==void 0?s:null,this.languageCode=(o=a.languageCode)!==null&&o!==void 0?o:null,this.tenantId=(c=a.tenantId)!==null&&c!==void 0?c:null}static parseLink(e){let t=vo(e);try{return new n(t)}catch{return null}}};var fe=class n{constructor(){this.providerId=n.PROVIDER_ID}static credential(e,t){return be._fromEmailAndPassword(e,t)}static credentialWithLink(e,t){let r=Qe.parseLink(t);return f(r,"argument-error"),be._fromEmailAndCode(e,r.code,r.tenantId)}};fe.PROVIDER_ID="password";fe.EMAIL_PASSWORD_SIGN_IN_METHOD="password";fe.EMAIL_LINK_SIGN_IN_METHOD="emailLink";var Ae=class{constructor(e){this.providerId=e,this.defaultLanguageCode=null,this.customParameters={}}setDefaultLanguage(e){this.defaultLanguageCode=e}setCustomParameters(e){return this.customParameters=e,this}getCustomParameters(){return this.customParameters}};var Q=class extends Ae{constructor(){super(...arguments),this.scopes=[]}addScope(e){return this.scopes.includes(e)||this.scopes.push(e),this}getScopes(){return[...this.scopes]}};var Se=class n extends Q{constructor(){super("facebook.com")}static credential(e){return X._fromParams({providerId:n.PROVIDER_ID,signInMethod:n.FACEBOOK_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return n.credentialFromTaggedObject(e)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return n.credential(e.oauthAccessToken)}catch{return null}}};Se.FACEBOOK_SIGN_IN_METHOD="facebook.com";Se.PROVIDER_ID="facebook.com";var Z=class n extends Q{constructor(){super("google.com"),this.addScope("profile")}static credential(e,t){return X._fromParams({providerId:n.PROVIDER_ID,signInMethod:n.GOOGLE_SIGN_IN_METHOD,idToken:e,accessToken:t})}static credentialFromResult(e){return n.credentialFromTaggedObject(e)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{oauthIdToken:t,oauthAccessToken:r}=e;if(!t&&!r)return null;try{return n.credential(t,r)}catch{return null}}};Z.GOOGLE_SIGN_IN_METHOD="google.com";Z.PROVIDER_ID="google.com";var Re=class n extends Q{constructor(){super("github.com")}static credential(e){return X._fromParams({providerId:n.PROVIDER_ID,signInMethod:n.GITHUB_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return n.credentialFromTaggedObject(e)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return n.credential(e.oauthAccessToken)}catch{return null}}};Re.GITHUB_SIGN_IN_METHOD="github.com";Re.PROVIDER_ID="github.com";var ke=class n extends Q{constructor(){super("twitter.com")}static credential(e,t){return X._fromParams({providerId:n.PROVIDER_ID,signInMethod:n.TWITTER_SIGN_IN_METHOD,oauthToken:e,oauthTokenSecret:t})}static credentialFromResult(e){return n.credentialFromTaggedObject(e)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{oauthAccessToken:t,oauthTokenSecret:r}=e;if(!t||!r)return null;try{return n.credential(t,r)}catch{return null}}};ke.TWITTER_SIGN_IN_METHOD="twitter.com";ke.PROVIDER_ID="twitter.com";var Oe=class n{constructor(e){this.user=e.user,this.providerId=e.providerId,this._tokenResponse=e._tokenResponse,this.operationType=e.operationType}static async _fromIdTokenResponse(e,t,r,i=!1){let s=await we._fromIdTokenResponse(e,r,i),o=cr(r);return new n({user:s,providerId:o,_tokenResponse:r,operationType:t})}static async _forOperation(e,t,r){await e._updateTokensIfNecessary(r,!0);let i=cr(r);return new n({user:e,providerId:i,_tokenResponse:r,operationType:t})}};function cr(n){return n.providerId?n.providerId:"phoneNumber"in n?"phone":null}var sn=class n extends P{constructor(e,t,r,i){var s;super(t.code,t.message),this.operationType=r,this.user=i,Object.setPrototypeOf(this,n.prototype),this.customData={appName:e.name,tenantId:(s=e.tenantId)!==null&&s!==void 0?s:void 0,_serverResponse:t.customData._serverResponse,operationType:r}}static _fromErrorAndOperation(e,t,r,i){return new n(e,t,r,i)}};function Fr(n,e,t,r){return(e==="reauthenticate"?t._getReauthenticationResolver(n):t._getIdTokenResponse(n)).catch(s=>{throw s.code==="auth/multi-factor-auth-required"?sn._fromErrorAndOperation(n,s,e,r):s})}async function Io(n,e,t=!1){let r=await Ee(n,e._linkToIdToken(n.auth,await n.getIdToken()),t);return Oe._forOperation(n,"link",r)}async function yo(n,e,t=!1){let{auth:r}=n,i="reauthenticate";try{let s=await Ee(n,Fr(r,i,e,n),t);f(s.idToken,r,"internal-error");let o=_n(s.idToken);f(o,r,"internal-error");let{sub:c}=o;return f(n.uid===c,r,"user-mismatch"),Oe._forOperation(n,i,s)}catch(s){throw s?.code==="auth/user-not-found"&&O(r,"user-mismatch"),s}}async function Eo(n,e,t=!1){let r="signIn",i=await Fr(n,r,e),s=await Oe._fromIdTokenResponse(n,r,i);return t||await n._updateCurrentUser(s.user),s}function Vr(n,e,t,r){return H(n).onIdTokenChanged(e,t,r)}function Hr(n,e,t){return H(n).beforeAuthStateChanged(e,t)}function wo(n,e){return S(n,"POST","/v2/accounts/mfaEnrollment:start",T(n,e))}function bo(n,e){return S(n,"POST","/v2/accounts/mfaEnrollment:finalize",T(n,e))}function To(n,e){return S(n,"POST","/v2/accounts/mfaEnrollment:start",T(n,e))}function Ao(n,e){return S(n,"POST","/v2/accounts/mfaEnrollment:finalize",T(n,e))}var Ze="__sak";var et=class{constructor(e,t){this.storageRetriever=e,this.type=t}_isAvailable(){try{return this.storage?(this.storage.setItem(Ze,"1"),this.storage.removeItem(Ze),Promise.resolve(!0)):Promise.resolve(!1)}catch{return Promise.resolve(!1)}}_set(e,t){return this.storage.setItem(e,JSON.stringify(t)),Promise.resolve()}_get(e){let t=this.storage.getItem(e);return Promise.resolve(t?JSON.parse(t):null)}_remove(e){return this.storage.removeItem(e),Promise.resolve()}get storage(){return this.storageRetriever()}};function So(){let n=b();return mn(n)||pt(n)}var Ro=1e3,ko=10,tt=class extends et{constructor(){super(()=>window.localStorage,"LOCAL"),this.boundEventHandler=(e,t)=>this.onStorageEvent(e,t),this.listeners={},this.localCache={},this.pollTimer=null,this.safariLocalStorageNotSynced=So()&&Js(),this.fallbackToPolling=Cr(),this._shouldAllowMigration=!0}forAllChangedKeys(e){for(let t of Object.keys(this.listeners)){let r=this.storage.getItem(t),i=this.localCache[t];r!==i&&e(t,i,r)}}onStorageEvent(e,t=!1){if(!e.key){this.forAllChangedKeys((o,c,a)=>{this.notifyListeners(o,a)});return}let r=e.key;if(t?this.detachListener():this.stopPolling(),this.safariLocalStorageNotSynced){let o=this.storage.getItem(r);if(e.newValue!==o)e.newValue!==null?this.storage.setItem(r,e.newValue):this.storage.removeItem(r);else if(this.localCache[r]===e.newValue&&!t)return}let i=()=>{let o=this.storage.getItem(r);!t&&this.localCache[r]===o||this.notifyListeners(r,o)},s=this.storage.getItem(r);Ks()&&s!==e.newValue&&e.newValue!==e.oldValue?setTimeout(i,ko):i()}notifyListeners(e,t){this.localCache[e]=t;let r=this.listeners[e];if(r)for(let i of Array.from(r))i(t&&JSON.parse(t))}startPolling(){this.stopPolling(),this.pollTimer=setInterval(()=>{this.forAllChangedKeys((e,t,r)=>{this.onStorageEvent(new StorageEvent("storage",{key:e,oldValue:t,newValue:r}),!0)})},Ro)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}attachListener(){window.addEventListener("storage",this.boundEventHandler)}detachListener(){window.removeEventListener("storage",this.boundEventHandler)}_addListener(e,t){Object.keys(this.listeners).length===0&&(this.fallbackToPolling?this.startPolling():this.attachListener()),this.listeners[e]||(this.listeners[e]=new Set,this.localCache[e]=this.storage.getItem(e)),this.listeners[e].add(t)}_removeListener(e,t){this.listeners[e]&&(this.listeners[e].delete(t),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&(this.detachListener(),this.stopPolling())}async _set(e,t){await super._set(e,t),this.localCache[e]=JSON.stringify(t)}async _get(e){let t=await super._get(e);return this.localCache[e]=JSON.stringify(t),t}async _remove(e){await super._remove(e),delete this.localCache[e]}};tt.type="LOCAL";var Wr=tt;var nt=class extends et{constructor(){super(()=>window.sessionStorage,"SESSION")}_addListener(e,t){}_removeListener(e,t){}};nt.type="SESSION";var gn=nt;function Oo(n){return Promise.all(n.map(async e=>{try{return{fulfilled:!0,value:await e}}catch(t){return{fulfilled:!1,reason:t}}}))}var rt=class n{constructor(e){this.eventTarget=e,this.handlersMap={},this.boundEventHandler=this.handleEvent.bind(this)}static _getInstance(e){let t=this.receivers.find(i=>i.isListeningto(e));if(t)return t;let r=new n(e);return this.receivers.push(r),r}isListeningto(e){return this.eventTarget===e}async handleEvent(e){let t=e,{eventId:r,eventType:i,data:s}=t.data,o=this.handlersMap[i];if(!o?.size)return;t.ports[0].postMessage({status:"ack",eventId:r,eventType:i});let c=Array.from(o).map(async l=>l(t.origin,s)),a=await Oo(c);t.ports[0].postMessage({status:"done",eventId:r,eventType:i,response:a})}_subscribe(e,t){Object.keys(this.handlersMap).length===0&&this.eventTarget.addEventListener("message",this.boundEventHandler),this.handlersMap[e]||(this.handlersMap[e]=new Set),this.handlersMap[e].add(t)}_unsubscribe(e,t){this.handlersMap[e]&&t&&this.handlersMap[e].delete(t),(!t||this.handlersMap[e].size===0)&&delete this.handlersMap[e],Object.keys(this.handlersMap).length===0&&this.eventTarget.removeEventListener("message",this.boundEventHandler)}};rt.receivers=[];function vn(n="",e=10){let t="";for(let r=0;r<e;r++)t+=Math.floor(Math.random()*10);return n+t}var on=class{constructor(e){this.target=e,this.handlers=new Set}removeMessageHandler(e){e.messageChannel&&(e.messageChannel.port1.removeEventListener("message",e.onMessage),e.messageChannel.port1.close()),this.handlers.delete(e)}async _send(e,t,r=50){let i=typeof MessageChannel<"u"?new MessageChannel:null;if(!i)throw new Error("connection_unavailable");let s,o;return new Promise((c,a)=>{let l=vn("",20);i.port1.start();let d=setTimeout(()=>{a(new Error("unsupported_event"))},r);o={messageChannel:i,onMessage(u){let _=u;if(_.data.eventId===l)switch(_.data.status){case"ack":clearTimeout(d),s=setTimeout(()=>{a(new Error("timeout"))},3e3);break;case"done":clearTimeout(s),c(_.data.response);break;default:clearTimeout(d),clearTimeout(s),a(new Error("invalid_response"));break}}},this.handlers.add(o),i.port1.addEventListener("message",o.onMessage),this.target.postMessage({eventType:e,eventId:l,data:t},[i.port2])}).finally(()=>{o&&this.removeMessageHandler(o)})}};function M(){return window}function Po(n){M().location.href=n}function Br(){return typeof M().WorkerGlobalScope<"u"&&typeof M().importScripts=="function"}async function Co(){if(!navigator?.serviceWorker)return null;try{return(await navigator.serviceWorker.ready).active}catch{return null}}function No(){var n;return((n=navigator?.serviceWorker)===null||n===void 0?void 0:n.controller)||null}function Do(){return Br()?self:null}var jr="firebaseLocalStorageDb",Lo=1,it="firebaseLocalStorage",$r="fbase_key",ee=class{constructor(e){this.request=e}toPromise(){return new Promise((e,t)=>{this.request.addEventListener("success",()=>{e(this.request.result)}),this.request.addEventListener("error",()=>{t(this.request.error)})})}};function _t(n,e){return n.transaction([it],e?"readwrite":"readonly").objectStore(it)}function Mo(){let n=indexedDB.deleteDatabase(jr);return new ee(n).toPromise()}function an(){let n=indexedDB.open(jr,Lo);return new Promise((e,t)=>{n.addEventListener("error",()=>{t(n.error)}),n.addEventListener("upgradeneeded",()=>{let r=n.result;try{r.createObjectStore(it,{keyPath:$r})}catch(i){t(i)}}),n.addEventListener("success",async()=>{let r=n.result;r.objectStoreNames.contains(it)?e(r):(r.close(),await Mo(),e(await an()))})})}async function ur(n,e,t){let r=_t(n,!0).put({[$r]:e,value:t});return new ee(r).toPromise()}async function xo(n,e){let t=_t(n,!1).get(e),r=await new ee(t).toPromise();return r===void 0?null:r.value}function lr(n,e){let t=_t(n,!0).delete(e);return new ee(t).toPromise()}var Uo=800,Fo=3,st=class{constructor(){this.type="LOCAL",this._shouldAllowMigration=!0,this.listeners={},this.localCache={},this.pollTimer=null,this.pendingWrites=0,this.receiver=null,this.sender=null,this.serviceWorkerReceiverAvailable=!1,this.activeServiceWorker=null,this._workerInitializationPromise=this.initializeServiceWorkerMessaging().then(()=>{},()=>{})}async _openDb(){return this.db?this.db:(this.db=await an(),this.db)}async _withRetries(e){let t=0;for(;;)try{let r=await this._openDb();return await e(r)}catch(r){if(t++>Fo)throw r;this.db&&(this.db.close(),this.db=void 0)}}async initializeServiceWorkerMessaging(){return Br()?this.initializeReceiver():this.initializeSender()}async initializeReceiver(){this.receiver=rt._getInstance(Do()),this.receiver._subscribe("keyChanged",async(e,t)=>({keyProcessed:(await this._poll()).includes(t.key)})),this.receiver._subscribe("ping",async(e,t)=>["keyChanged"])}async initializeSender(){var e,t;if(this.activeServiceWorker=await Co(),!this.activeServiceWorker)return;this.sender=new on(this.activeServiceWorker);let r=await this.sender._send("ping",{},800);r&&!((e=r[0])===null||e===void 0)&&e.fulfilled&&!((t=r[0])===null||t===void 0)&&t.value.includes("keyChanged")&&(this.serviceWorkerReceiverAvailable=!0)}async notifyServiceWorker(e){if(!(!this.sender||!this.activeServiceWorker||No()!==this.activeServiceWorker))try{await this.sender._send("keyChanged",{key:e},this.serviceWorkerReceiverAvailable?800:50)}catch{}}async _isAvailable(){try{if(!indexedDB)return!1;let e=await an();return await ur(e,Ze,"1"),await lr(e,Ze),!0}catch{}return!1}async _withPendingWrite(e){this.pendingWrites++;try{await e()}finally{this.pendingWrites--}}async _set(e,t){return this._withPendingWrite(async()=>(await this._withRetries(r=>ur(r,e,t)),this.localCache[e]=t,this.notifyServiceWorker(e)))}async _get(e){let t=await this._withRetries(r=>xo(r,e));return this.localCache[e]=t,t}async _remove(e){return this._withPendingWrite(async()=>(await this._withRetries(t=>lr(t,e)),delete this.localCache[e],this.notifyServiceWorker(e)))}async _poll(){let e=await this._withRetries(i=>{let s=_t(i,!1).getAll();return new ee(s).toPromise()});if(!e)return[];if(this.pendingWrites!==0)return[];let t=[],r=new Set;for(let{fbase_key:i,value:s}of e)r.add(i),JSON.stringify(this.localCache[i])!==JSON.stringify(s)&&(this.notifyListeners(i,s),t.push(i));for(let i of Object.keys(this.localCache))this.localCache[i]&&!r.has(i)&&(this.notifyListeners(i,null),t.push(i));return t}notifyListeners(e,t){this.localCache[e]=t;let r=this.listeners[e];if(r)for(let i of Array.from(r))i(t)}startPolling(){this.stopPolling(),this.pollTimer=setInterval(async()=>this._poll(),Uo)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}_addListener(e,t){Object.keys(this.listeners).length===0&&this.startPolling(),this.listeners[e]||(this.listeners[e]=new Set,this._get(e)),this.listeners[e].add(t)}_removeListener(e,t){this.listeners[e]&&(this.listeners[e].delete(t),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&this.stopPolling()}};st.type="LOCAL";var zr=st;function Vo(n,e){return S(n,"POST","/v2/accounts/mfaSignIn:start",T(n,e))}function Ho(n,e){return S(n,"POST","/v2/accounts/mfaSignIn:finalize",T(n,e))}function Wo(n,e){return S(n,"POST","/v2/accounts/mfaSignIn:finalize",T(n,e))}var yc=Lr("rcb"),Ec=new J(3e4,6e4);var Bo="recaptcha";async function jo(n,e,t){var r;let i=await t.verify();try{f(typeof i=="string",n,"argument-error"),f(t.type===Bo,n,"argument-error");let s;if(typeof e=="string"?s={phoneNumber:e}:s=e,"session"in s){let o=s.session;if("phoneNumber"in s)return f(o.type==="enroll",n,"internal-error"),(await wo(n,{idToken:o.credential,phoneEnrollmentInfo:{phoneNumber:s.phoneNumber,recaptchaToken:i}})).phoneSessionInfo.sessionInfo;{f(o.type==="signin",n,"internal-error");let c=((r=s.multiFactorHint)===null||r===void 0?void 0:r.uid)||s.multiFactorUid;return f(c,n,"missing-multi-factor-info"),(await Vo(n,{mfaPendingCredential:o.credential,mfaEnrollmentId:c,phoneSignInInfo:{recaptchaToken:i}})).phoneResponseInfo.sessionInfo}}else{let{sessionInfo:o}=await ho(n,{phoneNumber:s.phoneNumber,recaptchaToken:i});return o}}finally{t._reset()}}var Pe=class n{constructor(e){this.providerId=n.PROVIDER_ID,this.auth=pe(e)}verifyPhoneNumber(e,t){return jo(this.auth,e,H(t))}static credential(e,t){return Te._fromVerification(e,t)}static credentialFromResult(e){let t=e;return n.credentialFromTaggedObject(t)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{phoneNumber:t,temporaryProof:r}=e;return t&&r?Te._fromTokenResponse(t,r):null}};Pe.PROVIDER_ID="phone";Pe.PHONE_SIGN_IN_METHOD="phone";function qr(n,e){return e?U(e):(f(n._popupRedirectResolver,n,"argument-error"),n._popupRedirectResolver)}var Ce=class extends Y{constructor(e){super("custom","custom"),this.params=e}_getIdTokenResponse(e){return he(e,this._buildIdpRequest())}_linkToIdToken(e,t){return he(e,this._buildIdpRequest(t))}_getReauthenticationResolver(e){return he(e,this._buildIdpRequest())}_buildIdpRequest(e){let t={requestUri:this.params.requestUri,sessionId:this.params.sessionId,postBody:this.params.postBody,tenantId:this.params.tenantId,pendingToken:this.params.pendingToken,returnSecureToken:!0,returnIdpCredential:!0};return e&&(t.idToken=e),t}};function $o(n){return Eo(n.auth,new Ce(n),n.bypassAuthState)}function zo(n){let{auth:e,user:t}=n;return f(t,e,"internal-error"),yo(t,new Ce(n),n.bypassAuthState)}async function qo(n){let{auth:e,user:t}=n;return f(t,e,"internal-error"),Io(t,new Ce(n),n.bypassAuthState)}var ot=class{constructor(e,t,r,i,s=!1){this.auth=e,this.resolver=r,this.user=i,this.bypassAuthState=s,this.pendingPromise=null,this.eventManager=null,this.filter=Array.isArray(t)?t:[t]}execute(){return new Promise(async(e,t)=>{this.pendingPromise={resolve:e,reject:t};try{this.eventManager=await this.resolver._initialize(this.auth),await this.onExecution(),this.eventManager.registerConsumer(this)}catch(r){this.reject(r)}})}async onAuthEvent(e){let{urlResponse:t,sessionId:r,postBody:i,tenantId:s,error:o,type:c}=e;if(o){this.reject(o);return}let a={auth:this.auth,requestUri:t,sessionId:r,tenantId:s||void 0,postBody:i||void 0,user:this.user,bypassAuthState:this.bypassAuthState};try{this.resolve(await this.getIdpTask(c)(a))}catch(l){this.reject(l)}}onError(e){this.reject(e)}getIdpTask(e){switch(e){case"signInViaPopup":case"signInViaRedirect":return $o;case"linkViaPopup":case"linkViaRedirect":return qo;case"reauthViaPopup":case"reauthViaRedirect":return zo;default:O(this.auth,"internal-error")}}resolve(e){F(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.resolve(e),this.unregisterAndCleanUp()}reject(e){F(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.reject(e),this.unregisterAndCleanUp()}unregisterAndCleanUp(){this.eventManager&&this.eventManager.unregisterConsumer(this),this.pendingPromise=null,this.cleanUp()}};var Go=new J(2e3,1e4);async function In(n,e,t){let r=pe(n);Ns(n,e,Ae);let i=qr(r,t);return new at(r,"signInViaPopup",e,i).executeNotNull()}var at=class n extends ot{constructor(e,t,r,i,s){super(e,t,i,s),this.provider=r,this.authWindow=null,this.pollId=null,n.currentPopupAction&&n.currentPopupAction.cancel(),n.currentPopupAction=this}async executeNotNull(){let e=await this.execute();return f(e,this.auth,"internal-error"),e}async onExecution(){F(this.filter.length===1,"Popup operations only handle one event");let e=vn();this.authWindow=await this.resolver._openPopup(this.auth,this.provider,this.filter[0],e),this.authWindow.associatedEvent=e,this.resolver._originValidation(this.auth).catch(t=>{this.reject(t)}),this.resolver._isIframeWebStorageSupported(this.auth,t=>{t||this.reject(L(this.auth,"web-storage-unsupported"))}),this.pollUserCancellation()}get eventId(){var e;return((e=this.authWindow)===null||e===void 0?void 0:e.associatedEvent)||null}cancel(){this.reject(L(this.auth,"cancelled-popup-request"))}cleanUp(){this.authWindow&&this.authWindow.close(),this.pollId&&window.clearTimeout(this.pollId),this.authWindow=null,this.pollId=null,n.currentPopupAction=null}pollUserCancellation(){let e=()=>{var t,r;if(!((r=(t=this.authWindow)===null||t===void 0?void 0:t.window)===null||r===void 0)&&r.closed){this.pollId=window.setTimeout(()=>{this.pollId=null,this.reject(L(this.auth,"popup-closed-by-user"))},8e3);return}this.pollId=window.setTimeout(e,Go.get())};e()}};at.currentPopupAction=null;var Ko="pendingRedirect",Be=new Map,cn=class extends ot{constructor(e,t,r=!1){super(e,["signInViaRedirect","linkViaRedirect","reauthViaRedirect","unknown"],t,void 0,r),this.eventId=null}async execute(){let e=Be.get(this.auth._key());if(!e){try{let r=await Jo(this.resolver,this.auth)?await super.execute():null;e=()=>Promise.resolve(r)}catch(t){e=()=>Promise.reject(t)}Be.set(this.auth._key(),e)}return this.bypassAuthState||Be.set(this.auth._key(),()=>Promise.resolve(null)),e()}async onAuthEvent(e){if(e.type==="signInViaRedirect")return super.onAuthEvent(e);if(e.type==="unknown"){this.resolve(null);return}if(e.eventId){let t=await this.auth._redirectUserForId(e.eventId);if(t)return this.user=t,super.onAuthEvent(e);this.resolve(null)}}async onExecution(){}cleanUp(){}};async function Jo(n,e){let t=Qo(e),r=Xo(n);if(!await r._isAvailable())return!1;let i=await r._get(t)==="true";return await r._remove(t),i}function Yo(n,e){Be.set(n._key(),e)}function Xo(n){return U(n._redirectPersistence)}function Qo(n){return We(Ko,n.config.apiKey,n.name)}async function Zo(n,e,t=!1){let r=pe(n),i=qr(r,e),o=await new cn(r,i,t).execute();return o&&!t&&(delete o.user._redirectEventId,await r._persistUserIfCurrent(o.user),await r._setRedirectUser(null,e)),o}var ea=10*60*1e3,un=class{constructor(e){this.auth=e,this.cachedEventUids=new Set,this.consumers=new Set,this.queuedRedirectEvent=null,this.hasHandledPotentialRedirect=!1,this.lastProcessedEventTime=Date.now()}registerConsumer(e){this.consumers.add(e),this.queuedRedirectEvent&&this.isEventForConsumer(this.queuedRedirectEvent,e)&&(this.sendToConsumer(this.queuedRedirectEvent,e),this.saveEventToCache(this.queuedRedirectEvent),this.queuedRedirectEvent=null)}unregisterConsumer(e){this.consumers.delete(e)}onEvent(e){if(this.hasEventBeenHandled(e))return!1;let t=!1;return this.consumers.forEach(r=>{this.isEventForConsumer(e,r)&&(t=!0,this.sendToConsumer(e,r),this.saveEventToCache(e))}),this.hasHandledPotentialRedirect||!ta(e)||(this.hasHandledPotentialRedirect=!0,t||(this.queuedRedirectEvent=e,t=!0)),t}sendToConsumer(e,t){var r;if(e.error&&!Gr(e)){let i=((r=e.error.code)===null||r===void 0?void 0:r.split("auth/")[1])||"internal-error";t.onError(L(this.auth,i))}else t.onAuthEvent(e)}isEventForConsumer(e,t){let r=t.eventId===null||!!e.eventId&&e.eventId===t.eventId;return t.filter.includes(e.type)&&r}hasEventBeenHandled(e){return Date.now()-this.lastProcessedEventTime>=ea&&this.cachedEventUids.clear(),this.cachedEventUids.has(dr(e))}saveEventToCache(e){this.cachedEventUids.add(dr(e)),this.lastProcessedEventTime=Date.now()}};function dr(n){return[n.type,n.eventId,n.sessionId,n.tenantId].filter(e=>e).join("-")}function Gr({type:n,error:e}){return n==="unknown"&&e?.code==="auth/no-auth-event"}function ta(n){switch(n.type){case"signInViaRedirect":case"linkViaRedirect":case"reauthViaRedirect":return!0;case"unknown":return Gr(n);default:return!1}}async function na(n,e={}){return S(n,"GET","/v1/projects",e)}var ra=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/,ia=/^https?/;async function sa(n){if(n.config.emulator)return;let{authorizedDomains:e}=await na(n);for(let t of e)try{if(oa(t))return}catch{}O(n,"unauthorized-domain")}function oa(n){let e=Jt(),{protocol:t,hostname:r}=new URL(e);if(n.startsWith("chrome-extension://")){let o=new URL(n);return o.hostname===""&&r===""?t==="chrome-extension:"&&n.replace("chrome-extension://","")===e.replace("chrome-extension://",""):t==="chrome-extension:"&&o.hostname===r}if(!ia.test(t))return!1;if(ra.test(n))return r===n;let i=n.replace(/\./g,"\\.");return new RegExp("^(.+\\."+i+"|"+i+")$","i").test(r)}var aa=new J(3e4,6e4);function hr(){let n=M().___jsl;if(n?.H){for(let e of Object.keys(n.H))if(n.H[e].r=n.H[e].r||[],n.H[e].L=n.H[e].L||[],n.H[e].r=[...n.H[e].L],n.CP)for(let t=0;t<n.CP.length;t++)n.CP[t]=null}}function ca(n){return new Promise((e,t)=>{var r,i,s;function o(){hr(),gapi.load("gapi.iframes",{callback:()=>{e(gapi.iframes.getContext())},ontimeout:()=>{hr(),t(L(n,"network-request-failed"))},timeout:aa.get()})}if(!((i=(r=M().gapi)===null||r===void 0?void 0:r.iframes)===null||i===void 0)&&i.Iframe)e(gapi.iframes.getContext());else if(!((s=M().gapi)===null||s===void 0)&&s.load)o();else{let c=Lr("iframefcb");return M()[c]=()=>{gapi.load?o():t(L(n,"network-request-failed"))},Dr(`https://apis.google.com/js/api.js?onload=${c}`).catch(a=>t(a))}}).catch(e=>{throw je=null,e})}var je=null;function ua(n){return je=je||ca(n),je}var la=new J(5e3,15e3),da="__/auth/iframe",ha="emulator/auth/iframe",fa={style:{position:"absolute",top:"-100px",width:"1px",height:"1px"},"aria-hidden":"true",tabindex:"-1"},pa=new Map([["identitytoolkit.googleapis.com","p"],["staging-identitytoolkit.sandbox.googleapis.com","s"],["test-identitytoolkit.sandbox.googleapis.com","t"]]);function _a(n){let e=n.config;f(e.authDomain,n,"auth-domain-config-required");let t=e.emulator?pn(e,ha):`https://${n.config.authDomain}/${da}`,r={apiKey:e.apiKey,appName:n.name,v:de},i=pa.get(n.config.apiHost);i&&(r.eid=i);let s=n._getFrameworks();return s.length&&(r.fw=s.join(",")),`${t}?${oe(r).slice(1)}`}async function ma(n){let e=await ua(n),t=M().gapi;return f(t,n,"internal-error"),e.open({where:document.body,url:_a(n),messageHandlersFilter:t.iframes.CROSS_ORIGIN_IFRAMES_FILTER,attributes:fa,dontclear:!0},r=>new Promise(async(i,s)=>{await r.restyle({setHideOnLeave:!1});let o=L(n,"network-request-failed"),c=M().setTimeout(()=>{s(o)},la.get());function a(){M().clearTimeout(c),i(r)}r.ping(a).then(a,()=>{s(o)})}))}var ga={location:"yes",resizable:"yes",statusbar:"yes",toolbar:"no"},va=500,Ia=600,ya="_blank",Ea="http://localhost",ct=class{constructor(e){this.window=e,this.associatedEvent=null}close(){if(this.window)try{this.window.close()}catch{}}};function wa(n,e,t,r=va,i=Ia){let s=Math.max((window.screen.availHeight-i)/2,0).toString(),o=Math.max((window.screen.availWidth-r)/2,0).toString(),c="",a=Object.assign(Object.assign({},ga),{width:r.toString(),height:i.toString(),top:s,left:o}),l=b().toLowerCase();t&&(c=Sr(l)?ya:t),Ar(l)&&(e=e||Ea,a.scrollbars="yes");let d=Object.entries(a).reduce((_,[h,v])=>`${_}${h}=${v},`,"");if(Gs(l)&&c!=="_self")return ba(e||"",c),new ct(null);let u=window.open(e||"",c,d);f(u,n,"popup-blocked");try{u.focus()}catch{}return new ct(u)}function ba(n,e){let t=document.createElement("a");t.href=n,t.target=e;let r=document.createEvent("MouseEvent");r.initMouseEvent("click",!0,!0,window,1,0,0,0,0,!1,!1,!1,!1,1,null),t.dispatchEvent(r)}var Ta="__/auth/handler",Aa="emulator/auth/handler",Sa=encodeURIComponent("fac");async function fr(n,e,t,r,i,s){f(n.config.authDomain,n,"auth-domain-config-required"),f(n.config.apiKey,n,"invalid-api-key");let o={apiKey:n.config.apiKey,appName:n.name,authType:t,redirectUrl:r,v:de,eventId:i};if(e instanceof Ae){e.setDefaultLanguage(n.languageCode),o.providerId=e.providerId||"",Hn(e.getCustomParameters())||(o.customParameters=JSON.stringify(e.getCustomParameters()));for(let[d,u]of Object.entries(s||{}))o[d]=u}if(e instanceof Q){let d=e.getScopes().filter(u=>u!=="");d.length>0&&(o.scopes=d.join(","))}n.tenantId&&(o.tid=n.tenantId);let c=o;for(let d of Object.keys(c))c[d]===void 0&&delete c[d];let a=await n._getAppCheckToken(),l=a?`#${Sa}=${encodeURIComponent(a)}`:"";return`${Ra(n)}?${oe(c).slice(1)}${l}`}function Ra({config:n}){return n.emulator?pn(n,Aa):`https://${n.authDomain}/${Ta}`}var Kt="webStorageSupport",ln=class{constructor(){this.eventManagers={},this.iframes={},this.originValidationPromises={},this._redirectPersistence=gn,this._completeRedirectFn=Zo,this._overrideRedirectResult=Yo}async _openPopup(e,t,r,i){var s;F((s=this.eventManagers[e._key()])===null||s===void 0?void 0:s.manager,"_initialize() not called before _openPopup()");let o=await fr(e,t,r,Jt(),i);return wa(e,o,vn())}async _openRedirect(e,t,r,i){await this._originValidation(e);let s=await fr(e,t,r,Jt(),i);return Po(s),new Promise(()=>{})}_initialize(e){let t=e._key();if(this.eventManagers[t]){let{manager:i,promise:s}=this.eventManagers[t];return i?Promise.resolve(i):(F(s,"If manager is not set, promise should be"),s)}let r=this.initAndGetManager(e);return this.eventManagers[t]={promise:r},r.catch(()=>{delete this.eventManagers[t]}),r}async initAndGetManager(e){let t=await ma(e),r=new un(e);return t.register("authEvent",i=>(f(i?.authEvent,e,"invalid-auth-event"),{status:r.onEvent(i.authEvent)?"ACK":"ERROR"}),gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER),this.eventManagers[e._key()]={manager:r},this.iframes[e._key()]=t,r}_isIframeWebStorageSupported(e,t){this.iframes[e._key()].send(Kt,{type:Kt},i=>{var s;let o=(s=i?.[0])===null||s===void 0?void 0:s[Kt];o!==void 0&&t(!!o),O(e,"internal-error")},gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER)}_originValidation(e){let t=e._key();return this.originValidationPromises[t]||(this.originValidationPromises[t]=sa(e)),this.originValidationPromises[t]}get _shouldInitProactively(){return Cr()||mn()||pt()}},Kr=ln,ut=class{constructor(e){this.factorId=e}_process(e,t,r){switch(t.type){case"enroll":return this._finalizeEnroll(e,t.credential,r);case"signin":return this._finalizeSignIn(e,t.credential);default:return D("unexpected MultiFactorSessionType")}}},dn=class n extends ut{constructor(e){super("phone"),this.credential=e}static _fromCredential(e){return new n(e)}_finalizeEnroll(e,t,r){return bo(e,{idToken:t,displayName:r,phoneVerificationInfo:this.credential._makeVerificationRequest()})}_finalizeSignIn(e,t){return Ho(e,{mfaPendingCredential:t,phoneVerificationInfo:this.credential._makeVerificationRequest()})}},lt=class{constructor(){}static assertion(e){return dn._fromCredential(e)}};lt.FACTOR_ID="phone";var dt=class{static assertionForEnrollment(e,t){return ht._fromSecret(e,t)}static assertionForSignIn(e,t){return ht._fromEnrollmentId(e,t)}static async generateSecret(e){var t;let r=e;f(typeof((t=r.user)===null||t===void 0?void 0:t.auth)<"u","internal-error");let i=await To(r.user.auth,{idToken:r.credential,totpEnrollmentInfo:{}});return ft._fromStartTotpMfaEnrollmentResponse(i,r.user.auth)}};dt.FACTOR_ID="totp";var ht=class n extends ut{constructor(e,t,r){super("totp"),this.otp=e,this.enrollmentId=t,this.secret=r}static _fromSecret(e,t){return new n(t,void 0,e)}static _fromEnrollmentId(e,t){return new n(t,e)}async _finalizeEnroll(e,t,r){return f(typeof this.secret<"u",e,"argument-error"),Ao(e,{idToken:t,displayName:r,totpVerificationInfo:this.secret._makeTotpVerificationInfo(this.otp)})}async _finalizeSignIn(e,t){f(this.enrollmentId!==void 0&&this.otp!==void 0,e,"argument-error");let r={verificationCode:this.otp};return Wo(e,{mfaPendingCredential:t,mfaEnrollmentId:this.enrollmentId,totpVerificationInfo:r})}},ft=class n{constructor(e,t,r,i,s,o,c){this.sessionInfo=o,this.auth=c,this.secretKey=e,this.hashingAlgorithm=t,this.codeLength=r,this.codeIntervalSeconds=i,this.enrollmentCompletionDeadline=s}static _fromStartTotpMfaEnrollmentResponse(e,t){return new n(e.totpSessionInfo.sharedSecretKey,e.totpSessionInfo.hashingAlgorithm,e.totpSessionInfo.verificationCodeLength,e.totpSessionInfo.periodSec,new Date(e.totpSessionInfo.finalizeEnrollmentTime).toUTCString(),e.totpSessionInfo.sessionInfo,t)}_makeTotpVerificationInfo(e){return{sessionInfo:this.sessionInfo,verificationCode:e}}generateQrCodeUrl(e,t){var r;let i=!1;return(Ve(e)||Ve(t))&&(i=!0),i&&(Ve(e)&&(e=((r=this.auth.currentUser)===null||r===void 0?void 0:r.email)||"unknownuser"),Ve(t)&&(t=this.auth.name)),`otpauth://totp/${t}:${e}?secret=${this.secretKey}&issuer=${t}&algorithm=${this.hashingAlgorithm}&digits=${this.codeLength}`}};function Ve(n){return typeof n>"u"||n?.length===0}var pr="@firebase/auth",_r="1.3.2";var hn=class{constructor(e){this.auth=e,this.internalListeners=new Map}getUid(){var e;return this.assertAuthConfigured(),((e=this.auth.currentUser)===null||e===void 0?void 0:e.uid)||null}async getToken(e){return this.assertAuthConfigured(),await this.auth._initializationPromise,this.auth.currentUser?{accessToken:await this.auth.currentUser.getIdToken(e)}:null}addAuthTokenListener(e){if(this.assertAuthConfigured(),this.internalListeners.has(e))return;let t=this.auth.onIdTokenChanged(r=>{e(r?.stsTokenManager.accessToken||null)});this.internalListeners.set(e,t),this.updateProactiveRefresh()}removeAuthTokenListener(e){this.assertAuthConfigured();let t=this.internalListeners.get(e);t&&(this.internalListeners.delete(e),t(),this.updateProactiveRefresh())}assertAuthConfigured(){f(this.auth._initializationPromise,"dependent-sdk-initialized-before-auth")}updateProactiveRefresh(){this.internalListeners.size>0?this.auth._startProactiveRefresh():this.auth._stopProactiveRefresh()}};function ka(n){switch(n){case"Node":return"node";case"ReactNative":return"rn";case"Worker":return"webworker";case"Cordova":return"cordova";default:return}}function Oa(n){le(new C("auth",(e,{options:t})=>{let r=e.getProvider("app").getImmediate(),i=e.getProvider("heartbeat"),s=e.getProvider("app-check-internal"),{apiKey:o,authDomain:c}=r.options;f(o&&!o.includes(":"),"invalid-api-key",{appName:r.name});let a={apiKey:o,authDomain:c,clientPlatform:n,apiHost:"identitytoolkit.googleapis.com",tokenApiHost:"securetoken.googleapis.com",apiScheme:"https",sdkClientVersion:Nr(n)},l=new nn(r,i,s,a);return ro(l,t),l},"PUBLIC").setInstantiationMode("EXPLICIT").setInstanceCreatedCallback((e,t,r)=>{e.getProvider("auth-internal").initialize()})),le(new C("auth-internal",e=>{let t=pe(e.getProvider("auth").getImmediate());return(r=>new hn(r))(t)},"PRIVATE").setInstantiationMode("EXPLICIT")),B(pr,_r,ka(n)),B(pr,_r,"esm2017")}var Pa=5*60,Ca=Pt("authIdTokenMaxAge")||Pa,mr=null,Na=n=>async e=>{let t=e&&await e.getIdTokenResult(),r=t&&(new Date().getTime()-Date.parse(t.issuedAtTime))/1e3;if(r&&r>Ca)return;let i=t?.token;mr!==i&&(mr=i,await fetch(n,{method:i?"POST":"DELETE",headers:i?{Authorization:`Bearer ${i}`}:{}}))};function yn(n=Zn()){let e=zt(n,"auth");if(e.isInitialized())return e.getImmediate();let t=Mr(n,{popupRedirectResolver:Kr,persistence:[zr,Wr,gn]}),r=Pt("authTokenSyncURL");if(r){let s=Na(r);Hr(t,s,()=>s(t.currentUser)),Vr(t,o=>s(o))}let i=Dn("auth");return i&&xr(t,`http://${i}`),t}Oa("Browser");var yt,p,ei,Da,ne,Jr,ti,En,La,Ne={},ni=[],Ma=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,bn=Array.isArray;function $(n,e){for(var t in e)n[t]=e[t];return n}function ri(n){var e=n.parentNode;e&&e.removeChild(n)}function xa(n,e,t){var r,i,s,o={};for(s in e)s=="key"?r=e[s]:s=="ref"?i=e[s]:o[s]=e[s];if(arguments.length>2&&(o.children=arguments.length>3?yt.call(arguments,2):t),typeof n=="function"&&n.defaultProps!=null)for(s in n.defaultProps)o[s]===void 0&&(o[s]=n.defaultProps[s]);return gt(n,o,r,i,null)}function gt(n,e,t,r,i){var s={type:n,props:e,key:t,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:i??++ei,__i:-1,__u:0};return i==null&&p.vnode!=null&&p.vnode(s),s}function me(n){return n.children}function vt(n,e){this.props=n,this.context=e}function _e(n,e){if(e==null)return n.__?_e(n.__,n.__i+1):null;for(var t;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null)return t.__e;return typeof n.type=="function"?_e(n):null}function ii(n){var e,t;if((n=n.__)!=null&&n.__c!=null){for(n.__e=n.__c.base=null,e=0;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null){n.__e=n.__c.base=t.__e;break}return ii(n)}}function Yr(n){(!n.__d&&(n.__d=!0)&&ne.push(n)&&!It.__r++||Jr!==p.debounceRendering)&&((Jr=p.debounceRendering)||ti)(It)}function It(){var n,e,t,r,i,s,o,c,a;for(ne.sort(En);n=ne.shift();)n.__d&&(e=ne.length,r=void 0,s=(i=(t=n).__v).__e,c=[],a=[],(o=t.__P)&&((r=$({},i)).__v=i.__v+1,p.vnode&&p.vnode(r),Tn(o,r,i,t.__n,o.ownerSVGElement!==void 0,32&i.__u?[s]:null,c,s??_e(i),!!(32&i.__u),a),r.__.__k[r.__i]=r,ai(c,r,a),r.__e!=s&&ii(r)),ne.length>e&&ne.sort(En));It.__r=0}function si(n,e,t,r,i,s,o,c,a,l,d){var u,_,h,v,R,I=r&&r.__k||ni,g=e.length;for(t.__d=a,Ua(t,e,I),a=t.__d,u=0;u<g;u++)(h=t.__k[u])!=null&&typeof h!="boolean"&&typeof h!="function"&&(_=h.__i===-1?Ne:I[h.__i]||Ne,h.__i=u,Tn(n,h,_,i,s,o,c,a,l,d),v=h.__e,h.ref&&_.ref!=h.ref&&(_.ref&&An(_.ref,null,h),d.push(h.ref,h.__c||v,h)),R==null&&v!=null&&(R=v),65536&h.__u||_.__k===h.__k?a=oi(h,a,n):typeof h.type=="function"&&h.__d!==void 0?a=h.__d:v&&(a=v.nextSibling),h.__d=void 0,h.__u&=-196609);t.__d=a,t.__e=R}function Ua(n,e,t){var r,i,s,o,c,a=e.length,l=t.length,d=l,u=0;for(n.__k=[],r=0;r<a;r++)(i=n.__k[r]=(i=e[r])==null||typeof i=="boolean"||typeof i=="function"?null:typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?gt(null,i,null,null,i):bn(i)?gt(me,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?gt(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)!=null?(i.__=n,i.__b=n.__b+1,c=Fa(i,t,o=r+u,d),i.__i=c,s=null,c!==-1&&(d--,(s=t[c])&&(s.__u|=131072)),s==null||s.__v===null?(c==-1&&u--,typeof i.type!="function"&&(i.__u|=65536)):c!==o&&(c===o+1?u++:c>o?d>a-o?u+=c-o:u--:u=c<o&&c==o-1?c-o:0,c!==r+u&&(i.__u|=65536))):(s=t[r])&&s.key==null&&s.__e&&(s.__e==n.__d&&(n.__d=_e(s)),wn(s,s,!1),t[r]=null,d--);if(d)for(r=0;r<l;r++)(s=t[r])!=null&&!(131072&s.__u)&&(s.__e==n.__d&&(n.__d=_e(s)),wn(s,s))}function oi(n,e,t){var r,i;if(typeof n.type=="function"){for(r=n.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=n,e=oi(r[i],e,t));return e}return n.__e!=e&&(t.insertBefore(n.__e,e||null),e=n.__e),e&&e.nextSibling}function Fa(n,e,t,r){var i=n.key,s=n.type,o=t-1,c=t+1,a=e[t];if(a===null||a&&i==a.key&&s===a.type)return t;if(r>(a!=null&&!(131072&a.__u)?1:0))for(;o>=0||c<e.length;){if(o>=0){if((a=e[o])&&!(131072&a.__u)&&i==a.key&&s===a.type)return o;o--}if(c<e.length){if((a=e[c])&&!(131072&a.__u)&&i==a.key&&s===a.type)return c;c++}}return-1}function Xr(n,e,t){e[0]==="-"?n.setProperty(e,t??""):n[e]=t==null?"":typeof t!="number"||Ma.test(e)?t:t+"px"}function mt(n,e,t,r,i){var s;e:if(e==="style")if(typeof t=="string")n.style.cssText=t;else{if(typeof r=="string"&&(n.style.cssText=r=""),r)for(e in r)t&&e in t||Xr(n.style,e,"");if(t)for(e in t)r&&t[e]===r[e]||Xr(n.style,e,t[e])}else if(e[0]==="o"&&e[1]==="n")s=e!==(e=e.replace(/(PointerCapture)$|Capture$/,"$1")),e=e.toLowerCase()in n?e.toLowerCase().slice(2):e.slice(2),n.l||(n.l={}),n.l[e+s]=t,t?r?t.u=r.u:(t.u=Date.now(),n.addEventListener(e,s?Zr:Qr,s)):n.removeEventListener(e,s?Zr:Qr,s);else{if(i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!=="width"&&e!=="height"&&e!=="href"&&e!=="list"&&e!=="form"&&e!=="tabIndex"&&e!=="download"&&e!=="rowSpan"&&e!=="colSpan"&&e!=="role"&&e in n)try{n[e]=t??"";break e}catch{}typeof t=="function"||(t==null||t===!1&&e[4]!=="-"?n.removeAttribute(e):n.setAttribute(e,t))}}function Qr(n){var e=this.l[n.type+!1];if(n.t){if(n.t<=e.u)return}else n.t=Date.now();return e(p.event?p.event(n):n)}function Zr(n){return this.l[n.type+!0](p.event?p.event(n):n)}function Tn(n,e,t,r,i,s,o,c,a,l){var d,u,_,h,v,R,I,g,y,k,z,V,re,q,ge,A=e.type;if(e.constructor!==void 0)return null;128&t.__u&&(a=!!(32&t.__u),s=[c=e.__e=t.__e]),(d=p.__b)&&d(e);e:if(typeof A=="function")try{if(g=e.props,y=(d=A.contextType)&&r[d.__c],k=d?y?y.props.value:d.__:r,t.__c?I=(u=e.__c=t.__c).__=u.__E:("prototype"in A&&A.prototype.render?e.__c=u=new A(g,k):(e.__c=u=new vt(g,k),u.constructor=A,u.render=Ha),y&&y.sub(u),u.props=g,u.state||(u.state={}),u.context=k,u.__n=r,_=u.__d=!0,u.__h=[],u._sb=[]),u.__s==null&&(u.__s=u.state),A.getDerivedStateFromProps!=null&&(u.__s==u.state&&(u.__s=$({},u.__s)),$(u.__s,A.getDerivedStateFromProps(g,u.__s))),h=u.props,v=u.state,u.__v=e,_)A.getDerivedStateFromProps==null&&u.componentWillMount!=null&&u.componentWillMount(),u.componentDidMount!=null&&u.__h.push(u.componentDidMount);else{if(A.getDerivedStateFromProps==null&&g!==h&&u.componentWillReceiveProps!=null&&u.componentWillReceiveProps(g,k),!u.__e&&(u.shouldComponentUpdate!=null&&u.shouldComponentUpdate(g,u.__s,k)===!1||e.__v===t.__v)){for(e.__v!==t.__v&&(u.props=g,u.state=u.__s,u.__d=!1),e.__e=t.__e,e.__k=t.__k,e.__k.forEach(function(ie){ie&&(ie.__=e)}),z=0;z<u._sb.length;z++)u.__h.push(u._sb[z]);u._sb=[],u.__h.length&&o.push(u);break e}u.componentWillUpdate!=null&&u.componentWillUpdate(g,u.__s,k),u.componentDidUpdate!=null&&u.__h.push(function(){u.componentDidUpdate(h,v,R)})}if(u.context=k,u.props=g,u.__P=n,u.__e=!1,V=p.__r,re=0,"prototype"in A&&A.prototype.render){for(u.state=u.__s,u.__d=!1,V&&V(e),d=u.render(u.props,u.state,u.context),q=0;q<u._sb.length;q++)u.__h.push(u._sb[q]);u._sb=[]}else do u.__d=!1,V&&V(e),d=u.render(u.props,u.state,u.context),u.state=u.__s;while(u.__d&&++re<25);u.state=u.__s,u.getChildContext!=null&&(r=$($({},r),u.getChildContext())),_||u.getSnapshotBeforeUpdate==null||(R=u.getSnapshotBeforeUpdate(h,v)),si(n,bn(ge=d!=null&&d.type===me&&d.key==null?d.props.children:d)?ge:[ge],e,t,r,i,s,o,c,a,l),u.base=e.__e,e.__u&=-161,u.__h.length&&o.push(u),I&&(u.__E=u.__=null)}catch(ie){e.__v=null,a||s!=null?(e.__e=c,e.__u|=a?160:32,s[s.indexOf(c)]=null):(e.__e=t.__e,e.__k=t.__k),p.__e(ie,e,t)}else s==null&&e.__v===t.__v?(e.__k=t.__k,e.__e=t.__e):e.__e=Va(t.__e,e,t,r,i,s,o,a,l);(d=p.diffed)&&d(e)}function ai(n,e,t){e.__d=void 0;for(var r=0;r<t.length;r++)An(t[r],t[++r],t[++r]);p.__c&&p.__c(e,n),n.some(function(i){try{n=i.__h,i.__h=[],n.some(function(s){s.call(i)})}catch(s){p.__e(s,i.__v)}})}function Va(n,e,t,r,i,s,o,c,a){var l,d,u,_,h,v,R,I=t.props,g=e.props,y=e.type;if(y==="svg"&&(i=!0),s!=null){for(l=0;l<s.length;l++)if((h=s[l])&&"setAttribute"in h==!!y&&(y?h.localName===y:h.nodeType===3)){n=h,s[l]=null;break}}if(n==null){if(y===null)return document.createTextNode(g);n=i?document.createElementNS("http://www.w3.org/2000/svg",y):document.createElement(y,g.is&&g),s=null,c=!1}if(y===null)I===g||c&&n.data===g||(n.data=g);else{if(s=s&&yt.call(n.childNodes),I=t.props||Ne,!c&&s!=null)for(I={},l=0;l<n.attributes.length;l++)I[(h=n.attributes[l]).name]=h.value;for(l in I)h=I[l],l=="children"||(l=="dangerouslySetInnerHTML"?u=h:l==="key"||l in g||mt(n,l,null,h,i));for(l in g)h=g[l],l=="children"?_=h:l=="dangerouslySetInnerHTML"?d=h:l=="value"?v=h:l=="checked"?R=h:l==="key"||c&&typeof h!="function"||I[l]===h||mt(n,l,h,I[l],i);if(d)c||u&&(d.__html===u.__html||d.__html===n.innerHTML)||(n.innerHTML=d.__html),e.__k=[];else if(u&&(n.innerHTML=""),si(n,bn(_)?_:[_],e,t,r,i&&y!=="foreignObject",s,o,s?s[0]:t.__k&&_e(t,0),c,a),s!=null)for(l=s.length;l--;)s[l]!=null&&ri(s[l]);c||(l="value",v!==void 0&&(v!==n[l]||y==="progress"&&!v||y==="option"&&v!==I[l])&&mt(n,l,v,I[l],!1),l="checked",R!==void 0&&R!==n[l]&&mt(n,l,R,I[l],!1))}return n}function An(n,e,t){try{typeof n=="function"?n(e):n.current=e}catch(r){p.__e(r,t)}}function wn(n,e,t){var r,i;if(p.unmount&&p.unmount(n),(r=n.ref)&&(r.current&&r.current!==n.__e||An(r,null,e)),(r=n.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(s){p.__e(s,e)}r.base=r.__P=null,n.__c=void 0}if(r=n.__k)for(i=0;i<r.length;i++)r[i]&&wn(r[i],e,t||typeof n.type!="function");t||n.__e==null||ri(n.__e),n.__=n.__e=n.__d=void 0}function Ha(n,e,t){return this.constructor(n,t)}function ci(n,e,t){var r,i,s,o;p.__&&p.__(n,e),i=(r=typeof t=="function")?null:t&&t.__k||e.__k,s=[],o=[],Tn(e,n=(!r&&t||e).__k=xa(me,null,[n]),i||Ne,Ne,e.ownerSVGElement!==void 0,!r&&t?[t]:i?null:e.firstChild?yt.call(e.childNodes):null,s,!r&&t?t:i?i.__e:e.firstChild,r,o),ai(s,n,o)}yt=ni.slice,p={__e:function(n,e,t,r){for(var i,s,o;e=e.__;)if((i=e.__c)&&!i.__)try{if((s=i.constructor)&&s.getDerivedStateFromError!=null&&(i.setState(s.getDerivedStateFromError(n)),o=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(n,r||{}),o=i.__d),o)return i.__E=i}catch(c){n=c}throw n}},ei=0,Da=function(n){return n!=null&&n.constructor==null},vt.prototype.setState=function(n,e){var t;t=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=$({},this.state),typeof n=="function"&&(n=n($({},t),this.props)),n&&$(t,n),n!=null&&this.__v&&(e&&this._sb.push(e),Yr(this))},vt.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),Yr(this))},vt.prototype.render=me,ne=[],ti=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,En=function(n,e){return n.__v.__b-e.__v.__b},It.__r=0,La=0;var Rn,E,Sn,ui,kn=0,mi=[],Et=[],li=p.__b,di=p.__r,hi=p.diffed,fi=p.__c,pi=p.unmount;function Wa(n,e){p.__h&&p.__h(E,n,kn||e),kn=0;var t=E.__H||(E.__H={__:[],__h:[]});return n>=t.__.length&&t.__.push({__V:Et}),t.__[n]}function gi(n){return kn=1,Ba(vi,n)}function Ba(n,e,t){var r=Wa(Rn++,2);if(r.t=n,!r.__c&&(r.__=[t?t(e):vi(void 0,e),function(c){var a=r.__N?r.__N[0]:r.__[0],l=r.t(a,c);a!==l&&(r.__N=[l,r.__[1]],r.__c.setState({}))}],r.__c=E,!E.u)){var i=function(c,a,l){if(!r.__c.__H)return!0;var d=r.__c.__H.__.filter(function(_){return _.__c});if(d.every(function(_){return!_.__N}))return!s||s.call(this,c,a,l);var u=!1;return d.forEach(function(_){if(_.__N){var h=_.__[0];_.__=_.__N,_.__N=void 0,h!==_.__[0]&&(u=!0)}}),!(!u&&r.__c.props===c)&&(!s||s.call(this,c,a,l))};E.u=!0;var s=E.shouldComponentUpdate,o=E.componentWillUpdate;E.componentWillUpdate=function(c,a,l){if(this.__e){var d=s;s=void 0,i(c,a,l),s=d}o&&o.call(this,c,a,l)},E.shouldComponentUpdate=i}return r.__N||r.__}function ja(){for(var n;n=mi.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(wt),n.__H.__h.forEach(On),n.__H.__h=[]}catch(e){n.__H.__h=[],p.__e(e,n.__v)}}p.__b=function(n){E=null,li&&li(n)},p.__r=function(n){di&&di(n),Rn=0;var e=(E=n.__c).__H;e&&(Sn===E?(e.__h=[],E.__h=[],e.__.forEach(function(t){t.__N&&(t.__=t.__N),t.__V=Et,t.__N=t.i=void 0})):(e.__h.forEach(wt),e.__h.forEach(On),e.__h=[],Rn=0)),Sn=E},p.diffed=function(n){hi&&hi(n);var e=n.__c;e&&e.__H&&(e.__H.__h.length&&(mi.push(e)!==1&&ui===p.requestAnimationFrame||((ui=p.requestAnimationFrame)||$a)(ja)),e.__H.__.forEach(function(t){t.i&&(t.__H=t.i),t.__V!==Et&&(t.__=t.__V),t.i=void 0,t.__V=Et})),Sn=E=null},p.__c=function(n,e){e.some(function(t){try{t.__h.forEach(wt),t.__h=t.__h.filter(function(r){return!r.__||On(r)})}catch(r){e.some(function(i){i.__h&&(i.__h=[])}),e=[],p.__e(r,t.__v)}}),fi&&fi(n,e)},p.unmount=function(n){pi&&pi(n);var e,t=n.__c;t&&t.__H&&(t.__H.__.forEach(function(r){try{wt(r)}catch(i){e=i}}),t.__H=void 0,e&&p.__e(e,t.__v))};var _i=typeof requestAnimationFrame=="function";function $a(n){var e,t=function(){clearTimeout(r),_i&&cancelAnimationFrame(e),setTimeout(n)},r=setTimeout(t,100);_i&&(e=requestAnimationFrame(t))}function wt(n){var e=E,t=n.__c;typeof t=="function"&&(n.__c=void 0,t()),E=e}function On(n){var e=E;n.__c=n.__(),E=e}function vi(n,e){return typeof e=="function"?e(n):e}var za=0,Hu=Array.isArray;function w(n,e,t,r,i,s){var o,c,a={};for(c in e)c=="ref"?o=e[c]:a[c]=e[c];var l={type:n,props:a,key:t,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--za,__i:-1,__u:0,__source:i,__self:s};if(typeof n=="function"&&(o=n.defaultProps))for(c in o)a[c]===void 0&&(a[c]=o[c]);return p.vnode&&p.vnode(l),l}function De(){let[n,e]=gi(""),t=window.__ROOT_CTX.name;function r(i){e(i)}return w("div",{className:"signin",children:[w("div",{className:"signin__headline",children:[t&&w("h1",{className:"signin__headline__title",children:t}),w("p",{className:"signin__headline__body",children:t?`Sign in to continue to ${t}`:"Sign in to continue"})]}),w(De.Button,{onError:r}),n&&w("p",{className:"signin__error",children:n})]})}De.Button=n=>{async function e(r){try{return await r.json()}catch(i){console.error(i)}return{}}async function t(){let r=new Z;r.addScope("profile"),r.addScope("email");let s=(await In(window.firebase.auth,r)).user,o=await s.getIdToken(),c=await fetch("/cms/login",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({idToken:o})}),a=await e(c);if(c.status===401){let l=s?.email||"(no email)";a.reason?n.onError(`Login failed for: ${l}. Reason: ${a.reason}. If you believe this is a mistake, please contact a developer to help resolve the issue.`):n.onError(`Login failed for: ${l}. If you believe this is a mistake, please contact a developer to help resolve the issue.`);return}if(c.status!==200){console.error("login failed"),console.log(c.status,a),n.onError("An unknown error has occurred.");return}if(!a.success){console.error("login failed"),console.log(c.status,a),a.reason?n.onError(`Login failed. Reason: ${a.reason}`):n.onError("Login failed.");return}qa()}return w("button",{className:"signin__button",onClick:t,children:[w("div",{className:"signin__button__icon",children:w(De.GLogo,{})}),w("div",{className:"signin__button__label",children:"Sign in with Google"})]})};De.GLogo=()=>w("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 48 48",children:w("g",{children:[w("path",{fill:"#EA4335",d:"M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"}),w("path",{fill:"#4285F4",d:"M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"}),w("path",{fill:"#FBBC05",d:"M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"}),w("path",{fill:"#34A853",d:"M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"}),w("path",{fill:"none",d:"M0 0h48v48H0z"})]})});function qa(){let e=new URLSearchParams(window.location.search).get("continue");(!e||!e.startsWith("/")||e.startsWith("/cms/login"))&&(e="/cms"),window.location.replace(e)}var Ii=qt(window.__ROOT_CTX.firebaseConfig),Ga=yn(Ii);window.firebase={app:Ii,auth:Ga};var yi=document.getElementById("root");yi.innerHTML="";ci(w(De,{}),yi);})();
1
+ "use strict";(()=>{var Yn=()=>{};var Zn=function(t){let e=[],n=0;for(let r=0;r<t.length;r++){let i=t.charCodeAt(r);i<128?e[n++]=i:i<2048?(e[n++]=i>>6|192,e[n++]=i&63|128):(i&64512)===55296&&r+1<t.length&&(t.charCodeAt(r+1)&64512)===56320?(i=65536+((i&1023)<<10)+(t.charCodeAt(++r)&1023),e[n++]=i>>18|240,e[n++]=i>>12&63|128,e[n++]=i>>6&63|128,e[n++]=i&63|128):(e[n++]=i>>12|224,e[n++]=i>>6&63|128,e[n++]=i&63|128)}return e},ts=function(t){let e=[],n=0,r=0;for(;n<t.length;){let i=t[n++];if(i<128)e[r++]=String.fromCharCode(i);else if(i>191&&i<224){let s=t[n++];e[r++]=String.fromCharCode((i&31)<<6|s&63)}else if(i>239&&i<365){let s=t[n++],o=t[n++],a=t[n++],u=((i&7)<<18|(s&63)<<12|(o&63)<<6|a&63)-65536;e[r++]=String.fromCharCode(55296+(u>>10)),e[r++]=String.fromCharCode(56320+(u&1023))}else{let s=t[n++],o=t[n++];e[r++]=String.fromCharCode((i&15)<<12|(s&63)<<6|o&63)}}return e.join("")},er={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_();let n=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,r=[];for(let i=0;i<t.length;i+=3){let s=t[i],o=i+1<t.length,a=o?t[i+1]:0,u=i+2<t.length,c=u?t[i+2]:0,h=s>>2,l=(s&3)<<4|a>>4,d=(a&15)<<2|c>>6,f=c&63;u||(f=64,o||(d=64)),r.push(n[h],n[l],n[d],n[f])}return r.join("")},encodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(t):this.encodeByteArray(Zn(t),e)},decodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(t):ts(this.decodeStringToByteArray(t,e))},decodeStringToByteArray(t,e){this.init_();let n=e?this.charToByteMapWebSafe_:this.charToByteMap_,r=[];for(let i=0;i<t.length;){let s=n[t.charAt(i++)],a=i<t.length?n[t.charAt(i)]:0;++i;let c=i<t.length?n[t.charAt(i)]:64;++i;let l=i<t.length?n[t.charAt(i)]:64;if(++i,s==null||a==null||c==null||l==null)throw new xt;let d=s<<2|a>>4;if(r.push(d),c!==64){let f=a<<4&240|c>>2;if(r.push(f),l!==64){let g=c<<6&192|l;r.push(g)}}}return r},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)}}},xt=class extends Error{constructor(){super(...arguments),this.name="DecodeBase64StringError"}},ns=function(t){let e=Zn(t);return er.encodeByteArray(e,!0)},Vt=function(t){return ns(t).replace(/\./g,"")},je=function(t){try{return er.decodeString(t,!0)}catch(e){console.error("base64Decode failed: ",e)}return null};function rs(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("Unable to locate global object.")}var is=()=>rs().__FIREBASE_DEFAULTS__,ss=()=>{if(typeof process>"u"||typeof process.env>"u")return;let t=process.env.__FIREBASE_DEFAULTS__;if(t)return JSON.parse(t)},os=()=>{if(typeof document>"u")return;let t;try{t=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}let e=t&&je(t[1]);return e&&JSON.parse(e)},Ht=()=>{try{return Yn()||is()||ss()||os()}catch(t){console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${t}`);return}},tr=t=>Ht()?.emulatorHosts?.[t];var Wt=()=>Ht()?.config,Bt=t=>Ht()?.[`_${t}`];var ze=class{constructor(){this.reject=()=>{},this.resolve=()=>{},this.promise=new Promise((e,n)=>{this.resolve=e,this.reject=n})}wrapCallback(e){return(n,r)=>{n?this.reject(n):this.resolve(r),typeof e=="function"&&(this.promise.catch(()=>{}),e.length===1?e(n):e(n,r))}}};function ve(t){try{return(t.startsWith("http://")||t.startsWith("https://")?new URL(t).hostname:t).endsWith(".cloudworkstations.dev")}catch{return!1}}async function nr(t){return(await fetch(t,{credentials:"include"})).ok}var ye={};function as(){let t={prod:[],emulator:[]};for(let e of Object.keys(ye))ye[e]?t.emulator.push(e):t.prod.push(e);return t}function cs(t){let e=document.getElementById(t),n=!1;return e||(e=document.createElement("div"),e.setAttribute("id",t),n=!0),{created:n,element:e}}var Xn=!1;function rr(t,e){if(typeof window>"u"||typeof document>"u"||!ve(window.location.host)||ye[t]===e||ye[t]||Xn)return;ye[t]=e;function n(d){return`__firebase__banner__${d}`}let r="__firebase__banner",s=as().prod.length>0;function o(){let d=document.getElementById(r);d&&d.remove()}function a(d){d.style.display="flex",d.style.background="#7faaf0",d.style.position="fixed",d.style.bottom="5px",d.style.left="5px",d.style.padding=".5em",d.style.borderRadius="5px",d.style.alignItems="center"}function u(d,f){d.setAttribute("width","24"),d.setAttribute("id",f),d.setAttribute("height","24"),d.setAttribute("viewBox","0 0 24 24"),d.setAttribute("fill","none"),d.style.marginLeft="-6px"}function c(){let d=document.createElement("span");return d.style.cursor="pointer",d.style.marginLeft="16px",d.style.fontSize="24px",d.innerHTML=" &times;",d.onclick=()=>{Xn=!0,o()},d}function h(d,f){d.setAttribute("id",f),d.innerText="Learn more",d.href="https://firebase.google.com/docs/studio/preview-apps#preview-backend",d.setAttribute("target","__blank"),d.style.paddingLeft="5px",d.style.textDecoration="underline"}function l(){let d=cs(r),f=n("text"),g=document.getElementById(f)||document.createElement("span"),A=n("learnmore"),y=document.getElementById(A)||document.createElement("a"),_=n("preprendIcon"),m=document.getElementById(_)||document.createElementNS("http://www.w3.org/2000/svg","svg");if(d.created){let C=d.element;a(C),h(y,A);let D=c();u(m,_),C.append(m,g,y,D),document.body.appendChild(C)}s?(g.innerText="Preview backend disconnected.",m.innerHTML=`<g clip-path="url(#clip0_6013_33858)">
2
+ <path d="M4.8 17.6L12 5.6L19.2 17.6H4.8ZM6.91667 16.4H17.0833L12 7.93333L6.91667 16.4ZM12 15.6C12.1667 15.6 12.3056 15.5444 12.4167 15.4333C12.5389 15.3111 12.6 15.1667 12.6 15C12.6 14.8333 12.5389 14.6944 12.4167 14.5833C12.3056 14.4611 12.1667 14.4 12 14.4C11.8333 14.4 11.6889 14.4611 11.5667 14.5833C11.4556 14.6944 11.4 14.8333 11.4 15C11.4 15.1667 11.4556 15.3111 11.5667 15.4333C11.6889 15.5444 11.8333 15.6 12 15.6ZM11.4 13.6H12.6V10.4H11.4V13.6Z" fill="#212121"/>
3
+ </g>
4
+ <defs>
5
+ <clipPath id="clip0_6013_33858">
6
+ <rect width="24" height="24" fill="white"/>
7
+ </clipPath>
8
+ </defs>`):(m.innerHTML=`<g clip-path="url(#clip0_6083_34804)">
9
+ <path d="M11.4 15.2H12.6V11.2H11.4V15.2ZM12 10C12.1667 10 12.3056 9.94444 12.4167 9.83333C12.5389 9.71111 12.6 9.56667 12.6 9.4C12.6 9.23333 12.5389 9.09444 12.4167 8.98333C12.3056 8.86111 12.1667 8.8 12 8.8C11.8333 8.8 11.6889 8.86111 11.5667 8.98333C11.4556 9.09444 11.4 9.23333 11.4 9.4C11.4 9.56667 11.4556 9.71111 11.5667 9.83333C11.6889 9.94444 11.8333 10 12 10ZM12 18.4C11.1222 18.4 10.2944 18.2333 9.51667 17.9C8.73889 17.5667 8.05556 17.1111 7.46667 16.5333C6.88889 15.9444 6.43333 15.2611 6.1 14.4833C5.76667 13.7056 5.6 12.8778 5.6 12C5.6 11.1111 5.76667 10.2833 6.1 9.51667C6.43333 8.73889 6.88889 8.06111 7.46667 7.48333C8.05556 6.89444 8.73889 6.43333 9.51667 6.1C10.2944 5.76667 11.1222 5.6 12 5.6C12.8889 5.6 13.7167 5.76667 14.4833 6.1C15.2611 6.43333 15.9389 6.89444 16.5167 7.48333C17.1056 8.06111 17.5667 8.73889 17.9 9.51667C18.2333 10.2833 18.4 11.1111 18.4 12C18.4 12.8778 18.2333 13.7056 17.9 14.4833C17.5667 15.2611 17.1056 15.9444 16.5167 16.5333C15.9389 17.1111 15.2611 17.5667 14.4833 17.9C13.7167 18.2333 12.8889 18.4 12 18.4ZM12 17.2C13.4444 17.2 14.6722 16.6944 15.6833 15.6833C16.6944 14.6722 17.2 13.4444 17.2 12C17.2 10.5556 16.6944 9.32778 15.6833 8.31667C14.6722 7.30555 13.4444 6.8 12 6.8C10.5556 6.8 9.32778 7.30555 8.31667 8.31667C7.30556 9.32778 6.8 10.5556 6.8 12C6.8 13.4444 7.30556 14.6722 8.31667 15.6833C9.32778 16.6944 10.5556 17.2 12 17.2Z" fill="#212121"/>
10
+ </g>
11
+ <defs>
12
+ <clipPath id="clip0_6083_34804">
13
+ <rect width="24" height="24" fill="white"/>
14
+ </clipPath>
15
+ </defs>`,g.innerText="Preview backend running in this workspace."),g.setAttribute("id",f)}document.readyState==="loading"?window.addEventListener("DOMContentLoaded",l):l()}function S(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function ir(){return typeof window<"u"&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(S())}function sr(){return typeof navigator<"u"&&navigator.userAgent==="Cloudflare-Workers"}function or(){let t=typeof chrome=="object"?chrome.runtime:typeof browser=="object"?browser.runtime:void 0;return typeof t=="object"&&t.id!==void 0}function ar(){return typeof navigator=="object"&&navigator.product==="ReactNative"}function cr(){let t=S();return t.indexOf("MSIE ")>=0||t.indexOf("Trident/")>=0}function ur(){try{return typeof indexedDB=="object"}catch{return!1}}function lr(){return new Promise((t,e)=>{try{let n=!0,r="validate-browser-context-for-indexeddb-analytics-module",i=self.indexedDB.open(r);i.onsuccess=()=>{i.result.close(),n||self.indexedDB.deleteDatabase(r),t(!0)},i.onupgradeneeded=()=>{n=!1},i.onerror=()=>{e(i.error?.message||"")}}catch(n){e(n)}})}var us="FirebaseError",P=class t extends Error{constructor(e,n,r){super(n),this.code=e,this.customData=r,this.name=us,Object.setPrototypeOf(this,t.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,V.prototype.create)}},V=class{constructor(e,n,r){this.service=e,this.serviceName=n,this.errors=r}create(e,...n){let r=n[0]||{},i=`${this.service}/${e}`,s=this.errors[e],o=s?ls(s,r):"Error",a=`${this.serviceName}: ${o} (${i}).`;return new P(i,a,r)}};function ls(t,e){return t.replace(ds,(n,r)=>{let i=e[r];return i!=null?String(i):`<${r}?>`})}var ds=/\{\$([^}]+)}/g;function dr(t){for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}function z(t,e){if(t===e)return!0;let n=Object.keys(t),r=Object.keys(e);for(let i of n){if(!r.includes(i))return!1;let s=t[i],o=e[i];if(Qn(s)&&Qn(o)){if(!z(s,o))return!1}else if(s!==o)return!1}for(let i of r)if(!n.includes(i))return!1;return!0}function Qn(t){return t!==null&&typeof t=="object"}function ce(t){let e=[];for(let[n,r]of Object.entries(t))Array.isArray(r)?r.forEach(i=>{e.push(encodeURIComponent(n)+"="+encodeURIComponent(i))}):e.push(encodeURIComponent(n)+"="+encodeURIComponent(r));return e.length?"&"+e.join("&"):""}function ue(t){let e={};return t.replace(/^\?/,"").split("&").forEach(r=>{if(r){let[i,s]=r.split("=");e[decodeURIComponent(i)]=decodeURIComponent(s)}}),e}function le(t){let e=t.indexOf("?");if(!e)return"";let n=t.indexOf("#",e);return t.substring(e,n>0?n:void 0)}function hr(t,e){let n=new Ft(t,e);return n.subscribe.bind(n)}var Ft=class{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(r=>{this.error(r)})}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,r){let i;if(e===void 0&&n===void 0&&r===void 0)throw new Error("Missing Observer.");hs(e,["next","error","complete"])?i=e:i={next:e,error:n,complete:r},i.next===void 0&&(i.next=Ut),i.error===void 0&&(i.error=Ut),i.complete===void 0&&(i.complete=Ut);let s=this.unsubscribeOne.bind(this,this.observers.length);return this.finalized&&this.task.then(()=>{try{this.finalError?i.error(this.finalError):i.complete()}catch{}}),this.observers.push(i),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(r){typeof console<"u"&&console.error&&console.error(r)}})}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 hs(t,e){if(typeof t!="object"||t===null)return!1;for(let n of e)if(n in t&&typeof t[n]=="function")return!0;return!1}function Ut(){}var Rc=4*60*60*1e3;function j(t){return t&&t._delegate?t._delegate:t}var M=class{constructor(e,n,r){this.name=e,this.instanceFactory=n,this.type=r,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}setInstantiationMode(e){return this.instantiationMode=e,this}setMultipleInstances(e){return this.multipleInstances=e,this}setServiceProps(e){return this.serviceProps=e,this}setInstanceCreatedCallback(e){return this.onInstanceCreated=e,this}};var Y="[DEFAULT]";var $t=class{constructor(e,n){this.name=e,this.container=n,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}get(e){let n=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(n)){let r=new ze;if(this.instancesDeferred.set(n,r),this.isInitialized(n)||this.shouldAutoInitialize())try{let i=this.getOrInitializeService({instanceIdentifier:n});i&&r.resolve(i)}catch{}}return this.instancesDeferred.get(n).promise}getImmediate(e){let n=this.normalizeInstanceIdentifier(e?.identifier),r=e?.optional??!1;if(this.isInitialized(n)||this.shouldAutoInitialize())try{return this.getOrInitializeService({instanceIdentifier:n})}catch(i){if(r)return null;throw i}else{if(r)return null;throw Error(`Service ${this.name} is not available`)}}getComponent(){return this.component}setComponent(e){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,!!this.shouldAutoInitialize()){if(ps(e))try{this.getOrInitializeService({instanceIdentifier:Y})}catch{}for(let[n,r]of this.instancesDeferred.entries()){let i=this.normalizeInstanceIdentifier(n);try{let s=this.getOrInitializeService({instanceIdentifier:i});r.resolve(s)}catch{}}}}clearInstance(e=Y){this.instancesDeferred.delete(e),this.instancesOptions.delete(e),this.instances.delete(e)}async delete(){let e=Array.from(this.instances.values());await Promise.all([...e.filter(n=>"INTERNAL"in n).map(n=>n.INTERNAL.delete()),...e.filter(n=>"_delete"in n).map(n=>n._delete())])}isComponentSet(){return this.component!=null}isInitialized(e=Y){return this.instances.has(e)}getOptions(e=Y){return this.instancesOptions.get(e)||{}}initialize(e={}){let{options:n={}}=e,r=this.normalizeInstanceIdentifier(e.instanceIdentifier);if(this.isInitialized(r))throw Error(`${this.name}(${r}) has already been initialized`);if(!this.isComponentSet())throw Error(`Component ${this.name} has not been registered yet`);let i=this.getOrInitializeService({instanceIdentifier:r,options:n});for(let[s,o]of this.instancesDeferred.entries()){let a=this.normalizeInstanceIdentifier(s);r===a&&o.resolve(i)}return i}onInit(e,n){let r=this.normalizeInstanceIdentifier(n),i=this.onInitCallbacks.get(r)??new Set;i.add(e),this.onInitCallbacks.set(r,i);let s=this.instances.get(r);return s&&e(s,r),()=>{i.delete(e)}}invokeOnInitCallbacks(e,n){let r=this.onInitCallbacks.get(n);if(r)for(let i of r)try{i(e,n)}catch{}}getOrInitializeService({instanceIdentifier:e,options:n={}}){let r=this.instances.get(e);if(!r&&this.component&&(r=this.component.instanceFactory(this.container,{instanceIdentifier:fs(e),options:n}),this.instances.set(e,r),this.instancesOptions.set(e,n),this.invokeOnInitCallbacks(r,e),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,e,r)}catch{}return r||null}normalizeInstanceIdentifier(e=Y){return this.component?this.component.multipleInstances?e:Y:e}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}};function fs(t){return t===Y?void 0:t}function ps(t){return t.instantiationMode==="EAGER"}var qe=class{constructor(e){this.name=e,this.providers=new Map}addComponent(e){let n=this.getProvider(e.name);if(n.isComponentSet())throw new Error(`Component ${e.name} has already been registered with ${this.name}`);n.setComponent(e)}addOrOverwriteComponent(e){this.getProvider(e.name).isComponentSet()&&this.providers.delete(e.name),this.addComponent(e)}getProvider(e){if(this.providers.has(e))return this.providers.get(e);let n=new $t(e,this);return this.providers.set(e,n),n}getProviders(){return Array.from(this.providers.values())}};var _s=[],E;(function(t){t[t.DEBUG=0]="DEBUG",t[t.VERBOSE=1]="VERBOSE",t[t.INFO=2]="INFO",t[t.WARN=3]="WARN",t[t.ERROR=4]="ERROR",t[t.SILENT=5]="SILENT"})(E||(E={}));var ms={debug:E.DEBUG,verbose:E.VERBOSE,info:E.INFO,warn:E.WARN,error:E.ERROR,silent:E.SILENT},gs=E.INFO,Is={[E.DEBUG]:"log",[E.VERBOSE]:"log",[E.INFO]:"info",[E.WARN]:"warn",[E.ERROR]:"error"},Es=(t,e,...n)=>{if(e<t.logLevel)return;let r=new Date().toISOString(),i=Is[e];if(i)console[i](`[${r}] ${t.name}:`,...n);else throw new Error(`Attempted to log a message with an invalid logType (value: ${e})`)},de=class{constructor(e){this.name=e,this._logLevel=gs,this._logHandler=Es,this._userLogHandler=null,_s.push(this)}get logLevel(){return this._logLevel}set logLevel(e){if(!(e in E))throw new TypeError(`Invalid value "${e}" assigned to \`logLevel\``);this._logLevel=e}setLogLevel(e){this._logLevel=typeof e=="string"?ms[e]:e}get logHandler(){return this._logHandler}set logHandler(e){if(typeof e!="function")throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=e}get userLogHandler(){return this._userLogHandler}set userLogHandler(e){this._userLogHandler=e}debug(...e){this._userLogHandler&&this._userLogHandler(this,E.DEBUG,...e),this._logHandler(this,E.DEBUG,...e)}log(...e){this._userLogHandler&&this._userLogHandler(this,E.VERBOSE,...e),this._logHandler(this,E.VERBOSE,...e)}info(...e){this._userLogHandler&&this._userLogHandler(this,E.INFO,...e),this._logHandler(this,E.INFO,...e)}warn(...e){this._userLogHandler&&this._userLogHandler(this,E.WARN,...e),this._logHandler(this,E.WARN,...e)}error(...e){this._userLogHandler&&this._userLogHandler(this,E.ERROR,...e),this._logHandler(this,E.ERROR,...e)}};var ys=(t,e)=>e.some(n=>t instanceof n),fr,pr;function vs(){return fr||(fr=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function ws(){return pr||(pr=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}var _r=new WeakMap,jt=new WeakMap,mr=new WeakMap,zt=new WeakMap,Gt=new WeakMap;function Ts(t){let e=new Promise((n,r)=>{let i=()=>{t.removeEventListener("success",s),t.removeEventListener("error",o)},s=()=>{n(U(t.result)),i()},o=()=>{r(t.error),i()};t.addEventListener("success",s),t.addEventListener("error",o)});return e.then(n=>{n instanceof IDBCursor&&_r.set(n,t)}).catch(()=>{}),Gt.set(e,t),e}function bs(t){if(jt.has(t))return;let e=new Promise((n,r)=>{let i=()=>{t.removeEventListener("complete",s),t.removeEventListener("error",o),t.removeEventListener("abort",o)},s=()=>{n(),i()},o=()=>{r(t.error||new DOMException("AbortError","AbortError")),i()};t.addEventListener("complete",s),t.addEventListener("error",o),t.addEventListener("abort",o)});jt.set(t,e)}var qt={get(t,e,n){if(t instanceof IDBTransaction){if(e==="done")return jt.get(t);if(e==="objectStoreNames")return t.objectStoreNames||mr.get(t);if(e==="store")return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return U(t[e])},set(t,e,n){return t[e]=n,!0},has(t,e){return t instanceof IDBTransaction&&(e==="done"||e==="store")?!0:e in t}};function gr(t){qt=t(qt)}function As(t){return t===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(e,...n){let r=t.call(Ge(this),e,...n);return mr.set(r,e.sort?e.sort():[e]),U(r)}:ws().includes(t)?function(...e){return t.apply(Ge(this),e),U(_r.get(this))}:function(...e){return U(t.apply(Ge(this),e))}}function Ss(t){return typeof t=="function"?As(t):(t instanceof IDBTransaction&&bs(t),ys(t,vs())?new Proxy(t,qt):t)}function U(t){if(t instanceof IDBRequest)return Ts(t);if(zt.has(t))return zt.get(t);let e=Ss(t);return e!==t&&(zt.set(t,e),Gt.set(e,t)),e}var Ge=t=>Gt.get(t);function Er(t,e,{blocked:n,upgrade:r,blocking:i,terminated:s}={}){let o=indexedDB.open(t,e),a=U(o);return r&&o.addEventListener("upgradeneeded",u=>{r(U(o.result),u.oldVersion,u.newVersion,U(o.transaction),u)}),n&&o.addEventListener("blocked",u=>n(u.oldVersion,u.newVersion,u)),a.then(u=>{s&&u.addEventListener("close",()=>s()),i&&u.addEventListener("versionchange",c=>i(c.oldVersion,c.newVersion,c))}).catch(()=>{}),a}var ks=["get","getKey","getAll","getAllKeys","count"],Cs=["put","add","delete","clear"],Kt=new Map;function Ir(t,e){if(!(t instanceof IDBDatabase&&!(e in t)&&typeof e=="string"))return;if(Kt.get(e))return Kt.get(e);let n=e.replace(/FromIndex$/,""),r=e!==n,i=Cs.includes(n);if(!(n in(r?IDBIndex:IDBObjectStore).prototype)||!(i||ks.includes(n)))return;let s=async function(o,...a){let u=this.transaction(o,i?"readwrite":"readonly"),c=u.store;return r&&(c=c.index(a.shift())),(await Promise.all([c[n](...a),i&&u.done]))[0]};return Kt.set(e,s),s}gr(t=>({...t,get:(e,n,r)=>Ir(e,n)||t.get(e,n,r),has:(e,n)=>!!Ir(e,n)||t.has(e,n)}));var Yt=class{constructor(e){this.container=e}getPlatformInfoString(){return this.container.getProviders().map(n=>{if(Rs(n)){let r=n.getImmediate();return`${r.library}/${r.version}`}else return null}).filter(n=>n).join(" ")}};function Rs(t){return t.getComponent()?.type==="VERSION"}var Xt="@firebase/app",yr="0.14.2";var H=new de("@firebase/app"),Ps="@firebase/app-compat",Ns="@firebase/analytics-compat",Os="@firebase/analytics",Ds="@firebase/app-check-compat",Ls="@firebase/app-check",Ms="@firebase/auth",Us="@firebase/auth-compat",xs="@firebase/database",Fs="@firebase/data-connect",Vs="@firebase/database-compat",Hs="@firebase/functions",Ws="@firebase/functions-compat",Bs="@firebase/installations",$s="@firebase/installations-compat",zs="@firebase/messaging",js="@firebase/messaging-compat",qs="@firebase/performance",Gs="@firebase/performance-compat",Ks="@firebase/remote-config",Js="@firebase/remote-config-compat",Ys="@firebase/storage",Xs="@firebase/storage-compat",Qs="@firebase/firestore",Zs="@firebase/ai",eo="@firebase/firestore-compat",to="firebase",no="12.2.0";var Qt="[DEFAULT]",ro={[Xt]:"fire-core",[Ps]:"fire-core-compat",[Os]:"fire-analytics",[Ns]:"fire-analytics-compat",[Ls]:"fire-app-check",[Ds]:"fire-app-check-compat",[Ms]:"fire-auth",[Us]:"fire-auth-compat",[xs]:"fire-rtdb",[Fs]:"fire-data-connect",[Vs]:"fire-rtdb-compat",[Hs]:"fire-fn",[Ws]:"fire-fn-compat",[Bs]:"fire-iid",[$s]:"fire-iid-compat",[zs]:"fire-fcm",[js]:"fire-fcm-compat",[qs]:"fire-perf",[Gs]:"fire-perf-compat",[Ks]:"fire-rc",[Js]:"fire-rc-compat",[Ys]:"fire-gcs",[Xs]:"fire-gcs-compat",[Qs]:"fire-fst",[eo]:"fire-fst-compat",[Zs]:"fire-vertex","fire-js":"fire-js",[to]:"fire-js-all"};var Ke=new Map,io=new Map,Zt=new Map;function vr(t,e){try{t.container.addComponent(e)}catch(n){H.debug(`Component ${e.name} failed to register with FirebaseApp ${t.name}`,n)}}function he(t){let e=t.name;if(Zt.has(e))return H.debug(`There were multiple attempts to register component ${e}.`),!1;Zt.set(e,t);for(let n of Ke.values())vr(n,t);for(let n of io.values())vr(n,t);return!0}function rn(t,e){let n=t.container.getProvider("heartbeat").getImmediate({optional:!0});return n&&n.triggerHeartbeat(),t.container.getProvider(e)}function N(t){return t==null?!1:t.settings!==void 0}var so={"no-app":"No Firebase App '{$appName}' has been created - call initializeApp() first","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","server-app-deleted":"Firebase Server App has been deleted","no-options":"Need to provide options, when not being deployed to hosting via source.","invalid-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}.","finalization-registry-not-supported":"FirebaseServerApp deleteOnDeref field defined but the JS runtime does not support FinalizationRegistry.","invalid-server-app-environment":"FirebaseServerApp is not for use in browser environments."},q=new V("app","Firebase",so);var en=class{constructor(e,n,r){this._isDeleted=!1,this._options={...e},this._config={...n},this._name=n.name,this._automaticDataCollectionEnabled=n.automaticDataCollectionEnabled,this._container=r,this.container.addComponent(new M("app",()=>this,"PUBLIC"))}get automaticDataCollectionEnabled(){return this.checkDestroyed(),this._automaticDataCollectionEnabled}set automaticDataCollectionEnabled(e){this.checkDestroyed(),this._automaticDataCollectionEnabled=e}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(e){this._isDeleted=e}checkDestroyed(){if(this.isDeleted)throw q.create("app-deleted",{appName:this._name})}};var fe=no;function sn(t,e={}){let n=t;typeof e!="object"&&(e={name:e});let r={name:Qt,automaticDataCollectionEnabled:!0,...e},i=r.name;if(typeof i!="string"||!i)throw q.create("bad-app-name",{appName:String(i)});if(n||(n=Wt()),!n)throw q.create("no-options");let s=Ke.get(i);if(s){if(z(n,s.options)&&z(r,s.config))return s;throw q.create("duplicate-app",{appName:i})}let o=new qe(i);for(let u of Zt.values())o.addComponent(u);let a=new en(n,r,o);return Ke.set(i,a),a}function Ar(t=Qt){let e=Ke.get(t);if(!e&&t===Qt&&Wt())return sn();if(!e)throw q.create("no-app",{appName:t});return e}function G(t,e,n){let r=ro[t]??t;n&&(r+=`-${n}`);let i=r.match(/\s|\//),s=e.match(/\s|\//);if(i||s){let o=[`Unable to register library "${r}" with version "${e}":`];i&&o.push(`library name "${r}" contains illegal characters (whitespace or "/")`),i&&s&&o.push("and"),s&&o.push(`version name "${e}" contains illegal characters (whitespace or "/")`),H.warn(o.join(" "));return}he(new M(`${r}-version`,()=>({library:r,version:e}),"VERSION"))}var oo="firebase-heartbeat-database",ao=1,we="firebase-heartbeat-store",Jt=null;function Sr(){return Jt||(Jt=Er(oo,ao,{upgrade:(t,e)=>{switch(e){case 0:try{t.createObjectStore(we)}catch(n){console.warn(n)}}}}).catch(t=>{throw q.create("idb-open",{originalErrorMessage:t.message})})),Jt}async function co(t){try{let n=(await Sr()).transaction(we),r=await n.objectStore(we).get(kr(t));return await n.done,r}catch(e){if(e instanceof P)H.warn(e.message);else{let n=q.create("idb-get",{originalErrorMessage:e?.message});H.warn(n.message)}}}async function wr(t,e){try{let r=(await Sr()).transaction(we,"readwrite");await r.objectStore(we).put(e,kr(t)),await r.done}catch(n){if(n instanceof P)H.warn(n.message);else{let r=q.create("idb-set",{originalErrorMessage:n?.message});H.warn(r.message)}}}function kr(t){return`${t.name}!${t.options.appId}`}var uo=1024,lo=30,tn=class{constructor(e){this.container=e,this._heartbeatsCache=null;let n=this.container.getProvider("app").getImmediate();this._storage=new nn(n),this._heartbeatsCachePromise=this._storage.read().then(r=>(this._heartbeatsCache=r,r))}async triggerHeartbeat(){try{let n=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),r=Tr();if(this._heartbeatsCache?.heartbeats==null&&(this._heartbeatsCache=await this._heartbeatsCachePromise,this._heartbeatsCache?.heartbeats==null)||this._heartbeatsCache.lastSentHeartbeatDate===r||this._heartbeatsCache.heartbeats.some(i=>i.date===r))return;if(this._heartbeatsCache.heartbeats.push({date:r,agent:n}),this._heartbeatsCache.heartbeats.length>lo){let i=fo(this._heartbeatsCache.heartbeats);this._heartbeatsCache.heartbeats.splice(i,1)}return this._storage.overwrite(this._heartbeatsCache)}catch(e){H.warn(e)}}async getHeartbeatsHeader(){try{if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,this._heartbeatsCache?.heartbeats==null||this._heartbeatsCache.heartbeats.length===0)return"";let e=Tr(),{heartbeatsToSend:n,unsentEntries:r}=ho(this._heartbeatsCache.heartbeats),i=Vt(JSON.stringify({version:2,heartbeats:n}));return this._heartbeatsCache.lastSentHeartbeatDate=e,r.length>0?(this._heartbeatsCache.heartbeats=r,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),i}catch(e){return H.warn(e),""}}};function Tr(){return new Date().toISOString().substring(0,10)}function ho(t,e=uo){let n=[],r=t.slice();for(let i of t){let s=n.find(o=>o.agent===i.agent);if(s){if(s.dates.push(i.date),br(n)>e){s.dates.pop();break}}else if(n.push({agent:i.agent,dates:[i.date]}),br(n)>e){n.pop();break}r=r.slice(1)}return{heartbeatsToSend:n,unsentEntries:r}}var nn=class{constructor(e){this.app=e,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return ur()?lr().then(()=>!0).catch(()=>!1):!1}async read(){if(await this._canUseIndexedDBPromise){let n=await co(this.app);return n?.heartbeats?n:{heartbeats:[]}}else return{heartbeats:[]}}async overwrite(e){if(await this._canUseIndexedDBPromise){let r=await this.read();return wr(this.app,{lastSentHeartbeatDate:e.lastSentHeartbeatDate??r.lastSentHeartbeatDate,heartbeats:e.heartbeats})}else return}async add(e){if(await this._canUseIndexedDBPromise){let r=await this.read();return wr(this.app,{lastSentHeartbeatDate:e.lastSentHeartbeatDate??r.lastSentHeartbeatDate,heartbeats:[...r.heartbeats,...e.heartbeats]})}else return}};function br(t){return Vt(JSON.stringify({version:2,heartbeats:t})).length}function fo(t){if(t.length===0)return-1;let e=0,n=t[0].date;for(let r=1;r<t.length;r++)t[r].date<n&&(n=t[r].date,e=r);return e}function po(t){he(new M("platform-logger",e=>new Yt(e),"PRIVATE")),he(new M("heartbeat",e=>new tn(e),"PRIVATE")),G(Xt,yr,t),G(Xt,yr,"esm2020"),G("fire-js","")}po("");var _o="firebase",mo="12.2.1";G(_o,mo,"app");function qr(){return{"dependent-sdk-initialized-before-auth":"Another Firebase SDK was initialized and is trying to use Auth before Auth is initialized. Please be sure to call `initializeAuth` or `getAuth` before starting any other Firebase SDK."}}var Gr=qr,Kr=new V("auth","Firebase",qr());var tt=new de("@firebase/auth");function go(t,...e){tt.logLevel<=E.WARN&&tt.warn(`Auth (${fe}): ${t}`,...e)}function Ye(t,...e){tt.logLevel<=E.ERROR&&tt.error(`Auth (${fe}): ${t}`,...e)}function R(t,...e){throw Pn(t,...e)}function O(t,...e){return Pn(t,...e)}function Rn(t,e,n){let r={...Gr(),[e]:n};return new V("auth","Firebase",r).create(e,{appName:t.name})}function X(t){return Rn(t,"operation-not-supported-in-this-environment","Operations that alter the current user are not supported in conjunction with FirebaseServerApp")}function Io(t,e,n){let r=n;if(!(e instanceof r))throw r.name!==e.constructor.name&&R(t,"argument-error"),Rn(t,"argument-error",`Type of ${e.constructor.name} does not match expected instance.Did you pass a reference from a different Auth SDK?`)}function Pn(t,...e){if(typeof t!="string"){let n=e[0],r=[...e.slice(1)];return r[0]&&(r[0].appName=t.name),t._errorFactory.create(n,...r)}return Kr.create(t,...e)}function p(t,e,...n){if(!t)throw Pn(e,...n)}function x(t){let e="INTERNAL ASSERTION FAILED: "+t;throw Ye(e),new Error(e)}function B(t,e){t||x(e)}function dn(){return typeof self<"u"&&self.location?.href||""}function Eo(){return Cr()==="http:"||Cr()==="https:"}function Cr(){return typeof self<"u"&&self.location?.protocol||null}function yo(){return typeof navigator<"u"&&navigator&&"onLine"in navigator&&typeof navigator.onLine=="boolean"&&(Eo()||or()||"connection"in navigator)?navigator.onLine:!0}function vo(){if(typeof navigator>"u")return null;let t=navigator;return t.languages&&t.languages[0]||t.language||null}var Q=class{constructor(e,n){this.shortDelay=e,this.longDelay=n,B(n>e,"Short delay should be less than long delay!"),this.isMobile=ir()||ar()}get(){return yo()?this.isMobile?this.longDelay:this.shortDelay:Math.min(5e3,this.shortDelay)}};function Nn(t,e){B(t.emulator,"Emulator should always be set here");let{url:n}=t.emulator;return e?`${n}${e.startsWith("/")?e.slice(1):e}`:n}var nt=class{static initialize(e,n,r){this.fetchImpl=e,n&&(this.headersImpl=n),r&&(this.responseImpl=r)}static fetch(){if(this.fetchImpl)return this.fetchImpl;if(typeof self<"u"&&"fetch"in self)return self.fetch;if(typeof globalThis<"u"&&globalThis.fetch)return globalThis.fetch;if(typeof fetch<"u")return fetch;x("Could not find fetch implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static headers(){if(this.headersImpl)return this.headersImpl;if(typeof self<"u"&&"Headers"in self)return self.Headers;if(typeof globalThis<"u"&&globalThis.Headers)return globalThis.Headers;if(typeof Headers<"u")return Headers;x("Could not find Headers implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static response(){if(this.responseImpl)return this.responseImpl;if(typeof self<"u"&&"Response"in self)return self.Response;if(typeof globalThis<"u"&&globalThis.Response)return globalThis.Response;if(typeof Response<"u")return Response;x("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}};var wo={CREDENTIAL_MISMATCH:"custom-token-mismatch",MISSING_CUSTOM_TOKEN:"internal-error",INVALID_IDENTIFIER:"invalid-email",MISSING_CONTINUE_URI:"internal-error",INVALID_PASSWORD:"wrong-password",MISSING_PASSWORD:"missing-password",INVALID_LOGIN_CREDENTIALS:"invalid-credential",EMAIL_EXISTS:"email-already-in-use",PASSWORD_LOGIN_DISABLED:"operation-not-allowed",INVALID_IDP_RESPONSE:"invalid-credential",INVALID_PENDING_TOKEN:"invalid-credential",FEDERATED_USER_ID_ALREADY_LINKED:"credential-already-in-use",MISSING_REQ_TYPE:"internal-error",EMAIL_NOT_FOUND:"user-not-found",RESET_PASSWORD_EXCEED_LIMIT:"too-many-requests",EXPIRED_OOB_CODE:"expired-action-code",INVALID_OOB_CODE:"invalid-action-code",MISSING_OOB_CODE:"internal-error",CREDENTIAL_TOO_OLD_LOGIN_AGAIN:"requires-recent-login",INVALID_ID_TOKEN:"invalid-user-token",TOKEN_EXPIRED:"user-token-expired",USER_NOT_FOUND:"user-token-expired",TOO_MANY_ATTEMPTS_TRY_LATER:"too-many-requests",PASSWORD_DOES_NOT_MEET_REQUIREMENTS:"password-does-not-meet-requirements",INVALID_CODE:"invalid-verification-code",INVALID_SESSION_INFO:"invalid-verification-id",INVALID_TEMPORARY_PROOF:"invalid-credential",MISSING_SESSION_INFO:"missing-verification-id",SESSION_EXPIRED:"code-expired",MISSING_ANDROID_PACKAGE_NAME:"missing-android-pkg-name",UNAUTHORIZED_DOMAIN:"unauthorized-continue-uri",INVALID_OAUTH_CLIENT_ID:"invalid-oauth-client-id",ADMIN_ONLY_OPERATION:"admin-restricted-operation",INVALID_MFA_PENDING_CREDENTIAL:"invalid-multi-factor-session",MFA_ENROLLMENT_NOT_FOUND:"multi-factor-info-not-found",MISSING_MFA_ENROLLMENT_ID:"missing-multi-factor-info",MISSING_MFA_PENDING_CREDENTIAL:"missing-multi-factor-session",SECOND_FACTOR_EXISTS:"second-factor-already-in-use",SECOND_FACTOR_LIMIT_EXCEEDED:"maximum-second-factor-count-exceeded",BLOCKING_FUNCTION_ERROR_RESPONSE:"internal-error",RECAPTCHA_NOT_ENABLED:"recaptcha-not-enabled",MISSING_RECAPTCHA_TOKEN:"missing-recaptcha-token",INVALID_RECAPTCHA_TOKEN:"invalid-recaptcha-token",INVALID_RECAPTCHA_ACTION:"invalid-recaptcha-action",MISSING_CLIENT_TYPE:"missing-client-type",MISSING_RECAPTCHA_VERSION:"missing-recaptcha-version",INVALID_RECAPTCHA_VERSION:"invalid-recaptcha-version",INVALID_REQ_TYPE:"invalid-req-type"};var To=["/v1/accounts:signInWithCustomToken","/v1/accounts:signInWithEmailLink","/v1/accounts:signInWithIdp","/v1/accounts:signInWithPassword","/v1/accounts:signInWithPhoneNumber","/v1/token"],bo=new Q(3e4,6e4);function b(t,e){return t.tenantId&&!e.tenantId?{...e,tenantId:t.tenantId}:e}async function k(t,e,n,r,i={}){return Jr(t,i,async()=>{let s={},o={};r&&(e==="GET"?o=r:s={body:JSON.stringify(r)});let a=ce({key:t.config.apiKey,...o}).slice(1),u=await t._getAdditionalHeaders();u["Content-Type"]="application/json",t.languageCode&&(u["X-Firebase-Locale"]=t.languageCode);let c={method:e,headers:u,...s};return sr()||(c.referrerPolicy="no-referrer"),t.emulatorConfig&&ve(t.emulatorConfig.host)&&(c.credentials="include"),nt.fetch()(await Yr(t,t.config.apiHost,n,a),c)})}async function Jr(t,e,n){t._canInitEmulator=!1;let r={...wo,...e};try{let i=new hn(t),s=await Promise.race([n(),i.promise]);i.clearNetworkTimeout();let o=await s.json();if("needConfirmation"in o)throw be(t,"account-exists-with-different-credential",o);if(s.ok&&!("errorMessage"in o))return o;{let a=s.ok?o.errorMessage:o.error.message,[u,c]=a.split(" : ");if(u==="FEDERATED_USER_ID_ALREADY_LINKED")throw be(t,"credential-already-in-use",o);if(u==="EMAIL_EXISTS")throw be(t,"email-already-in-use",o);if(u==="USER_DISABLED")throw be(t,"user-disabled",o);let h=r[u]||u.toLowerCase().replace(/[_\s]+/g,"-");if(c)throw Rn(t,h,c);R(t,h)}}catch(i){if(i instanceof P)throw i;R(t,"network-request-failed",{message:String(i)})}}async function ie(t,e,n,r,i={}){let s=await k(t,e,n,r,i);return"mfaPendingCredential"in s&&R(t,"multi-factor-auth-required",{_serverResponse:s}),s}async function Yr(t,e,n,r){let i=`${e}${n}?${r}`,s=t,o=s.config.emulator?Nn(t.config,i):`${t.config.apiScheme}://${i}`;return To.includes(n)&&(await s._persistenceManagerAvailable,s._getPersistenceType()==="COOKIE")?s._getPersistence()._getFinalTarget(o).toString():o}function Ao(t){switch(t){case"ENFORCE":return"ENFORCE";case"AUDIT":return"AUDIT";case"OFF":return"OFF";default:return"ENFORCEMENT_STATE_UNSPECIFIED"}}var hn=class{clearNetworkTimeout(){clearTimeout(this.timer)}constructor(e){this.auth=e,this.timer=null,this.promise=new Promise((n,r)=>{this.timer=setTimeout(()=>r(O(this.auth,"network-request-failed")),bo.get())})}};function be(t,e,n){let r={appName:t.name};n.email&&(r.email=n.email),n.phoneNumber&&(r.phoneNumber=n.phoneNumber);let i=O(t,e,r);return i.customData._tokenResponse=n,i}function Rr(t){return t!==void 0&&t.enterprise!==void 0}var rt=class{constructor(e){if(this.siteKey="",this.recaptchaEnforcementState=[],e.recaptchaKey===void 0)throw new Error("recaptchaKey undefined");this.siteKey=e.recaptchaKey.split("/")[3],this.recaptchaEnforcementState=e.recaptchaEnforcementState}getProviderEnforcementState(e){if(!this.recaptchaEnforcementState||this.recaptchaEnforcementState.length===0)return null;for(let n of this.recaptchaEnforcementState)if(n.provider&&n.provider===e)return Ao(n.enforcementState);return null}isProviderEnabled(e){return this.getProviderEnforcementState(e)==="ENFORCE"||this.getProviderEnforcementState(e)==="AUDIT"}isAnyProviderEnabled(){return this.isProviderEnabled("EMAIL_PASSWORD_PROVIDER")||this.isProviderEnabled("PHONE_PROVIDER")}};async function Xr(t,e){return k(t,"GET","/v2/recaptchaConfig",b(t,e))}async function So(t,e){return k(t,"POST","/v1/accounts:delete",e)}async function it(t,e){return k(t,"POST","/v1/accounts:lookup",e)}function Ae(t){if(t)try{let e=new Date(Number(t));if(!isNaN(e.getTime()))return e.toUTCString()}catch{}}async function Qr(t,e=!1){let n=j(t),r=await n.getIdToken(e),i=On(r);p(i&&i.exp&&i.auth_time&&i.iat,n.auth,"internal-error");let s=typeof i.firebase=="object"?i.firebase:void 0,o=s?.sign_in_provider;return{claims:i,token:r,authTime:Ae(on(i.auth_time)),issuedAtTime:Ae(on(i.iat)),expirationTime:Ae(on(i.exp)),signInProvider:o||null,signInSecondFactor:s?.sign_in_second_factor||null}}function on(t){return Number(t)*1e3}function On(t){let[e,n,r]=t.split(".");if(e===void 0||n===void 0||r===void 0)return Ye("JWT malformed, contained fewer than 3 sections"),null;try{let i=je(n);return i?JSON.parse(i):(Ye("Failed to decode base64 JWT payload"),null)}catch(i){return Ye("Caught error parsing JWT payload as JSON",i?.toString()),null}}function Pr(t){let e=On(t);return p(e,"internal-error"),p(typeof e.exp<"u","internal-error"),p(typeof e.iat<"u","internal-error"),Number(e.exp)-Number(e.iat)}async function Re(t,e,n=!1){if(n)return e;try{return await e}catch(r){throw r instanceof P&&ko(r)&&t.auth.currentUser===t&&await t.auth.signOut(),r}}function ko({code:t}){return t==="auth/user-disabled"||t==="auth/user-token-expired"}var fn=class{constructor(e){this.user=e,this.isRunning=!1,this.timerId=null,this.errorBackoff=3e4}_start(){this.isRunning||(this.isRunning=!0,this.schedule())}_stop(){this.isRunning&&(this.isRunning=!1,this.timerId!==null&&clearTimeout(this.timerId))}getInterval(e){if(e){let n=this.errorBackoff;return this.errorBackoff=Math.min(this.errorBackoff*2,96e4),n}else{this.errorBackoff=3e4;let r=(this.user.stsTokenManager.expirationTime??0)-Date.now()-3e5;return Math.max(0,r)}}schedule(e=!1){if(!this.isRunning)return;let n=this.getInterval(e);this.timerId=setTimeout(async()=>{await this.iteration()},n)}async iteration(){try{await this.user.getIdToken(!0)}catch(e){e?.code==="auth/network-request-failed"&&this.schedule(!0);return}this.schedule()}};var Pe=class{constructor(e,n){this.createdAt=e,this.lastLoginAt=n,this._initializeTime()}_initializeTime(){this.lastSignInTime=Ae(this.lastLoginAt),this.creationTime=Ae(this.createdAt)}_copy(e){this.createdAt=e.createdAt,this.lastLoginAt=e.lastLoginAt,this._initializeTime()}toJSON(){return{createdAt:this.createdAt,lastLoginAt:this.lastLoginAt}}};async function st(t){let e=t.auth,n=await t.getIdToken(),r=await Re(t,it(e,{idToken:n}));p(r?.users.length,e,"internal-error");let i=r.users[0];t._notifyReloadListener(i);let s=i.providerUserInfo?.length?ei(i.providerUserInfo):[],o=Co(t.providerData,s),a=t.isAnonymous,u=!(t.email&&i.passwordHash)&&!o?.length,c=a?u:!1,h={uid:i.localId,displayName:i.displayName||null,photoURL:i.photoUrl||null,email:i.email||null,emailVerified:i.emailVerified||!1,phoneNumber:i.phoneNumber||null,tenantId:i.tenantId||null,providerData:o,metadata:new Pe(i.createdAt,i.lastLoginAt),isAnonymous:c};Object.assign(t,h)}async function Zr(t){let e=j(t);await st(e),await e.auth._persistUserIfCurrent(e),e.auth._notifyListenersIfCurrent(e)}function Co(t,e){return[...t.filter(r=>!e.some(i=>i.providerId===r.providerId)),...e]}function ei(t){return t.map(({providerId:e,...n})=>({providerId:e,uid:n.rawId||"",displayName:n.displayName||null,email:n.email||null,phoneNumber:n.phoneNumber||null,photoURL:n.photoUrl||null}))}async function Ro(t,e){let n=await Jr(t,{},async()=>{let r=ce({grant_type:"refresh_token",refresh_token:e}).slice(1),{tokenApiHost:i,apiKey:s}=t.config,o=await Yr(t,i,"/v1/token",`key=${s}`),a=await t._getAdditionalHeaders();a["Content-Type"]="application/x-www-form-urlencoded";let u={method:"POST",headers:a,body:r};return t.emulatorConfig&&ve(t.emulatorConfig.host)&&(u.credentials="include"),nt.fetch()(o,u)});return{accessToken:n.access_token,expiresIn:n.expires_in,refreshToken:n.refresh_token}}async function Po(t,e){return k(t,"POST","/v2/accounts:revokeToken",b(t,e))}var Se=class t{constructor(){this.refreshToken=null,this.accessToken=null,this.expirationTime=null}get isExpired(){return!this.expirationTime||Date.now()>this.expirationTime-3e4}updateFromServerResponse(e){p(e.idToken,"internal-error"),p(typeof e.idToken<"u","internal-error"),p(typeof e.refreshToken<"u","internal-error");let n="expiresIn"in e&&typeof e.expiresIn<"u"?Number(e.expiresIn):Pr(e.idToken);this.updateTokensAndExpiration(e.idToken,e.refreshToken,n)}updateFromIdToken(e){p(e.length!==0,"internal-error");let n=Pr(e);this.updateTokensAndExpiration(e,null,n)}async getToken(e,n=!1){return!n&&this.accessToken&&!this.isExpired?this.accessToken:(p(this.refreshToken,e,"user-token-expired"),this.refreshToken?(await this.refresh(e,this.refreshToken),this.accessToken):null)}clearRefreshToken(){this.refreshToken=null}async refresh(e,n){let{accessToken:r,refreshToken:i,expiresIn:s}=await Ro(e,n);this.updateTokensAndExpiration(r,i,Number(s))}updateTokensAndExpiration(e,n,r){this.refreshToken=n||null,this.accessToken=e||null,this.expirationTime=Date.now()+r*1e3}static fromJSON(e,n){let{refreshToken:r,accessToken:i,expirationTime:s}=n,o=new t;return r&&(p(typeof r=="string","internal-error",{appName:e}),o.refreshToken=r),i&&(p(typeof i=="string","internal-error",{appName:e}),o.accessToken=i),s&&(p(typeof s=="number","internal-error",{appName:e}),o.expirationTime=s),o}toJSON(){return{refreshToken:this.refreshToken,accessToken:this.accessToken,expirationTime:this.expirationTime}}_assign(e){this.accessToken=e.accessToken,this.refreshToken=e.refreshToken,this.expirationTime=e.expirationTime}_clone(){return Object.assign(new t,this.toJSON())}_performRefresh(){return x("not implemented")}};function K(t,e){p(typeof t=="string"||typeof t>"u","internal-error",{appName:e})}var J=class t{constructor({uid:e,auth:n,stsTokenManager:r,...i}){this.providerId="firebase",this.proactiveRefresh=new fn(this),this.reloadUserInfo=null,this.reloadListener=null,this.uid=e,this.auth=n,this.stsTokenManager=r,this.accessToken=r.accessToken,this.displayName=i.displayName||null,this.email=i.email||null,this.emailVerified=i.emailVerified||!1,this.phoneNumber=i.phoneNumber||null,this.photoURL=i.photoURL||null,this.isAnonymous=i.isAnonymous||!1,this.tenantId=i.tenantId||null,this.providerData=i.providerData?[...i.providerData]:[],this.metadata=new Pe(i.createdAt||void 0,i.lastLoginAt||void 0)}async getIdToken(e){let n=await Re(this,this.stsTokenManager.getToken(this.auth,e));return p(n,this.auth,"internal-error"),this.accessToken!==n&&(this.accessToken=n,await this.auth._persistUserIfCurrent(this),this.auth._notifyListenersIfCurrent(this)),n}getIdTokenResult(e){return Qr(this,e)}reload(){return Zr(this)}_assign(e){this!==e&&(p(this.uid===e.uid,this.auth,"internal-error"),this.displayName=e.displayName,this.photoURL=e.photoURL,this.email=e.email,this.emailVerified=e.emailVerified,this.phoneNumber=e.phoneNumber,this.isAnonymous=e.isAnonymous,this.tenantId=e.tenantId,this.providerData=e.providerData.map(n=>({...n})),this.metadata._copy(e.metadata),this.stsTokenManager._assign(e.stsTokenManager))}_clone(e){let n=new t({...this,auth:e,stsTokenManager:this.stsTokenManager._clone()});return n.metadata._copy(this.metadata),n}_onReload(e){p(!this.reloadListener,this.auth,"internal-error"),this.reloadListener=e,this.reloadUserInfo&&(this._notifyReloadListener(this.reloadUserInfo),this.reloadUserInfo=null)}_notifyReloadListener(e){this.reloadListener?this.reloadListener(e):this.reloadUserInfo=e}_startProactiveRefresh(){this.proactiveRefresh._start()}_stopProactiveRefresh(){this.proactiveRefresh._stop()}async _updateTokensIfNecessary(e,n=!1){let r=!1;e.idToken&&e.idToken!==this.stsTokenManager.accessToken&&(this.stsTokenManager.updateFromServerResponse(e),r=!0),n&&await st(this),await this.auth._persistUserIfCurrent(this),r&&this.auth._notifyListenersIfCurrent(this)}async delete(){if(N(this.auth.app))return Promise.reject(X(this.auth));let e=await this.getIdToken();return await Re(this,So(this.auth,{idToken:e})),this.stsTokenManager.clearRefreshToken(),this.auth.signOut()}toJSON(){return{uid:this.uid,email:this.email||void 0,emailVerified:this.emailVerified,displayName:this.displayName||void 0,isAnonymous:this.isAnonymous,photoURL:this.photoURL||void 0,phoneNumber:this.phoneNumber||void 0,tenantId:this.tenantId||void 0,providerData:this.providerData.map(e=>({...e})),stsTokenManager:this.stsTokenManager.toJSON(),_redirectEventId:this._redirectEventId,...this.metadata.toJSON(),apiKey:this.auth.config.apiKey,appName:this.auth.name}}get refreshToken(){return this.stsTokenManager.refreshToken||""}static _fromJSON(e,n){let r=n.displayName??void 0,i=n.email??void 0,s=n.phoneNumber??void 0,o=n.photoURL??void 0,a=n.tenantId??void 0,u=n._redirectEventId??void 0,c=n.createdAt??void 0,h=n.lastLoginAt??void 0,{uid:l,emailVerified:d,isAnonymous:f,providerData:g,stsTokenManager:A}=n;p(l&&A,e,"internal-error");let y=Se.fromJSON(this.name,A);p(typeof l=="string",e,"internal-error"),K(r,e.name),K(i,e.name),p(typeof d=="boolean",e,"internal-error"),p(typeof f=="boolean",e,"internal-error"),K(s,e.name),K(o,e.name),K(a,e.name),K(u,e.name),K(c,e.name),K(h,e.name);let _=new t({uid:l,auth:e,email:i,emailVerified:d,displayName:r,isAnonymous:f,photoURL:o,phoneNumber:s,tenantId:a,stsTokenManager:y,createdAt:c,lastLoginAt:h});return g&&Array.isArray(g)&&(_.providerData=g.map(m=>({...m}))),u&&(_._redirectEventId=u),_}static async _fromIdTokenResponse(e,n,r=!1){let i=new Se;i.updateFromServerResponse(n);let s=new t({uid:n.localId,auth:e,stsTokenManager:i,isAnonymous:r});return await st(s),s}static async _fromGetAccountInfoResponse(e,n,r){let i=n.users[0];p(i.localId!==void 0,"internal-error");let s=i.providerUserInfo!==void 0?ei(i.providerUserInfo):[],o=!(i.email&&i.passwordHash)&&!s?.length,a=new Se;a.updateFromIdToken(r);let u=new t({uid:i.localId,auth:e,stsTokenManager:a,isAnonymous:o}),c={uid:i.localId,displayName:i.displayName||null,photoURL:i.photoUrl||null,email:i.email||null,emailVerified:i.emailVerified||!1,phoneNumber:i.phoneNumber||null,tenantId:i.tenantId||null,providerData:s,metadata:new Pe(i.createdAt,i.lastLoginAt),isAnonymous:!(i.email&&i.passwordHash)&&!s?.length};return Object.assign(u,c),u}};var Nr=new Map;function W(t){B(t instanceof Function,"Expected a class definition");let e=Nr.get(t);return e?(B(e instanceof t,"Instance stored in cache mismatched with class"),e):(e=new t,Nr.set(t,e),e)}var ot=class{constructor(){this.type="NONE",this.storage={}}async _isAvailable(){return!0}async _set(e,n){this.storage[e]=n}async _get(e){let n=this.storage[e];return n===void 0?null:n}async _remove(e){delete this.storage[e]}_addListener(e,n){}_removeListener(e,n){}};ot.type="NONE";var pn=ot;function Xe(t,e,n){return`firebase:${t}:${e}:${n}`}var at=class t{constructor(e,n,r){this.persistence=e,this.auth=n,this.userKey=r;let{config:i,name:s}=this.auth;this.fullUserKey=Xe(this.userKey,i.apiKey,s),this.fullPersistenceKey=Xe("persistence",i.apiKey,s),this.boundEventHandler=n._onStorageEvent.bind(n),this.persistence._addListener(this.fullUserKey,this.boundEventHandler)}setCurrentUser(e){return this.persistence._set(this.fullUserKey,e.toJSON())}async getCurrentUser(){let e=await this.persistence._get(this.fullUserKey);if(!e)return null;if(typeof e=="string"){let n=await it(this.auth,{idToken:e}).catch(()=>{});return n?J._fromGetAccountInfoResponse(this.auth,n,e):null}return J._fromJSON(this.auth,e)}removeCurrentUser(){return this.persistence._remove(this.fullUserKey)}savePersistenceForRedirect(){return this.persistence._set(this.fullPersistenceKey,this.persistence.type)}async setPersistence(e){if(this.persistence===e)return;let n=await this.getCurrentUser();if(await this.removeCurrentUser(),this.persistence=e,n)return this.setCurrentUser(n)}delete(){this.persistence._removeListener(this.fullUserKey,this.boundEventHandler)}static async create(e,n,r="authUser"){if(!n.length)return new t(W(pn),e,r);let i=(await Promise.all(n.map(async c=>{if(await c._isAvailable())return c}))).filter(c=>c),s=i[0]||W(pn),o=Xe(r,e.config.apiKey,e.name),a=null;for(let c of n)try{let h=await c._get(o);if(h){let l;if(typeof h=="string"){let d=await it(e,{idToken:h}).catch(()=>{});if(!d)break;l=await J._fromGetAccountInfoResponse(e,d,h)}else l=J._fromJSON(e,h);c!==s&&(a=l),s=c;break}}catch{}let u=i.filter(c=>c._shouldAllowMigration);return!s._shouldAllowMigration||!u.length?new t(s,e,r):(s=u[0],a&&await s._set(o,a.toJSON()),await Promise.all(n.map(async c=>{if(c!==s)try{await c._remove(o)}catch{}})),new t(s,e,r))}};function Or(t){let e=t.toLowerCase();if(e.includes("opera/")||e.includes("opr/")||e.includes("opios/"))return"Opera";if(ii(e))return"IEMobile";if(e.includes("msie")||e.includes("trident/"))return"IE";if(e.includes("edge/"))return"Edge";if(ti(e))return"Firefox";if(e.includes("silk/"))return"Silk";if(oi(e))return"Blackberry";if(ai(e))return"Webos";if(ni(e))return"Safari";if((e.includes("chrome/")||ri(e))&&!e.includes("edge/"))return"Chrome";if(si(e))return"Android";{let n=/([a-zA-Z\d\.]+)\/[a-zA-Z\d\.]*$/,r=t.match(n);if(r?.length===2)return r[1]}return"Other"}function ti(t=S()){return/firefox\//i.test(t)}function ni(t=S()){let e=t.toLowerCase();return e.includes("safari/")&&!e.includes("chrome/")&&!e.includes("crios/")&&!e.includes("android")}function ri(t=S()){return/crios\//i.test(t)}function ii(t=S()){return/iemobile/i.test(t)}function si(t=S()){return/android/i.test(t)}function oi(t=S()){return/blackberry/i.test(t)}function ai(t=S()){return/webos/i.test(t)}function Dn(t=S()){return/iphone|ipad|ipod/i.test(t)||/macintosh/i.test(t)&&/mobile/i.test(t)}function No(t=S()){return Dn(t)&&!!window.navigator?.standalone}function Oo(){return cr()&&document.documentMode===10}function ci(t=S()){return Dn(t)||si(t)||ai(t)||oi(t)||/windows phone/i.test(t)||ii(t)}function ui(t,e=[]){let n;switch(t){case"Browser":n=Or(S());break;case"Worker":n=`${Or(S())}-${t}`;break;default:n=t}let r=e.length?e.join(","):"FirebaseCore-web";return`${n}/JsCore/${fe}/${r}`}var _n=class{constructor(e){this.auth=e,this.queue=[]}pushCallback(e,n){let r=s=>new Promise((o,a)=>{try{let u=e(s);o(u)}catch(u){a(u)}});r.onAbort=n,this.queue.push(r);let i=this.queue.length-1;return()=>{this.queue[i]=()=>Promise.resolve()}}async runMiddleware(e){if(this.auth.currentUser===e)return;let n=[];try{for(let r of this.queue)await r(e),r.onAbort&&n.push(r.onAbort)}catch(r){n.reverse();for(let i of n)try{i()}catch{}throw this.auth._errorFactory.create("login-blocked",{originalMessage:r?.message})}}};async function Do(t,e={}){return k(t,"GET","/v2/passwordPolicy",b(t,e))}var Lo=6,mn=class{constructor(e){let n=e.customStrengthOptions;this.customStrengthOptions={},this.customStrengthOptions.minPasswordLength=n.minPasswordLength??Lo,n.maxPasswordLength&&(this.customStrengthOptions.maxPasswordLength=n.maxPasswordLength),n.containsLowercaseCharacter!==void 0&&(this.customStrengthOptions.containsLowercaseLetter=n.containsLowercaseCharacter),n.containsUppercaseCharacter!==void 0&&(this.customStrengthOptions.containsUppercaseLetter=n.containsUppercaseCharacter),n.containsNumericCharacter!==void 0&&(this.customStrengthOptions.containsNumericCharacter=n.containsNumericCharacter),n.containsNonAlphanumericCharacter!==void 0&&(this.customStrengthOptions.containsNonAlphanumericCharacter=n.containsNonAlphanumericCharacter),this.enforcementState=e.enforcementState,this.enforcementState==="ENFORCEMENT_STATE_UNSPECIFIED"&&(this.enforcementState="OFF"),this.allowedNonAlphanumericCharacters=e.allowedNonAlphanumericCharacters?.join("")??"",this.forceUpgradeOnSignin=e.forceUpgradeOnSignin??!1,this.schemaVersion=e.schemaVersion}validatePassword(e){let n={isValid:!0,passwordPolicy:this};return this.validatePasswordLengthOptions(e,n),this.validatePasswordCharacterOptions(e,n),n.isValid&&(n.isValid=n.meetsMinPasswordLength??!0),n.isValid&&(n.isValid=n.meetsMaxPasswordLength??!0),n.isValid&&(n.isValid=n.containsLowercaseLetter??!0),n.isValid&&(n.isValid=n.containsUppercaseLetter??!0),n.isValid&&(n.isValid=n.containsNumericCharacter??!0),n.isValid&&(n.isValid=n.containsNonAlphanumericCharacter??!0),n}validatePasswordLengthOptions(e,n){let r=this.customStrengthOptions.minPasswordLength,i=this.customStrengthOptions.maxPasswordLength;r&&(n.meetsMinPasswordLength=e.length>=r),i&&(n.meetsMaxPasswordLength=e.length<=i)}validatePasswordCharacterOptions(e,n){this.updatePasswordCharacterOptionsStatuses(n,!1,!1,!1,!1);let r;for(let i=0;i<e.length;i++)r=e.charAt(i),this.updatePasswordCharacterOptionsStatuses(n,r>="a"&&r<="z",r>="A"&&r<="Z",r>="0"&&r<="9",this.allowedNonAlphanumericCharacters.includes(r))}updatePasswordCharacterOptionsStatuses(e,n,r,i,s){this.customStrengthOptions.containsLowercaseLetter&&(e.containsLowercaseLetter||(e.containsLowercaseLetter=n)),this.customStrengthOptions.containsUppercaseLetter&&(e.containsUppercaseLetter||(e.containsUppercaseLetter=r)),this.customStrengthOptions.containsNumericCharacter&&(e.containsNumericCharacter||(e.containsNumericCharacter=i)),this.customStrengthOptions.containsNonAlphanumericCharacter&&(e.containsNonAlphanumericCharacter||(e.containsNonAlphanumericCharacter=s))}};var gn=class{constructor(e,n,r,i){this.app=e,this.heartbeatServiceProvider=n,this.appCheckServiceProvider=r,this.config=i,this.currentUser=null,this.emulatorConfig=null,this.operations=Promise.resolve(),this.authStateSubscription=new ct(this),this.idTokenSubscription=new ct(this),this.beforeStateQueue=new _n(this),this.redirectUser=null,this.isProactiveRefreshEnabled=!1,this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION=1,this._canInitEmulator=!0,this._isInitialized=!1,this._deleted=!1,this._initializationPromise=null,this._popupRedirectResolver=null,this._errorFactory=Kr,this._agentRecaptchaConfig=null,this._tenantRecaptchaConfigs={},this._projectPasswordPolicy=null,this._tenantPasswordPolicies={},this._resolvePersistenceManagerAvailable=void 0,this.lastNotifiedUid=void 0,this.languageCode=null,this.tenantId=null,this.settings={appVerificationDisabledForTesting:!1},this.frameworks=[],this.name=e.name,this.clientVersion=i.sdkClientVersion,this._persistenceManagerAvailable=new Promise(s=>this._resolvePersistenceManagerAvailable=s)}_initializeWithPersistence(e,n){return n&&(this._popupRedirectResolver=W(n)),this._initializationPromise=this.queue(async()=>{if(!this._deleted&&(this.persistenceManager=await at.create(this,e),this._resolvePersistenceManagerAvailable?.(),!this._deleted)){if(this._popupRedirectResolver?._shouldInitProactively)try{await this._popupRedirectResolver._initialize(this)}catch{}await this.initializeCurrentUser(n),this.lastNotifiedUid=this.currentUser?.uid||null,!this._deleted&&(this._isInitialized=!0)}}),this._initializationPromise}async _onStorageEvent(){if(this._deleted)return;let e=await this.assertedPersistence.getCurrentUser();if(!(!this.currentUser&&!e)){if(this.currentUser&&e&&this.currentUser.uid===e.uid){this._currentUser._assign(e),await this.currentUser.getIdToken();return}await this._updateCurrentUser(e,!0)}}async initializeCurrentUserFromIdToken(e){try{let n=await it(this,{idToken:e}),r=await J._fromGetAccountInfoResponse(this,n,e);await this.directlySetCurrentUser(r)}catch(n){console.warn("FirebaseServerApp could not login user with provided authIdToken: ",n),await this.directlySetCurrentUser(null)}}async initializeCurrentUser(e){if(N(this.app)){let s=this.app.settings.authIdToken;return s?new Promise(o=>{setTimeout(()=>this.initializeCurrentUserFromIdToken(s).then(o,o))}):this.directlySetCurrentUser(null)}let n=await this.assertedPersistence.getCurrentUser(),r=n,i=!1;if(e&&this.config.authDomain){await this.getOrInitRedirectPersistenceManager();let s=this.redirectUser?._redirectEventId,o=r?._redirectEventId,a=await this.tryRedirectSignIn(e);(!s||s===o)&&a?.user&&(r=a.user,i=!0)}if(!r)return this.directlySetCurrentUser(null);if(!r._redirectEventId){if(i)try{await this.beforeStateQueue.runMiddleware(r)}catch(s){r=n,this._popupRedirectResolver._overrideRedirectResult(this,()=>Promise.reject(s))}return r?this.reloadAndSetCurrentUserOrClear(r):this.directlySetCurrentUser(null)}return p(this._popupRedirectResolver,this,"argument-error"),await this.getOrInitRedirectPersistenceManager(),this.redirectUser&&this.redirectUser._redirectEventId===r._redirectEventId?this.directlySetCurrentUser(r):this.reloadAndSetCurrentUserOrClear(r)}async tryRedirectSignIn(e){let n=null;try{n=await this._popupRedirectResolver._completeRedirectFn(this,e,!0)}catch{await this._setRedirectUser(null)}return n}async reloadAndSetCurrentUserOrClear(e){try{await st(e)}catch(n){if(n?.code!=="auth/network-request-failed")return this.directlySetCurrentUser(null)}return this.directlySetCurrentUser(e)}useDeviceLanguage(){this.languageCode=vo()}async _delete(){this._deleted=!0}async updateCurrentUser(e){if(N(this.app))return Promise.reject(X(this));let n=e?j(e):null;return n&&p(n.auth.config.apiKey===this.config.apiKey,this,"invalid-user-token"),this._updateCurrentUser(n&&n._clone(this))}async _updateCurrentUser(e,n=!1){if(!this._deleted)return e&&p(this.tenantId===e.tenantId,this,"tenant-id-mismatch"),n||await this.beforeStateQueue.runMiddleware(e),this.queue(async()=>{await this.directlySetCurrentUser(e),this.notifyAuthListeners()})}async signOut(){return N(this.app)?Promise.reject(X(this)):(await this.beforeStateQueue.runMiddleware(null),(this.redirectPersistenceManager||this._popupRedirectResolver)&&await this._setRedirectUser(null),this._updateCurrentUser(null,!0))}setPersistence(e){return N(this.app)?Promise.reject(X(this)):this.queue(async()=>{await this.assertedPersistence.setPersistence(W(e))})}_getRecaptchaConfig(){return this.tenantId==null?this._agentRecaptchaConfig:this._tenantRecaptchaConfigs[this.tenantId]}async validatePassword(e){this._getPasswordPolicyInternal()||await this._updatePasswordPolicy();let n=this._getPasswordPolicyInternal();return n.schemaVersion!==this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION?Promise.reject(this._errorFactory.create("unsupported-password-policy-schema-version",{})):n.validatePassword(e)}_getPasswordPolicyInternal(){return this.tenantId===null?this._projectPasswordPolicy:this._tenantPasswordPolicies[this.tenantId]}async _updatePasswordPolicy(){let e=await Do(this),n=new mn(e);this.tenantId===null?this._projectPasswordPolicy=n:this._tenantPasswordPolicies[this.tenantId]=n}_getPersistenceType(){return this.assertedPersistence.persistence.type}_getPersistence(){return this.assertedPersistence.persistence}_updateErrorMap(e){this._errorFactory=new V("auth","Firebase",e())}onAuthStateChanged(e,n,r){return this.registerStateListener(this.authStateSubscription,e,n,r)}beforeAuthStateChanged(e,n){return this.beforeStateQueue.pushCallback(e,n)}onIdTokenChanged(e,n,r){return this.registerStateListener(this.idTokenSubscription,e,n,r)}authStateReady(){return new Promise((e,n)=>{if(this.currentUser)e();else{let r=this.onAuthStateChanged(()=>{r(),e()},n)}})}async revokeAccessToken(e){if(this.currentUser){let n=await this.currentUser.getIdToken(),r={providerId:"apple.com",tokenType:"ACCESS_TOKEN",token:e,idToken:n};this.tenantId!=null&&(r.tenantId=this.tenantId),await Po(this,r)}}toJSON(){return{apiKey:this.config.apiKey,authDomain:this.config.authDomain,appName:this.name,currentUser:this._currentUser?.toJSON()}}async _setRedirectUser(e,n){let r=await this.getOrInitRedirectPersistenceManager(n);return e===null?r.removeCurrentUser():r.setCurrentUser(e)}async getOrInitRedirectPersistenceManager(e){if(!this.redirectPersistenceManager){let n=e&&W(e)||this._popupRedirectResolver;p(n,this,"argument-error"),this.redirectPersistenceManager=await at.create(this,[W(n._redirectPersistence)],"redirectUser"),this.redirectUser=await this.redirectPersistenceManager.getCurrentUser()}return this.redirectPersistenceManager}async _redirectUserForId(e){return this._isInitialized&&await this.queue(async()=>{}),this._currentUser?._redirectEventId===e?this._currentUser:this.redirectUser?._redirectEventId===e?this.redirectUser:null}async _persistUserIfCurrent(e){if(e===this.currentUser)return this.queue(async()=>this.directlySetCurrentUser(e))}_notifyListenersIfCurrent(e){e===this.currentUser&&this.notifyAuthListeners()}_key(){return`${this.config.authDomain}:${this.config.apiKey}:${this.name}`}_startProactiveRefresh(){this.isProactiveRefreshEnabled=!0,this.currentUser&&this._currentUser._startProactiveRefresh()}_stopProactiveRefresh(){this.isProactiveRefreshEnabled=!1,this.currentUser&&this._currentUser._stopProactiveRefresh()}get _currentUser(){return this.currentUser}notifyAuthListeners(){if(!this._isInitialized)return;this.idTokenSubscription.next(this.currentUser);let e=this.currentUser?.uid??null;this.lastNotifiedUid!==e&&(this.lastNotifiedUid=e,this.authStateSubscription.next(this.currentUser))}registerStateListener(e,n,r,i){if(this._deleted)return()=>{};let s=typeof n=="function"?n:n.next.bind(n),o=!1,a=this._isInitialized?Promise.resolve():this._initializationPromise;if(p(a,this,"internal-error"),a.then(()=>{o||s(this.currentUser)}),typeof n=="function"){let u=e.addObserver(n,r,i);return()=>{o=!0,u()}}else{let u=e.addObserver(n);return()=>{o=!0,u()}}}async directlySetCurrentUser(e){this.currentUser&&this.currentUser!==e&&this._currentUser._stopProactiveRefresh(),e&&this.isProactiveRefreshEnabled&&e._startProactiveRefresh(),this.currentUser=e,e?await this.assertedPersistence.setCurrentUser(e):await this.assertedPersistence.removeCurrentUser()}queue(e){return this.operations=this.operations.then(e,e),this.operations}get assertedPersistence(){return p(this.persistenceManager,this,"internal-error"),this.persistenceManager}_logFramework(e){!e||this.frameworks.includes(e)||(this.frameworks.push(e),this.frameworks.sort(),this.clientVersion=ui(this.config.clientPlatform,this._getFrameworks()))}_getFrameworks(){return this.frameworks}async _getAdditionalHeaders(){let e={"X-Client-Version":this.clientVersion};this.app.options.appId&&(e["X-Firebase-gmpid"]=this.app.options.appId);let n=await this.heartbeatServiceProvider.getImmediate({optional:!0})?.getHeartbeatsHeader();n&&(e["X-Firebase-Client"]=n);let r=await this._getAppCheckToken();return r&&(e["X-Firebase-AppCheck"]=r),e}async _getAppCheckToken(){if(N(this.app)&&this.app.settings.appCheckToken)return this.app.settings.appCheckToken;let e=await this.appCheckServiceProvider.getImmediate({optional:!0})?.getToken();return e?.error&&go(`Error while retrieving App Check token: ${e.error}`),e?.token}};function se(t){return j(t)}var ct=class{constructor(e){this.auth=e,this.observer=null,this.addObserver=hr(n=>this.observer=n)}get next(){return p(this.observer,this.auth,"internal-error"),this.observer.next.bind(this.observer)}};var St={async loadJS(){throw new Error("Unable to load external scripts")},recaptchaV2Script:"",recaptchaEnterpriseScript:"",gapiScript:""};function Mo(t){St=t}function li(t){return St.loadJS(t)}function Uo(){return St.recaptchaEnterpriseScript}function xo(){return St.gapiScript}function di(t){return`__${t}${Math.floor(Math.random()*1e6)}`}var In=class{constructor(){this.enterprise=new En}ready(e){e()}execute(e,n){return Promise.resolve("token")}render(e,n){return""}},En=class{ready(e){e()}execute(e,n){return Promise.resolve("token")}render(e,n){return""}};var Fo="recaptcha-enterprise",ke="NO_RECAPTCHA",ut=class{constructor(e){this.type=Fo,this.auth=se(e)}async verify(e="verify",n=!1){async function r(s){if(!n){if(s.tenantId==null&&s._agentRecaptchaConfig!=null)return s._agentRecaptchaConfig.siteKey;if(s.tenantId!=null&&s._tenantRecaptchaConfigs[s.tenantId]!==void 0)return s._tenantRecaptchaConfigs[s.tenantId].siteKey}return new Promise(async(o,a)=>{Xr(s,{clientType:"CLIENT_TYPE_WEB",version:"RECAPTCHA_ENTERPRISE"}).then(u=>{if(u.recaptchaKey===void 0)a(new Error("recaptcha Enterprise site key undefined"));else{let c=new rt(u);return s.tenantId==null?s._agentRecaptchaConfig=c:s._tenantRecaptchaConfigs[s.tenantId]=c,o(c.siteKey)}}).catch(u=>{a(u)})})}function i(s,o,a){let u=window.grecaptcha;Rr(u)?u.enterprise.ready(()=>{u.enterprise.execute(s,{action:e}).then(c=>{o(c)}).catch(()=>{o(ke)})}):a(Error("No reCAPTCHA enterprise script loaded."))}return this.auth.settings.appVerificationDisabledForTesting?new In().execute("siteKey",{action:"verify"}):new Promise((s,o)=>{r(this.auth).then(a=>{if(!n&&Rr(window.grecaptcha))i(a,s,o);else{if(typeof window>"u"){o(new Error("RecaptchaVerifier is only supported in browser"));return}let u=Uo();u.length!==0&&(u+=a),li(u).then(()=>{i(a,s,o)}).catch(c=>{o(c)})}}).catch(a=>{o(a)})})}};async function Te(t,e,n,r=!1,i=!1){let s=new ut(t),o;if(i)o=ke;else try{o=await s.verify(n)}catch{o=await s.verify(n,!0)}let a={...e};if(n==="mfaSmsEnrollment"||n==="mfaSmsSignIn"){if("phoneEnrollmentInfo"in a){let u=a.phoneEnrollmentInfo.phoneNumber,c=a.phoneEnrollmentInfo.recaptchaToken;Object.assign(a,{phoneEnrollmentInfo:{phoneNumber:u,recaptchaToken:c,captchaResponse:o,clientType:"CLIENT_TYPE_WEB",recaptchaVersion:"RECAPTCHA_ENTERPRISE"}})}else if("phoneSignInInfo"in a){let u=a.phoneSignInInfo.recaptchaToken;Object.assign(a,{phoneSignInInfo:{recaptchaToken:u,captchaResponse:o,clientType:"CLIENT_TYPE_WEB",recaptchaVersion:"RECAPTCHA_ENTERPRISE"}})}return a}return r?Object.assign(a,{captchaResp:o}):Object.assign(a,{captchaResponse:o}),Object.assign(a,{clientType:"CLIENT_TYPE_WEB"}),Object.assign(a,{recaptchaVersion:"RECAPTCHA_ENTERPRISE"}),a}async function Ce(t,e,n,r,i){if(i==="EMAIL_PASSWORD_PROVIDER")if(t._getRecaptchaConfig()?.isProviderEnabled("EMAIL_PASSWORD_PROVIDER")){let s=await Te(t,e,n,n==="getOobCode");return r(t,s)}else return r(t,e).catch(async s=>{if(s.code==="auth/missing-recaptcha-token"){console.log(`${n} is protected by reCAPTCHA Enterprise for this project. Automatically triggering the reCAPTCHA flow and restarting the flow.`);let o=await Te(t,e,n,n==="getOobCode");return r(t,o)}else return Promise.reject(s)});else if(i==="PHONE_PROVIDER")if(t._getRecaptchaConfig()?.isProviderEnabled("PHONE_PROVIDER")){let s=await Te(t,e,n);return r(t,s).catch(async o=>{if(t._getRecaptchaConfig()?.getProviderEnforcementState("PHONE_PROVIDER")==="AUDIT"&&(o.code==="auth/missing-recaptcha-token"||o.code==="auth/invalid-app-credential")){console.log(`Failed to verify with reCAPTCHA Enterprise. Automatically triggering the reCAPTCHA v2 flow to complete the ${n} flow.`);let a=await Te(t,e,n,!1,!0);return r(t,a)}return Promise.reject(o)})}else{let s=await Te(t,e,n,!1,!0);return r(t,s)}else return Promise.reject(i+" provider is not supported.")}async function Vo(t){let e=se(t),n=await Xr(e,{clientType:"CLIENT_TYPE_WEB",version:"RECAPTCHA_ENTERPRISE"}),r=new rt(n);e.tenantId==null?e._agentRecaptchaConfig=r:e._tenantRecaptchaConfigs[e.tenantId]=r,r.isAnyProviderEnabled()&&new ut(e).verify()}function hi(t,e){let n=rn(t,"auth");if(n.isInitialized()){let i=n.getImmediate(),s=n.getOptions();if(z(s,e??{}))return i;R(i,"already-initialized")}return n.initialize({options:e})}function Ho(t,e){let n=e?.persistence||[],r=(Array.isArray(n)?n:[n]).map(W);e?.errorMap&&t._updateErrorMap(e.errorMap),t._initializeWithPersistence(r,e?.popupRedirectResolver)}function fi(t,e,n){let r=se(t);p(/^https?:\/\//.test(e),r,"invalid-emulator-scheme");let i=!!n?.disableWarnings,s=pi(e),{host:o,port:a}=Wo(e),u=a===null?"":`:${a}`,c={url:`${s}//${o}${u}/`},h=Object.freeze({host:o,port:a,protocol:s.replace(":",""),options:Object.freeze({disableWarnings:i})});if(!r._canInitEmulator){p(r.config.emulator&&r.emulatorConfig,r,"emulator-config-failed"),p(z(c,r.config.emulator)&&z(h,r.emulatorConfig),r,"emulator-config-failed");return}r.config.emulator=c,r.emulatorConfig=h,r.settings.appVerificationDisabledForTesting=!0,ve(o)?(nr(`${s}//${o}${u}`),rr("Auth",!0)):i||Bo()}function pi(t){let e=t.indexOf(":");return e<0?"":t.substr(0,e+1)}function Wo(t){let e=pi(t),n=/(\/\/)?([^?#/]+)/.exec(t.substr(e.length));if(!n)return{host:"",port:null};let r=n[2].split("@").pop()||"",i=/^(\[[^\]]+\])(:|$)/.exec(r);if(i){let s=i[1];return{host:s,port:Dr(r.substr(s.length+1))}}else{let[s,o]=r.split(":");return{host:s,port:Dr(o)}}}function Dr(t){if(!t)return null;let e=Number(t);return isNaN(e)?null:e}function Bo(){function t(){let e=document.createElement("p"),n=e.style;e.innerText="Running in emulator mode. Do not use with production credentials.",n.position="fixed",n.width="100%",n.backgroundColor="#ffffff",n.border=".1em solid #000000",n.color="#b50000",n.bottom="0px",n.left="0px",n.margin="0px",n.zIndex="10000",n.textAlign="center",e.classList.add("firebase-emulator-warning"),document.body.appendChild(e)}typeof console<"u"&&typeof console.info=="function"&&console.info("WARNING: You are using the Auth Emulator, which is intended for local testing only. Do not use with production credentials."),typeof window<"u"&&typeof document<"u"&&(document.readyState==="loading"?window.addEventListener("DOMContentLoaded",t):t())}var Z=class{constructor(e,n){this.providerId=e,this.signInMethod=n}toJSON(){return x("not implemented")}_getIdTokenResponse(e){return x("not implemented")}_linkToIdToken(e,n){return x("not implemented")}_getReauthenticationResolver(e){return x("not implemented")}};async function $o(t,e){return k(t,"POST","/v1/accounts:signUp",e)}async function zo(t,e){return ie(t,"POST","/v1/accounts:signInWithPassword",b(t,e))}async function jo(t,e){return ie(t,"POST","/v1/accounts:signInWithEmailLink",b(t,e))}async function qo(t,e){return ie(t,"POST","/v1/accounts:signInWithEmailLink",b(t,e))}var Ne=class t extends Z{constructor(e,n,r,i=null){super("password",r),this._email=e,this._password=n,this._tenantId=i}static _fromEmailAndPassword(e,n){return new t(e,n,"password")}static _fromEmailAndCode(e,n,r=null){return new t(e,n,"emailLink",r)}toJSON(){return{email:this._email,password:this._password,signInMethod:this.signInMethod,tenantId:this._tenantId}}static fromJSON(e){let n=typeof e=="string"?JSON.parse(e):e;if(n?.email&&n?.password){if(n.signInMethod==="password")return this._fromEmailAndPassword(n.email,n.password);if(n.signInMethod==="emailLink")return this._fromEmailAndCode(n.email,n.password,n.tenantId)}return null}async _getIdTokenResponse(e){switch(this.signInMethod){case"password":let n={returnSecureToken:!0,email:this._email,password:this._password,clientType:"CLIENT_TYPE_WEB"};return Ce(e,n,"signInWithPassword",zo,"EMAIL_PASSWORD_PROVIDER");case"emailLink":return jo(e,{email:this._email,oobCode:this._password});default:R(e,"internal-error")}}async _linkToIdToken(e,n){switch(this.signInMethod){case"password":let r={idToken:n,returnSecureToken:!0,email:this._email,password:this._password,clientType:"CLIENT_TYPE_WEB"};return Ce(e,r,"signUpPassword",$o,"EMAIL_PASSWORD_PROVIDER");case"emailLink":return qo(e,{idToken:n,email:this._email,oobCode:this._password});default:R(e,"internal-error")}}_getReauthenticationResolver(e){return this._getIdTokenResponse(e)}};async function pe(t,e){return ie(t,"POST","/v1/accounts:signInWithIdp",b(t,e))}var Go="http://localhost",ee=class t extends Z{constructor(){super(...arguments),this.pendingToken=null}static _fromParams(e){let n=new t(e.providerId,e.signInMethod);return e.idToken||e.accessToken?(e.idToken&&(n.idToken=e.idToken),e.accessToken&&(n.accessToken=e.accessToken),e.nonce&&!e.pendingToken&&(n.nonce=e.nonce),e.pendingToken&&(n.pendingToken=e.pendingToken)):e.oauthToken&&e.oauthTokenSecret?(n.accessToken=e.oauthToken,n.secret=e.oauthTokenSecret):R("argument-error"),n}toJSON(){return{idToken:this.idToken,accessToken:this.accessToken,secret:this.secret,nonce:this.nonce,pendingToken:this.pendingToken,providerId:this.providerId,signInMethod:this.signInMethod}}static fromJSON(e){let n=typeof e=="string"?JSON.parse(e):e,{providerId:r,signInMethod:i,...s}=n;if(!r||!i)return null;let o=new t(r,i);return o.idToken=s.idToken||void 0,o.accessToken=s.accessToken||void 0,o.secret=s.secret,o.nonce=s.nonce,o.pendingToken=s.pendingToken||null,o}_getIdTokenResponse(e){let n=this.buildRequest();return pe(e,n)}_linkToIdToken(e,n){let r=this.buildRequest();return r.idToken=n,pe(e,r)}_getReauthenticationResolver(e){let n=this.buildRequest();return n.autoCreate=!1,pe(e,n)}buildRequest(){let e={requestUri:Go,returnSecureToken:!0};if(this.pendingToken)e.pendingToken=this.pendingToken;else{let n={};this.idToken&&(n.id_token=this.idToken),this.accessToken&&(n.access_token=this.accessToken),this.secret&&(n.oauth_token_secret=this.secret),n.providerId=this.providerId,this.nonce&&!this.pendingToken&&(n.nonce=this.nonce),e.postBody=ce(n)}return e}};async function Lr(t,e){return k(t,"POST","/v1/accounts:sendVerificationCode",b(t,e))}async function Ko(t,e){return ie(t,"POST","/v1/accounts:signInWithPhoneNumber",b(t,e))}async function Jo(t,e){let n=await ie(t,"POST","/v1/accounts:signInWithPhoneNumber",b(t,e));if(n.temporaryProof)throw be(t,"account-exists-with-different-credential",n);return n}var Yo={USER_NOT_FOUND:"user-not-found"};async function Xo(t,e){let n={...e,operation:"REAUTH"};return ie(t,"POST","/v1/accounts:signInWithPhoneNumber",b(t,n),Yo)}var Oe=class t extends Z{constructor(e){super("phone","phone"),this.params=e}static _fromVerification(e,n){return new t({verificationId:e,verificationCode:n})}static _fromTokenResponse(e,n){return new t({phoneNumber:e,temporaryProof:n})}_getIdTokenResponse(e){return Ko(e,this._makeVerificationRequest())}_linkToIdToken(e,n){return Jo(e,{idToken:n,...this._makeVerificationRequest()})}_getReauthenticationResolver(e){return Xo(e,this._makeVerificationRequest())}_makeVerificationRequest(){let{temporaryProof:e,phoneNumber:n,verificationId:r,verificationCode:i}=this.params;return e&&n?{temporaryProof:e,phoneNumber:n}:{sessionInfo:r,code:i}}toJSON(){let e={providerId:this.providerId};return this.params.phoneNumber&&(e.phoneNumber=this.params.phoneNumber),this.params.temporaryProof&&(e.temporaryProof=this.params.temporaryProof),this.params.verificationCode&&(e.verificationCode=this.params.verificationCode),this.params.verificationId&&(e.verificationId=this.params.verificationId),e}static fromJSON(e){typeof e=="string"&&(e=JSON.parse(e));let{verificationId:n,verificationCode:r,phoneNumber:i,temporaryProof:s}=e;return!r&&!n&&!i&&!s?null:new t({verificationId:n,verificationCode:r,phoneNumber:i,temporaryProof:s})}};function Qo(t){switch(t){case"recoverEmail":return"RECOVER_EMAIL";case"resetPassword":return"PASSWORD_RESET";case"signIn":return"EMAIL_SIGNIN";case"verifyEmail":return"VERIFY_EMAIL";case"verifyAndChangeEmail":return"VERIFY_AND_CHANGE_EMAIL";case"revertSecondFactorAddition":return"REVERT_SECOND_FACTOR_ADDITION";default:return null}}function Zo(t){let e=ue(le(t)).link,n=e?ue(le(e)).deep_link_id:null,r=ue(le(t)).deep_link_id;return(r?ue(le(r)).link:null)||r||n||e||t}var lt=class t{constructor(e){let n=ue(le(e)),r=n.apiKey??null,i=n.oobCode??null,s=Qo(n.mode??null);p(r&&i&&s,"argument-error"),this.apiKey=r,this.operation=s,this.code=i,this.continueUrl=n.continueUrl??null,this.languageCode=n.lang??null,this.tenantId=n.tenantId??null}static parseLink(e){let n=Zo(e);try{return new t(n)}catch{return null}}};var _e=class t{constructor(){this.providerId=t.PROVIDER_ID}static credential(e,n){return Ne._fromEmailAndPassword(e,n)}static credentialWithLink(e,n){let r=lt.parseLink(n);return p(r,"argument-error"),Ne._fromEmailAndCode(e,r.code,r.tenantId)}};_e.PROVIDER_ID="password";_e.EMAIL_PASSWORD_SIGN_IN_METHOD="password";_e.EMAIL_LINK_SIGN_IN_METHOD="emailLink";var De=class{constructor(e){this.providerId=e,this.defaultLanguageCode=null,this.customParameters={}}setDefaultLanguage(e){this.defaultLanguageCode=e}setCustomParameters(e){return this.customParameters=e,this}getCustomParameters(){return this.customParameters}};var te=class extends De{constructor(){super(...arguments),this.scopes=[]}addScope(e){return this.scopes.includes(e)||this.scopes.push(e),this}getScopes(){return[...this.scopes]}};var Le=class t extends te{constructor(){super("facebook.com")}static credential(e){return ee._fromParams({providerId:t.PROVIDER_ID,signInMethod:t.FACEBOOK_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return t.credentialFromTaggedObject(e)}static credentialFromError(e){return t.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return t.credential(e.oauthAccessToken)}catch{return null}}};Le.FACEBOOK_SIGN_IN_METHOD="facebook.com";Le.PROVIDER_ID="facebook.com";var ne=class t extends te{constructor(){super("google.com"),this.addScope("profile")}static credential(e,n){return ee._fromParams({providerId:t.PROVIDER_ID,signInMethod:t.GOOGLE_SIGN_IN_METHOD,idToken:e,accessToken:n})}static credentialFromResult(e){return t.credentialFromTaggedObject(e)}static credentialFromError(e){return t.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{oauthIdToken:n,oauthAccessToken:r}=e;if(!n&&!r)return null;try{return t.credential(n,r)}catch{return null}}};ne.GOOGLE_SIGN_IN_METHOD="google.com";ne.PROVIDER_ID="google.com";var Me=class t extends te{constructor(){super("github.com")}static credential(e){return ee._fromParams({providerId:t.PROVIDER_ID,signInMethod:t.GITHUB_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return t.credentialFromTaggedObject(e)}static credentialFromError(e){return t.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return t.credential(e.oauthAccessToken)}catch{return null}}};Me.GITHUB_SIGN_IN_METHOD="github.com";Me.PROVIDER_ID="github.com";var Ue=class t extends te{constructor(){super("twitter.com")}static credential(e,n){return ee._fromParams({providerId:t.PROVIDER_ID,signInMethod:t.TWITTER_SIGN_IN_METHOD,oauthToken:e,oauthTokenSecret:n})}static credentialFromResult(e){return t.credentialFromTaggedObject(e)}static credentialFromError(e){return t.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{oauthAccessToken:n,oauthTokenSecret:r}=e;if(!n||!r)return null;try{return t.credential(n,r)}catch{return null}}};Ue.TWITTER_SIGN_IN_METHOD="twitter.com";Ue.PROVIDER_ID="twitter.com";var xe=class t{constructor(e){this.user=e.user,this.providerId=e.providerId,this._tokenResponse=e._tokenResponse,this.operationType=e.operationType}static async _fromIdTokenResponse(e,n,r,i=!1){let s=await J._fromIdTokenResponse(e,r,i),o=Mr(r);return new t({user:s,providerId:o,_tokenResponse:r,operationType:n})}static async _forOperation(e,n,r){await e._updateTokensIfNecessary(r,!0);let i=Mr(r);return new t({user:e,providerId:i,_tokenResponse:r,operationType:n})}};function Mr(t){return t.providerId?t.providerId:"phoneNumber"in t?"phone":null}var yn=class t extends P{constructor(e,n,r,i){super(n.code,n.message),this.operationType=r,this.user=i,Object.setPrototypeOf(this,t.prototype),this.customData={appName:e.name,tenantId:e.tenantId??void 0,_serverResponse:n.customData._serverResponse,operationType:r}}static _fromErrorAndOperation(e,n,r,i){return new t(e,n,r,i)}};function _i(t,e,n,r){return(e==="reauthenticate"?n._getReauthenticationResolver(t):n._getIdTokenResponse(t)).catch(s=>{throw s.code==="auth/multi-factor-auth-required"?yn._fromErrorAndOperation(t,s,e,r):s})}async function ea(t,e,n=!1){let r=await Re(t,e._linkToIdToken(t.auth,await t.getIdToken()),n);return xe._forOperation(t,"link",r)}async function ta(t,e,n=!1){let{auth:r}=t;if(N(r.app))return Promise.reject(X(r));let i="reauthenticate";try{let s=await Re(t,_i(r,i,e,t),n);p(s.idToken,r,"internal-error");let o=On(s.idToken);p(o,r,"internal-error");let{sub:a}=o;return p(t.uid===a,r,"user-mismatch"),xe._forOperation(t,i,s)}catch(s){throw s?.code==="auth/user-not-found"&&R(r,"user-mismatch"),s}}async function na(t,e,n=!1){if(N(t.app))return Promise.reject(X(t));let r="signIn",i=await _i(t,r,e),s=await xe._fromIdTokenResponse(t,r,i);return n||await t._updateCurrentUser(s.user),s}function mi(t,e,n,r){return j(t).onIdTokenChanged(e,n,r)}function gi(t,e,n){return j(t).beforeAuthStateChanged(e,n)}function Ur(t,e){return k(t,"POST","/v2/accounts/mfaEnrollment:start",b(t,e))}function ra(t,e){return k(t,"POST","/v2/accounts/mfaEnrollment:finalize",b(t,e))}function ia(t,e){return k(t,"POST","/v2/accounts/mfaEnrollment:start",b(t,e))}function sa(t,e){return k(t,"POST","/v2/accounts/mfaEnrollment:finalize",b(t,e))}var dt="__sak";var ht=class{constructor(e,n){this.storageRetriever=e,this.type=n}_isAvailable(){try{return this.storage?(this.storage.setItem(dt,"1"),this.storage.removeItem(dt),Promise.resolve(!0)):Promise.resolve(!1)}catch{return Promise.resolve(!1)}}_set(e,n){return this.storage.setItem(e,JSON.stringify(n)),Promise.resolve()}_get(e){let n=this.storage.getItem(e);return Promise.resolve(n?JSON.parse(n):null)}_remove(e){return this.storage.removeItem(e),Promise.resolve()}get storage(){return this.storageRetriever()}};var oa=1e3,aa=10,ft=class extends ht{constructor(){super(()=>window.localStorage,"LOCAL"),this.boundEventHandler=(e,n)=>this.onStorageEvent(e,n),this.listeners={},this.localCache={},this.pollTimer=null,this.fallbackToPolling=ci(),this._shouldAllowMigration=!0}forAllChangedKeys(e){for(let n of Object.keys(this.listeners)){let r=this.storage.getItem(n),i=this.localCache[n];r!==i&&e(n,i,r)}}onStorageEvent(e,n=!1){if(!e.key){this.forAllChangedKeys((o,a,u)=>{this.notifyListeners(o,u)});return}let r=e.key;n?this.detachListener():this.stopPolling();let i=()=>{let o=this.storage.getItem(r);!n&&this.localCache[r]===o||this.notifyListeners(r,o)},s=this.storage.getItem(r);Oo()&&s!==e.newValue&&e.newValue!==e.oldValue?setTimeout(i,aa):i()}notifyListeners(e,n){this.localCache[e]=n;let r=this.listeners[e];if(r)for(let i of Array.from(r))i(n&&JSON.parse(n))}startPolling(){this.stopPolling(),this.pollTimer=setInterval(()=>{this.forAllChangedKeys((e,n,r)=>{this.onStorageEvent(new StorageEvent("storage",{key:e,oldValue:n,newValue:r}),!0)})},oa)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}attachListener(){window.addEventListener("storage",this.boundEventHandler)}detachListener(){window.removeEventListener("storage",this.boundEventHandler)}_addListener(e,n){Object.keys(this.listeners).length===0&&(this.fallbackToPolling?this.startPolling():this.attachListener()),this.listeners[e]||(this.listeners[e]=new Set,this.localCache[e]=this.storage.getItem(e)),this.listeners[e].add(n)}_removeListener(e,n){this.listeners[e]&&(this.listeners[e].delete(n),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&(this.detachListener(),this.stopPolling())}async _set(e,n){await super._set(e,n),this.localCache[e]=JSON.stringify(n)}async _get(e){let n=await super._get(e);return this.localCache[e]=JSON.stringify(n),n}async _remove(e){await super._remove(e),delete this.localCache[e]}};ft.type="LOCAL";var Ii=ft;var ca=1e3;function an(t){let e=t.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),n=RegExp(`${e}=([^;]+)`);return document.cookie.match(n)?.[1]??null}function cn(t){return`${window.location.protocol==="http:"?"__dev_":"__HOST-"}FIREBASE_${t.split(":")[3]}`}var vn=class{constructor(){this.type="COOKIE",this.listenerUnsubscribes=new Map}_getFinalTarget(e){if(typeof window===void 0)return e;let n=new URL(`${window.location.origin}/__cookies__`);return n.searchParams.set("finalTarget",e),n}async _isAvailable(){return typeof isSecureContext=="boolean"&&!isSecureContext||typeof navigator>"u"||typeof document>"u"?!1:navigator.cookieEnabled??!0}async _set(e,n){}async _get(e){if(!this._isAvailable())return null;let n=cn(e);return window.cookieStore?(await window.cookieStore.get(n))?.value:an(n)}async _remove(e){if(!this._isAvailable()||!await this._get(e))return;let r=cn(e);document.cookie=`${r}=;Max-Age=34560000;Partitioned;Secure;SameSite=Strict;Path=/;Priority=High`,await fetch("/__cookies__",{method:"DELETE"}).catch(()=>{})}_addListener(e,n){if(!this._isAvailable())return;let r=cn(e);if(window.cookieStore){let a=c=>{let h=c.changed.find(d=>d.name===r);h&&n(h.value),c.deleted.find(d=>d.name===r)&&n(null)},u=()=>window.cookieStore.removeEventListener("change",a);return this.listenerUnsubscribes.set(n,u),window.cookieStore.addEventListener("change",a)}let i=an(r),s=setInterval(()=>{let a=an(r);a!==i&&(n(a),i=a)},ca),o=()=>clearInterval(s);this.listenerUnsubscribes.set(n,o)}_removeListener(e,n){let r=this.listenerUnsubscribes.get(n);r&&(r(),this.listenerUnsubscribes.delete(n))}};vn.type="COOKIE";var pt=class extends ht{constructor(){super(()=>window.sessionStorage,"SESSION")}_addListener(e,n){}_removeListener(e,n){}};pt.type="SESSION";var Ln=pt;function ua(t){return Promise.all(t.map(async e=>{try{return{fulfilled:!0,value:await e}}catch(n){return{fulfilled:!1,reason:n}}}))}var _t=class t{constructor(e){this.eventTarget=e,this.handlersMap={},this.boundEventHandler=this.handleEvent.bind(this)}static _getInstance(e){let n=this.receivers.find(i=>i.isListeningto(e));if(n)return n;let r=new t(e);return this.receivers.push(r),r}isListeningto(e){return this.eventTarget===e}async handleEvent(e){let n=e,{eventId:r,eventType:i,data:s}=n.data,o=this.handlersMap[i];if(!o?.size)return;n.ports[0].postMessage({status:"ack",eventId:r,eventType:i});let a=Array.from(o).map(async c=>c(n.origin,s)),u=await ua(a);n.ports[0].postMessage({status:"done",eventId:r,eventType:i,response:u})}_subscribe(e,n){Object.keys(this.handlersMap).length===0&&this.eventTarget.addEventListener("message",this.boundEventHandler),this.handlersMap[e]||(this.handlersMap[e]=new Set),this.handlersMap[e].add(n)}_unsubscribe(e,n){this.handlersMap[e]&&n&&this.handlersMap[e].delete(n),(!n||this.handlersMap[e].size===0)&&delete this.handlersMap[e],Object.keys(this.handlersMap).length===0&&this.eventTarget.removeEventListener("message",this.boundEventHandler)}};_t.receivers=[];function Mn(t="",e=10){let n="";for(let r=0;r<e;r++)n+=Math.floor(Math.random()*10);return t+n}var wn=class{constructor(e){this.target=e,this.handlers=new Set}removeMessageHandler(e){e.messageChannel&&(e.messageChannel.port1.removeEventListener("message",e.onMessage),e.messageChannel.port1.close()),this.handlers.delete(e)}async _send(e,n,r=50){let i=typeof MessageChannel<"u"?new MessageChannel:null;if(!i)throw new Error("connection_unavailable");let s,o;return new Promise((a,u)=>{let c=Mn("",20);i.port1.start();let h=setTimeout(()=>{u(new Error("unsupported_event"))},r);o={messageChannel:i,onMessage(l){let d=l;if(d.data.eventId===c)switch(d.data.status){case"ack":clearTimeout(h),s=setTimeout(()=>{u(new Error("timeout"))},3e3);break;case"done":clearTimeout(s),a(d.data.response);break;default:clearTimeout(h),clearTimeout(s),u(new Error("invalid_response"));break}}},this.handlers.add(o),i.port1.addEventListener("message",o.onMessage),this.target.postMessage({eventType:e,eventId:c,data:n},[i.port2])}).finally(()=>{o&&this.removeMessageHandler(o)})}};function F(){return window}function la(t){F().location.href=t}function Ei(){return typeof F().WorkerGlobalScope<"u"&&typeof F().importScripts=="function"}async function da(){if(!navigator?.serviceWorker)return null;try{return(await navigator.serviceWorker.ready).active}catch{return null}}function ha(){return navigator?.serviceWorker?.controller||null}function fa(){return Ei()?self:null}var yi="firebaseLocalStorageDb",pa=1,mt="firebaseLocalStorage",vi="fbase_key",re=class{constructor(e){this.request=e}toPromise(){return new Promise((e,n)=>{this.request.addEventListener("success",()=>{e(this.request.result)}),this.request.addEventListener("error",()=>{n(this.request.error)})})}};function kt(t,e){return t.transaction([mt],e?"readwrite":"readonly").objectStore(mt)}function _a(){let t=indexedDB.deleteDatabase(yi);return new re(t).toPromise()}function Tn(){let t=indexedDB.open(yi,pa);return new Promise((e,n)=>{t.addEventListener("error",()=>{n(t.error)}),t.addEventListener("upgradeneeded",()=>{let r=t.result;try{r.createObjectStore(mt,{keyPath:vi})}catch(i){n(i)}}),t.addEventListener("success",async()=>{let r=t.result;r.objectStoreNames.contains(mt)?e(r):(r.close(),await _a(),e(await Tn()))})})}async function xr(t,e,n){let r=kt(t,!0).put({[vi]:e,value:n});return new re(r).toPromise()}async function ma(t,e){let n=kt(t,!1).get(e),r=await new re(n).toPromise();return r===void 0?null:r.value}function Fr(t,e){let n=kt(t,!0).delete(e);return new re(n).toPromise()}var ga=800,Ia=3,gt=class{constructor(){this.type="LOCAL",this._shouldAllowMigration=!0,this.listeners={},this.localCache={},this.pollTimer=null,this.pendingWrites=0,this.receiver=null,this.sender=null,this.serviceWorkerReceiverAvailable=!1,this.activeServiceWorker=null,this._workerInitializationPromise=this.initializeServiceWorkerMessaging().then(()=>{},()=>{})}async _openDb(){return this.db?this.db:(this.db=await Tn(),this.db)}async _withRetries(e){let n=0;for(;;)try{let r=await this._openDb();return await e(r)}catch(r){if(n++>Ia)throw r;this.db&&(this.db.close(),this.db=void 0)}}async initializeServiceWorkerMessaging(){return Ei()?this.initializeReceiver():this.initializeSender()}async initializeReceiver(){this.receiver=_t._getInstance(fa()),this.receiver._subscribe("keyChanged",async(e,n)=>({keyProcessed:(await this._poll()).includes(n.key)})),this.receiver._subscribe("ping",async(e,n)=>["keyChanged"])}async initializeSender(){if(this.activeServiceWorker=await da(),!this.activeServiceWorker)return;this.sender=new wn(this.activeServiceWorker);let e=await this.sender._send("ping",{},800);e&&e[0]?.fulfilled&&e[0]?.value.includes("keyChanged")&&(this.serviceWorkerReceiverAvailable=!0)}async notifyServiceWorker(e){if(!(!this.sender||!this.activeServiceWorker||ha()!==this.activeServiceWorker))try{await this.sender._send("keyChanged",{key:e},this.serviceWorkerReceiverAvailable?800:50)}catch{}}async _isAvailable(){try{if(!indexedDB)return!1;let e=await Tn();return await xr(e,dt,"1"),await Fr(e,dt),!0}catch{}return!1}async _withPendingWrite(e){this.pendingWrites++;try{await e()}finally{this.pendingWrites--}}async _set(e,n){return this._withPendingWrite(async()=>(await this._withRetries(r=>xr(r,e,n)),this.localCache[e]=n,this.notifyServiceWorker(e)))}async _get(e){let n=await this._withRetries(r=>ma(r,e));return this.localCache[e]=n,n}async _remove(e){return this._withPendingWrite(async()=>(await this._withRetries(n=>Fr(n,e)),delete this.localCache[e],this.notifyServiceWorker(e)))}async _poll(){let e=await this._withRetries(i=>{let s=kt(i,!1).getAll();return new re(s).toPromise()});if(!e)return[];if(this.pendingWrites!==0)return[];let n=[],r=new Set;if(e.length!==0)for(let{fbase_key:i,value:s}of e)r.add(i),JSON.stringify(this.localCache[i])!==JSON.stringify(s)&&(this.notifyListeners(i,s),n.push(i));for(let i of Object.keys(this.localCache))this.localCache[i]&&!r.has(i)&&(this.notifyListeners(i,null),n.push(i));return n}notifyListeners(e,n){this.localCache[e]=n;let r=this.listeners[e];if(r)for(let i of Array.from(r))i(n)}startPolling(){this.stopPolling(),this.pollTimer=setInterval(async()=>this._poll(),ga)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}_addListener(e,n){Object.keys(this.listeners).length===0&&this.startPolling(),this.listeners[e]||(this.listeners[e]=new Set,this._get(e)),this.listeners[e].add(n)}_removeListener(e,n){this.listeners[e]&&(this.listeners[e].delete(n),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&this.stopPolling()}};gt.type="LOCAL";var wi=gt;function Vr(t,e){return k(t,"POST","/v2/accounts/mfaSignIn:start",b(t,e))}function Ea(t,e){return k(t,"POST","/v2/accounts/mfaSignIn:finalize",b(t,e))}function ya(t,e){return k(t,"POST","/v2/accounts/mfaSignIn:finalize",b(t,e))}var tu=di("rcb"),nu=new Q(3e4,6e4);var Qe="recaptcha";async function va(t,e,n){if(!t._getRecaptchaConfig())try{await Vo(t)}catch{console.log("Failed to initialize reCAPTCHA Enterprise config. Triggering the reCAPTCHA v2 verification.")}try{let r;if(typeof e=="string"?r={phoneNumber:e}:r=e,"session"in r){let i=r.session;if("phoneNumber"in r){p(i.type==="enroll",t,"internal-error");let s={idToken:i.credential,phoneEnrollmentInfo:{phoneNumber:r.phoneNumber,clientType:"CLIENT_TYPE_WEB"}};return(await Ce(t,s,"mfaSmsEnrollment",async(c,h)=>{if(h.phoneEnrollmentInfo.captchaResponse===ke){p(n?.type===Qe,c,"argument-error");let l=await un(c,h,n);return Ur(c,l)}return Ur(c,h)},"PHONE_PROVIDER").catch(c=>Promise.reject(c))).phoneSessionInfo.sessionInfo}else{p(i.type==="signin",t,"internal-error");let s=r.multiFactorHint?.uid||r.multiFactorUid;p(s,t,"missing-multi-factor-info");let o={mfaPendingCredential:i.credential,mfaEnrollmentId:s,phoneSignInInfo:{clientType:"CLIENT_TYPE_WEB"}};return(await Ce(t,o,"mfaSmsSignIn",async(h,l)=>{if(l.phoneSignInInfo.captchaResponse===ke){p(n?.type===Qe,h,"argument-error");let d=await un(h,l,n);return Vr(h,d)}return Vr(h,l)},"PHONE_PROVIDER").catch(h=>Promise.reject(h))).phoneResponseInfo.sessionInfo}}else{let i={phoneNumber:r.phoneNumber,clientType:"CLIENT_TYPE_WEB"};return(await Ce(t,i,"sendVerificationCode",async(u,c)=>{if(c.captchaResponse===ke){p(n?.type===Qe,u,"argument-error");let h=await un(u,c,n);return Lr(u,h)}return Lr(u,c)},"PHONE_PROVIDER").catch(u=>Promise.reject(u))).sessionInfo}}finally{n?._reset()}}async function un(t,e,n){p(n.type===Qe,t,"argument-error");let r=await n.verify();p(typeof r=="string",t,"argument-error");let i={...e};if("phoneEnrollmentInfo"in i){let s=i.phoneEnrollmentInfo.phoneNumber,o=i.phoneEnrollmentInfo.captchaResponse,a=i.phoneEnrollmentInfo.clientType,u=i.phoneEnrollmentInfo.recaptchaVersion;return Object.assign(i,{phoneEnrollmentInfo:{phoneNumber:s,recaptchaToken:r,captchaResponse:o,clientType:a,recaptchaVersion:u}}),i}else if("phoneSignInInfo"in i){let s=i.phoneSignInInfo.captchaResponse,o=i.phoneSignInInfo.clientType,a=i.phoneSignInInfo.recaptchaVersion;return Object.assign(i,{phoneSignInInfo:{recaptchaToken:r,captchaResponse:s,clientType:o,recaptchaVersion:a}}),i}else return Object.assign(i,{recaptchaToken:r}),i}var Fe=class t{constructor(e){this.providerId=t.PROVIDER_ID,this.auth=se(e)}verifyPhoneNumber(e,n){return va(this.auth,e,j(n))}static credential(e,n){return Oe._fromVerification(e,n)}static credentialFromResult(e){let n=e;return t.credentialFromTaggedObject(n)}static credentialFromError(e){return t.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{phoneNumber:n,temporaryProof:r}=e;return n&&r?Oe._fromTokenResponse(n,r):null}};Fe.PROVIDER_ID="phone";Fe.PHONE_SIGN_IN_METHOD="phone";function Ti(t,e){return e?W(e):(p(t._popupRedirectResolver,t,"argument-error"),t._popupRedirectResolver)}var Ve=class extends Z{constructor(e){super("custom","custom"),this.params=e}_getIdTokenResponse(e){return pe(e,this._buildIdpRequest())}_linkToIdToken(e,n){return pe(e,this._buildIdpRequest(n))}_getReauthenticationResolver(e){return pe(e,this._buildIdpRequest())}_buildIdpRequest(e){let n={requestUri:this.params.requestUri,sessionId:this.params.sessionId,postBody:this.params.postBody,tenantId:this.params.tenantId,pendingToken:this.params.pendingToken,returnSecureToken:!0,returnIdpCredential:!0};return e&&(n.idToken=e),n}};function wa(t){return na(t.auth,new Ve(t),t.bypassAuthState)}function Ta(t){let{auth:e,user:n}=t;return p(n,e,"internal-error"),ta(n,new Ve(t),t.bypassAuthState)}async function ba(t){let{auth:e,user:n}=t;return p(n,e,"internal-error"),ea(n,new Ve(t),t.bypassAuthState)}var It=class{constructor(e,n,r,i,s=!1){this.auth=e,this.resolver=r,this.user=i,this.bypassAuthState=s,this.pendingPromise=null,this.eventManager=null,this.filter=Array.isArray(n)?n:[n]}execute(){return new Promise(async(e,n)=>{this.pendingPromise={resolve:e,reject:n};try{this.eventManager=await this.resolver._initialize(this.auth),await this.onExecution(),this.eventManager.registerConsumer(this)}catch(r){this.reject(r)}})}async onAuthEvent(e){let{urlResponse:n,sessionId:r,postBody:i,tenantId:s,error:o,type:a}=e;if(o){this.reject(o);return}let u={auth:this.auth,requestUri:n,sessionId:r,tenantId:s||void 0,postBody:i||void 0,user:this.user,bypassAuthState:this.bypassAuthState};try{this.resolve(await this.getIdpTask(a)(u))}catch(c){this.reject(c)}}onError(e){this.reject(e)}getIdpTask(e){switch(e){case"signInViaPopup":case"signInViaRedirect":return wa;case"linkViaPopup":case"linkViaRedirect":return ba;case"reauthViaPopup":case"reauthViaRedirect":return Ta;default:R(this.auth,"internal-error")}}resolve(e){B(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.resolve(e),this.unregisterAndCleanUp()}reject(e){B(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.reject(e),this.unregisterAndCleanUp()}unregisterAndCleanUp(){this.eventManager&&this.eventManager.unregisterConsumer(this),this.pendingPromise=null,this.cleanUp()}};var Aa=new Q(2e3,1e4);async function Un(t,e,n){if(N(t.app))return Promise.reject(O(t,"operation-not-supported-in-this-environment"));let r=se(t);Io(t,e,De);let i=Ti(r,n);return new Et(r,"signInViaPopup",e,i).executeNotNull()}var Et=class t extends It{constructor(e,n,r,i,s){super(e,n,i,s),this.provider=r,this.authWindow=null,this.pollId=null,t.currentPopupAction&&t.currentPopupAction.cancel(),t.currentPopupAction=this}async executeNotNull(){let e=await this.execute();return p(e,this.auth,"internal-error"),e}async onExecution(){B(this.filter.length===1,"Popup operations only handle one event");let e=Mn();this.authWindow=await this.resolver._openPopup(this.auth,this.provider,this.filter[0],e),this.authWindow.associatedEvent=e,this.resolver._originValidation(this.auth).catch(n=>{this.reject(n)}),this.resolver._isIframeWebStorageSupported(this.auth,n=>{n||this.reject(O(this.auth,"web-storage-unsupported"))}),this.pollUserCancellation()}get eventId(){return this.authWindow?.associatedEvent||null}cancel(){this.reject(O(this.auth,"cancelled-popup-request"))}cleanUp(){this.authWindow&&this.authWindow.close(),this.pollId&&window.clearTimeout(this.pollId),this.authWindow=null,this.pollId=null,t.currentPopupAction=null}pollUserCancellation(){let e=()=>{if(this.authWindow?.window?.closed){this.pollId=window.setTimeout(()=>{this.pollId=null,this.reject(O(this.auth,"popup-closed-by-user"))},8e3);return}this.pollId=window.setTimeout(e,Aa.get())};e()}};Et.currentPopupAction=null;var Sa="pendingRedirect",Ze=new Map,bn=class extends It{constructor(e,n,r=!1){super(e,["signInViaRedirect","linkViaRedirect","reauthViaRedirect","unknown"],n,void 0,r),this.eventId=null}async execute(){let e=Ze.get(this.auth._key());if(!e){try{let r=await ka(this.resolver,this.auth)?await super.execute():null;e=()=>Promise.resolve(r)}catch(n){e=()=>Promise.reject(n)}Ze.set(this.auth._key(),e)}return this.bypassAuthState||Ze.set(this.auth._key(),()=>Promise.resolve(null)),e()}async onAuthEvent(e){if(e.type==="signInViaRedirect")return super.onAuthEvent(e);if(e.type==="unknown"){this.resolve(null);return}if(e.eventId){let n=await this.auth._redirectUserForId(e.eventId);if(n)return this.user=n,super.onAuthEvent(e);this.resolve(null)}}async onExecution(){}cleanUp(){}};async function ka(t,e){let n=Pa(e),r=Ra(t);if(!await r._isAvailable())return!1;let i=await r._get(n)==="true";return await r._remove(n),i}function Ca(t,e){Ze.set(t._key(),e)}function Ra(t){return W(t._redirectPersistence)}function Pa(t){return Xe(Sa,t.config.apiKey,t.name)}async function Na(t,e,n=!1){if(N(t.app))return Promise.reject(X(t));let r=se(t),i=Ti(r,e),o=await new bn(r,i,n).execute();return o&&!n&&(delete o.user._redirectEventId,await r._persistUserIfCurrent(o.user),await r._setRedirectUser(null,e)),o}var Oa=10*60*1e3,An=class{constructor(e){this.auth=e,this.cachedEventUids=new Set,this.consumers=new Set,this.queuedRedirectEvent=null,this.hasHandledPotentialRedirect=!1,this.lastProcessedEventTime=Date.now()}registerConsumer(e){this.consumers.add(e),this.queuedRedirectEvent&&this.isEventForConsumer(this.queuedRedirectEvent,e)&&(this.sendToConsumer(this.queuedRedirectEvent,e),this.saveEventToCache(this.queuedRedirectEvent),this.queuedRedirectEvent=null)}unregisterConsumer(e){this.consumers.delete(e)}onEvent(e){if(this.hasEventBeenHandled(e))return!1;let n=!1;return this.consumers.forEach(r=>{this.isEventForConsumer(e,r)&&(n=!0,this.sendToConsumer(e,r),this.saveEventToCache(e))}),this.hasHandledPotentialRedirect||!Da(e)||(this.hasHandledPotentialRedirect=!0,n||(this.queuedRedirectEvent=e,n=!0)),n}sendToConsumer(e,n){if(e.error&&!bi(e)){let r=e.error.code?.split("auth/")[1]||"internal-error";n.onError(O(this.auth,r))}else n.onAuthEvent(e)}isEventForConsumer(e,n){let r=n.eventId===null||!!e.eventId&&e.eventId===n.eventId;return n.filter.includes(e.type)&&r}hasEventBeenHandled(e){return Date.now()-this.lastProcessedEventTime>=Oa&&this.cachedEventUids.clear(),this.cachedEventUids.has(Hr(e))}saveEventToCache(e){this.cachedEventUids.add(Hr(e)),this.lastProcessedEventTime=Date.now()}};function Hr(t){return[t.type,t.eventId,t.sessionId,t.tenantId].filter(e=>e).join("-")}function bi({type:t,error:e}){return t==="unknown"&&e?.code==="auth/no-auth-event"}function Da(t){switch(t.type){case"signInViaRedirect":case"linkViaRedirect":case"reauthViaRedirect":return!0;case"unknown":return bi(t);default:return!1}}async function La(t,e={}){return k(t,"GET","/v1/projects",e)}var Ma=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/,Ua=/^https?/;async function xa(t){if(t.config.emulator)return;let{authorizedDomains:e}=await La(t);for(let n of e)try{if(Fa(n))return}catch{}R(t,"unauthorized-domain")}function Fa(t){let e=dn(),{protocol:n,hostname:r}=new URL(e);if(t.startsWith("chrome-extension://")){let o=new URL(t);return o.hostname===""&&r===""?n==="chrome-extension:"&&t.replace("chrome-extension://","")===e.replace("chrome-extension://",""):n==="chrome-extension:"&&o.hostname===r}if(!Ua.test(n))return!1;if(Ma.test(t))return r===t;let i=t.replace(/\./g,"\\.");return new RegExp("^(.+\\."+i+"|"+i+")$","i").test(r)}var Va=new Q(3e4,6e4);function Wr(){let t=F().___jsl;if(t?.H){for(let e of Object.keys(t.H))if(t.H[e].r=t.H[e].r||[],t.H[e].L=t.H[e].L||[],t.H[e].r=[...t.H[e].L],t.CP)for(let n=0;n<t.CP.length;n++)t.CP[n]=null}}function Ha(t){return new Promise((e,n)=>{function r(){Wr(),gapi.load("gapi.iframes",{callback:()=>{e(gapi.iframes.getContext())},ontimeout:()=>{Wr(),n(O(t,"network-request-failed"))},timeout:Va.get()})}if(F().gapi?.iframes?.Iframe)e(gapi.iframes.getContext());else if(F().gapi?.load)r();else{let i=di("iframefcb");return F()[i]=()=>{gapi.load?r():n(O(t,"network-request-failed"))},li(`${xo()}?onload=${i}`).catch(s=>n(s))}}).catch(e=>{throw et=null,e})}var et=null;function Wa(t){return et=et||Ha(t),et}var Ba=new Q(5e3,15e3),$a="__/auth/iframe",za="emulator/auth/iframe",ja={style:{position:"absolute",top:"-100px",width:"1px",height:"1px"},"aria-hidden":"true",tabindex:"-1"},qa=new Map([["identitytoolkit.googleapis.com","p"],["staging-identitytoolkit.sandbox.googleapis.com","s"],["test-identitytoolkit.sandbox.googleapis.com","t"]]);function Ga(t){let e=t.config;p(e.authDomain,t,"auth-domain-config-required");let n=e.emulator?Nn(e,za):`https://${t.config.authDomain}/${$a}`,r={apiKey:e.apiKey,appName:t.name,v:fe},i=qa.get(t.config.apiHost);i&&(r.eid=i);let s=t._getFrameworks();return s.length&&(r.fw=s.join(",")),`${n}?${ce(r).slice(1)}`}async function Ka(t){let e=await Wa(t),n=F().gapi;return p(n,t,"internal-error"),e.open({where:document.body,url:Ga(t),messageHandlersFilter:n.iframes.CROSS_ORIGIN_IFRAMES_FILTER,attributes:ja,dontclear:!0},r=>new Promise(async(i,s)=>{await r.restyle({setHideOnLeave:!1});let o=O(t,"network-request-failed"),a=F().setTimeout(()=>{s(o)},Ba.get());function u(){F().clearTimeout(a),i(r)}r.ping(u).then(u,()=>{s(o)})}))}var Ja={location:"yes",resizable:"yes",statusbar:"yes",toolbar:"no"},Ya=500,Xa=600,Qa="_blank",Za="http://localhost",yt=class{constructor(e){this.window=e,this.associatedEvent=null}close(){if(this.window)try{this.window.close()}catch{}}};function ec(t,e,n,r=Ya,i=Xa){let s=Math.max((window.screen.availHeight-i)/2,0).toString(),o=Math.max((window.screen.availWidth-r)/2,0).toString(),a="",u={...Ja,width:r.toString(),height:i.toString(),top:s,left:o},c=S().toLowerCase();n&&(a=ri(c)?Qa:n),ti(c)&&(e=e||Za,u.scrollbars="yes");let h=Object.entries(u).reduce((d,[f,g])=>`${d}${f}=${g},`,"");if(No(c)&&a!=="_self")return tc(e||"",a),new yt(null);let l=window.open(e||"",a,h);p(l,t,"popup-blocked");try{l.focus()}catch{}return new yt(l)}function tc(t,e){let n=document.createElement("a");n.href=t,n.target=e;let r=document.createEvent("MouseEvent");r.initMouseEvent("click",!0,!0,window,1,0,0,0,0,!1,!1,!1,!1,1,null),n.dispatchEvent(r)}var nc="__/auth/handler",rc="emulator/auth/handler",ic=encodeURIComponent("fac");async function Br(t,e,n,r,i,s){p(t.config.authDomain,t,"auth-domain-config-required"),p(t.config.apiKey,t,"invalid-api-key");let o={apiKey:t.config.apiKey,appName:t.name,authType:n,redirectUrl:r,v:fe,eventId:i};if(e instanceof De){e.setDefaultLanguage(t.languageCode),o.providerId=e.providerId||"",dr(e.getCustomParameters())||(o.customParameters=JSON.stringify(e.getCustomParameters()));for(let[h,l]of Object.entries(s||{}))o[h]=l}if(e instanceof te){let h=e.getScopes().filter(l=>l!=="");h.length>0&&(o.scopes=h.join(","))}t.tenantId&&(o.tid=t.tenantId);let a=o;for(let h of Object.keys(a))a[h]===void 0&&delete a[h];let u=await t._getAppCheckToken(),c=u?`#${ic}=${encodeURIComponent(u)}`:"";return`${sc(t)}?${ce(a).slice(1)}${c}`}function sc({config:t}){return t.emulator?Nn(t,rc):`https://${t.authDomain}/${nc}`}var ln="webStorageSupport",Sn=class{constructor(){this.eventManagers={},this.iframes={},this.originValidationPromises={},this._redirectPersistence=Ln,this._completeRedirectFn=Na,this._overrideRedirectResult=Ca}async _openPopup(e,n,r,i){B(this.eventManagers[e._key()]?.manager,"_initialize() not called before _openPopup()");let s=await Br(e,n,r,dn(),i);return ec(e,s,Mn())}async _openRedirect(e,n,r,i){await this._originValidation(e);let s=await Br(e,n,r,dn(),i);return la(s),new Promise(()=>{})}_initialize(e){let n=e._key();if(this.eventManagers[n]){let{manager:i,promise:s}=this.eventManagers[n];return i?Promise.resolve(i):(B(s,"If manager is not set, promise should be"),s)}let r=this.initAndGetManager(e);return this.eventManagers[n]={promise:r},r.catch(()=>{delete this.eventManagers[n]}),r}async initAndGetManager(e){let n=await Ka(e),r=new An(e);return n.register("authEvent",i=>(p(i?.authEvent,e,"invalid-auth-event"),{status:r.onEvent(i.authEvent)?"ACK":"ERROR"}),gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER),this.eventManagers[e._key()]={manager:r},this.iframes[e._key()]=n,r}_isIframeWebStorageSupported(e,n){this.iframes[e._key()].send(ln,{type:ln},i=>{let s=i?.[0]?.[ln];s!==void 0&&n(!!s),R(e,"internal-error")},gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER)}_originValidation(e){let n=e._key();return this.originValidationPromises[n]||(this.originValidationPromises[n]=xa(e)),this.originValidationPromises[n]}get _shouldInitProactively(){return ci()||ni()||Dn()}},Ai=Sn,vt=class{constructor(e){this.factorId=e}_process(e,n,r){switch(n.type){case"enroll":return this._finalizeEnroll(e,n.credential,r);case"signin":return this._finalizeSignIn(e,n.credential);default:return x("unexpected MultiFactorSessionType")}}},kn=class t extends vt{constructor(e){super("phone"),this.credential=e}static _fromCredential(e){return new t(e)}_finalizeEnroll(e,n,r){return ra(e,{idToken:n,displayName:r,phoneVerificationInfo:this.credential._makeVerificationRequest()})}_finalizeSignIn(e,n){return Ea(e,{mfaPendingCredential:n,phoneVerificationInfo:this.credential._makeVerificationRequest()})}},wt=class{constructor(){}static assertion(e){return kn._fromCredential(e)}};wt.FACTOR_ID="phone";var Tt=class{static assertionForEnrollment(e,n){return bt._fromSecret(e,n)}static assertionForSignIn(e,n){return bt._fromEnrollmentId(e,n)}static async generateSecret(e){let n=e;p(typeof n.user?.auth<"u","internal-error");let r=await ia(n.user.auth,{idToken:n.credential,totpEnrollmentInfo:{}});return At._fromStartTotpMfaEnrollmentResponse(r,n.user.auth)}};Tt.FACTOR_ID="totp";var bt=class t extends vt{constructor(e,n,r){super("totp"),this.otp=e,this.enrollmentId=n,this.secret=r}static _fromSecret(e,n){return new t(n,void 0,e)}static _fromEnrollmentId(e,n){return new t(n,e)}async _finalizeEnroll(e,n,r){return p(typeof this.secret<"u",e,"argument-error"),sa(e,{idToken:n,displayName:r,totpVerificationInfo:this.secret._makeTotpVerificationInfo(this.otp)})}async _finalizeSignIn(e,n){p(this.enrollmentId!==void 0&&this.otp!==void 0,e,"argument-error");let r={verificationCode:this.otp};return ya(e,{mfaPendingCredential:n,mfaEnrollmentId:this.enrollmentId,totpVerificationInfo:r})}},At=class t{constructor(e,n,r,i,s,o,a){this.sessionInfo=o,this.auth=a,this.secretKey=e,this.hashingAlgorithm=n,this.codeLength=r,this.codeIntervalSeconds=i,this.enrollmentCompletionDeadline=s}static _fromStartTotpMfaEnrollmentResponse(e,n){return new t(e.totpSessionInfo.sharedSecretKey,e.totpSessionInfo.hashingAlgorithm,e.totpSessionInfo.verificationCodeLength,e.totpSessionInfo.periodSec,new Date(e.totpSessionInfo.finalizeEnrollmentTime).toUTCString(),e.totpSessionInfo.sessionInfo,n)}_makeTotpVerificationInfo(e){return{sessionInfo:this.sessionInfo,verificationCode:e}}generateQrCodeUrl(e,n){let r=!1;return(Je(e)||Je(n))&&(r=!0),r&&(Je(e)&&(e=this.auth.currentUser?.email||"unknownuser"),Je(n)&&(n=this.auth.name)),`otpauth://totp/${n}:${e}?secret=${this.secretKey}&issuer=${n}&algorithm=${this.hashingAlgorithm}&digits=${this.codeLength}`}};function Je(t){return typeof t>"u"||t?.length===0}var $r="@firebase/auth",zr="1.11.0";var Cn=class{constructor(e){this.auth=e,this.internalListeners=new Map}getUid(){return this.assertAuthConfigured(),this.auth.currentUser?.uid||null}async getToken(e){return this.assertAuthConfigured(),await this.auth._initializationPromise,this.auth.currentUser?{accessToken:await this.auth.currentUser.getIdToken(e)}:null}addAuthTokenListener(e){if(this.assertAuthConfigured(),this.internalListeners.has(e))return;let n=this.auth.onIdTokenChanged(r=>{e(r?.stsTokenManager.accessToken||null)});this.internalListeners.set(e,n),this.updateProactiveRefresh()}removeAuthTokenListener(e){this.assertAuthConfigured();let n=this.internalListeners.get(e);n&&(this.internalListeners.delete(e),n(),this.updateProactiveRefresh())}assertAuthConfigured(){p(this.auth._initializationPromise,"dependent-sdk-initialized-before-auth")}updateProactiveRefresh(){this.internalListeners.size>0?this.auth._startProactiveRefresh():this.auth._stopProactiveRefresh()}};function oc(t){switch(t){case"Node":return"node";case"ReactNative":return"rn";case"Worker":return"webworker";case"Cordova":return"cordova";case"WebExtension":return"web-extension";default:return}}function ac(t){he(new M("auth",(e,{options:n})=>{let r=e.getProvider("app").getImmediate(),i=e.getProvider("heartbeat"),s=e.getProvider("app-check-internal"),{apiKey:o,authDomain:a}=r.options;p(o&&!o.includes(":"),"invalid-api-key",{appName:r.name});let u={apiKey:o,authDomain:a,clientPlatform:t,apiHost:"identitytoolkit.googleapis.com",tokenApiHost:"securetoken.googleapis.com",apiScheme:"https",sdkClientVersion:ui(t)},c=new gn(r,i,s,u);return Ho(c,n),c},"PUBLIC").setInstantiationMode("EXPLICIT").setInstanceCreatedCallback((e,n,r)=>{e.getProvider("auth-internal").initialize()})),he(new M("auth-internal",e=>{let n=se(e.getProvider("auth").getImmediate());return(r=>new Cn(r))(n)},"PRIVATE").setInstantiationMode("EXPLICIT")),G($r,zr,oc(t)),G($r,zr,"esm2020")}var cc=5*60,uc=Bt("authIdTokenMaxAge")||cc,jr=null,lc=t=>async e=>{let n=e&&await e.getIdTokenResult(),r=n&&(new Date().getTime()-Date.parse(n.issuedAtTime))/1e3;if(r&&r>uc)return;let i=n?.token;jr!==i&&(jr=i,await fetch(t,{method:i?"POST":"DELETE",headers:i?{Authorization:`Bearer ${i}`}:{}}))};function xn(t=Ar()){let e=rn(t,"auth");if(e.isInitialized())return e.getImmediate();let n=hi(t,{popupRedirectResolver:Ai,persistence:[wi,Ii,Ln]}),r=Bt("authTokenSyncURL");if(r&&typeof isSecureContext=="boolean"&&isSecureContext){let s=new URL(r,location.origin);if(location.origin===s.origin){let o=lc(s.toString());gi(n,o,()=>o(n.currentUser)),mi(n,a=>o(a))}}let i=tr("auth");return i&&fi(n,`http://${i}`),n}function dc(){return document.getElementsByTagName("head")?.[0]??document}Mo({loadJS(t){return new Promise((e,n)=>{let r=document.createElement("script");r.setAttribute("src",t),r.onload=e,r.onerror=i=>{let s=O("internal-error");s.customData=i,n(s)},r.type="text/javascript",r.charset="UTF-8",dc().appendChild(r)})},gapiScript:"https://apis.google.com/js/api.js",recaptchaV2Script:"https://www.google.com/recaptcha/api.js",recaptchaEnterpriseScript:"https://www.google.com/recaptcha/enterprise.js?render="});ac("Browser");var Ot,I,Pi,hc,oe,Si,Ni,Oi,Di,Wn,Fn,Vn,fc,He={},Li=[],pc=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Dt=Array.isArray;function $(t,e){for(var n in e)t[n]=e[n];return t}function Bn(t){t&&t.parentNode&&t.parentNode.removeChild(t)}function _c(t,e,n){var r,i,s,o={};for(s in e)s=="key"?r=e[s]:s=="ref"?i=e[s]:o[s]=e[s];if(arguments.length>2&&(o.children=arguments.length>3?Ot.call(arguments,2):n),typeof t=="function"&&t.defaultProps!=null)for(s in t.defaultProps)o[s]===void 0&&(o[s]=t.defaultProps[s]);return Rt(t,o,r,i,null)}function Rt(t,e,n,r,i){var s={type:t,props:e,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++Pi,__i:-1,__u:0};return i==null&&I.vnode!=null&&I.vnode(s),s}function ge(t){return t.children}function Pt(t,e){this.props=t,this.context=e}function me(t,e){if(e==null)return t.__?me(t.__,t.__i+1):null;for(var n;e<t.__k.length;e++)if((n=t.__k[e])!=null&&n.__e!=null)return n.__e;return typeof t.type=="function"?me(t):null}function Mi(t){var e,n;if((t=t.__)!=null&&t.__c!=null){for(t.__e=t.__c.base=null,e=0;e<t.__k.length;e++)if((n=t.__k[e])!=null&&n.__e!=null){t.__e=t.__c.base=n.__e;break}return Mi(t)}}function ki(t){(!t.__d&&(t.__d=!0)&&oe.push(t)&&!Nt.__r++||Si!=I.debounceRendering)&&((Si=I.debounceRendering)||Ni)(Nt)}function Nt(){for(var t,e,n,r,i,s,o,a=1;oe.length;)oe.length>a&&oe.sort(Oi),t=oe.shift(),a=oe.length,t.__d&&(n=void 0,i=(r=(e=t).__v).__e,s=[],o=[],e.__P&&((n=$({},r)).__v=r.__v+1,I.vnode&&I.vnode(n),$n(e.__P,n,r,e.__n,e.__P.namespaceURI,32&r.__u?[i]:null,s,i??me(r),!!(32&r.__u),o),n.__v=r.__v,n.__.__k[n.__i]=n,Fi(s,n,o),n.__e!=i&&Mi(n)));Nt.__r=0}function Ui(t,e,n,r,i,s,o,a,u,c,h){var l,d,f,g,A,y,_,m=r&&r.__k||Li,C=e.length;for(u=mc(n,e,m,u,C),l=0;l<C;l++)(f=n.__k[l])!=null&&(d=f.__i==-1?He:m[f.__i]||He,f.__i=l,y=$n(t,f,d,i,s,o,a,u,c,h),g=f.__e,f.ref&&d.ref!=f.ref&&(d.ref&&zn(d.ref,null,f),h.push(f.ref,f.__c||g,f)),A==null&&g!=null&&(A=g),(_=!!(4&f.__u))||d.__k===f.__k?u=xi(f,u,t,_):typeof f.type=="function"&&y!==void 0?u=y:g&&(u=g.nextSibling),f.__u&=-7);return n.__e=A,u}function mc(t,e,n,r,i){var s,o,a,u,c,h=n.length,l=h,d=0;for(t.__k=new Array(i),s=0;s<i;s++)(o=e[s])!=null&&typeof o!="boolean"&&typeof o!="function"?(u=s+d,(o=t.__k[s]=typeof o=="string"||typeof o=="number"||typeof o=="bigint"||o.constructor==String?Rt(null,o,null,null,null):Dt(o)?Rt(ge,{children:o},null,null,null):o.constructor==null&&o.__b>0?Rt(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):o).__=t,o.__b=t.__b+1,a=null,(c=o.__i=gc(o,n,u,l))!=-1&&(l--,(a=n[c])&&(a.__u|=2)),a==null||a.__v==null?(c==-1&&(i>h?d--:i<h&&d++),typeof o.type!="function"&&(o.__u|=4)):c!=u&&(c==u-1?d--:c==u+1?d++:(c>u?d--:d++,o.__u|=4))):t.__k[s]=null;if(l)for(s=0;s<h;s++)(a=n[s])!=null&&!(2&a.__u)&&(a.__e==r&&(r=me(a)),Hi(a,a));return r}function xi(t,e,n,r){var i,s;if(typeof t.type=="function"){for(i=t.__k,s=0;i&&s<i.length;s++)i[s]&&(i[s].__=t,e=xi(i[s],e,n,r));return e}t.__e!=e&&(r&&(e&&t.type&&!e.parentNode&&(e=me(t)),n.insertBefore(t.__e,e||null)),e=t.__e);do e=e&&e.nextSibling;while(e!=null&&e.nodeType==8);return e}function gc(t,e,n,r){var i,s,o,a=t.key,u=t.type,c=e[n],h=c!=null&&(2&c.__u)==0;if(c===null&&t.key==null||h&&a==c.key&&u==c.type)return n;if(r>(h?1:0)){for(i=n-1,s=n+1;i>=0||s<e.length;)if((c=e[o=i>=0?i--:s++])!=null&&!(2&c.__u)&&a==c.key&&u==c.type)return o}return-1}function Ci(t,e,n){e[0]=="-"?t.setProperty(e,n??""):t[e]=n==null?"":typeof n!="number"||pc.test(e)?n:n+"px"}function Ct(t,e,n,r,i){var s,o;e:if(e=="style")if(typeof n=="string")t.style.cssText=n;else{if(typeof r=="string"&&(t.style.cssText=r=""),r)for(e in r)n&&e in n||Ci(t.style,e,"");if(n)for(e in n)r&&n[e]==r[e]||Ci(t.style,e,n[e])}else if(e[0]=="o"&&e[1]=="n")s=e!=(e=e.replace(Di,"$1")),o=e.toLowerCase(),e=o in t||e=="onFocusOut"||e=="onFocusIn"?o.slice(2):e.slice(2),t.l||(t.l={}),t.l[e+s]=n,n?r?n.u=r.u:(n.u=Wn,t.addEventListener(e,s?Vn:Fn,s)):t.removeEventListener(e,s?Vn:Fn,s);else{if(i=="http://www.w3.org/2000/svg")e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!="width"&&e!="height"&&e!="href"&&e!="list"&&e!="form"&&e!="tabIndex"&&e!="download"&&e!="rowSpan"&&e!="colSpan"&&e!="role"&&e!="popover"&&e in t)try{t[e]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&e[4]!="-"?t.removeAttribute(e):t.setAttribute(e,e=="popover"&&n==1?"":n))}}function Ri(t){return function(e){if(this.l){var n=this.l[e.type+t];if(e.t==null)e.t=Wn++;else if(e.t<n.u)return;return n(I.event?I.event(e):e)}}}function $n(t,e,n,r,i,s,o,a,u,c){var h,l,d,f,g,A,y,_,m,C,D,Be,Ie,Jn,$e,Ee,Mt,L=e.type;if(e.constructor!=null)return null;128&n.__u&&(u=!!(32&n.__u),s=[a=e.__e=n.__e]),(h=I.__b)&&h(e);e:if(typeof L=="function")try{if(_=e.props,m="prototype"in L&&L.prototype.render,C=(h=L.contextType)&&r[h.__c],D=h?C?C.props.value:h.__:r,n.__c?y=(l=e.__c=n.__c).__=l.__E:(m?e.__c=l=new L(_,D):(e.__c=l=new Pt(_,D),l.constructor=L,l.render=Ec),C&&C.sub(l),l.props=_,l.state||(l.state={}),l.context=D,l.__n=r,d=l.__d=!0,l.__h=[],l._sb=[]),m&&l.__s==null&&(l.__s=l.state),m&&L.getDerivedStateFromProps!=null&&(l.__s==l.state&&(l.__s=$({},l.__s)),$(l.__s,L.getDerivedStateFromProps(_,l.__s))),f=l.props,g=l.state,l.__v=e,d)m&&L.getDerivedStateFromProps==null&&l.componentWillMount!=null&&l.componentWillMount(),m&&l.componentDidMount!=null&&l.__h.push(l.componentDidMount);else{if(m&&L.getDerivedStateFromProps==null&&_!==f&&l.componentWillReceiveProps!=null&&l.componentWillReceiveProps(_,D),!l.__e&&l.shouldComponentUpdate!=null&&l.shouldComponentUpdate(_,l.__s,D)===!1||e.__v==n.__v){for(e.__v!=n.__v&&(l.props=_,l.state=l.__s,l.__d=!1),e.__e=n.__e,e.__k=n.__k,e.__k.some(function(ae){ae&&(ae.__=e)}),Be=0;Be<l._sb.length;Be++)l.__h.push(l._sb[Be]);l._sb=[],l.__h.length&&o.push(l);break e}l.componentWillUpdate!=null&&l.componentWillUpdate(_,l.__s,D),m&&l.componentDidUpdate!=null&&l.__h.push(function(){l.componentDidUpdate(f,g,A)})}if(l.context=D,l.props=_,l.__P=t,l.__e=!1,Ie=I.__r,Jn=0,m){for(l.state=l.__s,l.__d=!1,Ie&&Ie(e),h=l.render(l.props,l.state,l.context),$e=0;$e<l._sb.length;$e++)l.__h.push(l._sb[$e]);l._sb=[]}else do l.__d=!1,Ie&&Ie(e),h=l.render(l.props,l.state,l.context),l.state=l.__s;while(l.__d&&++Jn<25);l.state=l.__s,l.getChildContext!=null&&(r=$($({},r),l.getChildContext())),m&&!d&&l.getSnapshotBeforeUpdate!=null&&(A=l.getSnapshotBeforeUpdate(f,g)),Ee=h,h!=null&&h.type===ge&&h.key==null&&(Ee=Vi(h.props.children)),a=Ui(t,Dt(Ee)?Ee:[Ee],e,n,r,i,s,o,a,u,c),l.base=e.__e,e.__u&=-161,l.__h.length&&o.push(l),y&&(l.__E=l.__=null)}catch(ae){if(e.__v=null,u||s!=null)if(ae.then){for(e.__u|=u?160:128;a&&a.nodeType==8&&a.nextSibling;)a=a.nextSibling;s[s.indexOf(a)]=null,e.__e=a}else{for(Mt=s.length;Mt--;)Bn(s[Mt]);Hn(e)}else e.__e=n.__e,e.__k=n.__k,ae.then||Hn(e);I.__e(ae,e,n)}else s==null&&e.__v==n.__v?(e.__k=n.__k,e.__e=n.__e):a=e.__e=Ic(n.__e,e,n,r,i,s,o,u,c);return(h=I.diffed)&&h(e),128&e.__u?void 0:a}function Hn(t){t&&t.__c&&(t.__c.__e=!0),t&&t.__k&&t.__k.forEach(Hn)}function Fi(t,e,n){for(var r=0;r<n.length;r++)zn(n[r],n[++r],n[++r]);I.__c&&I.__c(e,t),t.some(function(i){try{t=i.__h,i.__h=[],t.some(function(s){s.call(i)})}catch(s){I.__e(s,i.__v)}})}function Vi(t){return typeof t!="object"||t==null||t.__b&&t.__b>0?t:Dt(t)?t.map(Vi):$({},t)}function Ic(t,e,n,r,i,s,o,a,u){var c,h,l,d,f,g,A,y=n.props,_=e.props,m=e.type;if(m=="svg"?i="http://www.w3.org/2000/svg":m=="math"?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),s!=null){for(c=0;c<s.length;c++)if((f=s[c])&&"setAttribute"in f==!!m&&(m?f.localName==m:f.nodeType==3)){t=f,s[c]=null;break}}if(t==null){if(m==null)return document.createTextNode(_);t=document.createElementNS(i,m,_.is&&_),a&&(I.__m&&I.__m(e,s),a=!1),s=null}if(m==null)y===_||a&&t.data==_||(t.data=_);else{if(s=s&&Ot.call(t.childNodes),y=n.props||He,!a&&s!=null)for(y={},c=0;c<t.attributes.length;c++)y[(f=t.attributes[c]).name]=f.value;for(c in y)if(f=y[c],c!="children"){if(c=="dangerouslySetInnerHTML")l=f;else if(!(c in _)){if(c=="value"&&"defaultValue"in _||c=="checked"&&"defaultChecked"in _)continue;Ct(t,c,null,f,i)}}for(c in _)f=_[c],c=="children"?d=f:c=="dangerouslySetInnerHTML"?h=f:c=="value"?g=f:c=="checked"?A=f:a&&typeof f!="function"||y[c]===f||Ct(t,c,f,y[c],i);if(h)a||l&&(h.__html==l.__html||h.__html==t.innerHTML)||(t.innerHTML=h.__html),e.__k=[];else if(l&&(t.innerHTML=""),Ui(e.type=="template"?t.content:t,Dt(d)?d:[d],e,n,r,m=="foreignObject"?"http://www.w3.org/1999/xhtml":i,s,o,s?s[0]:n.__k&&me(n,0),a,u),s!=null)for(c=s.length;c--;)Bn(s[c]);a||(c="value",m=="progress"&&g==null?t.removeAttribute("value"):g!=null&&(g!==t[c]||m=="progress"&&!g||m=="option"&&g!=y[c])&&Ct(t,c,g,y[c],i),c="checked",A!=null&&A!=t[c]&&Ct(t,c,A,y[c],i))}return t}function zn(t,e,n){try{if(typeof t=="function"){var r=typeof t.__u=="function";r&&t.__u(),r&&e==null||(t.__u=t(e))}else t.current=e}catch(i){I.__e(i,n)}}function Hi(t,e,n){var r,i;if(I.unmount&&I.unmount(t),(r=t.ref)&&(r.current&&r.current!=t.__e||zn(r,null,e)),(r=t.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(s){I.__e(s,e)}r.base=r.__P=null}if(r=t.__k)for(i=0;i<r.length;i++)r[i]&&Hi(r[i],e,n||typeof t.type!="function");n||Bn(t.__e),t.__c=t.__=t.__e=void 0}function Ec(t,e,n){return this.constructor(t,n)}function Wi(t,e,n){var r,i,s,o;e==document&&(e=document.documentElement),I.__&&I.__(t,e),i=(r=typeof n=="function")?null:n&&n.__k||e.__k,s=[],o=[],$n(e,t=(!r&&n||e).__k=_c(ge,null,[t]),i||He,He,e.namespaceURI,!r&&n?[n]:i?null:e.firstChild?Ot.call(e.childNodes):null,s,!r&&n?n:i?i.__e:e.firstChild,r,o),Fi(s,t,o)}Ot=Li.slice,I={__e:function(t,e,n,r){for(var i,s,o;e=e.__;)if((i=e.__c)&&!i.__)try{if((s=i.constructor)&&s.getDerivedStateFromError!=null&&(i.setState(s.getDerivedStateFromError(t)),o=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(t,r||{}),o=i.__d),o)return i.__E=i}catch(a){t=a}throw t}},Pi=0,hc=function(t){return t!=null&&t.constructor==null},Pt.prototype.setState=function(t,e){var n;n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=$({},this.state),typeof t=="function"&&(t=t($({},n),this.props)),t&&$(n,t),t!=null&&this.__v&&(e&&this._sb.push(e),ki(this))},Pt.prototype.forceUpdate=function(t){this.__v&&(this.__e=!0,t&&this.__h.push(t),ki(this))},Pt.prototype.render=ge,oe=[],Ni=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Oi=function(t,e){return t.__v.__b-e.__v.__b},Nt.__r=0,Di=/(PointerCapture)$|Capture$/i,Wn=0,Fn=Ri(!1),Vn=Ri(!0),fc=0;var qn,v,jn,Bi,Gn=0,Yi=[],T=I,$i=T.__b,zi=T.__r,ji=T.diffed,qi=T.__c,Gi=T.unmount,Ki=T.__;function yc(t,e){T.__h&&T.__h(v,t,Gn||e),Gn=0;var n=v.__H||(v.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({}),n.__[t]}function Xi(t){return Gn=1,vc(Qi,t)}function vc(t,e,n){var r=yc(qn++,2);if(r.t=t,!r.__c&&(r.__=[n?n(e):Qi(void 0,e),function(a){var u=r.__N?r.__N[0]:r.__[0],c=r.t(u,a);u!==c&&(r.__N=[c,r.__[1]],r.__c.setState({}))}],r.__c=v,!v.__f)){var i=function(a,u,c){if(!r.__c.__H)return!0;var h=r.__c.__H.__.filter(function(d){return!!d.__c});if(h.every(function(d){return!d.__N}))return!s||s.call(this,a,u,c);var l=r.__c.props!==a;return h.forEach(function(d){if(d.__N){var f=d.__[0];d.__=d.__N,d.__N=void 0,f!==d.__[0]&&(l=!0)}}),s&&s.call(this,a,u,c)||l};v.__f=!0;var s=v.shouldComponentUpdate,o=v.componentWillUpdate;v.componentWillUpdate=function(a,u,c){if(this.__e){var h=s;s=void 0,i(a,u,c),s=h}o&&o.call(this,a,u,c)},v.shouldComponentUpdate=i}return r.__N||r.__}function wc(){for(var t;t=Yi.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(Lt),t.__H.__h.forEach(Kn),t.__H.__h=[]}catch(e){t.__H.__h=[],T.__e(e,t.__v)}}T.__b=function(t){v=null,$i&&$i(t)},T.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),Ki&&Ki(t,e)},T.__r=function(t){zi&&zi(t),qn=0;var e=(v=t.__c).__H;e&&(jn===v?(e.__h=[],v.__h=[],e.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(e.__h.forEach(Lt),e.__h.forEach(Kn),e.__h=[],qn=0)),jn=v},T.diffed=function(t){ji&&ji(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(Yi.push(e)!==1&&Bi===T.requestAnimationFrame||((Bi=T.requestAnimationFrame)||Tc)(wc)),e.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0})),jn=v=null},T.__c=function(t,e){e.some(function(n){try{n.__h.forEach(Lt),n.__h=n.__h.filter(function(r){return!r.__||Kn(r)})}catch(r){e.some(function(i){i.__h&&(i.__h=[])}),e=[],T.__e(r,n.__v)}}),qi&&qi(t,e)},T.unmount=function(t){Gi&&Gi(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Lt(r)}catch(i){e=i}}),n.__H=void 0,e&&T.__e(e,n.__v))};var Ji=typeof requestAnimationFrame=="function";function Tc(t){var e,n=function(){clearTimeout(r),Ji&&cancelAnimationFrame(e),setTimeout(t)},r=setTimeout(n,35);Ji&&(e=requestAnimationFrame(n))}function Lt(t){var e=v,n=t.__c;typeof n=="function"&&(t.__c=void 0,n()),v=e}function Kn(t){var e=v;t.__c=t.__(),v=e}function Qi(t,e){return typeof e=="function"?e(t):e}var bc=0,Tl=Array.isArray;function w(t,e,n,r,i,s){e||(e={});var o,a,u=e;if("ref"in u)for(a in u={},e)a=="ref"?o=e[a]:u[a]=e[a];var c={type:t,props:u,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--bc,__i:-1,__u:0,__source:i,__self:s};if(typeof t=="function"&&(o=t.defaultProps))for(a in o)u[a]===void 0&&(u[a]=o[a]);return I.vnode&&I.vnode(c),c}function We(){let[t,e]=Xi(""),n=window.__ROOT_CTX.name;function r(i){e(i)}return w("div",{className:"signin",children:[w("div",{className:"signin__headline",children:[n&&w("h1",{className:"signin__headline__title",children:n}),w("p",{className:"signin__headline__body",children:n?`Sign in to continue to ${n}`:"Sign in to continue"})]}),w(We.Button,{onError:r}),t&&w("p",{className:"signin__error",children:t})]})}We.Button=t=>{async function e(r){try{return await r.json()}catch(i){console.error(i)}return{}}async function n(){let r=new ne;r.addScope("profile"),r.addScope("email");let s=(await Un(window.firebase.auth,r)).user,o=await s.getIdToken(),a=await fetch("/cms/login",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({idToken:o})}),u=await e(a);if(a.status===401){let c=s?.email||"(no email)";u.reason?t.onError(`Login failed for: ${c}. Reason: ${u.reason}. If you believe this is a mistake, please contact a developer to help resolve the issue.`):t.onError(`Login failed for: ${c}. If you believe this is a mistake, please contact a developer to help resolve the issue.`);return}if(a.status!==200){console.error("login failed"),console.log(a.status,u),t.onError("An unknown error has occurred.");return}if(!u.success){console.error("login failed"),console.log(a.status,u),u.reason?t.onError(`Login failed. Reason: ${u.reason}`):t.onError("Login failed.");return}Ac()}return w("button",{className:"signin__button",onClick:n,children:[w("div",{className:"signin__button__icon",children:w(We.GLogo,{})}),w("div",{className:"signin__button__label",children:"Sign in with Google"})]})};We.GLogo=()=>w("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 48 48",children:w("g",{children:[w("path",{fill:"#EA4335",d:"M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"}),w("path",{fill:"#4285F4",d:"M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"}),w("path",{fill:"#FBBC05",d:"M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"}),w("path",{fill:"#34A853",d:"M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"}),w("path",{fill:"none",d:"M0 0h48v48H0z"})]})});function Ac(){let e=new URLSearchParams(window.location.search).get("continue");(!e||!e.startsWith("/")||e.startsWith("/cms/login"))&&(e="/cms"),window.location.replace(e)}var Zi=sn(window.__ROOT_CTX.firebaseConfig),Sc=xn(Zi);window.firebase={app:Zi,auth:Sc};var es=document.getElementById("root");es.innerHTML="";Wi(w(We,{}),es);})();
2
16
  /*! Bundled license information:
3
17
 
4
- @firebase/util/dist/index.esm2017.js:
18
+ @firebase/util/dist/index.esm.js:
5
19
  (**
6
20
  * @license
7
21
  * Copyright 2017 Google LLC
@@ -19,7 +33,7 @@
19
33
  * limitations under the License.
20
34
  *)
21
35
 
22
- @firebase/util/dist/index.esm2017.js:
36
+ @firebase/util/dist/index.esm.js:
23
37
  (**
24
38
  * @license
25
39
  * Copyright 2017 Google LLC
@@ -37,7 +51,7 @@
37
51
  * limitations under the License.
38
52
  *)
39
53
 
40
- @firebase/util/dist/index.esm2017.js:
54
+ @firebase/util/dist/index.esm.js:
41
55
  (**
42
56
  * @license
43
57
  * Copyright 2017 Google LLC
@@ -55,7 +69,7 @@
55
69
  * limitations under the License.
56
70
  *)
57
71
 
58
- @firebase/util/dist/index.esm2017.js:
72
+ @firebase/util/dist/index.esm.js:
59
73
  (**
60
74
  * @license
61
75
  * Copyright 2022 Google LLC
@@ -73,7 +87,7 @@
73
87
  * limitations under the License.
74
88
  *)
75
89
 
76
- @firebase/util/dist/index.esm2017.js:
90
+ @firebase/util/dist/index.esm.js:
77
91
  (**
78
92
  * @license
79
93
  * Copyright 2017 Google LLC
@@ -92,7 +106,7 @@
92
106
  *)
93
107
  (**
94
108
  * @license
95
- * Copyright 2021 Google LLC
109
+ * Copyright 2025 Google LLC
96
110
  *
97
111
  * Licensed under the Apache License, Version 2.0 (the "License");
98
112
  * you may not use this file except in compliance with the License.
@@ -106,11 +120,9 @@
106
120
  * See the License for the specific language governing permissions and
107
121
  * limitations under the License.
108
122
  *)
109
-
110
- @firebase/util/dist/index.esm2017.js:
111
123
  (**
112
124
  * @license
113
- * Copyright 2017 Google LLC
125
+ * Copyright 2021 Google LLC
114
126
  *
115
127
  * Licensed under the Apache License, Version 2.0 (the "License");
116
128
  * you may not use this file except in compliance with the License.
@@ -125,7 +137,7 @@
125
137
  * limitations under the License.
126
138
  *)
127
139
 
128
- @firebase/util/dist/index.esm2017.js:
140
+ @firebase/util/dist/index.esm.js:
129
141
  (**
130
142
  * @license
131
143
  * Copyright 2017 Google LLC
@@ -143,7 +155,7 @@
143
155
  * limitations under the License.
144
156
  *)
145
157
 
146
- @firebase/util/dist/index.esm2017.js:
158
+ @firebase/util/dist/index.esm.js:
147
159
  (**
148
160
  * @license
149
161
  * Copyright 2017 Google LLC
@@ -161,7 +173,7 @@
161
173
  * limitations under the License.
162
174
  *)
163
175
 
164
- @firebase/util/dist/index.esm2017.js:
176
+ @firebase/util/dist/index.esm.js:
165
177
  (**
166
178
  * @license
167
179
  * Copyright 2017 Google LLC
@@ -179,10 +191,10 @@
179
191
  * limitations under the License.
180
192
  *)
181
193
 
182
- @firebase/util/dist/index.esm2017.js:
194
+ @firebase/util/dist/index.esm.js:
183
195
  (**
184
196
  * @license
185
- * Copyright 2022 Google LLC
197
+ * Copyright 2017 Google LLC
186
198
  *
187
199
  * Licensed under the Apache License, Version 2.0 (the "License");
188
200
  * you may not use this file except in compliance with the License.
@@ -197,10 +209,10 @@
197
209
  * limitations under the License.
198
210
  *)
199
211
 
200
- @firebase/util/dist/index.esm2017.js:
212
+ @firebase/util/dist/index.esm.js:
201
213
  (**
202
214
  * @license
203
- * Copyright 2017 Google LLC
215
+ * Copyright 2022 Google LLC
204
216
  *
205
217
  * Licensed under the Apache License, Version 2.0 (the "License");
206
218
  * you may not use this file except in compliance with the License.
@@ -215,7 +227,7 @@
215
227
  * limitations under the License.
216
228
  *)
217
229
 
218
- @firebase/util/dist/index.esm2017.js:
230
+ @firebase/util/dist/index.esm.js:
219
231
  (**
220
232
  * @license
221
233
  * Copyright 2017 Google LLC
@@ -233,7 +245,7 @@
233
245
  * limitations under the License.
234
246
  *)
235
247
 
236
- @firebase/util/dist/index.esm2017.js:
248
+ @firebase/util/dist/index.esm.js:
237
249
  (**
238
250
  * @license
239
251
  * Copyright 2017 Google LLC
@@ -251,10 +263,10 @@
251
263
  * limitations under the License.
252
264
  *)
253
265
 
254
- @firebase/util/dist/index.esm2017.js:
266
+ @firebase/util/dist/index.esm.js:
255
267
  (**
256
268
  * @license
257
- * Copyright 2022 Google LLC
269
+ * Copyright 2017 Google LLC
258
270
  *
259
271
  * Licensed under the Apache License, Version 2.0 (the "License");
260
272
  * you may not use this file except in compliance with the License.
@@ -269,7 +281,7 @@
269
281
  * limitations under the License.
270
282
  *)
271
283
 
272
- @firebase/util/dist/index.esm2017.js:
284
+ @firebase/util/dist/index.esm.js:
273
285
  (**
274
286
  * @license
275
287
  * Copyright 2019 Google LLC
@@ -287,7 +299,7 @@
287
299
  * limitations under the License.
288
300
  *)
289
301
 
290
- @firebase/util/dist/index.esm2017.js:
302
+ @firebase/util/dist/index.esm.js:
291
303
  (**
292
304
  * @license
293
305
  * Copyright 2020 Google LLC
@@ -305,7 +317,7 @@
305
317
  * limitations under the License.
306
318
  *)
307
319
 
308
- @firebase/util/dist/index.esm2017.js:
320
+ @firebase/util/dist/index.esm.js:
309
321
  (**
310
322
  * @license
311
323
  * Copyright 2021 Google LLC
@@ -323,7 +335,7 @@
323
335
  * limitations under the License.
324
336
  *)
325
337
 
326
- @firebase/component/dist/esm/index.esm2017.js:
338
+ @firebase/component/dist/esm/index.esm.js:
327
339
  (**
328
340
  * @license
329
341
  * Copyright 2019 Google LLC
@@ -341,7 +353,7 @@
341
353
  * limitations under the License.
342
354
  *)
343
355
 
344
- @firebase/logger/dist/esm/index.esm2017.js:
356
+ @firebase/logger/dist/esm/index.esm.js:
345
357
  (**
346
358
  * @license
347
359
  * Copyright 2017 Google LLC
@@ -359,7 +371,7 @@
359
371
  * limitations under the License.
360
372
  *)
361
373
 
362
- @firebase/app/dist/esm/index.esm2017.js:
374
+ @firebase/app/dist/esm/index.esm.js:
363
375
  (**
364
376
  * @license
365
377
  * Copyright 2019 Google LLC
@@ -377,7 +389,7 @@
377
389
  * limitations under the License.
378
390
  *)
379
391
 
380
- @firebase/app/dist/esm/index.esm2017.js:
392
+ @firebase/app/dist/esm/index.esm.js:
381
393
  (**
382
394
  * @license
383
395
  * Copyright 2019 Google LLC
@@ -394,8 +406,42 @@
394
406
  * See the License for the specific language governing permissions and
395
407
  * limitations under the License.
396
408
  *)
409
+ (**
410
+ * @license
411
+ * Copyright 2023 Google LLC
412
+ *
413
+ * Licensed under the Apache License, Version 2.0 (the "License");
414
+ * you may not use this file except in compliance with the License.
415
+ * You may obtain a copy of the License at
416
+ *
417
+ * http://www.apache.org/licenses/LICENSE-2.0
418
+ *
419
+ * Unless required by applicable law or agreed to in writing, software
420
+ * distributed under the License is distributed on an "AS IS" BASIS,
421
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
422
+ * See the License for the specific language governing permissions and
423
+ * limitations under the License.
424
+ *)
397
425
 
398
- @firebase/app/dist/esm/index.esm2017.js:
426
+ @firebase/app/dist/esm/index.esm.js:
427
+ (**
428
+ * @license
429
+ * Copyright 2019 Google LLC
430
+ *
431
+ * Licensed under the Apache License, Version 2.0 (the "License");
432
+ * you may not use this file except in compliance with the License.
433
+ * You may obtain a copy of the License at
434
+ *
435
+ * http://www.apache.org/licenses/LICENSE-2.0
436
+ *
437
+ * Unless required by applicable law or agreed to in writing, software
438
+ * distributed under the License is distributed on an "AS IS" BASIS,
439
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
440
+ * See the License for the specific language governing permissions and
441
+ * limitations under the License.
442
+ *)
443
+
444
+ @firebase/app/dist/esm/index.esm.js:
399
445
  (**
400
446
  * @license
401
447
  * Copyright 2021 Google LLC
@@ -447,7 +493,7 @@ firebase/app/dist/esm/index.esm.js:
447
493
  * limitations under the License.
448
494
  *)
449
495
 
450
- @firebase/auth/dist/esm2017/index-94e5f531.js:
496
+ @firebase/auth/dist/esm/index-9ccb475d.js:
451
497
  (**
452
498
  * @license
453
499
  * Copyright 2021 Google LLC
@@ -465,7 +511,7 @@ firebase/app/dist/esm/index.esm.js:
465
511
  * limitations under the License.
466
512
  *)
467
513
 
468
- @firebase/auth/dist/esm2017/index-94e5f531.js:
514
+ @firebase/auth/dist/esm/index-9ccb475d.js:
469
515
  (**
470
516
  * @license
471
517
  * Copyright 2020 Google LLC
@@ -483,7 +529,7 @@ firebase/app/dist/esm/index.esm.js:
483
529
  * limitations under the License.
484
530
  *)
485
531
 
486
- @firebase/auth/dist/esm2017/index-94e5f531.js:
532
+ @firebase/auth/dist/esm/index-9ccb475d.js:
487
533
  (**
488
534
  * @license
489
535
  * Copyright 2020 Google LLC
@@ -501,7 +547,7 @@ firebase/app/dist/esm/index.esm.js:
501
547
  * limitations under the License.
502
548
  *)
503
549
 
504
- @firebase/auth/dist/esm2017/index-94e5f531.js:
550
+ @firebase/auth/dist/esm/index-9ccb475d.js:
505
551
  (**
506
552
  * @license
507
553
  * Copyright 2020 Google LLC
@@ -519,7 +565,7 @@ firebase/app/dist/esm/index.esm.js:
519
565
  * limitations under the License.
520
566
  *)
521
567
 
522
- @firebase/auth/dist/esm2017/index-94e5f531.js:
568
+ @firebase/auth/dist/esm/index-9ccb475d.js:
523
569
  (**
524
570
  * @license
525
571
  * Copyright 2020 Google LLC
@@ -537,7 +583,7 @@ firebase/app/dist/esm/index.esm.js:
537
583
  * limitations under the License.
538
584
  *)
539
585
 
540
- @firebase/auth/dist/esm2017/index-94e5f531.js:
586
+ @firebase/auth/dist/esm/index-9ccb475d.js:
541
587
  (**
542
588
  * @license
543
589
  * Copyright 2020 Google LLC
@@ -555,7 +601,7 @@ firebase/app/dist/esm/index.esm.js:
555
601
  * limitations under the License.
556
602
  *)
557
603
 
558
- @firebase/auth/dist/esm2017/index-94e5f531.js:
604
+ @firebase/auth/dist/esm/index-9ccb475d.js:
559
605
  (**
560
606
  * @license
561
607
  * Copyright 2020 Google LLC
@@ -589,7 +635,7 @@ firebase/app/dist/esm/index.esm.js:
589
635
  * limitations under the License.
590
636
  *)
591
637
 
592
- @firebase/auth/dist/esm2017/index-94e5f531.js:
638
+ @firebase/auth/dist/esm/index-9ccb475d.js:
593
639
  (**
594
640
  * @license
595
641
  * Copyright 2020 Google LLC
@@ -639,7 +685,7 @@ firebase/app/dist/esm/index.esm.js:
639
685
  * limitations under the License.
640
686
  *)
641
687
 
642
- @firebase/auth/dist/esm2017/index-94e5f531.js:
688
+ @firebase/auth/dist/esm/index-9ccb475d.js:
643
689
  (**
644
690
  * @license
645
691
  * Copyright 2020 Google LLC
@@ -657,7 +703,7 @@ firebase/app/dist/esm/index.esm.js:
657
703
  * limitations under the License.
658
704
  *)
659
705
 
660
- @firebase/auth/dist/esm2017/index-94e5f531.js:
706
+ @firebase/auth/dist/esm/index-9ccb475d.js:
661
707
  (**
662
708
  * @license
663
709
  * Copyright 2020 Google LLC
@@ -675,7 +721,7 @@ firebase/app/dist/esm/index.esm.js:
675
721
  * limitations under the License.
676
722
  *)
677
723
 
678
- @firebase/auth/dist/esm2017/index-94e5f531.js:
724
+ @firebase/auth/dist/esm/index-9ccb475d.js:
679
725
  (**
680
726
  * @license
681
727
  * Copyright 2020 Google LLC
@@ -693,7 +739,25 @@ firebase/app/dist/esm/index.esm.js:
693
739
  * limitations under the License.
694
740
  *)
695
741
 
696
- @firebase/auth/dist/esm2017/index-94e5f531.js:
742
+ @firebase/auth/dist/esm/index-9ccb475d.js:
743
+ (**
744
+ * @license
745
+ * Copyright 2020 Google LLC
746
+ *
747
+ * Licensed under the Apache License, Version 2.0 (the "License");
748
+ * you may not use this file except in compliance with the License.
749
+ * You may obtain a copy of the License at
750
+ *
751
+ * http://www.apache.org/licenses/LICENSE-2.0
752
+ *
753
+ * Unless required by applicable law or agreed to in writing, software
754
+ * distributed under the License is distributed on an "AS IS" BASIS,
755
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
756
+ * See the License for the specific language governing permissions and
757
+ * limitations under the License.
758
+ *)
759
+
760
+ @firebase/auth/dist/esm/index-9ccb475d.js:
697
761
  (**
698
762
  * @license
699
763
  * Copyright 2020 Google LLC
@@ -727,7 +791,7 @@ firebase/app/dist/esm/index.esm.js:
727
791
  * limitations under the License.
728
792
  *)
729
793
 
730
- @firebase/auth/dist/esm2017/index-94e5f531.js:
794
+ @firebase/auth/dist/esm/index-9ccb475d.js:
731
795
  (**
732
796
  * @license
733
797
  * Copyright 2020 Google LLC
@@ -745,7 +809,7 @@ firebase/app/dist/esm/index.esm.js:
745
809
  * limitations under the License.
746
810
  *)
747
811
 
748
- @firebase/auth/dist/esm2017/index-94e5f531.js:
812
+ @firebase/auth/dist/esm/index-9ccb475d.js:
749
813
  (**
750
814
  * @license
751
815
  * Copyright 2020 Google LLC
@@ -763,7 +827,7 @@ firebase/app/dist/esm/index.esm.js:
763
827
  * limitations under the License.
764
828
  *)
765
829
 
766
- @firebase/auth/dist/esm2017/index-94e5f531.js:
830
+ @firebase/auth/dist/esm/index-9ccb475d.js:
767
831
  (**
768
832
  * @license
769
833
  * Copyright 2020 Google LLC
@@ -781,7 +845,7 @@ firebase/app/dist/esm/index.esm.js:
781
845
  * limitations under the License.
782
846
  *)
783
847
 
784
- @firebase/auth/dist/esm2017/index-94e5f531.js:
848
+ @firebase/auth/dist/esm/index-9ccb475d.js:
785
849
  (**
786
850
  * @license
787
851
  * Copyright 2020 Google LLC
@@ -799,7 +863,7 @@ firebase/app/dist/esm/index.esm.js:
799
863
  * limitations under the License.
800
864
  *)
801
865
 
802
- @firebase/auth/dist/esm2017/index-94e5f531.js:
866
+ @firebase/auth/dist/esm/index-9ccb475d.js:
803
867
  (**
804
868
  * @license
805
869
  * Copyright 2020 Google LLC
@@ -817,7 +881,7 @@ firebase/app/dist/esm/index.esm.js:
817
881
  * limitations under the License.
818
882
  *)
819
883
 
820
- @firebase/auth/dist/esm2017/index-94e5f531.js:
884
+ @firebase/auth/dist/esm/index-9ccb475d.js:
821
885
  (**
822
886
  * @license
823
887
  * Copyright 2019 Google LLC
@@ -835,7 +899,7 @@ firebase/app/dist/esm/index.esm.js:
835
899
  * limitations under the License.
836
900
  *)
837
901
 
838
- @firebase/auth/dist/esm2017/index-94e5f531.js:
902
+ @firebase/auth/dist/esm/index-9ccb475d.js:
839
903
  (**
840
904
  * @license
841
905
  * Copyright 2019 Google LLC
@@ -869,7 +933,7 @@ firebase/app/dist/esm/index.esm.js:
869
933
  * limitations under the License.
870
934
  *)
871
935
 
872
- @firebase/auth/dist/esm2017/index-94e5f531.js:
936
+ @firebase/auth/dist/esm/index-9ccb475d.js:
873
937
  (**
874
938
  * @license
875
939
  * Copyright 2020 Google LLC
@@ -887,7 +951,7 @@ firebase/app/dist/esm/index.esm.js:
887
951
  * limitations under the License.
888
952
  *)
889
953
 
890
- @firebase/auth/dist/esm2017/index-94e5f531.js:
954
+ @firebase/auth/dist/esm/index-9ccb475d.js:
891
955
  (**
892
956
  * @license
893
957
  * Copyright 2020 Google LLC
@@ -905,7 +969,7 @@ firebase/app/dist/esm/index.esm.js:
905
969
  * limitations under the License.
906
970
  *)
907
971
 
908
- @firebase/auth/dist/esm2017/index-94e5f531.js:
972
+ @firebase/auth/dist/esm/index-9ccb475d.js:
909
973
  (**
910
974
  * @license
911
975
  * Copyright 2020 Google LLC
@@ -923,7 +987,7 @@ firebase/app/dist/esm/index.esm.js:
923
987
  * limitations under the License.
924
988
  *)
925
989
 
926
- @firebase/auth/dist/esm2017/index-94e5f531.js:
990
+ @firebase/auth/dist/esm/index-9ccb475d.js:
927
991
  (**
928
992
  * @license
929
993
  * Copyright 2020 Google LLC
@@ -941,7 +1005,7 @@ firebase/app/dist/esm/index.esm.js:
941
1005
  * limitations under the License.
942
1006
  *)
943
1007
 
944
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1008
+ @firebase/auth/dist/esm/index-9ccb475d.js:
945
1009
  (**
946
1010
  * @license
947
1011
  * Copyright 2020 Google LLC
@@ -959,7 +1023,7 @@ firebase/app/dist/esm/index.esm.js:
959
1023
  * limitations under the License.
960
1024
  *)
961
1025
 
962
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1026
+ @firebase/auth/dist/esm/index-9ccb475d.js:
963
1027
  (**
964
1028
  * @license
965
1029
  * Copyright 2020 Google LLC
@@ -977,7 +1041,7 @@ firebase/app/dist/esm/index.esm.js:
977
1041
  * limitations under the License.
978
1042
  *)
979
1043
 
980
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1044
+ @firebase/auth/dist/esm/index-9ccb475d.js:
981
1045
  (**
982
1046
  * @license
983
1047
  * Copyright 2020 Google LLC
@@ -995,7 +1059,7 @@ firebase/app/dist/esm/index.esm.js:
995
1059
  * limitations under the License.
996
1060
  *)
997
1061
 
998
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1062
+ @firebase/auth/dist/esm/index-9ccb475d.js:
999
1063
  (**
1000
1064
  * @license
1001
1065
  * Copyright 2020 Google LLC
@@ -1013,7 +1077,7 @@ firebase/app/dist/esm/index.esm.js:
1013
1077
  * limitations under the License.
1014
1078
  *)
1015
1079
 
1016
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1080
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1017
1081
  (**
1018
1082
  * @license
1019
1083
  * Copyright 2020 Google LLC
@@ -1031,7 +1095,7 @@ firebase/app/dist/esm/index.esm.js:
1031
1095
  * limitations under the License.
1032
1096
  *)
1033
1097
 
1034
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1098
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1035
1099
  (**
1036
1100
  * @license
1037
1101
  * Copyright 2020 Google LLC
@@ -1049,7 +1113,7 @@ firebase/app/dist/esm/index.esm.js:
1049
1113
  * limitations under the License.
1050
1114
  *)
1051
1115
 
1052
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1116
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1053
1117
  (**
1054
1118
  * @license
1055
1119
  * Copyright 2019 Google LLC
@@ -1067,7 +1131,7 @@ firebase/app/dist/esm/index.esm.js:
1067
1131
  * limitations under the License.
1068
1132
  *)
1069
1133
 
1070
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1134
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1071
1135
  (**
1072
1136
  * @license
1073
1137
  * Copyright 2020 Google LLC
@@ -1085,7 +1149,7 @@ firebase/app/dist/esm/index.esm.js:
1085
1149
  * limitations under the License.
1086
1150
  *)
1087
1151
 
1088
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1152
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1089
1153
  (**
1090
1154
  * @license
1091
1155
  * Copyright 2020 Google LLC
@@ -1103,7 +1167,7 @@ firebase/app/dist/esm/index.esm.js:
1103
1167
  * limitations under the License.
1104
1168
  *)
1105
1169
 
1106
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1170
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1107
1171
  (**
1108
1172
  * @license
1109
1173
  * Copyright 2020 Google LLC
@@ -1121,7 +1185,7 @@ firebase/app/dist/esm/index.esm.js:
1121
1185
  * limitations under the License.
1122
1186
  *)
1123
1187
 
1124
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1188
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1125
1189
  (**
1126
1190
  * @license
1127
1191
  * Copyright 2020 Google LLC
@@ -1139,7 +1203,7 @@ firebase/app/dist/esm/index.esm.js:
1139
1203
  * limitations under the License.
1140
1204
  *)
1141
1205
 
1142
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1206
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1143
1207
  (**
1144
1208
  * @license
1145
1209
  * Copyright 2019 Google LLC
@@ -1174,7 +1238,7 @@ firebase/app/dist/esm/index.esm.js:
1174
1238
  *)
1175
1239
  (**
1176
1240
  * @license
1177
- * Copyright 2020 Google LLC.
1241
+ * Copyright 2025 Google LLC
1178
1242
  *
1179
1243
  * Licensed under the Apache License, Version 2.0 (the "License");
1180
1244
  * you may not use this file except in compliance with the License.
@@ -1189,7 +1253,7 @@ firebase/app/dist/esm/index.esm.js:
1189
1253
  * limitations under the License.
1190
1254
  *)
1191
1255
 
1192
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1256
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1193
1257
  (**
1194
1258
  * @license
1195
1259
  * Copyright 2020 Google LLC
@@ -1206,8 +1270,40 @@ firebase/app/dist/esm/index.esm.js:
1206
1270
  * See the License for the specific language governing permissions and
1207
1271
  * limitations under the License.
1208
1272
  *)
1273
+ (**
1274
+ * @license
1275
+ * Copyright 2019 Google LLC
1276
+ *
1277
+ * Licensed under the Apache License, Version 2.0 (the "License");
1278
+ * you may not use this file except in compliance with the License.
1279
+ * You may obtain a copy of the License at
1280
+ *
1281
+ * http://www.apache.org/licenses/LICENSE-2.0
1282
+ *
1283
+ * Unless required by applicable law or agreed to in writing, software
1284
+ * distributed under the License is distributed on an "AS IS" BASIS,
1285
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1286
+ * See the License for the specific language governing permissions and
1287
+ * limitations under the License.
1288
+ *)
1289
+ (**
1290
+ * @license
1291
+ * Copyright 2020 Google LLC.
1292
+ *
1293
+ * Licensed under the Apache License, Version 2.0 (the "License");
1294
+ * you may not use this file except in compliance with the License.
1295
+ * You may obtain a copy of the License at
1296
+ *
1297
+ * http://www.apache.org/licenses/LICENSE-2.0
1298
+ *
1299
+ * Unless required by applicable law or agreed to in writing, software
1300
+ * distributed under the License is distributed on an "AS IS" BASIS,
1301
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1302
+ * See the License for the specific language governing permissions and
1303
+ * limitations under the License.
1304
+ *)
1209
1305
 
1210
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1306
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1211
1307
  (**
1212
1308
  * @license
1213
1309
  * Copyright 2020 Google LLC
@@ -1225,7 +1321,7 @@ firebase/app/dist/esm/index.esm.js:
1225
1321
  * limitations under the License.
1226
1322
  *)
1227
1323
 
1228
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1324
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1229
1325
  (**
1230
1326
  * @license
1231
1327
  * Copyright 2020 Google LLC
@@ -1243,7 +1339,7 @@ firebase/app/dist/esm/index.esm.js:
1243
1339
  * limitations under the License.
1244
1340
  *)
1245
1341
 
1246
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1342
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1247
1343
  (**
1248
1344
  * @license
1249
1345
  * Copyright 2020 Google LLC
@@ -1293,7 +1389,7 @@ firebase/app/dist/esm/index.esm.js:
1293
1389
  * limitations under the License.
1294
1390
  *)
1295
1391
 
1296
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1392
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1297
1393
  (**
1298
1394
  * @license
1299
1395
  * Copyright 2020 Google LLC
@@ -1311,7 +1407,7 @@ firebase/app/dist/esm/index.esm.js:
1311
1407
  * limitations under the License.
1312
1408
  *)
1313
1409
 
1314
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1410
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1315
1411
  (**
1316
1412
  * @license
1317
1413
  * Copyright 2020 Google LLC
@@ -1329,7 +1425,7 @@ firebase/app/dist/esm/index.esm.js:
1329
1425
  * limitations under the License.
1330
1426
  *)
1331
1427
 
1332
- @firebase/auth/dist/esm2017/index-94e5f531.js:
1428
+ @firebase/auth/dist/esm/index-9ccb475d.js:
1333
1429
  (**
1334
1430
  * @license
1335
1431
  * Copyright 2020 Google LLC