PageSourceSearch

https://kancah4djp.vercel.app/assets/index-CfqdyEhE.js

js kancah4djp.vercel.app collected 2026-10-03 07:10:13 UTC 1,033,790 bytes, 3,163 lines download raw bytes

vendor: 7,159 bytes, lines 1-17
1var HT=Object.defineProperty;var UT=(r,e,t)=>e in r?HT(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t;var me=(r,e,t)=>UT(r,typeof e!="symbol"?e+"":e,t);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const u of o.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&n(u)}).observe(document,{childList:!0,subtree:!0});function t(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(i){if(i.ep)return;i.ep=!0;const o=t(i);fetch(i.href,o)}})();function zT(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var Gp={exports:{}},kc={};/**
2 * @license React
3 * react-jsx-runtime.production.js
4 *
5 * Copyright (c) Meta Platforms, Inc. and 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 Px;function qT(){if(Px)return kc;Px=1;var r=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function t(n,i,o){var u=null;if(o!==void 0&&(u=""+o),i.key!==void 0&&(u=""+i.key),"key"in i){o={};for(var B in i)B!=="key"&&(o[B]=i[B])}else o=i;return i=o.ref,{$$typeof:r,type:n,key:u,ref:i!==void 0?i:null,props:o}}return kc.Fragment=e,kc.jsx=t,kc.jsxs=t,kc}var Vx;function KT(){return Vx||(Vx=1,Gp.exports=qT()),Gp.exports}var h=KT(),Hp={exports:{}},Je={};/**
10 * @license React
11 * react.production.js
12 *
13 * Copyright (c) Meta Platforms, Inc. and 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 Fx;function JT(){if(Fx)return Je;Fx=1;var r=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),t=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),u=Symbol.for("react.context"),B=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),g=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),b=Symbol.for("react.activity"),D=Symbol.iterator;function T(P){return P===null||typeof P!="object"?null:(P=D&&P[D]||P["@@iterator"],typeof P=="function"?P:null)}var M={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},z=Object.assign,W={};function K(P,ae,xe){this.props=P,this.context=ae,this.refs=W,this.updater=xe||M}K.prototype.isReactComponent={},K.prototype.setState=function(P,ae){if(typeof P!="object"&&typeof P!="function"&&P!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,P,ae,"setState")},K.prototype.forceUpdate=function(P){this.updater.enqueueForceUpdate(this,P,"forceUpdate")};function he(){}he.prototype=K.prototype;function de(P,ae,xe){this.props=P,this.context=ae,this.refs=W,this.updater=xe||M}var ce=de.prototype=new he;ce.constructor=de,z(ce,K.prototype),ce.isPureReactComponent=!0;var _e=Array.isArray;function ye(){}var S={H:null,A:null,T:null,S:null},A=Object.prototype.hasOwnProperty;function k(P,ae,xe){var Ae=xe.ref;return{$$typeof:r,type:P,key:ae,ref:Ae!==void 0?Ae:null,props:xe}}function w(P,ae){return k(P.type,ae,P.props)}function O(P){return typeof P=="object"&&P!==null&&P.$$typeof===r}function L(P){var ae={"=":"=0",":":"=2"};return"$"+P.replace(/[=:]/g,function(xe){return ae[xe]})}var N=/\/+/g;function Le(P,ae){return typeof P=="object"&&P!==null&&P.key!=null?L(""+P.key):ae.toString(36)}function Bt(P){switch(P.status){case"fulfilled":return P.value;case"rejected":throw P.reason;default:switch(typeof P.status=="string"?P.then(ye,ye):(P.status="pending",P.then(function(ae){P.status==="pending"&&(P.status="fulfilled",P.value=ae)},function(ae){P.status==="pending"&&(P.status="rejected",P.reason=ae)})),P.status){case"fulfilled":return P.value;case"rejected":throw P.reason}}throw P}function $(P,ae,xe,Ae,Ge){var Ke=typeof P;(Ke==="undefined"||Ke==="boolean")&&(P=null);var We=!1;if(P===null)We=!0;else switch(Ke){case"bigint":case"string":case"number":We=!0;break;case"object":switch(P.$$typeof){case r:case e:We=!0;break;case y:return We=P._init,$(We(P._payload),ae,xe,Ae,Ge)}}if(We)return Ge=Ge(P),We=Ae===""?"."+Le(P,0):Ae,_e(Ge)?(xe="",We!=null&&(xe=We.replace(N,"$&/")+"/"),$(Ge,ae,xe,"",function(or){return or})):Ge!=null&&(O(Ge)&&(Ge=w(Ge,xe+(Ge.key==null||P&&P.key===Ge.key?"":(""+Ge.key).replace(N,"$&/")+"/")+We)),ae.push(Ge)),1;We=0;var Jt=Ae===""?".":Ae+":";if(_e(P))for(var Tt=0;Tt<P.length;Tt++)Ae=P[Tt],Ke=Jt+Le(Ae,Tt),We+=$(Ae,ae,xe,Ke,Ge);else if(Tt=T(P),typeof Tt=="function")for(P=Tt.call(P),Tt=0;!(Ae=P.next()).done;)Ae=Ae.value,Ke=Jt+Le(Ae,Tt++),We+=$(Ae,ae,xe,Ke,Ge);else if(Ke==="object"){if(typeof P.then=="function")return $(Bt(P),ae,xe,Ae,Ge);throw ae=String(P),Error("Objects are not valid as a React child (found: "+(ae==="[object Object]"?"object with keys {"+Object.keys(P).join(", ")+"}":ae)+"). If you meant to render a collection of children, use an array instead.")}return We}function pe(P,ae,xe){if(P==null)return P;var Ae=[],Ge=0;return $(P,Ae,"","",function(Ke){return ae.call(xe,Ke,Ge++)}),Ae}function Re(P){if(P._status===-1){var ae=P._result;ae=ae(),ae.then(function(xe){(P._status===0||P._status===-1)&&(P._status=1,P._result=xe)},function(xe){(P._status===0||P._status===-1)&&(P._status=2,P._result=xe)}),P._status===-1&&(P._status=0,P._result=ae)}if(P._status===1)return P._result.default;throw P._result}var qe=typeof reportError=="function"?reportError:function(P){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var ae=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof P=="object"&&P!==null&&typeof P.message=="string"?String(P.message):String(P),error:P});if(!window.dispatchEvent(ae))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",P);return}console.error(P)},Ie={map:pe,forEach:function(P,ae,xe){pe(P,function(){ae.apply(this,arguments)},xe)},count:function(P){var ae=0;return pe(P,function(){ae++}),ae},toArray:function(P){return pe(P,function(ae){return ae})||[]},only:function(P){if(!O(P))throw Error("React.Children.only expected to receive a single React element child.");return P}};return Je.Activity=b,Je.Children=Ie,Je.Component=K,Je.Fragment=t,Je.Profiler=i,Je.PureComponent=de,Je.StrictMode=n,Je.Suspense=f,Je.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=S,Je.__COMPILER_RUNTIME={__proto__:null,c:function(P){return S.H.useMemoCache(P)}},Je.cache=function(P){return function(){return P.apply(null,arguments)}},Je.cacheSignal=function(){return null},Je.cloneElement=function(P,ae,xe){if(P==null)throw Error("The argument must be a React element, but you passed "+P+".");var Ae=z({},P.props),Ge=P.key;
vendor: 14,606 bytes, lines 17-41
17if(ae!=null)for(Ke in ae.key!==void 0&&(Ge=""+ae.key),ae)!A.call(ae,Ke)||Ke==="key"||Ke==="__self"||Ke==="__source"||Ke==="ref"&&ae.ref===void 0||(Ae[Ke]=ae[Ke]);var Ke=arguments.length-2;if(Ke===1)Ae.children=xe;else if(1<Ke){for(var We=Array(Ke),Jt=0;Jt<Ke;Jt++)We[Jt]=arguments[Jt+2];Ae.children=We}return k(P.type,Ge,Ae)},Je.createContext=function(P){return P={$$typeof:u,_currentValue:P,_currentValue2:P,_threadCount:0,Provider:null,Consumer:null},P.Provider=P,P.Consumer={$$typeof:o,_context:P},P},Je.createElement=function(P,ae,xe){var Ae,Ge={},Ke=null;if(ae!=null)for(Ae in ae.key!==void 0&&(Ke=""+ae.key),ae)A.call(ae,Ae)&&Ae!=="key"&&Ae!=="__self"&&Ae!=="__source"&&(Ge[Ae]=ae[Ae]);var We=arguments.length-2;if(We===1)Ge.children=xe;else if(1<We){for(var Jt=Array(We),Tt=0;Tt<We;Tt++)Jt[Tt]=arguments[Tt+2];Ge.children=Jt}if(P&&P.defaultProps)for(Ae in We=P.defaultProps,We)Ge[Ae]===void 0&&(Ge[Ae]=We[Ae]);return k(P,Ke,Ge)},Je.createRef=function(){return{current:null}},Je.forwardRef=function(P){return{$$typeof:B,render:P}},Je.isValidElement=O,Je.lazy=function(P){return{$$typeof:y,_payload:{_status:-1,_result:P},_init:Re}},Je.memo=function(P,ae){return{$$typeof:g,type:P,compare:ae===void 0?null:ae}},Je.startTransition=function(P){var ae=S.T,xe={};S.T=xe;try{var Ae=P(),Ge=S.S;Ge!==null&&Ge(xe,Ae),typeof Ae=="object"&&Ae!==null&&typeof Ae.then=="function"&&Ae.then(ye,qe)}catch(Ke){qe(Ke)}finally{ae!==null&&xe.types!==null&&(ae.types=xe.types),S.T=ae}},Je.unstable_useCacheRefresh=function(){return S.H.useCacheRefresh()},Je.use=function(P){return S.H.use(P)},Je.useActionState=function(P,ae,xe){return S.H.useActionState(P,ae,xe)},Je.useCallback=function(P,ae){return S.H.useCallback(P,ae)},Je.useContext=function(P){return S.H.useContext(P)},Je.useDebugValue=function(){},Je.useDeferredValue=function(P,ae){return S.H.useDeferredValue(P,ae)},Je.useEffect=function(P,ae){return S.H.useEffect(P,ae)},Je.useEffectEvent=function(P){return S.H.useEffectEvent(P)},Je.useId=function(){return S.H.useId()},Je.useImperativeHandle=function(P,ae,xe){return S.H.useImperativeHandle(P,ae,xe)},Je.useInsertionEffect=function(P,ae){return S.H.useInsertionEffect(P,ae)},Je.useLayoutEffect=function(P,ae){return S.H.useLayoutEffect(P,ae)},Je.useMemo=function(P,ae){return S.H.useMemo(P,ae)},Je.useOptimistic=function(P,ae){return S.H.useOptimistic(P,ae)},Je.useReducer=function(P,ae,xe){return S.H.useReducer(P,ae,xe)},Je.useRef=function(P){return S.H.useRef(P)},Je.useState=function(P){return S.H.useState(P)},Je.useSyncExternalStore=function(P,ae,xe){return S.H.useSyncExternalStore(P,ae,xe)},Je.useTransition=function(){return S.H.useTransition()},Je.version="19.2.8",Je}var Gx;function rC(){return Gx||(Gx=1,Hp.exports=JT()),Hp.exports}var be=rC();const Ks=zT(be);var Up={exports:{}},Lc={},zp={exports:{}},qp={};/**
18 * @license React
19 * scheduler.production.js
20 *
21 * Copyright (c) Meta Platforms, Inc. and 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 */var Hx;function QT(){return Hx||(Hx=1,(function(r){function e($,pe){var Re=$.length;$.push(pe);e:for(;0<Re;){var qe=Re-1>>>1,Ie=$[qe];if(0<i(Ie,pe))$[qe]=pe,$[Re]=Ie,Re=qe;else break e}}function t($){return $.length===0?null:$[0]}function n($){if($.length===0)return null;var pe=$[0],Re=$.pop();if(Re!==pe){$[0]=Re;e:for(var qe=0,Ie=$.length,P=Ie>>>1;qe<P;){var ae=2*(qe+1)-1,xe=$[ae],Ae=ae+1,Ge=$[Ae];if(0>i(xe,Re))Ae<Ie&&0>i(Ge,xe)?($[qe]=Ge,$[Ae]=Re,qe=Ae):($[qe]=xe,$[ae]=Re,qe=ae);else if(Ae<Ie&&0>i(Ge,Re))$[qe]=Ge,$[Ae]=Re,qe=Ae;else break e}}return pe}function i($,pe){var Re=$.sortIndex-pe.sortIndex;return Re!==0?Re:$.id-pe.id}if(r.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;r.unstable_now=function(){return o.now()}}else{var u=Date,B=u.now();r.unstable_now=function(){return u.now()-B}}var f=[],g=[],y=1,b=null,D=3,T=!1,M=!1,z=!1,W=!1,K=typeof setTimeout=="function"?setTimeout:null,he=typeof clearTimeout=="function"?clearTimeout:null,de=typeof setImmediate<"u"?setImmediate:null;function ce($){for(var pe=t(g);pe!==null;){if(pe.callback===null)n(g);else if(pe.startTime<=$)n(g),pe.sortIndex=pe.expirationTime,e(f,pe);else break;pe=t(g)}}function _e($){if(z=!1,ce($),!M)if(t(f)!==null)M=!0,ye||(ye=!0,L());else{var pe=t(g);pe!==null&&Bt(_e,pe.startTime-$)}}var ye=!1,S=-1,A=5,k=-1;function w(){return W?!0:!(r.unstable_now()-k<A)}function O(){if(W=!1,ye){var $=r.unstable_now();k=$;var pe=!0;try{e:{M=!1,z&&(z=!1,he(S),S=-1),T=!0;var Re=D;try{t:{for(ce($),b=t(f);b!==null&&!(b.expirationTime>$&&w());){var qe=b.callback;if(typeof qe=="function"){b.callback=null,D=b.priorityLevel;var Ie=qe(b.expirationTime<=$);if($=r.unstable_now(),typeof Ie=="function"){b.callback=Ie,ce($),pe=!0;break t}b===t(f)&&n(f),ce($)}else n(f);b=t(f)}if(b!==null)pe=!0;else{var P=t(g);P!==null&&Bt(_e,P.startTime-$),pe=!1}}break e}finally{b=null,D=Re,T=!1}pe=void 0}}finally{pe?L():ye=!1}}}var L;if(typeof de=="function")L=function(){de(O)};else if(typeof MessageChannel<"u"){var N=new MessageChannel,Le=N.port2;N.port1.onmessage=O,L=function(){Le.postMessage(null)}}else L=function(){K(O,0)};function Bt($,pe){S=K(function(){$(r.unstable_now())},pe)}r.unstable_IdlePriority=5,r.unstable_ImmediatePriority=1,r.unstable_LowPriority=4,r.unstable_NormalPriority=3,r.unstable_Profiling=null,r.unstable_UserBlockingPriority=2,r.unstable_cancelCallback=function($){$.callback=null},r.unstable_forceFrameRate=function($){0>$||125<$?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):A=0<$?Math.floor(1e3/$):5},r.unstable_getCurrentPriorityLevel=function(){return D},r.unstable_next=function($){switch(D){case 1:case 2:case 3:var pe=3;break;default:pe=D}var Re=D;D=pe;try{return $()}finally{D=Re}},r.unstable_requestPaint=function(){W=!0},r.unstable_runWithPriority=function($,pe){switch($){case 1:case 2:case 3:case 4:case 5:break;default:$=3}var Re=D;D=$;try{return pe()}finally{D=Re}},r.unstable_scheduleCallback=function($,pe,Re){var qe=r.unstable_now();switch(typeof Re=="object"&&Re!==null?(Re=Re.delay,Re=typeof Re=="number"&&0<Re?qe+Re:qe):Re=qe,$){case 1:var Ie=-1;break;case 2:Ie=250;break;case 5:Ie=1073741823;break;case 4:Ie=1e4;break;default:Ie=5e3}return Ie=Re+Ie,$={id:y++,callback:pe,priorityLevel:$,startTime:Re,expirationTime:Ie,sortIndex:-1},Re>qe?($.sortIndex=Re,e(g,$),t(f)===null&&$===t(g)&&(z?(he(S),S=-1):z=!0,Bt(_e,Re-qe))):($.sortIndex=Ie,e(f,$),M||T||(M=!0,ye||(ye=!0,L()))),$},r.unstable_shouldYield=w,r.unstable_wrapCallback=function($){var pe=D;return function(){var Re=D;D=pe;try{return $.apply(this,arguments)}finally{D=Re}}}})(qp)),qp}var Ux;function YT(){return Ux||(Ux=1,zp.exports=QT()),zp.exports}var Kp={exports:{}},Mn={};/**
26 * @license React
27 * react-dom.production.js
28 *
29 * Copyright (c) Meta Platforms, Inc. and 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 zx;function XT(){if(zx)return Mn;zx=1;var r=rC();function e(f){var g="https://react.dev/errors/"+f;if(1<arguments.length){g+="?args[]="+encodeURIComponent(arguments[1]);for(var y=2;y<arguments.length;y++)g+="&args[]="+encodeURIComponent(arguments[y])}return"Minified React error #"+f+"; visit "+g+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function t(){}var n={d:{f:t,r:function(){throw Error(e(522))},D:t,C:t,L:t,m:t,X:t,S:t,M:t},p:0,findDOMNode:null},i=Symbol.for("react.portal");function o(f,g,y){var b=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:b==null?null:""+b,children:f,containerInfo:g,implementation:y}}var u=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function B(f,g){if(f==="font")return"";if(typeof g=="string")return g==="use-credentials"?g:""}return Mn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=n,Mn.createPortal=function(f,g){var y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!g||g.nodeType!==1&&g.nodeType!==9&&g.nodeType!==11)throw Error(e(299));return o(f,g,null,y)},Mn.flushSync=function(f){var g=u.T,y=n.p;try{if(u.T=null,n.p=2,f)return f()}finally{u.T=g,n.p=y,n.d.f()}},Mn.preconnect=function(f,g){typeof f=="string"&&(g?(g=g.crossOrigin,g=typeof g=="string"?g==="use-credentials"?g:"":void 0):g=null,n.d.C(f,g))},Mn.prefetchDNS=function(f){typeof f=="string"&&n.d.D(f)},Mn.preinit=function(f,g){if(typeof f=="string"&&g&&typeof g.as=="string"){var y=g.as,b=B(y,g.crossOrigin),D=typeof g.integrity=="string"?g.integrity:void 0,T=typeof g.fetchPriority=="string"?g.fetchPriority:void 0;y==="style"?n.d.S(f,typeof g.precedence=="string"?g.precedence:void 0,{crossOrigin:b,integrity:D,fetchPriority:T}):y==="script"&&n.d.X(f,{crossOrigin:b,integrity:D,fetchPriority:T,nonce:typeof g.nonce=="string"?g.nonce:void 0})}},Mn.preinitModule=function(f,g){if(typeof f=="string")if(typeof g=="object"&&g!==null){if(g.as==null||g.as==="script"){var y=B(g.as,g.crossOrigin);n.d.M(f,{crossOrigin:y,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0})}}else g==null&&n.d.M(f)},Mn.preload=function(f,g){if(typeof f=="string"&&typeof g=="object"&&g!==null&&typeof g.as=="string"){var y=g.as,b=B(y,g.crossOrigin);n.d.L(f,y,{crossOrigin:b,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0,type:typeof g.type=="string"?g.type:void 0,fetchPriority:typeof g.fetchPriority=="string"?g.fetchPriority:void 0,referrerPolicy:typeof g.referrerPolicy=="string"?g.referrerPolicy:void 0,imageSrcSet:typeof g.imageSrcSet=="string"?g.imageSrcSet:void 0,imageSizes:typeof g.imageSizes=="string"?g.imageSizes:void 0,media:typeof g.media=="string"?g.media:void 0})}},Mn.preloadModule=function(f,g){if(typeof f=="string")if(g){var y=B(g.as,g.crossOrigin);n.d.m(f,{as:typeof g.as=="string"&&g.as!=="script"?g.as:void 0,crossOrigin:y,integrity:typeof g.integrity=="string"?g.integrity:void 0})}else n.d.m(f)},Mn.requestFormReset=function(f){n.d.r(f)},Mn.unstable_batchedUpdates=function(f,g){return f(g)},Mn.useFormState=function(f,g,y){return u.H.useFormState(f,g,y)},Mn.useFormStatus=function(){return u.H.useHostTransitionStatus()},Mn.version="19.2.8",Mn}var qx;function $T(){if(qx)return Kp.exports;qx=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),Kp.exports=XT(),Kp.exports}/**
34 * @license React
35 * react-dom-client.production.js
36 *
37 * Copyright (c) Meta Platforms, Inc. and affiliates.
38 *
39 * This source code is licensed under the MIT license found in the
40 * LICENSE file in the root directory of this source tree.
41 */var Kx;function ZT(){if(Kx)return Lc;Kx=1;var r=YT(),e=rC(),t=$T();function n(s){var a="https://react.dev/errors/"+s;if(1<arguments.length){a+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)a+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+s+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function o(s){var a=s,l=s;if(s.alternate)for(;a.return;)a=a.return;else{s=a;do a=s,(a.flags&4098)!==0&&(l=a.return),s=a.return;while(s)}return a.tag===3?l:null}function u(s){if(s.tag===13){var a=s.memoizedState;if(a===null&&(s=s.alternate,s!==null&&(a=s.memoizedState)),a!==null)return a.dehydrated}return null}function B(s){if(s.tag===31){var a=s.memoizedState;if(a===null&&(s=s.alternate,s!==null&&(a=s.memoizedState)),a!==null)return a.dehydrated}return null}function f(s){if(o(s)!==s)throw Error(n(188))}function g(s){var a=s.alternate;if(!a){if(a=o(s),a===null)throw Error(n(188));return a!==s?null:s}for(var l=s,c=a;;){var m=l.return;if(m===null)break;var p=m.alternate;if(p===null){if(c=m.return,c!==null){l=c;continue}break}if(m.child===p.child){for(p=m.child;p;){if(p===l)return f(m),s;if(p===c)return f(m),a;p=p.sibling}throw Error(n(188))}if(l.return!==c.return)l=m,c=p;else{for(var x=!1,_=m.child;_;){if(_===l){x=!0,l=m,c=p;break}if(_===c){x=!0,c=m,l=p;break}_=_.sibling}if(!x){for(_=p.child;_;){if(_===l){x=!0,l=p,c=m;break}if(_===c){x=!0,c=p,l=m;break}_=_.sibling}if(!x)throw Error(n(189))}}if(l.alternate!==c)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?s:a}function y(s){var a=s.tag;if(a===5||a===26||a===27||a===6)return s;for(s=s.child;s!==null;){if(a=y(s),a!==null)return a;s=s.sibling}return null}var b=Object.assign,D=Symbol.for("react.element"),T=Symbol.for("react.transitional.element"),M=Symbol.for("react.portal"),z=Symbol.for("react.fragment"),W=Symbol.for("react.strict_mode"),K=Symbol.for("react.profiler"),he=Symbol.for("react.consumer"),de=Symbol.for("react.context"),ce=Symbol.for("react.forward_ref"),_e=Symbol.for("react.suspense"),ye=Symbol.for("react.suspense_list"),S=Symbol.for("react.memo"),A=Symbol.for("react.lazy"),k=Symbol.for("react.activity"),w=Symbol.for("react.memo_cache_sentinel"),O=Symbol.iterator;function L(s){return s===null||typeof s!="object"?null:(s=O&&s[O]||s["@@iterator"],typeof s=="function"?s:null)}var N=Symbol.for("react.client.reference");function Le(s){if(s==null)return null;if(typeof s=="function")return s.$$typeof===N?null:s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case z:return"Fragment";case K:return"Profiler";case W:return"StrictMode";case _e:return"Suspense";case ye:return"SuspenseList";case k:return"Activity"}if(typeof s=="object")switch(s.$$typeof){case M:return"Portal";case de:return s.displayName||"Context";case he:return(s._context.displayName||"Context")+".Consumer";case ce:var a=s.render;return s=s.displayName,s||(s=a.displayName||a.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case S:return a=s.displayName||null,a!==null?a:Le(s.type)||"Memo";case A:a=s._payload,s=s._init;try{return Le(s(a))}catch{}}return null}var Bt=Array.isArray,$=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,pe=t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Re={pending:!1,data:null,method:null,action:null},qe=[],Ie=-1;function P(s){return{current:s}}function ae(s){0>Ie||(s.current=qe[Ie],qe[Ie]=null,Ie--)}function xe(s,a){Ie++,qe[Ie]=s.current,s.current=a}var Ae=P(null),Ge=P(null),Ke=P(null),We=P(null);
vendor: 10,145 bytes, lines 41-48
41function Jt(s,a){switch(xe(Ke,a),xe(Ge,s),xe(Ae,null),a.nodeType){case 9:case 11:s=(s=a.documentElement)&&(s=s.namespaceURI)?lx(s):0;break;default:if(s=a.tagName,a=a.namespaceURI)a=lx(a),s=ox(a,s);else switch(s){case"svg":s=1;break;case"math":s=2;break;default:s=0}}ae(Ae),xe(Ae,s)}function Tt(){ae(Ae),ae(Ge),ae(Ke)}function or(s){s.memoizedState!==null&&xe(We,s);var a=Ae.current,l=ox(a,s.type);a!==l&&(xe(Ge,s),xe(Ae,l))}function Gr(s){Ge.current===s&&(ae(Ae),ae(Ge)),We.current===s&&(ae(We),Ic._currentValue=Re)}var Hr,Ur;function cs(s){if(Hr===void 0)try{throw Error()}catch(l){var a=l.stack.trim().match(/\n( *(at )?)/);Hr=a&&a[1]||"",Ur=-1<l.stack.indexOf(`
42    at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
43`+Hr+s+Ur}var _a=!1;function ur(s,a){if(!s||_a)return"";_a=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var c={DetermineComponentFrameRoot:function(){try{if(a){var oe=function(){throw Error()};if(Object.defineProperty(oe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(oe,[])}catch(ee){var X=ee}Reflect.construct(s,[],oe)}else{try{oe.call()}catch(ee){X=ee}s.call(oe.prototype)}}else{try{throw Error()}catch(ee){X=ee}(oe=s())&&typeof oe.catch=="function"&&oe.catch(function(){})}}catch(ee){if(ee&&X&&typeof ee.stack=="string")return[ee.stack,X.stack]}return[null,null]}};c.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var m=Object.getOwnPropertyDescriptor(c.DetermineComponentFrameRoot,"name");m&&m.configurable&&Object.defineProperty(c.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var p=c.DetermineComponentFrameRoot(),x=p[0],_=p[1];if(x&&_){var j=x.split(`
44`),Q=_.split(`
45`);for(m=c=0;c<j.length&&!j[c].includes("DetermineComponentFrameRoot");)c++;for(;m<Q.length&&!Q[m].includes("DetermineComponentFrameRoot");)m++;if(c===j.length||m===Q.length)for(c=j.length-1,m=Q.length-1;1<=c&&0<=m&&j[c]!==Q[m];)m--;for(;1<=c&&0<=m;c--,m--)if(j[c]!==Q[m]){if(c!==1||m!==1)do if(c--,m--,0>m||j[c]!==Q[m]){var re=`
46`+j[c].replace(" at new "," at ");return s.displayName&&re.includes("<anonymous>")&&(re=re.replace("<anonymous>",s.displayName)),re}while(1<=c&&0<=m);break}}}finally{_a=!1,Error.prepareStackTrace=l}return(l=s?s.displayName||s.name:"")?cs(l):""}function Da(s,a){switch(s.tag){case 26:case 27:case 5:return cs(s.type);case 16:return cs("Lazy");case 13:return s.child!==a&&a!==null?cs("Suspense Fallback"):cs("Suspense");case 19:return cs("SuspenseList");case 0:case 15:return ur(s.type,!1);case 11:return ur(s.type.render,!1);case 1:return ur(s.type,!0);case 31:return cs("Activity");default:return""}}function va(s){try{var a="",l=null;do a+=Da(s,l),l=s,s=s.return;while(s);return a}catch(c){return`
47Error generating stack: `+c.message+`
48`+c.stack}}var Kt=Object.prototype.hasOwnProperty,Qt=r.unstable_scheduleCallback,Qs=r.unstable_cancelCallback,Ul=r.unstable_shouldYield,Ri=r.unstable_requestPaint,En=r.unstable_now,cr=r.unstable_getCurrentPriorityLevel,wa=r.unstable_ImmediatePriority,Y=r.unstable_UserBlockingPriority,ze=r.unstable_NormalPriority,Ze=r.unstable_LowPriority,At=r.unstable_IdlePriority,Ft=r.log,Gt=r.unstable_setDisableYieldValue,Ot=null,an=null;function zn(s){if(typeof Ft=="function"&&Gt(s),an&&typeof an.setStrictMode=="function")try{an.setStrictMode(Ot,s)}catch{}}var Ht=Math.clz32?Math.clz32:ql,zl=Math.log,Ta=Math.LN2;function ql(s){return s>>>=0,s===0?32:31-(zl(s)/Ta|0)|0}var Ns=256,zr=262144,Yt=4194304;function _n(s){var a=s&42;if(a!==0)return a;switch(s&-s){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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return s&261888;case 262144:case 524288:case 1048576:case 2097152:return s&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return s&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return s}}function Nn(s,a,l){var c=s.pendingLanes;if(c===0)return 0;var m=0,p=s.suspendedLanes,x=s.pingedLanes;s=s.warmLanes;var _=c&134217727;return _!==0?(c=_&~p,c!==0?m=_n(c):(x&=_,x!==0?m=_n(x):l||(l=_&~s,l!==0&&(m=_n(l))))):(_=c&~p,_!==0?m=_n(_):x!==0?m=_n(x):l||(l=c&~s,l!==0&&(m=_n(l)))),m===0?0:a!==0&&a!==m&&(a&p)===0&&(p=m&-m,l=a&-a,p>=l||p===32&&(l&4194048)!==0)?a:m}function Ys(s,a){return(s.pendingLanes&~(s.suspendedLanes&~s.pingedLanes)&a)===0}function qf(s,a){switch(s){case 1:case 2:case 4:case 8:case 64:return a+250;case 16:case 32: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 a+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function UB(){var s=Yt;return Yt<<=1,(Yt&62914560)===0&&(Yt=4194304),s}function Br(s){for(var a=[],l=0;31>l;l++)a.push(s);return a}function Oi(s,a){s.pendingLanes|=a,a!==268435456&&(s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0)}function Kf(s,a,l,c,m,p){var x=s.pendingLanes;s.pendingLanes=l,s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0,s.expiredLanes&=l,s.entangledLanes&=l,s.errorRecoveryDisabledLanes&=l,s.shellSuspendCounter=0;var _=s.entanglements,j=s.expirationTimes,Q=s.hiddenUpdates;for(l=x&~l;0<l;){var re=31-Ht(l),oe=1<<re;_[re]=0,j[re]=-1;var X=Q[re];if(X!==null)for(Q[re]=null,re=0;re<X.length;re++){var ee=X[re];ee!==null&&(ee.lane&=-536870913)}l&=~oe}c!==0&&ki(s,c,0),p!==0&&m===0&&s.tag!==0&&(s.suspendedLanes|=p&~(x&~a))}function ki(s,a,l){s.pendingLanes|=a,s.suspendedLanes&=~a;var c=31-Ht(a);s.entangledLanes|=a,s.entanglements[c]=s.entanglements[c]|1073741824|l&261930}function Lu(s,a){var l=s.entangledLanes|=a;for(s=s.entanglements;l;){var c=31-Ht(l),m=1<<c;m&a|s[c]&a&&(s[c]|=a),l&=~m}}function ju(s,a){var l=a&-a;return l=(l&42)!==0?1:Li(l),(l&(s.suspendedLanes|a))!==0?0:l}function Li(s){switch(s){case 2:s=1;break;case 8:s=4;break;case 32:s=16;break;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:s=128;break;case 268435456:s=134217728;break;default:s=0}return s}function qr(s){return s&=-s,2<s?8<s?(s&134217727)!==0?32:268435456:8:2}function zB(){var s=pe.p;return s!==0?s:(s=window.event,s===void 0?32:Sx(s.type))}function Xs(s,a){var l=pe.p;try{return pe.p=s,a()}finally{pe.p=l}}var $s=Math.random().toString(36).slice(2),ln="__reactFiber$"+$s,Dn="__reactProps$"+$s,hr="__reactContainer$"+$s,Kl="__reactEvents$"+$s,Jf="__reactListeners$"+$s,qB="__reactHandles$"+$s,KB="__reactResources$"+$s,dr="__reactMarker$"+$s;function Jl(s){delete s[ln],delete s[Dn],delete s[Kl],delete s[Jf],delete s[qB]}function fr(s){var a=s[ln];if(a)return a;for(var l=s.parentNode;l;){if(a=l[hr]||l[ln]){if(l=a.alternate,a.child!==null||l!==null&&l.child!==null)for(s=mx(s);s!==null;){if(l=s[ln])return l;s=mx(s)}return a}s=l,l=s.parentNode}return null}function Is(s){if(s=s[ln]||s[hr]){var a=s.tag;if(a===5||a===6||a===13||a===31||a===26||a===27||a===3)return s}return null}function Bs(s){var a=s.tag;if(a===5||a===26||a===27||a===6)return s.stateNode;throw Error(n(33))}function mr(s){var a=s[KB];return a||(a=s[KB]={hoistableStyles:new Map,hoistableScripts:new Map}),a}function on(s){s[dr]=!0}var Mu=new Set,Pu={};function pr(s,a){gr(s,a),gr(s+"Capture",a)}function gr(s,a){for(Pu[s]=a,s=0;s<a.length;s++)Mu.add(a[s])}var Vu=RegExp("^[: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]*$"),Fu={},Gu={};function JB(s){return Kt.call(Gu,s)?!0:Kt.call(Fu,s)?!1:Vu.test(s)?Gu[s]=!0:(Fu[s]=!0,!1)}function Ql(s,a,l){if(JB(a))if(l===null)s.removeAttribute(a);else{switch(typeof l){case"undefined":case"function":case"symbol":s.removeAttribute(a);return;case"boolean":var c=a.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){s.removeAttribute(a);return}}s.setAttribute(a,""+l)}}function hs(s,a,l){if(l===null)s.removeAttribute(a);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(a);return}s.setAttribute(a,""+l)}}function un(s,a,l,c){if(c===null)s.removeAttribute(l);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(l);return}s.setAttributeNS(a,l,""+c)}}function vn(s){switch(typeof s){case"bigint":case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function Aa(s){var a=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function Hu(s,a,l){var c=Object.getOwnPropertyDescriptor(s.constructor.prototype,a);if(!s.hasOwnProperty(a)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var m=c.get,p=c.set;return Object.defineProperty(s,a,{configurable:!0,get:function(){return m.call(this)},set:function(x){l=""+x,p.call(this,x)}}),Object.defineProperty(s,a,{enumerable:c.enumerable}),{getValue:function(){return l},setValue:function(x){l=""+x},stopTracking:function(){s._valueTracker=null,delete s[a]}}}}function Ct(s){if(!s._valueTracker){var a=Aa(s)?"checked":"value";s._valueTracker=Hu(s,a,""+s[a])}}function ji(s){if(!s)return!1;var a=s._valueTracker;if(!a)return!0;var l=a.getValue(),c="";return s&&(c=Aa(s)?s.checked?"true":"false":s.value),s=c,s!==l?(a.setValue(s),!0):!1}function Cr(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}var Mi=/[\n"\\]/g;function $n(s){return s.replace(Mi,function(a){return"\\"+a.charCo
vendor: 4,418 bytes, line 48
48deAt(0).toString(16)+" "})}function Yl(s,a,l,c,m,p,x,_){s.name="",x!=null&&typeof x!="function"&&typeof x!="symbol"&&typeof x!="boolean"?s.type=x:s.removeAttribute("type"),a!=null?x==="number"?(a===0&&s.value===""||s.value!=a)&&(s.value=""+vn(a)):s.value!==""+vn(a)&&(s.value=""+vn(a)):x!=="submit"&&x!=="reset"||s.removeAttribute("value"),a!=null?Uu(s,x,vn(a)):l!=null?Uu(s,x,vn(l)):c!=null&&s.removeAttribute("value"),m==null&&p!=null&&(s.defaultChecked=!!p),m!=null&&(s.checked=m&&typeof m!="function"&&typeof m!="symbol"),_!=null&&typeof _!="function"&&typeof _!="symbol"&&typeof _!="boolean"?s.name=""+vn(_):s.removeAttribute("name")}function QB(s,a,l,c,m,p,x,_){if(p!=null&&typeof p!="function"&&typeof p!="symbol"&&typeof p!="boolean"&&(s.type=p),a!=null||l!=null){if(!(p!=="submit"&&p!=="reset"||a!=null)){Ct(s);return}l=l!=null?""+vn(l):"",a=a!=null?""+vn(a):l,_||a===s.value||(s.value=a),s.defaultValue=a}c=c??m,c=typeof c!="function"&&typeof c!="symbol"&&!!c,s.checked=_?s.checked:!!c,s.defaultChecked=!!c,x!=null&&typeof x!="function"&&typeof x!="symbol"&&typeof x!="boolean"&&(s.name=x),Ct(s)}function Uu(s,a,l){a==="number"&&Cr(s.ownerDocument)===s||s.defaultValue===""+l||(s.defaultValue=""+l)}function Na(s,a,l,c){if(s=s.options,a){a={};for(var m=0;m<l.length;m++)a["$"+l[m]]=!0;for(l=0;l<s.length;l++)m=a.hasOwnProperty("$"+s[l].value),s[l].selected!==m&&(s[l].selected=m),m&&c&&(s[l].defaultSelected=!0)}else{for(l=""+vn(l),a=null,m=0;m<s.length;m++){if(s[m].value===l){s[m].selected=!0,c&&(s[m].defaultSelected=!0);return}a!==null||s[m].disabled||(a=s[m])}a!==null&&(a.selected=!0)}}function YB(s,a,l){if(a!=null&&(a=""+vn(a),a!==s.value&&(s.value=a),l==null)){s.defaultValue!==a&&(s.defaultValue=a);return}s.defaultValue=l!=null?""+vn(l):""}function Ia(s,a,l,c){if(a==null){if(c!=null){if(l!=null)throw Error(n(92));if(Bt(c)){if(1<c.length)throw Error(n(93));c=c[0]}l=c}l==null&&(l=""),a=l}l=vn(a),s.defaultValue=l,c=s.textContent,c===l&&c!==""&&c!==null&&(s.value=c),Ct(s)}function Zn(s,a){if(a){var l=s.firstChild;if(l&&l===s.lastChild&&l.nodeType===3){l.nodeValue=a;return}}s.textContent=a}var XB=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function zu(s,a,l){var c=a.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?c?s.setProperty(a,""):a==="float"?s.cssFloat="":s[a]="":c?s.setProperty(a,l):typeof l!="number"||l===0||XB.has(a)?a==="float"?s.cssFloat=l:s[a]=(""+l).trim():s[a]=l+"px"}function qu(s,a,l){if(a!=null&&typeof a!="object")throw Error(n(62));if(s=s.style,l!=null){for(var c in l)!l.hasOwnProperty(c)||a!=null&&a.hasOwnProperty(c)||(c.indexOf("--")===0?s.setProperty(c,""):c==="float"?s.cssFloat="":s[c]="");for(var m in a)c=a[m],a.hasOwnProperty(m)&&l[m]!==c&&zu(s,m,c)}else for(var p in a)a.hasOwnProperty(p)&&zu(s,p,a[p])}function Xl(s){if(s.indexOf("-")===-1)return!1;switch(s){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 $B=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRen
48dering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Sa=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function $l(s){return Sa.test(""+s)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":s}function Zs(){}var Ku=null;function Ss(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var Ra=null,yr=null;function Pi(s){var a=Is(s);if(a&&(s=a.stateNode)){var l=s[Dn]||null;e:switch(s=a.stateNode,a.type){case"input":if(Yl(s,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),a=l.name,l.type==="radio"&&a!=null){for(l=s;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+$n(""+a)+'"][type="radio"]'),a=0;a<l.length;a++){var c=l[a];if(c!==s&&c.form===s.form){var m=c[Dn]||null;if(!m)throw Error(n(90));Yl(c,m.value,m.defaultValue,m.defaultValue,m.checked,m.defaultChecked,m.type,m.name)}}for(a=0;a<l.length;a++)c=l[a],c.form===s.form&&ji(c)}break e;case"textarea":YB(s,l.value,l.defaultValue);break e;case"select":a=l.value,a!=null&&Na(s,!!l.multiple,a,!1)}}}var Zl=!1;function Oa(s,a,l){if(Zl)return s(a,l);Zl=!0;try{var c=s(a);return c}finally{if(Zl=!1,(Ra!==null||yr!==null)&&(zh(),Ra&&(a=Ra,s=yr,yr=Ra=null,Pi(a),s)))for(a=0;a<s.length;a++)Pi(s[a])}}function Ws(s,a){var l=s.stateNode;if(l===null)return null;var c=l[Dn]||null;if(c===null)return null;l=c[a];e:switch(a){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(s=s.type,c=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!c;break e;default:s=!1}if(s)return null;if(l&&typeof l!="function")throw Error(n(231,a,typeof l));return l}var Rs=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Vi=!1;if(Rs)try{var Et={};Object.defineProperty(Et,"passive",{get:function(){Vi=!0}}),window.addEventListener("test",Et,Et),window.removeEventListener("test",Et,Et)}catch{Vi=!1}var br=null,Ju=null,Fi=null;function Qu(){if(Fi)return Fi;var s,a=Ju,l=a.length,c,m="value"in br?br.value:br.textContent,p=m.length;for(s=0;s<l&&a[s]===m[s];s++);var x=l-s;for(c=1;c<=x&&a[l-c]===m[p-c];c++);return Fi=m.slice(s,1<c?1-c:void 0)}function Gi(s){var a=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&a===13&&(s=13)):s=a,s===10&&(s=13),32<=s||s===13?s:0}function Kr(){return!0}function er(){return!1}function In(s){function a(l,c,m,p,x){this._reactName=l,this._targetInst=m,this.type=c,this.nativeEvent=p,this.target=x,this.currentTarget=null;for(var _ in s)s.hasOwnProperty(_)&&(l=s[_],this[_]=l?l(p):p[_]);return this.isDefaultPrevented=(p.defaultPrevented!=null?p.defaultPrevented:p.returnValue===!1)?Kr:er,this.isPropagationStopped=er,this}return b(a.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Kr)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Kr)},persist:function(){},isPersistent:Kr}),a}var Jr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},xr=In(Jr),ka=b({},Jr,{view:0,detail:0}),Yu=In(ka),La,Wl,Er,eo=b({},ka,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:ja,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==Er&&(Er&&s.type==="mousemove"?(La=s.screenX-Er.screenX,Wl=s.screenY-Er.screenY):Wl=La=0,Er=s),La)},movementY:function(s){return"movementY"in s?s.movementY:Wl}}),Xu=In(eo),Hi=b({},eo,{dataTransfer:0}),ZB=In(Hi),WB=b({},ka,{relatedTarget:0}),Ui=In(WB),$u=b({},Jr,{animationName:0,elapsedTime:0,pseudoElement:0}),eh=In($u),to=b({},Jr,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),th=In(to),nh=b({},Jr,{data:0}),_r=In(nh),sh={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},rh={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"},ah={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function ih(s){var a=this.nativeEvent;return a.getModifierState?a.getModifierState(s):(s=ah[s])?!!a[s]:!1}function ja(){return ih}var qn=b({},ka,{key:function(s){if(s.key){var a=sh[s.key]||s.key;if(a!=="Unidentified")return a}
vendor: 4,939 bytes, line 48
48return s.type==="keypress"?(s=Gi(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?rh[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:ja,charCode:function(s){return s.type==="keypress"?Gi(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?Gi(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),lh=In(qn),oh=b({},eo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Qr=In(oh),d=b({},ka,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:ja}),C=In(d),E=b({},Jr,{propertyName:0,elapsedTime:0,pseudoElement:0}),v=In(E),q=b({},eo,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),Z=In(q),Ee=b({},Jr,{newState:0,oldState:0}),Qe=In(Ee),en=[9,13,27,32],mt=Rs&&"CompositionEvent"in window,Ut=null;Rs&&"documentMode"in document&&(Ut=document.documentMode);var Os=Rs&&"TextEvent"in window&&!Ut,Dr=Rs&&(!mt||Ut&&8<Ut&&11>=Ut),tr=" ",nr=!1;function zi(s,a){switch(s){case"keyup":return en.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function no(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var so=!1;function hw(s,a){switch(s){case"compositionend":return no(a);case"keypress":return a.which!==32?null:(nr=!0,tr);case"textInput":return s=a.data,s===tr&&nr?null:s;default:return null}}function dw(s,a){if(so)return s==="compositionend"||!mt&&zi(s,a)?(s=Qu(),Fi=Ju=br=null,so=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1<a.char.length)return a.char;if(a.which)return String.fromCharCode(a.which)}return null;case"compositionend":return Dr&&a.locale!=="ko"?null:a.data;default:return null}}var fw={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 C0(s){var a=s&&s.nodeName&&s.nodeName.toLowerCase();return a==="input"?!!fw[s.type]:a==="textarea"}function y0(s,a,l,c){Ra?yr?yr.push(c):yr=[c]:Ra=c,a=$h(a,"onChange"),0<a.length&&(l=new xr("onChange","change",null,l,c),s.push({event:l,listeners:a}))}var Zu=null,Wu=null;function mw(s){tx(s,0)}function uh(s){var a=Bs(s);if(ji(a))return s}function b0(s,a){if(s==="change")return a}var x0=!1;if(Rs){var Qf;if(Rs){var Yf="oninput"in document;if(!Yf){var E0=document.createElement("div");E0.setAttribute("oninput","return;"),Yf=typeof E0.oninput=="function"}Qf=Yf}else Qf=!1;x0=Qf&&(!document.documentMode||9<document.documentMode)}function _0(){Zu&&(Zu.detachEvent("onpropertychange",D0),Wu=Zu=null)}function D0(s){if(s.propertyName==="value"&&uh(Wu)){var a=[];y0(a,Wu,s,Ss(s)),Oa(mw,a)}}function pw(s,a,l){s==="focusin"?(_0(),Zu=a,Wu=l,Zu.attachEvent("onpropertychange",D0)):s==="focusout"&&_0()}function gw(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return uh(Wu)}function Cw(s,a){if(s==="click")return uh(a)}function yw(s,a){if(s==="input"||s==="change")return uh(a)}function bw(s,a){return s===a&&(s!==0||1/s===1/a)||s!==s&&a!==a}var ds=typeof Object.is=="function"?Object.is:bw;function ec(s,a){if(ds(s,a))return!0;if(typeof s!="object"||s===null||typeof a!="object"||a===null)return!1;var l=Object.keys(s),c=Object.keys(a);if(l.length!==c.length)return!1;for(c=0;c<l.length;c++){var m=l[c];if(!Kt.call(a,m)||!ds(s[m],a[m]))return!1}return!0}function v0(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function w0(s,a){var l=v0(s);s=0;for(var c;l;){if(l.nodeType===3){if(c=s+l.textContent.length,s<=a&&c>=a)return{node:l,offset:a-s};s=c}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=v0(l)}}function T0(s,a){return s&&a?s===a?!0:s&&s.nodeType===3?!1:a&&a.nodeType===3?T0(s,a.parentNode):"contains"in s?s.contains(a):s.compareDocumentPosition?!!(s.compareDocumentPosition(a)&16):!1:!1}function A0(s){s=s!=null&&s.ownerDocument!=null&&s.ownerDocument.defaultView!=null?s.ownerDocument.defaultView:window;for(var a=Cr(s.document);a instanceof s.HTMLIFrameElement;){try{var l=typeof a.contentWindow.location.href=="string"}catch{l=!1}if(l)s=a.contentWindow;else break;a=Cr(s.document)}return a}function Xf(s){var a=s&&s.nodeName&&s.nodeName.toLowerCase();return a&&(a==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||a==="textarea"||s.contentEditable==="true")}var xw=Rs&&"documentMode"in document&&11>=document.documentMode,ro=null,$f=null,tc=null,Zf=!1;function N0(s,a,l){var c=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;
vendor: 22,577 bytes, line 48
48Zf||ro==null||ro!==Cr(c)||(c=ro,"selectionStart"in c&&Xf(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset}),tc&&ec(tc,c)||(tc=c,c=$h($f,"onSelect"),0<c.length&&(a=new xr("onSelect","select",null,a,l),s.push({event:a,listeners:c}),a.target=ro)))}function qi(s,a){var l={};return l[s.toLowerCase()]=a.toLowerCase(),l["Webkit"+s]="webkit"+a,l["Moz"+s]="moz"+a,l}var ao={animationend:qi("Animation","AnimationEnd"),animationiteration:qi("Animation","AnimationIteration"),animationstart:qi("Animation","AnimationStart"),transitionrun:qi("Transition","TransitionRun"),transitionstart:qi("Transition","TransitionStart"),transitioncancel:qi("Transition","TransitionCancel"),transitionend:qi("Transition","TransitionEnd")},Wf={},I0={};Rs&&(I0=document.createElement("div").style,"AnimationEvent"in window||(delete ao.animationend.animation,delete ao.animationiteration.animation,delete ao.animationstart.animation),"TransitionEvent"in window||delete ao.transitionend.transition);function Ki(s){if(Wf[s])return Wf[s];if(!ao[s])return s;var a=ao[s],l;for(l in a)if(a.hasOwnProperty(l)&&l in I0)return Wf[s]=a[l];return s}var S0=Ki("animationend"),R0=Ki("animationiteration"),O0=Ki("animationstart"),Ew=Ki("transitionrun"),_w=Ki("transitionstart"),Dw=Ki("transitioncancel"),k0=Ki("transitionend"),L0=new Map,em="abort auxClick beforeToggle 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(" ");em.push("scrollEnd");function sr(s,a){L0.set(s,a),pr(a,[s])}var ch=typeof reportError=="function"?reportError:function(s){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof s=="object"&&s!==null&&typeof s.message=="string"?String(s.message):String(s),error:s});if(!window.dispatchEvent(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",s);return}console.error(s)},ks=[],io=0,tm=0;function Bh(){for(var s=io,a=tm=io=0;a<s;){var l=ks[a];ks[a++]=null;var c=ks[a];ks[a++]=null;var m=ks[a];ks[a++]=null;var p=ks[a];if(ks[a++]=null,c!==null&&m!==null){var x=c.pending;x===null?m.next=m:(m.next=x.next,x.next=m),c.pending=m}p!==0&&j0(l,m,p)}}function hh(s,a,l,c){ks[io++]=s,ks[io++]=a,ks[io++]=l,ks[io++]=c,tm|=c,s.lanes|=c,s=s.alternate,s!==null&&(s.lanes|=c)}function nm(s,a,l,c){return hh(s,a,l,c),dh(s)}function Ji(s,a){return hh(s,null,null,a),dh(s)}function j0(s,a,l){s.lanes|=l;var c=s.alternate;c!==null&&(c.lanes|=l);for(var m=!1,p=s.return;p!==null;)p.childLanes|=l,c=p.alternate,c!==null&&(c.childLanes|=l),p.tag===22&&(s=p.stateNode,s===null||s._visibility&1||(m=!0)),s=p,p=p.return;return s.tag===3?(p=s.stateNode,m&&a!==null&&(m=31-Ht(l),s=p.hiddenUpdates,c=s[m],c===null?s[m]=[a]:c.push(a),a.lane=l|536870912),p):null}function dh(s){if(50<_c)throw _c=0,Bp=null,Error(n(185));for(var a=s.return;a!==null;)s=a,a=s.return;return s.tag===3?s.stateNode:null}var lo={};function vw(s,a,l,c){this.tag=s,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function fs(s,a,l,c){return new vw(s,a,l,c)}function sm(s){return s=s.prototype,!(!s||!s.isReactComponent)}function Yr(s,a){var l=s.alternate;return l===null?(l=fs(s.tag,a,s.key,s.mode),l.elementType=s.elementType,l.type=s.type,l.stateNode=s.stateNode,l.alternate=s,s.alternate=l):(l.pendingProps=a,l.type=s.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=s.flags&65011712,l.childLanes=s.childLanes,l.lanes=s.lanes,l.child=s.child,l.memoizedProps=s.memoizedProps,l.memoizedState=s.memoizedState,l.updateQueue=s.updateQueue,a=s.dependencies,l.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},l.sibling=s.sibling,l.index=s.index,l.ref=s.ref,l.refCleanup=s.refCleanup,l}function M0(s,a){s.flags&=65011714;var l=s.alternate;return l===null?(s.childLanes=0,s.lanes=a,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=l.childLanes,s.lanes=l.lanes,s.child=l.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=l.memoizedProps,s.memoizedState=l.memoizedState,s.updateQueue=l.updateQueue,s.type=l.type,a=l.dependencies,s.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext}),s}function fh(s,a,l,c,m,p){var x=0;if(c=s,typeof s=="function")sm(s)&&(x=1);else if(typeof s=="string")x=IT(s,l,Ae.current)?26:s==="html"||s==="head"||s==="body"?27:5;else e:switch(s){case k:return s=fs(31,l,a,m),s.elementType=k,s.lanes=p,s;case z:return Qi(l.children,m,p,a);case W:x=8,m|=24;break;case K:return s=fs(12,l,a,m|2),s.elementType=K,s.lanes=p,s;case _e:return s=fs(13,l,a,m),s.elementType=_e,s.lanes=p,s;case ye:return s=fs(19,l,a,m),s.elementType=ye,s.lanes=p,s;default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case de:x=10;break e;case he:x=9;break e;case ce:x=11;break e;case S:x=14;break e;case A:x=16,c=null;break e}x=29,l=Error(n(130,s===null?"null":typeof s,"")),c=null}return a=fs(x,l,a,m),a.elementType=s,a.type=c,a.lanes=p,a}function Qi(s,a,l,c){return s=fs(7,s,c,a),s.lanes=l,s}function rm(s,a,l){return s=fs(6,s,null,a),s.lanes=l,s}function P0(s){var a=fs(18,null,null,0);return a.stateNode=s,a}function am(s,a,l){return a=fs(4,s.children!==null?s.children:[],s.key,a),a.lanes=l,a.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},a}var V0=new WeakMap;function Ls(s,a){if(typeof s=="object"&&s!==null){var l=V0.get(s);return l!==void 0?l:(a={value:s,source:a,stack:va(a)},V0.set(s,a),a)}return{value:s,source:a,stack:va(a)}}var oo=[],uo=0,mh=null,nc=0,js=[],Ms=0,Ma=null,vr=1,wr="";function Xr(s,a){oo[uo++]=nc,oo[uo++]=mh,mh=s,nc=a}function F0(s,a,l){js[Ms++]=vr,js[Ms++]=wr,js[Ms++]=Ma,Ma=s;var c=vr;s=wr;var m=32-Ht(c)-1;c&=~(1<<m),l+=1;var p=32-Ht(a)+m;if(30<p){var x=m-m%5;p=(c&(1<<x)-1).toString(32),c>>=x,m-=x,vr=1<<32-Ht(a)+m|l<<m|c,wr=p+s}else vr=1<<p|l<<m|c,wr=s}function im(s){s.return!==null&&(Xr(s,1),F0(s,1,0))}function lm(s){for(;s===mh;)mh=oo[--uo],oo[uo]=null,nc=oo[--uo],oo[uo]=null;for(;s===Ma;)Ma=js[--Ms],js[Ms]=null,wr=js[--Ms],js[Ms]=null,vr=js[--Ms],js[Ms]=null}function G0(s,a){js[Ms++]=vr,js[Ms++]=wr,js[Ms++]=Ma,vr=a.id,wr=a.overflow,Ma=s}var Sn=null,jt=null,rt=!1,Pa=null,Ps=!1,om=Error(n(519));function Va(s){var a=Error(n(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw sc(Ls(a,s)),om}function H0(s){var a=s.stateNode,l=s.type,c=s.memoizedProps;switch(a[ln]=s,a[Dn]=c,l){case"dialog":tt("cancel",a),tt("close",a);break;case"iframe":case"object":case"embed":tt("load",a);break;case"video":case"audio":for(l=0;l<vc.length;l++)tt(vc[l],a);break;case"source":tt("error",a);break;case"img":case"image":case"link":tt("error",a),tt("load",a);break;case"details":tt("toggle",a);break;case"input":tt("invalid",a),QB(a,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0);break;case"select":tt("invalid",a);break;case"textarea":tt("invalid",a),Ia(a,c.value,c.defaultValue,c.children)}l=c.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||a.textContent===""+l||c.suppressHydrationWarning===!0||ax(a.textContent,l)?(c.popover!=null&&(tt("beforetoggle",a),tt("toggle",a)),c.onScroll!=null&&tt("scroll",a),c.onScrollEnd!=null&&tt("scrollend",a),c.onClick!=null&&(a.onclick=Zs),a=!0):a=!1,a||Va(s,!0)}function U0(s){for(Sn=s.return;Sn;)switch(Sn.tag){case 5:case 31:case 13:Ps=!1;return;case 27:case 3:Ps=!0;return;default:Sn=Sn.return}}function co(s){if(s!==Sn)return!1;if(!rt)return U0(s),rt=!0,!1;var a=s.tag,l;if((l=a!==3&&a!==27)&&((l=a===5)&&(l=s.type,l=!(l!=="form"&&l!=="button")||wp(s.type,s.memoizedProps)),l=!l),l&&jt&&Va(s),U0(s),a===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(n(317));jt=fx(s)}else if(a===31){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(n(317));jt=fx(s)}else a===27?(a=jt,Wa(s.type)?(s=Sp,Sp=null,jt=s):jt=a):jt=Sn?Fs(s.stateNode.nextSibling):null;return!0}function Yi(){jt=Sn=null,rt=!1}function um(){var s=Pa;return s!==null&&(ns===null?ns=s:ns.push.apply(ns,s),Pa=null),s}function sc(s){Pa===null?Pa=[s]:Pa.push(s)}var cm=P(null),Xi=null,$r=null;function Fa(s,a,l){xe(cm,a._currentValue),a._currentValue=l}function Zr(s){s._currentValue=cm.current,ae(cm)}function Bm(s,a,l){for(;s!==null;){var c=s.alternate;if((s.childLanes&a)!==a?(s.childLanes|=a,c!==null&&(c.childLanes|=a)):c!==null&&(c.childLanes&a)!==a&&(c.childLanes|=a),s===l)break;s=s.return}}function hm(s,a,l,c){var m=s.child;for(m!==null&&(m.return=s);m!==null;){var p=m.dependencies;if(p!==null){var x=m.child;p=p.firstContext;e:for(;p!==null;){var _=p;p=m;for(var j=0;j<a.length;j++)if(_.context===a[j]){p.lanes|=l,_=p.alternate,_!==null&&(_.lanes|=l),Bm(p.return,l,s),c||(x=null);break e}p=_.next}}else if(m.tag===18){if(x=m.return,x===null)throw Error(n(341));x.lanes|=l,p=x.alternate,p!==null&&(p.lanes|=l),Bm(x,l,s),x=null}else x=m.child;if(x!==null)x.return=m;else for(x=m;x!==null;){if(x===s){x=null;break}if(m=x.sibling,m!==null){m.return=x.return,x=m;break}x=x.return}m=x}}function Bo(s,a,l,c){s=null;for(var m=a,p=!1;m!==null;){if(!p){if((m.flags&524288)!==0)p=!0;else if((m.flags&262144)!==0)break}if(m.tag===10){var x=m.alternate;if(x===null)throw Error(n(387));if(x=x.memoizedProps,x!==null){var _=m.type;ds(m.pendingProps.value,x.value)||(s!==null?s.push(_):s=[_])}}else if(m===We.current){if(x=m.alternate,x===null)throw Error(n(387));x.memoizedState.memoizedState!==m.memoizedState.memoizedState&&(s!==null?s.push(Ic):s=[Ic])}m=m.return}s!==null&&hm(a,s,l,c),a.flags|=262144}function ph(s){for(s=s.firstContext;s!==null;){if(!ds(s.context._currentValue,s.memoizedValue))return!0;s=s.next}return!1}function $i(s){Xi=s,$r=null,s=s.dependencies,s!==null&&(s.firstContext=null)}function Rn(s){return z0(Xi,s)}function gh(s,a){return Xi===null&&$i(s),z0(s,a)}function z0(s,a){var l=a._currentValue;if(a={context:a,memoizedValue:l,next:null},$r===null){if(s===null)throw Error(n(308));$r=a,s.dependencies={lanes:0,firstContext:a},s.flags|=524288}else $r=$r.next=a;return l}var ww=typeof AbortController<"u"?AbortController:function(){var s=[],a=this.signal={aborted:!1,addEventListener:function(l,c){s.push(c)}};this.abort=function(){a.aborted=!0,s.forEach(function(l){return l()})}},Tw=r.unstable_scheduleCallback,Aw=r.unstable_NormalPriority,cn={$$typeof:de,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function dm(){return{controller:new ww,data:new Map,refCount:0}}function rc(s){s.refCount--,s.refCount===0&&Tw(Aw,function(){s.controller.abort()})}var ac=null,fm=0,ho=0,fo=null;function Nw(s,a){if(ac===null){var l=ac=[];fm=0,ho=gp(),fo={status:"pending",value:void 0,then:function(c){l.push(c)}}}return fm++,a.then(q0,q0),a}function q0(){if(--fm===0&&ac!==null){fo!==null&&(fo.status="fulfilled");var s=ac;ac=null,ho=0,fo=null;for(var a=0;a<s.length;a++)(0,s[a])()}}function Iw(s,a){var l=[],c={status:"pending",value:null,reason:null,then:function(m){l.push(m)}};return s.then(function(){c.status="fulfilled",c.value=a;for(var m=0;m<l.length;m++)(0,l[m])(a)},function(m){for(c.status="rejected",c.reason=m,m=0;m<l.length;m++)(0,l[m])(void 0)}),c}var K0=$.S;$.S=function(s,a){Nb=En(),typeof a=="object"&&a!==null&&typeof a.then=="function"&&Nw(s,a),K0!==null&&K0(s,a)};var Zi=P(null);function mm(){var s=Zi.current;return s!==null?s:Nt.pooledCache}function Ch(s,a){a===null?xe(Zi,Zi.current):xe(Zi,a.pool)}function J0(){var s=mm();return s===null?null:{parent:cn._currentValue,pool:s}}var mo=Error(n(460)),pm=Error(n(474)),yh=Error(n(542)),bh={then:function(){}};function Q0(s){return s=s.status,s==="fulfilled"||s==="rejected"}function Y0(s,a,l){switch(l=s[l],l===void 0?s.push(a):l!==a&&(a.then(Zs,Zs),a=l),a.status){case"fulfilled":return a.value;case"rejected":throw s=a.reason,$0(s),s;default:if(typeof a.status=="string")a.then(Zs,Zs);else{if(s=Nt,s!==null&&100<s.shellSuspendCounter)throw Error(n(482));s=a,s.status="pending",s.then(function(c){if(a.status==="pending"){var m=a;m.status="fulfilled",m.value=c}},function(c){if(a.status==="pending"){var m=a;m.status="rejected",m.reason=c}})}switch(a.status){case"fulfilled":return a.value;case"rejected":throw s=a.reason,$0(s),s}throw el=a,mo}}function Wi(s){try{var a=s._init;return a(s._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(el=l,mo):l}}var el=null;function X0(){if(el===null)throw Error(n(459));var s=el;return el=null,s}function $0(s){if(s===mo||s===yh)throw Error(n(483))}var po=null,ic=0;function xh(s){var a=ic;return ic+=1,po===null&&(po=[]),Y0(po,s,a)}function lc(s,a){a=a.props.ref,s.ref=a!==void 0?a:null}function Eh(s,a){throw a.$$typeof===D?Error(n(525)):(s=Object.prototype.toString.call(a),Error(n(31,s==="[object Object]"?"object with keys {"+Object.keys(a).join(", ")+"}":s)))}function Z0(s){function a(H,V){if(s){var J=H.deletions;J===null?(H.deletions=[V],H.flags|=16):J.push(V)}}function l(H,V){if(!s)return null;for(;V!==null;)a(H,V),V=V.sibling;return null}function c(H){for(var V=new Map;H!==null;)H.key!==null?V.set(H.key,H):V.set(H.index,H),H=H.sibling;return V}function m(H,V){return H=Yr(H,V),H.index=0,H.sibling=null,H}function p(H,V,J){return H.index=J,s?(J=H.alternate,J!==null?(J=J.index,J<V?(H.flags|=67108866,V):J):(H.flags|=67108866,V)):(H.flags|=1048576,V)}function x(H){return s&&H.alternate===null&&(H.flags|=67108866),H}function _(H,V,J,ie){return V===null||V.tag!==6?(V=rm(J,H.mode,ie),V.return=H,V):(V=m(V,J),V.return=H,V)}function j(H,V,J,ie){var Pe=J.type;return Pe===z?re(H,V,J.props.children,ie,J.key):V!==null&&(V.elementType===Pe||typeof Pe=="object"&&Pe!==null&&Pe.$$typeof===A&&Wi(Pe)===V.type)?(V=m(V,J.props),lc(V,J),V.return=H,V):(V=fh(J.type,J.key,J.props,null,H.mode,ie),lc(V,J),V.return=H,V)}function Q(H,V,J,ie){return V===null||V.tag!==4||V.stateNode.containerInfo!==J.containerInfo||V.stateNode.implementation!==J.implementation?(V=am(J,H.mode,ie),V.return=H,V):(V=m(V,J.children||[]),V.return=H,V)}function re(H,V,J,ie,Pe){return V===null||V.tag!==7?(V=Qi(J,H.mode,ie,Pe),V.return=H,V):(V=m(V,J),V.return=H,V)}function oe(H,V,J){if(typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint")return V=rm(""+V,H.mode,J),V.return=H,V;if(typeof V=="object"&&V!==null){switch(V.$$typeof){case T:return J=fh(V.type,V.key,V.props,null,H.mode,J),lc(J,V),J.return=H,J;case M:return V=am(V,H.mode,J),V.return=H,V;case A:return V=Wi(V),oe(H,V,J)}if(Bt(V)||L(V))return V=Qi(V,H.mode,J,null),V.return=H,V;if(typeof V.then=="function")return oe(H,xh(V),J);if(V.$$typeof===de)return oe(H,gh(H,V),J);Eh(H,V)}return null}function X(H,V,J,ie){var Pe=V!==null?V.key:null;if(typeof J=="string"&&J!==""||typeof J=="number"||typeof J=="bigint")return Pe!==null?null:_(H,V,""+J,ie);if(typeof J=="object"&&J!==null){switch(J.$$typeof){case T:return J.key===Pe?j(H,V,J,ie):null;case M:return J.key===Pe?Q(H,V,J,ie):null;case A:return J=Wi(J),X(H,V,J,ie)}if(Bt(J)||L(J))return Pe!==null?null:re(H,V,J,ie,null);if(typeof J.then=="function")return X(H,V,xh(J),ie);if(J.$$typeof===de)return X(H,V,gh(H,J),ie);Eh(H,J)}return null}function ee(H,V,J,ie,Pe){if(typeof ie=="string"&&ie!==""||typeof ie=="number"||typeof ie=="bigint")return H=H.get(J)||null,_(V,H,""+ie,Pe);if(typeof ie=="object"&&ie!==null){switch(ie.$$typeof){case T:return H=H.get(ie.key===null?J:ie.key)||null,j(V,H,ie,Pe);case M:return H=H.get(ie.key===null?J:ie.key)||null,Q(V,H,ie,Pe);case A:return ie=Wi(ie),ee(H,V,J,ie,Pe)}if(Bt(ie)||L(ie))return H=H.get(J)||null,re(V,H,ie,Pe,null);if(typeof ie.then=="function")return ee(H,V,J,xh(ie),Pe);if(ie.$$typeof===de)return ee(H,V,J,gh(V,ie),Pe);Eh(V,ie)}return null}function Ne(H,V,J,ie){for(var Pe=null,dt=null,Oe=V,$e=V=0,st=null;Oe!==null&&$e<J.length;$e++){Oe.index>$e?(st=Oe,Oe=null):st=Oe.sibling;var ft=X(H,Oe,J[$e],ie);if(ft===null){Oe===null&&(Oe=st);break}s&&Oe&&ft.alternate===null&&a(H,Oe),V=p(ft,V,$e),dt===null?Pe=ft:dt.sibling=ft,dt=ft,Oe=st}if($e===J.length)return l(H,Oe),rt&&Xr(H,$e),Pe;if(Oe===null){for(;$e<J.length;$e++)Oe=oe(H,J[$e],ie),Oe!==null&&(V=p(Oe,V,$e),dt===null?Pe=Oe:dt.sibling=Oe,dt=Oe);return rt&&Xr(H,$e),Pe}for(Oe=c(Oe);$e<J.length;$e++)st=ee(Oe,H,$e,J[$e],ie),st!==null&&(s&&st.alternate!==null&&Oe.delete(st.key===null?$e:st.key),V=p(st,V,$e),dt===null?Pe=st:dt.sibling=st,dt=st);return s&&Oe.forEach(function(ri){return a(H,ri)}),rt&&Xr(H,$e),Pe}function Ve(H,V,J,ie){if(J==null)throw Error(n(151));for(var Pe=null,dt=null,Oe=V,$e=V=0,st=null,ft=J.next();Oe!==null&&!ft.done;$e++,ft=J.next()){Oe.index>$e?(st=Oe,Oe=null):st=Oe.sibling;var ri=X(H,Oe,ft.value,ie);if(ri===null){Oe===null&&(Oe=st);break}s&&Oe&&ri.alternate===null&&a(H,Oe),V=p(ri,V,$e),dt===null?Pe=ri:dt.sibling=ri,dt=ri,Oe=st}if(ft.done)return l(H,Oe),rt&&Xr(H,$e),Pe;if(Oe===null){for(;!ft.done;$e++,ft=J.next())ft=oe(H,ft.value,ie),ft!==null&&(V=p(ft,V,$e),dt===null?Pe=ft:dt.sibling=ft,dt=ft);return rt&&Xr(H,$e),Pe}for(Oe=c(Oe);!ft.done;$e++,ft=J.next())ft=ee(Oe,H,$e,ft.value,ie),ft!==null&&(s&&ft.alternate!==null&&Oe.delete(ft.key===null?$e:ft.key),V=p(ft,V,$e),dt===null?Pe=ft:dt.sibling=ft,dt=ft);return s&&Oe.forEach(function(GT){return a(H,GT)}),rt&&Xr(H,$e),Pe}function vt(H,V,J,ie){if(typeof J=="object"&&J!==null&&J.type===z&&J.key===null&&(J=J.props.children),typeof J=="object"&&J!==null){switch(J.$$typeof){case T:e:{for(var Pe=J.key;V!==null;){if(V.key===Pe){if(Pe=J.type,Pe===z){if(V.tag===7){l(H,V.sibling),ie=m(V,J.props.children),ie.return=H,H=ie;break e}}else if(V.elementType===Pe||typeof Pe=="object"&&Pe!==null&&Pe.$$typeof===A&&Wi(Pe)===V.type){l(H,V.sibling),ie=m(V,J.props),lc(ie,J),ie.return=H,H=ie;break e}l(H,V);break}else a(H,V);V=V.sibling}J.type===z?(ie=Qi(J.props.children,H.mode,ie,J.key),ie.return=H,H=ie):(ie=fh(J.type,J.key,J.props,null,H.mode,ie),lc(ie,J),ie.return=H,H=ie)}return x(H);case M:e:{for(Pe=J.key;V!==null;){if(V.key===Pe)if(V.tag===4&&V.stateNode.containerInfo===J.containerInfo&&V.stateNode.implementation===J.implementation){l(H,V.sibling),ie=m(V,J.children||[]),ie.return=H,H=ie;break e}else{l(H,V);break}else a(H,V);V=V.sibling}ie=am(J,H.mode,ie),ie.return=H,H=ie}return x(H);case A:return J=Wi(J),vt(H,V,J,ie)}if(Bt(J))return Ne(H,V,J,ie);if(L(J)){if(Pe=L(J),typeof Pe!="function")throw Error(n(150));return J=Pe.call(J),Ve(H,V,J,ie)}if(typeof J.then=="function")return vt(H,V,xh(J),ie);if(J.$$typeof===de)return vt(H,V,gh(H,J),ie);Eh(H,J)}return typeof J=="string"&&J!==""||typeof J=="number"||typeof J=="bigint"?(J=""+J,V!==null&&V.tag===6?(l(H,V.sibling),ie=m(V,J),ie.return=H,H=ie):(l(H,V),ie=rm(J,H.mode,ie),ie.return=H,H=ie),x(H)):l(H,V)}return function(H,V,J,ie){try{ic=0;var Pe=vt(H,V,J,ie);return po=null,Pe}catch(Oe){if(Oe===mo||Oe===yh)throw Oe;var dt=fs(29,Oe,null,H.mode);return dt.lanes=ie,dt.return=H,dt}finally{}}}var tl=Z0(!0),W0=Z0(!1),Ga=!1;function gm(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Cm(s,a){s=s.updateQueue,a.updateQueue===s&&(a.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,callbacks:null})}function Ha(s){return{lane:s,tag:0,payload:null,callback:null,next:null}}function Ua(s,a,l){var c=s.updateQueue;if(c===null)return null;if(c=c.shared,(pt&2)!==0){var m=c.pending;return m===null?a.next=a:(a.next=m.next,m.next=a),c.pending=a,a=dh(s),j0(s,null,l),a}return hh(s,c,a,l),dh(s)}function oc(s,a,l){if(a=a.updateQueue,a!==null&&(a=a.shared,(l&4194048)!==0)){var c=a.lanes;c&=s.pendingLanes,l|=c,a.lanes=l,Lu(s,l)}}function ym(s,a){var l=s.updateQueue,c=s.alternate;if(c!==null&&(c=c.updateQueue,l===c)){var m=null,p=null;if(l=l.firstBaseUpdate,l!==null){do{var x={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};p===null?m=p=x:p=p.next=x,l=l.next}while(l!==null);p===null?m=p=a:p=p.next=a}else m=p=a;l={baseState:c.baseState,firstBaseUpdate:m,lastBaseUpdate:p,shared:c.shared,callbacks:c.callbacks},s.updateQueue=l;return}s=l.lastBaseUpdate,s===null?l.firstBaseUpdate=a:s.next=a,l.lastBaseUpdate=a}var bm=!1;function uc(){if(bm){var s=fo;if(s!==null)throw s}}function cc(s,a,l,c){bm=!1;var m=s.updateQueue;Ga=!1;var p=m.firstBaseUpdate,x=m.lastBaseUpdate,_=m.shared.pending;if(_!==null){m.shared.pending=null;var j=_,Q=j.next;j.next=null,x===null?p=Q:x.next=Q,x=j;var re=s.alternate;re!==null&&(re=re.updateQueue,_=re.lastBaseUpdate,_!==x&&(_===null?re.firstBaseUpdate=Q:_.next=Q,re.lastBaseUpdate=j))}if(p!==null){var oe=m.baseState;x=0,re=Q=j=null,_=p;do{var X=_.lane&-536870913,ee=X!==_.lane;if(ee?(nt&X)===X:(c&X)===X){X!==0&&X===ho&&(bm=!0),re!==null&&(re=re.next={lane:0,tag:_.tag,payload:_.payload,callback:null,next:null});e:{var Ne=s,Ve=_;X=a;var vt=l;switch(Ve.tag){case 1:if(Ne=Ve.payload,typeof Ne=="function"){oe=Ne.call(vt,oe,X);break e}oe=Ne;break e;case 3:Ne.flags=Ne.flags&-65537|128;case 0:if(Ne=Ve.payload,X=typeof Ne=="function"?Ne.call(vt,oe,X):Ne,X==null)break e;oe=b({},oe,X);break e;case 2:Ga=!0}}X=_.callback,X!==null&&(s.flags|=64,ee&&(s.flags|=8192),ee=m.callbacks,ee===null?m.callbacks=[X]:ee.push(X))}else ee={lane:X,tag:_.tag,payload:_.payload,callback:_.callback,next:null},re===null?(Q=re=ee,j=oe):re=re.next=ee,x|=X;if(_=_.next,_===null){if(_=m.shared.pending,_===null)break;ee=_,_=ee.next,ee.next=null,m.lastBaseUpdate=ee,m.shared.pending=null}}while(!0);re===null&&(j=oe),m.baseState=j,m.firstBaseUpdate=Q,m.lastBaseUpdate=re,p===null&&(m.shared.lanes=0),Qa|=x,s.lanes=x,s.memoizedState=oe}}function ey(s,a){if(typeof s!="function")throw Error(n(191,s));s.call(a)}function ty(s,a){var l=s.callbacks;
vendor: 4,476 bytes, line 48
48if(l!==null)for(s.callbacks=null,s=0;s<l.length;s++)ey(l[s],a)}var go=P(null),_h=P(0);function ny(s,a){s=la,xe(_h,s),xe(go,a),la=s|a.baseLanes}function xm(){xe(_h,la),xe(go,go.current)}function Em(){la=_h.current,ae(go),ae(_h)}var ms=P(null),Vs=null;function za(s){var a=s.alternate;xe(tn,tn.current&1),xe(ms,s),Vs===null&&(a===null||go.current!==null||a.memoizedState!==null)&&(Vs=s)}function _m(s){xe(tn,tn.current),xe(ms,s),Vs===null&&(Vs=s)}function sy(s){s.tag===22?(xe(tn,tn.current),xe(ms,s),Vs===null&&(Vs=s)):qa()}function qa(){xe(tn,tn.current),xe(ms,ms.current)}function ps(s){ae(ms),Vs===s&&(Vs=null),ae(tn)}var tn=P(0);function Dh(s){for(var a=s;a!==null;){if(a.tag===13){var l=a.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||Np(l)||Ip(l)))return a}else if(a.tag===19&&(a.memoizedProps.revealOrder==="forwards"||a.memoizedProps.revealOrder==="backwards"||a.memoizedProps.revealOrder==="unstable_legacy-backwards"||a.memoizedProps.revealOrder==="together")){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===s)break;for(;a.sibling===null;){if(a.return===null||a.return===s)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var Wr=0,Ye=null,_t=null,Bn=null,vh=!1,Co=!1,nl=!1,wh=0,Bc=0,yo=null,Sw=0;function Xt(){throw Error(n(321))}function Dm(s,a){if(a===null)return!1;for(var l=0;l<a.length&&l<s.length;l++)if(!ds(s[l],a[l]))return!1;return!0}function vm(s,a,l,c,m,p){return Wr=p,Ye=a,a.memoizedState=null,a.updateQueue=null,a.lanes=0,$.H=s===null||s.memoizedState===null?Fy:Fm,nl=!1,p=l(c,m),nl=!1,Co&&(p=ay(a,l,c,m)),ry(s),p}function ry(s){$.H=fc;var a=_t!==null&&_t.next!==null;if(Wr=0,Bn=_t=Ye=null,vh=!1,Bc=0,yo=null,a)throw Error(n(300));s===null||hn||(s=s.dependencies,s!==null&&ph(s)&&(hn=!0))}function ay(s,a,l,c){Ye=s;var m=0;do{if(Co&&(yo=null),Bc=0,Co=!1,25<=m)throw Error(n(301));if(m+=1,Bn=_t=null,s.updateQueue!=null){var p=s.updateQueue;p.lastEffect=null,p.events=null,p.stores=null,p.memoCache!=null&&(p.memoCache.index=0)}$.H=Gy,p=a(l,c)}while(Co);return p}function Rw(){var s=$.H,a=s.useState()[0];return a=typeof a.then=="function"?hc(a):a,s=s.useState()[0],(_t!==null?_t.memoizedState:null)!==s&&(Ye.flags|=1024),a}function wm(){var s=wh!==0;return wh=0,s}function Tm(s,a,l){a.updateQueue=s.updateQueue,a.flags&=-2053,s.lanes&=~l}function Am(s){if(vh){for(s=s.memoizedState;s!==null;){var a=s.queue;a!==null&&(a.pending=null),s=s.next}vh=!1}Wr=0,Bn=_t=Ye=null,Co=!1,Bc=wh=0,yo=null}function Kn(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bn===null?Ye.memoizedState=Bn=s:Bn=Bn.next=s,Bn}function nn(){if(_t===null){var s=Ye.alternate;s=s!==null?s.memoizedState:null}else s=_t.next;var a=Bn===null?Ye.memoizedState:Bn.next;if(a!==null)Bn=a,_t=s;else{if(s===null)throw Ye.alternate===null?Error(n(467)):Error(n(310));_t=s,s={memoizedState:_t.memoizedState,baseState:_t.baseState,baseQueue:_t.baseQueue,queue:_t.queue,next:null},Bn===null?Ye.memoizedState=Bn=s:Bn=Bn.next=s}return Bn}function Th(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function hc(s){var a=Bc;return Bc+=1,yo===null&&(yo=[]),s=Y0(yo,s,a),a=Ye,(Bn===null?a.memoizedState:Bn.next)===null&&(a=a.alternate,$.H=a===null||a.memoizedState===null?Fy:Fm),s}function Ah(s){if(s!==null&&typeof s=="object"){if(typeof s.then=="function")return hc(s);if(s.$$typeof===de)return Rn(s)}throw Error(n(438,String(s)))}function Nm(s){var a=null,l=Ye.updateQueue;if(l!==null&&(a=l.memoCache),a==null){var c=Ye.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(a={data:c.data.map(function(m){return m.slice()}),index:0})))}if(a==null&&(a={data:[],index:0}),l===null&&(l=Th(),Ye.updateQueue=l),l.memoCache=a,l=a.data[a.index],l===void 0)for(l=a.data[a.index]=Array(s),c=0;c<s;c++)l[c]=w;return a.index++,l}function ea(s,a){return typeof a=="function"?a(s):a}function Nh(s){var a=nn();return Im(a,_t,s)}function Im(s,a,l){var c=s.queue;if(c===null)throw Error(n(311));c.lastRenderedReducer=l;var m=s.baseQueue,p=c.pending;if(p!==null){if(m!==null){var x=m.next;m.next=p.next,p.next=x}a.baseQueue=m=p,c.pending=null}if(p=s.baseState,m===null)s.memoizedState=p;else{a=m.next;var _=x=null,j=null,Q=a,re=!1;do{var oe=Q.lane&-536870913;if(oe!==Q.lane?(nt&oe)===oe:(Wr&oe)===oe){var X=Q.revertLane;if(X===0)j!==null&&(j=j.next={lane:0,revertLane:0,gesture:null,action:Q.action,hasEagerState:Q.hasEagerState,eagerState:Q.eagerState,next:null}
vendor: 8,730 bytes, line 48
48),oe===ho&&(re=!0);else if((Wr&X)===X){Q=Q.next,X===ho&&(re=!0);continue}else oe={lane:0,revertLane:Q.revertLane,gesture:null,action:Q.action,hasEagerState:Q.hasEagerState,eagerState:Q.eagerState,next:null},j===null?(_=j=oe,x=p):j=j.next=oe,Ye.lanes|=X,Qa|=X;oe=Q.action,nl&&l(p,oe),p=Q.hasEagerState?Q.eagerState:l(p,oe)}else X={lane:oe,revertLane:Q.revertLane,gesture:Q.gesture,action:Q.action,hasEagerState:Q.hasEagerState,eagerState:Q.eagerState,next:null},j===null?(_=j=X,x=p):j=j.next=X,Ye.lanes|=oe,Qa|=oe;Q=Q.next}while(Q!==null&&Q!==a);if(j===null?x=p:j.next=_,!ds(p,s.memoizedState)&&(hn=!0,re&&(l=fo,l!==null)))throw l;s.memoizedState=p,s.baseState=x,s.baseQueue=j,c.lastRenderedState=p}return m===null&&(c.lanes=0),[s.memoizedState,c.dispatch]}function Sm(s){var a=nn(),l=a.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=s;var c=l.dispatch,m=l.pending,p=a.memoizedState;if(m!==null){l.pending=null;var x=m=m.next;do p=s(p,x.action),x=x.next;while(x!==m);ds(p,a.memoizedState)||(hn=!0),a.memoizedState=p,a.baseQueue===null&&(a.baseState=p),l.lastRenderedState=p}return[p,c]}function iy(s,a,l){var c=Ye,m=nn(),p=rt;if(p){if(l===void 0)throw Error(n(407));l=l()}else l=a();var x=!ds((_t||m).memoizedState,l);if(x&&(m.memoizedState=l,hn=!0),m=m.queue,km(uy.bind(null,c,m,s),[s]),m.getSnapshot!==a||x||Bn!==null&&Bn.memoizedState.tag&1){if(c.flags|=2048,bo(9,{destroy:void 0},oy.bind(null,c,m,l,a),null),Nt===null)throw Error(n(349));p||(Wr&127)!==0||ly(c,a,l)}return l}function ly(s,a,l){s.flags|=16384,s={getSnapshot:a,value:l},a=Ye.updateQueue,a===null?(a=Th(),Ye.updateQueue=a,a.stores=[s]):(l=a.stores,l===null?a.stores=[s]:l.push(s))}function oy(s,a,l,c){a.value=l,a.getSnapshot=c,cy(a)&&By(s)}function uy(s,a,l){return l(function(){cy(a)&&By(s)})}function cy(s){var a=s.getSnapshot;s=s.value;try{var l=a();return!ds(s,l)}catch{return!0}}function By(s){var a=Ji(s,2);a!==null&&ss(a,s,2)}function Rm(s){var a=Kn();if(typeof s=="function"){var l=s;if(s=l(),nl){zn(!0);try{l()}finally{zn(!1)}}}return a.memoizedState=a.baseState=s,a.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:s},a}function hy(s,a,l,c){return s.baseState=l,Im(s,_t,typeof c=="function"?c:ea)}function Ow(s,a,l,c,m){if(Rh(s))throw Error(n(485));if(s=a.action,s!==null){var p={payload:m,action:s,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(x){p.listeners.push(x)}};$.T!==null?l(!0):p.isTransition=!1,c(p),l=a.pending,l===null?(p.next=a.pending=p,dy(a,p)):(p.next=l.next,a.pending=l.next=p)}}function dy(s,a){var l=a.action,c=a.payload,m=s.state;if(a.isTransition){var p=$.T,x={};$.T=x;try{var _=l(m,c),j=$.S;j!==null&&j(x,_),fy(s,a,_)}catch(Q){Om(s,a,Q)}finally{p!==null&&x.types!==null&&(p.types=x.types),$.T=p}}else try{p=l(m,c),fy(s,a,p)}catch(Q){Om(s,a,Q)}}function fy(s,a,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(c){my(s,a,c)},function(c){return Om(s,a,c)}):my(s,a,l)}function my(s,a,l){a.status="fulfilled",a.value=l,py(a),s.state=l,a=s.pending,a!==null&&(l=a.next,l===a?s.pending=null:(l=l.next,a.next=l,dy(s,l)))}function Om(s,a,l){var c=s.pending;if(s.pending=null,c!==null){c=c.next;do a.status="rejected",a.reason=l,py(a),a=a.next;while(a!==c)}s.action=null}function py(s){s=s.listeners;for(var a=0;a<s.length;a++)(0,s[a])()}function gy(s,a){return a}function Cy(s,a){if(rt){var l=Nt.formState;if(l!==null){e:{var c=Ye;if(rt){if(jt){t:{for(var m=jt,p=Ps;m.nodeType!==8;){if(!p){m=null;break t}if(m=Fs(m.nextSibling),m===null){m=null;break t}}p=m.data,m=p==="F!"||p==="F"?m:null}if(m){jt=Fs(m.nextSibling),c=m.data==="F!";break e}}Va(c)}c=!1}c&&(a=l[0])}}return l=Kn(),l.memoizedState=l.baseState=a,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:gy,lastRenderedState:a},l.queue=c,l=My.bind(null,Ye,c),c.dispatch=l,c=Rm(!1),p=Vm.bind(null,Ye,!1,c.queue),c=Kn(),m={state:a,dispatch:null,action:s,pending:null},c.queue=m,l=Ow.bind(null,Ye,m,p,l),m.dispatch=l,c.memoizedState=s,[a,l,!1]}function yy(s){var a=nn();return by(a,_t,s)}function by(s,a,l){if(a=Im(s,a,gy)[0],s=Nh(ea)[0],typeof a=="object"&&a!==null&&typeof a.then=="function")try{var c=hc(a)}catch(x){throw x===mo?yh:x}else c=a;a=nn();var m=a.queue,p=m.dispatch;return l!==a.memoizedState&&(Ye.flags|=2048,bo(9,{destroy:void 0},kw.bind(null,m,l),null)),[c,p,s]}function kw(s,a){s.action=a}function xy(s){var a=nn(),l=_t;if(l!==null)return by(a,l,s);nn(),a=a.memoizedState,l=nn();var c=l.queue.dispatch;return l.memoizedState=s,[a,c,!1]}function bo(s,a,l,c){return s={tag:s,create:l,deps:c,inst:a,next:null},a=Ye.updateQueue,a===null&&(a=Th(),Ye.updateQueue=a),l=a.lastEffect,l===null?a.lastEffect=s.next=s:(c=l.next,l.next=s,s.next=c,a.lastEffect=s),s}function Ey(){return nn().memoizedState}function Ih(s,a,l,c){var m=Kn();Ye.flags|=s,m.memoizedState=bo(1|a,{destroy:void 0},l,c===void 0?null:c)}function Sh(s,a,l,c){var m=nn();c=c===void 0?null:c;var p=m.memoizedState.inst;_t!==null&&c!==null&&Dm(c,_t.memoizedState.deps)?m.memoizedState=bo(a,p,l,c):(Ye.flags|=s,m.memoizedState=bo(1|a,p,l,c))}function _y(s,a){Ih(8390656,8,s,a)}function km(s,a){Sh(2048,8,s,a)}function Lw(s){Ye.flags|=4;var a=Ye.updateQueue;if(a===null)a=Th(),Ye.updateQueue=a,a.events=[s];else{var l=a.events;l===null?a.events=[s]:l.push(s)}}function Dy(s){var a=nn().memoizedState;return Lw({ref:a,nextImpl:s}),function(){if((pt&2)!==0)throw Error(n(440));return a.impl.apply(void 0,arguments)}}function vy(s,a){return Sh(4,2,s,a)}function wy(s,a){return Sh(4,4,s,a)}function Ty(s,a){if(typeof a=="function"){s=s();var l=a(s);return function(){typeof l=="function"?l():a(null)}}if(a!=null)return s=s(),a.current=s,function(){a.current=null}}function Ay(s,a,l){l=l!=null?l.concat([s]):null,Sh(4,4,Ty.bind(null,a,s),l)}function Lm(){}function Ny(s,a){var l=nn();a=a===void 0?null:a;var c=l.memoizedState;return a!==null&&Dm(a,c[1])?c[0]:(l.memoizedState=[s,a],s)}function Iy(s,a){var l=nn();a=a===void 0?null:a;var c=l.memoizedState;if(a!==null&&Dm(a,c[1]))return c[0];if(c=s(),nl){zn(!0);try{s()}finally{zn(!1)}}return l.memoizedState=[c,a],c}function jm(s,a,l){return l===void 0||(Wr&1073741824)!==0&&(nt&261930)===0?s.memoizedState=a:(s.memoizedState=l,s=Sb(),Ye.lanes|=s,Qa|=s,l)}function Sy(s,a,l,c){return ds(l,a)?l:go.current!==null?(s=jm(s,l,c),ds(s,a)||(hn=!0),s):(Wr&42)===0||(Wr&1073741824)!==0&&(nt&261930)===0?(hn=!0,s.memoizedState=l):(s=Sb(),Ye.lanes|=s,Qa|=s,a)}function Ry(s,a,l,c,m){var p=pe.p;pe.p=p!==0&&8>p?p:8;var x=$.T,_={};$.T=_,Vm(s,!1,a,l);try{var j=m(),Q=$.S;if(Q!==null&&Q(_,j),j!==null&&typeof j=="object"&&typeof j.then=="function"){var re=Iw(j,c);dc(s,a,re,ys(s))}else dc(s,a,c,ys(s))}catch(oe){dc(s,a,{then:function(){},status:"rejected",reason:oe},ys())}finally{pe.p=p,x!==null&&_.types!==null&&(x.types=_.types),$.T=x}}function jw(){}function Mm(s,a,l,c){if(s.tag!==5)throw Error(n(476));var m=Oy(s).queue;Ry(s,m,a,Re,l===null?jw:function(){return ky(s),l(c)})}function Oy(s){var a=s.memoizedState;if(a!==null)return a;a={memoizedState:Re,baseState:Re,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:Re},next:null};var l={};return a.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:l},next:null},s.memoizedState=a,s=s.alternate,s!==null&&(s.memoizedState=a),a}function ky(s){var a=Oy(s);a.next===null&&(a=s.alternate.memoizedState),dc(s,a.next.queue,{},ys())}function Pm(){return Rn(Ic)}function Ly(){return nn().memoizedState}function jy(){return nn().memoizedState}function Mw(s){for(var a=s.return;a!==null;){switch(a.tag){case 24:case 3:var l=ys();s=Ha(l);var c=Ua(a,s,l);c!==null&&(ss(c,a,l),oc(c,a,l)),a={cache:dm()},s.payload=a;return}a=a.return}}function Pw(s,a,l){var c=ys();l={lane:c,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},Rh(s)?Py(a,l):(l=nm(s,a,l,c),l!==null&&(ss(l,s,c),Vy(l,a,c)))}function My(s,a,l){var c=ys();dc(s,a,l,c)}function dc(s,a,l,c){var m={lane:c,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(Rh(s))Py(a,m);else{var p=s.alternate;if(s.lanes===0&&(p===null||p.lanes===0)&&(p=a.lastRenderedReducer,p!==null))try{var x=a.lastRenderedState,_=p(x,l);if(m.hasEagerState=!0,m.eagerState=_,ds(_,x))return hh(s,a,m,0),Nt===null&&Bh(),!1}catch{}finally{}if(l=nm(s,a,m,c),l!==null)return ss(l,s,c),Vy(l,a,c),!0}return!1}function Vm(s,a,l,c){if(c={lane:2,revertLane:gp(),gesture:null,action:c,hasEagerState:!1,eagerState:null,next:null},Rh(s)){if(a)throw Error(n(479))}else a=nm(s,l,c,2),a!==null&&ss(a,s,2)}function Rh(s){var a=s.alternate;return s===Ye||a!==null&&a===Ye}function Py(s,a){Co=vh=!0;var l=s.pending;
vendor: 17,953 bytes, line 48
48l===null?a.next=a:(a.next=l.next,l.next=a),s.pending=a}function Vy(s,a,l){if((l&4194048)!==0){var c=a.lanes;c&=s.pendingLanes,l|=c,a.lanes=l,Lu(s,l)}}var fc={readContext:Rn,use:Ah,useCallback:Xt,useContext:Xt,useEffect:Xt,useImperativeHandle:Xt,useLayoutEffect:Xt,useInsertionEffect:Xt,useMemo:Xt,useReducer:Xt,useRef:Xt,useState:Xt,useDebugValue:Xt,useDeferredValue:Xt,useTransition:Xt,useSyncExternalStore:Xt,useId:Xt,useHostTransitionStatus:Xt,useFormState:Xt,useActionState:Xt,useOptimistic:Xt,useMemoCache:Xt,useCacheRefresh:Xt};fc.useEffectEvent=Xt;var Fy={readContext:Rn,use:Ah,useCallback:function(s,a){return Kn().memoizedState=[s,a===void 0?null:a],s},useContext:Rn,useEffect:_y,useImperativeHandle:function(s,a,l){l=l!=null?l.concat([s]):null,Ih(4194308,4,Ty.bind(null,a,s),l)},useLayoutEffect:function(s,a){return Ih(4194308,4,s,a)},useInsertionEffect:function(s,a){Ih(4,2,s,a)},useMemo:function(s,a){var l=Kn();a=a===void 0?null:a;var c=s();if(nl){zn(!0);try{s()}finally{zn(!1)}}return l.memoizedState=[c,a],c},useReducer:function(s,a,l){var c=Kn();if(l!==void 0){var m=l(a);if(nl){zn(!0);try{l(a)}finally{zn(!1)}}}else m=a;return c.memoizedState=c.baseState=m,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:m},c.queue=s,s=s.dispatch=Pw.bind(null,Ye,s),[c.memoizedState,s]},useRef:function(s){var a=Kn();return s={current:s},a.memoizedState=s},useState:function(s){s=Rm(s);var a=s.queue,l=My.bind(null,Ye,a);return a.dispatch=l,[s.memoizedState,l]},useDebugValue:Lm,useDeferredValue:function(s,a){var l=Kn();return jm(l,s,a)},useTransition:function(){var s=Rm(!1);return s=Ry.bind(null,Ye,s.queue,!0,!1),Kn().memoizedState=s,[!1,s]},useSyncExternalStore:function(s,a,l){var c=Ye,m=Kn();if(rt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=a(),Nt===null)throw Error(n(349));(nt&127)!==0||ly(c,a,l)}m.memoizedState=l;var p={value:l,getSnapshot:a};return m.queue=p,_y(uy.bind(null,c,p,s),[s]),c.flags|=2048,bo(9,{destroy:void 0},oy.bind(null,c,p,l,a),null),l},useId:function(){var s=Kn(),a=Nt.identifierPrefix;if(rt){var l=wr,c=vr;l=(c&~(1<<32-Ht(c)-1)).toString(32)+l,a="_"+a+"R_"+l,l=wh++,0<l&&(a+="H"+l.toString(32)),a+="_"}else l=Sw++,a="_"+a+"r_"+l.toString(32)+"_";return s.memoizedState=a},useHostTransitionStatus:Pm,useFormState:Cy,useActionState:Cy,useOptimistic:function(s){var a=Kn();a.memoizedState=a.baseState=s;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return a.queue=l,a=Vm.bind(null,Ye,!0,l),l.dispatch=a,[s,a]},useMemoCache:Nm,useCacheRefresh:function(){return Kn().memoizedState=Mw.bind(null,Ye)},useEffectEvent:function(s){var a=Kn(),l={impl:s};return a.memoizedState=l,function(){if((pt&2)!==0)throw Error(n(440));return l.impl.apply(void 0,arguments)}}},Fm={readContext:Rn,use:Ah,useCallback:Ny,useContext:Rn,useEffect:km,useImperativeHandle:Ay,useInsertionEffect:vy,useLayoutEffect:wy,useMemo:Iy,useReducer:Nh,useRef:Ey,useState:function(){return Nh(ea)},useDebugValue:Lm,useDeferredValue:function(s,a){var l=nn();return Sy(l,_t.memoizedState,s,a)},useTransition:function(){var s=Nh(ea)[0],a=nn().memoizedState;return[typeof s=="boolean"?s:hc(s),a]},useSyncExternalStore:iy,useId:Ly,useHostTransitionStatus:Pm,useFormState:yy,useActionState:yy,useOptimistic:function(s,a){var l=nn();return hy(l,_t,s,a)},useMemoCache:Nm,useCacheRefresh:jy};Fm.useEffectEvent=Dy;var Gy={readContext:Rn,use:Ah,useCallback:Ny,useContext:Rn,useEffect:km,useImperativeHandle:Ay,useInsertionEffect:vy,useLayoutEffect:wy,useMemo:Iy,useReducer:Sm,useRef:Ey,useState:function(){return Sm(ea)},useDebugValue:Lm,useDeferredValue:function(s,a){var l=nn();return _t===null?jm(l,s,a):Sy(l,_t.memoizedState,s,a)},useTransition:function(){var s=Sm(ea)[0],a=nn().memoizedState;return[typeof s=="boolean"?s:hc(s),a]},useSyncExternalStore:iy,useId:Ly,useHostTransitionStatus:Pm,useFormState:xy,useActionState:xy,useOptimistic:function(s,a){var l=nn();return _t!==null?hy(l,_t,s,a):(l.baseState=s,[s,l.queue.dispatch])},useMemoCache:Nm,useCacheRefresh:jy};Gy.useEffectEvent=Dy;function Gm(s,a,l,c){a=s.memoizedState,l=l(c,a),l=l==null?a:b({},a,l),s.memoizedState=l,s.lanes===0&&(s.updateQueue.baseState=l)}var Hm={enqueueSetState:function(s,a,l){s=s._reactInternals;var c=ys(),m=Ha(c);m.payload=a,l!=null&&(m.callback=l),a=Ua(s,m,c),a!==null&&(ss(a,s,c),oc(a,s,c))},enqueueReplaceState:function(s,a,l){s=s._reactInternals;var c=ys(),m=Ha(c);m.tag=1,m.payload=a,l!=null&&(m.callback=l),a=Ua(s,m,c),a!==null&&(ss(a,s,c),oc(a,s,c))},enqueueForceUpdate:function(s,a){s=s._reactInternals;var l=ys(),c=Ha(l);c.tag=2,a!=null&&(c.callback=a),a=Ua(s,c,l),a!==null&&(ss(a,s,l),oc(a,s,l))}};function Hy(s,a,l,c,m,p,x){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(c,p,x):a.prototype&&a.prototype.isPureReactComponent?!ec(l,c)||!ec(m,p):!0}function Uy(s,a,l,c){s=a.state,typeof a.componentWillReceiveProps=="function"&&a.componentWillReceiveProps(l,c),typeof a.UNSAFE_componentWillReceiveProps=="function"&&a.UNSAFE_componentWillReceiveProps(l,c),a.state!==s&&Hm.enqueueReplaceState(a,a.state,null)}function sl(s,a){var l=a;if("ref"in a){l={};for(var c in a)c!=="ref"&&(l[c]=a[c])}if(s=s.defaultProps){l===a&&(l=b({},l));for(var m in s)l[m]===void 0&&(l[m]=s[m])}return l}function zy(s){ch(s)}function qy(s){console.error(s)}function Ky(s){ch(s)}function Oh(s,a){try{var l=s.onUncaughtError;l(a.value,{componentStack:a.stack})}catch(c){setTimeout(function(){throw c})}}function Jy(s,a,l){try{var c=s.onCaughtError;c(l.value,{componentStack:l.stack,errorBoundary:a.tag===1?a.stateNode:null})}catch(m){setTimeout(function(){throw m})}}function Um(s,a,l){return l=Ha(l),l.tag=3,l.payload={element:null},l.callback=function(){Oh(s,a)},l}function Qy(s){return s=Ha(s),s.tag=3,s}function Yy(s,a,l,c){var m=l.type.getDerivedStateFromError;if(typeof m=="function"){var p=c.value;s.payload=function(){return m(p)},s.callback=function(){Jy(a,l,c)}}var x=l.stateNode;x!==null&&typeof x.componentDidCatch=="function"&&(s.callback=function(){Jy(a,l,c),typeof m!="function"&&(Ya===null?Ya=new Set([this]):Ya.add(this));var _=c.stack;this.componentDidCatch(c.value,{componentStack:_!==null?_:""})})}function Vw(s,a,l,c,m){if(l.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(a=l.alternate,a!==null&&Bo(a,l,m,!0),l=ms.current,l!==null){switch(l.tag){case 31:case 13:return Vs===null?qh():l.alternate===null&&$t===0&&($t=3),l.flags&=-257,l.flags|=65536,l.lanes=m,c===bh?l.flags|=16384:(a=l.updateQueue,a===null?l.updateQueue=new Set([c]):a.add(c),fp(s,c,m)),!1;case 22:return l.flags|=65536,c===bh?l.flags|=16384:(a=l.updateQueue,a===null?(a={transitions:null,markerInstances:null,retryQueue:new Set([c])},l.updateQueue=a):(l=a.retryQueue,l===null?a.retryQueue=new Set([c]):l.add(c)),fp(s,c,m)),!1}throw Error(n(435,l.tag))}return fp(s,c,m),qh(),!1}if(rt)return a=ms.current,a!==null?((a.flags&65536)===0&&(a.flags|=256),a.flags|=65536,a.lanes=m,c!==om&&(s=Error(n(422),{cause:c}),sc(Ls(s,l)))):(c!==om&&(a=Error(n(423),{cause:c}),sc(Ls(a,l))),s=s.current.alternate,s.flags|=65536,m&=-m,s.lanes|=m,c=Ls(c,l),m=Um(s.stateNode,c,m),ym(s,m),$t!==4&&($t=2)),!1;var p=Error(n(520),{cause:c});if(p=Ls(p,l),Ec===null?Ec=[p]:Ec.push(p),$t!==4&&($t=2),a===null)return!0;c=Ls(c,l),l=a;do{switch(l.tag){case 3:return l.flags|=65536,s=m&-m,l.lanes|=s,s=Um(l.stateNode,c,s),ym(l,s),!1;case 1:if(a=l.type,p=l.stateNode,(l.flags&128)===0&&(typeof a.getDerivedStateFromError=="function"||p!==null&&typeof p.componentDidCatch=="function"&&(Ya===null||!Ya.has(p))))return l.flags|=65536,m&=-m,l.lanes|=m,m=Qy(m),Yy(m,s,l,c),ym(l,m),!1}l=l.return}while(l!==null);return!1}var zm=Error(n(461)),hn=!1;function On(s,a,l,c){a.child=s===null?W0(a,null,l,c):tl(a,s.child,l,c)}function Xy(s,a,l,c,m){l=l.render;var p=a.ref;if("ref"in c){var x={};for(var _ in c)_!=="ref"&&(x[_]=c[_])}else x=c;return $i(a),c=vm(s,a,l,x,p,m),_=wm(),s!==null&&!hn?(Tm(s,a,m),ta(s,a,m)):(rt&&_&&im(a),a.flags|=1,On(s,a,c,m),a.child)}function $y(s,a,l,c,m){if(s===null){var p=l.type;return typeof p=="function"&&!sm(p)&&p.defaultProps===void 0&&l.compare===null?(a.tag=15,a.type=p,Zy(s,a,p,c,m)):(s=fh(l.type,null,c,a,a.mode,m),s.ref=a.ref,s.return=a,a.child=s)}if(p=s.child,!Zm(s,m)){var x=p.memoizedProps;if(l=l.compare,l=l!==null?l:ec,l(x,c)&&s.ref===a.ref)return ta(s,a,m)}return a.flags|=1,s=Yr(p,c),s.ref=a.ref,s.return=a,a.child=s}function Zy(s,a,l,c,m){if(s!==null){var p=s.memoizedProps;if(ec(p,c)&&s.ref===a.ref)if(hn=!1,a.pendingProps=c=p,Zm(s,m))(s.flags&131072)!==0&&(hn=!0);else return a.lanes=s.lanes,ta(s,a,m)}return qm(s,a,l,c,m)}function Wy(s,a,l,c){var m=c.children,p=s!==null?s.memoizedState:null;if(s===null&&a.stateNode===null&&(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),c.mode==="hidden"){if((a.flags&128)!==0){if(p=p!==null?p.baseLanes|l:l,s!==null){for(c=a.child=s.child,m=0;c!==null;)m=m|c.lanes|c.childLanes,c=c.sibling;c=m&~p}else c=0,a.child=null;return eb(s,a,p,l,c)}if((l&536870912)!==0)a.memoizedState={baseLanes:0,cachePool:null},s!==null&&Ch(a,p!==null?p.cachePool:null),p!==null?ny(a,p):xm(),sy(a);else return c=a.lanes=536870912,eb(s,a,p!==null?p.baseLanes|l:l,l,c)}else p!==null?(Ch(a,p.cachePool),ny(a,p),qa(),a.memoizedState=null):(s!==null&&Ch(a,null),xm(),qa());return On(s,a,m,l),a.child}function mc(s,a){return s!==null&&s.tag===22||a.stateNode!==null||(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.sibling}function eb(s,a,l,c,m){var p=mm();return p=p===null?null:{parent:cn._currentValue,pool:p},a.memoizedState={baseLanes:l,cachePool:p},s!==null&&Ch(a,null),xm(),sy(a),s!==null&&Bo(s,a,c,!0),a.childLanes=m,null}function kh(s,a){return a=jh({mode:a.mode,children:a.children},s.mode),a.ref=s.ref,s.child=a,a.return=s,a}function tb(s,a,l){return tl(a,s.child,null,l),s=kh(a,a.pendingProps),s.flags|=2,ps(a),a.memoizedState=null,s}function Fw(s,a,l){var c=a.pendingProps,m=(a.flags&128)!==0;if(a.flags&=-129,s===null){if(rt){if(c.mode==="hidden")return s=kh(a,c),a.lanes=536870912,mc(null,s);if(_m(a),(s=jt)?(s=dx(s,Ps),s=s!==null&&s.data==="&"?s:null,s!==null&&(a.memoizedState={dehydrated:s,treeContext:Ma!==null?{id:vr,overflow:wr}:null,retryLane:536870912,hydrationErrors:null},l=P0(s),l.return=a,a.child=l,Sn=a,jt=null)):s=null,s===null)throw Va(a);return a.lanes=536870912,null}return kh(a,c)}var p=s.memoizedState;if(p!==null){var x=p.dehydrated;if(_m(a),m)if(a.flags&256)a.flags&=-257,a=tb(s,a,l);else if(a.memoizedState!==null)a.child=s.child,a.flags|=128,a=null;else throw Error(n(558));else if(hn||Bo(s,a,l,!1),m=(l&s.childLanes)!==0,hn||m){if(c=Nt,c!==null&&(x=ju(c,l),x!==0&&x!==p.retryLane))throw p.retryLane=x,Ji(s,x),ss(c,s,x),zm;qh(),a=tb(s,a,l)}else s=p.treeContext,jt=Fs(x.nextSibling),Sn=a,rt=!0,Pa=null,Ps=!1,s!==null&&G0(a,s),a=kh(a,c),a.flags|=4096;return a}return s=Yr(s.child,{mode:c.mode,children:c.children}),s.ref=a.ref,a.child=s,s.return=a,s}function Lh(s,a){var l=a.ref;if(l===null)s!==null&&s.ref!==null&&(a.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(n(284));(s===null||s.ref!==l)&&(a.flags|=4194816)}}function qm(s,a,l,c,m){return $i(a),l=vm(s,a,l,c,void 0,m),c=wm(),s!==null&&!hn?(Tm(s,a,m),ta(s,a,m)):(rt&&c&&im(a),a.flags|=1,On(s,a,l,m),a.child)}function nb(s,a,l,c,m,p){return $i(a),a.updateQueue=null,l=ay(a,c,l,m),ry(s),c=wm(),s!==null&&!hn?(Tm(s,a,p),ta(s,a,p)):(rt&&c&&im(a),a.flags|=1,On(s,a,l,p),a.child)}function sb(s,a,l,c,m){if($i(a),a.stateNode===null){var p=lo,x=l.contextType;typeof x=="object"&&x!==null&&(p=Rn(x)),p=new l(c,p),a.memoizedState=p.state!==null&&p.state!==void 0?p.state:null,p.updater=Hm,a.stateNode=p,p._reactInternals=a,p=a.stateNode,p.props=c,p.state=a.memoizedState,p.refs={},gm(a),x=l.contextType,p.context=typeof x=="object"&&x!==null?Rn(x):lo,p.state=a.memoizedState,x=l.getDerivedStateFromProps,typeof x=="function"&&(Gm(a,l,x,c),p.state=a.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof p.getSnapshotBeforeUpdate=="function"||typeof p.UNSAFE_componentWillMount!="function"&&typeof p.componentWillMount!="function"||(x=p.state,typeof p.componentWillMount=="function"&&p.componentWillMount(),typeof p.UNSAFE_componentWillMount=="function"&&p.UNSAFE_componentWillMount(),x!==p.state&&Hm.enqueueReplaceState(p,p.state,null),cc(a,c,p,m),uc(),p.state=a.memoizedState),typeof p.componentDidMount=="function"&&(a.flags|=4194308),c=!0}else if(s===null){p=a.stateNode;var _=a.memoizedProps,j=sl(l,_);p.props=j;var Q=p.context,re=l.contextType;x=lo,typeof re=="object"&&re!==null&&(x=Rn(re));var oe=l.getDerivedStateFromProps;re=typeof oe=="function"||typeof p.getSnapshotBeforeUpdate=="function",_=a.pendingProps!==_,re||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(_||Q!==x)&&Uy(a,p,c,x),Ga=!1;var X=a.memoizedState;p.state=X,cc(a,c,p,m),uc(),Q=a.memoizedState,_||X!==Q||Ga?(typeof oe=="function"&&(Gm(a,l,oe,c),Q=a.memoizedState),(j=Ga||Hy(a,l,j,c,X,Q,x))?(re||typeof p.UNSAFE_componentWillMount!="function"&&typeof p.componentWillMount!="function"||(typeof p.componentWillMount=="function"&&p.componentWillMount(),typeof p.UNSAFE_componentWillMount=="function"&&p.UNSAFE_componentWillMount()),typeof p.componentDidMount=="function"&&(a.flags|=4194308)):(typeof p.componentDidMount=="function"&&(a.flags|=4194308),a.memoizedProps=c,a.memoizedState=Q),p.props=c,p.state=Q,p.context=x,c=j):(typeof p.componentDidMount=="function"&&(a.flags|=4194308),c=!1)}else{p=a.stateNode,Cm(s,a),x=a.memoizedProps,re=sl(l,x),p.props=re,oe=a.pendingProps,X=p.context,Q=l.contextType,j=lo,typeof Q=="object"&&Q!==null&&(j=Rn(Q)),_=l.getDerivedStateFromProps,(Q=typeof _=="function"||typeof p.getSnapshotBeforeUpdate=="function")||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(x!==oe||X!==j)&&Uy(a,p,c,j),Ga=!1,X=a.memoizedState,p.state=X,cc(a,c,p,m),uc();var ee=a.memoizedState;x!==oe||X!==ee||Ga||s!==null&&s.dependencies!==null&&ph(s.dependencies)?(typeof _=="function"&&(Gm(a,l,_,c),ee=a.memoizedState),(re=Ga||Hy(a,l,re,c,X,ee,j)||s!==null&&s.dependencies!==null&&ph(s.dependencies))?(Q||typeof p.UNSAFE_componentWillUpdate!="function"&&typeof p.componentWillUpdate!="function"||(typeof p.componentWillUpdate=="function"&&p.componentWillUpdate(c,ee,j),typeof p.UNSAFE_componentWillUpdate=="function"&&p.UNSAFE_componentWillUpdate(c,ee,j)),typeof p.componentDidUpdate=="function"&&(a.flags|=4),typeof p.getSnapshotBeforeUpdate=="function"&&(a.flags|=1024)):(typeof p.componentDidUpdate!="function"||x===s.memoizedProps&&X===s.memoizedState||(a.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||x===s.memoizedProps&&X===s.memoizedState||(a.flags|=1024),a.memoizedProps=c,a.memoizedState=ee),p.props=c,p.state=ee,p.context=j,c=re):(typeof p.componentDidUpdate!="function"||x===s.memoizedProps&&X===s.memoizedState||(a.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||x===s.memoizedProps&&X===s.memoizedState||(a.flags|=1024),c=!1)}return p=c,Lh(s,a),c=(a.flags&128)!==0,p||c?(p=a.stateNode,l=c&&typeof l.getDerivedStateFromError!="function"?null:p.render(),a.flags|=1,s!==null&&c?(a.child=tl(a,s.child,null,m),a.child=tl(a,null,l,m)):On(s,a,l,m),a.memoizedState=p.state,s=a.child):s=ta(s,a,m),s}function rb(s,a,l,c){return Yi(),a.flags|=256,On(s,a,l,c),a.child}var Km={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Jm(s){return{baseLanes:s,cachePool:J0()}}function Qm(s,a,l){return s=s!==null?s.childLanes&~l:0,a&&(s|=Cs),s}function ab(s,a,l){var c=a.pendingProps,m=!1,p=(a.flags&128)!==0,x;if((x=p)||(x=s!==null&&s.memoizedState===null?!1:(tn.current&2)!==0),x&&(m=!0,a.flags&=-129),x=(a.flags&32)!==0,a.flags&=-33,s===null){if(rt){if(m?za(a):qa(),(s=jt)?(s=dx(s,Ps),s=s!==null&&s.data!=="&"?s:null,s!==null&&(a.memoizedState={dehydrated:s,treeContext:Ma!==null?{id:vr,overflow:wr}:null,retryLane:536870912,hydrationErrors:null},l=P0(s),l.return=a,a.child=l,Sn=a,jt=null)):s=null,s===null)throw Va(a);return Ip(s)?a.lanes=32:a.lanes=536870912,null}var _=c.children;return c=c.fallback,m?(qa(),m=a.mode,_=jh({mode:"hidden",children:_},m),c=Qi(c,m,l,null),_.return=a,c.return=a,_.sibling=c,a.child=_,c=a.child,c.memoizedState=Jm(l),c.childLanes=Qm(s,x,l),a.memoizedState=Km,mc(null,c)):(za(a),Ym(a,_))}var j=s.memoizedState;if(j!==null&&(_=j.dehydrated,_!==null)){if(p)a.flags&256?(za(a),a.flags&=-257,a=Xm(s,a,l)):a.memoizedState!==null?(qa(),a.child=s.child,a.flags|=128,a=null):(qa(),_=c.fallback,m=a.mode,c=jh({mode:"visible",children:c.children},m),_=Qi(_,m,l,null),_.flags|=2,c.return=a,_.return=a,c.sibling=_,a.child=c,tl(a,s.child,null,l),c=a.child,c.memoizedState=Jm(l),c.childLanes=Qm(s,x,l),a.memoizedState=Km,a=mc(null,c));else if(za(a),Ip(_)){if(x=_.nextSibling&&_.nextSibling.dataset,x)var Q=x.dgst;x=Q,c=Error(n(419)),c.stack="",c.digest=x,sc({value:c,source:null,stack:null}),a=Xm(s,a,l)}else if(hn||Bo(s,a,l,!1),x=(l&s.childLanes)!==0,hn||x){if(x=Nt,x!==null&&(c=ju(x,l),c!==0&&c!==j.retryLane))throw j.retryLane=c,Ji(s,c),ss(x,s,c),zm;Np(_)||qh(),a=Xm(s,a,l)}else Np(_)?(a.flags|=192,a.child=s.child,a=null):(s=j.treeContext,jt=Fs(_.nextSibling),Sn=a,rt=!0,Pa=null,Ps=!1,s!==null&&G0(a,s),a=Ym(a,c.children),a.flags|=4096);return a}return m?(qa(),_=c.fallback,m=a.mode,j=s.child,Q=j.sibling,c=Yr(j,{mode:"hidden",children:c.children}),c.subtreeFlags=j.subtreeFlags&65011712,Q!==null?_=Yr(Q,_):(_=Qi(_,m,l,null),_.flags|=2),_.return=a,c.return=a,c.sibling=_,a.child=c,mc(null,c),c=a.child,_=s.child.memoizedState,_===null?_=Jm(l):(m=_.cachePool,m!==null?(j=cn._currentValue,m=m.parent!==j?{parent:j,pool:j}:m):m=J0(),_={baseLanes:_.baseLanes|l,cachePool:m}),c.memoizedState=_,c.childLanes=Qm(s,x,l),a.memoizedState=Km,mc(s.child,c)):(za(a),l=s.child,s=l.sibling,l=Yr(l,{mode:"visible",children:c.children}),l.return=a,l.sibling=null,s!==null&&(x=a.deletions,x===null?(a.deleti
vendor: 5,273 bytes, line 48
48ons=[s],a.flags|=16):x.push(s)),a.child=l,a.memoizedState=null,l)}function Ym(s,a){return a=jh({mode:"visible",children:a},s.mode),a.return=s,s.child=a}function jh(s,a){return s=fs(22,s,null,a),s.lanes=0,s}function Xm(s,a,l){return tl(a,s.child,null,l),s=Ym(a,a.pendingProps.children),s.flags|=2,a.memoizedState=null,s}function ib(s,a,l){s.lanes|=a;var c=s.alternate;c!==null&&(c.lanes|=a),Bm(s.return,a,l)}function $m(s,a,l,c,m,p){var x=s.memoizedState;x===null?s.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:c,tail:l,tailMode:m,treeForkCount:p}:(x.isBackwards=a,x.rendering=null,x.renderingStartTime=0,x.last=c,x.tail=l,x.tailMode=m,x.treeForkCount=p)}function lb(s,a,l){var c=a.pendingProps,m=c.revealOrder,p=c.tail;c=c.children;var x=tn.current,_=(x&2)!==0;if(_?(x=x&1|2,a.flags|=128):x&=1,xe(tn,x),On(s,a,c,l),c=rt?nc:0,!_&&s!==null&&(s.flags&128)!==0)e:for(s=a.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&ib(s,l,a);else if(s.tag===19)ib(s,l,a);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===a)break e;for(;s.sibling===null;){if(s.return===null||s.return===a)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}switch(m){case"forwards":for(l=a.child,m=null;l!==null;)s=l.alternate,s!==null&&Dh(s)===null&&(m=l),l=l.sibling;l=m,l===null?(m=a.child,a.child=null):(m=l.sibling,l.sibling=null),$m(a,!1,m,l,p,c);break;case"backwards":case"unstable_legacy-backwards":for(l=null,m=a.child,a.child=null;m!==null;){if(s=m.alternate,s!==null&&Dh(s)===null){a.child=m;break}s=m.sibling,m.sibling=l,l=m,m=s}$m(a,!0,l,null,p,c);break;case"together":$m(a,!1,null,null,void 0,c);break;default:a.memoizedState=null}return a.child}function ta(s,a,l){if(s!==null&&(a.dependencies=s.dependencies),Qa|=a.lanes,(l&a.childLanes)===0)if(s!==null){if(Bo(s,a,l,!1),(l&a.childLanes)===0)return null}else return null;if(s!==null&&a.child!==s.child)throw Error(n(153));if(a.child!==null){for(s=a.child,l=Yr(s,s.pendingProps),a.child=l,l.return=a;s.sibling!==null;)s=s.sibling,l=l.sibling=Yr(s,s.pendingProps),l.return=a;l.sibling=null}return a.child}function Zm(s,a){return(s.lanes&a)!==0?!0:(s=s.dependencies,!!(s!==null&&ph(s)))}function Gw(s,a,l){switch(a.tag){case 3:Jt(a,a.stateNode.containerInfo),Fa(a,cn,s.memoizedState.cache),Yi();break;case 27:case 5:or(a);break;case 4:Jt(a,a.stateNode.containerInfo);break;case 10:Fa(a,a.type,a.memoizedProps.value);break;case 31:if(a.memoizedState!==null)return a.flags|=128,_m(a),null;break;case 13:var c=a.memoizedState;if(c!==null)return c.dehydrated!==null?(za(a),a.flags|=128,null):(l&a.child.childLanes)!==0?ab(s,a,l):(za(a),s=ta(s,a,l),s!==null?s.sibling:null);za(a);break;case 19:var m=(s.flags&128)!==0;if(c=(l&a.childLanes)!==0,c||(Bo(s,a,l,!1),c=(l&a.childLanes)!==0),m){if(c)return lb(s,a,l);a.flags|=128}if(m=a.memoizedState,m!==null&&(m.rendering=null,m.tail=null,m.lastEffect=null),xe(tn,tn.current),c)break;return null;case 22:return a.lanes=0,Wy(s,a,l,a.pendingProps);case 24:Fa(a,cn,s.memoizedState.cache)}return ta(s,a,l)}function ob(s,a,l){if(s!==null)if(s.memoizedProps!==a.pendingProps)hn=!0;else{if(!Zm(s,l)&&(a.flags&128)===0)return hn=!1,Gw(s,a,l);hn=(s.flags&131072)!==0}else hn=!1,rt&&(a.flags&1048576)!==0&&F0(a,nc,a.index);switch(a.lanes=0,a.tag){case 16:e:{var c=a.pendingProps;if(s=Wi(a.elementType),a.type=s,typeof s=="function")sm(s)?(c=sl(s,c),a.tag=1,a=sb(null,a,s,c,l)):(a.tag=0,a=qm(null,a,s,c,l));else{if(s!=null){var m=s.$$typeof;if(m===ce){a.tag=11,a=Xy(null,a,s,c,l);break e}else if(m===S){a.tag=14,a=$y(null,a,s,c,l);break e}}throw a=Le(s)||s,Error(n(306,a,""))}}return a;case 0:return qm(s,a,a.type,a.pendingProps,l);case 1:return c=a.type,m=sl(c,a.pendingProps),sb(s,a,c,m,l);case 3:e:{if(Jt(a,a.stateNode.containerInfo),s===null)throw Error(n(387));c=a.pendingProps;var p=a.memoizedState;m=p.element,Cm(s,a),cc(a,c,null,l);var x=a.memoizedState;if(c=x.cache,Fa(a,cn,c),c!==p.cache&&hm(a,[cn],l,!0),uc(),c=x.element,p.isDehydrated)if(p={element:c,isDehydrated:!1,cache:x.cache},a.updateQueue.baseState=p,a.memoizedState=p,a.flags&256){a=rb(s,a,c,l);break e}else if(c!==m){m=Ls(Error(n(424)),a),sc(m),a=rb(s,a,c,l);break e}else{switch(s=a.stateNode.containerInfo,s.nodeType){case 9:s=s.body;break;default:s=s.nodeName==="HTML"?s.ownerDocument.body:s}for(jt=Fs(s.firstChild),Sn=a,rt=!0,Pa=null,Ps=!0,l=W0(a,null,c,l),a.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Yi(),c===m){a=ta(s,a,l);break e}On(s,a,c,l)}a=a.child}return a;case 26:return Lh(s,a),s===null?(l=yx(a.type,null,a.pendingProps,null))?a.memoizedState=l:rt||(l=a.type,s=a.pendingProps,c=Zh(Ke.current).createElement(l),c[ln]=a,c[Dn]=s,kn(c,l,s),on(c),a.stateNode=c):a.memoizedState=yx(a.type,s.memoizedProps,a.pendingProps,s.memoizedState),null;case 27:return or(a),s===null&&rt&&(c=a.stateNode=px(a.type,a.pendingProps,Ke.current),Sn=a,Ps=!0,m=jt,Wa(a.type)?(Sp=m,jt=Fs(c.firstChild)):jt=m),On(s,a,a.pendingProps.children,l),Lh(s,a),s===null&&(a.flags|=4194304),a.child;case 5:return s===null&&rt&&((m=c=jt)&&(c=gT(c,a.type,a.pendingProps,Ps),c!==null?(a.stateNode=c,Sn=a,jt=Fs(c.firstChild),Ps=!1,m=!0):m=!1),m||Va(a)),or(a),m=a.type,p=a.pendingProps,x=s!==null?s.memoizedProps:null,c=p.children,wp(m,p)?c=null:x!==null&&wp(m,x)&&(a.flags|=32),a.memoizedState!==null&&(m=vm
vendor: 4,257 bytes, line 48
48(s,a,Rw,null,null,l),Ic._currentValue=m),Lh(s,a),On(s,a,c,l),a.child;case 6:return s===null&&rt&&((s=l=jt)&&(l=CT(l,a.pendingProps,Ps),l!==null?(a.stateNode=l,Sn=a,jt=null,s=!0):s=!1),s||Va(a)),null;case 13:return ab(s,a,l);case 4:return Jt(a,a.stateNode.containerInfo),c=a.pendingProps,s===null?a.child=tl(a,null,c,l):On(s,a,c,l),a.child;case 11:return Xy(s,a,a.type,a.pendingProps,l);case 7:return On(s,a,a.pendingProps,l),a.child;case 8:return On(s,a,a.pendingProps.children,l),a.child;case 12:return On(s,a,a.pendingProps.children,l),a.child;case 10:return c=a.pendingProps,Fa(a,a.type,c.value),On(s,a,c.children,l),a.child;case 9:return m=a.type._context,c=a.pendingProps.children,$i(a),m=Rn(m),c=c(m),a.flags|=1,On(s,a,c,l),a.child;case 14:return $y(s,a,a.type,a.pendingProps,l);case 15:return Zy(s,a,a.type,a.pendingProps,l);case 19:return lb(s,a,l);case 31:return Fw(s,a,l);case 22:return Wy(s,a,l,a.pendingProps);case 24:return $i(a),c=Rn(cn),s===null?(m=mm(),m===null&&(m=Nt,p=dm(),m.pooledCache=p,p.refCount++,p!==null&&(m.pooledCacheLanes|=l),m=p),a.memoizedState={parent:c,cache:m},gm(a),Fa(a,cn,m)):((s.lanes&l)!==0&&(Cm(s,a),cc(a,null,null,l),uc()),m=s.memoizedState,p=a.memoizedState,m.parent!==c?(m={parent:c,cache:c},a.memoizedState=m,a.lanes===0&&(a.memoizedState=a.updateQueue.baseState=m),Fa(a,cn,c)):(c=p.cache,Fa(a,cn,c),c!==m.cache&&hm(a,[cn],l,!0))),On(s,a,a.pendingProps.children,l),a.child;case 29:throw a.pendingProps}throw Error(n(156,a.tag))}function na(s){s.flags|=4}function Wm(s,a,l,c,m){if((a=(s.mode&32)!==0)&&(a=!1),a){if(s.flags|=16777216,(m&335544128)===m)if(s.stateNode.complete)s.flags|=8192;else if(Lb())s.flags|=8192;else throw el=bh,pm}else s.flags&=-16777217}function ub(s,a){if(a.type!=="stylesheet"||(a.state.loading&4)!==0)s.flags&=-16777217;else if(s.flags|=16777216,!Dx(a))if(Lb())s.flags|=8192;else throw el=bh,pm}function Mh(s,a){a!==null&&(s.flags|=4),s.flags&16384&&(a=s.tag!==22?UB():536870912,s.lanes|=a,Do|=a)}function pc(s,a){if(!rt)switch(s.tailMode){case"hidden":a=s.tail;for(var l=null;a!==null;)a.alternate!==null&&(l=a),a=a.sibling;l===null?s.tail=null:l.sibling=null;break;case"collapsed":l=s.tail;for(var c=null;l!==null;)l.alternate!==null&&(c=l),l=l.sibling;c===null?a||s.tail===null?s.tail=null:s.tail.sibling=null:c.sibling=null}}function Mt(s){var a=s.alternate!==null&&s.alternate.child===s.child,l=0,c=0;if(a)for(var m=s.child;m!==null;)l|=m.lanes|m.childLanes,c|=m.subtreeFlags&65011712,c|=m.flags&65011712,m.return=s,m=m.sibling;else for(m=s.child;m!==null;)l|=m.lanes|m.childLanes,c|=m.subtreeFlags,c|=m.flags,m.return=s,m=m.sibling;return s.subtreeFlags|=c,s.childLanes=l,a}function Hw(s,a,l){var c=a.pendingProps;switch(lm(a),a.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Mt(a),null;case 1:return Mt(a),null;case 3:return l=a.stateNode,c=null,s!==null&&(c=s.memoizedState.cache),a.memoizedState.cache!==c&&(a.flags|=2048),Zr(cn),Tt(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(s===null||s.child===null)&&(co(a)?na(a):s===null||s.memoizedState.isDehydrated&&(a.flags&256)===0||(a.flags|=1024,um())),Mt(a),null;case 26:var m=a.type,p=a.memoizedState;return s===null?(na(a),p!==null?(Mt(a),ub(a,p)):(Mt(a),Wm(a,m,null,c,l))):p?p!==s.memoizedState?(na(a),Mt(a),ub(a,p)):(Mt(a),a.flags&=-16777217):(s=s.memoizedProps,s!==c&&na(a),Mt(a),Wm(a,m,s,c,l)),null;case 27:if(Gr(a),l=Ke.current,m=a.type,s!==null&&a.stateNode!=null)s.memoizedProps!==c&&na(a);else{if(!c){if(a.stateNode===null)throw Error(n(166));return Mt(a),null}s=Ae.current,co(a)?H0(a):(s=px(m,c,l),a.stateNode=s,na(a))}return Mt(a),null;case 5:if(Gr(a),m=a.type,s!==null&&a.stateNode!=null)s.memoizedProps!==c&&na(a);else{if(!c){if(a.stateNode===null)throw Error(n(166));return Mt(a),null}if(p=Ae.current,co(a))H0(a);else{var x=Zh(Ke.current);switch(p){case 1:p=x.createElementNS("http://www.w3.org/2000/svg",m);break;case 2:p=x.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;default:switch(m){case"svg":p=x.createElementNS("http://www.w3.org/2000/svg",m);break;case"math":p=x.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;case"script":p=x.createElement("div"),p.innerHTML="<script><\/script>",p=p.removeChild(p.firstChild);break;
vendor: 24,253 bytes, line 48
48case"select":p=typeof c.is=="string"?x.createElement("select",{is:c.is}):x.createElement("select"),c.multiple?p.multiple=!0:c.size&&(p.size=c.size);break;default:p=typeof c.is=="string"?x.createElement(m,{is:c.is}):x.createElement(m)}}p[ln]=a,p[Dn]=c;e:for(x=a.child;x!==null;){if(x.tag===5||x.tag===6)p.appendChild(x.stateNode);else if(x.tag!==4&&x.tag!==27&&x.child!==null){x.child.return=x,x=x.child;continue}if(x===a)break e;for(;x.sibling===null;){if(x.return===null||x.return===a)break e;x=x.return}x.sibling.return=x.return,x=x.sibling}a.stateNode=p;e:switch(kn(p,m,c),m){case"button":case"input":case"select":case"textarea":c=!!c.autoFocus;break e;case"img":c=!0;break e;default:c=!1}c&&na(a)}}return Mt(a),Wm(a,a.type,s===null?null:s.memoizedProps,a.pendingProps,l),null;case 6:if(s&&a.stateNode!=null)s.memoizedProps!==c&&na(a);else{if(typeof c!="string"&&a.stateNode===null)throw Error(n(166));if(s=Ke.current,co(a)){if(s=a.stateNode,l=a.memoizedProps,c=null,m=Sn,m!==null)switch(m.tag){case 27:case 5:c=m.memoizedProps}s[ln]=a,s=!!(s.nodeValue===l||c!==null&&c.suppressHydrationWarning===!0||ax(s.nodeValue,l)),s||Va(a,!0)}else s=Zh(s).createTextNode(c),s[ln]=a,a.stateNode=s}return Mt(a),null;case 31:if(l=a.memoizedState,s===null||s.memoizedState!==null){if(c=co(a),l!==null){if(s===null){if(!c)throw Error(n(318));if(s=a.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(n(557));s[ln]=a}else Yi(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Mt(a),s=!1}else l=um(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=l),s=!0;if(!s)return a.flags&256?(ps(a),a):(ps(a),null);if((a.flags&128)!==0)throw Error(n(558))}return Mt(a),null;case 13:if(c=a.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(m=co(a),c!==null&&c.dehydrated!==null){if(s===null){if(!m)throw Error(n(318));if(m=a.memoizedState,m=m!==null?m.dehydrated:null,!m)throw Error(n(317));m[ln]=a}else Yi(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Mt(a),m=!1}else m=um(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=m),m=!0;if(!m)return a.flags&256?(ps(a),a):(ps(a),null)}return ps(a),(a.flags&128)!==0?(a.lanes=l,a):(l=c!==null,s=s!==null&&s.memoizedState!==null,l&&(c=a.child,m=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(m=c.alternate.memoizedState.cachePool.pool),p=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(p=c.memoizedState.cachePool.pool),p!==m&&(c.flags|=2048)),l!==s&&l&&(a.child.flags|=8192),Mh(a,a.updateQueue),Mt(a),null);case 4:return Tt(),s===null&&xp(a.stateNode.containerInfo),Mt(a),null;case 10:return Zr(a.type),Mt(a),null;case 19:if(ae(tn),c=a.memoizedState,c===null)return Mt(a),null;if(m=(a.flags&128)!==0,p=c.rendering,p===null)if(m)pc(c,!1);else{if($t!==0||s!==null&&(s.flags&128)!==0)for(s=a.child;s!==null;){if(p=Dh(s),p!==null){for(a.flags|=128,pc(c,!1),s=p.updateQueue,a.updateQueue=s,Mh(a,s),a.subtreeFlags=0,s=l,l=a.child;l!==null;)M0(l,s),l=l.sibling;return xe(tn,tn.current&1|2),rt&&Xr(a,c.treeForkCount),a.child}s=s.sibling}c.tail!==null&&En()>Hh&&(a.flags|=128,m=!0,pc(c,!1),a.lanes=4194304)}else{if(!m)if(s=Dh(p),s!==null){if(a.flags|=128,m=!0,s=s.updateQueue,a.updateQueue=s,Mh(a,s),pc(c,!0),c.tail===null&&c.tailMode==="hidden"&&!p.alternate&&!rt)return Mt(a),null}else 2*En()-c.renderingStartTime>Hh&&l!==536870912&&(a.flags|=128,m=!0,pc(c,!1),a.lanes=4194304);c.isBackwards?(p.sibling=a.child,a.child=p):(s=c.last,s!==null?s.sibling=p:a.child=p,c.last=p)}return c.tail!==null?(s=c.tail,c.rendering=s,c.tail=s.sibling,c.renderingStartTime=En(),s.sibling=null,l=tn.current,xe(tn,m?l&1|2:l&1),rt&&Xr(a,c.treeForkCount),s):(Mt(a),null);case 22:case 23:return ps(a),Em(),c=a.memoizedState!==null,s!==null?s.memoizedState!==null!==c&&(a.flags|=8192):c&&(a.flags|=8192),c?(l&536870912)!==0&&(a.flags&128)===0&&(Mt(a),a.subtreeFlags&6&&(a.flags|=8192)):Mt(a),l=a.updateQueue,l!==null&&Mh(a,l.retryQueue),l=null,s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(l=s.memoizedState.cachePool.pool),c=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(c=a.memoizedState.cachePool.pool),c!==l&&(a.flags|=2048),s!==null&&ae(Zi),null;case 24:return l=null,s!==null&&(l=s.memoizedState.cache),a.memoizedState.cache!==l&&(a.flags|=2048),Zr(cn),Mt(a),null;case 25:return null;case 30:return null}throw Error(n(156,a.tag))}function Uw(s,a){switch(lm(a),a.tag){case 1:return s=a.flags,s&65536?(a.flags=s&-65537|128,a):null;case 3:return Zr(cn),Tt(),s=a.flags,(s&65536)!==0&&(s&128)===0?(a.flags=s&-65537|128,a):null;case 26:case 27:case 5:return Gr(a),null;case 31:if(a.memoizedState!==null){if(ps(a),a.alternate===null)throw Error(n(340));Yi()}return s=a.flags,s&65536?(a.flags=s&-65537|128,a):null;case 13:if(ps(a),s=a.memoizedState,s!==null&&s.dehydrated!==null){if(a.alternate===null)throw Error(n(340));Yi()}return s=a.flags,s&65536?(a.flags=s&-65537|128,a):null;case 19:return ae(tn),null;case 4:return Tt(),null;case 10:return Zr(a.type),null;case 22:case 23:return ps(a),Em(),s!==null&&ae(Zi),s=a.flags,s&65536?(a.flags=s&-65537|128,a):null;case 24:return Zr(cn),null;case 25:return null;default:return null}}function cb(s,a){switch(lm(a),a.tag){case 3:Zr(cn),Tt();break;case 26:case 27:case 5:Gr(a);break;case 4:Tt();break;case 31:a.memoizedState!==null&&ps(a);break;case 13:ps(a);break;case 19:ae(tn);break;case 10:Zr(a.type);break;case 22:case 23:ps(a),Em(),s!==null&&ae(Zi);break;case 24:Zr(cn)}}function gc(s,a){try{var l=a.updateQueue,c=l!==null?l.lastEffect:null;if(c!==null){var m=c.next;l=m;do{if((l.tag&s)===s){c=void 0;var p=l.create,x=l.inst;c=p(),x.destroy=c}l=l.next}while(l!==m)}}catch(_){bt(a,a.return,_)}}function Ka(s,a,l){try{var c=a.updateQueue,m=c!==null?c.lastEffect:null;if(m!==null){var p=m.next;c=p;do{if((c.tag&s)===s){var x=c.inst,_=x.destroy;if(_!==void 0){x.destroy=void 0,m=a;var j=l,Q=_;try{Q()}catch(re){bt(m,j,re)}}}c=c.next}while(c!==p)}}catch(re){bt(a,a.return,re)}}function Bb(s){var a=s.updateQueue;if(a!==null){var l=s.stateNode;try{ty(a,l)}catch(c){bt(s,s.return,c)}}}function hb(s,a,l){l.props=sl(s.type,s.memoizedProps),l.state=s.memoizedState;try{l.componentWillUnmount()}catch(c){bt(s,a,c)}}function Cc(s,a){try{var l=s.ref;if(l!==null){switch(s.tag){case 26:case 27:case 5:var c=s.stateNode;break;case 30:c=s.stateNode;break;default:c=s.stateNode}typeof l=="function"?s.refCleanup=l(c):l.current=c}}catch(m){bt(s,a,m)}}function Tr(s,a){var l=s.ref,c=s.refCleanup;if(l!==null)if(typeof c=="function")try{c()}catch(m){bt(s,a,m)}finally{s.refCleanup=null,s=s.alternate,s!=null&&(s.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(m){bt(s,a,m)}else l.current=null}function db(s){var a=s.type,l=s.memoizedProps,c=s.stateNode;try{e:switch(a){case"button":case"input":case"select":case"textarea":l.autoFocus&&c.focus();break e;case"img":l.src?c.src=l.src:l.srcSet&&(c.srcset=l.srcSet)}}catch(m){bt(s,s.return,m)}}function ep(s,a,l){try{var c=s.stateNode;BT(c,s.type,l,a),c[Dn]=a}catch(m){bt(s,s.return,m)}}function fb(s){return s.tag===5||s.tag===3||s.tag===26||s.tag===27&&Wa(s.type)||s.tag===4}function tp(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||fb(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.tag===27&&Wa(s.type)||s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function np(s,a,l){var c=s.tag;if(c===5||c===6)s=s.stateNode,a?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(s,a):(a=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,a.appendChild(s),l=l._reactRootContainer,l!=null||a.onclick!==null||(a.onclick=Zs));else if(c!==4&&(c===27&&Wa(s.type)&&(l=s.stateNode,a=null),s=s.child,s!==null))for(np(s,a,l),s=s.sibling;s!==null;)np(s,a,l),s=s.sibling}function Ph(s,a,l){var c=s.tag;if(c===5||c===6)s=s.stateNode,a?l.insertBefore(s,a):l.appendChild(s);else if(c!==4&&(c===27&&Wa(s.type)&&(l=s.stateNode),s=s.child,s!==null))for(Ph(s,a,l),s=s.sibling;s!==null;)Ph(s,a,l),s=s.sibling}function mb(s){var a=s.stateNode,l=s.memoizedProps;try{for(var c=s.type,m=a.attributes;m.length;)a.removeAttributeNode(m[0]);kn(a,c,l),a[ln]=s,a[Dn]=l}catch(p){bt(s,s.return,p)}}var sa=!1,dn=!1,sp=!1,pb=typeof WeakSet=="function"?WeakSet:Set,wn=null;function zw(s,a){if(s=s.containerInfo,Dp=ad,s=A0(s),Xf(s)){if("selectionStart"in s)var l={start:s.selectionStart,end:s.selectionEnd};else e:{l=(l=s.ownerDocument)&&l.defaultView||window;var c=l.getSelection&&l.getSelection();if(c&&c.rangeCount!==0){l=c.anchorNode;var m=c.anchorOffset,p=c.focusNode;c=c.focusOffset;try{l.nodeType,p.nodeType}catch{l=null;break e}var x=0,_=-1,j=-1,Q=0,re=0,oe=s,X=null;t:for(;;){for(var ee;oe!==l||m!==0&&oe.nodeType!==3||(_=x+m),oe!==p||c!==0&&oe.nodeType!==3||(j=x+c),oe.nodeType===3&&(x+=oe.nodeValue.length),(ee=oe.firstChild)!==null;)X=oe,oe=ee;for(;;){if(oe===s)break t;if(X===l&&++Q===m&&(_=x),X===p&&++re===c&&(j=x),(ee=oe.nextSibling)!==null)break;oe=X,X=oe.parentNode}oe=ee}l=_===-1||j===-1?null:{start:_,end:j}}else l=null}l=l||{start:0,end:0}}else l=null;for(vp={focusedElem:s,selectionRange:l},ad=!1,wn=a;wn!==null;)if(a=wn,s=a.child,(a.subtreeFlags&1028)!==0&&s!==null)s.return=a,wn=s;else for(;wn!==null;){switch(a=wn,p=a.alternate,s=a.flags,a.tag){case 0:if((s&4)!==0&&(s=a.updateQueue,s=s!==null?s.events:null,s!==null))for(l=0;l<s.length;l++)m=s[l],m.ref.impl=m.nextImpl;break;case 11:case 15:break;case 1:if((s&1024)!==0&&p!==null){s=void 0,l=a,m=p.memoizedProps,p=p.memoizedState,c=l.stateNode;try{var Ne=sl(l.type,m);s=c.getSnapshotBeforeUpdate(Ne,p),c.__reactInternalSnapshotBeforeUpdate=s}catch(Ve){bt(l,l.return,Ve)}}break;case 3:if((s&1024)!==0){if(s=a.stateNode.containerInfo,l=s.nodeType,l===9)Ap(s);else if(l===1)switch(s.nodeName){case"HEAD":case"HTML":case"BODY":Ap(s);break;default:s.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((s&1024)!==0)throw Error(n(163))}if(s=a.sibling,s!==null){s.return=a.return,wn=s;break}wn=a.return}}function gb(s,a,l){var c=l.flags;switch(l.tag){case 0:case 11:case 15:aa(s,l),c&4&&gc(5,l);break;case 1:if(aa(s,l),c&4)if(s=l.stateNode,a===null)try{s.componentDidMount()}catch(x){bt(l,l.return,x)}else{var m=sl(l.type,a.memoizedProps);a=a.memoizedState;try{s.componentDidUpdate(m,a,s.__reactInternalSnapshotBeforeUpdate)}catch(x){bt(l,l.return,x)}}c&64&&Bb(l),c&512&&Cc(l,l.return);break;case 3:if(aa(s,l),c&64&&(s=l.updateQueue,s!==null)){if(a=null,l.child!==null)switch(l.child.tag){case 27:case 5:a=l.child.stateNode;break;case 1:a=l.child.stateNode}try{ty(s,a)}catch(x){bt(l,l.return,x)}}break;case 27:a===null&&c&4&&mb(l);case 26:case 5:aa(s,l),a===null&&c&4&&db(l),c&512&&Cc(l,l.return);break;case 12:aa(s,l);break;case 31:aa(s,l),c&4&&bb(s,l);break;case 13:aa(s,l),c&4&&xb(s,l),c&64&&(s=l.memoizedState,s!==null&&(s=s.dehydrated,s!==null&&(l=Ww.bind(null,l),yT(s,l))));break;case 22:if(c=l.memoizedState!==null||sa,!c){a=a!==null&&a.memoizedState!==null||dn,m=sa;var p=dn;sa=c,(dn=a)&&!p?ia(s,l,(l.subtreeFlags&8772)!==0):aa(s,l),sa=m,dn=p}break;case 30:break;default:aa(s,l)}}function Cb(s){var a=s.alternate;a!==null&&(s.alternate=null,Cb(a)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(a=s.stateNode,a!==null&&Jl(a)),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}var zt=null,Wn=!1;function ra(s,a,l){for(l=l.child;l!==null;)yb(s,a,l),l=l.sibling}function yb(s,a,l){if(an&&typeof an.onCommitFiberUnmount=="function")try{an.onCommitFiberUnmount(Ot,l)}catch{}switch(l.tag){case 26:dn||Tr(l,a),ra(s,a,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:dn||Tr(l,a);var c=zt,m=Wn;Wa(l.type)&&(zt=l.stateNode,Wn=!1),ra(s,a,l),Tc(l.stateNode),zt=c,Wn=m;break;case 5:dn||Tr(l,a);case 6:if(c=zt,m=Wn,zt=null,ra(s,a,l),zt=c,Wn=m,zt!==null)if(Wn)try{(zt.nodeType===9?zt.body:zt.nodeName==="HTML"?zt.ownerDocument.body:zt).removeChild(l.stateNode)}catch(p){bt(l,a,p)}else try{zt.removeChild(l.stateNode)}catch(p){bt(l,a,p)}break;case 18:zt!==null&&(Wn?(s=zt,Bx(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,l.stateNode),Ro(s)):Bx(zt,l.stateNode));break;case 4:c=zt,m=Wn,zt=l.stateNode.containerInfo,Wn=!0,ra(s,a,l),zt=c,Wn=m;break;case 0:case 11:case 14:case 15:Ka(2,l,a),dn||Ka(4,l,a),ra(s,a,l);break;case 1:dn||(Tr(l,a),c=l.stateNode,typeof c.componentWillUnmount=="function"&&hb(l,a,c)),ra(s,a,l);break;case 21:ra(s,a,l);break;case 22:dn=(c=dn)||l.memoizedState!==null,ra(s,a,l),dn=c;break;default:ra(s,a,l)}}function bb(s,a){if(a.memoizedState===null&&(s=a.alternate,s!==null&&(s=s.memoizedState,s!==null))){s=s.dehydrated;try{Ro(s)}catch(l){bt(a,a.return,l)}}}function xb(s,a){if(a.memoizedState===null&&(s=a.alternate,s!==null&&(s=s.memoizedState,s!==null&&(s=s.dehydrated,s!==null))))try{Ro(s)}catch(l){bt(a,a.return,l)}}function qw(s){switch(s.tag){case 31:case 13:case 19:var a=s.stateNode;return a===null&&(a=s.stateNode=new pb),a;case 22:return s=s.stateNode,a=s._retryCache,a===null&&(a=s._retryCache=new pb),a;default:throw Error(n(435,s.tag))}}function Vh(s,a){var l=qw(s);a.forEach(function(c){if(!l.has(c)){l.add(c);var m=eT.bind(null,s,c);c.then(m,m)}})}function es(s,a){var l=a.deletions;if(l!==null)for(var c=0;c<l.length;c++){var m=l[c],p=s,x=a,_=x;e:for(;_!==null;){switch(_.tag){case 27:if(Wa(_.type)){zt=_.stateNode,Wn=!1;break e}break;case 5:zt=_.stateNode,Wn=!1;break e;case 3:case 4:zt=_.stateNode.containerInfo,Wn=!0;break e}_=_.return}if(zt===null)throw Error(n(160));yb(p,x,m),zt=null,Wn=!1,p=m.alternate,p!==null&&(p.return=null),m.return=null}if(a.subtreeFlags&13886)for(a=a.child;a!==null;)Eb(a,s),a=a.sibling}var rr=null;function Eb(s,a){var l=s.alternate,c=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:es(a,s),ts(s),c&4&&(Ka(3,s,s.return),gc(3,s),Ka(5,s,s.return));break;case 1:es(a,s),ts(s),c&512&&(dn||l===null||Tr(l,l.return)),c&64&&sa&&(s=s.updateQueue,s!==null&&(c=s.callbacks,c!==null&&(l=s.shared.hiddenCallbacks,s.shared.hiddenCallbacks=l===null?c:l.concat(c))));break;case 26:var m=rr;if(es(a,s),ts(s),c&512&&(dn||l===null||Tr(l,l.return)),c&4){var p=l!==null?l.memoizedState:null;if(c=s.memoizedState,l===null)if(c===null)if(s.stateNode===null){e:{c=s.type,l=s.memoizedProps,m=m.ownerDocument||m;t:switch(c){case"title":p=m.getElementsByTagName("title")[0],(!p||p[dr]||p[ln]||p.namespaceURI==="http://www.w3.org/2000/svg"||p.hasAttribute("itemprop"))&&(p=m.createElement(c),m.head.insertBefore(p,m.querySelector("head > title"))),kn(p,c,l),p[ln]=s,on(p),c=p;break e;case"link":var x=Ex("link","href",m).get(c+(l.href||""));if(x){for(var _=0;_<x.length;_++)if(p=x[_],p.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&p.getAttribute("rel")===(l.rel==null?null:l.rel)&&p.getAttribute("title")===(l.title==null?null:l.title)&&p.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){x.splice(_,1);break t}}p=m.createElement(c),kn(p,c,l),m.head.appendChild(p);break;case"meta":if(x=Ex("meta","content",m).get(c+(l.content||""))){for(_=0;_<x.length;_++)if(p=x[_],p.getAttribute("content")===(l.content==null?null:""+l.content)&&p.getAttribute("name")===(l.name==null?null:l.name)&&p.getAttribute("property")===(l.property==null?null:l.property)&&p.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&p.getAttribute("charset")===(l.charSet==null?null:l.charSet)){x.splice(_,1);break t}}p=m.createElement(c),kn(p,c,l),m.head.appendChild(p);break;default:throw Error(n(468,c))}p[ln]=s,on(p),c=p}s.stateNode=c}else _x(m,s.type,s.stateNode);else s.stateNode=xx(m,c,s.memoizedProps);else p!==c?(p===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):p.count--,c===null?_x(m,s.type,s.stateNode):xx(m,c,s.memoizedProps)):c===null&&s.stateNode!==null&&ep(s,s.memoizedProps,l.memoizedProps)}break;case 27:es(a,s),ts(s),c&512&&(dn||l===null||Tr(l,l.return)),l!==null&&c&4&&ep(s,s.memoizedProps,l.memoizedProps);break;case 5:if(es(a,s),ts(s),c&512&&(dn||l===null||Tr(l,l.return)),s.flags&32){m=s.stateNode;try{Zn(m,"")}catch(Ne){bt(s,s.return,Ne)}}c&4&&s.stateNode!=null&&(m=s.memoizedProps,ep(s,m,l!==null?l.memoizedProps:m)),c&1024&&(sp=!0);break;case 6:if(es(a,s),ts(s),c&4){if(s.stateNode===null)throw Error(n(162));c=s.memoizedProps,l=s.stateNode;try{l.nodeValue=c}catch(Ne){bt(s,s.return,Ne)}}break;case 3:if(td=null,m=rr,rr=Wh(a.containerInfo),es(a,s),rr=m,ts(s),c&4&&l!==null&&l.memoizedState.isDehydrated)try{Ro(a.containerInfo)}catch(Ne){bt(s,s.return,Ne)}sp&&(sp=!1,_b(s));break;case 4:c=rr,rr=Wh(s.stateNode.containerInfo),es(a,s),ts(s),rr=c;break;case 12:es(a,s),ts(s);break;case 31:es(a,s),ts(s),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Vh(s,c)));break;case 13:es(a,s),ts(s),s.child.flags&8192&&s.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(Gh=En()),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Vh(s,c)));break;case 22:m=s.memoizedState!==null;var j=l!==null&&l.memoizedState!==null,Q=sa,re=dn;if(sa=Q||m,dn=re||j,es(a,s),dn=re,sa=Q,ts(s),c&8192)e:for(a=s.stateNode,a._visibility=m?a._visibility&-2:a._visibility|1,m&&(l===null||j||sa||dn||rl(s)),l=null,a=s;;){if(a.tag===5||a.tag===26){if(l===null){j=l=a;try{if(p=j.stateNode,m)x=p.style,typeof x.setProperty=="function"?x.setProperty("display","none","important"):x.display="none";else{_=j.stateNode;var oe=j.memoizedProps.style,X=oe!=null&&oe.hasOwnProperty("display")?oe.display:null;_.style.display=X==null||typeof X=="boolean"?"":(""+X).trim()}}catch(Ne){bt(j,j.return,Ne)}}}else if(a.tag===6){if(l===null){j=a;try{j.stateNode.nodeValue=m?"":j.memoizedProps}catch(Ne){bt(j,j.return,Ne)}}}else if(a.tag===18){if(l===null){j=a;try{var ee=j.stateNode;m?hx(ee,!0):hx(j.stateNode,!1)}catch(Ne){bt(j,j.return,Ne)}}}else if((a.tag!==22&&a.tag!==23||a.memoizedState===null||a===s)&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===s)break e;for(;a.sibling===null;){if(a.return===null||a.return===s)break e;l===a&&(l=null),a=a.return}l===a&&(l=null),a.sibling.return=a.return,a=a.sibling}c&4&&(c=s.updateQueue,c!==null&&(l=c.retryQueue,l!==null&&(c.retryQueue=null,Vh(s,l))));break;case 19:es(a,s),ts(s),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Vh(s,c)));break;case 30:break;case 21:break;default:es(a,s),ts(s)}}function ts(s){var a=s.flags;if(a&2){try{for(var l,c=s.return;c!==null;){if(fb(c)){l=c;break}c=c.return}if(l==null)throw Error(n(160));switch(l.tag){case 27:var m=l.stateNode,p=tp(s);Ph(s,p,m);break;case 5:var x=l.stateNode;l.flags&32&&(Zn(x,""),l.flags&=-33);var _=tp(s);Ph(s,_,x);break;case 3:case 4:var j=l.stateNode.containerInfo,Q=tp(s);np(s,Q,j);break;default:throw Error(n(161))}}catch(re){bt(s,s.return,re)}s.flags&=-3}a&4096&&(s.flags&=-4097)}function _b(s){if(s.subtreeFlags&1024)for(s=s.child;s!==null;){var a=s;_b(a),a.tag===5&&a.flags&1024&&a.stateNode.reset(),s=s.sibling}}function aa(s,a){if(a.subtreeFlags&8772)for(a=a.child;a!==null;)gb(s,a.alternate,a),a=a.sibling}function rl(s){for(s=s.child;s!==null;){var a=s;switch(a.tag){case 0:case 11:case 14:case 15:Ka(4,a,a.return),rl(a);break;case 1:Tr(a,a.return);var l=a.stateNode;typeof l.componentWillUnmount=="function"&&hb(a,a.return,l),rl(a);break;case 27:Tc(a.stateNode);case 26:case 5:Tr(a,a.return),rl(a);break;case 22:a.memoizedState===null&&rl(a);break;case 30:rl(a);break;default:rl(a)}s=s.sibling}}function ia(s,a,l){for(l=l&&(a.subtreeFlags&8772)!==0,a=a.child;a!==null;){var c=a.alternate,m=s,p=a,x=p.flags;switch(p.tag){case 0:case 11:case 15:ia(m,p,l),gc(4,p);break;case 1:if(ia(m,p,l),c=p,m=c.stateNode,typeof m.componentDidMount=="function")try{m.componentDidMount()}catch(Q){bt(c,c.return,Q)}if(c=p,m=c.updateQueue,m!==null){var _=c.stateNode;try{var j=m.shared.hiddenCallbacks;if(j!==null)for(m.shared.hiddenCallbacks=null,m=0;m<j.length;m++)ey(j[m],_)}catch(Q){bt(c,c.return,Q)}}l&&x&64&&Bb(p),Cc(p,p.return);break;case 27:mb(p);case 26:case 5:ia(m,p,l),l&&c===null&&x&4&&db(p),Cc(p,p.return);break;case 12:ia(m,p,l);break;case 31:ia(m,p,l),l&&x&4&&bb(m,p);break;case 13:ia(m,p,l),l&&x&4&&xb(m,p);break;case 22:p.memoizedState===null&&ia(m,p,l),Cc(p,p.return);break;case 30:break;default:ia(m,p,l)}a=a.sibling}}function rp(s,a){var l=null;s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(l=s.memoizedState.cachePool.pool),s=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(s=a.memoizedState.cachePool.pool),s!==l&&(s!=null&&s.refCount++,l!=null&&rc(l))}function ap(s,a){s=null,a.alternate!==null&&(s=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==s&&(a.refCount++,s!=null&&rc(s))}function ar(s,a,l,c){if(a.subtreeFlags&10256)for(a=a.child;a!==null;)Db(s,a,l,c),a=a.sibling}function Db(s,a,l,c){var m=a.flags;switch(a.tag){case 0:case 11:case 15:ar(s,a,l,c),m&2048&&gc(9,a);break;case 1:ar(s,a,l,c);break;case 3:ar(s,a,l,c),m&2048&&(s=null,a.alternate!==null&&(s=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==s&&(a.refCount++,s!=null&&rc(s)));break;case 12:if(m&2048){ar(s,a,l,c),s=a.stateNode;try{var p=a.memoizedProps,x=p.id,_=p.onPostCommit;typeof _=="function"&&_(x,a.alternate===null?"mount":"update",s.passiveEffectDuration,-0)}catch(j){bt(a,a.return,j)}}else ar(s,a,l,c);break;case 31:ar(s,a,l,c);break;case 13:ar(s,a,l,c);break;case 23:break;case 22:p=a.stateNode,x=a.alternate,a.memoizedState!==null?p._visibility&2?ar(s,a,l,c):yc(s,a):p._visibility&2?ar(s,a,l,c):(p._visibility|=2,xo(s,a,l,c,(a.subtreeFlags&10256)!==0||!1)),m&2048&&rp(x,a);break;case 24:ar(s,a,l,c),m&2048&&ap(a.alternate,a);break;default:ar(s,a,l,c)}}function xo(s,a,l,c,m){for(m=m&&((a.subtreeFlags&10256)!==0||!1),a=a.child;a!==null;){var p=s,x=a,_=l,j=c,Q=x.flags;switch(x.tag){case 0:case 11:case 15:xo(p,x,_,j,m),gc(8,x);break;case 23:break;case 22:var re=x.stateNode;x.memoizedState!==null?re._visibility&2?xo(p,x,_,j,m):yc(p,x):(re._visibility|=2,xo(p,x,_,j,m)),m&&Q&2048&&rp(x.alternate,x);break;case 24:xo(p,x,_,j,m),m&&Q&2048&&ap(x.alternate,x);break;default:xo(p,x,_,j,m)}a=a.sibling}}function yc(s,a){if(a.subtreeFlags&10256)for(a=a.child;a!==null;){var l=s,c=a,m=c.flags;switch(c.tag){case 22:yc(l,c),m&2048&&rp(c.alternate,c);break;case 24:yc(l,c),m&2048&&ap(c.alternate,c);break;default:yc(l,c)}a=a.sibling}}var bc=8192;function Eo(s,a,l){if(s.subtreeFlags&bc)for(s=s.child;s!==null;)vb(s,a,l),s=s.sibling}function vb(s,a,l){switch(s.tag){case 26:Eo(s,a,l),s.flags&bc&&s.memoizedState!==null&&ST(l,rr,s.memoizedState,s.memoizedProps);break;case 5:Eo(s,a,l);break;case 3:case 4:var c=rr;rr=Wh(s.stateNode.containerInfo),Eo(s,a,l),rr=c;break;case 22:s.memoizedState===null&&(c=s.alternate,c!==null&&c.memoizedState!==null?(c=bc,bc=16777216,Eo(s,a,l),bc=c):Eo(s,a,l));break;default:Eo(s,a,l)}}function wb(s){var a=s.alternate;if(a!==null&&(s=a.child,s!==null)){a.child=null;do a=s.sibling,s.sibling=null,s=a;while(s!==null)}}function xc(s){var a=s.deletions;if((s.flags&16)!==0){if(a!==null)for(var l=0;l<a.length;l++){var c=a[l];wn=c,Ab(c,s)}wb(s)}if(s.subtreeFlags&10256)for(s=s.child;s!==null;)Tb(s),s=s.sibling}function Tb(s){switch(s.tag){case 0:case 11:case 15:xc(s),s.flags&2048&&Ka(9,s,s.return);break;case 3:xc(s);break;case 12:xc(s);break;case 22:var a=s.stateNode;s.memoizedState!==null&&a._visibility&2&&(s.return===null||s.return.tag!==13)?(a._visibility&=-3,Fh(s)):xc(s);break;default:xc(s)}}function Fh(s){var a=s.deletions;if((s.flags&16)!==0){if(a!==null)for(var l=0;l<a.length;l++){var c=a[l];wn=c,Ab(c,s)}wb(s)}for(s=s.child;s!==null;){switch(a=s,a.tag){case 0:case 11:case 15:Ka(8,a,a.return),Fh(a);break;case 22:l=a.stateNode,l._visibility&2&&(l._visibility&=-3,Fh(a));break;default:Fh(a)}s=s.sibling}}function Ab(s,a){for(;wn!==null;){var l=wn;switch(l.tag){case 0:case 11:case 15:Ka(8,l,a);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var c=l.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:rc(l.memoizedState.cache)}if(c=l.child,c!==null)c.return=l,wn=c;else e:for(l=s;wn!==null;){c=wn;var m=c.sibling,p=c.return;if(Cb(c),c===l){wn=null;break e}if(m!==null){m.return=p,wn=m;break e}
vendor: 15,076 bytes, line 48
48wn=p}}}var Kw={getCacheForType:function(s){var a=Rn(cn),l=a.data.get(s);return l===void 0&&(l=s(),a.data.set(s,l)),l},cacheSignal:function(){return Rn(cn).controller.signal}},Jw=typeof WeakMap=="function"?WeakMap:Map,pt=0,Nt=null,et=null,nt=0,yt=0,gs=null,Ja=!1,_o=!1,ip=!1,la=0,$t=0,Qa=0,al=0,lp=0,Cs=0,Do=0,Ec=null,ns=null,op=!1,Gh=0,Nb=0,Hh=1/0,Uh=null,Ya=null,Cn=0,Xa=null,vo=null,oa=0,up=0,cp=null,Ib=null,_c=0,Bp=null;function ys(){return(pt&2)!==0&&nt!==0?nt&-nt:$.T!==null?gp():zB()}function Sb(){if(Cs===0)if((nt&536870912)===0||rt){var s=zr;zr<<=1,(zr&3932160)===0&&(zr=262144),Cs=s}else Cs=536870912;return s=ms.current,s!==null&&(s.flags|=32),Cs}function ss(s,a,l){(s===Nt&&(yt===2||yt===9)||s.cancelPendingCommit!==null)&&(wo(s,0),$a(s,nt,Cs,!1)),Oi(s,l),((pt&2)===0||s!==Nt)&&(s===Nt&&((pt&2)===0&&(al|=l),$t===4&&$a(s,nt,Cs,!1)),Ar(s))}function Rb(s,a,l){if((pt&6)!==0)throw Error(n(327));var c=!l&&(a&127)===0&&(a&s.expiredLanes)===0||Ys(s,a),m=c?Xw(s,a):dp(s,a,!0),p=c;do{if(m===0){_o&&!c&&$a(s,a,0,!1);break}else{if(l=s.current.alternate,p&&!Qw(l)){m=dp(s,a,!1),p=!1;continue}if(m===2){if(p=a,s.errorRecoveryDisabledLanes&p)var x=0;else x=s.pendingLanes&-536870913,x=x!==0?x:x&536870912?536870912:0;if(x!==0){a=x;e:{var _=s;m=Ec;var j=_.current.memoizedState.isDehydrated;if(j&&(wo(_,x).flags|=256),x=dp(_,x,!1),x!==2){if(ip&&!j){_.errorRecoveryDisabledLanes|=p,al|=p,m=4;break e}p=ns,ns=m,p!==null&&(ns===null?ns=p:ns.push.apply(ns,p))}m=x}if(p=!1,m!==2)continue}}if(m===1){wo(s,0),$a(s,a,0,!0);break}e:{switch(c=s,p=m,p){case 0:case 1:throw Error(n(345));case 4:if((a&4194048)!==a)break;case 6:$a(c,a,Cs,!Ja);break e;case 2:ns=null;break;case 3:case 5:break;default:throw Error(n(329))}if((a&62914560)===a&&(m=Gh+300-En(),10<m)){if($a(c,a,Cs,!Ja),Nn(c,0,!0)!==0)break e;oa=a,c.timeoutHandle=ux(Ob.bind(null,c,l,ns,Uh,op,a,Cs,al,Do,Ja,p,"Throttled",-0,0),m);break e}Ob(c,l,ns,Uh,op,a,Cs,al,Do,Ja,p,null,-0,0)}}break}while(!0);Ar(s)}function Ob(s,a,l,c,m,p,x,_,j,Q,re,oe,X,ee){if(s.timeoutHandle=-1,oe=a.subtreeFlags,oe&8192||(oe&16785408)===16785408){oe={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Zs},vb(a,p,oe);var Ne=(p&62914560)===p?Gh-En():(p&4194048)===p?Nb-En():0;if(Ne=RT(oe,Ne),Ne!==null){oa=p,s.cancelPendingCommit=Ne(Gb.bind(null,s,a,p,l,c,m,x,_,j,re,oe,null,X,ee)),$a(s,p,x,!Q);return}}Gb(s,a,p,l,c,m,x,_,j)}function Qw(s){for(var a=s;;){var l=a.tag;if((l===0||l===11||l===15)&&a.flags&16384&&(l=a.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var c=0;c<l.length;c++){var m=l[c],p=m.getSnapshot;m=m.value;try{if(!ds(p(),m))return!1}catch{return!1}}if(l=a.child,a.subtreeFlags&16384&&l!==null)l.return=a,a=l;else{if(a===s)break;for(;a.sibling===null;){if(a.return===null||a.return===s)return!0;a=a.return}a.sibling.return=a.return,a=a.sibling}}return!0}function $a(s,a,l,c){a&=~lp,a&=~al,s.suspendedLanes|=a,s.pingedLanes&=~a,c&&(s.warmLanes|=a),c=s.expirationTimes;for(var m=a;0<m;){var p=31-Ht(m),x=1<<p;c[p]=-1,m&=~x}l!==0&&ki(s,l,a)}function zh(){return(pt&6)===0?(Dc(0),!1):!0}function hp(){if(et!==null){if(yt===0)var s=et.return;else s=et,$r=Xi=null,Am(s),po=null,ic=0,s=et;for(;s!==null;)cb(s.alternate,s),s=s.return;et=null}}function wo(s,a){var l=s.timeoutHandle;l!==-1&&(s.timeoutHandle=-1,fT(l)),l=s.cancelPendingCommit,l!==null&&(s.cancelPendingCommit=null,l()),oa=0,hp(),Nt=s,et=l=Yr(s.current,null),nt=a,yt=0,gs=null,Ja=!1,_o=Ys(s,a),ip=!1,Do=Cs=lp=al=Qa=$t=0,ns=Ec=null,op=!1,(a&8)!==0&&(a|=a&32);var c=s.entangledLanes;if(c!==0)for(s=s.entanglements,c&=a;0<c;){var m=31-Ht(c),p=1<<m;a|=s[m],c&=~p}return la=a,Bh(),l}function kb(s,a){Ye=null,$.H=fc,a===mo||a===yh?(a=X0(),yt=3):a===pm?(a=X0(),yt=4):yt=a===zm?8:a!==null&&typeof a=="object"&&typeof a.then=="function"?6:1,gs=a,et===null&&($t=1,Oh(s,Ls(a,s.current)))}function Lb(){var s=ms.current;return s===null?!0:(nt&4194048)===nt?Vs===null:(nt&62914560)===nt||(nt&536870912)!==0?s===Vs:!1}function jb(){var s=$.H;return $.H=fc,s===null?fc:s}function Mb(){var s=$.A;return $.A=Kw,s}function qh(){$t=4,Ja||(nt&4194048)!==nt&&ms.current!==null||(_o=!0),(Qa&134217727)===0&&(al&134217727)===0||Nt===null||$a(Nt,nt,Cs,!1)}function dp(s,a,l){var c=pt;pt|=2;var m=jb(),p=Mb();(Nt!==s||nt!==a)&&(Uh=null,wo(s,a)),a=!1;var x=$t;e:do try{if(yt!==0&&et!==null){var _=et,j=gs;switch(yt){case 8:hp(),x=6;break e;case 3:case 2:case 9:case 6:ms.current===null&&(a=!0);var Q=yt;if(yt=0,gs=null,To(s,_,j,Q),l&&_o){x=0;break e}break;default:Q=yt,yt=0,gs=null,To(s,_,j,Q)}}Yw(),x=$t;break}catch(re){kb(s,re)}while(!0);return a&&s.shellSuspendCounter++,$r=Xi=null,pt=c,$.H=m,$.A=p,et===null&&(Nt=null,nt=0,Bh()),x}function Yw(){for(;et!==null;)Pb(et)}function Xw(s,a){var l=pt;pt|=2;var c=jb(),m=Mb();Nt!==s||nt!==a?(Uh=null,Hh=En()+500,wo(s,a)):_o=Ys(s,a);e:do try{if(yt!==0&&et!==null){a=et;var p=gs;t:switch(yt){case 1:yt=0,gs=null,To(s,a,p,1);break;case 2:case 9:if(Q0(p)){yt=0,gs=null,Vb(a);break}a=function(){yt!==2&&yt!==9||Nt!==s||(yt=7),Ar(s)},p.then(a,a);break e;case 3:yt=7;break e;case 4:yt=5;break e;case 7:Q0(p)?(yt=0,gs=null,Vb(a)):(yt=0,gs=null,To(s,a,p,7));break;case 5:var x=null;switch(et.tag){case 26:x=et.memoizedState;case 5:case 27:var _=et;if(x?Dx(x):_.stateNode.complete){yt=0,gs=null;var j=_.sibling;if(j!==null)et=j;else{var Q=_.return;Q!==null?(et=Q,Kh(Q)):et=null}break t}}yt=0,gs=null,To(s,a,p,5);break;case 6:yt=0,gs=null,To(s,a,p,6);break;case 8:hp(),$t=6;break e;default:throw Error(n(462))}}$w();break}catch(re){kb(s,re)}while(!0);return $r=Xi=null,$.H=c,$.A=m,pt=l,et!==null?0:(Nt=null,nt=0,Bh(),$t)}function $w(){for(;et!==null&&!Ul();)Pb(et)}function Pb(s){var a=ob(s.alternate,s,la);s.memoizedProps=s.pendingProps,a===null?Kh(s):et=a}function Vb(s){var a=s,l=a.alternate;switch(a.tag){case 15:case 0:a=nb(l,a,a.pendingProps,a.type,void 0,nt);break;case 11:a=nb(l,a,a.pendingProps,a.type.render,a.ref,nt);break;case 5:Am(a);default:cb(l,a),a=et=M0(a,la),a=ob(l,a,la)}s.memoizedProps=s.pendingProps,a===null?Kh(s):et=a}function To(s,a,l,c){$r=Xi=null,Am(a),po=null,ic=0;var m=a.return;try{if(Vw(s,m,a,l,nt)){$t=1,Oh(s,Ls(l,s.current)),et=null;return}}catch(p){if(m!==null)throw et=m,p;$t=1,Oh(s,Ls(l,s.current)),et=null;return}a.flags&32768?(rt||c===1?s=!0:_o||(nt&536870912)!==0?s=!1:(Ja=s=!0,(c===2||c===9||c===3||c===6)&&(c=ms.current,c!==null&&c.tag===13&&(c.flags|=16384))),Fb(a,s)):Kh(a)}function Kh(s){var a=s;do{if((a.flags&32768)!==0){Fb(a,Ja);return}s=a.return;var l=Hw(a.alternate,a,la);if(l!==null){et=l;return}if(a=a.sibling,a!==null){et=a;return}et=a=s}while(a!==null);$t===0&&($t=5)}function Fb(s,a){do{var l=Uw(s.alternate,s);if(l!==null){l.flags&=32767,et=l;return}if(l=s.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!a&&(s=s.sibling,s!==null)){et=s;return}et=s=l}while(s!==null);$t=6,et=null}function Gb(s,a,l,c,m,p,x,_,j){s.cancelPendingCommit=null;do Jh();while(Cn!==0);if((pt&6)!==0)throw Error(n(327));if(a!==null){if(a===s.current)throw Error(n(177));if(p=a.lanes|a.childLanes,p|=tm,Kf(s,l,p,x,_,j),s===Nt&&(et=Nt=null,nt=0),vo=a,Xa=s,oa=l,up=p,cp=m,Ib=c,(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?(s.callbackNode=null,s.callbackPriority=0,tT(ze,function(){return Kb(),null})):(s.callbackNode=null,s.callbackPriority=0),c=(a.flags&13878)!==0,(a.subtreeFlags&13878)!==0||c){c=$.T,$.T=null,m=pe.p,pe.p=2,x=pt,pt|=4;try{zw(s,a,l)}finally{pt=x,pe.p=m,$.T=c}}Cn=1,Hb(),Ub(),zb()}}function Hb(){if(Cn===1){Cn=0;var s=Xa,a=vo,l=(a.flags&13878)!==0;if((a.subtreeFlags&13878)!==0||l){l=$.T,$.T=null;var c=pe.p;pe.p=2;var m=pt;pt|=4;try{Eb(a,s);var p=vp,x=A0(s.containerInfo),_=p.focusedElem,j=p.selectionRange;if(x!==_&&_&&_.ownerDocument&&T0(_.ownerDocument.documentElement,_)){if(j!==null&&Xf(_)){var Q=j.start,re=j.end;if(re===void 0&&(re=Q),"selectionStart"in _)_.selectionStart=Q,_.selectionEnd=Math.min(re,_.value.length);else{var oe=_.ownerDocument||document,X=oe&&oe.defaultView||window;if(X.getSelection){var ee=X.getSelection(),Ne=_.textContent.length,Ve=Math.min(j.start,Ne),vt=j.end===void 0?Ve:Math.min(j.end,Ne);!ee.extend&&Ve>vt&&(x=vt,vt=Ve,Ve=x);var H=w0(_,Ve),V=w0(_,vt);if(H&&V&&(ee.rangeCount!==1||ee.anchorNode!==H.node||ee.anchorOffset!==H.offset||ee.focusNode!==V.node||ee.focusOffset!==V.offset)){var J=oe.createRange();J.setStart(H.node,H.offset),ee.removeAllRanges(),Ve>vt?(ee.addRange(J),ee.extend(V.node,V.offset)):(J.setEnd(V.node,V.offset),ee.addRange(J))}}}}for(oe=[],ee=_;ee=ee.parentNode;)ee.nodeType===1&&oe.push({element:ee,left:ee.scrollLeft,top:ee.scrollTop});for(typeof _.focus=="function"&&_.focus(),_=0;_<oe.length;_++){var ie=oe[_];ie.element.scrollLeft=ie.left,ie.element.scrollTop=ie.top}}ad=!!Dp,vp=Dp=null}finally{pt=m,pe.p=c,$.T=l}}s.current=a,Cn=2}}function Ub(){if(Cn===2){Cn=0;var s=Xa,a=vo,l=(a.flags&8772)!==0;if((a.subtreeFlags&8772)!==0||l){l=$.T,$.T=null;var c=pe.p;pe.p=2;var m=pt;pt|=4;try{gb(s,a.alternate,a)}finally{pt=m,pe.p=c,$.T=l}}Cn=3}}function zb(){if(Cn===4||Cn===3){Cn=0,Ri();var s=Xa,a=vo,l=oa,c=Ib;(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?Cn=5:(Cn=0,vo=Xa=null,qb(s,s.pendingLanes));var m=s.pendingLanes;if(m===0&&(Ya=null),qr(l),a=a.stateNode,an&&typeof an.onCommitFiberRoot=="function")try{an.onCommitFiberRoot(Ot,a,void 0,(a.current.flags&128)===128)}catch{}if(c!==null){a=$.T,m=pe.p,pe.p=2,$.T=null;try{for(var p=s.onRecoverableError,x=0;x<c.length;x++){var _=c[x];p(_.value,{componentStack:_.stack})}}finally{$.T=a,pe.p=m}}(oa&3)!==0&&Jh(),Ar(s),m=s.pendingLanes,(l&261930)!==0&&(m&42)!==0?s===Bp?_c++:(_c=0,Bp=s):_c=0,Dc(0)}}function qb(s,a){(s.pooledCacheLanes&=a)===0&&(a=s.pooledCache,a!=null&&(s.pooledCache=null,rc(a)))}function Jh(){return Hb(),Ub(),zb(),Kb()}function Kb(){if(Cn!==5)return!1;var s=Xa,a=up;up=0;var l=qr(oa),c=$.T,m=pe.p;try{pe.p=32>l?32:l,$.T=null,l=cp,cp=null;var p=Xa,x=oa;if(Cn=0,vo=Xa=null,oa=0,(pt&6)!==0)throw Error(n(331));var _=pt;if(pt|=4,Tb(p.current),Db(p,p.current,x,l),pt=_,Dc(0,!1),an&&typeof an.onPostCommitFiberRoot=="function")try{an.onPostCommitFiberRoot(Ot,p)}catch{}return!0}finally{pe.p=m,$.T=c,qb(s,a)}}function Jb(s,a,l){a=Ls(l,a),a=Um(s.stateNode,a,2),s=Ua(s,a,2),s!==null&&(Oi(s,2),Ar(s))}function bt(s,a,l){if(s.tag===3)Jb(s,s,l);else for(;a!==null;){if(a.tag===3){Jb(a,s,l);break}else if(a.tag===1){var c=a.stateNode;if(typeof a.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&(Ya===null||!Ya.has(c))){s=Ls(l,s),l=Qy(2),c=Ua(a,l,2),c!==null&&(Yy(l,c,a,s),Oi(c,2),Ar(c));break}}a=a.return}}function fp(s,a,l){var c=s.pingCache;if(c===null){c=s.pingCache=new Jw;var m=new Set;c.set(a,m)}else m=c.get(a),m===void 0&&(m=new Set,c.set(a,m));m.has(l)||(ip=!0,m.add(l),s=Zw.bind(null,s,a,l),a.then(s,s))}function Zw(s,a,l){var c=s.pingCache;c!==null&&c.delete(a),s.pingedLanes|=s.suspendedLanes&l,s.warmLanes&=~l,Nt===s&&(nt&l)===l&&($t===4||$t===3&&(nt&62914560)===nt&&300>En()-Gh?(pt&2)===0&&wo(s,0):lp|=l,Do===nt&&(Do=0)),Ar(s)}function Qb(s,a){a===0&&(a=UB()),s=Ji(s,a),s!==null&&(Oi(s,a),Ar(s))}function Ww(s){var a=s.memoizedState,l=0;a!==null&&(l=a.retryLane),Qb(s,l)}function eT(s,a){var l=0;switch(s.tag){case 31:case 13:var c=s.stateNode,m=s.memoizedState;m!==null&&(l=m.retryLane);break;case 19:c=s.stateNode;break;case 22:c=s.stateNode._retryCache;break;default:throw Error(n(314))}c!==null&&c.delete(a),Qb(s,l)}function tT(s,a){return Qt(s,a)}var Qh=null,Ao=null,mp=!1,Yh=!1,pp=!1,Za=0;function Ar(s){s!==Ao&&s.next===null&&(Ao===null?Qh=Ao=s:Ao=Ao.next=s),Yh=!0,mp||(mp=!0,sT())}function Dc(s,a){if(!pp&&Yh){pp=!0;do for(var l=!1,c=Qh;c!==null;){if(s!==0){var m=c.pendingLanes;if(m===0)var p=0;else{var x=c.suspendedLanes,_=c.pingedLanes;p=(1<<31-Ht(42|s)+1)-1,p&=m&~(x&~_),p=p&201326741?p&201326741|1:p?p|2:0}p!==0&&(l=!0,Zb(c,p))}else p=nt,p=Nn(c,c===Nt?p:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(p&3)===0||Ys(c,p)||(l=!0,Zb(c,p));c=c.next}while(l);pp=!1}}function nT(){Yb()}function Yb(){Yh=mp=!1;var s=0;Za!==0&&dT()&&(s=Za);for(var a=En(),l=null,c=Qh;c!==null;){var m=c.next,p=Xb(c,a);p===0?(c.next=null,l===null?Qh=m:l.next=m,m===null&&(Ao=l)):(l=c,(s!==0||(p&3)!==0)&&(Yh=!0)),c=m}Cn!==0&&Cn!==5||Dc(s),Za!==0&&(Za=0)}function Xb(s,a){for(var l=s.suspendedLanes,c=s.pingedLanes,m=s.expirationTimes,p=s.pendingLanes&-62914561;0<p;){var x=31-Ht(p),_=1<<x,j=m[x];j===-1?((_&l)===0||(_&c)!==0)&&(m[x]=qf(_,a)):j<=a&&(s.expiredLanes|=_),p&=~_}if(a=Nt,l=nt,l=Nn(s,s===a?l:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),c=s.callbackNode,l===0||s===a&&(yt===2||yt===9)||s.cancelPendingCommit!==null)return c!==null&&c!==null&&Qs(c),s.callbackNode=null,s.callbackPriority=0;if((l&3)===0||Ys(s,l)){if(a=l&-l,a===s.callbackPriority)return a;switch(c!==null&&Qs(c),qr(l)){case 2:case 8:l=Y;break;case 32:l=ze;break;case 268435456:l=At;break;default:l=ze}return c=$b.bind(null,s),l=Qt(l,c),s.callbackPriority=a,s.callbackNode=l,a}return c!==null&&c!==null&&Qs(c),s.callbackPriority=2,s.callbackNode=null,2}function $b(s,a){if(Cn!==0&&Cn!==5)return s.callbackNode=null,s.callbackPriority=0,null;var l=s.callbackNode;if(Jh()&&s.callbackNode!==l)return null;var c=nt;return c=Nn(s,s===Nt?c:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),c===0?null:(Rb(s,c,a),Xb(s,En()),s.callbackNode!=null&&s.callbackNode===l?$b.bind(null,s):null)}function Zb(s,a){if(Jh())return null;Rb(s,a,!0)}function sT(){mT(function(){(pt&6)!==0?Qt(wa,nT):Yb()})}function gp(){if(Za===0){var s=ho;s===0&&(s=Ns,Ns<<=1,(Ns&261888)===0&&(Ns=256)),Za=s}return Za}function Wb(s){return s==null||typeof s=="symbol"||typeof s=="boolean"?null:typeof s=="function"?s:$l(""+s)}function ex(s,a){var l=a.ownerDocument.createElement("input");return l.name=a.name,l.value=a.value,s.id&&l.setAttribute("form",s.id),a.parentNode.insertBefore(l,a),s=new FormData(s),l.parentNode.removeChild(l),s}function rT(s,a,l,c,m){if(a==="submit"&&l&&l.stateNode===m){var p=Wb((m[Dn]||null).action),x=c.submitter;x&&(a=(a=x[Dn]||null)?Wb(a.formAction):x.getAttribute("formAction"),a!==null&&(p=a,x=null));var _=new xr("action","action",null,c,m);s.push({event:_,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(Za!==0){var j=x?ex(m,x):new FormData(m);Mm(l,{pending:!0,data:j,method:m.method,action:p},null,j)}}else typeof p=="function"&&(_.preventDefault(),j=x?ex(m,x):new FormData(m),Mm(l,{pending:!0,data:j,method:m.method,action:p},p,j))},currentTarget:m}]})}}for(var Cp=0;Cp<em.length;Cp++){var yp=em[Cp],aT=yp.toLowerCase(),iT=yp[0].toUpperCase()+yp.slice(1);sr(aT,"on"+iT)}sr(S0,"onAnimationEnd"),sr(R0,"onAnimationIteration"),sr(O0,"onAnimationStart"),sr("dblclick","onDoubleClick"),sr("focusin","onFocus"),sr("focusout","onBlur"),sr(Ew,"onTransitionRun"),sr(_w,"onTransitionStart"),sr(Dw,"onTransitionCancel"),sr(k0,"onTransitionEnd"),gr("onMouseEnter",["mouseout","mouseover"]),gr("onMouseLeave",["mouseout","mouseover"]),gr("onPointerEnter",["pointerout","pointerover"]),gr("onPointerLeave",["pointerout","pointerover"]),pr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),pr("onSelect","focusout contextmenu dragend focu
48sin keydown keyup mousedown mouseup selectionchange".split(" ")),pr("onBeforeInput",["compositionend","keypress","textInput","paste"]),pr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),pr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),pr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var vc="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(" "),lT=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(vc));function tx(s,a){a=(a&4)!==0;for(var l=0;l<s.length;l++){var c=s[l],m=c.event;c=c.listeners;e:{var p=void 0;if(a)for(var x=c.length-1;0<=x;x--){var _=c[x],j=_.instance,Q=_.currentTarget;if(_=_.listener,j!==p&&m.isPropagationStopped())break e;p=_,m.currentTarget=Q;try{p(m)}catch(re){ch(re)}m.currentTarget=null,p=j}else for(x=0;x<c.length;x++){if(_=c[x],j=_.instance,Q=_.currentTarget,_=_.listener,j!==p&&m.isPropagationStopped())break e;p=_,m.currentTarget=Q;try{p(m)}catch(re){ch(re)}m.currentTarget=null,p=j}}}}function tt(s,a){var l=a[Kl];l===void 0&&(l=a[Kl]=new Set);var c=s+"__bubble";l.has(c)||(nx(a,s,2,!1),l.add(c))}function bp(s,a,l){var c=0;a&&(c|=4),nx(l,s,c,a)}var Xh="_reactListening"+Math.random().toString(36).slice(2);function xp(s){if(!s[Xh]){s[Xh]=!0,Mu.forEach(function(l){l!=="selectionchange"&&(lT.has(l)||bp(l,!1,s),bp(l,!0,s))});var a=s.nodeType===9?s:s.ownerDocument;a===null||a[Xh]||(a[Xh]=!0,bp("selectionchange",!1,a))}}function nx(s,a,l,c){switch(Sx(a)){case 2:var m=LT;break;case 8:m=jT;break;default:m=jp}l=m.bind(null,a,l,s),m=void 0,!Vi||a!=="touchstart"&&a!=="touchmove"&&a!=="wheel"||(m=!0),c?m!==void 0?s.addEventListener(a,l,{capture:!0,passive:m}):s.addEventListener(a,l,!0):m!==void 0?s.addEventListener(a,l,{passive:m}):s.addEventListener(a,l,!1)}function Ep(s,a,l,c,m){var p=c;if((a&1)===0&&(a&2)===0&&c!==null)e:for(;;){if(c===null)return;var x=c.tag;if(x===3||x===4){var _=c.stateNode.containerInfo;if(_===m)break;if(x===4)for(x=c.return;x!==null;){var j=x.tag;if((j===3||j===4)&&x.stateNode.containerInfo===m)return;x=x.return}for(;_!==null;){if(x=fr(_),x===null)return;if(j=x.tag,j===5||j===6||j===26||j===27){c=p=x;continue e}_=_.parentNode}}c=c.return}Oa(function(){var Q=p,re=Ss(l),oe=[];e:{var X=L0.get(s);if(X!==void 0){var ee=xr,Ne=s;switch(s){case"keypress":if(Gi(l)===0)break e;case"keydown":case"keyup":ee=lh;break;case"focusin":Ne="focus",ee=Ui;break;case"focusout":Ne="blur",ee=Ui;break;case"beforeblur":case"afterblur":ee=Ui;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ee=Xu;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ee=ZB;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ee=C;break;case S0:case R0:case O0:ee=eh;break;case k0:ee=v;break;case"scroll":case"scrollend":ee=Yu;break;case"wheel":ee=Z;break;case"copy":case"cut":case"paste":ee=th;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ee=Qr;break;case"toggle":case"beforetoggle":ee=Qe}var Ve=(a&4)!==0,vt=!Ve&&(s==="scroll"||s==="scrollend"),H=Ve?X!==null?X+"Capture":null:X;Ve=[];for(var V=Q,J;V!==null;){var ie=V;if(J=ie.stateNode,ie=ie.tag,ie!==5&&ie!==26&&ie!==27||J===null||H===null||(ie=Ws(V,H),ie!=null&&Ve.push(wc(V,ie,J))),vt)break;V=V.return}0<Ve.length&&(X=new ee(X,Ne,null,l,re),oe.push({event:X,listeners:Ve}))}}if((a&7)===0){e:{if(X=s==="mouseover"||s==="pointerover",ee=s==="mouseout"||s==="pointerout",X&&l!==Ku&&(Ne=l.relatedTarget||l.fromElement)&&(fr(Ne)||Ne[hr]))break e;if((ee||X)&&(X=re.window===re?re:(X=re.ownerDocument)?X.defaultView||X.parentWindow:window,ee?(Ne=l.relatedTarget||l.toElement,ee=Q,Ne=Ne?fr(Ne):null,Ne!==null&&(vt=o(Ne),Ve=Ne.tag,Ne!==vt||Ve!==5&&Ve!==27&&Ve!==6)&&(Ne=null)):(ee=null,Ne=Q),ee!==Ne)){if(Ve=Xu,ie="onMouseLeave",H="onMouseEnter",V="mouse",(s==="pointerout"||s==="pointerover")&&(Ve=Qr,ie="onPointerLeave",H="onPointerEnter",V="pointer"),vt=ee==null?X:Bs(ee),J=Ne==null?X:Bs(Ne),X=new Ve(ie,V+"leave",ee,l,re),X.target=vt,X.relatedTarget=J,ie=null,fr(re)===Q&&(Ve=new Ve(H,V+"enter",Ne,l,re),Ve.target=J,Ve.relatedTarget=vt,ie=Ve),vt=ie,ee&&Ne)t:{for(Ve=oT,H=ee,V=Ne,J=0,ie=H;ie;ie=Ve(ie))J++;ie=0;for(var Pe=V;Pe;Pe=Ve(Pe))ie++;for(;0<J-ie;)H=Ve(H),J--;for(;0<ie-J;)V=Ve(V),ie--;for(;J--;){if(H===V||V!==null&&H===V.alternate){Ve=H;break t}H=Ve(H),V=Ve(V)}Ve=null}else Ve=null;ee!==null&&sx(oe,X,ee,Ve,!1),Ne!==null&&vt!==null&&sx(oe,vt,Ne,Ve,!0)}}
vendor: 5,209 bytes, lines 48-49
48e:{if(X=Q?Bs(Q):window,ee=X.nodeName&&X.nodeName.toLowerCase(),ee==="select"||ee==="input"&&X.type==="file")var dt=b0;else if(C0(X))if(x0)dt=yw;else{dt=gw;var Oe=pw}else ee=X.nodeName,!ee||ee.toLowerCase()!=="input"||X.type!=="checkbox"&&X.type!=="radio"?Q&&Xl(Q.elementType)&&(dt=b0):dt=Cw;if(dt&&(dt=dt(s,Q))){y0(oe,dt,l,re);break e}Oe&&Oe(s,X,Q),s==="focusout"&&Q&&X.type==="number"&&Q.memoizedProps.value!=null&&Uu(X,"number",X.value)}switch(Oe=Q?Bs(Q):window,s){case"focusin":(C0(Oe)||Oe.contentEditable==="true")&&(ro=Oe,$f=Q,tc=null);break;case"focusout":tc=$f=ro=null;break;case"mousedown":Zf=!0;break;case"contextmenu":case"mouseup":case"dragend":Zf=!1,N0(oe,l,re);break;case"selectionchange":if(xw)break;case"keydown":case"keyup":N0(oe,l,re)}var $e;if(mt)e:{switch(s){case"compositionstart":var st="onCompositionStart";break e;case"compositionend":st="onCompositionEnd";break e;case"compositionupdate":st="onCompositionUpdate";break e}st=void 0}else so?zi(s,l)&&(st="onCompositionEnd"):s==="keydown"&&l.keyCode===229&&(st="onCompositionStart");st&&(Dr&&l.locale!=="ko"&&(so||st!=="onCompositionStart"?st==="onCompositionEnd"&&so&&($e=Qu()):(br=re,Ju="value"in br?br.value:br.textContent,so=!0)),Oe=$h(Q,st),0<Oe.length&&(st=new _r(st,s,null,l,re),oe.push({event:st,listeners:Oe}),$e?st.data=$e:($e=no(l),$e!==null&&(st.data=$e)))),($e=Os?hw(s,l):dw(s,l))&&(st=$h(Q,"onBeforeInput"),0<st.length&&(Oe=new _r("onBeforeInput","beforeinput",null,l,re),oe.push({event:Oe,listeners:st}),Oe.data=$e)),rT(oe,s,Q,l,re)}tx(oe,a)})}function wc(s,a,l){return{instance:s,listener:a,currentTarget:l}}function $h(s,a){for(var l=a+"Capture",c=[];s!==null;){var m=s,p=m.stateNode;if(m=m.tag,m!==5&&m!==26&&m!==27||p===null||(m=Ws(s,l),m!=null&&c.unshift(wc(s,m,p)),m=Ws(s,a),m!=null&&c.push(wc(s,m,p))),s.tag===3)return c;s=s.return}return[]}function oT(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5&&s.tag!==27);return s||null}function sx(s,a,l,c,m){for(var p=a._reactName,x=[];l!==null&&l!==c;){var _=l,j=_.alternate,Q=_.stateNode;if(_=_.tag,j!==null&&j===c)break;_!==5&&_!==26&&_!==27||Q===null||(j=Q,m?(Q=Ws(l,p),Q!=null&&x.unshift(wc(l,Q,j))):m||(Q=Ws(l,p),Q!=null&&x.push(wc(l,Q,j)))),l=l.return}x.length!==0&&s.push({event:a,listeners:x})}var uT=/\r\n?/g,cT=/\u0000|\uFFFD/g;function rx(s){return(typeof s=="string"?s:""+s).replace(uT,`
49`).replace(cT,"")}function ax(s,a){return a=rx(a),rx(s)===a}function Dt(s,a,l,c,m,p){switch(l){case"children":typeof c=="string"?a==="body"||a==="textarea"&&c===""||Zn(s,c):(typeof c=="number"||typeof c=="bigint")&&a!=="body"&&Zn(s,""+c);break;case"className":hs(s,"class",c);break;case"tabIndex":hs(s,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":hs(s,l,c);break;case"style":qu(s,c,p);break;case"data":if(a!=="object"){hs(s,"data",c);break}case"src":case"href":if(c===""&&(a!=="a"||l!=="href")){s.removeAttribute(l);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){s.removeAttribute(l);break}c=$l(""+c),s.setAttribute(l,c);break;case"action":case"formAction":if(typeof c=="function"){s.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof p=="function"&&(l==="formAction"?(a!=="input"&&Dt(s,a,"name",m.name,m,null),Dt(s,a,"formEncType",m.formEncType,m,null),Dt(s,a,"formMethod",m.formMethod,m,null),Dt(s,a,"formTarget",m.formTarget,m,null)):(Dt(s,a,"encType",m.encType,m,null),Dt(s,a,"method",m.method,m,null),Dt(s,a,"target",m.target,m,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){s.removeAttribute(l);break}c=$l(""+c),s.setAttribute(l,c);break;case"onClick":c!=null&&(s.onclick=Zs);break;case"onScroll":c!=null&&tt("scroll",s);break;case"onScrollEnd":c!=null&&tt("scrollend",s);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(n(61));if(l=c.__html,l!=null){if(m.children!=null)throw Error(n(60));s.innerHTML=l}}break;case"multiple":s.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":s.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){s.removeAttribute("xlink:href");break}l=$l(""+c),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(l,""+c):s.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInl
49ine":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":c&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(l,""):s.removeAttribute(l);break;case"capture":case"download":c===!0?s.setAttribute(l,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(l,c):s.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?s.setAttribute(l,c):s.removeAttribute(l);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?s.removeAttribute(l):s.setAttribute(l,c);break;case"popover":tt("beforetoggle",s),tt("toggle",s),Ql(s,"popover",c);break;case"xlinkActuate":un(s,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":un(s,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":un(s,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":un(s,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":un(s,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":un(s,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":un(s,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":un(s,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":un(s,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":Ql(s,"is",c);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=$B.get(l)||l,Ql(s,l,c))}}function _p(s,a,l,c,m,p){switch(l){case"style":qu(s,c,p);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(n(61));if(l=c.__html,l!=null){if(m.children!=null)throw Error(n(60));s.innerHTML=l}}break;case"children":typeof c=="string"?Zn(s,c):(typeof c=="number"||typeof c=="bigint")&&Zn(s,""+c);break;case"onScroll":c!=null&&tt("scroll",s);break;case"onScrollEnd":c!=null&&tt("scrollend",s);break;case"onClick":c!=null&&(s.onclick=Zs);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Pu.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(m=l.endsWith("Capture"),a=l.slice(2,m?l.length-7:void 0),p=s[Dn]||null,p=p!=null?p[l]:null,typeof p=="function"&&s.removeEventListener(a,p,m),typeof c=="function")){typeof p!="function"&&p!==null&&(l in s?s[l]=null:s.hasAttribute(l)&&s.removeAttribute(l)),s.addEventListener(a,c,m);break e}l in s?s[l]=c:c===!0?s.setAttribute(l,""):Ql(s,l,c)}}}function kn(s,a,l){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":tt("error",s),tt("load",s);var c=!1,m=!1,p;for(p in l)if(l.hasOwnProperty(p)){var x=l[p];if(x!=null)switch(p){case"src":c=!0;break;case"srcSet":m=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(n(137,a));default:Dt(s,a,p,x,l,null)}}m&&Dt(s,a,"srcSet",l.srcSet,l,null),c&&Dt(s,a,"src",l.src,l,null);return;case"input":tt("invalid",s);var _=p=x=m=null,j=null,Q=null;for(c in l)if(l.hasOwnProperty(c)){var re=l[c];if(re!=null)switch(c){case"name":m=re;break;case"type":x=re;break;case"checked":j=re;break;case"defaultChecked":Q=re;break;case"value":p=re;break;case"defaultValue":_=re;break;case"children":case"dangerouslySetInnerHTML":if(re!=null)throw Error(n(137,a));break;default:Dt(s,a,c,re,l,null)}}QB(s,p,_,j,Q,x,m,!1);return;case"select":tt("invalid",s),c=x=p=null;for(m in l)if(l.hasOwnProperty(m)&&(_=l[m],_!=null))switch(m){case"value":p=_;break;case"defaultValue":x=_;break;case"multiple":c=_;default:Dt(s,a,m,_,l,null)}a=p,l=x,s.multiple=!!c,a!=null?Na(s,!!c,a,!1):l!=null&&Na(s,!!c,l,!0);return;case"textarea":tt("invalid",s),p=m=c=null;for(x in l)if(l.hasOwnProperty(x)&&(_=l[x],_!=null))switch(x){case"value":c=_;break;case"defaultValue":m=_;break;case"children":p=_;break;case"dangerouslySetInnerHTML":if(_!=null)throw Error(n(91));break;default:Dt(s,a,x,_,l,null)}Ia(s,c,m,p);return;case"option":for(j in l)if(l.hasOwnProperty(j)&&(c=l[j],c!=null))switch(j){case"selected":s.selected=c&&typeof c!="function"&&typeof c!="symbol";break;default:Dt(s,a,j,c,l,null)}return;case"dialog":tt("beforetoggle",s),tt("toggle",s),tt("cancel",s),tt("close",s
vendor: 7,653 bytes, line 49
49);break;case"iframe":case"object":tt("load",s);break;case"video":case"audio":for(c=0;c<vc.length;c++)tt(vc[c],s);break;case"image":tt("error",s),tt("load",s);break;case"details":tt("toggle",s);break;case"embed":case"source":case"link":tt("error",s),tt("load",s);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Q in l)if(l.hasOwnProperty(Q)&&(c=l[Q],c!=null))switch(Q){case"children":case"dangerouslySetInnerHTML":throw Error(n(137,a));default:Dt(s,a,Q,c,l,null)}return;default:if(Xl(a)){for(re in l)l.hasOwnProperty(re)&&(c=l[re],c!==void 0&&_p(s,a,re,c,l,void 0));return}}for(_ in l)l.hasOwnProperty(_)&&(c=l[_],c!=null&&Dt(s,a,_,c,l,null))}function BT(s,a,l,c){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var m=null,p=null,x=null,_=null,j=null,Q=null,re=null;for(ee in l){var oe=l[ee];if(l.hasOwnProperty(ee)&&oe!=null)switch(ee){case"checked":break;case"value":break;case"defaultValue":j=oe;default:c.hasOwnProperty(ee)||Dt(s,a,ee,null,c,oe)}}for(var X in c){var ee=c[X];if(oe=l[X],c.hasOwnProperty(X)&&(ee!=null||oe!=null))switch(X){case"type":p=ee;break;case"name":m=ee;break;case"checked":Q=ee;break;case"defaultChecked":re=ee;break;case"value":x=ee;break;case"defaultValue":_=ee;break;case"children":case"dangerouslySetInnerHTML":if(ee!=null)throw Error(n(137,a));break;default:ee!==oe&&Dt(s,a,X,ee,c,oe)}}Yl(s,x,_,j,Q,re,p,m);return;case"select":ee=x=_=X=null;for(p in l)if(j=l[p],l.hasOwnProperty(p)&&j!=null)switch(p){case"value":break;case"multiple":ee=j;default:c.hasOwnProperty(p)||Dt(s,a,p,null,c,j)}for(m in c)if(p=c[m],j=l[m],c.hasOwnProperty(m)&&(p!=null||j!=null))switch(m){case"value":X=p;break;case"defaultValue":_=p;break;case"multiple":x=p;default:p!==j&&Dt(s,a,m,p,c,j)}a=_,l=x,c=ee,X!=null?Na(s,!!l,X,!1):!!c!=!!l&&(a!=null?Na(s,!!l,a,!0):Na(s,!!l,l?[]:"",!1));return;case"textarea":ee=X=null;for(_ in l)if(m=l[_],l.hasOwnProperty(_)&&m!=null&&!c.hasOwnProperty(_))switch(_){case"value":break;case"children":break;default:Dt(s,a,_,null,c,m)}for(x in c)if(m=c[x],p=l[x],c.hasOwnProperty(x)&&(m!=null||p!=null))switch(x){case"value":X=m;break;case"defaultValue":ee=m;break;case"children":break;case"dangerouslySetInnerHTML":if(m!=null)throw Error(n(91));break;default:m!==p&&Dt(s,a,x,m,c,p)}YB(s,X,ee);return;case"option":for(var Ne in l)if(X=l[Ne],l.hasOwnProperty(Ne)&&X!=null&&!c.hasOwnProperty(Ne))switch(Ne){case"selected":s.selected=!1;break;default:Dt(s,a,Ne,null,c,X)}for(j in c)if(X=c[j],ee=l[j],c.hasOwnProperty(j)&&X!==ee&&(X!=null||ee!=null))switch(j){case"selected":s.selected=X&&typeof X!="function"&&typeof X!="symbol";break;default:Dt(s,a,j,X,c,ee)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Ve in l)X=l[Ve],l.hasOwnProperty(Ve)&&X!=null&&!c.hasOwnProperty(Ve)&&Dt(s,a,Ve,null,c,X);for(Q in c)if(X=c[Q],ee=l[Q],c.hasOwnProperty(Q)&&X!==ee&&(X!=null||ee!=null))switch(Q){case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(n(137,a));break;default:Dt(s,a,Q,X,c,ee)}return;default:if(Xl(a)){for(var vt in l)X=l[vt],l.hasOwnProperty(vt)&&X!==void 0&&!c.hasOwnProperty(vt)&&_p(s,a,vt,void 0,c,X);for(re in c)X=c[re],ee=l[re],!c.hasOwnProperty(re)||X===ee||X===void 0&&ee===void 0||_p(s,a,re,X,c,ee);return}}for(var H in l)X=l[H],l.hasOwnProperty(H)&&X!=null&&!c.hasOwnProperty(H)&&Dt(s,a,H,null,c,X);for(oe in c)X=c[oe],ee=l[oe],!c.hasOwnProperty(oe)||X===ee||X==null&&ee==null||Dt(s,a,oe,X,c,ee)}function ix(s){switch(s){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function hT(){if(typeof performance.getEntriesByType=="function"){for(var s=0,a=0,l=performance.getEntriesByType("resource"),c=0;c<l.length;c++){var m=l[c],p=m.transferSize,x=m.initiatorType,_=m.duration;if(p&&_&&ix(x)){for(x=0,_=m.responseEnd,c+=1;c<l.length;c++){var j=l[c],Q=j.startTime;if(Q>_)break;var re=j.transferSize,oe=j.initiatorType;re&&ix(oe)&&(j=j.responseEnd,x+=re*(j<_?1:(_-Q)/(j-Q)))}if(--c,a+=8*(p+x)/(m.duration/1e3),s++,10<s)break}}if(0<s)return a/s/1e6}return navigator.connection&&(s=navigator.connection.downlink,typeof s=="number")?s:5}var Dp=null,vp=null;function Zh(s){return s.nodeType===9?s:s.ownerDocument}function lx(s){switch(s){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function ox(s,a){if(s===0)switch(a){case"svg":return 1;case"math":return 2;default:return 0}return s===1&&a==="foreignObject"?0:s}function wp(s,a){return s==="textarea"||s==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.children=="bigint"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var Tp=null;function dT(){var s=window.event;return s&&s.type==="popstate"?s===Tp?!1:(Tp=s,!0):(Tp=null,!1)}var ux=typeof setTimeout=="function"?setTimeout:void 0,fT=typeof clearTimeout=="function"?clearTimeout:void 0,cx=typeof Promise=="function"?Promise:void 0,mT=typeof queueMicrotask=="function"?queueMicrotask:typeof cx<"u"?function(s){return cx.resolve(null).then(s).catch(pT)}:ux;function pT(s){setTimeout(function(){throw s})}function Wa(s){return s==="head"}function Bx(s,a){var l=a,c=0;do{var m=l.nextSibling;if(s.removeChild(l),m&&m.nodeType===8)if(l=m.data,l==="/$"||l==="/&"){if(c===0){s.removeChild(m),Ro(a);return}c--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")c++;else if(l==="html")Tc(s.ownerDocument.documentElement);else if(l==="head"){l=s.ownerDocument.head,Tc(l);for(var p=l.firstChild;p;){var x=p.nextSibling,_=p.nodeName;p[dr]||_==="SCRIPT"||_==="STYLE"||_==="LINK"&&p.rel.toLowerCase()==="stylesheet"||l.removeChild(p),p=x}}else l==="body"&&Tc(s.ownerDocument.body);l=m}while(l);Ro(a)}function hx(s,a){var l=s;s=0;do{var c=l.nextSibling;if(l.nodeType===1?a?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(a?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),c&&c.nodeType===8)if(l=c.data,l==="/$"){if(s===0)break;s--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||s++;l=c}while(l)}function Ap(s){var a=s.firstChild;for(a&&a.nodeType===10&&(a=a.nextSibling);a;){var l=a;switch(a=a.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Ap(l),Jl(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}s.removeChild(l)}}function gT(s,a,l,c){for(;s.nodeType===1;){var m=l;if(s.nodeName.toLowerCase()!==a.toLowerCase()){if(!c&&(s.nodeName!=="INPUT"||s.type!=="hidden"))break}else if(c){if(!s[dr])switch(a){case"meta":if(!s.hasAttribute("itemprop"))break;return s;case"link":if(p=s.getAttribute("rel"),p==="stylesheet"&&s.hasAttribute("data-precedence"))break;if(p!==m.rel||s.getAttribute("href")!==(m.href==null||m.href===""?null:m.href)||s.getAttribute("crossorigin")!==(m.crossOrigin==null?null:m.crossOrigin)||s.getAttribute("title")!==(m.title==null?null:m.title))break;return s;case"style":if(s.hasAttribute("data-precedence"))break;return s;case"script":if(p=s.getAttribute("src"),(p!==(m.src==null?null:m.src)||s.getAttribute("type")!==(m.type==null?null:m.type)||s.getAttribute("crossorigin")!==(m.crossOrigin==null?null:m.crossOrigin))&&p&&s.hasAttribute("async")&&!s.hasAttribute("itemprop"))break;return s;default:return s}}else if(a==="input"&&s.type==="hidden"){var p=m.name==null?null:""+m.name;
vendor: 9,853 bytes, line 49
49if(m.type==="hidden"&&s.getAttribute("name")===p)return s}else return s;if(s=Fs(s.nextSibling),s===null)break}return null}function CT(s,a,l){if(a==="")return null;for(;s.nodeType!==3;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!l||(s=Fs(s.nextSibling),s===null))return null;return s}function dx(s,a){for(;s.nodeType!==8;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!a||(s=Fs(s.nextSibling),s===null))return null;return s}function Np(s){return s.data==="$?"||s.data==="$~"}function Ip(s){return s.data==="$!"||s.data==="$?"&&s.ownerDocument.readyState!=="loading"}function yT(s,a){var l=s.ownerDocument;if(s.data==="$~")s._reactRetry=a;else if(s.data!=="$?"||l.readyState!=="loading")a();else{var c=function(){a(),l.removeEventListener("DOMContentLoaded",c)};l.addEventListener("DOMContentLoaded",c),s._reactRetry=c}}function Fs(s){for(;s!=null;s=s.nextSibling){var a=s.nodeType;if(a===1||a===3)break;if(a===8){if(a=s.data,a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"||a==="F!"||a==="F")break;if(a==="/$"||a==="/&")return null}}return s}var Sp=null;function fx(s){s=s.nextSibling;for(var a=0;s;){if(s.nodeType===8){var l=s.data;if(l==="/$"||l==="/&"){if(a===0)return Fs(s.nextSibling);a--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||a++}s=s.nextSibling}return null}function mx(s){s=s.previousSibling;for(var a=0;s;){if(s.nodeType===8){var l=s.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(a===0)return s;a--}else l!=="/$"&&l!=="/&"||a++}s=s.previousSibling}return null}function px(s,a,l){switch(a=Zh(l),s){case"html":if(s=a.documentElement,!s)throw Error(n(452));return s;case"head":if(s=a.head,!s)throw Error(n(453));return s;case"body":if(s=a.body,!s)throw Error(n(454));return s;default:throw Error(n(451))}}function Tc(s){for(var a=s.attributes;a.length;)s.removeAttributeNode(a[0]);Jl(s)}var Gs=new Map,gx=new Set;function Wh(s){return typeof s.getRootNode=="function"?s.getRootNode():s.nodeType===9?s:s.ownerDocument}var ua=pe.d;pe.d={f:bT,r:xT,D:ET,C:_T,L:DT,m:vT,X:TT,S:wT,M:AT};function bT(){var s=ua.f(),a=zh();return s||a}function xT(s){var a=Is(s);a!==null&&a.tag===5&&a.type==="form"?ky(a):ua.r(s)}var No=typeof document>"u"?null:document;function Cx(s,a,l){var c=No;if(c&&typeof a=="string"&&a){var m=$n(a);m='link[rel="'+s+'"][href="'+m+'"]',typeof l=="string"&&(m+='[crossorigin="'+l+'"]'),gx.has(m)||(gx.add(m),s={rel:s,crossOrigin:l,href:a},c.querySelector(m)===null&&(a=c.createElement("link"),kn(a,"link",s),on(a),c.head.appendChild(a)))}}function ET(s){ua.D(s),Cx("dns-prefetch",s,null)}function _T(s,a){ua.C(s,a),Cx("preconnect",s,a)}function DT(s,a,l){ua.L(s,a,l);var c=No;if(c&&s&&a){var m='link[rel="preload"][as="'+$n(a)+'"]';a==="image"&&l&&l.imageSrcSet?(m+='[imagesrcset="'+$n(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(m+='[imagesizes="'+$n(l.imageSizes)+'"]')):m+='[href="'+$n(s)+'"]';var p=m;switch(a){case"style":p=Io(s);break;case"script":p=So(s)}Gs.has(p)||(s=b({rel:"preload",href:a==="image"&&l&&l.imageSrcSet?void 0:s,as:a},l),Gs.set(p,s),c.querySelector(m)!==null||a==="style"&&c.querySelector(Ac(p))||a==="script"&&c.querySelector(Nc(p))||(a=c.createElement("link"),kn(a,"link",s),on(a),c.head.appendChild(a)))}}function vT(s,a){ua.m(s,a);var l=No;if(l&&s){var c=a&&typeof a.as=="string"?a.as:"script",m='link[rel="modulepreload"][as="'+$n(c)+'"][href="'+$n(s)+'"]',p=m;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":p=So(s)}if(!Gs.has(p)&&(s=b({rel:"modulepreload",href:s},a),Gs.set(p,s),l.querySelector(m)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Nc(p)))return}c=l.createElement("link"),kn(c,"link",s),on(c),l.head.appendChild(c)}}}function wT(s,a,l){ua.S(s,a,l);var c=No;if(c&&s){var m=mr(c).hoistableStyles,p=Io(s);a=a||"default";var x=m.get(p);if(!x){var _={loading:0,preload:null};if(x=c.querySelector(Ac(p)))_.loading=5;else{s=b({rel:"stylesheet",href:s,"data-precedence":a},l),(l=Gs.get(p))&&Rp(s,l);var j=x=c.createElement("link");on(j),kn(j,"link",s),j._p=new Promise(function(Q,re){j.onload=Q,j.onerror=re}),j.addEventListener("load",function(){_.loading|=1}),j.addEventListener("error",function(){_.loading|=2}),_.loading|=4,ed(x,a,c)}x={type:"stylesheet",instance:x,count:1,state:_},m.set(p,x)}}}function TT(s,a){ua.X(s,a);var l=No;if(l&&s){var c=mr(l).hoistableScripts,m=So(s),p=c.get(m);p||(p=l.querySelector(Nc(m)),p||(s=b({src:s,async:!0},a),(a=Gs.get(m))&&Op(s,a),p=l.createElement("script"),on(p),kn(p,"link",s),l.head.appendChild(p)),p={type:"script",instance:p,count:1,state:null},c.set(m,p))}}function AT(s,a){ua.M(s,a);var l=No;if(l&&s){var c=mr(l).hoistableScripts,m=So(s),p=c.get(m);p||(p=l.querySelector(Nc(m)),p||(s=b({src:s,async:!0,type:"module"},a),(a=Gs.get(m))&&Op(s,a),p=l.createElement("script"),on(p),kn(p,"link",s),l.head.appendChild(p)),p={type:"script",instance:p,count:1,state:null},c.set(m,p))}}function yx(s,a,l,c){var m=(m=Ke.current)?Wh(m):null;if(!m)throw Error(n(446));switch(s){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(a=Io(l.href),l=mr(m).hoistableStyles,c=l.get(a),c||(c={type:"style",instance:null,count:0,state:null},l.set(a,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){s=Io(l.href);var p=mr(m).hoistableStyles,x=p.get(s);if(x||(m=m.ownerDocument||m,x={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},p.set(s,x),(p=m.querySelector(Ac(s)))&&!p._p&&(x.instance=p,x.state.loading=5),Gs.has(s)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Gs.set(s,l),p||NT(m,s,l,x.state))),a&&c===null)throw Error(n(528,""));return x}if(a&&c!==null)throw Error(n(529,""));return null;case"script":return a=l.async,l=l.src,typeof l=="string"&&a&&typeof a!="function"&&typeof a!="symbol"?(a=So(l),l=mr(m).hoistableScripts,c=l.get(a),c||(c={type:"script",instance:null,count:0,state:null},l.set(a,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(n(444,s))}}function Io(s){return'href="'+$n(s)+'"'}function Ac(s){return'link[rel="stylesheet"]['+s+"]"}function bx(s){return b({},s,{"data-precedence":s.precedence,precedence:null})}function NT(s,a,l,c){s.querySelector('link[rel="preload"][as="style"]['+a+"]")?c.loading=1:(a=s.createElement("link"),c.preload=a,a.addEventListener("load",function(){return c.loading|=1}),a.addEventListener("error",function(){return c.loading|=2}),kn(a,"link",l),on(a),s.head.appendChild(a))}function So(s){return'[src="'+$n(s)+'"]'}function Nc(s){return"script[async]"+s}function xx(s,a,l){if(a.count++,a.instance===null)switch(a.type){case"style":var c=s.querySelector('style[data-href~="'+$n(l.href)+'"]');if(c)return a.instance=c,on(c),c;var m=b({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return c=(s.ownerDocument||s).createElement("style"),on(c),kn(c,"style",m),ed(c,l.precedence,s),a.instance=c;case"stylesheet":m=Io(l.href);var p=s.querySelector(Ac(m));if(p)return a.state.loading|=4,a.instance=p,on(p),p;c=bx(l),(m=Gs.get(m))&&Rp(c,m),p=(s.ownerDocument||s).createElement("link"),on(p);var x=p;return x._p=new Promise(function(_,j){x.onload=_,x.onerror=j}),kn(p,"link",c),a.state.loading|=4,ed(p,l.precedence,s),a.instance=p;case"script":return p=So(l.src),(m=s.querySelector(Nc(p)))?(a.instance=m,on(m),m):(c=l,(m=Gs.get(p))&&(c=b({},l),Op(c,m)),s=s.ownerDocument||s,m=s.createElement("script"),on(m),kn(m,"link",c),s.head.appendChild(m),a.instance=m);case"void":return null;default:throw Error(n(443,a.type))}else a.type==="stylesheet"&&(a.state.loading&4)===0&&(c=a.instance,a.state.loading|=4,ed(c,l.precedence,s));return a.instance}function ed(s,a,l){for(var c=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),m=c.length?c[c.length-1]:null,p=m,x=0;x<c.length;x++){var _=c[x];if(_.dataset.precedence===a)p=_;else if(p!==m)break}p?p.parentNode.insertBefore(s,p.nextSibling):(a=l.nodeType===9?l.head:l,a.insertBefore(s,a.firstChild))}function Rp(s,a){s.crossOrigin==null&&(s.crossOrigin=a.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=a.referrerPolicy),s.title==null&&(s.title=a.title)}function Op(s,a){s.crossOrigin==null&&(s.crossOrigin=a.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=a.referrerPolicy),s.integrity==null&&(s.integrity=a.integrity)}var td=null;function Ex(s,a,l){if(td===null){var c=new Map,m=td=new Map;m.set(l,c)}else m=td,c=m.get(l),c||(c=new Map,m.set(l,c));if(c.has(s))return c;for(c.set(s,null),l=l.getElementsByTagName(s),m=0;m<l.length;m++){var p=l[m];if(!(p[dr]||p[ln]||s==="link"&&p.getAttribute("rel")==="stylesheet")&&p.namespaceURI!=="http://www.w3.org/2000/svg"){var x=p.getAttribute(a)||"";x=s+x;var _=c.get(x);_?_.push(p):c.set(x,[p])}}return c}function _x(s,a,l){s=s.ownerDocument||s,s.head.insertBefore(l,a==="title"?s.querySelector("head > title"):null)}function IT(s,a,l){if(l===1||a.itemProp!=null)return!1;switch(s){case"meta":case"title":return!0;case"style":if(typeof a.precedence!="string"||typeof a.href!="string"||a.href==="")break;return!0;case"link":if(typeof a.rel!="string"||typeof a.href!="string"||a.href===""||a.onLoad||a.onError)break;switch(a.rel){case"stylesheet":return s=a.disabled,typeof a.precedence=="string"&&s==null;default:return!0}case"script":if(a.async&&typeof a.async!="function"&&typeof a.async!="symbol"&&!a.onLoad&&!a.onError&&a.src&&typeof a.src=="string")return!0}return!1}function Dx(s){return!(s.type==="stylesheet"&&(s.state.loading&3)===0)}function ST(s,a,l,c){if(l.type==="stylesheet"&&(typeof c.media!="str
49ing"||matchMedia(c.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var m=Io(c.href),p=a.querySelector(Ac(m));if(p){a=p._p,a!==null&&typeof a=="object"&&typeof a.then=="function"&&(s.count++,s=nd.bind(s),a.then(s,s)),l.state.loading|=4,l.instance=p,on(p);return}p=a.ownerDocument||a,c=bx(c),(m=Gs.get(m))&&Rp(c,m),p=p.createElement("link"),on(p);var x=p;x._p=new Promise(function(_,j){x.onload=_,x.onerror=j}),kn(p,"link",c),l.instance=p}s.stylesheets===null&&(s.stylesheets=new Map),s.stylesheets.set(l,a),(a=l.state.preload)&&(l.state.loading&3)===0&&(s.count++,l=nd.bind(s),a.addEventListener("load",l),a.addEventListener("error",l))}}var kp=0;function RT(s,a){return s.stylesheets&&s.count===0&&rd(s,s.stylesheets),0<s.count||0<s.imgCount?function(l){var c=setTimeout(function(){if(s.stylesheets&&rd(s,s.stylesheets),s.unsuspend){var p=s.unsuspend;s.unsuspend=null,p()}},6e4+a);0<s.imgBytes&&kp===0&&(kp=62500*hT());var m=setTimeout(function(){if(s.waitingForImages=!1,s.count===0&&(s.stylesheets&&rd(s,s.stylesheets),s.unsuspend)){var p=s.unsuspend;s.unsuspend=null,p()}},(s.imgBytes>kp?50:800)+a);return s.unsuspend=l,function(){s.unsuspend=null,clearTimeout(c),clearTimeout(m)}}:null}function nd(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)rd(this,this.stylesheets);else if(this.unsuspend){var s=this.unsuspend;this.unsuspend=null,s()}}}var sd=null;function rd(s,a){s.stylesheets=null,s.unsuspend!==null&&(s.count++,sd=new Map,a.forEach(OT,s),sd=null,nd.call(s))}function OT(s,a){if(!(a.state.loading&4)){var l=sd.get(s);if(l)var c=l.get(null);else{l=new Map,sd.set(s,l);for(var m=s.querySelectorAll("link[data-precedence],style[data-precedence]"),p=0;p<m.length;p++){var x=m[p];(x.nodeName==="LINK"||x.getAttribute("media")!=="not all")&&(l.set(x.dataset.precedence,x),c=x)}c&&l.set(null,c)}m=a.instance,x=m.getAttribute("data-precedence"),p=l.get(x)||c,p===c&&l.set(null,m),l.set(x,m),this.count++,c=nd.bind(this),m.addEventListener("load",c),m.addEventListener("error",c),p?p.parentNode.insertBefore(m,p.nextSibling):(s=s.nodeType===9?s.head:s,s.insertBefore(m,s.firstChild)),a.state.loading|=4}}var Ic={$$typeof:de,Provider:null,Consumer:null,_currentValue:Re,_currentValue2:Re,_threadCount:0};function kT(s,a,l,c,m,p,x,_,j){this.tag=1,this.containerInfo=s,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Br(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Br(0),this.hiddenUpdates=Br(null),this.identifierPrefix=c,this.onUncaughtError=m,this.onCaughtError=p,this.onRecoverableError=x,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=j,this.incompleteTransitions=new Map}function vx(s,a,l,c,m,p,x,_,j,Q,re,oe){return s=new kT(s,a,l,x,j,Q,re,oe,_),a=1,p===!0&&(a|=24),p=fs(3,null,null,a),s.current=p,p.stateNode=s,a=dm(),a.refCount++,s.pooledCache=a,a.refCount++,p.memoizedState={element:c,isDehydrated:l,cache:a},gm(p),s}function wx(s){return s?(s=lo,s):lo}function Tx(s,a,l,c,m,p){m=wx(m),c.context===null?c.context=m:c.pendingContext=m,c=Ha(a),c.payload={element:l},p=p===void 0?null:p,p!==null&&(c.callback=p),l=Ua(s,c,a),l!==null&&(ss(l,s,a),oc(l,s,a))}function Ax(s,a){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var l=s.retryLane;s.retryLane=l!==0&&l<a?l:a}}function Lp(s,a){Ax(s,a),(s=s.alternate)&&Ax(s,a)}function Nx(s){if(s.tag===13||s.tag===31){var a=Ji(s,67108864);a!==null&&ss(a,s,67108864),Lp(s,67108864)}}function Ix(s){if(s.tag===13||s.tag===31){var a=ys();a=Li(a);var l=Ji(s,a);l!==null&&ss(l,s,a),Lp(s,a)}}var ad=!0;function LT(s,a,l,c){var m=$.T;$.T=null;var p=pe.p;try{pe.p=2,jp(s,a,l,c)}finally{pe.p=p,$.T=m}}function jT(s,a,l,c){var m=$.T;$.T=null;var p=pe.p;try{pe.p=8,jp(s,a,l,c)}finally{pe.p=p,$.T=m}}function jp(s,a,l,c){if(ad){var m=Mp(c);if(m===null)Ep(s,a,c,id,l),Rx(s,c);else if(PT(m,s,a,l,c))c.stopPropagation();else if(Rx(s,c),a&4&&-1<MT.indexOf(s)){for(;m!==null;){var p=Is(m);if(p!==null)switch(p.tag){case 3:if(p=p.stateNode,p.current.memoizedState.isDehydrated){var x=_n(p.pendingLanes);if(x!==0){var _=p;for(_.pendingLanes|=2,_.entangledLanes|=2;x;){var j=1<<31-Ht(x);_.entanglements[1]|=j,x&=~j}Ar(p),(pt&6)===0&&(Hh=En()+500,Dc(0))}}break;case 31:case 13:_=Ji(p,2),_!==null&&ss(_,p,2),zh(),Lp(p,2)}if(p=Mp(c),p===null&&Ep(s,a,c,id,l),p===m)break;m=p}m!==null&&c.stopPropagation()}else Ep(s,a,c,null,l)}}function Mp(s){return s=Ss(s),Pp(s)}var id=null;function Pp(s){if(id=null,s=fr(s),s!==null){var a=o(s);if(a===null)s=null;else{var l=a.tag;if(l===13){if(s=u(a),s!==null)return s;s=null}else if(l===31){if(s=B(a),s!==null)return s;s=null}else if(l===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;s=null}else a!==s&&(s=null)}}return id=s,null}function Sx(s){switch(s){case"beforetoggle":case"cancel":case"click":case"close"
vendor: 5,404 bytes, line 49
49: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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(cr()){case wa:return 2;case Y:return 8;case ze:case Ze:return 32;case At:return 268435456;default:return 32}default:return 32}}var Vp=!1,ei=null,ti=null,ni=null,Sc=new Map,Rc=new Map,si=[],MT="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".split(" ");function Rx(s,a){switch(s){case"focusin":case"focusout":ei=null;break;case"dragenter":case"dragleave":ti=null;break;case"mouseover":case"mouseout":ni=null;break;case"pointerover":case"pointerout":Sc.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":Rc.delete(a.pointerId)}}function Oc(s,a,l,c,m,p){return s===null||s.nativeEvent!==p?(s={blockedOn:a,domEventName:l,eventSystemFlags:c,nativeEvent:p,targetContainers:[m]},a!==null&&(a=Is(a),a!==null&&Nx(a)),s):(s.eventSystemFlags|=c,a=s.targetContainers,m!==null&&a.indexOf(m)===-1&&a.push(m),s)}function PT(s,a,l,c,m){switch(a){case"focusin":return ei=Oc(ei,s,a,l,c,m),!0;case"dragenter":return ti=Oc(ti,s,a,l,c,m),!0;case"mouseover":return ni=Oc(ni,s,a,l,c,m),!0;case"pointerover":var p=m.pointerId;return Sc.set(p,Oc(Sc.get(p)||null,s,a,l,c,m)),!0;case"gotpointercapture":return p=m.pointerId,Rc.set(p,Oc(Rc.get(p)||null,s,a,l,c,m)),!0}return!1}function Ox(s){var a=fr(s.target);if(a!==null){var l=o(a);if(l!==null){if(a=l.tag,a===13){if(a=u(l),a!==null){s.blockedOn=a,Xs(s.priority,function(){Ix(l)});return}}else if(a===31){if(a=B(l),a!==null){s.blockedOn=a,Xs(s.priority,function(){Ix(l)});return}}else if(a===3&&l.stateNode.current.memoizedState.isDehydrated){s.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}s.blockedOn=null}function ld(s){if(s.blockedOn!==null)return!1;for(var a=s.targetContainers;0<a.length;){var l=Mp(s.nativeEvent);if(l===null){l=s.nativeEvent;var c=new l.constructor(l.type,l);Ku=c,l.target.dispatchEvent(c),Ku=null}else return a=Is(l),a!==null&&Nx(a),s.blockedOn=l,!1;a.shift()}return!0}function kx(s,a,l){ld(s)&&l.delete(a)}function VT(){Vp=!1,ei!==null&&ld(ei)&&(ei=null),ti!==null&&ld(ti)&&(ti=null),ni!==null&&ld(ni)&&(ni=null),Sc.forEach(kx),Rc.forEach(kx)}function od(s,a){s.blockedOn===a&&(s.blockedOn=null,Vp||(Vp=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,VT)))}var ud=null;function Lx(s){ud!==s&&(ud=s,r.unstable_scheduleCallback(r.unstable_NormalPriority,function(){ud===s&&(ud=null);for(var a=0;a<s.length;a+=3){var l=s[a],c=s[a+1],m=s[a+2];if(typeof c!="function"){if(Pp(c||l)===null)continue;break}var p=Is(l);p!==null&&(s.splice(a,3),a-=3,Mm(p,{pending:!0,data:m,method:l.method,action:c},c,m))}}))}function Ro(s){function a(j){return od(j,s)}ei!==null&&od(ei,s),ti!==null&&od(ti,s),ni!==null&&od(ni,s),Sc.forEach(a),Rc.forEach(a);for(var l=0;l<si.length;l++){var c=si[l];c.blockedOn===s&&(c.blockedOn=null)}for(;0<si.length&&(l=si[0],l.blockedOn===null);)Ox(l),l.blockedOn===null&&si.shift();if(l=(s.ownerDocument||s).$$reactFormReplay,l!=null)for(c=0;c<l.length;c+=3){var m=l[c],p=l[c+1],x=m[Dn]||null;if(typeof p=="function")x||Lx(l);else if(x){var _=null;if(p&&p.hasAttribute("formAction")){if(m=p,x=p[Dn]||null)_=x.formAction;else if(Pp(m)!==null)continue}else _=x.action;typeof _=="function"?l[c+1]=_:(l.splice(c,3),c-=3),Lx(l)}}}function jx(){function s(p){p.canIntercept&&p.info==="react-transition"&&p.intercept({handler:function(){return new Promise(function(x){return m=x})},focusReset:"manual",scroll:"manual"})}function a(){m!==null&&(m(),m=null),c||setTimeout(l,20)}function l(){if(!c&&!navigation.transition){var p=navigation.currentEntry;p&&p.url!=null&&navigation.navigate(p.url,{state:p.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var c=!1,m=null;return navigation.addEventListener("navigate",s),navigation.addEventListener("navigatesuccess",a),navigation.addEventListener("navigateerror",a),setTimeout(l,100),function(){c=!0,navigation.removeEventListener("navigate",s),navigation.removeEventListener("navigatesuccess",a),navigation.removeEventListener("navigateerror",a),m!==null&&(m(),m=null)}}}function Fp(s){this._internalRoot=s}cd.prototype.render=Fp.prototype.render=function(s){var a=this._internalRoot;if(a===null)throw Error(n(409));var l=a.current,c=ys();
vendor: 4,802 bytes, lines 49-79
49Tx(l,c,s,a,null,null)},cd.prototype.unmount=Fp.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var a=s.containerInfo;Tx(s.current,2,null,s,null,null),zh(),a[hr]=null}};function cd(s){this._internalRoot=s}cd.prototype.unstable_scheduleHydration=function(s){if(s){var a=zB();s={blockedOn:null,target:s,priority:a};for(var l=0;l<si.length&&a!==0&&a<si[l].priority;l++);si.splice(l,0,s),l===0&&Ox(s)}};var Mx=e.version;if(Mx!=="19.2.8")throw Error(n(527,Mx,"19.2.8"));pe.findDOMNode=function(s){var a=s._reactInternals;if(a===void 0)throw typeof s.render=="function"?Error(n(188)):(s=Object.keys(s).join(","),Error(n(268,s)));return s=g(a),s=s!==null?y(s):null,s=s===null?null:s.stateNode,s};var FT={bundleType:0,version:"19.2.8",rendererPackageName:"react-dom",currentDispatcherRef:$,reconcilerVersion:"19.2.8"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Bd=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Bd.isDisabled&&Bd.supportsFiber)try{Ot=Bd.inject(FT),an=Bd}catch{}}return Lc.createRoot=function(s,a){if(!i(s))throw Error(n(299));var l=!1,c="",m=zy,p=qy,x=Ky;return a!=null&&(a.unstable_strictMode===!0&&(l=!0),a.identifierPrefix!==void 0&&(c=a.identifierPrefix),a.onUncaughtError!==void 0&&(m=a.onUncaughtError),a.onCaughtError!==void 0&&(p=a.onCaughtError),a.onRecoverableError!==void 0&&(x=a.onRecoverableError)),a=vx(s,1,!1,null,null,l,c,null,m,p,x,jx),s[hr]=a.current,xp(s),new Fp(a)},Lc.hydrateRoot=function(s,a,l){if(!i(s))throw Error(n(299));var c=!1,m="",p=zy,x=qy,_=Ky,j=null;return l!=null&&(l.unstable_strictMode===!0&&(c=!0),l.identifierPrefix!==void 0&&(m=l.identifierPrefix),l.onUncaughtError!==void 0&&(p=l.onUncaughtError),l.onCaughtError!==void 0&&(x=l.onCaughtError),l.onRecoverableError!==void 0&&(_=l.onRecoverableError),l.formState!==void 0&&(j=l.formState)),a=vx(s,1,!0,a,l??null,c,m,j,p,x,_,jx),a.context=wx(null),l=a.current,c=ys(),c=Li(c),m=Ha(c),m.callback=null,Ua(l,m,c),l=c,a.current.lanes=l,Oi(a,l),Ar(a),s[hr]=a.current,xp(s),new cd(a)},Lc.version="19.2.8",Lc}var Jx;function WT(){if(Jx)return Up.exports;Jx=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),Up.exports=ZT(),Up.exports}var eA=WT();/**
50 * @license lucide-react v0.546.0 - ISC
51 *
52 * This source code is licensed under the ISC license.
53 * See the LICENSE file in the root directory of this source tree.
54 */const tA=r=>r.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),nA=r=>r.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),Qx=r=>{const e=nA(r);return e.charAt(0).toUpperCase()+e.slice(1)},W_=(...r)=>r.filter((e,t,n)=>!!e&&e.trim()!==""&&n.indexOf(e)===t).join(" ").trim(),sA=r=>{for(const e in r)if(e.startsWith("aria-")||e==="role"||e==="title")return!0};/**
55 * @license lucide-react v0.546.0 - ISC
56 *
57 * This source code is licensed under the ISC license.
58 * See the LICENSE file in the root directory of this source tree.
59 */var rA={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
60 * @license lucide-react v0.546.0 - ISC
61 *
62 * This source code is licensed under the ISC license.
63 * See the LICENSE file in the root directory of this source tree.
64 */const aA=be.forwardRef(({color:r="currentColor",size:e=24,strokeWidth:t=2,absoluteStrokeWidth:n,className:i="",children:o,iconNode:u,...B},f)=>be.createElement("svg",{ref:f,...rA,width:e,height:e,stroke:r,strokeWidth:n?Number(t)*24/Number(e):t,className:W_("lucide",i),...!o&&!sA(B)&&{"aria-hidden":"true"},...B},[...u.map(([g,y])=>be.createElement(g,y)),...Array.isArray(o)?o:[o]]));/**
65 * @license lucide-react v0.546.0 - ISC
66 *
67 * This source code is licensed under the ISC license.
68 * See the LICENSE file in the root directory of this source tree.
69 */const He=(r,e)=>{const t=be.forwardRef(({className:n,...i},o)=>be.createElement(aA,{ref:o,iconNode:e,className:W_(`lucide-${tA(Qx(r))}`,`lucide-${r}`,n),...i}));return t.displayName=Qx(r),t};/**
70 * @license lucide-react v0.546.0 - ISC
71 *
72 * This source code is licensed under the ISC license.
73 * See the LICENSE file in the root directory of this source tree.
74 */const iA=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],e1=He("arrow-right",iA);/**
75 * @license lucide-react v0.546.0 - ISC
76 *
77 * This source code is licensed under the ISC license.
78 * See the LICENSE file in the root directory of this source tree.
79 */const lA=[["path",{d:"m21 16-4 4-4-4",key:"f6ql7i"}],["path",{d:"M17 20V4",key:"1ejh1v"}],["path",{d:"m3 8 4-4 4 4",key:"11wl7u"}],["path",{d:"M7 4v16",key:"1glfcx"}]],oA=He("arrow-up-down",lA);
79/**
80 * @license lucide-react v0.546.0 - ISC
81 *
82 * This source code is licensed under the ISC license.
83 * See the LICENSE file in the root directory of this source tree.
84 */const uA=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],t1=He("check",uA);/**
85 * @license lucide-react v0.546.0 - ISC
86 *
87 * This source code is licensed under the ISC license.
88 * See the LICENSE file in the root directory of this source tree.
89 */const cA=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],aC=He("chevron-down",cA);/**
90 * @license lucide-react v0.546.0 - ISC
91 *
92 * This source code is licensed under the ISC license.
93 * See the LICENSE file in the root directory of this source tree.
94 */const BA=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],mg=He("chevron-left",BA);/**
95 * @license lucide-react v0.546.0 - ISC
96 *
97 * This source code is licensed under the ISC license.
98 * See the LICENSE file in the root directory of this source tree.
99 */const hA=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],hi=He("chevron-right",hA);/**
100 * @license lucide-react v0.546.0 - ISC
101 *
102 * This source code is licensed under the ISC license.
103 * See the LICENSE file in the root directory of this source tree.
104 */const dA=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],n1=He("chevron-up",dA);/**
105 * @license lucide-react v0.546.0 - ISC
106 *
107 * This source code is licensed under the ISC license.
108 * See the LICENSE file in the root directory of this source tree.
109 */const fA=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],mA=He("circle-alert",fA);/**
110 * @license lucide-react v0.546.0 - ISC
111 *
112 * This source code is licensed under the ISC license.
113 * See the LICENSE file in the root directory of this source tree.
114 */const pA=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],Du=He("circle-check",pA);/**
115 * @license lucide-react v0.546.0 - ISC
116 *
117 * This source code is licensed under the ISC license.
118 * See the LICENSE file in the root directory of this source tree.
119 */const gA=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],Jp=He("circle-question-mark",gA);/**
120 * @license lucide-react v0.546.0 - ISC
121 *
122 * This source code is licensed under the ISC license.
123 * See the LICENSE file in the root directory of this source tree.
124 */const CA=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],s1=He("clock",CA);/**
125 * @license lucide-react v0.546.0 - ISC
126 *
127 * This source code is licensed under the ISC license.
128 * See the LICENSE file in the root directory of this source tree.
129 */const yA=[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]],r1=He("code-xml",yA);/**
130 * @license lucide-react v0.546.0 - ISC
131 *
132 * This source code is licensed under the ISC license.
133 * See the LICENSE file in the root directory of this source tree.
134 */const bA=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],a1=He("copy",bA);/**
135 * @license lucide-react v0.546.0 - ISC
136 *
137 * This source code is licensed under the ISC license.
138 * See the LICENSE file in the root directory of this source tree.
139 */const xA=[["rect",{width:"12",height:"12",x:"2",y:"10",rx:"2",ry:"2",key:"6agr2n"}],["path",{d:"m17.92 14 3.5-3.5a2.24 2.24 0 0 0 0-3l-5-4.92a2.24 2.24 0 0 0-3 0L10 6",key:"1o487t"}],["path",{d:"M6 18h.01",key:"uhywen"}],["path",{d:"M10 14h.01",key:"ssrbsk"}],["path",{d:"M15 6h.01",key:"cblpky"}],["path",{d:"M18 9h.01",key:"2061c0"}]],Yx=He("dices",xA);/**
140 * @license lucide-react v0.546.0 - ISC
141 *
142 * This source code is licensed under the ISC license.
143 * See the LICENSE file in the root directory of this source tree.
144 */const EA=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],il=He("external-link",EA);/**
145 * @license lucide-react v0.546.0 - ISC
146 *
147 * This source code is licensed under the ISC license.
148 * See the LICENSE file in the root directory of this source tree.
149 */const _A=[["path",{d:"M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",ke
149y:"1slcih"}]],DA=He("flame",_A);/**
150 * @license lucide-react v0.546.0 - ISC
151 *
152 * This source code is licensed under the ISC license.
153 * See the LICENSE file in the root directory of this source tree.
154 */const vA=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],wA=He("funnel",vA);/**
155 * @license lucide-react v0.546.0 - ISC
156 *
157 * This source code is licensed under the ISC license.
158 * See the LICENSE file in the root directory of this source tree.
159 */const TA=[["rect",{x:"3",y:"8",width:"18",height:"4",rx:"1",key:"bkv52"}],["path",{d:"M12 8v13",key:"1c76mn"}],["path",{d:"M19 12v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-7",key:"6wjy6b"}],["path",{d:"M7.5 8a2.5 2.5 0 0 1 0-5A4.8 8 0 0 1 12 8a4.8 8 0 0 1 4.5-5 2.5 2.5 0 0 1 0 5",key:"1ihvrl"}]],AA=He("gift",TA);/**
160 * @license lucide-react v0.546.0 - ISC
161 *
162 * This source code is licensed under the ISC license.
163 * See the LICENSE file in the root directory of this source tree.
164 */const NA=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],IA=He("globe",NA);/**
165 * @license lucide-react v0.546.0 - ISC
166 *
167 * This source code is licensed under the ISC license.
168 * See the LICENSE file in the root directory of this source tree.
169 */const SA=[["path",{d:"M3 14h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-7a9 9 0 0 1 18 0v7a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3",key:"1xhozi"}]],Qo=He("headphones",SA);/**
170 * @license lucide-react v0.546.0 - ISC
171 *
172 * This source code is licensed under the ISC license.
173 * See the LICENSE file in the root directory of this source tree.
174 */const RA=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]],OA=He("image",RA);/**
175 * @license lucide-react v0.546.0 - ISC
176 *
177 * This source code is licensed under the ISC license.
178 * See the LICENSE file in the root directory of this source tree.
179 */const kA=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],pg=He("key-round",kA);/**
180 * @license lucide-react v0.546.0 - ISC
181 *
182 * This source code is licensed under the ISC license.
183 * See the LICENSE file in the root directory of this source tree.
184 */const LA=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],Xx=He("layers",LA);/**
185 * @license lucide-react v0.546.0 - ISC
186 *
187 * This source code is licensed under the ISC license.
188 * See the LICENSE file in the root directory of this source tree.
189 */const jA=[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]],$x=He("link-2",jA);/**
190 * @license lucide-react v0.546.0 - ISC
191 *
192 * This source code is licensed under the ISC license.
193 * See the LICENSE file in the root directory of this source tree.
194 */const MA=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],PA=He("loader-circle",MA);/**
195 * @license lucide-react v0.546.0 - ISC
196 *
197 * This source code is licensed under the ISC license.
198 * See the LICENSE file in the root directory of this source tree.
199 */const VA=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],iC=He("lock",VA);/**
200 * @license lucide-react v0.546.0 - ISC
201 *
202 * This source code is licensed under the ISC license.
203 * See the LICENSE file in the root directory of this source tree.
204 */const FA=[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}
204],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]],GA=He("log-in",FA);/**
205 * @license lucide-react v0.546.0 - ISC
206 *
207 * This source code is licensed under the ISC license.
208 * See the LICENSE file in the root directory of this source tree.
209 */const HA=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],wd=He("message-circle",HA);/**
210 * @license lucide-react v0.546.0 - ISC
211 *
212 * This source code is licensed under the ISC license.
213 * See the LICENSE file in the root directory of this source tree.
214 */const UA=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],Yo=He("message-square",UA);/**
215 * @license lucide-react v0.546.0 - ISC
216 *
217 * This source code is licensed under the ISC license.
218 * See the LICENSE file in the root directory of this source tree.
219 */const zA=[["path",{d:"M13 21h8",key:"1jsn5i"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],qA=He("pen-line",zA);/**
220 * @license lucide-react v0.546.0 - ISC
221 *
222 * This source code is licensed under the ISC license.
223 * See the LICENSE file in the root directory of this source tree.
224 */const KA=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],Qp=He("plus",KA);/**
225 * @license lucide-react v0.546.0 - ISC
226 *
227 * This source code is licensed under the ISC license.
228 * See the LICENSE file in the root directory of this source tree.
229 */const JA=[["path",{d:"M16.247 7.761a6 6 0 0 1 0 8.478",key:"1fwjs5"}],["path",{d:"M19.075 4.933a10 10 0 0 1 0 14.134",key:"ehdyv1"}],["path",{d:"M4.925 19.067a10 10 0 0 1 0-14.134",key:"1q22gi"}],["path",{d:"M7.753 16.239a6 6 0 0 1 0-8.478",key:"r2q7qm"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]],i1=He("radio",JA);/**
230 * @license lucide-react v0.546.0 - ISC
231 *
232 * This source code is licensed under the ISC license.
233 * See the LICENSE file in the root directory of this source tree.
234 */const QA=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],YA=He("refresh-cw",QA);/**
235 * @license lucide-react v0.546.0 - ISC
236 *
237 * This source code is licensed under the ISC license.
238 * See the LICENSE file in the root directory of this source tree.
239 */const XA=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],$A=He("rotate-ccw",XA);/**
240 * @license lucide-react v0.546.0 - ISC
241 *
242 * This source code is licensed under the ISC license.
243 * See the LICENSE file in the root directory of this source tree.
244 */const ZA=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],jc=He("save",ZA);/**
245 * @license lucide-react v0.546.0 - ISC
246 *
247 * This source code is licensed under the ISC license.
248 * See the LICENSE file in the root directory of this source tree.
249 */const WA=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],e2=He("search",WA);/**
250 * @license lucide-react v0.546.0 - ISC
251 *
252 * This source code is licensed under the ISC license.
253 * See the LICENSE file in the root directory of this source tree.
254 */const t2=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],Td=He("send",t2);/**
255 * @license lucide-react v0.546.0 - ISC
256 *
257 * This source code is licensed under the ISC license.
258 * See the LICENSE file in the root directory of this source tree.
259 */const n2=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",ke
259y:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]],s2=He("shield-alert",n2);/**
260 * @license lucide-react v0.546.0 - ISC
261 *
262 * This source code is licensed under the ISC license.
263 * See the LICENSE file in the root directory of this source tree.
264 */const r2=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],Al=He("shield-check",r2);/**
265 * @license lucide-react v0.546.0 - ISC
266 *
267 * This source code is licensed under the ISC license.
268 * See the LICENSE file in the root directory of this source tree.
269 */const a2=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}
vendor: 5,952 bytes, lines 269-314
269],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],Sr=He("sparkles",a2);/**
270 * @license lucide-react v0.546.0 - ISC
271 *
272 * This source code is licensed under the ISC license.
273 * See the LICENSE file in the root directory of this source tree.
274 */const i2=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],l2=He("star",i2);/**
275 * @license lucide-react v0.546.0 - ISC
276 *
277 * This source code is licensed under the ISC license.
278 * See the LICENSE file in the root directory of this source tree.
279 */const o2=[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]],u2=He("tag",o2);/**
280 * @license lucide-react v0.546.0 - ISC
281 *
282 * This source code is licensed under the ISC license.
283 * See the LICENSE file in the root directory of this source tree.
284 */const c2=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]],B2=He("target",c2);/**
285 * @license lucide-react v0.546.0 - ISC
286 *
287 * This source code is licensed under the ISC license.
288 * See the LICENSE file in the root directory of this source tree.
289 */const h2=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],Yp=He("trash-2",h2);/**
290 * @license lucide-react v0.546.0 - ISC
291 *
292 * This source code is licensed under the ISC license.
293 * See the LICENSE file in the root directory of this source tree.
294 */const d2=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],f2=He("trending-up",d2);/**
295 * @license lucide-react v0.546.0 - ISC
296 *
297 * This source code is licensed under the ISC license.
298 * See the LICENSE file in the root directory of this source tree.
299 */const m2=[["path",{d:"M10 14.66v1.626a2 2 0 0 1-.976 1.696A5 5 0 0 0 7 21.978",key:"1n3hpd"}],["path",{d:"M14 14.66v1.626a2 2 0 0 0 .976 1.696A5 5 0 0 1 17 21.978",key:"rfe1zi"}],["path",{d:"M18 9h1.5a1 1 0 0 0 0-5H18",key:"7xy6bh"}],["path",{d:"M4 22h16",key:"57wxv0"}],["path",{d:"M6 9a6 6 0 0 0 12 0V3a1 1 0 0 0-1-1H7a1 1 0 0 0-1 1z",key:"1mhfuq"}],["path",{d:"M6 9H4.5a1 1 0 0 1 0-5H6",key:"tex48p"}]],p2=He("trophy",m2);/**
300 * @license lucide-react v0.546.0 - ISC
301 *
302 * This source code is licensed under the ISC license.
303 * See the LICENSE file in the root directory of this source tree.
304 */const g2=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],NB=He("x",g2);/**
305 * @license lucide-react v0.546.0 - ISC
306 *
307 * This source code is licensed under the ISC license.
308 * See the LICENSE file in the root directory of this source tree.
309 */const C2=[["path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17",key:"1q2vi4"}],["path",{d:"m10 15 5-3-5-3z",key:"1jp15x"}]],Ad=He("youtube",C2);/**
310 * @license lucide-react v0.546.0 - ISC
311 *
312 * This source code is licensed under the ISC license.
313 * See the LICENSE file in the root directory of this source tree.
314 */const y2=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],bl=He("zap",y2),b2=Ks.memo(({config:r,isOwner:e,onOpenOwnerAuth:t,onOpenAdmin:n,onLogoutOwner:i,onOpenEmbed:o,onOpenPrivacy:u})=>{const B=r.brandName||"KANCAH4D";return h.jsxs("header",{className:"w-full max-w-xl mx-auto flex flex-col items-center justify-center pt-2 pb-2 relative text-center",children:[e&&h.jsxs("div",{className:"w-full flex items-center justify-between px-3 py-1.5 mb-3 bg-gradient-to-r from-amber-500/20 via-yellow-500/10 to-amber-500/20 border border-yellow-500/40 rounded-xl text-[11px] text-yellow-300 backdrop-blur-md animate-fadeIn",children:[h.jsxs("div",{className:"flex items-center gap-1.5 font-bold",children:[h.jsx("span",{className:"w-2 h-2 rounded-full bg-emerald-400 animate-ping"}),h.jsx("span",{children:"Halo Pemilik Kancah4D!"})]}),h.jsxs("div",{className:"flex items-center gap-2",children:[o&&h.jsxs("button",{onClick:o,className:"flex items-center gap-1 text-[10px] bg-slate-800 hover:bg-slate-700 text-cyan-300 font-bold px-2 py-0.5 rounded border border-cyan-500/40 transition cursor-pointer",title:"Ekspor Widget / Embed HTML",children:[h.jsx(r1,{className:"w-3 h-3"}),h.jsx("span",{children:"Kode Embed"})]}),n&&h.jsxs("button",{onClick:n,className:"flex items-center gap-1 text-[10px] bg-gradient-to-r from-yellow-500 to-amber-500 hover:from-yellow-400 hover:to-amber-400 text-slate-950 font-black px-2.5 py-0.5 rounded transition cursor-pointer",title:"Buka Pengaturan",children:[h.jsx(Sr,{className:"w-3 h-3"}),h.jsx("span",{children:"Panel Admin"})]}),i&&h.jsx("button",{onClick:i,className:"text-[10px] text-slate-400 hover:text-red-400 px-1 transition cursor-pointer",title:"Keluar dari sesi pemilik",children:"Kunci"})]})]}),h.jsxs("div",{className:"w-full flex items-center justify-between gap-2 px-1 mb-3.5",children:[h.jsxs("div",{className:"flex items-center gap-1.5 py-1.5 px-3 rounded-full bg-[#051024]/90 backdrop-blur-md border border-cyan-400/50 shadow-[0_2px_10px_rgba(6,182,212,0.25)] text-[9.5px] sm:text-[11px] font-extrabold text-cyan-300 tracking-wider up
314percase whitespace-nowrap select-none",children:[h.jsxs("span",{className:"relative flex h-2 w-2 flex-shrink-0",children:[h.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-emerald-400 opacity-75"}),h.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-emerald-400"})]}),h.jsx("span",{className:"hidden sm:inline",children:"OFFICIAL VERIFIED SERVER 2026"}),h.jsx("span",{className:"inline sm:hidden",children:"VERIFIED SERVER 2026"})]}),h.jsxs("button",{type:"button",onClick:u,className:"flex items-center gap-1.5 py-1.5 px-3 rounded-full bg-[#051024]/90 hover:bg-cyan-950/80 backdrop-blur-md border border-cyan-400/50 hover:border-cyan-300 shadow-[0_2px_10px_rgba(6,182,212,0.25)] text-[9.5px] sm:text-[11px] font-bold text-cyan-200 hover:text-white tracking-wider transition-all cursor-pointer whitespace-nowrap active:scale-95",children:[h.jsx(Al,{className:"w-3.5 h-3.5 text-cyan-400 flex-shrink-0"}),h.jsx("span",{children:"Kebijakan & Privasi"})]})]}),h.jsxs("div",{className:"relative group mb-3 cursor-pointer flex items-center justify-center select-none",onClick:t,title:e?"Buka Panel Admin":"Klik untuk Akses Pemilik Kancah4D",children:[h.jsx("div",{className:"absolute -inset-2 bg-gradient-to-r from-cyan-500/30 via-blue-600/40 to-cyan-500/30 rounded-2xl sm:rounded-full blur-xl opacity-75 group-hover:opacity-100 transition-opacity duration-300 pointer-events-none"}),h.jsxs("div",{className:"relative py-2 px-6 sm:px-9 bg-gradient-to-b from-[#091a38] via-[#061226] to-[#040c1c] border border-cyan-400/70 rounded-2xl sm:rounded-full shadow-[0_4px_20px_rgba(6,182,212,0.45),inset_0_1px_1px_rgba(255,255,255,0.25)] flex items-center justify-center transition-all duration-300 group-hover:scale-105 group-hover:border-cyan-300 min-h-[50px]",children:[r.logoUrl?h.jsx("img",{src:r.logoUrl,alt:B,className:"h-8 sm:h-10 md:h-11 w-auto max-w-[240px] sm:max-w-[300px] object-contain drop-shadow-[0_2px_8px_rgba(0,0,0,0.8)]",onError:f=>{var b;const g=f.target;g.style.display="none";const y=(b=g.parentElement)==null?void 0:b.querySelector(".brand-logo-fallback");y&&(y.style.display="block")}}):h.jsx("span",{className:"text-base sm:text-xl font-black tracking-wider text-white drop-shadow-[0_0_8px_rgba(255,255,255,0.7)]",children:B}),h.jsx("span",{className:"brand-logo-fallback hidden text-base sm:text-xl font-black tracking-wider text-white",children:B})]})]}),h.jsxs("div",{className:"flex flex-col items-center justify-center gap-0.5 px-2 text-center w-full",children:[h.jsxs("h1",{className:"text-base sm:text-xl md:text-2xl font-black tracking-wide text-white uppercase drop-shadow-[0_2px_10px_rgba(0,0,0,0.9)] leading-tight",children:["KALKULATOR ",B]}),h.jsx("div",{className:"text-xs sm:text-sm font-extrabold tracking-widest text-cyan-300 uppercase drop-shadow-[0_0_8px_rgba(6,182,212,0.8)]",children:"FITUR KALKULASI VIRAL"})]}),h.jsx("p",{className:"text-[11px] sm:text-xs text-slate-300/90 max-w-sm sm:max-w-md mx-auto mt-1.5 px-3 leading-relaxed font-medium",style:{textWrap:"balance"},children:r.headerSubtitle||`Akses fitur ${B} kalkulasi akurat membantu Anda mencapai target kemenangan jackpot & pola gacor.`}),h.jsx("div",{className:"w-16 sm:w-24 h-[1.5px] bg-gradient-to-r from-transparent via-cyan-400/60 to-transparent mt-2 mb-1 mx-auto"})]})}),x2=Ks.memo(({banners:r})=>{const[e,t]=be.useState(0),[n,i]=be.useState(!1),o=be.useRef(null);be.useEffect(()=>{if(!(r.length<=1||n))return o.current=setInterval(()=>{t(f=>(f+1)%r.length)},3e3),()=>{o.current&&clearInterval(o.current)}},[r.length,n]);const u=f=>{f.stopPropagation(),t(g=>(g-1+r.length)%r.length)},B=f=>{f.stopPropagation(),t(g=>(g+1)%r.length)};return!r||r.length===0?null:h.jsx("div",{className:"w-full my-1.5 px-0",children:h.jsxs("div",{className:"group relative w-full overflow-hidden rounded-xl bg-black border-2 border-cyan-400/80 box-border leading-none shadow-[0_0_20px_rgba(6,182,212,0.35)]",onMouseEnter:()=>i(!0),onMouseLeave:()=>i(!1),id:"kancah-banner-container",children:[h.jsx("div",{id:"kancah-pure-track",className:"flex w-full transition-transform duration-500 ease-in-out",style:{transform:`translate3d(-${e*100}%, 0, 0)`,willChange:"transform"},children:r.map((f,g)=>h.jsx("div",{className:"min-w-full w-full select-none",children:h.jsx("a",{href:f.link||"#",target:f.link?"_blank":void 0,rel:"noopener noreferrer",className:"block w-full cursor-pointer",children:h.jsx("img",{src:f.imageUrl,alt:f.alt||f.title,className:"w-full h-auto block object-contain",loading:g===0?"eager":"lazy",decoding:"async"})})},f.id||g))}),h.jsx("div",{className:"absolute top-0 w-1/2 h-full pointer-events-none z-10 skew-x-[-25deg] animate-shine",style:{background:"linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%)"}}),r.length>1&&h.jsxs(h.Fragment,{children:[h.jsx("button",{onClick:u,"aria-label":"Slide Sebelumnya",className:"absolute left-2 top-1/2 -translate-y-1/2 w-8 h-8 rounded-full bg-black/60 text-white flex items-center justify-center opacity-0 group-hover:opacity-90 hover:bg-black/90 transition-opacity z-20 cursor-pointer border border-white/40",children:h.jsx(mg,{className:"w-5 h-5 -ml-0.5"})}),h.jsx("button",{onClick:B,"aria-label":"Slide Selanjutnya",className:"absolute right-2 top-1/2 -translate-y-1/2 w-8 h-8 rounded-full bg-black/60 text-white flex items-center justify-center opacity-0 group-hover:opacity-90 hover:bg-black/90 transition-opacity z-20 cursor-pointer border border-white/40",children:h.jsx(hi,{className:"w-5 h-5 -mr-0.5"})}),h.jsx("div",{className:"absolute bottom-2 left-1/2 -translate-x-1/2 flex items-center gap-1.5 z-20",children:r.map((f,g)=>h.jsx("button",{onClick:()=>t(g),"aria-label":`Ke slide ${g+1}`,className:`h-1.5 rounded-full transition-all duration-300 ${e===g?"w-5 bg-yellow-400 shadow-[0_0_8px_#facc15]":"w-1.5 bg-white/50 hover:bg-white/80"}`},g))})]})]})})}),Xp=8,Zx=8,Wx=r=>{if(!r)return 0;const e=parseInt(r.replace(/[^0-9]/g,""),10);return isNaN(e)?0:e},E2=r=>{switch(r){case"red":return"bg-gradient-to-r from-red-600 via-rose-500 to-red-600 text-white shadow-[0_0_10px_rgba(239,68,68,0.85)] border border-rose-300/40";case"green":return"bg-gradient-to-r from-emerald-400 to-green-500 text-slate-950 shadow-[0_0_10px_rgba(52,211,153,0.85)] border border-emerald-200/50";case"blue":return"bg-gradient-to-r from-cyan-400 to-blue-500 text-white shadow-[0_0_10px_rgba(6,182,212,0.85)] border border-cyan-200/50";case"purple":return"bg-gradient-to-r from-purple-500 to-fuchsia-500 text-white shadow-[0_0_10px_rgba(168,85,247,0.85)] border border-fuchsia-300/40";case"yellow":default:return"bg-gradient-to-r from-amber-400 via-yellow-400 to-amber-500 text-slate-950 shadow-[0_0_10px_rgba(250,204,21,0.9)] border border-yellow-100/60"}},l1=Ks.memo(({item:r,index:e,onSelectProof:t})=>{const n=r.badgeText!==void 0?r.badgeText:r.isHighlighted?"HOT":"",i=r.buttonLabel?r.buttonLabel.replace(/^🎁\s*/,""):`BUKTI JACKPOT #${e+1}`;return h.jsx("div",{className:"w-full relative will-change-transform",children:h.jsxs("button",{type:"button",onClick:()=>t(r),id:`btn-proof-${r.id||e}`,className:"group relative w-full py-3.5 px-3 sm:px-4 bg-gradient-to-r from-[#1542a8] via-[#1f5ce0] to-[#1542a8] hover:from-[#1b4fc7] hover:via-[#2b6df5] hover:to-[#1b4fc7] text-white font-black text-xs sm:text-[13px] border-2 border-cyan-400 rounded-xl cursor-pointer shadow-[0_0_18px_rgba(6,182,212,0.4)] uppercase tracking-wide overflow-hidden transition-all duration-200 transform hover:scale-[1.01] active:scale-[0.98] text-center flex items-center justify-center",children:[h.jsx("span",{className:"absolute top-0 w-1/2 h-full pointer-events-none z-10 skew-x-[-25deg] animate-btn-shine",style:{background:"linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.45) 50%, rgba(255,255,255,0) 100%)"}}),h.jsxs("span",{className:"relative z-20 flex items-center justify-center gap-1.5 sm:gap-2.5 drop-shadow-[0_1px_3px_rgba(0,0,0,0.8)] w-full max-w-full px-1",children:[h.jsx("span",{className:"text-sm sm:text-base animate-bounce flex-shrink-0",children:"🎁"}),h.jsx("span",{className:"truncate max-w-[180px] xs:max-w-[240px] sm:max-w-[320px] md:max-w-[380px]",children:i}),n&&n.trim()!==""&&h.jsx("span",{className:`px-2 py-0.5 text-[8.5px] sm:text-[10px] font-black rounded-md tracking-wider up
314percase ${E2(r.badgeColor)} flex-shrink-0 animate-pulse`,children:n.trim()})]})]})})});l1.displayName="ProofButtonItem";const _2=Ks.memo(({proofs:r,onSelectProof:e})=>{const[t,n]=be.useState("ALL"),[i,o]=be.useState("default"),[u,B]=be.useState(Xp),[f,g]=be.useState(!1),y=be.useRef(null),b=be.useMemo(()=>{if(!r||r.length===0)return[];const ce=new Map;return r.forEach(_e=>{var S;const ye=(S=_e.gameProvider)==null?void 0:S.trim();ye&&ce.set(ye,(ce.get(ye)||0)+1)}),Array.from(ce.entries()).map(([_e,ye])=>({name:_e,count:ye}))},[r]),D=be.useMemo(()=>{if(!r||r.length===0)return[];let ce=r;return t!=="ALL"&&(ce=ce.filter(_e=>{var ye;return((ye=_e.gameProvider)==null?void 0:ye.trim().toLowerCase())===t.toLowerCase()})),i==="highest"&&(ce=[...ce].sort((_e,ye)=>Wx(ye.winAmount)-Wx(_e.winAmount))),ce},[r,t,i]),T=D.length;be.useEffect(()=>{B(Xp)},[t,i]),be.useEffect(()=>{const ce=y.current;if(!ce)return;const _e=new IntersectionObserver(ye=>{ye[0].isIntersecting&&u<T&&(g(!0),requestAnimationFrame(()=>{B(A=>Math.min(A+Zx,T)),g(!1)}))},{root:null,rootMargin:"180px",threshold:.1});return _e.observe(ce),()=>{_e.disconnect()}},[u,T]);const M=be.useMemo(()=>D.slice(0,u),[D,u]),z=be.useCallback(ce=>{n(ce)},[]),W=be.useCallback(()=>{o(ce=>ce==="default"?"highest":"default")},[]),K=be.useCallback(()=>{B(T)},[T]),he=be.useCallback(()=>{B(ce=>Math.min(ce+Zx,T))},[T]);if(!r||r.length===0)return h.jsx("div",{className:"w-full py-4 text-center text-xs text-slate-400 italic",children:"Belum ada bukti jackpot yang ditampilkan saat ini."});const de=u<T;return h.jsxs("div",{className:"w-full my-1 flex flex-col gap-2",id:"kancah-proof-list",children:[h.jsxs("div",{className:"w-full flex flex-col gap-1.5 pb-1",children:[h.jsxs("div",{className:"flex items-center justify-between text-[11px] px-1",children:[h.jsxs("div",{className:"flex items-center gap-1.5 text-cyan-400/90 font-bold uppercase tracking-wider text-[10.5px] sm:text-xs",children:[h.jsx(wA,{className:"w-3.5 h-3.5 text-cyan-400 flex-shrink-0"}),h.jsxs("span",{children:["Kategori Provider (",T,")"]})]}),h.jsxs("button",{type:"button",onClick:W,id:"btn-toggle-sort-proofs",className:"flex items-center gap-1.5 px-2.5 py-1 rounded-md bg-[#091a38] hover:bg-[#0f2957] text-cyan-300 border border-cyan-500/40 text-[10px] sm:text-[10.5px] font-semibold transition-colors cursor-pointer select-none active:scale-95 shadow-sm",title:"Klik untuk mengubah urutan bukti jackpot",children:[h.jsx(oA,{className:"w-3 h-3 text-cyan-400 flex-shrink-0"}),h.jsx("span",{children:i==="highest"?"🔥 Terbesar":"⚡ Terbaru"})]})]}),h.jsxs("div",{className:"flex items-center gap-1.5 overflow-x-auto py-1 px-0.5 no-scrollbar touch-pan-x",children:[h.jsxs("button",{type:"button",id:"filter-provider-all",onClick:()=>z("ALL"),className:`flex-shrink-0 px-2.5 py-1 rounded-lg text-[10.5px] font-bold tracking-wide uppercase transition-all duration-150 cursor-pointer select-none flex items-center gap-1 ${t==="ALL"?"bg-gradient-to-r from-cyan-400 to-blue-500 text-slate-950 shadow-[0_0_10px_rgba(6,182,212,0.6)] border border-cyan-300 scale-100":"bg-[#061224] text-slate-300 border border-cyan-500/25 hover:border-cyan-400 hover:text-white"}`,children:[h.jsx(Sr,{className:`w-3 h-3 ${t==="ALL"?"text-slate-950":"text-cyan-400"}`}),h.jsx("span",{children:"Semua"}),h.jsx("span",{className:`text-[9px] px-1 py-0.2 rounded-full ${t==="ALL"?"bg-slate-950/20 text-slate-950":"bg-cyan-950 text-cyan-300"}`,children:r.length})]}),b.map(ce=>{const _e=t.toLowerCase()===ce.name.toLowerCase();return h.jsxs("button",{id:`filter-provider-${ce.name.toLowerCase().replace(/\s+/g,"-")}`,type:"button",onClick:()=>z(ce.name),className:`flex-shrink-0 px-2.5 py-1 rounded-lg text-[10.5px] font-bold tracking-wide uppercase transition-all duration-150 cursor-pointer select-none flex items-center gap-1 ${_e?"bg-gradient-to-r from-cyan-400 to-blue-500 text-slate-950 shadow-[0_0_10px_rgba(6,182,212,0.6)] border border-cyan-300":"bg-[#061224] text-slate-300 border border-cyan-500/25 hover:border-cyan-400 hover:text-white"}`,children:[_e&&h.jsx(DA,{className:"w-3 h-3 text-slate-950 animate-pulse"}),h.jsx("span",{children:ce.name}),h.jsx("span",{className:`text-[9px] px-1 py-0.2 rounded-full ${_e?"bg-slate-950/20 text-slate-950":"bg-cyan-950 text-cyan-300"}`,children:ce.count})]},`prov-${ce.name}`)})]})]}),T===0?h.jsxs("div",{className:"w-full py-5 px-3 rounded-xl bg-[#061224]/80 border border-cyan-500/30 text-center flex flex-col items-center gap-2",children:[h.jsxs("p",{className:"text-xs text-slate-300",children:["Tidak ada bukti jackpot ditemukan untuk kategori ",h.jsx("span",{className:"text-cyan-300 font-bold",children:t}),"."]}),h.jsx("button",{type:"button",onClick:()=>z("ALL"),className:"px-3 py-1 bg-cyan-500 text-slate-950 font-bold text-xs rounded-lg hover:bg-cyan-400 transition-colors cursor-pointer",children:"Tampilkan Semua Bukti"})]}):h.jsxs("div",{className:"w-full flex flex-col gap-2.5",children:[M.map((ce,_e)=>h.jsx(l1,{item:ce,index:_e,onSelectProof:e},ce.id||_e)),h.jsx("div",{ref:y,className:"h-1 w-full pointer-events-none opacity-0","aria-hidden":"true"}),de?h.jsxs("div",{className:"w-full pt-1 flex flex-col items-center gap-2",children:[h.jsx("button",{type:"button",id:"btn-load-more-proofs",onClick:he,className:"w-full py-2.5 px-4 bg-[#091a38] hover:bg-[#0f2957] border border-cyan-400/50 hover:border-cyan-300 rounded-xl text-cyan-300 hover:text-white text-xs font-bold transition-all shadow-md active:scale-95 flex items-center justify-center gap-2 cursor-pointer",children:f?h.jsxs(h.Fragment,{children:[h.jsx(PA,{className:"w-3.5 h-3.5 animate-spin text-cyan-400"}),h.jsx("span",{children:"Memuat Bukti Berikutnya..."})]}):h.jsxs(h.Fragment,{children:[h.jsx(aC,{className:"w-4 h-4 text-cyan-400 animate-bounce"}),h.jsxs("span",{children:["Muat Lebih Banyak (",T-u," Bukti Lagi)"]})]})}),h.jsxs("div",{className:"flex items-center justify-between w-full px-1 text-[10.5px] text-slate-400",children:[h.jsxs("span",{children:["Menampilkan ",h.jsx("b",{className:"text-cyan-300",children:M.length})," dari ",h.jsx("b",{className:"text-white",children:T})," bukti"]}),h.jsxs("button",{type:"button",onClick:K,className:"text-cyan-400 hover:text-cyan-300 underline font-semibold cursor-pointer",children:["Tampilkan Semua (",T,")"]})]})]}):T>Xp&&h.jsxs("div",{className:"w-full py-2 text-center text-[10.5px] text-slate-400 flex items-center justify-center gap-1.5 border-t border-cyan-500/20 mt-1",children:[h.jsx(Du,{className:"w-3.5 h-3.5 text-emerald-400"}),h.jsxs("span",{children:["Seluruh ",T," bukti jackpot telah ditampilkan"]})]})]})]})}),Wo={brandName:"KANCAH4D",headerSubtitle:"KANCAH4D | TESTIMONI KEMENANGAN 2026",logoUrl:"https://ik.imagekit.io/CBadak/logo.gif",faviconUrl:"https://ik.imagekit.io/dxokd3m9y/favicon.png",mainCtaText:"🚀 KUNJUNGI WEBSITE UTAMA KANCAH4D",mainCtaUrl:"https://akseslink.com/kancah4d",mainCtaSubtext:"Situs Resmi Slot Gacor & Bukti Maxwin Terpercaya 2026",showMainCtaButton:!0,showStickyCtaBar:!0,registerUrl:"https://akseslink.com/kancah4d",registerButtonText:"DAFTAR AKUN VVIP",loginUrl:"https://akseslink.com/kancah4d",loginButtonText:"LOGIN MEMBER",liveChatUrl:"https://direct.lc.chat/kancah4d",liveChatButtonText:"LIVECHAT 24/7",modalCopyButtonText:"Salin Pola",modalPlayButtonText:"Mainkan Pola",modalPlayButtonUrl:"https://akseslink.com/kancah4d",modalClaimButtonText:"🚀 LOGIN & KLAIM JACKPOT SEKARANG",modalClaimButtonUrl:"https://akseslink.com/kancah4d",welcomePopup:{enabled:!0,imageUrl:"https://ik.imagekit.io/CBadak/ChatGPT%20Image%20Aug%2026,%202026,%2006_03_10%20PM.png",targetUrl:"https://akseslink.com/kancah4d",buttonText:"🔥 DAFTAR & KLAIM BONUS SEKARANG",subtext:"Daftar sekarang di Kancah4D & raih kemenangan jackpot maxwin!"},footerText:"OFFICIAL KANCAH4D • LISENSI RESMI",copyrightText:"© 2026 KANCAH4D",socialLinks:{telegram:"https://t.me/kancah4dofficial",whatsapp:"https://wa.me/6281234567890",twitter:"https://x.com/kancah4d",youtube:"https://youtube.com/@kancah4d",pinterest:"https://pinterest.com/kancah4d"}},eu=[{id:"banner-1",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner1.webp",title:"Navigasi Cepat Menang Bersama Kancah4D",alt:"Kancah4D Promo Utama",link:"https://kancah4d.com"},{id:"banner-5",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner5.webp",title:"Bonus New Member 200rb & Sensational Jackpot",alt:"Bonus New Member Kancah4D",link:"https://kancah4d.com/promo"},{id:"banner-3",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner3.webp",title:"Petir Zeus x500 Gates of Olympu
314s",alt:"Gates of Olympus Jackpot",link:"https://kancah4d.com/slots"},{id:"banner-4",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner4.webp",title:"Starlight Princess Sensational Maxwin",alt:"Starlight Princess Promo",link:"https://kancah4d.com/slots"},{id:"banner-2",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner2.webp",title:"Proses Depo WD Tercepat Layanan VIP 24 Jam",alt:"Layanan VIP Kancah4D",link:"https://kancah4d.com/vip"}],tu=[{id:"jp-1",buttonLabel:"🎁 KANCAH4D | BUKTI MAXWIN 19 AUG 2026",title:"🔥 KANCAH4D | BUKTI MAXWIN 19 AUG 2026",date:"19 AUG 2026",gameProvider:"PG Soft",gameName:"Mahjong Ways 2",imageUrl:"https://ik.imagekit.io/dxokd3m9y/tolkon.png",username:"r***88",winAmount:"Rp 64.850.000",betAmount:"Rp 12.000",multiplier:"x5404",badgeText:"HOT",badgeColor:"yellow",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"25x (Turbo Off)",spinAutoTurboOn:"70x (Turbo On)",spinAutoTurboOff:"40x (Turbo Off)",spinChance:"DC Aktif / Bet Bertingkat",jamHoki:"13:20 - 15:40 WIB & 20:15 - 22:45 WIB",rtpLive:"98.9%"},tips:"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal perkalian naga emas.",isHighlighted:!0,createdAt:"2026-08-19T00:15:00Z"},{id:"jp-2",buttonLabel:"🎁 KANCAH4D | BUKTI JACKPOT 18 AUG 2026",title:"🔥 KANCAH4D | BUKTI JACKPOT 18 AUG 2026",date:"18 AUG 2026",gameProvider:"PG Soft",gameName:"Mahjong Ways",imageUrl:"https://ik.imagekit.io/dxokd3m9y/tolkon.png",username:"b***99",winAmount:"Rp 48.750.000",betAmount:"Rp 10.000",multiplier:"x4875",badgeText:"MAXWIN",badgeColor:"yellow",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"30x (Turbo Off)",spinAutoTurboOn:"80x (Turbo On)",spinAutoTurboOff:"50x (Turbo Off)",spinChance:"Double Chance Aktif",jamHoki:"14:30 - 16:45 WIB & 21:00 - 23:30 WIB",rtpLive:"98.6%"},tips:"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal.",isHighlighted:!1,createdAt:"2026-08-18T16:20:00Z"},{id:"jp-3",buttonLabel:"🎁 KANCAH4D | BUKTI JACKPOT 17 AUG 2026",title:"🔥 KANCAH4D | BUKTI JACKPOT 17 AUG 2026",date:"17 AUG 2026",gameProvider:"Pragmatic Play",gameName:"Gates of Olympus 1000",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner1.webp",username:"k***77",winAmount:"Rp 92.500.000",betAmount:"Rp 18.500",multiplier:"x5000",badgeText:"GACOR",badgeColor:"red",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"20x (Turbo Off)",spinAutoTurboOn:"50x (Turbo On)",spinAutoTurboOff:"30x (Turbo Off)",spinChance:"Double Chance ON",jamHoki:"01:00 - 03:30 WIB & 18:00 - 20:30 WIB",rtpLive:"99.1%"},tips:"Trik petir merah: main di jam subuh dengan taruhan naik bertahap setelah 20 spin pertama.",isHighlighted:!1,createdAt:"2026-08-17T14:10:00Z"},{id:"jp-4",buttonLabel:"🎁 KANCAH4D | BUKTI MAXWIN 16 AUG 2026",title:"🔥 KANCAH4D | BUKTI MAXWIN 16 AUG 2026",date:"16 AUG 2026",gameProvider:"Pragmatic Play",gameName:"Starlight Princess 1000",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner4.webp",username:"p***23",winAmount:"Rp 75.000.000",betAmount:"Rp 15.000",multiplier:"x5000",badgeText:"VIP",badgeColor:"yellow",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"15x (Turbo Off)",spinAutoTurboOn:"60x (Turbo On)",spinAutoTurboOff:"40x (Turbo Off)",spinChance:"DC Aktif",jamHoki:"11:00 - 13:30 WIB & 19:30 - 22:00 WIB",rtpLive:"98.4%"},tips:"Pecahan bintang perkalian x500 sering keluar di free spin ke-4 dan ke-7.",isHighlighted:!1,createdAt:"2026-08-16T12:00:00Z"},{id:"jp-5",buttonLabel:"🎁 KANCAH4D | BUKTI JACKPOT 15 AUG 2026",title:"🔥 KANCAH4D | BUKTI JACKPOT 15 AUG 2026",date:"15 AUG 2026",gameProvider:"PG Soft",gameName:"Lucky Neko",imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner5.webp",username:"m***11",winAmount:"Rp 36.200.000",betAmount:"Rp 8.000",multiplier:"x4525",badgeText:"HOT",badgeColor:"green",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"20x (Turbo Off)",spinAutoTurboOn:"50x (Turbo On)",spinAutoTurboOff:"30x (Turbo Off)",spinChance:"Bet Standar",jamHoki:"15:00 - 17:30 WIB",rtpLive:"97.8%"},tips:"Kucing emas membawa keberuntungan dengan multiplier bertingkat yang terus bertambah.",isHighlighted:!1,createdAt:"2026-08-15T09:30:00Z"}],Nl=[{id:"m-1",brand:"KANCAH4D",text:"SITUS RESMI TERBAIK",highlight:"TERPERCAYA",badge:"HOT",badgeType:"yellow"},{id:"m-2",brand:"KANCAH4D",text:"DEPOSIT & WITHDRAWAL",highlight:"HITUNGAN DETIK",badge:"VIP",badgeType:"blue"},{id:"m-3",brand:"KANCAH4D",text:"BONUS HARIAN & CASHBACK",highlight:"TERBESAR 202
3146",badge:"GACOR",badgeType:"red"},{id:"m-4",brand:"KANCAH4D",text:"RTP LIVE SLOT TERTINGGI",highlight:"UP TO 99.2%",badge:"MAXWIN",badgeType:"green"}],D2=Ks.memo(({items:r})=>{const e=r&&r.length>0?r:Nl,t=e.length<5?[...e,...e]:e;return h.jsx("div",{className:"w-full my-1.5 sm:my-2 px-0",id:"kancah-marquee-section",children:h.jsx("div",{className:"k4d-led-box",children:h.jsxs("div",{className:"k4d-marquee-container",children:[h.jsx("div",{className:"k4d-marquee-content",children:t.map((n,i)=>h.jsxs(Ks.Fragment,{children:[h.jsxs("span",{className:"k4d-text-item",children:[n.brand?h.jsx("span",{className:"k4d-brand",children:n.brand}):null,n.text,n.highlight?h.jsx("span",{className:i%2===0?"k4d-highlight-yellow":"k4d-highlight-blue",children:n.highlight}):null]}),n.badge?h.jsx("span",{className:`k4d-badge ${n.badgeType==="blue"?"k4d-badge-blue":n.badgeType==="green"?"bg-emerald-500 text-black shadow-[0_0_6px_#10b981]":n.badgeType==="red"?"bg-red-500 text-white shadow-[0_0_6px_#ef4444]":"k4d-badge-yellow"}`,children:n.badge}):null]},`m1-${n.id||i}-${i}`))}),h.jsx("div",{className:"k4d-marquee-content","aria-hidden":"true",children:t.map((n,i)=>h.jsxs(Ks.Fragment,{children:[h.jsxs("span",{className:"k4d-text-item",children:[n.brand?h.jsx("span",{className:"k4d-brand",children:n.brand}):null,n.text,n.highlight?h.jsx("span",{className:i%2===0?"k4d-highlight-yellow":"k4d-highlight-blue",children:n.highlight}):null]}),n.badge?h.jsx("span",{className:`k4d-badge ${n.badgeType==="blue"?"k4d-badge-blue":n.badgeType==="green"?"bg-emerald-500 text-black shadow-[0_0_6px_#10b981]":n.badgeType==="red"?"bg-red-500 text-white shadow-[0_0_6px_#ef4444]":"k4d-badge-yellow"}`,children:n.badge}):null]},`m2-${n.id||i}-${i}`))})]})})})}),v2=({proof:r,proofs:e=[],config:t,onClose:n,onNavigate:i})=>{const[o,u]=be.useState(!1),[B,f]=be.useState(!1),[g,y]=be.useState(0),[b,D]=be.useState(!1),T=be.useRef(null),M=be.useRef(null),z=be.useRef(0);be.useEffect(()=>{u(!1),f(!1)},[r==null?void 0:r.id]);const W=be.useMemo(()=>!e||e.length===0||!r?-1:e.findIndex(Le=>Le.id===r.id),[e,r]),K=e.length,he=K>1&&W!==-1,de=be.useCallback(()=>{if(!he||!i)return;const Le=(W-1+K)%K;i(e[Le])},[he,i,W,K,e]),ce=be.useCallback(()=>{if(!he||!i)return;const Le=(W+1)%K;i(e[Le])},[he,i,W,K,e]);be.useEffect(()=>{const Le=Bt=>{Bt.key==="ArrowLeft"?de():Bt.key==="ArrowRight"?ce():Bt.key==="Escape"&&n()};return window.addEventListener("keydown",Le),()=>window.removeEventListener("keydown",Le)},[de,ce,n]);const _e=Le=>{Le.touches.length!==1||!he||(T.current=Le.touches[0].clientX,M.current=Le.touches[0].clientY,z.current=Date.now(),D(!1))},ye=Le=>{if(T.current===null||M.current===null||!he)return;const Bt=Le.touches[0].clientX,$=Le.touches[0].clientY,pe=Bt-T.current,Re=$-M.current;if(Math.abs(pe)>Math.abs(Re)&&Math.abs(pe)>8){D(!0);const qe=pe*.38;y(Math.max(-80,Math.min(80,qe)))}},S=Le=>{if(T.current===null||M.current===null||!he){y(0),D(!1);return}const Bt=Le.changedTouches[0].clientX,$=Le.changedTouches[0].clientY,pe=Bt-T.current,Re=$-M.current,qe=Date.now()-z.current;Math.abs(pe)>38&&Math.abs(pe)>Math.abs(Re)*1.15&&qe<700&&(pe<0?ce():de()),T.current=null,M.current=null,y(0),D(!1)};if(!r)return null;const A=r.playUrl||t.modalPlayButtonUrl||t.registerUrl||"https://akseslink.com/kancah4d",k=t.modalPlayButtonText||"Mainkan Pola",w=r.claimUrl||t.modalClaimButtonUrl||t.loginUrl||"https://akseslink.com/kancah4d",O=t.modalClaimButtonText||"🚀 LOGIN & KLAIM JACKPOT SEKARANG",L=t.modalCopyButtonText||"Salin Pola",N=()=>{const Le=`🎰 POLA GACOR ${r.gameName.toUpperCase()} - ${r.gameProvider.toUpperCase()}
315⚡ Spin Manual : ${r.polaGacor.spinManual}
316⚡ Spin Auto Turbo ON : ${r.polaGacor.spinAutoTurboOn}
317⚡ Spin Auto Turbo OFF : ${r.polaGacor.spinAutoTurboOff}
318🕒 Jam Hoki : ${r.polaGacor.jamHoki}
319📊 RTP Live : ${r.polaGacor.rtpLive}
320💡 Tips : ${r.tips}
321🔥 Mainkan di KANCAH4D: ${t.mainCtaUrl||t.registerUrl}`;navigator.clipboard.writeText(Le),u(!0),setTimeout(()=>u(!1),2500)};return h.jsx("div",{id:"kancahModalPopup2",className:"fixed inset-0 bg-black/85 backdrop-blur-sm z-[99999] flex items-center justify-center p-2 sm:p-4 overflow-y-auto select-none",onClick:Le=>{Le.target===Le.currentTarget&&n()},children:h.jsxs("div",{className:"relative w-full max-w-[460px] my-auto bg-gradient-to-b from-[#131a2a] to-[#0b0f19] rounded-2xl border-2 border-white overflow-hidden shadow-[0_10px_35px_rgba(255,255,255,0.18),0_20px_45px_rgba(0,0,0,0.9)] text-white text-left max-h-[94vh] flex flex-col will-change-transform",onTouchStart:_e,onTouchMove:ye,onTouchEnd:S,style:{transform:`translate3d(${g}px, 0, 0)`,transition:b?"none":"transform 0.28s cubic-bezier(0.16, 1, 0.3, 1)"},children:[h.jsxs("div",{className:"absolute top-2.5 inset-x-2.5 flex items-center justify-between z-30 pointer-events-none",children:[he?h.jsxs("div",{className:"pointer-events-auto px-2.5 py-1 rounded-full bg-slate-950/80 backdrop-blur-md border border-cyan-400/50 text-[10.5px] font-bold text-cyan-300 flex items-center gap-1.5 shadow-lg",children:[h.jsxs("span",{className:"text-yellow-400 font-extrabold",children:[W+1,"/",K]}),h.jsx("span",{className:"text-slate-400",children:"•"}),h.jsx("span",{className:"text-[10px] tracking-tight",children:"👈 Geser Bukti 👉"})]}):h.jsx("div",{}),h.jsx("button",{onClick:n,"aria-label":"Tutup Modal",className:"pointer-events-auto w-8 h-8 rounded-full bg-red-600/90 hover:bg-red-600 border border-white/60 text-white font-bold text-base flex items-center justify-center shadow-[0_4px_12px_rgba(0,0,0,0.7)] curs
321or-pointer transition-transform hover:scale-110 active:scale-95",children:"✕"})]}),h.jsxs("div",{className:"overflow-y-auto max-h-[94vh] touch-pan-y",children:[h.jsxs("div",{className:"relative w-full bg-black leading-none border-b border-white/15 group min-h-[160px] flex items-center justify-center overflow-hidden",children:[h.jsx("img",{src:r.imageUrl,alt:r.title,loading:"eager",decoding:"async",fetchPriority:"high",className:"w-full h-auto max-h-[260px] sm:max-h-[300px] object-contain mx-auto block cursor-pointer select-none animate-[modalFadeIn2_0.25s_ease-out]",onClick:()=>f(!B),title:"Klik untuk perbesar gambar bukti jackpot"},r.id),he&&h.jsxs(h.Fragment,{children:[h.jsx("button",{type:"button",onClick:Le=>{Le.stopPropagation(),de()},id:"btn-prev-jackpot-proof",className:"absolute left-2 top-1/2 -translate-y-1/2 w-8 h-8 sm:w-9 sm:h-9 rounded-full bg-slate-950/75 hover:bg-cyan-600/90 text-white border border-cyan-400/50 flex items-center justify-center shadow-lg transition-all active:scale-90 cursor-pointer z-20",title:"Bukti Sebelumnya (Geser Kanan)","aria-label":"Bukti Sebelumnya",children:h.jsx(mg,{className:"w-5 h-5 text-cyan-300"})}),h.jsx("button",{type:"button",onClick:Le=>{Le.stopPropagation(),ce()},id:"btn-next-jackpot-proof",className:"absolute right-2 top-1/2 -translate-y-1/2 w-8 h-8 sm:w-9 sm:h-9 rounded-full bg-slate-950/75 hover:bg-cyan-600/90 text-white border border-cyan-400/50 flex items-center justify-center shadow-lg transition-all active:scale-90 cursor-pointer z-20",title:"Bukti Berikutnya (Geser Kiri)","aria-label":"Bukti Berikutnya",children:h.jsx(hi,{className:"w-5 h-5 text-cyan-300"})})]}),h.jsxs("div",{className:"absolute bottom-2 left-2 bg-black/75 backdrop-blur-md px-2.5 py-1 rounded-md border border-emerald-500/50 flex items-center gap-1.5 text-[11px] text-emerald-400 font-bold z-10",children:[h.jsx("span",{className:"w-2 h-2 rounded-full bg-emerald-400 animate-ping"}),h.jsx("span",{children:"TERVERIFIKASI RESMI"})]}),r.winAmount&&h.jsxs("div",{className:"absolute bottom-2 right-2 bg-gradient-to-r from-yellow-500 to-amber-600 text-black font-black text-xs px-2.5 py-1 rounded-md shadow-lg flex items-center gap-1 z-10",children:[h.jsx(p2,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:r.winAmount})]})]}),B&&h.jsx("div",{className:"fixed inset-0 z-[100000] bg-black/95 flex items-center justify-center p-2",onClick:()=>f(!1),children:h.jsxs("div",{className:"relative max-w-full max-h-full",children:[h.jsx("img",{src:r.imageUrl,alt:r.title,className:"max-w-full max-h-[95vh] object-contain rounded-lg border border-yellow-500/50"}),h.jsx("button",{onClick:()=>f(!1),className:"absolute top-2 right-2 bg-red-600 text-white p-2 rounded-full font-bold text-sm",children:"✕ Tutup"})]})}),h.jsxs("div",{className:"p-4 sm:p-5",children:[h.jsxs("h3",{className:"font-extrabold text-sm sm:text-base text-yellow-400 border-b border-white/10 pb-2 mb-3 tracking-wide uppercase flex items-center justify-between gap-2",children:[h.jsx("span",{className:"truncate",children:r.title}),he&&h.jsxs("span",{className:"text-[10px] font-mono font-bold text-cyan-300 flex-shrink-0",children:["#",W+1]})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs mb-3",children:[h.jsxs("div",{className:"bg-[#0b101d] p-2.5 rounded-lg border border-slate-800 flex flex-col justify-center",children:[h.jsx("span",{className:"text-slate-400 text-[10px] uppercase font-semibold",children:"Game & Provider"}),h.jsx("span",{className:"font-black text-slate-100 text-xs truncate mt-0.5",children:r.gameName}),h.jsx("span",{className:"text-[10px] text-cyan-400 font-bold",children:r.gameProvider})]}),h.jsxs("div",{className:"bg-[#0b101d] p-2.5 rounded-lg border border-slate-800 flex flex-col justify-center",children:[h.jsx("span",{className:"text-slate-400 text-[10px] uppercase font-semibold",children:"Username Member"}),h.jsx("span",{className:"font-black text-yellow-400 text-xs mt-0.5",children:r.username}),h.jsx("span",{className:"text-[10px] text-emerald-400 font-semibold",children:r.date})]}),h.jsxs("div",{className:"bg-[#0b101d] p-2.5 rounded-lg border border-slate-800 flex flex-col justify-center",children:[h.jsx("span",{className:"text-slate-400 text-[10px] uppercase font-semibold",children:"Total Kemenangan"}),h.jsx("span",{className:"font-black text-emerald-400 text-sm mt-0.5",children:r.winAmount})]}),h.jsxs("div",{className:"bg-[#0b101d] p-2.5 rounded-lg border border-slate-800 flex flex-col justify-center",children:[h.jsx("span",{className:"text-slate-400 text-[10px] uppercase font-semibold",children:"Perkalian Maxwin"}),h.jsx("span",{className:"font-black text-cyan-400 text-sm mt-0.5",children:r.multiplier||"x5000"})]})]}),h.jsxs("div",{className:"p-3 bg-gradient-to-br from-[#0c1428] via-[#091020] to-[#060b17] rounded-xl border border-yellow-500/30 shadow-[0_0_15px_rgba(234,179,8,0.1)] text-xs space-y-2",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-yellow-500/20 pb-1.5",children:[h.jsxs("div",{className:"flex items-center gap-1.5 font-black text-yellow-400 text-[13px] tracking-wide",children:[h.jsx(Sr,{className:"w-4 h-4 text-yellow-400"}),h.jsx("span",{children:"POLA GACOR HARI INI"})]}),h.jsxs("div",{className:"px-2 py-0.5 bg-emerald-500/20 border border-emerald-500/40 rounded text-emerald-400 font-black text-[10px] flex items-center gap-1",children:[h.jsx(f2,{className:"w-3 h-3"}),h.jsxs("span",{children:["RTP ",r.polaGacor.rtpLive]})]})]}),h.jsxs("div",{className:"space-y-1.5 text-[11px] pt-1",children:[h.jsxs("div",{className:"flex items-center gap-1.5",children:[h.jsx("span",{className:"text-yellow-400",children:"⚡"}),h.jsx("span",{className:"text-slate-400",children:"Spin Manual :"}),h.jsx("strong",{className:"text-white font-bold ml-auto",children:r.polaGacor.spinManual})]}),h.jsxs("div",{className:"flex items-center gap-1.5",children:[h.jsx("span",{className:"text-yellow-400",children:"⚡"}),h.jsx("span",{className:"text-slate-400",children:"Spin Auto (Turbo On) :"}),h.jsx("strong",{className:"text-cyan-300 font-bold ml-auto",children:r.polaGacor.spinAutoTurboOn})]}),h.jsxs("div",{className:"flex items-center gap-1.5",children:[h.jsx("span",{className:"text-yellow-400",children:"⚡"}),h.jsx("span",{className:"text-slate-400",children:"Spin Auto (Turbo Off) :"}),h.jsx("strong",{className:"text-emerald-300 font-bold ml-auto",children:r.polaGacor.spinAutoTurboOff})]}),r.polaGacor.spinChance&&h.jsxs("div",{className:"flex items-center gap-1.5 text-[11px]",children:[h.jsx("span",{className:"text-yellow-400",children:"⚡"}),h.jsx("span",{className:"text-slate-400",children:"Opsi Bet / Fitur :"}),h.jsx("strong",{className:"text-purple-300 font-bold ml-auto",children:r.polaGacor.spinChance})]}),r.polaGacor.jamHoki&&h.jsxs("div",{className:"flex items-center gap-1.5 pt-1 text-[11px] text-amber-300 border-t border-white/5",children:[h.jsx(s1,{className:"w-3 h-3 text-amber-400"}),h.jsx("span",{className:"text-slate-400",children:"Jam Hoki:"}),h.jsx("span",{className:"font-bold ml-auto",children:r.polaGacor.jamHoki})]})]}),h.jsxs("div",{className:"mt-2 pt-2 border-t border-dashed border-white/15 text-rose-400 font-semibold text-[11px] leading-snug",children:["💡 ",h.jsx("strong",{children:"Tips:"})," ",r.tips||"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal."]})]}),h.jsxs("div",{className:"mt-4 space-y-2",children:[h.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[h.jsx("button",{type:"button",onClick:N,className:"flex items-center justify-center gap-1.5 py-2.5 px-3 bg-slate-800 hover:bg-slate-700 text-slate-200 text-xs font-bold rounded-lg border border-slate-600 transition cursor-pointer active:scale-95 shadow-sm",children:o?h.jsxs(h.Fragment,{children:[h.jsx(t1,{className:"w-3.5 h-3.5 text-emerald-400"}),h.jsx("span",{className:"text-emerald-400 font-bold",children:"Tersalin!"})]}):h.jsxs(h.Fragment,{children:[h.jsx(a1,{className:"w-3.5 h-3.5 text-cyan-400"}),h.jsx("span",{children:L})]})}),h.jsxs("a",{href:A,target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-1 py-2.5 px-3 bg-gradient-to-r from-emerald-600 to-teal-600 hover:from-emerald-500 hover:to-teal-500 text-white text-xs font-extrabold rounded-lg border border-emerald-400 shadow-[0_0_12px_rgba(16,185,129,0.4)] transition cursor-pointer active:scale-95",children:[h.jsx(bl,{className:"w-3.5 h-3.5 text-yellow-300"}),h.jsx("span",{children:k})]})]}),h.jsx("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"w-full flex items-center justify-center gap-1.5 py-3 px-4 bg-gradient-to-r from-blue-700 via-indigo-700 to-blue-800 hover:from-blue-600 hover:to-indigo-600 text-white font-extrabold text-xs uppercase tracking-wider rounded-lg border border-white/60 shadow-[0_0_18px_rgba(37,99,235,0.6)] transition active:scale-[0.98]",children:h.jsx("span",{children:O})}),r.customCtaText&&r.customCtaUrl&&h.jsxs("a",{href:r.customCtaUrl,target:"_blank",rel:"noopener noreferrer",className:"w-full flex items-center justify-center gap-1.5 py-2.5 px-4 bg-gradient-to-r from-amber-600 to-yellow-600 hover:from-amber-500 hover:to-yellow-500 text-slate-950 font-black text-xs uppercase tracking-wider rounded-lg border border-yellow-300 shadow-[0_0_12px_rgba(234,179,8,0.4)] transition active:scale-[0.98]",children:[h.jsx("span",{children:r.customCtaText}),h.jsx(il,{className:"w-3.5 h-3.5"})]})]}),he&&h.jsxs("div",{className:"mt-3.5 pt-2.5 border-t border-slate-800 flex items-center justify-between text-[11px] text-slate-400",children:[h.jsxs("button",{type:"button",onClick:de,className:"flex items-center gap-1 text-cyan-400 hover:text-cyan-300 font-bold transition active:scale-95 cursor-pointer",children:[h.jsx(mg,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Bukti Sebelumnya"})]}),h.jsxs("span",{className:"text-[10px] text-slate-400 font-mono",children:[W+1," / ",K]}),h.jsxs("button",{type:"button",onClick:ce,className:"flex items-center gap-1 text-cyan-400 hover:text-cyan-300 font-bold transition active:scale-95 cursor-pointer",children:[h.jsx("span",{children:"Bukti Berikutnya"}),h.jsx(hi,{className:"w-3.5 h-3.5"})]})]})]})]})]})})},w2=({config:r,isOpen:e,onClose:t})=>{const n=r.welcomePopup||{enabled:!0,imageUrl:"https://ik.imagekit.io/CBadak/ChatGPT%20Image%20Aug%2026,%202026,%2006_03_10%20PM.png"};if(!e||!n.enabled||!n.imageUrl)return null;const i=n.imageUrl;return h.jsx("div",{id:"kancahWelcomePromoOverlay",className:"fixed inset-0 bg-black/80 backdrop-blur-sm z-[999999] flex items-center justify-center p-3 sm:p-6 cursor-pointer select-none animate-[fadeIn_0.25s_ease-out]",onClick:t,title:"Klik di mana saja untuk menutup",children:h.jsx("div",{className:"relative max-w-[420px] w-full my-auto flex flex-col items-center justify-center animate-[modalFadeIn2_0.35s_cubic-bezier(0.16,1,0.3,1)]",onClick:t,children:h.jsxs("div",{className:"relative w-full flex items-center justify-center",children:[h.jsx("div",{className:"absolute inset-0 m-auto w-[85%] h-[85%] rounded-full opacity-35 blur-3xl pointer-events-none",style:{background:"radial-gradient(circle, rgba(6,182,212,0.5) 0%, rgba(14,165,233,0.2) 50%, transparent 80%)"}}),h.jsx("img",{src:i,alt:"Promo Kancah4D",className:"w-auto h-auto max-w-full max-h-[86vh] object-contain block pointer-events-none select-none drop-shadow-[0_15px_35px_rgba(0,0,0,0.9)] relative z-10",crossOrigin:"anonymous"}),h.jsx("div",{className:"absolute inset-0 pointer-events-none overflow-hidden z-20",style:{WebkitMaskImage:`url("${i}")`,maskImage:`url("${i}")`,WebkitMaskSize:"contain",maskSize:"contain",WebkitMaskRepeat:"no-repeat",maskRepeat:"no-repeat",WebkitMaskPosition:"center",maskPosition:"center"},children:h.jsx("div",{className:"absolute -inset-[60%] w-[220%] h-[220%] animate-light-sweep",style:{background:"linear-gradient(115deg, transparent 38%, rgba(255,255,255,0.08) 45%, rgba(255,255,255,0.6) 50%, rgba(56,189,248,0.45) 54%, transparent 62%)"}})})]})})})};/**
322 * @license
323 * Copyright 2025 Google LLC
324 *
325 * Licensed under the Apache License, Version 2.0 (the "License");
326 * you may not use this file except in compliance with the License.
327 * You may obtain a copy of the License at
328 *
329 *   http://www.apache.org/licenses/LICENSE-2.0
330 *
331 * Unless required by applicable law or agreed to in writing, software
332 * distributed under the License is distributed on an "AS IS" BASIS,
333 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
334 * See the License for the specific language governing permissions and
335 * limitations under the License.
336 */const T2=()=>{};var eE={};/**
337 * @license
338 * Copyright 2017 Google LLC
339 *
340 * Licensed under the Apache License, Version 2.0 (the "License");
341 * you may not use this file except in compliance with the License.
342 * You may obtain a copy of the License at
343 *
344 *   http://www.apache.org/licenses/LICENSE-2.0
345 *
346 * Unless required by applicable law or agreed to in writing, software
347 * distributed under the License is distributed on an "AS IS" BASIS,
348 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
349 * See the License for the specific language governing permissions and
350 * limitations under the License.
351 */const o1=function(r){const e=[];let t=0;for(let n=0;n<r.length;n++){let i=r.charCodeAt(n);i<128?e[t++]=i:i<2048?(e[t++]=i>>6|192,e[t++]=i&63|128):(i&64512)===55296&&n+1<r.length&&(r.charCodeAt(n+1)&64512)===56320?(i=65536+((i&1023)<<10)+(r.charCodeAt(++n)&1023),e[t++]=i>>18|240,e[t++]=i>>12&63|128,e[t++]=i>>6&63|128,e[t++]=i&63|128):(e[t++]=i>>12|224,e[t++]=i>>6&63|128,e[t++]=i&63|128)}return e},A2=function(r){const e=[];let t=0,n=0;for(;t<r.length;){const i=r[t++];if(i<128)e[n++]=String.fromCharCode(i);else if(i>191&&i<224){const o=r[t++];e[n++]=String.fromCharCode((i&31)<<6|o&63)}else if(i>239&&i<365){const o=r[t++],u=r[t++],B=r[t++],f=((i&7)<<18|(o&63)<<12|(u&63)<<6|B&63)-65536;e[n++]=String.fromCharCode(55296+(f>>10)),e[n++]=String.fromCharCode(56320+(f&1023))}else{const o=r[t++],u=r[t++];e[n++]=String.fromCharCode((i&15)<<12|(o&63)<<6|u&63)}}return e.join("")},u1={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(r,e){if(!Array.isArray(r))throw Error("encodeByteArray takes an array as a parameter");this.init_();const t=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,n=[];for(let i=0;i<r.length;i+=3){const o=r[i],u=i+1<r.length,B=u?r[i+1]:0,f=i+2<r.length,g=f?r[i+2]:0,y=o>>2,b=(o&3)<<4|B>>4;let D=(B&15)<<2|g>>6,T=g&63;f||(T=64,u||(D=64)),n.push(t[y],t[b],t[D],t[T])}return n.join("")},encodeString(r,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(r):this.encodeByteArray(o1(r),e)},decodeString(r,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(r):A2(this.decodeStringToByteArray(r,e))},decodeStringToByteArray(r,e){this.init_();const t=e?this.charToByteMapWebSafe_:this.charToByteMap_,n=[];for(let i=0;i<r.length;){const o=t[r.charAt(i++)],B=i<r.length?t[r.charAt(i)]:0;++i;const g=i<r.length?t[r.charAt(i)]:64;++i;const b=i<r.length?t[r.charAt(i)]:64;if(++i,o==null||B==null||g==null||b==null)throw new N2;const D=o<<2|B>>4;if(n.push(D),g!==64){const T=B<<4&240|g>>2;if(n.push(T),b!==64){const M=g<<6&192|b;n.push(M)}}}return n},init_(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(let r=0;r<this.ENCODED_VALS.length;r++)this.byteToCharMap_[r]=this.ENCODED_VALS.charAt(r),this.charToByteMap_[this.byteToCharMap_[r]]=r,this.byteToCharMapWebSafe_[r]=this.ENCODED_VALS_WEBSAFE.charAt(r),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[r]]=r,r>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(r)]=r,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(r)]=r)}}};class N2 extends Error{constructor(){super(...arguments),this.name="DecodeBase64StringError"}}const I2=function(r){const e=o1(r);return u1.encodeByteArray(e,!0)},c1=function(r){return I2(r).replace(/\./g,"")},S2=function(r){try{return u1.decodeString(r,!0)}catch(e){console.error("base64Decode failed: ",e)}return null};/**
352 * @license
353 * Copyright 2022 Google LLC
354 *
355 * Licensed under the Apache License, Version 2.0 (the "License");
356 * you may not use this file except in compliance with the License.
357 * You may obtain a copy of the License at
358 *
359 *   http://www.apache.org/licenses/LICENSE-2.0
360 *
361 * Unless required by applicable law or agreed to in writing, software
362 * distributed under the License is distributed on an "AS IS" BASIS,
363 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
364 * See the License for the specific language governing permissions and
365 * limitations under the License.
366 */function B1(){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.")}/**
367 * @license
368 * Copyright 2022 Google LLC
369 *
370 * Licensed under the Apache License, Version 2.0 (the "License");
371 * you may not use this file except in compliance with the License.
372 * You may obtain a copy of the License at
373 *
374 *   http://www.apache.org/licenses/LICENSE-2.0
375 *
376 * Unless required by applicable law or agreed to in writing, software
377 * distributed under the License is distributed on an "AS IS" BASIS,
378 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
379 * See the License for the specific language governing permissions and
380 * limitations under the License.
381 */const R2=()=>B1().__FIREBASE_DEFAULTS__,O2=()=>{if(typeof process>"u"||typeof eE>"u")return;const r=eE.__FIREBASE_DEFAULTS__;if(r)return JSON.parse(r)},k2=()=>{if(typeof document>"u")return;let r;try{r=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}const e=r&&S2(r[1]);return e&&JSON.parse(e)},h1=()=>{try{return T2()||R2()||O2()||k2()}catch(r){console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${r}`);return}},L2=()=>{var r;return(r=h1())==null?void 0:r.config};/**
382 * @license
383 * Copyright 2017 Google LLC
384 *
385 * Licensed under the Apache License, Version 2.0 (the "License");
386 * you may not use this file except in compliance with the License.
387 * You may obtain a copy of the License at
388 *
389 *   http://www.apache.org/licenses/LICENSE-2.0
390 *
391 * Unless required by applicable law or agreed to in writing, software
392 * distributed under the License is distributed on an "AS IS" BASIS,
393 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
394 * See the License for the specific language governing permissions and
395 * limitations under the License.
396 */class j2{constructor(){this.reject=()=>{},this.resolve=()=>{},this.promise=new Promise((e,t)=>{this.resolve=e,this.reject=t})}wrapCallback(e){return(t,n)=>{t?this.reject(t):this.resolve(n),typeof e=="function"&&(this.promise.catch(()=>{}),e.length===1?e(t):e(t,n))}}}/**
397 * @license
398 * Copyright 2017 Google LLC
399 *
400 * Licensed under the Apache License, Version 2.0 (the "License");
401 * you may not use this file except in compliance with the License.
402 * You may obtain a copy of the License at
403 *
404 *   http://www.apache.org/licenses/LICENSE-2.0
405 *
406 * Unless required by applicable law or agreed to in writing, software
407 * distributed under the License is distributed on an "AS IS" BASIS,
408 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
409 * See the License for the specific language governing permissions and
410 * limitations under the License.
411 */function Fd(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function d1(){var e;const r=(e=h1())==null?void 0:e.forceEnvironment;if(r==="node")return!0;if(r==="browser")return!1;try{return Object.prototype.toString.call(global.process)==="[object process]"}catch{return!1}}function f1(){return!d1()&&!!navigator.userAgent&&navigator.userAgent.includes("Safari")&&!navigator.userAgent.includes("Chrome")}function m1(){return!d1()&&!!navigator.userAgent&&(navigator.userAgent.includes("Safari")||navigator.userAgent.includes("WebKit"))&&!navigator.userAgent.includes("Chrome")}function p1(){try{return typeof indexedDB=="object"}catch{return!1}}function M2(){return new Promise((r,e)=>{try{let t=!0;const n="validate-browser-context-for-indexeddb-analytics-module",i=self.indexedDB.open(n);i.onsuccess=()=>{i.result.close(),t||self.indexedDB.deleteDatabase(n),r(!0)},i.onupgradeneeded=()=>{t=!1},i.onerror=()=>{var o;e(((o=i.error)==null?void 0:o.message)||"")}}catch(t){e(t)}})}/**
412 * @license
413 * Copyright 2017 Google LLC
414 *
415 * Licensed under the Apache License, Version 2.0 (the "License");
416 * you may not use this file except in compliance with the License.
417 * You may obtain a copy of the License at
418 *
419 *   http://www.apache.org/licenses/LICENSE-2.0
420 *
421 * Unless required by applicable law or agreed to in writing, software
422 * distributed under the License is distributed on an "AS IS" BASIS,
423 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
424 * See the License for the specific language governing permissions and
425 * limitations under the License.
426 */const P2="FirebaseError";class vu extends Error{constructor(e,t,n){super(t),this.code=e,this.customData=n,this.name=P2,Object.setPrototypeOf(this,vu.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,g1.prototype.create)}}class g1{constructor(e,t,n){this.service=e,this.serviceName=t,this.errors=n}create(e,...t){const n=t[0]||{},i=`${this.service}/${e}`,o=this.errors[e],u=o?V2(o,n):"Error",B=`${this.serviceName}: ${u} (${i}).`;return new vu(i,B,n)}}function V2(r,e){try{let t=0,n="";for(;t<r.length;){const i=r.indexOf("{$",t);if(i===-1){n+=r.substring(t);break}const o=r.indexOf("}",i+2);if(o===-1){n+=r.substring(t);break}const u=r.substring(i+2,o),B=e[u];n+=r.substring(t,i)+(B!=null?String(B):`<${u}?>`),t=o+1}return n}catch{return r}}function Gd(r,e){if(r===e)return!0;const t=Object.keys(r),n=Object.keys(e);for(const i of t){if(!n.includes(i))return!1;const o=r[i],u=e[i];if(tE(o)&&tE(u)){if(!Gd(o,u))return!1}else if(o!==u)return!1}for(const i of n)if(!t.includes(i))return!1;return!0}function tE(r){return r!==null&&typeof r=="object"}/**
427 * @license
428 * Copyright 2021 Google LLC
429 *
430 * Licensed under the Apache License, Version 2.0 (the "License");
431 * you may not use this file except in compliance with the License.
432 * You may obtain a copy of the License at
433 *
434 *   http://www.apache.org/licenses/LICENSE-2.0
435 *
436 * Unless required by applicable law or agreed to in writing, software
437 * distributed under the License is distributed on an "AS IS" BASIS,
438 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
439 * See the License for the specific language governing permissions and
440 * limitations under the License.
441 */function iB(r){return r&&r._delegate?r._delegate:r}/**
442 * @license
443 * Copyright 2025 Google LLC
444 *
445 * Licensed under the Apache License, Version 2.0 (the "License");
446 * you may not use this file except in compliance with the License.
447 * You may obtain a copy of the License at
448 *
449 *   http://www.apache.org/licenses/LICENSE-2.0
450 *
451 * Unless required by applicable law or agreed to in writing, software
452 * distributed under the License is distributed on an "AS IS" BASIS,
453 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
454 * See the License for the specific language governing permissions and
455 * limitations under the License.
456 */function C1(r){try{return(r.startsWith("http://")||r.startsWith("https://")?new URL(r).hostname:r).endsWith(".cloudworkstations.dev")}catch{return!1}}async function F2(r){return(await fetch(r,{credentials:"include"})).ok}class lB{constructor(e,t,n){this.name=e,this.instanceFactory=t,this.type=n,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}}/**
457 * @license
458 * Copyright 2019 Google LLC
459 *
460 * Licensed under the Apache License, Version 2.0 (the "License");
461 * you may not use this file except in compliance with the License.
462 * You may obtain a copy of the License at
463 *
464 *   http://www.apache.org/licenses/LICENSE-2.0
465 *
466 * Unless required by applicable law or agreed to in writing, software
467 * distributed under the License is distributed on an "AS IS" BASIS,
468 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
469 * See the License for the specific language governing permissions and
470 * limitations under the License.
471 */const ll="[DEFAULT]";/**
472 * @license
473 * Copyright 2019 Google LLC
474 *
475 * Licensed under the Apache License, Version 2.0 (the "License");
476 * you may not use this file except in compliance with the License.
477 * You may obtain a copy of the License at
478 *
479 *   http://www.apache.org/licenses/LICENSE-2.0
480 *
481 * Unless required by applicable law or agreed to in writing, software
482 * distributed under the License is distributed on an "AS IS" BASIS,
483 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
484 * See the License for the specific language governing permissions and
485 * limitations under the License.
486 */class G2{constructor(e,t){this.name=e,this.container=t,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}get(e){const t=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(t)){const n=new j2;if(this.instancesDeferred.set(t,n),this.isInitialized(t)||this.shouldAutoInitialize())try{const i=this.getOrInitializeService({instanceIdentifier:t});i&&n.resolve(i)}catch{}}return this.instancesDeferred.get(t).promise}getImmediate(e){const t=this.normalizeInstanceIdentifier(e==null?void 0:e.identifier),n=(e==null?void 0:e.optional)??!1;if(this.isInitialized(t)||this.shouldAutoInitialize())try{return this.getOrInitializeService({instanceIdentifier:t})}catch(i){if(n)return null;throw i}else{if(n)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(U2(e))try{this.getOrInitializeService({instanceIdentifier:ll})}catch{}for(const[t,n]of this.instancesDeferred.entries()){const i=this.normalizeInstanceIdentifier(t);try{const o=this.getOrInitializeService({instanceIdentifier:i});n.resolve(o)}catch{}}}}clearInstance(e=ll){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(t=>"INTERNAL"in t).map(t=>t.INTERNAL.delete()),...e.filter(t=>"_delete"in t).map(t=>t._delete())])}isComponentSet(){return this.component!=null}isInitialized(e=ll){return this.instances.has(e)}getOptions(e=ll){return this.instancesOptions.get(e)||{}}initialize(e={}){const{options:t={}}=e,n=this.normalizeInstanceIdentifier(e.instanceIdentifier);if(this.isInitialized(n))throw Error(`${this.name}(${n}) has already been initialized`);if(!this.isComponentSet())throw Error(`Component ${this.name} has not been registered yet`);const i=this.getOrInitializeService({instanceIdentifier:n,options:t});for(const[o,u]of this.instancesDeferred.entries()){const B=this.normalizeInstanceIdentifier(o);n===B&&u.resolve(i)}return i}onInit(e,t){const n=this.normalizeInstanceIdentifier(t),i=this.onInitCallbacks.get(n)??new Set;i.add(e),this.onInitCallbacks.set(n,i);const o=this.instances.get(n);return o&&e(o,n),()=>{i.delete(e)}}invokeOnInitCallbacks(e,t){const n=this.onInitCallbacks.get(t);if(n)for(const i of n)try{i(e,t)}catch{}}getOrInitializeService({instanceIdentifier:e,options:t={}}){let n=this.instances.get(e);if(!n&&this.component&&(n=this.component.instanceFactory(this.container,{instanceIdentifier:H2(e),options:t}),this.instances.set(e,n),this.instancesOptions.set(e,t),this.invokeOnInitCallbacks(n,e),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,e,n)}catch{}return n||null}normalizeInstanceIdentifier(e=ll){return this.component?this.component.multipleInstances?e:ll:e}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}}function H2(r){return r===ll?void 0:r}function U2(r){return r.instantiationMode==="EAGER"}/**
487 * @license
488 * Copyright 2019 Google LLC
489 *
490 * Licensed under the Apache License, Version 2.0 (the "License");
491 * you may not use this file except in compliance with the License.
492 * You may obtain a copy of the License at
493 *
494 *   http://www.apache.org/licenses/LICENSE-2.0
495 *
496 * Unless required by applicable law or agreed to in writing, softw
496are
497 * distributed under the License is distributed on an "AS IS" BASIS,
498 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
499 * See the License for the specific language governing permissions and
500 * limitations under the License.
501 */class z2{constructor(e){this.name=e,this.providers=new Map}addComponent(e){const t=this.getProvider(e.name);if(t.isComponentSet())throw new Error(`Component ${e.name} has already been registered with ${this.name}`);t.setComponent(e)}addOrOverwriteComponent(e){this.getProvider(e.name).isComponentSet()&&this.providers.delete(e.name),this.addComponent(e)}getProvider(e){if(this.providers.has(e))return this.providers.get(e);const t=new G2(e,this);return this.providers.set(e,t),t}getProviders(){return Array.from(this.providers.values())}}/**
502 * @license
503 * Copyright 2017 Google LLC
504 *
505 * Licensed under the Apache License, Version 2.0 (the "License");
506 * you may not use this file except in compliance with the License.
507 * You may obtain a copy of the License at
508 *
509 *   http://www.apache.org/licenses/LICENSE-2.0
510 *
511 * Unless required by applicable law or agreed to in writing, software
512 * distributed under the License is distributed on an "AS IS" BASIS,
513 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
514 * See the License for the specific language governing permissions and
515 * limitations under the License.
516 */var ut;(function(r){r[r.DEBUG=0]="DEBUG",r[r.VERBOSE=1]="VERBOSE",r[r.INFO=2]="INFO",r[r.WARN=3]="WARN",r[r.ERROR=4]="ERROR",r[r.SILENT=5]="SILENT"})(ut||(ut={}));const q2={debug:ut.DEBUG,verbose:ut.VERBOSE,info:ut.INFO,warn:ut.WARN,error:ut.ERROR,silent:ut.SILENT},K2=ut.INFO,J2={[ut.DEBUG]:"log",[ut.VERBOSE]:"log",[ut.INFO]:"info",[ut.WARN]:"warn",[ut.ERROR]:"error"},Q2=(r,e,...t)=>{if(e<r.logLevel)return;const n=new Date().toISOString(),i=J2[e];if(i)console[i](`[${n}]  ${r.name}:`,...t);else throw new Error(`Attempted to log a message with an invalid logType (value: ${e})`)};class y1{constructor(e){this.name=e,this._logLevel=K2,this._logHandler=Q2,this._userLogHandler=null}get logLevel(){return this._logLevel}set logLevel(e){if(!(e in ut))throw new TypeError(`Invalid value "${e}" assigned to \`logLevel\``);this._logLevel=e}setLogLevel(e){this._logLevel=typeof e=="string"?q2[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,ut.DEBUG,...e),this._logHandler(this,ut.DEBUG,...e)}log(...e){this._userLogHandler&&this._userLogHandler(this,ut.VERBOSE,...e),this._logHandler(this,ut.VERBOSE,...e)}info(...e){this._userLogHandler&&this._userLogHandler(this,ut.INFO,...e),this._logHandler(this,ut.INFO,...e)}warn(...e){this._userLogHandler&&this._userLogHandler(this,ut.WARN,...e),this._logHandler(this,ut.WARN,...e)}error(...e){this._userLogHandler&&this._userLogHandler(this,ut.ERROR,...e),this._logHandler(this,ut.ERROR,...e)}}const Y2=(r,e)=>e.some(t=>r instanceof t);let nE,sE;function X2(){return nE||(nE=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function $2(){return sE||(sE=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}const b1=new WeakMap,gg=new WeakMap,x1=new WeakMap,$p=new WeakMap,lC=new WeakMap;function Z2(r){const e=new Promise((t,n)=>{const i=()=>{r.removeEventListener("success",o),r.removeEventListener("error",u)},o=()=>{t(gi(r.result)),i()},u=()=>{n(r.error),i()};r.addEventListener("success",o),r.addEventListener("error",u)});return e.then(t=>{t instanceof IDBCursor&&b1.set(t,r)}).catch(()=>{}),lC.set(e,r),e}function W2(r){if(gg.has(r))return;const e=new Promise((t,n)=>{const i=()=>{r.removeEventListener("complete",o),r.removeEventListener("error",u),r.removeEventListener("abort",u)},o=()=>{t(),i()},u=()=>{n(r.error||new DOMException("AbortError","AbortError")),i()};r.addEventListener("complete",o),r.addEventListener("error",u),r.addEventListener("abort",u)});gg.set(r,e)}let Cg={get(r,e,t){if(r instanceof IDBTransaction){if(e==="done")return gg.get(r);if(e==="objectStoreNames")return r.objectStoreNames||x1.get(r);if(e==="store")return t.objectStoreNames[1]?void 0:t.objectStore(t.objectStoreNames[0])}return gi(r[e])},set(r,e,t){return r[e]=t,!0},has(r,e){return r instanceof IDBTransaction&&(e==="done"||e==="store")?!0:e in r}};function eN(r){Cg=r(Cg)}function tN(r){return r===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(e,...t){const n=r.call(Zp(this),e,...t);return x1.set(n,e.sort?e.sort():[e]),gi(n)}:$2().includes(r)?function(...e){return r.apply(Zp(this),e),gi(b1.get(this))}:function(...e){return gi(r.apply(Zp(this),e))}}function nN(r){return typeof r=="function"?tN(r):(r instanceof IDBTransaction&&W2(r),Y2(r,X2())?new Proxy(r,Cg):r)}function gi(r){if(r instanceof IDBRequest)return Z2(r);if($p.has(r))return $p.get(r);const e=nN(r);return e!==r&&($p.set(r,e),lC.set(e,r)),e}const Zp=r=>lC.get(r);function sN(r,e,{blocked:t,upgrade:n,blocking:i,terminated:o}={}){const u=indexedDB.open(r,e),B=gi(u);return n&&u.addEventListener("upgradeneeded",f=>{n(gi(u.result),f.oldVersion,f.newVersion,gi(u.transaction),f)}),t&&u.addEventListener("blocked",f=>t(f.oldVersion,f.newVersion,f)),B.then(f=>{o&&f.addEventListener("close",()=>o()),i&&f.addEventListener("versionchange",g=>i(g.oldVersion,g.newVersion,g))}).catch(()=>{}),B}const rN=["get","getKey","getAll","getAllKeys","count"],aN=["put","add","delete","clear"],Wp=new Map;function rE(r,e){if(!(r instanceof IDBDatabase&&!(e in r)&&typeof e=="string"))return;if(Wp.get(e))return Wp.get(e);const t=e.replace(/FromIndex$/,""),n=e!==t,i=aN.includes(t);if(!(t in(n?IDBIndex:IDBObjectStore).prototype)||!(i||rN.includes(t)))return;const o=async function(u,...B){const f=this.transaction(u,i?"readwrite":"readonly");let g=f.store;
516return n&&(g=g.index(B.shift())),(await Promise.all([g[t](...B),i&&f.done]))[0]};return Wp.set(e,o),o}eN(r=>({...r,get:(e,t,n)=>rE(e,t)||r.get(e,t,n),has:(e,t)=>!!rE(e,t)||r.has(e,t)}));/**
517 * @license
518 * Copyright 2019 Google LLC
519 *
520 * Licensed under the Apache License, Version 2.0 (the "License");
521 * you may not use this file except in compliance with the License.
522 * You may obtain a copy of the License at
523 *
524 *   http://www.apache.org/licenses/LICENSE-2.0
525 *
526 * Unless required by applicable law or agreed to in writing, software
527 * distributed under the License is distributed on an "AS IS" BASIS,
528 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
529 * See the License for the specific language governing permissions and
530 * limitations under the License.
531 */class iN{constructor(e){this.container=e}getPlatformInfoString(){return this.container.getProviders().map(t=>{if(lN(t)){const n=t.getImmediate();return`${n.library}/${n.version}`}else return null}).filter(t=>t).join(" ")}}function lN(r){const e=r.getComponent();return(e==null?void 0:e.type)==="VERSION"}const yg="@firebase/app",aE="0.16.0";/**
532 * @license
533 * Copyright 2019 Google LLC
534 *
535 * Licensed under the Apache License, Version 2.0 (the "License");
536 * you may not use this file except in compliance with the License.
537 * You may obtain a copy of the License at
538 *
539 *   http://www.apache.org/licenses/LICENSE-2.0
540 *
541 * Unless required by applicable law or agreed to in writing, software
542 * distributed under the License is distributed on an "AS IS" BASIS,
543 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
544 * See the License for the specific language governing permissions and
545 * limitations under the License.
546 */const ga=new y1("@firebase/app"),oN="@firebase/app-compat",uN="@firebase/analytics-compat",cN="@firebase/analytics",BN="@firebase/app-check-compat",hN="@firebase/app-check",dN="@firebase/auth",fN="@firebase/auth-compat",mN="@firebase/database",pN="@firebase/data-connect",gN="@firebase/database-compat",CN="@firebase/functions",yN="@firebase/functions-compat",bN="@firebase/installations",xN="@firebase/installations-compat",EN="@firebase/messaging",_N="@firebase/messaging-compat",DN="@firebase/performance",vN="@firebase/performance-compat",wN="@firebase/remote-config",TN="@firebase/remote-config-compat",AN="@firebase/storage",NN="@firebase/storage-compat",IN="@firebase/firestore",SN="@firebase/ai",RN="@firebase/firestore-compat",ON="firebase",kN="12.17.0";/**
547 * @license
548 * Copyright 2019 Google LLC
549 *
550 * Licensed under the Apache License, Version 2.0 (the "License");
551 * you may not use this file except in compliance with the License.
552 * You may obtain a copy of the License at
553 *
554 *   http://www.apache.org/licenses/LICENSE-2.0
555 *
556 * Unless required by applicable law or agreed to in writing, software
557 * distributed under the License is distributed on an "AS IS" BASIS,
558 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
559 * See the License for the specific language governing permissions and
560 * limitations under the License.
561 */const LN="[DEFAULT]",jN={[yg]:"fire-core",[oN]:"fire-core-compat",[cN]:"fire-analytics",[uN]:"fire-analytics-compat",[hN]:"fire-app-check",[BN]:"fire-app-check-compat",[dN]:"fire-auth",[fN]:"fire-auth-compat",[mN]:"fire-rtdb",[pN]:"fire-data-connect",[gN]:"fire-rtdb-compat",[CN]:"fire-fn",[yN]:"fire-fn-compat",[bN]:"fire-iid",[xN]:"fire-iid-compat",[EN]:"fire-fcm",[_N]:"fire-fcm-compat",[DN]:"fire-perf",[vN]:"fire-perf-compat",[wN]:"fire-rc",[TN]:"fire-rc-compat",[AN]:"fire-gcs",[NN]:"fire-gcs-compat",[IN]:"fire-fst",[RN]:"fire-fst-compat",[SN]:"fire-vertex","fire-js":"fire-js",[ON]:"fire-js-all"};/**
562 * @license
563 * Copyright 2019 Google LLC
564 *
565 * Licensed under the Apache License, Version 2.0 (the "License");
566 * you may not use this file except in compliance with the License.
567 * You may obtain a copy of the License at
568 *
569 *   http://www.apache.org/licenses/LICENSE-2.0
570 *
571 * Unless required by applicable law or agreed to in writing, software
572 * distributed under the License is distributed on an "AS IS" BASIS,
573 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
574 * See the License for the specific language governing permissions and
575 * limitations under the License.
576 */const bg=new Map,MN=new Map,xg=new Map;function iE(r,e){try{r.container.addComponent(e)}catch(t){ga.debug(`Component ${e.name} failed to register with FirebaseApp ${r.name}`,t)}}function Hd(r){const e=r.name;if(xg.has(e))return ga.debug(`There were multiple attempts to register component ${e}.`),!1;xg.set(e,r);for(const t of bg.values())iE(t,r);for(const t of MN.values())iE(t,r);return!0}function PN(r,e){const t=r.container.getProvider("heartbeat").getImmediate({optional:!0});return t&&t.triggerHeartbeat(),r.container.getProvider(e)}function VN(r){return r==null?!1:r.settings!==void 0}/**
577 * @license
578 * Copyright 2019 Google LLC
579 *
580 * Licensed under the Apache License, Version 2.0 (the "License");
581 * you may not use this file except in compliance with the License.
582 * You may obtain a copy of the License at
583 *
584 *   http://www.apache.org/licenses/LICENSE-2.0
585 *
586 * Unless required by applicable law or agreed to in writing, software
587 * distributed under the License is distributed on an "AS IS" BASIS,
588 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
589 * See the License for the specific language governing permissions and
590 * limitations under the License.
591 */const FN={"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 {$mismatchedParam}. Existing: '{$oldValue}'. New: '{$newValue}'.","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
591d-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."},fi=new g1("app","Firebase",FN);/**
592 * @license
593 * Copyright 2019 Google LLC
594 *
595 * Licensed under the Apache License, Version 2.0 (the "License");
596 * you may not use this file except in compliance with the License.
597 * You may obtain a copy of the License at
598 *
599 *   http://www.apache.org/licenses/LICENSE-2.0
600 *
601 * Unless required by applicable law or agreed to in writing, software
602 * distributed under the License is distributed on an "AS IS" BASIS,
603 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
604 * See the License for the specific language governing permissions and
605 * limitations under the License.
606 */class GN{constructor(e,t,n){this._isDeleted=!1,this._options={...e},this._config={...t},this._name=t.name,this._automaticDataCollectionEnabled=t.automaticDataCollectionEnabled,this._container=n,this.container.addComponent(new lB("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 fi.create("app-deleted",{appName:this._name})}}/**
607 * @license
608 * Copyright 2019 Google LLC
609 *
610 * Licensed under the Apache License, Version 2.0 (the "License");
611 * you may not use this file except in compliance with the License.
612 * You may obtain a copy of the License at
613 *
614 *   http://www.apache.org/licenses/LICENSE-2.0
615 *
616 * Unless required by applicable law or agreed to in writing, software
617 * distributed under the License is distributed on an "AS IS" BASIS,
618 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
619 * See the License for the specific language governing permissions and
620 * limitations under the License.
621 */const HN=kN;function UN(r,e={}){let t=r;typeof e!="object"&&(e={name:e});const n={name:LN,automaticDataCollectionEnabled:!0,...e},i=n.name;if(typeof i!="string"||!i)throw fi.create("bad-app-name",{appName:String(i)});if(t||(t=L2()),!t)throw fi.create("no-options");const o=bg.get(i);if(o)if(Gd(t,o.options)){if(Gd(n,o.config))return o;throw fi.create("duplicate-app",{appName:i,mismatchedParam:"config",oldValue:JSON.stringify(o.config),newValue:JSON.stringify(n)})}else throw fi.create("duplicate-app",{appName:i,mismatchedParam:"options",oldValue:JSON.stringify(o.options),newValue:JSON.stringify(t)});const u=new z2(i);for(const f of xg.values())u.addComponent(f);const B=new GN(t,n,u);return bg.set(i,B),B}function Xo(r,e,t){let n=jN[r]??r;t&&(n+=`-${t}`);const i=n.match(/\s|\//),o=e.match(/\s|\//);if(i||o){const u=[`Unable to register library "${n}" with version "${e}":`];i&&u.push(`library name "${n}" contains illegal characters (whitespace or "/")`),i&&o&&u.push("and"),o&&u.push(`version name "${e}" contains illegal characters (whitespace or "/")`),ga.warn(u.join(" "));return}Hd(new lB(`${n}-version`,()=>({library:n,version:e}),"VERSION"))}/**
622 * @license
623 * Copyright 2021 Google LLC
624 *
625 * Licensed under the Apache License, Version 2.0 (the "License");
626 * you may not use this file except in compliance with the License.
627 * You may obtain a copy of the License at
628 *
629 *   http://www.apache.org/licenses/LICENSE-2.0
630 *
631 * Unless required by applicable law or agreed to in writing, softw
631are
632 * distributed under the License is distributed on an "AS IS" BASIS,
633 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
634 * See the License for the specific language governing permissions and
635 * limitations under the License.
636 */const zN="firebase-heartbeat-database",qN=1,oB="firebase-heartbeat-store";let eg=null;function E1(){return eg||(eg=sN(zN,qN,{upgrade:(r,e)=>{switch(e){case 0:try{r.createObjectStore(oB)}catch(t){console.warn(t)}}}}).catch(r=>{throw fi.create("idb-open",{originalErrorMessage:r.message})})),eg}async function KN(r){try{const t=(await E1()).transaction(oB),n=await t.objectStore(oB).get(_1(r));return await t.done,n}catch(e){if(e instanceof vu)ga.warn(e.message);else{const t=fi.create("idb-get",{originalErrorMessage:e==null?void 0:e.message});ga.warn(t.message)}}}async function lE(r,e){try{const n=(await E1()).transaction(oB,"readwrite");await n.objectStore(oB).put(e,_1(r)),await n.done}catch(t){if(t instanceof vu)ga.warn(t.message);else{const n=fi.create("idb-set",{originalErrorMessage:t==null?void 0:t.message});ga.warn(n.message)}}}function _1(r){return`${r.name}!${r.options.appId}`}/**
637 * @license
638 * Copyright 2021 Google LLC
639 *
640 * Licensed under the Apache License, Version 2.0 (the "License");
641 * you may not use this file except in compliance with the License.
642 * You may obtain a copy of the License at
643 *
644 *   http://www.apache.org/licenses/LICENSE-2.0
645 *
646 * Unless required by applicable law or agreed to in writing, software
647 * distributed under the License is distributed on an "AS IS" BASIS,
648 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
649 * See the License for the specific language governing permissions and
650 * limitations under the License.
651 */const JN=1024,QN=30;class YN{constructor(e){this.container=e,this._heartbeatsCache=null;const t=this.container.getProvider("app").getImmediate();this._storage=new $N(t),this._heartbeatsCachePromise=this._storage.read().then(n=>(this._heartbeatsCache=n,n))}async triggerHeartbeat(){var e,t;try{const i=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),o=oE();if(((e=this._heartbeatsCache)==null?void 0:e.heartbeats)==null&&(this._heartbeatsCache=await this._heartbeatsCachePromise,((t=this._heartbeatsCache)==null?void 0:t.heartbeats)==null)||this._heartbeatsCache.lastSentHeartbeatDate===o||this._heartbeatsCache.heartbeats.some(u=>u.date===o))return;if(this._heartbeatsCache.heartbeats.push({date:o,agent:i}),this._heartbeatsCache.heartbeats.length>QN){const u=ZN(this._heartbeatsCache.heartbeats);this._heartbeatsCache.heartbeats.splice(u,1)}return this._storage.overwrite(this._heartbeatsCache)}catch(n){ga.warn(n)}}async getHeartbeatsHeader(){var e;try{if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,((e=this._heartbeatsCache)==null?void 0:e.heartbeats)==null||this._heartbeatsCache.heartbeats.length===0)return"";const t=oE(),{heartbeatsToSend:n,unsentEntries:i}=XN(this._heartbeatsCache.heartbeats),o=c1(JSON.stringify({version:2,heartbeats:n}));return this._heartbeatsCache.lastSentHeartbeatDate=t,i.length>0?(this._heartbeatsCache.heartbeats=i,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),o}catch(t){return ga.warn(t),""}}}function oE(){return new Date().toISOString().substring(0,10)}function XN(r,e=JN){const t=[];let n=r.slice();for(const i of r){const o=t.find(u=>u.agent===i.agent);if(o){if(o.dates.push(i.date),uE(t)>e){o.dates.pop();break}}else if(t.push({agent:i.agent,dates:[i.date]}),uE(t)>e){t.pop();break}n=n.slice(1)}return{heartbeatsToSend:t,unsentEntries:n}}class $N{constructor(e){this.app=e,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return p1()?M2().then(()=>!0).catch(()=>!1):!1}async read(){if(await this._canUseIndexedDBPromise){const t=await KN(this.app);return t!=null&&t.heartbeats?t:{heartbeats:[]}}else return{heartbeats:[]}}async overwrite(e){if(await this._canUseIndexedDBPromise){const n=await this.read();return lE(this.app,{lastSentHeartbeatDate:e.lastSentHeartbeatDate??n.lastSentHeartbeatDate,heartbeats:e.heartbeats})}else return}async add(e){if(await this._canUseIndexedDBPromise){const n=await this.read();return lE(this.app,{lastSentHeartbeatDate:e.lastSentHeartbeatDate??n.lastSentHeartbeatDate,heartbeats:[...n.heartbeats,...e.heartbeats]})}else return}}function uE(r){return c1(JSON.stringify({version:2,heartbeats:r})).length}function ZN(r){if(r.length===0)return-1;let e=0,t=r[0].date;for(let n=1;n<r.length;n++)r[n].date<t&&(t=r[n].date,e=n);return e}/**
652 * @license
653 * Copyright 2019 Google LLC
654 *
655 * Licensed under the Apache License, Version 2.0 (the "License");
656 * you may not use this file except in compliance with the License.
657 * You may obtain a copy of the License at
658 *
659 *   http://www.apache.org/licenses/LICENSE-2.0
660 *
661 * Unless required by applicable law or agreed to in writing, software
662 * distributed under the License is distributed on an "AS IS" BASIS,
663 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
664 * See the License for the specific language governing permissions and
665 * limitations under the License.
666 */function WN(r){Hd(new lB("platform-logger",e=>new iN(e),"PRIVATE")),Hd(new lB("heartbeat",e=>new YN(e),"PRIVATE")),Xo(yg,aE,r),Xo(yg,aE,"esm2020"),Xo("fire-js","")}/**
667 * @license
668 * Copyright 2019 Google LLC
669 *
670 * Licensed under the Apache License, Version 2.0 (the "License");
671 * you may not use this file except in compliance with the License.
672 * You may obtain a copy of the License at
673 *
674 *   http://www.apache.org/licenses/LICENSE-2.0
675 *
676 * Unless required by applicable law or agreed to in writing, software
677 * distributed under the License is distributed on an "AS IS" BASIS,
678 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
679 * See the License for the specific language governing permissions and
680 * limitations under the License.
681 */WN("");var eI="firebase",tI="12.17.1";/**
682 * @license
683 * Copyright 2020 Google LLC
684 *
685 * Licensed under the Apache License, Version 2.0 (the "License");
686 * you may not use this file except in compliance with the License.
687 * You may obtain a copy of the License at
688 *
689 *   http://www.apache.org/licenses/LICENSE-2.0
690 *
691 * Unless required by applicable law or agreed to in writing, software
692 * distributed under the License is distributed on an "AS IS" BASIS,
693 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
694 * See the License for the specific language governing permissions and
695 * limitations under the License.
696 */Xo(eI,tI,"app");var cE=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/** @license
697Copyright The Closure Library Authors.
698SPDX-License-Identifier: Apache-2.0
699*/var Ci,D1;(function(){var r;/** @license
700
701 Copyright The Closure Library Authors.
702 SPDX-License-Identifier: Apache-2.0
703*/function e(S,A){function k(){}k.prototype=A.prototype,S.F=A.prototype,S.prototype=new k,S.prototype.constructor=S,S.D=function(w,O,L){for(var N=Array(arguments.length-2),Le=2;Le<arguments.length;Le++)N[Le-2]=arguments[Le];return A.prototype[O].apply(w,N)}}function t(){this.blockSize=-1}function n(){this.blockSize=-1,this.blockSize=64,this.g=Array(4),this.C=Array(this.blockSize),this.o=this.h=0,this.u()}e(n,t),n.prototype.u=function(){this.g[0]=1732584193,this.g[1]=4023233417,this.g[2]=2562383102,this.g[3]=271733878,this.o=this.h=0};function i(S,A,k){k||(k=0);const w=Array(16);if(typeof A=="string")for(var O=0;O<16;++O)w[O]=A.charCodeAt(k++)|A.charCodeAt(k++)<<8|A.charCodeAt(k++)<<16|A.charCodeAt(k++)<<24;else for(O=0;O<16;++O)w[O]=A[k++]|A[k++]<<8|A[k++]<<16|A[k++]<<24;A=S.g[0],k=S.g[1],O=S.g[2];let L=S.g[3],N;N=A+(L^k&(O^L))+w[0]+3614090360&4294967295,A=k+(N<<7&4294967295|N>>>25),N=L+(O^A&(k^O))+w[1]+3905402710&4294967295,L=A+(N<<12&4294967295|N>>>20),N=O+(k^L&(A^k))+w[2]+606105819&4294967295,O=L+(N<<17&4294967295|N>>>15),N=k+(A^O&(L^A))+w[3]+3250441966&4294967295,k=O+(N<<22&4294967295|N>>>10),N=A+(L^k&(O^L))+w[4]+4118548399&4294967295,A=k+(N<<7&4294967295|N>>>25),N=L+(O^A&(k^O))+w[5]+1200080426&4294967295,L=A+(N<<12&4294967295|N>>>20),N=O+(k^L&(A^k))+w[6]+2821735955&4294967295,O=L+(N<<17&4294967295|N>>>15),N=k+(A^O&(L^A))+w[7]+4249261313&4294967295,k=O+(N<<22&4294967295|N>>>10),N=A+(L^k&(O^L))+w[8]+1770035416&4294967295,A=k+(N<<7&4294967295|N>>>25),N=L+(O^A&(k^O))+w[9]+2336552879&4294967295,L=A+(N<<12&4294967295|N>>>20),N=O+(k^L&(A^k))+w[10]+4294925233&4294967295,O=L+(N<<17&4294967295|N>>>15),N=k+(A^O&(L^A))+w[11]+2304563134&4294967295,k=O+(N<<22&4294967295|N>>>10),N=A+(L^k&(O^L))+w[12]+1804603682&4294967295,A=k+(N<<7&4294967295|N>>>25),N=L+(O^A&(k^O))+w[13]+4254626195&4294967295,L=A+(N<<12&4294967295|N>>>20),N=O+(k^L&(A^k))+w[14]+2792965006&4294967295,O=L+(N<<17&4294967295|N>>>15),N=k+(A^O&(L^A))+w[15]+1236535329&4294967295,k=O+(N<<22&4294967295|N>>>10),N=A+(O^L&(k^O))+w[1]+4129170786&4294967295,A=k+(N<<5&4294967295|N>>>27),N=L+(k^O&(A^k))+w[6]+3225465664&4294967295,L=A+(N<<9&4294967295|N>>>23),N=O+(A^k&(L^A))+w[11]+643717713&4294967295,O=L+(N<<14&4294967295|N>>>18),N=k+(L^A&(O^L))+w[0]+3921069994&4294967295,k=O+(N<<20&4294967295|N>>>12),N=A+(O^L&(k^O))+w[5]+3593408605&4294967295,A=k+(N<<5&4294967295|N>>>27),N=L+(k^O&(A^k))+w[10]+38016083&4294967295,L=A+(N<<9&4294967295|N>>>23),N=O+(A^k&(L^A))+w[15]+3634488961&4294967295,O=L+(N<<14&4294967295|N>>>18),N=k+(L^A&(O^L))+w[4]+3889429448&4294967295,k=O+(N<<20&4294967295|N>>>12),N=A+(O^L&(k^O))+w[9]+568446438&4294967295,A=k+(N<<5&4294967295|N>>>27),N=L+(k^O&(A^k))+w[14]+3275163606&4294967295,L=A+(N<<9&4294967295|N>>>23),N=O+(A^k&(L^A))+w[3]+4107603335&4294967295,O=L+(N<<14&4294967295|N>>>18),N=k+(L^A&(O^L))+w[8]+1163531501&4294967295,k=O+(N<<20&4294967295|N>>>12),N=A+(O^L&(k^O))+w[13]+2850285829&4294967295,A=k+(N<<5&4294967295|N>>>27),N=L+(k^O&(A^k))+w[2]+4243563512&4294967295,L=A+(N<<9&4294967295|N>>>23),N=O+(A^k&(L^A))+w[7]+1735328473&4294967295,O=L+(N<<14&4294967295|N>>>18),N=k+(L^A&(O^L))+w[12]+2368359562&4294967295,k=O+(N<<20&4294967295|N>>>12),N=A+(k^O^L)+w[5]+4294588738&4294967295,A=k+(N<<4&4294967295|N>>>28),N=L+(A^k^O)+w[8]+2272392833&4294967295,L=A+(N<<11&4294967295|N>>>21),N=O+(L^A^k)+w[11]+1839030562&4294967295,O=L+(N<<16&4294967295|N>>>16),N=k+(O^L^A)+w[14]+4259657740&4294967295,k=O+(N<<23&4294967295|N>>>9),N=A+(k^O^L)+w[1]+2763975236&4294967295,A=k+(N<<4&4294967295|N>>>28),N=L+(A^k^O)+w[4]+1272893353&4294967295,L=A+(N<<11&4294967295|N>>>21),N=O+(L^A^k)+w[7]+4139469664&4294967295,O=L+(N<<16&4294967295|N>>>16),N=k+(O^L^A)+w[10]+3200236656&4294967295,k=O+(N<<23&4294967295|N>>>9),N=A+(k^O^L)+w[13]+681279174&4294967295,A=k+(N<<4&4294967295|N>>>28),N=L+(A^k^O)+w[0]+3936430074&4294967295,L=A+(N<<11&4294967295|N>>>21),N=O+(L^A^k)+w[3]+3572445317&4294967295,O=L+(N<<16&4294967295|N>>>16),N=k+(O^L^A)+w[6]+76029189&4294967295,k=O+(N<<23&4294967295|N>>>9),N=A+(k^O^L)+w[9]+3654602809&4294967295,A=k+(N<<4&4294967295|N>>>28),N=L+(A^k^O)+w[12]+3873151461&4294967295,L=A+(N<<11&4294967295|N>>>21),N=O+(L^A^k)+w[15]+530742520&4294967295,O=L+(N<<16&4294967295|N>>>16),N=k+(O^L^A)+w[2]+3299628645&4294967295,k=O+(N<<23&4294967295|N>>>9),N=A+(O^(k|~L))+w[0]+4096336452&4294967295,A=k+(N<<6&4294967295|N>>>26),N=L+(k^(A|~O))+w[7]+1126891415&4294967295,L=A+(N<<10&4294967295|N>>>22),N=O+(A^(L|~k))+w[14]+2878612391&4294967295,O=L+(N<<15&4294967295|N>>>17),N=k+(L^(O|~A))+w[5]+4237533241&4294967295,k=O+(N<<21&4294967295|N>>>11),N=A+(O^(k|~L))+w[12]+1700485571&4294967295,A=k+(N<<6&4294967295|N>>>26),N=L+(k^(A|~O))+w[3]+2399980690&4294967295,L=A+(N<<10&4294967295|N>>>22),N=O+(A^(L|~k))+w[10]+4293915773&4294967295,O=L+(N<<15&4294967295|N>>>17),N=k+(L^(O|~A))+w[1]+2240044497&4294967295,k=O+(N<<21&4294967295|N>>>11),N=A+(O^(k|~L))+w[8]+1873313359&4294967295,A=k+(N<<6&4294967295|N>>>26),N=L+(k^(A|~O))+w[15]+4264355552&4294967295,L=A+(N<<10&4294967295|N>>>22),N=O+(A^(L|~k))+w[6]+2734768916&4294967295,O=L+(N<<15&4294967295|N>>>17),N=k+(L^(O|~A))+w[13]+1309151649&4294967295,k=O+(N<<21&4294967295|N>>>11),N=A+(O^(k|~L))+w[4]+4149444226&4294967295,A=k+(N<<6&4294967295|N>>>26),N=L+(k^(A|~O))+w[11]+3174756917&4294967295,L=A+(N<<10&4294967295|N>>>22),N=O+(A^(L|~k))+w[2]+718787259&4294967295,O=L+(N<<15&4294967295|N>>>17),N=k+(L^(O|~A))+w[9]+3951481745&4294967295,S.g[0]=S.g[0]+A&4294967295,S.g[1]=S.g[1]+(O+(N<<21&4294967295|N>>>11))&4294967295,S.g[2]=S.g[2]+O&4294967295,S.g[3]=S.g[3]+L&4294967295}n.prototype.v=function(S,A){A===void 0&&(A=S.length);const k=A-this.blockSize,w=this.C;let O=this.h,L=0;for(;L<A;){if(O==0)for(;L<=k;)i(this,S,L),L+=this.blockSize;if(typeof S=="string"){for(;L<A;)if(w[O++]=S.charCodeAt(L++),O==this.blockSize){i(this,w),O=0;break}}else for(;L<A;)if(w[O++]=S[L++],O==this.blockSize){i(this,w),O=0;break}}this.h=O,this.o+=A},n.prototype.A=function(){var S=Array((this.h<56?this.blockSize:this.blockSize*2)-this.h);S[0]=128;for(var A=1;A<S.length-8;++A)S[A]=0;A=this.o*8;for(var k=S.length-8;k<S.length;++k)S[k]=A&255,A/=256;for(this.v(S),S=Array(16),A=0,k=0;k<4;++k)for(let w=0;w<32;w+=8)S[A++]=this.g[k]>>>w&255;return S};function o(S,A){var k=B;return Object.prototype.hasOwnProperty.call(k,S)?k[S]:k[S]=A(S)}function u(S,A){this.h=A;const k=[];let w=!0;for(let O=S.length-1;O>=0;O--){const L=S[O]|0;w&&L==A||(k[O]=L,w=!1)}this.g=k}var B={};function f(S){return-128<=S&&S<128?o(S,function(A){return new u([A|0],A<0?-1:0)}):new u([S|0],S<0?-1:0)}function g(S){if(isNaN(S)||!isFinite(S))return b;if(S<0)return W(g(-S));const A=[];let k=1;for(let w=0;S>=k;w++)A[w]=S/k|0,k*=4294967296;return new u(A,0)}function y(S,A){if(S.length==0)throw Error("number format error: empty string");if(A=A||10,A<2||36<A)throw Error("radix out of range: "+A);if(S.charAt(0)=="-")return W(y(S.substring(1),A));if(S.indexOf("-")>=0)throw Error('number format error: interior "-" character');const k=g(Math.pow(A,8));let w=b;for(let L=0;L<S.length;L+=8){var O=Math.min(8,S.length-L);const N=parseInt(S.substring(L,L+O),A);O<8?(O=g(Math.pow(A,O)),w=w.j(O).add(g(N))):(w=w.j(k),w=w.add(g(N)))}return w}var b=f(0),D=f(1),T=f(16777216);r=u.prototype,r.m=function(){if(z(this))return-W(this).m();let S=0,A=1;for(let k=0;k<this.g.length;k++){const w=this.i(k);S+=(w>=0?w:4294967296+w)*A,A*=4294967296}return S},r.toString=function(S){if(S=S||10,S<2||36<S)throw Error("radix out of range: "+S);if(M(this))return"0";
703if(z(this))return"-"+W(this).toString(S);const A=g(Math.pow(S,6));var k=this;let w="";for(;;){const O=ce(k,A).g;k=K(k,O.j(A));let L=((k.g.length>0?k.g[0]:k.h)>>>0).toString(S);if(k=O,M(k))return L+w;for(;L.length<6;)L="0"+L;w=L+w}},r.i=function(S){return S<0?0:S<this.g.length?this.g[S]:this.h};function M(S){if(S.h!=0)return!1;for(let A=0;A<S.g.length;A++)if(S.g[A]!=0)return!1;return!0}function z(S){return S.h==-1}r.l=function(S){return S=K(this,S),z(S)?-1:M(S)?0:1};function W(S){const A=S.g.length,k=[];for(let w=0;w<A;w++)k[w]=~S.g[w];return new u(k,~S.h).add(D)}r.abs=function(){return z(this)?W(this):this},r.add=function(S){const A=Math.max(this.g.length,S.g.length),k=[];let w=0;for(let O=0;O<=A;O++){let L=w+(this.i(O)&65535)+(S.i(O)&65535),N=(L>>>16)+(this.i(O)>>>16)+(S.i(O)>>>16);w=N>>>16,L&=65535,N&=65535,k[O]=N<<16|L}return new u(k,k[k.length-1]&-2147483648?-1:0)};function K(S,A){return S.add(W(A))}r.j=function(S){if(M(this)||M(S))return b;if(z(this))return z(S)?W(this).j(W(S)):W(W(this).j(S));if(z(S))return W(this.j(W(S)));if(this.l(T)<0&&S.l(T)<0)return g(this.m()*S.m());const A=this.g.length+S.g.length,k=[];for(var w=0;w<2*A;w++)k[w]=0;for(w=0;w<this.g.length;w++)for(let O=0;O<S.g.length;O++){const L=this.i(w)>>>16,N=this.i(w)&65535,Le=S.i(O)>>>16,Bt=S.i(O)&65535;k[2*w+2*O]+=N*Bt,he(k,2*w+2*O),k[2*w+2*O+1]+=L*Bt,he(k,2*w+2*O+1),k[2*w+2*O+1]+=N*Le,he(k,2*w+2*O+1),k[2*w+2*O+2]+=L*Le,he(k,2*w+2*O+2)}for(S=0;S<A;S++)k[S]=k[2*S+1]<<16|k[2*S];for(S=A;S<2*A;S++)k[S]=0;return new u(k,0)};function he(S,A){for(;(S[A]&65535)!=S[A];)S[A+1]+=S[A]>>>16,S[A]&=65535,A++}function de(S,A){this.g=S,this.h=A}function ce(S,A){if(M(A))throw Error("division by zero");if(M(S))return new de(b,b);if(z(S))return A=ce(W(S),A),new de(W(A.g),W(A.h));if(z(A))return A=ce(S,W(A)),new de(W(A.g),A.h);if(S.g.length>30){if(z(S)||z(A))throw Error("slowDivide_ only works with positive integers.");for(var k=D,w=A;w.l(S)<=0;)k=_e(k),w=_e(w);var O=ye(k,1),L=ye(w,1);for(w=ye(w,2),k=ye(k,2);!M(w);){var N=L.add(w);N.l(S)<=0&&(O=O.add(k),L=N),w=ye(w,1),k=ye(k,1)}return A=K(S,O.j(A)),new de(O,A)}for(O=b;S.l(A)>=0;){for(k=Math.max(1,Math.floor(S.m()/A.m())),w=Math.ceil(Math.log(k)/Math.LN2),w=w<=48?1:Math.pow(2,w-48),L=g(k),N=L.j(A);z(N)||N.l(S)>0;)k-=w,L=g(k),N=L.j(A);M(L)&&(L=D),O=O.add(L),S=K(S,N)}return new de(O,S)}r.B=function(S){return ce(this,S).h},r.and=function(S){const A=Math.max(this.g.length,S.g.length),k=[];for(let w=0;w<A;w++)k[w]=this.i(w)&S.i(w);return new u(k,this.h&S.h)},r.or=function(S){const A=Math.max(this.g.length,S.g.length),k=[];for(let w=0;w<A;w++)k[w]=this.i(w)|S.i(w);return new u(k,this.h|S.h)},r.xor=function(S){const A=Math.max(this.g.length,S.g.length),k=[];for(let w=0;w<A;w++)k[w]=this.i(w)^S.i(w);return new u(k,this.h^S.h)};function _e(S){const A=S.g.length+1,k=[];for(let w=0;w<A;w++)k[w]=S.i(w)<<1|S.i(w-1)>>>31;return new u(k,S.h)}function ye(S,A){const k=A>>5;A%=32;const w=S.g.length-k,O=[];for(let L=0;L<w;L++)O[L]=A>0?S.i(L+k)>>>A|S.i(L+k+1)<<32-A:S.i(L+k);return new u(O,S.h)}n.prototype.digest=n.prototype.A,n.prototype.reset=n.prototype.u,n.prototype.update=n.prototype.v,D1=n,u.prototype.add=u.prototype.add,u.prototype.multiply=u.prototype.j,u.prototype.modulo=u.prototype.B,u.prototype.compare=u.prototype.l,u.prototype.toNumber=u.prototype.m,u.prototype.toString=u.prototype.toString,u.prototype.getBits=u.prototype.i,u.fromNumber=g,u.fromString=y,Ci=u}).apply(typeof cE<"u"?cE:typeof self<"u"?self:typeof window<"u"?window:{});var hd=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/** @license
704Copyright The Closure Library Authors.
705SPDX-License-Identifier: Apache-2.0
706*/var v1,Uc,w1,Nd,Eg,T1,A1,N1;(function(){var r,e=Object.defineProperty;function t(d){d=[typeof globalThis=="object"&&globalThis,d,typeof window=="object"&&window,typeof self=="object"&&self,typeof hd=="object"&&hd];for(var C=0;C<d.length;++C){var E=d[C];if(E&&E.Math==Math)return E}throw Error("Cannot find global object")}var n=t(this);function i(d,C){if(C)e:{var E=n;d=d.split(".");for(var v=0;v<d.length-1;v++){var q=d[v];if(!(q in E))break e;E=E[q]}d=d[d.length-1],v=E[d],C=C(v),C!=v&&C!=null&&e(E,d,{configurable:!0,writable:!0,value:C})}}i("Symbol.dispose",function(d){return d||Symbol("Symbol.dispose")}),i("Array.prototype.values",function(d){return d||function(){return this[Symbol.iterator]()}}),i("Object.entries",function(d){return d||function(C){var E=[],v;for(v in C)Object.prototype.hasOwnProperty.call(C,v)&&E.push([v,C[v]]);return E}});/** @license
707
708 Copyright The Closure Library Authors.
709 SPDX-License-Identifier: Apache-2.0
710*/var o=o||{},u=this||self;function B(d){var C=typeof d;return C=="object"&&d!=null||C=="function"}function f(d,C,E){return d.call.apply(d.bind,arguments)}function g(d,C,E){return g=f,g.apply(null,arguments)}
710function y(d,C){var E=Array.prototype.slice.call(arguments,1);return function(){var v=E.slice();return v.push.apply(v,arguments),d.apply(this,v)}}function b(d,C){function E(){}E.prototype=C.prototype,d.Z=C.prototype,d.prototype=new E,d.prototype.constructor=d,d.Ob=function(v,q,Z){for(var Ee=Array(arguments.length-2),Qe=2;Qe<arguments.length;Qe++)Ee[Qe-2]=arguments[Qe];return C.prototype[q].apply(v,Ee)}}var D=typeof AsyncContext<"u"&&typeof AsyncContext.Snapshot=="function"?d=>d&&AsyncContext.Snapshot.wrap(d):d=>d;function T(d){const C=d.length;if(C>0){const E=Array(C);for(let v=0;v<C;v++)E[v]=d[v];return E}return[]}function M(d,C){for(let v=1;v<arguments.length;v++){const q=arguments[v];var E=typeof q;if(E=E!="object"?E:q?Array.isArray(q)?"array":E:"null",E=="array"||E=="object"&&typeof q.length=="number"){E=d.length||0;const Z=q.length||0;d.length=E+Z;for(let Ee=0;Ee<Z;Ee++)d[E+Ee]=q[Ee]}else d.push(q)}}class z{constructor(C,E){this.i=C,this.j=E,this.h=0,this.g=null}get(){let C;return this.h>0?(this.h--,C=this.g,this.g=C.next,C.next=null):C=this.i(),C}}function W(d){u.setTimeout(()=>{throw d},0)}function K(){var d=S;let C=null;return d.g&&(C=d.g,d.g=d.g.next,d.g||(d.h=null),C.next=null),C}class he{constructor(){this.h=this.g=null}add(C,E){const v=de.get();v.set(C,E),this.h?this.h.next=v:this.g=v,this.h=v}}var de=new z(()=>new ce,d=>d.reset());class ce{constructor(){this.next=this.g=this.h=null}set(C,E){this.h=C,this.g=E,this.next=null}reset(){this.next=this.g=this.h=null}}let _e,ye=!1,S=new he,A=()=>{const d=Promise.resolve(void 0);_e=()=>{d.then(k)}};function k(){for(var d;d=K();){try{d.h.call(d.g)}catch(E){W(E)}var C=de;C.j(d),C.h<100&&(C.h++,d.next=C.g,C.g=d)}ye=!1}function w(){this.u=this.u,this.C=this.C}w.prototype.u=!1,w.prototype.dispose=function(){this.u||(this.u=!0,this.N())},w.prototype[Symbol.dispose]=function(){this.dispose()},w.prototype.N=function(){if(this.C)for(;this.C.length;)this.C.shift()()};function O(d,C){this.type=d,this.g=this.target=C,this.defaultPrevented=!1}O.prototype.h=function(){this.defaultPrevented=!0};var L=(function(){if(!u.addEventListener||!Object.defineProperty)return!1;var d=!1,C=Object.defineProperty({},"passive",{get:function(){d=!0}});try{const E=()=>{};u.addEventListener("test",E,C),u.removeEventListener("test",E,C)}catch{}return d})();function N(d){return/^[\s\xa0]*$/.test(d)}function Le(d,C){O.call(this,d?d.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,d&&this.init(d,C)}b(Le,O),Le.prototype.init=function(d,C){const E=this.type=d.type,v=d.changedTouches&&d.changedTouches.length?d.changedTouches[0]:null;this.target=d.target||d.srcElement,this.g=C,C=d.relatedTarget,C||(E=="mouseover"?C=d.fromElement:E=="mouseout"&&(C=d.toElement)),this.relatedTarget=C,v?(this.clientX=v.clientX!==void 0?v.clientX:v.pageX,this.clientY=v.clientY!==void 0?v.clientY:v.pageY,this.screenX=v.screenX||0,this.screenY=v.screenY||0):(this.clientX=d.clientX!==void 0?d.clientX:d.pageX,this.clientY=d.clientY!==void 0?d.clientY:d.pageY,this.screenX=d.screenX||0,this.screenY=d.screenY||0),this.button=d.button,this.key=d.key||"",this.ctrlKey=d.ctrlKey,this.altKey=d.altKey,this.shiftKey=d.shiftKey,this.metaKey=d.metaKey,this.pointerId=d.pointerId||0,this.pointerType=d.pointerType,this.state=d.state,this.i=d,d.defaultPrevented&&Le.Z.h.call(this)},Le.prototype.h=function(){Le.Z.h.call(this);const d=this.i;d.preventDefault?d.preventDefault():d.returnValue=!1};var Bt="closure_listenable_"+(Math.random()*1e6|0),$=0;function pe(d,C,E,v,q){this.listener=d,this.proxy=null,this.src=C,this.type=E,this.capture=!!v,this.ha=q,this.key=++$,this.da=this.fa=!1}function Re(d){d.da=!0,d.listener=null,d.proxy=null,d.src=null,d.ha=null}function qe(d,C,E){for(const v in d)C.call(E,d[v],v,d)}function Ie(d,C){for(const E in d)C.call(void 0,d[E],E,d)}function P(d){const C={};for(const E in d)C[E]=d[E];return C}const ae="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleStr
710ing toString valueOf".split(" ");function xe(d,C){let E,v;for(let q=1;q<arguments.length;q++){v=arguments[q];for(E in v)d[E]=v[E];for(let Z=0;Z<ae.length;Z++)E=ae[Z],Object.prototype.hasOwnProperty.call(v,E)&&(d[E]=v[E])}}function Ae(d){this.src=d,this.g={},this.h=0}Ae.prototype.add=function(d,C,E,v,q){const Z=d.toString();d=this.g[Z],d||(d=this.g[Z]=[],this.h++);const Ee=Ke(d,C,v,q);return Ee>-1?(C=d[Ee],E||(C.fa=!1)):(C=new pe(C,this.src,Z,!!v,q),C.fa=E,d.push(C)),C};function Ge(d,C){const E=C.type;if(E in d.g){var v=d.g[E],q=Array.prototype.indexOf.call(v,C,void 0),Z;(Z=q>=0)&&Array.prototype.splice.call(v,q,1),Z&&(Re(C),d.g[E].length==0&&(delete d.g[E],d.h--))}}function Ke(d,C,E,v){for(let q=0;q<d.length;++q){const Z=d[q];if(!Z.da&&Z.listener==C&&Z.capture==!!E&&Z.ha==v)return q}return-1}var We="closure_lm_"+(Math.random()*1e6|0),Jt={};function Tt(d,C,E,v,q){if(Array.isArray(C)){for(let Z=0;Z<C.length;Z++)Tt(d,C[Z],E,v,q);return null}return E=va(E),d&&d[Bt]?d.J(C,E,B(v)?!!v.capture:!1,q):or(d,C,E,!1,v,q)}function or(d,C,E,v,q,Z){if(!C)throw Error("Invalid event type");const Ee=B(q)?!!q.capture:!!q;let Qe=ur(d);if(Qe||(d[We]=Qe=new Ae(d)),E=Qe.add(C,E,v,Ee,Z),E.proxy)return E;if(v=Gr(),E.proxy=v,v.src=d,v.listener=E,d.addEventListener)L||(q=Ee),q===void 0&&(q=!1),d.addEventListener(C.toString(),v,q);else if(d.attachEvent)d.attachEvent(cs(C.toString()),v);else if(d.addListener&&d.removeListener)d.addListener(v);else throw Error("addEventListener and attachEvent are unavailable.");return E}function Gr(){function d(E){return C.call(d.src,d.listener,E)}const C=_a;return d}function Hr(d,C,E,v,q){if(Array.isArray(C))for(var Z=0;Z<C.length;Z++)Hr(d,C[Z],E,v,q);else v=B(v)?!!v.capture:!!v,E=va(E),d&&d[Bt]?(d=d.i,Z=String(C).toString(),Z in d.g&&(C=d.g[Z],E=Ke(C,E,v,q),E>-1&&(Re(C[E]),Array.prototype.splice.call(C,E,1),C.length==0&&(delete d.g[Z],d.h--)))):d&&(d=ur(d))&&(C=d.g[C.toString()],d=-1,C&&(d=Ke(C,E,v,q)),(E=d>-1?C[d]:null)&&Ur(E))}function Ur(d){if(typeof d!="number"&&d&&!d.da){var C=d.src;if(C&&C[Bt])Ge(C.i,d);else{var E=d.type,v=d.proxy;C.removeEventListener?C.removeEventListener(E,v,d.capture):C.detachEvent?C.detachEvent(cs(E),v):C.addListener&&C.removeListener&&C.removeListener(v),(E=ur(C))?(Ge(E,d),E.h==0&&(E.src=null,C[We]=null)):Re(d)}}}function cs(d){return d in Jt?Jt[d]:Jt[d]="on"+d}function _a(d,C){if(d.da)d=!0;else{C=new Le(C,this);const E=d.listener,v=d.ha||d.src;d.fa&&Ur(d),d=E.call(v,C)}return d}function ur(d){return d=d[We],d instanceof Ae?d:null}var Da="__closure_events_fn_"+(Math.random()*1e9>>>0);function va(d){return typeof d=="function"?d:(d[Da]||(d[Da]=function(C){return d.handleEvent(C)}),d[Da])}function Kt(){w.call(this),this.i=new Ae(this),this.M=this,this.G=null}b(Kt,w),Kt.prototype[Bt]=!0,Kt.prototype.removeEventListener=function(d,C,E,v){Hr(this,d,C,E,v)};function Qt(d,C){var E,v=d.G;if(v)for(E=[];v;v=v.G)E.push(v);if(d=d.M,v=C.type||C,typeof C=="string")C=new O(C,d);else if(C instanceof O)C.target=C.target||d;else{var q=C;C=new O(v,d),xe(C,q)}q=!0;let Z,Ee;if(E)for(Ee=E.length-1;Ee>=0;Ee--)Z=C.g=E[Ee],q=Qs(Z,v,!0,C)&&q;if(Z=C.g=d,q=Qs(Z,v,!0,C)&&q,q=Qs(Z,v,!1,C)&&q,E)for(Ee=0;Ee<E.length;Ee++)Z=C.g=E[Ee],q=Qs(Z,v,!1,C)&&q}Kt.prototype.N=function(){if(Kt.Z.N.call(this),this.i){var d=this.i;for(const C in d.g){const E=d.g[C];for(let v=0;v<E.length;v++)Re(E[v]);delete d.g[C],d.h--}}this.G=null},Kt.prototype.J=function(d,C,E,v){return this.i.add(String(d),C,!1,E,v)},Kt.prototype.K=function(d,C,E,v){return this.i.add(String(d),C,!0,E,v)};function Qs(d,C,E,v){if(C=d.i.g[String(C)],!C)return!0;C=C.concat();let q=!0;for(let Z=0;Z<C.length;++Z){const Ee=C[Z];if(Ee&&!Ee.da&&Ee.capture==E){const Qe=Ee.listener,en=Ee.ha||Ee.src;Ee.fa&&Ge(d.i,Ee),q=Qe.call(en,v)!==!1&&q}}return q&&!v.defaultPrevented}function Ul(d,C){if(typeof d!="function")if(d&&typeof d.handleEvent=="function")d=g(d.handleEvent,d);else throw Error("Invalid listener argument");return Number(C)>2147483647?-1:u.setTimeout(d,C||0)}function Ri(d){d.g=Ul(()=>{d.g=null,d.i&&(d.i=!1,Ri(d))},d.l);const C=d.h;d.h=null,d.m.apply(null,C)}class En extends w{constructor(C,E){super(),this.m=C,this.l=E,this.h=null,this.i=!1,this.g=null}j(C){this.h=arguments,this.g?this.i=!0:Ri(this)}N(){super.N(),this.g&&(u.clearTimeout(this.g),this.g=null,this.i=!1,this.h=null)}}function cr(d){w.call(this),this.h=d,this.g={}}b(cr,w);var wa=[];function Y(d){qe(d.g,function(C,E){this.g.hasOwnProperty(E)&&Ur(C)},d),d.g={}}cr.prototype.N=function(){cr.Z.N.call(this),Y(this)},cr.prototype.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented")};var ze=u.JSON.stringify,Ze=u.JSON.parse,At=class{stringify(d){return u.JSON.stringify(d,void 0)}parse(d){return u.JSON.parse(d,void 0)}};function Ft(){}function Gt(){}var Ot={OPEN:"a",hb:"b",ERROR:"c",tb:"d"};function an(){O.call(this,"d")}b(an,O);function zn(){O.call(this,"c")}b(zn,O);var Ht={},zl=null;function Ta(){return zl=zl||new Kt}Ht.Ia="serverreachability";function ql(d){O.call(this,Ht.Ia,d)}b(ql,O);function Ns(d){const C=Ta();Qt(C,new ql(C))}Ht.STAT_EVENT="statevent";function zr(d,C){O.call(this,Ht.STAT_EVENT,d),this.stat=C}b(zr,O);function Yt(d){const C=Ta();Qt(C,new zr(C,d))}Ht.Ja="timingevent";function _n(d,C){O.call(this,Ht.Ja,d),this.size=C}b(_n,O);function Nn(d,C){if(typeof d!="function")throw Error("Fn must not be null and must be a function");return u.setTimeout(function(){d()},C)}function Ys(){this.g=!0}Ys.prototype.ua=function(){this.g=!1};function qf(d,C,E,v,q,Z){d.info(function(){if(d.g)if(Z){var Ee="",Qe=Z.split("&");for(let mt=0;mt<Qe.length;mt++){var en=Qe[mt].split("=");if(en.length>1){const Ut=en[0];en=en[1];const Os=Ut.split("_");Ee=Os.length>=2&&Os[1]=="type"?Ee+(Ut+"="+en+"&"):Ee+(Ut+"=redacted&")}}}else Ee=null;else Ee=Z;return"XMLHTTP REQ ("+v+") [attempt "+q+"]: "+C+`
711`+E+`
712`+Ee})}function UB(d,C,E,v,q,Z,Ee){d.info(function(){return"XMLHTTP RESP ("+v+") [ attempt "+q+"]: "+C+`
713`+E+`
714`+Z+" "+Ee})}function Br(d,C,E,v){d.info(function(){return"XMLHTTP TEXT ("+C+"): "+Kf(d,E)+(v?" "+v:"")})}function Oi(d,C){d.info(function(){return"TIMEOUT: "+C})}Ys.prototype.info=function(){};function Kf(d,C){if(!d.g)return C;if(!C)return null;try{const Z=JSON.parse(C);if(Z){for(d=0;d<Z.length;d++)if(Array.isArray(Z[d])){var E=Z[d];if(!(E.length<2)){var v=E[1];if(Array.isArray(v)&&!(v.length<1)){var q=v[0];if(q!="noop"&&q!="stop"&&q!="close")for(let Ee=1;Ee<v.length;Ee++)v[Ee]=""}}}}return ze(Z)}catch{return C}}var ki={NO_ERROR:0,cb:1,qb:2,pb:3,kb:4,ob:5,rb:6,Ga:7,TIMEOUT:8,ub:9},Lu={ib:"complete",Fb:"success",ERROR:"error",Ga:"abort",xb:"ready",yb:"readystatechange",TIMEOUT:"timeout",sb:"incrementaldata",wb:"progress",lb:"downloadprogress",Nb:"uploadprogress"},ju;function Li(){}b(Li,Ft),Li.prototype.g=function(){return new XMLHttpRequest},ju=new Li;function qr(d){return encodeURIComponent(String(d))}function zB(d){var C=1;d=d.split(":");const E=[];for(;C>0&&d.length;)E.push(d.shift()),C--;return d.length&&E.push(d.join(":")),E}function Xs(d,C,E,v){this.j=d,this.i=C,this.l=E,this.S=v||1,this.V=new cr(this),this.H=45e3,this.J=null,this.o=!1,this.u=this.B=this.A=this.M=this.F=this.T=this.D=null,this.G=[],this.g=null,this.C=0,this.m=this.v=null,this.X=-1,this.K=!1,this.P=0,this.O=null,this.W=this.L=this.U=this.R=!1,this.h=new $s}function $s(){this.i=null,this.g="",this.h=!1}var ln={},Dn={};function hr(d,C,E){d.M=1,d.A=ji(un(C)),d.u=E,d.R=!0,Kl(d,null)}function Kl(d,C){d.F=Date.now(),dr(d),d.B=un(d.A);var E=d.B,v=d.S;Array.isArray(v)||(v=[String(v)]),Xl(E.i,"t",v),d.C=0,E=d.j.L,d.h=new $s,d.g=ah(d.j,E?C:null,!d.u),d.P>
7140&&(d.O=new En(g(d.Y,d,d.g),d.P)),C=d.V,E=d.g,v=d.ba;var q="readystatechange";Array.isArray(q)||(q&&(wa[0]=q.toString()),q=wa);for(let Z=0;Z<q.length;Z++){const Ee=Tt(E,q[Z],v||C.handleEvent,!1,C.h||C);if(!Ee)break;C.g[Ee.key]=Ee}C=d.J?P(d.J):{},d.u?(d.v||(d.v="POST"),C["Content-Type"]="application/x-www-form-urlencoded",d.g.ea(d.B,d.v,d.u,C)):(d.v="GET",d.g.ea(d.B,d.v,null,C)),Ns(),qf(d.i,d.v,d.B,d.l,d.S,d.u)}Xs.prototype.ba=function(d){d=d.target;const C=this.O;C&&er(d)==3?C.j():this.Y(d)},Xs.prototype.Y=function(d){try{if(d==this.g)e:{const Qe=er(this.g),en=this.g.ya(),mt=this.g.ca();if(!(Qe<3)&&(Qe!=3||this.g&&(this.h.h||this.g.la()||In(this.g)))){this.K||Qe!=4||en==7||(en==8||mt<=0?Ns(3):Ns(2)),fr(this);var C=this.g.ca();this.X=C;var E=Jf(this);if(this.o=C==200,UB(this.i,this.v,this.B,this.l,this.S,Qe,C),this.o){if(this.U&&!this.L){t:{if(this.g){var v,q=this.g;if((v=q.g?q.g.getResponseHeader("X-HTTP-Initial-Response"):null)&&!N(v)){var Z=v;break t}}Z=null}if(d=Z)Br(this.i,this.l,d,"Initial handshake response via X-HTTP-Initial-Response"),this.L=!0,mr(this,d);else{this.o=!1,this.m=3,Yt(12),Bs(this),Is(this);break e}}if(this.R){d=!0;let Ut;for(;!this.K&&this.C<E.length;)if(Ut=KB(this,E),Ut==Dn){Qe==4&&(this.m=4,Yt(14),d=!1),Br(this.i,this.l,null,"[Incomplete Response]");break}else if(Ut==ln){this.m=4,Yt(15),Br(this.i,this.l,E,"[Invalid Chunk]"),d=!1;break}else Br(this.i,this.l,Ut,null),mr(this,Ut);if(qB(this)&&this.C!=0&&(this.h.g=this.h.g.slice(this.C),this.C=0),Qe!=4||E.length!=0||this.h.h||(this.m=1,Yt(16),d=!1),this.o=this.o&&d,!d)Br(this.i,this.l,E,"[Invalid Chunked Response]"),Bs(this),Is(this);else if(E.length>0&&!this.W){this.W=!0;var Ee=this.j;Ee.g==this&&Ee.aa&&!Ee.P&&(Ee.j.info("Great, no buffering proxy detected. Bytes received: "+E.length),$u(Ee),Ee.P=!0,Yt(11))}}else Br(this.i,this.l,E,null),mr(this,E);Qe==4&&Bs(this),this.o&&!this.K&&(Qe==4?th(this.j,this):(this.o=!1,dr(this)))}else Jr(this.g),C==400&&E.indexOf("Unknown SID")>0?(this.m=3,Yt(12)):(this.m=0,Yt(13)),Bs(this),Is(this)}}}catch{}finally{}};function Jf(d){if(!qB(d))return d.g.la();const C=In(d.g);if(C==="")return"";let E="";const v=C.length,q=er(d.g)==4;if(!d.h.i){if(typeof TextDecoder>"u")return Bs(d),Is(d),"";d.h.i=new u.TextDecoder}for(let Z=0;Z<v;Z++)d.h.h=!0,E+=d.h.i.decode(C[Z],{stream:!(q&&Z==v-1)});return C.length=0,d.h.g+=E,d.C=0,d.h.g}function qB(d){return d.g?d.v=="GET"&&d.M!=2&&d.j.Aa:!1}function KB(d,C){var E=d.C,v=C.indexOf(`
715`,E);return v==-1?Dn:(E=Number(C.substring(E,v)),isNaN(E)?ln:(v+=1,v+E>C.length?Dn:(C=C.slice(v,v+E),d.C=v+E,C)))}Xs.prototype.cancel=function(){this.K=!0,Bs(this)};function dr(d){d.T=Date.now()+d.H,Jl(d,d.H)}function Jl(d,C){if(d.D!=null)throw Error("WatchDog timer not null");d.D=Nn(g(d.aa,d),C)}function fr(d){d.D&&(u.clearTimeout(d.D),d.D=null)}Xs.prototype.aa=function(){this.D=null;const d=Date.now();d-this.T>=0?(Oi(this.i,this.B),this.M!=2&&(Ns(),Yt(17)),Bs(this),this.m=2,Is(this)):Jl(this,this.T-d)};function Is(d){d.j.I==0||d.K||th(d.j,d)}function Bs(d){fr(d);var C=d.O;C&&typeof C.dispose=="function"&&C.dispose(),d.O=null,Y(d.V),d.g&&(C=d.g,d.g=null,C.abort(),C.dispose())}function mr(d,C){try{var E=d.j;if(E.I!=0&&(E.g==d||gr(E.h,d))){if(!d.L&&gr(E.h,d)&&E.I==3){try{var v=E.Ba.g.parse(C)}catch{v=null}if(Array.isArray(v)&&v.length==3){var q=v;if(q[0]==0){e:if(!E.v){if(E.g)if(E.g.F+3e3<d.F)to(E),La(E);else break e;Ui(E),Yt(18)}}else E.xa=q[1],0<E.xa-E.K&&q[2]<37500&&E.F&&E.A==0&&!E.C&&(E.C=Nn(g(E.Va,E),6e3));pr(E.h)<=1&&E.ta&&(E.ta=void 0)}else _r(E,11)}else if((d.L||E.g==d)&&to(E),!N(C))for(q=E.Ba.g.parse(C),C=0;C<q.length;C++){let mt=q[C];const Ut=mt[0];if(!(Ut<=E.K))if(E.K=Ut,mt=mt[1],E.I==2)if(mt[0]=="c"){E.M=mt[1],E.ba=mt[2];const Os=mt[3];Os!=null&&(E.ka=Os,E.j.info("VER="+E.ka));const Dr=mt[4];Dr!=null&&(E.za=Dr,E.j.info("SVER="+E.za));const tr=mt[5];tr!=null&&typeof tr=="number"&&tr>0&&(v=1.5*tr,E.O=v,E.j.info("backChannelRequestTimeoutMs_="+v)),v=E;const nr=d.g;if(nr){const zi=nr.g?nr.g.getResponseHeader("X-Client-Wire-Protocol"):null;if(zi){var Z=v.h;Z.g||zi.indexOf("spdy")==-1&&zi.indexOf("quic")==-1&&zi.indexOf("h2")==-1||(Z.j=Z.l,Z.g=new Set,Z.h&&(Vu(Z,Z.h),Z.h=null))}if(v.G){const no=nr.g?nr.g.getResponseHeader("X-HTTP-Session-Id"):null;no&&(v.wa=no,Ct(v.J,v.G,no))}}E.I=3,E.l&&E.l.ra(),E.aa&&(E.T=Date.now()-d.F,E.j.info("Handshake RTT: "+E.T+"ms")),v=E;var Ee=d;if(v.na=rh(v,v.L?v.ba:null,v.W),Ee.L){Fu(v.h,Ee);var Qe=Ee,en=v.O;en&&(Qe.H=en),Qe.D&&(fr(Qe),dr(Qe)),v.g=Ee}else WB(v);E.i.length>0&&Er(E)}else mt[0]!="stop"&&mt[0]!="close"||_r(E,7);else E.I==3&&(mt[0]=="stop"||mt[0]=="close"?mt[0]=="stop"?_r(E,7):Yu(E):mt[0]!="noop"&&E.l&&E.l.qa(mt),E.A=0)}}Ns(4)}catch{}}var on=class{constructor(d,C){this.g=d,this.map=C}};function Mu(d){this.l=d||10,u.PerformanceNavigationTiming?(d=u.performance.getEntriesByType("navigation"),d=d.length>0&&(d[0].nextHopProtocol=="hq"||d[0].nextHopProtocol=="h2")):d=!!(u.chrome&&u.chrome.loadTimes&&u.chrome.loadTimes()&&u.chrome.loadTimes().wasFetchedViaSpdy),this.j=d?this.l:1,this.g=null,this.j>1&&(this.g=new Set),this.h=null,this.i=[]}function Pu(d){return d.h?!0:d.g?d.g.size>=d.j:!1}function pr(d){return d.h?1:d.g?d.g.size:0}function gr(d,C){return d.h?d.h==C:d.g?d.g.has(C):!1}function Vu(d,C){d.g?d.g.add(C):d.h=C}function Fu(d,C){d.h&&d.h==C?d.h=null:d.g&&d.g.has(C)&&d.g.delete(C)}Mu.prototype.cancel=function(){if(this.i=Gu(this),this.h)this.h.cancel(),this.h=null;else if(this.g&&this.g.size!==0){for(const d of this.g.values())d.cancel();this.g.clear()}};function Gu(d){if(d.h!=null)return d.i.concat(d.h.G);if(d.g!=null&&d.g.size!==0){let C=d.i;for(const E of d.g.values())C=C.concat(E.G);return C}return T(d.i)}var JB=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^\\\\/?#]*)@)?([^\\\\/?#]*?)(?::([0-9]+))?(?=[\\\\/?#]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#([\\s\\S]*))?$");function Ql(d,C){if(d){d=d.split("&");for(let E=0;E<d.length;E++){const v=d[E].indexOf("=");let q,Z=null;v>=0?(q=d[E].substring(0,v),Z=d[E].substring(v+1)):q=d[E],C(q,Z?decode
715URIComponent(Z.replace(/\+/g," ")):"")}}}function hs(d){this.g=this.o=this.j="",this.u=null,this.m=this.h="",this.l=!1;let C;d instanceof hs?(this.l=d.l,vn(this,d.j),this.o=d.o,this.g=d.g,Aa(this,d.u),this.h=d.h,Hu(this,$B(d.i)),this.m=d.m):d&&(C=String(d).match(JB))?(this.l=!1,vn(this,C[1]||"",!0),this.o=Cr(C[2]||""),this.g=Cr(C[3]||"",!0),Aa(this,C[4]),this.h=Cr(C[5]||"",!0),Hu(this,C[6]||"",!0),this.m=Cr(C[7]||"")):(this.l=!1,this.i=new Ia(null,this.l))}hs.prototype.toString=function(){const d=[];var C=this.j;C&&d.push(Mi(C,Yl,!0),":");var E=this.g;return(E||C=="file")&&(d.push("//"),(C=this.o)&&d.push(Mi(C,Yl,!0),"@"),d.push(qr(E).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),E=this.u,E!=null&&d.push(":",String(E))),(E=this.h)&&(this.g&&E.charAt(0)!="/"&&d.push("/"),d.push(Mi(E,E.charAt(0)=="/"?Uu:QB,!0))),(E=this.i.toString())&&d.push("?",E),(E=this.m)&&d.push("#",Mi(E,YB)),d.join("")},hs.prototype.resolve=function(d){const C=un(this);let E=!!d.j;E?vn(C,d.j):E=!!d.o,E?C.o=d.o:E=!!d.g,E?C.g=d.g:E=d.u!=null;var v=d.h;if(E)Aa(C,d.u);else if(E=!!d.h){if(v.charAt(0)!="/")if(this.g&&!this.h)v="/"+v;else{var q=C.h.lastIndexOf("/");q!=-1&&(v=C.h.slice(0,q+1)+v)}if(q=v,q==".."||q==".")v="";else if(q.indexOf("./")!=-1||q.indexOf("/.")!=-1){v=q.lastIndexOf("/",0)==0,q=q.split("/");const Z=[];for(let Ee=0;Ee<q.length;){const Qe=q[Ee++];Qe=="."?v&&Ee==q.length&&Z.push(""):Qe==".."?((Z.length>1||Z.length==1&&Z[0]!="")&&Z.pop(),v&&Ee==q.length&&Z.push("")):(Z.push(Qe),v=!0)}v=Z.join("/")}else v=q}return E?C.h=v:E=d.i.toString()!=="",E?Hu(C,$B(d.i)):E=!!d.m,E&&(C.m=d.m),C};function un(d){return new hs(d)}function vn(d,C,E){d.j=E?Cr(C,!0):C,d.j&&(d.j=d.j.replace(/:$/,""))}function Aa(d,C){if(C){if(C=Number(C),isNaN(C)||C<0)throw Error("Bad port number "+C);d.u=C}else d.u=null}function Hu(d,C,E){C instanceof Ia?(d.i=C,$l(d.i,d.l)):(E||(C=Mi(C,Na)),d.i=new Ia(C,d.l))}function Ct(d,C,E){d.i.set(C,E)}function ji(d){return Ct(d,"zx",Math.floor(Math.random()*2147483648).toString(36)+Math.abs(Math.floor(Math.random()*2147483648)^Date.now()).toString(36)),d}function Cr(d,C){return d?C?decodeURI(d.replace(/%25/g,"%2525")):decodeURIComponent(d):""}function Mi(d,C,E){return typeof d=="string"?(d=encodeURI(d).replace(C,$n),E&&(d=d.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),d):null}function $n(d){return d=d.charCodeAt(0),"%"+(d>>4&15).toString(16)+(d&15).toString(16)}var Yl=/[#\/\?@]/g,QB=/[#\?:]/g,Uu=/[#\?]/g,Na=/[#\?@]/g,YB=/#/g;function Ia(d,C){this.h=this.g=null,this.i=d||null,this.j=!!C}function Zn(d){d.g||(d.g=new Map,d.h=0,d.i&&Ql(d.i,function(C,E){d.add(decodeURIComponent(C.replace(/\+/g," ")),E)}))}r=Ia.prototype,r.add=function(d,C){Zn(this),this.i=null,d=Sa(this,d);let E=this.g.get(d);return E||this.g.set(d,E=[]),E.push(C),this.h+=1,this};function XB(d,C){Zn(d),C=Sa(d,C),d.g.has(C)&&(d.i=null,d.h-=d.g.get(C).length,d.g.delete(C))}function zu(d,C){return Zn(d),C=Sa(d,C),d.g.has(C)}r.forEach=function(d,C){Zn(this),this.g.forEach(function(E,v){E.forEach(function(q){d.call(C,q,v,this)},this)},this)};function qu(d,C){Zn(d);let E=[];if(typeof C=="string")zu(d,C)&&(E=E.concat(d.g.get(Sa(d,C))));else for(d=Array.from(d.g.values()),C=0;C<d.length;C++)E=E.concat(d[C]);return E}r.set=function(d,C){return Zn(this),this.i=null,d=Sa(this,d),zu(this,d)&&(this.h-=this.g.get(d).length),this.g.set(d,[C]),this.h+=1,this},r.get=function(d,C){return d?(d=qu(this,d),d.length>0?String(d[0]):C):C};function Xl(d,C,E){XB(d,C),E.length>0&&(d.i=null,d.g.set(Sa(d,C),T(E)),d.h+=E.length)}r.toString=function(){if(this.i)return this.i;if(!this.g)return"";const d=[],C=Array.from(this.g.keys());for(let v=0;v<C.length;v++){var E=C[v];const q=qr(E);E=qu(this,E);for(let Z=0;Z<E.length;Z++){let Ee=q;E[Z]!==""&&(Ee+="="+qr(E[Z])),d.push(Ee)}}return this.i=d.join("&")};function $B(d){const C=new Ia;return C.i=d.i,d.g&&(C.g=new Map(d.g),C.h=d.h),C}function Sa(d,C){return C=String(C),d.j&&(C=C.toLowerCase()),C}function $l(d,C){C&&!d.j&&(Zn(d),d.i=null,d.g.forEach(function(E,v){const q=v.toLowerCase();v!=q&&(XB(this,v),Xl(this,q,E))},d)),d.j=C}function Zs(d,C){const E=new Ys;if(u.Image){const v=new Image;v.onload=y(Ss,E,"TestLoadImage: loaded",!0,C,v),v.onerror=y(Ss,E,"TestLoadImage: error",!1,C,v),v.onabort=y(Ss,E,"TestLoadImage: abort",!1,C,v),v.ontimeout=y(Ss,E,"TestLoadImage: timeout",!1,C,v),u.setTimeout(function(){v.ontimeout&&v.ontimeout()},1e4),v.src=d}else C(!1)}function Ku(d,C){const E=new Ys,v=new AbortController,q=setTimeout(()=>{v.abort(),Ss(E,"TestPingServer: timeout",!1,C)},1e4);fetch(d,{signal:v.signal}).then(Z=>{clearTimeout(q),Z.ok?Ss(E,"TestPingServer: ok",!0,C):Ss(E,"TestPingServer: server error",!1,C)}).catch(()=>{clearTimeout(q),Ss(E,"TestPingServer: error",!1,C)})}function Ss(d,C,E,v,q){try{q&&(q.onload=null,q.onerror=null,q.onabort=null,q.ontimeout=null),v(E)}catch{}}function Ra(){this.g=new At}function yr(d){this.i=d.Sb||null,this.h=d.ab||!1}b(yr,Ft),yr.prototype.g=function(){return new Pi(this.i,this.h)};function Pi(d,C){Kt.call(this),this.H=d,this.o=C,this.m=void 0,this.status=this.readyState=0,this.responseType=this.responseText=this.response=this.statusText="",this.onreadystatechange=null,this.A=new Headers,this.h=null,this.F="GET",this.D="",this.g=!1,this.B=this.j=this.l=null,this.v=new AbortController}b(Pi,Kt),r=Pi.prototype,r.open=function(d,C){if(this.readyState!=0)throw this.abort(),Error("Error reopening a connection");this.F=d,this.D=C,this.readyState=1,Ws(this)},r.send=function(d){if(this.readyState!=1)throw this.abort(),Error("need to call open() first. ");
vendor: 5,809 bytes, lines 715-718
715if(this.v.signal.aborted)throw this.abort(),Error("Request was aborted.");this.g=!0;const C={headers:this.A,method:this.F,credentials:this.m,cache:void 0,signal:this.v.signal};d&&(C.body=d),(this.H||u).fetch(new Request(this.D,C)).then(this.Pa.bind(this),this.ga.bind(this))},r.abort=function(){this.response=this.responseText="",this.A=new Headers,this.status=0,this.v.abort(),this.j&&this.j.cancel("Request was aborted.").catch(()=>{}),this.readyState>=1&&this.g&&this.readyState!=4&&(this.g=!1,Oa(this)),this.readyState=0},r.Pa=function(d){if(this.g&&(this.l=d,this.h||(this.status=this.l.status,this.statusText=this.l.statusText,this.h=d.headers,this.readyState=2,Ws(this)),this.g&&(this.readyState=3,Ws(this),this.g)))if(this.responseType==="arraybuffer")d.arrayBuffer().then(this.Na.bind(this),this.ga.bind(this));else if(typeof u.ReadableStream<"u"&&"body"in d){if(this.j=d.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.B=new TextDecoder;Zl(this)}else d.text().then(this.Oa.bind(this),this.ga.bind(this))};function Zl(d){d.j.read().then(d.Ma.bind(d)).catch(d.ga.bind(d))}r.Ma=function(d){if(this.g){if(this.o&&d.value)this.response.push(d.value);else if(!this.o){var C=d.value?d.value:new Uint8Array(0);(C=this.B.decode(C,{stream:!d.done}))&&(this.response=this.responseText+=C)}d.done?Oa(this):Ws(this),this.readyState==3&&Zl(this)}},r.Oa=function(d){this.g&&(this.response=this.responseText=d,Oa(this))},r.Na=function(d){this.g&&(this.response=d,Oa(this))},r.ga=function(){this.g&&Oa(this)};function Oa(d){d.readyState=4,d.l=null,d.j=null,d.B=null,Ws(d)}r.setRequestHeader=function(d,C){this.A.append(d,C)},r.getResponseHeader=function(d){return this.h&&this.h.get(d.toLowerCase())||""},r.getAllResponseHeaders=function(){if(!this.h)return"";const d=[],C=this.h.entries();for(var E=C.next();!E.done;)E=E.value,d.push(E[0]+": "+E[1]),E=C.next();return d.join(`\r
716`)};function Ws(d){d.onreadystatechange&&d.onreadystatechange.call(d)}Object.defineProperty(Pi.prototype,"withCredentials",{get:function(){return this.m==="include"},set:function(d){this.m=d?"include":"same-origin"}});function Rs(d){let C="";return qe(d,function(E,v){C+=v,C+=":",C+=E,C+=`\r
717`}),C}function Vi(d,C,E){e:{for(v in E){var v=!1;break e}v=!0}v||(E=Rs(E),typeof d=="string"?E!=null&&qr(E):Ct(d,C,E))}function Et(d){Kt.call(this),this.headers=new Map,this.L=d||null,this.h=!1,this.g=null,this.D="",this.o=0,this.l="",this.j=this.B=this.v=this.A=!1,this.m=null,this.F="",this.H=!1}b(Et,Kt);var br=/^https?$/i,Ju=["POST","PUT"];r=Et.prototype,r.Fa=function(d){this.H=d},r.ea=function(d,C,E,v){if(this.g)throw Error("[goog.net.XhrIo] Object is active with another request="+this.D+"; newUri="+d);C=C?C.toUpperCase():"GET",this.D=d,this.l="",this.o=0,this.A=!1,this.h=!0,this.g=this.L?this.L.g():ju.g(),this.g.onreadystatechange=D(g(this.Ca,this));try{this.B=!0,this.g.open(C,String(d),!0),this.B=!1}catch(Z){Fi(this,Z);return}if(d=E||"",E=new Map(this.headers),v)if(Object.getPrototypeOf(v)===Object.prototype)for(var q in v)E.set(q,v[q]);else if(typeof v.keys=="function"&&typeof v.get=="function")for(const Z of v.keys())E.set(Z,v.get(Z));else throw Error("Unknown input type for opt_headers: "+String(v));v=Array.from(E.keys()).find(Z=>Z.toLowerCase()=="content-type"),q=u.FormData&&d instanceof u.FormData,!(Array.prototype.indexOf.call(Ju,C,void 0)>=0)||v||q||E.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");for(const[Z,Ee]of E)this.g.setRequestHeader(Z,Ee);this.F&&(this.g.responseType=this.F),"withCredentials"in this.g&&this.g.withCredentials!==this.H&&(this.g.withCredentials=this.H);try{this.m&&(clearTimeout(this.m),this.m=null),this.v=!0,this.g.send(d),this.v=!1}catch(Z){Fi(this,Z)}};function Fi(d,C){d.h=!1,d.g&&(d.j=!0,d.g.abort(),d.j=!1),d.l=C,d.o=5,Qu(d),Kr(d)}function Qu(d){d.A||(d.A=!0,Qt(d,"complete"),Qt(d,"error"))}r.abort=function(d){this.g&&this.h&&(this.h=!1,this.j=!0,this.g.abort(),this.j=!1,this.o=d||7,Qt(this,"complete"),Qt(this,"abort"),Kr(this))},r.N=function(){this.g&&(this.h&&(this.h=!1,this.j=!0,this.g.abort(),this.j=!1),Kr(this,!0)),Et.Z.N.call(this)},r.Ca=function(){this.u||(this.B||this.v||this.j?Gi(this):this.Xa())},r.Xa=function(){Gi(this)};function Gi(d){if(d.h&&typeof o<"u"){if(d.v&&er(d)==4)setTimeout(d.Ca.bind(d),0);else if(Qt(d,"readystatechange"),er(d)==4){d.h=!1;try{const Z=d.ca();e:switch(Z){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:var C=!0;break e;default:C=!1}var E;if(!(E=C)){var v;if(v=Z===0){let Ee=String(d.D).match(JB)[1]||null;!Ee&&u.self&&u.self.location&&(Ee=u.self.location.protocol.slice(0,-1)),v=!br.test(Ee?Ee.toLowerCase():"")}E=v}if(E)Qt(d,"complete"),Qt(d,"success");else{d.o=6;try{var q=er(d)>2?d.g.statusText:""}catch{q=""}d.l=q+" ["+d.ca()+"]",Qu(d)}}finally{Kr(d)}}}}function Kr(d,C){if(d.g){d.m&&(clearTimeout(d.m),d.m=null);const E=d.g;d.g=null,C||Qt(d,"ready");try{E.onreadystatechange=null}catch{}}}r.isActive=function(){return!!this.g};function er(d){return d.g?d.g.readyState:0}r.ca=function(){try{return er(this)>2?this.g.status:-1}catch{return-1}},r.la=function(){try{return this.g?this.g.responseText:""}catch{return""}},r.La=function(d){if(this.g){var C=this.g.responseText;return d&&C.indexOf(d)==0&&(C=C.substring(d.length)),Ze(C)}};function In(d){try{if(!d.g)return null;if("response"in d.g)return d.g.response;switch(d.F){case"":case"text":return d.g.responseText;case"arraybuffer":if("mozResponseArrayBuffer"in d.g)return d.g.mozResponseArrayBuffer}return null}catch{return null}}function Jr(d){const C={};d=(d.g&&er(d)>=2&&d.g.getAllResponseHeaders()||"").split(`\r
718`);for(let v=0;v<d.length;v++){if(N(d[v]))continue;var E=zB(d[v]);const q=E[0];
vendor: 4,218 bytes, line 718
718if(E=E[1],typeof E!="string")continue;E=E.trim();const Z=C[q]||[];C[q]=Z,Z.push(E)}Ie(C,function(v){return v.join(", ")})}r.ya=function(){return this.o},r.Ha=function(){return typeof this.l=="string"?this.l:String(this.l)};function xr(d,C,E){return E&&E.internalChannelParams&&E.internalChannelParams[d]||C}function ka(d){this.za=0,this.i=[],this.j=new Ys,this.ba=this.na=this.J=this.W=this.g=this.wa=this.G=this.H=this.u=this.U=this.o=null,this.Ya=this.V=0,this.Sa=xr("failFast",!1,d),this.F=this.C=this.v=this.m=this.l=null,this.X=!0,this.xa=this.K=-1,this.Y=this.A=this.D=0,this.Qa=xr("baseRetryDelayMs",5e3,d),this.Za=xr("retryDelaySeedMs",1e4,d),this.Ta=xr("forwardChannelMaxRetries",2,d),this.va=xr("forwardChannelRequestTimeoutMs",2e4,d),this.ma=d&&d.xmlHttpFactory||void 0,this.Ua=d&&d.Rb||void 0,this.Aa=d&&d.useFetchStreams||!1,this.O=void 0,this.L=d&&d.supportsCrossDomainXhr||!1,this.M="",this.h=new Mu(d&&d.concurrentRequestLimit),this.Ba=new Ra,this.S=d&&d.fastHandshake||!1,this.R=d&&d.encodeInitMessageHeaders||!1,this.S&&this.R&&(this.R=!1),this.Ra=d&&d.Pb||!1,d&&d.ua&&this.j.ua(),d&&d.forceLongPolling&&(this.X=!1),this.aa=!this.S&&this.X&&d&&d.detectBufferingProxy||!1,this.ia=void 0,d&&d.longPollingTimeout&&d.longPollingTimeout>0&&(this.ia=d.longPollingTimeout),this.ta=void 0,this.T=0,this.P=!1,this.ja=this.B=null}r=ka.prototype,r.ka=8,r.I=1,r.connect=function(d,C,E,v){Yt(0),this.W=d,this.H=C||{},E&&v!==void 0&&(this.H.OSID=E,this.H.OAID=v),this.F=this.X,this.J=rh(this,null,this.W),Er(this)};function Yu(d){if(Wl(d),d.I==3){var C=d.V++,E=un(d.J);if(Ct(E,"SID",d.M),Ct(E,"RID",C),Ct(E,"TYPE","terminate"),Hi(d,E),C=new Xs(d,d.j,C),C.M=2,C.A=ji(un(E)),E=!1,u.navigator&&u.navigator.sendBeacon)try{E=u.navigator.sendBeacon(C.A.toString(),"")}catch{}!E&&u.Image&&(new Image().src=C.A,E=!0),E||(C.g=ah(C.j,null),C.g.ea(C.A)),C.F=Date.now(),dr(C)}sh(d)}function La(d){d.g&&($u(d),d.g.cancel(),d.g=null)}function Wl(d){La(d),d.v&&(u.clearTimeout(d.v),d.v=null),to(d),d.h.cancel(),d.m&&(typeof d.m=="number"&&u.clearTimeout(d.m),d.m=null)}function Er(d){if(!Pu(d.h)&&!d.m){d.m=!0;var C=d.Ea;_e||A(),ye||(_e(),ye=!0),S.add(C,d),d.D=0}}function eo(d,C){return pr(d.h)>=d.h.j-(d.m?1:0)?!1:d.m?(d.i=C.G.concat(d.i),!0):d.I==1||d.I==2||d.D>=(d.Sa?0:d.Ta)?!1:(d.m=Nn(g(d.Ea,d,C),nh(d,d.D)),d.D++,!0)}r.Ea=function(d){if(this.m)if(this.m=null,this.I==1){if(!d){this.V=Math.floor(Math.random()*1e5),d=this.V++;const q=new Xs(this,this.j,d);let Z=this.o;if(this.U&&(Z?(Z=P(Z),xe(Z,this.U)):Z=this.U),this.u!==null||this.R||(q.J=Z,Z=null),this.S)e:{for(var C=0,E=0;E<this.i.length;E++){t:{var v=this.i[E];if("__data__"in v.map&&(v=v.map.__data__,typeof v=="string")){v=v.length;break t}v=void 0}if(v===void 0)break;if(C+=v,C>4096){C=E;break e}if(C===4096||E===this.i.length-1){C=E+1;break e}}C=1e3}else C=1e3;C=ZB(this,q,C),E=un(this.J),Ct(E,"RID",d),Ct(E,"CVER",22),this.G&&Ct(E,"X-HTTP-Session-Id",this.G),Hi(this,E),Z&&(this.R?C="headers="+qr(Rs(Z))+"&"+C:this.u&&Vi(E,this.u,Z)),Vu(this.h,q),this.Ra&&Ct(E,"TYPE","init"),this.S?(Ct(E,"$req",C),Ct(E,"SID","null"),q.U=!0,hr(q,E,null)):hr(q,E,C),this.I=2}}else this.I==3&&(d?Xu(this,d):this.i.length==0||Pu(this.h)||Xu(this))};function Xu(d,C){var E;C?E=C.l:E=d.V++;const v=un(d.J);Ct(v,"SID",d.M),Ct(v,"RID",E),Ct(v,"AID",d.K),Hi(d,v),d.u&&d.o&&Vi(v,d.u,d.o),E=new Xs(d,d.j,E,d.D+1),d.u===null&&(E.J=d.o),C&&(d.i=C.G.concat(d.i)),C=ZB(d,E,1e3),E.H=Math.round(d.va*.5)+Math.round(d.va*.5*Math.random()),Vu(d.h,E),hr(E,v,C)}function Hi(d,C){d.H&&qe(d.H,function(E,v){Ct(C,v,E)}),d.l&&qe({},function(E,v){Ct(C,v,E)})}function ZB(d,C,E){E=Math.min(d.i.length,E);const v=d.l?g(d.l.Ka,d.l,d):null;e:{var q=d.i;let Qe=-1;for(;;){const en=["count="+E];Qe==-1?E>0?(Qe=q[0].g,en.push("ofs="+Qe)):Qe=0:en.push("ofs="+Qe);let mt=!0;for(let Ut=0;Ut<E;Ut++){var Z=q[Ut].g;const Os=q[Ut].map;if(Z-=Qe,Z<0)Qe=Math.max(0,q[Ut].g-100),mt=!1;else try{Z="req"+Z+"_"||"";try{var Ee=Os instanceof Map?Os:Object.entries(Os);for(const[Dr,tr]of Ee){let nr=tr;B(tr)&&(nr=ze(tr)),en.push(Z+Dr+"="+encodeURIComponent(nr))}}catch(Dr){throw en.push(Z+"type="+encodeURIComponent("_badmap")),Dr}}catch{v&&v(Os)}}if(mt){Ee=en.join("&");break e}}Ee=void 0}return d=d.i.splice(0,E),C.G=d,Ee}
vendor: 4,253 bytes, line 718
718function WB(d){if(!d.g&&!d.v){d.Y=1;var C=d.Da;_e||A(),ye||(_e(),ye=!0),S.add(C,d),d.A=0}}function Ui(d){return d.g||d.v||d.A>=3?!1:(d.Y++,d.v=Nn(g(d.Da,d),nh(d,d.A)),d.A++,!0)}r.Da=function(){if(this.v=null,eh(this),this.aa&&!(this.P||this.g==null||this.T<=0)){var d=4*this.T;this.j.info("BP detection timer enabled: "+d),this.B=Nn(g(this.Wa,this),d)}},r.Wa=function(){this.B&&(this.B=null,this.j.info("BP detection timeout reached."),this.j.info("Buffering proxy detected and switch to long-polling!"),this.F=!1,this.P=!0,Yt(10),La(this),eh(this))};function $u(d){d.B!=null&&(u.clearTimeout(d.B),d.B=null)}function eh(d){d.g=new Xs(d,d.j,"rpc",d.Y),d.u===null&&(d.g.J=d.o),d.g.P=0;var C=un(d.na);Ct(C,"RID","rpc"),Ct(C,"SID",d.M),Ct(C,"AID",d.K),Ct(C,"CI",d.F?"0":"1"),!d.F&&d.ia&&Ct(C,"TO",d.ia),Ct(C,"TYPE","xmlhttp"),Hi(d,C),d.u&&d.o&&Vi(C,d.u,d.o),d.O&&(d.g.H=d.O);var E=d.g;d=d.ba,E.M=1,E.A=ji(un(C)),E.u=null,E.R=!0,Kl(E,d)}r.Va=function(){this.C!=null&&(this.C=null,La(this),Ui(this),Yt(19))};function to(d){d.C!=null&&(u.clearTimeout(d.C),d.C=null)}function th(d,C){var E=null;if(d.g==C){to(d),$u(d),d.g=null;var v=2}else if(gr(d.h,C))E=C.G,Fu(d.h,C),v=1;else return;if(d.I!=0){if(C.o)if(v==1){E=C.u?C.u.length:0,C=Date.now()-C.F;var q=d.D;v=Ta(),Qt(v,new _n(v,E)),Er(d)}else WB(d);else if(q=C.m,q==3||q==0&&C.X>0||!(v==1&&eo(d,C)||v==2&&Ui(d)))switch(E&&E.length>0&&(C=d.h,C.i=C.i.concat(E)),q){case 1:_r(d,5);break;case 4:_r(d,10);break;case 3:_r(d,6);break;default:_r(d,2)}}}function nh(d,C){let E=d.Qa+Math.floor(Math.random()*d.Za);return d.isActive()||(E*=2),E*C}function _r(d,C){if(d.j.info("Error code "+C),C==2){var E=g(d.bb,d),v=d.Ua;const q=!v;v=new hs(v||"//www.google.com/images/cleardot.gif"),u.location&&u.location.protocol=="http"||vn(v,"https"),ji(v),q?Zs(v.toString(),E):Ku(v.toString(),E)}else Yt(2);d.I=0,d.l&&d.l.pa(C),sh(d),Wl(d)}r.bb=function(d){d?(this.j.info("Successfully pinged google.com"),Yt(2)):(this.j.info("Failed to ping google.com"),Yt(1))};function sh(d){if(d.I=0,d.ja=[],d.l){const C=Gu(d.h);(C.length!=0||d.i.length!=0)&&(M(d.ja,C),M(d.ja,d.i),d.h.i.length=0,T(d.i),d.i.length=0),d.l.oa()}}function rh(d,C,E){var v=E instanceof hs?un(E):new hs(E);if(v.g!="")C&&(v.g=C+"."+v.g),Aa(v,v.u);else{var q=u.location;v=q.protocol,C=C?C+"."+q.hostname:q.hostname,q=+q.port;const Z=new hs(null);v&&vn(Z,v),C&&(Z.g=C),q&&Aa(Z,q),E&&(Z.h=E),v=Z}return E=d.G,C=d.wa,E&&C&&Ct(v,E,C),Ct(v,"VER",d.ka),Hi(d,v),v}function ah(d,C,E){if(C&&!d.L)throw Error("Can't create secondary domain capable XhrIo object.");return C=d.Aa&&!d.ma?new Et(new yr({ab:E})):new Et(d.ma),C.Fa(d.L),C}r.isActive=function(){return!!this.l&&this.l.isActive(this)};function ih(){}r=ih.prototype,r.ra=function(){},r.qa=function(){},r.pa=function(){},r.oa=function(){},r.isActive=function(){return!0},r.Ka=function(){};function ja(){}ja.prototype.g=function(d,C){return new qn(d,C)};function qn(d,C){Kt.call(this),this.g=new ka(C),this.l=d,this.h=C&&C.messageUrlParams||null,d=C&&C.messageHeaders||null,C&&C.clientProtocolHeaderRequired&&(d?d["X-Client-Protocol"]="webchannel":d={"X-Client-Protocol":"webchannel"}),this.g.o=d,d=C&&C.initMessageHeaders||null,C&&C.messageContentType&&(d?d["X-WebChannel-Content-Type"]=C.messageContentType:d={"X-WebChannel-Content-Type":C.messageContentType}),C&&C.sa&&(d?d["X-WebChannel-Client-Profile"]=C.sa:d={"X-WebChannel-Client-Profile":C.sa}),this.g.U=d,(d=C&&C.Qb)&&!N(d)&&(this.g.u=d),this.A=C&&C.supportsCrossDomainXhr||!1,this.v=C&&C.sendRawJson||!1,(C=C&&C.httpSessionIdParam)&&!N(C)&&(this.g.G=C,d=this.h,d!==null&&C in d&&(d=this.h,C in d&&delete d[C])),this.j=new Qr(this)}b(qn,Kt),qn.prototype.m=function(){this.g.l=this.j,this.A&&(this.g.L=!0),this.g.connect(this.l,this.h||void 0)},qn.prototype.close=function(){Yu(this.g)},qn.prototype.o=function(d){var C=this.g;if(typeof d=="string"){var E={};E.__data__=d,d=E}else this.v&&(E={},E.__data__=ze(d),d=E);C.i.push(new on(C.Ya++,d)),C.I==3&&Er(C)},qn.prototype.N=function(){this.g.l=null,delete this.j,Yu(this.g),delete this.g,qn.Z.N.call(this)};function lh(d){an.call(this),d.__headers__&&(this.headers=d.__headers__,this.statusCode=d.__status__,delete d.__headers__,delete d.__status__);var C=d.__sm__;if(C){e:{for(const E in C){d=E;break e}d=void 0}
718(this.i=d)&&(d=this.i,C=C!==null&&d in C?C[d]:void 0),this.data=C}else this.data=d}b(lh,an);function oh(){zn.call(this),this.status=1}b(oh,zn);function Qr(d){this.g=d}b(Qr,ih),Qr.prototype.ra=function(){Qt(this.g,"a")},Qr.prototype.qa=function(d){Qt(this.g,new lh(d))},Qr.prototype.pa=function(d){Qt(this.g,new oh)},Qr.prototype.oa=function(){Qt(this.g,"b")},ja.prototype.createWebChannel=ja.prototype.g,qn.prototype.send=qn.prototype.o,qn.prototype.open=qn.prototype.m,qn.prototype.close=qn.prototype.close,N1=function(){return new ja},A1=function(){return Ta()},T1=Ht,Eg={jb:0,mb:1,nb:2,Hb:3,Mb:4,Jb:5,Kb:6,Ib:7,Gb:8,Lb:9,PROXY:10,NOPROXY:11,Eb:12,Ab:13,Bb:14,zb:15,Cb:16,Db:17,fb:18,eb:19,gb:20},ki.NO_ERROR=0,ki.TIMEOUT=8,ki.HTTP_ERROR=6,Nd=ki,Lu.COMPLETE="complete",w1=Lu,Gt.EventType=Ot,Ot.OPEN="a",Ot.CLOSE="b",Ot.ERROR="c",Ot.MESSAGE="d",Kt.prototype.listen=Kt.prototype.J,Uc=Gt,Et.prototype.listenOnce=Et.prototype.K,Et.prototype.getLastError=Et.prototype.Ha,Et.prototype.getLastErrorCode=Et.prototype.ya,Et.prototype.getStatus=Et.prototype.ca,Et.prototype.getResponseJson=Et.prototype.La,Et.prototype.getResponseText=Et.prototype.la,Et.prototype.send=Et.prototype.ea,Et.prototype.setWithCredentials=Et.prototype.Fa,v1=Et}).apply(typeof hd<"u"?hd:typeof self<"u"?self:typeof window<"u"?window:{});/*!
719* re2js
720* RE2JS is the JavaScript port of RE2, a regular expression engine that provides linear time matching
721*
722* @version v2.8.6
723* @author Oleksii Vasyliev
724* @homepage https://github.com/le0pard/re2js#readme
725* @repository github:le0pard/re2js
726* @license MIT
727*/var It,ue=(It=class{},me(It,"FOLD_CASE",1),me(It,"LITERAL",2),me(It,"CLASS_NL",4),me(It,"DOT_NL",8),me(It,"ONE_LINE",16),me(It,"NON_GREEDY",32),me(It,"PERL_X",64),me(It,"UNICODE_GROUPS",128),me(It,"WAS_DOLLAR",256),me(It,"LOOKBEHIND",512),me(It,"MATCH_NL",It.CLASS_NL|It.DOT_NL),me(It,"PERL",It.CLASS_NL|It.ONE_LINE|It.PERL_X|It.UNICODE_GROUPS),me(It,"POSIX",0),me(It,"UNANCHORED",0),me(It,"ANCHOR_START",1),me(It,"ANCHOR_BOTH",2),It);const Oo={CASE_INSENSITIVE:1,DOTALL:2,MULTILINE:4,DISABLE_UNICODE_GROUPS:8,LONGEST_MATCH:16,LOOKBEHINDS:512},uB=128,_g=new Int32Array(uB),Dg=new Int32Array(uB),dd=65535;for(let r=0;r<uB;r++)r>=97&&r<=122?_g[r]=r-32:_g[r]=r,r>=65&&r<=90?Dg[r]=r+32:Dg[r]=r;var fg,te=(fg=class{static toUpperCase(r){if(r<uB)return _g[r];const e=String.fromCodePoint(r).toUpperCase(),t=e.codePointAt(0)>dd?2:1;if(e.length>t)return r;const n=String.fromCodePoint(e.codePointAt(0)).toLowerCase(),i=n.codePointAt(0)>dd?2:1;return n.length>i||n.codePointAt(0)!==r?r:e.codePointAt(0)}static toLowerCase(r){if(r<uB)return Dg[r];const e=String.fromCodePoint(r).toLowerCase(),t=e.codePointAt(0)>dd?2:1;if(e.length>t)return r;const n=String.fromCodePoint(e.codePointAt(0)).toUpperCase(),i=n.codePointAt(0)>dd?2:1;return n.length>i||n.codePointAt(0)!==r?r:e.codePointAt(0)}},me(fg,"CODES",new Map([["\x07",7],["\b",8],["	",9],[`
728`,10],["\v",11],["\f",12],["\r",13],[" ",32],['"',34],["$",36],["&",38],["'",39],["(",40],[")",41],["*",42],["+",43],["-",45],[".",46],["0",48],["1",49],["2",50],["3",51],["4",52],["5",53],["6",54],["7",55],["8",56],["9",57],[":",58],["<",60],[">",62],["?",63],["A",65],["B",66],["C",67],["F",70],["P",80],["Q",81],["U",85],["Z",90],["[",91],["\\",92],["]",93],["^",94],["_",95],["`",96],["a",97],["b",98],["f",102],["i",105],["m",109],["n",110],["r",114],["s",115],["t",116],["v",118],["x",120],["z",122],["{",123],["|",124],["}",125]])),fg),I=class{constructor(r,e=!1){this.data=r,this.isStride1=e,this.SIZE=e?2:3}getLo(r){return this.data[r*this.SIZE]}getHi(r){return this.data[r*this.SIZE+1]}getStride(r){return this.isStride1?1:this.data[r*this.SIZE+2]}get length(){return this.data.length/this.SIZE}};const I1=new Uint8Array(256);for(let r=0,e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-";r<64;r++)I1[e.charCodeAt(r)]=r;const S1=r=>{const e=[];let t=0,n=0;for(let i=0;i<r.length;i++){let o=I1[r.charCodeAt(i)];t|=(o&31)<<n,(o&32)===0?(e.push(t),t=0,n=0):n+=5}return e},R=(r,e)=>{const t=S1(r),n=e?t.length/2:t.length/3,i=new Uint32Array(n*3);let o=0,u=0;for(let B=0;B<n;B++)o+=t[u++],i[B*3]=o,o+=t[u++],i[B*3+1]=o,i[B*3+2]=e?1:t[u++];return i},nI=r=>{const e=S1(r),t=new Map;let n=0;for(let i=0;i<e.length;i+=2){n+=e[i];const o=e[i+1],u=o>>>1^-(o&1);t.set(n,n+u)}return t};var fd=class{constructor(r){this.initializer=r,this.cache=new Map}has(r){return r in this.initializer}get(r){if(this.cache.has(r))return this.cache.get(r);const e=this.initializer[r],t=e?e():null;return this.cache.set(r,t),t}},ci,as=(ci=class{static get CASE_ORBIT(){return this._CASE_ORBIT||(this._CASE_ORBIT=nI("rCgCIgCY+rQI4QiCuuBLgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCCgCBgCBgCBgCBgCBgCBgCB+7OB-BB-BB-BB-BB-BBskQB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BC-BB-BB-BB-BB-BB-BB-BByHBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBDCBBBCBBBCBBCCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBCCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBxHBCBBBCBBBCBBB3SBmMBkNBCBBBCBBB8MBCBBB6MB6MBCBBC+EB0MB2MBCBBB6MB+MBiGBmNBiNBCBBBmKBikzCBmNBqNBkIBsNBCBBBCBBBCBBB0NBCBBB0NDCBBB0NBCBBByNByNBCBBBCBBB2NBCBBDCBBCwDFCBCBDBCBCBDBCBCBDBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBB9EBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBCCBCBDBCBBBhGBvDBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBjICCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBH2iVBCBBBlKBwiVB+jVB+jVBCBBBlMBqEBuEBCBBBCBBBCBBBCBBBCBBB+hVB4hVB8hVBjNB7MC5MB5MCzMC1MB+0yCE5MB20yCC9MBu2yCBwyyCBo0yCChNBlNBo0yCBu-UBi0yCDlNC6-UBpNDrNIu+UDzNCm0yCBzNE0yyCBzNBpEBxNBxNBtEG1NLqxyCBkxyCnFoFrBCBBBCBBDCBBEkIBkIBkICoHHsCCqCBqCBqCCgEC+DB+DBmkOBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCC+BBgCBgCBgCBgCBgCBgCBgCBgCBrCBpCBpCBpCBmjOB-BB8BB-B
728B-BBgEB-BB-BByBBqgOBsDB-BBtwBB-BB-BB-BBsBBgDBCB-BB-BB-BBeB-BB-BB61OB-BB-BB-DB9DB9DBQB7DBmCE9CBrDBPBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBrFB-EBOBnHB3FB-FCCBBBNBCBBCjIBjIBjIBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgFBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCB-BB-BB8kMB-BB6kMB-BB-BB-BB-BB-BB-BB-BB-BB-BBokMB-BB-BBkkMBkkMB-BB-BB-BB-BB-BB-BB-BB4jMB-BB-BB-BB-BB-BB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EB-EBCBBBCBoiMBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBJCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBeBCBBBCBBBCBBBCBBBCBBBCBBBCBBBdBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBCgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDL-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-C64CgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOBgmOCgmOGgmODg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FBg8FDg8FBg8FBg8FhVg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBg9rCBQBQBQBQBQBQDPBPBPBPBPBPjkC7mMB5mMBnmMBjmMBCBlmMB3lMBpiMBk8kCBCBBG-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FB-7FD-7FB-7FB-7F6FoglCEsuHRwjlCyDCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCB0DBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBG1DD97OCCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQBQBQBQBQDPBPBPBPBPBPDQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQBQBQBQBQDPBPBPBPBPBPEQCQCQCQCPCPCPCPBQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPB0EB0EBsFBsFBsFBsFBoGBoGBgIBgIBgHBgHB8HB8HDQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQBQBQBQBQBQBQBPBPBPBPBPBPBPBPBQBQCSFPBPBzEBzEBRCxnOFSFrFBrFBrFBrFBREQBQClkOFPBPBnGBnGFQBQCljOCODPBPB-GB-GBNHSF-HB-HB7HB7HBRqJ53OE9tQBrmQH4Bc3BSgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBgBBfBfBfBfBfBfBfBfBfBfBfBfBfBfBfBfECBByZ0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BB0BBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzBBzB34BgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDBgDB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CB-CBCBBBt-UBruHBt+UB1iVBviVBCBBBCBBBCBBB3hVB5-UB9hVB7hVCCBBCCBBI9jVB9jVBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBICBBBCBBECBBN-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOB-lOC-lOG-lOzoeCBBBCBBBCBBBCBBBCBBBCBl8kCBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBTC
728BBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBnECBBBCBBBCBBBCBBBCBBBCBBBCBBDCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBKCBBBCBBBnglCBCBBBCBBBCBBBCBBBCBBECBBBvyyCDCBBBCBBBgDCCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBn0yCB90yCB10yCBh0yCBn0yCCjxyCBzyyCBpxyCBg6BBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBB-CBl0yCBvjlCBCBBBCBBBt2yCBCBBBCBBBCBBBCBBBCBBBCBBBCBBBCBBBhkzCZCBB9a-5Bd-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCB-8rCm6TCBB7gBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCH-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BmlBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvChDwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCBwCFvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvCBvC1DuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCCuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCBuCCuCBuCBuCBuCBuCBuCBuCCuCBuCCtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCCtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCBtCCtCBtCBtCBtCBtCBtCBtCCtCBtCk2BgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEBgEO-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-DB-D+CgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCL-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-B74CgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BhrVgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCBgCB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BB-BhB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BB2BD1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BB1BtxekCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBkCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjCBjC")),this._CASE_ORBIT}static get Print(){return this._Print||(this._Print=new I(R("hB9CBjBLBCpWBDFBFGBCCCBSBCsMBClBBDxBBDCBC2BBJaBFFBSVBC-FBCvBBD6BBDkDBP6BBDwBBDOBCbBDCCBJBGfBIqCBCgFBCHBDBBDVBCGBCEEBCBDIBDBBDDBJFFBCCBDBDYBDCBCFBFBBDVBCGBCBBCBBCBBDCCBDBFBBDCBEIIBCBCIIBPBLCBCIBCCBCVBCGBCBBCEBDJBCCBCCBDQQBCBDLBIGBCCBCHBDBBDVBCGBCBBCEBDIBDBBDCBICBFBBCEBDRBLBBCFBECBCDBEBBCCCBEEBEEBBBELBFEBECBCDBDHHPUBGMBCCBCWBCPBDIBCCBCDBIBBCCBCBBDDBDJBIVBCCBCWBCJBCEBDIBCCBCDBIBBGCBCDBDJBCCBNMBCCBCyBBCCBCFBFPBDZBCCBCRBEXBCIBCDDBFBEFFBEBCCCBGBHJBDCBN5BBFcBmBBBCCCBDBCXBCCCBVBDEBCCCBFBCJBDDBhBnCBCjBBFmBBCjBBCOBCMBmBlGBCGGD4LBCDBDGBCCCBCBDoBBCDBDgBBCDBDGBCCCBCBDOBC4BBCDBDiCBDfBEZBH1CBDFBD-TBCbBE4CBIVBKXBKTBNMBCCBCBBN9CBDJBHJBHNBCKBH4CBIqBBGlCBLeBCLBFLBFEEBoBBDEBMrBBFZBHKBE9BBDgCBCcBDKBHJBHNBDtBBDLBVsCBClFBJ7BBEOBE9BBGqBBDKBJqBBG1QBDFBDlBBDFBDHBCGCBdBD0BBCOBCNBDFBCSBDCBCIBSXBJuBBSBBDaBCMBEhBBPgBBQrEBF5UBXKBWz4BBD9LBGsBBCGGD3BBIBBPXBKGBCGBCGBCGBCGBCGBCGBCGBC9DBjBZBC4CBN1GBbPBC+BBC1CBDmDBGqBBC9CBC1CBKvBBCszcBE2BBK7KBV3FBJ8GBV7BBEJBH3BBJlCBJLBHzDBMdBEtCBCKBFgBBC2BBKNBDJBDmDBZbBLFBDFBDFBKGBCGBC7BBF9DBDJBHj9KBNWBFwBBloItLBDpDBnBGBNEBGZBCEBCCCBCCBCCBoUBhBpBBHyBBCSBCDBFEBCmEBF9FBEFBDFBDFBDCBEGBCGBOBBDLBCZBCSBCBBCOBDNBjB6DBGCBFsBBE3CBCMBEwBwBBsBBjEcBEwBBQbBFjBBKdBGqBBGdBCkBBFNBrB9EBDJBHjB
728BFjBBFnBBJzBBMLBCOBCGBCBBCKBCOBCGBCBBEzBBN2JBKVBLHBZFBCpBBCIBmCFBDCCBqBBCBBEDDBVBCnCBJIBxBSBCBBGgBBEaBGaBnB3BBFTBDxBBCBBGHBCCBCcBDCBFJBIIBI-BBhBmBBFLBK1BBEcBDaBGZBIDBNGBxCoCB4ByBBOyBBItBBJJBHlBBEcBJBBxGeBCpBBCCBDBBRFBJIBiBtBBJpBBXZBnBbBVWBKtCBFjBBK9BBCEBOYBIJBH0BBCRBJmBBK-CBCTBMRBCuBB-BGBCCCBCBCOBCKBH6BBGJBHDBCHBDBBDVBCGBCBBCEBCJBDBBDCBDHHGGBDGBEEBMJBCDDClBBCJBCDDCDBCJBCBBJBBe7CBCEBfnCBJJBnF1BBDlBBjBkCBMJBHMBU5BBHJBHTBdaBDOBFWB6F7BBlDyCBNHBDDDBGBCBBCdBCBBDLBKJBnCHBDtBBDKBcnCBJyCBOoCBIJB3CHB5ChBBPJBHIBCsBBCNBLcBEfBDVBCNBqCGBCBBCrBBECCBCCBHBJJBHFBCBBCkBBCBBCFBIJBHrBBFJB3HYBIQBCoBBEcB2CQQBwBBO6cBnDuDBCEBMjGBtyCiDBOvhBBRVBL68DBGmSB61G5BBn2B4RBIeBCJBFwCBCJBHdBDFBLlCBLJBCGBCUBGSBxN5BBnG6CBGYBDYBtBqCBF4BBIQBhCEBMGBK1mHBqBfBiDyDB+vIDBCGBCBBCiJBQeeBBBDPPBCBJrMBloCqDBGMBEIBIJBDDBh7D8HBEzNBHWBQQBQtBBDWBKzDB9B1HBLmBBDpCBJvDBWlCB7DTBNTBN2CBKYBoE0CBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDjJBD9VBQEBCOBxiBeBHFB2GGBCQBDGBCBBCEBG9BBiBxDxDBrBBENBDJBFBBhKeBS5BBGxOxOBoBB3GqBBFhGhGBdBCVBJBBhHGBCDBCBBCOBCkGBDPBqBrCBFJBFBByYjCBtC8BBjGDBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQB1BBBvIrBBFjDBNOBDOBCOBCkBBLtFB5BcBOrBBFIBIBBPFB7E4eBEQBEMBE5GBHLBFQQBKBF3BBJJBHnBBJdBDLBFBBPIBoB3KBJNBDMBEKBE4BBCFFBOBDLBFJBIyEBCmDBmgB-2pBBhB9oEBDt0FBDwpHBQtTBjtC9QBjvBq6EBGppIBnkzVvHB",!1))),this._Print}static get Upper(){return this.CATEGORIES.get("Lu")}},me(ci,"_CASE_ORBIT",null),me(ci,"_Print",null),me(ci,"CATEGORIES",new fd({C:()=>new I(R("AfBgDgBBOrWrWBHHBCBICCVuMuMnBBBzBBBE4B4BBGBcDBHQBXhGhGxBBB8BBBmDNB8BBByBBBQddBCCMEBhBGBsCiFiFJBBDBBXIICCBFBBKBBDBBFHBCDBDGGBaaBEEHDBDBBXIIDGDBCCGDBDBBECBCGBFCCBFBSJBEKKEXXIDDGBBLIEBCCBNBFBBNGBIEEJBBDBBXIIDGGBKKBDDBEEBFBEDBDGGBTTBIBDHHBBBEFFBBBDCCDCBDCBECBNDBGCBEFFBCCBEBCNBWEBOEEYRRBKKEFFBFBDEEDBBFBBLGBXEEYLLGBBKEEFGBDEBEFFBLLELBOEE0BEEHDBRBBbEETCBZKKCBBICBCDBHCCJFBLBBELB7BDBekBBDCCGZZCYYBGGCIILBBFfBpClBlBBCBoBlBlBQOOBjBBnGCCBDBCBB6LFFBIICFFBqBqBFBBiBFFBIICFFBQQ6BFFBkCkCBhBhBBBBbFB3CBBHBB+UCB6CGBXIBZIBVLBOEEDLB-CBBLFBLFBPMMBEB6CGBsBEBnCJBgBNNBCBNDBCCBrBBBGKBtBDBbFBMCB-BBBiCeeBMMBEBLFBPBBvBBBNTBuCnFnFBGB9BCBQCB-BEBsBBBMHBsBEB3QBBHBBnBBBHBBJGCgBBB2BQQPBBHUUBEEKMMBDBbEByBPBDBBcOOBBBjBNBiBOBtEDB7UVBMUB14BBB-LEBuBCCBDBCBB5BGBDNBZIBI4BI-DhBBb6C6CBKB3GZBxC3C3CBoDoDBDBsB-C-C3CIBxBuzcuzcBBB4BIB9KTB5FHB+GTB9BCBLFB5BHBnCHBNFB1DKBfCBvCMMBCBiB4B4BBHBPBBLBBoDXBdJBHBBHBBHIBIII9BDB-DBBLFBl9KLBYDByBjoIBvLBBrDlBBILBGEBbGGCGDrUfBrBFB0BUUFDBGoEoEBCB-FCBHBBHBBHBBECBIIIBLBDBBNbbUDDQBBPhBB8DEBEDBuBCB5COOBBBCuBBvBhEBeCByBOBdDBlBIBfEBsBEBfmBmBBCBPpBB-EBBLFBlBDBlBDBpBHB1BKBNQQIDDMQQIDDBBB1BLB4JIBXJBJXBHrBrBKkCBHBBCtBtBDCBCBBYpCpCBGBKvBBUDDBDBiBCBcEBclBB5BDBVBBzBDDBDBJEEeBBEDBLGBKGBhCfBoBDBNIB3BCBeBBcEBbGBFLBIvCBqC2BB0BMB0BGBvBHBLFBnBCBeHBDvGBgBrBrBEBBDPBHHBKgBBvBHBrBVBblBBdTBYIBvCDBlBIB-BGGBLBaGBLFB2BTTBGBoBIBhDVVBJBTwBwBB8BBICCFQQMFB8BEBLFBFJJBDDBXXIDDGLLBDDBEEBCCBEBCEBIBBICBGKBLCCBCCnBLLCBBCFFLDDBGBDcB9CGGBcBpCHBLlFB3BBBnBhBBmCKBLFBOSB7BFBLFBVbBcBBQDBY4FB9BjDB0CLBJBBCBBJDDfDDBNNBHBLlCBJBBvBBBMaBpCHB0CMBqCGBL1CBJ3CBjBNBLFBKuBuBPJBeCBhBBBXPPBnCBIDDtBCBCDDKHBLFBHDDmBDDHGBLFBtBDBL1HBaGBSqBqBBBBe0CBCOBzBMB8clDBwDGGBJBlGryCBkDMBxhBPBXJB88DEBoS41GB7Bl2BB6RGBgBLLBCByCLLBEBfBBHJBnCJBLIIWEBUvNB7BlGB8CEBaBBarBBsCDB6BGBS-BBGKBIIB3mHoBBhBgDB0D8vIBFIIDkJkJBNBCcBEBBCNBFHBtMjoCBsDEBOCBKGBLBBF-6DB+HCB1NFBYOBSOBvBBBYIB1D7BB3HJBoBBBrCHBxDUBnC5DBVLBVLB4CIBamEB2CoCoCDBBCBBDBBFNNCIIiCFFBJJIddFGGCCBI1K1KBlJlJB-V-VBNBGQQBuiBBgBFBH0GBISSBIIDGGBDB-BgBBCvDBuBCBPBBLDBD-JBgBQB7BEBCvOBrB1GBsBDBC-FBgBXXBGBD-GBIFFDQQmGBBRoBBtCDBLDBDwYBlCrCB+BhGBFccDCCBCCLFFCCCBEBCDBCECEDDCBBCICDCCBFFIKFCLLSEBEGGSzBBDtIBtBDBlDLBQBBQQQmBJBvF3BBeMBtBDBKGBDNBH5EB6eCBSCBOCB7GFBNDBCOBNDB5BHBLFBpBHBfBBNDBDNBKmBB5KHBPBBOCBMCB6BCCBCBRBBND
728BLGB0EoDoDBjgBBh3pBfB-oEBBv0FBBypHOBvThtCB-QhvBBs6EEBrpIlkzVBxHvw-FB",!1)),Cc:()=>new I(R("AfgDgB",!0)),Cf:()=>new I(R("tFzqBzqBBEBXhGhGyBhMhMBxCxCs5D9-B9-BBDBbEByBEBCJBw03B6H6HBBBimEQQj7IPBhjiBDBwmFHBn0rYffB+CB",!1)),Cn:()=>new I(R("4bBBHDBICCVuMuMnBBBzBBBE4B4BBGBcDBHKBvI9B9BBmDmDBMB8BBByBBBQddBCCMEBjBEBuHJJBDDBXXICCBBBFBBKBBDBBFHBCDBDGGBaaBEEHDBDBBXIIDGDBCCGDBDBBECBCGBFCCBFBSJBEKKEXXIDDGBBLIEBCCBNBFBBNGBIEEJBBDBBXIIDGGBKKBDDBEEBFBEDBDGGBTTBIBDHHBBBEFFBBBDCCDCBDCBECBNDBGCBEFFBCCBEBCNBWEBOEEYRRBKKEFFBFBDEEDBBFBBLGBXEEYLLGBBKEEFGBDEBEFFBLLELBOEE0BEEHDBRBBbEETCBZKKCBBICBCDBHCCJFBLBBELB7BDBekBBDCCGZZCYYBGGCIILBBFfBpClBlBBCBoBlBlBQOOBjBBnGCCBDBCBB6LFFBIICFFBqBqBFBBiBFFBIICFFBQQ6BFFBkCkCBhBhBBBBbFB3CBBHBB+UCB6CGBXIBZIBVLBOEEDLB-CBBLFBLFBbFB6CGBsBEBnCJBgBNNBCBNDBCCBrBBBGKBtBDBbFBMCB-BBBiCeeBMMBEBLFBPBBvBBBNTBuCnFnFBGB9BCBQCB-BEBsBBBMHBsBEB3QBBHBBnBBBHBBJGCgBBB2BQQPBBHUUBEEKmDmDNBBcOOBBBjBNBiBOBtEDB7UVBMUB14BBB-LEBuBCCBDBCBB5BGBDNBZIBI4BI-DhBBb6C6CBKB3GZBxC3C3CBoDoDBDBsB-C-C3CIBxBuzcuzcBBB4BIB9KTB5FHB+GTB9BCBLFB5BHBnCHBNFB1DKBfCBvCMMBCBiB4B4BBHBPBBLBBoDXBdJBHBBHBBHIBIII9BDB-DBBLFBl9KLBYDByBDBvzIBBrDlBBILBGEBbGGCGDrUfBrBFB0BUUFDBGoEoEBCC-FCBHBBHBBHBBECBIIIBIBGBBNbbUDDQBBPhBB8DEBEDBuBCB5COOBBBCuBBvBhEBeCByBOBdDBlBIBfEBsBEBfmBmBBCBPpBB-EBBLFBlBDBlBDBpBHB1BKBNQQIDDMQQIDDBBB1BLB4JIBXJBJXBHrBrBKkCBHBBCtBtBDCBCBBYpCpCBGBKvBBUDDBDBiBCBcEBclBB5BDBVBBzBDDBDBJEEeBBEDBLGBKGBhCfBoBDBNIB3BCBeBBcEBbGBFLBIvCBqC2BB0BMB0BGBvBHBLFBnBCBeHBDvGBgBrBrBEBBDPBHHBKgBBvBHBrBVBblBBdTBYIBvCDBlBIBlCJBCBBaGBLFB2BTTBGBoBIBhDVVBJBTwBwBB8BBICCFQQMFB8BEBLFBFJJBDDBXXIDDGLLBDDBEEBCCBEBCEBIBBICBGKBLCCBCCnBLLCBBCFFLDDBGBDcB9CGGBcBpCHBLlFB3BBBnBhBBmCKBLFBOSB7BFBLFBVbBcBBQDBY4FB9BjDB0CLBJBBCBBJDDfDDBNNBHBLlCBJBBvBBBMaBpCHB0CMBqCGBL1CBJ3CBjBNBLFBKuBuBPJBeCBhBBBXPPBnCBIDDtBCBCDDKHBLFBHDDmBDDHGBLFBtBDBL1HBaGBSqBqBBBBe0CBCOBzBMB8clDBwDGGBJBlGryCBkDMB3iBJB88DEBoS41GB7Bl2BB6RGBgBLLBCByCLLBEBfBBHJBnCJBLIIWEBUvNB7BlGB8CEBaBBarBBsCDB6BGBS-BBGKBIIB3mHoBBhBgDB0D8vIBFIIDkJkJBNBCcBEBBCNBFHBtMjoCBsDEBOCBKGBLBBJ76DB+HCB1NFBYOBSOBvBBBYIB1D7BB3HJBoBBBjGUBnC5DBVLBVLB4CIBamEB2CoCoCDBBCBBDBBFNNCIIiCFFBJJIddFGGCCBI1K1KBlJlJB-V-VBNBGQQBuiBBgBFBH0GBISSBIIDGGBDB-BgBBCvDBuBCBPBBLDBD-JBgBQB7BEBCvOBrB1GBsBDBC-FBgBXXBGBD-GBIFFDQQmGBBRoBBtCDBLDBDwYBlCrCB+BhGBFccDCCBCCLFFCCCBEBCDBCECEDDCBBCICDCCBFFIKFCLLSEBEGGSzBBDtIBtBDBlDLBQBBQQQmBJBvF3BBeMBtBDBKGBDNBH5EB6eCBSCBOCB7GFBNDBCOBNDB5BHBLFBpBHBfBBNDBDNBKmBB5KHBPBBOCBMCB6BCCBCBRBBND
728BLGB0EoDoDBjgBBh3pBfB-oEBBv0FBBypHOBvThtCB-QhvBBs6EEBrpIm8yVBCdBhD-DBxHvw-BB---BBB---BBB",!1)),Co:()=>new I(R("gg4B-nGh4hc9--BD9--B",!0)),Cs:()=>new I(R("gg2B--B",!0)),L:()=>new I(R("hCZBHZBwBLLFGGBVBCeBCpOBFLBPEBICCiEEBCBBDDBCHHCCBCCCBSBCyCBCqEBJlFBClBBDHHBnBBoCaBFDBuBqBBkBBBCiDBCQQBIIBLLBBBDRRCdBe4CBMZZBfBKBBFGGBUBFKKEYYBXBIKBGXBCGBRpBB7B1BBETTIJBQPBFHBDBBDVBCGBCEEBCBERROBBCCBPBBLJJBEBFBBDVBCGBCBBCBBCBBgBDBCUUBBBRIBCCBCVBCGBCBBCEBETTQBBYMMBGBDBBDVBCGBCBBCEBEffBCCBBBQSSCFBECBCDBEBBCCCBEEBEEBBBELBX1B1BBGBCCBCWBCPBEbbBBBCBBDBBfFFBGBCCBCWBCJBCEBEffBBBCBBQBBSIBCCBCoBBDRRGCBJCBZFBGRBEXBCIBCDDBFB7BvBBCBBNGB7BBBCCCBDBCXBCCCBIBCBBKDDBDBCWWBCBhBgCgCBGBCjBBcEB0DqBBVRRBEBFDBEEEBIIBBBFMBNSSBkBBCGGDqBBCsKBCDBDGBCCCBCBDoBBCDBDgBBCDBDGBCCCBCBDOBC4BBCDBDiCBmBPBR1CBDFBErTBDQBCZBGqCBHHBIRBOSBPRBPMBCCBQzBBkBFFkC4CBIEBDhBBCGGBkCBLeByBdBDEBMrBBFZB3BWBK0BBzC+C+CBtBBSHB3BdBOBBLrBBbjBBqBCBLjBBDKBGqBBDCBqBDBCFBCBBEGGB+FBhC1IBDFBDlBBDFBDHBCGCBdBD0BBCGBCEEBBBCGBEDBDFBFMBGCBCGB1DOORMBmDFFDJBCEEBDBHGCBCBCKBDDBGEBF1B1BB8zC8zCBjHBHDBEBBNlBBCGGD3BBIRRBVBKGBCGBCGBCGBCGBCGBCGBCGBxC2O2OBrBrBBDBGBBF1CBHCBC5CBCDBGqBBC9CBSfBxBPBhQ-tGBhCs0VBkCtBBDsIBEPBLBBVuBBReBDlCByBIBDmDBDxCBVQBCCBCDBCWBezBBPxBB-BFBECCBMMBaBLWBacBIuBBdRRBDBCJBLEBCoBBYCBCHBVWBEEEBwBBCEEBDDBDBDCCZCBDKBICBNFBDFBDFBKGBCGBCqBBCNBHyDBej9KBNWBFwBBloItLBDpDBnBGBNEBGCCBIBCMBCEBCCCBCCBCCBqDBiBqLBT-BBD1BBpBLB1DEBCmEBlBZBHZBM4CBEFBDFBDFBDCBkBLBCZBCSBCBBCOBDNBjB6DBmMcBEwBBwBfBOTBCHBHlBBLdBDjBBFHBxB9EBTjBBFjBBFnBBJzBBNKBCOBCGBCBBCKBCOBCGBCBBEzBBN2JBKVBLHBZFBCpBBCIBmCFBDCCBqBBCBBEDDBVBLWBKeBiCSBCBBLVBLZBHZBnB3BBHBBhCQQBCBCCBCcBrBcBEcBkBHBCbBc1BBLVBLSBORBvDoCB4ByBBOyBBOjBBnBbBKWB7HpBBHBBRFB5BcBLJJBUBrBRBvBUBcWBN0BB6BBBDOOBrBBhBYBbjBBeDDJiBBENNBuBBPDBWCCkBRBCYBUBBgCGBCCCBCBCOBCJBIuBBnBHBDBBDVBCGBCBBCEBETTNEBfJBCDDClBBCaaCtBtBBzBBTDBVCBfvBBVBBC5F5FBtBBqBDBlBvBBV8B8BBpBBOoCoCBZBmBGB6FrBB1D-BBgBHBDDDBGBCBBCXBQCC-CHBDmBBRCCdLLBmBBIWWMtBBUTTBnCBoGgBBgBIBCkBBSyByBBcBxDGBCBBClBBWaaBEBCBBCfBPYYBqBBlISBQCCBLBChBB9DwCwCB4cBnHjGBtyCgDBQvhBBSFBa68DBGmSB61GdBj3B4RBIeBSuCBSdBTvBBRDBgBUBGSBxNsBB0G-BBhBYBDYBtBqCBGjCjCBLBhCBBCPPBNNB0mHBqBfBiDyDB+vIDBCGBCBBCiJBQeeBBBDPPBCBJrMBloCqDBGMBEIBIJBn7F0CBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDYBCYBCeBCYBCeBCYBCeBCYBCeBCYBCHB15BeBHFBmI9BBzEsBBLGBRiKiKBcBTrBBlPbBlHdBDwGwGBdBCCBCBBCGBDEBKBBhHGBCDBCBBCOBCkGB8BjCBI1lB1lBBCBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQBlqE-2pBBhB9oEBDt0FBDwpHBQtTBjtC9QBjvBq6EBGppIB",!1)),LC:()=>new I(R("hCZBHZB7BLLBVBCeBCiGBCDBFvGBDZBhGDBDBBECBCHHCCBCCCBSBCyCBCqEBJlFBClBBKoBB44ClBBCGGDqBBDCBhV1CBDFBjkCKBGqBBDCBhCrBBgCMBChBBmD1IBDFBDlBBDFBDHBCGCBdBD0BBCGBCEEBBBCGBEDBDFBFMBGCBCGBmIFFDJBCEEBDBHGCBCBCFBFDDBCBGEBF1B1BB8zC8zCB6DBDmDBHDBEBBNlBBCGGzoetBBTbBnEtCBCWBEDBCsCBZBBE2Z2ZBpBBGIBIvCBh6TGBNEBqgBZBHZBmlBvCBhDjBBFjBB1DKBCOBCGBCBBCKBCOBCGBCBBk2ByBBOyBB+CVBLVB74C-BBhrV-BBhBYBDYBtpZ0CBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDYBCYBCeBCYBCeBCYBCeBCYBCeBCYBCHB15BJBCTBHFB2uCjCB",!1)),Ll:()=>new I(R("hDZB7BqBqBBWBCHBC2BCBQCBuBCDECBBBDCCDEEBFFDEEBBBDDDCCCDCCBCCDEECDDBDDBBBHGDCOCBSCBDDCEEC4BCBFBDDDBCCFICBjCBDZBiGCCEEEBBBTccBhBBCBBECBCWCBDBCGDB0B0BBuBBCgBCK0BCDMCBgDCxBoBBo6CqBBDCB5XFBjkCIBC2D2DBqBBgCMBChBBnD0ECBHBCgDCBHBJFBLHBJHBJFBLHBJHBJNBDHBJHBJHBJEBCBBHEEBBBCBBJDBDBBJHBLCBCBBzIEEBEEcKFDBBJDBF2B2Bs1CvBBCEEBGCFCCBCCBEBGiDCBIICFFNlBBCGG0oesBCUaCoEMCBBBC+BCBGBCCCDICFCCDCCBBBCSCGGGCMCFCCDOCbEE2ZqBBGIBIvCBh6TGBNEBqhBZBumBnBBpEjBB8EKBCOBCGBCBBk4ByBB+DVB75CfBhsVfB8BYBnqZZBbGBCRBbZBbDBCCCBFBCKBbZBbZBbZBbZBbZBbZBbZBbZBbbBdYBCFBbYBCFBbYBCFBbYBCFBbYBCFBC15B15BBIBCTBHFB4vChBB",!1)),Lm:()=>new I(R("wVRBFLBPEBICCmEGG-OnHnHlFBBuIBBFgBgBKEEhFoFoF1mBgEgE2R72B72BsDkTkTxOFBvF+BBOjBjBBjBByVOORMBg-CBByHgGgG2OsBsBBDBGiDiDB+C+CBBB34bjnBjnBBEBvIzDzDdBB6DIBxCYYpDDBEBB2OXXqEtDtDWBBoDDBKngVngVuBBBh-BFBCpBBCIB0sBhBhB2K04D04DnrTDB9PCBpBBBnRMBhCBBCPPB9-P9-PBCBCGBCBByhM9BBqGGBud0Q0QsSAB",!1)),Lo:()=>new I(R("qFQQhIFFBCBxGBB7ZaBFDBuBfBCJBkBBBCiDBCZZBLLBBBDRRCdBe4CBMZZBfBWVBrBYBIKBGXBCGBRoBB8B1BBETTIJBROBFHBDBBDVBCGBCEEBCBERROBBCCBPBBLJJBEBFBBDVBCGBCBBCBBCBBgBDBCUUBBBRIBCCBCVBCGBCBBCEBETTQBBYMMBGBDBBDVBCGBCBBCEBEffBCCBBBQSSCFBECBCDBEBBCCCBEEBEEBBBELBX1B1BBGBCCBCWBCPBEbbBBBCBBDBBfFFBGBCCBCWBCJBCEBEffBBBCBBQBBSIBCCBCoBBDRRGCBJCBZFBGRBEXBCIBCDDBFB7BvBBCBBNFB8BBBCCCBDBCXBCCCBIBCBBKDDBDBYDBhBgCgCBGBCjBBcEB0DqBBVRRBEBFDBEEEBIIBBBFMBNyDyDBnKBCDBDGBCCCBCBDoBBCDBDgBBCDBDGBCCCBCBDOBC4BBCDBDiCBmBPByDrTBDQBCZBGqCBHHBIRBOSBPRBPMBCCBQzBBpBkCkCBhBBC0BBIEBDhBBCGGBkCBLeByBdBDEBMrBBFZB3BWBK0BBxFuBBSHB3BdBOBBLrBBbjBBqBCBLdByDDBCFBCBBE7hB7hBBCB4-C3BBZWBKGBCGBCGBCGBCGBCGBCGBCGBoR2B2BF1CBJCCB4CBFGGB
728pBBC9CBSfBxBPBhQ-tGBhC0wUBC2jBBkCnBBJrIBFPBLBBjCyByBBkCBqFoDoDEGBCCBCDBCWBezBBPxBB-BFBECCBMMBaBLWBacBIuBBuBEBDIBLEBCoBBYCBCHBVPBCFBEEEBwBBCEEBDDBDBDCCZBBEKBIPPBEBDFBDFBKGBCGByEiBBej9KBNWBFwBBloItLBDpDBkCCCBIBCMBCEBCCCBCCBCCBqDBiBqLBT-BBD1BBpBLB1DEBCmEBqDJBCsBBDeBEFBDFBDFBDCBkBLBCZBCSBCBBCOBDNBjB6DBmMcBEwBBwBfBOTBCHBHlBBLdBDjBBFHBhEtCBjDnBBJzBB9CzBBN2JBKVBLHB5EFBDCCBqBBCBBEDDBVBLWBKeBiCSBCBBLVBLZBHZBnB3BBHBBhCQQBCBCCBCcBrBcBEcBkBHBCbBc1BBLVBLSBORBvDoCB4FjBBnBDBCxJxJBoBBHBBRCBCBB5BcBLJJBUBrBRBvBUBcWBN0BB6BBBDOOBrBBhBYBbjBBeDDJiBBENNBuBBPDBWCCkBRBCYBUBBgCGBCCCBCBCOBCJBIuBBnBHBDBBDVBCGBCBBCEBETTNEBfJBCDDClBBCaaCtBtBBzBBTDBVCBfvBBVBBC5F5FBtBBqBDBlBvBBV8B8BBpBBOoCoCBZBmBGB6FrBB0GHBDDDBGBCBBCXBQCC-CHBDmBBRCCdLLBmBBIWWMtBBUTTBnCBoGgBBgBIBCkBBSyByBBcBxDGBCBBClBBWaaBEBCBBCfBPYYBnBBCBBlISBQCCBLBChBB9DwCwCB4cBnHjGBtyCgDBQvhBBSFBa68DBGmSB61GdBj3B4RBIeBSuCBSdBTvBB0BUBGSB0NnBB2MqCBGwFwFB0mHBqBfBiDyDBuwIiJBQeeBBBDPPBCBJrMBloCqDBGMBEIBIJBxzI2P2PBrBBiBiKiKBcBTrBBlPaBmHdBDwGwGBdBCCBCBBCGBDEBKiHiHBFBCDBCBBCOBCkGB8pBDBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQBlqE-2pBBhB9oEBDt0FBDwpHBQtTBjtC9QBjvBq6EBGppIB",!1)),Lt:()=>new I(R("lOGDnB2sH2sHBGBJHBJHBNQQwBAB",!1)),Lu:()=>new I(R("hCZBmDWBCGBiB2BCDOCDuBCBECEBBCCCBCCBBBDDBCBBCCBEBBCBBCECBCCDCCBCCBBBCCCBEEIJDCMCDQCDDDCCBC4BCIBBCBBDCCBCBCGCiJCCEJJHCCBBBCCCBCCBPBCIBkBDDBBBEWCGDDCBBDyBBxBgBCK2BCBMCD+CCDlBBq6ClBBCGGzW1CB0kCHHBpBBDCBhK0ECKgDCKHBJFBLHBJHBJFBMGCJHBpCDBNDBNDBNEBMDBnIFFECBDCBDEEBDBHGCBCBDDBLBBG+B+B9zCvBBxBCCBBBDGCBCBCDDJCBCgDCJCCFuqeuqeCqBCUaCoEMCE8BCLECBICFCCDCCEUCBDBCEBCOCBCBCCCBQCZs5Vs5VBYBmmBnBBpEjBB9EKBCOBCGBCBBr3ByBB+EVB75CfBhsVfBhCYBoqZZBbZBbZBbCCBGDBDDBCBCHBbZBbBBCDBDHBCGBcBBCDBCEBCEEBFBcZBbZBbZBbZBbZBbZBfYBiBYBiBYBiBYBiBYBiB2pE2pEBgBB",!1)),M:()=>new I(R("gYvDB0IGBoIsBBCCCBCCBCCpCKBxBUBRmDmDBFBDFBDBBCDBkBffBZB8CKB7BIBKZZBCBCIBCCBCEBsBCB8BIBrBXBCgBB3BCBCRBCGBLBBeCB5BCCBFBDBBDCBKLLBbbDCB5BCCBDBFBBDCBEffBEEMCB5BCCBGBCCBCCBVBBXFBCCB5BCCBFBDBBDCBICBLBBf8B8BBDBECBCDBKpBpBBDB4BCCBFBCCBCDBIBBMBBeCB5BCCBFBCCBCDBIBBMBBQNNBCB4BBBCGBCCBCDBKLLBeeBBBnCFFBEBCCCBGBTBB+BDDBFBNHBjDDDBHBMGBqCBBcECFBByBTBCBBGKBCjBBKlDlDBSBYDBFCBCCBDGBEDBOLBCLLBCBgWCBzdDBdCBeBBfBBhCfBKuBuBBBBC2D2DBjBjB3DLBFLB8GEB6BJBCcBDxBxBBsBBDLBVEBwBQBnB
728IBNCBfMB5BNBxBTB5ECBCUBFHHDCBnG-BBxWgBB--CCBuEhDhDBeBrRFBqDBB1udDBCJBhBBBxCBBxIEEFYYBDBF0C0CBzBzBBQBbRBOnBnBBGBaMBtBDBwBNBlBkCkCBMBNJJBuBuBBBBzBCCBBBDBBGBBCqBqBBDBGBBtHHBCBBx5TiXiXBOBRPBuejHjH2EEBn0BCBCBBGDBpBCBFmFmFB+R+RBCBiCEB+JBBuCFBnCKByBDB7DCB2BOBqBDDBLLBCBuBKBI+B+BBBBlBNBRBBtBNNBBBxBNBJDBCBB9CLBHDD+ELBWDB4BBBCGBDBBDCBKLLBDDBFBEEBkCIBCDDCDBCEBCPPBzCzCBQBYyCyCBSBsHGBDIBcBBzCQBrDMBmDOBhIOB2HFBCBBDDBCCCBuEuEBFBDGBEddBIBpBGBCDBJKKBJBvBPBnGHBoGHBCHBzCVBCNB7DFBECCBCCBFBCjCjCBDBCBBCEB8KDBKBBCxBxBBFBEEBYmnFmnFHOBpmLRBhuCEB8BGB5gBCCB1BBIDByCMMBslTslTBizEizEBsBBDWB-QEBEFBJHBDGBfDB1ECB89B2BBFxBBJPPXEBCOBxqBGBCQBDGBCBBCEBlDhFhFBFB4L+B+BBCB9PDB-HBB0HDDIBBG7O7OBFBuDGB29lYvHB",!1)),Mc:()=>new I(R("joC4B4BDCBJDBCBBzBBB7BCBHBBDBBLsBsB7BCBjC7B7BBBBJCCB2B2BB7B7BCHHBDDBLLnDBBCBBECBCCBLqBqBBBB+BDB+BBB7BCCBDBDBBCBBKBBdPPB7B7BBBBGCBCCBLrBrBBsCsCBBBHHBTBBrKBBgCsFsFBFFHDDBaaBLLBBBDGBWBBDFBDLLBBB5zBffiEIIBGBCBB7KDBDCBFBBCFBhHBB7BCCKCCBJJBEByExBxBGCCBDBCBB+BffFBBD9B9BDCBCEEBxBxBBGBJBBsFWW35EBB0-dBBD5C5CBzBzBBOBvEBBwBxBxBBFFBDDBBBvDBBDBBZuBuBCuDuDDBBGuHuHBCCBCCBCC0gZCCgEuBuBBBBFBB0DZZB8B8BxBCBKBBO+C+CBBBEBBCrFrFBBBgBBB7BBBCDBDBBDCBKLLB1C1CBBBIDDCDBCBBCmDmDBBBJBBErDrDBBBHCCBCBDuHuHBBBHDBDyDyDBBBJBBCuDuDCBBHoDoDCBBFmImIBBBK4H4HBEBCBBFDDCvEvEBBBJDBF1C1CeBB-BqGqGECCoGPPrDIID2G2GBDBFBBC-K-KBNNxBBBJBBCpvQpvQBBBlxD2BBpDBB0rYBBHFB",!1)),Me:()=>new I(R("okBBB1xF-wB-wBBCBCCBsshBCB",!1)),Mn:()=>new I(R("gYvDB0IEBqIsBBCCCBCCBCCpCKBxBUBRmDmDBFBDFBDBBCDBkBffBZB8CKB7BIBKZZBCBCIBCCBCEBsBCB8BIBrBXBCfB4BCCFHBFEEBFBLBBe7B7BFDBJVVBbbDBB6BFFBFFBDDBBBEffBEEMBB6BFFBDBCBBFVVBXXBEBC7B7BDCCBCBJIIBMMBff+BNNzBEE4BCCBBBGCBCDBIBBMBBe7B7BDHHGBBVBBdBB6BBBFDBJVVBeepCIIBBBC7C7CDGBNHBjDDDBHBMGBqCBBcEC4BNBCEBCBBGKBCjBBKnDnDBCBCFBCBBDBBaBBFCBRDBODDBHHQgWgWBBBzdCBeBBfBBfBBhCBBCGBJDDBJBKuBuBBBBC2D2DBjBjB3DCBFBBKHHBBB8GBBD7B7BCGBCCCDHBHJBDxBxBBMBCeBDLBVDBxBCCBDBCGGpBIBNBBhBDBDBBCCB5BCCBEECCB7BHBDBB5ECBCMBCGBFHHEBBnG-BBxWMBFEEBKB--CCBuEhDhDBeBrRDBsDBB1udFFBIBhBBBxCBBxIEEFaaBGG4EBBbRBOnBnBBGBaKBvBCBxBDDBCBDBBoBkCkCBEBDBBDBBNJJwB0B0BCCBDBBGBBCrBrBBJJvHDDFx5Tx5TiXPBRPBuejHjH2EEBn0BCBCBBGDBpBCBFmFmFB+R+RBCBiCEB+JBBuCFBnCKByBDB8D3B3BBNBqBDDBLLBBByBDBDBBI+B+BBBBlBEBCHB-BNNB1B1BBHBLDBDgDgDBBBDCCBHHD+E+EEHBWBB6BBBEmBmBBFBEEBnCFBOECPBB2CHBDCBCYY1CFBCFFBCCBvHvHBCBHBBCBBcBB2CHBDCCBrDrDCDDBEBCmDmDCDDBCBCEBkIIBCBBhIBBCFFxEDBDBBFhBhBBIBpBFBDDBJKKBEBDCBvBMBCBBnGCCBBBCqGqGBFBCFBCzCzCBUBDGBCBBCBB7DFBECCBCCBFBCpCpCBEEC8K8KBMMB1B1BBDBGCCYmnFmnFHOBpmLLBECBhuCEB8BGB5gBgCgCBCByC5lT5lTBizEizEBsBBDWBhRCBSHBDGBfDB1ECB89B2BBFxBBJPPXEBCOBxqBGBCQBDGBCBBCEBlDhFhFBFB4L+B+BBCB9PDB-HBB0HDDIBBG7O7OBFBuDGB29lYvHB",!1)),N:()=>new I(R("wBJB5DBBGDDBBBitBJBnEJBnGJB9MJB3DJBFFBtDJB3DJB3DJBDFBvDMB0DJBJGBoDJBpDGBISBuDJBhDJB3DJBnCTBtIJBnCJBwWTBybCBwHJBHJBXJBtJJBhEKBmFJBHJB3FJB3CJBnEJBHJB3gBEEBEBHJBnGyBBDEB3W7BBvCVB3TdBqrBqYqYaIBPCB4KDBrEJBfHBCOBhBJBoBOBh7cJB9FJBhKFB7EJBnBJBnGJBXJB3CJB3MJB34UJBuPsBBN4BBSBB2KaBlBDBeJJnEEBrGJBvdHBaGBoBIBsCEBXFBhFBBDPBDtBBhCIB1BBBfCBsCEBpDHBZHBqBGBrKFBxBJBHJB3IeB-EJBrBDBxDGBnEdBhEJB9BJBxEJBITB8HJB3KJB3DJB3LJBnDJBHTBtCLBlNSB+CJB3UJB3CcBkHJBnCJB3BJBnLJBnDUBshBuDBimPJBnpCJB3CJBnEJBCGBvQJBnIWB+KCB6nXJBnuBTBNTBtDYB2iBxBBhqCJBnNJB3PJB4HJBtWIBhEJB4Y6BBCCBCDBtCsBBCOBjeMBk3CJB",!1)),Nd:()=>new I(R("wBJnxBJnEJnGJ9MJ3DJ3DJ3DJ3DJ3DJ3DJ3DJ3DJ3DJhDJ3DJnCJ3IJnCJn6BJnBJtJJhEJnFJHJ3FJ3CJnEJHJnuiBJnVJnBJnGJXJ3CJ3MJ34UJnsBJnkCJHJ9YJhEJ9BJxEJ3IJ3KJ3DJ3LJnDJHTtCJnNJnDJ3UJ3CJ3HJnCJ3BJnLJ3uQJnpCJ3CJnEJ3QJ37XJ12CxBhqCJnNJ3PJ4HJ2aJ30EJ",!0)),Nl:()=>new I(R("u3FCBwzCiBBDDB-zDaaBHBPCBs1dJBxyW0BBtOJJnEEBrhIuDBm8SCB",!1)),No:()=>new I(R("yFBBGDDBBB2pCFB5LFB5DCBmEGB6GGBSIByNJB2hBTB0jBJBhP20B20BEFBHJBnGPBqB3W3WB6BBvCVB3TdBqrB1kB1kBBCBrEJBfHBCOBhBJBoBOBxrdFBymWsBBiCDBSBB2KaBlBDB1pBHBaGBoBIBsCEBXFBhFBBDPBDtBBhCIB1BBBfCBsCEBpDHBZHBqBGBrKFBhLeB-EJBrBDBxDGBnETB8LTBmqBBBvNIBobSB0aUBn8SGB-YWBqhZTBNTBtDYBvqFIBid6BBCCBCDBtCsBBCOBjeMB",!1)),P:()=>new I(R("hBCBCFBCDBLBBEBBbCBCccCkBkBGEELBBEEE-VJJzOFBqBBB0BCCDDDtBBBVBBCBBOCCBBBrCDBnDsBsBBMBqHCB3BOBgBmImIBLLtE5D5D6DnMnMNwLwL7CLLBpFpFBNBCmBmBBCBoCrCrCBDBFBBwDFBsFlTlTBHB4EuTuTtBBBvCCBoCBB+ECBCCBmBKB6JBB5GBBhEGBCFBhFBBLGBdCB9DDB8BEB-BBBhCHBM9Z9ZBWBJTBCMBCLBfBBPBB6TDBeBB+hBNBwCBBgBJB0MVBgCDBhBBB8XDBCBBxDwEwEBtBBCfBDLBkNCBFJBDLBRNNjD7C7CjgdBBuICBkDLL0DFB9LDB3CBBpBCBCyByBBwBwBiDMBRBB9DDB-DBBRBB6HzqUzqUBxGxGBI
728BXiBBCNBCFFCBB2ECBCFBCDBLBBEBBbCBCccCCCBFB7MCB9UxBxB-MoXoXoGgBgBxIIBnBxDxDBFBjCGB6CDByO-J-JjBlElEBDBtBDB+FGBuDBBCDB-DDBxBBBwCDBFOOCCB5CFBsDrJrJBCCBzDzDBDBLBBCpDpD7HWBqDCBdMBtCjEjEBBB9HpIpIBBB8E9C9CBGB0CCBCEB+CJB4GgDgDBDBrBBBmUBBrCMBwFxjBxjBBDB97CBB8zOBBmEiCiCBDBJpRpRBBBoJDBoK9lT9lTovHEB07C-a-aBAB",!1)),Pc:()=>new I(R("-Cg-Hg-HBUU-u3BBBZCBwHAB",!1)),Pd:()=>new I(R("tB9qB9qB0BiyDiyDmgBqgCqgCBEBiwDDDgBBBFdd-NUUwDxszBxszBBmBmBLqFqFhzD-J-J",!1)),Pe:()=>new I(R("pB0B0BgB+1D+1DC-6B-6BqtC4B4BQ7T7TCff-hBMCxChBhBCGC1MUChCCCiBmhBmhBCECtBGCtNICEGCDBB-ozB6G6GeOCESSCCCrF0B0BgBGD",!1)),Pf:()=>new I(R("7F+6H+6HEddpuDCCFDDQEE",!1)),Pi:()=>new I(R("rFt7Ht7HDBBDaapuDCCFDDQEE",!1)),Po:()=>new I(R("hBCBCCBDECBLLBEEBcclCGGPBBI-V-VJzOzOBEBqB3B3BDDDtBBBVBBCBBOCCBBBrCDBnDsBsBBMBqHCB3BOBgBmImIBLLtE5D5D6DnMnMNwLwL7CLLBpFpFBNBCxDxDrCEBFBBwDFBsFlTlTBHBmY9D9DBBBoCBB+ECBCCBmBFBCDB6JBB5GBBhEGBCFBhFBBLGBdCB9DDB8BEB-BBBhCHBMjajaBJJBGBJIBDDBDCBEKBCCCBIB7kDDBCBBxDwEwEBFFBBBDDDBHBCBBCDDBLLBDBCJBDDBCCCBLBDCBtNCB6B+F+FjgdBBuICBkDLL0DFB9LDB3CBBpBCBCyByBBwBwBiDMBRBB9DDB-DBBRBB6HlxUlxUBFBDXXVBBDDBECBCDBICBHCCB2E2EBBBCCBDECBLLBEEBcclBDDB7M7MBBB9UxBxB-MoXoXoGgBgBxIIBnBxDxDBFBjCGB6CDB0ZlElEBDBtBDB+FGBuDBBCDB-DDBxBBBwCDBFOOCCB5CFBsDrJrJBCCBzDzDBDBLBBCpDpD7HWBqDCBdMBtCjEjEBBB9HpIpIBBB8E9C9CBGB0CCBCEB+CJB4GgDgDBDBrBBBmUBBrCMBwFxjBxjBBDB97CBB8zOBBmEiCiCBDBJpRpRBBBoJDBoK9lT9lTovHEB07C-a-aBAB",!1)),Ps:()=>new I(R("oBzBzBgB-1D-1DC-6B-6B-rCEEnB4B4BQ7T7TCff-hBMCxChBhBCGC1MUChCCCiBmhBmhBCECaTTCECtNICEGCDipzBipzB4GeeCMCESSCCCrFzBzBgBEEDAB",!1)),S:()=>new I(R("kBHHRCBgBCCcCCkBEBCBBDCCBCBDEEfgBgBrODBNNBGGBCCCBPB2DPPBxDxDsErIrIBBB3DCBDDDBvGvGLUUB4H4HIBBpEqLqLBHHB2H2H-DjEjEBGBlEwGwGqBmGmGiGCBQCCBBBDFBVECmEHBCFBCBBGDBmGBBxXJB0WuLuLlL+E+EBgBBiLJBKIBhiBCCBBBMCBOCBOCBOBBmCOOoBCBOCBUhBB-BBBCDBCBBLCCBBBGFBCECFMMBFFBDBGDBC7B7BBFFB2LBFcBD+HBXKByCtCBXnTBtBwBBDeBLyMBX+BBFfBD1LBDpEBmHFBmLBBvBZBC4CBN1GBbPBFOOBNNWBBHBB8CBB0HBBFJBhBlBBKRRBdBMdBJQQBeBLmBBQ-JBhuG-BBx0V2BB6RWBKBBoDBB+EDBLDB+RCBiHPPB+9T+9TpEgBBuLPBhCBB3BHBtBDBjDCCBBBD7E7EHRRBBBgBCCcCCiEGBCGBOBB6JIB6BQBDCBCMBEwBwBBrBB7zBBBwSmWmWBiKiKBGBnjC2kC2kCBbBr6SDBG3qU3qUk7DvHBLCBEzNBHWBQQBgDzDB9B1HBLmBBD7BBGCBXBBIdBF8BBWhCBE7F7FB1CBrbaagBaagBaagBaagBaa9B-PB4BDBzBHBCNBCBBp2BwNwNttCEE+DiOiOBvIvIBqBBFjDBNOBDOBCOBCkBBYgFB5BcBOrBBFIBIBBPFB7E4eBEQBEMBE5GBHLBFQQBKBF3BBJJBHnBBJdBDLBFBBPIBoB3KBJNBDMBEKBE4BBCFFBOBDLBFJBIyEBC7CBLAB",!1)),Sc:()=>new I(R("kB+D+DBCBqnB8D8DzPBBzPBBI2H2HoImSmS8sClmClmCBgBB37hBkuVkuVtD7E7E8GBBEBB3-HDB-4wBxtCxtC",!1)),Sk:()=>new I(R("+CCCoCHHFEEqQDBNNBGGBCCCBPB2DPPBjoBjoB15FCCBBBMCBOCBOCBOBB9kEBBkzdWBKBBoDBBxePPBniUniUBPB8bCCjF4g9B4g9BBDB",!1)),Sm:()=>new I(R("rBRRBBB+BCCuBFFmBgBgB-XwQwQBBB8xGOOoBCBOCBsEoBoBBDBHlClCBDBGBBFGDIgBgBBDDCgBgBBqIBhBBB7CffBXBpBFB2OKK3BHBwDxKxKBDBDeBLPBhIiEBX+BBFfBDhIBxBUBDFB9+zB5Z5ZCCBlFRRBBB+BCCkEHHBCBitDBBhrwBx+Bx+BagBgBagBgBagBgBagBgBat5Ft5FB-uC-uCBHB",!1)),So:()=>new I(R("mFDDFCCyerIrIBgEgEBvGvGLUUB4H4HkQ2L2LjEFBClElEwGqBqBoMCBQCCBBBDFBVECmEHBCFBCBBGDBmGBBxXJB0WzWzW+EhBBiLJBKIBksBBBCDBCBBLCCBHHBEBCECFMMBPPCBBC7B7BBKKBDBDDBCBBCBBCGBCeBDBBCCCBdBtIHBFTBDGBDwCBCdBanBBHnCBXKByCtCBX2FBCIBC1BBJuDBC3HBtBrBBhC-HBhQvBBWBBHmBBDpEBmHFBmLBBvBZBC4CBN1GBbPBFOOBNNWBBHBBxKBBFJBhBlBBKRRBdBMdBJQQBeBLmBBQ-JBhuG-BBx0V2BBibDBLBBC+R+RBBBqqUPBuLPBhCBB3BHBuBCBlPEEFBBOBB6JIB6BQBDCBCMBEwBwBBrBB7zBBBwSpgBpgBBGBnjC2kC2kCBGBFQBr6SDBG3qU3qUk7DvHBLCBEzNBHWBQPBhDzDB9B1HBLmBBD7BBGCBXBBIdBF8BBWhCBE7F7FB1CBqlB-PB4BDBzBHBCNBCBBp2B96C96CiEyWyWBqBBFjDBNOBDOBCOBCkBBYgFB5BcBOrBBFIBIBBPFB7E6HBG4WBEQBEMBE5GBHLBFQQBKBF3BBJJBHnBBJdBDLBFBB-B3KBJNBDMBEKBE4BBCFFBOBDLBFJBIyEBC7CBLAB",!1)),Z:()=>new I(R("gBgEgEgvFgsCgsCBJBeBBGwBwBh9DAB",!1)),Zl:()=>new I(R("ohIA",!0)),Zp:()=>new I(R("phIA",!0)),Zs:()=>new I(R("gBgEgEgvFgsCgsCBJBlBwBwBh9DAB",!1)),ASCII_Hex_Digit:()=>new I(R("wBJIFbF",!0)),Alphabetic:()=>new I(R("hCZBHZBwBLLFGGBVBCeBCpOBFLBPEBICC3CeeBQBCBBDDBCHHCCBCCCBSBCyCBCqEBJlFBClBBDHHBnBBoBNBCCCBCCBCCJaBFDBeKBG3BBCGBPlDBCHBFHBFCBLCBDRRBuBBOkDBZgBBKBBFGGBWBDSBUYBIKBGXBCGBIJJBoBBLLBEGBHrCBCPBCCBFOBOSBCHBDBBDVBCGBCEEBCBEHBDBBDBBCJJFBBCEBNBBLFFBBBCFBFBBDVBCGBCBBCBBCBBFEBFBBDBBFIIBCBCSSBEBMCBCIBCCBCVBCGBCBBCEBEIBCCBCBBEQQBCBWDBFCBCHBDBBDVBCGBCBBCEBEHBDBBDBBKBBFBBCEBORRBCCBEBECBCDBEBBCCCBEEBEEBBBELBFEBECBCCBEHHpBMBCCBCWBCPBEHBCCBCCBJBBCCBCBBDDBdDBCHBCCBCWBCJBCEBEHBCCBCCBJBBGCBCDBOCBNMBCCBCoBBDHBCCBCCBCGGBCBIEBXFBCCBCRBEXBCIBCDDBFBJFBCCCBGBTBBO5BBGGBH0B0BBECBDBCXBCCCBRBCCBDEBCHHPDBhBgCgCBGBCjBBFSBFPBCjBBkC2BBCDDBDBR-BBLDBDlBBCGGDqBBCsKBCDBDGBCCCBCBDoBBCDBDgBBCDBDGBCCCBCBDOBC4BBCDBDiCBmBPBR1CBDFBErTBDQBCZBGqCBEKBITBMUBNTBNMBCCBCBBNzBBDSBPFFkC4CBIqBBGlCBLeBCLBFIBYdBDEBMrBBFZB3BbBF+BBDTBzBYYBMMBBByBzBBCOBCHB0BpBBDDBLrBBCKBP2BBXCBLjBBDKBGqBBDCBqBDBCFBCBBEGGB+FBUhBBM1IBDFBDlBBDFBDHBCGCBdBD0BBCGBCEEBBBCGBEDBDFBFMBGCBCGB1DOORMBmDFFDJBCEEBDBHGCBCBCKBDDBGEBFSSBnBBuZzBB34BkHBHDBEBBNlBBCGGD3BBI
728RRBVBKGBCGBCGBCGBCGBCGBCGBCGBCfBwB2O2OBBBaIBIEBDEBF1CBHCBC5CBCDBGqBBC9CBSfBxBPBhQ-tGBhCs0VBkCtBBDsIBEPBLBBVuBBGHBEwDBoBIBDmDBDxCBVUBCgBBZzBBNjCBCtBtBBEBECCBBBLgBBGiBBOcBEyBBCLBQRRBOBLEBC2BBKNBTWBEkCBCCCZCBDPBDDBMFBDFBDFBKGBCGBCqBBCNBH6DBWj9KBNWBFwBBloItLBDpDBnBGBNEBGLBCMBCEBCCCBCCBCCBqDBiBqLBT-BBD1BBpBLB1DEBCmEBlBZBHZBM4CBEFBDFBDFBDCBkBLBCZBCSBCBBCOBDNBjB6DBmC0BBsIcBEwBBwBfBOdBGqBBGdBDjBBFHBCEBrB9EBTjBBFjBBFnBBJzBBNKBCOBCGBCBBCKBCOBCGBCBBEzBBN2JBKVBLHBZFBCpBBCIBmCFBDCCBqBBCBBEDDBVBLWBKeBiCSBCBBLVBLZBHZBnB3BBHBBhCDBCBBGHBCCBCcBrBcBEcBkBHBCbBc1BBLVBLSBORBvDoCB4ByBBOyBBOnBBjBbBEGGBVB7HpBBCBBEBBRFBzBCBEcBLJJBUBrBRBvBUBcWBKlCBsBEBL4BBKOOBXBYyBBSDBJiBBEKKB+BBCDBKBBLCCkBRBChBBDHHBCB-BGBCCCBCBCOBCJBI4BBYDBCHBDBBDVBCGBCBBCEBEHBDBBDBBEHHGGBdJBCDDClBBCJBCDDCDBCBBECCtBhCBCCBCDBVCBfhCBDBBC5F5FB0BBDGBaFBjB+BBCEE8B1BBDoCoCBZBDNBWGB6F4BBoD-BBgBHBDDDBGBCBBCdBCBBDBBDDB+CHBDtBBDFBCCCBccBxBBDJBSnCBGTTBnCBoDHB5CgBBgBIBCsBBCGBCyByBBcBDVBCNBqCGBCBBCrBBECCBCCBBBCDDBZZBEBCBBCkBBCBBCDBCYYBqBBlIWBKQBCoBBECBwDwCwCB4cBnDuDBSjGBtyCgDBQvhBBSFBa68DBGmSB61GuBBy2B4RBIeBSuCBSdBTvBBRDBgBUBGSBxNsBB0G-BBhBYBDYBtBqCBF4BBIQBhCBBCNNBFBK1mHBqBfBiDyDB+vIDBCGBCBBCiJBQeeBBBDPPBCBJrMBloCqDBGMBEIBIJBFi7Fi7FBzCBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDYBCYBCeBCYBCeBCYBCeBCYBCeBCYBCHB15BeBHFB2GGBCQBDGBCBBCEBG9BBiBxDxDBrBBLGBRiKiKBcBTrBBlPbBlHdBDwGwGBdBCVBJBBhHGBCDBCBBCOBCkGB8BjCBEEE1lBDBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQB1TZBHZBHZB3zD-2pBBhB9oEBDt0FBDwpHBQtTBjtC9QBjvBq6EBGppIB",!1)),Dash:()=>new I(R("tB9qB9qB0BiyDiyDmgBqgCqgCBEB+BoBoBQnMnMlgDDDgBBBFdd-NUUwDxszBxszBBmBmBLqFqFhzD-J-J",!1)),Emoji:()=>new I(R("jBHHGJBwDFFu8HNN5GXX7CFBQBBwLBBNnFnFaKBFCBoGoHoHBLLK7B7BBCBCEBKGDBDDFDDCBBDIEBJJBBBGCCGLBMBBDCCBCCTDDBTTBEBCCCBEEBGGDBBFBBMBBGBBDGGBECBVVBGGBEBCDBDFFDDDBEBCDDCCCHEEHLLBQQDFFCFFBBBCMMBxBxBBBBKeP1LBBwOCBUBB0BFF7mBNN6SCCrrvDrGrGhFBBNBBPDDBIBsCZBCBBYVVDIBWBBvFhBBDvDBDBBCCBDyCBDCBCmIBC+BBMFBCXBIBBDHBNDDBCBDFFBOOBDDJBBKGGBBBNCBJCBDCCFHHEHHB0CBxBlCBGHBDDBEJBECCBEEDJBkHLBF8I8IBtBBCJBC4FBxDMBEKBE4BBCFFBOBDLBFJB",!1)),Emoji_Component:()=>new I(R("jBHHGJB0+H2G2Gsp3B3+8B3+8BBYB8PEBxtBDBtzhY-CB",!1)),Emoji_Modifier:()=>new I(R("7-8DE",!0)),Emoji_Modifier_Base:()=>new I(R("9wJ8G8GRDB4jzD9B9BBBBDDDBBB2DBBDKBWSBEFFBBBCCBICCZqGqGBFFWFFBvFvFBBBEEB0CRRBBBKMMgSDDJHBHKKBIBDCB5B+B+BBCCBCCSCBCMBmHCBrBIB",!1)),Emoji_Presentation:()=>new I(R("64IBBuGDBEDDqQBBWBBzBLBsBUUOJJBSSBGGBJJGWWIBBCFFDIIFBBdkBkBCFFBBBC+B+BBBBZPP8aBB0BFFvlxDrGrG-FDDBIBsCZBCZZVDDBDBCCBWBBvFgBBNIBClCBCVBNqBBFEBNQBEEEBlCBCCCB5FBD+BBODBCXBTbbBOO3C0CBxBlCBHEEBBBDDBEDBMBBIIBkHLBF8I8IBtBBCJBC4FBxDMBEKBE4BBCFFBOBDLBFJB",!1)),Extended_Pictographic:()=>new I(R("pFFFu8HNN5GXX7CFBQBBwLBBNnFnFaKBFCBoGoHoHBLLK7B7BBCBCEBKGDBDDFDDCBBDIEBJJBBBGCCGLBMBBDCCBCCTDDBTTBEBCCCBEEBGGDBBFBBMBBGBBDGGBECBVVBGGBEBCDBDFFDDDBEBCDDCCCHEEHLLBQQDFFCFFBBBCMMBxBxBBBBKeP1LBBwOCBUBB0BFF7mBNN6SCCrrvDoBoBBCBlDLBQBBQPPBmBmBBIBxDBBNBBPDDBIBU3BBcOBLVVDIBCDBKWBH7FBDvDBDBBCCBDyCBDCBCDBG9HBC+BBMFBCXBIBBDHBNDDBCBDFFBOOBDDJBBKGGBBBNCBJCBDCCFHHEHHB0CBxBlCBGHBDQBECCBEBDMB7GlBBNDB5BHBLFBpBHBfBBNDBDNBKmBBNuBBCJBC4FB5CHBPxEBhI9fB",!1)),Hex_Digit:()=>new I(R("wBJIFbFq1-BJIFbF",!0)),Lowercase:()=>new I(R("hDZBwBLLFlBlBBWBCHBC2BCBQCBuBCDECBBBDCCDEEBFFDEEBBBDDDCCCDCCBCCDEECDDBDDBBBHGDCOCBSCBDDCEEC4BCBFBDDDBCCFICBjCBDiBBIBBfEBhDsBsBCEEDDBTccBhBBCBBECBCWCBDBCGDB0B0BBuBBCgBCK0BCDMCBgDCxBoBBo6CqBBCDB5XFBjkCIBC2D2DB+FBiC0ECBHBCgDCBHBJFBLHBJHBJFBLHBJHBJNBDHBJHBJHBJEBCBBHEEBBBCBBJDBDBBJHBLCBCBB6DOORMBuDEEBEEcKFDBBJDBFiBiBBOBFsasaBYBn6BvBBCEEBGCFCCBCCBGBEiDCBIICFFNlBBCGG0oesBCUaCBBBmEMCBBBC8BCBIBCCCDICFCCDCCBBBCSCGGGCMCFCCDOCWDBCCCBBB2ZqBBCNBHvCBh6TGBNEBqhBZBumBnBBpEjBB8EKBCOBCGBCBBkODDBBBCpBBCIBmoByBB+DVB75CfBhsVfB8BYBnqZZBbGBCRBbZBbDBCCCBFBCKBbZBbZBbZBbZBbZBbZBbZBbZBbbBdYBCFBbYBCFBbYBCFBbYBCFBbYBCFBC15B15BBIBCTBHFBmI9BB1lChBB",!1)),Math:()=>new I(R("rBRRBBBgBeeCuBuBFmBmBgB5W5WBBBDbbBDDBBBwQCBuwGccBBBMEEOPPBCBWEBMEBiCMBFEEBFFBDBTFFDJBCDDBEBHEEBDDBCCBBBCFBENBClClCBWBCFBCBBFBBFfBCHHBPPBqIBJDBVBB7CffBZBCZZMGB+NBBNJBFFBFBBDBBEEBPCCDFBMHBGBB6BCCeDBKCBxK-BBhI-PBxBUBDFB9+zB4Z4ZBEBCjFjFRCBeCCeCCkEHHBCBitDBBhrwBwoBwoBBzCBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDjJBDxBBhwFDBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQB1BBB-uCIB",!1)),Quotation_Mark:()=>new I(R("iBFFkEQQ96HHBaBBowDqOqOBCBOCBixzBDB+FFF7CBB",!1)),Terminal_Punctuation:()=>new I(R("hBLLCMMBEE-ZJJiQ6B6BpCPPCCB1FsBsBBJBCsHsHB3B3BBEBCHBgBmImIB1nB1nBBtFtFFFB4JBB2YHBmY9D9DBBBoCBB+ECBEoBoBBCBDBB7JBBjLDBjFBBLBBCCBeCB8FEB-BBBldYYBKKBBBwlDCBzJOOFLLCBBEBBtNBB8ndBBuICBkHEB-LBB3CBBgD4E4EBBB0ECBgERRB6H6HnxUDDB6B6BBBBCDBqFLLCMMBEEiCDD7hBxBxBnkBoGoG3JBB5EFBlCFB6CDB5dEBtBDB+FGBxDDBgECBiEBBHRRB5C5CBDBtDrJrJB2D2DBBBNBBnLDBEOBqDBB6HCBmQCC8HBB4CBBFBB-MCBuBmUmUBrCrCBspBspBBDB6vRBBmEiCiCBBBLqRqRBoJoJBnwTnwTovHDB",!1)),Uppercase:()=>new I(R("hCZBmDWBCGBiB2BCDOCDuBCBECEBBCCCBCCBBBDDBCBBCCBEBBCBBCECBCCDCCBCCBBBCCCBEEIJDCMCDQCDDDCCBC4BCIBBCBBDCCBCBCGCiJCCEJJHCCBBBCCCBCCBPBCIBkBDDBBBEWCGDDCBBDyBBxBgBCK2BCBMCD+CCDlBBq6ClBBCGGzW1CB0kCHHBpBBDCBhK0ECKgDCKHBJFBLHBJHBJFBMGCJHBpCDBNDBNDBNEBMDBnIFFECBDCBDEEBDBHGCBCBDDBLBBGbbBOBUzZzZBYBx5BvBBxBCCB
728BBDGCBCBCDDJCBCgDCJCCFuqeuqeCqBCUaCoEMCE8BCLECBICFCCDCCEUCBDBCEBCOCBCBCCCBQCZs5Vs5VBYBmmBnBBpEjBB9EKBCOBCGBCBBr3ByBB+EVB75CfBhsVfBhCYBoqZZBbZBbZBbCCBGDBDDBCBCHBbZBbBBCDBDHBCGBcBBCDBCEBCEEBFBcZBbZBbZBbZBbZBbZBfYBiBYBiBYBiBYBiBYBiB2pE2pEBgBBvgCZBHZBHZB",!1)),White_Space:()=>new I(R("JEBTlDlDbgvFgvFgsCKBeBBGwBwBh9DAB",!1))})),me(ci,"SCRIPTS",new fd({Adlam:()=>new I(R("go6DrCFJFB",!0)),Ahom:()=>new I(R("g4lCaDOFW",!0)),Anatolian_Hieroglyphs:()=>new I(R("ggxCmS",!0)),Arabic:()=>new I(R("gwBEBCFBCNBCCBCfBCJBMZBCrDBChBBxCvBBxHhBBGqCBCcBxy8BtPBDvEBhBPBxDEBCmEBk7DeBkCFBJIBiBFBh43BDBCaBCBBCDDCJBCDBCCCHFFCECBBBCBBCDDCICBCCDDBCGBCDBCDBCCCBIBCQBGCBCEBCQB1BBB",!1)),Armenian:()=>new I(R("xpBlBDxBDCks9BE",!0)),Avestan:()=>new I(R("g4iC1BEG",!0)),Balinese:()=>new I(R("g4GsCCxB",!0)),Bamum:()=>new I(R("g1pB3CpowB4R",!0)),Bassa_Vah:()=>new I(R("w26CdDF",!0)),Batak:()=>new I(R("g+GzBJD",!0)),Bengali:()=>new I(R("gsCDBCHBDBBDVBCGBCEEBCBDIBDBBDDBJFFBCCBDBDYB",!1)),Beria_Erfe:()=>new I(R("g17CYDY",!0)),Bhaiksuki:()=>new I(R("ggnCICsBCNLc",!0)),Bopomofo:()=>new I(R("qXB6wLqBxDf",!0)),Brahmi:()=>new I(R("ggkCtCFjBKA",!0)),Braille:()=>new I(R("ggK-H",!0)),Buginese:()=>new I(R("gwGbDB",!0)),Buhid:()=>new I(R("g6FT",!0)),Canadian_Aboriginal:()=>new I(R("ggF-TxRlC7tgCP",!0)),Carian:()=>new I(R("g1gCwB",!0)),Caucasian_Albanian:()=>new I(R("wphCzBMA",!0)),Chakma:()=>new I(R("gokC0BCR",!0)),Cham:()=>new I(R("gwqB2BKNDJDD",!0)),Cherokee:()=>new I(R("g9E1CDFz7lBvC",!0)),Chorasmian:()=>new I(R("w9jCb",!0)),Common:()=>new I(R("AgCBbFBbuBBCOBCEBYgBgBiOmBBGEBDTB1DKKHCC+THHPEEhB9E9ElQiEiEB6mB6mB2MDBjJwvBwvBBBBoCBBsGBBCumBumBOIIBCBCFBCCBDmYmYBKBD2CBCKBEKBCOBShBB-BlBBCCBDFBCaBCQBqBCBF5UBXKBW-cBhIzTBDpEBhQ9CBzMUBCCCBXBQHBFDB8CBBE7C7CB0E0EBOBhBlBBKxBxBB+BBgBwCBwB5C5CBmFBhuG-BBhoWhBBnDCBmFJB1HhFhFsMPPBzuUzuUBxGxGBIBXiBBCSBCDB0ECCBeBbFBbKBLuBuBBhChCBFBCGBLEBjICBFsBBEIBxCMB0BsBBlHaBltuBDB96D8HBEzNBHWBQQBgDzDB9B1HBLmBBD9BBEQBJBBIdBF8BB2GTBNTBN2CBKYBoE0CBCmCBCBBDDDBDDBCBCLBCCCBFBCgCBCDBDHBCGBCbBCDBCEBCEEBFBCzKBDjJBDxBByjFjCBtC8BBjWrBBFjDBNOBDOBCOBCkBBLtFB5BZBCBBOrBBFIBIBBPFB7E4eBEQBEMBE5GBHLBFQQBKBF3BBJJBHnBBJdBDLBFBBPIBoB3KBJNBDMBEKBE4BBCFFBOBDLBFJBIyEBCmDBnghYffB+CB",!1)),Coptic:()=>new I(R("ifNxkKzDGG",!0)),Cuneiform:()=>new I(R("ggoC5cnDuDCEMjG",!0)),Cypriot:()=>new I(R("ggiCFBDCCBqBBCBBEDD",!1)),Cypro_Minoan:()=>new I(R("w8rCiD",!0)),Cyrillic:()=>new I(R("ggBkEBDoFBx6FKBhFtCtCojEfBhie-CBv8VBBhw4B9BBiBAB",!1)),Deseret:()=>new I(R("gghCvC",!0)),Devanagari:()=>new I(R("goCwCFODZh7nBfhwcJ",!0)),Dives_Akuru:()=>new I(R("gomCGBDDDBGBCBBCdBCBBDLBKJB",!1)),Dogra:()=>new I(R("ggmC7B",!0)),Duployan:()=>new I(R("ggvDqDGMEIIJDD",!0)),Egyptian_Hieroglyphs:()=>new I(R("ggsC1iBL68D",!0)),Elbasan:()=>new I(R("gohCnB",!0)),Elymaic:()=>new I(R("g-jCW",!0)),Ethiopic:()=>new I(R("gwEoCBCDBDGBCCCBCBDoBBCDBDgBBCDBDGBCCCBCBDOBC4BBCDBDiCBDfBEZBnvGWBKGBCGBCGBCGBCGBCGBCGBCGBjpfFBDFBDFBKGBCGBylvCGBCD
728BCBBCOB",!1)),Garay:()=>new I(R("gqjClBEcJB",!0)),Georgian:()=>new I(R("glElBBCGGDqBBCDBx8CqBBDCBhiElBBCGG",!1)),Glagolitic:()=>new I(R("ggL-Ch9sDGCQDGCBCE",!0)),Gothic:()=>new I(R("w5gCa",!0)),Grantha:()=>new I(R("g4kCDBCHBDBBDVBCGBCBBCEBDIBDBBDCBDHHGGBDGBEEB",!1)),Greek:()=>new I(R("wbDBCCBDDBCFFCCCBBBCCCBSBC+BBPPBnpGEBzBEBFEB1ChKhKBUBDFBDlBBDFBDHBCGCBdBD0BBCOBCNBDFBCSBDCBCIBoJ-xiB-xiB7uVuCBSgj0Bgj0BBkCB",!1)),Gujarati:()=>new I(R("h0CCBCIBCCBCVBCGBCBBCEBDJBCCBCCBDQQBCBDLBIGB",!1)),Gunjala_Gondi:()=>new I(R("grnCFCBCkBCBCFIJ",!0)),Gurmukhi:()=>new I(R("hwCCBCFBFBBDVBCGBCBBCBBCBBDCCBDBFBBDCBEIIBCBCIIBPB",!1)),Gurung_Khema:()=>new I(R("go4C5B",!0)),Han:()=>new I(R("g0LZBC4CBN1GBwBCCaIBPDBle-tGBhC-vUBhoWtLBDpDBpodBBNGBqgkB-2pBBhB9oEBDt0FBDwpHBQtTBjtC9QBjvBq6EBGppIB",!1)),Hangul:()=>new I(R("goE-HvxHBiI9CyDeiCei3dckUj9KNWFwBl9JeEFDFDFDC",!0)),Hanifi_Rohingya:()=>new I(R("gojCnBJJ",!0)),Hanunoo:()=>new I(R("g5FU",!0)),Hatran:()=>new I(R("gniCSCBGE",!0)),Hebrew:()=>new I(R("xsB2BBJaBFFBpp9BZBCEBCCCBCCBCCBIB",!1)),Hiragana:()=>new I(R("hiM1CBHCBi7-C+IBTeeBBBulQAB",!1)),Imperial_Aramaic:()=>new I(R("giiCVCI",!0)),Inherited:()=>new I(R("gYvDB2IBBlOKBbhXhXBCB8qEtBBDLBlPCBCMBCGBFHHEBBnG-BBtQBBjGgBB65DDBsDBBmrzBPBRNBwejHjH7iEl+uBl+uBBsBBDWBhRCBSHBDGBfDBz6rYvHB",!1)),Inscriptional_Pahlavi:()=>new I(R("g7iCSGH",!0)),Inscriptional_Parthian:()=>new I(R("g6iCVDH",!0)),Javanese:()=>new I(R("gsqBtCDJFB",!0)),Kaithi:()=>new I(R("gkkCiCLA",!0)),Kannada:()=>new I(R("gkDMCCCWCJCEDICCCDIBGCCDDJCC",!0)),Katakana:()=>new I(R("hlM5CBDCBxHPBxGuBBC3CBvgzBJBCsBBzisBDBCGBCBBCgJgJBBBzBPPBCB",!1)),Kawi:()=>new I(R("g4nCQCoBEc",!0)),Kayah_Li:()=>new I(R("goqBtBCA",!0)),Kharoshthi:()=>new I(R("gwiCDCBGHCCCcDCFJII",!0)),Khitan_Small_Script:()=>new I(R("k-7C84G84GB0OBqBAB",!1)),Khmer:()=>new I(R("g8F9CDJHJnPf",!0)),Khojki:()=>new I(R("gwkCRCuB",!0)),Khudawadi:()=>new I(R("w1kC6BGJ",!0)),Kirat_Rai:()=>new I(R("gq7C5B",!0)),Lao:()=>new I(R("h0DBBCCCBDBCXBCCCBVBDEBCCCBFBCJBDDB",!1)),Latin:()=>new I(R("hCZBHZBwBQQGWBCeBCgOBoBEB8wGlBBHwBBGDBGMBClCBiC-HByLOORMBuEBBHccSoBB42CfBj1elDBExCBVOBxZqBBCIBCDB38TGB7gBZBHZBmhCFBCpBBCIBm61BeBHFB",!1)),Lepcha:()=>new I(R("ggH3BEOEC",!0)),Limbu:()=>new I(R("goGeBCLBFLBFEEBKB",!1)),Linear_A:()=>new I(R("gwhC2JKVLH",!0)),Linear_B:()=>new I(R("gggCLCZCSCBCODNjB6D",!0)),Lisu:()=>new I(R("wmpBvBx1eA",!0)),Lycian:()=>new I(R("g0gCc",!0)),Lydian:()=>new I(R("gpiCZGA",!0)),Mahajani:()=>new I(R("wqkCmB",!0)),Makasar:()=>new I(R("g3nCY",!0)),Malayalam:()=>new I(R("goDMCCCyBCCCFFPDZ",!0)),Mandaic:()=>new I(R("giCbDA",!0)),Manichaean:()=>new I(R("g2iCmBFL",!0)),Marchen:()=>new I(R("wjnCfDVCN",!0)),Masaram_Gondi:()=>new I(R("gonCGBCBBCrBBECCBCCBHBJJB",!1)),Medefaidrin:()=>new I(R("gy7C6C",!0)),Meetei_Mayek:()=>new I(R("g3qBWqGtBDJ",!0)),Mende_Kikakui:()=>new I(R("gg6DkGDP",!0)),Meroitic_Cursive:()=>new I(R("gtiCXFTDtB",!0)),Meroitic_Hieroglyphs:()=>new I(R("gsiCf",!0)),Miao:()=>new I(R("g47CqCF4BIQ",!0)),Modi:()=>new I(R("gwlCkCMJ",!0)),Mongolian:()=>new I(R("ggGBBDCCBSBH4CBIqBB2t-BMB",!1)),Mro:()=>new I(R("gy6CeCJFB",!0)),Multani:()=>new I(R("g0kCGBCCCBCBCOBCKB",!1)),Myanmar:()=>new I(R("ggE-EhqmBeiDfxibT",!0)),Nabataean:()=>new I(R("gkiCeJI",!0)),Nag_Mundari:()=>new I(R("wm5DpB",!0)),Nandinagari:()=>new I(R("gtmCHDtBDK",!0)),New_Tai_Lue:()=>new I(R("gsGrBFZHKEB",!0)),Newa:()=>new I(R("gglC7CCE",!0)),Nko:()=>new I(R("g+B6BDC",!0)),Nushu:()=>new I(R("h-7CvsQvsQBqMB",!1)),Nyiakeng_Puachue_Hmong:()=>new I(R("go4DsBENDJFB",!0)),Ogham:()=>new I(R("g0Fc",!0)),Ol_Chiki:()=>new I(R("wiHvB",!0)),Ol_Onal:()=>new I(R("wu5DqBFA",!0)),Old_Hungarian:()=>new I(R("gkjCyBOyBIF",!0)),Old_Italic:()=>new I(R("g4gCjBKC",!0)),Old_North_Arabian:()=>new I(R("g0iCf",!0)),Old_Permic:()=>new I(R("w6gCqB",!0)),Old_Persian:()=>new I(R("g9gCjBFN",!0)),Old_Sogdian:()=>new I(R("g4jCnB",!0)),Old_South_Arabian:()=>new I(R("gziCf",!0)),Old_Turkic:()=>new I(R("ggjCoC",!0)),Old_Uyghur:()=>new I(R("w7jCZ",!0)),Oriya:()=>new I(R("h4CCCHDBDVCGCBCEDIDBDCICFBCEDR",!0)),Osage:()=>new I(R("wlhCjBFjB",!0)),Osmanya:()=>new I(R("gkhCdDJ",!0)),Pahawh_Hmong:()=>new I(R("g46ClCLJCGCUGS",!0)),Palmyrene:()=>new I(R("gjiCf",!0)),Pau_Cin_Hau:()=>new I(R("g2mC4B",!0)),Phags_Pa:()=>new I(R("giqB3B",!0)),Phoenician:()=>new I(R("goiCbEA",!0)),Psalter_Pahlavi:()=>new I(R("g8iCRIDNG",!0)),Rejang:()=>new I(R("wpqBjBMA",!0)),Runic:()=>new I(R("g1FqCEK",!0)),Samaritan:()=>new I(R("ggCtBDO",!0)),Saurashtra:()=>new I(R("gkqBlCJL",!0)),Sharada:()=>new I(R("gskC-ChsCH",!0)),Shavian:()=>new I(R("wihCvB",!0)),Siddham:()=>new I(R("gslC1BDlB",!0)),Sidetic:()=>new I(R("gqiCZ",!0)),SignWriting:()=>new I(R("gg2DrUQECO",!0)),Sinhala:()=>new I(R("hsDCBCRBEXBCIBCDDBFBEFFBEBCCCBGBHJBDCBt-gCTB",!1)),Sogdian:()=>new I(R("w5jCpB",!0)),Sora_Sompeng:()=>new I(R("wmkCYIJ",!0)),Soyombo:()=>new I(R("wymCyC",!0)),Sundanese:()=>new I(R("g8G-BhIH",!0)),Sunuwar:()=>new I(R("g+mChBPJ",!0)),Syloti_Nagri:()=>new I(R("ggqBsB",!0)),Syriac:()=>new I(R("g4BNC7BDCxIK",!0)),Tagalog:()=>new I(R("g4FVKA",!0)),Tagbanwa:()=>new I(R("g7FMCCCB",!0)),Tai_Le:()=>new I(R("wqGdDE",!0)),Tai_Tham:()=>new I(R("gxG+BCcDKHJHN",!0)),Tai_Viet:()=>new I(R("g0qBiCZE",!0)),Tai_Yo:()=>new I(R("g25DeCVJB",!0)),Takri:()=>new I(R("g0lC5BHJ",!0)),Tamil:()=>new I(R("i8CBBCFBECBCDBEBBCCCBEEBEEBBBELBFEBECBCDBDHHPUBm+kCxBBOAB",!1)),Tangsa:()=>new I(R("wz6CuCCJ",!0)),Tangut:()=>new I(R("g-7CgBgBB+3GBhQeBiDyDB",!1)),Telugu:()=>
728new I(R("ggDMCCCWCPDICCCDIBCCCBDDDJII",!0)),Thaana:()=>new I(R("g8BxB",!0)),Thai:()=>new I(R("hwD5BGb",!0)),Tibetan:()=>new I(R("g4DnCCjBFmBCjBCOCGFB",!0)),Tifinagh:()=>new I(R("wpL3BIBPA",!0)),Tirhuta:()=>new I(R("gklCnCJJ",!0)),Todhri:()=>new I(R("guhCzB",!0)),Tolong_Siki:()=>new I(R("wtnCrBFJ",!0)),Toto:()=>new I(R("w04De",!0)),Tulu_Tigalari:()=>new I(R("g8kCJBCDDClBBCJBCDDCDBCJBCBBJBB",!1)),Ugaritic:()=>new I(R("g8gCdCA",!0)),Unknown:()=>new I(R("4bBBHDBICCVuMuMnBBBzBBBE4B4BBGBcDBHKBvI9B9BBmDmDBMB8BBByBBBQddBCCMEBjBEBuHJJBDDBXXICCBBBFBBKBBDBBFHBCDBDGGBaaBEEHDBDBBXIIDGDBCCGDBDBBECBCGBFCCBFBSJBEKKEXXIDDGBBLIEBCCBNBFBBNGBIEEJBBDBBXIIDGGBKKBDDBEEBFBEDBDGGBTTBIBDHHBBBEFFBBBDCCDCBDCBECBNDBGCBEFFBCCBEBCNBWEBOEEYRRBKKEFFBFBDEEDBBFBBLGBXEEYLLGBBKEEFGBDEBEFFBLLELBOEE0BEEHDBRBBbEETCBZKKCBBICBCDBHCCJFBLBBELB7BDBekBBDCCGZZCYYBGGCIILBBFfBpClBlBBCBoBlBlBQOOBjBBnGCCBDBCBB6LFFBIICFFBqBqBFBBiBFFBIICFFBQQ6BFFBkCkCBhBhBBBBbFB3CBBHBB+UCB6CGBXIBZIBVLBOEEDLB-CBBLFBLFBbFB6CGBsBEBnCJBgBNNBCBNDBCCBrBBBGKBtBDBbFBMCB-BBBiCeeBMMBEBLFBPBBvBBBNTBuCnFnFBGB9BCBQCB-BEBsBBBMHBsBEB3QBBHBBnBBBHBBJGCgBBB2BQQPBBHUUBEEKmDmDNBBcOOBBBjBNBiBOBtEDB7UVBMUB14BBB-LEBuBCCBDBCBB5BGBDNBZIBI4BI-DhBBb6C6CBKB3GZBxC3C3CBoDoDBDBsB-C-C3CIBxBuzcuzcBBB4BIB9KTB5FHB+GTB9BCBLFB5BHBnCHBNFB1DKBfCBvCMMBCBiB4B4BBHBPBBLBBoDXBdJBHBBHBBHIBIII9BDB-DBBLFBl9KLBYDByBjoIBvLBBrDlBBILBGEBbGGCGDrUfBrBFB0BUUFDBGoEoEBCC-FCBHBBHBBHBBECBIIIBIBGBBNbbUDDQBBPhBB8DEBEDBuBCB5COOBBBCuBBvBhEBeCByBOBdDBlBIBfEBsBEBfmBmBBCBPpBB-EBBLFBlBDBlBDBpBHB1BKBNQQIDDMQQIDDBBB1BLB4JIBXJBJXBHrBrBKkCBHBBCtBtBDCBCBBYpCpCBGBKvBBUDDBDBiBCBcEBclBB5BDBVBBzBDDBDBJEEeBBEDBLGBKGBhCfBoBDBNIB3BCBeBBcEBbGBFLBIvCBqC2BB0BMB0BGBvBHBLFBnBCBeHBDvGBgBrBrBEBBDPBHHBKgBBvBHBrBVBblBBdTBYIBvCDBlBIBlCJBCBBaGBLFB2BTTBGBoBIBhDVVBJBTwBwBB8BBICCFQQMFB8BEBLFBFJJBDDBXXIDDGLLBDDBEEBCCBEBCEBIBBICBGKBLCCBCCnBLLCBBCFFLDDBGBDcB9CGGBcBpCHBLlFB3BBBnBhBBmCKBLFBOSB7BFBLFBVbBcBBQDBY4FB9BjDB0CLBJBBCBBJDDfDDBNNBHBLlCBJBBvBBBMaBpCHB0CMBqCGBL1CBJ3CBjBNBLFBKuBuBPJBeCBhBBBXPPBnCBIDDtBCBCDDKHBLFBHDDmBDDHGBLFBtBDBL1HBaGBSqBqBBBBe0CBCOBzBMB8clDBwDGGBJBlGryCBkDMB3iBJB88DEBoS41GB7Bl2BB6RGBgBLLBCByCLLBEBfBBHJBnCJBLIIWEBUvNB7BlGB8CEBaBBarBBsCDB6BGBS-BBGKBIIB3mHoBBhBgDB0D8vIBFIIDkJkJBNBCcBEBBCNBFHBtMjoCBsDEBOCBKGBLBBJ76DB+HCB1NFBYOBSOBvBBBYIB1D7BB3HJBoBBBjGUBnC5DBVLBVLB4CIBamEB2CoCoCDBBCBBDBBFNNCIIiCFFBJJIddFGGCCBI1K1KBlJlJB-V-VBNBGQQBuiBBgBFBH0GBISSBIIDGGBDB-BgBBCvDBuBCBPBBLDBD-JBgBQB7BEBCvOBrB1GBsBDBC-FBgBXXBGBD-GBIFFDQQmGBBRoBBtCDBLDBDwYBlCrCB+BhGBFccDCCBCCLFFCCCBEBCDBCECEDDCBBCICDCCBFFIKFCLLSEBEGGSzBBDtIBtBDBlDLBQBBQQQmBJBvF3BBeMBtBDBKGBDNBH5EB6eCBSCBOCB7GFBNDBCOBNDB5BHBLFBpBHBfBBNDBDNBKmBB5KHBPBBOCBMCB6BCCBCBRBBND
728BLGB0EoDoDBjgBBh3pBfB-oEBBv0FBBypHOBvThtCB-QhvBBs6EEBrpIm8yVBCdBhD-DBxHvw-FB",!1)),Vai:()=>new I(R("gopBrJ",!0)),Vithkuqi:()=>new I(R("wrhCKCOCGCBCKCOCGCB",!0)),Wancho:()=>new I(R("g24D5BGA",!0)),Warang_Citi:()=>new I(R("glmCyCNA",!0)),Yezidi:()=>new I(R("g0jCpBCCDB",!0)),Yi:()=>new I(R("ggoBskBE2B",!0)),Zanabazar_Square:()=>new I(R("gwmCnC",!0))})),me(ci,"FOLD_CATEGORIES",new fd({L:()=>new I(R("laA",!0)),LC:()=>new I(R("laA",!0)),Ll:()=>new I(R("hCZBmDWBCGBiBuBCEECDOCDuBCBECEBBCCCBCCBBBDDBCBBCCBEBBCBBCECBCCDCCBCCBBBCCCBEEIBBCBBCBBCOCDQCDBBCCCBBBC4BCIBBCBBDCCBCBCGC3HrBrBCEEJHHCCBCCCBCCBPBCIBkBJJCUCGDDCBBDyBBxBgBCK2BCBMCD+CCDlBBq6ClBBCGGzW1CB0kCHHBpBBDCBhK0ECKgDCKHBJFBLHBJHBJFBMGCJHBZHBJHBJHBJEBMEBMDBNEBMEBqJEEBHHxC9zC9zCBuBBxBCCBBBDGCBCBCDDJCBCgDCJCCFuqeuqeCqBCUaCoEMCE8BCLECBICFCCDCCEUCBDBCEBCOCBCBCCCBQCZs5Vs5VBYBmmBnBBpEjBB9EKBCOBCGBCBBr3ByBB+EVB75CfBhsVfBhCYBoyehBB",!1)),Lt:()=>new I(R("kOCCBCCBCClBCCtsHHBJHBJHBMQQwBAB",!1)),Lu:()=>new I(R("hDZB7BqBqBBWBCHBCuBCEECDOCDsBCDECBBBDCCDEEGDDECBDDDCCCDFFDEECDDECCGBBCBBCBBCOCBSCDBBCEECkBCEQCJDDBCCFICBEBCBBCCCBEEBCCBCBCEBDCCBDDIDDCBBEFBGLLBnFnFsBCCEEEBBBvBDBCdBCBBECBCWCBDBCGD1BvBBCgBCK0BCDMCBgDCyBlBBq6CqBBDCB5XFBjkCIBCvHvHERRzD0ECGGGC8CCBHBJFBLHBJHBJFBMGCJHBJNBzBBBNSSBPPBEEpL2B2Bs1CvBBCEEBGCHDDLiDCJCCFNNBkBBCGG0oesBCUaCoEMCE8BCLCCDICFFFCBBDSCMOCFCCDOCb9a9advCBi8UZBumBnBBpEjBB8EKBCOBCGBCBBk4ByBB+DVB75CfBhsVfB8BYBvyehBB",!1)),M:()=>new I(R("5cgBgBlgHAB",!1)),Mn:()=>new I(R("5cgBgBlgHAB",!1)),Emoji:()=>new I(R("8mJA",!0)),Extended_Pictographic:()=>new I(R("8mJA",!0)),Lowercase:()=>new I(R("hCZBmDWBCGBiBuBCEECDOCDuBCBECEBBCCCBCCBBBDDBCBBCCBEBBCBBCECBCCDCCBCCBBBCCCBEEIBBCBBCBBCOCDQCDBBCCCBBBC4BCIBBCBBDCCBCBCGCiJCCEJJHCCBBBCCCBCCBPBCIBkBJJCUCGDDCBBDyBBxBgBCK2BCBMCD+CCDlBBq6ClBBCGGzW1CB0kCHHBpBBDCBhK0ECKgDCKHBJFBLHBJHBJFBMGCJHBZHBJHBJHBJEBMEBMDBNEBMEBqJEEBHHuBPBUzZzZBYBx5BvBBxBCCBBBDGCBCBCDDJCBCgDCJCCFuqeuqeCqBCUaCoEMCE8BCLECBICFCCDCCEUCBDBCEBCOCBCBCCCBQCZs5Vs5VBYBmmBnBBpEjBB9EKBCOBCGBCBBr3ByBB+EVB75CfBhsVfBhCYBoyehBB",!1)),Math:()=>new I(R("ycGDCHHFMMDDDCHHFAB",!1)),Uppercase:()=>new I(R("hDZB7BqBqBBWBCHBCuBCEECDOCDsBCDECBBBDCCDEEGDDECBDDDCCCDFFDEECDDECCGBBCBBCBBCOCBSCDBBCEECkBCEQCJDDBCCFICBEBCBBCCCBEEBCCBCBCEBDCCBDDIDDCBBEFBGLLBnFnFsBCCEEEBBBvBDBCdBCBBECBCWCBDBCGD1BvBBCgBCK0BCDMCBgDCyBlBBq6CqBBDCB5XFBjkCIBCvHvHERRzD0ECGGGC8CCBHBJFBLHBJHBJFBMGCJHBJNBzBBBNSSBPPBEEpLiBiBBOBFsasaBYBn6BvBBCEEBGCHDDLiDCJCCFNNBkBBCGG0oesBCUaCoEMCE8BCLCCDICFFFCBBDSCMOCFCCDOCb9a9advCBi8UZBumBnBBpEjBB8EKBCOBCGBCBBk4ByBB+DVB75CfBhsVfB8BYBvyehBB",!1))})),me(ci,"FOLD_SCRIPT",new fd({Common:()=>new I(R("8cgBgB",!1)),Greek:()=>new I(R("1FwUwU",!1)),Inherited:()=>new I(R("5cgBgBlgHAB",!1))})),ci),St,we=(St=class{static is32(e,t){let n=0,i=e.length;for(;n<i;){const o=n+Math.floor((i-n)/2),u=e.getLo(o),B=e.getHi(o);if(u<=t&&t<=B){const f=e.getStride(o);return(t-u)%f===0}t<u?i=o:n=o+1}return!1}static is(e,t){if(t<=St.MAX_LATIN1){for(let n=0;n<e.length;n++){if(t>e.getHi(n))continue;const i=e.getLo(n);if(t<i)return!1;const o=e.getStride(n);return(t-i)%o===0}return!1}return e.length>0&&t>=e.getLo(0)&&St.is32(e,t)}static isUpper(e){if(e<=St.MAX_LATIN1){const t=String.fromCodePoint(e);return t.toUpperCase()===t&&t.toLowerCase()!==t}return St.is(as.Upper,e)}static isPrint(e){return e<=St.MAX_LATIN1?e>=32&&e<St.MAX_ASCII||e>=161&&e!==173:St.is(as.Print,e)}static simpleFold(e){if(as.CASE_ORBIT.has(e))return as.CASE_ORBIT.get(e);const t=te.toLowerCase(e);return t!==e?t:te.toUpperCase(e)}static equalsIgnoreCase(e,t){if(e===t)return!0;if(e<0||t<0)return!1;if(e<=St.MAX_ASCII&&t<=St.MAX_ASCII)return 65<=e&&e<=90&&(e|=32),65<=t&&t<=90&&(t|=32),e===t;for(let n=St.simpleFold(e);n!==e;n=St.simpleFold(n))if(n===t)return!0;return!1}},me(St,"MAX_RUNE",1114111),me(St,"MAX_ASCII",127),me(St,"MAX_LATIN1",255),me(St,"MAX_BMP",65535),me(St,"MIN_FOLD",65),me(St,"MAX_FOLD",125251),me(St,"MIN_HIGH_SURROGATE",55296),me(St,"MAX_HIGH_SURROGATE",56319),me(St,"MIN_LOW_SURROGATE",56320),me(St,"MAX_LOW_SURROGATE",57343),me(St,"MIN_SUPPLEMENTARY_CODE_POINT",65536),St);const oC=256,R1=new Uint8Array(oC);for(let r=0;r<oC;r++)R1[r]=97<=r&&r<=122||65<=r&&r<=90||48<=r&&r<=57||r===95?1:0;let tg=null,ng=null;var Vt,ke=(Vt=class{static emptyInts(){return[]}static isByteArray(e){return Array.isArray(e)||e instanceof Uint8Array}static isalnum(e){return te.CODES.get("0")<=e&&e<=te.CODES.get("9")||te.CODES.get("a")<=e&&e<=te.CODES.get("z")||te.CODES.get("A")<=e&&e<=te.CODES.get("Z")}static unhex(e){return te.CODES.get("0")<=e&&e<=te.CODES.get("9")?e-te.CODES.get("0"):te.CODES.get("a")<=e&&e<=te.CODES.get("f")?e-te.CODES.get("a")+10:te.CODES.get("A")<=e&&e<=te.CODES.get("F")?e-te.CODES.get("A")+10:-1}static escapeRune(e){let t="";if(we.isPrint(e))Vt.METACHARACTERS.indexOf(String.fromCodePoint(e))>=0&&(t+="\\"),t+=String.fromCodePoint(e);else switch(e){case te.CODES.get('"'):t+='\\"';break;case te.CODES.get("\\"):t+="\\\\";break;case te.CODES.get("	"):t+="\\t";break;case te.CODES.get(`
729`):t+="\\n";break;case te.CODES.get("\r"):t+="\\r";break;case te.CODES.get("\b"):t+="\\b";break;case te.CODES.get("\f"):t+="\\f";break;default:{let n=e.toString(16);e<256?(t+="\\x",n.length===1&&(t+="0"),t+=n):t+=`\\x{${n}}`;break}}return t}static stringToRunes(e){const t=String(e),n=[];let i=0;for(;i<t.length;){const o=t.codePointAt(i);n.push(o),i+=o>we.MAX_BMP?2:1}return n}static runeToString(e){return String.fromCodePoint(e)}static isWordRune(e){return e<oC?R1[e]===1:!1}static emptyOpContext(e,t){let n=0;return e<0&&(n|=Vt.EMPTY_BEGIN_TEXT|Vt.EMPTY_BEGIN_LINE),e===10&&(n|=Vt.EMPTY_BEGIN_LINE),t<0&&(n|=Vt.EMPTY_END_TEXT|Vt.EMPTY_END_LINE),t===10&&(n|=Vt.EMPTY_END_LINE),Vt.isWordRune(e)!==Vt.isWordRune(t)?n|=Vt.EMPTY_WORD_BOUNDARY:n|=Vt.EMPTY_NO_WORD_BOUNDARY,n}static quoteMeta(e){return e.split("").map(t=>Vt.METACHARACTERS.indexOf(t)>=0?`\\${t}`:t).join("")}static charCount(e){return e>we.MAX_BMP?2:1}static toArray(e){const t=e.length,n=new Array(t);for(let i=0;i<t;i++)n[i]=e[i];return n}static stringToUtf8ByteArray(e){if(globalThis.TextEncoder)return tg||(tg=new TextEncoder),tg.encode(e);{let t=[],n=0;for(let i=0;i<e.length;i++){let o=e.charCodeAt(i);o<128?t[n++]=o:o<2048?(t[n++]=o>>6|192,t[n++]=o&63|128):(o&64512)===we.MIN_HIGH_SURROGATE&&i+1<e.length&&(e.charCodeAt(i+1)&64512)===we.MIN_LOW_SURROGATE?(o=we.MIN_SUPPLEMENTARY_CODE_POINT+((o&1023)<<10)+(e.charCodeAt(++i)&1023),t[n++]=o>>18|240,t[n++]=o>>12&63|128,t[n++]=o>>6&63|128,t[n++]=o&63|128):(t[n++]=o>>12|224,t[n++]=o>>6&63|128,t[n++]=o&63|128)}return t}}static utf8ByteArrayToString(e){if(globalThis.TextDecoder){ng||(ng=new TextDecoder("utf-8"));const t=e instanceof Uint8Array?e:new Uint8Array(e);return ng.decode(t)}else{let t=[],n=0,i=0;for(;n<e.length;){let o=e[n++];if(o<128)t[i++]=String.fromCharCode(o);else if(o>191&&o<224){let u=e[n++];t[i++]=String.fromCharCode((o&31)<<6|u&63)}else if(o>239&&o<365){let u=e[n++],B=e[n++],f=e[n++],g=((o&7)<<18|(u&63)<<12|(B&63)<<6|f&63)-we.MIN_SUPPLEMENTARY_CODE_POINT;t[i++]=String.fromCharCode(we.MIN_HIGH_SURROGATE+(g>>10)),t[i++]=String.fromCharCode(we.MIN_LOW_SURROGATE+(g&1023))}else{let u=e[n++],B=e[n++];t[i++]=String.fromCharCode((o&15)<<12|(u&63)<<6|B&63)}}return t.join("")}}},me(Vt,"METACHARACTERS","\\.+*?()|[]{}^$"),me(Vt,"EMPTY_BEGIN_LINE",1),me(Vt,"EMPTY_END_LINE",2),me(Vt,"EMPTY_BEGIN_TEXT",4),me(Vt,"EMPTY_END_TEXT",8),me(Vt,"EMPTY_WORD_BOUNDARY",16),me(Vt,"EMPTY_NO_WORD_BOUNDARY",32),me(Vt,"EMPTY_ALL",-1),Vt);const O1=(r=[],e=0)=>{const t=Object.create(null);for(let n=0;n<r.length;n++){const i=r[n],o=e+n;t[i]=o,t[o]=i}return Object.freeze(t)};var pi,Il=(pi=class{getEncoding(){throw Error("not implemented")}asCharSequence(){throw Error("not implemented")}asBytes(){throw Error("not implemented")}length(){throw Error("not implemented")}isUTF8Encoding(){return this.getEncoding()===pi.Encoding.UTF_8}isUTF16Encoding(){return this.getEncoding()===pi.Encoding.UTF_16}},me(pi,"Encoding",O1(["UTF_16","UTF_8"])),pi),BE=class extends Il{constructor(r=null){super(),this.bytes=r}getEncoding(){return Il.Encoding.UTF_8}asCharSequence(){return ke.utf8ByteArrayToString(this.bytes)}asBytes(){return this.bytes}length(){return this.bytes.length}},sI=class extends Il{constructor(r=null){super(),this.charSequence=r}getEncoding(){return Il.Encoding.UTF_16}asCharSequence(){return this.charSequence}asBytes(){return ke.stringToUtf8ByteArray(this.charSequence.toString())}length(){return this.charSequence.length}},pl=class{static utf16(r){return new sI(r)}static utf8(r){return ke.isByteArray(r)?new BE(r):new BE(ke.stringToUtf8ByteArray(r))}},Yn=class{static EOF(){return-8}constructor(){this.end=0}canCheckPrefix(){return!0}endPos(){return this.end}hasString(){return!1}hasAnyString(){return!1}prefixLength(){return 0}},rI=class extends Yn{constructor(r,e=0,t=r.length){super(),this.bytes=r,this.start=e,this.end=t}hasString(r,e){const t=r.bytes;if(t.length===0)return!0;const n=this.indexOf(this.bytes,t,this.start+e);return n!==-1&&n<=this.end-t.length}hasAnyString(r,e){return r.ac8?r.ac8.searchUTF8(this.bytes,this.start+e,this.end):!1}step(r){if(r+=this.start,r>=this.end)return Yn.EOF();const e=this.bytes[r]&255;if(e<128)return e<<3|1;if(e>=194&&e<=223&&r+1<this.end){const t=this.bytes[r+1]&255;return(t&192)!==128?e<<3|1:((e&31)<<6|t&63)<<3|2}else if(e>=224&&e<=239&&r+2<this.end){const t=this.bytes[r+1]&255;if((t&192)!==128)return e<<3|1;const n=this.bytes[r+2]&255;return(n&192)!==128?e<<3|1:((e&15)<<12|(t&63)<<6|n&63)<<3|3}else if(e>=240&&e<=244&&r+3<this.end){const t=this.bytes[r+1]&255;if((t&192)!==128)return e<<3|1;const n=this.bytes[r+2]&255;if((n&192)!==128)return e<<3|1;const i=this.bytes[r+3]&255;return(i&192)!==128?e<<3|1:((e&7)<<18|(t&63)<<12|(n&63)<<6|i&63)<<3|4}else return e<<3|1}index(r,e){e+=this.start;const t=this.indexOf(this.bytes,r.prefixUTF8,e);return t<0?t:t-e}context(r){r+=this.start;let e=-1;if(r>this.start&&r<=this.end){let n=r-1;if(e=this.bytes[n--],e>=128){let i=r-4;for(i<this.start&&(i=this.start);n>=i&&(this.bytes[n]&192)===128;)n--;n<this.start&&(n=this.start),e=this.step(n-this.start)>>3}}const t=r<this.end?this.step(r-this.start)>>3:-1;return ke.emptyOpContext(e,t)}indexOf(r,e,t=0){let n=e.length;if(n===0)return t<=this.end?t:-1;const i=e[0];let o=this.end-n;const u=typeof r.indexOf=="function";let B=t;for(;B<=o;){if(u){if(B=r.indexOf(i,B),B===-1||B>
729o)return-1}else{for(;B<=o&&r[B]!==i;)B++;if(B>o)return-1}let f=!0;for(let g=1;g<n;g++)if(r[B+g]!==e[g]){f=!1;break}if(f)return B;B++}return-1}prefixLength(r){return r.prefixUTF8.length}},aI=class extends Yn{constructor(r,e=0,t=r.length){super(),this.charSequence=r,this.start=e,this.end=t}hasString(r,e){const t=this.charSequence.indexOf(r.str,this.start+e);return t!==-1&&t<=this.end-r.str.length}hasAnyString(r,e){return r.ac16?r.ac16.searchUTF16(this.charSequence,this.start+e,this.end):!1}step(r){if(r+=this.start,r>=this.end)return Yn.EOF();const e=this.charSequence.charCodeAt(r);if(e<we.MIN_HIGH_SURROGATE||e>we.MAX_HIGH_SURROGATE||r+1>=this.end)return e<<3|1;const t=this.charSequence.charCodeAt(r+1);return t>=we.MIN_LOW_SURROGATE&&t<=we.MAX_LOW_SURROGATE?(e-we.MIN_HIGH_SURROGATE)*1024+(t-we.MIN_LOW_SURROGATE)+we.MIN_SUPPLEMENTARY_CODE_POINT<<3|2:e<<3|1}index(r,e){e+=this.start;const t=this.charSequence.indexOf(r.prefix,e);return t<0||t>this.end-r.prefix.length?-1:t-e}context(r){r+=this.start;const e=r>this.start&&r<=this.end?this.charSequence.charCodeAt(r-1):-1,t=r<this.end?this.charSequence.charCodeAt(r):-1;return ke.emptyOpContext(e,t)}prefixLength(r){return r.prefix.length}},Pt=class{static fromUTF8(r,e=0,t=r.length){return new rI(r,e,t)}static fromUTF16(r,e=0,t=r.length){return new aI(r,e,t)}},IB=class extends Error{constructor(r){super(r),this.name="RE2JSException"}},kt=class extends IB{constructor(r,e=null){let t=`error parsing regexp: ${r}`;e&&(t+=`: \`${e}\``),super(t),this.name="RE2JSSyntaxException",this.message=t,this.error=r,this.input=e}getDescription(){return this.error}getPattern(){return this.input}},iI=class extends IB{constructor(r){super(r),this.name="RE2JSCompileException"}},rs=class extends IB{constructor(r){super(r),this.name="RE2JSGroupException"}},lI=class extends IB{constructor(r){super(r),this.name="RE2JSFlagsException"}},Qc=class extends IB{constructor(r){super(r),this.name="RE2JSInternalException"}},yl,hE=(yl=class{static quoteReplacement(e,t=!1){return t?e.indexOf("\\")<0&&e.indexOf("$")<0?e:e.split("").map(n=>{const i=n.codePointAt(0);return i===te.CODES.get("\\")||i===te.CODES.get("$")?`\\${n}`:n}).join(""):e.indexOf("$")<0?e:e.split("").map(n=>n.codePointAt(0)===te.CODES.get("$")?"$$":n).join("")}constructor(e,t){if(e===null)throw new Error("pattern is null");this.patternInput=e;const n=this.patternInput.re2();this.patternGroupCount=n.numberOfCapturingGroups(),this.groups=[],this.namedGroups=n.namedGroups,this.numberOfInstructions=n.numberOfInstructions(),t instanceof Il?this.resetMatcherInput(t):ke.isByteArray(t)?this.resetMatcherInput(pl.utf8(t)):this.resetMatcherInput(pl.utf16(t))}pattern(){return this.patternInput}reset(){return this.matcherInputLength=this.matcherInput.length(),this.appendPos=0,this.hasMatch=!1,this.hasGroups=!1,this.anchorFlag=0,this}resetMatcherInput(e){if(e===null)throw new Error("input is null");return e instanceof Il||(ke.isByteArray(e)?e=pl.utf8(e):e=pl.utf16(e)),this.matcherInput=e,this.reset(),this}start(e=0){if(typeof e=="string"){const t=this.namedGroups[e];if(!Number.isFinite(t))throw new rs(`group '${e}' not found`);e=t}return this.loadGroup(e),this.groups[2*e]}end(e=0){if(typeof e=="string"){const t=this.namedGroups[e];if(!Number.isFinite(t))throw new rs(`group '${e}' not found`);e=t}return this.loadGroup(e),this.groups[2*e+1]}programSize(){return this.numberOfInstructions}group(e=0){if(typeof e=="string"){const i=this.namedGroups[e];if(!Number.isFinite(i))throw new rs(`group '${e}' not found`);e=i}const t=this.start(e),n=this.end(e);return t<0&&n<0?null:this.substring(t,n)}getNamedGroups(){if(!this.hasMatch)throw new rs("perhaps no match attempted");const e=Object.create(null);for(const t of Object.keys(this.namedGroups))e[t]=this.group(t);return e}groupCount(){return this.patternGroupCount}loadGroup(e){if(e<0||e>this.patternGroupCount)throw new rs(`Group index out of bounds: ${e}`);if(!this.hasMatch)throw new rs("perhaps no match attempted");if(e===0||this.hasGroups)return;const t=this.matcherInputLength,n=this.patternInput.re2().matchMachineInput(this.matcherIn
729put,this.groups[0],t,this.anchorFlag,1+this.patternGroupCount);if(!n[0])throw new rs("inconsistency in matching group data");this.groups=n[1],this.hasGroups=!0}matches(){return this.genMatch(0,ue.ANCHOR_BOTH)}lookingAt(){return this.genMatch(0,ue.ANCHOR_START)}find(e=null){if(e!==null){if(e<0||e>this.matcherInputLength)throw new rs(`start index out of bounds: ${e}`);return this.reset(),this.genMatch(e,0)}if(e=0,this.hasMatch&&(e=this.groups[1],this.groups[0]===this.groups[1])){const t=(this.matcherInput.isUTF16Encoding()?Pt.fromUTF16(this.matcherInput.asCharSequence(),0,this.matcherInputLength):Pt.fromUTF8(this.matcherInput.asBytes(),0,this.matcherInputLength)).step(e);t<0?e++:e+=t&7}return this.genMatch(e,ue.UNANCHORED)}genMatch(e,t){const n=this.patternInput.re2().matchMachineInput(this.matcherInput,e,this.matcherInputLength,t,1);return n[0]?(this.groups=n[1],this.hasMatch=!0,this.hasGroups=this.patternGroupCount===0,this.anchorFlag=t,!0):(this.hasMatch=!1,!1)}substring(e,t){return this.matcherInput.isUTF8Encoding()?ke.utf8ByteArrayToString(this.matcherInput.asBytes().slice(e,t)):this.matcherInput.asCharSequence().substring(e,t).toString()}inputLength(){return this.matcherInputLength}appendReplacement(e,t=!1){let n="";const i=this.start(),o=this.end();return this.appendPos<i&&(n+=this.substring(this.appendPos,i)),this.appendPos=o,n+=t?this.appendReplacementInternalJava(e):this.appendReplacementInternalJs(e),n}appendReplacementInternalJava(e){let t="",n=0;const i=e.length;let o=0;for(;o<i;){const u=e.codePointAt(o);if(u===te.CODES.get("\\")){if(n<o&&(t+=e.substring(n,o)),o++,o>=i)throw new rs("character to be escaped is missing");n=o,o++;continue}if(u===te.CODES.get("$")){if(n<o&&(t+=e.substring(n,o)),o+1>=i)throw new rs("Illegal group reference: group index is missing");const B=e.codePointAt(o+1);if(te.CODES.get("0")<=B&&B<=te.CODES.get("9")){let f=B-te.CODES.get("0"),g=o+2;for(;g<i;g++){const b=e.codePointAt(g);if(b<te.CODES.get("0")||b>te.CODES.get("9")||f*10+b-te.CODES.get("0")>this.patternGroupCount)break;f=f*10+b-te.CODES.get("0")}if(f>this.patternGroupCount)throw new rs(`n > number of groups: ${f}`);const y=this.group(f);y!==null&&(t+=y),o=g,n=o}else if(B===te.CODES.get("{")){let f=o+2;for(;f<i&&e.codePointAt(f)!==te.CODES.get("}");)f++;if(f>=i)throw new rs("named capture group is missing trailing '}'");const g=e.substring(o+2,f),y=this.group(g);y!==null&&(t+=y),o=f+1,n=o}else throw new rs("Illegal group reference");continue}o++}return n<i&&(t+=e.substring(n,i)),t}appendReplacementInternalJs(e){let t="",n=0;const i=e.length;for(let o=0;o<i-1;o++)if(e.codePointAt(o)===te.CODES.get("$")){let u=e.codePointAt(o+1);if(te.CODES.get("$")===u){n<o&&(t+=e.substring(n,o)),t+="$",o++,n=o+1;continue}else if(te.CODES.get("&")===u){n<o&&(t+=e.substring(n,o));const B=this.group(0);B!==null?t+=B:t+="$&",o++,n=o+1;continue}else if(te.CODES.get("`")===u){n<o&&(t+=e.substring(n,o)),t+=this.substring(0,this.start(0)),o++,n=o+1;continue}else if(te.CODES.get("'")===u){n<o&&(t+=e.substring(n,o)),t+=this.substring(this.end(0),this.matcherInputLength),o++,n=o+1;continue}else if(te.CODES.get("1")<=u&&u<=te.CODES.get("9")){let B=u-te.CODES.get("0");for(n<o&&(t+=e.substring(n,o)),o+=2;o<i&&(u=e.codePointAt(o),!(u<te.CODES.get("0")||u>te.CODES.get("9")||B*10+u-te.CODES.get("0")>this.patternGroupCount));o++)B=B*10+u-te.CODES.get("0");if(B>this.patternGroupCount){t+=`$${B}`,n=o,o--;continue}const f=this.group(B);f!==null&&(t+=f),n=o,o--;continue}else if(u===te.CODES.get("<")){n<o&&(t+=e.substring(n,o)),o++;let B=o+1;for(;B<e.length&&e.codePointAt(B)!==te.CODES.get(">")&&e.codePointAt(B)!==te.CODES.get(" ");)B++;if(B===e.length||e.codePointAt(B)!==te.CODES.get(">")){t+=e.substring(o-1,B+1),n=B+1,o=B;continue}const f=e.substring(o+1,B);if(Object.prototype.hasOwnProperty.call(this.namedGroups,f)){const g=this.group(f);g!==null&&(t+=g)}else t+=`$<${f}>`;n=B+1,o=B;continue}}return n<i&&(t+=e.substring(n,i)),t}appendTail(){return this.substring(this.appendPos,this.matcherInputLength)}replaceAll(e,t=!1){return this.replace(e,!0,t)}replaceFirst(e,t=!1){return this.replace(e,!1,t)}replace(e,t=!0,n=!1){let i="";this.reset();const o=typeof e=="function",u=Object.keys(this.namedGroups).length>0;let B=null;if(o){if(this.groupCount()>=yl.MAX_REPLACER_ARGS)throw new rs("Too many capture groups to safely invoke replacer function");
729B=this.matcherInput.isUTF8Encoding()?this.matcherInput.asBytes():this.matcherInput.asCharSequence()}for(;this.find()&&(i+=o?this.appendReplacementFunc(e,u,B):this.appendReplacement(e,n),!!t););return i+=this.appendTail(),i}appendReplacementFunc(e,t,n){let i="";const o=this.start(),u=this.end();this.appendPos<o&&(i+=this.substring(this.appendPos,o)),this.appendPos=u;const B=this.buildReplacerArgs(o,t,n);return i+=String(e(...B)),i}buildReplacerArgs(e,t,n){const i=[this.group(0)],o=this.groupCount();for(let u=1;u<=o;u++){const B=this.start(u);B<0?i.push(void 0):i.push(this.substring(B,this.end(u)))}if(i.push(e),i.push(n),t){const u=this.getNamedGroups();for(const B in u)u[B]===null&&(u[B]=void 0);i.push(u)}return i}},me(yl,"MAX_REPLACER_ARGS",65535),yl),at,ne=(at=class{static isRuneOp(e){return at.RUNE<=e&&e<=at.RUNE_ANY_NOT_NL}static escapeRunes(e){let t='"';for(let n of e)t+=ke.escapeRune(n);return t+='"',t}constructor(e){this.op=e,this.out=0,this.arg=0,this.runes=[],this.next=null}matchRune(e){if(this.runes.length===1){const u=this.runes[0];return(this.arg&ue.FOLD_CASE)!==0?we.equalsIgnoreCase(u,e):e===u}const t=this.runes.length;if(t===0)return!1;if(t===2||t===4||t===6||t===8){for(let u=0;u<t;u+=2){if(e<this.runes[u])return!1;if(e<=this.runes[u+1])return!0}return!1}let n=0,i=t>>1;for(;i>1;){const u=i>>1;n+=this.runes[n+u<<1]<=e?u:0,i-=u}n+=this.runes[n<<1]<=e?1:0;const o=n-1;return o>=0&&e<=this.runes[o<<1|1]}matchRunePos(e){if(this.runes.length===1){const u=this.runes[0];return(this.arg&ue.FOLD_CASE)!==0?we.equalsIgnoreCase(u,e)?0:-1:e===u?0:-1}const t=this.runes.length;if(t===0)return-1;if(t===2||t===4||t===6||t===8){for(let u=0;u<t;u+=2){if(e<this.runes[u])return-1;if(e<=this.runes[u+1])return Math.floor(u/2)}return-1}let n=0,i=t>>1;for(;i>1;){const u=i>>1;n+=this.runes[n+u<<1]<=e?u:0,i-=u}n+=this.runes[n<<1]<=e?1:0;const o=n-1;return o>=0&&e<=this.runes[o<<1|1]?o:-1}toString(){switch(this.op){case at.ALT:return`alt -> ${this.out}, ${this.arg}`;case at.ALT_MATCH:return`altmatch -> ${this.out}, ${this.arg}`;case at.CAPTURE:return`cap ${this.arg} -> ${this.out}`;case at.EMPTY_WIDTH:return`empty ${this.arg} -> ${this.out}`;case at.MATCH:return`match${this.arg!==0?` ${this.arg}`:""}`;case at.FAIL:return"fail";case at.NOP:return`nop -> ${this.out}`;case at.LB_WRITE:return`lbwrite ${this.arg} -> ${this.out}`;case at.LB_CHECK:return`lbcheck ${this.arg} -> ${this.out}`;case at.RUNE:return this.runes===null?"rune <null>":["rune ",at.escapeRunes(this.runes),(this.arg&ue.FOLD_CASE)!==0?"/i":""," -> ",this.out].join("");case at.RUNE1:return`rune1 ${at.escapeRunes(this.runes)} -> ${this.out}`;case at.RUNE_ANY:return`any -> ${this.out}`;case at.RUNE_ANY_NOT_NL:return`anynotnl -> ${this.out}`;default:throw new Error("unhandled case in Inst.toString")}}},me(at,"ALT",1),me(at,"ALT_MATCH",2),me(at,"CAPTURE",3),me(at,"EMPTY_WIDTH",4),me(at,"FAIL",5),me(at,"MATCH",6),me(at,"NOP",7),me(at,"RUNE",8),me(at,"RUNE1",9),me(at,"RUNE_ANY",10),me(at,"RUNE_ANY_NOT_NL",11),me(at,"LB_WRITE",12),me(at,"LB_CHECK",13),at),dE=class{constructor(r){this.sparse=new Int32Array(r),this.densePcs=new Int32Array(r),this.denseCaps=null,this.size=0,this.ncap=0}init(r){this.ncap=r;const e=this.densePcs.length*r;(!this.denseCaps||this.denseCaps.length<e)&&(this.denseCaps=new Int32Array(e))}contains(r){const e=this.sparse[r];return e<this.size&&this.densePcs[e]===r}isEmpty(){return this.size===0}add(r){const e=this.size++;return this.sparse[r]=e,this.densePcs[e]=r,e}clear(){this.size=0}toString(){let r="{";for(let e=0;e<this.size;e++)e!==0&&(r+=", "),r+=this.densePcs[e];return r+="}",r}},oI=class vg{static fromRE2(e){const t=new vg;return t.prog=e.prog,t.re2=e,t.q0=new dE(t.prog.numInst()),t.q1=new dE(t.prog.numInst()),t.matched=!1,t.matchcap=new Int32Array(t.prog.numCap<2?2:t.prog.numCap),t.ncap=0,t}static fromMachine(e){return vg.fromRE2(e.re2)}constructor(){this.prog=null,this.re2=null,this.q0=null,this.q1=null,this.matched=!1,this.matchcap=null,this.ncap=0,this.lbTable=null}init(e){this.ncap=e,e>this.matchcap.length?this.matchcap=new Int32Array(e).fill(-1):this.matchcap.fill(-1),this.q0.init(e),this.q1.init(e),this.prog.numLb>0&&((!this.lbTable||this.lbTable.length<this.prog.numLb+1)&&(this.lbTable=new Int32Array(this.prog.numLb+1)),this.lbTable.fill(-1))}submatches(){return this.ncap===0?ke.emptyInts():ke.toArray(this.matchcap.subarray(0,this.ncap))}
729match(e,t,n){const i=this.re2.cond;if(i===ke.EMPTY_ALL||(n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&t!==0)return!1;this.matched=!1,this.matchcap.fill(-1);let o=this.prog.numLb>0?0:t,u=t,B=this.q0,f=this.q1,g=e.step(o),y=g>>3,b=g&7,D=-1,T=0;g!==Yn.EOF()&&(g=e.step(o+b),D=g>>3,T=g&7);let M;for(o===0?M=ke.emptyOpContext(-1,y):M=e.context(o);;){if(B.isEmpty()){if((i&ke.EMPTY_BEGIN_TEXT)!==0&&o!==0||(n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&o!==0||this.matched)break;if(this.prog.numLb===0&&this.re2.prefix.length!==0&&D!==this.re2.prefixRune&&e.canCheckPrefix()){const K=e.index(this.re2,o);if(K<0)break;o+=K,g=e.step(o),y=g>>3,b=g&7,g=e.step(o+b),D=g>>3,T=g&7,M=e.context(o)}}if(o===0&&this.prog.numLb>0)for(let K=0;K<this.prog.lbStarts.length;K++)this.add(B,this.prog.lbStarts[K],o,this.matchcap,0,M);!this.matched&&(o===0||n===ue.UNANCHORED)&&o>=u&&(this.ncap>0&&(this.matchcap[0]=o),this.add(B,this.prog.start,o,this.matchcap,0,M));const z=o+b;if(M=e.context(z),this.step(B,f,o,z,y,M,n,o===e.endPos()),b===0||this.ncap===0&&this.matched)break;o+=b,y=D,b=T,y!==-1&&(g=e.step(o+b),D=g>>3,T=g&7);const W=B;B=f,f=W}return f.clear(),this.matched}matchSet(e,t,n){const i=this.re2.cond;if(i===ke.EMPTY_ALL)return[];if((n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&t!==0)return[];let o=this.prog.numLb>0?0:t,u=t,B=this.q0,f=this.q1,g=e.step(o),y=g>>3,b=g&7,D=-1,T=0;g!==Yn.EOF()&&(g=e.step(o+b),D=g>>3,T=g&7);let M=o===0?ke.emptyOpContext(-1,y):e.context(o);const z=new Set;for(;!(B.isEmpty()&&((i&ke.EMPTY_BEGIN_TEXT)!==0&&o!==0||(n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&o!==0));){if(o===0&&this.prog.numLb>0)for(let he=0;he<this.prog.lbStarts.length;he++)this.add(B,this.prog.lbStarts[he],o,this.matchcap,0,M);(o===0||n===ue.UNANCHORED)&&o>=u&&this.add(B,this.prog.start,o,this.matchcap,0,M);const W=o+b;M=e.context(W);for(let he=0;he<B.size;he++){const de=B.densePcs[he],ce=this.prog.inst[de],_e=he*this.ncap;let ye=!1;switch(ce.op){case ne.MATCH:if(n===ue.ANCHOR_BOTH&&o!==e.endPos())break;z.add(ce.arg);break;case ne.RUNE:ye=ce.matchRune(y);break;case ne.RUNE1:ye=y===ce.runes[0];break;case ne.RUNE_ANY:ye=!0;break;case ne.RUNE_ANY_NOT_NL:ye=y!==10;break;default:continue}ye&&this.add(f,ce.out,W,B.denseCaps,_e,M)}if(B.clear(),b===0)break;o+=b,y=D,b=T,y!==-1&&(g=e.step(o+b),D=g>>3,T=g&7);const K=B;B=f,f=K}return f.clear(),Array.from(z).sort((W,K)=>W-K)}step(e,t,n,i,o,u,B,f){const g=this.re2.longest;for(let y=0;y<e.size;y++){const b=e.densePcs[y],D=y*this.ncap;if(g&&this.matched&&this.ncap>0&&this.matchcap[0]<e.denseCaps[D])continue;const T=this.prog.inst[b];let M=!1;switch(T.op){case ne.MATCH:if(B===ue.ANCHOR_BOTH&&!f)break;if(this.ncap>0&&(!g||!this.matched||this.matchcap[1]<n)){e.denseCaps[D+1]=n;for(let z=0;z<this.ncap;z++)this.matchcap[z]=e.denseCaps[D+z]}g||(e.size=0),this.matched=!0;break;case ne.RUNE:M=T.matchRune(o);break;case ne.RUNE1:M=o===T.runes[0];break;case ne.RUNE_ANY:M=!0;break;case ne.RUNE_ANY_NOT_NL:M=o!==10;break;default:continue}M&&this.add(t,T.out,i,e.denseCaps,D,u)}e.clear()}add(e,t,n,i,o,u){for(;;){if(t===0||e.contains(t))return;const B=e.add(t),f=this.prog.inst[t];switch(f.op){case ne.FAIL:return;case ne.ALT:case ne.ALT_MATCH:this.add(e,f.out,n,i,o,u),t=f.arg;continue;case ne.EMPTY_WIDTH:if((f.arg&~u)===0){t=f.out;continue}return;case ne.NOP:t=f.out;continue;case ne.CAPTURE:if(f.arg<this.ncap){const g=i[o+f.arg];i[o+f.arg]=n,this.add(e,f.out,n,i,o,u),i[o+f.arg]=g;return}else{t=f.out;continue}case ne.LB_WRITE:this.lbTable[Math.abs(f.arg)]=n,t=f.out;continue;case ne.LB_CHECK:if(f.arg>0){if(this.lbTable[f.arg]===n){t=f.out;continue}}else if(this.lbTable[-f.arg]!==n){t=f.out;continue}return;case ne.MATCH:case ne.RUNE:case ne.RUNE1:case ne.RUNE_ANY:case ne.RUNE_ANY_NOT_NL:if(this.ncap>0){const g=B*this.ncap;for(let y=0;y<this.ncap;y++)e.denseCaps[g+y]=i[o+y]}return;default:throw new Qc("unhandled")}}}};const fE=r=>{let e=-2128831035;for(let t=0;t<r.length;t++)e^=r[t],e=Math.imul(e,16777619);return e},uI=(r,e)=>{if(r.length!==e.length)return!1;for(let t=0;t<r.length;t++)if(r[t]!==e[t])return!1;return!0};var cI=class{constructor(r,e,t=[]){this.nfaStates=r,this.isMatch=e,this.matchIDs=t,this.nextLatin1=new Array(we.MAX_LATIN1+1).fill(null),this.nextLatin1Anchored=new Array(we.MAX_LATIN1+1).fill(null),this.transKeys=[],this.transVals=[],this.lastSeen=0}},ha,BI=(ha=class{constructor(e,t=8388608){this.prog=e,this.stateCache=new Map,this.stateCount=0,this.startState=null,this.stateLimit=Math.max(1,Math.floor(t/ha.STATE_MEMORY_ESTIMATE)),this.cacheClears=0,this.failed=!1,this.clock=0}computeClosure(e){const t=new Set,n=[...e];let i=!1;const o=[];for(;n.length>0;){const B=n.pop();if(t.has(B))continue;t.add(B);const f=this.prog.getInst(B);switch(f.op){case ne.MATCH:i=!0,o.includes(f.arg)||o.push(f.arg);break;case ne.ALT:case ne.ALT_MATCH:n.push(f.out),n.push(f.arg);break;case ne.NOP:case ne.CAPTURE:n.push(f.out);break;case ne.EMPTY_WIDTH:case ne.LB_WRITE:case ne.LB_CHECK:return null}}const u=Int32Array.from(t).sort();return o.sort((B,f)=>B-f),{pcs:u,isMatch:i,matchIDs:o}}getState(e){const t=this.computeClosure(e);
729if(!t)return null;const n=t.pcs,i=fE(n);let o=this.stateCache.get(i);if(o)for(let B=0;B<o.length;B++){const f=o[B];if(uI(f.nfaStates,n))return f.lastSeen=++this.clock,f}else o=[],this.stateCache.set(i,o);if(this.failed)return null;if(this.stateCount>=this.stateLimit){if(this.cacheClears++,this.cacheClears>=ha.MAX_CACHE_CLEARS)return this.failed=!0,this.stateCache.clear(),this.stateCount=0,this.startState=null,null;this.evictCache(),o=this.stateCache.get(i),o||(o=[],this.stateCache.set(i,o))}const u=new cI(n,t.isMatch,t.matchIDs);return u.lastSeen=++this.clock,o.push(u),this.stateCount++,u}evictCache(){const e=[];for(const u of this.stateCache.values())for(let B=0;B<u.length;B++)e.push(u[B]);e.sort((u,B)=>u.lastSeen-B.lastSeen);const t=Math.max(1,Math.floor(this.stateLimit/2)),n=e.length-t,i=e.slice(n),o=new Set(i);this.stateCache.clear(),this.stateCount=0;for(let u=0;u<i.length;u++){const B=i[u];B.nextLatin1.fill(null),B.nextLatin1Anchored.fill(null),B.transKeys.length=0,B.transVals.length=0;const f=fE(B.nfaStates);let g=this.stateCache.get(f);g||(g=[],this.stateCache.set(f,g)),g.push(B),this.stateCount++}this.startState&&!o.has(this.startState)&&(this.startState=null)}step(e,t,n){if(t<=we.MAX_LATIN1)if(n===ue.UNANCHORED){const u=e.nextLatin1[t];if(u!==null)return u}else{const u=e.nextLatin1Anchored[t];if(u!==null)return u}else{const u=t+(n===ue.UNANCHORED?0:we.MAX_RUNE+1),B=e.transKeys,f=B.length;for(let g=0;g<f;g++)if(B[g]===u)return e.transVals[g]}const i=[];for(let u=0;u<e.nfaStates.length;u++){const B=e.nfaStates[u],f=this.prog.getInst(B);ne.isRuneOp(f.op)&&f.matchRune(t)&&i.push(f.out)}n===ue.UNANCHORED&&i.push(this.prog.start);const o=this.getState(i);if(t<=we.MAX_LATIN1)n===ue.UNANCHORED?e.nextLatin1[t]=o:e.nextLatin1Anchored[t]=o;else{const u=t+(n===ue.UNANCHORED?0:we.MAX_RUNE+1);e.transKeys.push(u),e.transVals.push(o)}return o}match(e,t,n){if((n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&t!==0)return!1;if(!this.startState&&(this.startState=this.getState([this.prog.start]),!this.startState))return null;let i=e.endPos(),o=this.startState;if(o.isMatch)if(n===ue.ANCHOR_BOTH){if(t===i)return!0}else return!0;let u=t;for(;u<i;){const B=e.step(u),f=B>>3,g=B&7;if(g===0)break;if(o=n===ue.UNANCHORED&&f<=we.MAX_LATIN1&&o.nextLatin1[f]||this.step(o,f,n),o===null)return null;if(o.lastSeen=++this.clock,o.isMatch)if(n===ue.ANCHOR_BOTH){if(u+g===i)return!0}else return!0;if(o.nfaStates.length===0&&n!==ue.UNANCHORED)return!1;u+=g}return!1}matchSet(e,t,n){if((n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&t!==0)return[];if(!this.startState&&(this.startState=this.getState([this.prog.start]),!this.startState))return null;let i=e.endPos(),o=this.startState;const u=new Set,B=(g,y)=>{g.isMatch&&(n===ue.ANCHOR_BOTH?y===i&&g.matchIDs.forEach(b=>u.add(b)):g.matchIDs.forEach(b=>u.add(b)))};B(o,t);let f=t;for(;f<i;){const g=e.step(f),y=g>>3,b=g&7;if(b===0)break;if(o=n===ue.UNANCHORED&&y<=we.MAX_LATIN1&&o.nextLatin1[y]||this.step(o,y,n),o===null)return null;if(o.lastSeen=++this.clock,f+=b,B(o,f),o.nfaStates.length===0&&n!==ue.UNANCHORED)break}return Array.from(u).sort((g,y)=>g-y)}},me(ha,"MAX_CACHE_CLEARS",5),me(ha,"STATE_MEMORY_ESTIMATE",838),ha);const hI=32,dI=500,sg=256,fI=256*1024;var mI=class{constructor(){this.end=0,this.cap=new Int32Array(0),this.matchcap=new Int32Array(0),this.ncap=0,this.jobPc=new Int32Array(sg),this.jobArg=new Uint8Array(sg),this.jobPos=new Int32Array(sg),this.jobLen=0,this.visited=new Uint32Array(0)}reset(r,e,t){this.end=e,this.jobLen=0,this.ncap=t;const n=r.numInst()*(e+1)+hI-1>>>5;this.visited.length<n?this.visited=new Uint32Array(n):this.visited.fill(0,0,n),this.cap.length<t?this.cap=new Int32Array(t).fill(-1):this.cap.fill(-1,0,t),this.matchcap.length<t?this.matchcap=new Int32Array(t).fill(-1):this.matchcap.fill(-1,0,t)}shouldVisit(r,e){const t=r*(this.end+1)+e,n=t>>>5,i=1<<(t&31);return(this.visited[n]&i)!==0?!1:(this.visited[n]|=i,!0)}push(r,e,t,n){if(r.prog.getInst(e).op!==ne.FAIL&&(n||this.shouldVisit(e,t))){if(this.jobLen>=this.jobPc.length){const i=this.jobPc.length*2,o=new Int32Array(i);o.set(this.jobPc),this.jobPc=o;const u=new Uint8Array(i);u.set(this.jobArg),this.jobArg=u;const B=new Int32Array(i);B.set(this.jobPos),this.jobPos=B}this.jobPc[this.jobLen]=e,this.jobArg[this.jobLen]=n?1:0,this.jobPos[this.jobLen]=t,this.jobLen++}}tryBacktrack(r,e,t,n,i){const o=r.longest;for(this.push(r,t,n,!1);this.jobLen>0;){this.jobLen--;let u=this.jobPc[this.jobLen],B=this.jobArg[this.jobLen]===1,f=this.jobPos[this.jobLen],g=!0;for(;!(!g&&!this.shouldVisit(u,f));){g=!1;const y=r.prog.getInst(u);switch(y.op){case ne.FAIL:throw new Qc("unexpected InstFail");case ne.ALT:if(B){B=!1,u=y.arg;continue}else{this.push(r,u,f,!0),u=y.out;continue}case ne.ALT_MATCH:{const b=r.prog.getInst(y.out);if(ne.isRuneOp(b.op)){this.push(r,y.arg,f,!1),u=y.arg,f=this.end;continue}this.push(r,y.out,this.end,!1),u=y.out;continue}case ne.RUNE:{const b=e.step(f);if(b===Yn.EOF()||!y.matchRune(b>>3))break;f+=b&7,u=y.out;continue}case ne.RUNE1:{const b=e.step(f);if(b===Yn.EOF()||b>>3!==y.runes[0])break;f+=b&7,u=y.out;continue}case ne.RUNE_ANY_NOT_NL:{const b=e.step(f);if(b===Yn.EOF()||b>>3===10)break;f+=b&7,u=y.out;continue}case ne.RUNE_ANY:{const b=e.step(f);if(b===Yn.EOF())break;f+=b&7,u=y.out;continue}case ne.CAPTURE:if(B){this.cap[y.arg]=f;break}else{y.arg<this.ncap&&(this.push(r,u,this.cap[y.arg],!0),this.cap[y.arg]=f),u=y.out;continue}case ne.EMPTY_WIDTH:{const b=e.context(f);if((y.arg&~b)!==0)break;u=y.out;continue}case ne.NOP:u=y.out;continue;case ne.MATCH:{if(i===ue.ANCHOR_BOTH&&f!==this.end)break;if(this.ncap===0)return!0;this.ncap>1&&(this.cap[1]=f);const b=this.matchcap[1];if((b===-1||o&&f>0&&f>b)&&this.matchcap.set(this.cap),!o||f===this.end)return!0;break}case ne.LB_WRITE:case ne.LB_CHECK:throw new Qc("Backtracker cannot evaluate Lookbehind instructions");default:throw new Qc("bad inst")}break}}return o&&this.matchcap.length>1&&this.matchcap[1]>=0}};const md=[];var pd=class k1{static shouldBacktrack(e){return e.numInst()<=dI}static maxBitStateLen(e){return k1.shouldBacktrack(e)?Math.floor(fI/e.numInst()):0}static execute(e,t,n,i,o){const u=e.cond;if(u===ke.EMPTY_ALL||(i===ue.ANCHOR_START||i===ue.ANCHOR_BOTH)&&n!==0||(u&ke.EMPTY_BEGIN_TEXT)!==0&&n!==0)return null;const B=md.length>0?md.pop():new mI,f=t.endPos();B.reset(e.prog,f,o);let g=!1;if((u&ke.EMPTY_BEGIN_TEXT)!==0||i===ue.ANCHOR_START||i===ue.ANCHOR_BOTH)B.ncap>0&&(B.cap[0]=n),B.tryBacktrack(e,t,e.prog.start,n,i)&&(g=!0);else{let b=-1;for(;n<=f&&b!==0;n+=b){if(e.prefix.length>0){const T=t.index(e,n);if(T<0)break;n+=T}if(B.ncap>
7290&&(B.cap[0]=n),B.tryBacktrack(e,t,e.prog.start,n,i)){g=!0;break}const D=t.step(n);b=D===Yn.EOF()?0:D&7}}if(!g)return md.push(B),null;const y=o===0?[]:ke.toArray(B.matchcap.subarray(0,o));return md.push(B),y}},mE=class{constructor(r){this.sparse=new Uint32Array(r),this.dense=new Uint32Array(r),this.size=0,this.nextIndex=0}empty(){return this.nextIndex>=this.size}next(){return this.dense[this.nextIndex++]}clear(){this.size=0,this.nextIndex=0}contains(r){return r<this.sparse.length&&this.sparse[r]<this.size&&this.dense[this.sparse[r]]===r}insert(r){this.contains(r)||this.insertNew(r)}insertNew(r){r>=this.sparse.length||(this.sparse[r]=this.size,this.dense[this.size]=r,this.size++)}};const pI=(r,e,t,n)=>{const i=r.length,o=e.length;let u=0,B=0;const f=[],g=[];let y=!0,b=-1;const D=T=>{const M=T?r:e,z=T?u:B,W=T?t:n;return b>0&&M[z]<=f[b]?!1:(f.push(M[z],M[z+1]),T?u+=2:B+=2,b+=2,g.push(W),!0)};for(;u<i||B<o;)if(B>=o?y=D(!0):u>=i||e[B]<r[u]?y=D(!1):y=D(!0),!y)return null;return{merged:f,next:g}};var gI=class{constructor(r){this.start=r.start,this.numCap=r.numCap,this.inst=new Array(r.inst.length);for(let e=0;e<r.inst.length;e++){const t=r.inst[e],n=new ne(t.op);n.out=t.out,n.arg=t.arg,n.runes=t.runes?t.runes.slice():[],n.next=null,this.inst[e]=n}}};const CI=r=>{const e=new gI(r);for(let t=0;t<e.inst.length;t++){const n=e.inst[t];if(n.op!==ne.ALT&&n.op!==ne.ALT_MATCH)continue;let i="out",o="arg",u=e.inst[n[o]];if(u.op!==ne.ALT&&u.op!==ne.ALT_MATCH&&(i="arg",o="out",u=e.inst[n[o]],u.op!==ne.ALT&&u.op!==ne.ALT_MATCH))continue;const B=e.inst[n[i]];if(B.op===ne.ALT||B.op===ne.ALT_MATCH)continue;let f="out",g="arg",y=!1;u.out===t?y=!0:u.arg===t&&(y=!0,f="arg",g="out"),y&&(u[f]=n[i]),n[i]===u[f]&&(n[o]=u[g])}return e},yI=r=>{if(r.inst.length>=1e3)return null;const e=new mE(r.inst.length),t=new mE(r.inst.length),n=new Array(r.inst.length),i=new Array(r.inst.length).fill(!1),o=u=>{let B=!0;const f=r.inst[u];if(t.contains(u))return!0;switch(t.insert(u),f.op){case ne.ALT:case ne.ALT_MATCH:{B=o(f.out)&&o(f.arg);let g=i[f.out],y=i[f.arg];if(g&&y)return!1;if(y){const M=f.out;f.out=f.arg,f.arg=M;const z=g;g=y,y=z}g&&(i[u]=!0,f.op=ne.ALT_MATCH);const b=n[f.out]||[],D=n[f.arg]||[],T=pI(b,D,f.out,f.arg);
729if(!T)return!1;n[u]=T.merged,f.next=new Uint32Array(T.next);break}case ne.CAPTURE:case ne.EMPTY_WIDTH:case ne.NOP:B=o(f.out),i[u]=i[f.out],n[u]=n[f.out]?n[f.out].slice():[],f.next=new Uint32Array(Math.floor(n[u].length/2)+1).fill(f.out);break;case ne.MATCH:case ne.FAIL:i[u]=f.op===ne.MATCH;break;case ne.RUNE:{if(i[u]=!1,f.next&&f.next.length>0)break;if(e.insert(f.out),!f.runes||f.runes.length===0){n[u]=[],f.next=new Uint32Array([f.out]);break}let g=[];if(f.runes.length===1&&(f.arg&ue.FOLD_CASE)!==0){const y=f.runes[0];g.push(y,y);for(let b=we.simpleFold(y);b!==y;b=we.simpleFold(b))g.push(b,b);g.sort((b,D)=>b-D)}else for(let y=0;y<f.runes.length;y++)g.push(f.runes[y]);n[u]=g,f.next=new Uint32Array(Math.floor(g.length/2)+1).fill(f.out),f.op=ne.RUNE;break}case ne.RUNE1:{if(i[u]=!1,f.next&&f.next.length>0)break;e.insert(f.out);let g=[];if((f.arg&ue.FOLD_CASE)!==0){const y=f.runes[0];g.push(y,y);for(let b=we.simpleFold(y);b!==y;b=we.simpleFold(b))g.push(b,b);g.sort((b,D)=>b-D)}else g.push(f.runes[0],f.runes[0]);n[u]=g,f.next=new Uint32Array(Math.floor(g.length/2)+1).fill(f.out),f.op=ne.RUNE;break}case ne.RUNE_ANY:if(i[u]=!1,f.next&&f.next.length>0)break;e.insert(f.out),n[u]=[0,we.MAX_RUNE],f.next=new Uint32Array([f.out]);break;case ne.RUNE_ANY_NOT_NL:if(i[u]=!1,f.next&&f.next.length>0)break;e.insert(f.out),n[u]=[0,9,11,we.MAX_RUNE],f.next=new Uint32Array(Math.floor(n[u].length/2)+1).fill(f.out);break}return B};for(e.clear(),e.insert(r.start);!e.empty();)if(t.clear(),!o(e.next()))return null;for(let u=0;u<r.inst.length;u++)n[u]&&(r.inst[u].runes=n[u]);return r},bI=(r,e)=>{for(let t=0;t<e.inst.length;t++){const n=e.inst[t];switch(n.op){case ne.ALT:case ne.ALT_MATCH:case ne.RUNE:break;case ne.CAPTURE:case ne.EMPTY_WIDTH:case ne.NOP:case ne.MATCH:case ne.FAIL:r.inst[t].next=null;break;case ne.RUNE1:case ne.RUNE_ANY:case ne.RUNE_ANY_NOT_NL:r.inst[t].next=null,r.inst[t].op=n.op,r.inst[t].runes=n.runes?n.runes.slice():[];break}}};var pE=class L1{static compile(e){if(e.start===0||e.numLb>0)return null;const t=e.inst[e.start];if(t.op!==ne.EMPTY_WIDTH||(t.arg&ke.EMPTY_BEGIN_TEXT)===0)return null;let n=!1;for(let o=0;o<e.inst.length;o++)if(e.inst[o].op===ne.ALT||e.inst[o].op===ne.ALT_MATCH){n=!0;break}for(let o=0;o<e.inst.length;o++){const u=e.inst[o],B=e.inst[u.out].op;switch(u.op){case ne.ALT:case ne.ALT_MATCH:if(B===ne.MATCH||e.inst[u.arg].op===ne.MATCH)return null;break;case ne.EMPTY_WIDTH:if(B===ne.MATCH){if((u.arg&ke.EMPTY_END_TEXT)===ke.EMPTY_END_TEXT)continue;return null}break;default:if(B===ne.MATCH&&n)return null;break}}let i=CI(e);return i=yI(i),i!==null&&bI(i,e),i}static next(e,t){const n=e.matchRunePos(t);return n>=0?e.next[n]:e.op===ne.ALT_MATCH?e.out:0}static execute(e,t,n,i,o){const u=e.onepass;if(!u)return null;const B=new Int32Array(o).fill(-1);let f=!1,g=t.step(n),y=g>>3,b=g&7,D=Yn.EOF(),T=-1,M=0;g!==Yn.EOF()&&(D=t.step(n+b),D!==Yn.EOF()&&(T=D>>3,M=D&7));let z=n===0?ke.emptyOpContext(-1,y):t.context(n),W=u.start,K;for(;;){switch(K=u.inst[W],W=K.out,K.op){case ne.MATCH:return i===ue.ANCHOR_BOTH&&n!==t.endPos()?null:(f=!0,B.length>0&&(B[0]=0,B[1]=n),o===0?[]:ke.toArray(B));case ne.RUNE:if(!K.matchRune(y))return null;break;case ne.RUNE1:if(y!==K.runes[0])return null;break;case ne.RUNE_ANY:break;case ne.RUNE_ANY_NOT_NL:if(y===10)return null;break;case ne.ALT:case ne.ALT_MATCH:W=L1.next(K,y);continue;case ne.FAIL:return null;case ne.NOP:continue;case ne.EMPTY_WIDTH:if((K.arg&~z)!==0)return null;continue;case ne.CAPTURE:K.arg<B.length&&(B[K.arg]=n);continue;default:throw new Qc("bad inst")}if(b===0)break;z=ke.emptyOpContext(y,T),n+=b,y=T,b=M,y!==-1&&(D=t.step(n+b),D!==Yn.EOF()?(T=D>>3,M=D&7):(T=-1,M=0))}return f?o===0?[]:ke.toArray(B):null}},je,G=(je=class{static isPseudoOp(e){return e>=je.Op.LEFT_PAREN}static emptySubs(){return[]}static quoteIfHyphen(e){return e===te.CODES.get("-")?"\\":""}static fromRegexp(e){const t=new je(e.op);return t.flags=e.flags,t.subs=e.subs,t.runes=e.runes,t.cap=e.cap,t.min=e.min,t.max=e.max,t.name=e.name,t.namedGroups=e.namedGroups,t.lb=e.lb,t}constructor(e){this.op=e,this.flags=0,this.subs=je.emptySubs(),this.runes=[],this.min=0,this.max=0,this.cap=0,this.name=null,this.namedGroups=Object.create(null),this.lb=0}reinit(){this.flags=0,this.subs=je.emptySubs(),this.runes=[],this.cap=0,this.min=0,this.max=0,this.name=null,this.namedGroups=Object.create(null),this.lb=0}toString(){return this.appendTo()}appendTo(){let e="";switch(this.op){case je.Op.NO_MATCH:e+="[^\\x00-\\x{10FFFF}]";break;case je.Op.EMPTY_MATCH:e+="(?:)";break;case je.Op.STAR:case je.Op.PLUS:case je.Op.QUEST:case je.Op.REPEAT:{const t=this.subs[
7290];switch(t.op>je.Op.CAPTURE||t.op===je.Op.LITERAL&&t.runes.length>1?e+=`(?:${t.appendTo()})`:e+=t.appendTo(),this.op){case je.Op.STAR:e+="*";break;case je.Op.PLUS:e+="+";break;case je.Op.QUEST:e+="?";break;case je.Op.REPEAT:e+=`{${this.min}`,this.min!==this.max&&(e+=",",this.max>=0&&(e+=this.max)),e+="}";break}(this.flags&ue.NON_GREEDY)!==0&&(e+="?");break}case je.Op.CONCAT:for(let t of this.subs)t.op===je.Op.ALTERNATE?e+=`(?:${t.appendTo()})`:e+=t.appendTo();break;case je.Op.ALTERNATE:{let t="";for(let n of this.subs)e+=t,t="|",e+=n.appendTo();break}case je.Op.LITERAL:(this.flags&ue.FOLD_CASE)!==0&&(e+="(?i:");for(let t of this.runes)e+=ke.escapeRune(t);(this.flags&ue.FOLD_CASE)!==0&&(e+=")");break;case je.Op.ANY_CHAR_NOT_NL:e+="(?-s:.)";break;case je.Op.ANY_CHAR:e+="(?s:.)";break;case je.Op.PLB:e+=`(?<=${this.subs[0].appendTo()})`;break;case je.Op.NLB:e+=`(?<!${this.subs[0].appendTo()})`;break;case je.Op.CAPTURE:this.name===null||this.name.length===0?e+="(":e+=`(?P<${this.name}>`,this.subs[0].op!==je.Op.EMPTY_MATCH&&(e+=this.subs[0].appendTo()),e+=")";break;case je.Op.BEGIN_TEXT:e+="\\A";break;case je.Op.END_TEXT:(this.flags&ue.WAS_DOLLAR)!==0?e+="(?-m:$)":e+="\\z";break;case je.Op.BEGIN_LINE:e+="^";break;case je.Op.END_LINE:e+="$";break;case je.Op.WORD_BOUNDARY:e+="\\b";break;case je.Op.NO_WORD_BOUNDARY:e+="\\B";break;case je.Op.CHAR_CLASS:if(this.runes.length%2!==0){e+="[invalid char class]";break}if(e+="[",this.runes.length===0)e+="^\\x00-\\x{10FFFF}";else if(this.runes[0]===0&&this.runes[this.runes.length-1]===we.MAX_RUNE){e+="^";for(let t=1;t<this.runes.length-1;t+=2){const n=this.runes[t]+1,i=this.runes[t+1]-1;e+=je.quoteIfHyphen(n),e+=ke.escapeRune(n),n!==i&&(e+="-",e+=je.quoteIfHyphen(i),e+=ke.escapeRune(i))}}else for(let t=0;t<this.runes.length;t+=2){const n=this.runes[t],i=this.runes[t+1];e+=je.quoteIfHyphen(n),e+=ke.escapeRune(n),n!==i&&(e+="-",e+=je.quoteIfHyphen(i),e+=ke.escapeRune(i))}e+="]";break;default:e+=this.op;break}return e}maxCap(){let e=0;if(this.op===je.Op.CAPTURE&&(e=this.cap),this.subs!==null)for(let t of this.subs){const n=t.maxCap();e<n&&(e=n)}return e}equals(e){if(!(e!==null&&e instanceof je)||this.op!==e.op)return!1;switch(this.op){case je.Op.END_TEXT:if((this.flags&ue.WAS_DOLLAR)!==(e.flags&ue.WAS_DOLLAR))return!1;break;case je.Op.LITERAL:case je.Op.CHAR_CLASS:if(this.runes===null&&e.runes===null)break;if(this.runes===null||e.runes===null||this.runes.length!==e.runes.length)return!1;for(let t=0;t<this.runes.length;t++)if(this.runes[t]!==e.runes[t])return!1;break;case je.Op.ALTERNATE:case je.Op.CONCAT:if(this.subs.length!==e.subs.length)return!1;for(let t=0;t<this.subs.length;++t)if(!this.subs[t].equals(e.subs[t]))return!1;break;case je.Op.STAR:case je.Op.PLUS:case je.Op.QUEST:if((this.flags&ue.NON_GREEDY)!==(e.flags&ue.NON_GREEDY)||!this.subs[0].equals(e.subs[0]))return!1;break;case je.Op.REPEAT:if((this.flags&ue.NON_GREEDY)!==(e.flags&ue.NON_GREEDY)||this.min!==e.min||this.max!==e.max||!this.subs[0].equals(e.subs[0]))return!1;break;case je.Op.CAPTURE:if(this.cap!==e.cap||(this.name===null?e.name!==null:this.name!==e.name)||!this.subs[0].equals(e.subs[0]))return!1;break;case je.Op.PLB:case je.Op.NLB:if(this.lb!==e.lb||!this.subs[0].equals(e.subs[0]))return!1;break}return!0}},me(je,"Op",O1(["NO_MATCH","EMPTY_MATCH","LITERAL","CHAR_CLASS","ANY_CHAR_NOT_NL","ANY_CHAR","BEGIN_LINE","END_LINE","BEGIN_TEXT","END_TEXT","WORD_BOUNDARY","NO_WORD_BOUNDARY","CAPTURE","STAR","PLUS","QUEST","REPEAT","CONCAT","ALTERNATE","PLB","NLB","LEFT_PAREN","VERTICAL_BAR"])),je),gE=class{constructor(r){this.next=[Object.create(null)],this.fail=[0],this.match=[!1];for(const t of r){let n=0;for(let i=0;i<t.length;i++){const o=t[i];o in this.next[n]||(this.next.push(Object.create(null)),this.fail.push(0),this.match.push(!1),this.next[n][o]=this.next.length-1),n=this.next[n][o]}this.match[n]=!0}const e=[];for(const t in this.next[0])if(Object.prototype.hasOwnProperty.call(this.next[0],t)){const n=this.next[0][t];this.fail[n]=0,e.push(n)}for(;e.length>0;){const t=e.shift();for(const n in this.next[t])if(Object.prototype.hasOwnProperty.call(this.next[t],n)){const i=this.next[t][n];let o=this.fail[t];for(;o!==0&&!(n in this.next[o]);)o=this.fail[o];n in this.next[o]?this.fail[i]=this.next[o][n]:this.fail[i]=0,this.match[i]=this.match[i]||this.match[this.fail[i]],e.push(i)}}}searchUTF16(r,e,t){let n=0;for(let i=e;i<t;i++){const o=r.charCodeAt(i);for(;n!==0&&!(o in this.next[n]);)n=this.fail[n];if(o in this.next[n]&&(n=this.next[n][o]),this.match[n])return!0}return!1}searchUTF8(r,e,t){let n=0;for(let i=e;i<t;i++){const o=r[i];for(;n!==0&&!(o in this.next[n]);)n=this.fail[n];if(o in this.next[n]&&(n=this.next[n][o]),this.match[n])return!0}return!1}},jr,ht=(jr=class{constructor(e){this.type=e,this.subs=[],this.str="",this.bytes=null,this.ac16=null,this.ac8=null}eval(e,t){switch(this.type){case jr.Type.NONE:return!0;case jr.Type.EXACT:return e.hasString(this,t);case jr.Type.AND:for(let n=0;n<this.subs.length;n++)if(!this.subs[n].eval(e,t))return!1;return!0;case jr.Type.OR:if(this.ac16&&this.ac8)return e.hasAnyString(this,t);for(let n=0;n<this.subs.length;n++)if(this.subs[n].eval(e,t))return!0;return!1;default:return!0}}},me(jr,"Type",{NONE:0,EXACT:1,AND:2,OR:3}),jr),xI=class ca{static build(e){const t=ca.fromRegexp(e);return ca.simplify(t)}static fromRegexp(e){if(!e)return new ht(ht.Type.NONE);switch(e.op){case G.Op.PLB:case G.Op.NLB:case G.Op.NO_MATCH:case G.Op.EMPTY_MATCH:case G.Op.BEGIN_LINE:case G.Op.END_LINE:case G.Op.BEGIN_TEXT:case G.Op.END_TEXT:case G.Op.WORD_BOUNDARY:case G.Op.NO_WORD_BOUNDARY:case G.Op.CHAR_CLASS:case G.Op.ANY_CHAR_NOT_NL:case G.Op.ANY_CHAR:return new ht(ht.Type.NONE);case G.Op.LITERAL:{if(e.runes.length===0||(e.flags&ue.FOLD_CASE)!==0)return new ht(ht.Type.NONE);const t=new ht(ht.Type.EXACT);let n="";for(let i=0;i<e.runes.length;i++)n+=String.fromCodePoint(e.runes[i]);return t.str=n,t.bytes=ke.stringToUtf8ByteArray(t.str),t}case G.Op.CAPTURE:case G.Op.PLUS:return ca.fromRegexp(e.subs[0]);case G.Op.REPEAT:return e.min>=1?ca.fromRegexp(e.subs[0]):new ht(ht.Type.NONE);case G.Op.CONCAT:{const t=new ht(ht.Type.AND);for(const n of e.subs)t.subs.push(ca.fromRegexp(n));return t}case G.Op.ALTERNATE:{const t=new ht(ht.Type.OR);for(const n of e.subs)t.subs.push(ca.fromRegexp(n));return t}default:return new ht(ht.Type.NONE)}}static simplify(e){if(e.type===ht.Type.EXACT||e.type===ht.Type.NONE)return e;if(e.type===ht.Type.AND){const t=[];for(const n of e.subs){const i=ca.simplify(n);if(i.type!==ht.Type.NONE)if(i.type===ht.Type.AND)for(let o=0;o<i.subs.length;o++)t.push(i.subs[o]);else t.push(i)}return t.length===0?new ht(ht.Type.NONE):t.length===1?t[0]:(e.subs=t,e)}if(e.type===ht.Type.OR){const t=[];for(const u of e.subs){const B=ca.simplify(u);if(B.type===ht.Type.NONE)return new ht(ht.Type.NONE);if(B.type===ht.Type.OR)for(let f=0;
729f<B.subs.length;f++)t.push(B.subs[f]);else t.push(B)}if(t.length===0)return new ht(ht.Type.NONE);if(t.length===1)return t[0];const n=new Set,i=[];for(const u of t)u.type===ht.Type.EXACT?n.has(u.str)||(n.add(u.str),i.push(u)):i.push(u);e.subs=i;let o=!0;for(const u of i)if(u.type!==ht.Type.EXACT){o=!1;break}return o&&i.length>1&&(e.ac16=new gE(i.map(u=>{const B=[];for(let f=0;f<u.str.length;f++)B.push(u.str.charCodeAt(f));return B})),e.ac8=new gE(i.map(u=>u.bytes))),e}return e}},Hs=class{constructor(r=0,e=0){this.head=r,this.tail=e}},EI=class{constructor(){this.inst=[],this.start=0,this.numCap=2,this.lbStarts=[],this.numLb=0}getInst(r){return this.inst[r]}numInst(){return this.inst.length}addInst(r){this.inst.push(new ne(r))}skipNop(r){let e=this.inst[r];for(;e.op===ne.NOP||e.op===ne.CAPTURE;)e=this.inst[r],r=e.out;return e}prefix(){let r="",e=this.skipNop(this.start);if(!ne.isRuneOp(e.op)||e.runes.length!==1)return[e.op===ne.MATCH,r];for(;ne.isRuneOp(e.op)&&e.runes.length===1&&(e.arg&ue.FOLD_CASE)===0;)r+=String.fromCodePoint(e.runes[0]),e=this.skipNop(e.out);return[e.op===ne.MATCH,r]}startCond(){let r=0,e=this.start;e:for(;;){const t=this.inst[e];switch(t.op){case ne.EMPTY_WIDTH:r|=t.arg;break;case ne.FAIL:return-1;case ne.CAPTURE:case ne.NOP:break;default:break e}e=t.out}return r}patch(r,e){let t=r.head;for(;t!==0;){const n=this.inst[t>>1];(t&1)===0?(t=n.out,n.out=e):(t=n.arg,n.arg=e)}}append(r,e){if(r.head===0)return e;if(e.head===0)return r;const t=this.inst[r.tail>>1];return(r.tail&1)===0?t.out=e.head:t.arg=e.head,new Hs(r.head,e.tail)}toString(){let r="";for(let e=0;e<this.inst.length;e++){const t=r.length;r+=e,e===this.start&&(r+="*"),r+="        ".substring(r.length-t),r+=this.inst[e],r+=`
730`}return r}},gd=class{constructor(r=0,e=new Hs,t=!1){this.i=r,this.out=e,this.nullable=t}},_I=class Go{static ANY_RUNE_NOT_NL(){return[0,te.CODES.get(`
731`)-1,te.CODES.get(`
732`)+1,we.MAX_RUNE]}static ANY_RUNE(){return[0,we.MAX_RUNE]}static compileRegexp(e){const t=new Go,n=t.compile(e);return t.prog.patch(n.out,t.newInst(ne.MATCH).i),t.prog.start=n.i,t.prog}static compileSet(e){const t=new Go;if(e.length===0)return t.prog.start=t.newInst(ne.FAIL).i,t.prog;let n=[];for(let o=0;o<e.length;o++){const u=t.compile(e[o]),B=t.newInst(ne.MATCH);t.prog.getInst(B.i).arg=o,t.prog.patch(u.out,B.i),n.push(u.i)}let i=n[0];for(let o=1;o<n.length;o++){const u=t.newInst(ne.ALT),B=t.prog.getInst(u.i);B.out=i,B.arg=n[o],i=u.i}return t.prog.start=i,t.prog}constructor(){this.prog=new EI,this.newInst(ne.FAIL)}newInst(e){return this.prog.addInst(e),new gd(this.prog.numInst()-1,new Hs,!0)}nop(){const e=this.newInst(ne.NOP);return e.out=new Hs(e.i<<1,e.i<<1),e}fail(){return new gd}cap(e){const t=this.newInst(ne.CAPTURE);return t.out=new Hs(t.i<<1,t.i<<1),this.prog.getInst(t.i).arg=e,this.prog.numCap<e+1&&(this.prog.numCap=e+1),t}cat(e,t){return e.i===0||t.i===0?this.fail():(this.prog.patch(e.out,t.i),new gd(e.i,t.out,e.nullable&&t.nullable))}alt(e,t){if(e.i===0)return t;if(t.i===0)return e;const n=this.newInst(ne.ALT),i=this.prog.getInst(n.i);return i.out=e.i,i.arg=t.i,n.out=this.prog.append(e.out,t.out),n.nullable=e.nullable||t.nullable,n}loop(e,t){const n=this.newInst(ne.ALT),i=this.prog.getInst(n.i);return t?(i.arg=e.i,n.out=new Hs(n.i<<1,n.i<<1)):(i.out=e.i,n.out=new Hs(n.i<<1|1,n.i<<1|1)),this.prog.patch(e.out,n.i),n}quest(e,t){const n=this.newInst(ne.ALT),i=this.prog.getInst(n.i);return t?(i.arg=e.i,n.out=new Hs(n.i<<1,n.i<<1)):(i.out=e.i,n.out=new Hs(n.i<<1|1,n.i<<1|1)),n.out=this.prog.append(n.out,e.out),n}star(e,t){return e.nullable?this.quest(this.plus(e,t),t):this.loop(e,t)}plus(e,t){return new gd(e.i,this.loop(e,t).out,e.nullable)}empty(e){const t=this.newInst(ne.EMPTY_WIDTH);return this.prog.getInst(t.i).arg=e,t.out=new Hs(t.i<<1,t.i<<1),t}rune(e,t){const n=this.newInst(ne.RUNE);n.nullable=!1;const i=this.prog.getInst(n.i);return i.runes=e,t&=ue.FOLD_CASE,(e.length!==1||we.simpleFold(e[0])===e[0])&&(t&=-2),i.arg=t,n.out=new Hs(n.i<<1,n.i<<1),(t&ue.FOLD_CASE)===0&&e.length===1||e.length===2&&e[0]===e[1]?i.op=ne.RUNE1:e.length===2&&e[0]===0&&e[1]===we.MAX_RUNE?i.op=ne.RUNE_ANY:e.length===4&&e[0]===0&&e[1]===te.CODES.get(`
733`)-1&&e[2]===te.CODES.get(`
734`)+1&&e[3]===we.MAX_RUNE&&(i.op=ne.RUNE_ANY_NOT_NL),n}lookBehind(e,t){const n=this.newInst(ne.LB_WRITE);this.prog.getInst(n.i).arg=t;const i=this.rune(Go.ANY_RUNE(),0),o=this.star(i,!0),u=this.cat(o,e);this.prog.patch(u.out,n.i);const B=this.newInst(ne.LB_CHECK);return this.prog.getInst(B.i).arg=t,this.prog.lbStarts.push(u.i),Math.abs(t)>this.prog.numLb&&(this.prog.numLb=Math.abs(t)),B.out=new Hs(B.i<<1,B.i<<1),B}compile(e){switch(e.op){case G.Op.NO_MATCH:return this.fail();case G.Op.EMPTY_MATCH:return this.nop();case G.Op.LITERAL:if(e.runes.length===0)return this.nop();{let t=null;for(let n of e.runes){const i=this.rune([n],e.flags);t=t===null?i:this.cat(t,i)}return t}case G.Op.CHAR_CLASS:return this.rune(e.runes,e.flags);case G.Op.ANY_CHAR_NOT_NL:return this.rune(Go.ANY_RUNE_NOT_NL(),0);case G.Op.ANY_CHAR:return this.rune(Go.ANY_RUNE(),0);case G.Op.BEGIN_LINE:return this.empty(ke.EMPTY_BEGIN_LINE);case G.Op.END_LINE:return this.empty(ke.EMPTY_END_LINE);case G.Op.BEGIN_TEXT:return this.empty(ke.EMPTY_BEGIN_TEXT);case G.Op.END_TEXT:return this.empty(ke.EMPTY_END_TEXT);case G.Op.WORD_BOUNDARY:return this.empty(ke.EMPTY_WORD_BOUNDARY);case G.Op.NO_WORD_BOUNDARY:return this.empty(ke.EMPTY_NO_WORD_BOUNDARY);case G.Op.PLB:case G.Op.NLB:return this.lookBehind(this.compile(e.subs[0]),e.lb);case G.Op.CAPTURE:{const t=this.cap(e.cap<<1),n=this.compile(e.subs[0]),i=this.cap(e.cap<<1|1);return this.cat(this.cat(t,n),i)}case G.Op.STAR:return this.star(this.compile(e.subs[0]),(e.flags&ue.NON_GREEDY)!==0);case G.Op.PLUS:return this.plus(this.compile(e.subs[0]),(e.flags&ue.NON_GREEDY)!==0);case G.Op.QUEST:return this.quest(this.compile(e.subs[0]),(e.flags&ue.NON_GREEDY)!==0);case G.Op.CONCAT:if(e.subs.length===0)return this.nop();{let t=null;for(let n of e.subs){const i=this.compile(n);t=t===null?i:this.cat(t,i)}return t}case G.Op.ALTERNATE:if(e.subs.length===0)return this.nop();{let t=null;for(let n of e.subs){const i=this.compile(n);t=t===null?i:this.alt(t,i)}return t}default:throw new iI("regexp: unhandled case in compile")}}},DI=class bs{static simplify(e){if(e===null)return null;switch(e.op){case G.Op.PLB:case G.Op.NLB:case G.Op.CAPTURE:{const t=bs.simplify(e.subs[0]);if(t!==e.subs[0]){const n=G.fromRegexp(e);return n.runes=[],n.subs=[t],n}return e}case G.Op.CONCAT:case G.Op.ALTERNATE:{const t=[];let n=!1;for(let i=0;i<e.subs.length;i++){const o=e.subs[i],u=bs.simplify(o);if(u!==o&&(n=!0),e.op===G.Op.CONCAT){if(u.op===G.Op.NO_MATCH)return new G(G.Op.NO_MATCH);if(u.op===G.Op.EMPTY_MATCH){n=!0;continue}if(u.op===G.Op.CONCAT){n=!0;for(let B=0;B<u.subs.length;B++)t.push(u.subs[B]);continue}}else if(e.op===G.Op.ALTERNATE){if(u.op===G.Op.NO_MATCH){n=!0;continue}if(u.op===G.Op.ALTERNATE){n=!0;for(let B=0;B<u.subs.length;B++)t.push(u.subs[B]);continue}}t.push(u)}if(n){if(t.length===0)return new G(e.op===G.Op.CONCAT?G.Op.EMPTY_MATCH:G.Op.NO_MATCH);if(t.length===1)return t[0];const i=G.fromRegexp(e);return i.runes=[],i.subs=t,i}return e}case G.Op.CHAR_CLASS:return e.runes===null?e:e.runes.length===0?new G(G.Op.NO_MATCH):e.runes.length===2&&e.runes[0]===0&&e.runes[1]===we.MAX_RUNE?new G(G.Op.ANY_CHAR):e.runes.length===4&&e.runes[0]===0&&e.runes[1]===te.CODES.get(`
735`)-1&&e.runes[2]===te.CODES.get(`
736`)+1&&e.runes[3]===we.MAX_RUNE?new G(G.Op.ANY_CHAR_NOT_NL):e;case G.Op.STAR:case G.Op.PLUS:case G.Op.QUEST:{const t=bs.simplify(e.subs[0]);return bs.simplify1(e.op,e.flags,t,e)}case G.Op.REPEAT:{if(e.min===0&&e.max===0)return new G(G.Op.EMPTY_MATCH);const t=bs.simplify(e.subs[0]);if(e.max===-1){if(e.min===0)return bs.simplify1(G.Op.STAR,e.flags,t,null);if(e.min===1)return bs.simplify1(G.Op.PLUS,e.flags,t,null);const i=new G(G.Op.CONCAT),o=[];for(let u=0;u<e.min-1;u++)o.push(t);return o.push(bs.simplify1(G.Op.PLUS,e.flags,t,null)),i.subs=o.slice(0),bs.simplify(i)}if(e.min===1&&e.max===1)return t;let n=null;if(e.min>0){n=[];for(let i=0;i<e.min;i++)n.push(t)}if(e.max>e.min){let i=bs.simplify1(G.Op.QUEST,e.flags,t,null);for(let o=e.min+1;o<e.max;o++){const u=new G(G.Op.CONCAT);u.subs=[t,i],i=bs.simplify1(G.Op.QUEST,e.flags,u,null)}if(n===null)return i;n.push(i)}if(n!==null){const i=new G(G.Op.CONCAT);return i.subs=n.slice(0),bs.simplify(i)}return new G(G.Op.NO_MATCH)}}return e}static simplify1(e,t,n,i){if(n.op===G.Op.EMPTY_MATCH)return n;if(n.op===G.Op.NO_MATCH)return e===G.Op.PLUS?n:new G(G.Op.EMPTY_MATCH);if(e===n.op&&(t&ue.NON_GREEDY)===(n.flags&ue.NON_GREEDY))return n;if(i!==null&&i.op===e&&(i.flags&ue.NON_GREEDY)===(t&ue.NON_GREEDY)&&n===i.subs[
7360])return i;const o=new G(e);return o.flags=t,o.subs=[n],o}},ot=class{constructor(r,e){this.sign=r,this.cls=e}};const CE=[48,57],yE=[9,10,12,13,32,32],bE=[48,57,65,90,95,95,97,122],xE=new Map([["\\d",new ot(1,CE)],["\\D",new ot(-1,CE)],["\\s",new ot(1,yE)],["\\S",new ot(-1,yE)],["\\w",new ot(1,bE)],["\\W",new ot(-1,bE)]]),EE=[48,57,65,90,97,122],_E=[65,90,97,122],DE=[0,127],vE=[9,9,32,32],wE=[0,31,127,127],TE=[48,57],AE=[33,126],NE=[97,122],IE=[32,126],SE=[33,47,58,64,91,96,123,126],RE=[9,13,32,32],OE=[65,90],kE=[48,57,65,90,95,95,97,122],LE=[48,57,65,70,97,102],jE=new Map([["[:alnum:]",new ot(1,EE)],["[:^alnum:]",new ot(-1,EE)],["[:alpha:]",new ot(1,_E)],["[:^alpha:]",new ot(-1,_E)],["[:ascii:]",new ot(1,DE)],["[:^ascii:]",new ot(-1,DE)],["[:blank:]",new ot(1,vE)],["[:^blank:]",new ot(-1,vE)],["[:cntrl:]",new ot(1,wE)],["[:^cntrl:]",new ot(-1,wE)],["[:digit:]",new ot(1,TE)],["[:^digit:]",new ot(-1,TE)],["[:graph:]",new ot(1,AE)],["[:^graph:]",new ot(-1,AE)],["[:lower:]",new ot(1,NE)],["[:^lower:]",new ot(-1,NE)],["[:print:]",new ot(1,IE)],["[:^print:]",new ot(-1,IE)],["[:punct:]",new ot(1,SE)],["[:^punct:]",new ot(-1,SE)],["[:space:]",new ot(1,RE)],["[:^space:]",new ot(-1,RE)],["[:upper:]",new ot(1,OE)],["[:^upper:]",new ot(-1,OE)],["[:word:]",new ot(1,kE)],["[:^word:]",new ot(-1,kE)],["[:xdigit:]",new ot(1,LE)],["[:^xdigit:]",new ot(-1,LE)]]);var ai=class Bi{static charClassToString(e,t){let n="[";for(let i=0;i<t;i+=2){i>0&&(n+=" ");const o=e[i],u=e[i+1];o===u?n+=`0x${o.toString(16)}`:n+=`0x${o.toString(16)}-0x${u.toString(16)}`}return n+="]",n}static cmp(e,t,n,i){const o=e[t]-n;return o!==0?o:i-e[t+1]}static qsortIntPair(e,t,n){const i=((t+n)/2|0)&-2,o=e[i],u=e[i+1];let B=t,f=n;for(;B<=f;){for(;B<n&&Bi.cmp(e,B,o,u)<0;)B+=2;for(;f>t&&Bi.cmp(e,f,o,u)>0;)f-=2;if(B<=f){if(B!==f){let g=e[B];e[B]=e[f],e[f]=g,g=e[B+1],e[B+1]=e[f+1],e[f+1]=g}B+=2,f-=2}}t<f&&Bi.qsortIntPair(e,t,f),B<n&&Bi.qsortIntPair(e,B,n)}constructor(e=ke.emptyInts()){this.r=e,this.len=e.length}toArray(){return this.len===this.r.length?this.r:this.r.slice(0,this.len)}cleanClass(){if(this.len<4)return this;Bi.qsortIntPair(this.r,0,this.len-2);let e=2;for(let t=2;t<this.len;t+=2){const n=this.r[t],i=this.r[t+1];if(n<=this.r[e-1]+1){i>this.r[e-1]&&(this.r[e-1]=i);continue}this.r[e]=n,this.r[e+1]=i,e+=2}return this.len=e,this}appendLiteral(e,t){return(t&ue.FOLD_CASE)!==0?this.appendFoldedRange(e,e):this.appendRange(e,e)}appendRange(e,t){if(this.len>0){for(let n=2;n<=4;n+=2)if(this.len>=n){const i=this.r[this.len-n],o=this.r[this.len-n+1];if(e<=o+1&&i<=t+1)return e<i&&(this.r[this.len-n]=e),t>o&&(this.r[this.len-n+1]=t),this}}return this.r[this.len++]=e,this.r[this.len++]=t,this}appendFoldedRange(e,t){if(e<=we.MIN_FOLD&&t>=we.MAX_FOLD)return this.appendRange(e,t);if(t<we.MIN_FOLD||e>we.MAX_FOLD)return this.appendRange(e,t);e<we.MIN_FOLD&&(this.appendRange(e,we.MIN_FOLD-1),e=we.MIN_FOLD),t>we.MAX_FOLD&&(this.appendRange(we.MAX_FOLD+1,t),t=we.MAX_FOLD);for(let n=e;n<=t;n++){this.appendRange(n,n);for(let i=we.simpleFold(n);i!==n;i=we.simpleFold(i))this.appendRange(i,i)}return this}appendClass(e){for(let t=0;t<e.length;t+=2)this.appendRange(e[t],e[t+1]);return this}appendFoldedClass(e){for(let t=0;t<e.length;t+=2)this.appendFoldedRange(e[t],e[t+1]);return this}appendNegatedClass(e){let t=0;for(let n=0;n<e.length;n+=2){const i=e[n],o=e[n+1];t<=i-1&&this.appendRange(t,i-1),t=o+1}return t<=we.MAX_RUNE&&this.appendRange(t,we.MAX_RUNE),this}appendTable(e){for(let t=0;t<e.length;++t){const n=e.getLo(t),i=e.getHi(t),o=e.getStride(t);if(o===1){this.appendRange(n,i);continue}for(let u=n;u<=i;u+=o)this.appendRange(u,u)}return this}appendNegatedTable(e){let t=0;for(let n=0;n<e.length;++n){const i=e.getLo(n),o=e.getHi(n),u=e.getStride(n);if(u===1){t<=i-1&&this.appendRange(t,i-1),t=o+1;continue}for(let B=i;B<=o;B+=u)t<=B-1&&this.appendRange(t,B-1),t=B+1}return t<=we.MAX_RUNE&&this.appendRange(t,we.MAX_RUNE),this}appendTableWithSign(e,t){return t<0?this.appendNegatedTable(e):this.appendTable(e)}negateClass(){let e=0,t=0;for(let n=0;n<this.len;n+=2){const i=this.r[n],o=this.r[n+1];
736e<=i-1&&(this.r[t]=e,this.r[t+1]=i-1,t+=2),e=o+1}return this.len=t,e<=we.MAX_RUNE&&(this.r[this.len++]=e,this.r[this.len++]=we.MAX_RUNE),this}appendClassWithSign(e,t){return t<0?this.appendNegatedClass(e):this.appendClass(e)}appendGroup(e,t){let n=e.cls;return t&&(n=new Bi().appendFoldedClass(n).cleanClass().toArray()),this.appendClassWithSign(n,e.sign)}toString(){return Bi.charClassToString(this.r,this.len)}},vI=class{constructor(r){this.str=r,this.position=0}pos(){return this.position}rewindTo(r){this.position=r}more(){return this.position<this.str.length}peek(){return this.str.codePointAt(this.position)}skip(r){this.position+=r}skipString(r){this.position+=r.length}pop(){const r=this.str.codePointAt(this.position);return this.position+=ke.charCount(r),r}lookingAt(r){return this.str.startsWith(r,this.position)}rest(){return this.str.substring(this.position)}from(r){return this.str.substring(r,this.position)}toString(){return this.rest()}},ge,wI=(ge=class{static unicodeTable(e){return e==="Any"?{tab:ge.ANY_TABLE,fold:ge.ANY_TABLE,sign:1}:e==="Ascii"?{tab:ge.ASCII_TABLE,fold:ge.ASCII_FOLD_TABLE,sign:1}:e==="Assigned"?{tab:as.CATEGORIES.get("Cn"),fold:as.CATEGORIES.get("Cn"),sign:-1}:e==="Lc"?{tab:as.CATEGORIES.get("LC"),fold:as.FOLD_CATEGORIES.get("LC"),sign:1}:as.CATEGORIES.has(e)?{tab:as.CATEGORIES.get(e),fold:as.FOLD_CATEGORIES.get(e),sign:1}:as.SCRIPTS.has(e)?{tab:as.SCRIPTS.get(e),fold:as.FOLD_SCRIPT.get(e),sign:1}:null}static minFoldRune(e){if(e<we.MIN_FOLD||e>we.MAX_FOLD)return e;let t=e;const n=e;for(e=we.simpleFold(e);e!==n;e=we.simpleFold(e))t>e&&(t=e);return t}static leadingRegexp(e){if(e.op===G.Op.EMPTY_MATCH)return null;if(e.op===G.Op.CONCAT&&e.subs.length>0){const t=e.subs[0];return t.op===G.Op.EMPTY_MATCH?null:t}return e}static literalRegexp(e,t){const n=new G(G.Op.LITERAL);return n.flags=t,n.runes=ke.stringToRunes(e),n}static parse(e,t){return new ge(e,t).parseInternal()}static parseRepeat(e){const t=e.pos();if(!e.more()||!e.lookingAt("{"))return-1;e.skip(1);const n=ge.parseInt(e);if(n===-1||!e.more())return-1;let i;if(!e.lookingAt(","))i=n;else{if(e.skip(1),!e.more())return-1;if(e.lookingAt("}"))i=-1;else if((i=ge.parseInt(e))===-1)return-1}if(!e.more()||!e.lookingAt("}"))return-1;if(e.skip(1),n<0||n>1e3||i===-2||i>1e3||i>=0&&n>i)throw new kt(ge.ERR_INVALID_REPEAT_SIZE,e.from(t));return n<<16|i&we.MAX_BMP}static isValidCaptureName(e){if(e.length===0)return!1;for(let t=0;t<e.length;t++){const n=e.codePointAt(t);if(n!==te.CODES.get("_")&&!ke.isalnum(n))return!1}return!0}static parseInt(e){const t=e.pos();for(;e.more()&&e.peek()>=te.CODES.get("0")&&e.peek()<=te.CODES.get("9");)e.skip(1);const n=e.from(t);return n.length===0||n.length>1&&n.codePointAt(0)===te.CODES.get("0")?-1:n.length>8?-2:parseInt(n,10)}static isCharClass(e){return e.op===G.Op.LITERAL&&e.runes.length===1||e.op===G.Op.CHAR_CLASS||e.op===G.Op.ANY_CHAR_NOT_NL||e.op===G.Op.ANY_CHAR}static matchRune(e,t){switch(e.op){case G.Op.LITERAL:return e.runes.length===1&&e.runes[0]===t;case G.Op.CHAR_CLASS:for(let n=0;n<e.runes.length;n+=2)if(e.runes[n]<=t&&t<=e.runes[n+1])return!0;return!1;case G.Op.ANY_CHAR_NOT_NL:return t!==te.CODES.get(`
737`);case G.Op.ANY_CHAR:return!0}return!1}static mergeCharClass(e,t){switch(e.op){case G.Op.ANY_CHAR:break;case G.Op.ANY_CHAR_NOT_NL:ge.matchRune(t,te.CODES.get(`
738`))&&(e.op=G.Op.ANY_CHAR);break;case G.Op.CHAR_CLASS:t.op===G.Op.LITERAL?e.runes=new ai(e.runes).appendLiteral(t.runes[0],t.flags).toArray():e.runes=new ai(e.runes).appendClass(t.runes).toArray();break;case G.Op.LITERAL:if(t.runes[0]===e.runes[0]&&t.flags===e.flags)break;e.op=G.Op.CHAR_CLASS,e.runes=new ai().appendLiteral(e.runes[0],e.flags).appendLiteral(t.runes[0],t.flags).toArray();break}}static parseEscape(e){const t=e.pos();if(e.skip(1),!e.more())throw new kt(ge.ERR_TRAILING_BACKSLASH);let n=e.pop();e:switch(n){case te.CODES.get("1"):case te.CODES.get("2"):case te.CODES.get("3"):case te.CODES.get("4"):case te.CODES.get("5"):case te.CODES.get("6"):case te.CODES.get("7"):if(!e.more(
738)||e.peek()<te.CODES.get("0")||e.peek()>te.CODES.get("7"))break;case te.CODES.get("0"):{let i=n-te.CODES.get("0");for(let o=1;o<3&&!(!e.more()||e.peek()<te.CODES.get("0")||e.peek()>te.CODES.get("7"));o++)i=i*8+e.peek()-te.CODES.get("0"),e.skip(1);return i}case te.CODES.get("x"):{if(!e.more())break;if(n=e.pop(),n===te.CODES.get("{")){let u=0,B=0;for(;;){if(!e.more())break e;if(n=e.pop(),n===te.CODES.get("}"))break;const f=ke.unhex(n);if(f<0||(B=B*16+f,B>we.MAX_RUNE))break e;u++}if(u===0)break e;return B}const i=ke.unhex(n);if(!e.more())break;n=e.pop();const o=ke.unhex(n);if(i<0||o<0)break;return i*16+o}case te.CODES.get("a"):return te.CODES.get("\x07");case te.CODES.get("f"):return te.CODES.get("\f");case te.CODES.get("n"):return te.CODES.get(`
739`);case te.CODES.get("r"):return te.CODES.get("\r");case te.CODES.get("t"):return te.CODES.get("	");case te.CODES.get("v"):return te.CODES.get("\v");default:if(n<=we.MAX_ASCII&&!ke.isalnum(n))return n;break}throw new kt(ge.ERR_INVALID_ESCAPE,e.from(t))}static parseClassChar(e,t){if(!e.more())throw new kt(ge.ERR_MISSING_BRACKET,e.from(t));return e.lookingAt("\\")?ge.parseEscape(e):e.pop()}static concatRunes(e,t){for(let n=0;n<t.length;n++)e.push(t[n]);return e}static hasCapture(e){if(e===null)return!1;if(e.op===G.Op.CAPTURE)return!0;if(e.subs){for(let t of e.subs)if(ge.hasCapture(t))return!0}return!1}constructor(e,t=0){this.wholeRegexp=e,this.flags=t,this.numCap=0,this.namedGroups=Object.create(null),this.stack=[],this.free=null,this.numRegexp=0,this.numRunes=0,this.repeats=0,this.height=null,this.size=null,this.nlb=0}newRegexp(e){let t=this.free;return t!==null&&t.subs!==null&&t.subs.length>0?(this.free=t.subs[0],t.reinit(),t.op=e):(t=new G(e),this.numRegexp+=1),t}reuse(e){this.height!==null&&this.height.has(e)&&this.height.delete(e),e.subs!==null&&e.subs.length>0&&(e.subs[0]=this.free),this.free=e}checkLimits(e){if(this.numRunes>ge.MAX_RUNES)throw new kt(ge.ERR_LARGE);this.checkSize(e),this.checkHeight(e)}checkSize(e){if(this.size===null){if(this.repeats===0&&(this.repeats=1),e.op===G.Op.REPEAT){let t=e.max;t===-1&&(t=e.min),t<=0&&(t=1),t>Math.floor(ge.MAX_SIZE/this.repeats)?this.repeats=ge.MAX_SIZE:this.repeats*=t}if(this.numRegexp<Math.floor(ge.MAX_SIZE/this.repeats))return;this.size=new Map;for(let t of this.stack)this.checkSize(t)}if(this.calcSize(e,!0)>ge.MAX_SIZE)throw new kt(ge.ERR_LARGE)}calcSize(e,t=!1){if(!t&&this.size!==null&&this.size.has(e))return this.size.get(e);let n=0;switch(e.op){case G.Op.LITERAL:n=e.runes.length;break;case G.Op.PLB:case G.Op.NLB:case G.Op.CAPTURE:case G.Op.STAR:n=2+this.calcSize(e.subs[0]);break;case G.Op.PLUS:case G.Op.QUEST:n=1+this.calcSize(e.subs[0]);break;case G.Op.CONCAT:for(let i of e.subs)n=n+this.calcSize(i);break;case G.Op.ALTERNATE:for(let i of e.subs)n=n+this.calcSize(i);e.subs.length>1&&(n=n+e.subs.length-1);break;case G.Op.REPEAT:{let i=this.calcSize(e.subs[0]);if(e.max===-1){e.min===0?n=2+i:n=1+e.min*i;break}n=e.max*i+(e.max-e.min);break}}return n=Math.max(1,n),this.size===null&&(this.size=new Map),this.size.set(e,n),n}checkHeight(e){if(!(this.numRegexp<ge.MAX_HEIGHT)){if(this.height===null){this.height=new Map;for(let t of this.stack)this.checkHeight(t)}if(this.calcHeight(e,!0)>ge.MAX_HEIGHT)throw new kt(ge.ERR_NESTING_DEPTH)}}calcHeight(e,t=!1){if(!t&&this.height!==null&&this.height.has(e))return this.height.get(e);let n=1;for(let i of e.subs){const o=this.calcHeight(i);n<1+o&&(n=1+o)}return this.height===null&&(this.height=new Map),this.height.set(e,n),n}pop(){return this.stack.pop()}popToPseudo(){const e=this.stack.length;let t=e;for(;t>0&&!G.isPseudoOp(this.stack[t-1].op);)t--;const n=this.stack.slice(t,e);return this.stack=this.stack.slice(0,t),n}push(e){if(this.numRunes+=e.runes.length,e.op===G.Op.CHAR_CLASS&&e.runes.length===2&&e.runes[0]===e.runes[1]){if(this.maybeConcat(e.runes[0],this.flags&-2))return null;e.op=G.Op.LITERAL,e.runes=[e.runes[0]],e.flags=this.flags&-2}else if(e.op===G.Op.CHAR_CLASS&&e.runes.length===4&&e.runes[0]===e.runes[1]&&e.runes[2]===e.runes[3]&&we.simpleFold(e.runes[0])===e.runes[2]&&we.simpleFold(e.runes[2])===e.runes[0]||e.op===G.Op.CHAR_CLASS&&e.runes.length===2&&e.runes[0]+1===e.runes[1]&&we.simpleFold(e.runes[0])===e.runes[1]&&we.simpleFold(e.runes[1])===e.runes[0]){if
vendor: 4,442 bytes, lines 739-741
739(this.maybeConcat(e.runes[0],this.flags|ue.FOLD_CASE))return null;e.op=G.Op.LITERAL,e.runes=[e.runes[0]],e.flags=this.flags|ue.FOLD_CASE}else this.maybeConcat(-1,0);return this.stack.push(e),this.checkLimits(e),e}maybeConcat(e,t){const n=this.stack.length;if(n<2)return!1;const i=this.stack[n-1],o=this.stack[n-2];return i.op!==G.Op.LITERAL||o.op!==G.Op.LITERAL||(i.flags&ue.FOLD_CASE)!==(o.flags&ue.FOLD_CASE)?!1:(o.runes=ge.concatRunes(o.runes,i.runes),e>=0?(i.runes=[e],i.flags=t,!0):(this.pop(),this.reuse(i),!1))}newLiteral(e,t){const n=this.newRegexp(G.Op.LITERAL);return n.flags=t,(t&ue.FOLD_CASE)!==0&&(e=ge.minFoldRune(e)),n.runes=[e],n}literal(e){this.push(this.newLiteral(e,this.flags))}op(e){const t=this.newRegexp(e);return t.flags=this.flags,this.push(t)}repeat(e,t,n,i,o,u){let B=this.flags;if((B&ue.PERL_X)!==0&&(o.more()&&o.lookingAt("?")&&(o.skip(1),B^=ue.NON_GREEDY),u!==-1))throw new kt(ge.ERR_INVALID_REPEAT_OP,o.from(u));const f=this.stack.length;if(f===0)throw new kt(ge.ERR_MISSING_REPEAT_ARGUMENT,o.from(i));const g=this.stack[f-1];if(G.isPseudoOp(g.op))throw new kt(ge.ERR_MISSING_REPEAT_ARGUMENT,o.from(i));const y=this.newRegexp(e);if(y.min=t,y.max=n,y.flags=B,y.subs=[g],this.stack[f-1]=y,this.checkLimits(y),e===G.Op.REPEAT&&(t>=2||n>=2)&&!this.repeatIsValid(y,1e3))throw new kt(ge.ERR_INVALID_REPEAT_SIZE,o.from(i))}repeatIsValid(e,t){if(e.op===G.Op.REPEAT){let n=e.max;if(n===0)return!0;if(n<0&&(n=e.min),n>t)return!1;n>0&&(t=Math.trunc(t/n))}for(let n of e.subs)if(!this.repeatIsValid(n,t))return!1;return!0}concat(){this.maybeConcat(-1,0);const e=this.popToPseudo();return e.length===0?this.push(this.newRegexp(G.Op.EMPTY_MATCH)):this.push(this.collapse(e,G.Op.CONCAT))}alternate(){const e=this.popToPseudo();return e.length>0&&this.cleanAlt(e[e.length-1]),e.length===0?this.push(this.newRegexp(G.Op.NO_MATCH)):this.push(this.collapse(e,G.Op.ALTERNATE))}cleanAlt(e){e.op===G.Op.CHAR_CLASS&&(e.runes=new ai(e.runes).cleanClass().toArray(),e.runes.length===2&&e.runes[0]===0&&e.runes[1]===we.MAX_RUNE?(e.runes=[],e.op=G.Op.ANY_CHAR):e.runes.length===4&&e.runes[0]===0&&e.runes[1]===te.CODES.get(`
740`)-1&&e.runes[2]===te.CODES.get(`
741`)+1&&e.runes[3]===we.MAX_RUNE&&(e.runes=[],e.op=G.Op.ANY_CHAR_NOT_NL))}collapse(e,t){if(e.length===1)return e[0];let n=0;for(let B of e)n+=B.op===t?B.subs.length:1;let i=new Array(n).fill(null),o=0;for(let B of e)if(B.op===t){for(let f=0;f<B.subs.length;f++)i[o++]=B.subs[f];this.reuse(B)}else i[o++]=B;let u=this.newRegexp(t);if(u.subs=i,t===G.Op.ALTERNATE&&(u.subs=this.factor(u.subs),u.subs.length===1)){const B=u;u=u.subs[0],this.reuse(B)}return u}factor(e){if(e.length<2)return e;let t=0,n=e.length,i=0,o=null,u=0,B=0,f=0;for(let y=0;y<=n;y++){let b=null,D=0,T=0;if(y<n){let M=e[t+y];if(M.op===G.Op.CONCAT&&M.subs.length>0&&(M=M.subs[0]),M.op===G.Op.LITERAL&&(b=M.runes,D=M.runes.length,T=M.flags&ue.FOLD_CASE),T===B){let z=0;for(;z<u&&z<D&&o[z]===b[z];)z++;if(z>0){u=z;continue}}}if(y!==f)if(y===f+1)e[i++]=e[t+f];else{const M=this.newRegexp(G.Op.LITERAL);M.flags=B,M.runes=o.slice(0,u);for(let K=f;K<y;K++)e[t+K]=this.removeLeadingString(e[t+K],u),this.checkLimits(e[t+K]);const z=this.collapse(e.slice(t+f,t+y),G.Op.ALTERNATE),W=this.newRegexp(G.Op.CONCAT);W.subs=[M,z],e[i++]=W}f=y,o=b,u=D,B=T}n=i,t=0,f=0,i=0;let g=null;for(let y=0;y<=n;y++){let b=null;if(!(y<n&&(b=ge.leadingRegexp(e[t+y]),g!==null&&g.equals(b)&&(ge.isCharClass(g)||g.op===G.Op.REPEAT&&g.min===g.max&&ge.isCharClass(g.subs[0]))))){if(y!==f)if(y===f+1)e[i++]=e[t+f];else{const D=g;for(let z=f;z<y;z++){const W=z!==f;e[t+z]=this.removeLeadingRegexp(e[t+z],W),this.checkLimits(e[t+z])}const T=this.collapse(e.slice(t+f,t+y),G.Op.ALTERNATE),M=this.newRegexp(G.Op.CONCAT);M.subs=[D,T],e[i++]=M}f=y,g=b}}n=i,t=0,f=0,i=0;for(let y=0;y<=n;y++)if(!(y<n&&ge.isCharClass(e[t+y]))){if(y!==f)if(y===f+1)e[i++]=e[t+f];else{let b=f;for(let T=f+1;T<y;T++){const M=e[t+b],z=e[t+T];(M.op<z.op||M.op===z.op&&(M.runes!==null?M.runes.length:0)<(z.runes!==null?z.runes.length:0))&&(b=T)}const D=e[t+f];e[t+f]=e[t+b],e[t+b]=D;for(let T=f+1;T<y;T++)ge.mergeCharClass(e[t+f],e[t+T]),this.reuse(e[t+T]);this.cleanAlt(e[t+f]),e[i++]=e[t+f]}y<n&&(e[i++]=e[t+y]),f=y+1}n=i,t=0,f=0,i=0;for(let y=0;y<n;++y)y+1<n&&e[t+y].op===G.Op.EMPTY_MATCH&&e[t+y+1].op===G.Op.EMPTY_MATCH||(e[i++]=e[t+y]);return n=i,t=0,e.slice(t,n)}removeLeadingString(e,t){if(e.op===G.Op.CONCAT&&e.subs.length>0){const n=this.removeLeadingString(e.subs[0],t);
741if(e.subs[0]=n,n.op===G.Op.EMPTY_MATCH)switch(this.reuse(n),e.subs.length){case 0:case 1:e.op=G.Op.EMPTY_MATCH,e.subs=G.emptySubs();break;case 2:{const i=e;e=e.subs[1],this.reuse(i);break}default:e.subs=e.subs.slice(1,e.subs.length);break}return e}return e.op===G.Op.LITERAL&&(e.runes=e.runes.slice(t,e.runes.length),e.runes.length===0&&(e.op=G.Op.EMPTY_MATCH)),e}removeLeadingRegexp(e,t){if(e.op===G.Op.CONCAT&&e.subs.length>0){switch(t&&this.reuse(e.subs[0]),e.subs=e.subs.slice(1,e.subs.length),e.subs.length){case 0:e.op=G.Op.EMPTY_MATCH,e.subs=G.emptySubs();break;case 1:{const n=e;e=e.subs[0],this.reuse(n);break}}return e}return t&&this.reuse(e),this.newRegexp(G.Op.EMPTY_MATCH)}parseInternal(){if((this.flags&ue.LITERAL)!==0)return ge.literalRegexp(this.wholeRegexp,this.flags);let e=-1,t=-1,n=-1;const i=new vI(this.wholeRegexp);for(;i.more();){let o=-1;e:switch(i.peek()){case te.CODES.get("("):if((this.flags&ue.LOOKBEHIND)!==0){if(i.lookingAt("(?<=")){this.parsePosLookBehind(),i.skip(4);break}if(i.lookingAt("(?<!")){this.parseNegLookBehind(),i.skip(4);break}}if((this.flags&ue.PERL_X)!==0&&i.lookingAt("(?")){this.parsePerlFlags(i);break}this.op(G.Op.LEFT_PAREN).cap=++this.numCap,i.skip(1);break;case te.CODES.get("|"):this.parseVerticalBar(),i.skip(1);break;case te.CODES.get(")"):this.parseRightParen(),i.skip(1);break;case te.CODES.get("^"):(this.flags&ue.ONE_LINE)!==0?this.op(G.Op.BEGIN_TEXT):this.op(G.Op.BEGIN_LINE),i.skip(1);break;case te.CODES.get("$"):(this.flags&ue.ONE_LINE)!==0?this.op(G.Op.END_TEXT).flags|=ue.WAS_DOLLAR:this.op(G.Op.END_LINE),i.skip(1);break;case te.CODES.get("."):(this.flags&ue.DOT_NL)!==0?this.op(G.Op.ANY_CHAR):this.op(G.Op.ANY_CHAR_NOT_NL),i.skip(1);break;case te.CODES.get("["):this.parseClass(i);break;case te.CODES.get("*"):case te.CODES.get("+"):case te.CODES.get("?"):{o=i.pos();let u=null;switch(i.pop()){case te.CODES.get("*"):u=G.Op.STAR;break;case te.CODES.get("+"):u=G.Op.PLUS;break;case te.CODES.get("?"):u=G.Op.QUEST;break}this.repeat(u,t,n,o,i,e);break}case te.CODES.get("{"):{o=i.pos();const u=ge.parseRepeat(i);if(u<0){i.rewindTo(o),this.literal(i.pop());break}t=u>>16,n=(u&we.MAX_BMP)<<16>>16,this.repeat(G.Op.REPEAT,t,n,o,i,e);break}case te.CODES.get("\\"):{const u=i.pos();if(i.skip(1),(this.flags&ue.PERL_X)!==0&&i.more())switch(i.pop()){case te.CODES.get("A"):this.op(G.Op.BEGIN_TEXT);break e;case te.CODES.get("b"):this.op(G.Op.WORD_BOUNDARY);break e;case te.CODES.get("B"):this.op(G.Op.NO_WORD_BOUNDARY);break e;case te.CODES.get("C"):throw new kt(ge.ERR_INVALID_ESCAPE,"\\C");case te.CODES.get("Q"):{let g=i.rest();const y=g.indexOf("\\E");y>=0?(g=g.substring(0,y),i.skipString(g),i.skipString("\\E")):i.skipString(g);let b=0;for(;b<g.length;){const D=g.codePointAt(b);this.literal(D),b+=ke.charCount(D)}break e}case te.CODES.get("z"):this.op(G.Op.END_TEXT);break e;default:i.rewindTo(u);break}else i.rewindTo(u);const B=this.newRegexp(G.Op.CHAR_CLASS);if(B.flags=this.flags,i.lookingAt("\\p")||i.lookingAt("\\P")){const g=new ai;if(this.parseUnicodeClass(i,g)){B.runes=g.toArray(),this.push(B);break e}}const f=new ai;if(this.parsePerlClassEscape(i,f)){B.runes=f.toArray(),this.push(B);break e}i.rewindTo(u),this.reuse(B),this.literal(ge.parseEscape(i));break}default:this.literal(i.pop());break}e=o}if(this.concat(),this.swapVerticalBar()&&this.pop(),this.alternate(),this.stack.length!==1)throw new kt(ge.ERR_MISSING_PAREN,this.wholeRegexp);return this.stack[0].namedGroups=this.namedGroups,this.stack[0]}parsePerlFlags(e){const t=e.pos(),n=e.rest();if(n.startsWith("(?P<")||n.startsWith("(?<")){const B=n.charAt(2)==="P"?4:3,f=n.indexOf(">");if(f<0)throw new kt(ge.ERR_INVALID_NAMED_CAPTURE,n);const g=n.substring(B,f);if(e.skipString(g),e.skip(B+1),!ge.isValidCaptureName(g))throw new kt(ge.ERR_INVALID_NAMED_CAPTURE,n.substring(0,f+1));const y=this.op(G.Op.LEFT_PAREN);if(y.cap=++this.numCap,this.namedGroups[g])throw new kt(ge.ERR_DUPLICATE_NAMED_CAPTURE,g);this.namedGroups[g]=this.numCap,y.name=g;return}e.skip(2);let i=this.flags,o=1,u=!1;e:for(;e.more();){const B=e.pop();switch(B){case te.CODES.get("i"):i|=ue.FOLD_CASE,u=!0;break;case te.CODES.get("m"):i&=-17,u=!0;break;case te.CODES.get("s"):i|=ue.DOT_NL,u=!0;break;case te.CODES.get("U"):i|=ue.NON_GREEDY,u=!0;break;case te.CODES.get("-"):if(o<0)break e;o=-1,i=~i,u=!1;break;
741case te.CODES.get(":"):case te.CODES.get(")"):if(o<0){if(!u)break e;i=~i}B===te.CODES.get(":")&&this.op(G.Op.LEFT_PAREN),this.flags=i;return;default:break e}}throw new kt(ge.ERR_INVALID_PERL_OP,e.from(t))}parsePosLookBehind(){const e=this.newRegexp(G.Op.LEFT_PAREN);return e.flags=this.flags,e.lb=++this.nlb,this.push(e)}parseNegLookBehind(){const e=this.newRegexp(G.Op.LEFT_PAREN);return e.flags=this.flags,e.lb=-++this.nlb,this.push(e)}parseVerticalBar(){this.concat(),this.swapVerticalBar()||this.op(G.Op.VERTICAL_BAR)}swapVerticalBar(){const e=this.stack.length;if(e>=3&&this.stack[e-2].op===G.Op.VERTICAL_BAR&&ge.isCharClass(this.stack[e-1])&&ge.isCharClass(this.stack[e-3])){let t=this.stack[e-1],n=this.stack[e-3];if(t.op>n.op){const i=n;n=t,t=i,this.stack[e-3]=n}return ge.mergeCharClass(n,t),this.reuse(t),this.pop(),!0}if(e>=2){const t=this.stack[e-1],n=this.stack[e-2];if(n.op===G.Op.VERTICAL_BAR)return e>=3&&this.cleanAlt(this.stack[e-3]),this.stack[e-2]=t,this.stack[e-1]=n,!0}return!1}parseRightParen(){if(this.concat(),this.swapVerticalBar()&&this.pop(),this.alternate(),this.stack.length<2)throw new kt(ge.ERR_UNEXPECTED_PAREN,this.wholeRegexp);const e=this.pop(),t=this.pop();if(t.op!==G.Op.LEFT_PAREN)throw new kt(ge.ERR_UNEXPECTED_PAREN,this.wholeRegexp);if(this.flags=t.flags,t.lb!==0){if(ge.hasCapture(e))throw new kt(ge.ERR_INVALID_CAPTURE_IN_LOOKBEHIND,this.wholeRegexp);t.lb>0?t.op=G.Op.PLB:t.op=G.Op.NLB,t.subs=[e],this.push(t);return}t.cap===0?this.push(e):(t.op=G.Op.CAPTURE,t.subs=[e],this.push(t))}parsePerlClassEscape(e,t){const n=e.pos();if((this.flags&ue.PERL_X)===0||!e.more()||e.pop()!==te.CODES.get("\\")||!e.more())return!1;e.pop();const i=e.from(n),o=xE.has(i)?xE.get(i):null;return o===null?!1:(t.appendGroup(o,(this.flags&ue.FOLD_CASE)!==0),!0)}parseNamedClass(e,t){const n=e.rest(),i=n.indexOf(":]");if(i<0)return!1;const o=n.substring(0,i+2);e.skipString(o);const u=jE.has(o)?jE.get(o):null;if(u===null)throw new kt(ge.ERR_INVALID_CHAR_RANGE,o);return t.appendGroup(u,(this.flags&ue.FOLD_CASE)!==0),!0}parseUnicodeClass(e,t){const n=e.pos();if((this.flags&ue.UNICODE_GROUPS)===0||!e.lookingAt("\\p")&&!e.lookingAt("\\P"))return!1;e.skip(1);let i=1,o=e.pop();if(o===te.CODES.get("P")&&(i=-1),!e.more())throw e.rewindTo(n),new kt(ge.ERR_INVALID_CHAR_RANGE,e.rest());o=e.pop();let u;if(o!==te.CODES.get("{"))u=ke.runeToString(o);else{const y=e.rest(),b=y.indexOf("}");if(b<0)throw e.rewindTo(n),new kt(ge.ERR_INVALID_CHAR_RANGE,e.rest());u=y.substring(0,b),e.skipString(u),e.skip(1)}u.length!==0&&u.codePointAt(0)===te.CODES.get("^")&&(i=0-i,u=u.substring(1));const B=ge.unicodeTable(u);if(B===null)throw new kt(ge.ERR_INVALID_CHAR_RANGE,e.from(n));B.sign<0&&(i=0-i);const f=B.tab,g=B.fold;if((this.flags&ue.FOLD_CASE)===0||g===null)t.appendTableWithSign(f,i);else{const y=new ai().appendTable(f).appendTable(g).cleanClass().toArray();t.appendClassWithSign(y,i)}return!0}parseClass(e){const t=e.pos();e.skip(1);const n=this.newRegexp(G.Op.CHAR_CLASS);n.flags=this.flags;const i=new ai;let o=1;e.more()&&e.lookingAt("^")&&(o=-1,e.skip(1),(this.flags&ue.CLASS_NL)===0&&i.appendRange(te.CODES.get(`
742`),te.CODES.get(`
743`)));let u=!0;for(;!e.more()||e.peek()!==te.CODES.get("]")||u;){if(e.more()&&e.lookingAt("-")&&(this.flags&ue.PERL_X)===0&&!u){const y=e.rest();if(y==="-"||!y.startsWith("-]"))throw e.rewindTo(t),new kt(ge.ERR_INVALID_CHAR_RANGE,e.rest())}u=!1;const B=e.pos();if(e.lookingAt("[:")){if(this.parseNamedClass(e,i))continue;e.rewindTo(B)}if(this.parseUnicodeClass(e,i)||this.parsePerlClassEscape(e,i))continue;e.rewindTo(B);const f=ge.parseClassChar(e,t);let g=f;if(e.more()&&e.lookingAt("-")){if(e.skip(1),e.more()&&e.lookingAt("]"))e.skip(-1);else if(g=ge.parseClassChar(e,t),g<f)throw new kt(ge.ERR_INVALID_CHAR_RANGE,e.from(B))}(this.flags&ue.FOLD_CASE)===0?i.appendRange(f,g):i.appendFoldedRange(f,g)}e.skip(1),i.cleanClass(),o<0&&i.negateClass(),n.runes=i.toArray(),this.push(n)}},me(ge,"ERR_INTERNAL_ERROR","regexp/syntax: internal error"),me(ge,"ERR_INVALID_CHAR_RANGE","invalid character class range"),me(ge,"ERR_INVALID_ESCAPE","invalid escape sequence"),me(ge,"ERR_INVALID_
743NAMED_CAPTURE","invalid named capture"),me(ge,"ERR_INVALID_PERL_OP","invalid or unsupported Perl syntax"),me(ge,"ERR_INVALID_REPEAT_OP","invalid nested repetition operator"),me(ge,"ERR_INVALID_REPEAT_SIZE","invalid repeat count"),me(ge,"ERR_MISSING_BRACKET","missing closing ]"),me(ge,"ERR_MISSING_PAREN","missing closing )"),me(ge,"ERR_MISSING_REPEAT_ARGUMENT","missing argument to repetition operator"),me(ge,"ERR_TRAILING_BACKSLASH","trailing backslash at end of expression"),me(ge,"ERR_DUPLICATE_NAMED_CAPTURE","duplicate capture group name"),me(ge,"ERR_UNEXPECTED_PAREN","unexpected )"),me(ge,"ERR_NESTING_DEPTH","expression nests too deeply"),me(ge,"ERR_LARGE","expression too large"),me(ge,"ERR_INVALID_CAPTURE_IN_LOOKBEHIND","invalid capture in lookbehind"),me(ge,"MAX_HEIGHT",1e3),me(ge,"MAX_SIZE",3355443),me(ge,"MAX_RUNES",33554432),me(ge,"ANY_TABLE",new I(new Uint32Array([0,we.MAX_RUNE,1]))),me(ge,"ASCII_TABLE",new I(new Uint32Array([0,127,1]))),me(ge,"ASCII_FOLD_TABLE",new I(new Uint32Array([0,127,1,383,383,1,8490,8490,1]))),ge),TI=class ol{static initTest(e){const t=ol.compile(e),n=new ol(t.expr,t.prog,t.numSubexp,t.longest);return n.cond=t.cond,n.prefix=t.prefix,n.prefixUTF8=t.prefixUTF8,n.prefixComplete=t.prefixComplete,n.prefixRune=t.prefixRune,n.prefilter=t.prefilter,n}static compile(e){return ol.compileImpl(e,ue.PERL,!1)}static compilePOSIX(e){return ol.compileImpl(e,ue.POSIX,!0)}static compileImpl(e,t,n){let i=wI.parse(e,t);const o=i.maxCap();i=DI.simplify(i);const u=xI.build(i),B=_I.compileRegexp(i),f=new ol(e,B,o,n);f.prefilter=u.type===ht.Type.NONE?null:u;const[g,y]=B.prefix();return f.prefixComplete=g,f.prefix=y,f.prefixUTF8=ke.stringToUtf8ByteArray(f.prefix),f.prefix.length>0&&(f.prefixRune=f.prefix.codePointAt(0)),f.namedGroups=i.namedGroups,f}static match(e,t){return ol.compile(e).match(t)}constructor(e,t,n=0,i=0){this.expr=e,this.prog=t,this.numSubexp=n,this.longest=i,this.cond=t.startCond(),this.prefix=null,this.prefixUTF8=null,this.prefixComplete=!1,this.prefixRune=0,this.machinePool=[],this.dfa=new BI(this.prog),this.onepass=pE.compile(this.prog),this.prefilter=null}matchPrefixComplete(e,t,n,i){if((n===ue.ANCHOR_START||n===ue.ANCHOR_BOTH)&&t!==0)return null;let o=-1,u=-1;const B=e.prefixLength(this);if(n===ue.UNANCHORED){const f=e.index(this,t);if(f<0)return null;o=t+f,u=o+B}else if(n===ue.ANCHOR_BOTH){if(e.endPos()!==B||e.index(this,0)!==0)return null;o=0,u=B}else if(n===ue.ANCHOR_START){if(e.index(this,0)!==0)return null;o=0,u=B}if(o<0)return null;if(i>0){const f=new Int32Array(i).fill(-1);return f[0]=o,f[1]=u,Array.from(f)}return[]}executeEngine(e,t,n,i){if(this.prefixComplete&&(i===0||this.numSubexp===0))return this.matchPrefixComplete(e,t,n,i);if(this.prefilter!==null&&n===ue.UNANCHORED&&!this.prefilter.eval(e,t))return null;if(this.onepass!==null)return pE.execute(this,e,t,n,i);if(i>0)return this.prog.numLb===0&&e.endPos()<=pd.maxBitStateLen(this.prog)?pd.execute(this,e,t,n,i):this.doExecuteNFA(e,t,n,i);if(this.prog.numLb===0){const o=this.dfa.match(e,t,n);if(o!==null)return o?[]:null;if(e.endPos()<=pd.maxBitStateLen(this.prog))return pd.execute(this,e,t,n,i)}return this.doExecuteNFA(e,t,n,i)}numberOfCapturingGroups(){return this.numSubexp}numberOfInstructions(){return this.prog.numInst()}get(){return this.machinePool.length>0?this.machinePool.pop():null}reset(){this.machinePool.length=0}put(e){this.machinePool.push(e)}toString(){return this.expr}doExecuteNFA(e,t,n,i){let o=this.get();o||(o=oI.fromRE2(this)),o.init(i);const u=o.match(e,t,n)?o.submatches():null;return this.put(o),u}match(e){return this.executeEngine(Pt.fromUTF16(e),0,ue.UNANCHORED,0)!==null}matchWithGroup(e,t,n,i,o){return e instanceof Il||(ke.isByteArray(e)?e=pl.utf8(e):e=pl.utf16(e)),this.matchMachineInput(e,t,n,i,o)}matchMachineInput(e,t,n,i,o){if(t>n)return[!1,null];const u=e.isUTF16Encoding()?Pt.fromUTF16(e.asCharSequence(),0,n):Pt.fromUTF8(e.asBytes(),0,n),B=this.executeEngine(u,t,i,2*o);return B===null?[!1,null]:[!0,B]}matchUTF8(e){return this.executeEngine(Pt.fromUTF8(e),0,ue.UNANCHORED,0)!==null}replaceAll(e,t){return this.replaceAllFunc(e,()=>t,2*e.length+1)}replaceFirst(e,t){return this.replaceAllFunc(e,()=>t,1)}replaceAllFunc(e,t,n){let i=0,o=0,u="";const B=Pt.fromUTF16(e);let f=0;for(;o<=e.length;
743){const g=this.executeEngine(B,o,ue.UNANCHORED,2);if(g===null||g.length===0)break;u+=e.substring(i,g[0]),(g[1]>i||g[0]===0)&&(u+=t(e.substring(g[0],g[1])),f++),i=g[1];const y=B.step(o)&7;if(o+y>g[1]?o+=y:o+1>g[1]?o++:o=g[1],f>=n)break}return u+=e.substring(i),u}pad(e){if(e===null)return null;let t=(1+this.numSubexp)*2;if(e.length<t){let n=new Array(t).fill(-1);for(let i=0;i<e.length;i++)n[i]=e[i];e=n}return e}allMatches(e,t,n=i=>i){let i=[];const o=e.endPos();t<0&&(t=o+1);let u=0,B=0,f=-1;for(;B<t&&u<=o;){const g=this.executeEngine(e,u,ue.UNANCHORED,this.prog.numCap);if(g===null||g.length===0)break;let y=!0;if(g[1]===u){g[0]===f&&(y=!1);const b=e.step(u);b<0?u=o+1:u+=b&7}else u=g[1];f=g[1],y&&(i.push(n(this.pad(g))),B++)}return i}findUTF8(e){const t=this.executeEngine(Pt.fromUTF8(e),0,ue.UNANCHORED,2);return t===null?null:e.slice(t[0],t[1])}findUTF8Index(e){const t=this.executeEngine(Pt.fromUTF8(e),0,ue.UNANCHORED,2);return t===null?null:t.slice(0,2)}find(e){const t=this.executeEngine(Pt.fromUTF16(e),0,ue.UNANCHORED,2);return t===null?"":e.substring(t[0],t[1])}findIndex(e){return this.executeEngine(Pt.fromUTF16(e),0,ue.UNANCHORED,2)}findUTF8Submatch(e){const t=this.executeEngine(Pt.fromUTF8(e),0,ue.UNANCHORED,this.prog.numCap);if(t===null)return null;const n=new Array(1+this.numSubexp).fill(null);for(let i=0;i<n.length;i++)2*i<t.length&&t[2*i]>=0&&(n[i]=e.slice(t[2*i],t[2*i+1]));return n}findUTF8SubmatchIndex(e){return this.pad(this.executeEngine(Pt.fromUTF8(e),0,ue.UNANCHORED,this.prog.numCap))}findSubmatch(e){const t=this.executeEngine(Pt.fromUTF16(e),0,ue.UNANCHORED,this.prog.numCap);if(t===null)return null;const n=new Array(1+this.numSubexp).fill(null);for(let i=0;i<n.length;i++)2*i<t.length&&t[2*i]>=0&&(n[i]=e.substring(t[2*i],t[2*i+1]));return n}findSubmatchIndex(e){return this.pad(this.executeEngine(Pt.fromUTF16(e),0,ue.UNANCHORED,this.prog.numCap))}findAllUTF8(e,t){const n=this.allMatches(Pt.fromUTF8(e),t,i=>e.slice(i[0],i[1]));return n.length===0?null:n}findAllUTF8Index(e,t){const n=this.allMatches(Pt.fromUTF8(e),t,i=>i.slice(0,2));return n.length===0?null:n}findAll(e,t){const n=this.allMatches(Pt.fromUTF16(e),t,i=>e.substring(i[0],i[1]));return n.length===0?null:n}findAllIndex(e,t){const n=this.allMatches(Pt.fromUTF16(e),t,i=>i.slice(0,2));return n.length===0?null:n}findAllUTF8Submatch(e,t){const n=this.allMatches(Pt.fromUTF8(e),t,i=>{let o=new Array(i.length/2|0).fill(null);for(let u=0;u<o.length;u++)i[2*u]>=0&&(o[u]=e.slice(i[2*u],i[2*u+1]));return o});return n.length===0?null:n}findAllUTF8SubmatchIndex(e,t){const n=this.allMatches(Pt.fromUTF8(e),t);return n.length===0?null:n}findAllSubmatch(e,t){const n=this.allMatches(Pt.fromUTF16(e),t,i=>{let o=new Array(i.length/2|0).fill(null);for(let u=0;u<o.length;u++)i[2*u]>=0&&(o[u]=e.substring(i[2*u],i[2*u+1]));return o});return n.length===0?null:n}findAllSubmatchIndex(e,t){const n=this.allMatches(Pt.fromUTF16(e),t);return n.length===0?null:n}},AI=class Ho{static isHexadecimal(e){return"0"<=e&&e<="9"||"A"<=e&&e<="F"||"a"<=e&&e<="f"}static translate(e){let t="";if(e instanceof RegExp&&(e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e=e.source),typeof e!="string")return e;let n="",i=!1,o=e.length;o===0&&(n="(?:)",i=!0);let u=!1,B=0;for(;B<o;){let g=e[B];if(g==="\\"){if(B+1<o)switch(g=e[B+1],g){case"\\":n+="\\\\",B+=2;continue;case"c":if(B+2<o){let D=e[B+2].charCodeAt(0);if(D>=65&&D<=90||D>=97&&D<=122){let T=D%32;n+="\\x",n+=(T>>4).toString(16).toUpperCase(),n+=(T&15).toString(16).toUpperCase(),B+=3,i=!0;continue}}n+="c",B+=2,i=!0;continue;case"u":if(B+2<o){if(e[B+2]==="{"){let D=B+3,T=!1,M=!1;for(;D<o;){const z=e[D];if(z==="}"){M=!0;break}if(!Ho.isHexadecimal(z))break;T=!0,D++}if(M&&T){n+="\\x",B+=2,i=!0;continue}}else if(B+5<o){let D=!0;for(let T=0;T<4;T++)if(!Ho.isHexadecimal(e[B+2+T])){D=!1;break}if(D){n+="\\x{"+e.substring(B+2,B+6)+"}",B+=6,i=!0;continue}}}n+="u",B+=2,i=!0;continue;case"x":{let D=!1;if(B+2<o&&e[B+2]==="{"){let T=B+3,M=!1,z=!1;for(;T<o;){const W=e[T];if(W==="}"){z=!0;break}if(!Ho.isHexadecimal(W))break;M=!0,T++}z&&M&&(D=!0)}else B+3<o&&Ho.isHexadecimal(e[B+2])&&Ho.isHexadecimal(e[B+3])&&(D=!0);D?(n+="\\x",B+=2):(n+="x",B+=2,i=!0);continue}case"n":case"r":case"t":case"a":case"f":case"v":case"d":case"D":case"s":case"S":case"w":case"W":case"b":case"B":case"p":case"P":case"A":case"z":case"Q":case"E":case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":n+="\\"+g,B+=2;continue;default:{let D=e.codePointAt(B+1);if(D>=48&&D<=57||D>=65&&D<=90||D>=97&&D<=122){let T=ke.charCount(D);n+=e.substring(B+1,B+1+T),B+=T+1,i=!0}else{n+="\\";let T=ke.charCount(D);n+=e.substring(B+1,B+1+T),B+=T+1}continue}}}else if(g==="/"){n+="\\/",B+=1,i=!0;continue}else if(g==="[")u=!0;else if(g==="]")u=!1;else if(!u&&g==="("&&B+2<o&&e[B+1]==="?"&&e[B+2]==="<"&&B+3<o&&!"=!>)".includes(e[B+3])){n+="(?P<",B+=3,i=!0;continue}let y=e.codePointAt(B),b=ke.charCount(y);n+=e.substring(B,B+b),B+=b}const f=i?n:e;return t.length>0?`(?${t})${f}`:f}},mn,uC=(mn=class{static quote(e){return ke.quoteMeta(e)}
743static quoteReplacement(e,t=!1){return hE.quoteReplacement(e,t)}static translateRegExp(e){return AI.translate(e)}static compile(e,t=0){let n=e;if((t&mn.CASE_INSENSITIVE)!==0&&(n=`(?i)${n}`),(t&mn.DOTALL)!==0&&(n=`(?s)${n}`),(t&mn.MULTILINE)!==0&&(n=`(?m)${n}`),(t&-544)!==0)throw new lI("Flags should only be a combination of MULTILINE, DOTALL, CASE_INSENSITIVE, DISABLE_UNICODE_GROUPS, LONGEST_MATCH, LOOKBEHINDS");let i=ue.PERL;(t&mn.DISABLE_UNICODE_GROUPS)!==0&&(i&=-129),(t&mn.LOOKBEHINDS)!==0&&(i|=ue.LOOKBEHIND);const o=new mn(e,t);return o.re2Input=TI.compileImpl(n,i,(t&mn.LONGEST_MATCH)!==0),o}static matches(e,t){return mn.compile(e).testExact(t)}static initTest(e,t,n){if(e==null)throw new Error("pattern is null");if(n==null)throw new Error("re2 is null");const i=new mn(e,t);return i.re2Input=n,i}constructor(e,t){this.patternInput=e,this.flagsInput=t,this.re2Input=null}reset(){this.re2Input.reset()}flags(){return this.flagsInput}pattern(){return this.patternInput}re2(){return this.re2Input}matches(e){return this.testExact(e)}matcher(e){return ke.isByteArray(e)&&(e=pl.utf8(e)),new hE(this,e)}test(e){return ke.isByteArray(e)?this.re2Input.matchUTF8(e):this.re2Input.match(e)}testExact(e){const t=ke.isByteArray(e)?Pt.fromUTF8(e):Pt.fromUTF16(e);return this.re2Input.executeEngine(t,0,ue.ANCHOR_BOTH,0)!==null}exec(e){const t=this.matcher(e);if(!t.find())return null;const n=[t.group(0)];for(let o=1;o<=t.groupCount();o++){const u=t.group(o);n.push(u===null?void 0:u)}n.index=t.start(0),n.input=e;const i=this.namedGroups();if(Object.keys(i).length>0){const o=t.getNamedGroups();for(const u in o)o[u]===null&&(o[u]=void 0);n.groups=o}else n.groups=void 0;return n}split(e,t=0){const n=this.matcher(e),i=[];let o=0,u=0;for(;n.find();){if(u===0&&n.end()===0){u=n.end();continue}if(t>0&&i.length===t-1)break;if(u===n.start()){if(t===0){o+=1,u=n.end();continue}}else for(;o>0;)i.push(""),o-=1;i.push(n.substring(u,n.start())),u=n.end()}if(t===0&&u!==n.inputLength()){for(;o>0;)i.push(""),o-=1;i.push(n.substring(u,n.inputLength()))}return(t!==0||i.length===0&&!(u===n.inputLength()&&u>0))&&i.push(n.substring(u,n.inputLength())),i}*matchAll(e){const t=this.matcher(e);for(;t.find();){const n=[t.group(0)];for(let o=1;o<=t.groupCount();o++){const u=t.group(o);n.push(u===null?void 0:u)}n.index=t.start(0),n.input=e;const i=this.namedGroups();if(Object.keys(i).length>0){const o=t.getNamedGroups();for(const u in o)o[u]===null&&(o[u]=void 0);n.groups=o}else n.groups=void 0;yield n}}toString(){return this.patternInput}programSize(){return this.re2Input.numberOfInstructions()}groupCount(){return this.re2Input.numberOfCapturingGroups()}namedGroups(){return this.re2Input.namedGroups}equals(e){return this===e?!0:e===null||this.constructor!==e.constructor?!1:this.flagsInput===e.flagsInput&&this.patternInput===e.patternInput}},me(mn,"CASE_INSENSITIVE",Oo.CASE_INSENSITIVE),me(mn,"DOTALL",Oo.DOTALL),me(mn,"MULTILINE",Oo.MULTILINE),me(mn,"DISABLE_UNICODE_GROUPS",Oo.DISABLE_UNICODE_GROUPS),me(mn,"LONGEST_MATCH",Oo.LONGEST_MATCH),me(mn,"LOOKBEHINDS",Oo.LOOKBEHINDS),mn);/**
744 * @license
745 * Copyright 2017 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 */let wu="12.17.0";function NI(r){wu=r}/**
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 *//**
774 * @license
775 * Copyright 2017 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 */const Sl=new y1("@firebase/firestore");function Uo(){return Sl.logLevel}function Be(r,...e){if(Sl.logLevel<=ut.DEBUG){const t=e.map(cC);Sl.debug(`Firestore (${wu}): ${r}`,...t)}}function sn(r,...e){if(Sl.logLevel<=ut.ERROR){const t=e.map(cC);Sl.error(`Firestore (${wu}): ${r}`,...t)}}function lr(r,...e){if(Sl.logLevel<=ut.WARN){const t=e.map(cC);Sl.warn(`Firestore (${wu}): ${r}`,...t)}}function cC(r){if(typeof r=="string")return r;try{return(function(t){return JSON.stringify(t)})(r)}catch{return r}}/**
789 * @license
790 * Copyright 2017 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 */function Te(r,e,t){let n="Unexpected state";typeof e=="string"?n=e:t=e,j1(r,n,t)}function j1(r,e,t){let n=`FIRESTORE (${wu}) INTERNAL ASSERTION FAILED: ${e} (ID: ${r.toString(16)})`;if(t!==void 0)try{n+=" CONTEXT: "+JSON.stringify(t)}catch{n+=" CONTEXT: "+t}throw sn(n),new Error(n)}function fe(r,e,t,n){let i="Unexpected state";typeof t=="string"?i=t:n=t,r||j1(e,i,n)}function Se(r,e){return r}/**
804 * @license
805 * Copyright 2020 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 */function II(r){const e=typeof self<"u"&&(self.crypto||self.msCrypto),t=new Uint8Array(r);if(e&&typeof e.getRandomValues=="function")e.getRandomValues(t);else for(let n=0;n<r;n++)t[n]=Math.floor(256*Math.random());return t}/**
819 * @license
820 * Copyright 2017 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 BC{static newId(){const e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",t=62*Math.floor(4.129032258064516);let n="";for(;n.length<20;){const i=II(40);for(let o=0;o<i.length;++o)n.length<20&&i[o]<t&&(n+=e.charAt(i[o]%62))}return n}}function Ue(r,e){return r<e?-1:r>e?1:0}function wg(r,e){const t=Math.min(r.length,e.length);for(let n=0;n<t;n++){const i=r.charAt(n),o=e.charAt(n);if(i!==o)return rg(i)===rg(o)?Ue(i,o):rg(i)?1:-1}return Ue(r.length,e.length)}const SI=55296,RI=57343;function rg(r){const e=r.charCodeAt(0);return e>=SI&&e<=RI}function nu(r,e,t){return r.length===e.length&&r.every(((n,i)=>t(n,e[i])))}function M1(r){return r+"\0"}/**
834 * @license
835 * Copyright 2017 Google LLC
836 *
837 * Licensed under the Apache License, Version 2.0 (the "License");
vendor: 5,212 bytes, lines 838-848
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 */class Rt{constructor(e,t){this.comparator=e,this.root=t||Ln.EMPTY}insert(e,t){return new Rt(this.comparator,this.root.insert(e,t,this.comparator).copy(null,null,Ln.BLACK,null,null))}remove(e){return new Rt(this.comparator,this.root.remove(e,this.comparator).copy(null,null,Ln.BLACK,null,null))}get(e){let t=this.root;for(;!t.isEmpty();){const n=this.comparator(e,t.key);if(n===0)return t.value;n<0?t=t.left:n>0&&(t=t.right)}return null}indexOf(e){let t=0,n=this.root;for(;!n.isEmpty();){const i=this.comparator(e,n.key);if(i===0)return t+n.left.size;i<0?n=n.left:(t+=n.left.size+1,n=n.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(((t,n)=>(e(t,n),!1)))}toString(){const e=[];return this.inorderTraversal(((t,n)=>(e.push(`${t}:${n}`),!1))),`{${e.join(", ")}}`}reverseTraversal(e){return this.root.reverseTraversal(e)}getIterator(){return new Cd(this.root,null,this.comparator,!1)}getIteratorFrom(e){return new Cd(this.root,e,this.comparator,!1)}getReverseIterator(){return new Cd(this.root,null,this.comparator,!0)}getReverseIteratorFrom(e){return new Cd(this.root,e,this.comparator,!0)}}class Cd{constructor(e,t,n,i){this.isReverse=i,this.nodeStack=[];let o=1;for(;!e.isEmpty();)if(o=t?n(e.key,t):1,t&&i&&(o*=-1),o<0)e=this.isReverse?e.left:e.right;else{if(o===0){this.nodeStack.push(e);break}this.nodeStack.push(e),e=this.isReverse?e.right:e.left}}getNext(){let e=this.nodeStack.pop();const t={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 t}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 Ln{constructor(e,t,n,i,o){this.key=e,this.value=t,this.color=n??Ln.RED,this.left=i??Ln.EMPTY,this.right=o??Ln.EMPTY,this.size=this.left.size+1+this.right.size}copy(e,t,n,i,o){return new Ln(e??this.key,t??this.value,n??this.color,i??this.left,o??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,t,n){let i=this;const o=n(e,i.key);return i=o<0?i.copy(null,null,null,i.left.insert(e,t,n),null):o===0?i.copy(null,t,null,null,null):i.copy(null,null,null,null,i.right.insert(e,t,n)),i.fixUp()}removeMin(){if(this.left.isEmpty())return Ln.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,t){let n,i=this;if(t(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,t),null);else{if(i.left.isRed()&&(i=i.rotateRight()),i.right.isEmpty()||i.right.isRed()||i.right.left.isRed()||(i=i.moveRedRight()),t(e,i.key)===0){if(i.right.isEmpty())return Ln.EMPTY;n=i.right.min(),i=i.copy(n.key,n.value,null,null,i.right.removeMin())}i=i.copy(null,null,null,null,i.right.remove(e,t))}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,Ln.RED,null,this.right.left);return this.right.copy(null,null,this.color,e,null)}rotateRight(){const e=this.copy(null,null,Ln.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),t=this.right.copy(null,null,!this.right.color,null,null);return this.copy(null,null,!this.color,e,t)}checkMaxDepth(){const e=this.check();return Math.pow(2,e)<=this.size+1}check(){if(this.isRed()&&this.left.isRed())throw Te(43730,{key:this.key,value:this.value});if(this.right.isRed())throw Te(14113,{key:this.key,value:this.value});const e=this.left.check();if(e!==this.right.check())throw Te(27949);return e+(this.isRed()?0:1)}}Ln.EMPTY=null,Ln.RED=!0,Ln.BLACK=!1;
vendor: 4,296 bytes, lines 848-888
848Ln.EMPTY=new class{constructor(){this.size=0}get key(){throw Te(57766)}get value(){throw Te(16141)}get color(){throw Te(16727)}get left(){throw Te(29726)}get right(){throw Te(36894)}copy(e,t,n,i,o){return this}insert(e,t,n){return new Ln(e,t)}remove(e,t){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}};/**
849 * @license
850 * Copyright 2017 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 */class gt{constructor(e){this.comparator=e,this.data=new Rt(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(((t,n)=>(e(t),!1)))}forEachInRange(e,t){const n=this.data.getIteratorFrom(e[0]);for(;n.hasNext();){const i=n.getNext();if(this.comparator(i.key,e[1])>=0)return;t(i.key)}}forEachWhile(e,t){let n;for(n=t!==void 0?this.data.getIteratorFrom(t):this.data.getIterator();n.hasNext();)if(!e(n.getNext().key))return}firstAfterOrEqual(e){const t=this.data.getIteratorFrom(e);return t.hasNext()?t.getNext().key:null}getIterator(){return new ME(this.data.getIterator())}getIteratorFrom(e){return new ME(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 t=this;return t.size<e.size&&(t=e,e=this),e.forEach((n=>{t=t.add(n)})),t}isEqual(e){if(!(e instanceof gt)||this.size!==e.size)return!1;const t=this.data.getIterator(),n=e.data.getIterator();for(;t.hasNext();){const i=t.getNext().key,o=n.getNext().key;if(this.comparator(i,o)!==0)return!1}return!0}toArray(){const e=[];return this.forEach((t=>{e.push(t)})),e}toString(){const e=[];return this.forEach((t=>e.push(t))),"SortedSet("+e.toString()+")"}copy(e){const t=new gt(this.comparator);return t.data=e,t}}class ME{constructor(e){this.iter=e}getNext(){return this.iter.getNext().key}hasNext(){return this.iter.hasNext()}}function ko(r){return r.hasNext()?r.getNext():void 0}/**
864 * @license
865 * Copyright 2017 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 */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 ve extends vu{constructor(e,t){super(e,t),this.code=e,this.message=t,this.toString=()=>`${this.name}: [code=${this.code}]: ${this.message}`}}/**
879 * @license
880 * Copyright 2017 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, softw
888are
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 */const su="__name__";class Nr{constructor(e,t,n){t===void 0?t=0:t>e.length&&Te(637,{offset:t,range:e.length}),n===void 0?n=e.length-t:n>e.length-t&&Te(1746,{length:n,range:e.length-t}),this.segments=e,this.offset=t,this.len=n}get length(){return this.len}isEqual(e){return Nr.comparator(this,e)===0}child(e){const t=this.segments.slice(this.offset,this.limit());return e instanceof Nr?e.forEach((n=>{t.push(n)})):t.push(e),this.construct(t)}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 t=0;t<this.length;t++)if(this.get(t)!==e.get(t))return!1;return!0}isImmediateParentOf(e){if(this.length+1!==e.length)return!1;for(let t=0;t<this.length;t++)if(this.get(t)!==e.get(t))return!1;return!0}forEach(e){for(let t=this.offset,n=this.limit();t<n;t++)e(this.segments[t])}toArray(){return this.segments.slice(this.offset,this.limit())}static comparator(e,t){const n=Math.min(e.length,t.length);for(let i=0;i<n;i++){const o=Nr.compareSegments(e.get(i),t.get(i));if(o!==0)return o}return Ue(e.length,t.length)}static compareSegments(e,t){const n=Nr.isNumericId(e),i=Nr.isNumericId(t);return n&&!i?-1:!n&&i?1:n&&i?Nr.extractNumericId(e).compare(Nr.extractNumericId(t)):wg(e,t)}static isNumericId(e){return e.startsWith("__id")&&e.endsWith("__")}static extractNumericId(e){return Ci.fromString(e.substring(4,e.length-2))}}class ct extends Nr{construct(e,t,n){return new ct(e,t,n)}canonicalString(){return this.toArray().join("/")}toString(){return this.canonicalString()}toStringWithLeadingSlash(){return`/${this.canonicalString()}`}toUriEncodedString(){return this.toArray().map(encodeURIComponent).join("/")}static fromString(...e){const t=[];for(const n of e){if(n.indexOf("//")>=0)throw new ve(le.INVALID_ARGUMENT,`Invalid segment (${n}). Paths must not contain // in them.`);t.push(...n.split("/").filter((i=>i.length>0)))}return new ct(t)}static emptyPath(){return new ct([])}}const OI=/^[_a-zA-Z][_a-zA-Z0-9]*$/;let bn=class zo extends Nr{construct(e,t,n){return new zo(e,t,n)}static isValidIdentifier(e){return OI.test(e)}canonicalString(){return this.toArray().map((e=>(e=e.replace(/\\/g,"\\\\").replace(/`/g,"\\`"),zo.isValidIdentifier(e)||(e="`"+e+"`"),e))).join(".")}toString(){return this.canonicalString()}isKeyField(){return this.length===1&&this.get(0)===su}static keyField(){return new zo([su])}static fromServerFormat(e){const t=[];let n="",i=0;const o=()=>{if(n.length===0)throw new ve(le.INVALID_ARGUMENT,`Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`);t.push(n),n=""};let u=!1;for(;i<e.length;){const B=e[i];if(B==="\\"){if(i+1===e.length)throw new ve(le.INVALID_ARGUMENT,"Path has trailing escape character: "+e);const f=e[i+1];if(f!=="\\"&&f!=="."&&f!=="`")throw new ve(le.INVALID_ARGUMENT,"Path has invalid escape sequence: "+e);n+=f,i+=2}else B==="`"?(u=!u,i++):B!=="."||u?(n+=B,i++):(o(),i++)}if(o(),u)throw new ve(le.INVALID_ARGUMENT,"Unterminated ` in path: "+e);return new zo(t)}static emptyPath(){return new zo([])}};/**
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 */class qs{constructor(e){this.fields=e,e.sort(bn.comparator)}static empty(){return new qs([])}unionWith(e){let t=new gt(bn.comparator);for(const n of this.fields)t=t.add(n);for(const n of e)t=t.add(n);return new qs(t.toArray())}covers(e){for(const t of this.fields)if(t.isPrefixOf(e))return!0;return!1}isEqual(e){return nu(this.fields,e.fields,((t,n)=>t.isEqual(n)))}}/**
909 * @license
910 * Copyright 2017 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 */function Ud(r){let e=0;for(const t in r)Object.prototype.hasOwnProperty.call(r,t)&&e++;return e}function Vl(r,e){for(const t in r)Object.prototype.hasOwnProperty.call(r,t)&&e(t,r[t])}function kI(r,e){const t=[];for(const n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.push(e(r[n],n,r));return t}function P1(r){for(const e in r)if(Object.prototype.hasOwnProperty.call(r,e))return!1;return!0}/**
924 * @license
925 * Copyright 2017 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 De{constructor(e){this.path=e}static fromPath(e){return new De(ct.fromString(e))}static fromName(e){return new De(ct.fromString(e).popFirst(5))}static empty(){return new De(ct.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&&ct.comparator(this.path,e.path)===0}toString(){return this.path.toString()}static comparator(e,t){return ct.comparator(e.path,t.path)}static isDocumentKey(e){return e.length%2==0}static fromSegments(e){return new De(new ct(e.slice()))}}/**
939 * @license
940 * Copyright 2017 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 */function LI(r,e,t){if(!t)throw new ve(le.INVALID_ARGUMENT,`Function ${r}() cannot be called with an empty ${e}.`)}function jI(r,e,t,n){if(e===!0&&n===!0)throw new ve(le.INVALID_ARGUMENT,`${r} and ${t} cannot be used together.`)}function PE(r){if(!De.isDocumentKey(r))throw new ve(le.INVALID_ARGUMENT,`Invalid document reference. Document references must have an even number of segments, but ${r} has ${r.length}.`)}function SB(r){return typeof r=="object"&&r!==null&&(Object.getPrototypeOf(r)===Object.prototype||Object.getPrototypeOf(r)===null)}function hC(r){if(r===void 0)return"undefined";if(r===null)return"null";if(typeof r=="string")return r.length>20&&(r=`${r.substring(0,20)}...`),JSON.stringify(r);if(typeof r=="number"||typeof r=="boolean")return""+r;if(typeof r=="object"){if(r instanceof Array)return"an array";{const e=(function(n){return n.constructor?n.constructor.name:null})(r);return e?`a custom ${e} object`:"an object"}}return typeof r=="function"?"a function":Te(12329,{type:typeof r})}function da(r,e){if("_delegate"in r&&(r=r._delegate),!(r instanceof e)){if(e.name===r.constructor.name)throw new ve(le.INVALID_ARGUMENT,"Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?");{const t=hC(r);throw new ve(le.INVALID_ARGUMENT,`Expected type '${e.name}', but it was: ${t}`)}}return r}/**
954 * @license
955 * Copyright 2025 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, software
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 */function pn(r,e){const t={typeString:r};return e&&(t.value=e),t}function RB(r,e){if(!SB(r))throw new ve(le.INVALID_ARGUMENT,"JSON must be an object");let t;for(const n in e)if(e[n]){const i=e[n].typeString,o="value"in e[n]?{value:e[n].value}:void 0;if(!(n in r)){t=`JSON missing required field: '${n}'`;break}const u=r[n];if(i&&typeof u!==i){t=`JSON field '${n}' must be a ${i}.`;break}if(o!==void 0&&u!==o.value){t=`Expected '${n}' field to equal '${o.value}'`;break}}if(t)throw new ve(le.INVALID_ARGUMENT,t);return!0}/**
969 * @license
970 * Copyright 2017 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 */const VE=-62135596800,FE=1e6;class xt{static now(){return xt.fromMillis(Date.now())}static fromDate(e){return xt.fromMillis(e.getTime())}static fromMillis(e){const t=Math.floor(e/1e3),n=Math.floor((e-1e3*t)*FE);return new xt(t,n)}constructor(e,t){if(this.seconds=e,this.nanoseconds=t,t<0)throw new ve(le.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+t);if(t>=1e9)throw new ve(le.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+t);if(e<VE)throw new ve(le.INVALID_ARGUMENT,"Timestamp seconds out of range: "+e);if(e>=253402300800)throw new ve(le.INVALID_ARGUMENT,"Timestamp seconds out of range: "+e)}toDate(){return new Date(this.toMillis())}toMillis(){return 1e3*this.seconds+this.nanoseconds/FE}_compareTo(e){return this.seconds===e.seconds?Ue(this.nanoseconds,e.nanoseconds):Ue(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{type:xt._jsonSchemaVersion,seconds:this.seconds,nanoseconds:this.nanoseconds}}static fromJSON(e){if(RB(e,xt._jsonSchema))return new xt(e.seconds,e.nanoseconds)}valueOf(){const e=this.seconds-VE;return String(e).padStart(12,"0")+"."+String(this.nanoseconds).padStart(9,"0")}}xt._jsonSchemaVersion="firestore/timestamp/1.0",xt._jsonSchema={type:pn("string",xt._jsonSchemaVersion),seconds:pn("number"),nanoseconds:pn("number")};/**
984 * @license
985 * Copyright 2023 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 V1 extends Error{constructor(){super(...arguments),this.name="Base64DecodeError"}}/**
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 qt{constructor(e){this.binaryString=e}static fromBase64String(e){const t=(function(i){try{return atob(i)}catch(o){throw typeof DOMException<"u"&&o instanceof DOMException?new V1("Invalid base64 string: "+o):o}})(e);return new qt(t)}static fromUint8Array(e){const t=(function(i){let o="";for(let u=0;u<i.length;++u)o+=String.fromCharCode(i[u]);return o}
1013)(e);return new qt(t)}[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(t){return btoa(t)})(this.binaryString)}toUint8Array(){return(function(t){const n=new Uint8Array(t.length);for(let i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return n})(this.binaryString)}approximateByteSize(){return 2*this.binaryString.length}compareTo(e){return Ue(this.binaryString,e.binaryString)}isEqual(e){return this.binaryString===e.binaryString}}qt.EMPTY_BYTE_STRING=new qt("");const MI=new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);function Ca(r){if(fe(!!r,39018),typeof r=="string"){let e=0;const t=MI.exec(r);if(fe(!!t,46558,{timestamp:r}),t[1]){let i=t[1];i=(i+"000000000").substr(0,9),e=Number(i)}const n=new Date(r);return{seconds:Math.floor(n.getTime()/1e3),nanos:e}}return{seconds:Lt(r.seconds),nanos:Lt(r.nanos)}}function Lt(r){return typeof r=="number"?r:typeof r=="string"?Number(r):0}function ya(r){return typeof r=="string"?qt.fromBase64String(r):qt.fromUint8Array(r)}/**
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 */const F1="server_timestamp",G1="__type__",H1="__previous_value__",U1="__local_write_time__";function pf(r){var t,n;return((n=(((t=r==null?void 0:r.mapValue)==null?void 0:t.fields)||{})[G1])==null?void 0:n.stringValue)===F1}function OB(r){const e=r.mapValue.fields[H1];return pf(e)?OB(e):e}function ru(r){const e=Ca(r.mapValue.fields[U1].timestampValue);return new xt(e.seconds,e.nanos)}/**
1029 * @license
1030 * Copyright 2017 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 */class PI{constructor(e,t,n,i,o,u,B,f,g,y,b,D,T){this.databaseId=e,this.appId=t,this.persistenceKey=n,this.host=i,this.ssl=o,this.forceLongPolling=u,this.autoDetectLongPolling=B,this.longPollingOptions=f,this.useFetchStreams=g,this.isUsingEmulator=y,this.apiKey=b,this._customHeaders=D,this.grpcFlowControlWindow=T}}const zd="(default)";class Rl{constructor(e,t){this.projectId=e,this.database=t||zd}static empty(){return new Rl("","")}get isDefaultDatabase(){return this.database===zd}isEqual(e){return e instanceof Rl&&e.projectId===this.projectId&&e.database===this.database}}function VI(r,e){if(!Object.prototype.hasOwnProperty.apply(r.options,["projectId"]))throw new ve(le.INVALID_ARGUMENT,'"projectId" not provided in firebase.initializeApp.');return new Rl(r.options.projectId,e)}/**
1044 * @license
1045 * Copyright 2017 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 */const xl=-1;function gf(r){return r==null}
1058function au(r){return r===0&&1/r==-1/0}function z1(r){return typeof r=="number"&&Number.isInteger(r)&&!au(r)&&r<=Number.MAX_SAFE_INTEGER&&r>=Number.MIN_SAFE_INTEGER}function FI(r){return typeof r=="string"}/**
1059 * @license
1060 * Copyright 2020 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 */const dC="__type__",q1="__max__",mi={mapValue:{fields:{__type__:{stringValue:q1}}}},fC="__vector__",Ol="value",Mr={nullValue:"NULL_VALUE"},os={booleanValue:!0},An={booleanValue:!1};function gn(r){return"nullValue"in r?0:"booleanValue"in r?1:"integerValue"in r||"doubleValue"in r?2:"timestampValue"in r?3:"stringValue"in r?5:"bytesValue"in r?6:"referenceValue"in r?7:"geoPointValue"in r?8:"arrayValue"in r?9:"mapValue"in r?pf(r)?4:K1(r)?9007199254740991:kl(r)?10:11:Te(28295,{value:r})}function Js(r,e,t){if(r===e)return!0;const n=gn(r);if(n!==gn(e))return!1;switch(n){case 0:case 9007199254740991:return!0;case 1:return r.booleanValue===e.booleanValue;case 4:return ru(r).isEqual(ru(e));case 3:return(function(o,u){if(typeof o.timestampValue=="string"&&typeof u.timestampValue=="string"&&o.timestampValue.length===u.timestampValue.length)return o.timestampValue===u.timestampValue;const B=Ca(o.timestampValue),f=Ca(u.timestampValue);return B.seconds===f.seconds&&B.nanos===f.nanos})(r,e);case 5:return r.stringValue===e.stringValue;case 6:return(function(o,u){return ya(o.bytesValue).isEqual(ya(u.bytesValue))})(r,e);case 7:return r.referenceValue===e.referenceValue;case 8:return(function(o,u){return Lt(o.geoPointValue.latitude)===Lt(u.geoPointValue.latitude)&&Lt(o.geoPointValue.longitude)===Lt(u.geoPointValue.longitude)})(r,e);case 2:return(function(o,u,B){if("integerValue"in o&&"integerValue"in u)return Lt(o.integerValue)===Lt(u.integerValue);let f,g;if("doubleValue"in o&&"doubleValue"in u)f=Lt(o.doubleValue),g=Lt(u.doubleValue);else{if(!(B!=null&&B.t))return!1;f=Lt(o.integerValue??o.doubleValue),g=Lt(u.integerValue??u.doubleValue)}return f===g?!!(B!=null&&B.i)||au(f)===au(g):!!(B===void 0||B.o)&&isNaN(f)&&isNaN(g)})(r,e,t);case 9:return nu(r.arrayValue.values||[],e.arrayValue.values||[],((i,o)=>Js(i,o,t)));case 10:case 11:return(function(o,u,B){const f=o.mapValue.fields||{},g=u.mapValue.fields||{};if(Ud(f)!==Ud(g))return!1;for(const y in f)if(f.hasOwnProperty(y)&&(g[y]===void 0||!Js(f[y],g[y],B)))return!1;return!0})(r,e,t);default:return Te(52216,{left:r})}}function cB(r,e){return(r.values||[]).find((t=>Js(t,e)))!==void 0}function Hn(r,e){if(r===e)return 0;const t=gn(r),n=gn(e);if(t!==n)return Ue(t,n);switch(t){case 0:case 9007199254740991:return 0;case 1:return Ue(r.booleanValue,e.booleanValue);case 2:return(function(o,u){const B=Lt(o.integerValue||o.doubleValue),f=Lt(u.integerValue||u.doubleValue);return B<f?-1:B>f?1:B===f?0:isNaN(B)?isNaN(f)?0:-1:1})(r,e);case 3:return GE(r.timestampValue,e.timestampValue);case 4:return GE(ru(r),ru(e));case 5:return wg(r.stringValue,e.stringValue);case 6:return(function(o,u){const B=ya(o),f=ya(u);return B.compareTo(f)})(r.bytesValue,e.bytesValue);case 7:return(function(o,u){const B=o.split("/"),f=u.split("/");for(let g=0;g<B.length&&g<f.length;g++){const y=Ue(B[g],f[g]);if(y!==0)return y}return Ue(B.length,f.length)})(r.referenceValue,e.referenceValue);case 8:return(function(o,u){const B=Ue(Lt(o.latitude),Lt(u.latitude));return B!==0?B:Ue(Lt(o.longitude),Lt(u.longitude))})(r.geoPointValue,e.geoPointValue);case 9:return HE(r.arrayValue,e.arrayValue);case 10:return(function(o,u){var D,T,M,z;const B=o.fields||{},f=u.fields||{},g=(D=B[Ol])==null?void 0:D.arrayValue,y=(T=f[Ol])==null?void 0:T.arrayValue,b=Ue(((M=g==null?void 0:g.values)==null?void 0:M.length)||0,((z=y==null?void 0:y.values)==null?void 0:z.length)||0);return b!==0?b:HE(g,y)})(r.mapValue,e.mapValue);
1073case 11:return(function(o,u){if(o===mi.mapValue&&u===mi.mapValue)return 0;if(o===mi.mapValue)return 1;if(u===mi.mapValue)return-1;const B=o.fields||{},f=Object.keys(B),g=u.fields||{},y=Object.keys(g);f.sort(),y.sort();for(let b=0;b<f.length&&b<y.length;++b){const D=wg(f[b],y[b]);if(D!==0)return D;const T=Hn(B[f[b]],g[y[b]]);if(T!==0)return T}return Ue(f.length,y.length)})(r.mapValue,e.mapValue);default:throw Te(23264,{u:t})}}function GE(r,e){if(typeof r=="string"&&typeof e=="string"&&r.length===e.length)return Ue(r,e);const t=Ca(r),n=Ca(e),i=Ue(t.seconds,n.seconds);return i!==0?i:Ue(t.nanos,n.nanos)}function HE(r,e){const t=r.values||[],n=e.values||[];for(let i=0;i<t.length&&i<n.length;++i){const o=Hn(t[i],n[i]);if(o!==void 0&&o!==0)return o}return Ue(t.length,n.length)}function iu(r){return Tg(r)}function Tg(r){return"nullValue"in r?"null":"booleanValue"in r?""+r.booleanValue:"integerValue"in r?""+r.integerValue:"doubleValue"in r?""+r.doubleValue:"timestampValue"in r?(function(t){const n=Ca(t);return`time(${n.seconds},${n.nanos})`})(r.timestampValue):"stringValue"in r?r.stringValue:"bytesValue"in r?(function(t){return ya(t).toBase64()})(r.bytesValue):"referenceValue"in r?(function(t){return De.fromName(t).toString()})(r.referenceValue):"geoPointValue"in r?(function(t){return`geo(${t.latitude},${t.longitude})`})(r.geoPointValue):"arrayValue"in r?(function(t){let n="[",i=!0;for(const o of t.values||[])i?i=!1:n+=",",n+=Tg(o);return n+"]"})(r.arrayValue):"mapValue"in r?(function(t){const n=Object.keys(t.fields||{}).sort();let i="{",o=!0;for(const u of n)o?o=!1:i+=",",i+=`${u}:${Tg(t.fields[u])}`;return i+"}"})(r.mapValue):Te(61005,{value:r})}function Id(r){switch(gn(r)){case 0:case 1:return 4;case 2:return 8;case 3:case 8:return 16;case 4:const e=OB(r);return e?16+Id(e):16;case 5:return 2*r.stringValue.length;case 6:return ya(r.bytesValue).approximateByteSize();case 7:return r.referenceValue.length;case 9:return(function(n){return(n.values||[]).reduce(((i,o)=>i+Id(o)),0)})(r.arrayValue);case 10:case 11:return(function(n){let i=0;return Vl(n.fields,((o,u)=>{i+=o.length+Id(u)})),i})(r.mapValue);default:throw Te(13486,{value:r})}}function mC(r,e){return{referenceValue:`projects/${r.projectId}/databases/${r.database}/documents/${e.path.canonicalString()}`}}function Rr(r){return!!r&&"integerValue"in r}function gl(r){return!!r&&"doubleValue"in r}function Ei(r){return Rr(r)||gl(r)}function _i(r){return!!r&&"arrayValue"in r}function _s(r){return!!r&&"nullValue"in r}function us(r){return!!r&&"doubleValue"in r&&isNaN(Number(r.doubleValue))}function El(r){return!!r&&"mapValue"in r}function kl(r){var t,n;return((n=(((t=r==null?void 0:r.mapValue)==null?void 0:t.fields)||{})[dC])==null?void 0:n.stringValue)===fC}function Ag(r){var e,t;return(t=(((e=r==null?void 0:r.mapValue)==null?void 0:e.fields)||{})[Ol])==null?void 0:t.arrayValue}function Yc(r){if(r.geoPointValue)return{geoPointValue:{...r.geoPointValue}};if(r.timestampValue&&typeof r.timestampValue=="object")return{timestampValue:{...r.timestampValue}};if(r.mapValue){const e={mapValue:{fields:{}}};return Vl(r.mapValue.fields,((t,n)=>e.mapValue.fields[t]=Yc(n))),e}if(r.arrayValue){const e={arrayValue:{values:[]}};for(let t=0;t<(r.arrayValue.values||[]).length;++t)e.arrayValue.values[t]=Yc(r.arrayValue.values[t]);return e}return{...r}}function K1(r){return(((r.mapValue||{}).fields||{}).__type__||{}).stringValue===q1}const J1={mapValue:{fields:{[dC]:{stringValue:fC},[Ol]:{arrayValue:{}}}}};function GI(r){return"nullValue"in r?Mr:"booleanValue"in r?{booleanValue:!1}:"integerValue"in r||"doubleValue"in r?{doubleValue:NaN}:"timestampValue"in r?{timestampValue:{seconds:Number.MIN_SAFE_INTEGER}}:"stringValue"in r?{stringValue:""}:"bytesValue"in r?{bytesValue:""}:"referenceValue"in r?mC(Rl.empty(),De.empty()):"geoPointValue"in r?{geoPointValue:{latitude:-90,longitude:-180}}:"arrayValue"in r?{arrayValue:{}}:"mapValue"in r?kl(r)?J1:{mapValue:{}}:Te(35942,{value:r})}function HI(r){return"nullValue"in r?{booleanValue:!1}:"booleanValue"in r?{doubleValue:NaN}:"integerValue"in r||"doubleValue"in r?{timestampValue:{seconds:Number.MIN_SAFE_INTEGER}}:"timestampValue"in r?{stringValue:""}:"stringValue"in r?{bytesValue:""}
vendor: 2,319 bytes, lines 1073-1088
1073:"bytesValue"in r?mC(Rl.empty(),De.empty()):"referenceValue"in r?{geoPointValue:{latitude:-90,longitude:-180}}:"geoPointValue"in r?{arrayValue:{}}:"arrayValue"in r?J1:"mapValue"in r?kl(r)?{mapValue:{}}:mi:Te(61959,{value:r})}function UE(r,e){const t=Hn(r.value,e.value);return t!==0?t:r.inclusive&&!e.inclusive?-1:!r.inclusive&&e.inclusive?1:0}function zE(r,e){const t=Hn(r.value,e.value);return t!==0?t:r.inclusive&&!e.inclusive?1:!r.inclusive&&e.inclusive?-1:0}/**
1074 * @license
1075 * Copyright 2017 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 */class Qn{constructor(e){this.value=e}static empty(){return new Qn({mapValue:{}})}field(e){if(e.isEmpty())return this.value;{let t=this.value;for(let n=0;n<e.length-1;++n)if(t=(t.mapValue.fields||{})[e.get(n)],!El(t))return null;return t=(t.mapValue.fields||{})[e.lastSegment()],t||null}}set(e,t){this.getFieldsMap(e.popLast())[e.lastSegment()]=Yc(t)}setAll(e){let t=bn.emptyPath(),n={},i=[];e.forEach(((u,B)=>{if(!t.isImmediateParentOf(B)){const f=this.getFieldsMap(t);this.applyChanges(f,n,i),n={},i=[],t=B.popLast()}u?n[B.lastSegment()]=Yc(u):i.push(B.lastSegment())}));const o=this.getFieldsMap(t);this.applyChanges(o,n,i)}delete(e){const t=this.field(e.popLast());El(t)&&t.mapValue.fields&&delete t.mapValue.fields[e.lastSegment()]}isEqual(e){return Js(this.value,e.value)}getFieldsMap(e){let t=this.value;t.mapValue.fields||(t.mapValue={fields:{}});for(let n=0;n<e.length;++n){let i=t.mapValue.fields[e.get(n)];El(i)&&i.mapValue.fields||(i={mapValue:{fields:{}}},t.mapValue.fields[e.get(n)]=i),t=i}return t.mapValue.fields}applyChanges(e,t,n){Vl(t,((i,o)=>e[i]=o));for(const i of n)delete e[i]}clone(){return new Qn(Yc(this.value))}}function Q1(r){const e=[];return Vl(r.fields,((t,n)=>{const i=new bn([t]);if(El(n)){const o=Q1(n.mapValue).fields;
1088if(o.length===0)e.push(i);else for(const u of o)e.push(i.child(u))}else e.push(i)})),new qs(e)}/**
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 */function Cf(r,e){if(r.useProto3Json){if(isNaN(e))return{doubleValue:"NaN"};if(e===1/0)return{doubleValue:"Infinity"};if(e===-1/0)return{doubleValue:"-Infinity"}}return{doubleValue:au(e)?"-0":e}}function pC(r){return{integerValue:""+r}}function gC(r,e,t){return z1(e)?pC(e):Cf(r,e)}/**
1104 * @license
1105 * Copyright 2018 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 */class yf{constructor(){this._=void 0}}function UI(r,e,t){return r instanceof BB?(function(i,o){const u={fields:{[G1]:{stringValue:F1},[U1]:{timestampValue:{seconds:i.seconds,nanos:i.nanoseconds}}}};return o&&pf(o)&&(o=OB(o)),o&&(u.fields[H1]=o),{mapValue:u}})(t,e):r instanceof lu?X1(r,e):r instanceof ou?$1(r,e):r instanceof uu?(function(i,o){const u=Y1(i,o),B=qd(u)+qd(i.l);return Rr(u)&&Rr(i.l)?pC(B):Cf(i.serializer,B)})(r,e):r instanceof hB?(function(i,o){return qE(i,o,Math.min)})(r,e):r instanceof dB?(function(i,o){return qE(i,o,Math.max)})(r,e):void 0}function zI(r,e,t){return r instanceof lu?X1(r,e):r instanceof ou?$1(r,e):t}function Y1(r,e){return r instanceof uu?Ei(e)?e:{integerValue:0}:null}class BB extends yf{}class lu extends yf{constructor(e){super(),this.elements=e}}function X1(r,e){const t=Z1(e);for(const n of r.elements)t.some((i=>Js(i,n)))||t.push(n);return{arrayValue:{values:t}}}class ou extends yf{constructor(e){super(),this.elements=e}}function $1(r,e){let t=Z1(e);for(const n of r.elements)t=t.filter((i=>!Js(i,n)));return{arrayValue:{values:t}}}class CC extends yf{constructor(e,t){super(),this.serializer=e,this.l=t}}class uu extends CC{}class hB extends CC{}class dB extends CC{}function qE(r,e,t){if(!Ei(e))return r.l;const n=t(qd(e),qd(r.l));return Rr(e)&&Rr(r.l)?pC(n):Cf(r.serializer,n)}function qd(r){return Lt(r.integerValue||r.doubleValue)}function Z1(r){return _i(r)&&r.arrayValue.values?r.arrayValue.values.slice():[]}/**
1119 * @license
1120 * Copyright 2017 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 qI{constructor(e,t){this.field=e,this.transform=t}}function KI(r,e){return r.field.isEqual(e.field)&&(function(n,i){return n instanceof lu&&i instanceof lu||n instanceof ou&&i instanceof ou?nu(n.elements,i.elements,Js):n instanceof uu&&i instanceof uu||n instanceof hB&&i instanceof hB||n instanceof dB&&i instanceof dB?Js(n.l,i.l):n instanceof BB&&i instanceof BB})(r.transform,e.transform)}class JI{constructor(e,t){this.version=e,this.transformResults=t}}class Ds{constructor(e,t){this.updateTime=e,this.exists=t}static none(){return new Ds}static exists(e){return new Ds(void 0,e)}static updateTime(e){return new Ds(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 Sd(r,e){return r.updateTime!==void 0?e.isFoundDocument()&&e.version.isEqual(r.updateTime):r.exists===void 0||r.exists===e.isFoundDocument()}class bf{}function W1(r,e){if(!r.hasLocalMutations||e&&e.fields.length===0)return null;if(e===null)return r.isNoDocument()?new yC(r.key,Ds.none()):new Tu(r.key,r.data,Ds.none());{const t=r.data,n=Qn.empty();let i=new gt(bn.comparator);for(let o of e.fields)if(!i.has(o)){let u=t.field(o);u===null&&o.length>1&&(o=o.popLast(),u=t.field(o)),u===null?n.delete(o):n.set(o,u),i=i.add(o)}return new Ai(r.key,n,new qs(i.toArray()),Ds.none())}}function QI(r,e,t){r instanceof Tu?(function(i,o,u){const B=i.value.clone(),f=JE(i.fieldTransforms,o,u.transformResults);B.setAll(f),o.convertToFoundDocument(u.version,B).setHasCommittedMutations()}
1133)(r,e,t):r instanceof Ai?(function(i,o,u){if(!Sd(i.precondition,o))return void o.convertToUnknownDocument(u.version);const B=JE(i.fieldTransforms,o,u.transformResults),f=o.data;f.setAll(eD(i)),f.setAll(B),o.convertToFoundDocument(u.version,f).setHasCommittedMutations()})(r,e,t):(function(i,o,u){o.convertToNoDocument(u.version).setHasCommittedMutations()})(0,e,t)}function Xc(r,e,t,n){return r instanceof Tu?(function(o,u,B,f){if(!Sd(o.precondition,u))return B;const g=o.value.clone(),y=QE(o.fieldTransforms,f,u);return g.setAll(y),u.convertToFoundDocument(u.version,g).setHasLocalMutations(),null})(r,e,t,n):r instanceof Ai?(function(o,u,B,f){if(!Sd(o.precondition,u))return B;const g=QE(o.fieldTransforms,f,u),y=u.data;return y.setAll(eD(o)),y.setAll(g),u.convertToFoundDocument(u.version,y).setHasLocalMutations(),B===null?null:B.unionWith(o.fieldMask.fields).unionWith(o.fieldTransforms.map((b=>b.field)))})(r,e,t,n):(function(o,u,B){return Sd(o.precondition,u)?(u.convertToNoDocument(u.version).setHasLocalMutations(),null):B})(r,e,t)}function YI(r,e){let t=null;for(const n of r.fieldTransforms){const i=e.data.field(n.field),o=Y1(n.transform,i||null);o!=null&&(t===null&&(t=Qn.empty()),t.set(n.field,o))}return t||null}function KE(r,e){return r.type===e.type&&!!r.key.isEqual(e.key)&&!!r.precondition.isEqual(e.precondition)&&!!(function(n,i){return n===void 0&&i===void 0||!(!n||!i)&&nu(n,i,((o,u)=>KI(o,u)))})(r.fieldTransforms,e.fieldTransforms)&&(r.type===0?r.value.isEqual(e.value):r.type!==1||r.data.isEqual(e.data)&&r.fieldMask.isEqual(e.fieldMask))}class Tu extends bf{constructor(e,t,n,i=[]){super(),this.key=e,this.value=t,this.precondition=n,this.fieldTransforms=i,this.type=0}getFieldMask(){return null}}class Ai extends bf{constructor(e,t,n,i,o=[]){super(),this.key=e,this.data=t,this.fieldMask=n,this.precondition=i,this.fieldTransforms=o,this.type=1}getFieldMask(){return this.fieldMask}}function eD(r){const e=new Map;return r.fieldMask.fields.forEach((t=>{if(!t.isEmpty()){const n=r.data.field(t);e.set(t,n)}})),e}function JE(r,e,t){const n=new Map;fe(r.length===t.length,32656,{h:t.length,T:r.length});for(let i=0;i<t.length;i++){const o=r[i],u=o.transform,B=e.data.field(o.field);n.set(o.field,zI(u,B,t[i]))}return n}function QE(r,e,t){const n=new Map;for(const i of r){const o=i.transform,u=t.data.field(i.field);n.set(i.field,UI(o,u,e))}return n}class yC extends bf{constructor(e,t){super(),this.key=e,this.precondition=t,this.type=2,this.fieldTransforms=[]}getFieldMask(){return null}}class tD extends bf{constructor(e,t){super(),this.key=e,this.precondition=t,this.type=3,this.fieldTransforms=[]}getFieldMask(){return null}}/**
1134 * @license
1135 * Copyright 2022 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 */class cu{constructor(e,t){this.position=e,this.inclusive=t}}function YE(r,e,t){let n=0;for(let i=0;i<r.position.length;i++){const o=e[i],u=r.position[i];if(o.field.isKeyField()?n=De.comparator(De.fromName(u.referenceValue),t.key):n=Hn(u,t.data.field(o.field)),o.dir==="desc"&&(n*=-1),n!==0)break}return n}function XE(r,e){if(r===null)return e===null;if(e===null||r.inclusive!==e.inclusive||r.position.length!==e.position.length)return!1;for(let t=0;t<r.position.length;t++)if(!Js(r.position[t],e.position[t]))return!1;return!0}/**
1149 * @license
1150 * Copyright 2022 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, softw
1158are
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 nD{}class it extends nD{constructor(e,t,n){super(),this.field=e,this.op=t,this.value=n}static create(e,t,n){return e.isKeyField()?t==="in"||t==="not-in"?this.createKeyFieldInFilter(e,t,n):new XI(e,t,n):t==="array-contains"?new WI(e,n):t==="in"?new oD(e,n):t==="not-in"?new eS(e,n):t==="array-contains-any"?new tS(e,n):new it(e,t,n)}static createKeyFieldInFilter(e,t,n){return t==="in"?new $I(e,n):new ZI(e,n)}matches(e){const t=e.data.field(this.field);return this.op==="!="?t!==null&&t.nullValue===void 0&&this.matchesComparison(Hn(t,this.value)):t!==null&&gn(this.value)===gn(t)&&this.matchesComparison(Hn(t,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 Te(47266,{operator:this.op})}}isInequality(){return["<","<=",">",">=","!=","not-in"].indexOf(this.op)>=0}getFlattenedFilters(){return[this]}getFilters(){return[this]}}class wt extends nD{constructor(e,t){super(),this.filters=e,this.op=t,this.P=null}static create(e,t){return new wt(e,t)}matches(e){return Bu(this)?this.filters.find((t=>!t.matches(e)))===void 0:this.filters.find((t=>t.matches(e)))!==void 0}getFlattenedFilters(){return this.P!==null||(this.P=this.filters.reduce(((e,t)=>e.concat(t.getFlattenedFilters())),[])),this.P}getFilters(){return Object.assign([],this.filters)}}function Bu(r){return r.op==="and"}function Ng(r){return r.op==="or"}function bC(r){return sD(r)&&Bu(r)}function sD(r){for(const e of r.filters)if(e instanceof wt)return!1;return!0}function Ig(r){if(r instanceof it)return r.field.canonicalString()+r.op.toString()+iu(r.value);if(bC(r))return r.filters.map((e=>Ig(e))).join(",");{const e=r.filters.map((t=>Ig(t))).join(",");return`${r.op}(${e})`}}function rD(r,e){return r instanceof it?(function(n,i){return i instanceof it&&n.op===i.op&&n.field.isEqual(i.field)&&Js(n.value,i.value)})(r,e):r instanceof wt?(function(n,i){return i instanceof wt&&n.op===i.op&&n.filters.length===i.filters.length?n.filters.reduce(((o,u,B)=>o&&rD(u,i.filters[B])),!0):!1})(r,e):void Te(19439)}function aD(r,e){const t=r.filters.concat(e);return wt.create(t,r.op)}function iD(r){return r instanceof it?(function(t){return`${t.field.canonicalString()} ${t.op} ${iu(t.value)}`})(r):r instanceof wt?(function(t){return t.op.toString()+" {"+t.getFilters().map(iD).join(" ,")+"}"})(r):"Filter"}class XI extends it{constructor(e,t,n){super(e,t,n),this.key=De.fromName(n.referenceValue)}matches(e){const t=De.comparator(e.key,this.key);return this.matchesComparison(t)}}class $I extends it{constructor(e,t){super(e,"in",t),this.keys=lD("in",t)}matches(e){return this.keys.some((t=>t.isEqual(e.key)))}}class ZI extends it{constructor(e,t){super(e,"not-in",t),this.keys=lD("not-in",t)}matches(e){return!this.keys.some((t=>t.isEqual(e.key)))}}function lD(r,e){var t;return(((t=e.arrayValue)==null?void 0:t.values)||[]).map((n=>De.fromName(n.referenceValue)))}class WI extends it{constructor(e,t){super(e,"array-contains",t)}matches(e){const t=e.data.field(this.field);return _i(t)&&cB(t.arrayValue,this.value)}}class oD extends it{constructor(e,t){super(e,"in",t)}matches(e){const t=e.data.field(this.field);return t!==null&&cB(this.value.arrayValue,t)}}class eS extends it{constructor(e,t){super(e,"not-in",t)}matches(e){if(cB(this.value.arrayValue,{nullValue:"NULL_VALUE"}))return!1;const t=e.data.field(this.field);return t!==null&&t.nullValue===void 0&&!cB(this.value.arrayValue,t)}}class tS extends it{constructor(e,t){super(e,"array-contains-any",t)}matches(e){const t=e.data.field(this.field);return!(!_i(t)||!t.arrayValue.values)&&t.arrayValue.values.some((n=>cB(this.value.arrayValue,n)))}}/**
1164 * @license
1165 * Copyright 2022 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, softw
1173are
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 */class Kd{constructor(e,t="asc"){this.field=e,this.dir=t}}function nS(r,e){return r.dir===e.dir&&r.field.isEqual(e.field)}/**
1179 * @license
1180 * Copyright 2017 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 */class Me{static fromTimestamp(e){return new Me(e)}static min(){return new Me(new xt(0,0))}static max(){return new Me(new xt(253402300799,999999999))}constructor(e){this.timestamp=e}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}}/**
1194 * @license
1195 * Copyright 2017 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 */class Zt{constructor(e,t,n,i,o,u,B){this.key=e,this.documentType=t,this.version=n,this.readTime=i,this.createTime=o,this.data=u,this.documentState=B}static newInvalidDocument(e){return new Zt(e,0,Me.min(),Me.min(),Me.min(),Qn.empty(),0)}static newFoundDocument(e,t,n,i){return new Zt(e,1,t,Me.min(),n,i,0)}static newNoDocument(e,t){return new Zt(e,2,t,Me.min(),Me.min(),Qn.empty(),0)}static newUnknownDocument(e,t){return new Zt(e,3,t,Me.min(),Me.min(),Qn.empty(),2)}convertToFoundDocument(e,t){return!this.createTime.isEqual(Me.min())||this.documentType!==2&&this.documentType!==0||(this.createTime=e),this.version=e,this.documentType=1,this.data=t,this.documentState=0,this}convertToNoDocument(e){return this.version=e,this.documentType=2,this.data=Qn.empty(),this.documentState=0,this}convertToUnknownDocument(e){return this.version=e,this.documentType=3,this.data=Qn.empty(),this.documentState=2,this}setHasCommittedMutations(){return this.documentState=2,this}setHasLocalMutations(){return this.documentState=1,this.version=Me.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 Zt&&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 Zt(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}})`}}/**
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 */const hu=-1;class Jd{constructor(e,t,n,i){this.indexId=e,this.collectionGroup=t,this.fields=n,this.indexState=i}}function Sg(r){return r.fields.find((e=>e.kind===2))}function ul(r){return r.fields.filter((e=>e.kind!==2))}Jd.UNKNOWN_ID=-1;class Rd{constructor(e,t){this.fieldPath=e,this.kind=t}}class fB{constructor(e,t){this.sequenceNumber=e,this.offset=t}static empty(){return new fB(0,Ts.min())}}function uD(r,e){const t=r.toTimestamp().seconds,n=r.toTimestamp().nanoseconds+1,i=Me.fromTimestamp(n===1e9?new xt(t+1,0):new xt(t,n));return new Ts(i,De.empty(),e)}function cD(r){return new Ts(r.readTime,r.key,hu)}class Ts{constructor(e,t,n){this.readTime=e,this.documentKey=t,this.largestBatchId=n}static min(){return new Ts(Me.min(),De.empty(),hu)}static max(){return new Ts(Me.max(),De.empty(),hu)}}function xC(r,e){let t=r.readTime.compareTo(e.readTime);return t!==0?t:(t=De.comparator(r.documentKey,e.documentKey),t!==0?t:Ue(r.largestBatchId,e.largestBatchId))}/**
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 sS{constructor(e,t=null,n=[],i=[],o=null,u=null,B=null){this.path=e,this.collectionGroup=t,this.orderBy=n,this.filters=i,this.limit=o,this.startAt=u,this.endAt=B,this.R=null}}function Rg(r,e=null,t=[],n=[],i=null,o=null,u=null){return new sS(r,e,t,n,i,o,u)}function Qd(r){const e=Se(r);if(e.R===null){let t=e.path.canonicalString();e.collectionGroup!==null&&(t+="|cg:"+e.collectionGroup),t+="|f:",t+=e.filters.map((n=>Ig(n))).join(","),t+="|ob:",t+=e.orderBy.map((n=>(function(o){return o.field.canonicalString()+o.dir})(n))).join(","),gf(e.limit)||(t+="|l:",t+=e.limit),e.startAt&&(t+="|lb:",t+=e.startAt.inclusive?"b:":"a:",t+=e.startAt.position.map((n=>iu(n))).join(",")),e.endAt&&(t+="|ub:",t+=e.endAt.inclusive?"a:":"b:",t+=e.endAt.position.map((n=>iu(n))).join(",")),e.R=t}return e.R}function EC(r,e){if(r.limit!==e.limit||r.orderBy.length!==e.orderBy.length)return!1;for(let t=0;t<r.orderBy.length;t++)if(!nS(r.orderBy[t],e.orderBy[t]))return!1;if(r.filters.length!==e.filters.length)return!1;for(let t=0;t<r.filters.length;t++)if(!rD(r.filters[t],e.filters[t]))return!1;return r.collectionGroup===e.collectionGroup&&!!r.path.isEqual(e.path)&&!!XE(r.startAt,e.startAt)&&XE(r.endAt,e.endAt)}function Ba(r){return!!r.isCorePipeline}function _C(r){return!!r.path&&De.isDocumentKey(r.path)&&r.collectionGroup===null&&r.filters.length===0}function Yd(r,e){return r.filters.filter((t=>t instanceof it&&t.field.isEqual(e)))}function $E(r,e,t){let n=Mr,i=!0;for(const o of Yd(r,e)){let u=Mr,B=!0;switch(o.op){case"<":case"<=":u=GI(o.value);break;case"==":case"in":case">=":u=o.value;break;case">":u=o.value,B=!1;break;case"!=":case"not-in":u=Mr}UE({value:n,inclusive:i},{value:u,inclusive:B})<0&&(n=u,i=B)}if(t!==null){for(let o=0;o<r.orderBy.length;++o)if(r.orderBy[o].field.isEqual(e)){const u=t.position[o];UE({value:n,inclusive:i},{value:u,inclusive:t.inclusive})<0&&(n=u,i=t.inclusive);break}}return{value:n,inclusive:i}}function ZE(r,e,t){let n=mi,i=!0;for(const o of Yd(r,e)){let u=mi,B=!0;switch(o.op){case">=":case">":u=HI(o.value),B=!1;break;case"==":case"in":case"<=":u=o.value;break;case"<":u=o.value,B=!1;break;case"!=":case"not-in":u=mi}zE({value:n,inclusive:i},{value:u,inclusive:B})>0&&(n=u,i=B)}if(t!==null){for(let o=0;o<r.orderBy.length;++o)if(r.orderBy[o].field.isEqual(e)){const u=t.position[o];zE({value:n,inclusive:i},{value:u,inclusive:t.inclusive})>0&&(n=u,i=t.inclusive);break}}return{value:n,inclusive:i}}/**
1239 * @license
1240 * Copyright 2017 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 xf{constructor(e,t=null,n=[],i=[],o=null,u="F",B=null,f=null){this.path=e,this.collectionGroup=t,this.explicitOrderBy=n,this.filters=i,this.limit=o,this.limitType=u,this.startAt=B,this.endAt=f,this.I=null,this.A=null,this.V=null,this.startAt,this.endAt}}function BD(r,e,t,n,i,o,u,B){return new xf(r,e,t,n,i,o,u,B)}function kB(r){return new xf(r)}function WE(r){return r.filters.length===0&&r.limit===null&&r.startAt==null&&r.endAt==null&&(r.explicitOrderBy.length===0||r.explicitOrderBy.length===1&&r.explicitOrderBy[0].field.isKeyField())}function rS(r){return De.isDocumentKey(r.path)&&r.collectionGroup===null&&r.filters.length===0}function aS(r){return r.collectionGroup!==null}function $c(r){const e=Se(r);if(e.I===null){e.I=[];const t=new Set;for(const o of e.explicitOrderBy)e.I.push(o),t.add(o.field.canonicalString());const n=e.explicitOrderBy.length>0?e.explicitOrderBy[e.explicitOrderBy.length-1].dir:"asc";(function(u){let B=new gt(bn.comparator);return u.filters.forEach((f=>{f.getFlattenedFilters().forEach((g=>{g.isInequality()&&(B=B.add(g.field))}))})),B})(e).forEach((o=>{t.has(o.canonicalString())||o.isKeyField()||e.I.push(new Kd(o,n))})),t.has(bn.keyField().canonicalString())||e.I.push(new Kd(bn.keyField(),n))}return e.I}function ws(r){const e=Se(r);return e.A||(e.A=iS(e,$c(r))),e.A}function iS(r,e){if(r.limitType==="F")return Rg(r.path,r.collectionGroup,e,r.filters,r.limit,r.startAt,r.endAt);{e=e.map((i=>{const o=i.dir==="desc"?"asc":"desc";return new Kd(i.field,o)}));const t=r.endAt?new cu(r.endAt.position,r.endAt.inclusive):null,n=r.startAt?new cu(r.startAt.position,r.startAt.inclusive):null;return Rg(r.path,r.collectionGroup,e,r.filters,r.limit,t,n)}}function Og(r,e,t){return new xf(r.path,r.collectionGroup,r.explicitOrderBy.slice(),r.filters.slice(),e,t,r.startAt,r.endAt)}function lS(r,e){return EC(ws(r),ws(e))&&r.limitType===e.limitType}function Zc(r){return`Query(target=${(function(t){let n=t.path.canonicalString();return t.collectionGroup!==null&&(n+=" collectionGroup="+t.collectionGroup),t.filters.length>0&&(n+=`, filters: [${t.filters.map((i=>iD(i))).join(", ")}]`),gf(t.limit)||(n+=", limit: "+t.limit),t.orderBy.length>0&&(n+=`, orderBy: [${t.orderBy.map((i=>(function(u){return`${u.field.canonicalString()} (${u.dir})`})(i))).join(", ")}]`),t.startAt&&(n+=", startAt: ",n+=t.startAt.inclusive?"b:":"a:",n+=t.startAt.position.map((i=>iu(i))).join(",")),t.endAt&&(n+=", endAt: ",n+=t.endAt.inclusive?"a:":"b:",n+=t.endAt.position.map((i=>iu(i))).join(",")),`Target(${n})`})(ws(r))}; limitType=${r.limitType})`}function Ef(r,e){return e.isFoundDocument()&&(function(n,i){const o=i.key.path;return n.collectionGroup!==null?i.key.hasCollectionId(n.collectionGroup)&&n.path.isPrefixOf(o):De.isDocumentKey(n.path)?n.path.isEqual(o):n.path.isImmediateParentOf(o)})(r,e)&&(function(n,i){for(const o of $c(n))if(!o.field.isKeyField()&&i.data.field(o.field)===null)return!1;return!0})(r,e)&&(function(n,i){for(const o of n.filters)if(!o.matches(i))return!1;return!0})(r,e)&&(function(n,i){return!(n.startAt&&!(function(u,B,f){const g=YE(u,B,f);return u.inclusive?g<=0:g<0})(n.startAt,$c(n),i)||n.endAt&&!(function(u,B,f){const g=YE(u,B,f);return u.inclusive?g>=0:g>0})(n.endAt,$c(n),i))})(r,e)}function DC(r){return(e,t)=>{let n=!1;for(const i of $c(r)){const o=oS(i,e,t);if(o!==0)return o;n=n||i.field.isKeyField()}return 0}}function oS(r,e,t){const n=r.field.isKeyField()?De.comparator(e.key,t.key):(function(o,u,B){const f=u.data.field(o),g=B.data.field(o);return f!==null&&g!==null?Hn(f,g):Te(42886)})(r.field,e,t);switch(r.dir){case"asc":return n;case"desc":return-1*n;default:return Te(19790,{direction:r.dir})}}/**
1254 * @license
1255 * Copyright 2017 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 */class uS{constructor(e,t){this.count=e,this.unchangedNames=t}}/**
1269 * @license
1270 * Copyright 2017 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 */var fn,lt;function cS(r){switch(r){case le.OK:return Te(64938);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.UNIMPLEMENTED:case le.DATA_LOSS:return!0;default:return Te(15467,{code:r})}}function hD(r){if(r===void 0)return sn("GRPC error has no .code"),le.UNKNOWN;switch(r){case fn.OK:return le.OK;case fn.CANCELLED:return le.CANCELLED;case fn.UNKNOWN:return le.UNKNOWN;case fn.DEADLINE_EXCEEDED:return le.DEADLINE_EXCEEDED;case fn.RESOURCE_EXHAUSTED:return le.RESOURCE_EXHAUSTED;case fn.INTERNAL:return le.INTERNAL;case fn.UNAVAILABLE:return le.UNAVAILABLE;case fn.UNAUTHENTICATED:return le.UNAUTHENTICATED;case fn.INVALID_ARGUMENT:return le.INVALID_ARGUMENT;case fn.NOT_FOUND:return le.NOT_FOUND;case fn.ALREADY_EXISTS:return le.ALREADY_EXISTS;case fn.PERMISSION_DENIED:return le.PERMISSION_DENIED;case fn.FAILED_PRECONDITION:return le.FAILED_PRECONDITION;case fn.ABORTED:return le.ABORTED;case fn.OUT_OF_RANGE:return le.OUT_OF_RANGE;case fn.UNIMPLEMENTED:return le.UNIMPLEMENTED;case fn.DATA_LOSS:return le.DATA_LOSS;default:return Te(39323,{code:r})}}(lt=fn||(fn={}))[lt.OK=0]="OK",lt[lt.CANCELLED=1]="CANCELLED",lt[lt.UNKNOWN=2]="UNKNOWN",lt[lt.INVALID_ARGUMENT=3]="INVALID_ARGUMENT",lt[lt.DEADLINE_EXCEEDED=4]="DEADLINE_EXCEEDED",lt[lt.NOT_FOUND=5]="NOT_FOUND",lt[lt.ALREADY_EXISTS=6]="ALREADY_EXISTS",lt[lt.PERMISSION_DENIED=7]="PERMISSION_DENIED",lt[lt.UNAUTHENTICATED=16]="UNAUTHENTICATED",lt[lt.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",lt[lt.FAILED_PRECONDITION=9]="FAILED_PRECONDITION",lt[lt.ABORTED=10]="ABORTED",lt[lt.OUT_OF_RANGE=11]="OUT_OF_RANGE",lt[lt.UNIMPLEMENTED=12]="UNIMPLEMENTED",lt[lt.INTERNAL=13]="INTERNAL",lt[lt.UNAVAILABLE=14]="UNAVAILABLE",lt[lt.DATA_LOSS=15]="DATA_LOSS";/**
1284 * @license
1285 * Copyright 2017 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 */class Ea{constructor(e,t){this.mapKeyFn=e,this.equalsFn=t,this.inner={},this.innerSize=0}get(e){const t=this.mapKeyFn(e),n=this.inner[t];if(n!==void 0){for(const[i,o]of n)if(this.equalsFn(i,e))return o}}has(e){return this.get(e)!==void 0}set(e,t){const n=this.mapKeyFn(e),i=this.inner[n];if(i===void 0)return this.inner[n]=[[e,t]],void this.innerSize++;for(let o=0;o<i.length;o++)if(this.equalsFn(i[o][0],e))return void(i[o]=[e,t]);i.push([e,t]),this.innerSize++}delete(e){const t=this.mapKeyFn(e),n=this.inner[t];if(n===void 0)return!1;for(let i=0;i<n.length;i++)if(this.equalsFn(n[i][0],e))return n.length===1?delete this.inner[t]:n.splice(i,1),this.innerSize--,!0;return!1}forEach(e){Vl(this.inner,((t,n)=>{for(const[i,o]of n)e(i,o)}))}isEmpty(){return P1(this.inner)}size(){return this.innerSize}}/**
1299 * @license
1300 * Copyright 2017 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 */const BS=new Rt(De.comparator);function yn(){return BS}const dD=new Rt(De.comparator);function Bl(...r){let e=dD;for(const t of r)e=e.insert(t.key,t);return e}function fD(r){let e=dD;return r.forEach(((t,n)=>e=e.insert(t,n.overlayedDocument))),e}function Us(){return Wc()}function mD(){return Wc()}function Wc(){return new Ea((r=>r.toString()),((r,e)=>r.isEqual(e)))}const hS=new Rt(De.comparator),dS=new gt(De.comparator);function Xe(...r){let e=dS;for(const t of r)e=e.add(t);return e}const fS=new gt(Ue);function vC(){return fS}/**
1314 * @license
1315 * Copyright 2023 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 */function mS(){return new TextEncoder}/**
1329 * @license
1330 * Copyright 2022 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 pS=new Ci([4294967295,4294967295],0);function e_(r){const e=mS().encode(r),t=new D1;return t.update(e),new Uint8Array(t.digest())}function t_(r){const e=new DataView(r.buffer),t=e.getUint32(0,!0),n=e.getUint32(4,!0),i=e.getUint32(8,!0),o=e.getUint32(12,!0);return[new Ci([t,n],0),new Ci([i,o],0)]}class wC{constructor(e,t,n){if(this.bitmap=e,this.padding=t,this.hashCount=n,t<0||t>=8)throw new zc(`Invalid padding: ${t}`);if(n<0)throw new zc(`Invalid hash count: ${n}`);if(e.length>0&&this.hashCount===0)throw new zc(`Invalid hash count: ${n}`);if(e.length===0&&t!==0)throw new zc(`Invalid padding when bitmap length is 0: ${t}`);this.m=8*e.length-t,this.p=Ci.fromNumber(this.m)}v(e,t,n){let i=e.add(t.multiply(Ci.fromNumber(n)));return i.compare(pS)===1&&(i=new Ci([i.getBits(0),i.getBits(1)],0)),i.modulo(this.p).toNumber()}S(e){return!!(this.bitmap[Math.floor(e/8)]&1<<e%8)}mightContain(e){if(this.m===0)return!1;const t=e_(e),[n,i]=t_(t);for(let o=0;o<this.hashCount;o++){const u=this.v(n,i,o);if(!this.S(u))return!1}return!0}static create(e,t,n){const i=e%8==0?0:8-e%8,o=new Uint8Array(Math.ceil(e/8)),u=new wC(o,i,t);return n.forEach((B=>u.insert(B))),u}insert(e){if(this.m===0)return;const t=e_(e),[n,i]=t_(t);for(let o=0;o<this.hashCount;o++){const u=this.v(n,i,o);this.D(u)}}D(e){const t=Math.floor(e/8),n=e%8;this.bitmap[t]|=1<<n}}class zc extends Error{constructor(){super(...arguments),this.name="BloomFilterError"}}/**
1344 * @license
1345 * Copyright 2017 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 */class Au{constructor(e,t,n,i,o,u){this.snapshotVersion=e,this.targetChanges=t,this.targetMismatches=n,this.documentUpdates=i,this.augmentedDocumentUpdates=o,this.resolvedLimboDocuments=u}static createSynthesizedRemoteEventForCurrentChange(e,t,n){const i=new Map;return i.set(e,LB.createSynthesizedTargetChangeForCurrentChange(e,t,n)),new Au(Me.min(),i,new Rt(Ue),yn(),yn(),Xe())}}class LB{constructor(e,t,n,i,o){this.resumeToken=e,this.current=t,this.addedDocuments=n,this.modifiedDocuments=i,this.removedDocuments=o}static createSynthesizedTargetChangeForCurrentChange(e,t,n){return new LB(n,t,Xe(),Xe(),Xe())}}/**
1359 * @license
1360 * Copyright 2017 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 */class Od{constructor(e,t,n,i){this.C=e,this.removedTargetIds=t,this.key=n,this.F=i}}class pD{constructor(e,t){this.targetId=e,this.O=t}}class gD{constructor(e,t,n=qt.EMPTY_BYTE_STRING,i=null){this.state=e,this.targetIds=t,this.resumeToken=n,this.cause=i}}class n_{constructor(e){this.targetId=e,this.M=0,this.N=s_(),this.L=qt.EMPTY_BYTE_STRING,this.B=!1,this.U=!0}get current(){return this.B}get resumeToken(){return this.L}get k(){return this.M!==0}get q(){return this.U}$(e){e.approximateByteSize()>0&&(this.U=!0,this.L=e)}K(){let e=Xe(),t=Xe(),n=Xe();return this.N.forEach(((i,o)=>{switch(o){case 0:e=e.add(i);break;case 2:t=t.add(i);break;case 1:n=n.add(i);break;default:Te(38017,{changeType:o})}})),new LB(this.L,this.B,e,t,n)}W(){this.U=!1,this.N=s_()}G(e,t){this.U=!0,this.N=this.N.insert(e,t)}j(e){this.U=!0,this.N=this.N.remove(e)}H(){this.M+=1}J(){this.M-=1,fe(this.M>=0,3241,{M:this.M,targetId:this.targetId})}Y(){this.U=!0,this.B=!0}}const Mc="WatchChangeAggregator";class gS{constructor(e){this.Z=e,this.X=new Map,this.ee=yn(),this.te=yd(),this.ne=yn(),this.re=yd(),this.ie=new Rt(Ue)}se(e){for(const t of e.C)e.F&&e.F.isFoundDocument()?this._e(t,e.F):this.oe(t,e.key,e.F);for(const t of e.removedTargetIds)this.oe(t,e.key,e.F)}ae(e){this.forEachTarget(e,(t=>{const n=this.X.get(t);if(n)switch(e.state){case 0:this.ue(t)&&n.$(e.resumeToken);break;case 1:n.J(),n.k||n.W(),n.$(e.resumeToken);break;case 2:n.J(),n.k||this.removeTarget(t);break;case 3:this.ue(t)&&(n.Y(),n.$(e.resumeToken));break;case 4:this.ue(t)&&(this.ce(t),n.$(e.resumeToken));break;default:Te(56790,{state:e.state})}else Be(Mc,`handleTargetChange received targetChange for untracked target ID (${t}) with state (${e.state})`)}))}forEachTarget(e,t){e.targetIds.length>0?e.targetIds.forEach(t):this.X.forEach(((n,i)=>{this.ue(i)&&t(i)}))}le(e){var t;return Ba(e)?e.getPipelineSourceType()==="documents"&&((t=e.getPipelineDocuments())==null?void 0:t.length)===1:_C(e)}Ee(e){const t=e.targetId,n=e.O.count,i=this.he(t);if(i){const o=i.target;if(this.le(o))if(n===0){const u=new De(Ba(o)?ct.fromString(o.getPipelineDocuments()[0]):o.path);this.oe(t,u,Zt.newNoDocument(u,Me.min()))}else fe(n===1,20013,"Single document existence filter with count: "+n);else{const u=this.Te(t);if(u!==n){const B=this.Pe(e),f=B?this.Re(B,e,u):1;if(f!==0){this.ce(t);const g=f===2?"TargetPurposeExistenceFilterMismatchBloom":"TargetPurposeExistenceFilterMismatch";this.ie=this.ie.insert(t,g)}}}}}Pe(e){const t=e.O.unchangedNames;if(!t||!t.bits)return null;const{bits:{bitmap:n="",padding:i=0},hashCount:o=0}=t;let u,B;try{u=ya(n).toUint8Array()}catch(f){if(f instanceof V1)return lr("Decoding the base64 bloom filter in existence filter failed ("+f.message+"); ignoring the bloom filter and falling back to full re-query."),null;throw f}try{B=new wC(u,i,o)}catch(f){return lr(f instanceof zc?"BloomFilter error: ":"Applying bloom filter failed: ",f),null}return B.m===0?null:B}Re(e,t,n){return t.O.count===n-this.Ve(e,t.targetId)?0:2}Ve(e,t){const n=this.Z.getRemoteKeysForTarget(t);let i=0;return n.forEach((o=>{const u=this.Z.Ae(),B=`projects/${u.projectId}/databases/${u.database}/documents/${o.path.canonicalString()}`;e.mightContain(B)||(this.oe(t,o,null),i++)})),i}de(e){const t=new Map;this.X.forEach(((o,u)=>{const B=this.he(u);if(B){if(o.current&&this.le(B.target)){const f=Ba(B.target)?ct.fromString(B.target.getPipelineDocuments()[0]):B.target.path,g=new De(f);this.fe(g).has(u)||this.me(u,g)||this.oe(u,g,Zt.newNoDocument(g,e))}o.q&&(t.set(u,o.K()),o.W())}}));let n=Xe();this.re.forEach(((o,u)=>{let B=!0;u.forEachWhile((f=>{const g=this.he(f);return!g||g.purpose==="TargetPurposeLimboResolution"||(B=!1,!1)})),B&&(n=n.add(o))})),this.ee.forEach(((o,u)=>u.setReadTime(e))),this.ne.forEach(((o,u)=>u.setReadTime(e)));const i=new Au(e,t,this.ie,this.ee,this.ne,n);return this.ee=yn(),this.te=yd(),this.ne=yn(),this.re=yd(),this.ie=new Rt(Ue),i}_e(e,t){const n=this.X.get(e);if(!n||!this.ue(e))return void Be(Mc,`addDocumentToTarget received document for unknown inactive target (${e})`);
1373const i=this.me(e,t.key)?2:0;n.G(t.key,i),Ba(this.he(e).target)&&this.he(e).target.getPipelineFlavor()!=="exact"?this.ne=this.ne.insert(t.key,t):this.ee=this.ee.insert(t.key,t),this.te=this.te.insert(t.key,this.fe(t.key).add(e)),this.re=this.re.insert(t.key,this.pe(t.key).add(e))}oe(e,t,n){const i=this.X.get(e);i&&this.ue(e)?(this.me(e,t)?i.G(t,1):i.j(t),this.re=this.re.insert(t,this.pe(t).delete(e)),this.re=this.re.insert(t,this.pe(t).add(e)),n&&(Ba(this.he(e).target)&&this.he(e).target.getPipelineFlavor()!=="exact"?this.ne=this.ne.insert(t,n):this.ee=this.ee.insert(t,n))):Be(Mc,`removeDocumentFromTarget received document for unknown or inactive target (${e})`)}removeTarget(e){this.X.delete(e)}Te(e){const t=this.X.get(e);if(!t)return 0;const n=t.K();return this.Z.getRemoteKeysForTarget(e).size+n.addedDocuments.size-n.removedDocuments.size}H(e){let t=this.X.get(e);t||(Be(Mc,`recordPendingTargetRequest set up tracking for target ID ${e}`),t=new n_(e),this.X.set(e,t)),t.H()}pe(e){let t=this.re.get(e);return t||(t=new gt(Ue),this.re=this.re.insert(e,t)),t}fe(e){let t=this.te.get(e);return t||(t=new gt(Ue),this.te=this.te.insert(e,t)),t}ue(e){const t=this.he(e)!==null;return t||Be(Mc,"Detected inactive target",e),t}he(e){const t=this.X.get(e);return t===void 0||t.k?null:this.Z.ge(e)}ce(e){this.X.set(e,new n_(e)),this.Z.getRemoteKeysForTarget(e).forEach((t=>{this.oe(e,t,null)}))}me(e,t){return this.Z.getRemoteKeysForTarget(e).has(t)}}function yd(){return new Rt(De.comparator)}function s_(){return new Rt(De.comparator)}const CS={asc:"ASCENDING",desc:"DESCENDING"},yS={"<":"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"},bS={and:"AND",or:"OR"};class xS{constructor(e,t){this.databaseId=e,this.useProto3Json=t}}function kg(r,e){return r.useProto3Json||gf(e)?e:{value:e}}function du(r,e){return r.useProto3Json?`${new Date(1e3*e.seconds).toISOString().replace(/\.\d*/,"").replace("Z","")}.${("000000000"+e.nanoseconds).slice(-9)}Z`:{seconds:""+e.seconds,nanos:e.nanoseconds}}function TC(r){const e=Ca(r);return new xt(e.seconds,e.nanos)}function CD(r,e){return r.useProto3Json?e.toBase64():e.toUint8Array()}function kd(r,e){return du(r,e.toTimestamp())}function Xn(r){return fe(!!r,49232),Me.fromTimestamp(TC(r))}function AC(r,e){return Lg(r,e).canonicalString()}function Lg(r,e){const t=(function(i){return new ct(["projects",i.projectId,"databases",i.database])})(r).child("documents");return e===void 0?t:t.child(e)}function yD(r){const e=ct.fromString(r);return fe(ND(e),10190,{key:e.toString()}),e}function mB(r,e){return AC(r.databaseId,e.path)}function _l(r,e){const t=yD(e);if(t.get(1)!==r.databaseId.projectId)throw new ve(le.INVALID_ARGUMENT,"Tried to deserialize key from different project: "+t.get(1)+" vs "+r.databaseId.projectId);if(t.get(3)!==r.databaseId.database)throw new ve(le.INVALID_ARGUMENT,"Tried to deserialize key from different database: "+t.get(3)+" vs "+r.databaseId.database);return new De(ED(t))}function bD(r,e){return AC(r.databaseId,e)}function xD(r){const e=yD(r);return e.length===4?ct.emptyPath():ED(e)}function jg(r){return new ct(["projects",r.databaseId.projectId,"databases",r.databaseId.database]).canonicalString()}function ED(r){return fe(r.length>4&&r.get(4)==="documents",29091,{key:r.toString()}),r.popFirst(5)}function r_(r,e,t){return{name:mB(r,e),fields:t.value.mapValue.fields}}function ES(r,e,t){const n=_l(r,e.name),i=Xn(e.updateTime),o=e.createTime?Xn(e.createTime):Me.min(),u=new Qn({mapValue:{fields:e.fields}}),B=Zt.newFoundDocument(n,i,o,u);return t&&B.setHasCommittedMutations(),t?B.setHasCommittedMutations():B}function _S(r,e){let t;if("targetChange"in e){e.targetChange;const n=(function(g){return g==="NO_CHANGE"?0:g==="ADD"?1:g==="REMOVE"?2:g==="CURRENT"?3:g==="RESET"?4:Te(39313,{state:g})})(e.targetChange.targetChangeType||"NO_CHANGE"),i=e.targetChange.targetIds||[],o=(function(g,y){return g.useProto3Json?(fe(y===void 0||typeof y=="string",58123),qt.fromBase64String(y||"")):(fe(y===void 0||y instanceof Buffer||y instanceof Uint8Array,16193),qt.fromUint8Array(y||new Uint8Array))})(r,e.targetChange.resumeToken),u=e.targetChange.cause,B=u&&(function(g){const y=g.code===void 0?le.UNKNOWN:hD(g.code);return new ve(y,g.message||"")})(u);t=new gD(n,i,o,B||null)}else if("documentChange"in e){e.documentChange;const n=e.documentChange;n.document,n.document.name,n.document.updateTime;const i=_l(r,n.document.name),o=Xn(n.document.updateTime),u=n.document.createTime?Xn(n.document.createTime):Me.min(),B=new Qn({mapValue:{fields:n.document.fields}}),f=Zt.newFoundDocument(i,o,u,B),g=n.targetIds||[],y=n.removedTargetIds||[];t=new Od(g,y,f.key,f)}else if("documentDelete"in e){e.documentDelete;const n=e.documentDelete;n.document;const i=_l(r,n.document),o=n.readTime?Xn(n.readTime):Me.min(),u=Zt.newNoDocument(i,o),B=n.removedTargetIds||[];t=new Od([],B,u.key,u)}else if("documentRemove"in e){e.documentRemove;const n=e.documentRemove;n.document;const i=_l(r,n.document),o=n.removedTargetIds||[];t=new Od([],o,i,null)}else{if(!("filter"in e))return Te(11601,{ye:e});{e.filter;const n=e.filter;n.targetId;const{count:i=0,unchangedNames:o}=n,u=new uS(i,o),B=n.targetId;t=new pD(B,u)}}return t}function Xd(r,e){let t;if(e instanceof Tu)t={update:r_(r,e.key,e.value)};else if(e instanceof yC)t={delete:mB(r,e.key)};else if(e instanceof Ai)t={update:r_(r,e.key,e.data),updateMask:NS(e.fieldMask)};else{if(!(e instanceof tD))return Te(16599,{we:e.type});t={verify:mB(r,e.key)}}return e.fieldTransforms.length>0&&(t.updateTransforms=e.fieldTransforms.map((n=>(function(o,u){const B=u.transform;
1373if(B instanceof BB)return{fieldPath:u.field.canonicalString(),setToServerValue:"REQUEST_TIME"};if(B instanceof lu)return{fieldPath:u.field.canonicalString(),appendMissingElements:{values:B.elements}};if(B instanceof ou)return{fieldPath:u.field.canonicalString(),removeAllFromArray:{values:B.elements}};if(B instanceof uu)return{fieldPath:u.field.canonicalString(),increment:B.l};if(B instanceof hB)return{fieldPath:u.field.canonicalString(),minimum:B.l};if(B instanceof dB)return{fieldPath:u.field.canonicalString(),maximum:B.l};throw Te(20930,{transform:u.transform})})(0,n)))),e.precondition.isNone||(t.currentDocument=(function(i,o){return o.updateTime!==void 0?{updateTime:kd(i,o.updateTime)}:o.exists!==void 0?{exists:o.exists}:Te(27497)})(r,e.precondition)),t}function Mg(r,e){const t=e.currentDocument?(function(o){return o.updateTime!==void 0?Ds.updateTime(Xn(o.updateTime)):o.exists!==void 0?Ds.exists(o.exists):Ds.none()})(e.currentDocument):Ds.none(),n=e.updateTransforms?e.updateTransforms.map((i=>(function(u,B){let f=null;if("setToServerValue"in B)fe(B.setToServerValue==="REQUEST_TIME",16630,{proto:B}),f=new BB;else if("appendMissingElements"in B){const y=B.appendMissingElements.values||[];f=new lu(y)}else if("removeAllFromArray"in B){const y=B.removeAllFromArray.values||[];f=new ou(y)}else"increment"in B?f=new uu(u,B.increment):"minimum"in B?f=new hB(u,B.minimum):"maximum"in B?f=new dB(u,B.maximum):Te(16584,{proto:B});const g=bn.fromServerFormat(B.fieldPath);return new qI(g,f)})(r,i))):[];if(e.update){e.update.name;const i=_l(r,e.update.name),o=new Qn({mapValue:{fields:e.update.fields}});if(e.updateMask){const u=(function(f){const g=f.fieldPaths||[];return new qs(g.map((y=>bn.fromServerFormat(y))))})(e.updateMask);return new Ai(i,o,u,t,n)}return new Tu(i,o,t,n)}if(e.delete){const i=_l(r,e.delete);return new yC(i,t)}if(e.verify){const i=_l(r,e.verify);return new tD(i,t)}return Te(1463,{proto:e})}function DS(r,e){return r&&r.length>0?(fe(e!==void 0,14353),r.map((t=>(function(i,o){let u=i.updateTime?Xn(i.updateTime):Xn(o);return u.isEqual(Me.min())&&(u=Xn(o)),new JI(u,i.transformResults||[])})(t,e)))):[]}function _D(r,e){return{documents:[bD(r,e.path)]}}function DD(r,e){const t={structuredQuery:{}},n=e.path;let i;e.collectionGroup!==null?(i=n,t.structuredQuery.from=[{collectionId:e.collectionGroup,allDescendants:!0}]):(i=n.popLast(),t.structuredQuery.from=[{collectionId:n.lastSegment()}]),t.parent=bD(r,i);const o=(function(g){if(g.length!==0)return AD(wt.create(g,"and"))})(e.filters);o&&(t.structuredQuery.where=o);const u=(function(g){if(g.length!==0)return g.map((y=>(function(D){return{field:qo(D.field),direction:wS(D.dir)}})(y)))})(e.orderBy);u&&(t.structuredQuery.orderBy=u);const B=kg(r,e.limit);return B!==null&&(t.structuredQuery.limit=B),e.startAt&&(t.structuredQuery.startAt=(function(g){return{before:g.inclusive,values:g.position}})(e.startAt)),e.endAt&&(t.structuredQuery.endAt=(function(g){return{before:!g.inclusive,values:g.position}})(e.endAt)),{be:t,parent:i}}function vD(r){let e=xD(r.parent);const t=r.structuredQuery,n=t.from?t.from.length:0;let i=null;if(n>0){fe(n===1,65062);const y=t.from[0];y.allDescendants?i=y.collectionId:e=e.child(y.collectionId)}let o=[];t.where&&(o=(function(b){const D=TD(b);return D instanceof wt&&bC(D)?D.getFilters():[D]})(t.where));let u=[];t.orderBy&&(u=(function(b){return b.map((D=>(function(M){return new Kd(Ko(M.field),(function(W){switch(W){case"ASCENDING":return"asc";case"DESCENDING":return"desc";default:return}})(M.direction))})(D)))})(t.orderBy));let B=null;t.limit&&(B=(function(b){let D;return D=typeof b=="object"?b.value:b,gf(D)?null:D})(t.limit));let f=null;t.startAt&&(f=(function(b){const D=!!b.before,T=b.values||[];return new cu(T,D)})(t.startAt));let g=null;return t.endAt&&(g=(function(b){const D=!b.before,T=b.values||[];return new cu(T,D)})(t.endAt)),BD(e,i,u,o,B,"F",f,g)}function vS(r,e){const t=(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 Te(28987,{purpose:i})}})(e.purpose);return t==null?null:{"goog-listen-tags":t}}function wD(r,e){return{structuredPipeline:{pipeline:{stages:e.stages.map((t=>t._toProto(r)))}}}}function TD(r){return r.unaryFilter!==void 0?(function(t){switch(t.unaryFilter.op){case"IS_NAN":const n=Ko(t.unaryFilter.field);return it.create(n,"==",{doubleValue:NaN});case"IS_NULL":const i=Ko(t.unaryFilter.field);return it.create(i,"==",{nullValue:"NULL_VALUE"});
1373case"IS_NOT_NAN":const o=Ko(t.unaryFilter.field);return it.create(o,"!=",{doubleValue:NaN});case"IS_NOT_NULL":const u=Ko(t.unaryFilter.field);return it.create(u,"!=",{nullValue:"NULL_VALUE"});case"OPERATOR_UNSPECIFIED":return Te(61313);default:return Te(60726)}})(r):r.fieldFilter!==void 0?(function(t){return it.create(Ko(t.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";case"OPERATOR_UNSPECIFIED":return Te(58110);default:return Te(50506)}})(t.fieldFilter.op),t.fieldFilter.value)})(r):r.compositeFilter!==void 0?(function(t){return wt.create(t.compositeFilter.filters.map((n=>TD(n))),(function(i){switch(i){case"AND":return"and";case"OR":return"or";default:return Te(1026)}})(t.compositeFilter.op))})(r):Te(30097,{filter:r})}function wS(r){return CS[r]}function TS(r){return yS[r]}function AS(r){return bS[r]}function qo(r){return{fieldPath:r.canonicalString()}}function Ko(r){return bn.fromServerFormat(r.fieldPath)}function AD(r){return r instanceof it?(function(t){if(t.op==="=="){if(us(t.value))return{unaryFilter:{field:qo(t.field),op:"IS_NAN"}};if(_s(t.value))return{unaryFilter:{field:qo(t.field),op:"IS_NULL"}}}else if(t.op==="!="){if(us(t.value))return{unaryFilter:{field:qo(t.field),op:"IS_NOT_NAN"}};if(_s(t.value))return{unaryFilter:{field:qo(t.field),op:"IS_NOT_NULL"}}}return{fieldFilter:{field:qo(t.field),op:TS(t.op),value:t.value}}})(r):r instanceof wt?(function(t){const n=t.getFilters().map((i=>AD(i)));return n.length===1?n[0]:{compositeFilter:{op:AS(t.op),filters:n}}})(r):Te(54877,{filter:r})}function NS(r){const e=[];return r.fields.forEach((t=>e.push(t.canonicalString()))),{fieldPaths:e}}function ND(r){return r.length>=4&&r.get(0)==="projects"&&r.get(2)==="databases"}function ID(r){return!!r&&typeof r._toProto=="function"&&r._protoValueType==="ProtoValue"}function pB(r,e){const t={fields:{}};return e.forEach(((n,i)=>{if(typeof i!="string")throw new Error(`Cannot encode map with non-string key: ${i}`);t.fields[i]=n._toProto(r)})),{mapValue:t}}function SD(r){return{stringValue:r}}/**
1374 * @license
1375 * Copyright 2020 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 */function _f(r){return new xS(r,!0)}/**
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 */class zs{constructor(e){this._byteString=e}static fromBase64String(e){try{return new zs(qt.fromBase64String(e))}catch(t){throw new ve(le.INVALID_ARGUMENT,"Failed to construct data from Base64 string: "+t)}}static fromUint8Array(e){return new zs(qt.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)}toJSON(){return{type:zs._jsonSchemaVersion,bytes:this.toBase64()}}static fromJSON(e){if(RB(e,zs._jsonSchema))return zs.fromBase64String(e.bytes)}}
vendor: 4,151 bytes, lines 1403-1467
1403zs._jsonSchemaVersion="firestore/bytes/1.0",zs._jsonSchema={type:pn("string",zs._jsonSchemaVersion),bytes:pn("string")};/**
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, software
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 NC{constructor(...e){for(let t=0;t<e.length;++t)if(e[t].length===0)throw new ve(le.INVALID_ARGUMENT,"Invalid field name at argument $(i + 1). Field names must not be empty.");this._internalPath=new bn(e)}isEqual(e){return this._internalPath.isEqual(e._internalPath)}}function IS(){return new NC(su)}/**
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 */class RD{constructor(e){this._methodName=e}}/**
1434 * @license
1435 * Copyright 2017 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 */class Pr{constructor(e,t){if(!isFinite(e)||e<-90||e>90)throw new ve(le.INVALID_ARGUMENT,"Latitude must be a number between -90 and 90, but was: "+e);if(!isFinite(t)||t<-180||t>180)throw new ve(le.INVALID_ARGUMENT,"Longitude must be a number between -180 and 180, but was: "+t);this._lat=e,this._long=t}get latitude(){return this._lat}get longitude(){return this._long}isEqual(e){return this._lat===e._lat&&this._long===e._long}_compareTo(e){return Ue(this._lat,e._lat)||Ue(this._long,e._long)}toJSON(){return{latitude:this._lat,longitude:this._long,type:Pr._jsonSchemaVersion}}static fromJSON(e){if(RB(e,Pr._jsonSchema))return new Pr(e.latitude,e.longitude)}}Pr._jsonSchemaVersion="firestore/geoPoint/1.0",Pr._jsonSchema={type:pn("string",Pr._jsonSchemaVersion),latitude:pn("number"),longitude:pn("number")};/**
1449 * @license
1450 * Copyright 2017 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 */class Vn{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}}Vn.UNAUTHENTICATED=new Vn(null),Vn.GOOGLE_CREDENTIALS=new Vn("google-credentials-uid"),Vn.FIRST_PARTY=new Vn("first-party-uid"),Vn.MOCK_USER=new Vn("mock-user");/**
1464 * @license
1465 * Copyright 2017 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 */class fa{constructor(){this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t}))}}/**
1479 * @license
1480 * Copyright 2017 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 */class SS{constructor(e,t){this.user=t,this.type="OAuth",this.headers=new Map,this.headers.set("Authorization",`Bearer ${e}`)}}class RS{getToken(){return Promise.resolve(null)}invalidateToken(){}start(e,t){e.enqueueRetryable((()=>t(Vn.UNAUTHENTICATED)))}shutdown(){}}class OS{constructor(e){this.Se=e,this.currentUser=Vn.UNAUTHENTICATED,this.De=0,this.forceRefresh=!1,this.auth=null}start(e,t){fe(this.xe===void 0,42304);let n=this.De;const i=f=>this.De!==n?(n=this.De,t(f)):Promise.resolve();let o=new fa;this.xe=()=>{this.De++,this.currentUser=this.Ce(),o.resolve(),o=new fa,e.enqueueRetryable((()=>i(this.currentUser)))};const u=()=>{const f=o;e.enqueueRetryable((async()=>{await f.promise,await i(this.currentUser)}))},B=f=>{Be("FirebaseAuthCredentialsProvider","Auth detected"),this.auth=f,this.xe&&(this.auth.addAuthTokenListener(this.xe),u())};this.Se.onInit((f=>B(f))),setTimeout((()=>{if(!this.auth){const f=this.Se.getImmediate({optional:!0});f?B(f):(Be("FirebaseAuthCredentialsProvider","Auth not yet detected"),o.resolve(),o=new fa)}}),0),u()}getToken(){const e=this.De,t=this.forceRefresh;return this.forceRefresh=!1,this.auth?this.auth.getToken(t).then((n=>this.De!==e?(Be("FirebaseAuthCredentialsProvider","getToken aborted due to token change."),this.getToken()):n?(fe(typeof n.accessToken=="string",31837,{Fe:n}),new SS(n.accessToken,this.currentUser)):null)):Promise.resolve(null)}invalidateToken(){this.forceRefresh=!0}shutdown(){this.auth&&this.xe&&this.auth.removeAuthTokenListener(this.xe),this.xe=void 0}Ce(){const e=this.auth&&this.auth.getUid();return fe(e===null||typeof e=="string",2055,{Oe:e}),new Vn(e)}}class kS{constructor(e,t,n){this.Me=e,this.Ne=t,this.Le=n,this.type="FirstParty",this.user=Vn.FIRST_PARTY,this.Be=new Map}Ue(){return this.Le?this.Le():null}get headers(){this.Be.set("X-Goog-AuthUser",this.Me);const e=this.Ue();return e&&this.Be.set("Authorization",e),this.Ne&&this.Be.set("X-Goog-Iam-Authorization-Token",this.Ne),this.Be}}class LS{constructor(e,t,n){this.Me=e,this.Ne=t,this.Le=n}getToken(){return Promise.resolve(new kS(this.Me,this.Ne,this.Le))}start(e,t){e.enqueueRetryable((()=>t(Vn.FIRST_PARTY)))}shutdown(){}invalidateToken(){}}class a_{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 jS{constructor(e,t){this.ke=t,this.forceRefresh=!1,this.appCheck=null,this.qe=null,this.$e=null,VN(e)&&e.settings.appCheckToken&&(this.$e=e.settings.appCheckToken)}start(e,t){fe(this.xe===void 0,3512);const n=o=>{o.error!=null&&Be("FirebaseAppCheckTokenProvider",`Error getting App Check token; using placeholder token instead. Error: ${o.error.message}`);const u=o.token!==this.qe;return this.qe=o.token,Be("FirebaseAppCheckTokenProvider",`Received ${u?"new":"existing"} token.`),u?t(o.token):Promise.resolve()};this.xe=o=>{e.enqueueRetryable((()=>n(o)))};const i=o=>{Be("FirebaseAppCheckTokenProvider","AppCheck detected"),this.appCheck=o,this.xe&&this.appCheck.addTokenListener(this.xe)};this.ke.onInit((o=>i(o))),setTimeout((()=>
1493{if(!this.appCheck){const o=this.ke.getImmediate({optional:!0});o?i(o):Be("FirebaseAppCheckTokenProvider","AppCheck not yet detected")}}),0)}getToken(){if(this.$e)return Promise.resolve(new a_(this.$e));const e=this.forceRefresh;return this.forceRefresh=!1,this.appCheck?this.appCheck.getToken(e).then((t=>t?(fe(typeof t.token=="string",44558,{tokenResult:t}),this.qe=t.token,new a_(t.token)):null)):Promise.resolve(null)}invalidateToken(){this.forceRefresh=!0}shutdown(){this.appCheck&&this.xe&&this.appCheck.removeTokenListener(this.xe),this.xe=void 0}}function OD(r){const e={};return r.timeoutSeconds!==void 0&&(e.timeoutSeconds=r.timeoutSeconds),e}/**
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 */class MS{Ke(e){}shutdown(){}}/**
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 */const i_="ConnectivityMonitor";class l_{constructor(){this.We=()=>this.Qe(),this.Ge=()=>this.ze(),this.je=[],this.He()}Ke(e){this.je.push(e)}shutdown(){window.removeEventListener("online",this.We),window.removeEventListener("offline",this.Ge)}He(){window.addEventListener("online",this.We),window.addEventListener("offline",this.Ge)}Qe(){Be(i_,"Network connectivity changed: AVAILABLE");for(const e of this.je)e(0)}ze(){Be(i_,"Network connectivity changed: UNAVAILABLE");for(const e of this.je)e(1)}static Je(){return typeof window<"u"&&window.addEventListener!==void 0&&window.removeEventListener!==void 0}}/**
1524 * @license
1525 * Copyright 2023 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 */let bd=null;function Pg(){return bd===null?bd=(function(){return 268435456+Math.round(2147483648*Math.random())})():bd++,"0x"+bd.toString(16)}/**
1539 * @license
1540 * Copyright 2020 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 */const ag="RestConnection",PS={BatchGetDocuments:"batchGet",Commit:"commit",RunQuery:"runQuery",RunAggregationQuery:"runAggregationQuery",ExecutePipeline:"executePipeline"};class VS{get Ye(){return!1}constructor(e){this.databaseInfo=e,this.databaseId=e.databaseId;const t=e.ssl?"https":"http",n=encodeURIComponent(this.databaseId.projectId),i=encodeURIComponent(this.databaseId.database);this.Ze=t+"://"+e.host,this.Xe=`projects/${n}/databases/${i}`,this.et=this.databaseId.database===zd?`project_id=${n}`:`project_id=${n}&database_id=${i}`}tt(e,t,n,i,o){const u=Pg(),B=this.nt(e,t.toUriEncodedString());Be(ag,`Sending RPC '${e}' ${u}:`,B,n);
vendor: 4,297 bytes, lines 1553-1583
1553const f={"google-cloud-resource-prefix":this.Xe,"x-goog-request-params":this.et};this.rt(f,i,o);const{host:g}=new URL(B),y=C1(g);return this.it(e,B,f,n,y).then((b=>(Be(ag,`Received RPC '${e}' ${u}: `,b),b)),(b=>{throw lr(ag,`RPC '${e}' ${u} failed with error: `,b,"url: ",B,"request:",n),b}))}st(e,t,n,i,o,u){return this.tt(e,t,n,i,o)}rt(e,t,n){if(e["X-Goog-Api-Client"]=(function(){return"gl-js/ fire/"+wu})(),e["Content-Type"]="text/plain",this.databaseInfo.appId&&(e["X-Firebase-GMPID"]=this.databaseInfo.appId),t&&t.headers.forEach(((i,o)=>e[o]=i)),n&&n.headers.forEach(((i,o)=>e[o]=i)),this.databaseInfo._customHeaders)for(const i of Object.keys(this.databaseInfo._customHeaders))e[i]=this.databaseInfo._customHeaders[i]}nt(e,t){const n=PS[e];let i=`${this.Ze}/v1/${t}:${n}`;return this.databaseInfo.apiKey&&(i=`${i}?key=${encodeURIComponent(this.databaseInfo.apiKey)}`),i}terminate(){}}/**
1554 * @license
1555 * Copyright 2017 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 */class FS{constructor(e){this._t=e._t,this.ot=e.ot}ut(e){this.ct=e}lt(e){this.Et=e}ht(e){this.Tt=e}onMessage(e){this.Pt=e}close(){this.ot()}send(e){this._t(e)}Rt(){this.ct()}It(){this.Et()}At(e){this.Tt(e)}Vt(e){this.Pt(e)}}/**
1569 * @license
1570 * Copyright 2017 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 */const Pn="WebChannelConnection",Pc=(r,e,t)=>{r.listen(e,(n=>{try{t(n)}catch(i){setTimeout((()=>{throw i}),0)}}))};class $o extends VS{constructor(e){super(e),this.dt=[],this.forceLongPolling=e.forceLongPolling,this.autoDetectLongPolling=e.autoDetectLongPolling,this.useFetchStreams=e.useFetchStreams,this.longPollingOptions=e.longPollingOptions}static ft(){if(!$o.gt){const e=A1();Pc(e,T1.STAT_EVENT,(t=>{t.stat===Eg.PROXY?Be(Pn,"STAT_EVENT: detected buffering proxy"):t.stat===Eg.NOPROXY&&Be(Pn,"STAT_EVENT: detected no buffering proxy")})),$o.gt=!0}}it(e,t,n,i,o){const u=Pg();return new Promise(((B,f)=>{const g=new v1;g.setWithCredentials(!0),g.listenOnce(w1.COMPLETE,(()=>{try{switch(g.getLastErrorCode()){case Nd.NO_ERROR:const b=g.getResponseJson();Be(Pn,`XHR for RPC '${e}' ${u} received:`,JSON.stringify(b)),B(b);break;case Nd.TIMEOUT:Be(Pn,`RPC '${e}' ${u} timed out`),f(new ve(le.DEADLINE_EXCEEDED,"Request time out"));break;case Nd.HTTP_ERROR:const D=g.getStatus();if(Be(Pn,`RPC '${e}' ${u} failed with status:`,D,"response text:",g.getResponseText()),D>0){let T=g.getResponseJson();Array.isArray(T)&&(T=T[0]);const M=T==null?void 0:T.error;if(M&&M.status&&M.message){const z=(function(K){const he=K.toLowerCase().replace(/_/g,"-");return Object.values(le).indexOf(he)>=0?he:le.UNKNOWN})(M.status);f(new ve(z,M.message))}else f(new ve(le.UNKNOWN,"Server responded with status "+g.getStatus()))}else f(new ve(le.UNAVAILABLE,"Connection failed."));break;default:Te(9055,{yt:e,streamId:u,wt:g.getLastErrorCode(),bt:g.getLastError()})}}finally{Be(Pn,`RPC '${e}' ${u} completed.`)}}));const y=JSON.stringify(i);Be(Pn,`RPC '${e}' ${u} sending request:`,i),g.send(t,"POST",y,n,15)}))}vt(e,t,n){const i=Pg(),o=[this.Ze,"/","google.firestore.v1.Firestore","/",e,"/channel"],u=this.createWebChannelTransport(),B={httpSessionIdParam:"gsessionid",initMessageHeaders:{},messageUrlParams:{database:`projects/${this.databaseId.projectId}/databases/${this.databaseId.database}`}
1583,sendRawJson:!0,supportsCrossDomainXhr:!0,internalChannelParams:{forwardChannelRequestTimeoutMs:6e5},forceLongPolling:this.forceLongPolling,detectBufferingProxy:this.autoDetectLongPolling},f=this.longPollingOptions.timeoutSeconds;f!==void 0&&(B.longPollingTimeout=Math.round(1e3*f)),this.useFetchStreams&&(B.useFetchStreams=!0),this.rt(B.initMessageHeaders,t,n),B.encodeInitMessageHeaders=!0;const g=o.join("");Be(Pn,`Creating RPC '${e}' stream ${i}: ${g}`,B);const y=u.createWebChannel(g,B);this.St(y);let b=!1,D=!1;const T=new FS({_t:M=>{D?Be(Pn,`Not sending because RPC '${e}' stream ${i} is closed:`,M):(b||(Be(Pn,`Opening RPC '${e}' stream ${i} transport.`),y.open(),b=!0),Be(Pn,`RPC '${e}' stream ${i} sending:`,M),y.send(M))},ot:()=>y.close()});return Pc(y,Uc.EventType.OPEN,(()=>{D||(Be(Pn,`RPC '${e}' stream ${i} transport opened.`),T.Rt())})),Pc(y,Uc.EventType.CLOSE,(()=>{D||(D=!0,Be(Pn,`RPC '${e}' stream ${i} transport closed`),T.At(),this.Dt(y))})),Pc(y,Uc.EventType.ERROR,(M=>{D||(D=!0,lr(Pn,`RPC '${e}' stream ${i} transport errored. Name:`,M.name,"Message:",M.message),T.At(new ve(le.UNAVAILABLE,"The operation could not be completed")))})),Pc(y,Uc.EventType.MESSAGE,(M=>{var z;if(!D){const W=M.data[0];fe(!!W,16349);const K=W,he=(K==null?void 0:K.error)||((z=K[0])==null?void 0:z.error);if(he){Be(Pn,`RPC '${e}' stream ${i} received error:`,he);const de=he.status;let ce=(function(S){const A=fn[S];if(A!==void 0)return hD(A)})(de),_e=he.message;de==="NOT_FOUND"&&_e.includes("database")&&_e.includes("does not exist")&&_e.includes(this.databaseId.database)&&lr(`Database '${this.databaseId.database}' not found. Please check your project configuration.`),ce===void 0&&(ce=le.INTERNAL,_e="Unknown error status: "+de+" with message "+he.message),D=!0,T.At(new ve(ce,_e)),y.close()}else Be(Pn,`RPC '${e}' stream ${i} received:`,W),T.Vt(W)}})),$o.ft(),setTimeout((()=>{T.It()}),0),T}terminate(){this.dt.forEach((e=>e.close())),this.dt=[]}St(e){this.dt.push(e)}Dt(e){this.dt=this.dt.filter((t=>t===e))}rt(e,t,n){super.rt(e,t,n),this.databaseInfo.apiKey&&(e["x-goog-api-key"]=this.databaseInfo.apiKey)}createWebChannelTransport(){return N1()}}/**
1584 * @license
1585 * Copyright 2020 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, software
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 */function GS(r){return new $o(r)}$o.gt=!1;class kD{constructor(e,t,n=1e3,i=1.5,o=6e4){this.xt=e,this.timerId=t,this.Ct=n,this.Ft=i,this.Ot=o,this.Mt=0,this.Nt=null,this.Lt=Date.now(),this.reset()}reset(){this.Mt=0}Bt(){this.Mt=this.Ot}Ut(e){this.cancel();const t=Math.floor(this.Mt+this.kt()),n=Math.max(0,Date.now()-this.Lt),i=Math.max(0,t-n);i>0&&Be("ExponentialBackoff",`Backing off for ${i} ms (base delay: ${this.Mt} ms, delay with jitter: ${t} ms, last attempt: ${n} ms ago)`),this.Nt=this.xt.enqueueAfterDelay(this.timerId,i,(()=>(this.Lt=Date.now(),e()))),this.Mt*=this.Ft,this.Mt<this.Ct&&(this.Mt=this.Ct),this.Mt>this.Ot&&(this.Mt=this.Ot)}qt(){this.Nt!==null&&(this.Nt.skipDelay(),this.Nt=null)}cancel(){this.Nt!==null&&(this.Nt.cancel(),this.Nt=null)}kt(){return(Math.random()-.5)*this.Mt}}/**
1599 * @license
1600 * Copyright 2017 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 o_="PersistentStream";
1613class LD{constructor(e,t,n,i,o,u,B,f){this.xt=e,this.$t=n,this.Kt=i,this.connection=o,this.authCredentialsProvider=u,this.appCheckCredentialsProvider=B,this.listener=f,this.state=0,this.Wt=0,this.Qt=null,this.Gt=null,this.stream=null,this.zt=0,this.jt=new kD(e,t)}Ht(){return this.state===1||this.state===5||this.Jt()}Jt(){return this.state===2||this.state===3}start(){this.zt=0,this.state!==4?this.auth():this.Yt()}async stop(){this.Ht()&&await this.close(0)}Zt(){this.state=0,this.jt.reset()}Xt(){this.Jt()&&this.Qt===null&&(this.Qt=this.xt.enqueueAfterDelay(this.$t,6e4,(()=>this.en())))}tn(e){this.nn(),this.stream.send(e)}async en(){if(this.Jt())return this.close(0)}nn(){this.Qt&&(this.Qt.cancel(),this.Qt=null)}rn(){this.Gt&&(this.Gt.cancel(),this.Gt=null)}async close(e,t){this.nn(),this.rn(),this.jt.cancel(),this.Wt++,e!==4?this.jt.reset():t&&t.code===le.RESOURCE_EXHAUSTED?(sn(t.toString()),sn("Using maximum backoff delay to prevent overloading the backend."),this.jt.Bt()):t&&t.code===le.UNAUTHENTICATED&&this.state!==3&&(this.authCredentialsProvider.invalidateToken(),this.appCheckCredentialsProvider.invalidateToken()),this.stream!==null&&(this.sn(),this.stream.close(),this.stream=null),this.state=e,await this.listener.ht(t)}sn(){}auth(){this.state=1;const e=this._n(this.Wt),t=this.Wt;Promise.all([this.authCredentialsProvider.getToken(),this.appCheckCredentialsProvider.getToken()]).then((([n,i])=>{this.Wt===t&&this.an(n,i)}),(n=>{e((()=>{const i=new ve(le.UNKNOWN,"Fetching auth token failed: "+n.message);return this.un(i)}))}))}an(e,t){const n=this._n(this.Wt);this.stream=this.cn(e,t),this.stream.ut((()=>{n((()=>this.listener.ut()))})),this.stream.lt((()=>{n((()=>(this.state=2,this.Gt=this.xt.enqueueAfterDelay(this.Kt,1e4,(()=>(this.Jt()&&(this.state=3),Promise.resolve()))),this.listener.lt())))})),this.stream.ht((i=>{n((()=>this.un(i)))})),this.stream.onMessage((i=>{n((()=>++this.zt==1?this.En(i):this.onNext(i)))}))}Yt(){this.state=5,this.jt.Ut((async()=>{this.state=0,this.start()}))}un(e){return Be(o_,`close with error: ${e}`),this.stream=null,this.close(4,e)}_n(e){return t=>{this.xt.enqueueAndForget((()=>this.Wt===e?t():(Be(o_,"stream callback skipped by getCloseGuardedDispatcher."),Promise.resolve())))}}}class HS extends LD{constructor(e,t,n,i,o,u){super(e,"listen_stream_connection_backoff","listen_stream_idle","health_check_timeout",t,n,i,u),this.serializer=o}cn(e,t){return this.connection.vt("Listen",e,t)}En(e){return this.onNext(e)}onNext(e){this.jt.reset();const t=_S(this.serializer,e),n=(function(o){if(!("targetChange"in o))return Me.min();const u=o.targetChange;return u.targetIds&&u.targetIds.length?Me.min():u.readTime?Xn(u.readTime):Me.min()})(e);return this.listener.hn(t,n)}Tn(e){const t={};t.database=jg(this.serializer),t.addTarget=(function(o,u){let B;const f=u.target;if(B=Ba(f)?{pipelineQuery:wD(o,f)}:_C(f)?{documents:_D(o,f)}:{query:DD(o,f).be},B.targetId=u.targetId,u.resumeToken.approximateByteSize()>0){B.resumeToken=CD(o,u.resumeToken);const g=kg(o,u.expectedCount);g!==null&&(B.expectedCount=g)}else if(u.snapshotVersion.compareTo(Me.min())>0){B.readTime=du(o,u.snapshotVersion.toTimestamp());const g=kg(o,u.expectedCount);g!==null&&(B.expectedCount=g)}return B})(this.serializer,e);const n=vS(this.serializer,e);n&&(t.labels=n),this.tn(t)}Pn(e){const t={};t.database=jg(this.serializer),t.removeTarget=e,this.tn(t)}}class US extends LD{constructor(e,t,n,i,o,u){super(e,"write_stream_connection_backoff","write_stream_idle","health_check_timeout",t,n,i,u),this.serializer=o}get Rn(){return this.zt>0}start(){this.lastStreamToken=void 0,super.start()}sn(){this.Rn&&this.In([])}cn(e,t){return this.connection.vt("Write",e,t)}En(e){return fe(!!e.streamToken,31322),this.lastStreamToken=e.streamToken,fe(!e.writeResults||e.writeResults.length===0,55816),this.listener.An()}onNext(e){fe(!!e.streamToken,12678),this.lastStreamToken=e.streamToken,this.jt.reset();const t=DS(e.writeResults,e.commitTime),n=Xn(e.commitTime);return this.listener.Vn(n,t)}dn(){const e={};e.database=jg(this.serializer),this.tn(e)}In(e){const t={streamToken:this.lastStreamToken,writes:e.map((n=>Xd(this.serializer,n)))};this.tn(t)}}/**
1614 * @license
1615 * Copyright 2017 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 */class zS{}class qS extends zS{constructor(e,t,n,i){super(),this.authCredentials=e,this.appCheckCredentials=t,this.connection=n,this.serializer=i,this.fn=!1}mn(){if(this.fn)throw new ve(le.FAILED_PRECONDITION,"The client has already been terminated.")}tt(e,t,n,i){return this.mn(),Promise.all([this.authCredentials.getToken(),this.appCheckCredentials.getToken()]).then((([o,u])=>this.connection.tt(e,Lg(t,n),i,o,u))).catch((o=>{throw o.name==="FirebaseError"?(o.code===le.UNAUTHENTICATED&&(this.authCredentials.invalidateToken(),this.appCheckCredentials.invalidateToken()),o):new ve(le.UNKNOWN,o.toString())}))}st(e,t,n,i,o){return this.mn(),Promise.all([this.authCredentials.getToken(),this.appCheckCredentials.getToken()]).then((([u,B])=>this.connection.st(e,Lg(t,n),i,u,B,o))).catch((u=>{throw u.name==="FirebaseError"?(u.code===le.UNAUTHENTICATED&&(this.authCredentials.invalidateToken(),this.appCheckCredentials.invalidateToken()),u):new ve(le.UNKNOWN,u.toString())}))}terminate(){this.fn=!0,this.connection.terminate()}}function KS(r,e,t,n){return new qS(r,e,t,n)}/**
1629 * @license
1630 * Copyright 2020 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 */const JS="ComponentProvider",u_=new Map;function QS(r,e,t,n,i){return new PI(r,e,t,i.host,i.ssl,i.experimentalForceLongPolling,i.experimentalAutoDetectLongPolling,OD(i.experimentalLongPollingOptions),i.useFetchStreams,i.isUsingEmulator,n,i._customHeaders,i.grpcFlowControlWindow)}/**
1644 * @license
1645 * Copyright 2018 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 */const c_={didRun:!1,sequenceNumbersCollected:0,targetsRemoved:0,documentsRemoved:0},jD=41943040;class Fn{static withCacheSize(e){return new Fn(e,Fn.DEFAULT_COLLECTION_PERCENTILE,Fn.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT)}constructor(e,t,n){this.cacheSizeCollectionThreshold=e,this.percentileToCollect=t,this.maximumSequenceNumbersToCollect=n}}Fn.DEFAULT_COLLECTION_PERCENTILE=10,Fn.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT=1e3,Fn.DEFAULT=new Fn(jD,Fn.DEFAULT_COLLECTION_PERCENTILE,Fn.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT),Fn.DISABLED=new Fn(-1,0,0);/**
1659 * @license
1660 * Copyright 2018 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 */class is{constructor(e,t){this.previousValue=e,t&&(t.sequenceNumberHandler=n=>this.pn(n),this.gn=n=>t.writeSequenceNumber(n))}pn(e){return this.previousValue=Math.max(e,this.previousValue),this.previousValue}next(){const e=++this.previousValue;return this.gn&&this.gn(e),e}}is.yn=-1;/**
1674 * @license
1675 * Copyright 2020 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 */const MD="The current tab is not in the required state to perform this operation. It might be necessary to refresh the browser tab.";class PD{constructor(){this.onCommittedListeners=[]}addOnCommittedListener(e){this.onCommittedListeners.push(e)}raiseOnCommittedEvent(){this.onCommittedListeners.forEach((e=>e()))}}/**
1689 * @license
1690 * Copyright 2017 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 */async function Ni(r){if(r.code!==le.FAILED_PRECONDITION||r.message!==MD)throw r;Be("LocalStore","Unexpectedly lost primary lease")}/**
1704 * @license
1705 * Copyright 2017 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 */class U{constructor(e){this.nextCallback=null,this.catchCallback=null,this.result=void 0,this.error=void 0,this.isDone=!1,this.callbackAttached=!1,e((t=>{this.isDone=!0,this.result=t,this.nextCallback&&this.nextCallback(t)}),(t=>{this.isDone=!0,this.error=t,this.catchCallback&&this.catchCallback(t)}))}catch(e){return this.next(void 0,e)}next(e,t){return this.callbackAttached&&Te(59440),this.callbackAttached=!0,this.isDone?this.error?this.wrapFailure(t,this.error):this.wrapSuccess(e,this.result):new U(((n,i)=>{this.nextCallback=o=>{this.wrapSuccess(e,o).next(n,i)},this.catchCallback=o=>{this.wrapFailure(t,o).next(n,i)}}))}toPromise(){return new Promise(((e,t)=>{this.next(e,t)}))}wrapUserFunction(e){try{const t=e();return t instanceof U?t:U.resolve(t)}catch(t){return U.reject(t)}}wrapSuccess(e,t){return e?this.wrapUserFunction((()=>e(t))):U.resolve(t)}wrapFailure(e,t){return e?this.wrapUserFunction((()=>e(t))):U.reject(t)}static resolve(e){return new U(((t,n)=>{t(e)}))}static reject(e){return new U(((t,n)=>{n(e)}))}static waitFor(e){return new U(((t,n)=>{let i=0,o=0,u=!1;e.forEach((B=>{++i,B.next((()=>{++o,u&&o===i&&t()}),(f=>n(f)))})),u=!0,o===i&&t()}))}static or(e){let t=U.resolve(!1);for(const n of e)t=t.next((i=>i?U.resolve(i):n()));return t}static forEach(e,t){const n=[];return e.forEach(((i,o)=>{n.push(t.call(this,i,o))})),this.waitFor(n)}static mapArray(e,t){return new U(((n,i)=>{const o=e.length,u=new Array(o);let B=0;for(let f=0;f<o;f++){const g=f;t(e[g]).next((y=>{u[g]=y,++B,B===o&&n(u)}),(y=>i(y)))}}))}static doWhile(e,t){return new U(((n,i)=>{const o=()=>{e()===!0?t().next((()=>{o()}),i):n()};o()}))}}/**
1719 * @license
1720 * Copyright 2017 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, softw
1728are
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 Es="SimpleDb";class Df{static open(e,t,n,i){try{return new Df(t,e.transaction(i,n))}catch(o){throw new eB(t,o)}}constructor(e,t){this.action=e,this.transaction=t,this.aborted=!1,this.wn=new fa,this.transaction.oncomplete=()=>{this.wn.resolve()},this.transaction.onabort=()=>{t.error?this.wn.reject(new eB(e,t.error)):this.wn.resolve()},this.transaction.onerror=n=>{const i=IC(n.target.error);this.wn.reject(new eB(e,i))}}get bn(){return this.wn.promise}abort(e){e&&this.wn.reject(e),this.aborted||(Be(Es,"Aborting transaction:",e?e.message:"Client-initiated abort"),this.aborted=!0,this.transaction.abort())}vn(){const e=this.transaction;this.aborted||typeof e.commit!="function"||e.commit()}store(e){const t=this.transaction.objectStore(e);return new XS(t)}}class yi{static delete(e){return Be(Es,"Removing database:",e),hl(B1().indexedDB.deleteDatabase(e)).toPromise()}static Je(){if(!p1())return!1;if(yi.Sn())return!0;const e=Fd(),t=yi.Dn(e),n=0<t&&t<10,i=VD(e),o=0<i&&i<4.5;return!(e.indexOf("MSIE ")>0||e.indexOf("Trident/")>0||e.indexOf("Edge/")>0||n||o)}static Sn(){var e;return typeof process<"u"&&((e=process.__PRIVATE_env)==null?void 0:e.__PRIVATE_USE_MOCK_PERSISTENCE)==="YES"}static xn(e,t){return e.store(t)}static Dn(e){const t=e.match(/i(?:phone|pad|pod) os ([\d_]+)/i),n=t?t[1].split("_").slice(0,2).join("."):"-1";return Number(n)}constructor(e,t,n){this.name=e,this.version=t,this.Cn=n,this.Fn=null,yi.Dn(Fd())===12.2&&sn("Firestore persistence suffers from a bug in iOS 12.2 Safari that may cause your app to stop working. See https://stackoverflow.com/q/56496296/110915 for details and a potential workaround.")}async On(e){return this.db||(Be(Es,"Opening database:",this.name),this.db=await new Promise(((t,n)=>{const i=indexedDB.open(this.name,this.version);i.onsuccess=o=>{const u=o.target.result;t(u)},i.onblocked=()=>{n(new eB(e,"Cannot upgrade IndexedDB schema while another tab is open. Close all tabs that access Firestore and reload this page to proceed."))},i.onerror=o=>{const u=o.target.error;u.name==="VersionError"?n(new ve(le.FAILED_PRECONDITION,"A newer version of the Firestore SDK was previously used and so the persisted data is not compatible with the version of the SDK you are now using. The SDK will operate with persistence disabled. If you need persistence, please re-upgrade to a newer version of the SDK or else clear the persisted IndexedDB data for your app to start fresh.")):u.name==="InvalidStateError"?n(new ve(le.FAILED_PRECONDITION,"Unable to open an IndexedDB connection. This could be due to running in a private browsing session on a browser whose private browsing sessions do not support IndexedDB: "+u)):n(new eB(e,u))},i.onupgradeneeded=o=>{Be(Es,'Database "'+this.name+'" requires upgrade from version:',o.oldVersion);const u=o.target.result;this.Cn.Mn(u,i.transaction,o.oldVersion,this.version).next((()=>{Be(Es,"Database upgrade to version "+this.version+" complete")}))}}))),this.Nn&&(this.db.onversionchange=t=>this.Nn(t)),this.db}Ln(e){this.Nn=e,this.db&&(this.db.onversionchange=t=>e(t))}async runTransaction(e,t,n,i){const o=t==="readonly";let u=0;for(;;){++u;try{this.db=await this.On(e);const B=Df.open(this.db,e,o?"readonly":"readwrite",n),f=i(B).next((g=>(B.vn(),g))).catch((g=>(B.abort(g),U.reject(g)))).toPromise();return f.catch((()=>{})),await B.bn,f}catch(B){const f=B,g=f.name!=="FirebaseError"&&u<3;if(Be(Es,"Transaction failed with error:",f.message,"Retrying:",g),this.close(),!g)return Promise.reject(f)}}}close(){this.db&&this.db.close(),this.db=void 0}}function VD(r){const e=r.match(/Android ([\d.]+)/i),t=e?e[1].split(".").slice(0,2).join("."):"-1";return Number(t)}class YS{constructor(e){this.Bn=e,this.Un=!1,this.kn=null}get isDone(){return this.Un}get qn(){return this.kn}set cursor(e){this.Bn=e}done(){this.Un=!0}$n(e){this.kn=e}delete(){return hl(this.Bn.delete())}}class eB extends ve{constructor(e,t){super(le.UNAVAILABLE,`IndexedDB transaction '${e}' failed: ${t}`),this.name="IndexedDbTransactionError"}}function Ii(r){return r.name==="IndexedDbTransactionError"}class XS{constructor(e){this.store=e}put(e,t){let n;return t!==void 0?(Be(Es,"PUT",this.store.name,e,t),n=this.store.put(t,e)):(Be(Es,"PUT",this.store.name,"<auto-key>",e),n=this.store.put(e)),hl(n)}add(e){return Be(Es,"ADD",this.store.name,e,e),hl(this.store.add(e))}get(e){return hl(this.store.get(e)).next((t=>(t===void 0&&(t=null),Be(Es,"GET",this.store.name,e,t),t)))}delete(e){return Be(Es,"DELETE",this.store.name,e),hl(this.store.delete(e))}count(){return Be(Es,"COUNT",this.store.name),hl(this.store.count())}Kn(e,t){const n=this.options(e,t),i=n.index?this.store.index(n.index):this.store;if(typeof i.getAll=="function"){const o=i.getAll(n.range);return new U(((u,B)=>{o.onerror=f=>{B(f.target.error)},o.onsuccess=f=>{u(f.target.result)}}))}{const o=this.cursor(n),u=[];return this.Wn(o,((B,f)=>{u.push(f)})).next((()=>u))}}Qn(e,t){const n=this.store.getAll(e,t===null?void 0:t);return new U(((i,o)=>{n.onerror=u=>{o(u.target.error)},n.onsuccess=u=>{i(u.target.result)}}))}Gn(e,t){Be(Es,"DELETE ALL",this.store.name);const n=this.options(e,t);n.zn=!1;const i=this.cursor(n);return this.Wn(i,((o,u,B)=>B.delete()))}jn(e,t){let n;t?n=e:(n={},t=e);const i=this.cursor(n);return this.Wn(i,t)}Hn(e){const t=this.cursor({});return new U(((n,i)=>{t.onerror=o=>{const u=IC(o.target.error);i(u)},t.onsuccess=o=>{const u=o.target.result;u?e(u.primaryKey,u.value).next((B=>{B?u.continue():n()})):n()}}))}Wn(e,t){const n=[];return new U(((i,o)=>{e.onerror=u=>{o(u.target.error)},e.onsuccess=u=>{const B=u.target.result;if(!B)return void i();const f=new YS(B),g=t(B.primaryKey,B.value,f);if(g instanceof U){const y=g.catch((b=>(f.done(),U.reject(b))));n.push(y)}f.isDone?i():f.qn===null?B.continue():B.continue(f.qn)}})).next((()=>U.waitFor(n)))}options(e,t){let n;return e!==void 0&&(typeof e=="string"?n=e:t=e),{index:n,range:t}}cursor(e){let t="next";if(e.reverse&&(t="prev"),e.index){const n=this.store.index(e.index);return e.zn?n.openKeyCursor(e.range,t):n.openCursor(e.range,t)}return this.store.openCursor(e.range,t)}}function hl(r){return new U(((e,t)=>{r.onsuccess=n=>{const i=n.target.result;e(i)},r.onerror=n=>{const i=IC(n.target.error);t(i)}}))}let B_=!1;function IC(r){const e=yi.Dn(Fd());if(e>=12.2&&e<13){const t="An internal error was encountered in the Indexed Database server";if(r.message.indexOf(t)>=0){const n=new ve("internal",`IOS_INDEXEDDB_BUG1: IndexedDb has thrown '${t}'. This is likely due to an unavoidable bug in iOS. See https://stackoverflow.com/q/56496296/110915 for details and a potential workaround.`);return B_||(B_=!0,setTimeout((()=>{throw n}),0)),n}}return r}/**
1734 * @license
1735 * Copyright 2020 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 h_="LruGarbageCollector",FD=1048576;function d_([r,e],[t,n]){const i=Ue(r,t);return i===0?Ue(e,n):i}class $S{constructor(e){this.Jn=e,this.buffer=new gt(d_),this.Yn=0}Zn(){return++this.Yn}Xn(e){const t=[e,this.Zn()];if(this.buffer.size<this.Jn)this.buffer=this.buffer.add(t);else{const n=this.buffer.last();d_(t,n)<0&&(this.buffer=this.buffer.delete(n).add(t))}}get maxValue(){return this.buffer.last()[0]}}class GD{constructor(e,t,n){this.garbageCollector=e,this.asyncQueue=t,this.localStore=n,this.er=null}start(){this.garbageCollector.params.cacheSizeCollectionThreshold!==-1&&this.tr(6e4)}stop(){this.er&&(this.er.cancel(),this.er=null)}get started(){return this.er!==null}tr(e){Be(h_,`Garbage collection scheduled in ${e}ms`),this.er=this.asyncQueue.enqueueAfterDelay("lru_garbage_collection",e,(async()=>{this.er=null;try{await this.localStore.collectGarbage(this.garbageCollector)}catch(t){Ii(t)?Be(h_,"Ignoring IndexedDB error during garbage collection: ",t):await Ni(t)}await this.tr(3e5)}))}}class ZS{constructor(e,t){this.nr=e,this.params=t}calculateTargetCount(e,t){return this.nr.rr(e).next((n=>Math.floor(t/100*n)))}nthSequenceNumber(e,t){if(t===0)return U.resolve(is.yn);const n=new $S(t);return this.nr.forEachTarget(e,(i=>n.Xn(i.sequenceNumber))).next((()=>this.nr.ir(e,(i=>n.Xn(i))))).next((()=>n.maxValue))}removeTargets(e,t,n){return this.nr.removeTargets(e,t,n)}removeOrphanedDocuments(e,t){return this.nr.removeOrphanedDocuments(e,t)}collect(e,t){return this.params.cacheSizeCollectionThreshold===-1?(Be("LruGarbageCollector","Garbage collection skipped; disabled"),U.resolve(c_)):this.getCacheSize(e).next((n=>n<this.params.cacheSizeCollectionThreshold?(Be("LruGarbageCollector",`Garbage collection skipped; Cache size ${n} is lower than threshold ${this.params.cacheSizeCollectionThreshold}`),c_):this.sr(e,t)))}getCacheSize(e){return this.nr.getCacheSize(e)}sr(e,t){let n,i,o,u,B,f,g;const y=Date.now();return this.calculateTargetCount(e,this.params.percentileToCollect).next((b=>(b>this.params.maximumSequenceNumbersToCollect?(Be("LruGarbageCollector",`Capping sequence numbers to collect down to the maximum of ${this.params.maximumSequenceNumbersToCollect} from ${b}`),i=this.params.maximumSequenceNumbersToCollect):i=b,u=Date.now(),this.nthSequenceNumber(e,i)))).next((b=>(n=b,B=Date.now(),this.removeTargets(e,n,t)))).next((b=>(o=b,f=Date.now(),this.removeOrphanedDocuments(e,n)))).next((b=>(g=Date.now(),Uo()<=ut.DEBUG&&Be("LruGarbageCollector",`LRU Garbage Collection
1749	Counted targets in ${u-y}ms
1750	Determined least recently used ${i} in `+(B-u)+`ms
1751	Removed ${o} targets in `+(f-B)+`ms
1752	Removed ${b} documents in `+(g-f)+`ms
1753Total Duration: ${g-y}ms`),U.resolve({didRun:!0,sequenceNumbersCollected:i,targetsRemoved:o,documentsRemoved:b}))))}}function HD(r,e){return new ZS(r,e)}/**
1754 * @license
1755 * Copyright 2020 Google LLC
1756 *
1757 * Licensed under the Apache License, Version 2.0 (the "License");
1758 * you may not use this file except in compliance with the License.
1759 * You may obtain a copy of the License at
1760 *
1761 *   http://www.apache.org/licenses/LICENSE-2.0
1762 *
1763 * Unless required by applicable law or agreed to in writing, software
1764 * distributed under the License is distributed on an "AS IS" BASIS,
1765 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1766 * See the License for the specific language governing permissions and
1767 * limitations under the License.
1768 */const WS="firestore.googleapis.com",f_=!0;class m_{constructor(e){if(e.host===void 0){if(e.ssl!==void 0)throw new ve(le.INVALID_ARGUMENT,"Can't provide ssl option if host option is not set");this.host=WS,this.ssl=f_}else this.host=e.host,this.ssl=e.ssl??f_;if(this.isUsingEmulator=e.emulatorOptions!==void 0,this.credentials=e.credentials,this.ignoreUndefinedProperties=!!e.ignoreUndefinedProperties,this.localCache=e.localCache,e._customHeaders&&(this._customHeaders={...e._customHeaders}),e.cacheSizeBytes===void 0)this.cacheSizeBytes=jD;
1768else{if(e.cacheSizeBytes!==-1&&e.cacheSizeBytes<FD)throw new ve(le.INVALID_ARGUMENT,"cacheSizeBytes must be at least 1048576");this.cacheSizeBytes=e.cacheSizeBytes}if(jI("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=OD(e.experimentalLongPollingOptions??{}),(function(n){if(n.timeoutSeconds!==void 0){if(isNaN(n.timeoutSeconds))throw new ve(le.INVALID_ARGUMENT,`invalid long polling timeout: ${n.timeoutSeconds} (must not be NaN)`);if(n.timeoutSeconds<5)throw new ve(le.INVALID_ARGUMENT,`invalid long polling timeout: ${n.timeoutSeconds} (minimum allowed value is 5)`);if(n.timeoutSeconds>30)throw new ve(le.INVALID_ARGUMENT,`invalid long polling timeout: ${n.timeoutSeconds} (maximum allowed value is 30)`)}})(this.experimentalLongPollingOptions),this.useFetchStreams=!!e.useFetchStreams,e.grpcFlowControlWindow!==void 0){if(typeof e.grpcFlowControlWindow!="number"||e.grpcFlowControlWindow<=0||e.grpcFlowControlWindow>2147483647||!Number.isInteger(e.grpcFlowControlWindow))throw new ve(le.INVALID_ARGUMENT,"grpcFlowControlWindow must be a positive integer and cannot exceed 2147483647");this.grpcFlowControlWindow=e.grpcFlowControlWindow}}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(n,i){return n.timeoutSeconds===i.timeoutSeconds})(this.experimentalLongPollingOptions,e.experimentalLongPollingOptions)&&this.ignoreUndefinedProperties===e.ignoreUndefinedProperties&&this.useFetchStreams===e.useFetchStreams&&this.grpcFlowControlWindow===e.grpcFlowControlWindow&&(function(n,i){if(n===i)return!0;if(!n||!i)return!1;const o=Object.keys(n),u=Object.keys(i);if(o.length!==u.length)return!1;for(const B of o)if(n[B]!==i[B])return!1;return!0})(this._customHeaders,e._customHeaders)}}let UD=class{constructor(e,t,n,i){this._authCredentials=e,this._appCheckCredentials=t,this._databaseId=n,this._app=i,this.type="firestore-lite",this._persistenceKey="(lite)",this._settings=new m_({}),this._settingsFrozen=!1,this._emulatorOptions={},this._terminateTask="notTerminated"}get app(){if(!this._app)throw new ve(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 ve(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 m_(e),this._emulatorOptions=e.emulatorOptions||{},e.credentials!==void 0&&(this._authCredentials=(function(n){if(!n)return new RS;switch(n.type){case"firstParty":return new LS(n.sessionIndex||"0",n.iamToken||null,n.authTokenFactory||null);case"provider":return n.client;default:throw new ve(le.INVALID_ARGUMENT,"makeAuthCredentialsProvider failed due to invalid credential type")}})(e.credentials))}_getSettings(){return this._settings}_getEmulatorOptions(){return this._emulatorOptions}_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(t){const n=u_.get(t);n&&(Be(JS,"Removing Datastore"),u_.delete(t),n.terminate())})(this),Promise.resolve()}};/**
1769 * @license
1770 * Copyright 2020 Google LLC
1771 *
1772 * Licensed under the Apache License, Version 2.0 (the "License");
1773 * you may not use this file except in compliance with the License.
1774 * You may obtain a copy of the License at
1775 *
1776 *   http://www.apache.org/licenses/LICENSE-2.0
1777 *
1778 * Unless required by applicable law or agreed to in writing, software
1779 * distributed under the License is distributed on an "AS IS" BASIS,
1780 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1781 * See the License for the specific language governing permissions and
1782 * limitations under the License.
1783 */class vf{constructor(e,t,n){this.converter=t,this._query=n,this.type="query",this.firestore=e}withConverter(e){return new vf(this.firestore,e,this._query)}}class rn{constructor(e,t,n){this.converter=t,this._key=n,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 gB(this.firestore,this.converter,this._key.path.popLast())}withConverter(e){return new rn(this.firestore,e,this._key)}toJSON(){return{type:rn._jsonSchemaVersion,referencePath:this._key.toString()}}static fromJSON(e,t,n){if(RB(t,rn._jsonSchema))return new rn(e,n||null,new De(ct.fromString(t.referencePath)))}}rn._jsonSchemaVersion="firestore/documentReference/1.0",rn._jsonSchema={type:pn("string",rn._jsonSchemaVersion),referencePath:pn("string")};class gB extends vf{constructor(e,t,n){super(e,t,kB(n)),this._path=n,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 rn(this.firestore,null,new De(e))}withConverter(e){return new gB(this.firestore,e,this._path)}}function Ll(r,e,...t){if(r=iB(r),arguments.length===1&&(e=BC.newId()),LI("doc","path",e),r instanceof UD){const n=ct.fromString(e,...t);return PE(n),new rn(r,null,new De(n))}{if(!(r instanceof rn||r instanceof gB))throw new ve(le.INVALID_ARGUMENT,"Expected first argument to doc() to be a CollectionReference, a DocumentReference or FirebaseFirestore");const n=r._path.child(ct.fromString(e,...t));return PE(n),new rn(r.firestore,r instanceof gB?r.converter:null,new De(n))}}/**
1784 * @license
1785 * Copyright 2017 Google LLC
1786 *
1787 * Licensed under the Apache License, Version 2.0 (the "License");
1788 * you may not use this file except in compliance with the License.
1789 * You may obtain a copy of the License at
1790 *
1791 *   http://www.apache.org/licenses/LICENSE-2.0
1792 *
1793 * Unless required by applicable law or agreed to in writing, software
1794 * distributed under the License is distributed on an "AS IS" BASIS,
1795 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1796 * See the License for the specific language governing permissions and
1797 * limitations under the License.
1798 *//**
1799 * @license
1800 * Copyright 2024 Google LLC
1801 *
1802 * Licensed under the Apache License, Version 2.0 (the "License");
1803 * you may not use this file except in compliance with the License.
1804 * You may obtain a copy of the License at
1805 *
1806 *   http://www.apache.org/licenses/LICENSE-2.0
1807 *
1808 * Unless required by applicable law or agreed to in writing, software
1809 * distributed under the License is distributed on an "AS IS" BASIS,
1810 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1811 * See the License for the specific language governing permissions and
1812 * limitations under the License.
1813 */class ls{constructor(e){this._values=(e||[]).map((t=>t))}toArray(){return this._values.map((e=>e))}isEqual(e){return(function(n,i){if(n.length!==i.length)return!1;for(let o=0;o<n.length;++o)if(n[o]!==i[o])return!1;return!0})(this._values,e._values)}toJSON(){return{type:ls._jsonSchemaVersion,vectorValues:this._values}}static fromJSON(e){if(RB(e,ls._jsonSchema)){if(Array.isArray(e.vectorValues)&&e.vectorValues.every((t=>typeof t=="number")))return new ls(e.vectorValues);throw new ve(le.INVALID_ARGUMENT,"Expected 'vectorValues' field to be a number array")}}}ls._jsonSchemaVersion="firestore/vectorValue/1.0",ls._jsonSchema={type:pn("string",ls._jsonSchemaVersion),vectorValues:pn("object")};/**
1814 * @license
1815 * Copyright 2017 Google LLC
1816 *
1817 * Licensed under the Apache License, Version 2.0 (the "License");
1818 * you may not use this file except in compliance with the License.
1819 * You may obtain a copy of the License at
1820 *
1821 *   http://www.apache.org/licenses/LICENSE-2.0
1822 *
1823 * Unless required by applicable law or agreed to in writing, software
1824 * distributed under the License is distributed on an "AS IS" BASIS,
1825 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1826 * See the License for the specific language governing permissions and
1827 * limitations under the License.
1828 */const eR=/^__.*__$/;class tR{constructor(e,t,n){this.data=e,this.fieldMask=t,this.fieldTransforms=n}toMutation(e,t){return this.fieldMask!==null?new Ai(e,this.data,this.fieldMask,t,this.fieldTransforms):new Tu(e,this.data,t,this.fieldTransforms)}}function zD(r){switch(r){case 0:case 2:case 1:return!0;case 3:case 4:return!1;default:throw Te(40011,{dataSource:r})}}class SC{constructor(e,t,n,i,o,u){this.settings=e,this.databaseId=t,this.serializer=n,this.ignoreUndefinedProperties=i,o===void 0&&this.validatePath(),this.fieldTransforms=o||[],this.fieldMask=u||[]}get path(){return this.settings.path}get dataSource(){return this.settings.dataSource}contextWith(e){return new SC({...this.settings,...e},this.databaseId,this.serializer,this.ignoreUndefinedProperties,this.fieldTransforms,this.fieldMask)}childContextForField(e){var i;const t=(i=this.path)==null?void 0:i.child(e),n=this.contextWith({path:t,arrayElement:!1});return n.validatePathSegment(e),n}childContextForFieldPath(e){var i;const t=(i=this.path)==null?void 0:i.child(e),n=this.contextWith({path:t,arrayElement:!1});return n.validatePath(),n}childContextForArray(e){return this.contextWith({path:void 0,arrayElement:!0})}createError(e){return $d(e,this.settings.methodName,this.settings.hasConverter||!1,this.path,this.settings.targetDoc)}contains(e){return this.fieldMask.find((t=>e.isPrefixOf(t)))!==void 0||this.fieldTransforms.find((t=>e.isPrefixOf(t.field)))!==void 0}validatePath(){if(this.path)for(let e=0;e<this.path.length;e++)this.validatePathSegment(this.path.get(e))}validatePathSegment(e){if(e.length===0)throw this.createError("Document fields must not be empty");if(zD(this.dataSource)&&eR.test(e))throw this.createError('Document fields cannot begin and end with "__"')}}class nR{constructor(e,t,n){this.databaseId=e,this.ignoreUndefinedProperties=t,this.serializer=n||_f(e)}createContext(e,t,n,i=!1){return new SC({dataSource:e,methodName:t,targetDoc:n,path:bn.emptyPath(),arrayElement:!1,hasConverter:i},this.databaseId,this.serializer,this.ignoreUndefinedProperties)}}function sR(r){const e=r._freezeSettings(),t=_f(r._databaseId);return new nR(r._databaseId,!!e.ignoreUndefinedProperties,t)}function rR(r,e,t,n,i,o={}){const u=r.createContext(o.merge||o.mergeFields?2:0,e,t,i);JD("Data must be an object, but it was:",u,n);const B=qD(n,u);let f,g;if(o.merge)f=new qs(u.fieldMask),g=u.fieldTransforms;else if(o.mergeFields){const y=[];for(const b of o.mergeFields){const D=jB(e,b,t);if(!u.contains(D))throw new ve(le.INVALID_ARGUMENT,`Field '${D}' is specified in your field mask but missing from your input data.`);lR(y,D)||y.push(D)}f=new qs(y),g=u.fieldTransforms.filter((b=>f.covers(b.field)))}else f=null,g=u.fieldTransforms;return new tR(new Qn(B),f,g)}function CB(r,e,t){if(KD(r=iB(r)))return JD("Unsupported field value:",e,r),qD(r,e);if(r instanceof RD)return(function(i,o){if(!zD(o.dataSource))throw o.createError(`${i._methodName}() can only be used with update() and set()`);if(!o.path)throw o.createError(`${i._methodName}() is not currently supported inside arrays`);const u=i._toFieldTransform(o);u&&o.fieldTransforms.push(u)})(r,e),null;if(r===void 0&&e.ignoreUndefinedProperties)return null;if(e.path&&e.fieldMask.push(e.path),r instanceof Array){if(e.settings.arrayElement&&e.dataSource!==4)throw e.createError("Nested arrays are not supported");return(function(i,o){const u=[];let B=0;for(const f of i){let g=CB(f,o.childContextForArray(B));g==null&&(g={nullValue:"NULL_VALUE"}),u.push(g),B++}return{arrayValue:{values:u}}})(r,e)}return(function(i,o,u){if((i=iB(i))===null)return{nullValue:"NULL_VALUE"};if(typeof i=="number")return gC(o.serializer,i);if(typeof i=="boolean")return{booleanValue:i};if(typeof i=="string")return{stringValue:i};if(i instanceof Date){const B=xt.fromDate(i);return{timestampValue:du(o.serializer,B)}}if(i instanceof xt){const B=new xt(i.seconds,1e3*Math.floor(i.nanoseconds/1e3));return{timestampValue:du(o.serializer,B)}}if(i instanceof Pr)return{geoPointValue:{latitude:i.latitude,longitude:i.longitude}};if(i instanceof zs)return{bytesValue:CD(o.serializer,i._byteString)};if(i instanceof rn){const B=o.databaseId,f=i.firestore._databaseId;if(!f.isEqual(B))throw o.createError(`Document reference is for database ${f.projectId}/${f.database} but should be for database ${B.projectId}/${B.database}`);return{referenceValue:AC(i.firestore._databaseId||o.databaseId,i._key.path)}}if(i instanceof ls)return(function(f,g){const y=f instanceof ls?f.toArray():f;return{mapValue:{fields:{[dC]:{stringValue:fC},[Ol]:{arrayValue:{values:y.map((D=>{if(typeof D!="number")throw g.createError("VectorValues must only contain numeric values.");return Cf(g.serializer,D)}))}}}}}})(i,o);if(ID(i))return i._toProto(o.serializer);throw o.createError(`Unsupported field value: ${hC(i)}`)})(r,e)}function qD(r,e){const t={};return P1(r)?e.path&&e.path.length>0&&e.fieldMask.push(e.path):Vl(r,((n,i)=>{const o=CB(i,e.childContextForField(n));o!=null&&(t[n]=o)})),{mapValue:{fields:t}}}function KD(r){return!(typeof r!="object"||r===null||r instanceof Array||r instanceof Date||r instanceof xt||r instanceof Pr||r instanceof zs||r instanceof rn||r instanceof RD||r instanceof ls||ID(r))}function JD(r,e,t){if(!KD(t)||!SB(t)){const n=hC(t);throw n==="an object"?e.createError(r+" a custom object"):e.createError(r+" "+n)}}function jB(r,e,t){if((e=iB(e))instanceof NC)return e._internalPath;if(typeof e=="string")return iR(r,e);throw $d("Field path arguments must be of type string or ",r,!1,void 0,t)}const aR=new RegExp("[~\\*/\\[\\]]");function iR(r,e,t){if(e.search(aR)>=0)throw $d(`Invalid field path (${e}). Paths must not contain '~', '*', '/', '[', or ']'`,r,!1,void 0,t);try{return new NC(...e.split("."))._internalPath}catch{throw $d(`Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`,r,!1,void 0,t)}}function $d(r,e,t,n,i){const o=n&&!n.isEmpty(),u=i!==void 0;let B=`Function ${e}
1828() called with invalid data`;t&&(B+=" (via `toFirestore()`)"),B+=". ";let f="";return(o||u)&&(f+=" (found",o&&(f+=` in field ${n}`),u&&(f+=` in document ${i}`),f+=")"),new ve(le.INVALID_ARGUMENT,B+r+f)}function lR(r,e){return r.some((t=>t.isEqual(e)))}function oR(r){return typeof r._readUserData=="function"}/**
1829 * @license
1830 * Copyright 2025 Google LLC
1831 *
1832 * Licensed under the Apache License, Version 2.0 (the "License");
1833 * you may not use this file except in compliance with the License.
1834 * You may obtain a copy of the License at
1835 *
1836 *   http://www.apache.org/licenses/LICENSE-2.0
1837 *
1838 * Unless required by applicable law or agreed to in writing, software
1839 * distributed under the License is distributed on an "AS IS" BASIS,
1840 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1841 * See the License for the specific language governing permissions and
1842 * limitations under the License.
1843 */class Un{constructor(e){this.optionDefinitions=e}_getKnownOptions(e,t){const n=Qn.empty();for(const i in this.optionDefinitions)if(this.optionDefinitions.hasOwnProperty(i)){const o=this.optionDefinitions[i];if(i in e){const u=e[i];let B;o.nestedOptions&&SB(u)?B={mapValue:{fields:new Un(o.nestedOptions).getOptionsProto(t,u)}}:u&&(B=CB(u,t)??void 0),B&&n.set(bn.fromServerFormat(o.serverName),B)}}return n}getOptionsProto(e,t,n){const i=this._getKnownOptions(t,e);if(n){const o=new Map(kI(n,((u,B)=>[bn.fromServerFormat(B),u!==void 0?CB(u,e):null])));i.setAll(o)}return i.value.mapValue.fields??{}}}/**
1844 * @license
1845 * Copyright 2024 Google LLC
1846 *
1847 * Licensed under the Apache License, Version 2.0 (the "License");
1848 * you may not use this file except in compliance with the License.
1849 * You may obtain a copy of the License at
1850 *
1851 *   http://www.apache.org/licenses/LICENSE-2.0
1852 *
1853 * Unless required by applicable law or agreed to in writing, software
1854 * distributed under the License is distributed on an "AS IS" BASIS,
1855 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1856 * See the License for the specific language governing permissions and
1857 * limitations under the License.
1858 */function uR(r){return typeof r=="object"&&r!==null&&!!("nullValue"in r&&(r.nullValue===null||r.nullValue==="NULL_VALUE")||"booleanValue"in r&&(r.booleanValue===null||typeof r.booleanValue=="boolean")||"integerValue"in r&&(r.integerValue===null||typeof r.integerValue=="number"||typeof r.integerValue=="string")||"doubleValue"in r&&(r.doubleValue===null||typeof r.doubleValue=="number")||"timestampValue"in r&&(r.timestampValue===null||(function(t){return typeof t=="object"&&t!==null&&"seconds"in t&&(t.seconds===null||typeof t.seconds=="number"||typeof t.seconds=="string")&&"nanos"in t&&(t.nanos===null||typeof t.nanos=="number")})(r.timestampValue))||"stringValue"in r&&(r.stringValue===null||typeof r.stringValue=="string")||"bytesValue"in r&&(r.bytesValue===null||r.bytesValue instanceof Uint8Array)||"referenceValue"in r&&(r.referenceValue===null||typeof r.referenceValue=="string")||"geoPointValue"in r&&(r.geoPointValue===null||(function(t){return typeof t=="object"&&t!==null&&"latitude"in t&&(t.latitude===null||typeof t.latitude=="number")&&"longitude"in t&&(t.longitude===null||typeof t.longitude=="number")})(r.geoPointValue))||"arrayValue"in r&&(r.arrayValue===null||(function(t){return typeof t=="object"&&t!==null&&!(!("values"in t)||t.values!==null&&!Array.isArray(t.values))})(r.arrayValue))||"mapValue"in r&&(r.mapValue===null||(function(t){return typeof t=="object"&&t!==null&&!(!("fields"in t)||t.fields!==null&&!SB(t.fields))})(r.mapValue))||"fieldReferenceValue"in r&&(r.fieldReferenceValue===null||typeof r.fieldReferenceValue=="string")||"functionValue"in r&&(r.functionValue===null||(function(t){return typeof t=="object"&&t!==null&&!(!("name"in t)||t.name!==null&&typeof t.name!="string"||!("args"in t)||t.args!==null&&!Array.isArray(t.args))})(r.functionValue))||"pipelineValue"in r&&(r.pipelineValue===null||(function(t){return typeof t=="object"&&t!==null&&!(!("stages"in t)||t.stages!==null&&!Array.isArray(t.stages))})(r.pipelineValue)))}function cR(r){return new ls(r)}/**
1859 * @license
1860 * Copyright 2024 Google LLC
1861 *
1862 * Licensed under the Apache License, Version 2.0 (the "License");
vendor: 9,447 bytes, lines 1863-1873
1863 * you may not use this file except in compliance with the License.
1864 * You may obtain a copy of the License at
1865 *
1866 *   http://www.apache.org/licenses/LICENSE-2.0
1867 *
1868 * Unless required by applicable law or agreed to in writing, software
1869 * distributed under the License is distributed on an "AS IS" BASIS,
1870 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1871 * See the License for the specific language governing permissions and
1872 * limitations under the License.
1873 */function Ce(r){let e;return r instanceof Fl?r:(e=SB(r)?pR(r):r instanceof Array?gR(r):QD(r,void 0),e)}function ig(r){if(r instanceof Fl)return r;if(r instanceof ls)return yB(r);if(Array.isArray(r))return yB(cR(r));throw new Error("Unsupported value: "+typeof r)}function RC(r){return FI(r)?dR(r):Ce(r)}class Fl{constructor(){this._protoValueType="ProtoValue"}add(e){return new se("add",[this,Ce(e)],"add")}asBoolean(){if(this instanceof Di)return this;if(this instanceof Gl)return new XD(this);if(this instanceof Nu)return new mR(this);if(this instanceof se)return new YD(this);throw new ve("invalid-argument",`Conversion of type ${typeof this} to BooleanExpression not supported.`)}subtract(e){return new se("subtract",[this,Ce(e)],"subtract")}multiply(e){return new se("multiply",[this,Ce(e)],"multiply")}divide(e){return new se("divide",[this,Ce(e)],"divide")}mod(e){return new se("mod",[this,Ce(e)],"mod")}equal(e){return new se("equal",[this,Ce(e)],"equal").asBoolean()}notEqual(e){return new se("not_equal",[this,Ce(e)],"notEqual").asBoolean()}lessThan(e){return new se("less_than",[this,Ce(e)],"lessThan").asBoolean()}lessThanOrEqual(e){return new se("less_than_or_equal",[this,Ce(e)],"lessThanOrEqual").asBoolean()}greaterThan(e){return new se("greater_than",[this,Ce(e)],"greaterThan").asBoolean()}greaterThanOrEqual(e){return new se("greater_than_or_equal",[this,Ce(e)],"greaterThanOrEqual").asBoolean()}arrayConcat(e,...t){const n=[e,...t].map((i=>Ce(i)));return new se("array_concat",[this,...n],"arrayConcat")}arrayContains(e){return new se("array_contains",[this,Ce(e)],"arrayContains").asBoolean()}arrayContainsAll(e){const t=Array.isArray(e)?new qc(e.map(Ce),"arrayContainsAll"):e;return new se("array_contains_all",[this,t],"arrayContainsAll").asBoolean()}arrayContainsAny(e){const t=Array.isArray(e)?new qc(e.map(Ce),"arrayContainsAny"):e;return new se("array_contains_any",[this,t],"arrayContainsAny").asBoolean()}arrayReverse(){return new se("array_reverse",[this])}arrayLength(){return new se("array_length",[this],"arrayLength")}equalAny(e){const t=Array.isArray(e)?new qc(e.map(Ce),"equalAny"):e;return new se("equal_any",[this,t],"equalAny").asBoolean()}notEqualAny(e){const t=Array.isArray(e)?new qc(e.map(Ce),"notEqualAny"):e;return new se("not_equal_any",[this,t],"notEqualAny").asBoolean()}exists(){return new se("exists",[this],"exists").asBoolean()}charLength(){return new se("char_length",[this],"charLength")}like(e){return new se("like",[this,Ce(e)],"like").asBoolean()}regexContains(e){return new se("regex_contains",[this,Ce(e)],"regexContains").asBoolean()}regexFind(e){return new se("regex_find",[this,Ce(e)],"regexFind")}regexFindAll(e){return new se("regex_find_all",[this,Ce(e)],"regexFindAll")}regexMatch(e){return new se("regex_match",[this,Ce(e)],"regexMatch").asBoolean()}stringContains(e){return new se("string_contains",[this,Ce(e)],"stringContains").asBoolean()}startsWith(e){return new se("starts_with",[this,Ce(e)],"startsWith").asBoolean()}endsWith(e){return new se("ends_with",[this,Ce(e)],"endsWith").asBoolean()}toLower(){return new se("to_lower",[this],"toLower")}toUpper(){return new se("to_upper",[this],"toUpper")}trim(e){const t=[this];return e&&t.push(Ce(e)),new se("trim",t,"trim")}ltrim(e){const t=[this];return e&&t.push(Ce(e)),new se("ltrim",t,"ltrim")}rtrim(e){const t=[this];return e&&t.push(Ce(e)),new se("rtrim",t,"rtrim")}type(){return new se("type",[this])}isType(e){return new se("is_type",[this,yB(e)],"isType").asBoolean()}stringConcat(e,...t){const n=[e,...t].map(Ce);return new se("string_concat",[this,...n],"stringConcat")}stringIndexOf(e){return new se("string_index_of",[this,Ce(e)],"stringIndexOf")}stringRepeat(e){return new se("string_repeat",[this,Ce(e)],"stringRepeat")}stringReplaceAll(e,t){return new se("string_replace_all",[this,Ce(e),Ce(t)],"stringReplaceAll")}stringReplaceOne(e,t){return new se("string_replace_one",[this,Ce(e),Ce(t)],"stringReplaceOne")}concat(e,...t){const n=[e,...t].map(Ce);return new se("concat",[this,...n],"concat")}reverse(){return new se("reverse",[this],"reverse")}arrayFilter(e,t){return new se("array_filter",[this,Ce(e),t],"arrayFilter")}arrayTransform(e,t){return new se("array_transform",[this,Ce(e),t],"arrayTransform")}arrayTransformWithIndex(e,t,n){return new se("array_transform",[this,Ce(e),Ce(t),n],"arrayTransformWithIndex")}arraySlice(e,t){const n=[this,Ce(e)];return t!==void 0&&n.push(Ce(t)),new se("array_slice",n,"arraySlice")}arrayFirst(){return new se("array_first",[this],"arrayFirst")}arrayFirstN(e){return new se("array_first_n",[this,Ce(e)],"arrayFirstN")}arrayLast(){return new se("array_last",[this],"arrayLast")}arrayLastN(e){return new se("array_last_n",[this,Ce(e)],"arrayLastN")}arrayMaximum(){return new se("maximum",[this],"arrayMaximum")}arrayMaximumN(e){return new se("maximum_n",[this,Ce(e)],"arrayMaximumN")}arrayMinimum(){return new se("minimum",[this],"arrayMinimum")}arrayMinimumN(e){return new se("minimum_n",[this,Ce(e)],"arrayMinimumN")}arrayIndexOf(e){return new se("array_index_of",[this,Ce(e),Ce("first")],"arrayIndexOf")}arrayLastIndexOf(e){return new se("array_index_of",[this,Ce(e),Ce("last")],"arrayLastIndexOf")}arrayIndexOfAll(e){return new se("array_index_of_all",[this,Ce(e)],"arrayIndexOfAll")}byteLength(){return new se("byte_length",[this],"byteLength")}ceil(){return new se("ceil",[this])}floor(){return new se("floor",[this])}abs(){return new se("abs",[this])}exp(){return new se("exp",[this])}mapGet(e){return new se("map_get",[this,yB(e)],"mapGet")}mapSet(e,t,...n){const i=[this,Ce(e),Ce(t),...n.map(Ce)];return new se("map_set",i,"mapSet")}mapKeys(){return new se("map_keys",[this],"mapKeys")}mapValues(){return new se("map_values",[this],"mapValues")}mapEntries(){return new se("map_entries",[this],"mapEntries")}getField(e){return new se("get_field",[this,Ce(e)],"get_field")}count(){return xs._create("count",[this],"count")}sum(){return xs._create("sum",[this],"sum")}average(){return xs._create("average",[this],"average")}minimum(){return xs._create("minimum",[this],"minimum")}maximum(){return xs._create("maximum",[this],"maximum")}first(){return xs._create("first",[this],"first")}last(){return xs._create("last",[this],"last")}arrayAgg(){return xs._create("array_agg",[this],"arrayAgg")}arrayAggDistinct(){return xs._create("array_agg_distinct",[this],"arrayAggDistinct")}countDistinct(){return xs._create("count_distinct",[this],"countDistinct")}logicalMaximum(e,...t){const n=[e,...t];return new se("maximum",[this,...n.map(Ce)],"logicalMaximum")}logicalMinimum(e,...t){const n=[e,...t];return new se("minimum",[this,...n.map(Ce)],"minimum")}vectorLength(){return new se("vector_length",[this],"vectorLength")}cosineDistance(e){return new se("cosine_distance",[this,ig(e)],"cosineDistance")}dotProduct(e){return new se("dot_product",[this,ig(e)],"dotProduct")}euclideanDistance(e){return new se("euclidean_distance",[this,ig(e)],"euclideanDistance")}unixMicrosToTimestamp(){return new se("unix_micros_to_timestamp",[this],"unixMicrosToTimestamp")}timestampToUnixMicros(){return new se("timestamp_to_unix_micros",[this],"timestampToUnixMicros")}unixMillisToTimestamp(){return new se("unix_millis_to_timestamp",[this],"unixMillisToTimestamp")}timestampToUnixMillis(){return new se("timestamp_to_unix_millis",[this],"timestampToUnixMillis")}unixSecondsToTimestamp(){return new se("unix_seconds_to_timestamp",[this],"unixSecondsToTimestamp")}timestampToUnixSeconds(){return new se("timestamp_to_unix_seconds",[this],"timestampToUnixSeconds")}timestampAdd(e,t){return new se("timestamp_add",[this,Ce(e),Ce(t)],"timestampAdd")}timestampSubtract(e,t){return new se("timestamp_subtract",[this,Ce(e),Ce(t)],"timestampSubtract")}timestampDiff(e,t){return new se("timestamp_diff",[this,RC(e),Ce(t)],"timestampDiff")}timestampExtract(e,t){const n=[this,Ce(e)];return t&&n.push(Ce(t)),new se("timestamp_extract",n,"timestampExtract")}documentId(){return new se("document_id",[this],"documentId")}parent(){return new se("parent",[this],"parent")}substring(e,t){const n=Ce(e);return new se("substring",t===void 0?[this,n]:[this,n,Ce(t)],"substring")}arrayGet(e){return new se("array_get",[this,Ce(e)],"arrayGet")}isError(){return new se("is_error",[this],"isError").asBoolean()}ifError(e){const t=new se("if_error",[this,Ce(e)],"ifError");return e instanceof Di?t.asBoolean():t}isAbsent(){return new se("is_absent",[this],"isAbsent").asBoolean()}mapRemove(e){return new se("map_remove",[this,Ce(e)],"mapRemove")}mapMerge(e,...t){const n=Ce(e),i=t.map(Ce);return new se("map_merge",[this,n,...i],"mapMerge")}pow(e){return new se("pow",[this,Ce(e)])}trunc(e){return e===void 0?new se("trunc",[this]):new se("trunc",[this,Ce(e)],"trunc")}round(e){return e===void 0?new se("round",[this]):new se("round",[this,Ce(e)],"round")}collectionId(){return new se("collection_id",[this])}length(){return new se("length",[this])}ln(){return new se("ln",[this])}sqrt(){return new se("sqrt",[this])}
vendor: 4,836 bytes, lines 1873-1877
1873stringReverse(){return new se("string_reverse",[this])}ifAbsent(e){return new se("if_absent",[this,Ce(e)],"ifAbsent")}ifNull(e){return new se("if_null",[this,Ce(e)],"ifNull")}coalesce(e,...t){return new se("coalesce",[this,Ce(e),...t.map(Ce)],"coalesce")}join(e){return new se("join",[this,Ce(e)],"join")}log10(){return new se("log10",[this])}arraySum(){return new se("sum",[this])}split(e){return new se("split",[this,Ce(e)])}timestampTruncate(e,t){const n=[this,Ce(e)];return t&&n.push(Ce(t)),new se("timestamp_trunc",n)}ascending(){return CR(this)}descending(){return yR(this)}as(e){return new hR(this,e,"as")}}class xs{constructor(e,t){this.name=e,this.params=t,this.exprType="AggregateFunction",this._protoValueType="ProtoValue"}static _create(e,t,n){const i=new xs(e,t);return i._methodName=n,i}as(e){return new BR(this,e,"as")}_toProto(e){return{functionValue:{name:this.name,args:this.params.map((t=>t._toProto(e)))}}}_readUserData(e){e=this._methodName?e.contextWith({methodName:this._methodName}):e,this.params.forEach((t=>t._readUserData(e)))}}class BR{constructor(e,t,n){this.aggregate=e,this.alias=t,this._methodName=n}_readUserData(e){this.aggregate._readUserData(e)}}class hR{constructor(e,t,n){this.expr=e,this.alias=t,this._methodName=n,this.exprType="AliasedExpression",this.selectable=!0}_readUserData(e){this.expr._readUserData(e)}}class qc extends Fl{constructor(e,t){super(),this.ur=e,this._methodName=t,this.expressionType="ListOfExpressions"}_toProto(e){return{arrayValue:{values:this.ur.map((t=>t._toProto(e)))}}}_readUserData(e){this.ur.forEach((t=>t._readUserData(e)))}}class Nu extends Fl{constructor(e,t){super(),this.fieldPath=e,this._methodName=t,this.expressionType="Field",this.selectable=!0}get _fieldPath(){return this.fieldPath}get fieldName(){return this.fieldPath.canonicalString()}get alias(){return this.fieldName}get expr(){return this}geoDistance(e){return new se("geo_distance",[this,Ce(e)],"geoDistance")}_toProto(e){return{fieldReferenceValue:this.fieldPath.canonicalString()}}_readUserData(e){}}function dR(r){return fR(r,"field")}function fR(r,e){return new Nu(typeof r=="string"?su===r?IS()._internalPath:jB("field",r):r._internalPath,e)}class Gl extends Fl{constructor(e,t){super(),this.value=e,this._methodName=t,this.expressionType="Constant"}static _fromProto(e){const t=new Gl(e,void 0);return t._protoValue=e,t}_toProto(e){return fe(this._protoValue!==void 0,237),this._protoValue}_getValue(){return this._protoValue}_readUserData(e){e=this._methodName?e.contextWith({methodName:this._methodName}):e,uR(this._protoValue)||(this._protoValue=CB(this.value,e))}}function yB(r,e){return QD(r,"constant")}function QD(r,e){const t=new Gl(r,e);return typeof r=="boolean"?new XD(t):t}class se extends Fl{constructor(e,t,n,i){super(),this.name=e,this.params=t,this.expressionType="Function",this._optionsProto=void 0,n!==void 0&&(this._methodName=n),i!==void 0&&(this._options=i)}get _optionsUtil(){return new Un({})}_toProto(e){const t={functionValue:{name:this.name,args:this.params.map((n=>n._toProto(e)))}};return this._optionsProto&&(t.functionValue.options=this._optionsProto),t}_readUserData(e){e=this._methodName?e.contextWith({methodName:this._methodName}):e,this.params.forEach((t=>t._readUserData(e))),this._options&&(this._optionsProto=this._optionsUtil.getOptionsProto(e,this._options))}}class Di extends Fl{get _methodName(){return this._expr._methodName}countIf(){return xs._create("count_if",[this],"countIf")}not(){return new se("not",[this],"not").asBoolean()}conditional(e,t){return new se("conditional",[this,e,t],"conditional")}ifError(e){const t=Ce(e),n=new se("if_error",[this,t],"ifError");return t instanceof Di?n.asBoolean():n}_toProto(e){return this._expr._toProto(e)}_readUserData(e){this._expr._readUserData(e)}}class YD extends Di{constructor(e){super(),this._expr=e,this.expressionType="Function"}}class XD extends Di{constructor(e){super(),this._expr=e,this.expressionType="Constant"}_getValue(){return this._expr._getValue()}}class mR extends Di{constructor(e){super(),this._expr=e,this.expressionType="Field"}}function pR(r,e){const t=[];for(const n in r)if(Object.prototype.hasOwnProperty.call(r,n)){const i=r[n];t.push(yB(n)),t.push(Ce(i))}return new se("map",t,"map")}function gR(r){return(function(t,n){return new se("array",t.map((i=>Ce(i))),n)})(r,"array")}function CR(r){return new OC(RC(r),"ascending","ascending")}function yR(r){return new OC(RC(r),"descending","descending")}class OC{constructor(e,t,n){this.expr=e,this.direction=t,this._methodName=n,this._protoValueType="ProtoValue"}_toProto(e){return{mapValue:{fields:{direction:SD(this.direction),expression:this.expr._toProto(e)}}}}_readUserData(e){this.expr._readUserData(e)}}/**
1874 * @license
1875 * Copyright 2024 Google LLC
1876 *
1877 * Licensed under the Apache License, Version 2.0 (the "License");
1878 * you may not use this file except in compliance with the License.
1879 * You may obtain a copy of the License at
1880 *
1881 *   http://www.apache.org/licenses/LICENSE-2.0
1882 *
1883 * Unless required by applicable law or agreed to in writing, software
1884 * distributed under the License is distributed on an "AS IS" BASIS,
1885 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1886 * See the License for the specific language governing permissions and
1887 * limitations under the License.
1888 */class As{constructor(e){this.optionsProto=void 0,{rawOptions:this.rawOptions,...this.knownOptions}=e}_readUserData(e){this.optionsProto=this._optionsUtil.getOptionsProto(e,this.knownOptions,this.rawOptions)}_toProto(e){return{name:this._name,options:this.optionsProto}}}class $D extends As{get _name(){return"add_fields"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.fields=e}_toProto(e){return{...super._toProto(e),args:[pB(e,this.fields)]}}_readUserData(e){super._readUserData(e),vi(this.fields,e)}}class ZD extends As{get _name(){return"aggregate"}get _optionsUtil(){return new Un({})}constructor(e,t,n){super(n),this.groups=e,this.accumulators=t}_toProto(e){return{...super._toProto(e),args:[pB(e,this.accumulators),pB(e,this.groups)]}}_readUserData(e){super._readUserData(e),vi(this.groups,e),vi(this.accumulators,e)}}class WD extends As{get _name(){return"distinct"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.groups=e}_toProto(e){return{...super._toProto(e),args:[pB(e,this.groups)]}}_readUserData(e){super._readUserData(e),vi(this.groups,e)}}class MB extends As{get _name(){return"collection"}get _optionsUtil(){return new Un({forceIndex:{serverName:"force_index"}})}constructor(e,t){super(t),this.Er=e.startsWith("/")?e:"/"+e}_toProto(e){return{...super._toProto(e),args:[{referenceValue:this.Er}]}}_readUserData(e){super._readUserData(e)}}class PB extends As{get _name(){return"collection_group"}get _optionsUtil(){return new Un({forceIndex:{serverName:"force_index"}})}constructor(e,t){super(t),this.collectionId=e}_toProto(e){return{...super._toProto(e),args:[{referenceValue:""},{stringValue:this.collectionId}]}}_readUserData(e){super._readUserData(e)}}class wf extends As{get _name(){return"database"}get _optionsUtil(){return new Un({})}_toProto(e){return{...super._toProto(e)}}_readUserData(e){super._readUserData(e)}}class Tf extends As{get _name(){return"documents"}get _optionsUtil(){return new Un({})}constructor(e,t){if(super(t),!e||e.length===0)throw new ve(le.INVALID_ARGUMENT,"Empty document paths are not allowed in DocumentsSource");const n=e.map((o=>o.startsWith("/")?o:"/"+o)),i=new Set(n);if(i.size!==n.length)throw new ve(le.INVALID_ARGUMENT,"Duplicate document paths are not allowed in DocumentsSource");this.hr=n,this.Tr=i}_toProto(e){return{...super._toProto(e),args:this.hr.map((t=>({referenceValue:t})))}}_readUserData(e){super._readUserData(e)}}class Af extends As{get _name(){return"where"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.condition=e}_toProto(e){return{...super._toProto(e),args:[this.condition._toProto(e)]}}_readUserData(e){super._readUserData(e),vi(this.condition,e)}}class fu extends As{get _name(){return"limit"}get _optionsUtil(){return new Un({})}constructor(e,t){fe(!isNaN(e)&&e!==1/0&&e!==-1/0,34860),super(t),this.limit=e}_toProto(e){return{...super._toProto(e),args:[gC(e,this.limit)]}}}class p_ extends As{get _name(){return"offset"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.offset=e}_toProto(e){return{...super._toProto(e),args:[gC(e,this.offset)]}}}class bR extends As{get _name(){return"select"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.selections=e}_toProto(e){return{...super._toProto(e),args:[pB(e,this.selections)]}}_readUserData(e){super._readUserData(e),vi(this.selections,e)}}class Nf extends As{get _name(){return"sort"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.orderings=e}_toProto(e){return{...super._toProto(e),args:this.orderings.map((t=>t._toProto(e)))}}_readUserData(e){super._readUserData(e),vi(this.orderings,e)}}class kC extends As{get _name(){return"replace_with"}get _optionsUtil(){return new Un({})}constructor(e,t){super(t),this.map=e}_toProto(e){return{...super._toProto(e),args:[this.map._toProto(e),SD(kC.Pr)]}}_readUserData(e){super._readUserData(e),vi(this.map,e)}}kC.Pr="full_replace";function vi(r,e){return oR(r)?r._readUserData(e):Array.isArray(r)?r.forEach((t=>t._readUserData(e))):r instanceof Map?r.forEach((t=>t._readUserData(e))):Object.values(r).forEach((t=>t._readUserData(e))),r}// Copyright 2024 Google LLC* @license
1889class F{constructor(e,t){this.type=e,this.value=t}static dr(){return new F("ERROR",void 0)}static mr(){return new F("UNSET",void 0)}static pr(){return new F("NULL",Mr)}static newValue(e){return _s(e)?new F("NULL",Mr):(function(n){return!!n&&"booleanValue"in n})(e)?new F("BOOLEAN",e):Rr(e)?new F("INT",e):gl(e)?new F("DOUBLE",e):(function(n){return!!n&&"timestampValue"in n&&!!n.timestampValue})(e)?new F("TIMESTAMP",e):(function(n){return!!n&&"stringValue"in n})(e)?new F("STRING",e):(function(n){return!!n&&"bytesValue"in n})(e)?new F("BYTES",e):e.referenceValue?new F("REFERENCE",e):e.geoPointValue?new F("GEO_POINT",e):_i(e)?new F("ARRAY",e):kl(e)?new F("VECTOR",e):El(e)?new F("MAP",e):new F("ERROR",void 0)}gr(){return this.type==="ERROR"||this.type==="UNSET"}yr(){return this.type==="NULL"}}function tB(r){if(!r.gr())return r.value}function ev(r){return r instanceof Di?r._expr:r}function Fe(r){if((r=ev(r))instanceof Nu)return new xR(r);if(r instanceof Gl)return new ER(r);if(r instanceof qc)return new _R(r);if(r instanceof se){if(r.name==="add")return new wR(r);if(r.name==="subtract")return new TR(r);if(r.name==="multiply")return new AR(r);if(r.name==="divide")return new NR(r);if(r.name==="mod")return new IR(r);if(r.name==="and")return new SR(r);if(r.name==="equal")return new UR(r);if(r.name==="not_equal")return new zR(r);if(r.name==="less_than")return new qR(r);if(r.name==="less_than_or_equal")return new KR(r);if(r.name==="greater_than")return new JR(r);if(r.name==="greater_than_or_equal")return new QR(r);if(r.name==="array_concat")return new YR(r);if(r.name==="array_reverse")return new XR(r);if(r.name==="array_contains")return new $R(r);if(r.name==="array_contains_all")return new ZR(r);if(r.name==="array_contains_any")return new WR(r);if(r.name==="array_length")return new eO(r);if(r.name==="array_element")return new tO(r);if(r.name==="equal_any")return new tv(r);if(r.name==="not_equal_any")return new OR(r);if(r.name==="is_nan")return new kR(r);if(r.name==="is_not_nan")return new LR(r);if(r.name==="is_null")return new jR(r);if(r.name==="is_not_null")return new MR(r);if(r.name==="is_error")return new PR(r);if(r.name==="exists")return new VR(r);if(r.name==="not")return new If(r);if(r.name==="or")return new RR(r);if(r.name==="xor")return new LC(r);if(r.name==="conditional")return new FR(r);if(r.name==="maximum")return new GR(r);if(r.name==="minimum")return new HR(r);if(r.name==="reverse")return new nO(r);if(r.name==="replace_first")return new sO(r);if(r.name==="replace_all")return new rO(r);if(r.name==="char_length")return new aO(r);if(r.name==="byte_length")return new iO(r);if(r.name==="like")return new lO(r);if(r.name==="regex_contains")return new oO(r);if(r.name==="regex_match")return new uO(r);
1889if(r.name==="string_contains")return new cO(r);if(r.name==="starts_with")return new BO(r);if(r.name==="ends_with")return new hO(r);if(r.name==="to_lower")return new dO(r);if(r.name==="to_upper")return new fO(r);if(r.name==="trim")return new mO(r);if(r.name==="string_concat")return new pO(r);if(r.name==="map_get")return new gO(r);if(r.name==="cosine_distance")return new CO(r);if(r.name==="dot_product")return new yO(r);if(r.name==="euclidean_distance")return new bO(r);if(r.name==="vector_length")return new xO(r);if(r.name==="unix_micros_to_timestamp")return new wO(r);if(r.name==="timestamp_to_unix_micros")return new NO(r);if(r.name==="unix_millis_to_timestamp")return new TO(r);if(r.name==="timestamp_to_unix_millis")return new IO(r);if(r.name==="unix_seconds_to_timestamp")return new AO(r);if(r.name==="timestamp_to_unix_seconds")return new SO(r);if(r.name==="timestamp_add")return new RO(r);if(r.name==="timestamp_subtract")return new OO(r)}throw new Error(`Unknown Expr : ${r}`)}class xR{constructor(e){this.expr=e}evaluate(e,t){if(this.expr.fieldName===su)return F.newValue({referenceValue:mB(e.serializer,t.key)});if(this.expr.fieldName==="__update_time__")return F.newValue({timestampValue:kd(e.serializer,t.version)});if(this.expr.fieldName==="__create_time__")return F.newValue({timestampValue:kd(e.serializer,t.createTime)});const n=t.data.field(this.expr._fieldPath);return n?pf(n)?F.newValue((function(o,u){if(o.serverTimestampBehavior==="estimate")return{timestampValue:kd(o.serializer,Me.fromTimestamp(ru(u)))};if(o.serverTimestampBehavior==="previous"){const B=OB(u);if(B)return B}return{nullValue:"NULL_VALUE"}})(e,n)):F.newValue(n):F.mr()}}class ER{constructor(e){this.expr=e}evaluate(e,t){return F.newValue(this.expr._getValue())}}class _R{constructor(e){this.expr=e}evaluate(e,t){const n=this.expr.ur.map((i=>Fe(i).evaluate(e,t)));return n.some((i=>i.gr()))?F.dr():F.newValue({arrayValue:{values:n.map((i=>i.value))}})}}function jn(r){return gl(r)?Number(r.doubleValue):Number(r.integerValue)}function Vr(r){return BigInt(r.integerValue)}const DR=BigInt("0x7fffffffffffffff"),vR=-BigInt("0x8000000000000000");class VB{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length>=2,24778);const n=Fe(this.expr.params[0]).evaluate(e,t),i=Fe(this.expr.params[1]).evaluate(e,t);let o=this.wr(n,i);for(const u of this.expr.params.slice(2)){const B=Fe(u).evaluate(e,t);o=this.wr(o,B)}return o}wr(e,t){if(e.gr()||t.gr())return F.dr();if(e.yr()||t.yr())return F.pr();const n=e.value,i=t.value;if(!gl(n)&&!Rr(n)||!gl(i)&&!Rr(i))return F.dr();if(gl(n)||gl(i)){const o=this.br(n,i);return o?F.newValue(o):F.dr()}if(Rr(n)&&Rr(i)){const o=this.vr(n,i);return o===void 0?F.dr():typeof o=="number"?F.newValue({doubleValue:o}):o<vR||o>DR?F.dr():F.newValue({integerValue:`${o}`})}return F.dr()}}function ba(r,e){return gn(r)!==gn(e)?"TYPE_MISMATCH":us(r)||us(e)?"NOT_EQ":_s(r)&&_s(e)?"EQ":_s(r)||_s(e)?"NULL":_i(r)&&_i(e)?(function(n,i){var u,B,f;if(((u=n.values)==null?void 0:u.length)!==((B=i.values)==null?void 0:B.length))return"NOT_EQ";let o=!1;for(let g=0;g<(((f=n.values)==null?void 0:f.length)??0);g++){const y=n.values[g],b=i.values[g];switch(ba(y,b)){case"EQ":break;case"NOT_EQ":case"TYPE_MISMATCH":return"NOT_EQ";case"NULL":o=!0;break;default:Te(44609,{Sr:y,Dr:b})}}return o?"NULL":"EQ"})(r.arrayValue,e.arrayValue):kl(r)&&kl(e)||El(r)&&El(e)?(function(n,i){const o=n.fields||{},u=i.fields||{};if(Ud(o)!==Ud(u))return"NOT_EQ";let B=!1;for(const f in o)if(o.hasOwnProperty(f)){if(u[f]===void 0)return"NOT_EQ";switch(ba(o[f],u[f])){case"NOT_EQ":case"TYPE_MISMATCH":return"NOT_EQ";case"NULL":B=!0}}return B?"NULL":"EQ"})(r.mapValue,e.mapValue):(function(n,i){return Js(n,i,{o:!1,t:!0,i:!0})})(r,e)?"EQ":"NOT_EQ"}
1889class wR extends VB{vr(e,t){return Vr(e)+Vr(t)}br(e,t){return{doubleValue:jn(e)+jn(t)}}}class TR extends VB{constructor(e){super(e),this.expr=e}vr(e,t){return Vr(e)-Vr(t)}br(e,t){return{doubleValue:jn(e)-jn(t)}}}class AR extends VB{constructor(e){super(e),this.expr=e}vr(e,t){return Vr(e)*Vr(t)}br(e,t){return{doubleValue:jn(e)*jn(t)}}}class NR extends VB{constructor(e){super(e),this.expr=e}vr(e,t){const n=Vr(t);if(n!==BigInt(0))return Vr(e)/n}br(e,t){const n=jn(t);return n===0?{doubleValue:au(n)?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY}:{doubleValue:jn(e)/n}}}class IR extends VB{constructor(e){super(e),this.expr=e}vr(e,t){const n=Vr(t);if(n!==BigInt(0))return Vr(e)%n}br(e,t){const n=jn(t);if(n!==0)return{doubleValue:jn(e)%n}}}class SR{constructor(e){this.expr=e}evaluate(e,t){var o;let n=!1,i=!1;for(const u of this.expr.params){const B=Fe(u).evaluate(e,t);switch(B.type){case"BOOLEAN":if(!((o=B.value)!=null&&o.booleanValue))return F.newValue(An);break;case"NULL":i=!0;break;default:n=!0}}return n?F.dr():i?F.pr():F.newValue(os)}}class If{constructor(e){this.expr=e}evaluate(e,t){var i;fe(this.expr.params.length===1,9634);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"BOOLEAN":return F.newValue({booleanValue:!((i=n.value)!=null&&i.booleanValue)});case"NULL":return F.pr();default:return F.dr()}}}class RR{constructor(e){this.expr=e}evaluate(e,t){var o;let n=!1,i=!1;for(const u of this.expr.params){const B=Fe(u).evaluate(e,t);switch(B.type){case"BOOLEAN":if((o=B.value)!=null&&o.booleanValue)return F.newValue(os);break;case"NULL":i=!0;break;default:n=!0}}return n?F.dr():i?F.pr():F.newValue(An)}}class LC{constructor(e){this.expr=e}evaluate(e,t){var o;let n=!1,i=!1;for(const u of this.expr.params){const B=Fe(u).evaluate(e,t);switch(B.type){case"BOOLEAN":n=LC.xor(n,!!((o=B.value)!=null&&o.booleanValue));break;case"NULL":i=!0;break;default:return F.dr()}}
1889return i?F.pr():F.newValue({booleanValue:n})}static xor(e,t){return(e||t)&&!(e&&t)}}class tv{constructor(e){this.expr=e}evaluate(e,t){var u,B;fe(this.expr.params.length===2,55094);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"NULL":n=!0;break;case"ERROR":case"UNSET":return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);switch(o.type){case"ARRAY":break;case"NULL":n=!0;break;default:return F.dr()}if(n)return F.pr();for(const f of((B=(u=o.value)==null?void 0:u.arrayValue)==null?void 0:B.values)??[])switch(_s(i.value)&&_s(f)?"EQ":ba(i.value,f)){case"EQ":return F.newValue(os);case"NOT_EQ":case"TYPE_MISMATCH":break;case"NULL":n=!0;break;default:Te(44608,{value:i.value,candidate:f})}return n?F.pr():F.newValue(An)}}class OR{constructor(e){this.expr=e}evaluate(e,t){return new If(new se("not",[new se("equal_any",this.expr.params)])).evaluate(e,t)}}class kR{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===1,23322);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"INT":return F.newValue(An);case"DOUBLE":return F.newValue({booleanValue:isNaN(jn(n.value))});case"NULL":return F.pr();default:return F.dr()}}}class LR{constructor(e){this.expr=e}evaluate(e,t){return fe(this.expr.params.length===1,50406),new If(new se("not",[new se("is_nan",this.expr.params)])).evaluate(e,t)}}class jR{constructor(e){this.expr=e}evaluate(e,t){switch(fe(this.expr.params.length===1,23123),Fe(this.expr.params[0]).evaluate(e,t).type){case"NULL":return F.newValue(os);case"UNSET":case"ERROR":return F.dr();default:return F.newValue(An)}}}class MR{constructor(e){this.expr=e}evaluate(e,t){return fe(this.expr.params.length===1,23167),new If(new se("not",[new se("is_null",this.expr.params)])).evaluate(e,t)}}class PR{constructor(e){this.expr=e}evaluate(e,t){return fe(this.expr.params.length===1,5228),Fe(this.expr.params[0]).evaluate(e,t).type==="ERROR"?F.newValue(os):F.newValue(An)}}class VR{constructor(e){this.expr=e}evaluate(e,t){switch(fe(this.expr.params.length===1,6877),Fe(this.expr.params[0]).evaluate(e,t).type){case"ERROR":return F.dr();case"UNSET":return F.newValue(An);default:return F.newValue(os)}}}class FR{constructor(e){this.expr=e}evaluate(e,t){var i;fe(this.expr.params.length===3,11706);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"BOOLEAN":return(i=n.value)!=null&&i.booleanValue?Fe(this.expr.params[1]).evaluate(e,t):Fe(this.expr.params[2]).evaluate(e,t);case"NULL":return Fe(this.expr.params[2]).evaluate(e,t);default:return F.dr()}}}class GR{constructor(e){this.expr=e}evaluate(e,t){const n=this.expr.params.map((o=>Fe(o).evaluate(e,t)));let i;for(const o of n)switch(o.type){case"ERROR":case"UNSET":case"NULL":continue;default:i=i===void 0||Hn(o.value,i.value)>0?o:i}return i===void 0?F.pr():i}}class HR{constructor(e){this.expr=e}evaluate(e,t){const n=this.expr.params.map((o=>Fe(o).evaluate(e,t)));let i;for(const o of n)switch(o.type){case"ERROR":case"UNSET":case"NULL":continue;default:i=i===void 0||Hn(o.value,i.value)<0?o:i}return i===void 0?F.pr():i}}class Iu{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===2,31033,`${this.expr.name}() function should have exactly 2 params`);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"ERROR":case"UNSET":return F.dr()}const i=Fe(this.expr.params[1]).evaluate(e,t);switch(i.type){case"ERROR":case"UNSET":return F.dr()}return this.Cr(n,i)}}class UR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){if(e.yr()&&t.yr())return F.newValue(os);if(e.yr()||t.yr()||us(e.value)||us(t.value)||gn(e.value)!==gn(t.value))return F.newValue(An);switch(ba(e.value,t.value)){case"EQ":return F.newValue(os);case"NOT_EQ":return F.newValue(An);case"NULL":return F.pr();default:Te(44615,{left:e,right:t})}}}class zR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){switch(ba(e.value,t.value)){case"EQ":return F.newValue(An);case"NOT_EQ":case"TYPE_MISMATCH":return F.newValue(os);case"NULL":return F.pr();default:Te(44614,{left:e,right:t})}}}class qR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){return gn(e.value)!==gn(t.value)||us(e.value)||us(t.value)?F.newValue(An):F.newValue({booleanValue:Hn(e.value,t.value)<0})}}class KR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){return gn(e.value)!==gn(t.value)||us(e.value)||us(t.value)?F.newValue(An):ba(e.value,t.value)==="EQ"?F.newValue(os):F.newValue({booleanValue:Hn(e.value,t.value)<0})}}class JR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){return gn(e.value)!==gn(t.value)||us(e.value)||us(t.value)?F.newValue(An):F.newValue({booleanValue:Hn(e.value,t.value)>0})}}class QR extends Iu{constructor(e){super(e),this.expr=e}Cr(e,t){return gn(e.value)!==gn(t.value)||us(e.value)||us(t.value)?F.newValue(An):ba(e.value,t.value)==="EQ"?F.newValue(os):F.newValue({booleanValue:Hn(e.value,t.value)>0})}}class YR{constructor(e){this.expr=e}evaluate(e,t){throw new Error("Unimplemented")}}class XR{constructor(e){this.expr=e}evaluate(e,t){var i;fe(this.expr.params.length===1,216);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"NULL":return F.pr();case"ARRAY":{const o=((i=n.value.arrayValue)==null?void 0:i.values)??[];return F.newValue({arrayValue:{values:[...o].reverse()}})}default:return F.dr()}}}class $R{constructor(e){this.expr=e}evaluate(e,t){return fe(this.expr.params.length===2,52884),new tv(new se("eq_any",[this.expr.params[1],this.expr.params[0]])).evaluate(e,t)}}class ZR{constructor(e){this.expr=e}evaluate(e,t){var f,g,y,b;fe(this.expr.params.length===2,1392);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"ARRAY":break;case"NULL":n=!0;break;default:return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);switch(o.type){case"ARRAY":break;case"NULL":n=!0;break;default:return F.dr()}if(n)return F.pr();const u=((g=(f=o.value)==null?void 0:f.arrayValue)==null?void 0:g.values)??[],B=((b=(y=i.value)==null?void 0:y.arrayValue)==null?void 0:b.values)??[];for(const D of u){let T=!1;n=!1;for(const M of B){switch(_s(D)&&_s(M)?"EQ":ba(D,M)){case"EQ":T=!0;break;case"NOT_EQ":case"TYPE_MISMATCH":break;case"NULL":n=!0;break;default:Te(44613,{value:M,search:D})}if(T)break}if(!T)return F.newValue(An)}return F.newValue(os)}}class WR{constructor(e){this.expr=e}evaluate(e,t){var f,g,y,b;fe(this.expr.params.length===2,2680);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"ARRAY":break;case"NULL":n=!0;break;default:return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);switch(o.type){case"ARRAY":break;case"NULL":n=!0;break;default:return F.dr()}if(n)return F.pr();const u=((g=(f=o.value)==null?void 0:f.arrayValue)==null?void 0:g.values)??[],B=((b=(y=i.value)==null?void 0:y.arrayValue)==null?void 0:b.values)??[];for(const D of B)for(const T of u)switch(_s(D)&&_s(T)?"EQ":ba(D,T)){case"EQ":return F.newValue(os);case"NOT_EQ":case"TYPE_MISMATCH":break;case"NULL":n=!0;break;default:Te(60403,{value:D,search:T})}
1889return n?F.pr():F.newValue(An)}}class eO{constructor(e){this.expr=e}evaluate(e,t){var i,o,u;fe(this.expr.params.length===1,38605);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"NULL":return F.pr();case"ARRAY":return F.newValue({integerValue:`${((u=(o=(i=n.value)==null?void 0:i.arrayValue)==null?void 0:o.values)==null?void 0:u.length)??0}`});default:return F.dr()}}}class tO{constructor(e){this.expr=e}evaluate(e,t){throw new Error("Unimplemented")}}class nO{constructor(e){this.expr=e}evaluate(e,t){var i,o;fe(this.expr.params.length===1,1508);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"NULL":return F.pr();case"BYTES":{const u=(i=n.value)==null?void 0:i.bytesValue;if(typeof u=="string"){const B=qt.fromBase64String(u).toUint8Array();return B.reverse(),F.newValue({bytesValue:qt.fromUint8Array(B).toBase64()})}return F.newValue({bytesValue:new Uint8Array(u).reverse()})}case"STRING":{const u=(o=n.value)==null?void 0:o.stringValue,B=new Intl.__PRIVATE_Segmenter(void 0,{granularity:"grapheme"}).segment(u),f=Array.from(B,(g=>g.segment)).reverse();return F.newValue({stringValue:f.join("")})}default:return F.dr()}}}class sO{constructor(e){this.expr=e}evaluate(e,t){throw new Error("Unimplemented")}}class rO{constructor(e){this.expr=e}evaluate(e,t){throw new Error("Unimplemented")}}class aO{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===1,19400);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"NULL":return F.pr();case"STRING":{const i=(function(u){let B=0;for(let f=0;f<u.length;f++){const g=u.codePointAt(f);if(g===void 0)return;if(g<=65535)if(g>=55296&&g<=57343)if(g<=56319){const y=u.codePointAt(f+1);y!==void 0&&y>=56320&&y<=57343?(B+=1,f++):B+=1}else B+=1;else B+=1;else{if(!(g<=1114111))return;B+=1,f++}}return B})(n.value.stringValue);return i===void 0?F.dr():F.newValue({integerValue:i})}default:return F.dr()}}}class iO{constructor(e){this.expr=e}evaluate(e,t){var i,o;fe(this.expr.params.length===1,8486);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"BYTES":{const u=(i=n.value)==null?void 0:i.bytesValue;return typeof u=="string"?F.newValue({integerValue:qt.fromBase64String(u).toUint8Array().length}):F.newValue({integerValue:new Uint8Array(u).length})}case"STRING":{const u=(function(f){let g=0;for(let y=0;y<f.length;y++){const b=f.codePointAt(y);if(b===void 0)return;if(b>=55296&&b<=57343){if(!(b<=56319))return;{const D=f.codePointAt(y+1);if(D===void 0||!(D>=56320&&D<=57343))return;g+=4,y++}}else if(b<=127)g+=1;else if(b<=2047)g+=2;else if(b<=65535)g+=3;else{if(!(b<=1114111))return;g+=4,y++}}return g})((o=n.value)==null?void 0:o.stringValue);return u===void 0?F.dr():F.newValue({integerValue:u})}case"NULL":return F.pr();default:return F.dr()}}}class Su{constructor(e){this.expr=e}evaluate(e,t){var u,B;fe(this.expr.params.length===2,39773,`${this.expr.name}() function should have exactly two parameters`);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"STRING":break;case"NULL":n=!0;break;default:return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);switch(o.type){case"STRING":break;case"NULL":n=!0;break;default:return F.dr()}return n?F.pr():this.Fr((u=i.value)==null?void 0:u.stringValue,(B=o.value)==null?void 0:B.stringValue)}}class lO extends Su{Fr(e,t){try{const n=(function(u){let B="";for(let f=0;f<u.length;f++){const g=u.charAt(f);switch(g){case"_":B+=".";break;case"%":B+=".*";break;case"\\":case".":case"*":case"?":case"+":case"^":case"$":case"|":case"(":case")":case"[":case"]":case"{":case"}":B+="\\"+g;break;default:B+=g}}return"^"+B+"$"})(t),i=uC.compile(n);return F.newValue({booleanValue:i.matches(e)})}catch(n){return lr(`Invalid LIKE pattern converted to regex: ${t}, returning error. Error: ${n}`),F.dr()}}}class oO extends Su{Fr(e,t){try{const n=uC.compile(t);return F.newValue({booleanValue:n.test(e)})}catch{return lr(`Invalid regex pattern found in regex_contains: ${t}, returning error`),F.dr()}}}class uO extends Su{Fr(e,t){try{return F.newValue({booleanValue:uC.compile(t).matches(e)})}catch{return lr(`Invalid regex pattern found in regex_match: ${t}, returning error`),F.dr()}}}class cO extends Su{Fr(e,t){return F.newValue({booleanValue:e.includes(t)})}}class BO extends Su{Fr(e,t){return F.newValue({booleanValue:e.startsWith(t)})}}class hO extends Su{Fr(e,t){return F.newValue({booleanValue:e.endsWith(t)})}}class dO{constructor(e){this.expr=e}evaluate(e,t){var i,o;fe(this.expr.params.length===1,29079);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"STRING":return F.newValue({stringValue:(o=(i=n.value)==null?void 0:i.stringValue)==null?void 0:o.toLowerCase()});case"NULL":return F.pr();default:return F.dr()}}}class fO{constructor(e){this.expr=e}evaluate(e,t){var i,o;fe(this.expr.params.length===1,60487);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"STRING":return F.newValue({stringValue:(o=(i=n.value)==null?void 0:i.stringValue)==null?void 0:o.toUpperCase()});case"NULL":return F.pr();default:return F.dr()}}}class mO{constructor(e){this.expr=e}evaluate(e,t){var i,o;fe(this.expr.params.length===1,28544);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"STRING":return F.newValue({stringValue:(o=(i=n.value)==null?void 0:i.stringValue)==null?void 0:o.trim()});case"NULL":return F.pr();default:return F.dr()}}}class pO{constructor(e){this.expr=e}evaluate(e,t){const n=this.expr.params.map((u=>Fe(u).evaluate(e,t)));let i="",o=!1;for(const u of n)switch(u.type){case"STRING":i+=u.value.stringValue;break;case"NULL":o=!0;break;default:return F.dr()}return o?F.pr():F.newValue({stringValue:i})}}class gO{constructor(e){this.expr=e}evaluate(e,t){var u,B,f,g;fe(this.expr.params.length===2,4483);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"UNSET":return F.mr();case"MAP":break;default:return F.dr()}const i=Fe(this.expr.params[1]).evaluate(e,t);if(i.type!=="STRING")return F.dr();const o=(g=(B=(u=n.value)==null?void 0:u.mapValue)==null?void 0:B.fields)==null?void 0:g[(f=i.value)==null?void 0:f.stringValue];return o===void 0?F.mr():F.newValue(o)}}class jC{constructor(e){this.expr=e}evaluate(e,t){var g,y;fe(this.expr.params.length===2,25231,`${this.expr.name}() function should have exactly 2 params`);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"VECTOR":break;case"NULL":n=!0;break;default:return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);switch(o.type){case"VECTOR":break;case"NULL":n=!0;break;default:return F.dr()}if(n)return F.pr();const u=Ag(i.value),B=Ag(o.value);if(u===void 0||B===void 0||((g=u.values)==null?void 0:g.length)!==((y=B.values)==null?void 0:y.length))return F.dr();const f=this.Or(u,B);
1889return f===void 0||isNaN(f)?F.dr():F.newValue({doubleValue:f})}}class CO extends jC{Or(e,t){const n=(e==null?void 0:e.values)??[],i=(t==null?void 0:t.values)??[];if(n.length===0)return;let o=0,u=0,B=0;for(let g=0;g<n.length;g++){if(!Ei(n[g])||!Ei(i[g]))return;const y=jn(n[g]),b=jn(i[g]);o+=y*b,u+=y*y,B+=b*b}const f=Math.sqrt(u)*Math.sqrt(B);if(f!==0)return 1-Math.max(-1,Math.min(1,o/f))}}class yO extends jC{Or(e,t){const n=(e==null?void 0:e.values)??[],i=(t==null?void 0:t.values)??[];if(n.length===0)return 0;let o=0;for(let u=0;u<n.length;u++){if(!Ei(n[u])||!Ei(i[u]))return;o+=jn(n[u])*jn(i[u])}return o}}class bO extends jC{Or(e,t){const n=(e==null?void 0:e.values)??[],i=(t==null?void 0:t.values)??[];if(n.length===0)return 0;let o=0;for(let u=0;u<n.length;u++){if(!Ei(n[u])||!Ei(i[u]))return;const B=jn(n[u]),f=jn(i[u]);o+=Math.pow(B-f,2)}return Math.sqrt(o)}}class xO{constructor(e){this.expr=e}evaluate(e,t){var i;fe(this.expr.params.length===1,39044);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"VECTOR":{const o=Ag(n.value);return F.newValue({integerValue:((i=o==null?void 0:o.values)==null?void 0:i.length)??0})}case"NULL":return F.pr();default:return F.dr()}}}const bB=BigInt(-62135596800),xB=BigInt(253402300799),Zd=BigInt(1e3),bi=BigInt(1e6),EO=bB*Zd,_O=xB*Zd+BigInt(999),DO=bB*bi,vO=xB*bi+BigInt(999999);function MC(r){return r>=DO&&r<=vO}function nv(r){return r>=bB&&r<=xB}function EB(r,e){const t=BigInt(r);return!(t<bB||t>xB)&&!(e<0||e>=1e9)&&(t!==bB||e===0)&&!(t===xB&&e>999999999)}function sv(r,e){return e<0?{seconds:r-1,nanos:e+1e9}:{seconds:r,nanos:e}}function PC(r){return BigInt(r.seconds)*bi+BigInt(Math.trunc(r.nanoseconds/1e3))}class VC{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===1,49262,`${this.expr.name}() function should have exactly one parameter`);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"INT":return this.toTimestamp(BigInt(n.value.integerValue));case"NULL":return F.pr();default:return F.dr()}}}class wO extends VC{toTimestamp(e){if(!MC(e))return F.dr();let t=Number(e/bi),n=Number(e%bi*BigInt(1e3));const i=sv(t,n);return t=i.seconds,n=i.nanos,EB(t,n)?F.newValue({timestampValue:{seconds:t,nanos:n}}):F.dr()}}class TO extends VC{toTimestamp(e){if(!(function(u){return u>=EO&&u<=_O})(e))return F.dr();let t=Number(e/Zd),n=Number(e%Zd*BigInt(1e6));const i=sv(t,n);return t=i.seconds,n=i.nanos,EB(t,n)?F.newValue({timestampValue:{seconds:t,nanos:n}}):F.dr()}}class AO extends VC{toTimestamp(e){if(!nv(e))return F.dr();const t=Number(e);return F.newValue({timestampValue:{seconds:t,nanos:0}})}}class FC{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===1,1265,`${this.expr.name}() function should have exactly one parameter`);const n=Fe(this.expr.params[0]).evaluate(e,t);switch(n.type){case"TIMESTAMP":break;case"NULL":return F.pr();default:return F.dr()}const i=TC(n.value.timestampValue);return EB(i.seconds,i.nanoseconds)?this.Mr(i):F.dr()}}class NO extends FC{Mr(e){const t=PC(e);return MC(t)?F.newValue({integerValue:`${t.toString()}`}):F.dr()}}class IO extends FC{Mr(e){const t=PC(e),n=t/BigInt(1e3),i=t%BigInt(1e3);return n>BigInt(0)||i===BigInt(0)?F.newValue({integerValue:n.toString()}):F.newValue({integerValue:(n-BigInt(1)).toString()})}}class SO extends FC{Mr(e){const t=BigInt(e.seconds);return nv(t)?F.newValue({integerValue:t.toString()}):F.dr()}}class rv{constructor(e){this.expr=e}evaluate(e,t){fe(this.expr.params.length===3,2775,`${this.expr.name}() function should have exactly 3 parameters`);let n=!1;const i=Fe(this.expr.params[0]).evaluate(e,t);switch(i.type){case"TIMESTAMP":break;case"NULL":n=!0;break;default:return F.dr()}const o=Fe(this.expr.params[1]).evaluate(e,t);let u;switch(o.type){case"STRING":if(u=(function(he){switch(he){case"microsecond":return"microsecond";case"millisecond":return"millisecond";case"second":return"second";case"minute":return"minute";case"hour":return"hour";case"day":return"day";default:return}})(o.value.stringValue),u===void 0)return F.dr();break;case"NULL":n=!0;break;default:return F.dr()}const B=Fe(this.expr.params[2]).evaluate(e,t);switch(B.type){case"INT":break;case"NULL":n=!0;break;default:return F.dr()}if(n)return F.pr();const f=BigInt(B.value.integerValue);let g;try{switch(u){case"microsecond":g=f;break;case"millisecond":g=f*BigInt(1e3);break;case"second":g=f*BigInt(1e6);break;case"minute":g=f*BigInt(6e7);break;case"hour":g=f*BigInt(36e8);break;case"day":g=f*BigInt(864e8);break;default:return F.dr()}if(u!=="microsecond"&&f!==BigInt(0)&&g/f!==BigInt(this.Nr(u)))return F.dr()}catch(K){return lr(`Error during timestamp arithmetic: ${K}`),F.dr()}const y=TC(i.value.timestampValue);if(!EB(y.seconds,y.nanoseconds))return F.dr();const b=PC(y),D=this.Lr(b,g);if(!MC(D))return F.dr();const T=Number(D/bi),M=D%bi,z=Number((M<0?M+bi:M)*BigInt(1e3)),W=M<0?T-1:T;return EB(W,z)?F.newValue({timestampValue:{seconds:W,nanos:z}}):F.dr()}Nr(e){switch(e){case"millisecond":return 1e3;case"second":return 1e6;case"minute":return 6e7;case"hour":return 36e8;case"day":return 864e8;default:return 1}}}class RO extends rv{Lr(e,t){return e+t}}class OO extends rv{Lr(e,t){return e-t}}// Copyright 2024 Google LLC* @license
vendor: 9,280 bytes, lines 1890-1954
1890class Jn{constructor(e,t,n){this.serializer=e,this.stages=t,this.listenOptions=n,this.isCorePipeline=!0}getPipelineCollection(){return FB(this)}getPipelineCollectionGroup(){return GC(this)}getPipelineCollectionId(){return av(this)}getPipelineDocuments(){return Wd(this)}getPipelineFlavor(){return(function(t){let n="exact";return t.stages.forEach(((i,o)=>{i._name!==WD.name&&i._name!==ZD.name||(n="keyless"),i._name===bR.name&&n==="exact"&&(n="augmented"),i._name===$D.name&&o<t.stages.length-1&&n==="exact"&&(n="augmented")})),n})(this)}getPipelineSourceType(){return ma(this)}}function ma(r){const e=r.stages[0];return e instanceof MB||e instanceof PB||e instanceof wf||e instanceof Tf?e._name:"unknown"}function FB(r){if(ma(r)==="collection")return r.stages[0].Er}function GC(r){if(ma(r)==="collection_group")return r.stages[0].collectionId}function av(r){switch(ma(r)){case"collection":return ct.fromString(FB(r)).lastSegment();case"collection_group":return GC(r);default:return}}function Wd(r){if(ma(r)==="documents")return r.stages[0].hr}function _B(r){if((r=ev(r))instanceof Nu)return`fld(${r.fieldName})`;if(r instanceof Gl)return`cst(${(function(t){return t===null?"null":typeof t=="number"?t.toString():typeof t=="string"?`"${t}"`:t instanceof rn?`ref(${t.path})`:t instanceof ls?`vec(${JSON.stringify(t)})`:JSON.stringify(t)})(r.value)})`;if(r instanceof se)return`fn(${r.name},[${r.params.map(_B).join(",")}])`;if(r.expressionType==="ListOfExpressions")return`list([${r.ur.map(_B).join(",")}])`;throw new Error(`Unrecognized expr ${JSON.stringify(r,null,2)}`)}function kO(r){if(r instanceof $D)return`${r._name}(${xd(r.fields)})`;if(r instanceof ZD){let e=`${r._name}(${xd(r.accumulators)})`;return r.groups.size>0&&(e+=`grouping(${xd(r.groups)})`),e}if(r instanceof WD)return`${r._name}(${xd(r.groups)})`;if(r instanceof MB)return`${r._name}(${r.Er})`;if(r instanceof PB)return`${r._name}(${r.collectionId})`;if(r instanceof wf)return`${r._name}()`;if(r instanceof Tf)return`${r._name}(${r.hr.sort()})`;if(r instanceof Af)return`${r._name}(${_B(r.condition)})`;if(r instanceof fu)return`${r._name}(${r.limit})`;if(r instanceof Nf)return`${r._name}(${(function(t){return t.map((n=>`${_B(n.expr)}${n.direction}`)).join(",")})(r.orderings)})`;throw new Error(`Unrecognized stage ${r._name}`)}function xd(r){return`${Array.from(r.entries()).sort().map((([e,t])=>`${e}=${_B(t)}`)).join(",")}`}function pa(r){return r.stages.map((e=>kO(e))).join("|")}function iv(r,e){return pa(r)===pa(e)}function Wt(r){return r instanceof Jn}function g_(r){return Wt(r)?pa(r):Zc(r)}function lv(r){return Wt(r)?pa(r):(function(t){return`${Qd(ws(t))}|lt:${t.limitType}`})(r)}function Sf(r,e){return r instanceof Jn&&e instanceof Jn?iv(r,e):!(r instanceof Jn&&!(e instanceof Jn)||!(r instanceof Jn)&&e instanceof Jn)&&lS(r,e)}function Rf(r){return Ba(r)?pa(r):Qd(r)}function HC(r,e){return r instanceof Jn&&e instanceof Jn?iv(r,e):!(r instanceof Jn&&!(e instanceof Jn)||!(r instanceof Jn)&&e instanceof Jn)&&EC(r,e)}/**
1891 * @license
1892 * Copyright 2017 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 */class UC{constructor(e,t,n,i){this.batchId=e,this.localWriteTime=t,this.baseMutations=n,this.mutations=i}applyToRemoteDocument(e,t){const n=t.mutationResults;for(let i=0;i<this.mutations.length;i++){const o=this.mutations[i];o.key.isEqual(e.key)&&QI(o,e,n[i])}}applyToLocalView(e,t){for(const n of this.baseMutations)n.key.isEqual(e.key)&&(t=Xc(n,e,t,this.localWriteTime));for(const n of this.mutations)n.key.isEqual(e.key)&&(t=Xc(n,e,t,this.localWriteTime));return t}applyToLocalDocumentSet(e,t){const n=mD();return this.mutations.forEach((i=>{const o=e.get(i.key),u=o.overlayedDocument;let B=this.applyToLocalView(u,o.mutatedFields);B=t.has(i.key)?null:B;const f=W1(u,B);f!==null&&n.set(i.key,f),u.isValidDocument()||u.convertToNoDocument(Me.min())})),n}keys(){return this.mutations.reduce(((e,t)=>e.add(t.key)),Xe())}isEqual(e){return this.batchId===e.batchId&&nu(this.mutations,e.mutations,((t,n)=>KE(t,n)))&&nu(this.baseMutations,e.baseMutations,((t,n)=>KE(t,n)))}}class zC{constructor(e,t,n,i){this.batch=e,this.commitVersion=t,this.mutationResults=n,this.docVersions=i}static from(e,t,n){fe(e.mutations.length===n.length,58842,{Br:e.mutations.length,Ur:n.length});let i=(function(){return hS})();const o=e.mutations;for(let u=0;u<o.length;u++)i=i.insert(o[u].key,n[u].version);return new zC(e,t,n,i)}}/**
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 */const ef="�";function Gn(r){let e="";for(let t=0;t<r.length;t++)e.length>0&&(e=C_(e)),e=LO(r.get(t),e);return C_(e)}function LO(r,e){let t=e;const n=r.length;for(let i=0;i<n;i++){const o=r.charAt(i);switch(o){case"\0":t+="��";break;case ef:t+="��";break;default:t+=o}}return t}function C_(r){return r+ef+"�"}function Or(r){const e=r.length;if(fe(e>=2,64408,{path:r}),e===2)return fe(r.charAt(0)===ef&&r.charAt(1)==="�",56145,{path:r}),ct.emptyPath();const t=e-2,n=[];let i="";for(let o=0;o<e;){const u=r.indexOf(ef,o);switch((u<0||u>t)&&Te(50515,{path:r}),r.charAt(u+1)){case"�":const B=r.substring(o,u);let f;i.length===0?f=B:(i+=B,f=i,i=""),n.push(f);break;case"�":i+=r.substring(o,u),i+="\0";break;case"�":i+=r.substring(o,u+1);break;default:Te(61167,{path:r})}o=u+2}return new ct(n)}/**
1921 * @license
1922 * Copyright 2022 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 cl="remoteDocuments",GB="owner",Lo="owner",DB="mutationQueues",jO="userId",ir="mutations",y_="batchId",Cl="userMutationsIndex",b_=["userId","batchId"];/**
1936 * @license
1937 * Copyright 2022 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 */function Ld(r,e){return[r,Gn(e)]}function ov(r,e,t){return[r,Gn(e),t]}const MO={},mu="documentMutations",tf="remoteDocumentsV14",PO=["prefixPath","collectionGroup","readTime","documentId"],jd="documentKeyIndex",VO=["prefixPath","collectionGroup","documentId"],uv="collectionGroupIndex",FO=["collectionGroup","readTime","prefixPath","documentId"],vB="remoteDocumentGlobal",Vg="remoteDocumentGlobalKey",pu="targets",cv="queryTargetsIndex",GO=["canonicalId","targetId"],gu="targetDocuments",HO=["targetId","path"],qC="documentTargetsIndex",UO=["path","targetId"],nf="targetGlobalKey",Dl="targetGlobal",wB="collectionParents",zO=["collectionId","parent"],Cu="clientMetadata",qO="clientId",Of="bundles",KO="bundleId",kf="namedQueries",JO="name",KC="indexConfiguration",QO="indexId",Fg="collectionGroupIndex",YO="collectionGroup",nB="indexState",XO=["indexId","uid"],Bv="sequenceNumberIndex",$O=["uid","sequenceNumber"],sB="indexEntries",ZO=["indexId","uid","arrayValue","directionalValue","orderedDocumentKey","documentKey"],hv="documentKeyIndex",WO=["indexId","uid","orderedDocumentKey"],Lf="documentOverlays",ek=["userId","collectionPath","documentId"],Gg="collectionPathOverlayIndex",tk=["userId","collectionPath","largestBatchId"],dv="collectionGroupOverlayIndex",nk=["userId","collectionGroup","largestBatchId"],JC="globals",sk="name",fv=[DB,ir,mu,cl,pu,GB,Dl,gu,Cu,vB,wB,Of,kf],rk=[...fv,Lf],mv=[DB,ir,mu,tf,pu,GB,Dl,gu,Cu,vB,wB,Of,kf,Lf],pv=mv,QC=[...pv,KC,nB,sB],ak=QC,gv=[...QC,JC],ik=gv;/**
1951 * @license
1952 * Copyright 2020 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 */function Cv(r,e,t){const n=r.store(ir),i=r.store(mu),o=[],u=IDBKeyRange.only(t.batchId);let B=0;const f=n.jn({range:u},((y,b,D)=>(B++,D.delete())));o.push(f.next((()=>{fe(B===1,47070,{batchId:t.batchId})})));const g=[];for(const y of t.mutations){const b=ov(e,y.key.path,t.batchId);o.push(i.delete(b)),g.push(y.key)}return U.waitFor(o).next((()=>g))}function sf(r){if(!r)return 0;let e;if(r.document)e=r.document;else if(r.unknownDocument)e=r.unknownDocument;else{if(!r.noDocument)throw Te(14731);e=r.noDocument}return JSON.stringify(e).length}/**
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 */class Hg extends PD{constructor(e,t){super(),this.kr=e,this.currentSequenceNumber=t}}function xn(r,e){const t=Se(r);return yi.xn(t.kr,e)}/**
1981 * @license
1982 * Copyright 2022 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 YC{constructor(e,t){this.largestBatchId=e,this.mutation=t}getKey(){return this.mutation.key}isEqual(e){return e!==null&&this.mutation===e.mutation}toString(){return`Overlay{
1996      largestBatchId: ${this.largestBatchId},
1997      mutation: ${this.mutation.toString()}
1998    }`}}/**
1999 * @license
2000 * Copyright 2017 Google LLC
2001 *
2002 * Licensed under the Apache License, Version 2.0 (the "License");
2003 * you may not use this file except in compliance with the License.
2004 * You may obtain a copy of the License at
2005 *
2006 *   http://www.apache.org/licenses/LICENSE-2.0
2007 *
2008 * Unless required by applicable law or agreed to in writing, software
2009 * distributed under the License is distributed on an "AS IS" BASIS,
2010 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2011 * See the License for the specific language governing permissions and
2012 * limitations under the License.
2013 */class kr{constructor(e,t,n,i,o=Me.min(),u=Me.min(),B=qt.EMPTY_BYTE_STRING,f=null){this.target=e,this.targetId=t,this.purpose=n,this.sequenceNumber=i,this.snapshotVersion=o,this.lastLimboFreeSnapshotVersion=u,this.resumeToken=B,this.expectedCount=f}withSequenceNumber(e){return new kr(this.target,this.targetId,this.purpose,e,this.snapshotVersion,this.lastLimboFreeSnapshotVersion,this.resumeToken,this.expectedCount)}withResumeToken(e,t){return new kr(this.target,this.targetId,this.purpose,this.sequenceNumber,t,this.lastLimboFreeSnapshotVersion,e,null)}withExpectedCount(e){return new kr(this.target,this.targetId,this.purpose,this.sequenceNumber,this.snapshotVersion,this.lastLimboFreeSnapshotVersion,this.resumeToken,e)}withLastLimboFreeSnapshotVersion(e){return new kr(this.target,this.targetId,this.purpose,this.sequenceNumber,this.snapshotVersion,e,this.resumeToken,this.expectedCount)}}/**
2014 * @license
2015 * Copyright 2017 Google LLC
2016 *
2017 * Licensed under the Apache License, Version 2.0 (the "License");
2018 * you may not use this file except in compliance with the License.
2019 * You may obtain a copy of the License at
2020 *
2021 *   http://www.apache.org/licenses/LICENSE-2.0
2022 *
2023 * Unless required by applicable law or agreed to in writing, software
2024 * distributed under the License is distributed on an "AS IS" BASIS,
2025 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2026 * See the License for the specific language governing permissions and
2027 * limitations under the License.
2028 */class yv{constructor(e){this.qr=e}}function lk(r,e){let t;if(e.document)t=ES(r.qr,e.document,!!e.hasCommittedMutations);else if(e.noDocument){const n=De.fromSegments(e.noDocument.path),i=Ml(e.noDocument.readTime);t=Zt.newNoDocument(n,i),e.hasCommittedMutations&&t.setHasCommittedMutations()}else{if(!e.unknownDocument)return Te(56709);{const n=De.fromSegments(e.unknownDocument.path),i=Ml(e.unknownDocument.version);t=Zt.newUnknownDocument(n,i)}}return e.readTime&&t.setReadTime((function(i){const o=new xt(i[0],i[1]);return Me.fromTimestamp(o)})(e.readTime)),t}function x_(r,e){const t=e.key,n={prefixPath:t.getCollectionPath().popLast().toArray(),collectionGroup:t.collectionGroup,documentId:t.path.lastSegment(),readTime:rf(e.readTime),hasCommittedMutations:e.hasCommittedMutations};if(e.isFoundDocument())n.document=(function(o,u){return{name:mB(o,u.key),fields:u.data.value.mapValue.fields,updateTime:du(o,u.version.toTimestamp()),createTime:du(o,u.createTime.toTimestamp())}})(r.qr,e);else if(e.isNoDocument())n.noDocument={path:t.path.toArray(),readTime:jl(e.version)};else{if(!e.isUnknownDocument())return Te(57904,{document:e});n.unknownDocument={path:t.path.toArray(),version:jl(e.version)}}return n}function rf(r){const e=r.toTimestamp();return[e.seconds,e.nanoseconds]}function jl(r){const e=r.toTimestamp();return{seconds:e.seconds,nanoseconds:e.nanoseconds}}function Ml(r){const e=new xt(r.seconds,r.nanoseconds);return Me.fromTimestamp(e)}function dl(r,e){const t=(e.baseMutations||[]).map((o=>Mg(r.qr,o)));for(let o=0;o<e.mutations.length-1;++o){const u=e.mutations[o];if(o+1<e.mutations.length&&e.mutations[o+1].transform!==void 0){const B=e.mutations[o+1];u.updateTransforms=B.transform.fieldTransforms,e.mutations.splice(o+1,1),++o}}const n=e.mutations.map((o=>Mg(r.qr,o))),i=xt.fromMillis(e.localWriteTimeMs);return new UC(e.batchId,i,t,n)}function Kc(r,e){const t=Ml(e.readTime),n=e.lastLimboFreeSnapshotVersion!==void 0?Ml(e.lastLimboFreeSnapshotVersion):Me.min();let i;return i=(function(u){return u.structuredPipeline!==void 0})(e.query)?(function(u,B){var y,b;const f=u.structuredPipeline;fe((((y=f==null?void 0:f.pipeline)==null?void 0:y.stages)??[]).length>0,1845);const g=(b=f==null?void 0:f.pipeline)==null?void 0:b.stages.map(ok);return new Jn(B,g)})(e.query,r.qr):(function(u){return u.documents!==void 0})(e.query)?(function(u){const B=u.documents.length;return fe(B===1,1966,{count:B}),ws(kB(xD(u.documents[0])))})(e.query):(function(u){return ws(vD(u))})(e.query),new kr(i,e.targetId,"TargetPurposeListen",e.lastListenSequenceNumber,t,n,qt.fromBase64String(e.resumeToken))}function bv(r,e){const t=jl(e.snapshotVersion),n=jl(e.lastLimboFreeSnapshotVersion);let i;i=Ba(e.target)?wD(r.qr,e.target):_C(e.target)?_D(r.qr,e.target):DD(r.qr,e.target).be;const o=e.resumeToken.toBase64();return{targetId:e.targetId,canonicalId:Rf(e.target),readTime:t,resumeToken:o,lastListenSequenceNumber:e.sequenceNumber,lastLimboFreeSnapshotVersion:n,query:i}}function xv(r){const e=vD({parent:r.parent,structuredQuery:r.structuredQuery});return r.limitType==="LAST"?Og(e,e.limit,"L"):e}function Ed(r,e){return new YC(e.largestBatchId,Mg(r.qr,e.overlayMutation))}function E_(r,e){const t=e.path.lastSegment();return[r,Gn(e.path.popLast()),t]}function __(r,e,t,n){return{indexId:r,uid:e,sequenceNumber:t,readTime:jl(n.readTime),documentKey:Gn(n.documentKey.path),largestBatchId:n.largestBatchId}}function ok(r){switch(r.name){case"collection":return new MB(r.args[0].referenceValue,{});case"collection_group":return new PB(r.args[1].stringValue,{});case"database":return new wf({});case"documents":return new Tf(r.args.map((e=>e.referenceValue)),{});case"where":return new Af(Ug(r.args[0]),{});case"limit":{const e=r.args[0].integerValue??r.args[0].doubleValue;return new fu(typeof e=="number"?e:Number(e),{})}case"sort":return new Nf(r.args.map((e=>(function(n){var o,u;const i=(o=n.mapValue)==null?void 0:o.fields;return new OC(Ug(i.expression),(u=i.direction)==null?void 0:u.stringValue,"orderingFromProto")})(e))),{});default:throw new Error(`Stage type: ${r.name} not supported.`)}}function Ug(r){return r.fieldReferenceValue?new Nu(jB("_exprFromProto",r.fieldReferenceValue),"_exprFromProto"):r.functionValue?(function(t){var n;return new se(t.functionValue.name,((n=t.functionValue.args)==null?void 0:n.map(Ug))||[])})(r):Gl._fromProto(r)}
vendor: 4,568 bytes, lines 2028-2032
2028class jf{constructor(e,t,n,i){this.userId=e,this.serializer=t,this.indexManager=n,this.referenceDelegate=i,this.$r={}}static Kr(e,t,n,i){fe(e.uid!=="",64387);const o=e.isAuthenticated()?e.uid:"";return new jf(o,t,n,i)}checkEmpty(e){let t=!0;const n=IDBKeyRange.bound([this.userId,Number.NEGATIVE_INFINITY],[this.userId,Number.POSITIVE_INFINITY]);return ii(e).jn({index:Cl,range:n},((i,o,u)=>{t=!1,u.done()})).next((()=>t))}addMutationBatch(e,t,n,i){const o=Jo(e),u=ii(e);return u.add({}).next((B=>{fe(typeof B=="number",49019);const f=new UC(B,t,n,i),g=(function(T,M,z){const W=z.baseMutations.map((he=>Xd(T.qr,he))),K=z.mutations.map((he=>Xd(T.qr,he)));return{userId:M,batchId:z.batchId,localWriteTimeMs:z.localWriteTime.toMillis(),baseMutations:W,mutations:K}})(this.serializer,this.userId,f),y=[];let b=new gt(((D,T)=>Ue(D.canonicalString(),T.canonicalString())));for(const D of i){const T=ov(this.userId,D.key.path,B);b=b.add(D.key.path.popLast()),y.push(u.put(g)),y.push(o.put(T,MO))}return b.forEach((D=>{y.push(this.indexManager.addToCollectionParentIndex(e,D))})),e.addOnCommittedListener((()=>{this.$r[B]=f.keys()})),U.waitFor(y).next((()=>f))}))}lookupMutationBatch(e,t){return ii(e).get(t).next((n=>n?(fe(n.userId===this.userId,48,"Unexpected user for mutation batch",{userId:n.userId,batchId:t}),dl(this.serializer,n)):null))}Wr(e,t){return this.$r[t]?U.resolve(this.$r[t]):this.lookupMutationBatch(e,t).next((n=>{if(n){const i=n.keys();return this.$r[t]=i,i}return null}))}getNextMutationBatchAfterBatchId(e,t){const n=t+1,i=IDBKeyRange.lowerBound([this.userId,n]);let o=null;return ii(e).jn({index:Cl,range:i},((u,B,f)=>{B.userId===this.userId&&(fe(B.batchId>=n,47524,{Qr:n}),o=dl(this.serializer,B)),f.done()})).next((()=>o))}getHighestUnacknowledgedBatchId(e){const t=IDBKeyRange.upperBound([this.userId,Number.POSITIVE_INFINITY]);let n=xl;return ii(e).jn({index:Cl,range:t,reverse:!0},((i,o,u)=>{n=o.batchId,u.done()})).next((()=>n))}getAllMutationBatches(e){const t=IDBKeyRange.bound([this.userId,xl],[this.userId,Number.POSITIVE_INFINITY]);return ii(e).Kn(Cl,t).next((n=>n.map((i=>dl(this.serializer,i)))))}getAllMutationBatchesAffectingDocumentKey(e,t){const n=Ld(this.userId,t.path),i=IDBKeyRange.lowerBound(n),o=[];return Jo(e).jn({range:i},((u,B,f)=>{const[g,y,b]=u,D=Or(y);if(g===this.userId&&t.path.isEqual(D))return ii(e).get(b).next((T=>{if(!T)throw Te(61480,{Gr:u,batchId:b});fe(T.userId===this.userId,10503,"Unexpected user for mutation batch",{userId:T.userId,batchId:b}),o.push(dl(this.serializer,T))}));f.done()})).next((()=>o))}getAllMutationBatchesAffectingDocumentKeys(e,t){let n=new gt(Ue);const i=[];return t.forEach((o=>{const u=Ld(this.userId,o.path),B=IDBKeyRange.lowerBound(u),f=Jo(e).jn({range:B},((g,y,b)=>{const[D,T,M]=g,z=Or(T);D===this.userId&&o.path.isEqual(z)?n=n.add(M):b.done()}));i.push(f)})),U.waitFor(i).next((()=>this.zr(e,n)))}getAllMutationBatchesAffectingQuery(e,t){const n=t.path,i=n.length+1,o=Ld(this.userId,n),u=IDBKeyRange.lowerBound(o);let B=new gt(Ue);return Jo(e).jn({range:u},((f,g,y)=>{const[b,D,T]=f,M=Or(D);b===this.userId&&n.isPrefixOf(M)?M.length===i&&(B=B.add(T)):y.done()})).next((()=>this.zr(e,B)))}zr(e,t){const n=[],i=[];return t.forEach((o=>{i.push(ii(e).get(o).next((u=>{if(u===null)throw Te(35274,{batchId:o});fe(u.userId===this.userId,9748,"Unexpected user for mutation batch",{userId:u.userId,batchId:o}),n.push(dl(this.serializer,u))})))})),U.waitFor(i).next((()=>n))}removeMutationBatch(e,t){return Cv(e.kr,this.userId,t).next((n=>(e.addOnCommittedListener((()=>{this.jr(t.batchId)})),U.forEach(n,(i=>this.referenceDelegate.markPotentiallyOrphaned(e,i))))))}jr(e){delete this.$r[e]}performConsistencyCheck(e){return this.checkEmpty(e).next((t=>{if(!t)return U.resolve();const n=IDBKeyRange.lowerBound((function(u){return[u]})(this.userId)),i=[];return Jo(e).jn({range:n},((o,u,B)=>{if(o[0]===this.userId){const f=Or(o[1]);i.push(f)}else B.done()})).next((()=>{fe(i.length===0,56720,{Hr:i.map((o=>o.canonicalString()))})}))}))}containsKey(e,t){return Ev(e,this.userId,t)}Jr(e){return _v(e).get(this.userId).next((t=>t||{userId:this.userId,lastAcknowledgedBatchId:xl,lastStreamToken:""}))}}function Ev(r,e,t){const n=Ld(e,t.path),i=n[1],o=IDBKeyRange.lowerBound(n);let u=!1;return Jo(r).jn({range:o,zn:!0},((B,f,g)=>{const[y,b,D]=B;y===e&&b===i&&(u=!0),g.done()})).next((()=>u))}function ii(r){return xn(r,ir)}function Jo(r){return xn(r,mu)}function _v(r){return xn(r,DB)}/**
2029 * @license
2030 * Copyright 2020 Google LLC
2031 *
2032 * Licensed under the Apache License, Version 2.0 (the "License");
2033 * you may not use this file except in compliance with the License.
2034 * You may obtain a copy of the License at
2035 *
2036 *   http://www.apache.org/licenses/LICENSE-2.0
2037 *
2038 * Unless required by applicable law or agreed to in writing, software
2039 * distributed under the License is distributed on an "AS IS" BASIS,
2040 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2041 * See the License for the specific language governing permissions and
2042 * limitations under the License.
2043 */class uk{getBundleMetadata(e,t){return D_(e).get(t).next((n=>{if(n)return(function(o){return{id:o.bundleId,createTime:Ml(o.createTime),version:o.version}})(n)}))}saveBundleMetadata(e,t){return D_(e).put((function(i){return{bundleId:i.id,createTime:jl(Xn(i.createTime)),version:i.version}})(t))}getNamedQuery(e,t){return v_(e).get(t).next((n=>{if(n)return(function(o){return{name:o.name,query:xv(o.bundledQuery),readTime:Ml(o.readTime)}})(n)}))}saveNamedQuery(e,t){return v_(e).put((function(i){return{name:i.name,readTime:jl(Xn(i.readTime)),bundledQuery:i.bundledQuery}})(t))}}function D_(r){return xn(r,Of)}function v_(r){return xn(r,kf)}/**
2044 * @license
2045 * Copyright 2022 Google LLC
2046 *
2047 * Licensed under the Apache License, Version 2.0 (the "License");
2048 * you may not use this file except in compliance with the License.
2049 * You may obtain a copy of the License at
2050 *
2051 *   http://www.apache.org/licenses/LICENSE-2.0
2052 *
2053 * Unless required by applicable law or agreed to in writing, software
2054 * distributed under the License is distributed on an "AS IS" BASIS,
2055 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2056 * See the License for the specific language governing permissions and
2057 * limitations under the License.
2058 */class Mf{constructor(e,t){this.serializer=e,this.userId=t}static Kr(e,t){const n=t.uid||"";return new Mf(e,n)}getOverlay(e,t){return jo(e).get(E_(this.userId,t)).next((n=>n?Ed(this.serializer,n):null))}getOverlays(e,t){const n=Us();return U.forEach(t,(i=>this.getOverlay(e,i).next((o=>{o!==null&&n.set(i,o)})))).next((()=>n))}getAllOverlays(e,t){const n=Us();return jo(e).jn(((i,o)=>{const u=Ed(this.serializer,o);u.largestBatchId>t&&n.set(u.getKey(),u)})).next((()=>n))}saveOverlays(e,t,n){const i=[];return n.forEach(((o,u)=>{const B=new YC(t,u);i.push(this.Yr(e,B))})),U.waitFor(i)}removeOverlaysForBatchId(e,t,n){const i=new Set;t.forEach((u=>i.add(Gn(u.getCollectionPath()))));const o=[];return i.forEach((u=>{const B=IDBKeyRange.bound([this.userId,u,n],[this.userId,u,n+1],!1,!0);o.push(jo(e).Gn(Gg,B))})),U.waitFor(o)}getOverlaysForCollection(e,t,n){const i=Us(),o=Gn(t),u=IDBKeyRange.bound([this.userId,o,n],[this.userId,o,Number.POSITIVE_INFINITY],!0);return jo(e).Kn(Gg,u).next((B=>{for(const f of B){const g=Ed(this.serializer,f);i.set(g.getKey(),g)}return i}))}getOverlaysForCollectionGroup(e,t,n,i){const o=Us();let u;const B=IDBKeyRange.bound([this.userId,t,n],[this.userId,t,Number.POSITIVE_INFINITY],!0);return jo(e).jn({index:dv,range:B},((f,g,y)=>{const b=Ed(this.serializer,g);o.size()<i||b.largestBatchId===u?(o.set(b.getKey(),b),u=b.largestBatchId):y.done()})).next((()=>o))}Yr(e,t){return jo(e).put((function(i,o,u){const[B,f,g]=E_(o,u.mutation.key);return{userId:o,collectionPath:f,documentId:g,collectionGroup:u.mutation.key.getCollectionGroup(),largestBatchId:u.largestBatchId,overlayMutation:Xd(i.qr,u.mutation)}})(this.serializer,this.userId,t))}}function jo(r){return xn(r,Lf)}/**
2059 * @license
2060 * Copyright 2024 Google LLC
2061 *
2062 * Licensed under the Apache License, Version 2.0 (the "License");
2063 * you may not use this file except in compliance with the License.
2064 * You may obtain a copy of the License at
2065 *
2066 *   http://www.apache.org/licenses/LICENSE-2.0
2067 *
2068 * Unless required by applicable law or agreed to in writing, software
2069 * distributed under the License is distributed on an "AS IS" BASIS,
2070 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2071 * See the License for the specific language governing permissions and
2072 * limitations under the License.
2073 */class ck{Zr(e){return xn(e,JC)}getSessionToken(e){return this.Zr(e).get("sessionToken").next((t=>{const n=t==null?void 0:t.value;return n?qt.fromUint8Array(n):qt.EMPTY_BYTE_STRING}))}setSessionToken(e,t){return this.Zr(e).put({name:"sessionToken",value:t.toUint8Array()})}}/**
2074 * @license
2075 * Copyright 2021 Google LLC
2076 *
2077 * Licensed under the Apache License, Version 2.0 (the "License");
2078 * you may not use this file except in compliance with the License.
2079 * You may obtain a copy of the License at
2080 *
2081 *   http://www.apache.org/licenses/LICENSE-2.0
2082 *
2083 * Unless required by applicable law or agreed to in writing, software
2084 * distributed under the License is distributed on an "AS IS" BASIS,
2085 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2086 * See the License for the specific language governing permissions and
2087 * limitations under the License.
2088 */class fl{constructor(){}Xr(e,t){this.ei(e,t),t.ti()}ei(e,t){if("nullValue"in e)this.ni(t,5);else if("booleanValue"in e)this.ni(t,10),t.ri(e.booleanValue?1:0);else if("integerValue"in e)this.ni(t,15),t.ri(Lt(e.integerValue));else if("doubleValue"in e){const n=Lt(e.doubleValue);isNaN(n)?this.ni(t,13):(this.ni(t,15),au(n)?t.ri(0):t.ri(n))}else if("timestampValue"in e){let n=e.timestampValue;this.ni(t,20),typeof n=="string"&&(n=Ca(n)),t.ii(`${n.seconds||""}`),t.ri(n.nanos||0)}else if("stringValue"in e)this.si(e.stringValue,t),this._i(t);else if("bytesValue"in e)this.ni(t,30),t.oi(ya(e.bytesValue)),this._i(t);else if("referenceValue"in e)this.ai(e.referenceValue,t);else if("geoPointValue"in e){const n=e.geoPointValue;this.ni(t,45),t.ri(n.latitude||0),t.ri(n.longitude||0)}else"mapValue"in e?K1(e)?this.ni(t,Number.MAX_SAFE_INTEGER):kl(e)?this.ui(e.mapValue,t):(this.ci(e.mapValue,t),this._i(t)):"arrayValue"in e?(this.li(e.arrayValue,t),this._i(t)):Te(19022,{Ei:e})}si(e,t){this.ni(t,25),this.hi(e,t)}hi(e,t){t.ii(e)}ci(e,t){const n=e.fields||{};this.ni(t,55);for(const i of Object.keys(n))this.si(i,t),this.ei(n[i],t)}ui(e,t){var u,B;const n=e.fields||{};this.ni(t,53);const i=Ol,o=((B=(u=n[i].arrayValue)==null?void 0:u.values)==null?void 0:B.length)||0;this.ni(t,15),t.ri(Lt(o)),this.si(i,t),this.ei(n[i],t)}li(e,t){const n=e.values||[];this.ni(t,50);for(const i of n)this.ei(i,t)}ai(e,t){this.ni(t,37),De.fromName(e).path.forEach((n=>{this.ni(t,60),this.hi(n,t)}))}ni(e,t){e.ri(t)}_i(e){e.ri(2)}}fl.Ti=new fl;/**
2089 * @license
2090 * Copyright 2021 Google LLC
2091 *
2092 * Licensed under the Apache License, Version 2.0 (the "License");
2093 * you may not use this file except in compliance with the License.
2094 * You may obtain a copy of the License at
2095 *
2096 *   http://www.apache.org/licenses/LICENSE-2.0
2097 *
2098 * Unless required by applicable law | agreed to in writing, software
2099 * distributed under the License is distributed on an "AS IS" BASIS,
2100 * WITHOUT WARRANTIES | CONDITIONS OF ANY KIND, either express | implied.
2101 * See the License for the specific language governing permissions and
2102 * limitations under the License.
2103 */const Mo=255;function Bk(r){if(r===0)return 8;let e=0;return r>>4||(e+=4,r<<=4),r>>6||(e+=2,r<<=2),r>>7||(e+=1),e}function w_(r){const e=64-(function(n){let i=0;for(let o=0;o<8;++o){const u=Bk(255&n[o]);if(i+=u,u!==8)break}return i})(r);return Math.ceil(e/8)}class hk{constructor(){this.buffer=new Uint8Array(1024),this.position=0}Pi(e){const t=e[Symbol.iterator]();let n=t.next();for(;!n.done;)this.Ri(n.value),n=t.next();this.Ii()}Ai(e){const t=e[Symbol.iterator]();let n=t.next();for(;!n.done;)this.Vi(n.value),n=t.next();this.di()}fi(e){for(const t of e){const n=t.charCodeAt(0);if(n<128)this.Ri(n);else if(n<2048)this.Ri(960|n>>>6),this.Ri(128|63&n);else if(t<"\uD800"||"\uDBFF"<t)this.Ri(480|n>>>12),this.Ri(128|63&n>>>6),this.Ri(128|63&n);else{const i=t.codePointAt(0);this.Ri(240|i>>>18),this.Ri(128|63&i>>>12),this.Ri(128|63&i>>>6),this.Ri(128|63&i)}}this.Ii()}mi(e){for(const t of e){const n=t.charCodeAt(0);if(n<128)this.Vi(n);else if(n<2048)this.Vi(960|n>>>6),this.Vi(128|63&n);else if(t<"\uD800"||"\uDBFF"<t)this.Vi(480|n>>>12),this.Vi(128|63&n>>>6),this.Vi(128|63&n);else{const i=t.codePointAt(0);this.Vi(240|i>>>18),this.Vi(128|63&i>>>12),this.Vi(128|63&i>>>6),this.Vi(128|63&i)}}this.di()}pi(e){const t=this.gi(e),n=w_(t);this.yi(1+n),this.buffer[this.position++]=255&n;for(let i=t.length-n;i<t.length;++i)this.buffer[this.position++]=255&t[i]}wi(e){const t=this.gi(e),n=w_(t);this.yi(1+n),this.buffer[this.position++]=~(255&n);for(let i=t.length-n;i<t.length;++i)this.buffer[this.position++]=~(255&t[i])}bi(){this.Si(Mo),this.Si(255)}Di(){this.xi(Mo),this.xi(255)}reset(){this.position=0}seed(e){this.yi(e.length),this.buffer.set(e,this.position),this.position+=e.length}Ci(){return this.buffer.slice(0,this.position)}gi(e){const t=(function(o){const u=new DataView(new ArrayBuffer(8));return u.setFloat64(0,o,!1),new Uint8Array(u.buffer)})(e),n=!!(128&t[0]);t[0]^=n?255:128;for(let i=1;i<t.length;++i)t[i]^=n?255:0;return t}Ri(e){const t=255&e;t===0?(this.Si(0),this.Si(255)):t===Mo?(this.Si(Mo),this.Si(0)):this.Si(t)}Vi(e){const t=255&e;t===0?(this.xi(0),this.xi(255)):t===Mo?(this.xi(Mo),this.xi(0)):this.xi(e)}Ii(){this.Si(0),this.Si(1)}di(){this.xi(0),this.xi(1)}Si(e){this.yi(1),this.buffer[this.position++]=e}xi(e){this.yi(1),this.buffer[this.position++]=~e}yi(e){const t=e+this.position;if(t<=this.buffer.length)return;let n=2*this.buffer.length;n<t&&(n=t);const i=new Uint8Array(n);i.set(this.buffer),this.buffer=i}}class dk{constructor(e){this.Fi=e}oi(e){this.Fi.Pi(e)}ii(e){this.Fi.fi(e)}ri(e){this.Fi.pi(e)}ti(){this.Fi.bi()}}class fk{constructor(e){this.Fi=e}oi(e){this.Fi.Ai(e)}ii(e){this.Fi.mi(e)}ri(e){this.Fi.wi(e)}ti(){this.Fi.Di()}}class Vc{constructor(){this.Fi=new hk,this.ascending=new dk(this.Fi),this.descending=new fk(this.Fi)}seed(e){this.Fi.seed(e)}Oi(e){return e===0?this.ascending:this.descending}Ci(){return this.Fi.Ci()}reset(){this.Fi.reset()}}/**
2104 * @license
2105 * Copyright 2022 Google LLC
2106 *
2107 * Licensed under the Apache License, Version 2.0 (the "License");
2108 * you may not use this file except in compliance with the License.
2109 * You may obtain a copy of the License at
2110 *
2111 *   http://www.apache.org/licenses/LICENSE-2.0
2112 *
2113 * Unless required by applicable law or agreed to in writing, software
2114 * distributed under the License is distributed on an "AS IS" BASIS,
2115 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2116 * See the License for the specific language governing permissions and
2117 * limitations under the License.
2118 */class ml{constructor(e,t,n,i){this.Mi=e,this.Ni=t,this.Li=n,this.Bi=i}Ui(){const e=this.Bi.length,t=e===0||this.Bi[e-1]===255?e+1:e,n=new Uint8Array(t);return n.set(this.Bi,0),t!==e?n.set([0],this.Bi.length):++n[n.length-1],new ml(this.Mi,this.Ni,this.Li,n)}ki(e,t,n){return{indexId:this.Mi,uid:e,arrayValue:Md(this.Li),directionalValue:Md(this.Bi),orderedDocumentKey:Md(t),documentKey:n.path.toArray()}}qi(e,t,n){const i=this.ki(e,t,n);return[i.indexId,i.uid,i.arrayValue,i.directionalValue,i.orderedDocumentKey,i.documentKey]}}function li(r,e){let t=r.Mi-e.Mi;return t!==0?t:(t=T_(r.Li,e.Li),t!==0?t:(t=T_(r.Bi,e.Bi),t!==0?t:De.comparator(r.Ni,e.Ni)))}function T_(r,e){for(let t=0;t<r.length&&t<e.length;++t){const n=r[t]-e[t];if(n!==0)return n}return r.length-e.length}function Md(r){return m1()?(function(t){let n="";for(let i=0;i<t.length;i++)n+=String.fromCharCode(t[i]);return n})(r):r}function A_(r){return typeof r!="string"?r:(function(t){const n=new Uint8Array(t.length);for(let i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return n})(r)}class N_{constructor(e){this.$i=new gt(((t,n)=>bn.comparator(t.field,n.field))),this.collectionId=e.collectionGroup!=null?e.collectionGroup:e.path.lastSegment(),this.Ki=e.orderBy,this.Wi=[];for(const t of e.filters){const n=t;n.isInequality()?this.$i=this.$i.add(n):this.Wi.push(n)}}get Qi(){return this.$i.size>1}Gi(e){if(fe(e.collectionGroup===this.collectionId,49279),this.Qi)return!1;const t=Sg(e);if(t!==void 0&&!this.zi(t))return!1;const n=ul(e);let i=new Set,o=0,u=0;for(;o<n.length&&this.zi(n[o]);++o)i=i.add(n[o].fieldPath.canonicalString());if(o===n.length)return!0;if(this.$i.size>0){const B=this.$i.getIterator().getNext();if(!i.has(B.field.canonicalString())){const f=n[o];if(!this.ji(B,f)||!this.Hi(this.Ki[u++],f))return!1}++o}for(;o<n.length;++o){const B=n[o];if(u>=this.Ki.length||!this.Hi(this.Ki[u++],B))return!1}return!0}Ji(){if(this.Qi)return null;let e=new gt(bn.comparator);const t=[];for(const n of this.Wi)if(!n.field.isKeyField())if(n.op==="array-contains"||n.op==="array-contains-any")t.push(new Rd(n.field,2));else{if(e.has(n.field))continue;e=e.add(n.field),t.push(new Rd(n.field,0))}for(const n of this.Ki)n.field.isKeyField()||e.has(n.field)||(e=e.add(n.field),t.push(new Rd(n.field,n.dir==="asc"?0:1)));return new Jd(Jd.UNKNOWN_ID,this.collectionId,t,fB.empty())}zi(e){for(const t of this.Wi)if(this.ji(t,e))return!0;return!1}ji(e,t){if(e===void 0||!e.field.isEqual(t.fieldPath))return!1;const n=e.op==="array-contains"||e.op==="array-contains-any";return t.kind===2===n}Hi(e,t){return!!e.field.isEqual(t.fieldPath)&&(t.kind===0&&e.dir==="asc"||t.kind===1&&e.dir==="desc")}}/**
2119 * @license
2120 * Copyright 2022 Google LLC
2121 *
2122 * Licensed under the Apache License, Version 2.0 (the "License");
2123 * you may not use this file except in compliance with the License.
2124 * You may obtain a copy of the License at
2125 *
2126 *   http://www.apache.org/licenses/LICENSE-2.0
2127 *
2128 * Unless required by applicable law or agreed to in writing, software
2129 * distributed under the License is distributed on an "AS IS" BASIS,
2130 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2131 * See the License for the specific language governing permissions and
2132 * limitations under the License.
2133 */function Dv(r){var t,n;if(fe(r instanceof it||r instanceof wt,20012),r instanceof it){if(r instanceof oD){const i=((n=(t=r.value.arrayValue)==null?void 0:t.values)==null?void 0:n.map((o=>it.create(r.field,"==",o))))||[];return wt.create(i,"or")}return r}const e=r.filters.map((i=>Dv(i)));return wt.create(e,r.op)}function mk(r){if(r.getFilters().length===0)return[];const e=Kg(Dv(r));return fe(vv(e),7391),zg(e)||qg(e)?[e]:e.getFilters()}function zg(r){return r instanceof it}function qg(r){return r instanceof wt&&bC(r)}function vv(r){return zg(r)||qg(r)||(function(t){if(t instanceof wt&&Ng(t)){for(const n of t.getFilters())if(!zg(n)&&!qg(n))return!1;return!0}return!1})(r)}function Kg(r){if(fe(r instanceof it||r instanceof wt,34018),r instanceof it)return r;if(r.filters.length===1)return Kg(r.filters[0]);const e=r.filters.map((n=>Kg(n)));let t=wt.create(e,r.op);return t=af(t),vv(t)?t:(fe(t instanceof wt,64498),fe(Bu(t),40251),fe(t.filters.length>1,57927),t.filters.reduce(((n,i)=>XC(n,i))))}function XC(r,e){let t;return fe(r instanceof it||r instanceof wt,38388),fe(e instanceof it||e instanceof wt,25473),t=r instanceof it?e instanceof it?(function(i,o){return wt.create([i,o],"and")})(r,e):I_(r,e):e instanceof it?I_(e,r):(function(i,o){if(fe(i.filters.length>0&&o.filters.length>0,48005),Bu(i)&&Bu(o))return aD(i,o.getFilters());const u=Ng(i)?i:o,B=Ng(i)?o:i,f=u.filters.map((g=>XC(g,B)));return wt.create(f,"or")})(r,e),af(t)}function I_(r,e){if(Bu(e))return aD(e,r.getFilters());{const t=e.filters.map((n=>XC(r,n)));return wt.create(t,"or")}}function af(r){if(fe(r instanceof it||r instanceof wt,11850),r instanceof it)return r;const e=r.getFilters();if(e.length===1)return af(e[0]);if(sD(r))return r;const t=e.map((i=>af(i))),n=[];return t.forEach((i=>{i instanceof it?n.push(i):i instanceof wt&&(i.op===r.op?n.push(...i.filters):n.push(i))})),n.length===1?n[0]:wt.create(n,r.op)}/**
2134 * @license
2135 * Copyright 2019 Google LLC
2136 *
2137 * Licensed under the Apache License, Version 2.0 (the "License");
2138 * you may not use this file except in compliance with the License.
2139 * You may obtain a copy of the License at
2140 *
2141 *   http://www.apache.org/licenses/LICENSE-2.0
2142 *
2143 * Unless required by applicable law or agreed to in writing, software
2144 * distributed under the License is distributed on an "AS IS" BASIS,
2145 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2146 * See the License for the specific language governing permissions and
2147 * limitations under the License.
2148 */class pk{constructor(){this.Yi=new $C}addToCollectionParentIndex(e,t){return this.Yi.add(t),U.resolve()}getCollectionParents(e,t){return U.resolve(this.Yi.getEntries(t))}addFieldIndex(e,t){return U.resolve()}deleteFieldIndex(e,t){return U.resolve()}deleteAllFieldIndexes(e){return U.resolve()}createTargetIndexes(e,t){return U.resolve()}getDocumentsMatchingTarget(e,t){return U.resolve(null)}getIndexType(e,t){return U.resolve(0)}getFieldIndexes(e,t){return U.resolve([])}getNextCollectionGroupToUpdate(e){return U.resolve(null)}getMinOffset(e,t){return U.resolve(Ts.min())}getMinOffsetFromCollectionGroup(e,t){return U.resolve(Ts.min())}updateCollectionGroup(e,t,n){return U.resolve()}updateIndexEntries(e,t){return U.resolve()}}class $C{constructor(){this.index={}}add(e){const t=e.lastSegment(),n=e.popLast(),i=this.index[t]||new gt(ct.comparator),o=!i.has(n);return this.index[t]=i.add(n),o}has(e){const t=e.lastSegment(),n=e.popLast(),i=this.index[t];return i&&i.has(n)}getEntries(e){return(this.index[e]||new gt(ct.comparator)).toArray()}}/**
2149 * @license
2150 * Copyright 2019 Google LLC
2151 *
2152 * Licensed under the Apache License, Version 2.0 (the "License");
2153 * you may not use this file except in compliance with the License.
2154 * You may obtain a copy of the License at
2155 *
2156 *   http://www.apache.org/licenses/LICENSE-2.0
2157 *
2158 * Unless required by applicable law or agreed to in writing, software
2159 * distributed under the License is distributed on an "AS IS" BASIS,
2160 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2161 * See the License for the specific language governing permissions and
2162 * limitations under the License.
2163 */const S_="IndexedDbIndexManager",_d=new Uint8Array(0);class gk{constructor(e,t){this.databaseId=t,this.Zi=new $C,this.Xi=new Ea((n=>Qd(n)),((n,i)=>EC(n,i))),this.uid=e.uid||""}addToCollectionParentIndex(e,t){if(!this.Zi.has(t)){const n=t.lastSegment(),i=t.popLast();e.addOnCommittedListener((()=>{this.Zi.add(t)}));const o={collectionId:n,parent:Gn(i)};return R_(e).put(o)}return U.resolve()}getCollectionParents(e,t){const n=[],i=IDBKeyRange.bound([t,""],[M1(t),""],!1,!0);return R_(e).Kn(i).next((o=>{for(const u of o){if(u.collectionId!==t)break;n.push(Or(u.parent))}return n}))}addFieldIndex(e,t){const n=Fc(e),i=(function(B){return{indexId:B.indexId,collectionGroup:B.collectionGroup,fields:B.fields.map((f=>[f.fieldPath.canonicalString(),f.kind]))}})(t);delete i.indexId;const o=n.add(i);if(t.indexState){const u=Vo(e);return o.next((B=>{u.put(__(B,this.uid,t.indexState.sequenceNumber,t.indexState.offset))}))}return o.next()}deleteFieldIndex(e,t){const n=Fc(e),i=Vo(e),o=Po(e);return n.delete(t.indexId).next((()=>i.delete(IDBKeyRange.bound([t.indexId],[t.indexId+1],!1,!0)))).next((()=>o.delete(IDBKeyRange.bound([t.indexId],[t.indexId+1],!1,!0))))}deleteAllFieldIndexes(e){const t=Fc(e),n=Po(e),i=Vo(e);return t.Gn().next((()=>n.Gn())).next((()=>i.Gn()))}createTargetIndexes(e,t){return U.forEach(this.es(t),(n=>this.getIndexType(e,n).next((i=>{if(i===0||i===1){const o=new N_(n).Ji();if(o!=null)return this.addFieldIndex(e,o)}}))))}getDocumentsMatchingTarget(e,t){const n=Po(e);let i=!0;const o=new Map;return U.forEach(this.es(t),(u=>this.ts(e,u).next((B=>{i&&(i=!!B),o.set(u,B)})))).next((()=>{if(i){let u=Xe();const B=[];return U.forEach(o,((f,g)=>{Be(S_,`Using index ${(function(de){return`id=${de.indexId}|cg=${de.collectionGroup}|f=${de.fields.map((ce=>`${ce.fieldPath}:${ce.kind}`)).join(",")}`})(f)} to execute ${Qd(t)}`);const y=(function(de,ce){const _e=Sg(ce);if(_e===void 0)return null;for(const ye of Yd(de,_e.fieldPath))switch(ye.op){case"array-contains-any":return ye.value.arrayValue.values||[];case"array-contains":return[ye.value]}return null})(g,f),b=(function(de,ce){const _e=new Map;for(const ye of ul(ce))for(const S of Yd(de,ye.fieldPath))switch(S.op){case"==":case"in":_e.set(ye.fieldPath.canonicalString(),S.value);break;case"not-in":case"!=":return _e.set(ye.fieldPath.canonicalString(),S.value),Array.from(_e.values())}return null})(g,f),D=(function(de,ce){const _e=[];let ye=!0;for(const S of ul(ce)){const A=S.kind===0?$E(de,S.fieldPath,de.startAt):ZE(de,S.fieldPath,de.startAt);_e.push(A.value),ye&&(ye=A.inclusive)}return new cu(_e,ye)}
2163)(g,f),T=(function(de,ce){const _e=[];let ye=!0;for(const S of ul(ce)){const A=S.kind===0?ZE(de,S.fieldPath,de.endAt):$E(de,S.fieldPath,de.endAt);_e.push(A.value),ye&&(ye=A.inclusive)}return new cu(_e,ye)})(g,f),M=this.ns(f,g,D),z=this.ns(f,g,T),W=this.rs(f,g,b),K=this.ss(f.indexId,y,M,D.inclusive,z,T.inclusive,W);return U.forEach(K,(he=>n.Qn(he,t.limit).next((de=>{de.forEach((ce=>{const _e=De.fromSegments(ce.documentKey);u.has(_e)||(u=u.add(_e),B.push(_e))}))}))))})).next((()=>B))}return U.resolve(null)}))}es(e){let t=this.Xi.get(e);return t||(e.filters.length===0?t=[e]:t=mk(wt.create(e.filters,"and")).map((n=>Rg(e.path,e.collectionGroup,e.orderBy,n.getFilters(),e.limit,e.startAt,e.endAt))),this.Xi.set(e,t),t)}ss(e,t,n,i,o,u,B){const f=(t!=null?t.length:1)*Math.max(n.length,o.length),g=f/(t!=null?t.length:1),y=[];for(let b=0;b<f;++b){const D=t?this._s(t[b/g]):_d,T=this.us(e,D,n[b%g],i),M=this.cs(e,D,o[b%g],u),z=B.map((W=>this.us(e,D,W,!0)));y.push(...this.createRange(T,M,z))}return y}us(e,t,n,i){const o=new ml(e,De.empty(),t,n);return i?o:o.Ui()}cs(e,t,n,i){const o=new ml(e,De.empty(),t,n);return i?o.Ui():o}ts(e,t){const n=new N_(t),i=t.collectionGroup!=null?t.collectionGroup:t.path.lastSegment();return this.getFieldIndexes(e,i).next((o=>{let u=null;for(const B of o)n.Gi(B)&&(!u||B.fields.length>u.fields.length)&&(u=B);return u}))}getIndexType(e,t){let n=2;const i=this.es(t);return U.forEach(i,(o=>this.ts(e,o).next((u=>{u?n!==0&&u.fields.length<(function(f){let g=new gt(bn.comparator),y=!1;for(const b of f.filters)for(const D of b.getFlattenedFilters())D.field.isKeyField()||(D.op==="array-contains"||D.op==="array-contains-any"?y=!0:g=g.add(D.field));for(const b of f.orderBy)b.field.isKeyField()||(g=g.add(b.field));return g.size+(y?1:0)})(o)&&(n=1):n=0})))).next((()=>(function(u){return u.limit!==null})(t)&&i.length>1&&n===2?1:n))}ls(e,t){const n=new Vc;for(const i of ul(e)){const o=t.data.field(i.fieldPath);if(o==null)return null;const u=n.Oi(i.kind);fl.Ti.Xr(o,u)}return n.Ci()}_s(e){const t=new Vc;return fl.Ti.Xr(e,t.Oi(0)),t.Ci()}Es(e,t){const n=new Vc;return fl.Ti.Xr(mC(this.databaseId,t),n.Oi((function(o){const u=ul(o);return u.length===0?0:u[u.length-1].kind})(e))),n.Ci()}rs(e,t,n){if(n===null)return[];let i=[];i.push(new Vc);let o=0;for(const u of ul(e)){const B=n[o++];for(const f of i)if(this.hs(t,u.fieldPath)&&_i(B))i=this.Ts(i,u,B);else{const g=f.Oi(u.kind);fl.Ti.Xr(B,g)}}return this.Ps(i)}ns(e,t,n){return this.rs(e,t,n.position)}Ps(e){const t=[];for(let n=0;n<e.length;++n)t[n]=e[n].Ci();return t}Ts(e,t,n){const i=[...e],o=[];for(const u of n.arrayValue.values||[])for(const B of i){const f=new Vc;f.seed(B.Ci()),fl.Ti.Xr(u,f.Oi(t.kind)),o.push(f)}return o}hs(e,t){return!!e.filters.find((n=>n instanceof it&&n.field.isEqual(t)&&(n.op==="in"||n.op==="not-in")))}getFieldIndexes(e,t){const n=Fc(e),i=Vo(e);return(t?n.Kn(Fg,IDBKeyRange.bound(t,t)):n.Kn()).next((o=>{const u=[];return U.forEach(o,(B=>i.get([B.indexId,this.uid]).next((f=>{u.push((function(y,b){const D=b?new fB(b.sequenceNumber,new Ts(Ml(b.readTime),new De(Or(b.documentKey)),b.largestBatchId)):fB.empty(),T=y.fields.map((([M,z])=>new Rd(bn.fromServerFormat(M),z)));return new Jd(y.indexId,y.collectionGroup,T,D)})(B,f))})))).next((()=>u))}))}getNextCollectionGroupToUpdate(e){return this.getFieldIndexes(e).next((t=>t.length===0?null:(t.sort(((n,i)=>{const o=n.indexState.sequenceNumber-i.indexState.sequenceNumber;return o!==0?o:Ue(n.collectionGroup,i.collectionGroup)})),t[0].collectionGroup)))}updateCollectionGroup(e,t,n){const i=Fc(e),o=Vo(e);return this.Rs(e).next((u=>i.Kn(Fg,IDBKeyRange.bound(t,t)).next((B=>U.forEach(B,(f=>o.put(__(f.indexId,this.uid,u,n))))))))}updateIndexEntries(e,t){const n=new Map;return U.forEach(t,((i,o)=>{const u=n.get(i.collectionGroup);return(u?U.resolve(u):this.getFieldIndexes(e,i.collectionGroup)).next((B=>(n.set(i.collectionGroup,B),U.forEach(B,(f=>this.Is(e,i,f).next((g=>{const y=this.As(o,f);return g.isEqual(y)?U.resolve():this.Vs(e,o,f,g,y)})))))))}))}ds(e,t,n,i){return Po(e).put(i.ki(this.uid,this.Es(n,t.key),t.key))}fs(e,t,n,i){return Po(e).delete(i.qi(this.uid,this.Es(n,t.key),t.key))}Is(e,t,n){const i=Po(e);let o=new gt(li);return i.jn({index:hv,range:IDBKeyRange.only([n.indexId,this.uid,Md(this.Es(n,t))])},((u,B)=>{o=o.add(new ml(n.indexId,t,A_(B.arrayValue),A_(B.directionalValue)))})).next((()=>o))}As(e,t){let n=new gt(li);const i=this.ls(t,e);if(i==null)return n;const o=Sg(t);if(o!=null){const u=e.data.field(o.fieldPath);if(_i(u))for(const B of u.arrayValue.values||[])n=n.add(new ml(t.indexId,e.key,this._s(B),i)
vendor: 5,217 bytes, lines 2163-2193
2163)}else n=n.add(new ml(t.indexId,e.key,_d,i));return n}Vs(e,t,n,i,o){Be(S_,"Updating index entries for document '%s'",t.key);const u=[];return(function(f,g,y,b,D){const T=f.getIterator(),M=g.getIterator();let z=ko(T),W=ko(M);for(;z||W;){let K=!1,he=!1;if(z&&W){const de=y(z,W);de<0?he=!0:de>0&&(K=!0)}else z!=null?he=!0:K=!0;K?(b(W),W=ko(M)):he?(D(z),z=ko(T)):(z=ko(T),W=ko(M))}})(i,o,li,(B=>{u.push(this.ds(e,t,n,B))}),(B=>{u.push(this.fs(e,t,n,B))})),U.waitFor(u)}Rs(e){let t=1;return Vo(e).jn({index:Bv,reverse:!0,range:IDBKeyRange.upperBound([this.uid,Number.MAX_SAFE_INTEGER])},((n,i,o)=>{o.done(),t=i.sequenceNumber+1})).next((()=>t))}createRange(e,t,n){n=n.sort(((u,B)=>li(u,B))).filter(((u,B,f)=>!B||li(u,f[B-1])!==0));const i=[];i.push(e);for(const u of n){const B=li(u,e),f=li(u,t);if(B===0)i[0]=e.Ui();else if(B>0&&f<0)i.push(u),i.push(u.Ui());else if(f>0)break}i.push(t);const o=[];for(let u=0;u<i.length;u+=2){if(this.ps(i[u],i[u+1]))return[];const B=i[u].qi(this.uid,_d,De.empty()),f=i[u+1].qi(this.uid,_d,De.empty());o.push(IDBKeyRange.bound(B,f))}return o}ps(e,t){return li(e,t)>0}getMinOffsetFromCollectionGroup(e,t){return this.getFieldIndexes(e,t).next(O_)}getMinOffset(e,t){return U.mapArray(this.es(t),(n=>this.ts(e,n).next((i=>i||Te(44426))))).next(O_)}}function R_(r){return xn(r,wB)}function Po(r){return xn(r,sB)}function Fc(r){return xn(r,KC)}function Vo(r){return xn(r,nB)}function O_(r){fe(r.length!==0,28825);let e=r[0].indexState.offset,t=e.largestBatchId;for(let n=1;n<r.length;n++){const i=r[n].indexState.offset;xC(i,e)<0&&(e=i),t<i.largestBatchId&&(t=i.largestBatchId)}return new Ts(e.readTime,e.documentKey,t)}/**
2164 * @license
2165 * Copyright 2017 Google LLC
2166 *
2167 * Licensed under the Apache License, Version 2.0 (the "License");
2168 * you may not use this file except in compliance with the License.
2169 * You may obtain a copy of the License at
2170 *
2171 *   http://www.apache.org/licenses/LICENSE-2.0
2172 *
2173 * Unless required by applicable law or agreed to in writing, software
2174 * distributed under the License is distributed on an "AS IS" BASIS,
2175 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2176 * See the License for the specific language governing permissions and
2177 * limitations under the License.
2178 */class xa{constructor(e){this.gs=e}next(){return this.gs+=2,this.gs}static ys(){return new xa(0)}static ws(){return new xa(-1)}}/**
2179 * @license
2180 * Copyright 2017 Google LLC
2181 *
2182 * Licensed under the Apache License, Version 2.0 (the "License");
2183 * you may not use this file except in compliance with the License.
2184 * You may obtain a copy of the License at
2185 *
2186 *   http://www.apache.org/licenses/LICENSE-2.0
2187 *
2188 * Unless required by applicable law or agreed to in writing, software
2189 * distributed under the License is distributed on an "AS IS" BASIS,
2190 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2191 * See the License for the specific language governing permissions and
2192 * limitations under the License.
2193 */class Ck{constructor(e,t){this.referenceDelegate=e,this.serializer=t}allocateTargetId(e){return this.bs(e).next((t=>{const n=new xa(t.highestTargetId);return t.highestTargetId=n.next(),this.vs(e,t).next((()=>t.highestTargetId))}))}getLastRemoteSnapshotVersion(e){return this.bs(e).next((t=>Me.fromTimestamp(new xt(t.lastRemoteSnapshotVersion.seconds,t.lastRemoteSnapshotVersion.nanoseconds))))}getHighestSequenceNumber(e){return this.bs(e).next((t=>t.highestListenSequenceNumber))}setTargetsMetadata(e,t,n){return this.bs(e).next((i=>(i.highestListenSequenceNumber=t,n&&(i.lastRemoteSnapshotVersion=n.toTimestamp()),t>i.highestListenSequenceNumber&&(i.highestListenSequenceNumber=t),this.vs(e,i))))}addTargetData(e,t){return this.Ss(e,t).next((()=>this.bs(e).next((n=>(n.targetCount+=1,this.Ds(t,n),this.vs(e,n))))))}updateTargetData(e,t){return this.Ss(e,t)}removeTargetData(e,t){return this.removeMatchingKeysForTargetId(e,t.targetId).next((()=>Fo(e).delete(t.targetId))).next((()=>this.bs(e))).next((n=>(fe(n.targetCount>0,8065),n.targetCount-=1,this.vs(e,n))))}removeTargets(e,t,n){let i=0;const o=[];return Fo(e).jn(((u,B)=>{const f=Kc(this.serializer,B);f.sequenceNumber<=t&&n.get(f.targetId)===null&&(i++,o.push(this.removeTargetData(e,f)))})).next((()=>U.waitFor(o))).next((()=>i))}forEachTarget(e,t){return Fo(e).jn(((n,i)=>{const o=Kc(this.serializer,i);t(o)}))}bs(e){return k_(e).get(nf).next((t=>(fe(t!==null,2888),t)))}vs(e,t){return k_(e).put(nf,t)}Ss(e,t){return Fo(e).put(bv(this.serializer,t))}Ds(e,t){let n=!1;return e.targetId>t.highestTargetId&&(t.highestTargetId=e.targetId,n=!0),e.sequenceNumber>t.highestListenSequenceNumber&&(t.highestListenSequenceNumber=e.sequenceNumber,n=!0),n}getTargetCount(e){return this.bs(e).next((t=>t.targetCount))}getTargetData(e,t){const n=Rf(t),i=IDBKeyRange.bound([n,Number.NEGATIVE_INFINITY],[n,Number.POSITIVE_INFINITY]);let o=null;return Fo(e).jn({range:i,index:cv},((u,B,f)=>{const g=Kc(this.serializer,B);HC(t,g.target)&&(o=g,f.done())})).next((()=>o))}addMatchingKeys(e,t,n){const i=[],o=di(e);return t.forEach((u=>{const B=Gn(u.path);i.push(o.put({targetId:n,path:B})),i.push(this.referenceDelegate.addReference(e,n,u))})),U.waitFor(i)}removeMatchingKeys(e,t,n){const i=di(e);
2193return U.forEach(t,(o=>{const u=Gn(o.path);return U.waitFor([i.delete([n,u]),this.referenceDelegate.removeReference(e,n,o)])}))}removeMatchingKeysForTargetId(e,t){const n=di(e),i=IDBKeyRange.bound([t],[t+1],!1,!0);return n.delete(i)}getMatchingKeysForTargetId(e,t){const n=IDBKeyRange.bound([t],[t+1],!1,!0),i=di(e);let o=Xe();return i.jn({range:n,zn:!0},((u,B,f)=>{const g=Or(u[1]),y=new De(g);o=o.add(y)})).next((()=>o))}containsKey(e,t){const n=Gn(t.path),i=IDBKeyRange.bound([n],[M1(n)],!1,!0);let o=0;return di(e).jn({index:qC,zn:!0,range:i},(([u,B],f,g)=>{u!==0&&(o++,g.done())})).next((()=>o>0))}ge(e,t){return Fo(e).get(t).next((n=>n?Kc(this.serializer,n):null))}}function Fo(r){return xn(r,pu)}function k_(r){return xn(r,Dl)}function di(r){return xn(r,gu)}/**
2194 * @license
2195 * Copyright 2020 Google LLC
2196 *
2197 * Licensed under the Apache License, Version 2.0 (the "License");
2198 * you may not use this file except in compliance with the License.
2199 * You may obtain a copy of the License at
2200 *
2201 *   http://www.apache.org/licenses/LICENSE-2.0
2202 *
2203 * Unless required by applicable law or agreed to in writing, software
2204 * distributed under the License is distributed on an "AS IS" BASIS,
2205 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2206 * See the License for the specific language governing permissions and
2207 * limitations under the License.
2208 */class yk{constructor(e,t){this.db=e,this.garbageCollector=HD(this,t)}rr(e){const t=this.xs(e);return this.db.getTargetCache().getTargetCount(e).next((n=>t.next((i=>n+i))))}xs(e){let t=0;return this.ir(e,(n=>{t++})).next((()=>t))}forEachTarget(e,t){return this.db.getTargetCache().forEachTarget(e,t)}ir(e,t){return this.Cs(e,((n,i)=>t(i)))}addReference(e,t,n){return Dd(e,n)}removeReference(e,t,n){return Dd(e,n)}removeTargets(e,t,n){return this.db.getTargetCache().removeTargets(e,t,n)}markPotentiallyOrphaned(e,t){return Dd(e,t)}Fs(e,t){return(function(i,o){let u=!1;return _v(i).Hn((B=>Ev(i,B,o).next((f=>(f&&(u=!0),U.resolve(!f)))))).next((()=>u))})(e,t)}removeOrphanedDocuments(e,t){const n=this.db.getRemoteDocumentCache().newChangeBuffer(),i=[];let o=0;return this.Cs(e,((u,B)=>{if(B<=t){const f=this.Fs(e,u).next((g=>{if(!g)return o++,n.getEntry(e,u).next((()=>(n.removeEntry(u,Me.min()),di(e).delete((function(b){return[0,Gn(b.path)]})(u)))))}));i.push(f)}})).next((()=>U.waitFor(i))).next((()=>n.apply(e))).next((()=>o))}removeTarget(e,t){const n=t.withSequenceNumber(e.currentSequenceNumber);return this.db.getTargetCache().updateTargetData(e,n)}updateLimboDocument(e,t){return Dd(e,t)}Cs(e,t){const n=di(e);let i,o=is.yn;return n.jn({index:qC},(([u,B],{path:f,sequenceNumber:g})=>{u===0?(o!==is.yn&&t(new De(Or(i)),o),o=g,i=f):o=is.yn})).next((()=>{o!==is.yn&&t(new De(Or(i)),o)}))}getCacheSize(e){return this.db.getRemoteDocumentCache().getSize(e)}}function Dd(r,e){return di(r).put((function(n,i){return{targetId:0,path:Gn(n.path),sequenceNumber:i}})(e,r.currentSequenceNumber))}// Copyright 2024 Google LLC* @license
2209function wv(r,e){var n;let t=e;for(const i of r.stages)t=bk({serializer:r.serializer,serverTimestampBehavior:(n=r.listenOptions)==null?void 0:n.serverTimestampBehavior},i,t);return t}function Pf(r,e){return wv(r,[e]).length>0}function Tv(r,e){return Wt(r)?Pf(r,e):Ef(r,e)}function bk(r,e,t){if(e instanceof MB)return(function(i,o,u){return u.filter((B=>B.isFoundDocument()&&`/${B.key.getCollectionPath().canonicalString()}`===o.Er))})(0,e,t);if(e instanceof Af)return(function(i,o,u){return u.filter((B=>{const f=tB(Fe(o.condition).evaluate(i,B));return f!==void 0&&Js(f,os)}))})(r,e,t);if(e instanceof PB)return(function(i,o,u){return u.filter((B=>B.isFoundDocument()&&B.key.getCollectionPath().lastSegment()===o.collectionId))})(0,e,t);if(e instanceof wf)return(function(i,o,u){return u.filter((B=>B.isFoundDocument()))})(0,0,t);if(e instanceof Tf)return(function(i,o,u){return u.filter((B=>B.isFoundDocument()&&o.Tr.has(B.key.path.toStringWithLeadingSlash())))})(0,e,t);if(e instanceof fu)return(function(i,o,u){return u.slice(0,o.limit)})(0,e,t);if(e instanceof Nf)return(function(i,o,u){const B=o.orderings.map((f=>({Os:Fe(f.expr),direction:f.direction})));return[...u].sort(((f,g)=>{for(const{Os:y,direction:b}of B){const D=tB(y.evaluate(i,f)),T=tB(y.evaluate(i,g)),M=Hn(D??Mr,T??Mr);if(M!==0)return b==="ascending"?M:-M}return 0}))})(r,e,t);throw new Error(`Unknown stage: ${e._name}`)}function Jg(r){const e=(function(n){for(let i=n.stages.length-1;i>=0;i--){const o=n.stages[i];if(o instanceof Nf)return o.orderings}throw new Error("Pipeline must contain at least one Sort stage")})(r);return(t,n)=>{for(const i of e){const o=tB(Fe(i.expr).evaluate({serializer:r.serializer},t)),u=tB(Fe(i.expr).evaluate({serializer:r.serializer},n)),B=Hn(o||Mr,u||Mr);if(B!==0)return i.direction==="ascending"?B:-B}return 0}}function lg(r){for(let e=r.stages.length-1;e>=0;e--){const t=r.stages[e];if(t instanceof fu)return{limit:t.limit}}}/**
2210 * @license
2211 * Copyright 2017 Google LLC
2212 *
2213 * Licensed under the Apache License, Version 2.0 (the "License");
vendor: 13,700 bytes, lines 2214-2288
2214 * you may not use this file except in compliance with the License.
2215 * You may obtain a copy of the License at
2216 *
2217 *   http://www.apache.org/licenses/LICENSE-2.0
2218 *
2219 * Unless required by applicable law or agreed to in writing, software
2220 * distributed under the License is distributed on an "AS IS" BASIS,
2221 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2222 * See the License for the specific language governing permissions and
2223 * limitations under the License.
2224 */class Av{constructor(){this.changes=new Ea((e=>e.toString()),((e,t)=>e.isEqual(t))),this.changesApplied=!1}addEntry(e){this.assertNotApplied(),this.changes.set(e.key,e)}removeEntry(e,t){this.assertNotApplied(),this.changes.set(e,Zt.newInvalidDocument(e).setReadTime(t))}getEntry(e,t){this.assertNotApplied();const n=this.changes.get(t);return n!==void 0?U.resolve(n):this.getFromCache(e,t)}getEntries(e,t){return this.getAllFromCache(e,t)}apply(e){return this.assertNotApplied(),this.changesApplied=!0,this.applyChanges(e)}assertNotApplied(){}}/**
2225 * @license
2226 * Copyright 2017 Google LLC
2227 *
2228 * Licensed under the Apache License, Version 2.0 (the "License");
2229 * you may not use this file except in compliance with the License.
2230 * You may obtain a copy of the License at
2231 *
2232 *   http://www.apache.org/licenses/LICENSE-2.0
2233 *
2234 * Unless required by applicable law or agreed to in writing, software
2235 * distributed under the License is distributed on an "AS IS" BASIS,
2236 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2237 * See the License for the specific language governing permissions and
2238 * limitations under the License.
2239 */class xk{constructor(e){this.serializer=e}setIndexManager(e){this.indexManager=e}addEntry(e,t,n){return oi(e).put(n)}removeEntry(e,t,n){return oi(e).delete((function(o,u){const B=o.path.toArray();return[B.slice(0,B.length-2),B[B.length-2],rf(u),B[B.length-1]]})(t,n))}updateMetadata(e,t){return this.getMetadata(e).next((n=>(n.byteSize+=t,this.Ms(e,n))))}getEntry(e,t){let n=Zt.newInvalidDocument(t);return oi(e).jn({index:jd,range:IDBKeyRange.only(Gc(t))},((i,o)=>{n=this.Ns(t,o)})).next((()=>n))}Ls(e,t){let n={size:0,document:Zt.newInvalidDocument(t)};return oi(e).jn({index:jd,range:IDBKeyRange.only(Gc(t))},((i,o)=>{n={document:this.Ns(t,o),size:sf(o)}})).next((()=>n))}getEntries(e,t){let n=yn();return this.Bs(e,t,((i,o)=>{const u=this.Ns(i,o);n=n.insert(i,u)})).next((()=>n))}getAllEntries(e){let t=yn();return oi(e).jn(((n,i)=>{const o=this.Ns(De.fromSegments(i.prefixPath.concat(i.collectionGroup,i.documentId)),i);t=t.insert(o.key,o)})).next((()=>t))}Us(e,t){let n=yn(),i=new Rt(De.comparator);return this.Bs(e,t,((o,u)=>{const B=this.Ns(o,u);n=n.insert(o,B),i=i.insert(o,sf(u))})).next((()=>({documents:n,ks:i})))}Bs(e,t,n){if(t.isEmpty())return U.resolve();let i=new gt(M_);t.forEach((f=>i=i.add(f)));const o=IDBKeyRange.bound(Gc(i.first()),Gc(i.last())),u=i.getIterator();let B=u.getNext();return oi(e).jn({index:jd,range:o},((f,g,y)=>{const b=De.fromSegments([...g.prefixPath,g.collectionGroup,g.documentId]);for(;B&&M_(B,b)<0;)n(B,null),B=u.getNext();B&&B.isEqual(b)&&(n(B,g),B=u.hasNext()?u.getNext():null),B?y.$n(Gc(B)):y.done()})).next((()=>{for(;B;)n(B,null),B=u.hasNext()?u.getNext():null}))}getDocumentsMatchingQuery(e,t,n,i,o){const u=Wt(t)?ct.fromString(FB(t)):t.path,B=[u.popLast().toArray(),u.lastSegment(),rf(n.readTime),n.documentKey.path.isEmpty()?"":n.documentKey.path.lastSegment()],f=[u.popLast().toArray(),u.lastSegment(),[Number.MAX_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],""];return oi(e).Kn(IDBKeyRange.bound(B,f,!0)).next((g=>{o==null||o.incrementDocumentReadCount(g.length);let y=yn();for(const b of g){const D=this.Ns(De.fromSegments(b.prefixPath.concat(b.collectionGroup,b.documentId)),b);D.isFoundDocument()&&(Tv(t,D)||i.has(D.key))&&(y=y.insert(D.key,D))}return y}))}getAllFromCollectionGroup(e,t,n,i){let o=yn();const u=j_(t,n),B=j_(t,Ts.max());return oi(e).jn({index:uv,range:IDBKeyRange.bound(u,B,!0)},((f,g,y)=>{const b=this.Ns(De.fromSegments(g.prefixPath.concat(g.collectionGroup,g.documentId)),g);o=o.insert(b.key,b),o.size===i&&y.done()})).next((()=>o))}newChangeBuffer(e){return new Ek(this,!!e&&e.trackRemovals)}getSize(e){return this.getMetadata(e).next((t=>t.byteSize))}getMetadata(e){return L_(e).get(Vg).next((t=>(fe(!!t,20021),t)))}Ms(e,t){return L_(e).put(Vg,t)}Ns(e,t){if(t){const n=lk(this.serializer,t);if(!(n.isNoDocument()&&n.version.isEqual(Me.min())))return n}return Zt.newInvalidDocument(e)}}function Nv(r){return new xk(r)}class Ek extends Av{constructor(e,t){super(),this.qs=e,this.trackRemovals=t,this.$s=new Ea((n=>n.toString()),((n,i)=>n.isEqual(i)))}applyChanges(e){const t=[];let n=0,i=new gt(((o,u)=>Ue(o.canonicalString(),u.canonicalString())));return this.changes.forEach(((o,u)=>{const B=this.$s.get(o);if(t.push(this.qs.removeEntry(e,o,B.readTime)),u.isValidDocument()){const f=x_(this.qs.serializer,u);i=i.add(o.path.popLast());const g=sf(f);n+=g-B.size,t.push(this.qs.addEntry(e,o,f))}else if(n-=B.size,this.trackRemovals){const f=x_(this.qs.serializer,u.convertToNoDocument(Me.min()));t.push(this.qs.addEntry(e,o,f))}})),i.forEach((o=>{t.push(this.qs.indexManager.addToCollectionParentIndex(e,o))})),t.push(this.qs.updateMetadata(e,n)),U.waitFor(t)}getFromCache(e,t){return this.qs.Ls(e,t).next((n=>(this.$s.set(t,{size:n.size,readTime:n.document.readTime}),n.document)))}getAllFromCache(e,t){return this.qs.Us(e,t).next((({documents:n,ks:i})=>(i.forEach(((o,u)=>{this.$s.set(o,{size:u,readTime:n.get(o).readTime})})),n)))}}function L_(r){return xn(r,vB)}function oi(r){return xn(r,tf)}function Gc(r){const e=r.path.toArray();return[e.slice(0,e.length-2),e[e.length-2],e[e.length-1]]}function j_(r,e){const t=e.documentKey.path.toArray();return[r,rf(e.readTime),t.slice(0,t.length-2),t.length>0?t[t.length-1]:""]}function M_(r,e){const t=r.path.toArray(),n=e.path.toArray();let i=0;for(let o=0;o<t.length-2&&o<n.length-2;++o)if(i=Ue(t[o],n[o]),i)return i;return i=Ue(t.length,n.length),i||(i=Ue(t[t.length-2],n[n.length-2]),i||Ue(t[t.length-1],n[n.length-1]))}/**
2240 * @license
2241 * Copyright 2017 Google LLC
2242 *
2243 * Licensed under the Apache License, Version 2.0 (the "License");
2244 * you may not use this file except in compliance with the License.
2245 * You may obtain a copy of the License at
2246 *
2247 *   http://www.apache.org/licenses/LICENSE-2.0
2248 *
2249 * Unless required by applicable law or agreed to in writing, software
2250 * distributed under the License is distributed on an "AS IS" BASIS,
2251 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2252 * See the License for the specific language governing permissions and
2253 * limitations under the License.
2254 *//**
2255 * @license
2256 * Copyright 2022 Google LLC
2257 *
2258 * Licensed under the Apache License, Version 2.0 (the "License");
2259 * you may not use this file except in compliance with the License.
2260 * You may obtain a copy of the License at
2261 *
2262 *   http://www.apache.org/licenses/LICENSE-2.0
2263 *
2264 * Unless required by applicable law or agreed to in writing, software
2265 * distributed under the License is distributed on an "AS IS" BASIS,
2266 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2267 * See the License for the specific language governing permissions and
2268 * limitations under the License.
2269 */class _k{constructor(e,t){this.overlayedDocument=e,this.mutatedFields=t}}/**
2270 * @license
2271 * Copyright 2017 Google LLC
2272 *
2273 * Licensed under the Apache License, Version 2.0 (the "License");
2274 * you may not use this file except in compliance with the License.
2275 * You may obtain a copy of the License at
2276 *
2277 *   http://www.apache.org/licenses/LICENSE-2.0
2278 *
2279 * Unless required by applicable law or agreed to in writing, software
2280 * distributed under the License is distributed on an "AS IS" BASIS,
2281 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2282 * See the License for the specific language governing permissions and
2283 * limitations under the License.
2284 */class Iv{constructor(e,t,n,i){this.remoteDocumentCache=e,this.mutationQueue=t,this.documentOverlayCache=n,this.indexManager=i}getDocument(e,t){let n=null;return this.documentOverlayCache.getOverlay(e,t).next((i=>(n=i,this.remoteDocumentCache.getEntry(e,t)))).next((i=>(n!==null&&Xc(n.mutation,i,qs.empty(),xt.now()),i)))}getDocuments(e,t){return this.remoteDocumentCache.getEntries(e,t).next((n=>this.getLocalViewOfDocuments(e,n,Xe()).next((()=>n))))}getLocalViewOfDocuments(e,t,n=Xe()){const i=Us();return this.populateOverlays(e,i,t).next((()=>this.computeViews(e,t,i,n).next((o=>{let u=Bl();return o.forEach(((B,f)=>{u=u.insert(B,f.overlayedDocument)})),u}))))}getOverlayedDocuments(e,t){const n=Us();return this.populateOverlays(e,n,t).next((()=>this.computeViews(e,t,n,Xe())))}populateOverlays(e,t,n){const i=[];return n.forEach((o=>{t.has(o)||i.push(o)})),this.documentOverlayCache.getOverlays(e,i).next((o=>{o.forEach(((u,B)=>{t.set(u,B)}))}))}computeViews(e,t,n,i){let o=yn();const u=Wc(),B=(function(){return Wc()})();return t.forEach(((f,g)=>{const y=n.get(g.key);i.has(g.key)&&(y===void 0||y.mutation instanceof Ai)?o=o.insert(g.key,g):y!==void 0?(u.set(g.key,y.mutation.getFieldMask()),Xc(y.mutation,g,y.mutation.getFieldMask(),xt.now())):u.set(g.key,qs.empty())})),this.recalculateAndSaveOverlays(e,o).next((f=>(f.forEach(((g,y)=>u.set(g,y))),t.forEach(((g,y)=>B.set(g,new _k(y,u.get(g)??null)))),B)))}recalculateAndSaveOverlays(e,t){const n=Wc();let i=new Rt(((u,B)=>u-B)),o=Xe();return this.mutationQueue.getAllMutationBatchesAffectingDocumentKeys(e,t).next((u=>{for(const B of u)B.keys().forEach((f=>{const g=t.get(f);if(g===null)return;let y=n.get(f)||qs.empty();y=B.applyToLocalView(g,y),n.set(f,y);const b=(i.get(B.batchId)||Xe()).add(f);i=i.insert(B.batchId,b)}))})).next((()=>{const u=[],B=i.getReverseIterator();for(;B.hasNext();){const f=B.getNext(),g=f.key,y=f.value,b=mD();y.forEach((D=>{if(!o.has(D)){const T=W1(t.get(D),n.get(D));T!==null&&b.set(D,T),o=o.add(D)}})),u.push(this.documentOverlayCache.saveOverlays(e,g,b))}return U.waitFor(u)})).next((()=>n))}recalculateAndSaveOverlaysForDocumentKeys(e,t){return this.remoteDocumentCache.getEntries(e,t).next((n=>this.recalculateAndSaveOverlays(e,n)))}getDocumentsMatchingQuery(e,t,n,i){return Wt(t)?this.getDocumentsMatchingPipeline(e,t,n,i):rS(t)?this.getDocumentsMatchingDocumentQuery(e,t.path):aS(t)?this.getDocumentsMatchingCollectionGroupQuery(e,t,n,i):this.getDocumentsMatchingCollectionQuery(e,t,n,i)}getNextDocuments(e,t,n,i){return this.remoteDocumentCache.getAllFromCollectionGroup(e,t,n,i).next((o=>{const u=i-o.size>0?this.documentOverlayCache.getOverlaysForCollectionGroup(e,t,n.largestBatchId,i-o.size):U.resolve(Us());let B=hu,f=o;return u.next((g=>U.forEach(g,((y,b)=>(B<b.largestBatchId&&(B=b.largestBatchId),o.get(y)?U.resolve():this.remoteDocumentCache.getEntry(e,y).next((D=>{f=f.insert(y,D)}))))).next((()=>this.populateOverlays(e,g,o))).next((()=>this.computeViews(e,f,g,Xe()))).next((y=>({batchId:B,changes:fD(y)})))))}))}getDocumentsMatchingDocumentQuery(e,t){return this.getDocument(e,new De(t)).next((n=>{let i=Bl();return n.isFoundDocument()&&(i=i.insert(n.key,n)),i}))}getDocumentsMatchingCollectionGroupQuery(e,t,n,i){const o=t.collectionGroup;let u=Bl();return this.indexManager.getCollectionParents(e,o).next((B=>U.forEach(B,(f=>{const g=(function(b,D){return new xf(D,null,b.explicitOrderBy.slice(),b.filters.slice(),b.limit,b.limitType,b.startAt,b.endAt)})(t,f.child(o));return this.getDocumentsMatchingCollectionQuery(e,g,n,i).next((y=>{y.forEach(((b,D)=>{u=u.insert(b,D)}))}))})).next((()=>u))))}getDocumentsMatchingCollectionQuery(e,t,n,i){let o;return this.documentOverlayCache.getOverlaysForCollection(e,t.path,n.largestBatchId).next((u=>(o=u,this.remoteDocumentCache.getDocumentsMatchingQuery(e,t,n,o,i)))).next((u=>this.retrieveMatchingLocalDocuments(o,u,(B=>Ef(t,B)))))}getDocumentsMatchingPipeline(e,t,n,i){if(ma(t)==="collection_group"){const o=GC(t);let u=Bl();return this.indexManager.getCollectionParents(e,o).next((B=>U.forEach(B,(f=>{const g=(function(b,D){const T=b.stages.map((M=>M instanceof PB?new MB(D.canonicalString(),{}):M));return new Jn(b.serializer,T)})(t,f.child(o));return this.getDocumentsMatchingPipeline(e,g,n,i).next((y=>{y.forEach(((b,D)=>{u=u.insert(b,D)}))}))})).next((()=>u))))}{let o;return this.getOverlaysForPipeline(e,t,n.largestBatchId).next((u=>{switch(o=u,ma(t)){case"collection":return this.remoteDocumentCache.getDocumentsMatchingQuery(e,t,n,o,i);case"documents":let B=Xe();for(const f of Wd(t))B=B.add(De.fromPath(f));return this.remoteDocumentCache.getEntries(e,B);case"database":return this.remoteDocumentCache.getAllEntries(e);default:throw new ve("invalid-argument",`Invalid pipeline source to execute offline: ${pa(t)}`)}})).next((u=>this.retrieveMatchingLocalDocuments(o,u,(B=>Pf(t,B)))))}}retrieveMatchingLocalDocuments(e,t,n){e.forEach(((o,u)=>{const B=u.getKey();t.get(B)===null&&(t=t.insert(B,Zt.newInvalidDocument(B)))}));let i=Bl();return t.forEach(((o,u)=>{const B=e.get(o);B!==void 0&&Xc(B.mutation,u,qs.empty(),xt.now()),n(u)&&(i=i.insert(o,u))})),i}getOverlaysForPipeline(e,t,n){switch(ma(t)){case"collection":return this.documentOverlayCache.getOverlaysForCollection(e,ct.fromString(FB(t)),n);case"collection_group":throw new ve("invalid-argument",`Unexpected collection group pipeline: ${pa(t)}`);case"documents":return this.documentOverlayCache.getOverlays(e,Wd(t).map((i=>De.fromPath(i))));case"database":return this.documentOverlayCache.getAllOverlays(e,n);default:throw new ve("invalid-argument",`Failed to get overlays for pipeline: ${pa(t)}`)}}}/**
2285 * @license
2286 * Copyright 2020 Google LLC
2287 *
2288 * Licensed under the Apache License, Version 2.0 (the "License");
2289 * you may not use this file except in compliance with the License.
2290 * You may obtain a copy of the License at
2291 *
2292 *   http://www.apache.org/licenses/LICENSE-2.0
2293 *
2294 * Unless required by applicable law or agreed to in writing, software
2295 * distributed under the License is distributed on an "AS IS" BASIS,
2296 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2297 * See the License for the specific language governing permissions and
2298 * limitations under the License.
2299 */class Dk{constructor(e){this.serializer=e,this.Ks=new Map,this.Ws=new Map}getBundleMetadata(e,t){return U.resolve(this.Ks.get(t))}saveBundleMetadata(e,t){return this.Ks.set(t.id,(function(i){return{id:i.id,version:i.version,createTime:Xn(i.createTime)}})(t)),U.resolve()}getNamedQuery(e,t){return U.resolve(this.Ws.get(t))}saveNamedQuery(e,t){return this.Ws.set(t.name,(function(i){return{name:i.name,query:xv(i.bundledQuery),readTime:Xn(i.readTime)}})(t)),U.resolve()}}/**
2300 * @license
2301 * Copyright 2022 Google LLC
2302 *
2303 * Licensed under the Apache License, Version 2.0 (the "License");
2304 * you may not use this file except in compliance with the License.
2305 * You may obtain a copy of the License at
2306 *
2307 *   http://www.apache.org/licenses/LICENSE-2.0
2308 *
2309 * Unless required by applicable law or agreed to in writing, software
2310 * distributed under the License is distributed on an "AS IS" BASIS,
2311 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2312 * See the License for the specific language governing permissions and
2313 * limitations under the License.
2314 */class vk{constructor(){this.overlays=new Rt(De.comparator),this.Qs=new Map}getOverlay(e,t){return U.resolve(this.overlays.get(t))}getOverlays(e,t){const n=Us();return U.forEach(t,(i=>this.getOverlay(e,i).next((o=>{o!==null&&n.set(i,o)})))).next((()=>n))}getAllOverlays(e,t){const n=Us();return this.overlays.forEach(((i,o)=>{o.largestBatchId>t&&n.set(i,o)})),U.resolve(n)}saveOverlays(e,t,n){return n.forEach(((i,o)=>{this.Yr(e,t,o)})),U.resolve()}removeOverlaysForBatchId(e,t,n){const i=this.Qs.get(n);return i!==void 0&&(i.forEach((o=>this.overlays=this.overlays.remove(o))),this.Qs.delete(n)),U.resolve()}getOverlaysForCollection(e,t,n){const i=Us(),o=t.length+1,u=new De(t.child("")),B=this.overlays.getIteratorFrom(u);for(;B.hasNext();){const f=B.getNext().value,g=f.getKey();if(!t.isPrefixOf(g.path))break;g.path.length===o&&f.largestBatchId>n&&i.set(f.getKey(),f)}return U.resolve(i)}getOverlaysForCollectionGroup(e,t,n,i){let o=new Rt(((g,y)=>g-y));const u=this.overlays.getIterator();for(;u.hasNext();){const g=u.getNext().value;if(g.getKey().getCollectionGroup()===t&&g.largestBatchId>n){let y=o.get(g.largestBatchId);y===null&&(y=Us(),o=o.insert(g.largestBatchId,y)),y.set(g.getKey(),g)}}const B=Us(),f=o.getIterator();for(;f.hasNext()&&(f.getNext().value.forEach(((g,y)=>B.set(g,y))),!(B.size()>=i)););return U.resolve(B)}Yr(e,t,n){const i=this.overlays.get(n.key);if(i!==null){const u=this.Qs.get(i.largestBatchId).delete(n.key);this.Qs.set(i.largestBatchId,u)}this.overlays=this.overlays.insert(n.key,new YC(t,n));let o=this.Qs.get(t);o===void 0&&(o=Xe(),this.Qs.set(t,o)),this.Qs.set(t,o.add(n.key))}}/**
2315 * @license
2316 * Copyright 2024 Google LLC
2317 *
2318 * Licensed under the Apache License, Version 2.0 (the "License");
2319 * you may not use this file except in compliance with the License.
2320 * You may obtain a copy of the License at
2321 *
2322 *   http://www.apache.org/licenses/LICENSE-2.0
2323 *
2324 * Unless required by applicable law or agreed to in writing, software
2325 * distributed under the License is distributed on an "AS IS" BASIS,
2326 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2327 * See the License for the specific language governing permissions and
2328 * limitations under the License.
2329 */class wk{constructor(){this.sessionToken=qt.EMPTY_BYTE_STRING}getSessionToken(e){return U.resolve(this.sessionToken)}setSessionToken(e,t){return this.sessionToken=t,U.resolve()}}/**
2330 * @license
2331 * Copyright 2017 Google LLC
2332 *
2333 * Licensed under the Apache License, Version 2.0 (the "License");
2334 * you may not use this file except in compliance with the License.
2335 * You may obtain a copy of the License at
2336 *
2337 *   http://www.apache.org/licenses/LICENSE-2.0
2338 *
2339 * Unless required by applicable law or agreed to in writing, softw
2339are
2340 * distributed under the License is distributed on an "AS IS" BASIS,
2341 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2342 * See the License for the specific language governing permissions and
2343 * limitations under the License.
2344 */class ZC{constructor(){this.Gs=new gt(Tn.zs),this.js=new gt(Tn.Hs)}isEmpty(){return this.Gs.isEmpty()}addReference(e,t){const n=new Tn(e,t);this.Gs=this.Gs.add(n),this.js=this.js.add(n)}Js(e,t){e.forEach((n=>this.addReference(n,t)))}removeReference(e,t){this.Ys(new Tn(e,t))}Zs(e,t){e.forEach((n=>this.removeReference(n,t)))}Xs(e){const t=new De(new ct([])),n=new Tn(t,e),i=new Tn(t,e+1),o=[];return this.js.forEachInRange([n,i],(u=>{this.Ys(u),o.push(u.key)})),o}e_(){this.Gs.forEach((e=>this.Ys(e)))}Ys(e){this.Gs=this.Gs.delete(e),this.js=this.js.delete(e)}t_(e){const t=new De(new ct([])),n=new Tn(t,e),i=new Tn(t,e+1);let o=Xe();return this.js.forEachInRange([n,i],(u=>{o=o.add(u.key)})),o}containsKey(e){const t=new Tn(e,0),n=this.Gs.firstAfterOrEqual(t);return n!==null&&e.isEqual(n.key)}}class Tn{constructor(e,t){this.key=e,this.n_=t}static zs(e,t){return De.comparator(e.key,t.key)||Ue(e.n_,t.n_)}static Hs(e,t){return Ue(e.n_,t.n_)||De.comparator(e.key,t.key)}}/**
2345 * @license
2346 * Copyright 2017 Google LLC
2347 *
2348 * Licensed under the Apache License, Version 2.0 (the "License");
2349 * you may not use this file except in compliance with the License.
2350 * You may obtain a copy of the License at
2351 *
2352 *   http://www.apache.org/licenses/LICENSE-2.0
2353 *
2354 * Unless required by applicable law or agreed to in writing, software
2355 * distributed under the License is distributed on an "AS IS" BASIS,
2356 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2357 * See the License for the specific language governing permissions and
2358 * limitations under the License.
2359 */class Tk{constructor(e,t){this.indexManager=e,this.referenceDelegate=t,this.mutationQueue=[],this.Qr=1,this.r_=new gt(Tn.zs)}checkEmpty(e){return U.resolve(this.mutationQueue.length===0)}addMutationBatch(e,t,n,i){const o=this.Qr;this.Qr++,this.mutationQueue.length>0&&this.mutationQueue[this.mutationQueue.length-1];const u=new UC(o,t,n,i);this.mutationQueue.push(u);for(const B of i)this.r_=this.r_.add(new Tn(B.key,o)),this.indexManager.addToCollectionParentIndex(e,B.key.path.popLast());return U.resolve(u)}lookupMutationBatch(e,t){return U.resolve(this.i_(t))}getNextMutationBatchAfterBatchId(e,t){const n=t+1,i=this.s_(n),o=i<0?0:i;return U.resolve(this.mutationQueue.length>o?this.mutationQueue[o]:null)}getHighestUnacknowledgedBatchId(){return U.resolve(this.mutationQueue.length===0?xl:this.Qr-1)}getAllMutationBatches(e){return U.resolve(this.mutationQueue.slice())}getAllMutationBatchesAffectingDocumentKey(e,t){const n=new Tn(t,0),i=new Tn(t,Number.POSITIVE_INFINITY),o=[];return this.r_.forEachInRange([n,i],(u=>{const B=this.i_(u.n_);o.push(B)})),U.resolve(o)}getAllMutationBatchesAffectingDocumentKeys(e,t){let n=new gt(Ue);return t.forEach((i=>{const o=new Tn(i,0),u=new Tn(i,Number.POSITIVE_INFINITY);this.r_.forEachInRange([o,u],(B=>{n=n.add(B.n_)}))})),U.resolve(this.__(n))}getAllMutationBatchesAffectingQuery(e,t){const n=t.path,i=n.length+1;let o=n;De.isDocumentKey(o)||(o=o.child(""));const u=new Tn(new De(o),0);let B=new gt(Ue);return this.r_.forEachWhile((f=>{const g=f.key.path;return!!n.isPrefixOf(g)&&(g.length===i&&(B=B.add(f.n_)),!0)}),u),U.resolve(this.__(B))}__(e){const t=[];return e.forEach((n=>{const i=this.i_(n);i!==null&&t.push(i)})),t}removeMutationBatch(e,t){fe(this.o_(t.batchId,"removed")===0,55003),this.mutationQueue.shift();let n=this.r_;return U.forEach(t.mutations,(i=>{const o=new Tn(i.key,t.batchId);return n=n.delete(o),this.referenceDelegate.markPotentiallyOrphaned(e,i.key)})).next((()=>{this.r_=n}))}jr(e){}containsKey(e,t){const n=new Tn(t,0),i=this.r_.firstAfterOrEqual(n);return U.resolve(t.isEqual(i&&i.key))}performConsistencyCheck(e){return this.mutationQueue.length,U.resolve()}o_(e,t){return this.s_(e)}s_(e){return this.mutationQueue.length===0?0:e-this.mutationQueue[0].batchId}i_(e){const t=this.s_(e);return t<0||t>
vendor: 7,105 bytes, lines 2359-2404
2359=this.mutationQueue.length?null:this.mutationQueue[t]}}/**
2360 * @license
2361 * Copyright 2017 Google LLC
2362 *
2363 * Licensed under the Apache License, Version 2.0 (the "License");
2364 * you may not use this file except in compliance with the License.
2365 * You may obtain a copy of the License at
2366 *
2367 *   http://www.apache.org/licenses/LICENSE-2.0
2368 *
2369 * Unless required by applicable law or agreed to in writing, software
2370 * distributed under the License is distributed on an "AS IS" BASIS,
2371 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2372 * See the License for the specific language governing permissions and
2373 * limitations under the License.
2374 */class Ak{constructor(e){this.a_=e,this.docs=(function(){return new Rt(De.comparator)})(),this.size=0}setIndexManager(e){this.indexManager=e}addEntry(e,t){const n=t.key,i=this.docs.get(n),o=i?i.size:0,u=this.a_(t);return this.docs=this.docs.insert(n,{document:t.mutableCopy(),size:u}),this.size+=u-o,this.indexManager.addToCollectionParentIndex(e,n.path.popLast())}removeEntry(e){const t=this.docs.get(e);t&&(this.docs=this.docs.remove(e),this.size-=t.size)}getEntry(e,t){const n=this.docs.get(t);return U.resolve(n?n.document.mutableCopy():Zt.newInvalidDocument(t))}getEntries(e,t){let n=yn();return t.forEach((i=>{const o=this.docs.get(i);n=n.insert(i,o?o.document.mutableCopy():Zt.newInvalidDocument(i))})),U.resolve(n)}getAllEntries(e){let t=yn();return this.docs.forEach(((n,i)=>{t=t.insert(n,i.document)})),U.resolve(t)}getDocumentsMatchingQuery(e,t,n,i){let o,u;Wt(t)?(o=ct.fromString(FB(t)),u=y=>Pf(t,y)):(o=t.path,u=y=>Ef(t,y));let B=yn();const f=new De(o.child("__id-9223372036854775808__")),g=this.docs.getIteratorFrom(f);for(;g.hasNext();){const{key:y,value:{document:b}}=g.getNext();if(!o.isPrefixOf(y.path))break;y.path.length>o.length+1||xC(cD(b),n)<=0||(i.has(b.key)||u(b))&&(B=B.insert(b.key,b.mutableCopy()))}return U.resolve(B)}getAllFromCollectionGroup(e,t,n,i){Te(9500)}u_(e,t){return U.forEach(this.docs,(n=>t(n)))}newChangeBuffer(e){return new Nk(this)}getSize(e){return U.resolve(this.size)}}class Nk extends Av{constructor(e){super(),this.qs=e}applyChanges(e){const t=[];return this.changes.forEach(((n,i)=>{i.isValidDocument()?t.push(this.qs.addEntry(e,i)):this.qs.removeEntry(n)})),U.waitFor(t)}getFromCache(e,t){return this.qs.getEntry(e,t)}getAllFromCache(e,t){return this.qs.getEntries(e,t)}}/**
2375 * @license
2376 * Copyright 2017 Google LLC
2377 *
2378 * Licensed under the Apache License, Version 2.0 (the "License");
2379 * you may not use this file except in compliance with the License.
2380 * You may obtain a copy of the License at
2381 *
2382 *   http://www.apache.org/licenses/LICENSE-2.0
2383 *
2384 * Unless required by applicable law or agreed to in writing, software
2385 * distributed under the License is distributed on an "AS IS" BASIS,
2386 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2387 * See the License for the specific language governing permissions and
2388 * limitations under the License.
2389 */class Ik{constructor(e){this.persistence=e,this.c_=new Ea((t=>Rf(t)),HC),this.lastRemoteSnapshotVersion=Me.min(),this.highestTargetId=0,this.l_=0,this.E_=new ZC,this.targetCount=0,this.h_=xa.ys()}forEachTarget(e,t){return this.c_.forEach(((n,i)=>t(i))),U.resolve()}getLastRemoteSnapshotVersion(e){return U.resolve(this.lastRemoteSnapshotVersion)}getHighestSequenceNumber(e){return U.resolve(this.l_)}allocateTargetId(e){return this.highestTargetId=this.h_.next(),U.resolve(this.highestTargetId)}setTargetsMetadata(e,t,n){return n&&(this.lastRemoteSnapshotVersion=n),t>this.l_&&(this.l_=t),U.resolve()}Ss(e){this.c_.set(e.target,e);const t=e.targetId;t>this.highestTargetId&&(this.h_=new xa(t),this.highestTargetId=t),e.sequenceNumber>this.l_&&(this.l_=e.sequenceNumber)}addTargetData(e,t){return this.Ss(t),this.targetCount+=1,U.resolve()}updateTargetData(e,t){return this.Ss(t),U.resolve()}removeTargetData(e,t){return this.c_.delete(t.target),this.E_.Xs(t.targetId),this.targetCount-=1,U.resolve()}removeTargets(e,t,n){let i=0;const o=[];return this.c_.forEach(((u,B)=>{B.sequenceNumber<=t&&n.get(B.targetId)===null&&(this.c_.delete(u),o.push(this.removeMatchingKeysForTargetId(e,B.targetId)),i++)})),U.waitFor(o).next((()=>i))}getTargetCount(e){return U.resolve(this.targetCount)}getTargetData(e,t){const n=this.c_.get(t)||null;return U.resolve(n)}addMatchingKeys(e,t,n){return this.E_.Js(t,n),U.resolve()}removeMatchingKeys(e,t,n){this.E_.Zs(t,n);const i=this.persistence.referenceDelegate,o=[];return i&&t.forEach((u=>{o.push(i.markPotentiallyOrphaned(e,u))})),U.waitFor(o)}removeMatchingKeysForTargetId(e,t){return this.E_.Xs(t),U.resolve()}getMatchingKeysForTargetId(e,t){const n=this.E_.t_(t);return U.resolve(n)}containsKey(e,t){return U.resolve(this.E_.containsKey(t))}}/**
2390 * @license
2391 * Copyright 2017 Google LLC
2392 *
2393 * Licensed under the Apache License, Version 2.0 (the "License");
2394 * you may not use this file except in compliance with the License.
2395 * You may obtain a copy of the License at
2396 *
2397 *   http://www.apache.org/licenses/LICENSE-2.0
2398 *
2399 * Unless required by applicable law or agreed to in writing, software
2400 * distributed under the License is distributed on an "AS IS" BASIS,
2401 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2402 * See the License for the specific language governing permissions and
2403 * limitations under the License.
2404 */class WC{constructor(e,t){this.T_={},this.overlays={},this.P_=new is(0),this.R_=!1,this.R_=!0,this.I_=new wk,this.referenceDelegate=e(this),this.A_=new Ik(this),this.indexManager=new pk,this.remoteDocumentCache=(function(i){return new Ak(i)})((n=>this.referenceDelegate.V_(n))),this.serializer=new yv(t),this.d_=new Dk(this.serializer)}start(){return Promise.resolve()}shutdown(){return this.R_=!1,Promise.resolve()}get started(){return this.R_}setDatabaseDeletedListener(){}setNetworkEnabled(){}getIndexManager(e){return this.indexManager}getDocumentOverlayCache(e){let t=this.overlays[e.toKey()];return t||(t=new vk,this.overlays[e.toKey()]=t),t}getMutationQueue(e,t){let n=this.T_[e.toKey()];return n||(n=new Tk(t,this.referenceDelegate),this.T_[e.toKey()]=n),n}getGlobalsCache(){return this.I_}getTargetCache(){return this.A_}getRemoteDocumentCache(){return this.remoteDocumentCache}getBundleCache(){return this.d_}runTransaction(e,t,n){Be("MemoryPersistence","Starting transaction:",e);const i=new Sk(this.P_.next());return this.referenceDelegate.f_(),n(i).next((o=>this.referenceDelegate.m_(i).next((()=>o)))).toPromise().then((o=>(i.raiseOnCommittedEvent(),o)))}p_(e,t){return U.or(Object.values(this.T_).map((n=>()=>n.containsKey(e,t))))}}class Sk extends PD{constructor(e){super(),this.currentSequenceNumber=e}}class Vf{constructor(e){this.persistence=e,this.g_=new ZC,this.y_=null}static w_(e){return new Vf(e)}get b_(){if(this.y_)return this.y_;throw Te(60996)}addReference(e,t,n){return this.g_.addReference(n,t),this.b_.delete(n.toString()),U.resolve()}removeReference(e,t,n){return this.g_.removeReference(n,t),this.b_.add(n.toString()),U.resolve()}markPotentiallyOrphaned(e,t){return this.b_.add(t.toString()),U.resolve()}
2404removeTarget(e,t){this.g_.Xs(t.targetId).forEach((i=>this.b_.add(i.toString())));const n=this.persistence.getTargetCache();return n.getMatchingKeysForTargetId(e,t.targetId).next((i=>{i.forEach((o=>this.b_.add(o.toString())))})).next((()=>n.removeTargetData(e,t)))}f_(){this.y_=new Set}m_(e){const t=this.persistence.getRemoteDocumentCache().newChangeBuffer();return U.forEach(this.b_,(n=>{const i=De.fromPath(n);return this.v_(e,i).next((o=>{o||t.removeEntry(i,Me.min())}))})).next((()=>(this.y_=null,t.apply(e))))}updateLimboDocument(e,t){return this.v_(e,t).next((n=>{n?this.b_.delete(t.toString()):this.b_.add(t.toString())}))}V_(e){return 0}v_(e,t){return U.or([()=>U.resolve(this.g_.containsKey(t)),()=>this.persistence.getTargetCache().containsKey(e,t),()=>this.persistence.p_(e,t)])}}class lf{constructor(e,t){this.persistence=e,this.S_=new Ea((n=>Gn(n.path)),((n,i)=>n.isEqual(i))),this.garbageCollector=HD(this,t)}static w_(e,t){return new lf(e,t)}f_(){}m_(e){return U.resolve()}forEachTarget(e,t){return this.persistence.getTargetCache().forEachTarget(e,t)}rr(e){const t=this.xs(e);return this.persistence.getTargetCache().getTargetCount(e).next((n=>t.next((i=>n+i))))}xs(e){let t=0;return this.ir(e,(n=>{t++})).next((()=>t))}ir(e,t){return U.forEach(this.S_,((n,i)=>this.Fs(e,n,i).next((o=>o?U.resolve():t(i)))))}removeTargets(e,t,n){return this.persistence.getTargetCache().removeTargets(e,t,n)}removeOrphanedDocuments(e,t){let n=0;const i=this.persistence.getRemoteDocumentCache(),o=i.newChangeBuffer();return i.u_(e,(u=>this.Fs(e,u,t).next((B=>{B||(n++,o.removeEntry(u,Me.min()))})))).next((()=>o.apply(e))).next((()=>n))}markPotentiallyOrphaned(e,t){return this.S_.set(t,e.currentSequenceNumber),U.resolve()}removeTarget(e,t){const n=t.withSequenceNumber(e.currentSequenceNumber);return this.persistence.getTargetCache().updateTargetData(e,n)}addReference(e,t,n){return this.S_.set(n,e.currentSequenceNumber),U.resolve()}removeReference(e,t,n){return this.S_.set(n,e.currentSequenceNumber),U.resolve()}updateLimboDocument(e,t){return this.S_.set(t,e.currentSequenceNumber),U.resolve()}V_(e){let t=e.key.toString().length;return e.isFoundDocument()&&(t+=Id(e.data.value)),t}Fs(e,t,n){return U.or([()=>this.persistence.p_(e,t),()=>this.persistence.getTargetCache().containsKey(e,t),()=>{const i=this.S_.get(t);return U.resolve(i!==void 0&&i>n)}])}getCacheSize(e){return this.persistence.getRemoteDocumentCache().getSize(e)}}/**
2405 * @license
2406 * Copyright 2020 Google LLC
2407 *
2408 * Licensed under the Apache License, Version 2.0 (the "License");
2409 * you may not use this file except in compliance with the License.
2410 * You may obtain a copy of the License at
2411 *
2412 *   http://www.apache.org/licenses/LICENSE-2.0
2413 *
2414 * Unless required by applicable law or agreed to in writing, software
2415 * distributed under the License is distributed on an "AS IS" BASIS,
2416 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2417 * See the License for the specific language governing permissions and
2418 * limitations under the License.
2419 */class Rk{constructor(e){this.serializer=e}Mn(e,t,n,i){const o=new Df("createOrUpgrade",t);n<1&&i>=1&&((function(f){f.createObjectStore(GB)})(e),(function(f){f.createObjectStore(DB,{keyPath:jO}),f.createObjectStore(ir,{keyPath:y_,autoIncrement:!0}).createIndex(Cl,b_,{unique:!0}),f.createObjectStore(mu)})(e),P_(e),(function(f){f.createObjectStore(cl)})(e));let u=U.resolve();return n<3&&i>=3&&(n!==0&&((function(f){f.deleteObjectStore(gu),f.deleteObjectStore(pu),f.deleteObjectStore(Dl)})(e),P_(e)),u=u.next((()=>(function(f){const g=f.store(Dl),y={highestTargetId:0,highestListenSequenceNumber:0,lastRemoteSnapshotVersion:Me.min().toTimestamp(),targetCount:0};return g.put(nf,y)})(o)))),n<4&&i>=4&&(n!==0&&(u=u.next((()=>(function(f,g){return g.store(ir).Kn().next((b=>{f.deleteObjectStore(ir),f.createObjectStore(ir,{keyPath:y_,autoIncrement:!0}).createIndex(Cl,b_,{unique:!0});const D=g.store(ir),T=b.map((M=>D.put(M)));return U.waitFor(T)}))})(e,o)))),u=u.next((()=>{(function(f){f.createObjectStore(Cu,{keyPath:qO})})(e)}))),n<5&&i>=5&&(u=u.next((()=>
vendor: 11,980 bytes, lines 2419-2423
2419this.D_(o)))),n<6&&i>=6&&(u=u.next((()=>((function(f){f.createObjectStore(vB)})(e),this.x_(o))))),n<7&&i>=7&&(u=u.next((()=>this.C_(o)))),n<8&&i>=8&&(u=u.next((()=>this.F_(e,o)))),n<9&&i>=9&&(u=u.next((()=>{(function(f){f.objectStoreNames.contains("remoteDocumentChanges")&&f.deleteObjectStore("remoteDocumentChanges")})(e)}))),n<10&&i>=10&&(u=u.next((()=>this.O_(o)))),n<11&&i>=11&&(u=u.next((()=>{(function(f){f.createObjectStore(Of,{keyPath:KO})})(e),(function(f){f.createObjectStore(kf,{keyPath:JO})})(e)}))),n<12&&i>=12&&(u=u.next((()=>{(function(f){const g=f.createObjectStore(Lf,{keyPath:ek});g.createIndex(Gg,tk,{unique:!1}),g.createIndex(dv,nk,{unique:!1})})(e)}))),n<13&&i>=13&&(u=u.next((()=>(function(f){const g=f.createObjectStore(tf,{keyPath:PO});g.createIndex(jd,VO),g.createIndex(uv,FO)})(e))).next((()=>this.M_(e,o))).next((()=>e.deleteObjectStore(cl)))),n<14&&i>=14&&(u=u.next((()=>this.N_(e,o)))),n<15&&i>=15&&(u=u.next((()=>(function(f){f.createObjectStore(KC,{keyPath:QO,autoIncrement:!0}).createIndex(Fg,YO,{unique:!1}),f.createObjectStore(nB,{keyPath:XO}).createIndex(Bv,$O,{unique:!1}),f.createObjectStore(sB,{keyPath:ZO}).createIndex(hv,WO,{unique:!1})})(e)))),n<16&&i>=16&&(u=u.next((()=>{t.objectStore(nB).clear()})).next((()=>{t.objectStore(sB).clear()}))),n<17&&i>=17&&(u=u.next((()=>{(function(f){f.createObjectStore(JC,{keyPath:sk})})(e)}))),n<18&&i>=18&&m1()&&(u=u.next((()=>{t.objectStore(nB).clear()})).next((()=>{t.objectStore(sB).clear()}))),u}x_(e){let t=0;return e.store(cl).jn(((n,i)=>{t+=sf(i)})).next((()=>{const n={byteSize:t};return e.store(vB).put(Vg,n)}))}D_(e){const t=e.store(DB),n=e.store(ir);return t.Kn().next((i=>U.forEach(i,(o=>{const u=IDBKeyRange.bound([o.userId,xl],[o.userId,o.lastAcknowledgedBatchId]);return n.Kn(Cl,u).next((B=>U.forEach(B,(f=>{fe(f.userId===o.userId,18650,"Cannot process batch from unexpected user",{batchId:f.batchId});const g=dl(this.serializer,f);return Cv(e,o.userId,g).next((()=>{}))}))))}))))}C_(e){const t=e.store(gu),n=e.store(cl);return e.store(Dl).get(nf).next((i=>{const o=[];return n.jn(((u,B)=>{const f=new ct(u),g=(function(b){return[0,Gn(b)]})(f);o.push(t.get(g).next((y=>y?U.resolve():(b=>t.put({targetId:0,path:Gn(b),sequenceNumber:i.highestListenSequenceNumber}))(f))))})).next((()=>U.waitFor(o)))}))}F_(e,t){e.createObjectStore(wB,{keyPath:zO});const n=t.store(wB),i=new $C,o=u=>{if(i.add(u)){const B=u.lastSegment(),f=u.popLast();return n.put({collectionId:B,parent:Gn(f)})}};return t.store(cl).jn({zn:!0},((u,B)=>{const f=new ct(u);return o(f.popLast())})).next((()=>t.store(mu).jn({zn:!0},(([u,B,f],g)=>{const y=Or(B);return o(y.popLast())}))))}O_(e){const t=e.store(pu);return t.jn(((n,i)=>{const o=Kc(this.serializer,i),u=bv(this.serializer,o);return t.put(u)}))}M_(e,t){const n=t.store(cl),i=[];return n.jn(((o,u)=>{const B=t.store(tf),f=(function(b){return b.document?new De(ct.fromString(b.document.name).popFirst(5)):b.noDocument?De.fromSegments(b.noDocument.path):b.unknownDocument?De.fromSegments(b.unknownDocument.path):Te(36783)})(u).path.toArray(),g={prefixPath:f.slice(0,f.length-2),collectionGroup:f[f.length-2],documentId:f[f.length-1],readTime:u.readTime||[0,0],unknownDocument:u.unknownDocument,noDocument:u.noDocument,document:u.document,hasCommittedMutations:!!u.hasCommittedMutations};i.push(B.put(g))})).next((()=>U.waitFor(i)))}N_(e,t){const n=t.store(ir),i=Nv(this.serializer),o=new WC(Vf.w_,this.serializer.qr);return n.Kn().next((u=>{const B=new Map;return u.forEach((f=>{let g=B.get(f.userId)??Xe();dl(this.serializer,f).keys().forEach((y=>g=g.add(y))),B.set(f.userId,g)})),U.forEach(B,((f,g)=>{const y=new Vn(g),b=Mf.Kr(this.serializer,y),D=o.getIndexManager(y),T=jf.Kr(y,this.serializer,D,o.referenceDelegate);return new Iv(i,T,b,D).recalculateAndSaveOverlaysForDocumentKeys(new Hg(t,is.yn),f).next()}))}))}}function P_(r){r.createObjectStore(gu,{keyPath:HO}).createIndex(qC,UO,{unique:!0}),r.createObjectStore(pu,{keyPath:"targetId"}).createIndex(cv,GO,{unique:!0}),r.createObjectStore(Dl)}const ui="IndexedDbPersistence",og=18e5,ug=5e3,cg="Failed to obtain exclusive access to the persistence layer. To allow shared access, multi-tab synchronization has to be enabled in all tabs. If you are using `experimentalForceOwningTab:true`, make sure that only one tab has persistence enabled at any given time.",Ok="main";class e0{constructor(e,t,n,i,o,u,B,f,g,y,b=18){if(this.allowTabSynchronization=e,this.persistenceKey=t,this.clientId=n,this.xt=o,this.window=u,this.document=B,this.L_=g,this.B_=y,this.U_=b,this.P_=null,this.R_=!1,this.isPrimary=!1,this.networkEnabled=!0,this.k_=null,this.inForeground=!1,this.q_=null,this.K_=null,this.W_=Number.NEGATIVE_INFINITY,this.Q_=D=>Promise.resolve(),!e0.Je())throw new ve(le.UNIMPLEMENTED,"This platform is either missing IndexedDB or is known to have an incomplete implementation. Offline persistence has been disabled.");this.referenceDelegate=new yk(this,i),this.G_=t+Ok,this.serializer=new yv(f),this.z_=new yi(this.G_,this.U_,new Rk(this.serializer)),this.I_=new ck,this.A_=new Ck(this.referenceDelegate,this.serializer),this.remoteDocumentCache=Nv(this.serializer),this.d_=new uk,this.window&&this.window.localStorage?this.j_=this.window.localStorage:(this.j_=null,y===!1&&sn(ui,"LocalStorage is unavailable. As a result, persistence may not work reliably. In particular enablePersistence() could fail immediately after refreshing the page."))}start(){return this.H_().then((()=>{if(!this.isPrimary&&!this.allowTabSynchronization)throw new ve(le.FAILED_PRECONDITION,cg);return this.J_(),this.Y_(),this.Z_(),this.runTransaction("getHighestListenSequenceNumber","readonly",(e=>this.A_.getHighestSequenceNumber(e)))})).then((e=>{this.P_=new is(e,this.L_)})).then((()=>{this.R_=!0})).catch((e=>(this.z_&&this.z_.close(),Promise.reject(e))))}X_(e){return this.Q_=async t=>{if(this.started)return e(t)},e(this.isPrimary)}setDatabaseDeletedListener(e){this.z_.Ln((async t=>{t.newVersion===null&&await e()}))}setNetworkEnabled(e){this.networkEnabled!==e&&(this.networkEnabled=e,this.xt.enqueueAndForget((async()=>{this.started&&await this.H_()})))}H_(){return this.runTransaction("updateClientMetadataAndTryBecomePrimary","readwrite",(e=>vd(e).put({clientId:this.clientId,updateTimeMs:Date.now(),networkEnabled:this.networkEnabled,inForeground:this.inForeground}).next((()=>{if(this.isPrimary)return this.eo(e).next((t=>{t||(this.isPrimary=!1,this.xt.enqueueRetryable((()=>this.Q_(!1))))}))})).next((()=>this.no(e))).next((t=>this.isPrimary&&!t?this.ro(e).next((()=>!1)):!!t&&this.io(e).next((()=>!0)))))).catch((e=>{if(Ii(e))return Be(ui,"Failed to extend owner lease: ",e),this.isPrimary;if(!this.allowTabSynchronization)throw e;return Be(ui,"Releasing owner lease after error during lease refresh",e),!1})).then((e=>{this.isPrimary!==e&&this.xt.enqueueRetryable((()=>this.Q_(e))),this.isPrimary=e}))}eo(e){return Hc(e).get(Lo).next((t=>U.resolve(this.so(t))))}_o(e){return vd(e).delete(this.clientId)}async oo(){if(this.isPrimary&&!this.ao(this.W_,og)){this.W_=Date.now();const e=await this.runTransaction("maybeGarbageCollectMultiClientState","readwrite-primary",(t=>{const n=xn(t,Cu);return n.Kn().next((i=>{const o=this.uo(i,og),u=i.filter((B=>o.indexOf(B)===-1));return U.forEach(u,(B=>n.delete(B.clientId))).next((()=>u))}))})).catch((()=>[]));if(this.j_)for(const t of e)this.j_.removeItem(this.co(t.clientId))}}Z_(){this.K_=this.xt.enqueueAfterDelay("client_metadata_refresh",4e3,(()=>this.H_().then((()=>this.oo())).then((()=>this.Z_()))))}so(e){return!!e&&e.ownerId===this.clientId}no(e){return this.B_?U.resolve(!0):Hc(e).get(Lo).next((t=>{if(t!==null&&this.ao(t.leaseTimestampMs,ug)&&!this.lo(t.ownerId)){if(this.so(t)&&this.networkEnabled)return!0;if(!this.so(t)){if(!t.allowTabSynchronization)throw new ve(le.FAILED_PRECONDITION,cg);return!1}}return!(!this.networkEnabled||!this.inForeground)||vd(e).Kn().next((n=>this.uo(n,ug).find((i=>{if(this.clientId!==i.clientId){const o=!this.networkEnabled&&i.networkEnabled,u=!this.inForeground&&i.inForeground,B=this.networkEnabled===i.networkEnabled;if(o||u&&B)return!0}return!1}))===void 0))})).next((t=>(this.isPrimary!==t&&Be(ui,`Client ${t?"is":"is not"} eligible for a primary lease.`),t)))}async shutdown(){this.R_=!1,this.Eo(),this.K_&&(this.K_.cancel(),this.K_=null),this.ho(),this.To(),await this.z_.runTransaction("shutdown","readwrite",[GB,Cu],(e=>{const t=new Hg(e,is.yn);return this.ro(t).next((()=>this._o(t)))})),this.z_.close(),this.Po()}uo(e,t){return e.filter((n=>this.ao(n.updateTimeMs,t)&&!this.lo(n.clientId)))}Ro(){return this.runTransaction("getActiveClients","readonly",(e=>vd(e).Kn().next((t=>this.uo(t,og).map((n=>n.clientId))))))}get started(){return this.R_}getGlobalsCache(){return this.I_}getMutationQueue(e,t){return jf.Kr(e,this.serializer,t,this.referenceDelegate)}getTargetCache(){return this.A_}getRemoteDocumentCache(){return this.remoteDocumentCache}getIndexManager(e){return new gk(e,this.serializer.qr.databaseId)}getDocumentOverlayCache(e){return Mf.Kr(this.serializer,e)}getBundleCache(){return this.d_}runTransaction(e,t,n){Be(ui,"Starting transaction:",e);const i=t==="readonly"?"readonly":"readwrite",o=(function(f){return f===18?ik:f===17?gv:f===16?ak:f===15?QC:f===14?pv:f===13?mv:f===12?rk:f===11?fv:void Te(60245)})(this.U_);let u;return this.z_.runTransaction(e,i,o,(B=>(u=new Hg(B,this.P_?this.P_.next():is.yn),t==="readwrite-primary"?this.eo(u).next((f=>!!f||this.no(u))).next((f=>{if(!f)throw sn(`Failed to obtain primary lease for action '${e}'.`),this.isPrimary=!1,this.xt.enqueueRetryable((()=>this.Q_(!1))),new ve(le.FAILED_PRECONDITION,MD);return n(u)})).next((f=>this.io(u).next((()=>f)))):this.Io(u).next((()=>n(u)))))).then((B=>(u.raiseOnCommittedEvent(),B)))}Io(e){return Hc(e).get(Lo).next((t=>{if(t!==null&&this.ao(t.leaseTimestampMs,ug)&&!this.lo(t.ownerId)&&!this.so(t)&&!(this.B_||this.allowTabSynchronization&&t.allowTabSynchronization))throw new ve(le.FAILED_PRECONDITION,cg)}))}io(e){const t={ownerId:this.clientId,allowTabSynchronization:this.allowTabSynchronization,leaseTimestampMs:Date.now()};return Hc(e).put(Lo,t)}static Je(){return yi.Je()}ro(e){const t=Hc(e);return t.get(Lo).next((n=>this.so(n)?(Be(ui,"Releasing primary lease."),t.delete(Lo)):U.resolve()))}ao(e,t){const n=Date.now();return!(e<n-t)&&(!(e>n)||(sn(`Detected an update time that is in the future: ${e} > ${n}`),!1))}J_(){this.document!==null&&typeof this.document.addEventListener=="function"&&(this.q_=()=>{this.xt.enqueueAndForget((()=>(this.inForeground=this.document.visibilityState==="visible",this.H_())))},this.document.addEventListener("visibilitychange",this.q_),this.inForeground=this.document.visibilityState==="visible")}ho(){this.q_&&(this.document.removeEventListener("visibilitychange",this.q_),this.q_=null)}Y_(){var e;typeof((e=this.window)==null?void 0:e.addEventListener)=="function"&&(this.k_=()=>{this.Eo();const t=/(?:Version|Mobile)\/1[456]/;f1()&&(navigator.appVersion.match(t)||navigator.userAgent.match(t))&&this.xt.enterRestrictedMode(!0),this.xt.enqueueAndForget((()=>this.shutdown()))},this.window.addEventListener("pagehide",this.k_))}To(){this.k_&&(this.window.removeEventListener("pagehide",this.k_),this.k_=null)}lo(e){var t;try{const n=((t=this.j_)==null?void 0:t.getItem(this.co(e)))!==null;return Be(ui,`Client '${e}' ${n?"is":"is not"} zombied in LocalStorage`),n}catch(n){return sn(ui,"Failed to get zombied client id.",n),!1}}Eo(){if(this.j_)try{this.j_.setItem(this.co(this.clientId),String(Date.now()))}catch(e){sn("Failed to set zombie client id.",e)}}Po(){if(this.j_)try{this.j_.removeItem(this.co(this.clientId))}catch{}}co(e){return`firestore_zombie_${this.persistenceKey}_${e}`}}function Hc(r){return xn(r,GB)}function vd(r){return xn(r,Cu)}function Sv(r,e){let t=r.projectId;return r.isDefaultDatabase||(t+="."+r.database),"firestore/"+e+"/"+t+"/"}/**
2420 * @license
2421 * Copyright 2017 Google LLC
2422 *
2423 * Licensed under the Apache License, Version 2.0 (the "License");
2424 * you may not use this file except in compliance with the License.
2425 * You may obtain a copy of the License at
2426 *
2427 *   http://www.apache.org/licenses/LICENSE-2.0
2428 *
2429 * Unless required by applicable law or agreed to in writing, software
2430 * distributed under the License is distributed on an "AS IS" BASIS,
2431 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2432 * See the License for the specific language governing permissions and
2433 * limitations under the License.
2434 */class t0{constructor(e,t,n,i){this.targetId=e,this.fromCache=t,this.Ao=n,this.Vo=i}static fo(e,t){let n=Xe(),i=Xe();for(const o of t.docChanges)switch(o.type){case 0:n=n.add(o.doc.key);break;case 1:i=i.add(o.doc.key)}return new t0(e,t.fromCache,n,i)}}/**
2435 * @license
2436 * Copyright 2017 Google LLC
2437 *
2438 * Licensed under the Apache License, Version 2.0 (the "License");
2439 * you may not use this file except in compliance with the License.
2440 * You may obtain a copy of the License at
2441 *
2442 *   http://www.apache.org/licenses/LICENSE-2.0
2443 *
2444 * Unless required by applicable law or agreed to in writing, software
2445 * distributed under the License is distributed on an "AS IS" BASIS,
2446 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2447 * See the License for the specific language governing permissions and
2448 * limitations under the License.
2449 */function kk(r,e){return De.comparator(r.key,e.key)}/**
2450 * @license
2451 * Copyright 2023 Google LLC
2452 *
2453 * Licensed under the Apache License, Version 2.0 (the "License");
2454 * you may not use this file except in compliance with the License.
2455 * You may obtain a copy of the License at
2456 *
2457 *   http://www.apache.org/licenses/LICENSE-2.0
2458 *
2459 * Unless required by applicable law or agreed to in writing, software
2460 * distributed under the License is distributed on an "AS IS" BASIS,
2461 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2462 * See the License for the specific language governing permissions and
2463 * limitations under the License.
2464 */class Lk{constructor(){this._documentReadCount=0}get documentReadCount(){return this._documentReadCount}incrementDocumentReadCount(e){this._documentReadCount+=e}}/**
2465 * @license
2466 * Copyright 2019 Google LLC
2467 *
2468 * Licensed under the Apache License, Version 2.0 (the "License");
2469 * you may not use this file except in compliance with the License.
2470 * You may obtain a copy of the License at
2471 *
2472 *   http://www.apache.org/licenses/LICENSE-2.0
2473 *
2474 * Unless required by applicable law or agreed to in writing, software
2475 * distributed under the License is distributed on an "AS IS" BASIS,
2476 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2477 * See the License for the specific language governing permissions and
2478 * limitations under the License.
2479 */class Rv{constructor(){this.mo=!1,this.po=!1,this.yo=100,this.wo=(function(){return f1()?8:VD(Fd())>0?6:4})()}initialize(e,t){this.bo=e,this.indexManager=t,this.mo=!0}getDocumentsMatchingQuery(e,t,n,i){const o={result:null};return this.vo(e,t).next((u=>{o.result=u})).next((()=>{if(!o.result)return this.So(e,t,i,n).next((u=>{o.result=u}))})).next((()=>{if(o.result)return;const u=new Lk;return this.Do(e,t,u).next((B=>{if(o.result=B,this.po)return this.xo(e,t,u,B.size)}))})).next((()=>o.result))}xo(e,t,n,i){return Wt(t)?U.resolve():n.documentReadCount<this.yo?(Uo()<=ut.DEBUG&&Be("QueryEngine","SDK will not create cache indexes for query:",Zc(t),"since it only creates cache indexes for collection contains","more than or equal to",this.yo,"documents"),U.resolve()):(Uo()<=ut.DEBUG&&Be("QueryEngine","Query:",Zc(t),"scans",n.documentReadCount,"local documents and returns",i,"documents as results."),n.documentReadCount>this.wo*i?(Uo()<=ut.DEBUG&&Be("QueryEngine","The SDK decides to create cache indexes for query:",Zc(t),"as using cache indexes may help improve performance."),this.indexManager.createTargetIndexes(e,ws(t))):U.resolve())}vo(e,t){if(Wt(t))return U.resolve(null);let n=t;if(WE(n))return U.resolve(null);let i=ws(n);return this.indexManager.getIndexType(e,i).next((o=>o===0?null:(n.limit!==null&&o===1&&(n=Og(n,null,"F"),i=ws(n)),this.indexManager.getDocumentsMatchingTarget(e,i).next((u=>{const B=Xe(...u);return this.bo.getDocuments(e,B).next((f=>this.indexManager.getMinOffset(e,i).next((g=>{const y=this.Co(n,f);return this.Fo(n,y,B,g.readTime)?this.vo(e,Og(n,null,"F")):this.Oo(e,y,n,g)}))))})))))}So(e,t,n,i){return(Wt(t)?(function(u){for(const B of u.stages){if(B instanceof fu||B instanceof p_)return!1;if(B instanceof Af){if(B.condition instanceof YD&&B.condition._expr.name==="exists"&&B.condition._expr.params[0]instanceof Nu&&B.condition._expr.params[0].fieldName===su)continue;return!1}}return!0})(t):WE(t))||i.isEqual(Me.min())?U.resolve(null):this.bo.getDocuments(e,n).next((o=>{const u=this.Co(t,o);return this.Fo(t,u,n,i)?U.resolve(null):(Uo()<=ut.DEBUG&&Be("QueryEngine","Re-using previous result from %s to execute query: %s",i.toString(),g_(t)),this.Oo(e,u,t,uD(i,hu)).next((B=>B)))}
vendor: 3,145 bytes, lines 2479-2494
2479))}Co(e,t){let n,i;return Wt(e)?(n=new gt(kk),i=o=>Pf(e,o)):(n=new gt(DC(e)),i=o=>Ef(e,o)),t.forEach(((o,u)=>{i(u)&&(n=n.add(u))})),n}Fo(e,t,n,i){if(Wt(e))return(function(B){return B.stages.some((f=>f instanceof fu||f instanceof p_))})(e);if(e.limit===null)return!1;if(n.size!==t.size)return!0;const o=e.limitType==="F"?t.last():t.first();return!!o&&(o.hasPendingWrites||o.version.compareTo(i)>0)}Do(e,t,n){return Uo()<=ut.DEBUG&&Be("QueryEngine","Using full collection scan to execute query:",g_(t)),this.bo.getDocumentsMatchingQuery(e,t,Ts.min(),n)}Oo(e,t,n,i){return this.bo.getDocumentsMatchingQuery(e,n,i).next((o=>(t.forEach((u=>{o=o.insert(u.key,u)})),o)))}}/**
2480 * @license
2481 * Copyright 2020 Google LLC
2482 *
2483 * Licensed under the Apache License, Version 2.0 (the "License");
2484 * you may not use this file except in compliance with the License.
2485 * You may obtain a copy of the License at
2486 *
2487 *   http://www.apache.org/licenses/LICENSE-2.0
2488 *
2489 * Unless required by applicable law or agreed to in writing, software
2490 * distributed under the License is distributed on an "AS IS" BASIS,
2491 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2492 * See the License for the specific language governing permissions and
2493 * limitations under the License.
2494 */const n0="LocalStore",jk=3e8;class Mk{constructor(e,t,n,i){this.persistence=e,this.Mo=t,this.serializer=i,this.No=new Rt(Ue),this.Lo=new Ea((o=>Rf(o)),HC),this.Bo=new Map,this.Uo=e.getRemoteDocumentCache(),this.A_=e.getTargetCache(),this.d_=e.getBundleCache(),this.ko(n)}ko(e){this.documentOverlayCache=this.persistence.getDocumentOverlayCache(e),this.indexManager=this.persistence.getIndexManager(e),this.mutationQueue=this.persistence.getMutationQueue(e,this.indexManager),this.localDocuments=new Iv(this.Uo,this.mutationQueue,this.documentOverlayCache,this.indexManager),this.Uo.setIndexManager(this.indexManager),this.Mo.initialize(this.localDocuments,this.indexManager)}collectGarbage(e){return this.persistence.runTransaction("Collect garbage","readwrite-primary",(t=>e.collect(t,this.No)))}}function Ov(r,e,t,n){return new Mk(r,e,t,n)}async function kv(r,e){const t=Se(r);return await t.persistence.runTransaction("Handle user change","readonly",(n=>{let i;return t.mutationQueue.getAllMutationBatches(n).next((o=>(i=o,t.ko(e),t.mutationQueue.getAllMutationBatches(n)))).next((o=>{const u=[],B=[];let f=Xe();for(const g of i){u.push(g.batchId);for(const y of g.mutations)f=f.add(y.key)}for(const g of o){B.push(g.batchId);for(const y of g.mutations)f=f.add(y.key)}return t.localDocuments.getDocuments(n,f).next((g=>({qo:g,removedBatchIds:u,addedBatchIds:B})))}))}))}function Pk(r,e){const t=Se(r);return t.persistence.runTransaction("Acknowledge batch","readwrite-primary",(n=>{const i=e.batch.keys(),o=t.Uo.newChangeBuffer({trackRemovals:!0});return(function(B,f,g,y){const b=g.batch,D=b.keys();let T=U.resolve();return D.forEach((M=>{T=T.next((()=>y.getEntry(f,M))).next((z=>{const W=g.docVersions.get(M);fe(W!==null,48541),z.version.compareTo(W)<0&&(b.applyToRemoteDocument(z,g),z.isValidDocument()&&(z.setReadTime(g.commitVersion),y.addEntry(z)))}))})),T.next((()=>
2494B.mutationQueue.removeMutationBatch(f,b)))})(t,n,e,o).next((()=>o.apply(n))).next((()=>t.mutationQueue.performConsistencyCheck(n))).next((()=>t.documentOverlayCache.removeOverlaysForBatchId(n,i,e.batch.batchId))).next((()=>t.localDocuments.recalculateAndSaveOverlaysForDocumentKeys(n,(function(B){let f=Xe();for(let g=0;g<B.mutationResults.length;++g)B.mutationResults[g].transformResults.length>0&&(f=f.add(B.batch.mutations[g].key));return f})(e)))).next((()=>t.localDocuments.getDocuments(n,i)))}))}function Lv(r){const e=Se(r);return e.persistence.runTransaction("Get last remote snapshot version","readonly",(t=>e.A_.getLastRemoteSnapshotVersion(t)))}function Vk(r,e){const t=Se(r),n=e.snapshotVersion;let i=t.No;return t.persistence.runTransaction("Apply remote event","readwrite-primary",(o=>{const u=t.Uo.newChangeBuffer({trackRemovals:!0});i=t.No;const B=[];e.targetChanges.forEach(((y,b)=>{const D=i.get(b);if(!D)return;B.push(t.A_.removeMatchingKeys(o,y.removedDocuments,b).next((()=>t.A_.addMatchingKeys(o,y.addedDocuments,b))));let T=D.withSequenceNumber(o.currentSequenceNumber);e.targetMismatches.get(b)!==null?T=T.withResumeToken(qt.EMPTY_BYTE_STRING,Me.min()).withLastLimboFreeSnapshotVersion(Me.min()):y.resumeToken.approximateByteSize()>0&&(T=T.withResumeToken(y.resumeToken,n)),i=i.insert(b,T),(function(z,W,K){return z.resumeToken.approximateByteSize()===0||W.snapshotVersion.toMicroseconds()-z.snapshotVersion.toMicroseconds()>=jk?!0:K.addedDocuments.size+K.modifiedDocuments.size+K.removedDocuments.size>0})(D,T,y)&&B.push(t.A_.updateTargetData(o,T))}));let f=yn(),g=Xe();if(e.documentUpdates.forEach((y=>{e.resolvedLimboDocuments.has(y)&&B.push(t.persistence.referenceDelegate.updateLimboDocument(o,y))})),B.push(Fk(o,u,e.documentUpdates).next((y=>{f=y.$o,g=y.Ko}))),!n.isEqual(Me.min())){const y=t.A_.getLastRemoteSnapshotVersion(o).next((b=>t.A_.setTargetsMetadata(o,o.currentSequenceNumber,n)));B.push(y)}return U.waitFor(B).next((()=>u.apply(o))).next((()=>t.localDocuments.getLocalViewOfDocuments(o,f,g))).next((()=>f))})).then((o=>(t.No=i,o)))}function Fk(r,e,t){let n=Xe(),i=Xe();return t.forEach((o=>n=n.add(o))),e.getEntries(r,n).next((o=>{let u=yn();return t.forEach(((B,f)=>{const g=o.get(B);f.isFoundDocument()!==g.isFoundDocument()&&(i=i.add(B)),f.isNoDocument()&&f.version.isEqual(Me.min())?(e.removeEntry(B,f.readTime),u=u.insert(B,f)):!g.isValidDocument()||f.version.compareTo(g.version)>0||f.version.compareTo(g.version)===0&&g.hasPendingWrites?(e.addEntry(f),u=u.insert(B,f)):Be(n0,"Ignoring outdated watch update for ",B,". Current version:",g.version," Watch version:",f.version)})),{$o:u,Ko:i}}))}function Gk(r,e){const t=Se(r);return t.persistence.runTransaction("Get next mutation batch","readonly",(n=>(e===void 0&&(e=xl),t.mutationQueue.getNextMutationBatchAfterBatchId(n,e))))}function of(r,e){const t=Se(r);return t.persistence.runTransaction("Allocate target","readwrite",(n=>{let i;return t.A_.getTargetData(n,e).next((o=>o?(i=o,U.resolve(i)):t.A_.allocateTargetId(n).next((u=>(i=new kr(e,u,"TargetPurposeListen",n.currentSequenceNumber),t.A_.addTargetData(n,i).next((()=>i)))))))})).then((n=>{const i=t.No.get(n.targetId);return(i===null||n.snapshotVersion.compareTo(i.snapshotVersion)>0)&&(t.No=t.No.insert(n.targetId,n),t.Lo.set(e,n.targetId)),n}))}async function yu(r,e,t){const n=Se(r),i=n.No.get(e),o=t?"readwrite":"readwrite-primary";try{t||await n.persistence.runTransaction("Release target",o,(u=>n.persistence.referenceDelegate.removeTarget(u,i)))}catch(u){if(!Ii(u))throw u;Be(n0,`Failed to update sequence numbers for target ${e}: ${u}`)}n.No=n.No.remove(e),n.Lo.delete(i.target)}function Qg(r,e,t){const n=Se(r);let i=Me.min(),o=Xe();return n.persistence.runTransaction("Execute query","readwrite",(u=>(function(f,g,y){const b=Se(f),D=b.Lo.get(y);return D!==void 0?U.resolve(b.No.get(D)):b.A_.getTargetData(g,y)})(n,u,Wt(e)?e:ws(e)).next((B=>{if(B)return i=B.lastLimboFreeSnapshotVersion,n.A_.getMatchingKeysForTargetId(u,B.targetId).next((f=>{o=f}))})).next((()=>n.Mo.getDocumentsMatchingQuery(u,e,t?i:Me.min(),t?o:Xe()))).next((B=>(Mv(n,B),{documents:B,Wo:o})))))}function jv(r,e){const t=Se(r),n=Se(t.A_),i=t.No.get(e);return i?Promise.resolve(i.target??null):t.persistence.runTransaction("Get target data","readonly",(o=>n.ge(o,e).next((u=>(u==null?void 0:u.target)??null))))}function Yg(r,e){const t=Se(r),n=t.Bo.get(e)||Me.min();return t.persistence.runTransaction("Get new document changes","readonly",(i=>t.Uo.getAllFromCollectionGroup(i,e,uD(n,hu),Number.MAX_SAFE_INTEGER))).then((i=>(Mv(t,i),i)))}function Mv(r,e){e.forEach(((t,n)=>{const i=n.key.getCollectionGroup(),o=r.Bo.get(i)||Me.min();n.readTime.compareTo(o)>0&&r.Bo.set(i,n.readTime)}))}/**
2495 * @license
2496 * Copyright 2020 Google LLC
2497 *
2498 * Licensed under the Apache License, Version 2.0 (the "License");
2499 * you may not use this file except in compliance with the License.
2500 * You may obtain a copy of the License at
2501 *
2502 *   http://www.apache.org/licenses/LICENSE-2.0
2503 *
2504 * Unless required by applicable law or agreed to in writing, software
2505 * distributed under the License is distributed on an "AS IS" BASIS,
2506 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2507 * See the License for the specific language governing permissions and
2508 * limitations under the License.
2509 */class Hk{constructor(e,t){this.asyncQueue=e,this.onlineStateHandler=t,this.state="Unknown",this.Jo=0,this.Yo=null,this.Zo=!0}Xo(){this.Jo===0&&(this.ea("Unknown"),this.Yo=this.asyncQueue.enqueueAfterDelay("online_state_timeout",1e4,(()=>(this.Yo=null,this.ta("Backend didn't respond within 10 seconds."),this.ea("Offline"),Promise.resolve()))))}na(e){this.state==="Online"?this.ea("Unknown"):(this.Jo++,this.Jo>=1&&(this.ra(),this.ta(`Connection failed 1 times. Most recent error: ${e.toString()}`),this.ea("Offline")))}set(e){this.ra(),this.Jo=0,e==="Online"&&(this.Zo=!1),this.ea(e)}ea(e){e!==this.state&&(this.state=e,this.onlineStateHandler(e))}ta(e){const t=`Could not reach Cloud Firestore backend. ${e}
2510This 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.Zo?(sn(t),this.Zo=!1):Be("OnlineStateTracker",t)}ra(){this.Yo!==null&&(this.Yo.cancel(),this.Yo=null)}}/**
2511 * @license
2512 * Copyright 2017 Google LLC
2513 *
2514 * Licensed under the Apache License, Version 2.0 (the "License");
2515 * you may not use this file except in compliance with the License.
2516 * You may obtain a copy of the License at
2517 *
2518 *   http://www.apache.org/licenses/LICENSE-2.0
2519 *
2520 * Unless required by applicable law or agreed to in writing, software
2521 * distributed under the License is distributed on an "AS IS" BASIS,
2522 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2523 * See the License for the specific language governing permissions and
2524 * limitations under the License.
2525 */const Fr="RemoteStore";class Uk{constructor(e,t,n,i,o){this.localStore=e,this.datastore=t,this.asyncQueue=n,this.remoteSyncer={},this.ia=[],this.sa=new Map,this._a=new Map,this.oa=new Map,this.aa=new xa(1e3),this.ua=new xa(1001),this.ca=new Set,this.la=[],this.Ea=o,this.Ea.Ke((u=>{n.enqueueAndForget((async()=>{Hl(this)&&(Be(Fr,"Restarting streams for network reachability change."),await(async function(f){const g=Se(f);g.ca.add(4),await HB(g),g.ha.set("Unknown"),g.ca.delete(4),await Ff(g)})(this))}))})),this.ha=new Hk(n,i)}}async function Ff(r){if(Hl(r))for(const e of r.la)await e(!0)}async function HB(r){for(const e of r.la)await e(!1)}function Xg(r,e){return r._a.get(e)||void 0}function Gf(r,e){const t=Se(r),n=Xg(t,e.targetId);if(n!==void 0&&t.sa.has(n))return;const i=(function(B,f){const g=Xg(B,f);g!==void 0&&B.oa.delete(g);const y=(function(D,T){return T%2!=0?D.ua.next():D.aa.next()})(B,f);return B._a.set(f,y),B.oa.set(y,f),y})(t,e.targetId);Be(Fr,"remoteStoreListen mapping SDK target ID to remote",e.targetId,i);const o=new kr(e.target,i,e.purpose,e.sequenceNumber,e.snapshotVersion,e.lastLimboFreeSnapshotVersion,e.resumeToken);t.sa.set(i,o),a0(t)?r0(t):Ou(t).Jt()&&s0(t,o)}function bu(r,e){const t=Se(r),n=Ou(t),i=Xg(t,e);Be(Fr,"remoteStoreUnlisten removing mapping of SDK target ID to remote",e,i),t.sa.delete(i),t._a.delete(e),t.oa.delete(i),n.Jt()&&Pv(t,i),t.sa.size===0&&(n.Jt()?n.Xt():Hl(t)&&t.ha.set("Unknown"))}function s0(r,e){if(r.Ta.H(e.targetId),e.resumeToken.approximateByteSize()>0||e.snapshotVersion.compareTo(Me.min())>0){const t=r.oa.get(e.targetId);if(t===void 0)return void Be(Fr,"SDK target ID not found for remote ID: "+e.targetId);const n=r.remoteSyncer.getRemoteKeysForTarget(t).size;e=e.withExpectedCount(n)}Ou(r).Tn(e)}function Pv(r,e){r.Ta.H(e),Ou(r).Pn(e)}function r0(r){r.Ta=new gS({getRemoteKeysForTarget:e=>{const t=r.oa.get(e);return t!==void 0?r.remoteSyncer.getRemoteKeysForTarget(t):Xe()},ge:e=>r.sa.get(e)||null,Ae:()=>r.datastore.serializer.databaseId}),Ou(r).start(),r.ha.Xo()}function a0(r){return Hl(r)&&!Ou(r).Ht()&&r.sa.size>0}function Hl(r){return Se(r).ca.size===0}function Vv(r){r.Ta=void 0}async function zk(r){r.ha.set("Online")}
2525async function qk(r){r.sa.forEach(((e,t)=>{s0(r,e)}))}async function Kk(r,e){Vv(r),a0(r)?(r.ha.na(e),r0(r)):r.ha.set("Unknown")}async function Jk(r,e,t){if(r.ha.set("Online"),e instanceof gD&&e.state===2&&e.cause)try{await(async function(i,o){const u=o.cause;for(const B of o.targetIds){if(i.sa.has(B)){const f=i.oa.get(B);f!==void 0&&(await i.remoteSyncer.rejectListen(f,u),i._a.delete(f),i.oa.delete(B)),i.sa.delete(B)}i.Ta.removeTarget(B)}})(r,e)}catch(n){Be(Fr,"Failed to remove targets %s: %s ",e.targetIds.join(","),n),await uf(r,n)}else if(e instanceof Od?r.Ta.se(e):e instanceof pD?r.Ta.Ee(e):r.Ta.ae(e),!t.isEqual(Me.min()))try{const n=await Lv(r.localStore);t.compareTo(n)>=0&&await(function(o,u){const B=o.Ta.de(u);B.targetChanges.forEach(((g,y)=>{if(g.resumeToken.approximateByteSize()>0){const b=o.sa.get(y);b&&o.sa.set(y,b.withResumeToken(g.resumeToken,u))}})),B.targetMismatches.forEach(((g,y)=>{const b=o.sa.get(g);if(!b)return;o.sa.set(g,b.withResumeToken(qt.EMPTY_BYTE_STRING,b.snapshotVersion)),Pv(o,g);const D=new kr(b.target,g,y,b.sequenceNumber);s0(o,D)}));const f=(function(y,b){const D=new Map;
vendor: 4,933 bytes, lines 2525-2555
2525b.targetChanges.forEach(((M,z)=>{const W=y.oa.get(z);W!==void 0&&D.set(W,M)}));let T=new Rt(Ue);return b.targetMismatches.forEach(((M,z)=>{const W=y.oa.get(M);W!==void 0&&(T=T.insert(W,z))})),new Au(b.snapshotVersion,D,T,b.documentUpdates,b.augmentedDocumentUpdates,b.resolvedLimboDocuments)})(o,B);return o.remoteSyncer.applyRemoteEvent(f)})(r,t)}catch(n){Be(Fr,"Failed to raise snapshot:",n),await uf(r,n)}}async function uf(r,e,t){if(!Ii(e))throw e;r.ca.add(1),await HB(r),r.ha.set("Offline"),t||(t=()=>Lv(r.localStore)),r.asyncQueue.enqueueRetryable((async()=>{Be(Fr,"Retrying IndexedDB access"),await t(),r.ca.delete(1),await Ff(r)}))}function Fv(r,e){return e().catch((t=>uf(r,t,e)))}async function Ru(r){const e=Se(r),t=wi(e);let n=e.ia.length>0?e.ia[e.ia.length-1].batchId:xl;for(;Qk(e);)try{const i=await Gk(e.localStore,n);if(i===null){e.ia.length===0&&t.Xt();break}n=i.batchId,Yk(e,i)}catch(i){await uf(e,i)}Gv(e)&&Hv(e)}function Qk(r){return Hl(r)&&r.ia.length<10}function Yk(r,e){r.ia.push(e);const t=wi(r);t.Jt()&&t.Rn&&t.In(e.mutations)}function Gv(r){return Hl(r)&&!wi(r).Ht()&&r.ia.length>0}function Hv(r){wi(r).start()}async function Xk(r){wi(r).dn()}async function $k(r){const e=wi(r);for(const t of r.ia)e.In(t.mutations)}async function Zk(r,e,t){const n=r.ia.shift(),i=zC.from(n,e,t);await Fv(r,(()=>r.remoteSyncer.applySuccessfulWrite(i))),await Ru(r)}async function Wk(r,e){e&&wi(r).Rn&&await(async function(n,i){if((function(u){return cS(u)&&u!==le.ABORTED})(i.code)){const o=n.ia.shift();wi(n).Zt(),await Fv(n,(()=>n.remoteSyncer.rejectFailedWrite(o.batchId,i))),await Ru(n)}})(r,e),Gv(r)&&Hv(r)}async function V_(r,e){const t=Se(r);t.asyncQueue.verifyOperationInProgress(),Be(Fr,"RemoteStore received new credentials");const n=Hl(t);t.ca.add(3),await HB(t),n&&t.ha.set("Unknown"),await t.remoteSyncer.handleCredentialChange(e),t.ca.delete(3),await Ff(t)}async function $g(r,e){const t=Se(r);e?(t.ca.delete(2),await Ff(t)):e||(t.ca.add(2),await HB(t),t.ha.set("Unknown"))}function Ou(r){return r.Pa||(r.Pa=(function(t,n,i){const o=Se(t);return o.mn(),new HS(n,o.connection,o.authCredentials,o.appCheckCredentials,o.serializer,i)})(r.datastore,r.asyncQueue,{ut:zk.bind(null,r),lt:qk.bind(null,r),ht:Kk.bind(null,r),hn:Jk.bind(null,r)}),r.la.push((async e=>{e?(r.Pa.Zt(),a0(r)?r0(r):r.ha.set("Unknown")):(await r.Pa.stop(),Vv(r))}))),r.Pa}function wi(r){return r.Ra||(r.Ra=(function(t,n,i){const o=Se(t);return o.mn(),new US(n,o.connection,o.authCredentials,o.appCheckCredentials,o.serializer,i)})(r.datastore,r.asyncQueue,{ut:()=>Promise.resolve(),lt:Xk.bind(null,r),ht:Wk.bind(null,r),An:$k.bind(null,r),Vn:Zk.bind(null,r)}),r.la.push((async e=>{e?(r.Ra.Zt(),await Ru(r)):(await r.Ra.stop(),r.ia.length>0&&(Be(Fr,`Stopping write stream with ${r.ia.length} pending writes`),r.ia=[]))}))),r.Ra}/**
2526 * @license
2527 * Copyright 2017 Google LLC
2528 *
2529 * Licensed under the Apache License, Version 2.0 (the "License");
2530 * you may not use this file except in compliance with the License.
2531 * You may obtain a copy of the License at
2532 *
2533 *   http://www.apache.org/licenses/LICENSE-2.0
2534 *
2535 * Unless required by applicable law or agreed to in writing, software
2536 * distributed under the License is distributed on an "AS IS" BASIS,
2537 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2538 * See the License for the specific language governing permissions and
2539 * limitations under the License.
2540 */class Uv{constructor(e){this.observer=e,this.muted=!1}next(e){this.muted||this.observer.next&&this.Ia(this.observer.next,e)}error(e){this.muted||(this.observer.error?this.Ia(this.observer.error,e):sn("Uncaught Error in snapshot listener:",e.toString()))}Aa(){this.muted=!0}Ia(e,t){setTimeout((()=>{this.muted||e(t)}),0)}}/**
2541 * @license
2542 * Copyright 2017 Google LLC
2543 *
2544 * Licensed under the Apache License, Version 2.0 (the "License");
2545 * you may not use this file except in compliance with the License.
2546 * You may obtain a copy of the License at
2547 *
2548 *   http://www.apache.org/licenses/LICENSE-2.0
2549 *
2550 * Unless required by applicable law or agreed to in writing, software
2551 * distributed under the License is distributed on an "AS IS" BASIS,
2552 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2553 * See the License for the specific language governing permissions and
2554 * limitations under the License.
2555 */class i0{constructor(e,t,n,i,o){this.asyncQueue=e,this.timerId=t,this.targetTimeMs=n,this.op=i,this.removalCallback=o,this.deferred=new fa,this.then=this.deferred.promise.then.bind(this.deferred.promise),this.deferred.promise.catch((u=>{}))}get promise(){return this.deferred.promise}static createAndSchedule(e,t,n,i,o){const u=Date.now()+n,B=new i0(e,t,u,i,o);return B.start(n),B}start(e){this.timerHandle=setTimeout((()=>this.handleDelayElapsed()),e)}skipDelay(){return this.handleDelayElapsed()}cancel(e){this.timerHandle!==null&&(this.clearTimeout(),this.deferred.reject(new ve(le.CA
2555NCELLED,"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 l0(r,e){if(sn("AsyncQueue",`${e}: ${r}`),Ii(r))return new ve(le.UNAVAILABLE,`${e}: ${r}`);throw r}const rB="IndexBackfiller";class e5{constructor(e,t){this.asyncQueue=e,this.Sa=t,this.task=null}start(){this.Da(15e3)}stop(){this.task&&(this.task.cancel(),this.task=null)}get started(){return this.task!==null}Da(e){Be(rB,`Scheduled in ${e}ms`),this.task=this.asyncQueue.enqueueAfterDelay("index_backfill",e,(async()=>{this.task=null;try{const t=await this.Sa.xa();Be(rB,`Documents written: ${t}`)}catch(t){Ii(t)?Be(rB,"Ignoring IndexedDB error during index backfill: ",t):await Ni(t)}await this.Da(6e4)}))}}class t5{constructor(e,t){this.localStore=e,this.persistence=t}async xa(e=50){return this.persistence.runTransaction("Backfill Indexes","readwrite-primary",(t=>this.Ca(t,e)))}Ca(e,t){const n=new Set;let i=t,o=!0;return U.doWhile((()=>o===!0&&i>0),(()=>this.localStore.indexManager.getNextCollectionGroupToUpdate(e).next((u=>{if(u!==null&&!n.has(u))return Be(rB,`Processing collection: ${u}`),this.Fa(e,u,i).next((B=>{i-=B,n.add(u)}));o=!1})))).next((()=>t-i))}Fa(e,t,n){return this.localStore.indexManager.getMinOffsetFromCollectionGroup(e,t).next((i=>this.localStore.localDocuments.getNextDocuments(e,t,i,n).next((o=>{const u=o.changes;return this.localStore.indexManager.updateIndexEntries(e,u).next((()=>this.Oa(i,o))).next((B=>(Be(rB,`Updating offset: ${B}`),this.localStore.indexManager.updateCollectionGroup(e,t,B)))).next((()=>u.size))}))))}Oa(e,t){let n=e;
2555return t.changes.forEach(((i,o)=>{const u=cD(o);xC(u,n)>0&&(n=u)})),new Ts(n.readTime,n.documentKey,Math.max(t.batchId,e.largestBatchId))}}/**
2556 * @license
2557 * Copyright 2019 Google LLC
2558 *
2559 * Licensed under the Apache License, Version 2.0 (the "License");
2560 * you may not use this file except in compliance with the License.
2561 * You may obtain a copy of the License at
2562 *
2563 *   http://www.apache.org/licenses/LICENSE-2.0
2564 *
2565 * Unless required by applicable law or agreed to in writing, software
2566 * distributed under the License is distributed on an "AS IS" BASIS,
2567 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2568 * See the License for the specific language governing permissions and
2569 * limitations under the License.
2570 */const zv="firestore_clients";function F_(r,e){return`${zv}_${r}_${e}`}const qv="firestore_mutations";function G_(r,e,t){let n=`${qv}_${r}_${t}`;return e.isAuthenticated()&&(n+=`_${e.uid}`),n}const Kv="firestore_targets";function Bg(r,e){return`${Kv}_${r}_${e}`}/**
2571 * @license
2572 * Copyright 2018 Google LLC
2573 *
2574 * Licensed under the Apache License, Version 2.0 (the "License");
2575 * you may not use this file except in compliance with the License.
2576 * You may obtain a copy of the License at
2577 *
2578 *   http://www.apache.org/licenses/LICENSE-2.0
2579 *
2580 * Unless required by applicable law or agreed to in writing, software
2581 * distributed under the License is distributed on an "AS IS" BASIS,
2582 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2583 * See the License for the specific language governing permissions and
2584 * limitations under the License.
2585 */const Ir="SharedClientState";class cf{constructor(e,t,n,i){this.user=e,this.batchId=t,this.state=n,this.error=i}static Ma(e,t,n){const i=JSON.parse(n);let o,u=typeof i=="object"&&["pending","acknowledged","rejected"].indexOf(i.state)!==-1&&(i.error===void 0||typeof i.error=="object");return u&&i.error&&(u=typeof i.error.message=="string"&&typeof i.error.code=="string",u&&(o=new ve(i.error.code,i.error.message))),u?new cf(e,t,i.state,o):(sn(Ir,`Failed to parse mutation state for ID '${t}': ${n}`),null)}Na(){const e={state:this.state,updateTimeMs:Date.now()};return this.error&&(e.error={code:this.error.code,message:this.error.message}),JSON.stringify(e)}}class aB{constructor(e,t,n){this.targetId=e,this.state=t,this.error=n}static Ma(e,t){const n=JSON.parse(t);let i,o=typeof n=="object"&&["not-current","current","rejected"].indexOf(n.state)!==-1&&(n.error===void 0||typeof n.error=="object");return o&&n.error&&(o=typeof n.error.message=="string"&&typeof n.error.code=="string",o&&(i=new ve(n.error.code,n.error.message))),o?new aB(e,n.state,i):(sn(Ir,`Failed to parse target state for ID '${e}': ${t}`),null)}Na(){const e={state:this.state,updateTimeMs:Date.now()};return this.error&&(e.error={code:this.error.code,message:this.error.message}),JSON.stringify(e)}}class Bf{constructor(e,t){this.clientId=e,this.activeTargetIds=t}static Ma(e,t){const n=JSON.parse(t);let i=typeof n=="object"&&n.activeTargetIds instanceof Array,o=vC();for(let u=0;i&&u<n.activeTargetIds.length;++u)i=z1(n.activeTargetIds[u]),o=o.add(n.activeTargetIds[u]);return i?new Bf(e,o):(sn(Ir,`Failed to parse client data for instance '${e}': ${t}`),null)}}class o0{constructor(e,t){this.clientId=e,this.onlineState=t}static Ma(e){const t=JSON.parse(e);return typeof t=="object"&&["Unknown","Online","Offline"].indexOf(t.onlineState)!==-1&&typeof t.clientId=="string"?new o0(t.clientId,t.onlineState):(sn(Ir,`Failed to parse online state: ${e}`),null)}}class Zg{constructor(){this.activeTargetIds=vC()}La(e){this.activeTargetIds=this.activeTargetIds.add(e)}Ba(e){this.activeTargetIds=this.activeTargetIds.delete(e)}Na(){const e={activeTargetIds:this.activeTargetIds.toArray(),updateTimeMs:Date.now()};return JSON.stringify(e)}}class hg{constructor(e,t,n,i,o){this.window=e,this.xt=t,this.persistenceKey=n,this.Ua=i,this.syncEngine=null,this.onlineStateHandler=null,this.sequenceNumberHandler=null,this.ka=this.qa.bind(this),this.$a=new Rt(Ue),this.started=!1,this.Ka=[];const u=n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");this.storage=this.window.localStorage,this.currentUser=o,this.Wa=F_(this.persistenceKey,this.Ua),this.Qa=(function(f){return`firestore_sequence_number_${f}`})(this.persistenceKey),this.$a=this.$a.insert(this.Ua,new Zg),this.Ga=new RegExp(`^${zv}_${u}_([^_]*)$`),this.za=new RegExp(`^${qv}_${u}_(\\d+)(?:_(.*))?$`),this.ja=new RegExp(`^${Kv}_${u}_(\\d+)$`),this.Ha=(function(f){return`firestore_online_state_${f}`})(this.persistenceKey),this.Ja=(function(f){return`firestore_bundle_loaded_v2_${f}`})(this.persistenceKey),this.window.addEventListener("storage",this.ka)}static Je(e){return!(!e||!e.localStorage)}async start(){const e=await this.syncEngine.Ro();for(const n of e){if(n===this.Ua)continue;const i=this.getItem(F_(this.persistenceKey,n));if(i){const o=Bf.Ma(n,i);o&&(this.$a=this.$a.insert(o.clientId,o))}}this.Ya();const t=this.storage.getItem(this.Ha);if(t){const n=this.Za(t);n&&this.Xa(n)}for(const n of this.Ka)this.qa(n);this.Ka=[],this.window.addEventListener("pagehide",(()=>this.shutdown())),this.started=!0}writeSequenceNumber(e){this.setItem(this.Qa,JSON.stringify(e))}getAllActiveQueryTargets(){return this.eu(this.$a)}isActiveQueryTarget(e){let t=!1;return this.$a.forEach(((n,i)=>{i.activeTargetIds.has(e)&&(t=!0)})),t}addPendingMutation(e){this.tu(e,"pending")}updateMutationState(e,t,n){this.tu(e,t,n),this.nu(e)}addLocalQueryTarget(e,t=!0){let n="not-current";if(this.isActiveQueryTarget(e)){const i=this.storage.getItem(Bg(this.persistenceKey,e));if(i){const o=aB.Ma(e,i);o&&(n=o.state)}}return t&&this.ru.La(e),this.Ya(),n}removeLocalQueryTarget(e){this.ru.Ba(e),this.Ya()}isLocalQueryTarget(e){return this.ru.activeTargetIds.has(e)}clearQueryState(e){this.removeItem(Bg(this.persistenceKey,e))}updateQueryState(e,t,n){this.iu(e,t,n)}handleUserChange(e,t,n){t.forEach((i=>{this.nu(i)}
vendor: 4,541 bytes, lines 2585-2604
2585)),this.currentUser=e,n.forEach((i=>{this.addPendingMutation(i)}))}setOnlineState(e){this.su(e)}notifyBundleLoaded(e){this._u(e)}shutdown(){this.started&&(this.window.removeEventListener("storage",this.ka),this.removeItem(this.Wa),this.started=!1)}getItem(e){const t=this.storage.getItem(e);return Be(Ir,"READ",e,t),t}setItem(e,t){Be(Ir,"SET",e,t),this.storage.setItem(e,t)}removeItem(e){Be(Ir,"REMOVE",e),this.storage.removeItem(e)}qa(e){const t=e;if(t.storageArea===this.storage){if(Be(Ir,"EVENT",t.key,t.newValue),t.key===this.Wa)return void sn("Received WebStorage notification for local change. Another client might have garbage-collected our state");this.xt.enqueueRetryable((async()=>{if(this.started){if(t.key!==null){if(this.Ga.test(t.key)){if(t.newValue==null){const n=this.ou(t.key);return this.au(n,null)}{const n=this.uu(t.key,t.newValue);if(n)return this.au(n.clientId,n)}}else if(this.za.test(t.key)){if(t.newValue!==null){const n=this.cu(t.key,t.newValue);if(n)return this.lu(n)}}else if(this.ja.test(t.key)){if(t.newValue!==null){const n=this.Eu(t.key,t.newValue);if(n)return this.hu(n)}}else if(t.key===this.Ha){if(t.newValue!==null){const n=this.Za(t.newValue);if(n)return this.Xa(n)}}else if(t.key===this.Qa){const n=(function(o){let u=is.yn;if(o!=null)try{const B=JSON.parse(o);fe(typeof B=="number",30636,{Tu:o}),u=B}catch(B){sn(Ir,"Failed to read sequence number from WebStorage",B)}return u})(t.newValue);n!==is.yn&&this.sequenceNumberHandler(n)}else if(t.key===this.Ja){const n=this.Pu(t.newValue);await Promise.all(n.map((i=>this.syncEngine.Ru(i))))}}}else this.Ka.push(t)}))}}get ru(){return this.$a.get(this.Ua)}Ya(){this.setItem(this.Wa,this.ru.Na())}tu(e,t,n){const i=new cf(this.currentUser,e,t,n),o=G_(this.persistenceKey,this.currentUser,e);this.setItem(o,i.Na())}nu(e){const t=G_(this.persistenceKey,this.currentUser,e);this.removeItem(t)}su(e){const t={clientId:this.Ua,onlineState:e};this.storage.setItem(this.Ha,JSON.stringify(t))}iu(e,t,n){const i=Bg(this.persistenceKey,e),o=new aB(e,t,n);this.setItem(i,o.Na())}_u(e){const t=JSON.stringify(Array.from(e));this.setItem(this.Ja,t)}ou(e){const t=this.Ga.exec(e);return t?t[1]:null}uu(e,t){const n=this.ou(e);return Bf.Ma(n,t)}cu(e,t){const n=this.za.exec(e),i=Number(n[1]),o=n[2]!==void 0?n[2]:null;return cf.Ma(new Vn(o),i,t)}Eu(e,t){const n=this.ja.exec(e),i=Number(n[1]);return aB.Ma(i,t)}Za(e){return o0.Ma(e)}Pu(e){return JSON.parse(e)}async lu(e){if(e.user.uid===this.currentUser.uid)return this.syncEngine.Iu(e.batchId,e.state,e.error);Be(Ir,`Ignoring mutation for non-active user ${e.user.uid}`)}hu(e){return this.syncEngine.Au(e.targetId,e.state,e.error)}au(e,t){const n=t?this.$a.insert(e,t):this.$a.remove(e),i=this.eu(this.$a),o=this.eu(n),u=[],B=[];return o.forEach((f=>{i.has(f)||u.push(f)})),i.forEach((f=>{o.has(f)||B.push(f)})),this.syncEngine.Vu(u,B).then((()=>{this.$a=n}))}Xa(e){this.$a.get(e.clientId)&&this.onlineStateHandler(e.onlineState)}eu(e){let t=vC();return e.forEach(((n,i)=>{t=t.unionWith(i.activeTargetIds)})),t}}class Jv{constructor(){this.du=new Zg,this.fu={},this.onlineStateHandler=null,this.sequenceNumberHandler=null}addPendingMutation(e){}updateMutationState(e,t,n){}addLocalQueryTarget(e,t=!0){return t&&this.du.La(e),this.fu[e]||"not-current"}updateQueryState(e,t,n){this.fu[e]=t}removeLocalQueryTarget(e){this.du.Ba(e)}isLocalQueryTarget(e){return this.du.activeTargetIds.has(e)}clearQueryState(e){delete this.fu[e]}getAllActiveQueryTargets(){return this.du.activeTargetIds}isActiveQueryTarget(e){return this.du.activeTargetIds.has(e)}start(){return this.du=new Zg,Promise.resolve()}handleUserChange(e,t,n){}setOnlineState(e){}shutdown(){}writeSequenceNumber(e){}notifyBundleLoaded(e){}}/**
2586 * @license
2587 * Copyright 2020 Google LLC
2588 *
2589 * Licensed under the Apache License, Version 2.0 (the "License");
2590 * you may not use this file except in compliance with the License.
2591 * You may obtain a copy of the License at
2592 *
2593 *   http://www.apache.org/licenses/LICENSE-2.0
2594 *
2595 * Unless required by applicable law or agreed to in writing, software
2596 * distributed under the License is distributed on an "AS IS" BASIS,
2597 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2598 * See the License for the specific language governing permissions and
2599 * limitations under the License.
2600 */function Qv(){return typeof window<"u"?window:null}function Pd(){return typeof document<"u"?document:null}/**
2601 * @license
2602 * Copyright 2017 Google LLC
2603 *
2604 * Licensed under the Apache License, Version 2.0 (the "License");
2605 * you may not use this file except in compliance with the License.
2606 * You may obtain a copy of the License at
2607 *
2608 *   http://www.apache.org/licenses/LICENSE-2.0
2609 *
2610 * Unless required by applicable law or agreed to in writing, software
2611 * distributed under the License is distributed on an "AS IS" BASIS,
2612 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2613 * See the License for the specific language governing permissions and
2614 * limitations under the License.
2615 */class vl{static emptySet(e){return new vl(e.comparator)}constructor(e){this.comparator=e?(t,n)=>e(t,n)||De.comparator(t.key,n.key):(t,n)=>De.comparator(t.key,n.key),this.keyedMap=Bl(),this.sortedSet=new Rt(this.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 t=this.keyedMap.get(e);return t?this.sortedSet.indexOf(t):-1}get size(){return this.sortedSet.size}forEach(e){this.sortedSet.inorderTraversal(((t,n)=>(e(t),!1)))}add(e){const t=this.delete(e.key);return t.copy(t.keyedMap.insert(e.key,e),t.sortedSet.insert(e,null))}delete(e){const t=this.get(e);return t?this.copy(this.keyedMap.remove(e),this.sortedSet.remove(t)):this}isEqual(e){if(!(e instanceof vl)||this.size!==e.size)return!1;const t=this.sortedSet.getIterator(),n=e.sortedSet.getIterator();for(;t.hasNext();){const i=t.getNext().key,o=n.getNext().key;if(!i.isEqual(o))return!1}return!0}toString(){const e=[];return this.forEach((t=>{e.push(t.toString())})),e.length===0?"DocumentSet ()":`DocumentSet (
2616  `+e.join(`  
2617`)+`
2618)`}copy(e,t){const n=new vl;return n.comparator=this.comparator,n.keyedMap=e,n.sortedSet=t,n}}/**
2619 * @license
2620 * Copyright 2017 Google LLC
2621 *
2622 * Licensed under the Apache License, Version 2.0 (the "License");
2623 * you may not use this file except in compliance with the License.
2624 * You may obtain a copy of the License at
2625 *
2626 *   http://www.apache.org/licenses/LICENSE-2.0
2627 *
2628 * Unless required by applicable law or agreed to in writing, software
2629 * distributed under the License is distributed on an "AS IS" BASIS,
2630 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2631 * See the License for the specific language governing permissions and
2632 * limitations under the License.
2633 */class H_{constructor(){this.mu=new Rt(De.comparator)}track(e){const t=e.doc.key,n=this.mu.get(t);n?e.type!==0&&n.type===3?this.mu=this.mu.insert(t,e):e.type===3&&n.type!==1?this.mu=this.mu.insert(t,{type:n.type,doc:e.doc}):e.type===2&&n.type===2?this.mu=this.mu.insert(t,{type:2,doc:e.doc}):e.type===2&&n.type===0?this.mu=this.mu.insert(t,{type:0,doc:e.doc}):e.type===1&&n.type===0?this.mu=this.mu.remove(t):e.type===1&&n.type===2?this.mu=this.mu.insert(t,{type:1,doc:n.doc}):e.type===0&&n.type===1?this.mu=this.mu.insert(t,{type:2,doc:e.doc}):Te(63341,{ye:e,pu:n}):this.mu=this.mu.insert(t,e)}gu(){const e=[];return this.mu.inorderTraversal(((t,n)=>{e.push(n)})),e}}class xu{constructor(e,t,n,i,o,u,B,f,g){this.query=e,this.docs=t,this.oldDocs=n,this.docChanges=i,this.mutatedKeys=o,this.fromCache=u,this.syncStateChanged=B,this.excludesMetadataChanges=f,this.hasCachedResults=g}static fromInitialDocuments(e,t,n,i,o){const u=[];return t.forEach((B=>{u.push({type:0,doc:B})})),new xu(e,t,vl.emptySet(t),u,n,i,!0,!1,o)}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)&&Sf(this.query,e.query)&&this.docs.isEqual(e.docs)&&this.oldDocs.isEqual(e.oldDocs)))return!1;const t=this.docChanges,n=e.docChanges;if(t.length!==n.length)return!1;for(let i=0;i<t.length;i++)if(t[i].type!==n[i].type||!t[i].doc.isEqual(n[i].doc))return!1;return!0}}/**
2634 * @license
2635 * Copyright 2017 Google LLC
2636 *
2637 * Licensed under the Apache License, Version 2.0 (the "License");
2638 * you may not use this file except in compliance with the License.
2639 * You may obtain a copy of the License at
2640 *
2641 *   http://www.apache.org/licenses/LICENSE-2.0
2642 *
2643 * Unless required by applicable law or agreed to in writing, softw
2643are
2644 * distributed under the License is distributed on an "AS IS" BASIS,
2645 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2646 * See the License for the specific language governing permissions and
2647 * limitations under the License.
2648 */class n5{constructor(){this.yu=void 0,this.wu=[]}bu(){return this.wu.some((e=>e.vu()))}}class s5{constructor(){this.queries=U_(),this.onlineState="Unknown",this.Su=new Set}terminate(){(function(t,n){const i=Se(t),o=i.queries;i.queries=U_(),o.forEach(((u,B)=>{for(const f of B.wu)f.onError(n)}))})(this,new ve(le.ABORTED,"Firestore shutting down"))}}function U_(){return new Ea((r=>lv(r)),Sf)}async function Yv(r,e){const t=Se(r);let n=3;const i=e.query;let o=t.queries.get(i);o?!o.bu()&&e.vu()&&(n=2):(o=new n5,n=e.vu()?0:1);try{switch(n){case 0:o.yu=await t.onListen(i,!0);break;case 1:o.yu=await t.onListen(i,!1);break;case 2:await t.onFirstRemoteStoreListen(i)}}catch(u){const B=l0(u,`Initialization of query '${Wt(e.query)?pa(e.query):Zc(e.query)}' failed`);return void e.onError(B)}t.queries.set(i,o),o.wu.push(e),e.Du(t.onlineState),o.yu&&e.xu(o.yu)&&u0(t)}async function Xv(r,e){const t=Se(r),n=e.query;let i=3;const o=t.queries.get(n);if(o){const u=o.wu.indexOf(e);u>=0&&(o.wu.splice(u,1),o.wu.length===0?i=e.vu()?0:1:!o.bu()&&e.vu()&&(i=2))}switch(i){case 0:return t.queries.delete(n),t.onUnlisten(n,!0);case 1:return t.queries.delete(n),t.onUnlisten(n,!1);case 2:return t.onLastRemoteStoreUnlisten(n);default:return}}function r5(r,e){const t=Se(r);let n=!1;for(const i of e){const o=i.query,u=t.queries.get(o);if(u){for(const B of u.wu)B.xu(i)&&(n=!0);u.yu=i}}n&&u0(t)}function a5(r,e,t){const n=Se(r),i=n.queries.get(e);if(i)for(const o of i.wu)o.onError(t);n.queries.delete(e)}function u0(r){r.Su.forEach((e=>{e.next()}))}var Wg;(function(r){r.Default="default",r.Cache="cache"})(Wg||(Wg={}));class $v{constructor(e,t,n){this.query=e,this.Cu=t,this.Fu=!1,this.Ou=null,this.onlineState="Unknown",this.options=n||{}}xu(e){if(!this.options.includeMetadataChanges){const n=[];for(const i of e.docChanges)i.type!==3&&n.push(i);e=new xu(e.query,e.docs,e.oldDocs,n,e.mutatedKeys,e.fromCache,e.syncStateChanged,!0,e.hasCachedResults)}let t=!1;return this.Fu?this.Mu(e)&&(this.Cu.next(e),t=!0):this.Nu(e,this.onlineState)&&(this.Lu(e),t=!0),this.Ou=e,t}onError(e){this.Cu.error(e)}Du(e){this.onlineState=e;let t=!1;return this.Ou&&!this.Fu&&this.Nu(this.Ou,e)&&(this.Lu(this.Ou),t=!0),t}Nu(e,t){if(!e.fromCache||!this.vu())return!0;const n=t!=="Offline";return(!this.options.waitForSyncWhenOnline||!n)&&(!e.docs.isEmpty()||e.hasCachedResults||t==="Offline")}Mu(e){if(e.docChanges.length>0)return!0;const t=this.Ou&&this.Ou.hasPendingWrites!==e.hasPendingWrites;return!(!e.syncStateChanged&&!t)&&this.options.includeMetadataChanges===!0}Lu(e){e=xu.fromInitialDocuments(e.query,e.docs,e.mutatedKeys,e.fromCache,e.hasCachedResults),this.Fu=!0,this.Cu.next(e)}vu(){return this.options.source!==Wg.Cache}}/**
2649 * @license
2650 * Copyright 2017 Google LLC
2651 *
2652 * Licensed under the Apache License, Version 2.0 (the "License");
2653 * you may not use this file except in compliance with the License.
2654 * You may obtain a copy of the License at
2655 *
2656 *   http://www.apache.org/licenses/LICENSE-2.0
2657 *
2658 * Unless required by applicable law or agreed to in writing, software
2659 * distributed under the License is distributed on an "AS IS" BASIS,
2660 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2661 * See the License for the specific language governing permissions and
2662 * limitations under the License.
2663 */class Zv{constructor(e){this.key=e}}class Wv{constructor(e){this.key=e}}class i5{constructor(e,t){this.query=e,this.Gu=t,this.zu=null,this.hasCachedResults=!1,this.current=!1,this.ju=Xe(),this.mutatedKeys=Xe(),this.Hu=Wt(e)?Jg(e):DC(e),this.Ju=new vl(this.Hu)}get Yu(){return this.Gu}Zu(e,t){const n=t?t.Xu:new H_,i=t?t.Ju:this.Ju;let o=t?t.mutatedKeys:this.mutatedKeys,u=i,B=!1;const[f,g]=this.ec(this.query,i);e.inorderTraversal(((b,D)=>{const T=i.get(b),M=Tv(this.query,D)?D:null,z=!!T&&this.mutatedKeys.has(T.key),W=!!M&&(M.hasLocalMutations||this.mutatedKeys.has(M.key)&&M.hasCommittedMutations);let K=!1;T&&M?T.data.isEqual(M.data)?z!==W&&(n.track({type:3,doc:M}),K=!0):this.tc(T,M)||(n.track({type:2,doc:M}),K=!0,(f&&this.Hu(M,f)>0||g&&this.Hu(M,g)<0)&&(B=!0)):!T&&M?(n.track({type:0,doc:M}),K=!0):T&&!M&&(n.track({type:1,doc:T}),K=!0,(f||g)&&(B=!0)),K&&(M?(u=u.add(M),o=W?o.add(b):o.delete(b)):(u=u.delete(b),o=o.delete(b)))}));const y=this.nc(this.query);if(y)if(Wt(this.query)){const b=[];u.forEach((M=>b.push(M)));const D=wv(this.query,b);let T=new vl(Jg(this.query));for(const M of D)T=T.add(M);u.forEach((M=>{T.has(M.key)||(o=o.delete(M.key),n.track({type:1,doc:M}))})),u=T}else{const b=this.rc(this.query);for(;u.size>y;){const D=b==="F"?u.last():u.first();u=u.delete(D.key),o=o.delete(D.key),n.track({type:1,doc:D})}}return{Ju:u,Xu:n,Fo:B,mutatedKeys:o}}nc(e){var t;return Wt(e)?(t=lg(e))==null?void 0:t.limit:e.limit||void 0}rc(e){if(Wt(e)){const t=lg(e);return t&&t.limit<0?"L":"F"}return e.limitType}ec(e,t){var n;if(Wt(e)){const i=(n=lg(e))==null?void 0:n.limit;return[t.size===i?t.last():null,null]}return[e.limitType==="F"&&t.size===this.nc(this.query)?t.last():null,e.limitType==="L"&&t.size===this.nc(this.query)?t.first():null]}tc(e,t){return e.hasLocalMutations&&t.hasCommittedMutations&&!t.hasLocalMutations}
2663applyChanges(e,t,n,i){const o=this.Ju;this.Ju=e.Ju,this.mutatedKeys=e.mutatedKeys;const u=e.Xu.gu();u.sort(((y,b)=>(function(T,M){const z=W=>{switch(W){case 0:return 1;case 2:case 3:return 2;case 1:return 0;default:return Te(20277,{ye:W})}};return z(T)-z(M)})(y.type,b.type)||this.Hu(y.doc,b.doc))),this.sc(n),i=i??!1;const B=t&&!i?this._c():[],f=this.ju.size===0&&this.current&&!i?1:0,g=f!==this.zu;return this.zu=f,u.length!==0||g?{snapshot:new xu(this.query,e.Ju,o,u,e.mutatedKeys,f===0,g,!1,!!n&&n.resumeToken.approximateByteSize()>0),oc:B}:{oc:B}}Du(e){return this.current&&e==="Offline"?(this.current=!1,this.applyChanges({Ju:this.Ju,Xu:new H_,mutatedKeys:this.mutatedKeys,Fo:!1},!1)):{oc:[]}}ac(e){return!this.Gu.has(e)&&!!this.Ju.has(e)&&!this.Ju.get(e).hasLocalMutations}sc(e){e&&(e.addedDocuments.forEach((t=>this.Gu=this.Gu.add(t))),e.modifiedDocuments.forEach((t=>{})),e.removedDocuments.forEach((t=>this.Gu=this.Gu.delete(t))),this.current=e.current)}_c(){if(!this.current)return[];const e=this.ju;this.ju=Xe(),this.Ju.forEach((n=>{this.ac(n.key)&&(this.ju=this.ju.add(n.key))}));const t=[];return e.forEach((n=>{this.ju.has(n)||t.push(new Wv(n))})),this.ju.forEach((n=>{e.has(n)||t.push(new Zv(n))})),t}uc(e){this.Gu=e.Wo,this.ju=Xe();const t=this.Zu(e.documents);return this.applyChanges(t,!0)}cc(){return xu.fromInitialDocuments(this.query,this.Ju,this.mutatedKeys,this.zu===0,this.hasCachedResults)}}const ku="SyncEngine";class l5{constructor(e,t,n){this.query=e,this.targetId=t,this.view=n}}class o5{constructor(e){this.key=e,this.lc=!1}}class u5{constructor(e,t,n,i,o,u){this.localStore=e,this.remoteStore=t,this.eventManager=n,this.sharedClientState=i,this.currentUser=o,this.maxConcurrentLimboResolutions=u,this.Ec={},this.hc=new Ea((B=>lv(B)),Sf),this.Tc=new Map,this.Pc=new Set,this.Rc=new Rt(De.comparator),this.Ic=new Map,this.Ac=new ZC,this.Vc={},this.dc=new Map,this.fc=xa.ws(),this.onlineState="Unknown",this.mc=void 0}get isPrimaryClient(){return this.mc===!0}}async function c5(r,e,t=!0){const n=Hf(r);let i;const o=n.hc.get(e);return o?(n.sharedClientState.addLocalQueryTarget(o.targetId),i=o.view.cc()):i=await ew(n,e,t,!0),i}async function B5(r,e){const t=Hf(r);await ew(t,e,!0,!1)}async function ew(r,e,t,n){const i=await of(r.localStore,Wt(e)?e:ws(e)),o=i.targetId,u=r.sharedClientState.addLocalQueryTarget(o,t);let B;return n&&(B=await c0(r,e,o,u==="current",i.resumeToken)),r.isPrimaryClient&&t&&Gf(r.remoteStore,i),B}async function c0(r,e,t,n,i){r.gc=(b,D,T)=>(async function(z,W,K,he){let de=W.view.Zu(K);de.Fo&&(de=await Qg(z.localStore,W.query,!1).then((({documents:S})=>W.view.Zu(S,de))));const ce=he&&he.targetChanges.get(W.targetId),_e=he&&he.targetMismatches.get(W.targetId)!=null,ye=W.view.applyChanges(de,z.isPrimaryClient,ce,_e);return eC(z,W.targetId,ye.oc),ye.snapshot})(r,b,D,T);const o=await Qg(r.localStore,e,!0),u=new i5(e,o.Wo),B=u.Zu(o.documents),f=LB.createSynthesizedTargetChangeForCurrentChange(t,n&&r.onlineState!=="Offline",i),g=u.applyChanges(B,r.isPrimaryClient,f);eC(r,t,g.oc);const y=new l5(e,t,u);return r.hc.set(e,y),r.Tc.has(t)?r.Tc.get(t).push(e):r.Tc.set(t,[e]),g.snapshot}async function h5(r,e,t){const n=Se(r),i=n.hc.get(e),o=n.Tc.get(i.targetId);if(o.length>1)return n.Tc.set(i.targetId,o.filter((u=>!Sf(u,e)))),void n.hc.delete(e);n.isPrimaryClient?(n.sharedClientState.removeLocalQueryTarget(i.targetId),n.sharedClientState.isActiveQueryTarget(i.targetId)||await yu(n.localStore,i.targetId,!1).then((()=>{n.sharedClientState.clearQueryState(i.targetId),t&&bu(n.remoteStore,i.targetId),Eu(n,i.targetId)})).catch(Ni)):(Eu(n,i.targetId),await yu(n.localStore,i.targetId,!0))}async function d5(r,e){const t=Se(r),n=t.hc.get(e),i=t.Tc.get(n.targetId);t.isPrimaryClient&&i.length===1&&(t.sharedClientState.removeLocalQueryTarget(n.targetId),bu(t.remoteStore,n.targetId))}async function f5(r,e,t){const n=f0(r);try{const i=await(function(u,B){const f=Se(u),g=xt.now(),y=B.reduce(((T,M)=>T.add(M.key)),Xe());let b,D;return f.persistence.runTransaction("Locally write mutations","readwrite",(T=>{let M=yn(),z=Xe();return f.Uo.getEntries(T,y).next((W=>{M=W,M.forEach(((K,he)=>{he.isValidDocument()||(z=z.add(K))}))})).next((()=>f.localDocuments.getOverlayedDocuments(T,M))).next((W=>{b=W;const K=[];for(const he of B){const de=YI(he,b.get(he.key).overlayedDocument);de!=null&&K.push(new Ai(he.key,de,Q1(de.value.mapValue),Ds.exists(!0)))}
2663return f.mutationQueue.addMutationBatch(T,g,K,B)})).next((W=>{D=W;const K=W.applyToLocalDocumentSet(b,z);return f.documentOverlayCache.saveOverlays(T,W.batchId,K)}))})).then((()=>({batchId:D.batchId,changes:fD(b)})))})(n.localStore,e);n.sharedClientState.addPendingMutation(i.batchId),(function(u,B,f){let g=u.Vc[u.currentUser.toKey()];g||(g=new Rt(Ue)),g=g.insert(B,f),u.Vc[u.currentUser.toKey()]=g})(n,i.batchId,t),await Si(n,i.changes),await Ru(n.remoteStore)}catch(i){const o=l0(i,"Failed to persist write");t.reject(o)}}async function tw(r,e){const t=Se(r);try{const n=await Vk(t.localStore,e);e.targetChanges.forEach(((i,o)=>{const u=t.Ic.get(o);u&&(fe(i.addedDocuments.size+i.modifiedDocuments.size+i.removedDocuments.size<=1,22616),i.addedDocuments.size>0?u.lc=!0:i.modifiedDocuments.size>0?fe(u.lc,14607):i.removedDocuments.size>0&&(fe(u.lc,42227),u.lc=!1))})),await Si(t,n,e)}catch(n){await Ni(n)}}function z_(r,e,t){const n=Se(r);if(n.isPrimaryClient&&t===0||!n.isPrimaryClient&&t===1){const i=[];n.hc.forEach(((o,u)=>{const B=u.view.Du(e);B.snapshot&&i.push(B.snapshot)})),(function(u,B){const f=Se(u);f.onlineState=B;let g=!1;f.queries.forEach(((y,b)=>{for(const D of b.wu)D.Du(B)&&(g=!0)})),g&&u0(f)})(n.eventManager,e),i.length&&n.Ec.hn(i),n.onlineState=e,n.isPrimaryClient&&n.sharedClientState.setOnlineState(e)}}async function m5(r,e,t){const n=Se(r);n.sharedClientState.updateQueryState(e,"rejected",t);const i=n.Ic.get(e),o=i&&i.key;if(o){let u=new Rt(De.comparator);u=u.insert(o,Zt.newNoDocument(o,Me.min()));const B=Xe().add(o),f=new Au(Me.min(),new Map,new Rt(Ue),u,yn(),B);await tw(n,f),n.Rc=n.Rc.remove(o),n.Ic.delete(e),d0(n)}else await yu(n.localStore,e,!1).then((()=>Eu(n,e,t))).catch(Ni)}async function p5(r,e){const t=Se(r),n=e.batch.batchId;try{const i=await Pk(t.localStore,e);h0(t,n,null),B0(t,n),t.sharedClientState.updateMutationState(n,"acknowledged"),await Si(t,i)}catch(i){await Ni(i)}}async function g5(r,e,t){const n=Se(r);try{const i=await(function(u,B){const f=Se(u);return f.persistence.runTransaction("Reject batch","readwrite-primary",(g=>{let y;return f.mutationQueue.lookupMutationBatch(g,B).next((b=>(fe(b!==null,37113),y=b.keys(),f.mutationQueue.removeMutationBatch(g,b)))).next((()=>f.mutationQueue.performConsistencyCheck(g))).next((()=>f.documentOverlayCache.removeOverlaysForBatchId(g,y,B))).next((()=>f.localDocuments.recalculateAndSaveOverlaysForDocumentKeys(g,y))).next((()=>f.localDocuments.getDocuments(g,y)))}))})(n.localStore,e);h0(n,e,t),B0(n,e),n.sharedClientState.updateMutationState(e,"rejected",t),await Si(n,i)}catch(i){await Ni(i)}}function B0(r,e){(r.dc.get(e)||[]).forEach((t=>{t.resolve()})),r.dc.delete(e)}function h0(r,e,t){const n=Se(r);let i=n.Vc[n.currentUser.toKey()];if(i){const o=i.get(e);o&&(t?o.reject(t):o.resolve(),i=i.remove(e)),n.Vc[n.currentUser.toKey()]=i}}function Eu(r,e,t=null){r.sharedClientState.removeLocalQueryTarget(e);for(const n of r.Tc.get(e))r.hc.delete(n),t&&r.Ec.yc(n,t);r.Tc.delete(e),r.isPrimaryClient&&r.Ac.Xs(e).forEach((n=>{r.Ac.containsKey(n)||nw(r,n)}))}function nw(r,e){r.Pc.delete(e.path.canonicalString());const t=r.Rc.get(e);t!==null&&(bu(r.remoteStore,t),r.Rc=r.Rc.remove(e),r.Ic.delete(t),d0(r))}function eC(r,e,t){for(const n of t)n instanceof Zv?(r.Ac.addReference(n.key,e),C5(r,n)):n instanceof Wv?(Be(ku,"Document no longer in limbo: "+n.key),r.Ac.removeReference(n.key,e),r.Ac.containsKey(n.key)||nw(r,n.key)):Te(19791,{wc:n})}function C5(r,e){const t=e.key,n=t.path.canonicalString();r.Rc.get(t)||r.Pc.has(n)||(Be(ku,"New document in limbo: "+t),r.Pc.add(n),d0(r))}function d0(r){for(;r.Pc.size>0&&r.Rc.size<r.maxConcurrentLimboResolutions;){const e=r.Pc.values().next().value;r.Pc.delete(e);const t=new De(ct.fromString(e)),n=r.fc.next();r.Ic.set(n,new o5(t)),r.Rc=r.Rc.insert(t,n),Gf(r.remoteStore,new kr(ws(kB(t.path)),n,"TargetPurposeLimboResolution",is.yn))}}async function Si(r,e,t){const n=Se(r),i=[],o=[],u=[];n.hc.isEmpty()||(n.hc.forEach(((B,f)=>{u.push(n.gc(f,e,t).then((g=>{var y;if((g||t)&&n.isPrimaryClient){const b=g?!g.fromCache:(y=t==null?void 0:t.targetChanges.get(f.targetId))==null?void 0:y.current;
2663n.sharedClientState.updateQueryState(f.targetId,b?"current":"not-current")}if(g){i.push(g);const b=t0.fo(f.targetId,g);o.push(b)}})))})),await Promise.all(u),n.Ec.hn(i),await(async function(f,g){const y=Se(f);try{await y.persistence.runTransaction("notifyLocalViewChanges","readwrite",(b=>U.forEach(g,(D=>U.forEach(D.Ao,(T=>y.persistence.referenceDelegate.addReference(b,D.targetId,T))).next((()=>U.forEach(D.Vo,(T=>y.persistence.referenceDelegate.removeReference(b,D.targetId,T)))))))))}catch(b){if(!Ii(b))throw b;Be(n0,"Failed to update sequence numbers: "+b)}for(const b of g){const D=b.targetId;if(!b.fromCache){const T=y.No.get(D),M=T.snapshotVersion,z=T.withLastLimboFreeSnapshotVersion(M);y.No=y.No.insert(D,z)}}})(n.localStore,o))}async function y5(r,e){const t=Se(r);if(!t.currentUser.isEqual(e)){Be(ku,"User change. New user:",e.toKey());const n=await kv(t.localStore,e);t.currentUser=e,(function(o,u){o.dc.forEach((B=>{B.forEach((f=>{f.reject(new ve(le.CANCELLED,u))}))})),o.dc.clear()})(t,"'waitForPendingWrites' promise is rejected due to a user change."),t.sharedClientState.handleUserChange(e,n.removedBatchIds,n.addedBatchIds),await Si(t,n.qo)}}function b5(r,e){const t=Se(r),n=t.Ic.get(e);if(n&&n.lc)return Xe().add(n.key);{let i=Xe();const o=t.Tc.get(e);if(!o)return i;for(const u of o??[]){const B=t.hc.get(u);i=i.unionWith(B.view.Yu)}return i}}async function x5(r,e){const t=Se(r),n=await Qg(t.localStore,e.query,!0),i=e.view.uc(n);return t.isPrimaryClient&&eC(t,e.targetId,i.oc),i}async function E5(r,e){const t=Se(r);return Yg(t.localStore,e).then((n=>Si(t,n)))}async function _5(r,e,t,n){const i=Se(r),o=await(function(B,f){const g=Se(B),y=Se(g.mutationQueue);return g.persistence.runTransaction("Lookup mutation documents","readonly",(b=>y.Wr(b,f).next((D=>D?g.localDocuments.getDocuments(b,D):U.resolve(null)))))})(i.localStore,e);o!==null?(t==="pending"?await Ru(i.remoteStore):t==="acknowledged"||t==="rejected"?(h0(i,e,n||null),B0(i,e),(function(B,f){Se(Se(B).mutationQueue).jr(f)})(i.localStore,e)):Te(6720,"Unknown batchState",{bc:t}),await Si(i,o)):Be(ku,"Cannot apply mutation batch with id: "+e)}async function D5(r,e){const t=Se(r);if(Hf(t),f0(t),e===!0&&t.mc!==!0){const n=t.sharedClientState.getAllActiveQueryTargets(),i=await q_(t,n.toArray());t.mc=!0,await $g(t.remoteStore,!0);for(const o of i)Gf(t.remoteStore,o)}else if(e===!1&&t.mc!==!1){const n=[];let i=Promise.resolve();t.Tc.forEach(((o,u)=>{t.sharedClientState.isLocalQueryTarget(u)?n.push(u):i=i.then((()=>(Eu(t,u),yu(t.localStore,u,!0)))),bu(t.remoteStore,u)})),await i,await q_(t,n),(function(u){const B=Se(u);B.Ic.forEach(((f,g)=>{bu(B.remoteStore,g)})),B.Ac.e_(),B.Ic=new Map,B.Rc=new Rt(De.comparator)})(t),t.mc=!1,await $g(t.remoteStore,!1)}}async function q_(r,e,t){const n=Se(r),i=[],o=[];for(const u of e){let B;const f=n.Tc.get(u);if(f&&f.length!==0){B=await of(n.localStore,Wt(f[0])?f[0]:ws(f[0]));for(const g of f){const y=n.hc.get(g),b=await x5(n,y);b.snapshot&&o.push(b.snapshot)}}else{const g=await jv(n.localStore,u);B=await of(n.localStore,g),await c0(n,sw(g),u,!1,B.resumeToken)}i.push(B)}return n.Ec.hn(o),i}function sw(r){return Ba(r)?r:BD(r.path,r.collectionGroup,r.orderBy,r.filters,r.limit,"F",r.startAt,r.endAt)}function v5(r){return(function(t){return Se(Se(t).persistence).Ro()})(Se(r).localStore)}async function w5(r,e,t,n){const i=Se(r);if(i.mc)return void Be(ku,"Ignoring unexpected query state notification.");const o=i.Tc.get(e);if(o&&o.length>0)switch(t){case"current":case"not-current":{let u;if(Wt(o[0]))switch(ma(o[0])){case"collection_group":case"collection":u=await Yg(i.localStore,av(o[0]));break;case"documents":u=await(function(g,y){const b=Se(g),D=Xe(...Wd(y).map((T=>De.fromPath(T))));return b.persistence.runTransaction("Get documents for pipeline","readonly",(T=>b.Uo.getEntries(T,D))).then((T=>T))})(i.localStore,o[0]);break;default:lr(""),u=Bl()}else u=await Yg(i.localStore,(function(g){return g.collectionGroup||(g.path.length%2==1?g.path.lastSegment():g.path.get(g.path.length-2))})(o[0]));const B=Au.createSynthesizedRemoteEventForCurrentChange(e,t==="current",qt.EMPTY_BYTE_STRING);await Si(i,u,B);break}case"rejected":await yu(i.localStore,e,!0),Eu(i,e,n);break;default:Te(64155,t)}}async function T5(r,e,t){const n=Hf(r);
vendor: 4,105 bytes, line 2663
2663if(n.mc){for(const i of e){if(n.Tc.has(i)&&n.sharedClientState.isActiveQueryTarget(i)){Be(ku,"Adding an already active target "+i);continue}const o=await jv(n.localStore,i),u=await of(n.localStore,o);await c0(n,sw(o),u.targetId,!1,u.resumeToken),Gf(n.remoteStore,u)}for(const i of t)n.Tc.has(i)&&await yu(n.localStore,i,!1).then((()=>{bu(n.remoteStore,i),Eu(n,i)})).catch(Ni)}}function Hf(r){const e=Se(r);return e.remoteStore.remoteSyncer.applyRemoteEvent=tw.bind(null,e),e.remoteStore.remoteSyncer.getRemoteKeysForTarget=b5.bind(null,e),e.remoteStore.remoteSyncer.rejectListen=m5.bind(null,e),e.Ec.hn=r5.bind(null,e.eventManager),e.Ec.yc=a5.bind(null,e.eventManager),e}function f0(r){const e=Se(r);return e.remoteStore.remoteSyncer.applySuccessfulWrite=p5.bind(null,e),e.remoteStore.remoteSyncer.rejectFailedWrite=g5.bind(null,e),e}class TB{constructor(){this.kind="memory",this.synchronizeTabs=!1}async initialize(e){this.serializer=_f(e.databaseInfo.databaseId),this.sharedClientState=this.vc(e),this.persistence=this.Sc(e),await this.persistence.start(),this.localStore=this.Dc(e),this.gcScheduler=this.xc(e,this.localStore),this.indexBackfillerScheduler=this.Cc(e,this.localStore)}xc(e,t){return null}Cc(e,t){return null}Dc(e){return Ov(this.persistence,new Rv,e.initialUser,this.serializer)}Sc(e){return new WC(Vf.w_,this.serializer)}vc(e){return new Jv}async terminate(){var e,t;(e=this.gcScheduler)==null||e.stop(),(t=this.indexBackfillerScheduler)==null||t.stop(),this.sharedClientState.shutdown(),await this.persistence.shutdown()}}TB.provider={build:()=>new TB};class A5 extends TB{constructor(e){super(),this.cacheSizeBytes=e}xc(e,t){fe(this.persistence.referenceDelegate instanceof lf,46915);const n=this.persistence.referenceDelegate.garbageCollector;return new GD(n,e.asyncQueue,t)}Sc(e){const t=this.cacheSizeBytes!==void 0?Fn.withCacheSize(this.cacheSizeBytes):Fn.DEFAULT;return new WC((n=>lf.w_(n,t)),this.serializer)}}class rw extends TB{constructor(e,t,n){super(),this.Fc=e,this.cacheSizeBytes=t,this.forceOwnership=n,this.kind="persistent",this.synchronizeTabs=!1}async initialize(e){await super.initialize(e),await this.Fc.initialize(this,e),await f0(this.Fc.syncEngine),await Ru(this.Fc.remoteStore),await this.persistence.X_((()=>(this.gcScheduler&&!this.gcScheduler.started&&this.gcScheduler.start(),this.indexBackfillerScheduler&&!this.indexBackfillerScheduler.started&&this.indexBackfillerScheduler.start(),Promise.resolve())))}Dc(e){return Ov(this.persistence,new Rv,e.initialUser,this.serializer)}xc(e,t){const n=this.persistence.referenceDelegate.garbageCollector;return new GD(n,e.asyncQueue,t)}Cc(e,t){const n=new t5(t,this.persistence);return new e5(e.asyncQueue,n)}Sc(e){const t=Sv(e.databaseInfo.databaseId,e.databaseInfo.persistenceKey),n=this.cacheSizeBytes!==void 0?Fn.withCacheSize(this.cacheSizeBytes):Fn.DEFAULT;return new e0(this.synchronizeTabs,t,e.clientId,n,e.asyncQueue,Qv(),Pd(),this.serializer,this.sharedClientState,!!this.forceOwnership)}vc(e){return new Jv}}class N5 extends rw{constructor(e,t){super(e,t,!1),this.Fc=e,this.cacheSizeBytes=t,this.synchronizeTabs=!0}async initialize(e){await super.initialize(e);const t=this.Fc.syncEngine;this.sharedClientState instanceof hg&&(this.sharedClientState.syncEngine={Iu:_5.bind(null,t),Au:w5.bind(null,t),Vu:T5.bind(null,t),Ro:v5.bind(null,t),Ru:E5.bind(null,t)},await this.sharedClientState.start()),await this.persistence.X_((async n=>{await D5(this.Fc.syncEngine,n),this.gcScheduler&&(n&&!this.gcScheduler.started?this.gcScheduler.start():n||this.gcScheduler.stop()),this.indexBackfillerScheduler&&(n&&!this.indexBackfillerScheduler.started?this.indexBackfillerScheduler.start():n||this.indexBackfillerScheduler.stop())}))}vc(e){const t=Qv();if(!hg.Je(t))throw new ve(le.UNIMPLEMENTED,"IndexedDB persistence is only available on platforms that support LocalStorage.");const n=Sv(e.databaseInfo.databaseId,e.databaseInfo.persistenceKey);return new hg(t,e.asyncQueue,n,e.clientId,e.initialUser)}}class AB{async initialize(e,t){this.localStore||(this.localStore=e.localStore,this.sharedClientState=e.sharedCl
2663ientState,this.datastore=this.createDatastore(t),this.remoteStore=this.createRemoteStore(t),this.eventManager=this.createEventManager(t),this.syncEngine=this.createSyncEngine(t,!e.synchronizeTabs),this.sharedClientState.onlineStateHandler=n=>z_(this.syncEngine,n,1),this.remoteStore.remoteSyncer.handleCredentialChange=y5.bind(null,this.syncEngine),await $g(this.remoteStore,this.syncEngine.isPrimaryClient))}createEventManager(e){return(function(){return new s5})()}createDatastore(e){const t=_f(e.databaseInfo.databaseId),n=GS(e.databaseInfo);return KS(e.authCredentials,e.appCheckCredentials,n,t)}createRemoteStore(e){return(function(n,i,o,u,B){return new Uk(n,i,o,u,B)})(this.localStore,this.datastore,e.asyncQueue,(t=>z_(this.syncEngine,t,0)),(function(){return l_.Je()?new l_:new MS})())}createSyncEngine(e,t){return(function(i,o,u,B,f,g,y){const b=new u5(i,o,u,B,f,g);return y&&(b.mc=!0),b})(this.localStore,this.remoteStore,this.eventManager,this.sharedClientState,e.initialUser,e.maxConcurrentLimboResolutions,t)}async terminate(){var e,t;await(async function(i){const o=Se(i);Be(Fr,"RemoteStore shutting down."),o.ca.add(5),await HB(o),o.Ea.shutdown(),o.ha.set("Unknown")})(this.remoteStore),(e=this.datastore)==null||e.terminate(),(t=this.eventManager)==null||t.terminate()}}AB.provider={build:()=>new AB};/**
2664 * @license
2665 * Copyright 2017 Google LLC
2666 *
2667 * Licensed under the Apache License, Version 2.0 (the "License");
2668 * you may not use this file except in compliance with the License.
2669 * You may obtain a copy of the License at
2670 *
2671 *   http://www.apache.org/licenses/LICENSE-2.0
2672 *
2673 * Unless required by applicable law or agreed to in writing, software
2674 * distributed under the License is distributed on an "AS IS" BASIS,
2675 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2676 * See the License for the specific language governing permissions and
2677 * limitations under the License.
2678 */const Ti="FirestoreClient";class I5{constructor(e,t,n,i,o){this.authCredentials=e,this.appCheckCredentials=t,this.asyncQueue=n,this._databaseInfo=i,this.user=Vn.UNAUTHENTICATED,this.clientId=BC.newId(),this.authCredentialListener=()=>Promise.resolve(),this.appCheckCredentialListener=()=>Promise.resolve(),this._uninitializedComponentsProvider=o,this.authCredentials.start(n,(async u=>{Be(Ti,"Received user=",u.uid),await this.authCredentialListener(u),this.user=u})),this.appCheckCredentials.start(n,(u=>(Be(Ti,"Received new app check token=",u),this.appCheckCredentialListener(u,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 fa;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(t){const n=l0(t,"Failed to shutdown persistence");e.reject(n)}})),e.promise}}async function dg(r,e){r.asyncQueue.verifyOperationInProgress(),Be(Ti,"Initializing OfflineComponentProvider");const t=r.configuration;await e.initialize(t);let n=t.initialUser;r.setCredentialChangeListener((async i=>{n.isEqual(i)||(await kv(e.localStore,i),n=i)})),e.persistence.setDatabaseDeletedListener((()=>r.terminate())),r._offlineComponents=e}async function K_(r,e){r.asyncQueue.verifyOperationInProgress();const t=await S5(r);Be(Ti,"Initializing OnlineComponentProvider"),await e.initialize(t,r.configuration),r.setCredentialChangeListener((n=>V_(e.remoteStore,n))),r.setAppCheckTokenChangeListener(((n,i)=>V_(e.remoteStore,i))),r._onlineComponents=e}async function S5(r){if(!r._offlineComponents)if(r._uninitializedComponentsProvider){Be(Ti,"Using user provided OfflineComponentProvider");try{await dg(r,r._uninitializedComponentsProvider._offline)}catch(e){const t=e;if(!(function(i){return i.name==="FirebaseError"?i.code===le.FAILED_PRECONDITION||i.code===le.UNIMPLEMENT
vendor: 5,570 bytes, lines 2678-2694
2678ED:!(typeof DOMException<"u"&&i instanceof DOMException)||i.code===22||i.code===20||i.code===11})(t))throw t;lr("Error using user provided cache. Falling back to memory cache: "+t),await dg(r,new TB)}}else Be(Ti,"Using default OfflineComponentProvider"),await dg(r,new A5(void 0));return r._offlineComponents}async function aw(r){return r._onlineComponents||(r._uninitializedComponentsProvider?(Be(Ti,"Using user provided OnlineComponentProvider"),await K_(r,r._uninitializedComponentsProvider._online)):(Be(Ti,"Using default OnlineComponentProvider"),await K_(r,new AB))),r._onlineComponents}function R5(r){return aw(r).then((e=>e.syncEngine))}async function tC(r){const e=await aw(r),t=e.eventManager;return t.onListen=c5.bind(null,e.syncEngine),t.onUnlisten=h5.bind(null,e.syncEngine),t.onFirstRemoteStoreListen=B5.bind(null,e.syncEngine),t.onLastRemoteStoreUnlisten=d5.bind(null,e.syncEngine),t}function O5(r,e,t,n){const i=new Uv(n),o=new $v(e,i,t);return r.asyncQueue.enqueueAndForget((async()=>Yv(await tC(r),o))),()=>{i.Aa(),r.asyncQueue.enqueueAndForget((async()=>Xv(await tC(r),o)))}}function iw(r,e,t={}){const n=new fa;return r.asyncQueue.enqueueAndForget((async()=>(function(o,u,B,f,g){const y=new Uv({next:D=>{y.Aa(),u.enqueueAndForget((()=>Xv(o,b)));const T=D.docs.has(B);!T&&D.fromCache?g.reject(new ve(le.UNAVAILABLE,"Failed to get document because the client is offline.")):T&&D.fromCache&&f&&f.source==="server"?g.reject(new ve(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.)')):g.resolve(D)},error:D=>g.reject(D)}),b=new $v(kB(B.path),y,{includeMetadataChanges:!0,waitForSyncWhenOnline:!0});return Yv(o,b)})(await tC(r),r.asyncQueue,e,t,n))),n.promise}function k5(r,e){const t=new fa;return r.asyncQueue.enqueueAndForget((async()=>f5(await R5(r),e,t))),t.promise}/**
2679 * @license
2680 * Copyright 2020 Google LLC
2681 *
2682 * Licensed under the Apache License, Version 2.0 (the "License");
2683 * you may not use this file except in compliance with the License.
2684 * You may obtain a copy of the License at
2685 *
2686 *   http://www.apache.org/licenses/LICENSE-2.0
2687 *
2688 * Unless required by applicable law or agreed to in writing, software
2689 * distributed under the License is distributed on an "AS IS" BASIS,
2690 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2691 * See the License for the specific language governing permissions and
2692 * limitations under the License.
2693 */const J_="AsyncQueue";class Q_{constructor(e=Promise.resolve()){this.Wc=[],this.Qc=!1,this.Gc=[],this.zc=null,this.jc=!1,this.Hc=!1,this.Jc=[],this.jt=new kD(this,"async_queue_retry"),this.Yc=()=>{const n=Pd();n&&Be(J_,"Visibility state changed to "+n.visibilityState),this.jt.qt()},this.Zc=e;const t=Pd();t&&typeof t.addEventListener=="function"&&t.addEventListener("visibilitychange",this.Yc)}get isShuttingDown(){return this.Qc}enqueueAndForget(e){this.enqueue(e)}enqueueAndForgetEvenWhileRestricted(e){this.Xc(),this.el(e)}enterRestrictedMode(e){if(!this.Qc){this.Qc=!0,this.Hc=e||!1;const t=Pd();t&&typeof t.removeEventListener=="function"&&t.removeEventListener("visibilitychange",this.Yc)}}enqueue(e){if(this.Xc(),this.Qc)return new Promise((()=>{}));const t=new fa;return this.el((()=>this.Qc&&this.Hc?Promise.resolve():(e().then(t.resolve,t.reject),t.promise))).then((()=>t.promise))}enqueueRetryable(e){this.enqueueAndForget((()=>(this.Wc.push(e),this.tl())))}async tl(){if(this.Wc.length!==0){try{await this.Wc[0](),this.Wc.shift(),this.jt.reset()}catch(e){if(!Ii(e))throw e;Be(J_,"Operation failed with retryable error: "+e)}this.Wc.length>0&&this.jt.Ut((()=>this.tl()))}}el(e){const t=this.Zc.then((()=>(this.jc=!0,e().catch((n=>{throw this.zc=n,this.jc=!1,sn("INTERNAL UNHANDLED ERROR: ",Y_(n)),n})).then((n=>(this.jc=!1,n))))));return this.Zc=t,t}enqueueAfterDelay(e,t,n){this.Xc(),this.Jc.indexOf(e)>-1&&(t=0);const i=i0.createAndSchedule(this,e,t,n,(o=>this.nl(o)));return this.Gc.push(i),i}Xc(){this.zc&&Te(47125,{rl:Y_(this.zc)})}verifyOperationInProgress(){}async il(){let e;do e=this.Zc,await e;while(e!==this.Zc)}sl(e){for(const t of this.Gc)if(t.timerId===e)return!0;return!1}_l(e){return this.il().then((()=>{this.Gc.sort(((t,n)=>t.targetTimeMs-n.targetTimeMs));for(const t of this.Gc)if(t.skipDelay(),e!=="all"&&t.timerId===e)break;return this.il()}))}ol(e){this.Jc.push(e)}nl(e){const t=this.Gc.indexOf(e);this.Gc.splice(t,1)}}function Y_(r){let e=r.message||"";return r.stack&&(e=r.stack.includes(r.message)?r.stack:r.message+`
2694`+r.stack),e}class _u extends UD{constructor(e,t,n,i){super(e,t,n,i),this.type="firestore",this._queue=new Q_,this._persistenceKey=(i==null?void 0:i.name)||"[DEFAULT]"}async _terminate(){if(this._firestoreClient){const e=this._firestoreClient.terminate();this._queue=new Q_(e),this._firestoreClient=void 0,await e}}}function L5(r,e,t){t||(t=zd);const n=PN(r,"firestore");if(n.isInitialized(t)){const i=n.getImmediate({identifier:t}),o=n.getOptions(t);if(Gd(o,e))return i;throw new ve(le.FAILED_PRECONDITION,"initializeFirestore() has already been called with different options. To avoid this error, call initializeFirestore() with the same options as when it was originally called, or call getFirestore() to return the already initialized instance.")}if(e.cacheSizeBytes!==void 0&&e.localCache!==void 0)throw new ve(le.INVALID_ARGUMENT,"cache and cacheSizeBytes cannot be specified at the same time as cacheSizeBytes willbe deprecated. Instead, specify the cache size in the cache object");
2694if(e.cacheSizeBytes!==void 0&&e.cacheSizeBytes!==-1&&e.cacheSizeBytes<FD)throw new ve(le.INVALID_ARGUMENT,"cacheSizeBytes must be at least 1048576");return e.host&&C1(e.host)&&F2(e.host),n.initialize({options:e,instanceIdentifier:t})}function Uf(r){if(r._terminated)throw new ve(le.FAILED_PRECONDITION,"The client has already been terminated.");return r._firestoreClient||j5(r),r._firestoreClient}function j5(r){var n,i,o,u;const e=r._freezeSettings(),t=QS(r._databaseId,((n=r._app)==null?void 0:n.options.appId)||"",r._persistenceKey,(i=r._app)==null?void 0:i.options.apiKey,e);r._componentsProvider||(o=e.localCache)!=null&&o._offlineComponentProvider&&((u=e.localCache)!=null&&u._onlineComponentProvider)&&(r._componentsProvider={_offline:e.localCache._offlineComponentProvider,_online:e.localCache._onlineComponentProvider}),r._firestoreClient=new I5(r._authCredentials,r._appCheckCredentials,r._queue,t,r._componentsProvider&&(function(f){const g=f==null?void 0:f._online.build();return{_offline:f==null?void 0:f._offline.build(g),_online:g}})(r._componentsProvider))}/**
2695 * @license
2696 * Copyright 2020 Google LLC
2697 *
2698 * Licensed under the Apache License, Version 2.0 (the "License");
2699 * you may not use this file except in compliance with the License.
2700 * You may obtain a copy of the License at
2701 *
2702 *   http://www.apache.org/licenses/LICENSE-2.0
2703 *
2704 * Unless required by applicable law or agreed to in writing, software
2705 * distributed under the License is distributed on an "AS IS" BASIS,
2706 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2707 * See the License for the specific language governing permissions and
2708 * limitations under the License.
2709 */class M5{convertValue(e,t="none"){switch(gn(e)){case 0:return null;case 1:return e.booleanValue;case 2:return Lt(e.integerValue||e.doubleValue);case 3:return this.convertTimestamp(e.timestampValue);case 4:return this.convertServerTimestamp(e,t);case 5:return e.stringValue;case 6:return this.convertBytes(ya(e.bytesValue));case 7:return this.convertReference(e.referenceValue);case 8:return this.convertGeoPoint(e.geoPointValue);case 9:return this.convertArray(e.arrayValue,t);case 11:return this.convertObject(e.mapValue,t);case 10:return this.convertVectorValue(e.mapValue);default:throw Te(62114,{value:e})}}convertObject(e,t){return this.convertObjectMap(e.fields,t)}convertObjectMap(e,t="none"){const n={};return Vl(e,((i,o)=>{n[i]=this.convertValue(o,t)})),n}convertVectorValue(e){var n,i,o;const t=(o=(i=(n=e.fields)==null?void 0:n[Ol].arrayValue)==null?void 0:i.values)==null?void 0:o.map((u=>Lt(u.doubleValue)));return new ls(t)}convertGeoPoint(e){return new Pr(Lt(e.latitude),Lt(e.longitude))}convertArray(e,t){return(e.values||[]).map((n=>this.convertValue(n,t)))}convertServerTimestamp(e,t){switch(t){case"previous":const n=OB(e);return n==null?null:this.convertValue(n,t);case"estimate":return this.convertTimestamp(ru(e));default:return null}}convertTimestamp(e){const t=Ca(e);return new xt(t.seconds,t.nanos)}convertDocumentKey(e,t){const n=ct.fromString(e);fe(ND(n),9688,{name:e});const i=new Rl(n.get(1),n.get(3)),o=new De(n.popFirst(5));return i.isEqual(t)||sn(`Document ${o} 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 (${t.projectId}/${t.database}) instead.`),o}}/**
2710 * @license
2711 * Copyright 2024 Google LLC
2712 *
2713 * Licensed under the Apache License, Version 2.0 (the "License");
2714 * you may not use this file except in compliance with the License.
2715 * You may obtain a copy of the License at
2716 *
2717 *   http://www.apache.org/licenses/LICENSE-2.0
2718 *
2719 * Unless required by applicable law or agreed to in writing, software
2720 * distributed under the License is distributed on an "AS IS" BASIS,
2721 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2722 * See the License for the specific language governing permissions and
2723 * limitations under the License.
2724 */class lw extends M5{constructor(e){super(),this.firestore=e}convertBytes(e){return new zs(e)}convertReference(e){const t=this.convertDocumentKey(e,this.firestore._databaseId);
2724return new rn(this.firestore,null,t)}}/**
2725 * @license
2726 * Copyright 2017 Google LLC
2727 *
2728 * Licensed under the Apache License, Version 2.0 (the "License");
2729 * you may not use this file except in compliance with the License.
2730 * You may obtain a copy of the License at
2731 *
2732 *   http://www.apache.org/licenses/LICENSE-2.0
2733 *
2734 * Unless required by applicable law or agreed to in writing, software
2735 * distributed under the License is distributed on an "AS IS" BASIS,
2736 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2737 * See the License for the specific language governing permissions and
2738 * limitations under the License.
2739 */function X_(r){return(function(t,n){if(typeof t!="object"||t===null)return!1;const i=t;for(const o of n)if(o in i&&typeof i[o]=="function")return!0;return!1})(r,["next","error","complete"])}const $_="@firebase/firestore",Z_="4.17.0";/**
2740 * @license
2741 * Copyright 2020 Google LLC
2742 *
2743 * Licensed under the Apache License, Version 2.0 (the "License");
2744 * you may not use this file except in compliance with the License.
2745 * You may obtain a copy of the License at
2746 *
2747 *   http://www.apache.org/licenses/LICENSE-2.0
2748 *
2749 * Unless required by applicable law or agreed to in writing, software
2750 * distributed under the License is distributed on an "AS IS" BASIS,
2751 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2752 * See the License for the specific language governing permissions and
2753 * limitations under the License.
2754 */let ow=class{constructor(e,t,n,i,o){this._firestore=e,this._userDataWriter=t,this._key=n,this._document=i,this._converter=o}get id(){return this._key.path.lastSegment()}get ref(){return new rn(this._firestore,this._converter,this._key)}exists(){return this._document!==null}data(){if(this._document){if(this._converter){const e=new P5(this._firestore,this._userDataWriter,this._key,this._document,null);return this._converter.fromFirestore(e)}return this._userDataWriter.convertValue(this._document.data.value)}}_fieldsProto(){var e;return((e=this._document)==null?void 0:e.data.clone().value.mapValue.fields)??void 0}get(e){if(this._document){const t=this._document.data.field(jB("DocumentSnapshot.get",e));if(t!==null)return this._userDataWriter.convertValue(t)}}},P5=class extends ow{data(){return super.data()}};/**
2755 * @license
2756 * Copyright 2020 Google LLC
2757 *
2758 * Licensed under the Apache License, Version 2.0 (the "License");
2759 * you may not use this file except in compliance with the License.
2760 * You may obtain a copy of the License at
2761 *
2762 *   http://www.apache.org/licenses/LICENSE-2.0
2763 *
2764 * Unless required by applicable law or agreed to in writing, software
2765 * distributed under the License is distributed on an "AS IS" BASIS,
2766 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2767 * See the License for the specific language governing permissions and
2768 * limitations under the License.
2769 */function V5(r){if(r.limitType==="L"&&r.explicitOrderBy.length===0)throw new ve(le.UNIMPLEMENTED,"limitToLast() queries require specifying at least one orderBy() clause")}function F5(r,e,t){let n;return n=r?t&&(t.merge||t.mergeFields)?r.toFirestore(e,t):r.toFirestore(e):e,n}class G5{constructor(e){let t;this.kind="persistent",e!=null&&e.tabManager?(e.tabManager._initialize(e),t=e.tabManager):(t=q5(void 0),t._initialize(e)),this._onlineComponentProvider=t._onlineComponentProvider,this._offlineComponentProvider=t._offlineComponentProvider}toJSON(){return{kind:this.kind}}}function H5(r){return new G5(r)}class U5{constructor(e){this.forceOwnership=e,this.kind="persistentSingleTab"}toJSON(){return{kind:this.kind}}_initialize(e){this._onlineComponentProvider=AB.provider,this._offlineComponentProvider={build:t=>new rw(t,e==null?void 0:e.cacheSizeBytes,this.forceOwnership)}}}class z5{constructor(){this.kind="PersistentMultipleTab"}toJSON(){return{kind:this.kind}}_initialize(e){this._onlineComponentProvider=AB.provider,this._offlineComponentProvider={build:t=>new N5(t,e==null?void 0:e.cacheSizeBytes)}}}function q5(r){return new U5(r==null?void 0:r.forceOwnership)}function K5(){return new z5}class Jc{constructor(e,t){this.hasPendingWrites=e,this.fromCache=t}isEqual(e){return this.hasPendingWrites===e.hasPendingWrites&&this.fromCache===e.fromCache}}class wl extends ow{constructor(e,t,n,i,o,u){super(e,t,n,i,u),this._firestore=e,this._firestoreImpl=e,this.metadata=o}exists(){return super.exists()}data(e={}){if(this._document){if(this._converter){const t=new Vd(this._firestore,this._userDataWriter,this._key,this._document,this.metadata,null);return this._converter.fromFirestore(t,e)}return this._userDataWriter.convertValue(this._document.data.value,e.serverTimestamps)}}get(e,t={}){if(this._document){const n=this._document.data.field(jB("DocumentSnapshot.get",e));if(n!==null)return this._userDataWriter.convertValue(n,t.serverTimestamps)}}toJSON(){if(this.metadata.hasPendingWrites)throw new ve(le.FAILED_PRECONDITION,"DocumentSnapshot.toJSON() attempted to serialize a document with pending writes. Await waitForPendingWrites() before invoking toJSON().");const e=this._document,t={};return t.type=wl._jsonSchemaVersion,t.bundle="",t.bundleSource="DocumentSnapshot",t.bundleName=this._key.toString(),!e||!e.isValidDocument()||!e.isFoundDocument()?t:(this._userDataWriter.convertObjectMap(e.data.value.mapValue.fields,"previous"),t.bundle=(this._firestore,this.ref.path,"NOT SUPPORTED"),t)}}wl._jsonSchemaVersion="firestore/documentSnapshot/1.0",wl._jsonSchema={type:pn("string",wl._jsonSchemaVersion),bundleSource:pn("string","DocumentSnapshot"),bundleName:pn("string"),bundle:pn("string")};class Vd extends wl{data(e={}){return super.data(e)}}class Zo{constructor(e,t,n,i){this._firestore=e,this._userDataWriter=t,this._snapshot=i,this.metadata=new Jc(i.hasPendingWrites,i.fromCache),this.query=n}get docs(){const e=[];return this.forEach((t=>e.push(t))),e}get size(){return this._snapshot.docs.size}get empty(){return this.size===0}forEach(e,t){this._snapshot.docs.forEach((n=>{e.call(t,new Vd(this._firestore,this._userDataWriter,n.key,n,new Jc(this._snapshot.mutatedKeys.has(n.key),this._snapshot.fromCache),this.query.converter))}))}docChanges(e={}){const t=!!e.includeMetadataChanges;if(t&&this._snapshot.excludesMetadataChanges)throw new ve(le.INVALID_ARGUMENT,"To include metadata changes with your document changes, you must also pass { includeMetadataChanges:true } to onSnapshot().");return this._cachedChanges&&this._cachedChangesIncludeMetadataChanges===t||(this._cachedChanges=(function(i,o){if(i._snapshot.oldDocs.isEmpty()){let u=0;return i._snapshot.docChanges.map((B=>
2769{Wt(i._snapshot.query)?Jg(i._snapshot.query):DC(i.query._query);const f=new Vd(i._firestore,i._userDataWriter,B.doc.key,B.doc,new Jc(i._snapshot.mutatedKeys.has(B.doc.key),i._snapshot.fromCache),i.query.converter);return B.doc,{type:"added",doc:f,oldIndex:-1,newIndex:u++}}))}{let u=i._snapshot.oldDocs;return i._snapshot.docChanges.filter((B=>o||B.type!==3)).map((B=>{const f=new Vd(i._firestore,i._userDataWriter,B.doc.key,B.doc,new Jc(i._snapshot.mutatedKeys.has(B.doc.key),i._snapshot.fromCache),i.query.converter);let g=-1,y=-1;return B.type!==0&&(g=u.indexOf(B.doc.key),u=u.delete(B.doc.key)),B.type!==1&&(u=u.add(B.doc),y=u.indexOf(B.doc.key)),{type:J5(B.type),doc:f,oldIndex:g,newIndex:y}}))}})(this,t),this._cachedChangesIncludeMetadataChanges=t),this._cachedChanges}toJSON(){if(this.metadata.hasPendingWrites)throw new ve(le.FAILED_PRECONDITION,"QuerySnapshot.toJSON() attempted to serialize a document with pending writes. Await waitForPendingWrites() before invoking toJSON().");const e={};e.type=Zo._jsonSchemaVersion,e.bundleSource="QuerySnapshot",e.bundleName=BC.newId(),this._firestore._databaseId.database,this._firestore._databaseId.projectId;const t=[],n=[],i=[];return this.docs.forEach((o=>{o._document!==null&&(t.push(o._document),n.push(this._userDataWriter.convertObjectMap(o._document.data.value.mapValue.fields,"previous")),i.push(o.ref.path))})),e.bundle=(this._firestore,this.query._query,e.bundleName,"NOT SUPPORTED"),e}}function J5(r){switch(r){case 0:return"added";case 2:case 3:return"modified";case 1:return"removed";default:return Te(61501,{type:r})}}/**
2770 * @license
2771 * Copyright 2022 Google LLC
2772 *
2773 * Licensed under the Apache License, Version 2.0 (the "License");
2774 * you may not use this file except in compliance with the License.
2775 * You may obtain a copy of the License at
2776 *
2777 *   http://www.apache.org/licenses/LICENSE-2.0
2778 *
2779 * Unless required by applicable law or agreed to in writing, software
2780 * distributed under the License is distributed on an "AS IS" BASIS,
2781 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2782 * See the License for the specific language governing permissions and
2783 * limitations under the License.
2784 */Zo._jsonSchemaVersion="firestore/querySnapshot/1.0",Zo._jsonSchema={type:pn("string",Zo._jsonSchemaVersion),bundleSource:pn("string","QuerySnapshot"),bundleName:pn("string"),bundle:pn("string")};/**
2785 * @license
2786 * Copyright 2020 Google LLC
2787 *
2788 * Licensed under the Apache License, Version 2.0 (the "License");
2789 * you may not use this file except in compliance with the License.
2790 * You may obtain a copy of the License at
2791 *
2792 *   http://www.apache.org/licenses/LICENSE-2.0
2793 *
2794 * Unless required by applicable law or agreed to in writing, software
2795 * distributed under the License is distributed on an "AS IS" BASIS,
2796 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2797 * See the License for the specific language governing permissions and
2798 * limitations under the License.
2799 */function uw(r){r=da(r,rn);const e=da(r.firestore,_u),t=Uf(e);return iw(t,r._key).then((n=>m0(e,r,n)))}function Q5(r){r=da(r,rn);const e=da(r.firestore,_u),t=Uf(e);return iw(t,r._key,{source:"server"}).then((n=>m0(e,r,n)))}function hf(r,e,t){r=da(r,rn);const n=da(r.firestore,_u),i=F5(r.converter,e,t),o=sR(n);return X5(n,[rR(o,"setDoc",r._key,i,r.converter!==null,t).toMutation(r._key,Ds.none())])}function Y5(r,...e){var g,y,b;r=iB(r);let t={includeMetadataChanges:!1,source:"default"},n=0;typeof e[n]!="object"||X_(e[n])||(t=e[n++]);const i={includeMetadataChanges:t.includeMetadataChanges,source:t.source};if(X_(e[n])){const D=e[n];e[n]=(g=D.next)==null?void 0:g.bind(D),e[n+1]=(y=D.error)==null?void 0:y.bind(D),e[n+2]=(b=D.complete)==null?void 0:b.bind(D)}let o,u,B;if(r instanceof rn)u=da(r.firestore,_u),B=kB(r._key.path),o={next:D=>{e[n]&&e[n](m0(u,r,D))},error:e[n+1],complete:e[n+2]};else{const D=da(r,vf);u=da(D.firestore,_u),B=D._query;const T=new lw(u);o={next:M=>{e[n]&&e[n](new Zo(u,T,D,M))},error:e[n+1],complete:e[n+2]},V5(r._query)}const f=Uf(u);return O5(f,B,i,o)}function X5(r,e){const t=Uf(r);return k5(t,e)}function m0(r,e,t){const n=t.docs.get(e._key),i=new lw(r);return new wl(r,i,e._key,n,new Jc(t.hasPendingWrites,t.fromCache),e.converter)}(function(e,t=!0){NI(HN),Hd(new lB("firestore",((n,{instanceIdentifier:i,options:o})=>{const u=n.getProvider("app").getImmediate(),B=new _u(new OS(n.getProvider("auth-internal")),new jS(u,n.getProvider("app-check-internal")),VI(u,i),u);return o={useFetchStreams:t,...o},B._setSettings(o),B}),"PUBLIC").setMultipleInstances(!0)),Xo($_,Z_,e),Xo($_,Z_,"esm2020")})();const $5="kancahjp",Z5="1:295753744164:web:11f00dde6fd093c107bdb1",W5="AIzaSyAoMm1Trwk722SPPTR742gmboACuOxx7AI",e4="kancahjp.firebaseapp.com",t4="ai-studio-kancah4dtestimon-3a521ee2-1c52-459f-a4e8-934a5e759b3c",n4="kancahjp.firebasestorage.app",s4="295753744164",r4="",a4="295753744164-5dope299d6lev2r3afgk74o0enoc02f2.apps.googleusercontent.com",i4="",cw={projectId:$5,appI
2799d:Z5,apiKey:W5,authDomain:e4,firestoreDatabaseId:t4,storageBucket:n4,messagingSenderId:s4,measurementId:r4,oAuthClientId:a4,recaptchaSiteKey:i4},l4=UN(cw),Pl=L5(l4,{localCache:H5({tabManager:K5()})},cw.firestoreDatabaseId);var xi=(r=>(r.CREATE="create",r.UPDATE="update",r.DELETE="delete",r.LIST="list",r.GET="get",r.WRITE="write",r))(xi||{});function Tl(r,e,t){const n={error:r instanceof Error?r.message:String(r),operationType:e,path:t,timestamp:new Date().toISOString()};return console.warn("Firestore Error Context:",JSON.stringify(n)),n}async function o4(){try{await Q5(Ll(Pl,"site_data","kancah4d_live"))}catch(r){r instanceof Error&&r.message.includes("the client is offline")&&console.warn("Please check your Firebase Firestore configuration or internet connection.")}}o4();const vs="site_data",Lr="kancah4d_live",nC="kancah4d_admin",p0="k4d_live_data_v1",g0="k4d_custom_admin_pin",u4="kancah2026";function zf(){try{const r=localStorage.getItem(p0);if(r){const e=JSON.parse(r);return{proofs:e.proofs||tu,banners:e.banners||eu,marqueeItems:e.marqueeItems||Nl,config:{...Wo,...e.config||{}},updatedAt:e.updatedAt||new Date().toISOString()}}}catch(r){console.warn("Could not read from localStorage",r)}return{proofs:tu,banners:eu,marqueeItems:Nl,config:Wo,updatedAt:new Date().toISOString()}}function df(r,e){try{const t=zf(),n={proofs:r.proofs!==void 0?r.proofs:t.proofs,banners:r.banners!==void 0?r.banners:t.banners,marqueeItems:r.marqueeItems!==void 0?r.marqueeItems:t.marqueeItems,config:r.config!==void 0?{...t.config,...r.config}:t.config,updatedAt:new Date().toISOString()};return localStorage.setItem(p0,JSON.stringify(n)),e&&localStorage.setItem(g0,e),window.dispatchEvent(new CustomEvent("k4d_local_update",{detail:n})),n}catch(t){return console.error("Could not save to localStorage",t),null}}function sC(r){var e,t;if(!(typeof window>"u"))try{const n=[];(e=r.config)!=null&&e.logoUrl&&n.push(r.config.logoUrl),r.banners&&((t=r.banners[0])!=null&&t.imageUrl)&&n.push(r.banners[0].imageUrl),n.forEach(o=>{const u=new Image;u.decoding="async",u.src=o});const i=()=>{var u;const o=[];r.banners&&((u=r.banners[1])!=null&&u.imageUrl)&&o.push(r.banners[1].imageUrl),r.proofs&&r.proofs.length>0&&r.proofs.slice(0,3).forEach(B=>{B.imageUrl&&o.push(B.imageUrl)}),o.forEach(B=>{const f=new Image;f.decoding="async",f.src=B})};"requestIdleCallback"in window?window.requestIdleCallback(i,{timeout:2500}):setTimeout(i,1500)}catch{}}function c4(r,e){try{const t=Ll(Pl,vs,Lr);return Y5(t,{includeMetadataChanges:!1},i=>{if(i.exists()){const o=i.data(),u={proofs:o.proofs||tu,banners:o.banners||eu,marqueeItems:o.marqueeItems||Nl,config:{...Wo,...o.config||{}},updatedAt:o.updatedAt||new Date().toISOString()};df(u),sC(u),r(u)}else{const o={proofs:tu,banners:eu,marqueeItems:Nl,config:Wo,updatedAt:new Date().toISOString()};hf(t,o,{merge:!0}).catch(u=>{Tl(u,xi.WRITE,`${vs}/${Lr}`)}),r(o)}},i=>{Tl(i,xi.GET,`${vs}/${Lr}`)})}catch(t){return Tl(t,xi.GET,`${vs}/${Lr}`),()=>{}}}async function B4(){try{const r=Ll(Pl,vs,Lr),e=await uw(r);if(e.exists()){const t=e.data(),n={proofs:t.proofs||tu,banners:t.banners||eu,marqueeItems:t.marqueeItems||Nl,config:{...Wo,...t.config||{}},updatedAt:t.updatedAt||new Date().toISOString()};return df(n),n}}catch(r){Tl(r,xi.GET,`${vs}/${Lr}`)}try{const r=new AbortController,e=setTimeout(()=>r.abort(),2e3),t=await fetch("/api/data",{signal:r.signal});if(clearTimeout(e),t.ok){const n=await t.json();if(n&&n.data)return df(n.data),n.data}}catch{}return zf()}async function h4(r){try{const t=Ll(Pl,vs,nC),n=await uw(t);if(n.exists()){const i=n.data();if(i&&i.pin)return r===i.pin?{success:!0,message:"Autentikasi Pemilik Berhasil!"}:{success:!1,message:"PIN rahasia salah! Akses ditolak."}}}catch(t){Tl(t,xi.GET,`${vs}/${nC}`)}const e=localStorage.getItem(g0);return e?r===e?{success:!0,message:"Autentikasi Pemilik Berhasil!"}:{success:!1,message:"PIN rahasia salah! Akses ditolak."}:r===u4?{success:!0,message:"Autentikasi Pemilik Berhasil!"}:{success:!1,message:"PIN rahasia salah! Akses ditolak."}}async function d4(r,e){const t=zf(),n={proofs:e.proofs!==void 0?e.proofs:t.proofs,banners:e.banners!==void 0?e.banners:t.banners,marqueeItems:e.marqueeItems!==void 0?e.marqueeItems:t.marqueeItems,config:e.config!==void 0?{...t.config,...e.config}:t.config,updatedAt:new Date().toISOString()};df(n,e.newPin);let i=!1;try{const o=Ll(Pl,vs,Lr);
2799if(await hf(o,n,{merge:!0}),i=!0,e.newPin){const u=Ll(Pl,vs,nC);await hf(u,{pin:e.newPin,updatedAt:new Date().toISOString()},{merge:!0})}}catch(o){Tl(o,xi.WRITE,`${vs}/${Lr}`)}try{const o=new AbortController,u=setTimeout(()=>o.abort(),2e3);await fetch("/api/admin/update",{method:"POST",headers:{"Content-Type":"application/json","x-admin-pin":r},body:JSON.stringify({pin:r,...e}),signal:o.signal}),clearTimeout(u)}catch{}return{success:!0,message:i?"Berhasil! Data tersimpan di Cloud Firebase & tersiar ke seluruh perangkat.":"Data tersimpan & diperbarui secara real-time!",updatedAt:n.updatedAt}}async function f4(r){const e={proofs:tu,banners:eu,marqueeItems:Nl,config:Wo,updatedAt:new Date().toISOString()};try{const t=Ll(Pl,vs,Lr);await hf(t,e)}catch(t){Tl(t,xi.WRITE,`${vs}/${Lr}`)}try{localStorage.removeItem(p0),localStorage.removeItem(g0)}catch{}return{success:!0,message:"Data berhasil direset ke setelan awal Kancah4D di Cloud Firebase."}}const m4=({isOpen:r,onClose:e,adminPin:t,proofs:n,banners:i,marqueeItems:o,config:u,onServerUpdateSuccess:B})=>{var ae,xe,Ae,Ge,Ke,We,Jt,Tt,or,Gr,Hr,Ur,cs,_a,ur,Da,va,Kt,Qt,Qs,Ul,Ri,En,cr,wa;const[f,g]=be.useState("header_footer"),[y,b]=be.useState(null),[D,T]=be.useState(!1),[M,z]=be.useState(!1),[W,K]=be.useState(null),[he,de]=be.useState(""),[ce,_e]=be.useState(n),[ye,S]=be.useState(i),[A,k]=be.useState(o),[w,O]=be.useState(u);Ks.useEffect(()=>{r&&(_e(n),S(i),k(o),O(u))},[r,n,i,o,u]);const[L,N]=be.useState({buttonLabel:`🎁 KANCAH4D | BUKTI MAXWIN ${new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase()}`,title:`🔥 KANCAH4D | BUKTI MAXWIN ${new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase()}`,date:new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase(),gameProvider:"PG Soft",gameName:"Mahjong Ways 2",imageUrl:"https://ik.imagekit.io/dxokd3m9y/tolkon.png",username:"r***88",winAmount:"Rp 64.850.000",betAmount:"Rp 12.000",multiplier:"x5404",badgeText:"HOT",badgeColor:"yellow",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"25x (Turbo Off)",spinAutoTurboOn:"70x (Turbo On)",spinAutoTurboOff:"40x (Turbo Off)",spinChance:"DC Aktif / Bet Bertingkat",jamHoki:"13:20 - 15:40 WIB & 20:15 - 22:45 WIB",rtpLive:"98.9%"},tips:"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal perkalian naga emas.",isHighlighted:!0}),Le=()=>{const Y=["10x (Turbo Off)","15x (Turbo Off)","20x (Turbo Off)","25x (Turbo Off)","30x (Turbo Off)","35x (Turbo Off)","10x (Quick Spin)"],ze=["30x (Turbo On)","50x (Turbo On)","70x (Turbo On)","80x (Turbo On)","100x (Turbo On)"],Ze=["20x (Turbo Off)","30x (Turbo Off)","40x (Turbo Off)","50x (Turbo Off)","70x (Turbo Off)"],At=["Rp 400","Rp 800","Rp 1.200","Rp 2.400","Rp 4.800","Rp 6.000","Rp 10.000","Rp 15.000","Rp 25.000","Rp 50.000"],Ft=["DC Aktif / Naikkan Bet 2x","DC Aktif / Bet Bertingkat / Beli Free Spin","DC ON + Beli Fitur Setelah 30 Spin Auto","DC OFF / Pola Bet Stabil Naik Bertahap","Beli Free Spin di Akhir Pola Spin Auto","DC Aktif / Spin Santai Pecah Maxwin","DC ON / Manual 20x Langsung Pecah Perkalian"],Gt=["Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal.","Awali dengan taruhan bet terendah, lalu naikkan bertahap saat scatter mulai sering muncul berdekatan.","Ikuti urutan pola spin secara disiplin dan beri jeda 10 detik setiap pergantian mode spin.","Kombinasikan Turbo On dan Off untuk memancing putaran gratis (Free Spins) pecah jackpot maxwin!","Gunakan o
2799psi DC Aktif jika dalam 20 spin manual sudah muncul minimal 2 simbol scatter naga emas.","Bila sudah mencapai profit 3x hingga 5x lipat dari modal awal, segera lakukan WD untuk amankan saldo!"],Ot=new Date,an=Ot.getHours(),zn=Ot.getMinutes(),Ht=Nn=>Nn.toString().padStart(2,"0"),zl=an%24,Ta=(an+2+Math.floor(Math.random()*2))%24,ql=zn<30?"00":"30",Ns=zn<30?"45":"15",zr=`${Ht(zl)}:${ql} - ${Ht(Ta)}:${Ns} WIB`,Yt=["98.2%","98.5%","98.8%","99.1%","99.4%","99.6%","99.8%"],_n=Nn=>Nn[Math.floor(Math.random()*Nn.length)];N(Nn=>({...Nn,betAmount:_n(At),tips:_n(Gt),polaGacor:{spinManual:_n(Y),spinAutoTurboOn:_n(ze),spinAutoTurboOff:_n(Ze),jamHoki:zr,rtpLive:_n(Yt),spinChance:_n(Ft)}}))};if(!r)return null;const Bt=Y=>{K(Y),setTimeout(()=>K(null),3500)},$=async Y=>{z(!0);const ze=await d4(t,Y);z(!1),ze.success?(Bt("✨ Berhasil tersimpan & tersiarkan REAL-TIME ke semua pemain!"),B()):Bt("❌ "+ze.message)},pe=async Y=>{if(Y.preventDefault(),!L.buttonLabel||!L.title)return;let ze;y?(ze=ce.map(Ze=>Ze.id===y?{...Ze,...L,id:y}:Ze),b(null)):(ze=[{...L,id:`jp-${Date.now()}`,createdAt:new Date().toISOString()},...ce],T(!1)),_e(ze),await $({proofs:ze})},Re=async Y=>{if(confirm("Hapus bukti kemenangan ini secara real-time?")){const ze=ce.filter(Ze=>Ze.id!==Y);_e(ze),await $({proofs:ze})}},qe=async(Y,ze)=>{const Ze=ze==="up"?Y-1:Y+1;if(Ze<0||Ze>=ce.length)return;const At=[...ce],Ft=At[Y];At[Y]=At[Ze],At[Ze]=Ft,_e(At),await $({proofs:At})},Ie=async Y=>{if(Y.preventDefault(),!he.trim()||he.trim().length<4){alert("PIN baru minimal 4 karakter!");return}await $({newPin:he.trim()}),de("")},P=async()=>{if(confirm("Kembalikan semua data ke pengaturan default Kancah4D di server?")){z(!0);const Y=await f4();z(!1),Y.success&&(Bt("Data di server berhasil di-reset!"),B(),e())}};return h.jsx("div",{className:"fixed inset-0 bg-black/90 backdrop-blur-md z-[999999] flex items-center justify-center p-3 sm:p-5 overflow-y-auto",children:h.jsxs("div",{className:"relative w-full max-w-4xl bg-[#0a1020] border-2 border-yellow-500/80 rounded-2xl p-4 sm:p-6 text-slate-100 shadow-[0_0_50px_rgba(234,179,8,0.25)] flex flex-col max-h-[92vh]",children:[h.jsxs("div",{className:"flex items-center justify-between pb-3 border-b border-slate-800",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-2 bg-yellow-500/20 text-yellow-400 rounded-lg border border-yellow-500/40",children:h.jsx(Sr,{className:"w-5 h-5"})}),h.jsxs("div",{children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("h2",{className:"text-base sm:text-lg font-black text-white uppercase tracking-wider",children:"Panel Pemilik KANCAH4D"}),h.jsxs("span",{className:"text-[10px] bg-emerald-500/20 text-emerald-400 border border-emerald-500/40 px-2 py-0.5 rounded-full font-bold flex items-center gap-1",children:[h.jsx(i1,{className:"w-2.5 h-2.5 animate-pulse text-emerald-400"}),"REAL-TIME SYNC"]})]}),h.jsx("p",{className:"text-xs text-slate-400",children:"Semua pembaruan langsung tampil otomatis ke layar pemain tanpa perlu reload."})]})]}),h.jsx("button",{onClick:e,className:"w-8 h-8 rounded-full bg-slate-800 hover:bg-slate-700 text-slate-300 hover:text-white flex items-center justify-center border border-slate-600 transition cursor-pointer",children:h.jsx(NB,{className:"w-5 h-5"})})]}),W&&h.jsxs("div",{className:"my-2 p-2.5 bg-emerald-950/80 border border-emerald-500/60 text-emerald-300 rounded-lg text-xs flex items-center gap-2 animate-fade-in font-bold",children:[h.jsx(Du,{className:"w-4 h-4 text-emerald-400"}),h.jsx("span",{children:W})]}),h.jsxs("div",{className:"flex items-center gap-2 border-b border-slate-800 py-2.5 overflow-x-auto text-xs font-bold",children:[h.jsxs("button",{onClick:()=>g("header_footer"),className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="header_footer"?"bg-yellow-500 text-slate-950 font-black shadow-[0_0_12px_rgba(234,179,8,0.5)]":"text-slate-400 hover:text-white hover:bg-slate-800/60"}`,children:[h.jsx(IA,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Tombol CTA, Link & Tampilan"})]}),h.jsxs("button",{onClick:()=>g("contacts"),className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="contacts"?"bg-cyan-500 text-slate-950 font-black shadow-[0_0_12px_rgba(6,182,212,0.5)]":"text-cyan-400 hover:text-white hover:bg-slate-800/60 border border-cyan-500/30"}`,children:[h.jsx(Qo,{className:"w-3.5 h-3.5 text-cyan-300"}),h.jsx("span",{children:"🎧 Layanan Resmi Kancah4D"})]}),h.jsxs("button",{onClick:()=>{g("proofs"),T(!1),b(null)},className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="proofs"?"bg-yellow-500 text-slate-950 font-black shadow-[0_0_12px_rgba(234,179,8,0.5)]":"text-slate-400 hover:text-white hover:bg-slate-800/60"}`,children:[h.jsx(Xx,{className:"w-3.5 h-3.5"}),h.jsxs("span",{children:["Bukti Jackpot (",ce.length,")"]})]}),h.jsxs("button",{onClick:()=>g("banners"),className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="banners"?"bg-yellow-500 text-slate-950 font-black shadow-[0_0_12px_rgba(234,179,8,0.5)]":"text-slate-400 hover:text-white hover:bg-slate-800/60"}`,children:[h.jsx(OA,{className:"w-3.5 h-3.5"}),h.jsxs("span",{children:["Slider Banner (",ye.length,")"]})]}),h.jsxs("button",{onClick:()=>g("marquee"),className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="marquee"?"bg-yellow-500 text-slate-950 font-black shadow-[0_0_12px_rgba(234,179,8,0.5)]":"text-slate-400 hover:text-white hover:bg-slate-800/60"}`,children:[h.jsx(Yo,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Teks Berjalan LED"})]}),h.jsxs("button",{onClick:()=>g("security"),className:`flex items-center gap-1.5 px-3 py-1.5 rounded-lg transition whitespace-nowrap cursor-pointer ${f==="security"?"bg-yellow-500 text-slate-950 font-black shadow-[0_0_12px_rgba(234,179,8,0.5)]":"text-slate-400 hover:text-white hover:bg-slate-800/60"}`,children:[h.jsx(pg,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Ganti PIN Rahasia"})]})]}),h.jsxs("div",{className:"flex-1 overflow-y-auto py-3 pr-1",children:[f==="header_footer"&&h.jsxs("div",{className:"space-y-4 text-xs",children:[h.jsxs("div",{className:"p-3.5 bg-[#070c18] border-2 border-yellow-500/60 rounded-xl space-y-3 shadow-[0_0_20px_rgba(234,179,8,0.15)]",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:[h.jsxs("h3",{className:"font-bold text-yellow-400 text-sm flex items-center gap-1.5",children:[h.jsx(bl,{className:"w-4 h-4 text-amber-400 animate-bounce"}),h.jsx("span",{children:"1. Tombol CTA Utama ke Website Resmi Kancah4D"})]}),h.jsxs("label",{className:"flex items-center gap-2 cursor-pointer text-slate-300 text-xs",children:[h.jsx("input",{type:"checkbox",checked:w.showMainCtaButton!==!1,onChange:Y=>O({...w,showMainCtaButton:Y.target.checked}),className:"w-4 h-4 accent-yellow-400 rounded cursor-pointer"}),h.jsx("span",{className:"font-bold text-emerald-400",children:"Tampilkan Tombol CTA"})]})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Judul Tombol CTA Utama"}),h.jsx("input",{type:"text",value:w.mainCtaText||"",onChange:Y=>O({...w,mainCtaText:Y.target.value}),placeholder:"🚀 KUNJUNGI WEBSITE UTAMA KANCAH4D",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-300 font-black focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL / Link Website Utama Anda"}),h.jsx("input",{type:"text",value:w.mainCtaUrl||"",onChange:Y=>O({...w,mainCtaUrl:Y.target.value}),placeholder:"https://kancah4d.com",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-cyan-300 font-mono focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Subteks / Keterangan di Bawah Tombol CTA (Opsional)"}),h.jsx("input",{type:"text",value:w.mainCtaSubtext||"",onChange:Y=>O({...w,mainCtaSubtext:Y.target.value}),placeholder:"Situs Resmi Slot Gacor & Bukti Maxwin Terpercaya 2026",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border-2 border-amber-500/70 rounded-xl space-y-3 shadow-[0_0_20px_rgba(245,158,11,0.15)]",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:[h.jsxs("h3",{className:"font-bold text-amber-400 text-sm flex items-center gap-1.5",children:[h.jsx(Sr,{className:"w-4 h-4 text-yellow-400"}),h.jsx("span",{children:"2. Popup Banner Promo Otomatis Saat Buka Website"})]}),h.jsxs("label",{className:"flex items-center gap-2 cursor-pointer text-slate-300 text-xs",children:[h.jsx("input",{type:"checkbox",checked:((ae=w.welcomePopup)==null?void 0:ae.enabled)!==!1,onChange:Y=>O({...w,welcomePopup:{imageUrl:"https://ik.imagekit.io/CBadak/ChatGPT%20Image%20Aug%2026,%202026,%2006_03_10%20PM.png",targetUrl:w.registerUrl||"https://kancah4d.com/register",...w.welcomePopup,enabled:Y.target.checked}}),className:"w-4 h-4 accent-yellow-400 rounded cursor-pointer"}),h.jsx("span",{className:"font-bold text-emerald-400",children:"Aktifkan Popup Promo"})]})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL Link Gambar Banner Promo"}),h.jsx("input",{type:"text",value:((xe=w.welcomePopup)==null?void 0:xe.imageUrl)||"",onChange:Y=>O({...w,welcomePopup:{enabled:!0,targetUrl:w.registerUrl||"https://kancah4d.com/register",...w.welcomePopup,imageUrl:Y.target.value}}),placeholder:"https://ik.imagekit.io/CBadak/ChatGPT%20Image%20Aug%2026,%202026,%2006_03_10%20PM.png",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-300 font-mono text-xs focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL / Link Tujuan Saat Gambar Diklik"}),h.jsx("input",{type:"text",value:((Ae=w.welcomePopup)==null?void 0:Ae.targetUrl)||"",onChange:Y=>O({...w,welcomePopup:{enabled:!0,imageUrl:"https://ik.imagekit.io/CBadak/ChatGPT%20Image%20Aug%2026,%202026,%2006_03_10%20PM.png",...w.welcomePopup,targetUrl:Y.target.value}}),placeholder:"https://kancah4d.com/register",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-cyan-300 font-mono text-xs focus:border-yellow-400 outline-none"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-blue-500/50 rounded-xl space-y-3",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:[h.jsxs("h3",{className:"font-bold text-cyan-400 text-sm flex items-center gap-1.5",children:[h.jsx(il,{className:"w-4 h-4"}),h.jsx("span",{children:"2. Pengaturan Tombol & Link di Modal Popup Bukti Jackpot"})]}),h.jsx("span",{className:"text-[10px] text-slate-400",children:"Ganti teks & link tombol popup"})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Tombol 1: Salin Pola"}),h.jsx("input",{type:"text",value:w.modalCopyButtonText||"",onChange:Y=>O({...w,modalCopyButtonText:Y.target.value}),placeholder:"Salin Pola",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white font-bold focus:border-cyan-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Tombol 2: Mainkan Pola"}),h.jsx("input",{type:"text",value:w.modalPlayButtonText||"",onChange:Y=>O({...w,modalPlayButtonText:Y.target.value}),placeholder:"Mainkan Pola",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-emerald-300 font-bold focus:border-cyan-400 outline-none"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:'URL Default Tombol "Mainkan Pola" (Jika bukti tidak memiliki link khusus)'}),h.jsx("input",{type:"text",value:w.modalPlayButtonUrl||"",onChange:Y=>O({...w,modalPlayButtonUrl:Y.target.value}),placeholder:"https://kancah4d.com/slots",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-emerald-400 font-mono focus:border-cyan-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Tombol 3: Login & Klaim Jackpot"}),h.jsx("input",{type:"text",value:w.modalClaimButtonText||"",onChange:Y=>O({...w,modalClaimButtonText:Y.target.value}),placeholder:"🚀 LOGIN & KLAIM JACKPOT SEKARANG",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-blue-300 font-bold focus:border-cyan-400 outline-none uppercase"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:'URL Default Tombol "Login & Klaim Jackpot"'}),h.jsx("input",{type:"text",value:w.modalClaimButtonUrl||"",onChange:Y=>O({...w,modalClaimButtonUrl:Y.target.value}),placeholder:"https://kancah4d.com/login",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-blue-400 font-mono focus:border-cyan-400 outline-none"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-slate-800 rounded-xl space-y-3",children:[h.jsx("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:h.jsxs("h3",{className:"font-bold text-yellow-400 text-sm flex items-center gap-1.5",children:[h.jsx(Sr,{className:"w-4 h-4"}),h.jsx("span",{children:"3. Logo, Favicon Tab Browser & Subtitle Header"})]})}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL Gambar / GIF Logo Header"}),h.jsx("input",{type:"text",value:w.logoUrl||"",onChange:Y=>O({...w,logoUrl:Y.target.value}),placeholder:"https://ik.imagekit.io/CBadak/logo.gif",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL Favicon Tab Browser (.png / .ico)"}),h.jsx("input",{type:"text",value:w.faviconUrl||"https://ik.imagekit.io/dxokd3m9y/favicon.png",onCh
2799ange:Y=>O({...w,faviconUrl:Y.target.value}),placeholder:"https://ik.imagekit.io/dxokd3m9y/favicon.png",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-300 focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Subtitle Header"}),h.jsx("input",{type:"text",value:w.headerSubtitle||"",onChange:Y=>O({...w,headerSubtitle:Y.target.value}),placeholder:"KANCAH4D | TESTIMONI KEMENANGAN 2026",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none uppercase font-bold"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-slate-800 rounded-xl space-y-3",children:[h.jsx("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:h.jsxs("h3",{className:"font-bold text-yellow-400 text-sm flex items-center gap-1.5",children:[h.jsx($x,{className:"w-4 h-4"}),h.jsx("span",{children:"4. Tombol DAFTAR AKUN VVIP"})]})}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Label / Teks Tombol"}),h.jsx("input",{type:"text",value:w.registerButtonText||"",onChange:Y=>O({...w,registerButtonText:Y.target.value}),placeholder:"DAFTAR AKUN VVIP",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none font-bold uppercase"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL Link Pendaftaran"}),h.jsx("input",{type:"text",value:w.registerUrl||"",onChange:Y=>O({...w,registerUrl:Y.target.value}),placeholder:"https://kancah4d.com/register",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-400 font-mono focus:border-yellow-400 outline-none"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-cyan-500/50 rounded-xl space-y-3",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:[h.jsxs("h3",{className:"font-bold text-cyan-400 text-sm flex items-center gap-1.5",children:[h.jsx(Qo,{className:"w-4 h-4 text-cyan-400"}),h.jsx("span",{children:"5. Link Hubungi Layanan Resmi Kancah4D"})]}),h.jsx("span",{className:"text-[10px] text-slate-400",children:"Atur link 5 tombol layanan resmi"})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsxs("label",{className:"text-slate-300 font-semibold mb-1 flex items-center gap-1.5",children:[h.jsx(wd,{className:"w-3.5 h-3.5 text-emerald-400"}),h.jsx("span",{children:"Link WhatsApp:"})]}),h.jsx("input",{type:"text",value:((Ge=w.socialLinks)==null?void 0:Ge.whatsapp)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,whatsapp:Y.target.value}}),placeholder:"https://wa.me/6281234567890",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-emerald-300 font-mono text-xs focus:border-emerald-400 outline-none"})]}),h.jsxs("div",{children:[h.jsxs("label",{className:"text-slate-300 font-semibold mb-1 flex items-center gap-1.5",children:[h.jsx(Td,{className:"w-3.5 h-3.5 text-cyan-400"}),h.jsx("span",{children:"Link Telegram:"})]}),h.jsx("input",{type:"text",value:((Ke=w.socialLinks)==null?void 0:Ke.telegram)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,telegram:Y.target.value}}),placeholder:"https://t.me/kancah4dofficial",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-cyan-300 font-mono text-xs focus:border-cyan-400 outline-none"})]}),h.jsxs("div",{children:[h.jsxs("label",{className:"text-slate-300 font-semibold mb-1 flex items-center gap-1.5",children:[h.jsx("span",{className:"font-bold font-sans text-xs",children:"𝕏"}),h.jsx("span",{children:"Link Twitter / X:"})]}),h.jsx("input",{type:"text",value:((We=w.socialLinks)==null?void 0:We.twitter)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,twitter:Y.target.value}}),placeholder:"https://x.com/kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-slate-200 font-mono text-xs focus:border-slate-400 outline-none"})]}),h.jsxs("div",{children:[h.jsxs("label",{className:"text-slate-300 font-semibold mb-1 flex items-center gap-1.5",children:[h.jsx(Ad,{className:"w-3.5 h-3.5 text-red-500"}),h.jsx("span",{children:"Link YouTube:"})]}),h.jsx("input",{type:"text",value:((Jt=w.socialLinks)==null?void 0:Jt.youtube)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,youtube:Y.target.value}}),placeholder:"https://youtube.com/@kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-red-300 font-mono text-xs focus:border-red-400 outline-none"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsxs("label",{className:"text-slate-300 font-semibold mb-1 flex items-center gap-1.5",children:[h.jsx(Yo,{className:"w-3.5 h-3.5 text-yellow-400"}),h.jsx("span",{children:"Link LiveChat 24H:"})]}),h.jsx("input",{type:"text",value:w.liveChatUrl||"",onChange:Y=>O({...w,liveChatUrl:Y.target.value}),placeholder:"https://direct.lc.chat/kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-300 font-mono text-xs focus:border-yellow-400 outline-none"})]})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-slate-800 rounded-xl space-y-3",children:[h.jsx("div",{className:"flex items-center justify-between border-b border-slate-800 pb-2",children:h.jsxs("h3",{className:"font-bold text-yellow-400 text-sm flex items-center gap-1.5",children:[h.jsx(Al,{className:"w-4 h-4 text-emerald-400"}),h.jsx("span",{children:"6. Footer & Lisensi"})]})}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Lisensi Footer"}),h.jsx("input",{type:"text",value:w.footerText||"",onChange:Y=>O({...w,footerText:Y.target.value}),placeholder:"OFFICIAL KANCAH4D • LISENSI RESMI",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none uppercase font-bold"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Teks Hak Cipta (Copyright)"}),h.jsx("input",{type:"text",value:w.copyrightText||"",onChange:Y=>O({...w,copyrightText:Y.target.value}),placeholder:"© 2026 KANCAH4D",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none uppercase font-bold"})]})]})]}),h.jsx("div",{className:"pt-2 flex justify-end",children:h.jsxs("button",{onClick:()=>$({config:w}),disabled:M,className:"px-5 py-2.5 bg-gradient-to-r from-emerald-600 to-teal-600 hover:from-emerald-500 hover:to-teal-500 text-white font-black text-xs uppercase tracking-wider rounded-xl shadow-[0_0_20px_rgba(16,185,129,0.4)] cursor-pointer flex items-center gap-2 transition active:scale-95",children:[h.jsx(jc,{className:"w-4 h-4"}),h.jsx("span",{children:M?"Menyimpan Real-Time...":"Simpan Semua Pengaturan Real-Time"})]})})]}),f==="contacts"&&h.jsxs("div",{className:"space-y-4 text-xs",children:[h.jsxs("div",{className:"p-4 bg-gradient-to-r from-[#071329] via-[#091a38] to-[#071329] border-2 border-cyan-500/70 rounded-xl shadow-[0_0_25px_rgba(6,182,212,0.25)] space-y-2",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-2 bg-cyan-500/20 text-cyan-300 rounded-lg border border-cyan-400/50 shadow-[0_0_12px_rgba(6,182,212,0.4)]",children:h.jsx(Qo,{className:"w-5 h-5 text-cyan-300"})}),h.jsxs("div",{children:[h.jsxs("h3",{className:"text-sm sm:text-base font-black text-white uppercase tracking-wider flex items-center gap-2",children:[h.jsx("span",{children:"🎧 Edit Link Layanan Resmi Kancah4D"}),h.jsx("span",{className:"text-[10px] bg-cyan-500/20 text-cyan-300 border border-cyan-400/40 px-2 py-0.5 rounded-full font-bold",children:"5 TOMBOL RESMI"})]}),h.jsx("p",{className:"text-[11px] text-slate-300",children:"Ubah dan ganti link untuk 5 tombol layanan resmi di bawah ini. Semua perubahan langsung terupdate secara real-time ke layar pemain."})]})]}),h.jsxs("div",{className:"mt-3 pt-3 border-t border-cyan-500/30",children:[h.jsxs("div",{className:"text-[11px] font-bold text-cyan-400 mb-1.5 flex items-center gap-1.5",children:[h.jsx(Sr,{className:"w-3.5 h-3.5 text-yellow-400"}),h.jsx("span",{children:"PREVIEW TAMPILAN LANGSUNG DI HALAMAN WEBSITE:"})]}),h.jsxs("div",{className:"w-full bg-[#071329]/95 rounded-xl border border-cyan-400/60 p-3 shadow-[0_0_15px_rgba(6,182,212,0.3)]",children:[h.jsxs("div",{className:"w-full flex items-center justify-center gap-2 mb-2.5",children:[h.jsx("span",{className:"h-[2px] w-6 bg-gradient-to-r from-transparent to-cyan-400"}),h.jsxs("h4",{className:"text-xs font-black tracking-wider text-cyan-300 uppercase flex items-center gap-1",children:[h.jsx(Qo,{className:"w-3.5 h-3.5 text-cyan-400"}),"HUBUNGI LAYANAN RESMI ",w.brandName||"KANCAH4D"]}),h.jsx("span",{className:"h-[2px] w-6 bg-gradient-to-l from-transparent to-cyan-400"})]}
2799),h.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-5 gap-2",children:[h.jsxs("a",{href:((Tt=w.socialLinks)==null?void 0:Tt.whatsapp)||"#",target:"_blank",rel:"noopener noreferrer",className:"p-2 rounded-lg bg-[#050e1f] border border-emerald-500/50 text-emerald-400 font-bold text-[11px] flex items-center justify-center gap-1 hover:bg-[#081a33] transition",children:[h.jsx(wd,{className:"w-3.5 h-3.5 text-emerald-400"}),h.jsx("span",{children:"WHATSAPP"})]}),h.jsxs("a",{href:((or=w.socialLinks)==null?void 0:or.telegram)||"#",target:"_blank",rel:"noopener noreferrer",className:"p-2 rounded-lg bg-[#050e1f] border border-cyan-500/50 text-cyan-300 font-bold text-[11px] flex items-center justify-center gap-1 hover:bg-[#081a33] transition",children:[h.jsx(Td,{className:"w-3.5 h-3.5 text-cyan-400"}),h.jsx("span",{children:"TELEGRAM"})]}),h.jsxs("a",{href:((Gr=w.socialLinks)==null?void 0:Gr.twitter)||"#",target:"_blank",rel:"noopener noreferrer",className:"p-2 rounded-lg bg-[#050e1f] border border-slate-500/50 text-slate-200 font-bold text-[11px] flex items-center justify-center gap-1 hover:bg-[#081a33] transition",children:[h.jsx("span",{className:"font-bold text-xs",children:"𝕏"}),h.jsx("span",{children:"TWITTER"})]}),h.jsxs("a",{href:((Hr=w.socialLinks)==null?void 0:Hr.youtube)||"#",target:"_blank",rel:"noopener noreferrer",className:"p-2 rounded-lg bg-[#050e1f] border border-red-500/50 text-red-400 font-bold text-[11px] flex items-center justify-center gap-1 hover:bg-[#081a33] transition",children:[h.jsx(Ad,{className:"w-3.5 h-3.5 text-red-500"}),h.jsx("span",{children:"YOUTUBE"})]}),h.jsxs("a",{href:w.liveChatUrl||"#",target:"_blank",rel:"noopener noreferrer",className:"p-2 rounded-lg bg-[#050e1f] border border-yellow-500/50 text-yellow-400 font-bold text-[11px] flex items-center justify-center gap-1 hover:bg-[#081a33] transition col-span-2 sm:col-span-1",children:[h.jsx(Yo,{className:"w-3.5 h-3.5 text-yellow-400"}),h.jsx("span",{children:"LIVECHAT 24H"})]})]})]})]})]}),h.jsxs("div",{className:"space-y-3",children:[h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-emerald-500/40 rounded-xl space-y-2 hover:border-emerald-400 transition",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{className:"font-bold text-emerald-400 flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 bg-emerald-500/20 rounded-lg text-emerald-400 border border-emerald-500/30",children:h.jsx(wd,{className:"w-4 h-4"})}),h.jsx("span",{children:"1. Link WhatsApp Resmi"})]}),((Ur=w.socialLinks)==null?void 0:Ur.whatsapp)&&h.jsxs("a",{href:w.socialLinks.whatsapp,target:"_blank",rel:"noopener noreferrer",className:"px-2 py-1 bg-emerald-500/20 hover:bg-emerald-500/40 text-emerald-300 rounded text-[10px] font-bold flex items-center gap-1 border border-emerald-500/30 transition",children:[h.jsx(il,{className:"w-3 h-3"}),h.jsx("span",{children:"Tes Buka Link"})]})]}),h.jsx("input",{type:"text",value:((cs=w.socialLinks)==null?void 0:cs.whatsapp)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,whatsapp:Y.target.value}}),placeholder:"https://wa.me/6281234567890",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2.5 text-emerald-300 font-mono text-xs focus:border-emerald-400 outline-none"}),h.jsxs("p",{className:"text-[10px] text-slate-400",children:["Contoh format: ",h.jsx("code",{className:"text-emerald-300 font-mono",children:"https://wa.me/6281234567890"})," atau link wa.link Anda."]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-cyan-500/40 rounded-xl space-y-2 hover:border-cyan-400 transition",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{className:"font-bold text-cyan-300 flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 bg-cyan-500/20 rounded-lg text-cyan-300 border border-cyan-500/30",children:h.jsx(Td,{className:"w-4 h-4"})}),h.jsx("span",{children:"2. Link Telegram Resmi / Channel"})]}),((_a=w.socialLinks)==null?void 0:_a.telegram)&&h.jsxs("a",{href:w.socialLinks.telegram,target:"_blank",rel:"noopener noreferrer",className:"px-2 py-1 bg-cyan-500/20 hover:bg-cyan-500/40 text-cyan-200 rounded text-[10px] font-bold flex items-center gap-1 border border-cyan-500/30 transition",children:[h.jsx(il,{className:"w-3 h-3"}),h.jsx("span",{children:"Tes Buka Link"})]})]}),h.jsx("input",{type:"text",value:((ur=w.socialLinks)==null?void 0:ur.telegram)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,telegram:Y.target.value}}),placeholder:"https://t.me/kancah4dofficial",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2.5 text-cyan-300 font-mono text-xs focus:border-cyan-400 outline-none"}),h.jsxs("p",{className:"text-[10px] text-slate-400",children:["Contoh format: ",h.jsx("code",{className:"text-cyan-300 font-mono",children:"https://t.me/kancah4dofficial"})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-slate-600/50 rounded-xl space-y-2 hover:border-slate-400 transition",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{className:"font-bold text-slate-200 flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 bg-slate-700/40 rounded-lg text-white border border-slate-600/50 font-bold px-2",children:"𝕏"}),h.jsx("span",{children:"3. Link Twitter / X"})]}),((Da=w.socialLinks)==null?void 0:Da.twitter)&&h.jsxs("a",{href:w.socialLinks.twitter,target:"_blank",rel:"noopener noreferrer",className:"px-2 py-1 bg-slate-700/40 hover:bg-slate-700/80 text-white rounded text-[10px] font-bold flex items-center gap-1 border border-slate-600 transition",children:[h.jsx(il,{className:"w-3 h-3"}),h.jsx("span",{children:"Tes Buka Link"})]})]}),h.jsx("input",{type:"text",value:((va=w.socialLinks)==null?void 0:va.twitter)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,twitter:Y.target.value}}),placeholder:"https://x.com/kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2.5 text-slate-100 font-mono text-xs focus:border-slate-400 outline-none"}),h.jsxs("p",{className:"text-[10px] text-slate-400",children:["Contoh format: ",h.jsx("code",{className:"text-slate-300 font-mono",children:"https://x.com/kancah4d"})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-red-500/40 rounded-xl space-y-2 hover:border-red-400 transition",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{className:"font-bold text-red-400 flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 bg-red-500/20 rounded-lg text-red-400 border border-red-500/30",children:h.jsx(Ad,{className:"w-4 h-4"})}),h.jsx("span",{children:"4. Link YouTube Channel"})]}),((Kt=w.socialLinks)==null?void 0:Kt.youtube)&&h.jsxs("a",{href:w.socialLinks.youtube,target:"_blank",rel:"noopener noreferrer",className:"px-2 py-1 bg-red-500/20 hover:bg-red-500/40 text-red-200 rounded text-[10px] font-bold flex items-center gap-1 border border-red-500/30 transition",children:[h.jsx(il,{className:"w-3 h-3"}),h.jsx("span",{children:"Tes Buka Link"})]})]}),h.jsx("input",{type:"text",value:((Qt=w.socialLinks)==null?void 0:Qt.youtube)||"",onChange:Y=>O({...w,socialLinks:{...w.socialLinks,youtube:Y.target.value}}),placeholder:"https://youtube.com/@kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2.5 text-red-300 font-mono text-xs focus:border-red-400 outline-none"}),h.jsxs("p",{className:"text-[10px] text-slate-400",children:["Contoh format: ",h.jsx("code",{className:"text-red-300 font-mono",children:"https://youtube.com/@kancah4d"})]})]}),h.jsxs("div",{className:"p-3.5 bg-[#070c18] border border-yellow-500/50 rounded-xl space-y-2 hover:border-yellow-400 transition shadow-[0_0_15px_rgba(234,179,8,0.1)]",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{className:"font-bold text-yellow-400 flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 bg-yellow-500/20 rounded-lg text-yellow-400 border border-yellow-500/30",children:h.jsx(Yo,{className:"w-4 h-4"})}),h.jsx("span",{children:"5. Link LiveChat 24H Nonstop"})]}),w.liveChatUrl&&h.jsxs("a",{href:w.liveChatUrl,target:"_blank",rel:"noopener noreferrer",className:"px-2 py-1 bg-yellow-500/20 hover:bg-yellow-500/40 text-yellow-200 rounded text-[10px] font-bold flex items-center gap-1 border border-yellow-500/30 transition",children:[h.jsx(il,{className:"w-3 h-3"}),h.jsx("span",{children:"Tes Buka Link"})]})]}),h.jsx("input",{type:"text",value:w.liveChatUrl||"",onChange:Y=>O({...w,liveChatUrl:Y.target.value}),placeholder:"https://direct.lc.chat/kancah4d",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2.5 text-yellow-300 font-mono text-xs focus:border-yellow-400 outline-none"}),h.jsxs("p",{className:"text-[10px] text-slate-400",children:["Contoh: ",h.jsx("code",{className:"text-yellow-300 font-mono",children:"https://direct.lc.chat/kancah4d"}),", Tawk.to, Zendesk, atau URL livechat situs Anda."]})]})]}),h.jsx("div",{className:"pt-2 flex justify-end",children:h.jsxs("button",{onClick:()=>$({config:w}),disabled:M,className:"px-6 py-3 bg-gradient-to-r from-cyan-600 via-teal-600 to-emerald-600 hover:from-cyan-500 hover:to-emerald-500 text-white font-black text-xs uppercase tracking-wider rounded-xl shadow-[0_0_25px_rgba(6,182,212,0.4)] cursor-pointer flex items-center gap-2 transition active:scale-95",children:[h.jsx(jc,{className:"w-4 h-4"}),h.jsx("span",{children:M?"Menyimpan Real-Time...":"Simpan Perubahan Link Layanan Resmi Real-Time"})]})})]}),f==="proofs"&&h.jsxs("div",{children:[D||y?h.jsxs("form",{onSubmit:pe,className:"bg-[#0e162a] p-4 rounded-xl border border-yellow-500/50 mb-4 space-y-3",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-700 pb-2",children:[h.jsxs("h3",{className:"text-sm font-bold text-yellow-400 flex items-center gap-2",children:[h.jsx(Xx,{className:"w-4 h-4"}),h.jsx("span",{children:y?"✏️ Edit Bukti Jackpot":"➕ Tambah Bukti Jackpot Baru"})]}),h.jsx("button",{type:"button",onClick:()=>{T(!1),b(null)},className:"text-xs text-slate-400 hover:text-white",children:"Batal"})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3 text-xs",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Label Tombol"}),h.jsx("input",{type:"text",value:L.buttonLabel||"",onChange:Y=>N({...L,buttonLabel:Y.target.value}),placeholder:"🎁 KANCAH4D | BUKTI MAXWIN 20 AUG 2026",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none",required:!0})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Judul di Popup (Modal)"}),h.jsx("input",{type:"text",value:L.title||"",onChange:Y=>N({...L,title:Y.target.value}),placeholder:"🔥 KANCAH4D | BUKTI MAXWIN 20 AUG 2026",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none",required:!0})]}),h.jsxs("div",{className:"p-2.5 bg-[#070b14] border border-yellow-500/40 rounded-lg space-y-2 sm:col-span-2",children:[h.jsxs("div",{className:"flex items-center gap-1.5 text-yellow-400 font-bold",children:[h.jsx(u2,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"🏷️ Teks & Warna Badge Tombol (HOT / MAXWIN / VIP / GACOR)"})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-300 block mb-1",children:"Teks Badge (Kosongkan jika tidak ingin badge muncul):"}),h.jsx("input",{type:"text",value:L.badgeText!==void 0?L.badgeText:L.isHighlighted?"HOT":"",onChange:Y=>N({...L,badgeText:Y.target.value,isHighlighted:Y.target.value.trim().length>0}),placeholder:"Contoh: HOT, MAXWIN, GACOR, VIP, JP",className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-yellow-300 font-black uppercase outline-none focus:border-yellow-400"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-300 block mb-1",children:"Warna Badge:"}),h.jsxs("select",{value:L.badgeColor||"yellow",onChange:Y=>N({...L,badgeColor:Y.target.value}),className:"w-full bg-[#0c1222] border border-slate-700 rounded-lg p-2 text-white font-bold outline-none focus:border-yellow-400",children:[h.jsx("option",{value:"yellow",children:"🟡 Kuning Emas (Default)"}),h.jsx("option",{value:"red",children:"🔴 Merah Api (Hot Gacor)"}),h.jsx("option",{value:"green",children:"🟢 Hijau Neon (Maxwin)"}),h.jsx("option",{value:"blue",children:"🔵 Biru Kilat (Sensational)"}),h.jsx("option",{value:"purple",children:"🟣 Ungu VIP (Exclusive)"})]})]})]})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Nama Game"}),h.jsx("input",{type:"text",value:L.gameName||"",onChange:Y=>N({...L,gameName:Y.target.value}
2799),placeholder:"Mahjong Ways 2 / Gates of Olympus",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none",required:!0})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Provider Game"}),h.jsxs("select",{value:L.gameProvider||"PG Soft",onChange:Y=>N({...L,gameProvider:Y.target.value}),className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none",children:[h.jsx("option",{value:"PG Soft",children:"PG Soft"}),h.jsx("option",{value:"Pragmatic Play",children:"Pragmatic Play"}),h.jsx("option",{value:"Habanero",children:"Habanero"}),h.jsx("option",{value:"Spadegaming",children:"Spadegaming"}),h.jsx("option",{value:"Microgaming",children:"Microgaming"}),h.jsx("option",{value:"NoLimit City",children:"NoLimit City"})]})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"URL Gambar Bukti Screenshot"}),h.jsx("input",{type:"text",value:L.imageUrl||"",onChange:Y=>N({...L,imageUrl:Y.target.value}),placeholder:"https://ik.imagekit.io/dxokd3m9y/tolkon.png",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none",required:!0})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Member ID / Username"}),h.jsx("input",{type:"text",value:L.username||"",onChange:Y=>N({...L,username:Y.target.value}),placeholder:"r***88",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-cyan-300 font-bold focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"💰 Total Kemenangan (Total WD)"}),h.jsx("input",{type:"text",value:L.winAmount||"",onChange:Y=>N({...L,winAmount:Y.target.value}),placeholder:"Rp 64.850.000",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-yellow-400 font-black focus:border-yellow-400 outline-none text-sm",required:!0})]}),h.jsxs("div",{children:[h.jsxs("label",{className:"block text-emerald-400 font-black mb-1 flex items-center gap-1",children:[h.jsx("span",{children:"⚡ PERKALIAN (Multiplier Maxwin)"}),h.jsx("span",{className:"text-[10px] bg-emerald-500/20 px-1.5 py-0.5 rounded text-emerald-300",children:"Wajib"})]}),h.jsx("input",{type:"text",value:L.multiplier||"",onChange:Y=>N({...L,multiplier:Y.target.value}),placeholder:"x5404 / x5000 / x1000",className:"w-full bg-[#070b14] border-2 border-emerald-500/80 rounded-lg p-2 text-emerald-300 font-black focus:border-emerald-400 outline-none text-sm shadow-[0_0_10px_rgba(16,185,129,0.2)]",required:!0})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Taruhan / Bet"}),h.jsx("input",{type:"text",value:L.betAmount||"",onChange:Y=>N({...L,betAmount:Y.target.value}),placeholder:"Rp 12.000",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white font-bold focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"Opsi Double Chance / Fitur"}),h.jsx("input",{type:"text",value:((Qs=L.polaGacor)==null?void 0:Qs.spinChance)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,spinChance:Y.target.value}}),placeholder:"DC Aktif / Bet Bertingkat / Beli Free Spin",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-white focus:border-yellow-400 outline-none"})]})]}),h.jsxs("div",{className:"p-3 bg-[#070b14] border border-cyan-500/40 rounded-lg space-y-2 text-xs",children:[h.jsxs("div",{className:"flex items-center gap-1.5 text-cyan-400 font-bold",children:[h.jsx($x,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"🔗 Link Tombol Khusus untuk Bukti Ini (Opsional - Kosongkan jika ingin pakai link default)"})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-300 block mb-1",children:'Link Khusus Tombol "Mainkan Pola":'}),h.jsx("input",{type:"text",value:L.playUrl||"",onChange:Y=>N({...L,playUrl:Y.target.value}),placeholder:"https://kancah4d.com/slots?game=mahjong2",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-2 text-emerald-300 font-mono text-xs"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-300 block mb-1",children:'Link Khusus Tombol "Login & Klaim Jackpot":'}),h.jsx("input",{type:"text",value:L.claimUrl||"",onChange:Y=>N({...L,claimUrl:Y.target.value}),placeholder:"https://kancah4d.com/login",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-2 text-blue-300 font-mono text-xs"})]})]})]}),h.jsxs("div",{className:"text-xs",children:[h.jsxs("div",{className:"flex items-center justify-between mb-1",children:[h.jsx("label",{className:"block text-slate-300 font-semibold",children:"💡 Tips Bermain / Trik Maxwin"}),h.jsxs("button",{type:"button",onClick:Le,className:"flex items-center gap-1 text-[11px] bg-gradient-to-r from-amber-500 to-yellow-400 hover:from-amber-400 hover:to-yellow-300 text-slate-950 font-black px-2.5 py-1 rounded shadow-[0_0_10px_rgba(234,179,8,0.4)] transition cursor-pointer active:scale-95",title:"Acak semua pola spin, jam hoki, RTP, bet, dan tips sekaligus",children:[h.jsx(Yx,{className:"w-3.5 h-3.5 animate-spin",style:{animationDuration:"4s"}}),h.jsx("span",{children:"🎲 Acak Hasil Pola & Jam Hoki (RNG)"})]})]}),h.jsx("input",{type:"text",value:L.tips||"",onChange:Y=>N({...L,tips:Y.target.value}),placeholder:"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal...",className:"w-full bg-[#070b14] border border-slate-700 rounded-lg p-2 text-slate-200 focus:border-yellow-400 outline-none"})]}),h.jsxs("div",{className:"p-3 bg-[#070b14] rounded-lg border border-slate-800 space-y-2 text-xs",children:[h.jsxs("div",{className:"flex items-center justify-between border-b border-slate-800/80 pb-1.5",children:[h.jsxs("div",{className:"text-emerald-400 font-bold flex items-center gap-1.5",children:[h.jsx(bl,{className:"w-3.5 h-3.5 text-yellow-400"}),h.jsx("span",{children:"⚡ Pengaturan Pola Gacor:"})]}),h.jsxs("button",{type:"button",onClick:Le,className:"text-[10px] text-yellow-400 hover:text-yellow-300 font-bold underline cursor-pointer flex items-center gap-1",children:[h.jsx(Yx,{className:"w-3 h-3"}),h.jsx("span",{children:"Acak Pola Baru"})]})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-400",children:"Spin Manual (Turbo Off)"}),h.jsx("input",{type:"text",value:((Ul=L.polaGacor)==null?void 0:Ul.spinManual)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,spinManual:Y.target.value}}),placeholder:"30x",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-400",children:"Spin Auto (Turbo On)"}),h.jsx("input",{type:"text",value:((Ri=L.polaGacor)==null?void 0:Ri.spinAutoTurboOn)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,spinAutoTurboOn:Y.target.value}}),placeholder:"80x",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-400",children:"Spin Auto (Turbo Off)"}),h.jsx("input",{type:"text",value:((En=L.polaGacor)==null?void 0:En.spinAutoTurboOff)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,spinAutoTurboOff:Y.target.value}}),placeholder:"50x",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"})]})]}),h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-400",children:"Jam Hoki"}),h.jsx("input",{type:"text",value:((cr=L.polaGacor)==null?void 0:cr.jamHoki)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,jamHoki:Y.target.value}}),placeholder:"14:30 - 16:45 WIB",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[11px] text-slate-400",children:"RTP Live Slot"}),h.jsx("input",{type:"text",value:((wa=L.polaGacor)==null?void 0:wa.rtpLive)||"",onChange:Y=>N({...L,polaGacor:{...L.polaGacor,rtpLive:Y.target.value}}),placeholder:"98.8%",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-emerald-400 font-bold"})]})]})]}),h.jsxs("div",{className:"flex items-center justify-end gap-2 pt-2",children:[h.jsx("button",{type:"button",onClick:()=>{T(!1),b(null)},className:"px-3 py-1.5 rounded-lg bg-slate-800 text-slate-300 text-xs font-bold",children:"Batal"}),h.jsxs("button",{type:"submit",disabled:M,className:"flex items-center gap-1.5 px-4 py-1.5 rounded-lg bg-emerald-600 hover:bg-emerald-500 text-white text-xs font-extrabold shadow-[0_0_12px_rgba(16,185,129,0.5)] curs
2799or-pointer",children:[h.jsx(jc,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:M?"Menyiarkan...":"Simpan & Siarkan Real-Time"})]})]})]}):h.jsxs("div",{className:"mb-3 flex items-center justify-between",children:[h.jsx("span",{className:"text-xs text-slate-400",children:"Daftar Tombol Bukti Jackpot (Klik urutkan, edit, atau tambah baru)"}),h.jsxs("button",{onClick:()=>{N({buttonLabel:`🎁 KANCAH4D | BUKTI MAXWIN ${new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase()}`,title:`🔥 KANCAH4D | BUKTI MAXWIN ${new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase()}`,date:new Date().toLocaleDateString("en-GB",{day:"2-digit",month:"short",year:"numeric"}).toUpperCase(),gameProvider:"PG Soft",gameName:"Mahjong Ways 2",imageUrl:"https://ik.imagekit.io/dxokd3m9y/tolkon.png",username:"k***99",winAmount:"Rp 50.000.000",betAmount:"Rp 10.000",multiplier:"x5000",badgeText:"HOT",badgeColor:"yellow",playUrl:"https://kancah4d.com/slots",claimUrl:"https://kancah4d.com/login",polaGacor:{spinManual:"30x (Turbo Off)",spinAutoTurboOn:"80x (Turbo On)",spinAutoTurboOff:"50x (Turbo Off)",jamHoki:"14:00 - 17:00 WIB",rtpLive:"98.8%"},tips:"Gunakan taruhan stabil dan beli fitur Free Spin jika saldo mencukupi untuk hasil maksimal."}),T(!0),b(null)},className:"flex items-center gap-1 px-3 py-1.5 bg-yellow-500 hover:bg-yellow-400 text-slate-950 rounded-lg text-xs font-black transition cursor-pointer shadow-[0_0_10px_rgba(234,179,8,0.4)]",children:[h.jsx(Qp,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"+ Tambah Bukti Baru"})]})]}),h.jsx("div",{className:"space-y-2",children:ce.map((Y,ze)=>{const Ze=Y.badgeText!==void 0?Y.badgeText:Y.isHighlighted?"HOT":"";return h.jsxs("div",{className:"flex items-center gap-2 p-2.5 bg-[#070c18] border border-slate-800 hover:border-slate-700 rounded-xl transition",children:[h.jsxs("div",{className:"flex flex-col",children:[h.jsx("button",{onClick:()=>qe(ze,"up"),disabled:ze===0,className:"text-slate-500 hover:text-white disabled:opacity-20 cursor-pointer",children:h.jsx(n1,{className:"w-3.5 h-3.5"})}),h.jsx("button",{onClick:()=>qe(ze,"down"),disabled:ze===ce.length-1,className:"text-slate-500 hover:text-white disabled:opacity-20 cursor-pointer",children:h.jsx(aC,{className:"w-3.5 h-3.5"})})]}),h.jsx("img",{src:Y.imageUrl,alt:"",className:"w-12 h-12 object-cover rounded-lg border border-slate-700 bg-black"}),h.jsxs("div",{className:"flex-1 min-w-0",children:[h.jsxs("div",{className:"flex items-center gap-1.5",children:[h.jsx("span",{className:"text-xs font-bold text-white truncate",children:Y.buttonLabel}),Ze&&Ze.trim()!==""&&h.jsx("span",{className:"text-[9px] bg-yellow-400 text-black px-1 rounded font-bold uppercase",children:Ze})]}),h.jsxs("div",{className:"text-[11px] text-slate-400 flex items-center gap-1.5 mt-0.5 flex-wrap",children:[h.jsxs("span",{children:[Y.gameName," (",Y.gameProvider,")"]}),h.jsx("span",{children:"•"}),h.jsx("span",{className:"text-yellow-400 font-bold",children:Y.winAmount}),h.jsx("span",{children:"•"}),h.jsx("span",{className:"text-emerald-400 font-extrabold bg-emerald-950/80 px-1.5 py-0.2 rounded border border-emerald-500/30",children:Y.multiplier||"x5000"}),h.jsx("span",{children:"•"}),h.jsx("span",{className:"text-cyan-400",children:Y.username})]})]}),h.jsxs("div",{className:"flex items-center gap-1",children:[h.jsx("button",{onClick:()=>{N(Y),b(Y.id),T(!1)},className:"p-1.5 text-blue-400 hover:bg-blue-950/60 rounded-lg transition",title:"Edit Bukti",children:h.jsx(qA,{className:"w-4 h-4"})}),h.jsx("button",{onClick:()=>Re(Y.id),className:"p-1.5 text-red-400 hover:bg-red-950/60 rounded-lg transition",title:"Hapus Bukti",children:h.jsx(Yp,{className:"w-4 h-4"})})]})]},Y.id)})})]}),f==="banners"&&h.jsxs("div",{className:"space-y-3",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("span",{className:"text-xs text-slate-400",children:"Slider Banner Otomatis (Berganti tiap 3 detik)"}),h.jsxs("button",{onClick:()=>{const Y={id:`banner-${Date.now()}`,imageUrl:"https://ik.imagekit.io/dxokd3m9y/banner1.webp",title:"Banner Promo Kancah4D",alt:"Promo Terbaru",link:w.registerUrl},ze=[...ye,Y];S(ze),$({banners:ze})},className:"flex items-center gap-1 px-3 py-1 bg-yellow-500 text-slate-950 font-bold rounded-lg text-xs",children:[h.jsx(Qp,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Tambah Banner"})]})]}),ye.map((Y,ze)=>h.jsx("div",{className:"p-3 bg-[#070c18] border border-slate-800 rounded-xl space-y-2",children:h.jsxs("div",{className:"flex items-center gap-3",children:[h.jsx("img",{src:Y.imageUrl,alt:"",className:"w-24 h-12 object-contain bg-black rounded border border-white/20"}),h.jsxs("div",{className:"flex-1 space-y-1 text-xs",children:[h.jsx("input",{type:"text",value:Y.imageUrl,onChange:Ze=>{const At=Ze.target.value,Ft=ye.map((Gt,Ot)=>Ot===ze?{...Gt,imageUrl:At}:Gt);S(Ft)},placeholder:"URL Gambar Banner (WebP/PNG/JPG)",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"}),h.jsx("input",{type:"text",value:Y.link||"",onChange:Ze=>{const At=Ze.target.value,Ft=ye.map((Gt,Ot)=>Ot===ze?{...Gt,link:At}:Gt);S(Ft)},placeholder:"Link Tujuan saat banner diklik (https://kancah4d.com)",className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-cyan-300 font-mono text-[11px]"})]}),h.jsx("button",{onClick:()=>
2799{if(ye.length<=1)return;const Ze=ye.filter((At,Ft)=>Ft!==ze);S(Ze),$({banners:Ze})},className:"p-2 text-red-400 hover:bg-red-950 rounded-lg cursor-pointer",children:h.jsx(Yp,{className:"w-4 h-4"})})]})},Y.id||ze)),h.jsx("div",{className:"pt-2 flex justify-end",children:h.jsxs("button",{onClick:()=>$({banners:ye}),className:"px-4 py-2 bg-emerald-600 hover:bg-emerald-500 text-white text-xs font-bold rounded-lg flex items-center gap-1.5 cursor-pointer",children:[h.jsx(jc,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Simpan Perubahan Banner"})]})})]}),f==="marquee"&&h.jsxs("div",{className:"space-y-3",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("span",{className:"text-xs text-slate-400",children:"Teks Berjalan LED dengan Border Neon"}),h.jsxs("button",{onClick:()=>{const Y={id:`m-${Date.now()}`,brand:"KANCAH4D",text:"SITUS GACOR RESMI",highlight:"JACKPOT BESAR",badge:"HOT",badgeType:"yellow"},ze=[...A,Y];k(ze),$({marqueeItems:ze})},className:"flex items-center gap-1 px-3 py-1 bg-yellow-500 text-slate-950 font-bold rounded-lg text-xs",children:[h.jsx(Qp,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Tambah Pesan"})]})]}),A.map((Y,ze)=>h.jsx("div",{className:"p-3 bg-[#070c18] border border-slate-800 rounded-xl space-y-2 text-xs",children:h.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-4 gap-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"text-[10px] text-slate-400",children:"Brand"}),h.jsx("input",{type:"text",value:Y.brand,onChange:Ze=>{const At=Ze.target.value;k(Ft=>Ft.map((Gt,Ot)=>Ot===ze?{...Gt,brand:At}:Gt))},className:"w-full bg-[#0c1222] border border-slate-700 rounded p-1.5 text-cyan-300 font-bold"})]}),h.jsxs("div",{className:"sm:col-span-2",children:[h.jsx("label",{className:"text-[10px] text-slate-400",children:"Isi Teks & Highlight"}),h.jsxs("div",{className:"flex gap-1.5",children:[h.jsx("input",{type:"text",value:Y.text,onChange:Ze=>{const At=Ze.target.value;k(Ft=>Ft.map((Gt,Ot)=>Ot===ze?{...Gt,text:At}:Gt))},className:"flex-1 bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white"}),h.jsx("input",{type:"text",value:Y.highlight,onChange:Ze=>{const At=Ze.target.value;k(Ft=>Ft.map((Gt,Ot)=>Ot===ze?{...Gt,highlight:At}:Gt))},className:"w-32 bg-[#0c1222] border border-slate-700 rounded p-1.5 text-yellow-400 font-bold"})]})]}),h.jsxs("div",{children:[h.jsx("label",{className:"text-[10px] text-slate-400",children:"Badge"}),h.jsxs("div",{className:"flex gap-1",children:[h.jsx("input",{type:"text",value:Y.badge,onChange:Ze=>{const At=Ze.target.value;k(Ft=>Ft.map((Gt,Ot)=>Ot===ze?{...Gt,badge:At}:Gt))},className:"w-16 bg-[#0c1222] border border-slate-700 rounded p-1.5 text-white font-bold"}),h.jsx("button",{onClick:()=>{if(A.length<=1)return;const Ze=A.filter((At,Ft)=>Ft!==ze);k(Ze),$({marqueeItems:Ze})},className:"p-1 text-red-400 hover:bg-red-950 rounded cursor-pointer",children:h.jsx(Yp,{className:"w-3.5 h-3.5"})})]})]})]})},Y.id||ze)),h.jsx("div",{className:"pt-2 flex justify-end",children:h.jsxs("button",{onClick:()=>$({marqueeItems:A}),className:"px-4 py-2 bg-emerald-600 hover:bg-emerald-500 text-white text-xs font-bold rounded-lg flex items-center gap-1.5 cursor-pointer",children:[h.jsx(jc,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Simpan Perubahan LED"})]})})]}),f==="security"&&h.jsx("div",{className:"space-y-4 text-xs max-w-md",children:h.jsxs("div",{className:"p-3 bg-[#070c18] border border-yellow-500/40 rounded-xl space-y-2",children:[h.jsxs("h4",{className:"font-bold text-yellow-400 text-sm flex items-center gap-1.5",children:[h.jsx(pg,{className:"w-4 h-4"}),h.jsx("span",{children:"Ganti PIN Rahasia Pemilik"})]}),h.jsx("p",{className:"text-slate-400 text-[11px] leading-relaxed",children:"Ubah PIN pemilik agar hanya Anda yang memiliki wewenang mengupdate bukti kemenangan."}),h.jsxs("form",{onSubmit:Ie,className:"space-y-3 pt-2",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-slate-300 font-semibold mb-1",children:"PIN Rahasia Baru:"}),h.jsx("input",{type:"password",value:he,onChange:Y=>de(Y.target.value),placeholder:"Masukkan PIN baru minimal 4 karakter...",className:"w-full bg-[#040711] border border-slate-700 focus:border-yellow-400 rounded-lg p-2 text-white font-mono",required:!0})]}),h.jsx("button",{type:"submit",className:"w-full py-2 bg-yellow-500 hover:bg-yellow-400 text-slate-950 font-black rounded-lg transition cursor-pointer",children:"Perbarui PIN Sekarang"})]})]})})]}),h.jsxs("div",{className:"pt-3 border-t border-slate-800 flex items-center justify-between",children:[h.jsxs("button",{onClick:P,className:"flex items-center gap-1 text-xs text-rose-400 hover:text-rose-300 hover:underline cursor-pointer",children:[h.jsx($A,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"Reset Data Default"})]}),h.jsx("button",{onClick:e,className:"px-5 py-2 bg-slate-800 hover:bg-slate-700 text-white font-extrabold text-xs rounded-lg transition cursor-pointer",children:"Tutup Panel"})]})]})})},p4=({isOpen:r,onClose:e,proofs:t,banners:n,marqueeItems:i,config:o})=>{const[u,B]=be.useState(!1);if(!r)return null;const g=(()=>{const b=n.map(K=>`        <div style="min-width: 100%; width: 100%;"><img src="${K.imageUrl}" alt="${K.alt||K.title}" style="width: 100%; height: auto; display: block; object-fit: contain;"></div>`).join(`
2800`),D=o.welcomePopup&&o.welcomePopup.enabled!==!1&&o.welcomePopup.imageUrl?`
2801<!-- Welcome Promo Popup on Load -->
2802<div id="kancah-welcome-promo-modal" onclick="closeKancahWelcomeModal()" class="kancah-modal-overlay" style="
2803    display: flex;
2804    position: fixed;
2805    top: 0;
2806    left: 0;
2807    width: 100%;
2808    height: 100%;
2809    background-color: rgba(0, 0, 0, 0.85);
2810    backdrop-filter: blur(8px);
2811    -webkit-backdrop-filter: blur(8px);
2812    z-index: 999999;
2813    justify-content: center;
2814    align-items: center;
2815    padding: 15px;
2816    box-sizing: border-box;
2817    cursor: pointer;
2818">
2819    <div style="
2820        width: 100%;
2821        max-width: 420px;
2822        position: relative;
2823        text-align: center;
2824        display: flex;
2825        align-items: center;
2826        justify-content: center;
2827        animation: modalFadeIn2 0.35s cubic-bezier(0.16, 1, 0.3, 1);
2828    ">
2829        <img src="${o.welcomePopup.imageUrl}" alt="Promo Kancah4D" style="width: auto; height: auto; max-width: 100%; max-height: 88vh; display: block; object-fit: contain; pointer-events: none; filter: drop-shadow(0 15px 30px rgba(0,0,0,0.8));">
2830        <!-- Light Sweep Animation Masked to Pure Image Shape -->
2831        <div style="
2832            position: absolute;
2833            top: 0;
2834            left: 0;
2835            width: 100%;
2836            height: 100%;
2837            pointer-events: none;
2838            overflow: hidden;
2839            -webkit-mask-image: url('${o.welcomePopup.imageUrl}');
2840            mask-image: url('${o.welcomePopup.imageUrl}');
2841            -webkit-mask-size: contain;
2842            mask-size: contain;
2843            -webkit-mask-repeat: no-repeat;
2844            mask-repeat: no-repeat;
2845            -webkit-mask-position: center;
2846            mask-position: center;
2847        ">
2848            <div style="
2849                position: absolute;
2850                top: 0;
2851                left: 0;
2852                width: 100%;
2853                height: 100%;
2854                background: linear-gradient(110deg, transparent 25%, rgba(255,255,255,0.2) 38%, rgba(255,255,255,0.85) 50%, rgba(56,189,248,0.7) 56%, transparent 72%);
2855                animation: imageLightSweep 2.8s ease-in-out infinite;
2856            "></div>
2857        </div>
2858    </div>
2859</div>`:"",T=o.showMainCtaButton!==!1&&o.mainCtaUrl?`
2860    <!-- Tombol CTA Utama ke Website Resmi -->
2861    <div style="width: 100%; max-width: 480px; margin: 12px auto 8px auto; text-align: center;">
2862        <a href="${o.mainCtaUrl}" target="_blank" style="
2863            display: block;
2864            padding: 14px 16px;
2865            background: linear-gradient(135deg, #f59e0b, #eab308, #d97706);
2866            color: #020617;
2867            text-decoration: none;
2868            font-weight: 900;
2869            font-size: 15px;
2870            border: 2px solid #fef08a;
2871            border-radius: 12px;
2872            text-transform: uppercase;
2873            letter-spacing: 0.5px;
2874            box-shadow: 0 0 25px rgba(234, 179, 8, 0.7);
2875        ">
2876            ${o.mainCtaText||"🚀 KUNJUNGI WEBSITE UTAMA KANCAH4D"}
2877            ${o.mainCtaSubtext?`<div style="font-size: 11px; font-weight: 700; opacity: 0.9; margin-top: 2px;">${o.mainCtaSubtext}</div>`:""}
2878        </a>
2879    </div>`:"",M=t.map((K,he)=>{const de=K.badgeText!==void 0?K.badgeText:K.isHighlighted?"HOT":"",ce=de&&de.trim()!==""?`<span style="margin-left: 6px; padding: 2px 6px; font-size: 10px; background: #fbbf24; color: #000000; font-weight: 900; border-radius: 3px; vertical-align: middle;">${de.trim()}</span>`:"";return`    <!-- Tombol Bukti ${he+1} -->
2880    <div style="width: 100%; max-width: 480px; margin: 8px auto; font-family: sans-serif; text-align: center;">
2881        <button onclick="openKancahModal('${K.id}')" style="
2882            width: 100%;
2883            padding: 14px;
2884            background: linear-gradient(135deg, #1542a8, #1f5ce0, #1542a8);
2885            color: #ffffff;
2886            font-weight: 900;
2887            font-size: 13px;
2888            border: 2px solid #22d3ee;
2889            border-radius: 12px;
2890            cursor: pointer;
2891            box-shadow: 0 0 18px rgba(6, 182, 212, 0.4);
2892            text-transform: uppercase;
2893            letter-spacing: 0.5px;
2894            position: relative;
2895            overflow: hidden;
2896            transition: transform 0.15s, box-shadow 0.15s;
2897        " onmousedown="this.style.transform='scale(0.98)'" onmouseup="this.style.transform='scale(1)'">
2898            <span style="position: relative; z-index: 2;">🎁 ${K.buttonLabel.replace(/^🎁\s*/,"")} ${ce}</span>
2899            <span style="
2900                position: absolute;
2901                top: 0;
2902                left: -100%;
2903                width: 50%;
2904                height: 100%;
2905                background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%);
2906                transform: skewX(-25deg);
2907                animation: btnShine2 3s infinite;
2908                pointer-events: none;
2909                z-index: 1;
2910            "></span>
2911        </button>
2912    </div>`}).join(`
2913
2914`),z=t.map(K=>{const he=K.playUrl||o.modalPlayButtonUrl||o.registerUrl||"https://akseslink.com/kancah4d",de=o.modalPlayButtonText||"Mainkan Pola",ce=K.claimUrl||o.modalClaimButtonUrl||o.loginUrl||"https://akseslink.com/kancah4d",_e=o.modalClaimButtonText||"🚀 LOGIN & KLAIM JACKPOT SEKARANG",ye=o.modalCopyButtonText||"Salin Pola";return`    <!-- Modal Popup ${K.id} -->
2915    <div id="modal-${K.id}" class="kancah-modal-overlay" style="
2916        display: none;
2917        position: fixed;
2918        top: 0;
2919        left: 0;
2920        width: 100%;
2921        height: 100%;
2922        background-color: rgba(0, 0, 0, 0.85);
2923        backdrop-filter: blur(4px);
2924        z-index: 99999;
2925        justify-content: center;
2926        align-items: center;
2927        padding: 15px;
2928        box-sizing: border-box;
2929    ">
2930        <div style="
2931            background: linear-gradient(180deg, #131a2a 0%, #0b0f19 100%);
2932            width: 100%;
2933            max-width: 450px;
2934            border-radius: 16px;
2935            border: 2px solid #ffffff;
2936            overflow: hidden;
2937            box-shadow: 0 10px 30px rgba(255, 255, 255, 0.15), 0 20px 40px rgba(0,0,0,0.8);
2938            color: #ffffff;
2939            text-align: left;
2940            position: relative;
2941            max-height: 90vh;
2942            overflow-y: auto;
2943            animation: modalFadeIn2 0.3s cubic-bezier(0.16, 1, 0.3, 1);
2944        ">
2945            <!-- Tombol Tutup (X) -->
2946            <button onclick="closeKancahModal('${K.id}')" style="
2947                position: absolute;
2948                top: 12px;
2949                right: 12px;
2950                background: rgba(220, 38, 38, 0.9);
2951                color: white;
2952                border: 1px solid rgba(255, 255, 255, 0.4);
2953                border-radius: 50%;
2954                width: 32px;
2955                height: 32px;
2956                font-weight: bold;
2957                font-size: 15px;
2958                cursor: pointer;
2959                z-index: 10;
2960                display: flex;
2961                align-items: center;
2962                justify-content: center;
2963                box-shadow: 0 4px 10px rgba(0,0,0,0.5);
2964            ">×</button>
2965
2966            <!-- Gambar Bukti -->
2967            <div style="width: 100%; background: #000; line-height: 0; position: relative; border-bottom: 1px solid rgba(255,255,255,0.1);">
2968                <img src="${K.imageUrl}" alt="${K.title}" style="width: 100%; height: auto; display: block; object-fit: contain;">
2969            </div>
2970
2971            <!-- Teks & Pola Gacor -->
2972            <div style="padding: 18px; font-family: sans-serif;">
2973                <div style="font-size: 13px; font-weight: 800; color: #fbbf24; margin-bottom: 8px; letter-spacing: 0.5px;">
2974                    ${K.title}
2975                </div>
2976                <p style="font-size: 12px; color: #cbd5e1; line-height: 1.6; margin: 0 0 12px 0;">
2977                    Selamat kepada member setia Kancah4D (<strong>${K.username||"Member"}</strong>) yang berhasil menang <strong style="color:#ffd700;">${K.winAmount}</strong> di game <strong style="color: #ffffff;">${K.gameName}</strong>! Gunakan rincian pola gacor di bawah ini:
2978                </p>
2979                
2980                <div style="background: rgba(11, 15, 25, 0.8); padding: 12px; border-radius: 8px; border: 1px dashed rgba(71, 85, 105, 0.8); font-size: 12px; color: #34d399; line-height: 1.7;">
2981                    <div style="color: #60a5fa; margin-bottom: 4px;">🎰 <strong>Game:</strong> ${K.gameName} (${K.gameProvider})</div>
2982                    <div>⚡ Spin Manual (Turbo Off) : <strong>${K.polaGacor.spinManual}</strong></div>
2983                    <div>⚡ Spin Auto (Turbo On)   : <strong>${K.polaGacor.spinAutoTurboOn}</strong></div>
2984                    <div>⚡ Spin Auto (Turbo Off)  : <strong>${K.polaGacor.spinAutoTurboOff}</strong></div>
2985                    ${K.polaGacor.jamHoki?`<div>🕒 Jam Hoki : <strong>${K.polaGacor.jamHoki}</strong></div>`:""}
2986                    <div style="margin-top: 8px; padding-top: 6px; border-top: 1px dashed rgba(255,255,255,0.1); color: #f87171; font-weight: bold;">💡 Tips: ${K.tips}</div>
2987                </div>
2988
2989                <div style="margin-top: 15px; display: flex; flex-direction: column; gap: 8px;">
2990                    <div style="display: flex; gap: 8px;">
2991                        <button onclick="navigator.clipboard.writeText('POLA GACOR ${K.gameName} : Manual ${K.polaGacor.spinManual} | Auto ON ${K.polaGacor.spinAutoTurboOn} | Auto OFF ${K.polaGacor.spinAutoTurboOff}'); alert('Pola Berhasil Disalin!');" style="
2992                            flex: 1;
2993                            padding: 10px;
2994                            background: #1e293b;
2995                            color: #ffffff;
2996                            border: 1px solid #475569;
2997                            border-radius: 8px;
2998                            font-weight: bold;
2999                            font-size: 12px;
3000                            cursor: pointer;
3001                        ">${ye}</button>
3002                        
3003                        <a href="${he}" target="_blank" style="
3004                            flex: 1;
3005                            padding: 10px;
3006                            background: linear-gradient(135deg, #10b981, #059669);
3007                            color: white;
3008                            text-decoration: none;
3009                            font-weight: 800;
3010                            font-size: 12px;
3011                            text-align: center;
3012                            border-radius: 8px;
3013                            box-shadow: 0 4px 10px rgba(16,185,129,0.3);
3014                        ">${de}</a>
3015                    </div>
3016
3017                    <a href="${ce}" target="_blank" style="
3018                        display: block;
3019                        padding: 12px;
3020                        background: linear-gradient(135deg, #1d4ed8, #2563eb);
3021                        color: white;
3022                        text-decoration: none;
3023                        font-weight: 800;
3024                        font-size: 12px;
3025                        text-align: center;
3026                        border-radius: 8px;
3027                        text-transform: uppercase;
3028                        box-shadow: 0 4px 12px rgba(37,99,235,0.4);
3029                    ">${_e}</a>
3030                </div>
3031            </div>
3032        </div>
3033    </div>`}).join(`
3034
3035`),W=`
3036<!-- LED Running Text Marquee -->
3037<div class="k4d-led-box">
3038    <div class="k4d-led-inner">
3039        ${i.map(K=>`<span class="k4d-led-item"><strong style="color: #60a5fa;">[${K.brand}]</strong> ${K.text} <span style="color:#fbbf24; font-weight:800;">${K.highlight}</span> <span class="k4d-led-badge">${K.badge}</span></span>`).join(" • ")}
3040    </div>
3041</div>`;return`<!-- ==========================================
3042     WIDGET BUKTI JACKPOT & TESTIMONI KANCAH4D
3043     Lisensi Resmi & Real-Time Sync Kancah4D
3044     ========================================== -->
3045<style>
3046@keyframes btnShine2 {
3047    0% { left: -100%; }
3048    20% { left: 100%; }
3049    100% { left: 100%; }
3050}
3051@keyframes modalFadeIn2 {
3052    from { opacity: 0; transform: scale(0.95); }
3053    to { opacity: 1; transform: scale(1); }
3054}
3055@keyframes imageLightSweep {
3056    0% { transform: translateX(-180%) skewX(-25deg); opacity: 0; }
3057    20% { opacity: 0.9; }
3058    70% { transform: translateX(280%) skewX(-25deg); opacity: 0.9; }
3059    100% { transform: translateX(280%) skewX(-25deg); opacity: 0; }
3060}
3061@keyframes marqueeRoll2 {
3062    0% { transform: translateX(0%); }
3063    100% { transform: translateX(-50%); }
3064}
3065.k4d-led-box {
3066    width: 100%;
3067    max-width: 480px;
3068    margin: 14px auto 8px auto;
3069    background: #020617;
3070    border: 2px solid #3b82f6;
3071    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
3072    border-radius: 10px;
3073    padding: 8px 0;
3074    overflow: hidden;
3075    white-space: nowrap;
3076    position: relative;
3077    font-family: sans-serif;
3078}
3079.k4d-led-inner {
3080    display: inline-block;
3081    padding-left: 100%;
3082    animation: marqueeRoll2 20s linear infinite;
3083    font-size: 12px;
3084    color: #e2e8f0;
3085    font-weight: 600;
3086}
3087.k4d-led-inner:hover {
3088    animation-play-state: paused;
3089}
3090.k4d-led-badge {
3091    background: #eab308;
3092    color: #020617;
3093    font-size: 10px;
3094    font-weight: 900;
3095    padding: 1px 5px;
3096    border-radius: 3px;
3097    margin-left: 4px;
3098}
3099</style>
3100
3101<div id="kancah4d-widget-container" style="width: 100%; max-width: 480px; margin: 0 auto; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;">
3102    <!-- Slider Banner -->
3103    <div id="kancah-slider-banner" style="width: 100%; max-width: 480px; margin: 0 auto 10px auto; overflow: hidden; border-radius: 12px; border: 2px solid #ffffff; box-shadow: 0 4px 20px rgba(0,0,0,0.6);">
3104        <div id="kancah-slide-track" style="display: flex; transition: transform 0.5s ease-in-out;">
3105${b}
3106        </div>
3107    </div>
3108${T}
3109
3110    <!-- Daftar Tombol Bukti Jackpot -->
3111${M}
3112
3113    ${W}
3114</div>
3115
3116<!-- Modal Popups Container -->
3117${z}
3118${D}
3119
3120<script>
3121// Welcome Popup Closer
3122function closeKancahWelcomeModal() {
3123    var modal = document.getElementById('kancah-welcome-promo-modal');
3124    if (modal) {
3125        modal.style.display = 'none';
3126    }
3127}
3128// Auto Slider Script
3129(function() {
3130    var track = document.getElementById('kancah-slide-track');
3131    if (!track) return;
3132    var totalSlides = ${n.length};
3133    var currentSlide = 0;
3134    setInterval(function() {
3135        currentSlide = (currentSlide + 1) % totalSlides;
3136        track.style.transform = 'translateX(-' + (currentSlide * 100) + '%)';
3137    }, 3000);
3138})();
3139
3140// Modal Popup Handlers
3141function openKancahModal(id) {
3142    var modal = document.getElementById('modal-' + id);
3143    if (modal) {
3144        modal.style.display = 'flex';
3145        document.body.style.overflow = 'hidden';
3146    }
3147}
3148function closeKancahModal(id) {
3149    var modal = document.getElementById('modal-' + id);
3150    if (modal) {
3151        modal.style.display = 'none';
3152        document.body.style.overflow = 'auto';
3153    }
3154}
3155// Close on outside click
3156window.addEventListener('click', function(e) {
3157    if (e.target && e.target.classList.contains('kancah-modal-overlay')) {
3158        e.target.style.display = 'none';
3159        document.body.style.overflow = 'auto';
3160    }
3161});
3162<\/script>
3163`})(),y=()=>{navigator.clipboard.writeText(g),B(!0),setTimeout(()=>B(!1),3e3)};return h.jsx("div",{className:"fixed inset-0 bg-black/85 backdrop-blur-sm z-[999999] flex items-center justify-center p-3 sm:p-5 overflow-y-auto",children:h.jsxs("div",{className:"relative w-full max-w-3xl bg-[#090e1c] border-2 border-cyan-500/80 rounded-2xl p-4 sm:p-6 text-slate-100 shadow-[0_0_40px_rgba(6,182,212,0.25)] flex flex-col max-h-[92vh]",children:[h.jsxs("div",{className:"flex items-center justify-between pb-3 border-b border-slate-800",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-2 bg-cyan-500/20 text-cyan-400 rounded-lg border border-cyan-500/40",children:h.jsx(r1,{className:"w-5 h-5"})}),h.jsxs("div",{children:[h.jsx("h2",{className:"text-base sm:text-lg font-black text-white uppercase tracking-wider",children:"Kode Embed HTML Murni KANCAH4D"}),h.jsx("p",{className:"text-xs text-slate-400",children:"Salin kode ini untuk dipasang di landing page, blog, WordPress, atau CMS Anda."})]})]}),h.jsx("button",{onClick:e,className:"w-8 h-8 rounded-full bg-slate-800 hover:bg-slate-700 text-slate-300 hover:text-white flex items-center justify-center border border-slate-600 transition cursor-pointer",children:h.jsx(NB,{className:"w-5 h-5"})})]}),h.jsx("div",{className:"flex-1 overflow-y-auto py-3",children:h.jsx("div",{className:"relative",children:h.jsx("pre",{className:"p-3 bg-[#03060f] border border-slate-800 rounded-xl text-[11px] font-mono text-cyan-300 overflow-x-auto max-h-[50vh] selection:bg-cyan-900",children:h.jsx("code",{children:g})})})}),h.jsxs("div",{className:"pt-3 border-t border-slate-800 flex items-center justify-between",children:[h.jsx("span",{className:"text-xs text-slate-400",children:"✅ Siap dipasang tanpa dependensi (Pure HTML + CSS + JS)"}),h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("button",{onClick:y,className:"flex items-center gap-1.5 px-5 py-2.5 bg-gradient-to-r from-cyan-500 to-blue-600 hover:from-cyan-400 hover:to-blue-500 text-slate-950 font-black text-xs uppercase tracking-wider rounded-xl shadow-[0_0_15px_rgba(6,182,212,0.4)] transition cursor-pointer active:scale-95",children:u?h.jsxs(h.Fragment,{children:[h.jsx(t1,{className:"w-4 h-4 text-slate-950"}),h.jsx("span",{children:"Kode Tersalin!"})]}):h.jsxs(h.Fragment,{children:[h.jsx(a1,{className:"w-4 h-4 text-slate-950"}),h.jsx("span",{children:"Salin Kode HTML"})]})}),h.jsx("button",{onClick:e,className:"px-4 py-2.5 bg-slate-800 hover:bg-slate-700 text-white font-bold text-xs rounded-xl transition cursor-pointer",children:"Tutup"})]})]})]})})},g4=({isOpen:r,onClose:e,onSuccess:t})=>{const[n,i]=be.useState(""),[o,u]=be.useState(null),[B,f]=be.useState(!1);if(!r)return null;const g=async y=>{if(y.preventDefault(),!n.trim())return;f(!0),u(null);const b=await h4(n.trim());f(!1),b.success?(t(n.trim()),e()):u(b.message||"PIN Salah! Akses ditolak.")};return h.jsx("div",{className:"fixed inset-0 bg-black/85 backdrop-blur-sm z-[999999] flex items-center justify-center p-4",children:h.jsxs("div",{className:"relative w-full max-w-sm bg-gradient-to-b from-[#11192e] to-[#070b14] border-2 border-yellow-500/70 rounded-2xl p-5 sm:p-6 text-slate-100 shadow-[0_0_40px_rgba(234,179,8,0.3)]",children:[h.jsx("button",{onClick:e,className:"absolute top-3 right-3 w-7 h-7 rounded-full bg-slate-800 text-slate-400 hover:text-white flex items-center justify-center transition cursor-pointer",children:h.jsx(NB,{className:"w-4 h-4"})}),h.jsx("div",{className:"mx-auto w-12 h-12 rounded-full bg-yellow-500/20 border border-yellow-500/50 flex items-center justify-center text-yellow-400 mb-3 shadow-[0_0_15px_rgba(234,179,8,0.3)]",children:h.jsx(iC,{className:"w-6 h-6"})}),h.jsx("h3",{className:"text-center text-sm sm:text-base font-black uppercase text-white tracking-wider",children:"Akses Khusus Pemilik"}),h.jsxs("p",{className:"text-center text-[11px] text-slate-400 mt-1 mb-4 leading-relaxed",children:[h.jsx("strong",{children:"KANCAH4D"}),". Rasakan sensasi maxwin tanpa batas dan buktikan sendiri kemenangan fantastis member setia setiap hari!"]}),o&&h.jsxs("div",{className:"mb-3 p-2.5 bg-rose-950/80 border border-rose-500/60 rounded-lg text-rose-300 text-xs flex items-center gap-2",children:[h.jsx(s2,{className:"w-4 h-4 text-rose-400 shrink-0"}),h.jsx("span",{children:o})]}),h.jsxs("form",{onSubmit:g,className:"space-y-3",children:[h.jsxs("div",{children:[h.jsx("label",{className:"block text-[11px] font-bold text-slate-300 mb-1",children:"Masukkan PIN / Kata Sandi Rahasia:"}),h.jsxs("div",{className:"relative",children:[h.jsx("input",{type:"password",value:n,onChange:y=>{i(y.target.value),u(null)},placeholder:"Masukkan PIN Anda...",className:"w-full bg-[#050811] border border-slate-700 focus:border-yellow-400 rounded-xl py-2.5 pl-3 pr-10 text-white font-mono text-center tracking-widest outline-none transition",autoFocus:!0,required:!0}),h.jsx(pg,{className:"w-4 h-4 text-slate-500 absolute right-3 top-1/2 -translate-y-1/2"})]})]}),h.jsx("button",{type:"submit",disabled:B,className:"w-full py-2.5 bg-gradient-to-r from-yellow-500 to-amber-600 hover:from-yellow-400 hover:to-amber-500 text-slate-950 font-black text-xs uppercase tracking-wider rounded-xl shadow-[0_0_15px_rgba(234,179,8,0.4)] transition-all cursor-pointer flex items-center justify-center gap-1.5 active:scale-[0.98] disabled:opacity-50",children:B?h.jsx("span",{children:"Memverifikasi..."}):h.jsxs(h.Fragment,{children:[h.jsx("span",{children:"Buka Panel Update"}),h.jsx(e1,{className:"w-4 h-4"})]})})]})]})})},C4=["PRAGMATIC PLAY","PG SOFT","JILI","AFB GAMING","CQ9","JOKER","HABANERO","PP POP","SPADEGAMING","FAST SPIN","MICROGAMING","NO LIMIT CITY"],y4=[{label:"+10rb",value:1e4},{label:"+25rb",value:25e3},{label:"+50rb",value:5e4},{label:"+100rb",value:1e5},{label:"+250rb",value:25e4},{label:"+500rb",value:5e5}],b4=Ks.memo(({config:r})=>{const[e,t]=be.useState(""),[n,i]=be.useState(null),[o,u]=be.useState("50000"),[B,f]=be.useState("PRAGMATIC PLAY"),[g,y]=be.useState(!1),[b,D]=be.useState(null),T=K=>{const de=parseInt(o.replace(/\D/g,"")||"0",10)+K;u(de.toString())},M=K=>{const de=K.replace(/[^,\d]/g,"").toString().split(","),ce=de[0].length%3;let _e=de[0].substr(0,ce);const ye=de[0].substr(ce).match(/\d{3}/gi);return ye&&(_e+=(ce?".":"")+ye.join(".")),de[1]!==void 0?_e+","+de[1]:_e},z=K=>{K.preventDefault();const he=e.trim();if(!he){i("Harap masukkan User ID akun Anda terlebih dahulu!");const ce=document.getElementById("input-calculator-userid");ce&&ce.focus();return}if(he.length<3){i("User ID akun minimal 3 karakter!");const ce=document.getElementById("input-calculator-userid");ce&&ce.focus();return}i(null);const de=parseInt(o.replace(/\D/g,"")||"0",10);if(de<1e4){alert("Minimal modal untuk kalkulasi cerdas adalah Rp 10.000");return}y(!0),D(null),setTimeout(()=>{const ce=12+Math.floor(Math.random()*8),_e=ce+25+Math.floor(Math.random()*20),ye=de*ce,S=de*_e,A=new Date().getHours(),k=(A+3)%24,w=`${String(A).padStart(2,"0")}:15 - ${String(k).padStart(2,"0")}:45 WIB`,O=(96.8+Math.random()*2.6).toFixed(1);D({userId:he,winrate:`${O}
3163%`,targetMin:"Rp "+ye.toLocaleString("id-ID"),targetMax:"Rp "+S.toLocaleString("id-ID"),jamHoki:w,polaSpin:{manual:`${10+Math.floor(Math.random()*15)}X (Centang Lewati Layar)`,turboOn:`${30+Math.floor(Math.random()*40)}X (DC ON / Turbo)`,turboOff:`${20+Math.floor(Math.random()*25)}X (Normal Cepat)`},status:"SUPER GACOR VVIP"}),y(!1)},450)},W=r.registerUrl||r.mainCtaUrl||"https://akseslink.com/kancah4d";return h.jsxs("div",{id:"kalkulator-cuan-cerdas",className:"w-full bg-[#071329] rounded-2xl border-2 border-cyan-400 shadow-[0_0_25px_rgba(6,182,212,0.4)] p-4 sm:p-5 text-white flex flex-col relative overflow-hidden",children:[h.jsx("div",{className:"absolute top-0 right-0 w-36 h-36 bg-cyan-500/15 rounded-full blur-2xl pointer-events-none"}),h.jsx("div",{className:"absolute bottom-0 left-0 w-36 h-36 bg-blue-600/15 rounded-full blur-2xl pointer-events-none"}),h.jsxs("div",{className:"w-full flex items-center justify-center gap-2 sm:gap-3 mb-4",children:[h.jsx("span",{className:"flex-1 max-w-[36px] sm:max-w-[64px] h-[1.5px] bg-gradient-to-r from-transparent to-cyan-400"}),h.jsxs("div",{className:"flex items-center justify-center gap-1.5 sm:gap-2 flex-shrink-0",children:[h.jsx(bl,{className:"w-4 h-4 text-yellow-400 flex-shrink-0"}),h.jsx("h2",{className:"text-xs sm:text-sm md:text-base font-black tracking-wider text-cyan-300 uppercase drop-shadow-[0_0_8px_rgba(6,182,212,0.8)] text-center whitespace-nowrap",children:"KALKULATOR CUAN CERDAS"}),h.jsx(bl,{className:"w-4 h-4 text-yellow-400 flex-shrink-0"})]}),h.jsx("span",{className:"flex-1 max-w-[36px] sm:max-w-[64px] h-[1.5px] bg-gradient-to-l from-transparent to-cyan-400"})]}),h.jsxs("form",{onSubmit:z,className:"flex flex-col gap-3.5 relative z-10",children:[h.jsxs("div",{className:"flex flex-col gap-1.5 text-left",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("label",{htmlFor:"input-calculator-userid",className:"text-[11px] sm:text-xs font-bold text-slate-200 flex items-center gap-1 cursor-pointer",children:[h.jsx("span",{children:"Masukkan ID Anda"}),h.jsx("span",{className:"text-red-400 font-bold",children:"*"})]}),h.jsx("span",{className:"text-[10px] text-yellow-300 font-bold px-2 py-0.5 rounded bg-yellow-500/20 border border-yellow-400/40 tracking-wider",children:"Wajib Diisi"})]}),h.jsx("div",{className:"relative",children:h.jsx("input",{id:"input-calculator-userid",type:"text",value:e,onChange:K=>{t(K.target.value),n&&i(null),b&&D(null)},placeholder:"Contoh: kancahjuara88",required:!0,className:`w-full bg-[#0a1b38] border rounded-lg px-3 py-2 text-xs sm:text-sm text-slate-100 placeholder-slate-500 focus:outline-none transition ${n?"border-red-500 ring-2 ring-red-500/50 bg-red-950/20":"border-cyan-500/40 focus:border-cyan-400 focus:ring-1 focus:ring-cyan-400"}`})}),n&&h.jsxs("p",{className:"text-[10.5px] text-red-400 font-bold flex items-center gap-1 mt-0.5 animate-bounce",children:[h.jsx(mA,{className:"w-3.5 h-3.5 flex-shrink-0"}),h.jsx("span",{children:n})]})]}),h.jsxs("div",{className:"flex flex-col gap-1 text-left",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("label",{className:"text-[11px] sm:text-xs font-bold text-slate-300",children:"Masukkan Modal Anda (Rp)"}),h.jsx("span",{className:"text-[10px] text-yellow-400 font-semibold",children:"Min. Rp 10.000"})]}),h.jsxs("div",{className:"relative",children:[h.jsx("span",{className:"absolute left-3 top-1/2 -translate-y-1/2 text-cyan-400 text-xs font-black",children:"Rp"}),h.jsx("input",{type:"text",value:M(o),onChange:K=>{const he=K.target.value.replace(/\D/g,"");u(he),b&&D(null)},placeholder:"Contoh: 10.000 atau 50000",required:!0,className:"w-full bg-[#0a1b38] border border-cyan-500/40 rounded-lg pl-9 pr-3 py-2 text-xs sm:text-sm font-bold text-yellow-300 placeholder-slate-500 focus:outline-none focus:border-cyan-400 focus:ring-1 focus:ring-cyan-400 transition"})]}),h.jsx("div",{className:"grid grid-cols-3 sm:grid-cols-6 gap-1.5 mt-1.5",children:y4.map(K=>h.jsx("button",{type:"button",onClick:()=>{T(K.value),b&&D(null)},className:"py-1.5 px-1 bg-[#0a1e42] hover:bg-cyan-900/60 border border-cyan-500/30 hover:border-cyan-400 text-[10px] sm:text-[11px] text-cyan-200 font-bold rounded-lg cursor-pointer transition active:scale-95 text-center shadow-sm",children:K.label},K.label))})]}),h.jsxs("div",{className:"flex flex-col gap-1.5 text-left",children:[h.jsx("label",{className:"text-[11px] sm:text-xs font-bold text-slate-300",children:"PILIH KATEGORI PROVIDER GAME"}),h.jsx("div",{className:"grid grid-cols-3 sm:grid-cols-4 gap-1.5",children:C4.map(K=>{const he=B===K;return h.jsx("button",{type:"button",onClick:()=>{f(K),b&&D(null)},className:`py-2 px-1 rounded-lg text-[9.5px] sm:text-[10.5px] font-black uppercase tracking-wider transition-all cursor-pointer border flex items-center justify-center text-center ${he?"bg-gradient-to-r from-cyan-500 to-blue-600 text-slate-950 border-cyan-300 shadow-[0_0_12px_rgba(6,182,212,0.8)] scale-[1.02]":"bg-[#091833] hover:bg-[#0d2248] text-slate-300 border-slate-700/60 hover:border-cyan-500/40"}`,children:h.jsx("span",{className:"truncate",children:K})},K)})})]}),h.jsx("button",{type:"submit",disabled:g,id:"btn-kalkulasi-cuan",className:"w-full mt-2 py-3 px-4 bg-gradient-to-r from-cyan-500 via-blue-500 to-cyan-500 hover:from-cyan-400 hover:via-blue-400 hover:to-cyan-400 text-slate-950 font-black text-xs sm:text-sm rounded-xl border border-cyan-200 shadow-[0_0_20px_rgba(6,182,212,0.6)] uppercase tracking-wider transition-all duration-200 transform hover:scale-[1.01] active:scale-[0.98] cursor-pointer flex items-center justify-center gap-2",children:g?h.jsxs(h.Fragment,{children:[h.jsx(YA,{className:"w-4 h-4 animate-spin text-slate-950"}),h.jsx("span",{children:"MENGANALISIS SISTEM ALGORITMA..."})]}):h.jsxs(h.Fragment,{children:[h.jsx(bl,{className:"w-4 h-4 text-yellow-300 fill-current animate-bounce"}),h.jsx("span",{children:"KALKULASI KEMENANGANMU SEKARANG ⚡"})]})})]}),b?h.jsxs("div",{className:"mt-4 p-3.5 bg-gradient-to-b from-[#0c224a] to-[#081733] border-2 border-cyan-400/80 rounded-xl shadow-[0_0_20px_rgba(6,182,212,0.5)] text-left animate-fadeIn",children:[h.jsxs("div",{className:"flex items-center justify-between pb-2 border-b border-cyan-500/30",children:[h.jsxs("div",{className:"flex items-center gap-1.5 text-xs font-black text-cyan-300",children:[h.jsx(Du,{className:"w-4 h-4 text-emerald-400 flex-shrink-0"}),h.jsxs("span",{children:["HASIL ALGORITMA: ",h.jsx("span",{className:"text-yellow-300 font-mono underline uppercase tracking-wider",children:b.userId})]})]}),h.jsx("span",{className:"px-2 py-0.5 rounded bg-emerald-500/20 text-emerald-300 text-[10px] font-bold border border-emerald-500/40",children:b.status})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-2 my-2.5",children:[h.jsxs("div",{className:"bg-[#071329] p-2.5 rounded-lg border border-cyan-500/30",children:[h.jsx("span",{className:"text-[10px] text-slate-400 block",children:"Winrate Prediksi:"}),h.jsxs("span",{className:"text-sm sm:text-base font-black text-yellow-300",children:[b.winrate," 🔥"]})]}),h.jsxs("div",{className:"bg-[#071329] p-2.5 rounded-lg border border-cyan-500/30",children:[h.jsx("span",{className:"text-[10px] text-slate-400 block",children:"Target Estimasi Cuan:"}),h.jsx("span",{className:"text-xs sm:text-sm font-black text-emerald-400 truncate block",children:b.targetMax})]})]}),h.jsxs("div",{className:"space-y-1.5 text-[11px] bg-[#071329]/80 p-2.5 rounded-lg border border-cyan-500/20 mb-3",children:[h.jsxs("div",{className:"flex items-center justify-between text-slate-300",children:[h.jsxs("span",{className:"flex items-center gap-1 text-slate-400",children:[h.jsx(Al,{className:"w-3 h-3 text-emerald-400"})," ID Terhubung:"]}),h.jsx("span",{className:"font-bold text-emerald-400 font-mono uppercase",children:b.userId})]}),h.jsxs("div",{className:"flex items-center justify-between text-slate-300",children:[h.jsxs("span",{className:"flex items-center gap-1 text-slate-400",children:[h.jsx(s1,{className:"w-3 h-3 text-cyan-400"})," Jam Hoki:"]}),h.jsx("span",{className:"font-bold text-cyan-300",children:b.jamHoki})]}),h.jsxs("div",{className:"flex items-center justify-between text-slate-300",children:[h.jsxs("span",{className:"flex items-center gap-1 text-slate-400",children:[h.jsx(B2,{className:"w-3 h-3 text-yellow-400"})," Provider:"]}),h.jsx("span",{className:"font-bold text-yellow-300",children:B})]}),h.jsxs("div",{className:"pt-1.5 border-t border-slate-800 text-[10px] text-slate-400",children:[h.jsx("div",{className:"font-semibold text-cyan-200 mb-0.5",children:"Rekomendasi Pola Spin:"}),h.jsxs("div",{children:["⚡ Spin Manual: ",h.jsx("b",{className:"text-white",children:b.polaSpin.manual})]}),h.jsxs("div",{children:["⚡ Spin Turbo ON: ",h.jsx("b",{className:"text-white",children:b.polaSpin.turboOn})]}),h.jsxs("div",{children:["⚡ Spin Turbo OFF: ",h.jsx("b",{className:"text-white",children:b.polaSpin.turboOff})]})]})]}),h.jsxs("a",{href:W,target:"_blank",rel:"noopener noreferrer",className:"w-full py-2.5 px-3 bg-gradient-to-r from-amber-500 to-yellow-400 hover:from-yellow-400 hover:to-amber-500 text-slate-950 font-black text-xs rounded-lg shadow-[0_0_15px_rgba(234,179,8,0.7)] flex items-center justify-center gap-1.5 uppercase tracking-wider transition transform active:scale-95",children:[h.jsx("span",{children:"AMBIL POLA & MAINKAN DI KANCAH4D"}),h.jsx(e1,{className:"w-3.5 h-3.5"})]})]}):h.jsxs("div",{className:"mt-3.5 p-3 rounded-xl bg-[#061224]/80 border border-cyan-500/20 text-center flex flex-col items-center gap-1 text-slate-400",children:[h.jsxs("div",{className:"text-xs font-bold text-cyan-300 flex items-center gap-1.5",children:[h.jsx(Sr,{className:"w-3.5 h-3.5 text-yellow-400"}),h.jsx("span",{children:"Masukkan ID Anda & Klik Kalkulasi"})]}),h.jsx("p",{className:"text-[10.5px] text-slate-400 max-w-xs",children:"Algoritma kemenangan & jam hoki akan dihitung dan disinkronkan secara eksklusif khusus untuk ID akun Anda."})]})]})}),x4=Ks.memo(({config:r})=>{const e=r.brandName||"KANCAH4D",t=[{label:"Nama Situs",value:e,highlight:!1},{label:"Minimal Deposit",value:"Rp 10.000",highlight:!0},{label:"Metode Transaksi",value:"QRIS, Bank Lokal (BCA, Mandiri, BRI, BNI), E-Wallet (DANA, OVO, GoPay)",highlight:!1},{label:"Pilihan Game",value:"Slot Online, Togel 4D, Live Casino",highlight:!1},{label:"Layanan CS",value:"24 Jam Nonstop (Live Chat, WA, Telegram)",highlight:!1}];return h.jsxs("div",{id:"info-kancah4d",className:"w-full bg-[#071329]/80 rounded-xl border border-cyan-500/30 p-3.5 sm:p-4 text-white my-3 select-none",children:[h.jsxs("h2",{className:"text-center text-xs sm:text-sm font-bold tracking-wider text-cyan-300 uppercase mb-3",children:["INFORMASI SITUS RESMI ",e]}),h.jsx("div",{className:"w-full rounded-lg border border-slate-700/50 overflow-hidden text-xs bg-[#050e1f]/80",children:h.jsx("table",{className:"w-full text-left border-collapse",children:h.jsx("tbody",{children:t.map((n,i)=>h.jsxs("tr",{className:`border-b border-slate-700/40 last:border-b-0 ${i%2===0?"bg-transparent":"bg-cyan-950/15"}`,children:[h.jsx("td",{className:"py-2.5 px-3 sm:px-4 text-slate-400 font-medium w-1/3 sm:w-1/4 align-middle whitespace-nowrap",children:n.label}),h.jsx("td",{className:"py-2.5 px-3 sm:px-4 text-slate-200 font-semibold align-middle",children:n.highlight?h.jsx("span",{className:"text-yellow-400 font-bold",children:n.value}):h.jsx("span",{children:n.value})})]},i))})})})]})}),E4=Ks.memo(({config:r})=>{const e=r.brandName||"KANCAH4D",t=[{name:"Rian Pratama",city:"Surabaya",keyword:"WD Maxwin Kilat",text:`"Awalnya ragu coba link alternatif ${e}
3163, ternyata pas tembus Maxwin perkalian x500 di Gates of Olympus tembus 28 juta, proses WD langsung cair dalam 2 menit lunas tanpa potongan. Situs terpercaya nomor satu!"`,rating:"5.0 / 5.0 (Member VVIP)",time:"35 menit lalu"},{name:"Bayu Anggoro",city:"Medan",keyword:"RTP Live Akurat",text:`"Update bocoran RTP live slot gacor ${e} beneran presisi. Coba racikan pola spin Mahjong Ways 2 di jam hoki, scatter beruntun langsung sensational. Modal receh bisa narik jutaan di ${e}!"`,rating:"5.0 / 5.0 (Member VVIP)",time:"1 jam lalu"},{name:"Ferry Kurniawan",city:"Jakarta",keyword:"Pasaran Togel Terlengkap",text:`"Buat pecinta angka jitu pasaran HK, SGP, sama Sydney, ${e} juaranya. Bayaran 4D full prize tertinggi dengan diskon terbaik, result selalu tepat waktu dan transparan tanpa ada manipulasi."`,rating:"5.0 / 5.0 (Member VVIP)",time:"3 jam lalu"},{name:"Siti Rahmawati",city:"Bandung",keyword:"QRIS Auto Deposit",text:`"Fitur deposit QRIS ${e} hitungan 3 detik saldo langsung masuk otomatis. CS livechat 24 jam fast respon dan sangat sopan waktu tanya promo rollingan. Bikin betah main tiap hari."`,rating:"5.0 / 5.0 (Member VVIP)",time:"5 jam lalu"},{name:"Doni Setiawan",city:"Semarang",keyword:"Server VVIP Anti Lag",text:`"Server VVIP resmi ${e} beneran enteng, putaran spin halus tanpa lemot dan winrate kerasa banget bedanya. Sudah buktiin sendiri ratusan testimoni bukan settingan, mantap pokoknya!"`,rating:"5.0 / 5.0 (Member VVIP)",time:"8 jam lalu"},{name:"Agus Wijaya",city:"Balikpapan",keyword:"Daftar Akun Resmi",text:`"Daftar akun VVIP di ${e} prosesnya cepat dan praktis. Bonus new member langsung masuk di depan tanpa syarat ribet. Rekomendasi utama buat yang cari tempat bermain aman dan berbayar lunas!"`,rating:"5.0 / 5.0 (Member VVIP)",time:"12 jam lalu"}];return h.jsxs("div",{id:"review-pengguna",className:"w-full bg-[#071329] rounded-2xl border-2 border-cyan-400 shadow-[0_0_25px_rgba(6,182,212,0.35)] p-4 sm:p-5 text-white flex flex-col relative overflow-hidden my-4",children:[h.jsxs("div",{className:"w-full flex items-center justify-center gap-2 mb-4",children:[h.jsx("span",{className:"h-[2px] w-8 sm:w-12 bg-gradient-to-r from-transparent to-cyan-400"}),h.jsxs("h2",{className:"text-sm sm:text-base font-black tracking-wider text-cyan-300 uppercase drop-shadow-[0_0_8px_rgba(6,182,212,0.8)] flex items-center gap-1.5 text-center",children:[h.jsx(Yo,{className:"w-4 h-4 text-cyan-400"}),"REVIEW PENGGUNA ",e]}),h.jsx("span",{className:"h-[2px] w-8 sm:w-12 bg-gradient-to-l from-transparent to-cyan-400"})]}),h.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-2.5 sm:gap-3 text-left",children:t.map((n,i)=>h.jsxs("div",{className:"p-3 sm:p-3.5 rounded-xl bg-[#050e1f] border border-cyan-500/30 flex flex-col justify-between hover:border-cyan-400/80 transition-all duration-200 group",children:[h.jsxs("div",{children:[h.jsxs("div",{className:"flex items-center justify-between gap-2 mb-1.5",children:[h.jsxs("div",{className:"flex items-center gap-1.5 flex-wrap",children:[h.jsx("span",{className:"font-extrabold text-xs text-white",children:n.name}),h.jsxs("span",{className:"text-[10px] text-slate-400",children:["(",n.city,")"]}),h.jsx(Du,{className:"w-3.5 h-3.5 text-cyan-400 fill-cyan-400/20"})]}),h.jsx("div",{className:"flex items-center gap-0.5 text-yellow-400 shrink-0",children:[...Array(5)].map((o,u)=>h.jsx(l2,{className:"w-3 h-3 fill-yellow-400 text-yellow-400"},u))})]}),h.jsx("div",{className:"mb-2",children:h.jsx("span",{className:"inline-block px-1.5 py-0.5 rounded text-[9px] font-bold tracking-wide uppercase bg-cyan-950/80 border border-cyan-500/40 text-cyan-300",children:n.keyword})}),h.jsx("p",{className:"text-[11px] sm:text-xs text-slate-300 italic leading-relaxed mb-3",children:n.text})]}),h.jsxs("div",{className:"pt-2 border-t border-cyan-500/20 flex items-center justify-between text-[10px] text-slate-400",children:[h.jsxs("span",{className:"font-semibold text-cyan-300",children:["Rating: ",n.rating]}),h.jsx("span",{children:n.time})]})]},i))})]})}),_4=({config:r})=>{var g,y,b,D,T;const[e,t]=be.useState(!1),[n,i]=be.useState("contact"),[o,u]=be.useState(0),B=r.brandName||"KANCAH4D";be.useEffect(()=>{const M=()=>{i("contact"),t(!0)},z=()=>{i("faq"),t(!0)},W=K=>{K.key==="Escape"&&t(!1)};return window.addEventListener("open-contact-drawer",M),window.addEventListener("open-faq-drawer",z),window.addEventListener("keydown",W),()=>{window.removeEventListener("open-contact-drawer",M),window.removeEventListener("open-faq-drawer",z),window.removeEventListener("keydown",W)}},[]);const f=[{q:`1. Apa itu Kalkulator Cuan ${B} ?`,a:`Kalkulator Cuan ${B} adalah instrumen berbasis sistem cerdas algoritma statistik yang membantu memproyeksikan estimasi rasio kemenangan, target jackpot optimal, jam hoki terupdate, serta rek
3163omendasi pola spin manual dan turbo berdasarkan modal awal pemain.`},{q:`2. Apakah hasil kalkulasi ${B} ini akurat ?`,a:`Kalkulasi ini menggunakan data riwayat RTP Live real-time dan pola kemenangan member resmi ${B} yang diperbarui setiap saat untuk memberikan gambaran manajemen modal yang terukur dan terbukti efektif.`},{q:`3. Berapa minimal deposit ${B} untuk mulai bermain ?`,a:`Minimal deposit di ${B} sangat terjangkau, yaitu mulai dari Rp 10.000 saja. Dengan modal minim, Anda sudah bisa menikmati seluruh pilihan game slot gacor, togel, live casino, dan lainnya.`},{q:`4. Metode pembayaran apa saja yang didukung di ${B} ?`,a:"Kami mendukung transaksi terlengkap: Seluruh Bank Lokal Indonesia (BCA, Mandiri, BRI, BNI, CIMB, Danamon), E-Wallet (DANA, OVO, GoPay, LinkAja, ShopeePay), serta metode instan QRIS All Payment dan Pulsa tanpa potongan."},{q:`5. Berapa lama proses transaksi deposit dan withdraw ${B} ?`,a:"Proses deposit via QRIS hanya memerlukan waktu sekitar 1 detik. Untuk deposit bank/e-wallet rata-rata 1–2 menit, dan penarikan dana (withdraw) diproses cepat kilat nonstop 24 jam tanpa potongan tersembunyi."},{q:`6. Bagaimana cara menghubungi layanan Customer Service ${B} ?`,a:`Customer Service ${B} siap melayani Anda 24 jam nonstop setiap hari melalui Live Chat di situs resmi, kontak resmi WhatsApp, dan channel Telegram kami dengan respon ramah dan profesional.`}];return h.jsxs(h.Fragment,{children:[e&&h.jsx("div",{onClick:()=>t(!1),className:"fixed inset-0 bg-black/75 backdrop-blur-xs z-50 transition-opacity animate-fadeIn cursor-pointer","aria-hidden":"true"}),h.jsxs("div",{className:`fixed top-0 left-0 h-full w-[310px] sm:w-[360px] max-w-[90vw] bg-gradient-to-b from-[#071329] via-[#081733] to-[#050e1f] border-r-2 border-cyan-400 shadow-[0_0_40px_rgba(6,182,212,0.55)] z-50 flex flex-col justify-between p-4 transition-transform duration-300 ease-in-out select-none ${e?"translate-x-0":"-translate-x-full"}`,children:[h.jsxs("div",{className:"flex flex-col overflow-hidden flex-1",children:[h.jsxs("div",{className:"flex items-center justify-between pb-3 border-b border-cyan-500/30",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-cyan-500/20 text-cyan-300 border border-cyan-400/40 shadow-[0_0_10px_rgba(6,182,212,0.4)]",children:n==="contact"?h.jsx(Qo,{className:"w-4 h-4 text-cyan-300"}):h.jsx(Jp,{className:"w-4 h-4 text-cyan-300"})}),h.jsxs("div",{children:[h.jsx("h3",{className:"text-xs font-black tracking-wider text-white uppercase flex items-center gap-1.5",children:h.jsx("span",{children:n==="contact"?`LAYANAN RESMI ${B}`:`FAQ ${B} RESMI`})}),h.jsxs("span",{className:"text-[10px] text-emerald-400 font-bold flex items-center gap-1",children:[h.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-emerald-400 animate-ping inline-block"}),"RESPON RESMI 24 JAM"]})]})]}),h.jsx("button",{type:"button",onClick:()=>t(!1),className:"p-1.5 rounded-xl bg-slate-800/80 hover:bg-red-500/20 text-slate-300 hover:text-red-400 border border-slate-700 hover:border-red-400/50 transition cursor-pointer",title:"Tutup Menu",children:h.jsx(NB,{className:"w-4 h-4"})})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-1.5 p-1 bg-[#050e1f] rounded-xl border border-cyan-500/30 my-3",children:[h.jsxs("button",{type:"button",onClick:()=>i("contact"),className:`py-1.5 px-2 rounded-lg text-xs font-bold transition flex items-center justify-center gap-1.5 cursor-pointer ${n==="contact"?"bg-gradient-to-r from-cyan-600 to-blue-600 text-white shadow-[0_0_12px_rgba(6,182,212,0.6)]":"text-slate-400 hover:text-cyan-300"}`,children:[h.jsx(Qo,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"LAYANAN RESMI"})]}),h.jsxs("button",{type:"button",onClick:()=>i("faq"),className:`py-1.5 px-2 rounded-lg text-xs font-bold transition flex items-center justify-center gap-1.5 cursor-pointer ${n==="faq"?"bg-gradient-to-r from-cyan-600 to-blue-600 text-white shadow-[0_0_12px_rgba(6,182,212,0.6)]":"text-slate-400 hover:text-cyan-300"}`,children:[h.jsx(Jp,{className:"w-3.5 h-3.5"}),h.jsx("span",{children:"FAQ RESMI"})]})]}),h.jsx("div",{className:"overflow-y-auto pr-1 flex-1 space-y-2.5 custom-scrollbar",children:n==="contact"?h.jsxs(h.Fragment,{children:[h.jsx("p",{className:"text-[11px] text-slate-300 leading-relaxed mb-2",children:"Hubungi customer service resmi kami untuk bantuan deposit, withdraw, dan promo:"}),h.jsxs("div",{className:"space-y-2",children:[((g=r.socialLinks)==null?void 0:g.whatsapp)&&h.jsxs("a",{href:r.socialLinks.whatsapp,target:"_blank",rel:"noopener noreferrer",onClick:()=>t(!1),className:"group p-2.5 rounded-xl bg-[#050e1f] border border-emerald-500/50 hover:border-emerald-400 hover:bg-emerald-950/30 transition flex items-center justify-between shadow-[0_0_10px_rgba(16,185,129,0.15)] hover:shadow-[0_0_15px_rgba(16,185,129,0.4)] cursor-pointer",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-emerald-500/20 text-emerald-400 group-hover:scale-110 transition",children:h.jsx(wd,{className:"w-4 h-4"})}),h.jsxs("div",{children:[h.jsx("div",{className:"text-xs font-bold text-white group-hover:text-emerald-300 transition",children:"WHATSAPP RESMI"}),h.jsx("div",{className:"text-[9px] text-emerald-400 font-mono",children:"Online 24 Jam Nonstop"})]})]}),h.jsx(hi,{className:"w-4 h-4 text-slate-500 group-hover:text-emerald-400 group-hover:translate-x-0.5 transition"})]}),((y=r.socialLinks)==null?void 0:y.telegram)&&h.jsxs("a",{href:r.socialLinks.telegram,target:"_blank",rel:"noopener noreferrer",onClick:()=>t(!1),className:"group p-2.5 rounded-xl bg-[#050e1f] border border-cyan-500/50 hover:border-cyan-400 hover:bg-cyan-950/30 transition flex items-center justify-between shadow-[0_0_10px_rgba(6,182,212,0.15)] hover:shadow-[0_0_15px_rgba(6,182,212,0.4)] cursor-pointer",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-cyan-500/20 text-cyan-300 group-hover:scale-110 transition",children:h.jsx(Td,{className:"w-4 h-4"})}),h.jsxs("div",{children:[h.jsx("div",{className:"text-xs font-bold text-white group-hover:text-cyan-300 transition",children:"TELEGRAM RESMI"}),h.jsx("div",{className:"text-[9px] text-cyan-400 font-mono",children:"Channel & CS Aktif"})]})]}),h.jsx(hi,{className:"w-4 h-4 text-slate-500 group-hover:text-cyan-300 group-hover:translate-x-0.5 transition"})]}
3163),((b=r.socialLinks)==null?void 0:b.twitter)&&h.jsxs("a",{href:r.socialLinks.twitter,target:"_blank",rel:"noopener noreferrer",onClick:()=>t(!1),className:"group p-2.5 rounded-xl bg-[#050e1f] border border-slate-600/60 hover:border-slate-300 hover:bg-slate-900 transition flex items-center justify-between shadow-[0_0_10px_rgba(255,255,255,0.08)] cursor-pointer",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-slate-800 text-white group-hover:scale-110 transition flex items-center justify-center w-7 h-7 font-black text-xs",children:"𝕏"}),h.jsxs("div",{children:[h.jsx("div",{className:"text-xs font-bold text-white group-hover:text-slate-200 transition",children:"TWITTER / X"}),h.jsx("div",{className:"text-[9px] text-slate-400 font-mono",children:"Info & Update Promo"})]})]}),h.jsx(hi,{className:"w-4 h-4 text-slate-500 group-hover:text-white group-hover:translate-x-0.5 transition"})]}),((D=r.socialLinks)==null?void 0:D.youtube)&&h.jsxs("a",{href:r.socialLinks.youtube,target:"_blank",rel:"noopener noreferrer",onClick:()=>t(!1),className:"group p-2.5 rounded-xl bg-[#050e1f] border border-red-500/50 hover:border-red-400 hover:bg-red-950/30 transition flex items-center justify-between shadow-[0_0_10px_rgba(239,68,68,0.15)] hover:shadow-[0_0_15px_rgba(239,68,68,0.4)] cursor-pointer",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-red-500/20 text-red-500 group-hover:scale-110 transition",children:h.jsx(Ad,{className:"w-4 h-4"})}),h.jsxs("div",{children:[h.jsx("div",{className:"text-xs font-bold text-white group-hover:text-red-300 transition",children:"YOUTUBE CHANNEL"}),h.jsx("div",{className:"text-[9px] text-red-400 font-mono",children:"Video & Pola Gacor"})]})]}),h.jsx(hi,{className:"w-4 h-4 text-slate-500 group-hover:text-red-400 group-hover:translate-x-0.5 transition"})]}),h.jsxs("a",{href:r.liveChatUrl||((T=r.socialLinks)==null?void 0:T.pinterest)||r.registerUrl||"#",target:"_blank",rel:"noopener noreferrer",onClick:()=>t(!1),className:"group p-2.5 rounded-xl bg-[#050e1f] border border-yellow-500/60 hover:border-yellow-400 hover:bg-yellow-950/30 transition flex items-center justify-between shadow-[0_0_12px_rgba(234,179,8,0.2)] hover:shadow-[0_0_18px_rgba(234,179,8,0.5)] cursor-pointer",children:[h.jsxs("div",{className:"flex items-center gap-2.5",children:[h.jsx("div",{className:"p-1.5 rounded-lg bg-yellow-500/20 text-yellow-400 group-hover:scale-110 transition",children:h.jsx(Yo,{className:"w-4 h-4"})}),h.jsxs("div",{children:[h.jsx("div",{className:"text-xs font-bold text-yellow-300 group-hover:text-yellow-200 transition",children:"LIVECHAT 24H"}),h.jsx("div",{className:"text-[9px] text-yellow-400 font-mono",children:"Respon Instan 1 Detik"})]})]}),h.jsx(hi,{className:"w-4 h-4 text-slate-500 group-hover:text-yellow-400 group-hover:translate-x-0.5 transition"})]})]})]}):h.jsxs(h.Fragment,{children:[h.jsxs("p",{className:"text-[11px] text-slate-300 leading-relaxed mb-2",children:["Pertanyaan yang sering diajukan seputar Kalkulator & Layanan ",B,":"]}),h.jsx("div",{className:"space-y-2",children:f.map((M,z)=>{const W=o===z;return h.jsxs("div",{className:"rounded-xl border border-cyan-500/30 bg-[#050e1f] overflow-hidden transition-all",children:[h.jsxs("button",{type:"button",onClick:()=>u(W?null:z),className:"w-full p-2.5 flex items-center justify-between gap-2 text-left font-bold text-xs text-slate-200 hover:text-cyan-300 transition cursor-pointer",children:[h.jsx("span",{children:M.q}),h.jsx("span",{className:"text-cyan-400 shrink-0",children:W?h.jsx(n1,{className:"w-3.5 h-3.5"}):h.jsx(aC,{className:"w-3.5 h-3.5"})})]}),W&&h.jsx("div",{className:"px-2.5 pb-2.5 pt-1 text-[11px] text-slate-300 border-t border-cyan-500/20 leading-relaxed bg-[#061226]/60",children:M.a})]},z)})})]})})]}),h.jsx("div",{className:"pt-3 border-t border-cyan-500/20 text-center",children:h.jsx("button",{type:"button",onClick:()=>t(!1),className:"w-full py-2 rounded-lg bg-slate-800/80 hover:bg-slate-700 text-slate-300 hover:text-white text-xs font-semibold transition cursor-pointer",children:"✕ Tutup Menu"})})]}),!e&&h.jsxs("aside",{"aria-label":"Menu Layanan & FAQ",className:"fixed left-0 top-[52%] -translate-y-1/2 z-40 select-none flex flex-col gap-3 items-start",children:[h.jsxs("div",{className:"relative group",children:[h.jsxs("div",{onClick:()=>{i("contact"),t(!0)},className:"absolute -top-6 left-1 cursor-pointer select-none animate-bounce",children:[h.jsx("div",{className:"bg-gradient-to-r from-blue-600 via-sky-500 to-cyan-400 text-white font-black text-[9px] px-2 py-0.5 rounded-md shadow-[0_0_12px_rgba(14,165,233,0.9)] tracking-wider border border-cyan-200/70 uppercase whitespace-nowrap",children:"!! KLIK DISINI !!"}),h.jsx("div",{className:"w-0 h-0 border-l-[4px] border-l-transparent border-r-[4px] border-r-transparent border-t-[5px] border-t-sky-500 ml-3.5 -mt-0.5"})]}),h.jsxs("button",{type:"button",onClick:()=>{i("contact"),t(!0)},title:"Buka Menu Layanan Resmi","aria-label":"Buka Menu Layanan Resmi",className:"w-10 h-11 sm:w-11 sm:h-12 rounded-r-2xl rounded-l-none bg-gradient-to-r from-blue-600 via-sky-500 to-cyan-400 border-y border-r-2 border-cyan-200 shadow-[0_0_20px_rgba(14,165,233,0.85)] hover:w-12 transition-all duration-300 flex flex-col justify-center items-center gap-1 pl-1 cursor-pointer hover:shadow-[0_0_25px_rgba(6,182,212,1)] active:scale-95",children:[h.jsx("span",{className:"w-5 h-1 rounded-full bg-cyan-100 shadow-[0_0_4px_rgba(255,255,255,0.9)]"}),h.jsx("span",{className:"w-5 h-1 rounded-full bg-cyan-200 shadow-[0_0_4px_rgba(6,182,212,0.8)]"}),h.jsx("span",{className:"w-5 h-1 rounded-full bg-cyan-100 shadow-[0_0_4px_rgba(255,255,255,0.9)]"})]})]}),h.jsxs("div",{className:"relative group",children:[h.jsxs("div",{onClick:()=>{i("faq"),t(!0)},className:"absolute -top-6 left-1 cursor-pointer select-none animate-pulse",children:[h.jsx("div",{className:"bg-gradient-to-r from-emerald-600 via-teal-500 to-cyan-400 text-white font-black text-[9px] px-2 py-0.5 rounded-md shadow-[0_0_12px_rgba(16,185,129,0.9)] tracking-wider border border-teal-200/70 uppercase whitespace-nowrap",children:"!! FAQ DISINI !!"}),h.jsx("div",{className:"w-0 h-0 border-l-[4px] border-l-transparent border-r-[4px] border-r-transparent border-t-[5px] border-t-teal-500 ml-3.5 -mt-0.5"})]}),h.jsx("button",{type:"button",onClick:()=>{i("faq"),t(!0)},title:"Buka FAQ Kancah4D Resmi","aria-label":"Buka FAQ Kancah4D Resmi",className:"w-10 h-11 sm:w-11 sm:h-12 rounded-r-2xl rounded-l-none bg-gradient-to-r from-emerald-600 via-teal-500 to-cyan-500 border-y border-r-2 border-emerald-200 shadow-[0_0_20px_rgba(16,185,129,0.85)] hover:w-12 transition-all duration-300 flex flex-col justify-center items-center gap-0.5 pl-1 cursor-pointer hover:shadow-[0_0_25px_rgba(20,184,166,1)] active:scale-95 text-white",children:h.jsx(Jp,{className:"w-5 h-5 text-white drop-shadow-[0_0_6px_rgba(255,255,255,0.8)]"})})]})]})]})},D4=({isOpen:r,onClose:e,config:t})=>{if(!r)return null;const n=t.brandName||"KANCAH4D";return h.jsx("div",{className:"fixed inset-0 bg-black/80 backdrop-blur-md z-[999999] flex items-center justify-center p-4 overflow-y-auto",onClick:i=>{i.target===i.currentTarget&&e()},children:h.jsxs("div",{className:"relative w-full max-w-lg bg-[#071329] border-2 border-cyan-400 rounded-2xl p-5 text-white shadow-[0_0_35px_rgba(6,182,212,0.6)] animate-fadeIn text-left",children:[h.jsx("button",{onClick:e,className:"absolute top-4 right-4 w-7 h-7 rounded-full bg-cyan-950/80 border border-cyan-400 text-cyan-300 hover:text-white flex items-center justify-center transition cursor-pointer",children:h.jsx(NB,{className:"w-4 h-4"})}),h.jsxs("div",{className:"flex items-center gap-2 mb-3 pb-3 border-b border-cyan-500/30",children:[h.jsx(Al,{className:"w-5 h-5 text-cyan-400"}),h.jsxs("h3",{className:"text-sm sm:text-base font-black text-cyan-300 uppercase tracking-wider",children:["KEBIJAKAN & PRIVASI RESMI ",n]})]}),h.jsxs("div",{className:"space-y-3 text-xs text-slate-300 leading-relaxed max-h-[70vh] overflow-y-auto pr-1",children:[h.jsxs("div",{className:"p-3 rounded-lg bg-[#040c1c] border border-cyan-500/20",children:[h.jsxs("h4",{className:"font-bold text-cyan-200 mb-1 flex items-center gap-1.5",children:[h.jsx(iC,{className:"w-3.5 h-3.5 text-cyan-400"}),"1. Keamanan & Enkripsi Data"]}),h.jsxs("p",{className:"text-[11px] text-slate-400",children:["Platform ",n," dilengkapi dengan sertifikasi proteksi enkripsi SSL 256-Bit tingkat perbankan. Seluruh data identitas pengguna, riwayat kalkulasi, dan aktivitas transaksi dijamin 100% aman dan dirahasiakan tanpa pihak ketiga."]})]}),h.jsxs("div",{className:"p-3 rounded-lg bg-[#040c1c] border border-cyan-500/20",children:[h.jsxs("h4",{className:"font-bold text-cyan-200 mb-1 flex items-center gap-1.5",children:[h.jsx(Du,{className:"w-3.5 h-3.5 text-emerald-400"}),"2. Keaslian Bukti Kemenangan"]}),h.jsxs("p",{className:"text-[11px] text-slate-400",children:["Setiap bukti transfer kemenangan jackpot yang tercantum pada platform ini adalah otentik dan bersumber langsung dari sistem pembayaran transaksi member resmi ",n,"."]})]}),h.jsxs("div",{className:"p-3 rounded-lg bg-[#040c1c] border border-cyan-500/20",children:[h.jsxs("h4",{className:"font-bold text-cyan-200 mb-1 flex items-center gap-1.5",children:[h.jsx(Al,{className:"w-3.5 h-3.5 text-yellow-400"}),"3. Tanggung Jawab & Batasan Usia (18+)"]}),h.jsx("p",{className:"text-[11px] text-slate-400",children:"Layanan ini ditujukan hanya untuk pengguna yang telah berusia 18 tahun ke atas. Harap bermain secara bijak dengan manajemen keuangan y
3163ang bertanggung jawab."})]})]}),h.jsx("div",{className:"mt-4 pt-3 border-t border-cyan-500/30 flex justify-end",children:h.jsx("button",{onClick:e,className:"py-2 px-5 rounded-lg bg-gradient-to-r from-cyan-500 to-blue-600 hover:from-cyan-400 hover:to-blue-500 text-slate-950 font-black text-xs uppercase tracking-wider transition cursor-pointer shadow-[0_0_12px_rgba(6,182,212,0.6)]",children:"SAYA MENGERTI"})})]})})},v4=Ks.memo(()=>h.jsxs("div",{className:"fixed inset-0 pointer-events-none z-0 overflow-hidden select-none",id:"kancah-cyber-background",style:{contain:"strict",transform:"translate3d(0, 0, 0)",backfaceVisibility:"hidden"},children:[h.jsx("div",{className:"absolute inset-0 bg-[#02050f]"}),h.jsx("div",{className:"absolute inset-0",style:{background:"radial-gradient(ellipse 80% 65% at 50% 25%, #061838 0%, #030818 60%, #01040c 100%)"}}),h.jsxs("svg",{className:"absolute inset-0 w-full h-full opacity-25",xmlns:"http://www.w3.org/2000/svg",preserveAspectRatio:"none",children:[h.jsx("defs",{children:h.jsxs("pattern",{id:"cyber-circuit-pattern",width:"220",height:"220",patternUnits:"userSpaceOnUse",children:[h.jsx("circle",{cx:"10",cy:"10",r:"1",fill:"#00e5ff",opacity:"0.3"}),h.jsx("circle",{cx:"110",cy:"10",r:"1",fill:"#00e5ff",opacity:"0.2"}),h.jsx("circle",{cx:"110",cy:"110",r:"1.5",fill:"#38bdf8",opacity:"0.4"}),h.jsx("circle",{cx:"210",cy:"210",r:"1",fill:"#00e5ff",opacity:"0.3"}),h.jsx("path",{d:"M10 60 L70 60 L95 85 L180 85",fill:"none",stroke:"#0284c7",strokeWidth:"1.2",opacity:"0.35"}),h.jsx("path",{d:"M30 140 L80 140 L110 110 L150 110 L170 130 L210 130",fill:"none",stroke:"#00e5ff",strokeWidth:"1.2",opacity:"0.3"}),h.jsx("path",{d:"M140 10 L140 50 L165 75 L165 140",fill:"none",stroke:"#0369a1",strokeWidth:"1",opacity:"0.25"}),h.jsx("path",{d:"M60 180 L110 180 L135 155 L200 155",fill:"none",stroke:"#00e5ff",strokeWidth:"1",opacity:"0.25"}),h.jsx("circle",{cx:"70",cy:"60",r:"2.5",fill:"#00e5ff",opacity:"0.6"}),h.jsx("circle",{cx:"180",cy:"85",r:"2",fill:"#38bdf8",opacity:"0.5"}),h.jsx("circle",{cx:"80",cy:"140",r:"2.5",fill:"#00e5ff",opacity:"0.7"}),h.jsx("circle",{cx:"170",cy:"130",r:"2",fill:"#38bdf8",opacity:"0.6"}),h.jsx("circle",{cx:"135",cy:"155",r:"2.5",fill:"#00e5ff",opacity:"0.5"})]})}),h.jsx("rect",{width:"100%",height:"100%",fill:"url(#cyber-circuit-pattern)"})]}),h.jsx("div",{className:"absolute top-6 left-1/2 -translate-x-1/2 w-[700px] max-w-[95vw] h-[450px] pointer-events-none opacity-40 animate-pulse-glow",style:{background:"radial-gradient(ellipse at center, rgba(6,182,212,0.3) 0%, rgba(14,116,224,0.15) 45%, transparent 75%)"}}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-1",style:{to
3163p:"35%",left:"max(2vw, 12px)",width:"52px",height:"52px"},children:h.jsx("span",{className:"cyber-water-bubble-dot"})}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-2",style:{top:"68%",left:"max(3vw, 20px)",width:"42px",height:"42px"},children:h.jsx("span",{className:"cyber-water-bubble-dot"})}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-1 hidden sm:block",style:{top:"18%",left:"max(5vw, 35px)",width:"22px",height:"22px"}}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-2",style:{top:"62%",right:"max(2.5vw, 16px)",width:"48px",height:"48px"},children:h.jsx("span",{className:"cyber-water-bubble-dot"})}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-1",style:{top:"38%",right:"max(4vw, 32px)",width:"28px",height:"28px"},children:h.jsx("span",{className:"cyber-water-bubble-dot"})}),h.jsx("div",{className:"cyber-water-bubble animate-bubble-2 hidden sm:block",style:{top:"82%",right:"max(5vw, 42px)",width:"20px",height:"20px"}}),h.jsx("div",{className:"absolute top-[18%] left-[10%] w-1.5 h-1.5 bg-cyan-300 rounded-full animate-star-twinkle opacity-75"}),h.jsx("div",{className:"absolute top-[52%] right-[12%] w-1.5 h-1.5 bg-sky-300 rounded-full animate-star-twinkle opacity-75",style:{animationDelay:"1.5s"}}),h.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"radial-gradient(ellipse 95% 85% at 50% 35%, transparent 50%, rgba(1, 4, 12, 0.7) 90%, #01030a 100%)"}})]}));var ff={},w4=()=>{window.si||(window.si=function(...e){window.siq=window.siq||[],window.siq.push(e)})},T4="@vercel/speed-insights",A4="2.0.0";function N4(){return typeof window<"u"}function I4(){try{const r="production"}catch{}return"production"}function Bw(){return I4()==="development"}function S4(r){return r.scriptSrc?mf(r.scriptSrc):Bw()?"https://va.vercel-scripts.com/v1/speed-insights/script.debug.js":r.dsn?"https://va.vercel-scripts.com/v1/speed-insights/script.js":r.basePath?mf(`${r.basePath}/speed-insights/script.js`):"/_vercel/speed-insights/script.js"}function R4(r,e){var t;let n=r;if(e)try{n={...(t=JSON.parse(e))==null?void 0:t.speedInsights,...r}}catch{}const i={sdkn:T4+(n.framework?`/${n.framework}`:""),sdkv:A4};return n.sampleRate&&(i.sampleRate=n.sampleRate.toString()),n.route&&(i.route=n.route),Bw()&&n.debug===!1&&(i.debug="false"),n.dsn&&(i.dsn=n.dsn),n.endpoint?i.endpoint=mf(n.endpoint):n.basePath&&(i.endpoint=mf(`${n.basePath}/speed-insights/vitals`)),{src:S4(n),beforeSend:n.beforeSend,dataset:i}}function mf(r){return r.startsWith("http://")||r.startsWith("https://")||r.startsWith("/")?r:`/${r}`}function O4(r={},e){var t;if(!N4()||r.route===null)return null;w4();const{beforeSend:n,src:i,dataset:o}=R4(r,e);if(document.head.querySelector(`script[src*="${i}"]`))return null;n&&((t=window.si)==null||t.call(window,"beforeSend",n));const u=document.createElement("script");u.src=i,u.defer=!0;for(const[B,f]of Object.entries(o))u.dataset[B]=f;return u.onerror=()=>{console.log(`[Vercel Speed Insights] Failed to load script from ${i}. Please check if any content blockers are enabled and try again.`)},document.head.appendChild(u),{setRoute:B=>{u.dataset.route=B??void 0}}}function k4(){if(!(typeof process>"u"||typeof ff>"u"))return ff.REACT_APP_VERCEL_OBSERVABILITY_BASEPATH}function L4(){if(!(typeof process>"u"||typeof ff>"u"))return ff.REACT_APP_VERCEL_OBSERVABILITY_CLIENT_CONFIG}function j4(r){be.useEffect(()=>{var t;r.beforeSend&&((t=window.si)==null||t.call(window,"beforeSend",r.beforeSend))},[r.beforeSend]);const e=be.useRef(null);return be.useEffect(()=>{if(!e.current){const t=O4({framework:r.framework??"react",basePath:r.basePath??k4(),...r},r.configString??L4());t&&(e.current=t.setRoute)}},[r]),be.useEffect(()=>{e.current&&r.route&&e.current(r.route)},[r.route]),null}function M4(){const r=be.useMemo(()=>zf(),[]),[e,t]=be.useState(()=>r.proofs),[n,i]=be.useState(()=>r.banners),[o,u]=be.useState(()=>r.marqueeItems),[B,f]=be.useState(()=>r.config),[g,y]=be.useState(()=>r.updatedAt||null),[b,D]=be.useState(null),[T,M]=be.useState(null),[z,W]=be.useState(!1),[K,he]=be.useState(!1),[de,ce]=be.useState(!1),[_e,ye]=be.useState(!0),[S,A]=be.useState(!1),k=be.useMemo(()=>b&&e.find(Ie=>Ie.id===b)||T,[b,e,T]),[w,O]=be.useState(()=>{try{return sessionStorage.getItem("k4d_owner_pin")}catch{return null}}),L=!!w,N=be.useCallback(Ie=>{Ie.proofs&&Ie.proofs.length>0&&t(Ie.proofs),Ie.banners&&Ie.banners.length>0&&i(Ie.banners),Ie.marqueeItems&&Ie.marqueeItems.length>0&&u(Ie.marqueeItems),Ie.config&&f(Ie.config),Ie.updatedAt&&y(Ie.updatedAt),sC(Ie)},[]);be.useEffect(()=>{sC(r);const Ie=c4(ae=>{N(ae)}),P=ae=>{const xe=ae;xe.detail&&N(xe.detail)};return window.addEventListener("k4d_local_update",P),()=>{Ie(),window.removeEventListener("k4d_local_update",P)}},[N,r]),be.useEffect(()=>{const Ie=B.faviconUrl||"https://ik.imagekit.io/dxokd3m9y/favicon.png";let P=document.querySelector("link[rel~='icon']");P||(P=document.createElement("link"),P.rel="icon",document.head.appendChild(P)),P.href=Ie,P.type="image/png";const ae=document.querySelector("link[rel='apple-touch-icon']");ae&&(ae.href=Ie);const xe=document.querySelector("link[rel='shortcut icon']");xe&&(xe.href=Ie)},[B.faviconUrl]);const Le=be.useCallback(Ie=>{D(Ie.id),M(Ie)},[]),Bt=be.useCallback(()=>{D(null),M(null)},[]),$=Ie=>{O(Ie);try{sessionStorage.setItem("k4d_owner_pin",Ie)}catch{}W(!0)}
3163,pe=()=>{O(null);try{sessionStorage.removeItem("k4d_owner_pin")}catch{}W(!1)},Re=async()=>{const Ie=await B4();Ie&&N(Ie)},qe=B.brandName||"KANCAH4D";return h.jsxs("div",{className:"min-h-screen w-full bg-[#02050f] text-slate-100 flex flex-col items-center justify-start relative overflow-x-hidden selection:bg-cyan-500 selection:text-black",children:[h.jsx(v4,{}),h.jsxs("main",{className:"relative z-10 w-full max-w-5xl min-h-screen flex flex-col items-center px-3 sm:px-4 lg:px-6 py-3",children:[h.jsx(b2,{config:B,isOwner:L,onOpenOwnerAuth:()=>L?W(!0):ce(!0),onOpenAdmin:()=>W(!0),onLogoutOwner:pe,onOpenEmbed:()=>he(!0),onOpenPrivacy:()=>A(!0)}),h.jsx(D2,{items:o}),h.jsxs("section",{className:"w-full grid grid-cols-1 lg:grid-cols-12 gap-4 lg:gap-5 my-2.5 items-start",children:[h.jsx("div",{className:"lg:col-span-6 flex flex-col gap-3",children:h.jsxs("div",{className:"w-full bg-[#071329] rounded-2xl border-2 border-cyan-400 shadow-[0_0_25px_rgba(6,182,212,0.4)] p-3.5 sm:p-4 text-white relative overflow-hidden flex flex-col items-center",children:[h.jsx("div",{className:"absolute -top-10 -left-10 w-36 h-36 bg-cyan-500/20 rounded-full blur-2xl pointer-events-none"}),h.jsxs("div",{className:"w-full grid grid-cols-2 gap-2 mb-2 px-0.5",children:[h.jsxs("div",{className:"flex items-center justify-center gap-1.5 py-1.5 px-2 rounded-full bg-[#050e1f] border border-cyan-400/60 shadow-[0_0_8px_rgba(6,182,212,0.25)] text-[9px] sm:text-[11px] font-black text-cyan-300 text-center",children:[h.jsx(Du,{className:"w-3.5 h-3.5 text-cyan-400 flex-shrink-0"}),h.jsx("span",{className:"truncate",children:"SISTEM VIP RESMI"})]}),h.jsxs("div",{className:"flex items-center justify-center gap-1.5 py-1.5 px-2 rounded-full bg-[#050e1f] border border-cyan-400/60 shadow-[0_0_8px_rgba(234,179,8,0.25)] text-[9px] sm:text-[11px] font-bold text-yellow-300 text-center",children:[h.jsx(e2,{className:"w-3.5 h-3.5 text-yellow-400 flex-shrink-0"}),h.jsx("span",{className:"truncate",children:"BUKTI JP TERUPDATE"})]})]}),h.jsx("div",{className:"w-full my-1",children:h.jsx(x2,{banners:n})}),h.jsxs("div",{className:"w-full my-2 p-2.5 sm:p-3 rounded-xl bg-gradient-to-r from-blue-950/80 via-cyan-950/60 to-blue-950/80 border border-cyan-400/70 flex items-center justify-center gap-2 shadow-[0_0_15px_rgba(6,182,212,0.35)] text-center",children:[h.jsx(AA,{className:"w-4 h-4 text-yellow-300 animate-bounce flex-shrink-0"}),h.jsxs("span",{className:"text-[10px] sm:text-xs font-black tracking-wider text-yellow-300 uppercase drop-shadow-sm leading-snug",children:["KLAIM LUCKY SPIN DI ",qe," HADIAH SALDO UP 200K"]})]}),h.jsxs("div",{className:"w-full my-2 pt-2 border-t border-cyan-500/30",children:[h.jsxs("div",{className:"flex items-center justify-between gap-2 mb-2 px-1",children:[h.jsxs("div",{className:"flex items-center gap-1.5 min-w-0",children:[h.jsx(Sr,{className:"w-3.5 h-3.5 text-yellow-400 flex-shrink-0 animate-pulse"}),h.jsx("span",{className:"text-xs sm:text-sm font-black tracking-wider text-cyan-300 uppercase whitespace-nowrap",children:"BUKTI JACKPOT & POLA GACOR"})]}),h.jsx("span",{className:"text-[9.5px] sm:text-[10.5px] text-slate-400 font-medium whitespace-nowrap flex-shrink-0",children:"Klik untuk lihat pola"})]}),h.jsx(_2,{proofs:e,onSelectProof:Le})]}),h.jsxs("div",{className:"w-full flex flex-col gap-2.5 mt-2.5 pt-2.5 border-t border-cyan-500/20",children:[B.showMainCtaButton!==!1&&B.mainCtaUrl&&h.jsxs("a",{href:B.mainCtaUrl||"https://akseslink.com/kancah4d",target:"_blank",rel:"noopener noreferrer",id:"btn-cta-main-website",className:"group relative flex items-center justify-center w-full py-3.5 px-4 bg-gradient-to-r from-amber-500 via-yellow-400 to-amber-500 hover:from-yellow-400 hover:to-amber-400 text-slate-950 font-black rounded-xl border-2 border-yellow-200 shadow-[0_0_22px_rgba(234,179,8,0.75)] overflow-hidden transition-all duration-200 transform hover:scale-[1.01] active:scale-[0.98] text-xs sm:text-sm uppercase tracking-wider min-h-[48px]",children:[h.jsx("div",{className:"absolute inset-0 w-1/2 h-full bg-gradient-to-r from-transparent via-white/50 to-transparent skew-x-[-25deg] animate-btn-shine pointer-events-none"}),h.jsxs("div",{className:"relative z-10 flex items-center justify-center gap-2 font-black text-center",children:[h.jsx(bl,{className:"w-4 h-4 text-red-600 animate-bounce flex-shrink-0"}),h.jsx("span",{className:"truncate",children:B.mainCtaText||"🚀 KUNJUNGI WEBSITE UTAMA KANCAH4D"})]})]}),h.jsxs("a",{href:B.registerUrl||"https://akseslink.com/kancah4d",target:"_blank",rel:"noopener noreferrer",id:"btn-daftar-vvip",className:"group relative flex items-center justify-center w-full py-3.5 px-4 bg-gradient-to-r from-[#0d3b82] via-[#104eab] to-[#0a2e66] hover:from-[#1354b8] hover:via-[#1965dd] hover:to-[#0f408e] text-white font-black text-xs sm:text-sm rounded-xl border-2 border-cyan-400 shadow-[0_0_20px_rgba(6,182,212,0.45)] overflow-hidden transition-all duration-200 transform hover:scale-[1.01] active:scale-[0.98] uppercase tracking-wider min-h-[48px]",children:[h.jsx("div",{className:"absolute inset-0 w-1/2 h-full bg-gradient-to-r from-transparent via-white/40 to-transparent skew-x-[-25deg] animate-btn-shine pointer-events-none"}),h.jsxs("div",{className:"relative z-10 flex items-center justify-center gap-2 text-center",children:[h.jsx(GA,{className:"w-4 h-4 text-yellow-300 flex-shrink-0"}),h.jsx("span",{className:"truncate",children:B.registerButtonText||"DAFTAR AKUN VVIP"})]})]})]})]})}),h.jsx("div",{className:"lg:col-span-6 flex flex-col gap-3",children:h.jsx(b4,{config:B})})]}),h.jsx("section",{className:"w-full",children:h.jsx(x4,{config:B})}),h.jsx("section",{className:"w-full",children:h.jsx(E4,{config:B})}),h.jsxs("footer",{className:"w-full py-6 text-center text-xs text-slate-400 space-y-2.5 border-t border-cyan-500/30 mt-4 select-none",children:[h.jsxs("div",{className:"flex items-center justify-center gap-2 sm:gap-3 text-[11px] sm:text-xs text-cyan-300 flex-wrap font-bold",children:[h.jsx("a",{href:"#kalkulator-cuan-cerdas",className:"hover:text-white transition",children:"Kalkulator Cuan"}),h.jsx("span",{children:"•"}),h.jsx("a",{href:"#info-kancah4d",className:"hover:text-white transition",children:"Info Situs"}),h.jsx("span",{children:"•"}),h.jsx("button",{type:"button",onClick:()=>window.dispatchEvent(new CustomEvent("open-faq-drawer")),className:"hover:text-white transition cursor-pointer text-cyan-300",children:"FAQ"}),h.jsx("span",{children:"•"}),h.jsx("a",{href:"#review-pengguna",className:"hover:text-white transition",children:"Review Pengguna"}),h.jsx("span",{children:"•"}),h.jsx("button",{type:"button",onClick:()=>window.dispatchEvent(new CustomEvent("open-contact-drawer")),className:"hover:text-white transition cursor-pointer text-cyan-300",children:"Kontak Resmi"}),h.jsx("span",{children:"•"}),h.jsxs("button",{onClick:()=>A(!0),className:"hover:text-white transition cursor-pointer flex items-center gap-1 text-cyan-400",children:[h.jsx(Al,{className:"w-3 h-3"}),h.jsx("span",{children:"Kebijakan & Privasi"})]})]}),h.jsxs("div",{className:"flex items-center justify-center gap-1.5 text-slate-300 text-[11px] font-semibold",children:[h.jsx(Al,{className:"w-3.5 h-3.5 text-emerald-400"}),h.jsx("span",{children:B.footerText||`OFFICIAL ${qe} • LISENSI RESMI RESMI 2026`}),h.jsx("span",{className:"w-1 h-1 rounded-full bg-slate-600"}),h.jsxs("span",{className:"text-[10px] text-emerald-400 flex items-center gap-1",children:[h.jsx(i1,{className:"w-2.5 h-2.5 animate-pulse"}),"LIVE"]})]}),h.jsxs("div",{className:"text-[10px] text-slate-500 flex items-center justify-center gap-2 pt-1",children:[h.jsx("span",{children:B.copyrightText||`© 2026 Perlindungan Hak Cipta Resmi | KALKULATOR ${qe}`}),h.jsx("span",{children:"•"}),h.jsxs("button",{onClick:()=>L?W(!0):ce(!0),className:"text-slate-500 hover:text-yellow-400 transition cursor-pointer flex items-center gap-1",title:"Akses Khusus Pemilik",children:[h.jsx(iC,{className:"w-3 h-3"}),h.jsx("span",{children:L?"Panel Pemilik":"Kelola"})]})]})]})]}),L&&h.jsx("aside",{"aria-label":"Aksi Pemilik",className:"fixed bottom-4 right-4 z-40",children:h.jsxs("button",{onClick:()=>W(!0),className:"flex items-center gap-2 py-2.5 px-4 bg-gradient-to-r from-yellow-500 to-amber-600 hover:from-yellow-400 hover:to-amber-500 text-slate-950 font-black text-xs rounded-full shadow-[0_4px_25px_rgba(234,179,8,0.5)] border border-yellow-300 transition-all transform hover:scale-105 active:scale-95 cursor-pointer uppercase tracking-wider",title:"Update bukti kemenangan baru",children:[h.jsx(Sr,{className:"w-4 h-4"}),h.jsx("span",{children:"+ Update Bukti"})]})}),h.jsx(_4,{config:B}),h.jsx(D4,{isOpen:S,onClose:()=>A(!1),config:B}),h.jsx(w2,{config:B,isOpen:_e,onClose:()=>ye(!1)}),h.jsx(v2,{proof:k,proofs:e,config:B,onClose:Bt,onNavigate:Le}),h.jsx(g4,{isOpen:de,onClose:()=>ce(!1),onSuccess:$}),L&&w&&h.jsx(m4,{isOpen:z,onClose:()=>W(!1),adminPin:w,proofs:e,banners:n,marqueeItems:o,config:B,onServerUpdateSuccess:Re}),h.jsx(p4,{isOpen:K,onClose:()=>he(!1),proofs:e,banners:n,marqueeItems:o,config:B}),h.jsx(j4,{})]})}eA.createRoot(document.getElementById("root")).render(h.jsx(be.StrictMode,{children:h.jsx(M4,{})}));

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.