vendor: 6,342 bytes, lines 1-9
1var db=t=>{throw TypeError(t)};var _N=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Tg=(t,e,n)=>e.has(t)||db("Cannot "+n);var z=(t,e,n)=>(Tg(t,e,"read from private field"),n?n.call(t):e.get(t)),De=(t,e,n)=>e.has(t)?db("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,n),be=(t,e,n,r)=>(Tg(t,e,"write to private field"),r?r.call(t,n):e.set(t,n),n),Ke=(t,e,n)=>(Tg(t,e,"access private method"),n);var Nd=(t,e,n,r)=>({set _(i){be(t,e,i,n)},get _(){return z(t,e,r)}});var Qee=_N((ite,qh)=>{function c2(t,e){for(var n=0;n<e.length;n++){const r=e[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in t)){const s=Object.getOwnPropertyDescriptor(r,i);s&&Object.defineProperty(t,i,s.get?s:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();var br=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ou(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function wN(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(r){var i=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return t[r]}})}),n}var f2={exports:{}},im={},d2={exports:{}},tt={};/** 2 * @license React 3 * react.production.min.js 4 * 5 * Copyright (c) Facebook, Inc. and its affiliates. 6 * 7 * This source code is licensed under the MIT license found in the 8 * LICENSE file in the root directory of this source tree. 9 */var Kf=Symbol.for("react.element"),bN=Symbol.for("react.portal"),EN=Symbol.for("react.fragment"),xN=Symbol.for("react.strict_mode"),TN=Symbol.for("react.profiler"),SN=Symbol.for("react.provider"),kN=Symbol.for("react.context"),AN=Symbol.for("react.forward_ref"),IN=Symbol.for("react.suspense"),ON=Symbol.for("react.memo"),PN=Symbol.for("react.lazy"),hb=Symbol.iterator;function RN(t){return t===null||typeof t!="object"?null:(t=hb&&t[hb]||t["@@iterator"],typeof t=="function"?t:null)}var h2={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},p2=Object.assign,m2={};function Pu(t,e,n){this.props=t,this.context=e,this.refs=m2,this.updater=n||h2}Pu.prototype.isReactComponent={};Pu.prototype.setState=function(t,e){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")};Pu.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function g2(){}g2.prototype=Pu.prototype;function q0(t,e,n){this.props=t,this.context=e,this.refs=m2,this.updater=n||h2}var H0=q0.prototype=new g2;H0.constructor=q0;p2(H0,Pu.prototype);H0.isPureReactComponent=!0;var pb=Array.isArray,v2=Object.prototype.hasOwnProperty,W0={current:null},y2={key:!0,ref:!0,__self:!0,__source:!0};function _2(t,e,n){var r,i={},s=null,o=null;if(e!=null)for(r in e.ref!==void 0&&(o=e.ref),e.key!==void 0&&(s=""+e.key),e)v2.call(e,r)&&!y2.hasOwnProperty(r)&&(i[r]=e[r]);var a=arguments.length-2;if(a===1)i.children=n;else if(1<a){for(var l=Array(a),u=0;u<a;u++)l[u]=arguments[u+2];i.children=l}if(t&&t.defaultProps)for(r in a=t.defaultProps,a)i[r]===void 0&&(i[r]=a[r]);return{$$typeof:Kf,type:t,key:s,ref:o,props:i,_owner:W0.current}}function CN(t,e){return{$$typeof:Kf,type:t.type,key:e,ref:t.ref,props:t.props,_owner:t._owner}}function G0(t){return typeof t=="object"&&t!==null&&t.$$typeof===Kf}function NN(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,function(n){return e[n]})}var mb=/\/+/g;function Sg(t,e){return typeof t=="object"&&t!==null&&t.key!=null?NN(""+t.key):e.toString(36)}function ph(t,e,n,r,i){var s=typeof t;(s==="undefined"||s==="boolean")&&(t=null);var o=!1;if(t===null)o=!0;else switch(s){case"string":case"number":o=!0;break;case"object":switch(t.$$typeof){case Kf:case bN:o=!0}}if(o)return o=t,i=i(o),t=r===""?"."+Sg(o,0):r,pb(i)?(n="",t!=null&&(n=t.replace(mb,"$&/")+"/"),ph(i,e,n,"",function(u){return u})):i!=null&&(G0(i)&&(i=CN(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(mb,"$&/")+"/")+t)),e.push(i)),1;if(o=0,r=r===""?".":r+":",pb(t))for(var a=0;a<t.length;a++){s=t[a];var l=r+Sg(s,a);o+=ph(s,e,n,l,i)}else if(l=RN(t),typeof l=="function")for(t=l.call(t),a=0;!(s=t.next()).done;)s=s.value,l=r+Sg(s,a++),o+=ph(s,e,n,l,i);else if(s==="object")throw e=String(t),Error("Objects are not valid as a React child (found: "+(e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.");return o}function Dd(t,e,n){if(t==null)return t;var r=[],i=0;return ph(t,r,"","",function(s){return e.call(n,s,i++)}),r}function DN(t){if(t._status===-1){var e=t._result;e=e(),e.then(function(n){(t._status===0||t._status===-1)&&(t._status=1,t._result=n)},function(n){(t._status===0||t._status===-1)&&(t._status=2,t._result=n)}),t._status===-1&&(t._status=0,t._result=e)}if(t._status===1)return t._result.default;throw t._result}var Xn={current:null},mh={transition:null},MN={ReactCurrentDispatcher:Xn,ReactCurrentBatchConfig:mh,ReactCurrentOwner:W0};function w2(){throw Error("act(...) is not supported in production builds of React.")}
vendor: 4,092 bytes, lines 9-25
9tt.Children={map:Dd,forEach:function(t,e,n){Dd(t,function(){e.apply(this,arguments)},n)},count:function(t){var e=0;return Dd(t,function(){e++}),e},toArray:function(t){return Dd(t,function(e){return e})||[]},only:function(t){if(!G0(t))throw Error("React.Children.only expected to receive a single React element child.");return t}};tt.Component=Pu;tt.Fragment=EN;tt.Profiler=TN;tt.PureComponent=q0;tt.StrictMode=xN;tt.Suspense=IN;tt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=MN;tt.act=w2;tt.cloneElement=function(t,e,n){if(t==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var r=p2({},t.props),i=t.key,s=t.ref,o=t._owner;if(e!=null){if(e.ref!==void 0&&(s=e.ref,o=W0.current),e.key!==void 0&&(i=""+e.key),t.type&&t.type.defaultProps)var a=t.type.defaultProps;for(l in e)v2.call(e,l)&&!y2.hasOwnProperty(l)&&(r[l]=e[l]===void 0&&a!==void 0?a[l]:e[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){a=Array(l);for(var u=0;u<l;u++)a[u]=arguments[u+2];r.children=a}return{$$typeof:Kf,type:t.type,key:i,ref:s,props:r,_owner:o}};tt.createContext=function(t){return t={$$typeof:kN,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},t.Provider={$$typeof:SN,_context:t},t.Consumer=t};tt.createElement=_2;tt.createFactory=function(t){var e=_2.bind(null,t);return e.type=t,e};tt.createRef=function(){return{current:null}};tt.forwardRef=function(t){return{$$typeof:AN,render:t}};tt.isValidElement=G0;tt.lazy=function(t){return{$$typeof:PN,_payload:{_status:-1,_result:t},_init:DN}};tt.memo=function(t,e){return{$$typeof:ON,type:t,compare:e===void 0?null:e}};tt.startTransition=function(t){var e=mh.transition;mh.transition={};try{t()}finally{mh.transition=e}};tt.unstable_act=w2;tt.useCallback=function(t,e){return Xn.current.useCallback(t,e)};tt.useContext=function(t){return Xn.current.useContext(t)};tt.useDebugValue=function(){};tt.useDeferredValue=function(t){return Xn.current.useDeferredValue(t)};tt.useEffect=function(t,e){return Xn.current.useEffect(t,e)};tt.useId=function(){return Xn.current.useId()};tt.useImperativeHandle=function(t,e,n){return Xn.current.useImperativeHandle(t,e,n)};tt.useInsertionEffect=function(t,e){return Xn.current.useInsertionEffect(t,e)};tt.useLayoutEffect=function(t,e){return Xn.current.useLayoutEffect(t,e)};tt.useMemo=function(t,e){return Xn.current.useMemo(t,e)};tt.useReducer=function(t,e,n){return Xn.current.useReducer(t,e,n)};tt.useRef=function(t){return Xn.current.useRef(t)};tt.useState=function(t){return Xn.current.useState(t)};tt.useSyncExternalStore=function(t,e,n){return Xn.current.useSyncExternalStore(t,e,n)};tt.useTransition=function(){return Xn.current.useTransition()};tt.version="18.3.1";d2.exports=tt;var H=d2.exports;const Je=Ou(H),LN=c2({__proto__:null,default:Je},[H]);/** 10 * @license React 11 * react-jsx-runtime.production.min.js 12 * 13 * Copyright (c) Facebook, Inc. and its affiliates. 14 * 15 * This source code is licensed under the MIT license found in the 16 * LICENSE file in the root directory of this source tree. 17 */var jN=H,FN=Symbol.for("react.element"),VN=Symbol.for("react.fragment"),UN=Object.prototype.hasOwnProperty,$N=jN.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,BN={key:!0,ref:!0,__self:!0,__source:!0};function b2(t,e,n){var r,i={},s=null,o=null;n!==void 0&&(s=""+n),e.key!==void 0&&(s=""+e.key),e.ref!==void 0&&(o=e.ref);for(r in e)UN.call(e,r)&&!BN.hasOwnProperty(r)&&(i[r]=e[r]);if(t&&t.defaultProps)for(r in e=t.defaultProps,e)i[r]===void 0&&(i[r]=e[r]);return{$$typeof:FN,type:t,key:s,ref:o,props:i,_owner:$N.current}}im.Fragment=VN;im.jsx=b2;im.jsxs=b2;f2.exports=im;var R=f2.exports,E2={exports:{}},Ir={},x2={exports:{}},T2={};/** 18 * @license React 19 * scheduler.production.min.js 20 * 21 * Copyright (c) Facebook, Inc. and its affiliates. 22 * 23 * This source code is licensed under the MIT license found in the 24 * LICENSE file in the root directory of this source tree. 25 */(function(t){function e(K,B){var V=K.length;K.push(B);e:for(;0<V;){var D=V-1>>>1,j=K[D];
vendor: 10,531 bytes, lines 25-34
25if(0<i(j,B))K[D]=B,K[V]=j,V=D;else break e}}function n(K){return K.length===0?null:K[0]}function r(K){if(K.length===0)return null;var B=K[0],V=K.pop();if(V!==B){K[0]=V;e:for(var D=0,j=K.length,U=j>>>1;D<U;){var Y=2*(D+1)-1,W=K[Y],F=Y+1,q=K[F];if(0>i(W,V))F<j&&0>i(q,W)?(K[D]=q,K[F]=V,D=F):(K[D]=W,K[Y]=V,D=Y);else if(F<j&&0>i(q,V))K[D]=q,K[F]=V,D=F;else break e}}return B}function i(K,B){var V=K.sortIndex-B.sortIndex;return V!==0?V:K.id-B.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;t.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();t.unstable_now=function(){return o.now()-a}}var l=[],u=[],c=1,d=null,f=3,p=!1,_=!1,y=!1,w=typeof setTimeout=="function"?setTimeout:null,g=typeof clearTimeout=="function"?clearTimeout:null,m=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function b(K){for(var B=n(u);B!==null;){if(B.callback===null)r(u);else if(B.startTime<=K)r(u),B.sortIndex=B.expirationTime,e(l,B);else break;B=n(u)}}function v(K){if(y=!1,b(K),!_)if(n(l)!==null)_=!0,Z(A);else{var B=n(u);B!==null&&Q(v,B.startTime-K)}}function A(K,B){_=!1,y&&(y=!1,g(E),E=-1),p=!0;var V=f;try{for(b(B),d=n(l);d!==null&&(!(d.expirationTime>B)||K&&!k());){var D=d.callback;if(typeof D=="function"){d.callback=null,f=d.priorityLevel;var j=D(d.expirationTime<=B);B=t.unstable_now(),typeof j=="function"?d.callback=j:d===n(l)&&r(l),b(B)}else r(l);d=n(l)}if(d!==null)var U=!0;else{var Y=n(u);Y!==null&&Q(v,Y.startTime-B),U=!1}return U}finally{d=null,f=V,p=!1}}var N=!1,x=null,E=-1,T=5,S=-1;function k(){return!(t.unstable_now()-S<T)}function I(){if(x!==null){var K=t.unstable_now();S=K;var B=!0;try{B=x(!0,K)}finally{B?P():(N=!1,x=null)}}else N=!1}var P;if(typeof m=="function")P=function(){m(I)};else if(typeof MessageChannel<"u"){var M=new MessageChannel,$=M.port2;M.port1.onmessage=I,P=function(){$.postMessage(null)}}else P=function(){w(I,0)};function Z(K){x=K,N||(N=!0,P())}function Q(K,B){E=w(function(){K(t.unstable_now())},B)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(K){K.callback=null},t.unstable_continueExecution=function(){_||p||(_=!0,Z(A))},t.unstable_forceFrameRate=function(K){0>K||125<K?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):T=0<K?Math.floor(1e3/K):5},t.unstable_getCurrentPriorityLevel=function(){return f},t.unstable_getFirstCallbackNode=function(){return n(l)},t.unstable_next=function(K){switch(f){case 1:case 2:case 3:var B=3;break;default:B=f}var V=f;f=B;try{return K()}finally{f=V}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(K,B){switch(K){case 1:case 2:case 3:case 4:case 5:break;default:K=3}var V=f;f=K;try{return B()}finally{f=V}},t.unstable_scheduleCallback=function(K,B,V){var D=t.unstable_now();switch(typeof V=="object"&&V!==null?(V=V.delay,V=typeof V=="number"&&0<V?D+V:D):V=D,K){case 1:var j=-1;break;case 2:j=250;break;case 5:j=1073741823;break;case 4:j=1e4;break;default:j=5e3}return j=V+j,K={id:c++,callback:B,priorityLevel:K,startTime:V,expirationTime:j,sortIndex:-1},V>D?(K.sortIndex=V,e(u,K),n(l)===null&&K===n(u)&&(y?(g(E),E=-1):y=!0,Q(v,V-D))):(K.sortIndex=j,e(l,K),_||p||(_=!0,Z(A))),K},t.unstable_shouldYield=k,t.unstable_wrapCallback=function(K){var B=f;return function(){var V=f;f=B;try{return K.apply(this,arguments)}finally{f=V}}}})(T2);x2.exports=T2;var zN=x2.exports;/** 26 * @license React 27 * react-dom.production.min.js 28 * 29 * Copyright (c) Facebook, Inc. and its affiliates. 30 * 31 * This source code is licensed under the MIT license found in the 32 * LICENSE file in the root directory of this source tree. 33 */var qN=H,Ar=zN;function de(t){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+t,n=1;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var S2=new Set,ef={};function il(t,e){hu(t,e),hu(t+"Capture",e)}function hu(t,e){for(ef[t]=e,t=0;t<e.length;t++)S2.add(e[t])}var As=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Pv=Object.prototype.hasOwnProperty,HN=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,gb={},vb={};function WN(t){return Pv.call(vb,t)?!0:Pv.call(gb,t)?!1:HN.test(t)?vb[t]=!0:(gb[t]=!0,!1)}function GN(t,e,n,r){if(n!==null&&n.type===0)return!1;switch(typeof e){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function KN(t,e,n,r){if(e===null||typeof e>"u"||GN(t,e,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!e;case 4:return e===!1;case 5:return isNaN(e);case 6:return isNaN(e)||1>e}return!1}function Jn(t,e,n,r,i,s,o){this.acceptsBooleans=e===2||e===3||e===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=t,this.type=e,this.sanitizeURL=s,this.removeEmptyString=o}var kn={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){kn[t]=new Jn(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var e=t[0];kn[e]=new Jn(e,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){kn[t]=new Jn(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){kn[t]=new Jn(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){kn[t]=new Jn(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){kn[t]=new Jn(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){kn[t]=new Jn(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){kn[t]=new Jn(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){kn[t]=new Jn(t,5,!1,t.toLowerCase(),null,!1,!1)});var K0=/[\-:]([a-z])/g;function Y0(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var e=t.replace(K0,Y0);kn[e]=new Jn(e,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var e=t.replace(K0,Y0);kn[e]=new Jn(e,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var e=t.replace(K0,Y0);kn[e]=new Jn(e,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){kn[t]=new Jn(t,1,!1,t.toLowerCase(),null,!1,!1)});kn.xlinkHref=new Jn("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){kn[t]=new Jn(t,1,!1,t.toLowerCase(),null,!0,!0)});function Q0(t,e,n,r){var i=kn.hasOwnProperty(e)?kn[e]:null;(i!==null?i.type!==0:r||!(2<e.length)||e[0]!=="o"&&e[0]!=="O"||e[1]!=="n"&&e[1]!=="N")&&(KN(e,n,i,r)&&(n=null),r||i===null?WN(e)&&(n===null?t.removeAttribute(e):t.setAttribute(e,""+n)):i.mustUseProperty?t[i.propertyName]=n===null?i.type===3?!1:"":n:(e=i.attributeName,r=i.attributeNamespace,n===null?t.removeAttribute(e):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?t.setAttributeNS(r,e,n):t.setAttribute(e,n))))}var Fs=qN.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Md=Symbol.for("react.element"),Sl=Symbol.for("react.portal"),kl=Symbol.for("react.fragment"),Z0=Symbol.for("react.strict_mode"),Rv=Symbol.for("react.profiler"),k2=Symbol.for("react.provider"),A2=Symbol.for("react.context"),X0=Symbol.for("react.forward_ref"),Cv=Symbol.for("react.suspense"),Nv=Symbol.for("react.suspense_list"),J0=Symbol.for("react.memo"),no=Symbol.for("react.lazy"),I2=Symbol.for("react.offscreen"),yb=Symbol.iterator;function ac(t){return t===null||typeof t!="object"?null:(t=yb&&t[yb]||t["@@iterator"],typeof t=="function"?t:null)}var Gt=Object.assign,kg;function Sc(t){if(kg===void 0)try{throw Error()}catch(n){var e=n.stack.trim().match(/\n( *(at )?)/);kg=e&&e[1]||""}return` 34`+kg+t}var Ag=!1;function Ig(t,e){if(!t||Ag)return"";Ag=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(e)if(e=function(){throw Error()},Object.defineProperty(e.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(e,[])}catch(u){var r=u}Reflect.construct(t,[],e)}else{try{e.call()}catch(u){r=u}t.call(e.prototype)}else{try{throw Error()}catch(u){r=u}t()}}
vendor: 16,488 bytes, lines 34-37
34catch(u){if(u&&r&&typeof u.stack=="string"){for(var i=u.stack.split(` 35`),s=r.stack.split(` 36`),o=i.length-1,a=s.length-1;1<=o&&0<=a&&i[o]!==s[a];)a--;for(;1<=o&&0<=a;o--,a--)if(i[o]!==s[a]){if(o!==1||a!==1)do if(o--,a--,0>a||i[o]!==s[a]){var l=` 37`+i[o].replace(" at new "," at ");return t.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",t.displayName)),l}while(1<=o&&0<=a);break}}}finally{Ag=!1,Error.prepareStackTrace=n}return(t=t?t.displayName||t.name:"")?Sc(t):""}function YN(t){switch(t.tag){case 5:return Sc(t.type);case 16:return Sc("Lazy");case 13:return Sc("Suspense");case 19:return Sc("SuspenseList");case 0:case 2:case 15:return t=Ig(t.type,!1),t;case 11:return t=Ig(t.type.render,!1),t;case 1:return t=Ig(t.type,!0),t;default:return""}}function Dv(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case kl:return"Fragment";case Sl:return"Portal";case Rv:return"Profiler";case Z0:return"StrictMode";case Cv:return"Suspense";case Nv:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case A2:return(t.displayName||"Context")+".Consumer";case k2:return(t._context.displayName||"Context")+".Provider";case X0:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case J0:return e=t.displayName||null,e!==null?e:Dv(t.type)||"Memo";case no:e=t._payload,t=t._init;try{return Dv(t(e))}catch{}}return null}function QN(t){var e=t.type;switch(t.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=e.render,t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Dv(e);case 8:return e===Z0?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function Uo(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function O2(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function ZN(t){var e=O2(t)?"checked":"value",n=Object.getOwnPropertyDescriptor(t.constructor.prototype,e),r=""+t[e];if(!t.hasOwnProperty(e)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,s=n.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function Ld(t){t._valueTracker||(t._valueTracker=ZN(t))}function P2(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),r="";return t&&(r=O2(t)?t.checked?"true":"false":t.value),t=r,t!==n?(e.setValue(t),!0):!1}function Hh(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function Mv(t,e){var n=e.checked;return Gt({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??t._wrapperState.initialChecked})}function _b(t,e){var n=e.defaultValue==null?"":e.defaultValue,r=e.checked!=null?e.checked:e.defaultChecked;n=Uo(e.value!=null?e.value:n),t._wrapperState={initialChecked:r,initialValue:n,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function R2(t,e){e=e.checked,e!=null&&Q0(t,"checked",e,!1)}function Lv(t,e){R2(t,e);var n=Uo(e.value),r=e.type;if(n!=null)r==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+n):t.value!==""+n&&(t.value=""+n);else if(r==="submit"||r==="reset"){t.removeAttribute("value");return}e.hasOwnProperty("value")?jv(t,e.type,n):e.hasOwnProperty("defaultValue")&&jv(t,e.type,Uo(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(t.defaultChecked=!!e.defaultChecked)}function wb(t,e,n){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var r=e.type;if(!(r!=="submit"&&r!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+t._wrapperState.initialValue,n||e===t.value||(t.value=e),t.defaultValue=e}n=t.name,n!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,n!==""&&(t.name=n)}function jv(t,e,n){(e!=="number"||Hh(t.ownerDocument)!==t)&&(n==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+n&&(t.defaultValue=""+n))}var kc=Array.isArray;function Ul(t,e,n,r){if(t=t.options,e){e={};for(var i=0;i<n.length;i++)e["$"+n[i]]=!0;for(n=0;n<t.length;n++)i=e.hasOwnProperty("$"+t[n].value),t[n].selected!==i&&(t[n].selected=i),i&&r&&(t[n].defaultSelected=!0)}else{for(n=""+Uo(n),e=null,i=0;i<t.length;i++){if(t[i].value===n){t[i].selected=!0,r&&(t[i].defaultSelected=!0);return}e!==null||t[i].disabled||(e=t[i])}e!==null&&(e.selected=!0)}}function Fv(t,e){if(e.dangerouslySetInnerHTML!=null)throw Error(de(91));return Gt({},e,{value:void 0,defaultValue:void 0,children:""+t._wrapperState.initialValue})}function bb(t,e){var n=e.value;if(n==null){if(n=e.children,e=e.defaultValue,n!=null){if(e!=null)throw Error(de(92));if(kc(n)){if(1<n.length)throw Error(de(93));n=n[0]}e=n}e==null&&(e=""),n=e}t._wrapperState={initialValue:Uo(n)}}function C2(t,e){var n=Uo(e.value),r=Uo(e.defaultValue);n!=null&&(n=""+n,n!==t.value&&(t.value=n),e.defaultValue==null&&t.defaultValue!==n&&(t.defaultValue=n)),r!=null&&(t.defaultValue=""+r)}function Eb(t){var e=t.textContent;e===t._wrapperState.initialValue&&e!==""&&e!==null&&(t.value=e)}function N2(t){switch(t){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Vv(t,e){return t==null||t==="http://www.w3.org/1999/xhtml"?N2(e):t==="http://www.w3.org/2000/svg"&&e==="foreignObject"?"http://www.w3.org/1999/xhtml":t}var jd,D2=function(t){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(e,n,r,i){MSApp.execUnsafeLocalFunction(function(){return t(e,n,r,i)})}:t}(function(t,e){if(t.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in t)t.innerHTML=e;else{for(jd=jd||document.createElement("div"),jd.innerHTML="<svg>"+e.valueOf().toString()+"</svg>",e=jd.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;e.firstChild;)t.appendChild(e.firstChild)}});function tf(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}var Lc={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},XN=["Webkit","ms","Moz","O"];Object.keys(Lc).forEach(function(t){XN.forEach(function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),Lc[e]=Lc[t]})});function M2(t,e,n){return e==null||typeof e=="boolean"||e===""?"":n||typeof e!="number"||e===0||Lc.hasOwnProperty(t)&&Lc[t]?(""+e).trim():e+"px"}function L2(t,e){t=t.style;for(var n in e)if(e.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=M2(n,e[n],r);n==="float"&&(n="cssFloat"),r?t.setProperty(n,i):t[n]=i}}var JN=Gt({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Uv(t,e){if(e){if(JN[t]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(de(137,t));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(de(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(de(61))}if(e.style!=null&&typeof e.style!="object")throw Error(de(62))}}function $v(t,e){if(t.indexOf("-")===-1)return typeof e.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Bv=null;function e_(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var zv=null,$l=null,Bl=null;function xb(t){if(t=Zf(t)){if(typeof zv!="function")throw Error(de(280));var e=t.stateNode;e&&(e=um(e),zv(t.stateNode,t.type,e))}}function j2(t){$l?Bl?Bl.push(t):Bl=[t]:$l=t}function F2(){if($l){var t=$l,e=Bl;if(Bl=$l=null,xb(t),e)for(t=0;t<e.length;t++)xb(e[t])}}function V2(t,e){return t(e)}function U2(){}var Og=!1;function $2(t,e,n){if(Og)return t(e,n);Og=!0;try{return V2(t,e,n)}finally{Og=!1,($l!==null||Bl!==null)&&(U2(),F2())}}function nf(t,e){var n=t.stateNode;if(n===null)return null;var r=um(n);if(r===null)return null;n=r[e];e:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(t=t.type,r=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!r;break e;default:t=!1}if(t)return null;if(n&&typeof n!="function")throw Error(de(231,e,typeof n));return n}var qv=!1;if(As)try{var lc={};Object.defineProperty(lc,"passive",{get:function(){qv=!0}}),window.addEventListener("test",lc,lc),window.removeEventListener("test",lc,lc)}catch{qv=!1}function eD(t,e,n,r,i,s,o,a,l){var u=Array.prototype.slice.call(arguments,3);try{e.apply(n,u)}catch(c){this.onError(c)}}var jc=!1,Wh=null,Gh=!1,Hv=null,tD={onError:function(t){jc=!0,Wh=t}};function nD(t,e,n,r,i,s,o,a,l){jc=!1,Wh=null,eD.apply(tD,arguments)}function rD(t,e,n,r,i,s,o,a,l){if(nD.apply(this,arguments),jc){if(jc){var u=Wh;jc=!1,Wh=null}else throw Error(de(198));Gh||(Gh=!0,Hv=u)}}function sl(t){var e=t,n=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,e.flags&4098&&(n=e.return),t=e.return;while(t)}return e.tag===3?n:null}function B2(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function Tb(t){if(sl(t)!==t)throw Error(de(188))}function iD(t){var e=t.alternate;if(!e){if(e=sl(t),e===null)throw Error(de(188));return e!==t?null:t}for(var n=t,r=e;;){var i=n.return;if(i===null)break;var s=i.alternate;if(s===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===s.child){for(s=i.child;s;){if(s===n)return Tb(i),t;if(s===r)return Tb(i),e;s=s.sibling}throw Error(de(188))}if(n.return!==r.return)n=i,r=s;else{for(var o=!1,a=i.child;a;){if(a===n){o=!0,n=i,r=s;break}if(a===r){o=!0,r=i,n=s;break}a=a.sibling}if(!o){for(a=s.child;a;){if(a===n){o=!0,n=s,r=i;break}if(a===r){o=!0,r=s,n=i;break}a=a.sibling}if(!o)throw Error(de(189))}}if(n.alternate!==r)throw Error(de(190))}if(n.tag!==3)throw Error(de(188));return n.stateNode.current===n?t:e}function z2(t){return t=iD(t),t!==null?q2(t):null}function q2(t){if(t.tag===5||t.tag===6)return t;for(t=t.child;t!==null;){var e=q2(t);if(e!==null)return e;t=t.sibling}return null}var H2=Ar.unstable_scheduleCallback,Sb=Ar.unstable_cancelCallback,sD=Ar.unstable_shouldYield,oD=Ar.unstable_requestPaint,nn=Ar.unstable_now,aD=Ar.unstable_getCurrentPriorityLevel,t_=Ar.unstable_ImmediatePriority,W2=Ar.unstable_UserBlockingPriority,Kh=Ar.unstable_NormalPriority,lD=Ar.unstable_LowPriority,G2=Ar.unstable_IdlePriority,sm=null,Ci=null;function uD(t){if(Ci&&typeof Ci.onCommitFiberRoot=="function")try{Ci.onCommitFiberRoot(sm,t,void 0,(t.current.flags&128)===128)}catch{}}var oi=Math.clz32?Math.clz32:dD,cD=Math.log,fD=Math.LN2;function dD(t){return t>>>=0,t===0?32:31-(cD(t)/fD|0)|0}var Fd=64,Vd=4194304;function Ac(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function Yh(t,e){var n=t.pendingLanes;if(n===0)return 0;var r=0,i=t.suspendedLanes,s=t.pingedLanes,o=n&268435455;if(o!==0){var a=o&~i;a!==0?r=Ac(a):(s&=o,s!==0&&(r=Ac(s)))}else o=n&~i,o!==0?r=Ac(o):s!==0&&(r=Ac(s));if(r===0)return 0;if(e!==0&&e!==r&&!(e&i)&&(i=r&-r,s=e&-e,i>=s||i===16&&(s&4194240)!==0))return e;if(r&4&&(r|=n&16),e=t.entangledLanes,e!==0)for(t=t.entanglements,e&=r;0<e;)n=31-oi(e),i=1<<n,r|=t[n],e&=~i;return r}function hD(t,e){switch(t){case 1:case 2:case 4:return e+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function pD(t,e){for(var n=t.suspendedLanes,r=t.pingedLanes,i=t.expirationTimes,s=t.pendingLanes;0<s;){var o=31-oi(s),a=1<<o,l=i[o];l===-1?(!(a&n)||a&r)&&(i[o]=hD(a,e)):l<=e&&(t.expiredLanes|=a),s&=~a}}function Wv(t){return t=t.pendingLanes&-1073741825,t!==0?t:t&1073741824?1073741824:0}function K2(){var t=Fd;return Fd<<=1,!(Fd&4194240)&&(Fd=64),t}function Pg(t){for(var e=[],n=0;31>n;n++)e.push(t);return e}function Yf(t,e,n){t.pendingLanes|=e,e!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,e=31-oi(e),t[e]=n}function mD(t,e){var n=t.pendingLanes&~e;t.pendingLanes=e,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=e,t.mutableReadLanes&=e,t.entangledLanes&=e,e=t.entanglements;var r=t.eventTimes;for(t=t.expirationTimes;0<n;){var i=31-oi(n),s=1<<i;e[i]=0,r[i]=-1,t[i]=-1,n&=~s}}function n_(t,e){var n=t.entangledLanes|=e;for(t=t.entanglements;n;){var r=31-oi(n),i=1<<r;i&e|t[r]&e&&(t[r]|=e),n&=~i}}var wt=0;function Y2(t){return t&=-t,1<t?4<t?t&268435455?16:536870912:4:1}var Q2,r_,Z2,X2,J2,Gv=!1,Ud=[],Ao=null,Io=null,Oo=null,rf=new Map,sf=new Map,io=[],gD="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function kb(t,e){switch(t){case"focusin":case"focusout":Ao=null;break;case"dragenter":case"dragleave":Io=null;break;case"mouseover":case"mouseout":Oo=null;break;case"pointerover":case"pointerout":rf.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":sf.delete(e.pointerId)}}function uc(t,e,n,r,i,s){return t===null||t.nativeEvent!==s?(t={blockedOn:e,domEventName:n,eventSystemFlags:r,nativeEvent:s,targetContainers:[i]},e!==null&&(e=Zf(e),e!==null&&r_(e)),t):(t.eventSystemFlags|=r,e=t.targetContainers,i!==null&&e.indexOf(i)===-1&&e.push(i),t)}function vD(t,e,n,r,i){switch(e){case"focusin":return Ao=uc(Ao,t,e,n,r,i),!0;case"dragenter":return Io=uc(Io,t,e,n,r,i),!0;case"mouseover":return Oo=uc(Oo,t,e,n,r,i),!0;case"pointerover":var s=i.pointerId;return rf.set(s,uc(rf.get(s)||null,t,e,n,r,i)),!0;case"gotpointercapture":return s=i.pointerId,sf.set(s,uc(sf.get(s)||null,t,e,n,r,i)),!0}return!1}function ek(t){var e=va(t.target);if(e!==null){var n=sl(e);if(n!==null){if(e=n.tag,e===13){if(e=B2(n),e!==null){t.blockedOn=e,J2(t.priority,function(){Z2(n)});return}}else if(e===3&&n.stateNode.current.memoizedState.isDehydrated){t.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}t.blockedOn=null}function gh(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var n=Kv(t.domEventName,t.eventSystemFlags,e[0],t.nativeEvent);if(n===null){n=t.nativeEvent;var r=new n.constructor(n.type,n);
vendor: 8,954 bytes, line 37
37Bv=r,n.target.dispatchEvent(r),Bv=null}else return e=Zf(n),e!==null&&r_(e),t.blockedOn=n,!1;e.shift()}return!0}function Ab(t,e,n){gh(t)&&n.delete(e)}function yD(){Gv=!1,Ao!==null&&gh(Ao)&&(Ao=null),Io!==null&&gh(Io)&&(Io=null),Oo!==null&&gh(Oo)&&(Oo=null),rf.forEach(Ab),sf.forEach(Ab)}function cc(t,e){t.blockedOn===e&&(t.blockedOn=null,Gv||(Gv=!0,Ar.unstable_scheduleCallback(Ar.unstable_NormalPriority,yD)))}function of(t){function e(i){return cc(i,t)}if(0<Ud.length){cc(Ud[0],t);for(var n=1;n<Ud.length;n++){var r=Ud[n];r.blockedOn===t&&(r.blockedOn=null)}}for(Ao!==null&&cc(Ao,t),Io!==null&&cc(Io,t),Oo!==null&&cc(Oo,t),rf.forEach(e),sf.forEach(e),n=0;n<io.length;n++)r=io[n],r.blockedOn===t&&(r.blockedOn=null);for(;0<io.length&&(n=io[0],n.blockedOn===null);)ek(n),n.blockedOn===null&&io.shift()}var zl=Fs.ReactCurrentBatchConfig,Qh=!0;function _D(t,e,n,r){var i=wt,s=zl.transition;zl.transition=null;try{wt=1,i_(t,e,n,r)}finally{wt=i,zl.transition=s}}function wD(t,e,n,r){var i=wt,s=zl.transition;zl.transition=null;try{wt=4,i_(t,e,n,r)}finally{wt=i,zl.transition=s}}function i_(t,e,n,r){if(Qh){var i=Kv(t,e,n,r);if(i===null)Ug(t,e,r,Zh,n),kb(t,r);else if(vD(i,t,e,n,r))r.stopPropagation();else if(kb(t,r),e&4&&-1<gD.indexOf(t)){for(;i!==null;){var s=Zf(i);if(s!==null&&Q2(s),s=Kv(t,e,n,r),s===null&&Ug(t,e,r,Zh,n),s===i)break;i=s}i!==null&&r.stopPropagation()}else Ug(t,e,r,null,n)}}var Zh=null;function Kv(t,e,n,r){if(Zh=null,t=e_(r),t=va(t),t!==null)if(e=sl(t),e===null)t=null;else if(n=e.tag,n===13){if(t=B2(e),t!==null)return t;t=null}else if(n===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null);return Zh=t,null}function tk(t){switch(t){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(aD()){case t_:return 1;case W2:return 4;case Kh:case lD:return 16;case G2:return 536870912;default:return 16}default:return 16}}var wo=null,s_=null,vh=null;function nk(){if(vh)return vh;var t,e=s_,n=e.length,r,i="value"in wo?wo.value:wo.textContent,s=i.length;for(t=0;t<n&&e[t]===i[t];t++);var o=n-t;for(r=1;r<=o&&e[n-r]===i[s-r];r++);return vh=i.slice(t,1<r?1-r:void 0)}function yh(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function $d(){return!0}function Ib(){return!1}function Or(t){function e(n,r,i,s,o){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=s,this.target=o,this.currentTarget=null;for(var a in t)t.hasOwnProperty(a)&&(n=t[a],this[a]=n?n(s):s[a]);return this.isDefaultPrevented=(s.defaultPrevented!=null?s.defaultPrevented:s.returnValue===!1)?$d:Ib,this.isPropagationStopped=Ib,this}return Gt(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=$d)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=$d)},persist:function(){},isPersistent:$d}),e}var Ru={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},o_=Or(Ru),Qf=Gt({},Ru,{view:0,detail:0}),bD=Or(Qf),Rg,Cg,fc,om=Gt({},Qf,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:a_,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==fc&&(fc&&t.type==="mousemove"?(Rg=t.screenX-fc.screenX,Cg=t.screenY-fc.screenY):Cg=Rg=0,fc=t),Rg)},movementY:function(t){return"movementY"in t?t.movementY:Cg}}),Ob=Or(om),ED=Gt({},om,{dataTransfer:0}),xD=Or(ED),TD=Gt({},Qf,{relatedTarget:0}),Ng=Or(TD),SD=Gt({},Ru,{animationName:0,elapsedTime:0,pseudoElement:0}),kD=Or(SD),AD=Gt({},Ru,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),ID=Or(AD),OD=Gt({},Ru,{data:0}),Pb=Or(OD),PD={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},RD={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},CD={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function ND(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=CD[t])?!!e[t]:!1}function a_(){return ND}var DD=Gt({},Qf,{key:function(t){if(t.key){var e=PD[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=yh(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?RD[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:a_,charCode:function(t){return t.type==="keypress"?yh(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?yh(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),MD=Or(DD),LD=Gt({},om,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Rb=Or(LD),jD=Gt({},Qf,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:a_}),FD=Or(jD),VD=Gt({},Ru,{propertyName:0,elapsedTime:0,pseudoElement:0}),UD=Or(VD),$D=Gt({},om,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),BD=Or($D),zD=[9,13,27,32],l_=As&&"CompositionEvent"in window,Fc=null;As&&"documentMode"in document&&(Fc=document.documentMode);var qD=As&&"TextEvent"in window&&!Fc,rk=As&&(!l_||Fc&&8<Fc&&11>=Fc),Cb=" ",Nb=!1;function ik(t,e){switch(t){case"keyup":return zD.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function sk(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Al=!1;function HD(t,e){switch(t){case"compositionend":return sk(e);case"keypress":return e.which!==32?null:(Nb=!0,Cb);case"textInput":return t=e.data,t===Cb&&Nb?null:t;default:return null}}function WD(t,e){if(Al)return t==="compositionend"||!l_&&ik(t,e)?(t=nk(),vh=s_=wo=null,Al=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return rk&&e.locale!=="ko"?null:e.data;default:return null}}var GD={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Db(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!GD[t.type]:e==="textarea"}function ok(t,e,n,r){j2(r),e=Xh(e,"onChange"),0<e.length&&(n=new o_("onChange","change",null,n,r),t.push({event:n,listeners:e}))}var Vc=null,af=null;function KD(t){vk(t,0)}function am(t){var e=Pl(t);if(P2(e))return t}function YD(t,e){if(t==="change")return e}var ak=!1;if(As){var Dg;if(As){var Mg="oninput"in document;if(!Mg){var Mb=document.createElement("div");Mb.setAttribute("oninput","return;"),Mg=typeof Mb.oninput=="function"}Dg=Mg}else Dg=!1;ak=Dg&&(!document.documentMode||9<document.documentMode)}
vendor: 5,410 bytes, line 37
37function Lb(){Vc&&(Vc.detachEvent("onpropertychange",lk),af=Vc=null)}function lk(t){if(t.propertyName==="value"&&am(af)){var e=[];ok(e,af,t,e_(t)),$2(KD,e)}}function QD(t,e,n){t==="focusin"?(Lb(),Vc=e,af=n,Vc.attachEvent("onpropertychange",lk)):t==="focusout"&&Lb()}function ZD(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return am(af)}function XD(t,e){if(t==="click")return am(e)}function JD(t,e){if(t==="input"||t==="change")return am(e)}function e4(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var ci=typeof Object.is=="function"?Object.is:e4;function lf(t,e){if(ci(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Pv.call(e,i)||!ci(t[i],e[i]))return!1}return!0}function jb(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Fb(t,e){var n=jb(t);t=0;for(var r;n;){if(n.nodeType===3){if(r=t+n.textContent.length,t<=e&&r>=e)return{node:n,offset:e-t};t=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=jb(n)}}function uk(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?uk(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function ck(){for(var t=window,e=Hh();e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href=="string"}catch{n=!1}if(n)t=e.contentWindow;else break;e=Hh(t.document)}return e}function u_(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function t4(t){var e=ck(),n=t.focusedElem,r=t.selectionRange;if(e!==n&&n&&n.ownerDocument&&uk(n.ownerDocument.documentElement,n)){if(r!==null&&u_(n)){if(e=r.start,t=r.end,t===void 0&&(t=e),"selectionStart"in n)n.selectionStart=e,n.selectionEnd=Math.min(t,n.value.length);else if(t=(e=n.ownerDocument||document)&&e.defaultView||window,t.getSelection){t=t.getSelection();var i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!t.extend&&s>r&&(i=r,r=s,s=i),i=Fb(n,s);var o=Fb(n,r);i&&o&&(t.rangeCount!==1||t.anchorNode!==i.node||t.anchorOffset!==i.offset||t.focusNode!==o.node||t.focusOffset!==o.offset)&&(e=e.createRange(),e.setStart(i.node,i.offset),t.removeAllRanges(),s>r?(t.addRange(e),t.extend(o.node,o.offset)):(e.setEnd(o.node,o.offset),t.addRange(e)))}}for(e=[],t=n;t=t.parentNode;)t.nodeType===1&&e.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<e.length;n++)t=e[n],t.element.scrollLeft=t.left,t.element.scrollTop=t.top}}var n4=As&&"documentMode"in document&&11>=document.documentMode,Il=null,Yv=null,Uc=null,Qv=!1;function Vb(t,e,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Qv||Il==null||Il!==Hh(r)||(r=Il,"selectionStart"in r&&u_(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Uc&&lf(Uc,r)||(Uc=r,r=Xh(Yv,"onSelect"),0<r.length&&(e=new o_("onSelect","select",null,e,n),t.push({event:e,listeners:r}),e.target=Il)))}function Bd(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n}var Ol={animationend:Bd("Animation","AnimationEnd"),animationiteration:Bd("Animation","AnimationIteration"),animationstart:Bd("Animation","AnimationStart"),transitionend:Bd("Transition","TransitionEnd")},Lg={},fk={};As&&(fk=document.createElement("div").style,"AnimationEvent"in window||(delete Ol.animationend.animation,delete Ol.animationiteration.animation,delete Ol.animationstart.animation),"TransitionEvent"in window||delete Ol.transitionend.transition);function lm(t){if(Lg[t])return Lg[t];if(!Ol[t])return t;var e=Ol[t],n;for(n in e)if(e.hasOwnProperty(n)&&n in fk)return Lg[t]=e[n];return t}var dk=lm("animationend"),hk=lm("animationiteration"),pk=lm("animationstart"),mk=lm("transitionend"),gk=new Map,Ub="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Ko(t,e){gk.set(t,e),il(e,[t])}for(var jg=0;jg<Ub.length;jg++){var Fg=Ub[jg],r4=Fg.toLowerCase(),i4=Fg[0].toUpperCase()+Fg.slice(1);Ko(r4,"on"+i4)}Ko(dk,"onAnimationEnd");Ko(hk,"onAnimationIteration");Ko(pk,"onAnimationStart");Ko("dblclick","onDoubleClick");Ko("focusin","onFocus");Ko("focusout","onBlur");Ko(mk,"onTransitionEnd");hu("onMouseEnter",["mouseout","mouseover"]);hu("onMouseLeave",["mouseout","mouseover"]);hu("onPointerEnter",["pointerout","pointerover"]);hu("onPointerLeave",["pointerout","pointerover"]);il("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));
vendor: 4,227 bytes, line 37
37il("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));il("onBeforeInput",["compositionend","keypress","textInput","paste"]);il("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));il("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));il("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ic="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),s4=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ic));function $b(t,e,n){var r=t.type||"unknown-event";t.currentTarget=n,rD(r,e,void 0,t),t.currentTarget=null}function vk(t,e){e=(e&4)!==0;for(var n=0;n<t.length;n++){var r=t[n],i=r.event;r=r.listeners;e:{var s=void 0;if(e)for(var o=r.length-1;0<=o;o--){var a=r[o],l=a.instance,u=a.currentTarget;if(a=a.listener,l!==s&&i.isPropagationStopped())break e;$b(i,a,u),s=l}else for(o=0;o<r.length;o++){if(a=r[o],l=a.instance,u=a.currentTarget,a=a.listener,l!==s&&i.isPropagationStopped())break e;$b(i,a,u),s=l}}}if(Gh)throw t=Hv,Gh=!1,Hv=null,t}function Nt(t,e){var n=e[ty];n===void 0&&(n=e[ty]=new Set);var r=t+"__bubble";n.has(r)||(yk(e,t,2,!1),n.add(r))}function Vg(t,e,n){var r=0;e&&(r|=4),yk(n,t,r,e)}var zd="_reactListening"+Math.random().toString(36).slice(2);function uf(t){if(!t[zd]){t[zd]=!0,S2.forEach(function(n){n!=="selectionchange"&&(s4.has(n)||Vg(n,!1,t),Vg(n,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[zd]||(e[zd]=!0,Vg("selectionchange",!1,e))}}function yk(t,e,n,r){switch(tk(e)){case 1:var i=_D;break;case 4:i=wD;break;default:i=i_}n=i.bind(null,e,n,t),i=void 0,!qv||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(i=!0),r?i!==void 0?t.addEventListener(e,n,{capture:!0,passive:i}):t.addEventListener(e,n,!0):i!==void 0?t.addEventListener(e,n,{passive:i}):t.addEventListener(e,n,!1)}function Ug(t,e,n,r,i){var s=r;if(!(e&1)&&!(e&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var a=r.stateNode.containerInfo;if(a===i||a.nodeType===8&&a.parentNode===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&(l=o.stateNode.containerInfo,l===i||l.nodeType===8&&l.parentNode===i))return;o=o.return}for(;a!==null;){if(o=va(a),o===null)return;if(l=o.tag,l===5||l===6){r=s=o;continue e}a=a.parentNode}}r=r.return}$2(function(){var u=s,c=e_(n),d=[];e:{var f=gk.get(t);if(f!==void 0){var p=o_,_=t;switch(t){case"keypress":if(yh(n)===0)break e;case"keydown":case"keyup":p=MD;break;case"focusin":_="focus",p=Ng;break;case"focusout":_="blur",p=Ng;break;case"beforeblur":case"afterblur":p=Ng;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=Ob;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=xD;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=FD;break;case dk:case hk:case pk:p=kD;break;case mk:p=UD;break;case"scroll":p=bD;break;case"wheel":p=BD;break;case"copy":case"cut":case"paste":p=ID;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=Rb}var y=(e&4)!==0,w=!y&&t==="scroll",g=y?f!==null?f+"Capture":null:f;y=[];for(var m=u,b;m!==null;){b=m;var v=b.stateNode;if(b.tag===5&&v!==null&&(b=v,g!==null&&(v=nf(m,g),v!=null&&y.push(cf(m,v,b)))),w)break;m=m.return}0<y.length&&(f=new p(f,_,null,n,c),d.push({event:f,listeners:y}))}}if(!(e&7)){e:{if(f=t==="mouseover"||t==="pointerover",p=t==="mouseout"||t==="pointerout",f&&n!==Bv&&(_=n.relatedTarget||n.fromElement)&&(va(_)||_[Is]))break e;if((p||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,p?(_=n.relatedTarget||n.toElement,p=u,_=_?va(_):null,_!==null&&(w=sl(_),_!==w||_.tag!==5&&_.tag!==6)&&(_=null)):(p=null,_=u),p!==_)){if(y=Ob,v="onMouseLeave",g="onMouseEnter",m="mou
37se",(t==="pointerout"||t==="pointerover")&&(y=Rb,v="onPointerLeave",g="onPointerEnter",m="pointer"),w=p==null?f:Pl(p),b=_==null?f:Pl(_),f=new y(v,m+"leave",p,n,c),f.target=w,f.relatedTarget=b,v=null,va(c)===u&&(y=new y(g,m+"enter",_,n,c),y.target=b,y.relatedTarget=w,v=y),w=v,p&&_)t:{for(y=p,g=_,m=0,b=y;b;b=vl(b))m++;for(b=0,v=g;v;v=vl(v))b++;for(;0<m-b;)y=vl(y),m--;for(;0<b-m;)g=vl(g),b--;for(;m--;){if(y===g||g!==null&&y===g.alternate)break t;y=vl(y),g=vl(g)}y=null}else y=null;p!==null&&Bb(d,f,p,y,!1),_!==null&&w!==null&&Bb(d,w,_,y,!0)}}e:{if(f=u?Pl(u):window,p=f.nodeName&&f.nodeName.toLowerCase(),p==="select"||p==="input"&&f.type==="file")var A=YD;else if(Db(f))if(ak)A=JD;else{A=ZD;var N=QD}else(p=f.nodeName)&&p.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(A=XD);if(A&&(A=A(t,u))){ok(d,A,n,c);break e}N&&N(t,f,u),t==="focusout"&&(N=f._wrapperState)&&N.controlled&&f.type==="number"&&jv(f,"number",f.value)}switch(N=u?Pl(u):window,t){case"focusin":(Db(N)||N.contentEditable==="true")&&(Il=N,Yv=u,Uc=null);break;case"focusout":Uc=Yv=Il=null;break;case"mousedown":Qv=!0;break;case"contextmenu":case"mouseup":case"dragend":Qv=!1,Vb(d,n,c);break;case"selectionchange":if(n4)break;case"keydown":case"keyup":Vb(d,n,c)}var x;if(l_)e:{switch(t){case"compositionstart":var E="onCompositionStart";break e;case"compositionend":E="onCompositionEnd";break e;case"compositionupdate":E="onCompositionUpdate";break e}E=void 0}else Al?ik(t,n)&&(E="onCompositionEnd"):t==="keydown"&&n.keyCode===229&&(E="onCompositionStart");E&&(rk&&n.locale!=="ko"&&(Al||E!=="onCompositionStart"?E==="onCompositionEnd"&&Al&&(x=nk()):(wo=c,s_="value"in wo?wo.value:wo.textContent,Al=!0)),N=Xh(u,E),0<N.length&&(E=new Pb(E,t,null,n,c),d.push({event:E,listeners:N}),x?E.data=x:(x=sk(n),x!==null&&(E.data=x)))),(x=qD?HD(t,n):WD(t,n))&&(u=Xh(u,"onBeforeInput"),0<u.length&&(c=new Pb("onBeforeInput","beforeinput",null,n,c),d.push({event:c,listeners:u}),c.data=x))}vk(d,e)})}function cf(t,e,n){return{instance:t,listener:e,currentTarget:n}}function Xh(t,e){for(var n=e+"Capture",r=[];t!==null;){var i=t,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=nf(t,n),s!=null&&r.unshift(cf(t,s,i)),s=nf(t,e),s!=null&&r.push(cf(t,s,i))),t=t.return}return r}function vl(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5);return t||null}function Bb(t,e,n,r,i){for(var s=e._reactName,o=[];n!==null&&n!==r;){var a=n,l=a.alternate,u=a.stateNode;if(l!==null&&l===r)break;a.tag===5&&u!==null&&(a=u,i?(l=nf(n,s),l!=null&&o.unshift(cf(n,l,a))):i||(l=nf(n,s),l!=null&&o.push(cf(n,l,a)))),n=n.return}o.length!==0&&t.push({event:e,listeners:o})}var o4=/\r\n?/g,a4=/\u0000|\uFFFD/g;function zb(t){return(typeof t=="string"?t:""+t).replace(o4,` 38`).replace(a4,"")}function qd(t,e,n){if(e=zb(e),zb(t)!==e&&n)throw Error(de(425))}function Jh(){}var Zv=null,Xv=null;function Jv(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var ey=typeof setTimeout=="function"?setTimeout:void 0,l4=typeof clearTimeout=="function"?clearTimeout:void 0,qb=typeof Promise=="function"?Promise:void 0,u4=typeof queueMicrotask=="function"?queueMicrotask:typeof qb<"u"?function(t){return qb.resolve(null).then(t).catch(c4)}:ey;function c4(t){setTimeout(function(){throw t})}function $g(t,e){var n=e,r=0;do{var i=n.nextSibling;if(t.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){t.removeChild(i),of(e);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);of(e)}function Po(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?")break;if(e==="/$")return null}}return t}function Hb(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="$"||n==="$!"||n==="$?"){if(e===0)return t;e--}else n==="/$"&&e++}t=t.previousSibling}return null}var Cu=Math.random().toString(36).slice(2),Pi="__reactFiber$"+Cu,ff="__reactProps$"+Cu,Is="__reactContainer$"+Cu,ty="__reactEvents$"+Cu,f4="__reactListeners$"+Cu,d4="__reactHandles$"+Cu;function va(t){var e=t[Pi];if(e)return e;for(var n=t.parentNode;n;){if(e=n[Is]||n[Pi]){if(n=e.alternate,e.child!==null||n!==null&&n.child!==null)for(t=Hb(t);t!==null;){if(n=t[Pi])return n;t=Hb(t)}return e}t=n,n=t.parentNode}return null}function Zf(t){return t=t[Pi]||t[Is],!t||t.tag!==5&&t.tag!==6&&t.tag!==13&&t.tag!==3?null:t}function Pl(t){if(t.tag===5||t.tag===6)return t.stateNode;throw Error(de(33))}function um(t){return t[ff]||null}var ny=[],Rl=-1;function Yo(t){return{current:t}}function jt(t){0>Rl||(t.current=ny[Rl],ny[Rl]=null,Rl--)}function It(t,e){Rl++,ny[Rl]=t.current,t.current=e}var $o={}
vendor: 29,022 bytes, lines 38-40
38,Fn=Yo($o),ur=Yo(!1),qa=$o;function pu(t,e){var n=t.type.contextTypes;if(!n)return $o;var r=t.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===e)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=e[s];return r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=e,t.__reactInternalMemoizedMaskedChildContext=i),i}function cr(t){return t=t.childContextTypes,t!=null}function ep(){jt(ur),jt(Fn)}function Wb(t,e,n){if(Fn.current!==$o)throw Error(de(168));It(Fn,e),It(ur,n)}function _k(t,e,n){var r=t.stateNode;if(e=e.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in e))throw Error(de(108,QN(t)||"Unknown",i));return Gt({},n,r)}function tp(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||$o,qa=Fn.current,It(Fn,t),It(ur,ur.current),!0}function Gb(t,e,n){var r=t.stateNode;if(!r)throw Error(de(169));n?(t=_k(t,e,qa),r.__reactInternalMemoizedMergedChildContext=t,jt(ur),jt(Fn),It(Fn,t)):jt(ur),It(ur,n)}var ss=null,cm=!1,Bg=!1;function wk(t){ss===null?ss=[t]:ss.push(t)}function h4(t){cm=!0,wk(t)}function Qo(){if(!Bg&&ss!==null){Bg=!0;var t=0,e=wt;try{var n=ss;for(wt=1;t<n.length;t++){var r=n[t];do r=r(!0);while(r!==null)}ss=null,cm=!1}catch(i){throw ss!==null&&(ss=ss.slice(t+1)),H2(t_,Qo),i}finally{wt=e,Bg=!1}}return null}var Cl=[],Nl=0,np=null,rp=0,Mr=[],Lr=0,Ha=null,fs=1,ds="";function ca(t,e){Cl[Nl++]=rp,Cl[Nl++]=np,np=t,rp=e}function bk(t,e,n){Mr[Lr++]=fs,Mr[Lr++]=ds,Mr[Lr++]=Ha,Ha=t;var r=fs;t=ds;var i=32-oi(r)-1;r&=~(1<<i),n+=1;var s=32-oi(e)+i;if(30<s){var o=i-i%5;s=(r&(1<<o)-1).toString(32),r>>=o,i-=o,fs=1<<32-oi(e)+i|n<<i|r,ds=s+t}else fs=1<<s|n<<i|r,ds=t}function c_(t){t.return!==null&&(ca(t,1),bk(t,1,0))}function f_(t){for(;t===np;)np=Cl[--Nl],Cl[Nl]=null,rp=Cl[--Nl],Cl[Nl]=null;for(;t===Ha;)Ha=Mr[--Lr],Mr[Lr]=null,ds=Mr[--Lr],Mr[Lr]=null,fs=Mr[--Lr],Mr[Lr]=null}var Sr=null,Er=null,qt=!1,ri=null;function Ek(t,e){var n=Vr(5,null,null,0);n.elementType="DELETED",n.stateNode=e,n.return=t,e=t.deletions,e===null?(t.deletions=[n],t.flags|=16):e.push(n)}function Kb(t,e){switch(t.tag){case 5:var n=t.type;return e=e.nodeType!==1||n.toLowerCase()!==e.nodeName.toLowerCase()?null:e,e!==null?(t.stateNode=e,Sr=t,Er=Po(e.firstChild),!0):!1;case 6:return e=t.pendingProps===""||e.nodeType!==3?null:e,e!==null?(t.stateNode=e,Sr=t,Er=null,!0):!1;case 13:return e=e.nodeType!==8?null:e,e!==null?(n=Ha!==null?{id:fs,overflow:ds}:null,t.memoizedState={dehydrated:e,treeContext:n,retryLane:1073741824},n=Vr(18,null,null,0),n.stateNode=e,n.return=t,t.child=n,Sr=t,Er=null,!0):!1;default:return!1}}function ry(t){return(t.mode&1)!==0&&(t.flags&128)===0}function iy(t){if(qt){var e=Er;if(e){var n=e;if(!Kb(t,e)){if(ry(t))throw Error(de(418));e=Po(n.nextSibling);var r=Sr;e&&Kb(t,e)?Ek(r,n):(t.flags=t.flags&-4097|2,qt=!1,Sr=t)}}else{if(ry(t))throw Error(de(418));t.flags=t.flags&-4097|2,qt=!1,Sr=t}}}function Yb(t){for(t=t.return;t!==null&&t.tag!==5&&t.tag!==3&&t.tag!==13;)t=t.return;Sr=t}function Hd(t){if(t!==Sr)return!1;if(!qt)return Yb(t),qt=!0,!1;var e;if((e=t.tag!==3)&&!(e=t.tag!==5)&&(e=t.type,e=e!=="head"&&e!=="body"&&!Jv(t.type,t.memoizedProps)),e&&(e=Er)){if(ry(t))throw xk(),Error(de(418));for(;e;)Ek(t,e),e=Po(e.nextSibling)}if(Yb(t),t.tag===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(de(317));e:{for(t=t.nextSibling,e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="/$"){if(e===0){Er=Po(t.nextSibling);break e}e--}else n!=="$"&&n!=="$!"&&n!=="$?"||e++}t=t.nextSibling}Er=null}}else Er=Sr?Po(t.stateNode.nextSibling):null;return!0}function xk(){for(var t=Er;t;)t=Po(t.nextSibling)}function mu(){Er=Sr=null,qt=!1}function d_(t){ri===null?ri=[t]:ri.push(t)}var p4=Fs.ReactCurrentBatchConfig;function dc(t,e,n){if(t=n.ref,t!==null&&typeof t!="function"&&typeof t!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(de(309));var r=n.stateNode}if(!r)throw Error(de(147,t));var i=r,s=""+t;return e!==null&&e.ref!==null&&typeof e.ref=="function"&&e.ref._stringRef===s?e.ref:(e=function(o){var a=i.refs;o===null?delete a[s]:a[s]=o},e._stringRef=s,e)}if(typeof t!="string")throw Error(de(284));if(!n._owner)throw Error(de(290,t))}return t}function Wd(t,e){throw t=Object.prototype.toString.call(e),Error(de(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t))}function Qb(t){var e=t._init;return e(t._payload)}function Tk(t){function e(g,m){if(t){var b=g.deletions;b===null?(g.deletions=[m],g.flags|=16):b.push(m)}}function n(g,m){if(!t)return null;for(;m!==null;)e(g,m),m=m.sibling;return null}function r(g,m){for(g=new Map;m!==null;)m.key!==null?g.set(m.key,m):g.set(m.index,m),m=m.sibling;return g}function i(g,m){return g=Do(g,m),g.index=0,g.sibling=null,g}function s(g,m,b){return g.index=b,t?(b=g.alternate,b!==null?(b=b.index,b<m?(g.flags|=2,m):b):(g.flags|=2,m)):(g.flags|=1048576,m)}function o(g){return t&&g.alternate===null&&(g.flags|=2),g}function a(g,m,b,v){return m===null||m.tag!==6?(m=Yg(b,g.mode,v),m.return=g,m):(m=i(m,b),m.return=g,m)}function l(g,m,b,v){var A=b.type;return A===kl?c(g,m,b.props.children,v,b.key):m!==null&&(m.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===no&&Qb(A)===m.type)?(v=i(m,b.props),v.ref=dc(g,m,b),v.return=g,v):(v=Sh(b.type,b.key,b.props,null,g.mode,v),v.ref=dc(g,m,b),v.return=g,v)}function u(g,m,b,v){return m===null||m.tag!==4||m.stateNode.containerInfo!==b.containerInfo||m.stateNode.implementation!==b.implementation?(m=Qg(b,g.mode,v),m.return=g,m):(m=i(m,b.children||[]),m.return=g,m)}function c(g,m,b,v,A){return m===null||m.tag!==7?(m=ja(b,g.mode,v,A),m.return=g,m):(m=i(m,b),m.return=g,m)}function d(g,m,b){if(typeof m=="string"&&m!==""||typeof m=="number")return m=Yg(""+m,g.mode,b),m.return=g,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case Md:return b=Sh(m.type,m.key,m.props,null,g.mode,b),b.ref=dc(g,null,m),b.return=g,b;case Sl:return m=Qg(m,g.mode,b),m.return=g,m;case no:var v=m._init;return d(g,v(m._payload),b)}if(kc(m)||ac(m))return m=ja(m,g.mode,b,null),m.return=g,m;Wd(g,m)}return null}function f(g,m,b,v){var A=m!==null?m.key:null;if(typeof b=="string"&&b!==""||typeof b=="number")return A!==null?null:a(g,m,""+b,v);if(typeof b=="object"&&b!==null){switch(b.$$typeof){case Md:return b.key===A?l(g,m,b,v):null;case Sl:return b.key===A?u(g,m,b,v):null;case no:return A=b._init,f(g,m,A(b._payload),v)}if(kc(b)||ac(b))return A!==null?null:c(g,m,b,v,null);Wd(g,b)}return null}function p(g,m,b,v,A){if(typeof v=="string"&&v!==""||typeof v=="number")return g=g.get(b)||null,a(m,g,""+v,A);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case Md:return g=g.get(v.key===null?b:v.key)||null,l(m,g,v,A);case Sl:return g=g.get(v.key===null?b:v.key)||null,u(m,g,v,A);case no:var N=v._init;return p(g,m,b,N(v._payload),A)}if(kc(v)||ac(v))return g=g.get(b)||null,c(m,g,v,A,null);Wd(m,v)}return null}function _(g,m,b,v){for(var A=null,N=null,x=m,E=m=0,T=null;x!==null&&E<b.length;E++){x.index>E?(T=x,x=null):T=x.sibling;var S=f(g,x,b[E],v);if(S===null){x===null&&(x=T);break}t&&x&&S.alternate===null&&e(g,x),m=s(S,m,E),N===null?A=S:N.sibling=S,N=S,x=T}if(E===b.length)return n(g,x),qt&&ca(g,E),A;if(x===null){for(;E<b.length;E++)x=d(g,b[E],v),x!==null&&(m=s(x,m,E),N===null?A=x:N.sibling=x,N=x);return qt&&ca(g,E),A}for(x=r(g,x);E<b.length;E++)T=p(x,g,E,b[E],v),T!==null&&(t&&T.alternate!==null&&x.delete(T.key===null?E:T.key),m=s(T,m,E),N===null?A=T:N.sibling=T,N=T);return t&&x.forEach(function(k){return e(g,k)}),qt&&ca(g,E),A}function y(g,m,b,v){var A=ac(b);if(typeof A!="function")throw Error(de(150));if(b=A.call(b),b==null)throw Error(de(151));for(var N=A=null,x=m,E=m=0,T=null,S=b.next();x!==null&&!S.done;E++,S=b.next()){x.index>E?(T=x,x=null):T=x.sibling;var k=f(g,x,S.value,v);if(k===null){x===null&&(x=T);break}t&&x&&k.alternate===null&&e(g,x),m=s(k,m,E),N===null?A=k:N.sibling=k,N=k,x=T}if(S.done)return n(g,x),qt&&ca(g,E),A;if(x===null){for(;!S.done;E++,S=b.next())S=d(g,S.value,v),S!==null&&(m=s(S,m,E),N===null?A=S:N.sibling=S,N=S);return qt&&ca(g,E),A}for(x=r(g,x);!S.done;E++,S=b.next())S=p(x,g,E,S.value,v),S!==null&&(t&&S.alternate!==null&&x.delete(S.key===null?E:S.key),m=s(S,m,E),N===null?A=S:N.sibling=S,N=S);return t&&x.forEach(function(I){return e(g,I)}),qt&&ca(g,E),A}function w(g,m,b,v){if(typeof b=="object"&&b!==null&&b.type===kl&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case Md:e:{for(var A=b.key,N=m;N!==null;){if(N.key===A){if(A=b.type,A===kl){if(N.tag===7){n(g,N.sibling),m=i(N,b.props.children),m.return=g,g=m;break e}}else if(N.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===no&&Qb(A)===N.type){n(g,N.sibling),m=i(N,b.props),m.ref=dc(g,N,b),m.return=g,g=m;break e}n(g,N);break}else e(g,N);N=N.sibling}b.type===kl?(m=ja(b.props.children,g.mode,v,b.key),m.return=g,g=m):(v=Sh(b.type,b.key,b.props,null,g.mode,v),v.ref=dc(g,m,b),v.return=g,g=v)}return o(g);case Sl:e:{for(N=b.key;m!==null;){if(m.key===N)if(m.tag===4&&m.stateNode.containerInfo===b.containerInfo&&m.stateNode.implementation===b.implementation){n(g,m.sibling),m=i(m,b.children||[]),m.return=g,g=m;break e}else{n(g,m);break}else e(g,m);m=m.sibling}m=Qg(b,g.mode,v),m.return=g,g=m}return o(g);case no:return N=b._init,w(g,m,N(b._payload),v)}if(kc(b))return _(g,m,b,v);if(ac(b))return y(g,m,b,v);Wd(g,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,m!==null&&m.tag===6?(n(g,m.sibling),m=i(m,b),m.return=g,g=m):(n(g,m),m=Yg(b,g.mode,v),m.return=g,g=m),o(g)):n(g,m)}return w}var gu=Tk(!0),Sk=Tk(!1),ip=Yo(null),sp=null,Dl=null,h_=null;function p_(){h_=Dl=sp=null}function m_(t){var e=ip.current;jt(ip),t._currentValue=e}function sy(t,e,n){for(;t!==null;){var r=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,r!==null&&(r.childLanes|=e)):r!==null&&(r.childLanes&e)!==e&&(r.childLanes|=e),t===n)break;t=t.return}}function ql(t,e){sp=t,h_=Dl=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&e&&(lr=!0),t.firstContext=null)}function $r(t){var e=t._currentValue;if(h_!==t)if(t={context:t,memoizedValue:e,next:null},Dl===null){if(sp===null)throw Error(de(308));Dl=t,sp.dependencies={lanes:0,firstContext:t}}else Dl=Dl.next=t;return e}var ya=null;function g_(t){ya===null?ya=[t]:ya.push(t)}function kk(t,e,n,r){var i=e.interleaved;return i===null?(n.next=n,g_(e)):(n.next=i.next,i.next=n),e.interleaved=n,Os(t,r)}function Os(t,e){t.lanes|=e;var n=t.alternate;for(n!==null&&(n.lanes|=e),n=t,t=t.return;t!==null;)t.childLanes|=e,n=t.alternate,n!==null&&(n.childLanes|=e),n=t,t=t.return;return n.tag===3?n.stateNode:null}var ro=!1;function v_(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Ak(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function _s(t,e){return{eventTime:t,lane:e,tag:0,payload:null,callback:null,next:null}}function Ro(t,e,n){var r=t.updateQueue;if(r===null)return null;if(r=r.shared,ft&2){var i=r.pending;return i===null?e.next=e:(e.next=i.next,i.next=e),r.pending=e,Os(t,n)}return i=r.interleaved,i===null?(e.next=e,g_(r)):(e.next=i.next,i.next=e),r.interleaved=e,Os(t,n)}function _h(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194240)!==0)){var r=e.lanes;r&=t.pendingLanes,n|=r,e.lanes=n,n_(t,n)}}function Zb(t,e){var n=t.updateQueue,r=t.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?i=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?i=s=e:s=s.next=e}else i=s=e;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:r.shared,effects:r.effects},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}function op(t,e,n,r){var i=t.updateQueue;ro=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,a=i.shared.pending;if(a!==null){i.shared.pending=null;var l=a,u=l.next;l.next=null,o===null?s=u:o.next=u,o=l;var c=t.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==o&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(s!==null){var d=i.baseState;o=0,c=u=l=null,a=s;do{var f=a.lane,p=a.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:p,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var _=t,y=a;switch(f=e,p=n,y.tag){case 1:if(_=y.payload,typeof _=="function"){d=_.call(p,d,f);break e}d=_;break e;case 3:_.flags=_.flags&-65537|128;case 0:if(_=y.payload,f=typeof _=="function"?_.call(p,d,f):_,f==null)break e;d=Gt({},d,f);break e;case 2:ro=!0}}a.callback!==null&&a.lane!==0&&(t.flags|=64,f=i.effects,f===null?i.effects=[a]:f.push(a))}else p={eventTime:p,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=p,l=d):c=c.next=p,o|=f;if(a=a.next,a===null){if(a=i.shared.pending,a===null)break;f=a,a=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(l=d),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,e=i.shared.interleaved,e!==null){i=e;do o|=i.lane,i=i.next;while(i!==e)}else s===null&&(i.shared.lanes=0);Ga|=o,t.lanes=o,t.memoizedState=d}}function Xb(t,e,n){if(t=e.effects,e.effects=null,t!==null)for(e=0;e<t.length;e++){var r=t[e],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(de(191,i));i.call(r)}}}var Xf={},Ni=Yo(Xf),df=Yo(Xf),hf=Yo(Xf);function _a(t){if(t===Xf)throw Error(de(174));return t}function y_(t,e){switch(It(hf,e),It(df,t),It(Ni,Xf),t=e.nodeType,t){case 9:case 11:e=(e=e.documentElement)?e.namespaceURI:Vv(null,"");break;default:t=t===8?e.parentNode:e,e=t.namespaceURI||null,t=t.tagName,e=Vv(e,t)}jt(Ni),It(Ni,e)}function vu(){jt(Ni),jt(df),jt(hf)}function Ik(t){_a(hf.current);var e=_a(Ni.current),n=Vv(e,t.type);e!==n&&(It(df,t),It(Ni,n))}function __(t){df.current===t&&(jt(Ni),jt(df))}var Ht=Yo(0);function ap(t){for(var e=t;e!==null;){if(e.tag===13){var n=e.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return e}else if(e.tag===19&&e.memoizedProps.revealOrder!==void 0){if(e.flags&128)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var zg=[];function w_(){for(var t=0;t<zg.length;t++)zg[t]._workInProgressVersionPrimary=null;zg.length=0}var wh=Fs.ReactCurrentDispatcher,qg=Fs.ReactCurrentBatchConfig,Wa=0,Wt=null,cn=null,vn=null,lp=!1,$c=!1,pf=0,m4=0;function Pn(){throw Error(de(321))}function b_(t,e){if(e===null)return!1;for(var n=0;n<e.length&&n<t.length;n++)if(!ci(t[n],e[n]))return!1;return!0}function E_(t,e,n,r,i,s){if(Wa=s,Wt=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,wh.current=t===null||t.memoizedState===null?_4:w4,t=n(r,i),$c){s=0;do{if($c=!1,pf=0,25<=s)throw Error(de(301));s+=1,vn=cn=null,e.updateQueue=null,wh.current=b4,t=n(r,i)}while($c)}if(wh.current=up,e=cn!==null&&cn.next!==null,Wa=0,vn=cn=Wt=null,lp=!1,e)throw Error(de(300));return t}function x_(){var t=pf!==0;return pf=0,t}function Si(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vn===null?Wt.memoizedState=vn=t:vn=vn.next=t,vn}function Br(){if(cn===null){var t=Wt.alternate;t=t!==null?t.memoizedState:null}else t=cn.next;var e=vn===null?Wt.memoizedState:vn.next;if(e!==null)vn=e,cn=t;else{if(t===null)throw Error(de(310));cn=t,t={memoizedState:cn.memoizedState,baseState:cn.baseState,baseQueue:cn.baseQueue,queue:cn.queue,next:null},vn===null?Wt.memoizedState=vn=t:vn=vn.next=t}return vn}function mf(t,e){return typeof e=="function"?e(t):e}function Hg(t){var e=Br(),n=e.queue;if(n===null)throw Error(de(311));n.lastRenderedReducer=t;var r=cn,i=r.baseQueue,s=n.pending;if(s!==null){if(i!==null){var o=i.next;i.next=s.next,s.next=o}r.baseQueue=i=s,n.pending=null}if(i!==null){s=i.next,r=r.baseState;var a=o=null,l=null,u=s;do{var c=u.lane;if((Wa&c)===c)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:t(r,u.action);else{var d={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(a=l=d,o=r):l=l.next=d,Wt.lanes|=c,Ga|=c}u=u.next}while(u!==null&&u!==s);l===null?o=r:l.next=a,ci(r,e.memoizedState)||(lr=!0),e.memoizedState=r,e.baseState=o,e.baseQueue=l,n.lastRenderedState=r}if(t=n.interleaved,t!==null){i=t;do s=i.lane,Wt.lanes|=s,Ga|=s,i=i.next;while(i!==t)}else i===null&&(n.lanes=0);return[e.memoizedState,n.dispatch]}function Wg(t){var e=Br(),n=e.queue;if(n===null)throw Error(de(311));n.lastRenderedReducer=t;var r=n.dispatch,i=n.pending,s=e.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do s=t(s,o.action),o=o.next;while(o!==i);ci(s,e.memoizedState)||(lr=!0),e.memoizedState=s,e.baseQueue===null&&(e.baseState=s),n.lastRenderedState=s}return[s,r]}function Ok(){}function Pk(t,e){var n=Wt,r=Br(),i=e(),s=!ci(r.memoizedState,i);if(s&&(r.memoizedState=i,lr=!0),r=r.queue,T_(Nk.bind(null,n,r,t),[t]),r.getSnapshot!==e||s||vn!==null&&vn.memoizedState.tag&1){if(n.flags|=2048,gf(9,Ck.bind(null,n,r,i,e),void 0,null),yn===null)throw Error(de(349));Wa&30||Rk(n,e,i)}return i}function Rk(t,e,n){t.flags|=16384,t={getSnapshot:e,value:n},e=Wt.updateQueue,e===null?(e={lastEffect:null,stores:null},Wt.updateQueue=e,e.stores=[t]):(n=e.stores,n===null?e.stores=[t]:n.push(t))}function Ck(t,e,n,r){e.value=n,e.getSnapshot=r,Dk(e)&&Mk(t)}function Nk(t,e,n){return n(function(){Dk(e)&&Mk(t)})}function Dk(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!ci(t,n)}catch{return!0}}function Mk(t){var e=Os(t,1);e!==null&&ai(e,t,1,-1)}function Jb(t){var e=Si();return typeof t=="function"&&(t=t()),e.memoizedState=e.baseState=t,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:mf,lastRenderedState:t},e.queue=t,t=t.dispatch=y4.bind(null,Wt,t),[e.memoizedState,t]}function gf(t,e,n,r){return t={tag:t,create:e,destroy:n,deps:r,next:null},e=Wt.updateQueue,e===null?(e={lastEffect:null,stores:null},Wt.updateQueue=e,e.lastEffect=t.next=t):(n=e.lastEffect,n===null?e.lastEffect=t.next=t:(r=n.next,n.next=t,t.next=r,e.lastEffect=t)),t}function Lk(){return Br().memoizedState}function bh(t,e,n,r){var i=Si();Wt.flags|=t,i.memoizedState=gf(1|e,n,void 0,r===void 0?null:r)}function fm(t,e,n,r){var i=Br();r=r===void 0?null:r;var s=void 0;if(cn!==null){var o=cn.memoizedState;if(s=o.destroy,r!==null&&b_(r,o.deps)){i.memoizedState=gf(e,n,s,r);return}}Wt.flags|=t,i.memoizedState=gf(1|e,n,s,r)}function eE(t,e){return bh(8390656,8,t,e)}function T_(t,e){return fm(2048,8,t,e)}function jk(t,e){return fm(4,2,t,e)}function Fk(t,e){return fm(4,4,t,e)}function Vk(t,e){if(typeof e=="function")return t=t(),e(t),function(){e(null)};if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function Uk(t,e,n){return n=n!=null?n.concat([t]):null,fm(4,4,Vk.bind(null,e,t),n)}function S_(){}function $k(t,e){var n=Br();e=e===void 0?null:e;var r=n.memoizedState;return r!==null&&e!==null&&b_(e,r[1])?r[0]:(n.memoizedState=[t,e],t)}function Bk(t,e){var n=Br();e=e===void 0?null:e;var r=n.memoizedState;return r!==null&&e!==null&&b_(e,r[1])?r[0]:(t=t(),n.memoizedState=[t,e],t)}function zk(t,e,n){return Wa&21?(ci(n,e)||(n=K2(),Wt.lanes|=n,Ga|=n,t.baseState=!0),e):(t.baseState&&(t.baseState=!1,lr=!0),t.memoizedState=n)}function g4(t,e){var n=wt;wt=n!==0&&4>n?n:4,t(!0);var r=qg.transition;qg.transition={};try{t(!1),e()}finally{wt=n,qg.transition=r}}function qk(){return Br().memoizedState}function v4(t,e,n){var r=No(t);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Hk(t))Wk(e,n);else if(n=kk(t,e,n,r),n!==null){var i=Qn();ai(n,t,r,i),Gk(n,e,r)}}function y4(t,e,n){var r=No(t),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Hk(t))Wk(e,i);else{var s=t.alternate;if(t.lanes===0&&(s===null||s.lanes===0)&&(s=e.lastRenderedReducer,s!==null))try{var o=e.lastRenderedState,a=s(o,n);if(i.hasEagerState=!0,i.eagerState=a,ci(a,o)){var l=e.interleaved;l===null?(i.next=i,g_(e)):(i.next=l.next,l.next=i),e.interleaved=i;return}}catch{}finally{}n=kk(t,e,i,r),n!==null&&(i=Qn(),ai(n,t,r,i),Gk(n,e,r))}}function Hk(t){var e=t.alternate;return t===Wt||e!==null&&e===Wt}function Wk(t,e){$c=lp=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function Gk(t,e,n){if(n&4194240){var r=e.lanes;r&=t.pendingLanes,n|=r,e.lanes=n,n_(t,n)}}var up={readContext:$r,useCallback:Pn,useContext:Pn,useEffect:Pn,useImperativeHandle:Pn,useInsertionEffect:Pn,useLayoutEffect:Pn,useMemo:Pn,useReducer:Pn,useRef:Pn,useState:Pn,useDebugValue:Pn,useDeferredValue:Pn,useTransition:Pn,useMutableSource:Pn,useSyncExternalStore:Pn,useId:Pn,unstable_isNewReconciler:!1},_4={readContext:$r,useCallback:function(t,e){return Si().memoizedState=[t,e===void 0?null:e],t},useContext:$r,useEffect:eE,useImperativeHandle:function(t,e,n){return n=n!=null?n.concat([t]):null,bh(4194308,4,Vk.bind(null,e,t),n)},useLayoutEffect:function(t,e){return bh(4194308,4,t,e)},useInsertionEffect:function(t,e){return bh(4,2,t,e)},useMemo:function(t,e){var n=Si();return e=e===void 0?null:e,t=t(),n.memoizedState=[t,e],t},useReducer:function(t,e,n){var r=Si();return e=n!==void 0?n(e):e,r.memoizedState=r.baseState=e,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:e},r.queue=t,t=t.dispatch=v4.bind(null,Wt,t),[r.memoizedState,t]},useRef:function(t){var e=Si();return t={current:t},e.memoizedState=t},useState:Jb,useDebugValue:S_,useDeferredValue:function(t){return Si().memoizedState=t},useTransition:function(){var t=Jb(!1),e=t[0];return t=g4.bind(null,t[1]),Si().memoizedState=t,[e,t]},useMutableSource:function(){},useSyncExternalStore:function(t,e,n){var r=Wt,i=Si();if(qt){if(n===void 0)throw Error(de(407));n=n()}else{if(n=e(),yn===null)throw Error(de(349));Wa&30||Rk(r,e,n)}i.memoizedState=n;var s={value:n,getSnapshot:e};return i.queue=s,eE(Nk.bind(null,r,s,t),[t]),r.flags|=2048,gf(9,Ck.bind(null,r,s,n,e),void 0,null),n},useId:function(){var t=Si(),e=yn.identifierPrefix;if(qt){var n=ds,r=fs;n=(r&~(1<<32-oi(r)-1)).toString(32)+n,e=":"+e+"R"+n,n=pf++,0<n&&(e+="H"+n.toString(32)),e+=":"}else n=m4++,e=":"+e+"r"+n.toString(32)+":";return t.memoizedState=e},unstable_isNewReconciler:!1},w4={readContext:$r,useCallback:$k,useContext:$r,useEffect:T_,useImperativeHandle:Uk,useInsertionEffect:jk,useLayoutEffect:Fk,useMemo:Bk,useReducer:Hg,useRef:Lk,useState:function(){return Hg(mf)},useDebugValue:S_,useDeferredValue:function(t){var e=Br();return zk(e,cn.memoizedState,t)},useTransition:function(){var t=Hg(mf)[0],e=Br().memoizedState;return[t,e]},useMutableSource:Ok,useSyncExternalStore:Pk,useId:qk,unstable_isNewReconciler:!1},b4={readContext:$r,useCallback:$k,useContext:$r,useEffect:T_,useImperativeHandle:Uk,useInsertionEffect:jk,useLayoutEffect:Fk,useMemo:Bk,useReducer:Wg,useRef:Lk,useState:function(){return Wg(mf)},useDebugValue:S_,useDeferredValue:function(t){var e=Br();return cn===null?e.memoizedState=t:zk(e,cn.memoizedState,t)},useTransition:function(){var t=Wg(mf)[0],e=Br().memoizedState;return[t,e]},useMutableSource:Ok,useSyncExternalStore:Pk,useId:qk,unstable_isNewReconciler:!1};function Jr(t,e){if(t&&t.defaultProps){e=Gt({},e),t=t.defaultProps;for(var n in t)e[n]===void 0&&(e[n]=t[n]);return e}return e}function oy(t,e,n,r){e=t.memoizedState,n=n(r,e),n=n==null?e:Gt({},e,n),t.memoizedState=n,t.lanes===0&&(t.updateQueue.baseState=n)}var dm={isMounted:function(t){return(t=t._reactInternals)?sl(t)===t:!1},enqueueSetState:function(t,e,n){t=t._reactInternals;var r=Qn(),i=No(t),s=_s(r,i);s.payload=e,n!=null&&(s.callback=n),e=Ro(t,s,i),e!==null&&(ai(e,t,i,r),_h(e,t,i))},enqueueReplaceState:function(t,e,n){t=t._reactInternals;var r=Qn(),i=No(t),s=_s(r,i);s.tag=1,s.payload=e,n!=null&&(s.callback=n),e=Ro(t,s,i),e!==null&&(ai(e,t,i,r),_h(e,t,i))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var n=Qn(),r=No(t),i=_s(n,r);i.tag=2,e!=null&&(i.callback=e),e=Ro(t,i,r),e!==null&&(ai(e,t,r,n),_h(e,t,r))}};function tE(t,e,n,r,i,s,o){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(r,s,o):e.prototype&&e.prototype.isPureReactComponent?!lf(n,r)||!lf(i,s):!0}function Kk(t,e,n){var r=!1,i=$o,s=e.contextType;return typeof s=="object"&&s!==null?s=$r(s):(i=cr(e)?qa:Fn.current,r=e.contextTypes,s=(r=r!=null)?pu(t,i):$o),e=new e(n,s),t.memoizedState=e.state!==null&&e.state!==void 0?e.state:null,e.updater=dm,t.stateNode=e,e._reactInternals=t,r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=i,t.__reactInternalMemoizedMaskedChildContext=s),e}function nE(t,e,n,r){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(n,r),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(n,r),e.state!==t&&dm.enqueueReplaceState(e,e.state,null)}function ay(t,e,n,r){var i=t.stateNode;i.props=n,i.state=t.memoizedState,i.refs={},v_(t);var s=e.contextType;typeof s=="object"&&s!==null?i.context=$r(s):(s=cr(e)?qa:Fn.current,i.context=pu(t,s)),i.state=t.memoizedState,s=e.getDerivedStateFromProps,typeof s=="function"&&(oy(t,e,s,n),i.state=t.memoizedState),typeof e.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(e=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),e!==i.state&&dm.enqueueReplaceState(i,i.state,null),op(t,n,i,r),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308)}function yu(t,e){try{var n="",r=e;do n+=YN(r),r=r.return;while(r);var i=n}catch(s){i=` 39Error generating stack: `+s.message+` 40`+s.stack}return{value:t,source:e,stack:i,digest:null}}function Gg(t,e,n){return{value:t,source:null,stack:n??null,digest:e??null}}function ly(t,e){try{console.error(e.value)}catch(n){setTimeout(function(){throw n})}}var E4=typeof WeakMap=="function"?WeakMap:Map;function Yk(t,e,n){n=_s(-1,n),n.tag=3,n.payload={element:null};var r=e.value;return n.callback=function(){fp||(fp=!0,yy=r),ly(t,e)},n}function Qk(t,e,n){n=_s(-1,n),n.tag=3;var r=t.type.getDerivedStateFromError;if(typeof r=="function"){var i=e.value;n.payload=function(){return r(i)},n.callback=function(){ly(t,e)}}var s=t.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){ly(t,e),typeof r!="function"&&(Co===null?Co=new Set([this]):Co.add(this));var o=e.stack;this.componentDidCatch(e.value,{componentStack:o!==null?o:""})}),n}function rE(t,e,n){var r=t.pingCache;if(r===null){r=t.pingCache=new E4;var i=new Set;r.set(e,i)}else i=r.get(e),i===void 0&&(i=new Set,r.set(e,i));i.has(n)||(i.add(n),t=L4.bind(null,t,e,n),e.then(t,t))}function iE(t){do{var e;if((e=t.tag===13)&&(e=t.memoizedState,e=e!==null?e.dehydrated!==null:!0),e)return t;t=t.return}while(t!==null);return null}function sE(t,e,n,r,i){return t.mode&1?(t.flags|=65536,t.lanes=i,t):(t===e?t.flags|=65536:(t.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(e=_s(-1,1),e.tag=2,Ro(n,e,1))),n.lanes|=1),t)}var x4=Fs.ReactCurrentOwner,lr=!1;function qn(t,e,n,r){e.child=t===null?Sk(e,null,n,r):gu(e,t.child,n,r)}function oE(t,e,n,r,i){n=n.render;var s=e.ref;return ql(e,i),r=E_(t,e,n,r,s,i),n=x_(),t!==null&&!lr?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,Ps(t,e,i)):(qt&&n&&c_(e),e.flags|=1,qn(t,e,r,i),e.child)}function aE(t,e,n,r,i){if(t===null){var s=n.type;return typeof s=="function"&&!N_(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(e.tag=15,e.type=s,Zk(t,e,s,r,i)):(t=Sh(n.type,null,r,e,e.mode,i),t.ref=e.ref,t.return=e,e.child=t)}if(s=t.child,!(t.lanes&i)){var o=s.memoizedProps;if(n=n.compare,n=n!==null?n:lf,n(o,r)&&t.ref===e.ref)return Ps(t,e,i)}return e.flags|=1,t=Do(s,r),t.ref=e.ref,t.return=e,e.child=t}function Zk(t,e,n,r,i){if(t!==null){var s=t.memoizedProps;if(lf(s,r)&&t.ref===e.ref)if(lr=!1,e.pendingProps=r=s,(t.lanes&i)!==0)t.flags&131072&&(lr=!0);else return e.lanes=t.lanes,Ps(t,e,i)}return uy(t,e,n,r,i)}function Xk(t,e,n){var r=e.pendingProps,i=r.children,s=t!==null?t.memoizedState:null;if(r.mode==="hidden")if(!(e.mode&1))e.memoizedState={baseLanes:0,cachePool:null,transitions:null},It(Ll,vr),vr|=n;else{if(!(n&1073741824))return t=s!==null?s.baseLanes|n:n,e.lanes=e.childLanes=1073741824,e.memoizedState={baseLanes:t,cachePool:null,transitions:null},e.updateQueue=null,It(Ll,vr),vr|=t,null;e.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,It(Ll,vr),vr|=r}else s!==null?(r=s.baseLanes|n,e.memoizedState=null):r=n,It(Ll,vr),vr|=r;return qn(t,e,i,n),e.child}function Jk(t,e){var n=e.ref;(t===null&&n!==null||t!==null&&t.ref!==n)&&(e.flags|=512,e.flags|=2097152)}
vendor: 5,244 bytes, line 40
40function uy(t,e,n,r,i){var s=cr(n)?qa:Fn.current;return s=pu(e,s),ql(e,i),n=E_(t,e,n,r,s,i),r=x_(),t!==null&&!lr?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,Ps(t,e,i)):(qt&&r&&c_(e),e.flags|=1,qn(t,e,n,i),e.child)}function lE(t,e,n,r,i){if(cr(n)){var s=!0;tp(e)}else s=!1;if(ql(e,i),e.stateNode===null)Eh(t,e),Kk(e,n,r),ay(e,n,r,i),r=!0;else if(t===null){var o=e.stateNode,a=e.memoizedProps;o.props=a;var l=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=$r(u):(u=cr(n)?qa:Fn.current,u=pu(e,u));var c=n.getDerivedStateFromProps,d=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";d||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==r||l!==u)&&nE(e,o,r,u),ro=!1;var f=e.memoizedState;o.state=f,op(e,r,o,i),l=e.memoizedState,a!==r||f!==l||ur.current||ro?(typeof c=="function"&&(oy(e,n,c,r),l=e.memoizedState),(a=ro||tE(e,n,a,r,f,l,u))?(d||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(e.flags|=4194308)):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=r,e.memoizedState=l),o.props=r,o.state=l,o.context=u,r=a):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),r=!1)}else{o=e.stateNode,Ak(t,e),a=e.memoizedProps,u=e.type===e.elementType?a:Jr(e.type,a),o.props=u,d=e.pendingProps,f=o.context,l=n.contextType,typeof l=="object"&&l!==null?l=$r(l):(l=cr(n)?qa:Fn.current,l=pu(e,l));var p=n.getDerivedStateFromProps;(c=typeof p=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==d||f!==l)&&nE(e,o,r,l),ro=!1,f=e.memoizedState,o.state=f,op(e,r,o,i);var _=e.memoizedState;a!==d||f!==_||ur.current||ro?(typeof p=="function"&&(oy(e,n,p,r),_=e.memoizedState),(u=ro||tE(e,n,u,r,f,_,l)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,_,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,_,l)),typeof o.componentDidUpdate=="function"&&(e.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),e.memoizedProps=r,e.memoizedState=_),o.props=r,o.state=_,o.context=l,r=u):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),r=!1)}return cy(t,e,n,r,s,i)}function cy(t,e,n,r,i,s){Jk(t,e);var o=(e.flags&128)!==0;if(!r&&!o)return i&&Gb(e,n,!1),Ps(t,e,s);r=e.stateNode,x4.current=e;var a=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return e.flags|=1,t!==null&&o?(e.child=gu(e,t.child,null,s),e.child=gu(e,null,a,s)):qn(t,e,a,s),e.memoizedState=r.state,i&&Gb(e,n,!0),e.child}function eA(t){var e=t.stateNode;e.pendingContext?Wb(t,e.pendingContext,e.pendingContext!==e.context):e.context&&Wb(t,e.context,!1),y_(t,e.containerInfo)}function uE(t,e,n,r,i){return mu(),d_(i),e.flags|=256,qn(t,e,n,r),e.child}var fy={dehydrated:null,treeContext:null,retryLane:0};function dy(t){return{baseLanes:t,cachePool:null,transitions:null}}function tA(t,e,n){var r=e.pendingProps,i=Ht.current,s=!1,o=(e.flags&128)!==0,a;if((a=o)||(a=t!==null&&t.memoizedState===null?!1:(i&2)!==0),a?(s=!0,e.flags&=-129):(t===null||t.memoizedState!==null)&&(i|=1),It(Ht,i&1),t===null)return iy(e),t=e.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?(e.mode&1?t.data==="$!"?e.lanes=8:e.lanes=1073741824:e.lanes=1,null):(o=r.children,t=r.fallback,s?(r=e.mode,s=e.child,o={mode:"hidden",children:o},!(r&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=mm(o,r,0,null),t=ja(t,r,n,null),s.return=e,t.return=e,s.sibling=t,e.child=s,e.child.memoizedState=dy(n),e.memoizedState=fy,t):k_(e,o));if(i=t.memoizedState,i!==null&&(a=i.dehydrated,a!==null))return T4(t,e,o,r,a,i,n);if(s){s=r.fallback,o=e.mode,i=t.child,a=i.sibling;var l={mode:"hidden",children:r.children};return!(o&1)&&e.child!==i?(r=e.child,r.childLanes=0,r.pendingProps=l,e.deletions=null):(r=Do(i,l),r.subtreeFlags=i.subtreeFlags&14680064),a!==null?s=Do(a,s):(s=ja(s,o,n,null),s.flags|=2),s.return=e,r.return=e,r.sibling=s,e.child=r,r=s,s=e.child,o=t.child.memoizedState,o=o===null?dy(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=t.childLanes&~n,e.memoizedState=fy,r}return s=t.child,t=s.sibling,r=Do(s,{mode:"visible",children:r.children}),!(e.mode&1)&&(r.lanes=n),r.return=e,r.sibling=null,t!==null&&(n=e.deletions,n===null?(e.deletions=[t],e.flags|=16):n.push(t)),e.child=r,e.memoizedState=null,r}function k_(t,e){return e=mm({mode:"visible",children:e},t.mode,0,null),e.return=t,t.child=e}function Gd(t,e,n,r){return r!==null&&d_(r),gu(e,t.child,null,n),t=k_(e,e.pen
vendor: 4,919 bytes, line 40
40dingProps.children),t.flags|=2,e.memoizedState=null,t}function T4(t,e,n,r,i,s,o){if(n)return e.flags&256?(e.flags&=-257,r=Gg(Error(de(422))),Gd(t,e,o,r)):e.memoizedState!==null?(e.child=t.child,e.flags|=128,null):(s=r.fallback,i=e.mode,r=mm({mode:"visible",children:r.children},i,0,null),s=ja(s,i,o,null),s.flags|=2,r.return=e,s.return=e,r.sibling=s,e.child=r,e.mode&1&&gu(e,t.child,null,o),e.child.memoizedState=dy(o),e.memoizedState=fy,s);if(!(e.mode&1))return Gd(t,e,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var a=r.dgst;return r=a,s=Error(de(419)),r=Gg(s,r,void 0),Gd(t,e,o,r)}if(a=(o&t.childLanes)!==0,lr||a){if(r=yn,r!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,Os(t,i),ai(r,t,i,-1))}return C_(),r=Gg(Error(de(421))),Gd(t,e,o,r)}return i.data==="$?"?(e.flags|=128,e.child=t.child,e=j4.bind(null,t),i._reactRetry=e,null):(t=s.treeContext,Er=Po(i.nextSibling),Sr=e,qt=!0,ri=null,t!==null&&(Mr[Lr++]=fs,Mr[Lr++]=ds,Mr[Lr++]=Ha,fs=t.id,ds=t.overflow,Ha=e),e=k_(e,r.children),e.flags|=4096,e)}function cE(t,e,n){t.lanes|=e;var r=t.alternate;r!==null&&(r.lanes|=e),sy(t.return,e,n)}function Kg(t,e,n,r,i){var s=t.memoizedState;s===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(s.isBackwards=e,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=n,s.tailMode=i)}function nA(t,e,n){var r=e.pendingProps,i=r.revealOrder,s=r.tail;if(qn(t,e,r.children,n),r=Ht.current,r&2)r=r&1|2,e.flags|=128;else{if(t!==null&&t.flags&128)e:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&cE(t,n,e);else if(t.tag===19)cE(t,n,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}r&=1}if(It(Ht,r),!(e.mode&1))e.memoizedState=null;else switch(i){case"forwards":for(n=e.child,i=null;n!==null;)t=n.alternate,t!==null&&ap(t)===null&&(i=n),n=n.sibling;n=i,n===null?(i=e.child,e.child=null):(i=n.sibling,n.sibling=null),Kg(e,!1,i,n,s);break;case"backwards":for(n=null,i=e.child,e.child=null;i!==null;){if(t=i.alternate,t!==null&&ap(t)===null){e.child=i;break}t=i.sibling,i.sibling=n,n=i,i=t}Kg(e,!0,n,null,s);break;case"together":Kg(e,!1,null,null,void 0);break;default:e.memoizedState=null}return e.child}function Eh(t,e){!(e.mode&1)&&t!==null&&(t.alternate=null,e.alternate=null,e.flags|=2)}function Ps(t,e,n){if(t!==null&&(e.dependencies=t.dependencies),Ga|=e.lanes,!(n&e.childLanes))return null;if(t!==null&&e.child!==t.child)throw Error(de(153));if(e.child!==null){for(t=e.child,n=Do(t,t.pendingProps),e.child=n,n.return=e;t.sibling!==null;)t=t.sibling,n=n.sibling=Do(t,t.pendingProps),n.return=e;n.sibling=null}return e.child}function S4(t,e,n){switch(e.tag){case 3:eA(e),mu();break;case 5:Ik(e);break;case 1:cr(e.type)&&tp(e);break;case 4:y_(e,e.stateNode.containerInfo);break;case 10:var r=e.type._context,i=e.memoizedProps.value;It(ip,r._currentValue),r._currentValue=i;break;case 13:if(r=e.memoizedState,r!==null)return r.dehydrated!==null?(It(Ht,Ht.current&1),e.flags|=128,null):n&e.child.childLanes?tA(t,e,n):(It(Ht,Ht.current&1),t=Ps(t,e,n),t!==null?t.sibling:null);It(Ht,Ht.current&1);break;case 19:if(r=(n&e.childLanes)!==0,t.flags&128){if(r)return nA(t,e,n);e.flags|=128}if(i=e.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),It(Ht,Ht.current),r)break;return null;case 22:case 23:return e.lanes=0,Xk(t,e,n)}return Ps(t,e,n)}var rA,hy,iA,sA;rA=function(t,e){for(var n=e.child;n!==null;){if(n.tag===5||n.tag===6)t.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};hy=function(){};iA=function(t,e,n,r){var i=t.memoizedProps;if(i!==r){t=e.stateNode,_a(Ni.current);var s=null;switch(n){case"input":i=Mv(t,i),r=Mv(t,r),s=[];break;case"select":i=Gt({},i,{value:void 0}),r=Gt({},r,{value:void 0}),s=[];break;case"textarea":i=Fv(t,i),r=Fv(t,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(t.onclick=Jh)}Uv(n,r);var o;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var a=i[u];for(o in a)a.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(ef.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in r){var l=r[u];
vendor: 4,070 bytes, line 40
40if(a=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&l!==a&&(l!=null||a!=null))if(u==="style")if(a){for(o in a)!a.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in l)l.hasOwnProperty(o)&&a[o]!==l[o]&&(n||(n={}),n[o]=l[o])}else n||(s||(s=[]),s.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(s=s||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(s=s||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(ef.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&Nt("scroll",t),s||a===l||(s=[])):(s=s||[]).push(u,l))}n&&(s=s||[]).push("style",n);var u=s;(e.updateQueue=u)&&(e.flags|=4)}};sA=function(t,e,n,r){n!==r&&(e.flags|=4)};function hc(t,e){if(!qt)switch(t.tailMode){case"hidden":e=t.tail;for(var n=null;e!==null;)e.alternate!==null&&(n=e),e=e.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:r.sibling=null}}function Rn(t){var e=t.alternate!==null&&t.alternate.child===t.child,n=0,r=0;if(e)for(var i=t.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=t,i=i.sibling;else for(i=t.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=t,i=i.sibling;return t.subtreeFlags|=r,t.childLanes=n,e}function k4(t,e,n){var r=e.pendingProps;switch(f_(e),e.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Rn(e),null;case 1:return cr(e.type)&&ep(),Rn(e),null;case 3:return r=e.stateNode,vu(),jt(ur),jt(Fn),w_(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(t===null||t.child===null)&&(Hd(e)?e.flags|=4:t===null||t.memoizedState.isDehydrated&&!(e.flags&256)||(e.flags|=1024,ri!==null&&(by(ri),ri=null))),hy(t,e),Rn(e),null;case 5:__(e);var i=_a(hf.current);if(n=e.type,t!==null&&e.stateNode!=null)iA(t,e,n,r,i),t.ref!==e.ref&&(e.flags|=512,e.flags|=2097152);else{if(!r){if(e.stateNode===null)throw Error(de(166));return Rn(e),null}if(t=_a(Ni.current),Hd(e)){r=e.stateNode,n=e.type;var s=e.memoizedProps;switch(r[Pi]=e,r[ff]=s,t=(e.mode&1)!==0,n){case"dialog":Nt("cancel",r),Nt("close",r);break;case"iframe":case"object":case"embed":Nt("load",r);break;case"video":case"audio":for(i=0;i<Ic.length;i++)Nt(Ic[i],r);break;case"source":Nt("error",r);break;case"img":case"image":case"link":Nt("error",r),Nt("load",r);break;case"details":Nt("toggle",r);break;case"input":_b(r,s),Nt("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},Nt("invalid",r);break;case"textarea":bb(r,s),Nt("invalid",r)}Uv(n,s),i=null;for(var o in s)if(s.hasOwnProperty(o)){var a=s[o];o==="children"?typeof a=="string"?r.textContent!==a&&(s.suppressHydrationWarning!==!0&&qd(r.textContent,a,t),i=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(s.suppressHydrationWarning!==!0&&qd(r.textContent,a,t),i=["children",""+a]):ef.hasOwnProperty(o)&&a!=null&&o==="onScroll"&&Nt("scroll",r)}switch(n){case"input":Ld(r),wb(r,s,!0);break;case"textarea":Ld(r),Eb(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=Jh)}r=i,e.updateQueue=r,r!==null&&(e.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,t==="http://www.w3.org/1999/xhtml"&&(t=N2(n)),t==="http://www.w3.org/1999/xhtml"?n==="script"?(t=o.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild)):typeof r.is=="string"?t=o.createElement(n,{is:r.is}):(t=o.createElement(n),n==="select"&&(o=t,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):t=o.createElementNS(t,n),t[Pi]=e,t[ff]=r,rA(t,e,!1,!1),e.stateNode=t;e:{switch(o=$v(n,r),n){case"dialog":Nt("cancel",t),Nt("close",t),i=r;break;case"iframe":case"object":case"embed":Nt("load",t),i=r;break;case"video":case"audio":for(i=0;i<Ic.length;i++)Nt(Ic[i],t);i=r;break;case"source":Nt("error",t),i=r;break;case"img":case"image":case"link":Nt("error",t),Nt("load",t),i=r;break;case"details":Nt("toggle",t),i=r;break;
vendor: 4,452 bytes, line 40
40case"input":_b(t,r),i=Mv(t,r),Nt("invalid",t);break;case"option":i=r;break;case"select":t._wrapperState={wasMultiple:!!r.multiple},i=Gt({},r,{value:void 0}),Nt("invalid",t);break;case"textarea":bb(t,r),i=Fv(t,r),Nt("invalid",t);break;default:i=r}Uv(n,i),a=i;for(s in a)if(a.hasOwnProperty(s)){var l=a[s];s==="style"?L2(t,l):s==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&D2(t,l)):s==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&tf(t,l):typeof l=="number"&&tf(t,""+l):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(ef.hasOwnProperty(s)?l!=null&&s==="onScroll"&&Nt("scroll",t):l!=null&&Q0(t,s,l,o))}switch(n){case"input":Ld(t),wb(t,r,!1);break;case"textarea":Ld(t),Eb(t);break;case"option":r.value!=null&&t.setAttribute("value",""+Uo(r.value));break;case"select":t.multiple=!!r.multiple,s=r.value,s!=null?Ul(t,!!r.multiple,s,!1):r.defaultValue!=null&&Ul(t,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(t.onclick=Jh)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(e.flags|=4)}e.ref!==null&&(e.flags|=512,e.flags|=2097152)}return Rn(e),null;case 6:if(t&&e.stateNode!=null)sA(t,e,t.memoizedProps,r);else{if(typeof r!="string"&&e.stateNode===null)throw Error(de(166));if(n=_a(hf.current),_a(Ni.current),Hd(e)){if(r=e.stateNode,n=e.memoizedProps,r[Pi]=e,(s=r.nodeValue!==n)&&(t=Sr,t!==null))switch(t.tag){case 3:qd(r.nodeValue,n,(t.mode&1)!==0);break;case 5:t.memoizedProps.suppressHydrationWarning!==!0&&qd(r.nodeValue,n,(t.mode&1)!==0)}s&&(e.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Pi]=e,e.stateNode=r}return Rn(e),null;case 13:if(jt(Ht),r=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(qt&&Er!==null&&e.mode&1&&!(e.flags&128))xk(),mu(),e.flags|=98560,s=!1;else if(s=Hd(e),r!==null&&r.dehydrated!==null){if(t===null){if(!s)throw Error(de(318));if(s=e.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(de(317));s[Pi]=e}else mu(),!(e.flags&128)&&(e.memoizedState=null),e.flags|=4;Rn(e),s=!1}else ri!==null&&(by(ri),ri=null),s=!0;if(!s)return e.flags&65536?e:null}return e.flags&128?(e.lanes=n,e):(r=r!==null,r!==(t!==null&&t.memoizedState!==null)&&r&&(e.child.flags|=8192,e.mode&1&&(t===null||Ht.current&1?dn===0&&(dn=3):C_())),e.updateQueue!==null&&(e.flags|=4),Rn(e),null);case 4:return vu(),hy(t,e),t===null&&uf(e.stateNode.containerInfo),Rn(e),null;case 10:return m_(e.type._context),Rn(e),null;case 17:return cr(e.type)&&ep(),Rn(e),null;case 19:if(jt(Ht),s=e.memoizedState,s===null)return Rn(e),null;if(r=(e.flags&128)!==0,o=s.rendering,o===null)if(r)hc(s,!1);else{if(dn!==0||t!==null&&t.flags&128)for(t=e.child;t!==null;){if(o=ap(t),o!==null){for(e.flags|=128,hc(s,!1),r=o.updateQueue,r!==null&&(e.updateQueue=r,e.flags|=4),e.subtreeFlags=0,r=n,n=e.child;n!==null;)s=n,t=r,s.flags&=14680066,o=s.alternate,o===null?(s.childLanes=0,s.lanes=t,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=o.childLanes,s.lanes=o.lanes,s.child=o.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=o.memoizedProps,s.memoizedState=o.memoizedState,s.updateQueue=o.updateQueue,s.type=o.type,t=o.dependencies,s.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),n=n.sibling;return It(Ht,Ht.current&1|2),e.child}t=t.sibling}s.tail!==null&&nn()>_u&&(e.flags|=128,r=!0,hc(s,!1),e.lanes=4194304)}else{if(!r)if(t=ap(o),t!==null){if(e.flags|=128,r=!0,n=t.updateQueue,n!==null&&(e.updateQueue=n,e.flags|=4),hc(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!qt)return Rn(e),null}else 2*nn()-s.renderingStartTime>_u&&n!==1073741824&&(e.flags|=128,r=!0,hc(s,!1),e.lanes=4194304);s.isBackwards?(o.sibling=e.child,e.child=o):(n=s.last,n!==null?n.sibling=o:e.child=o,s.last=o)}return s.tail!==null?(e=s.tail,s.rendering=e,s.tail=e.sibling,s.renderingStartTime=nn(),e.sibling=null,n=Ht.current,It(Ht,r?n&1|2:n&1),e):(Rn(e),null);case 22:case 23:return R_(),r=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==r&&(e.flags|=8192),r&&e.mode&1?vr&1073741824&&(Rn(e),e.subtreeFlags&6&&(e.flags|=8192)):Rn(e),null;case 24:return null;case 25:return null}throw Error(de(156,e.tag))}function A4(t,e){switch(f_(e),e.tag){case 1:return cr(e.type)&&ep(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;
vendor: 8,579 bytes, line 40
40case 3:return vu(),jt(ur),jt(Fn),w_(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return __(e),null;case 13:if(jt(Ht),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(de(340));mu()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return jt(Ht),null;case 4:return vu(),null;case 10:return m_(e.type._context),null;case 22:case 23:return R_(),null;case 24:return null;default:return null}}var Kd=!1,Mn=!1,I4=typeof WeakSet=="function"?WeakSet:Set,Se=null;function Ml(t,e){var n=t.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Zt(t,e,r)}else n.current=null}function py(t,e,n){try{n()}catch(r){Zt(t,e,r)}}var fE=!1;function O4(t,e){if(Zv=Qh,t=ck(),u_(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else e:{n=(n=t.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,l=-1,u=0,c=0,d=t,f=null;t:for(;;){for(var p;d!==n||i!==0&&d.nodeType!==3||(a=o+i),d!==s||r!==0&&d.nodeType!==3||(l=o+r),d.nodeType===3&&(o+=d.nodeValue.length),(p=d.firstChild)!==null;)f=d,d=p;for(;;){if(d===t)break t;if(f===n&&++u===i&&(a=o),f===s&&++c===r&&(l=o),(p=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=p}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Xv={focusedElem:t,selectionRange:n},Qh=!1,Se=e;Se!==null;)if(e=Se,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Se=t;else for(;Se!==null;){e=Se;try{var _=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(_!==null){var y=_.memoizedProps,w=_.memoizedState,g=e.stateNode,m=g.getSnapshotBeforeUpdate(e.elementType===e.type?y:Jr(e.type,y),w);g.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var b=e.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(de(163))}}catch(v){Zt(e,e.return,v)}if(t=e.sibling,t!==null){t.return=e.return,Se=t;break}Se=e.return}return _=fE,fE=!1,_}function Bc(t,e,n){var r=e.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&t)===t){var s=i.destroy;i.destroy=void 0,s!==void 0&&py(e,n,s)}i=i.next}while(i!==r)}}function hm(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var n=e=e.next;do{if((n.tag&t)===t){var r=n.create;n.destroy=r()}n=n.next}while(n!==e)}}function my(t){var e=t.ref;if(e!==null){var n=t.stateNode;switch(t.tag){case 5:t=n;break;default:t=n}typeof e=="function"?e(t):e.current=t}}function oA(t){var e=t.alternate;e!==null&&(t.alternate=null,oA(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[Pi],delete e[ff],delete e[ty],delete e[f4],delete e[d4])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function aA(t){return t.tag===5||t.tag===3||t.tag===4}function dE(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||aA(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function gy(t,e,n){var r=t.tag;if(r===5||r===6)t=t.stateNode,e?n.nodeType===8?n.parentNode.insertBefore(t,e):n.insertBefore(t,e):(n.nodeType===8?(e=n.parentNode,e.insertBefore(t,n)):(e=n,e.appendChild(t)),n=n._reactRootContainer,n!=null||e.onclick!==null||(e.onclick=Jh));else if(r!==4&&(t=t.child,t!==null))for(gy(t,e,n),t=t.sibling;t!==null;)gy(t,e,n),t=t.sibling}function vy(t,e,n){var r=t.tag;if(r===5||r===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(r!==4&&(t=t.child,t!==null))for(vy(t,e,n),t=t.sibling;t!==null;)vy(t,e,n),t=t.sibling}var bn=null,ti=!1;function Ks(t,e,n){for(n=n.child;n!==null;)lA(t,e,n),n=n.sibling}function lA(t,e,n){if(Ci&&typeof Ci.onCommitFiberUnmount=="function")try{Ci.onCommitFiberUnmount(sm,n)}catch{}switch(n.tag){case 5:Mn||Ml(n,e);case 6:var r=bn,i=ti;bn=null,Ks(t,e,n),bn=r,ti=i,bn!==null&&(ti?(t=bn,n=n.stateNode,t.nodeType===8?t.parentNode.removeChild(n):t.removeChild(n)):bn.removeChild(n.stateNode));break;case 18:bn!==null&&(ti?(t=bn,n=n.stateNode,t.nodeType===8?$g(t.parentNode,n):t.nodeType===1&&$g(t,n),of(t)):$g(bn,n.stateNode));break;case 4:r=bn,i=ti,bn=n.stateNode.containerInfo,ti=!0,Ks(t,e,n),bn=r,ti=i;break;case 0:case 11:case 14:case 15:if(!Mn&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&py(n,e,o),i=i.next}while(i!==r)}Ks(t,e,n);break;case 1:if(!Mn&&(Ml(n,e),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Zt(n,e,a)}Ks(t,e,n);break;case 21:Ks(t,e,n);break;case 22:n.mode&1?(Mn=(r=Mn)||n.memoizedState!==null,Ks(t,e,n),Mn=r):Ks(t,e,n);break;default:Ks(t,e,n)}}function hE(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var n=t.stateNode;n===null&&(n=t.stateNode=new I4),e.forEach(function(r){var i=F4.bind(null,t,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Xr(t,e){var n=e.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var s=t,o=e,a=o;e:for(;a!==null;){switch(a.tag){case 5:bn=a.stateNode,ti=!1;break e;case 3:bn=a.stateNode.containerInfo,ti=!0;break e;case 4:bn=a.stateNode.containerInfo,ti=!0;break e}a=a.return}if(bn===null)throw Error(de(160));lA(s,o,i),bn=null,ti=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){Zt(i,e,u)}}if(e.subtreeFlags&12854)for(e=e.child;e!==null;)uA(e,t),e=e.sibling}function uA(t,e){var n=t.alternate,r=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:if(Xr(e,t),Ei(t),r&4){try{Bc(3,t,t.return),hm(3,t)}catch(y){Zt(t,t.return,y)}try{Bc(5,t,t.return)}catch(y){Zt(t,t.return,y)}}break;case 1:Xr(e,t),Ei(t),r&512&&n!==null&&Ml(n,n.return);break;case 5:if(Xr(e,t),Ei(t),r&512&&n!==null&&Ml(n,n.return),t.flags&32){var i=t.stateNode;try{tf(i,"")}catch(y){Zt(t,t.return,y)}}if(r&4&&(i=t.stateNode,i!=null)){var s=t.memoizedProps,o=n!==null?n.memoizedProps:s,a=t.type,l=t.updateQueue;if(t.updateQueue=null,l!==null)try{a==="input"&&s.type==="radio"&&s.name!=null&&R2(i,s),$v(a,o);var u=$v(a,s);for(o=0;o<l.length;o+=2){var c=l[o],d=l[o+1];c==="style"?L2(i,d):c==="dangerouslySetInnerHTML"?D2(i,d):c==="children"?tf(i,d):Q0(i,c,d,u)}switch(a){case"input":Lv(i,s);break;case"textarea":C2(i,s);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var p=s.value;p!=null?Ul(i,!!s.multiple,p,!1):f!==!!s.multiple&&(s.defaultValue!=null?Ul(i,!!s.multiple,s.defaultValue,!0):Ul(i,!!s.multiple,s.multiple?[]:"",!1))}i[ff]=s}catch(y){Zt(t,t.return,y)}}break;case 6:if(Xr(e,t),Ei(t),r&4){if(t.stateNode===null)throw Error(de(162));i=t.stateNode,s=t.memoizedProps;try{i.nodeValue=s}catch(y){Zt(t,t.return,y)}}break;case 3:if(Xr(e,t),Ei(t),r&4&&n!==null&&n.memoizedState.isDehydrated)try{of(e.containerInfo)}catch(y){Zt(t,t.return,y)}break;case 4:Xr(e,t),Ei(t);break;case 13:Xr(e,t),Ei(t),i=t.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||(O_=nn())),r&4&&hE(t);break;case 22:if(c=n!==null&&n.memoizedState!==null,t.mode&1?(Mn=(u=Mn)||c,Xr(e,t),Mn=u):Xr(e,t),Ei(t),r&8192){if(u=t.memoizedState!==null,(t.stateNode.isHidden=u)&&!c&&t.mode&1)for(Se=t,c=t.child;c!==null;){for(d=Se=c;Se!==null;){switch(f=Se,p=f.child,f.tag){case 0:case 11:case 14:case 15:Bc(4,f,f.return);break;case 1:Ml(f,f.return);var _=f.stateNode;if(typeof _.componentWillUnmount=="function"){r=f,n=f.return;try{e=r,_.props=e.memoizedProps,_.state=e.memoizedState,_.componentWillUnmount()}catch(y){Zt(r,n,y)}}break;case 5:Ml(f,f.return);break;case 22:if(f.memoizedState!==null){mE(d);continue}}p!==null?(p.return=f,Se=p):mE(d)}c=c.sibling}e:for(c=null,d=t;;){if(d.tag===5){if(c===null){c=d;try{i=d.stateNode,u?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(a=d.stateNode,l=d.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=M2("display",o))}catch(y){Zt(t,t.return,y)}}}else if(d.tag===6){if(c===null)try{d.stateNode.nodeValue=u?"":d.memoizedProps}catch(y){Zt(t,t.return,y)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===t)&&d.child!==null){d.
vendor: 18,197 bytes, line 40
40child.return=d,d=d.child;continue}if(d===t)break e;for(;d.sibling===null;){if(d.return===null||d.return===t)break e;c===d&&(c=null),d=d.return}c===d&&(c=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Xr(e,t),Ei(t),r&4&&hE(t);break;case 21:break;default:Xr(e,t),Ei(t)}}function Ei(t){var e=t.flags;if(e&2){try{e:{for(var n=t.return;n!==null;){if(aA(n)){var r=n;break e}n=n.return}throw Error(de(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(tf(i,""),r.flags&=-33);var s=dE(t);vy(t,s,i);break;case 3:case 4:var o=r.stateNode.containerInfo,a=dE(t);gy(t,a,o);break;default:throw Error(de(161))}}catch(l){Zt(t,t.return,l)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function P4(t,e,n){Se=t,cA(t)}function cA(t,e,n){for(var r=(t.mode&1)!==0;Se!==null;){var i=Se,s=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||Kd;if(!o){var a=i.alternate,l=a!==null&&a.memoizedState!==null||Mn;a=Kd;var u=Mn;if(Kd=o,(Mn=l)&&!u)for(Se=i;Se!==null;)o=Se,l=o.child,o.tag===22&&o.memoizedState!==null?gE(i):l!==null?(l.return=o,Se=l):gE(i);for(;s!==null;)Se=s,cA(s),s=s.sibling;Se=i,Kd=a,Mn=u}pE(t)}else i.subtreeFlags&8772&&s!==null?(s.return=i,Se=s):pE(t)}}function pE(t){for(;Se!==null;){var e=Se;if(e.flags&8772){var n=e.alternate;try{if(e.flags&8772)switch(e.tag){case 0:case 11:case 15:Mn||hm(5,e);break;case 1:var r=e.stateNode;if(e.flags&4&&!Mn)if(n===null)r.componentDidMount();else{var i=e.elementType===e.type?n.memoizedProps:Jr(e.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=e.updateQueue;s!==null&&Xb(e,s,r);break;case 3:var o=e.updateQueue;if(o!==null){if(n=null,e.child!==null)switch(e.child.tag){case 5:n=e.child.stateNode;break;case 1:n=e.child.stateNode}Xb(e,o,n)}break;case 5:var a=e.stateNode;if(n===null&&e.flags&4){n=a;var l=e.memoizedProps;switch(e.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(e.memoizedState===null){var u=e.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var d=c.dehydrated;d!==null&&of(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(de(163))}Mn||e.flags&512&&my(e)}catch(f){Zt(e,e.return,f)}}if(e===t){Se=null;break}if(n=e.sibling,n!==null){n.return=e.return,Se=n;break}Se=e.return}}function mE(t){for(;Se!==null;){var e=Se;if(e===t){Se=null;break}var n=e.sibling;if(n!==null){n.return=e.return,Se=n;break}Se=e.return}}function gE(t){for(;Se!==null;){var e=Se;try{switch(e.tag){case 0:case 11:case 15:var n=e.return;try{hm(4,e)}catch(l){Zt(e,n,l)}break;case 1:var r=e.stateNode;if(typeof r.componentDidMount=="function"){var i=e.return;try{r.componentDidMount()}catch(l){Zt(e,i,l)}}var s=e.return;try{my(e)}catch(l){Zt(e,s,l)}break;case 5:var o=e.return;try{my(e)}catch(l){Zt(e,o,l)}}}catch(l){Zt(e,e.return,l)}if(e===t){Se=null;break}var a=e.sibling;if(a!==null){a.return=e.return,Se=a;break}Se=e.return}}var R4=Math.ceil,cp=Fs.ReactCurrentDispatcher,A_=Fs.ReactCurrentOwner,Ur=Fs.ReactCurrentBatchConfig,ft=0,yn=null,ln=null,Tn=0,vr=0,Ll=Yo(0),dn=0,vf=null,Ga=0,pm=0,I_=0,zc=null,or=null,O_=0,_u=1/0,rs=null,fp=!1,yy=null,Co=null,Yd=!1,bo=null,dp=0,qc=0,_y=null,xh=-1,Th=0;function Qn(){return ft&6?nn():xh!==-1?xh:xh=nn()}function No(t){return t.mode&1?ft&2&&Tn!==0?Tn&-Tn:p4.transition!==null?(Th===0&&(Th=K2()),Th):(t=wt,t!==0||(t=window.event,t=t===void 0?16:tk(t.type)),t):1}function ai(t,e,n,r){if(50<qc)throw qc=0,_y=null,Error(de(185));Yf(t,n,r),(!(ft&2)||t!==yn)&&(t===yn&&(!(ft&2)&&(pm|=n),dn===4&&so(t,Tn)),fr(t,r),n===1&&ft===0&&!(e.mode&1)&&(_u=nn()+500,cm&&Qo()))}function fr(t,e){var n=t.callbackNode;pD(t,e);var r=Yh(t,t===yn?Tn:0);if(r===0)n!==null&&Sb(n),t.callbackNode=null,t.callbackPriority=0;else if(e=r&-r,t.callbackPriority!==e){if(n!=null&&Sb(n),e===1)t.tag===0?h4(vE.bind(null,t)):wk(vE.bind(null,t)),u4(function(){!(ft&6)&&Qo()}),n=null;else{switch(Y2(r)){case 1:n=t_;break;case 4:n=W2;break;case 16:n=Kh;break;case 536870912:n=G2;break;default:n=Kh}n=yA(n,fA.bind(null,t))}t.callbackPriority=e,t.callbackNode=n}}function fA(t,e){if(xh=-1,Th=0,ft&6)throw Error(de(327));var n=t.callbackNode;if(Hl()&&t.callbackNode!==n)return null;var r=Yh(t,t===yn?Tn:0);if(r===0)return null;if(r&30||r&t.expiredLanes||e)e=hp(t,r);else{e=r;var i=ft;ft|=2;var s=hA();(yn!==t||Tn!==e)&&(rs=null,_u=nn()+500,La(t,e));do try{D4();break}catch(a){dA(t,a)}while(!0);p_(),cp.current=s,ft=i,ln!==null?e=0:(yn=null,Tn=0,e=dn)}if(e!==0){if(e===2&&(i=Wv(t),i!==0&&(r=i,e=wy(t,i))),e===1)throw n=vf,La(t,0),so(t,r),fr(t,nn()),n;if(e===6)so(t,r);else{if(i=t.current.alternate,!(r&30)&&!C4(i)&&(e=hp(t,r),e===2&&(s=Wv(t),s!==0&&(r=s,e=wy(t,s))),e===1))throw n=vf,La(t,0),so(t,r),fr(t,nn()),n;switch(t.finishedWork=i,t.finishedLanes=r,e){case 0:case 1:throw Error(de(345));case 2:fa(t,or,rs);break;case 3:if(so(t,r),(r&130023424)===r&&(e=O_+500-nn(),10<e)){if(Yh(t,0)!==0)break;if(i=t.suspendedLanes,(i&r)!==r){Qn(),t.pingedLanes|=t.suspendedLanes&i;break}t.timeoutHandle=ey(fa.bind(null,t,or,rs),e);break}fa(t,or,rs);break;case 4:if(so(t,r),(r&4194240)===r)break;for(e=t.eventTimes,i=-1;0<r;){var o=31-oi(r);s=1<<o,o=e[o],o>i&&(i=o),r&=~s}if(r=i,r=nn()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*R4(r/1960))-r,10<r){t.timeoutHandle=ey(fa.bind(null,t,or,rs),r);break}fa(t,or,rs);break;case 5:fa(t,or,rs);break;default:throw Error(de(329))}}}return fr(t,nn()),t.callbackNode===n?fA.bind(null,t):null}function wy(t,e){var n=zc;return t.current.memoizedState.isDehydrated&&(La(t,e).flags|=256),t=hp(t,e),t!==2&&(e=or,or=n,e!==null&&by(e)),t}function by(t){or===null?or=t:or.push.apply(or,t)}function C4(t){for(var e=t;;){if(e.flags&16384){var n=e.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],s=i.getSnapshot;i=i.value;try{if(!ci(s(),i))return!1}catch{return!1}}}if(n=e.child,e.subtreeFlags&16384&&n!==null)n.return=e,e=n;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function so(t,e){for(e&=~I_,e&=~pm,t.suspendedLanes|=e,t.pingedLanes&=~e,t=t.expirationTimes;0<e;){var n=31-oi(e),r=1<<n;t[n]=-1,e&=~r}}function vE(t){if(ft&6)throw Error(de(327));Hl();var e=Yh(t,0);if(!(e&1))return fr(t,nn()),null;var n=hp(t,e);if(t.tag!==0&&n===2){var r=Wv(t);r!==0&&(e=r,n=wy(t,r))}if(n===1)throw n=vf,La(t,0),so(t,e),fr(t,nn()),n;if(n===6)throw Error(de(345));return t.finishedWork=t.current.alternate,t.finishedLanes=e,fa(t,or,rs),fr(t,nn()),null}function P_(t,e){var n=ft;ft|=1;try{return t(e)}finally{ft=n,ft===0&&(_u=nn()+500,cm&&Qo())}}function Ka(t){bo!==null&&bo.tag===0&&!(ft&6)&&Hl();var e=ft;ft|=1;var n=Ur.transition,r=wt;try{if(Ur.transition=null,wt=1,t)return t()}finally{wt=r,Ur.transition=n,ft=e,!(ft&6)&&Qo()}}function R_(){vr=Ll.current,jt(Ll)}function La(t,e){t.finishedWork=null,t.finishedLanes=0;var n=t.timeoutHandle;if(n!==-1&&(t.timeoutHandle=-1,l4(n)),ln!==null)for(n=ln.return;n!==null;){var r=n;switch(f_(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&ep();break;case 3:vu(),jt(ur),jt(Fn),w_();break;case 5:__(r);break;case 4:vu();break;case 13:jt(Ht);break;case 19:jt(Ht);break;case 10:m_(r.type._context);break;case 22:case 23:R_()}n=n.return}if(yn=t,ln=t=Do(t.current,null),Tn=vr=e,dn=0,vf=null,I_=pm=Ga=0,or=zc=null,ya!==null){for(e=0;e<ya.length;e++)if(n=ya[e],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,s=n.pending;if(s!==null){var o=s.next;s.next=i,r.next=o}n.pending=r}ya=null}return t}function dA(t,e){do{var n=ln;try{if(p_(),wh.current=up,lp){for(var r=Wt.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}lp=!1}if(Wa=0,vn=cn=Wt=null,$c=!1,pf=0,A_.current=null,n===null||n.return===null){dn=1,vf=e,ln=null;break}e:{var s=t,o=n.return,a=n,l=e;if(e=Tn,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,c=a,d=c.tag;if(!(c.mode&1)&&(d===0||d===11||d===15)){var f=c.alternate;f?(c.updateQueue=f.updateQueue,c.memoizedState=f.memoizedState,c.lanes=f.lanes):(c.updateQueue=null,c.memoizedState=null)}var p=iE(o);if(p!==null){p.flags&=-257,sE(p,o,a,s,e),p.mode&1&&rE(s,u,e),e=p,l=u;var _=e.updateQueue;if(_===null){var y=new Set;y.add(l),e.updateQueue=y}else _.add(l);break e}else{if(!(e&1)){rE(s,u,e),C_();break e}l=Error(de(426))}}else if(qt&&a.mode&1){var w=iE(o);if(w!==null){!(w.flags&65536)&&(w.flags|=256),sE(w,o,a,s,e),d_(yu(l,a));break e}}s=l=yu(l,a),dn!==4&&(dn=2),zc===null?zc=[s]:zc.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,e&=-e,s.lanes|=e;var g=Yk(s,l,e);Zb(s,g);break e;case 1:a=l;var m=s.type,b=s.stateNode;if(!(s.flags&128)&&(typeof m.getDerivedStateFromError=="function"||b!==null&&typeof b.componentDidCatch=="function"&&(Co===null||!Co.has(b)))){s.flags|=65536,e&=-e,s.lanes|=e;var v=Qk(s,a,e);Zb(s,v);break e}}s=s.return}while(s!==null)}mA(n)}catch(A){e=A,ln===n&&n!==null&&(ln=n=n.return);continue}break}while(!0)}function hA(){var t=cp.current;return cp.current=up,t===null?up:t}function C_(){(dn===0||dn===3||dn===2)&&(dn=4),yn===null||!(Ga&268435455)&&!(pm&268435455)||so(yn,Tn)}function hp(t,e){var n=ft;ft|=2;var r=hA();(yn!==t||Tn!==e)&&(rs=null,La(t,e));do try{N4();break}catch(i){dA(t,i)}while(!0);if(p_(),ft=n,cp.current=r,ln!==null)throw Error(de(261));return yn=null,Tn=0,dn}function N4(){for(;ln!==null;)pA(ln)}function D4(){for(;ln!==null&&!sD();)pA(ln)}function pA(t){var e=vA(t.alternate,t,vr);t.memoizedProps=t.pendingProps,e===null?mA(t):ln=e,A_.current=null}function mA(t){var e=t;do{var n=e.alternate;if(t=e.return,e.flags&32768){if(n=A4(n,e),n!==null){n.flags&=32767,ln=n;return}if(t!==null)t.flags|=32768,t.subtreeFlags=0,t.deletions=null;else{dn=6,ln=null;return}}else if(n=k4(n,e,vr),n!==null){ln=n;return}if(e=e.sibling,e!==null){ln=e;return}ln=e=t}while(e!==null);dn===0&&(dn=5)}function fa(t,e,n){var r=wt,i=Ur.transition;try{Ur.transition=null,wt=1,M4(t,e,n,r)}finally{Ur.transition=i,wt=r}return null}function M4(t,e,n,r){do Hl();while(bo!==null);if(ft&6)throw Error(de(327));n=t.finishedWork;var i=t.finishedLanes;if(n===null)return null;if(t.finishedWork=null,t.finishedLanes=0,n===t.current)throw Error(de(177));t.callbackNode=null,t.callbackPriority=0;var s=n.lanes|n.childLanes;if(mD(t,s),t===yn&&(ln=yn=null,Tn=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Yd||(Yd=!0,yA(Kh,function(){return Hl(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=Ur.transition,Ur.transition=null;var o=wt;wt=1;var a=ft;ft|=4,A_.current=null,O4(t,n),uA(n,t),t4(Xv),Qh=!!Zv,Xv=Zv=null,t.current=n,P4(n),oD(),ft=a,wt=o,Ur.transition=s}else t.current=n;if(Yd&&(Yd=!1,bo=t,dp=i),s=t.pendingLanes,s===0&&(Co=null),uD(n.stateNode),fr(t,nn()),e!==null)for(r=t.onRecoverableError,n=0;n<e.length;n++)i=e[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(fp)throw fp=!1,t=yy,yy=null,t;return dp&1&&t.tag!==0&&Hl(),s=t.pendingLanes,s&1?t===_y?qc++:(qc=0,_y=t):qc=0,Qo(),null}function Hl(){if(bo!==null){var t=Y2(dp),e=Ur.transition,n=wt;try{if(Ur.transition=null,wt=16>t?16:t,bo===null)var r=!1;else{if(t=bo,bo=null,dp=0,ft&6)throw Error(de(331));var i=ft;for(ft|=4,Se=t.current;Se!==null;){var s=Se,o=s.child;if(Se.flags&16){var a=s.deletions;if(a!==null){for(var l=0;l<a.length;l++){var u=a[l];for(Se=u;Se!==null;){var c=Se;switch(c.tag){case 0:case 11:case 15:Bc(8,c,s)}var d=c.child;if(d!==null)d.return=c,Se=d;else for(;Se!==null;){c=Se;var f=c.sibling,p=c.return;if(oA(c),c===u){Se=null;break}if(f!==null){f.return=p,Se=f;break}Se=p}}}var _=s.alternate;if(_!==null){var y=_.child;if(y!==null){_.child=null;do{var w=y.sibling;y.sibling=null,y=w}while(y!==null)}}Se=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,Se=o;else e:for(;Se!==null;){if(s=Se,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Bc(9,s,s.return)}var g=s.sibling;if(g!==null){g.return=s.return,Se=g;break e}Se=s.return}}var m=t.current;for(Se=m;Se!==null;){o=Se;var b=o.child;if(o.subtreeFlags&2064&&b!==null)b.return=o,Se=b;else e:for(o=m;Se!==null;){if(a=Se,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:hm(9,a)}}catch(A){Zt(a,a.return,A)}if(a===o){Se=null;break e}var v=a.sibling;if(v!==null){v.return=a.return,Se=v;break e}Se=a.return}}if(ft=i,Qo(),Ci&&typeof Ci.onPostCommitFiberRoot=="function")try{Ci.onPostCommitFiberRoot(sm,t)}catch{}r=!0}return r}finally{wt=n,Ur.transition=e}}return!1}function yE(t,e,n){e=yu(n,e),e=Yk(t,e,1),t=Ro(t,e,1),e=Qn(),t!==null&&(Yf(t,1,e),fr(t,e))}function Zt(t,e,n){if(t.tag===3)yE(t,t,n);else for(;e!==null;){if(e.tag===3){yE(e,t,n);break}else if(e.tag===1){var r=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Co===null||!Co.has(r))){t=yu(n,t),t=Qk(e,t,1),e=Ro(e,t,1),t=Qn(),e!==null&&(Yf(e,1,t),fr(e,t));break}}e=e.return}}function L4(t,e,n){var r=t.pingCache;r!==null&&r.delete(e),e=Qn(),t.pingedLanes|=t.suspendedLanes&n,yn===t&&(Tn&n)===n&&(dn===4||dn===3&&(Tn&130023424)===Tn&&500>nn()-O_?La(t,0):I_|=n),fr(t,e)}function gA(t,e){e===0&&(t.mode&1?(e=Vd,Vd<<=1,!(Vd&130023424)&&(Vd=4194304)):e=1);var n=Qn();t=Os(t,e),t!==null&&(Yf(t,e,n),fr(t,n))}function j4(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),gA(t,n)}function F4(t,e){var n=0;switch(t.tag){case 13:var r=t.stateNode,i=t.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=t.stateNode;break;default:throw Error(de(314))}r!==null&&r.delete(e),gA(t,n)}var vA;vA=function(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps||ur.current)lr=!0;else{if(!(t.lanes&n)&&!(e.flags&128))return lr=!1,S4(t,e,n);lr=!!(t.flags&131072)}else lr=!1,qt&&e.flags&1048576&&bk(e,rp,e.index);switch(e.lanes=0,e.tag){case 2:var r=e.type;Eh(t,e),t=e.pendingProps;var i=pu(e,Fn.current);ql(e,n),i=E_(null,e,r,t,i,n);var s=x_();return e.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,cr(r)?(s=!0,tp(e)):s=!1,e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,v_(e),i.updater=dm,e.stateNode=i,i._reactInternals=e,ay(e,r,t,n),e=cy(null,e,r,!0,s,n)):(e.tag=0,qt&&s&&c_(e),qn(null,e,i,n),e=e.child),e;case 16:r=e.elementType;e:{switch(Eh(t,e),t=e.pendingProps,i=r._init,r=i(r._payload),e.type=r,i=e.tag=U4(r),t=Jr(r,t),i){case 0:e=uy(null,e,r,t,n);break e;case 1:e=lE(null,e,r,t,n);break e;case 11:e=oE(null,e,r,t,n);break e;case 14:e=aE(null,e,r,Jr(r.type,t),n);break e}throw Error(de(306,r,""))}return e;case 0:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Jr(r,i),uy(t,e,r,i,n);case 1:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Jr(r,i),lE(t,e,r,i,n);case 3:e:{if(eA(e),t===null)throw Error(de(387));r=e.pendingProps,s=e.memoizedState,i=s.element,Ak(t,e),op(e,r,null,n);var o=e.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},e.updateQueue.baseState=s,e.memoizedState=s,e.flags&256){i=yu(Error(de(423)),e),e=uE(t,e,r,n,i);break e}else if(r!==i){i=yu(Error(de(424)),e),e=uE(t,e,r,n,i);break e}else for(Er=Po(e.stateNode.containerInfo.firstChild),Sr=e,qt=!0,ri=null,n=Sk(e,null,r,n),e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(mu(),r===i){e=Ps(t,e,n);break e}qn(t,e,r,n)}e=e.child}return e;case 5:return Ik(e),t===null&&iy(e),r=e.type,i=e.pendingProps,s=t!==null?t.memoizedProps:null,o=i.children,Jv(r,i)?o=null:s!==null&&Jv(r,s)&&(e.flags|=32),Jk(t,e),qn(t,e,o,n),e.child;case 6:return t===null&&iy(e),null;case 13:return tA(t,e,n);case 4:return y_(e,e.stateNode.containerInfo),r=e.pendingProps,t===null?e.child=gu(e,null,r,n):qn(t,e,r,n),e.child;case 11:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Jr(r,i),oE(t,e,r,i,n);case 7:return qn(t,e,e.pendingProps,n),e.child;case 8:return qn(t,e,e.pendingProps.children,n),e.child;case 12:return qn(t,e,e.pendingProps.children,n),e.child;case 10:e:{if(r=e.type._context,i=e.pendingProps,s=e.memoizedProps,o=i.value,It(ip,r._currentValue),r._currentValue=o,s!==null)if(ci(s.value,o)){if(s.children===i.children&&!ur.current){e=Ps(t,e,n);break e}}else for(s=e.child,s!==null&&(s.return=e);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(s.tag===1){l=_s(-1,n&-n),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),sy(s.return,n,e),a.lanes|=n;break}l=l.next}}else if(s.tag===10)o=s.type===e.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(de(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),sy(o,n,e),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===e){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}qn(t,e,i.children,n),e=e.child}return e;case 9:return i=e.type,r=e.pendingProps.children,ql(e,n),i=$r(i),r=r(i),e.flags|=1,qn(t,e,r,n),e.child;case 14:return r=e.type,i=Jr(r,e.pendingProps),i=Jr(r.type,i),aE(t,e,r,i,n);case 15:return Zk(t,e,e.type,e.pendingProps,n);case 17:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Jr(r,i),Eh(t,e),e.tag=1,cr(r)?(t=!0,tp(e)):t=!1,ql(e,n),Kk(e,r,i),ay(e,r,i,n),cy(null,e,r,!0,t,n);case 19:return nA(t,e,n);case 22:return Xk(t,e,n)}throw Error(de(156,e.tag))};function yA(t,e){return H2(t,e)}function V4(t,e,n,r){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Vr(t,e,n,r){return new V4(t,e,n,r)}function N_(t){return t=t.prototype,!(!t||!t.isReactComponent)}function U4(t){if(typeof t=="function")return N_(t)?1:0;if(t!=null){if(t=t.$$typeof,t===X0)return 11;if(t===J0)return 14}return 2}function Do(t,e){var n=t.alternate;return n===null?(n=Vr(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deleti
vendor: 10,038 bytes, lines 40-49
40ons=null),n.flags=t.flags&14680064,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n}function Sh(t,e,n,r,i,s){var o=2;if(r=t,typeof t=="function")N_(t)&&(o=1);else if(typeof t=="string")o=5;else e:switch(t){case kl:return ja(n.children,i,s,e);case Z0:o=8,i|=8;break;case Rv:return t=Vr(12,n,e,i|2),t.elementType=Rv,t.lanes=s,t;case Cv:return t=Vr(13,n,e,i),t.elementType=Cv,t.lanes=s,t;case Nv:return t=Vr(19,n,e,i),t.elementType=Nv,t.lanes=s,t;case I2:return mm(n,i,s,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case k2:o=10;break e;case A2:o=9;break e;case X0:o=11;break e;case J0:o=14;break e;case no:o=16,r=null;break e}throw Error(de(130,t==null?t:typeof t,""))}return e=Vr(o,n,e,i),e.elementType=t,e.type=r,e.lanes=s,e}function ja(t,e,n,r){return t=Vr(7,t,r,e),t.lanes=n,t}function mm(t,e,n,r){return t=Vr(22,t,r,e),t.elementType=I2,t.lanes=n,t.stateNode={isHidden:!1},t}function Yg(t,e,n){return t=Vr(6,t,null,e),t.lanes=n,t}function Qg(t,e,n){return e=Vr(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function $4(t,e,n,r,i){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Pg(0),this.expirationTimes=Pg(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Pg(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function D_(t,e,n,r,i,s,o,a,l){return t=new $4(t,e,n,a,l),e===1?(e=1,s===!0&&(e|=8)):e=0,s=Vr(3,null,null,e),t.current=s,s.stateNode=t,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},v_(s),t}function B4(t,e,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Sl,key:r==null?null:""+r,children:t,containerInfo:e,implementation:n}}function _A(t){if(!t)return $o;t=t._reactInternals;e:{if(sl(t)!==t||t.tag!==1)throw Error(de(170));var e=t;do{switch(e.tag){case 3:e=e.stateNode.context;break e;case 1:if(cr(e.type)){e=e.stateNode.__reactInternalMemoizedMergedChildContext;break e}}e=e.return}while(e!==null);throw Error(de(171))}if(t.tag===1){var n=t.type;if(cr(n))return _k(t,n,e)}return e}function wA(t,e,n,r,i,s,o,a,l){return t=D_(n,r,!0,t,i,s,o,a,l),t.context=_A(null),n=t.current,r=Qn(),i=No(n),s=_s(r,i),s.callback=e??null,Ro(n,s,i),t.current.lanes=i,Yf(t,i,r),fr(t,r),t}function gm(t,e,n,r){var i=e.current,s=Qn(),o=No(i);return n=_A(n),e.context===null?e.context=n:e.pendingContext=n,e=_s(s,o),e.payload={element:t},r=r===void 0?null:r,r!==null&&(e.callback=r),t=Ro(i,e,o),t!==null&&(ai(t,i,o,s),_h(t,i,o)),o}function pp(t){if(t=t.current,!t.child)return null;switch(t.child.tag){case 5:return t.child.stateNode;default:return t.child.stateNode}}function _E(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var n=t.retryLane;t.retryLane=n!==0&&n<e?n:e}}function M_(t,e){_E(t,e),(t=t.alternate)&&_E(t,e)}function z4(){return null}var bA=typeof reportError=="function"?reportError:function(t){console.error(t)};function L_(t){this._internalRoot=t}vm.prototype.render=L_.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(de(409));gm(t,e,null,null)};vm.prototype.unmount=L_.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Ka(function(){gm(null,t,null,null)}),e[Is]=null}};function vm(t){this._internalRoot=t}vm.prototype.unstable_scheduleHydration=function(t){if(t){var e=X2();t={blockedOn:null,target:t,priority:e};for(var n=0;n<io.length&&e!==0&&e<io[n].priority;n++);io.splice(n,0,t),n===0&&ek(t)}};function j_(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function ym(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11&&(t.nodeType!==8||t.nodeValue!==" react-mount-point-unstable "))}function wE(){}function q4(t,e,n,r,i){if(i){if(typeof r=="function"){var s=r;r=function(){var u=pp(o);s.call(u)}}var o=wA(e,r,t,0,null,!1,!1,"",wE);return t._reactRootContainer=o,t[Is]=o.current,uf(t.nodeType===8?t.parentNode:t),Ka(),o}for(;i=t.lastChild;)t.removeChild(i);if(typeof r=="function"){var a=r;r=function(){var u=pp(l);a.call(u)}}var l=D_(t,0,!1,null,null,!1,!1,"",wE);return t._reactRootContainer=l,t[Is]=l.current,uf(t.nodeType===8?t.parentNode:t),Ka(function(){gm(e,l,n,r)}),l}function _m(t,e,n,r,i){var s=n._reactRootContainer;if(s){var o=s;if(typeof i=="function"){var a=i;i=function(){var l=pp(o);a.call(l)}}gm(e,o,t,i)}else o=q4(n,e,t,i,r);return pp(o)}Q2=function(t){switch(t.tag){case 3:var e=t.stateNode;if(e.current.memoizedState.isDehydrated){var n=Ac(e.pendingLanes);n!==0&&(n_(e,n|1),fr(e,nn()),!(ft&6)&&(_u=nn()+500,Qo()))}break;case 13:Ka(function(){var r=Os(t,1);if(r!==null){var i=Qn();ai(r,t,1,i)}}),M_(t,1)}};r_=function(t){if(t.tag===13){var e=Os(t,134217728);if(e!==null){var n=Qn();ai(e,t,134217728,n)}M_(t,134217728)}};Z2=function(t){if(t.tag===13){var e=No(t),n=Os(t,e);if(n!==null){var r=Qn();ai(n,t,e,r)}M_(t,e)}};X2=function(){return wt};J2=function(t,e){var n=wt;try{return wt=t,e()}finally{wt=n}};zv=function(t,e,n){switch(e){case"input":if(Lv(t,n),e=n.name,n.type==="radio"&&e!=null){for(n=t;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+e)+'][type="radio"]'),e=0;e<n.length;e++){var r=n[e];if(r!==t&&r.form===t.form){var i=um(r);if(!i)throw Error(de(90));P2(r),Lv(r,i)}}}break;case"textarea":C2(t,n);break;case"select":e=n.value,e!=null&&Ul(t,!!n.multiple,e,!1)}};V2=P_;U2=Ka;var H4={usingClientEntryPoint:!1,Events:[Zf,Pl,um,j2,F2,P_]},pc={findFiberByHostInstance:va,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},W4={bundleType:pc.bundleType,version:pc.version,rendererPackageName:pc.rendererPackageName,rendererConfig:pc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Fs.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=z2(t),t===null?null:t.stateNode},findFiberByHostInstance:pc.findFiberByHostInstance||z4,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Qd=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Qd.isDisabled&&Qd.supportsFiber)try{sm=Qd.inject(W4),Ci=Qd}catch{}}Ir.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=H4;Ir.createPortal=function(t,e){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!j_(e))throw Error(de(200));return B4(t,e,null,n)};Ir.createRoot=function(t,e){if(!j_(t))throw Error(de(299));var n=!1,r="",i=bA;return e!=null&&(e.unstable_strictMode===!0&&(n=!0),e.identifierPrefix!==void 0&&(r=e.identifierPrefix),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=D_(t,1,!1,null,null,n,!1,r,i),t[Is]=e.current,uf(t.nodeType===8?t.parentNode:t),new L_(e)};Ir.findDOMNode=function(t){if(t==null)return null;if(t.nodeType===1)return t;var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(de(188)):(t=Object.keys(t).join(","),Error(de(268,t)));return t=z2(e),t=t===null?null:t.stateNode,t};Ir.flushSync=function(t){return Ka(t)};Ir.hydrate=function(t,e,n){if(!ym(e))throw Error(de(200));return _m(null,t,e,!0,n)};Ir.hydrateRoot=function(t,e,n){if(!j_(t))throw Error(de(405));var r=n!=null&&n.hydratedSources||null,i=!1,s="",o=bA;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),e=wA(e,null,t,1,n??null,i,!1,s,o),t[Is]=e.current,uf(t),r)for(t=0;t<r.length;t++)n=r[t],i=n._getVersion,i=i(n._source),e.mutableSourceEagerHydrationData==null?e.mutableSourceEagerHydrationData=[n,i]:e.mutableSourceEagerHydrationData.push(n,i);return new vm(e)};Ir.render=function(t,e,n){if(!ym(e))throw Error(de(200));return _m(null,t,e,!1,n)};Ir.unmountComponentAtNode=function(t){if(!ym(t))throw Error(de(40));return t._reactRootContainer?(Ka(function(){_m(null,null,t,!1,function(){t._reactRootContainer=null,t[Is]=null})}),!0):!1};Ir.unstable_batchedUpdates=P_;Ir.unstable_renderSubtreeIntoContainer=function(t,e,n,r){if(!ym(n))throw Error(de(200));if(t==null||t._reactInternals===void 0)throw Error(de(38));return _m(t,e,n,!1,r)};Ir.version="18.3.1-next-f1338f8080-20240426";function EA(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(EA)}catch(t){console.error(t)}}EA(),E2.exports=Ir;var wm=E2.exports;const G4=Ou(wm),K4=c2({__proto__:null,default:G4},[wm]);/** 41 * @remix-run/router v1.23.3 42 * 43 * Copyright (c) Remix Software Inc. 44 * 45 * This source code is licensed under the MIT license found in the 46 * LICENSE.md file in the root directory of this source tree. 47 * 48 * @license MIT 49 */function zt(){return zt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},zt.apply(null,arguments)}var on;(function(t){t.Pop="POP",t.Push="PUSH",t.Replace="REPLACE"})(on||(on={}));const bE="popstate";function Y4(t){t===void 0&&(t={});function e(r,i){let{pathname:s,search:o,hash:a}=r.location;return yf("",{pathname:s,search:o,hash:a},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Qa(i)}
vendor: 2,661 bytes, line 49
49return Z4(e,n,null,t)}function et(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function Ya(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function Q4(){return Math.random().toString(36).substr(2,8)}function EE(t,e){return{usr:t.state,key:t.key,idx:e}}function yf(t,e,n,r){return n===void 0&&(n=null),zt({pathname:typeof t=="string"?t:t.pathname,search:"",hash:""},typeof e=="string"?Zo(e):e,{state:n,key:e&&e.key||r||Q4()})}function Qa(t){let{pathname:e="/",search:n="",hash:r=""}=t;return n&&n!=="?"&&(e+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}function Zo(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substr(n),t=t.substr(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substr(r),t=t.substr(0,r)),t&&(e.pathname=t)}return e}function Z4(t,e,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,a=on.Pop,l=null,u=c();u==null&&(u=0,o.replaceState(zt({},o.state,{idx:u}),""));function c(){return(o.state||{idx:null}).idx}function d(){a=on.Pop;let w=c(),g=w==null?null:w-u;u=w,l&&l({action:a,location:y.location,delta:g})}function f(w,g){a=on.Push;let m=yf(y.location,w,g);u=c()+1;let b=EE(m,u),v=y.createHref(m);try{o.pushState(b,"",v)}catch(A){if(A instanceof DOMException&&A.name==="DataCloneError")throw A;i.location.assign(v)}s&&l&&l({action:a,location:y.location,delta:1})}function p(w,g){a=on.Replace;let m=yf(y.location,w,g);u=c();let b=EE(m,u),v=y.createHref(m);o.replaceState(b,"",v),s&&l&&l({action:a,location:y.location,delta:0})}function _(w){let g=i.location.origin!=="null"?i.location.origin:i.location.href,m=typeof w=="string"?w:Qa(w);return m=m.replace(/ $/,"%20"),et(g,"No window.location.(origin|href) available to create URL for href: "+m),new URL(m,g)}let y={get action(){return a},get location(){return t(i,o)},listen(w){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(bE,d),l=w,()=>{i.removeEventListener(bE,d),l=null}},createHref(w){return e(i,w)},createURL:_,encodeLocation(w){let g=_(w);return{pathname:g.pathname,search:g.search,hash:g.hash}},push:f,replace:p,go(w){return o.go(w)}};return y}var _t;(function(t){t.data="data",t.deferred="deferred",t.redirect="redirect",t.error="error"})(_t||(_t={}));const X4=new Set(["lazy","caseSensitive","path","id","index","children"]);function J4(t){return t.index===!0}function mp(t,e,n,r){return n===void 0&&(n=[]),r===void 0&&(r={}),t.map((i,s)=>{let o=[...n,String(s)],a=typeof i.id=="string"?i.id:o.join("-");if(et(i.index!==!0||!i.children,"Cannot specify children on an index route"),et(!r[a],'Found a route id collision on i
49d "'+a+`". Route id's must be globally unique within Data Router usages`),J4(i)){let l=zt({},i,e(i),{id:a});return r[a]=l,l}else{let l=zt({},i,e(i),{id:a,children:void 0});return r[a]=l,i.children&&(l.children=mp(i.children,e,o,r)),l}})}function pa(t,e,n){return n===void 0&&(n="/"),kh(t,e,n,!1)}function kh(t,e,n,r){let i=typeof e=="string"?Zo(e):e,s=Nu(i.pathname||"/",n);if(s==null)return null;let o=xA(t);tM(o);let a=null,l=dM(s);for(let u=0;a==null&&u<o.length;++u)a=cM(o[u],l,r);return a}function eM(t,e){let{route:n,pathname:r,params:i}=t;return{id:n.id,pathname:r,params:i,data:e[n.id],handle:n.handle}}function xA(t,e,n,r){e===void 0&&(e=[]),n===void 0&&(n=[]),r===void 0&&(r="");let i=(s,o,a)=>{let l={relativePath:a===void 0?s.path||"":a,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};l.relativePath.startsWith("/")&&(et(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let u=ws([r,l.relativePath]),c=n.concat(l);s.children&&s.children.length>0&&(et(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),xA(s.children,e,c,u)),!(s.path==null&&!s.index)&&e.push({path:u,score:lM(u,s.index),routesMeta:c})};return t.forEach((s,o)=>{var a;if(s.path===""||!((a=s.path)!=null&&a.includes("?")))i(s,o);else for(let l of TA(s.path))i(s,o,l)}),e}function TA(t){let e=t.split("/");if(e.length===0)return[];let[n,...r]=e,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=TA(r.join("/")),a=[];return a.push(...o.map(l=>l===""?s:[s,l].join("/"))),i&&a.push(...o),a.map(l=>t.startsWith("/")&&l===""?"/":l)}function tM(t){t.sort((e,n)=>e.score!==n.score?n.score-e.score:uM(e.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const nM=/^:[\w-]+$/,rM=3,iM=2,sM=1,oM=10,aM=-2,xE=t=>t==="*";function lM(t,e){let n=t.split("/"),r=n.length;return n.some(xE)&&(r+=aM),e&&(r+=iM),n.filter(i=>!xE(i)).reduce((i,s)=>i+(nM.test(s)?rM:s===""?sM:oM),r)}function uM(t,e){return t.length===e.length&&t.slice(0,-1).every((r,i)=>r===e[i])?t[t.length-1]-e[e.length-1]:0}function cM(t,e,n){n===void 0&&(n=!1);let{routesMeta:r}=t,i={},s="/",o=[];for(let a=0;a<r.length;++a){let l=r[a],u=a===r.length-1,c=s==="/"?e:e.slice(s.length)||"/",d=TE({path:l.relativePath,caseSensitive:l.caseSensitive,end:u},c),f=l.route;if(!d&&u&&n&&!r[r.length-1].route.index&&(d=TE({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},c)),!d)return null;
vendor: 57,678 bytes, lines 49-68
49Object.assign(i,d.params),o.push({params:i,pathname:ws([s,d.pathname]),pathnameBase:gM(ws([s,d.pathnameBase])),route:f}),d.pathnameBase!=="/"&&(s=ws([s,d.pathnameBase]))}return o}function TE(t,e){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[n,r]=fM(t.path,t.caseSensitive,t.end),i=e.match(n);if(!i)return null;let s=i[0],o=s.replace(/(.)\/+$/,"$1"),a=i.slice(1);return{params:r.reduce((u,c,d)=>{let{paramName:f,isOptional:p}=c;if(f==="*"){let y=a[d]||"";o=s.slice(0,s.length-y.length).replace(/(.)\/+$/,"$1")}const _=a[d];return p&&!_?u[f]=void 0:u[f]=(_||"").replace(/%2F/g,"/"),u},{}),pathname:s,pathnameBase:o,pattern:t}}function fM(t,e,n){e===void 0&&(e=!1),n===void 0&&(n=!0),Ya(t==="*"||!t.endsWith("*")||t.endsWith("/*"),'Route path "'+t+'" will be treated as if it were '+('"'+t.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+t.replace(/\*$/,"/*")+'".'));let r=[],i="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(r.push({paramName:"*"}),i+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":t!==""&&t!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,e?void 0:"i"),r]}function dM(t){try{return t.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return Ya(!1,'The URL path "'+t+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+e+").")),t}}function Nu(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let n=e.endsWith("/")?e.length-1:e.length,r=t.charAt(n);return r&&r!=="/"?null:t.slice(n)||"/"}const hM=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,pM=t=>hM.test(t);function mM(t,e){e===void 0&&(e="/");let{pathname:n,search:r="",hash:i=""}=typeof t=="string"?Zo(t):t,s;if(n)if(pM(n))s=n;else{if(n.includes("//")){let o=n;n=F_(n),Ya(!1,"Pathnames cannot have embedded double slashes - normalizing "+(o+" -> "+n))}n.startsWith("/")?s=SE(n.substring(1),"/"):s=SE(n,e)}else s=e;return{pathname:s,search:vM(r),hash:yM(i)}}function SE(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function Zg(t,e,n,r){return"Cannot include a '"+t+"' character in a manually specified "+("`to."+e+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function SA(t){return t.filter((e,n)=>n===0||e.route.path&&e.route.path.length>0)}function bm(t,e){let n=SA(t);return e?n.map((r,i)=>i===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Em(t,e,n,r){r===void 0&&(r=!1);let i;typeof t=="string"?i=Zo(t):(i=zt({},t),et(!i.pathname||!i.pathname.includes("?"),Zg("?","pathname","search",i)),et(!i.pathname||!i.pathname.includes("#"),Zg("#","pathname","hash",i)),et(!i.search||!i.search.includes("#"),Zg("#","search","hash",i)));let s=t===""||i.pathname==="",o=s?"/":i.pathname,a;if(o==null)a=n;else{let d=e.length-1;if(!r&&o.startsWith("..")){let f=o.split("/");for(;f[0]==="..";)f.shift(),d-=1;i.pathname=f.join("/")}a=d>=0?e[d]:"/"}let l=mM(i,a),u=o&&o!=="/"&&o.endsWith("/"),c=(s||o===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(u||c)&&(l.pathname+="/"),l}const F_=t=>t.replace(/\/\/+/g,"/"),ws=t=>F_(t.join("/")),gM=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),vM=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,yM=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t;class gp{constructor(e,n,r,i){i===void 0&&(i=!1),this.status=e,this.statusText=n||"",this.internal=i,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}}function _f(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}const kA=["post","put","patch","delete"],_M=new Set(kA),wM=["get",...kA],bM=new Set(wM),EM=new Set([301,302,303,307,308]),xM=new Set([307,308]),Xg={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},TM={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},mc={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},V_=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,SM=t=>({hasErrorBoundary:!!t.hasErrorBoundary}),AA="remix-router-transitions";function kM(t){const e=t.window?t.window:typeof window<"u"?window:void 0,n=typeof e<"u"&&typeof e.document<"u"&&typeof e.document.createElement<"u",r=!n;et(t.routes.length>0,"You must provide a non-empty routes array to createRouter");let i;if(t.mapRouteProperties)i=t.mapRouteProperties;else if(t.detectErrorBoundary){let G=t.detectErrorBoundary;i=X=>({hasErrorBoundary:G(X)})}else i=SM;let s={},o=mp(t.routes,i,void 0,s),a,l=t.basename||"/",u=t.dataStrategy||PM,c=t.patchRoutesOnNavigation,d=zt({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},t.future),f=null,p=new Set,_=null,y=null,w=null,g=t.hydrationData!=null,m=pa(o,t.history.location,l),b=!1,v=null;if(m==null&&!c){let G=sr(404,{pathname:t.history.location.pathname}),{matches:X,route:ne}=LE(o);m=X,v={[ne.id]:G}}m&&!t.hydrationData&&oa(m,o,t.history.location.pathname).active&&(m=null);let A;if(m)if(m.some(G=>G.route.lazy))A=!1;else if(!m.some(G=>G.route.loader))A=!0;else if(d.v7_partialHydration){let G=t.hydrationData?t.hydrationData.loaderData:null,X=t.hydrationData?t.hydrationData.errors:null;if(X){let ne=m.findIndex(ce=>X[ce.route.id]!==void 0);A=m.slice(0,ne+1).every(ce=>!xy(ce.route,G,X))}else A=m.every(ne=>!xy(ne.route,G,X))}else A=t.hydrationData!=null;else if(A=!1,m=[],d.v7_partialHydration){let G=oa(null,o,t.history.location.pathname);G.active&&G.matches&&(b=!0,m=G.matches)}let N,x={historyAction:t.history.action,location:t.history.location,matches:m,initialized:A,navigation:Xg,restoreScrollPosition:t.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:t.hydrationData&&t.hydrationData.loaderData||{},actionData:t.hydrationData&&t.hydrationData.actionData||null,errors:t.hydrationData&&t.hydrationData.errors||v,fetchers:new Map,blockers:new Map},E=on.Pop,T=!1,S,k=!1,I=new Map,P=null,M=!1,$=!1,Z=[],Q=new Set,K=new Map,B=0,V=-1,D=new Map,j=new Set,U=new Map,Y=new Map,W=new Set,F=new Map,q=new Map,ee;function te(){if(f=t.history.listen(G=>{let{action:X,location:ne,delta:ce}=G;if(ee){ee(),ee=void 0;return}Ya(q.size===0||ce!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let we=ra({currentLocation:x.location,nextLocation:ne,historyAction:X});if(we&&ce!=null){let Pe=new Promise(Ve=>{ee=Ve});t.history.go(ce*-1),Yr(we,{state:"blocked",location:ne,proceed(){Yr(we,{state:"proceeding",proceed:void 0,reset:void 0,location:ne}),Pe.then(()=>t.history.go(ce))},reset(){let Ve=new Map(x.blockers);Ve.set(we,mc),Ee({blockers:Ve})}});return}return Et(X,ne)}),n){qM(e,I);let G=()=>HM(e,I);e.addEventListener("pagehide",G),P=()=>e.removeEventListener("pagehide",G)}return x.initialized||Et(on.Pop,x.location,{initialHydration:!0}),N}function ae(){f&&f(),P&&P(),p.clear(),S&&S.abort(),x.fetchers.forEach((G,X)=>Pt(X)),x.blockers.forEach((G,X)=>yi(X))}function _e(G){return p.add(G),()=>p.delete(G)}function Ee(G,X){X===void 0&&(X={}),x=zt({},x,G);let ne=[],ce=[];d.v7_fetcherPersist&&x.fetchers.forEach((we,Pe)=>{we.state==="idle"&&(W.has(Pe)?ce.push(Pe):ne.push(Pe))}),W.forEach(we=>{!x.fetchers.has(we)&&!K.has(we)&&ce.push(we)}),[...p].forEach(we=>we(x,{deletedFetchers:ce,viewTransitionOpts:X.viewTransitionOpts,flushSync:X.flushSync===!0})),d.v7_fetcherPersist?(ne.forEach(we=>x.fetchers.delete(we)),ce.forEach(we=>Pt(we))):ce.forEach(we=>W.delete(we))}function Ce(G,X,ne){var ce,we;let{flushSync:Pe}=ne===void 0?{}:ne,Ve=x.actionData!=null&&x.navigation.formMethod!=null&&ni(x.navigation.formMethod)&&x.navigation.state==="loading"&&((ce=G.state)==null?void 0:ce._isRedirect)!==!0,Ie;X.actionData?Object.keys(X.actionData).length>0?Ie=X.actionData:Ie=null:Ve?Ie=x.actionData:Ie=null;let Ae=X.loaderData?DE(x.loaderData,X.loaderData,X.matches||[],X.errors):x.loaderData,xe=x.blockers;xe.size>0&&(xe=new Map(xe),xe.forEach((Ge,rn)=>xe.set(rn,mc)));let Re=T===!0||x.navigation.formMethod!=null&&ni(x.navigation.formMethod)&&((we=G.state)==null?void 0:we._isRedirect)!==!0;a&&(o=a,a=void 0),M||E===on.Pop||(E===on.Push?t.history.push(G,G.state):E===on.Replace&&t.history.replace(G,G.state));let $e;if(E===on.Pop){let Ge=I.get(x.location.pathname);Ge&&Ge.has(G.pathname)?$e={currentLocation:x.location,nextLocation:G}:I.has(G.pathname)&&($e={currentLocation:G,nextLocation:x.location})}else if(k){let Ge=I.get(x.location.pathname);Ge?Ge.add(G.pathname):(Ge=new Set([G.pathname]),I.set(x.location.pathname,Ge)),$e={currentLocation:x.location,nextLocation:G}}Ee(zt({},X,{actionData:Ie,loaderData:Ae,historyAction:E,location:G,initialized:!0,navigation:Xg,revalidation:"idle",restoreScrollPosition:sa(G,X.matches||x.matches),preventScrollReset:Re,blockers:xe}),{viewTransitionOpts:$e,flushSync:Pe===!0}),E=on.Pop,T=!1,k=!1,M=!1,$=!1,Z=[]}async function qe(G,X){if(typeof G=="number"){t.history.go(G);return}let ne=Ey(x.location,x.matches,l,d.v7_prependBasename,G,d.v7_relativeSplatPath,X==null?void 0:X.fromRouteId,X==null?void 0:X.relative),{path:ce,submission:we,error:Pe}=kE(d.v7_normalizeFormMethod,!1,ne,X),Ve=x.location,Ie=yf(x.location,ce,X&&X.state);Ie=zt({},Ie,t.history.encodeLocation(Ie));let Ae=X&&X.replace!=null?X.replace:void 0,xe=on.Push;Ae===!0?xe=on.Replace:Ae===!1||we!=null&&ni(we.formMethod)&&we.formAction===x.location.pathname+x.location.search&&(xe=on.Replace);let Re=X&&"preventScrollReset"in X?X.preventScrollReset===!0:void 0,$e=(X&&X.flushSync)===!0,Ge=ra({currentLocation:Ve,nextLocation:Ie,historyAction:xe});if(Ge){Yr(Ge,{state:"blocked",location:Ie,proceed(){Yr(Ge,{state:"proceeding",proceed:void 0,reset:void 0,location:Ie}),qe(G,X)},reset(){let rn=new Map(x.blockers);rn.set(Ge,mc),Ee({blockers:rn})}});return}return await Et(xe,Ie,{submission:we,pendingError:Pe,preventScrollReset:Re,replace:X&&X.replace,enableViewTransition:X&&X.viewTransition,flushSync:$e})}function Ze(){if(je(),Ee({revalidation:"loading"}),x.navigation.state!=="submitting"){if(x.navigation.state==="idle"){Et(x.historyAction,x.location,{startUninterruptedRevalidation:!0});return}Et(E||x.historyAction,x.navigation.location,{overrideNavigation:x.navigation,enableViewTransition:k===!0})}}async function Et(G,X,ne){S&&S.abort(),S=null,E=G,M=(ne&&ne.startUninterruptedRevalidation)===!0,_d(x.location,x.matches),T=(ne&&ne.preventScrollReset)===!0,k=(ne&&ne.enableViewTransition)===!0;let ce=a||o,we=ne&&ne.overrideNavigation,Pe=ne!=null&&ne.initialHydration&&x.matches&&x.matches.length>0&&!b?x.matches:pa(ce,X,l),Ve=(ne&&ne.flushSync)===!0;if(Pe&&x.initialized&&!$&&LM(x.location,X)&&!(ne&&ne.submission&&ni(ne.submission.formMethod))){Ce(X,{matches:Pe},{flushSync:Ve});return}let Ie=oa(Pe,ce,X.pathname);if(Ie.active&&Ie.matches&&(Pe=Ie.matches),!Pe){let{error:yt,notFoundMatches:st,route:At}=Wi(X.pathname);Ce(X,{matches:st,loaderData:{},errors:{[At.id]:yt}},{flushSync:Ve});return}S=new AbortController;let Ae=yl(t.history,X,S.signal,ne&&ne.submission),xe;if(ne&&ne.pendingError)xe=[ma(Pe).route.id,{type:_t.error,error:ne.pendingError}];else if(ne&&ne.submission&&ni(ne.submission.formMethod)){let yt=await kt(Ae,X,ne.submission,Pe,Ie.active,{replace:ne.replace,flushSync:Ve});if(yt.shortCircuited)return;if(yt.pendingActionResult){let[st,At]=yt.pendingActionResult;if(_r(At)&&_f(At.error)&&At.error.status===404){S=null,Ce(X,{matches:yt.matches,loaderData:{},errors:{[st]:At.error}});return}}Pe=yt.matches||Pe,xe=yt.pendingActionResult,we=Jg(X,ne.submission),Ve=!1,Ie.active=!1,Ae=yl(t.history,Ae.url,Ae.signal)}let{shortCircuited:Re,matches:$e,loaderData:Ge,errors:rn}=await ie(Ae,X,Pe,Ie.active,we,ne&&ne.submission,ne&&ne.fetcherSubmission,ne&&ne.replace,ne&&ne.initialHydration===!0,Ve,xe);Re||(S=null,Ce(X,zt({matches:$e||Pe},ME(xe),{loaderData:Ge,errors:rn})))}async function kt(G,X,ne,ce,we,Pe){Pe===void 0&&(Pe={}),je();let Ve=BM(X,ne);if(Ee({navigation:Ve},{flushSync:Pe.flushSync===!0}),we){let xe=await wi(ce,X.pathname,G.signal);if(xe.type==="aborted")return{shortCircuited:!0};if(xe.type==="error"){let Re=ma(xe.partialMatches).route.id;return{matches:xe.partialMatches,pendingActionResult:[Re,{type:_t.error,error:xe.error}]}}else if(xe.matches)ce=xe.matches;else{let{notFoundMatches:Re,error:$e,route:Ge}=Wi(X.pathname);return{matches:Re,pendingActionResult:[Ge.id,{type:_t.error,error:$e}]}}}let Ie,Ae=Oc(ce,X);if(!Ae.route.action&&!Ae.route.lazy)Ie={type:_t.error,error:sr(405,{method:G.method,pathname:X.pathname,routeId:Ae.route.id})};else if(Ie=(await oe("action",x,G,[Ae],ce,null))[Ae.route.id],G.signal.aborted)return{shortCircuited:!0};if(wa(Ie)){let xe;return Pe&&Pe.replace!=null?xe=Pe.replace:xe=RE(Ie.response.headers.get("Location"),new URL(G.url),l,t.history)===x.location.pathname+x.location.search,await Fe(G,Ie,!0,{submission:ne,replace:xe}),{shortCircuited:!0}}if(Eo(Ie))throw sr(400,{type:"defer-action"});if(_r(Ie)){let xe=ma(ce,Ae.route.id);return(Pe&&Pe.replace)!==!0&&(E=on.Push),{matches:ce,pendingActionResult:[xe.route.id,Ie]}}return{matches:ce,pendingActionResult:[Ae.route.id,Ie]}}async function ie(G,X,ne,ce,we,Pe,Ve,Ie,Ae,xe,Re){let $e=we||Jg(X,Pe),Ge=Pe||Ve||FE($e),rn=!M&&(!d.v7_partialHydration||!Ae);if(ce){if(rn){let Rt=se(Re);Ee(zt({navigation:$e},Rt!==void 0?{actionData:Rt}:{}),{flushSync:xe})}let lt=await wi(ne,X.pathname,G.signal);if(lt.type==="aborted")return{shortCircuited:!0};if(lt.type==="error"){let Rt=ma(lt.partialMatches).route.id;return{matches:lt.partialMatches,loaderData:{},errors:{[Rt]:lt.error}}}else if(lt.matches)ne=lt.matches;else{let{error:Rt,notFoundMatches:Yi,route:Hs}=Wi(X.pathname);return{matches:Yi,loaderData:{},errors:{[Hs.id]:Rt}}}}let yt=a||o,[st,At]=IE(t.history,x,ne,Ge,X,d.v7_partialHydration&&Ae===!0,d.v7_skipActionErrorRevalidation,$,Z,Q,W,U,j,yt,l,Re);if(ia(lt=>!(ne&&ne.some(Rt=>Rt.route.id===lt))||st&&st.some(Rt=>Rt.route.id===lt)),V=++B,st.length===0&&At.length===0){let lt=Kr();return Ce(X,zt({matches:ne,loaderData:{},errors:Re&&_r(Re[1])?{[Re[0]]:Re[1].error}:null},ME(Re),lt?{fetchers:new Map(x.fetchers)}:{}),{flushSync:xe}),{shortCircuited:!0}}if(rn){let lt={};if(!ce){lt.navigation=$e;let Rt=se(Re);Rt!==void 0&&(lt.actionData=Rt)}At.length>0&&(lt.fetchers=pe(At)),Ee(lt,{flushSync:xe})}At.forEach(lt=>{Un(lt.key),lt.controller&&K.set(lt.key,lt.controller)});let Gi=()=>At.forEach(lt=>Un(lt.key));S&&S.signal.addEventListener("abort",Gi);let{loaderResults:zs,fetcherResults:Qr}=await me(x,ne,st,At,G);if(G.signal.aborted)return{shortCircuited:!0};S&&S.signal.removeEventListener("abort",Gi),At.forEach(lt=>K.delete(lt.key));let $n=Zd(zs);if($n)return await Fe(G,$n.result,!0,{replace:Ie}),{shortCircuited:!0};if($n=Zd(Qr),$n)return j.add($n.key),await Fe(G,$n.result,!0,{replace:Ie}),{shortCircuited:!0};let{loaderData:hl,errors:Ki}=NE(x,ne,zs,Re,At,Qr,F);F.forEach((lt,Rt)=>{lt.subscribe(Yi=>{(Yi||lt.done)&&F.delete(Rt)})}),d.v7_partialHydration&&Ae&&x.errors&&(Ki=zt({},x.errors,Ki));let pr=Kr(),Cr=Bs(V),qs=pr||Cr||At.length>0;return zt({matches:ne,loaderData:hl,errors:Ki},qs?{fetchers:new Map(x.fetchers)}:{})}function se(G){if(G&&!_r(G[1]))return{[G[0]]:G[1].data};if(x.actionData)return Object.keys(x.actionData).length===0?null:x.actionData}function pe(G){return G.forEach(X=>{let ne=x.fetchers.get(X.key),ce=gc(void 0,ne?ne.data:void 0);x.fetchers.set(X.key,ce)}),new Map(x.fetchers)}function ye(G,X,ne,ce){if(r)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");Un(G);let we=(ce&&ce.flushSync)===!0,Pe=a||o,Ve=Ey(x.location,x.matches,l,d.v7_prependBasename,ne,d.v7_relativeSplatPath,X,ce==null?void 0:ce.relative),Ie=pa(Pe,Ve,l),Ae=oa(Ie,Pe,Ve);if(Ae.active&&Ae.matches&&(Ie=Ae.matches),!Ie){dt(G,X,sr(404,{pathname:Ve}),{flushSync:we});return}let{path:xe,submission:Re,error:$e}=kE(d.v7_normalizeFormMethod,!0,Ve,ce);if($e){dt(G,X,$e,{flushSync:we});return}let Ge=Oc(Ie,xe),rn=(ce&&ce.preventScrollReset)===!0;if(Re&&ni(Re.formMethod)){ue(G,X,xe,Ge,Ie,Ae.active,we,rn,Re);return}U.set(G,{routeId:X,path:xe}),Ue(G,X,xe,Ge,Ie,Ae.active,we,rn,Re)}async function ue(G,X,ne,ce,we,Pe,Ve,Ie,Ae){je(),U.delete(G);function xe(Ut){if(!Ut.route.action&&!Ut.route.lazy){let bi=sr(405,{method:Ae.formMethod,pathname:ne,routeId:X});return dt(G,X,bi,{flushSync:Ve}),!0}return!1}if(!Pe&&xe(ce))return;let Re=x.fetchers.get(G);Ne(G,zM(Ae,Re),{flushSync:Ve});let $e=new AbortController,Ge=yl(t.history,ne,$e.signal,Ae);if(Pe){let Ut=await wi(we,new URL(Ge.url).pathname,Ge.signal,G);if(Ut.type==="aborted")return;if(Ut.type==="error"){dt(G,X,Ut.error,{flushSync:Ve});return}else if(Ut.matches){if(we=Ut.matches,ce=Oc(we,ne),xe(ce))return}else{dt(G,X,sr(404,{pathname:ne}),{flushSync:Ve});return}}K.set(G,$e);let rn=B,st=(await oe("action",x,Ge,[ce],we,G))[ce.route.id];if(Ge.signal.aborted){K.get(G)===$e&&K.delete(G);return}if(d.v7_fetcherPersist&&W.has(G)){if(wa(st)||_r(st)){Ne(G,eo(void 0));return}}else{if(wa(st))if(K.delete(G),V>rn){Ne(G,eo(void 0));return}else return j.add(G),Ne(G,gc(Ae)),Fe(Ge,st,!1,{fetcherSubmission:Ae,preventScrollReset:Ie});if(_r(st)){dt(G,X,st.error);return}}if(Eo(st))throw sr(400,{type:"defer-action"});let At=x.navigation.location||x.location,Gi=yl(t.history,At,$e.signal),zs=a||o,Qr=x.navigation.state!=="idle"?pa(zs,x.navigation.location,l):x.matches;et(Qr,"Didn't find any matches after fetcher action");let $n=++B;D.set(G,$n);let hl=gc(Ae,st.data);x.fetchers.set(G,hl);let[Ki,pr]=IE(t.history,x,Qr,Ae,At,!1,d.v7_skipActionErrorRevalidation,$,Z,Q,W,U,j,zs,l,[ce.route.id,st]);pr.filter(Ut=>Ut.key!==G).forEach(Ut=>{let bi=Ut.key,Ju=x.fetchers.get(bi),bd=gc(void 0,Ju?Ju.data:void 0);x.fetchers.set(bi,bd),Un(bi),Ut.controller&&K.set(bi,Ut.controller)}),Ee({fetchers:new Map(x.fetchers)});let Cr=()=>pr.forEach(Ut=>Un(Ut.key));$e.signal.addEventListener("abort",Cr);let{loaderResults:qs,fetcherResults:lt}=await me(x,Qr,Ki,pr,Gi);if($e.signal.aborted)return;$e.signal.removeEventListener("abort",Cr),D.delete(G),K.delete(G),pr.forEach(Ut=>K.delete(Ut.key));let Rt=Zd(qs);if(Rt)return Fe(Gi,Rt.result,!1,{preventScrollReset:Ie});if(Rt=Zd(lt),Rt)return j.add(Rt.key),Fe(Gi,Rt.result,!1,{preventScrollReset:Ie});let{loaderData:Yi,errors:Hs}=NE(x,Qr,qs,void 0,pr,lt,F);if(x.fetchers.has(G)){let Ut=eo(st.data);x.fetchers.set(G,Ut)}Bs($n),x.navigation.state==="loading"&&$n>V?(et(E,"Expected pending action"),S&&S.abort(),Ce(x.navigation.location,{matches:Qr,loaderData:Yi,errors:Hs,fetchers:new Map(x.fetchers)})):(Ee({errors:Hs,loaderData:DE(x.loaderData,Yi,Qr,Hs),fetchers:new Map(x.fetchers)}),$=!1)}async function Ue(G,X,ne,ce,we,Pe,Ve,Ie,Ae){let xe=x.fetchers.get(G);Ne(G,gc(Ae,xe?xe.data:void 0),{flushSync:Ve});let Re=new AbortController,$e=yl(t.history,ne,Re.signal);if(Pe){let st=await wi(we,new URL($e.url).pathname,$e.signal,G);if(st.type==="aborted")return;if(st.type==="error"){dt(G,X,st.error,{flushSync:Ve});return}else if(st.matches)we=st.matches,ce=Oc(we,ne);else{dt(G,X,sr(404,{pathname:ne}),{flushSync:Ve});return}}K.set(G,Re);let Ge=B,yt=(await oe("loader",x,$e,[ce],we,G))[ce.route.id];if(Eo(yt)&&(yt=await U_(yt,$e.signal,!0)||yt),K.get(G)===Re&&K.delete(G),!$e.signal.aborted){if(W.has(G)){Ne(G,eo(void 0));return}if(wa(yt))if(V>Ge){Ne(G,eo(void 0));return}else{j.add(G),await Fe($e,yt,!1,{preventScrollReset:Ie});return}if(_r(yt)){dt(G,X,yt.error);return}et(!Eo(yt),"Unhandled fetcher deferred data"),Ne(G,eo(yt.data))}}async function Fe(G,X,ne,ce){let{submission:we,fetcherSubmission:Pe,preventScrollReset:Ve,replace:Ie}=ce===void 0?{}:ce;X.response.headers.has("X-Remix-Revalidate")&&($=!0);let Ae=X.response.headers.get("Location");et(Ae,"Expected a Location header on the redirect Response"),Ae=RE(Ae,new URL(G.url),l,t.history);let xe=yf(x.location,Ae,{_isRedirect:!0});if(n){let st=!1;if(X.response.headers.has("X-Remix-Reload-Document"))st=!0;else if(V_.test(Ae)){const At=t.history.createURL(Ae);st=At.origin!==e.location.origin||Nu(At.pathname,l)==null}if(st){Ie?e.location.replace(Ae):e.location.assign(Ae);return}}S=null;let Re=Ie===!0||X.response.headers.has("X-Remix-Replace")?on.Replace:on.Push,{formMethod:$e,formAction:Ge,formEncType:rn}=x.navigation;!we&&!Pe&&$e&&Ge&&rn&&(we=FE(x.navigation));let yt=we||Pe;if(xM.has(X.response.status)&&yt&&ni(yt.formMethod))await Et(Re,xe,{submission:zt({},yt,{formAction:Ae}),preventScrollReset:Ve||T,enableViewTransition:ne?k:void 0});else{let st=Jg(xe,we);await Et(Re,xe,{overrideNavigation:st,fetcherSubmission:Pe,preventScrollReset:Ve||T,enableViewTransition:ne?k:void 0})}}async function oe(G,X,ne,ce,we,Pe){let Ve,Ie={};try{Ve=await RM(u,G,X,ne,ce,we,Pe,s,i)}catch(Ae){return ce.forEach(xe=>{Ie[xe.route.id]={type:_t.error,error:Ae}}),Ie}for(let[Ae,xe]of Object.entries(Ve))if(jM(xe)){let Re=xe.result;Ie[Ae]={type:_t.redirect,response:DM(Re,ne,Ae,we,l,d.v7_relativeSplatPath)}}else Ie[Ae]=await NM(xe);return Ie}async function me(G,X,ne,ce,we){let Pe=G.matches,Ve=oe("loader",G,we,ne,X,null),Ie=Promise.all(ce.map(async Re=>{if(Re.matches&&Re.match&&Re.controller){let Ge=(await oe("loader",G,yl(t.history,Re.path,Re.controller.signal),[Re.match],Re.matches,Re.key))[Re.match.route.id];return{[Re.key]:Ge}}else return Promise.resolve({[Re.key]:{type:_t.error,error:sr(404,{pathname:Re.path})}})})),Ae=await Ve,xe=(await Ie).reduce((Re,$e)=>Object.assign(Re,$e),{});return await Promise.all([UM(X,Ae,we.signal,Pe,G.loaderData),$M(X,xe,ce)]),{loaderResults:Ae,fetcherResults:xe}}function je(){$=!0,Z.push(...ia()),U.forEach((G,X)=>{K.has(X)&&Q.add(X),Un(X)})}function Ne(G,X,ne){ne===void 0&&(ne={}),x.fetchers.set(G,X),Ee({fetchers:new Map(x.fetchers)},{flushSync:(ne&&ne.flushSync)===!0})}function dt(G,X,ne,ce){ce===void 0&&(ce={});let we=ma(x.matches,X);Pt(G),Ee({errors:{[we.route.id]:ne},fetchers:new Map(x.fetchers)},{flushSync:(ce&&ce.flushSync)===!0})}function Xe(G){return Y.set(G,(Y.get(G)||0)+1),W.has(G)&&W.delete(G),x.fetchers.get(G)||TM}function Pt(G){let X=x.fetchers.get(G);K.has(G)&&!(X&&X.state==="loading"&&D.has(G))&&Un(G),U.delete(G),D.delete(G),j.delete(G),d.v7_fetcherPersist&&W.delete(G),Q.delete(G),x.fetchers.delete(G)}function Gr(G){let X=(Y.get(G)||0)-1;X<=0?(Y.delete(G),W.add(G),d.v7_fetcherPersist||Pt(G)):Y.set(G,X),Ee({fetchers:new Map(x.fetchers)})}function Un(G){let X=K.get(G);X&&(X.abort(),K.delete(G))}function Hi(G){for(let X of G){let ne=Xe(X),ce=eo(ne.data);x.fetchers.set(X,ce)}}function Kr(){let G=[],X=!1;for(let ne of j){let ce=x.fetchers.get(ne);et(ce,"Expected fetcher: "+ne),ce.state==="loading"&&(j.delete(ne),G.push(ne),X=!0)}return Hi(G),X}function Bs(G){let X=[];for(let[ne,ce]of D)if(ce<G){let we=x.fetchers.get(ne);et(we,"Expected fetcher: "+ne),we.state==="loading"&&(Un(ne),D.delete(ne),X.push(ne))}return Hi(X),X.length>0}function na(G,X){let ne=x.blockers.get(G)||mc;return q.get(G)!==X&&q.set(G,X),ne}function yi(G){x.blockers.delete(G),q.delete(G)}function Yr(G,X){let ne=x.blockers.get(G)||mc;et(ne.state==="unblocked"&&X.state==="blocked"||ne.state==="blocked"&&X.state==="blocked"||ne.state==="blocked"&&X.state==="proceeding"||ne.state==="blocked"&&X.state==="unblocked"||ne.state==="proceeding"&&X.state==="unblocked","Invalid blocker state transition: "+ne.state+" -> "+X.state);let ce=new Map(x.blockers);ce.set(G,X),Ee({blockers:ce})}function ra(G){let{currentLocation:X,nextLocation:ne,historyAction:ce}=G;if(q.size===0)return;q.size>1&&Ya(!1,"A router only supports one blocker at a time");let we=Array.from(q.entries()),[Pe,Ve]=we[we.length-1],Ie=x.blockers.get(Pe);if(!(Ie&&Ie.state==="proceeding")&&Ve({currentLocation:X,nextLocation:ne,historyAction:ce}))return Pe}function Wi(G){let X=sr(404,{pathname:G}),ne=a||o,{matches:ce,route:we}=LE(ne);return ia(),{notFoundMatches:ce,route:we,error:X}}function ia(G){let X=[];return F.forEach((ne,ce)=>{(!G||G(ce))&&(ne.cancel(),X.push(ce),F.delete(ce))}),X}function Xu(G,X,ne){if(_=G,w=X,y=ne||null,!g&&x.navigation===Xg){g=!0;let ce=sa(x.location,x.matches);ce!=null&&Ee({restoreScrollPosition:ce})}return()=>{_=null,w=null,y=null}}function _i(G,X){return y&&y(G,X.map(ce=>eM(ce,x.loaderData)))||G.key}function _d(G,X){if(_&&w){let ne=_i(G,X);_[ne]=w()}}function sa(G,X){if(_){let ne=_i(G,X),ce=_[ne];if(typeof ce=="number")return ce}return null}function oa(G,X,ne){if(c)if(G){if(Object.keys(G[0].params).length>0)return{active:!0,matches:kh(X,ne,l,!0)}}else return{active:!0,matches:kh(X,ne,l,!0)||[]};return{active:!1,matches:null}}async function wi(G,X,ne,ce){if(!c)return{type:"success",matches:G};let we=G;for(;;){let Pe=a==null,Ve=a||o,Ie=s;try{await c({signal:ne,path:X,matches:we,fetcherKey:ce,patch:(Re,$e)=>{ne.aborted||PE(Re,$e,Ve,Ie,i)}})}catch(Re){return{type:"error",error:Re,partialMatches:we}}finally{Pe&&!ne.aborted&&(o=[...o])}if(ne.aborted)return{type:"aborted"};let Ae=pa(Ve,X,l);if(Ae)return{type:"success",matches:Ae};let xe=kh(Ve,X,l,!0);if(!xe||we.length===xe.length&&we.every((Re,$e)=>Re.route.id===xe[$e].route.id))return{type:"success",matches:null};we=xe}}function wd(G){s={},a=mp(G,i,void 0,s)}function _n(G,X){let ne=a==null;PE(G,X,a||o,s,i),ne&&(o=[...o],Ee({}))}return N={get basename(){return l},get future(){return d},get state(){return x},get routes(){return o},get window(){return e},initialize:te,subscribe:_e,enableScrollRestoration:Xu,navigate:qe,fetch:ye,revalidate:Ze,createHref:G=>t.history.createHref(G),encodeLocation:G=>t.history.encodeLocation(G),getFetcher:Xe,deleteFetcher:Gr,dispose:ae,getBlocker:na,deleteBlocker:yi,patchRoutes:_n,_internalFetchControllers:K,_internalActiveDeferreds:F,_internalSetRoutes:wd},N}function AM(t){return t!=null&&("formData"in t&&t.formData!=null||"body"in t&&t.body!==void 0)}function Ey(t,e,n,r,i,s,o,a){let l,u;if(o){l=[];for(let d of e)if(l.push(d),d.route.id===o){u=d;break}}else l=e,u=e[e.length-1];let c=Em(i||".",bm(l,s),Nu(t.pathname,n)||t.pathname,a==="path");if(i==null&&(c.search=t.search,c.hash=t.hash),(i==null||i===""||i===".")&&u){let d=$_(c.search);if(u.route.index&&!d)c.search=c.search?c.search.replace(/^\?/,"?index&"):"?index";else if(!u.route.index&&d){let f=new URLSearchParams(c.search),p=f.getAll("index");f.delete("index"),p.filter(y=>y).forEach(y=>f.append("index",y));let _=f.toString();c.search=_?"?"+_:""}}return r&&n!=="/"&&(c.pathname=c.pathname==="/"?n:ws([n,c.pathname])),Qa(c)}function kE(t,e,n,r){if(!r||!AM(r))return{path:n};if(r.formMethod&&!VM(r.formMethod))return{path:n,error:sr(405,{method:r.formMethod})};let i=()=>({path:n,error:sr(400,{type:"invalid-body"})}),s=r.formMethod||"get",o=t?s.toUpperCase():s.toLowerCase(),a=PA(n);if(r.body!==void 0){if(r.formEncType==="text/plain"){if(!ni(o))return i();let f=typeof r.body=="string"?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((p,_)=>{let[y,w]=_;return""+p+y+"="+w+` 50`},""):String(r.body);return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:void 0,text:f}}}else if(r.formEncType==="application/json"){if(!ni(o))return i();try{let f=typeof r.body=="string"?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:f,text:void 0}}}catch{return i()}}}et(typeof FormData=="function","FormData is not available in this environment");let l,u;if(r.formData)l=Ty(r.formData),u=r.formData;else if(r.body instanceof FormData)l=Ty(r.body),u=r.body;else if(r.body instanceof URLSearchParams)l=r.body,u=CE(l);else if(r.body==null)l=new URLSearchParams,u=new FormData;else try{l=new URLSearchParams(r.body),u=CE(l)}catch{return i()}let c={formMethod:o,formAction:a,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:u,json:void 0,text:void 0};if(ni(c.formMethod))return{path:n,submission:c};let d=Zo(n);return e&&d.search&&$_(d.search)&&l.append("index",""),d.search="?"+l,{path:Qa(d),submission:c}}function AE(t,e,n){n===void 0&&(n=!1);let r=t.findIndex(i=>i.route.id===e);return r>=0?t.slice(0,n?r+1:r):t}function IE(t,e,n,r,i,s,o,a,l,u,c,d,f,p,_,y){let w=y?_r(y[1])?y[1].error:y[1].data:void 0,g=t.createURL(e.location),m=t.createURL(i),b=n;s&&e.errors?b=AE(n,Object.keys(e.errors)[0],!0):y&&_r(y[1])&&(b=AE(n,y[0]));let v=y?y[1].statusCode:void 0,A=o&&v&&v>=400,N=b.filter((E,T)=>{let{route:S}=E;if(S.lazy)return!0;if(S.loader==null)return!1;if(s)return xy(S,e.loaderData,e.errors);if(IM(e.loaderData,e.matches[T],E)||l.some(P=>P===E.route.id))return!0;let k=e.matches[T],I=E;return OE(E,zt({currentUrl:g,currentParams:k.params,nextUrl:m,nextParams:I.params},r,{actionResult:w,actionStatus:v,defaultShouldRevalidate:A?!1:a||g.pathname+g.search===m.pathname+m.search||g.search!==m.search||IA(k,I)}))}),x=[];return d.forEach((E,T)=>{if(s||!n.some(M=>M.route.id===E.routeId)||c.has(T))return;let S=pa(p,E.path,_);if(!S){x.push({key:T,routeId:E.routeId,path:E.path,matches:null,match:null,controller:null});return}let k=e.fetchers.get(T),I=Oc(S,E.path),P=!1;f.has(T)?P=!1:u.has(T)?(u.delete(T),P=!0):k&&k.state!=="idle"&&k.data===void 0?P=a:P=OE(I,zt({currentUrl:g,currentParams:e.matches[e.matches.length-1].params,nextUrl:m,nextParams:n[n.length-1].params},r,{actionResult:w,actionStatus:v,defaultShouldRevalidate:A?!1:a})),P&&x.push({key:T,routeId:E.routeId,path:E.path,matches:S,match:I,controller:new AbortController})}),[N,x]}function xy(t,e,n){if(t.lazy)return!0;if(!t.loader)return!1;let r=e!=null&&e[t.id]!==void 0,i=n!=null&&n[t.id]!==void 0;return!r&&i?!1:typeof t.loader=="function"&&t.loader.hydrate===!0?!0:!r&&!i}function IM(t,e,n){let r=!e||n.route.id!==e.route.id,i=t[n.route.id]===void 0;return r||i}function IA(t,e){let n=t.route.path;return t.pathname!==e.pathname||n!=null&&n.endsWith("*")&&t.params["*"]!==e.params["*"]}function OE(t,e){if(t.route.shouldRevalidate){let n=t.route.shouldRevalidate(e);if(typeof n=="boolean")return n}return e.defaultShouldRevalidate}function PE(t,e,n,r,i){var s;let o;if(t){let u=r[t];et(u,"No route found to patch children into: routeId = "+t),u.children||(u.children=[]),o=u.children}else o=n;let a=e.filter(u=>!o.some(c=>OA(u,c))),l=mp(a,i,[t||"_","patch",String(((s=o)==null?void 0:s.length)||"0")],r);o.push(...l)}function OA(t,e){return"id"in t&&"id"in e&&t.id===e.id?!0:t.index===e.index&&t.path===e.path&&t.caseSensitive===e.caseSensitive?(!t.children||t.children.length===0)&&(!e.children||e.children.length===0)?!0:t.children.every((n,r)=>{var i;return(i=e.children)==null?void 0:i.some(s=>OA(n,s))}):!1}async function OM(t,e,n){if(!t.lazy)return;let r=await t.lazy();if(!t.lazy)return;let i=n[t.id];et(i,"No route found in manifest");let s={};for(let o in r){let l=i[o]!==void 0&&o!=="hasErrorBoundary";Ya(!l,'Route "'+i.id+'" has a static property "'+o+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+o+'" will be ignored.')),!l&&!X4.has(o)&&(s[o]=r[o])}Object.assign(i,s),Object.assign(i,zt({},e(i),{lazy:void 0}))}async function PM(t){let{matches:e}=t,n=e.filter(i=>i.shouldLoad);return(await Promise.all(n.map(i=>i.resolve()))).reduce((i,s,o)=>Object.assign(i,{[n[o].route.id]:s}),{})}async function RM(t,e,n,r,i,s,o,a,l,u){let c=s.map(p=>p.route.lazy?OM(p.route,l,a):void 0),d=s.map((p,_)=>{let y=c[_],w=i.some(m=>m.route.id===p.route.id);return zt({},p,{shouldLoad:w,resolve:async m=>(m&&r.method==="GET"&&(p.route.lazy||p.route.loader)&&(w=!0),w?CM(e,r,p,y,m,u):Promise.resolve({type:_t.data,result:void 0}))})}),f=await t({matches:d,request:r,params:s[0].params,fetcherKey:o,context:u});try{await Promise.all(c)}catch{}return f}async function CM(t,e,n,r,i,s){let o,a,l=u=>{let c,d=new Promise((_,y)=>c=y);a=()=>c(),e.signal.addEventListener("abort",a);let f=_=>typeof u!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+t+'" [routeId: '+n.route.id+"]"))):u({request:e,params:n.params,context:s},..._!==void 0?[_]:[]),p=(async()=>{try{return{type:"data",result:await(i?i(y=>f(y)):f())}}catch(_){return{type:"error",result:_}}})();return Promise.race([p,d])};try{let u=n.route[t];if(r)if(u){let c,[d]=await Promise.all([l(u).catch(f=>{c=f}),r]);if(c!==void 0)throw c;o=d}else if(await r,u=n.route[t],u)o=await l(u);else if(t==="action"){let c=new URL(e.url),d=c.pathname+c.search;throw sr(405,{method:e.method,pathname:d,routeId:n.route.id})}else return{type:_t.data,result:void 0};else if(u)o=await l(u);else{let c=new URL(e.url),d=c.pathname+c.search;throw sr(404,{pathname:d})}et(o.result!==void 0,"You defined "+(t==="action"?"an action":"a loader")+" for route "+('"'+n.route.id+"\" but didn't return anything from your `"+t+"` ")+"function. Please return a value or `null`.")}catch(u){return{type:_t.error,result:u}}finally{a&&e.signal.removeEventListener("abort",a)}return o}async function NM(t){let{result:e,type:n}=t;if(RA(e)){let d;try{let f=e.headers.get("Content-Type");f&&/\bapplication\/json\b/.test(f)?e.body==null?d=null:d=await e.json():d=await e.text()}catch(f){return{type:_t.error,error:f}}return n===_t.error?{type:_t.error,error:new gp(e.status,e.statusText,d),statusCode:e.status,headers:e.headers}:{type:_t.data,data:d,statusCode:e.status,headers:e.headers}}if(n===_t.error){if(jE(e)){var r,i;if(e.data instanceof Error){var s,o;return{type:_t.error,error:e.data,statusCode:(s=e.init)==null?void 0:s.status,headers:(o=e.init)!=null&&o.headers?new Headers(e.init.headers):void 0}}return{type:_t.error,error:new gp(((r=e.init)==null?void 0:r.status)||500,void 0,e.data),statusCode:_f(e)?e.status:void 0,headers:(i=e.init)!=null&&i.headers?new Headers(e.init.headers):void 0}}return{type:_t.error,error:e,statusCode:_f(e)?e.status:void 0}}if(FM(e)){var a,l;return{type:_t.deferred,deferredData:e,statusCode:(a=e.init)==null?void 0:a.status,headers:((l=e.init)==null?void 0:l.headers)&&new Headers(e.init.headers)}}if(jE(e)){var u,c;return{type:_t.data,data:e.data,statusCode:(u=e.init)==null?void 0:u.status,headers:(c=e.init)!=null&&c.headers?new Headers(e.init.headers):void 0}}return{type:_t.data,data:e}}function DM(t,e,n,r,i,s){let o=t.headers.get("Location");if(et(o,"Redirects returned/thrown from loaders/actions must have a Location header"),!V_.test(o)){let a=r.slice(0,r.findIndex(l=>l.route.id===n)+1);o=Ey(new URL(e.url),a,i,!0,o,s),t.headers.set("Location",o)}return t}function RE(t,e,n,r){let i=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];if(V_.test(t)){let s=t,o=s.startsWith("//")?new URL(e.protocol+s):new URL(s);if(i.includes(o.protocol))throw new Error("Invalid redirect location");let a=Nu(o.pathname,n)!=null;if(o.origin===e.origin&&a)return F_(o.pathname)+o.search+o.hash}try{let s=r.createURL(t);if(i.includes(s.protocol))throw new Error("Invalid redirect location")}catch{}return t}function yl(t,e,n,r){let i=t.createURL(PA(e)).toString(),s={signal:n};if(r&&ni(r.formMethod)){let{formMethod:o,formEncType:a}=r;s.method=o.toUpperCase(),a==="application/json"?(s.headers=new Headers({"Content-Type":a}),s.body=JSON.stringify(r.json)):a==="text/plain"?s.body=r.text:a==="application/x-www-form-urlencoded"&&r.formData?s.body=Ty(r.formData):s.body=r.formData}return new Request(i,s)}function Ty(t){let e=new URLSearchParams;for(let[n,r]of t.entries())e.append(n,typeof r=="string"?r:r.name);return e}function CE(t){let e=new FormData;for(let[n,r]of t.entries())e.append(n,r);return e}function MM(t,e,n,r,i){let s={},o=null,a,l=!1,u={},c=n&&_r(n[1])?n[1].error:void 0;return t.forEach(d=>{if(!(d.route.id in e))return;let f=d.route.id,p=e[f];if(et(!wa(p),"Cannot handle redirect results in processLoaderData"),_r(p)){let _=p.error;c!==void 0&&(_=c,c=void 0),o=o||{};{let y=ma(t,f);o[y.route.id]==null&&(o[y.route.id]=_)}s[f]=void 0,l||(l=!0,a=_f(p.error)?p.error.status:500),p.headers&&(u[f]=p.headers)}else Eo(p)?(r.set(f,p.deferredData),s[f]=p.deferredData.data,p.statusCode!=null&&p.statusCode!==200&&!l&&(a=p.statusCode),p.headers&&(u[f]=p.headers)):(s[f]=p.data,p.statusCode&&p.statusCode!==200&&!l&&(a=p.statusCode),p.headers&&(u[f]=p.headers))}),c!==void 0&&n&&(o={[n[0]]:c},s[n[0]]=void 0),{loaderData:s,errors:o,statusCode:a||200,loaderHeaders:u}}function NE(t,e,n,r,i,s,o){let{loaderData:a,errors:l}=MM(e,n,r,o);return i.forEach(u=>{let{key:c,match:d,controller:f}=u,p=s[c];if(et(p,"Did not find corresponding fetcher result"),!(f&&f.signal.aborted))if(_r(p)){let _=ma(t.matches,d==null?void 0:d.route.id);l&&l[_.route.id]||(l=zt({},l,{[_.route.id]:p.error})),t.fetchers.delete(c)}else if(wa(p))et(!1,"Unhandled fetcher revalidation redirect");else if(Eo(p))et(!1,"Unhandled fetcher deferred data");else{let _=eo(p.data);t.fetchers.set(c,_)}}),{loaderData:a,errors:l}}function DE(t,e,n,r){let i=zt({},e);for(let s of n){let o=s.route.id;if(e.hasOwnProperty(o)?e[o]!==void 0&&(i[o]=e[o]):t[o]!==void 0&&s.route.loader&&(i[o]=t[o]),r&&r.hasOwnProperty(o))break}return i}function ME(t){return t?_r(t[1])?{actionData:{}}:{actionData:{[t[0]]:t[1].data}}:{}}function ma(t,e){return(e?t.slice(0,t.findIndex(r=>r.route.id===e)+1):[...t]).reverse().find(r=>r.route.hasErrorBoundary===!0)||t[0]}function LE(t){let e=t.length===1?t[0]:t.find(n=>n.index||!n.path||n.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:e}],route:e}}function sr(t,e){let{pathname:n,routeId:r,method:i,type:s,message:o}=e===void 0?{}:e,a="Unknown Server Error",l="Unknown @remix-run/router error";return t===400?(a="Bad Request",i&&n&&r?l="You made a "+i+' request to "'+n+'" but '+('did not provide a `loader` for route "'+r+'", ')+"so there is no way to handle the request.":s==="defer-action"?l="defer() is not supported in actions":s==="invalid-body"&&(l="Unable to encode submission body")):t===403?(a="Forbidden",l='Route "'+r+'" does not match URL "'+n+'"'):t===404?(a="Not Found",l='No route matches URL "'+n+'"'):t===405&&(a="Method Not Allowed",i&&n&&r?l="You made a "+i.toUpperCase()+' request to "'+n+'" but '+('did not provide an `action` for route "'+r+'", ')+"so there is no way to handle the request.":i&&(l='Invalid request method "'+i.toUpperCase()+'"')),new gp(t||500,a,new Error(l),!0)}function Zd(t){let e=Object.entries(t);for(let n=e.length-1;n>=0;n--){let[r,i]=e[n];if(wa(i))return{key:r,result:i}}}function PA(t){let e=typeof t=="string"?Zo(t):t;return Qa(zt({},e,{hash:""}))}function LM(t,e){return t.pathname!==e.pathname||t.search!==e.search?!1:t.hash===""?e.hash!=="":t.hash===e.hash?!0:e.hash!==""}function jM(t){return RA(t.result)&&EM.has(t.result.status)}function Eo(t){return t.type===_t.deferred}function _r(t){return t.type===_t.error}function wa(t){return(t&&t.type)===_t.redirect}function jE(t){return typeof t=="object"&&t!=null&&"type"in t&&"data"in t&&"init"in t&&t.type==="DataWithResponseInit"}function FM(t){let e=t;return e&&typeof e=="object"&&typeof e.data=="object"&&typeof e.subscribe=="function"&&typeof e.cancel=="function"&&typeof e.resolveData=="function"}function RA(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.headers=="object"&&typeof t.body<"u"}function VM(t){return bM.has(t.toLowerCase())}function ni(t){return _M.has(t.toLowerCase())}async function UM(t,e,n,r,i){let s=Object.entries(e);for(let o=0;o<s.length;o++){let[a,l]=s[o],u=t.find(f=>(f==null?void 0:f.route.id)===a);if(!u)continue;let c=r.find(f=>f.route.id===u.route.id),d=c!=null&&!IA(c,u)&&(i&&i[u.route.id])!==void 0;Eo(l)&&d&&await U_(l,n,!1).then(f=>{f&&(e[a]=f)})}}async function $M(t,e,n){for(let r=0;r<n.length;r++){let{key:i,routeId:s,controller:o}=n[r],a=e[i];t.find(u=>(u==null?void 0:u.route.id)===s)&&Eo(a)&&(et(o,"Expected an AbortController for revalidating fetcher deferred result"),await U_(a,o.signal,!0).then(u=>{u&&(e[i]=u)}))}}async function U_(t,e,n){if(n===void 0&&(n=!1),!await t.deferredData.resolveData(e)){if(n)try{return{type:_t.data,data:t.deferredData.unwrappedData}}catch(i){return{type:_t.error,error:i}}return{type:_t.data,data:t.deferredData.data}}}function $_(t){return new URLSearchParams(t).getAll("index").some(e=>e==="")}function Oc(t,e){let n=typeof e=="string"?Zo(e).search:e.search;if(t[t.length-1].route.index&&$_(n||""))return t[t.length-1];let r=SA(t);return r[r.length-1]}function FE(t){let{formMethod:e,formAction:n,formEncType:r,text:i,formData:s,json:o}=t;if(!(!e||!n||!r)){if(i!=null)return{formMethod:e,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(s!=null)return{formMethod:e,formAction:n,formEncType:r,formData:s,json:void 0,text:void 0};if(o!==void 0)return{formMethod:e,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function Jg(t,e){return e?{state:"loading",location:t,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}:{state:"loading",location:t,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function BM(t,e){return{state:"submitting",location:t,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}}function gc(t,e){return t?{state:"loading",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:e}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function zM(t,e){return{state:"submitting",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:e?e.data:void 0}}function eo(t){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function qM(t,e){try{let n=t.sessionStorage.getItem(AA);if(n){let r=JSON.parse(n);for(let[i,s]of Object.entries(r||{}))s&&Array.isArray(s)&&e.set(i,new Set(s||[]))}}catch{}}function HM(t,e){if(e.size>0){let n={};for(let[r,i]of e)n[r]=[...i];try{t.sessionStorage.setItem(AA,JSON.stringify(n))}catch(r){Ya(!1,"Failed to save applied view transitions in sessionStorage ("+r+").")}}}/** 51 * React Router v6.30.4 52 * 53 * Copyright (c) Remix Software Inc. 54 * 55 * This source code is licensed under the MIT license found in the 56 * LICENSE.md file in the root directory of this source tree. 57 * 58 * @license MIT 59 */function vp(){return vp=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},vp.apply(null,arguments)}const xm=H.createContext(null),CA=H.createContext(null),Xo=H.createContext(null),B_=H.createContext(null),$i=H.createContext({outlet:null,matches:[],isDataRoute:!1}),NA=H.createContext(null);function WM(t,e){let{relative:n}=e===void 0?{}:e;Du()||et(!1);let{basename:r,navigator:i}=H.useContext(Xo),{hash:s,pathname:o,search:a}=LA(t,{relative:n}),l=o;return r!=="/"&&(l=o==="/"?r:ws([r,o])),i.createHref({pathname:l,search:a,hash:s})}function Du(){return H.useContext(B_)!=null}function Jf(){return Du()||et(!1),H.useContext(B_).location}function DA(t){H.useContext(Xo).static||H.useLayoutEffect(t)}function MA(){let{isDataRoute:t}=H.useContext($i);return t?oL():GM()}function GM(){Du()||et(!1);let t=H.useContext(xm),{basename:e,future:n,navigator:r}=H.useContext(Xo),{matches:i}=H.useContext($i),{pathname:s}=Jf(),o=JSON.stringify(bm(i,n.v7_relativeSplatPath)),a=H.useRef(!1);return DA(()=>{a.current=!0}),H.useCallback(function(u,c){if(c===void 0&&(c={}),!a.current)return;if(typeof u=="number"){r.go(u);return}let d=Em(u,JSON.parse(o),s,c.relative==="path");t==null&&e!=="/"&&(d.pathname=d.pathname==="/"?e:ws([e,d.pathname])),(c.replace?r.replace:r.push)(d,c.state,c)},[e,r,o,s,t])}const KM=H.createContext(null);function YM(t){let e=H.useContext($i).outlet;return e&&H.createElement(KM.Provider,{value:t},e)}function Pr(){let{matches:t}=H.useContext($i),e=t[t.length-1];return e?e.params:{}}function LA(t,e){let{relative:n}=e===void 0?{}:e,{future:r}=H.useContext(Xo),{matches:i}=H.useContext($i),{pathname:s}=Jf(),o=JSON.stringify(bm(i,r.v7_relativeSplatPath));return H.useMemo(()=>Em(t,JSON.parse(o),s,n==="path"),[t,o,s,n])}function QM(t,e,n,r){Du()||et(!1);let{navigator:i}=H.useContext(Xo),{matches:s}=H.useContext($i),o=s[s.length-1],a=o?o.params:{};o&&o.pathname;let l=o?o.pathnameBase:"/";o&&o.route;let u=Jf(),c;c=u;let d=c.pathname||"/",f=d;if(l!=="/"){let y=l.replace(/^\//,"").split("/");f="/"+d.replace(/^\//,"").split("/").slice(y.length).join("/")}let p=pa(t,{pathname:f});return tL(p&&p.map(y=>Object.assign({},y,{params:Object.assign({},a,y.params),pathname:ws([l,i.encodeLocation?i.encodeLocation(y.pathname).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?l:ws([l,i.encodeLocation?i.encodeLocation(y.pathnameBase).pathname:y.pathnameBase])})),s,n,r)}function ZM(){let t=sL(),e=_f(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),n=t instanceof Error?t.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return H.createElement(H.Fragment,null,H.createElement("h2",null,"Unexpected Application Error!"),H.createElement("h3",{style:{fontStyle:"italic"}},e),n?H.createElement("pre",{style:i},n):null,null)}const XM=H.createElement(ZM,null);class JM extends H.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,n){return n.location!==e.location||n.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:n.error,location:n.location,revalidation:e.revalidation||n.revalidation}}componentDidCatch(e,n){console.error("React Router caught the following error during render",e,n)}render(){return this.state.error!==void 0?H.createElement($i.Provider,{value:this.props.routeContext},H.createElement(NA.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function eL(t){let{routeContext:e,match:n,children:r}=t,i=H.useContext(xm);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),H.createElement($i.Provider,{value:e},r)}function tL(t,e,n,r){var i;if(e===void 0&&(e=[]),n===void 0&&(n=null),r===void 0&&(r=null),t==null){var s;if(!n)return null;if(n.errors)t=n.matches;else if((s=r)!=null&&s.v7_partialHydration&&e.length===0&&!n.initialized&&n.matches.length>0)t=n.matches;else return null}let o=t,a=(i=n)==null?void 0:i.errors;if(a!=null){let c=o.findIndex(d=>d.route.id&&(a==null?void 0:a[d.route.id])!==void 0);c>=0||et(!1),o=o.slice(0,Math.min(o.length,c+1))}let l=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c<o.length;c++){let d=o[c];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(u=c),d.route.id){let{loaderData:f,errors:p}=n,_=d.route.loader&&f[d.route.id]===void 0&&(!p||p[d.route.id]===void 0);if(d.route.lazy||_){l=!0,u>=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((c,d,f)=>{let p,_=!1,y=null,w=null;n&&(p=a&&d.route.id?a[d.route.id]:void 0,y=d.route.errorElement||XM,l&&(u<0&&f===0?(aL("route-fallback"),_=!0,w=null):u===f&&(_=!0,w=d.route.hydrateFallbackElement||null)));let g=e.concat(o.slice(0,f+1)),m=()=>{let b;return p?b=y:_?b=w:d.route.Component?b=H.createElement(d.route.Component,null):d.route.element?b=d.route.element:b=c,H.createElement(eL,{match:d,routeContext:{outlet:c,matches:g,isDataRoute:n!=null},children:b})};return n&&(d.route.ErrorBoundary||d.route.errorElement||f===0)?H.createElement(JM,{location:n.location,revalidation:n.revalidation,component:y,error:p,children:m(),routeContext:{outlet:null,matches:g,isDataRoute:!0}}):m()},null)}var jA=function(t){return t.UseBlocker="useBlocker",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t}(jA||{}),FA=function(t){return t.UseBlocker="useBlocker",t.UseLoaderData="useLoaderData",t.UseActionData="useActionData",t.UseRouteError="useRouteError",t.UseNavigation="useNavigation",t.UseRouteLoaderData="useRouteLoaderData",t.UseMatches="useMatches",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t.UseRouteId="useRouteId",t}(FA||{});function nL(t){let e=H.useContext(xm);return e||et(!1),e}function rL(t){let e=H.useContext(CA);return e||et(!1),e}function iL(t){let e=H.useContext($i);return e||et(!1),e}function VA(t){let e=iL(),n=e.matches[e.matches.length-1];return n.route.id||et(!1),n.route.id}function sL(){var t;let e=H.useContext(NA),n=rL(FA.UseRouteError),r=VA();return e!==void 0?e:(t=n.errors)==null?void 0:t[r]}function oL(){let{router:t}=nL(jA.UseNavigateStable),e=VA(),n=H.useRef(!1);return DA(()=>{n.current=!0}),H.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?t.navigate(i):t.navigate(i,vp({fromRouteId:e},s)))},[t,e])}const VE={};function aL(t,e,n){VE[t]||(VE[t]=!0)}function lL(t,e){t==null||t.v7_startTransition,(t==null?void 0:t.v7_relativeSplatPath)===void 0&&(!e||e.v7_relativeSplatPath),e&&(e.v7_fetcherPersist,e.v7_normalizeFormMethod,e.v7_partialHydration,e.v7_skipActionErrorRevalidation)}function uL(t){let{to:e,replace:n,state:r,relative:i}=t;Du()||et(!1);let{future:s,static:o}=H.useContext(Xo),{matches:a}=H.useContext($i),{pathname:l}=Jf(),u=MA(),c=Em(e,bm(a,s.v7_relativeSplatPath),l,i==="path"),d=JSON.stringify(c);return H.useEffect(()=>u(JSON.parse(d),{replace:n,state:r,relative:i}),[u,d,i,n,r]),null}function cL(t){return YM(t.context)}function fL(t){let{basename:e="/",children:n=null,location:r,navigationType:i=on.Pop,navigator:s,static:o=!1,future:a}=t;Du()&&et(!1);let l=e.replace(/^\/*/,"/"),u=H.useMemo(()=>({basename:l,navigator:s,static:o,future:vp({v7_relativeSplatPath:!1},a)}),[l,a,s,o]);typeof r=="string"&&(r=Zo(r));let{pathname:c="/",search:d="",hash:f="",state:p=null,key:_="default"}=r,y=H.useMemo(()=>{let w=Nu(c,l);return w==null?null:{location:{pathname:w,search:d,hash:f,state:p,key:_},navigationType:i}},[l,c,d,f,p,_,i]);return y==null?null:H.createElement(Xo.Provider,{value:u},H.createElement(B_.Provider,{children:n,value:y}))}new Promise(()=>{});function dL(t){let e={hasErrorBoundary:t.ErrorBoundary!=null||t.errorElement!=null};return t.Component&&Object.assign(e,{element:H.createElement(t.Component),Component:void 0}),t.HydrateFallback&&Object.assign(e,{hydrateFallbackElement:H.createElement(t.HydrateFallback),HydrateFallback:void 0}),t.ErrorBoundary&&Object.assign(e,{errorElement:H.createElement(t.ErrorBoundary),ErrorBoundary:void 0}),e}/** 60 * React Router DOM v6.30.4 61 * 62 * Copyright (c) Remix Software Inc. 63 * 64 * This source code is licensed under the MIT license found in the 65 * LICENSE.md file in the root directory of this source tree. 66 * 67 * @license MIT 68 */function wf(){return wf=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},wf.apply(null,arguments)}function hL(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function pL(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function mL(t,e){return t.button===0&&(!e||e==="_self")&&!pL(t)}const gL=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],vL="6";try{window.__reactRouterVersion=vL}catch{}function yL(t,e){return kM({basename:void 0,future:wf({},void 0,{v7_prependBasename:!0}),history:Y4({window:void 0}),hydrationData:_L(),routes:t,mapRouteProperties:dL,dataStrategy:void 0,patchRoutesOnNavigation:void 0,window:void 0}).initialize()}function _L(){var t;let e=(t=window)==null?void 0:t.__staticRouterHydrationData;return e&&e.errors&&(e=wf({},e,{errors:wL(e.errors)})),e}function wL(t){if(!t)return null;let e=Object.entries(t),n={};for(let[r,i]of e)if(i&&i.__type==="RouteErrorResponse")n[r]=new gp(i.status,i.statusText,i.data,i.internal===!0);else if(i&&i.__type==="Error"){if(i.__subType){let s=window[i.__subType];if(typeof s=="function")try{let o=new s(i.message);o.stack="",n[r]=o}catch{}}if(n[r]==null){let s=new Error(i.message);s.stack="",n[r]=s}}else n[r]=i;return n}const bL=H.createContext({isTransitioning:!1}),EL=H.createContext(new Map),xL="startTransition",UE=LN[xL],TL="flushSync",$E=K4[TL];function SL(t){UE?UE(t):t()}function vc(t){$E?$E(t):t()}let kL=class{constructor(){this.status="pending",this.promise=new Promise((e,n)=>{this.resolve=r=>{this.status==="pending"&&(this.status="resolved",e(r))},this.reject=r=>{this.status==="pending"&&(this.status="rejected",n(r))}})}};function AL(t){let{fallbackElement:e,router:n,future:r}=t,[i,s]=H.useState(n.state),[o,a]=H.useState(),[l,u]=H.useState({isTransitioning:!1}),[c,d]=H.useState(),[f,p]=H.useState(),[_,y]=H.useState(),w=H.useRef(new Map),{v7_startTransition:g}=r||{},m=H.useCallback(E=>{g?SL(E):E()},[g]),b=H.useCallback((E,T)=>{let{deletedFetchers:S,flushSync:k,viewTransitionOpts:I}=T;E.fetchers.forEach((M,$)=>{M.data!==void 0&&w.current.set($,M.data)}),S.forEach(M=>w.current.delete(M));let P=n.window==null||n.window.document==null||typeof n.window.document.startViewTransition!="function";if(!I||P){k?vc(()=>s(E)):m(()=>s(E));return}if(k){vc(()=>{f&&(c&&c.resolve(),f.skipTransition()),u({isTransitioning:!0,flushSync:!0,currentLocation:I.currentLocation,nextLocation:I.nextLocation})});let M=n.window.document.startViewTransition(()=>{vc(()=>s(E))});M.finished.finally(()=>{vc(()=>{d(void 0),p(void 0),a(void 0),u({isTransitioning:!1})})}),vc(()=>p(M));return}f?(c&&c.resolve(),f.skipTransition(),y({state:E,currentLocation:I.currentLocation,nextLocation:I.nextLocation})):(a(E),u({isTransitioning:!0,flushSync:!1,currentLocation:I.currentLocation,nextLocation:I.nextLocation}))},[n.window,f,c,w,m]);H.useLayoutEffect(()=>n.subscribe(b),[n,b]),H.useEffect(()=>{l.isTransitioning&&!l.flushSync&&d(new kL)},[l]),H.useEffect(()=>{if(c&&o&&n.window){let E=o,T=c.promise,S=n.window.document.startViewTransition(async()=>{m(()=>s(E)),await T});S.finished.finally(()=>{d(void 0),p(void 0),a(void 0),u({isTransitioning:!1})}),p(S)}},[m,o,c,n.window]),H.useEffect(()=>{c&&o&&i.location.key===o.location.key&&c.resolve()},[c,f,i.location,o]),H.useEffect(()=>{!l.isTransitioning&&_&&(a(_.state),u({isTransitioning:!0,flushSync:!1,currentLocation:_.currentLocation,nextLocation:_.nextLocation}),y(void 0))},[l.isTransitioning,_]),H.useEffect(()=>{},[]);let v=H.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:E=>n.navigate(E),push:(E,T,S)=>n.navigate(E,{state:T,preventScrollReset:S==null?void 0:S.preventScrollReset}),replace:(E,T,S)=>n.navigate(E,{replace:!0,state:T,preventScrollReset:S==null?void 0:S.preventScrollReset})}),[n]),A=n.basename||"/",N=H.useMemo(()=>({router:n,navigator:v,static:!1,basename:A}),[n,v,A]),x=H.useMemo(()=>({v7_relativeSplatPath:n.future.v7_relativeSplatPath}),[n.future.v7_relativeSplatPath]);return H.useEffect(()=>lL(r,n.future),[r,n.future]),H.createElement(H.Fragment,null,H.createElement(xm.Provider,{value:N},H.createElement(CA.Provider,{value:i},H.createElement(EL.Provider,{value:w.current},H.createElement(bL.Provider,{value:l},H.createElement(fL,{basename:A,location:i.location,navigationType:i.historyAction,navigator:v,future:x},i.initialized||n.future.v7_partialHydration?H.createElement(IL,{routes:n.routes,future:n.future,state:i}):e))))),null)}const IL=H.memo(OL);function OL(t){let{routes:e,future:n,state:r}=t;return QM(e,void 0,r,n)}const PL=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",RL=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,an=H.forwardRef(function(e,n){let{onClick:r,relative:i,reloadDocument:s,replace:o,state:a,target:l,to:u,preventScrollReset:c,viewTransition:d}=e,f=hL(e,gL),{basename:p}=H.useContext(Xo),_,y=!1;if(typeof u=="string"&&RL.test(u)&&(_=u,PL))try{let b=new URL(window.location.href),v=u.startsWith("//")?new URL(b.protocol+u):new URL(u),A=Nu(v.pathname,p);v.origin===b.origin&&A!=null?u=A+v.search+v.hash:y=!0}catch{}let w=WM(u,{relative:i}),g=CL(u,{replace:o,state:a,target:l,preventScrollReset:c,relative:i,viewTransition:d});function m(b){r&&r(b),b.defaultPrevented||g(b)}return H.createElement("a",wf({},f,{href:_||w,onClick:y||s?r:m,ref:n,target:l}))});var BE;(function(t){t.UseScrollRestoration="useScrollRestoration",t.UseSubmit="useSubmit",t.UseSubmitFetcher="useSubmitFetcher",t.UseFetcher="useFetcher",t.useViewTransitionState="useViewTransitionState"})(BE||(BE={}));var zE;(function(t){t.UseFetcher="useFetcher",t.UseFetchers="useFetchers",t.UseScrollRestoration="useScrollRestoration"})(zE||(zE={}));function CL(t,e){let{target:n,replace:r,state:i,preventScrollReset:s,relative:o,viewTransition:a}=e===void 0?{}:e,l=MA(),u=Jf(),c=LA(t,{relative:o});return H.useCallback(d=>
68{if(mL(d,n)){d.preventDefault();let f=r!==void 0?r:Qa(u)===Qa(c);l(t,{replace:f,state:i,preventScrollReset:s,relative:o,viewTransition:a})}},[u,l,c,r,i,n,t,s,o,a])}var UA,qE=wm;UA=qE.createRoot,qE.hydrateRoot;var HE={};/** 69 * @license 70 * Copyright 2017 Google LLC 71 * 72 * Licensed under the Apache License, Version 2.0 (the "License"); 73 * you may not use this file except in compliance with the License. 74 * You may obtain a copy of the License at 75 * 76 * http://www.apache.org/licenses/LICENSE-2.0 77 * 78 * Unless required by applicable law or agreed to in writing, software 79 * distributed under the License is distributed on an "AS IS" BASIS, 80 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 81 * See the License for the specific language governing permissions and 82 * limitations under the License. 83 */const $A=function(t){const e=[];let 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},NL=function(t){const e=[];let n=0,r=0;for(;n<t.length;){const i=t[n++];if(i<128)e[r++]=String.fromCharCode(i);else if(i>191&&i<224){const s=t[n++];e[r++]=String.fromCharCode((i&31)<<6|s&63)}else if(i>239&&i<365){const s=t[n++],o=t[n++],a=t[n++],l=((i&7)<<18|(s&63)<<12|(o&63)<<6|a&63)-65536;e[r++]=String.fromCharCode(55296+(l>>10)),e[r++]=String.fromCharCode(56320+(l&1023))}else{const s=t[n++],o=t[n++];e[r++]=String.fromCharCode((i&15)<<12|(s&63)<<6|o&63)}}return e.join("")},BA={byteToCharMap_:null,charToByteMap_:null,byteToCharMapWebSafe_:null,charToByteMapWebSafe_:null,ENCODED_VALS_BASE:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",get ENCODED_VALS(){return this.ENCODED_VALS_BASE+"+/="},get ENCODED_VALS_WEBSAFE(){return this.ENCODED_VALS_BASE+"-_."},HAS_NATIVE_SUPPORT:typeof atob=="function",encodeByteArray(t,e){if(!Array.isArray(t))throw Error("encodeByteArray takes an array as a parameter");this.init_();const n=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,r=[];for(let i=0;i<t.length;i+=3){const s=t[i],o=i+1<t.length,a=o?t[i+1]:0,l=i+2<t.length,u=l?t[i+2]:0,c=s>>2,d=(s&3)<<4|a>>4;let f=(a&15)<<2|u>>6,p=u&63;l||(p=64,o||(f=64)),r.push(n[c],n[d],n[f],n[p])}return r.join("")},encodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(t):this.encodeByteArray($A(t),e)},decodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(t):NL(this.decodeStringToByteArray(t,e))},decodeStringToByteArray(t,e){this.init_();const n=e?this.charToByteMapWebSafe_:this.charToByteMap_,r=[];for(let i=0;i<t.length;){const s=n[t.charAt(i++)],a=i<t.length?n[t.charAt(i)]:0;++i;const u=i<t.length?n[t.charAt(i)]:64;++i;const d=i<t.length?n[t.charAt(i)]:64;if(++i,s==null||a==null||u==null||d==null)throw new DL;const f=s<<2|a>>4;if(r.push(f),u!==64){const p=a<<4&240|u>>2;if(r.push(p),d!==64){const _=u<<6&192|d;r.push(_)}}}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)}}};class DL extends Error{constructor(){super(...arguments),this.name="DecodeBase64StringError"}}const ML=function(t){const e=$A(t);return BA.encodeByteArray(e,!0)},yp=function(t){return ML(t).replace(/\./g,"")},zA=function(t){try{return BA.decodeString(t,!0)}catch(e){console.error("base64Decode failed: ",e)}return null};/** 84 * @license 85 * Copyright 2022 Google LLC 86 * 87 * Licensed under the Apache License, Version 2.0 (the "License"); 88 * you may not use this file except in compliance with the License. 89 * You may obtain a copy of the License at 90 * 91 * http://www.apache.org/licenses/LICENSE-2.0 92 * 93 * Unless required by applicable law or agreed to in writing, softw
93are 94 * distributed under the License is distributed on an "AS IS" BASIS, 95 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 96 * See the License for the specific language governing permissions and 97 * limitations under the License. 98 */function LL(){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.")}/** 99 * @license 100 * Copyright 2022 Google LLC 101 * 102 * Licensed under the Apache License, Version 2.0 (the "License"); 103 * you may not use this file except in compliance with the License. 104 * You may obtain a copy of the License at 105 * 106 * http://www.apache.org/licenses/LICENSE-2.0 107 * 108 * Unless required by applicable law or agreed to in writing, software 109 * distributed under the License is distributed on an "AS IS" BASIS, 110 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 111 * See the License for the specific language governing permissions and 112 * limitations under the License. 113 */const jL=()=>LL().__FIREBASE_DEFAULTS__,FL=()=>{if(typeof process>"u"||typeof HE>"u")return;const t=HE.__FIREBASE_DEFAULTS__;if(t)return JSON.parse(t)},VL=()=>{if(typeof document>"u")return;let t;try{t=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}const e=t&&zA(t[1]);return e&&JSON.parse(e)},Tm=()=>{try{return jL()||FL()||VL()}catch(t){console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${t}`);return}},qA=t=>{var e,n;return(n=(e=Tm())===null||e===void 0?void 0:e.emulatorHosts)===null||n===void 0?void 0:n[t]},HA=t=>{const e=qA(t);if(!e)return;const n=e.lastIndexOf(":");if(n<=0||n+1===e.length)throw new Error(`Invalid host ${e} with no separate hostname and port!`);const r=parseInt(e.substring(n+1),10);return e[0]==="["?[e.substring(1,n-1),r]:[e.substring(0,n),r]},WA=()=>{var t;return(t=Tm())===null||t===void 0?void 0:t.config},GA=t=>{var e;return(e=Tm())===null||e===void 0?void 0:e[`_${t}`]};/** 114 * @license 115 * Copyright 2017 Google LLC 116 * 117 * Licensed under the Apache License, Version 2.0 (the "License"); 118 * you may not use this file except in compliance with the License. 119 * You may obtain a copy of the License at 120 * 121 * http://www.apache.org/licenses/LICENSE-2.0 122 * 123 * Unless required by applicable law or agreed to in writing, software 124 * distributed under the License is distributed on an "AS IS" BASIS, 125 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 126 * See the License for the specific language governing permissions and 127 * limitations under the License. 128 */class UL{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))}}}/** 129 * @license 130 * Copyright 2021 Google LLC 131 * 132 * Licensed under the Apache License, Version 2.0 (the "License"); 133 * you may not use this file except in compliance with the License. 134 * You may obtain a copy of the License at 135 * 136 * http://www.apache.org/licenses/LICENSE-2.0 137 * 138 * Unless required by applicable law or agreed to in writing, software 139 * distributed under the License is distributed on an "AS IS" BASIS, 140 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 141 * See the License for the specific language governing permissions and 142 * limitations under the License. 143 */function KA(t,e){if(t.uid)throw new Error('The "uid" field is no longer supported by mockUserToken. Please use "sub" instead for Firebase Auth User ID.');const n={alg:"none",type:"JWT"},r=e||"demo-project",i=t.iat||0,s=t.sub||t.user_id;if(!s)throw new Error("mockUserToken must contain 'sub' or 'user_id' field!");const o=Object.assign({iss:`https://securetoken.google.com/${r}`,aud:r,iat:i,exp:i+3600,auth_time:i,sub:s,user_id:s,firebase:{sign_in_provider:"custom",identities:{}}},t);return[yp(JSON.stringify(n)),yp(JSON.stringify(o)),""].join(".")}/** 144 * @license 145 * Copyright 2017 Google LLC 146 * 147 * Licensed under the Apache License, Version 2.0 (the "License");
148 * you may not use this file except in compliance with the License. 149 * You may obtain a copy of the License at 150 * 151 * http://www.apache.org/licenses/LICENSE-2.0 152 * 153 * Unless required by applicable law or agreed to in writing, software 154 * distributed under the License is distributed on an "AS IS" BASIS, 155 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 156 * See the License for the specific language governing permissions and 157 * limitations under the License. 158 */function Vn(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function $L(){return typeof window<"u"&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(Vn())}function BL(){var t;const e=(t=Tm())===null||t===void 0?void 0:t.forceEnvironment;if(e==="node")return!0;if(e==="browser")return!1;try{return Object.prototype.toString.call(global.process)==="[object process]"}catch{return!1}}function zL(){return typeof navigator<"u"&&navigator.userAgent==="Cloudflare-Workers"}function YA(){const t=typeof chrome=="object"?chrome.runtime:typeof browser=="object"?browser.runtime:void 0;return typeof t=="object"&&t.id!==void 0}function qL(){return typeof navigator=="object"&&navigator.product==="ReactNative"}function HL(){const t=Vn();return t.indexOf("MSIE ")>=0||t.indexOf("Trident/")>=0}function WL(){return!BL()&&!!navigator.userAgent&&navigator.userAgent.includes("Safari")&&!navigator.userAgent.includes("Chrome")}function QA(){try{return typeof indexedDB=="object"}catch{return!1}}function ZA(){return new Promise((t,e)=>{try{let n=!0;const 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=()=>{var s;e(((s=i.error)===null||s===void 0?void 0:s.message)||"")}}catch(n){e(n)}})}function GL(){return!(typeof navigator>"u"||!navigator.cookieEnabled)}/** 159 * @license 160 * Copyright 2017 Google LLC 161 * 162 * Licensed under the Apache License, Version 2.0 (the "License"); 163 * you may not use this file except in compliance with the License. 164 * You may obtain a copy of the License at 165 * 166 * http://www.apache.org/licenses/LICENSE-2.0 167 * 168 * Unless required by applicable law or agreed to in writing, software 169 * distributed under the License is distributed on an "AS IS" BASIS, 170 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 171 * See the License for the specific language governing permissions and 172 * limitations under the License. 173 */const KL="FirebaseError";class qr extends Error{constructor(e,n,r){super(n),this.code=e,this.customData=r,this.name=KL,Object.setPrototypeOf(this,qr.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,ol.prototype.create)}}class ol{constructor(e,n,r){this.service=e,this.serviceName=n,this.errors=r}create(e,...n){const r=n[0]||{},i=`${this.service}/${e}`,s=this.errors[e],o=s?YL(s,r):"Error",a=`${this.serviceName}: ${o} (${i}).`;return new qr(i,a,r)}}function YL(t,e){return t.replace(QL,(n,r)=>{const i=e[r];return i!=null?String(i):`<${r}?>`})}const QL=/\{\$([^}]+)}/g;function ZL(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}function bf(t,e){if(t===e)return!0;const n=Object.keys(t),r=Object.keys(e);for(const i of n){if(!r.includes(i))return!1;const s=t[i],o=e[i];if(WE(s)&&WE(o)){if(!bf(s,o))return!1}else if(s!==o)return!1}for(const i of r)if(!n.includes(i))return!1;return!0}function WE(t){return t!==null&&typeof t=="object"}/** 174 * @license 175 * Copyright 2017 Google LLC 176 * 177 * Licensed under the Apache License, Version 2.0 (the "License"); 178 * you may not use this file except in compliance with the License. 179 * You may obtain a copy of the License at 180 * 181 * http://www.apache.org/licenses/LICENSE-2.0 182 * 183 * Unless required by applicable law or agreed to in writing, software 184 * distributed under the License is distributed on an "AS IS" BASIS, 185 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 186 * See the License for the specific language governing permissions and 187 * limitations under the License. 188 */function ed(t){const e=[];for(const[n,r]of Object.entries(t))Array.isArray(r)?r.forEach(i=>
188{e.push(encodeURIComponent(n)+"="+encodeURIComponent(i))}):e.push(encodeURIComponent(n)+"="+encodeURIComponent(r));return e.length?"&"+e.join("&"):""}function XL(t,e){const n=new JL(t,e);return n.subscribe.bind(n)}class JL{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.");ej(e,["next","error","complete"])?i=e:i={next:e,error:n,complete:r},i.next===void 0&&(i.next=ev),i.error===void 0&&(i.error=ev),i.complete===void 0&&(i.complete=ev);const 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 ej(t,e){if(typeof t!="object"||t===null)return!1;for(const n of e)if(n in t&&typeof t[n]=="function")return!0;return!1}function ev(){}/** 189 * @license 190 * Copyright 2019 Google LLC 191 * 192 * Licensed under the Apache License, Version 2.0 (the "License"); 193 * you may not use this file except in compliance with the License. 194 * You may obtain a copy of the License at 195 * 196 * http://www.apache.org/licenses/LICENSE-2.0 197 * 198 * Unless required by applicable law or agreed to in writing, software 199 * distributed under the License is distributed on an "AS IS" BASIS, 200 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 201 * See the License for the specific language governing permissions and 202 * limitations under the License. 203 */const tj=1e3,nj=2,rj=4*60*60*1e3,ij=.5;function GE(t,e=tj,n=nj){const r=e*Math.pow(n,t),i=Math.round(ij*r*(Math.random()-.5)*2);return Math.min(rj,r+i)}/** 204 * @license 205 * Copyright 2021 Google LLC 206 * 207 * Licensed under the Apache License, Version 2.0 (the "License"); 208 * you may not use this file except in compliance with the License. 209 * You may obtain a copy of the License at 210 * 211 * http://www.apache.org/licenses/LICENSE-2.0 212 * 213 * Unless required by applicable law or agreed to in writing, software 214 * distributed under the License is distributed on an "AS IS" BASIS, 215 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 216 * See the License for the specific language governing permissions and 217 * limitations under the License. 218 */function Ot(t){return t&&t._delegate?t._delegate:t}class zr{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}}/** 219 * @license 220 * Copyright 2019 Google LLC 221 * 222 * Licensed under the Apache License, Version 2.0 (the "License"); 223 * you may not use this file except in compliance with the License. 224 * You may obtain a copy of the License at 225 * 226 * http://www.apache.org/licenses/LICENSE-2.0 227 * 228 * Unless required by applicable law or agreed to in writing, software 229 * distributed under the License is distributed on an "AS IS" BASIS, 230 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 231 * See the License for the specific language governing permissions and 232 * limitations under the License. 233 */const da="[DEFAULT]";/** 234 * @license 235 * Copyright 2019 Google LLC 236 * 237 * Licensed under the Apache License, Version 2.0 (the "License");
238 * you may not use this file except in compliance with the License. 239 * You may obtain a copy of the License at 240 * 241 * http://www.apache.org/licenses/LICENSE-2.0 242 * 243 * Unless required by applicable law or agreed to in writing, software 244 * distributed under the License is distributed on an "AS IS" BASIS, 245 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 246 * See the License for the specific language governing permissions and 247 * limitations under the License. 248 */class sj{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){const n=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(n)){const r=new UL;if(this.instancesDeferred.set(n,r),this.isInitialized(n)||this.shouldAutoInitialize())try{const i=this.getOrInitializeService({instanceIdentifier:n});i&&r.resolve(i)}catch{}}return this.instancesDeferred.get(n).promise}getImmediate(e){var n;const r=this.normalizeInstanceIdentifier(e==null?void 0:e.identifier),i=(n=e==null?void 0:e.optional)!==null&&n!==void 0?n:!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(aj(e))try{this.getOrInitializeService({instanceIdentifier:da})}catch{}for(const[n,r]of this.instancesDeferred.entries()){const i=this.normalizeInstanceIdentifier(n);try{const s=this.getOrInitializeService({instanceIdentifier:i});r.resolve(s)}catch{}}}}clearInstance(e=da){this.instancesDeferred.delete(e),this.instancesOptions.delete(e),this.instances.delete(e)}async delete(){const 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=da){return this.instances.has(e)}getOptions(e=da){return this.instancesOptions.get(e)||{}}initialize(e={}){const{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`);const i=this.getOrInitializeService({instanceIdentifier:r,options:n});for(const[s,o]of this.instancesDeferred.entries()){const a=this.normalizeInstanceIdentifier(s);r===a&&o.resolve(i)}return i}onInit(e,n){var r;const i=this.normalizeInstanceIdentifier(n),s=(r=this.onInitCallbacks.get(i))!==null&&r!==void 0?r:new Set;s.add(e),this.onInitCallbacks.set(i,s);const o=this.instances.get(i);return o&&e(o,i),()=>{s.delete(e)}}invokeOnInitCallbacks(e,n){const r=this.onInitCallbacks.get(n);if(r)for(const 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:oj(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=da){return this.component?this.component.multipleInstances?e:da:e}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}}function oj(t){return t===da?void 0:t}function aj(t){return t.instantiationMode==="EAGER"}/** 249 * @license 250 * Copyright 2019 Google LLC 251 * 252 * Licensed under the Apache License, Version 2.0 (the "License"); 253 * you may not use this file except in compliance with the License. 254 * You may obtain a copy of the License at 255 * 256 * http://www.apache.org/licenses/LICENSE-2.0 257 * 258 * Unless required by applicable law or agreed to in writing, softw
258are 259 * distributed under the License is distributed on an "AS IS" BASIS, 260 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 261 * See the License for the specific language governing permissions and 262 * limitations under the License. 263 */class lj{constructor(e){this.name=e,this.providers=new Map}addComponent(e){const 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);const n=new sj(e,this);return this.providers.set(e,n),n}getProviders(){return Array.from(this.providers.values())}}/** 264 * @license 265 * Copyright 2017 Google LLC 266 * 267 * Licensed under the Apache License, Version 2.0 (the "License"); 268 * you may not use this file except in compliance with the License. 269 * You may obtain a copy of the License at 270 * 271 * http://www.apache.org/licenses/LICENSE-2.0 272 * 273 * Unless required by applicable law or agreed to in writing, software 274 * distributed under the License is distributed on an "AS IS" BASIS, 275 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 276 * See the License for the specific language governing permissions and 277 * limitations under the License. 278 */var at;(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"})(at||(at={}));const uj={debug:at.DEBUG,verbose:at.VERBOSE,info:at.INFO,warn:at.WARN,error:at.ERROR,silent:at.SILENT},cj=at.INFO,fj={[at.DEBUG]:"log",[at.VERBOSE]:"log",[at.INFO]:"info",[at.WARN]:"warn",[at.ERROR]:"error"},dj=(t,e,...n)=>{if(e<t.logLevel)return;const r=new Date().toISOString(),i=fj[e];if(i)console[i](`[${r}] ${t.name}:`,...n);else throw new Error(`Attempted to log a message with an invalid logType (value: ${e})`)};class Sm{constructor(e){this.name=e,this._logLevel=cj,this._logHandler=dj,this._userLogHandler=null}get logLevel(){return this._logLevel}set logLevel(e){if(!(e in at))throw new TypeError(`Invalid value "${e}" assigned to \`logLevel\``);this._logLevel=e}setLogLevel(e){this._logLevel=typeof e=="string"?uj[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,at.DEBUG,...e),this._logHandler(this,at.DEBUG,...e)}log(...e){this._userLogHandler&&this._userLogHandler(this,at.VERBOSE,...e),this._logHandler(this,at.VERBOSE,...e)}info(...e){this._userLogHandler&&this._userLogHandler(this,at.INFO,...e),this._logHandler(this,at.INFO,...e)}warn(...e){this._userLogHandler&&this._userLogHandler(this,at.WARN,...e),this._logHandler(this,at.WARN,...e)}error(...e){this._userLogHandler&&this._userLogHandler(this,at.ERROR,...e),this._logHandler(this,at.ERROR,...e)}}const hj=(t,e)=>e.some(n=>t instanceof n);let KE,YE;function pj(){return KE||(KE=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function mj(){return YE||(YE=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}const XA=new WeakMap,Sy=new WeakMap,JA=new WeakMap,tv=new WeakMap,z_=new WeakMap;function gj(t){const e=new Promise((n,r)=>{const i=()=>{t.removeEventListener("success",s),t.removeEventListener("error",o)},s=()=>{n(Mo(t.result)),i()},o=()=>{r(t.error),i()};t.addEventListener("success",s),t.addEventListener("error",o)});return e.then(n=>{n instanceof IDBCursor&&XA.set(n,t)}).catch(()=>{}),z_.set(e,t),e}function vj(t){if(Sy.has(t))return;const e=new Promise((n,r)=>{const 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)});Sy.set(t,e)}let ky={get(t,e,n){if(t instanceof IDBTransaction){if(e==="done")return Sy.get(t);if(e==="objectStoreNames")return t.objectStoreNames||JA.get(t);if(e==="store")return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return Mo(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 yj(t){ky=t(ky)}function _j(t){return t===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(e,...n){const r=t.call(nv(this),e,...n);return JA.set(r,e.sort?e.sort():[e]),Mo(r)}:mj().includes(t)?function(...e){return t.apply(nv(this),e),Mo(XA.get(this))}:function(...e){return Mo(t.apply(nv(this),e))}}function wj(t){return typeof t=="function"?_j(t):(t instanceof IDBTransaction&&vj(t),hj(t,pj())?new Proxy(t,ky):t)}function Mo(t){if(t instanceof IDBRequest)return gj(t);if(tv.has(t))return tv.get(t);const e=wj(t);return e!==t&&(tv.set(t,e),z_.set(e,t)),e}const nv=t=>z_.get(t);function eI(t,e,{blocked:n,upgrade:r,blocking:i,terminated:s}={}){const o=indexedDB.open(t,e),a=Mo(o);return r&&o.addEventListener("upgradeneeded",l=>{r(Mo(o.result),l.oldVersion,l.newVersion,Mo(o.transaction),l)}),n&&o.addEventListener("blocked",l=>n(l.oldVersion,l.newVersion,l)),a.then(l=>{s&&l.addEventListener("close",()=>s()),i&&l.addEventListener("versionchange",u=>i(u.oldVersion,u.newVersion,u))}).catch(()=>{}),a}const bj=["get","getKey","getAll","getAllKeys","count"],Ej=["put","add","delete","clear"],rv=ne
278w Map;function QE(t,e){if(!(t instanceof IDBDatabase&&!(e in t)&&typeof e=="string"))return;if(rv.get(e))return rv.get(e);const n=e.replace(/FromIndex$/,""),r=e!==n,i=Ej.includes(n);if(!(n in(r?IDBIndex:IDBObjectStore).prototype)||!(i||bj.includes(n)))return;const s=async function(o,...a){const l=this.transaction(o,i?"readwrite":"readonly");let u=l.store;return r&&(u=u.index(a.shift())),(await Promise.all([u[n](...a),i&&l.done]))[0]};return rv.set(e,s),s}yj(t=>({...t,get:(e,n,r)=>QE(e,n)||t.get(e,n,r),has:(e,n)=>!!QE(e,n)||t.has(e,n)}));/** 279 * @license 280 * Copyright 2019 Google LLC 281 * 282 * Licensed under the Apache License, Version 2.0 (the "License"); 283 * you may not use this file except in compliance with the License. 284 * You may obtain a copy of the License at 285 * 286 * http://www.apache.org/licenses/LICENSE-2.0 287 * 288 * Unless required by applicable law or agreed to in writing, software 289 * distributed under the License is distributed on an "AS IS" BASIS, 290 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 291 * See the License for the specific language governing permissions and 292 * limitations under the License. 293 */class xj{constructor(e){this.container=e}getPlatformInfoString(){return this.container.getProviders().map(n=>{if(Tj(n)){const r=n.getImmediate();return`${r.library}/${r.version}`}else return null}).filter(n=>n).join(" ")}}function Tj(t){const e=t.getComponent();return(e==null?void 0:e.type)==="VERSION"}const Ay="@firebase/app",ZE="0.10.13";/** 294 * @license 295 * Copyright 2019 Google LLC 296 * 297 * Licensed under the Apache License, Version 2.0 (the "License"); 298 * you may not use this file except in compliance with the License. 299 * You may obtain a copy of the License at 300 * 301 * http://www.apache.org/licenses/LICENSE-2.0 302 * 303 * Unless required by applicable law or agreed to in writing, software 304 * distributed under the License is distributed on an "AS IS" BASIS, 305 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 306 * See the License for the specific language governing permissions and 307 * limitations under the License. 308 */const Rs=new Sm("@firebase/app"),Sj="@firebase/app-compat",kj="@firebase/analytics-compat",Aj="@firebase/analytics",Ij="@firebase/app-check-compat",Oj="@firebase/app-check",Pj="@firebase/auth",Rj="@firebase/auth-compat",Cj="@firebase/database",Nj="@firebase/data-connect",Dj="@firebase/database-compat",Mj="@firebase/functions",Lj="@firebase/functions-compat",jj="@firebase/installations",Fj="@firebase/installations-compat",Vj="@firebase/messaging",Uj="@firebase/messaging-compat",$j="@firebase/performance",Bj="@firebase/performance-compat",zj="@firebase/remote-config",qj="@firebase/remote-config-compat",Hj="@firebase/storage",Wj="@firebase/storage-compat",Gj="@firebase/firestore",Kj="@firebase/vertexai-preview",Yj="@firebase/firestore-compat",Qj="firebase",Zj="10.14.1";/** 309 * @license 310 * Copyright 2019 Google LLC 311 * 312 * Licensed under the Apache License, Version 2.0 (the "License"); 313 * you may not use this file except in compliance with the License. 314 * You may obtain a copy of the License at 315 * 316 * http://www.apache.org/licenses/LICENSE-2.0 317 * 318 * Unless required by applicable law or agreed to in writing, software 319 * distributed under the License is distributed on an "AS IS" BASIS, 320 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 321 * See the License for the specific language governing permissions and 322 * limitations under the License. 323 */const Iy="[DEFAULT]",Xj={[Ay]:"fire-core",[Sj]:"fire-core-compat",[Aj]:"fire-analytics",[kj]:"fire-analytics-compat",[Oj]:"fire-app-check",[Ij]:"fire-app-check-compat",[Pj]:"fire-auth",[Rj]:"fire-auth-compat",[Cj]:"fire-rtdb",[Nj]:"fire-data-connect",[Dj]:"fire-rtdb-compat",[Mj]:"fire-fn",[Lj]:"fire-fn-compat",[jj]:"fire-iid",[Fj]:"fire-iid-compat",[Vj]:"fire-fcm",[Uj]:"fire-fcm-compat",[$j]:"fire-perf",[Bj]:"fire-perf-compat",[zj]:"fire-rc",[qj]:"fire-rc-compat",[Hj]:"fire-gcs",[Wj]:"fire-gcs-compat",[Gj]:"fire-fst",[Yj]:"fire-fst-compat",[Kj]:"fire-vertex","fire-js":"fire-js",[Qj]:"fire-js-all"};/** 324 * @license 325 * Copyright 2019 Google LLC 326 * 327 * Licensed under the Apache License, Version 2.0 (the "License");
328 * you may not use this file except in compliance with the License. 329 * You may obtain a copy of the License at 330 * 331 * http://www.apache.org/licenses/LICENSE-2.0 332 * 333 * Unless required by applicable law or agreed to in writing, software 334 * distributed under the License is distributed on an "AS IS" BASIS, 335 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 336 * See the License for the specific language governing permissions and 337 * limitations under the License. 338 */const _p=new Map,Jj=new Map,Oy=new Map;function XE(t,e){try{t.container.addComponent(e)}catch(n){Rs.debug(`Component ${e.name} failed to register with FirebaseApp ${t.name}`,n)}}function fi(t){const e=t.name;if(Oy.has(e))return Rs.debug(`There were multiple attempts to register component ${e}.`),!1;Oy.set(e,t);for(const n of _p.values())XE(n,t);for(const n of Jj.values())XE(n,t);return!0}function Jo(t,e){const n=t.container.getProvider("heartbeat").getImmediate({optional:!0});return n&&n.triggerHeartbeat(),t.container.getProvider(e)}function hs(t){return t.settings!==void 0}/** 339 * @license 340 * Copyright 2019 Google LLC 341 * 342 * Licensed under the Apache License, Version 2.0 (the "License"); 343 * you may not use this file except in compliance with the License. 344 * You may obtain a copy of the License at 345 * 346 * http://www.apache.org/licenses/LICENSE-2.0 347 * 348 * Unless required by applicable law or agreed to in writing, software 349 * distributed under the License is distributed on an "AS IS" BASIS, 350 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 351 * See the License for the specific language governing permissions and 352 * limitations under the License. 353 */const e6={"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.","invali
353d-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."},Lo=new ol("app","Firebase",e6);/** 354 * @license 355 * Copyright 2019 Google LLC 356 * 357 * Licensed under the Apache License, Version 2.0 (the "License"); 358 * you may not use this file except in compliance with the License. 359 * You may obtain a copy of the License at 360 * 361 * http://www.apache.org/licenses/LICENSE-2.0 362 * 363 * Unless required by applicable law or agreed to in writing, software 364 * distributed under the License is distributed on an "AS IS" BASIS, 365 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 366 * See the License for the specific language governing permissions and 367 * limitations under the License. 368 */class t6{constructor(e,n,r){this._isDeleted=!1,this._options=Object.assign({},e),this._config=Object.assign({},n),this._name=n.name,this._automaticDataCollectionEnabled=n.automaticDataCollectionEnabled,this._container=r,this.container.addComponent(new zr("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 Lo.create("app-deleted",{appName:this._name})}}/** 369 * @license 370 * Copyright 2019 Google LLC 371 * 372 * Licensed under the Apache License, Version 2.0 (the "License"); 373 * you may not use this file except in compliance with the License. 374 * You may obtain a copy of the License at 375 * 376 * http://www.apache.org/licenses/LICENSE-2.0 377 * 378 * Unless required by applicable law or agreed to in writing, software 379 * distributed under the License is distributed on an "AS IS" BASIS, 380 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 381 * See the License for the specific language governing permissions and 382 * limitations under the License. 383 */const al=Zj;function tI(t,e={}){let n=t;typeof e!="object"&&(e={name:e});const r=Object.assign({name:Iy,automaticDataCollectionEnabled:!1},e),i=r.name;if(typeof i!="string"||!i)throw Lo.create("bad-app-name",{appName:String(i)});if(n||(n=WA()),!n)throw Lo.create("no-options");const s=_p.get(i);if(s){if(bf(n,s.options)&&bf(r,s.config))return s;throw Lo.create("duplicate-app",{appName:i})}const o=new lj(i);for(const l of Oy.values())o.addComponent(l);const a=new t6(n,r,o);return _p.set(i,a),a}function km(t=Iy){const e=_p.get(t);if(!e&&t===Iy&&WA())return tI();if(!e)throw Lo.create("no-app",{appName:t});return e}function dr(t,e,n){var r;let i=(r=Xj[t])!==null&&r!==void 0?r:t;n&&(i+=`-${n}`);const s=i.match(/\s|\//),o=e.match(/\s|\//);if(s||o){const a=[`Unable to register library "${i}" with version "${e}":`];s&&a.push(`library name "${i}" contains illegal characters (whitespace or "/")`),s&&o&&a.push("and"),o&&a.push(`version name "${e}" contains illegal characters (whitespace or "/")`),Rs.warn(a.join(" "));return}fi(new zr(`${i}-version`,()=>({library:i,version:e}),"VERSION"))}/** 384 * @license 385 * Copyright 2021 Google LLC 386 * 387 * Licensed under the Apache License, Version 2.0 (the "License"); 388 * you may not use this file except in compliance with the License. 389 * You may obtain a copy of the License at 390 * 391 * http://www.apache.org/licenses/LICENSE-2.0 392 * 393 * Unless required by applicable law or agreed to in writing, softw
393are 394 * distributed under the License is distributed on an "AS IS" BASIS, 395 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 396 * See the License for the specific language governing permissions and 397 * limitations under the License. 398 */const n6="firebase-heartbeat-database",r6=1,Ef="firebase-heartbeat-store";let iv=null;function nI(){return iv||(iv=eI(n6,r6,{upgrade:(t,e)=>{switch(e){case 0:try{t.createObjectStore(Ef)}catch(n){console.warn(n)}}}}).catch(t=>{throw Lo.create("idb-open",{originalErrorMessage:t.message})})),iv}async function i6(t){try{const n=(await nI()).transaction(Ef),r=await n.objectStore(Ef).get(rI(t));return await n.done,r}catch(e){if(e instanceof qr)Rs.warn(e.message);else{const n=Lo.create("idb-get",{originalErrorMessage:e==null?void 0:e.message});Rs.warn(n.message)}}}async function JE(t,e){try{const r=(await nI()).transaction(Ef,"readwrite");await r.objectStore(Ef).put(e,rI(t)),await r.done}catch(n){if(n instanceof qr)Rs.warn(n.message);else{const r=Lo.create("idb-set",{originalErrorMessage:n==null?void 0:n.message});Rs.warn(r.message)}}}function rI(t){return`${t.name}!${t.options.appId}`}/** 399 * @license 400 * Copyright 2021 Google LLC 401 * 402 * Licensed under the Apache License, Version 2.0 (the "License"); 403 * you may not use this file except in compliance with the License. 404 * You may obtain a copy of the License at 405 * 406 * http://www.apache.org/licenses/LICENSE-2.0 407 * 408 * Unless required by applicable law or agreed to in writing, software 409 * distributed under the License is distributed on an "AS IS" BASIS, 410 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 411 * See the License for the specific language governing permissions and 412 * limitations under the License. 413 */const s6=1024,o6=30*24*60*60*1e3;class a6{constructor(e){this.container=e,this._heartbeatsCache=null;const n=this.container.getProvider("app").getImmediate();this._storage=new u6(n),this._heartbeatsCachePromise=this._storage.read().then(r=>(this._heartbeatsCache=r,r))}async triggerHeartbeat(){var e,n;try{const i=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),s=ex();return((e=this._heartbeatsCache)===null||e===void 0?void 0:e.heartbeats)==null&&(this._heartbeatsCache=await this._heartbeatsCachePromise,((n=this._heartbeatsCache)===null||n===void 0?void 0:n.heartbeats)==null)||this._heartbeatsCache.lastSentHeartbeatDate===s||this._heartbeatsCache.heartbeats.some(o=>o.date===s)?void 0:(this._heartbeatsCache.heartbeats.push({date:s,agent:i}),this._heartbeatsCache.heartbeats=this._heartbeatsCache.heartbeats.filter(o=>{const a=new Date(o.date).valueOf();return Date.now()-a<=o6}),this._storage.overwrite(this._heartbeatsCache))}catch(r){Rs.warn(r)}}async getHeartbeatsHeader(){var e;try{if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,((e=this._heartbeatsCache)===null||e===void 0?void 0:e.heartbeats)==null||this._heartbeatsCache.heartbeats.length===0)return"";const n=ex(),{heartbeatsToSend:r,unsentEntries:i}=l6(this._heartbeatsCache.heartbeats),s=yp(JSON.stringify({version:2,heartbeats:r}));return this._heartbeatsCache.lastSentHeartbeatDate=n,i.length>0?(this._heartbeatsCache.heartbeats=i,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),s}catch(n){return Rs.warn(n),""}}}function ex(){return new Date().toISOString().substring(0,10)}function l6(t,e=s6){const n=[];let r=t.slice();for(const i of t){const s=n.find(o=>o.agent===i.agent);if(s){if(s.dates.push(i.date),tx(n)>e){s.dates.pop();break}}else if(n.push({agent:i.agent,dates:[i.date]}),tx(n)>e){n.pop();break}r=r.slice(1)}return{heartbeatsToSend:n,unsentEntries:r}}class u6{constructor(e){this.app=e,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return QA()?ZA().then(()=>!0).catch(()=>!1):!1}async read(){if(await this._canUseIndexedDBPromise){const n=await i6(this.app);return n!=null&&n.heartbeats?n:{heartbeats:[]}}else return{heartbeats:[]}}async overwrite(e){var n;if(await this._canUseIndexedDBPromise){const i=await this.read();return JE(this.app,{lastSentHeartbeatDate:(n=e.lastSentHeartbeatDate)!==null&&n!==void 0?n:i.lastSentHeartbeatDate,heartbeats:e.heartbeats})}else return}async add(e){var n;if(await this._canUseIndexedDBPromise){const i=await this.read();return JE(this.app,{lastSentHeartbeatDate:(n=e.lastSentHeartbeatDate)!==null&&n!==void 0?n:i.lastSentHeartbeatDate,heartbeats:[...i.heartbeats,...e.heartbeats]})}else return}}function tx(t){return yp(JSON.stringify({version:2,heartbeats:t})).length}/** 414 * @license 415 * Copyright 2019 Google LLC 416 * 417 * Licensed under the Apache License, Version 2.0 (the "License");
418 * you may not use this file except in compliance with the License. 419 * You may obtain a copy of the License at 420 * 421 * http://www.apache.org/licenses/LICENSE-2.0 422 * 423 * Unless required by applicable law or agreed to in writing, software 424 * distributed under the License is distributed on an "AS IS" BASIS, 425 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 426 * See the License for the specific language governing permissions and 427 * limitations under the License. 428 */function c6(t){fi(new zr("platform-logger",e=>new xj(e),"PRIVATE")),fi(new zr("heartbeat",e=>new a6(e),"PRIVATE")),dr(Ay,ZE,t),dr(Ay,ZE,"esm2017"),dr("fire-js","")}c6("");function q_(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]]);return n}function ll(t,e,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function a(c){try{u(r.next(c))}catch(d){o(d)}}function l(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(a,l)}u((r=r.apply(t,e||[])).next())})}function iI(){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."}}const f6=iI,sI=new ol("auth","Firebase",iI());/** 429 * @license 430 * Copyright 2020 Google LLC 431 * 432 * Licensed under the Apache License, Version 2.0 (the "License"); 433 * you may not use this file except in compliance with the License. 434 * You may obtain a copy of the License at 435 * 436 * http://www.apache.org/licenses/LICENSE-2.0 437 * 438 * Unless required by applicable law or agreed to in writing, software 439 * distributed under the License is distributed on an "AS IS" BASIS, 440 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 441 * See the License for the specific language governing permissions and 442 * limitations under the License. 443 */const wp=new Sm("@firebase/auth");function d6(t,...e){wp.logLevel<=at.WARN&&wp.warn(`Auth (${al}): ${t}`,...e)}function Ah(t,...e){wp.logLevel<=at.ERROR&&wp.error(`Auth (${al}): ${t}`,...e)}/** 444 * @license 445 * Copyright 2020 Google LLC 446 * 447 * Licensed under the Apache License, Version 2.0 (the "License"); 448 * you may not use this file except in compliance with the License. 449 * You may obtain a copy of the License at 450 * 451 * http://www.apache.org/licenses/LICENSE-2.0 452 * 453 * Unless required by applicable law or agreed to in writing, software 454 * distributed under the License is distributed on an "AS IS" BASIS, 455 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 456 * See the License for the specific language governing permissions and 457 * limitations under the License. 458 */function Fi(t,...e){throw W_(t,...e)}function li(t,...e){return W_(t,...e)}function H_(t,e,n){const r=Object.assign(Object.assign({},f6()),{[e]:n});return new ol("auth","Firebase",r).create(e,{appName:t.name})}function Fa(t){return H_(t,"operation-not-supported-in-this-environment","Operations that alter the current user are not supported in conjunction with FirebaseServerApp")}function h6(t,e,n){const r=n;if(!(e instanceof r))throw r.name!==e.constructor.name&&Fi(t,"argument-error"),H_(t,"argument-error",`Type of ${e.constructor.name} does not match expected instance.Did you pass a reference from a different Auth SDK?`)}function W_(t,...e){if(typeof t!="string"){const n=e[0],r=[...e.slice(1)];return r[0]&&(r[0].appName=t.name),t._errorFactory.create(n,...r)}return sI.create(t,...e)}function Be(t,e,...n){if(!t)throw W_(e,...n)}function ps(t){const e="INTERNAL ASSERTION FAILED: "+t;throw Ah(e),new Error(e)}function Cs(t,e){t||ps(e)}/** 459 * @license 460 * Copyright 2020 Google LLC 461 * 462 * Licensed under the Apache License, Version 2.0 (the "License"); 463 * you may not use this file except in compliance with the License. 464 * You may obtain a copy of the License at 465 * 466 * http://www.apache.org/licenses/LICENSE-2.0 467 * 468 * Unless required by applicable law or agreed to in writing, softw
468are 469 * distributed under the License is distributed on an "AS IS" BASIS, 470 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 471 * See the License for the specific language governing permissions and 472 * limitations under the License. 473 */function Py(){var t;return typeof self<"u"&&((t=self.location)===null||t===void 0?void 0:t.href)||""}function p6(){return nx()==="http:"||nx()==="https:"}function nx(){var t;return typeof self<"u"&&((t=self.location)===null||t===void 0?void 0:t.protocol)||null}/** 474 * @license 475 * Copyright 2020 Google LLC 476 * 477 * Licensed under the Apache License, Version 2.0 (the "License"); 478 * you may not use this file except in compliance with the License. 479 * You may obtain a copy of the License at 480 * 481 * http://www.apache.org/licenses/LICENSE-2.0 482 * 483 * Unless required by applicable law or agreed to in writing, software 484 * distributed under the License is distributed on an "AS IS" BASIS, 485 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 486 * See the License for the specific language governing permissions and 487 * limitations under the License. 488 */function m6(){return typeof navigator<"u"&&navigator&&"onLine"in navigator&&typeof navigator.onLine=="boolean"&&(p6()||YA()||"connection"in navigator)?navigator.onLine:!0}function g6(){if(typeof navigator>"u")return null;const t=navigator;return t.languages&&t.languages[0]||t.language||null}/** 489 * @license 490 * Copyright 2020 Google LLC 491 * 492 * Licensed under the Apache License, Version 2.0 (the "License"); 493 * you may not use this file except in compliance with the License. 494 * You may obtain a copy of the License at 495 * 496 * http://www.apache.org/licenses/LICENSE-2.0 497 * 498 * Unless required by applicable law or agreed to in writing, software 499 * distributed under the License is distributed on an "AS IS" BASIS, 500 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 501 * See the License for the specific language governing permissions and 502 * limitations under the License. 503 */class td{constructor(e,n){this.shortDelay=e,this.longDelay=n,Cs(n>e,"Short delay should be less than long delay!"),this.isMobile=$L()||qL()}get(){return m6()?this.isMobile?this.longDelay:this.shortDelay:Math.min(5e3,this.shortDelay)}}/** 504 * @license 505 * Copyright 2020 Google LLC 506 * 507 * Licensed under the Apache License, Version 2.0 (the "License"); 508 * you may not use this file except in compliance with the License. 509 * You may obtain a copy of the License at 510 * 511 * http://www.apache.org/licenses/LICENSE-2.0 512 * 513 * Unless required by applicable law or agreed to in writing, software 514 * distributed under the License is distributed on an "AS IS" BASIS, 515 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 516 * See the License for the specific language governing permissions and 517 * limitations under the License. 518 */function G_(t,e){Cs(t.emulator,"Emulator should always be set here");const{url:n}=t.emulator;return e?`${n}${e.startsWith("/")?e.slice(1):e}`:n}/** 519 * @license 520 * Copyright 2020 Google LLC 521 * 522 * Licensed under the Apache License, Version 2.0 (the "License"); 523 * you may not use this file except in compliance with the License. 524 * You may obtain a copy of the License at 525 * 526 * http://www.apache.org/licenses/LICENSE-2.0 527 * 528 * Unless required by applicable law or agreed to in writing, software 529 * distributed under the License is distributed on an "AS IS" BASIS, 530 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 531 * See the License for the specific language governing permissions and 532 * limitations under the License. 533 */class oI{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;ps("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;ps("Could not find Headers implementation, make sure you call FetchProvi
533der.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;ps("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}}/** 534 * @license 535 * Copyright 2020 Google LLC 536 * 537 * Licensed under the Apache License, Version 2.0 (the "License"); 538 * you may not use this file except in compliance with the License. 539 * You may obtain a copy of the License at 540 * 541 * http://www.apache.org/licenses/LICENSE-2.0 542 * 543 * Unless required by applicable law or agreed to in writing, software 544 * distributed under the License is distributed on an "AS IS" BASIS, 545 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 546 * See the License for the specific language governing permissions and 547 * limitations under the License. 548 */const v6={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"};/** 549 * @license 550 * Copyright 2020 Google LLC 551 * 552 * Licensed under the Apache License, Version 2.0 (the "License"); 553 * you may not use this file except in compliance with the License. 554 * You may obtain a copy of the License at 555 * 556 * http://www.apache.org/licenses/LICENSE-2.0 557 * 558 * Unless required by applicable law or agreed to in writing, software 559 * distributed under the License is distributed on an "AS IS" BASIS, 560 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 561 * See the License for the specific language governing permissions and 562 * limitations under the License. 563 */const y6=new td(3e4,6e4);function K_(t,e){return t.tenantId&&!e.tenantId?Object.assign(Object.assign({},e),{tenantId:t.tenantId}):e}async function Mu(t,e,n,r,i={}){return aI(t,i,async()=>{let s={},o={};r&&(e==="GET"?o=r:s={body:JSON.stringify(r)});const a=ed(Object.assign({key:t.config.apiKey},o)).slice(1),l=await t._getAdditionalHeaders();l["Content-Type"]="application/json",t.languageCode&&(l["X-Firebase-Locale"]=t.languageCode);const u=Object.assign({method:e,headers:l},s);return zL()||(u.referrerPolicy="no-referrer"),oI.fetch()(lI(t,t.config.apiHost,n,a),u)})}async function aI(t,e,n){t._canInitEmulator=!1;const r=Object.assign(Object.assign({},v6),e);try{const i=new w6(t),s=await Promise.race([n(),i.promise]);i.clearNetworkTimeout();const o=await s.json();if("needConfirmation"in o)throw Xd(t,"account-exists-with-different-credential",o);if(s.ok&&!("errorMessage"in o))return o;{const a=s.ok?o.errorMessage:o.error.message,[l,u]=a.split(" : ");if(l==="FEDERATED_USER_ID_ALREADY_LINKED")throw Xd(t,"credential-already-in-use",o);if(l==="EMAIL_EXISTS")throw Xd(t,"email-already-in-use",o);if(l==="USER_DISABLED")throw Xd(t,"user-disabled",o);const c=r[l]||l.toLowerCase().replace(/[_\s]+/g,"-");if(u)throw H_(t,c,u);Fi(t,c)}}catch(i){if(i instanceof qr)throw i;Fi(t,"network-request-failed",{message:String(i)})}}async function _6(t,e,n,r,i={}){const s=await Mu(t,e,n,r,i);return"mfaPendingCredential"in s&&Fi(t,"multi-factor-auth-required",{_serverResponse:s}),s}function lI(t,e,n,r){const i=`${e}${n}?${r}`;return t.config.emulator?G_(t.config,i):`${t.config.apiScheme}://${i}`}class w6{constructor(e){this.auth=e,this.timer=null,this.promise=new Promise((n,r)=>{this.timer=setTimeout(()=>r(li(this.auth,"network-request-failed")),y6.get())})}clearNetworkTimeout(){clearTimeout(this.timer)}}function Xd(t,e,n){const r={appName:t.name};n.email&&(r.email=n.email),n.phoneNumber&&(r.phoneNumber=n.phoneNumber);const i=li(t,e,r);return i.customData._tokenResponse=n,i}/** 564 * @license 565 * Copyright 2020 Google LLC 566 * 567 * Licensed under the Apache License, Version 2.0 (the "License");
568 * you may not use this file except in compliance with the License. 569 * You may obtain a copy of the License at 570 * 571 * http://www.apache.org/licenses/LICENSE-2.0 572 * 573 * Unless required by applicable law or agreed to in writing, software 574 * distributed under the License is distributed on an "AS IS" BASIS, 575 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 576 * See the License for the specific language governing permissions and 577 * limitations under the License. 578 */async function b6(t,e){return Mu(t,"POST","/v1/accounts:delete",e)}async function uI(t,e){return Mu(t,"POST","/v1/accounts:lookup",e)}/** 579 * @license 580 * Copyright 2020 Google LLC 581 * 582 * Licensed under the Apache License, Version 2.0 (the "License"); 583 * you may not use this file except in compliance with the License. 584 * You may obtain a copy of the License at 585 * 586 * http://www.apache.org/licenses/LICENSE-2.0 587 * 588 * Unless required by applicable law or agreed to in writing, software 589 * distributed under the License is distributed on an "AS IS" BASIS, 590 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 591 * See the License for the specific language governing permissions and 592 * limitations under the License. 593 */function Hc(t){if(t)try{const e=new Date(Number(t));if(!isNaN(e.getTime()))return e.toUTCString()}catch{}}async function E6(t,e=!1){const n=Ot(t),r=await n.getIdToken(e),i=Y_(r);Be(i&&i.exp&&i.auth_time&&i.iat,n.auth,"internal-error");const s=typeof i.firebase=="object"?i.firebase:void 0,o=s==null?void 0:s.sign_in_provider;return{claims:i,token:r,authTime:Hc(sv(i.auth_time)),issuedAtTime:Hc(sv(i.iat)),expirationTime:Hc(sv(i.exp)),signInProvider:o||null,signInSecondFactor:(s==null?void 0:s.sign_in_second_factor)||null}}function sv(t){return Number(t)*1e3}function Y_(t){const[e,n,r]=t.split(".");if(e===void 0||n===void 0||r===void 0)return Ah("JWT malformed, contained fewer than 3 sections"),null;try{const i=zA(n);return i?JSON.parse(i):(Ah("Failed to decode base64 JWT payload"),null)}catch(i){return Ah("Caught error parsing JWT payload as JSON",i==null?void 0:i.toString()),null}}function rx(t){const e=Y_(t);return Be(e,"internal-error"),Be(typeof e.exp<"u","internal-error"),Be(typeof e.iat<"u","internal-error"),Number(e.exp)-Number(e.iat)}/** 594 * @license 595 * Copyright 2020 Google LLC 596 * 597 * Licensed under the Apache License, Version 2.0 (the "License"); 598 * you may not use this file except in compliance with the License. 599 * You may obtain a copy of the License at 600 * 601 * http://www.apache.org/licenses/LICENSE-2.0 602 * 603 * Unless required by applicable law or agreed to in writing, software 604 * distributed under the License is distributed on an "AS IS" BASIS, 605 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 606 * See the License for the specific language governing permissions and 607 * limitations under the License. 608 */async function xf(t,e,n=!1){if(n)return e;try{return await e}catch(r){throw r instanceof qr&&x6(r)&&t.auth.currentUser===t&&await t.auth.signOut(),r}}function x6({code:t}){return t==="auth/user-disabled"||t==="auth/user-token-expired"}/** 609 * @license 610 * Copyright 2020 Google LLC 611 * 612 * Licensed under the Apache License, Version 2.0 (the "License"); 613 * you may not use this file except in compliance with the License. 614 * You may obtain a copy of the License at 615 * 616 * http://www.apache.org/licenses/LICENSE-2.0 617 * 618 * Unless required by applicable law or agreed to in writing, software 619 * distributed under the License is distributed on an "AS IS" BASIS, 620 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 621 * See the License for the specific language governing permissions and 622 * limitations under the License. 623 */class T6{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 n;if(e){const r=this.errorBackoff;return this.errorBackoff=Math.min(this.errorBackoff*2,96e4),r}else{this.errorBackoff=3e4;const i=((n=this.user.stsTokenManager.expirationTime)!==null&&n!==void 0?n:0)-Date.now()-3e5;return Math.max(0,i)}}schedule(e=!1){if(!this.isRunning)return;const n=this.getInterval(e);this.timerId=setTimeout(async()=>{await this.iteration()},n)}async iteration(){try{await this.user.getIdToken(!0)}catch(e){(e==null?void 0:e.code)==="auth/network-request-failed"&&this.schedule(!0);return}this.schedule()}}/** 624 * @license 625 * Copyright 2020 Google LLC 626 * 627 * Licensed under the Apache License, Version 2.0 (the "License");
628 * you may not use this file except in compliance with the License. 629 * You may obtain a copy of the License at 630 * 631 * http://www.apache.org/licenses/LICENSE-2.0 632 * 633 * Unless required by applicable law or agreed to in writing, software 634 * distributed under the License is distributed on an "AS IS" BASIS, 635 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 636 * See the License for the specific language governing permissions and 637 * limitations under the License. 638 */class Ry{constructor(e,n){this.createdAt=e,this.lastLoginAt=n,this._initializeTime()}_initializeTime(){this.lastSignInTime=Hc(this.lastLoginAt),this.creationTime=Hc(this.createdAt)}_copy(e){this.createdAt=e.createdAt,this.lastLoginAt=e.lastLoginAt,this._initializeTime()}toJSON(){return{createdAt:this.createdAt,lastLoginAt:this.lastLoginAt}}}/** 639 * @license 640 * Copyright 2019 Google LLC 641 * 642 * Licensed under the Apache License, Version 2.0 (the "License"); 643 * you may not use this file except in compliance with the License. 644 * You may obtain a copy of the License at 645 * 646 * http://www.apache.org/licenses/LICENSE-2.0 647 * 648 * Unless required by applicable law or agreed to in writing, software 649 * distributed under the License is distributed on an "AS IS" BASIS, 650 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 651 * See the License for the specific language governing permissions and 652 * limitations under the License. 653 */async function bp(t){var e;const n=t.auth,r=await t.getIdToken(),i=await xf(t,uI(n,{idToken:r}));Be(i==null?void 0:i.users.length,n,"internal-error");const s=i.users[0];t._notifyReloadListener(s);const o=!((e=s.providerUserInfo)===null||e===void 0)&&e.length?cI(s.providerUserInfo):[],a=k6(t.providerData,o),l=t.isAnonymous,u=!(t.email&&s.passwordHash)&&!(a!=null&&a.length),c=l?u:!1,d={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:a,metadata:new Ry(s.createdAt,s.lastLoginAt),isAnonymous:c};Object.assign(t,d)}async function S6(t){const e=Ot(t);await bp(e),await e.auth._persistUserIfCurrent(e),e.auth._notifyListenersIfCurrent(e)}function k6(t,e){return[...t.filter(r=>!e.some(i=>i.providerId===r.providerId)),...e]}function cI(t){return t.map(e=>{var{providerId:n}=e,r=q_(e,["providerId"]);return{providerId:n,uid:r.rawId||"",displayName:r.displayName||null,email:r.email||null,phoneNumber:r.phoneNumber||null,photoURL:r.photoUrl||null}})}/** 654 * @license 655 * Copyright 2020 Google LLC 656 * 657 * Licensed under the Apache License, Version 2.0 (the "License"); 658 * you may not use this file except in compliance with the License. 659 * You may obtain a copy of the License at 660 * 661 * http://www.apache.org/licenses/LICENSE-2.0 662 * 663 * Unless required by applicable law or agreed to in writing, software 664 * distributed under the License is distributed on an "AS IS" BASIS, 665 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 666 * See the License for the specific language governing permissions and 667 * limitations under the License. 668 */async function A6(t,e){const n=await aI(t,{},async()=>{const r=ed({grant_type:"refresh_token",refresh_token:e}).slice(1),{tokenApiHost:i,apiKey:s}=t.config,o=lI(t,i,"/v1/token",`key=${s}`),a=await t._getAdditionalHeaders();return a["Content-Type"]="application/x-www-form-urlencoded",oI.fetch()(o,{method:"POST",headers:a,body:r})});return{accessToken:n.access_token,expiresIn:n.expires_in,refreshToken:n.refresh_token}}async function I6(t,e){return Mu(t,"POST","/v2/accounts:revokeToken",K_(t,e))}/** 669 * @license 670 * Copyright 2020 Google LLC 671 * 672 * Licensed under the Apache License, Version 2.0 (the "License"); 673 * you may not use this file except in compliance with the License. 674 * You may obtain a copy of the License at 675 * 676 * http://www.apache.org/licenses/LICENSE-2.0 677 * 678 * Unless required by applicable law or agreed to in writing, software 679 * distributed under the License is distributed on an "AS IS" BASIS, 680 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 681 * See the License for the specific language governing permissions and 682 * limitations under the License. 683 */class Wl{constructor(){this.refreshToken=null,this.accessToken=null,this.expirationTime=null}get isExpired(){return!this.expirationTime||Date.now()>this.expirationTime-3e4}updateFromServerResponse(e){Be(e.idToken,"internal-error"),Be(typeof e.idToken<"u","internal-error"),Be(typeof e.refreshToken<"u","internal-error");
683const n="expiresIn"in e&&typeof e.expiresIn<"u"?Number(e.expiresIn):rx(e.idToken);this.updateTokensAndExpiration(e.idToken,e.refreshToken,n)}updateFromIdToken(e){Be(e.length!==0,"internal-error");const n=rx(e);this.updateTokensAndExpiration(e,null,n)}async getToken(e,n=!1){return!n&&this.accessToken&&!this.isExpired?this.accessToken:(Be(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){const{accessToken:r,refreshToken:i,expiresIn:s}=await A6(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){const{refreshToken:r,accessToken:i,expirationTime:s}=n,o=new Wl;return r&&(Be(typeof r=="string","internal-error",{appName:e}),o.refreshToken=r),i&&(Be(typeof i=="string","internal-error",{appName:e}),o.accessToken=i),s&&(Be(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 Wl,this.toJSON())}_performRefresh(){return ps("not implemented")}}/** 684 * @license 685 * Copyright 2020 Google LLC 686 * 687 * Licensed under the Apache License, Version 2.0 (the "License"); 688 * you may not use this file except in compliance with the License. 689 * You may obtain a copy of the License at 690 * 691 * http://www.apache.org/licenses/LICENSE-2.0 692 * 693 * Unless required by applicable law or agreed to in writing, software 694 * distributed under the License is distributed on an "AS IS" BASIS, 695 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 696 * See the License for the specific language governing permissions and 697 * limitations under the License. 698 */function Ys(t,e){Be(typeof t=="string"||typeof t>"u","internal-error",{appName:e})}class ms{constructor(e){var{uid:n,auth:r,stsTokenManager:i}=e,s=q_(e,["uid","auth","stsTokenManager"]);this.providerId="firebase",this.proactiveRefresh=new T6(this),this.reloadUserInfo=null,this.reloadListener=null,this.uid=n,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 Ry(s.createdAt||void 0,s.lastLoginAt||void 0)}async getIdToken(e){const n=await xf(this,this.stsTokenManager.getToken(this.auth,e));return Be(n,this.auth,"internal-error"),this.accessToken!==n&&(this.accessToken=n,await this.auth._persistUserIfCurrent(this),this.auth._notifyListenersIfCurrent(this)),n}getIdTokenResult(e){return E6(this,e)}reload(){return S6(this)}_assign(e){this!==e&&(Be(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=>Object.assign({},n)),this.metadata._copy(e.metadata),this.stsTokenManager._assign(e.stsTokenManager))}_clone(e){const n=new ms(Object.assign(Object.assign({},this),{auth:e,stsTokenManager:this.stsTokenManager._clone()}));return n.metadata._copy(this.metadata),n}_onReload(e){Be(!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 bp(this),await this.auth._persistUserIfCurrent(this),r&&this.auth._notifyListenersIfCurrent(this)}async delete(){if(hs(this.auth.app))return Promise.reject(Fa(this.auth));const e=await this.getIdToken();return await xf(this,b6(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,isA
698nonymous: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,n){var r,i,s,o,a,l,u,c;const d=(r=n.displayName)!==null&&r!==void 0?r:void 0,f=(i=n.email)!==null&&i!==void 0?i:void 0,p=(s=n.phoneNumber)!==null&&s!==void 0?s:void 0,_=(o=n.photoURL)!==null&&o!==void 0?o:void 0,y=(a=n.tenantId)!==null&&a!==void 0?a:void 0,w=(l=n._redirectEventId)!==null&&l!==void 0?l:void 0,g=(u=n.createdAt)!==null&&u!==void 0?u:void 0,m=(c=n.lastLoginAt)!==null&&c!==void 0?c:void 0,{uid:b,emailVerified:v,isAnonymous:A,providerData:N,stsTokenManager:x}=n;Be(b&&x,e,"internal-error");const E=Wl.fromJSON(this.name,x);Be(typeof b=="string",e,"internal-error"),Ys(d,e.name),Ys(f,e.name),Be(typeof v=="boolean",e,"internal-error"),Be(typeof A=="boolean",e,"internal-error"),Ys(p,e.name),Ys(_,e.name),Ys(y,e.name),Ys(w,e.name),Ys(g,e.name),Ys(m,e.name);const T=new ms({uid:b,auth:e,email:f,emailVerified:v,displayName:d,isAnonymous:A,photoURL:_,phoneNumber:p,tenantId:y,stsTokenManager:E,createdAt:g,lastLoginAt:m});return N&&Array.isArray(N)&&(T.providerData=N.map(S=>Object.assign({},S))),w&&(T._redirectEventId=w),T}static async _fromIdTokenResponse(e,n,r=!1){const i=new Wl;i.updateFromServerResponse(n);const s=new ms({uid:n.localId,auth:e,stsTokenManager:i,isAnonymous:r});return await bp(s),s}static async _fromGetAccountInfoResponse(e,n,r){const i=n.users[0];Be(i.localId!==void 0,"internal-error");const s=i.providerUserInfo!==void 0?cI(i.providerUserInfo):[],o=!(i.email&&i.passwordHash)&&!(s!=null&&s.length),a=new Wl;a.updateFromIdToken(r);const l=new ms({uid:i.localId,auth:e,stsTokenManager:a,isAnonymous:o}),u={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 Ry(i.createdAt,i.lastLoginAt),isAnonymous:!(i.email&&i.passwordHash)&&!(s!=null&&s.length)};return Object.assign(l,u),l}}/** 699 * @license 700 * Copyright 2020 Google LLC 701 * 702 * Licensed under the Apache License, Version 2.0 (the "License"); 703 * you may not use this file except in compliance with the License. 704 * You may obtain a copy of the License at 705 * 706 * http://www.apache.org/licenses/LICENSE-2.0 707 * 708 * Unless required by applicable law or agreed to in writing, software 709 * distributed under the License is distributed on an "AS IS" BASIS, 710 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 711 * See the License for the specific language governing permissions and 712 * limitations under the License. 713 */const ix=new Map;function gs(t){Cs(t instanceof Function,"Expected a class definition");let e=ix.get(t);return e?(Cs(e instanceof t,"Instance stored in cache mismatched with class"),e):(e=new t,ix.set(t,e),e)}/** 714 * @license 715 * Copyright 2019 Google LLC 716 * 717 * Licensed under the Apache License, Version 2.0 (the "License"); 718 * you may not use this file except in compliance with the License. 719 * You may obtain a copy of the License at 720 * 721 * http://www.apache.org/licenses/LICENSE-2.0 722 * 723 * Unless required by applicable law or agreed to in writing, software 724 * distributed under the License is distributed on an "AS IS" BASIS, 725 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 726 * See the License for the specific language governing permissions and 727 * limitations under the License. 728 */class fI{constructor(){this.type="NONE",this.storage={}}async _isAvailable(){return!0}async _set(e,n){this.storage[e]=n}async _get(e){const n=this.storage[e];return n===void 0?null:n}async _remove(e){delete this.storage[e]}_addListener(e,n){}_removeListener(e,n){}}fI.type="NONE";const sx=fI;/** 729 * @license 730 * Copyright 2019 Google LLC 731 * 732 * Licensed under the Apache License, Version 2.0 (the "License");
733 * you may not use this file except in compliance with the License. 734 * You may obtain a copy of the License at 735 * 736 * http://www.apache.org/licenses/LICENSE-2.0 737 * 738 * Unless required by applicable law or agreed to in writing, software 739 * distributed under the License is distributed on an "AS IS" BASIS, 740 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 741 * See the License for the specific language governing permissions and 742 * limitations under the License. 743 */function Ih(t,e,n){return`firebase:${t}:${e}:${n}`}class Gl{constructor(e,n,r){this.persistence=e,this.auth=n,this.userKey=r;const{config:i,name:s}=this.auth;this.fullUserKey=Ih(this.userKey,i.apiKey,s),this.fullPersistenceKey=Ih("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(){const e=await this.persistence._get(this.fullUserKey);return e?ms._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;const 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 Gl(gs(sx),e,r);const i=(await Promise.all(n.map(async u=>{if(await u._isAvailable())return u}))).filter(u=>u);let s=i[0]||gs(sx);const o=Ih(r,e.config.apiKey,e.name);let a=null;for(const u of n)try{const c=await u._get(o);if(c){const d=ms._fromJSON(e,c);u!==s&&(a=d),s=u;break}}catch{}const l=i.filter(u=>u._shouldAllowMigration);return!s._shouldAllowMigration||!l.length?new Gl(s,e,r):(s=l[0],a&&await s._set(o,a.toJSON()),await Promise.all(n.map(async u=>{if(u!==s)try{await u._remove(o)}catch{}})),new Gl(s,e,r))}}/** 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 */function ox(t){const e=t.toLowerCase();if(e.includes("opera/")||e.includes("opr/")||e.includes("opios/"))return"Opera";if(mI(e))return"IEMobile";if(e.includes("msie")||e.includes("trident/"))return"IE";if(e.includes("edge/"))return"Edge";if(dI(e))return"Firefox";if(e.includes("silk/"))return"Silk";if(vI(e))return"Blackberry";if(yI(e))return"Webos";if(hI(e))return"Safari";if((e.includes("chrome/")||pI(e))&&!e.includes("edge/"))return"Chrome";if(gI(e))return"Android";{const n=/([a-zA-Z\d\.]+)\/[a-zA-Z\d\.]*$/,r=t.match(n);if((r==null?void 0:r.length)===2)return r[1]}return"Other"}function dI(t=Vn()){return/firefox\//i.test(t)}function hI(t=Vn()){const e=t.toLowerCase();return e.includes("safari/")&&!e.includes("chrome/")&&!e.includes("crios/")&&!e.includes("android")}function pI(t=Vn()){return/crios\//i.test(t)}function mI(t=Vn()){return/iemobile/i.test(t)}function gI(t=Vn()){return/android/i.test(t)}function vI(t=Vn()){return/blackberry/i.test(t)}function yI(t=Vn()){return/webos/i.test(t)}function Q_(t=Vn()){return/iphone|ipad|ipod/i.test(t)||/macintosh/i.test(t)&&/mobile/i.test(t)}function O6(t=Vn()){var e;return Q_(t)&&!!(!((e=window.navigator)===null||e===void 0)&&e.standalone)}function P6(){return HL()&&document.documentMode===10}function _I(t=Vn()){return Q_(t)||gI(t)||yI(t)||vI(t)||/windows phone/i.test(t)||mI(t)}/** 759 * @license 760 * Copyright 2020 Google LLC 761 * 762 * Licensed under the Apache License, Version 2.0 (the "License");
763 * you may not use this file except in compliance with the License. 764 * You may obtain a copy of the License at 765 * 766 * http://www.apache.org/licenses/LICENSE-2.0 767 * 768 * Unless required by applicable law or agreed to in writing, software 769 * distributed under the License is distributed on an "AS IS" BASIS, 770 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 771 * See the License for the specific language governing permissions and 772 * limitations under the License. 773 */function wI(t,e=[]){let n;switch(t){case"Browser":n=ox(Vn());break;case"Worker":n=`${ox(Vn())}-${t}`;break;default:n=t}const r=e.length?e.join(","):"FirebaseCore-web";return`${n}/JsCore/${al}/${r}`}/** 774 * @license 775 * Copyright 2022 Google LLC 776 * 777 * Licensed under the Apache License, Version 2.0 (the "License"); 778 * you may not use this file except in compliance with the License. 779 * You may obtain a copy of the License at 780 * 781 * http://www.apache.org/licenses/LICENSE-2.0 782 * 783 * Unless required by applicable law or agreed to in writing, software 784 * distributed under the License is distributed on an "AS IS" BASIS, 785 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 786 * See the License for the specific language governing permissions and 787 * limitations under the License. 788 */class R6{constructor(e){this.auth=e,this.queue=[]}pushCallback(e,n){const r=s=>new Promise((o,a)=>{try{const l=e(s);o(l)}catch(l){a(l)}});r.onAbort=n,this.queue.push(r);const i=this.queue.length-1;return()=>{this.queue[i]=()=>Promise.resolve()}}async runMiddleware(e){if(this.auth.currentUser===e)return;const n=[];try{for(const r of this.queue)await r(e),r.onAbort&&n.push(r.onAbort)}catch(r){n.reverse();for(const i of n)try{i()}catch{}throw this.auth._errorFactory.create("login-blocked",{originalMessage:r==null?void 0:r.message})}}}/** 789 * @license 790 * Copyright 2023 Google LLC 791 * 792 * Licensed under the Apache License, Version 2.0 (the "License"); 793 * you may not use this file except in compliance with the License. 794 * You may obtain a copy of the License at 795 * 796 * http://www.apache.org/licenses/LICENSE-2.0 797 * 798 * Unless required by applicable law or agreed to in writing, software 799 * distributed under the License is distributed on an "AS IS" BASIS, 800 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 801 * See the License for the specific language governing permissions and 802 * limitations under the License. 803 */async function C6(t,e={}){return Mu(t,"GET","/v2/passwordPolicy",K_(t,e))}/** 804 * @license 805 * Copyright 2023 Google LLC 806 * 807 * Licensed under the Apache License, Version 2.0 (the "License"); 808 * you may not use this file except in compliance with the License. 809 * You may obtain a copy of the License at 810 * 811 * http://www.apache.org/licenses/LICENSE-2.0 812 * 813 * Unless required by applicable law or agreed to in writing, software 814 * distributed under the License is distributed on an "AS IS" BASIS, 815 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 816 * See the License for the specific language governing permissions and 817 * limitations under the License. 818 */const N6=6;class D6{constructor(e){var n,r,i,s;const o=e.customStrengthOptions;this.customStrengthOptions={},this.customStrengthOptions.minPasswordLength=(n=o.minPasswordLength)!==null&&n!==void 0?n:N6,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 n,r,i,s,o,a;const l={isValid:!0,passwordPolicy:this};return this.validatePasswordLengthOptions(e,l),this.validatePasswordCharacterOptions(e,l),l.isValid&&
818(l.isValid=(n=l.meetsMinPasswordLength)!==null&&n!==void 0?n:!0),l.isValid&&(l.isValid=(r=l.meetsMaxPasswordLength)!==null&&r!==void 0?r:!0),l.isValid&&(l.isValid=(i=l.containsLowercaseLetter)!==null&&i!==void 0?i:!0),l.isValid&&(l.isValid=(s=l.containsUppercaseLetter)!==null&&s!==void 0?s:!0),l.isValid&&(l.isValid=(o=l.containsNumericCharacter)!==null&&o!==void 0?o:!0),l.isValid&&(l.isValid=(a=l.containsNonAlphanumericCharacter)!==null&&a!==void 0?a:!0),l}validatePasswordLengthOptions(e,n){const 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))}}/** 819 * @license 820 * Copyright 2020 Google LLC 821 * 822 * Licensed under the Apache License, Version 2.0 (the "License"); 823 * you may not use this file except in compliance with the License. 824 * You may obtain a copy of the License at 825 * 826 * http://www.apache.org/licenses/LICENSE-2.0 827 * 828 * Unless required by applicable law or agreed to in writing, software 829 * distributed under the License is distributed on an "AS IS" BASIS, 830 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 831 * See the License for the specific language governing permissions and 832 * limitations under the License. 833 */class M6{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 ax(this),this.idTokenSubscription=new ax(this),this.beforeStateQueue=new R6(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=sI,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,n){return n&&(this._popupRedirectResolver=gs(n)),this._initializationPromise=this.queue(async()=>{var r,i;if(!this._deleted&&(this.persistenceManager=await Gl.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(n),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;const 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{const n=await uI(this,{idToken:e}),r=await ms._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){var n;if(hs(this.app)){const o=this.app.settings.authIdToken;return o?new Promise(a=>{setTimeout(()=>this.initializeCurrentUserFromIdToken(o).then(a,a))}):this.directlySetCurrentUser(null)}const r=await this.assertedPersistence.getCurrentUser();let i=r,s=!1;if(e&&this.config.authDomain){await this.getOrInitRedirectPersistenceManager();const o=(n=this.redirectUser)===null||n===void 0?void 0:n._redirectEventId,a=i==null?void 0:i._redirectEventId,l=await this.tryRedirectSignIn(e);(!o||o===a)&&(l!=null&&l.user)&&(i=l.user,s=!0)}if(!i)return this.directlySetCurrentUser(null);
833if(!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 Be(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 n=null;try{n=await this._popupRedirectResolver._completeRedirectFn(this,e,!0)}catch{await this._setRedirectUser(null)}return n}async reloadAndSetCurrentUserOrClear(e){try{await bp(e)}catch(n){if((n==null?void 0:n.code)!=="auth/network-request-failed")return this.directlySetCurrentUser(null)}return this.directlySetCurrentUser(e)}useDeviceLanguage(){this.languageCode=g6()}async _delete(){this._deleted=!0}async updateCurrentUser(e){if(hs(this.app))return Promise.reject(Fa(this));const n=e?Ot(e):null;return n&&Be(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&&Be(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 hs(this.app)?Promise.reject(Fa(this)):(await this.beforeStateQueue.runMiddleware(null),(this.redirectPersistenceManager||this._popupRedirectResolver)&&await this._setRedirectUser(null),this._updateCurrentUser(null,!0))}setPersistence(e){return hs(this.app)?Promise.reject(Fa(this)):this.queue(async()=>{await this.assertedPersistence.setPersistence(gs(e))})}_getRecaptchaConfig(){return this.tenantId==null?this._agentRecaptchaConfig:this._tenantRecaptchaConfigs[this.tenantId]}async validatePassword(e){this._getPasswordPolicyInternal()||await this._updatePasswordPolicy();const 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(){const e=await C6(this),n=new D6(e);this.tenantId===null?this._projectPasswordPolicy=n:this._tenantPasswordPolicies[this.tenantId]=n}_getPersistence(){return this.assertedPersistence.persistence.type}_updateErrorMap(e){this._errorFactory=new ol("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{const r=this.onAuthStateChanged(()=>{r(),e()},n)}})}async revokeAccessToken(e){if(this.currentUser){const n=await this.currentUser.getIdToken(),r={providerId:"apple.com",tokenType:"ACCESS_TOKEN",token:e,idToken:n};this.tenantId!=null&&(r.tenantId=this.tenantId),await I6(this,r)}}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,n){const r=await this.getOrInitRedirectPersistenceManager(n);return e===null?r.removeCurrentUser():r.setCurrentUser(e)}async getOrInitRedirectPersistenceManager(e){if(!this.redirectPersistenceManager){const n=e&&gs(e)||this._popupRedirectResolver;Be(n,this,"argument-error"),this.redirectPersistenceManager=await Gl.create(this,[gs(n._redirectPersistence)],"redirectUser"),this.redirectUser=await this.redirectPersistenceManager.getCurrentUser()}return this.redirectPersistenceManager}async _redirectUserForId(e){var n,r;return this._isInitialized&&await this.queue(async()=>{}),((n=this._currentUser)===null||n===void 0?void 0:n._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,n;if(!this._isInitialized)return;this.idTokenSubscription.next(this.currentUser);const r=(n=(e=this.currentUser)===null||e===void 0?void 0:e.uid)!==null&&n!==void 0?n:null;this.lastNotifiedUid!==r&&(this.lastNotifiedUid=r,this.authStateSubscription.next(this.currentUser))}registerStateListener(e,n,r,i){if(this._deleted)return()=>{};const s=typeof n=="function"?n:n.next.bind(n);let o=!1;const a=this._isInitialized?Promise.resolve():this._initializationPromise;if(Be(a,this,"internal-error"),a.then(()=>{o||s(this.currentUser)}),typeof n=="function"){const l=e.addObserver(n,r,i);return()=>{o=!0,l()}}else{const l=e.addObserver(n);return()=>{o=!0,l()}}}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 Be(this.persistenceManager,this,"internal-error"),this.persistenceManager}_logFramework(e){!e||this.frameworks.includes(e)||(this.frameworks.push(e),this.frameworks.sort(),this.clientVersion=wI(this.config.clientPlatform,this._getFrameworks()))}_getFrameworks(){return this.frameworks}async _getAdditionalHeaders(){var e;const n={"X-Client-Version":this.clientVersion};this.app.options.appId&&(n["X-Firebase-gmpid"]=this.app.options.appId);const r=await((e=this.heartbeatServiceProvider.getImmediate({optional:!0}))===null||e===void 0?void 0:e.getHeartbeatsHeader());r&&(n["X-Firebase-Client"]=r);const i=await this._getAppCheckToken();return i&&(n["X-Firebase-AppCheck"]=i),n}async _getAppCheckToken(){var e;const n=await((e=this.appCheckServiceProvider.getImmediate({optional:!0}))===null||e===void 0?void 0:e.getToken());return n!=null&&n.error&&d6(`Error while retrieving App Check token: ${n.error}`),n==null?void 0:n.token}}function Am(t){return Ot(t)}class ax{constructor(e){this.auth=e,this.observer=null,this.addObserver=XL(n=>this.observer=n)}get next(){return Be(this.observer,this.auth,"internal-error"),this.observer.next.bind(this.observer)}}/** 834 * @license 835 * Copyright 2020 Google LLC 836 * 837 * Licensed under the Apache License, Version 2.0 (the "License");
838 * you may not use this file except in compliance with the License. 839 * You may obtain a copy of the License at 840 * 841 * http://www.apache.org/licenses/LICENSE-2.0 842 * 843 * Unless required by applicable law or agreed to in writing, software 844 * distributed under the License is distributed on an "AS IS" BASIS, 845 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 846 * See the License for the specific language governing permissions and 847 * limitations under the License. 848 */let Z_={async loadJS(){throw new Error("Unable to load external scripts")},recaptchaV2Script:"",recaptchaEnterpriseScript:"",gapiScript:""};function L6(t){Z_=t}function j6(t){return Z_.loadJS(t)}function F6(){return Z_.gapiScript}function V6(t){return`__${t}${Math.floor(Math.random()*1e6)}`}/** 849 * @license 850 * Copyright 2020 Google LLC 851 * 852 * Licensed under the Apache License, Version 2.0 (the "License"); 853 * you may not use this file except in compliance with the License. 854 * You may obtain a copy of the License at 855 * 856 * http://www.apache.org/licenses/LICENSE-2.0 857 * 858 * Unless required by applicable law or agreed to in writing, software 859 * distributed under the License is distributed on an "AS IS" BASIS, 860 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 861 * See the License for the specific language governing permissions and 862 * limitations under the License. 863 */function U6(t,e){const n=Jo(t,"auth");if(n.isInitialized()){const i=n.getImmediate(),s=n.getOptions();if(bf(s,e??{}))return i;Fi(i,"already-initialized")}return n.initialize({options:e})}function $6(t,e){const n=(e==null?void 0:e.persistence)||[],r=(Array.isArray(n)?n:[n]).map(gs);e!=null&&e.errorMap&&t._updateErrorMap(e.errorMap),t._initializeWithPersistence(r,e==null?void 0:e.popupRedirectResolver)}function B6(t,e,n){const r=Am(t);Be(r._canInitEmulator,r,"emulator-config-failed"),Be(/^https?:\/\//.test(e),r,"invali
863d-emulator-scheme");const i=!1,s=bI(e),{host:o,port:a}=z6(e),l=a===null?"":`:${a}`;r.config.emulator={url:`${s}//${o}${l}/`},r.settings.appVerificationDisabledForTesting=!0,r.emulatorConfig=Object.freeze({host:o,port:a,protocol:s.replace(":",""),options:Object.freeze({disableWarnings:i})}),q6()}function bI(t){const e=t.indexOf(":");return e<0?"":t.substr(0,e+1)}function z6(t){const e=bI(t),n=/(\/\/)?([^?#/]+)/.exec(t.substr(e.length));if(!n)return{host:"",port:null};const r=n[2].split("@").pop()||"",i=/^(\[[^\]]+\])(:|$)/.exec(r);if(i){const s=i[1];return{host:s,port:lx(r.substr(s.length+1))}}else{const[s,o]=r.split(":");return{host:s,port:lx(o)}}}function lx(t){if(!t)return null;const e=Number(t);return isNaN(e)?null:e}function q6(){function t(){const 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())}/** 864 * @license 865 * Copyright 2020 Google LLC 866 * 867 * Licensed under the Apache License, Version 2.0 (the "License"); 868 * you may not use this file except in compliance with the License. 869 * You may obtain a copy of the License at 870 * 871 * http://www.apache.org/licenses/LICENSE-2.0 872 * 873 * Unless required by applicable law or agreed to in writing, software 874 * distributed under the License is distributed on an "AS IS" BASIS, 875 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 876 * See the License for the specific language governing permissions and 877 * limitations under the License. 878 */class EI{constructor(e,n){this.providerId=e,this.signInMethod=n}toJSON(){return ps("not implemented")}_getIdTokenResponse(e){return ps("not implemented")}_linkToIdToken(e,n){return ps("not implemented")}_getReauthenticationResolver(e){return ps("not implemented")}}/** 879 * @license 880 * Copyright 2020 Google LLC 881 * 882 * Licensed under the Apache License, Version 2.0 (the "License"); 883 * you may not use this file except in compliance with the License. 884 * You may obtain a copy of the License at 885 * 886 * http://www.apache.org/licenses/LICENSE-2.0 887 * 888 * Unless required by applicable law or agreed to in writing, software 889 * distributed under the License is distributed on an "AS IS" BASIS, 890 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 891 * See the License for the specific language governing permissions and 892 * limitations under the License. 893 */async function Kl(t,e){return _6(t,"POST","/v1/accounts:signInWithIdp",K_(t,e))}/** 894 * @license 895 * Copyright 2020 Google LLC 896 * 897 * Licensed under the Apache License, Version 2.0 (the "License"); 898 * you may not use this file except in compliance with the License. 899 * You may obtain a copy of the License at 900 * 901 * http://www.apache.org/licenses/LICENSE-2.0 902 * 903 * Unless required by applicable law or agreed to in writing, software 904 * distributed under the License is distributed on an "AS IS" BASIS, 905 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 906 * See the License for the specific language governing permissions and 907 * limitations under the License. 908 */const H6="http://localhost";class Za extends EI{constructor(){super(...arguments),this.pendingToken=null}static _fromParams(e){const n=new Za(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):Fi("argument-error"),n}toJSON(){return{idToken:this.idToken,accessToken:this.accessToken,secret:this.secret,n
908once:this.nonce,pendingToken:this.pendingToken,providerId:this.providerId,signInMethod:this.signInMethod}}static fromJSON(e){const n=typeof e=="string"?JSON.parse(e):e,{providerId:r,signInMethod:i}=n,s=q_(n,["providerId","signInMethod"]);if(!r||!i)return null;const o=new Za(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){const n=this.buildRequest();return Kl(e,n)}_linkToIdToken(e,n){const r=this.buildRequest();return r.idToken=n,Kl(e,r)}_getReauthenticationResolver(e){const n=this.buildRequest();return n.autoCreate=!1,Kl(e,n)}buildRequest(){const e={requestUri:H6,returnSecureToken:!0};if(this.pendingToken)e.pendingToken=this.pendingToken;else{const 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=ed(n)}return e}}/** 909 * @license 910 * Copyright 2020 Google LLC 911 * 912 * Licensed under the Apache License, Version 2.0 (the "License"); 913 * you may not use this file except in compliance with the License. 914 * You may obtain a copy of the License at 915 * 916 * http://www.apache.org/licenses/LICENSE-2.0 917 * 918 * Unless required by applicable law or agreed to in writing, software 919 * distributed under the License is distributed on an "AS IS" BASIS, 920 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 921 * See the License for the specific language governing permissions and 922 * limitations under the License. 923 */class X_{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}}/** 924 * @license 925 * Copyright 2019 Google LLC 926 * 927 * Licensed under the Apache License, Version 2.0 (the "License"); 928 * you may not use this file except in compliance with the License. 929 * You may obtain a copy of the License at 930 * 931 * http://www.apache.org/licenses/LICENSE-2.0 932 * 933 * Unless required by applicable law or agreed to in writing, software 934 * distributed under the License is distributed on an "AS IS" BASIS, 935 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 936 * See the License for the specific language governing permissions and 937 * limitations under the License. 938 */class nd extends X_{constructor(){super(...arguments),this.scopes=[]}addScope(e){return this.scopes.includes(e)||this.scopes.push(e),this}getScopes(){return[...this.scopes]}}/** 939 * @license 940 * Copyright 2020 Google LLC 941 * 942 * Licensed under the Apache License, Version 2.0 (the "License"); 943 * you may not use this file except in compliance with the License. 944 * You may obtain a copy of the License at 945 * 946 * http://www.apache.org/licenses/LICENSE-2.0 947 * 948 * Unless required by applicable law or agreed to in writing, software 949 * distributed under the License is distributed on an "AS IS" BASIS, 950 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 951 * See the License for the specific language governing permissions and 952 * limitations under the License. 953 */class oo extends nd{constructor(){super("facebook.com")}static credential(e){return Za._fromParams({providerId:oo.PROVIDER_ID,signInMethod:oo.FACEBOOK_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return oo.credentialFromTaggedObject(e)}static credentialFromError(e){return oo.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return oo.credential(e.oauthAccessToken)}catch{return null}}}oo.FACEBOOK_SIGN_IN_METHOD="facebook.com";oo.PROVIDER_ID="facebook.com";/** 954 * @license 955 * Copyright 2020 Google LLC 956 * 957 * Licensed under the Apache License, Version 2.0 (the "License"); 958 * you may not use this file except in compliance with the License. 959 * You may obtain a copy of the License at 960 * 961 * http://www.apache.org/licenses/LICENSE-2.0 962 * 963 * Unless required by applicable law or agreed to in writing, softw
963are 964 * distributed under the License is distributed on an "AS IS" BASIS, 965 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 966 * See the License for the specific language governing permissions and 967 * limitations under the License. 968 */class cs extends nd{constructor(){super("google.com"),this.addScope("profile")}static credential(e,n){return Za._fromParams({providerId:cs.PROVIDER_ID,signInMethod:cs.GOOGLE_SIGN_IN_METHOD,idToken:e,accessToken:n})}static credentialFromResult(e){return cs.credentialFromTaggedObject(e)}static credentialFromError(e){return cs.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;const{oauthIdToken:n,oauthAccessToken:r}=e;if(!n&&!r)return null;try{return cs.credential(n,r)}catch{return null}}}cs.GOOGLE_SIGN_IN_METHOD="google.com";cs.PROVIDER_ID="google.com";/** 969 * @license 970 * Copyright 2020 Google LLC 971 * 972 * Licensed under the Apache License, Version 2.0 (the "License"); 973 * you may not use this file except in compliance with the License. 974 * You may obtain a copy of the License at 975 * 976 * http://www.apache.org/licenses/LICENSE-2.0 977 * 978 * Unless required by applicable law or agreed to in writing, software 979 * distributed under the License is distributed on an "AS IS" BASIS, 980 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 981 * See the License for the specific language governing permissions and 982 * limitations under the License. 983 */class ao extends nd{constructor(){super("github.com")}static credential(e){return Za._fromParams({providerId:ao.PROVIDER_ID,signInMethod:ao.GITHUB_SIGN_IN_METHOD,accessToken:e})}static credentialFromResult(e){return ao.credentialFromTaggedObject(e)}static credentialFromError(e){return ao.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e||!("oauthAccessToken"in e)||!e.oauthAccessToken)return null;try{return ao.credential(e.oauthAccessToken)}catch{return null}}}ao.GITHUB_SIGN_IN_METHOD="github.com";ao.PROVIDER_ID="github.com";/** 984 * @license 985 * Copyright 2020 Google LLC 986 * 987 * Licensed under the Apache License, Version 2.0 (the "License"); 988 * you may not use this file except in compliance with the License. 989 * You may obtain a copy of the License at 990 * 991 * http://www.apache.org/licenses/LICENSE-2.0 992 * 993 * Unless required by applicable law or agreed to in writing, software 994 * distributed under the License is distributed on an "AS IS" BASIS, 995 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 996 * See the License for the specific language governing permissions and 997 * limitations under the License. 998 */class lo extends nd{constructor(){super("twitter.com")}static credential(e,n){return Za._fromParams({providerId:lo.PROVIDER_ID,signInMethod:lo.TWITTER_SIGN_IN_METHOD,oauthToken:e,oauthTokenSecret:n})}static credentialFromResult(e){return lo.credentialFromTaggedObject(e)}static credentialFromError(e){return lo.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;const{oauthAccessToken:n,oauthTokenSecret:r}=e;if(!n||!r)return null;try{return lo.credential(n,r)}catch{return null}}}lo.TWITTER_SIGN_IN_METHOD="twitter.com";lo.PROVIDER_ID="twitter.com";/** 999 * @license 1000 * Copyright 2020 Google LLC 1001 * 1002 * Licensed under the Apache License, Version 2.0 (the "License"); 1003 * you may not use this file except in compliance with the License. 1004 * You may obtain a copy of the License at 1005 * 1006 * http://www.apache.org/licenses/LICENSE-2.0 1007 * 1008 * Unless required by applicable law or agreed to in writing, software 1009 * distributed under the License is distributed on an "AS IS" BASIS, 1010 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1011 * See the License for the specific language governing permissions and 1012 * limitations under the License. 1013 */class wu{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){const s=await ms._fromIdTokenResponse(e,r,i),o=ux(r);return new wu({user:s,providerId:o,_tokenResponse:r,operationType:n})}static async _forOperation(e,n,r){await e._updateTokensIfNecessary(r,!0);const i=ux(r);return new wu({user:e,providerId:i,_tokenResponse:r,operationType:n})}}function ux(t){return t.providerId?t.providerId:"phoneNumber"in t?"phone":null}/** 1014 * @license 1015 * Copyright 2020 Google LLC 1016 * 1017 * Licensed under the Apache License, Version 2.0 (the "License");
1018 * you may not use this file except in compliance with the License. 1019 * You may obtain a copy of the License at 1020 * 1021 * http://www.apache.org/licenses/LICENSE-2.0 1022 * 1023 * Unless required by applicable law or agreed to in writing, software 1024 * distributed under the License is distributed on an "AS IS" BASIS, 1025 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1026 * See the License for the specific language governing permissions and 1027 * limitations under the License. 1028 */class Ep extends qr{constructor(e,n,r,i){var s;super(n.code,n.message),this.operationType=r,this.user=i,Object.setPrototypeOf(this,Ep.prototype),this.customData={appName:e.name,tenantId:(s=e.tenantId)!==null&&s!==void 0?s:void 0,_serverResponse:n.customData._serverResponse,operationType:r}}static _fromErrorAndOperation(e,n,r,i){return new Ep(e,n,r,i)}}function xI(t,e,n,r){return(e==="reauthenticate"?n._getReauthenticationResolver(t):n._getIdTokenResponse(t)).catch(s=>{throw s.code==="auth/multi-factor-auth-required"?Ep._fromErrorAndOperation(t,s,e,r):s})}async function W6(t,e,n=!1){const r=await xf(t,e._linkToIdToken(t.auth,await t.getIdToken()),n);return wu._forOperation(t,"link",r)}/** 1029 * @license 1030 * Copyright 2019 Google LLC 1031 * 1032 * Licensed under the Apache License, Version 2.0 (the "License"); 1033 * you may not use this file except in compliance with the License. 1034 * You may obtain a copy of the License at 1035 * 1036 * http://www.apache.org/licenses/LICENSE-2.0 1037 * 1038 * Unless required by applicable law or agreed to in writing, software 1039 * distributed under the License is distributed on an "AS IS" BASIS, 1040 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1041 * See the License for the specific language governing permissions and 1042 * limitations under the License. 1043 */async function G6(t,e,n=!1){const{auth:r}=t;if(hs(r.app))return Promise.reject(Fa(r));const i="reauthenticate";try{const s=await xf(t,xI(r,i,e,t),n);Be(s.idToken,r,"internal-error");const o=Y_(s.idToken);Be(o,r,"internal-error");const{sub:a}=o;return Be(t.uid===a,r,"user-mismatch"),wu._forOperation(t,i,s)}catch(s){throw(s==null?void 0:s.code)==="auth/user-not-found"&&Fi(r,"user-mismatch"),s}}/** 1044 * @license 1045 * Copyright 2020 Google LLC 1046 * 1047 * Licensed under the Apache License, Version 2.0 (the "License"); 1048 * you may not use this file except in compliance with the License. 1049 * You may obtain a copy of the License at 1050 * 1051 * http://www.apache.org/licenses/LICENSE-2.0 1052 * 1053 * Unless required by applicable law or agreed to in writing, software 1054 * distributed under the License is distributed on an "AS IS" BASIS, 1055 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1056 * See the License for the specific language governing permissions and 1057 * limitations under the License. 1058 */async function K6(t,e,n=!1){if(hs(t.app))return Promise.reject(Fa(t));const r="signIn",i=await xI(t,r,e),s=await wu._fromIdTokenResponse(t,r,i);return n||await t._updateCurrentUser(s.user),s}function Y6(t,e,n,r){return Ot(t).onIdTokenChanged(e,n,r)}function Q6(t,e,n){return Ot(t).beforeAuthStateChanged(e,n)}function Z6(t,e,n,r){return Ot(t).onAuthStateChanged(e,n,r)}function X6(t){return Ot(t).signOut()}const xp="__sak";/** 1059 * @license 1060 * Copyright 2019 Google LLC 1061 * 1062 * Licensed under the Apache License, Version 2.0 (the "License"); 1063 * you may not use this file except in compliance with the License. 1064 * You may obtain a copy of the License at 1065 * 1066 * http://www.apache.org/licenses/LICENSE-2.0 1067 * 1068 * Unless required by applicable law or agreed to in writing, software 1069 * distributed under the License is distributed on an "AS IS" BASIS, 1070 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1071 * See the License for the specific language governing permissions and 1072 * limitations under the License. 1073 */class TI{constructor(e,n){this.storageRetriever=e,this.type=n}_isAvailable(){try{return this.storage?(this.storage.setItem(xp,"1"),this.storage.removeItem(xp),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){const 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()}}/** 1074 * @license 1075 * Copyright 2020 Google LLC 1076 * 1077 * Licensed under the Apache License, Version 2.0 (the "License");
1078 * you may not use this file except in compliance with the License. 1079 * You may obtain a copy of the License at 1080 * 1081 * http://www.apache.org/licenses/LICENSE-2.0 1082 * 1083 * Unless required by applicable law or agreed to in writing, software 1084 * distributed under the License is distributed on an "AS IS" BASIS, 1085 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1086 * See the License for the specific language governing permissions and 1087 * limitations under the License. 1088 */const J6=1e3,e3=10;class SI extends TI{constructor(){super(()=>window.localStorage,"LOCAL"),this.boundEventHandler=(e,n)=>this.onStorageEvent(e,n),this.listeners={},this.localCache={},this.pollTimer=null,this.fallbackToPolling=_I(),this._shouldAllowMigration=!0}forAllChangedKeys(e){for(const n of Object.keys(this.listeners)){const 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,l)=>{this.notifyListeners(o,l)});return}const r=e.key;n?this.detachListener():this.stopPolling();const i=()=>{const o=this.storage.getItem(r);!n&&this.localCache[r]===o||this.notifyListeners(r,o)},s=this.storage.getItem(r);P6()&&s!==e.newValue&&e.newValue!==e.oldValue?setTimeout(i,e3):i()}notifyListeners(e,n){this.localCache[e]=n;const r=this.listeners[e];if(r)for(const 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)})},J6)}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]),Ob
1088ject.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){const n=await super._get(e);return this.localCache[e]=JSON.stringify(n),n}async _remove(e){await super._remove(e),delete this.localCache[e]}}SI.type="LOCAL";const t3=SI;/** 1089 * @license 1090 * Copyright 2020 Google LLC 1091 * 1092 * Licensed under the Apache License, Version 2.0 (the "License"); 1093 * you may not use this file except in compliance with the License. 1094 * You may obtain a copy of the License at 1095 * 1096 * http://www.apache.org/licenses/LICENSE-2.0 1097 * 1098 * Unless required by applicable law or agreed to in writing, software 1099 * distributed under the License is distributed on an "AS IS" BASIS, 1100 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1101 * See the License for the specific language governing permissions and 1102 * limitations under the License. 1103 */class kI extends TI{constructor(){super(()=>window.sessionStorage,"SESSION")}_addListener(e,n){}_removeListener(e,n){}}kI.type="SESSION";const AI=kI;/** 1104 * @license 1105 * Copyright 2019 Google LLC 1106 * 1107 * Licensed under the Apache License, Version 2.0 (the "License"); 1108 * you may not use this file except in compliance with the License. 1109 * You may obtain a copy of the License at 1110 * 1111 * http://www.apache.org/licenses/LICENSE-2.0 1112 * 1113 * Unless required by applicable law or agreed to in writing, software 1114 * distributed under the License is distributed on an "AS IS" BASIS, 1115 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1116 * See the License for the specific language governing permissions and 1117 * limitations under the License. 1118 */function n3(t){return Promise.all(t.map(async e=>{try{return{fulfilled:!0,value:await e}}catch(n){return{fulfilled:!1,reason:n}}}))}/** 1119 * @license 1120 * Copyright 2019 Google LLC 1121 * 1122 * Licensed under the Apache License, Version 2.0 (the "License"); 1123 * you may not use this file except in compliance with the License. 1124 * You may obtain a copy of the License at 1125 * 1126 * http://www.apache.org/licenses/LICENSE-2.0 1127 * 1128 * Unless required by applicable law or agreed to in writing, software 1129 * distributed under the License is distributed on an "AS IS" BASIS, 1130 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1131 * See the License for the specific language governing permissions and 1132 * limitations under the License. 1133 */class Im{constructor(e){this.eventTarget=e,this.handlersMap={},this.boundEventHandler=this.handleEvent.bind(this)}static _getInstance(e){const n=this.receivers.find(i=>i.isListeningto(e));if(n)return n;const r=new Im(e);return this.receivers.push(r),r}isListeningto(e){return this.eventTarget===e}async handleEvent(e){const n=e,{eventId:r,eventType:i,data:s}=n.data,o=this.handlersMap[i];if(!(o!=null&&o.size))return;n.ports[0].postMessage({status:"ack",eventId:r,eventType:i});const a=Array.from(o).map(async u=>u(n.origin,s)),l=await n3(a);n.ports[0].postMessage({status:"done",eventId:r,eventType:i,response:l})}_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)}}Im.receivers=[];/** 1134 * @license 1135 * Copyright 2020 Google LLC 1136 * 1137 * Licensed under the Apache License, Version 2.0 (the "License"); 1138 * you may not use this file except in compliance with the License. 1139 * You may obtain a copy of the License at 1140 * 1141 * http://www.apache.org/licenses/LICENSE-2.0 1142 * 1143 * Unless required by applicable law or agreed to in writing, software 1144 * distributed under the License is distributed on an "AS IS" BASIS, 1145 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1146 * See the License for the specific language governing permissions and 1147 * limitations under the License. 1148 */function J_(t="",e=10){let n="";for(let r=0;r<e;r++)n+=Math.floor(Math.random()*10);return t+n}/** 1149 * @license 1150 * Copyright 2019 Google LLC 1151 * 1152 * Licensed under the Apache License, Version 2.0 (the "License");
1153 * you may not use this file except in compliance with the License. 1154 * You may obtain a copy of the License at 1155 * 1156 * http://www.apache.org/licenses/LICENSE-2.0 1157 * 1158 * Unless required by applicable law or agreed to in writing, software 1159 * distributed under the License is distributed on an "AS IS" BASIS, 1160 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1161 * See the License for the specific language governing permissions and 1162 * limitations under the License. 1163 */class r3{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){const i=typeof MessageChannel<"u"?new MessageChannel:null;if(!i)throw new Error("connection_unavailable");let s,o;return new Promise((a,l)=>{const u=J_("",20);i.port1.start();const c=setTimeout(()=>{l(new Error("unsupported_event"))},r);o={messageChannel:i,onMessage(d){const f=d;if(f.data.eventId===u)switch(f.data.status){case"ack":clearTimeout(c),s=setTimeout(()=>{l(new Error("timeout"))},3e3);break;case"done":clearTimeout(s),a(f.data.response);break;default:clearTimeout(c),clearTimeout(s),l(new Error("invalid_response"));break}}},this.handlers.add(o),i.port1.addEventListener("message",o.onMessage),this.target.postMessage({eventType:e,eventId:u,data:n},[i.port2])}).finally(()=>{o&&this.removeMessageHandler(o)})}}/** 1164 * @license 1165 * Copyright 2020 Google LLC 1166 * 1167 * Licensed under the Apache License, Version 2.0 (the "License"); 1168 * you may not use this file except in compliance with the License. 1169 * You may obtain a copy of the License at 1170 * 1171 * http://www.apache.org/licenses/LICENSE-2.0 1172 * 1173 * Unless required by applicable law or agreed to in writing, software 1174 * distributed under the License is distributed on an "AS IS" BASIS, 1175 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1176 * See the License for the specific language governing permissions and 1177 * limitations under the License. 1178 */function Di(){return window}function i3(t){Di().location.href=t}/** 1179 * @license 1180 * Copyright 2020 Google LLC. 1181 * 1182 * Licensed under the Apache License, Version 2.0 (the "License"); 1183 * you may not use this file except in compliance with the License. 1184 * You may obtain a copy of the License at 1185 * 1186 * http://www.apache.org/licenses/LICENSE-2.0 1187 * 1188 * Unless required by applicable law or agreed to in writing, software 1189 * distributed under the License is distributed on an "AS IS" BASIS, 1190 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1191 * See the License for the specific language governing permissions and 1192 * limitations under the License. 1193 */function II(){return typeof Di().WorkerGlobalScope<"u"&&typeof Di().importScripts=="function"}async function s3(){if(!(navigator!=null&&navigator.serviceWorker))return null;try{return(await navigator.serviceWorker.ready).active}catch{return null}}function o3(){var t;return((t=navigator==null?void 0:navigator.serviceWorker)===null||t===void 0?void 0:t.controller)||null}function a3(){return II()?self:null}/** 1194 * @license 1195 * Copyright 2019 Google LLC 1196 * 1197 * Licensed under the Apache License, Version 2.0 (the "License"); 1198 * you may not use this file except in compliance with the License. 1199 * You may obtain a copy of the License at 1200 * 1201 * http://www.apache.org/licenses/LICENSE-2.0 1202 * 1203 * Unless required by applicable law or agreed to in writing, software 1204 * distributed under the License is distributed on an "AS IS" BASIS, 1205 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1206 * See the License for the specific language governing permissions and 1207 * limitations under the License. 1208 */const OI="firebaseLocalStorageDb",l3=1,Tp="firebaseLocalStorage",PI="fbase_key";class rd{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 Om(t,e){return t.transaction([Tp],e?"readwrite":"readonly").objectStore(Tp)}function u3(){const t=indexedDB.deleteDatabase(OI);
1208return new rd(t).toPromise()}function Cy(){const t=indexedDB.open(OI,l3);return new Promise((e,n)=>{t.addEventListener("error",()=>{n(t.error)}),t.addEventListener("upgradeneeded",()=>{const r=t.result;try{r.createObjectStore(Tp,{keyPath:PI})}catch(i){n(i)}}),t.addEventListener("success",async()=>{const r=t.result;r.objectStoreNames.contains(Tp)?e(r):(r.close(),await u3(),e(await Cy()))})})}async function cx(t,e,n){const r=Om(t,!0).put({[PI]:e,value:n});return new rd(r).toPromise()}async function c3(t,e){const n=Om(t,!1).get(e),r=await new rd(n).toPromise();return r===void 0?null:r.value}function fx(t,e){const n=Om(t,!0).delete(e);return new rd(n).toPromise()}const f3=800,d3=3;class RI{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 Cy(),this.db)}async _withRetries(e){let n=0;for(;;)try{const r=await this._openDb();return await e(r)}catch(r){if(n++>d3)throw r;this.db&&(this.db.close(),this.db=void 0)}}async initializeServiceWorkerMessaging(){return II()?this.initializeReceiver():this.initializeSender()}async initializeReceiver(){this.receiver=Im._getInstance(a3()),this.receiver._subscribe("keyChanged",async(e,n)=>({keyProcessed:(await this._poll()).includes(n.key)}
1208)),this.receiver._subscribe("ping",async(e,n)=>["keyChanged"])}async initializeSender(){var e,n;if(this.activeServiceWorker=await s3(),!this.activeServiceWorker)return;this.sender=new r3(this.activeServiceWorker);const r=await this.sender._send("ping",{},800);r&&!((e=r[0])===null||e===void 0)&&e.fulfilled&&!((n=r[0])===null||n===void 0)&&n.value.includes("keyChanged")&&(this.serviceWorkerReceiverAvailable=!0)}async notifyServiceWorker(e){if(!(!this.sender||!this.activeServiceWorker||o3()!==this.activeServiceWorker))try{await this.sender._send("keyChanged",{key:e},this.serviceWorkerReceiverAvailable?800:50)}catch{}}async _isAvailable(){try{if(!indexedDB)return!1;const e=await Cy();return await cx(e,xp,"1"),await fx(e,xp),!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=>cx(r,e,n)),this.localCache[e]=n,this.notifyServiceWorker(e)))}async _get(e){const n=await this._withRetries(r=>c3(r,e));return this.localCache[e]=n,n}async _remove(e){return this._withPendingWrite(async()=>(await this._withRetries(n=>fx(n,e)),delete this.localCache[e],this.notifyServiceWorker(e)))}async _poll(){const e=await this._withRetries(i=>{const s=Om(i,!1).getAll();return new rd(s).toPromise()});if(!e)return[];if(this.pendingWrites!==0)return[];const n=[],r=new Set;if(e.length!==0)for(const{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(const 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;const r=this.listeners[e];if(r)for(const i of Array.from(r))i(n)}startPolling(){this.stopPolling(),this.pollTimer=setInterval(async()=>this._poll(),f3)}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]),Ob
vendor: 4,318 bytes, lines 1208-1257
1208ject.keys(this.listeners).length===0&&this.stopPolling()}}RI.type="LOCAL";const h3=RI;new td(3e4,6e4);/** 1209 * @license 1210 * Copyright 2021 Google LLC 1211 * 1212 * Licensed under the Apache License, Version 2.0 (the "License"); 1213 * you may not use this file except in compliance with the License. 1214 * You may obtain a copy of the License at 1215 * 1216 * http://www.apache.org/licenses/LICENSE-2.0 1217 * 1218 * Unless required by applicable law or agreed to in writing, software 1219 * distributed under the License is distributed on an "AS IS" BASIS, 1220 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1221 * See the License for the specific language governing permissions and 1222 * limitations under the License. 1223 */function CI(t,e){return e?gs(e):(Be(t._popupRedirectResolver,t,"argument-error"),t._popupRedirectResolver)}/** 1224 * @license 1225 * Copyright 2019 Google LLC 1226 * 1227 * Licensed under the Apache License, Version 2.0 (the "License"); 1228 * you may not use this file except in compliance with the License. 1229 * You may obtain a copy of the License at 1230 * 1231 * http://www.apache.org/licenses/LICENSE-2.0 1232 * 1233 * Unless required by applicable law or agreed to in writing, software 1234 * distributed under the License is distributed on an "AS IS" BASIS, 1235 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1236 * See the License for the specific language governing permissions and 1237 * limitations under the License. 1238 */class e1 extends EI{constructor(e){super("custom","custom"),this.params=e}_getIdTokenResponse(e){return Kl(e,this._buildIdpRequest())}_linkToIdToken(e,n){return Kl(e,this._buildIdpRequest(n))}_getReauthenticationResolver(e){return Kl(e,this._buildIdpRequest())}_buildIdpRequest(e){const 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 p3(t){return K6(t.auth,new e1(t),t.bypassAuthState)}function m3(t){const{auth:e,user:n}=t;return Be(n,e,"internal-error"),G6(n,new e1(t),t.bypassAuthState)}async function g3(t){const{auth:e,user:n}=t;return Be(n,e,"internal-error"),W6(n,new e1(t),t.bypassAuthState)}/** 1239 * @license 1240 * Copyright 2020 Google LLC 1241 * 1242 * Licensed under the Apache License, Version 2.0 (the "License"); 1243 * you may not use this file except in compliance with the License. 1244 * You may obtain a copy of the License at 1245 * 1246 * http://www.apache.org/licenses/LICENSE-2.0 1247 * 1248 * Unless required by applicable law or agreed to in writing, software 1249 * distributed under the License is distributed on an "AS IS" BASIS, 1250 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1251 * See the License for the specific language governing permissions and 1252 * limitations under the License. 1253 */class NI{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){const{urlResponse:n,sessionId:r,postBody:i,tenantId:s,error:o,type:a}=e;if(o){this.reject(o);return}const l={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)(l))}catch(u){this.reject(u)}}onError(e){this.reject(e)}getIdpTask(e){switch(e){case"signInViaPopup":case"signInViaRedirect":return p3;case"linkViaPopup":case"linkViaRedirect":return g3;case"reauthViaPopup":case"reauthViaRedirect":return m3;default:Fi(this.auth,"internal-error")}}resolve(e){Cs(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.resolve(e),this.unregisterAndCleanUp()}reject(e){Cs(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()}}/** 1254 * @license 1255 * Copyright 2020 Google LLC 1256 * 1257 * Licensed under the Apache License, Version 2.0 (the "License");
1258 * you may not use this file except in compliance with the License. 1259 * You may obtain a copy of the License at 1260 * 1261 * http://www.apache.org/licenses/LICENSE-2.0 1262 * 1263 * Unless required by applicable law or agreed to in writing, software 1264 * distributed under the License is distributed on an "AS IS" BASIS, 1265 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1266 * See the License for the specific language governing permissions and 1267 * limitations under the License. 1268 */const v3=new td(2e3,1e4);async function y3(t,e,n){if(hs(t.app))return Promise.reject(li(t,"operation-not-supported-in-this-environment"));const r=Am(t);h6(t,e,X_);const i=CI(r,n);return new ba(r,"signInViaPopup",e,i).executeNotNull()}class ba extends NI{constructor(e,n,r,i,s){super(e,n,i,s),this.provider=r,this.authWindow=null,this.pollId=null,ba.currentPopupAction&&ba.currentPopupAction.cancel(),ba.currentPopupAction=this}async executeNotNull(){const e=await this.execute();return Be(e,this.auth,"internal-error"),e}async onExecution(){Cs(this.filter.length===1,"Popup operations only handle one event");const e=J_();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(li(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(li(this.auth,"cancelled-popup-request"))}cleanUp(){this.authWindow&&this.authWindow.close(),this.pollId&&window.clearTimeout(this.pollId),this.authWindow=null,this.pollId=null,ba.currentPopupAction=null}pollUserCancellation(){const e=()=>{var n,r;if(!((r=(n=this.authWindow)===null||n===void 0?void 0:n.window)===null||r===void 0)&&r.closed){this.pollId=window.setTimeout(()=>{this.pollId=null,this.reject(li(this.auth,"popup-closed-by-user"))},8e3);return}this.pollId=window.setTimeout(e,v3.get())};e()}}ba.currentPopupAction=null;/** 1269 * @license 1270 * Copyright 2020 Google LLC 1271 * 1272 * Licensed under the Apache License, Version 2.0 (the "License"); 1273 * you may not use this file except in compliance with the License. 1274 * You may obtain a copy of the License at 1275 * 1276 * http://www.apache.org/licenses/LICENSE-2.0 1277 * 1278 * Unless required by applicable law or agreed to in writing, software 1279 * distributed under the License is distributed on an "AS IS" BASIS, 1280 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1281 * See the License for the specific language governing permissions and 1282 * limitations under the License. 1283 */const _3="pendingRedirect",Oh=new Map;class w3 extends NI{constructor(e,n,r=!1){super(e,["signInViaRedirect","linkViaRedirect","reauthViaRedirect","unknown"],n,void 0,r),this.eventId=null}async execute(){let e=Oh.get(this.auth._key());if(!e){try{const r=await b3(this.resolver,this.auth)?await super.execute():null;e=()=>Promise.resolve(r)}catch(n){e=()=>Promise.reject(n)}Oh.set(this.auth._key(),e)}return this.bypassAuthState||Oh.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){const n=await this.auth._redirectUserForId(e.eventId);if(n)return this.user=n,super.onAuthEvent(e);this.resolve(null)}}async onExecution(){}cleanUp(){}}async function b3(t,e){const n=T3(e),r=x3(t);if(!await r._isAvailable())return!1;const i=await r._get(n)==="true";return await r._remove(n),i}function E3(t,e){Oh.set(t._key(),e)}function x3(t){return gs(t._redirectPersistence)}function T3(t){return Ih(_3,t.config.apiKey,t.name)}async function S3(t,e,n=!1){if(hs(t.app))return Promise.reject(Fa(t));const r=Am(t),i=CI(r,e),o=await new w3(r,i,n).execute();return o&&!n&&(delete o.user._redirectEventId,await r._persistUserIfCurrent(o.user),await r._setRedirectUser(null,e)),o}/** 1284 * @license 1285 * Copyright 2020 Google LLC 1286 * 1287 * Licensed under the Apache License, Version 2.0 (the "License");
1288 * you may not use this file except in compliance with the License. 1289 * You may obtain a copy of the License at 1290 * 1291 * http://www.apache.org/licenses/LICENSE-2.0 1292 * 1293 * Unless required by applicable law or agreed to in writing, software 1294 * distributed under the License is distributed on an "AS IS" BASIS, 1295 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1296 * See the License for the specific language governing permissions and 1297 * limitations under the License. 1298 */const k3=10*60*1e3;class A3{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||!I3(e)||(this.hasHandledPotentialRedirect=!0,n||(this.queuedRedirectEvent=e,n=!0)),n}sendToConsumer(e,n){var r;if(e.error&&!DI(e)){const i=((r=e.error.code)===null||r===void 0?void 0:r.split("auth/")[1])||"internal-error";n.onError(li(this.auth,i))}else n.onAuthEvent(e)}isEventForConsumer(e,n){const r=n.eventId===null||!!e.eventId&&e.eventId===n.eventId;return n.filter.includes(e.type)&&r}hasEventBeenHandled(e){return Date.now()-this.lastProcessedEventTime>=k3&&this.cachedEventUids.clear(),this.cachedEventUids.has(dx(e))}saveEventToCache(e){this.cachedEventUids.add(dx(e)),this.lastProcessedEventTime=Date.now()}}function dx(t){return[t.type,t.eventId,t.sessionId,t.tenantId].filter(e=>e).join("-")}function DI({type:t,error:e}){return t==="unknown"&&(e==null?void 0:e.code)==="auth/no-auth-event"}function I3(t){switch(t.type){case"signInViaRedirect":case"linkViaRedirect":case"reauthViaRedirect":return!0;case"unknown":return DI(t);default:return!1}}/** 1299 * @license 1300 * Copyright 2020 Google LLC 1301 * 1302 * Licensed under the Apache License, Version 2.0 (the "License"); 1303 * you may not use this file except in compliance with the License. 1304 * You may obtain a copy of the License at 1305 * 1306 * http://www.apache.org/licenses/LICENSE-2.0 1307 * 1308 * Unless required by applicable law or agreed to in writing, software 1309 * distributed under the License is distributed on an "AS IS" BASIS, 1310 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1311 * See the License for the specific language governing permissions and 1312 * limitations under the License. 1313 */async function O3(t,e={}){return Mu(t,"GET","/v1/projects",e)}/** 1314 * @license 1315 * Copyright 2020 Google LLC 1316 * 1317 * Licensed under the Apache License, Version 2.0 (the "License"); 1318 * you may not use this file except in compliance with the License. 1319 * You may obtain a copy of the License at 1320 * 1321 * http://www.apache.org/licenses/LICENSE-2.0 1322 * 1323 * Unless required by applicable law or agreed to in writing, software 1324 * distributed under the License is distributed on an "AS IS" BASIS, 1325 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1326 * See the License for the specific language governing permissions and 1327 * limitations under the License. 1328 */const P3=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/,R3=/^https?/;async function C3(t){if(t.config.emulator)return;const{authorizedDomains:e}=await O3(t);for(const n of e)try{if(N3(n))return}catch{}Fi(t,"unauthorized-domain")}function N3(t){const e=Py(),{protocol:n,hostname:r}=new URL(e);if(t.startsWith("chrome-extension://")){const 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(!R3.test(n))return!1;if(P3.test(t))return r===t;const i=t.replace(/\./g,"\\.");return new RegExp("^(.+\\."+i+"|"+i+")$","i").test(r)}/** 1329 * @license 1330 * Copyright 2020 Google LLC. 1331 * 1332 * Licensed under the Apache License, Version 2.0 (the "License");
1333 * you may not use this file except in compliance with the License. 1334 * You may obtain a copy of the License at 1335 * 1336 * http://www.apache.org/licenses/LICENSE-2.0 1337 * 1338 * Unless required by applicable law or agreed to in writing, software 1339 * distributed under the License is distributed on an "AS IS" BASIS, 1340 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1341 * See the License for the specific language governing permissions and 1342 * limitations under the License. 1343 */const D3=new td(3e4,6e4);function hx(){const t=Di().___jsl;if(t!=null&&t.H){for(const 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 M3(t){return new Promise((e,n)=>{var r,i,s;function o(){hx(),gapi.load("gapi.iframes",{callback:()=>{e(gapi.iframes.getContext())},ontimeout:()=>{hx(),n(li(t,"network-request-failed"))},timeout:D3.get()})}if(!((i=(r=Di().gapi)===null||r===void 0?void 0:r.iframes)===null||i===void 0)&&i.Iframe)e(gapi.iframes.getContext());else if(!((s=Di().gapi)===null||s===void 0)&&s.load)o();else{const a=V6("iframefcb");return Di()[a]=()=>{gapi.load?o():n(li(t,"network-request-failed"))},j6(`${F6()}?onload=${a}`).catch(l=>n(l))}}).catch(e=>{throw Ph=null,e})}let Ph=null;function L3(t){return Ph=Ph||M3(t),Ph}/** 1344 * @license 1345 * Copyright 2020 Google LLC. 1346 * 1347 * Licensed under the Apache License, Version 2.0 (the "License"); 1348 * you may not use this file except in compliance with the License. 1349 * You may obtain a copy of the License at 1350 * 1351 * http://www.apache.org/licenses/LICENSE-2.0 1352 * 1353 * Unless required by applicable law or agreed to in writing, software 1354 * distributed under the License is distributed on an "AS IS" BASIS, 1355 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1356 * See the License for the specific language governing permissions and 1357 * limitations under the License. 1358 */const j3=new td(5e3,15e3),F3="__/auth/iframe",V3="emulator/auth/iframe",U3={style:{position:"absolute",top:"-100px",width:"1px",height:"1px"},"aria-hidden":"true",tabindex:"-1"},$3=new Map([["identitytoolkit.googleapis.com","p"],["staging-identitytoolkit.sandbox.googleapis.com","s"],["test-identitytoolkit.sandbox.googleapis.com","t"]]);function B3(t){const e=t.config;Be(e.authDomain,t,"auth-domain-config-required");const n=e.emulator?G_(e,V3):`https://${t.config.authDomain}/${F3}`,r={apiKey:e.apiKey,appName:t.name,v:al},i=$3.get(t.config.apiHost);i&&(r.eid=i);const s=t._getFrameworks();return s.length&&(r.fw=s.join(",")),`${n}?${ed(r).slice(1)}`}async function z3(t){const e=await L3(t),n=Di().gapi;return Be(n,t,"internal-error"),e.open({where:document.body,url:B3(t),messageHandlersFilter:n.iframes.CROSS_ORIGIN_IFRAMES_FILTER,attributes:U3,dontclear:!0},r=>new Promise(async(i,s)=>{await r.restyle({setHideOnLeave:!1});const o=li(t,"network-request-failed"),a=Di().setTimeout(()=>{s(o)},j3.get());function l(){Di().clearTimeout(a),i(r)}r.ping(l).then(l,()=>{s(o)})}))}/** 1359 * @license 1360 * Copyright 2020 Google LLC. 1361 * 1362 * Licensed under the Apache License, Version 2.0 (the "License"); 1363 * you may not use this file except in compliance with the License. 1364 * You may obtain a copy of the License at 1365 * 1366 * http://www.apache.org/licenses/LICENSE-2.0 1367 * 1368 * Unless required by applicable law or agreed to in writing, software 1369 * distributed under the License is distributed on an "AS IS" BASIS, 1370 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1371 * See the License for the specific language governing permissions and 1372 * limitations under the License. 1373 */const q3={location:"yes",resizable:"yes",statusbar:"yes",toolbar:"no"},H3=500,W3=600,G3="_blank",K3="http://localhost";class px{constructor(e){this.window=e,this.associatedEvent=null}close(){if(this.window)try{this.window.close()}catch{}}}function Y3(t,e,n,r=H3,i=W3){const s=Math.max((window.screen.availHeight-i)/2,0).toString(),o=Math.max((window.screen.availWidth-r)/2,0).toString();let a="";const l=Object.assign(Object.assign({},q3),{width:r.toString(),height:i.toString(),top:s,left:o}),u=Vn().toLowerCase();n&&(a=pI(u)?G3:n),dI(u)&&(e=e||K3,l.scrollbars="yes");const c=Object.entries(l).reduce((f,[p,_])=>`${f}${p}=${_},`,"");if(O6(u)&&a!=="_self")return Q3(e||"",a),new px(null);const d=window.open(e||"",a,c);Be(d,t,"popup-blocked");try{d.focus()}catch{}return new px(d)}function Q3(t,e){const n=document.createElement("a");n.href=t,n.target=e;const r=document.createEvent("MouseEvent");
1373r.initMouseEvent("click",!0,!0,window,1,0,0,0,0,!1,!1,!1,!1,1,null),n.dispatchEvent(r)}/** 1374 * @license 1375 * Copyright 2021 Google LLC 1376 * 1377 * Licensed under the Apache License, Version 2.0 (the "License"); 1378 * you may not use this file except in compliance with the License. 1379 * You may obtain a copy of the License at 1380 * 1381 * http://www.apache.org/licenses/LICENSE-2.0 1382 * 1383 * Unless required by applicable law or agreed to in writing, software 1384 * distributed under the License is distributed on an "AS IS" BASIS, 1385 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1386 * See the License for the specific language governing permissions and 1387 * limitations under the License. 1388 */const Z3="__/auth/handler",X3="emulator/auth/handler",J3=encodeURIComponent("fac");async function mx(t,e,n,r,i,s){Be(t.config.authDomain,t,"auth-domain-config-required"),Be(t.config.apiKey,t,"invalid-api-key");const o={apiKey:t.config.apiKey,appName:t.name,authType:n,redirectUrl:r,v:al,eventId:i};if(e instanceof X_){e.setDefaultLanguage(t.languageCode),o.providerId=e.providerId||"",ZL(e.getCustomParameters())||(o.customParameters=JSON.stringify(e.getCustomParameters()));for(const[c,d]of Object.entries({}))o[c]=d}if(e instanceof nd){const c=e.getScopes().filter(d=>d!=="");c.length>0&&(o.scopes=c.join(","))}t.tenantId&&(o.tid=t.tenantId);const a=o;for(const c of Object.keys(a))a[c]===void 0&&delete a[c];const l=await t._getAppCheckToken(),u=l?`#${J3}=${encodeURIComponent(l)}`:"";return`${eF(t)}?${ed(a).slice(1)}${u}`}function eF({config:t}){return t.emulator?G_(t,X3):`https://${t.authDomain}/${Z3}`}/** 1389 * @license 1390 * Copyright 2020 Google LLC 1391 * 1392 * Licensed under the Apache License, Version 2.0 (the "License"); 1393 * you may not use this file except in compliance with the License. 1394 * You may obtain a copy of the License at 1395 * 1396 * http://www.apache.org/licenses/LICENSE-2.0 1397 * 1398 * Unless required by applicable law or agreed to in writing, software 1399 * distributed under the License is distributed on an "AS IS" BASIS, 1400 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1401 * See the License for the specific language governing permissions and 1402 * limitations under the License. 1403 */const ov="webStorageSupport";class tF{constructor(){this.eventManagers={},this.iframes={},this.originValidationPromises={},this._redirectPersistence=AI,this._completeRedirectFn=S3,this._overrideRedirectResult=E3}async _openPopup(e,n,r,i){var s;Cs((s=this.eventManagers[e._key()])===null||s===void 0?void 0:s.manager,"_initialize() not called before _openPopup()");const o=await mx(e,n,r,Py(),i);return Y3(e,o,J_())}async _openRedirect(e,n,r,i){await this._originValidation(e);const s=await mx(e,n,r,Py(),i);return i3(s),new Promise(()=>{})}_initialize(e){const n=e._key();if(this.eventManagers[n]){const{manager:i,promise:s}=this.eventManagers[n];return i?Promise.resolve(i):(Cs(s,"If manager is not set, promise should be"),s)}const r=this.initAndGetManager(e);return this.eventManagers[n]={promise:r},r.catch(()=>{delete this.eventManagers[n]}),r}async initAndGetManager(e){const n=await z3(e),r=new A3(e);return n.register("authEvent",i=>(Be(i==null?void 0: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(ov,{type:ov},i=>{var s;const o=(s=i==null?void 0:i[0])===null||s===void 0?void 0:s[ov];o!==void 0&&n(!!o),Fi(e,"internal-error")},gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER)}_originValidation(e){const n=e._key();return this.originValidationPromises[n]||(this.originValidationPromises[n]=C3(e)),this.originValidationPromises[n]}get _shouldInitProactively(){return _I()||hI()||Q_()}}const nF=tF;var gx="@firebase/auth",vx="1.7.9";/** 1404 * @license 1405 * Copyright 2020 Google LLC 1406 * 1407 * Licensed under the Apache License, Version 2.0 (the "License"); 1408 * you may not use this file except in compliance with the License. 1409 * You may obtain a copy of the License at 1410 * 1411 * http://www.apache.org/licenses/LICENSE-2.0 1412 * 1413 * Unless required by applicable law or agreed to in writing, softw
1413are 1414 * distributed under the License is distributed on an "AS IS" BASIS, 1415 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1416 * See the License for the specific language governing permissions and 1417 * limitations under the License. 1418 */class rF{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;const n=this.auth.onIdTokenChanged(r=>{e((r==null?void 0:r.stsTokenManager.accessToken)||null)});this.internalListeners.set(e,n),this.updateProactiveRefresh()}removeAuthTokenListener(e){this.assertAuthConfigured();const n=this.internalListeners.get(e);n&&(this.internalListeners.delete(e),n(),this.updateProactiveRefresh())}assertAuthConfigured(){Be(this.auth._initializationPromise,"dependent-sdk-initialized-before-auth")}updateProactiveRefresh(){this.internalListeners.size>0?this.auth._startProactiveRefresh():this.auth._stopProactiveRefresh()}}/** 1419 * @license 1420 * Copyright 2020 Google LLC 1421 * 1422 * Licensed under the Apache License, Version 2.0 (the "License"); 1423 * you may not use this file except in compliance with the License. 1424 * You may obtain a copy of the License at 1425 * 1426 * http://www.apache.org/licenses/LICENSE-2.0 1427 * 1428 * Unless required by applicable law or agreed to in writing, software 1429 * distributed under the License is distributed on an "AS IS" BASIS, 1430 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1431 * See the License for the specific language governing permissions and 1432 * limitations under the License. 1433 */function iF(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 sF(t){fi(new zr("auth",(e,{options:n})=>{const r=e.getProvider("app").getImmediate(),i=e.getProvider("heartbeat"),s=e.getProvider("app-check-internal"),{apiKey:o,authDomain:a}=r.options;Be(o&&!o.includes(":"),"invalid-api-key",{appName:r.name});const l={apiKey:o,authDomain:a,clientPlatform:t,apiHost:"identitytoolkit.googleapis.com",tokenApiHost:"securetoken.googleapis.com",apiScheme:"https",sdkClientVersion:wI(t)},u=new M6(r,i,s,l);return $6(u,n),u},"PUBLIC").setInstantiationMode("EXPLICIT").setInstanceCreatedCallback((e,n,r)=>{e.getProvider("auth-internal").initialize()})),fi(new zr("auth-internal",e=>{const n=Am(e.getProvider("auth").getImmediate());return(r=>new rF(r))(n)},"PRIVATE").setInstantiationMode("EXPLICIT")),dr(gx,vx,iF(t)),dr(gx,vx,"esm2017")}/** 1434 * @license 1435 * Copyright 2021 Google LLC 1436 * 1437 * Licensed under the Apache License, Version 2.0 (the "License"); 1438 * you may not use this file except in compliance with the License. 1439 * You may obtain a copy of the License at 1440 * 1441 * http://www.apache.org/licenses/LICENSE-2.0 1442 * 1443 * Unless required by applicable law or agreed to in writing, software 1444 * distributed under the License is distributed on an "AS IS" BASIS, 1445 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1446 * See the License for the specific language governing permissions and 1447 * limitations under the License. 1448 */const oF=5*60,aF=GA("authIdTokenMaxAge")||oF;let yx=null;const lF=t=>async e=>{const n=e&&await e.getIdTokenResult(),r=n&&(new Date().getTime()-Date.parse(n.issuedAtTime))/1e3;if(r&&r>aF)return;const i=n==null?void 0:n.token;yx!==i&&(yx=i,await fetch(t,{method:i?"POST":"DELETE",headers:i?{Authorization:`Bearer ${i}`}:{}}))};function uF(t=km()){const e=Jo(t,"auth");if(e.isInitialized())return e.getImmediate();const n=U6(t,{popupRedirectResolver:nF,persistence:[h3,t3,AI]}),r=GA("authTokenSyncURL");if(r&&typeof isSecureContext=="boolean"&&isSecureContext){const s=new URL(r,location.origin);if(location.origin===s.origin){const o=lF(s.toString());Q6(n,o,()=>o(n.currentUser)),Y6(n,a=>o(a))}}const i=qA("auth");return i&&B6(n,`http://${i}`),n}function cF(){var t,e;return(e=(t=document.getElementsByTagName("head"))===null||t===void 0?void 0:t[0])!==null&&e!==void 0?e:document}
1448L6({loadJS(t){return new Promise((e,n)=>{const r=document.createElement("script");r.setAttribute("src",t),r.onload=e,r.onerror=i=>{const s=li("internal-error");s.customData=i,n(s)},r.type="text/javascript",r.charset="UTF-8",cF().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="});sF("Browser");var fF="firebase",dF="10.14.1";/** 1449 * @license 1450 * Copyright 2020 Google LLC 1451 * 1452 * Licensed under the Apache License, Version 2.0 (the "License"); 1453 * you may not use this file except in compliance with the License. 1454 * You may obtain a copy of the License at 1455 * 1456 * http://www.apache.org/licenses/LICENSE-2.0 1457 * 1458 * Unless required by applicable law or agreed to in writing, software 1459 * distributed under the License is distributed on an "AS IS" BASIS, 1460 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1461 * See the License for the specific language governing permissions and 1462 * limitations under the License. 1463 */dr(fF,dF,"app");const MI="@firebase/installations",t1="0.6.9";/** 1464 * @license 1465 * Copyright 2019 Google LLC 1466 * 1467 * Licensed under the Apache License, Version 2.0 (the "License"); 1468 * you may not use this file except in compliance with the License. 1469 * You may obtain a copy of the License at 1470 * 1471 * http://www.apache.org/licenses/LICENSE-2.0 1472 * 1473 * Unless required by applicable law or agreed to in writing, software 1474 * distributed under the License is distributed on an "AS IS" BASIS, 1475 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1476 * See the License for the specific language governing permissions and 1477 * limitations under the License. 1478 */const LI=1e4,jI=`w:${t1}`,FI="FIS_v2",hF="https://firebaseinstallations.googleapis.com/v1",pF=60*60*1e3,mF="installations",gF="Installations";/** 1479 * @license 1480 * Copyright 2019 Google LLC 1481 * 1482 * Licensed under the Apache License, Version 2.0 (the "License"); 1483 * you may not use this file except in compliance with the License. 1484 * You may obtain a copy of the License at 1485 * 1486 * http://www.apache.org/licenses/LICENSE-2.0 1487 * 1488 * Unless required by applicable law or agreed to in writing, software 1489 * distributed under the License is distributed on an "AS IS" BASIS, 1490 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1491 * See the License for the specific language governing permissions and 1492 * limitations under the License. 1493 */const vF={"missing-app-config-values":'Missing App configuration value: "{$valueName}"',"not-registered":"Firebase Installation is not registered.","installation-not-found":"Firebase Installation not found.","request-failed":'{$requestName} request failed with error "{$serverCode} {$serverStatus}: {$serverMessage}"',"app-offline":"Could not process request. Application offline.","delete-pending-registration":"Can't delete installation while there is a pending registration request."},Xa=new ol(mF,gF,vF);function VI(t){return t instanceof qr&&t.code.includes("request-failed")}/** 1494 * @license 1495 * Copyright 2019 Google LLC 1496 * 1497 * Licensed under the Apache License, Version 2.0 (the "License"); 1498 * you may not use this file except in compliance with the License. 1499 * You may obtain a copy of the License at 1500 * 1501 * http://www.apache.org/licenses/LICENSE-2.0 1502 * 1503 * Unless required by applicable law or agreed to in writing, software 1504 * distributed under the License is distributed on an "AS IS" BASIS, 1505 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1506 * See the License for the specific language governing permissions and 1507 * limitations under the License. 1508 */function UI({projectId:t}){return`${hF}/projects/${t}/installations`}function $I(t){return{token:t.token,requestStatus:2,expiresIn:_F(t.expiresIn),creationTime:Date.now()}}async function BI(t,e){const r=(await e.json()).error;return Xa.create("request-failed",{requestName:t,serverCode:r.code,serverMessage:r.message,serverStatus:r.status})}function zI({apiKey:t}){return new Headers({"Content-Type":"application/json",Accept:"application/json","x-goog-api-key":t})}function yF(t,{refreshToken:e}){const n=zI(t);return n.append("Authorization",wF(e)),n}async function qI(t){const e=await t();return e.status>=500&&e.status<600?t():e}function _F(t){return Number(t.replace("s","000"))}function wF(t){return`${FI} ${t}`}/** 1509 * @license 1510 * Copyright 2019 Google LLC 1511 * 1512 * Licensed under the Apache License, Version 2.0 (the "License");
1513 * you may not use this file except in compliance with the License. 1514 * You may obtain a copy of the License at 1515 * 1516 * http://www.apache.org/licenses/LICENSE-2.0 1517 * 1518 * Unless required by applicable law or agreed to in writing, software 1519 * distributed under the License is distributed on an "AS IS" BASIS, 1520 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1521 * See the License for the specific language governing permissions and 1522 * limitations under the License. 1523 */async function bF({appConfig:t,heartbeatServiceProvider:e},{fid:n}){const r=UI(t),i=zI(t),s=e.getImmediate({optional:!0});if(s){const u=await s.getHeartbeatsHeader();u&&i.append("x-firebase-client",u)}const o={fid:n,authVersion:FI,appId:t.appId,sdkVersion:jI},a={method:"POST",headers:i,body:JSON.stringify(o)},l=await qI(()=>fetch(r,a));if(l.ok){const u=await l.json();return{fid:u.fid||n,registrationStatus:2,refreshToken:u.refreshToken,authToken:$I(u.authToken)}}else throw await BI("Create Installation",l)}/** 1524 * @license 1525 * Copyright 2019 Google LLC 1526 * 1527 * Licensed under the Apache License, Version 2.0 (the "License"); 1528 * you may not use this file except in compliance with the License. 1529 * You may obtain a copy of the License at 1530 * 1531 * http://www.apache.org/licenses/LICENSE-2.0 1532 * 1533 * Unless required by applicable law or agreed to in writing, software 1534 * distributed under the License is distributed on an "AS IS" BASIS, 1535 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1536 * See the License for the specific language governing permissions and 1537 * limitations under the License. 1538 */function HI(t){return new Promise(e=>{setTimeout(e,t)})}/** 1539 * @license 1540 * Copyright 2019 Google LLC 1541 * 1542 * Licensed under the Apache License, Version 2.0 (the "License"); 1543 * you may not use this file except in compliance with the License. 1544 * You may obtain a copy of the License at 1545 * 1546 * http://www.apache.org/licenses/LICENSE-2.0 1547 * 1548 * Unless required by applicable law or agreed to in writing, software 1549 * distributed under the License is distributed on an "AS IS" BASIS, 1550 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1551 * See the License for the specific language governing permissions and 1552 * limitations under the License. 1553 */function EF(t){return btoa(String.fromCharCode(...t)).replace(/\+/g,"-").replace(/\//g,"_")}/** 1554 * @license 1555 * Copyright 2019 Google LLC 1556 * 1557 * Licensed under the Apache License, Version 2.0 (the "License"); 1558 * you may not use this file except in compliance with the License. 1559 * You may obtain a copy of the License at 1560 * 1561 * http://www.apache.org/licenses/LICENSE-2.0 1562 * 1563 * Unless required by applicable law or agreed to in writing, software 1564 * distributed under the License is distributed on an "AS IS" BASIS, 1565 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1566 * See the License for the specific language governing permissions and 1567 * limitations under the License. 1568 */const xF=/^[cdef][\w-]{21}$/,Ny="";function TF(){try{const t=new Uint8Array(17);(self.crypto||self.msCrypto).getRandomValues(t),t[0]=112+t[0]%16;const n=SF(t);return xF.test(n)?n:Ny}catch{return Ny}}function SF(t){return EF(t).substr(0,22)}/** 1569 * @license 1570 * Copyright 2019 Google LLC 1571 * 1572 * Licensed under the Apache License, Version 2.0 (the "License"); 1573 * you may not use this file except in compliance with the License. 1574 * You may obtain a copy of the License at 1575 * 1576 * http://www.apache.org/licenses/LICENSE-2.0 1577 * 1578 * Unless required by applicable law or agreed to in writing, software 1579 * distributed under the License is distributed on an "AS IS" BASIS, 1580 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1581 * See the License for the specific language governing permissions and 1582 * limitations under the License. 1583 */function Pm(t){return`${t.appName}!${t.appId}`}/** 1584 * @license 1585 * Copyright 2019 Google LLC 1586 * 1587 * Licensed under the Apache License, Version 2.0 (the "License"); 1588 * you may not use this file except in compliance with the License. 1589 * You may obtain a copy of the License at 1590 * 1591 * http://www.apache.org/licenses/LICENSE-2.0 1592 * 1593 * Unless required by applicable law or agreed to in writing, softw
1593are 1594 * distributed under the License is distributed on an "AS IS" BASIS, 1595 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1596 * See the License for the specific language governing permissions and 1597 * limitations under the License. 1598 */const WI=new Map;function GI(t,e){const n=Pm(t);KI(n,e),kF(n,e)}function KI(t,e){const n=WI.get(t);if(n)for(const r of n)r(e)}function kF(t,e){const n=AF();n&&n.postMessage({key:t,fid:e}),IF()}let Ea=null;function AF(){return!Ea&&"BroadcastChannel"in self&&(Ea=new BroadcastChannel("[Firebase] FID Change"),Ea.onmessage=t=>{KI(t.data.key,t.data.fid)}),Ea}function IF(){WI.size===0&&Ea&&(Ea.close(),Ea=null)}/** 1599 * @license 1600 * Copyright 2019 Google LLC 1601 * 1602 * Licensed under the Apache License, Version 2.0 (the "License"); 1603 * you may not use this file except in compliance with the License. 1604 * You may obtain a copy of the License at 1605 * 1606 * http://www.apache.org/licenses/LICENSE-2.0 1607 * 1608 * Unless required by applicable law or agreed to in writing, software 1609 * distributed under the License is distributed on an "AS IS" BASIS, 1610 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1611 * See the License for the specific language governing permissions and 1612 * limitations under the License. 1613 */const OF="firebase-installations-database",PF=1,Ja="firebase-installations-store";let av=null;function n1(){return av||(av=eI(OF,PF,{upgrade:(t,e)=>{switch(e){case 0:t.createObjectStore(Ja)}}})),av}async function Sp(t,e){const n=Pm(t),i=(await n1()).transaction(Ja,"readwrite"),s=i.objectStore(Ja),o=await s.get(n);return await s.put(e,n),await i.done,(!o||o.fid!==e.fid)&&GI(t,e.fid),e}async function YI(t){const e=Pm(t),r=(await n1()).transaction(Ja,"readwrite");await r.objectStore(Ja).delete(e),await r.done}async function Rm(t,e){const n=Pm(t),i=(await n1()).transaction(Ja,"readwrite"),s=i.objectStore(Ja),o=await s.get(n),a=e(o);return a===void 0?await s.delete(n):await s.put(a,n),await i.done,a&&(!o||o.fid!==a.fid)&&GI(t,a.fid),a}/** 1614 * @license 1615 * Copyright 2019 Google LLC 1616 * 1617 * Licensed under the Apache License, Version 2.0 (the "License"); 1618 * you may not use this file except in compliance with the License. 1619 * You may obtain a copy of the License at 1620 * 1621 * http://www.apache.org/licenses/LICENSE-2.0 1622 * 1623 * Unless required by applicable law or agreed to in writing, software 1624 * distributed under the License is distributed on an "AS IS" BASIS, 1625 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1626 * See the License for the specific language governing permissions and 1627 * limitations under the License. 1628 */async function r1(t){let e;const n=await Rm(t.appConfig,r=>{const i=RF(r),s=CF(t,i);return e=s.registrationPromise,s.installationEntry});return n.fid===Ny?{installationEntry:await e}:{installationEntry:n,registrationPromise:e}}function RF(t){const e=t||{fid:TF(),registrationStatus:0};return QI(e)}function CF(t,e){if(e.registrationStatus===0){if(!navigator.onLine){const i=Promise.reject(Xa.create("app-offline"));return{installationEntry:e,registrationPromise:i}}const n={fid:e.fid,registrationStatus:1,registrationTime:Date.now()},r=NF(t,n);return{installationEntry:n,registrationPromise:r}}else return e.registrationStatus===1?{installationEntry:e,registrationPromise:DF(t)}:{installationEntry:e}}async function NF(t,e){try{const n=await bF(t,e);return Sp(t.appConfig,n)}catch(n){throw VI(n)&&n.customData.serverCode===409?await YI(t.appConfig):await Sp(t.appConfig,{fid:e.fid,registrationStatus:0}),n}}async function DF(t){let e=await _x(t.appConfig);for(;e.registrationStatus===1;)await HI(100),e=await _x(t.appConfig);if(e.registrationStatus===0){const{installationEntry:n,registrationPromise:r}=await r1(t);return r||n}return e}function _x(t){return Rm(t,e=>{if(!e)throw Xa.create("installation-not-found");return QI(e)})}function QI(t){return MF(t)?{fid:t.fid,registrationStatus:0}:t}function MF(t){return t.registrationStatus===1&&t.registrationTime+LI<Date.now()}/** 1629 * @license 1630 * Copyright 2019 Google LLC 1631 * 1632 * Licensed under the Apache License, Version 2.0 (the "License");
1633 * you may not use this file except in compliance with the License. 1634 * You may obtain a copy of the License at 1635 * 1636 * http://www.apache.org/licenses/LICENSE-2.0 1637 * 1638 * Unless required by applicable law or agreed to in writing, software 1639 * distributed under the License is distributed on an "AS IS" BASIS, 1640 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1641 * See the License for the specific language governing permissions and 1642 * limitations under the License. 1643 */async function LF({appConfig:t,heartbeatServiceProvider:e},n){const r=jF(t,n),i=yF(t,n),s=e.getImmediate({optional:!0});if(s){const u=await s.getHeartbeatsHeader();u&&i.append("x-firebase-client",u)}const o={installation:{sdkVersion:jI,appId:t.appId}},a={method:"POST",headers:i,body:JSON.stringify(o)},l=await qI(()=>fetch(r,a));if(l.ok){const u=await l.json();return $I(u)}else throw await BI("Generate Auth Token",l)}function jF(t,{fid:e}){return`${UI(t)}/${e}/authTokens:generate`}/** 1644 * @license 1645 * Copyright 2019 Google LLC 1646 * 1647 * Licensed under the Apache License, Version 2.0 (the "License"); 1648 * you may not use this file except in compliance with the License. 1649 * You may obtain a copy of the License at 1650 * 1651 * http://www.apache.org/licenses/LICENSE-2.0 1652 * 1653 * Unless required by applicable law or agreed to in writing, software 1654 * distributed under the License is distributed on an "AS IS" BASIS, 1655 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1656 * See the License for the specific language governing permissions and 1657 * limitations under the License. 1658 */async function i1(t,e=!1){let n;const r=await Rm(t.appConfig,s=>{if(!ZI(s))throw Xa.create("not-registered");const o=s.authToken;if(!e&&UF(o))return s;if(o.requestStatus===1)return n=FF(t,e),s;{if(!navigator.onLine)throw Xa.create("app-offline");const a=BF(s);return n=VF(t,a),a}});return n?await n:r.authToken}async function FF(t,e){let n=await wx(t.appConfig);for(;n.authToken.requestStatus===1;)await HI(100),n=await wx(t.appConfig);const r=n.authToken;return r.requestStatus===0?i1(t,e):r}function wx(t){return Rm(t,e=>{if(!ZI(e))throw Xa.create("not-registered");const n=e.authToken;return zF(n)?Object.assign(Object.assign({},e),{authToken:{requestStatus:0}}):e})}async function VF(t,e){try{const n=await LF(t,e),r=Object.assign(Object.assign({},e),{authToken:n});return await Sp(t.appConfig,r),n}catch(n){if(VI(n)&&(n.customData.serverCode===401||n.customData.serverCode===404))await YI(t.appConfig);else{const r=Object.assign(Object.assign({},e),{authToken:{requestStatus:0}});await Sp(t.appConfig,r)}throw n}}function ZI(t){return t!==void 0&&t.registrationStatus===2}function UF(t){return t.requestStatus===2&&!$F(t)}function $F(t){const e=Date.now();return e<t.creationTime||t.creationTime+t.expiresIn<e+pF}function BF(t){const e={requestStatus:1,requestTime:Date.now()};return Object.assign(Object.assign({},t),{authToken:e})}function zF(t){return t.requestStatus===1&&t.requestTime+LI<Date.now()}/** 1659 * @license 1660 * Copyright 2019 Google LLC 1661 * 1662 * Licensed under the Apache License, Version 2.0 (the "License"); 1663 * you may not use this file except in compliance with the License. 1664 * You may obtain a copy of the License at 1665 * 1666 * http://www.apache.org/licenses/LICENSE-2.0 1667 * 1668 * Unless required by applicable law or agreed to in writing, software 1669 * distributed under the License is distributed on an "AS IS" BASIS, 1670 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1671 * See the License for the specific language governing permissions and 1672 * limitations under the License. 1673 */async function qF(t){const e=t,{installationEntry:n,registrationPromise:r}=await r1(e);return r?r.catch(console.error):i1(e).catch(console.error),n.fid}/** 1674 * @license 1675 * Copyright 2019 Google LLC 1676 * 1677 * Licensed under the Apache License, Version 2.0 (the "License"); 1678 * you may not use this file except in compliance with the License. 1679 * You may obtain a copy of the License at 1680 * 1681 * http://www.apache.org/licenses/LICENSE-2.0 1682 * 1683 * Unless required by applicable law or agreed to in writing, software 1684 * distributed under the License is distributed on an "AS IS" BASIS, 1685 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1686 * See the License for the specific language governing permissions and 1687 * limitations under the License. 1688 */async function HF(t,e=!1){const n=t;return await WF(n),(await i1(n,e)).token}async function WF(t){const{registrationPromise:e}=await r1(t);e&&await e}/** 1689 * @license 1690 * Copyright 2019 Google LLC 1691 * 1692 * Licensed under the Apache License, Version 2.0 (the "License");
1693 * you may not use this file except in compliance with the License. 1694 * You may obtain a copy of the License at 1695 * 1696 * http://www.apache.org/licenses/LICENSE-2.0 1697 * 1698 * Unless required by applicable law or agreed to in writing, software 1699 * distributed under the License is distributed on an "AS IS" BASIS, 1700 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1701 * See the License for the specific language governing permissions and 1702 * limitations under the License. 1703 */function GF(t){if(!t||!t.options)throw lv("App Configuration");if(!t.name)throw lv("App Name");const e=["projectId","apiKey","appId"];for(const n of e)if(!t.options[n])throw lv(n);return{appName:t.name,projectId:t.options.projectId,apiKey:t.options.apiKey,appId:t.options.appId}}function lv(t){return Xa.create("missing-app-config-values",{valueName:t})}/** 1704 * @license 1705 * Copyright 2020 Google LLC 1706 * 1707 * Licensed under the Apache License, Version 2.0 (the "License"); 1708 * you may not use this file except in compliance with the License. 1709 * You may obtain a copy of the License at 1710 * 1711 * http://www.apache.org/licenses/LICENSE-2.0 1712 * 1713 * Unless required by applicable law or agreed to in writing, software 1714 * distributed under the License is distributed on an "AS IS" BASIS, 1715 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1716 * See the License for the specific language governing permissions and 1717 * limitations under the License. 1718 */const XI="installations",KF="installations-internal",YF=t=>{const e=t.getProvider("app").getImmediate(),n=GF(e),r=Jo(e,"heartbeat");return{app:e,appConfig:n,heartbeatServiceProvider:r,_delete:()=>Promise.resolve()}},QF=t=>{const e=t.getProvider("app").getImmediate(),n=Jo(e,XI).getImmediate();return{getId:()=>qF(n),getToken:i=>HF(n,i)}};function ZF(){fi(new zr(XI,YF,"PUBLIC")),fi(new zr(KF,QF,"PRIVATE"))}ZF();dr(MI,t1);dr(MI,t1,"esm2017");/** 1719 * @license 1720 * Copyright 2019 Google LLC 1721 * 1722 * Licensed under the Apache License, Version 2.0 (the "License"); 1723 * you may not use this file except in compliance with the License. 1724 * You may obtain a copy of the License at 1725 * 1726 * http://www.apache.org/licenses/LICENSE-2.0 1727 * 1728 * Unless required by applicable law or agreed to in writing, software 1729 * distributed under the License is distributed on an "AS IS" BASIS, 1730 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1731 * See the License for the specific language governing permissions and 1732 * limitations under the License. 1733 */const kp="analytics",XF="firebase_id",JF="origin",e5=60*1e3,t5="https://firebase.googleapis.com/v1alpha/projects/-/apps/{app-id}/webConfig",s1="https://www.googletagmanager.com/gtag/js";/** 1734 * @license 1735 * Copyright 2019 Google LLC 1736 * 1737 * Licensed under the Apache License, Version 2.0 (the "License"); 1738 * you may not use this file except in compliance with the License. 1739 * You may obtain a copy of the License at 1740 * 1741 * http://www.apache.org/licenses/LICENSE-2.0 1742 * 1743 * Unless required by applicable law or agreed to in writing, software 1744 * distributed under the License is distributed on an "AS IS" BASIS, 1745 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1746 * See the License for the specific language governing permissions and 1747 * limitations under the License. 1748 */const hr=new Sm("@firebase/analytics");/** 1749 * @license 1750 * Copyright 2019 Google LLC 1751 * 1752 * Licensed under the Apache License, Version 2.0 (the "License"); 1753 * you may not use this file except in compliance with the License. 1754 * You may obtain a copy of the License at 1755 * 1756 * http://www.apache.org/licenses/LICENSE-2.0 1757 * 1758 * Unless required by applicable law or agreed to in writing, software 1759 * distributed under the License is distributed on an "AS IS" BASIS, 1760 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1761 * See the License for the specific language governing permissions and 1762 * limitations under the License. 1763 */const n5={"already-exists":"A Firebase Analytics instance with the appId {$id} already exists. Only one Firebase Analytics instance can be created for each appId.","already-initialized":"initializeAnalytics() cannot be called again with different options than those it was initially called with. It can be called again with the same options to return the existing instance, or getAnalytics() can be used to get a reference to the already-initialized instance.","already-initialized-settings":"Firebase Analytics has already been initialized.settings() must be called before initializing any Analytics instanceor it will have no effect.","interop-component-reg-failed":"Firebase Analytics Interop Component failed to instantiate: {$reason}
1763","invalid-analytics-context":"Firebase Analytics is not supported in this environment. Wrap initialization of analytics in analytics.isSupported() to prevent initialization in unsupported environments. Details: {$errorInfo}","indexeddb-unavailable":"IndexedDB unavailable or restricted in this environment. Wrap initialization of analytics in analytics.isSupported() to prevent initialization in unsupported environments. Details: {$errorInfo}","fetch-throttle":"The config fetch request timed out while in an exponential backoff state. Unix timestamp in milliseconds when fetch request throttling ends: {$throttleEndTimeMillis}.","config-fetch-failed":"Dynamic config fetch failed: [{$httpStatus}] {$responseMessage}","no-api-key":'The "apiKey" field is empty in the local Firebase config. Firebase Analytics requires this field tocontain a valid API key.',"no-app-id":'The "appId" field is empty in the local Firebase config. Firebase Analytics requires this field tocontain a valid app ID.',"no-client-id":'The "client_id" field is empty.',"invalid-gtag-resource":"Trusted Types detected an invalid gtag resource: {$gtagURL}."},kr=new ol("analytics","Analytics",n5);/** 1764 * @license 1765 * Copyright 2019 Google LLC 1766 * 1767 * Licensed under the Apache License, Version 2.0 (the "License"); 1768 * you may not use this file except in compliance with the License. 1769 * You may obtain a copy of the License at 1770 * 1771 * http://www.apache.org/licenses/LICENSE-2.0 1772 * 1773 * Unless required by applicable law or agreed to in writing, software 1774 * distributed under the License is distributed on an "AS IS" BASIS, 1775 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1776 * See the License for the specific language governing permissions and 1777 * limitations under the License. 1778 */function r5(t){if(!t.startsWith(s1)){const e=kr.create("invalid-gtag-resource",{gtagURL:t});return hr.warn(e.message),""}return t}function JI(t){return Promise.all(t.map(e=>e.catch(n=>n)))}function i5(t,e){let n;return window.trustedTypes&&(n=window.trustedTypes.createPolicy(t,e)),n}function s5(t,e){const n=i5("firebase-js-sdk-policy",{createScriptURL:r5}),r=document.createElement("script"),i=`${s1}?l=${t}&id=${e}`;r.src=n?n==null?void 0:n.createScriptURL(i):i,r.async=!0,document.head.appendChild(r)}function o5(t){let e=[];return Array.isArray(window[t])?e=window[t]:window[t]=e,e}async function a5(t,e,n,r,i,s){const o=r[i];try{if(o)await e[o];else{const l=(await JI(n)).find(u=>u.measurementId===i);l&&await e[l.appId]}}catch(a){hr.error(a)}t("config",i,s)}async function l5(t,e,n,r,i){try{let s=[];if(i&&i.send_to){let o=i.send_to;Array.isArray(o)||(o=[o]);const a=await JI(n);for(const l of o){const u=a.find(d=>d.measurementId===l),c=u&&e[u.appId];if(c)s.push(c);else{s=[];break}}}s.length===0&&(s=Object.values(e)),await Promise.all(s),t("event",r,i||{})}catch(s){hr.error(s)}}function u5(t,e,n,r){async function i(s,...o){try{if(s==="event"){const[a,l]=o;await l5(t,e,n,a,l)}else if(s==="config"){const[a,l]=o;await a5(t,e,n,r,a,l)}else if(s==="consent"){const[a,l]=o;t("consent",a,l)}else if(s==="get"){const[a,l,u]=o;t("get",a,l,u)}else if(s==="set"){const[a]=o;t("set",a)}else t(s,...o)}catch(a){hr.error(a)}}return i}function c5(t,e,n,r,i){let s=function(...o){window[r].push(arguments)};return window[i]&&typeof window[i]=="function"&&(s=window[i]),window[i]=u5(s,t,e,n),{gtagCore:s,wrappedGtag:window[i]}}function f5(t){const e=window.document.getElementsByTagName("script");for(const n of Object.values(e))if(n.src&&n.src.includes(s1)&&n.src.includes(t))return n;return null}/** 1779 * @license 1780 * Copyright 2020 Google LLC 1781 * 1782 * Licensed under the Apache License, Version 2.0 (the "License"); 1783 * you may not use this file except in compliance with the License. 1784 * You may obtain a copy of the License at 1785 * 1786 * http://www.apache.org/licenses/LICENSE-2.0 1787 * 1788 * Unless required by applicable law or agreed to in writing, software 1789 * distributed under the License is distributed on an "AS IS" BASIS, 1790 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1791 * See the License for the specific language governing permissions and 1792 * limitations under the License. 1793 */const d5=30,h5=1e3;class p5{constructor(e={},n=h5){this.throttleMetadata=e,this.intervalMillis=n}getThrottleMetadata(e){return this.throttleMetadata[e]}setThrottleMetadata(e,n){this.throttleMetadata[e]=n}deleteThrottleMetadata(e){delete this.throttleMetadata[e]}}const eO=new p5;function m5(t){return new Headers({Accept:"application/json","x-goog-api-key":t})}async function g5(t){var e;const{appId:n,apiKey:r}=t,i={method:"GET",headers:m5(r)},s=t5.replace("{app-id}",n),o=await fetch(s,i);if(o.status!==200&&o.status!==304){let a="";try{const l=await o.json();!((e=l.error)===null||e===void 0)&&e.message&&(a=l.error.message)}catch{}throw kr.create("config-fetch-failed",{httpStatus:o.status,responseMessage:a})}return o.json()}async function v5(t,e=eO,n){const{appId:r,apiKey:i,measurementId:s}=t.options;if(!r)throw kr.create("no-app-id");
1793if(!i){if(s)return{measurementId:s,appId:r};throw kr.create("no-api-key")}const o=e.getThrottleMetadata(r)||{backoffCount:0,throttleEndTimeMillis:Date.now()},a=new w5;return setTimeout(async()=>{a.abort()},e5),tO({appId:r,apiKey:i,measurementId:s},o,a,e)}async function tO(t,{throttleEndTimeMillis:e,backoffCount:n},r,i=eO){var s;const{appId:o,measurementId:a}=t;try{await y5(r,e)}catch(l){if(a)return hr.warn(`Timed out fetching this Firebase app's measurement ID from the server. Falling back to the measurement ID ${a} provided in the "measurementId" field in the local Firebase config. [${l==null?void 0:l.message}]`),{appId:o,measurementId:a};throw l}try{const l=await g5(t);return i.deleteThrottleMetadata(o),l}catch(l){const u=l;if(!_5(u)){if(i.deleteThrottleMetadata(o),a)return hr.warn(`Failed to fetch this Firebase app's measurement ID from the server. Falling back to the measurement ID ${a} provided in the "measurementId" field in the local Firebase config. [${u==null?void 0:u.message}]`),{appId:o,measurementId:a};throw l}const c=Number((s=u==null?void 0:u.customData)===null||s===void 0?void 0:s.httpStatus)===503?GE(n,i.intervalMillis,d5):GE(n,i.intervalMillis),d={throttleEndTimeMillis:Date.now()+c,backoffCount:n+1};return i.setThrottleMetadata(o,d),hr.debug(`Calling attemptFetch again in ${c} millis`),tO(t,d,r,i)}}function y5(t,e){return new Promise((n,r)=>{const i=Math.max(e-Date.now(),0),s=setTimeout(n,i);t.addEventListener(()=>{clearTimeout(s),r(kr.create("fetch-throttle",{throttleEndTimeMillis:e}))})})}function _5(t){if(!(t instanceof qr)||!t.customData)return!1;const e=Number(t.customData.httpStatus);return e===429||e===500||e===503||e===504}class w5{constructor(){this.listeners=[]}addEventListener(e){this.listeners.push(e)}abort(){this.listeners.forEach(e=>e())}}async function b5(t,e,n,r,i){if(i&&i.global){t("event",n,r);return}else{const s=await e,o=Object.assign(Object.assign({},r),{send_to:s});t("event",n,o)}}/** 1794 * @license 1795 * Copyright 2020 Google LLC 1796 * 1797 * Licensed under the Apache License, Version 2.0 (the "License"); 1798 * you may not use this file except in compliance with the License. 1799 * You may obtain a copy of the License at 1800 * 1801 * http://www.apache.org/licenses/LICENSE-2.0 1802 * 1803 * Unless required by applicable law or agreed to in writing, software 1804 * distributed under the License is distributed on an "AS IS" BASIS, 1805 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1806 * See the License for the specific language governing permissions and 1807 * limitations under the License. 1808 */async function E5(){if(QA())try{await ZA()}catch(t){return hr.warn(kr.create("indexeddb-unavailable",{errorInfo:t==null?void 0:t.toString()}).message),!1}else return hr.warn(kr.create("indexeddb-unavailable",{errorInfo:"IndexedDB is not available in this environment."}).message),!1;return!0}async function x5(t,e,n,r,i,s,o){var a;const l=v5(t);l.then(p=>{n[p.measurementId]=p.appId,t.options.measurementId&&p.measurementId!==t.options.measurementId&&hr.warn(`The measurement ID in the local Firebase config (${t.options.measurementId}) does not match the measurement ID fetched from the server (${p.measurementId}). To ensure analytics events are always sent to the correct Analytics property, update the measurement ID field in the local config or remove it from the local config.`)}).catch(p=>hr.error(p)),e.push(l);const u=E5().then(p=>{if(p)return r.getId()}),[c,d]=await Promise.all([l,u]);f5(s)||s5(s,c.measurementId),i("js",new Date);const f=(a=o==null?void 0:o.config)!==null&&a!==void 0?a:{};return f[JF]="firebase",f.update=!0,d!=null&&(f[XF]=d),i("config",c.measurementId,f),c.measurementId}/** 1809 * @license 1810 * Copyright 2019 Google LLC 1811 * 1812 * Licensed under the Apache License, Version 2.0 (the "License"); 1813 * you may not use this file except in compliance with the License. 1814 * You may obtain a copy of the License at 1815 * 1816 * http://www.apache.org/licenses/LICENSE-2.0 1817 * 1818 * Unless required by applicable law or agreed to in writing, software 1819 * distributed under the License is distributed on an "AS IS" BASIS, 1820 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1821 * See the License for the specific language governing permissions and 1822 * limitations under the License. 1823 */class T5{constructor(e){this.app=e}_delete(){return delete Wc[this.app.options.appId],Promise.resolve()}}let Wc={},bx=[];const Ex={};let uv="dataLayer",S5="gtag",xx,nO,Tx=!1;function k5(){const t=[];
1823if(YA()&&t.push("This is a browser extension environment."),GL()||t.push("Cookies are not available."),t.length>0){const e=t.map((r,i)=>`(${i+1}) ${r}`).join(" "),n=kr.create("invalid-analytics-context",{errorInfo:e});hr.warn(n.message)}}function A5(t,e,n){k5();const r=t.options.appId;if(!r)throw kr.create("no-app-id");if(!t.options.apiKey)if(t.options.measurementId)hr.warn(`The "apiKey" field is empty in the local Firebase config. This is needed to fetch the latest measurement ID for this Firebase app. Falling back to the measurement ID ${t.options.measurementId} provided in the "measurementId" field in the local Firebase config.`);else throw kr.create("no-api-key");if(Wc[r]!=null)throw kr.create("already-exists",{id:r});if(!Tx){o5(uv);const{wrappedGtag:s,gtagCore:o}=c5(Wc,bx,Ex,uv,S5);nO=s,xx=o,Tx=!0}return Wc[r]=x5(t,bx,Ex,e,xx,uv,n),new T5(t)}function I5(t=km()){t=Ot(t);const e=Jo(t,kp);return e.isInitialized()?e.getImmediate():O5(t)}function O5(t,e={}){const n=Jo(t,kp);if(n.isInitialized()){const i=n.getImmediate();if(bf(e,n.getOptions()))return i;throw kr.create("already-initialized")}return n.initialize({options:e})}function P5(t,e,n,r){t=Ot(t),b5(nO,Wc[t.app.options.appId],e,n,r).catch(i=>hr.error(i))}const Sx="@firebase/analytics",kx="0.10.8";function R5(){fi(new zr(kp,(e,{options:n})=>{const r=e.getProvider("app").getImmediate(),i=e.getProvider("installations-internal").getImmediate();return A5(r,i,n)},"PUBLIC")),fi(new zr("analytics-internal",t,"PRIVATE")),dr(Sx,kx),dr(Sx,kx,"esm2017");function t(e){try{const n=e.getProvider(kp).getImmediate();return{logEvent:(r,i,s)=>P5(n,r,i,s)}}catch(n){throw kr.create("interop-component-reg-failed",{reason:n})}}}R5();var Ax=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/** @license 1824Copyright The Closure Library Authors. 1825SPDX-License-Identifier: Apache-2.0 1826*/var Va,rO;(function(){var t;/** @license 1827 1828 Copyright The Closure Library Authors. 1829 SPDX-License-Identifier: Apache-2.0 1830*/function e(x,E){function T(){}T.prototype=E.prototype,x.D=E.prototype,x.prototype=new T,x.prototype.constructor=x,x.C=function(S,k,I){for(var P=Array(arguments.length-2),M=2;M<arguments.length;M++)P[M-2]=arguments[M];return E.prototype[k].apply(S,P)}}function n(){this.blockSize=-1}function r(){this.blockSize=-1,this.blockSize=64,this.g=Array(4),this.B=Array(this.blockSize),this.o=this.h=0,this.s()}e(r,n),r.prototype.s=function(){this.g[0]=1732584193,this.g[1]=4023233417,this.g[2]=2562383102,this.g[3]=271733878,this.o=this.h=0};function i(x,E,T){T||(T=0);var S=Array(16);if(typeof E=="string")for(var k=0;16>k;++k)S[k]=E.charCodeAt(T++)|E.charCodeAt(T++)<<8|E.charCodeAt(T++)<<16|E.charCo
vendor: 49,887 bytes, lines 1830-1845
1830deAt(T++)<<24;else for(k=0;16>k;++k)S[k]=E[T++]|E[T++]<<8|E[T++]<<16|E[T++]<<24;E=x.g[0],T=x.g[1],k=x.g[2];var I=x.g[3],P=E+(I^T&(k^I))+S[0]+3614090360&4294967295;E=T+(P<<7&4294967295|P>>>25),P=I+(k^E&(T^k))+S[1]+3905402710&4294967295,I=E+(P<<12&4294967295|P>>>20),P=k+(T^I&(E^T))+S[2]+606105819&4294967295,k=I+(P<<17&4294967295|P>>>15),P=T+(E^k&(I^E))+S[3]+3250441966&4294967295,T=k+(P<<22&4294967295|P>>>10),P=E+(I^T&(k^I))+S[4]+4118548399&4294967295,E=T+(P<<7&4294967295|P>>>25),P=I+(k^E&(T^k))+S[5]+1200080426&4294967295,I=E+(P<<12&4294967295|P>>>20),P=k+(T^I&(E^T))+S[6]+2821735955&4294967295,k=I+(P<<17&4294967295|P>>>15),P=T+(E^k&(I^E))+S[7]+4249261313&4294967295,T=k+(P<<22&4294967295|P>>>10),P=E+(I^T&(k^I))+S[8]+1770035416&4294967295,E=T+(P<<7&4294967295|P>>>25),P=I+(k^E&(T^k))+S[9]+2336552879&4294967295,I=E+(P<<12&4294967295|P>>>20),P=k+(T^I&(E^T))+S[10]+4294925233&4294967295,k=I+(P<<17&4294967295|P>>>15),P=T+(E^k&(I^E))+S[11]+2304563134&4294967295,T=k+(P<<22&4294967295|P>>>10),P=E+(I^T&(k^I))+S[12]+1804603682&4294967295,E=T+(P<<7&4294967295|P>>>25),P=I+(k^E&(T^k))+S[13]+4254626195&4294967295,I=E+(P<<12&4294967295|P>>>20),P=k+(T^I&(E^T))+S[14]+2792965006&4294967295,k=I+(P<<17&4294967295|P>>>15),P=T+(E^k&(I^E))+S[15]+1236535329&4294967295,T=k+(P<<22&4294967295|P>>>10),P=E+(k^I&(T^k))+S[1]+4129170786&4294967295,E=T+(P<<5&4294967295|P>>>27),P=I+(T^k&(E^T))+S[6]+3225465664&4294967295,I=E+(P<<9&4294967295|P>>>23),P=k+(E^T&(I^E))+S[11]+643717713&4294967295,k=I+(P<<14&4294967295|P>>>18),P=T+(I^E&(k^I))+S[0]+3921069994&4294967295,T=k+(P<<20&4294967295|P>>>12),P=E+(k^I&(T^k))+S[5]+3593408605&4294967295,E=T+(P<<5&4294967295|P>>>27),P=I+(T^k&(E^T))+S[10]+38016083&4294967295,I=E+(P<<9&4294967295|P>>>23),P=k+(E^T&(I^E))+S[15]+3634488961&4294967295,k=I+(P<<14&4294967295|P>>>18),P=T+(I^E&(k^I))+S[4]+3889429448&4294967295,T=k+(P<<20&4294967295|P>>>12),P=E+(k^I&(T^k))+S[9]+568446438&4294967295,E=T+(P<<5&4294967295|P>>>27),P=I+(T^k&(E^T))+S[14]+3275163606&4294967295,I=E+(P<<9&4294967295|P>>>23),P=k+(E^T&(I^E))+S[3]+4107603335&4294967295,k=I+(P<<14&4294967295|P>>>18),P=T+(I^E&(k^I))+S[8]+1163531501&4294967295,T=k+(P<<20&4294967295|P>>>12),P=E+(k^I&(T^k))+S[13]+2850285829&4294967295,E=T+(P<<5&4294967295|P>>>27),P=I+(T^k&(E^T))+S[2]+4243563512&4294967295,I=E+(P<<9&4294967295|P>>>23),P=k+(E^T&(I^E))+S[7]+1735328473&4294967295,k=I+(P<<14&4294967295|P>>>18),P=T+(I^E&(k^I))+S[12]+2368359562&4294967295,T=k+(P<<20&4294967295|P>>>12),P=E+(T^k^I)+S[5]+4294588738&4294967295,E=T+(P<<4&4294967295|P>>>28),P=I+(E^T^k)+S[8]+2272392833&4294967295,I=E+(P<<11&4294967295|P>>>21),P=k+(I^E^T)+S[11]+1839030562&4294967295,k=I+(P<<16&4294967295|P>>>16),P=T+(k^I^E)+S[14]+4259657740&4294967295,T=k+(P<<23&4294967295|P>>>9),P=E+(T^k^I)+S[1]+2763975236&4294967295,E=T+(P<<4&4294967295|P>>>28),P=I+(E^T^k)+S[4]+1272893353&4294967295,I=E+(P<<11&4294967295|P>>>21),P=k+(I^E^T)+S[7]+4139469664&4294967295,k=I+(P<<16&4294967295|P>>>16),P=T+(k^I^E)+S[10]+3200236656&4294967295,T=k+(P<<23&4294967295|P>>>9),P=E+(T^k^I)+S[13]+681279174&4294967295,E=T+(P<<4&4294967295|P>>>28),P=I+(E^T^k)+S[0]+3936430074&4294967295,I=E+(P<<11&4294967295|P>>>21),P=k+(I^E^T)+S[3]+3572445317&4294967295,k=I+(P<<16&4294967295|P>>>16),P=T+(k^I^E)+S[6]+76029189&4294967295,T=k+(P<<23&4294967295|P>>>9),P=E+(T^k^I)+S[9]+3654602809&4294967295,E=T+(P<<4&4294967295|P>>>28),P=I+(E^T^k)+S[12]+3873151461&4294967295,I=E+(P<<11&4294967295|P>>>21),P=k+(I^E^T)+S[15]+530742520&4294967295,k=I+(P<<16&4294967295|P>>>16),P=T+(k^I^E)+S[2]+3299628645&4294967295,T=k+(P<<23&4294967295|P>>>9),P=E+(k^(T|~I))+S[0]+4096336452&4294967295,E=T+(P<<6&4294967295|P>>>26),P=I+(T^(E|~k))+S[7]+1126891415&4294967295,I=E+(P<<10&4294967295|P>>>22),P=k+(E^(I|~T))+S[14]+2878612391&4294967295,k=I+(P<<15&4294967295|P>>>17),P=T+(I^(k|~E))+S[5]+4237533241&4294967295,T=k+(P<<21&4294967295|P>>>11),P=E+(k^(T|~I))+S[12]+1700485571&4294967295,E=T+(P<<6&4294967295|P>>>26),P=I+(T^(E|~k))+S[3]+2399980690&4294967295,I=E+(P<<10&4294967295|P>>>22),P=k+(E^(I|~T))+S[10]+4293915773&4294967295,k=I+(P<<15&4294967295|P>>>17),P=T+(I^(k|~E))+S[1]+2240044497&4294967295,T=k+(P<<21&4294967295|P>>>11),P=E+(k^(T|~I))+S[8]+1873313359&4294967295,E=T+(P<<6&4294967295|P>>>26),P=I+(T^(E|~k))+S[15]+4264355552&4294967295,I=E+(P<<10&4294967295|P>>>22),P=k+(E^(I|~T))+S[6]+2734768916&4294967295,k=I+(P<<15&4294967295|P>>>17),P=T+(I^(k|~E))+S[13]+1309151649&4294967295,T=k+(P<<21&4294967295|P>>>11),P=E+(k^(T|~I))+S[4]+4149444226&4294967295,E=T+(P<<6&4294967295|P>>>26),P=I+(T^(E|~k))+S[11]+3174756917&4294967295,I=E+(P<<10&4294967295|P>>>22),P=k+(E^(I|~T))+S[2]+718787259&4294967295,k=I+(P<<15&4294967295|P>>>17),P=T+(I^(k|~E))+S[9]+3951481745&4294967295,x.g[0]=x.g[0]+E&4294967295,x.g[1]=x.g[1]+(k+(P<<21&4294967295|P>>>11))&4294967295,x.g[2]=x.g[2]+k&4294967295,x.g[3]=x.g[3]+I&4294967295}r.prototype.u=function(x,E){E===void 0&&(E=x.length);for(var T=E-this.blockSize,S=this.B,k=this.h,I=0;I<E;){if(k==0)for(;I<=T;)i(this,x,I),I+=this.blockSize;if(typeof x=="string"){for(;I<E;)if(S[k++]=x.charCodeAt(I++),k==this.blockSize){i(this,S),k=0;break}}else for(;I<E;)if(S[k++]=x[I++],k==this.blockSize){i(this,S),k=0;break}}this.h=k,this.o+=E},r.prototype.v=function(){var x=Array((56>this.h?this.blockSize:2*this.blockSize)-this.h);x[0]=128;for(var E=1;E<x.length-8;++E)x[E]=0;var T=8*this.o;for(E=x.length-8;E<x.length;++E)x[E]=T&255,T/=256;for(this.u(x),x=Array(16),E=T=0;4>E;++E)for(var S=0;32>S;S+=8)x[T++]=this.g[E]>>>S&255;return x};function s(x,E){var T=a;return Object.prototype.hasOwnProperty.call(T,x)?T[x]:T[x]=E(x)}function o(x,E){this.h=E;for(var T=[],S=!0,k=x.length-1;0<=k;k--){var I=x[k]|0;S&&I==E||(T[k]=I,S=!1)}this.g=T}var a={};function l(x){return-128<=x&&128>x?s(x,function(E){return new o([E|0],0>E?-1:0)}):new o([x|0],0>x?-1:0)}function u(x){if(isNaN(x)||!isFinite(x))return d;if(0>x)return w(u(-x));for(var E=[],T=1,S=0;x>=T;S++)E[S]=x/T|0,T*=4294967296;return new o(E,0)}function c(x,E){if(x.length==0)throw Error("number format error: empty string");if(E=E||10,2>E||36<E)throw Error("radix out of range: "+E);if(x.charAt(0)=="-")return w(c(x.substring(1),E));if(0<=x.indexOf("-"))throw Error('number format error: interior "-" character');for(var T=u(Math.pow(E,8)),S=d,k=0;k<x.length;k+=8){var I=Math.min(8,x.length-k),P=parseInt(x.substring(k,k+I),E);8>I?(I=u(Math.pow(E,I)),S=S.j(I).add(u(P))):(S=S.j(T),S=S.add(u(P)))}return S}var d=l(0),f=l(1),p=l(16777216);t=o.prototype,t.m=function(){if(y(this))return-w(this).m();for(var x=0,E=1,T=0;T<this.g.length;T++){var S=this.i(T);x+=(0<=S?S:4294967296+S)*E,E*=4294967296}return x},t.toString=function(x){if(x=x||10,2>x||36<x)throw Error("radix out of range: "+x);if(_(this))return"0";if(y(this))return"-"+w(this).toString(x);for(var E=u(Math.pow(x,6)),T=this,S="";;){var k=v(T,E).g;T=g(T,k.j(E));var I=((0<T.g.length?T.g[0]:T.h)>>>0).toString(x);if(T=k,_(T))return I+S;for(;6>I.length;)I="0"+I;S=I+S}},t.i=function(x){return 0>x?0:x<this.g.length?this.g[x]:this.h};function _(x){if(x.h!=0)return!1;for(var E=0;E<x.g.length;E++)if(x.g[E]!=0)return!1;return!0}function y(x){return x.h==-1}t.l=function(x){return x=g(this,x),y(x)?-1:_(x)?0:1};function w(x){for(var E=x.g.length,T=[],S=0;S<E;S++)T[S]=~x.g[S];return new o(T,~x.h).add(f)}t.abs=function(){return y(this)?w(this):this},t.add=function(x){for(var E=Math.max(this.g.length,x.g.length),T=[],S=0,k=0;k<=E;k++){var I=S+(this.i(k)&65535)+(x.i(k)&65535),P=(I>>>16)+(this.i(k)>>>16)+(x.i(k)>>>16);S=P>>>16,I&=65535,P&=65535,T[k]=P<<16|I}return new o(T,T[T.length-1]&-2147483648?-1:0)};function g(x,E){return x.add(w(E))}t.j=function(x){if(_(this)||_(x))return d;if(y(this))return y(x)?w(this).j(w(x)):w(w(this).j(x));if(y(x))return w(this.j(w(x)));if(0>this.l(p)&&0>x.l(p))return u(this.m()*x.m());for(var E=this.g.length+x.g.length,T=[],S=0;S<2*E;S++)T[S]=0;for(S=0;S<this.g.length;S++)for(var k=0;k<x.g.length;k++){var I=this.i(S)>>>16,P=this.i(S)&65535,M=x.i(k)>>>16,$=x.i(k)&65535;T[2*S+2*k]+=P*$,m(T,2*S+2*k),T[2*S+2*k+1]+=I*$,m(T,2*S+2*k+1),T[2*S+2*k+1]+=P*M,m(T,2*S+2*k+1),T[2*S+2*k+2]+=I*M,m(T,2*S+2*k+2)}for(S=0;S<E;S++)T[S]=T[2*S+1]<<16|T[2*S];for(S=E;S<2*E;S++)T[S]=0;return new o(T,0)};function m(x,E){for(;(x[E]&65535)!=x[E];)x[E+1]+=x[E]>>>16,x[E]&=65535,E++}function b(x,E){this.g=x,this.h=E}function v(x,E){if(_(E))throw Error("division by zero");if(_(x))return new b(d,d);if(y(x))return E=v(w(x),E),new b(w(E.g),w(E.h));if(y(E))return E=v(x,w(E)),new b(w(E.g),E.h);if(30<x.g.length){if(y(x)||y(E))throw Error("slowDivide_ only works with positive integers.");for(var T=f,S=E;0>=S.l(x);)T=A(T),S=A(S);var k=N(T,1),I=N(S,1);for(S=N(S,2),T=N(T,2);!_(S);){var P=I.add(S);0>=P.l(x)&&(k=k.add(T),I=P),S=N(S,1),T=N(T,1)}return E=g(x,k.j(E)),new b(k,E)}for(k=d;0<=x.l(E);){for(T=Math.max(1,Math.floor(x.m()/E.m())),S=Math.ceil(Math.log(T)/Math.LN2),S=48>=S?1:Math.pow(2,S-48),I=u(T),P=I.j(E);y(P)||0<P.l(x);)T-=S,I=u(T),P=I.j(E);_(I)&&(I=f),k=k.add(I),x=g(x,P)}return new b(k,x)}t.A=function(x){return v(this,x).h},t.and=function(x){for(var E=Math.max(this.g.length,x.g.length),T=[],S=0;S<E;S++)T[S]=this.i(S)&x.i(S);return new o(T,this.h&x.h)},t.or=function(x){for(var E=Math.max(this.g.length,x.g.length),T=[],S=0;S<E;S++)T[S]=this.i(S)|x.i(S);return new o(T,this.h|x.h)},t.xor=function(x){for(var E=Math.max(this.g.length,x.g.length),T=[],S=0;S<E;S++)T[S]=this.i(S)^x.i(S);return new o(T,this.h^x.h)};function A(x){for(var E=x.g.length+1,T=[],S=0;S<E;S++)T[S]=x.i(S)<<1|x.i(S-1)>>>31;return new o(T,x.h)}function N(x,E){var T=E>>5;E%=32;for(var S=x.g.length-T,k=[],I=0;I<S;I++)k[I]=0<E?x.i(I+T)>>>E|x.i(I+T+1)<<32-E:x.i(I+T);return new o(k,x.h)}r.prototype.digest=r.prototype.v,r.prototype.reset=r.prototype.s,r.prototype.update=r.prototype.u,rO=r,o.prototype.add=o.prototype.add,o.prototype.multiply=o.prototype.j,o.prototype.modulo=o.prototype.A,o.prototype.compare=o.prototype.l,o.prototype.toNumber=o.prototype.m,o.prototype.toString=o.prototype.toString,o.prototype.getBits=o.prototype.i,o.fromNumber=u,o.fromString=c,Va=o}).apply(typeof Ax<"u"?Ax:typeof self<"u"?self:typeof window<"u"?window:{});var Jd=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/** @license 1831Copyright The Closure Library Authors. 1832SPDX-License-Identifier: Apache-2.0 1833*/var iO,Pc,sO,Rh,Dy,oO,aO,lO;(function(){var t,e=typeof Object.defineProperties=="function"?Object.defineProperty:function(h,O,C){return h==Array.prototype||h==Object.prototype||(h[O]=C.value),h};function n(h){h=[typeof globalThis=="object"&&globalThis,h,typeof window=="object"&&window,typeof self=="object"&&self,typeof Jd=="object"&&Jd];for(var O=0;O<h.length;++O){var C=h[O];if(C&&C.Math==Math)return C}throw Error("Cannot find global object")}var r=n(this);function i(h,O){if(O)e:{var C=r;h=h.split(".");for(var L=0;L<h.length-1;L++){var J=h[L];if(!(J in C))break e;C=C[J]}h=h[h.length-1],L=C[h],O=O(L),O!=L&&O!=null&&e(C,h,{configurable:!0,writable:!0,value:O})}}function s(h,O){h instanceof String&&(h+="");var C=0,L=!1,J={next:function(){if(!L&&C<h.length){var re=C++;return{value:O(re,h[re]),done:!1}}return L=!0,{done:!0,value:void 0}}};return J[Symbol.iterator]=function(){return J},J}i("Array.prototype.values",function(h){return h||function(){return s(this,function(O,C){return C})}});/** @license 1834 1835 Copyright The Closure Library Authors. 1836 SPDX-License-Identifier: Apache-2.0 1837*/var o=o||{},a=this||self;function l(h){var O=typeof h;return O=O!="object"?O:h?Array.isArray(h)?"array":O:"null",O=="array"||O=="object"&&typeof h.length=="number"}function u(h){var O=typeof h;return O=="object"&&h!=null||O=="function"}function c(h,O,C){return h.call.apply(h.bind,arguments)}function d(h,O,C){if(!h)throw Error();if(2<arguments.length){var L=Array.prototype.slice.call(arguments,2);return function(){var J=Array.prototype.slice.call(arguments);return Array.prototype.unshift.apply(J,L),h.apply(O,J)}}return function(){return h.apply(O,arguments)}}function f(h,O,C){return f=Function.prototype.bind&&Function.prototype.bind.toString().indexOf("native code")!=-1?c:d,f.apply(null,arguments)}function p(h,O){var C=Array.prototype.slice.call(arguments,1);return function(){var L=C.slice();return L.push.apply(L,arguments),h.apply(this,L)}}function _(h,O){function C(){}C.prototype=O.prototype,h.aa=O.prototype,h.prototype=new C,h.prototype.constructor=h,h.Qb=function(L,J,re){for(var ge=Array(arguments.length-2),Tt=2;Tt<arguments.length;Tt++)ge[Tt-2]=arguments[Tt];return O.prototype[J].apply(L,ge)}}function y(h){const O=h.length;if(0<O){const C=Array(O);for(let L=0;L<O;L++)C[L]=h[L];return C}return[]}function w(h,O){for(let C=1;C<arguments.length;C++){const L=arguments[C];if(l(L)){const J=h.length||0,re=L.length||0;h.length=J+re;for(let ge=0;ge<re;ge++)h[J+ge]=L[ge]}else h.push(L)}}class g{constructor(O,C){this.i=O,this.j=C,this.h=0,this.g=null}get(){let O;return 0<this.h?(this.h--,O=this.g,this.g=O.next,O.next=null):O=this.i(),O}}function m(h){return/^[\s\xa0]*$/.test(h)}function b(){var h=a.navigator;return h&&(h=h.userAgent)?h:""}function v(h){return v[" "](h),h}v[" "]=function(){};var A=b().indexOf("Gecko")!=-1&&!(b().toLowerCase().indexOf("webkit")!=-1&&b().indexOf("Edge")==-1)&&!(b().indexOf("Trident")!=-1||b().indexOf("MSIE")!=-1)&&b().indexOf("Edge")==-1;function N(h,O,C){for(const L in h)O.call(C,h[L],L,h)}function x(h,O){for(const C in h)O.call(void 0,h[C],C,h)}function E(h){const O={};for(const C in h)O[C]=h[C];return O}const T="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function S(h,O){let C,L;for(let J=1;J<arguments.length;J++){L=arguments[J];for(C in L)h[C]=L[C];for(let re=0;re<T.length;re++)C=T[re],Object.prototype.hasOwnProperty.call(L,C)&&(h[C]=L[C])}}function k(h){var O=1;h=h.split(":");const C=[];for(;0<O&&h.length;)C.push(h.shift()),O--;return h.length&&C.push(h.join(":")),C}function I(h){a.setTimeout(()=>{throw h},0)}function P(){var h=B;let O=null;return h.g&&(O=h.g,h.g=h.g.next,h.g||(h.h=null),O.next=null),O}class M{constructor(){this.h=this.g=null}add(O,C){const L=$.get();L.set(O,C),this.h?this.h.next=L:this.g=L,this.h=L}}var $=new g(()=>new Z,h=>h.reset());class Z{constructor(){this.next=this.g=this.h=null}set(O,C){this.h=O,this.g=C,this.next=null}reset(){this.next=this.g=this.h=null}}let Q,K=!1,B=new M,V=()=>{const h=a.Promise.resolve(void 0);Q=()=>{h.then(D)}};var D=()=>{for(var h;h=P();){try{h.h.call(h.g)}catch(C){I(C)}var O=$;O.j(h),100>O.h&&(O.h++,h.next=O.g,O.g=h)}K=!1};function j(){this.s=this.s,this.C=this.C}j.prototype.s=!1,j.prototype.ma=function(){this.s||(this.s=!0,this.N())},j.prototype.N=function(){if(this.C)for(;this.C.length;)this.C.shift()()};function U(h,O){this.type=h,this.g=this.target=O,this.defaultPrevented=!1}U.prototype.h=function(){this.defaultPrevented=!0};var Y=function(){if(!a.addEventListener||!Object.defineProperty)return!1;var h=!1,O=Object.defineProperty({},"passive",{get:function(){h=!0}});try{const C=()=>{};a.addEventListener("test",C,O),a.removeEventListener("test",C,O)}catch{}return h}();function W(h,O){if(U.call(this,h?h.type:""),this.relatedTarget=this.g=this.target=null,this.button=this.screenY=this.screenX=this.clientY=this.clientX=0,this.key="",this.metaKey=this.shiftKey=this.altKey=this.ctrlKey=!1,this.state=null,this.pointerId=0,this.pointerType="",this.i=null,h){var C=this.type=h.type,L=h.changedTouches&&h.changedTouches.length?h.changedTouches[0]:null;if(this.target=h.target||h.srcElement,this.g=O,O=h.relatedTarget){if(A){e:{try{v(O.nodeName);var J=!0;break e}catch{}J=!1}J||(O=null)}}else C=="mouseover"?O=h.fromElement:C=="mouseout"&&(O=h.toElement);this.relatedTarget=O,L?(this.clientX=L.clientX!==void 0?L.clientX:L.pageX,this.clientY=L.clientY!==void 0?L.clientY:L.pageY,this.screenX=L.screenX||0,this.screenY=L.screenY||0):(this.clientX=h.clientX!==void 0?h.clientX:h.pageX,this.clientY=h.clientY!==void 0?h.clientY:h.pageY,this.screenX=h.screenX||0,this.screenY=h.screenY||0),this.button=h.button,this.key=h.key||"",this.ctrlKey=h.ctrlKey,this.altKey=h.altKey,this.shiftKey=h.shiftKey,this.metaKey=h.metaKey,this.pointerId=h.pointerId||0,this.pointerType=typeof h.pointerType=="string"?h.pointerType:F[h.pointerType]||"",this.state=h.state,this.i=h,h.defaultPrevented&&W.aa.h.call(this)}}_(W,U);var F={2:"touch",3:"pen",4:"mouse"};W.prototype.h=function(){W.aa.h.call(this);var h=this.i;h.preventDefault?h.preventDefault():h.returnValue=!1};var q="closure_listenable_"+(1e6*Math.random()|0),ee=0;function te(h,O,C,L,J){this.listener=h,this.proxy=null,this.src=O,this.type=C,this.capture=!!L,this.ha=J,this.key=++ee,this.da=this.fa=!1}function ae(h){h.da=!0,h.listener=null,h.proxy=null,h.src=null,h.ha=null}function _e(h){this.src=h,this.g={},this.h=0}_e.prototype.add=function(h,O,C,L,J){var re=h.toString();h=this.g[re],h||(h=this.g[re]=[],this.h++);var ge=Ce(h,O,L,J);return-1<ge?(O=h[ge],C||(O.fa=!1)):(O=new te(O,this.src,re,!!L,J),O.fa=C,h.push(O)),O};function Ee(h,O){var C=O.type;if(C in h.g){var L=h.g[C],J=Array.prototype.indexOf.call(L,O,void 0),re;(re=0<=J)&&Array.prototype.splice.call(L,J,1),re&&(ae(O),h.g[C].length==0&&(delete h.g[C],h.h--))}}function Ce(h,O,C,L){for(var J=0;J<h.length;++J){var re=h[J];if(!re.da&&re.listener==O&&re.capture==!!C&&re.ha==L)return J}return-1}var qe="closure_lm_"+(1e6*Math.random()|0),Ze={};function Et(h,O,C,L,J){if(Array.isArray(O)){for(var re=0;re<O.length;re++)Et(h,O[re],C,L,J);return null}return C=oe(C),h&&h[q]?h.K(O,C,u(L)?!!L.capture:!1,J):kt(h,O,C,!1,L,J)}function kt(h,O,C,L,J,re){if(!O)throw Error("Invalid event type");var ge=u(J)?!!J.capture:!!J,Tt=Ue(h);if(Tt||(h[qe]=Tt=new _e(h)),C=Tt.add(O,C,L,ge,re),C.proxy)return C;if(L=ie(),C.proxy=L,L.src=h,L.listener=C,h.addEventListener)Y||(J=ge),J===void 0&&(J=!1),h.addEventListener(O.toString(),L,J);else if(h.attachEvent)h.attachEvent(ye(O.toString()),L);else if(h.addListener&&h.removeListener)h.addListener(L);else throw Error("addEventListener and attachEvent are unavailable.");return C}function ie(){function h(C){return O.call(h.src,h.listener,C)}const O=ue;return h}function se(h,O,C,L,J){if(Array.isArray(O))for(var re=0;re<O.length;re++)se(h,O[re],C,L,J);else L=u(L)?!!L.capture:!!L,C=oe(C),h&&h[q]?(h=h.i,O=String(O).toString(),O in h.g&&(re=h.g[O],C=Ce(re,C,L,J),-1<C&&(ae(re[C]),Array.prototype.splice.call(re,C,1),re.length==0&&(delete h.g[O],h.h--)))):h&&(h=Ue(h))&&(O=h.g[O.toString()],h=-1,O&&(h=Ce(O,C,L,J)),(C=-1<h?O[h]:null)&&pe(C))}function pe(h){if(typeof h!="number"&&h&&!h.da){var O=h.src;if(O&&O[q])Ee(O.i,h);else{var C=h.type,L=h.proxy;O.removeEventListener?O.removeEventListener(C,L,h.capture):O.detachEvent?O.detachEvent(ye(C),L):O.addListener&&O.removeListener&&O.removeListener(L),(C=Ue(O))?(Ee(C,h),C.h==0&&(C.src=null,O[qe]=null)):ae(h)}}}function ye(h){return h in Ze?Ze[h]:Ze[h]="on"+h}function ue(h,O){if(h.da)h=!0;else{O=new W(O,this);var C=h.listener,L=h.ha||h.src;h.fa&&pe(h),h=C.call(L,O)}return h}function Ue(h){return h=h[qe],h instanceof _e?h:null}var Fe="__closure_events_fn_"+(1e9*Math.random()>>>0);function oe(h){return typeof h=="function"?h:(h[Fe]||(h[Fe]=function(O){return h.handleEvent(O)}),h[Fe])}function me(){j.call(this),this.i=new _e(this),this.M=this,this.F=null}_(me,j),me.prototype[q]=!0,me.prototype.removeEventListener=function(h,O,C,L){se(this,h,O,C,L)};function je(h,O){var C,L=h.F;if(L)for(C=[];L;L=L.F)C.push(L);if(h=h.M,L=O.type||O,typeof O=="string")O=new U(O,h);else if(O instanceof U)O.target=O.target||h;else{var J=O;O=new U(L,h),S(O,J)}if(J=!0,C)for(var re=C.length-1;0<=re;re--){var ge=O.g=C[re];J=Ne(ge,L,!0,O)&&J}if(ge=O.g=h,J=Ne(ge,L,!0,O)&&J,J=Ne(ge,L,!1,O)&&J,C)for(re=0;re<C.length;re++)ge=O.g=C[re],J=Ne(ge,L,!1,O)&&J}me.prototype.N=function(){if(me.aa.N.call(this),this.i){var h=this.i,O;for(O in h.g){for(var C=h.g[O],L=0;L<C.length;L++)ae(C[L]);delete h.g[O],h.h--}}this.F=null},me.prototype.K=function(h,O,C,L){return this.i.add(String(h),O,!1,C,L)},me.prototype.L=function(h,O,C,L){return this.i.add(String(h),O,!0,C,L)};function Ne(h,O,C,L){if(O=h.i.g[String(O)],!O)return!0;O=O.concat();for(var J=!0,re=0;re<O.length;++re){var ge=O[re];if(ge&&!ge.da&&ge.capture==C){var Tt=ge.listener,wn=ge.ha||ge.src;ge.fa&&Ee(h.i,ge),J=Tt.call(wn,L)!==!1&&J}}return J&&!L.defaultPrevented}function dt(h,O,C){if(typeof h=="function")C&&(h=f(h,C));else if(h&&typeof h.handleEvent=="function")h=f(h.handleEvent,h);else throw Error("Invalid listener argument");return 2147483647<Number(O)?-1:a.setTimeout(h,O||0)}function Xe(h){h.g=dt(()=>{h.g=null,h.i&&(h.i=!1,Xe(h))},h.l);const O=h.h;h.h=null,h.m.apply(null,O)}class Pt extends j{constructor(O,C){super(),this.m=O,this.l=C,this.h=null,this.i=!1,this.g=null}j(O){this.h=arguments,this.g?this.i=!0:Xe(this)}N(){super.N(),this.g&&(a.clearTimeout(this.g),this.g=null,this.i=!1,this.h=null)}}function Gr(h){j.call(this),this.h=h,this.g={}}_(Gr,j);var Un=[];function Hi(h){N(h.g,function(O,C){this.g.hasOwnProperty(C)&&pe(O)},h),h.g={}}Gr.prototype.N=function(){Gr.aa.N.call(this),Hi(this)},Gr.prototype.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented")};var Kr=a.JSON.stringify,Bs=a.JSON.parse,na=class{stringify(h){return a.JSON.stringify(h,void 0)}parse(h){return a.JSON.parse(h,void 0)}};function yi(){}yi.prototype.h=null;function Yr(h){return h.h||(h.h=h.i())}function ra(){}var Wi={OPEN:"a",kb:"b",Ja:"c",wb:"d"};function ia(){U.call(this,"d")}_(ia,U);function Xu(){U.call(this,"c")}_(Xu,U);var _i={},_d=null;function sa(){return _d=_d||new me}_i.La="serverreachability";function oa(h){U.call(this,_i.La,h)}_(oa,U);function wi(h){const O=sa();je(O,new oa(O))}_i.STAT_EVENT="statevent";function wd(h,O){U.call(this,_i.STAT_EVENT,h),this.stat=O}_(wd,U);function _n(h){const O=sa();je(O,new wd(O,h))}_i.Ma="timingevent";function G(h,O){U.call(this,_i.Ma,h),this.size=O}_(G,U);function X(h,O){if(typeof h!="function")throw Error("Fn must not be null and must be a function");return a.setTimeout(function(){h()},O)}function ne(){this.g=!0}ne.prototype.xa=function(){this.g=!1};function ce(h,O,C,L,J,re){h.info(function(){if(h.g)if(re)for(var ge="",Tt=re.split("&"),wn=0;wn<Tt.length;wn++){var ht=Tt[wn].split("=");if(1<ht.length){var In=ht[0];ht=ht[1];var On=In.split("_");ge=2<=On.length&&On[1]=="type"?ge+(In+"="+ht+"&"):ge+(In+"=redacted&")}}else ge=null;else ge=re;return"XMLHTTP REQ ("+L+") [attempt "+J+"]: "+O+` 1838`+C+` 1839`+ge})}function we(h,O,C,L,J,re,ge){h.info(function(){return"XMLHTTP RESP ("+L+") [ attempt "+J+"]: "+O+` 1840`+C+` 1841`+re+" "+ge})}function Pe(h,O,C,L){h.info(function(){return"XMLHTTP TEXT ("+O+"): "+Ie(h,C)+(L?" "+L:"")})}function Ve(h,O){h.info(function(){return"TIMEOUT: "+O})}ne.prototype.info=function(){};function Ie(h,O){if(!h.g)return O;if(!O)return null;try{var C=JSON.parse(O);if(C){for(h=0;h<C.length;h++)if(Array.isArray(C[h])){var L=C[h];if(!(2>L.length)){var J=L[1];if(Array.isArray(J)&&!(1>J.length)){var re=J[0];if(re!="noop"&&re!="stop"&&re!="close")for(var ge=1;ge<J.length;ge++)J[ge]=""}}}}return Kr(C)}catch{return O}}var Ae={NO_ERROR:0,gb:1,tb:2,sb:3,nb:4,rb:5,ub:6,Ia:7,TIMEOUT:8,xb:9},xe={lb:"complete",Hb:"success",Ja:"error",Ia:"abort",zb:"ready",Ab:"readystatechange",TIMEOUT:"timeout",vb:"incrementaldata",yb:"progress",ob:"downloadprogress",Pb:"uploadprogress"},Re;function $e(){}_($e,yi),$e.prototype.g=function(){return new XMLHttpRequest},$e.prototype.i=function(){return{}},Re=new $e;function Ge(h,O,C,L){this.j=h,this.i=O,this.l=C,this.R=L||1,this.U=new Gr(this),this.I=45e3,this.H=null,this.o=!1,this.m=this.A=this.v=this.L=this.F=this.S=this.B=null,this.D=[],this.g=null,this.C=0,this.s=this.u=null,this.X=-1,this.J=!1,this.O=0,this.M=null,this.W=this.K=this.T=this.P=!1,this.h=new rn}function rn(){this.i=null,this.g="",this.h=!1}var yt={},st={};function At(h,O,C){h.L=1,h.v=Td(Qi(O)),h.m=C,h.P=!0,Gi(h,null)}function Gi(h,O){h.F=Date.now(),$n(h),h.A=Qi(h.v);var C=h.A,L=h.R;Array.isArray(L)||(L=[String(L)]),qw(C.i,"t",L),h.C=0,C=h.j.J,h.h=new rn,h.g=lb(h.j,C?O:null,!h.m),0<h.O&&(h.M=new Pt(f(h.Y,h,h.g),h.O)),O=h.U,C=h.g,L=h.ca;var J="readystatechange";Array.isArray(J)||(J&&(Un[0]=J.toString()),J=Un);for(var re=0;re<J.length;re++){var ge=Et(C,J[re],L||O.handleEvent,!1,O.h||O);if(!ge)break;O.g[ge.key]=ge}O=h.H?E(h.H):{},h.m?(h.u||(h.u="POST"),O["Content-Type"]="application/x-www-form-urlencoded",h.g.ea(h.A,h.u,h.m,O)):(h.u="GET",h.g.ea(h.A,h.u,null,O)),wi(),ce(h.i,h.u,h.A,h.l,h.R,h.m)}Ge.prototype.ca=function(h){h=h.target;const O=this.M;O&&Zi(h)==3?O.j():this.Y(h)},Ge.prototype.Y=function(h){try{if(h==this.g)e:{const On=Zi(this.g);var O=this.g.Ba();const gl=this.g.Z();if(!(3>On)&&(On!=3||this.g&&(this.h.h||this.g.oa()||Zw(this.g)))){this.J||On!=4||O==7||(O==8||0>=gl?wi(3):wi(2)),Ki(this);var C=this.g.Z();this.X=C;t:if(zs(this)){var L=Zw(this.g);h="";var J=L.length,re=Zi(this.g)==4;if(!this.h.i){if(typeof TextDecoder>"u"){Cr(this),pr(this);var ge="";break t}this.h.i=new a.TextDecoder}for(O=0;O<J;O++)this.h.h=!0,h+=this.h.i.decode(L[O],{stream:!(re&&O==J-1)});L.length=0,this.h.g+=h,this.C=0,ge=this.h.g}else ge=this.g.oa();if(this.o=C==200,we(this.i,this.u,this.A,this.l,this.R,On,C),this.o){if(this.T&&!this.K){t:{if(this.g){var Tt,wn=this.g;if((Tt=wn.g?wn.g.getResponseHeader("X-HTTP-Initial-Response"):null)&&!m(Tt)){var ht=Tt;break t}}ht=null}if(C=ht)Pe(this.i,this.l,C,"Initial handshake response via X-HTTP-Initial-Response"),this.K=!0,qs(this,C);else{this.o=!1,this.s=3,_n(12),Cr(this),pr(this);break e}}if(this.P){C=!0;let Zr;for(;!this.J&&this.C<ge.length;)if(Zr=Qr(this,ge),Zr==st){On==4&&(this.s=4,_n(14),C=!1),Pe(this.i,this.l,null,"[Incomplete Response]");break}else if(Zr==yt){this.s=4,_n(15),Pe(this.i,this.l,ge,"[Invalid Chunk]"),C=!1;break}else Pe(this.i,this.l,Zr,null),qs(this,Zr);if(zs(this)&&this.C!=0&&(this.h.g=this.h.g.slice(this.C),this.C=0),On!=4||ge.length!=0||this.h.h||(this.s=1,_n(16),C=!1),this.o=this.o&&C,!C)Pe(this.i,this.l,ge,"[Invalid Chunked Response]"),Cr(this),pr(this);else if(0<ge.length&&!this.W){this.W=!0;var In=this.j;In.g==this&&In.ba&&!In.M&&(In.j.info("Great, no buffering proxy detected. Bytes received: "+ge.length),Eg(In),In.M=!0,_n(11))}}else Pe(this.i,this.l,ge,null),qs(this,ge);On==4&&Cr(this),this.o&&!this.J&&(On==4?ib(this.j,this):(this.o=!1,$n(this)))}else vN(this.g),C==400&&0<ge.indexOf("Unknown SID")?(this.s=3,_n(12)):(this.s=0,_n(13)),Cr(this),pr(this)}}}catch{}finally{}};function zs(h){return h.g?h.u=="GET"&&h.L!=2&&h.j.Ca:!1}function Qr(h,O){var C=h.C,L=O.indexOf(` 1842`,C);return L==-1?st:(C=Number(O.substring(C,L)),isNaN(C)?yt:(L+=1,L+C>O.length?st:(O=O.slice(L,L+C),h.C=L+C,O)))}Ge.prototype.cancel=function(){this.J=!0,Cr(this)};function $n(h){h.S=Date.now()+h.I,hl(h,h.I)}function hl(h,O){if(h.B!=null)throw Error("WatchDog timer not null");h.B=X(f(h.ba,h),O)}function Ki(h){h.B&&(a.clearTimeout(h.B),h.B=null)}Ge.prototype.ba=function(){this.B=null;const h=Date.now();0<=h-this.S?(Ve(this.i,this.A),this.L!=2&&(wi(),_n(17)),Cr(this),this.s=2,pr(this)):hl(this,this.S-h)};function pr(h){h.j.G==0||h.J||ib(h.j,h)}function Cr(h){Ki(h);var O=h.M;O&&typeof O.ma=="function"&&O.ma(),h.M=null,Hi(h.U),h.g&&(O=h.g,h.g=null,O.abort(),O.ma())}function qs(h,O){try{var C=h.j;if(C.G!=0&&(C.g==h||Ut(C.h,h))){if(!h.K&&Ut(C.h,h)&&C.G==3){try{var L=C.Da.g.parse(O)}catch{L=null}if(Array.isArray(L)&&L.length==3){var J=L;if(J[0]==0){e:if(!C.u){if(C.g)if(C.g.F+3e3<h.F)Pd(C),Id(C);else break e;bg(C),_n(18)}}else C.za=J[1],0<C.za-C.T&&37500>J[2]&&C.F&&C.v==0&&!C.C&&(C.C=X(f(C.Za,C),6e3));if(1>=Hs(C.h)&&C.ca){try{C.ca()}catch{}C.ca=void 0}}else la(C,11)}else if((h.K||C.g==h)&&Pd(C),!m(O))for(J=C.Da.g.parse(O),O=0;O<J.length;O++){let ht=J[O];if(C.T=ht[0],ht=ht[1],C.G==2)if(ht[0]=="c"){C.K=ht[1],C.ia=ht[2];const In=ht[3];In!=null&&(C.la=In,C.j.info("VER="+C.la));const On=ht[4];On!=null&&(C.Aa=On,C.j.info("SVER="+C.Aa));const gl=ht[5];gl!=null&&typeof gl=="number"&&0<gl&&(L=1.5*gl,C.L=L,C.j.info("backChannelRequestTimeoutMs_="+L)),L=C;const Zr=h.g;if(Zr){const Cd=Zr.g?Zr.g.getResponseHeader("X-Client-Wire-Protocol"):null;if(Cd){var re=L.h;re.g||Cd.indexOf("spdy")==-1&&Cd.indexOf("quic")==-1&&Cd.indexOf("h2")==-1||(re.j=re.l,re.g=new Set,re.h&&(bi(re,re.h),re.h=null))}if(L.D){const xg=Zr.g?Zr.g.getResponseHeader("X-HTTP-Session-Id"):null;xg&&(L.ya=xg,Ct(L.I,L.D,xg))}}C.G=3,C.l&&C.l.ua(),C.ba&&(C.R=Date.now()-h.F,C.j.info("Handshake RTT: "+C.R+"ms")),L=C;var ge=h;if(L.qa=ab(L,L.J?L.ia:null,L.W),ge.K){Ju(L.h,ge);var Tt=ge,wn=L.L;wn&&(Tt.I=wn),Tt.B&&(Ki(Tt),$n(Tt)),L.g=ge}else nb(L);0<C.i.length&&Od(C)}else ht[0]!="stop"&&ht[0]!="close"||la(C,7);else C.G==3&&(ht[0]=="stop"||ht[0]=="close"?ht[0]=="stop"?la(C,7):wg(C):ht[0]!="noop"&&C.l&&C.l.ta(ht),C.v=0)}}wi(4)}catch{}}var lt=class{constructor(h,O){this.g=h,this.map=O}};function Rt(h){this.l=h||10,a.PerformanceNavigationTiming?(h=a.performance.getEntriesByType("navigation"),h=0<h.length&&(h[0].nextHopProtocol=="hq"||h[0].nextHopProtocol=="h2")):h=!!(a.chrome&&a.chrome.loadTimes&&a.chrome.loadTimes()&&a.chrome.loadTimes().wasFetchedViaSpdy),this.j=h?this.l:1,this.g=null,1<this.j&&(this.g=new Set),this.h=null,this.i=[]}function Yi(h){return h.h?!0:h.g?h.g.size>=h.j:!1}function Hs(h){return h.h?1:h.g?h.g.size:0}function Ut(h,O){return h.h?h.h==O:h.g?h.g.has(O):!1}function bi(h,O){h.g?h.g.add(O):h.h=O}function Ju(h,O){h.h&&h.h==O?h.h=null:h.g&&h.g.has(O)&&h.g.delete(O)}Rt.prototype.cancel=function(){if(this.i=bd(this),this.h)this.h.cancel(),this.h=null;else if(this.g&&this.g.size!==0){for(const h of this.g.values())h.cancel();this.g.clear()}};function bd(h){if(h.h!=null)return h.i.concat(h.h.D);if(h.g!=null&&h.g.size!==0){let O=h.i;for(const C of h.g.values())O=O.concat(C.D);return O}return y(h.i)}function nN(h){if(h.V&&typeof h.V=="function")return h.V();if(typeof Map<"u"&&h instanceof Map||typeof Set<"u"&&h instanceof Set)return Array.from(h.values());if(typeof h=="string")return h.split("");if(l(h)){for(var O=[],C=h.length,L=0;L<C;L++)O.push(h[L]);return O}O=[],C=0;for(L in h)O[C++]=h[L];return O}function rN(h){if(h.na&&typeof h.na=="function")return h.na();if(!h.V||typeof h.V!="function"){if(typeof Map<"u"&&h instanceof Map)return Array.from(h.keys());if(!(typeof Set<"u"&&h instanceof Set)){if(l(h)||typeof h=="string"){var O=[];h=h.length;for(var C=0;C<h;C++)O.push(C);return O}O=[],C=0;for(const L in h)O[C++]=L;return O}}}function Fw(h,O){if(h.forEach&&typeof h.forEach=="function")h.forEach(O,void 0);else if(l(h)||typeof h=="string")Array.prototype.forEach.call(h,O,void 0);else for(var C=rN(h),L=nN(h),J=L.length,re=0;re<J;re++)O.call(void 0,L[re],C&&C[re],h)}var Vw=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^\\\\/?#]*)@)?([^\\\\/?#]*?)(?::([0-9]+))?(?=[\\\\/?#]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#([\\s\\S]*))?$");function iN(h,O){if(h){h=h.split("&");for(var C=0;C<h.length;C++){var L=h[C].indexOf("="),J=null;if(0<=L){var re=h[C].substring(0,L);J=h[C].substring(L+1)}else re=h[C];O(re,J?decodeURIComponent(J.replace(/\+/g," ")):"")}}}function aa(h){if(this.g=this.o=this.j="",this.s=null,this.m=this.l="",this.h=!1,h instanceof aa){this.h=h.h,Ed(this,h.j),this.o=h.o,this.g=h.g,xd(this,h.s),this.l=h.l;var O=h.i,C=new nc;C.i=O.i,O.g&&(C.g=new Map(O.g),C.h=O.h),Uw(this,C),this.m=h.m}else h&&(O=String(h).match(Vw))?(this.h=!1,Ed(this,O[1]||"",!0),this.o=ec(O[2]||""),this.g=ec(O[3]||"",!0),xd(this,O[4]),this.l=ec(O[5]||"",!0),Uw(this,O[6]||"",!0),this.m=ec(O[7]||"")):(this.h=!1,this.i=new nc(null,this.h))}aa.prototype.toString=function(){var h=[],O=this.j;O&&h.push(tc(O,$w,!0),":");var C=this.g;return(C||O=="file")&&(h.push("//"),(O=this.o)&&h.push(tc(O,$w,!0),"@"),h.push(encodeURIComponent(String(C)).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),C=this.s,C!=null&&h.push(":",String(C))),(C=this.l)&&(this.g&&C.charAt(0)!="/"&&h.push("/"),h.push(tc(C,C.charAt(0)=="/"?aN:oN,!0))),(C=this.i.toString())&&h.push("?",C),(C=this.m)&&h.push("#",tc(C,uN)),h.join("")};function Qi(h){return new aa(h)}function Ed(h,O,C){h.j=C?ec(O,!0):O,h.j&&(h.j=h.j.replace(/:$/,""))}function xd(h,O){if(O){if(O=Number(O),isNaN(O)||0>O)throw Error("Bad port number "+O);h.s=O}else h.s=null}function Uw(h,O,C){O instanceof nc?(h.i=O,cN(h.i,h.h)):(C||(O=tc(O,lN)),h.i=new nc(O,h.h))}function Ct(h,O,C){h.i.set(O,C)}function Td(h){return Ct(h,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^Date.now()).toString(36)),h}function ec(h,O){return h?O?decodeURI(h.replace(/%25/g,"%2525")):decodeURIComponent(h):""}function tc(h,O,C){return typeof h=="string"?(h=encodeURI(h).replace(O,sN),C&&(h=h.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),h):null}function sN(h){return h=h.charCodeAt(0),"%"+(h>>4&15).toString(16)+(h&15).toString(16)}var $w=/[#\/\?@]/g,oN=/[#\?:]/g,aN=/[#\?]/g,lN=/[#\?@]/g,uN=/#/g;function nc(h,O){this.h=this.g=null,this.i=h||null,this.j=!!O}function Ws(h){h.g||(h.g=new Map,h.h=0,h.i&&iN(h.i,function(O,C){h.add(decodeURIComponent(O.replace(/\+/g," ")),C)}))}t=nc.prototype,t.add=function(h,O){Ws(this),this.i=null,h=pl(this,h);var C=this.g.get(h);return C||this.g.set(h,C=[]),C.push(O),this.h+=1,this};function Bw(h,O){Ws(h),O=pl(h,O),h.g.has(O)&&(h.i=null,h.h-=h.g.get(O).length,h.g.delete(O))}function zw(h,O){return Ws(h),O=pl(h,O),h.g.has(O)}t.forEach=function(h,O){Ws(this),this.g.forEach(function(C,L){C.forEach(function(J){h.call(O,J,L,this)},this)},this)},t.na=function(){Ws(this);const h=Array.from(this.g.values()),O=Array.from(this.g.keys()),C=[];for(let L=0;L<O.length;L++){const J=h[L];for(let re=0;re<J.length;re++)C.push(O[L])}return C},t.V=function(h){Ws(this);let O=[];if(typeof h=="string")zw(this,h)&&(O=O.concat(this.g.get(pl(this,h))));else{h=Array.from(this.g.values());for(let C=0;C<h.length;C++)O=O.concat(h[C])}return O},t.set=function(h,O){return Ws(this),this.i=null,h=pl(this,h),zw(this,h)&&(this.h-=this.g.get(h).length),this.g.set(h,[O]),this.h+=1,this},t.get=function(h,O){return h?(h=this.V(h),0<h.length?String(h[0]):O):O};function qw(h,O,C){Bw(h,O),0<C.length&&(h.i=null,h.g.set(pl(h,O),y(C)),h.h+=C.length)}t.toString=function(){if(this.i)return this.i;if(!this.g)return"";const h=[],O=Array.from(this.g.keys());for(var C=0;C<O.length;C++){var L=O[C];const re=encodeURIComponent(String(L)),ge=this.V(L);for(L=0;L<ge.length;L++){var J=re;ge[L]!==""&&(J+="="+encodeURIComponent(String(ge[L]))),h.push(J)}}return this.i=h.join("&")};function pl(h,O){return O=String(O),h.j&&(O=O.toLowerCase()),O}function cN(h,O){O&&!h.j&&(Ws(h),h.i=null,h.g.forEach(function(C,L){var J=L.toLowerCase();L!=J&&(Bw(this,L),qw(this,J,C))},h)),h.j=O}function fN(h,O){const C=new ne;if(a.Image){const L=new Image;L.onload=p(Gs,C,"TestLoadImage: loaded",!0,O,L),L.onerror=p(Gs,C,"TestLoadImage: error",!1,O,L),L.onabort=p(Gs,C,"TestLoadImage: abort",!1,O,L),L.ontimeout=p(Gs,C,"TestLoadImage: timeout",!1,O,L),a.setTimeout(function(){L.ontimeout&&L.ontimeout()},1e4),L.src=h}else O(!1)}function dN(h,O){const C=new ne,L=new AbortController,J=setTimeout(()=>{L.abort(),Gs(C,"TestPingServer: timeout",!1,O)},1e4);fetch(h,{signal:L.signal}).then(re=>{clearTimeout(J),re.ok?Gs(C,"TestPingServer: ok",!0,O):Gs(C,"TestPingServer: server error",!1,O)}).catch(()=>{clearTimeout(J),Gs(C,"TestPingServer: error",!1,O)})}function Gs(h,O,C,L,J){try{J&&(J.onload=null,J.onerror=null,J.onabort=null,J.ontimeout=null),L(C)}catch{}}function hN(){this.g=new na}function pN(h,O,C){const L=C||"";try{Fw(h,function(J,re){let ge=J;u(J)&&(ge=Kr(J)),O.push(L+re+"="+encodeURIComponent(ge))})}catch(J){throw O.push(L+"type="+encodeURIComponent("_badmap")),J}}function Sd(h){this.l=h.Ub||null,this.j=h.eb||!1}_(Sd,yi),Sd.prototype.g=function(){return new kd(this.l,this.j)},Sd.prototype.i=function(h){return function(){return h}}({});function kd(h,O){me.call(this),this.D=h,this.o=O,this.m=void 0,this.status=this.readyState=0,this.responseType=this.responseText=this.response=this.statusText="",this.onreadystatechange=null,this.u=new Headers,this.h=null,this.B="GET",this.A="",this.g=!1,this.v=this.j=this.l=null}_(kd,me),t=kd.prototype,t.open=function(h,O){if(this.readyState!=0)throw this.abort(),Error("Error reopening a connection");this.B=h,this.A=O,this.readyState=1,ic(this)},t.send=function(h){if(this.readyState!=1)throw this.abort(),Error("need to call open() first. ");this.g=!0;const O={headers:this.u,method:this.B,credentials:this.m,cache:void 0};h&&(O.body=h),(this.D||a).fetch(new Request(this.A,O)).then(this.Sa.bind(this),this.ga.bind(this))},t.abort=function(){this.response=this.responseText="",this.u=new Headers,this.status=0,this.j&&this.j.cancel("Request was aborted.").catch(()=>{}),1<=this.readyState&&this.g&&this.readyState!=4&&(this.g=!1,rc(this)),this.readyState=0},t.Sa=function(h){if(this.g&&(this.l=h,this.h||(this.status=this.l.status,this.statusText=this.l.statusText,this.h=h.headers,this.readyState=2,ic(this)),this.g&&(this.readyState=3,ic(this),this.g)))if(this.responseType==="arraybuffer")h.arrayBuffer().then(this.Qa.bind(this),this.ga.bind(this));else if(typeof a.ReadableStream<"u"&&"body"in h){if(this.j=h.body.getReader(),this.o){if(this.responseType)throw Error('responseType must be empty for "streamBinaryChunks" mode responses.');this.response=[]}else this.response=this.responseText="",this.v=new TextDecoder;Hw(this)}else h.text().then(this.Ra.bind(this),this.ga.bind(this))};function Hw(h){h.j.read().then(h.Pa.bind(h)).catch(h.ga.bind(h))}t.Pa=function(h){if(this.g){if(this.o&&h.value)this.response.push(h.value);else if(!this.o){var O=h.value?h.value:new Uint8Array(0);(O=this.v.decode(O,{stream:!h.done}))&&(this.response=this.responseText+=O)}h.done?rc(this):ic(this),this.readyState==3&&Hw(this)}},t.Ra=function(h){this.g&&(this.response=this.responseText=h,rc(this))},t.Qa=function(h){this.g&&(this.response=h,rc(this))},t.ga=function(){this.g&&rc(this)};function rc(h){h.readyState=4,h.l=null,h.j=null,h.v=null,ic(h)}t.setRequestHeader=function(h,O){this.u.append(h,O)},t.getResponseHeader=function(h){return this.h&&this.h.get(h.toLowerCase())||""},t.getAllResponseHeaders=function(){if(!this.h)return"";const h=[],O=this.h.entries();for(var C=O.next();!C.done;)C=C.value,h.push(C[0]+": "+C[1]),C=O.next();return h.join(`\r 1843`)};function ic(h){h.onreadystatechange&&h.onreadystatechange.call(h)}Object.defineProperty(kd.prototype,"withCredentials",{get:function(){return this.m==="include"},set:function(h){this.m=h?"include":"same-origin"}});function Ww(h){let O="";return N(h,function(C,L){O+=L,O+=":",O+=C,O+=`\r 1844`}),O}function _g(h,O,C){e:{for(L in C){var L=!1;break e}L=!0}L||(C=Ww(C),typeof h=="string"?C!=null&&encodeURIComponent(String(C)):Ct(h,O,C))}function Yt(h){me.call(this),this.headers=new Map,this.o=h||null,this.h=!1,this.v=this.g=null,this.D="",this.m=0,this.l="",this.j=this.B=this.u=this.A=!1,this.I=null,this.H="",this.J=!1}_(Yt,me);var mN=/^https?$/i,gN=["POST","PUT"];t=Yt.prototype,t.Ha=function(h){this.J=h},t.ea=function(h,O,C,L){if(this.g)throw Error("[goog.net.XhrIo] Object is active with another request="+this.D+"; newUri="+h);O=O?O.toUpperCase():"GET",this.D=h,this.l="",this.m=0,this.A=!1,this.h=!0,this.g=this.o?this.o.g():Re.g(),this.v=this.o?Yr(this.o):Yr(Re),this.g.onreadystatechange=f(this.Ea,this);try{this.B=!0,this.g.open(O,String(h),!0),this.B=!1}catch(re){Gw(this,re);return}if(h=C||"",C=new Map(this.headers),L)if(Object.getPrototypeOf(L)===Object.prototype)for(var J in L)C.set(J,L[J]);else if(typeof L.keys=="function"&&typeof L.get=="function")for(const re of L.keys())C.set(re,L.get(re));else throw Error("Unknown input type for opt_headers: "+String(L));L=Array.from(C.keys()).find(re=>re.toLowerCase()=="content-type"),J=a.FormData&&h instanceof a.FormData,!(0<=Array.prototype.indexOf.call(gN,O,void 0))||L||J||C.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");for(const[re,ge]of C)this.g.setRequestHeader(re,ge);this.H&&(this.g.responseType=this.H),"withCredentials"in this.g&&this.g.withCredentials!==this.J&&(this.g.withCredentials=this.J);try{Qw(this),this.u=!0,this.g.send(h),this.u=!1}catch(re){Gw(this,re)}};function Gw(h,O){h.h=!1,h.g&&(h.j=!0,h.g.abort(),h.j=!1),h.l=O,h.m=5,Kw(h),Ad(h)}function Kw(h){h.A||(h.A=!0,je(h,"complete"),je(h,"error"))}t.abort=function(h){this.g&&this.h&&(this.h=!1,this.j=!0,this.g.abort(),this.j=!1,this.m=h||7,je(this,"complete"),je(this,"abort"),Ad(this))},t.N=function(){this.g&&(this.h&&(this.h=!1,this.j=!0,this.g.abort(),this.j=!1),Ad(this,!0)),Yt.aa.N.call(this)},t.Ea=function(){this.s||(this.B||this.u||this.j?Yw(this):this.bb())},t.bb=function(){Yw(this)};function Yw(h){if(h.h&&typeof o<"u"&&(!h.v[1]||Zi(h)!=4||h.Z()!=2)){if(h.u&&Zi(h)==4)dt(h.Ea,0,h);else if(je(h,"readystatechange"),Zi(h)==4){h.h=!1;try{const ge=h.Z();e:switch(ge){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:var O=!0;break e;default:O=!1}var C;if(!(C=O)){var L;if(L=ge===0){var J=String(h.D).match(Vw)[1]||null;!J&&a.self&&a.self.location&&(J=a.self.location.protocol.slice(0,-1)),L=!mN.test(J?J.toLowerCase():"")}C=L}if(C)je(h,"complete"),je(h,"success");else{h.m=6;try{var re=2<Zi(h)?h.g.statusText:""}catch{re=""}h.l=re+" ["+h.Z()+"]",Kw(h)}}finally{Ad(h)}}}}function Ad(h,O){if(h.g){Qw(h);const C=h.g,L=h.v[0]?()=>{}:null;h.g=null,h.v=null,O||je(h,"ready");try{C.onreadystatechange=L}catch{}}}function Qw(h){h.I&&(a.clearTimeout(h.I),h.I=null)}t.isActive=function(){return!!this.g};function Zi(h){return h.g?h.g.readyState:0}t.Z=function(){try{return 2<Zi(this)?this.g.status:-1}catch{return-1}},t.oa=function(){try{return this.g?this.g.responseText:""}catch{return""}},t.Oa=function(h){if(this.g){var O=this.g.responseText;return h&&O.indexOf(h)==0&&(O=O.substring(h.length)),Bs(O)}};function Zw(h){try{if(!h.g)return null;if("response"in h.g)return h.g.response;switch(h.H){case"":case"text":return h.g.responseText;case"arraybuffer":if("mozResponseArrayBuffer"in h.g)return h.g.mozResponseArrayBuffer}return null}catch{return null}}function vN(h){const O={};h=(h.g&&2<=Zi(h)&&h.g.getAllResponseHeaders()||"").split(`\r 1845`);for(let L=0;L<h.length;L++){if(m(h[L]))continue;var C=k(h[L]);const J=C[0];if(C=C[1],typeof C!="string")continue;C=C.trim();const re=O[J]||[];O[J]=re,re.push(C)}x(O,function(L){return L.join(", ")})}t.Ba=function(){return this.m},t.Ka=function(){return typeof this.l=="string"?this.l:String(this.l)};function sc(h,O,C){return C&&C.internalChannelParams&&C.internalChannelParams[h]||O}function Xw(h){this.Aa=0,this.i=[],this.j=new ne,this.ia=this.qa=this.I=this.W=this.g=this.ya=this.D=this.H=this.m=this.S=this.o=null,this.Ya=this.U=0,this.Va=sc("failFast",!1,h),this.F=this.C=this.u=this.s=this.l=null,this.X=!0,this.za=this.T=-1,this.Y=this.v=this.B=0,this.Ta=sc("baseRetryDelayMs",5e3,h),this.cb=sc("retryDelaySeedMs",1e4,h),this.Wa=sc("forwardChannelMaxRetries",2,h),this.wa=sc("forwardChannelRequestTimeoutMs",2e4,h),this.pa=h&&h.xmlHttpFactory||void 0,this.Xa=h&&h.Tb||void 0,this.Ca=h&&h.useFetchStreams||!1,this.L=void 0,this.J=h&&h.supportsCrossDomainXhr||!1,this.K="",this.h=new Rt(h&&h.concurrentRequestLimit),this.Da=new hN,this.P=h&&h.fastHandshake||!1,this.O=h&&h.encodeInitMessageHeaders||!1,this.P&&this.O&&(this.O=!1),this.Ua=h&&h.Rb||!1,h&&h.xa&&this.j.xa(),h&&h.forceLongPolling&&(this.X=!1),this.ba=!this.P&&this.X&&h&&h.detectBufferingProxy||!1,this.ja=void 0,h&&h.longPollingTimeout&&0<h.longPollingTimeout&&(this.ja=h.longPollingTimeout),this.ca=void 0,this.R=0,this.M=!1,this.ka=this.A=null}t=Xw.prototype,t.la=8,t.G=1,t.connect=function(h,O,C,L){_n(0),this.W=h,this.H=O||{},C&&L!==void 0&&(this.H.OSID=C,this.H.OAID=L),this.F=this.X,this.I=ab(this,null,this.W),Od(this)};function wg(h){if(Jw(h),h.G==3){var O=h.U++,C=Qi(h.I);if(Ct(C,"SID",h.K),Ct(C,"RID",O),Ct(C,"TYPE","terminate"),oc(h,C),O=new Ge(h,h.j,O),O.L=2,O.v=Td(Qi(C)),C=!1,a.navigator&&a.navigator.sendBeacon)try{C=a.navigator.sendBeacon(O.v.toString(),"")}catch{}!C&&a.Image&&(new Image().src=O.v,C=!0),C||(O.g=lb(O.j,null),O.g.ea(O.v)),O.F=Date.now(),$n(O)}ob(h)}function Id(h){h.g&&(Eg(h),h.g.cancel(),h.g=null)}function Jw(h){Id(h),h.u&&(a.clearTimeout(h.u),h.u=null),Pd(h),h.h.cancel(),h.s&&(typeof h.s=="number"&&a.clearTimeout(h.s),h.s=null)}function Od(h){if(!Yi(h.h)&&!h.s){h.s=!0;var O=h.Ga;Q||V(),K||(Q(),K=!0),B.add(O,h),h.B=0}}function yN(h,O){return Hs(h.h)>=h.h.j-(h.s?1:0)?!1:h.s?(h.i=O.D.concat(h.i),!0):h.G==1||h.G==2||h.B>=(h.Va?0:h.Wa)?!1:(h.s=X(f(h.Ga,h,O),sb(h,h.B)),h.B++,!0)}t.Ga=function(h){if(this.s)if(this.s=null,this.G==1){if(!h){this.U=Math.floor(1e5*Math.random()),h=this.U++;const J=new Ge(this,this.j,h);let re=this.o;if(this.S&&(re?(re=E(re),S(re,this.S)):re=this.S),this.m!==null||this.O||(J.H=re,re=null),this.P)e:{for(var O=0,C=0;C<this.i.length;C++){t:{var L=this.i[C];if("__data__"in L.map&&(L=L.map.__data__,typeof L=="string")){L=L.length;break t}L=void 0}if(L===void 0)break;if(O+=L,4096<O){O=C;break e}if(O===4096||C===this.i.length-1){O=C+1;break e}}O=1e3}else O=1e3;O=tb(this,J,O),C=Qi(this.I),Ct(C,"RID",h),Ct(C,"CVER",22),this.D&&Ct(C,"X-HTTP-Session-Id",this.D),oc(this,C),re&&(this.O?O="headers="+encodeURIComponent(String(Ww(re)))+"&"+O:this.m&&_g(C,this.m,re)),bi(this.h,J),this.Ua&&Ct(C,"TYPE","init"),this.P?(Ct(C,"$req",O),Ct(C,"SID","null"),J.T=!0,At(J,C,null)):At(J,C,O),this.G=2}}else this.G==3&&(h?eb(this,h):this.i.length==0||Yi(this.h)||eb(this))};function eb(h,O){var C;O?C=O.l:C=h.U++;const L=Qi(h.I);Ct(L,"SID",h.K),Ct(L,"RID",C),Ct(L,"AID",h.T),oc(h,L),h.m&&h.o&&_g(L,h.m,h.o),C=new Ge(h,h.j,C,h.B+1),h.m===null&&(C.H=h.o),O&&(h.i=O.D.concat(h.i)),O=tb(h,C,1e3),C.I=Math.round(.5*h.wa)+Math.round(.5*h.wa*Math.random()),bi(h.h,C),At(C,L,O)}function oc(h,O){h.H&&N(h.H,function(C,L){Ct(O,L,C)}),h.l&&Fw({},function(C,L){Ct(O,L,C)})}function tb(h,O,C){C=Math.min(h.i.length,C);var L=h.l?f(h.l.Na,h.l,h):null;e:{var J=h.i;let re=-1;for(;;){const ge=["count="+C];re==-1?0<C?(re=J[0].g,ge.push("ofs="+re)):re=0:ge.push("ofs="+re);let Tt=!0;for(let wn=0;wn<C;wn++){let ht=J[wn].g;const In=J[wn].map;if(ht-=re,0>ht)re=Math.max(0,J[wn].g-100),Tt=!1;else try{pN(In,ge,"req"+ht+"_")}catch{L&&L(In)}}if(Tt){L=ge.join("&");break e}}}return h=h.i.splice(0,C),O.D=h,L}function nb(h){if(!h.g&&!h.u){h.Y=1;var O=h.Fa;Q||V(),K||(Q(),K=!0),B.add(O,h),h.v=0}}function bg(h){return h.g||h.u||3<=h.v?!1:(h.Y++,h.u=X(f(h.Fa,h),sb(h,h.v)),h.v++,!0)}t.Fa=function(){if(this.u=null,rb(this),this.ba&&!(this.M||this.g==null||0>=this.R)){var h=2*this.R;this.j.info("BP detection timer enabled: "+h),this.A=X(f(this.ab,this),h)}},t.ab=function(){this.A&&(this.A=null,this.j.info("BP detection timeout reached."),this.j.info("Buffering proxy detected and switch to long-polling!"),this.F=!1,this.M=!0,_n(10),Id(this),rb(this))};function Eg(h){h.A!=null&&(a.clearTimeout(h.A),h.A=null)}function rb(h){h.g=new Ge(h,h.j,"rpc",h.Y),h.m===null&&(h.g.H=h.o),h.g.O=0;var O=Qi(h.qa);Ct(O,"RID","rpc"),Ct(O,"SID",h.K),Ct(O,"AID",h.T),Ct(O,"CI",h.F?"0":"1"),!h.F&&h.ja&&Ct(O,"TO",h.ja),Ct(O,"TYPE","xmlhttp"),oc(h,O),h.m&&h.o&&_g(O,h.m,h.o),h.L&&(h.g.I=h.L);var C=h.g;h=h.ia,C.L=1,C.v=Td(Qi(O)),C.m=null,C.P=!0,Gi(C,h)}t.Za=function(){this.C!=null&&(this.C=null,Id(this),bg(this),_n(19))};function Pd(h){h.C!=null&&(a.clearTimeout(h.C),h.C=null)}function ib(h,O){var C=null;if(h.g==O){Pd(h),Eg(h),h.g=null;var L=2}else if(Ut(h.h,O))C=O.D,Ju(h.h,O),L=1;else return;if(h.G!=0){if(O.o)if(L==1){C=O.m?O.m.length:0,O=Date.now()-O.F;var J=h.B;L=sa(),je(L,new G(L,C)),Od(h)}else nb(h);else if(J=O.s,J==3||J==0&&0<O.X||!(L==1&&yN(h,O)||L==2&&bg(h)))switch(C&&0<C.length&&(O=h.h,O.i=O.i.concat(C)),J){case 1:la(h,5);break;case 4:la(h,10);break;case 3:la(h,6);break;default:la(h,2)}}}function sb(h,O){let C=h.Ta+Math.floor(Math.random()*h.cb);return h.isActive()||(C*=2),C*O}function la(h,O){if(h.j.info("Error code "+O),O==2){var C=f(h.fb,h),L=h.Xa;const J=!L;L=new aa(L||"//www.google.com/images/cleardot.gif"),a.location&&a.location.protocol=="http"||Ed(L,"https"),Td(L),J?fN(L.toString(),C):dN(L.toString(),C)}else _n(2);h.G=0,h.l&&h.l.sa(O),ob(h),Jw(h)}t.fb=function(h){h?(this.j.info("Successfully pinged google.com"),_n(2)):(this.j.info("Failed to ping google.com"),_n(1))};function ob(h){if(h.G=0,h.ka=[],h.l){const O=bd(h.h);(O.length!=0||h.i.length!=0)&&(w(h.ka,O),w(h.ka,h.i),h.h.i.length=0,y(h.i),h.i.length=0),h.l.ra()}}function ab(h,O,C){var L=C instanceof aa?Qi(C):new aa(C);if(L.g!="")O&&(L.g=O+"."+L.g),xd(L,L.s);else{var J=a.location;L=J.protocol,O=O?O+"."+J.hostname:J.hostname,J=+J.port;var re=new aa(null);L&&Ed(re,L),O&&(re.g=O),J&&xd(re,J),C&&(re.l=C),L=re}return C=h.D,O=h.ya,C&&O&&Ct(L,C,O),Ct(L,"VER",h.la),oc(h,L),L}function lb(h,O,C){if(O&&!h.J)throw Error("Can't create secondary domain capable XhrIo object.");return O=h.Ca&&!h.pa?new Yt(new Sd({eb:C})):new Yt(h.pa),O.Ha(h.J),O}t.isActive=function(){return!!this.l&&this.l.isActive(this)};function ub(){}t=ub.prototype,t.ua=function(){},t.ta=function(){},t.sa=function(){},t.ra=function(){},t.isActive=function(){return!0},t.Na=function(){};function Rd(){}Rd.prototype.g=function(h,O){return new mr(h,O)};function mr(h,O){me.call(this),this.g=new Xw(O),this.l=h,this.h=O&&O.messageUrlParams||null,h=O&&O.messageHeaders||null,O&&O.clientProtocolHeaderRequired&&(h?h["X-Client-Protocol"]="webchannel":h={"X-Client-Protocol":"webchannel"}),this.g.o=h,h=O&&O.initMessageHeaders||null,O&&O.messageContentType&&(h?h["X-WebChannel-Content-Type"]=O.messageContentType:h={"X-WebChannel-Content-Type":O.messageContentType}),O&&O.va&&(h?h["X-WebChannel-Client-Profile"]=O.va:h={"X-WebChannel-Client-Profile":O.va}),this.g.S=h,(h=O&&O.Sb)&&!m(h)&&(this.g.m=h),this.v=O&&O.supportsCrossDomainXhr||!1,this.u=O&&O.sendRawJson||!1,(O=O&&O.httpSessionIdParam)&&!m(O)&&(this.g.D=O,h=this.h,h!==null&&O in h&&(h=this.h,O in h&&delete h[O])),this.j=new ml(this)}_(mr,me),mr.prototype.m=function(){this.g.l=this.j,this.v&&(this.g.J=!0),this.g.connect(this.l,this.h||void 0)},mr.prototype.close=function(){wg(this.g)},mr.prototype.o=function(h){var O=this.g;if(typeof h=="string"){var C={};C.__data__=h,h=C}else this.u&&(C={},C.__data__=Kr(h),h=C);
1845O.i.push(new lt(O.Ya++,h)),O.G==3&&Od(O)},mr.prototype.N=function(){this.g.l=null,delete this.j,wg(this.g),delete this.g,mr.aa.N.call(this)};function cb(h){ia.call(this),h.__headers__&&(this.headers=h.__headers__,this.statusCode=h.__status__,delete h.__headers__,delete h.__status__);var O=h.__sm__;if(O){e:{for(const C in O){h=C;break e}h=void 0}(this.i=h)&&(h=this.i,O=O!==null&&h in O?O[h]:void 0),this.data=O}else this.data=h}_(cb,ia);function fb(){Xu.call(this),this.status=1}_(fb,Xu);function ml(h){this.g=h}_(ml,ub),ml.prototype.ua=function(){je(this.g,"a")},ml.prototype.ta=function(h){je(this.g,new cb(h))},ml.prototype.sa=function(h){je(this.g,new fb)},ml.prototype.ra=function(){je(this.g,"b")},Rd.prototype.createWebChannel=Rd.prototype.g,mr.prototype.send=mr.prototype.o,mr.prototype.open=mr.prototype.m,mr.prototype.close=mr.prototype.close,lO=function(){return new Rd},aO=function(){return sa()},oO=_i,Dy={mb:0,pb:1,qb:2,Jb:3,Ob:4,Lb:5,Mb:6,Kb:7,Ib:8,Nb:9,PROXY:10,NOPROXY:11,Gb:12,Cb:13,Db:14,Bb:15,Eb:16,Fb:17,ib:18,hb:19,jb:20},Ae.NO_ERROR=0,Ae.TIMEOUT=8,Ae.HTTP_ERROR=6,Rh=Ae,xe.COMPLETE="complete",sO=xe,ra.EventType=Wi,Wi.OPEN="a",Wi.CLOSE="b",Wi.ERROR="c",Wi.MESSAGE="d",me.prototype.listen=me.prototype.K,Pc=ra,Yt.prototype.listenOnce=Yt.prototype.L,Yt.prototype.getLastError=Yt.prototype.Ka,Yt.prototype.getLastErrorCode=Yt.prototype.Ba,Yt.prototype.getStatus=Yt.prototype.Z,Yt.prototype.getResponseJson=Yt.prototype.Oa,Yt.prototype.getResponseText=Yt.prototype.oa,Yt.prototype.send=Yt.prototype.ea,Yt.prototype.setWithCredentials=Yt.prototype.Ha,iO=Yt}).apply(typeof Jd<"u"?Jd:typeof self<"u"?self:typeof window<"u"?window:{});const Ix="@firebase/firestore";/** 1846 * @license 1847 * Copyright 2017 Google LLC 1848 * 1849 * Licensed under the Apache License, Version 2.0 (the "License"); 1850 * you may not use this file except in compliance with the License. 1851 * You may obtain a copy of the License at 1852 * 1853 * http://www.apache.org/licenses/LICENSE-2.0 1854 * 1855 * Unless required by applicable law or agreed to in writing, software 1856 * distributed under the License is distributed on an "AS IS" BASIS, 1857 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1858 * See the License for the specific language governing permissions and 1859 * limitations under the License. 1860 */class Dn{constructor(e){this.uid=e}isAuthenticated(){return this.uid!=null}toKey(){return this.isAuthenticated()?"uid:"+this.uid:"anonymous-user"}isEqual(e){return e.uid===this.uid}}Dn.UNAUTHENTICATED=new Dn(null),Dn.GOOGLE_CREDENTIALS=new Dn("google-credentials-uid"),Dn.FIRST_PARTY=new Dn("first-party-uid"),Dn.MOCK_USER=new Dn("mock-user");/** 1861 * @license 1862 * Copyright 2017 Google LLC 1863 * 1864 * Licensed under the Apache License, Version 2.0 (the "License"); 1865 * you may not use this file except in compliance with the License. 1866 * You may obtain a copy of the License at 1867 * 1868 * http://www.apache.org/licenses/LICENSE-2.0 1869 * 1870 * Unless required by applicable law or agreed to in writing, software 1871 * distributed under the License is distributed on an "AS IS" BASIS, 1872 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1873 * See the License for the specific language governing permissions and 1874 * limitations under the License. 1875 */let Lu="10.14.0";/** 1876 * @license 1877 * Copyright 2017 Google LLC 1878 * 1879 * Licensed under the Apache License, Version 2.0 (the "License"); 1880 * you may not use this file except in compliance with the License. 1881 * You may obtain a copy of the License at 1882 * 1883 * http://www.apache.org/licenses/LICENSE-2.0 1884 * 1885 * Unless required by applicable law or agreed to in writing, software 1886 * distributed under the License is distributed on an "AS IS" BASIS, 1887 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1888 * See the License for the specific language governing permissions and 1889 * limitations under the License. 1890 */const el=new Sm("@firebase/firestore");function yc(){return el.logLevel}function Oe(t,...e){if(el.logLevel<=at.DEBUG){const n=e.map(o1);el.debug(`Firestore (${Lu}): ${t}`,...n)}}function Ns(t,...e){if(el.logLevel<=at.ERROR){const n=e.map(o1);el.error(`Firestore (${Lu}): ${t}`,...n)}}function bu(t,...e){if(el.logLevel<=at.WARN){const n=e.map(o1);el.warn(`Firestore (${Lu}): ${t}`,...n)}}function o1(t){if(typeof t=="string")return t;try{/** 1891* @license 1892* Copyright 2020 Google LLC 1893* 1894* Licensed under the Apache License, Version 2.0 (the "License");
1895* you may not use this file except in compliance with the License. 1896* You may obtain a copy of the License at 1897* 1898* http://www.apache.org/licenses/LICENSE-2.0 1899* 1900* Unless required by applicable law or agreed to in writing, software 1901* distributed under the License is distributed on an "AS IS" BASIS, 1902* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1903* See the License for the specific language governing permissions and 1904* limitations under the License. 1905*/return function(n){return JSON.stringify(n)}(t)}catch{return t}}/** 1906 * @license 1907 * Copyright 2017 Google LLC 1908 * 1909 * Licensed under the Apache License, Version 2.0 (the "License"); 1910 * you may not use this file except in compliance with the License. 1911 * You may obtain a copy of the License at 1912 * 1913 * http://www.apache.org/licenses/LICENSE-2.0 1914 * 1915 * Unless required by applicable law or agreed to in writing, software 1916 * distributed under the License is distributed on an "AS IS" BASIS, 1917 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1918 * See the License for the specific language governing permissions and 1919 * limitations under the License. 1920 */function ze(t="Unexpected state"){const e=`FIRESTORE (${Lu}) INTERNAL ASSERTION FAILED: `+t;throw Ns(e),new Error(e)}function bt(t,e){t||ze()}function We(t,e){return t}/** 1921 * @license 1922 * Copyright 2017 Google LLC 1923 * 1924 * Licensed under the Apache License, Version 2.0 (the "License"); 1925 * you may not use this file except in compliance with the License. 1926 * You may obtain a copy of the License at 1927 * 1928 * http://www.apache.org/licenses/LICENSE-2.0 1929 * 1930 * Unless required by applicable law or agreed to in writing, software 1931 * distributed under the License is distributed on an "AS IS" BASIS, 1932 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1933 * See the License for the specific language governing permissions and 1934 * limitations under the License. 1935 */const le={OK:"ok",CANCELLED:"cancelled",UNKNOWN:"unknown",INVALID_ARGUMENT:"invalid-argument",DEADLINE_EXCEEDED:"deadline-exceeded",NOT_FOUND:"not-found",ALREADY_EXISTS:"already-exists",PERMISSION_DENIED:"permission-denied",UNAUTHENTICATED:"unauthenticated",RESOURCE_EXHAUSTED:"resource-exhausted",FAILED_PRECONDITION:"failed-precondition",ABORTED:"aborted",OUT_OF_RANGE:"out-of-range",UNIMPLEMENTED:"unimplemented",INTERNAL:"internal",UNAVAILABLE:"unavailable",DATA_LOSS:"data-loss"};class ke extends qr{constructor(e,n){super(e,n),this.code=e,this.message=n,this.toString=()=>`${this.name}: [code=${this.code}]: ${this.message}`}}/** 1936 * @license 1937 * Copyright 2017 Google LLC 1938 * 1939 * Licensed under the Apache License, Version 2.0 (the "License"); 1940 * you may not use this file except in compliance with the License. 1941 * You may obtain a copy of the License at 1942 * 1943 * http://www.apache.org/licenses/LICENSE-2.0 1944 * 1945 * Unless required by applicable law or agreed to in writing, software 1946 * distributed under the License is distributed on an "AS IS" BASIS, 1947 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1948 * See the License for the specific language governing permissions and 1949 * limitations under the License. 1950 */class bs{constructor(){this.promise=new Promise((e,n)=>{this.resolve=e,this.reject=n})}}/** 1951 * @license 1952 * Copyright 2017 Google LLC 1953 * 1954 * Licensed under the Apache License, Version 2.0 (the "License"); 1955 * you may not use this file except in compliance with the License. 1956 * You may obtain a copy of the License at 1957 * 1958 * http://www.apache.org/licenses/LICENSE-2.0 1959 * 1960 * Unless required by applicable law or agreed to in writing, software 1961 * distributed under the License is distributed on an "AS IS" BASIS, 1962 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1963 * See the License for the specific language governing permissions and 1964 * limitations under the License. 1965 */class uO{constructor(e,n){this.user=n,this.type="OAuth",this.headers=new Map,this.headers.set("Authorization",`Bearer ${e}`)}}class C5{getToken(){return Promise.resolve(null)}invalidateToken(){}start(e,n){e.enqueueRetryable(()=>n(Dn.UNAUTHENTICATED))}shutdown(){}}class N5{constructor(e){this.token=e,this.changeListener=null}getToken(){return Promise.resolve(this.token)}invalidateToken(){}start(e,n){this.changeListener=n,e.enqueueRetryable(()=>n(this.token.user))}shutdown(){this.changeListener=null}}class D5{constructor(e){this.t=e,this.currentUser=Dn.UNAUTHENTICATED,this.i=0,this.forceRefresh=!1,this.auth=null}start(e,n){bt(this.o===void 0);let r=this.i;const i=l=>this.i!==r?(r=this.i,n(l)):Promise.resolve();let s=new bs;this.o=()=>{this.i++,this.currentUser=this.u(),s.resolve(),s=new bs,e.enqueueRetryable(()=>i(this.currentUser))};const o=()=>{const l=s;e.enqueueRetryable(async()=>{await l.promise,await i(this.currentUser)})},a=l=>{Oe("FirebaseAuthCredentialsProvider","Auth detected"),this.auth=l,this.o&&(this.auth.addAuthTokenListener(this.o),o())};this.t.onInit(l=>a(l)),setTimeout(()=>{if(!this.auth){const l=this.t.getImmediate({optional:!0});l?a(l):(Oe("FirebaseAuthCredentialsProvider","Auth not yet detected"),s.resolve(),s=new bs)}},0),o()}getToken(){const e=this.i,n=this.forceRefresh;return this.forceRefresh=!1,this.auth?this.auth.getToken(n).then(r=>this.i!==e?(Oe("FirebaseAuthCredentialsProvider","getToken aborted due to token change."),this.getToken()):r?(bt(typeof r.accessToken=="string"),new uO(r.accessToken,this.currentUser)):null):Promise.resolve(null)}invalidateToken(){this.forceRefresh=!0}shutdown(){this.auth&&this.o&&this.auth.removeAuthTokenListener(this.o),this.o=void 0}u(){const e=this.auth&&this.auth.getUid();return bt(e===null||typeof e=="string"),new Dn(e)}}class M5{constructor(e,n,r){this.l=e,this.h=n,this.P=r,this.type="FirstParty",this.user=Dn.FIRST_PARTY,this.I=new Map}T(){return this.P?this.P():null}get headers(){this.I.set("X-Goog-AuthUser",this.l);const e=this.T();return e&&this.I.set("Authorization",e),this.h&&this.I.set("X-Goog-Iam-Authorization-Token",this.h),this.I}}class L5{constructor(e,n,r){this.l=e,this.h=n,this.P=r}getToken(){return Promise.resolve(new M5(this.l,this.h,this.P))}start(e,n){e.enqueueRetryable(()=>n(Dn.FIRST_PARTY))}shutdown(){}invalidateToken(){}}class j5{constructor(e){this.value=e,this.type="AppCheck",this.headers=new Map,e&&e.length>0&&this.headers.set("x-firebase-appcheck",this.value)}}class F5{constructor(e){this.A=e,this.forceRefresh=!1,this.appCheck=null,this.R=null}start(e,n){bt(this.o===void 0);const r=s=>{s.error!=null&&Oe("FirebaseAppCheckTokenProvider",`Error getting App Check token; using placeholder token instead. Error: ${s.error.message}`);const o=s.token!==this.R;return this.R=s.token,Oe("FirebaseAppCheckTokenProvider",`Received ${o?"new":"existing"} token.`),o?n(s.token):Promise.resolve()};this.o=s=>{e.enqueueRetryable(()=>r(s))};const i=s=>{Oe("FirebaseAppCheckTokenProvider","AppCheck detected"),this.appCheck=s,this.o&&this.appCheck.addTokenListener(this.o)};this.A.onInit(s=>i(s)),setTimeout(()=>{if(!this.appCheck){const s=this.A.getImmediate({optional:!0});s?i(s):Oe("FirebaseAppCheckTokenProvider","AppCheck not yet detected")}},0)}getToken(){const e=this.forceRefresh;return this.forceRefresh=!1,this.appCheck?this.appCheck.getToken(e).then(n=>n?(bt(typeof n.token=="string"),this.R=n.token,new j5(n.token)):null):Promise.resolve(null)}invalidateToken(){this.forceRefresh=!0}shutdown(){this.appCheck&&this.o&&this.appCheck.removeTokenListener(this.o),this.o=void 0}}/** 1966 * @license 1967 * Copyright 2020 Google LLC 1968 * 1969 * Licensed under the Apache License, Version 2.0 (the "License");
1970 * you may not use this file except in compliance with the License. 1971 * You may obtain a copy of the License at 1972 * 1973 * http://www.apache.org/licenses/LICENSE-2.0 1974 * 1975 * Unless required by applicable law or agreed to in writing, software 1976 * distributed under the License is distributed on an "AS IS" BASIS, 1977 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1978 * See the License for the specific language governing permissions and 1979 * limitations under the License. 1980 */function V5(t){const e=typeof self<"u"&&(self.crypto||self.msCrypto),n=new Uint8Array(t);if(e&&typeof e.getRandomValues=="function")e.getRandomValues(n);else for(let r=0;r<t;r++)n[r]=Math.floor(256*Math.random());return n}/** 1981 * @license 1982 * Copyright 2017 Google LLC 1983 * 1984 * Licensed under the Apache License, Version 2.0 (the "License"); 1985 * you may not use this file except in compliance with the License. 1986 * You may obtain a copy of the License at 1987 * 1988 * http://www.apache.org/licenses/LICENSE-2.0 1989 * 1990 * Unless required by applicable law or agreed to in writing, software 1991 * distributed under the License is distributed on an "AS IS" BASIS, 1992 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1993 * See the License for the specific language governing permissions and 1994 * limitations under the License. 1995 */class cO{static newId(){const e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=Math.floor(256/e.length)*e.length;let r="";for(;r.length<20;){const i=V5(40);for(let s=0;s<i.length;++s)r.length<20&&i[s]<n&&(r+=e.charAt(i[s]%e.length))}return r}}function pt(t,e){return t<e?-1:t>e?1:0}function Eu(t,e,n){return t.length===e.length&&t.every((r,i)=>n(r,e[i]))}/** 1996 * @license 1997 * Copyright 2017 Google LLC 1998 * 1999 * Licensed under the Apache License, Version 2.0 (the "License"); 2000 * you may not use this file except in compliance with the License. 2001 * You may obtain a copy of the License at 2002 * 2003 * http://www.apache.org/licenses/LICENSE-2.0 2004 * 2005 * Unless required by applicable law or agreed to in writing, software 2006 * distributed under the License is distributed on an "AS IS" BASIS, 2007 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2008 * See the License for the specific language governing permissions and 2009 * limitations under the License. 2010 */class pn{constructor(e,n){if(this.seconds=e,this.nanoseconds=n,n<0)throw new ke(le.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+n);if(n>=1e9)throw new ke(le.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+n);if(e<-62135596800)throw new ke(le.INVALID_ARGUMENT,"Timestamp seconds out of range: "+e);if(e>=253402300800)throw new ke(le.INVALID_ARGUMENT,"Timestamp seconds out of range: "+e)}static now(){return pn.fromMillis(Date.now())}static fromDate(e){return pn.fromMillis(e.getTime())}static fromMillis(e){const n=Math.floor(e/1e3),r=Math.floor(1e6*(e-1e3*n));return new pn(n,r)}toDate(){return new Date(this.toMillis())}toMillis(){return 1e3*this.seconds+this.nanoseconds/1e6}_compareTo(e){return this.seconds===e.seconds?pt(this.nanoseconds,e.nanoseconds):pt(this.seconds,e.seconds)}isEqual(e){return e.seconds===this.seconds&&e.nanoseconds===this.nanoseconds}toString(){return"Timestamp(seconds="+this.seconds+", nanoseconds="+this.nanoseconds+")"}toJSON(){return{seconds:this.seconds,nanoseconds:this.nanoseconds}}valueOf(){const e=this.seconds- -62135596800;return String(e).padStart(12,"0")+"."+String(this.nanoseconds).padStart(9,"0")}}/** 2011 * @license 2012 * Copyright 2017 Google LLC 2013 * 2014 * Licensed under the Apache License, Version 2.0 (the "License"); 2015 * you may not use this file except in compliance with the License. 2016 * You may obtain a copy of the License at 2017 * 2018 * http://www.apache.org/licenses/LICENSE-2.0 2019 * 2020 * Unless required by applicable law or agreed to in writing, software 2021 * distributed under the License is distributed on an "AS IS" BASIS, 2022 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2023 * See the License for the specific language governing permissions and 2024 * limitations under the License. 2025 */class He{constructor(e){this.timestamp=e}static fromTimestamp(e){return new He(e)}static min(){return new He(new pn(0,0))}static max(){return new He(new pn(253402300799,999999999))}compareTo(e){return this.timestamp._compareTo(e.timestamp)}isEqual(e){return this.timestamp.isEqual(e.timestamp)}toMicroseconds(){return 1e6*this.timestamp.seconds+this.timestamp.nanoseconds/1e3}toString(){return"SnapshotVersion("+this.timestamp.toString()+")"}toTimestamp(){return this.timestamp}}/** 2026 * @license 2027 * Copyright 2017 Google LLC 2028 * 2029 * Licensed under the Apache License, Version 2.0 (the "License");
2030 * you may not use this file except in compliance with the License. 2031 * You may obtain a copy of the License at 2032 * 2033 * http://www.apache.org/licenses/LICENSE-2.0 2034 * 2035 * Unless required by applicable law or agreed to in writing, software 2036 * distributed under the License is distributed on an "AS IS" BASIS, 2037 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2038 * See the License for the specific language governing permissions and 2039 * limitations under the License. 2040 */class Tf{constructor(e,n,r){n===void 0?n=0:n>e.length&&ze(),r===void 0?r=e.length-n:r>e.length-n&&ze(),this.segments=e,this.offset=n,this.len=r}get length(){return this.len}isEqual(e){return Tf.comparator(this,e)===0}child(e){const n=this.segments.slice(this.offset,this.limit());return e instanceof Tf?e.forEach(r=>{n.push(r)}):n.push(e),this.construct(n)}limit(){return this.offset+this.length}popFirst(e){return e=e===void 0?1:e,this.construct(this.segments,this.offset+e,this.length-e)}popLast(){return this.construct(this.segments,this.offset,this.length-1)}firstSegment(){return this.segments[this.offset]}lastSegment(){return this.get(this.length-1)}get(e){return this.segments[this.offset+e]}isEmpty(){return this.length===0}isPrefixOf(e){if(e.length<this.length)return!1;for(let n=0;n<this.length;n++)if(this.get(n)!==e.get(n))return!1;return!0}isImmediateParentOf(e){if(this.length+1!==e.length)return!1;for(let n=0;n<this.length;n++)if(this.get(n)!==e.get(n))return!1;return!0}forEach(e){for(let n=this.offset,r=this.limit();n<r;n++)e(this.segments[n])}toArray(){return this.segments.slice(this.offset,this.limit())}static comparator(e,n){const r=Math.min(e.length,n.length);for(let i=0;i<r;i++){const s=e.get(i),o=n.get(i);if(s<o)return-1;if(s>o)return 1}return e.length<n.length?-1:e.length>n.length?1:0}}class Lt extends Tf{construct(e,n,r){return new Lt(e,n,r)}canonicalString(){return this.toArray().join("/")}toString(){return this.canonicalString()}toUriEncodedString(){return this.toArray().map(encodeURIComponent).join("/")}static fromString(...e){const n=[];for(const r of e){if(r.indexOf("//")>=0)throw new ke(le.INVALID_ARGUMENT,`Invalid segment (${r}). Paths must not contain // in them.`);n.push(...r.split("/").filter(i=>i.length>0))}return new Lt(n)}static emptyPath(){return new Lt([])}}const U5=/^[_a-zA-Z][_a-zA-Z0-9]*$/;class xn extends Tf{construct(e,n,r){return new xn(e,n,r)}static isValidIdentifier(e){return U5.test(e)}canonicalString(){return this.toArray().map(e=>(e=e.replace(/\\/g,"\\\\").replace(/`/g,"\\`"),xn.isValidIdentifier(e)||(e="`"+e+"`"),e)).join(".")}toString(){return this.canonicalString()}isKeyField(){return this.length===1&&this.get(0)==="__name__"}static keyField(){return new xn(["__name__"])}static fromServerFormat(e){const n=[];let r="",i=0;const s=()=>
2040{if(r.length===0)throw new ke(le.INVALID_ARGUMENT,`Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`);n.push(r),r=""};let o=!1;for(;i<e.length;){const a=e[i];if(a==="\\"){if(i+1===e.length)throw new ke(le.INVALID_ARGUMENT,"Path has trailing escape character: "+e);const l=e[i+1];if(l!=="\\"&&l!=="."&&l!=="`")throw new ke(le.INVALID_ARGUMENT,"Path has invalid escape sequence: "+e);r+=l,i+=2}else a==="`"?(o=!o,i++):a!=="."||o?(r+=a,i++):(s(),i++)}if(s(),o)throw new ke(le.INVALID_ARGUMENT,"Unterminated ` in path: "+e);return new xn(n)}static emptyPath(){return new xn([])}}/** 2041 * @license 2042 * Copyright 2017 Google LLC 2043 * 2044 * Licensed under the Apache License, Version 2.0 (the "License"); 2045 * you may not use this file except in compliance with the License. 2046 * You may obtain a copy of the License at 2047 * 2048 * http://www.apache.org/licenses/LICENSE-2.0 2049 * 2050 * Unless required by applicable law or agreed to in writing, software 2051 * distributed under the License is distributed on an "AS IS" BASIS, 2052 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2053 * See the License for the specific language governing permissions and 2054 * limitations under the License. 2055 */class Le{constructor(e){this.path=e}static fromPath(e){return new Le(Lt.fromString(e))}static fromName(e){return new Le(Lt.fromString(e).popFirst(5))}static empty(){return new Le(Lt.emptyPath())}get collectionGroup(){return this.path.popLast().lastSegment()}hasCollectionId(e){return this.path.length>=2&&this.path.get(this.path.length-2)===e}getCollectionGroup(){return this.path.get(this.path.length-2)}getCollectionPath(){return this.path.popLast()}isEqual(e){return e!==null&&Lt.comparator(this.path,e.path)===0}toString(){return this.path.toString()}static comparator(e,n){return Lt.comparator(e.path,n.path)}static isDocumentKey(e){return e.length%2==0}static fromSegments(e){return new Le(new Lt(e.slice()))}}function $5(t,e){const n=t.toTimestamp().seconds,r=t.toTimestamp().nanoseconds+1,i=He.fromTimestamp(r===1e9?new pn(n+1,0):new pn(n,r));return new Bo(i,Le.empty(),e)}function B5(t){return new Bo(t.readTime,t.key,-1)}class Bo{constructor(e,n,r){this.readTime=e,this.documentKey=n,this.largestBatchId=r}static min(){return new Bo(He.min(),Le.empty(),-1)}static max(){return new Bo(He.max(),Le.empty(),-1)}}function z5(t,e){let n=t.readTime.compareTo(e.readTime);return n!==0?n:(n=Le.comparator(t.documentKey,e.documentKey),n!==0?n:pt(t.largestBatchId,e.largestBatchId))}/** 2056 * @license 2057 * Copyright 2020 Google LLC 2058 * 2059 * Licensed under the Apache License, Version 2.0 (the "License"); 2060 * you may not use this file except in compliance with the License. 2061 * You may obtain a copy of the License at 2062 * 2063 * http://www.apache.org/licenses/LICENSE-2.0 2064 * 2065 * Unless required by applicable law or agreed to in writing, software 2066 * distributed under the License is distributed on an "AS IS" BASIS, 2067 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2068 * See the License for the specific language governing permissions and 2069 * limitations under the License. 2070 */const q5="The current tab is not in the required state to perform this operation. It might be necessary to refresh the browser tab.";class H5{constructor(){this.onCommittedListeners=[]}addOnCommittedListener(e){this.onCommittedListeners.push(e)}raiseOnCommittedEvent(){this.onCommittedListeners.forEach(e=>e())}}/** 2071 * @license 2072 * Copyright 2017 Google LLC 2073 * 2074 * Licensed under the Apache License, Version 2.0 (the "License"); 2075 * you may not use this file except in compliance with the License. 2076 * You may obtain a copy of the License at 2077 * 2078 * http://www.apache.org/licenses/LICENSE-2.0 2079 * 2080 * Unless required by applicable law or agreed to in writing, software 2081 * distributed under the License is distributed on an "AS IS" BASIS, 2082 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2083 * See the License for the specific language governing permissions and 2084 * limitations under the License. 2085 */async function id(t){if(t.code!==le.FAILED_PRECONDITION||t.message!==q5)throw t;Oe("LocalStore","Unexpectedly lost primary lease")}/** 2086 * @license 2087 * Copyright 2017 Google LLC 2088 * 2089 * Licensed under the Apache License, Version 2.0 (the "License");
2090 * you may not use this file except in compliance with the License. 2091 * You may obtain a copy of the License at 2092 * 2093 * http://www.apache.org/licenses/LICENSE-2.0 2094 * 2095 * Unless required by applicable law or agreed to in writing, software 2096 * distributed under the License is distributed on an "AS IS" BASIS, 2097 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2098 * See the License for the specific language governing permissions and 2099 * limitations under the License. 2100 */class fe{constructor(e){this.nextCallback=null,this.catchCallback=null,this.result=void 0,this.error=void 0,this.isDone=!1,this.callbackAttached=!1,e(n=>{this.isDone=!0,this.result=n,this.nextCallback&&this.nextCallback(n)},n=>{this.isDone=!0,this.error=n,this.catchCallback&&this.catchCallback(n)})}catch(e){return this.next(void 0,e)}next(e,n){return this.callbackAttached&&ze(),this.callbackAttached=!0,this.isDone?this.error?this.wrapFailure(n,this.error):this.wrapSuccess(e,this.result):new fe((r,i)=>{this.nextCallback=s=>{this.wrapSuccess(e,s).next(r,i)},this.catchCallback=s=>{this.wrapFailure(n,s).next(r,i)}})}toPromise(){return new Promise((e,n)=>{this.next(e,n)})}wrapUserFunction(e){try{const n=e();return n instanceof fe?n:fe.resolve(n)}catch(n){return fe.reject(n)}}wrapSuccess(e,n){return e?this.wrapUserFunction(()=>e(n)):fe.resolve(n)}wrapFailure(e,n){return e?this.wrapUserFunction(()=>e(n)):fe.reject(n)}static resolve(e){return new fe((n,r)=>{n(e)})}static reject(e){return new fe((n,r)=>{r(e)})}static waitFor(e){return new fe((n,r)=>{let i=0,s=0,o=!1;e.forEach(a=>{++i,a.next(()=>{++s,o&&s===i&&n()},l=>r(l))}),o=!0,s===i&&n()})}static or(e){let n=fe.resolve(!1);for(const r of e)n=n.next(i=>i?fe.resolve(i):r());return n}static forEach(e,n){const r=[];return e.forEach((i,s)=>{r.push(n.call(this,i,s))}),this.waitFor(r)}static mapArray(e,n){return new fe((r,i)=>{const s=e.length,o=new Array(s);let a=0;for(let l=0;l<s;l++){const u=l;n(e[u]).next(c=>{o[u]=c,++a,a===s&&r(o)},c=>i(c))}})}static doWhile(e,n){return new fe((r,i)=>{const s=()=>{e()===!0?n().next(()=>{s()},i):r()};s()})}}function W5(t){const e=t.match(/Android ([\d.]+)/i),n=e?e[1].split(".").slice(0,2).join("."):"-1";return Number(n)}function sd(t){return t.name==="IndexedDbTransactionError"}/** 2101 * @license 2102 * Copyright 2018 Google LLC 2103 * 2104 * Licensed under the Apache License, Version 2.0 (the "License"); 2105 * you may not use this file except in compliance with the License. 2106 * You may obtain a copy of the License at 2107 * 2108 * http://www.apache.org/licenses/LICENSE-2.0 2109 * 2110 * Unless required by applicable law or agreed to in writing, software 2111 * distributed under the License is distributed on an "AS IS" BASIS, 2112 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2113 * See the License for the specific language governing permissions and 2114 * limitations under the License. 2115 */class a1{constructor(e,n){this.previousValue=e,n&&(n.sequenceNumberHandler=r=>this.ie(r),this.se=r=>n.writeSequenceNumber(r))}ie(e){return this.previousValue=Math.max(e,this.previousValue),this.previousValue}next(){const e=++this.previousValue;return this.se&&this.se(e),e}}a1.oe=-1;function Cm(t){return t==null}function Ap(t){return t===0&&1/t==-1/0}function G5(t){return typeof t=="number"&&Number.isInteger(t)&&!Ap(t)&&t<=Number.MAX_SAFE_INTEGER&&t>=Number.MIN_SAFE_INTEGER}/** 2116 * @license 2117 * Copyright 2017 Google LLC 2118 * 2119 * Licensed under the Apache License, Version 2.0 (the "License"); 2120 * you may not use this file except in compliance with the License. 2121 * You may obtain a copy of the License at 2122 * 2123 * http://www.apache.org/licenses/LICENSE-2.0 2124 * 2125 * Unless required by applicable law or agreed to in writing, software 2126 * distributed under the License is distributed on an "AS IS" BASIS, 2127 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2128 * See the License for the specific language governing permissions and 2129 * limitations under the License. 2130 */function Ox(t){let e=0;for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&e++;return e}function ul(t,e){for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&e(n,t[n])}function fO(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}/** 2131 * @license 2132 * Copyright 2017 Google LLC 2133 * 2134 * Licensed under the Apache License, Version 2.0 (the "License");
vendor: 5,116 bytes, lines 2135-2145
2135 * you may not use this file except in compliance with the License. 2136 * You may obtain a copy of the License at 2137 * 2138 * http://www.apache.org/licenses/LICENSE-2.0 2139 * 2140 * Unless required by applicable law or agreed to in writing, software 2141 * distributed under the License is distributed on an "AS IS" BASIS, 2142 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2143 * See the License for the specific language governing permissions and 2144 * limitations under the License. 2145 */class Kt{constructor(e,n){this.comparator=e,this.root=n||En.EMPTY}insert(e,n){return new Kt(this.comparator,this.root.insert(e,n,this.comparator).copy(null,null,En.BLACK,null,null))}remove(e){return new Kt(this.comparator,this.root.remove(e,this.comparator).copy(null,null,En.BLACK,null,null))}get(e){let n=this.root;for(;!n.isEmpty();){const r=this.comparator(e,n.key);if(r===0)return n.value;r<0?n=n.left:r>0&&(n=n.right)}return null}indexOf(e){let n=0,r=this.root;for(;!r.isEmpty();){const i=this.comparator(e,r.key);if(i===0)return n+r.left.size;i<0?r=r.left:(n+=r.left.size+1,r=r.right)}return-1}isEmpty(){return this.root.isEmpty()}get size(){return this.root.size}minKey(){return this.root.minKey()}maxKey(){return this.root.maxKey()}inorderTraversal(e){return this.root.inorderTraversal(e)}forEach(e){this.inorderTraversal((n,r)=>(e(n,r),!1))}toString(){const e=[];return this.inorderTraversal((n,r)=>(e.push(`${n}:${r}`),!1)),`{${e.join(", ")}}`}reverseTraversal(e){return this.root.reverseTraversal(e)}getIterator(){return new eh(this.root,null,this.comparator,!1)}getIteratorFrom(e){return new eh(this.root,e,this.comparator,!1)}getReverseIterator(){return new eh(this.root,null,this.comparator,!0)}getReverseIteratorFrom(e){return new eh(this.root,e,this.comparator,!0)}}class eh{constructor(e,n,r,i){this.isReverse=i,this.nodeStack=[];let s=1;for(;!e.isEmpty();)if(s=n?r(e.key,n):1,n&&i&&(s*=-1),s<0)e=this.isReverse?e.left:e.right;else{if(s===0){this.nodeStack.push(e);break}this.nodeStack.push(e),e=this.isReverse?e.right:e.left}}getNext(){let e=this.nodeStack.pop();const n={key:e.key,value:e.value};if(this.isReverse)for(e=e.left;!e.isEmpty();)this.nodeStack.push(e),e=e.right;else for(e=e.right;!e.isEmpty();)this.nodeStack.push(e),e=e.left;return n}hasNext(){return this.nodeStack.length>0}peek(){if(this.nodeStack.length===0)return null;const e=this.nodeStack[this.nodeStack.length-1];return{key:e.key,value:e.value}}}class En{constructor(e,n,r,i,s){this.key=e,this.value=n,this.color=r??En.RED,this.left=i??En.EMPTY,this.right=s??En.EMPTY,this.size=this.left.size+1+this.right.size}copy(e,n,r,i,s){return new En(e??this.key,n??this.value,r??this.color,i??this.left,s??this.right)}isEmpty(){return!1}inorderTraversal(e){return this.left.inorderTraversal(e)||e(this.key,this.value)||this.right.inorderTraversal(e)}reverseTraversal(e){return this.right.reverseTraversal(e)||e(this.key,this.value)||this.left.reverseTraversal(e)}min(){return this.left.isEmpty()?this:this.left.min()}minKey(){return this.min().key}maxKey(){return this.right.isEmpty()?this.key:this.right.maxKey()}insert(e,n,r){let i=this;const s=r(e,i.key);return i=s<0?i.copy(null,null,null,i.left.insert(e,n,r),null):s===0?i.copy(null,n,null,null,null):i.copy(null,null,null,null,i.right.insert(e,n,r)),i.fixUp()}removeMin(){if(this.left.isEmpty())return En.EMPTY;let e=this;return e.left.isRed()||e.left.left.isRed()||(e=e.moveRedLeft()),e=e.copy(null,null,null,e.left.removeMin(),null),e.fixUp()}remove(e,n){let r,i=this;if(n(e,i.key)<0)i.left.isEmpty()||i.left.isRed()||i.left.left.isRed()||(i=i.moveRedLeft()),i=i.copy(null,null,null,i.left.remove(e,n),null);else{if(i.left.isRed()&&(i=i.rotateRight()),i.right.isEmpty()||i.right.isRed()||i.right.left.isRed()||(i=i.moveRedRight()),n(e,i.key)===0){if(i.right.isEmpty())return En.EMPTY;r=i.right.min(),i=i.copy(r.key,r.value,null,null,i.right.removeMin())}i=i.copy(null,null,null,null,i.right.remove(e,n))}return i.fixUp()}isRed(){return this.color}fixUp(){let e=this;return e.right.isRed()&&!e.left.isRed()&&(e=e.rotateLeft()),e.left.isRed()&&e.left.left.isRed()&&(e=e.rotateRight()),e.left.isRed()&&e.right.isRed()&&(e=e.colorFlip()),e}moveRedLeft(){let e=this.colorFlip();return e.right.left.isRed()&&(e=e.copy(null,null,null,null,e.right.rotateRight()),e=e.rotateLeft(),e=e.colorFlip()),e}moveRedRight(){let e=this.colorFlip();return e.left.left.isRed()&&(e=e.rotateRight(),e=e.colorFlip()),e}rotateLeft(){const e=this.copy(null,null,En.RED,null,this.right.left);return this.right.copy(null,null,this.color,e,null)}rotateRight(){const e=this.copy(null,null,En.RED,this.left.right,null);return this.left.copy(null,null,this.color,null,e)}colorFlip(){const e=this.left.copy(null,null,!this.left.color,null,null),n=this.right.copy(null,null,!this.right.color,null,null);return this.copy(null,null,!this.color,e,n)}checkMaxDepth(){const e=this.check();return Math.pow(2,e)<=this.size+1}check(){if(this.isRed()&&this.left.isRed()||this.right.isRed())throw ze();const e=this.left.check();if(e!==this.right.check())throw ze();return e+(this.isRed()?0:1)}}En.EMPTY=null,En.RED=!0,En.BLACK=!1;
2145En.EMPTY=new class{constructor(){this.size=0}get key(){throw ze()}get value(){throw ze()}get color(){throw ze()}get left(){throw ze()}get right(){throw ze()}copy(e,n,r,i,s){return this}insert(e,n,r){return new En(e,n)}remove(e,n){return this}isEmpty(){return!0}inorderTraversal(e){return!1}reverseTraversal(e){return!1}minKey(){return null}maxKey(){return null}isRed(){return!1}checkMaxDepth(){return!0}check(){return 0}};/** 2146 * @license 2147 * Copyright 2017 Google LLC 2148 * 2149 * Licensed under the Apache License, Version 2.0 (the "License"); 2150 * you may not use this file except in compliance with the License. 2151 * You may obtain a copy of the License at 2152 * 2153 * http://www.apache.org/licenses/LICENSE-2.0 2154 * 2155 * Unless required by applicable law or agreed to in writing, software 2156 * distributed under the License is distributed on an "AS IS" BASIS, 2157 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2158 * See the License for the specific language governing permissions and 2159 * limitations under the License. 2160 */class Sn{constructor(e){this.comparator=e,this.data=new Kt(this.comparator)}has(e){return this.data.get(e)!==null}first(){return this.data.minKey()}last(){return this.data.maxKey()}get size(){return this.data.size}indexOf(e){return this.data.indexOf(e)}forEach(e){this.data.inorderTraversal((n,r)=>(e(n),!1))}forEachInRange(e,n){const r=this.data.getIteratorFrom(e[0]);for(;r.hasNext();){const i=r.getNext();if(this.comparator(i.key,e[1])>=0)return;n(i.key)}}forEachWhile(e,n){let r;for(r=n!==void 0?this.data.getIteratorFrom(n):this.data.getIterator();r.hasNext();)if(!e(r.getNext().key))return}firstAfterOrEqual(e){const n=this.data.getIteratorFrom(e);return n.hasNext()?n.getNext().key:null}getIterator(){return new Px(this.data.getIterator())}getIteratorFrom(e){return new Px(this.data.getIteratorFrom(e))}add(e){return this.copy(this.data.remove(e).insert(e,!0))}delete(e){return this.has(e)?this.copy(this.data.remove(e)):this}isEmpty(){return this.data.isEmpty()}unionWith(e){let n=this;return n.size<e.size&&(n=e,e=this),e.forEach(r=>{n=n.add(r)}),n}isEqual(e){if(!(e instanceof Sn)||this.size!==e.size)return!1;const n=this.data.getIterator(),r=e.data.getIterator();for(;n.hasNext();){const i=n.getNext().key,s=r.getNext().key;if(this.comparator(i,s)!==0)return!1}return!0}toArray(){const e=[];return this.forEach(n=>{e.push(n)}),e}toString(){const e=[];return this.forEach(n=>e.push(n)),"SortedSet("+e.toString()+")"}copy(e){const n=new Sn(this.comparator);return n.data=e,n}}class Px{constructor(e){this.iter=e}getNext(){return this.iter.getNext().key}hasNext(){return this.iter.hasNext()}}/** 2161 * @license 2162 * Copyright 2020 Google LLC 2163 * 2164 * Licensed under the Apache License, Version 2.0 (the "License"); 2165 * you may not use this file except in compliance with the License. 2166 * You may obtain a copy of the License at 2167 * 2168 * http://www.apache.org/licenses/LICENSE-2.0 2169 * 2170 * Unless required by applicable law or agreed to in writing, software 2171 * distributed under the License is distributed on an "AS IS" BASIS, 2172 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2173 * See the License for the specific language governing permissions and 2174 * limitations under the License. 2175 */class xr{constructor(e){this.fields=e,e.sort(xn.comparator)}static empty(){return new xr([])}unionWith(e){let n=new Sn(xn.comparator);for(const r of this.fields)n=n.add(r);for(const r of e)n=n.add(r);return new xr(n.toArray())}covers(e){for(const n of this.fields)if(n.isPrefixOf(e))return!0;return!1}isEqual(e){return Eu(this.fields,e.fields,(n,r)=>n.isEqual(r))}}/** 2176 * @license 2177 * Copyright 2023 Google LLC 2178 * 2179 * Licensed under the Apache License, Version 2.0 (the "License"); 2180 * you may not use this file except in compliance with the License. 2181 * You may obtain a copy of the License at 2182 * 2183 * http://www.apache.org/licenses/LICENSE-2.0 2184 * 2185 * Unless required by applicable law or agreed to in writing, software 2186 * distributed under the License is distributed on an "AS IS" BASIS, 2187 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2188 * See the License for the specific language governing permissions and 2189 * limitations under the License.
2190 */class dO extends Error{constructor(){super(...arguments),this.name="Base64DecodeError"}}/** 2191 * @license 2192 * Copyright 2020 Google LLC 2193 * 2194 * Licensed under the Apache License, Version 2.0 (the "License"); 2195 * you may not use this file except in compliance with the License. 2196 * You may obtain a copy of the License at 2197 * 2198 * http://www.apache.org/licenses/LICENSE-2.0 2199 * 2200 * Unless required by applicable law or agreed to in writing, software 2201 * distributed under the License is distributed on an "AS IS" BASIS, 2202 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2203 * See the License for the specific language governing permissions and 2204 * limitations under the License. 2205 */class An{constructor(e){this.binaryString=e}static fromBase64String(e){const n=function(i){try{return atob(i)}catch(s){throw typeof DOMException<"u"&&s instanceof DOMException?new dO("Invalid base64 string: "+s):s}}(e);return new An(n)}static fromUint8Array(e){const n=function(i){let s="";for(let o=0;o<i.length;++o)s+=String.fromCharCode(i[o]);return s}(e);return new An(n)}[Symbol.iterator](){let e=0;return{next:()=>e<this.binaryString.length?{value:this.binaryString.charCodeAt(e++),done:!1}:{value:void 0,done:!0}}}toBase64(){return function(n){return btoa(n)}(this.binaryString)}toUint8Array(){return function(n){const r=new Uint8Array(n.length);for(let i=0;i<n.length;i++)r[i]=n.charCodeAt(i);return r}(this.binaryString)}approximateByteSize(){return 2*this.binaryString.length}compareTo(e){return pt(this.binaryString,e.binaryString)}isEqual(e){return this.binaryString===e.binaryString}}An.EMPTY_BYTE_STRING=new An("");const K5=new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);function zo(t){if(bt(!!t),typeof t=="string"){let e=0;const n=K5.exec(t);if(bt(!!n),n[1]){let i=n[1];i=(i+"000000000").substr(0,9),e=Number(i)}const r=new Date(t);return{seconds:Math.floor(r.getTime()/1e3),nanos:e}}return{seconds:tn(t.seconds),nanos:tn(t.nanos)}}function tn(t){return typeof t=="number"?t:typeof t=="string"?Number(t):0}function tl(t){return typeof t=="string"?An.fromBase64String(t):An.fromUint8Array(t)}/** 2206 * @license 2207 * Copyright 2020 Google LLC 2208 * 2209 * Licensed under the Apache License, Version 2.0 (the "License"); 2210 * you may not use this file except in compliance with the License. 2211 * You may obtain a copy of the License at 2212 * 2213 * http://www.apache.org/licenses/LICENSE-2.0 2214 * 2215 * Unless required by applicable law or agreed to in writing, software 2216 * distributed under the License is distributed on an "AS IS" BASIS, 2217 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2218 * See the License for the specific language governing permissions and 2219 * limitations under the License. 2220 */function l1(t){var e,n;return((n=(((e=t==null?void 0:t.mapValue)===null||e===void 0?void 0:e.fields)||{}).__type__)===null||n===void 0?void 0:n.stringValue)==="server_timestamp"}function u1(t){const e=t.mapValue.fields.__previous_value__;return l1(e)?u1(e):e}function Sf(t){const e=zo(t.mapValue.fields.__local_write_time__.timestampValue);return new pn(e.seconds,e.nanos)}/** 2221 * @license 2222 * Copyright 2017 Google LLC 2223 * 2224 * Licensed under the Apache License, Version 2.0 (the "License"); 2225 * you may not use this file except in compliance with the License. 2226 * You may obtain a copy of the License at 2227 * 2228 * http://www.apache.org/licenses/LICENSE-2.0 2229 * 2230 * Unless required by applicable law or agreed to in writing, software 2231 * distributed under the License is distributed on an "AS IS" BASIS, 2232 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2233 * See the License for the specific language governing permissions and 2234 * limitations under the License. 2235 */class Y5{constructor(e,n,r,i,s,o,a,l,u){this.databaseId=e,this.appId=n,this.persistenceKey=r,this.host=i,this.ssl=s,this.forceLongPolling=o,this.autoDetectLongPolling=a,this.longPollingOptions=l,this.useFetchStreams=u}}class kf{constructor(e,n){this.projectId=e,this.database=n||"(default)"}static empty(){return new kf("","")}get isDefaultDatabase(){return this.database==="(default)"}isEqual(e){return e instanceof kf&&e.projectId===this.projectId&&e.database===this.database}}/** 2236 * @license 2237 * Copyright 2020 Google LLC 2238 * 2239 * Licensed under the Apache License, Version 2.0 (the "License");
2240 * you may not use this file except in compliance with the License. 2241 * You may obtain a copy of the License at 2242 * 2243 * http://www.apache.org/licenses/LICENSE-2.0 2244 * 2245 * Unless required by applicable law or agreed to in writing, software 2246 * distributed under the License is distributed on an "AS IS" BASIS, 2247 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2248 * See the License for the specific language governing permissions and 2249 * limitations under the License. 2250 */const th={mapValue:{}};function nl(t){return"nullValue"in t?0:"booleanValue"in t?1:"integerValue"in t||"doubleValue"in t?2:"timestampValue"in t?3:"stringValue"in t?5:"bytesValue"in t?6:"referenceValue"in t?7:"geoPointValue"in t?8:"arrayValue"in t?9:"mapValue"in t?l1(t)?4:Z5(t)?9007199254740991:Q5(t)?10:11:ze()}function Vi(t,e){if(t===e)return!0;const n=nl(t);if(n!==nl(e))return!1;switch(n){case 0:case 9007199254740991:return!0;case 1:return t.booleanValue===e.booleanValue;case 4:return Sf(t).isEqual(Sf(e));case 3:return function(i,s){if(typeof i.timestampValue=="string"&&typeof s.timestampValue=="string"&&i.timestampValue.length===s.timestampValue.length)return i.timestampValue===s.timestampValue;const o=zo(i.timestampValue),a=zo(s.timestampValue);return o.seconds===a.seconds&&o.nanos===a.nanos}(t,e);case 5:return t.stringValue===e.stringValue;case 6:return function(i,s){return tl(i.bytesValue).isEqual(tl(s.bytesValue))}(t,e);case 7:return t.referenceValue===e.referenceValue;case 8:return function(i,s){return tn(i.geoPointValue.latitude)===tn(s.geoPointValue.latitude)&&tn(i.geoPointValue.longitude)===tn(s.geoPointValue.longitude)}(t,e);case 2:return function(i,s){if("integerValue"in i&&"integerValue"in s)return tn(i.integerValue)===tn(s.integerValue);if("doubleValue"in i&&"doubleValue"in s){const o=tn(i.doubleValue),a=tn(s.doubleValue);return o===a?Ap(o)===Ap(a):isNaN(o)&&isNaN(a)}return!1}(t,e);case 9:return Eu(t.arrayValue.values||[],e.arrayValue.values||[],Vi);case 10:case 11:return function(i,s){const o=i.mapValue.fields||{},a=s.mapValue.fields||{};if(Ox(o)!==Ox(a))return!1;for(const l in o)if(o.hasOwnProperty(l)&&(a[l]===void 0||!Vi(o[l],a[l])))return!1;return!0}(t,e);default:return ze()}}function Af(t,e){return(t.values||[]).find(n=>Vi(n,e))!==void 0}function xu(t,e){if(t===e)return 0;const n=nl(t),r=nl(e);if(n!==r)return pt(n,r);switch(n){case 0:case 9007199254740991:return 0;case 1:return pt(t.booleanValue,e.booleanValue);case 2:return function(s,o){const a=tn(s.integerValue||s.doubleValue),l=tn(o.integerValue||o.doubleValue);return a<l?-1:a>l?1:a===l?0:isNaN(a)?isNaN(l)?0:-1:1}(t,e);case 3:return Rx(t.timestampValue,e.timestampValue);case 4:return Rx(Sf(t),Sf(e));case 5:return pt(t.stringValue,e.stringValue);case 6:return function(s,o){const a=tl(s),l=tl(o);return a.compareTo(l)}(t.bytesValue,e.bytesValue);case 7:return function(s,o){const a=s.split("/"),l=o.split("/");for(let u=0;u<a.length&&u<l.length;u++){const c=pt(a[u],l[u]);if(c!==0)return c}return pt(a.length,l.length)}(t.referenceValue,e.referenceValue);case 8:return function(s,o){const a=pt(tn(s.latitude),tn(o.latitude));return a!==0?a:pt(tn(s.longitude),tn(o.longitude))}(t.geoPointValue,e.geoPointValue);case 9:return Cx(t.arrayValue,e.arrayValue);case 10:return function(s,o){var a,l,u,c;const d=s.fields||{},f=o.fields||{},p=(a=d.value)===null||a===void 0?void 0:a.arrayValue,_=(l=f.value)===null||l===void 0?void 0:l.arrayValue,y=pt(((u=p==null?void 0:p.values)===null||u===void 0?void 0:u.length)||0,((c=_==null?void 0:_.values)===null||c===void 0?void 0:c.length)||0);return y!==0?y:Cx(p,_)}(t.mapValue,e.mapValue);case 11:return function(s,o){if(s===th.mapValue&&o===th.mapValue)return 0;if(s===th.mapValue)return 1;if(o===th.mapValue)return-1;const a=s.fields||{},l=Object.keys(a),u=o.fields||{},c=Object.keys(u);l.sort(),c.sort();for(let d=0;d<l.length&&d<c.length;++d){const f=pt(l[d],c[d]);if(f!==0)return f;const p=xu(a[l[d]],u[c[d]]);if(p!==0)return p}return pt(l.length,c.length)}(t.mapValue,e.mapValue);default:throw ze()}}function Rx(t,e){if(typeof t=="string"&&typeof e=="string"&&t.length===e.length)return pt(t,e);const n=zo(t),r=zo(e),i=pt(n.seconds,r.seconds);return i!==0?i:pt(n.nanos,r.nanos)}function Cx(t,e){const n=t.values||[],r=e.values||[];for(let i=0;i<n.length&&i<r.length;++i){const s=xu(n[i],r[i]);if(s)return s}return pt(n.length,r.length)}function Tu(t){return My(t)}function My(t){return"nullValue"in t?"null":"booleanValue"in t?""+t.booleanValue:"integerValue"in t?""+t.integerValue:"doubleValue"in t?""+t.doubleValue:"timestampValue"in t?function(n){const r=zo(n);return`time(${r.seconds},${r.nanos})`}(t.timestampValue):"stringValue"in t?t.stringValue:"bytesValue"in t?function(n){return tl(n).toBase64()}(t.bytesValue):"referenceValue"in t?function(n){return Le.fromName(n).toString()}(t.referenceValue):"geoPointValue"in t?function(n){return`geo(${n.latitude},${n.longitude})`}(t.geoPointValue):"arrayValue"in t?function(n){let r="[",i=!0;for(const s of n.values||[])i?i=!1:r+=",",r+=My(s);return r+"]"}(t.arrayValue):"mapValue"in t?function(n){const r=Object.keys(n.fields||{}).sort();let i="{",s=!0;for(const o of r)s?s=!1:i+=",",i+=`${o}:${My(n.fields[o])}`;return i+"}"}(t.mapValue):ze()}function Nx(t,e){return{referenceValue:`projects/${t.projectId}/databases/${t.database}/documents/${e.path.canonicalString()}`}}function Ly(t){return!!t&&"integerValue"in t}function c1(t){return!!t&&"arrayValue"in t}function Dx(t){return!!t&&"nullValue"in t}function Mx(t){return!!t&&"doubleValue"in t&&isNaN(Number(t.doubleValue))}function Ch(t){return!!t&&"mapValue"in t}function Q5(t){var e,n;return((n=(((e=t==null?void 0:t.mapValue)===null||e===void 0?void 0:e.fields)||{}).__type__)===null||n===void 0?void 0:n.stringValue)==="__vector__"}function Gc(t){if(t.geoPointValue)return{geoPointValue:Object.assign({},t.geoPointValue)};if(t.timestampValue&&typeof t.timestampValue=="object")return{timestampValue:Object.assign({},t.timestampValue)};if(t.mapValue){const e={mapValue:{fields:{}}};return ul(t.mapValue.fields,(n,r)=>e.mapValue.fields[n]=Gc(r)),e}if(t.arrayValue){const e={arrayValue:{values:[]}};for(let n=0;n<(t.arrayValue.values||[]).length;++n)e.arrayValue.values[n]=Gc(t.arrayValue.values[n]);return e}return Object.assign({},t)}function Z5(t){return(((t.mapValue||{}).fields||{}).__type__||{}).stringValue==="__max__"}/** 2251 * @license 2252 * Copyright 2017 Google LLC 2253 * 2254 * Licensed under the Apache License, Version 2.0 (the "License");
2255 * you may not use this file except in compliance with the License. 2256 * You may obtain a copy of the License at 2257 * 2258 * http://www.apache.org/licenses/LICENSE-2.0 2259 * 2260 * Unless required by applicable law or agreed to in writing, software 2261 * distributed under the License is distributed on an "AS IS" BASIS, 2262 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2263 * See the License for the specific language governing permissions and 2264 * limitations under the License. 2265 */class ar{constructor(e){this.value=e}static empty(){return new ar({mapValue:{}})}field(e){if(e.isEmpty())return this.value;{let n=this.value;for(let r=0;r<e.length-1;++r)if(n=(n.mapValue.fields||{})[e.get(r)],!Ch(n))return null;return n=(n.mapValue.fields||{})[e.lastSegment()],n||null}}set(e,n){this.getFieldsMap(e.popLast())[e.lastSegment()]=Gc(n)}setAll(e){let n=xn.emptyPath(),r={},i=[];e.forEach((o,a)=>{if(!n.isImmediateParentOf(a)){const l=this.getFieldsMap(n);this.applyChanges(l,r,i),r={},i=[],n=a.popLast()}o?r[a.lastSegment()]=Gc(o):i.push(a.lastSegment())});const s=this.getFieldsMap(n);this.applyChanges(s,r,i)}delete(e){const n=this.field(e.popLast());Ch(n)&&n.mapValue.fields&&delete n.mapValue.fields[e.lastSegment()]}isEqual(e){return Vi(this.value,e.value)}getFieldsMap(e){let n=this.value;n.mapValue.fields||(n.mapValue={fields:{}});for(let r=0;r<e.length;++r){let i=n.mapValue.fields[e.get(r)];Ch(i)&&i.mapValue.fields||(i={mapValue:{fields:{}}},n.mapValue.fields[e.get(r)]=i),n=i}return n.mapValue.fields}applyChanges(e,n,r){ul(n,(i,s)=>e[i]=s);for(const i of r)delete e[i]}clone(){return new ar(Gc(this.value))}}function hO(t){const e=[];return ul(t.fields,(n,r)=>{const i=new xn([n]);if(Ch(r)){const s=hO(r.mapValue).fields;
vendor: 4,180 bytes, lines 2265-2305
2265if(s.length===0)e.push(i);else for(const o of s)e.push(i.child(o))}else e.push(i)}),new xr(e)}/** 2266 * @license 2267 * Copyright 2017 Google LLC 2268 * 2269 * Licensed under the Apache License, Version 2.0 (the "License"); 2270 * you may not use this file except in compliance with the License. 2271 * You may obtain a copy of the License at 2272 * 2273 * http://www.apache.org/licenses/LICENSE-2.0 2274 * 2275 * Unless required by applicable law or agreed to in writing, software 2276 * distributed under the License is distributed on an "AS IS" BASIS, 2277 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2278 * See the License for the specific language governing permissions and 2279 * limitations under the License. 2280 */class Ln{constructor(e,n,r,i,s,o,a){this.key=e,this.documentType=n,this.version=r,this.readTime=i,this.createTime=s,this.data=o,this.documentState=a}static newInvalidDocument(e){return new Ln(e,0,He.min(),He.min(),He.min(),ar.empty(),0)}static newFoundDocument(e,n,r,i){return new Ln(e,1,n,He.min(),r,i,0)}static newNoDocument(e,n){return new Ln(e,2,n,He.min(),He.min(),ar.empty(),0)}static newUnknownDocument(e,n){return new Ln(e,3,n,He.min(),He.min(),ar.empty(),2)}convertToFoundDocument(e,n){return!this.createTime.isEqual(He.min())||this.documentType!==2&&this.documentType!==0||(this.createTime=e),this.version=e,this.documentType=1,this.data=n,this.documentState=0,this}convertToNoDocument(e){return this.version=e,this.documentType=2,this.data=ar.empty(),this.documentState=0,this}convertToUnknownDocument(e){return this.version=e,this.documentType=3,this.data=ar.empty(),this.documentState=2,this}setHasCommittedMutations(){return this.documentState=2,this}setHasLocalMutations(){return this.documentState=1,this.version=He.min(),this}setReadTime(e){return this.readTime=e,this}get hasLocalMutations(){return this.documentState===1}get hasCommittedMutations(){return this.documentState===2}get hasPendingWrites(){return this.hasLocalMutations||this.hasCommittedMutations}isValidDocument(){return this.documentType!==0}isFoundDocument(){return this.documentType===1}isNoDocument(){return this.documentType===2}isUnknownDocument(){return this.documentType===3}isEqual(e){return e instanceof Ln&&this.key.isEqual(e.key)&&this.version.isEqual(e.version)&&this.documentType===e.documentType&&this.documentState===e.documentState&&this.data.isEqual(e.data)}mutableCopy(){return new Ln(this.key,this.documentType,this.version,this.readTime,this.createTime,this.data.clone(),this.documentState)}toString(){return`Document(${this.key}, ${this.version}, ${JSON.stringify(this.data.value)}, {createTime: ${this.createTime}}), {documentType: ${this.documentType}}), {documentState: ${this.documentState}})`}}/** 2281 * @license 2282 * Copyright 2022 Google LLC 2283 * 2284 * Licensed under the Apache License, Version 2.0 (the "License"); 2285 * you may not use this file except in compliance with the License. 2286 * You may obtain a copy of the License at 2287 * 2288 * http://www.apache.org/licenses/LICENSE-2.0 2289 * 2290 * Unless required by applicable law or agreed to in writing, software 2291 * distributed under the License is distributed on an "AS IS" BASIS, 2292 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2293 * See the License for the specific language governing permissions and 2294 * limitations under the License. 2295 */class Ip{constructor(e,n){this.position=e,this.inclusive=n}}function Lx(t,e,n){let r=0;for(let i=0;i<t.position.length;i++){const s=e[i],o=t.position[i];if(s.field.isKeyField()?r=Le.comparator(Le.fromName(o.referenceValue),n.key):r=xu(o,n.data.field(s.field)),s.dir==="desc"&&(r*=-1),r!==0)break}return r}function jx(t,e){if(t===null)return e===null;if(e===null||t.inclusive!==e.inclusive||t.position.length!==e.position.length)return!1;for(let n=0;n<t.position.length;n++)if(!Vi(t.position[n],e.position[n]))return!1;return!0}/** 2296 * @license 2297 * Copyright 2022 Google LLC 2298 * 2299 * Licensed under the Apache License, Version 2.0 (the "License"); 2300 * you may not use this file except in compliance with the License. 2301 * You may obtain a copy of the License at 2302 * 2303 * http://www.apache.org/licenses/LICENSE-2.0 2304 * 2305 * Unless required by applicable law or agreed to in writing, softw
2305are 2306 * distributed under the License is distributed on an "AS IS" BASIS, 2307 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2308 * See the License for the specific language governing permissions and 2309 * limitations under the License. 2310 */class Op{constructor(e,n="asc"){this.field=e,this.dir=n}}function X5(t,e){return t.dir===e.dir&&t.field.isEqual(e.field)}/** 2311 * @license 2312 * Copyright 2022 Google LLC 2313 * 2314 * Licensed under the Apache License, Version 2.0 (the "License"); 2315 * you may not use this file except in compliance with the License. 2316 * You may obtain a copy of the License at 2317 * 2318 * http://www.apache.org/licenses/LICENSE-2.0 2319 * 2320 * Unless required by applicable law or agreed to in writing, software 2321 * distributed under the License is distributed on an "AS IS" BASIS, 2322 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2323 * See the License for the specific language governing permissions and 2324 * limitations under the License. 2325 */class pO{}class un extends pO{constructor(e,n,r){super(),this.field=e,this.op=n,this.value=r}static create(e,n,r){return e.isKeyField()?n==="in"||n==="not-in"?this.createKeyFieldInFilter(e,n,r):new e9(e,n,r):n==="array-contains"?new r9(e,r):n==="in"?new i9(e,r):n==="not-in"?new s9(e,r):n==="array-contains-any"?new o9(e,r):new un(e,n,r)}static createKeyFieldInFilter(e,n,r){return n==="in"?new t9(e,r):new n9(e,r)}matches(e){const n=e.data.field(this.field);return this.op==="!="?n!==null&&this.matchesComparison(xu(n,this.value)):n!==null&&nl(this.value)===nl(n)&&this.matchesComparison(xu(n,this.value))}matchesComparison(e){switch(this.op){case"<":return e<0;case"<=":return e<=0;case"==":return e===0;case"!=":return e!==0;case">":return e>0;case">=":return e>=0;default:return ze()}}isInequality(){return["<","<=",">",">=","!=","not-in"].indexOf(this.op)>=0}getFlattenedFilters(){return[this]}getFilters(){return[this]}}class di extends pO{constructor(e,n){super(),this.filters=e,this.op=n,this.ae=null}static create(e,n){return new di(e,n)}matches(e){return mO(this)?this.filters.find(n=>!n.matches(e))===void 0:this.filters.find(n=>n.matches(e))!==void 0}getFlattenedFilters(){return this.ae!==null||(this.ae=this.filters.reduce((e,n)=>e.concat(n.getFlattenedFilters()),[])),this.ae}getFilters(){return Object.assign([],this.filters)}}function mO(t){return t.op==="and"}function gO(t){return J5(t)&&mO(t)}function J5(t){for(const e of t.filters)if(e instanceof di)return!1;return!0}function jy(t){if(t instanceof un)return t.field.canonicalString()+t.op.toString()+Tu(t.value);if(gO(t))return t.filters.map(e=>jy(e)).join(",");{const e=t.filters.map(n=>jy(n)).join(",");return`${t.op}(${e})`}}function vO(t,e){return t instanceof un?function(r,i){return i instanceof un&&r.op===i.op&&r.field.isEqual(i.field)&&Vi(r.value,i.value)}(t,e):t instanceof di?function(r,i){return i instanceof di&&r.op===i.op&&r.filters.length===i.filters.length?r.filters.reduce((s,o,a)=>s&&vO(o,i.filters[a]),!0):!1}(t,e):void ze()}function yO(t){return t instanceof un?function(n){return`${n.field.canonicalString()} ${n.op} ${Tu(n.value)}`}(t):t instanceof di?function(n){return n.op.toString()+" {"+n.getFilters().map(yO).join(" ,")+"}"}(t):"Filter"}class e9 extends un{constructor(e,n,r){super(e,n,r),this.key=Le.fromName(r.referenceValue)}matches(e){const n=Le.comparator(e.key,this.key);return this.matchesComparison(n)}}class t9 extends un{constructor(e,n){super(e,"in",n),this.keys=_O("in",n)}matches(e){return this.keys.some(n=>n.isEqual(e.key))}}class n9 extends un{constructor(e,n){super(e,"not-in",n),this.keys=_O("not-in",n)}matches(e){return!this.keys.some(n=>n.isEqual(e.key))}}function _O(t,e){var n;return(((n=e.arrayValue)===null||n===void 0?void 0:n.values)||[]).map(r=>Le.fromName(r.referenceValue))}class r9 extends un{constructor(e,n){super(e,"array-contains",n)}matches(e){const n=e.data.field(this.field);return c1(n)&&Af(n.arrayValue,this.value)}}class i9 extends un{constructor(e,n){super(e,"in",n)}matches(e){const n=e.data.field(this.field);return n!==null&&Af(this.value.arrayValue,n)}}class s9 extends un{constructor(e,n){super(e,"not-in",n)}matches(e){if(Af(this.value.arrayValue,{nullValue:"NULL_VALUE"}))return!1;const n=e.data.field(this.field);return n!==null&&!Af(this.value.arrayValue,n)}}class o9 extends un{constructor(e,n){super(e,"array-contains-any",n)}matches(e){const n=e.data.field(this.field);return!(!c1(n)||!n.arrayValue.values)&&n.arrayValue.values.some(r=>Af(this.value.arrayValue,r))}}/** 2326 * @license 2327 * Copyright 2019 Google LLC 2328 * 2329 * Licensed under the Apache License, Version 2.0 (the "License");
2330 * you may not use this file except in compliance with the License. 2331 * You may obtain a copy of the License at 2332 * 2333 * http://www.apache.org/licenses/LICENSE-2.0 2334 * 2335 * Unless required by applicable law or agreed to in writing, software 2336 * distributed under the License is distributed on an "AS IS" BASIS, 2337 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2338 * See the License for the specific language governing permissions and 2339 * limitations under the License. 2340 */class a9{constructor(e,n=null,r=[],i=[],s=null,o=null,a=null){this.path=e,this.collectionGroup=n,this.orderBy=r,this.filters=i,this.limit=s,this.startAt=o,this.endAt=a,this.ue=null}}function Fx(t,e=null,n=[],r=[],i=null,s=null,o=null){return new a9(t,e,n,r,i,s,o)}function f1(t){const e=We(t);if(e.ue===null){let n=e.path.canonicalString();e.collectionGroup!==null&&(n+="|cg:"+e.collectionGroup),n+="|f:",n+=e.filters.map(r=>jy(r)).join(","),n+="|ob:",n+=e.orderBy.map(r=>function(s){return s.field.canonicalString()+s.dir}(r)).join(","),Cm(e.limit)||(n+="|l:",n+=e.limit),e.startAt&&(n+="|lb:",n+=e.startAt.inclusive?"b:":"a:",n+=e.startAt.position.map(r=>Tu(r)).join(",")),e.endAt&&(n+="|ub:",n+=e.endAt.inclusive?"a:":"b:",n+=e.endAt.position.map(r=>Tu(r)).join(",")),e.ue=n}return e.ue}function d1(t,e){if(t.limit!==e.limit||t.orderBy.length!==e.orderBy.length)return!1;for(let n=0;n<t.orderBy.length;n++)if(!X5(t.orderBy[n],e.orderBy[n]))return!1;if(t.filters.length!==e.filters.length)return!1;for(let n=0;n<t.filters.length;n++)if(!vO(t.filters[n],e.filters[n]))return!1;return t.collectionGroup===e.collectionGroup&&!!t.path.isEqual(e.path)&&!!jx(t.startAt,e.startAt)&&jx(t.endAt,e.endAt)}function Fy(t){return Le.isDocumentKey(t.path)&&t.collectionGroup===null&&t.filters.length===0}/** 2341 * @license 2342 * Copyright 2017 Google LLC 2343 * 2344 * Licensed under the Apache License, Version 2.0 (the "License"); 2345 * you may not use this file except in compliance with the License. 2346 * You may obtain a copy of the License at 2347 * 2348 * http://www.apache.org/licenses/LICENSE-2.0 2349 * 2350 * Unless required by applicable law or agreed to in writing, software 2351 * distributed under the License is distributed on an "AS IS" BASIS, 2352 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2353 * See the License for the specific language governing permissions and 2354 * limitations under the License. 2355 */class od{constructor(e,n=null,r=[],i=[],s=null,o="F",a=null,l=null){this.path=e,this.collectionGroup=n,this.explicitOrderBy=r,this.filters=i,this.limit=s,this.limitType=o,this.startAt=a,this.endAt=l,this.ce=null,this.le=null,this.he=null,this.startAt,this.endAt}}function l9(t,e,n,r,i,s,o,a){return new od(t,e,n,r,i,s,o,a)}function h1(t){return new od(t)}function Vx(t){return t.filters.length===0&&t.limit===null&&t.startAt==null&&t.endAt==null&&(t.explicitOrderBy.length===0||t.explicitOrderBy.length===1&&t.explicitOrderBy[0].field.isKeyField())}function wO(t){return t.collectionGroup!==null}function Kc(t){const e=We(t);if(e.ce===null){e.ce=[];const n=new Set;for(const s of e.explicitOrderBy)e.ce.push(s),n.add(s.field.canonicalString());const r=e.explicitOrderBy.length>0?e.explicitOrderBy[e.explicitOrderBy.length-1].dir:"asc";(function(o){let a=new Sn(xn.comparator);return o.filters.forEach(l=>{l.getFlattenedFilters().forEach(u=>{u.isInequality()&&(a=a.add(u.field))})}),a})(e).forEach(s=>{n.has(s.canonicalString())||s.isKeyField()||e.ce.push(new Op(s,r))}),n.has(xn.keyField().canonicalString())||e.ce.push(new Op(xn.keyField(),r))}return e.ce}function Mi(t){const e=We(t);return e.le||(e.le=u9(e,Kc(t))),e.le}function u9(t,e){if(t.limitType==="F")return Fx(t.path,t.collectionGroup,e,t.filters,t.limit,t.startAt,t.endAt);{e=e.map(i=>{const s=i.dir==="desc"?"asc":"desc";return new Op(i.field,s)});const n=t.endAt?new Ip(t.endAt.position,t.endAt.inclusive):null,r=t.startAt?new Ip(t.startAt.position,t.startAt.inclusive):null;return Fx(t.path,t.collectionGroup,e,t.filters,t.limit,n,r)}}function Vy(t,e){const n=t.filters.concat([e]);return new od(t.path,t.collectionGroup,t.explicitOrderBy.slice(),n,t.limit,t.limitType,t.startAt,t.endAt)}function Uy(t,e,n){return new od(t.path,t.collectionGroup,t.explicitOrderBy.slice(),t.filters.slice(),e,n,t.startAt,t.endAt)}function Nm(t,e){return d1(Mi(t),Mi(e))&&t.limitType===e.limitType}function bO(t){return`${f1(Mi(t))}|lt:${t.limitType}`}function bl(t){return`Query(target=${function(n){let r=n.path.canonicalString();return n.collectionGroup!==null&&(r+=" collectionGroup="+n.collectionGroup),n.filters.length>0&&(r+=`, filters: [${n.filters.map(i=>yO(i)).join(", ")}]`),Cm(n.limit)||(r+=", limit: "+n.limit),n.orderBy.length>0&&(r+=`, orderBy: [${n.orderBy.map(i=>function(o){return`${o.field.canonicalString()} (${o.dir})`}(i)).join(", ")}]`),n.startAt&&(r+=", startAt: ",r+=n.startAt.inclusive?"b:":"a:",r+=n.startAt.position.map(i=>Tu(i)).join(",")),n.endAt&&(r+=", endAt: ",r+=n.endAt.inclusive?"a:":"b:",r+=n.endAt.position.map(i=>Tu(i)).join(",")),`Target(${r})`}(Mi(t))}; limitType=${t.limitType})`}function Dm(t,e){return e.isFoundDocument()&&function(r,i){const s=i.key.path;return r.collectionGroup!==null?i.key.hasCollectionId(r.collectionGroup)&&r.path.isPrefixOf(s):Le.isDocumentKey(r.path)?r.path.isEqual(s):r.path.isImmediateParentOf(s)}(t,e)&&function(r,i){for(const s of Kc(r))if(!s.field.isKeyField()&&i.data.field(s.field)===null)return!1;return!0}(t,e)&&function(r,i){for(const s of r.filters)if(!s.matches(i))return!1;return!0}(t,e)&&function(r,i){return!(r.startAt&&!function(o,a,l){const u=Lx(o,a,l);return o.inclusive?u<=0:u<0}(r.startAt,Kc(r),i)||r.endAt&&!function(o,a,l){const u=Lx(o,a,l);return o.inclusive?u>=0:u>0}(r.endAt,Kc(r),i))}(t,e)}function c9(t){return t.collectionGroup||(t.path.length%2==1?t.path.lastSegment():t.path.get(t.path.length-2))}function EO(t){return(e,n)=>{let r=!1;for(const i of Kc(t)){const s=f9(i,e,n);if(s!==0)return s;r=r||i.field.isKeyField()}return 0}}function f9(t,e,n){const r=t.field.isKeyField()?Le.comparator(e.key,n.key):function(s,o,a){const l=o.data.field(s),u=a.data.field(s);return l!==null&&u!==null?xu(l,u):ze()}
2355(t.field,e,n);switch(t.dir){case"asc":return r;case"desc":return-1*r;default:return ze()}}/** 2356 * @license 2357 * Copyright 2017 Google LLC 2358 * 2359 * Licensed under the Apache License, Version 2.0 (the "License"); 2360 * you may not use this file except in compliance with the License. 2361 * You may obtain a copy of the License at 2362 * 2363 * http://www.apache.org/licenses/LICENSE-2.0 2364 * 2365 * Unless required by applicable law or agreed to in writing, software 2366 * distributed under the License is distributed on an "AS IS" BASIS, 2367 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2368 * See the License for the specific language governing permissions and 2369 * limitations under the License. 2370 */class ju{constructor(e,n){this.mapKeyFn=e,this.equalsFn=n,this.inner={},this.innerSize=0}get(e){const n=this.mapKeyFn(e),r=this.inner[n];if(r!==void 0){for(const[i,s]of r)if(this.equalsFn(i,e))return s}}has(e){return this.get(e)!==void 0}set(e,n){const r=this.mapKeyFn(e),i=this.inner[r];if(i===void 0)return this.inner[r]=[[e,n]],void this.innerSize++;for(let s=0;s<i.length;s++)if(this.equalsFn(i[s][0],e))return void(i[s]=[e,n]);i.push([e,n]),this.innerSize++}delete(e){const n=this.mapKeyFn(e),r=this.inner[n];if(r===void 0)return!1;for(let i=0;i<r.length;i++)if(this.equalsFn(r[i][0],e))return r.length===1?delete this.inner[n]:r.splice(i,1),this.innerSize--,!0;return!1}forEach(e){ul(this.inner,(n,r)=>{for(const[i,s]of r)e(i,s)})}isEmpty(){return fO(this.inner)}size(){return this.innerSize}}/** 2371 * @license 2372 * Copyright 2017 Google LLC 2373 * 2374 * Licensed under the Apache License, Version 2.0 (the "License"); 2375 * you may not use this file except in compliance with the License. 2376 * You may obtain a copy of the License at 2377 * 2378 * http://www.apache.org/licenses/LICENSE-2.0 2379 * 2380 * Unless required by applicable law or agreed to in writing, software 2381 * distributed under the License is distributed on an "AS IS" BASIS, 2382 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2383 * See the License for the specific language governing permissions and 2384 * limitations under the License. 2385 */const d9=new Kt(Le.comparator);function Ds(){return d9}const xO=new Kt(Le.comparator);function Rc(...t){let e=xO;for(const n of t)e=e.insert(n.key,n);return e}function TO(t){let e=xO;return t.forEach((n,r)=>e=e.insert(n,r.overlayedDocument)),e}function xa(){return Yc()}function SO(){return Yc()}function Yc(){return new ju(t=>t.toString(),(t,e)=>t.isEqual(e))}const h9=new Kt(Le.comparator),p9=new Sn(Le.comparator);function rt(...t){let e=p9;for(const n of t)e=e.add(n);return e}const m9=new Sn(pt);function g9(){return m9}/** 2386 * @license 2387 * Copyright 2020 Google LLC 2388 * 2389 * Licensed under the Apache License, Version 2.0 (the "License"); 2390 * you may not use this file except in compliance with the License. 2391 * You may obtain a copy of the License at 2392 * 2393 * http://www.apache.org/licenses/LICENSE-2.0 2394 * 2395 * Unless required by applicable law or agreed to in writing, software 2396 * distributed under the License is distributed on an "AS IS" BASIS, 2397 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2398 * See the License for the specific language governing permissions and 2399 * limitations under the License. 2400 */function p1(t,e){if(t.useProto3Json){if(isNaN(e))return{doubleValue:"NaN"};if(e===1/0)return{doubleValue:"Infinity"};if(e===-1/0)return{doubleValue:"-Infinity"}}return{doubleValue:Ap(e)?"-0":e}}function kO(t){return{integerValue:""+t}}function v9(t,e){return G5(e)?kO(e):p1(t,e)}/** 2401 * @license 2402 * Copyright 2018 Google LLC 2403 * 2404 * Licensed under the Apache License, Version 2.0 (the "License"); 2405 * you may not use this file except in compliance with the License. 2406 * You may obtain a copy of the License at 2407 * 2408 * http://www.apache.org/licenses/LICENSE-2.0 2409 * 2410 * Unless required by applicable law or agreed to in writing, software 2411 * distributed under the License is distributed on an "AS IS" BASIS, 2412 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2413 * See the License for the specific language governing permissions and 2414 * limitations under the License. 2415 */class Mm{constructor(){this._=void 0}}function y9(t,e,n){return t instanceof Pp?function(i,s){const o={fields:{__type__:{stringValue:"server_timestamp"},__local_write_time__:{timestampValue:{seconds:i.seconds,nanos:i.nanoseconds}}}};return s&&l1(s)&&(s=u1(s)),s&&(o.fields.__previous_value__=s),{mapValue:o}}(n,e):t instanceof If?IO(t,e):t instanceof Of?OO(t,e):function(i,s){const o=AO(i,s),a=Ux(o)+Ux(i.Pe);return Ly(o)&&Ly(i.Pe)?kO(a):p1(i.serializer,a)}(t,e)}function _9(t,e,n){return t instanceof If?IO(t,e):t instanceof Of?OO(t,e):n}function AO(t,e){return t instanceof Rp?function(r){return Ly(r)||function(s){return!!s&&"doubleValue"in s}(r)}(e)?e:{integerValue:0}:null}class Pp extends Mm{}class If extends Mm{constructor(e){super(),this.elements=e}}function IO(t,e){const n=PO(e);for(const r of t.elements)n.some(i=>Vi(i,r))||n.push(r);return{arrayValue:{values:n}}}class Of extends Mm{constructor(e){super(),this.elements=e}}function OO(t,e){let n=PO(e);for(const r of t.elements)n=n.filter(i=>!Vi(i,r));return{arrayValue:{values:n}}}
2415class Rp extends Mm{constructor(e,n){super(),this.serializer=e,this.Pe=n}}function Ux(t){return tn(t.integerValue||t.doubleValue)}function PO(t){return c1(t)&&t.arrayValue.values?t.arrayValue.values.slice():[]}function w9(t,e){return t.field.isEqual(e.field)&&function(r,i){return r instanceof If&&i instanceof If||r instanceof Of&&i instanceof Of?Eu(r.elements,i.elements,Vi):r instanceof Rp&&i instanceof Rp?Vi(r.Pe,i.Pe):r instanceof Pp&&i instanceof Pp}(t.transform,e.transform)}class b9{constructor(e,n){this.version=e,this.transformResults=n}}class Li{constructor(e,n){this.updateTime=e,this.exists=n}static none(){return new Li}static exists(e){return new Li(void 0,e)}static updateTime(e){return new Li(e)}get isNone(){return this.updateTime===void 0&&this.exists===void 0}isEqual(e){return this.exists===e.exists&&(this.updateTime?!!e.updateTime&&this.updateTime.isEqual(e.updateTime):!e.updateTime)}}function Nh(t,e){return t.updateTime!==void 0?e.isFoundDocument()&&e.version.isEqual(t.updateTime):t.exists===void 0||t.exists===e.isFoundDocument()}let Lm=class{};function RO(t,e){if(!t.hasLocalMutations||e&&e.fields.length===0)return null;if(e===null)return t.isNoDocument()?new NO(t.key,Li.none()):new ad(t.key,t.data,Li.none());{const n=t.data,r=ar.empty();let i=new Sn(xn.comparator);for(let s of e.fields)if(!i.has(s)){let o=n.field(s);o===null&&s.length>1&&(s=s.popLast(),o=n.field(s)),o===null?r.delete(s):r.set(s,o),i=i.add(s)}return new ea(t.key,r,new xr(i.toArray()),Li.none())}}function E9(t,e,n){t instanceof ad?function(i,s,o){const a=i.value.clone(),l=Bx(i.fieldTransforms,s,o.transformResults);a.setAll(l),s.convertToFoundDocument(o.version,a).setHasCommittedMutations()}(t,e,n):t instanceof ea?function(i,s,o){if(!Nh(i.precondition,s))return void s.convertToUnknownDocument(o.version);const a=Bx(i.fieldTransforms,s,o.transformResults),l=s.data;l.setAll(CO(i)),l.setAll(a),s.convertToFoundDocument(o.version,l).setHasCommittedMutations()}(t,e,n):function(i,s,o){s.convertToNoDocument(o.version).setHasCommittedMutations()}(0,e,n)}function Qc(t,e,n,r){return t instanceof ad?function(s,o,a,l){if(!Nh(s.precondition,o))return a;const u=s.value.clone(),c=zx(s.fieldTransforms,l,o);return u.setAll(c),o.convertToFoundDocument(o.version,u).setHasLocalMutations(),null}(t,e,n,r):t instanceof ea?function(s,o,a,l){if(!Nh(s.precondition,o))return a;const u=zx(s.fieldTransforms,l,o),c=o.data;return c.setAll(CO(s)),c.setAll(u),o.convertToFoundDocument(o.version,c).setHasLocalMutations(),a===null?null:a.unionWith(s.fieldMask.fields).unionWith(s.fieldTransforms.map(d=>d.field))}(t,e,n,r):function(s,o,a){return Nh(s.precondition,o)?(o.convertToNoDocument(o.version).setHasLocalMutations(),null):a}(t,e,n)}function x9(t,e){let n=null;for(const r of t.fieldTransforms){const i=e.data.field(r.field),s=AO(r.transform,i||null);s!=null&&(n===null&&(n=ar.empty()),n.set(r.field,s))}return n||null}function $x(t,e){return t.type===e.type&&!!t.key.isEqual(e.key)&&!!t.precondition.isEqual(e.precondition)&&!!function(r,i){return r===void 0&&i===void 0||!(!r||!i)&&Eu(r,i,(s,o)=>w9(s,o))}(t.fieldTransforms,e.fieldTransforms)&&(t.type===0?t.value.isEqual(e.value):t.type!==1||t.data.isEqual(e.data)&&t.fieldMask.isEqual(e.fieldMask))}class ad extends Lm{constructor(e,n,r,i=[]){super(),this.key=e,this.value=n,this.precondition=r,this.fieldTransforms=i,this.type=0}getFieldMask(){return null}}class ea extends Lm{constructor(e,n,r,i,s=[]){super(),this.key=e,this.data=n,this.fieldMask=r,this.precondition=i,this.fieldTransforms=s,this.type=1}getFieldMask(){return this.fieldMask}}function CO(t){const e=new Map;return t.fieldMask.fields.forEach(n=>{if(!n.isEmpty()){const r=t.data.field(n);e.set(n,r)}}),e}function Bx(t,e,n){const r=new Map;bt(t.length===n.length);for(let i=0;i<n.length;i++){const s=t[i],o=s.transform,a=e.data.field(s.field);r.set(s.field,_9(o,a,n[i]))}return r}function zx(t,e,n){const r=new Map;for(const i of t){const s=i.transform,o=n.data.field(i.field);r.set(i.field,y9(s,o,e))}return r}class NO extends Lm{constructor(e,n){super(),this.key=e,this.precondition=n,this.type=2,this.fieldTransforms=[]}getFieldMask(){return null}}class T9 extends Lm{constructor(e,n){super(),this.key=e,this.prec
2415ondition=n,this.type=3,this.fieldTransforms=[]}getFieldMask(){return null}}/** 2416 * @license 2417 * Copyright 2017 Google LLC 2418 * 2419 * Licensed under the Apache License, Version 2.0 (the "License"); 2420 * you may not use this file except in compliance with the License. 2421 * You may obtain a copy of the License at 2422 * 2423 * http://www.apache.org/licenses/LICENSE-2.0 2424 * 2425 * Unless required by applicable law or agreed to in writing, software 2426 * distributed under the License is distributed on an "AS IS" BASIS, 2427 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2428 * See the License for the specific language governing permissions and 2429 * limitations under the License. 2430 */class S9{constructor(e,n,r,i){this.batchId=e,this.localWriteTime=n,this.baseMutations=r,this.mutations=i}applyToRemoteDocument(e,n){const r=n.mutationResults;for(let i=0;i<this.mutations.length;i++){const s=this.mutations[i];s.key.isEqual(e.key)&&E9(s,e,r[i])}}applyToLocalView(e,n){for(const r of this.baseMutations)r.key.isEqual(e.key)&&(n=Qc(r,e,n,this.localWriteTime));for(const r of this.mutations)r.key.isEqual(e.key)&&(n=Qc(r,e,n,this.localWriteTime));return n}applyToLocalDocumentSet(e,n){const r=SO();return this.mutations.forEach(i=>{const s=e.get(i.key),o=s.overlayedDocument;let a=this.applyToLocalView(o,s.mutatedFields);a=n.has(i.key)?null:a;const l=RO(o,a);l!==null&&r.set(i.key,l),o.isValidDocument()||o.convertToNoDocument(He.min())}),r}keys(){return this.mutations.reduce((e,n)=>e.add(n.key),rt())}isEqual(e){return this.batchId===e.batchId&&Eu(this.mutations,e.mutations,(n,r)=>$x(n,r))&&Eu(this.baseMutations,e.baseMutations,(n,r)=>$x(n,r))}}class m1{constructor(e,n,r,i){this.batch=e,this.commitVersion=n,this.mutationResults=r,this.docVersions=i}static from(e,n,r){bt(e.mutations.length===r.length);let i=function(){return h9}();const s=e.mutations;for(let o=0;o<s.length;o++)i=i.insert(s[o].key,r[o].version);return new m1(e,n,r,i)}}/** 2431 * @license 2432 * Copyright 2022 Google LLC 2433 * 2434 * Licensed under the Apache License, Version 2.0 (the "License"); 2435 * you may not use this file except in compliance with the License. 2436 * You may obtain a copy of the License at 2437 * 2438 * http://www.apache.org/licenses/LICENSE-2.0 2439 * 2440 * Unless required by applicable law or agreed to in writing, software 2441 * distributed under the License is distributed on an "AS IS" BASIS, 2442 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2443 * See the License for the specific language governing permissions and 2444 * limitations under the License. 2445 */class k9{constructor(e,n){this.largestBatchId=e,this.mutation=n}getKey(){return this.mutation.key}isEqual(e){return e!==null&&this.mutation===e.mutation}toString(){return`Overlay{ 2446 largestBatchId: ${this.largestBatchId}, 2447 mutation: ${this.mutation.toString()} 2448 }`}}/** 2449 * @license 2450 * Copyright 2017 Google LLC 2451 * 2452 * Licensed under the Apache License, Version 2.0 (the "License"); 2453 * you may not use this file except in compliance with the License. 2454 * You may obtain a copy of the License at 2455 * 2456 * http://www.apache.org/licenses/LICENSE-2.0 2457 * 2458 * Unless required by applicable law or agreed to in writing, software 2459 * distributed under the License is distributed on an "AS IS" BASIS, 2460 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2461 * See the License for the specific language governing permissions and 2462 * limitations under the License. 2463 */class A9{constructor(e,n){this.count=e,this.unchangedNames=n}}/** 2464 * @license 2465 * Copyright 2017 Google LLC 2466 * 2467 * Licensed under the Apache License, Version 2.0 (the "License"); 2468 * you may not use this file except in compliance with the License. 2469 * You may obtain a copy of the License at 2470 * 2471 * http://www.apache.org/licenses/LICENSE-2.0 2472 * 2473 * Unless required by applicable law or agreed to in writing, software 2474 * distributed under the License is distributed on an "AS IS" BASIS, 2475 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2476 * See the License for the specific language governing permissions and 2477 * limitations under the License. 2478 */var sn,ut;function I9(t){switch(t){default:return ze();case le.CANCELLED:case le.UNKNOWN:case le.DEADLINE_EXCEEDED:case le.RESOURCE_EXHAUSTED:case le.INTERNAL:case le.UNAVAILABLE:case le.UNAUTHENTICATED:return!1;case le.INVALID_ARGUMENT:case le.NOT_FOUND:case le.ALREADY_EXISTS:case le.PERMISSION_DENIED:case le.FAILED_PRECONDITION:case le.ABORTED:case le.OUT_OF_RANGE:case le.UNIMPLEMENT
2478ED:case le.DATA_LOSS:return!0}}function DO(t){if(t===void 0)return Ns("GRPC error has no .code"),le.UNKNOWN;switch(t){case sn.OK:return le.OK;case sn.CANCELLED:return le.CANCELLED;case sn.UNKNOWN:return le.UNKNOWN;case sn.DEADLINE_EXCEEDED:return le.DEADLINE_EXCEEDED;case sn.RESOURCE_EXHAUSTED:return le.RESOURCE_EXHAUSTED;case sn.INTERNAL:return le.INTERNAL;case sn.UNAVAILABLE:return le.UNAVAILABLE;case sn.UNAUTHENTICATED:return le.UNAUTHENTICATED;case sn.INVALID_ARGUMENT:return le.INVALID_ARGUMENT;case sn.NOT_FOUND:return le.NOT_FOUND;case sn.ALREADY_EXISTS:return le.ALREADY_EXISTS;case sn.PERMISSION_DENIED:return le.PERMISSION_DENIED;case sn.FAILED_PRECONDITION:return le.FAILED_PRECONDITION;case sn.ABORTED:return le.ABORTED;case sn.OUT_OF_RANGE:return le.OUT_OF_RANGE;case sn.UNIMPLEMENTED:return le.UNIMPLEMENTED;case sn.DATA_LOSS:return le.DATA_LOSS;default:return ze()}}(ut=sn||(sn={}))[ut.OK=0]="OK",ut[ut.CANCELLED=1]="CANCELLED",ut[ut.UNKNOWN=2]="UNKNOWN",ut[ut.INVALID_ARGUMENT=3]="INVALID_ARGUMENT",ut[ut.DEADLINE_EXCEEDED=4]="DEADLINE_EXCEEDED",ut[ut.NOT_FOUND=5]="NOT_FOUND",ut[ut.ALREADY_EXISTS=6]="ALREADY_EXISTS",ut[ut.PERMISSION_DENIED=7]="PERMISSION_DENIED",ut[ut.UNAUTHENTICATED=16]="UNAUTHENTICATED",ut[ut.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",ut[ut.FAILED_PRECONDITION=9]="FAILED_PRECONDITION",ut[ut.ABORTED=10]="ABORTED",ut[ut.OUT_OF_RANGE=11]="OUT_OF_RANGE",ut[ut.UNIMPLEMENTED=12]="UNIMPLEMENTED",ut[ut.INTERNAL=13]="INTERNAL",ut[ut.UNAVAILABLE=14]="UNAVAILABLE",ut[ut.DATA_LOSS=15]="DATA_LOSS";/** 2479 * @license 2480 * Copyright 2023 Google LLC 2481 * 2482 * Licensed under the Apache License, Version 2.0 (the "License"); 2483 * you may not use this file except in compliance with the License. 2484 * You may obtain a copy of the License at 2485 * 2486 * http://www.apache.org/licenses/LICENSE-2.0 2487 * 2488 * Unless required by applicable law or agreed to in writing, software 2489 * distributed under the License is distributed on an "AS IS" BASIS, 2490 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2491 * See the License for the specific language governing permissions and 2492 * limitations under the License. 2493 */function O9(){return new TextEncoder}/** 2494 * @license 2495 * Copyright 2022 Google LLC 2496 * 2497 * Licensed under the Apache License, Version 2.0 (the "License"); 2498 * you may not use this file except in compliance with the License. 2499 * You may obtain a copy of the License at 2500 * 2501 * http://www.apache.org/licenses/LICENSE-2.0 2502 * 2503 * Unless required by applicable law or agreed to in writing, software 2504 * distributed under the License is distributed on an "AS IS" BASIS, 2505 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2506 * See the License for the specific language governing permissions and 2507 * limitations under the License. 2508 */const P9=new Va([4294967295,4294967295],0);function qx(t){const e=O9().encode(t),n=new rO;return n.update(e),new Uint8Array(n.digest())}function Hx(t){const e=new DataView(t.buffer),n=e.getUint32(0,!0),r=e.getUint32(4,!0),i=e.getUint32(8,!0),s=e.getUint32(12,!0);return[new Va([n,r],0),new Va([i,s],0)]}class g1{constructor(e,n,r){if(this.bitmap=e,this.padding=n,this.hashCount=r,n<0||n>=8)throw new Cc(`Invalid padding: ${n}`);if(r<0)throw new Cc(`Invalid hash count: ${r}`);if(e.length>0&&this.hashCount===0)throw new Cc(`Invalid hash count: ${r}`);if(e.length===0&&n!==0)throw new Cc(`Invalid padding when bitmap length is 0: ${n}`);this.Ie=8*e.length-n,this.Te=Va.fromNumber(this.Ie)}Ee(e,n,r){let i=e.add(n.multiply(Va.fromNumber(r)));return i.compare(P9)===1&&(i=new Va([i.getBits(0),i.getBits(1)],0)),i.modulo(this.Te).toNumber()}de(e){return(this.bitmap[Math.floor(e/8)]&1<<e%8)!=0}mightContain(e){if(this.Ie===0)return!1;const n=qx(e),[r,i]=Hx(n);for(let s=0;s<this.hashCount;s++){const o=this.Ee(r,i,s);if(!this.de(o))return!1}return!0}static create(e,n,r){const i=e%8==0?0:8-e%8,s=new Uint8Array(Math.ceil(e/8)),o=new g1(s,i,n);return r.forEach(a=>o.insert(a)),o}insert(e){if(this.Ie===0)return;const n=qx(e),[r,i]=Hx(n);for(let s=0;s<this.hashCount;s++){const o=this.Ee(r,i,s);this.Ae(o)}}Ae(e){const n=Math.floor(e/8),r=e%8;this.bitmap[n]|=1<<r}}
2508class Cc extends Error{constructor(){super(...arguments),this.name="BloomFilterError"}}/** 2509 * @license 2510 * Copyright 2017 Google LLC 2511 * 2512 * Licensed under the Apache License, Version 2.0 (the "License"); 2513 * you may not use this file except in compliance with the License. 2514 * You may obtain a copy of the License at 2515 * 2516 * http://www.apache.org/licenses/LICENSE-2.0 2517 * 2518 * Unless required by applicable law or agreed to in writing, software 2519 * distributed under the License is distributed on an "AS IS" BASIS, 2520 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2521 * See the License for the specific language governing permissions and 2522 * limitations under the License. 2523 */class jm{constructor(e,n,r,i,s){this.snapshotVersion=e,this.targetChanges=n,this.targetMismatches=r,this.documentUpdates=i,this.resolvedLimboDocuments=s}static createSynthesizedRemoteEventForCurrentChange(e,n,r){const i=new Map;return i.set(e,ld.createSynthesizedTargetChangeForCurrentChange(e,n,r)),new jm(He.min(),i,new Kt(pt),Ds(),rt())}}class ld{constructor(e,n,r,i,s){this.resumeToken=e,this.current=n,this.addedDocuments=r,this.modifiedDocuments=i,this.removedDocuments=s}static createSynthesizedTargetChangeForCurrentChange(e,n,r){return new ld(r,n,rt(),rt(),rt())}}/** 2524 * @license 2525 * Copyright 2017 Google LLC 2526 * 2527 * Licensed under the Apache License, Version 2.0 (the "License"); 2528 * you may not use this file except in compliance with the License. 2529 * You may obtain a copy of the License at 2530 * 2531 * http://www.apache.org/licenses/LICENSE-2.0 2532 * 2533 * Unless required by applicable law or agreed to in writing, software 2534 * distributed under the License is distributed on an "AS IS" BASIS, 2535 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2536 * See the License for the specific language governing permissions and 2537 * limitations under the License. 2538 */class Dh{constructor(e,n,r,i){this.Re=e,this.removedTargetIds=n,this.key=r,this.Ve=i}}class MO{constructor(e,n){this.targetId=e,this.me=n}}class LO{constructor(e,n,r=An.EMPTY_BYTE_STRING,i=null){this.state=e,this.targetIds=n,this.resumeToken=r,this.cause=i}}class Wx{constructor(){this.fe=0,this.ge=Kx(),this.pe=An.EMPTY_BYTE_STRING,this.ye=!1,this.we=!0}get current(){return this.ye}get resumeToken(){return this.pe}get Se(){return this.fe!==0}get be(){return this.we}De(e){e.approximateByteSize()>0&&(this.we=!0,this.pe=e)}ve(){let e=rt(),n=rt(),r=rt();return this.ge.forEach((i,s)=>{switch(s){case 0:e=e.add(i);break;case 2:n=n.add(i);break;case 1:r=r.add(i);break;default:ze()}}),new ld(this.pe,this.ye,e,n,r)}Ce(){this.we=!1,this.ge=Kx()}Fe(e,n){this.we=!0,this.ge=this.ge.insert(e,n)}Me(e){this.we=!0,this.ge=this.ge.remove(e)}xe(){this.fe+=1}Oe(){this.fe-=1,bt(this.fe>=0)}Ne(){this.we=!0,this.ye=!0}}class R9{constructor(e){this.Le=e,this.Be=new Map,this.ke=Ds(),this.qe=Gx(),this.Qe=new Kt(pt)}Ke(e){for(const n of e.Re)e.Ve&&e.Ve.isFoundDocument()?this.$e(n,e.Ve):this.Ue(n,e.key,e.Ve);for(const n of e.removedTargetIds)this.Ue(n,e.key,e.Ve)}We(e){this.forEachTarget(e,n=>{const r=this.Ge(n);switch(e.state){case 0:this.ze(n)&&r.De(e.resumeToken);break;case 1:r.Oe(),r.Se||r.Ce(),r.De(e.resumeToken);break;case 2:r.Oe(),r.Se||this.removeTarget(n);break;case 3:this.ze(n)&&(r.Ne(),r.De(e.resumeToken));break;case 4:this.ze(n)&&(this.je(n),r.De(e.resumeToken));break;default:ze()}})}forEachTarget(e,n){e.targetIds.length>0?e.targetIds.forEach(n):this.Be.forEach((r,i)=>{this.ze(i)&&n(i)})}He(e){const n=e.targetId,r=e.me.count,i=this.Je(n);if(i){const s=i.target;if(Fy(s))if(r===0){const o=new Le(s.path);this.Ue(n,o,Ln.newNoDocument(o,He.min()))}else bt(r===1);else{const o=this.Ye(n);if(o!==r){const a=this.Ze(e),l=a?this.Xe(a,e,o):1;if(l!==0){this.je(n);const u=l===2?"TargetPurposeExistenceFilterMismatchBloom":"TargetPurposeExistenceFilterMismatch";this.Qe=this.Qe.insert(n,u)}}}}}Ze(e){const n=e.me.unchangedNames;if(!n||!n.bits)return null;const{bits:{bitmap:r="",padding:i=0},hashCount:s=0}=n;let o,a;try{o=tl(r).toUint8Array()}catch(l){if(l instanceof dO)return bu("Decoding the base64 bloom filter in existence filter failed ("+l.message+"); ignoring the bloom filter and falling back to full re-query."),null;throw l}try{a=new g1(o,i,s)}catch(l){return bu(l instanceof Cc?"BloomFilter error: ":"Applying bloom filter failed: ",l),null}return a.Ie===0?null:a}Xe(e,n,r){return n.me.count===r-this.nt(e,n.targetId)?0:2}nt(e,n){const r=this.Le.getRemoteKeysForTarget(n);let i=0;return r.forEach(s=>{const o=this.Le.tt(),a=`projects/${o.projectId}/databases/${o.database}/documents/${s.path.canonicalString()}`;e.mightContain(a)||(this.Ue(n,s,null),i++)}),i}rt(e){const n=new Map;this.Be.forEach((s,o)=>{const a=this.Je(o);if(a){if(s.current&&Fy(a.target)){const l=new Le(a.target.path);this.ke.get(l)!==null||this.it(o,l)||this.Ue(o,l,Ln.newNoDocument(l,e))}s.be&&(n.set(o,s.ve()),s.Ce())}});let r=rt();this.qe.forEach((s,o)=>{let a=!0;o.forEachWhile(l=>{const u=this.Je(l);return!u||u.purpose==="TargetPurposeLimboResolution"||(a=!1,!1)}),a&&(r=r.add(s))}),this.ke.forEach((s,o)=>o.setReadTime(e));const i=new jm(e,n,this.Qe,this.ke,r);return this.ke=Ds(),this.qe=Gx(),this.Qe=new Kt(pt),i}$e(e,n){if(!this.ze(e))return;const r=this.it(e,n.key)?2:0;this.Ge(e).Fe(n.key,r),this.ke=this.ke.insert(n.key,n),this.qe=this.qe.insert(n.key,this.st(n.key).add(e))}Ue(e,n,r){if(!this.ze(e))return;const i=this.Ge(e);this.it(e,n)?i.Fe(n,1):i.Me(n),this.qe=this.qe.insert(n,this.st(n).delete(e)),r&&(this.ke=this.ke.insert(n,r))}removeTarget(e){this.Be.delete(e)}Ye(e){const n=this.Ge(e).ve();return this.Le.getRemoteKeysForTarget(e).size+n.addedDocuments.size-n.removedDocuments.size}xe(e){this.Ge(e).xe()}Ge(e){let n=this.Be.get(e);return n||(n=new Wx,this.Be.set(e,n)),n}st(e){let n=this.qe.get(e);return n||(n=new Sn(pt),this.qe=this.qe.insert(e,n)),n}ze(e){const n=this.Je(e)!==null;return n||Oe("WatchChangeAggregator","Detected inactive target",e),n}Je(e){const n=this.Be.get(e);return n&&n.Se?null:this.Le.ot(e)}je(e){this.Be.set(e,new Wx),this.Le.getRemoteKeysForTarget(e).forEach(n=>{this.Ue(e,n,null)})}it(e,n){return this.Le.getRemoteKeysForTarget(e).has(n)}}function Gx(){return new Kt(Le.comparator)}function Kx(){return new Kt(Le.comparator)}const C9={asc:"ASCENDING",desc:"DESCENDING"},N9={"<":"LESS_THAN","<=":"LESS_THAN_OR_EQUAL",">":"GREATER_THAN",">=":"GREATER_THAN_OR_EQUAL","==":"EQUAL","!=":"NOT_EQUAL","array-contains":"ARRAY_CONTAINS",in:"IN","not-in":"NOT_IN","array-contains-any":"ARRAY_CONTAINS_ANY"},D9={and:"AND",or:"OR"};class M9{constructor(e,n){this.databaseId=e,this.useProto3Json=n}}function $y(t,e){return t.useProto3Json||Cm(e)?e:{value:e}}function Cp(t,e){return t.useProto3Json?`${new Date(1e3*e.seconds).toISOString().replace(/\.\d*/,"").replace("Z","")}.${("000000000"+e.nanoseconds).slice(-9)}Z`:{seconds:""+e.seconds,nanos:e.nanoseconds}}function jO(t,e){return t.useProto3Json?e.toBase64():e.toUint8Array()}function L9(t,e){return Cp(t,e.toTimestamp())}function ji(t){return bt(!!t),He.fromTimestamp(function(n){const r=zo(n);return new pn(r.seconds,r.nanos)}(t))}function v1(t,e){return By(t,e).canonicalString()}function By(t,e){const n=function(i){return new Lt(["projects",i.projectId,"databases",i.database])}(t).child("documents");return e===void 0?n:n.child(e)}function FO(t){const e=Lt.fromString(t);return bt(zO(e)),e}function zy(t,e){return v1(t.databaseId,e.path)}function cv(t,e){const n=FO(e);if(n.get(1)!==t.databaseId.projectId)throw new ke(le.INVALID_ARGUMENT,"Tried to deserialize key from different project: "+n.get(1)+" vs "+t.databaseId.projectId);if(n.get(3)!==t.databaseId.database)throw new ke(le.INVALID_ARGUMENT,"Tried to deserialize key from different database: "+n.get(3)+" vs "+t.databaseId.database);return new Le(UO(n))}function VO(t,e){return v1(t.databaseId,e)}function j9(t){const e=FO(t);return e.length===4?Lt.emptyPath():UO(e)}function qy(t){return new Lt(["projects",t.databaseId.projectId,"databases",t.databaseId.database]).canonicalString()}function UO(t){return bt(t.length>4&&t.get(4)==="documents"),t.popFirst(5)}function Yx(t,e,n){return{name:zy(t,e),fields:n.value.mapValue.fields}}function F9(t,e){let n;if("targetChange"in e){e.targetChange;const r=function(u){return u==="NO_CHANGE"?0:u==="ADD"?1:u==="REMOVE"?2:u==="CURRENT"?3:u==="RESET"?4:ze()}(e.targetChange.targetChangeType||"NO_CHANGE"),i=e.targetChange.targetIds||[],s=function(u,c){return u.useProto3Json?(bt(c===void 0||typeof c=="string"),An.fromBase64String(c||"")):(bt(c===void 0||c instanceof Buffer||c instanceof Uint8Array),An.fromUint8Array(c||new Uint8Array))}(t,e.targetChange.resumeToken),o=e.targetChange.cause,a=o&&function(u){const c=u.code===void 0?le.UNKNOWN:DO(u.code);return new ke(c,u.message||"")}(o);n=new LO(r,i,s,a||null)}else if("documentChange"in e){e.documentChange;const r=e.documentChange;r.document,r.document.name,r.document.updateTime;const i=cv(t,r.document.name),s=ji(r.document.updateTime),o=r.document.createTime?ji(r.document.createTime):He.min(),a=new ar({mapValue:{fields:r.document.fields}}),l=Ln.newFoundDocument(i,s,o,a),u=r.targetIds||[],c=r.removedTargetIds||[];n=new Dh(u,c,l.key,l)}else if("documentDelete"in e){e.documentDelete;const r=e.documentDelete;r.document;const i=cv(t,r.document),s=r.readTime?ji(r.readTime):He.min(),o=Ln.newNoDocument(i,s),a=r.removedTargetIds||[];n=new Dh([],a,o.key,o)}else if("documentRemove"in e){e.documentRemove;const r=e.documentRemove;r.document;const i=cv(t,r.document),s=r.removedTargetIds||[];n=new Dh([],s,i,null)}else{if(!("filter"in e))return ze();{e.filter;const r=e.filter;r.targetId;const{count:i=0,unchangedNames:s}=r,o=new A9(i,s),a=r.targetId;n=new MO(a,o)}}return n}function V9(t,e){let n;if(e instanceof ad)n={update:Yx(t,e.key,e.value)};else if(e instanceof NO)n={delete:zy(t,e.key)};else if(e instanceof ea)n={update:Yx(t,e.key,e.data),updateMask:K9(e.fieldMask)};else{if(!(e instanceof T9))return ze();n={verify:zy(t,e.key)}}return e.fieldTransforms.length>0&&(n.updateTransforms=e.fieldTransforms.map(r=>function(s,o){const a=o.transform;if(a instanceof Pp)return{fieldPath:o.field.canonicalString(),setToServerValue:"REQUEST_TIME"};if(a instanceof If)return{fieldPath:o.field.canonicalString(),appendMissingElements:{values:a.elements}};if(a instanceof Of)return{fieldPath:o.field.canonicalString(),removeAllFromArray:{values:a.elements}};if(a instanceof Rp)return{fieldPath:o.field.canonicalString(),increment:a.Pe};throw ze()}(0,r))),e.precondition.isNone||(n.currentDocument=function(i,s){return s.updateTime!==void 0?{updateTime:L9(i,s.updateTime)}:s.exists!==void 0?{exists:s.exists}:ze()}(t,e.precondition)),n}function U9(t,e){return t&&t.length>0?(bt(e!==void 0),t.map(n=>function(i,s){let o=i.updateTime?ji(i.updateTime):ji(s);return o.isEqual(He.min())&&(o=ji(s)),new b9(o,i.transformResults||[])}(n,e))):[]}function $9(t,e){return{documents:[VO(t,e.path)]}}function B9(t,e){const n={structuredQuery:{}},r=e.path;let i;e.collectionGroup!==null?(i=r,n.structuredQuery.from=[{collectionId:e.collectionGroup,allDescendants:!0}]):(i=r.popLast(),n.structuredQuery.from=[{collectionId:r.lastSegment()}]),n.parent=VO(t,i);const s=function(u){if(u.length!==0)return BO(di.create(u,"and"))}(e.filters);s&&(n.structuredQuery.where=s);const o=function(u){if(u.length!==0)return u.map(c=>function(f){return{field:El(f.field),direction:H9(f.dir)}}(c))}(e.orderBy);o&&(n.structuredQuery.orderBy=o);const a=$y(t,e.limit);return a!==null&&(n.structuredQuery.limit=a),e.startAt&&(n.structuredQuery.startAt=function(u){return{before:u.inclusive,values:u.position}}(e.startAt)),e.endAt&&(n.structuredQuery.endAt=function(u){return{before:!u.inclusive,values:u.position}}(e.endAt)),{_t:n,parent:i}}function z9(t){let e=j9(t.parent);
2538const n=t.structuredQuery,r=n.from?n.from.length:0;let i=null;if(r>0){bt(r===1);const c=n.from[0];c.allDescendants?i=c.collectionId:e=e.child(c.collectionId)}let s=[];n.where&&(s=function(d){const f=$O(d);return f instanceof di&&gO(f)?f.getFilters():[f]}(n.where));let o=[];n.orderBy&&(o=function(d){return d.map(f=>function(_){return new Op(xl(_.field),function(w){switch(w){case"ASCENDING":return"asc";case"DESCENDING":return"desc";default:return}}(_.direction))}(f))}(n.orderBy));let a=null;n.limit&&(a=function(d){let f;return f=typeof d=="object"?d.value:d,Cm(f)?null:f}(n.limit));let l=null;n.startAt&&(l=function(d){const f=!!d.before,p=d.values||[];return new Ip(p,f)}(n.startAt));let u=null;return n.endAt&&(u=function(d){const f=!d.before,p=d.values||[];return new Ip(p,f)}(n.endAt)),l9(e,i,o,s,a,"F",l,u)}function q9(t,e){const n=function(i){switch(i){case"TargetPurposeListen":return null;case"TargetPurposeExistenceFilterMismatch":return"existence-filter-mismatch";case"TargetPurposeExistenceFilterMismatchBloom":return"existence-filter-mismatch-bloom";case"TargetPurposeLimboResolution":return"limbo-document";default:return ze()}}(e.purpose);return n==null?null:{"goog-listen-tags":n}}function $O(t){return t.unaryFilter!==void 0?function(n){switch(n.unaryFilter.op){case"IS_NAN":const r=xl(n.unaryFilter.field);return un.create(r,"==",{doubleValue:NaN});case"IS_NULL":const i=xl(n.unaryFilter.field);return un.create(i,"==",{nullValue:"NULL_VALUE"});case"IS_NOT_NAN":const s=xl(n.unaryFilter.field);return un.create(s,"!=",{doubleValue:NaN});case"IS_NOT_NULL":const o=xl(n.unaryFilter.field);return un.create(o,"!=",{nullValue:"NULL_VALUE"});default:return ze()}}(t):t.fieldFilter!==void 0?function(n){return un.create(xl(n.fieldFilter.field),function(i){switch(i){case"EQUAL":return"==";case"NOT_EQUAL":return"!=";case"GREATER_THAN":return">";case"GREATER_THAN_OR_EQUAL":return">=";case"LESS_THAN":return"<";case"LESS_THAN_OR_EQUAL":return"<=";case"ARRAY_CONTAINS":return"array-contains";case"IN":return"in";case"NOT_IN":return"not-in";case"ARRAY_CONTAINS_ANY":return"array-contains-any";default:return ze()}}(n.fieldFilter.op),n.fieldFilter.value)}(t):t.compositeFilter!==void 0?function(n){return di.create(n.compositeFilter.filters.map(r=>$O(r)),function(i){switch(i){case"AND":return"and";case"OR":return"or";default:return ze()}}(n.compositeFilter.op))}(t):ze()}function H9(t){return C9[t]}function W9(t){return N9[t]}function G9(t){return D9[t]}function El(t){return{fieldPath:t.canonicalString()}}function xl(t){return xn.fromServerFormat(t.fieldPath)}function BO(t){return t instanceof un?function(n){if(n.op==="=="){if(Mx(n.value))return{unaryFilter:{field:El(n.field),op:"IS_NAN"}};if(Dx(n.value))return{unaryFilter:{field:El(n.field),op:"IS_NULL"}}}else if(n.op==="!="){if(Mx(n.value))return{unaryFilter:{field:El(n.field),op:"IS_NOT_NAN"}};if(Dx(n.value))return{unaryFilter:{field:El(n.field),op:"IS_NOT_NULL"}}}return{fieldFilter:{field:El(n.field),op:W9(n.op),value:n.value}}}(t):t instanceof di?function(n){const r=n.getFilters().map(i=>BO(i));return r.length===1?r[0]:{compositeFilter:{op:G9(n.op),filters:r}}}(t):ze()}function K9(t){const e=[];return t.fields.forEach(n=>e.push(n.canonicalString())),{fieldPaths:e}}function zO(t){return t.length>=4&&t.get(0)==="projects"&&t.get(2)==="databases"}/** 2539 * @license 2540 * Copyright 2017 Google LLC 2541 * 2542 * Licensed under the Apache License, Version 2.0 (the "License"); 2543 * you may not use this file except in compliance with the License. 2544 * You may obtain a copy of the License at 2545 * 2546 * http://www.apache.org/licenses/LICENSE-2.0 2547 * 2548 * Unless required by applicable law or agreed to in writing, software 2549 * distributed under the License is distributed on an "AS IS" BASIS, 2550 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2551 * See the License for the specific language governing permissions and 2552 * limitations under the License. 2553 */class xo{constructor(e,n,r,i,s=He.min(),o=He.min(),a=An.EMPTY_BYTE_STRING,l=null){this.target=e,this.targetId=n,this.purpose=r,this.sequenceNumber=i,this.snapshotVersion=s,this.lastLimboFreeSnapshotVersion=o,this.resumeToken=a,this.expectedCount=l}withSequenceNumber(e){return new xo(this.target,this.targetId,this.purpose,e,this.snapshotVersion,this.lastLimboFreeSnapshotVersion,this.resumeToken,this.expectedCount)}withResumeToken(e,n){return new xo(this.target,this.targetId,this.purpose,this.sequenceNumber,n,this.lastLimboFreeSnapshotVersion,e,null)}withExpectedCount(e){return new xo(this.target,this.targetId,this.purpose,this.sequenceNumber,this.snapshotVersion,this.lastLimboFreeSnapshotVersion,this.resumeToken,e)}withLastLimboFreeSnapshotVersion(e){return new xo(this.target,this.targetId,this.purpose,this.sequenceNumber,this.snapshotVersion,e,this.resumeToken,this.expectedCount)}}/** 2554 * @license 2555 * Copyright 2017 Google LLC 2556 * 2557 * Licensed under the Apache License, Version 2.0 (the "License");
2558 * you may not use this file except in compliance with the License. 2559 * You may obtain a copy of the License at 2560 * 2561 * http://www.apache.org/licenses/LICENSE-2.0 2562 * 2563 * Unless required by applicable law or agreed to in writing, software 2564 * distributed under the License is distributed on an "AS IS" BASIS, 2565 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2566 * See the License for the specific language governing permissions and 2567 * limitations under the License. 2568 */class Y9{constructor(e){this.ct=e}}function Q9(t){const e=z9({parent:t.parent,structuredQuery:t.structuredQuery});return t.limitType==="LAST"?Uy(e,e.limit,"L"):e}/** 2569 * @license 2570 * Copyright 2019 Google LLC 2571 * 2572 * Licensed under the Apache License, Version 2.0 (the "License"); 2573 * you may not use this file except in compliance with the License. 2574 * You may obtain a copy of the License at 2575 * 2576 * http://www.apache.org/licenses/LICENSE-2.0 2577 * 2578 * Unless required by applicable law or agreed to in writing, software 2579 * distributed under the License is distributed on an "AS IS" BASIS, 2580 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2581 * See the License for the specific language governing permissions and 2582 * limitations under the License. 2583 */class Z9{constructor(){this.un=new X9}addToCollectionParentIndex(e,n){return this.un.add(n),fe.resolve()}getCollectionParents(e,n){return fe.resolve(this.un.getEntries(n))}addFieldIndex(e,n){return fe.resolve()}deleteFieldIndex(e,n){return fe.resolve()}deleteAllFieldIndexes(e){return fe.resolve()}createTargetIndexes(e,n){return fe.resolve()}getDocumentsMatchingTarget(e,n){return fe.resolve(null)}getIndexType(e,n){return fe.resolve(0)}getFieldIndexes(e,n){return fe.resolve([])}getNextCollectionGroupToUpdate(e){return fe.resolve(null)}getMinOffset(e,n){return fe.resolve(Bo.min())}getMinOffsetFromCollectionGroup(e,n){return fe.resolve(Bo.min())}updateCollectionGroup(e,n,r){return fe.resolve()}updateIndexEntries(e,n){return fe.resolve()}}class X9{constructor(){this.index={}}add(e){const n=e.lastSegment(),r=e.popLast(),i=this.index[n]||new Sn(Lt.comparator),s=!i.has(r);return this.index[n]=i.add(r),s}has(e){const n=e.lastSegment(),r=e.popLast(),i=this.index[n];return i&&i.has(r)}getEntries(e){return(this.index[e]||new Sn(Lt.comparator)).toArray()}}/** 2584 * @license 2585 * Copyright 2017 Google LLC 2586 * 2587 * Licensed under the Apache License, Version 2.0 (the "License"); 2588 * you may not use this file except in compliance with the License. 2589 * You may obtain a copy of the License at 2590 * 2591 * http://www.apache.org/licenses/LICENSE-2.0 2592 * 2593 * Unless required by applicable law or agreed to in writing, software 2594 * distributed under the License is distributed on an "AS IS" BASIS, 2595 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2596 * See the License for the specific language governing permissions and 2597 * limitations under the License. 2598 */class Su{constructor(e){this.Ln=e}next(){return this.Ln+=2,this.Ln}static Bn(){return new Su(0)}static kn(){return new Su(-1)}}/** 2599 * @license 2600 * Copyright 2017 Google LLC 2601 * 2602 * Licensed under the Apache License, Version 2.0 (the "License"); 2603 * you may not use this file except in compliance with the License. 2604 * You may obtain a copy of the License at 2605 * 2606 * http://www.apache.org/licenses/LICENSE-2.0 2607 * 2608 * Unless required by applicable law or agreed to in writing, software 2609 * distributed under the License is distributed on an "AS IS" BASIS, 2610 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2611 * See the License for the specific language governing permissions and 2612 * limitations under the License. 2613 */class J9{constructor(){this.changes=new ju(e=>e.toString(),(e,n)=>e.isEqual(n)),this.changesApplied=!1}addEntry(e){this.assertNotApplied(),this.changes.set(e.key,e)}removeEntry(e,n){this.assertNotApplied(),this.changes.set(e,Ln.newInvalidDocument(e).setReadTime(n))}getEntry(e,n){this.assertNotApplied();const r=this.changes.get(n);return r!==void 0?fe.resolve(r):this.getFromCache(e,n)}getEntries(e,n){return this.getAllFromCache(e,n)}apply(e){return this.assertNotApplied(),this.changesApplied=!0,this.applyChanges(e)}
vendor: 9,262 bytes, lines 2613-2692
2613assertNotApplied(){}}/** 2614 * @license 2615 * Copyright 2017 Google LLC 2616 * 2617 * Licensed under the Apache License, Version 2.0 (the "License"); 2618 * you may not use this file except in compliance with the License. 2619 * You may obtain a copy of the License at 2620 * 2621 * http://www.apache.org/licenses/LICENSE-2.0 2622 * 2623 * Unless required by applicable law or agreed to in writing, software 2624 * distributed under the License is distributed on an "AS IS" BASIS, 2625 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2626 * See the License for the specific language governing permissions and 2627 * limitations under the License. 2628 *//** 2629 * @license 2630 * Copyright 2022 Google LLC 2631 * 2632 * Licensed under the Apache License, Version 2.0 (the "License"); 2633 * you may not use this file except in compliance with the License. 2634 * You may obtain a copy of the License at 2635 * 2636 * http://www.apache.org/licenses/LICENSE-2.0 2637 * 2638 * Unless required by applicable law or agreed to in writing, software 2639 * distributed under the License is distributed on an "AS IS" BASIS, 2640 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2641 * See the License for the specific language governing permissions and 2642 * limitations under the License. 2643 */class eV{constructor(e,n){this.overlayedDocument=e,this.mutatedFields=n}}/** 2644 * @license 2645 * Copyright 2017 Google LLC 2646 * 2647 * Licensed under the Apache License, Version 2.0 (the "License"); 2648 * you may not use this file except in compliance with the License. 2649 * You may obtain a copy of the License at 2650 * 2651 * http://www.apache.org/licenses/LICENSE-2.0 2652 * 2653 * Unless required by applicable law or agreed to in writing, software 2654 * distributed under the License is distributed on an "AS IS" BASIS, 2655 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2656 * See the License for the specific language governing permissions and 2657 * limitations under the License. 2658 */class tV{constructor(e,n,r,i){this.remoteDocumentCache=e,this.mutationQueue=n,this.documentOverlayCache=r,this.indexManager=i}getDocument(e,n){let r=null;return this.documentOverlayCache.getOverlay(e,n).next(i=>(r=i,this.remoteDocumentCache.getEntry(e,n))).next(i=>(r!==null&&Qc(r.mutation,i,xr.empty(),pn.now()),i))}getDocuments(e,n){return this.remoteDocumentCache.getEntries(e,n).next(r=>this.getLocalViewOfDocuments(e,r,rt()).next(()=>r))}getLocalViewOfDocuments(e,n,r=rt()){const i=xa();return this.populateOverlays(e,i,n).next(()=>this.computeViews(e,n,i,r).next(s=>{let o=Rc();return s.forEach((a,l)=>{o=o.insert(a,l.overlayedDocument)}),o}))}getOverlayedDocuments(e,n){const r=xa();return this.populateOverlays(e,r,n).next(()=>this.computeViews(e,n,r,rt()))}populateOverlays(e,n,r){const i=[];return r.forEach(s=>{n.has(s)||i.push(s)}),this.documentOverlayCache.getOverlays(e,i).next(s=>{s.forEach((o,a)=>{n.set(o,a)})})}computeViews(e,n,r,i){let s=Ds();const o=Yc(),a=function(){return Yc()}();return n.forEach((l,u)=>{const c=r.get(u.key);i.has(u.key)&&(c===void 0||c.mutation instanceof ea)?s=s.insert(u.key,u):c!==void 0?(o.set(u.key,c.mutation.getFieldMask()),Qc(c.mutation,u,c.mutation.getFieldMask(),pn.now())):o.set(u.key,xr.empty())}),this.recalculateAndSaveOverlays(e,s).next(l=>(l.forEach((u,c)=>o.set(u,c)),n.forEach((u,c)=>{var d;return a.set(u,new eV(c,(d=o.get(u))!==null&&d!==void 0?d:null))}),a))}recalculateAndSaveOverlays(e,n){const r=Yc();let i=new Kt((o,a)=>o-a),s=rt();return this.mutationQueue.getAllMutationBatchesAffectingDocumentKeys(e,n).next(o=>{for(const a of o)a.keys().forEach(l=>{const u=n.get(l);if(u===null)return;let c=r.get(l)||xr.empty();c=a.applyToLocalView(u,c),r.set(l,c);const d=(i.get(a.batchId)||rt()).add(l);i=i.insert(a.batchId,d)})}).next(()=>{const o=[],a=i.getReverseIterator();for(;a.hasNext();){const l=a.getNext(),u=l.key,c=l.value,d=SO();c.forEach(f=>{if(!s.has(f)){const p=RO(n.get(f),r.get(f));p!==null&&d.set(f,p),s=s.add(f)}}),o.push(this.documentOverlayCache.saveOverlays(e,u,d))}return fe.waitFor(o)}).next(()=>r)}recalculateAndSaveOverlaysForDocumentKeys(e,n){return this.remoteDocumentCache.getEntries(e,n).next(r=>this.recalculateAndSaveOverlays(e,r))}getDocumentsMatchingQuery(e,n,r,i){return function(o){return Le.isDocumentKey(o.path)&&o.collectionGroup===null&&o.filters.length===0}(n)?this.getDocumentsMatchingDocumentQuery(e,n.path):wO(n)?this.getDocumentsMatchingCollectionGroupQuery(e,n,r,i):this.getDocumentsMatchingCollectionQuery(e,n,r,i)}getNextDocuments(e,n,r,i){return this.remoteDocumentCache.getAllFromCollectionGroup(e,n,r,i).next(s=>{const o=i-s.size>0?this.documentOverlayCache.getOverlaysForCollectionGroup(e,n,r.largestBatchId,i-s.size):fe.resolve(xa());let a=-1,l=s;return o.next(u=>fe.forEach(u,(c,d)=>(a<d.largestBatchId&&(a=d.largestBatchId),s.get(c)?fe.resolve():this.remoteDocumentCache.getEntry(e,c).next(f=>{l=l.insert(c,f)}))).next(()=>this.populateOverlays(e,u,s)).next(()=>this.computeViews(e,l,u,rt())).next(c=>({batchId:a,changes:TO(c)})))})}getDocumentsMatchingDocumentQuery(e,n){return this.getDocument(e,new Le(n)).next(r=>{let i=Rc();return r.isFoundDocument()&&(i=i.insert(r.key,r)),i})}getDocumentsMatchingCollectionGroupQuery(e,n,r,i){const s=n.collectionGroup;let o=Rc();return this.indexManager.getCollectionParents(e,s).next(a=>fe.forEach(a,l=>{const u=function(d,f){return new od(f,null,d.explicitOrderBy.slice(),d.filters.slice(),d.limit,d.limitType,d.startAt,d.endAt)}(n,l.child(s));return this.getDocumentsMatchingCollectionQuery(e,u,r,i).next(c=>{c.forEach((d,f)=>{o=o.insert(d,f)})})}).next(()=>o))}getDocumentsMatchingCollectionQuery(e,n,r,i){let s;return this.documentOverlayCache.getOverlaysForCollection(e,n.path,r.largestBatchId).next(o=>(s=o,this.remoteDocumentCache.getDocumentsMatchingQuery(e,n,r,s,i))).next(o=>{s.forEach((l,u)=>{const c=u.getKey();o.get(c)===null&&(o=o.insert(c,Ln.newInvalidDocument(c)))});let a=Rc();return o.forEach((l,u)=>{const c=s.get(l);c!==void 0&&Qc(c.mutation,u,xr.empty(),pn.now()),Dm(n,u)&&(a=a.insert(l,u))}),a})}}/** 2659 * @license 2660 * Copyright 2020 Google LLC 2661 * 2662 * Licensed under the Apache License, Version 2.0 (the "License"); 2663 * you may not use this file except in compliance with the License. 2664 * You may obtain a copy of the License at 2665 * 2666 * http://www.apache.org/licenses/LICENSE-2.0 2667 * 2668 * Unless required by applicable law or agreed to in writing, software 2669 * distributed under the License is distributed on an "AS IS" BASIS, 2670 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2671 * See the License for the specific language governing permissions and 2672 * limitations under the License. 2673 */class nV{constructor(e){this.serializer=e,this.hr=new Map,this.Pr=new Map}getBundleMetadata(e,n){return fe.resolve(this.hr.get(n))}saveBundleMetadata(e,n){return this.hr.set(n.id,function(i){return{id:i.id,version:i.version,createTime:ji(i.createTime)}}(n)),fe.resolve()}getNamedQuery(e,n){return fe.resolve(this.Pr.get(n))}saveNamedQuery(e,n){return this.Pr.set(n.name,function(i){return{name:i.name,query:Q9(i.bundledQuery),readTime:ji(i.readTime)}}(n)),fe.resolve()}}/** 2674 * @license 2675 * Copyright 2022 Google LLC 2676 * 2677 * Licensed under the Apache License, Version 2.0 (the "License"); 2678 * you may not use this file except in compliance with the License. 2679 * You may obtain a copy of the License at 2680 * 2681 * http://www.apache.org/licenses/LICENSE-2.0 2682 * 2683 * Unless required by applicable law or agreed to in writing, software 2684 * distributed under the License is distributed on an "AS IS" BASIS, 2685 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2686 * See the License for the specific language governing permissions and 2687 * limitations under the License. 2688 */class rV{constructor(){this.overlays=new Kt(Le.comparator),this.Ir=new Map}getOverlay(e,n){return fe.resolve(this.overlays.get(n))}getOverlays(e,n){const r=xa();return fe.forEach(n,i=>this.getOverlay(e,i).next(s=>{s!==null&&r.set(i,s)})).next(()=>r)}saveOverlays(e,n,r){return r.forEach((i,s)=>{this.ht(e,n,s)}),fe.resolve()}removeOverlaysForBatchId(e,n,r){const i=this.Ir.get(r);return i!==void 0&&(i.forEach(s=>this.overlays=this.overlays.remove(s)),this.Ir.delete(r)),fe.resolve()}getOverlaysForCollection(e,n,r){const i=xa(),s=n.length+1,o=new Le(n.child("")),a=this.overlays.getIteratorFrom(o);for(;a.hasNext();){const l=a.getNext().value,u=l.getKey();if(!n.isPrefixOf(u.path))break;u.path.length===s&&l.largestBatchId>r&&i.set(l.getKey(),l)}return fe.resolve(i)}getOverlaysForCollectionGroup(e,n,r,i){let s=new Kt((u,c)=>u-c);const o=this.overlays.getIterator();for(;o.hasNext();){const u=o.getNext().value;if(u.getKey().getCollectionGroup()===n&&u.largestBatchId>r){let c=s.get(u.largestBatchId);c===null&&(c=xa(),s=s.insert(u.largestBatchId,c)),c.set(u.getKey(),u)}}const a=xa(),l=s.getIterator();for(;l.hasNext()&&(l.getNext().value.forEach((u,c)=>a.set(u,c)),!(a.size()>=i)););return fe.resolve(a)}ht(e,n,r){const i=this.overlays.get(r.key);if(i!==null){const o=this.Ir.get(i.largestBatchId).delete(r.key);this.Ir.set(i.largestBatchId,o)}this.overlays=this.overlays.insert(r.key,new k9(n,r));let s=this.Ir.get(n);s===void 0&&(s=rt(),this.Ir.set(n,s)),this.Ir.set(n,s.add(r.key))}}/** 2689 * @license 2690 * Copyright 2024 Google LLC 2691 * 2692 * Licensed under the Apache License, Version 2.0 (the "License");
2693 * you may not use this file except in compliance with the License. 2694 * You may obtain a copy of the License at 2695 * 2696 * http://www.apache.org/licenses/LICENSE-2.0 2697 * 2698 * Unless required by applicable law or agreed to in writing, software 2699 * distributed under the License is distributed on an "AS IS" BASIS, 2700 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2701 * See the License for the specific language governing permissions and 2702 * limitations under the License. 2703 */class iV{constructor(){this.sessionToken=An.EMPTY_BYTE_STRING}getSessionToken(e){return fe.resolve(this.sessionToken)}setSessionToken(e,n){return this.sessionToken=n,fe.resolve()}}/** 2704 * @license 2705 * Copyright 2017 Google LLC 2706 * 2707 * Licensed under the Apache License, Version 2.0 (the "License"); 2708 * you may not use this file except in compliance with the License. 2709 * You may obtain a copy of the License at 2710 * 2711 * http://www.apache.org/licenses/LICENSE-2.0 2712 * 2713 * Unless required by applicable law or agreed to in writing, software 2714 * distributed under the License is distributed on an "AS IS" BASIS, 2715 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2716 * See the License for the specific language governing permissions and 2717 * limitations under the License. 2718 */class y1{constructor(){this.Tr=new Sn(gn.Er),this.dr=new Sn(gn.Ar)}isEmpty(){return this.Tr.isEmpty()}addReference(e,n){const r=new gn(e,n);this.Tr=this.Tr.add(r),this.dr=this.dr.add(r)}Rr(e,n){e.forEach(r=>this.addReference(r,n))}removeReference(e,n){this.Vr(new gn(e,n))}mr(e,n){e.forEach(r=>this.removeReference(r,n))}gr(e){const n=new Le(new Lt([])),r=new gn(n,e),i=new gn(n,e+1),s=[];return this.dr.forEachInRange([r,i],o=>{this.Vr(o),s.push(o.key)}),s}pr(){this.Tr.forEach(e=>this.Vr(e))}Vr(e){this.Tr=this.Tr.delete(e),this.dr=this.dr.delete(e)}yr(e){const n=new Le(new Lt([])),r=new gn(n,e),i=new gn(n,e+1);let s=rt();return this.dr.forEachInRange([r,i],o=>{s=s.add(o.key)}),s}containsKey(e){const n=new gn(e,0),r=this.Tr.firstAfterOrEqual(n);return r!==null&&e.isEqual(r.key)}}class gn{constructor(e,n){this.key=e,this.wr=n}static Er(e,n){return Le.comparator(e.key,n.key)||pt(e.wr,n.wr)}static Ar(e,n){return pt(e.wr,n.wr)||Le.comparator(e.key,n.key)}}/** 2719 * @license 2720 * Copyright 2017 Google LLC 2721 * 2722 * Licensed under the Apache License, Version 2.0 (the "License"); 2723 * you may not use this file except in compliance with the License. 2724 * You may obtain a copy of the License at 2725 * 2726 * http://www.apache.org/licenses/LICENSE-2.0 2727 * 2728 * Unless required by applicable law or agreed to in writing, software 2729 * distributed under the License is distributed on an "AS IS" BASIS, 2730 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2731 * See the License for the specific language governing permissions and 2732 * limitations under the License. 2733 */class sV{constructor(e,n){this.indexManager=e,this.referenceDelegate=n,this.mutationQueue=[],this.Sr=1,this.br=new Sn(gn.Er)}checkEmpty(e){return fe.resolve(this.mutationQueue.length===0)}addMutationBatch(e,n,r,i){const s=this.Sr;this.Sr++,this.mutationQueue.length>0&&this.mutationQueue[this.mutationQueue.length-1];const o=new S9(s,n,r,i);this.mutationQueue.push(o);for(const a of i)this.br=this.br.add(new gn(a.key,s)),this.indexManager.addToCollectionParentIndex(e,a.key.path.popLast());return fe.resolve(o)}lookupMutationBatch(e,n){return fe.resolve(this.Dr(n))}getNextMutationBatchAfterBatchId(e,n){const r=n+1,i=this.vr(r),s=i<0?0:i;return fe.resolve(this.mutationQueue.length>s?this.mutationQueue[s]:null)}getHighestUnacknowledgedBatchId(){return fe.resolve(this.mutationQueue.length===0?-1:this.Sr-1)}getAllMutationBatches(e){return fe.resolve(this.mutationQueue.slice())}getAllMutationBatchesAffectingDocumentKey(e,n){const r=new gn(n,0),i=new gn(n,Number.POSITIVE_INFINITY),s=[];return this.br.forEachInRange([r,i],o=>{const a=this.Dr(o.wr);s.push(a)}),fe.resolve(s)}getAllMutationBatchesAffectingDocumentKeys(e,n){let r=new Sn(pt);return n.forEach(i=>{const s=new gn(i,0),o=new gn(i,Number.POSITIVE_INFINITY);this.br.forEachInRange([s,o],a=>{r=r.add(a.wr)})}),fe.resolve(this.Cr(r))}getAllMutationBatchesAffectingQuery(e,n){const r=n.path,i=r.length+1;let s=r;Le.isDocumentKey(s)||(s=s.child(""));const o=new gn(new Le(s),0);let a=new Sn(pt);return this.br.forEachWhile(l=>{const u=l.key.path;return!!r.isPrefixOf(u)&&(u.length===i&&(a=a.add(l.wr)),!0)},o),fe.resolve(this.Cr(a))}Cr(e){const n=[];return e.forEach(r=>{const i=this.Dr(r);i!==null&&n.push(i)}),n}removeMutationBatch(e,n){bt(this.Fr(n.batchId,"removed")===0),this.mutation
2733Queue.shift();let r=this.br;return fe.forEach(n.mutations,i=>{const s=new gn(i.key,n.batchId);return r=r.delete(s),this.referenceDelegate.markPotentiallyOrphaned(e,i.key)}).next(()=>{this.br=r})}On(e){}containsKey(e,n){const r=new gn(n,0),i=this.br.firstAfterOrEqual(r);return fe.resolve(n.isEqual(i&&i.key))}performConsistencyCheck(e){return this.mutationQueue.length,fe.resolve()}Fr(e,n){return this.vr(e)}vr(e){return this.mutationQueue.length===0?0:e-this.mutationQueue[0].batchId}Dr(e){const n=this.vr(e);return n<0||n>=this.mutationQueue.length?null:this.mutationQueue[n]}}/** 2734 * @license 2735 * Copyright 2017 Google LLC 2736 * 2737 * Licensed under the Apache License, Version 2.0 (the "License"); 2738 * you may not use this file except in compliance with the License. 2739 * You may obtain a copy of the License at 2740 * 2741 * http://www.apache.org/licenses/LICENSE-2.0 2742 * 2743 * Unless required by applicable law or agreed to in writing, software 2744 * distributed under the License is distributed on an "AS IS" BASIS, 2745 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2746 * See the License for the specific language governing permissions and 2747 * limitations under the License. 2748 */class oV{constructor(e){this.Mr=e,this.docs=function(){return new Kt(Le.comparator)}(),this.size=0}setIndexManager(e){this.indexManager=e}addEntry(e,n){const r=n.key,i=this.docs.get(r),s=i?i.size:0,o=this.Mr(n);return this.docs=this.docs.insert(r,{document:n.mutableCopy(),size:o}),this.size+=o-s,this.indexManager.addToCollectionParentIndex(e,r.path.popLast())}removeEntry(e){const n=this.docs.get(e);n&&(this.docs=this.docs.remove(e),this.size-=n.size)}getEntry(e,n){const r=this.docs.get(n);return fe.resolve(r?r.document.mutableCopy():Ln.newInvalidDocument(n))}getEntries(e,n){let r=Ds();return n.forEach(i=>{const s=this.docs.get(i);r=r.insert(i,s?s.document.mutableCopy():Ln.newInvalidDocument(i))}),fe.resolve(r)}getDocumentsMatchingQuery(e,n,r,i){let s=Ds();const o=n.path,a=new Le(o.child("")),l=this.docs.getIteratorFrom(a);for(;l.hasNext();){const{key:u,value:{document:c}}=l.getNext();if(!o.isPrefixOf(u.path))break;u.path.length>o.length+1||z5(B5(c),r)<=0||(i.has(c.key)||Dm(n,c))&&(s=s.insert(c.key,c.mutableCopy()))}return fe.resolve(s)}getAllFromCollectionGroup(e,n,r,i){ze()}Or(e,n){return fe.forEach(this.docs,r=>n(r))}newChangeBuffer(e){return new aV(this)}getSize(e){return fe.resolve(this.size)}}class aV extends J9{constructor(e){super(),this.cr=e}applyChanges(e){const n=[];
vendor: 9,828 bytes, lines 2748-2823
2748return this.changes.forEach((r,i)=>{i.isValidDocument()?n.push(this.cr.addEntry(e,i)):this.cr.removeEntry(r)}),fe.waitFor(n)}getFromCache(e,n){return this.cr.getEntry(e,n)}getAllFromCache(e,n){return this.cr.getEntries(e,n)}}/** 2749 * @license 2750 * Copyright 2017 Google LLC 2751 * 2752 * Licensed under the Apache License, Version 2.0 (the "License"); 2753 * you may not use this file except in compliance with the License. 2754 * You may obtain a copy of the License at 2755 * 2756 * http://www.apache.org/licenses/LICENSE-2.0 2757 * 2758 * Unless required by applicable law or agreed to in writing, software 2759 * distributed under the License is distributed on an "AS IS" BASIS, 2760 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2761 * See the License for the specific language governing permissions and 2762 * limitations under the License. 2763 */class lV{constructor(e){this.persistence=e,this.Nr=new ju(n=>f1(n),d1),this.lastRemoteSnapshotVersion=He.min(),this.highestTargetId=0,this.Lr=0,this.Br=new y1,this.targetCount=0,this.kr=Su.Bn()}forEachTarget(e,n){return this.Nr.forEach((r,i)=>n(i)),fe.resolve()}getLastRemoteSnapshotVersion(e){return fe.resolve(this.lastRemoteSnapshotVersion)}getHighestSequenceNumber(e){return fe.resolve(this.Lr)}allocateTargetId(e){return this.highestTargetId=this.kr.next(),fe.resolve(this.highestTargetId)}setTargetsMetadata(e,n,r){return r&&(this.lastRemoteSnapshotVersion=r),n>this.Lr&&(this.Lr=n),fe.resolve()}Kn(e){this.Nr.set(e.target,e);const n=e.targetId;n>this.highestTargetId&&(this.kr=new Su(n),this.highestTargetId=n),e.sequenceNumber>this.Lr&&(this.Lr=e.sequenceNumber)}addTargetData(e,n){return this.Kn(n),this.targetCount+=1,fe.resolve()}updateTargetData(e,n){return this.Kn(n),fe.resolve()}removeTargetData(e,n){return this.Nr.delete(n.target),this.Br.gr(n.targetId),this.targetCount-=1,fe.resolve()}removeTargets(e,n,r){let i=0;const s=[];return this.Nr.forEach((o,a)=>{a.sequenceNumber<=n&&r.get(a.targetId)===null&&(this.Nr.delete(o),s.push(this.removeMatchingKeysForTargetId(e,a.targetId)),i++)}),fe.waitFor(s).next(()=>i)}getTargetCount(e){return fe.resolve(this.targetCount)}getTargetData(e,n){const r=this.Nr.get(n)||null;return fe.resolve(r)}addMatchingKeys(e,n,r){return this.Br.Rr(n,r),fe.resolve()}removeMatchingKeys(e,n,r){this.Br.mr(n,r);const i=this.persistence.referenceDelegate,s=[];return i&&n.forEach(o=>{s.push(i.markPotentiallyOrphaned(e,o))}),fe.waitFor(s)}removeMatchingKeysForTargetId(e,n){return this.Br.gr(n),fe.resolve()}getMatchingKeysForTargetId(e,n){const r=this.Br.yr(n);return fe.resolve(r)}containsKey(e,n){return fe.resolve(this.Br.containsKey(n))}}/** 2764 * @license 2765 * Copyright 2017 Google LLC 2766 * 2767 * Licensed under the Apache License, Version 2.0 (the "License"); 2768 * you may not use this file except in compliance with the License. 2769 * You may obtain a copy of the License at 2770 * 2771 * http://www.apache.org/licenses/LICENSE-2.0 2772 * 2773 * Unless required by applicable law or agreed to in writing, software 2774 * distributed under the License is distributed on an "AS IS" BASIS, 2775 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2776 * See the License for the specific language governing permissions and 2777 * limitations under the License. 2778 */class uV{constructor(e,n){this.qr={},this.overlays={},this.Qr=new a1(0),this.Kr=!1,this.Kr=!0,this.$r=new iV,this.referenceDelegate=e(this),this.Ur=new lV(this),this.indexManager=new Z9,this.remoteDocumentCache=function(i){return new oV(i)}(r=>this.referenceDelegate.Wr(r)),this.serializer=new Y9(n),this.Gr=new nV(this.serializer)}start(){return Promise.resolve()}shutdown(){return this.Kr=!1,Promise.resolve()}get started(){return this.Kr}setDatabaseDeletedListener(){}setNetworkEnabled(){}getIndexManager(e){return this.indexManager}getDocumentOverlayCache(e){let n=this.overlays[e.toKey()];return n||(n=new rV,this.overlays[e.toKey()]=n),n}getMutationQueue(e,n){let r=this.qr[e.toKey()];return r||(r=new sV(n,this.referenceDelegate),this.qr[e.toKey()]=r),r}getGlobalsCache(){return this.$r}getTargetCache(){return this.Ur}getRemoteDocumentCache(){return this.remoteDocumentCache}getBundleCache(){return this.Gr}runTransaction(e,n,r){Oe("MemoryPersistence","Starting transaction:",e);const i=new cV(this.Qr.next());return this.referenceDelegate.zr(),r(i).next(s=>this.referenceDelegate.jr(i).next(()=>s)).toPromise().then(s=>(i.raiseOnCommittedEvent(),s))}Hr(e,n){return fe.or(Object.values(this.qr).map(r=>()=>r.containsKey(e,n)))}}class cV extends H5{constructor(e){super(),this.currentSequenceNumber=e}}class _1{constructor(e){this.persistence=e,this.Jr=new y1,this.Yr=null}static Zr(e){return new _1(e)}get Xr(){if(this.Yr)return this.Yr;throw ze()}addReference(e,n,r){return this.Jr.addReference(r,n),this.Xr.delete(r.toString()),fe.resolve()}removeReference(e,n,r){return this.Jr.removeReference(r,n),this.Xr.add(r.toString()),fe.resolve()}markPotentiallyOrphaned(e,n){return this.Xr.add(n.toString()),fe.resolve()}removeTarget(e,n){this.Jr.gr(n.targetId).forEach(i=>this.Xr.add(i.toString()));const r=this.persistence.getTargetCache();return r.getMatchingKeysForTargetId(e,n.targetId).next(i=>{i.forEach(s=>this.Xr.add(s.toString()))}).next(()=>r.removeTargetData(e,n))}zr(){this.Yr=new Set}jr(e){const n=this.persistence.getRemoteDocumentCache().newChangeBuffer();return fe.forEach(this.Xr,r=>{const i=Le.fromPath(r);return this.ei(e,i).next(s=>{s||n.removeEntry(i,He.min())})}).next(()=>(this.Yr=null,n.apply(e)))}updateLimboDocument(e,n){return this.ei(e,n).next(r=>{r?this.Xr.delete(n.toString()):this.Xr.add(n.toString())})}Wr(e){return 0}ei(e,n){return fe.or([()=>fe.resolve(this.Jr.containsKey(n)),()=>this.persistence.getTargetCache().containsKey(e,n),()=>this.persistence.Hr(e,n)])}}/** 2779 * @license 2780 * Copyright 2017 Google LLC 2781 * 2782 * Licensed under the Apache License, Version 2.0 (the "License"); 2783 * you may not use this file except in compliance with the License. 2784 * You may obtain a copy of the License at 2785 * 2786 * http://www.apache.org/licenses/LICENSE-2.0 2787 * 2788 * Unless required by applicable law or agreed to in writing, software 2789 * distributed under the License is distributed on an "AS IS" BASIS, 2790 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2791 * See the License for the specific language governing permissions and 2792 * limitations under the License. 2793 */class w1{constructor(e,n,r,i){this.targetId=e,this.fromCache=n,this.$i=r,this.Ui=i}static Wi(e,n){let r=rt(),i=rt();for(const s of n.docChanges)switch(s.type){case 0:r=r.add(s.doc.key);break;case 1:i=i.add(s.doc.key)}return new w1(e,n.fromCache,r,i)}}/** 2794 * @license 2795 * Copyright 2023 Google LLC 2796 * 2797 * Licensed under the Apache License, Version 2.0 (the "License"); 2798 * you may not use this file except in compliance with the License. 2799 * You may obtain a copy of the License at 2800 * 2801 * http://www.apache.org/licenses/LICENSE-2.0 2802 * 2803 * Unless required by applicable law or agreed to in writing, software 2804 * distributed under the License is distributed on an "AS IS" BASIS, 2805 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2806 * See the License for the specific language governing permissions and 2807 * limitations under the License. 2808 */class fV{constructor(){this._documentReadCount=0}get documentReadCount(){return this._documentReadCount}incrementDocumentReadCount(e){this._documentReadCount+=e}}/** 2809 * @license 2810 * Copyright 2019 Google LLC 2811 * 2812 * Licensed under the Apache License, Version 2.0 (the "License"); 2813 * you may not use this file except in compliance with the License. 2814 * You may obtain a copy of the License at 2815 * 2816 * http://www.apache.org/licenses/LICENSE-2.0 2817 * 2818 * Unless required by applicable law or agreed to in writing, software 2819 * distributed under the License is distributed on an "AS IS" BASIS, 2820 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2821 * See the License for the specific language governing permissions and 2822 * limitations under the License. 2823 */class dV{constructor(){this.Gi=!1,this.zi=!1,this.ji=100,this.Hi=function(){return WL()?8:W5(Vn())>0?6:4}()}initialize(e,n){this.Ji=e,this.indexManager=n,this.Gi=!0}getDocumentsMatchingQuery(e,n,r,i){const s={result:null};return this.Yi(e,n).next(o=>{s.result=o}).next(()=>{if(!s.result)return this.Zi(e,n,i,r).next(o=>{s.result=o})}).next(()=>{if(s.result)return;const o=new fV;return this.Xi(e,n,o).next(a=>{if(s.result=a,this.zi)return this.es(e,n,o,a.size)})}).next(()=>s.result)}es(e,n,r,i){return r.documentReadCount<this.ji?(yc()<=at.DEBUG&&Oe("QueryEngine","SDK will not create cache indexes for query:",bl(n),"since it only creates cache indexes for collection contains","more than or equal to",this.ji,"documents"),fe.resolve()):(yc()<=at.DEBUG&&Oe("QueryEngine","Query:",bl(n),"scans",r.documentReadCount,"local documents and returns",i,"documents as results."),r.documentReadCount>this.Hi*i?(yc()<=at.DEBUG&&Oe("QueryEngine","The SDK decides to create cache indexes for query:",bl(n),"as using cache indexes may help improve performance."),this.indexManager.createTargetIndexes(e,Mi(n))):fe.resolve())}Yi(e,n){if(Vx(n))return fe.resolve(null);let r=Mi(n);return this.indexManager.getIndexType(e,r).next(i=>i===0?null:(n.limit!==null&&i===1&&(n=Uy(n,null,"F"),r=Mi(n)),this.indexManager.getDocumentsMatchingTarget(e,r).next(s=>{const o=rt(...s);return this.Ji.getDocuments(e,o).next(a=>this.indexManager.getMinOffset(e,r).next(l=>{const u=this.ts(n,a);return this.ns(n,u,o,l.readTime)?this.Yi(e,Uy(n,null,"F")):this.rs(e,u,n,l)}))})))}Zi(e,n,r,i){return Vx(n)||i.isEqual(He.min())?fe.resolve(null):this.Ji.getDocuments(e,r).next(s=>{const o=this.ts(n,s);return this.ns(n,o,r,i)?fe.resolve(null):(yc()<=at.DEBUG&&Oe("QueryEngine","Re-using previous result from %s to execute query: %s",i.toString(),bl(n)),this.rs(e,o,n,$5(i,-1)).next(a=>a))})}ts(e,n){let r=new Sn(EO(e));
2823return n.forEach((i,s)=>{Dm(e,s)&&(r=r.add(s))}),r}ns(e,n,r,i){if(e.limit===null)return!1;if(r.size!==n.size)return!0;const s=e.limitType==="F"?n.last():n.first();return!!s&&(s.hasPendingWrites||s.version.compareTo(i)>0)}Xi(e,n,r){return yc()<=at.DEBUG&&Oe("QueryEngine","Using full collection scan to execute query:",bl(n)),this.Ji.getDocumentsMatchingQuery(e,n,Bo.min(),r)}rs(e,n,r,i){return this.Ji.getDocumentsMatchingQuery(e,r,i).next(s=>(n.forEach(o=>{s=s.insert(o.key,o)}),s))}}/** 2824 * @license 2825 * Copyright 2020 Google LLC 2826 * 2827 * Licensed under the Apache License, Version 2.0 (the "License"); 2828 * you may not use this file except in compliance with the License. 2829 * You may obtain a copy of the License at 2830 * 2831 * http://www.apache.org/licenses/LICENSE-2.0 2832 * 2833 * Unless required by applicable law or agreed to in writing, software 2834 * distributed under the License is distributed on an "AS IS" BASIS, 2835 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2836 * See the License for the specific language governing permissions and 2837 * limitations under the License. 2838 */class hV{constructor(e,n,r,i){this.persistence=e,this.ss=n,this.serializer=i,this.os=new Kt(pt),this._s=new ju(s=>f1(s),d1),this.us=new Map,this.cs=e.getRemoteDocumentCache(),this.Ur=e.getTargetCache(),this.Gr=e.getBundleCache(),this.ls(r)}ls(e){this.documentOverlayCache=this.persistence.getDocumentOverlayCache(e),this.indexManager=this.persistence.getIndexManager(e),this.mutationQueue=this.persistence.getMutationQueue(e,this.indexManager),this.localDocuments=new tV(this.cs,this.mutationQueue,this.documentOverlayCache,this.indexManager),this.cs.setIndexManager(this.indexManager),this.ss.initialize(this.localDocuments,this.indexManager)}collectGarbage(e){return this.persistence.runTransaction("Collect garbage","readwrite-primary",n=>e.collect(n,this.os))}}function pV(t,e,n,r){return new hV(t,e,n,r)}async function qO(t,e){const n=We(t);return await n.persistence.runTransaction("Handle user change","readonly",r=>{let i;
2838return n.mutationQueue.getAllMutationBatches(r).next(s=>(i=s,n.ls(e),n.mutationQueue.getAllMutationBatches(r))).next(s=>{const o=[],a=[];let l=rt();for(const u of i){o.push(u.batchId);for(const c of u.mutations)l=l.add(c.key)}for(const u of s){a.push(u.batchId);for(const c of u.mutations)l=l.add(c.key)}return n.localDocuments.getDocuments(r,l).next(u=>({hs:u,removedBatchIds:o,addedBatchIds:a}))})})}function mV(t,e){const n=We(t);return n.persistence.runTransaction("Acknowledge batch","readwrite-primary",r=>{const i=e.batch.keys(),s=n.cs.newChangeBuffer({trackRemovals:!0});return function(a,l,u,c){const d=u.batch,f=d.keys();let p=fe.resolve();return f.forEach(_=>{p=p.next(()=>c.getEntry(l,_)).next(y=>{const w=u.docVersions.get(_);bt(w!==null),y.version.compareTo(w)<0&&(d.applyToRemoteDocument(y,u),y.isValidDocument()&&(y.setReadTime(u.commitVersion),c.addEntry(y)))})}),p.next(()=>a.mutationQueue.removeMutationBatch(l,d))}(n,r,e,s).next(()=>s.apply(r)).next(()=>n.mutationQueue.performConsistencyCheck(r)).next(()=>n.documentOverlayCache.removeOverlaysForBatchId(r,i,e.batch.batchId)).next(()=>n.localDocuments.recalculateAndSaveOverlaysForDocumentKeys(r,function(a){let l=rt();for(let u=0;u<a.mutationResults.length;++u)a.mutationResults[u].transformResults.length>0&&(l=l.add(a.batch.mutations[u].key));return l}(e))).next(()=>n.localDocuments.getDocuments(r,i))})}function HO(t){const e=We(t);return e.persistence.runTransaction("Get last remote snapshot version","readonly",n=>e.Ur.getLastRemoteSnapshotVersion(n))}function gV(t,e){const n=We(t),r=e.snapshotVersion;let i=n.os;return n.persistence.runTransaction("Apply remote event","readwrite-primary",s=>{const o=n.cs.newChangeBuffer({trackRemovals:!0});i=n.os;const a=[];
vendor: 4,430 bytes, lines 2838-2842
2838e.targetChanges.forEach((c,d)=>{const f=i.get(d);if(!f)return;a.push(n.Ur.removeMatchingKeys(s,c.removedDocuments,d).next(()=>n.Ur.addMatchingKeys(s,c.addedDocuments,d)));let p=f.withSequenceNumber(s.currentSequenceNumber);e.targetMismatches.get(d)!==null?p=p.withResumeToken(An.EMPTY_BYTE_STRING,He.min()).withLastLimboFreeSnapshotVersion(He.min()):c.resumeToken.approximateByteSize()>0&&(p=p.withResumeToken(c.resumeToken,r)),i=i.insert(d,p),function(y,w,g){return y.resumeToken.approximateByteSize()===0||w.snapshotVersion.toMicroseconds()-y.snapshotVersion.toMicroseconds()>=3e8?!0:g.addedDocuments.size+g.modifiedDocuments.size+g.removedDocuments.size>0}(f,p,c)&&a.push(n.Ur.updateTargetData(s,p))});let l=Ds(),u=rt();if(e.documentUpdates.forEach(c=>{e.resolvedLimboDocuments.has(c)&&a.push(n.persistence.referenceDelegate.updateLimboDocument(s,c))}),a.push(vV(s,o,e.documentUpdates).next(c=>{l=c.Ps,u=c.Is})),!r.isEqual(He.min())){const c=n.Ur.getLastRemoteSnapshotVersion(s).next(d=>n.Ur.setTargetsMetadata(s,s.currentSequenceNumber,r));a.push(c)}return fe.waitFor(a).next(()=>o.apply(s)).next(()=>n.localDocuments.getLocalViewOfDocuments(s,l,u)).next(()=>l)}).then(s=>(n.os=i,s))}function vV(t,e,n){let r=rt(),i=rt();return n.forEach(s=>r=r.add(s)),e.getEntries(t,r).next(s=>{let o=Ds();return n.forEach((a,l)=>{const u=s.get(a);l.isFoundDocument()!==u.isFoundDocument()&&(i=i.add(a)),l.isNoDocument()&&l.version.isEqual(He.min())?(e.removeEntry(a,l.readTime),o=o.insert(a,l)):!u.isValidDocument()||l.version.compareTo(u.version)>0||l.version.compareTo(u.version)===0&&u.hasPendingWrites?(e.addEntry(l),o=o.insert(a,l)):Oe("LocalStore","Ignoring outdated watch update for ",a,". Current version:",u.version," Watch version:",l.version)}),{Ps:o,Is:i}})}function yV(t,e){const n=We(t);return n.persistence.runTransaction("Get next mutation batch","readonly",r=>(e===void 0&&(e=-1),n.mutationQueue.getNextMutationBatchAfterBatchId(r,e)))}function _V(t,e){const n=We(t);return n.persistence.runTransaction("Allocate target","readwrite",r=>{let i;return n.Ur.getTargetData(r,e).next(s=>s?(i=s,fe.resolve(i)):n.Ur.allocateTargetId(r).next(o=>(i=new xo(e,o,"TargetPurposeListen",r.currentSequenceNumber),n.Ur.addTargetData(r,i).next(()=>i))))}).then(r=>{const i=n.os.get(r.targetId);return(i===null||r.snapshotVersion.compareTo(i.snapshotVersion)>0)&&(n.os=n.os.insert(r.targetId,r),n._s.set(e,r.targetId)),r})}async function Hy(t,e,n){const r=We(t),i=r.os.get(e),s=n?"readwrite":"readwrite-primary";try{n||await r.persistence.runTransaction("Release target",s,o=>r.persistence.referenceDelegate.removeTarget(o,i))}catch(o){if(!sd(o))throw o;Oe("LocalStore",`Failed to update sequence numbers for target ${e}: ${o}`)}r.os=r.os.remove(e),r._s.delete(i.target)}function Qx(t,e,n){const r=We(t);let i=He.min(),s=rt();return r.persistence.runTransaction("Execute query","readwrite",o=>function(l,u,c){const d=We(l),f=d._s.get(c);return f!==void 0?fe.resolve(d.os.get(f)):d.Ur.getTargetData(u,c)}(r,o,Mi(e)).next(a=>{if(a)return i=a.lastLimboFreeSnapshotVersion,r.Ur.getMatchingKeysForTargetId(o,a.targetId).next(l=>{s=l})}).next(()=>r.ss.getDocumentsMatchingQuery(o,e,n?i:He.min(),n?s:rt())).next(a=>(wV(r,c9(e),a),{documents:a,Ts:s})))}function wV(t,e,n){let r=t.us.get(e)||He.min();n.forEach((i,s)=>{s.readTime.compareTo(r)>0&&(r=s.readTime)}),t.us.set(e,r)}class Zx{constructor(){this.activeTargetIds=g9()}fs(e){this.activeTargetIds=this.activeTargetIds.add(e)}gs(e){this.activeTargetIds=this.activeTargetIds.delete(e)}Vs(){const e={activeTargetIds:this.activeTargetIds.toArray(),updateTimeMs:Date.now()};return JSON.stringify(e)}}class bV{constructor(){this.so=new Zx,this.oo={},this.onlineStateHandler=null,this.sequenceNumberHandler=null}addPendingMutation(e){}updateMutationState(e,n,r){}addLocalQueryTarget(e,n=!0){return n&&this.so.fs(e),this.oo[e]||"not-current"}updateQueryState(e,n,r){this.oo[e]=n}removeLocalQueryTarget(e){this.so.gs(e)}isLocalQueryTarget(e){return this.so.activeTargetIds.has(e)}clearQueryState(e){delete this.oo[e]}getAllActiveQueryTargets(){return this.so.activeTargetIds}isActiveQueryTarget(e){return this.so.activeTargetIds.has(e)}start(){return this.so=new Zx,Promise.resolve()}handleUserChange(e,n,r){}setOnlineState(e){}shutdown(){}writeSequenceNumber(e){}notifyBundleLoaded(e){}}/** 2839 * @license 2840 * Copyright 2019 Google LLC 2841 * 2842 * Licensed under the Apache License, Version 2.0 (the "License");
2843 * you may not use this file except in compliance with the License. 2844 * You may obtain a copy of the License at 2845 * 2846 * http://www.apache.org/licenses/LICENSE-2.0 2847 * 2848 * Unless required by applicable law or agreed to in writing, software 2849 * distributed under the License is distributed on an "AS IS" BASIS, 2850 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2851 * See the License for the specific language governing permissions and 2852 * limitations under the License. 2853 */class EV{_o(e){}shutdown(){}}/** 2854 * @license 2855 * Copyright 2019 Google LLC 2856 * 2857 * Licensed under the Apache License, Version 2.0 (the "License"); 2858 * you may not use this file except in compliance with the License. 2859 * You may obtain a copy of the License at 2860 * 2861 * http://www.apache.org/licenses/LICENSE-2.0 2862 * 2863 * Unless required by applicable law or agreed to in writing, software 2864 * distributed under the License is distributed on an "AS IS" BASIS, 2865 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2866 * See the License for the specific language governing permissions and 2867 * limitations under the License. 2868 */class Xx{constructor(){this.ao=()=>this.uo(),this.co=()=>this.lo(),this.ho=[],this.Po()}_o(e){this.ho.push(e)}shutdown(){window.removeEventListener("online",this.ao),window.removeEventListener("offline",this.co)}Po(){window.addEventListener("online",this.ao),window.addEventListener("offline",this.co)}uo(){Oe("ConnectivityMonitor","Network connectivity changed: AVAILABLE");for(const e of this.ho)e(0)}lo(){Oe("ConnectivityMonitor","Network connectivity changed: UNAVAILABLE");for(const e of this.ho)e(1)}static D(){return typeof window<"u"&&window.addEventListener!==void 0&&window.removeEventListener!==void 0}}/** 2869 * @license 2870 * Copyright 2023 Google LLC 2871 * 2872 * Licensed under the Apache License, Version 2.0 (the "License"); 2873 * you may not use this file except in compliance with the License. 2874 * You may obtain a copy of the License at 2875 * 2876 * http://www.apache.org/licenses/LICENSE-2.0 2877 * 2878 * Unless required by applicable law or agreed to in writing, software 2879 * distributed under the License is distributed on an "AS IS" BASIS, 2880 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2881 * See the License for the specific language governing permissions and 2882 * limitations under the License. 2883 */let nh=null;function fv(){return nh===null?nh=function(){return 268435456+Math.round(2147483648*Math.random())}():nh++,"0x"+nh.toString(16)}/** 2884 * @license 2885 * Copyright 2020 Google LLC 2886 * 2887 * Licensed under the Apache License, Version 2.0 (the "License"); 2888 * you may not use this file except in compliance with the License. 2889 * You may obtain a copy of the License at 2890 * 2891 * http://www.apache.org/licenses/LICENSE-2.0 2892 * 2893 * Unless required by applicable law or agreed to in writing, software 2894 * distributed under the License is distributed on an "AS IS" BASIS, 2895 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2896 * See the License for the specific language governing permissions and 2897 * limitations under the License. 2898 */const xV={BatchGetDocuments:"batchGet",Commit:"commit",RunQuery:"runQuery",RunAggregationQuery:"runAggregationQuery"};/** 2899 * @license 2900 * Copyright 2017 Google LLC 2901 * 2902 * Licensed under the Apache License, Version 2.0 (the "License"); 2903 * you may not use this file except in compliance with the License. 2904 * You may obtain a copy of the License at 2905 * 2906 * http://www.apache.org/licenses/LICENSE-2.0 2907 * 2908 * Unless required by applicable law or agreed to in writing, software 2909 * distributed under the License is distributed on an "AS IS" BASIS, 2910 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2911 * See the License for the specific language governing permissions and 2912 * limitations under the License. 2913 */class TV{constructor(e){this.Io=e.Io,this.To=e.To}Eo(e){this.Ao=e}Ro(e){this.Vo=e}mo(e){this.fo=e}onMessage(e){this.po=e}close(){this.To()}send(e){this.Io(e)}yo(){this.Ao()}wo(){this.Vo()}So(e){this.fo(e)}bo(e){this.po(e)}}/** 2914 * @license 2915 * Copyright 2017 Google LLC 2916 * 2917 * Licensed under the Apache License, Version 2.0 (the "License");
2918 * you may not use this file except in compliance with the License. 2919 * You may obtain a copy of the License at 2920 * 2921 * http://www.apache.org/licenses/LICENSE-2.0 2922 * 2923 * Unless required by applicable law or agreed to in writing, software 2924 * distributed under the License is distributed on an "AS IS" BASIS, 2925 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2926 * See the License for the specific language governing permissions and 2927 * limitations under the License. 2928 */const Cn="WebChannelConnection";class SV extends class{constructor(n){this.databaseInfo=n,this.databaseId=n.databaseId;const r=n.ssl?"https":"http",i=encodeURIComponent(this.databaseId.projectId),s=encodeURIComponent(this.databaseId.database);this.Do=r+"://"+n.host,this.vo=`projects/${i}/databases/${s}`,this.Co=this.databaseId.database==="(default)"?`project_id=${i}`:`project_id=${i}&database_id=${s}`}get Fo(){return!1}Mo(n,r,i,s,o){const a=fv(),l=this.xo(n,r.toUriEncodedString());Oe("RestConnection",`Sending RPC '${n}' ${a}:`,l,i);const u={"google-cloud-resource-prefix":this.vo,"x-goog-request-params":this.Co};return this.Oo(u,s,o),this.No(n,l,u,i).then(c=>(Oe("RestConnection",`Received RPC '${n}' ${a}: `,c),c),c=>{throw bu("RestConnection",`RPC '${n}' ${a} failed with error: `,c,"url: ",l,"request:",i),c})}Lo(n,r,i,s,o,a){return this.Mo(n,r,i,s,o)}Oo(n,r,i){n["X-Goog-Api-Client"]=function(){return"gl-js/ fire/"+Lu}(),n["Content-Type"]="text/plain",this.databaseInfo.appId&&(n["X-Firebase-GMPID"]=this.databaseInfo.appId),r&&r.headers.forEach((s,o)=>n[o]=s),i&&i.headers.forEach((s,o)=>n[o]=s)}xo(n,r){const i=xV[n];return`${this.Do}/v1/${r}:${i}`}terminate(){}}{constructor(e){super(e),this.forceLongPolling=e.forceLongPolling,this.autoDetectLongPolling=e.autoDetectLongPolling,this.useFetchStreams=e.useFetchStreams,this.longPollingOptions=e.longPollingOptions}No(e,n,r,i){const s=fv();return new Promise((o,a)=>{const l=new iO;l.setWithCredentials(!0),l.listenOnce(sO.COMPLETE,()=>{try{switch(l.getLastErrorCode()){case Rh.NO_ERROR:const c=l.getResponseJson();Oe(Cn,`XHR for RPC '${e}' ${s} received:`,JSON.stringify(c)),o(c);break;case Rh.TIMEOUT:Oe(Cn,`RPC '${e}' ${s} timed out`),a(new ke(le.DEADLINE_EXCEEDED,"Request time out"));break;case Rh.HTTP_ERROR:const d=l.getStatus();if(Oe(Cn,`RPC '${e}' ${s} failed with status:`,d,"response text:",l.getResponseText()),d>0){let f=l.getResponseJson();Array.isArray(f)&&(f=f[0]);const p=f==null?void 0:f.error;if(p&&p.status&&p.message){const _=function(w){const g=w.toLowerCase().replace(/_/g,"-");return Object.values(le).indexOf(g)>=0?g:le.UNKNOWN}(p.status);a(new ke(_,p.message))}else a(new ke(le.UNKNOWN,"Server responded with status "+l.getStatus()))}else a(new ke(le.UNAVAILABLE,"Connection failed."));break;default:ze()}}finally{Oe(Cn,`RPC '${e}' ${s} completed.`)}});const u=JSON.stringify(i);Oe(Cn,`RPC '${e}' ${s} sending request:`,i),l.send(n,"POST",u,r,15)})}Bo(e,n,r){const i=fv(),s=[this.Do,"/","google.firestore.v1.Firestore","/",e,"/channel"],o=lO(),a=aO(),l={httpSessionIdParam:"gsessionid",initMessageHeaders:{},messageUrlParams:{database:`projects/${this.databaseId.projectId}/databases/${this.databaseId.database}`},sendRawJson:!0,supportsCrossDomainXhr:!0,internalChannelParams:{forwardChannelRequestTimeoutMs:6e5},forceLongPolling:this.forceLongPolling,detectBufferingProxy:this.autoDetectLongPolling},u=this.longPollingOptions.timeoutSeconds;u!==void 0&&(l.longPollingTimeout=Math.round(1e3*u)),this.useFetchStreams&&(l.useFetchStreams=!0),this.Oo(l.initMessageHeaders,n,r),l.encodeInitMessageHeaders=!0;const c=s.join("");Oe(Cn,`Creating RPC '${e}' stream ${i}: ${c}`,l);const d=o.createWebChannel(c,l);let f=!1,p=!1;const _=new TV({Io:w=>{p?Oe(Cn,`Not sending because RPC '${e}' stream ${i} is closed:`,w):(f||(Oe(Cn,`Opening RPC '${e}' stream ${i} transport.`),d.open(),f=!0),Oe(Cn,`RPC '${e}' stream ${i} sending:`,w),d.send(w))},To:()=>d.close()}),y=(w,g,m)=>{w.listen(g,b=>{try{m(b)}catch(v){setTimeout(()=>{throw v},0)}})};return y(d,Pc.EventType.OPEN,()=>{p||(Oe(Cn,`RPC '${e}' stream ${i} transport opened.`),_.yo())}),y(d,Pc.EventType.CLOSE,()=>{p||(p=!0,Oe(Cn,`RPC '${e}' stream ${i} transport closed`),_.So())}
2928),y(d,Pc.EventType.ERROR,w=>{p||(p=!0,bu(Cn,`RPC '${e}' stream ${i} transport errored:`,w),_.So(new ke(le.UNAVAILABLE,"The operation could not be completed")))}),y(d,Pc.EventType.MESSAGE,w=>{var g;if(!p){const m=w.data[0];bt(!!m);const b=m,v=b.error||((g=b[0])===null||g===void 0?void 0:g.error);if(v){Oe(Cn,`RPC '${e}' stream ${i} received error:`,v);const A=v.status;let N=function(T){const S=sn[T];if(S!==void 0)return DO(S)}(A),x=v.message;N===void 0&&(N=le.INTERNAL,x="Unknown error status: "+A+" with message "+v.message),p=!0,_.So(new ke(N,x)),d.close()}else Oe(Cn,`RPC '${e}' stream ${i} received:`,m),_.bo(m)}}),y(a,oO.STAT_EVENT,w=>{w.stat===Dy.PROXY?Oe(Cn,`RPC '${e}' stream ${i} detected buffering proxy`):w.stat===Dy.NOPROXY&&Oe(Cn,`RPC '${e}' stream ${i} detected no buffering proxy`)}),setTimeout(()=>{_.wo()},0),_}}function dv(){return typeof document<"u"?document:null}/** 2929 * @license 2930 * Copyright 2020 Google LLC 2931 * 2932 * Licensed under the Apache License, Version 2.0 (the "License"); 2933 * you may not use this file except in compliance with the License. 2934 * You may obtain a copy of the License at 2935 * 2936 * http://www.apache.org/licenses/LICENSE-2.0 2937 * 2938 * Unless required by applicable law or agreed to in writing, software 2939 * distributed under the License is distributed on an "AS IS" BASIS, 2940 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2941 * See the License for the specific language governing permissions and 2942 * limitations under the License. 2943 */function Fm(t){return new M9(t,!0)}/** 2944 * @license 2945 * Copyright 2017 Google LLC 2946 * 2947 * Licensed under the Apache License, Version 2.0 (the "License"); 2948 * you may not use this file except in compliance with the License. 2949 * You may obtain a copy of the License at 2950 * 2951 * http://www.apache.org/licenses/LICENSE-2.0 2952 * 2953 * Unless required by applicable law or agreed to in writing, software 2954 * distributed under the License is distributed on an "AS IS" BASIS, 2955 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2956 * See the License for the specific language governing permissions and 2957 * limitations under the License. 2958 */class WO{constructor(e,n,r=1e3,i=1.5,s=6e4){this.ui=e,this.timerId=n,this.ko=r,this.qo=i,this.Qo=s,this.Ko=0,this.$o=null,this.Uo=Date.now(),this.reset()}reset(){this.Ko=0}Wo(){this.Ko=this.Qo}Go(e){this.cancel();const n=Math.floor(this.Ko+this.zo()),r=Math.max(0,Date.now()-this.Uo),i=Math.max(0,n-r);i>0&&Oe("ExponentialBackoff",`Backing off for ${i} ms (base delay: ${this.Ko} ms, delay with jitter: ${n} ms, last attempt: ${r} ms ago)`),this.$o=this.ui.enqueueAfterDelay(this.timerId,i,()=>(this.Uo=Date.now(),e())),this.Ko*=this.qo,this.Ko<this.ko&&(this.Ko=this.ko),this.Ko>this.Qo&&(this.Ko=this.Qo)}jo(){this.$o!==null&&(this.$o.skipDelay(),this.$o=null)}cancel(){this.$o!==null&&(this.$o.cancel(),this.$o=null)}zo(){return(Math.random()-.5)*this.Ko}}/** 2959 * @license 2960 * Copyright 2017 Google LLC 2961 * 2962 * Licensed under the Apache License, Version 2.0 (the "License"); 2963 * you may not use this file except in compliance with the License. 2964 * You may obtain a copy of the License at 2965 * 2966 * http://www.apache.org/licenses/LICENSE-2.0 2967 * 2968 * Unless required by applicable law or agreed to in writing, software 2969 * distributed under the License is distributed on an "AS IS" BASIS, 2970 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2971 * See the License for the specific language governing permissions and 2972 * limitations under the License. 2973 */class GO{constructor(e,n,r,i,s,o,a,l){this.ui=e,this.Ho=r,this.Jo=i,this.connection=s,this.authCredentialsProvider=o,this.appCheckCredentialsProvider=a,this.listener=l,this.state=0,this.Yo=0,this.Zo=null,this.Xo=null,this.stream=null,this.e_=0,this.t_=new WO(e,n)}n_(){return this.state===1||this.state===5||this.r_()}r_(){return this.state===2||this.state===3}start(){this.e_=0,this.state!==4?this.auth():this.i_()}async stop(){this.n_()&&await this.close(0)}s_(){this.state=0,this.t_.reset()}o_(){this.r_()&&this.Zo===null&&(this.Zo=this.ui.enqueueAfterDelay(this.Ho,6e4,()=>this.__()))}a_(e){this.u_(),this.stream.send(e)}async __(){if(this.r_())return this.close(0)}u_(){this.Zo&&(this.Zo.cancel(),this.Zo=null)}
2973c_(){this.Xo&&(this.Xo.cancel(),this.Xo=null)}async close(e,n){this.u_(),this.c_(),this.t_.cancel(),this.Yo++,e!==4?this.t_.reset():n&&n.code===le.RESOURCE_EXHAUSTED?(Ns(n.toString()),Ns("Using maximum backoff delay to prevent overloading the backend."),this.t_.Wo()):n&&n.code===le.UNAUTHENTICATED&&this.state!==3&&(this.authCredentialsProvider.invalidateToken(),this.appCheckCredentialsProvider.invalidateToken()),this.stream!==null&&(this.l_(),this.stream.close(),this.stream=null),this.state=e,await this.listener.mo(n)}l_(){}auth(){this.state=1;const e=this.h_(this.Yo),n=this.Yo;Promise.all([this.authCredentialsProvider.getToken(),this.appCheckCredentialsProvider.getToken()]).then(([r,i])=>{this.Yo===n&&this.P_(r,i)},r=>{e(()=>{const i=new ke(le.UNKNOWN,"Fetching auth token failed: "+r.message);return this.I_(i)})})}P_(e,n){const r=this.h_(this.Yo);this.stream=this.T_(e,n),this.stream.Eo(()=>{r(()=>this.listener.Eo())}),this.stream.Ro(()=>{r(()=>(this.state=2,this.Xo=this.ui.enqueueAfterDelay(this.Jo,1e4,()=>(this.r_()&&(this.state=3),Promise.resolve())),this.listener.Ro()))}),this.stream.mo(i=>{r(()=>this.I_(i))}),this.stream.onMessage(i=>{r(()=>++this.e_==1?this.E_(i):this.onNext(i))})}i_(){this.state=5,this.t_.Go(async()=>{this.state=0,this.start()})}I_(e){return Oe("PersistentStream",`close with error: ${e}`),this.stream=null,this.close(4,e)}h_(e){return n=>{this.ui.enqueueAndForget(()=>this.Yo===e?n():(Oe("PersistentStream","stream callback skipped by getCloseGuardedDispatcher."),Promise.resolve()))}}}class kV extends GO{constructor(e,n,r,i,s,o){super(e,"listen_stream_connection_backoff","listen_stream_idle","health_check_timeout",n,r,i,o),this.serializer=s}T_(e,n){return this.connection.Bo("Listen",e,n)}E_(e){return this.onNext(e)}onNext(e){this.t_.reset();const n=F9(this.serializer,e),r=function(s){if(!("targetChange"in s))return He.min();const o=s.targetChange;return o.targetIds&&o.targetIds.length?He.min():o.readTime?ji(o.readTime):He.min()}(e);return this.listener.d_(n,r)}A_(e){const n={};n.database=qy(this.serializer),n.addTarget=function(s,o){let a;const l=o.target;if(a=Fy(l)?{documents:$9(s,l)}:{query:B9(s,l)._t},a.targetId=o.targetId,o.resumeToken.approximateByteSize()>0){a.resumeToken=jO(s,o.resumeToken);const u=$y(s,o.expectedCount);u!==null&&(a.expectedCount=u)}else if(o.snapshotVersion.compareTo(He.min())>0){a.readTime=Cp(s,o.snapshotVersion.toTimestamp());const u=$y(s,o.expectedCount);u!==null&&(a.expectedCount=u)}return a}(this.serializer,e);const r=q9(this.serializer,e);r&&(n.labels=r),this.a_(n)}R_(e){const n={};n.database=qy(this.serializer),n.removeTarget=e,this.a_(n)}}class AV extends GO{constructor(e,n,r,i,s,o){super(e,"write_stream_connection_backoff","write_stream_idle","health_check_timeout",n,r,i,o),this.serializer=s}get V_(){return this.e_>0}start(){this.lastStreamToken=void 0,super.start()}l_(){this.V_&&this.m_([])}T_(e,n){return this.connection.Bo("Write",e,n)}E_(e){return bt(!!e.streamToken),this.lastStreamToken=e.streamToken,bt(!e.writeResults||e.writeResults.length===0),this.listener.f_()}onNext(e){bt(!!e.streamToken),this.lastStreamToken=e.streamToken,this.t_.reset();const n=U9(e.writeResults,e.commitTime),r=ji(e.commitTime);return this.listener.g_(r,n)}p_(){const e={};e.database=qy(this.serializer),this.a_(e)}m_(e){const n={streamToken:this.lastStreamToken,writes:e.map(r=>V9(this.serializer,r))};this.a_(n)}}/** 2974 * @license 2975 * Copyright 2017 Google LLC 2976 * 2977 * Licensed under the Apache License, Version 2.0 (the "License"); 2978 * you may not use this file except in compliance with the License. 2979 * You may obtain a copy of the License at 2980 * 2981 * http://www.apache.org/licenses/LICENSE-2.0 2982 * 2983 * Unless required by applicable law or agreed to in writing, software 2984 * distributed under the License is distributed on an "AS IS" BASIS, 2985 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 2986 * See the License for the specific language governing permissions and 2987 * limitations under the License. 2988 */class IV extends class{}{constructor(e,n,r,i){super(),this.authCredentials=e,this.appCheckCredentials=n,this.connection=r,this.serializer
2988=i,this.y_=!1}w_(){if(this.y_)throw new ke(le.FAILED_PRECONDITION,"The client has already been terminated.")}Mo(e,n,r,i){return this.w_(),Promise.all([this.authCredentials.getToken(),this.appCheckCredentials.getToken()]).then(([s,o])=>this.connection.Mo(e,By(n,r),i,s,o)).catch(s=>{throw s.name==="FirebaseError"?(s.code===le.UNAUTHENTICATED&&(this.authCredentials.invalidateToken(),this.appCheckCredentials.invalidateToken()),s):new ke(le.UNKNOWN,s.toString())})}Lo(e,n,r,i,s){return this.w_(),Promise.all([this.authCredentials.getToken(),this.appCheckCredentials.getToken()]).then(([o,a])=>this.connection.Lo(e,By(n,r),i,o,a,s)).catch(o=>{throw o.name==="FirebaseError"?(o.code===le.UNAUTHENTICATED&&(this.authCredentials.invalidateToken(),this.appCheckCredentials.invalidateToken()),o):new ke(le.UNKNOWN,o.toString())})}terminate(){this.y_=!0,this.connection.terminate()}}class OV{constructor(e,n){this.asyncQueue=e,this.onlineStateHandler=n,this.state="Unknown",this.S_=0,this.b_=null,this.D_=!0}v_(){this.S_===0&&(this.C_("Unknown"),this.b_=this.asyncQueue.enqueueAfterDelay("online_state_timeout",1e4,()=>(this.b_=null,this.F_("Backend didn't respond within 10 seconds."),this.C_("Offline"),Promise.resolve())))}M_(e){this.state==="Online"?this.C_("Unknown"):(this.S_++,this.S_>=1&&(this.x_(),this.F_(`Connection failed 1 times. Most recent error: ${e.toString()}`),this.C_("Offline")))}set(e){this.x_(),this.S_=0,e==="Online"&&(this.D_=!1),this.C_(e)}C_(e){e!==this.state&&(this.state=e,this.onlineStateHandler(e))}F_(e){const n=`Could not reach Cloud Firestore backend. ${e} 2989This typically indicates that your device does not have a healthy Internet connection at the moment. The client will operate in offline mode until it is able to successfully connect to the backend.`;this.D_?(Ns(n),this.D_=!1):Oe("OnlineStateTracker",n)}x_(){this.b_!==null&&(this.b_.cancel(),this.b_=null)}}/** 2990 * @license 2991 * Copyright 2017 Google LLC 2992 * 2993 * Licensed under the Apache License, Version 2.0 (the "License"); 2994 * you may not use this file except in compliance with the License. 2995 * You may obtain a copy of the License at 2996 * 2997 * http://www.apache.org/licenses/LICENSE-2.0 2998 * 2999 * Unless required by applicable law or agreed to in writing, software 3000 * distributed under the License is distributed on an "AS IS" BASIS, 3001 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3002 * See the License for the specific language governing permissions and 3003 * limitations under the License. 3004 */class PV{constructor(e,n,r,i,s){this.localStore=e,this.datastore=n,this.asyncQueue=r,this.remoteSyncer={},this.O_=[],this.N_=new Map,this.L_=new Set,this.B_=[],this.k_=s,this.k_._o(o=>{r.enqueueAndForget(async()=>{cl(this)&&(Oe("RemoteStore","Restarting streams for network reachability change."),await async function(l){const u=We(l);u.L_.add(4),await ud(u),u.q_.set("Unknown"),u.L_.delete(4),await Vm(u)}(this))})}),this.q_=new OV(r,i)}}async function Vm(t){if(cl(t))for(const e of t.B_)await e(!0)}async function ud(t){for(const e of t.B_)await e(!1)}function KO(t,e){const n=We(t);n.N_.has(e.targetId)||(n.N_.set(e.targetId,e),T1(n)?x1(n):Fu(n).r_()&&E1(n,e))}function b1(t,e){const n=We(t),r=Fu(n);n.N_.delete(e),r.r_()&&YO(n,e),n.N_.size===0&&(r.r_()?r.o_():cl(n)&&n.q_.set("Unknown"))}function E1(t,e){if(t.Q_.xe(e.targetId),e.resumeToken.approximateByteSize()>0||e.snapshotVersion.compareTo(He.min())>0){const n=t.remoteSyncer.getRemoteKeysForTarget(e.targetId).size;e=e.withExpectedCount(n)}Fu(t).A_(e)}function YO(t,e){t.Q_.xe(e),Fu(t).R_(e)}function x1(t){t.Q_=new R9({getRemoteKeysForTarget:e=>t.remoteSyncer.getRemoteKeysForTarget(e),ot:e=>t.N_.get(e)||null,tt:()=>t.datastore.serializer.databaseId}),Fu(t).start(),t.q_.v_()}function T1(t){return cl(t)&&!Fu(t).n_()&&t.N_.size>0}function cl(t){return We(t).L_.size===0}function QO(t){t.Q_=void 0}async function RV(t){t.q_.set("Online")}async function CV(t){t.N_.forEach((e,n)=>{E1(t,e)})}async function NV(t,e){QO(t),T1(t)?(t.q_.M_(e),x1(t)):t.q_.set("Unknown")}async function DV(t,e,n){if(t.q_.set("Online"),e instanceof LO&&e.state===2&&e.cause)try{await async function(i,s){const o=s.cause;for(const a of s.targetIds)i.N_.has(a)&&(await i.remoteSyncer.rejectListen(a,o),i.N_.delete(a),i.Q_.removeTarget(a))}(t,e)}catch(r){Oe("RemoteStore","Failed to remove targets %s: %s ",e.targetIds.join(","),r),await Np(t,r)}else if(e instanceof Dh?t.Q_.Ke(e):e instanceof MO?t.Q_.He(e):t.Q_.We(e),!n.isEqual(He.min()))try{const r=await HO(t.localStore);n.compareTo(r)>=0&&await function(s,o){const a=s.Q_.rt(o);
3004return a.targetChanges.forEach((l,u)=>{if(l.resumeToken.approximateByteSize()>0){const c=s.N_.get(u);c&&s.N_.set(u,c.withResumeToken(l.resumeToken,o))}}),a.targetMismatches.forEach((l,u)=>{const c=s.N_.get(l);if(!c)return;s.N_.set(l,c.withResumeToken(An.EMPTY_BYTE_STRING,c.snapshotVersion)),YO(s,l);const d=new xo(c.target,l,u,c.sequenceNumber);E1(s,d)}),s.remoteSyncer.applyRemoteEvent(a)}(t,n)}catch(r){Oe("RemoteStore","Failed to raise snapshot:",r),await Np(t,r)}}async function Np(t,e,n){if(!sd(e))throw e;t.L_.add(1),await ud(t),t.q_.set("Offline"),n||(n=()=>HO(t.localStore)),t.asyncQueue.enqueueRetryable(async()=>{Oe("RemoteStore","Retrying IndexedDB access"),await n(),t.L_.delete(1),await Vm(t)})}function ZO(t,e){return e().catch(n=>Np(t,n,e))}async function Um(t){const e=We(t),n=qo(e);let r=e.O_.length>0?e.O_[e.O_.length-1].batchId:-1;for(;MV(e);)try{const i=await yV(e.localStore,r);if(i===null){e.O_.length===0&&n.o_();break}r=i.batchId,LV(e,i)}catch(i){await Np(e,i)}XO(e)&&JO(e)}function MV(t){return cl(t)&&t.O_.length<10}function LV(t,e){t.O_.push(e);const n=qo(t);n.r_()&&n.V_&&n.m_(e.mutations)}function XO(t){return cl(t)&&!qo(t).n_()&&t.O_.length>0}function JO(t){qo(t).start()}async function jV(t){qo(t).p_()}async function FV(t){const e=qo(t);for(const n of t.O_)e.m_(n.mutations)}async function VV(t,e,n){const r=t.O_.shift(),i=m1.from(r,e,n);await ZO(t,()=>t.remoteSyncer.applySuccessfulWrite(i)),await Um(t)}async function UV(t,e){e&&qo(t).V_&&await async function(r,i){if(function(o){return I9(o)&&o!==le.ABORTED}(i.code)){const s=r.O_.shift();qo(r).s_(),await ZO(r,()=>r.remoteSyncer.rejectFailedWrite(s.batchId,i)),await Um(r)}}(t,e),XO(t)&&JO(t)}async function Jx(t,e){const n=We(t);n.asyncQueue.verifyOperationInProgress(),Oe("RemoteStore","RemoteStore received new credentials");const r=cl(n);n.L_.add(3),await ud(n),r&&n.q_.set("Unknown"),await n.remoteSyncer.handleCredentialChange(e),n.L_.delete(3),await Vm(n)}async function $V(t,e){const n=We(t);e?(n.L_.delete(2),await Vm(n)):e||(n.L_.add(2),await ud(n),n.q_.set("Unknown"))}function Fu(t){return t.K_||(t.K_=function(n,r,i){const s=We(n);return s.w_(),new kV(r,s.connection,s.authCredentials,s.appCheckCredentials,s.serializer,i)}(t.datastore,t.asyncQueue,{Eo:RV.bind(null,t),Ro:CV.bind(null,t),mo:NV.bind(null,t),d_:DV.bind(null,t)}),t.B_.push(async e=>{e?(t.K_.s_(),T1(t)?x1(t):t.q_.set("Unknown")):(await t.K_.stop(),QO(t))})),t.K_}function qo(t){return t.U_||(t.U_=function(n,r,i){const s=We(n);return s.w_(),new AV(r,s.connection,s.authCredentials,s.appCheckCredentials,s.serializer,i)}(t.datastore,t.asyncQueue,{Eo:()=>Promise.resolve(),Ro:jV.bind(null,t),mo:UV.bind(null,t),f_:FV.bind(null,t),g_:VV.bind(null,t)}),t.B_.push(async e=>{e?(t.U_.s_(),await Um(t)):(await t.U_.stop(),t.O_.length>0&&(Oe("RemoteStore",`Stopping write stream with ${t.O_.length} pending writes`),t.O_=[]))})),t.U_}/** 3005 * @license 3006 * Copyright 2017 Google LLC 3007 * 3008 * Licensed under the Apache License, Version 2.0 (the "License"); 3009 * you may not use this file except in compliance with the License. 3010 * You may obtain a copy of the License at 3011 * 3012 * http://www.apache.org/licenses/LICENSE-2.0 3013 * 3014 * Unless required by applicable law or agreed to in writing, software 3015 * distributed under the License is distributed on an "AS IS" BASIS, 3016 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3017 * See the License for the specific language governing permissions and 3018 * limitations under the License. 3019 */class S1{constructor(e,n,r,i,s){this.asyncQueue=e,this.timerId=n,this.targetTimeMs=r,this.op=i,this.removalCallback=s,this.deferred=new bs,this.then=this.deferred.promise.then.bind(this.deferred.promise),this.deferred.promise.catch(o=>{})}get promise(){return this.deferred.promise}static createAndSchedule(e,n,r,i,s){const o=Date.now()+r,a=new S1(e,n,o,i,s);return a.start(r),a}start(e){this.timerHandle=setTimeout(()=>this.handleDelayElapsed(),e)}skipDelay(){return this.handleDelayElapsed()}cancel(e){this.timerHandle!==null&&(this.clearTimeout(),this.deferred.reject(new ke(le.CANCELLED,"Operation cancelled"+(e?": "+e:""))))}handleDelayElapsed(){this.asyncQueue.enqueueAndForget(()=>this.timerHandle!==null?(this.clearTimeout(),this.op().then(e=>this.deferred.resolve(e))):Promise.resolve())}clearTimeout(){this.timerHandle!==null&&(this.removalCallback(this),clearTimeout(this.timerHandle),this.timerHandle=null)}}function k1(t,e){if(Ns("AsyncQueue",`${e}: ${t}`),sd(t))return new ke(le.UNAVAILABLE,`${e}: ${t}`);throw t}/** 3020 * @license 3021 * Copyright 2017 Google LLC 3022 * 3023 * Licensed under the Apache License, Version 2.0 (the "License");
3024 * you may not use this file except in compliance with the License. 3025 * You may obtain a copy of the License at 3026 * 3027 * http://www.apache.org/licenses/LICENSE-2.0 3028 * 3029 * Unless required by applicable law or agreed to in writing, software 3030 * distributed under the License is distributed on an "AS IS" BASIS, 3031 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3032 * See the License for the specific language governing permissions and 3033 * limitations under the License. 3034 */class Yl{constructor(e){this.comparator=e?(n,r)=>e(n,r)||Le.comparator(n.key,r.key):(n,r)=>Le.comparator(n.key,r.key),this.keyedMap=Rc(),this.sortedSet=new Kt(this.comparator)}static emptySet(e){return new Yl(e.comparator)}has(e){return this.keyedMap.get(e)!=null}get(e){return this.keyedMap.get(e)}first(){return this.sortedSet.minKey()}last(){return this.sortedSet.maxKey()}isEmpty(){return this.sortedSet.isEmpty()}indexOf(e){const n=this.keyedMap.get(e);return n?this.sortedSet.indexOf(n):-1}get size(){return this.sortedSet.size}forEach(e){this.sortedSet.inorderTraversal((n,r)=>(e(n),!1))}add(e){const n=this.delete(e.key);return n.copy(n.keyedMap.insert(e.key,e),n.sortedSet.insert(e,null))}delete(e){const n=this.get(e);return n?this.copy(this.keyedMap.remove(e),this.sortedSet.remove(n)):this}isEqual(e){if(!(e instanceof Yl)||this.size!==e.size)return!1;const n=this.sortedSet.getIterator(),r=e.sortedSet.getIterator();for(;n.hasNext();){const i=n.getNext().key,s=r.getNext().key;if(!i.isEqual(s))return!1}return!0}toString(){const e=[];return this.forEach(n=>{e.push(n.toString())}),e.length===0?"DocumentSet ()":`DocumentSet ( 3035 `+e.join(` 3036`)+` 3037)`}copy(e,n){const r=new Yl;return r.comparator=this.comparator,r.keyedMap=e,r.sortedSet=n,r}}/** 3038 * @license 3039 * Copyright 2017 Google LLC 3040 * 3041 * Licensed under the Apache License, Version 2.0 (the "License"); 3042 * you may not use this file except in compliance with the License. 3043 * You may obtain a copy of the License at 3044 * 3045 * http://www.apache.org/licenses/LICENSE-2.0 3046 * 3047 * Unless required by applicable law or agreed to in writing, software 3048 * distributed under the License is distributed on an "AS IS" BASIS, 3049 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3050 * See the License for the specific language governing permissions and 3051 * limitations under the License. 3052 */class eT{constructor(){this.W_=new Kt(Le.comparator)}track(e){const n=e.doc.key,r=this.W_.get(n);r?e.type!==0&&r.type===3?this.W_=this.W_.insert(n,e):e.type===3&&r.type!==1?this.W_=this.W_.insert(n,{type:r.type,doc:e.doc}):e.type===2&&r.type===2?this.W_=this.W_.insert(n,{type:2,doc:e.doc}):e.type===2&&r.type===0?this.W_=this.W_.insert(n,{type:0,doc:e.doc}):e.type===1&&r.type===0?this.W_=this.W_.remove(n):e.type===1&&r.type===2?this.W_=this.W_.insert(n,{type:1,doc:r.doc}):e.type===0&&r.type===1?this.W_=this.W_.insert(n,{type:2,doc:e.doc}):ze():this.W_=this.W_.insert(n,e)}G_(){const e=[];return this.W_.inorderTraversal((n,r)=>{e.push(r)}),e}}class ku{constructor(e,n,r,i,s,o,a,l,u){this.query=e,this.docs=n,this.oldDocs=r,this.docChanges=i,this.mutatedKeys=s,this.fromCache=o,this.syncStateChanged=a,this.excludesMetadataChanges=l,this.hasCachedResults=u}static fromInitialDocuments(e,n,r,i,s){const o=[];return n.forEach(a=>{o.push({type:0,doc:a})}),new ku(e,n,Yl.emptySet(n),o,r,i,!0,!1,s)}get hasPendingWrites(){return!this.mutatedKeys.isEmpty()}isEqual(e){if(!(this.fromCache===e.fromCache&&this.hasCachedResults===e.hasCachedResults&&this.syncStateChanged===e.syncStateChanged&&this.mutatedKeys.isEqual(e.mutatedKeys)&&Nm(this.query,e.query)&&this.docs.isEqual(e.docs)&&this.oldDocs.isEqual(e.oldDocs)))return!1;const n=this.docChanges,r=e.docChanges;if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++)if(n[i].type!==r[i].type||!n[i].doc.isEqual(r[i].doc))return!1;return!0}}/** 3053 * @license 3054 * Copyright 2017 Google LLC 3055 * 3056 * Licensed under the Apache License, Version 2.0 (the "License"); 3057 * you may not use this file except in compliance with the License. 3058 * You may obtain a copy of the License at 3059 * 3060 * http://www.apache.org/licenses/LICENSE-2.0 3061 * 3062 * Unless required by applicable law or agreed to in writing, softw
3062are 3063 * distributed under the License is distributed on an "AS IS" BASIS, 3064 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3065 * See the License for the specific language governing permissions and 3066 * limitations under the License. 3067 */class BV{constructor(){this.z_=void 0,this.j_=[]}H_(){return this.j_.some(e=>e.J_())}}class zV{constructor(){this.queries=tT(),this.onlineState="Unknown",this.Y_=new Set}terminate(){(function(n,r){const i=We(n),s=i.queries;i.queries=tT(),s.forEach((o,a)=>{for(const l of a.j_)l.onError(r)})})(this,new ke(le.ABORTED,"Firestore shutting down"))}}function tT(){return new ju(t=>bO(t),Nm)}async function eP(t,e){const n=We(t);let r=3;const i=e.query;let s=n.queries.get(i);s?!s.H_()&&e.J_()&&(r=2):(s=new BV,r=e.J_()?0:1);try{switch(r){case 0:s.z_=await n.onListen(i,!0);break;case 1:s.z_=await n.onListen(i,!1);break;case 2:await n.onFirstRemoteStoreListen(i)}}catch(o){const a=k1(o,`Initialization of query '${bl(e.query)}' failed`);return void e.onError(a)}n.queries.set(i,s),s.j_.push(e),e.Z_(n.onlineState),s.z_&&e.X_(s.z_)&&A1(n)}async function tP(t,e){const n=We(t),r=e.query;let i=3;const s=n.queries.get(r);if(s){const o=s.j_.indexOf(e);o>=0&&(s.j_.splice(o,1),s.j_.length===0?i=e.J_()?0:1:!s.H_()&&e.J_()&&(i=2))}switch(i){case 0:return n.queries.delete(r),n.onUnlisten(r,!0);case 1:return n.queries.delete(r),n.onUnlisten(r,!1);case 2:return n.onLastRemoteStoreUnlisten(r);default:return}}function qV(t,e){const n=We(t);let r=!1;for(const i of e){const s=i.query,o=n.queries.get(s);if(o){for(const a of o.j_)a.X_(i)&&(r=!0);o.z_=i}}r&&A1(n)}function HV(t,e,n){const r=We(t),i=r.queries.get(e);if(i)for(const s of i.j_)s.onError(n);r.queries.delete(e)}function A1(t){t.Y_.forEach(e=>{e.next()})}var Wy,nT;(nT=Wy||(Wy={})).ea="default",nT.Cache="cache";class nP{constructor(e,n,r){this.query=e,this.ta=n,this.na=!1,this.ra=null,this.onlineState="Unknown",this.options=r||{}}X_(e){if(!this.options.includeMetadataChanges){const r=[];for(const i of e.docChanges)i.type!==3&&r.push(i);e=new ku(e.query,e.docs,e.oldDocs,r,e.mutatedKeys,e.fromCache,e.syncStateChanged,!0,e.hasCachedResults)}let n=!1;return this.na?this.ia(e)&&(this.ta.next(e),n=!0):this.sa(e,this.onlineState)&&(this.oa(e),n=!0),this.ra=e,n}onError(e){this.ta.error(e)}Z_(e){this.onlineState=e;let n=!1;return this.ra&&!this.na&&this.sa(this.ra,e)&&(this.oa(this.ra),n=!0),n}sa(e,n){if(!e.fromCache||!this.J_())return!0;const r=n!=="Offline";return(!this.options._a||!r)&&(!e.docs.isEmpty()||e.hasCachedResults||n==="Offline")}ia(e){if(e.docChanges.length>0)return!0;const n=this.ra&&this.ra.hasPendingWrites!==e.hasPendingWrites;return!(!e.syncStateChanged&&!n)&&this.options.includeMetadataChanges===!0}oa(e){e=ku.fromInitialDocuments(e.query,e.docs,e.mutatedKeys,e.fromCache,e.hasCachedResults),this.na=!0,this.ta.next(e)}J_(){return this.options.source!==Wy.Cache}}/** 3068 * @license 3069 * Copyright 2017 Google LLC 3070 * 3071 * Licensed under the Apache License, Version 2.0 (the "License"); 3072 * you may not use this file except in compliance with the License. 3073 * You may obtain a copy of the License at 3074 * 3075 * http://www.apache.org/licenses/LICENSE-2.0 3076 * 3077 * Unless required by applicable law or agreed to in writing, software 3078 * distributed under the License is distributed on an "AS IS" BASIS, 3079 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3080 * See the License for the specific language governing permissions and 3081 * limitations under the License. 3082 */class rP{constructor(e){this.key=e}}class iP{constructor(e){this.key=e}}class WV{constructor(e,n){this.query=e,this.Ta=n,this.Ea=null,this.hasCachedResults=!1,this.current=!1,this.da=rt(),this.mutatedKeys=rt(),this.Aa=EO(e),this.Ra=new Yl(this.Aa)}get Va(){return this.Ta}ma(e,n){const r=n?n.fa:new eT,i=n?n.Ra:this.Ra;let s=n?n.mutatedKeys:this.mutatedKeys,o=i,a=!1;const l=this.query.limitType==="F"&&i.size===this.query.limit?i.last():null,u=this.query.limitType==="L"&&i.size===this.query.limit?i.first():null;if(e.inorderTraversal((c,d)=>{const f=i.get(c),p=Dm(this.query,d)?d:null,_=!!f&&this.mutatedKeys.has(f.key),y=!!p&&(p.hasLocalMutations||this.mutatedKeys.has(p.key)&&p.hasCommittedMutations);let w=!1;f&&p?f.data.isEqual(p.data)?_!==y&&(r.track({type:3,doc:p}),w=!0):this.ga(f,p)||(r.track({type:2,doc:p}),w=!0,(l&&this.Aa(p,l)>0||u&&this.Aa(p,u)<0)&&(a=!0)):!f&&p?(r.track({type:0,doc:p}),w=!0):f&&!p&&(r.track({type:1,doc:f}),w=!0,(l||u)&&(a=!0)),w&&(p?(o=o.add(p),s=y?s.add(c):s.delete(c)):(o=o.delete(c),s=s.delete(c)))}),this.query.limit!==null)for(;o.size>this.query.limit;){const c=this.query.limitType==="F"?o.last():o.first();o=o.delete(c.key),s=s.delete(c.key),r.track({type:1,doc:c})}return{Ra:o,fa:r,ns:a,mutatedKeys:s}}ga(e,n){return e.hasLocalMutations&&n.hasCommittedMutations&&!n.hasLocalMutations}
3082applyChanges(e,n,r,i){const s=this.Ra;this.Ra=e.Ra,this.mutatedKeys=e.mutatedKeys;const o=e.fa.G_();o.sort((c,d)=>function(p,_){const y=w=>{switch(w){case 0:return 1;case 2:case 3:return 2;case 1:return 0;default:return ze()}};return y(p)-y(_)}(c.type,d.type)||this.Aa(c.doc,d.doc)),this.pa(r),i=i!=null&&i;const a=n&&!i?this.ya():[],l=this.da.size===0&&this.current&&!i?1:0,u=l!==this.Ea;return this.Ea=l,o.length!==0||u?{snapshot:new ku(this.query,e.Ra,s,o,e.mutatedKeys,l===0,u,!1,!!r&&r.resumeToken.approximateByteSize()>0),wa:a}:{wa:a}}Z_(e){return this.current&&e==="Offline"?(this.current=!1,this.applyChanges({Ra:this.Ra,fa:new eT,mutatedKeys:this.mutatedKeys,ns:!1},!1)):{wa:[]}}Sa(e){return!this.Ta.has(e)&&!!this.Ra.has(e)&&!this.Ra.get(e).hasLocalMutations}pa(e){e&&(e.addedDocuments.forEach(n=>this.Ta=this.Ta.add(n)),e.modifiedDocuments.forEach(n=>{}),e.removedDocuments.forEach(n=>this.Ta=this.Ta.delete(n)),this.current=e.current)}ya(){if(!this.current)return[];const e=this.da;this.da=rt(),this.Ra.forEach(r=>{this.Sa(r.key)&&(this.da=this.da.add(r.key))});const n=[];return e.forEach(r=>{this.da.has(r)||n.push(new iP(r))}),this.da.forEach(r=>{e.has(r)||n.push(new rP(r))}),n}ba(e){this.Ta=e.Ts,this.da=rt();const n=this.ma(e.documents);return this.applyChanges(n,!0)}Da(){return ku.fromInitialDocuments(this.query,this.Ra,this.mutatedKeys,this.Ea===0,this.hasCachedResults)}}class GV{constructor(e,n,r){this.query=e,this.targetId=n,this.view=r}}class KV{constructor(e){this.key=e,this.va=!1}}class YV{constructor(e,n,r,i,s,o){this.localStore=e,this.remoteStore=n,this.eventManager=r,this.sharedClientState=i,this.currentUser=s,this.maxConcurrentLimboResolutions=o,this.Ca={},this.Fa=new ju(a=>bO(a),Nm),this.Ma=new Map,this.xa=new Set,this.Oa=new Kt(Le.comparator),this.Na=new Map,this.La=new y1,this.Ba={},this.ka=new Map,this.qa=Su.kn(),this.onlineState="Unknown",this.Qa=void 0}get isPrimaryClient(){return this.Qa===!0}}async function QV(t,e,n=!0){const r=cP(t);let i;const s=r.Fa.get(e);return s?(r.sharedClientState.addLocalQueryTarget(s.targetId),i=s.view.Da()):i=await sP(r,e,n,!0),i}async function ZV(t,e){const n=cP(t);await sP(n,e,!0,!1)}async function sP(t,e,n,r){const i=await _V(t.localStore,Mi(e)),s=i.targetId,o=t.sharedClientState.addLocalQueryTarget(s,n);let a;return r&&(a=await XV(t,e,s,o==="current",i.resumeToken)),t.isPrimaryClient&&n&&KO(t.remoteStore,i),a}async function XV(t,e,n,r,i){t.Ka=(d,f,p)=>async function(y,w,g,m){let b=w.view.ma(g);b.ns&&(b=await Qx(y.localStore,w.query,!1).then(({documents:x})=>w.view.ma(x,b)));const v=m&&m.targetChanges.get(w.targetId),A=m&&m.targetMismatches.get(w.targetId)!=null,N=w.view.applyChanges(b,y.isPrimaryClient,v,A);return iT(y,w.targetId,N.wa),N.snapshot}(t,d,f,p);const s=await Qx(t.localStore,e,!0),o=new WV(e,s.Ts),a=o.ma(s.documents),l=ld.createSynthesizedTargetChangeForCurrentChange(n,r&&t.onlineState!=="Offline",i),u=o.applyChanges(a,t.isPrimaryClient,l);iT(t,n,u.wa);const c=new GV(e,n,o);return t.Fa.set(e,c),t.Ma.has(n)?t.Ma.get(n).push(e):t.Ma.set(n,[e]),u.snapshot}async function JV(t,e,n){const r=We(t),i=r.Fa.get(e),s=r.Ma.get(i.targetId);if(s.length>1)return r.Ma.set(i.targetId,s.filter(o=>!Nm(o,e))),void r.Fa.delete(e);r.isPrimaryClient?(r.sharedClientState.removeLocalQueryTarget(i.targetId),r.sharedCl
3082ientState.isActiveQueryTarget(i.targetId)||await Hy(r.localStore,i.targetId,!1).then(()=>{r.sharedClientState.clearQueryState(i.targetId),n&&b1(r.remoteStore,i.targetId),Gy(r,i.targetId)}).catch(id)):(Gy(r,i.targetId),await Hy(r.localStore,i.targetId,!0))}async function eU(t,e){const n=We(t),r=n.Fa.get(e),i=n.Ma.get(r.targetId);n.isPrimaryClient&&i.length===1&&(n.sharedClientState.removeLocalQueryTarget(r.targetId),b1(n.remoteStore,r.targetId))}async function tU(t,e,n){const r=lU(t);try{const i=await function(o,a){const l=We(o),u=pn.now(),c=a.reduce((p,_)=>p.add(_.key),rt());let d,f;return l.persistence.runTransaction("Locally write mutations","readwrite",p=>{let _=Ds(),y=rt();return l.cs.getEntries(p,c).next(w=>{_=w,_.forEach((g,m)=>{m.isValidDocument()||(y=y.add(g))})}).next(()=>l.localDocuments.getOverlayedDocuments(p,_)).next(w=>{d=w;const g=[];for(const m of a){const b=x9(m,d.get(m.key).overlayedDocument);b!=null&&g.push(new ea(m.key,b,hO(b.value.mapValue),Li.exists(!0)))}return l.mutationQueue.addMutationBatch(p,u,g,a)}).next(w=>{f=w;const g=w.applyToLocalDocumentSet(d,y);return l.documentOverlayCache.saveOverlays(p,w.batchId,g)})}).then(()=>({batchId:f.batchId,changes:TO(d)}))}(r.localStore,e);r.sharedClientState.addPendingMutation(i.batchId),function(o,a,l){let u=o.Ba[o.currentUser.toKey()];u||(u=new Kt(pt)),u=u.insert(a,l),o.Ba[o.currentUser.toKey()]=u}(r,i.batchId,n),await cd(r,i.changes),await Um(r.remoteStore)}catch(i){const s=k1(i,"Failed to persist write");n.reject(s)}}async function oP(t,e){const n=We(t);try{const r=await gV(n.localStore,e);
3082e.targetChanges.forEach((i,s)=>{const o=n.Na.get(s);o&&(bt(i.addedDocuments.size+i.modifiedDocuments.size+i.removedDocuments.size<=1),i.addedDocuments.size>0?o.va=!0:i.modifiedDocuments.size>0?bt(o.va):i.removedDocuments.size>0&&(bt(o.va),o.va=!1))}),await cd(n,r,e)}catch(r){await id(r)}}function rT(t,e,n){const r=We(t);if(r.isPrimaryClient&&n===0||!r.isPrimaryClient&&n===1){const i=[];r.Fa.forEach((s,o)=>{const a=o.view.Z_(e);a.snapshot&&i.push(a.snapshot)}),function(o,a){const l=We(o);l.onlineState=a;let u=!1;l.queries.forEach((c,d)=>{for(const f of d.j_)f.Z_(a)&&(u=!0)}),u&&A1(l)}(r.eventManager,e),i.length&&r.Ca.d_(i),r.onlineState=e,r.isPrimaryClient&&r.sharedClientState.setOnlineState(e)}}async function nU(t,e,n){const r=We(t);r.sharedClientState.updateQueryState(e,"rejected",n);const i=r.Na.get(e),s=i&&i.key;if(s){let o=new Kt(Le.comparator);o=o.insert(s,Ln.newNoDocument(s,He.min()));const a=rt().add(s),l=new jm(He.min(),new Map,new Kt(pt),o,a);await oP(r,l),r.Oa=r.Oa.remove(s),r.Na.delete(e),I1(r)}else await Hy(r.localStore,e,!1).then(()=>Gy(r,e,n)).catch(id)}async function rU(t,e){const n=We(t),r=e.batch.batchId;try{const i=await mV(n.localStore,e);lP(n,r,null),aP(n,r),n.sharedClientState.updateMutationState(r,"acknowledged"),await cd(n,i)}catch(i){await id(i)}}async function iU(t,e,n){const r=We(t);try{const i=await function(o,a){const l=We(o);return l.persistence.runTransaction("Reject batch","readwrite-primary",u=>{let c;return l.mutationQueue.lookupMutationBatch(u,a).next(d=>(bt(d!==null),c=d.keys(),l.mutationQueue.removeMutationBatch(u,d))).next(()=>l.mutationQueue.performConsistencyCheck(u)).next(()=>l.documentOverlayCache.removeOverlaysForBatchId(u,c,a)).next(()=>l.localDocuments.recalculateAndSaveOverlaysForDocumentKeys(u,c)).next(()=>l.localDocuments.getDocuments(u,c))})}(r.localStore,e);lP(r,e,n),aP(r,e),r.sharedClientState.updateMutationState(e,"rejected",n),await cd(r,i)}catch(i){await id(i)}}function aP(t,e){(t.ka.get(e)||[]).forEach(n=>{n.resolve()}),t.ka.delete(e)}function lP(t,e,n){const r=We(t);let i=r.Ba[r.currentUser.toKey()];if(i){const s=i.get(e);s&&(n?s.reject(n):s.resolve(),i=i.remove(e)),r.Ba[r.currentUser.toKey()]=i}}
3082function Gy(t,e,n=null){t.sharedClientState.removeLocalQueryTarget(e);for(const r of t.Ma.get(e))t.Fa.delete(r),n&&t.Ca.$a(r,n);t.Ma.delete(e),t.isPrimaryClient&&t.La.gr(e).forEach(r=>{t.La.containsKey(r)||uP(t,r)})}function uP(t,e){t.xa.delete(e.path.canonicalString());const n=t.Oa.get(e);n!==null&&(b1(t.remoteStore,n),t.Oa=t.Oa.remove(e),t.Na.delete(n),I1(t))}function iT(t,e,n){for(const r of n)r instanceof rP?(t.La.addReference(r.key,e),sU(t,r)):r instanceof iP?(Oe("SyncEngine","Document no longer in limbo: "+r.key),t.La.removeReference(r.key,e),t.La.containsKey(r.key)||uP(t,r.key)):ze()}function sU(t,e){const n=e.key,r=n.path.canonicalString();t.Oa.get(n)||t.xa.has(r)||(Oe("SyncEngine","New document in limbo: "+n),t.xa.add(r),I1(t))}function I1(t){for(;t.xa.size>0&&t.Oa.size<t.maxConcurrentLimboResolutions;){const e=t.xa.values().next().value;t.xa.delete(e);const n=new Le(Lt.fromString(e)),r=t.qa.next();t.Na.set(r,new KV(n)),t.Oa=t.Oa.insert(n,r),KO(t.remoteStore,new xo(Mi(h1(n.path)),r,"TargetPurposeLimboResolution",a1.oe))}}async function cd(t,e,n){const r=We(t),i=[],s=[],o=[];r.Fa.isEmpty()||(r.Fa.forEach((a,l)=>{o.push(r.Ka(l,e,n).then(u=>{var c;if((u||n)&&r.isPrimaryClient){const d=u?!u.fromCache:(c=n==null?void 0:n.targetChanges.get(l.targetId))===null||c===void 0?void 0:c.current;
3082r.sharedClientState.updateQueryState(l.targetId,d?"current":"not-current")}if(u){i.push(u);const d=w1.Wi(l.targetId,u);s.push(d)}}))}),await Promise.all(o),r.Ca.d_(i),await async function(l,u){const c=We(l);try{await c.persistence.runTransaction("notifyLocalViewChanges","readwrite",d=>fe.forEach(u,f=>fe.forEach(f.$i,p=>c.persistence.referenceDelegate.addReference(d,f.targetId,p)).next(()=>fe.forEach(f.Ui,p=>c.persistence.referenceDelegate.removeReference(d,f.targetId,p)))))}catch(d){if(!sd(d))throw d;Oe("LocalStore","Failed to update sequence numbers: "+d)}for(const d of u){const f=d.targetId;if(!d.fromCache){const p=c.os.get(f),_=p.snapshotVersion,y=p.withLastLimboFreeSnapshotVersion(_);c.os=c.os.insert(f,y)}}}(r.localStore,s))}async function oU(t,e){const n=We(t);if(!n.currentUser.isEqual(e)){Oe("SyncEngine","User change. New user:",e.toKey());const r=await qO(n.localStore,e);n.currentUser=e,function(s,o){s.ka.forEach(a=>{a.forEach(l=>{l.reject(new ke(le.CANCELLED,o))})}),s.ka.clear()}(n,"'waitForPendingWrites' promise is rejected due to a user change."),n.sharedClientState.handleUserChange(e,r.removedBatchIds,r.addedBatchIds),await cd(n,r.hs)}}function aU(t,e){const n=We(t),r=n.Na.get(e);if(r&&r.va)return rt().add(r.key);{let i=rt();const s=n.Ma.get(e);if(!s)return i;for(const o of s){const a=n.Fa.get(o);i=i.unionWith(a.view.Va)}return i}}function cP(t){const e=We(t);return e.remoteStore.remoteSyncer.applyRemoteEvent=oP.bind(null,e),e.remoteStore.remoteSyncer.getRemoteKeysForTarget=aU.bind(null,e),e.remoteStore.remoteSyncer.rejectListen=nU.bind(null,e),e.Ca.d_=qV.bind(null,e.eventManager),e.Ca.$a=HV.bind(null,e.eventManager),e}function lU(t){const e=We(t);return e.remoteStore.remoteSyncer.applySuccessfulWrite=rU.bind(null,e),e.remoteStore.remoteSyncer.rejectFailedWrite=iU.bind(null,e),e}class Dp{constructor(){this.kind="memory",this.synchronizeTabs=!1}async initialize(e){this.serializer=Fm(e.databaseInfo.databaseId),this.sharedClientState=this.Wa(e),this.persistence=this.Ga(e),await this.persistence.start(),this.localStore=this.za(e),this.gcScheduler=this.ja(e,this.localStore),this.indexBackfillerScheduler=this.Ha(e,this.localStore)}ja(e,n){return null}Ha(e,n){return null}za(e){return pV(this.persistence,new dV,e.initialUser,this.serializer)}Ga(e){return new uV(_1.Zr,this.serializer)}Wa(e){return new bV}async terminate(){var e,n;(e=this.gcScheduler)===null||e===void 0||e.stop(),(n=this.indexBackfillerScheduler)===null||n===void 0||n.stop(),this.sharedClientState.shutdown(),await this.persistence.shutdown()}}Dp.provider={build:()=>new Dp};class Ky{async initialize(e,n){this.localStore||(this.localStore=e.localStore,this.sharedClientState=e.sharedClientState,this.datastore=this.createDatastore(n),this.remoteStore=this.createRemoteStore(n),this.eventManager=this.createEventManager(n),this.syncEngine=this.createSyncEngine(n,!e.synchronizeTabs),this.sharedClientState.onlineStateHandler=r=>rT(this.syncEngine,r,1),this.remoteStore.remoteSyncer.handleCredentialChange=oU.bind(null,this.syncEngine),await $V(this.remoteStore,this.syncEngine.isPrimaryClient))}createEventManager(e){return function(){return new zV}()}createDatastore(e){const n=Fm(e.databaseInfo.databaseId),r=function(s){return new SV(s)}(e.databaseInfo);return function(s,o,a,l){return new IV(s,o,a,l)}(e.authCredentials,e.appCheckCredentials,r,n)}createRemoteStore(e){return function(r,i,s,o,a){return new PV(r,i,s,o,a)}(this.localStore,this.datastore,e.asyncQueue,n=>rT(this.syncEngine,n,0),function(){return Xx.D()?new Xx:new EV}())}createSyncEngine(e,n){return function(i,s,o,a,l,u,c){const d=new YV(i,s,o,a,l,u);return c&&(d.Qa=!0),d}(this.localStore,this.remoteStore,this.eventManager,this.sharedClientState,e.initialUser,e.maxConcurrentLimboResolutions,n)}async terminate(){var e,n;await async function(i){const s=We(i);Oe("RemoteStore","RemoteStore shutting down."),s.L_.add(5),await ud(s),s.k_.shutdown(),s.q_.set("Unknown")}(this.remoteStore),(e=this.datastore)===null||e===void 0||e.terminate(),(n=this.eventManager)===null||n===void 0||n.terminate()}}Ky.provider={build:()=>new Ky};/** 3083 * @license 3084 * Copyright 2020 Google LLC 3085 * 3086 * Licensed under the Apache License, Version 2.0 (the "License");
3087 * you may not use this file except in compliance with the License. 3088 * You may obtain a copy of the License at 3089 * 3090 * http://www.apache.org/licenses/LICENSE-2.0 3091 * 3092 * Unless required by applicable law or agreed to in writing, software 3093 * distributed under the License is distributed on an "AS IS" BASIS, 3094 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3095 * See the License for the specific language governing permissions and 3096 * limitations under the License. 3097 *//** 3098 * @license 3099 * Copyright 2017 Google LLC 3100 * 3101 * Licensed under the Apache License, Version 2.0 (the "License"); 3102 * you may not use this file except in compliance with the License. 3103 * You may obtain a copy of the License at 3104 * 3105 * http://www.apache.org/licenses/LICENSE-2.0 3106 * 3107 * Unless required by applicable law or agreed to in writing, software 3108 * distributed under the License is distributed on an "AS IS" BASIS, 3109 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3110 * See the License for the specific language governing permissions and 3111 * limitations under the License. 3112 */class fP{constructor(e){this.observer=e,this.muted=!1}next(e){this.muted||this.observer.next&&this.Ya(this.observer.next,e)}error(e){this.muted||(this.observer.error?this.Ya(this.observer.error,e):Ns("Uncaught Error in snapshot listener:",e.toString()))}Za(){this.muted=!0}Ya(e,n){setTimeout(()=>{this.muted||e(n)},0)}}/** 3113 * @license 3114 * Copyright 2017 Google LLC 3115 * 3116 * Licensed under the Apache License, Version 2.0 (the "License"); 3117 * you may not use this file except in compliance with the License. 3118 * You may obtain a copy of the License at 3119 * 3120 * http://www.apache.org/licenses/LICENSE-2.0 3121 * 3122 * Unless required by applicable law or agreed to in writing, software 3123 * distributed under the License is distributed on an "AS IS" BASIS, 3124 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3125 * See the License for the specific language governing permissions and 3126 * limitations under the License. 3127 */class uU{constructor(e,n,r,i,s){this.authCredentials=e,this.appCheckCredentials=n,this.asyncQueue=r,this.databaseInfo=i,this.user=Dn.UNAUTHENTICATED,this.clientId=cO.newId(),this.authCredentialListener=()=>Promise.resolve(),this.appCheckCredentialListener=()=>Promise.resolve(),this._uninitializedComponentsProvider=s,this.authCredentials.start(r,async o=>{Oe("FirestoreClient","Received user=",o.uid),await this.authCredentialListener(o),this.user=o}),this.appCheckCredentials.start(r,o=>(Oe("FirestoreClient","Received new app check token=",o),this.appCheckCredentialListener(o,this.user)))}get configuration(){return{asyncQueue:this.asyncQueue,databaseInfo:this.databaseInfo,clientId:this.clientId,authCredentials:this.authCredentials,appCheckCredentials:this.appCheckCredentials,initialUser:this.user,maxConcurrentLimboResolutions:100}}setCredentialChangeListener(e){this.authCredentialListener=e}setAppCheckTokenChangeListener(e){this.appCheckCredentialListener=e}terminate(){this.asyncQueue.enterRestrictedMode();const e=new bs;return this.asyncQueue.enqueueAndForgetEvenWhileRestricted(async()=>{try{this._onlineComponents&&await this._onlineComponents.terminate(),this._offlineComponents&&await this._offlineComponents.terminate(),this.authCredentials.shutdown(),this.appCheckCredentials.shutdown(),e.resolve()}catch(n){const r=k1(n,"Failed to shutdown persistence");e.reject(r)}}),e.promise}}async function hv(t,e){t.asyncQueue.verifyOperationInProgress(),Oe("FirestoreClient","Initializing OfflineComponentProvider");const n=t.configuration;await e.initialize(n);let r=n.initialUser;t.setCredentialChangeListener(async i=>{r.isEqual(i)||(await qO(e.localStore,i),r=i)}),e.persistence.setDatabaseDeletedListener(()=>t.terminate()),t._offlineComponents=e}async function sT(t,e){t.asyncQueue.verifyOperationInProgress();const n=await cU(t);Oe("FirestoreClient","Initializing OnlineComponentProvider"),await e.initialize(n,t.configuration),t.setCredentialChangeListener(r=>Jx(e.remoteStore,r)),t.setAppCheckTokenChangeListener((r,i)=>Jx(e.remoteStore,i)),t._onlineComponents=e}async function cU(t){if(!t._offlineComponents)if(t._uninitializedComponentsProvider){Oe("FirestoreClient","Using user provided OfflineComponentProvider");try{await hv(t,t._uninitializedComponentsProvider._offline)}catch(e){const n=e;if(!function(i){return i.name==="FirebaseError"?i.code===le.FAILED_PRECONDITION||i.code===le.UNIMPLEMENT
3127ED:!(typeof DOMException<"u"&&i instanceof DOMException)||i.code===22||i.code===20||i.code===11}(n))throw n;bu("Error using user provided cache. Falling back to memory cache: "+n),await hv(t,new Dp)}}else Oe("FirestoreClient","Using default OfflineComponentProvider"),await hv(t,new Dp);return t._offlineComponents}async function dP(t){return t._onlineComponents||(t._uninitializedComponentsProvider?(Oe("FirestoreClient","Using user provided OnlineComponentProvider"),await sT(t,t._uninitializedComponentsProvider._online)):(Oe("FirestoreClient","Using default OnlineComponentProvider"),await sT(t,new Ky))),t._onlineComponents}function fU(t){return dP(t).then(e=>e.syncEngine)}async function hP(t){const e=await dP(t),n=e.eventManager;return n.onListen=QV.bind(null,e.syncEngine),n.onUnlisten=JV.bind(null,e.syncEngine),n.onFirstRemoteStoreListen=ZV.bind(null,e.syncEngine),n.onLastRemoteStoreUnlisten=eU.bind(null,e.syncEngine),n}function dU(t,e,n={}){const r=new bs;return t.asyncQueue.enqueueAndForget(async()=>function(s,o,a,l,u){const c=new fP({next:f=>{c.Za(),o.enqueueAndForget(()=>tP(s,d));const p=f.docs.has(a);!p&&f.fromCache?u.reject(new ke(le.UNAVAILABLE,"Failed to get document because the client is offline.")):p&&f.fromCache&&l&&l.source==="server"?u.reject(new ke(le.UNAVAILABLE,'Failed to get document from server. (However, this document does exist in the local cache. Run again without setting source to "server" to retrieve the cached document.)')):u.resolve(f)},error:f=>u.reject(f)}),d=new nP(h1(a.path),c,{includeMetadataChanges:!0,_a:!0});return eP(s,d)}(await hP(t),t.asyncQueue,e,n,r)),r.promise}function hU(t,e,n={}){const r=new bs;return t.asyncQueue.enqueueAndForget(async()=>function(s,o,a,l,u){const c=new fP({next:f=>{c.Za(),o.enqueueAndForget(()=>tP(s,d)),f.fromCache&&l.source==="server"?u.reject(new ke(le.UNAVAILABLE,'Failed to get documents from server. (However, these documents may exist in the local cache. Run again without setting source to "server" to retrieve the cached documents.)')):u.resolve(f)},error:f=>u.reject(f)}),d=new nP(a,c,{includeMetadataChanges:!0,_a:!0});return eP(s,d)}(await hP(t),t.asyncQueue,e,n,r)),r.promise}/** 3128 * @license 3129 * Copyright 2023 Google LLC 3130 * 3131 * Licensed under the Apache License, Version 2.0 (the "License"); 3132 * you may not use this file except in compliance with the License. 3133 * You may obtain a copy of the License at 3134 * 3135 * http://www.apache.org/licenses/LICENSE-2.0 3136 * 3137 * Unless required by applicable law or agreed to in writing, software 3138 * distributed under the License is distributed on an "AS IS" BASIS, 3139 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3140 * See the License for the specific language governing permissions and 3141 * limitations under the License. 3142 */function pP(t){const e={};return t.timeoutSeconds!==void 0&&(e.timeoutSeconds=t.timeoutSeconds),e}/** 3143 * @license 3144 * Copyright 2020 Google LLC 3145 * 3146 * Licensed under the Apache License, Version 2.0 (the "License"); 3147 * you may not use this file except in compliance with the License. 3148 * You may obtain a copy of the License at 3149 * 3150 * http://www.apache.org/licenses/LICENSE-2.0 3151 * 3152 * Unless required by applicable law or agreed to in writing, software 3153 * distributed under the License is distributed on an "AS IS" BASIS, 3154 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3155 * See the License for the specific language governing permissions and 3156 * limitations under the License. 3157 */const oT=new Map;/** 3158 * @license 3159 * Copyright 2017 Google LLC 3160 * 3161 * Licensed under the Apache License, Version 2.0 (the "License"); 3162 * you may not use this file except in compliance with the License. 3163 * You may obtain a copy of the License at 3164 * 3165 * http://www.apache.org/licenses/LICENSE-2.0 3166 * 3167 * Unless required by applicable law or agreed to in writing, software 3168 * distributed under the License is distributed on an "AS IS" BASIS, 3169 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3170 * See the License for the specific language governing permissions and 3171 * limitations under the License. 3172 */function mP(t,e,n){if(!n)throw new ke(le.INVALID_ARGUMENT,`Function ${t}() cannot be called with an empty ${e}.`)}function pU(t,e,n,r){if(e===!0&&r===!0)throw new ke(le.INVALID_ARGUMENT,`${t} and ${n} cannot be used together.`)}function aT(t){if(!Le.isDocumentKey(t))throw new ke(le.INVALID_ARGUMENT,`Invalid document reference. Document references must have an even number of segments, but ${t} has ${t.length}.`)}function lT(t){if(Le.isDocumentKey(t))throw new ke(le.INVALID_ARGUMENT,`Invalid collection reference. Collection references must have an odd number of segments, but ${t} has ${t.length}.`)}function $m(t){if(t===void 0)return"undefined";if(t===null)return"null";if(typeof t=="string")return t.length>20&&(t=`${t.substring(0,20)}...`),JSON.stringify(t);if(typeof t=="number"||typeof t=="boolean")return""+t;if(typeof t=="object"){if(t instanceof Array)return"an array";{const e=function(r){return r.constructor?r.constructor.name:null}(t);return e?`a custom ${e} object`:"an object"}}return typeof t=="function"?"a function":ze()}function Ms(t,e){if("_delegate"in t&&(t=t._delegate),!(t instanceof e)){if(e.name===t.constructor.name)throw new ke(le.INVALID_ARGUMENT,"Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?");{const n=$m(t);throw new ke(le.INVALID_ARGUMENT,`Expected type '${e.name}', but it was: ${n}`)}}return t}/** 3173 * @license 3174 * Copyright 2020 Google LLC 3175 * 3176 * Licensed under the Apache License, Version 2.0 (the "License");
3177 * you may not use this file except in compliance with the License. 3178 * You may obtain a copy of the License at 3179 * 3180 * http://www.apache.org/licenses/LICENSE-2.0 3181 * 3182 * Unless required by applicable law or agreed to in writing, software 3183 * distributed under the License is distributed on an "AS IS" BASIS, 3184 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3185 * See the License for the specific language governing permissions and 3186 * limitations under the License. 3187 */class uT{constructor(e){var n,r;if(e.host===void 0){if(e.ssl!==void 0)throw new ke(le.INVALID_ARGUMENT,"Can't provide ssl option if host option is not set");this.host="firestore.googleapis.com",this.ssl=!0}else this.host=e.host,this.ssl=(n=e.ssl)===null||n===void 0||n;if(this.credentials=e.credentials,this.ignoreUndefinedProperties=!!e.ignoreUndefinedProperties,this.localCache=e.localCache,e.cacheSizeBytes===void 0)this.cacheSizeBytes=41943040;else{if(e.cacheSizeBytes!==-1&&e.cacheSizeBytes<1048576)throw new ke(le.INVALID_ARGUMENT,"cacheSizeBytes must be at least 1048576");this.cacheSizeBytes=e.cacheSizeBytes}pU("experimentalForceLongPolling",e.experimentalForceLongPolling,"experimentalAutoDetectLongPolling",e.experimentalAutoDetectLongPolling),this.experimentalForceLongPolling=!!e.experimentalForceLongPolling,this.experimentalForceLongPolling?this.experimentalAutoDetectLongPolling=!1:e.experimentalAutoDetectLongPolling===void 0?this.experimentalAutoDetectLongPolling=!0:this.experimentalAutoDetectLongPolling=!!e.experimentalAutoDetectLongPolling,this.experimentalLongPollingOptions=pP((r=e.experimentalLongPollingOptions)!==null&&r!==void 0?r:{}),function(s){if(s.timeoutSeconds!==void 0){if(isNaN(s.timeoutSeconds))throw new ke(le.INVALID_ARGUMENT,`invalid long polling timeout: ${s.timeoutSeconds} (must not be NaN)`);if(s.timeoutSeconds<5)throw new ke(le.INVALID_ARGUMENT,`invalid long polling timeout: ${s.timeoutSeconds} (minimum allowed value is 5)`);if(s.timeoutSeconds>30)throw new ke(le.INVALID_ARGUMENT,`invalid long polling timeout: ${s.timeoutSeconds} (maximum allowed value is 30)`)}}(this.experimentalLongPollingOptions),this.useFetchStreams=!!e.useFetchStreams}isEqual(e){return this.host===e.host&&this.ssl===e.ssl&&this.credentials===e.credentials&&this.cacheSizeBytes===e.cacheSizeBytes&&this.experimentalForceLongPolling===e.experimentalForceLongPolling&&this.experimentalAutoDetectLongPolling===e.experimentalAutoDetectLongPolling&&function(r,i){return r.timeoutSeconds===i.timeoutSeconds}(this.experimentalLongPollingOptions,e.experimentalLongPollingOptions)&&this.ignoreUndefinedProperties===e.ignoreUndefinedProperties&&this.useFetchStreams===e.useFetchStreams}}class Bm{constructor(e,n,r,i){this._authCredentials=e,this._appCheckCredentials=n,this._databaseId=r,this._app=i,this.type="firestore-lite",this._persistenceKey="(lite)",this._settings=new uT({}),this._settingsFrozen=!1,this._terminateTask="notTerminated"}get app(){if(!this._app)throw new ke(le.FAILED_PRECONDITION,"Firestore was not initialized using the Firebase SDK. 'app' is not available");return this._app}get _initialized(){return this._settingsFrozen}get _terminated(){return this._terminateTask!=="notTerminated"}_setSettings(e){if(this._settingsFrozen)throw new ke(le.FAILED_PRECONDITION,"Firestore has already been started and its settings can no longer be changed. You can only modify settings before calling any other methods on a Firestore object.");this._settings=new uT(e),e.credentials!==void 0&&(this._authCredentials=function(r){if(!r)return new C5;switch(r.type){case"firstParty":return new L5(r.sessionIndex||"0",r.iamToken||null,r.authTokenFactory||null);case"provider":return r.client;default:throw new ke(le.INVALID_ARGUMENT,"makeAuthCredentialsProvider failed due to invalid credential type")}}(e.credentials))}_getSettings(){return this._settings}_freezeSettings(){return this._settingsFrozen=!0,this._settings}_delete(){return this._terminateTask==="notTerminated"&&(this._terminateTask=this._terminate()),this._terminateTask}async _restart(){this._terminateTask==="notTerminated"?await this._terminate():this._terminateTask="notTerminated"}toJSON(){return{app:this._app,databaseId:this._databaseId,settings:this._settings}}_terminate(){return function(n){const r=oT.get(n);r&&(Oe("ComponentProvider","Removing Datastore"),oT.delete(n),r.terminate())}(this),Promise.resolve()}}function mU(t,e,n,r={}){var i;const s=(t=Ms(t,Bm))._getSettings(),o=`${e}:${n}`;if(s.host!=="firestore.googleapis.com"&&s.host!==o&&bu("Host has been set in both settings() and connectFirestoreEmulator(), emulator host will be used."),t._setSettings(Object.assign(Object.assign({},s),{host:o,ssl:!1})),r.mockUserToken){let a,l;if(typeof r.mockUserToken=="string")a=r.mockUserToken,l=Dn.MOCK_USER;else{a=KA(r.mockUserToken,(i=t._app)===null||i===void 0?void 0:i.options.projectId);const u=r.mockUserToken.sub||r.mockUserToken.user_id;if(!u)throw new ke(le.INVALID_ARGUMENT,"mockUserToken must contain 'sub' or 'user_id' field!");l=new Dn(u)}t._authCredentials=new N5(new uO(a,l))}}/** 3188 * @license 3189 * Copyright 2020 Google LLC 3190 * 3191 * Licensed under the Apache License, Version 2.0 (the "License");
3192 * you may not use this file except in compliance with the License. 3193 * You may obtain a copy of the License at 3194 * 3195 * http://www.apache.org/licenses/LICENSE-2.0 3196 * 3197 * Unless required by applicable law or agreed to in writing, software 3198 * distributed under the License is distributed on an "AS IS" BASIS, 3199 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3200 * See the License for the specific language governing permissions and 3201 * limitations under the License. 3202 */let zm=class gP{constructor(e,n,r){this.converter=n,this._query=r,this.type="query",this.firestore=e}withConverter(e){return new gP(this.firestore,e,this._query)}};class Zn{constructor(e,n,r){this.converter=n,this._key=r,this.type="document",this.firestore=e}get _path(){return this._key.path}get id(){return this._key.path.lastSegment()}get path(){return this._key.path.canonicalString()}get parent(){return new jo(this.firestore,this.converter,this._key.path.popLast())}withConverter(e){return new Zn(this.firestore,e,this._key)}}class jo extends zm{constructor(e,n,r){super(e,n,h1(r)),this._path=r,this.type="collection"}get id(){return this._query.path.lastSegment()}get path(){return this._query.path.canonicalString()}get parent(){const e=this._path.popLast();return e.isEmpty()?null:new Zn(this.firestore,null,new Le(e))}withConverter(e){return new jo(this.firestore,e,this._path)}}function O1(t,e,...n){if(t=Ot(t),mP("collection","path",e),t instanceof Bm){const r=Lt.fromString(e,...n);return lT(r),new jo(t,null,r)}{if(!(t instanceof Zn||t instanceof jo))throw new ke(le.INVALID_ARGUMENT,"Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");const r=t._path.child(Lt.fromString(e,...n));return lT(r),new jo(t.firestore,null,r)}}function ui(t,e,...n){if(t=Ot(t),arguments.length===1&&(e=cO.newId()),mP("doc","path",e),t instanceof Bm){const r=Lt.fromString(e,...n);return aT(r),new Zn(t,null,new Le(r))}{if(!(t instanceof Zn||t instanceof jo))throw new ke(le.INVALID_ARGUMENT,"Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");const r=t._path.child(Lt.fromString(e,...n));return aT(r),new Zn(t.firestore,t instanceof jo?t.converter:null,new Le(r))}}/** 3203 * @license 3204 * Copyright 2020 Google LLC 3205 * 3206 * Licensed under the Apache License, Version 2.0 (the "License"); 3207 * you may not use this file except in compliance with the License. 3208 * You may obtain a copy of the License at 3209 * 3210 * http://www.apache.org/licenses/LICENSE-2.0 3211 * 3212 * Unless required by applicable law or agreed to in writing, software 3213 * distributed under the License is distributed on an "AS IS" BASIS, 3214 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3215 * See the License for the specific language governing permissions and 3216 * limitations under the License. 3217 */class cT{constructor(e=Promise.resolve()){this.Pu=[],this.Iu=!1,this.Tu=[],this.Eu=null,this.du=!1,this.Au=!1,this.Ru=[],this.t_=new WO(this,"async_queue_retry"),this.Vu=()=>{const r=dv();r&&Oe("AsyncQueue","Visibility state changed to "+r.visibilityState),this.t_.jo()},this.mu=e;const n=dv();n&&typeof n.addEventListener=="function"&&n.addEventListener("visibilitychange",this.Vu)}get isShuttingDown(){return this.Iu}enqueueAndForget(e){this.enqueue(e)}enqueueAndForgetEvenWhileRestricted(e){this.fu(),this.gu(e)}enterRestrictedMode(e){if(!this.Iu){this.Iu=!0,this.Au=e||!1;const n=dv();n&&typeof n.removeEventListener=="function"&&n.removeEventListener("visibilitychange",this.Vu)}}enqueue(e){if(this.fu(),this.Iu)return new Promise(()=>{});const n=new bs;return this.gu(()=>this.Iu&&this.Au?Promise.resolve():(e().then(n.resolve,n.reject),n.promise)).then(()=>n.promise)}enqueueRetryable(e){this.enqueueAndForget(()=>(this.Pu.push(e),this.pu()))}async pu(){if(this.Pu.length!==0){try{await this.Pu[0](),this.Pu.shift(),this.t_.reset()}catch(e){if(!sd(e))throw e;Oe("AsyncQueue","Operation failed with retryable error: "+e)}this.Pu.length>0&&this.t_.Go(()=>this.pu())}}gu(e){const n=this.mu.then(()=>(this.du=!0,e().catch(r=>{this.Eu=r,this.du=!1;const i=function(o){let a=o.message||"";return o.stack&&(a=o.stack.includes(o.message)?o.stack:o.message+` 3218`+o.stack),a}(r);throw Ns("INTERNAL UNHANDLED ERROR: ",i),r}).then(r=>(this.du=!1,r))));return this.mu=n,n}enqueueAfterDelay(e,n,r){this.fu(),this.Ru.indexOf(e)>-1&&(n=0);const i=S1.createAndSchedule(this,e,n,r,s=>this.yu(s));return this.Tu.push(i),i}fu(){this.Eu&&ze()}verifyOperationInProgress(){}async wu(){let e;do e=this.mu,await e;while(e!==this.mu)}Su(e){for(const n of this.Tu)if(n.timerId===e)return!0;return!1}bu(e){return this.wu().then(()=>{this.Tu.sort((n,r)=>n.targetTimeMs-r.targetTimeMs);for(const n of this.Tu)if(n.skipDelay(),e!=="all"&&n.timerId===e)break;return this.wu()})}Du(e){this.Ru.push(e)}yu(e){const n=this.Tu.indexOf(e);this.Tu.splice(n,1)}}class fd extends Bm{constructor(e,n,r,i){super(e,n,r,i),this.type="firestore",this._queue=new cT,this._persistenceKey=(i==null?void 0:i.name)||"[DEFAULT]"}async _terminate(){if(this._firestoreClient){const e=this._firestoreClient.terminate();this._queue=new cT(e),this._firestoreClient=void 0,await e}}}function gU(t,e){const n=typeof t=="object"?t:km(),r=typeof t=="string"?t:"(default)",i=Jo(n,"firestore").getImmediate({identifier:r});if(!i._initialized){const s=HA("firestore");s&&mU(i,...s)}return i}function P1(t){if(t._terminated)throw new ke(le.FAILED_PRECONDITION,"The client has already been terminated.");return t._firestoreClient||vU(t),t._firestoreClient}function vU(t){var e,n,r;const i=t._freezeSettings(),s=function(a,l,u,c){return new Y5(a,l,u,c.host,c.ssl,c.experimentalForceLongPolling,c.experimentalAutoDetectLongPolling,pP(c.experimentalLongPollingOptions),c.useFetchStreams)}(t._databaseId,((e=t._app)===null||e===void 0?void 0:e.options.appId)||"",t._persistenceKey,i);t._componentsProvider||!((n=i.localCache)===null||n===void 0)&&n._offlineComponentProvider&&(!((r=i.localCache)===null||r===void 0)&&r._onlineComponentProvider)&&(t._componentsProvider={_offline:i.localCache._offlineComponentProvider,_online:i.localCache._onlineComponentProvider}),t._firestoreClient=new uU(t._authCredentials,t._appCheckCredentials,t._queue,s,t._componentsProvider&&function(a){const l=a==null?void 0:a._online.build();return{_offline:a==null?void 0:a._offline.build(l),_online:l}}(t._componentsProvider))}/** 3219 * @license 3220 * Copyright 2020 Google LLC 3221 * 3222 * Licensed under the Apache License, Version 2.0 (the "License");
3223 * you may not use this file except in compliance with the License. 3224 * You may obtain a copy of the License at 3225 * 3226 * http://www.apache.org/licenses/LICENSE-2.0 3227 * 3228 * Unless required by applicable law or agreed to in writing, software 3229 * distributed under the License is distributed on an "AS IS" BASIS, 3230 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3231 * See the License for the specific language governing permissions and 3232 * limitations under the License. 3233 */class Au{constructor(e){this._byteString=e}static fromBase64String(e){try{return new Au(An.fromBase64String(e))}catch(n){throw new ke(le.INVALID_ARGUMENT,"Failed to construct data from Base64 string: "+n)}}static fromUint8Array(e){return new Au(An.fromUint8Array(e))}toBase64(){return this._byteString.toBase64()}toUint8Array(){return this._byteString.toUint8Array()}toString(){return"Bytes(base64: "+this.toBase64()+")"}isEqual(e){return this._byteString.isEqual(e._byteString)}}/** 3234 * @license 3235 * Copyright 2020 Google LLC 3236 * 3237 * Licensed under the Apache License, Version 2.0 (the "License"); 3238 * you may not use this file except in compliance with the License. 3239 * You may obtain a copy of the License at 3240 * 3241 * http://www.apache.org/licenses/LICENSE-2.0 3242 * 3243 * Unless required by applicable law or agreed to in writing, software 3244 * distributed under the License is distributed on an "AS IS" BASIS, 3245 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3246 * See the License for the specific language governing permissions and 3247 * limitations under the License. 3248 */class qm{constructor(...e){for(let n=0;n<e.length;++n)if(e[n].length===0)throw new ke(le.INVALID_ARGUMENT,"Invalid field name at argument $(i + 1). Field names must not be empty.");this._internalPath=new xn(e)}isEqual(e){return this._internalPath.isEqual(e._internalPath)}}/** 3249 * @license 3250 * Copyright 2020 Google LLC 3251 * 3252 * Licensed under the Apache License, Version 2.0 (the "License"); 3253 * you may not use this file except in compliance with the License. 3254 * You may obtain a copy of the License at 3255 * 3256 * http://www.apache.org/licenses/LICENSE-2.0 3257 * 3258 * Unless required by applicable law or agreed to in writing, software 3259 * distributed under the License is distributed on an "AS IS" BASIS, 3260 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3261 * See the License for the specific language governing permissions and 3262 * limitations under the License. 3263 */class R1{constructor(e){this._methodName=e}}/** 3264 * @license 3265 * Copyright 2017 Google LLC 3266 * 3267 * Licensed under the Apache License, Version 2.0 (the "License"); 3268 * you may not use this file except in compliance with the License. 3269 * You may obtain a copy of the License at 3270 * 3271 * http://www.apache.org/licenses/LICENSE-2.0 3272 * 3273 * Unless required by applicable law or agreed to in writing, software 3274 * distributed under the License is distributed on an "AS IS" BASIS, 3275 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3276 * See the License for the specific language governing permissions and 3277 * limitations under the License. 3278 */class C1{constructor(e,n){if(!isFinite(e)||e<-90||e>90)throw new ke(le.INVALID_ARGUMENT,"Latitude must be a number between -90 and 90, but was: "+e);if(!isFinite(n)||n<-180||n>180)throw new ke(le.INVALID_ARGUMENT,"Longitude must be a number between -180 and 180, but was: "+n);this._lat=e,this._long=n}get latitude(){return this._lat}get longitude(){return this._long}isEqual(e){return this._lat===e._lat&&this._long===e._long}toJSON(){return{latitude:this._lat,longitude:this._long}}_compareTo(e){return pt(this._lat,e._lat)||pt(this._long,e._long)}}/** 3279 * @license 3280 * Copyright 2024 Google LLC 3281 * 3282 * Licensed under the Apache License, Version 2.0 (the "License"); 3283 * you may not use this file except in compliance with the License. 3284 * You may obtain a copy of the License at 3285 * 3286 * http://www.apache.org/licenses/LICENSE-2.0 3287 * 3288 * Unless required by applicable law or agreed to in writing, software 3289 * distributed under the License is distributed on an "AS IS" BASIS, 3290 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3291 * See the License for the specific language governing permissions and 3292 * limitations under the License. 3293 */class N1{constructor(e){this._values=(e||[]).map(n=>n)}toArray(){return this._values.map(e=>e)}isEqual(e){return function(r,i){if(r.length!==i.length)return!1;for(let s=0;s<r.length;++s)if(r[s]!==i[s])return!1;return!0}(this._values,e._values)}}/** 3294 * @license 3295 * Copyright 2017 Google LLC 3296 * 3297 * Licensed under the Apache License, Version 2.0 (the "License");
3298 * you may not use this file except in compliance with the License. 3299 * You may obtain a copy of the License at 3300 * 3301 * http://www.apache.org/licenses/LICENSE-2.0 3302 * 3303 * Unless required by applicable law or agreed to in writing, software 3304 * distributed under the License is distributed on an "AS IS" BASIS, 3305 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3306 * See the License for the specific language governing permissions and 3307 * limitations under the License. 3308 */const yU=/^__.*__$/;class _U{constructor(e,n,r){this.data=e,this.fieldMask=n,this.fieldTransforms=r}toMutation(e,n){return this.fieldMask!==null?new ea(e,this.data,this.fieldMask,n,this.fieldTransforms):new ad(e,this.data,n,this.fieldTransforms)}}class vP{constructor(e,n,r){this.data=e,this.fieldMask=n,this.fieldTransforms=r}toMutation(e,n){return new ea(e,this.data,this.fieldMask,n,this.fieldTransforms)}}function yP(t){switch(t){case 0:case 2:case 1:return!0;case 3:case 4:return!1;default:throw ze()}}class D1{constructor(e,n,r,i,s,o){this.settings=e,this.databaseId=n,this.serializer=r,this.ignoreUndefinedProperties=i,s===void 0&&this.vu(),this.fieldTransforms=s||[],this.fieldMask=o||[]}get path(){return this.settings.path}get Cu(){return this.settings.Cu}Fu(e){return new D1(Object.assign(Object.assign({},this.settings),e),this.databaseId,this.serializer,this.ignoreUndefinedProperties,this.fieldTransforms,this.fieldMask)}Mu(e){var n;const r=(n=this.path)===null||n===void 0?void 0:n.child(e),i=this.Fu({path:r,xu:!1});return i.Ou(e),i}Nu(e){var n;const r=(n=this.path)===null||n===void 0?void 0:n.child(e),i=this.Fu({path:r,xu:!1});return i.vu(),i}Lu(e){return this.Fu({path:void 0,xu:!0})}Bu(e){return Mp(e,this.settings.methodName,this.settings.ku||!1,this.path,this.settings.qu)}contains(e){return this.fieldMask.find(n=>e.isPrefixOf(n))!==void 0||this.fieldTransforms.find(n=>e.isPrefixOf(n.field))!==void 0}vu(){if(this.path)for(let e=0;e<this.path.length;e++)this.Ou(this.path.get(e))}Ou(e){if(e.length===0)throw this.Bu("Document fields must not be empty");if(yP(this.Cu)&&yU.test(e))throw this.Bu('Document fields cannot begin and end with "__"')}}class wU{constructor(e,n,r){this.databaseId=e,this.ignoreUndefinedProperties=n,this.serializer=r||Fm(e)}Qu(e,n,r,i=!1){return new D1({Cu:e,methodName:n,qu:r,path:xn.emptyPath(),xu:!1,ku:i},this.databaseId,this.serializer,this.ignoreUndefinedProperties)}}function M1(t){const e=t._freezeSettings(),n=Fm(t._databaseId);return new wU(t._databaseId,!!e.ignoreUndefinedProperties,n)}function bU(t,e,n,r,i,s={}){const o=t.Qu(s.merge||s.mergeFields?2:0,e,n,i);L1("Data must be an object, but it was:",o,r);const a=_P(r,o);let l,u;if(s.merge)l=new xr(o.fieldMask),u=o.fieldTransforms;else if(s.mergeFields){const c=[];for(const d of s.mergeFields){const f=Yy(e,d,n);if(!o.contains(f))throw new ke(le.INVALID_ARGUMENT,`Field '${f}' is specified in your field mask but missing from your input data.`);bP(c,f)||c.push(f)}l=new xr(c),u=o.fieldTransforms.filter(d=>l.covers(d.field))}else l=null,u=o.fieldTransforms;return new _U(new ar(a),l,u)}class Hm extends R1{_toFieldTransform(e){if(e.Cu!==2)throw e.Cu===1?e.Bu(`${this._methodName}() can only appear at the top level of your update data`):e.Bu(`${this._methodName}() cannot be used with set() unless you pass {merge:true}`);return e.fieldMask.push(e.path),null}isEqual(e){return e instanceof Hm}}function EU(t,e,n,r){const i=t.Qu(1,e,n);L1("Data must be an object, but it was:",i,r);const s=[],o=ar.empty();ul(r,(l,u)=>{const c=j1(e,l,n);u=Ot(u);const d=i.Nu(c);if(u instanceof Hm)s.push(c);else{const f=dd(u,d);f!=null&&(s.push(c),o.set(c,f))}});const a=new xr(s);return new vP(o,a,i.fieldTransforms)}function xU(t,e,n,r,i,s){const o=t.Qu(1,e,n),a=[Yy(e,r,n)],l=[i];if(s.length%2!=0)throw new ke(le.INVALID_ARGUMENT,`Function ${e}() needs to be called with an even number of arguments that alternate between field names and values.`);for(let f=0;f<s.length;f+=2)a.push(Yy(e,s[f])),l.push(s[f+1]);const u=[],c=ar.empty();for(let f=a.length-1;f>=0;--f)if(!bP(u,a[f])){const p=a[f];let _=l[f];_=Ot(_);const y=o.Nu(p);if(_ instanceof Hm)u.push(p);else{const w=dd(_,y);w!=null&&(u.push(p),c.set(p,w))}}const d=new xr(u);return new vP(c,d,o.fieldTransforms)}function TU(t,e,n,r=!1){return dd(n,t.Qu(r?4:3,e))}function dd(t,e){if(wP(t=Ot(t)))return L1("Unsupported field value:",e,t),_P(t,e);if(t instanceof R1)return function(r,i){if(!yP(i.Cu))throw i.Bu(`${r._methodName}
3308() can only be used with update() and set()`);if(!i.path)throw i.Bu(`${r._methodName}() is not currently supported inside arrays`);const s=r._toFieldTransform(i);s&&i.fieldTransforms.push(s)}(t,e),null;if(t===void 0&&e.ignoreUndefinedProperties)return null;if(e.path&&e.fieldMask.push(e.path),t instanceof Array){if(e.settings.xu&&e.Cu!==4)throw e.Bu("Nested arrays are not supported");return function(r,i){const s=[];let o=0;for(const a of r){let l=dd(a,i.Lu(o));l==null&&(l={nullValue:"NULL_VALUE"}),s.push(l),o++}return{arrayValue:{values:s}}}(t,e)}return function(r,i){if((r=Ot(r))===null)return{nullValue:"NULL_VALUE"};if(typeof r=="number")return v9(i.serializer,r);if(typeof r=="boolean")return{booleanValue:r};if(typeof r=="string")return{stringValue:r};if(r instanceof Date){const s=pn.fromDate(r);return{timestampValue:Cp(i.serializer,s)}}if(r instanceof pn){const s=new pn(r.seconds,1e3*Math.floor(r.nanoseconds/1e3));return{timestampValue:Cp(i.serializer,s)}}if(r instanceof C1)return{geoPointValue:{latitude:r.latitude,longitude:r.longitude}};if(r instanceof Au)return{bytesValue:jO(i.serializer,r._byteString)};if(r instanceof Zn){const s=i.databaseId,o=r.firestore._databaseId;if(!o.isEqual(s))throw i.Bu(`Document reference is for database ${o.projectId}/${o.database} but should be for database ${s.projectId}/${s.database}`);return{referenceValue:v1(r.firestore._databaseId||i.databaseId,r._key.path)}}if(r instanceof N1)return function(o,a){return{mapValue:{fields:{__type__:{stringValue:"__vector__"},value:{arrayValue:{values:o.toArray().map(l=>{if(typeof l!="number")throw a.Bu("VectorValues must only contain numeric values.");return p1(a.serializer,l)})}}}}}}(r,i);throw i.Bu(`Unsupported field value: ${$m(r)}`)}(t,e)}function _P(t,e){const n={};return fO(t)?e.path&&e.path.length>0&&e.fieldMask.push(e.path):ul(t,(r,i)=>{const s=dd(i,e.Mu(r));s!=null&&(n[r]=s)}),{mapValue:{fields:n}}}function wP(t){return!(typeof t!="object"||t===null||t instanceof Array||t instanceof Date||t instanceof pn||t instanceof C1||t instanceof Au||t instanceof Zn||t instanceof R1||t instanceof N1)}function L1(t,e,n){if(!wP(n)||!function(i){return typeof i=="object"&&i!==null&&(Object.getPrototypeOf(i)===Object.prototype||Object.getPrototypeOf(i)===null)}(n)){const r=$m(n);throw r==="an object"?e.Bu(t+" a custom object"):e.Bu(t+" "+r)}}function Yy(t,e,n){if((e=Ot(e))instanceof qm)return e._internalPath;if(typeof e=="string")return j1(t,e);throw Mp("Field path arguments must be of type string or ",t,!1,void 0,n)}const SU=new RegExp("[~\\*/\\[\\]]");function j1(t,e,n){if(e.search(SU)>=0)throw Mp(`Invalid field path (${e}). Paths must not contain '~', '*', '/', '[', or ']'`,t,!1,void 0,n);try{return new qm(...e.split("."))._internalPath}catch{throw Mp(`Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`,t,!1,void 0,n)}}function Mp(t,e,n,r,i){const s=r&&!r.isEmpty(),o=i!==void 0;let a=`Function ${e}() called with invalid data`;n&&(a+=" (via `toFirestore()`)"),a+=". ";let l="";return(s||o)&&(l+=" (found",s&&(l+=` in field ${r}`),o&&(l+=` in document ${i}`),l+=")"),new ke(le.INVALID_ARGUMENT,a+t+l)}function bP(t,e){return t.some(n=>n.isEqual(e))}/** 3309 * @license 3310 * Copyright 2020 Google LLC 3311 * 3312 * Licensed under the Apache License, Version 2.0 (the "License"); 3313 * you may not use this file except in compliance with the License. 3314 * You may obtain a copy of the License at 3315 * 3316 * http://www.apache.org/licenses/LICENSE-2.0 3317 * 3318 * Unless required by applicable law or agreed to in writing, software 3319 * distributed under the License is distributed on an "AS IS" BASIS, 3320 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3321 * See the License for the specific language governing permissions and 3322 * limitations under the License. 3323 */class EP{constructor(e,n,r,i,s){this._firestore=e,this._userDataWriter=n,this._key=r,this._document=i,this._converter=s}get id(){return this._key.path.lastSegment()}get ref(){return new Zn(this._firestore,this._converter,this._key)}exists(){return this._document!==null}data(){if(this._document){if(this._converter){const e=new kU(this._firestore,this._userDataWriter,this._key,this._document,null);return this._converter.fromFirestore(e)}return this._userDataWriter.convertValue(this._document.data.value)}}get(e){if(this._document){const n=this._document.data.field(F1("DocumentSnapshot.get",e));if(n!==null)return this._userDataWriter.convertValue(n)}}}
3323class kU extends EP{data(){return super.data()}}function F1(t,e){return typeof e=="string"?j1(t,e):e instanceof qm?e._internalPath:e._delegate._internalPath}/** 3324 * @license 3325 * Copyright 2020 Google LLC 3326 * 3327 * Licensed under the Apache License, Version 2.0 (the "License"); 3328 * you may not use this file except in compliance with the License. 3329 * You may obtain a copy of the License at 3330 * 3331 * http://www.apache.org/licenses/LICENSE-2.0 3332 * 3333 * Unless required by applicable law or agreed to in writing, software 3334 * distributed under the License is distributed on an "AS IS" BASIS, 3335 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3336 * See the License for the specific language governing permissions and 3337 * limitations under the License. 3338 */function AU(t){if(t.limitType==="L"&&t.explicitOrderBy.length===0)throw new ke(le.UNIMPLEMENTED,"limitToLast() queries require specifying at least one orderBy() clause")}class V1{}class IU extends V1{}function Vu(t,e,...n){let r=[];e instanceof V1&&r.push(e),r=r.concat(n),function(s){const o=s.filter(l=>l instanceof U1).length,a=s.filter(l=>l instanceof Wm).length;if(o>1||o>0&&a>0)throw new ke(le.INVALID_ARGUMENT,"InvalidQuery. When using composite filters, you cannot use more than one filter at the top level. Consider nesting the multiple filters within an `and(...)` statement. For example: change `query(query, where(...), or(...))` to `query(query, and(where(...), or(...)))`.")}(r);for(const i of r)t=i._apply(t);return t}class Wm extends IU{constructor(e,n,r){super(),this._field=e,this._op=n,this._value=r,this.type="where"}static _create(e,n,r){return new Wm(e,n,r)}_apply(e){const n=this._parse(e);return xP(e._query,n),new zm(e.firestore,e.converter,Vy(e._query,n))}_parse(e){const n=M1(e.firestore);return function(s,o,a,l,u,c,d){let f;if(u.isKeyField()){if(c==="array-contains"||c==="array-contains-any")throw new ke(le.INVALID_ARGUMENT,`Invalid Query. You can't perform '${c}' queries on documentId().`);if(c==="in"||c==="not-in"){dT(d,c);const p=[];for(const _ of d)p.push(fT(l,s,_));f={arrayValue:{values:p}}}else f=fT(l,s,d)}else c!=="in"&&c!=="not-in"&&c!=="array-contains-any"||dT(d,c),f=TU(a,o,d,c==="in"||c==="not-in");return un.create(u,c,f)}(e._query,"where",n,e.firestore._databaseId,this._field,this._op,this._value)}}function Ho(t,e,n){const r=e,i=F1("where",t);return Wm._create(i,r,n)}class U1 extends V1{constructor(e,n){super(),this.type=e,this._queryConstraints=n}static _create(e,n){return new U1(e,n)}_parse(e){const n=this._queryConstraints.map(r=>r._parse(e)).filter(r=>r.getFilters().length>0);return n.length===1?n[0]:di.create(n,this._getOperator())}_apply(e){const n=this._parse(e);return n.getFilters().length===0?e:(function(i,s){let o=i;const a=s.getFlattenedFilters();for(const l of a)xP(o,l),o=Vy(o,l)}(e._query,n),new zm(e.firestore,e.converter,Vy(e._query,n)))}_getQueryConstraints(){return this._queryConstraints}_getOperator(){return this.type==="and"?"and":"or"}}function fT(t,e,n){if(typeof(n=Ot(n))=="string"){if(n==="")throw new ke(le.INVALID_ARGUMENT,"Invalid query. When querying with documentId(), you must provide a valid document ID, but it was an empty string.");if(!wO(e)&&n.indexOf("/")!==-1)throw new ke(le.INVALID_ARGUMENT,`Invalid query. When querying a collection by documentId(), you must provide a plain document ID, but '${n}' contains a '/' character.`);const r=e.path.child(Lt.fromString(n));if(!Le.isDocumentKey(r))throw new ke(le.INVALID_ARGUMENT,`Invalid query. When querying a collection group by documentId(), the value provided must result in a valid document path, but '${r}' is not because it has an odd number of segments (${r.length}).`);return Nx(t,new Le(r))}if(n instanceof Zn)return Nx(t,n._key);throw new ke(le.INVALID_ARGUMENT,`Invalid query. When querying with documentId(), you must provide a valid string or a DocumentReference, but it was: ${$m(n)}.`)}function dT(t,e){if(!Array.isArray(t)||t.length===0)throw new ke(le.INVALID_ARGUMENT,`Invalid Query. A non-empty array is required for '${e.toString()}' filters.`)}function xP(t,e){const n=function(i,s){for(const o of i)for(const a of o.getFlattenedFilters())if(s.indexOf(a.op)>=0)return a.op;return null}(t.filters,function(i){switch(i){case"!=":return["!=","not-in"];case"array-contains-any":case"in":return["not-in"];case"not-in":return["array-contains-any","in","not-in","!="];default:return[]}}(e.op));if(n!==null)throw n===e.op?new ke(le.INVALID_ARGUMENT,`Invalid query. You cannot use more than one '${e.op.toString()}' filter.`):new ke(le.INVALID_ARGUMENT,`Invalid query. You cannot use '${e.op.toString()}' filters with '${n.toString()}' filters.`)}class OU{convertValue(e,n="none"){switch(nl(e)){case 0:return null;case 1:return e.booleanValue;case 2:return tn(e.integerValue||e.doubleValue);case 3:return this.convertTimestamp(e.timestampValue);case 4:return this.convertServerTimestamp(e,n);case 5:return e.stringValue;case 6:return this.convertBytes(tl(e.bytesValue));case 7:return this.convertReference(e.referenceValue);case 8:return this.convertGeoPoint(e.geoPointValue);case 9:return this.convertArray(e.arrayValue,n);case 11:return this.convertObject(e.mapValue,n);case 10:return this.convertVectorValue(e.mapValue);default:throw ze()}}convertObject(e,n){return this.convertObjectMap(e.fields,n)}convertObjectMap(e,n="none"){const r={};return ul(e,(i,s)=>{r[i]=this.convertValue(s,n)}),r}convertVectorValue(e){var n,r,i;const s=(i=(r=(n=e.fields)===null||n===void 0?void 0:n.value.arrayValue)===null||r===void 0?void 0:r.values)===null||i===void 0?void 0:i.map(o=>tn(o.doubleValue));return new N1(s)}convertGeoPoint(e){return new C1(tn(e.latitude),tn(e.longitude))}convertArray(e,n){return(e.values||[]).map(r=>this.convertValue(r,n))}convertServerTimestamp(e,n){switch(n){case"previous":const r=u1(e);return r==null?null:this.convertValue(r,n);case"estimate":return this.convertTimestamp(Sf(e));default:return null}}convertTimestamp(e){const n=zo(e);return new pn(n.seconds,n.nanos)}convertDocumentKey(e,n){const r=Lt.fromString(e);bt(zO(r));const i=new kf(r.get(1),r.get(3)),s=new Le(r.popFirst(5));return i.isEqual(n)||Ns(`Document ${s} contains a document reference within a different database (${i.projectId}/${i.database}) which is not supported. It will be treated as a reference in the current database (${n.projectId}/${n.database}) instead.`),s}}/** 3339 * @license 3340 * Copyright 2020 Google LLC 3341 * 3342 * Licensed under the Apache License, Version 2.0 (the "License");
3343 * you may not use this file except in compliance with the License. 3344 * You may obtain a copy of the License at 3345 * 3346 * http://www.apache.org/licenses/LICENSE-2.0 3347 * 3348 * Unless required by applicable law or agreed to in writing, software 3349 * distributed under the License is distributed on an "AS IS" BASIS, 3350 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3351 * See the License for the specific language governing permissions and 3352 * limitations under the License. 3353 */function PU(t,e,n){let r;return r=t?n&&(n.merge||n.mergeFields)?t.toFirestore(e,n):t.toFirestore(e):e,r}/** 3354 * @license 3355 * Copyright 2020 Google LLC 3356 * 3357 * Licensed under the Apache License, Version 2.0 (the "License"); 3358 * you may not use this file except in compliance with the License. 3359 * You may obtain a copy of the License at 3360 * 3361 * http://www.apache.org/licenses/LICENSE-2.0 3362 * 3363 * Unless required by applicable law or agreed to in writing, software 3364 * distributed under the License is distributed on an "AS IS" BASIS, 3365 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3366 * See the License for the specific language governing permissions and 3367 * limitations under the License. 3368 */class Nc{constructor(e,n){this.hasPendingWrites=e,this.fromCache=n}isEqual(e){return this.hasPendingWrites===e.hasPendingWrites&&this.fromCache===e.fromCache}}class TP extends EP{constructor(e,n,r,i,s,o){super(e,n,r,i,o),this._firestore=e,this._firestoreImpl=e,this.metadata=s}exists(){return super.exists()}data(e={}){if(this._document){if(this._converter){const n=new Mh(this._firestore,this._userDataWriter,this._key,this._document,this.metadata,null);return this._converter.fromFirestore(n,e)}return this._userDataWriter.convertValue(this._document.data.value,e.serverTimestamps)}}get(e,n={}){if(this._document){const r=this._document.data.field(F1("DocumentSnapshot.get",e));if(r!==null)return this._userDataWriter.convertValue(r,n.serverTimestamps)}}}class Mh extends TP{data(e={}){return super.data(e)}}class RU{constructor(e,n,r,i){this._firestore=e,this._userDataWriter=n,this._snapshot=i,this.metadata=new Nc(i.hasPendingWrites,i.fromCache),this.query=r}get docs(){const e=[];return this.forEach(n=>e.push(n)),e}get size(){return this._snapshot.docs.size}get empty(){return this.size===0}forEach(e,n){this._snapshot.docs.forEach(r=>{e.call(n,new Mh(this._firestore,this._userDataWriter,r.key,r,new Nc(this._snapshot.mutatedKeys.has(r.key),this._snapshot.fromCache),this.query.converter))})}docChanges(e={}){const n=!!e.includeMetadataChanges;if(n&&this._snapshot.excludesMetadataChanges)throw new ke(le.INVALID_ARGUMENT,"To include metadata changes with your document changes, you must also pass { includeMetadataChanges:true } to onSnapshot().");return this._cachedChanges&&this._cachedChangesIncludeMetadataChanges===n||(this._cachedChanges=function(i,s){if(i._snapshot.oldDocs.isEmpty()){let o=0;return i._snapshot.docChanges.map(a=>{const l=new Mh(i._firestore,i._userDataWriter,a.doc.key,a.doc,new Nc(i._snapshot.mutatedKeys.has(a.doc.key),i._snapshot.fromCache),i.query.converter);return a.doc,{type:"added",doc:l,oldIndex:-1,newIndex:o++}})}{let o=i._snapshot.oldDocs;return i._snapshot.docChanges.filter(a=>s||a.type!==3).map(a=>{const l=new Mh(i._firestore,i._userDataWriter,a.doc.key,a.doc,new Nc(i._snapshot.mutatedKeys.has(a.doc.key),i._snapshot.fromCache),i.query.converter);let u=-1,c=-1;return a.type!==0&&(u=o.indexOf(a.doc.key),o=o.delete(a.doc.key)),a.type!==1&&(o=o.add(a.doc),c=o.indexOf(a.doc.key)),{type:CU(a.type),doc:l,oldIndex:u,newIndex:c}})}}(this,n),this._cachedChangesIncludeMetadataChanges=n),this._cachedChanges}}function CU(t){switch(t){case 0:return"added";case 2:case 3:return"modified";case 1:return"removed";default:return ze()}}/** 3369 * @license 3370 * Copyright 2020 Google LLC 3371 * 3372 * Licensed under the Apache License, Version 2.0 (the "License"); 3373 * you may not use this file except in compliance with the License. 3374 * You may obtain a copy of the License at 3375 * 3376 * http://www.apache.org/licenses/LICENSE-2.0 3377 * 3378 * Unless required by applicable law or agreed to in writing, softw
3378are 3379 * distributed under the License is distributed on an "AS IS" BASIS, 3380 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3381 * See the License for the specific language governing permissions and 3382 * limitations under the License. 3383 */function Lp(t){t=Ms(t,Zn);const e=Ms(t.firestore,fd);return dU(P1(e),t._key).then(n=>NU(e,t,n))}class SP extends OU{constructor(e){super(),this.firestore=e}convertBytes(e){return new Au(e)}convertReference(e){const n=this.convertDocumentKey(e,this.firestore._databaseId);return new Zn(this.firestore,null,n)}}function Uu(t){t=Ms(t,zm);const e=Ms(t.firestore,fd),n=P1(e),r=new SP(e);return AU(t._query),hU(n,t._query).then(i=>new RU(e,r,t,i))}function Pf(t,e,n){t=Ms(t,Zn);const r=Ms(t.firestore,fd),i=PU(t.converter,e,n);return kP(r,[bU(M1(r),"setDoc",t._key,i,t.converter!==null,n).toMutation(t._key,Li.none())])}function Rf(t,e,n,...r){t=Ms(t,Zn);const i=Ms(t.firestore,fd),s=M1(i);let o;return o=typeof(e=Ot(e))=="string"||e instanceof qm?xU(s,"updateDoc",t._key,e,n,r):EU(s,"updateDoc",t._key,e),kP(i,[o.toMutation(t._key,Li.exists(!0))])}function kP(t,e){return function(r,i){const s=new bs;return r.asyncQueue.enqueueAndForget(async()=>tU(await fU(r),i,s)),s.promise}(P1(t),e)}function NU(t,e,n){const r=n.docs.get(e._key),i=new SP(t);return new TP(t,i,e._key,r,new Nc(n.hasPendingWrites,n.fromCache),e.converter)}(function(e,n=!0){(function(i){Lu=i})(al),fi(new zr("firestore",(r,{instanceIdentifier:i,options:s})=>{const o=r.getProvider("app").getImmediate(),a=new fd(new D5(r.getProvider("auth-internal")),new F5(r.getProvider("app-check-internal")),function(u,c){if(!Object.prototype.hasOwnProperty.apply(u.options,["projectId"]))throw new ke(le.INVALID_ARGUMENT,'"projectId" not provided in firebase.initializeApp.');return new kf(u.options.projectId,c)}(o,i),o);return s=Object.assign({useFetchStreams:n},s),a._setSettings(s),a},"PUBLIC").setMultipleInstances(!0)),dr(Ix,"4.7.3",e),dr(Ix,"4.7.3","esm2017")})();/** 3384 * @license 3385 * Copyright 2017 Google LLC 3386 * 3387 * Licensed under the Apache License, Version 2.0 (the "License"); 3388 * you may not use this file except in compliance with the License. 3389 * You may obtain a copy of the License at 3390 * 3391 * http://www.apache.org/licenses/LICENSE-2.0 3392 * 3393 * Unless required by applicable law or agreed to in writing, software 3394 * distributed under the License is distributed on an "AS IS" BASIS, 3395 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3396 * See the License for the specific language governing permissions and 3397 * limitations under the License. 3398 */const AP="firebasestorage.googleapis.com",IP="storageBucket",DU=2*60*1e3,MU=10*60*1e3;/** 3399 * @license 3400 * Copyright 2017 Google LLC 3401 * 3402 * Licensed under the Apache License, Version 2.0 (the "License"); 3403 * you may not use this file except in compliance with the License. 3404 * You may obtain a copy of the License at 3405 * 3406 * http://www.apache.org/licenses/LICENSE-2.0 3407 * 3408 * Unless required by applicable law or agreed to in writing, software 3409 * distributed under the License is distributed on an "AS IS" BASIS, 3410 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3411 * See the License for the specific language governing permissions and 3412 * limitations under the License. 3413 */class Jt extends qr{constructor(e,n,r=0){super(pv(e),`Firebase Storage: ${n} (${pv(e)})`),this.status_=r,this.customData={serverResponse:null},this._baseMessage=this.message,Object.setPrototypeOf(this,Jt.prototype)}get status(){return this.status_}set status(e){this.status_=e}_codeEquals(e){return pv(e)===this.code}get serverResponse(){return this.customData.serverResponse}set serverResponse(e){this.customData.serverResponse=e,this.customData.serverResponse?this.message=`${this._baseMessage} 3414${this.customData.serverResponse}`:this.message=this._baseMessage}}var Xt;(function(t){t.UNKNOWN="unknown",t.OBJECT_NOT_FOUND="object-not-found",t.BUCKET_NOT_FOUND="bucket-not-found",t.PROJECT_NOT_FOUND="project-not-found",t.QUOTA_EXCEEDED="quota-exceeded",t.UNAUTHENTICATED="unauthenticated",t.UNAUTHORIZED="unauthorized",t.UNAUTHORIZED_APP="unauthorized-app",t.RETRY_LIMIT_EXCEEDED="retry-limit-exceeded",t.INVALID_CHECKSUM="invalid-checksum",t.CANCELED="canceled",t.INVALID_EVENT_NAME="invalid-event-name",t.INVA
3414LID_URL="invalid-url",t.INVALID_DEFAULT_BUCKET="invalid-default-bucket",t.NO_DEFAULT_BUCKET="no-default-bucket",t.CANNOT_SLICE_BLOB="cannot-slice-blob",t.SERVER_FILE_WRONG_SIZE="server-file-wrong-size",t.NO_DOWNLOAD_URL="no-download-url",t.INVALID_ARGUMENT="invalid-argument",t.INVALID_ARGUMENT_COUNT="invalid-argument-count",t.APP_DELETED="app-deleted",t.INVALID_ROOT_OPERATION="invalid-root-operation",t.INVALID_FORMAT="invalid-format",t.INTERNAL_ERROR="internal-error",t.UNSUPPORTED_ENVIRONMENT="unsupported-environment"})(Xt||(Xt={}));function pv(t){return"storage/"+t}function $1(){const t="An unknown error occurred, please check the error payload for server response.";return new Jt(Xt.UNKNOWN,t)}function LU(t){return new Jt(Xt.OBJECT_NOT_FOUND,"Object '"+t+"' does not exist.")}function jU(t){return new Jt(Xt.QUOTA_EXCEEDED,"Quota for bucket '"+t+"' exceeded, please view quota on https://firebase.google.com/pricing/.")}function FU(){const t="User is not authenticated, please authenticate using Firebase Authentication and try again.";return new Jt(Xt.UNAUTHENTICATED,t)}function VU(){return new Jt(Xt.UNAUTHORIZED_APP,"This app does not have permission to access Firebase Storage on this project.")}function UU(t){return new Jt(Xt.UNAUTHORIZED,"User does not have permission to access '"+t+"'.")}function $U(){return new Jt(Xt.RETRY_LIMIT_EXCEEDED,"Max retry time for operation exceeded, please try again.")}function BU(){return new Jt(Xt.CANCELED,"User canceled the upload/download.")}function zU(t){return new Jt(Xt.INVALID_URL,"Invalid URL '"+t+"'.")}function qU(t){return new Jt(Xt.INVALID_DEFAULT_BUCKET,"Invalid default bucket '"+t+"'.")}function HU(){return new Jt(Xt.NO_DEFAULT_BUCKET,"No default bucket found. Did you set the '"+IP+"' property when initializing the app?")}function WU(){return new Jt(Xt.CANNOT_SLICE_BLOB,"Cannot slice blob for upload. Please retry the upload.")}function GU(){return new Jt(Xt.NO_DOWNLOAD_URL,"The given file does not have any download URLs.")}function KU(t){return new Jt(Xt.UNSUPPORTED_ENVIRONMENT,`${t} is missing. Make sure to install the required polyfills. See https://firebase.google.com/docs/web/environments-js-sdk#polyfills for more information.`)}function Qy(t){return new Jt(Xt.INVALID_ARGUMENT,t)}function OP(){return new Jt(Xt.APP_DELETED,"The Firebase app was deleted.")}function YU(t){return new Jt(Xt.INVALID_ROOT_OPERATION,"The operation '"+t+"' cannot be performed on a root reference, create a non-root reference using child, such as .child('file.png').")}function Zc(t,e){return new Jt(Xt.INVALID_FORMAT,"String does not match format '"+t+"': "+e)}function _c(t){throw new Jt(Xt.INTERNAL_ERROR,"Internal error: "+t)}/** 3415 * @license 3416 * Copyright 2017 Google LLC 3417 * 3418 * Licensed under the Apache License, Version 2.0 (the "License"); 3419 * you may not use this file except in compliance with the License. 3420 * You may obtain a copy of the License at 3421 * 3422 * http://www.apache.org/licenses/LICENSE-2.0 3423 * 3424 * Unless required by applicable law or agreed to in writing, software 3425 * distributed under the License is distributed on an "AS IS" BASIS, 3426 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3427 * See the License for the specific language governing permissions and 3428 * limitations under the License. 3429 */class Yn{constructor(e,n){this.bucket=e,this.path_=n}get path(){return this.path_}get isRoot(){return this.path.length===0}fullServerUrl(){const e=encodeURIComponent;return"/b/"+e(this.bucket)+"/o/"+e(this.path)}bucketOnlyServerUrl(){return"/b/"+encodeURIComponent(this.bucket)+"/o"}static makeFromBucketSpec(e,n){let r;try{r=Yn.makeFromUrl(e,n)}catch{return new Yn(e,"")}if(r.path==="")return r;throw qU(e)}static makeFromUrl(e,n){let r=null;const i="([A-Za-z0-9.\\-_]+)";function s(v){v.path.charAt(v.path.length-1)==="/"&&(v.path_=v.path_.slice(0,-1))}const o="(/(.*))?$",a=new RegExp("^gs://"+i+o,"i"),l={bucket:1,path:3};function u(v){v.path_=decodeURIComponent(v.path)}const c="v[A-Za-z0-9_]+",d=n.replace(/[.]/g,"\\."),f="(/([^?#]*).*)?$",p=new RegExp(`^https?://${d}/${c}/b/${i}/o${f}`,"i"),_={bucket:1,path:3},y=n===AP?"(?:storage.googleapis.com|storage.cloud.google.com)":n,w="([^?#]*)",g=new RegExp(`^https?://${y}/${i}/${w}`,"i"),b=[{regex:a,indices:l,postModify:s},{regex:p,indices:_,postModify:u},{regex:g,indices:{bucket:1,path:2},postModify:u}];for(let v=0;v<b.length;v++){const A=b[v],N=A.regex.exec(e);if(N){const x=N[A.indices.bucket];let E=N[A.indices.path];E||(E=""),r=new Yn(x,E),A.postModify(r);break}}if(r==null)throw zU(e);return r}}class QU{constructor(e){this.promise_=Promise.reject(e)}getPromise(){return this.promise_}cancel(e=!1){}}/** 3430 * @license 3431 * Copyright 2017 Google LLC 3432 * 3433 * Licensed under the Apache License, Version 2.0 (the "License");
3434 * you may not use this file except in compliance with the License. 3435 * You may obtain a copy of the License at 3436 * 3437 * http://www.apache.org/licenses/LICENSE-2.0 3438 * 3439 * Unless required by applicable law or agreed to in writing, software 3440 * distributed under the License is distributed on an "AS IS" BASIS, 3441 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3442 * See the License for the specific language governing permissions and 3443 * limitations under the License. 3444 */function ZU(t,e,n){let r=1,i=null,s=null,o=!1,a=0;function l(){return a===2}let u=!1;function c(...w){u||(u=!0,e.apply(null,w))}function d(w){i=setTimeout(()=>{i=null,t(p,l())},w)}function f(){s&&clearTimeout(s)}function p(w,...g){if(u){f();return}if(w){f(),c.call(null,w,...g);return}if(l()||o){f(),c.call(null,w,...g);return}r<64&&(r*=2);let b;a===1?(a=2,b=0):b=(r+Math.random())*1e3,d(b)}let _=!1;function y(w){_||(_=!0,f(),!u&&(i!==null?(w||(a=2),clearTimeout(i),d(0)):w||(a=1)))}return d(0),s=setTimeout(()=>{o=!0,y(!0)},n),y}function XU(t){t(!1)}/** 3445 * @license 3446 * Copyright 2017 Google LLC 3447 * 3448 * Licensed under the Apache License, Version 2.0 (the "License"); 3449 * you may not use this file except in compliance with the License. 3450 * You may obtain a copy of the License at 3451 * 3452 * http://www.apache.org/licenses/LICENSE-2.0 3453 * 3454 * Unless required by applicable law or agreed to in writing, software 3455 * distributed under the License is distributed on an "AS IS" BASIS, 3456 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3457 * See the License for the specific language governing permissions and 3458 * limitations under the License. 3459 */function JU(t){return t!==void 0}function e8(t){return typeof t=="object"&&!Array.isArray(t)}function B1(t){return typeof t=="string"||t instanceof String}function hT(t){return z1()&&t instanceof Blob}function z1(){return typeof Blob<"u"}function Zy(t,e,n,r){if(r<e)throw Qy(`Invalid value for '${t}'. Expected ${e} or greater.`);if(r>n)throw Qy(`Invalid value for '${t}'. Expected ${n} or less.`)}/** 3460 * @license 3461 * Copyright 2017 Google LLC 3462 * 3463 * Licensed under the Apache License, Version 2.0 (the "License"); 3464 * you may not use this file except in compliance with the License. 3465 * You may obtain a copy of the License at 3466 * 3467 * http://www.apache.org/licenses/LICENSE-2.0 3468 * 3469 * Unless required by applicable law or agreed to in writing, software 3470 * distributed under the License is distributed on an "AS IS" BASIS, 3471 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3472 * See the License for the specific language governing permissions and 3473 * limitations under the License. 3474 */function hd(t,e,n){let r=e;return n==null&&(r=`https://${e}`),`${n}://${r}/v0${t}`}function PP(t){const e=encodeURIComponent;let n="?";for(const r in t)if(t.hasOwnProperty(r)){const i=e(r)+"="+e(t[r]);n=n+i+"&"}return n=n.slice(0,-1),n}var Ua;(function(t){t[t.NO_ERROR=0]="NO_ERROR",t[t.NETWORK_ERROR=1]="NETWORK_ERROR",t[t.ABORT=2]="ABORT"})(Ua||(Ua={}));/** 3475 * @license 3476 * Copyright 2022 Google LLC 3477 * 3478 * Licensed under the Apache License, Version 2.0 (the "License"); 3479 * you may not use this file except in compliance with the License. 3480 * You may obtain a copy of the License at 3481 * 3482 * http://www.apache.org/licenses/LICENSE-2.0 3483 * 3484 * Unless required by applicable law or agreed to in writing, software 3485 * distributed under the License is distributed on an "AS IS" BASIS, 3486 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3487 * See the License for the specific language governing permissions and 3488 * limitations under the License. 3489 */function t8(t,e){const n=t>=500&&t<600,i=[408,429].indexOf(t)!==-1,s=e.indexOf(t)!==-1;return n||i||s}/** 3490 * @license 3491 * Copyright 2017 Google LLC 3492 * 3493 * Licensed under the Apache License, Version 2.0 (the "License"); 3494 * you may not use this file except in compliance with the License. 3495 * You may obtain a copy of the License at 3496 * 3497 * http://www.apache.org/licenses/LICENSE-2.0 3498 * 3499 * Unless required by applicable law or agreed to in writing, software 3500 * distributed under the License is distributed on an "AS IS" BASIS, 3501 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3502 * See the License for the specific language governing permissions and 3503 * limitations under the License. 3504 */class n8{constructor(e,n,r,i,s,o,a,l,u,c,d,f=!0){this.url_=e,this.method_=n,this.headers_=r,this.body_=i,this.successCodes_=s,this.additionalRetryCodes_=o,this.callback_=a,this.errorCallback_=l,this.timeout_=u,this.progressCallback_=c,this.connectionFactory_=d,this.retry=f,this.pendingConnection_=null,this.backoffId_=null,this.canceled_=!1,this.appDelete_=!1,this.promise_=new Promise((p,_)=>{this.resolve_=p,this.reject_=_,this.start_()})}start_(){const e=(r,i)=>{if(i){r(!1,new rh(!1,null,!0));return}const s=this.connectionFactory_();this.pendingConnection_=s;const o=a=>{const l=a.loaded,u=a.lengthComputable?a.total:-1;this.progressCallback_!==null&&this.progressCallback_(l,u)};this.progressCallback_!==null&&s.addUploadProgressListener(o),s.send(this.url_,this.method_,this.body_,this.headers_).then(()=>{this.progressCallback_!==null&&s.removeUploadProgressListener(o),this.pendingConnection_=null;const a=s.getErrorCode()===Ua.NO_ERROR,l=s.getStatus();if(!a||t8(l,this.additionalRetryCodes_)&&this.retry){const c=s.getErrorCode()===Ua.ABORT;r(!1,new rh(!1,null,c));return}const u=this.successCodes_.indexOf(l)!==-1;r(!0,new rh(u,s))})},n=(r,i)=>{const s=this.resolve_,o=this.reject_,a=i.connection;if(i.wasSuccessCode)try{const l=this.callback_(a,a.getResponse());JU(l)?s(l):s()}catch(l){o(l)}else if(a!==null){const l=$1();l.serverResponse=a.getErrorText(),this.errorCallback_?o(this.errorCallback_(a,l)):o(l)}else if(i.canceled){const l=this.appDelete_?OP():BU();o(l)}else{const l=$U();o(l)}};this.canceled_?n(!1,new rh(!1,null,!0)):this.backoffId_=ZU(e,n,this.timeout_)}getPromise(){return this.promise_}cancel(e){this.canceled_=!0,this.appDelete_=e||!1,this.backoffId_!==null&&XU(this.backoffId_),this.pendingConnection_!==null&&this.pendingConnection_.abort()}}class rh{constructor(e,n,r){this.wasSuccessCode=e,this.connection=n,this.canceled=!!r}}function r8(t,e){e!==null&&e.length>0&&(t.Authorization="Firebase "+e)}function i8(t,e){t["X-Firebase-Storage-Version"]="webjs/"+(e??"AppManager")}function s8(t,e){e&&(t["X-Firebase-GMPID"]=e)}function o8(t,e){e!==null&&(t["X-Firebase-AppCheck"]=e)}
3504function a8(t,e,n,r,i,s,o=!0){const a=PP(t.urlParams),l=t.url+a,u=Object.assign({},t.headers);return s8(u,e),r8(u,n),i8(u,s),o8(u,r),new n8(l,t.method,u,t.body,t.successCodes,t.additionalRetryCodes,t.handler,t.errorHandler,t.timeout,t.progressCallback,i,o)}/** 3505 * @license 3506 * Copyright 2017 Google LLC 3507 * 3508 * Licensed under the Apache License, Version 2.0 (the "License"); 3509 * you may not use this file except in compliance with the License. 3510 * You may obtain a copy of the License at 3511 * 3512 * http://www.apache.org/licenses/LICENSE-2.0 3513 * 3514 * Unless required by applicable law or agreed to in writing, software 3515 * distributed under the License is distributed on an "AS IS" BASIS, 3516 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3517 * See the License for the specific language governing permissions and 3518 * limitations under the License. 3519 */function l8(){return typeof BlobBuilder<"u"?BlobBuilder:typeof WebKitBlobBuilder<"u"?WebKitBlobBuilder:void 0}function u8(...t){const e=l8();if(e!==void 0){const n=new e;for(let r=0;r<t.length;r++)n.append(t[r]);return n.getBlob()}else{if(z1())return new Blob(t);throw new Jt(Xt.UNSUPPORTED_ENVIRONMENT,"This browser doesn't seem to support creating Blobs")}}function c8(t,e,n){return t.webkitSlice?t.webkitSlice(e,n):t.mozSlice?t.mozSlice(e,n):t.slice?t.slice(e,n):null}/** 3520 * @license 3521 * Copyright 2021 Google LLC 3522 * 3523 * Licensed under the Apache License, Version 2.0 (the "License"); 3524 * you may not use this file except in compliance with the License. 3525 * You may obtain a copy of the License at 3526 * 3527 * http://www.apache.org/licenses/LICENSE-2.0 3528 * 3529 * Unless required by applicable law or agreed to in writing, software 3530 * distributed under the License is distributed on an "AS IS" BASIS, 3531 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3532 * See the License for the specific language governing permissions and 3533 * limitations under the License. 3534 */function f8(t){if(typeof atob>"u")throw KU("base-64");return atob(t)}/** 3535 * @license 3536 * Copyright 2017 Google LLC 3537 * 3538 * Licensed under the Apache License, Version 2.0 (the "License"); 3539 * you may not use this file except in compliance with the License. 3540 * You may obtain a copy of the License at 3541 * 3542 * http://www.apache.org/licenses/LICENSE-2.0 3543 * 3544 * Unless required by applicable law or agreed to in writing, software 3545 * distributed under the License is distributed on an "AS IS" BASIS, 3546 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3547 * See the License for the specific language governing permissions and 3548 * limitations under the License. 3549 */const ii={RAW:"raw",BASE64:"base64",BASE64URL:"base64url",DATA_URL:"data_url"};class mv{constructor(e,n){this.data=e,this.contentType=n||null}}function RP(t,e){switch(t){case ii.RAW:return new mv(CP(e));case ii.BASE64:case ii.BASE64URL:return new mv(NP(t,e));case ii.DATA_URL:return new mv(h8(e),p8(e))}throw $1()}function CP(t){const e=[];for(let n=0;n<t.length;n++){let r=t.charCodeAt(n);if(r<=127)e.push(r);else if(r<=2047)e.push(192|r>>6,128|r&63);else if((r&64512)===55296)if(!(n<t.length-1&&(t.charCodeAt(n+1)&64512)===56320))e.push(239,191,189);else{const s=r,o=t.charCodeAt(++n);r=65536|(s&1023)<<10|o&1023,e.push(240|r>>18,128|r>>12&63,128|r>>6&63,128|r&63)}else(r&64512)===56320?e.push(239,191,189):e.push(224|r>>12,128|r>>6&63,128|r&63)}return new Uint8Array(e)}function d8(t){let e;try{e=decodeURIComponent(t)}catch{throw Zc(ii.DATA_URL,"Malformed data URL.")}return CP(e)}function NP(t,e){switch(t){case ii.BASE64:{const i=e.indexOf("-")!==-1,s=e.indexOf("_")!==-1;if(i||s)throw Zc(t,"Invalid character '"+(i?"-":"_")+"' found: is it base64url encoded?");break}case ii.BASE64URL:{const i=e.indexOf("+")!==-1,s=e.indexOf("/")!==-1;if(i||s)throw Zc(t,"Invalid character '"+(i?"+":"/")+"' found: is it base64 encoded?");e=e.replace(/-/g,"+").replace(/_/g,"/");break}}let n;try{n=f8(e)}catch(i){throw i.message.includes("polyfill")?i:Zc(t,"Invalid character found")}const r=new Uint8Array(n.length);for(let i=0;i<n.length;i++)r[i]=n.charCodeAt(i);return r}class DP{constructor(e){this.base64=!1,this.contentType=null;const n=e.match(/^data:([^,]+)?,/);if(n===null)throw Zc(ii.DATA_URL,"Must be formatted 'data:[<mediatype>][;base64],<data>");const r=n[1]||null;r!=null&&(this.base64=m8(r,";base64"),this.contentType=this.base64?r.substring(0,r.length-7):r),this.rest=e.substring(e.indexOf(",")+1)}}function h8(t){const e=new DP(t);return e.base64?NP(ii.BASE64,e.rest):d8(e.rest)}function p8(t){return new DP(t).contentType}function m8(t,e){return t.length>=e.length?t.substring(t.length-e.length)===e:!1}/** 3550 * @license 3551 * Copyright 2017 Google LLC 3552 * 3553 * Licensed under the Apache License, Version 2.0 (the "License");
3554 * you may not use this file except in compliance with the License. 3555 * You may obtain a copy of the License at 3556 * 3557 * http://www.apache.org/licenses/LICENSE-2.0 3558 * 3559 * Unless required by applicable law or agreed to in writing, software 3560 * distributed under the License is distributed on an "AS IS" BASIS, 3561 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3562 * See the License for the specific language governing permissions and 3563 * limitations under the License. 3564 */class uo{constructor(e,n){let r=0,i="";hT(e)?(this.data_=e,r=e.size,i=e.type):e instanceof ArrayBuffer?(n?this.data_=new Uint8Array(e):(this.data_=new Uint8Array(e.byteLength),this.data_.set(new Uint8Array(e))),r=this.data_.length):e instanceof Uint8Array&&(n?this.data_=e:(this.data_=new Uint8Array(e.length),this.data_.set(e)),r=e.length),this.size_=r,this.type_=i}size(){return this.size_}type(){return this.type_}slice(e,n){if(hT(this.data_)){const r=this.data_,i=c8(r,e,n);return i===null?null:new uo(i)}else{const r=new Uint8Array(this.data_.buffer,e,n-e);return new uo(r,!0)}}static getBlob(...e){if(z1()){const n=e.map(r=>r instanceof uo?r.data_:r);return new uo(u8.apply(null,n))}else{const n=e.map(o=>B1(o)?RP(ii.RAW,o).data:o.data_);let r=0;n.forEach(o=>{r+=o.byteLength});const i=new Uint8Array(r);let s=0;return n.forEach(o=>{for(let a=0;a<o.length;a++)i[s++]=o[a]}),new uo(i,!0)}}uploadData(){return this.data_}}/** 3565 * @license 3566 * Copyright 2017 Google LLC 3567 * 3568 * Licensed under the Apache License, Version 2.0 (the "License"); 3569 * you may not use this file except in compliance with the License. 3570 * You may obtain a copy of the License at 3571 * 3572 * http://www.apache.org/licenses/LICENSE-2.0 3573 * 3574 * Unless required by applicable law or agreed to in writing, software 3575 * distributed under the License is distributed on an "AS IS" BASIS, 3576 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3577 * See the License for the specific language governing permissions and 3578 * limitations under the License. 3579 */function q1(t){let e;try{e=JSON.parse(t)}catch{return null}return e8(e)?e:null}/** 3580 * @license 3581 * Copyright 2017 Google LLC 3582 * 3583 * Licensed under the Apache License, Version 2.0 (the "License"); 3584 * you may not use this file except in compliance with the License. 3585 * You may obtain a copy of the License at 3586 * 3587 * http://www.apache.org/licenses/LICENSE-2.0 3588 * 3589 * Unless required by applicable law or agreed to in writing, software 3590 * distributed under the License is distributed on an "AS IS" BASIS, 3591 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3592 * See the License for the specific language governing permissions and 3593 * limitations under the License. 3594 */function g8(t){if(t.length===0)return null;const e=t.lastIndexOf("/");return e===-1?"":t.slice(0,e)}function v8(t,e){const n=e.split("/").filter(r=>r.length>0).join("/");return t.length===0?n:t+"/"+n}function MP(t){const e=t.lastIndexOf("/",t.length-2);return e===-1?t:t.slice(e+1)}/** 3595 * @license 3596 * Copyright 2017 Google LLC 3597 * 3598 * Licensed under the Apache License, Version 2.0 (the "License"); 3599 * you may not use this file except in compliance with the License. 3600 * You may obtain a copy of the License at 3601 * 3602 * http://www.apache.org/licenses/LICENSE-2.0 3603 * 3604 * Unless required by applicable law or agreed to in writing, software 3605 * distributed under the License is distributed on an "AS IS" BASIS, 3606 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3607 * See the License for the specific language governing permissions and 3608 * limitations under the License. 3609 */function y8(t,e){return e}class Bn{constructor(e,n,r,i){this.server=e,this.local=n||e,this.writable=!!r,this.xform=i||y8}}let ih=null;function _8(t){return!B1(t)||t.length<2?t:MP(t)}function LP(){if(ih)return ih;const t=[];t.push(new Bn("bucket")),t.push(new Bn("generation")),t.push(new Bn("metageneration")),t.push(new Bn("name","fullPath",!0));function e(s,o){return _8(o)}const n=new Bn("name");n.xform=e,t.push(n);function r(s,o){return o!==void 0?Number(o):o}const i=new Bn("size");return i.xform=r,t.push(i),t.push(new Bn("timeCreated")),t.push(new Bn("updated")),t.push(new Bn("md5Hash",null,!0)),t.push(new Bn("cacheControl",null,!0)),t.push(new Bn("contentDisposition",null,!0)),t.push(new Bn("contentEncoding",null,!0)),t.push(new Bn("contentLanguage",null,!0)),t.push(new Bn("contentType",null,!0)),t.push(new Bn("metadata","customMetadata",!0)),ih=t,ih}function w8(t,e){function n(){const r=t.bucket,i=t.fullPath,s=new Yn(r,i);return e._makeStorageReference(s)}Object.defineProperty(t,"ref",{get:n})}function b8(t,e,n){const r={};r.type="file";const i=n.length;for(let s=0;s<i;s++){const o=n[s];r[o.local]=o.xform(r,e[o.server])}return w8(r,t),r}function jP(t,e,n){const r=q1(e);return r===null?null:b8(t,r,n)}function E8(t,e,n,r){const i=q1(e);if(i===null||!B1(i.downloadTokens))return null;const s=i.downloadTokens;if(s.length===0)return null;const o=encodeURIComponent;return s.split(",").map(u=>{const c=t.bucket,d=t.fullPath,f="/b/"+o(c)+"/o/"+o(d),p=hd(f,n,r),_=PP({alt:"media",token:u});return p+_})[0]}function x8(t,e){const n={},r=e.length;for(let i=0;i<r;i++){const s=e[i];s.writable&&(n[s.server]=t[s.local])}return JSON.stringify(n)}/** 3610 * @license 3611 * Copyright 2019 Google LLC 3612 * 3613 * Licensed under the Apache License, Version 2.0 (the "License");
3614 * you may not use this file except in compliance with the License. 3615 * You may obtain a copy of the License at 3616 * 3617 * http://www.apache.org/licenses/LICENSE-2.0 3618 * 3619 * Unless required by applicable law or agreed to in writing, software 3620 * distributed under the License is distributed on an "AS IS" BASIS, 3621 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3622 * See the License for the specific language governing permissions and 3623 * limitations under the License. 3624 */const pT="prefixes",mT="items";function T8(t,e,n){const r={prefixes:[],items:[],nextPageToken:n.nextPageToken};if(n[pT])for(const i of n[pT]){const s=i.replace(/\/$/,""),o=t._makeStorageReference(new Yn(e,s));r.prefixes.push(o)}if(n[mT])for(const i of n[mT]){const s=t._makeStorageReference(new Yn(e,i.name));r.items.push(s)}return r}function S8(t,e,n){const r=q1(n);return r===null?null:T8(t,e,r)}class Gm{constructor(e,n,r,i){this.url=e,this.method=n,this.handler=r,this.timeout=i,this.urlParams={},this.headers={},this.body=null,this.errorHandler=null,this.progressCallback=null,this.successCodes=[200],this.additionalRetryCodes=[]}}/** 3625 * @license 3626 * Copyright 2017 Google LLC 3627 * 3628 * Licensed under the Apache License, Version 2.0 (the "License"); 3629 * you may not use this file except in compliance with the License. 3630 * You may obtain a copy of the License at 3631 * 3632 * http://www.apache.org/licenses/LICENSE-2.0 3633 * 3634 * Unless required by applicable law or agreed to in writing, software 3635 * distributed under the License is distributed on an "AS IS" BASIS, 3636 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3637 * See the License for the specific language governing permissions and 3638 * limitations under the License. 3639 */function H1(t){if(!t)throw $1()}function k8(t,e){function n(r,i){const s=jP(t,i,e);return H1(s!==null),s}return n}function A8(t,e){function n(r,i){const s=S8(t,e,i);return H1(s!==null),s}return n}function I8(t,e){function n(r,i){const s=jP(t,i,e);return H1(s!==null),E8(s,i,t.host,t._protocol)}return n}function W1(t){function e(n,r){let i;return n.getStatus()===401?n.getErrorText().includes("Firebase App Check token is invalid")?i=VU():i=FU():n.getStatus()===402?i=jU(t.bucket):n.getStatus()===403?i=UU(t.path):i=r,i.status=n.getStatus(),i.serverResponse=r.serverResponse,i}return e}function FP(t){const e=W1(t);function n(r,i){let s=e(r,i);return r.getStatus()===404&&(s=LU(t.path)),s.serverResponse=i.serverResponse,s}return n}function O8(t,e,n,r,i){const s={};e.isRoot?s.prefix="":s.prefix=e.path+"/",n.length>0&&(s.delimiter=n),r&&(s.pageToken=r),i&&(s.maxResults=i);const o=e.bucketOnlyServerUrl(),a=hd(o,t.host,t._protocol),l="GET",u=t.maxOperationRetryTime,c=new Gm(a,l,A8(t,e.bucket),u);return c.urlParams=s,c.errorHandler=W1(e),c}function P8(t,e,n){const r=e.fullServerUrl(),i=hd(r,t.host,t._protocol),s="GET",o=t.maxOperationRetryTime,a=new Gm(i,s,I8(t,n),o);return a.errorHandler=FP(e),a}function R8(t,e){const n=e.fullServerUrl(),r=hd(n,t.host,t._protocol),i="DELETE",s=t.maxOperationRetryTime;function o(l,u){}const a=new Gm(r,i,o,s);return a.successCodes=[200,204],a.errorHandler=FP(e),a}function C8(t,e){return t&&t.contentType||e&&e.type()||"application/octet-stream"}function N8(t,e,n){const r=Object.assign({},n);return r.fullPath=t.path,r.size=e.size(),r.contentType||(r.contentType=C8(null,e)),r}function D8(t,e,n,r,i){const s=e.bucketOnlyServerUrl(),o={"X-Goog-Upload-Protocol":"multipart"};function a(){let b="";for(let v=0;v<2;v++)b=b+Math.random().toString().slice(2);return b}const l=a();o["Content-Type"]="multipart/related; boundary="+l;const u=N8(e,r,i),c=x8(u,n),d="--"+l+`\r 3640Content-Type: application/json; charset=utf-8\r 3641\r 3642`+c+`\r 3643--`+l+`\r 3644Content-Type: `+u.contentType+`\r 3645\r 3646`,f=`\r 3647--`+l+"--",p=uo.getBlob(d,r,f);if(p===null)throw WU();const _={name:u.fullPath},y=hd(s,t.host,t._protocol),w="POST",g=t.maxUploadRetryTime,m=new Gm(y,w,k8(t,n),g);return m.urlParams=_,m.headers=o,m.body=p.uploadData(),m.errorHandler=W1(e),m}class M8{constructor(){this.sent_=!1,this.xhr_=new XMLHttpRequest,this.initXhr(),this.errorCode_=Ua.NO_ERROR,this.sendPromise_=new Promise(e=>{this.xhr_.addEventListener("abort",()=>{this.errorCode_=Ua.ABORT,e()}),this.xhr_.addEventListener("error",()=>
3647{this.errorCode_=Ua.NETWORK_ERROR,e()}),this.xhr_.addEventListener("load",()=>{e()})})}send(e,n,r,i){if(this.sent_)throw _c("cannot .send() more than once");if(this.sent_=!0,this.xhr_.open(n,e,!0),i!==void 0)for(const s in i)i.hasOwnProperty(s)&&this.xhr_.setRequestHeader(s,i[s].toString());return r!==void 0?this.xhr_.send(r):this.xhr_.send(),this.sendPromise_}getErrorCode(){if(!this.sent_)throw _c("cannot .getErrorCode() before sending");return this.errorCode_}getStatus(){if(!this.sent_)throw _c("cannot .getStatus() before sending");try{return this.xhr_.status}catch{return-1}}getResponse(){if(!this.sent_)throw _c("cannot .getResponse() before sending");return this.xhr_.response}getErrorText(){if(!this.sent_)throw _c("cannot .getErrorText() before sending");return this.xhr_.statusText}abort(){this.xhr_.abort()}getResponseHeader(e){return this.xhr_.getResponseHeader(e)}addUploadProgressListener(e){this.xhr_.upload!=null&&this.xhr_.upload.addEventListener("progress",e)}removeUploadProgressListener(e){this.xhr_.upload!=null&&this.xhr_.upload.removeEventListener("progress",e)}}class L8 extends M8{initXhr(){this.xhr_.responseType="text"}}function Km(){return new L8}/** 3648 * @license 3649 * Copyright 2019 Google LLC 3650 * 3651 * Licensed under the Apache License, Version 2.0 (the "License"); 3652 * you may not use this file except in compliance with the License. 3653 * You may obtain a copy of the License at 3654 * 3655 * http://www.apache.org/licenses/LICENSE-2.0 3656 * 3657 * Unless required by applicable law or agreed to in writing, software 3658 * distributed under the License is distributed on an "AS IS" BASIS, 3659 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3660 * See the License for the specific language governing permissions and 3661 * limitations under the License. 3662 */let Ym=class Xy{constructor(e,n){this._service=e,n instanceof Yn?this._location=n:this._location=Yn.makeFromUrl(n,e.host)}toString(){return"gs://"+this._location.bucket+"/"+this._location.path}_newRef(e,n){return new Xy(e,n)}get root(){const e=new Yn(this._location.bucket,"");return this._newRef(this._service,e)}get bucket(){return this._location.bucket}get fullPath(){return this._location.path}get name(){return MP(this._location.path)}get storage(){return this._service}get parent(){const e=g8(this._location.path);if(e===null)return null;const n=new Yn(this._location.bucket,e);return new Xy(this._service,n)}_throwIfRoot(e){if(this._location.path==="")throw YU(e)}};function VP(t,e,n){t._throwIfRoot("uploadBytes");const r=D8(t.storage,t._location,LP(),new uo(e,!0),n);return t.storage.makeRequestWithTokens(r,Km).then(i=>({metadata:i,ref:t}))}function j8(t,e,n=ii.RAW,r){t._throwIfRoot("uploadString");const i=RP(n,e),s=Object.assign({},r);return s.contentType==null&&i.contentType!=null&&(s.contentType=i.contentType),VP(t,i.data,s)}function F8(t){const e={prefixes:[],items:[]};return UP(t,e).then(()=>e)}async function UP(t,e,n){const i=await V8(t,{pageToken:n});e.prefixes.push(...i.prefixes),e.items.push(...i.items),i.nextPageToken!=null&&await UP(t,e,i.nextPageToken)}function V8(t,e){e!=null&&typeof e.maxResults=="number"&&Zy("options.maxResults",1,1e3,e.maxResults);const n=e||{},r=O8(t.storage,t._location,"/",n.pageToken,n.maxResults);return t.storage.makeRequestWithTokens(r,Km)}function U8(t){t._throwIfRoot("getDownloadURL");const e=P8(t.storage,t._location,LP());return t.storage.makeRequestWithTokens(e,Km).then(n=>{if(n===null)throw GU();return n})}function $8(t){t._throwIfRoot("deleteObject");const e=R8(t.storage,t._location);return t.storage.makeRequestWithTokens(e,Km)}function B8(t,e){const n=v8(t._location.path,e),r=new Yn(t._location.bucket,n);return new Ym(t.storage,r)}/** 3663 * @license 3664 * Copyright 2017 Google LLC 3665 * 3666 * Licensed under the Apache License, Version 2.0 (the "License"); 3667 * you may not use this file except in compliance with the License. 3668 * You may obtain a copy of the License at 3669 * 3670 * http://www.apache.org/licenses/LICENSE-2.0 3671 * 3672 * Unless required by applicable law or agreed to in writing, software 3673 * distributed under the License is distributed on an "AS IS" BASIS, 3674 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3675 * See the License for the specific language governing permissions and 3676 * limitations under the License. 3677 */function z8(t){return/^[A-Za-z]+:\/\//.test(t)}function q8(t,e){return new Ym(t,e)}function $P(t,e){if(t instanceof G1){const n=t;if(n._bucket==null)throw HU();const r=new Ym(n,n._bucket);return e!=null?$P(r,e):r}else return e!==void 0?B8(t,e):t}function H8(t,e){if(e&&z8(e)){if(t instanceof G1)return q8(t,e);throw Qy("To use ref(service, url), the first argument must be a Storage instance.")}else return $P(t,e)}function gT(t,e){const n=e==null?void 0:e[IP];return n==null?null:Yn.makeFromBucketSpec(n,t)}function W8(t,e,n,r={}){t.host=`${e}:${n}`,t._protocol="http";const{mockUserToken:i}=r;i&&(t._overrideAuthToken=typeof i=="string"?i:KA(i,t.app.options.projectId))}class G1{constructor(e,n,r,i,s){this.app=e,this._authProvider=n,this._appCheckProvider=r,this._url=i,this._firebaseVersion=s,this._bucket=null,this._host=AP,this._protocol="https",this._appId=null,this._deleted=!1,this._maxOperationRetryTime=DU,this._maxUploadRetryTime=MU,this._requests=new Set,i!=null?this._bucket=Yn.makeFromBucketSpec(i,this._host):this._bucket=gT(this._host,this.app.options)}get host(){return this._host}set host(e){this._host=e,this._url!=null?this._bucket=Yn.makeFromBucketSpec(this._url,e):this._bucket=gT(e,this.app.options)}get maxUploadRetryTime(){return this._maxUploadRetryTime}set maxUploadRetryTime(e){Zy("time",0,Number.POSITIVE_INFINITY,e),this._maxUploadRetryTime=e}get maxOperationRetryTime(){return this._maxOperationRetryTime}set maxOperationRetryTime(e){Zy("time",0,Number.POSITIVE_INFINITY,e),this._maxOperationRetryTime=e}async _getAuthToken(){if(this._overrideAuthToken)return this._overrideAuthToken;const e=this._authProvider.getImmediate({optional:!0});if(e){const n=await e.getToken();if(n!==null)return n.accessToken}return null}async _getAppCheckToken(){const e=this._appCheckProvider.getImmediate({optional:!0});
3677return e?(await e.getToken()).token:null}_delete(){return this._deleted||(this._deleted=!0,this._requests.forEach(e=>e.cancel()),this._requests.clear()),Promise.resolve()}_makeStorageReference(e){return new Ym(this,e)}_makeRequest(e,n,r,i,s=!0){if(this._deleted)return new QU(OP());{const o=a8(e,this._appId,r,i,n,this._firebaseVersion,s);return this._requests.add(o),o.getPromise().then(()=>this._requests.delete(o),()=>this._requests.delete(o)),o}}async makeRequestWithTokens(e,n){const[r,i]=await Promise.all([this._getAuthToken(),this._getAppCheckToken()]);return this._makeRequest(e,n,r,i).getPromise()}}const vT="@firebase/storage",yT="0.13.2";/** 3678 * @license 3679 * Copyright 2020 Google LLC 3680 * 3681 * Licensed under the Apache License, Version 2.0 (the "License"); 3682 * you may not use this file except in compliance with the License. 3683 * You may obtain a copy of the License at 3684 * 3685 * http://www.apache.org/licenses/LICENSE-2.0 3686 * 3687 * Unless required by applicable law or agreed to in writing, software 3688 * distributed under the License is distributed on an "AS IS" BASIS, 3689 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 3690 * See the License for the specific language governing permissions and 3691 * limitations under the License. 3692 */const BP="storage";function _T(t,e,n){return t=Ot(t),VP(t,e,n)}function wT(t,e,n,r){return t=Ot(t),j8(t,e,n,r)}function G8(t){return t=Ot(t),F8(t)}function Cf(t){return t=Ot(t),U8(t)}function bT(t){return t=Ot(t),$8(t)}function Wo(t,e){return t=Ot(t),H8(t,e)}function K8(t=km(),e){t=Ot(t);const r=Jo(t,BP).getImmediate({identifier:e}),i=HA("storage");return i&&Y8(r,...i),r}function Y8(t,e,n,r={}){W8(t,e,n,r)}function Q8(t,{instanceIdentifier:e}){const n=t.getProvider("app").getImmediate(),r=t.getProvider("auth-internal"),i=t.getProvider("app-check-internal");return new G1(n,r,i,e,al)}function Z8(){fi(new zr(BP,Q8,"PUBLIC").setMultipleInstances(!0)),dr(vT,yT,""),dr(vT,yT,"esm2017")}Z8();const X8={apiKey:"AIzaSyDOi7NvFdWJgP_9Wun-bRg7D4VFI_1jTYA",authDomain:"skfm-479ab.firebaseapp.com",projectId:"skfm-479ab",storageBucket:"skfm-479ab.appspot.com",messagingSenderId:"593647084359",appId:"1:593647084359:web:ac6e3bf0b2150a0400e262",measurementId:"G-GNK304QNX2"},K1=tI(X8);I5(K1);const Y1=gU(K1),gv=uF(K1),Go=K8();O1(Y1,"users");const Ql=O1(Y1,"conferences"),hi=O1(Y1,"articles");/*! ***************************************************************************** 3693Copyright (c) Microsoft Corporation. 3694 3695Permission to use, copy, modify, and/or distribute this software for any 3696purpose with or without fee is hereby granted. 3697 3698THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH 3699REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 3700AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, 3701INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 3702LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 3703OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 3704PERFORMANCE OF THIS SOFTWARE. 3705***************************************************************************** */function J8(t,e,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function a(c){try{u(r.next(c))}catch(d){o(d)}}function l(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(a,l)}u((r=r.apply(t,[])).next())})}function e7(t,e){var n={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(u){return function(c){return l([u,c])}}function l(u){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,i&&(s=u[0]&2?i.return:u[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,u[1])).done)return s;switch(i=0,s&&(u=[u[0]&2,s.value]),u[0]){case 0:case 1:s=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(s=n.trys,!(s=s.length>0&&s[s.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!s||u[1]>s[0]&&u[1]<s[3])){n.label=u[1];break}if(u[0]===6&&n.label<s[1]){n.label=s[1],s=u;break}if(s&&n.label<s[2]){n.label=s[2],n.ops.push(u);break}s[2]&&n.ops.pop(),n.trys.pop();continue}u=e.call(t,n)}catch(c){u=[6,c],i=0}finally{r=s=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}/*! ***************************************************************************** 3706Copyright (c) Microsoft Corporation. 3707 3708Permission to use, copy, modify, and/or distribute this software for any 3709purpose with or without fee is hereby granted. 3710 3711THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH 3712REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 3713AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, 3714INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 3715LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 3716OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 3717PERFORMANCE OF THIS SOFTWARE. 3718***************************************************************************** */var jl=function(){return jl=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e},jl.apply(this,arguments)},zP=function(t){return{loading:t==null,value:t}},t7=function(){return function(t,e){switch(e.type){case"error":return jl(jl({},t),{error:e.error,loading:!1,value:void 0});case"reset":return zP(e.defaultValue);case"value":return jl(jl({},t),{error:void 0,loading:!1,value:e.value});default:return t}}},n7=function(t){var e=t?t():void 0,n=H.useReducer(t7(),zP(e)),r=n[0],i=n[1],s=H.useCallback(function(){var l=t?t():void 0;i({type:"reset",defaultValue:l})},[t]),o=H.useCallback(function(l){i({type:"error",error:l})},[]),a=H.useCallback(function(l){i({type:"value",value:l})},[]);return H.useMemo(function(){return{error:r.error,loading:r.loading,reset:s,setError:o,setValue:a,value:r.value}},[r.error,r.loading,s,o,a,r.value])},r7=function(t,e){var n=n7(function(){return t.currentUser}),r=n.error,i=n.loading,s=n.setError,o=n.setValue,a=n.value;return H.useEffect(function(){var l=Z6(t,function(u){return J8(void 0,void 0,void 0,function(){var c;return e7(this,function(d){switch(d.label){case 0:if(!(e!=null&&e.onUserChanged))return[3,4];d.label=1;case 1:return d.trys.push([1,3,,4]),[4,e.onUserChanged(u)];case 2:return d.sent(),[3,4];case 3:return c=d.sent(),s(c),[3,4];case 4:return o(u),[2]}})})},s);return function(){l()}},[t]),[a,i,r]};//! moment.js 3719//! version : 2.30.1 3720//! authors : Tim Wood, Iskren Chernev, Moment.js contributors 3721//! license : MIT 3722//! momentjs.com 3723var qP;function ve(){return qP.apply(null,arguments)}function i7(t){qP=t}function pi(t){return t instanceof Array||Object.prototype.toString.call(t)==="[object Array]"}function $a(t){return t!=null&&Object.prototype.toString.call(t)==="[object Object]"}function mt(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Q1(t){if(Object.getOwnPropertyNames)return Object.getOwnPropertyNames(t).length===0;var e;
vendor: 15,052 bytes, lines 3723-3726
3723for(e in t)if(mt(t,e))return!1;return!0}function nr(t){return t===void 0}function Ls(t){return typeof t=="number"||Object.prototype.toString.call(t)==="[object Number]"}function pd(t){return t instanceof Date||Object.prototype.toString.call(t)==="[object Date]"}function HP(t,e){var n=[],r,i=t.length;for(r=0;r<i;++r)n.push(e(t[r],r));return n}function To(t,e){for(var n in e)mt(e,n)&&(t[n]=e[n]);return mt(e,"toString")&&(t.toString=e.toString),mt(e,"valueOf")&&(t.valueOf=e.valueOf),t}function Bi(t,e,n,r){return pR(t,e,n,r,!0).utc()}function s7(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function Qe(t){return t._pf==null&&(t._pf=s7()),t._pf}var Jy;Array.prototype.some?Jy=Array.prototype.some:Jy=function(t){var e=Object(this),n=e.length>>>0,r;for(r=0;r<n;r++)if(r in e&&t.call(this,e[r],r,e))return!0;return!1};function Z1(t){var e=null,n=!1,r=t._d&&!isNaN(t._d.getTime());if(r&&(e=Qe(t),n=Jy.call(e.parsedDateParts,function(i){return i!=null}),r=e.overflow<0&&!e.empty&&!e.invalidEra&&!e.invalidMonth&&!e.invalidWeekday&&!e.weekdayMismatch&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated&&(!e.meridiem||e.meridiem&&n),t._strict&&(r=r&&e.charsLeftOver===0&&e.unusedTokens.length===0&&e.bigHour===void 0)),Object.isFrozen==null||!Object.isFrozen(t))t._isValid=r;else return r;return t._isValid}function Qm(t){var e=Bi(NaN);return t!=null?To(Qe(e),t):Qe(e).userInvalidated=!0,e}var ET=ve.momentProperties=[],vv=!1;function X1(t,e){var n,r,i,s=ET.length;if(nr(e._isAMomentObject)||(t._isAMomentObject=e._isAMomentObject),nr(e._i)||(t._i=e._i),nr(e._f)||(t._f=e._f),nr(e._l)||(t._l=e._l),nr(e._strict)||(t._strict=e._strict),nr(e._tzm)||(t._tzm=e._tzm),nr(e._isUTC)||(t._isUTC=e._isUTC),nr(e._offset)||(t._offset=e._offset),nr(e._pf)||(t._pf=Qe(e)),nr(e._locale)||(t._locale=e._locale),s>0)for(n=0;n<s;n++)r=ET[n],i=e[r],nr(i)||(t[r]=i);return t}function md(t){X1(this,t),this._d=new Date(t._d!=null?t._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),vv===!1&&(vv=!0,ve.updateOffset(this),vv=!1)}function mi(t){return t instanceof md||t!=null&&t._isAMomentObject!=null}function WP(t){ve.suppressDeprecationWarnings===!1&&typeof console<"u"&&console.warn&&console.warn("Deprecation warning: "+t)}function Hr(t,e){var n=!0;return To(function(){if(ve.deprecationHandler!=null&&ve.deprecationHandler(null,t),n){var r=[],i,s,o,a=arguments.length;for(s=0;s<a;s++){if(i="",typeof arguments[s]=="object"){i+=` 3724[`+s+"] ";for(o in arguments[0])mt(arguments[0],o)&&(i+=o+": "+arguments[0][o]+", ");i=i.slice(0,-2)}else i=arguments[s];r.push(i)}WP(t+` 3725Arguments: `+Array.prototype.slice.call(r).join("")+` 3726`+new Error().stack),n=!1}return e.apply(this,arguments)},e)}var xT={};function GP(t,e){ve.deprecationHandler!=null&&ve.deprecationHandler(t,e),xT[t]||(WP(e),xT[t]=!0)}ve.suppressDeprecationWarnings=!1;ve.deprecationHandler=null;function zi(t){return typeof Function<"u"&&t instanceof Function||Object.prototype.toString.call(t)==="[object Function]"}function o7(t){var e,n;for(n in t)mt(t,n)&&(e=t[n],zi(e)?this[n]=e:this["_"+n]=e);this._config=t,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function e0(t,e){var n=To({},t),r;for(r in e)mt(e,r)&&($a(t[r])&&$a(e[r])?(n[r]={},To(n[r],t[r]),To(n[r],e[r])):e[r]!=null?n[r]=e[r]:delete n[r]);for(r in t)mt(t,r)&&!mt(e,r)&&$a(t[r])&&(n[r]=To({},n[r]));return n}function J1(t){t!=null&&this.set(t)}var t0;Object.keys?t0=Object.keys:t0=function(t){var e,n=[];for(e in t)mt(t,e)&&n.push(e);return n};var a7={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function l7(t,e,n){var r=this._calendar[t]||this._calendar.sameElse;return zi(r)?r.call(e,n):r}function Ui(t,e,n){var r=""+Math.abs(t),i=e-r.length,s=t>=0;return(s?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}var ew=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,sh=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,yv={},Zl={};function Me(t,e,n,r){var i=r;typeof r=="string"&&(i=function(){return this[r]()}),t&&(Zl[t]=i),e&&(Zl[e[0]]=function(){return Ui(i.apply(this,arguments),e[1],e[2])}),n&&(Zl[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function u7(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function c7(t){var e=t.match(ew),n,r;for(n=0,r=e.length;n<r;n++)Zl[e[n]]?e[n]=Zl[e[n]]:e[n]=u7(e[n]);return function(i){var s="",o;for(o=0;o<r;o++)s+=zi(e[o])?e[o].call(i,t):e[o];return s}}function Lh(t,e){return t.isValid()?(e=KP(e,t.localeData()),yv[e]=yv[e]||c7(e),yv[e](t)):t.localeData().invalidDate()}function KP(t,e){var n=5;function r(i){return e.longDateFormat(i)||i}for(sh.lastIndex=0;n>=0&&sh.test(t);)t=t.replace(sh,r),sh.lastIndex=0,n-=1;return t}var f7={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};function d7(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.match(ew).map(function(r){return r==="MMMM"||r==="MM"||r==="DD"||r==="dddd"?r.slice(1):r}).join(""),this._longDateFormat[t])}var h7="Invalid date";function p7(){return this._invalidDate}var m7="%d",g7=/\d{1,2}/;function v7(t){return this._ordinal.replace("%d",t)}var y7={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function _7(t,e,n,r){var i=this._relativeTime[n];return zi(i)?i(t,e,n,r):i.replace(/%d/i,t)}function w7(t,e){var n=this._relativeTime[t>0?"future":"past"];return zi(n)?n(e):n.replace(/%s/i,e)}var TT={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function Wr(t){return typeof t=="string"?TT[t]||TT[t.toLowerCase()]:void 0}function tw(t){var e={},n,r;for(r in t)mt(t,r)&&(n=Wr(r),n&&(e[n]=t[r]));return e}var b7={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function E7(t){var e=[],n;for(n in t)mt(t,n)&&e.push({unit:n,priority:b7[n]});return e.sort(function(r,i){return r.priority-i.priority}),e}var YP=/\d/,Rr=/\d\d/,QP=/\d{3}/,nw=/\d{4}/,Zm=/[+-]?\d{6}/,Vt=/\d\d?/,ZP=/\d\d\d\d?/,XP=/\d\d\d\d\d\d?/,Xm=/\d{1,3}/,rw=/\d{1,4}/,Jm=/[+-]?\d{1,6}/,$u=/\d+/,eg=/[+-]?\d+/,x7=/Z|[+-]\d\d:?\d\d/gi,tg=/Z|[+-]\d\d(?::?\d\d)?/gi,T7=/[+-]?\d+(\.\d{1,3})?/,gd=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Bu=/^[1-9]\d?/,iw=/^([1-9]\d|\d)/,jp;jp={};function Te(t,e,n){jp[t]=zi(e)?e:function(r,i){return r&&n?n:e}}function S7(t,e){return mt(jp,t)?jp[t](e._strict,e._locale):new RegExp(k7(t))}function k7(t){return Es(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,n,r,i,s){return n||r||i||s}))}function Es(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function jr(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function it(t){var e=+t,n=0;return e!==0&&isFinite(e)&&(n=jr(e)),n}var n0={};function xt(t,e){var n,r=e,i;for(typeof t=="string"&&(t=[t]),Ls(e)&&(r=function(s,o){o[e]=it(s)}),i=t.length,n=0;n<i;n++)n0[t[n]]=r}function vd(t,e){xt(t,function(n,r,i,s){i._w=i._w||{},e(n,i._w,i,s)})}function A7(t,e,n){e!=null&&mt(n0,t)&&n0[t](e,n._a,n,t)}function ng(t){return t%4===0&&t%100!==0||t%400===0}var jn=0,vs=1,Ri=2,hn=3,si=4,ys=5,Ta=6,I7=7,O7=8;Me("Y",0,0,function(){var t=this.year();return t<=9999?Ui(t,4):"+"+t});Me(0,["YY",2],0,function(){return this.year()%100});Me(0,["YYYY",4],0,"year");Me(0,["YYYYY",5],0,"year");Me(0,["YYYYYY",6,!0],0,"year");Te("Y",eg);Te("YY",Vt,Rr);Te("YYYY",rw,nw);Te("YYYYY",Jm,Zm);Te("YYYYYY",Jm,Zm);xt(["YYYYY","YYYYYY"],jn);xt("YYYY",function(t,e){e[jn]=t.length===2?ve.parseTwoDigitYear(t):it(t)});xt("YY",function(t,e){e[jn]=ve.parseTwoDigitYear(t)});xt("Y",function(t,e){e[jn]=parseInt(t,10)});function Xc(t){return ng(t)?366:365}ve.parseTwoDigitYear=function(t){return it(t)+(it(t)>68?1900:2e3)};var JP=zu("FullYear",!0);function P7(){return ng(this.year())}function zu(t,e){return function(n){return n!=null?(eR(this,t,n),ve.updateOffset(this,e),this):Nf(this,t)}}function Nf(t,e){if(!t.isValid())return NaN;var n=t._d,r=t._isUTC;switch(e){case"Milliseconds":return r?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return r?n.getUTCSeconds():n.getSeconds();case"Minutes":return r?n.getUTCMinutes():n.getMinutes();case"Hours":return r?n.getUTCHours():n.getHours();case"Date":return r?n.getUTCDate():n.getDate();case"Day":return r?n.getUTCDay():n.getDay();case"Month":return r?n.getUTCMonth():n.getMonth();case"FullYear":return r?n.getUTCFullYear():n.getFullYear();default:return NaN}}function eR(t,e,n){var r,i,s,o,a;if(!(!t.isValid()||isNaN(n))){switch(r=t._d,i=t._isUTC,e){case"Milliseconds":return void(i?r.setUTCMilliseconds(n):r.setMilliseconds(n));case"Seconds":return void(i?r.setUTCSeconds(n):r.setSeconds(n));case"Minutes":return void(i?r.setUTCMinutes(n):r.setMinutes(n));case"Hours":return void(i?r.setUTCHours(n):r.setHours(n));case"Date":return void(i?r.setUTCDate(n):r.setDate(n));case"FullYear":break;default:return}s=n,o=t.month(),a=t.date(),a=a===29&&o===1&&!ng(s)?28:a,i?r.setUTCFullYear(s,o,a):r.setFullYear(s,o,a)}}function R7(t){return t=Wr(t),zi(this[t])?this[t]():this}function C7(t,e){if(typeof t=="object"){t=tw(t);var n=E7(t),r,i=n.length;for(r=0;r<i;r++)this[n[r].unit](t[n[r].unit])}else if(t=Wr(t),zi(this[t]))return this[t](e);return this}function N7(t,e){return(t%e+e)%e}var en;Array.prototype.indexOf?en=Array.prototype.indexOf:en=function(t){var e;for(e=0;e<this.length;++e)if(this[e]===t)return e;return-1};function sw(t,e){if(isNaN(t)||isNaN(e))return NaN;var n=N7(e,12);return t+=(e-n)/12,n===1?ng(t)?29:28:31-n%7%2}Me("M",["MM",2],"Mo",function(){return this.month()+1});Me("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)});Me("MMMM",0,0,function(t){return this.localeData().months(this,t)});Te("M",Vt,Bu);Te("MM",Vt,Rr);Te("MMM",function(t,e){return e.monthsShortRegex(t)});Te("MMMM",function(t,e){return e.monthsRegex(t)});xt(["M","MM"],function(t,e){e[vs]=it(t)-1});xt(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);i!=null?e[vs]=i:Qe(n).invalidMonth=t});var D7="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),tR="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),nR=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,M7=gd,L7=gd;function j7(t,e){return t?pi(this._months)?this._months[t.month()]:this._months[(this._months.isFormat||nR).test(e)?"format":"standalone"][t.month()]:pi(this._months)?this._months:this._months.standalone}function F7(t,e){return t?pi(this._monthsShort)?this._monthsShort[t.month()]:this._monthsShort[nR.test(e)?"format":"standalone"][t.month()]:pi(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function V7(t,e,n){var r,i,s,o=t.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)s=Bi([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(s,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(s,"").toLocaleLowerCase();return n?e==="MMM"?(i=en.call(this._shortMonthsParse,o),i!==-1?i:null):(i=en.call(this._longMonthsParse,o),i!==-1?i:null):e==="MMM"?(i=en.call(this._shortMonthsParse,o),i!==-1?i:(i=en.call(this._longMonthsParse,o),i!==-1?i:null)):(i=en.call(this._longMonthsParse,o),i!==-1?i:(i=en.call(this._shortMonthsParse,o),i!==-1?i:null))}function U7(t,e,n){var r,i,s;if(this._monthsParseExact)return V7.call(this,t,e,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(i=Bi([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),!n&&!this._monthsParse[r]&&(s="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(s.replace(".",""),"i")),n&&e==="MMMM"&&this._longMonthsParse[r].test(t))return r;if(n&&e==="MMM"&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function rR(t,e){if(!t.isValid())return t;if(typeof e=="string"){if(/^\d+$/.test(e))e=it(e);else if(e=t.localeData().monthsParse(e),!Ls(e))return t}var n=e,r=t.date();return r=r<29?r:Math.min(r,sw(t.year(),n)),t._isUTC?t._d.setUTCMonth(n,r):t._d.setMonth(n,r),t}function iR(t){return t!=null?(rR(this,t),ve.updateOffset(this,!0),this):Nf(this,"Month")}function $7(){return sw(this.year(),this.month())}function B7(t){return this._monthsParseExact?(mt(this,"_monthsRegex")||sR.call(this),t?this._monthsShortStrictRegex:this._monthsShortRegex):(mt(this,"_monthsShortRegex")||(this._monthsShortRegex=M7),this._monthsShortStrictRegex&&t?this._monthsShortStrictRegex:this._monthsShortRegex)}function z7(t){return this._monthsParseExact?(mt(this,"_monthsRegex")||sR.call(this),t?this._monthsStrictRegex:this._monthsRegex):(mt(this,"_monthsRegex")||(this._monthsRegex=L7),this._monthsStrictRegex&&t?this._monthsStrictRegex:this._monthsRegex)}function sR(){function t(l,u){return u.length-l.length}var e=[],n=[],r=[],i,s,o,a;for(i=0;i<12;i++)s=Bi([2e3,i]),o=Es(this.monthsShort(s,"")),a=Es(this.months(s,"")),e.push(o),n.push(a),r.push(a),r.push(o);e.sort(t),n.sort(t),r.sort(t),this._monthsRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+e.join("|")+")","i")}function q7(t,e,n,r,i,s,o){var a;return t<100&&t>=0?(a=new Date(t+400,e,n,r,i,s,o),isFinite(a.getFullYear())&&a.setFullYear(t)):a=new Date(t,e,n,r,i,s,o),a}function Df(t){var e,n;return t<100&&t>
3726=0?(n=Array.prototype.slice.call(arguments),n[0]=t+400,e=new Date(Date.UTC.apply(null,n)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)):e=new Date(Date.UTC.apply(null,arguments)),e}function Fp(t,e,n){var r=7+e-n,i=(7+Df(t,0,r).getUTCDay()-e)%7;return-i+r-1}function oR(t,e,n,r,i){var s=(7+n-r)%7,o=Fp(t,r,i),a=1+7*(e-1)+s+o,l,u;return a<=0?(l=t-1,u=Xc(l)+a):a>Xc(t)?(l=t+1,u=a-Xc(t)):(l=t,u=a),{year:l,dayOfYear:u}}function Mf(t,e,n){var r=Fp(t.year(),e,n),i=Math.floor((t.dayOfYear()-r-1)/7)+1,s,o;return i<1?(o=t.year()-1,s=i+xs(o,e,n)):i>xs(t.year(),e,n)?(s=i-xs(t.year(),e,n),o=t.year()+1):(o=t.year(),s=i),{week:s,year:o}}function xs(t,e,n){var r=Fp(t,e,n),i=Fp(t+1,e,n);return(Xc(t)-r+i)/7}Me("w",["ww",2],"wo","week");Me("W",["WW",2],"Wo","isoWeek");Te("w",Vt,Bu);Te("ww",Vt,Rr);Te("W",Vt,Bu);Te("WW",Vt,Rr);vd(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=it(t)});function H7(t){return Mf(t,this._week.dow,this._week.doy).week}var W7={dow:0,doy:6};function G7(){return this._week.dow}function K7(){return this._week.doy}function Y7(t){var e=this.localeData().week(this);return t==null?e:this.add((t-e)*7,"d")}function Q7(t){var e=Mf(this,1,4).week;return t==null?e:this.add((t-e)*7,"d")}Me("d",0,"do","day");Me("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)});Me("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)});Me("dddd",0,0,function(t){return this.localeData().weekdays(this,t)});Me("e",0,0,"weekday");Me("E",0,0,"isoWeekday");Te("d",Vt);Te("e",Vt);Te("E",Vt);Te("dd",function(t,e){return e.weekdaysMinRegex(t)});Te("ddd",function(t,e){return e.weekdaysShortRegex(t)});Te("dddd",function(t,e){return e.weekdaysRegex(t)});vd(["dd","ddd","dddd"],function(t,e,n,r){var i=n._locale.weekdaysParse(t,r,n._strict);i!=null?e.d=i:Qe(n).invalidWeekday=t});vd(["d","e","E"],function(t,e,n,r){e[r]=it(t)});function Z7(t,e){return typeof t!="string"?t:isNaN(t)?(t=e.weekdaysParse(t),t
vendor: 4,951 bytes, line 3726
3726ypeof t=="number"?t:null):parseInt(t,10)}function X7(t,e){return typeof t=="string"?e.weekdaysParse(t)%7||7:isNaN(t)?null:t}function ow(t,e){return t.slice(e,7).concat(t.slice(0,e))}var J7="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),aR="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),e$="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),t$=gd,n$=gd,r$=gd;function i$(t,e){var n=pi(this._weekdays)?this._weekdays:this._weekdays[t&&t!==!0&&this._weekdays.isFormat.test(e)?"format":"standalone"];return t===!0?ow(n,this._week.dow):t?n[t.day()]:n}function s$(t){return t===!0?ow(this._weekdaysShort,this._week.dow):t?this._weekdaysShort[t.day()]:this._weekdaysShort}function o$(t){return t===!0?ow(this._weekdaysMin,this._week.dow):t?this._weekdaysMin[t.day()]:this._weekdaysMin}function a$(t,e,n){var r,i,s,o=t.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)s=Bi([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(s,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(s,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(s,"").toLocaleLowerCase();return n?e==="dddd"?(i=en.call(this._weekdaysParse,o),i!==-1?i:null):e==="ddd"?(i=en.call(this._shortWeekdaysParse,o),i!==-1?i:null):(i=en.call(this._minWeekdaysParse,o),i!==-1?i:null):e==="dddd"?(i=en.call(this._weekdaysParse,o),i!==-1||(i=en.call(this._shortWeekdaysParse,o),i!==-1)?i:(i=en.call(this._minWeekdaysParse,o),i!==-1?i:null)):e==="ddd"?(i=en.call(this._shortWeekdaysParse,o),i!==-1||(i=en.call(this._weekdaysParse,o),i!==-1)?i:(i=en.call(this._minWeekdaysParse,o),i!==-1?i:null)):(i=en.call(this._minWeekdaysParse,o),i!==-1||(i=en.call(this._weekdaysParse,o),i!==-1)?i:(i=en.call(this._shortWeekdaysParse,o),i!==-1?i:null))}function l$(t,e,n){var r,i,s;if(this._weekdaysParseExact)return a$.call(this,t,e,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(i=Bi([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(s="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(s.replace(".",""),"i")),n&&e==="dddd"&&this._fullWeekdaysParse[r].test(t))return r;if(n&&e==="ddd"&&this._shortWeekdaysParse[r].test(t))return r;if(n&&e==="dd"&&this._minWeekdaysParse[r].test(t))return r;if(!n&&this._weekdaysParse[r].test(t))return r}}function u$(t){if(!this.isValid())return t!=null?this:NaN;var e=Nf(this,"Day");return t!=null?(t=Z7(t,this.localeData()),this.add(t-e,"d")):e}function c$(t){if(!this.isValid())return t!=null?this:NaN;var e=(this.day()+7-this.localeData()._week.dow)%7;return t==null?e:this.add(t-e,"d")}function f$(t){if(!this.isValid())return t!=null?this:NaN;if(t!=null){var e=X7(t,this.localeData());return this.day(this.day()%7?e:e-7)}else return this.day()||7}function d$(t){return this._weekdaysParseExact?(mt(this,"_weekdaysRegex")||aw.call(this),t?this._weekdaysStrictRegex:this._weekdaysRegex):(mt(this,"_weekdaysRegex")||(this._weekdaysRegex=t$),this._weekdaysStrictRegex&&t?this._weekdaysStrictRegex:this._weekdaysRegex)}function h$(t){return this._weekdaysParseExact?(mt(this,"_weekdaysRegex")||aw.call(this),t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(mt(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=n$),this._weekdaysShortStrictRegex&&t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function p$(t){return this._weekdaysParseExact?(mt(this,"_weekdaysRegex")||aw.call(this),t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(mt(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=r$),this._weekdaysMinStrictRegex&&t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function aw(){function t(c,d){return d.length-c.length}var e=[],n=[],r=[],i=[],s,o,a,l,u;for(s=0;s<7;s++)o=Bi([2e3,1]).day(s),a=Es(this.weekdaysMin(o,"")),l=Es(this.weekdaysShort(o,"")),u=Es(this.weekdays(o,"")),e.push(a),n.push(l),r.push(u),i.push(a),i.push(l),i.push(u);e.sort(t),n.sort(t),r.sort(t),i.sort(t),this._weekdaysRegex=new RegExp("^("+i.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+r.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+e.join("|")+")","i")}function lw(){return this.hours()%12||12}function m$(){return this.hours()||24}Me("H",["HH",2],0,"hour");Me("h",["hh",2],0,lw);Me("k",["kk",2],0,m$);Me("hmm",0,0,function(){return""+lw.apply(this)+Ui(this.minutes(),2)}
vendor: 18,062 bytes, line 3726
3726);Me("hmmss",0,0,function(){return""+lw.apply(this)+Ui(this.minutes(),2)+Ui(this.seconds(),2)});Me("Hmm",0,0,function(){return""+this.hours()+Ui(this.minutes(),2)});Me("Hmmss",0,0,function(){return""+this.hours()+Ui(this.minutes(),2)+Ui(this.seconds(),2)});function lR(t,e){Me(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}lR("a",!0);lR("A",!1);function uR(t,e){return e._meridiemParse}Te("a",uR);Te("A",uR);Te("H",Vt,iw);Te("h",Vt,Bu);Te("k",Vt,Bu);Te("HH",Vt,Rr);Te("hh",Vt,Rr);Te("kk",Vt,Rr);Te("hmm",ZP);Te("hmmss",XP);Te("Hmm",ZP);Te("Hmmss",XP);xt(["H","HH"],hn);xt(["k","kk"],function(t,e,n){var r=it(t);e[hn]=r===24?0:r});xt(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t});xt(["h","hh"],function(t,e,n){e[hn]=it(t),Qe(n).bigHour=!0});xt("hmm",function(t,e,n){var r=t.length-2;e[hn]=it(t.substr(0,r)),e[si]=it(t.substr(r)),Qe(n).bigHour=!0});xt("hmmss",function(t,e,n){var r=t.length-4,i=t.length-2;e[hn]=it(t.substr(0,r)),e[si]=it(t.substr(r,2)),e[ys]=it(t.substr(i)),Qe(n).bigHour=!0});xt("Hmm",function(t,e,n){var r=t.length-2;e[hn]=it(t.substr(0,r)),e[si]=it(t.substr(r))});xt("Hmmss",function(t,e,n){var r=t.length-4,i=t.length-2;e[hn]=it(t.substr(0,r)),e[si]=it(t.substr(r,2)),e[ys]=it(t.substr(i))});function g$(t){return(t+"").toLowerCase().charAt(0)==="p"}var v$=/[ap]\.?m?\.?/i,y$=zu("Hours",!0);function _$(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}var cR={calendar:a7,longDateFormat:f7,invalidDate:h7,ordinal:m7,dayOfMonthOrdinalParse:g7,relativeTime:y7,months:D7,monthsShort:tR,week:W7,weekdays:J7,weekdaysMin:e$,weekdaysShort:aR,meridiemParse:v$},Bt={},wc={},Lf;function w$(t,e){var n,r=Math.min(t.length,e.length);for(n=0;n<r;n+=1)if(t[n]!==e[n])return n;return r}function ST(t){return t&&t.toLowerCase().replace("_","-")}function b$(t){for(var e=0,n,r,i,s;e<t.length;){for(s=ST(t[e]).split("-"),n=s.length,r=ST(t[e+1]),r=r?r.split("-"):null;n>0;){if(i=rg(s.slice(0,n).join("-")),i)return i;if(r&&r.length>=n&&w$(s,r)>=n-1)break;n--}e++}return Lf}function E$(t){return!!(t&&t.match("^[^/\\\\]*$"))}function rg(t){var e=null,n;if(Bt[t]===void 0&&typeof qh<"u"&&qh&&qh.exports&&E$(t))try{e=Lf._abbr,n=require,n("./locale/"+t),Fo(e)}catch{Bt[t]=null}return Bt[t]}function Fo(t,e){var n;return t&&(nr(e)?n=Vs(t):n=uw(t,e),n?Lf=n:typeof console<"u"&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),Lf._abbr}function uw(t,e){if(e!==null){var n,r=cR;if(e.abbr=t,Bt[t]!=null)GP("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=Bt[t]._config;else if(e.parentLocale!=null)if(Bt[e.parentLocale]!=null)r=Bt[e.parentLocale]._config;else if(n=rg(e.parentLocale),n!=null)r=n._config;else return wc[e.parentLocale]||(wc[e.parentLocale]=[]),wc[e.parentLocale].push({name:t,config:e}),null;return Bt[t]=new J1(e0(r,e)),wc[t]&&wc[t].forEach(function(i){uw(i.name,i.config)}),Fo(t),Bt[t]}else return delete Bt[t],null}function x$(t,e){if(e!=null){var n,r,i=cR;Bt[t]!=null&&Bt[t].parentLocale!=null?Bt[t].set(e0(Bt[t]._config,e)):(r=rg(t),r!=null&&(i=r._config),e=e0(i,e),r==null&&(e.abbr=t),n=new J1(e),n.parentLocale=Bt[t],Bt[t]=n),Fo(t)}else Bt[t]!=null&&(Bt[t].parentLocale!=null?(Bt[t]=Bt[t].parentLocale,t===Fo()&&Fo(t)):Bt[t]!=null&&delete Bt[t]);return Bt[t]}function Vs(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Lf;if(!pi(t)){if(e=rg(t),e)return e;t=[t]}return b$(t)}function T$(){return t0(Bt)}function cw(t){var e,n=t._a;return n&&Qe(t).overflow===-2&&(e=n[vs]<0||n[vs]>11?vs:n[Ri]<1||n[Ri]>sw(n[jn],n[vs])?Ri:n[hn]<0||n[hn]>24||n[hn]===24&&(n[si]!==0||n[ys]!==0||n[Ta]!==0)?hn:n[si]<0||n[si]>59?si:n[ys]<0||n[ys]>59?ys:n[Ta]<0||n[Ta]>999?Ta:-1,Qe(t)._overflowDayOfYear&&(e<jn||e>Ri)&&(e=Ri),Qe(t)._overflowWeeks&&e===-1&&(e=I7),Qe(t)._overflowWeekday&&e===-1&&(e=O7),Qe(t).overflow=e),t}var S$=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,k$=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,A$=/Z|[+-]\d\d(?::?\d\d)?/,oh=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],_v=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],I$=/^\/?Date\((-?\d+)/i,O$=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,P$={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function fR(t){var e,n,r=t._i,i=S$.exec(r)||k$.exec(r),s,o,a,l,u=oh.length,c=_v.length;if(i){for(Qe(t).iso=!0,e=0,n=u;e<n;e++)if(oh[e][1].exec(i[1])){o=oh[e][0],s=oh[e][2]!==!1;break}if(o==null){t._isValid=!1;return}if(i[3]){for(e=0,n=c;e<n;e++)if(_v[e][1].exec(i[3])){a=(i[2]||" ")+_v[e][0];break}if(a==null){t._isValid=!1;return}}if(!s&&a!=null){t._isValid=!1;return}if(i[4])if(A$.exec(i[4]))l="Z";else{t._isValid=!1;return}t._f=o+(a||"")+(l||""),dw(t)}else t._isValid=!1}function R$(t,e,n,r,i,s){var o=[C$(t),tR.indexOf(e),parseInt(n,10),parseInt(r,10),parseInt(i,10)];return s&&o.push(parseInt(s,10)),o}function C$(t){var e=parseInt(t,10);return e<=49?2e3+e:e<=999?1900+e:e}function N$(t){return t.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function D$(t,e,n){if(t){var r=aR.indexOf(t),i=new Date(e[0],e[1],e[2]).getDay();if(r!==i)return Qe(n).weekdayMismatch=!0,n._isValid=!1,!1}return!0}function M$(t,e,n){if(t)return P$[t];if(e)return 0;var r=parseInt(n,10),i=r%100,s=(r-i)/100;return s*60+i}function dR(t){var e=O$.exec(N$(t._i)),n;if(e){if(n=R$(e[4],e[3],e[2],e[5],e[6],e[7]),!D$(e[1],n,t))return;t._a=n,t._tzm=M$(e[8],e[9],e[10]),t._d=Df.apply(null,t._a),t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),Qe(t).rfc2822=!0}else t._isValid=!1}function L$(t){var e=I$.exec(t._i);if(e!==null){t._d=new Date(+e[1]);return}if(fR(t),t._isValid===!1)delete t._isValid;else return;if(dR(t),t._isValid===!1)delete t._isValid;else return;t._strict?t._isValid=!1:ve.createFromInputFallback(t)}ve.createFromInputFallback=Hr("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))});function Tl(t,e,n){return t??e??n}function j$(t){var e=new Date(ve.now());return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function fw(t){var e,n,r=[],i,s,o;if(!t._d){for(i=j$(t),t._w&&t._a[Ri]==null&&t._a[vs]==null&&F$(t),t._dayOfYear!=null&&(o=Tl(t._a[jn],i[jn]),(t._dayOfYear>Xc(o)||t._dayOfYear===0)&&(Qe(t)._overflowDayOfYear=!0),n=Df(o,0,t._dayOfYear),t._a[vs]=n.getUTCMonth(),t._a[Ri]=n.getUTCDate()),e=0;e<3&&t._a[e]==null;++e)t._a[e]=r[e]=i[e];for(;e<7;e++)t._a[e]=r[e]=t._a[e]==null?e===2?1:0:t._a[e];t._a[hn]===24&&t._a[si]===0&&t._a[ys]===0&&t._a[Ta]===0&&(t._nextDay=!0,t._a[hn]=0),t._d=(t._useUTC?Df:q7).apply(null,r),s=t._useUTC?t._d.getUTCDay():t._d.getDay(),t._tzm!=null&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hn]=24),t._w&&typeof t._w.d<"u"&&t._w.d!==s&&(Qe(t).weekdayMismatch=!0)}}function F$(t){var e,n,r,i,s,o,a,l,u;e=t._w,e.GG!=null||e.W!=null||e.E!=null?(s=1,o=4,n=Tl(e.GG,t._a[jn],Mf(Ft(),1,4).year),r=Tl(e.W,1),i=Tl(e.E,1),(i<1||i>7)&&(l=!0)):(s=t._locale._week.dow,o=t._locale._week.doy,u=Mf(Ft(),s,o),n=Tl(e.gg,t._a[jn],u.year),r=Tl(e.w,u.week),e.d!=null?(i=e.d,(i<0||i>6)&&(l=!0)):e.e!=null?(i=e.e+s,(e.e<0||e.e>6)&&(l=!0)):i=s),r<1||r>xs(n,s,o)?Qe(t)._overflowWeeks=!0:l!=null?Qe(t)._overflowWeekday=!0:(a=oR(n,r,i,s,o),t._a[jn]=a.year,t._dayOfYear=a.dayOfYear)}ve.ISO_8601=function(){};ve.RFC_2822=function(){};function dw(t){if(t._f===ve.ISO_8601){fR(t);return}if(t._f===ve.RFC_2822){dR(t);return}t._a=[],Qe(t).empty=!0;var e=""+t._i,n,r,i,s,o,a=e.length,l=0,u,c;for(i=KP(t._f,t._locale).match(ew)||[],c=i.length,n=0;n<c;n++)s=i[n],r=(e.match(S7(s,t))||[])[0],r&&(o=e.substr(0,e.indexOf(r)),o.length>0&&Qe(t).unusedInput.push(o),e=e.slice(e.indexOf(r)+r.length),l+=r.length),Zl[s]?(r?Qe(t).empty=!1:Qe(t).unusedTokens.push(s),A7(s,r,t)):t._strict&&!r&&Qe(t).unusedTokens.push(s);Qe(t).charsLeftOver=a-l,e.length>0&&Qe(t).unusedInput.push(e),t._a[hn]<=12&&Qe(t).bigHour===!0&&t._a[hn]>0&&(Qe(t).bigHour=void 0),Qe(t).parsedDateParts=t._a.slice(0),Qe(t).meridiem=t._meridiem,t._a[hn]=V$(t._locale,t._a[hn],t._meridiem),u=Qe(t).era,u!==null&&(t._a[jn]=t._locale.erasConvertYear(u,t._a[jn])),fw(t),cw(t)}function V$(t,e,n){var r;return n==null?e:t.meridiemHour!=null?t.meridiemHour(e,n):(t.isPM!=null&&(r=t.isPM(n),r&&e<12&&(e+=12),!r&&e===12&&(e=0)),e)}function U$(t){var e,n,r,i,s,o,a=!1,l=t._f.length;if(l===0){Qe(t).invalidFormat=!0,t._d=new Date(NaN);return}for(i=0;i<l;i++)s=0,o=!1,e=X1({},t),t._useUTC!=null&&(e._useUTC=t._useUTC),e._f=t._f[i],dw(e),Z1(e)&&(o=!0),s+=Qe(e).charsLeftOver,s+=Qe(e).unusedTokens.length*10,Qe(e).score=s,a?s<r&&(r=s,n=e):(r==null||s<r||o)&&(r=s,n=e,o&&(a=!0));To(t,n||e)}function $$(t){if(!t._d){var e=tw(t._i),n=e.day===void 0?e.date:e.day;t._a=HP([e.year,e.month,n,e.hour,e.minute,e.second,e.millisecond],function(r){return r&&parseInt(r,10)}),fw(t)}}function B$(t){var e=new md(cw(hR(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function hR(t){var e=t._i,n=t._f;return t._locale=t._locale||Vs(t._l),e===null||n===void 0&&e===""?Qm({nullInput:!0}):(typeof e=="string"&&(t._i=e=t._locale.preparse(e)),mi(e)?new md(cw(e)):(pd(e)?t._d=e:pi(n)?U$(t):n?dw(t):z$(t),Z1(t)||(t._d=null),t))}function z$(t){var e=t._i;nr(e)?t._d=new Date(ve.now()):pd(e)?t._d=new Date(e.valueOf()):typeof e=="string"?L$(t):pi(e)?(t._a=HP(e.slice(0),function(n){return parseInt(n,10)}),fw(t)):$a(e)?$$(t):Ls(e)?t._d=new Date(e):ve.createFromInputFallback(t)}function pR(t,e,n,r,i){var s={};return(e===!0||e===!1)&&(r=e,e=void 0),(n===!0||n===!1)&&(r=n,n=void 0),($a(t)&&Q1(t)||pi(t)&&t.length===0)&&(t=void 0),s._isAMomentObject=!0,s._useUTC=s._isUTC=i,s._l=n,s._i=t,s._f=e,s._strict=r,B$(s)}function Ft(t,e,n,r){return pR(t,e,n,r,!1)}var q$=Hr("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var t=Ft.apply(null,arguments);return this.isValid()&&t.isValid()?t<this?this:t:Qm()}),H$=Hr("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var t=Ft.apply(null,arguments);return this.isValid()&&t.isValid()?t>this?this:t:Qm()});function mR(t,e){var n,r;if(e.length===1&&pi(e[0])&&(e=e[0]),!e.length)return Ft();for(n=e[0],r=1;r<e.length;++r)(!e[r].isValid()||e[r][t](n))&&(n=e[r]);return n}function W$(){var t=[].slice.call(arguments,0);return mR("isBefore",t)}function G$(){var t=[].slice.call(arguments,0);return mR("isAfter",t)}var K$=function(){return Date.now?Date.now():+new Date},bc=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Y$(t){var e,n=!1,r,i=bc.length;for(e in t)if(mt(t,e)&&!(en.call(bc,e)!==-1&&(t[e]==null||!isNaN(t[e]))))return!1;for(r=0;r<i;++r)if(t[bc[r]]){if(n)return!1;parseFloat(t[bc[r]])!==it(t[bc[r]])&&(n=!0)}return!0}function Q$(){return this._isValid}function Z$(){return vi(NaN)}function ig(t){var e=tw(t),n=e.year||0,r=e.quarter||0,i=e.month||0,s=e.week||e.isoWeek||0,o=e.day||0,a=e.hour||0,l=e.minute||0,u=e.second||0,c=e.millisecond||0;this._isValid=Y$(e),this._milliseconds=+c+u*1e3+l*6e4+a*1e3*60*60,this._days=+o+s*7,this._months=+i+r*3+n*12,this._data={},this._locale=Vs(),this._bubble()}function jh(t){return t instanceof ig}function r0(t){return t<0?Math.round(-1*t)*-1:Math.round(t)}function X$(t,e,n){var r=Math.min(t.length,e.length),i=Math.abs(t.length-e.length),s=0,o;for(o=0;o<r;o++)it(t[o])!==it(e[o])&&s++;return s+i}function gR(t,e){Me(t,0,0,function(){var n=this.utcOffset(),r="+";return n<0&&(n=-n,r="-"),r+Ui(~~(n/60),2)+e+Ui(~~n%60,2)})}gR("Z",":");gR("ZZ","");Te("Z",tg);Te("ZZ",tg);xt(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=hw(tg,t)});var J$=/([\+\-]|\d\d)/gi;function hw(t,e){var n=(e||"").match(t),r,i,s;return n===null?null:(r=n[n.length-1]||[],i=(r+"").match(J$)||["-",0,0],s=+(i[1]*60)+it(i[2]),s===0?0:i[0]==="+"?s:-s)}function pw(t,e){var n,r;return e._isUTC?(n=e.clone(),r=(mi(t)||pd(t)?t.valueOf():Ft(t).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),ve.updateOffset(n,!1),n):Ft(t).local()}function i0(t){return-Math.round(t._d.getTimezoneOffset())}ve.updateOffset=function(){};function eB(t,e,n){var r=this._offset||0,i;if(!this.isValid())return t!=null?this:NaN;if(t!=null){if(typeof t=="string"){if(t=hw(tg,t),t===null)return this}else Math.abs(t)<16&&!n&&(t=t*60);return!this._isUTC&&e&&(i=i0(this)),this._offset=t,this._isUTC=!0,i!=null&&this.add(i,"m"),r!==t&&(!e||this._changeInProgress?_R(this,vi(t-r,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,ve.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?r:i0(this)}function tB(t,e){return t!=null?(typeof t!="string"&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function nB(t){return this.utcOffset(0,t)}function rB(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(i0(this),"m")),this}function iB(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var t=hw(x7,this._i);t!=null?this.utcOffset(t):this.utcOffset(0,!0)}return this}function sB(t){return this.isValid()?(t=t?Ft(t).utcOffset():0,(this.utcOffset()-t)%60===0):!1}function oB(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function aB(){if(!nr(this._isDSTShifted))return this._isDSTShifted;var t={},e;return X1(t,this),t=hR(t),t._a?(e=t._isUTC?Bi(t._a):Ft(t._a),this._isDSTShifted=this.isValid()&&X$(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function lB(){return this.isValid()?!this._isUTC:!1}function uB(){return this.isValid()?this._isUTC:!1}function vR(){return this.isValid()?this._isUTC&&this._offset===0:!1}var cB=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,fB=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function vi(t,e){var n=t,r=null,i,s,o;return jh(t)?n={ms:t._milliseconds,d:t._days,M:t._months}:Ls(t)||!isNaN(+t)?(n={},e?n[e]=+t:n.milliseconds=+t):(r=cB.exec(t))?(i=r[1]==="-"?-1:1,n={y:0,d:it(r[Ri])*i,h:it(r[hn])*i,m:it(r[si])*i,s:it(r[ys])*i,ms:it(r0(r[Ta]*1e3))*i}):(r=fB.exec(t))?(i=r[1]==="-"?-1:1,n={y:ua(r[2],i),M:ua(r[3],i),w:ua(r[4],i),d:ua(r[5],i),h:ua(r[6],i),m:ua(r[7],i),s:ua(r[8],i)}):n==null?n={}:typeof n=="object"&&("from"in n||"to"in n)&&(o=dB(Ft(n.from),Ft(n.to)),n={},n.ms=o.milliseconds,n.M=o.months),s=new ig(n),jh(t)&&mt(t,"_locale")&&(s._locale=t._locale),jh(t)&&mt(t,"_isValid")&&(s._isValid=t._isValid),s}vi.fn=ig.prototype;vi.invalid=Z$;function ua(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function kT(t,e){var n={};return n.months=e.month()-t.month()+(e.year()-t.year())*12,t.clone().add(n.months,"M").isAfter(e)&&--n.months,n.milliseconds=+e-+t.clone().add(n.months,"M"),n}function dB(t,e){var n;return t.isValid()&&e.isValid()?(e=pw(e,t),t.isBefore(e)?n=kT(t,e):(n=kT(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function yR(t,e){return function(n,r){var i,s;return r!==null&&!isNaN(+r)&&(GP(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),s=n,n=r,r=s),i=vi(n,r),_R(this,i,t),this}}function _R(t,e,n,r){var i=e._milliseconds,s=r0(e._days),o=r0(e._months);t.isValid()&&(r=r??!0,o&&rR(t,Nf(t,"Month")+o*n),s&&eR(t,"Date",Nf(t,"Date")+s*n),i&&t._d.setTime(t._d.valueOf()+i*n),r&&ve.updateOffset(t,s||o))}var hB=yR(1,"add"),pB=yR(-1,"subtract");function wR(t){return typeof t=="string"||t instanceof String}function mB(t){return mi(t)||pd(t)||wR(t)||Ls(t)||vB(t)||gB(t)||t===null||t===void 0}function gB(t){var e=$a(t)&&!Q1(t),n=!1,r=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],i,s,o=r.length;for(i=0;i<o;i+=1)s=r[i],n=n||mt(t,s);return e&&n}function vB(t){var e=pi(t),n=!1;return e&&(n=t.filter(function(r){return!Ls(r)&&wR(t)}).length===0),e&&n}function yB(t){var e=$a(t)&&!Q1(t),n=!1,r=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],i,s;for(i=0;i<r.length;i+=1)s=r[i],n=n||mt(t,s);return e&&n}function _B(t,e){var n=t.diff(e,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function wB(t,e){arguments.length===1&&(arguments[0]?mB(arguments[0])?(t=arguments[0],e=void 0):yB(arguments[0])&&(e=arguments[0],t=void 0):(t=void 0,e=void 0));var n=t||Ft(),r=pw(n,this).startOf("day"),i=ve.calendarFormat(this,r)||"sameElse",s=e&&(zi(e[i])?e[i].call(this,n):e[i]);return this.format(s||this.localeData().calendar(i,this,Ft(n)))}function bB(){return new md(this)}
vendor: 14,461 bytes, line 3726
3726function EB(t,e){var n=mi(t)?t:Ft(t);return this.isValid()&&n.isValid()?(e=Wr(e)||"millisecond",e==="millisecond"?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(e).valueOf()):!1}function xB(t,e){var n=mi(t)?t:Ft(t);return this.isValid()&&n.isValid()?(e=Wr(e)||"millisecond",e==="millisecond"?this.valueOf()<n.valueOf():this.clone().endOf(e).valueOf()<n.valueOf()):!1}function TB(t,e,n,r){var i=mi(t)?t:Ft(t),s=mi(e)?e:Ft(e);return this.isValid()&&i.isValid()&&s.isValid()?(r=r||"()",(r[0]==="("?this.isAfter(i,n):!this.isBefore(i,n))&&(r[1]===")"?this.isBefore(s,n):!this.isAfter(s,n))):!1}function SB(t,e){var n=mi(t)?t:Ft(t),r;return this.isValid()&&n.isValid()?(e=Wr(e)||"millisecond",e==="millisecond"?this.valueOf()===n.valueOf():(r=n.valueOf(),this.clone().startOf(e).valueOf()<=r&&r<=this.clone().endOf(e).valueOf())):!1}function kB(t,e){return this.isSame(t,e)||this.isAfter(t,e)}function AB(t,e){return this.isSame(t,e)||this.isBefore(t,e)}function IB(t,e,n){var r,i,s;if(!this.isValid())return NaN;if(r=pw(t,this),!r.isValid())return NaN;switch(i=(r.utcOffset()-this.utcOffset())*6e4,e=Wr(e),e){case"year":s=Fh(this,r)/12;break;case"month":s=Fh(this,r);break;case"quarter":s=Fh(this,r)/3;break;case"second":s=(this-r)/1e3;break;case"minute":s=(this-r)/6e4;break;case"hour":s=(this-r)/36e5;break;case"day":s=(this-r-i)/864e5;break;case"week":s=(this-r-i)/6048e5;break;default:s=this-r}return n?s:jr(s)}function Fh(t,e){if(t.date()<e.date())return-Fh(e,t);var n=(e.year()-t.year())*12+(e.month()-t.month()),r=t.clone().add(n,"months"),i,s;return e-r<0?(i=t.clone().add(n-1,"months"),s=(e-r)/(r-i)):(i=t.clone().add(n+1,"months"),s=(e-r)/(i-r)),-(n+s)||0}ve.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";ve.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function OB(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function PB(t){if(!this.isValid())return null;var e=t!==!0,n=e?this.clone().utc():this;return n.year()<0||n.year()>9999?Lh(n,e?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):zi(Date.prototype.toISOString)?e?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",Lh(n,"Z")):Lh(n,e?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function RB(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var t="moment",e="",n,r,i,s;return this.isLocal()||(t=this.utcOffset()===0?"moment.utc":"moment.parseZone",e="Z"),n="["+t+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",i="-MM-DD[T]HH:mm:ss.SSS",s=e+'[")]',this.format(n+r+i+s)}function CB(t){t||(t=this.isUtc()?ve.defaultFormatUtc:ve.defaultFormat);var e=Lh(this,t);return this.localeData().postformat(e)}function NB(t,e){return this.isValid()&&(mi(t)&&t.isValid()||Ft(t).isValid())?vi({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function DB(t){return this.from(Ft(),t)}function MB(t,e){return this.isValid()&&(mi(t)&&t.isValid()||Ft(t).isValid())?vi({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function LB(t){return this.to(Ft(),t)}function bR(t){var e;return t===void 0?this._locale._abbr:(e=Vs(t),e!=null&&(this._locale=e),this)}var ER=Hr("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return t===void 0?this.localeData():this.locale(t)});function xR(){return this._locale}var Vp=1e3,Xl=60*Vp,Up=60*Xl,TR=(365*400+97)*24*Up;function Jl(t,e){return(t%e+e)%e}function SR(t,e,n){return t<100&&t>=0?new Date(t+400,e,n)-TR:new Date(t,e,n).valueOf()}function kR(t,e,n){return t<100&&t>=0?Date.UTC(t+400,e,n)-TR:Date.UTC(t,e,n)}function jB(t){var e,n;if(t=Wr(t),t===void 0||t==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?kR:SR,t){case"year":e=n(this.year(),0,1);break;case"quarter":e=n(this.year(),this.month()-this.month()%3,1);break;case"month":e=n(this.year(),this.month(),1);break;case"week":e=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":e=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":e=n(this.year(),this.month(),this.date());break;case"hour":e=this._d.valueOf(),e-=Jl(e+(this._isUTC?0:this.utcOffset()*Xl),Up);break;case"minute":e=this._d.valueOf(),e-=Jl(e,Xl);break;case"second":e=this._d.valueOf(),e-=Jl(e,Vp);break}return this._d.setTime(e),ve.updateOffset(this,!0),this}function FB(t){var e,n;if(t=Wr(t),t===void 0||t==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?kR:SR,t){case"year":e=n(this.year()+1,0,1)-1;break;case"quarter":e=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":e=n(this.year(),this.month()+1,1)-1;break;case"week":e=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":e=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":e=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":e=this._d.valueOf(),e+=Up-Jl(e+(this._isUTC?0:this.utcOffset()*Xl),Up)-1;break;case"minute":e=this._d.valueOf(),e+=Xl-Jl(e,Xl)-1;break;case"second":e=this._d.valueOf(),e+=Vp-Jl(e,Vp)-1;break}return this._d.setTime(e),ve.updateOffset(this,!0),this}function VB(){return this._d.valueOf()-(this._offset||0)*6e4}function UB(){return Math.floor(this.valueOf()/1e3)}function $B(){return new Date(this.valueOf())}function BB(){var t=this;return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second(),t.millisecond()]}function zB(){var t=this;return{years:t.year(),months:t.month(),date:t.date(),hours:t.hours(),minutes:t.minutes(),seconds:t.seconds(),milliseconds:t.milliseconds()}}function qB(){return this.isValid()?this.toISOString():null}function HB(){return Z1(this)}function WB(){return To({},Qe(this))}function GB(){return Qe(this).overflow}function KB(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}Me("N",0,0,"eraAbbr");Me("NN",0,0,"eraAbbr");Me("NNN",0,0,"eraAbbr");Me("NNNN",0,0,"eraName");Me("NNNNN",0,0,"eraNarrow");Me("y",["y",1],"yo","eraYear");Me("y",["yy",2],0,"eraYear");Me("y",["yyy",3],0,"eraYear");Me("y",["yyyy",4],0,"eraYear");Te("N",mw);Te("NN",mw);Te("NNN",mw);Te("NNNN",sz);Te("NNNNN",oz);xt(["N","NN","NNN","NNNN","NNNNN"],function(t,e,n,r){var i=n._locale.erasParse(t,r,n._strict);i?Qe(n).era=i:Qe(n).invalidEra=t});Te("y",$u);Te("yy",$u);Te("yyy",$u);Te("yyyy",$u);Te("yo",az);xt(["y","yy","yyy","yyyy"],jn);xt(["yo"],function(t,e,n,r){var i;n._locale._eraYearOrdinalRegex&&(i=t.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?e[jn]=n._locale.eraYearOrdinalParse(t,i):e[jn]=parseInt(t,10)});function YB(t,e){var n,r,i,s=this._eras||Vs("en")._eras;for(n=0,r=s.length;n<r;++n){switch(typeof s[n].since){case"string":i=ve(s[n].since).startOf("day"),s[n].since=i.valueOf();break}switch(typeof s[n].until){case"undefined":s[n].until=1/0;break;case"string":i=ve(s[n].until).startOf("day").valueOf(),s[n].until=i.valueOf();break}}return s}function QB(t,e,n){var r,i,s=this.eras(),o,a,l;for(t=t.toUpperCase(),r=0,i=s.length;r<i;++r)if(o=s[r].name.toUpperCase(),a=s[r].abbr.toUpperCase(),l=s[r].narrow.toUpperCase(),n)switch(e){case"N":case"NN":case"NNN":if(a===t)return s[r];break;case"NNNN":if(o===t)return s[r];break;case"NNNNN":if(l===t)return s[r];break}else if([o,a,l].indexOf(t)>=0)return s[r]}function ZB(t,e){var n=t.since<=t.until?1:-1;return e===void 0?ve(t.since).year():ve(t.since).year()+(e-t.offset)*n}function XB(){var t,e,n,r=this.localeData().eras();for(t=0,e=r.length;t<e;++t)if(n=this.clone().startOf("day").valueOf(),r[t].since<=n&&n<=r[t].until||r[t].until<=n&&n<=r[t].since)return r[t].name;return""}function JB(){var t,e,n,r=this.localeData().eras();for(t=0,e=r.length;t<e;++t)if(n=this.clone().startOf("day").valueOf(),r[t].since<=n&&n<=r[t].until||r[t].until<=n&&n<=r[t].since)return r[t].narrow;return""}function ez(){var t,e,n,r=this.localeData().eras();for(t=0,e=r.length;t<e;++t)if(n=this.clone().startOf("day").valueOf(),r[t].since<=n&&n<=r[t].until||r[t].until<=n&&n<=r[t].since)return r[t].abbr;return""}function tz(){var t,e,n,r,i=this.localeData().eras();for(t=0,e=i.length;t<e;++t)if(n=i[t].since<=i[t].until?1:-1,r=this.clone().startOf("day").valueOf(),i[t].since<=r&&r<=i[t].until||i[t].until<=r&&r<=i[t].since)return(this.year()-ve(i[t].since).year())*n+i[t].offset;return this.year()}function nz(t){return mt(this,"_erasNameRegex")||gw.call(this),t?this._erasNameRegex:this._erasRegex}function rz(t){return mt(this,"_erasAbbrRegex")||gw.call(this),t?this._erasAbbrRegex:this._erasRegex}function iz(t){return mt(this,"_erasNarrowRegex")||gw.call(this),t?this._erasNarrowRegex:this._erasRegex}function mw(t,e){return e.erasAbbrRegex(t)}function sz(t,e){return e.erasNameRegex(t)}function oz(t,e){return e.erasNarrowRegex(t)}function az(t,e){return e._eraYearOrdinalRegex||$u}function gw(){var t=[],e=[],n=[],r=[],i,s,o,a,l,u=this.eras();for(i=0,s=u.length;i<s;++i)o=Es(u[i].name),a=Es(u[i].abbr),l=Es(u[i].narrow),e.push(o),t.push(a),n.push(l),r.push(o),r.push(a),r.push(l);this._erasRegex=new RegExp("^("+r.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+e.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+t.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+n.join("|")+")","i")}Me(0,["gg",2],0,function(){return this.weekYear()%100});Me(0,["GG",2],0,function(){return this.isoWeekYear()%100});function sg(t,e){Me(0,[t,t.length],0,e)}sg("gggg","weekYear");sg("ggggg","weekYear");sg("GGGG","isoWeekYear");sg("GGGGG","isoWeekYear");Te("G",eg);Te("g",eg);Te("GG",Vt,Rr);Te("gg",Vt,Rr);Te("GGGG",rw,nw);Te("gggg",rw,nw);Te("GGGGG",Jm,Zm);Te("ggggg",Jm,Zm);vd(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=it(t)});vd(["gg","GG"],function(t,e,n,r){e[r]=ve.parseTwoDigitYear(t)});function lz(t){return AR.call(this,t,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)}function uz(t){return AR.call(this,t,this.isoWeek(),this.isoWeekday(),1,4)}function cz(){return xs(this.year(),1,4)}function fz(){return xs(this.isoWeekYear(),1,4)}function dz(){var t=this.localeData()._week;return xs(this.year(),t.dow,t.doy)}function hz(){var t=this.localeData()._week;return xs(this.weekYear(),t.dow,t.doy)}function AR(t,e,n,r,i){var s;return t==null?Mf(this,r,i).year:(s=xs(t,r,i),e>s&&(e=s),pz.call(this,t,e,n,r,i))}function pz(t,e,n,r,i){var s=oR(t,e,n,r,i),o=Df(s.year,0,s.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}Me("Q",0,"Qo","quarter");Te("Q",YP);xt("Q",function(t,e){e[vs]=(it(t)-1)*3});function mz(t){return t==null?Math.ceil((this.month()+1)/3):this.month((t-1)*3+this.month()%3)}Me("D",["DD",2],"Do","date");Te("D",Vt,Bu);Te("DD",Vt,Rr);Te("Do",function(t,e){return t?e._dayOfMonthOrdinalParse||e._ordinalParse:e._dayOfMonthOrdinalParseLenient});xt(["D","DD"],Ri);xt("Do",function(t,e){e[Ri]=it(t.match(Vt)[0])});var IR=zu("Date",!0);Me("DDD",["DDDD",3],"DDDo","dayOfYear");Te("DDD",Xm);Te("DDDD",QP);xt(["DDD","DDDD"],function(t,e,n){n._dayOfYear=it(t)});function gz(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return t==null?e:this.add(t-e,"d")}Me("m",["mm",2],0,"minute");Te("m",Vt,iw);Te("mm",Vt,Rr);xt(["m","mm"],si);var vz=zu("Minutes",!1);Me("s",["ss",2],0,"second");Te("s",Vt,iw);Te("ss",Vt,Rr);xt(["s","ss"],ys);var yz=zu("Seconds",!1);Me("S",0,0,function(){return~~(this.millisecond()/100)});Me(0,["SS",2],0,function(){return~~(this.millisecond()/10)});Me(0,["SSS",3],0,"millisecond");Me(0,["SSSS",4],0,function(){return this.millisecond()*10});Me(0,["SSSSS",5],0,function(){return this.millisecond()*100});Me(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3});Me(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4});Me(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5});Me(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6});Te("S",Xm,YP);Te("SS",Xm,Rr);Te("SSS",Xm,QP);var So,OR;for(So="SSSS";So.length<=9;So+="S")Te(So,$u);function _z(t,e){e[Ta]=it(("0."+t)*1e3)}for(So="S";So.length<=9;So+="S")xt(So,_z);OR=zu("Milliseconds",!1);Me("z",0,0,"zoneAbbr");Me("zz",0,0,"zoneName");function wz(){return this._isUTC?"UTC":""}function bz(){return this._isUTC?"Coordinated Universal Time":""}var he=md.prototype;he.add=hB;he.calendar=wB;he.clone=bB;he.diff=IB;he.endOf=FB;he.format=CB;he.from=NB;he.fromNow=DB;he.to=MB;he.toNow=LB;he.get=R7;he.invalidAt=GB;he.isAfter=EB;he.isBefore=xB;he.isBetween=TB;he.isSame=SB;he.isSameOrAfter=kB;he.isSameOrBefore=AB;he.isValid=HB;he.lang=ER;he.locale=bR;he.localeData=xR;he.max=H$;he.min=q$;he.parsingFlags=WB;he.set=C7;he.startOf=jB;he.subtract=pB;he.toArray=BB;he.toObject=zB;he.toDate=$B;he.toISOString=PB;he.inspect=RB;typeof Symbol<"u"&&Symbol.for!=null&&(he[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"});he.toJSON=qB;he.toString=OB;he.unix=UB;he.valueOf=VB;he.creationData=KB;he.eraName=XB;he.eraNarrow=JB;he.eraAbbr=ez;he.eraYear=tz;he.year=JP;he.isLeapYear=P7;he.weekYear=lz;he.isoWeekYear=uz;he.quarter=he.quarters=mz;he.month=iR;he.daysInMonth=$7;he.week=he.weeks=Y7;he.isoWeek=he.isoWeeks=Q7;he.weeksInYear=dz;he.weeksInWeekYear=hz;he.isoWeeksInYear=cz;he.isoWeeksInISOWeekYear=fz;he.date=IR;he.day=he.days=u$;he.weekday=c$;he.isoWeekday=f$;he.dayOfYear=gz;he.hour=he.hours=y$;he.minute=he.minutes=vz;he.second=he.seconds=yz;he.millisecond=he.milliseconds=OR;he.utcOffset=eB;he.utc=nB;he.local=rB;he.parseZone=iB;he.hasAlignedHourOffset=sB;he.isDST=oB;he.isLocal=lB;he.isUtcOffset=uB;he.isUtc=vR;he.isUTC=vR;he.zoneAbbr=wz;he.zoneName=bz;he.dates=Hr("dates accessor is deprecated. Use date instead.",IR);he.months=Hr("months accessor is deprecated. Use month instead",iR);he.years=Hr("years accessor is deprecated. Use year instead",JP);he.zone=Hr("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",tB);he.isDSTShifted=Hr("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",aB);function Ez(t){return Ft(t*1e3)}function xz(){return Ft.apply(null,arguments).parseZone()}function PR(t){return t}var gt=J1.prototype;gt.calendar=l7;gt.longDateFormat=d7;gt.invalidDate=p7;gt.ordinal=v7;gt.preparse=PR;gt.postformat=PR;gt.relativeTime=_7;gt.pastFuture=w7;gt.set=o7;gt.eras=YB;gt.erasParse=QB;
vendor: 6,100 bytes, lines 3726-3727
3726gt.erasConvertYear=ZB;gt.erasAbbrRegex=rz;gt.erasNameRegex=nz;gt.erasNarrowRegex=iz;gt.months=j7;gt.monthsShort=F7;gt.monthsParse=U7;gt.monthsRegex=z7;gt.monthsShortRegex=B7;gt.week=H7;gt.firstDayOfYear=K7;gt.firstDayOfWeek=G7;gt.weekdays=i$;gt.weekdaysMin=o$;gt.weekdaysShort=s$;gt.weekdaysParse=l$;gt.weekdaysRegex=d$;gt.weekdaysShortRegex=h$;gt.weekdaysMinRegex=p$;gt.isPM=g$;gt.meridiem=_$;function $p(t,e,n,r){var i=Vs(),s=Bi().set(r,e);return i[n](s,t)}function RR(t,e,n){if(Ls(t)&&(e=t,t=void 0),t=t||"",e!=null)return $p(t,e,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=$p(t,r,n,"month");return i}function vw(t,e,n,r){typeof t=="boolean"?(Ls(e)&&(n=e,e=void 0),e=e||""):(e=t,n=e,t=!1,Ls(e)&&(n=e,e=void 0),e=e||"");var i=Vs(),s=t?i._week.dow:0,o,a=[];if(n!=null)return $p(e,(n+s)%7,r,"day");for(o=0;o<7;o++)a[o]=$p(e,(o+s)%7,r,"day");return a}function Tz(t,e){return RR(t,e,"months")}function Sz(t,e){return RR(t,e,"monthsShort")}function kz(t,e,n){return vw(t,e,n,"weekdays")}function Az(t,e,n){return vw(t,e,n,"weekdaysShort")}function Iz(t,e,n){return vw(t,e,n,"weekdaysMin")}Fo("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=it(t%100/10)===1?"th":e===1?"st":e===2?"nd":e===3?"rd":"th";return t+n}});ve.lang=Hr("moment.lang is deprecated. Use moment.locale instead.",Fo);ve.langData=Hr("moment.langData is deprecated. Use moment.localeData instead.",Vs);var Xi=Math.abs;function Oz(){var t=this._data;return this._milliseconds=Xi(this._milliseconds),this._days=Xi(this._days),this._months=Xi(this._months),t.milliseconds=Xi(t.milliseconds),t.seconds=Xi(t.seconds),t.minutes=Xi(t.minutes),t.hours=Xi(t.hours),t.months=Xi(t.months),t.years=Xi(t.years),this}function CR(t,e,n,r){var i=vi(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function Pz(t,e){return CR(this,t,e,1)}function Rz(t,e){return CR(this,t,e,-1)}function AT(t){return t<0?Math.floor(t):Math.ceil(t)}function Cz(){var t=this._milliseconds,e=this._days,n=this._months,r=this._data,i,s,o,a,l;return t>=0&&e>=0&&n>=0||t<=0&&e<=0&&n<=0||(t+=AT(s0(n)+e)*864e5,e=0,n=0),r.milliseconds=t%1e3,i=jr(t/1e3),r.seconds=i%60,s=jr(i/60),r.minutes=s%60,o=jr(s/60),r.hours=o%24,e+=jr(o/24),l=jr(NR(e)),n+=l,e-=AT(s0(l)),a=jr(n/12),n%=12,r.days=e,r.months=n,r.years=a,this}function NR(t){return t*4800/146097}function s0(t){return t*146097/4800}function Nz(t){if(!this.isValid())return NaN;var e,n,r=this._milliseconds;if(t=Wr(t),t==="month"||t==="quarter"||t==="year")switch(e=this._days+r/864e5,n=this._months+NR(e),t){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(e=this._days+Math.round(s0(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return e*24+r/36e5;case"minute":return e*1440+r/6e4;case"second":return e*86400+r/1e3;case"millisecond":return Math.floor(e*864e5)+r;default:throw new Error("Unknown unit "+t)}}function Us(t){return function(){return this.as(t)}}var DR=Us("ms"),Dz=Us("s"),Mz=Us("m"),Lz=Us("h"),jz=Us("d"),Fz=Us("w"),Vz=Us("M"),Uz=Us("Q"),$z=Us("y"),Bz=DR;function zz(){return vi(this)}function qz(t){return t=Wr(t),this.isValid()?this[t+"s"]():NaN}function fl(t){return function(){return this.isValid()?this._data[t]:NaN}}var Hz=fl("milliseconds"),Wz=fl("seconds"),Gz=fl("minutes"),Kz=fl("hours"),Yz=fl("days"),Qz=fl("months"),Zz=fl("years");function Xz(){return jr(this.days()/7)}var is=Math.round,Fl={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function Jz(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function eq(t,e,n,r){var i=vi(t).abs(),s=is(i.as("s")),o=is(i.as("m")),a=is(i.as("h")),l=is(i.as("d")),u=is(i.as("M")),c=is(i.as("w")),d=is(i.as("y")),f=s<=n.ss&&["s",s]||s<n.s&&["ss",s]||o<=1&&["m"]||o<n.m&&["mm",o]||a<=1&&["h"]||a<n.h&&["hh",a]||l<=1&&["d"]||l<n.d&&["dd",l];return n.w!=null&&(f=f||c<=1&&["w"]||c<n.w&&["ww",c]),f=f||u<=1&&["M"]||u<n.M&&["MM",u]||d<=1&&["y"]||["yy",d],f[2]=e,f[3]=+t>0,f[4]=r,Jz.apply(null,f)}function tq(t){return t===void 0?is:typeof t=="function"?(is=t,!0):!1}function nq(t,e){return Fl[t]===void 0?!1:e===void 0?Fl[t]:(Fl[t]=e,t==="s"&&(Fl.ss=e-1),!0)}function rq(t,e){if(!this.isValid())return this.localeData().invalidDate();var n=!1,r=Fl,i,s;return typeof t=="object"&&(e=t,t=!1),typeof t=="boolean"&&(n=t),typeof e=="object"&&(r=Object.assign({},Fl,e),e.s!=null&&e.ss==null&&(r.ss=e.s-1)),i=this.localeData(),s=eq(this,!n,r,i),n&&(s=i.pastFuture(+this,s)),i.postformat(s)}var wv=Math.abs;function _l(t){return(t>0)-(t<0)||+t}function og(){if(!this.isValid())return this.localeData().invalidDate();var t=wv(this._milliseconds)/1e3,e=wv(this._days),n=wv(this._months),r,i,s,o,a=this.asSeconds(),l,u,c,d;return a?(r=jr(t/60),i=jr(r/60),t%=60,r%=60,s=jr(n/12),n%=12,o=t?t.toFixed(3).replace(/\.?0+$/,""):"",l=a<0?"-":"",u=_l(this._months)!==_l(a)?"-":"",c=_l(this._days)!==_l(a)?"-":"",d=_l(this._milliseconds)!==_l(a)?"-":"",l+"P"+(s?u+s+"Y":"")+(n?u+n+"M":"")+(e?c+e+"D":"")+(i||r||t?"T":"")+(i?d+i+"H":"")+(r?d+r+"M":"")+(t?d+o+"S":"")):"P0D"}var ct=ig.prototype;ct.isValid=Q$;ct.abs=Oz;ct.add=Pz;ct.subtract=Rz;ct.as=Nz;ct.asMilliseconds=DR;ct.asSeconds=Dz;ct.asMinutes=Mz;ct.asHours=Lz;ct.asDays=jz;ct.asWeeks=Fz;ct.asMonths=Vz;ct.asQuarters=Uz;ct.asYears=$z;ct.valueOf=Bz;ct._bubble=Cz;ct.clone=zz;ct.get=qz;ct.milliseconds=Hz;ct.seconds=Wz;ct.minutes=Gz;ct.hours=Kz;ct.days=Yz;ct.weeks=Xz;ct.months=Qz;ct.years=Zz;ct.humanize=rq;ct.toISOString=og;ct.toString=og;ct.toJSON=og;ct.locale=bR;ct.localeData=xR;ct.toIsoString=Hr("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",og);ct.lang=ER;Me("X",0,0,"unix");Me("x",0,0,"valueOf");Te("x",eg);Te("X",T7);xt("X",function(t,e,n){n._d=new Date(parseFloat(t)*1e3)});xt("x",function(t,e,n){n._d=new Date(it(t))});//! moment.js 3727ve.version="2.30.1";i7(Ft);ve.fn=he;ve.min=W$;ve.max=G$;ve.now=K$;ve.utc=Bi;ve.unix=Ez;ve.months=Tz;ve.isDate=pd;ve.locale=Fo;
3727ve.invalid=Qm;ve.duration=vi;ve.isMoment=mi;ve.weekdays=kz;ve.parseZone=xz;ve.localeData=Vs;ve.isDuration=jh;ve.monthsShort=Sz;ve.weekdaysMin=Iz;ve.defineLocale=uw;ve.updateLocale=x$;ve.locales=T$;ve.weekdaysShort=Az;ve.normalizeUnits=Wr;ve.relativeTimeRounding=tq;ve.relativeTimeThreshold=nq;ve.calendarFormat=_B;ve.prototype=he;ve.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};const Gn={currentConference:2026,registrationDeadline:ve(new Date("2026-05-24 23:59:59")),papersDeadline:ve(new Date("2026-06-08 23:59:59")),postersDeadline:ve(new Date("2026-06-11 23:59:59")),conferenceDate:ve(new Date("2026-06-18 12:00:00")),admins:["3K7h944y2nYtmm5RbWHKikdQX1y1","vz2csBu9aDWXipbYPFye6BMHXTi2"],dateFmt:"ddd, MMM D, YYYY",timeFmt:"HH:mm",skfmOldWebsite:"https://sk.fm.tul.cz"},qi=()=>{const[t,e]=H.useState(null),[n,r,i]=r7(gv,{onUserChanged:async l=>{e(l)}}),s=async()=>{const l=new cs;await y3(gv,l)},o=async()=>{await X6(gv)},a=Gn.admins.includes((t==null?void 0:t.uid)??"");return{user:t,isAdmin:a,signIn:s,signOut:o,loading:r,error:i}};H.createContext({user:null,setUser:()=>{}});const Ts=t=>{const e=Gn.currentConference.toString()===(t==null?void 0:t.toString()),n=new Date;return e&&n.toDateString()===Gn.conferenceDate.toDate().toDateString()?"today":!e||n>Gn.conferenceDate.toDate()?"over":n>=Gn.postersDeadline.toDate()?"coming-soon":n>=Gn.registrationDeadline.toDate()?"files-open":"registration-open"};var MR={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},IT=Je.createContext&&Je.createContext(MR),iq=["attr","size","title"];function sq(t,e){if(t==null)return{};var n,r,i=oq(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(r=0;r<s.length;r++)n=s[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function oq(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Bp(){return Bp=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Bp.apply(null,arguments)}function OT(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function zp(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?OT(Object(n),!0).forEach(function(r){aq(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):OT(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function aq(t,e,n){return(e=lq(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function lq(t){var e=uq(t,"string");return typeof e=="symbol"?e:e+""}function uq(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function LR(t){return t&&t.map((e,n)=>Je.createElement(e.tag,zp({key:n},e.attr),LR(e.child)))}function yd(t){return e=>Je.createElement(cq,Bp({attr:zp({},t.attr)},e),LR(t.child))}function cq(t){var e=n=>{var{attr:r,size:i,title:s}=t,o=sq(t,iq),a=i||n.size||"1em",l;return n.className&&(l=n.className),t.className&&(l=(l?l+" ":"")+t.className),Je.createElement("svg",Bp({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,o,{className:l,style:zp(zp({color:t.color||n.color},n.style),t.style),height:a,width:a,xmlns:"http://www.w3.org/2000/svg"}),s&&Je.createElement("title",null,s),t.children)};return IT!==void 0?Je.createElement(IT.Consumer,null,n=>e(n)):e(MR)}function fq(t){return yd({attr:{viewBox:"0 0 496 512"},child:[{tag:"path",attr:{d:"M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm0 96c48.6 0 88 39.4 88 88s-39.4 88-88 88-88-39.4-88-88 39.4-88 88-88zm0 344c-58.7 0-111.3-26.6-146.5-68.2 18.8-35.4 55.6-59.8 98.5-59.8 2.4 0 4.8.4 7.
37271 1.1 13 4.2 26.6 6.9 40.9 6.9 14.3 0 28-2.7 40.9-6.9 2.3-.7 4.7-1.1 7.1-1.1 42.9 0 79.7 24.4 98.5 59.8C359.3 421.4 306.7 448 248 448z"},child:[]}]})(t)}function dq(t){return yd({attr:{viewBox:"0 0 288 512"},child:[{tag:"path",attr:{d:"M112 316.94v156.69l22.02 33.02c4.75 7.12 15.22 7.12 19.97 0L176 473.63V316.94c-10.39 1.92-21.06 3.06-32 3.06s-21.61-1.14-32-3.06zM144 0C64.47 0 0 64.47 0 144s64.47 144 144 144 144-64.47 144-144S223.53 0 144 0zm0 76c-37.5 0-68 30.5-68 68 0 6.62-5.38 12-12 12s-12-5.38-12-12c0-50.73 41.28-92 92-92 6.62 0 12 5.38 12 12s-5.38 12-12 12z"},child:[]}]})(t)}function Dc(t){return yd({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M432,320H400a16,16,0,0,0-16,16V448H64V128H208a16,16,0,0,0,16-16V80a16,16,0,0,0-16-16H48A48,48,0,0,0,0,112V464a48,48,0,0,0,48,48H400a48,48,0,0,0,48-48V336A16,16,0,0,0,432,320ZM488,0h-128c-21.37,0-32.05,25.91-17,41l35.73,35.73L135,320.37a24,24,0,0,0,0,34L157.67,377a24,24,0,0,0,34,0L435.28,133.32,471,169c15,15,41,4.5,41-17V24A24,24,0,0,0,488,0Z"},child:[]}]})(t)}const jR=H.createContext({settings:{fullWidth:!0},setSettings:()=>{}}),hq=jR.Provider,js=(...t)=>{const e=t.filter(Boolean).join(" ");return e.length?e:""},PT="/imgs/logo-white.svg",pq=()=>{const{user:t,isAdmin:e}=qi(),{year:n}=Pr(),r=Ts(n??""),[i,s]=H.useState({fullWidth:!1});return R.jsx(hq,{value:{settings:i,setSettings:s},children:R.jsxs("div",{className:js("container mx-auto",i.fullWidth&&"max-w-none"),children:[R.jsx("nav",{className:"bg-orange-600 p-4 rounded my-1 shadow-xl text-white relative overflow-hidden",children:R.jsxs("div",{className:"flex gap-2 items-center flex-wrap",children:[R.jsx(an,{to:"/",className:"hover:bg-white/20 px-2 min-w-10 text-center py-1 rounded group",children:R.jsx("img",{src:PT,alt:"logo",className:"h-8 w-8 inline-block group-hover:scale-125 transition-all group-hover:rotate-6"})}),r!=="over"&&r!=="today"&&n===Gn.currentConference.toString()&&R.jsx(an,{to:`conferences/${n}/call-for-papers`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Call for Papers"}),r!=="over"&&R.jsx(an,{to:`conferences/${n}/programme`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Programme"}),r!=="over"&&r!=="today"&&n===Gn.currentConference.toString()&&R.jsx(an,{to:`conferences/${n}/templates`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Templates"}),r==="over"&&R.jsxs(R.Fragment,{children:[R.jsx(an,{to:`conferences/${n}/proceedings`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Proceedings"}),R.jsx(an,{to:`conferences/${n}/gallery`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Gallery"})]}),R.jsx(an,{to:`conferences/${n}/previous-years`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Previous Years"}),R.jsx(an,{to:`conferences/${n}/contacts`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Contacts"}),R.jsx("span",{className:"ml-auto",children:"Â "}),!!t&&!!n&&R.jsxs(R.Fragment,{children:[R.jsx(an,{to:`conferences/${n}/my-paper`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Registration"}),R.jsx(an,{to:`conferences/${n}/my-files`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Paper & Poster"}),e&&R.jsx(an,{to:`conferences/${n}/manage`,className:"min-w-fit hover:bg-white/20 px-2 text-center py-1 rounded",children:"Manage"})]}),R.jsx("img",{src:PT,alt:"logo",className:"h-96 w-96 inline-block absolute -top-[156px] -left-[152px] opacity-10 pointer-events-none"}),R.jsx(mq,{})]})}),R.jsx("div",{className:"p-4",children:R.jsx(cL,{})})]})})},mq=()=>{const{user:t,signIn:e,signOut:n}=qi(),r=()=>{confirm("Do you want to sign out?")&&n()};return R.jsx("div",{className:"ring-white/75 ring-1 px-2 rounded items-center flex gap-1 py-1 mx-1",children:t?R.jsx("button",{onClick:r,children:R.jsx(fq,{className:"text-xl",title:`Sign out ${t.displayName}`})}):R.jsx("button",{onClick:e,children:"Sign in"})})},gq=H.createContext({user:null,setUser:()=>{}}),vq=t=>{const{children:e}=t,[n,r]=H.useState(null);return R.jsx(gq.Provider,{value:{user:n,setUser:r},children:e})};var qu=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Aa,co,eu,JS,yq=(JS=class extends qu{constructor(){super();De(this,Aa);De(this,co);De(this,eu);be(this,eu,e=>{if(typeof window<"u"&&window.addEventListener){const n=()=>e();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){z(this,co)||this.setEventListener(z(this,eu))}onUnsubscribe(){var e;this.hasListeners()||((e=z(this,co))==null||e.call(this),be(this,co,void 0))}setEventListener(e){var n;be(this,eu,e),(n=z(this,co))==null||n.call(this),be(this,co,e(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(e){z(this,Aa)!==e&&(be(this,Aa,e),this.onFocus())}onFocus(){const e=this.isFocused();
3727this.listeners.forEach(n=>{n(e)})}isFocused(){var e;return typeof z(this,Aa)=="boolean"?z(this,Aa):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},Aa=new WeakMap,co=new WeakMap,eu=new WeakMap,JS),yw=new yq,_q={setTimeout:(t,e)=>setTimeout(t,e),clearTimeout:t=>clearTimeout(t),setInterval:(t,e)=>setInterval(t,e),clearInterval:t=>clearInterval(t)},fo,z0,e2,wq=(e2=class{constructor(){De(this,fo,_q);De(this,z0,!1)}setTimeoutProvider(t){be(this,fo,t)}setTimeout(t,e){return z(this,fo).setTimeout(t,e)}clearTimeout(t){z(this,fo).clearTimeout(t)}setInterval(t,e){return z(this,fo).setInterval(t,e)}clearInterval(t){z(this,fo).clearInterval(t)}},fo=new WeakMap,z0=new WeakMap,e2),Sa=new wq;function bq(t){setTimeout(t,0)}var Eq=typeof window>"u"||"Deno"in globalThis;function Hn(){}function xq(t,e){return typeof t=="function"?t(e):t}function o0(t){return typeof t=="number"&&t>=0&&t!==1/0}function FR(t,e){return Math.max(t+(e||0)-Date.now(),0)}function Vo(t,e){return typeof t=="function"?t(e):t}function wr(t,e){return typeof t=="function"?t(e):t}function RT(t,e){const{type:n="all",exact:r,fetchStatus:i,predicate:s,queryKey:o,stale:a}=t;if(o){if(r){if(e.queryHash!==_w(o,e.options))return!1}else if(!jf(e.queryKey,o))return!1}if(n!=="all"){const l=e.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&e.isStale()!==a||i&&i!==e.state.fetchStatus||s&&!s(e))}function CT(t,e){const{exact:n,status:r,predicate:i,mutationKey:s}=t;if(s){if(!e.options.mutationKey)return!1;if(n){if(rl(e.options.mutationKey)!==rl(s))return!1}else if(!jf(e.options.mutationKey,s))return!1}return!(r&&e.state.status!==r||i&&!i(e))}function _w(t,e){return((e==null?void 0:e.queryKeyHashFn)||rl)(t)}function rl(t){return JSON.stringify(t,(e,n)=>a0(n)?Object.keys(n).sort().reduce((r,i)=>(r[i]=n[i],r),{}):n)}function jf(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?Object.keys(e).every(n=>jf(t[n],e[n])):!1}var Tq=Object.prototype.hasOwnProperty;function VR(t,e,n=0){if(t===e)return t;if(n>500)return e;const r=NT(t)&&NT(e);if(!r&&!(a0(t)&&a0(e)))return e;const s=(r?t:Object.keys(t)).length,o=r?e:Object.keys(e),a=o.length,l=r?new Array(a):{};let u=0;for(let c=0;c<a;c++){const d=r?c:o[c],f=t[d],p=e[d];if(f===p){l[d]=f,(r?c<s:Tq.call(t,d))&&u++;continue}if(f===null||p===null||typeof f!="object"||typeof p!="object"){l[d]=p;continue}const _=VR(f,p,n+1);l[d]=_,_===f&&u++}return s===a&&u===s?t:l}function qp(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(t[n]!==e[n])return!1;return!0}function NT(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function a0(t){if(!DT(t))return!1;const e=t.constructor;if(e===void 0)return!0;const n=e.prototype;return!(!DT(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function DT(t){return Object.prototype.toString.call(t)==="[object Object]"}function Sq(t){return new Promise(e=>{Sa.setTimeout(e,t)})}function l0(t,e,n){return typeof n.structuralSharing=="function"?n.structuralSharing(t,e):n.structuralSharing!==!1?VR(t,e):e}function kq(t,e,n=0){const r=[...t,e];return n&&r.length>n?r.slice(1):r}function Aq(t,e,n=0){const r=[e,...t];return n&&r.length>n?r.slice(0,-1):r}var ww=Symbol();function UR(t,e){return!t.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!t.queryFn||t.queryFn===ww?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}function bw(t,e){return typeof t=="function"?t(...e):!!t}function Iq(t,e,n){let r=!1,i;return Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(i??(i=e()),r||(r=!0,i.aborted?n():i.addEventListener("abort",n,{once:!0})),i)}),t}var Ff=(()=>{let t=()=>Eq;return{isServer(){return t()},setIsServer(e){t=e}}})();function u0(){let t,e;const n=new Promise((i,s)=>{t=i,e=s});n.status="pending",n.catch(()=>{});function r(i){Object.assign(n,i),delete n.resolve,delete n.reject}return n.resolve=i=>{r({status:"fulfilled",value:i}),t(i)},n.reject=i=>{r({status:"rejected",reason:i}),e(i)},n}var Oq=bq;function Pq(){let t=[],e=0,n=a=>{a()},r=a=>{a()},i=Oq;const s=a=>{e?t.push(a):i(()=>{n(a)})},o=()=>{const a=t;t=[],a.length&&i(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;e++;try{l=a()}finally{e--,e||o()}return l},batchCalls:a=>(...l)=>
3727{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{i=a}}}var fn=Pq(),tu,ho,nu,t2,Rq=(t2=class extends qu{constructor(){super();De(this,tu,!0);De(this,ho);De(this,nu);be(this,nu,e=>{if(typeof window<"u"&&window.addEventListener){const n=()=>e(!0),r=()=>e(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){z(this,ho)||this.setEventListener(z(this,nu))}onUnsubscribe(){var e;this.hasListeners()||((e=z(this,ho))==null||e.call(this),be(this,ho,void 0))}setEventListener(e){var n;be(this,nu,e),(n=z(this,ho))==null||n.call(this),be(this,ho,e(this.setOnline.bind(this)))}setOnline(e){z(this,tu)!==e&&(be(this,tu,e),this.listeners.forEach(r=>{r(e)}))}isOnline(){return z(this,tu)}},tu=new WeakMap,ho=new WeakMap,nu=new WeakMap,t2),Hp=new Rq;function Cq(t){return Math.min(1e3*2**t,3e4)}function $R(t){return(t??"online")==="online"?Hp.isOnline():!0}var c0=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function BR(t){let e=!1,n=0,r;const i=u0(),s=()=>i.status!=="pending",o=y=>{var w;if(!s()){const g=new c0(y);f(g),(w=t.onCancel)==null||w.call(t,g)}},a=()=>{e=!0},l=()=>{e=!1},u=()=>yw.isFocused()&&(t.networkMode==="always"||Hp.isOnline())&&t.canRun(),c=()=>$R(t.networkMode)&&t.canRun(),d=y=>{s()||(r==null||r(),i.resolve(y))},f=y=>{s()||(r==null||r(),i.reject(y))},p=()=>new Promise(y=>{var w;r=g=>{(s()||u())&&y(g)},(w=t.onPause)==null||w.call(t)}).then(()=>{var y;r=void 0,s()||(y=t.onContinue)==null||y.call(t)}),_=()=>{if(s())return;let y;const w=n===0?t.initialPromise:void 0;try{y=w??t.fn()}catch(g){y=Promise.reject(g)}Promise.resolve(y).then(d).catch(g=>{var N;if(s())return;const m=t.retry??(Ff.isServer()?0:3),b=t.retryDelay??Cq,v=typeof b=="function"?b(n,g):b,A=m===!0||typeof m=="number"&&n<m||typeof m=="function"&&m(n,g);if(e||!A){f(g);return}n++,(N=t.onFail)==null||N.call(t,n,g),Sq(v).then(()=>u()?void 0:p()).then(()=>{e?f(g):_()})})};return{promise:i,status:()=>i.status,cancel:o,continue:()=>(r==null||r(),i),cancelRetry:a,continueRetry:l,canStart:c,start:()=>(c()?_():p().then(_),i)}}var Ia,n2,zR=(n2=class{constructor(){De(this,Ia)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),o0(this.gcTime)&&be(this,Ia,Sa.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(Ff.isServer()?1/0:5*60*1e3))}clearGcTimeout(){z(this,Ia)!==void 0&&(Sa.clearTimeout(z(this,Ia)),be(this,Ia,void 0))}},Ia=new WeakMap,n2);function Nq(t){return{onFetch:(e,n)=>{var c,d,f,p,_;const r=e.options,i=(f=(d=(c=e.fetchOptions)==null?void 0:c.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,s=((p=e.state.data)==null?void 0:p.pages)||[],o=((_=e.state.data)==null?void 0:_.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let y=!1;const w=b=>{Iq(b,()=>e.signal,()=>y=!0)},g=UR(e.options,e.fetchOptions),m=async(b,v,A)=>{if(y)return Promise.reject(e.signal.reason);if(v==null&&b.pages.length)return Promise.resolve(b);const x=(()=>{const k={client:e.client,queryKey:e.queryKey,pageParam:v,direction:A?"backward":"forward",meta:e.options.meta};return w(k),k})(),E=await g(x),{maxPages:T}=e.options,S=A?Aq:kq;return{pages:S(b.pages,E,T),pageParams:S(b.pageParams,v,T)}};if(i&&s.length){const b=i==="backward",v=b?Dq:MT,A={pages:s,pageParams:o},N=v(r,A);a=await m(A,N,b)}else{const b=t??s.length;do{const v=l===0?o[0]??r.initialPageParam:MT(r,a);if(l>0&&v==null)break;a=await m(a,v),l++}while(l<b)}return a};e.options.persister?e.fetchFn=()=>{var y,w;return(w=(y=e.options).persister)==null?void 0:w.call(y,u,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},n)}:e.fetchFn=u}}}function MT(t,{pages:e,pageParams:n}){const r=e.length-1;return e.length>0?t.getNextPageParam(e[r],e,n[r],n):void 0}function Dq(t,{pages:e,pageParams:n}){var r;return e.length>0?(r=t.getPreviousPageParam)==null?void 0:r.call(t,e[0],e,n[0],n):void 0}var ru,Oa,iu,Dr,Pa,mn,zf,Ra,yr,qR,ts,r2,Mq=(r2=class extends zR{constructor(e){super();De(this,yr);De(this,ru);De(this,Oa);De(this,iu);De(this,Dr);De(this,Pa);De(this,mn);De(this,zf);De(this,Ra);be(this,Ra,!1),be(this,zf,e.defaultOptions),this.setOptions(e.options),this.observers=[],be(this,Pa,e.client),be(this,Dr,z(this,Pa).getQueryCache()),this.queryKey=e.queryKey,this.queryHash=e.queryHash,be(this,Oa,jT(this.options)),this.state=e.state??z(this,Oa),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return z(this,ru)}get promise(){var e;return(e=z(this,mn))==null?void 0:e.promise}setOptions(e){if(this.options={...z(this,zf),...e},e!=null&&e._type&&be(this,ru,e._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const n=jT(this.options);n.data!==void 0&&(this.setState(LT(n.data,n.dataUpdatedAt)),be(this,Oa,n))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&z(this,Dr).remove(this)}setData(e,n){const r=l0(this.state.data,e,this.options);return Ke(this,yr,ts).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(e){Ke(this,yr,ts).call(this,{type:"setState",state:e})}cancel(e){var r,i;const n=(r=z(this,mn))==null?void 0:r.promise;return(i=z(this,mn))==null||i.cancel(e),n?n.then(Hn).catch(Hn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return z(this,Oa)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>wr(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===ww||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdate
3727Count>0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>Vo(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!FR(this.state.dataUpdatedAt,e)}onFocus(){var n;const e=this.observers.find(r=>r.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(n=z(this,mn))==null||n.continue()}onOnline(){var n;const e=this.observers.find(r=>r.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(n=z(this,mn))==null||n.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),z(this,Dr).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(n=>n!==e),this.observers.length||(z(this,mn)&&(z(this,Ra)||Ke(this,yr,qR).call(this)?z(this,mn).cancel({revert:!0}):z(this,mn).cancelRetry()),this.scheduleGc()),z(this,Dr).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ke(this,yr,ts).call(this,{type:"invalidate"})}async fetch(e,n){var u,c,d,f,p,_,y,w,g,m,b;if(this.state.fetchStatus!=="idle"&&((u=z(this,mn))==null?void 0:u.status())!=="rejected"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(z(this,mn))return z(this,mn).continueRetry(),z(this,mn).promise}if(e&&this.setOptions(e),!this.options.queryFn){const v=this.observers.find(A=>A.options.queryFn);v&&this.setOptions(v.options)}const r=new AbortController,i=v=>{Object.defineProperty(v,"signal",{enumerable:!0,get:()=>(be(this,Ra,!0),r.signal)})},s=()=>{const v=UR(this.options,n),N=(()=>{const x={client:z(this,Pa),queryKey:this.queryKey,meta:this.meta};return i(x),x})();return be(this,Ra,!1),this.options.persister?this.options.persister(v,N,this):v(N)},a=(()=>{const v={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:z(this,Pa),state:this.state,fetchFn:s};return i(v),v})(),l=z(this,ru)==="infinite"?Nq(this.options.pages):this.options.behavior;l==null||l.onFetch(a,this),be(this,iu,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=a.fetchOptions)==null?void 0:c.meta))&&Ke(this,yr,ts).call(this,{type:"fetch",meta:(d=a.fetchOptions)==null?void 0:d.meta}),be(this,mn,BR({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,onCancel:v=>{v instanceof c0&&v.revert&&this.setState({...z(this,iu),fetchStatus:"idle"}),r.abort()},onFail:(v,A)=>{Ke(this,yr,ts).call(this,{type:"failed",failureCount:v,error:A})},onPause:()=>{Ke(this,yr,ts).call(this,{type:"pause"})},onContinue:()=>{Ke(this,yr,ts).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0}));try{const v=await z(this,mn).start();if(v===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(v),(p=(f=z(this,Dr).config).onSuccess)==null||p.call(f,v,this),(y=(_=z(this,Dr).config).onSettled)==null||y.call(_,v,this.state.error,this),v}catch(v){if(v instanceof c0){if(v.silent)return z(this,mn).promise;if(v.revert){if(this.state.data===void 0)throw v;return this.state.data}}throw Ke(this,yr,ts).call(this,{type:"error",error:v}),(g=(w=z(this,Dr).config).onError)==null||g.call(w,v,this),(b=(m=z(this,Dr).config).onSettled)==null||b.call(m,this.state.data,v,this),v}finally{this.scheduleGc()}}},ru=new WeakMap,Oa=new WeakMap,iu=new WeakMap,Dr=new WeakMap,Pa=new WeakMap,mn=new WeakMap,zf=new WeakMap,Ra=new WeakMap,yr=new WeakSet,qR=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},ts=function(e){const n=r=>{switch(e.type){case"failed":return{...r,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...HR(r.data,this.options),fetchMeta:e.meta??null};case"success":const i={...r,...LT(e.data,e.dataUpdatedAt),dataUpdateCount:r.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return be(this,iu,e.manual?i:void 0),i;case"error":const s=e.error;
vendor: 9,586 bytes, line 3727
3727return{...r,error:s,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:s,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...e.state}}};this.state=n(this.state),fn.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),z(this,Dr).notify({query:this,type:"updated",action:e})})},r2);function HR(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:$R(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function LT(t,e){return{data:t,dataUpdatedAt:e??Date.now(),error:null,isInvalidated:!1,status:"success"}}function jT(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,n=e!==void 0,r=n?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var rr,ot,qf,zn,Ca,su,os,po,Hf,ou,au,Na,Da,mo,lu,vt,Mc,f0,d0,h0,p0,m0,g0,v0,WR,i2,Lq=(i2=class extends qu{constructor(e,n){super();De(this,vt);De(this,rr);De(this,ot);De(this,qf);De(this,zn);De(this,Ca);De(this,su);De(this,os);De(this,po);De(this,Hf);De(this,ou);De(this,au);De(this,Na);De(this,Da);De(this,mo);De(this,lu,new Set);this.options=n,be(this,rr,e),be(this,po,null),be(this,os,u0()),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(z(this,ot).addObserver(this),FT(z(this,ot),this.options)?Ke(this,vt,Mc).call(this):this.updateResult(),Ke(this,vt,p0).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return y0(z(this,ot),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return y0(z(this,ot),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Ke(this,vt,m0).call(this),Ke(this,vt,g0).call(this),z(this,ot).removeObserver(this)}setOptions(e){const n=this.options,r=z(this,ot);if(this.options=z(this,rr).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof wr(this.options.enabled,z(this,ot))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Ke(this,vt,v0).call(this),z(this,ot).setOptions(this.options),n._defaulted&&!qp(this.options,n)&&z(this,rr).getQueryCache().notify({type:"observerOptionsUpdated",query:z(this,ot),observer:this});const i=this.hasListeners();i&&VT(z(this,ot),r,this.options,n)&&Ke(this,vt,Mc).call(this),this.updateResult(),i&&(z(this,ot)!==r||wr(this.options.enabled,z(this,ot))!==wr(n.enabled,z(this,ot))||Vo(this.options.staleTime,z(this,ot))!==Vo(n.staleTime,z(this,ot)))&&Ke(this,vt,f0).call(this);const s=Ke(this,vt,d0).call(this);i&&(z(this,ot)!==r||wr(this.options.enabled,z(this,ot))!==wr(n.enabled,z(this,ot))||s!==z(this,mo))&&Ke(this,vt,h0).call(this,s)}getOptimisticResult(e){const n=z(this,rr).getQueryCache().build(z(this,rr),e),r=this.createResult(n,e);return Fq(this,r)&&(be(this,zn,r),be(this,su,this.options),be(this,Ca,z(this,ot).state)),r}getCurrentResult(){return z(this,zn)}trackResult(e,n){return new Proxy(e,{get:(r,i)=>(this.trackProp(i),n==null||n(i),i==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&z(this,os).status==="pending"&&z(this,os).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(r,i))})}trackProp(e){z(this,lu).add(e)}getCurrentQuery(){return z(this,ot)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const n=z(this,rr).defaultQueryOptions(e),r=z(this,rr).getQueryCache().build(z(this,rr),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(e){return Ke(this,vt,Mc).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),z(this,zn)))}createResult(e,n){var T;const r=z(this,ot),i=this.options,s=z(this,zn),o=z(this,Ca),a=z(this,su),u=e!==r?e.state:z(this,qf),{state:c}=e;let d={...c},f=!1,p;if(n._optimisticResults){const S=this.hasListeners(),k=!S&&FT(e,n),I=S&&VT(e,r,n,i);(k||I)&&(d={...d,...HR(c.data,e.options)}),n._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:_,errorUpdatedAt:y,status:w}=d;p=d.data;let g=!1;if(n.placeholderData!==void 0&&p===void 0&&w==="pending"){let S;s!=null&&s.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(S=s.data,g=!0):S=typeof n.placeholderData=="function"?n.placeholderData((T=z(this,au))==null?void 0:T.state.data,z(this,au)):n.placeholderData,S!==void 0&&(w="success",p=l0(s==null?void 0:s.data,S,n),f=!0)}if(n.select&&p!==void 0&&!g)if(s&&p===(o==null?void 0:o.data)&&n.select===z(this,Hf))p=z(this,ou);else try{be(this,Hf,n.select),p=n.select(p),p=l0(s==null?void 0:s.data,p,n),be(this,ou,p),be(this,po,null)}catch(S){be(this,po,S)}z(this,po)&&(_=z(this,po),p=z(this,ou),y=Date.now(),w="error");const m=d.fetchStatus==="fetching",b=w==="pending",v=w==="error",A=b&&m,N=p!==void 0,E={status:w,fetchStatus:d.fetchStatus,isPending:b,isSuccess:w==="success",isError:v,isInitialLoading:A,isLoading:A,data:p,dataUpdatedAt:d.dataUpdatedAt,error:_,errorUpdatedAt:y,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:e.isFetched(),isFetchedAfterMount:d.dataUpdateCount>u.dataUpdateCount||d.errorUpdateCount>u.errorUpdateCount,isFetching:m,isRefetching:m&&!b,isLoadingError:v&&!N,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:v&&N,isStale:Ew(e,n),refetch:this.refetch,promise:z(this,os),isEnabled:wr(n.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const S=E.data!==void 0,k=E.status==="error"&&!S,I=$=>{k?$.reject(E.error):S&&$.resolve(E.data)},P=()=>{const $=be(this,os,E.promise=u0());I($)},M=z(this,os);switch(M.status){case"pending":e.queryHash===r.queryHash&&I(M);break;case"fulfilled":(k||E.data!==M.value)&&P();break;case"rejected":(!k||E.error!==M.reason)&&P();break}}return E}updateResult(){const e=z(this,zn),n=this.createResult(z(this,ot),this.options);if(be(this,Ca,z(this,ot).state),be(this,su,this.options),z(this,Ca).data!==void 0&&be(this,au,z(this,ot)),qp(n,e))return;be(this,zn,n);const r=()=>{if(!e)return!0;const{notifyOnChangeProps:i}=this.options,s=typeof i=="function"?i():i;if(s==="all"||!s&&!z(this,lu).size)return!0;const o=new Set(s??z(this,lu));return this.options.throwOnError&&o.add("error"),Object.keys(z(this,zn)).some(a=>{const l=a;return z(this,zn)[l]!==e[l]&&o.has(l)})};Ke(this,vt,WR).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Ke(this,vt,p0).call(this)}},rr=new WeakMap,ot=new WeakMap,qf=new WeakMap,zn=new WeakMap,Ca=new WeakMap,su=new WeakMap,os=new WeakMap,po=new WeakMap,Hf=new WeakMap,ou=new WeakMap,au=new WeakMap,Na=new WeakMap,Da=new WeakMap,mo=new WeakMap,lu=new WeakMap,vt=new WeakSet,Mc=function(e){Ke(this,vt,v0).call(this);let n=z(this,ot).fetch(this.options,e);return e!=null&&e.throwOnError||(n=n.catch(Hn)),n},f0=function(){Ke(this,vt,m0).call(this);const e=Vo(this.options.staleTime,z(this,ot));if(Ff.isServer()||z(this,zn).isStale||!o0(e))return;const r=FR(z(this,zn).dataUpdatedAt,e)+1;be(this,Na,Sa.setTimeout(()=>{z(this,zn).isStale||this.updateResult()},r))},d0=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(z(this,ot)):this.options.refetchInterval)??!1},h0=function(e){Ke(this,vt,g0).call(this),be(this,mo,e),!(Ff.isServer()||wr(this.options.enabled,z(this,ot))===!1||!o0(z(this,mo))||z(this,mo)===0)&&be(this,Da,Sa.setInterval(()=>{(this.options.refetchIntervalInBackground||yw.isFocused())&&Ke(this,vt,Mc).call(this)},z(this,mo)))},p0=function(){Ke(this,vt,f0).call(this),Ke(this,vt,h0).call(this,Ke(this,vt,d0).call(this))},m0=function(){z(this,Na)!==void 0&&(Sa.clearTimeout(z(this,Na)),be(this,Na,void 0))},g0=function(){z(this,Da)!==void 0&&(Sa.clearInterval(z(this,Da)),be(this,Da,void 0))},v0=function(){const e=z(this,rr).getQueryCache().build(z(this,rr),this.options);if(e===z(this,ot))return;const n=z(this,ot);be(this,ot,e),be(this,qf,e.state),this.hasListeners()&&(n==null||n.removeObserver(this),e.addObserver(this))},WR=function(e){fn.batch(()=>{e.listeners&&this.listeners.forEach(n=>{n(z(this,zn))}),z(this,rr).getQueryCache().notify({query:z(this,ot),type:"observerResultsUpdated"})})},i2);function jq(t,e){return wr(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&wr(e.retryOnMount,t)===!1)}function FT(t,e){return jq(t,e)||t.state.data!==void 0&&y0(t,e,e.refetchOnMount)}function y0(t,e,n){if(wr(e.enabled,t)!==!1&&Vo(e.staleTime,t)!=="static"){const r=typeof n=="function"?n(t):n;return r==="always"||r!==!1&&Ew(t,e)}return!1}function VT(t,e,n,r){return(t!==e||wr(r.enabled,t)===!1)&&(!n.suspense||t.state.status!=="error")&&Ew(t,n)}function Ew(t,e){return wr(e.enabled,t)!==!1&&t.isStaleByTime(Vo(e.staleTime,t))}function Fq(t,e){return!qp(t.getCurrentResult(),e)}var Wf,Ai,Nn,Ma,Ii,to,s2,Vq=(s2=class extends zR{constructor(e){super();De(this,Ii);De(this,Wf);De(this,Ai);De(this,Nn);De(this,Ma);be(this,Wf,e.client),this.mutationId=e.mutationId,be(this,Nn,e.mutationCache),be(this,Ai,[]),this.state=e.state||GR(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}
3727addObserver(e){z(this,Ai).includes(e)||(z(this,Ai).push(e),this.clearGcTimeout(),z(this,Nn).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){be(this,Ai,z(this,Ai).filter(n=>n!==e)),this.scheduleGc(),z(this,Nn).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){z(this,Ai).length||(this.state.status==="pending"?this.scheduleGc():z(this,Nn).remove(this))}continue(){var e;return((e=z(this,Ma))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var o,a,l,u,c,d,f,p,_,y,w,g,m,b,v,A,N,x;const n=()=>{Ke(this,Ii,to).call(this,{type:"continue"})},r={client:z(this,Wf),meta:this.options.meta,mutationKey:this.options.mutationKey};be(this,Ma,BR({fn:()=>this.options.mutationFn?this.options.mutationFn(e,r):Promise.reject(new Error("No mutationFn found")),onFail:(E,T)=>{Ke(this,Ii,to).call(this,{type:"failed",failureCount:E,error:T})},onPause:()=>{Ke(this,Ii,to).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>z(this,Nn).canRun(this)}));const i=this.state.status==="pending",s=!z(this,Ma).canStart();try{if(i)n();else{Ke(this,Ii,to).call(this,{type:"pending",variables:e,isPaused:s}),z(this,Nn).config.onMutate&&await z(this,Nn).config.onMutate(e,this,r);const T=await((a=(o=this.options).onMutate)==null?void 0:a.call(o,e,r));T!==this.state.context&&Ke(this,Ii,to).call(this,{type:"pending",context:T,variables:e,isPaused:s})}const E=await z(this,Ma).start();return await((u=(l=z(this,Nn).config).onSuccess)==null?void 0:u.call(l,E,e,this.state.context,this,r)),await((d=(c=this.options).onSuccess)==null?void 0:d.call(c,E,e,this.state.context,r)),await((p=(f=z(this,Nn).config).onSettled)==null?void 0:p.call(f,E,null,this.state.variables,this.state.context,this,r)),await((y=(_=this.options).onSettled)==null?void 0:y.call(_,E,null,e,this.state.context,r)),Ke(this,Ii,to).call(this,{type:"success",data:E}),E}catch(E){try{await((g=(w=z(this,Nn).config).onError)==null?void 0:g.call(w,E,e,this.state.context,this,r))}catch(T){Promise.reject(T)}try{await((b=(m=this.options).onError)==null?void 0:b.call(m,E,e,this.state.context,r))}catch(T){Promise.reject(T)}try{await((A=(v=z(this,Nn).config).onSettled)==null?void 0:A.call(v,void 0,E,this.state.variables,this.state.context,this,r))}catch(T){Promise.reject(T)}try{await((x=(N=this.options).onSettled)==null?void 0:x.call(N,void 0,E,e,this.state.context,r))}catch(T){Promise.reject(T)}throw Ke(this,Ii,to).call(this,{type:"error",error:E}),E}finally{z(this,Nn).runNext(this)}}},Wf=new WeakMap,Ai=new WeakMap,Nn=new WeakMap,Ma=new WeakMap,Ii=new WeakSet,to=function(e){const n=r=>{switch(e.type){case"failed":return{...r,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...r,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:e.error,failureCount:r.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=n(this.state),fn.batch(()=>{z(this,Ai).forEach(r=>{r.onMutationUpdate(e)}),z(this,Nn).notify({mutation:this,type:"updated",action:e})})},s2);function GR(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var as,ei,Gf,o2,Uq=(o2=class extends qu{constructor(e={}){super();De(this,as);De(this,ei);De(this,Gf);this.config=e,be(this,as,new Set),be(this,ei,new Map),be(this,Gf,0)}build(e,n,r){const i=new Vq({client:e,mutationCache:this,mutationId:++Nd(this,Gf)._,options:e.defaultMutationOptions(n),state:r});return this.add(i),i}add(e){z(this,as).add(e);const n=ah(e);if(typeof n=="string"){const r=z(this,ei).get(n);r?r.push(e):z(this,ei).set(n,[e])}this.notify({type:"added",mutation:e})}remove(e){if(z(this,as).delete(e)){const n=ah(e);if(typeof n=="string"){const r=z(this,ei).get(n);if(r)if(r.length>1){const i=r.indexOf(e);i!==-1&&r.splice(i,1)}else r[0]===e&&z(this,ei).delete(n)}}this.notify({type:"removed",mutation:e})}canRun(e){const n=ah(e);if(typeof n=="string"){const r=z(this,ei).get(n),i=r==null?void 0:r.find(s=>
vendor: 4,097 bytes, line 3727
3727s.state.status==="pending");return!i||i===e}else return!0}runNext(e){var r;const n=ah(e);if(typeof n=="string"){const i=(r=z(this,ei).get(n))==null?void 0:r.find(s=>s!==e&&s.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){fn.batch(()=>{z(this,as).forEach(e=>{this.notify({type:"removed",mutation:e})}),z(this,as).clear(),z(this,ei).clear()})}getAll(){return Array.from(z(this,as))}find(e){const n={exact:!0,...e};return this.getAll().find(r=>CT(n,r))}findAll(e={}){return this.getAll().filter(n=>CT(e,n))}notify(e){fn.batch(()=>{this.listeners.forEach(n=>{n(e)})})}resumePausedMutations(){const e=this.getAll().filter(n=>n.state.isPaused);return fn.batch(()=>Promise.all(e.map(n=>n.continue().catch(Hn))))}},as=new WeakMap,ei=new WeakMap,Gf=new WeakMap,o2);function ah(t){var e;return(e=t.options.scope)==null?void 0:e.id}var ls,go,ir,us,ks,Vh,_0,a2,$q=(a2=class extends qu{constructor(n,r){super();De(this,ks);De(this,ls);De(this,go);De(this,ir);De(this,us);be(this,ls,n),this.setOptions(r),this.bindMethods(),Ke(this,ks,Vh).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var i;const r=this.options;this.options=z(this,ls).defaultMutationOptions(n),qp(this.options,r)||z(this,ls).getMutationCache().notify({type:"observerOptionsUpdated",mutation:z(this,ir),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&rl(r.mutationKey)!==rl(this.options.mutationKey)?this.reset():((i=z(this,ir))==null?void 0:i.state.status)==="pending"&&z(this,ir).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=z(this,ir))==null||n.removeObserver(this)}onMutationUpdate(n){Ke(this,ks,Vh).call(this),Ke(this,ks,_0).call(this,n)}getCurrentResult(){return z(this,go)}reset(){var n;(n=z(this,ir))==null||n.removeObserver(this),be(this,ir,void 0),Ke(this,ks,Vh).call(this),Ke(this,ks,_0).call(this)}mutate(n,r){var i;return be(this,us,r),(i=z(this,ir))==null||i.removeObserver(this),be(this,ir,z(this,ls).getMutationCache().build(z(this,ls),this.options)),z(this,ir).addObserver(this),z(this,ir).execute(n)}},ls=new WeakMap,go=new WeakMap,ir=new WeakMap,us=new WeakMap,ks=new WeakSet,Vh=function(){var r;const n=((r=z(this,ir))==null?void 0:r.state)??GR();be(this,go,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},_0=function(n){fn.batch(()=>{var r,i,s,o,a,l,u,c;if(z(this,us)&&this.hasListeners()){const d=z(this,go).variables,f=z(this,go).context,p={client:z(this,ls),meta:this.options.meta,mutationKey:this.options.mutationKey};if((n==null?void 0:n.type)==="success"){try{(i=(r=z(this,us)).onSuccess)==null||i.call(r,n.data,d,f,p)}catch(_){Promise.reject(_)}try{(o=(s=z(this,us)).onSettled)==null||o.call(s,n.data,null,d,f,p)}catch(_){Promise.reject(_)}}else if((n==null?void 0:n.type)==="error"){try{(l=(a=z(this,us)).onError)==null||l.call(a,n.error,d,f,p)}catch(_){Promise.reject(_)}try{(c=(u=z(this,us)).onSettled)==null||c.call(u,void 0,n.error,d,f,p)}catch(_){Promise.reject(_)}}}this.listeners.forEach(d=>{d(z(this,go))})})},a2),Oi,l2,Bq=(l2=class extends qu{constructor(e={}){super();De(this,Oi);this.config=e,be(this,Oi,new Map)}build(e,n,r){const i=n.queryKey,s=n.queryHash??_w(i,n);let o=this.get(s);return o||(o=new Mq({client:e,queryKey:i,queryHash:s,options:e.defaultQueryOptions(n),state:r,defaultOptions:e.getQueryDefaults(i)}),this.add(o)),o}add(e){z(this,Oi).has(e.queryHash)||(z(this,Oi).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const n=z(this,Oi).get(e.queryHash);n&&(e.destroy(),n===e&&z(this,Oi).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){fn.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return z(this,Oi).get(e)}getAll(){return[...z(this,Oi).values()]}find(e){const n={exact:!0,...e};return this.getAll().find(r=>RT(n,r))}findAll(e={}){const n=this.getAll();return Object.keys(e).length>0?n.filter(r=>RT(e,r)):n}notify(e){fn.batch(()=>{this.listeners.forEach(n=>
vendor: 5,482 bytes, line 3727
3727{n(e)})})}onFocus(){fn.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){fn.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Oi=new WeakMap,l2),Qt,vo,yo,uu,cu,_o,fu,du,u2,zq=(u2=class{constructor(t={}){De(this,Qt);De(this,vo);De(this,yo);De(this,uu);De(this,cu);De(this,_o);De(this,fu);De(this,du);be(this,Qt,t.queryCache||new Bq),be(this,vo,t.mutationCache||new Uq),be(this,yo,t.defaultOptions||{}),be(this,uu,new Map),be(this,cu,new Map),be(this,_o,0)}mount(){Nd(this,_o)._++,z(this,_o)===1&&(be(this,fu,yw.subscribe(async t=>{t&&(await this.resumePausedMutations(),z(this,Qt).onFocus())})),be(this,du,Hp.subscribe(async t=>{t&&(await this.resumePausedMutations(),z(this,Qt).onOnline())})))}unmount(){var t,e;Nd(this,_o)._--,z(this,_o)===0&&((t=z(this,fu))==null||t.call(this),be(this,fu,void 0),(e=z(this,du))==null||e.call(this),be(this,du,void 0))}isFetching(t){return z(this,Qt).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return z(this,vo).findAll({...t,status:"pending"}).length}getQueryData(t){var n;const e=this.defaultQueryOptions({queryKey:t});return(n=z(this,Qt).get(e.queryHash))==null?void 0:n.state.data}ensureQueryData(t){const e=this.defaultQueryOptions(t),n=z(this,Qt).build(this,e),r=n.state.data;return r===void 0?this.fetchQuery(t):(t.revalidateIfStale&&n.isStaleByTime(Vo(e.staleTime,n))&&this.prefetchQuery(e),Promise.resolve(r))}getQueriesData(t){return z(this,Qt).findAll(t).map(({queryKey:e,state:n})=>{const r=n.data;return[e,r]})}setQueryData(t,e,n){const r=this.defaultQueryOptions({queryKey:t}),i=z(this,Qt).get(r.queryHash),s=i==null?void 0:i.state.data,o=xq(e,s);if(o!==void 0)return z(this,Qt).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(t,e,n){return fn.batch(()=>z(this,Qt).findAll(t).map(({queryKey:r})=>[r,this.setQueryData(r,e,n)]))}getQueryState(t){var n;const e=this.defaultQueryOptions({queryKey:t});return(n=z(this,Qt).get(e.queryHash))==null?void 0:n.state}removeQueries(t){const e=z(this,Qt);fn.batch(()=>{e.findAll(t).forEach(n=>{e.remove(n)})})}resetQueries(t,e){const n=z(this,Qt);return fn.batch(()=>(n.findAll(t).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...t},e)))}cancelQueries(t,e={}){const n={revert:!0,...e},r=fn.batch(()=>z(this,Qt).findAll(t).map(i=>i.cancel(n)));return Promise.all(r).then(Hn).catch(Hn)}invalidateQueries(t,e={}){return fn.batch(()=>(z(this,Qt).findAll(t).forEach(n=>{n.invalidate()}),(t==null?void 0:t.refetchType)==="none"?Promise.resolve():this.refetchQueries({...t,type:(t==null?void 0:t.refetchType)??(t==null?void 0:t.type)??"active"},e)))}refetchQueries(t,e={}){const n={...e,cancelRefetch:e.cancelRefetch??!0},r=fn.batch(()=>z(this,Qt).findAll(t).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let s=i.fetch(void 0,n);return n.throwOnError||(s=s.catch(Hn)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(Hn)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const n=z(this,Qt).build(this,e);return n.isStaleByTime(Vo(e.staleTime,n))?n.fetch(e):Promise.resolve(n.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(Hn).catch(Hn)}fetchInfiniteQuery(t){return t._type="infinite",this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(Hn).catch(Hn)}ensureInfiniteQueryData(t){return t._type="infinite",this.ensureQueryData(t)}resumePausedMutations(){return Hp.isOnline()?z(this,vo).resumePausedMutations():Promise.resolve()}getQueryCache(){return z(this,Qt)}getMutationCache(){return z(this,vo)}getDefaultOptions(){return z(this,yo)}setDefaultOptions(t){be(this,yo,t)}setQueryDefaults(t,e){z(this,uu).set(rl(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...z(this,uu).values()],n={};return e.forEach(r=>{jf(t,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(t,e){z(this,cu).set(rl(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...z(this,cu).values()],n={};return e.forEach(r=>{jf(t,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(t){if(t._defaulted)return t;const e={...z(this,yo).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=_w(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===ww&&(e.enabled=!1),e}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...z(this,yo).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){z(this,Qt).clear(),z(this,vo).clear()}},Qt=new WeakMap,vo=new WeakMap,yo=new WeakMap,uu=new WeakMap,cu=new WeakMap,_o=new WeakMap,fu=new WeakMap,du=new WeakMap,u2),KR=H.createContext(void 0),xw=t=>{const e=H.useContext(KR);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},qq=({client:t,children:e})=>(H.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),R.jsx(KR.Provider,{value:t,children:e})),YR=H.createContext(!1),Hq=()=>H.useContext(YR);YR.Provider;function Wq(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var Gq=H.createContext(Wq()),Kq=()=>H.useContext(Gq),Yq=(t,e,n)=>{const r=n!=null&&n.state.error&&typeof t.throwOnError=="function"?bw(t.throwOnError,[n.state.error,n]):t.throwOnError;(t.suspense||t.experimental_prefetchInRender||r)&&(e.isReset()||(t.retryOn
3727Mount=!1))},Qq=t=>{H.useEffect(()=>{t.clearReset()},[t])},Zq=({result:t,errorResetBoundary:e,throwOnError:n,query:r,suspense:i})=>t.isError&&!e.isReset()&&!t.isFetching&&r&&(i&&t.data===void 0||bw(n,[t.error,r])),Xq=t=>{if(t.suspense){const n=i=>i==="static"?i:Math.max(i??1e3,1e3),r=t.staleTime;t.staleTime=typeof r=="function"?(...i)=>n(r(...i)):n(r),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3))}},Jq=(t,e)=>t.isLoading&&t.isFetching&&!e,eH=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,UT=(t,e,n)=>e.fetchOptimistic(t).catch(()=>{n.clearReset()});function tH(t,e,n){var p,_,y,w;const r=Hq(),i=Kq(),s=xw(),o=s.defaultQueryOptions(t);(_=(p=s.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||_.call(p,o);const a=s.getQueryCache().get(o.queryHash),l=t.subscribed!==!1;o._optimisticResults=r?"isRestoring":l?"optimistic":void 0,Xq(o),Yq(o,i,a),Qq(i);const u=!s.getQueryCache().get(o.queryHash),[c]=H.useState(()=>new e(s,o)),d=c.getOptimisticResult(o),f=!r&&l;if(H.useSyncExternalStore(H.useCallback(g=>{const m=f?c.subscribe(fn.batchCalls(g)):Hn;return c.updateResult(),m},[c,f]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),H.useEffect(()=>{c.setOptions(o)},[o,c]),eH(o,d))throw UT(o,c,i);if(Zq({result:d,errorResetBoundary:i,throwOnError:o.throwOnError,query:a,suspense:o.suspense}))throw d.error;if((w=(y=s.getDefaultOptions().queries)==null?void 0:y._experimental_afterQuery)==null||w.call(y,o,d),o.experimental_prefetchInRender&&!Ff.isServer()&&Jq(d,r)){const g=u?UT(o,c,i):a==null?void 0:a.promise;g==null||g.catch(Hn).finally(()=>{c.updateResult()})}return o.notifyOnChangeProps?d:c.trackResult(d)}function ta(t,e){return tH(t,Lq)}function Vf(t,e){const n=xw(),[r]=H.useState(()=>new $q(n,t));H.useEffect(()=>{r.setOptions(t)},[r,t]);const i=H.useSyncExternalStore(H.useCallback(o=>r.subscribe(fn.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=H.useCallback((o,a)=>{r.mutate(o,a).catch(Hn)},[r]);if(i.error&&bw(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}var Fr=(t=>(t.SGS="SGS",t.BP="BP",t.DP="DP",t.Dproj="Dproj",t.PHD="PHD",t))(Fr||{}),Ye=(t=>(t.PENDING="PENDING",t.ACCEPTED="ACCEPTED",t.PUBLISHED="PUBLISHED",t.REJECTED="REJECTED",t.WITHDRAWN="WITHDRAWN",t.PAPER_OK="PAPER_OK",t.POSTER_OK="POSTER_OK",t.ACTION_REQUIRED="ACTION_REQUIRED",t))(Ye||{});const Tw=t=>{const{user:e,signIn:n}=qi(),{year:r}=Pr(),i=Ts(r),s=ta({queryKey:["articles",r,e==null?void 0:e.uid],queryFn:async()=>{const a=Vu(hi,Ho("conferenceId","==",r),Ho("userId","==",e==null?void 0:e.uid));return(await Uu(a)).docs.map(c=>c.data())[0]},enabled:!!e});if(!e)return R.jsx("div",{className:"flex gap-2 items-center mt-2",children:R.jsx("button",{className:"bg-orange-500 text-white px-4 py-1 rounded inline-block",onClick:n,children:"Sign in to see your registration status"})});if(s.isLoading)return R.jsx("div",{children:"Loading..."});const o=s.data;return r!==Gn.currentConference.toString()?R.jsx(R.Fragment,{}):i==="today"?R.jsx(R.Fragment,{}):R.jsx("div",{className:"border border-dashed p-4 rounded",children:R.jsx(nH,{article:o})})},nH=({article:t})=>{const{year:e}=Pr(),n=Ts(e);if(!t)return n!=="registration-open"?R.jsx("div",{children:"Registration for the conference is closed"}):R.jsxs("div",{className:"flex gap-2 items-center",children:["Want to present your article at the conference?",Ts(e)==="registration-open"&&R.jsx(an,{className:"bg-orange-500 text-white px-4 py-1 rounded inline-block ml-auto",to:`/conferences/${e}/my-paper`,children:"Register for the conference"})]});if(t.status===Ye.PENDING)return R.jsxs("div",{className:"flex gap-2 items-center",children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," is pending review",Ts(e)==="registration-open"&&R.jsx(an,{className:"bg-orange-500 text-white px-4 py-1 rounded inline-block ml-auto",to:`/conferences/${e}/my-paper`,children:"Update your registration"})]});if(t.status===Ye.ACTION_REQUIRED){const{posterFileComments:r,abstractFileComments:i}=t,s=!!i||!!r;return R.jsxs("div",{children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," requires your attention",R.jsxs("div",{className:"flex flex-col gap-2",children:[!!i&&R.jsxs("div",{className:"bg-orange-100 p-2 rounded mt-2",children:[R.jsx("h1",{className:"text-lg",children:"Reviewer comments on your abstract:"}),R.jsx("p",{dangerouslySetInnerHTML:{__html:i}})]}),!!r&&R.jsxs("div",{className:"bg-orange-100 p-2 rounded mt-2",children:[R.jsx("h1",{className:"text-lg",children:"Reviewer comments on your poster:"}),R.jsx("p",{dangerouslySetInnerHTML:{__html:r}}
vendor: 217,140 bytes, lines 3727-3767
3727)]}),s&&R.jsx("div",{children:R.jsx(an,{className:"bg-orange-500 text-white px-4 py-1 rounded inline-block",to:`/conferences/${e}/my-files`,children:"Upload corrected version of your files"})})]})]})}if(t.status===Ye.ACCEPTED)return R.jsxs("div",{children:["Congratulations! Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," has been accepted to the conference!"]});if(t.status===Ye.REJECTED)return R.jsxs("div",{children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," has been rejected from the conference."]});if(t.status===Ye.PAPER_OK)return R.jsxs("div",{children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," has been accepted to the conference and the paper you submitted is has been approved."]});if(t.status===Ye.POSTER_OK)return R.jsxs("div",{children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," has been accepted to the conference and both the paper and the poster you submitted are approved."]});if(t.status===Ye.WITHDRAWN)return R.jsxs("div",{children:["You have withdrawn your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," from the conference."]});if(t.status===Ye.PUBLISHED)return R.jsxs("div",{children:["Your registration ",R.jsx("span",{className:"bg-orange-100 font-bold px-1",children:t.title})," has been published and is now available to the public."]})};function rH(){this.__data__=[],this.size=0}var iH=rH;function sH(t,e){return t===e||t!==t&&e!==e}var QR=sH,oH=QR;function aH(t,e){for(var n=t.length;n--;)if(oH(t[n][0],e))return n;return-1}var ag=aH,lH=ag,uH=Array.prototype,cH=uH.splice;function fH(t){var e=this.__data__,n=lH(e,t);if(n<0)return!1;var r=e.length-1;return n==r?e.pop():cH.call(e,n,1),--this.size,!0}var dH=fH,hH=ag;function pH(t){var e=this.__data__,n=hH(e,t);return n<0?void 0:e[n][1]}var mH=pH,gH=ag;function vH(t){return gH(this.__data__,t)>-1}var yH=vH,_H=ag;function wH(t,e){var n=this.__data__,r=_H(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}var bH=wH,EH=iH,xH=dH,TH=mH,SH=yH,kH=bH;function Hu(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}Hu.prototype.clear=EH;Hu.prototype.delete=xH;Hu.prototype.get=TH;Hu.prototype.has=SH;Hu.prototype.set=kH;var lg=Hu,AH=lg;function IH(){this.__data__=new AH,this.size=0}var OH=IH;function PH(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}var RH=PH;function CH(t){return this.__data__.get(t)}var NH=CH;function DH(t){return this.__data__.has(t)}var MH=DH,LH=typeof br=="object"&&br&&br.Object===Object&&br,ZR=LH,jH=ZR,FH=typeof self=="object"&&self&&self.Object===Object&&self,VH=jH||FH||Function("return this")(),$s=VH,UH=$s,$H=UH.Symbol,Sw=$H,$T=Sw,XR=Object.prototype,BH=XR.hasOwnProperty,zH=XR.toString,Ec=$T?$T.toStringTag:void 0;function qH(t){var e=BH.call(t,Ec),n=t[Ec];try{t[Ec]=void 0;var r=!0}catch{}var i=zH.call(t);return r&&(e?t[Ec]=n:delete t[Ec]),i}var HH=qH,WH=Object.prototype,GH=WH.toString;function KH(t){return GH.call(t)}var YH=KH,BT=Sw,QH=HH,ZH=YH,XH="[object Null]",JH="[object Undefined]",zT=BT?BT.toStringTag:void 0;function eW(t){return t==null?t===void 0?JH:XH:zT&&zT in Object(t)?QH(t):ZH(t)}var ug=eW;function tW(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var JR=tW,nW=ug,rW=JR,iW="[object AsyncFunction]",sW="[object Function]",oW="[object GeneratorFunction]",aW="[object Proxy]";function lW(t){if(!rW(t))return!1;var e=nW(t);return e==sW||e==oW||e==iW||e==aW}var eC=lW,uW=$s,cW=uW["__core-js_shared__"],fW=cW,bv=fW,qT=function(){var t=/[^.]+$/.exec(bv&&bv.keys&&bv.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function dW(t){return!!qT&&qT in t}var hW=dW,pW=Function.prototype,mW=pW.toString;function gW(t){if(t!=null){try{return mW.call(t)}catch{}try{return t+""}catch{}}return""}var tC=gW,vW=eC,yW=hW,_W=JR,wW=tC,bW=/[\\^$.*+?()[\]{}|]/g,EW=/^\[object .+?Constructor\]$/,xW=Function.prototype,TW=Object.prototype,SW=xW.toString,kW=TW.hasOwnProperty,AW=RegExp("^"+SW.call(kW).replace(bW,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function IW(t){if(!_W(t)||yW(t))return!1;var e=vW(t)?AW:EW;return e.test(wW(t))}var OW=IW;function PW(t,e){return t==null?void 0:t[e]}var RW=PW,CW=OW,NW=RW;function DW(t,e){var n=NW(t,e);return CW(n)?n:void 0}var Wu=DW,MW=Wu,LW=$s,jW=MW(LW,"Map"),kw=jW,FW=Wu,VW=FW(Object,"create"),cg=VW,HT=cg;function UW(){this.__data__=HT?HT(null):{},this.size=0}var $W=UW;function BW(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var zW=BW,qW=cg,HW="__lodash_hash_undefined__",WW=Object.prototype,GW=WW.hasOwnProperty;function KW(t){var e=this.__data__;if(qW){var n=e[t];return n===HW?void 0:n}return GW.call(e,t)?e[t]:void 0}var YW=KW,QW=cg,ZW=Object.prototype,XW=ZW.hasOwnProperty;function JW(t){var e=this.__data__;return QW?e[t]!==void 0:XW.call(e,t)}var eG=JW,tG=cg,nG="__lodash_hash_undefined__";function rG(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=tG&&e===void 0?nG:e,this}var iG=rG,sG=$W,oG=zW,aG=YW,lG=eG,uG=iG;function Gu(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}Gu.prototype.clear=sG;Gu.prototype.delete=oG;Gu.prototype.get=aG;Gu.prototype.has=lG;Gu.prototype.set=uG;var cG=Gu,WT=cG,fG=lg,dG=kw;function hG(){this.size=0,this.__data__={hash:new WT,map:new(dG||fG),string:new WT}}var pG=hG;function mG(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var gG=mG,vG=gG;function yG(t,e){var n=t.__data__;return vG(e)?n[typeof e=="string"?"string":"hash"]:n.map}var fg=yG,_G=fg;function wG(t){var e=_G(this,t).delete(t);return this.size-=e?1:0,e}var bG=wG,EG=fg;function xG(t){return EG(this,t).get(t)}var TG=xG,SG=fg;function kG(t){return SG(this,t).has(t)}var AG=kG,IG=fg;function OG(t,e){var n=IG(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this}var PG=OG,RG=pG,CG=bG,NG=TG,DG=AG,MG=PG;function Ku(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}Ku.prototype.clear=RG;Ku.prototype.delete=CG;Ku.prototype.get=NG;Ku.prototype.has=DG;Ku.prototype.set=MG;var nC=Ku,LG=lg,jG=kw,FG=nC,VG=200;function UG(t,e){var n=this.__data__;if(n instanceof LG){var r=n.__data__;if(!jG||r.length<VG-1)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new FG(r)}return n.set(t,e),this.size=n.size,this}var $G=UG,BG=lg,zG=OH,qG=RH,HG=NH,WG=MH,GG=$G;function Yu(t){var e=this.__data__=new BG(t);this.size=e.size}Yu.prototype.clear=zG;Yu.prototype.delete=qG;Yu.prototype.get=HG;Yu.prototype.has=WG;Yu.prototype.set=GG;var KG=Yu,YG="__lodash_hash_undefined__";function QG(t){return this.__data__.set(t,YG),this}var ZG=QG;function XG(t){return this.__data__.has(t)}var JG=XG,eK=nC,tK=ZG,nK=JG;function Wp(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new eK;++e<n;)this.add(t[e])}Wp.prototype.add=Wp.prototype.push=tK;Wp.prototype.has=nK;var rK=Wp;function iK(t,e){for(var n=-1,r=t==null?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var sK=iK;function oK(t,e){return t.has(e)}var aK=oK,lK=rK,uK=sK,cK=aK,fK=1,dK=2;function hK(t,e,n,r,i,s){var o=n&fK,a=t.length,l=e.length;if(a!=l&&!(o&&l>a))return!1;var u=s.get(t),c=s.get(e);if(u&&c)return u==e&&c==t;var d=-1,f=!0,p=n&dK?new lK:void 0;for(s.set(t,e),s.set(e,t);++d<a;){var _=t[d],y=e[d];if(r)var w=o?r(y,_,d,e,t,s):r(_,y,d,t,e,s);if(w!==void 0){if(w)continue;f=!1;break}if(p){if(!uK(e,function(g,m){if(!cK(p,m)&&(_===g||i(_,g,n,r,s)))return p.push(m)})){f=!1;break}}else if(!(_===y||i(_,y,n,r,s))){f=!1;break}}return s.delete(t),s.delete(e),f}var rC=hK,pK=$s,mK=pK.Uint8Array,gK=mK;function vK(t){var e=-1,n=Array(t.size);return t.forEach(function(r,i){n[++e]=[i,r]}),n}var yK=vK;function _K(t){var e=-1,n=Array(t.size);return t.forEach(function(r){n[++e]=r}),n}var wK=_K,GT=Sw,KT=gK,bK=QR,EK=rC,xK=yK,TK=wK,SK=1,kK=2,AK="[object Boolean]",IK="[object Date]",OK="[object Error]",PK="[object Map]",RK="[object Number]",CK="[object RegExp]",NK="[object Set]",DK="[object String]",MK="[object Symbol]",LK="[object ArrayBuffer]",jK="[object DataView]",YT=GT?GT.prototype:void 0,Ev=YT?YT.valueOf:void 0;function FK(t,e,n,r,i,s,o){switch(n){case jK:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case LK:return!(t.byteLength!=e.byteLength||!s(new KT(t),new KT(e)));case AK:case IK:case RK:return bK(+t,+e);case OK:return t.name==e.name&&t.message==e.message;case CK:case DK:return t==e+"";case PK:var a=xK;case NK:var l=r&SK;if(a||(a=TK),t.size!=e.size&&!l)return!1;var u=o.get(t);if(u)return u==e;r|=kK,o.set(t,e);var c=EK(a(t),a(e),r,i,s,o);return o.delete(t),c;case MK:if(Ev)return Ev.call(t)==Ev.call(e)}return!1}var VK=FK;function UK(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}var $K=UK,BK=Array.isArray,Aw=BK,zK=$K,qK=Aw;function HK(t,e,n){var r=e(t);return qK(t)?r:zK(r,n(t))}var WK=HK;function GK(t,e){for(var n=-1,r=t==null?0:t.length,i=0,s=[];++n<r;){var o=t[n];e(o,n,t)&&(s[i++]=o)}return s}var KK=GK;function YK(){return[]}var QK=YK,ZK=KK,XK=QK,JK=Object.prototype,eY=JK.propertyIsEnumerable,QT=Object.getOwnPropertySymbols,tY=QT?function(t){return t==null?[]:(t=Object(t),ZK(QT(t),function(e){return eY.call(t,e)}))}:XK,nY=tY;function rY(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}var iY=rY;function sY(t){return t!=null&&typeof t=="object"}var dg=sY,oY=ug,aY=dg,lY="[object Arguments]";function uY(t){return aY(t)&&oY(t)==lY}var cY=uY,ZT=cY,fY=dg,iC=Object.prototype,dY=iC.hasOwnProperty,hY=iC.propertyIsEnumerable,pY=ZT(function(){return arguments}())?ZT:function(t){return fY(t)&&dY.call(t,"callee")&&!hY.call(t,"callee")},mY=pY,Gp={exports:{}};function gY(){return!1}var vY=gY;Gp.exports;(function(t,e){var n=$s,r=vY,i=e&&!e.nodeType&&e,s=i&&!0&&t&&!t.nodeType&&t,o=s&&s.exports===i,a=o?n.Buffer:void 0,l=a?a.isBuffer:void 0,u=l||r;t.exports=u})(Gp,Gp.exports);var sC=Gp.exports,yY=9007199254740991,_Y=/^(?:0|[1-9]\d*)$/;function wY(t,e){var n=typeof t;return e=e??yY,!!e&&(n=="number"||n!="symbol"&&_Y.test(t))&&t>-1&&t%1==0&&t<e}var bY=wY,EY=9007199254740991;function xY(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=EY}var oC=xY,TY=ug,SY=oC,kY=dg,AY="[object Arguments]",IY="[object Array]",OY="[object Boolean]",PY="[object Date]",RY="[object Error]",CY="[object Function]",NY="[object Map]",DY="[object Number]",MY="[object Object]",LY="[object RegExp]",jY="[object Set]",FY="[object String]",VY="[object WeakMap]",UY="[object ArrayBuffer]",$Y="[object DataView]",BY="[object Float32Array]",zY="[object Float64Array]",qY="[object Int8Array]",HY="[object Int16Array]",WY="[object Int32Array]",GY="[object Uint8Array]",KY="[object Uint8ClampedArray]",YY="[object Uint16Array]",QY="[object Uint32Array]",Dt={};Dt[BY]=Dt[zY]=Dt[qY]=Dt[HY]=Dt[WY]=Dt[GY]=Dt[KY]=Dt[YY]=Dt[QY]=!0;Dt[AY]=Dt[IY]=Dt[UY]=Dt[OY]=Dt[$Y]=Dt[PY]=Dt[RY]=Dt[CY]=Dt[NY]=Dt[DY]=Dt[MY]=Dt[LY]=Dt[jY]=Dt[FY]=Dt[VY]=!1;function ZY(t){return kY(t)&&SY(t.length)&&!!Dt[TY(t)]}var XY=ZY;function JY(t){return function(e){return t(e)}}var eQ=JY,Kp={exports:{}};Kp.exports;(function(t,e){var n=ZR,r=e&&!e.nodeType&&e,i=r&&!0&&t&&!t.nodeType&&t,s=i&&i.exports===r,o=s&&n.process,a=function(){try{var l=i&&i.require&&i.require("util").types;return l||o&&o.binding&&o.binding("util")}catch{}}();t.exports=a})(Kp,Kp.exports);var tQ=Kp.exports,nQ=XY,rQ=eQ,XT=tQ,JT=XT&&XT.isTypedArray,iQ=JT?rQ(JT):nQ,aC=iQ,sQ=iY,oQ=mY,aQ=Aw,lQ=sC,uQ=bY,cQ=aC,fQ=Object.prototype,dQ=fQ.hasOwnProperty;function hQ(t,e){var n=aQ(t),r=!n&&oQ(t),i=!n&&!r&&lQ(t),s=!n&&!r&&!i&&cQ(t),o=n||r||i||s,a=o?sQ(t.length,String):[],l=a.length;for(var u in t)(e||dQ.call(t,u))&&!(o&&(u=="length"||i&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||uQ(u,l)))&&a.push(u);return a}var pQ=hQ,mQ=Object.prototype;function gQ(t){var e=t&&t.constructor,n=typeof e=="function"&&e.prototype||mQ;return t===n}var vQ=gQ;function yQ(t,e){return function(n){return t(e(n))}}var _Q=yQ,wQ=_Q,bQ=wQ(Object.keys,Object),EQ=bQ,xQ=vQ,TQ=EQ,SQ=Object.prototype,kQ=SQ.hasOwnProperty;function AQ(t){if(!xQ(t))return TQ(t);var e=[];for(var n in Object(t))kQ.call(t,n)&&n!="constructor"&&e.push(n);return e}var IQ=AQ,OQ=eC,PQ=oC;function RQ(t){return t!=null&&PQ(t.length)&&!OQ(t)}var CQ=RQ,NQ=pQ,DQ=IQ,MQ=CQ;function LQ(t){return MQ(t)?NQ(t):DQ(t)}var jQ=LQ,FQ=WK,VQ=nY,UQ=jQ;function $Q(t){return FQ(t,UQ,VQ)}var BQ=$Q,eS=BQ,zQ=1,qQ=Object.prototype,HQ=qQ.hasOwnProperty;function WQ(t,e,n,r,i,s){var o=n&zQ,a=eS(t),l=a.length,u=eS(e),c=u.length;if(l!=c&&!o)return!1;for(var d=l;d--;){var f=a[d];if(!(o?f in e:HQ.call(e,f)))return!1}var p=s.get(t),_=s.get(e);if(p&&_)return p==e&&_==t;var y=!0;s.set(t,e),s.set(e,t);for(var w=o;++d<l;){f=a[d];var g=t[f],m=e[f];if(r)var b=o?r(m,g,f,e,t,s):r(g,m,f,t,e,s);if(!(b===void 0?g===m||i(g,m,n,r,s):b)){y=!1;break}w||(w=f=="constructor")}if(y&&!w){var v=t.constructor,A=e.constructor;v!=A&&"constructor"in t&&"constructor"in e&&!(typeof v=="function"&&v instanceof v&&typeof A=="function"&&A instanceof A)&&(y=!1)}return s.delete(t),s.delete(e),y}var GQ=WQ,KQ=Wu,YQ=$s,QQ=KQ(YQ,"DataView"),ZQ=QQ,XQ=Wu,JQ=$s,eZ=XQ(JQ,"Promise"),tZ=eZ,nZ=Wu,rZ=$s,iZ=nZ(rZ,"Set"),sZ=iZ,oZ=Wu,aZ=$s,lZ=oZ(aZ,"WeakMap"),uZ=lZ,w0=ZQ,b0=kw,E0=tZ,x0=sZ,T0=uZ,lC=ug,Qu=tC,tS="[object Map]",cZ="[object Object]",nS="[object Promise]",rS="[object Set]",iS="[object WeakMap]",sS="[object DataView]",fZ=Qu(w0),dZ=Qu(b0),hZ=Qu(E0),pZ=Qu(x0),mZ=Qu(T0),ha=lC;(w0&&ha(new w0(new ArrayBuffer(1)))!=sS||b0&&ha(new b0)!=tS||E0&&ha(E0.resolve())!=nS||x0&&ha(new x0)!=rS||T0&&ha(new T0)!=iS)&&(ha=function(t){var e=lC(t),n=e==cZ?t.constructor:void 0,r=n?Qu(n):"";if(r)switch(r){case fZ:return sS;case dZ:return tS;case hZ:return nS;case pZ:return rS;case mZ:return iS}return e});var gZ=ha,xv=KG,vZ=rC,yZ=VK,_Z=GQ,oS=gZ,aS=Aw,lS=sC,wZ=aC,bZ=1,uS="[object Arguments]",cS="[object Array]",lh="[object Object]",EZ=Object.prototype,fS=EZ.hasOwnProperty;function xZ(t,e,n,r,i,s){var o=aS(t),a=aS(e),l=o?cS:oS(t),u=a?cS:oS(e);l=l==uS?lh:l,u=u==uS?lh:u;var c=l==lh,d=u==lh,f=l==u;if(f&&lS(t)){if(!lS(e))return!1;o=!0,c=!1}if(f&&!c)return s||(s=new xv),o||wZ(t)?vZ(t,e,n,r,i,s):yZ(t,e,l,n,r,i,s);if(!(n&bZ)){var p=c&&fS.call(t,"__wrapped__"),_=d&&fS.call(e,"__wrapped__");if(p||_){var y=p?t.value():t,w=_?e.value():e;return s||(s=new xv),i(y,w,n,r,s)}}return f?(s||(s=new xv),_Z(t,e,n,r,i,s)):!1}var TZ=xZ,SZ=TZ,dS=dg;function uC(t,e,n,r,i){return t===e?!0:t==null||e==null||!dS(t)&&!dS(e)?t!==t&&e!==e:SZ(t,e,n,r,uC,i)}var kZ=uC,AZ=kZ;function IZ(t,e){return AZ(t,e)}var OZ=IZ,cC={exports:{}};/*! 3728 * Quill Editor v1.3.7 3729 * https://quilljs.com/ 3730 * Copyright (c) 2014, Jason Chen 3731 * Copyright (c) 2013, salesforce.com 3732 */(function(t,e){(function(r,i){t.exports=i()})(typeof self<"u"?self:br,function(){return function(n){var r={};function i(s){if(r[s])return r[s].exports;var o=r[s]={i:s,l:!1,exports:{}};return n[s].call(o.exports,o,o.exports,i),o.l=!0,o.exports}return i.m=n,i.c=r,i.d=function(s,o,a){i.o(s,o)||Object.defineProperty(s,o,{configurable:!1,enumerable:!0,get:a})},i.n=function(s){var o=s&&s.__esModule?function(){return s.default}:function(){return s};return i.d(o,"a",o),o},i.o=function(s,o){return Object.prototype.hasOwnProperty.call(s,o)},i.p="",i(i.s=109)}([function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(17),o=i(18),a=i(19),l=i(45),u=i(46),c=i(47),d=i(48),f=i(49),p=i(12),_=i(32),y=i(33),w=i(31),g=i(1),m={Scope:g.Scope,create:g.create,find:g.find,query:g.query,register:g.register,Container:s.default,Format:o.default,Leaf:a.default,Embed:d.default,Scroll:l.default,Block:c.default,Inline:u.default,Text:f.default,Attributor:{Attribute:p.default,Class:_.default,Style:y.default,Store:w.default}};r.default=m},function(n,r,i){var s=this&&this.__extends||function(){var w=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,m){g.__proto__=m}||function(g,m){for(var b in m)m.hasOwnProperty(b)&&(g[b]=m[b])};return function(g,m){w(g,m);function b(){this.constructor=g}g.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=function(w){s(g,w);function g(m){var b=this;return m="[Parchment] "+m,b=w.call(this,m)||this,b.message=m,b.name=b.constructor.name,b}return g}(Error);r.ParchmentError=o;var a={},l={},u={},c={};r.DATA_KEY="__blot";var d;(function(w){w[w.TYPE=3]="TYPE",w[w.LEVEL=12]="LEVEL",w[w.ATTRIBUTE=13]="ATTRIBUTE",w[w.BLOT=14]="BLOT",w[w.INLINE=7]="INLINE",w[w.BLOCK=11]="BLOCK",w[w.BLOCK_BLOT=10]="BLOCK_BLOT",w[w.INLINE_BLOT=6]="INLINE_BLOT",w[w.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",w[w.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",w[w.ANY=15]="ANY"})(d=r.Scope||(r.Scope={}));function f(w,g){var m=_(w);if(m==null)throw new o("Unable to create "+w+" blot");var b=m,v=w instanceof Node||w.nodeType===Node.TEXT_NODE?w:b.create(g);return new b(v,g)}r.create=f;function p(w,g){return g===void 0&&(g=!1),w==null?null:w[r.DATA_KEY]!=null?w[r.DATA_KEY].blot:g?p(w.parentNode,g):null}r.find=p;function _(w,g){g===void 0&&(g=d.ANY);var m;if(typeof w=="string")m=c[w]||a[w];else if(w instanceof Text||w.nodeType===Node.TEXT_NODE)m=c.text;else if(typeof w=="number")w&d.LEVEL&d.BLOCK?m=c.block:w&d.LEVEL&d.INLINE&&(m=c.inline);else if(w instanceof HTMLElement){var b=(w.getAttribute("class")||"").split(/\s+/);for(var v in b)if(m=l[b[v]],m)break;m=m||u[w.tagName]}return m==null?null:g&d.LEVEL&m.scope&&g&d.TYPE&m.scope?m:null}r.query=_;function y(){for(var w=[],g=0;g<arguments.length;g++)w[g]=arguments[g];if(w.length>1)return w.map(function(v){return y(v)});var m=w[0];if(typeof m.blotName!="string"&&typeof m.attrName!="string")throw new o("Invalid definition");if(m.blotName==="abstract")throw new o("Cannot register abstract class");if(c[m.blotName||m.attrName]=m,typeof m.keyName=="string")a[m.keyName]=m;else if(m.className!=null&&(l[m.className]=m),m.tagName!=null){Array.isArray(m.tagName)?m.tagName=m.tagName.map(function(v){return v.toUpperCase()}):m.tagName=m.tagName.toUpperCase();var b=Array.isArray(m.tagName)?m.tagName:[m.tagName];b.forEach(function(v){(u[v]==null||m.className==null)&&(u[v]=m)})}return m}r.register=y},function(n,r,i){var s=i(51),o=i(11),a=i(3),l=i(20),u="\0",c=function(d){Array.isArray(d)?this.ops=d:d!=null&&Array.isArray(d.ops)?this.ops=d.ops:this.ops=[]};c.prototype.insert=function(d,f){var p={};return d.length===0?this:(p.insert=d,f!=null&&typeof f=="object"&&Object.keys(f).length>0&&(p.attributes=f),this.push(p))},c.prototype.delete=function(d){return d<=0?this:this.push({delete:d})},c.prototype.retain=function(d,f){if(d<=0)return this;var p={retain:d};return f!=null&&typeof f=="object"&&Object.keys(f).length>0&&(p.attributes=f),this.push(p)},c.prototype.push=function(d){var f=this.ops.length,p=this.ops[f-1];if(d=a(!0,{},d),typeof p=="object"){if(typeof d.delete=="number"&&typeof p.delete=="number")return this.ops[f-1]={delete:p.delete+d.delete},this;if(typeof p.delete=="number"&&d.insert!=null&&(f-=1,p=this.ops[f-1],typeof p!="object"))return this.ops.unshift(d),this;if(o(d.attributes,p.attributes)){if(typeof d.insert=="string"&&typeof p.insert=="string")return this.ops[f-1]={insert:p.insert+d.insert},typeof d.attributes=="object"&&(this.ops[f-1].attributes=d.attributes),this;if(typeof d.retain=="number"&&typeof p.retain=="number")return this.ops[f-1]={retain:p.retain+d.retain},typeof d.attributes=="object"&&(this.ops[f-1].attributes=d.attributes),this}}return f===this.ops.length?this.ops.push(d):this.ops.splice(f,0,d),this},c.prototype.chop=function(){var d=this.ops[this.ops.length-1];return d&&d.retain&&!d.attributes&&this.ops.pop(),this},c.prototype.filter=function(d){return this.ops.filter(d)},c.prototype.forEach=function(d){this.ops.forEach(d)},c.prototype.map=function(d){return this.ops.map(d)},c.prototype.partition=function(d){var f=[],p=[];return this.forEach(function(_){var y=d(_)?f:p;y.push(_)}),[f,p]},c.prototype.reduce=function(d,f){return this.ops.reduce(d,f)},c.prototype.changeLength=function(){return this.reduce(function(d,f){return f.insert?d+l.length(f):f.delete?d-f.delete:d},0)},c.prototype.length=function(){return this.reduce(function(d,f){return d+l.length(f)},0)},c.prototype.slice=function(d,f){d=d||0,typeof f!="number"&&(f=1/0);for(var p=[],_=l.iterator(this.ops),y=0;y<f&&_.hasNext();){var w;y<d?w=_.next(d-y):(w=_.next(f-y),p.push(w)),y+=l.length(w)}return new c(p)},c.prototype.compose=function(d){var f=l.iterator(this.ops),p=l.iterator(d.ops),_=[],y=p.peek();if(y!=null&&typeof y.retain=="number"&&y.attributes==null){for(var w=y.retain;f.peekType()==="insert"&&f.peekLength()<=w;)w-=f.peekLength(),_.push(f.next());y.retain-w>0&&p.next(y.retain-w)}for(var g=new c(_);f.hasNext()||p.hasNext();)if(p.peekType()==="insert")g.push(p.next());else if(f.peekType()==="delete")g.push(f.next());else{var m=Math.min(f.peekLength(),p.peekLength()),b=f.next(m),v=p.next(m);if(typeof v.retain=="number"){var A={};typeof b.retain=="number"?A.retain=m:A.insert=b.insert;var N=l.attributes.compose(b.attributes,v.attributes,typeof b.retain=="number");if(N&&(A.attributes=N),g.push(A),!p.hasNext()&&o(g.ops[g.ops.length-1],A)){var x=new c(f.rest());return g.concat(x).chop()}}else typeof v.delete=="number"&&typeof b.retain=="number"&&g.push(v)}return g.chop()},c.prototype.concat=function(d){var f=new c(this.ops.slice());return d.ops.length>0&&(f.push(d.ops[0]),f.ops=f.ops.concat(d.ops.slice(1))),f},c.prototype.diff=function(d,f){if(this.ops===d.ops)return new c;var p=[this,d].map(function(m){return m.map(function(b){if(b.insert!=null)return typeof b.insert=="string"?b.insert:u;var v=m===d?"on":"with";throw new Error("diff() called "+v+" non-document")}).join("")}),_=new c,y=s(p[0],p[1],f),w=l.iterator(this.ops),g=l.iterator(d.ops);return y.forEach(function(m){for(var b=m[1].length;b>0;){var v=0;switch(m[0]){case s.INSERT:v=Math.min(g.peekLength(),b),_.push(g.next(v));break;case s.DELETE:v=Math.min(b,w.peekLength()),w.next(v),_.delete(v);break;case s.EQUAL:v=Math.min(w.peekLength(),g.peekLength(),b);var A=w.next(v),N=g.next(v);o(A.insert,N.insert)?_.retain(v,l.attributes.diff(A.attributes,N.attributes)):_.push(N).delete(v);break}b-=v}}),_.chop()},c.prototype.eachLine=function(d,f){f=f||` 3733`;for(var p=l.iterator(this.ops),_=new c,y=0;p.hasNext();){if(p.peekType()!=="insert")return;var w=p.peek(),g=l.length(w)-p.peekLength(),m=typeof w.insert=="string"?w.insert.indexOf(f,g)-g:-1;if(m<0)_.push(p.next());else if(m>0)_.push(p.next(m));else{if(d(_,p.next(1).attributes||{},y)===!1)return;y+=1,_=new c}}_.length()>0&&d(_,{},y)},c.prototype.transform=function(d,f){if(f=!!f,typeof d=="number")return this.transformPosition(d,f);for(var p=l.iterator(this.ops),_=l.iterator(d.ops),y=new c;p.hasNext()||_.hasNext();)if(p.peekType()==="insert"&&(f||_.peekType()!=="insert"))y.retain(l.length(p.next()));else if(_.peekType()==="insert")y.push(_.next());else{var w=Math.min(p.peekLength(),_.peekLength()),g=p.next(w),m=_.next(w);if(g.delete)continue;m.delete?y.push(m):y.retain(w,l.attributes.transform(g.attributes,m.attributes,f))}return y.chop()},c.prototype.transformPosition=function(d,f){f=!!f;for(var p=l.iterator(this.ops),_=0;p.hasNext()&&_<=d;){var y=p.peekLength(),w=p.peekType();if(p.next(),w==="delete"){d-=Math.min(y,d-_);continue}else w==="insert"&&(_<d||!f)&&(d+=y);_+=y}return d},n.exports=c},function(n,r){var i=Object.prototype.hasOwnProperty,s=Object.prototype.toString,o=Object.defineProperty,a=Object.getOwnPropertyDescriptor,l=function(p){return typeof Array.isArray=="function"?Array.isArray(p):s.call(p)==="[object Array]"},u=function(p){if(!p||s.call(p)!=="[object Object]")return!1;var _=i.call(p,"constructor"),y=p.constructor&&p.constructor.prototype&&i.call(p.constructor.prototype,"isPrototypeOf");if(p.constructor&&!_&&!y)return!1;var w;for(w in p);return typeof w>"u"||i.call(p,w)},c=function(p,_){o&&_.name==="__proto__"?o(p,_.name,{enumerable:!0,configurable:!0,value:_.newValue,writable:!0}):p[_.name]=_.newValue},d=function(p,_){if(_==="__proto__")if(i.call(p,_)){if(a)return a(p,_).value}else return;return p[_]};n.exports=function f(){var p,_,y,w,g,m,b=arguments[0],v=1,A=arguments.length,N=!1;for(typeof b=="boolean"&&(N=b,b=arguments[1]||{},v=2),(b==null||typeof b!="object"&&typeof b!="function")&&(b={});v<A;++v)if(p=arguments[v],p!=null)for(_ in p)y=d(b,_),w=d(p,_),b!==w&&(N&&w&&(u(w)||(g=l(w)))?(g?(g=!1,m=y&&l(y)?y:[]):m=y&&u(y)?y:{},c(b,{name:_,newValue:f(N,m,w)})):typeof w<"u"&&c(b,{name:_,newValue:w}));return b}},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BlockEmbed=r.bubbleFormats=void 0;var s=function(){function k(I,P){for(var M=0;M<P.length;M++){var $=P[M];$.enumerable=$.enumerable||!1,$.configurable=!0,"value"in $&&($.writable=!0),Object.defineProperty(I,$.key,$)}}return function(I,P,M){return P&&k(I.prototype,P),M&&k(I,M),I}}(),o=function k(I,P,M){I===null&&(I=Function.prototype);var $=Object.getOwnPropertyDescriptor(I,P);if($===void 0){var Z=Object.getPrototypeOf(I);return Z===null?void 0:k(Z,P,M)}else{if("value"in $)return $.value;var Q=$.get;return Q===void 0?void 0:Q.call(M)}},a=i(3),l=b(a),u=i(2),c=b(u),d=i(0),f=b(d),p=i(16),_=b(p),y=i(6),w=b(y),g=i(7),m=b(g);function b(k){return k&&k.__esModule?k:{default:k}}function v(k,I){if(!(k instanceof I))throw new TypeError("Cannot call a class as a function")}function A(k,I){if(!k)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return I&&(typeof I=="object"||typeof I=="function")?I:k}function N(k,I){if(typeof I!="function"&&I!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof I);k.prototype=Object.create(I&&I.prototype,{constructor:{value:k,enumerable:!1,writable:!0,configurable:!0}}),I&&(Object.setPrototypeOf?Object.setPrototypeOf(k,I):k.__proto__=I)}var x=1,E=function(k){N(I,k);function I(){return v(this,I),A(this,(I.__proto__||Object.getPrototypeOf(I)).apply(this,arguments))}return s(I,[{key:"attach",value:function(){o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"attach",this).call(this),this.attributes=new f.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return new c.default().insert(this.value(),(0,l.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(M,$){var Z=f.default.query(M,f.default.Scope.BLOCK_ATTRIBUTE);Z!=null&&this.attributes.attribute(Z,$)}},{key:"formatAt",value:function(M,$,Z,Q){this.format(Z,Q)}},{key:"insertAt",value:function(M,$,Z){if(typeof $=="string"&&$.endsWith(` 3734`)){var Q=f.default.create(T.blotName);this.parent.insertBefore(Q,M===0?this:this.next),Q.insertAt(0,$.slice(0,-1))}else o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"insertAt",this).call(this,M,$,Z)}}]),I}(f.default.Embed);E.scope=f.default.Scope.BLOCK_BLOT;var T=function(k){N(I,k);function I(P){v(this,I);var M=A(this,(I.__proto__||Object.getPrototypeOf(I)).call(this,P));return M.cache={},M}return s(I,[{key:"delta",value:function(){return this.cache.delta==null&&(this.cache.delta=this.descendants(f.default.Leaf).reduce(function(M,$){return $.length()===0?M:M.insert($.value(),S($))},new c.default).insert(` 3735`,S(this))),this.cache.delta}},{key:"deleteAt",value:function(M,$){o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"deleteAt",this).call(this,M,$),this.cache={}}},{key:"formatAt",value:function(M,$,Z,Q){$<=0||(f.default.query(Z,f.default.Scope.BLOCK)?M+$===this.length()&&this.format(Z,Q):o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"formatAt",this).call(this,M,Math.min($,this.length()-M-1),Z,Q),this.cache={})}},{key:"insertAt",value:function(M,$,Z){if(Z!=null)return o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"insertAt",this).call(this,M,$,Z);if($.length!==0){var Q=$.split(` 3736`),K=Q.shift();K.length>0&&(M<this.length()-1||this.children.tail==null?o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"insertAt",this).call(this,Math.min(M,this.length()-1),K):this.children.tail.insertAt(this.children.tail.length(),K),this.cache={});var B=this;Q.reduce(function(V,D){return B=B.split(V,!0),B.insertAt(0,D),D.length},M+K.length)}}},{key:"insertBefore",value:function(M,$){var Z=this.children.head;o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"insertBefore",this).call(this,M,$),Z instanceof _.default&&Z.remove(),this.cache={}}},{key:"length",value:function(){return this.cache.length==null&&(this.cache.length=o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"length",this).call(this)+x),this.cache.length}},{key:"moveChildren",value:function(M,$){o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"moveChildren",this).call(this,M,$),this.cache={}}},{key:"optimize",value:function(M){o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"optimize",this).call(this,M),this.cache={}}},{key:"path",value:function(M){return o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"path",this).call(this,M,!0)}},{key:"removeChild",value:function(M){o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"removeChild",this).call(this,M),this.cache={}}},{key:"split",value:function(M){var $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if($&&(M===0||M>=this.length()-x)){var Z=this.clone();return M===0?(this.parent.insertBefore(Z,this),this):(this.parent.insertBefore(Z,this.next),Z)}else{var Q=o(I.prototype.__proto__||Object.getPrototypeOf(I.prototype),"split",this).call(this,M,$);return this.cache={},Q}}}]),I}(f.default.Block);T.blotName="block",T.tagName="P",T.defaultChild="break",T.allowedChildren=[w.default,f.default.Embed,m.default];function S(k){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return k==null||(typeof k.formats=="function"&&(I=(0,l.default)(I,k.formats())),k.parent==null||k.parent.blotName=="scroll"||k.parent.statics.scope!==k.statics.scope)?I:S(k.parent,I)}r.bubbleFormats=S,r.BlockEmbed=E,r.default=T},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.overload=r.expandConfig=void 0;var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(B){return typeof B}:function(B){return B&&typeof Symbol=="function"&&B.constructor===Symbol&&B!==Symbol.prototype?"symbol":typeof B},o=function(){function B(V,D){var j=[],U=!0,Y=!1,W=void 0;try{for(var F=V[Symbol.iterator](),q;!(U=(q=F.next()).done)&&(j.push(q.value),!(D&&j.length===D));U=!0);}catch(ee){Y=!0,W=ee}finally{try{!U&&F.return&&F.return()}finally{if(Y)throw W}}return j}return function(V,D){if(Array.isArray(V))return V;if(Symbol.iterator in Object(V))return B(V,D);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(){function B(V,D){for(var j=0;j<D.length;j++){var U=D[j];U.enumerable=U.enumerable||!1,U.configurable=!0,"value"in U&&(U.writable=!0),Object.defineProperty(V,U.key,U)}}return function(V,D,j){return D&&B(V.prototype,D),j&&B(V,j),V}}();i(50);var l=i(2),u=S(l),c=i(14),d=S(c),f=i(8),p=S(f),_=i(9),y=S(_),w=i(0),g=S(w),m=i(15),b=S(m),v=i(3),A=S(v),N=i(10),x=S(N),E=i(34),T=S(E);function S(B){return B&&B.__esModule?B:{default:B}}function k(B,V,D){return V in B?Object.defineProperty(B,V,{value:D,enumerable:!0,configurable:!0,writable:!0}):B[V]=D,B}function I(B,V){if(!(B instanceof V))throw new TypeError("Cannot call a class as a function")}var P=(0,x.default)("quill"),M=function(){a(B,null,[{key:"debug",value:function(D){D===!0&&(D="log"),x.default.level(D)}},{key:"find",value:function(D){return D.__quill||g.default.find(D)}},{key:"import",value:function(D){return this.imports[D]==null&&P.error("Cannot import "+D+". Are you sure it was registered?"),this.imports[D]}},{key:"register",value:function(D,j){var U=this,Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(typeof D!="string"){var W=D.attrName||D.blotName;typeof W=="string"?this.register("formats/"+W,D,j):Object.keys(D).forEach(function(F){U.register(F,D[F],j)})}else this.imports[D]!=null&&!Y&&P.warn("Overwriting "+D+" with",j),this.imports[D]=j,(D.startsWith("blots/")||D.startsWith("formats/"))&&j.blotName!=="abstract"?g.default.register(j):D.startsWith("modules")&&typeof j.register=="function"&&j.register()}}]);function B(V){var D=this,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(I(this,B),this.options=$(V,j),this.container=this.options.container,this.container==null)return P.error("Invalid Quill container",V);this.options.debug&&B.debug(this.options.debug);var U=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new p.default,this.scroll=g.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new d.default(this.scroll),this.selection=new b.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(p.default.events.EDITOR_CHANGE,function(W){W===p.default.events.TEXT_CHANGE&&D.root.classList.toggle("ql-blank",D.editor.isBlank())}),this.emitter.on(p.default.events.SCROLL_UPDATE,function(W,F){var q=D.selection.lastRange,ee=q&&q.length===0?q.index:void 0;Z.call(D,function(){return D.editor.update(null,F,ee)},W)});var Y=this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">`+U+"<p><br></p></div>");this.setContents(Y),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return a(B,[{key:"addContainer",value:function(D){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof D=="string"){var U=D;D=document.createElement("div"),D.classList.add(U)}return this.container.insertBefore(D,j),D}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(D,j,U){var Y=this,W=Q(D,j,U),F=o(W,4);return D=F[0],j=F[1],U=F[3],Z.call(this,function(){return Y.editor.deleteText(D,j)},U,D,-1*j)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(D),this.container.classList.toggle("ql-disabled",!D)}},{key:"focus",value:function(){var D=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=D,this.scrollIntoView()}},{key:"format",value:function(D,j){var U=this,Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:p.default.sources.API;return Z.call(this,function(){var W=U.getSelection(!0),F=new u.default;if(W==null)return F;if(g.default.query(D,g.default.Scope.BLOCK))F=U.editor.formatLine(W.index,W.length,k({},D,j));else{if(W.length===0)return U.selection.format(D,j),F;F=U.editor.formatText(W.index,W.length,k({},D,j))}return U.setSelection(W,p.default.sources.SILENT),F},Y)}},{key:"formatLine",value:function(D,j,U,Y,W){var F=this,q=void 0,ee=Q(D,j,U,Y,W),te=o(ee,4);return D=te[0],j=te[1],q=te[2],W=te[3],Z.call(this,function(){return F.editor.formatLine(D,j,q)},W,D,0)}},{key:"formatText",value:function(D,j,U,Y,W){var F=this,q=void 0,ee=Q(D,j,U,Y,W),te=o(ee,4);return D=te[0],j=te[1],q=te[2],W=te[3],Z.call(this,function(){return F.editor.formatText(D,j,q)},W,D,0)}},{key:"getBounds",value:function(D){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,U=void 0;typeof D=="number"?U=this.selection.getBounds(D,j):U=this.selection.getBounds(D.index,D.length);var Y=this.container.getBoundingClientRect();return{bottom:U.bottom-Y.top,height:U.height,left:U.left-Y.left,right:U.right-Y.left,top:U.top-Y.top,width:U.width}}},{key:"getContents",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-D,U=Q(D,j),Y=o(U,2);return D=Y[0],j=Y[1],this.editor.getContents(D,j)}},{key:"getFormat",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof D=="number"?this.editor.getFormat(D,j):this.editor.getFormat(D.index,D.length)}},{key:"getIndex",value:function(D){return D.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(D){return this.scroll.leaf(D)}},{key:"getLine",value:function(D){return this.scroll.line(D)}},{key:"getLines",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof D!="number"?this.scroll.lines(D.index,D.length):this.scroll.lines(D,j)}},{key:"getModule",value:function(D){return this.theme.modules[D]}},{key:"getSelection",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return D&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-D,U=Q(D,j),Y=o(U,2);return D=Y[0],j=Y[1],this.editor.getText(D,j)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(D,j,U){var Y=this,W=arguments.length>3&&arguments[3]!==void 0?arguments[3]:B.sources.API;return Z.call(this,function(){return Y.editor.insertEmbed(D,j,U)},W,D)}},{key:"insertText",value:function(D,j,U,Y,W){var F=this,q=void 0,ee=Q(D,0,U,Y,W),te=o(ee,4);return D=te[0],q=te[2],W=te[3],Z.call(this,function(){return F.editor.insertText(D,j,q)},W,D,j.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(D,j,U){this.clipboard.dangerouslyPasteHTML(D,j,U)}},{key:"removeFormat",value:function(D,j,U){var Y=this,W=Q(D,j,U),F=o(W,4);return D=F[0],j=F[1],U=F[3],Z.call(this,function(){return Y.editor.removeFormat(D,j)},U,D)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(D){var j=this,U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API;return Z.call(this,function(){D=new u.default(D);var Y=j.getLength(),W=j.editor.deleteText(0,Y),F=j.editor.applyDelta(D),q=F.ops[F.ops.length-1];q!=null&&typeof q.insert=="string"&&q.insert[q.insert.length-1]===` 3737`&&(j.editor.deleteText(j.getLength()-1,1),F.delete(1));var ee=W.compose(F);return ee},U)}},{key:"setSelection",value:function(D,j,U){if(D==null)this.selection.setRange(null,j||B.sources.API);else{var Y=Q(D,j,U),W=o(Y,4);D=W[0],j=W[1],U=W[3],this.selection.setRange(new m.Range(D,j),U),U!==p.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(D){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API,U=new u.default().insert(D);return this.setContents(U,j)}},{key:"update",value:function(){var D=arguments.length>0&&arguments[0]!==void 0?arguments[0]:p.default.sources.USER,j=this.scroll.update(D);return this.selection.update(D),j}},{key:"updateContents",value:function(D){var j=this,U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API;return Z.call(this,function(){return D=new u.default(D),j.editor.applyDelta(D,U)},U,!0)}}]),B}();M.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},M.events=p.default.events,M.sources=p.default.sources,M.version="1.3.7",M.imports={delta:u.default,parchment:g.default,"core/module":y.default,"core/theme":T.default};function $(B,V){if(V=(0,A.default)(!0,{container:B,modules:{clipboard:!0,keyboard:!0,history:!0}},V),!V.theme||V.theme===M.DEFAULTS.theme)V.theme=T.default;else if(V.theme=M.import("themes/"+V.theme),V.theme==null)throw new Error("Invalid theme "+V.theme+". Did you register it?");var D=(0,A.default)(!0,{},V.theme.DEFAULTS);[D,V].forEach(function(Y){Y.modules=Y.modules||{},Object.keys(Y.modules).forEach(function(W){Y.modules[W]===!0&&(Y.modules[W]={})})});var j=Object.keys(D.modules).concat(Object.keys(V.modules)),U=j.reduce(function(Y,W){var F=M.import("modules/"+W);return F==null?P.error("Cannot load "+W+" module. Are you sure you registered it?"):Y[W]=F.DEFAULTS||{},Y},{});return V.modules!=null&&V.modules.toolbar&&V.modules.toolbar.constructor!==Object&&(V.modules.toolbar={container:V.modules.toolbar}),V=(0,A.default)(!0,{},M.DEFAULTS,{modules:U},D,V),["bounds","container","scrollingContainer"].forEach(function(Y){typeof V[Y]=="string"&&(V[Y]=document.querySelector(V[Y]))}),V.modules=Object.keys(V.modules).reduce(function(Y,W){return V.modules[W]&&(Y[W]=V.modules[W]),Y},{}),V}function Z(B,V,D,j){if(this.options.strict&&!this.isEnabled()&&V===p.default.sources.USER)return new u.default;var U=D==null?null:this.getSelection(),Y=this.editor.delta,W=B();if(U!=null&&(D===!0&&(D=U.index),j==null?U=K(U,W,V):j!==0&&(U=K(U,D,j,V)),this.setSelection(U,p.default.sources.SILENT)),W.length()>0){var F,q=[p.default.events.TEXT_CHANGE,W,Y,V];if((F=this.emitter).emit.apply(F,[p.default.events.EDITOR_CHANGE].concat(q)),V!==p.default.sources.SILENT){var ee;(ee=this.emitter).emit.apply(ee,q)}}return W}function Q(B,V,D,j,U){var Y={};return typeof B.index=="number"&&typeof B.length=="number"?typeof V!="number"?(U=j,j=D,D=V,V=B.length,B=B.index):(V=B.length,B=B.index):typeof V!="number"&&(U=j,j=D,D=V,V=0),(typeof D>"u"?"undefined":s(D))==="object"?(Y=D,U=j):typeof D=="string"&&(j!=null?Y[D]=j:U=D),U=U||p.default.sources.API,[B,V,Y,U]}function K(B,V,D,j){if(B==null)return null;var U=void 0,Y=void 0;if(V instanceof u.default){var W=[B.index,B.index+B.length].map(function(te){return V.transformPosition(te,j!==p.default.sources.USER)}),F=o(W,2);U=F[0],Y=F[1]}else{var q=[B.index,B.index+B.length].map(function(te){return te<V||te===V&&j===p.default.sources.USER?te:D>=0?te+D:Math.max(V,te+D)}),ee=o(q,2);U=ee[0],Y=ee[1]}return new m.Range(U,Y-U)}r.expandConfig=$,r.overload=Q,r.default=M},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function w(g,m){for(var b=0;b<m.length;b++){var v=m[b];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(g,v.key,v)}}return function(g,m,b){return m&&w(g.prototype,m),b&&w(g,b),g}}(),o=function w(g,m,b){g===null&&(g=Function.prototype);var v=Object.getOwnPropertyDescriptor(g,m);if(v===void 0){var A=Object.getPrototypeOf(g);return A===null?void 0:w(A,m,b)}else{if("value"in v)return v.value;var N=v.get;return N===void 0?void 0:N.call(b)}},a=i(7),l=d(a),u=i(0),c=d(u);function d(w){return w&&w.__esModule?w:{default:w}}function f(w,g){if(!(w instanceof g))throw new TypeError("Cannot call a class as a function")}function p(w,g){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:w}function _(w,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);w.prototype=Object.create(g&&g.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(w,g):w.__proto__=g)}var y=function(w){_(g,w);function g(){return f(this,g),p(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"formatAt",value:function(b,v,A,N){if(g.compare(this.statics.blotName,A)<0&&c.default.query(A,c.default.Scope.BLOT)){var x=this.isolate(b,v);N&&x.wrap(A,N)}else o(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"formatAt",this).call(this,b,v,A,N)}},{key:"optimize",value:function(b){if(o(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"optimize",this).call(this,b),this.parent instanceof g&&g.compare(this.statics.blotName,this.parent.statics.blotName)>0){var v=this.parent.isolate(this.offset(),this.length());this.moveChildren(v),v.wrap(this)}}}],[{key:"compare",value:function(b,v){var A=g.order.indexOf(b),N=g.order.indexOf(v);return A>=0||N>=0?A-N:b===v?0:b<v?-1:1}}]),g}(c.default.Inline);y.allowedChildren=[y,c.default.Embed,l.default],y.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],r.default=y},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(0),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}function l(f,p){if(!(f instanceof p))throw new TypeError("Cannot call a class as a function")}function u(f,p){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:f}function c(f,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);f.prototype=Object.create(p&&p.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(f,p):f.__proto__=p)}var d=function(f){c(p,f);function p(){return l(this,p),u(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p}(o.default.Text);r.default=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function m(b,v){for(var A=0;A<v.length;A++){var N=v[A];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(b,N.key,N)}}return function(b,v,A){return v&&m(b.prototype,v),A&&m(b,A),b}}(),o=function m(b,v,A){b===null&&(b=Function.prototype);var N=Object.getOwnPropertyDescriptor(b,v);if(N===void 0){var x=Object.getPrototypeOf(b);return x===null?void 0:m(x,v,A)}else{if("value"in N)return N.value;var E=N.get;return E===void 0?void 0:E.call(A)}},a=i(54),l=d(a),u=i(10),c=d(u);function d(m){return m&&m.__esModule?m:{default:m}}function f(m,b){if(!(m instanceof b))throw new TypeError("Cannot call a class as a function")}function p(m,b){if(!m)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:m}function _(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);m.prototype=Object.create(b&&b.prototype,{constructor:{value:m,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(m,b):m.__proto__=b)}var y=(0,c.default)("quill:events"),w=["selectionchange","mousedown","mouseup","click"];w.forEach(function(m){document.addEventListener(m,function(){for(var b=arguments.length,v=Array(b),A=0;A<b;A++)v[A]=arguments[A];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(N){if(N.__quill&&N.__quill.emitter){var x;(x=N.__quill.emitter).handleDOM.apply(x,v)}})})});var g=function(m){_(b,m);function b(){f(this,b);var v=p(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return v.listeners={},v.on("error",y.error),v}return s(b,[{key:"emit",value:function(){y.log.apply(y,arguments),o(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(A){for(var N=arguments.length,x=Array(N>1?N-1:0),E=1;E<N;E++)x[E-1]=arguments[E];(this.listeners[A.type]||[]).forEach(function(T){var S=T.node,k=T.handler;(A.target===S||S.contains(A.target))&&k.apply(void 0,[A].concat(x))})}},{key:"listenDOM",value:function(A,N,x){this.listeners[A]||(this.listeners[A]=[]),this.listeners[A].push({node:N,handler:x})}}]),b}(l.default);g.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},g.sources={API:"api",SILENT:"silent",USER:"user"},r.default=g},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});function s(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")}var o=function a(l){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};s(this,a),this.quill=l,this.options=u};o.DEFAULTS={},r.default=o},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=["error","warn","log","info"],o="warn";function a(u){if(s.indexOf(u)<=s.indexOf(o)){for(var c,d=arguments.length,f=Array(d>1?d-1:0),p=1;p<d;p++)f[p-1]=arguments[p];(c=console)[u].apply(c,f)}}function l(u){return s.reduce(function(c,d){return c[d]=a.bind(console,d,u),c},{})}a.level=l.level=function(u){o=u},r.default=l},function(n,r,i){var s=Array.prototype.slice,o=i(52),a=i(53),l=n.exports=function(f,p,_){return _||(_={}),f===p?!0:f instanceof Date&&p instanceof Date?f.getTime()===p.getTime():!f||!p||typeof f!="object"&&typeof p!="object"?_.strict?f===p:f==p:d(f,p,_)};function u(f){return f==null}function c(f){return!(!f||typeof f!="object"||typeof f.length!="number"||typeof f.copy!="function"||typeof f.slice!="function"||f.length>0&&typeof f[0]!="number")}function d(f,p,_){var y,w;if(u(f)||u(p)||f.prototype!==p.prototype)return!1;if(a(f))return a(p)?(f=s.call(f),p=s.call(p),l(f,p,_)):!1;if(c(f)){if(!c(p)||f.length!==p.length)return!1;for(y=0;y<f.length;y++)if(f[y]!==p[y])return!1;return!0}try{var g=o(f),m=o(p)}catch{return!1}if(g.length!=m.length)return!1;for(g.sort(),m.sort(),y=g.length-1;y>=0;y--)if(g[y]!=m[y])return!1;for(y=g.length-1;y>=0;y--)if(w=g[y],!l(f[w],p[w],_))return!1;return typeof f==typeof p}},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(1),o=function(){function a(l,u,c){c===void 0&&(c={}),this.attrName=l,this.keyName=u;var d=s.Scope.TYPE&s.Scope.ATTRIBUTE;c.scope!=null?this.scope=c.scope&s.Scope.LEVEL|d:this.scope=s.Scope.ATTRIBUTE,c.whitelist!=null&&(this.whitelist=c.whitelist)}return a.keys=function(l){return[].map.call(l.attributes,function(u){return u.name})},a.prototype.add=function(l,u){return this.canAdd(l,u)?(l.setAttribute(this.keyName,u),!0):!1},a.prototype.canAdd=function(l,u){var c=s.query(l,s.Scope.BLOT&(this.scope|s.Scope.TYPE));return c==null?!1:this.whitelist==null?!0:typeof u=="string"?this.whitelist.indexOf(u.replace(/["']/g,""))>-1:this.whitelist.indexOf(u)>-1},a.prototype.remove=function(l){l.removeAttribute(this.keyName)},a.prototype.value=function(l){var u=l.getAttribute(this.keyName);return this.canAdd(l,u)&&u?u:""},a}();r.default=o},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Code=void 0;var s=function(){function E(T,S){var k=[],I=!0,P=!1,M=void 0;try{for(var $=T[Symbol.iterator](),Z;!(I=(Z=$.next()).done)&&(k.push(Z.value),!(S&&k.length===S));I=!0);}catch(Q){P=!0,M=Q}finally{try{!I&&$.return&&$.return()}finally{if(P)throw M}}return k}return function(T,S){if(Array.isArray(T))return T;if(Symbol.iterator in Object(T))return E(T,S);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function E(T,S){for(var k=0;k<S.length;k++){var I=S[k];I.enumerable=I.enumerable||!1,I.configurable=!0,"value"in I&&(I.writable=!0),Object.defineProperty(T,I.key,I)}}return function(T,S,k){return S&&E(T.prototype,S),k&&E(T,k),T}}(),a=function E(T,S,k){T===null&&(T=Function.prototype);var I=Object.getOwnPropertyDescriptor(T,S);if(I===void 0){var P=Object.getPrototypeOf(T);return P===null?void 0:E(P,S,k)}else{if("value"in I)return I.value;var M=I.get;return M===void 0?void 0:M.call(k)}},l=i(2),u=m(l),c=i(0),d=m(c),f=i(4),p=m(f),_=i(6),y=m(_),w=i(7),g=m(w);function m(E){return E&&E.__esModule?E:{default:E}}function b(E,T){if(!(E instanceof T))throw new TypeError("Cannot call a class as a function")}function v(E,T){if(!E)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return T&&(typeof T=="object"||typeof T=="function")?T:E}function A(E,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof T);E.prototype=Object.create(T&&T.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}),T&&(Object.setPrototypeOf?Object.setPrototypeOf(E,T):E.__proto__=T)}var N=function(E){A(T,E);function T(){return b(this,T),v(this,(T.__proto__||Object.getPrototypeOf(T)).apply(this,arguments))}return T}(y.default);N.blotName="code",N.tagName="CODE";var x=function(E){A(T,E);function T(){return b(this,T),v(this,(T.__proto__||Object.getPrototypeOf(T)).apply(this,arguments))}return o(T,[{key:"delta",value:function(){var k=this,I=this.domNode.textContent;return I.endsWith(` 3738`)&&(I=I.slice(0,-1)),I.split(` 3739`).reduce(function(P,M){return P.insert(M).insert(` 3740`,k.formats())},new u.default)}},{key:"format",value:function(k,I){if(!(k===this.statics.blotName&&I)){var P=this.descendant(g.default,this.length()-1),M=s(P,1),$=M[0];$!=null&&$.deleteAt($.length()-1,1),a(T.prototype.__proto__||Object.getPrototypeOf(T.prototype),"format",this).call(this,k,I)}}},{key:"formatAt",value:function(k,I,P,M){if(I!==0&&!(d.default.query(P,d.default.Scope.BLOCK)==null||P===this.statics.blotName&&M===this.statics.formats(this.domNode))){var $=this.newlineIndex(k);if(!($<0||$>=k+I)){var Z=this.newlineIndex(k,!0)+1,Q=$-Z+1,K=this.isolate(Z,Q),B=K.next;K.format(P,M),B instanceof T&&B.formatAt(0,k-Z+I-Q,P,M)}}}},{key:"insertAt",value:function(k,I,P){if(P==null){var M=this.descendant(g.default,k),$=s(M,2),Z=$[0],Q=$[1];Z.insertAt(Q,I)}}},{key:"length",value:function(){var k=this.domNode.textContent.length;return this.domNode.textContent.endsWith(` 3741`)?k:k+1}},{key:"newlineIndex",value:function(k){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(I)return this.domNode.textContent.slice(0,k).lastIndexOf(` 3742`);var P=this.domNode.textContent.slice(k).indexOf(` 3743`);return P>-1?k+P:-1}},{key:"optimize",value:function(k){this.domNode.textContent.endsWith(` 3744`)||this.appendChild(d.default.create("text",` 3745`)),a(T.prototype.__proto__||Object.getPrototypeOf(T.prototype),"optimize",this).call(this,k);var I=this.next;I!=null&&I.prev===this&&I.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===I.statics.formats(I.domNode)&&(I.optimize(k),I.moveChildren(this),I.remove())}},{key:"replace",value:function(k){a(T.prototype.__proto__||Object.getPrototypeOf(T.prototype),"replace",this).call(this,k),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(I){var P=d.default.find(I);P==null?I.parentNode.removeChild(I):P instanceof d.default.Embed?P.remove():P.unwrap()})}}],[{key:"create",value:function(k){var I=a(T.__proto__||Object.getPrototypeOf(T),"create",this).call(this,k);return I.setAttribute("spellcheck",!1),I}},{key:"formats",value:function(){return!0}}]),T}(p.default);x.blotName="code-block",x.tagName="PRE",x.TAB=" ",r.Code=N,r.default=x},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(B){return typeof B}:function(B){return B&&typeof Symbol=="function"&&B.constructor===Symbol&&B!==Symbol.prototype?"symbol":typeof B},o=function(){function B(V,D){var j=[],U=!0,Y=!1,W=void 0;try{for(var F=V[Symbol.iterator](),q;!(U=(q=F.next()).done)&&(j.push(q.value),!(D&&j.length===D));U=!0);}catch(ee){Y=!0,W=ee}finally{try{!U&&F.return&&F.return()}finally{if(Y)throw W}}return j}return function(V,D){if(Array.isArray(V))return V;if(Symbol.iterator in Object(V))return B(V,D);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(){function B(V,D){for(var j=0;j<D.length;j++){var U=D[j];U.enumerable=U.enumerable||!1,U.configurable=!0,"value"in U&&(U.writable=!0),Object.defineProperty(V,U.key,U)}}return function(V,D,j){return D&&B(V.prototype,D),j&&B(V,j),V}}(),l=i(2),u=I(l),c=i(20),d=I(c),f=i(0),p=I(f),_=i(13),y=I(_),w=i(24),g=I(w),m=i(4),b=I(m),v=i(16),A=I(v),N=i(21),x=I(N),E=i(11),T=I(E),S=i(3),k=I(S);function I(B){return B&&B.__esModule?B:{default:B}}function P(B,V,D){return V in B?Object.defineProperty(B,V,{value:D,enumerable:!0,configurable:!0,writable:!0}):B[V]=D,B}function M(B,V){if(!(B instanceof V))throw new TypeError("Cannot call a class as a function")}var $=/^[ -~]*$/,Z=function(){function B(V){M(this,B),this.scroll=V,this.delta=this.getDelta()}return a(B,[{key:"applyDelta",value:function(D){var j=this,U=!1;this.scroll.update();var Y=this.scroll.length();return this.scroll.batchStart(),D=K(D),D.reduce(function(W,F){var q=F.retain||F.delete||F.insert.length||1,ee=F.attributes||{};if(F.insert!=null){if(typeof F.insert=="string"){var te=F.insert;te.endsWith(` 3746`)&&U&&(U=!1,te=te.slice(0,-1)),W>=Y&&!te.endsWith(` 3747`)&&(U=!0),j.scroll.insertAt(W,te);var ae=j.scroll.line(W),_e=o(ae,2),Ee=_e[0],Ce=_e[1],qe=(0,k.default)({},(0,m.bubbleFormats)(Ee));if(Ee instanceof b.default){var Ze=Ee.descendant(p.default.Leaf,Ce),Et=o(Ze,1),kt=Et[0];qe=(0,k.default)(qe,(0,m.bubbleFormats)(kt))}ee=d.default.attributes.diff(qe,ee)||{}}else if(s(F.insert)==="object"){var ie=Object.keys(F.insert)[0];if(ie==null)return W;j.scroll.insertAt(W,ie,F.insert[ie])}Y+=q}return Object.keys(ee).forEach(function(se){j.scroll.formatAt(W,q,se,ee[se])}),W+q},0),D.reduce(function(W,F){return typeof F.delete=="number"?(j.scroll.deleteAt(W,F.delete),W):W+(F.retain||F.insert.length||1)},0),this.scroll.batchEnd(),this.update(D)}},{key:"deleteText",value:function(D,j){return this.scroll.deleteAt(D,j),this.update(new u.default().retain(D).delete(j))}},{key:"formatLine",value:function(D,j){var U=this,Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.scroll.update(),Object.keys(Y).forEach(function(W){if(!(U.scroll.whitelist!=null&&!U.scroll.whitelist[W])){var F=U.scroll.lines(D,Math.max(j,1)),q=j;F.forEach(function(ee){var te=ee.length();if(!(ee instanceof y.default))ee.format(W,Y[W]);else{var ae=D-ee.offset(U.scroll),_e=ee.newlineIndex(ae+q)-ae+1;ee.formatAt(ae,_e,W,Y[W])}q-=te})}}),this.scroll.optimize(),this.update(new u.default().retain(D).retain(j,(0,x.default)(Y)))}},{key:"formatText",value:function(D,j){var U=this,Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Object.keys(Y).forEach(function(W){U.scroll.formatAt(D,j,W,Y[W])}),this.update(new u.default().retain(D).retain(j,(0,x.default)(Y)))}},{key:"getContents",value:function(D,j){return this.delta.slice(D,D+j)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(D,j){return D.concat(j.delta())},new u.default)}},{key:"getFormat",value:function(D){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,U=[],Y=[];j===0?this.scroll.path(D).forEach(function(F){var q=o(F,1),ee=q[0];ee instanceof b.default?U.push(ee):ee instanceof p.default.Leaf&&Y.push(ee)}):(U=this.scroll.lines(D,j),Y=this.scroll.descendants(p.default.Leaf,D,j));var W=[U,Y].map(function(F){if(F.length===0)return{};for(var q=(0,m.bubbleFormats)(F.shift());Object.keys(q).length>0;){var ee=F.shift();if(ee==null)return q;q=Q((0,m.bubbleFormats)(ee),q)}return q});return k.default.apply(k.default,W)}},{key:"getText",value:function(D,j){return this.getContents(D,j).filter(function(U){return typeof U.insert=="string"}).map(function(U){return U.insert}).join("")}},{key:"insertEmbed",value:function(D,j,U){return this.scroll.insertAt(D,j,U),this.update(new u.default().retain(D).insert(P({},j,U)))}},{key:"insertText",value:function(D,j){var U=this,Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return j=j.replace(/\r\n/g,` 3748`).replace(/\r/g,` 3749`),this.scroll.insertAt(D,j),Object.keys(Y).forEach(function(W){U.scroll.formatAt(D,j.length,W,Y[W])}),this.update(new u.default().retain(D).insert(j,(0,x.default)(Y)))}},{key:"isBlank",value:function(){if(this.scroll.children.length==0)return!0;if(this.scroll.children.length>1)return!1;var D=this.scroll.children.head;return D.statics.blotName!==b.default.blotName||D.children.length>1?!1:D.children.head instanceof A.default}},{key:"removeFormat",value:function(D,j){var U=this.getText(D,j),Y=this.scroll.line(D+j),W=o(Y,2),F=W[0],q=W[1],ee=0,te=new u.default;F!=null&&(F instanceof y.default?ee=F.newlineIndex(q)-q+1:ee=F.length()-q,te=F.delta().slice(q,q+ee-1).insert(` 3750`));var ae=this.getContents(D,j+ee),_e=ae.diff(new u.default().insert(U).concat(te)),Ee=new u.default().retain(D).concat(_e);return this.applyDelta(Ee)}},{key:"update",value:function(D){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],U=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,Y=this.delta;if(j.length===1&&j[0].type==="characterData"&&j[0].target.data.match($)&&p.default.find(j[0].target)){var W=p.default.find(j[0].target),F=(0,m.bubbleFormats)(W),q=W.offset(this.scroll),ee=j[0].oldValue.replace(g.default.CONTENTS,""),te=new u.default().insert(ee),ae=new u.default().insert(W.value()),_e=new u.default().retain(q).concat(te.diff(ae,U));D=_e.reduce(function(Ee,Ce){return Ce.insert?Ee.insert(Ce.insert,F):Ee.push(Ce)},new u.default),this.delta=Y.compose(D)}else this.delta=this.getDelta(),(!D||!(0,T.default)(Y.compose(D),this.delta))&&(D=Y.diff(this.delta,U));return D}}]),B}();function Q(B,V){return Object.keys(V).reduce(function(D,j){return B[j]==null||(V[j]===B[j]?D[j]=V[j]:Array.isArray(V[j])?V[j].indexOf(B[j])<0&&(D[j]=V[j].concat([B[j]])):D[j]=[V[j],B[j]]),D},{})}function K(B){return B.reduce(function(V,D){if(D.insert===1){var j=(0,x.default)(D.attributes);return delete j.image,V.insert({image:D.attributes.image},j)}if(D.attributes!=null&&(D.attributes.list===!0||D.attributes.bullet===!0)&&(D=(0,x.default)(D),D.attributes.list?D.attributes.list="ordered":(D.attributes.list="bullet",delete D.attributes.bullet)),typeof D.insert=="string"){var U=D.insert.replace(/\r\n/g,` 3751`).replace(/\r/g,` 3752`);return V.insert(U,D.attributes)}return V.push(D)},new u.default)}r.default=Z},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Range=void 0;var s=function(){function E(T,S){var k=[],I=!0,P=!1,M=void 0;try{for(var $=T[Symbol.iterator](),Z;!(I=(Z=$.next()).done)&&(k.push(Z.value),!(S&&k.length===S));I=!0);}catch(Q){P=!0,M=Q}finally{try{!I&&$.return&&$.return()}finally{if(P)throw M}}return k}return function(T,S){if(Array.isArray(T))return T;if(Symbol.iterator in Object(T))return E(T,S);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function E(T,S){for(var k=0;k<S.length;k++){var I=S[k];I.enumerable=I.enumerable||!1,I.configurable=!0,"value"in I&&(I.writable=!0),Object.defineProperty(T,I.key,I)}}return function(T,S,k){return S&&E(T.prototype,S),k&&E(T,k),T}}(),a=i(0),l=g(a),u=i(21),c=g(u),d=i(11),f=g(d),p=i(8),_=g(p),y=i(10),w=g(y);function g(E){return E&&E.__esModule?E:{default:E}}function m(E){if(Array.isArray(E)){for(var T=0,S=Array(E.length);T<E.length;T++)S[T]=E[T];return S}else return Array.from(E)}function b(E,T){if(!(E instanceof T))throw new TypeError("Cannot call a class as a function")}var v=(0,w.default)("quill:selection"),A=function E(T){var S=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;b(this,E),this.index=T,this.length=S},N=function(){function E(T,S){var k=this;b(this,E),this.emitter=S,this.scroll=T,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=l.default.create("cursor",this),this.lastRange=this.savedRange=new A(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){k.mouseDown||setTimeout(k.update.bind(k,_.default.sources.USER),1)}),this.emitter.on(_.default.events.EDITOR_CHANGE,function(I,P){I===_.default.events.TEXT_CHANGE&&P.length()>0&&k.update(_.default.sources.SILENT)}),this.emitter.on(_.default.events.SCROLL_BEFORE_UPDATE,function(){if(k.hasFocus()){var I=k.getNativeRange();I!=null&&I.start.node!==k.cursor.textNode&&k.emitter.once(_.default.events.SCROLL_UPDATE,function(){try{k.setNativeRange(I.start.node,I.start.offset,I.end.node,I.end.offset)}catch{}})}}),this.emitter.on(_.default.events.SCROLL_OPTIMIZE,function(I,P){if(P.range){var M=P.range,$=M.startNode,Z=M.startOffset,Q=M.endNode,K=M.endOffset;k.setNativeRange($,Z,Q,K)}}),this.update(_.default.sources.SILENT)}return o(E,[{key:"handleComposition",value:function(){var S=this;this.root.addEventListener("compositionstart",function(){S.composing=!0}),this.root.addEventListener("compositionend",function(){if(S.composing=!1,S.cursor.parent){var k=S.cursor.restore();if(!k)return;setTimeout(function(){S.setNativeRange(k.startNode,k.startOffset,k.endNode,k.endOffset)},1)}})}},{key:"handleDragging",value:function(){var S=this;this.emitter.listenDOM("mousedown",document.body,function(){S.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){S.mouseDown=!1,S.update(_.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(S,k){if(!(this.scroll.whitelist!=null&&!this.scroll.whitelist[S])){this.scroll.update();var I=this.getNativeRange();if(!(I==null||!I.native.collapsed||l.default.query(S,l.default.Scope.BLOCK))){if(I.start.node!==this.cursor.textNode){var P=l.default.find(I.start.node,!1);if(P==null)return;if(P instanceof l.default.Leaf){var M=P.split(I.start.offset);P.parent.insertBefore(this.cursor,M)}else P.insertBefore(this.cursor,I.start.node);this.cursor.attach()}this.cursor.format(S,k),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(S){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,I=this.scroll.length();S=Math.min(S,I-1),k=Math.min(S+k,I-1)-S;var P=void 0,M=this.scroll.leaf(S),$=s(M,2),Z=$[0],Q=$[1];if(Z==null)return null;var K=Z.position(Q,!0),B=s(K,2);P=B[0],Q=B[1];var V=document.createRange();if(k>0){V.setStart(P,Q);var D=this.scroll.leaf(S+k),j=s(D,2);if(Z=j[0],Q=j[1],Z==null)return null;var U=Z.position(Q,!0),Y=s(U,2);return P=Y[0],Q=Y[1],V.setEnd(P,Q),V.getBoundingClientRect()}else{var W="left",F=void 0;return P instanceof Text?(Q<P.data.length?(V.setStart(P,Q),V.setEnd(P,Q+1)):(V.setStart(P,Q-1),V.setEnd(P,Q),W="right"),F=V.getBoundingClientRect()):(F=Z.domNode.getBoundingClientRect(),Q>0&&(W="right")),{bottom:F.top+F.height,height:F.height,left:F[W],right:F[W],top:F.top,width:0}}}},{key:"getNativeRange",value:function(){var S=document.getSelection();if(S==null||S.rangeCount<=0)return null;var k=S.getRangeAt(0);if(k==null)return null;var I=this.normalizeNative(k);return v.info("getNativeRange",I),I}},{key:"getRange",value:function(){var S=this.getNativeRange();if(S==null)return[null,null];var k=this.normalizedToRange(S);return[k,S]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(S){var k=this,I=[[S.start.node,S.start.offset]];S.native.collapsed||I.push([S.end.node,S.end.offset]);var P=I.map(function(Z){var Q=s(Z,2),K=Q[0],B=Q[1],V=l.default.find(K,!0),D=V.offset(k.scroll);return B===0?D:V instanceof l.default.Container?D+V.length():D+V.index(K,B)}),M=Math.min(Math.max.apply(Math,m(P)),this.scroll.length()-1),$=Math.min.apply(Math,[M].concat(m(P)));return new A($,M-$)}},{key:"normalizeNative",value:function(S){if(!x(this.root,S.startContainer)||!S.collapsed&&!x(this.root,S.endContainer))return null;var k={start:{node:S.startContainer,offset:S.startOffset},end:{node:S.endContainer,offset:S.endOffset},native:S};return[k.start,k.end].forEach(function(I){for(var P=I.node,M=I.offset;!(P instanceof Text)&&P.childNodes.length>0;)if(P.childNodes.length>M)P=P.childNodes[M],M=0;else if(P.childNodes.length===M)P=P.lastChild,M=P instanceof Text?P.data.length:P.childNodes.length+1;else break;I.node=P,I.offset=M}),k}},{key:"rangeToNative",value:function(S){var k=this,I=S.collapsed?[S.index]:[S.index,S.index+S.length],P=[],M=this.scroll.length();return I.forEach(function($,Z){$=Math.min(M-1,$);var Q=void 0,K=k.scroll.leaf($),B=s(K,2),V=B[0],D=B[1],j=V.position(D,Z!==0),U=s(j,2);Q=U[0],D=U[1],P.push(Q,D)}),P.length<2&&(P=P.concat(P)),P}},{key:"scrollIntoView",value:function(S){var k=this.lastRange;if(k!=null){var I=this.getBounds(k.index,k.length);if(I!=null){var P=this.scroll.length()-1,M=this.scroll.line(Math.min(k.index,P)),$=s(M,1),Z=$[0],Q=Z;if(k.length>0){var K=this.scroll.line(Math.min(k.index+k.length,P)),B=s(K,1);Q=B[0]}if(!(Z==null||Q==null)){var V=S.getBoundingClientRect();I.top<V.top?S.scrollTop-=V.top-I.top:I.bottom>V.bottom&&(S.scrollTop+=I.bottom-V.bottom)}}}}},{key:"setNativeRange",value:function(S,k){var I=arguments.length>2&&arguments[2]!==void 0?arguments[2]:S,P=arguments.length>3&&arguments[3]!==void 0?arguments[3]:k,M=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(v.info("setNativeRange",S,k,I,P),!(S!=null&&(this.root.parentNode==null||S.parentNode==null||I.parentNode==null))){var $=document.getSelection();if($!=null)if(S!=null){this.hasFocus()||this.root.focus();var Z=(this.getNativeRange()||{}).native;if(Z==null||M||S!==Z.startContainer||k!==Z.startOffset||I!==Z.endContainer||P!==Z.endOffset){S.tagName=="BR"&&(k=[].indexOf.call(S.parentNode.childNodes,S),S=S.parentNode),I.tagName=="BR"&&(P=[].indexOf.call(I.parentNode.childNodes,I),I=I.parentNode);var Q=document.createRange();Q.setStart(S,k),Q.setEnd(I,P),$.removeAllRanges(),$.addRange(Q)}}else $.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(S){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,I=arguments.length>2&&arguments[2]!==void 0?arguments[2]:_.default.sources.API;if(typeof k=="string"&&(I=k,k=!1),v.info("setRange",S),S!=null){var P=this.rangeToNative(S);this.setNativeRange.apply(this,m(P).concat([k]))}else this.setNativeRange(null);this.update(I)}},{key:"update",value:function(){var S=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_.default.sources.USER,k=this.lastRange,I=this.getRange(),P=s(I,2),M=P[0],$=P[1];if(this.lastRange=M,this.lastRange!=null&&(this.savedRange=this.lastRange),!(0,f.default)(k,this.lastRange)){var Z;!this.composing&&$!=null&&$.native.collapsed&&$.start.node!==this.cursor.textNode&&this.cursor.restore();var Q=[_.default.events.SELECTION_CHANGE,(0,c.default)(this.lastRange),(0,c.default)(k),S];if((Z=this.emitter).emit.apply(Z,[_.default.events.EDITOR_CHANGE].concat(Q)),S!==_.default.sources.SILENT){var K;(K=this.emitter).emit.apply(K,Q)}}}}]),E}();function x(E,T){try{T.parentNode}catch{return!1}return T instanceof Text&&(T=T.parentNode),E.contains(T)}r.Range=A,r.default=N},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function _(y,w){for(var g=0;g<w.length;g++){var m=w[g];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,g){return w&&_(y.prototype,w),g&&_(y,g),y}}(),o=function _(y,w,g){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var b=Object.getPrototypeOf(y);return b===null?void 0:_(b,w,g)}else{if("value"in m)return m.value;var v=m.get;return v===void 0?void 0:v.call(g)}},a=i(0),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(){return c(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"insertInto",value:function(g,m){g.children.length===0?o(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"insertInto",this).call(this,g,m):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),y}(l.default.Embed);p.blotName="break",p.tagName="BR",r.default=p},function(n,r,i){var s=this&&this.__extends||function(){var d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,p){f.__proto__=p}||function(f,p){for(var _ in p)p.hasOwnProperty(_)&&(f[_]=p[_])};return function(f,p){d(f,p);function _(){this.constructor=f}f.prototype=p===null?Object.create(p):(_.prototype=p.prototype,new _)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(44),a=i(30),l=i(1),u=function(d){s(f,d);function f(p){var _=d.call(this,p)||this;return _.build(),_}return f.prototype.appendChild=function(p){this.insertBefore(p)},f.prototype.attach=function(){d.prototype.attach.call(this),this.children.forEach(function(p){p.attach()})},f.prototype.build=function(){var p=this;this.children=new o.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(_){try{var y=c(_);p.insertBefore(y,p.children.head||void 0)}catch(w){if(w instanceof l.ParchmentError)return;throw w}})},f.prototype.deleteAt=function(p,_){if(p===0&&_===this.length())return this.remove();this.children.forEachAt(p,_,function(y,w,g){y.deleteAt(w,g)})},f.prototype.descendant=function(p,_){var y=this.children.find(_),w=y[0],g=y[1];return p.blotName==null&&p(w)||p.blotName!=null&&w instanceof p?[w,g]:w instanceof f?w.descendant(p,g):[null,-1]},f.prototype.descendants=function(p,_,y){_===void 0&&(_=0),y===void 0&&(y=Number.MAX_VALUE);var w=[],g=y;return this.children.forEachAt(_,y,function(m,b,v){(p.blotName==null&&p(m)||p.blotName!=null&&m instanceof p)&&w.push(m),m instanceof f&&(w=w.concat(m.descendants(p,b,g))),g-=v}),w},f.prototype.detach=function(){this.children.forEach(function(p){p.detach()}),d.prototype.detach.call(this)},f.prototype.formatAt=function(p,_,y,w){this.children.forEachAt(p,_,function(g,m,b){g.formatAt(m,b,y,w)})},f.prototype.insertAt=function(p,_,y){var w=this.children.find(p),g=w[0],m=w[1];if(g)g.insertAt(m,_,y);else{var b=y==null?l.create("text",_):l.create(_,y);this.appendChild(b)}},f.prototype.insertBefore=function(p,_){if(this.statics.allowedChildren!=null&&!this.statics.allowedChildren.some(function(y){return p instanceof y}))throw new l.ParchmentError("Cannot insert "+p.statics.blotName+" into "+this.statics.blotName);p.insertInto(this,_)},f.prototype.length=function(){return this.children.reduce(function(p,_){return p+_.length()},0)},f.prototype.moveChildren=function(p,_){this.children.forEach(function(y){p.insertBefore(y,_)})},f.prototype.optimize=function(p){if(d.prototype.optimize.call(this,p),this.children.length===0)if(this.statics.defaultChild!=null){var _=l.create(this.statics.defaultChild);this.appendChild(_),_.optimize(p)}else this.remove()},f.prototype.path=function(p,_){_===void 0&&(_=!1);var y=this.children.find(p,_),w=y[0],g=y[1],m=[[this,p]];return w instanceof f?m.concat(w.path(g,_)):(w!=null&&m.push([w,g]),m)},f.prototype.removeChild=function(p){this.children.remove(p)},f.prototype.replace=function(p){p instanceof f&&p.moveChildren(this),d.prototype.replace.call(this,p)},f.prototype.split=function(p,_){if(_===void 0&&(_=!1),!_){if(p===0)return this;if(p===this.length())return this.next}var y=this.clone();return this.parent.insertBefore(y,this.next),this.children.forEachAt(p,this.length(),function(w,g,m){w=w.split(g,_),y.appendChild(w)}),y},f.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},f.prototype.update=function(p,_){var y=this,w=[],g=[];p.forEach(function(m){m.target===y.domNode&&m.type==="childList"&&(w.push.apply(w,m.addedNodes),g.push.apply(g,m.removedNodes))}),g.forEach(function(m){if(!(m.parentNode!=null&&m.tagName!=="IFRAME"&&document.body.compareDocumentPosition(m)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var b=l.find(m);b!=null&&(b.domNode.parentNode==null||b.domNode.parentNode===y.domNode)&&b.detach()}}),w.filter(function(m){return m.parentNode==y.domNode}).sort(function(m,b){return m===b?0:m.compareDocumentPosition(b)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(m){var b=null;m.nextSibling!=null&&(b=l.find(m.nextSibling));var v=c(m);(v.next!=b||v.next==null)&&(v.parent!=null&&v.parent.removeChild(y),y.insertBefore(v,b||void 0))})},f}(a.default);function c(d){var f=l.find(d);if(f==null)try{f=l.create(d)}catch{f=l.create(l.Scope.INLINE),[].slice.call(d.childNodes).forEach(function(_){f.domNode.appendChild(_)}),d.parentNode&&d.parentNode.replaceChild(f.domNode,d),f.attach()}return f}r.default=u},function(n,r,i){var s=this&&this.__extends||function(){var d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,p){f.__proto__=p}||function(f,p){for(var _ in p)p.hasOwnProperty(_)&&(f[_]=p[_])};return function(f,p){d(f,p);function _(){this.constructor=f}f.prototype=p===null?Object.create(p):(_.prototype=p.prototype,new _)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(12),a=i(31),l=i(17),u=i(1),c=function(d){s(f,d);function f(p){var _=d.call(this,p)||this;return _.attributes=new a.default(_.domNode),_}return f.formats=function(p){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return p.tagName.toLowerCase()},f.prototype.format=function(p,_){var y=u.query(p);y instanceof o.default?this.attributes.attribute(y,_):_&&y!=null&&(p!==this.statics.blotName||this.formats()[p]!==_)&&this.replaceWith(p,_)},f.prototype.formats=function(){var p=this.attributes.values(),_=this.statics.formats(this.domNode);return _!=null&&(p[this.statics.blotName]=_),p},f.prototype.replaceWith=function(p,_){var y=d.prototype.replaceWith.call(this,p,_);return this.attributes.copy(y),y},f.prototype.update=function(p,_){var y=this;d.prototype.update.call(this,p,_),p.some(function(w){return w.target===y.domNode&&w.type==="attributes"})&&this.attributes.build()},f.prototype.wrap=function(p,_){var y=d.prototype.wrap.call(this,p,_);return y instanceof f&&y.statics.scope===this.statics.scope&&this.attributes.move(y),y},f}(l.default);r.default=c},function(n,r,i){var s=this&&this.__extends||function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)d.hasOwnProperty(f)&&(c[f]=d[f])};return function(c,d){u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(30),a=i(1),l=function(u){s(c,u);function c(){return u!==null&&u.apply(this,arguments)||this}return c.value=function(d){return!0},c.prototype.index=function(d,f){return this.domNode===d||this.domNode.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(f,1):-1},c.prototype.position=function(d,f){var p=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return d>0&&(p+=1),[this.parent.domNode,p]},c.prototype.value=function(){var d;return d={},d[this.statics.blotName]=this.statics.value(this.domNode)||!0,d},c.scope=a.Scope.INLINE_BLOT,c}(o.default);r.default=l},function(n,r,i){var s=i(11),o=i(3),a={attributes:{compose:function(u,c,d){typeof u!="object"&&(u={}),typeof c!="object"&&(c={});var f=o(!0,{},c);d||(f=Object.keys(f).reduce(function(_,y){return f[y]!=null&&(_[y]=f[y]),_},{}));for(var p in u)u[p]!==void 0&&c[p]===void 0&&(f[p]=u[p]);return Object.keys(f).length>0?f:void 0},diff:function(u,c){typeof u!="object"&&(u={}),typeof c!="object"&&(c={});var d=Object.keys(u).concat(Object.keys(c)).reduce(function(f,p){return s(u[p],c[p])||(f[p]=c[p]===void 0?null:c[p]),f},{});return Object.keys(d).length>0?d:void 0},transform:function(u,c,d){if(typeof u!="object")return c;if(typeof c=="object"){if(!d)return c;var f=Object.keys(c).reduce(function(p,_){return u[_]===void 0&&(p[_]=c[_]),p},{});return Object.keys(f).length>0?f:void 0}}},iterator:function(u){return new l(u)},length:function(u){return typeof u.delete=="number"?u.delete:typeof u.retain=="number"?u.retain:typeof u.insert=="string"?u.insert.length:1}};function l(u){this.ops=u,this.index=0,this.offset=0}l.prototype.hasNext=function(){return this.peekLength()<1/0},l.prototype.next=function(u){u||(u=1/0);var c=this.ops[this.index];if(c){var d=this.offset,f=a.length(c);if(u>=f-d?(u=f-d,this.index+=1,this.offset=0):this.offset+=u,typeof c.delete=="number")return{delete:u};var p={};return c.attributes&&(p.attributes=c.attributes),typeof c.retain=="number"?p.retain=u:typeof c.insert=="string"?p.insert=c.insert.substr(d,u):p.insert=c.insert,p}else return{retain:1/0}},l.prototype.peek=function(){return this.ops[this.index]},l.prototype.peekLength=function(){return this.ops[this.index]?a.length(this.ops[this.index])-this.offset:1/0},l.prototype.peekType=function(){return this.ops[this.index]?typeof this.ops[this.index].delete=="number"?"delete":typeof this.ops[this.index].retain=="number"?"retain":"insert":"retain"},l.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var u=this.offset,c=this.index,d=this.next(),f=this.ops.slice(this.index);return this.offset=u,this.index=c,[d].concat(f)}else return[]},n.exports=a},function(n,r){var i=function(){function s(y,w){return w!=null&&y instanceof w}var o;try{o=Map}catch{o=function(){}}var a;try{a=Set}catch{a=function(){}}var l;try{l=Promise}catch{l=function(){}}function u(y,w,g,m,b){typeof w=="object"&&(g=w.depth,m=w.prototype,b=w.includeNonEnumerable,w=w.circular);var v=[],A=[],N=typeof Buffer<"u";typeof w>"u"&&(w=!0),typeof g>"u"&&(g=1/0);function x(E,T){if(E===null)return null;if(T===0)return E;var S,k;if(typeof E!="object")return E;if(s(E,o))S=new o;else if(s(E,a))S=new a;else if(s(E,l))S=new l(function(V,D){E.then(function(j){V(x(j,T-1))},function(j){D(x(j,T-1))})});else if(u.__isArray(E))S=[];else if(u.__isRegExp(E))S=new RegExp(E.source,_(E)),E.lastIndex&&(S.lastIndex=E.lastIndex);else if(u.__isDate(E))S=new Date(E.getTime());else{if(N&&Buffer.isBuffer(E))return Buffer.allocUnsafe?S=Buffer.allocUnsafe(E.length):S=new Buffer(E.length),E.copy(S),S;s(E,Error)?S=Object.create(E):typeof m>"u"?(k=Object.getPrototypeOf(E),S=Object.create(k)):(S=Object.create(m),k=m)}if(w){var I=v.indexOf(E);if(I!=-1)return A[I];v.push(E),A.push(S)}s(E,o)&&E.forEach(function(V,D){var j=x(D,T-1),U=x(V,T-1);S.set(j,U)}),s(E,a)&&E.forEach(function(V){var D=x(V,T-1);S.add(D)});for(var P in E){var M;k&&(M=Object.getOwnPropertyDescriptor(k,P)),!(M&&M.set==null)&&(S[P]=x(E[P],T-1))}if(Object.getOwnPropertySymbols)for(var $=Object.getOwnPropertySymbols(E),P=0;P<$.length;P++){var Z=$[P],Q=Object.getOwnPropertyDescriptor(E,Z);Q&&!Q.enumerable&&!b||(S[Z]=x(E[Z],T-1),Q.enumerable||Object.defineProperty(S,Z,{enumerable:!1}))}if(b)for(var K=Object.getOwnPropertyNames(E),P=0;P<K.length;P++){var B=K[P],Q=Object.getOwnPropertyDescriptor(E,B);Q&&Q.enumerable||(S[B]=x(E[B],T-1),Object.defineProperty(S,B,{enumerable:!1}))}return S}return x(y,g)}u.clonePrototype=function(w){if(w===null)return null;var g=function(){};return g.prototype=w,new g};function c(y){return Object.prototype.toString.call(y)}u.__objToStr=c;function d(y){return typeof y=="object"&&c(y)==="[object Date]"}u.__isDate=d;function f(y){return typeof y=="object"&&c(y)==="[object Array]"}u.__isArray=f;function p(y){return typeof y=="object"&&c(y)==="[object RegExp]"}u.__isRegExp=p;function _(y){var w="";return y.global&&(w+="g"),y.ignoreCase&&(w+="i"),y.multiline&&(w+="m"),w}return u.__getRegExpFlags=_,u}();typeof n=="object"&&n.exports&&(n.exports=i)},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function S(k,I){var P=[],M=!0,$=!1,Z=void 0;try{for(var Q=k[Symbol.iterator](),K;!(M=(K=Q.next()).done)&&(P.push(K.value),!(I&&P.length===I));M=!0);}catch(B){$=!0,Z=B}finally{try{!M&&Q.return&&Q.return()}finally{if($)throw Z}}return P}return function(k,I){if(Array.isArray(k))return k;if(Symbol.iterator in Object(k))return S(k,I);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function S(k,I){for(var P=0;P<I.length;P++){var M=I[P];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(k,M.key,M)}}return function(k,I,P){return I&&S(k.prototype,I),P&&S(k,P),k}}(),a=function S(k,I,P){k===null&&(k=Function.prototype);var M=Object.getOwnPropertyDescriptor(k,I);if(M===void 0){var $=Object.getPrototypeOf(k);return $===null?void 0:S($,I,P)}else{if("value"in M)return M.value;var Z=M.get;return Z===void 0?void 0:Z.call(P)}},l=i(0),u=v(l),c=i(8),d=v(c),f=i(4),p=v(f),_=i(16),y=v(_),w=i(13),g=v(w),m=i(25),b=v(m);function v(S){return S&&S.__esModule?S:{default:S}}function A(S,k){if(!(S instanceof k))throw new TypeError("Cannot call a class as a function")}function N(S,k){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return k&&(typeof k=="object"||typeof k=="function")?k:S}function x(S,k){if(typeof k!="function"&&k!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof k);S.prototype=Object.create(k&&k.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),k&&(Object.setPrototypeOf?Object.setPrototypeOf(S,k):S.__proto__=k)}function E(S){return S instanceof p.default||S instanceof f.BlockEmbed}var T=function(S){x(k,S);function k(I,P){A(this,k);var M=N(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,I));return M.emitter=P.emitter,Array.isArray(P.whitelist)&&(M.whitelist=P.whitelist.reduce(function($,Z){return $[Z]=!0,$},{})),M.domNode.addEventListener("DOMNodeInserted",function(){}),M.optimize(),M.enable(),M}return o(k,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(P,M){var $=this.line(P),Z=s($,2),Q=Z[0],K=Z[1],B=this.line(P+M),V=s(B,1),D=V[0];if(a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"deleteAt",this).call(this,P,M),D!=null&&Q!==D&&K>0){if(Q instanceof f.BlockEmbed||D instanceof f.BlockEmbed){this.optimize();return}if(Q instanceof g.default){var j=Q.newlineIndex(Q.length(),!0);if(j>-1&&(Q=Q.split(j+1),Q===D)){this.optimize();return}}else if(D instanceof g.default){var U=D.newlineIndex(0);U>-1&&D.split(U+1)}var Y=D.children.head instanceof y.default?null:D.children.head;Q.moveChildren(D,Y),Q.remove()}this.optimize()}},{key:"enable",value:function(){var P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",P)}},{key:"formatAt",value:function(P,M,$,Z){this.whitelist!=null&&!this.whitelist[$]||(a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"formatAt",this).call(this,P,M,$,Z),this.optimize())}},{key:"insertAt",value:function(P,M,$){if(!($!=null&&this.whitelist!=null&&!this.whitelist[M])){if(P>=this.length())if($==null||u.default.query(M,u.default.Scope.BLOCK)==null){var Z=u.default.create(this.statics.defaultChild);this.appendChild(Z),$==null&&M.endsWith(` 3753`)&&(M=M.slice(0,-1)),Z.insertAt(0,M,$)}else{var Q=u.default.create(M,$);this.appendChild(Q)}else a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"insertAt",this).call(this,P,M,$);this.optimize()}}},{key:"insertBefore",value:function(P,M){if(P.statics.scope===u.default.Scope.INLINE_BLOT){var $=u.default.create(this.statics.defaultChild);$.appendChild(P),P=$}a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"insertBefore",this).call(this,P,M)}},{key:"leaf",value:function(P){return this.path(P).pop()||[null,-1]}},{key:"line",value:function(P){return P===this.length()?this.line(P-1):this.descendant(E,P)}},{key:"lines",value:function(){var P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,$=function Z(Q,K,B){var V=[],D=B;return Q.children.forEachAt(K,B,function(j,U,Y){E(j)?V.push(j):j instanceof u.default.Container&&(V=V.concat(Z(j,U,D))),D-=Y}),V};return $(this,P,M)}},{key:"optimize",value:function(){var P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.batch!==!0&&(a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"optimize",this).call(this,P,M),P.length>0&&this.emitter.emit(d.default.events.SCROLL_OPTIMIZE,P,M))}},{key:"path",value:function(P){return a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"path",this).call(this,P).slice(1)}},{key:"update",value:function(P){if(this.batch!==!0){var M=d.default.sources.USER;typeof P=="string"&&(M=P),Array.isArray(P)||(P=this.observer.takeRecords()),P.length>0&&this.emitter.emit(d.default.events.SCROLL_BEFORE_UPDATE,M,P),a(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"update",this).call(this,P.concat([])),P.length>0&&this.emitter.emit(d.default.events.SCROLL_UPDATE,M,P)}}}]),k}(u.default.Scroll);T.blotName="scroll",T.className="ql-editor",T.tagName="DIV",T.defaultChild="block",T.allowedChildren=[p.default,f.BlockEmbed,b.default],r.default=T},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.SHORTKEY=r.default=void 0;var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(F){return typeof F}:function(F){return F&&typeof Symbol=="function"&&F.constructor===Symbol&&F!==Symbol.prototype?"symbol":typeof F},o=function(){function F(q,ee){var te=[],ae=!0,_e=!1,Ee=void 0;try{for(var Ce=q[Symbol.iterator](),qe;!(ae=(qe=Ce.next()).done)&&(te.push(qe.value),!(ee&&te.length===ee));ae=!0);}catch(Ze){_e=!0,Ee=Ze}finally{try{!ae&&Ce.return&&Ce.return()}finally{if(_e)throw Ee}}return te}return function(q,ee){if(Array.isArray(q))return q;if(Symbol.iterator in Object(q))return F(q,ee);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(){function F(q,ee){for(var te=0;te<ee.length;te++){var ae=ee[te];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(q,ae.key,ae)}}return function(q,ee,te){return ee&&F(q.prototype,ee),te&&F(q,te),q}}(),l=i(21),u=S(l),c=i(11),d=S(c),f=i(3),p=S(f),_=i(2),y=S(_),w=i(20),g=S(w),m=i(0),b=S(m),v=i(5),A=S(v),N=i(10),x=S(N),E=i(9),T=S(E);function S(F){return F&&F.__esModule?F:{default:F}}function k(F,q,ee){return q in F?Object.defineProperty(F,q,{value:ee,enumerable:!0,configurable:!0,writable:!0}):F[q]=ee,F}function I(F,q){if(!(F instanceof q))throw new TypeError("Cannot call a class as a function")}function P(F,q){if(!F)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return q&&(typeof q=="object"||typeof q=="function")?q:F}function M(F,q){if(typeof q!="function"&&q!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof q);F.prototype=Object.create(q&&q.prototype,{constructor:{value:F,enumerable:!1,writable:!0,configurable:!0}}),q&&(Object.setPrototypeOf?Object.setPrototypeOf(F,q):F.__proto__=q)}var $=(0,x.default)("quill:keyboard"),Z=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",Q=function(F){M(q,F),a(q,null,[{key:"match",value:function(te,ae){return ae=W(ae),["altKey","ctrlKey","metaKey","shiftKey"].some(function(_e){return!!ae[_e]!==te[_e]&&ae[_e]!==null})?!1:ae.key===(te.which||te.keyCode)}}]);function q(ee,te){I(this,q);var ae=P(this,(q.__proto__||Object.getPrototypeOf(q)).call(this,ee,te));return ae.bindings={},Object.keys(ae.options.bindings).forEach(function(_e){_e==="list autofill"&&ee.scroll.whitelist!=null&&!ee.scroll.whitelist.list||ae.options.bindings[_e]&&ae.addBinding(ae.options.bindings[_e])}),ae.addBinding({key:q.keys.ENTER,shiftKey:null},j),ae.addBinding({key:q.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},function(){}),/Firefox/i.test(navigator.userAgent)?(ae.addBinding({key:q.keys.BACKSPACE},{collapsed:!0},B),ae.addBinding({key:q.keys.DELETE},{collapsed:!0},V)):(ae.addBinding({key:q.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},B),ae.addBinding({key:q.keys.DELETE},{collapsed:!0,suffix:/^.?$/},V)),ae.addBinding({key:q.keys.BACKSPACE},{collapsed:!1},D),ae.addBinding({key:q.keys.DELETE},{collapsed:!1},D),ae.addBinding({key:q.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},B),ae.listen(),ae}return a(q,[{key:"addBinding",value:function(te){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},_e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Ee=W(te);if(Ee==null||Ee.key==null)return $.warn("Attempted to add invalid keyboard binding",Ee);typeof ae=="function"&&(ae={handler:ae}),typeof _e=="function"&&(_e={handler:_e}),Ee=(0,p.default)(Ee,ae,_e),this.bindings[Ee.key]=this.bindings[Ee.key]||[],this.bindings[Ee.key].push(Ee)}},{key:"listen",value:function(){var te=this;this.quill.root.addEventListener("keydown",function(ae){if(!ae.defaultPrevented){var _e=ae.which||ae.keyCode,Ee=(te.bindings[_e]||[]).filter(function(Xe){return q.match(ae,Xe)});if(Ee.length!==0){var Ce=te.quill.getSelection();if(!(Ce==null||!te.quill.hasFocus())){var qe=te.quill.getLine(Ce.index),Ze=o(qe,2),Et=Ze[0],kt=Ze[1],ie=te.quill.getLeaf(Ce.index),se=o(ie,2),pe=se[0],ye=se[1],ue=Ce.length===0?[pe,ye]:te.quill.getLeaf(Ce.index+Ce.length),Ue=o(ue,2),Fe=Ue[0],oe=Ue[1],me=pe instanceof b.default.Text?pe.value().slice(0,ye):"",je=Fe instanceof b.default.Text?Fe.value().slice(oe):"",Ne={collapsed:Ce.length===0,empty:Ce.length===0&&Et.length()<=1,format:te.quill.getFormat(Ce),offset:kt,prefix:me,suffix:je},dt=Ee.some(function(Xe){if(Xe.collapsed!=null&&Xe.collapsed!==Ne.collapsed||Xe.empty!=null&&Xe.empty!==Ne.empty||Xe.offset!=null&&Xe.offset!==Ne.offset)return!1;if(Array.isArray(Xe.format)){if(Xe.format.every(function(Pt){return Ne.format[Pt]==null}))return!1}else if(s(Xe.format)==="object"&&!Object.keys(Xe.format).every(function(Pt){return Xe.format[Pt]===!0?Ne.format[Pt]!=null:Xe.format[Pt]===!1?Ne.format[Pt]==null:(0,d.default)(Xe.format[Pt],Ne.format[Pt])}))return!1;return Xe.prefix!=null&&!Xe.prefix.test(Ne.prefix)||Xe.suffix!=null&&!Xe.suffix.test(Ne.suffix)?!1:Xe.handler.call(te,Ce,Ne)!==!0});dt&&ae.preventDefault()}}}})}}]),q}(T.default);Q.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},Q.DEFAULTS={bindings:{bold:Y("bold"),italic:Y("italic"),underline:Y("underline"),indent:{key:Q.keys.TAB,format:["blockquote","indent","list"],handler:function(q,ee){if(ee.collapsed&&ee.offset!==0)return!0;this.quill.format("indent","+1",A.default.sources.USER)}},outdent:{key:Q.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(q,ee){if(ee.collapsed&&ee.offset!==0)return!0;this.quill.format("indent","-1",A.default.sources.USER)}},"outdent backspace":{key:Q.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(q,ee){ee.format.indent!=null?this.quill.format("indent","-1",A.default.sources.USER):ee.format.list!=null&&this.quill.format("list",!1,A.default.sources.USER)}},"indent code-block":U(!0),"outdent code-block":U(!1),"remove tab":{key:Q.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(q){this.quill.deleteText(q.index-1,1,A.default.sources.USER)}},tab:{key:Q.keys.TAB,handler:function(q){this.quill.history.cutoff();var ee=new y.default().retain(q.index).delete(q.length).insert(" ");this.quill.updateContents(ee,A.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(q.index+1,A.default.sources.SILENT)}},"list empty enter":{key:Q.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(q,ee){this.quill.format("list",!1,A.default.sources.USER),ee.format.indent&&this.quill.format("indent",!1,A.default.sources.USER)}},"checklist enter":{key:Q.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(q){var ee=this.quill.getLine(q.index),te=o(ee,2),ae=te[0],_e=te[1],Ee=(0,p.default)({},ae.formats(),{list:"checked"}),Ce=new y.default().retain(q.index).insert(` 3754`,Ee).retain(ae.length()-_e-1).retain(1,{list:"unchecked"});this.quill.updateContents(Ce,A.default.sources.USER),this.quill.setSelection(q.index+1,A.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:Q.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(q,ee){var te=this.quill.getLine(q.index),ae=o(te,2),_e=ae[0],Ee=ae[1],Ce=new y.default().retain(q.index).insert(` 3755`,ee.format).retain(_e.length()-Ee-1).retain(1,{header:null});this.quill.updateContents(Ce,A.default.sources.USER),this.quill.setSelection(q.index+1,A.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(q,ee){var te=ee.prefix.length,ae=this.quill.getLine(q.index),_e=o(ae,2),Ee=_e[0],Ce=_e[1];if(Ce>te)return!0;var qe=void 0;switch(ee.prefix.trim()){case"[]":case"[ ]":qe="unchecked";break;case"[x]":qe="checked";break;case"-":case"*":qe="bullet";break;default:qe="ordered"}this.quill.insertText(q.index," ",A.default.sources.USER),this.quill.history.cutoff();var Ze=new y.default().retain(q.index-Ce).delete(te+1).retain(Ee.length()-2-Ce).retain(1,{list:qe});this.quill.updateContents(Ze,A.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(q.index-te,A.default.sources.SILENT)}},"code exit":{key:Q.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(q){var ee=this.quill.getLine(q.index),te=o(ee,2),ae=te[0],_e=te[1],Ee=new y.default().retain(q.index+ae.length()-_e-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(Ee,A.default.sources.USER)}},"embed left":K(Q.keys.LEFT,!1),"embed left shift":K(Q.keys.LEFT,!0),"embed right":K(Q.keys.RIGHT,!1),"embed right shift":K(Q.keys.RIGHT,!0)}};function K(F,q){var ee,te=F===Q.keys.LEFT?"prefix":"suffix";return ee={key:F,shiftKey:q,altKey:null},k(ee,te,/^$/),k(ee,"handler",function(_e){var Ee=_e.index;F===Q.keys.RIGHT&&(Ee+=_e.length+1);var Ce=this.quill.getLeaf(Ee),qe=o(Ce,1),Ze=qe[0];return Ze instanceof b.default.Embed?(F===Q.keys.LEFT?q?this.quill.setSelection(_e.index-1,_e.length+1,A.default.sources.USER):this.quill.setSelection(_e.index-1,A.default.sources.USER):q?this.quill.setSelection(_e.index,_e.length+1,A.default.sources.USER):this.quill.setSelection(_e.index+_e.length+1,A.default.sources.USER),!1):!0}),ee}function B(F,q){if(!(F.index===0||this.quill.getLength()<=1)){var ee=this.quill.getLine(F.index),te=o(ee,1),ae=te[0],_e={};if(q.offset===0){var Ee=this.quill.getLine(F.index-1),Ce=o(Ee,1),qe=Ce[0];if(qe!=null&&qe.length()>1){var Ze=ae.formats(),Et=this.quill.getFormat(F.index-1,1);_e=g.default.attributes.diff(Ze,Et)||{}}}var kt=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(q.prefix)?2:1;this.quill.deleteText(F.index-kt,kt,A.default.sources.USER),Object.keys(_e).length>0&&this.quill.formatLine(F.index-kt,kt,_e,A.default.sources.USER),this.quill.focus()}}function V(F,q){var ee=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(q.suffix)?2:1;if(!(F.index>=this.quill.getLength()-ee)){var te={},ae=0,_e=this.quill.getLine(F.index),Ee=o(_e,1),Ce=Ee[0];if(q.offset>=Ce.length()-1){var qe=this.quill.getLine(F.index+1),Ze=o(qe,1),Et=Ze[0];if(Et){var kt=Ce.formats(),ie=this.quill.getFormat(F.index,1);te=g.default.attributes.diff(kt,ie)||{},ae=Et.length()}}this.quill.deleteText(F.index,ee,A.default.sources.USER),Object.keys(te).length>0&&this.quill.formatLine(F.index+ae-1,ee,te,A.default.sources.USER)}}function D(F){var q=this.quill.getLines(F),ee={};if(q.length>1){var te=q[0].formats(),ae=q[q.length-1].formats();ee=g.default.attributes.diff(ae,te)||{}}this.quill.deleteText(F,A.default.sources.USER),Object.keys(ee).length>0&&this.quill.formatLine(F.index,1,ee,A.default.sources.USER),this.quill.setSelection(F.index,A.default.sources.SILENT),this.quill.focus()}function j(F,q){var ee=this;F.length>0&&this.quill.scroll.deleteAt(F.index,F.length);var te=Object.keys(q.format).reduce(function(ae,_e){return b.default.query(_e,b.default.Scope.BLOCK)&&!Array.isArray(q.format[_e])&&(ae[_e]=q.format[_e]),ae},{});this.quill.insertText(F.index,` 3756`,te,A.default.sources.USER),this.quill.setSelection(F.index+1,A.default.sources.SILENT),this.quill.focus(),Object.keys(q.format).forEach(function(ae){te[ae]==null&&(Array.isArray(q.format[ae])||ae!=="link"&&ee.quill.format(ae,q.format[ae],A.default.sources.USER))})}function U(F){return{key:Q.keys.TAB,shiftKey:!F,format:{"code-block":!0},handler:function(ee){var te=b.default.query("code-block"),ae=ee.index,_e=ee.length,Ee=this.quill.scroll.descendant(te,ae),Ce=o(Ee,2),qe=Ce[0],Ze=Ce[1];if(qe!=null){var Et=this.quill.getIndex(qe),kt=qe.newlineIndex(Ze,!0)+1,ie=qe.newlineIndex(Et+Ze+_e),se=qe.domNode.textContent.slice(kt,ie).split(` 3757`);Ze=0,se.forEach(function(pe,ye){F?(qe.insertAt(kt+Ze,te.TAB),Ze+=te.TAB.length,ye===0?ae+=te.TAB.length:_e+=te.TAB.length):pe.startsWith(te.TAB)&&(qe.deleteAt(kt+Ze,te.TAB.length),Ze-=te.TAB.length,ye===0?ae-=te.TAB.length:_e-=te.TAB.length),Ze+=pe.length+1}),this.quill.update(A.default.sources.USER),this.quill.setSelection(ae,_e,A.default.sources.SILENT)}}}}function Y(F){return{key:F[0].toUpperCase(),shortKey:!0,handler:function(ee,te){this.quill.format(F,!te.format[F],A.default.sources.USER)}}}function W(F){if(typeof F=="string"||typeof F=="number")return W({key:F});if((typeof F>"u"?"undefined":s(F))==="object"&&(F=(0,u.default)(F,!1)),typeof F.key=="string")if(Q.keys[F.key.toUpperCase()]!=null)F.key=Q.keys[F.key.toUpperCase()];else if(F.key.length===1)F.key=F.key.toUpperCase().charCodeAt(0);else return null;return F.shortKey&&(F[Z]=F.shortKey,delete F.shortKey),F}r.default=Q,r.SHORTKEY=Z},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function g(m,b){var v=[],A=!0,N=!1,x=void 0;try{for(var E=m[Symbol.iterator](),T;!(A=(T=E.next()).done)&&(v.push(T.value),!(b&&v.length===b));A=!0);}catch(S){N=!0,x=S}finally{try{!A&&E.return&&E.return()}finally{if(N)throw x}}return v}return function(m,b){if(Array.isArray(m))return m;if(Symbol.iterator in Object(m))return g(m,b);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function g(m,b,v){m===null&&(m=Function.prototype);var A=Object.getOwnPropertyDescriptor(m,b);if(A===void 0){var N=Object.getPrototypeOf(m);return N===null?void 0:g(N,b,v)}else{if("value"in A)return A.value;var x=A.get;return x===void 0?void 0:x.call(v)}},a=function(){function g(m,b){for(var v=0;v<b.length;v++){var A=b[v];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(m,A.key,A)}}return function(m,b,v){return b&&g(m.prototype,b),v&&g(m,v),m}}(),l=i(0),u=f(l),c=i(7),d=f(c);function f(g){return g&&g.__esModule?g:{default:g}}function p(g,m){if(!(g instanceof m))throw new TypeError("Cannot call a class as a function")}function _(g,m){if(!g)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m&&(typeof m=="object"||typeof m=="function")?m:g}function y(g,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);g.prototype=Object.create(m&&m.prototype,{constructor:{value:g,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(g,m):g.__proto__=m)}var w=function(g){y(m,g),a(m,null,[{key:"value",value:function(){}}]);function m(b,v){p(this,m);var A=_(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,b));return A.selection=v,A.textNode=document.createTextNode(m.CONTENTS),A.domNode.appendChild(A.textNode),A._length=0,A}return a(m,[{key:"detach",value:function(){this.parent!=null&&this.parent.removeChild(this)}},{key:"format",value:function(v,A){if(this._length!==0)return o(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"format",this).call(this,v,A);for(var N=this,x=0;N!=null&&N.statics.scope!==u.default.Scope.BLOCK_BLOT;)x+=N.offset(N.parent),N=N.parent;N!=null&&(this._length=m.CONTENTS.length,N.optimize(),N.formatAt(x,m.CONTENTS.length,v,A),this._length=0)}},{key:"index",value:function(v,A){return v===this.textNode?0:o(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"index",this).call(this,v,A)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){o(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!(this.selection.composing||this.parent==null)){var v=this.textNode,A=this.selection.getNativeRange(),N=void 0,x=void 0,E=void 0;if(A!=null&&A.start.node===v&&A.end.node===v){var T=[v,A.start.offset,A.end.offset];N=T[0],x=T[1],E=T[2]}for(;this.domNode.lastChild!=null&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==m.CONTENTS){var S=this.textNode.data.split(m.CONTENTS).join("");this.next instanceof d.default?(N=this.next.domNode,this.next.insertAt(0,S),this.textNode.data=m.CONTENTS):(this.textNode.data=S,this.parent.insertBefore(u.default.create(this.textNode),this),this.textNode=document.createTextNode(m.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),x!=null){var k=[x,E].map(function(P){return Math.max(0,Math.min(N.data.length,P-1))}),I=s(k,2);return x=I[0],E=I[1],{startNode:N,startOffset:x,endNode:N,endOffset:E}}}}},{key:"update",value:function(v,A){var N=this;if(v.some(function(E){return E.type==="characterData"&&E.target===N.textNode})){var x=this.restore();x&&(A.range=x)}}},{key:"value",value:function(){return""}}]),m}(u.default.Embed);w.blotName="cursor",w.className="ql-cursor",w.tagName="span",w.CONTENTS="\uFEFF",r.default=w},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(0),o=u(s),a=i(4),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(){return c(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return y}(o.default.Container);p.allowedChildren=[l.default,a.BlockEmbed,p],r.default=p},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.ColorStyle=r.ColorClass=r.ColorAttributor=void 0;var s=function(){function w(g,m){for(var b=0;b<m.length;b++){var v=m[b];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(g,v.key,v)}}return function(g,m,b){return m&&w(g.prototype,m),b&&w(g,b),g}}(),o=function w(g,m,b){g===null&&(g=Function.prototype);var v=Object.getOwnPropertyDescriptor(g,m);if(v===void 0){var A=Object.getPrototypeOf(g);return A===null?void 0:w(A,m,b)}else{if("value"in v)return v.value;var N=v.get;return N===void 0?void 0:N.call(b)}},a=i(0),l=u(a);function u(w){return w&&w.__esModule?w:{default:w}}function c(w,g){if(!(w instanceof g))throw new TypeError("Cannot call a class as a function")}function d(w,g){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:w}function f(w,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);w.prototype=Object.create(g&&g.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(w,g):w.__proto__=g)}var p=function(w){f(g,w);function g(){return c(this,g),d(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"value",value:function(b){var v=o(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"value",this).call(this,b);return v.startsWith("rgb(")?(v=v.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+v.split(",").map(function(A){return("00"+parseInt(A).toString(16)).slice(-2)}).join("")):v}}]),g}(l.default.Attributor.Style),_=new l.default.Attributor.Class("color","ql-color",{scope:l.default.Scope.INLINE}),y=new p("color","color",{scope:l.default.Scope.INLINE});r.ColorAttributor=p,r.ColorClass=_,r.ColorStyle=y},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.sanitize=r.default=void 0;var s=function(){function y(w,g){for(var m=0;m<g.length;m++){var b=g[m];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(w,b.key,b)}}return function(w,g,m){return g&&y(w.prototype,g),m&&y(w,m),w}}(),o=function y(w,g,m){w===null&&(w=Function.prototype);var b=Object.getOwnPropertyDescriptor(w,g);if(b===void 0){var v=Object.getPrototypeOf(w);return v===null?void 0:y(v,g,m)}else{if("value"in b)return b.value;var A=b.get;return A===void 0?void 0:A.call(m)}},a=i(6),l=u(a);function u(y){return y&&y.__esModule?y:{default:y}}function c(y,w){if(!(y instanceof w))throw new TypeError("Cannot call a class as a function")}function d(y,w){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:y}function f(y,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);y.prototype=Object.create(w&&w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(y,w):y.__proto__=w)}var p=function(y){f(w,y);function w(){return c(this,w),d(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return s(w,[{key:"format",value:function(m,b){if(m!==this.statics.blotName||!b)return o(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"format",this).call(this,m,b);b=this.constructor.sanitize(b),this.domNode.setAttribute("href",b)}}],[{key:"create",value:function(m){var b=o(w.__proto__||Object.getPrototypeOf(w),"create",this).call(this,m);return m=this.sanitize(m),b.setAttribute("href",m),b.setAttribute("rel","noopener noreferrer"),b.setAttribute("target","_blank"),b}},{key:"formats",value:function(m){return m.getAttribute("href")}},{key:"sanitize",value:function(m){return _(m,this.PROTOCOL_WHITELIST)?m:this.SANITIZED_URL}}]),w}(l.default);p.blotName="link",p.tagName="A",p.SANITIZED_URL="about:blank",p.PROTOCOL_WHITELIST=["http","https","mailto","tel"];function _(y,w){var g=document.createElement("a");g.href=y;var m=g.href.slice(0,g.href.indexOf(":"));return w.indexOf(m)>-1}r.default=p,r.sanitize=_},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(w){return typeof w}:function(w){return w&&typeof Symbol=="function"&&w.constructor===Symbol&&w!==Symbol.prototype?"symbol":typeof w},o=function(){function w(g,m){for(var b=0;b<m.length;b++){var v=m[b];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(g,v.key,v)}}return function(g,m,b){return m&&w(g.prototype,m),b&&w(g,b),g}}(),a=i(23),l=d(a),u=i(107),c=d(u);function d(w){return w&&w.__esModule?w:{default:w}}function f(w,g){if(!(w instanceof g))throw new TypeError("Cannot call a class as a function")}var p=0;function _(w,g){w.setAttribute(g,w.getAttribute(g)!=="true")}var y=function(){function w(g){var m=this;f(this,w),this.select=g,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){m.togglePicker()}),this.label.addEventListener("keydown",function(b){switch(b.keyCode){case l.default.keys.ENTER:m.togglePicker();break;case l.default.keys.ESCAPE:m.escape(),b.preventDefault();break}}),this.select.addEventListener("change",this.update.bind(this))}return o(w,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),_(this.label,"aria-expanded"),_(this.options,"aria-hidden")}},{key:"buildItem",value:function(m){var b=this,v=document.createElement("span");return v.tabIndex="0",v.setAttribute("role","button"),v.classList.add("ql-picker-item"),m.hasAttribute("value")&&v.setAttribute("data-value",m.getAttribute("value")),m.textContent&&v.setAttribute("data-label",m.textContent),v.addEventListener("click",function(){b.selectItem(v,!0)}),v.addEventListener("keydown",function(A){switch(A.keyCode){case l.default.keys.ENTER:b.selectItem(v,!0),A.preventDefault();break;case l.default.keys.ESCAPE:b.escape(),A.preventDefault();break}}),v}},{key:"buildLabel",value:function(){var m=document.createElement("span");return m.classList.add("ql-picker-label"),m.innerHTML=c.default,m.tabIndex="0",m.setAttribute("role","button"),m.setAttribute("aria-expanded","false"),this.container.appendChild(m),m}},{key:"buildOptions",value:function(){var m=this,b=document.createElement("span");b.classList.add("ql-picker-options"),b.setAttribute("aria-hidden","true"),b.tabIndex="-1",b.id="ql-picker-options-"+p,p+=1,this.label.setAttribute("aria-controls",b.id),this.options=b,[].slice.call(this.select.options).forEach(function(v){var A=m.buildItem(v);b.appendChild(A),v.selected===!0&&m.selectItem(A)}),this.container.appendChild(b)}},{key:"buildPicker",value:function(){var m=this;[].slice.call(this.select.attributes).forEach(function(b){m.container.setAttribute(b.name,b.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var m=this;this.close(),setTimeout(function(){return m.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(m){var b=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,v=this.container.querySelector(".ql-selected");if(m!==v&&(v!=null&&v.classList.remove("ql-selected"),m!=null&&(m.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(m.parentNode.children,m),m.hasAttribute("data-value")?this.label.setAttribute("data-value",m.getAttribute("data-value")):this.label.removeAttribute("data-value"),m.hasAttribute("data-label")?this.label.setAttribute("data-label",m.getAttribute("data-label")):this.label.removeAttribute("data-label"),b))){if(typeof Event=="function")this.select.dispatchEvent(new Event("change"));else if((typeof Event>"u"?"undefined":s(Event))==="object"){var A=document.createEvent("Event");A.initEvent("change",!0,!0),this.select.dispatchEvent(A)}this.close()}}},{key:"update",value:function(){var m=void 0;if(this.select.selectedIndex>-1){var b=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];m=this.select.options[this.select.selectedIndex],this.selectItem(b)}else this.selectItem(null);var v=m!=null&&m!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",v)}}]),w}();r.default=y},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(0),o=$(s),a=i(5),l=$(a),u=i(4),c=$(u),d=i(16),f=$(d),p=i(25),_=$(p),y=i(24),w=$(y),g=i(35),m=$(g),b=i(6),v=$(b),A=i(22),N=$(A),x=i(7),E=$(x),T=i(55),S=$(T),k=i(42),I=$(k),P=i(23),M=$(P);function $(Z){return Z&&Z.__esModule?Z:{default:Z}}l.default.register({"blots/block":c.default,"blots/block/embed":u.BlockEmbed,"blots/break":f.default,"blots/container":_.default,"blots/cursor":w.default,"blots/embed":m.default,"blots/inline":v.default,"blots/scroll":N.default,"blots/text":E.default,"modules/clipboard":S.default,"modules/history":I.default,"modules/keyboard":M.default}),o.default.register(c.default,f.default,w.default,v.default,N.default,E.default),r.default=l.default},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(1),o=function(){function a(l){this.domNode=l,this.domNode[s.DATA_KEY]={blot:this}}return Object.defineProperty(a.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),a.create=function(l){if(this.tagName==null)throw new s.ParchmentError("Blot definition missing tagName");var u;return Array.isArray(this.tagName)?(typeof l=="string"&&(l=l.toUpperCase(),parseInt(l).toString()===l&&(l=parseInt(l))),typeof l=="number"?u=document.createElement(this.tagName[l-1]):this.tagName.indexOf(l)>-1?u=document.createElement(l):u=document.createElement(this.tagName[0])):u=document.createElement(this.tagName),this.className&&u.classList.add(this.className),u},a.prototype.attach=function(){this.parent!=null&&(this.scroll=this.parent.scroll)},a.prototype.clone=function(){var l=this.domNode.cloneNode(!1);return s.create(l)},a.prototype.detach=function(){this.parent!=null&&this.parent.removeChild(this),delete this.domNode[s.DATA_KEY]},a.prototype.deleteAt=function(l,u){var c=this.isolate(l,u);c.remove()},a.prototype.formatAt=function(l,u,c,d){var f=this.isolate(l,u);if(s.query(c,s.Scope.BLOT)!=null&&d)f.wrap(c,d);else if(s.query(c,s.Scope.ATTRIBUTE)!=null){var p=s.create(this.statics.scope);f.wrap(p),p.format(c,d)}},a.prototype.insertAt=function(l,u,c){var d=c==null?s.create("text",u):s.create(u,c),f=this.split(l);this.parent.insertBefore(d,f)},a.prototype.insertInto=function(l,u){u===void 0&&(u=null),this.parent!=null&&this.parent.children.remove(this);var c=null;l.children.insertBefore(this,u),u!=null&&(c=u.domNode),(this.domNode.parentNode!=l.domNode||this.domNode.nextSibling!=c)&&l.domNode.insertBefore(this.domNode,c),this.parent=l,this.attach()},a.prototype.isolate=function(l,u){var c=this.split(l);return c.split(u),c},a.prototype.length=function(){return 1},a.prototype.offset=function(l){return l===void 0&&(l=this.parent),this.parent==null||this==l?0:this.parent.children.offset(this)+this.parent.offset(l)},a.prototype.optimize=function(l){this.domNode[s.DATA_KEY]!=null&&delete this.domNode[s.DATA_KEY].mutations},a.prototype.remove=function(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},a.prototype.replace=function(l){l.parent!=null&&(l.parent.insertBefore(this,l.next),l.remove())},a.prototype.replaceWith=function(l,u){var c=typeof l=="string"?s.create(l,u):l;return c.replace(this),c},a.prototype.split=function(l,u){return l===0?this:this.next},a.prototype.update=function(l,u){},a.prototype.wrap=function(l,u){var c=typeof l=="string"?s.create(l,u):l;return this.parent!=null&&this.parent.insertBefore(c,this.next),c.appendChild(this),c},a.blotName="abstract",a}();r.default=o},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(12),o=i(32),a=i(33),l=i(1),u=function(){function c(d){this.attributes={},this.domNode=d,this.build()}return c.prototype.attribute=function(d,f){f?d.add(this.domNode,f)&&(d.value(this.domNode)!=null?this.attributes[d.attrName]=d:delete this.attributes[d.attrName]):(d.remove(this.domNode),delete this.attributes[d.attrName])},c.prototype.build=function(){var d=this;this.attributes={};var f=s.default.keys(this.domNode),p=o.default.keys(this.domNode),_=a.default.keys(this.domNode);f.concat(p).concat(_).forEach(function(y){var w=l.query(y,l.Scope.ATTRIBUTE);w instanceof s.default&&(d.attributes[w.attrName]=w)})},c.prototype.copy=function(d){var f=this;Object.keys(this.attributes).forEach(function(p){var _=f.attributes[p].value(f.domNode);d.format(p,_)})},c.prototype.move=function(d){var f=this;this.copy(d),Object.keys(this.attributes).forEach(function(p){f.attributes[p].remove(f.domNode)}),this.attributes={}},c.prototype.values=function(){var d=this;return Object.keys(this.attributes).reduce(function(f,p){return f[p]=d.attributes[p].value(d.domNode),f},{})},c}();r.default=u},function(n,r,i){var s=this&&this.__extends||function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)d.hasOwnProperty(f)&&(c[f]=d[f])};return function(c,d){u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(12);function a(u,c){var d=u.getAttribute("class")||"";return d.split(/\s+/).filter(function(f){return f.indexOf(c+"-")===0})}var l=function(u){s(c,u);function c(){return u!==null&&u.apply(this,arguments)||this}return c.keys=function(d){return(d.getAttribute("class")||"").split(/\s+/).map(function(f){return f.split("-").slice(0,-1).join("-")})},c.prototype.add=function(d,f){return this.canAdd(d,f)?(this.remove(d),d.classList.add(this.keyName+"-"+f),!0):!1},c.prototype.remove=function(d){var f=a(d,this.keyName);f.forEach(function(p){d.classList.remove(p)}),d.classList.length===0&&d.removeAttribute("class")},c.prototype.value=function(d){var f=a(d,this.keyName)[0]||"",p=f.slice(this.keyName.length+1);return this.canAdd(d,p)?p:""},c}(o.default);r.default=l},function(n,r,i){var s=this&&this.__extends||function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)d.hasOwnProperty(f)&&(c[f]=d[f])};return function(c,d){u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(12);function a(u){var c=u.split("-"),d=c.slice(1).map(function(f){return f[0].toUpperCase()+f.slice(1)}).join("");return c[0]+d}var l=function(u){s(c,u);function c(){return u!==null&&u.apply(this,arguments)||this}return c.keys=function(d){return(d.getAttribute("style")||"").split(";").map(function(f){var p=f.split(":");return p[0].trim()})},c.prototype.add=function(d,f){return this.canAdd(d,f)?(d.style[a(this.keyName)]=f,!0):!1},c.prototype.remove=function(d){d.style[a(this.keyName)]="",d.getAttribute("style")||d.removeAttribute("style")},c.prototype.value=function(d){var f=d.style[a(this.keyName)];return this.canAdd(d,f)?f:""},c}(o.default);r.default=l},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function l(u,c){for(var d=0;d<c.length;d++){var f=c[d];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(u,f.key,f)}}return function(u,c,d){return c&&l(u.prototype,c),d&&l(u,d),u}}();function o(l,u){if(!(l instanceof u))throw new TypeError("Cannot call a class as a function")}var a=function(){function l(u,c){o(this,l),this.quill=u,this.options=c,this.modules={}}return s(l,[{key:"init",value:function(){var c=this;Object.keys(this.options.modules).forEach(function(d){c.modules[d]==null&&c.addModule(d)})}},{key:"addModule",value:function(c){var d=this.quill.constructor.import("modules/"+c);return this.modules[c]=new d(this.quill,this.options.modules[c]||{}),this.modules[c]}}]),l}();a.DEFAULTS={modules:{}},a.themes={default:a},r.default=a},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function g(m,b){for(var v=0;v<b.length;v++){var A=b[v];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(m,A.key,A)}}return function(m,b,v){return b&&g(m.prototype,b),v&&g(m,v),m}}(),o=function g(m,b,v){m===null&&(m=Function.prototype);var A=Object.getOwnPropertyDescriptor(m,b);if(A===void 0){var N=Object.getPrototypeOf(m);return N===null?void 0:g(N,b,v)}else{if("value"in A)return A.value;var x=A.get;return x===void 0?void 0:x.call(v)}},a=i(0),l=d(a),u=i(7),c=d(u);function d(g){return g&&g.__esModule?g:{default:g}}function f(g,m){if(!(g instanceof m))throw new TypeError("Cannot call a class as a function")}function p(g,m){if(!g)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m&&(typeof m=="object"||typeof m=="function")?m:g}function _(g,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);g.prototype=Object.create(m&&m.prototype,{constructor:{value:g,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(g,m):g.__proto__=m)}var y="\uFEFF",w=function(g){_(m,g);function m(b){f(this,m);var v=p(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,b));return v.contentNode=document.createElement("span"),v.contentNode.setAttribute("contenteditable",!1),[].slice.call(v.domNode.childNodes).forEach(function(A){v.contentNode.appendChild(A)}),v.leftGuard=document.createTextNode(y),v.rightGuard=document.createTextNode(y),v.domNode.appendChild(v.leftGuard),v.domNode.appendChild(v.contentNode),v.domNode.appendChild(v.rightGuard),v}return s(m,[{key:"index",value:function(v,A){return v===this.leftGuard?0:v===this.rightGuard?1:o(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"index",this).call(this,v,A)}},{key:"restore",value:function(v){var A=void 0,N=void 0,x=v.data.split(y).join("");if(v===this.leftGuard)if(this.prev instanceof c.default){var E=this.prev.length();this.prev.insertAt(E,x),A={startNode:this.prev.domNode,startOffset:E+x.length}}else N=document.createTextNode(x),this.parent.insertBefore(l.default.create(N),this),A={startNode:N,startOffset:x.length};else v===this.rightGuard&&(this.next instanceof c.default?(this.next.insertAt(0,x),A={startNode:this.next.domNode,startOffset:x.length}):(N=document.createTextNode(x),this.parent.insertBefore(l.default.create(N),this.next),A={startNode:N,startOffset:x.length}));return v.data=y,A}},{key:"update",value:function(v,A){var N=this;v.forEach(function(x){if(x.type==="characterData"&&(x.target===N.leftGuard||x.target===N.rightGuard)){var E=N.restore(x.target);E&&(A.range=E)}})}}]),m}(l.default.Embed);r.default=w},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.AlignStyle=r.AlignClass=r.AlignAttribute=void 0;var s=i(0),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}var l={scope:o.default.Scope.BLOCK,whitelist:["right","center","justify"]},u=new o.default.Attributor.Attribute("align","align",l),c=new o.default.Attributor.Class("align","ql-align",l),d=new o.default.Attributor.Style("align","text-align",l);r.AlignAttribute=u,r.AlignClass=c,r.AlignStyle=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.BackgroundStyle=r.BackgroundClass=void 0;var s=i(0),o=l(s),a=i(26);function l(d){return d&&d.__esModule?d:{default:d}}var u=new o.default.Attributor.Class("background","ql-bg",{scope:o.default.Scope.INLINE}),c=new a.ColorAttributor("background","background-color",{scope:o.default.Scope.INLINE});r.BackgroundClass=u,r.BackgroundStyle=c},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.DirectionStyle=r.DirectionClass=r.DirectionAttribute=void 0;var s=i(0),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}var l={scope:o.default.Scope.BLOCK,whitelist:["rtl"]},u=new o.default.Attributor.Attribute("direction","dir",l),c=new o.default.Attributor.Class("direction","ql-direction",l),d=new o.default.Attributor.Style("direction","direction",l);r.DirectionAttribute=u,r.DirectionClass=c,r.DirectionStyle=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.FontClass=r.FontStyle=void 0;var s=function(){function g(m,b){for(var v=0;v<b.length;v++){var A=b[v];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(m,A.key,A)}}return function(m,b,v){return b&&g(m.prototype,b),v&&g(m,v),m}}(),o=function g(m,b,v){m===null&&(m=Function.prototype);var A=Object.getOwnPropertyDescriptor(m,b);if(A===void 0){var N=Object.getPrototypeOf(m);return N===null?void 0:g(N,b,v)}else{if("value"in A)return A.value;var x=A.get;return x===void 0?void 0:x.call(v)}},a=i(0),l=u(a);function u(g){return g&&g.__esModule?g:{default:g}}function c(g,m){if(!(g instanceof m))throw new TypeError("Cannot call a class as a function")}function d(g,m){if(!g)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m&&(typeof m=="object"||typeof m=="function")?m:g}function f(g,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);g.prototype=Object.create(m&&m.prototype,{constructor:{value:g,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(g,m):g.__proto__=m)}var p={scope:l.default.Scope.INLINE,whitelist:["serif","monospace"]},_=new l.default.Attributor.Class("font","ql-font",p),y=function(g){f(m,g);function m(){return c(this,m),d(this,(m.__proto__||Object.getPrototypeOf(m)).apply(this,arguments))}return s(m,[{key:"value",value:function(v){return o(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"value",this).call(this,v).replace(/["']/g,"")}}]),m}(l.default.Attributor.Style),w=new y("font","font-family",p);r.FontStyle=w,r.FontClass=_},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.SizeStyle=r.SizeClass=void 0;var s=i(0),o=a(s);function a(c){return c&&c.__esModule?c:{default:c}}var l=new o.default.Attributor.Class("size","ql-size",{scope:o.default.Scope.INLINE,whitelist:["small","large","huge"]}),u=new o.default.Attributor.Style("size","font-size",{scope:o.default.Scope.INLINE,whitelist:["10px","18px","32px"]});r.SizeClass=l,r.SizeStyle=u},function(n,r,i){n.exports={align:{"":i(76),center:i(77),right:i(78),justify:i(79)},background:i(80),blockquote:i(81),bold:i(82),clean:i(83),code:i(58),"code-block":i(58),color:i(84),direction:{"":i(85),rtl:i(86)},float:{center:i(87),full:i(88),left:i(89),right:i(90)},formula:i(91),header:{1:i(92),2:i(93)},italic:i(94),image:i(95),indent:{"+1":i(96),"-1":i(97)},link:i(98),list:{ordered:i(99),bullet:i(100),check:i(101)},script:{sub:i(102),super:i(103)},strike:i(104),underline:i(105),video:i(106)}},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.getLastChangeIndex=r.default=void 0;var s=function(){function b(v,A){for(var N=0;N<A.length;N++){var x=A[N];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(v,x.key,x)}}return function(v,A,N){return A&&b(v.prototype,A),N&&b(v,N),v}}(),o=i(0),a=f(o),l=i(5),u=f(l),c=i(9),d=f(c);function f(b){return b&&b.__esModule?b:{default:b}}function p(b,v){if(!(b instanceof v))throw new TypeError("Cannot call a class as a function")}function _(b,v){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return v&&(typeof v=="object"||typeof v=="function")?v:b}function y(b,v){if(typeof v!="function"&&v!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof v);b.prototype=Object.create(v&&v.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),v&&(Object.setPrototypeOf?Object.setPrototypeOf(b,v):b.__proto__=v)}var w=function(b){y(v,b);function v(A,N){p(this,v);var x=_(this,(v.__proto__||Object.getPrototypeOf(v)).call(this,A,N));return x.lastRecorded=0,x.ignoreChange=!1,x.clear(),x.quill.on(u.default.events.EDITOR_CHANGE,function(E,T,S,k){E!==u.default.events.TEXT_CHANGE||x.ignoreChange||(!x.options.userOnly||k===u.default.sources.USER?x.record(T,S):x.transform(T))}),x.quill.keyboard.addBinding({key:"Z",shortKey:!0},x.undo.bind(x)),x.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},x.redo.bind(x)),/Win/i.test(navigator.platform)&&x.quill.keyboard.addBinding({key:"Y",shortKey:!0},x.redo.bind(x)),x}return s(v,[{key:"change",value:function(N,x){if(this.stack[N].length!==0){var E=this.stack[N].pop();this.stack[x].push(E),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(E[N],u.default.sources.USER),this.ignoreChange=!1;var T=m(E[N]);this.quill.setSelection(T)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(N,x){if(N.ops.length!==0){this.stack.redo=[];var E=this.quill.getContents().diff(x),T=Date.now();if(this.lastRecorded+this.options.delay>T&&this.stack.undo.length>0){var S=this.stack.undo.pop();E=E.compose(S.undo),N=S.redo.compose(N)}else this.lastRecorded=T;this.stack.undo.push({redo:N,undo:E}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(N){this.stack.undo.forEach(function(x){x.undo=N.transform(x.undo,!0),x.redo=N.transform(x.redo,!0)}),this.stack.redo.forEach(function(x){x.undo=N.transform(x.undo,!0),x.redo=N.transform(x.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),v}(d.default);w.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};function g(b){var v=b.ops[b.ops.length-1];return v==null?!1:v.insert!=null?typeof v.insert=="string"&&v.insert.endsWith(` 3758`):v.attributes!=null?Object.keys(v.attributes).some(function(A){return a.default.query(A,a.default.Scope.BLOCK)!=null}):!1}function m(b){var v=b.reduce(function(N,x){return N+=x.delete||0,N},0),A=b.length()-v;return g(b)&&(A-=1),A}r.default=w,r.getLastChangeIndex=m},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BaseTooltip=void 0;var s=function(){function j(U,Y){for(var W=0;W<Y.length;W++){var F=Y[W];F.enumerable=F.enumerable||!1,F.configurable=!0,"value"in F&&(F.writable=!0),Object.defineProperty(U,F.key,F)}}return function(U,Y,W){return Y&&j(U.prototype,Y),W&&j(U,W),U}}(),o=function j(U,Y,W){U===null&&(U=Function.prototype);var F=Object.getOwnPropertyDescriptor(U,Y);if(F===void 0){var q=Object.getPrototypeOf(U);return q===null?void 0:j(q,Y,W)}else{if("value"in F)return F.value;var ee=F.get;return ee===void 0?void 0:ee.call(W)}},a=i(3),l=T(a),u=i(2),c=T(u),d=i(8),f=T(d),p=i(23),_=T(p),y=i(34),w=T(y),g=i(59),m=T(g),b=i(60),v=T(b),A=i(28),N=T(A),x=i(61),E=T(x);function T(j){return j&&j.__esModule?j:{default:j}}function S(j,U){if(!(j instanceof U))throw new TypeError("Cannot call a class as a function")}function k(j,U){if(!j)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return U&&(typeof U=="object"||typeof U=="function")?U:j}function I(j,U){if(typeof U!="function"&&U!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof U);j.prototype=Object.create(U&&U.prototype,{constructor:{value:j,enumerable:!1,writable:!0,configurable:!0}}),U&&(Object.setPrototypeOf?Object.setPrototypeOf(j,U):j.__proto__=U)}var P=[!1,"center","right","justify"],M=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],$=[!1,"serif","monospace"],Z=["1","2","3",!1],Q=["small",!1,"large","huge"],K=function(j){I(U,j);function U(Y,W){S(this,U);var F=k(this,(U.__proto__||Object.getPrototypeOf(U)).call(this,Y,W)),q=function ee(te){if(!document.body.contains(Y.root))return document.body.removeEventListener("click",ee);F.tooltip!=null&&!F.tooltip.root.contains(te.target)&&document.activeElement!==F.tooltip.textbox&&!F.quill.hasFocus()&&F.tooltip.hide(),F.pickers!=null&&F.pickers.forEach(function(ae){ae.container.contains(te.target)||ae.close()})};return Y.emitter.listenDOM("click",document.body,q),F}return s(U,[{key:"addModule",value:function(W){var F=o(U.prototype.__proto__||Object.getPrototypeOf(U.prototype),"addModule",this).call(this,W);return W==="toolbar"&&this.extendToolbar(F),F}},{key:"buildButtons",value:function(W,F){W.forEach(function(q){var ee=q.getAttribute("class")||"";ee.split(/\s+/).forEach(function(te){if(te.startsWith("ql-")&&(te=te.slice(3),F[te]!=null))if(te==="direction")q.innerHTML=F[te][""]+F[te].rtl;else if(typeof F[te]=="string")q.innerHTML=F[te];else{var ae=q.value||"";ae!=null&&F[te][ae]&&(q.innerHTML=F[te][ae])}})})}},{key:"buildPickers",value:function(W,F){var q=this;this.pickers=W.map(function(te){if(te.classList.contains("ql-align"))return te.querySelector("option")==null&&D(te,P),new v.default(te,F.align);if(te.classList.contains("ql-background")||te.classList.contains("ql-color")){var ae=te.classList.contains("ql-background")?"background":"color";return te.querySelector("option")==null&&D(te,M,ae==="background"?"#ffffff":"#000000"),new m.default(te,F[ae])}else return te.querySelector("option")==null&&(te.classList.contains("ql-font")?D(te,$):te.classList.contains("ql-header")?D(te,Z):te.classList.contains("ql-size")&&D(te,Q)),new N.default(te)});var ee=function(){q.pickers.forEach(function(ae){ae.update()})};this.quill.on(f.default.events.EDITOR_CHANGE,ee)}}]),U}(w.default);K.DEFAULTS=(0,l.default)(!0,{},w.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var U=this,Y=this.container.querySelector("input.ql-image[type=file]");Y==null&&(Y=document.createElement("input"),Y.setAttribute("type","file"),Y.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),Y.classList.add("ql-image"),Y.addEventListener("change",function(){if(Y.files!=null&&Y.files[0]!=null){var W=new FileReader;W.onload=function(F){var q=U.quill.getSelection(!0);U.quill.updateContents(new c.default().retain(q.index).delete(q.length).insert({image:F.target.result}),f.default.sources.USER),U.quill.setSelection(q.index+1,f.default.sources.SILENT),Y.value=""},W.readAsDataURL(Y.files[0])}}),this.container.appendChild(Y)),Y.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var B=function(j){I(U,j);function U(Y,W){S(this,U);var F=k(this,(U.__proto__||Object.getPrototypeOf(U)).call(this,Y,W));return F.textbox=F.root.querySelector('input[type="text"]'),F.listen(),F}return s(U,[{key:"listen",value:function(){var W=this;this.textbox.addEventListener("keydown",function(F){_.default.match(F,"enter")?(W.save(),F.preventDefault()):_.default.match(F,"escape")&&(W.cancel(),F.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"link",F=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),F!=null?this.textbox.value=F:W!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+W)||""),this.root.setAttribute("data-mode",W)}},{key:"restoreFocus",value:function(){var W=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=W}},{key:"save",value:function(){var W=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{var F=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",W,f.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",W,f.default.sources.USER)),this.quill.root.scrollTop=F;break}case"video":W=V(W);case"formula":{if(!W)break;var q=this.quill.getSelection(!0);if(q!=null){var ee=q.index+q.length;this.quill.insertEmbed(ee,this.root.getAttribute("data-mode"),W,f.default.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(ee+1," ",f.default.sources.USER),this.quill.setSelection(ee+2,f.default.sources.USER)}break}}this.textbox.value="",this.hide()}}]),U}(E.default);function V(j){var U=j.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||j.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return U?(U[1]||"https")+"://www.youtube.com/embed/"+U[2]+"?showinfo=0":(U=j.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(U[1]||"https")+"://player.vimeo.com/video/"+U[2]+"/":j}function D(j,U){var Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;U.forEach(function(W){var F=document.createElement("option");W===Y?F.setAttribute("selected","selected"):F.setAttribute("value",W),j.appendChild(F)})}r.BaseTooltip=B,r.default=K},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function o(){this.head=this.tail=null,this.length=0}return o.prototype.append=function(){for(var a=[],l=0;l<arguments.length;l++)a[l]=arguments[l];this.insertBefore(a[0],null),a.length>1&&this.append.apply(this,a.slice(1))},o.prototype.contains=function(a){for(var l,u=this.iterator();l=u();)if(l===a)return!0;return!1},o.prototype.insertBefore=function(a,l){a&&(a.next=l,l!=null?(a.prev=l.prev,l.prev!=null&&(l.prev.next=a),l.prev=a,l===this.head&&(this.head=a)):this.tail!=null?(this.tail.next=a,a.prev=this.tail,this.tail=a):(a.prev=null,this.head=this.tail=a),this.length+=1)},o.prototype.offset=function(a){for(var l=0,u=this.head;u!=null;){if(u===a)return l;l+=u.length(),u=u.next}return-1},o.prototype.remove=function(a){this.contains(a)&&(a.prev!=null&&(a.prev.next=a.next),a.next!=null&&(a.next.prev=a.prev),a===this.head&&(this.head=a.next),a===this.tail&&(this.tail=a.prev),this.length-=1)},o.prototype.iterator=function(a){return a===void 0&&(a=this.head),function(){var l=a;return a!=null&&(a=a.next),l}},o.prototype.find=function(a,l){l===void 0&&(l=!1);for(var u,c=this.iterator();u=c();){var d=u.length();if(a<d||l&&a===d&&(u.next==null||u.next.length()!==0))return[u,a];a-=d}return[null,0]},o.prototype.forEach=function(a){for(var l,u=this.iterator();l=u();)a(l)},o.prototype.forEachAt=function(a,l,u){if(!(l<=0))for(var c=this.find(a),d=c[0],f=c[1],p,_=a-f,y=this.iterator(d);(p=y())&&_<a+l;){var w=p.length();a>_?u(p,a-_,Math.min(l,_+w-a)):u(p,0,Math.min(w,a+l-_)),_+=w}},o.prototype.map=function(a){return this.reduce(function(l,u){return l.push(a(u)),l},[])},o.prototype.reduce=function(a,l){for(var u,c=this.iterator();u=c();)l=a(l,u);return l},o}();r.default=s},function(n,r,i){var s=this&&this.__extends||function(){var d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,p){f.__proto__=p}||function(f,p){for(var _ in p)p.hasOwnProperty(_)&&(f[_]=p[_])};return function(f,p){d(f,p);function _(){this.constructor=f}f.prototype=p===null?Object.create(p):(_.prototype=p.prototype,new _)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(17),a=i(1),l={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},u=100,c=function(d){s(f,d);function f(p){var _=d.call(this,p)||this;return _.scroll=_,_.observer=new MutationObserver(function(y){_.update(y)}),_.observer.observe(_.domNode,l),_.attach(),_}return f.prototype.detach=function(){d.prototype.detach.call(this),this.observer.disconnect()},f.prototype.deleteAt=function(p,_){this.update(),p===0&&_===this.length()?this.children.forEach(function(y){y.remove()}):d.prototype.deleteAt.call(this,p,_)},f.prototype.formatAt=function(p,_,y,w){this.update(),d.prototype.formatAt.call(this,p,_,y,w)},f.prototype.insertAt=function(p,_,y){this.update(),d.prototype.insertAt.call(this,p,_,y)},f.prototype.optimize=function(p,_){var y=this;p===void 0&&(p=[]),_===void 0&&(_={}),d.prototype.optimize.call(this,_);for(var w=[].slice.call(this.observer.takeRecords());w.length>0;)p.push(w.pop());for(var g=function(A,N){N===void 0&&(N=!0),!(A==null||A===y)&&A.domNode.parentNode!=null&&(A.domNode[a.DATA_KEY].mutations==null&&(A.domNode[a.DATA_KEY].mutations=[]),N&&g(A.parent))},m=function(A){A.domNode[a.DATA_KEY]==null||A.domNode[a.DATA_KEY].mutations==null||(A instanceof o.default&&A.children.forEach(m),A.optimize(_))},b=p,v=0;b.length>0;v+=1){if(v>=u)throw new Error("[Parchment] Maximum optimize iterations reached");for(b.forEach(function(A){var N=a.find(A.target,!0);N!=null&&(N.domNode===A.target&&(A.type==="childList"?(g(a.find(A.previousSibling,!1)),[].forEach.call(A.addedNodes,function(x){var E=a.find(x,!1);g(E,!1),E instanceof o.default&&E.children.forEach(function(T){g(T,!1)})})):A.type==="attributes"&&g(N.prev)),g(N))}),this.children.forEach(m),b=[].slice.call(this.observer.takeRecords()),w=b.slice();w.length>0;)p.push(w.pop())}},f.prototype.update=function(p,_){var y=this;_===void 0&&(_={}),p=p||this.observer.takeRecords(),p.map(function(w){var g=a.find(w.target,!0);return g==null?null:g.domNode[a.DATA_KEY].mutations==null?(g.domNode[a.DATA_KEY].mutations=[w],g):(g.domNode[a.DATA_KEY].mutations.push(w),null)}).forEach(function(w){w==null||w===y||w.domNode[a.DATA_KEY]==null||w.update(w.domNode[a.DATA_KEY].mutations||[],_)}),this.domNode[a.DATA_KEY].mutations!=null&&d.prototype.update.call(this,this.domNode[a.DATA_KEY].mutations,_),this.optimize(p,_)},f.blotName="scroll",f.defaultChild="block",f.scope=a.Scope.BLOCK_BLOT,f.tagName="DIV",f}(o.default);r.default=c},function(n,r,i){var s=this&&this.__extends||function(){var c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var p in f)f.hasOwnProperty(p)&&(d[p]=f[p])};return function(d,f){c(d,f);function p(){this.constructor=d}d.prototype=f===null?Object.create(f):(p.prototype=f.prototype,new p)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(18),a=i(1);function l(c,d){if(Object.keys(c).length!==Object.keys(d).length)return!1;for(var f in c)if(c[f]!==d[f])return!1;return!0}var u=function(c){s(d,c);function d(){return c!==null&&c.apply(this,arguments)||this}return d.formats=function(f){if(f.tagName!==d.tagName)return c.formats.call(this,f)},d.prototype.format=function(f,p){var _=this;f===this.statics.blotName&&!p?(this.children.forEach(function(y){y instanceof o.default||(y=y.wrap(d.blotName,!0)),_.attributes.copy(y)}),this.unwrap()):c.prototype.format.call(this,f,p)},d.prototype.formatAt=function(f,p,_,y){if(this.formats()[_]!=null||a.query(_,a.Scope.ATTRIBUTE)){var w=this.isolate(f,p);w.format(_,y)}else c.prototype.formatAt.call(this,f,p,_,y)},d.prototype.optimize=function(f){c.prototype.optimize.call(this,f);var p=this.formats();if(Object.keys(p).length===0)return this.unwrap();var _=this.next;_ instanceof d&&_.prev===this&&l(p,_.formats())&&(_.moveChildren(this),_.remove())},d.blotName="inline",d.scope=a.Scope.INLINE_BLOT,d.tagName="SPAN",d}(o.default);r.default=u},function(n,r,i){var s=this&&this.__extends||function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)d.hasOwnProperty(f)&&(c[f]=d[f])};return function(c,d){u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(18),a=i(1),l=function(u){s(c,u);function c(){return u!==null&&u.apply(this,arguments)||this}return c.formats=function(d){var f=a.query(c.blotName).tagName;if(d.tagName!==f)return u.formats.call(this,d)},c.prototype.format=function(d,f){a.query(d,a.Scope.BLOCK)!=null&&(d===this.statics.blotName&&!f?this.replaceWith(c.blotName):u.prototype.format.call(this,d,f))},c.prototype.formatAt=function(d,f,p,_){a.query(p,a.Scope.BLOCK)!=null?this.format(p,_):u.prototype.formatAt.call(this,d,f,p,_)},c.prototype.insertAt=function(d,f,p){if(p==null||a.query(f,a.Scope.INLINE)!=null)u.prototype.insertAt.call(this,d,f,p);else{var _=this.split(d),y=a.create(f,p);_.parent.insertBefore(y,_)}},c.prototype.update=function(d,f){navigator.userAgent.match(/Trident/)?this.build():u.prototype.update.call(this,d,f)},c.blotName="block",c.scope=a.Scope.BLOCK_BLOT,c.tagName="P",c}(o.default);r.default=l},function(n,r,i){var s=this&&this.__extends||function(){var l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)c.hasOwnProperty(d)&&(u[d]=c[d])};return function(u,c){l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(19),a=function(l){s(u,l);function u(){return l!==null&&l.apply(this,arguments)||this}return u.formats=function(c){},u.prototype.format=function(c,d){l.prototype.formatAt.call(this,0,this.length(),c,d)},u.prototype.formatAt=function(c,d,f,p){c===0&&d===this.length()?this.format(f,p):l.prototype.formatAt.call(this,c,d,f,p)},u.prototype.formats=function(){return this.statics.formats(this.domNode)},u}(o.default);r.default=a},function(n,r,i){var s=this&&this.__extends||function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)d.hasOwnProperty(f)&&(c[f]=d[f])};return function(c,d){u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}}();Object.defineProperty(r,"__esModule",{value:!0});var o=i(19),a=i(1),l=function(u){s(c,u);function c(d){var f=u.call(this,d)||this;return f.text=f.statics.value(f.domNode),f}return c.create=function(d){return document.createTextNode(d)},c.value=function(d){var f=d.data;return f.normalize&&(f=f.normalize()),f},c.prototype.deleteAt=function(d,f){this.domNode.data=this.text=this.text.slice(0,d)+this.text.slice(d+f)},c.prototype.index=function(d,f){return this.domNode===d?f:-1},c.prototype.insertAt=function(d,f,p){p==null?(this.text=this.text.slice(0,d)+f+this.text.slice(d),this.domNode.data=this.text):u.prototype.insertAt.call(this,d,f,p)},c.prototype.length=function(){return this.text.length},c.prototype.optimize=function(d){u.prototype.optimize.call(this,d),this.text=this.statics.value(this.domNode),this.text.length===0?this.remove():this.next instanceof c&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},c.prototype.position=function(d,f){return[this.domNode,d]},c.prototype.split=function(d,f){if(f===void 0&&(f=!1),!f){if(d===0)return this;if(d===this.length())return this.next}var p=a.create(this.domNode.splitText(d));return this.parent.insertBefore(p,this.next),this.text=this.statics.value(this.domNode),p},c.prototype.update=function(d,f){var p=this;d.some(function(_){return _.type==="characterData"&&_.target===p.domNode})&&(this.text=this.statics.value(this.domNode))},c.prototype.value=function(){return this.text},c.blotName="text",c.scope=a.Scope.INLINE_BLOT,c}(o.default);r.default=l},function(n,r,i){var s=document.createElement("div");if(s.classList.toggle("test-class",!1),s.classList.contains("test-class")){var o=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(a,l){return arguments.length>1&&!this.contains(a)==!l?l:o.call(this,a)}}String.prototype.startsWith||(String.prototype.startsWith=function(a,l){return l=l||0,this.substr(l,a.length)===a}),String.prototype.endsWith||(String.prototype.endsWith=function(a,l){var u=this.toString();(typeof l!="number"||!isFinite(l)||Math.floor(l)!==l||l>u.length)&&(l=u.length),l-=a.length;var c=u.indexOf(a,l);return c!==-1&&c===l}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(l){if(this===null)throw new TypeError("Array.prototype.find called on null or undefined");if(typeof l!="function")throw new TypeError("predicate must be a function");for(var u=Object(this),c=u.length>>>0,d=arguments[1],f,p=0;p<c;p++)if(f=u[p],l.call(d,f,p,u))return f}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})},function(n,r){var i=-1,s=1,o=0;function a(v,A,N){if(v==A)return v?[[o,v]]:[];(N<0||v.length<N)&&(N=null);var x=d(v,A),E=v.substring(0,x);v=v.substring(x),A=A.substring(x),x=f(v,A);var T=v.substring(v.length-x);v=v.substring(0,v.length-x),A=A.substring(0,A.length-x);var S=l(v,A);return E&&S.unshift([o,E]),T&&S.push([o,T]),_(S),N!=null&&(S=g(S,N)),S=m(S),S}function l(v,A){var N;if(!v)return[[s,A]];if(!A)return[[i,v]];var x=v.length>A.length?v:A,E=v.length>A.length?A:v,T=x.indexOf(E);if(T!=-1)return N=[[s,x.substring(0,T)],[o,E],[s,x.substring(T+E.length)]],v.length>A.length&&(N[0][0]=N[2][0]=i),N;if(E.length==1)return[[i,v],[s,A]];var S=p(v,A);if(S){var k=S[0],I=S[1],P=S[2],M=S[3],$=S[4],Z=a(k,P),Q=a(I,M);return Z.concat([[o,$]],Q)}return u(v,A)}function u(v,A){for(var N=v.length,x=A.length,E=Math.ceil((N+x)/2),T=E,S=2*E,k=new Array(S),I=new Array(S),P=0;P<S;P++)k[P]=-1,I[P]=-1;k[T+1]=0,I[T+1]=0;for(var M=N-x,$=M%2!=0,Z=0,Q=0,K=0,B=0,V=0;V<E;V++){for(var D=-V+Z;D<=V-Q;D+=2){var j=T+D,U;D==-V||D!=V&&k[j-1]<k[j+1]?U=k[j+1]:U=k[j-1]+1;for(var Y=U-D;U<N&&Y<x&&v.charAt(U)==A.charAt(Y);)U++,Y++;if(k[j]=U,U>N)Q+=2;else if(Y>x)Z+=2;else if($){var W=T+M-D;if(W>=0&&W<S&&I[W]!=-1){var F=N-I[W];if(U>=F)return c(v,A,U,Y)}}}for(var q=-V+K;q<=V-B;q+=2){var W=T+q,F;q==-V||q!=V&&I[W-1]<I[W+1]?F=I[W+1]:F=I[W-1]+1;for(var ee=F-q;F<N&&ee<x&&v.charAt(N-F-1)==A.charAt(x-ee-1);)F++,ee++;if(I[W]=F,F>N)B+=2;else if(ee>x)K+=2;else if(!$){var j=T+M-q;if(j>=0&&j<S&&k[j]!=-1){var U=k[j],Y=T+U-j;if(F=N-F,U>=F)return c(v,A,U,Y)}}}}return[[i,v],[s,A]]}function c(v,A,N,x){var E=v.substring(0,N),T=A.substring(0,x),S=v.substring(N),k=A.substring(x),I=a(E,T),P=a(S,k);return I.concat(P)}function d(v,A){if(!v||!A||v.charAt(0)!=A.charAt(0))return 0;for(var N=0,x=Math.min(v.length,A.length),E=x,T=0;N<E;)v.substring(T,E)==A.substring(T,E)?(N=E,T=N):x=E,E=Math.floor((x-N)/2+N);return E}function f(v,A){if(!v||!A||v.charAt(v.length-1)!=A.charAt(A.length-1))return 0;for(var N=0,x=Math.min(v.length,A.length),E=x,T=0;N<E;)v.substring(v.length-E,v.length-T)==A.substring(A.length-E,A.length-T)?(N=E,T=N):x=E,E=Math.floor((x-N)/2+N);return E}function p(v,A){var N=v.length>A.length?v:A,x=v.length>A.length?A:v;if(N.length<4||x.length*2<N.length)return null;function E(Q,K,B){for(var V=Q.substring(B,B+Math.floor(Q.length/4)),D=-1,j="",U,Y,W,F;(D=K.indexOf(V,D+1))!=-1;){var q=d(Q.substring(B),K.substring(D)),ee=f(Q.substring(0,B),K.substring(0,D));j.length<ee+q&&(j=K.substring(D-ee,D)+K.substring(D,D+q),U=Q.substring(0,B-ee),Y=Q.substring(B+q),W=K.substring(0,D-ee),F=K.substring(D+q))}return j.length*2>=Q.length?[U,Y,W,F,j]:null}var T=E(N,x,Math.ceil(N.length/4)),S=E(N,x,Math.ceil(N.length/2)),k;if(!T&&!S)return null;S?T?k=T[4].length>S[4].length?T:S:k=S:k=T;var I,P,M,$;v.length>A.length?(I=k[0],P=k[1],M=k[2],$=k[3]):(M=k[0],$=k[1],I=k[2],P=k[3]);var Z=k[4];return[I,P,M,$,Z]}function _(v){v.push([o,""]);for(var A=0,N=0,x=0,E="",T="",S;A<v.length;)switch(v[A][0]){case s:x++,T+=v[A][1],A++;break;case i:N++,E+=v[A][1],A++;break;case o:N+x>1?(N!==0&&x!==0&&(S=d(T,E),S!==0&&(A-N-x>0&&v[A-N-x-1][0]==o?v[A-N-x-1][1]+=T.substring(0,S):(v.splice(0,0,[o,T.substring(0,S)]),A++),T=T.substring(S),E=E.substring(S)),S=f(T,E),S!==0&&(v[A][1]=T.substring(T.length-S)+v[A][1],T=T.substring(0,T.length-S),E=E.substring(0,E.length-S))),N===0?v.splice(A-x,N+x,[s,T]):x===0?v.splice(A-N,N+x,[i,E]):v.splice(A-N-x,N+x,[i,E],[s,T]),A=A-N-x+(N?1:0)+(x?1:0)+1):A!==0&&v[A-1][0]==o?(v[A-1][1]+=v[A][1],v.splice(A,1)):A++,x=0,N=0,E="",T="";break}v[v.length-1][1]===""&&v.pop();var k=!1;for(A=1;A<v.length-1;)v[A-1][0]==o&&v[A+1][0]==o&&(v[A][1].substring(v[A][1].length-v[A-1][1].length)==v[A-1][1]?(v[A][1]=v[A-1][1]+v[A][1].substring(0,v[A][1].length-v[A-1][1].length),v[A+1][1]=v[A-1][1]+v[A+1][1],v.splice(A-1,1),k=!0):v[A][1].substring(0,v[A+1][1].length)==v[A+1][1]&&(v[A-1][1]+=v[A+1][1],v[A][1]=v[A][1].substring(v[A+1][1].length)+v[A+1][1],v.splice(A+1,1),k=!0)),A++;k&&_(v)}var y=a;y.INSERT=s,y.DELETE=i,y.EQUAL=o,n.exports=y;function w(v,A){if(A===0)return[o,v];for(var N=0,x=0;x<v.length;x++){var E=v[x];if(E[0]===i||E[0]===o){var T=N+E[1].length;if(A===T)return[x+1,v];if(A<T){v=v.slice();var S=A-N,k=[E[0],E[1].slice(0,S)],I=[E[0],E[1].slice(S)];return v.splice(x,1,k,I),[x+1,v]}else N=T}}throw new Error("cursor_pos is out of bounds!")}function g(v,A){var N=w(v,A),x=N[1],E=N[0],T=x[E],S=x[E+1];if(T==null)return v;if(T[0]!==o)return v;if(S!=null&&T[1]+S[1]===S[1]+T[1])return x.splice(E,2,S,T),b(x,E,2);if(S!=null&&S[1].indexOf(T[1])===0){x.splice(E,2,[S[0],T[1]],[0,T[1]]);var k=S[1].slice(T[1].length);return k.length>0&&x.splice(E+2,0,[S[0],k]),b(x,E,3)}else return v}function m(v){for(var A=!1,N=function(S){return S.charCodeAt(0)>=56320&&S.charCodeAt(0)<=57343},x=function(S){return S.charCodeAt(S.length-1)>=55296&&S.charCodeAt(S.length-1)<=56319},E=2;E<v.length;E+=1)v[E-2][0]===o&&x(v[E-2][1])&&v[E-1][0]===i&&N(v[E-1][1])&&v[E][0]===s&&N(v[E][1])&&(A=!0,v[E-1][1]=v[E-2][1].slice(-1)+v[E-1][1],v[E][1]=v[E-2][1].slice(-1)+v[E][1],v[E-2][1]=v[E-2][1].slice(0,-1));if(!A)return v;for(var T=[],E=0;E<v.length;E+=1)v[E][1].length>0&&T.push(v[E]);return T}function b(v,A,N){for(var x=A+N-1;x>=0&&x>=A-1;x--)if(x+1<v.length){var E=v[x],T=v[x+1];E[0]===T[1]&&v.splice(x,2,[E[0],E[1]+T[1]])}return v}},function(n,r){r=n.exports=typeof Object.keys=="function"?Object.keys:i,r.shim=i;function i(s){var o=[];for(var a in s)o.push(a);return o}},function(n,r){var i=function(){return Object.prototype.toString.call(arguments)}()=="[object Arguments]";r=n.exports=i?s:o,r.supported=s;function s(a){return Object.prototype.toString.call(a)=="[object Arguments]"}r.unsupported=o;function o(a){return a&&typeof a=="object"&&typeof a.length=="number"&&Object.prototype.hasOwnProperty.call(a,"callee")&&!Object.prototype.propertyIsEnumerable.call(a,"callee")||!1}},function(n,r){var i=Object.prototype.hasOwnProperty,s="~";function o(){}Object.create&&(o.prototype=Object.create(null),new o().__proto__||(s=!1));function a(u,c,d){this.fn=u,this.context=c,this.once=d||!1}function l(){this._events=new o,this._eventsCount=0}l.prototype.eventNames=function(){var c=[],d,f;if(this._eventsCount===0)return c;for(f in d=this._events)i.call(d,f)&&c.push(s?f.slice(1):f);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(d)):c},l.prototype.listeners=function(c,d){var f=s?s+c:c,p=this._events[f];if(d)return!!p;if(!p)return[];if(p.fn)return[p.fn];for(var _=0,y=p.length,w=new Array(y);_<y;_++)w[_]=p[_].fn;return w},l.prototype.emit=function(c,d,f,p,_,y){var w=s?s+c:c;if(!this._events[w])return!1;var g=this._events[w],m=arguments.length,b,v;if(g.fn){switch(g.once&&this.removeListener(c,g.fn,void 0,!0),m){case 1:return g.fn.call(g.context),!0;case 2:return g.fn.call(g.context,d),!0;case 3:return g.fn.call(g.context,d,f),!0;case 4:return g.fn.call(g.context,d,f,p),!0;case 5:return g.fn.call(g.context,d,f,p,_),!0;case 6:return g.fn.call(g.context,d,f,p,_,y),!0}for(v=1,b=new Array(m-1);v<m;v++)b[v-1]=arguments[v];g.fn.apply(g.context,b)}else{var A=g.length,N;for(v=0;v<A;v++)switch(g[v].once&&this.removeListener(c,g[v].fn,void 0,!0),m){case 1:g[v].fn.call(g[v].context);break;case 2:g[v].fn.call(g[v].context,d);break;case 3:g[v].fn.call(g[v].context,d,f);break;case 4:g[v].fn.call(g[v].context,d,f,p);break;default:if(!b)for(N=1,b=new Array(m-1);N<m;N++)b[N-1]=arguments[N];g[v].fn.apply(g[v].context,b)}}return!0},l.prototype.on=function(c,d,f){var p=new a(d,f||this),_=s?s+c:c;return this._events[_]?this._events[_].fn?this._events[_]=[this._events[_],p]:this._events[_].push(p):(this._events[_]=p,this._eventsCount++),this},l.prototype.once=function(c,d,f){var p=new a(d,f||this,!0),_=s?s+c:c;return this._events[_]?this._events[_].fn?this._events[_]=[this._events[_],p]:this._events[_].push(p):(this._events[_]=p,this._eventsCount++),this},l.prototype.removeListener=function(c,d,f,p){var _=s?s+c:c;if(!this._events[_])return this;if(!d)return--this._eventsCount===0?this._events=new o:delete this._events[_],this;var y=this._events[_];if(y.fn)y.fn===d&&(!p||y.once)&&(!f||y.context===f)&&(--this._eventsCount===0?this._events=new o:delete this._events[_]);else{for(var w=0,g=[],m=y.length;w<m;w++)(y[w].fn!==d||p&&!y[w].once||f&&y[w].context!==f)&&g.push(y[w]);g.length?this._events[_]=g.length===1?g[0]:g:--this._eventsCount===0?this._events=new o:delete this._events[_]}return this},l.prototype.removeAllListeners=function(c){var d;return c?(d=s?s+c:c,this._events[d]&&(--this._eventsCount===0?this._events=new o:delete this._events[d])):(this._events=new o,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prototype.setMaxListeners=function(){return this},l.prefixed=s,l.EventEmitter=l,typeof n<"u"&&(n.exports=l)},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.matchText=r.matchSpacing=r.matchNewline=r.matchBlot=r.matchAttributor=r.default=void 0;var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ie){return typeof ie}:function(ie){return ie&&typeof Symbol=="function"&&ie.constructor===Symbol&&ie!==Symbol.prototype?"symbol":typeof ie},o=function(){function ie(se,pe){var ye=[],ue=!0,Ue=!1,Fe=void 0;try{for(var oe=se[Symbol.iterator](),me;!(ue=(me=oe.next()).done)&&(ye.push(me.value),!(pe&&ye.length===pe));ue=!0);}catch(je){Ue=!0,Fe=je}finally{try{!ue&&oe.return&&oe.return()}finally{if(Ue)throw Fe}}return ye}return function(se,pe){if(Array.isArray(se))return se;if(Symbol.iterator in Object(se))return ie(se,pe);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(){function ie(se,pe){for(var ye=0;ye<pe.length;ye++){var ue=pe[ye];ue.enumerable=ue.enumerable||!1,ue.configurable=!0,"value"in ue&&(ue.writable=!0),Object.defineProperty(se,ue.key,ue)}}return function(se,pe,ye){return pe&&ie(se.prototype,pe),ye&&ie(se,ye),se}}(),l=i(3),u=I(l),c=i(2),d=I(c),f=i(0),p=I(f),_=i(5),y=I(_),w=i(10),g=I(w),m=i(9),b=I(m),v=i(36),A=i(37),N=i(13),x=I(N),E=i(26),T=i(38),S=i(39),k=i(40);function I(ie){return ie&&ie.__esModule?ie:{default:ie}}function P(ie,se,pe){return se in ie?Object.defineProperty(ie,se,{value:pe,enumerable:!0,configurable:!0,writable:!0}):ie[se]=pe,ie}function M(ie,se){if(!(ie instanceof se))throw new TypeError("Cannot call a class as a function")}function $(ie,se){if(!ie)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return se&&(typeof se=="object"||typeof se=="function")?se:ie}function Z(ie,se){if(typeof se!="function"&&se!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof se);ie.prototype=Object.create(se&&se.prototype,{constructor:{value:ie,enumerable:!1,writable:!0,configurable:!0}}),se&&(Object.setPrototypeOf?Object.setPrototypeOf(ie,se):ie.__proto__=se)}var Q=(0,g.default)("quill:clipboard"),K="__ql-matcher",B=[[Node.TEXT_NODE,kt],[Node.TEXT_NODE,qe],["br",_e],[Node.ELEMENT_NODE,qe],[Node.ELEMENT_NODE,ae],[Node.ELEMENT_NODE,Ze],[Node.ELEMENT_NODE,te],[Node.ELEMENT_NODE,Et],["li",Ce],["b",ee.bind(ee,"bold")],["i",ee.bind(ee,"italic")],["style",Ee]],V=[v.AlignAttribute,T.DirectionAttribute].reduce(function(ie,se){return ie[se.keyName]=se,ie},{}),D=[v.AlignStyle,A.BackgroundStyle,E.ColorStyle,T.DirectionStyle,S.FontStyle,k.SizeStyle].reduce(function(ie,se){return ie[se.keyName]=se,ie},{}),j=function(ie){Z(se,ie);function se(pe,ye){M(this,se);var ue=$(this,(se.__proto__||Object.getPrototypeOf(se)).call(this,pe,ye));return ue.quill.root.addEventListener("paste",ue.onPaste.bind(ue)),ue.container=ue.quill.addContainer("ql-clipboard"),ue.container.setAttribute("contenteditable",!0),ue.container.setAttribute("tabindex",-1),ue.matchers=[],B.concat(ue.options.matchers).forEach(function(Ue){var Fe=o(Ue,2),oe=Fe[0],me=Fe[1];!ye.matchVisual&&me===Ze||ue.addMatcher(oe,me)}),ue}return a(se,[{key:"addMatcher",value:function(ye,ue){this.matchers.push([ye,ue])}},{key:"convert",value:function(ye){if(typeof ye=="string")return this.container.innerHTML=ye.replace(/\>\r?\n +\</g,"><"),this.convert();var ue=this.quill.getFormat(this.quill.selection.savedRange.index);if(ue[x.default.blotName]){var Ue=this.container.innerText;return this.container.innerHTML="",new d.default().insert(Ue,P({},x.default.blotName,ue[x.default.blotName]))}var Fe=this.prepareMatching(),oe=o(Fe,2),me=oe[0],je=oe[1],Ne=q(this.container,me,je);return W(Ne,` 3759`)&&Ne.ops[Ne.ops.length-1].attributes==null&&(Ne=Ne.compose(new d.default().retain(Ne.length()-1).delete(1))),Q.log("convert",this.container.innerHTML,Ne),this.container.innerHTML="",Ne}},{key:"dangerouslyPasteHTML",value:function(ye,ue){var Ue=arguments.length>2&&arguments[2]!==void 0?arguments[2]:y.default.sources.API;if(typeof ye=="string")this.quill.setContents(this.convert(ye),ue),this.quill.setSelection(0,y.default.sources.SILENT);else{var Fe=this.convert(ue);this.quill.updateContents(new d.default().retain(ye).concat(Fe),Ue),this.quill.setSelection(ye+Fe.length(),y.default.sources.SILENT)}}},{key:"onPaste",value:function(ye){var ue=this;if(!(ye.defaultPrevented||!this.quill.isEnabled())){var Ue=this.quill.getSelection(),Fe=new d.default().retain(Ue.index),oe=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(y.default.sources.SILENT),setTimeout(function(){Fe=Fe.concat(ue.convert()).delete(Ue.length),ue.quill.updateContents(Fe,y.default.sources.USER),ue.quill.setSelection(Fe.length()-Ue.length,y.default.sources.SILENT),ue.quill.scrollingContainer.scrollTop=oe,ue.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var ye=this,ue=[],Ue=[];return this.matchers.forEach(function(Fe){var oe=o(Fe,2),me=oe[0],je=oe[1];switch(me){case Node.TEXT_NODE:Ue.push(je);break;case Node.ELEMENT_NODE:ue.push(je);break;default:[].forEach.call(ye.container.querySelectorAll(me),function(Ne){Ne[K]=Ne[K]||[],Ne[K].push(je)});break}}),[ue,Ue]}}]),se}(b.default);j.DEFAULTS={matchers:[],matchVisual:!0};function U(ie,se,pe){return(typeof se>"u"?"undefined":s(se))==="object"?Object.keys(se).reduce(function(ye,ue){return U(ye,ue,se[ue])},ie):ie.reduce(function(ye,ue){return ue.attributes&&ue.attributes[se]?ye.push(ue):ye.insert(ue.insert,(0,u.default)({},P({},se,pe),ue.attributes))},new d.default)}function Y(ie){if(ie.nodeType!==Node.ELEMENT_NODE)return{};var se="__ql-computed-style";return ie[se]||(ie[se]=window.getComputedStyle(ie))}function W(ie,se){for(var pe="",ye=ie.ops.length-1;ye>=0&&pe.length<se.length;--ye){var ue=ie.ops[ye];if(typeof ue.insert!="string")break;pe=ue.insert+pe}return pe.slice(-1*se.length)===se}function F(ie){if(ie.childNodes.length===0)return!1;var se=Y(ie);return["block","list-item"].indexOf(se.display)>-1}function q(ie,se,pe){return ie.nodeType===ie.TEXT_NODE?pe.reduce(function(ye,ue){return ue(ie,ye)},new d.default):ie.nodeType===ie.ELEMENT_NODE?[].reduce.call(ie.childNodes||[],function(ye,ue){var Ue=q(ue,se,pe);return ue.nodeType===ie.ELEMENT_NODE&&(Ue=se.reduce(function(Fe,oe){return oe(ue,Fe)},Ue),Ue=(ue[K]||[]).reduce(function(Fe,oe){return oe(ue,Fe)},Ue)),ye.concat(Ue)},new d.default):new d.default}function ee(ie,se,pe){return U(pe,ie,!0)}function te(ie,se){var pe=p.default.Attributor.Attribute.keys(ie),ye=p.default.Attributor.Class.keys(ie),ue=p.default.Attributor.Style.keys(ie),Ue={};return pe.concat(ye).concat(ue).forEach(function(Fe){var oe=p.default.query(Fe,p.default.Scope.ATTRIBUTE);oe!=null&&(Ue[oe.attrName]=oe.value(ie),Ue[oe.attrName])||(oe=V[Fe],oe!=null&&(oe.attrName===Fe||oe.keyName===Fe)&&(Ue[oe.attrName]=oe.value(ie)||void 0),oe=D[Fe],oe!=null&&(oe.attrName===Fe||oe.keyName===Fe)&&(oe=D[Fe],Ue[oe.attrName]=oe.value(ie)||void 0))}),Object.keys(Ue).length>0&&(se=U(se,Ue)),se}function ae(ie,se){var pe=p.default.query(ie);if(pe==null)return se;if(pe.prototype instanceof p.default.Embed){var ye={},ue=pe.value(ie);ue!=null&&(ye[pe.blotName]=ue,se=new d.default().insert(ye,pe.formats(ie)))}else typeof pe.formats=="function"&&(se=U(se,pe.blotName,pe.formats(ie)));return se}function _e(ie,se){return W(se,` 3760`)||se.insert(` 3761`),se}function Ee(){return new d.default}function Ce(ie,se){var pe=p.default.query(ie);if(pe==null||pe.blotName!=="list-item"||!W(se,` 3762`))return se;for(var ye=-1,ue=ie.parentNode;!ue.classList.contains("ql-clipboard");)(p.default.query(ue)||{}).blotName==="list"&&(ye+=1),ue=ue.parentNode;return ye<=0?se:se.compose(new d.default().retain(se.length()-1).retain(1,{indent:ye}))}function qe(ie,se){return W(se,` 3763`)||(F(ie)||se.length()>0&&ie.nextSibling&&F(ie.nextSibling))&&se.insert(` 3764`),se}function Ze(ie,se){if(F(ie)&&ie.nextElementSibling!=null&&!W(se,` 3765 3766`)){var pe=ie.offsetHeight+parseFloat(Y(ie).marginTop)+parseFloat(Y(ie).marginBottom);ie.nextElementSibling.offsetTop>ie.offsetTop+pe*1.5&&se.insert(` 3767`)}return se}function Et(ie,se){var pe={},ye=ie.style||{};return ye.fontStyle&&Y(ie).fontStyle==="italic"&&(pe.italic=!0),ye.fontWeight&&(Y(ie).fontWeight.startsWith("bold")||parseInt(Y(ie).fontWeight)>=700)&&(pe.bold=!0),Object.keys(pe).length>0&&(se=U(se,pe)),parseFloat(ye.textIndent||0)>0&&(se=new d.default().insert(" ").concat(se)),se}function kt(ie,se){var pe=ie.data;if(ie.parentNode.tagName==="O:P")return se.insert(pe.trim());if(pe.trim().length===0&&ie.parentNode.classList.contains("ql-clipboard"))return se;if(!Y(ie.parentNode).whiteSpace.startsWith("pre")){var ye=function(Ue,Fe){return Fe=Fe.replace(/[^\u00a0]/g,""),Fe.length<1&&Ue?" ":Fe};pe=pe.replace(/\r\n/g," ").replace(/\n/g," "),pe=pe.replace(/\s\s+/g,ye.bind(ye,!0)),(ie.previousSibling==null&&F(ie.parentNode)||ie.previousSibling!=null&&F(ie.previousSibling))&&(pe=pe.replace(/^\s+/,ye.bind(ye,!1))),(ie.nextSibling==null&&F(ie.parentNode)||ie.nextSibling!=null&&F(ie.nextSibling))&&(pe=pe.replace(/\s+$/,ye.bind(ye,!1)))}return se.insert(pe)}r.default=j,r.matchAttributor=te,r.matchBlot=ae,r.matchNewline=qe,r.matchSpacing=Ze,r.matchText=kt},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function _(y,w){for(var g=0;g<w.length;g++){var m=w[g];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,g){return w&&_(y.prototype,w),g&&_(y,g),y}}(),o=function _(y,w,g){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var b=Object.getPrototypeOf(y);return b===null?void 0:_(b,w,g)}else{if("value"in m)return m.value;var v=m.get;return v===void 0?void 0:v.call(g)}},a=i(6),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(){return c(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"optimize",value:function(g){o(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"optimize",this).call(this,g),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return o(y.__proto__||Object.getPrototypeOf(y),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),y}(l.default);p.blotName="bold",p.tagName=["STRONG","B"],r.default=p},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.addControls=r.default=void 0;var s=function(){function k(I,P){var M=[],$=!0,Z=!1,Q=void 0;try{for(var K=I[Symbol.iterator](),B;!($=(B=K.next()).done)&&(M.push(B.value),!(P&&M.length===P));$=!0);}catch(V){Z=!0,Q=V}finally{try{!$&&K.return&&K.return()}finally{if(Z)throw Q}}return M}return function(I,P){if(Array.isArray(I))return I;if(Symbol.iterator in Object(I))return k(I,P);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function k(I,P){for(var M=0;M<P.length;M++){var $=P[M];$.enumerable=$.enumerable||!1,$.configurable=!0,"value"in $&&($.writable=!0),Object.defineProperty(I,$.key,$)}}return function(I,P,M){return P&&k(I.prototype,P),M&&k(I,M),I}}(),a=i(2),l=g(a),u=i(0),c=g(u),d=i(5),f=g(d),p=i(10),_=g(p),y=i(9),w=g(y);function g(k){return k&&k.__esModule?k:{default:k}}function m(k,I,P){return I in k?Object.defineProperty(k,I,{value:P,enumerable:!0,configurable:!0,writable:!0}):k[I]=P,k}function b(k,I){if(!(k instanceof I))throw new TypeError("Cannot call a class as a function")}function v(k,I){if(!k)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return I&&(typeof I=="object"||typeof I=="function")?I:k}function A(k,I){if(typeof I!="function"&&I!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof I);k.prototype=Object.create(I&&I.prototype,{constructor:{value:k,enumerable:!1,writable:!0,configurable:!0}}),I&&(Object.setPrototypeOf?Object.setPrototypeOf(k,I):k.__proto__=I)}var N=(0,_.default)("quill:toolbar"),x=function(k){A(I,k);function I(P,M){b(this,I);var $=v(this,(I.__proto__||Object.getPrototypeOf(I)).call(this,P,M));if(Array.isArray($.options.container)){var Z=document.createElement("div");T(Z,$.options.container),P.container.parentNode.insertBefore(Z,P.container),$.container=Z}else typeof $.options.container=="string"?$.container=document.querySelector($.options.container):$.container=$.options.container;if(!($.container instanceof HTMLElement)){var Q;return Q=N.error("Container required for toolbar",$.options),v($,Q)}return $.container.classList.add("ql-toolbar"),$.controls=[],$.handlers={},Object.keys($.options.handlers).forEach(function(K){$.addHandler(K,$.options.handlers[K])}),[].forEach.call($.container.querySelectorAll("button, select"),function(K){$.attach(K)}),$.quill.on(f.default.events.EDITOR_CHANGE,function(K,B){K===f.default.events.SELECTION_CHANGE&&$.update(B)}),$.quill.on(f.default.events.SCROLL_OPTIMIZE,function(){var K=$.quill.selection.getRange(),B=s(K,1),V=B[0];$.update(V)}),$}return o(I,[{key:"addHandler",value:function(M,$){this.handlers[M]=$}},{key:"attach",value:function(M){var $=this,Z=[].find.call(M.classList,function(K){return K.indexOf("ql-")===0});if(Z){if(Z=Z.slice(3),M.tagName==="BUTTON"&&M.setAttribute("type","button"),this.handlers[Z]==null){if(this.quill.scroll.whitelist!=null&&this.quill.scroll.whitelist[Z]==null){N.warn("ignoring attaching to disabled format",Z,M);return}if(c.default.query(Z)==null){N.warn("ignoring attaching to nonexistent format",Z,M);return}}var Q=M.tagName==="SELECT"?"change":"click";M.addEventListener(Q,function(K){var B=void 0;if(M.tagName==="SELECT"){if(M.selectedIndex<0)return;var V=M.options[M.selectedIndex];V.hasAttribute("selected")?B=!1:B=V.value||!1}else M.classList.contains("ql-active")?B=!1:B=M.value||!M.hasAttribute("value"),K.preventDefault();$.quill.focus();var D=$.quill.selection.getRange(),j=s(D,1),U=j[0];if($.handlers[Z]!=null)$.handlers[Z].call($,B);else if(c.default.query(Z).prototype instanceof c.default.Embed){if(B=prompt("Enter "+Z),!B)return;$.quill.updateContents(new l.default().retain(U.index).delete(U.length).insert(m({},Z,B)),f.default.sources.USER)}else $.quill.format(Z,B,f.default.sources.USER);$.update(U)}),this.controls.push([Z,M])}}},{key:"update",value:function(M){var $=M==null?{}:this.quill.getFormat(M);this.controls.forEach(function(Z){var Q=s(Z,2),K=Q[0],B=Q[1];if(B.tagName==="SELECT"){var V=void 0;if(M==null)V=null;else if($[K]==null)V=B.querySelector("option[selected]");else if(!Array.isArray($[K])){var D=$[K];typeof D=="string"&&(D=D.replace(/\"/g,'\\"')),V=B.querySelector('option[value="'+D+'"]')}V==null?(B.value="",B.selectedIndex=-1):V.selected=!0}else if(M==null)B.classList.remove("ql-active");else if(B.hasAttribute("value")){var j=$[K]===B.getAttribute("value")||$[K]!=null&&$[K].toString()===B.getAttribute("value")||$[K]==null&&!B.getAttribute("value");B.classList.toggle("ql-active",j)}else B.classList.toggle("ql-active",$[K]!=null)})}}]),I}(w.default);x.DEFAULTS={};function E(k,I,P){var M=document.createElement("button");M.setAttribute("type","button"),M.classList.add("ql-"+I),P!=null&&(M.value=P),k.appendChild(M)}function T(k,I){Array.isArray(I[0])||(I=[I]),I.forEach(function(P){var M=document.createElement("span");M.classList.add("ql-formats"),P.forEach(function($){if(typeof $=="string")E(M,$);else{var Z=Object.keys($)[0],Q=$[Z];Array.isArray(Q)?S(M,Z,Q):E(M,Z,Q)}}),k.appendChild(M)})}function S(k,I,P){var M=document.createElement("select");M.classList.add("ql-"+I),P.forEach(function($){var Z=document.createElement("option");$!==!1?Z.setAttribute("value",$):Z.setAttribute("selected","selected"),M.appendChild(Z)}),k.appendChild(M)}x.DEFAULTS={container:null,handlers:{clean:function(){var I=this,P=this.quill.getSelection();if(P!=null)if(P.length==0){var M=this.quill.getFormat();Object.keys(M).forEach(function($){c.default.query($,c.default.Scope.INLINE)!=null&&I.quill.format($,!1)})}else this.quill.removeFormat(P,f.default.sources.USER)},direction:function(I){var P=this.quill.getFormat().align;I==="rtl"&&P==null?this.quill.format("align","right",f.default.sources.USER):!I&&P==="right"&&this.quill.format("align",!1,f.default.sources.USER),this.quill.format("direction",I,f.default.sources.USER)},indent:function(I){var P=this.quill.getSelection(),M=this.quill.getFormat(P),$=parseInt(M.indent||0);if(I==="+1"||I==="-1"){var Z=I==="+1"?1:-1;M.direction==="rtl"&&(Z*=-1),this.quill.format("indent",$+Z,f.default.sources.USER)}},link:function(I){I===!0&&(I=prompt("Enter link URL:")),this.quill.format("link",I,f.default.sources.USER)},list:function(I){var P=this.quill.getSelection(),M=this.quill.getFormat(P);I==="check"?M.list==="checked"||M.list==="unchecked"?this.quill.format("list",!1,f.default.sources.USER):this.quill.format("list","unchecked",f.default.sources.USER):this.quill.format("list",I,f.default.sources.USER)}}},r.default=x,r.addControls=T},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function _(y,w){for(var g=0;g<w.length;g++){var m=w[g];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,g){return w&&_(y.prototype,w),g&&_(y,g),y}}(),o=function _(y,w,g){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var b=Object.getPrototypeOf(y);return b===null?void 0:_(b,w,g)}else{if("value"in m)return m.value;var v=m.get;return v===void 0?void 0:v.call(g)}},a=i(28),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(w,g){c(this,y);var m=d(this,(y.__proto__||Object.getPrototypeOf(y)).call(this,w));return m.label.innerHTML=g,m.container.classList.add("ql-color-picker"),[].slice.call(m.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(b){b.classList.add("ql-primary")}),m}return s(y,[{key:"buildItem",value:function(g){var m=o(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"buildItem",this).call(this,g);return m.style.backgroundColor=g.getAttribute("value")||"",m}},{key:"selectItem",value:function(g,m){o(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"selectItem",this).call(this,g,m);var b=this.label.querySelector(".ql-color-label"),v=g&&g.getAttribute("data-value")||"";b&&(b.tagName==="line"?b.style.stroke=v:b.style.fill=v)}}]),y}(l.default);r.default=p},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function _(y,w){for(var g=0;g<w.length;g++){var m=w[g];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,g){return w&&_(y.prototype,w),g&&_(y,g),y}}(),o=function _(y,w,g){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var b=Object.getPrototypeOf(y);return b===null?void 0:_(b,w,g)}else{if("value"in m)return m.value;var v=m.get;return v===void 0?void 0:v.call(g)}},a=i(28),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(w,g){c(this,y);var m=d(this,(y.__proto__||Object.getPrototypeOf(y)).call(this,w));return m.container.classList.add("ql-icon-picker"),[].forEach.call(m.container.querySelectorAll(".ql-picker-item"),function(b){b.innerHTML=g[b.getAttribute("data-value")||""]}),m.defaultItem=m.container.querySelector(".ql-selected"),m.selectItem(m.defaultItem),m}return s(y,[{key:"selectItem",value:function(g,m){o(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"selectItem",this).call(this,g,m),g=g||this.defaultItem,this.label.innerHTML=g.innerHTML}}]),y}(l.default);r.default=p},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function l(u,c){for(var d=0;d<c.length;d++){var f=c[d];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(u,f.key,f)}}return function(u,c,d){return c&&l(u.prototype,c),d&&l(u,d),u}}();function o(l,u){if(!(l instanceof u))throw new TypeError("Cannot call a class as a function")}var a=function(){function l(u,c){var d=this;o(this,l),this.quill=u,this.boundsContainer=c||document.body,this.root=u.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){d.root.style.marginTop=-1*d.quill.root.scrollTop+"px"}),this.hide()}return s(l,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(c){var d=c.left+c.width/2-this.root.offsetWidth/2,f=c.bottom+this.quill.root.scrollTop;this.root.style.left=d+"px",this.root.style.top=f+"px",this.root.classList.remove("ql-flip");var p=this.boundsContainer.getBoundingClientRect(),_=this.root.getBoundingClientRect(),y=0;if(_.right>p.right&&(y=p.right-_.right,this.root.style.left=d+y+"px"),_.left<p.left&&(y=p.left-_.left,this.root.style.left=d+y+"px"),_.bottom>p.bottom){var w=_.bottom-_.top,g=c.bottom-c.top+w;this.root.style.top=f-g+"px",this.root.classList.add("ql-flip")}return y}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),l}();r.default=a},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function S(k,I){var P=[],M=!0,$=!1,Z=void 0;try{for(var Q=k[Symbol.iterator](),K;!(M=(K=Q.next()).done)&&(P.push(K.value),!(I&&P.length===I));M=!0);}catch(B){$=!0,Z=B}finally{try{!M&&Q.return&&Q.return()}finally{if($)throw Z}}return P}return function(k,I){if(Array.isArray(k))return k;if(Symbol.iterator in Object(k))return S(k,I);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function S(k,I,P){k===null&&(k=Function.prototype);var M=Object.getOwnPropertyDescriptor(k,I);if(M===void 0){var $=Object.getPrototypeOf(k);return $===null?void 0:S($,I,P)}else{if("value"in M)return M.value;var Z=M.get;return Z===void 0?void 0:Z.call(P)}},a=function(){function S(k,I){for(var P=0;P<I.length;P++){var M=I[P];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(k,M.key,M)}}return function(k,I,P){return I&&S(k.prototype,I),P&&S(k,P),k}}(),l=i(3),u=b(l),c=i(8),d=b(c),f=i(43),p=b(f),_=i(27),y=b(_),w=i(15),g=i(41),m=b(g);function b(S){return S&&S.__esModule?S:{default:S}}function v(S,k){if(!(S instanceof k))throw new TypeError("Cannot call a class as a function")}function A(S,k){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return k&&(typeof k=="object"||typeof k=="function")?k:S}function N(S,k){if(typeof k!="function"&&k!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof k);S.prototype=Object.create(k&&k.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),k&&(Object.setPrototypeOf?Object.setPrototypeOf(S,k):S.__proto__=k)}var x=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],E=function(S){N(k,S);function k(I,P){v(this,k),P.modules.toolbar!=null&&P.modules.toolbar.container==null&&(P.modules.toolbar.container=x);var M=A(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,I,P));return M.quill.container.classList.add("ql-snow"),M}return a(k,[{key:"extendToolbar",value:function(P){P.container.classList.add("ql-snow"),this.buildButtons([].slice.call(P.container.querySelectorAll("button")),m.default),this.buildPickers([].slice.call(P.container.querySelectorAll("select")),m.default),this.tooltip=new T(this.quill,this.options.bounds),P.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(M,$){P.handlers.link.call(P,!$.format.link)})}}]),k}(p.default);E.DEFAULTS=(0,u.default)(!0,{},p.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(k){if(k){var I=this.quill.getSelection();if(I==null||I.length==0)return;var P=this.quill.getText(I);/^\S+@\S+\.\S+$/.test(P)&&P.indexOf("mailto:")!==0&&(P="mailto:"+P);var M=this.quill.theme.tooltip;M.edit("link",P)}else this.quill.format("link",!1)}}}}});var T=function(S){N(k,S);function k(I,P){v(this,k);var M=A(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,I,P));return M.preview=M.root.querySelector("a.ql-preview"),M}return a(k,[{key:"listen",value:function(){var P=this;o(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(M){P.root.classList.contains("ql-editing")?P.save():P.edit("link",P.preview.textContent),M.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(M){if(P.linkRange!=null){var $=P.linkRange;P.restoreFocus(),P.quill.formatText($,"link",!1,d.default.sources.USER),delete P.linkRange}M.preventDefault(),P.hide()}),this.quill.on(d.default.events.SELECTION_CHANGE,function(M,$,Z){if(M!=null){if(M.length===0&&Z===d.default.sources.USER){var Q=P.quill.scroll.descendant(y.default,M.index),K=s(Q,2),B=K[0],V=K[1];if(B!=null){P.linkRange=new w.Range(M.index-V,B.length());var D=y.default.formats(B.domNode);P.preview.textContent=D,P.preview.setAttribute("href",D),P.show(),P.position(P.quill.getBounds(P.linkRange));return}}else delete P.linkRange;P.hide()}})}},{key:"show",value:function(){o(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),k}(f.BaseTooltip);T.TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),r.default=E},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(29),o=ue(s),a=i(36),l=i(38),u=i(64),c=i(65),d=ue(c),f=i(66),p=ue(f),_=i(67),y=ue(_),w=i(37),g=i(26),m=i(39),b=i(40),v=i(56),A=ue(v),N=i(68),x=ue(N),E=i(27),T=ue(E),S=i(69),k=ue(S),I=i(70),P=ue(I),M=i(71),$=ue(M),Z=i(72),Q=ue(Z),K=i(73),B=ue(K),V=i(13),D=ue(V),j=i(74),U=ue(j),Y=i(75),W=ue(Y),F=i(57),q=ue(F),ee=i(41),te=ue(ee),ae=i(28),_e=ue(ae),Ee=i(59),Ce=ue(Ee),qe=i(60),Ze=ue(qe),Et=i(61),kt=ue(Et),ie=i(108),se=ue(ie),pe=i(62),ye=ue(pe);function ue(Ue){return Ue&&Ue.__esModule?Ue:{default:Ue}}o.default.register({"attributors/attribute/direction":l.DirectionAttribute,"attributors/class/align":a.AlignClass,"attributors/class/background":w.BackgroundClass,"attributors/class/color":g.ColorClass,"attributors/class/direction":l.DirectionClass,"attributors/class/font":m.FontClass,"attributors/class/size":b.SizeClass,"attributors/style/align":a.AlignStyle,"attributors/style/background":w.BackgroundStyle,"attributors/style/color":g.ColorStyle,"attributors/style/direction":l.DirectionStyle,"attributors/style/font":m.FontStyle,"attributors/style/size":b.SizeStyle},!0),o.default.register({"formats/align":a.AlignClass,"formats/direction":l.DirectionClass,"formats/indent":u.IndentClass,"formats/background":w.BackgroundStyle,"formats/color":g.ColorStyle,"formats/font":m.FontClass,"formats/size":b.SizeClass,"formats/blockquote":d.default,"formats/code-block":D.default,"formats/header":p.default,"formats/list":y.default,"formats/bold":A.default,"formats/code":V.Code,"formats/italic":x.default,"formats/link":T.default,"formats/script":k.default,"formats/strike":P.default,"formats/underline":$.default,"formats/image":Q.default,"formats/video":B.default,"formats/list/item":_.ListItem,"modules/formula":U.default,"modules/syntax":W.default,"modules/toolbar":q.default,"themes/bubble":se.default,"themes/snow":ye.default,"ui/icons":te.default,"ui/picker":_e.default,"ui/icon-picker":Ze.default,"ui/color-picker":Ce.default,"ui/tooltip":kt.default},!0),r.default=o.default},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.IndentClass=void 0;var s=function(){function y(w,g){for(var m=0;m<g.length;m++){var b=g[m];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(w,b.key,b)}}return function(w,g,m){return g&&y(w.prototype,g),m&&y(w,m),w}}(),o=function y(w,g,m){w===null&&(w=Function.prototype);var b=Object.getOwnPropertyDescriptor(w,g);if(b===void 0){var v=Object.getPrototypeOf(w);return v===null?void 0:y(v,g,m)}else{if("value"in b)return b.value;var A=b.get;return A===void 0?void 0:A.call(m)}},a=i(0),l=u(a);function u(y){return y&&y.__esModule?y:{default:y}}function c(y,w){if(!(y instanceof w))throw new TypeError("Cannot call a class as a function")}function d(y,w){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:y}function f(y,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);y.prototype=Object.create(w&&w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(y,w):y.__proto__=w)}var p=function(y){f(w,y);function w(){return c(this,w),d(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return s(w,[{key:"add",value:function(m,b){if(b==="+1"||b==="-1"){var v=this.value(m)||0;b=b==="+1"?v+1:v-1}return b===0?(this.remove(m),!0):o(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"add",this).call(this,m,b)}},{key:"canAdd",value:function(m,b){return o(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"canAdd",this).call(this,m,b)||o(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"canAdd",this).call(this,m,parseInt(b))}},{key:"value",value:function(m){return parseInt(o(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"value",this).call(this,m))||void 0}}]),w}(l.default.Attributor.Class),_=new p("indent","ql-indent",{scope:l.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});r.IndentClass=_},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(4),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}function l(f,p){if(!(f instanceof p))throw new TypeError("Cannot call a class as a function")}function u(f,p){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:f}function c(f,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);f.prototype=Object.create(p&&p.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(f,p):f.__proto__=p)}var d=function(f){c(p,f);function p(){return l(this,p),u(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p}(o.default);d.blotName="blockquote",d.tagName="blockquote",r.default=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function p(_,y){for(var w=0;w<y.length;w++){var g=y[w];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(_,g.key,g)}}return function(_,y,w){return y&&p(_.prototype,y),w&&p(_,w),_}}(),o=i(4),a=l(o);function l(p){return p&&p.__esModule?p:{default:p}}function u(p,_){if(!(p instanceof _))throw new TypeError("Cannot call a class as a function")}function c(p,_){if(!p)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _&&(typeof _=="object"||typeof _=="function")?_:p}function d(p,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof _);p.prototype=Object.create(_&&_.prototype,{constructor:{value:p,enumerable:!1,writable:!0,configurable:!0}}),_&&(Object.setPrototypeOf?Object.setPrototypeOf(p,_):p.__proto__=_)}var f=function(p){d(_,p);function _(){return u(this,_),c(this,(_.__proto__||Object.getPrototypeOf(_)).apply(this,arguments))}return s(_,null,[{key:"formats",value:function(w){return this.tagName.indexOf(w.tagName)+1}}]),_}(a.default);f.blotName="header",f.tagName=["H1","H2","H3","H4","H5","H6"],r.default=f},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.ListItem=void 0;var s=function(){function v(A,N){for(var x=0;x<N.length;x++){var E=N[x];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(A,E.key,E)}}return function(A,N,x){return N&&v(A.prototype,N),x&&v(A,x),A}}(),o=function v(A,N,x){A===null&&(A=Function.prototype);var E=Object.getOwnPropertyDescriptor(A,N);if(E===void 0){var T=Object.getPrototypeOf(A);return T===null?void 0:v(T,N,x)}else{if("value"in E)return E.value;var S=E.get;return S===void 0?void 0:S.call(x)}},a=i(0),l=p(a),u=i(4),c=p(u),d=i(25),f=p(d);function p(v){return v&&v.__esModule?v:{default:v}}function _(v,A,N){return A in v?Object.defineProperty(v,A,{value:N,enumerable:!0,configurable:!0,writable:!0}):v[A]=N,v}function y(v,A){if(!(v instanceof A))throw new TypeError("Cannot call a class as a function")}function w(v,A){if(!v)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return A&&(typeof A=="object"||typeof A=="function")?A:v}function g(v,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof A);v.prototype=Object.create(A&&A.prototype,{constructor:{value:v,enumerable:!1,writable:!0,configurable:!0}}),A&&(Object.setPrototypeOf?Object.setPrototypeOf(v,A):v.__proto__=A)}var m=function(v){g(A,v);function A(){return y(this,A),w(this,(A.__proto__||Object.getPrototypeOf(A)).apply(this,arguments))}return s(A,[{key:"format",value:function(x,E){x===b.blotName&&!E?this.replaceWith(l.default.create(this.statics.scope)):o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"format",this).call(this,x,E)}},{key:"remove",value:function(){this.prev==null&&this.next==null?this.parent.remove():o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(x,E){return this.parent.isolate(this.offset(this.parent),this.length()),x===this.parent.statics.blotName?(this.parent.replaceWith(x,E),this):(this.parent.unwrap(),o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"replaceWith",this).call(this,x,E))}}],[{key:"formats",value:function(x){return x.tagName===this.tagName?void 0:o(A.__proto__||Object.getPrototypeOf(A),"formats",this).call(this,x)}}]),A}(c.default);m.blotName="list-item",m.tagName="LI";var b=function(v){g(A,v),s(A,null,[{key:"create",value:function(x){var E=x==="ordered"?"OL":"UL",T=o(A.__proto__||Object.getPrototypeOf(A),"create",this).call(this,E);return(x==="checked"||x==="unchecked")&&T.setAttribute("data-checked",x==="checked"),T}},{key:"formats",value:function(x){if(x.tagName==="OL")return"ordered";if(x.tagName==="UL")return x.hasAttribute("data-checked")?x.getAttribute("data-checked")==="true"?"checked":"unchecked":"bullet"}}]);function A(N){y(this,A);var x=w(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,N)),E=function(S){if(S.target.parentNode===N){var k=x.statics.formats(N),I=l.default.find(S.target);k==="checked"?I.format("list","unchecked"):k==="unchecked"&&I.format("list","checked")}};return N.addEventListener("touchstart",E),N.addEventListener("mousedown",E),x}return s(A,[{key:"format",value:function(x,E){this.children.length>0&&this.children.tail.format(x,E)}},{key:"formats",value:function(){return _({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(x,E){if(x instanceof m)o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"insertBefore",this).call(this,x,E);else{var T=E==null?this.length():E.offset(this),S=this.split(T);S.parent.insertBefore(x,S)}}},{key:"optimize",value:function(x){o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"optimize",this).call(this,x);var E=this.next;E!=null&&E.prev===this&&E.statics.blotName===this.statics.blotName&&E.domNode.tagName===this.domNode.tagName&&E.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(E.moveChildren(this),E.remove())}},{key:"replace",value:function(x){if(x.statics.blotName!==this.statics.blotName){var E=l.default.create(this.statics.defaultChild);x.moveChildren(E),this.appendChild(E)}o(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"replace",this).call(this,x)}}]),A}(f.default);b.blotName="list",b.scope=l.default.Scope.BLOCK_BLOT,b.tagName=["OL","UL"],b.defaultChild="list-item",b.allowedChildren=[m],r.ListItem=m,r.default=b},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(56),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}function l(f,p){if(!(f instanceof p))throw new TypeError("Cannot call a class as a function")}function u(f,p){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:f}function c(f,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);f.prototype=Object.create(p&&p.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(f,p):f.__proto__=p)}var d=function(f){c(p,f);function p(){return l(this,p),u(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p}(o.default);d.blotName="italic",d.tagName=["EM","I"],r.default=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function _(y,w){for(var g=0;g<w.length;g++){var m=w[g];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,g){return w&&_(y.prototype,w),g&&_(y,g),y}}(),o=function _(y,w,g){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var b=Object.getPrototypeOf(y);return b===null?void 0:_(b,w,g)}else{if("value"in m)return m.value;var v=m.get;return v===void 0?void 0:v.call(g)}},a=i(6),l=u(a);function u(_){return _&&_.__esModule?_:{default:_}}function c(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function f(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=function(_){f(y,_);function y(){return c(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,null,[{key:"create",value:function(g){return g==="super"?document.createElement("sup"):g==="sub"?document.createElement("sub"):o(y.__proto__||Object.getPrototypeOf(y),"create",this).call(this,g)}},{key:"formats",value:function(g){if(g.tagName==="SUB")return"sub";if(g.tagName==="SUP")return"super"}}]),y}(l.default);p.blotName="script",p.tagName=["SUB","SUP"],r.default=p},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(6),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}function l(f,p){if(!(f instanceof p))throw new TypeError("Cannot call a class as a function")}function u(f,p){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:f}function c(f,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);f.prototype=Object.create(p&&p.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(f,p):f.__proto__=p)}var d=function(f){c(p,f);function p(){return l(this,p),u(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p}(o.default);d.blotName="strike",d.tagName="S",r.default=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=i(6),o=a(s);function a(f){return f&&f.__esModule?f:{default:f}}function l(f,p){if(!(f instanceof p))throw new TypeError("Cannot call a class as a function")}function u(f,p){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:f}function c(f,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);f.prototype=Object.create(p&&p.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(f,p):f.__proto__=p)}var d=function(f){c(p,f);function p(){return l(this,p),u(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p}(o.default);d.blotName="underline",d.tagName="U",r.default=d},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function w(g,m){for(var b=0;b<m.length;b++){var v=m[b];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(g,v.key,v)}}return function(g,m,b){return m&&w(g.prototype,m),b&&w(g,b),g}}(),o=function w(g,m,b){g===null&&(g=Function.prototype);var v=Object.getOwnPropertyDescriptor(g,m);if(v===void 0){var A=Object.getPrototypeOf(g);return A===null?void 0:w(A,m,b)}else{if("value"in v)return v.value;var N=v.get;return N===void 0?void 0:N.call(b)}},a=i(0),l=c(a),u=i(27);function c(w){return w&&w.__esModule?w:{default:w}}function d(w,g){if(!(w instanceof g))throw new TypeError("Cannot call a class as a function")}function f(w,g){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:w}function p(w,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);w.prototype=Object.create(g&&g.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(w,g):w.__proto__=g)}var _=["alt","height","width"],y=function(w){p(g,w);function g(){return d(this,g),f(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"format",value:function(b,v){_.indexOf(b)>-1?v?this.domNode.setAttribute(b,v):this.domNode.removeAttribute(b):o(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"format",this).call(this,b,v)}}],[{key:"create",value:function(b){var v=o(g.__proto__||Object.getPrototypeOf(g),"create",this).call(this,b);return typeof b=="string"&&v.setAttribute("src",this.sanitize(b)),v}},{key:"formats",value:function(b){return _.reduce(function(v,A){return b.hasAttribute(A)&&(v[A]=b.getAttribute(A)),v},{})}},{key:"match",value:function(b){return/\.(jpe?g|gif|png)$/.test(b)||/^data:image\/.+;base64/.test(b)}},{key:"sanitize",value:function(b){return(0,u.sanitize)(b,["http","https","data"])?b:"//:0"}},{key:"value",value:function(b){return b.getAttribute("src")}}]),g}(l.default.Embed);y.blotName="image",y.tagName="IMG",r.default=y},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0});var s=function(){function w(g,m){for(var b=0;b<m.length;b++){var v=m[b];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(g,v.key,v)}}return function(g,m,b){return m&&w(g.prototype,m),b&&w(g,b),g}}(),o=function w(g,m,b){g===null&&(g=Function.prototype);var v=Object.getOwnPropertyDescriptor(g,m);if(v===void 0){var A=Object.getPrototypeOf(g);return A===null?void 0:w(A,m,b)}else{if("value"in v)return v.value;var N=v.get;return N===void 0?void 0:N.call(b)}},a=i(4),l=i(27),u=c(l);function c(w){return w&&w.__esModule?w:{default:w}}function d(w,g){if(!(w instanceof g))throw new TypeError("Cannot call a class as a function")}function f(w,g){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:w}function p(w,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);w.prototype=Object.create(g&&g.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(w,g):w.__proto__=g)}var _=["height","width"],y=function(w){p(g,w);function g(){return d(this,g),f(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"format",value:function(b,v){_.indexOf(b)>-1?v?this.domNode.setAttribute(b,v):this.domNode.removeAttribute(b):o(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"format",this).call(this,b,v)}}],[{key:"create",value:function(b){var v=o(g.__proto__||Object.getPrototypeOf(g),"create",this).call(this,b);return v.setAttribute("frameborder","0"),v.setAttribute("allowfullscreen",!0),v.setAttribute("src",this.sanitize(b)),v}},{key:"formats",value:function(b){return _.reduce(function(v,A){return b.hasAttribute(A)&&(v[A]=b.getAttribute(A)),v},{})}},{key:"sanitize",value:function(b){return u.default.sanitize(b)}},{key:"value",value:function(b){return b.getAttribute("src")}}]),g}(a.BlockEmbed);y.blotName="video",y.className="ql-video",y.tagName="IFRAME",r.default=y},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.FormulaBlot=void 0;var s=function(){function b(v,A){for(var N=0;N<A.length;N++){var x=A[N];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(v,x.key,x)}}return function(v,A,N){return A&&b(v.prototype,A),N&&b(v,N),v}}(),o=function b(v,A,N){v===null&&(v=Function.prototype);var x=Object.getOwnPropertyDescriptor(v,A);if(x===void 0){var E=Object.getPrototypeOf(v);return E===null?void 0:b(E,A,N)}else{if("value"in x)return x.value;var T=x.get;return T===void 0?void 0:T.call(N)}},a=i(35),l=p(a),u=i(5),c=p(u),d=i(9),f=p(d);function p(b){return b&&b.__esModule?b:{default:b}}function _(b,v){if(!(b instanceof v))throw new TypeError("Cannot call a class as a function")}function y(b,v){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return v&&(typeof v=="object"||typeof v=="function")?v:b}function w(b,v){if(typeof v!="function"&&v!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof v);b.prototype=Object.create(v&&v.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),v&&(Object.setPrototypeOf?Object.setPrototypeOf(b,v):b.__proto__=v)}var g=function(b){w(v,b);function v(){return _(this,v),y(this,(v.__proto__||Object.getPrototypeOf(v)).apply(this,arguments))}return s(v,null,[{key:"create",value:function(N){var x=o(v.__proto__||Object.getPrototypeOf(v),"create",this).call(this,N);return typeof N=="string"&&(window.katex.render(N,x,{throwOnError:!1,errorColor:"#f00"}),x.setAttribute("data-value",N)),x}},{key:"value",value:function(N){return N.getAttribute("data-value")}}]),v}(l.default);g.blotName="formula",g.className="ql-formula",g.tagName="SPAN";var m=function(b){w(v,b),s(v,null,[{key:"register",value:function(){c.default.register(g,!0)}}]);function v(){_(this,v);var A=y(this,(v.__proto__||Object.getPrototypeOf(v)).call(this));if(window.katex==null)throw new Error("Formula module requires KaTeX.");return A}return v}(f.default);r.FormulaBlot=g,r.default=m},function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.CodeToken=r.CodeBlock=void 0;var s=function(){function N(x,E){for(var T=0;T<E.length;T++){var S=E[T];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(x,S.key,S)}}return function(x,E,T){return E&&N(x.prototype,E),T&&N(x,T),x}}(),o=function N(x,E,T){x===null&&(x=Function.prototype);var S=Object.getOwnPropertyDescriptor(x,E);if(S===void 0){var k=Object.getPrototypeOf(x);return k===null?void 0:N(k,E,T)}else{if("value"in S)return S.value;var I=S.get;return I===void 0?void 0:I.call(T)}},a=i(0),l=y(a),u=i(5),c=y(u),d=i(9),f=y(d),p=i(13),_=y(p);function y(N){return N&&N.__esModule?N:{default:N}}function w(N,x){if(!(N instanceof x))throw new TypeError("Cannot call a class as a function")}function g(N,x){if(!N)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x&&(typeof x=="object"||typeof x=="function")?x:N}function m(N,x){if(typeof x!="function"&&x!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof x);N.prototype=Object.create(x&&x.prototype,{constructor:{value:N,enumerable:!1,writable:!0,configurable:!0}}),x&&(Object.setPrototypeOf?Object.setPrototypeOf(N,x):N.__proto__=x)}var b=function(N){m(x,N);function x(){return w(this,x),g(this,(x.__proto__||Object.getPrototypeOf(x)).apply(this,arguments))}return s(x,[{key:"replaceWith",value:function(T){this.domNode.textContent=this.domNode.textContent,this.attach(),o(x.prototype.__proto__||Object.getPrototypeOf(x.prototype),"replaceWith",this).call(this,T)}},{key:"highlight",value:function(T){var S=this.domNode.textContent;this.cachedText!==S&&((S.trim().length>0||this.cachedText==null)&&(this.domNode.innerHTML=T(S),this.domNode.normalize(),this.attach()),this.cachedText=S)}}]),x}(_.default);b.className="ql-syntax";var v=new l.default.Attributor.Class("token","hljs",{scope:l.default.Scope.INLINE}),A=function(N){m(x,N),s(x,null,[{key:"register",value:function(){c.default.register(v,!0),c.default.register(b,!0)}}]);function x(E,T){w(this,x);var S=g(this,(x.__proto__||Object.getPrototypeOf(x)).call(this,E,T));if(typeof S.options.highlight!="function")throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var k=null;return S.quill.on(c.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(k),k=setTimeout(function(){S.highlight(),k=null},S.options.interval)}),S.highlight(),S}return s(x,[{key:"highlight",value:function(){var T=this;if(!this.quill.selection.composing){this.quill.update(c.default.sources.USER);var S=this.quill.getSelection();this.quill.scroll.descendants(b).forEach(function(k){k.highlight(T.options.highlight)}),this.quill.update(c.default.sources.SILENT),S!=null&&this.quill.setSelection(S,c.default.sources.SILENT)}}}]),x}(f.default);A.DEFAULTS={highlight:function(){return window.hljs==null?null:function(N){var x=window.hljs.highlightAuto(N);return x.value}}(),interval:1e3},r.CodeBlock=b,r.CodeToken=v,r.default=A},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'},function(n,r){n.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line>
3767 <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'},function(n,r){n.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'},function(n,r){n.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'},function(n,r){n.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'},function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'}
vendor: 9,442 bytes, line 3767
3767,function(n,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BubbleTooltip=void 0;var s=function x(E,T,S){E===null&&(E=Function.prototype);var k=Object.getOwnPropertyDescriptor(E,T);if(k===void 0){var I=Object.getPrototypeOf(E);return I===null?void 0:x(I,T,S)}else{if("value"in k)return k.value;var P=k.get;return P===void 0?void 0:P.call(S)}},o=function(){function x(E,T){for(var S=0;S<T.length;S++){var k=T[S];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(E,k.key,k)}}return function(E,T,S){return T&&x(E.prototype,T),S&&x(E,S),E}}(),a=i(3),l=w(a),u=i(8),c=w(u),d=i(43),f=w(d),p=i(15),_=i(41),y=w(_);function w(x){return x&&x.__esModule?x:{default:x}}function g(x,E){if(!(x instanceof E))throw new TypeError("Cannot call a class as a function")}function m(x,E){if(!x)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return E&&(typeof E=="object"||typeof E=="function")?E:x}function b(x,E){if(typeof E!="function"&&E!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof E);x.prototype=Object.create(E&&E.prototype,{constructor:{value:x,enumerable:!1,writable:!0,configurable:!0}}),E&&(Object.setPrototypeOf?Object.setPrototypeOf(x,E):x.__proto__=E)}var v=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],A=function(x){b(E,x);function E(T,S){g(this,E),S.modules.toolbar!=null&&S.modules.toolbar.container==null&&(S.modules.toolbar.container=v);var k=m(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,T,S));return k.quill.container.classList.add("ql-bubble"),k}return o(E,[{key:"extendToolbar",value:function(S){this.tooltip=new N(this.quill,this.options.bounds),this.tooltip.root.appendChild(S.container),this.buildButtons([].slice.call(S.container.querySelectorAll("button")),y.default),this.buildPickers([].slice.call(S.container.querySelectorAll("select")),y.default)}}]),E}(f.default);A.DEFAULTS=(0,l.default)(!0,{},f.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(E){E?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var N=function(x){b(E,x);function E(T,S){g(this,E);var k=m(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,T,S));return k.quill.on(c.default.events.EDITOR_CHANGE,function(I,P,M,$){if(I===c.default.events.SELECTION_CHANGE)if(P!=null&&P.length>0&&$===c.default.sources.USER){k.show(),k.root.style.left="0px",k.root.style.width="",k.root.style.width=k.root.offsetWidth+"px";var Z=k.quill.getLines(P.index,P.length);if(Z.length===1)k.position(k.quill.getBounds(P));else{var Q=Z[Z.length-1],K=k.quill.getIndex(Q),B=Math.min(Q.length()-1,P.index+P.length-K),V=k.quill.getBounds(new p.Range(K,B));k.position(V)}}else document.activeElement!==k.textbox&&k.quill.hasFocus()&&k.hide()}),k}return o(E,[{key:"listen",value:function(){var S=this;s(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){S.root.classList.remove("ql-editing")}),this.quill.on(c.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!S.root.classList.contains("ql-hidden")){var k=S.quill.getSelection();k!=null&&S.position(S.quill.getBounds(k))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(S){var k=s(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"position",this).call(this,S),I=this.root.querySelector(".ql-tooltip-arrow");if(I.style.marginLeft="",k===0)return k;I.style.marginLeft=-1*k-I.offsetWidth/2+"px"}}]),E}(d.BaseTooltip);N.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),r.BubbleTooltip=N,r.default=A},function(n,r,i){n.exports=i(63)}]).default})})(cC);var PZ=cC.exports,RZ=br&&br.__extends||function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var s in i)i.hasOwnProperty(s)&&(r[s]=i[s])},t(e,n)};return function(e,n){t(e,n);function r(){this.constructor=e}e.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}}(),Yp=br&&br.__assign||function(){return Yp=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++){e=arguments[n];for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])}return t},Yp.apply(this,arguments)},CZ=br&&br.__spreadArrays||function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;for(var r=Array(t),i=0,e=0;e<n;e++)for(var s=arguments[e],o=0,a=s.length;o<a;o++,i++)r[i]=s[o];return r},hg=br&&br.__importDefault||function(t){return t&&t.__esModule?t:{default:t}},xi=hg(H),NZ=hg(wm),xc=hg(OZ),hS=hg(PZ),DZ=function(t){RZ(e,t);function e(n){var r=t.call(this,n)||this;r.dirtyProps=["modules","formats","bounds","theme","children"],r.cleanProps=["id","className","style","placeholder","tabIndex","onChange","onChangeSelection","onFocus","onBlur","onKeyPress","onKeyDown","onKeyUp"],r.state={generation:0},r.selection=null,r.onEditorChange=function(s,o,a,l){var u,c,d,f;s==="text-change"?(c=(u=r).onEditorChangeText)===null||c===void 0||c.call(u,r.editor.root.innerHTML,o,l,r.unprivilegedEditor):s==="selection-change"&&((f=(d=r).onEditorChangeSelection)===null||f===void 0||f.call(d,o,l,r.unprivilegedEditor))};var i=r.isControlled()?n.value:n.defaultValue;return r.value=i??"",r}return e.prototype.validateProps=function(n){var r;if(xi.default.Children.count(n.children)>1)throw new Error("The Quill editing area can only be composed of a single React element.");if(xi.default.Children.count(n.children)){var i=xi.default.Children.only(n.children);if(((r=i)===null||r===void 0?void 0:r.type)==="textarea")throw new Error("Quill does not support editing on a <textarea>. Use a <div> instead.")}if(this.lastDeltaChangeSet&&n.value===this.lastDeltaChangeSet)throw new Error("You are passing the `delta` object from the `onChange` event back as `value`. You most probably want `editor.getContents()` instead. See: https://github.com/zenoamaro/react-quill#using-deltas")},e.prototype.shouldComponentUpdate=function(n,r){var i=this,s;if(this.validateProps(n),!this.editor||this.state.generation!==r.generation)return!0;if("value"in n){var o=this.getEditorContents(),a=(s=n.value,s??"");this.isEqualValue(a,o)||this.setEditorContents(this.editor,a)}return n.readOnly!==this.props.readOnly&&this.setEditorReadOnly(this.editor,n.readOnly),CZ(this.cleanProps,this.dirtyProps).some(function(l){return!xc.default(n[l],i.props[l])})},e.prototype.shouldComponentRegenerate=function(n){var r=this;return this.dirtyProps.some(function(i){return!xc.default(n[i],r.props[i])})},e.prototype.componentDidMount=function(){this.instantiateEditor(),this.setEditorContents(this.editor,this.getEditorContents())},e.prototype.componentWillUnmount=function(){this.destroyEditor()},e.prototype.componentDidUpdate=function(n,r){var i=this;if(this.editor&&this.shouldComponentRegenerate(n)){var s=this.editor.getContents(),o=this.editor.getSelection();this.regenerationSnapshot={delta:s,selection:o},this.setState({generation:this.state.generation+1}),this.destroyEditor()}if(this.state.generation!==r.generation){var a=this.regenerationSnapshot,s=a.delta,l=a.selection;delete this.regenerationSnapshot,this.instantiateEditor();var u=this.editor;u.setContents(s),pS(function(){return i.setEditorSelection(u,l)})}},e.prototype.instantiateEditor=function(){this.editor?this.hookEditor(this.editor):this.editor=this.createEditor(this.getEditingArea(),this.getEditorConfig())},e.prototype.destroyEditor=function(){this.editor&&this.unhookEditor(this.editor)},e.prototype.isControlled=function(){return"value"in this.props},e.prototype.getEditorConfig=function(){return{bounds:this.props.bounds,formats:this.props.formats,modules:this.props.modules,placeholder:this.props.placeholder,readOnly:this.props.readOnly,scrollingContainer:this.props.scrollingContainer,tabIndex:this.props.tabIndex,theme:this.props.theme}},e.prototype.getEditor=function(){if(!this.editor)throw new Error("Accessing non-instantiated editor");return this.editor},e.prototype.createEditor=function(n,r){var i=new hS.default(n,r);return r.tabIndex!=null&&this.setEditorTabIndex(i,r.tabIndex),this.hookEditor(i),i},e.prototype.hookEditor=function(n){this.unprivilegedEditor=this.makeUnprivilegedEditor(n),n.on("editor-change",this.onEditorChange)},e.prototype.unhookEditor=function(n){n.off("editor-change",this.onEditorChange)},e.prototype.getEditorContents=function(){return this.value},e.prototype.getEditorSelection=function(){return this.selection},e.prototype.isDelta=function(n){return n&&n.ops},e.prototype.isEqualValue=function(n,r){return this.isDelta(n)&&this.isDelta(r)?xc.default(n.ops,r.ops):xc.default(n,r)},e.prototype.setEditorContents=function(n,r){var i=this;this.value=r;var s=this.getEditorSelection();typeof r=="string"?n.setContents(n.clipboard.convert(r)):n.setContents(r),pS(function(){return i.setEditorSelection(n,s)})},e.prototype.setEditorSelection=function(n,r){if(this.selection=r,r){var i=n.getLength();r.index=Math.max(0,Math.min(r.index,i-1)),r.length=Math.max(0,Math.min(r.length,i-1-r.index)),n.setSelection(r)}},e.prototype.setEditorTabIndex=function(n,r){var i,s;!((s=(i=n)===null||i===void 0?void 0:i.scroll)===null||s===void 0)&&s.domNo
3767de&&(n.scroll.domNode.tabIndex=r)},e.prototype.setEditorReadOnly=function(n,r){r?n.disable():n.enable()},e.prototype.makeUnprivilegedEditor=function(n){var r=n;return{getHTML:function(){return r.root.innerHTML},getLength:r.getLength.bind(r),getText:r.getText.bind(r),getContents:r.getContents.bind(r),getSelection:r.getSelection.bind(r),getBounds:r.getBounds.bind(r)}},e.prototype.getEditingArea=function(){if(!this.editingArea)throw new Error("Instantiating on missing editing area");var n=NZ.default.findDOMNode(this.editingArea);if(!n)throw new Error("Cannot find element for editing area");if(n.nodeType===3)throw new Error("Editing area cannot be a text node");return n},e.prototype.renderEditingArea=function(){var n=this,r=this.props,i=r.children,s=r.preserveWhitespace,o=this.state.generation,a={key:o,ref:function(l){n.editingArea=l}};return xi.default.Children.count(i)?xi.default.cloneElement(xi.default.Children.only(i),a):s?xi.default.createElement("pre",Yp({},a)):xi.default.createElement("div",Yp({},a))},e.prototype.render=function(){var n;return xi.default.createElement("div",{id:this.props.id,style:this.props.style,key:this.state.generation,className:"quill "+(n=this.props.className,n??""),onKeyPress:this.props.onKeyPress,onKeyDown:this.props.onKeyDown,onKeyUp:this.props.onKeyUp},this.renderEditingArea())},e.prototype.onEditorChangeText=function(n,r,i,s){var o,a;if(this.editor){var l=this.isDelta(this.value)?s.getContents():s.getHTML();l!==this.getEditorContents()&&(this.lastDeltaChangeSet=r,this.value=l,(a=(o=this.props).onChange)===null||a===void 0||a.call(o,n,r,i,s))}},e.prototype.onEditorChangeSelection=function(n,r,i){var s,o,a,l,u,c;if(this.editor){var d=this.getEditorSelection(),f=!d&&n,p=d&&!n;xc.default(n,d)||(this.selection=n,(o=(s=this.props).onChangeSelection)===null||o===void 0||o.call(s,n,r,i),f?(l=(a=this.props).onFocus)===null||l===void 0||l.call(a,n,r,i):p&&((c=(u=this.props).onBlur)===null||c===void 0||c.call(u,d,r,i)))}},e.prototype.focus=function(){this.editor&&this.editor.focus()},e.prototype.blur=function(){this.editor&&(this.selection=null,this.editor.blur())},e.displayName="React Quill",e.Quill=hS.default,e.defaultProps={theme:"snow",modules:{},readOnly:!1},e}(xi.default.Component);function pS(t){Promise.resolve().then(t)}var MZ=DZ;const fC=Ou(MZ);var pg={},dC={exports:{}},LZ="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",jZ=LZ,FZ=jZ;function hC(){}function pC(){}pC.resetWarningCache=hC;var VZ=function(){function t(r,i,s,o,a,l){if(l!==FZ){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}t.isRequired=t;function e(){return t}var n={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:pC,resetWarningCache:hC};return n.PropTypes=n,n};dC.exports=VZ();var Iw=dC.exports;const St=Ou(Iw);var mC={exports:{}};/*! 3768 Copyright (c) 2018 Jed Watson. 3769 Licensed under the MIT License (MIT), see 3770 http://jedwatson.github.io/classnames 3771*/(function(t){(function(){var e={}.hasOwnProperty;function n(){for(var s="",o=0;o<arguments.length;o++){var a=arguments[o];a&&(s=i(s,r(a)))}return s}function r(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return n.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var o="";for(var a in s)e.call(s,a)&&s[a]&&(o=i(o,a));return o}function i(s,o){return o?s?s+" "+o:s+o:s}t.exports?(n.default=n,t.exports=n):window.classNames=n})()})(mC);var gC=mC.exports;pg.__esModule=!0;pg.default=void 0;var UZ=Ow(H),Qs=Ow(Iw),$Z=Ow(gC);function Ow(t){return t&&t.__esModule?t:{default:t}}const vC=({animate:t=!0,className:e="",layout:n="2-columns",lineColor:r="#FFF",children:i})=>(typeof window=="object"&&document.documentElement.style.setProperty("--line-color",r),UZ.default.createElement("div",{className:(0,$Z.default)(e,"vertical-timeline",{"vertical-timeline--animate":t,"vertical-timeline--two-columns":n==="2-columns","vertical-timeline--one-column-left":n==="1-column"||n==="1-column-left","vertical-timeline--one-column-right":n==="1-column-right"})},i));vC.propTypes={children:Qs.default.oneOfType([Qs.default.arrayOf(Qs.default.node),Qs.default.node]).isRequired,className:Qs.default.string,animate:Qs.default.bool,layout:Qs.default.oneOf(["1-column-left","1-column","2-columns","1-column-right"]),lineColor:Qs.default.string};var BZ=vC;pg.default=BZ;var mg={};function S0(){return S0=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},S0.apply(this,arguments)}function zZ(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,k0(t,e)}
3771function k0(t,e){return k0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},k0(t,e)}function qZ(t,e){if(t==null)return{};var n={},r=Object.keys(t),i,s;for(s=0;s<r.length;s++)i=r[s],!(e.indexOf(i)>=0)&&(n[i]=t[i]);return n}var A0=new Map,uh=new WeakMap,mS=0,yC=void 0;function HZ(t){yC=t}function WZ(t){return t?(uh.has(t)||(mS+=1,uh.set(t,mS.toString())),uh.get(t)):"0"}function GZ(t){return Object.keys(t).sort().filter(function(e){return t[e]!==void 0}).map(function(e){return e+"_"+(e==="root"?WZ(t.root):t[e])}).toString()}function KZ(t){var e=GZ(t),n=A0.get(e);if(!n){var r=new Map,i,s=new IntersectionObserver(function(o){o.forEach(function(a){var l,u=a.isIntersecting&&i.some(function(c){return a.intersectionRatio>=c});t.trackVisibility&&typeof a.isVisible>"u"&&(a.isVisible=u),(l=r.get(a.target))==null||l.forEach(function(c){c(u,a)})})},t);i=s.thresholds||(Array.isArray(t.threshold)?t.threshold:[t.threshold||0]),n={id:e,observer:s,elements:r},A0.set(e,n)}return n}function Pw(t,e,n,r){if(n===void 0&&(n={}),r===void 0&&(r=yC),typeof window.IntersectionObserver>"u"&&r!==void 0){var i=t.getBoundingClientRect();return e(r,{isIntersecting:r,target:t,intersectionRatio:typeof n.threshold=="number"?n.threshold:0,time:0,boundingClientRect:i,intersectionRect:i,rootBounds:i}),function(){}}var s=KZ(n),o=s.id,a=s.observer,l=s.elements,u=l.get(t)||[];return l.has(t)||l.set(t,u),u.push(e),a.observe(t),function(){u.splice(u.indexOf(e),1),u.length===0&&(l.delete(t),a.unobserve(t)),l.size===0&&(a.disconnect(),A0.delete(o))}}var YZ=["children","as","triggerOnce","threshold","root","rootMargin","onChange","skip","trackVisibility","delay","initialInView","fallbackInView"];function gS(t){return typeof t.children!="function"}var Qp=function(t){zZ(e,t);function e(r){var i;return i=t.call(this,r)||this,i.node=null,i._unobserveCb=null,i.handleNode=function(s){i.node&&(i.unobserve(),!s&&!i.props.triggerOnce&&!i.props.skip&&i.setState({inView:!!i.props.initialInView,entry:void 0})),i.node=s||null,i.observeNode()},i.handleChange=function(s,o){s&&i.props.triggerOnce&&i.unobserve(),gS(i.props)||i.setState({inView:s,entry:o}),i.props.onChange&&i.props.onChange(s,o)},i.state={inView:!!r.initialInView,entry:void 0},i}var n=e.prototype;return n.componentDidUpdate=function(i){(i.rootMargin!==this.props.rootMargin||i.root!==this.props.root||i.threshold!==this.props.threshold||i.skip!==this.props.skip||i.trackVisibility!==this.props.trackVisibility||i.delay!==this.props.delay)&&(this.unobserve(),this.observeNode())},n.componentWillUnmount=function(){this.unobserve(),this.node=null},n.observeNode=function(){if(!(!this.node||this.props.skip)){var i=this.props,s=i.threshold,o=i.root,a=i.rootMargin,l=i.trackVisibility,u=i.delay,c=i.fallbackInView;this._unobserveCb=Pw(this.node,this.handleChange,{threshold:s,root:o,rootMargin:a,trackVisibility:l,delay:u},c)}},n.unobserve=function(){this._unobserveCb&&(this._unobserveCb(),this._unobserveCb=null)},n.render=function(){if(!gS(this.props)){var i=this.state,s=i.inView,o=i.entry;return this.props.children({inView:s,entry:o,ref:this.handleNode})}var a=this.props,l=a.children,u=a.as,c=qZ(a,YZ);return H.createElement(u||"div",S0({ref:this.handleNode},c),l)},e}(H.Component);Qp.displayName="InView";Qp.defaultProps={threshold:0,triggerOnce:!1,initialInView:!1};function QZ(t){var e=t===void 0?{}:t,n=e.threshold,r=e.delay,i=e.trackVisibility,s=e.rootMargin,o=e.root,a=e.triggerOnce,l=e.skip,u=e.initialInView,c=e.fallbackInView,d=H.useRef(),f=H.useState({inView:!!u}),p=f[0],_=f[1],y=H.useCallback(function(g){d.current!==void 0&&(d.current(),d.current=void 0),!l&&g&&(d.current=Pw(g,function(m,b){_({inView:m,entry:b}),b.isIntersecting&&a&&d.current&&(d.current(),d.current=void 0)},{root:o,rootMargin:s,threshold:n,trackVisibility:i,delay:r},c))},[Array.isArray(n)?n.toString():n,o,s,a,l,i,c,r]);H.useEffect(function(){!d.current&&p.entry&&!a&&!l&&_({inView:!!u})});var w=[y,p.inView,p.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}const ZZ=Object.freeze(Object.defineProperty({__proto__:null,InView:Qp,default:Qp,defaultFallbackInView:HZ,observe:Pw,useInView:QZ},Symbol.toStringTag,{value:"Module"})),XZ=wN(ZZ);mg.__esModule=!0;mg.default=void 0;var Zs=Rw(H),$t=Rw(Iw),ch=Rw(gC),JZ=XZ;function Rw(t){return t&&t.__esModule?t:{default:t}}const _C=({children:t="",className:e="",contentArrowStyle:n=null,contentStyle:r=null,date:i="",dateClassName:s="",icon:o=null,iconClassName:a="",iconOnClick:l=null,onTimelineElementClick:u=null,iconStyle:c=null,id:d="",position:f="",style:p=null,textClassName:_="",intersectionObserverProps:y={rootMargin:"0px 0px -40px 0px",triggerOnce:!0},visible:w=!1})=>Zs.default.createElement(JZ.InView,y,({inView:g,ref:m})=>
3771Zs.default.createElement("div",{ref:m,id:d,className:(0,ch.default)(e,"vertical-timeline-element",{"vertical-timeline-element--left":f==="left","vertical-timeline-element--right":f==="right","vertical-timeline-element--no-children":t===""}),style:p},Zs.default.createElement(Zs.default.Fragment,null,Zs.default.createElement("span",{style:c,onClick:l,className:(0,ch.default)(a,"vertical-timeline-element-icon",{"bounce-in":g||w,"is-hidden":!(g||w)})},o),Zs.default.createElement("div",{style:r,onClick:u,className:(0,ch.default)(_,"vertical-timeline-element-content",{"bounce-in":g||w,"is-hidden":!(g||w)})},Zs.default.createElement("div",{style:n,className:"vertical-timeline-element-content-arrow"}),t,Zs.default.createElement("span",{className:(0,ch.default)(s,"vertical-timeline-element-date")},i)))));_C.propTypes={children:$t.default.oneOfType([$t.default.arrayOf($t.default.node),$t.default.node]),className:$t.default.string,contentArrowStyle:$t.default.shape({}),contentStyle:$t.default.shape({}),date:$t.default.node,dateClassName:$t.default.string,icon:$t.default.element,iconClassName:$t.default.string,iconStyle:$t.default.shape({}),iconOnClick:$t.default.func,onTimelineElementClick:$t.default.func,id:$t.default.string,position:$t.default.string,style:$t.default.shape({}),textClassName:$t.default.string,visible:$t.default.bool,intersectionObserverProps:$t.default.shape({root:$t.default.object,rootMargin:$t.default.string,threshold:$t.default.number,triggerOnce:$t.default.bool})};var eX=_C;mg.default=eX;var vS={VerticalTimeline:pg.default,VerticalTimelineElement:mg.default};function yS(t){return yd({attr:{viewBox:"0 0 384 512"},child:[{tag:"path",attr:{d:"M64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-288-128 0c-17.7 0-32-14.3-32-32L224 0 64 0zM256 0l0 128 128 0L256 0zM216 408c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-102.1-31 31c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l72-72c9.4-9.4 24.6-9.4 33.9 0l72 72c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-31-31L216 408z"},child:[]}]})(t)}function tX(t){return yd({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M96 32l0 32L48 64C21.5 64 0 85.5 0 112l0 48 448 0 0-48c0-26.5-21.5-48-48-48l-48 0 0-32c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 32L160 64l0-32c0-17.7-14.3-32-32-32S96 14.3 96 32zM448 192L0 192 0 464c0 26.5 21.5 48 48 48l352 0c26.5 0 48-21.5 48-48l0-272zM224 248c13.3 0 24 10.7 24 24l0 56 56 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-56 0 0 56c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-56-56 0c-13.3 0-24-10.7-24-24s10.7-24 24-24l56 0 0-56c0-13.3 10.7-24 24-24z"},child:[]}]})(t)}const nX=({fill:t,className:e})=>{const n=t??"#ea7603";return R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"249.947",height:"249.947",viewBox:"0 0 249.947 249.947",className:e,children:R.jsx("g",{style:{isolation:"isolate"},children:R.jsx("g",{id:"Layer_1","data-name":"Layer 1",children:R.jsxs("g",{style:{mixBlendMode:"multiply"},children:[R.jsx("path",{d:"M125.02,50.833a2.647,2.647,0,0,0,2.636-2.635V2.6a2.636,2.636,0,0,0-5.271,0V48.2A2.69,2.69,0,0,0,125.02,50.833Z",fill:n}),R.jsx("path",{d:"M105.83,53.347a2.646,2.646,0,0,0,1.863-3.228l-11.8-44.04A2.636,2.636,0,0,0,90.8,7.443l11.8,44.041A2.69,2.69,0,0,0,105.83,53.347Z",fill:n}),R.jsx("path",{d:"M87.944,60.743a2.649,2.649,0,0,0,.965-3.6l-22.8-39.485a2.635,2.635,0,0,0-4.564,2.635l22.8,39.486A2.691,2.691,0,0,0,87.944,60.743Z",fill:n}),R.jsx("path",{d:"M72.581,72.515a2.647,2.647,0,0,0,0-3.727l-32.24-32.24a2.636,2.636,0,0,0-3.727,3.727l32.24,32.24A2.69,2.69,0,0,0,72.581,72.515Z",fill:n}),R.jsx("path",{d:"M60.79,87.863a2.649,2.649,0,0,0-.965-3.6l-39.486-22.8A2.636,2.636,0,0,0,17.7,66.03l39.485,22.8A2.692,2.692,0,0,0,60.79,87.863Z",fill:n}),R.jsx("path",{d:"M53.372,105.739a2.648,2.648,0,0,0-1.864-3.228L7.467,90.711A2.635,2.635,0,0,0,6.1,95.8l44.041,11.8A2.691,2.691,0,0,0,53.372,105.739Z",fill:n}),R.jsx("path",{d:"M50.833,124.926a2.647,2.647,0,0,0-2.635-2.635H2.6a2.636,2.636,0,0,0,0,5.271H48.2A2.69,2.69,0,0,0,50.833,124.926Z",fill:n}),R.jsx("path",{d:"M53.347,144.117a2.648,2.648,0,0,0-3.228-1.864l-44.04,11.8a2.635,2.635,0,0,0,1.364,5.091l44.041-11.8A2.69,2.69,0,0,0,53.347,144.117Z",fill:n}),R.jsx("path",{d:"M60.743,162a2.648,2.648,0,0,0-3.6-.965l-39.485,22.8a2.636,2.636,0,0,0,2.635,4.565l39.486-22.8A2.69,2.69,0,0,0,60.743,162Z",fill:n}),R.jsx("path",{d:"M72.515,177.365a2.647,2.647,0,0,0-3.727,0l-32.24,32.24a2.636,2.636,0,0,0,3.727,3.727l32.24-32.24A2.69,2.69,0,0,0,72.515,177.365Z",fill:n}),R.jsx("path",{d:"M87.863,189.157a2.648,2.648,0,0,0-3.6.965l-22.8,39.486a2.636,2.636,0,0,0,4.565,2.635l22.8-39.486A2.691,2.691,0,0,0,87.863,189.157Z",fill:n}),R.jsx("path",{d:"M105.739,196.575a2.648,2.648,0,0,0-3.228,1.864l-11.8,44.04a2.636,2.636,0,0,0,5.091,1.365L107.6,199.8A2.691,2.691,0,0,0,105.739,196.575Z",fill:n}),R.jsx("path",{d:"M124.926,199.113a2.648,2.648,0,0,0-2.635,2.636v45.594a2.636,2.636,0,0,0,5.271,0V201.749A2.691,2.691,0,0,0,124.926,199.113Z",fill:n}),R.jsx("path",{d:"M144.117,196.6a2.648,2.648,0,0,0-1.864,3.228l11.8,44.041a2.635,2.635,0,0,0,5.091-1.364l-11.8-44.041A2.692,2.692,0,0,0,144.117,196.6Z",fill:n}),R.jsx("path",{d:"M162,189.2a2.647,2.647,0,0,0-.965,3.6l22.8,39.486a2.636,2.636,0,0,0,4.565-2.636l-22.8-39.485A2.69,2.69,0,0,0,162,189.2Z",fill:n}),R.jsx("path",{d:"M177.365,177.431a2.648,2.648,0,0,0,0,3.728l32.24,32.24a2.636,2.636,0,0,0,3.727-3.728l-32.24-32.24A2.691,2.691,0,0,0,177.365,177.431Z",fill:n}),R.jsx("path",{d:"M189.157,162.084a2.647,2.647,0,0,0,.965,3.6l39.486,22.8a2.636,2.636,0,0,0,2.635-4.565l-39.486-22.8A2.69,2.69,0,0,0,189.157,162.084Z",fill:n}),R.jsx("path",{d:"M196.575,144.207a2.648,2.648,0,0,0,1.864,3.228l44.04,11.8a2.636,2.636,0,0,0,1.365-5.091l-44.041-11.8A2.691,2.691,0,0,0,196.575,144.207Z",fill:n}),R.jsx("path",{d:"M199.113,125.02a2.649,2.649,0,0,0,2.636,2.636h45.594a2.636,2.636,0,0,0,0-5.271H201.749A2.69,2.69,0,0,0,199.113,125.02Z",fill:n}),R.jsx("path",{d:"M196.6,105.83a2.647,2.647,0,0,0,3.228,1.863l44.041-11.8A2.636,2.636,0,0,0,242.5,90.8l-44.041,11.8A2.691,2.691,0,0,0,196.6,105.83Z",fill:n}),R.jsx("path",{d:"M189.2,87.944a2.648,2.648,0,0,0,3.6.965l39.486-22.8a2.635,2.635,0,0,0-2.636-4.564l-39.485,22.8A2.69,2.69,0,0,0,189.2,87.944Z",fill:n}),R.jsx("path",{d:"M177.431,72.581a2.648,2.648,0,0,0,3.728,0l32.24-32.24a2.636,2.636,0,0,0-3.728-3.727l-32.24,32.24A2.691,2.691,0,0,0,177.431,72.581Z",fill:n}),R.jsx("path",{d:"M162.084,60.79a2.648,2.648,0,0,0,3.6-.965l22.8-39.486a2.636,2.636,0,0,0-4.565-2.635l-22.8,39.485A2.691,2.691,0,0,0,162.084,60.79Z",fill:n}),R.jsx("path",{d:"M144.207,53.372a2.648,2.648,0,0,0,3.228-1.864l11.8-44.041A2.635,2.635,0,0,0,154.145,6.1l-11.8,44.041A2.691,2.691,0,0,0,144.207,53.372Z",fill:n}),R.jsx("path",{d:"M139.124,143.492a2.649,2.649,0,0,0-.486,3.7l27.756,36.172a2.636,2.636,0,0,0,4.182-3.209L142.82,143.979A2.692,2.692,0,0,0,139.124,143.492Z",fill:n}),R.jsx("path",{d:"M143.435,139.2a2.647,2.647,0,0,0,.487,3.695l36.172,27.756a2.636,2.636,0,0,0,3.209-4.182l-36.172-27.756A2.691,2.691,0,0,0,143.435,139.2Z",fill:n}),R.jsx("path",{d:"M146.488,133.936a2.647,2.647,0,0,0,1.426,3.443l42.124,17.448a2.635,2.635,0,0,0,2.017-4.869l-42.123-17.449A2.691,2.691,0,0,0,146.488,133.936Z",fill:n}),R.jsx("path",{d:"M103.423,133.849a2.648,2.648,0,0,0-3.444-1.426L57.855,149.871a2.636,2.636,0,0,0,2.018,4.87L102,137.293A2.692,2.692,0,0,0,103.423,133.849Z",fill:n}),R.jsx("path",{d:"M106.454,139.124a2.647,2.647,0,0,0-3.695-.486L66.586,166.394a2.636,2.636,0,0,0,3.209,4.182l36.173-27.756A2.692,2.692,0,0,0,106.454,139.124Z",fill:n}),R.jsx("path",{d:"M110.748,143.435a2.648,2.648,0,0,0-3.7.487L79.3,180.094a2.636,2.636,0,0,0,4.182,3.209l27.756-36.172A2.691,2.691,0,0,0,110.748,143.435Z",fill:n}
3771),R.jsx("path",{d:"M116.011,146.488a2.649,2.649,0,0,0-3.444,1.426L95.119,190.038a2.636,2.636,0,0,0,4.87,2.017l17.448-42.123A2.69,2.69,0,0,0,116.011,146.488Z",fill:n}),R.jsx("path",{d:"M121.885,148.075a2.647,2.647,0,0,0-2.957,2.269l-5.952,45.2a2.636,2.636,0,0,0,5.226.688l5.952-45.2A2.691,2.691,0,0,0,121.885,148.075Z",fill:n}),R.jsx("path",{d:"M127.969,148.087a2.647,2.647,0,0,0-2.269,2.957l5.951,45.2a2.636,2.636,0,0,0,5.226-.688l-5.951-45.2A2.691,2.691,0,0,0,127.969,148.087Z",fill:n}),R.jsx("path",{d:"M133.849,146.524a2.647,2.647,0,0,0-1.426,3.443l17.448,42.124a2.636,2.636,0,0,0,4.87-2.017L137.293,147.95A2.691,2.691,0,0,0,133.849,146.524Z",fill:n}),R.jsx("path",{d:"M148.075,128.062a2.647,2.647,0,0,0,2.269,2.957l45.2,5.951a2.636,2.636,0,0,0,.688-5.226l-45.2-5.951A2.69,2.69,0,0,0,148.075,128.062Z",fill:n}),R.jsx("path",{d:"M148.087,121.978a2.648,2.648,0,0,0,2.957,2.269l45.2-5.952a2.636,2.636,0,0,0-.688-5.226l-45.2,5.952A2.69,2.69,0,0,0,148.087,121.978Z",fill:n}),R.jsx("path",{d:"M146.524,116.1a2.648,2.648,0,0,0,3.444,1.427l42.123-17.448a2.636,2.636,0,0,0-2.017-4.87L147.95,112.654A2.69,2.69,0,0,0,146.524,116.1Z",fill:n}),R.jsx("path",{d:"M143.492,110.822a2.648,2.648,0,0,0,3.7.487L183.36,83.553a2.636,2.636,0,0,0-3.209-4.182l-36.172,27.756A2.691,2.691,0,0,0,143.492,110.822Z",fill:n}),R.jsx("path",{d:"M139.2,106.511a2.647,2.647,0,0,0,3.695-.486L170.65,69.852a2.636,2.636,0,0,0-4.182-3.208l-27.756,36.172A2.69,2.69,0,0,0,139.2,106.511Z",fill:n}),R.jsx("path",{d:"M133.936,103.458a2.646,2.646,0,0,0,3.443-1.426l17.448-42.124a2.635,2.635,0,0,0-4.869-2.017l-17.449,42.124A2.69,2.69,0,0,0,133.936,103.458Z",fill:n}),R.jsx("path",{d:"M121.978,101.86a2.648,2.648,0,0,0,2.269-2.957L118.3,53.7a2.636,2.636,0,0,0-5.226.688l5.952,45.2A2.69,2.69,0,0,0,121.978,101.86Z",fill:n}),R.jsx("path",{d:"M116.1,103.423a2.648,2.648,0,0,0,1.427-3.444L100.076,57.855a2.636,2.636,0,0,0-4.87,2.018L112.654,102A2.691,2.691,0,0,0,116.1,103.423Z",fill:n}),R.jsx("path",{d:"M110.822,106.454a2.647,2.647,0,0,0,.487-3.695L83.553,66.586A2.636,2.636,0,0,0,79.371,69.8l27.756,36.173A2.691,2.691,0,0,0,110.822,106.454Z",fill:n}),R.jsx("path",{d:"M106.511,110.748a2.648,2.648,0,0,0-.486-3.7L69.852,79.3a2.636,2.636,0,0,0-3.208,4.182l36.172,27.756A2.69,2.69,0,0,0,106.511,110.748Z",fill:n}),R.jsx("path",{d:"M103.458,116.011a2.648,2.648,0,0,0-1.426-3.444L59.908,95.119a2.636,2.636,0,0,0-2.017,4.87l42.124,17.448A2.689,2.689,0,0,0,103.458,116.011Z",fill:n}),R.jsx("path",{d:"M101.872,121.885a2.647,2.647,0,0,0-2.269-2.957l-45.2-5.952a2.636,2.636,0,0,0-.688,5.226l45.2,5.952A2.691,2.691,0,0,0,101.872,121.885Z",fill:n}),R.jsx("path",{d:"M101.86,127.969A2.647,2.647,0,0,0,98.9,125.7L53.7,131.651a2.636,2.636,0,0,0,.688,5.226l45.2-5.951A2.691,2.691,0,0,0,101.86,127.969Z",fill:n}),R.jsx("path",{d:"M128.062,101.872a2.647,2.647,0,0,0,2.957-2.269l5.951-45.2a2.636,2.636,0,0,0-5.226-.688l-5.951,45.2A2.691,2.691,0,0,0,128.062,101.872Z",fill:n})]})})})})},_S="#ea7603",rX="#fff8f1",{currentConference:iX,registrationDeadline:wS,papersDeadline:bS,postersDeadline:ES,conferenceDate:xS,dateFmt:ns}=Gn,TS={name:"You are here",description:"",date:ve(),dateFmt:ns,icon:R.jsx(dq,{})},sX=()=>{const t=ve(),e=[{name:`Registration deadline - ${wS.format(ns)}`,description:"Submit your registration form before this date if you want to participate in the conference.",date:wS,dateFmt:ns,icon:R.jsx(tX,{})},{name:`Papers deadline - ${bS.format(ns)}`,description:"Submit your paper before this date.",date:bS,dateFmt:ns,icon:R.jsx(yS,{})},{name:`Posters deadline - ${ES.format(ns)}`,description:"Submit your poster before this date.",date:ES,dateFmt:ns,icon:R.jsx(yS,{})},{name:`Conference - ${xS.format(ns)}`,description:R.jsxs(R.Fragment,{children:[R.jsx("p",{children:"The conference will take place on this date."}),R.jsx("p",{children:"Please arrive few minutes earlier and wear formal attire."}),R.jsxs("p",{children:[R.jsx("span",{className:"font-bold",children:"Location:"}),R.jsx("div",{children:"Building A, Faculty of Mechatronics, Informatics and Interdisciplinary Studies"}),R.jsxs("div",{children:[R.jsx("span",{className:"font-bold",children:"Room:"})," 3rd floor, room A310"]})]})]}),date:xS,dateFmt:ns,icon:R.jsx(nX,{fill:"black"}),iconClassName:"xl"}],n=e.findIndex(r=>TS.date.isBefore(r.date));return e.splice(n,0,TS),R.jsxs("div",{children:[R.jsxs("h1",{className:"text-2xl",children:["Timeline for SKFM ",iX]}),R.jsx("div",{className:"bg-black/5 p-4 rounded-lg mb-4",children:R.jsx(vS.VerticalTimeline,{lineColor:_S,children:e.map(r=>{const i=t.isAfter(r.date),s=i?"white":rX,o=i?"#666":_S;return R.jsx(vS.VerticalTimelineElement,{className:"vertical-timeline-element",contentStyle:{background:s,border:`2px solid ${o}`,color:i?"#333":"#000"},contentArrowStyle:{borderRight:`7px solid ${o}`},date:r.description?r.date.format(r.dateFmt):"",iconStyle:{background:"white",color:"#000"},icon:r.icon,iconClassName:js(r.iconClassName,"border-2 border-[#ea7603]"),children:R.jsxs("div",{children:[R.jsx("h3",{className:"vertical-timeline-element-title",children:r.name}),!!r.description&&R.jsx(R.Fragment,{children:R.jsx("span",{className:"text-xs font-bold",children:r.date.from(t)})})]})},r.name)})})})]})},oX="/imgs/logo-white.svg",aX=()=>{const{isAdmin:t}=qi(),{year:e}=Pr(),[n,r]=H.useState(!1),[i,s]=H.useState(""),o=ui(Ql,e),a=ta({queryKey:["conference",e],queryFn:async()=>(await Lp(o)).data()});if(a.isFetched&&!a.data)return R.jsx("div",{children:"Conference not found"});if(a.isLoading)return R.jsx("div",{children:"Loading..."});const l=a.data,u=Ts(l.year);return R.jsxs("div",{className:"flex flex-col gap-1",children:[R.jsx("h1",{className:"text-5xl",children:l.name}),R.jsxs("h2",{className:"text-2xl",children:["Student Conference of Faculty of Mechatronics, Informatics and Interdisciplinary Studies ",e]}),u!=="over"&&R.jsx(Tw,{conference:l}),n?R.jsxs(R.Fragment,{children:[R.jsx(fC,{theme:"snow",value:i,onChange:s}),R.jsxs("div",{className:"flex gap-2",children:[R.jsx("button",{className:"bg-green-500 text-white px-2 rounded",onClick:async()=>{await Pf(o,{description:i},{merge:!0}),r(!1),await a.refetch()},children:"Save"}),R.jsx("button",{className:"bg-red-500 text-white px-2 rounded",onClick:()=>r(!1),children:"Cancel"})]})]}):R.jsxs("div",{children:[u==="today"&&e===Gn.currentConference.toString()&&R.jsx("div",{className:"flex justify-center p-2 ",children:R.jsxs("div",{className:"bg-orange-500 text-white px-4 py-2 rounded shadow-xl shadow-orange-500/30 relative overflow-hidden hover:shadow-orange-500/50 transition-all hover:px-8 hover:py-4",children:[R.jsx("img",{src:oX,alt:"logo",className:"h-80 w-80 logo-spin absolute -top-36 -left-28 opacity-15 select-none pointer-events-none"}),R.jsx(an,{to:`/conferences/${e}/programme`,className:"",children:"Today is the conference day! Click here to see the program."})]})}),R.jsx("article",{className:"prose max-w-none",children:!!l.description&&R.jsx("p",{dangerouslySetInnerHTML:{__html:l.description}})}),t&&R.jsx("button",{className:"bg-orange-500 text-white px-2 rounded",onClick:()=>{s(l.description??""),r(!0)},children:"Edit"})]}),u==="over"&&R.jsxs("div",{className:"flex gap-2",children:[R.jsx(an,{to:`/conferences/${e}/proceedings`,className:"bg-orange-500 text-white p-2 rounded",children:"Proceedings"}),R.jsx(an,{to:`/conferences/${e}/gallery`,className:"bg-orange-500 text-white p-2 rounded",children:"Gallery"})]}),u!=="over"&&u!=="today"&&R.jsx("div",{className:"mt-4",children:R.jsx(sX,{})})]})};function wC(t){var e,n,r="";if(typeof t=="string"||typeof t=="number")r+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(n=wC(t[e]))&&(r&&(r+=" "),r+=n)}else for(n in t)t[n]&&(r&&(r+=" "),r+=n);return r}function ko(){for(var t,e,n=0,r="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=wC(t))&&(r&&(r+=" "),r+=e);return r}const Uf=t=>typeof t=="number"&&!isNaN(t),Ba=t=>typeof t=="string",Tr=t=>typeof t=="function",Uh=t=>Ba(t)||Tr(t)?t:null,I0=t=>H.isValidElement(t)||Ba(t)||Tr(t)||Uf(t);function lX(t,e,n){n===void 0&&(n=300);const{scrollHeight:r,style:i}=t;requestAnimationFrame(()=>{i.minHeight="initial",i.height=r+"px",i.transition=`all ${n}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(e,n)})})}function gg(t){let{enter:e,exit:n,appendPosition:r=!1,collapse:i=!0,collapseDuration:s=300}=t;return function(o){let{children:a,position:l,preventExitTransition:u,done:c,nodeRef:d,isIn:f,playToast:p}=o;const _=r?`${e}--${l}`:e,y=r?`${n}--${l}
3771`:n,w=H.useRef(0);return H.useLayoutEffect(()=>{const g=d.current,m=_.split(" "),b=v=>{v.target===d.current&&(p(),g.removeEventListener("animationend",b),g.removeEventListener("animationcancel",b),w.current===0&&v.type!=="animationcancel"&&g.classList.remove(...m))};g.classList.add(...m),g.addEventListener("animationend",b),g.addEventListener("animationcancel",b)},[]),H.useEffect(()=>{const g=d.current,m=()=>{g.removeEventListener("animationend",m),i?lX(g,c,s):c()};f||(u?m():(w.current=1,g.className+=` ${y}`,g.addEventListener("animationend",m)))},[f]),Je.createElement(Je.Fragment,null,a)}}function SS(t,e){return t!=null?{content:t.content,containerId:t.props.containerId,id:t.props.toastId,theme:t.props.theme,type:t.props.type,data:t.props.data||{},isLoading:t.props.isLoading,icon:t.props.icon,status:e}:{}}const Kn=new Map;let $f=[];const O0=new Set,uX=t=>O0.forEach(e=>e(t)),bC=()=>Kn.size>0;function EC(t,e){var n;if(e)return!((n=Kn.get(e))==null||!n.isToastActive(t));let r=!1;return Kn.forEach(i=>{i.isToastActive(t)&&(r=!0)}),r}function xC(t,e){I0(t)&&(bC()||$f.push({content:t,options:e}),Kn.forEach(n=>{n.buildToast(t,e)}))}function kS(t,e){Kn.forEach(n=>{e!=null&&e!=null&&e.containerId?(e==null?void 0:e.containerId)===n.id&&n.toggle(t,e==null?void 0:e.id):n.toggle(t,e==null?void 0:e.id)})}function cX(t){const{subscribe:e,getSnapshot:n,setProps:r}=H.useRef(function(s){const o=s.containerId||1;return{subscribe(a){const l=function(c,d,f){let p=1,_=0,y=[],w=[],g=[],m=d;const b=new Map,v=new Set,A=()=>{g=Array.from(b.values()),v.forEach(E=>E())},N=E=>{w=E==null?[]:w.filter(T=>T!==E),A()},x=E=>{const{toastId:T,onOpen:S,updateId:k,children:I}=E.props,P=k==null;E.staleId&&b.delete(E.staleId),b.set(T,E),w=[...w,E.props.toastId].filter(M=>M!==E.staleId),A(),f(SS(E,P?"added":"updated")),P&&Tr(S)&&S(H.isValidElement(I)&&I.props)};return{id:c,props:m,observe:E=>(v.add(E),()=>v.delete(E)),toggle:(E,T)=>{b.forEach(S=>{T!=null&&T!==S.props.toastId||Tr(S.toggle)&&S.toggle(E)})},removeToast:N,toasts:b,clearQueue:()=>{_-=y.length,y=[]},buildToast:(E,T)=>{if((j=>{let{containerId:U,toastId:Y,updateId:W}=j;const F=U?U!==c:c!==1,q=b.has(Y)&&W==null;return F||q})(T))return;const{toastId:S,updateId:k,data:I,staleId:P,delay:M}=T,$=()=>{N(S)},Z=k==null;Z&&_++;const Q={...m,style:m.toastStyle,key:p++,...Object.fromEntries(Object.entries(T).filter(j=>{let[U,Y]=j;return Y!=null})),toastId:S,updateId:k,data:I,closeToast:$,isIn:!1,className:Uh(T.className||m.toastClassName),bodyClassName:Uh(T.bodyClassName||m.bodyClassName),progressClassName:Uh(T.progressClassName||m.progressClassName),autoClose:!T.isLoading&&(K=T.autoClose,B=m.autoClose,K===!1||Uf(K)&&K>0?K:B),deleteToast(){const j=b.get(S),{onClose:U,children:Y}=j.props;Tr(U)&&U(H.isValidElement(Y)&&Y.props),f(SS(j,"removed")),b.delete(S),_--,_<0&&(_=0),y.length>0?x(y.shift()):A()}};var K,B;Q.closeButton=m.closeButton,T.closeButton===!1||I0(T.closeButton)?Q.closeButton=T.closeButton:T.closeButton===!0&&(Q.closeButton=!I0(m.closeButton)||m.closeButton);let V=E;H.isValidElement(E)&&!Ba(E.type)?V=H.cloneElement(E,{closeToast:$,toastProps:Q,data:I}):Tr(E)&&(V=E({closeToast:$,toastProps:Q,data:I}));const D={content:V,props:Q,staleId:P};m.limit&&m.limit>0&&_>m.limit&&Z?y.push(D):Uf(M)?setTimeout(()=>{x(D)},M):x(D)},setProps(E){m=E},setToggle:(E,T)=>{b.get(E).toggle=T},isToastActive:E=>w.some(T=>T===E),getSnapshot:()=>g}}(o,s,uX);Kn.set(o,l);const u=l.observe(a);return $f.forEach(c=>xC(c.content,c.options)),$f=[],()=>{u(),Kn.delete(o)}},setProps(a){var l;(l=Kn.get(o))==null||l.setProps(a)},getSnapshot(){var a;return(a=Kn.get(o))==null?void 0:a.getSnapshot()}}}(t)).current;r(t);const i=H.useSyncExternalStore(e,n,n);return{getToastToRender:function(s){if(!i)return[];const o=new Map;
3771return t.newestOnTop&&i.reverse(),i.forEach(a=>{const{position:l}=a.props;o.has(l)||o.set(l,[]),o.get(l).push(a)}),Array.from(o,a=>s(a[0],a[1]))},isToastActive:EC,count:i==null?void 0:i.length}}function fX(t){const[e,n]=H.useState(!1),[r,i]=H.useState(!1),s=H.useRef(null),o=H.useRef({start:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,didMove:!1}).current,{autoClose:a,pauseOnHover:l,closeToast:u,onClick:c,closeOnClick:d}=t;var f,p;function _(){n(!0)}function y(){n(!1)}function w(b){const v=s.current;o.canDrag&&v&&(o.didMove=!0,e&&y(),o.delta=t.draggableDirection==="x"?b.clientX-o.start:b.clientY-o.start,o.start!==b.clientX&&(o.canCloseOnClick=!1),v.style.transform=`translate3d(${t.draggableDirection==="x"?`${o.delta}px, var(--y)`:`0, calc(${o.delta}px + var(--y))`},0)`,v.style.opacity=""+(1-Math.abs(o.delta/o.removalDistance)))}function g(){document.removeEventListener("pointermove",w),document.removeEventListener("pointerup",g);const b=s.current;if(o.canDrag&&o.didMove&&b){if(o.canDrag=!1,Math.abs(o.delta)>o.removalDistance)return i(!0),t.closeToast(),void t.collapseAll();b.style.transition="transform 0.2s, opacity 0.2s",b.style.removeProperty("transform"),b.style.removeProperty("opacity")}}(p=Kn.get((f={id:t.toastId,containerId:t.containerId,fn:n}).containerId||1))==null||p.setToggle(f.id,f.fn),H.useEffect(()=>{if(t.pauseOnFocusLoss)return document.hasFocus()||y(),window.addEventListener("focus",_),window.addEventListener("blur",y),()=>{window.removeEventListener("focus",_),window.removeEventListener("blur",y)}},[t.pauseOnFocusLoss]);const m={onPointerDown:function(b){if(t.draggable===!0||t.draggable===b.pointerType){o.didMove=!1,document.addEventListener("pointermove",w),document.addEventListener("pointerup",g);const v=s.current;o.canCloseOnClick=!0,o.canDrag=!0,v.style.transition="none",t.draggableDirection==="x"?(o.start=b.clientX,o.removalDistance=v.offsetWidth*(t.draggablePercent/100)):(o.start=b.clientY,o.removalDistance=v.offsetHeight*(t.draggablePercent===80?1.5*t.draggablePercent:t.draggablePercent)/100)}},onPointerUp:function(b){const{top:v,bottom:A,left:N,right:x}=s.current.getBoundingClientRect();b.nativeEvent.type!=="touchend"&&t.pauseOnHover&&b.clientX>=N&&b.clientX<=x&&b.clientY>=v&&b.clientY<=A?y():_()}};return a&&l&&(m.onMouseEnter=y,t.stacked||(m.onMouseLeave=_)),d&&(m.onClick=b=>{c&&c(b),o.canCloseOnClick&&u()}),{playToast:_,pauseToast:y,isRunning:e,preventExitTransition:r,toastRef:s,eventHandlers:m}}function dX(t){let{delay:e,isRunning:n,closeToast:r,type:i="default",hide:s,className:o,style:a,controlledProgress:l,progress:u,rtl:c,isIn:d,theme:f}=t;const p=s||l&&u===0,_={...a,animationDuration:`${e}ms`,animationPlayState:n?"running":"paused"};l&&(_.transform=`scaleX(${u})`);const y=ko("Toastify__progress-bar",l?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${f}`,`Toastify__progress-bar--${i}`,{"Toastify__progress-bar--rtl":c}),w=Tr(o)?o({rtl:c,type:i,defaultClassName:y}):ko(y,o),g={[l&&u>=1?"onTransitionEnd":"onAnimationEnd"]:l&&u<1?null:()=>{d&&r()}};return Je.createElement("div",{className:"Toastify__progress-bar--wrp","data-hidden":p},Je.createElement("div",{className:`Toastify__progress-bar--bg Toastify__progress-bar-theme--${f} Toastify__progress-bar--${i}`}),Je.createElement("div",{role:"progressbar","aria-hidden":p?"true":"false","aria-label":"notification timer",className:w,style:_,...g}))}let hX=1;const TC=()=>""+hX++;function pX(t){return t&&(Ba(t.toastId)||Uf(t.toastId))?t.toastId:TC()}function Jc(t,e){return xC(t,e),e.toastId}function Zp(t,e){return{...e,type:e&&e.type||t,toastId:pX(e)}}function fh(t){return(e,n)=>Jc(e,Zp(t,n))}function nt(t,e){return Jc(t,Zp("default",e))}nt.loading=(t,e)=>Jc(t,Zp("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...e})),nt.promise=function(t,e,n){let r,{pending:i,error:s,success:o}=e;i&&(r=Ba(i)?nt.loading(i,n):nt.loading(i.render,{...n,...i}));const a={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},l=(c,d,f)=>{if(d==null)return void nt.dismiss(r);const p={type:c,...a,...n,data:f},_=Ba(d)?{render:d}:d;return r?nt.update(r,{...p,..._}):nt(_.render,{...p,..._}),f},u=Tr(t)?t():t;return u.then(c=>l("success",o,c)).catch(c=>l("error",s,c)),u},nt.success=fh("success"),nt.info=fh("info"),nt.error=fh("error"),nt.warning=fh("warning"),nt.warn=nt.warning,nt.dark=(t,e)=>Jc(t,Zp("default",{theme:"dark",...e})),nt.dismiss=function(t){(function(e){var n;if(bC()){if(e==null||Ba(n=e)||Uf(n))Kn.forEach(r=>{r.removeToast(e)});else if(e&&("containerId"in e||"id"in e)){const r=Kn.get(e.containerId);r?r.removeToast(e.id):Kn.forEach(i=>
3771{i.removeToast(e.id)})}}else $f=$f.filter(r=>e!=null&&r.options.toastId!==e)})(t)},nt.clearWaitingQueue=function(t){t===void 0&&(t={}),Kn.forEach(e=>{!e.props.limit||t.containerId&&e.id!==t.containerId||e.clearQueue()})},nt.isActive=EC,nt.update=function(t,e){e===void 0&&(e={});const n=((r,i)=>{var s;let{containerId:o}=i;return(s=Kn.get(o||1))==null?void 0:s.toasts.get(r)})(t,e);if(n){const{props:r,content:i}=n,s={delay:100,...r,...e,toastId:e.toastId||t,updateId:TC()};s.toastId!==t&&(s.staleId=t);const o=s.render||i;delete s.render,Jc(o,s)}},nt.done=t=>{nt.update(t,{progress:1})},nt.onChange=function(t){return O0.add(t),()=>{O0.delete(t)}},nt.play=t=>kS(!0,t),nt.pause=t=>kS(!1,t);const mX=typeof window<"u"?H.useLayoutEffect:H.useEffect,dh=t=>{let{theme:e,type:n,isLoading:r,...i}=t;return Je.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:e==="colored"?"currentColor":`var(--toastify-icon-color-${n})`,...i})},Tv={info:function(t){return Je.createElement(dh,{...t},Je.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(t){return Je.createElement(dh,{...t},Je.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(t){return Je.createElement(dh,{...t},Je.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(t){return Je.createElement(dh,{...t},Je.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return Je.createElement("div",{className:"Toastify__spinner"})}},gX=t=>{const{isRunning:e,preventExitTransition:n,toastRef:r,eventHandlers:i,playToast:s}=fX(t),{closeButton:o,children:a,autoClose:l,onClick:u,type:c,hideProgressBar:d,closeToast:f,transition:p,position:_,className:y,style:w,bodyClassName:g,bodyStyle:m,progressClassName:b,progressStyle:v,updateId:A,role:N,progress:x,rtl:E,toastId:T,deleteToast:S,isIn:k,isLoading:I,closeOnClick:P,theme:M}=t,$=ko("Toastify__toast",`Toastify__toast-theme--${M}`,`Toastify__toast--${c}`,{"Toastify__toast--rtl":E},{"Toastify__toast--close-on-click":P}),Z=Tr(y)?y({rtl:E,position:_,type:c,defaultClassName:$}):ko($,y),Q=function(D){let{theme:j,type:U,isLoading:Y,icon:W}=D,F=null;const q={theme:j,type:U};return W===!1||(Tr(W)?F=W({...q,isLoading:Y}):H.isValidElement(W)?F=H.cloneElement(W,q):Y?F=Tv.spinner():(ee=>ee in Tv)(U)&&(F=Tv[U](q))),F}(t),K=!!x||!l,B={closeToast:f,type:c,theme:M};let V=null;return o===!1||(V=Tr(o)?o(B):H.isValidElement(o)?H.cloneElement(o,B):function(D){let{closeToast:j,theme:U,ariaLabel:Y="close"}=D;return Je.createElement("button",{className:`Toastify__close-button Toastify__close-button--${U}`,type:"button",onClick:W=>{W.stopPropagation(),j(W)},"aria-label":Y},Je.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},Je.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}(B)),Je.createElement(p,{isIn:k,done:S,position:_,preventExitTransition:n,nodeRef:r,playToast:s},Je.createElement("div",{id:T,onClick:u,"data-in":k,className:Z,...i,style:w,ref:r},Je.createElement("div",{...k&&{role:N},className:Tr(g)?g({type:c}):ko("Toastify__toast-body",g),style:m},Q!=null&&Je.createElement("div",{className:ko("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter"
3771:!I})},Q),Je.createElement("div",null,a)),V,Je.createElement(dX,{...A&&!K?{key:`pb-${A}`}:{},rtl:E,theme:M,delay:l,isRunning:e,isIn:k,closeToast:f,hide:d,type:c,style:v,className:b,controlledProgress:K,progress:x||0})))},vg=function(t,e){return e===void 0&&(e=!1),{enter:`Toastify--animate Toastify__${t}-enter`,exit:`Toastify--animate Toastify__${t}-exit`,appendPosition:e}},vX=gg(vg("bounce",!0));gg(vg("slide",!0));gg(vg("zoom"));gg(vg("flip"));const yX={position:"top-right",transition:vX,autoClose:5e3,closeButton:!0,pauseOnHover:!0,pauseOnFocusLoss:!0,draggable:"touch",draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};function _X(t){let e={...yX,...t};const n=t.stacked,[r,i]=H.useState(!0),s=H.useRef(null),{getToastToRender:o,isToastActive:a,count:l}=cX(e),{className:u,style:c,rtl:d,containerId:f}=e;function p(y){const w=ko("Toastify__toast-container",`Toastify__toast-container--${y}`,{"Toastify__toast-container--rtl":d});return Tr(u)?u({position:y,rtl:d,defaultClassName:w}):ko(w,Uh(u))}function _(){n&&(i(!0),nt.play())}return mX(()=>{if(n){var y;const w=s.current.querySelectorAll('[data-in="true"]'),g=12,m=(y=e.position)==null?void 0:y.includes("top");let b=0,v=0;Array.from(w).reverse().forEach((A,N)=>{const x=A;x.classList.add("Toastify__toast--stacked"),N>0&&(x.dataset.collapsed=`${r}`),x.dataset.pos||(x.dataset.pos=m?"top":"bot");const E=b*(r?.2:1)+(r?0:g*N);x.style.setProperty("--y",`${m?E:-1*E}px`),x.style.setProperty("--g",`${g}`),x.style.setProperty("--s",""+(1-(r?v:0))),b+=x.offsetHeight,v+=.025})}},[r,l,n]),Je.createElement("div",{ref:s,className:"Toastify",id:f,onMouseEnter:()=>{n&&(i(!1),nt.pause())},onMouseLeave:_},o((y,w)=>{const g=w.length?{...c}:{...c,pointerEvents:"none"};return Je.createElement("div",{className:p(y),style:g,key:`container-${y}`},w.map(m=>{let{content:b,props:v}=m;return Je.createElement(gX,{...v,stacked:n,collapseAll:_,isIn:a(v.toastId,v.containerId),style:v.style,key:`toast-${v.key}`},b)}))}))}function Zu(t){this._maxSize=t,this.clear()}Zu.prototype.clear=function(){this._size=0,this._values=Object.create(null)};Zu.prototype.get=function(t){return this._values[t]};Zu.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var wX=/[^.^\]^[]+|(?=\[\]|\.\.)/g,SC=/^\d+$/,bX=/^\d/,EX=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,xX=/^\s*(['"]?)(.*?)(\1)\s*$/,Cw=512,AS=new Zu(Cw);new Zu(Cw);var IS=new Zu(Cw),za={split:P0,normalizePath:OS,getter:function(t,e){var n=OS(t);return IS.get(t)||IS.set(t,function(i){for(var s=0,o=n.length;s<o;)if(i!=null||!e)i=i[n[s++]];else return;return i})},join:function(t){return t.reduce(function(e,n){return e+(Nw(n)||SC.test(n)?"["+n+"]":(e?".":"")+n)},"")},forEach:function(t,e,n){TX(Array.isArray(t)?t:P0(t),e,n)}};function OS(t){return AS.get(t)||AS.set(t,P0(t).map(function(e){return e.replace(xX,"$2")}))}function P0(t){return t.match(wX)||[""]}function TX(t,e,n){var r=t.length,i,s,o,a;for(s=0;s<r;s++)i=t[s],i&&(AX(i)&&(i='"'+i+'"'),a=Nw(i),o=!a&&/^\d+$/.test(i),e.call(n,i,a,o,s,t))}function Nw(t){return typeof t=="string"&&t&&["'",'"'].indexOf(t.charAt(0))!==-1}function SX(t){return t.match(bX)&&!t.match(SC)}function kX(t){return EX.test(t)}function AX(t){return!Nw(t)&&(SX(t)||kX(t))}const IX=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['â](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['â](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['â](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['â](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,kC=t=>t.match(IX)||[],OX=(t,e)=>kC(t).join(e).toLowerCase(),PX=t=>kC(t).reduce((e,n)=>`${e}${e?n[0].toUpperCase()+n.slice(1).toLowerCase():n.toLowerCase()}`,""),RX=t=>OX(t,"_");var Sv={camelCase:PX,snakeCase:RX},Dw={exports:{}};Dw.exports=function(t){return AC(CX(t),t)};Dw.exports.array=AC;function AC(t,e){var n=t.length,r=new Array(n),i={},s=n,o=NX(e),a=DX(t);for(e.forEach(function(u){if(!a.has(u[0])||!a.has(u[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)i[s]||l(t[s],s,new Set);return r;function l(u,c,d){if(d.has(u)){var f;try{f=", node was:"+JSON.stringify(u)}catch{f=""}throw new Error("Cyclic dependency"+f)}if(!a.has(u))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(u));if(!i[c]){i[c]=!0;var p=o.get(u)||new Set;if(p=Array.from(p),c=p.length){d.add(u);do{var _=p[--c];l(_,a.get(_),d)}while(c);d.delete(u)}r[--n]=u}}}function CX(t){for(var e=new Set,n=0,r=t.length;n<r;n++){var i=t[n];e.add(i[0]),e.add(i[1])}return Array.from(e)}function NX(t){for(var e=new Map,n=0,r=t.length;n<r;n++){var i=t[n];e.has(i[0])||e.set(i[0],new Set),e.has(i[1])||e.set(i[1],new Set),e.get(i[0]).add(i[1])}return e}function DX(t){for(var e=new Map,n=0,r=t.length;n<r;n++)e.set(t[n],n);return e}var MX=Dw.exports;const LX=Ou(MX),jX=Object.prototype.toString,FX=Error.prototype.toString,VX=RegExp.prototype.toString,UX=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",$X=/^Symbol\((.*)\)(.*)$/;function BX(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function PS(t,e=!1){if(t==null||t===!0||t===!1)return""+t;const n=typeof t;if(n==="number")return BX(t);if(n==="string")return e?`"${t}"`:t;if(n==="function")return"[Function "+(t.name||"anonymous")+"]";if(n==="symbol")return UX.call(t).replace($X,"Symbol($1)");const r=jX.call(t).slice(8,-1);return r==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):r==="Error"||t instanceof Error?"["+FX.call(t)+"]":r==="RegExp"?VX.call(t):null}function Ss(t,e){let n=PS(t,e);return n!==null?n:JSON.stringify(t,function(r,i){let s=PS(this[r],e);return s!==null?s:i},2)}function IC(t){return t==null?[]:[].concat(t)}let OC,PC,RC,zX=/\$\{\s*(\w+)\s*\}/g;OC=Symbol.toStringTag;class RS{constructor(e,n,r,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[OC]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=i,this.errors=[],this.inner=[],IC(e).forEach(s=>{if(Wn.isError(s)){this.errors.push(...s.errors);const o=s.inner.length?s.inner:[s];this.inner.push(...o)}else this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}PC=Symbol.hasInstance;RC=Symbol.toStringTag;
vendor: 5,769 bytes, line 3771
3771class Wn extends Error{static formatError(e,n){const r=n.label||n.path||"this";return n=Object.assign({},n,{path:r,originalPath:n.path}),typeof e=="string"?e.replace(zX,(i,s)=>Ss(n[s])):typeof e=="function"?e(n):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,n,r,i,s){const o=new RS(e,n,r,i);if(s)return o;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[RC]="Error",this.name=o.name,this.message=o.message,this.type=o.type,this.value=o.value,this.path=o.path,this.errors=o.errors,this.inner=o.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Wn)}static[PC](e){return RS[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let ki={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:n,originalValue:r})=>{const i=r!=null&&r!==n?` (cast from the value \`${Ss(r,!0)}\`).`:".";return e!=="mixed"?`${t} must be a \`${e}\` type, but the final value was: \`${Ss(n,!0)}\``+i:`${t} must match the configured type. The validated value was: \`${Ss(n,!0)}\``+i}},tr={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},qX={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},R0={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},HX={isValue:"${path} field must be ${value}"},$h={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},Bh={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},WX={notType:t=>{const{path:e,value:n,spec:r}=t,i=r.types.length;if(Array.isArray(n)){if(n.length<i)return`${e} tuple value has too few items, expected a length of ${i} but got ${n.length} for value: \`${Ss(n,!0)}\``;if(n.length>i)return`${e} tuple value has too many items, expected a length of ${i} but got ${n.length} for value: \`${Ss(n,!0)}\``}return Wn.formatError(ki.notType,t)}};Object.assign(Object.create(null),{mixed:ki,string:tr,number:qX,date:R0,object:$h,array:Bh,boolean:HX,tuple:WX});const yg=t=>t&&t.__isYupSchema__;class Xp{static fromOptions(e,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:i,otherwise:s}=n,o=typeof r=="function"?r:(...a)=>a.every(l=>l===r);return new Xp(e,(a,l)=>{var u;let c=o(...a)?i:s;return(u=c==null?void 0:c(l))!=null?u:l})}constructor(e,n){this.fn=void 0,this.refs=e,this.refs=e,this.fn=n}resolve(e,n){let r=this.refs.map(s=>s.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),i=this.fn(r,e,n);if(i===void 0||i===e)return e;if(!yg(i))throw new TypeError("conditions must return a schema object");return i.resolve(n)}}const hh={context:"$",value:"."};class dl{constructor(e,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===hh.context,this.isValue=this.key[0]===hh.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?hh.context:this.isValue?hh.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&za.getter(this.path,!0),this.map=n.map}getValue(e,n,r){let i=this.isContext?r:this.isValue?e:n;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(e,n){return this.getValue(e,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}dl.prototype.__isYupRef=!0;const ka=t=>t==null;function wl(t){function e({value:n,path:r="",options:i,originalValue:s,schema:o},a,l){const{name:u,test:c,params:d,message:f,skipAbsent:p}=t;let{parent:_,context:y,abortEarly:w=o.spec.abortEarly,disableStackTrace:g=o.spec.disableStackTrace}=i;const m={value:n,parent:_,context:y};function b(k={}){const I=CC(Object.assign({value:n,originalValue:s,label:o.spec.label,path:k.path||r,spec:o.spec,disableStackTrace:k.disableStackTrace||g},d,k.params),m),P=new Wn(Wn.formatError(k.message||f,I),n,I.path,k.type||u,I.disableStackTrace);return P.params=I,P}const v=w?a:l;let A={path:r,parent:_,type:u,from:i.from,createError:b,resolve(k){return NC(k,m)},options:i,originalValue:s,schema:o};const N=k=>{Wn.isError(k)?v(k):k?l(null):v(b())},x=k=>{Wn.isError(k)?v(k):a(k)};if(p&&ka(n))return N(!0);let T;
3771try{var S;if(T=c.call(A,n,A),typeof((S=T)==null?void 0:S.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${A.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(T).then(N,x)}}catch(k){x(k);return}N(T)}return e.OPTIONS=t,e}function CC(t,e){if(!t)return t;for(const n of Object.keys(t))t[n]=NC(t[n],e);return t}function NC(t,e){return dl.isRef(t)?t.getValue(e.value,e.parent,e.context):t}function GX(t,e,n,r=n){let i,s,o;return e?(za.forEach(e,(a,l,u)=>{let c=l?a.slice(1,a.length-1):a;t=t.resolve({context:r,parent:i,value:n});let d=t.type==="tuple",f=u?parseInt(c,10):0;if(t.innerType||d){if(d&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(n&&f>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${e}. because there is no value at that index. `);i=n,n=n&&n[f],t=d?t.spec.types[f]:t.innerType}if(!u){if(!t.fields||!t.fields[c])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${o} which is a type: "${t.type}")`);i=n,n=n&&n[c],t=t.fields[c]}s=c,o=l?"["+a+"]":"."+a}),{schema:t,parent:i,parentPath:s}):{parent:i,parentPath:e,schema:t}}class Jp extends Set{describe(){const e=[];for(const n of this.values())e.push(dl.isRef(n)?n.describe():n);return e}resolveAll(e){let n=[];for(const r of this.values())n.push(e(r));return n}clone(){return new Jp(this.values())}merge(e,n){const r=this.clone();return e.forEach(i=>r.add(i)),n.forEach(i=>r.delete(i)),r}}function Vl(t,e=new Map){if(yg(t)||!t||typeof t!="object")return t;if(e.has(t))return e.get(t);let n;if(t instanceof Date)n=new Date(t.getTime()),e.set(t,n);else if(t instanceof RegExp)n=new RegExp(t),e.set(t,n);else if(Array.isArray(t)){n=new Array(t.length),e.set(t,n);for(let r=0;r<t.length;r++)n[r]=Vl(t[r],e)}else if(t instanceof Map){n=new Map,e.set(t,n);for(const[r,i]of t.entries())n.set(r,Vl(i,e))}else if(t instanceof Set){n=new Set,e.set(t,n);for(const r of t)n.add(Vl(r,e))}else if(t instanceof Object){n={},e.set(t,n);for(const[r,i]of Object.entries(t))n[r]=Vl(i,e)}else throw Error(`Unable to clone ${t}`);return n}function KX(t){if(!(t!=null&&t.length))return;const e=[];let n="",r=!1,i=!1;for(let s=0;s<t.length;s++){const o=t[s];if(o==="["&&!i){n&&(e.push(...n.split(".").filter(Boolean)),n=""),r=!0;continue}if(o==="]"&&!i){n&&(/^\d+$/.test(n)?e.push(n):e.push(n.replace(/^"|"$/g,"")),n=""),r=!1;continue}if(o==='"'){i=!i;continue}if(o==="."&&!r&&!i){n&&(e.push(n),n="");continue}n+=o}return n&&e.push(...n.split(".").filter(Boolean)),e}function YX(t,e){const n=e?`${e}.${t.path}`:t.path;return t.errors.map(r=>({message:r,path:KX(n)}))}function DC(t,e){var n;if(!((n=t.inner)!=null&&n.length)&&t.errors.length)return YX(t,e);const r=e?`${e}.${t.path}`:t.path;return t.inner.flatMap(i=>DC(i,r))}class gi{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new Jp,this._blacklist=new Jp,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(ki.notType)}),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},e==null?void 0:e.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const n=Object.create(Object.getPrototypeOf(this));
vendor: 10,557 bytes, lines 3771-3774
3771return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=Vl(Object.assign({},this.spec,e)),n}label(e){let n=this.clone();return n.spec.label=e,n}meta(...e){if(e.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},e[0]),n}withMutation(e){let n=this._mutate;this._mutate=!0;let r=e(this);return this._mutate=n,r}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let n=this,r=e.clone();const i=Object.assign({},n.spec,r.spec);return r.spec=i,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(e._whitelist,e._blacklist),r._blacklist=n._blacklist.merge(e._blacklist,e._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(s=>{e.tests.forEach(o=>{s.test(o.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(e){return e==null?!!(this.spec.nullable&&e===null||this.spec.optional&&e===void 0):this._typeCheck(e)}resolve(e){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((i,s)=>s.resolve(i,e),n),n=n.resolve(e)}return n}resolveOptions(e){var n,r,i,s;return Object.assign({},e,{from:e.from||[],strict:(n=e.strict)!=null?n:this.spec.strict,abortEarly:(r=e.abortEarly)!=null?r:this.spec.abortEarly,recursive:(i=e.recursive)!=null?i:this.spec.recursive,disableStackTrace:(s=e.disableStackTrace)!=null?s:this.spec.disableStackTrace})}cast(e,n={}){let r=this.resolve(Object.assign({},n,{value:e})),i=n.assert==="ignore-optionality",s=r._cast(e,n);if(n.assert!==!1&&!r.isType(s)){if(i&&ka(s))return s;let o=Ss(e),a=Ss(s);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}". 3772 3773attempted value: ${o} 3774`+(a!==o?`result of cast: ${a}`:""))}return s}_cast(e,n){let r=e===void 0?e:this.transforms.reduce((i,s)=>s.call(this,i,e,this,n),e);return r===void 0&&(r=this.getDefault(n)),r}_validate(e,n={},r,i){let{path:s,originalValue:o=e,strict:a=this.spec.strict}=n,l=e;a||(l=this._cast(l,Object.assign({assert:!1},n)));let u=[];for(let c of Object.values(this.internalTests))c&&u.push(c);this.runTests({path:s,value:l,originalValue:o,options:n,tests:u},r,c=>{if(c.length)return i(c,l);this.runTests({path:s,value:l,originalValue:o,options:n,tests:this.tests},r,i)})}runTests(e,n,r){let i=!1,{tests:s,value:o,originalValue:a,path:l,options:u}=e,c=y=>{i||(i=!0,n(y,o))},d=y=>{i||(i=!0,r(y,o))},f=s.length,p=[];if(!f)return d([]);let _={value:o,originalValue:a,path:l,options:u,schema:this};for(let y=0;y<s.length;y++){const w=s[y];w(_,c,function(m){m&&(Array.isArray(m)?p.push(...m):p.push(m)),--f<=0&&d(p)})}}asNestedTest({key:e,index:n,parent:r,parentPath:i,originalParent:s,options:o}){const a=e??n;if(a==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof a=="number";let u=r[a];const c=Object.assign({},o,{strict:!0,parent:r,value:u,originalValue:s[a],key:void 0,[l?"index":"key"]:a,path:l||a.includes(".")?`${i||""}[${l?a:`"${a}"`}]`:(i?`${i}.`:"")+e});return(d,f,p)=>this.resolve(c)._validate(u,c,f,p)}validate(e,n){var r;let i=this.resolve(Object.assign({},n,{value:e})),s=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return new Promise((o,a)=>i._validate(e,n,(l,u)=>{Wn.isError(l)&&(l.value=u),a(l)},(l,u)=>{l.length?a(new Wn(l,u,void 0,void 0,s)):o(u)}))}validateSync(e,n){var r;let i=this.resolve(Object.assign({},n,{value:e})),s,o=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return i._validate(e,Object.assign({},n,{sync:!0}),(a,l)=>{throw Wn.isError(a)&&(a.value=l),a},(a,l)=>{if(a.length)throw new Wn(a,e,void 0,void 0,o);s=l}),s}isValid(e,n){return this.validate(e,n).then(()=>!0,r=>{if(Wn.isError(r))return!1;throw r})}isValidSync(e,n){try{return this.validateSync(e,n),!0}catch(r){if(Wn.isError(r))return!1;throw r}}_getDefault(e){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,e):Vl(n)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,n){const r=this.clone({nullable:e});return r.internalTests.nullable=wl({message:n,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),r}optionality(e,n){const r=this.clone({optional:e});return r.internalTests.optionality=wl({message:n,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(e=ki.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=ki.notNull){return this.nullability(!1,e)}required(e=ki.required){return this.clone().withMutation(n=>n.nonNullable(e).defined(e))}notRequired(){return this.clone().withMutation(e=>e.nullable().optional())}transform(e){let n=this.clone();return n.transforms.push(e),n}test(...e){let n;if(e.length===1?typeof e[0]=="function"?n={test:e[0]}:n=e[0]:e.length===2?n={name:e[0],test:e[1]}:n={name:e[0],message:e[1],test:e[2]},n.message===void 0&&(n.message=ki.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),i=wl(n),s=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(o=>!(o.OPTIONS.name===n.name&&(s||o.OPTIONS.test===i.OPTIONS.test))),r.tests.push(i),r}when(e,n){!Array.isArray(e)&&typeof e!="string"&&(n=e,e=".");let r=this.clone(),i=IC(e).map(s=>new dl(s));return i.forEach(s=>{s.isSibling&&r.deps.push(s.key)}),r.conditions.push(typeof n=="function"?new Xp(i,n):Xp.fromOptions(i,n)),r}typeError(e){let n=this.clone();return n.internalTests.typeError=wl({message:e,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(e,n=ki.oneOf){let r=this.clone();return e.forEach(i=>{r._whitelist.add(i),r._blacklist.delete(i)}),r.internalTests.whiteList=wl({message:n,name:"oneOf",skipAbsent:!0,test(i){let s=this.schema._whitelist,o=s.resolveAll(this.resolve);return o.includes(i)?!0:this.createError({params:{values:Array.from(s).join(", "),resolved:o}})}}),r}notOneOf(e,n=ki.notOneOf){let r=this.clone();return e.forEach(i=>{r._blacklist.add(i),r._whitelist.delete(i)}),r.internalTests.blacklist=wl({message:n,name:"notOneOf",test(i){let s=this.schema._blacklist,o=s.resolveAll(this.resolve);return o.includes(i)?this.createError({params:{values:Array.from(s).join(", "),resolved:o}}):!0}}),r}strip(e=!0){let n=this.clone();return n.spec.strip=e,n}describe(e){const n=(e?this.resolve(e):this).clone(),{label:r,meta:i,optional:s,nullable:o}=n.spec;return{meta:i,label:r,optional:s,nullable:o,default:n.getDefault(e),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.filter((l,u,c)=>c.findIndex(d=>d.OPTIONS.name===l.OPTIONS.name)===u).map(l=>{const u=l.OPTIONS.params&&e?CC(Object.assign({},l.OPTIONS.params),e):l.OPTIONS.params;return{name:l.OPTIONS.name,params:u}})}}get"~standard"(){const e=this;return{version:1,vendor:"yup",async validate(r){try{return{value:await e.validate(r,{abortEarly:!1})}}catch(i){if(i instanceof Wn)return{issues:DC(i)};throw i}}}}}gi.prototype.__isYupSchema__=!0;for(const t of["validate","validateSync"])gi.prototype[`${t}At`]=function(e,n,r={}){const{parent:i,parentPath:s,schema:o}=GX(this,e,n,r.context);return o[t](i&&i[s],Object.assign({},r,{parent:i,path:e}))};for(const t of["equals","is"])gi.prototype[t]=gi.prototype.oneOf;for(const t of["not","nope"])gi.prototype[t]=gi.prototype.notOneOf;const QX=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function ZX(t){const e=C0(t);if(!e)return Date.parse?Date.parse(t):Number.NaN;if(e.z===void 0&&e.plusMinus===void 0)return new Date(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond).valueOf();let n=0;return e.z!=="Z"&&e.plusMinus!==void 0&&(n=e.hourOffset*60+e.minuteOffset,e.plusMinus==="+"&&(n=0-n)),Date.UTC(e.year,e.month,e.day,e.hour,e.minute+n,e.second,e.millisecond)}function C0(t){var e,n;const r=QX.exec(t);return r?{year:Ji(r[1]),month:Ji(r[2],1)-1,day:Ji(r[3],1),hour:Ji(r[4]),minute:Ji(r[5]),second:Ji(r[6]),millisecond:r[7]?Ji(r[7].substring(0,3)):0,precision:(e=(n=r[7])==null?void 0:n.length)!=null?e:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:Ji(r[10]),minuteOffset:Ji(r[11])}:null}function Ji(t,e=0){return Number(t)||e}let XX=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,JX=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,eJ=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,tJ="^\\d{4}-\\d{2}-\\d{2}
3774",nJ="\\d{2}:\\d{2}:\\d{2}",rJ="(([+-]\\d{2}(:?\\d{2})?)|Z)",iJ=new RegExp(`${tJ}T${nJ}(\\.\\d+)?${rJ}$`),sJ=t=>ka(t)||t===t.trim(),oJ={}.toString();function Nr(){return new MC}class MC extends gi{constructor(){super({type:"string",check(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}}),this.withMutation(()=>{this.transform((e,n)=>{if(!this.spec.coerce||this.isType(e)||Array.isArray(e))return e;const r=e!=null&&e.toString?e.toString():e;return r===oJ?e:r})})}required(e){return super.required(e).withMutation(n=>n.test({message:e||ki.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(e=>(e.tests=e.tests.filter(n=>n.OPTIONS.name!=="required"),e))}length(e,n=tr.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(r){return r.length===this.resolve(e)}})}min(e,n=tr.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(r){return r.length>=this.resolve(e)}})}max(e,n=tr.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:e},skipAbsent:!0,test(r){return r.length<=this.resolve(e)}})}matches(e,n){let r=!1,i,s;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:i,name:s}=n:i=n),this.test({name:s||"matches",message:i||tr.matches,params:{regex:e},skipAbsent:!0,test:o=>o===""&&r||o.search(e)!==-1})}email(e=tr.email){return this.matches(XX,{name:"email",message:e,excludeEmptyString:!0})}url(e=tr.url){return this.matches(JX,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=tr.uuid){return this.matches(eJ,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let n="",r,i;return e&&(typeof e=="object"?{message:n="",allowOffset:r=!1,precision:i=void 0}=e:n=e),this.matches(iJ,{name:"datetime",message:n||tr.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||tr.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:s=>{if(!s||r)return!0;const o=C0(s);return o?!!o.z:!1}}).test({name:"datetime_precision",message:n||tr.datetime_precision,params:{precision:i},skipAbsent:!0,test:s=>{if(!s||i==null)return!0;const o=C0(s);return o?o.precision===i:!1}})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=tr.trim){return this.transform(n=>n!=null?n.trim():n).test({message:e,name:"trim",test:sJ})}lowercase(e=tr.lowercase){return this.transform(n=>ka(n)?n:n.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>ka(n)||n===n.toLowerCase()})}uppercase(e=tr.uppercase){return this.transform(n=>ka(n)?n:n.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>ka(n)||n===n.toUpperCase()})}}Nr.prototype=MC.prototype;let aJ=new Date(""),lJ=t=>Object.prototype.toString.call(t)==="[object Date]";class Mw extends gi{constructor(){super({type:"date",check(e){return lJ(e)&&!isNaN(e.getTime())}}),this.withMutation(()=>{this.transform((e,n)=>!this.spec.coerce||this.isType(e)||e===null?e:(e=ZX(e),isNaN(e)?Mw.INVALID_DATE:new Date(e)))})}prepareParam(e,n){let r;if(dl.isRef(e))r=e;else{let i=this.cast(e);if(!this._typeCheck(i))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=i}return r}min(e,n=R0.min){let r=this.prepareParam(e,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(i){return i>=this.resolve(r)}})}max(e,n=R0.max){let r=this.prepareParam(e,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(i){return i<=this.resolve(r)}})}}Mw.INVALID_DATE=aJ;function uJ(t,e=[]){let n=[],r=new Set,i=new Set(e.map(([o,a])=>`${o}-${a}`));function s(o,a){let l=za.split(o)[0];r.add(l),i.has(`${a}-${l}`)||n.push([a,l])}for(const o of Object.keys(t)){let a=t[o];r.add(o),dl.isRef(a)&&a.isSibling?s(a.path,o):yg(a)&&"deps"in a&&a.deps.forEach(l=>s(l,o))}return LX.array(Array.from(r),n).reverse()}function CS(t,e){let n=1/0;return t.some((r,i)=>{var s;if((s=e.path)!=null&&s.includes(r))return n=i,!0}),n}function LC(t){return(e,n)=>CS(t,e)-CS(t,n)}const jC=(t,e,n)=>{if(typeof t!="string")return t;let r=t;try{r=JSON.parse(t)}catch{}return n.isType(r)?r:t};function zh(t){if("fields"in t){const e={};for(const[n,r]of Object.entries(t.fields))e[n]=zh(r);return t.setFields(e)}if(t.type==="array"){const e=t.optional();return e.innerType&&(e.innerType=zh(e.innerType)),e}return t.type==="tuple"?t.optional().clone({types:t.spec.types.map(zh)}):"optional"in t?t.optional():t}const cJ=(t,e)=>{const n=[...za.normalizePath(e)];if(n.length===1)return n[0]in t;let r=n.pop(),i=za.getter(za.join(n),!0)(t);return!!(i&&r in i)};let NS=t=>Object.prototype.toString.call(t)==="[object Object]";function DS(t,e){let n=Object.keys(t.fields);return Object.keys(e).filter(r=>n.indexOf(r)===-1)}const fJ=LC([]);function FC(t){return new VC(t)}class VC extends gi{constructor(e){super({type:"object",check(n){return NS(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=fJ,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{e&&this.shape(e)})}_cast(e,n={}){var r;let i=super._cast(e,n);if(i===void 0)return this.getDefault(n);if(!this._typeCheck(i))return i;let s=this.fields,o=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,a=[].concat(this._nodes,Object.keys(i).filter(d=>!this._nodes.includes(d))),l={},u=Object.assign({}
3774,n,{parent:l,__validating:n.__validating||!1}),c=!1;for(const d of a){let f=s[d],p=d in i,_=i[d];if(f){let y;u.path=(n.path?`${n.path}.`:"")+d,f=f.resolve({value:_,context:n.context,parent:l});let w=f instanceof gi?f.spec:void 0,g=w==null?void 0:w.strict;if(w!=null&&w.strip){c=c||d in i;continue}y=!n.__validating||!g?f.cast(_,u):_,y!==void 0&&(l[d]=y)}else p&&!o&&(l[d]=_);(p!==d in l||l[d]!==_)&&(c=!0)}return c?l:i}_validate(e,n={},r,i){let{from:s=[],originalValue:o=e,recursive:a=this.spec.recursive}=n;n.from=[{schema:this,value:o},...s],n.__validating=!0,n.originalValue=o,super._validate(e,n,r,(l,u)=>{if(!a||!NS(u)){i(l,u);return}o=o||u;let c=[];for(let d of this._nodes){let f=this.fields[d];!f||dl.isRef(f)||c.push(f.asNestedTest({options:n,key:d,parent:u,parentPath:n.path,originalParent:o}))}this.runTests({tests:c,value:u,originalValue:o,options:n},r,d=>{i(d.sort(this._sortErrors).concat(l),u)})})}clone(e){const n=super.clone(e);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(e){let n=super.concat(e),r=n.fields;for(let[i,s]of Object.entries(this.fields)){const o=r[i];r[i]=o===void 0?s:o}return n.withMutation(i=>i.setFields(r,[...this._excludedEdges,...e._excludedEdges]))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var i;const s=this.fields[r];let o=e;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[r]})),n[r]=s&&"getDefault"in s?s.getDefault(o):void 0}),n}setFields(e,n){let r=this.clone();return r.fields=e,r._nodes=uJ(e,n),r._sortErrors=LC(Object.keys(e)),n&&(r._excludedEdges=n),r}shape(e,n=[]){return this.clone().withMutation(r=>{let i=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),i=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,e),i)})}partial(){const e={};for(const[n,r]of Object.entries(this.fields))e[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(e)}deepPartial(){return zh(this)}pick(e){const n={};for(const r of e)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,i])=>e.includes(r)&&e.includes(i)))}omit(e){const n=[];for(const r of Object.keys(this.fields))e.includes(r)||n.push(r);return this.pick(n)}from(e,n,r){let i=za.getter(e,!0);return this.transform(s=>{if(!s)return s;let o=s;return cJ(s,e)&&(o=Object.assign({},s),r||delete o[e],o[n]=i(s)),o})}json(){return this.transform(jC)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||$h.exact,test(n){if(n==null)return!0;const r=DS(this.schema,n);return r.length===0||this.createError({params:{properties:r.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,n=$h.noUnknown){typeof e!="boolean"&&(n=e,e=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(i){if(i==null)return!0;const s=DS(this.schema,i);return!e||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return r.spec.noUnknown=e,r}unknown(e=!0,n=$h.noUnknown){return this.noUnknown(!e,n)}transformKeys(e){return this.transform(n=>{if(!n)return n;const r={};for(const i of Object.keys(n))r[e(i)]=n[i];return r})}camelCase(){return this.transformKeys(Sv.camelCase)}snakeCase(){return this.transformKeys(Sv.snakeCase)}constantCase(){return this.transformKeys(e=>Sv.snakeCase(e).toUpperCase())}describe(e){const n=(e?this.resolve(e):this).clone(),r=super.describe(e);r.fields={};for(const[s,o]of Object.entries(n.fields)){var i;let a=e;(i=a)!=null&&i.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[s]})),r.fields[s]=o.describe(a)}return r}}FC.prototype=VC.prototype;function UC(t){return new $C(t)}class $C extends gi{constructor(e){super({type:"array",spec:{types:e},check(n){return Array.isArray(n)}}),this.innerType=void 0,this.innerType=e}_cast(e,n){const r=super._cast(e,n);if(!this._typeCheck(r)||!this.innerType)return r;let i=!1;const s=r.map((o,a)=>{const l=this.innerType.cast(o,Object.assign({},n,{path:`${n.path||""}[${a}]`,parent:r,originalValue:o,value:o,index:a}));return l!==o&&(i=!0),l});return i?s:r}_validate(e,n={},r,i){var s;let o=this.innerType,a=(s=n.recursive)!=null?s:this.spec.recursive;n.originalValue!=null&&n.originalValue,super._validate(e,n,r,(l,u)=>{var c;if(!a||!o||!this._typeCheck(u)){i(l,u);return}let d=new Array(u.length);for(let p=0;p<u.length;p++){var f;d[p]=o.asNestedTest({options:n,index:p,parent:u,parentPath:n.path,originalParent:(f=n.originalValue)!=null?f:e})}this.runTests({value:u,tests:d,originalValue:(c=n.originalValue)!=null?c:e,options:n},r,p=>i(p.concat(l),u))})}clone(e){const n=super.clone(e);return n.innerType=this.innerType,n}json(){return this.transform(jC)}concat(e){let n=super.concat(e);return n.innerType=this.innerType,e.innerType&&(n.innerType=n.innerType?n.innerType.concat(e.innerType):e.innerType),n}of(e){let n=this.clone();if(!yg(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+Ss(e));return n.innerType=e,n.spec=Object.assign({},n.spec,{types:e}),n}length(e,n=Bh.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(r){return r.length===this.resolve(e)}})}min(e,n){return n=n||Bh.min,this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(r){return r.length>=this.resolve(e)}})}max(e,n){return n=n||Bh.max,this.test({message:n,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(r){return r.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,n)=>this._typeCheck(e)?e:n==null?[]:[].concat(n))}compact(e){let n=e?(r,i,s)=>!e(r,i,s):r=>!!r;return this.transform(r=>r!=null?r.filter(n):r)}describe(e){const n=(e?this.resolve(e):this).clone(),r=super.describe(e);if(n.innerType){var i;let s=e;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[0]})),r.innerType=n.innerType.describe(s)}return r}}UC.prototype=$C.prototype;const BC=[{value:Fr.SGS,label:"Student Grant Competition"},{value:Fr.PHD,label:"Introduction to PhD thesis"},{value:Fr.DP,label:"Master's thesis"},{value:Fr.Dproj,label:"Diploma project"}],dJ=FC({firstName:Nr().required("This field is required").min(2).max(50),middleName:Nr().max(50),lastName:Nr().required("This field is required").min(2).max(50),studentId:Nr().required("This field is required").matches(/^([A-Z]\d{8})$/,"Enter your student ID in the format X12345678"),contactEmail:Nr().email().required("This field is required").matches(/@tul.cz$/,"Specify your university email"),supervisorFullName:Nr().required("This field is required").min(2).max(100),supervisorEmail:Nr().email().required("This field is required"),title:Nr().required("This field is required").min(5).max(200),abstract:Nr().required("This field is required").min(50).max(1e3),keywords:UC(Nr()).required("This field is required").min(3).max(10),type:Nr().oneOf(BC.map(t=>t.value))}),hJ=()=>{const{user:t}=qi(),{year:e}=Pr(),[n,r]=H.useState(null),[i,s]=H.useState({}),o=(n==null?void 0:n.status)!==void 0&&(n==null?void 0:n.status)!==Ye.PENDING,a=ta({queryKey:["articles",e,t==null?void 0:t.uid],queryFn:async()=>{const f=Vu(hi,Ho("conferenceId","==",e),Ho("userId","==",t==null?void 0:t.uid)),y=(await Uu(f)).docs.map(w=>
3774w.data())[0]??{conferenceId:e,userId:t.uid,contactEmail:t.email,type:Fr.SGS};return r(y),y},enabled:!!t&&!!e}),l=f=>({value:n==null?void 0:n[f],propName:f,onChange:p=>r({...n,[f]:p}),errors:i[f]??[],readonly:o});H.useEffect(()=>{n&&dJ.validate(n,{abortEarly:!1}).then(()=>s({})).catch(f=>s(f.inner.reduce((p,_)=>({...p,[_.path]:_.errors}),{})))},[n]);const u=Vf({mutationKey:["articles",e,t==null?void 0:t.uid],mutationFn:async()=>{const f={...n};f.id=f.id??`${e}-${t.uid}`,f.createdAt=f.createdAt??Date.now(),f.updatedAt=Date.now(),f.createdEmail=f.createdEmail??t.email,f.userId=t.uid,f.conferenceId=e.toString(),f.status=Ye.PENDING;const p=ui(hi,f.id);try{await Pf(p,f),a.refetch(),nt.success(n!=null&&n.id?"Article updated":"Article registered")}catch(_){console.error(_),nt.error("Failed to update the articlem If the problem persists, contact the support")}}});if(!t)return R.jsx("div",{children:"Not logged in"});if(a.isLoading||n==null)return R.jsx("div",{children:"Loading..."});const c=Ts(e)==="registration-open";if(!c&&!n.id)return R.jsx("div",{children:"You can't register your Paper anymore"});const d=n.id===void 0;return R.jsxs("div",{className:"flex flex-col gap-8",children:[!d&&R.jsx(Tw,{}),c?R.jsxs("h1",{className:"text-4xl",children:[d?"Register":"Update"," your Paper for ",e," Conference"]}):R.jsx("h1",{className:"text-4xl",children:"Your registration"}),R.jsxs("div",{className:"flex flex-col gap-2 p-2 hover:bg-orange-50",children:[R.jsx("h2",{className:"text-xl",children:"About the author"}),R.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-x-6 gap-2",children:[R.jsx(es,{...l("firstName"),label:"First name"}),R.jsx(es,{...l("middleName"),label:"Middle name"}),R.jsx(es,{...l("lastName"),label:"Last name"})]}),R.jsx("hr",{className:"my-0 opacity-0"}),R.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-x-6 gap-2",children:[R.jsx(es,{...l("studentId"),label:"Student ID",description:"in the format X12345678"}),R.jsx(es,{...l("contactEmail"),label:"Contact email",description:"@tul.cz"})]})]}),R.jsxs("div",{className:"flex flex-col gap-2 p-2 hover:bg-orange-50",children:[R.jsx("h2",{className:"text-xl",children:"About the Paper"}),R.jsx(es,{...l("title"),label:"Title"}),R.jsx(pJ,{...l("abstract"),label:"Abstract",description:"provide a brief summary of your article in 50-100 words"}),R.jsx(es,{...l("keywords"),label:"Keywords",description:"comma-separated",transform:mJ}),R.jsx(gJ,{...l("type"),label:"Category",description:"participant's category",options:BC})]}),R.jsxs("div",{className:"flex flex-col gap-2 p-2 hover:bg-orange-50",children:[R.jsx("h2",{className:"text-xl",children:n.type===Fr.SGS?"SGS Project Leader":"About the Supervisor"}),R.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-x-6 gap-2",children:[R.jsx(es,{...l("supervisorFullName"),label:"Full name",description:"no titles or degrees"}),R.jsx(es,{...l("supervisorEmail"),label:"Email"})]})]}),!o&&c&&R.jsxs("button",{className:"bg-orange-500 text-white px-4 py-2 rounded disabled:bg-gray-300",onClick:()=>u.mutate(),disabled:u.isPending||Object.keys(i).length>0,children:[d?"Register":"Update"," Paper"]})]})},es=({label:t,value:e,propName:n,className:r,description:i,transform:s,readonly:o,errors:a,onChange:l})=>{const u=`field-${n}`;return R.jsxs("div",{className:`grid grid-cols-2 items-center gap-8 hover:bg-orange-100 p-1 ${r}`,children:[R.jsxs("label",{htmlFor:u,className:"text-left p-1 flex flex-col",children:[t,i&&R.jsxs("span",{className:"text-gray-600 text-xs",children:[" (",i,")"]}),a.map(c=>R.jsx("span",{className:"text-red-600 text-xs",children:c},c))]}),R.jsx("input",{id:u,type:"text",name:n,disabled:o,value:(s==null?void 0:s.to(e))??e??"",onChange:c=>l((s==null?void 0:s.from(c.target.value))??c.target.value),className:"border border-gray-300 rounded p-2 outline-none focus:border-orange-500"})]})},pJ=({label:t,value:e,propName:n,className:r,description:i,readonly:s,errors:o,onChange:a})=>{const l=`field-${n}`;return R.jsxs("div",{className:`grid grid-cols-2 items-center gap-8 hover:bg-orange-100 p-1 ${r}`,children:[R.jsxs("label",{htmlFor:l,className:"text-left p-1 flex flex-col",children:[t,i&&R.jsxs("span",{className:"text-gray-600 text-xs",children:[" (",i,")"]}),o.map(u=>R.jsx("span",{className:"text-red-600 text-xs",children:u},u))]}),R.jsx("textarea",{id:l,name:n,disabled:s,value:e??"",onChange:u=>a(u.target.value),className:"border border-gray-300 rounded p-2 outline-none focus:border-orange-500 resize-none text-sm",rows:3})]})},mJ={from:t=>(t??"").split(",").map(e=>e.trim()),to:t=>(t??[]).join(", ")},gJ=({label:t,value:e,propName:n,className:r,description:i,options:s,readonly:o,errors:a,onChange:l})=>{const u=`field-${n}`;return R.jsxs("div",{className:`grid grid-cols-2 items-center gap-8 hover:bg-orange-100 p-1 ${r}`,children:[R.jsxs("label",{htmlFor:u,className:"text-left p-1 flex flex-col",children:[t,i&&R.jsxs("span",{className:"text-gray-600 text-xs",children:[" (",i,")"]}),a.map(c=>R.jsx("span",{className:"text-red-600 text-xs",children:c},c))]}),R.jsx("select",{id:u,name:n,disabled:o,value:e??"",onChange:c=>l(c.target.value),className:"border border-gray-300 rounded p-2 outline-none focus:border-orange-500",children:s.map(c=>R.jsx("option",{value:c.value,children:c.label},c.value))})]})},vJ
vendor: 41,168 bytes, line 3774
3774=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function
vendor: 16,913 bytes, lines 3774-3778
3774Iu(t,e,n){const r=yJ(t),{webkitRelativePath:i}=t,s=typeof e=="string"?e:typeof i=="string"&&i.length>0?i:`./${t.name}`;return typeof r.path!="string"&&MS(r,"path",s),MS(r,"relativePath",s),r}function yJ(t){const{name:e}=t;if(e&&e.lastIndexOf(".")!==-1&&!t.type){const r=e.split(".").pop().toLowerCase(),i=vJ.get(r);i&&Object.defineProperty(t,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return t}function MS(t,e,n){Object.defineProperty(t,e,{value:n,writable:!1,configurable:!1,enumerable:!0})}const _J=[".DS_Store","Thumbs.db"];function wJ(t){return ll(this,void 0,void 0,function*(){return em(t)&&bJ(t.dataTransfer)?SJ(t.dataTransfer,t.type):EJ(t)?xJ(t):Array.isArray(t)&&t.every(e=>"getFile"in e&&typeof e.getFile=="function")?TJ(t):[]})}function bJ(t){return em(t)}function EJ(t){return em(t)&&em(t.target)}function em(t){return typeof t=="object"&&t!==null}function xJ(t){return N0(t.target.files).map(e=>Iu(e))}function TJ(t){return ll(this,void 0,void 0,function*(){return(yield Promise.all(t.map(n=>n.getFile()))).map(n=>Iu(n))})}function SJ(t,e){return ll(this,void 0,void 0,function*(){if(t.items){const n=N0(t.items).filter(i=>i.kind==="file");if(e!=="drop")return n;const r=yield Promise.all(n.map(kJ));return LS(zC(r))}return LS(N0(t.files).map(n=>Iu(n)))})}function LS(t){return t.filter(e=>_J.indexOf(e.name)===-1)}function N0(t){if(t===null)return[];const e=[];for(let n=0;n<t.length;n++){const r=t[n];e.push(r)}return e}function kJ(t){if(typeof t.webkitGetAsEntry!="function")return jS(t);const e=t.webkitGetAsEntry();return e&&e.isDirectory?qC(e):jS(t,e)}function zC(t){return t.reduce((e,n)=>[...e,...Array.isArray(n)?zC(n):[n]],[])}function jS(t,e){return ll(this,void 0,void 0,function*(){var n;if(globalThis.isSecureContext&&typeof t.getAsFileSystemHandle=="function"){const s=yield t.getAsFileSystemHandle();if(s===null)throw new Error(`${t} is not a File`);if(s!==void 0){const o=yield s.getFile();return o.handle=s,Iu(o)}}const r=t.getAsFile();if(!r)throw new Error(`${t} is not a File`);return Iu(r,(n=e==null?void 0:e.fullPath)!==null&&n!==void 0?n:void 0)})}function AJ(t){return ll(this,void 0,void 0,function*(){return t.isDirectory?qC(t):IJ(t)})}function qC(t){const e=t.createReader();return new Promise((n,r)=>{const i=[];function s(){e.readEntries(o=>ll(this,void 0,void 0,function*(){if(o.length){const a=Promise.all(o.map(AJ));i.push(a),s()}else try{const a=yield Promise.all(i);n(a)}catch(a){r(a)}}),o=>{r(o)})}s()})}function IJ(t){return ll(this,void 0,void 0,function*(){return new Promise((e,n)=>{t.file(r=>{const i=Iu(r,t.fullPath);e(i)},r=>{n(r)})})})}var kv=function(t,e){if(t&&e){var n=Array.isArray(e)?e:e.split(",");if(n.length===0)return!0;var r=t.name||"",i=(t.type||"").toLowerCase(),s=i.replace(/\/.*$/,"");return n.some(function(o){var a=o.trim().toLowerCase();return a.charAt(0)==="."?r.toLowerCase().endsWith(a):a.endsWith("/*")?s===a.replace(/\/.*$/,""):i===a})}return!0};function FS(t){return RJ(t)||PJ(t)||WC(t)||OJ()}function OJ(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 3775In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function PJ(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function RJ(t){if(Array.isArray(t))return D0(t)}function VS(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function US(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?VS(Object(n),!0).forEach(function(r){HC(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):VS(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function HC(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Bf(t,e){return DJ(t)||NJ(t,e)||WC(t,e)||CJ()}function CJ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 3776In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function WC(t,e){if(t){if(typeof t=="string")return D0(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return D0(t,e)}}function D0(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function NJ(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r=[],i=!0,s=!1,o,a;try{for(n=n.call(t);!(i=(o=n.next()).done)&&(r.push(o.value),!(e&&r.length===e));i=!0);}catch(l){s=!0,a=l}finally{try{!i&&n.return!=null&&n.return()}finally{if(s)throw a}}return r}}function DJ(t){if(Array.isArray(t))return t}var MJ=typeof kv=="function"?kv:kv.default,LJ="file-invalid-type",jJ="file-too-large",FJ="file-too-small",VJ="too-many-files",UJ=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=e.split(","),r=n.length>1?"one of ".concat(n.join(", ")):n[0];return{code:LJ,message:"File type must be ".concat(r)}},$S=function(e){return{code:jJ,message:"File is larger than ".concat(e," ").concat(e===1?"byte":"bytes")}},BS=function(e){return{code:FJ,message:"File is smaller than ".concat(e," ").concat(e===1?"byte":"bytes")}},$J={code:VJ,message:"Too many files"};function BJ(t){return t.type===""&&typeof t.getAsFile=="function"}function GC(t,e){var n=t.type==="application/x-moz-file"||MJ(t,e)||BJ(t);return[n,n?null:UJ(e)]}function KC(t,e,n){if(ga(t.size))if(ga(e)&&ga(n)){if(t.size>n)return[!1,$S(n)];if(t.size<e)return[!1,BS(e)]}else{if(ga(e)&&t.size<e)return[!1,BS(e)];if(ga(n)&&t.size>n)return[!1,$S(n)]}return[!0,null]}function ga(t){return t!=null}function zJ(t){var e=t.files,n=t.accept,r=t.minSize,i=t.maxSize,s=t.multiple,o=t.maxFiles,a=t.validator;return!s&&e.length>1||s&&o>=1&&e.length>o?!1:e.every(function(l){var u=GC(l,n),c=Bf(u,1),d=c[0],f=KC(l,r,i),p=Bf(f,1),_=p[0],y=a?a(l):null;return d&&_&&!y})}function tm(t){return typeof t.isPropagationStopped=="function"?t.isPropagationStopped():typeof t.cancelBubble<"u"?t.cancelBubble:!1}function Tc(t){return t.dataTransfer?Array.prototype.some.call(t.dataTransfer.types,function(e){return e==="Files"||e==="application/x-moz-file"}):!!t.target&&!!t.target.files}function zS(t){t.preventDefault()}function qJ(t){return t.indexOf("MSIE")!==-1||t.indexOf("Trident/")!==-1}function HJ(t){return t.indexOf("Edge/")!==-1}function WJ(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return qJ(t)||HJ(t)}function Ti(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(r){for(var i=arguments.length,s=new Array(i>1?i-1:0),o=1;o<i;o++)s[o-1]=arguments[o];return e.some(function(a){return!tm(r)&&a&&a.apply(void 0,[r].concat(s)),tm(r)})}}function GJ(){return"showOpenFilePicker"in window}function KJ(t){if(ga(t)){var e=Object.entries(t).filter(function(n){var r=Bf(n,2),i=r[0],s=r[1],o=!0;return YC(i)||(console.warn('Skipped "'.concat(i,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),(!Array.isArray(s)||!s.every(QC))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),o=!1),o}).reduce(function(n,r){var i=Bf(r,2),s=i[0],o=i[1];return US(US({},n),{},HC({},s,o))},{});return[{description:"Files",accept:e}]}return t}function YJ(t){if(ga(t))return Object.entries(t).reduce(function(e,n){var r=Bf(n,2),i=r[0],s=r[1];return[].concat(FS(e),[i],FS(s))},[]).filter(function(e){return YC(e)||QC(e)}).join(",")}function QJ(t){return t instanceof DOMException&&(t.name==="AbortError"||t.code===t.ABORT_ERR)}function ZJ(t){return t instanceof DOMException&&(t.name==="SecurityError"||t.code===t.SECURITY_ERR)}function YC(t){return t==="audio/*"||t==="video/*"||t==="image/*"||t==="text/*"||t==="application/*"||/\w+\/[-+.\w]+/g.test(t)}function QC(t){return/^.*\.[\w]+$/.test(t)}var XJ=["children"],JJ=["open"],eee=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],tee=["refKey","onChange","onClick"];function qS(t){return iee(t)||ree(t)||ZC(t)||nee()}function nee(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 3777In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ree(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function iee(t){if(Array.isArray(t))return M0(t)}function Av(t,e){return aee(t)||oee(t,e)||ZC(t,e)||see()}function see(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 3778In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ZC(t,e){if(t){if(typeof t=="string")return M0(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return M0(t,e)}}function M0(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function oee(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r=[],i=!0,s=!1,o,a;try{for(n=n.call(t);!(i=(o=n.next()).done)&&(r.push(o.value),!(e&&r.length===e));i=!0);}catch(l){s=!0,a=l}finally{try{!i&&n.return!=null&&n.return()}finally{if(s)throw a}}return r}}function aee(t){if(Array.isArray(t))return t}function HS(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Mt(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?HS(Object(n),!0).forEach(function(r){L0(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):HS(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function L0(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function nm(t,e){if(t==null)return{};var n=lee(t,e),r,i;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(i=0;i<s.length;i++)r=s[i],!(e.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(t,r)&&(n[r]=t[r])}return n}function lee(t,e){if(t==null)return{};var n={},r=Object.keys(t),i,s;for(s=0;s<r.length;s++)i=r[s],!(e.indexOf(i)>=0)&&(n[i]=t[i]);return n}var Lw=H.forwardRef(function(t,e){var n=t.children,r=nm(t,XJ),i=jw(r),s=i.open,o=nm(i,JJ);return H.useImperativeHandle(e,function(){return{open:s}},[s]),Je.createElement(H.Fragment,null,n(Mt(Mt({},o),{},{open:s})))});Lw.displayName="Dropzone";var XC={disabled:!1,getFilesFromEvent:wJ,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};Lw.defaultProps=XC;Lw.propTypes={children:St.func,accept:St.objectOf(St.arrayOf(St.string)),multiple:St.bool,preventDropOnDocument:St.bool,noClick:St.bool,noKeyboard:St.bool,noDrag:St.bool,noDragEventsBubbling:St.bool,minSize:St.number,maxSize:St.number,maxFiles:St.number,disabled:St.bool,getFilesFromEvent:St.func,onFileDialogCancel:St.func,onFileDialogOpen:St.func,useFsAccessApi:St.bool,autoFocus:St.bool,onDragEnter:St.func,onDragLeave:St.func,onDragOver:St.func,onDrop:St.func,onDropAccepted:St.func,onDropRejected:St.func,onError:St.func,validator:St.func};var j0={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,isDragGlobal:!1,acceptedFiles:[],fileRejections:[]};function jw(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=Mt(Mt({},XC),t),n=e.accept,r=e.disabled,i=e.getFilesFromEvent,s=e.maxSize,o=e.minSize,a=e.multiple,l=e.maxFiles,u=e.onDragEnter,c=e.onDragLeave,d=e.onDragOver,f=e.onDrop,p=e.onDropAccepted,_=e.onDropRejected,y=e.onFileDialogCancel,w=e.onFileDialogOpen,g=e.useFsAccessApi,m=e.autoFocus,b=e.preventDropOnDocument,v=e.noClick,A=e.noKeyboard,N=e.noDrag,x=e.noDragEventsBubbling,E=e.onError,T=e.validator,S=H.useMemo(function(){return YJ(n)},[n]),k=H.useMemo(function(){return KJ(n)},[n]),I=H.useMemo(function(){return typeof w=="function"?w:WS},[w]),P=H.useMemo(function(){return typeof y=="function"?y:WS},[y]),M=H.useRef(null),$=H.useRef(null),Z=H.useReducer(uee,j0),Q=Av(Z,2),K=Q[0],B=Q[1],V=K.isFocused,D=K.isFileDialogActive,j=H.useRef(typeof window<"u"&&window.isSecureContext&&g&&GJ()),U=function(){!j.current&&D&&setTimeout(function(){if($.current){var me=$.current.files;me.length||(B({type:"closeDialog"}),P())}},300)};H.useEffect(function(){return window.addEventListener("focus",U,!1),function(){window.removeEventListener("focus",U,!1)}},[$,D,P,j]);var Y=H.useRef([]),W=H.useRef([]),F=function(me){M.current&&M.current.contains(me.target)||(me.preventDefault(),Y.current=[])};H.useEffect(function(){return b&&(document.addEventListener("dragover",zS,!1),document.addEventListener("drop",F,!1)),function(){b&&(document.removeEventListener("dragover",zS),document.removeEventListener("drop",F))}},[M,b]),H.useEffect(function(){var oe=function(Xe){W.current=[].concat(qS(W.current),[Xe.target]),Tc(Xe)&&B({isDragGlobal:!0,type:"setDragGlobal"})},me=function(Xe){W.current=W.current.filter(function(Pt){return Pt!==Xe.target&&Pt!==null}),!(W.current.length>0)&&B({isDragGlobal:!1,type:"setDragGlobal"})},je=function(){W.current=[],B({isDragGlobal:!1,type:"setDragGlobal"})},Ne=function(){W.current=[],B({isDragGlobal:!1,type:"setDragGlobal"})};return document.addEventListener("dragenter",oe,!1),document.addEventListener("dragleave",me,!1),document.addEventListener("dragend",je,!1),document.addEventListener("drop",Ne,!1),function(){document.removeEventListener("dragenter",oe),document.removeEventListener("dragleave",me),document.removeEventListener("dragend",je),document.removeEventListener("drop",Ne)}},[M]),H.useEffect(function(){return!r&&m&&M.current&&M.current.focus(),function(){}},[M,m,r]);var q=H.useCallback(function(oe){E?E(oe):console.error(oe)},[E]),ee=H.useCallback(function(oe){oe.preventDefault(),oe.persist(),ye(oe),Y.current=[].concat(qS(Y.current),[oe.target]),Tc(oe)&&Promise.resolve(i(oe)).then(function(me){if(!(tm(oe)&&!x)){var je=me.length,Ne=je>0&&zJ({files:me,accept:S,minSize:o,maxSize:s,multiple:a,maxFiles:l,validator:T}),dt=je>0&&!Ne;B({isDragAccept:Ne,isDragReject:dt,isDragActive:!0,type:"setDraggedFiles"}),u&&u(oe)}}).catch(function(me){return q(me)})},[i,u,q,x,S,o,s,a,l,T]),te=H.useCallback(function(oe){oe.preventDefault(),oe.persist(),ye(oe);var me=Tc(oe);if(me&&oe.dataTransfer)try{oe.dataTransfer.dropEffect="copy"}catch{}return me&&d&&d(oe),!1},[d,x]),ae=H.useCallback(function(oe){oe.preventDefault(),oe.persist(),ye(oe);var me=Y.current.filter(function(Ne){return M.current&&M.current.contains(Ne)}),je=me.indexOf(oe.target);je!==-1&&me.splice(je,1),Y.current=me,!(me.length>0)&&(B({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Tc(oe)&&c&&c(oe))},[M,c,x]),_e=H.useCallback(function(oe,me){var je=[],Ne=[];oe.forEach(function(dt){var Xe=GC(dt,S),Pt=Av(Xe,2),Gr=Pt[0],Un=Pt[1],Hi=KC(dt,o,s),Kr=Av(Hi,2),Bs=Kr[0],na=Kr[1],yi=T?T(dt):null;if(Gr&&Bs&&!yi)je.push(dt);else{var Yr=[Un,na];yi&&(Yr=Yr.concat(yi)),Ne.push({file:dt,errors:Yr.filter(function(ra){return ra})})}}),(!a&&je.length>1||a&&l>=1&&je.length>l)&&(je.forEach(function(dt){Ne.push({file:dt,errors:[$J]})}),je.splice(0)),B({acceptedFiles:je,fileRejections:Ne,isDragReject:Ne.length>0,type:"setFiles"}),f&&f(je,Ne,me),Ne.length>0&&_&&_(Ne,me),je.length>0&&p&&p(je,me)},[B,a,S,o,s,l,f,p,_,T]),Ee=H.useCallback(function(oe){oe.preventDefault(),oe.persist(),ye(oe),Y.current=[],Tc(oe)&&Promise.resolve(i(oe)).then(function(me){tm(oe)&&!x||_e(me,oe)}).catch(function(me){return q(me)}),B({type:"reset"})},[i,_e,q,x]),Ce=H.useCallback(function(){if(j.current){B({type:"openDialog"}),I();var oe={multiple:a,types:k};window.showOpenFilePicker(oe).then(function(me){return i(me)}).then(function(me){_e(me,null),B({type:"closeDialog"})}).catch(function(me){QJ(me)?(P(me),B({type:"closeDialog"})):ZJ(me)?(j.current=!1,$.current?($.current.value=null,$.current.click()):q(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):q(me)});return}$.current&&(B({type:"openDialog"}),I(),$.current.value=null,$.current.click())}
3778,[B,I,P,g,_e,q,k,a]),qe=H.useCallback(function(oe){!M.current||!M.current.isEqualNode(oe.target)||(oe.key===" "||oe.key==="Enter"||oe.keyCode===32||oe.keyCode===13)&&(oe.preventDefault(),Ce())},[M,Ce]),Ze=H.useCallback(function(){B({type:"focus"})},[]),Et=H.useCallback(function(){B({type:"blur"})},[]),kt=H.useCallback(function(){v||(WJ()?setTimeout(Ce,0):Ce())},[v,Ce]),ie=function(me){return r?null:me},se=function(me){return A?null:ie(me)},pe=function(me){return N?null:ie(me)},ye=function(me){x&&me.stopPropagation()},ue=H.useMemo(function(){return function(){var oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},me=oe.refKey,je=me===void 0?"ref":me,Ne=oe.role,dt=oe.onKeyDown,Xe=oe.onFocus,Pt=oe.onBlur,Gr=oe.onClick,Un=oe.onDragEnter,Hi=oe.onDragOver,Kr=oe.onDragLeave,Bs=oe.onDrop,na=nm(oe,eee);return Mt(Mt(L0({onKeyDown:se(Ti(dt,qe)),onFocus:se(Ti(Xe,Ze)),onBlur:se(Ti(Pt,Et)),onClick:ie(Ti(Gr,kt)),onDragEnter:pe(Ti(Un,ee)),onDragOver:pe(Ti(Hi,te)),onDragLeave:pe(Ti(Kr,ae)),onDrop:pe(Ti(Bs,Ee)),role:typeof Ne=="string"&&Ne!==""?Ne:"presentation"},je,M),!r&&!A?{tabIndex:0}:{}),na)}},[M,qe,Ze,Et,kt,ee,te,ae,Ee,A,N,r]),Ue=H.useCallback(function(oe){oe.stopPropagation()},[]),Fe=H.useMemo(function(){return function(){var oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},me=oe.refKey,je=me===void 0?"ref":me,Ne=oe.onChange,dt=oe.onClick,Xe=nm(oe,tee),Pt=L0({accept:S,multiple:a,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:ie(Ti(Ne,Ee)),onClick:ie(Ti(dt,Ue)),tabIndex:-1},je,$);return Mt(Mt({},Pt),Xe)}},[$,n,a,Ee,r]);return Mt(Mt({},K),{},{isFocused:V&&!r,getRootProps:ue,getInputProps:Fe,rootRef:M,inputRef:$,open:ie(Ce)})}function uee(t,e){switch(e.type){case"focus":return Mt(Mt({},t),{},{isFocused:!0});case"blur":return Mt(Mt({},t),{},{isFocused:!1});case"openDialog":return Mt(Mt({},j0),{},{isFileDialogActive:!0});case"closeDialog":return Mt(Mt({},t),{},{isFileDialogActive:!1});case"setDraggedFiles":return Mt(Mt({},t),{},{isDragActive:e.isDragActive,isDragAccept:e.isDragAccept,isDragReject:e.isDragReject});case"setFiles":return Mt(Mt({},t),{},{acceptedFiles:e.acceptedFiles,fileRejections:e.fileRejections,isDragReject:e.isDragReject});case"setDragGlobal":return Mt(Mt({},t),{},{isDragGlobal:e.isDragGlobal});case"reset":return Mt({},j0);default:return t}}function WS(){}const rm=t=>{const{id:e,name:n,whenEmpty:r}=t;if(!e&&!r)return null;const i=async s=>{const o=await Cf(Wo(Go,s));window.open(o,"_blank")};return R.jsx("div",{className:js("px-2 rounded-sm ring-1",e?"bg-orange-100 ring-orange-700/50 hover:ring-orange-700/100 hover:bg-orange-200":"bg-gray-100 ring-gray-700/50 cursor-not-allowed"),children:e?R.jsx("button",{className:"w-full",onClick:()=>i(e),children:n}):r})},cee=()=>{const{user:t}=qi(),{year:e}=Pr(),n=ta({queryKey:["articles",e,t==null?void 0:t.uid],queryFn:async()=>{const s=Vu(hi,Ho("conferenceId","==",e),Ho("userId","==",t==null?void 0:t.uid));return(await Uu(s)).docs.map(u=>u.data())[0]},enabled:!!t&&!!e});if(!t)return R.jsx("div",{className:"bg-yellow-50 shadow-xl shadow-yellow-600/15 p-2 rounded text-yellow-900",children:"Sign in to upload files"});const r=n.data;if(n.isLoading)return R.jsx("div",{children:"Loading..."});if(!r)return R.jsx("div",{className:"bg-yellow-50 shadow-xl shadow-yellow-600/15 p-2 rounded text-yellow-900",children:"You are not registered for this conference"});const i=Ts(e);return i!=="files-open"&&i!=="registration-open"&&r.status!==Ye.ACTION_REQUIRED?R.jsx("div",{children:"You can't upload files at the moment"}):R.jsxs("div",{className:"flex flex-col gap-4",children:[R.jsx(Tw,{}),R.jsx(fee,{article:r,year:e})]})},fee=({article:t,year:e})=>{const[n,r]=H.useState(null),[i,s]=H.useState(null),o=Ts(e),a=Vf({mutationFn:async()=>{const l=`${KS(t.lastName)}-${KS(t.firstName)}`;if(n)try{const u=`papers/${e}-${l}-paper.pdf`,c=Wo(Go,u);await _T(c,n,{customMetadata:{status:Ye.PENDING,userId:t.userId}});const d=ui(hi,t.id);await Rf(d,{abstractFileId:u,abstractFileName:n.name,updatedAt:Date.now()}),nt.success("Paper uploaded")}catch(u){throw console.error("Error uploading abstract file:",u),nt.error(`Failed to upload paper: ${u instanceof Error?u.message:"Unknown error"}`),u}if(i)try{const u=`posters/${e}-${l}-poster.pdf`,c=Wo(Go,u);await _T(c,i,{customMetadata:{status:Ye.PENDING,userId:t.userId}});const d=ui(hi,t.id);await Rf(d,{posterFileId:u,posterFileName:i.name,updatedAt:Date.now()}),nt.success("Poster uploaded")}catch(u){throw console.error("Error uploading poster file:",u),nt.error(`Failed to upload poster: ${u instanceof Error?u.message:"Unknown error"}`),u}}});return R.jsxs("div",{children:[t.status===Ye.ACTION_REQUIRED&&R.jsx("div",{className:"bg-yellow-50 shadow-xl mb-4 shadow-yellow-600/15 p-2 rounded text-yellow-900",children:o==="files-open"?"Please upload corrected versions of your files":"It's after the deadline, but you have been granted a deadline extension. Please upload corrected versions of your files as soon as possible."}),R.jsx("h1",{className:"text-4xl",children:"Upload files"}),R.jsxs("div",{className:"p-2 grid grid-cols-1 lg:grid-cols-2 gap-x-6 gap-2",children:[R.jsxs("div",{className:"flex flex-col gap-2 p-2",children:[R.jsx("h2",{className:"text-xl",children:"Paper"}),R.jsx(GS,{onDrop:r}),R.jsx(rm,{id:t.abstractFileId,name:t.abstractFileName,whenEmpty:"You haven't uploaded the paper yet"}),n&&R.jsxs("div",{className:"flex gap-1",children:[R.jsx("div",{children:"You will upload:"}),R.jsxs("div",{className:"bg-orange-100 px-2 rounded font-bold",children:[n.name,"
3778(",(n.size/1024).toFixed(2)," KB)"]})]})]}),R.jsx("div",{children:R.jsxs("div",{className:"flex flex-col gap-2 p-2 ",children:[R.jsx("h2",{className:"text-xl",children:"Poster"}),R.jsx(GS,{onDrop:s}),R.jsx(rm,{id:t.posterFileId,name:t.posterFileName,whenEmpty:"You haven't uploaded the poster yet"}),i&&R.jsxs("div",{className:"flex gap-1",children:[R.jsx("div",{children:"You will upload:"}),R.jsxs("div",{className:"bg-orange-100 px-2 rounded font-bold",children:[i.name," (",(i.size/1024).toFixed(2)," KB)"]})]})]})})]}),R.jsx("button",{onClick:()=>a.mutate(),disabled:a.isPending||!n&&!i,className:"bg-orange-500 text-white px-4 py-2 rounded disabled:bg-gray-300 disabled:text-gray-500",children:a.isPending?"Uploading...":"Upload"})]})},GS=({onDrop:t})=>{const{getRootProps:e,getInputProps:n,isDragActive:r}=jw({onDropAccepted:i=>{if(i.length!==1){nt.error("Only one file is accepted");return}t(i[0])},onDropRejected:i=>{nt.error(i.length!==1?"Only one file is accepted":"Only PDF files are accepted")},multiple:!1,accept:{"application/pdf":[".pdf"]}});return R.jsxs("div",{...e(),className:"border border-dashed p-4 rounded",children:[R.jsx("input",{...n()}),r?R.jsx("p",{children:"Drop the files here ..."}):R.jsx("p",{children:"Drag 'n' drop some files here, or click to select files"})]})},dee={a:"áà âä",c:"çÄÄ",d:"Ä",e:"éèêë",i:"Ãìîï",l:"Å",n:"ÅÅ",o:"óòôö",r:"Å",s:"Å¡Å",t:"Å¥",u:"úùûü",y:"ý",z:"žźż"},KS=t=>t.toLowerCase().split("").map(e=>{for(const[n,r]of Object.entries(dee))if(r.includes(e))return n;return e}).join(""),hee=(t,e=100)=>{const n=t||"";return n.length<=e?n:n.substring(0,e)+"..."},YS=t=>{const e=t.contactEmail,n=e.indexOf("@"),r=e.substring(0,n);return r.includes(".")?r.toLowerCase():`${t.lastName}.${t.firstName}`.toLowerCase()},pee=()=>{const{user:t,isAdmin:e}=qi(),{year:n}=Pr(),[r,i]=H.useState([]),[s,o]=H.useState(null),[a,l]=H.useState(null),[u,c]=H.useState("table"),{setSettings:d}=H.useContext(jR),[f,p]=H.useState("updatedAt"),[_,y]=H.useState("desc"),w=T=>{T===f?y(_==="asc"?"desc":"asc"):(p(T),y("desc"))};H.useEffect(()=>(d({fullWidth:!0}),()=>{d({fullWidth:!1})}),[]);const g=ta({queryKey:["articles",n],queryFn:async()=>{const T=Vu(hi,Ho("conferenceId","==",n)),k=(await Uu(T)).docs.map(I=>I.data());return i(k.sort((I,P)=>
3778P.updatedAt-I.updatedAt)),k},enabled:!!t&&!!n}),m=async T=>{const S=await Cf(Wo(Go,T));window.open(S,"_blank")},b=Vf({mutationKey:["articles",n],mutationFn:async T=>{const{articleId:S,status:k}=T,I=ui(hi,S);await Rf(I,{status:k});const P=r.find(M=>M.id===S);P&&(P.status=k,i([...r]))}});if(!t||!e)return R.jsx("div",{children:"Unauthorized"});if(g.isLoading)return R.jsx("div",{children:"Loading..."});const v=()=>{const T=[["Student ID","First Name","Last Name","Email","Supervisor","Supervisor Email","Type","Title","Has Paper","Paper Comments","Has Poster","Poster Comments","Status","Abstract","Updated at","Created at"]],S=r.map(k=>{const I=k.abstractFileId?"Yes":"No",P=k.posterFileId?"Yes":"No";return[k.studentId,k.firstName,k.lastName,k.contactEmail,k.supervisorFullName,k.supervisorEmail,k.type,k.title,I,k.abstractFileComments??"",P,k.posterFileComments??"",k.status,hee(k.abstract),new Date(k.updatedAt).toLocaleString(),new Date(k.createdAt).toLocaleString()]});return T.push(...S),T},A=async()=>{const T=v().map(P=>P.map(M=>`"${M}"`).join(",")).join(` 3779`),S=new Blob([T],{type:"text/csv;charset=utf-8"}),k=URL.createObjectURL(S),I=document.createElement("a");I.href=k,I.download=`articles-${n}.csv`,I.click()},N=async()=>{const T=v().map(S=>S.join(" ")).join(` 3780`);await navigator.clipboard.writeText(T),nt.success("Data copied to clipboard")},x=async T=>{await navigator.clipboard.writeText(T),nt.success("Text copied to clipboard")},E=r.filter(T=>!s||T.status===s).sort((T,S)=>vee(f,_,T,S));return R.jsxs("div",{children:[R.jsxs("div",{className:"text-2xl flex justify-between items-center gap-4",children:[R.jsxs("span",{children:["Manage ",E.length," articles"]}),R.jsxs("div",{className:"flex gap-1",children:[R.jsxs("select",{value:s??"",onChange:T=>o(T.target.value?T.target.value:null),className:"p-1 px-2 text-sm bg-orange-100 text-orange-800 rounded hover:bg-orange-200",children:[R.jsx("option",{value:"",children:"Show All"}),[Ye.PENDING,Ye.ACCEPTED,Ye.REJECTED,Ye.PAPER_OK,Ye.POSTER_OK,Ye.PUBLISHED,Ye.ACTION_REQUIRED].map(T=>R.jsx("option",{value:T,children:T},T))]}),R.jsxs("select",{value:u,onChange:T=>c(T.target.value),className:"p-1 px-2 text-sm bg-orange-100 text-orange-800 rounded hover:bg-orange-200",children:[R.jsx("option",{value:"list",children:"List"}),R.jsx("option",{value:"table",children:"Table"})]}),R.jsx("button",{onClick:A,className:"p-1 px-2 text-sm bg-orange-500 text-white rounded hover:bg-orange-700",children:"Download as CSV"}),R.jsx("button",{onClick:N,className:"p-1 px-2 text-sm bg-orange-500 text-white rounded hover:bg-orange-700",children:"Copy to clipboard"})]})]}),u==="list"&&R.jsx("div",{children:E.map(T=>{const{abstractFileId:S}=T,{posterFileId:k}=T;return R.jsxs("div",{className:"grid grid-cols-[1fr,auto] gap-2 hover:bg-orange-100 p-2 items-center",children:[R.jsxs("div",{children:[R.jsxs("div",{children:[T.title," - ",R.jsx("span",{className:"text-xs text-neutral-600",children:T.abstract})]}),R.jsxs("div",{className:"grid grid-cols-[2fr,1fr,1fr] text-xs",children:[R.jsxs("div",{className:"hover:bg-orange-500/10 p-1",children:[R.jsx("div",{className:"italic block",children:"About the author"}),R.jsxs("div",{children:[T.firstName," ",T.middleName," ",T.lastName," - ",T.contactEmail," (",T.createdEmail,") - ",T.studentId]})]}),R.jsxs("div",{className:"hover:bg-orange-500/10 p-1",children:[R.jsx("div",{className:"italic block",children:"About the supervisor"}),R.jsxs("div",{children:[T.supervisorFullName," - ",T.supervisorEmail]})]}),R.jsxs("div",{className:"hover:bg-orange-500/10 p-1",children:[R.jsx("div",{className:"italic block",children:"About the article"}),R.jsxs("div",{children:[T.type," - ",T.keywords.join(", ")]})]})]})]}),R.jsxs("div",{className:"flex flex-col gap-2 items-end",children:[R.jsxs("div",{className:"flex flex-col gap-2 text-sm items-end ",children:[R.jsxs("div",{className:"flex gap-1",children:[R.jsx(rm,{id:S,name:`${YS(T)}-paper.pdf`,whenEmpty:"No abstract"}),R.jsx("button",{onClick:()=>l({article:T,type:"paper"}),className:"p-1 px-2 text-xs bg-orange-500 text-white rounded hover:bg-orange-700",children:T.abstractFileComments?"Edit note":"Add note"})]}),R.jsxs("div",{className:"flex gap-1",children:[R.jsx(rm,{id:k,name:`${YS(T)}-poster.pdf`,whenEmpty:"No poster"}),R.jsx("button",{onClick:()=>l({article:T,type:"poster"}),className:"p-1 px-2 text-xs bg-orange-500 text-white rounded hover:bg-orange-700",children:T.posterFileComments?"Edit note":"Add note"})]})]}),R.jsx("div",{className:"flex flex-wrap gap-1",children:[Ye.PENDING,Ye.ACCEPTED,Ye.REJECTED,Ye.PAPER_OK,Ye.POSTER_OK,Ye.PUBLISHED,Ye.ACTION_REQUIRED].map(I=>R.jsx("button",{className:`px-2 py-px text-xs rounded ${T.status===I?"bg-blue-500 text-white":"bg-gray-200 text-gray-500"}`,disabled:b.isPending,onClick:()=>{b.mutate({articleId:T.id,status:I})},children:I},I))})]})]},T.id)})}),u==="table"&&R.jsxs("table",{className:"table w-full text-xs",children:[R.jsx("thead",{children:R.jsxs("tr",{children:[R.jsx("th",{onClick:()=>w("studentId"),children:"Student ID"}),R.jsx("th",{onClick:()=>w("lastName"),children:"Full Name"}),R.jsx("th",{onClick:()=>w("supervisorFullName"),children:"Supervisor"}),R.jsx("th",{onClick:()=>w("type"),children:"Type"}),R.jsx("th",{onClick:()=>w("title"),children:"Title"}),R.jsx("th",{onClick:()=>w("abstractFileId"),children:"Has Paper"}),R.jsx("th",{onClick:()=>w("abstractFileComments"),children:"Paper Comments"}),R.jsx("th",{onClick:()=>w("posterFileId"),children:"Has Poster"}),R.jsx("th",{onClick:()=>w("posterFileComments"),children:"Poster Comments"}),R.jsx("th",{onClick:()=>w("status"),children:"Status"}),R.jsx("th",{onClick:()=>w("updatedAt"),children:"Updated at"}),R.jsx("th",{onClick:()=>w("createdAt"),children:"Created at"})]})}),R.jsx("tbody",{children:E.map(T=>{const S=!!T.abstractFileId,k=!!T.posterFileId;return R.jsxs("tr",{children:[R.jsx("td",{children:T.studentId}),R.jsxs("td",{className:"can-copy",onClick:()=>x(T.contactEmail),children:[T.firstName," ",T.middleName," ",T.lastName]}),R.jsx("td",{className:"can-copy",onClick:()=>x(T.supervisorEmail),children:T.supervisorFullName}),R.jsx("td",{children:T.type}),R.jsx("td",{children:T.title}),R.jsx("td",{className:js("text-center",S?"bg-green-500/25":"bg-red-500/25"),children:S?R.jsxs("div",{className:"flex flex-col gap-1 items-center",children:["Yes"," ",R.jsx("button",{onClick:()=>m(T.abstractFileId),className:"p-1 px-2 text-xs bg-green-500/20 rounded hover:bg-green-700 hover:text-white",children:"Download"})]}):"No"}),R.jsxs("td",{className:"max-w-40",children:[R.jsx("small",{className:"mx-2",dangerouslySetInnerHTML:{__html:T.abstractFileComments??""}}),R.jsx("button",{onClick:()=>l({article:T,type:"paper"}),className:"p-1 px-2 text-xs bg-orange-100 rounded hover:bg-orange-200",children:T.abstractFileComments?"Edit note":"Add note"})]}),R.jsx("td",{className:js("text-center",k?"bg-green-500/25":"bg-red-500/25"),children:k?R.jsxs("div",{className:"flex flex-col gap-1 items-center",children:["Yes"," ",R.jsx("button",{onClick:()=>m(T.posterFileId),className:"p-1 px-2 text-xs bg-green-500/20 rounded hover:bg-green-700 hover:text-white",children:"Download"})]}):"No"}),R.jsxs("td",{className:"max-w-40 flex flex-col gap-1 items-center",children:[R.jsx("small",{className:"mx-2",dangerouslySetInnerHTML:{__html:T.posterFileComments??""}}),R.jsx("button",{onClick:()=>l({article:T,type:"poster"}),className:"p-1 px-2 text-xs bg-orange-100 rounded hover:bg-orange-200",children:T.posterFileComments?"Edit note":"Add note"})]}),R.jsx("td",{children:R.jsx("div",{className:"grid grid-cols-3 gap-1",children:Object.entries(JC).map(([I,P])=>R.jsx(mee,{status:I,currentStatus:T.status,twoColumns:I===Ye.ACTION_REQUIRED,onClick:()=>b.mutate({articleId:T.id,status:I})},I))})}),R.jsx("td",{children:R.jsx("span",{title:ve(T.updatedAt).format(),children:ve(T.updatedAt).fromNow()})}),R.jsx("td",{children:R.jsx("span",{title:ve(T.createdAt).format(),children:ve(T.createdAt).fromNow()})})]},T.id)})})]}),a&&R.jsx(gee,{context:a,onClose:()=>l(null)})]})},mee=t=>{const{status:e,currentStatus:n,twoColumns:r,onClick:i}=t;return R.jsx("button",{onClick:i,className:js("p-1 px-2 text-xs rounded",r?"col-span-2":"col-span-1",n===e?JC[e]:"bg-black/5 text-gray-500"),children:e})},JC={[Ye.PENDING]:"bg-yellow-200 text-yellow-900 shadow-yellow-200/50 shadow-xl",[Ye.ACCEPTED]:"bg-green-200 text-green-900 shadow-green-200/50 shadow-xl",[Ye.REJECTED]:"bg-red-200 text-red-900 shadow-red-200/50 shadow-xl",[Ye.PAPER_OK]:"bg-purple-200 text-purple-900 shadow-purple-200/50 shadow-xl",[Ye.POSTER_OK]:"bg-purple-200 text-purple-900 shadow-purple-200/50 shadow-xl",[Ye.PUBLISHED]:"bg-blue-200 text-blue-900 shadow-blue-200/50 shadow-xl",[Ye.ACTION_REQUIRED]:"bg-orange-200 text-orange-900 shadow-orange-200/50 shadow-xl"},gee=t=>{const{onClose:e,context:n}=t,{article:r,type:i}=n,[s,o]=H.useState((i==="paper"?r.abstractFileComments:r.posterFileComments)??""),a=H.useRef(null),l=xw();H.useEffect(()=>{var p;return(p=a.current)==null||p.showModal(),()=>{var _;(_=a.current)==null||_.close()}},[]);const u=Vf({mutationKey:["articles","updatePaperNote"],mutationFn:async p=>{const _=ui(hi,r.id);await Rf(_,{abstractFileComments:p})}}),c=Vf({mutationKey:["articles","updatePosterNote"],mutationFn:async p=>{const _=ui(hi,r.id);await Rf(_,{posterFileComments:p})}}),d=async()=>{i==="paper"?await u.mutateAsync(s):i==="poster"&&await c.mutateAsync(s),l.invali
3780dateQueries({queryKey:["articles"]}),e()},f=async()=>{r.abstractFileId?await u.mutateAsync(""):r.posterFileId&&await c.mutateAsync(""),l.invalidateQueries({queryKey:["articles"]}),e()};return R.jsxs("dialog",{ref:a,className:"p-4 w-[960px] flex flex-col gap-2",children:[R.jsx(fC,{theme:"snow",value:s,onChange:o,className:"h-auto"}),R.jsxs("div",{className:"flex gap-2 justify-end",children:[R.jsx("button",{onClick:d,className:"p-1 px-2 text-sm bg-orange-500 text-white rounded hover:bg-orange-700",children:"Save"}),R.jsx("button",{onClick:e,className:"p-1 px-2 text-sm bg-orange-500 text-white rounded hover:bg-orange-700",children:"Cancel"}),R.jsx("button",{onClick:f,className:"p-1 px-2 text-sm bg-orange-500 text-white rounded hover:bg-orange-700",children:"Clear"})]})]})},vee=(t,e,n,r)=>{const i=n[t],s=r[t];if(typeof i=="string"&&typeof s=="string")return e==="asc"?i.localeCompare(s):s.localeCompare(i);if(typeof i=="number"&&typeof s=="number")return e==="asc"?i-s:s-i;const o=!!i,a=!!s;return e==="asc"?Number(o)-Number(a):Number(a)-Number(o)},yee="/imgs/logo-orange.svg",_ee=()=>R.jsxs("div",{className:"relative overflow-hidden min-h-[80vh]",children:[R.jsx("h1",{className:"text-4xl",children:"Contacts"}),R.jsx("p",{className:"mt-4",children:"If you have any questions, please contact the conference organizers:"}),R.jsxs("ul",{className:"ml-4 mt-4",children:[R.jsxs("li",{children:[R.jsxs("a",{href:"mailto:[email protected]",children:["Ing. ",R.jsx("strong",{children:"Lukáš MatÄjů"}),", Ph.D"]}),"."]}),R.jsx("li",{children:R.jsxs("span",{children:["Ing. ",R.jsx("strong",{children:"Jan HybÅ¡"})]})})]}),R.jsx("img",{src:yee,alt:"logo",className:"w-[800px] aspect-square opacity-5 spin-slow absolute -top-[400px] -left-[400px] pointer-events-none"})]}),wee="/imgs/logo-orange.svg",bee="/files/paper.pdf",Eee="/files/poster-a.png",xee="/files/poster-b.png",QS=t=>`/files/logo.${t}`,Tee=()=>R.jsxs("div",{className:"relative overflow-hidden min-h-[80vh] flex flex-col gap-4",children:[R.jsx("h1",{className:"text-4xl",children:"Templates"}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl",children:"Paper Template:"}),R.jsx("ul",{className:"ml-4",children:R.jsxs("li",{children:[R.jsxs("a",{href:bee,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1",children:["Paper example (PDF) ",R.jsx(Dc,{})]}),R.jsxs("a",{href:"https://www.overleaf.com/read/yxxxcrvrdktz#3d3f45",target:"_blank",rel:"noreferrer",className:"flex items-center gap-1",children:["Paper template (Overleaf) ",R.jsx(Dc,{})]})]})})]}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl",children:"Poster examples:"}),R.jsxs("ul",{className:"ml-4",children:[R.jsx("li",{children:R.jsxs("a",{href:Eee,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1",children:["Poster example A ",R.jsx(Dc,{})]})}),R.jsx("li",{children:R.jsxs("a",{href:xee,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1",children:["Poster example B ",R.jsx(Dc,{})]})})]}),R.jsxs("span",{className:"text-xs opacity-75",children:["Source: ",R.jsx("a",{href:"https://www.animateyour.science/post/best-examples-of-scientific-posters",className:"italic",target:"_blank",rel:"noreferrer",children:"www.animateyour.science"})]})]}),R.jsx(See,{}),R.jsx("img",{src:wee,alt:"logo",className:"w-[800px] aspect-square opacity-5 spin-slow absolute -top-[400px] -left-[400px] pointer-events-none"})]}),See=()=>R.jsxs("div",{children:[R.jsx("h1",{className:"text-xl",children:"Conference logo"}),R.jsx("p",{className:"prose",children:"You can download the conference logo in PDF or SVG format"}),R.jsxs("div",{className:"flex gap-1",children:[R.jsx("a",{href:QS("pdf"),download:!0,className:"bg-orange-500 text-white px-4 py-2 rounded inline-block",children:"Download PDF"}),R.jsx("a",{href:QS("svg"),download:!0,className:"bg-orange-500 text-white px-4 py-2 rounded inline-block",children:"Download SVG"})]})]}),{currentConference:ZS,registrationDeadline:kee,papersDeadline:Aee,postersDeadline:Iee,dateFmt:Iv}=Gn,Xs=t=>t?`This work was supported by the Student Grant Competition (SGS) at the Technical University of Liberec in ${ZS} under project No. SGS-XXXX-XXXX.`:`This work was supported by the Student Grant Competition (SGS) at the Technical University of Liberec in ${ZS}.`,Oee=()=>{const{year:t}=Pr(),e=n=>{navigator.clipboard.writeText(n),nt.success("Acknowledgment copied to clipboard")};return R.jsxs("div",{className:"flex flex-col gap-4",children:[R.jsx("h1",{className:"text-4xl",children:"Call for Papers"}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl",children:"Important Dates"}),R.jsx("div",{className:"prose text-base",children:R.jsxs("ul",{children:[R.jsxs("li",{children:["Registration deadline: ",R.jsx("strong",{children:kee.format(Iv)})]}),R.jsxs("li",{children:["Paper submission deadline: ",R.jsx("strong",{children:Aee.format(Iv)})]}),R.jsxs("li",{children:["Poster submission deadline: ",R.jsx("strong",{children:Iee.format(Iv)})]})]})})]}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl my-2",children:"Registration"}),R.jsx("div",{className:"prose max-w-none",children:R.jsxs("p",{children:["To register for the conference, please sign-in to the conference website using your TUL Google account and fill out the registration form. You'll be asked to provide your name and contact information, as well as your student ID number. In case you do not have a student ID number enter ",R.jsx("em",{children:"X00000000"})," instead. If you are registering as a SGS project, please select ",R.jsx("em",{children:"Student Grant Category"})," and fill out the SGS project leader information (not your supervisor's). If you are not a SGS project, please select appropriate category and fill out the supervisor information."]})})]}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl my-2",children:"Paper Submission"}),R.jsxs("div",{className:"prose max-w-none",children:[R.jsxs("p",{children:["All papers must be written in English. Each paper must be tw
3780o pages long, using a two-column format, with an extra page allowed only for references. Please use the official ",R.jsx("a",{href:"https://www.overleaf.com/read/yxxxcrvrdktz#3d3f45",children:"Overleaf template"})," for your paper. Papers must be submitted online in PDF format on the conference website. The papers will be reviewed based on their originality, technical accuracy and the quality of references."]}),R.jsxs("p",{children:[R.jsx("h6",{children:"Formatting Guidelines"}),R.jsxs("ul",{className:"text-sm my-0",children:[R.jsx("li",{children:"Use the provided template and don't change the template's formatting."}),R.jsx("li",{children:"Don't exceed the two page limit (third page is only for references)."}),R.jsx("li",{children:"Don't forget to include brief summary, keywords, and references."}),R.jsxs("li",{children:["Include an acknowledgment to the SGS project:",R.jsxs("pre",{className:"relative",children:[Xs(!0),R.jsx("button",{className:"absolute right-4 opacity-50 hover:opacity-100",onClick:()=>e(Xs(!0)),children:"Copy"})]}),"or if you don't have a SGS project number, include the following acknowledgment:",R.jsxs("pre",{className:"relative",children:[Xs(!1),R.jsx("button",{className:"absolute right-4 opacity-50 hover:opacity-100",onClick:()=>e(Xs(!1)),children:"Copy"})]})]})]})]}),R.jsxs("p",{children:[R.jsx("h6",{children:"Tips & Tricks"}),R.jsxs("ul",{className:"text-sm my-0",children:[R.jsx("li",{children:"Proofread your paper."}),R.jsx("li",{children:"Structure your paper into sections (e.g., Introduction, Methods, Results, Conclusion)."}),R.jsx("li",{children:"Use tables and figures to illustrate your points."}),R.jsx("li",{children:"Properly cite your sources."}),R.jsxs("li",{children:["Take a"," ",R.jsx(an,{to:`/conferences/${t}/previous-years`,rel:"noreferrer",children:"look"})," ","at the previous conference papers for inspiration."]})]})]})]})]}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl my-2",children:"Poster Submission"}),R.jsxs("div",{className:"prose max-w-none",children:[R.jsx("p",{children:"All posters are to be in English. Posters must be A1 format (portrait orientation) and must be submitted online on the conference website in PDF format. Each poster will be evaluated based on their clarity and visual appeal. The posters will be displayed during the conference in the poster session. There is no template for the posters, so feel free to design your poster in any way, use your creativity to make your poster stand out!"}),R.jsxs("p",{children:[R.jsx("h6",{children:"Formatting Guidelines"}),R.jsxs("ul",{className:"text-sm my-0",children:[R.jsx("li",{children:"Don't forget to include a title, author names, and affiliations."}),R.jsxs("li",{children:["Use ",R.jsx(an,{to:`/conferences/${t}/templates`,children:"Logo"})," of the conference"]}),R.jsx("li",{children:"Incorporate a logo of the conference."}),R.jsxs("li",{children:["Include an acknowledgment to the SGS project:",R.jsxs("pre",{className:"relative",children:[Xs(!0),R.jsx("button",{className:"absolute right-4 opacity-50 hover:opacity-100",onClick:()=>e(Xs(!0)),children:"Copy"})]}),"or if you don't have a SGS project number, include the following acknowledgment:",R.jsxs("pre",{className:"relative",children:[Xs(!1),R.jsx("button",{className:"absolute right-4 opacity-50 hover:opacity-100",onClick:()=>e(Xs(!1)),children:"Copy"})]})]})]})]}),R.jsxs("p",{children:[R.jsx("h6",{children:"Tips & Tricks"}),R.jsxs("ul",{className:"text-sm my-0",children:[R.jsx("li",{children:"Less is more, don't overcrowd your poster with text - use bullet points and short sentences."}),R.jsx("li",{children:"Make you poster clear, concise, and visually appealing (It is not a copy of your paper!)."}),R.jsx("li",{children:"Use large font sizes for readability."}),R.jsx("li",{children:"Include graphs, tables, and images."}),R.jsx("li",{children:"Try to use vector graphics where possible."}),R.jsx("li",{children:"Make sure you charts and tables have labels and legends with reasonable large fonts."}),R.jsx("li",{children:"No need to incorporate the references, they are already in the paper."})]})]})]})]})]})},Pee={2024:[{group:"A",name:"BRAUN Jan (ABDALLAH Sabrin Issam)",title:"Laser ablation of gold by femtosecond optical vortex beam in continuous liquid flow",type:"SGS",supervisor:"Sabrin Issam Abdallah",verified:!0},{group:"A",name:"BOYARCHIKOV Yegor",title:"Road Pavement Monitoring and Analysis Approaches Using Gyroscope and Accelerometer Data",type:"SGS",supervisor:"Yegor Boyarchikov",verified:!0}
3780,{group:"A",name:"Å PAÄEK Jan (BOYRAZ Evren)",title:"Innovative Cartridges for Water Filtration",type:"SGS",supervisor:"Evren Boyraz",verified:!0},{group:"B",name:"BRAUN Jan",title:"Laser-based formation of circuits on flexible graphene oxide films",type:"DP",supervisor:"Rafael Omar Torres Mendieta"},{group:"A",name:"DOMINKO Daniel",title:"Usage of AI in Software Engineering",type:"DP",supervisor:"Roman Å pánek"},{group:"A",name:"DOSTRAÅ IL David",title:"Optimization of control algorithms of the kinetic sculpture âPendulumâ",type:"DP",supervisor:"Otto Severýn"},{group:"A",name:"DUFEK Tomáš",title:"Removal of pharmaceuticals from biologically treated water",type:"PHD",supervisor:"Miroslav ÄernÃk"},{group:"A",name:"DUÅ EK Martin",title:"Optical Caustic Layer Beams",type:"SGS",supervisor:"Martin DuÅ¡ek",verified:!0},{group:"A",name:"HIMMEL Jan",title:"Ananlysis of Composite Saddle Reinforcement using Numrical Simulation",type:"SGS",supervisor:"Václav VomáÄko",verified:!0},{group:"A",name:"KHALEGHIABBASABADI Masoud",title:"Activation of persulfate for the degradation of vancomycin Via Heteroatom dopt graphene oxide",type:"PHD",supervisor:"Stanislaw Waclawek"},{group:"A",name:"KLEIN Lukáš",title:"Adaptive Push-Broom Hyperspectral Camera",type:"SGS",supervisor:"Lukáš Klein",verified:!0},{group:"A",name:"KOSINA VÃt",title:"Ferroelectric Transistor and Its Applications",type:"SGS",supervisor:"VÃt Kosina",verified:!0},{group:"A",name:"KÅEPELKA Michal",title:"Metrics for evaluating the realism of the vehicle speed profile",type:"SGS",supervisor:"Michal KÅepelka",verified:!0},{group:"A",name:"KYNYCH FrantiÅ¡ek",title:"Real-time Speaker Diarization for Audio-Visual Data Streams",type:"SGS",supervisor:"FrantiÅ¡ek Kynych",verified:!0},{group:"A",name:"LE DUC Trung",title:"Effect of Microorganisms on Low-pH Concrete in Deep Geological Repository",type:"SGS",supervisor:"Trung Le Duc",verified:!0},{group:"B",name:"LINDAUER VojtÄch",title:"Electrochemical effects on the ferroelectric-tissue interface",type:"SGS",supervisor:"VojtÄch Lindauer",verified:!0},{group:"B",name:"LUKEÅ Jakub",title:"Characterisation of LIDT samples via second harmonic generation",type:"SGS",supervisor:"Jakub LukeÅ¡",verified:!0},{group:"B",name:"MARLITA Marlita",title:"Isolation of potential plastic-degrading microorganisms from algae culture exposed to bio-based plastics",type:"SGS",supervisor:"Marlita Marlita",verified:!0},{group:"B",name:"MILLER VojtÄch",title:"Optical measurement of stress in birefringent samples",type:"SGS",supervisor:"VojtÄch Miller",verified:!0},{group:"B",name:"POLÃÄEK Martin",title:"Lightweight Online Punctuation and Capitalization Restoration for Streaming ASR Systems",type:"SGS",supervisor:"Martin PoláÄek",verified:!0},{group:"B",name:"Å OLC OndÅej",title:"Long-range mesh networks for two-way communication",type:"DP",supervisor:"Tomáš Martinec"},{group:"B",name:"Å PETLÃK Martin",title:"Surrogate for predicting hydraulic conductivity tensors from stochastic DFM models",type:"SGS",supervisor:"Martin Å petlÃk",verified:!0},{group:"B",name:"Å UMOVSKà Oskar",title:"Design and Verification of Car Reverse Assist Algorithm with a One-axis Trailer",type:"DP",supervisor:"Lukáš Hubka"},{group:"B",name:"TAGHAVIAN Hadi",title:"Performance improvement of PES membrane via Green surface modification",type:"PHD",supervisor:"Miroslav ÄernÃk"},{group:"B",name:"LE DUC Trung (VELIANYK Vira)",title:"Metal tolerant bacterial species, isolated from Zlate Hory former mining site",type:"SGS",supervisor:"Vira Velianyk",verified:!0},{group:"B",name:"VRÃTNà Martin",title:"Exploratory analysis of fMRI recordings using blind source separation",type:"DP",supervisor:"ZbynÄk Koldovský"},{group:"B",name:"VYHNÃLEK VojtÄch",title:"Implementation of a battery management system for an electric vehicle",type:"SGS",supervisor:"Zoltán Dolenský",verified:!0}],2025:[{group:"A",name:"HAVELKA OndÅej",title:"Applying the SIR Model in a Nanotechnological Innovation Environment",type:"DP",supervisor:"Rafael Torres"}
3780,{group:"A",name:"NAVRÃTIL MatÄj",title:"Small Multimodal Large Language Models for Mobile Platforms",type:"DP",supervisor:"Karel PaleÄek"},{group:"A",name:"BOYARCHIKOV Yegor",title:"Approaches and Methods for Improving the Precision of Road Pavement Analysis",type:"PHD",supervisor:"Tomas Martinec"},{group:"A",name:"BOHÃÄ Radek",title:"Study of electrochemical phenomena at the electrode-electrolyte interface and their effects in a flowmeter system",type:"SGS",supervisor:"Radek BoháÄ"},{group:"A",name:"BUCHTA Tomáš",title:"Detecting End Effector Command Pose Error Using Perfect Bit Field Imaging",type:"SGS",supervisor:"Tomáš Martinec"},{group:"A",name:"DUFEK Tomáš",title:"Optimization of Advanced Technologies for Micropollutant Removal in Effluents from Municipal Wastewater Treatment Plants",type:"SGS",supervisor:"Tomáš Dufek"},{group:"A",name:"DUÅ EK Martin",title:"Use of pseudo-nondiffracting Layer beams for alignment",type:"SGS",supervisor:"Martin DuÅ¡ek"},{group:"A",name:"KLEIN Lukáš",title:"Improved Portable Hyperspectral Camera",type:"SGS",supervisor:"Lukas Klein"},{group:"A",name:"LE DUC Trung",title:"Synergistic Microbial Interactions Affecting Low-pH Concrete in Deep Geological Repositories",type:"SGS",supervisor:"Trung Le Duc"},{group:"A",name:"LUKEÅ Jakub",title:"Thin film interface and bulk characterization via second harmonic generation",type:"SGS",supervisor:"Jakub LukeÅ¡"},{group:"A",name:"Å OLC OndÅej",title:"Robust wireless communication for IoT applications using a combination of different transmission technologies",type:"SGS",supervisor:"OndÅej Å olc"},{group:"A",name:"TAGHAVIAN Hadi",title:"Visible Light-Driven Photocatalytic-Modified Ultrafiltration Membranes for Efficient Removal of Emerging Contaminants from Wastewater",type:"SGS",supervisor:"Lukas Dvorak"},{group:"B",name:"HONC Marek",title:"Heating control in building A",type:"DP",supervisor:"MiloÅ¡ Hernych"},{group:"B",name:"SLABIHOUDEK Jakub",title:"Optimization of pFIB-SEM setup parameters for TEM lamella preparation considering the sample material",type:"DP",supervisor:"Pavel Kejzlar"},{group:"B",name:"KHALEGHIABBASABADI Masoud",title:"A New OrganicâInorganic Nanocomposite Reduced Graphene Oxide for Efficient NO2 Sensing",type:"PHD",supervisor:"Stanislaw Waclawek"},{group:"B",name:"BOYRAZ Evren",title:"Innovative cartridges for water filtration",type:"SGS",supervisor:"Fatma Yalcinkaya"},{group:"B",name:"BRAUN Jan",title:"Development of Flexible Circuits Based on Graphene Oxide and Natural Polysaccharides",type:"SGS",supervisor:"Rafael Omar Torres Mendieta"},{group:"B",name:"HERGESEL Jan",title:"Measurement of Flicker Visibility Threshold with PC Screen in Field of View",type:"SGS",supervisor:"Jan Hergesel"},{group:"B",name:"HIMMEL Jan",title:"Failure analysis of composite bicycle saddle rails using numerical simulations",type:"SGS",supervisor:"Václav VomáÄko"},{group:"B",name:"LEOVà Veronika",title:"Study of advanced reduction processes for destruction of per- and poly- fluoroalkyl substances",type:"SGS",supervisor:"Veronika Leová"},{group:"B",name:"MORÃVKOVà KarolÃna",title:"Nanofiber system for the therapy of vulvovaginal candidiasis.",type:"SGS",supervisor:"Karolina Moravkova"},{group:"B",name:"POLÃÄEK Martin",title:"Study on Automatic Punctuation Restoration in Bilingual Broadcast Streams",type:"SGS",supervisor:"Martin PoláÄek"},{group:"B",name:"Å PETLÃK Martin",title:"Deep Learning Surrogate for Efficient Upscaling in 3D Fractured Media",type:"SGS",supervisor:"Martin Å petlÃk"},{group:"B",name:"VELIANYK Vira",title:"Biosynthesis of Selenium Nanoparticles by Variovorax sp., Isolated from Former Mine",type:"SGS",supervisor:"Vira Velianyk"}],2026:[{group:"A",name:"AL-DAILAMI Zaid",title:"Optimized Nonlinear Modeling of an ABS Isolation Valve",supervisor:"Zaid Al-Dailami",type:"SGS"},{group:"A",name:"BOHÃÄ Radek",title:"Current-mode electromagnetic flowmeter using permanent magnets",supervisor:"Radek BoháÄ",type:"SGS"},{group:"B",name:"BUCHTA Tomáš",title:"Vision-Based Measurement of a Laser-Defined Reference Plane Using Perfect Bit Fields",supervisor:"Tomáš Buchta",type:"SGS"},{group:"B",name:"DUFEK Tomáš",title:"Optimization of Advanced Technologies for Micropollutant Removal in Effluents from Municipal Wastewater Treatment Plants",supervisor:"Tomáš Dufek",type:"SGS"},{group:"A",name:"GHEIBI Mohammad",title:"Recovery of Silver Ions Using Low-Density Concrete as a Sustainable Adsorbent: A Circular Economy Approach",supervisor:"Mohammad Gheibi",type:"SGS"},{group:"A",name:"HERGESEL Jan",title:"Survey on LED Lamps in Central Europe",supervisor:"Jan Hergesel",type:"SGS"},{group:"A",name:"HIMMEL Jan",title:"Numerical model of accordion free reed",supervisor:"Jan Himmel",type:"SGS"},{group:"B",name:"KHALEGHIABBASABADI Masoud",title:"Metal-Free Activation of Persulfate via N,S-Co-Doped Graphene Oxide Prepared by Green Electrochemistry for the Accelerated Degradation of Vancomycin",supervisor:"Masoud Khaleghiabbasabadi",type:"SGS"},{group:"A",name:"KLEIN Lukáš",title:"Multidimensional Single-Pixel Microscope",supervisor:"Karel ŽÃdek",type:"PHD"},{group:"A",name:"KOHOUT Jan",title:"Add-on module for cordless drill measuring distance and angle to surface",supervisor:"Lukáš Hubka",type:"DP"},{group:"A",name:"LINDAUER VojtÄch",title:"Relation Between Macroscopic and Microscopic Fields in Electrophysiology",supervisor:"Tomáš SouÄek",type:"SGS"},{group:"B",name:"LUKEÅ Jakub",title:"Angle-resolved second harmonic generation for thin film characterisation",supervisor:"Jakub LukeÅ¡",type:"SGS"},{group:"B",name:"MAHR Libor",title:"Communication module for the platform of laboratory instruments",supervisor:"LeoÅ¡ PetržÃlka",type:"DP"},{group:"B",name:"MARUÅ KOVà Martina",title:"Effect of Microfibers on Horizontal Gene Transfer Among Microorganisms in Aquatic Environment",supervisor:"Nhung H.A. Nguyen",type:"DP"},{group:"A",name:"MINAÅÃK Jan",title:"Modeling and control of an inverted pendulum with uncertainties and implementation of a controller in a Siemens PLC",supervisor:"Lukáš Hubka",type:"DP"},{group:"B",name:"MORÃVKOVà KarolÃna",title:"Nanofibrous Layers Incorporating Natural extract from Satureja montana",supervisor:"KarolÃna Morávková",type:"SGS"},{group:"A",name:"MOTEJLEK Martin",title:"Acoustic Volume Mismatch in Distant Streaming ASR",supervisor:"Martin Motejlek",type:"SGS"},{group:"B",name:"PEREZ AGUILERA Juan Pablo",title:"Hybrid Conductive Fillers for Electrospun Biomedical Nanofibrous Yarns: Previous Findings and Planned Improvements",supervisor:"Juan Pablo Pérez Aguilera",type:"SGS"},{group:"B",name:"POLÃÄEK Martin",title:"Online Punctuation and Capitalization Restoration Using a Seq2Seq Approach",supervisor:"Martin PoláÄek",type:"SGS"},{group:"B",name:"PROKOPCOVà EliÅ¡ka",title:"MEW/MES scaffolds for skin tissue engineering in reconstructive surgery",supervisor:"Miroslava Rysová",type:"DP"},{group:"B",name:"RACZAK Barbara Klaudia",title:"Oxidation of oxacillin by sulfate radical: kinetics, mechanism and toxicity evaluation",supervisor:"Klaudia Barbara Raczak",type:"SGS"},{group:"A",name:"VELIANYK Vira",title:"Metal-based nanoparticles immobilization using Pseudomonadota from Zlate Hory former mining site",supervisor:"Vira Velianyk",type:"SGS"},{group:"B",name:"VRÃTNà Martin",title:"Template-Guided Independent Vector Extraction for Fast Search of fMRI Spatial Maps",supervisor:"ZbynÄk Koldovský",type:"PHD"},{group:"A",name:"ZÃMEÄNÃK Lukáš",title:"Nanostructured individual carbon-based fibres as electrochemical sensors",supervisor:"Petr MikeÅ¡",type:"DP"}]},{conferenceDate:Ree,timeFmt:gr,dateFmt:Cee}=Gn,er=()=>Ree.clone(),F0=15,V0=75+F0,U0=60+V0,$0=30+U0,B0=60+$0,Nee=5+B0,XS=(t,e)=>R.jsxs("div",{children:[R.jsxs("h2",{className:"text-lg my-2",children:["Group ",e]}),R.jsx("div",{className:"flex flex-col gap-2",children:t.filter(n=>n.group===e).map(n=>R.jsx("div",{className:"hover:bg-gray-100 p-2 rounded flex gap-2 items-center w-full",children:R.jsxs("div",{className:"flex w-full gap-4",children:[R.jsxs("div",{className:"flex flex-col grow",children:[R.jsx("span",{className:"text-sm font-semibold",children:n.name}),R.jsx("span",{className:"text-xs italic",children:n.title})]}),R.jsx("div",{className:"flex justify-between text-right",children:R.jsxs("div",{className:"flex flex-col justify-center items-end",children:[R.jsx("span",{className:js("px-1 py-px rounded text-xs",n.type==="SGS"&&"bg-orange-100/75",n.type==="DP"&&"bg-blue-100/75",n.type==="PHD"&&"bg-green-100/75"),children:n.type}),n.type==="SGS"&&R.jsx(R.Fragment,{children:R.jsx("span",{className:"text-xs italic",children:n.supervisor})})]})})]})},n.name))})]}),Dee=()=>{const{year:t}=Pr(),e=Pee[t]??[];return R.jsxs("div",{className:"flex flex-col gap-4",children:[R.jsx("h1",{className:"text-4xl",children:"Programme"}),R.jsxs("p",{children:["The conference will be held on ",R.jsx(R.Fragment,{children:er().format(Cee)})," in Building A, Faculty of Mechatronics, Informatics and Interdisciplinary Studies, room A310 and the hallway on the 3rd floor. Start of the conference is on ",R.jsx(Js,{children:er().format(gr)})," - please arrive few minutes earlier and wear formal attire."]}),R.jsxs("div",{children:[R.jsx("h2",{className:"text-xl",children:"Overview"}),R.jsxs("div",{className:"prose max-w-none text-base",children:[R.jsxs("ul",{children:[R.jsxs("li",{children:["Opening speech"," ",R.jsxs(J
3780s,{children:[er().format(gr)," - ",er().add(F0,"minutes").format(gr)]})," ",R.jsxs("span",{className:"text-sm",children:["will be held by the dean of the faculty, ",R.jsx("strong",{children:"doc. Ing. Josef Äernohorský, Ph.D"}),", in the room A310."]})]}),R.jsxs("li",{children:["2-minute presentations"," ",R.jsxs(Js,{children:[er().add(F0,"minutes").format(gr)," - ",er().add(V0,"minutes").format(gr)]}),R.jsx("span",{className:"text-sm",children:", the presentations will be held in the room A310."})]}),R.jsxs("li",{children:["Poster section A"," ",R.jsxs(Js,{children:[er().add(V0,"minutes").format(gr)," - ",er().add(U0,"minutes").format(gr)]}),R.jsx("span",{className:"text-sm",children:", the posters will be displayed in the hallway on the 3rd floor."})]}),R.jsxs("li",{children:["Coffee break"," ",R.jsxs(Js,{children:[er().add(U0,"minutes").format(gr)," - ",er().add($0,"minutes").format(gr)]}),R.jsx("span",{className:"text-sm",children:", the break will be held in the hallway on the 3rd floor."})]}),R.jsxs("li",{children:["Poster section B"," ",R.jsxs(Js,{children:[er().add($0,"minutes").format(gr)," - ",er().add(B0,"minutes").format(gr)]}),R.jsx("span",{className:"text-sm",children:", the posters will be displayed in the hallway on the 3rd floor."})]}),R.jsxs("li",{children:["Closing speech"," ",R.jsxs(Js,{children:[er().add(B0,"minutes").format(gr)," - ",er().add(Nee,"minutes").format(gr)]}),R.jsx("span",{className:"text-sm",children:", the closing speech will be in the hallway on the 3rd floor."})]})]}),R.jsxs("p",{children:["After the conference, there will be an optional SGS projects seminar. ",R.jsx(Js,{children:"16:30 - 17:30"}),R.jsx("span",{className:"text-sm",children:", the seminar will be held in the room A310."})]})]})]}),!1,e.length>0&&R.jsxs(R.Fragment,{children:[R.jsx("h2",{className:"text-xl mt-8",children:"Presenters"}),R.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[XS(e,"A"),XS(e,"B")]})]})]})},Js=({children:t})=>R.jsx("strong",{children:t}),Mee=()=>{const{isAdmin:t}=qi(),{year:e}=Pr(),r=ta({queryKey:["articles",e],queryFn:async()=>{const s=Vu(hi,Ho("conferenceId","==",e)),a=(await Uu(s)).docs.map(l=>l.data());return a.filter(l=>l.status!==Ye.REJECTED).filter(l=>t||l.status===Ye.PUBLISHED).sort((l,u)=>l.lastName.localeCompare(u.lastName)),a},enabled:!!e}).data??[],i=async s=>{const o=await Cf(Wo(Go,s));window.open(o,"_blank")};return R.jsxs("div",{children:[R.jsx("h1",{className:"text-3xl mb-2",children:"Proceedings"}),R.jsx("div",{className:"flex flex-col gap-2",children:R.jsxs("table",{className:"table sm w-full",children:[R.jsx("thead",{children:R.jsxs("tr",{children:[R.jsx("th",{children:"Article Type"}),R.jsx("th",{children:"Author"}),R.jsx("th",{children:"Title"}),R.jsx("th",{children:"Paper & Poster"})]})}),R.jsx("tbody",{children:r.sort((s,o)=>(s.lastName??"").localeCompare(o.lastName??"")).map(s=>{var l;const o=s.status===Ye.PUBLISHED;if(s.status===Ye.REJECTED)return null;const a=[{id:s.abstractFileId,title:"Paper",icon:Lee},{id:s.posterFileId,title:"Poster",icon:jee}];return R.jsxs("tr",{className:"hover:bg-gray-100",children:[R.jsx("td",{className:"text-xs opacity-85",children:Fee[s.type]}),R.jsxs("td",{children:[(l=s.lastName)==null?void 0:l.toUpperCase()," ",s.middleName," ",s.firstName]}),R.jsx("td",{className:"text-sm opacity-85",children:s.title}),R.jsx("td",{children:R.jsx("div",{className:"flex gap-1",children:a.map((u,c)=>R.jsxs("button",{onClick:()=>i(u.id),disabled:!o,className:js("flex items-center gap-1 px-2 text-orange-700 hover:bg-orange-100",!o&&"opacity-50 cursor-not-allowed"),children:[u.icon,u.title]},`${u.id}-${c}`))})})]},s.id)})})]})})]})},Lee=R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"size-6",children:R.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m.75 12 3 3m0 0 3-3m-3 3v-6m-1.5-9H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z"})}),jee=R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"size-6",children:R.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m2.25 15.75 5.159-5.159a2.25 2.25 0 0 1 3.182 0l5.159 5.159m-1.5-1.5 1.409-1.409a2.25 2.25 0 0 1 3.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 0 0 1.5-1.5V6a1.5 1.5 0 0 0-1.5-1.5H3.75A1.5 1.5 0 0 0 2.25 6v12a1.5 1.5 0 0 0 1.5 1.5Zm10.5-11.25h.008v.008h-.008V8.25Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z"})}),Fee={[Fr.BP]:"Bachelor's thesis",[Fr.DP]:"Diploma thesis",[Fr.Dproj
3780]:"Diploma project",[Fr.PHD]:"Dissertation thesis",[Fr.SGS]:"Student grant scheme"};var eN={exports:{}};(()=>{var t={d:(s,o)=>{for(var a in o)t.o(o,a)&&!t.o(s,a)&&Object.defineProperty(s,a,{enumerable:!0,get:o[a]})},o:(s,o)=>Object.prototype.hasOwnProperty.call(s,o),r:s=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})}},e={};function n(s,o){for(var a=0;a<o.length;a++){var l=o[a];l.enumerable=l.enumerable||!1,l.configurable=!0,"value"in l&&(l.writable=!0),Object.defineProperty(s,l.key,l)}}t.r(e),t.d(e,{default:()=>i});var r=function(){function s(){(function(l,u){if(!(l instanceof u))throw new TypeError("Cannot call a class as a function")})(this,s)}var o,a;return o=s,a=[{key:"changeHeightWidth",value:function(l,u,c,d,f,p){return c>d&&(l=Math.round(l*d/c),c=d),l>u&&(c=Math.round(c*u/l),l=u),f&&c<f&&(l=Math.round(l*f/c),c=f),p&&l<p&&(c=Math.round(c*p/l),l=p),{height:l,width:c}}},{key:"resizeAndRotateImage",value:function(l,u,c,d,f){var p=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"jpeg",_=arguments.length>6&&arguments[6]!==void 0?arguments[6]:100,y=arguments.length>7&&arguments[7]!==void 0?arguments[7]:0,w=_/100,g=document.createElement("canvas"),m=l.width,b=l.height,v=this.changeHeightWidth(b,c,m,u,d,f);!y||y!==90&&y!==270?(g.width=v.width,g.height=v.height):(g.width=v.height,g.height=v.width),m=v.width,b=v.height;var A=g.getContext("2d");return A.fillStyle="rgba(0, 0, 0, 0)",A.fillRect(0,0,m,b),A.imageSmoothingEnabled&&A.imageSmoothingQuality&&(A.imageSmoothingQuality="high"),y&&(A.rotate(y*Math.PI/180),y===90?A.translate(0,-g.width):y===180?A.translate(-g.width,-g.height):y===270?A.translate(-g.height,0):y!==0&&y!==360||A.translate(0,0)),A.drawImage(l,0,0,m,b),g.toDataURL("image/".concat(p),w)}},{key:"b64toByteArrays",value:function(l,u){for(var c=atob(l.toString().replace(/^data:image\/(png|jpeg|jpg|webp);base64,/,"")),d=[],f=0;f<c.length;f+=512){for(var p=c.slice(f,f+512),_=new Array(p.length),y=0;y<p.length;y++)_[y]=p.charCodeAt(y);var w=new Uint8Array(_);d.push(w)}return d}},{key:"b64toBlob",value:function(l,u){var c=this.b64toByteArrays(l,u);return new Blob(c,{type:u,lastModified:new Date})}},{key:"b64toFile",value:function(l,u,c){var d=this.b64toByteArrays(l,c);return new File(d,u,{type:c,lastModified:new Date})}},{key:"createResizedImage",value:function(l,u,c,d,f,p,_){var y=arguments.length>7&&arguments[7]!==void 0?arguments[7]:"base64",w=arguments.length>8&&arguments[8]!==void 0?arguments[8]:null,g=arguments.length>9&&arguments[9]!==void 0?arguments[9]:null,m=new FileReader;if(!l)throw Error("File Not Found!");if(l.type&&!l.type.includes("image"))throw Error("File Is NOT Image!");m.readAsDataURL(l),m.onload=function(){var b=new Image;b.src=m.result,b.onload=function(){var v=s.resizeAndRotateImage(b,u,c,w,g,d,f,p),A="image/".concat(d);switch(y){case"blob":var N=s.b64toBlob(v,A);_(N);break;case"base64":_(v);break;case"file":var x=l.name.toString().replace(/(png|jpeg|jpg|webp)$/i,"").concat(d.toString()),E=s.b64toFile(v,x,A);_(E);break;default:_(v)}}},m.onerror=function(b){throw Error(b)}}}],a&&n(o,a),s}();const i={imageFileResizer:function(s,o,a,l,u,c,d,f,p,_){return r.createResizedImage(s,o,a,l,u,c,d,f,p,_)}};eN.exports=e})();var Vee=eN.exports;const Uee=Ou(Vee),Ov=(t,e,n,r=90)=>new Promise(i=>{Uee.imageFileResizer(t,e??300,n??e??300,"JPEG",r,0,s=>i(s),"base64")}),$ee=t=>{const e=n=>n.toString().padStart(2,"0");return`${t.getFullYear()}${e(t.getMonth()+1)}${e(t.getDate())}${e(t.getHours())}${e(t.getMinutes())}${e(t.getSeconds())}`},tN=({edit:t=!1})=>{const{year:e}=Pr(),[n,r]=H.useState(-1),[i,s]=H.useState([]),[o,a]=H.useState([]),[l,u]=H.useState(-1),{isAdmin:c}=qi(),d=ta({queryKey:["gallery",e],queryFn:async()=>{const w=ui(Ql,e),b=(await Lp(w)).data().gallery??[],v=Wo(Go,`gallery/${e}`),A=await G8(v),x=A.items.filter(T=>T.name.endsWith(".preview.jpg")).map(T=>({original:A.items.find(k=>k.name===T.name.replace(".preview.jpg",".original.jpg")),preview:T})),E=await Promise.all(x.map(async T=>{const S=await Cf(T.preview),k=await Cf(T.original);return{original:T.original,preview:T.preview,previewUrl:S,originalUrl:k}}));return s(E),a(b),{galleryImgs:E,gallery:b}}});H.useEffect(()=>{const w=g=>{g.key==="Escape"&&r(-1),g.key==="ArrowRight"&&r(m=>(m+1)%i.length),g.key==="ArrowLeft"&&r(m=>(m-1+i.length)%i.length)};return window.addEventListener("keyup",w),()=>{window.removeEventListener("keyup",w)}},[d.data]);const f=async w=>{await bT(w.original),await bT(w.preview);const g=ui(Ql,e),v=((await Lp(g)).data().gallery??[]).filter(A=>A!==w.preview.fullPath);await Pf(g,{gallery:v},{merge:!0}),d.refetch()};if(!d.data||d.isLoading)return R.jsx("div",{children:"Loading..."});const p=o.map(w=>i.find(g=>g.preview.fullPath===w)).filter(w=>w),_=w=>{w.preventDefault()},y=async w=>{if(l===-1){u(w);return}if(l===w){u(-1);return}const g=[...o],[m]=g.splice(l,1);g.splice(w,0,m);const b=ui(Ql,e);await Pf(b,{gallery:g},{merge:!0}),u(-1),a(g)};return R.jsxs("div",{children:[R.jsx("h1",{className:"text-2xl",children:"Gallery"}),R.jsxs("div",{className:"grid grid-cols-[repeat(auto-fill,minmax(160px,1fr))] gap-1 place-items-center p-4 gallery",children:[p.map((w,g)=>R.jsxs("div",{onDrop:_,onDragOver:_,draggable:t,onClick:()=>t?y(g):r(g),className:js("relative hover:scale-110 hover:z-10 transition-all hover:ring-2 hover:ring-orange-500 gallery-img rounded hover:rounded-lg overflow-hidden",l===g?"ring-green-500 ring-8 z-20 animate-pulse":""),children:[R.jsx("img",{src:w.previewUrl,alt:"preview",className:"w-40 h-40 object-cover"}),c&&t&&R.jsx("button",{className:"absolute top-1 right-2 bg-red-500 text-white p-1 rounded text-xs",onClick:m=>{m.stopPropagation(),f(w)},children:"Delete"})]},w.preview.fullPath)),n!==-1&&R.jsx("div",{className:"gallery-img-full fixed z-30 top-0 left-0 w-full h-full bg-black bg-opacity-75 flex justify-center items-center",onClick:()=>r(-1),children:R.jsx("img",{src:p[n].originalUrl,alt:"preview"})})]})]})},Bee=()=>{const{year:t}=Pr(),{isAdmin:e}=qi(),[n,r]=H.useState([]),[i,s]=H.useState(!1),[o,a]=H.useState(""),l=H.useCallback(async _=>{if(_.length===0)return;const y=await Promise.all(_.map(w=>Ov(w,240,240,100)));r(y),console.log(_)},[]),{getRootProps:u,getInputProps:c,isDragActive:d,acceptedFiles:f}=jw({onDrop:l,accept:{"image/jpeg":[],"image/png":[]}}),p=async()=>
3780{if(!e)return;s(!0);const _=ui(Ql,t),g=(await Lp(_)).data().gallery??[],b=`gallery/${t}/${$ee(new Date)}`,v=f.sort((A,N)=>A.name.localeCompare(N.name));for(let A=0;A<v.length;A++){a(`${A+1}/${v.length}`);const N=v[A],x=await Ov(N,1e3,1e3,90),E=await Ov(N,240,240,90),T=Wo(Go,`${b}-${A}-${N.name}.original.jpg`),S=Wo(Go,`${b}-${A}-${N.name}.preview.jpg`);await wT(T,x,"data_url",{contentType:"image/jpeg"}),await wT(S,E,"data_url",{contentType:"image/jpeg",customMetadata:{original:T.fullPath,order:A.toString()}}),g.push(S.fullPath)}await Pf(_,{gallery:g},{merge:!0}),a("finished"),s(!1)};return R.jsxs("div",{className:"flex flex-col gap-2",children:[R.jsx(tN,{edit:!0}),R.jsxs("div",{...u(),className:"border border-dashed p-8 rounded",children:[R.jsx("input",{...c()}),d?R.jsx("p",{children:"Drop the files here ..."}):R.jsx("p",{children:"Drag 'n' drop some files here, or click to select files"})]}),f.length>0&&R.jsxs("div",{children:[R.jsxs("div",{children:["To be uploaded:",R.jsx("div",{className:"flex gap-1 flex-wrap",children:n.map((_,y)=>R.jsx("img",{src:_,alt:"file",className:"object-contain"},y))})]}),R.jsx("button",{onClick:p,disabled:i,className:"bg-orange-500 text-white p-2 rounded",children:i?R.jsxs(R.Fragment,{children:["Uploading ",o,R.jsx("span",{className:"animate-spin rounded-full h-3 w-3 border-b-2 border-white inline-block ml-2"})]}):"Upload"})]})]})},{skfmOldWebsite:zee}=Gn,qee=[2023,2022,2021,2020,2019,2018,2017,2016,2015,2014,2013,2012],Hee=()=>{const{year:t}=Pr(),e=parseInt(t),r=ta({queryKey:["previousYears",t],queryFn:async()=>{const i=Vu(Ql);return(await Uu(i)).docs.map(a=>a.data()).filter(a=>a.year<e)}}).data??[];return R.jsxs("div",{className:"prose prose-orange",children:[r.length>0&&R.jsxs(R.Fragment,{children:[R.jsx("h2",{className:"text-2xl",children:"Previous years"}),R.jsx("ul",{children:r.map(i=>R.jsx("li",{children:R.jsx(Gee,{to:`/conferences/${i.year}`,children:i.name})},i.year))})]}),R.jsx("h2",{children:"Older conferences"}),R.jsx("ul",{children:qee.map(i=>R.jsx("li",{children:R.jsxs(Wee,{href:`${zee}/${i}`,children:["SKFM ",i," ",R.jsx(Dc,{className:"text-xs opacity-50"})]})},i))})]})},Wee=({children:t,...e})=>R.jsx("a",{...e,className:"p-1 px-3 text-base no-underline rounded inline-flex items-center gap-1 hover:bg-orange-500/5",target:"_blank",rel:"noreferrer",children:t}),Gee=({children:t,...e})=>R.jsx(an,{...e,className:"p-1 px-3 text-base no-underline rounded inline-flex items-center gap-1 hover:bg-orange-500/5",children:t}),Kee=yL([{path:"/",element:R.jsx(pq,{}),children:[{path:"conferences/:year",element:R.jsx(aX,{})},{path:"conferences/:year/my-paper",element:R.jsx(hJ,{})},{path:"conferences/:year/my-files",element:R.jsx(cee,{})},{path:"conferences/:year/manage",element:R.jsx(pee,{})},{path:"conferences/:year/contacts",element:R.jsx(_ee,{})},{path:"conferences/:year/templates",element:R.jsx(Tee,{})},{path:"conferences/:year/call-for-papers",element:R.jsx(Oee,{})},{path:"conferences/:year/programme",element:R.jsx(Dee,{})},{path:"conferences/:year/proceedings",element:R.jsx(Mee,{})},{path:"conferences/:year/gallery",element:R.jsx(tN,{})},{path:"conferences/:year/gallery/manage",element:R.jsx(Bee,{})},{path:"conferences/:year/previous-years",element:R.jsx(Hee,{})},{element:R.jsx(uL,{to:`/conferences/${Gn.currentConference}`}),path:"/"}]}]),Yee=new zq({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:!1,refetchOnMount:!1}}});UA(document.getElementById("root")).render(R.jsx(Je.StrictMode,{children:R.jsx(qq,{client:Yee,children:R.jsxs(vq,{children:[R.jsx(AL,{router:Kee}),R.jsx(_X,{position:"bottom-right"})]})})}))});
3780export default Qee();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.