var AN=Object.defineProperty;var EN=(n,t,e)=>t in n?AN(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var Wn=(n,t,e)=>EN(n,typeof t!="symbol"?t+"":t,e);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))s(l);new MutationObserver(l=>{for(const o of l)if(o.type==="childList")for(const c of o.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&s(c)}).observe(document,{childList:!0,subtree:!0});function e(l){const o={};return l.integrity&&(o.integrity=l.integrity),l.referrerPolicy&&(o.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?o.credentials="include":l.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(l){if(l.ep)return;l.ep=!0;const o=e(l);fetch(l.href,o)}})();var Wv=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function zy(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var fp={exports:{}},tu={};/**
 * @license React
 * react-jsx-runtime.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var tS;function ON(){if(tS)return tu;tS=1;var n=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function e(s,l,o){var c=null;if(o!==void 0&&(c=""+o),l.key!==void 0&&(c=""+l.key),"key"in l){o={};for(var f in l)f!=="key"&&(o[f]=l[f])}else o=l;return l=o.ref,{$$typeof:n,type:s,key:c,ref:l!==void 0?l:null,props:o}}return tu.Fragment=t,tu.jsx=e,tu.jsxs=e,tu}var eS;function NN(){return eS||(eS=1,fp.exports=ON()),fp.exports}var gt=NN(),dp={exports:{}},Rt={};/**
 * @license React
 * react.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var nS;function CN(){if(nS)return Rt;nS=1;var n=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),e=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),l=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),c=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),m=Symbol.iterator;function _(B){return B===null||typeof B!="object"?null:(B=m&&B[m]||B["@@iterator"],typeof B=="function"?B:null)}var S={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,A={};function x(B,G,tt){this.props=B,this.context=G,this.refs=A,this.updater=tt||S}x.prototype.isReactComponent={},x.prototype.setState=function(B,G){if(typeof B!="object"&&typeof B!="function"&&B!=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,B,G,"setState")},x.prototype.forceUpdate=function(B){this.updater.enqueueForceUpdate(this,B,"forceUpdate")};function C(){}C.prototype=x.prototype;function w(B,G,tt){this.props=B,this.context=G,this.refs=A,this.updater=tt||S}var E=w.prototype=new C;E.constructor=w,v(E,x.prototype),E.isPureReactComponent=!0;var M=Array.isArray,O={H:null,A:null,T:null,S:null,V:null},D=Object.prototype.hasOwnProperty;function I(B,G,tt,et,at,Nt){return tt=Nt.ref,{$$typeof:n,type:B,key:G,ref:tt!==void 0?tt:null,props:Nt}}function z(B,G){return I(B.type,G,void 0,void 0,void 0,B.props)}function L(B){return typeof B=="object"&&B!==null&&B.$$typeof===n}function J(B){var G={"=":"=0",":":"=2"};return"$"+B.replace(/[=:]/g,function(tt){return G[tt]})}var rt=/\/+/g;function dt(B,G){return typeof B=="object"&&B!==null&&B.key!=null?J(""+B.key):G.toString(36)}function vt(){}function mt(B){switch(B.status){case"fulfilled":return B.value;case"rejected":throw B.reason;default:switch(typeof B.status=="string"?B.then(vt,vt):(B.status="pending",B.then(function(G){B.status==="pending"&&(B.status="fulfilled",B.value=G)},function(G){B.status==="pending"&&(B.status="rejected",B.reason=G)})),B.status){case"fulfilled":return B.value;case"rejected":throw B.reason}}throw B}function ut(B,G,tt,et,at){var Nt=typeof B;(Nt==="undefined"||Nt==="boolean")&&(B=null);var ot=!1;if(B===null)ot=!0;else switch(Nt){case"bigint":case"string":case"number":ot=!0;break;case"object":switch(B.$$typeof){case n:case t:ot=!0;break;case y:return ot=B._init,ut(ot(B._payload),G,tt,et,at)}}if(ot)return at=at(B),ot=et===""?"."+dt(B,0):et,M(at)?(tt="",ot!=null&&(tt=ot.replace(rt,"$&/")+"/"),ut(at,G,tt,"",function(Xe){return Xe})):at!=null&&(L(at)&&(at=z(at,tt+(at.key==null||B&&B.key===at.key?"":(""+at.key).replace(rt,"$&/")+"/")+ot)),G.push(at)),1;ot=0;var Se=et===""?".":et+":";if(M(B))for(var Vt=0;Vt<B.length;Vt++)et=B[Vt],Nt=Se+dt(et,Vt),ot+=ut(et,G,tt,Nt,at);else if(Vt=_(B),typeof Vt=="function")for(B=Vt.call(B),Vt=0;!(et=B.next()).done;)et=et.value,Nt=Se+dt(et,Vt++),ot+=ut(et,G,tt,Nt,at);else if(Nt==="object"){if(typeof B.then=="function")return ut(mt(B),G,tt,et,at);throw G=String(B),Error("Objects are not valid as a React child (found: "+(G==="[object Object]"?"object with keys {"+Object.keys(B).join(", ")+"}":G)+"). If you meant to render a collection of children, use an array instead.")}return ot}function H(B,G,tt){if(B==null)return B;var et=[],at=0;return ut(B,et,"","",function(Nt){return G.call(tt,Nt,at++)}),et}function Q(B){if(B._status===-1){var G=B._result;G=G(),G.then(function(tt){(B._status===0||B._status===-1)&&(B._status=1,B._result=tt)},function(tt){(B._status===0||B._status===-1)&&(B._status=2,B._result=tt)}),B._status===-1&&(B._status=0,B._result=G)}if(B._status===1)return B._result.default;throw B._result}var it=typeof reportError=="function"?reportError:function(B){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var G=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof B=="object"&&B!==null&&typeof B.message=="string"?String(B.message):String(B),error:B});if(!window.dispatchEvent(G))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",B);return}console.error(B)};function _t(){}return Rt.Children={map:H,forEach:function(B,G,tt){H(B,function(){G.apply(this,arguments)},tt)},count:function(B){var G=0;return H(B,function(){G++}),G},toArray:function(B){return H(B,function(G){return G})||[]},only:function(B){if(!L(B))throw Error("React.Children.only expected to receive a single React element child.");return B}},Rt.Component=x,Rt.Fragment=e,Rt.Profiler=l,Rt.PureComponent=w,Rt.StrictMode=s,Rt.Suspense=h,Rt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=O,Rt.__COMPILER_RUNTIME={__proto__:null,c:function(B){return O.H.useMemoCache(B)}},Rt.cache=function(B){return function(){return B.apply(null,arguments)}},Rt.cloneElement=function(B,G,tt){if(B==null)throw Error("The argument must be a React element, but you passed "+B+".");var et=v({},B.props),at=B.key,Nt=void 0;if(G!=null)for(ot in G.ref!==void 0&&(Nt=void 0),G.key!==void 0&&(at=""+G.key),G)!D.call(G,ot)||ot==="key"||ot==="__self"||ot==="__source"||ot==="ref"&&G.ref===void 0||(et[ot]=G[ot]);var ot=arguments.length-2;if(ot===1)et.children=tt;else if(1<ot){for(var Se=Array(ot),Vt=0;Vt<ot;Vt++)Se[Vt]=arguments[Vt+2];et.children=Se}return I(B.type,at,void 0,void 0,Nt,et)},Rt.createContext=function(B){return B={$$typeof:c,_currentValue:B,_currentValue2:B,_threadCount:0,Provider:null,Consumer:null},B.Provider=B,B.Consumer={$$typeof:o,_context:B},B},Rt.createElement=function(B,G,tt){var et,at={},Nt=null;if(G!=null)for(et in G.key!==void 0&&(Nt=""+G.key),G)D.call(G,et)&&et!=="key"&&et!=="__self"&&et!=="__source"&&(at[et]=G[et]);var ot=arguments.length-2;if(ot===1)at.children=tt;else if(1<ot){for(var Se=Array(ot),Vt=0;Vt<ot;Vt++)Se[Vt]=arguments[Vt+2];at.children=Se}if(B&&B.defaultProps)for(et in ot=B.defaultProps,ot)at[et]===void 0&&(at[et]=ot[et]);return I(B,Nt,void 0,void 0,null,at)},Rt.createRef=function(){return{current:null}},Rt.forwardRef=function(B){return{$$typeof:f,render:B}},Rt.isValidElement=L,Rt.lazy=function(B){return{$$typeof:y,_payload:{_status:-1,_result:B},_init:Q}},Rt.memo=function(B,G){return{$$typeof:p,type:B,compare:G===void 0?null:G}},Rt.startTransition=function(B){var G=O.T,tt={};O.T=tt;try{var et=B(),at=O.S;at!==null&&at(tt,et),typeof et=="object"&&et!==null&&typeof et.then=="function"&&et.then(_t,it)}catch(Nt){it(Nt)}finally{O.T=G}},Rt.unstable_useCacheRefresh=function(){return O.H.useCacheRefresh()},Rt.use=function(B){return O.H.use(B)},Rt.useActionState=function(B,G,tt){return O.H.useActionState(B,G,tt)},Rt.useCallback=function(B,G){return O.H.useCallback(B,G)},Rt.useContext=function(B){return O.H.useContext(B)},Rt.useDebugValue=function(){},Rt.useDeferredValue=function(B,G){return O.H.useDeferredValue(B,G)},Rt.useEffect=function(B,G,tt){var et=O.H;if(typeof tt=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return et.useEffect(B,G)},Rt.useId=function(){return O.H.useId()},Rt.useImperativeHandle=function(B,G,tt){return O.H.useImperativeHandle(B,G,tt)},Rt.useInsertionEffect=function(B,G){return O.H.useInsertionEffect(B,G)},Rt.useLayoutEffect=function(B,G){return O.H.useLayoutEffect(B,G)},Rt.useMemo=function(B,G){return O.H.useMemo(B,G)},Rt.useOptimistic=function(B,G){return O.H.useOptimistic(B,G)},Rt.useReducer=function(B,G,tt){return O.H.useReducer(B,G,tt)},Rt.useRef=function(B){return O.H.useRef(B)},Rt.useState=function(B){return O.H.useState(B)},Rt.useSyncExternalStore=function(B,G,tt){return O.H.useSyncExternalStore(B,G,tt)},Rt.useTransition=function(){return O.H.useTransition()},Rt.version="19.1.0",Rt}var iS;function $y(){return iS||(iS=1,dp.exports=CN()),dp.exports}var ft=$y();const Zs=zy(ft);var hp={exports:{}},eu={},gp={exports:{}},pp={};/**
 * @license React
 * scheduler.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var rS;function DN(){return rS||(rS=1,function(n){function t(H,Q){var it=H.length;H.push(Q);t:for(;0<it;){var _t=it-1>>>1,B=H[_t];if(0<l(B,Q))H[_t]=Q,H[it]=B,it=_t;else break t}}function e(H){return H.length===0?null:H[0]}function s(H){if(H.length===0)return null;var Q=H[0],it=H.pop();if(it!==Q){H[0]=it;t:for(var _t=0,B=H.length,G=B>>>1;_t<G;){var tt=2*(_t+1)-1,et=H[tt],at=tt+1,Nt=H[at];if(0>l(et,it))at<B&&0>l(Nt,et)?(H[_t]=Nt,H[at]=it,_t=at):(H[_t]=et,H[tt]=it,_t=tt);else if(at<B&&0>l(Nt,it))H[_t]=Nt,H[at]=it,_t=at;else break t}}return Q}function l(H,Q){var it=H.sortIndex-Q.sortIndex;return it!==0?it:H.id-Q.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;n.unstable_now=function(){return o.now()}}else{var c=Date,f=c.now();n.unstable_now=function(){return c.now()-f}}var h=[],p=[],y=1,m=null,_=3,S=!1,v=!1,A=!1,x=!1,C=typeof setTimeout=="function"?setTimeout:null,w=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;function M(H){for(var Q=e(p);Q!==null;){if(Q.callback===null)s(p);else if(Q.startTime<=H)s(p),Q.sortIndex=Q.expirationTime,t(h,Q);else break;Q=e(p)}}function O(H){if(A=!1,M(H),!v)if(e(h)!==null)v=!0,D||(D=!0,dt());else{var Q=e(p);Q!==null&&ut(O,Q.startTime-H)}}var D=!1,I=-1,z=5,L=-1;function J(){return x?!0:!(n.unstable_now()-L<z)}function rt(){if(x=!1,D){var H=n.unstable_now();L=H;var Q=!0;try{t:{v=!1,A&&(A=!1,w(I),I=-1),S=!0;var it=_;try{e:{for(M(H),m=e(h);m!==null&&!(m.expirationTime>H&&J());){var _t=m.callback;if(typeof _t=="function"){m.callback=null,_=m.priorityLevel;var B=_t(m.expirationTime<=H);if(H=n.unstable_now(),typeof B=="function"){m.callback=B,M(H),Q=!0;break e}m===e(h)&&s(h),M(H)}else s(h);m=e(h)}if(m!==null)Q=!0;else{var G=e(p);G!==null&&ut(O,G.startTime-H),Q=!1}}break t}finally{m=null,_=it,S=!1}Q=void 0}}finally{Q?dt():D=!1}}}var dt;if(typeof E=="function")dt=function(){E(rt)};else if(typeof MessageChannel<"u"){var vt=new MessageChannel,mt=vt.port2;vt.port1.onmessage=rt,dt=function(){mt.postMessage(null)}}else dt=function(){C(rt,0)};function ut(H,Q){I=C(function(){H(n.unstable_now())},Q)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(H){H.callback=null},n.unstable_forceFrameRate=function(H){0>H||125<H?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):z=0<H?Math.floor(1e3/H):5},n.unstable_getCurrentPriorityLevel=function(){return _},n.unstable_next=function(H){switch(_){case 1:case 2:case 3:var Q=3;break;default:Q=_}var it=_;_=Q;try{return H()}finally{_=it}},n.unstable_requestPaint=function(){x=!0},n.unstable_runWithPriority=function(H,Q){switch(H){case 1:case 2:case 3:case 4:case 5:break;default:H=3}var it=_;_=H;try{return Q()}finally{_=it}},n.unstable_scheduleCallback=function(H,Q,it){var _t=n.unstable_now();switch(typeof it=="object"&&it!==null?(it=it.delay,it=typeof it=="number"&&0<it?_t+it:_t):it=_t,H){case 1:var B=-1;break;case 2:B=250;break;case 5:B=1073741823;break;case 4:B=1e4;break;default:B=5e3}return B=it+B,H={id:y++,callback:Q,priorityLevel:H,startTime:it,expirationTime:B,sortIndex:-1},it>_t?(H.sortIndex=it,t(p,H),e(h)===null&&H===e(p)&&(A?(w(I),I=-1):A=!0,ut(O,it-_t))):(H.sortIndex=B,t(h,H),v||S||(v=!0,D||(D=!0,dt()))),H},n.unstable_shouldYield=J,n.unstable_wrapCallback=function(H){var Q=_;return function(){var it=_;_=Q;try{return H.apply(this,arguments)}finally{_=it}}}}(pp)),pp}var sS;function MN(){return sS||(sS=1,gp.exports=DN()),gp.exports}var yp={exports:{}},We={};/**
 * @license React
 * react-dom.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var aS;function BN(){if(aS)return We;aS=1;var n=$y();function t(h){var p="https://react.dev/errors/"+h;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var y=2;y<arguments.length;y++)p+="&args[]="+encodeURIComponent(arguments[y])}return"Minified React error #"+h+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function e(){}var s={d:{f:e,r:function(){throw Error(t(522))},D:e,C:e,L:e,m:e,X:e,S:e,M:e},p:0,findDOMNode:null},l=Symbol.for("react.portal");function o(h,p,y){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:l,key:m==null?null:""+m,children:h,containerInfo:p,implementation:y}}var c=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(h,p){if(h==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return We.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,We.createPortal=function(h,p){var y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(t(299));return o(h,p,null,y)},We.flushSync=function(h){var p=c.T,y=s.p;try{if(c.T=null,s.p=2,h)return h()}finally{c.T=p,s.p=y,s.d.f()}},We.preconnect=function(h,p){typeof h=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,s.d.C(h,p))},We.prefetchDNS=function(h){typeof h=="string"&&s.d.D(h)},We.preinit=function(h,p){if(typeof h=="string"&&p&&typeof p.as=="string"){var y=p.as,m=f(y,p.crossOrigin),_=typeof p.integrity=="string"?p.integrity:void 0,S=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;y==="style"?s.d.S(h,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:m,integrity:_,fetchPriority:S}):y==="script"&&s.d.X(h,{crossOrigin:m,integrity:_,fetchPriority:S,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},We.preinitModule=function(h,p){if(typeof h=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var y=f(p.as,p.crossOrigin);s.d.M(h,{crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&s.d.M(h)},We.preload=function(h,p){if(typeof h=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var y=p.as,m=f(y,p.crossOrigin);s.d.L(h,y,{crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},We.preloadModule=function(h,p){if(typeof h=="string")if(p){var y=f(p.as,p.crossOrigin);s.d.m(h,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else s.d.m(h)},We.requestFormReset=function(h){s.d.r(h)},We.unstable_batchedUpdates=function(h,p){return h(p)},We.useFormState=function(h,p,y){return c.H.useFormState(h,p,y)},We.useFormStatus=function(){return c.H.useHostTransitionStatus()},We.version="19.1.0",We}var lS;function TT(){if(lS)return yp.exports;lS=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(t){console.error(t)}}return n(),yp.exports=BN(),yp.exports}/**
 * @license React
 * react-dom-client.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var oS;function RN(){if(oS)return eu;oS=1;var n=MN(),t=$y(),e=TT();function s(i){var r="https://react.dev/errors/"+i;if(1<arguments.length){r+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)r+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+i+"; visit "+r+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function l(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function o(i){var r=i,a=i;if(i.alternate)for(;r.return;)r=r.return;else{i=r;do r=i,(r.flags&4098)!==0&&(a=r.return),i=r.return;while(i)}return r.tag===3?a:null}function c(i){if(i.tag===13){var r=i.memoizedState;if(r===null&&(i=i.alternate,i!==null&&(r=i.memoizedState)),r!==null)return r.dehydrated}return null}function f(i){if(o(i)!==i)throw Error(s(188))}function h(i){var r=i.alternate;if(!r){if(r=o(i),r===null)throw Error(s(188));return r!==i?null:i}for(var a=i,u=r;;){var d=a.return;if(d===null)break;var g=d.alternate;if(g===null){if(u=d.return,u!==null){a=u;continue}break}if(d.child===g.child){for(g=d.child;g;){if(g===a)return f(d),i;if(g===u)return f(d),r;g=g.sibling}throw Error(s(188))}if(a.return!==u.return)a=d,u=g;else{for(var b=!1,T=d.child;T;){if(T===a){b=!0,a=d,u=g;break}if(T===u){b=!0,u=d,a=g;break}T=T.sibling}if(!b){for(T=g.child;T;){if(T===a){b=!0,a=g,u=d;break}if(T===u){b=!0,u=g,a=d;break}T=T.sibling}if(!b)throw Error(s(189))}}if(a.alternate!==u)throw Error(s(190))}if(a.tag!==3)throw Error(s(188));return a.stateNode.current===a?i:r}function p(i){var r=i.tag;if(r===5||r===26||r===27||r===6)return i;for(i=i.child;i!==null;){if(r=p(i),r!==null)return r;i=i.sibling}return null}var y=Object.assign,m=Symbol.for("react.element"),_=Symbol.for("react.transitional.element"),S=Symbol.for("react.portal"),v=Symbol.for("react.fragment"),A=Symbol.for("react.strict_mode"),x=Symbol.for("react.profiler"),C=Symbol.for("react.provider"),w=Symbol.for("react.consumer"),E=Symbol.for("react.context"),M=Symbol.for("react.forward_ref"),O=Symbol.for("react.suspense"),D=Symbol.for("react.suspense_list"),I=Symbol.for("react.memo"),z=Symbol.for("react.lazy"),L=Symbol.for("react.activity"),J=Symbol.for("react.memo_cache_sentinel"),rt=Symbol.iterator;function dt(i){return i===null||typeof i!="object"?null:(i=rt&&i[rt]||i["@@iterator"],typeof i=="function"?i:null)}var vt=Symbol.for("react.client.reference");function mt(i){if(i==null)return null;if(typeof i=="function")return i.$$typeof===vt?null:i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case v:return"Fragment";case x:return"Profiler";case A:return"StrictMode";case O:return"Suspense";case D:return"SuspenseList";case L:return"Activity"}if(typeof i=="object")switch(i.$$typeof){case S:return"Portal";case E:return(i.displayName||"Context")+".Provider";case w:return(i._context.displayName||"Context")+".Consumer";case M:var r=i.render;return i=i.displayName,i||(i=r.displayName||r.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case I:return r=i.displayName||null,r!==null?r:mt(i.type)||"Memo";case z:r=i._payload,i=i._init;try{return mt(i(r))}catch{}}return null}var ut=Array.isArray,H=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Q=e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,it={pending:!1,data:null,method:null,action:null},_t=[],B=-1;function G(i){return{current:i}}function tt(i){0>B||(i.current=_t[B],_t[B]=null,B--)}function et(i,r){B++,_t[B]=i.current,i.current=r}var at=G(null),Nt=G(null),ot=G(null),Se=G(null);function Vt(i,r){switch(et(ot,r),et(Nt,i),et(at,null),r.nodeType){case 9:case 11:i=(i=r.documentElement)&&(i=i.namespaceURI)?Ov(i):0;break;default:if(i=r.tagName,r=r.namespaceURI)r=Ov(r),i=Nv(r,i);else switch(i){case"svg":i=1;break;case"math":i=2;break;default:i=0}}tt(at),et(at,i)}function Xe(){tt(at),tt(Nt),tt(ot)}function Ti(i){i.memoizedState!==null&&et(Se,i);var r=at.current,a=Nv(r,i.type);r!==a&&(et(Nt,i),et(at,a))}function Zi(i){Nt.current===i&&(tt(at),tt(Nt)),Se.current===i&&(tt(Se),Zo._currentValue=it)}var eo=Object.prototype.hasOwnProperty,Es=n.unstable_scheduleCallback,Wd=n.unstable_cancelCallback,iE=n.unstable_shouldYield,rE=n.unstable_requestPaint,wi=n.unstable_now,sE=n.unstable_getCurrentPriorityLevel,l_=n.unstable_ImmediatePriority,o_=n.unstable_UserBlockingPriority,Gu=n.unstable_NormalPriority,aE=n.unstable_LowPriority,u_=n.unstable_IdlePriority,lE=n.log,oE=n.unstable_setDisableYieldValue,no=null,An=null;function Rr(i){if(typeof lE=="function"&&oE(i),An&&typeof An.setStrictMode=="function")try{An.setStrictMode(no,i)}catch{}}var En=Math.clz32?Math.clz32:fE,uE=Math.log,cE=Math.LN2;function fE(i){return i>>>=0,i===0?32:31-(uE(i)/cE|0)|0}var Zu=256,Xu=4194304;function Os(i){var r=i&42;if(r!==0)return r;switch(i&-i){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:case 262144:case 524288:case 1048576:case 2097152:return i&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return i&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return i}}function Qu(i,r,a){var u=i.pendingLanes;if(u===0)return 0;var d=0,g=i.suspendedLanes,b=i.pingedLanes;i=i.warmLanes;var T=u&134217727;return T!==0?(u=T&~g,u!==0?d=Os(u):(b&=T,b!==0?d=Os(b):a||(a=T&~i,a!==0&&(d=Os(a))))):(T=u&~g,T!==0?d=Os(T):b!==0?d=Os(b):a||(a=u&~i,a!==0&&(d=Os(a)))),d===0?0:r!==0&&r!==d&&(r&g)===0&&(g=d&-d,a=r&-r,g>=a||g===32&&(a&4194048)!==0)?r:d}function io(i,r){return(i.pendingLanes&~(i.suspendedLanes&~i.pingedLanes)&r)===0}function dE(i,r){switch(i){case 1:case 2:case 4:case 8:case 64:return r+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 r+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 c_(){var i=Zu;return Zu<<=1,(Zu&4194048)===0&&(Zu=256),i}function f_(){var i=Xu;return Xu<<=1,(Xu&62914560)===0&&(Xu=4194304),i}function th(i){for(var r=[],a=0;31>a;a++)r.push(i);return r}function ro(i,r){i.pendingLanes|=r,r!==268435456&&(i.suspendedLanes=0,i.pingedLanes=0,i.warmLanes=0)}function hE(i,r,a,u,d,g){var b=i.pendingLanes;i.pendingLanes=a,i.suspendedLanes=0,i.pingedLanes=0,i.warmLanes=0,i.expiredLanes&=a,i.entangledLanes&=a,i.errorRecoveryDisabledLanes&=a,i.shellSuspendCounter=0;var T=i.entanglements,N=i.expirationTimes,$=i.hiddenUpdates;for(a=b&~a;0<a;){var q=31-En(a),P=1<<q;T[q]=0,N[q]=-1;var j=$[q];if(j!==null)for($[q]=null,q=0;q<j.length;q++){var V=j[q];V!==null&&(V.lane&=-536870913)}a&=~P}u!==0&&d_(i,u,0),g!==0&&d===0&&i.tag!==0&&(i.suspendedLanes|=g&~(b&~r))}function d_(i,r,a){i.pendingLanes|=r,i.suspendedLanes&=~r;var u=31-En(r);i.entangledLanes|=r,i.entanglements[u]=i.entanglements[u]|1073741824|a&4194090}function h_(i,r){var a=i.entangledLanes|=r;for(i=i.entanglements;a;){var u=31-En(a),d=1<<u;d&r|i[u]&r&&(i[u]|=r),a&=~d}}function eh(i){switch(i){case 2:i=1;break;case 8:i=4;break;case 32:i=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:i=128;break;case 268435456:i=134217728;break;default:i=0}return i}function nh(i){return i&=-i,2<i?8<i?(i&134217727)!==0?32:268435456:8:2}function g_(){var i=Q.p;return i!==0?i:(i=window.event,i===void 0?32:Pv(i.type))}function gE(i,r){var a=Q.p;try{return Q.p=i,r()}finally{Q.p=a}}var Fr=Math.random().toString(36).slice(2),Qe="__reactFiber$"+Fr,cn="__reactProps$"+Fr,xa="__reactContainer$"+Fr,ih="__reactEvents$"+Fr,pE="__reactListeners$"+Fr,yE="__reactHandles$"+Fr,p_="__reactResources$"+Fr,so="__reactMarker$"+Fr;function rh(i){delete i[Qe],delete i[cn],delete i[ih],delete i[pE],delete i[yE]}function Aa(i){var r=i[Qe];if(r)return r;for(var a=i.parentNode;a;){if(r=a[xa]||a[Qe]){if(a=r.alternate,r.child!==null||a!==null&&a.child!==null)for(i=Bv(i);i!==null;){if(a=i[Qe])return a;i=Bv(i)}return r}i=a,a=i.parentNode}return null}function Ea(i){if(i=i[Qe]||i[xa]){var r=i.tag;if(r===5||r===6||r===13||r===26||r===27||r===3)return i}return null}function ao(i){var r=i.tag;if(r===5||r===26||r===27||r===6)return i.stateNode;throw Error(s(33))}function Oa(i){var r=i[p_];return r||(r=i[p_]={hoistableStyles:new Map,hoistableScripts:new Map}),r}function ke(i){i[so]=!0}var y_=new Set,m_={};function Ns(i,r){Na(i,r),Na(i+"Capture",r)}function Na(i,r){for(m_[i]=r,i=0;i<r.length;i++)y_.add(r[i])}var mE=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]*$"),__={},b_={};function _E(i){return eo.call(b_,i)?!0:eo.call(__,i)?!1:mE.test(i)?b_[i]=!0:(__[i]=!0,!1)}function Ju(i,r,a){if(_E(r))if(a===null)i.removeAttribute(r);else{switch(typeof a){case"undefined":case"function":case"symbol":i.removeAttribute(r);return;case"boolean":var u=r.toLowerCase().slice(0,5);if(u!=="data-"&&u!=="aria-"){i.removeAttribute(r);return}}i.setAttribute(r,""+a)}}function Wu(i,r,a){if(a===null)i.removeAttribute(r);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":i.removeAttribute(r);return}i.setAttribute(r,""+a)}}function Xi(i,r,a,u){if(u===null)i.removeAttribute(a);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":i.removeAttribute(a);return}i.setAttributeNS(r,a,""+u)}}var sh,v_;function Ca(i){if(sh===void 0)try{throw Error()}catch(a){var r=a.stack.trim().match(/\n( *(at )?)/);sh=r&&r[1]||"",v_=-1<a.stack.indexOf(`
    at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
`+sh+i+v_}var ah=!1;function lh(i,r){if(!i||ah)return"";ah=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var u={DetermineComponentFrameRoot:function(){try{if(r){var P=function(){throw Error()};if(Object.defineProperty(P.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(P,[])}catch(V){var j=V}Reflect.construct(i,[],P)}else{try{P.call()}catch(V){j=V}i.call(P.prototype)}}else{try{throw Error()}catch(V){j=V}(P=i())&&typeof P.catch=="function"&&P.catch(function(){})}}catch(V){if(V&&j&&typeof V.stack=="string")return[V.stack,j.stack]}return[null,null]}};u.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var d=Object.getOwnPropertyDescriptor(u.DetermineComponentFrameRoot,"name");d&&d.configurable&&Object.defineProperty(u.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=u.DetermineComponentFrameRoot(),b=g[0],T=g[1];if(b&&T){var N=b.split(`
`),$=T.split(`
`);for(d=u=0;u<N.length&&!N[u].includes("DetermineComponentFrameRoot");)u++;for(;d<$.length&&!$[d].includes("DetermineComponentFrameRoot");)d++;if(u===N.length||d===$.length)for(u=N.length-1,d=$.length-1;1<=u&&0<=d&&N[u]!==$[d];)d--;for(;1<=u&&0<=d;u--,d--)if(N[u]!==$[d]){if(u!==1||d!==1)do if(u--,d--,0>d||N[u]!==$[d]){var q=`
`+N[u].replace(" at new "," at ");return i.displayName&&q.includes("<anonymous>")&&(q=q.replace("<anonymous>",i.displayName)),q}while(1<=u&&0<=d);break}}}finally{ah=!1,Error.prepareStackTrace=a}return(a=i?i.displayName||i.name:"")?Ca(a):""}function bE(i){switch(i.tag){case 26:case 27:case 5:return Ca(i.type);case 16:return Ca("Lazy");case 13:return Ca("Suspense");case 19:return Ca("SuspenseList");case 0:case 15:return lh(i.type,!1);case 11:return lh(i.type.render,!1);case 1:return lh(i.type,!0);case 31:return Ca("Activity");default:return""}}function S_(i){try{var r="";do r+=bE(i),i=i.return;while(i);return r}catch(a){return`
Error generating stack: `+a.message+`
`+a.stack}}function Yn(i){switch(typeof i){case"bigint":case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function T_(i){var r=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function vE(i){var r=T_(i)?"checked":"value",a=Object.getOwnPropertyDescriptor(i.constructor.prototype,r),u=""+i[r];if(!i.hasOwnProperty(r)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var d=a.get,g=a.set;return Object.defineProperty(i,r,{configurable:!0,get:function(){return d.call(this)},set:function(b){u=""+b,g.call(this,b)}}),Object.defineProperty(i,r,{enumerable:a.enumerable}),{getValue:function(){return u},setValue:function(b){u=""+b},stopTracking:function(){i._valueTracker=null,delete i[r]}}}}function tc(i){i._valueTracker||(i._valueTracker=vE(i))}function w_(i){if(!i)return!1;var r=i._valueTracker;if(!r)return!0;var a=r.getValue(),u="";return i&&(u=T_(i)?i.checked?"true":"false":i.value),i=u,i!==a?(r.setValue(i),!0):!1}function ec(i){if(i=i||(typeof document<"u"?document:void 0),typeof i>"u")return null;try{return i.activeElement||i.body}catch{return i.body}}var SE=/[\n"\\]/g;function qn(i){return i.replace(SE,function(r){return"\\"+r.charCodeAt(0).toString(16)+" "})}function oh(i,r,a,u,d,g,b,T){i.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?i.type=b:i.removeAttribute("type"),r!=null?b==="number"?(r===0&&i.value===""||i.value!=r)&&(i.value=""+Yn(r)):i.value!==""+Yn(r)&&(i.value=""+Yn(r)):b!=="submit"&&b!=="reset"||i.removeAttribute("value"),r!=null?uh(i,b,Yn(r)):a!=null?uh(i,b,Yn(a)):u!=null&&i.removeAttribute("value"),d==null&&g!=null&&(i.defaultChecked=!!g),d!=null&&(i.checked=d&&typeof d!="function"&&typeof d!="symbol"),T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"?i.name=""+Yn(T):i.removeAttribute("name")}function x_(i,r,a,u,d,g,b,T){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(i.type=g),r!=null||a!=null){if(!(g!=="submit"&&g!=="reset"||r!=null))return;a=a!=null?""+Yn(a):"",r=r!=null?""+Yn(r):a,T||r===i.value||(i.value=r),i.defaultValue=r}u=u??d,u=typeof u!="function"&&typeof u!="symbol"&&!!u,i.checked=T?i.checked:!!u,i.defaultChecked=!!u,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(i.name=b)}function uh(i,r,a){r==="number"&&ec(i.ownerDocument)===i||i.defaultValue===""+a||(i.defaultValue=""+a)}function Da(i,r,a,u){if(i=i.options,r){r={};for(var d=0;d<a.length;d++)r["$"+a[d]]=!0;for(a=0;a<i.length;a++)d=r.hasOwnProperty("$"+i[a].value),i[a].selected!==d&&(i[a].selected=d),d&&u&&(i[a].defaultSelected=!0)}else{for(a=""+Yn(a),r=null,d=0;d<i.length;d++){if(i[d].value===a){i[d].selected=!0,u&&(i[d].defaultSelected=!0);return}r!==null||i[d].disabled||(r=i[d])}r!==null&&(r.selected=!0)}}function A_(i,r,a){if(r!=null&&(r=""+Yn(r),r!==i.value&&(i.value=r),a==null)){i.defaultValue!==r&&(i.defaultValue=r);return}i.defaultValue=a!=null?""+Yn(a):""}function E_(i,r,a,u){if(r==null){if(u!=null){if(a!=null)throw Error(s(92));if(ut(u)){if(1<u.length)throw Error(s(93));u=u[0]}a=u}a==null&&(a=""),r=a}a=Yn(r),i.defaultValue=a,u=i.textContent,u===a&&u!==""&&u!==null&&(i.value=u)}function Ma(i,r){if(r){var a=i.firstChild;if(a&&a===i.lastChild&&a.nodeType===3){a.nodeValue=r;return}}i.textContent=r}var TE=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 O_(i,r,a){var u=r.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?u?i.setProperty(r,""):r==="float"?i.cssFloat="":i[r]="":u?i.setProperty(r,a):typeof a!="number"||a===0||TE.has(r)?r==="float"?i.cssFloat=a:i[r]=(""+a).trim():i[r]=a+"px"}function N_(i,r,a){if(r!=null&&typeof r!="object")throw Error(s(62));if(i=i.style,a!=null){for(var u in a)!a.hasOwnProperty(u)||r!=null&&r.hasOwnProperty(u)||(u.indexOf("--")===0?i.setProperty(u,""):u==="float"?i.cssFloat="":i[u]="");for(var d in r)u=r[d],r.hasOwnProperty(d)&&a[d]!==u&&O_(i,d,u)}else for(var g in r)r.hasOwnProperty(g)&&O_(i,g,r[g])}function ch(i){if(i.indexOf("-")===-1)return!1;switch(i){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 wE=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"],["colorRendering","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"]]),xE=/^[\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 nc(i){return xE.test(""+i)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":i}var fh=null;function dh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Ba=null,Ra=null;function C_(i){var r=Ea(i);if(r&&(i=r.stateNode)){var a=i[cn]||null;t:switch(i=r.stateNode,r.type){case"input":if(oh(i,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),r=a.name,a.type==="radio"&&r!=null){for(a=i;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+qn(""+r)+'"][type="radio"]'),r=0;r<a.length;r++){var u=a[r];if(u!==i&&u.form===i.form){var d=u[cn]||null;if(!d)throw Error(s(90));oh(u,d.value,d.defaultValue,d.defaultValue,d.checked,d.defaultChecked,d.type,d.name)}}for(r=0;r<a.length;r++)u=a[r],u.form===i.form&&w_(u)}break t;case"textarea":A_(i,a.value,a.defaultValue);break t;case"select":r=a.value,r!=null&&Da(i,!!a.multiple,r,!1)}}}var hh=!1;function D_(i,r,a){if(hh)return i(r,a);hh=!0;try{var u=i(r);return u}finally{if(hh=!1,(Ba!==null||Ra!==null)&&(jc(),Ba&&(r=Ba,i=Ra,Ra=Ba=null,C_(r),i)))for(r=0;r<i.length;r++)C_(i[r])}}function lo(i,r){var a=i.stateNode;if(a===null)return null;var u=a[cn]||null;if(u===null)return null;a=u[r];t:switch(r){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(u=!u.disabled)||(i=i.type,u=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!u;break t;default:i=!1}if(i)return null;if(a&&typeof a!="function")throw Error(s(231,r,typeof a));return a}var Qi=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),gh=!1;if(Qi)try{var oo={};Object.defineProperty(oo,"passive",{get:function(){gh=!0}}),window.addEventListener("test",oo,oo),window.removeEventListener("test",oo,oo)}catch{gh=!1}var Lr=null,ph=null,ic=null;function M_(){if(ic)return ic;var i,r=ph,a=r.length,u,d="value"in Lr?Lr.value:Lr.textContent,g=d.length;for(i=0;i<a&&r[i]===d[i];i++);var b=a-i;for(u=1;u<=b&&r[a-u]===d[g-u];u++);return ic=d.slice(i,1<u?1-u:void 0)}function rc(i){var r=i.keyCode;return"charCode"in i?(i=i.charCode,i===0&&r===13&&(i=13)):i=r,i===10&&(i=13),32<=i||i===13?i:0}function sc(){return!0}function B_(){return!1}function fn(i){function r(a,u,d,g,b){this._reactName=a,this._targetInst=d,this.type=u,this.nativeEvent=g,this.target=b,this.currentTarget=null;for(var T in i)i.hasOwnProperty(T)&&(a=i[T],this[T]=a?a(g):g[T]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?sc:B_,this.isPropagationStopped=B_,this}return y(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=sc)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=sc)},persist:function(){},isPersistent:sc}),r}var Cs={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ac=fn(Cs),uo=y({},Cs,{view:0,detail:0}),AE=fn(uo),yh,mh,co,lc=y({},uo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:bh,button:0,buttons:0,relatedTarget:function(i){return i.relatedTarget===void 0?i.fromElement===i.srcElement?i.toElement:i.fromElement:i.relatedTarget},movementX:function(i){return"movementX"in i?i.movementX:(i!==co&&(co&&i.type==="mousemove"?(yh=i.screenX-co.screenX,mh=i.screenY-co.screenY):mh=yh=0,co=i),yh)},movementY:function(i){return"movementY"in i?i.movementY:mh}}),R_=fn(lc),EE=y({},lc,{dataTransfer:0}),OE=fn(EE),NE=y({},uo,{relatedTarget:0}),_h=fn(NE),CE=y({},Cs,{animationName:0,elapsedTime:0,pseudoElement:0}),DE=fn(CE),ME=y({},Cs,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),BE=fn(ME),RE=y({},Cs,{data:0}),F_=fn(RE),FE={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},LE={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"},IE={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function kE(i){var r=this.nativeEvent;return r.getModifierState?r.getModifierState(i):(i=IE[i])?!!r[i]:!1}function bh(){return kE}var UE=y({},uo,{key:function(i){if(i.key){var r=FE[i.key]||i.key;if(r!=="Unidentified")return r}return i.type==="keypress"?(i=rc(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?LE[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:bh,charCode:function(i){return i.type==="keypress"?rc(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?rc(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),zE=fn(UE),$E=y({},lc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),L_=fn($E),jE=y({},uo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:bh}),VE=fn(jE),HE=y({},Cs,{propertyName:0,elapsedTime:0,pseudoElement:0}),YE=fn(HE),qE=y({},lc,{deltaX:function(i){return"deltaX"in i?i.deltaX:"wheelDeltaX"in i?-i.wheelDeltaX:0},deltaY:function(i){return"deltaY"in i?i.deltaY:"wheelDeltaY"in i?-i.wheelDeltaY:"wheelDelta"in i?-i.wheelDelta:0},deltaZ:0,deltaMode:0}),KE=fn(qE),PE=y({},Cs,{newState:0,oldState:0}),GE=fn(PE),ZE=[9,13,27,32],vh=Qi&&"CompositionEvent"in window,fo=null;Qi&&"documentMode"in document&&(fo=document.documentMode);var XE=Qi&&"TextEvent"in window&&!fo,I_=Qi&&(!vh||fo&&8<fo&&11>=fo),k_=" ",U_=!1;function z_(i,r){switch(i){case"keyup":return ZE.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function $_(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Fa=!1;function QE(i,r){switch(i){case"compositionend":return $_(r);case"keypress":return r.which!==32?null:(U_=!0,k_);case"textInput":return i=r.data,i===k_&&U_?null:i;default:return null}}function JE(i,r){if(Fa)return i==="compositionend"||!vh&&z_(i,r)?(i=M_(),ic=ph=Lr=null,Fa=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1<r.char.length)return r.char;if(r.which)return String.fromCharCode(r.which)}return null;case"compositionend":return I_&&r.locale!=="ko"?null:r.data;default:return null}}var WE={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 j_(i){var r=i&&i.nodeName&&i.nodeName.toLowerCase();return r==="input"?!!WE[i.type]:r==="textarea"}function V_(i,r,a,u){Ba?Ra?Ra.push(u):Ra=[u]:Ba=u,r=Pc(r,"onChange"),0<r.length&&(a=new ac("onChange","change",null,a,u),i.push({event:a,listeners:r}))}var ho=null,go=null;function tO(i){Tv(i,0)}function oc(i){var r=ao(i);if(w_(r))return i}function H_(i,r){if(i==="change")return r}var Y_=!1;if(Qi){var Sh;if(Qi){var Th="oninput"in document;if(!Th){var q_=document.createElement("div");q_.setAttribute("oninput","return;"),Th=typeof q_.oninput=="function"}Sh=Th}else Sh=!1;Y_=Sh&&(!document.documentMode||9<document.documentMode)}function K_(){ho&&(ho.detachEvent("onpropertychange",P_),go=ho=null)}function P_(i){if(i.propertyName==="value"&&oc(go)){var r=[];V_(r,go,i,dh(i)),D_(tO,r)}}function eO(i,r,a){i==="focusin"?(K_(),ho=r,go=a,ho.attachEvent("onpropertychange",P_)):i==="focusout"&&K_()}function nO(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return oc(go)}function iO(i,r){if(i==="click")return oc(r)}function rO(i,r){if(i==="input"||i==="change")return oc(r)}function sO(i,r){return i===r&&(i!==0||1/i===1/r)||i!==i&&r!==r}var On=typeof Object.is=="function"?Object.is:sO;function po(i,r){if(On(i,r))return!0;if(typeof i!="object"||i===null||typeof r!="object"||r===null)return!1;var a=Object.keys(i),u=Object.keys(r);if(a.length!==u.length)return!1;for(u=0;u<a.length;u++){var d=a[u];if(!eo.call(r,d)||!On(i[d],r[d]))return!1}return!0}function G_(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function Z_(i,r){var a=G_(i);i=0;for(var u;a;){if(a.nodeType===3){if(u=i+a.textContent.length,i<=r&&u>=r)return{node:a,offset:r-i};i=u}t:{for(;a;){if(a.nextSibling){a=a.nextSibling;break t}a=a.parentNode}a=void 0}a=G_(a)}}function X_(i,r){return i&&r?i===r?!0:i&&i.nodeType===3?!1:r&&r.nodeType===3?X_(i,r.parentNode):"contains"in i?i.contains(r):i.compareDocumentPosition?!!(i.compareDocumentPosition(r)&16):!1:!1}function Q_(i){i=i!=null&&i.ownerDocument!=null&&i.ownerDocument.defaultView!=null?i.ownerDocument.defaultView:window;for(var r=ec(i.document);r instanceof i.HTMLIFrameElement;){try{var a=typeof r.contentWindow.location.href=="string"}catch{a=!1}if(a)i=r.contentWindow;else break;r=ec(i.document)}return r}function wh(i){var r=i&&i.nodeName&&i.nodeName.toLowerCase();return r&&(r==="input"&&(i.type==="text"||i.type==="search"||i.type==="tel"||i.type==="url"||i.type==="password")||r==="textarea"||i.contentEditable==="true")}var aO=Qi&&"documentMode"in document&&11>=document.documentMode,La=null,xh=null,yo=null,Ah=!1;function J_(i,r,a){var u=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Ah||La==null||La!==ec(u)||(u=La,"selectionStart"in u&&wh(u)?u={start:u.selectionStart,end:u.selectionEnd}:(u=(u.ownerDocument&&u.ownerDocument.defaultView||window).getSelection(),u={anchorNode:u.anchorNode,anchorOffset:u.anchorOffset,focusNode:u.focusNode,focusOffset:u.focusOffset}),yo&&po(yo,u)||(yo=u,u=Pc(xh,"onSelect"),0<u.length&&(r=new ac("onSelect","select",null,r,a),i.push({event:r,listeners:u}),r.target=La)))}function Ds(i,r){var a={};return a[i.toLowerCase()]=r.toLowerCase(),a["Webkit"+i]="webkit"+r,a["Moz"+i]="moz"+r,a}var Ia={animationend:Ds("Animation","AnimationEnd"),animationiteration:Ds("Animation","AnimationIteration"),animationstart:Ds("Animation","AnimationStart"),transitionrun:Ds("Transition","TransitionRun"),transitionstart:Ds("Transition","TransitionStart"),transitioncancel:Ds("Transition","TransitionCancel"),transitionend:Ds("Transition","TransitionEnd")},Eh={},W_={};Qi&&(W_=document.createElement("div").style,"AnimationEvent"in window||(delete Ia.animationend.animation,delete Ia.animationiteration.animation,delete Ia.animationstart.animation),"TransitionEvent"in window||delete Ia.transitionend.transition);function Ms(i){if(Eh[i])return Eh[i];if(!Ia[i])return i;var r=Ia[i],a;for(a in r)if(r.hasOwnProperty(a)&&a in W_)return Eh[i]=r[a];return i}var t0=Ms("animationend"),e0=Ms("animationiteration"),n0=Ms("animationstart"),lO=Ms("transitionrun"),oO=Ms("transitionstart"),uO=Ms("transitioncancel"),i0=Ms("transitionend"),r0=new Map,Oh="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(" ");Oh.push("scrollEnd");function oi(i,r){r0.set(i,r),Ns(r,[i])}var s0=new WeakMap;function Kn(i,r){if(typeof i=="object"&&i!==null){var a=s0.get(i);return a!==void 0?a:(r={value:i,source:r,stack:S_(r)},s0.set(i,r),r)}return{value:i,source:r,stack:S_(r)}}var Pn=[],ka=0,Nh=0;function uc(){for(var i=ka,r=Nh=ka=0;r<i;){var a=Pn[r];Pn[r++]=null;var u=Pn[r];Pn[r++]=null;var d=Pn[r];Pn[r++]=null;var g=Pn[r];if(Pn[r++]=null,u!==null&&d!==null){var b=u.pending;b===null?d.next=d:(d.next=b.next,b.next=d),u.pending=d}g!==0&&a0(a,d,g)}}function cc(i,r,a,u){Pn[ka++]=i,Pn[ka++]=r,Pn[ka++]=a,Pn[ka++]=u,Nh|=u,i.lanes|=u,i=i.alternate,i!==null&&(i.lanes|=u)}function Ch(i,r,a,u){return cc(i,r,a,u),fc(i)}function Ua(i,r){return cc(i,null,null,r),fc(i)}function a0(i,r,a){i.lanes|=a;var u=i.alternate;u!==null&&(u.lanes|=a);for(var d=!1,g=i.return;g!==null;)g.childLanes|=a,u=g.alternate,u!==null&&(u.childLanes|=a),g.tag===22&&(i=g.stateNode,i===null||i._visibility&1||(d=!0)),i=g,g=g.return;return i.tag===3?(g=i.stateNode,d&&r!==null&&(d=31-En(a),i=g.hiddenUpdates,u=i[d],u===null?i[d]=[r]:u.push(r),r.lane=a|536870912),g):null}function fc(i){if(50<jo)throw jo=0,Lg=null,Error(s(185));for(var r=i.return;r!==null;)i=r,r=i.return;return i.tag===3?i.stateNode:null}var za={};function cO(i,r,a,u){this.tag=i,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=u,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Nn(i,r,a,u){return new cO(i,r,a,u)}function Dh(i){return i=i.prototype,!(!i||!i.isReactComponent)}function Ji(i,r){var a=i.alternate;return a===null?(a=Nn(i.tag,r,i.key,i.mode),a.elementType=i.elementType,a.type=i.type,a.stateNode=i.stateNode,a.alternate=i,i.alternate=a):(a.pendingProps=r,a.type=i.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=i.flags&65011712,a.childLanes=i.childLanes,a.lanes=i.lanes,a.child=i.child,a.memoizedProps=i.memoizedProps,a.memoizedState=i.memoizedState,a.updateQueue=i.updateQueue,r=i.dependencies,a.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},a.sibling=i.sibling,a.index=i.index,a.ref=i.ref,a.refCleanup=i.refCleanup,a}function l0(i,r){i.flags&=65011714;var a=i.alternate;return a===null?(i.childLanes=0,i.lanes=r,i.child=null,i.subtreeFlags=0,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=a.childLanes,i.lanes=a.lanes,i.child=a.child,i.subtreeFlags=0,i.deletions=null,i.memoizedProps=a.memoizedProps,i.memoizedState=a.memoizedState,i.updateQueue=a.updateQueue,i.type=a.type,r=a.dependencies,i.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext}),i}function dc(i,r,a,u,d,g){var b=0;if(u=i,typeof i=="function")Dh(i)&&(b=1);else if(typeof i=="string")b=dN(i,a,at.current)?26:i==="html"||i==="head"||i==="body"?27:5;else t:switch(i){case L:return i=Nn(31,a,r,d),i.elementType=L,i.lanes=g,i;case v:return Bs(a.children,d,g,r);case A:b=8,d|=24;break;case x:return i=Nn(12,a,r,d|2),i.elementType=x,i.lanes=g,i;case O:return i=Nn(13,a,r,d),i.elementType=O,i.lanes=g,i;case D:return i=Nn(19,a,r,d),i.elementType=D,i.lanes=g,i;default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case C:case E:b=10;break t;case w:b=9;break t;case M:b=11;break t;case I:b=14;break t;case z:b=16,u=null;break t}b=29,a=Error(s(130,i===null?"null":typeof i,"")),u=null}return r=Nn(b,a,r,d),r.elementType=i,r.type=u,r.lanes=g,r}function Bs(i,r,a,u){return i=Nn(7,i,u,r),i.lanes=a,i}function Mh(i,r,a){return i=Nn(6,i,null,r),i.lanes=a,i}function Bh(i,r,a){return r=Nn(4,i.children!==null?i.children:[],i.key,r),r.lanes=a,r.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},r}var $a=[],ja=0,hc=null,gc=0,Gn=[],Zn=0,Rs=null,Wi=1,tr="";function Fs(i,r){$a[ja++]=gc,$a[ja++]=hc,hc=i,gc=r}function o0(i,r,a){Gn[Zn++]=Wi,Gn[Zn++]=tr,Gn[Zn++]=Rs,Rs=i;var u=Wi;i=tr;var d=32-En(u)-1;u&=~(1<<d),a+=1;var g=32-En(r)+d;if(30<g){var b=d-d%5;g=(u&(1<<b)-1).toString(32),u>>=b,d-=b,Wi=1<<32-En(r)+d|a<<d|u,tr=g+i}else Wi=1<<g|a<<d|u,tr=i}function Rh(i){i.return!==null&&(Fs(i,1),o0(i,1,0))}function Fh(i){for(;i===hc;)hc=$a[--ja],$a[ja]=null,gc=$a[--ja],$a[ja]=null;for(;i===Rs;)Rs=Gn[--Zn],Gn[Zn]=null,tr=Gn[--Zn],Gn[Zn]=null,Wi=Gn[--Zn],Gn[Zn]=null}var nn=null,Te=null,Gt=!1,Ls=null,xi=!1,Lh=Error(s(519));function Is(i){var r=Error(s(418,""));throw bo(Kn(r,i)),Lh}function u0(i){var r=i.stateNode,a=i.type,u=i.memoizedProps;switch(r[Qe]=i,r[cn]=u,a){case"dialog":zt("cancel",r),zt("close",r);break;case"iframe":case"object":case"embed":zt("load",r);break;case"video":case"audio":for(a=0;a<Ho.length;a++)zt(Ho[a],r);break;case"source":zt("error",r);break;case"img":case"image":case"link":zt("error",r),zt("load",r);break;case"details":zt("toggle",r);break;case"input":zt("invalid",r),x_(r,u.value,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name,!0),tc(r);break;case"select":zt("invalid",r);break;case"textarea":zt("invalid",r),E_(r,u.value,u.defaultValue,u.children),tc(r)}a=u.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||r.textContent===""+a||u.suppressHydrationWarning===!0||Ev(r.textContent,a)?(u.popover!=null&&(zt("beforetoggle",r),zt("toggle",r)),u.onScroll!=null&&zt("scroll",r),u.onScrollEnd!=null&&zt("scrollend",r),u.onClick!=null&&(r.onclick=Gc),r=!0):r=!1,r||Is(i)}function c0(i){for(nn=i.return;nn;)switch(nn.tag){case 5:case 13:xi=!1;return;case 27:case 3:xi=!0;return;default:nn=nn.return}}function mo(i){if(i!==nn)return!1;if(!Gt)return c0(i),Gt=!0,!1;var r=i.tag,a;if((a=r!==3&&r!==27)&&((a=r===5)&&(a=i.type,a=!(a!=="form"&&a!=="button")||Qg(i.type,i.memoizedProps)),a=!a),a&&Te&&Is(i),c0(i),r===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(s(317));t:{for(i=i.nextSibling,r=0;i;){if(i.nodeType===8)if(a=i.data,a==="/$"){if(r===0){Te=ci(i.nextSibling);break t}r--}else a!=="$"&&a!=="$!"&&a!=="$?"||r++;i=i.nextSibling}Te=null}}else r===27?(r=Te,Qr(i.type)?(i=ep,ep=null,Te=i):Te=r):Te=nn?ci(i.stateNode.nextSibling):null;return!0}function _o(){Te=nn=null,Gt=!1}function f0(){var i=Ls;return i!==null&&(gn===null?gn=i:gn.push.apply(gn,i),Ls=null),i}function bo(i){Ls===null?Ls=[i]:Ls.push(i)}var Ih=G(null),ks=null,er=null;function Ir(i,r,a){et(Ih,r._currentValue),r._currentValue=a}function nr(i){i._currentValue=Ih.current,tt(Ih)}function kh(i,r,a){for(;i!==null;){var u=i.alternate;if((i.childLanes&r)!==r?(i.childLanes|=r,u!==null&&(u.childLanes|=r)):u!==null&&(u.childLanes&r)!==r&&(u.childLanes|=r),i===a)break;i=i.return}}function Uh(i,r,a,u){var d=i.child;for(d!==null&&(d.return=i);d!==null;){var g=d.dependencies;if(g!==null){var b=d.child;g=g.firstContext;t:for(;g!==null;){var T=g;g=d;for(var N=0;N<r.length;N++)if(T.context===r[N]){g.lanes|=a,T=g.alternate,T!==null&&(T.lanes|=a),kh(g.return,a,i),u||(b=null);break t}g=T.next}}else if(d.tag===18){if(b=d.return,b===null)throw Error(s(341));b.lanes|=a,g=b.alternate,g!==null&&(g.lanes|=a),kh(b,a,i),b=null}else b=d.child;if(b!==null)b.return=d;else for(b=d;b!==null;){if(b===i){b=null;break}if(d=b.sibling,d!==null){d.return=b.return,b=d;break}b=b.return}d=b}}function vo(i,r,a,u){i=null;for(var d=r,g=!1;d!==null;){if(!g){if((d.flags&524288)!==0)g=!0;else if((d.flags&262144)!==0)break}if(d.tag===10){var b=d.alternate;if(b===null)throw Error(s(387));if(b=b.memoizedProps,b!==null){var T=d.type;On(d.pendingProps.value,b.value)||(i!==null?i.push(T):i=[T])}}else if(d===Se.current){if(b=d.alternate,b===null)throw Error(s(387));b.memoizedState.memoizedState!==d.memoizedState.memoizedState&&(i!==null?i.push(Zo):i=[Zo])}d=d.return}i!==null&&Uh(r,i,a,u),r.flags|=262144}function pc(i){for(i=i.firstContext;i!==null;){if(!On(i.context._currentValue,i.memoizedValue))return!0;i=i.next}return!1}function Us(i){ks=i,er=null,i=i.dependencies,i!==null&&(i.firstContext=null)}function Je(i){return d0(ks,i)}function yc(i,r){return ks===null&&Us(i),d0(i,r)}function d0(i,r){var a=r._currentValue;if(r={context:r,memoizedValue:a,next:null},er===null){if(i===null)throw Error(s(308));er=r,i.dependencies={lanes:0,firstContext:r},i.flags|=524288}else er=er.next=r;return a}var fO=typeof AbortController<"u"?AbortController:function(){var i=[],r=this.signal={aborted:!1,addEventListener:function(a,u){i.push(u)}};this.abort=function(){r.aborted=!0,i.forEach(function(a){return a()})}},dO=n.unstable_scheduleCallback,hO=n.unstable_NormalPriority,Be={$$typeof:E,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function zh(){return{controller:new fO,data:new Map,refCount:0}}function So(i){i.refCount--,i.refCount===0&&dO(hO,function(){i.controller.abort()})}var To=null,$h=0,Va=0,Ha=null;function gO(i,r){if(To===null){var a=To=[];$h=0,Va=Vg(),Ha={status:"pending",value:void 0,then:function(u){a.push(u)}}}return $h++,r.then(h0,h0),r}function h0(){if(--$h===0&&To!==null){Ha!==null&&(Ha.status="fulfilled");var i=To;To=null,Va=0,Ha=null;for(var r=0;r<i.length;r++)(0,i[r])()}}function pO(i,r){var a=[],u={status:"pending",value:null,reason:null,then:function(d){a.push(d)}};return i.then(function(){u.status="fulfilled",u.value=r;for(var d=0;d<a.length;d++)(0,a[d])(r)},function(d){for(u.status="rejected",u.reason=d,d=0;d<a.length;d++)(0,a[d])(void 0)}),u}var g0=H.S;H.S=function(i,r){typeof r=="object"&&r!==null&&typeof r.then=="function"&&gO(i,r),g0!==null&&g0(i,r)};var zs=G(null);function jh(){var i=zs.current;return i!==null?i:fe.pooledCache}function mc(i,r){r===null?et(zs,zs.current):et(zs,r.pool)}function p0(){var i=jh();return i===null?null:{parent:Be._currentValue,pool:i}}var wo=Error(s(460)),y0=Error(s(474)),_c=Error(s(542)),Vh={then:function(){}};function m0(i){return i=i.status,i==="fulfilled"||i==="rejected"}function bc(){}function _0(i,r,a){switch(a=i[a],a===void 0?i.push(r):a!==r&&(r.then(bc,bc),r=a),r.status){case"fulfilled":return r.value;case"rejected":throw i=r.reason,v0(i),i;default:if(typeof r.status=="string")r.then(bc,bc);else{if(i=fe,i!==null&&100<i.shellSuspendCounter)throw Error(s(482));i=r,i.status="pending",i.then(function(u){if(r.status==="pending"){var d=r;d.status="fulfilled",d.value=u}},function(u){if(r.status==="pending"){var d=r;d.status="rejected",d.reason=u}})}switch(r.status){case"fulfilled":return r.value;case"rejected":throw i=r.reason,v0(i),i}throw xo=r,wo}}var xo=null;function b0(){if(xo===null)throw Error(s(459));var i=xo;return xo=null,i}function v0(i){if(i===wo||i===_c)throw Error(s(483))}var kr=!1;function Hh(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Yh(i,r){i=i.updateQueue,r.updateQueue===i&&(r.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,callbacks:null})}function Ur(i){return{lane:i,tag:0,payload:null,callback:null,next:null}}function zr(i,r,a){var u=i.updateQueue;if(u===null)return null;if(u=u.shared,(ee&2)!==0){var d=u.pending;return d===null?r.next=r:(r.next=d.next,d.next=r),u.pending=r,r=fc(i),a0(i,null,a),r}return cc(i,u,r,a),fc(i)}function Ao(i,r,a){if(r=r.updateQueue,r!==null&&(r=r.shared,(a&4194048)!==0)){var u=r.lanes;u&=i.pendingLanes,a|=u,r.lanes=a,h_(i,a)}}function qh(i,r){var a=i.updateQueue,u=i.alternate;if(u!==null&&(u=u.updateQueue,a===u)){var d=null,g=null;if(a=a.firstBaseUpdate,a!==null){do{var b={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};g===null?d=g=b:g=g.next=b,a=a.next}while(a!==null);g===null?d=g=r:g=g.next=r}else d=g=r;a={baseState:u.baseState,firstBaseUpdate:d,lastBaseUpdate:g,shared:u.shared,callbacks:u.callbacks},i.updateQueue=a;return}i=a.lastBaseUpdate,i===null?a.firstBaseUpdate=r:i.next=r,a.lastBaseUpdate=r}var Kh=!1;function Eo(){if(Kh){var i=Ha;if(i!==null)throw i}}function Oo(i,r,a,u){Kh=!1;var d=i.updateQueue;kr=!1;var g=d.firstBaseUpdate,b=d.lastBaseUpdate,T=d.shared.pending;if(T!==null){d.shared.pending=null;var N=T,$=N.next;N.next=null,b===null?g=$:b.next=$,b=N;var q=i.alternate;q!==null&&(q=q.updateQueue,T=q.lastBaseUpdate,T!==b&&(T===null?q.firstBaseUpdate=$:T.next=$,q.lastBaseUpdate=N))}if(g!==null){var P=d.baseState;b=0,q=$=N=null,T=g;do{var j=T.lane&-536870913,V=j!==T.lane;if(V?(Ht&j)===j:(u&j)===j){j!==0&&j===Va&&(Kh=!0),q!==null&&(q=q.next={lane:0,tag:T.tag,payload:T.payload,callback:null,next:null});t:{var bt=i,ht=T;j=r;var le=a;switch(ht.tag){case 1:if(bt=ht.payload,typeof bt=="function"){P=bt.call(le,P,j);break t}P=bt;break t;case 3:bt.flags=bt.flags&-65537|128;case 0:if(bt=ht.payload,j=typeof bt=="function"?bt.call(le,P,j):bt,j==null)break t;P=y({},P,j);break t;case 2:kr=!0}}j=T.callback,j!==null&&(i.flags|=64,V&&(i.flags|=8192),V=d.callbacks,V===null?d.callbacks=[j]:V.push(j))}else V={lane:j,tag:T.tag,payload:T.payload,callback:T.callback,next:null},q===null?($=q=V,N=P):q=q.next=V,b|=j;if(T=T.next,T===null){if(T=d.shared.pending,T===null)break;V=T,T=V.next,V.next=null,d.lastBaseUpdate=V,d.shared.pending=null}}while(!0);q===null&&(N=P),d.baseState=N,d.firstBaseUpdate=$,d.lastBaseUpdate=q,g===null&&(d.shared.lanes=0),Pr|=b,i.lanes=b,i.memoizedState=P}}function S0(i,r){if(typeof i!="function")throw Error(s(191,i));i.call(r)}function T0(i,r){var a=i.callbacks;if(a!==null)for(i.callbacks=null,i=0;i<a.length;i++)S0(a[i],r)}var Ya=G(null),vc=G(0);function w0(i,r){i=ur,et(vc,i),et(Ya,r),ur=i|r.baseLanes}function Ph(){et(vc,ur),et(Ya,Ya.current)}function Gh(){ur=vc.current,tt(Ya),tt(vc)}var $r=0,It=null,se=null,Oe=null,Sc=!1,qa=!1,$s=!1,Tc=0,No=0,Ka=null,yO=0;function xe(){throw Error(s(321))}function Zh(i,r){if(r===null)return!1;for(var a=0;a<r.length&&a<i.length;a++)if(!On(i[a],r[a]))return!1;return!0}function Xh(i,r,a,u,d,g){return $r=g,It=r,r.memoizedState=null,r.updateQueue=null,r.lanes=0,H.H=i===null||i.memoizedState===null?ab:lb,$s=!1,g=a(u,d),$s=!1,qa&&(g=A0(r,a,u,d)),x0(i),g}function x0(i){H.H=Nc;var r=se!==null&&se.next!==null;if($r=0,Oe=se=It=null,Sc=!1,No=0,Ka=null,r)throw Error(s(300));i===null||Ue||(i=i.dependencies,i!==null&&pc(i)&&(Ue=!0))}function A0(i,r,a,u){It=i;var d=0;do{if(qa&&(Ka=null),No=0,qa=!1,25<=d)throw Error(s(301));if(d+=1,Oe=se=null,i.updateQueue!=null){var g=i.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}H.H=wO,g=r(a,u)}while(qa);return g}function mO(){var i=H.H,r=i.useState()[0];return r=typeof r.then=="function"?Co(r):r,i=i.useState()[0],(se!==null?se.memoizedState:null)!==i&&(It.flags|=1024),r}function Qh(){var i=Tc!==0;return Tc=0,i}function Jh(i,r,a){r.updateQueue=i.updateQueue,r.flags&=-2053,i.lanes&=~a}function Wh(i){if(Sc){for(i=i.memoizedState;i!==null;){var r=i.queue;r!==null&&(r.pending=null),i=i.next}Sc=!1}$r=0,Oe=se=It=null,qa=!1,No=Tc=0,Ka=null}function dn(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Oe===null?It.memoizedState=Oe=i:Oe=Oe.next=i,Oe}function Ne(){if(se===null){var i=It.alternate;i=i!==null?i.memoizedState:null}else i=se.next;var r=Oe===null?It.memoizedState:Oe.next;if(r!==null)Oe=r,se=i;else{if(i===null)throw It.alternate===null?Error(s(467)):Error(s(310));se=i,i={memoizedState:se.memoizedState,baseState:se.baseState,baseQueue:se.baseQueue,queue:se.queue,next:null},Oe===null?It.memoizedState=Oe=i:Oe=Oe.next=i}return Oe}function tg(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Co(i){var r=No;return No+=1,Ka===null&&(Ka=[]),i=_0(Ka,i,r),r=It,(Oe===null?r.memoizedState:Oe.next)===null&&(r=r.alternate,H.H=r===null||r.memoizedState===null?ab:lb),i}function wc(i){if(i!==null&&typeof i=="object"){if(typeof i.then=="function")return Co(i);if(i.$$typeof===E)return Je(i)}throw Error(s(438,String(i)))}function eg(i){var r=null,a=It.updateQueue;if(a!==null&&(r=a.memoCache),r==null){var u=It.alternate;u!==null&&(u=u.updateQueue,u!==null&&(u=u.memoCache,u!=null&&(r={data:u.data.map(function(d){return d.slice()}),index:0})))}if(r==null&&(r={data:[],index:0}),a===null&&(a=tg(),It.updateQueue=a),a.memoCache=r,a=r.data[r.index],a===void 0)for(a=r.data[r.index]=Array(i),u=0;u<i;u++)a[u]=J;return r.index++,a}function ir(i,r){return typeof r=="function"?r(i):r}function xc(i){var r=Ne();return ng(r,se,i)}function ng(i,r,a){var u=i.queue;if(u===null)throw Error(s(311));u.lastRenderedReducer=a;var d=i.baseQueue,g=u.pending;if(g!==null){if(d!==null){var b=d.next;d.next=g.next,g.next=b}r.baseQueue=d=g,u.pending=null}if(g=i.baseState,d===null)i.memoizedState=g;else{r=d.next;var T=b=null,N=null,$=r,q=!1;do{var P=$.lane&-536870913;if(P!==$.lane?(Ht&P)===P:($r&P)===P){var j=$.revertLane;if(j===0)N!==null&&(N=N.next={lane:0,revertLane:0,action:$.action,hasEagerState:$.hasEagerState,eagerState:$.eagerState,next:null}),P===Va&&(q=!0);else if(($r&j)===j){$=$.next,j===Va&&(q=!0);continue}else P={lane:0,revertLane:$.revertLane,action:$.action,hasEagerState:$.hasEagerState,eagerState:$.eagerState,next:null},N===null?(T=N=P,b=g):N=N.next=P,It.lanes|=j,Pr|=j;P=$.action,$s&&a(g,P),g=$.hasEagerState?$.eagerState:a(g,P)}else j={lane:P,revertLane:$.revertLane,action:$.action,hasEagerState:$.hasEagerState,eagerState:$.eagerState,next:null},N===null?(T=N=j,b=g):N=N.next=j,It.lanes|=P,Pr|=P;$=$.next}while($!==null&&$!==r);if(N===null?b=g:N.next=T,!On(g,i.memoizedState)&&(Ue=!0,q&&(a=Ha,a!==null)))throw a;i.memoizedState=g,i.baseState=b,i.baseQueue=N,u.lastRenderedState=g}return d===null&&(u.lanes=0),[i.memoizedState,u.dispatch]}function ig(i){var r=Ne(),a=r.queue;if(a===null)throw Error(s(311));a.lastRenderedReducer=i;var u=a.dispatch,d=a.pending,g=r.memoizedState;if(d!==null){a.pending=null;var b=d=d.next;do g=i(g,b.action),b=b.next;while(b!==d);On(g,r.memoizedState)||(Ue=!0),r.memoizedState=g,r.baseQueue===null&&(r.baseState=g),a.lastRenderedState=g}return[g,u]}function E0(i,r,a){var u=It,d=Ne(),g=Gt;if(g){if(a===void 0)throw Error(s(407));a=a()}else a=r();var b=!On((se||d).memoizedState,a);b&&(d.memoizedState=a,Ue=!0),d=d.queue;var T=C0.bind(null,u,d,i);if(Do(2048,8,T,[i]),d.getSnapshot!==r||b||Oe!==null&&Oe.memoizedState.tag&1){if(u.flags|=2048,Pa(9,Ac(),N0.bind(null,u,d,a,r),null),fe===null)throw Error(s(349));g||($r&124)!==0||O0(u,r,a)}return a}function O0(i,r,a){i.flags|=16384,i={getSnapshot:r,value:a},r=It.updateQueue,r===null?(r=tg(),It.updateQueue=r,r.stores=[i]):(a=r.stores,a===null?r.stores=[i]:a.push(i))}function N0(i,r,a,u){r.value=a,r.getSnapshot=u,D0(r)&&M0(i)}function C0(i,r,a){return a(function(){D0(r)&&M0(i)})}function D0(i){var r=i.getSnapshot;i=i.value;try{var a=r();return!On(i,a)}catch{return!0}}function M0(i){var r=Ua(i,2);r!==null&&Rn(r,i,2)}function rg(i){var r=dn();if(typeof i=="function"){var a=i;if(i=a(),$s){Rr(!0);try{a()}finally{Rr(!1)}}}return r.memoizedState=r.baseState=i,r.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ir,lastRenderedState:i},r}function B0(i,r,a,u){return i.baseState=a,ng(i,se,typeof u=="function"?u:ir)}function _O(i,r,a,u,d){if(Oc(i))throw Error(s(485));if(i=r.action,i!==null){var g={payload:d,action:i,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){g.listeners.push(b)}};H.T!==null?a(!0):g.isTransition=!1,u(g),a=r.pending,a===null?(g.next=r.pending=g,R0(r,g)):(g.next=a.next,r.pending=a.next=g)}}function R0(i,r){var a=r.action,u=r.payload,d=i.state;if(r.isTransition){var g=H.T,b={};H.T=b;try{var T=a(d,u),N=H.S;N!==null&&N(b,T),F0(i,r,T)}catch($){sg(i,r,$)}finally{H.T=g}}else try{g=a(d,u),F0(i,r,g)}catch($){sg(i,r,$)}}function F0(i,r,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(u){L0(i,r,u)},function(u){return sg(i,r,u)}):L0(i,r,a)}function L0(i,r,a){r.status="fulfilled",r.value=a,I0(r),i.state=a,r=i.pending,r!==null&&(a=r.next,a===r?i.pending=null:(a=a.next,r.next=a,R0(i,a)))}function sg(i,r,a){var u=i.pending;if(i.pending=null,u!==null){u=u.next;do r.status="rejected",r.reason=a,I0(r),r=r.next;while(r!==u)}i.action=null}function I0(i){i=i.listeners;for(var r=0;r<i.length;r++)(0,i[r])()}function k0(i,r){return r}function U0(i,r){if(Gt){var a=fe.formState;if(a!==null){t:{var u=It;if(Gt){if(Te){e:{for(var d=Te,g=xi;d.nodeType!==8;){if(!g){d=null;break e}if(d=ci(d.nextSibling),d===null){d=null;break e}}g=d.data,d=g==="F!"||g==="F"?d:null}if(d){Te=ci(d.nextSibling),u=d.data==="F!";break t}}Is(u)}u=!1}u&&(r=a[0])}}return a=dn(),a.memoizedState=a.baseState=r,u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:k0,lastRenderedState:r},a.queue=u,a=ib.bind(null,It,u),u.dispatch=a,u=rg(!1),g=cg.bind(null,It,!1,u.queue),u=dn(),d={state:r,dispatch:null,action:i,pending:null},u.queue=d,a=_O.bind(null,It,d,g,a),d.dispatch=a,u.memoizedState=i,[r,a,!1]}function z0(i){var r=Ne();return $0(r,se,i)}function $0(i,r,a){if(r=ng(i,r,k0)[0],i=xc(ir)[0],typeof r=="object"&&r!==null&&typeof r.then=="function")try{var u=Co(r)}catch(b){throw b===wo?_c:b}else u=r;r=Ne();var d=r.queue,g=d.dispatch;return a!==r.memoizedState&&(It.flags|=2048,Pa(9,Ac(),bO.bind(null,d,a),null)),[u,g,i]}function bO(i,r){i.action=r}function j0(i){var r=Ne(),a=se;if(a!==null)return $0(r,a,i);Ne(),r=r.memoizedState,a=Ne();var u=a.queue.dispatch;return a.memoizedState=i,[r,u,!1]}function Pa(i,r,a,u){return i={tag:i,create:a,deps:u,inst:r,next:null},r=It.updateQueue,r===null&&(r=tg(),It.updateQueue=r),a=r.lastEffect,a===null?r.lastEffect=i.next=i:(u=a.next,a.next=i,i.next=u,r.lastEffect=i),i}function Ac(){return{destroy:void 0,resource:void 0}}function V0(){return Ne().memoizedState}function Ec(i,r,a,u){var d=dn();u=u===void 0?null:u,It.flags|=i,d.memoizedState=Pa(1|r,Ac(),a,u)}function Do(i,r,a,u){var d=Ne();u=u===void 0?null:u;var g=d.memoizedState.inst;se!==null&&u!==null&&Zh(u,se.memoizedState.deps)?d.memoizedState=Pa(r,g,a,u):(It.flags|=i,d.memoizedState=Pa(1|r,g,a,u))}function H0(i,r){Ec(8390656,8,i,r)}function Y0(i,r){Do(2048,8,i,r)}function q0(i,r){return Do(4,2,i,r)}function K0(i,r){return Do(4,4,i,r)}function P0(i,r){if(typeof r=="function"){i=i();var a=r(i);return function(){typeof a=="function"?a():r(null)}}if(r!=null)return i=i(),r.current=i,function(){r.current=null}}function G0(i,r,a){a=a!=null?a.concat([i]):null,Do(4,4,P0.bind(null,r,i),a)}function ag(){}function Z0(i,r){var a=Ne();r=r===void 0?null:r;var u=a.memoizedState;return r!==null&&Zh(r,u[1])?u[0]:(a.memoizedState=[i,r],i)}function X0(i,r){var a=Ne();r=r===void 0?null:r;var u=a.memoizedState;if(r!==null&&Zh(r,u[1]))return u[0];if(u=i(),$s){Rr(!0);try{i()}finally{Rr(!1)}}return a.memoizedState=[u,r],u}function lg(i,r,a){return a===void 0||($r&1073741824)!==0?i.memoizedState=r:(i.memoizedState=a,i=Wb(),It.lanes|=i,Pr|=i,a)}function Q0(i,r,a,u){return On(a,r)?a:Ya.current!==null?(i=lg(i,a,u),On(i,r)||(Ue=!0),i):($r&42)===0?(Ue=!0,i.memoizedState=a):(i=Wb(),It.lanes|=i,Pr|=i,r)}function J0(i,r,a,u,d){var g=Q.p;Q.p=g!==0&&8>g?g:8;var b=H.T,T={};H.T=T,cg(i,!1,r,a);try{var N=d(),$=H.S;if($!==null&&$(T,N),N!==null&&typeof N=="object"&&typeof N.then=="function"){var q=pO(N,u);Mo(i,r,q,Bn(i))}else Mo(i,r,u,Bn(i))}catch(P){Mo(i,r,{then:function(){},status:"rejected",reason:P},Bn())}finally{Q.p=g,H.T=b}}function vO(){}function og(i,r,a,u){if(i.tag!==5)throw Error(s(476));var d=W0(i).queue;J0(i,d,r,it,a===null?vO:function(){return tb(i),a(u)})}function W0(i){var r=i.memoizedState;if(r!==null)return r;r={memoizedState:it,baseState:it,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ir,lastRenderedState:it},next:null};var a={};return r.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ir,lastRenderedState:a},next:null},i.memoizedState=r,i=i.alternate,i!==null&&(i.memoizedState=r),r}function tb(i){var r=W0(i).next.queue;Mo(i,r,{},Bn())}function ug(){return Je(Zo)}function eb(){return Ne().memoizedState}function nb(){return Ne().memoizedState}function SO(i){for(var r=i.return;r!==null;){switch(r.tag){case 24:case 3:var a=Bn();i=Ur(a);var u=zr(r,i,a);u!==null&&(Rn(u,r,a),Ao(u,r,a)),r={cache:zh()},i.payload=r;return}r=r.return}}function TO(i,r,a){var u=Bn();a={lane:u,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null},Oc(i)?rb(r,a):(a=Ch(i,r,a,u),a!==null&&(Rn(a,i,u),sb(a,r,u)))}function ib(i,r,a){var u=Bn();Mo(i,r,a,u)}function Mo(i,r,a,u){var d={lane:u,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null};if(Oc(i))rb(r,d);else{var g=i.alternate;if(i.lanes===0&&(g===null||g.lanes===0)&&(g=r.lastRenderedReducer,g!==null))try{var b=r.lastRenderedState,T=g(b,a);if(d.hasEagerState=!0,d.eagerState=T,On(T,b))return cc(i,r,d,0),fe===null&&uc(),!1}catch{}finally{}if(a=Ch(i,r,d,u),a!==null)return Rn(a,i,u),sb(a,r,u),!0}return!1}function cg(i,r,a,u){if(u={lane:2,revertLane:Vg(),action:u,hasEagerState:!1,eagerState:null,next:null},Oc(i)){if(r)throw Error(s(479))}else r=Ch(i,a,u,2),r!==null&&Rn(r,i,2)}function Oc(i){var r=i.alternate;return i===It||r!==null&&r===It}function rb(i,r){qa=Sc=!0;var a=i.pending;a===null?r.next=r:(r.next=a.next,a.next=r),i.pending=r}function sb(i,r,a){if((a&4194048)!==0){var u=r.lanes;u&=i.pendingLanes,a|=u,r.lanes=a,h_(i,a)}}var Nc={readContext:Je,use:wc,useCallback:xe,useContext:xe,useEffect:xe,useImperativeHandle:xe,useLayoutEffect:xe,useInsertionEffect:xe,useMemo:xe,useReducer:xe,useRef:xe,useState:xe,useDebugValue:xe,useDeferredValue:xe,useTransition:xe,useSyncExternalStore:xe,useId:xe,useHostTransitionStatus:xe,useFormState:xe,useActionState:xe,useOptimistic:xe,useMemoCache:xe,useCacheRefresh:xe},ab={readContext:Je,use:wc,useCallback:function(i,r){return dn().memoizedState=[i,r===void 0?null:r],i},useContext:Je,useEffect:H0,useImperativeHandle:function(i,r,a){a=a!=null?a.concat([i]):null,Ec(4194308,4,P0.bind(null,r,i),a)},useLayoutEffect:function(i,r){return Ec(4194308,4,i,r)},useInsertionEffect:function(i,r){Ec(4,2,i,r)},useMemo:function(i,r){var a=dn();r=r===void 0?null:r;var u=i();if($s){Rr(!0);try{i()}finally{Rr(!1)}}return a.memoizedState=[u,r],u},useReducer:function(i,r,a){var u=dn();if(a!==void 0){var d=a(r);if($s){Rr(!0);try{a(r)}finally{Rr(!1)}}}else d=r;return u.memoizedState=u.baseState=d,i={pending:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:d},u.queue=i,i=i.dispatch=TO.bind(null,It,i),[u.memoizedState,i]},useRef:function(i){var r=dn();return i={current:i},r.memoizedState=i},useState:function(i){i=rg(i);var r=i.queue,a=ib.bind(null,It,r);return r.dispatch=a,[i.memoizedState,a]},useDebugValue:ag,useDeferredValue:function(i,r){var a=dn();return lg(a,i,r)},useTransition:function(){var i=rg(!1);return i=J0.bind(null,It,i.queue,!0,!1),dn().memoizedState=i,[!1,i]},useSyncExternalStore:function(i,r,a){var u=It,d=dn();if(Gt){if(a===void 0)throw Error(s(407));a=a()}else{if(a=r(),fe===null)throw Error(s(349));(Ht&124)!==0||O0(u,r,a)}d.memoizedState=a;var g={value:a,getSnapshot:r};return d.queue=g,H0(C0.bind(null,u,g,i),[i]),u.flags|=2048,Pa(9,Ac(),N0.bind(null,u,g,a,r),null),a},useId:function(){var i=dn(),r=fe.identifierPrefix;if(Gt){var a=tr,u=Wi;a=(u&~(1<<32-En(u)-1)).toString(32)+a,r="«"+r+"R"+a,a=Tc++,0<a&&(r+="H"+a.toString(32)),r+="»"}else a=yO++,r="«"+r+"r"+a.toString(32)+"»";return i.memoizedState=r},useHostTransitionStatus:ug,useFormState:U0,useActionState:U0,useOptimistic:function(i){var r=dn();r.memoizedState=r.baseState=i;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return r.queue=a,r=cg.bind(null,It,!0,a),a.dispatch=r,[i,r]},useMemoCache:eg,useCacheRefresh:function(){return dn().memoizedState=SO.bind(null,It)}},lb={readContext:Je,use:wc,useCallback:Z0,useContext:Je,useEffect:Y0,useImperativeHandle:G0,useInsertionEffect:q0,useLayoutEffect:K0,useMemo:X0,useReducer:xc,useRef:V0,useState:function(){return xc(ir)},useDebugValue:ag,useDeferredValue:function(i,r){var a=Ne();return Q0(a,se.memoizedState,i,r)},useTransition:function(){var i=xc(ir)[0],r=Ne().memoizedState;return[typeof i=="boolean"?i:Co(i),r]},useSyncExternalStore:E0,useId:eb,useHostTransitionStatus:ug,useFormState:z0,useActionState:z0,useOptimistic:function(i,r){var a=Ne();return B0(a,se,i,r)},useMemoCache:eg,useCacheRefresh:nb},wO={readContext:Je,use:wc,useCallback:Z0,useContext:Je,useEffect:Y0,useImperativeHandle:G0,useInsertionEffect:q0,useLayoutEffect:K0,useMemo:X0,useReducer:ig,useRef:V0,useState:function(){return ig(ir)},useDebugValue:ag,useDeferredValue:function(i,r){var a=Ne();return se===null?lg(a,i,r):Q0(a,se.memoizedState,i,r)},useTransition:function(){var i=ig(ir)[0],r=Ne().memoizedState;return[typeof i=="boolean"?i:Co(i),r]},useSyncExternalStore:E0,useId:eb,useHostTransitionStatus:ug,useFormState:j0,useActionState:j0,useOptimistic:function(i,r){var a=Ne();return se!==null?B0(a,se,i,r):(a.baseState=i,[i,a.queue.dispatch])},useMemoCache:eg,useCacheRefresh:nb},Ga=null,Bo=0;function Cc(i){var r=Bo;return Bo+=1,Ga===null&&(Ga=[]),_0(Ga,i,r)}function Ro(i,r){r=r.props.ref,i.ref=r!==void 0?r:null}function Dc(i,r){throw r.$$typeof===m?Error(s(525)):(i=Object.prototype.toString.call(r),Error(s(31,i==="[object Object]"?"object with keys {"+Object.keys(r).join(", ")+"}":i)))}function ob(i){var r=i._init;return r(i._payload)}function ub(i){function r(F,R){if(i){var U=F.deletions;U===null?(F.deletions=[R],F.flags|=16):U.push(R)}}function a(F,R){if(!i)return null;for(;R!==null;)r(F,R),R=R.sibling;return null}function u(F){for(var R=new Map;F!==null;)F.key!==null?R.set(F.key,F):R.set(F.index,F),F=F.sibling;return R}function d(F,R){return F=Ji(F,R),F.index=0,F.sibling=null,F}function g(F,R,U){return F.index=U,i?(U=F.alternate,U!==null?(U=U.index,U<R?(F.flags|=67108866,R):U):(F.flags|=67108866,R)):(F.flags|=1048576,R)}function b(F){return i&&F.alternate===null&&(F.flags|=67108866),F}function T(F,R,U,K){return R===null||R.tag!==6?(R=Mh(U,F.mode,K),R.return=F,R):(R=d(R,U),R.return=F,R)}function N(F,R,U,K){var lt=U.type;return lt===v?q(F,R,U.props.children,K,U.key):R!==null&&(R.elementType===lt||typeof lt=="object"&&lt!==null&&lt.$$typeof===z&&ob(lt)===R.type)?(R=d(R,U.props),Ro(R,U),R.return=F,R):(R=dc(U.type,U.key,U.props,null,F.mode,K),Ro(R,U),R.return=F,R)}function $(F,R,U,K){return R===null||R.tag!==4||R.stateNode.containerInfo!==U.containerInfo||R.stateNode.implementation!==U.implementation?(R=Bh(U,F.mode,K),R.return=F,R):(R=d(R,U.children||[]),R.return=F,R)}function q(F,R,U,K,lt){return R===null||R.tag!==7?(R=Bs(U,F.mode,K,lt),R.return=F,R):(R=d(R,U),R.return=F,R)}function P(F,R,U){if(typeof R=="string"&&R!==""||typeof R=="number"||typeof R=="bigint")return R=Mh(""+R,F.mode,U),R.return=F,R;if(typeof R=="object"&&R!==null){switch(R.$$typeof){case _:return U=dc(R.type,R.key,R.props,null,F.mode,U),Ro(U,R),U.return=F,U;case S:return R=Bh(R,F.mode,U),R.return=F,R;case z:var K=R._init;return R=K(R._payload),P(F,R,U)}if(ut(R)||dt(R))return R=Bs(R,F.mode,U,null),R.return=F,R;if(typeof R.then=="function")return P(F,Cc(R),U);if(R.$$typeof===E)return P(F,yc(F,R),U);Dc(F,R)}return null}function j(F,R,U,K){var lt=R!==null?R.key:null;if(typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint")return lt!==null?null:T(F,R,""+U,K);if(typeof U=="object"&&U!==null){switch(U.$$typeof){case _:return U.key===lt?N(F,R,U,K):null;case S:return U.key===lt?$(F,R,U,K):null;case z:return lt=U._init,U=lt(U._payload),j(F,R,U,K)}if(ut(U)||dt(U))return lt!==null?null:q(F,R,U,K,null);if(typeof U.then=="function")return j(F,R,Cc(U),K);if(U.$$typeof===E)return j(F,R,yc(F,U),K);Dc(F,U)}return null}function V(F,R,U,K,lt){if(typeof K=="string"&&K!==""||typeof K=="number"||typeof K=="bigint")return F=F.get(U)||null,T(R,F,""+K,lt);if(typeof K=="object"&&K!==null){switch(K.$$typeof){case _:return F=F.get(K.key===null?U:K.key)||null,N(R,F,K,lt);case S:return F=F.get(K.key===null?U:K.key)||null,$(R,F,K,lt);case z:var kt=K._init;return K=kt(K._payload),V(F,R,U,K,lt)}if(ut(K)||dt(K))return F=F.get(U)||null,q(R,F,K,lt,null);if(typeof K.then=="function")return V(F,R,U,Cc(K),lt);if(K.$$typeof===E)return V(F,R,U,yc(R,K),lt);Dc(R,K)}return null}function bt(F,R,U,K){for(var lt=null,kt=null,ct=R,pt=R=0,$e=null;ct!==null&&pt<U.length;pt++){ct.index>pt?($e=ct,ct=null):$e=ct.sibling;var Kt=j(F,ct,U[pt],K);if(Kt===null){ct===null&&(ct=$e);break}i&&ct&&Kt.alternate===null&&r(F,ct),R=g(Kt,R,pt),kt===null?lt=Kt:kt.sibling=Kt,kt=Kt,ct=$e}if(pt===U.length)return a(F,ct),Gt&&Fs(F,pt),lt;if(ct===null){for(;pt<U.length;pt++)ct=P(F,U[pt],K),ct!==null&&(R=g(ct,R,pt),kt===null?lt=ct:kt.sibling=ct,kt=ct);return Gt&&Fs(F,pt),lt}for(ct=u(ct);pt<U.length;pt++)$e=V(ct,F,pt,U[pt],K),$e!==null&&(i&&$e.alternate!==null&&ct.delete($e.key===null?pt:$e.key),R=g($e,R,pt),kt===null?lt=$e:kt.sibling=$e,kt=$e);return i&&ct.forEach(function(ns){return r(F,ns)}),Gt&&Fs(F,pt),lt}function ht(F,R,U,K){if(U==null)throw Error(s(151));for(var lt=null,kt=null,ct=R,pt=R=0,$e=null,Kt=U.next();ct!==null&&!Kt.done;pt++,Kt=U.next()){ct.index>pt?($e=ct,ct=null):$e=ct.sibling;var ns=j(F,ct,Kt.value,K);if(ns===null){ct===null&&(ct=$e);break}i&&ct&&ns.alternate===null&&r(F,ct),R=g(ns,R,pt),kt===null?lt=ns:kt.sibling=ns,kt=ns,ct=$e}if(Kt.done)return a(F,ct),Gt&&Fs(F,pt),lt;if(ct===null){for(;!Kt.done;pt++,Kt=U.next())Kt=P(F,Kt.value,K),Kt!==null&&(R=g(Kt,R,pt),kt===null?lt=Kt:kt.sibling=Kt,kt=Kt);return Gt&&Fs(F,pt),lt}for(ct=u(ct);!Kt.done;pt++,Kt=U.next())Kt=V(ct,F,pt,Kt.value,K),Kt!==null&&(i&&Kt.alternate!==null&&ct.delete(Kt.key===null?pt:Kt.key),R=g(Kt,R,pt),kt===null?lt=Kt:kt.sibling=Kt,kt=Kt);return i&&ct.forEach(function(xN){return r(F,xN)}),Gt&&Fs(F,pt),lt}function le(F,R,U,K){if(typeof U=="object"&&U!==null&&U.type===v&&U.key===null&&(U=U.props.children),typeof U=="object"&&U!==null){switch(U.$$typeof){case _:t:{for(var lt=U.key;R!==null;){if(R.key===lt){if(lt=U.type,lt===v){if(R.tag===7){a(F,R.sibling),K=d(R,U.props.children),K.return=F,F=K;break t}}else if(R.elementType===lt||typeof lt=="object"&&lt!==null&&lt.$$typeof===z&&ob(lt)===R.type){a(F,R.sibling),K=d(R,U.props),Ro(K,U),K.return=F,F=K;break t}a(F,R);break}else r(F,R);R=R.sibling}U.type===v?(K=Bs(U.props.children,F.mode,K,U.key),K.return=F,F=K):(K=dc(U.type,U.key,U.props,null,F.mode,K),Ro(K,U),K.return=F,F=K)}return b(F);case S:t:{for(lt=U.key;R!==null;){if(R.key===lt)if(R.tag===4&&R.stateNode.containerInfo===U.containerInfo&&R.stateNode.implementation===U.implementation){a(F,R.sibling),K=d(R,U.children||[]),K.return=F,F=K;break t}else{a(F,R);break}else r(F,R);R=R.sibling}K=Bh(U,F.mode,K),K.return=F,F=K}return b(F);case z:return lt=U._init,U=lt(U._payload),le(F,R,U,K)}if(ut(U))return bt(F,R,U,K);if(dt(U)){if(lt=dt(U),typeof lt!="function")throw Error(s(150));return U=lt.call(U),ht(F,R,U,K)}if(typeof U.then=="function")return le(F,R,Cc(U),K);if(U.$$typeof===E)return le(F,R,yc(F,U),K);Dc(F,U)}return typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint"?(U=""+U,R!==null&&R.tag===6?(a(F,R.sibling),K=d(R,U),K.return=F,F=K):(a(F,R),K=Mh(U,F.mode,K),K.return=F,F=K),b(F)):a(F,R)}return function(F,R,U,K){try{Bo=0;var lt=le(F,R,U,K);return Ga=null,lt}catch(ct){if(ct===wo||ct===_c)throw ct;var kt=Nn(29,ct,null,F.mode);return kt.lanes=K,kt.return=F,kt}finally{}}}var Za=ub(!0),cb=ub(!1),Xn=G(null),Ai=null;function jr(i){var r=i.alternate;et(Re,Re.current&1),et(Xn,i),Ai===null&&(r===null||Ya.current!==null||r.memoizedState!==null)&&(Ai=i)}function fb(i){if(i.tag===22){if(et(Re,Re.current),et(Xn,i),Ai===null){var r=i.alternate;r!==null&&r.memoizedState!==null&&(Ai=i)}}else Vr()}function Vr(){et(Re,Re.current),et(Xn,Xn.current)}function rr(i){tt(Xn),Ai===i&&(Ai=null),tt(Re)}var Re=G(0);function Mc(i){for(var r=i;r!==null;){if(r.tag===13){var a=r.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||a.data==="$?"||tp(a)))return r}else if(r.tag===19&&r.memoizedProps.revealOrder!==void 0){if((r.flags&128)!==0)return r}else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===i)break;for(;r.sibling===null;){if(r.return===null||r.return===i)return null;r=r.return}r.sibling.return=r.return,r=r.sibling}return null}function fg(i,r,a,u){r=i.memoizedState,a=a(u,r),a=a==null?r:y({},r,a),i.memoizedState=a,i.lanes===0&&(i.updateQueue.baseState=a)}var dg={enqueueSetState:function(i,r,a){i=i._reactInternals;var u=Bn(),d=Ur(u);d.payload=r,a!=null&&(d.callback=a),r=zr(i,d,u),r!==null&&(Rn(r,i,u),Ao(r,i,u))},enqueueReplaceState:function(i,r,a){i=i._reactInternals;var u=Bn(),d=Ur(u);d.tag=1,d.payload=r,a!=null&&(d.callback=a),r=zr(i,d,u),r!==null&&(Rn(r,i,u),Ao(r,i,u))},enqueueForceUpdate:function(i,r){i=i._reactInternals;var a=Bn(),u=Ur(a);u.tag=2,r!=null&&(u.callback=r),r=zr(i,u,a),r!==null&&(Rn(r,i,a),Ao(r,i,a))}};function db(i,r,a,u,d,g,b){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(u,g,b):r.prototype&&r.prototype.isPureReactComponent?!po(a,u)||!po(d,g):!0}function hb(i,r,a,u){i=r.state,typeof r.componentWillReceiveProps=="function"&&r.componentWillReceiveProps(a,u),typeof r.UNSAFE_componentWillReceiveProps=="function"&&r.UNSAFE_componentWillReceiveProps(a,u),r.state!==i&&dg.enqueueReplaceState(r,r.state,null)}function js(i,r){var a=r;if("ref"in r){a={};for(var u in r)u!=="ref"&&(a[u]=r[u])}if(i=i.defaultProps){a===r&&(a=y({},a));for(var d in i)a[d]===void 0&&(a[d]=i[d])}return a}var Bc=typeof reportError=="function"?reportError:function(i){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var r=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof i=="object"&&i!==null&&typeof i.message=="string"?String(i.message):String(i),error:i});if(!window.dispatchEvent(r))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",i);return}console.error(i)};function gb(i){Bc(i)}function pb(i){console.error(i)}function yb(i){Bc(i)}function Rc(i,r){try{var a=i.onUncaughtError;a(r.value,{componentStack:r.stack})}catch(u){setTimeout(function(){throw u})}}function mb(i,r,a){try{var u=i.onCaughtError;u(a.value,{componentStack:a.stack,errorBoundary:r.tag===1?r.stateNode:null})}catch(d){setTimeout(function(){throw d})}}function hg(i,r,a){return a=Ur(a),a.tag=3,a.payload={element:null},a.callback=function(){Rc(i,r)},a}function _b(i){return i=Ur(i),i.tag=3,i}function bb(i,r,a,u){var d=a.type.getDerivedStateFromError;if(typeof d=="function"){var g=u.value;i.payload=function(){return d(g)},i.callback=function(){mb(r,a,u)}}var b=a.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(i.callback=function(){mb(r,a,u),typeof d!="function"&&(Gr===null?Gr=new Set([this]):Gr.add(this));var T=u.stack;this.componentDidCatch(u.value,{componentStack:T!==null?T:""})})}function xO(i,r,a,u,d){if(a.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){if(r=a.alternate,r!==null&&vo(r,a,d,!0),a=Xn.current,a!==null){switch(a.tag){case 13:return Ai===null?kg():a.alternate===null&&we===0&&(we=3),a.flags&=-257,a.flags|=65536,a.lanes=d,u===Vh?a.flags|=16384:(r=a.updateQueue,r===null?a.updateQueue=new Set([u]):r.add(u),zg(i,u,d)),!1;case 22:return a.flags|=65536,u===Vh?a.flags|=16384:(r=a.updateQueue,r===null?(r={transitions:null,markerInstances:null,retryQueue:new Set([u])},a.updateQueue=r):(a=r.retryQueue,a===null?r.retryQueue=new Set([u]):a.add(u)),zg(i,u,d)),!1}throw Error(s(435,a.tag))}return zg(i,u,d),kg(),!1}if(Gt)return r=Xn.current,r!==null?((r.flags&65536)===0&&(r.flags|=256),r.flags|=65536,r.lanes=d,u!==Lh&&(i=Error(s(422),{cause:u}),bo(Kn(i,a)))):(u!==Lh&&(r=Error(s(423),{cause:u}),bo(Kn(r,a))),i=i.current.alternate,i.flags|=65536,d&=-d,i.lanes|=d,u=Kn(u,a),d=hg(i.stateNode,u,d),qh(i,d),we!==4&&(we=2)),!1;var g=Error(s(520),{cause:u});if(g=Kn(g,a),$o===null?$o=[g]:$o.push(g),we!==4&&(we=2),r===null)return!0;u=Kn(u,a),a=r;do{switch(a.tag){case 3:return a.flags|=65536,i=d&-d,a.lanes|=i,i=hg(a.stateNode,u,i),qh(a,i),!1;case 1:if(r=a.type,g=a.stateNode,(a.flags&128)===0&&(typeof r.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Gr===null||!Gr.has(g))))return a.flags|=65536,d&=-d,a.lanes|=d,d=_b(d),bb(d,i,a,u),qh(a,d),!1}a=a.return}while(a!==null);return!1}var vb=Error(s(461)),Ue=!1;function He(i,r,a,u){r.child=i===null?cb(r,null,a,u):Za(r,i.child,a,u)}function Sb(i,r,a,u,d){a=a.render;var g=r.ref;if("ref"in u){var b={};for(var T in u)T!=="ref"&&(b[T]=u[T])}else b=u;return Us(r),u=Xh(i,r,a,b,g,d),T=Qh(),i!==null&&!Ue?(Jh(i,r,d),sr(i,r,d)):(Gt&&T&&Rh(r),r.flags|=1,He(i,r,u,d),r.child)}function Tb(i,r,a,u,d){if(i===null){var g=a.type;return typeof g=="function"&&!Dh(g)&&g.defaultProps===void 0&&a.compare===null?(r.tag=15,r.type=g,wb(i,r,g,u,d)):(i=dc(a.type,null,u,r,r.mode,d),i.ref=r.ref,i.return=r,r.child=i)}if(g=i.child,!Sg(i,d)){var b=g.memoizedProps;if(a=a.compare,a=a!==null?a:po,a(b,u)&&i.ref===r.ref)return sr(i,r,d)}return r.flags|=1,i=Ji(g,u),i.ref=r.ref,i.return=r,r.child=i}function wb(i,r,a,u,d){if(i!==null){var g=i.memoizedProps;if(po(g,u)&&i.ref===r.ref)if(Ue=!1,r.pendingProps=u=g,Sg(i,d))(i.flags&131072)!==0&&(Ue=!0);else return r.lanes=i.lanes,sr(i,r,d)}return gg(i,r,a,u,d)}function xb(i,r,a){var u=r.pendingProps,d=u.children,g=i!==null?i.memoizedState:null;if(u.mode==="hidden"){if((r.flags&128)!==0){if(u=g!==null?g.baseLanes|a:a,i!==null){for(d=r.child=i.child,g=0;d!==null;)g=g|d.lanes|d.childLanes,d=d.sibling;r.childLanes=g&~u}else r.childLanes=0,r.child=null;return Ab(i,r,u,a)}if((a&536870912)!==0)r.memoizedState={baseLanes:0,cachePool:null},i!==null&&mc(r,g!==null?g.cachePool:null),g!==null?w0(r,g):Ph(),fb(r);else return r.lanes=r.childLanes=536870912,Ab(i,r,g!==null?g.baseLanes|a:a,a)}else g!==null?(mc(r,g.cachePool),w0(r,g),Vr(),r.memoizedState=null):(i!==null&&mc(r,null),Ph(),Vr());return He(i,r,d,a),r.child}function Ab(i,r,a,u){var d=jh();return d=d===null?null:{parent:Be._currentValue,pool:d},r.memoizedState={baseLanes:a,cachePool:d},i!==null&&mc(r,null),Ph(),fb(r),i!==null&&vo(i,r,u,!0),null}function Fc(i,r){var a=r.ref;if(a===null)i!==null&&i.ref!==null&&(r.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(s(284));(i===null||i.ref!==a)&&(r.flags|=4194816)}}function gg(i,r,a,u,d){return Us(r),a=Xh(i,r,a,u,void 0,d),u=Qh(),i!==null&&!Ue?(Jh(i,r,d),sr(i,r,d)):(Gt&&u&&Rh(r),r.flags|=1,He(i,r,a,d),r.child)}function Eb(i,r,a,u,d,g){return Us(r),r.updateQueue=null,a=A0(r,u,a,d),x0(i),u=Qh(),i!==null&&!Ue?(Jh(i,r,g),sr(i,r,g)):(Gt&&u&&Rh(r),r.flags|=1,He(i,r,a,g),r.child)}function Ob(i,r,a,u,d){if(Us(r),r.stateNode===null){var g=za,b=a.contextType;typeof b=="object"&&b!==null&&(g=Je(b)),g=new a(u,g),r.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=dg,r.stateNode=g,g._reactInternals=r,g=r.stateNode,g.props=u,g.state=r.memoizedState,g.refs={},Hh(r),b=a.contextType,g.context=typeof b=="object"&&b!==null?Je(b):za,g.state=r.memoizedState,b=a.getDerivedStateFromProps,typeof b=="function"&&(fg(r,a,b,u),g.state=r.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(b=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),b!==g.state&&dg.enqueueReplaceState(g,g.state,null),Oo(r,u,g,d),Eo(),g.state=r.memoizedState),typeof g.componentDidMount=="function"&&(r.flags|=4194308),u=!0}else if(i===null){g=r.stateNode;var T=r.memoizedProps,N=js(a,T);g.props=N;var $=g.context,q=a.contextType;b=za,typeof q=="object"&&q!==null&&(b=Je(q));var P=a.getDerivedStateFromProps;q=typeof P=="function"||typeof g.getSnapshotBeforeUpdate=="function",T=r.pendingProps!==T,q||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(T||$!==b)&&hb(r,g,u,b),kr=!1;var j=r.memoizedState;g.state=j,Oo(r,u,g,d),Eo(),$=r.memoizedState,T||j!==$||kr?(typeof P=="function"&&(fg(r,a,P,u),$=r.memoizedState),(N=kr||db(r,a,N,u,j,$,b))?(q||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(r.flags|=4194308)):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=u,r.memoizedState=$),g.props=u,g.state=$,g.context=b,u=N):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),u=!1)}else{g=r.stateNode,Yh(i,r),b=r.memoizedProps,q=js(a,b),g.props=q,P=r.pendingProps,j=g.context,$=a.contextType,N=za,typeof $=="object"&&$!==null&&(N=Je($)),T=a.getDerivedStateFromProps,($=typeof T=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(b!==P||j!==N)&&hb(r,g,u,N),kr=!1,j=r.memoizedState,g.state=j,Oo(r,u,g,d),Eo();var V=r.memoizedState;b!==P||j!==V||kr||i!==null&&i.dependencies!==null&&pc(i.dependencies)?(typeof T=="function"&&(fg(r,a,T,u),V=r.memoizedState),(q=kr||db(r,a,q,u,j,V,N)||i!==null&&i.dependencies!==null&&pc(i.dependencies))?($||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(u,V,N),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(u,V,N)),typeof g.componentDidUpdate=="function"&&(r.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof g.componentDidUpdate!="function"||b===i.memoizedProps&&j===i.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||b===i.memoizedProps&&j===i.memoizedState||(r.flags|=1024),r.memoizedProps=u,r.memoizedState=V),g.props=u,g.state=V,g.context=N,u=q):(typeof g.componentDidUpdate!="function"||b===i.memoizedProps&&j===i.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||b===i.memoizedProps&&j===i.memoizedState||(r.flags|=1024),u=!1)}return g=u,Fc(i,r),u=(r.flags&128)!==0,g||u?(g=r.stateNode,a=u&&typeof a.getDerivedStateFromError!="function"?null:g.render(),r.flags|=1,i!==null&&u?(r.child=Za(r,i.child,null,d),r.child=Za(r,null,a,d)):He(i,r,a,d),r.memoizedState=g.state,i=r.child):i=sr(i,r,d),i}function Nb(i,r,a,u){return _o(),r.flags|=256,He(i,r,a,u),r.child}var pg={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function yg(i){return{baseLanes:i,cachePool:p0()}}function mg(i,r,a){return i=i!==null?i.childLanes&~a:0,r&&(i|=Qn),i}function Cb(i,r,a){var u=r.pendingProps,d=!1,g=(r.flags&128)!==0,b;if((b=g)||(b=i!==null&&i.memoizedState===null?!1:(Re.current&2)!==0),b&&(d=!0,r.flags&=-129),b=(r.flags&32)!==0,r.flags&=-33,i===null){if(Gt){if(d?jr(r):Vr(),Gt){var T=Te,N;if(N=T){t:{for(N=T,T=xi;N.nodeType!==8;){if(!T){T=null;break t}if(N=ci(N.nextSibling),N===null){T=null;break t}}T=N}T!==null?(r.memoizedState={dehydrated:T,treeContext:Rs!==null?{id:Wi,overflow:tr}:null,retryLane:536870912,hydrationErrors:null},N=Nn(18,null,null,0),N.stateNode=T,N.return=r,r.child=N,nn=r,Te=null,N=!0):N=!1}N||Is(r)}if(T=r.memoizedState,T!==null&&(T=T.dehydrated,T!==null))return tp(T)?r.lanes=32:r.lanes=536870912,null;rr(r)}return T=u.children,u=u.fallback,d?(Vr(),d=r.mode,T=Lc({mode:"hidden",children:T},d),u=Bs(u,d,a,null),T.return=r,u.return=r,T.sibling=u,r.child=T,d=r.child,d.memoizedState=yg(a),d.childLanes=mg(i,b,a),r.memoizedState=pg,u):(jr(r),_g(r,T))}if(N=i.memoizedState,N!==null&&(T=N.dehydrated,T!==null)){if(g)r.flags&256?(jr(r),r.flags&=-257,r=bg(i,r,a)):r.memoizedState!==null?(Vr(),r.child=i.child,r.flags|=128,r=null):(Vr(),d=u.fallback,T=r.mode,u=Lc({mode:"visible",children:u.children},T),d=Bs(d,T,a,null),d.flags|=2,u.return=r,d.return=r,u.sibling=d,r.child=u,Za(r,i.child,null,a),u=r.child,u.memoizedState=yg(a),u.childLanes=mg(i,b,a),r.memoizedState=pg,r=d);else if(jr(r),tp(T)){if(b=T.nextSibling&&T.nextSibling.dataset,b)var $=b.dgst;b=$,u=Error(s(419)),u.stack="",u.digest=b,bo({value:u,source:null,stack:null}),r=bg(i,r,a)}else if(Ue||vo(i,r,a,!1),b=(a&i.childLanes)!==0,Ue||b){if(b=fe,b!==null&&(u=a&-a,u=(u&42)!==0?1:eh(u),u=(u&(b.suspendedLanes|a))!==0?0:u,u!==0&&u!==N.retryLane))throw N.retryLane=u,Ua(i,u),Rn(b,i,u),vb;T.data==="$?"||kg(),r=bg(i,r,a)}else T.data==="$?"?(r.flags|=192,r.child=i.child,r=null):(i=N.treeContext,Te=ci(T.nextSibling),nn=r,Gt=!0,Ls=null,xi=!1,i!==null&&(Gn[Zn++]=Wi,Gn[Zn++]=tr,Gn[Zn++]=Rs,Wi=i.id,tr=i.overflow,Rs=r),r=_g(r,u.children),r.flags|=4096);return r}return d?(Vr(),d=u.fallback,T=r.mode,N=i.child,$=N.sibling,u=Ji(N,{mode:"hidden",children:u.children}),u.subtreeFlags=N.subtreeFlags&65011712,$!==null?d=Ji($,d):(d=Bs(d,T,a,null),d.flags|=2),d.return=r,u.return=r,u.sibling=d,r.child=u,u=d,d=r.child,T=i.child.memoizedState,T===null?T=yg(a):(N=T.cachePool,N!==null?($=Be._currentValue,N=N.parent!==$?{parent:$,pool:$}:N):N=p0(),T={baseLanes:T.baseLanes|a,cachePool:N}),d.memoizedState=T,d.childLanes=mg(i,b,a),r.memoizedState=pg,u):(jr(r),a=i.child,i=a.sibling,a=Ji(a,{mode:"visible",children:u.children}),a.return=r,a.sibling=null,i!==null&&(b=r.deletions,b===null?(r.deletions=[i],r.flags|=16):b.push(i)),r.child=a,r.memoizedState=null,a)}function _g(i,r){return r=Lc({mode:"visible",children:r},i.mode),r.return=i,i.child=r}function Lc(i,r){return i=Nn(22,i,null,r),i.lanes=0,i.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},i}function bg(i,r,a){return Za(r,i.child,null,a),i=_g(r,r.pendingProps.children),i.flags|=2,r.memoizedState=null,i}function Db(i,r,a){i.lanes|=r;var u=i.alternate;u!==null&&(u.lanes|=r),kh(i.return,r,a)}function vg(i,r,a,u,d){var g=i.memoizedState;g===null?i.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:u,tail:a,tailMode:d}:(g.isBackwards=r,g.rendering=null,g.renderingStartTime=0,g.last=u,g.tail=a,g.tailMode=d)}function Mb(i,r,a){var u=r.pendingProps,d=u.revealOrder,g=u.tail;if(He(i,r,u.children,a),u=Re.current,(u&2)!==0)u=u&1|2,r.flags|=128;else{if(i!==null&&(i.flags&128)!==0)t:for(i=r.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&Db(i,a,r);else if(i.tag===19)Db(i,a,r);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===r)break t;for(;i.sibling===null;){if(i.return===null||i.return===r)break t;i=i.return}i.sibling.return=i.return,i=i.sibling}u&=1}switch(et(Re,u),d){case"forwards":for(a=r.child,d=null;a!==null;)i=a.alternate,i!==null&&Mc(i)===null&&(d=a),a=a.sibling;a=d,a===null?(d=r.child,r.child=null):(d=a.sibling,a.sibling=null),vg(r,!1,d,a,g);break;case"backwards":for(a=null,d=r.child,r.child=null;d!==null;){if(i=d.alternate,i!==null&&Mc(i)===null){r.child=d;break}i=d.sibling,d.sibling=a,a=d,d=i}vg(r,!0,a,null,g);break;case"together":vg(r,!1,null,null,void 0);break;default:r.memoizedState=null}return r.child}function sr(i,r,a){if(i!==null&&(r.dependencies=i.dependencies),Pr|=r.lanes,(a&r.childLanes)===0)if(i!==null){if(vo(i,r,a,!1),(a&r.childLanes)===0)return null}else return null;if(i!==null&&r.child!==i.child)throw Error(s(153));if(r.child!==null){for(i=r.child,a=Ji(i,i.pendingProps),r.child=a,a.return=r;i.sibling!==null;)i=i.sibling,a=a.sibling=Ji(i,i.pendingProps),a.return=r;a.sibling=null}return r.child}function Sg(i,r){return(i.lanes&r)!==0?!0:(i=i.dependencies,!!(i!==null&&pc(i)))}function AO(i,r,a){switch(r.tag){case 3:Vt(r,r.stateNode.containerInfo),Ir(r,Be,i.memoizedState.cache),_o();break;case 27:case 5:Ti(r);break;case 4:Vt(r,r.stateNode.containerInfo);break;case 10:Ir(r,r.type,r.memoizedProps.value);break;case 13:var u=r.memoizedState;if(u!==null)return u.dehydrated!==null?(jr(r),r.flags|=128,null):(a&r.child.childLanes)!==0?Cb(i,r,a):(jr(r),i=sr(i,r,a),i!==null?i.sibling:null);jr(r);break;case 19:var d=(i.flags&128)!==0;if(u=(a&r.childLanes)!==0,u||(vo(i,r,a,!1),u=(a&r.childLanes)!==0),d){if(u)return Mb(i,r,a);r.flags|=128}if(d=r.memoizedState,d!==null&&(d.rendering=null,d.tail=null,d.lastEffect=null),et(Re,Re.current),u)break;return null;case 22:case 23:return r.lanes=0,xb(i,r,a);case 24:Ir(r,Be,i.memoizedState.cache)}return sr(i,r,a)}function Bb(i,r,a){if(i!==null)if(i.memoizedProps!==r.pendingProps)Ue=!0;else{if(!Sg(i,a)&&(r.flags&128)===0)return Ue=!1,AO(i,r,a);Ue=(i.flags&131072)!==0}else Ue=!1,Gt&&(r.flags&1048576)!==0&&o0(r,gc,r.index);switch(r.lanes=0,r.tag){case 16:t:{i=r.pendingProps;var u=r.elementType,d=u._init;if(u=d(u._payload),r.type=u,typeof u=="function")Dh(u)?(i=js(u,i),r.tag=1,r=Ob(null,r,u,i,a)):(r.tag=0,r=gg(null,r,u,i,a));else{if(u!=null){if(d=u.$$typeof,d===M){r.tag=11,r=Sb(null,r,u,i,a);break t}else if(d===I){r.tag=14,r=Tb(null,r,u,i,a);break t}}throw r=mt(u)||u,Error(s(306,r,""))}}return r;case 0:return gg(i,r,r.type,r.pendingProps,a);case 1:return u=r.type,d=js(u,r.pendingProps),Ob(i,r,u,d,a);case 3:t:{if(Vt(r,r.stateNode.containerInfo),i===null)throw Error(s(387));u=r.pendingProps;var g=r.memoizedState;d=g.element,Yh(i,r),Oo(r,u,null,a);var b=r.memoizedState;if(u=b.cache,Ir(r,Be,u),u!==g.cache&&Uh(r,[Be],a,!0),Eo(),u=b.element,g.isDehydrated)if(g={element:u,isDehydrated:!1,cache:b.cache},r.updateQueue.baseState=g,r.memoizedState=g,r.flags&256){r=Nb(i,r,u,a);break t}else if(u!==d){d=Kn(Error(s(424)),r),bo(d),r=Nb(i,r,u,a);break t}else{switch(i=r.stateNode.containerInfo,i.nodeType){case 9:i=i.body;break;default:i=i.nodeName==="HTML"?i.ownerDocument.body:i}for(Te=ci(i.firstChild),nn=r,Gt=!0,Ls=null,xi=!0,a=cb(r,null,u,a),r.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling}else{if(_o(),u===d){r=sr(i,r,a);break t}He(i,r,u,a)}r=r.child}return r;case 26:return Fc(i,r),i===null?(a=Iv(r.type,null,r.pendingProps,null))?r.memoizedState=a:Gt||(a=r.type,i=r.pendingProps,u=Zc(ot.current).createElement(a),u[Qe]=r,u[cn]=i,qe(u,a,i),ke(u),r.stateNode=u):r.memoizedState=Iv(r.type,i.memoizedProps,r.pendingProps,i.memoizedState),null;case 27:return Ti(r),i===null&&Gt&&(u=r.stateNode=Rv(r.type,r.pendingProps,ot.current),nn=r,xi=!0,d=Te,Qr(r.type)?(ep=d,Te=ci(u.firstChild)):Te=d),He(i,r,r.pendingProps.children,a),Fc(i,r),i===null&&(r.flags|=4194304),r.child;case 5:return i===null&&Gt&&((d=u=Te)&&(u=WO(u,r.type,r.pendingProps,xi),u!==null?(r.stateNode=u,nn=r,Te=ci(u.firstChild),xi=!1,d=!0):d=!1),d||Is(r)),Ti(r),d=r.type,g=r.pendingProps,b=i!==null?i.memoizedProps:null,u=g.children,Qg(d,g)?u=null:b!==null&&Qg(d,b)&&(r.flags|=32),r.memoizedState!==null&&(d=Xh(i,r,mO,null,null,a),Zo._currentValue=d),Fc(i,r),He(i,r,u,a),r.child;case 6:return i===null&&Gt&&((i=a=Te)&&(a=tN(a,r.pendingProps,xi),a!==null?(r.stateNode=a,nn=r,Te=null,i=!0):i=!1),i||Is(r)),null;case 13:return Cb(i,r,a);case 4:return Vt(r,r.stateNode.containerInfo),u=r.pendingProps,i===null?r.child=Za(r,null,u,a):He(i,r,u,a),r.child;case 11:return Sb(i,r,r.type,r.pendingProps,a);case 7:return He(i,r,r.pendingProps,a),r.child;case 8:return He(i,r,r.pendingProps.children,a),r.child;case 12:return He(i,r,r.pendingProps.children,a),r.child;case 10:return u=r.pendingProps,Ir(r,r.type,u.value),He(i,r,u.children,a),r.child;case 9:return d=r.type._context,u=r.pendingProps.children,Us(r),d=Je(d),u=u(d),r.flags|=1,He(i,r,u,a),r.child;case 14:return Tb(i,r,r.type,r.pendingProps,a);case 15:return wb(i,r,r.type,r.pendingProps,a);case 19:return Mb(i,r,a);case 31:return u=r.pendingProps,a=r.mode,u={mode:u.mode,children:u.children},i===null?(a=Lc(u,a),a.ref=r.ref,r.child=a,a.return=r,r=a):(a=Ji(i.child,u),a.ref=r.ref,r.child=a,a.return=r,r=a),r;case 22:return xb(i,r,a);case 24:return Us(r),u=Je(Be),i===null?(d=jh(),d===null&&(d=fe,g=zh(),d.pooledCache=g,g.refCount++,g!==null&&(d.pooledCacheLanes|=a),d=g),r.memoizedState={parent:u,cache:d},Hh(r),Ir(r,Be,d)):((i.lanes&a)!==0&&(Yh(i,r),Oo(r,null,null,a),Eo()),d=i.memoizedState,g=r.memoizedState,d.parent!==u?(d={parent:u,cache:u},r.memoizedState=d,r.lanes===0&&(r.memoizedState=r.updateQueue.baseState=d),Ir(r,Be,u)):(u=g.cache,Ir(r,Be,u),u!==d.cache&&Uh(r,[Be],a,!0))),He(i,r,r.pendingProps.children,a),r.child;case 29:throw r.pendingProps}throw Error(s(156,r.tag))}function ar(i){i.flags|=4}function Rb(i,r){if(r.type!=="stylesheet"||(r.state.loading&4)!==0)i.flags&=-16777217;else if(i.flags|=16777216,!jv(r)){if(r=Xn.current,r!==null&&((Ht&4194048)===Ht?Ai!==null:(Ht&62914560)!==Ht&&(Ht&536870912)===0||r!==Ai))throw xo=Vh,y0;i.flags|=8192}}function Ic(i,r){r!==null&&(i.flags|=4),i.flags&16384&&(r=i.tag!==22?f_():536870912,i.lanes|=r,Wa|=r)}function Fo(i,r){if(!Gt)switch(i.tailMode){case"hidden":r=i.tail;for(var a=null;r!==null;)r.alternate!==null&&(a=r),r=r.sibling;a===null?i.tail=null:a.sibling=null;break;case"collapsed":a=i.tail;for(var u=null;a!==null;)a.alternate!==null&&(u=a),a=a.sibling;u===null?r||i.tail===null?i.tail=null:i.tail.sibling=null:u.sibling=null}}function ye(i){var r=i.alternate!==null&&i.alternate.child===i.child,a=0,u=0;if(r)for(var d=i.child;d!==null;)a|=d.lanes|d.childLanes,u|=d.subtreeFlags&65011712,u|=d.flags&65011712,d.return=i,d=d.sibling;else for(d=i.child;d!==null;)a|=d.lanes|d.childLanes,u|=d.subtreeFlags,u|=d.flags,d.return=i,d=d.sibling;return i.subtreeFlags|=u,i.childLanes=a,r}function EO(i,r,a){var u=r.pendingProps;switch(Fh(r),r.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ye(r),null;case 1:return ye(r),null;case 3:return a=r.stateNode,u=null,i!==null&&(u=i.memoizedState.cache),r.memoizedState.cache!==u&&(r.flags|=2048),nr(Be),Xe(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(i===null||i.child===null)&&(mo(r)?ar(r):i===null||i.memoizedState.isDehydrated&&(r.flags&256)===0||(r.flags|=1024,f0())),ye(r),null;case 26:return a=r.memoizedState,i===null?(ar(r),a!==null?(ye(r),Rb(r,a)):(ye(r),r.flags&=-16777217)):a?a!==i.memoizedState?(ar(r),ye(r),Rb(r,a)):(ye(r),r.flags&=-16777217):(i.memoizedProps!==u&&ar(r),ye(r),r.flags&=-16777217),null;case 27:Zi(r),a=ot.current;var d=r.type;if(i!==null&&r.stateNode!=null)i.memoizedProps!==u&&ar(r);else{if(!u){if(r.stateNode===null)throw Error(s(166));return ye(r),null}i=at.current,mo(r)?u0(r):(i=Rv(d,u,a),r.stateNode=i,ar(r))}return ye(r),null;case 5:if(Zi(r),a=r.type,i!==null&&r.stateNode!=null)i.memoizedProps!==u&&ar(r);else{if(!u){if(r.stateNode===null)throw Error(s(166));return ye(r),null}if(i=at.current,mo(r))u0(r);else{switch(d=Zc(ot.current),i){case 1:i=d.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=d.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=d.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=d.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=d.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof u.is=="string"?d.createElement("select",{is:u.is}):d.createElement("select"),u.multiple?i.multiple=!0:u.size&&(i.size=u.size);break;default:i=typeof u.is=="string"?d.createElement(a,{is:u.is}):d.createElement(a)}}i[Qe]=r,i[cn]=u;t:for(d=r.child;d!==null;){if(d.tag===5||d.tag===6)i.appendChild(d.stateNode);else if(d.tag!==4&&d.tag!==27&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===r)break t;for(;d.sibling===null;){if(d.return===null||d.return===r)break t;d=d.return}d.sibling.return=d.return,d=d.sibling}r.stateNode=i;t:switch(qe(i,a,u),a){case"button":case"input":case"select":case"textarea":i=!!u.autoFocus;break t;case"img":i=!0;break t;default:i=!1}i&&ar(r)}}return ye(r),r.flags&=-16777217,null;case 6:if(i&&r.stateNode!=null)i.memoizedProps!==u&&ar(r);else{if(typeof u!="string"&&r.stateNode===null)throw Error(s(166));if(i=ot.current,mo(r)){if(i=r.stateNode,a=r.memoizedProps,u=null,d=nn,d!==null)switch(d.tag){case 27:case 5:u=d.memoizedProps}i[Qe]=r,i=!!(i.nodeValue===a||u!==null&&u.suppressHydrationWarning===!0||Ev(i.nodeValue,a)),i||Is(r)}else i=Zc(i).createTextNode(u),i[Qe]=r,r.stateNode=i}return ye(r),null;case 13:if(u=r.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(d=mo(r),u!==null&&u.dehydrated!==null){if(i===null){if(!d)throw Error(s(318));if(d=r.memoizedState,d=d!==null?d.dehydrated:null,!d)throw Error(s(317));d[Qe]=r}else _o(),(r.flags&128)===0&&(r.memoizedState=null),r.flags|=4;ye(r),d=!1}else d=f0(),i!==null&&i.memoizedState!==null&&(i.memoizedState.hydrationErrors=d),d=!0;if(!d)return r.flags&256?(rr(r),r):(rr(r),null)}if(rr(r),(r.flags&128)!==0)return r.lanes=a,r;if(a=u!==null,i=i!==null&&i.memoizedState!==null,a){u=r.child,d=null,u.alternate!==null&&u.alternate.memoizedState!==null&&u.alternate.memoizedState.cachePool!==null&&(d=u.alternate.memoizedState.cachePool.pool);var g=null;u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(g=u.memoizedState.cachePool.pool),g!==d&&(u.flags|=2048)}return a!==i&&a&&(r.child.flags|=8192),Ic(r,r.updateQueue),ye(r),null;case 4:return Xe(),i===null&&Kg(r.stateNode.containerInfo),ye(r),null;case 10:return nr(r.type),ye(r),null;case 19:if(tt(Re),d=r.memoizedState,d===null)return ye(r),null;if(u=(r.flags&128)!==0,g=d.rendering,g===null)if(u)Fo(d,!1);else{if(we!==0||i!==null&&(i.flags&128)!==0)for(i=r.child;i!==null;){if(g=Mc(i),g!==null){for(r.flags|=128,Fo(d,!1),i=g.updateQueue,r.updateQueue=i,Ic(r,i),r.subtreeFlags=0,i=a,a=r.child;a!==null;)l0(a,i),a=a.sibling;return et(Re,Re.current&1|2),r.child}i=i.sibling}d.tail!==null&&wi()>zc&&(r.flags|=128,u=!0,Fo(d,!1),r.lanes=4194304)}else{if(!u)if(i=Mc(g),i!==null){if(r.flags|=128,u=!0,i=i.updateQueue,r.updateQueue=i,Ic(r,i),Fo(d,!0),d.tail===null&&d.tailMode==="hidden"&&!g.alternate&&!Gt)return ye(r),null}else 2*wi()-d.renderingStartTime>zc&&a!==536870912&&(r.flags|=128,u=!0,Fo(d,!1),r.lanes=4194304);d.isBackwards?(g.sibling=r.child,r.child=g):(i=d.last,i!==null?i.sibling=g:r.child=g,d.last=g)}return d.tail!==null?(r=d.tail,d.rendering=r,d.tail=r.sibling,d.renderingStartTime=wi(),r.sibling=null,i=Re.current,et(Re,u?i&1|2:i&1),r):(ye(r),null);case 22:case 23:return rr(r),Gh(),u=r.memoizedState!==null,i!==null?i.memoizedState!==null!==u&&(r.flags|=8192):u&&(r.flags|=8192),u?(a&536870912)!==0&&(r.flags&128)===0&&(ye(r),r.subtreeFlags&6&&(r.flags|=8192)):ye(r),a=r.updateQueue,a!==null&&Ic(r,a.retryQueue),a=null,i!==null&&i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(a=i.memoizedState.cachePool.pool),u=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(u=r.memoizedState.cachePool.pool),u!==a&&(r.flags|=2048),i!==null&&tt(zs),null;case 24:return a=null,i!==null&&(a=i.memoizedState.cache),r.memoizedState.cache!==a&&(r.flags|=2048),nr(Be),ye(r),null;case 25:return null;case 30:return null}throw Error(s(156,r.tag))}function OO(i,r){switch(Fh(r),r.tag){case 1:return i=r.flags,i&65536?(r.flags=i&-65537|128,r):null;case 3:return nr(Be),Xe(),i=r.flags,(i&65536)!==0&&(i&128)===0?(r.flags=i&-65537|128,r):null;case 26:case 27:case 5:return Zi(r),null;case 13:if(rr(r),i=r.memoizedState,i!==null&&i.dehydrated!==null){if(r.alternate===null)throw Error(s(340));_o()}return i=r.flags,i&65536?(r.flags=i&-65537|128,r):null;case 19:return tt(Re),null;case 4:return Xe(),null;case 10:return nr(r.type),null;case 22:case 23:return rr(r),Gh(),i!==null&&tt(zs),i=r.flags,i&65536?(r.flags=i&-65537|128,r):null;case 24:return nr(Be),null;case 25:return null;default:return null}}function Fb(i,r){switch(Fh(r),r.tag){case 3:nr(Be),Xe();break;case 26:case 27:case 5:Zi(r);break;case 4:Xe();break;case 13:rr(r);break;case 19:tt(Re);break;case 10:nr(r.type);break;case 22:case 23:rr(r),Gh(),i!==null&&tt(zs);break;case 24:nr(Be)}}function Lo(i,r){try{var a=r.updateQueue,u=a!==null?a.lastEffect:null;if(u!==null){var d=u.next;a=d;do{if((a.tag&i)===i){u=void 0;var g=a.create,b=a.inst;u=g(),b.destroy=u}a=a.next}while(a!==d)}}catch(T){oe(r,r.return,T)}}function Hr(i,r,a){try{var u=r.updateQueue,d=u!==null?u.lastEffect:null;if(d!==null){var g=d.next;u=g;do{if((u.tag&i)===i){var b=u.inst,T=b.destroy;if(T!==void 0){b.destroy=void 0,d=r;var N=a,$=T;try{$()}catch(q){oe(d,N,q)}}}u=u.next}while(u!==g)}}catch(q){oe(r,r.return,q)}}function Lb(i){var r=i.updateQueue;if(r!==null){var a=i.stateNode;try{T0(r,a)}catch(u){oe(i,i.return,u)}}}function Ib(i,r,a){a.props=js(i.type,i.memoizedProps),a.state=i.memoizedState;try{a.componentWillUnmount()}catch(u){oe(i,r,u)}}function Io(i,r){try{var a=i.ref;if(a!==null){switch(i.tag){case 26:case 27:case 5:var u=i.stateNode;break;case 30:u=i.stateNode;break;default:u=i.stateNode}typeof a=="function"?i.refCleanup=a(u):a.current=u}}catch(d){oe(i,r,d)}}function Ei(i,r){var a=i.ref,u=i.refCleanup;if(a!==null)if(typeof u=="function")try{u()}catch(d){oe(i,r,d)}finally{i.refCleanup=null,i=i.alternate,i!=null&&(i.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(d){oe(i,r,d)}else a.current=null}function kb(i){var r=i.type,a=i.memoizedProps,u=i.stateNode;try{t:switch(r){case"button":case"input":case"select":case"textarea":a.autoFocus&&u.focus();break t;case"img":a.src?u.src=a.src:a.srcSet&&(u.srcset=a.srcSet)}}catch(d){oe(i,i.return,d)}}function Tg(i,r,a){try{var u=i.stateNode;GO(u,i.type,a,r),u[cn]=r}catch(d){oe(i,i.return,d)}}function Ub(i){return i.tag===5||i.tag===3||i.tag===26||i.tag===27&&Qr(i.type)||i.tag===4}function wg(i){t:for(;;){for(;i.sibling===null;){if(i.return===null||Ub(i.return))return null;i=i.return}for(i.sibling.return=i.return,i=i.sibling;i.tag!==5&&i.tag!==6&&i.tag!==18;){if(i.tag===27&&Qr(i.type)||i.flags&2||i.child===null||i.tag===4)continue t;i.child.return=i,i=i.child}if(!(i.flags&2))return i.stateNode}}function xg(i,r,a){var u=i.tag;if(u===5||u===6)i=i.stateNode,r?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(i,r):(r=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,r.appendChild(i),a=a._reactRootContainer,a!=null||r.onclick!==null||(r.onclick=Gc));else if(u!==4&&(u===27&&Qr(i.type)&&(a=i.stateNode,r=null),i=i.child,i!==null))for(xg(i,r,a),i=i.sibling;i!==null;)xg(i,r,a),i=i.sibling}function kc(i,r,a){var u=i.tag;if(u===5||u===6)i=i.stateNode,r?a.insertBefore(i,r):a.appendChild(i);else if(u!==4&&(u===27&&Qr(i.type)&&(a=i.stateNode),i=i.child,i!==null))for(kc(i,r,a),i=i.sibling;i!==null;)kc(i,r,a),i=i.sibling}function zb(i){var r=i.stateNode,a=i.memoizedProps;try{for(var u=i.type,d=r.attributes;d.length;)r.removeAttributeNode(d[0]);qe(r,u,a),r[Qe]=i,r[cn]=a}catch(g){oe(i,i.return,g)}}var lr=!1,Ae=!1,Ag=!1,$b=typeof WeakSet=="function"?WeakSet:Set,ze=null;function NO(i,r){if(i=i.containerInfo,Zg=ef,i=Q_(i),wh(i)){if("selectionStart"in i)var a={start:i.selectionStart,end:i.selectionEnd};else t:{a=(a=i.ownerDocument)&&a.defaultView||window;var u=a.getSelection&&a.getSelection();if(u&&u.rangeCount!==0){a=u.anchorNode;var d=u.anchorOffset,g=u.focusNode;u=u.focusOffset;try{a.nodeType,g.nodeType}catch{a=null;break t}var b=0,T=-1,N=-1,$=0,q=0,P=i,j=null;e:for(;;){for(var V;P!==a||d!==0&&P.nodeType!==3||(T=b+d),P!==g||u!==0&&P.nodeType!==3||(N=b+u),P.nodeType===3&&(b+=P.nodeValue.length),(V=P.firstChild)!==null;)j=P,P=V;for(;;){if(P===i)break e;if(j===a&&++$===d&&(T=b),j===g&&++q===u&&(N=b),(V=P.nextSibling)!==null)break;P=j,j=P.parentNode}P=V}a=T===-1||N===-1?null:{start:T,end:N}}else a=null}a=a||{start:0,end:0}}else a=null;for(Xg={focusedElem:i,selectionRange:a},ef=!1,ze=r;ze!==null;)if(r=ze,i=r.child,(r.subtreeFlags&1024)!==0&&i!==null)i.return=r,ze=i;else for(;ze!==null;){switch(r=ze,g=r.alternate,i=r.flags,r.tag){case 0:break;case 11:case 15:break;case 1:if((i&1024)!==0&&g!==null){i=void 0,a=r,d=g.memoizedProps,g=g.memoizedState,u=a.stateNode;try{var bt=js(a.type,d,a.elementType===a.type);i=u.getSnapshotBeforeUpdate(bt,g),u.__reactInternalSnapshotBeforeUpdate=i}catch(ht){oe(a,a.return,ht)}}break;case 3:if((i&1024)!==0){if(i=r.stateNode.containerInfo,a=i.nodeType,a===9)Wg(i);else if(a===1)switch(i.nodeName){case"HEAD":case"HTML":case"BODY":Wg(i);break;default:i.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((i&1024)!==0)throw Error(s(163))}if(i=r.sibling,i!==null){i.return=r.return,ze=i;break}ze=r.return}}function jb(i,r,a){var u=a.flags;switch(a.tag){case 0:case 11:case 15:Yr(i,a),u&4&&Lo(5,a);break;case 1:if(Yr(i,a),u&4)if(i=a.stateNode,r===null)try{i.componentDidMount()}catch(b){oe(a,a.return,b)}else{var d=js(a.type,r.memoizedProps);r=r.memoizedState;try{i.componentDidUpdate(d,r,i.__reactInternalSnapshotBeforeUpdate)}catch(b){oe(a,a.return,b)}}u&64&&Lb(a),u&512&&Io(a,a.return);break;case 3:if(Yr(i,a),u&64&&(i=a.updateQueue,i!==null)){if(r=null,a.child!==null)switch(a.child.tag){case 27:case 5:r=a.child.stateNode;break;case 1:r=a.child.stateNode}try{T0(i,r)}catch(b){oe(a,a.return,b)}}break;case 27:r===null&&u&4&&zb(a);case 26:case 5:Yr(i,a),r===null&&u&4&&kb(a),u&512&&Io(a,a.return);break;case 12:Yr(i,a);break;case 13:Yr(i,a),u&4&&Yb(i,a),u&64&&(i=a.memoizedState,i!==null&&(i=i.dehydrated,i!==null&&(a=kO.bind(null,a),eN(i,a))));break;case 22:if(u=a.memoizedState!==null||lr,!u){r=r!==null&&r.memoizedState!==null||Ae,d=lr;var g=Ae;lr=u,(Ae=r)&&!g?qr(i,a,(a.subtreeFlags&8772)!==0):Yr(i,a),lr=d,Ae=g}break;case 30:break;default:Yr(i,a)}}function Vb(i){var r=i.alternate;r!==null&&(i.alternate=null,Vb(r)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(r=i.stateNode,r!==null&&rh(r)),i.stateNode=null,i.return=null,i.dependencies=null,i.memoizedProps=null,i.memoizedState=null,i.pendingProps=null,i.stateNode=null,i.updateQueue=null}var pe=null,hn=!1;function or(i,r,a){for(a=a.child;a!==null;)Hb(i,r,a),a=a.sibling}function Hb(i,r,a){if(An&&typeof An.onCommitFiberUnmount=="function")try{An.onCommitFiberUnmount(no,a)}catch{}switch(a.tag){case 26:Ae||Ei(a,r),or(i,r,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:Ae||Ei(a,r);var u=pe,d=hn;Qr(a.type)&&(pe=a.stateNode,hn=!1),or(i,r,a),qo(a.stateNode),pe=u,hn=d;break;case 5:Ae||Ei(a,r);case 6:if(u=pe,d=hn,pe=null,or(i,r,a),pe=u,hn=d,pe!==null)if(hn)try{(pe.nodeType===9?pe.body:pe.nodeName==="HTML"?pe.ownerDocument.body:pe).removeChild(a.stateNode)}catch(g){oe(a,r,g)}else try{pe.removeChild(a.stateNode)}catch(g){oe(a,r,g)}break;case 18:pe!==null&&(hn?(i=pe,Mv(i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i,a.stateNode),Wo(i)):Mv(pe,a.stateNode));break;case 4:u=pe,d=hn,pe=a.stateNode.containerInfo,hn=!0,or(i,r,a),pe=u,hn=d;break;case 0:case 11:case 14:case 15:Ae||Hr(2,a,r),Ae||Hr(4,a,r),or(i,r,a);break;case 1:Ae||(Ei(a,r),u=a.stateNode,typeof u.componentWillUnmount=="function"&&Ib(a,r,u)),or(i,r,a);break;case 21:or(i,r,a);break;case 22:Ae=(u=Ae)||a.memoizedState!==null,or(i,r,a),Ae=u;break;default:or(i,r,a)}}function Yb(i,r){if(r.memoizedState===null&&(i=r.alternate,i!==null&&(i=i.memoizedState,i!==null&&(i=i.dehydrated,i!==null))))try{Wo(i)}catch(a){oe(r,r.return,a)}}function CO(i){switch(i.tag){case 13:case 19:var r=i.stateNode;return r===null&&(r=i.stateNode=new $b),r;case 22:return i=i.stateNode,r=i._retryCache,r===null&&(r=i._retryCache=new $b),r;default:throw Error(s(435,i.tag))}}function Eg(i,r){var a=CO(i);r.forEach(function(u){var d=UO.bind(null,i,u);a.has(u)||(a.add(u),u.then(d,d))})}function Cn(i,r){var a=r.deletions;if(a!==null)for(var u=0;u<a.length;u++){var d=a[u],g=i,b=r,T=b;t:for(;T!==null;){switch(T.tag){case 27:if(Qr(T.type)){pe=T.stateNode,hn=!1;break t}break;case 5:pe=T.stateNode,hn=!1;break t;case 3:case 4:pe=T.stateNode.containerInfo,hn=!0;break t}T=T.return}if(pe===null)throw Error(s(160));Hb(g,b,d),pe=null,hn=!1,g=d.alternate,g!==null&&(g.return=null),d.return=null}if(r.subtreeFlags&13878)for(r=r.child;r!==null;)qb(r,i),r=r.sibling}var ui=null;function qb(i,r){var a=i.alternate,u=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:Cn(r,i),Dn(i),u&4&&(Hr(3,i,i.return),Lo(3,i),Hr(5,i,i.return));break;case 1:Cn(r,i),Dn(i),u&512&&(Ae||a===null||Ei(a,a.return)),u&64&&lr&&(i=i.updateQueue,i!==null&&(u=i.callbacks,u!==null&&(a=i.shared.hiddenCallbacks,i.shared.hiddenCallbacks=a===null?u:a.concat(u))));break;case 26:var d=ui;if(Cn(r,i),Dn(i),u&512&&(Ae||a===null||Ei(a,a.return)),u&4){var g=a!==null?a.memoizedState:null;if(u=i.memoizedState,a===null)if(u===null)if(i.stateNode===null){t:{u=i.type,a=i.memoizedProps,d=d.ownerDocument||d;e:switch(u){case"title":g=d.getElementsByTagName("title")[0],(!g||g[so]||g[Qe]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=d.createElement(u),d.head.insertBefore(g,d.querySelector("head > title"))),qe(g,u,a),g[Qe]=i,ke(g),u=g;break t;case"link":var b=zv("link","href",d).get(u+(a.href||""));if(b){for(var T=0;T<b.length;T++)if(g=b[T],g.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&g.getAttribute("rel")===(a.rel==null?null:a.rel)&&g.getAttribute("title")===(a.title==null?null:a.title)&&g.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){b.splice(T,1);break e}}g=d.createElement(u),qe(g,u,a),d.head.appendChild(g);break;case"meta":if(b=zv("meta","content",d).get(u+(a.content||""))){for(T=0;T<b.length;T++)if(g=b[T],g.getAttribute("content")===(a.content==null?null:""+a.content)&&g.getAttribute("name")===(a.name==null?null:a.name)&&g.getAttribute("property")===(a.property==null?null:a.property)&&g.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&g.getAttribute("charset")===(a.charSet==null?null:a.charSet)){b.splice(T,1);break e}}g=d.createElement(u),qe(g,u,a),d.head.appendChild(g);break;default:throw Error(s(468,u))}g[Qe]=i,ke(g),u=g}i.stateNode=u}else $v(d,i.type,i.stateNode);else i.stateNode=Uv(d,u,i.memoizedProps);else g!==u?(g===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):g.count--,u===null?$v(d,i.type,i.stateNode):Uv(d,u,i.memoizedProps)):u===null&&i.stateNode!==null&&Tg(i,i.memoizedProps,a.memoizedProps)}break;case 27:Cn(r,i),Dn(i),u&512&&(Ae||a===null||Ei(a,a.return)),a!==null&&u&4&&Tg(i,i.memoizedProps,a.memoizedProps);break;case 5:if(Cn(r,i),Dn(i),u&512&&(Ae||a===null||Ei(a,a.return)),i.flags&32){d=i.stateNode;try{Ma(d,"")}catch(V){oe(i,i.return,V)}}u&4&&i.stateNode!=null&&(d=i.memoizedProps,Tg(i,d,a!==null?a.memoizedProps:d)),u&1024&&(Ag=!0);break;case 6:if(Cn(r,i),Dn(i),u&4){if(i.stateNode===null)throw Error(s(162));u=i.memoizedProps,a=i.stateNode;try{a.nodeValue=u}catch(V){oe(i,i.return,V)}}break;case 3:if(Jc=null,d=ui,ui=Xc(r.containerInfo),Cn(r,i),ui=d,Dn(i),u&4&&a!==null&&a.memoizedState.isDehydrated)try{Wo(r.containerInfo)}catch(V){oe(i,i.return,V)}Ag&&(Ag=!1,Kb(i));break;case 4:u=ui,ui=Xc(i.stateNode.containerInfo),Cn(r,i),Dn(i),ui=u;break;case 12:Cn(r,i),Dn(i);break;case 13:Cn(r,i),Dn(i),i.child.flags&8192&&i.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(Bg=wi()),u&4&&(u=i.updateQueue,u!==null&&(i.updateQueue=null,Eg(i,u)));break;case 22:d=i.memoizedState!==null;var N=a!==null&&a.memoizedState!==null,$=lr,q=Ae;if(lr=$||d,Ae=q||N,Cn(r,i),Ae=q,lr=$,Dn(i),u&8192)t:for(r=i.stateNode,r._visibility=d?r._visibility&-2:r._visibility|1,d&&(a===null||N||lr||Ae||Vs(i)),a=null,r=i;;){if(r.tag===5||r.tag===26){if(a===null){N=a=r;try{if(g=N.stateNode,d)b=g.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none";else{T=N.stateNode;var P=N.memoizedProps.style,j=P!=null&&P.hasOwnProperty("display")?P.display:null;T.style.display=j==null||typeof j=="boolean"?"":(""+j).trim()}}catch(V){oe(N,N.return,V)}}}else if(r.tag===6){if(a===null){N=r;try{N.stateNode.nodeValue=d?"":N.memoizedProps}catch(V){oe(N,N.return,V)}}}else if((r.tag!==22&&r.tag!==23||r.memoizedState===null||r===i)&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===i)break t;for(;r.sibling===null;){if(r.return===null||r.return===i)break t;a===r&&(a=null),r=r.return}a===r&&(a=null),r.sibling.return=r.return,r=r.sibling}u&4&&(u=i.updateQueue,u!==null&&(a=u.retryQueue,a!==null&&(u.retryQueue=null,Eg(i,a))));break;case 19:Cn(r,i),Dn(i),u&4&&(u=i.updateQueue,u!==null&&(i.updateQueue=null,Eg(i,u)));break;case 30:break;case 21:break;default:Cn(r,i),Dn(i)}}function Dn(i){var r=i.flags;if(r&2){try{for(var a,u=i.return;u!==null;){if(Ub(u)){a=u;break}u=u.return}if(a==null)throw Error(s(160));switch(a.tag){case 27:var d=a.stateNode,g=wg(i);kc(i,g,d);break;case 5:var b=a.stateNode;a.flags&32&&(Ma(b,""),a.flags&=-33);var T=wg(i);kc(i,T,b);break;case 3:case 4:var N=a.stateNode.containerInfo,$=wg(i);xg(i,$,N);break;default:throw Error(s(161))}}catch(q){oe(i,i.return,q)}i.flags&=-3}r&4096&&(i.flags&=-4097)}function Kb(i){if(i.subtreeFlags&1024)for(i=i.child;i!==null;){var r=i;Kb(r),r.tag===5&&r.flags&1024&&r.stateNode.reset(),i=i.sibling}}function Yr(i,r){if(r.subtreeFlags&8772)for(r=r.child;r!==null;)jb(i,r.alternate,r),r=r.sibling}function Vs(i){for(i=i.child;i!==null;){var r=i;switch(r.tag){case 0:case 11:case 14:case 15:Hr(4,r,r.return),Vs(r);break;case 1:Ei(r,r.return);var a=r.stateNode;typeof a.componentWillUnmount=="function"&&Ib(r,r.return,a),Vs(r);break;case 27:qo(r.stateNode);case 26:case 5:Ei(r,r.return),Vs(r);break;case 22:r.memoizedState===null&&Vs(r);break;case 30:Vs(r);break;default:Vs(r)}i=i.sibling}}function qr(i,r,a){for(a=a&&(r.subtreeFlags&8772)!==0,r=r.child;r!==null;){var u=r.alternate,d=i,g=r,b=g.flags;switch(g.tag){case 0:case 11:case 15:qr(d,g,a),Lo(4,g);break;case 1:if(qr(d,g,a),u=g,d=u.stateNode,typeof d.componentDidMount=="function")try{d.componentDidMount()}catch($){oe(u,u.return,$)}if(u=g,d=u.updateQueue,d!==null){var T=u.stateNode;try{var N=d.shared.hiddenCallbacks;if(N!==null)for(d.shared.hiddenCallbacks=null,d=0;d<N.length;d++)S0(N[d],T)}catch($){oe(u,u.return,$)}}a&&b&64&&Lb(g),Io(g,g.return);break;case 27:zb(g);case 26:case 5:qr(d,g,a),a&&u===null&&b&4&&kb(g),Io(g,g.return);break;case 12:qr(d,g,a);break;case 13:qr(d,g,a),a&&b&4&&Yb(d,g);break;case 22:g.memoizedState===null&&qr(d,g,a),Io(g,g.return);break;case 30:break;default:qr(d,g,a)}r=r.sibling}}function Og(i,r){var a=null;i!==null&&i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(a=i.memoizedState.cachePool.pool),i=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(i=r.memoizedState.cachePool.pool),i!==a&&(i!=null&&i.refCount++,a!=null&&So(a))}function Ng(i,r){i=null,r.alternate!==null&&(i=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==i&&(r.refCount++,i!=null&&So(i))}function Oi(i,r,a,u){if(r.subtreeFlags&10256)for(r=r.child;r!==null;)Pb(i,r,a,u),r=r.sibling}function Pb(i,r,a,u){var d=r.flags;switch(r.tag){case 0:case 11:case 15:Oi(i,r,a,u),d&2048&&Lo(9,r);break;case 1:Oi(i,r,a,u);break;case 3:Oi(i,r,a,u),d&2048&&(i=null,r.alternate!==null&&(i=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==i&&(r.refCount++,i!=null&&So(i)));break;case 12:if(d&2048){Oi(i,r,a,u),i=r.stateNode;try{var g=r.memoizedProps,b=g.id,T=g.onPostCommit;typeof T=="function"&&T(b,r.alternate===null?"mount":"update",i.passiveEffectDuration,-0)}catch(N){oe(r,r.return,N)}}else Oi(i,r,a,u);break;case 13:Oi(i,r,a,u);break;case 23:break;case 22:g=r.stateNode,b=r.alternate,r.memoizedState!==null?g._visibility&2?Oi(i,r,a,u):ko(i,r):g._visibility&2?Oi(i,r,a,u):(g._visibility|=2,Xa(i,r,a,u,(r.subtreeFlags&10256)!==0)),d&2048&&Og(b,r);break;case 24:Oi(i,r,a,u),d&2048&&Ng(r.alternate,r);break;default:Oi(i,r,a,u)}}function Xa(i,r,a,u,d){for(d=d&&(r.subtreeFlags&10256)!==0,r=r.child;r!==null;){var g=i,b=r,T=a,N=u,$=b.flags;switch(b.tag){case 0:case 11:case 15:Xa(g,b,T,N,d),Lo(8,b);break;case 23:break;case 22:var q=b.stateNode;b.memoizedState!==null?q._visibility&2?Xa(g,b,T,N,d):ko(g,b):(q._visibility|=2,Xa(g,b,T,N,d)),d&&$&2048&&Og(b.alternate,b);break;case 24:Xa(g,b,T,N,d),d&&$&2048&&Ng(b.alternate,b);break;default:Xa(g,b,T,N,d)}r=r.sibling}}function ko(i,r){if(r.subtreeFlags&10256)for(r=r.child;r!==null;){var a=i,u=r,d=u.flags;switch(u.tag){case 22:ko(a,u),d&2048&&Og(u.alternate,u);break;case 24:ko(a,u),d&2048&&Ng(u.alternate,u);break;default:ko(a,u)}r=r.sibling}}var Uo=8192;function Qa(i){if(i.subtreeFlags&Uo)for(i=i.child;i!==null;)Gb(i),i=i.sibling}function Gb(i){switch(i.tag){case 26:Qa(i),i.flags&Uo&&i.memoizedState!==null&&gN(ui,i.memoizedState,i.memoizedProps);break;case 5:Qa(i);break;case 3:case 4:var r=ui;ui=Xc(i.stateNode.containerInfo),Qa(i),ui=r;break;case 22:i.memoizedState===null&&(r=i.alternate,r!==null&&r.memoizedState!==null?(r=Uo,Uo=16777216,Qa(i),Uo=r):Qa(i));break;default:Qa(i)}}function Zb(i){var r=i.alternate;if(r!==null&&(i=r.child,i!==null)){r.child=null;do r=i.sibling,i.sibling=null,i=r;while(i!==null)}}function zo(i){var r=i.deletions;if((i.flags&16)!==0){if(r!==null)for(var a=0;a<r.length;a++){var u=r[a];ze=u,Qb(u,i)}Zb(i)}if(i.subtreeFlags&10256)for(i=i.child;i!==null;)Xb(i),i=i.sibling}function Xb(i){switch(i.tag){case 0:case 11:case 15:zo(i),i.flags&2048&&Hr(9,i,i.return);break;case 3:zo(i);break;case 12:zo(i);break;case 22:var r=i.stateNode;i.memoizedState!==null&&r._visibility&2&&(i.return===null||i.return.tag!==13)?(r._visibility&=-3,Uc(i)):zo(i);break;default:zo(i)}}function Uc(i){var r=i.deletions;if((i.flags&16)!==0){if(r!==null)for(var a=0;a<r.length;a++){var u=r[a];ze=u,Qb(u,i)}Zb(i)}for(i=i.child;i!==null;){switch(r=i,r.tag){case 0:case 11:case 15:Hr(8,r,r.return),Uc(r);break;case 22:a=r.stateNode,a._visibility&2&&(a._visibility&=-3,Uc(r));break;default:Uc(r)}i=i.sibling}}function Qb(i,r){for(;ze!==null;){var a=ze;switch(a.tag){case 0:case 11:case 15:Hr(8,a,r);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var u=a.memoizedState.cachePool.pool;u!=null&&u.refCount++}break;case 24:So(a.memoizedState.cache)}if(u=a.child,u!==null)u.return=a,ze=u;else t:for(a=i;ze!==null;){u=ze;var d=u.sibling,g=u.return;if(Vb(u),u===a){ze=null;break t}if(d!==null){d.return=g,ze=d;break t}ze=g}}}var DO={getCacheForType:function(i){var r=Je(Be),a=r.data.get(i);return a===void 0&&(a=i(),r.data.set(i,a)),a}},MO=typeof WeakMap=="function"?WeakMap:Map,ee=0,fe=null,Ut=null,Ht=0,ne=0,Mn=null,Kr=!1,Ja=!1,Cg=!1,ur=0,we=0,Pr=0,Hs=0,Dg=0,Qn=0,Wa=0,$o=null,gn=null,Mg=!1,Bg=0,zc=1/0,$c=null,Gr=null,Ye=0,Zr=null,tl=null,el=0,Rg=0,Fg=null,Jb=null,jo=0,Lg=null;function Bn(){if((ee&2)!==0&&Ht!==0)return Ht&-Ht;if(H.T!==null){var i=Va;return i!==0?i:Vg()}return g_()}function Wb(){Qn===0&&(Qn=(Ht&536870912)===0||Gt?c_():536870912);var i=Xn.current;return i!==null&&(i.flags|=32),Qn}function Rn(i,r,a){(i===fe&&(ne===2||ne===9)||i.cancelPendingCommit!==null)&&(nl(i,0),Xr(i,Ht,Qn,!1)),ro(i,a),((ee&2)===0||i!==fe)&&(i===fe&&((ee&2)===0&&(Hs|=a),we===4&&Xr(i,Ht,Qn,!1)),Ni(i))}function tv(i,r,a){if((ee&6)!==0)throw Error(s(327));var u=!a&&(r&124)===0&&(r&i.expiredLanes)===0||io(i,r),d=u?FO(i,r):Ug(i,r,!0),g=u;do{if(d===0){Ja&&!u&&Xr(i,r,0,!1);break}else{if(a=i.current.alternate,g&&!BO(a)){d=Ug(i,r,!1),g=!1;continue}if(d===2){if(g=r,i.errorRecoveryDisabledLanes&g)var b=0;else b=i.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){r=b;t:{var T=i;d=$o;var N=T.current.memoizedState.isDehydrated;if(N&&(nl(T,b).flags|=256),b=Ug(T,b,!1),b!==2){if(Cg&&!N){T.errorRecoveryDisabledLanes|=g,Hs|=g,d=4;break t}g=gn,gn=d,g!==null&&(gn===null?gn=g:gn.push.apply(gn,g))}d=b}if(g=!1,d!==2)continue}}if(d===1){nl(i,0),Xr(i,r,0,!0);break}t:{switch(u=i,g=d,g){case 0:case 1:throw Error(s(345));case 4:if((r&4194048)!==r)break;case 6:Xr(u,r,Qn,!Kr);break t;case 2:gn=null;break;case 3:case 5:break;default:throw Error(s(329))}if((r&62914560)===r&&(d=Bg+300-wi(),10<d)){if(Xr(u,r,Qn,!Kr),Qu(u,0,!0)!==0)break t;u.timeoutHandle=Cv(ev.bind(null,u,a,gn,$c,Mg,r,Qn,Hs,Wa,Kr,g,2,-0,0),d);break t}ev(u,a,gn,$c,Mg,r,Qn,Hs,Wa,Kr,g,0,-0,0)}}break}while(!0);Ni(i)}function ev(i,r,a,u,d,g,b,T,N,$,q,P,j,V){if(i.timeoutHandle=-1,P=r.subtreeFlags,(P&8192||(P&16785408)===16785408)&&(Go={stylesheets:null,count:0,unsuspend:hN},Gb(r),P=pN(),P!==null)){i.cancelPendingCommit=P(ov.bind(null,i,r,g,a,u,d,b,T,N,q,1,j,V)),Xr(i,g,b,!$);return}ov(i,r,g,a,u,d,b,T,N)}function BO(i){for(var r=i;;){var a=r.tag;if((a===0||a===11||a===15)&&r.flags&16384&&(a=r.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var u=0;u<a.length;u++){var d=a[u],g=d.getSnapshot;d=d.value;try{if(!On(g(),d))return!1}catch{return!1}}if(a=r.child,r.subtreeFlags&16384&&a!==null)a.return=r,r=a;else{if(r===i)break;for(;r.sibling===null;){if(r.return===null||r.return===i)return!0;r=r.return}r.sibling.return=r.return,r=r.sibling}}return!0}function Xr(i,r,a,u){r&=~Dg,r&=~Hs,i.suspendedLanes|=r,i.pingedLanes&=~r,u&&(i.warmLanes|=r),u=i.expirationTimes;for(var d=r;0<d;){var g=31-En(d),b=1<<g;u[g]=-1,d&=~b}a!==0&&d_(i,a,r)}function jc(){return(ee&6)===0?(Vo(0),!1):!0}function Ig(){if(Ut!==null){if(ne===0)var i=Ut.return;else i=Ut,er=ks=null,Wh(i),Ga=null,Bo=0,i=Ut;for(;i!==null;)Fb(i.alternate,i),i=i.return;Ut=null}}function nl(i,r){var a=i.timeoutHandle;a!==-1&&(i.timeoutHandle=-1,XO(a)),a=i.cancelPendingCommit,a!==null&&(i.cancelPendingCommit=null,a()),Ig(),fe=i,Ut=a=Ji(i.current,null),Ht=r,ne=0,Mn=null,Kr=!1,Ja=io(i,r),Cg=!1,Wa=Qn=Dg=Hs=Pr=we=0,gn=$o=null,Mg=!1,(r&8)!==0&&(r|=r&32);var u=i.entangledLanes;if(u!==0)for(i=i.entanglements,u&=r;0<u;){var d=31-En(u),g=1<<d;r|=i[d],u&=~g}return ur=r,uc(),a}function nv(i,r){It=null,H.H=Nc,r===wo||r===_c?(r=b0(),ne=3):r===y0?(r=b0(),ne=4):ne=r===vb?8:r!==null&&typeof r=="object"&&typeof r.then=="function"?6:1,Mn=r,Ut===null&&(we=1,Rc(i,Kn(r,i.current)))}function iv(){var i=H.H;return H.H=Nc,i===null?Nc:i}function rv(){var i=H.A;return H.A=DO,i}function kg(){we=4,Kr||(Ht&4194048)!==Ht&&Xn.current!==null||(Ja=!0),(Pr&134217727)===0&&(Hs&134217727)===0||fe===null||Xr(fe,Ht,Qn,!1)}function Ug(i,r,a){var u=ee;ee|=2;var d=iv(),g=rv();(fe!==i||Ht!==r)&&($c=null,nl(i,r)),r=!1;var b=we;t:do try{if(ne!==0&&Ut!==null){var T=Ut,N=Mn;switch(ne){case 8:Ig(),b=6;break t;case 3:case 2:case 9:case 6:Xn.current===null&&(r=!0);var $=ne;if(ne=0,Mn=null,il(i,T,N,$),a&&Ja){b=0;break t}break;default:$=ne,ne=0,Mn=null,il(i,T,N,$)}}RO(),b=we;break}catch(q){nv(i,q)}while(!0);return r&&i.shellSuspendCounter++,er=ks=null,ee=u,H.H=d,H.A=g,Ut===null&&(fe=null,Ht=0,uc()),b}function RO(){for(;Ut!==null;)sv(Ut)}function FO(i,r){var a=ee;ee|=2;var u=iv(),d=rv();fe!==i||Ht!==r?($c=null,zc=wi()+500,nl(i,r)):Ja=io(i,r);t:do try{if(ne!==0&&Ut!==null){r=Ut;var g=Mn;e:switch(ne){case 1:ne=0,Mn=null,il(i,r,g,1);break;case 2:case 9:if(m0(g)){ne=0,Mn=null,av(r);break}r=function(){ne!==2&&ne!==9||fe!==i||(ne=7),Ni(i)},g.then(r,r);break t;case 3:ne=7;break t;case 4:ne=5;break t;case 7:m0(g)?(ne=0,Mn=null,av(r)):(ne=0,Mn=null,il(i,r,g,7));break;case 5:var b=null;switch(Ut.tag){case 26:b=Ut.memoizedState;case 5:case 27:var T=Ut;if(!b||jv(b)){ne=0,Mn=null;var N=T.sibling;if(N!==null)Ut=N;else{var $=T.return;$!==null?(Ut=$,Vc($)):Ut=null}break e}}ne=0,Mn=null,il(i,r,g,5);break;case 6:ne=0,Mn=null,il(i,r,g,6);break;case 8:Ig(),we=6;break t;default:throw Error(s(462))}}LO();break}catch(q){nv(i,q)}while(!0);return er=ks=null,H.H=u,H.A=d,ee=a,Ut!==null?0:(fe=null,Ht=0,uc(),we)}function LO(){for(;Ut!==null&&!iE();)sv(Ut)}function sv(i){var r=Bb(i.alternate,i,ur);i.memoizedProps=i.pendingProps,r===null?Vc(i):Ut=r}function av(i){var r=i,a=r.alternate;switch(r.tag){case 15:case 0:r=Eb(a,r,r.pendingProps,r.type,void 0,Ht);break;case 11:r=Eb(a,r,r.pendingProps,r.type.render,r.ref,Ht);break;case 5:Wh(r);default:Fb(a,r),r=Ut=l0(r,ur),r=Bb(a,r,ur)}i.memoizedProps=i.pendingProps,r===null?Vc(i):Ut=r}function il(i,r,a,u){er=ks=null,Wh(r),Ga=null,Bo=0;var d=r.return;try{if(xO(i,d,r,a,Ht)){we=1,Rc(i,Kn(a,i.current)),Ut=null;return}}catch(g){if(d!==null)throw Ut=d,g;we=1,Rc(i,Kn(a,i.current)),Ut=null;return}r.flags&32768?(Gt||u===1?i=!0:Ja||(Ht&536870912)!==0?i=!1:(Kr=i=!0,(u===2||u===9||u===3||u===6)&&(u=Xn.current,u!==null&&u.tag===13&&(u.flags|=16384))),lv(r,i)):Vc(r)}function Vc(i){var r=i;do{if((r.flags&32768)!==0){lv(r,Kr);return}i=r.return;var a=EO(r.alternate,r,ur);if(a!==null){Ut=a;return}if(r=r.sibling,r!==null){Ut=r;return}Ut=r=i}while(r!==null);we===0&&(we=5)}function lv(i,r){do{var a=OO(i.alternate,i);if(a!==null){a.flags&=32767,Ut=a;return}if(a=i.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!r&&(i=i.sibling,i!==null)){Ut=i;return}Ut=i=a}while(i!==null);we=6,Ut=null}function ov(i,r,a,u,d,g,b,T,N){i.cancelPendingCommit=null;do Hc();while(Ye!==0);if((ee&6)!==0)throw Error(s(327));if(r!==null){if(r===i.current)throw Error(s(177));if(g=r.lanes|r.childLanes,g|=Nh,hE(i,a,g,b,T,N),i===fe&&(Ut=fe=null,Ht=0),tl=r,Zr=i,el=a,Rg=g,Fg=d,Jb=u,(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?(i.callbackNode=null,i.callbackPriority=0,zO(Gu,function(){return hv(),null})):(i.callbackNode=null,i.callbackPriority=0),u=(r.flags&13878)!==0,(r.subtreeFlags&13878)!==0||u){u=H.T,H.T=null,d=Q.p,Q.p=2,b=ee,ee|=4;try{NO(i,r,a)}finally{ee=b,Q.p=d,H.T=u}}Ye=1,uv(),cv(),fv()}}function uv(){if(Ye===1){Ye=0;var i=Zr,r=tl,a=(r.flags&13878)!==0;if((r.subtreeFlags&13878)!==0||a){a=H.T,H.T=null;var u=Q.p;Q.p=2;var d=ee;ee|=4;try{qb(r,i);var g=Xg,b=Q_(i.containerInfo),T=g.focusedElem,N=g.selectionRange;if(b!==T&&T&&T.ownerDocument&&X_(T.ownerDocument.documentElement,T)){if(N!==null&&wh(T)){var $=N.start,q=N.end;if(q===void 0&&(q=$),"selectionStart"in T)T.selectionStart=$,T.selectionEnd=Math.min(q,T.value.length);else{var P=T.ownerDocument||document,j=P&&P.defaultView||window;if(j.getSelection){var V=j.getSelection(),bt=T.textContent.length,ht=Math.min(N.start,bt),le=N.end===void 0?ht:Math.min(N.end,bt);!V.extend&&ht>le&&(b=le,le=ht,ht=b);var F=Z_(T,ht),R=Z_(T,le);if(F&&R&&(V.rangeCount!==1||V.anchorNode!==F.node||V.anchorOffset!==F.offset||V.focusNode!==R.node||V.focusOffset!==R.offset)){var U=P.createRange();U.setStart(F.node,F.offset),V.removeAllRanges(),ht>le?(V.addRange(U),V.extend(R.node,R.offset)):(U.setEnd(R.node,R.offset),V.addRange(U))}}}}for(P=[],V=T;V=V.parentNode;)V.nodeType===1&&P.push({element:V,left:V.scrollLeft,top:V.scrollTop});for(typeof T.focus=="function"&&T.focus(),T=0;T<P.length;T++){var K=P[T];K.element.scrollLeft=K.left,K.element.scrollTop=K.top}}ef=!!Zg,Xg=Zg=null}finally{ee=d,Q.p=u,H.T=a}}i.current=r,Ye=2}}function cv(){if(Ye===2){Ye=0;var i=Zr,r=tl,a=(r.flags&8772)!==0;if((r.subtreeFlags&8772)!==0||a){a=H.T,H.T=null;var u=Q.p;Q.p=2;var d=ee;ee|=4;try{jb(i,r.alternate,r)}finally{ee=d,Q.p=u,H.T=a}}Ye=3}}function fv(){if(Ye===4||Ye===3){Ye=0,rE();var i=Zr,r=tl,a=el,u=Jb;(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?Ye=5:(Ye=0,tl=Zr=null,dv(i,i.pendingLanes));var d=i.pendingLanes;if(d===0&&(Gr=null),nh(a),r=r.stateNode,An&&typeof An.onCommitFiberRoot=="function")try{An.onCommitFiberRoot(no,r,void 0,(r.current.flags&128)===128)}catch{}if(u!==null){r=H.T,d=Q.p,Q.p=2,H.T=null;try{for(var g=i.onRecoverableError,b=0;b<u.length;b++){var T=u[b];g(T.value,{componentStack:T.stack})}}finally{H.T=r,Q.p=d}}(el&3)!==0&&Hc(),Ni(i),d=i.pendingLanes,(a&4194090)!==0&&(d&42)!==0?i===Lg?jo++:(jo=0,Lg=i):jo=0,Vo(0)}}function dv(i,r){(i.pooledCacheLanes&=r)===0&&(r=i.pooledCache,r!=null&&(i.pooledCache=null,So(r)))}function Hc(i){return uv(),cv(),fv(),hv()}function hv(){if(Ye!==5)return!1;var i=Zr,r=Rg;Rg=0;var a=nh(el),u=H.T,d=Q.p;try{Q.p=32>a?32:a,H.T=null,a=Fg,Fg=null;var g=Zr,b=el;if(Ye=0,tl=Zr=null,el=0,(ee&6)!==0)throw Error(s(331));var T=ee;if(ee|=4,Xb(g.current),Pb(g,g.current,b,a),ee=T,Vo(0,!1),An&&typeof An.onPostCommitFiberRoot=="function")try{An.onPostCommitFiberRoot(no,g)}catch{}return!0}finally{Q.p=d,H.T=u,dv(i,r)}}function gv(i,r,a){r=Kn(a,r),r=hg(i.stateNode,r,2),i=zr(i,r,2),i!==null&&(ro(i,2),Ni(i))}function oe(i,r,a){if(i.tag===3)gv(i,i,a);else for(;r!==null;){if(r.tag===3){gv(r,i,a);break}else if(r.tag===1){var u=r.stateNode;if(typeof r.type.getDerivedStateFromError=="function"||typeof u.componentDidCatch=="function"&&(Gr===null||!Gr.has(u))){i=Kn(a,i),a=_b(2),u=zr(r,a,2),u!==null&&(bb(a,u,r,i),ro(u,2),Ni(u));break}}r=r.return}}function zg(i,r,a){var u=i.pingCache;if(u===null){u=i.pingCache=new MO;var d=new Set;u.set(r,d)}else d=u.get(r),d===void 0&&(d=new Set,u.set(r,d));d.has(a)||(Cg=!0,d.add(a),i=IO.bind(null,i,r,a),r.then(i,i))}function IO(i,r,a){var u=i.pingCache;u!==null&&u.delete(r),i.pingedLanes|=i.suspendedLanes&a,i.warmLanes&=~a,fe===i&&(Ht&a)===a&&(we===4||we===3&&(Ht&62914560)===Ht&&300>wi()-Bg?(ee&2)===0&&nl(i,0):Dg|=a,Wa===Ht&&(Wa=0)),Ni(i)}function pv(i,r){r===0&&(r=f_()),i=Ua(i,r),i!==null&&(ro(i,r),Ni(i))}function kO(i){var r=i.memoizedState,a=0;r!==null&&(a=r.retryLane),pv(i,a)}function UO(i,r){var a=0;switch(i.tag){case 13:var u=i.stateNode,d=i.memoizedState;d!==null&&(a=d.retryLane);break;case 19:u=i.stateNode;break;case 22:u=i.stateNode._retryCache;break;default:throw Error(s(314))}u!==null&&u.delete(r),pv(i,a)}function zO(i,r){return Es(i,r)}var Yc=null,rl=null,$g=!1,qc=!1,jg=!1,Ys=0;function Ni(i){i!==rl&&i.next===null&&(rl===null?Yc=rl=i:rl=rl.next=i),qc=!0,$g||($g=!0,jO())}function Vo(i,r){if(!jg&&qc){jg=!0;do for(var a=!1,u=Yc;u!==null;){if(i!==0){var d=u.pendingLanes;if(d===0)var g=0;else{var b=u.suspendedLanes,T=u.pingedLanes;g=(1<<31-En(42|i)+1)-1,g&=d&~(b&~T),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(a=!0,bv(u,g))}else g=Ht,g=Qu(u,u===fe?g:0,u.cancelPendingCommit!==null||u.timeoutHandle!==-1),(g&3)===0||io(u,g)||(a=!0,bv(u,g));u=u.next}while(a);jg=!1}}function $O(){yv()}function yv(){qc=$g=!1;var i=0;Ys!==0&&(ZO()&&(i=Ys),Ys=0);for(var r=wi(),a=null,u=Yc;u!==null;){var d=u.next,g=mv(u,r);g===0?(u.next=null,a===null?Yc=d:a.next=d,d===null&&(rl=a)):(a=u,(i!==0||(g&3)!==0)&&(qc=!0)),u=d}Vo(i)}function mv(i,r){for(var a=i.suspendedLanes,u=i.pingedLanes,d=i.expirationTimes,g=i.pendingLanes&-62914561;0<g;){var b=31-En(g),T=1<<b,N=d[b];N===-1?((T&a)===0||(T&u)!==0)&&(d[b]=dE(T,r)):N<=r&&(i.expiredLanes|=T),g&=~T}if(r=fe,a=Ht,a=Qu(i,i===r?a:0,i.cancelPendingCommit!==null||i.timeoutHandle!==-1),u=i.callbackNode,a===0||i===r&&(ne===2||ne===9)||i.cancelPendingCommit!==null)return u!==null&&u!==null&&Wd(u),i.callbackNode=null,i.callbackPriority=0;if((a&3)===0||io(i,a)){if(r=a&-a,r===i.callbackPriority)return r;switch(u!==null&&Wd(u),nh(a)){case 2:case 8:a=o_;break;case 32:a=Gu;break;case 268435456:a=u_;break;default:a=Gu}return u=_v.bind(null,i),a=Es(a,u),i.callbackPriority=r,i.callbackNode=a,r}return u!==null&&u!==null&&Wd(u),i.callbackPriority=2,i.callbackNode=null,2}function _v(i,r){if(Ye!==0&&Ye!==5)return i.callbackNode=null,i.callbackPriority=0,null;var a=i.callbackNode;if(Hc()&&i.callbackNode!==a)return null;var u=Ht;return u=Qu(i,i===fe?u:0,i.cancelPendingCommit!==null||i.timeoutHandle!==-1),u===0?null:(tv(i,u,r),mv(i,wi()),i.callbackNode!=null&&i.callbackNode===a?_v.bind(null,i):null)}function bv(i,r){if(Hc())return null;tv(i,r,!0)}function jO(){QO(function(){(ee&6)!==0?Es(l_,$O):yv()})}function Vg(){return Ys===0&&(Ys=c_()),Ys}function vv(i){return i==null||typeof i=="symbol"||typeof i=="boolean"?null:typeof i=="function"?i:nc(""+i)}function Sv(i,r){var a=r.ownerDocument.createElement("input");return a.name=r.name,a.value=r.value,i.id&&a.setAttribute("form",i.id),r.parentNode.insertBefore(a,r),i=new FormData(i),a.parentNode.removeChild(a),i}function VO(i,r,a,u,d){if(r==="submit"&&a&&a.stateNode===d){var g=vv((d[cn]||null).action),b=u.submitter;b&&(r=(r=b[cn]||null)?vv(r.formAction):b.getAttribute("formAction"),r!==null&&(g=r,b=null));var T=new ac("action","action",null,u,d);i.push({event:T,listeners:[{instance:null,listener:function(){if(u.defaultPrevented){if(Ys!==0){var N=b?Sv(d,b):new FormData(d);og(a,{pending:!0,data:N,method:d.method,action:g},null,N)}}else typeof g=="function"&&(T.preventDefault(),N=b?Sv(d,b):new FormData(d),og(a,{pending:!0,data:N,method:d.method,action:g},g,N))},currentTarget:d}]})}}for(var Hg=0;Hg<Oh.length;Hg++){var Yg=Oh[Hg],HO=Yg.toLowerCase(),YO=Yg[0].toUpperCase()+Yg.slice(1);oi(HO,"on"+YO)}oi(t0,"onAnimationEnd"),oi(e0,"onAnimationIteration"),oi(n0,"onAnimationStart"),oi("dblclick","onDoubleClick"),oi("focusin","onFocus"),oi("focusout","onBlur"),oi(lO,"onTransitionRun"),oi(oO,"onTransitionStart"),oi(uO,"onTransitionCancel"),oi(i0,"onTransitionEnd"),Na("onMouseEnter",["mouseout","mouseover"]),Na("onMouseLeave",["mouseout","mouseover"]),Na("onPointerEnter",["pointerout","pointerover"]),Na("onPointerLeave",["pointerout","pointerover"]),Ns("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ns("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ns("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ns("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ns("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ns("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ho="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(" "),qO=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Ho));function Tv(i,r){r=(r&4)!==0;for(var a=0;a<i.length;a++){var u=i[a],d=u.event;u=u.listeners;t:{var g=void 0;if(r)for(var b=u.length-1;0<=b;b--){var T=u[b],N=T.instance,$=T.currentTarget;if(T=T.listener,N!==g&&d.isPropagationStopped())break t;g=T,d.currentTarget=$;try{g(d)}catch(q){Bc(q)}d.currentTarget=null,g=N}else for(b=0;b<u.length;b++){if(T=u[b],N=T.instance,$=T.currentTarget,T=T.listener,N!==g&&d.isPropagationStopped())break t;g=T,d.currentTarget=$;try{g(d)}catch(q){Bc(q)}d.currentTarget=null,g=N}}}}function zt(i,r){var a=r[ih];a===void 0&&(a=r[ih]=new Set);var u=i+"__bubble";a.has(u)||(wv(r,i,2,!1),a.add(u))}function qg(i,r,a){var u=0;r&&(u|=4),wv(a,i,u,r)}var Kc="_reactListening"+Math.random().toString(36).slice(2);function Kg(i){if(!i[Kc]){i[Kc]=!0,y_.forEach(function(a){a!=="selectionchange"&&(qO.has(a)||qg(a,!1,i),qg(a,!0,i))});var r=i.nodeType===9?i:i.ownerDocument;r===null||r[Kc]||(r[Kc]=!0,qg("selectionchange",!1,r))}}function wv(i,r,a,u){switch(Pv(r)){case 2:var d=_N;break;case 8:d=bN;break;default:d=ap}a=d.bind(null,r,a,i),d=void 0,!gh||r!=="touchstart"&&r!=="touchmove"&&r!=="wheel"||(d=!0),u?d!==void 0?i.addEventListener(r,a,{capture:!0,passive:d}):i.addEventListener(r,a,!0):d!==void 0?i.addEventListener(r,a,{passive:d}):i.addEventListener(r,a,!1)}function Pg(i,r,a,u,d){var g=u;if((r&1)===0&&(r&2)===0&&u!==null)t:for(;;){if(u===null)return;var b=u.tag;if(b===3||b===4){var T=u.stateNode.containerInfo;if(T===d)break;if(b===4)for(b=u.return;b!==null;){var N=b.tag;if((N===3||N===4)&&b.stateNode.containerInfo===d)return;b=b.return}for(;T!==null;){if(b=Aa(T),b===null)return;if(N=b.tag,N===5||N===6||N===26||N===27){u=g=b;continue t}T=T.parentNode}}u=u.return}D_(function(){var $=g,q=dh(a),P=[];t:{var j=r0.get(i);if(j!==void 0){var V=ac,bt=i;switch(i){case"keypress":if(rc(a)===0)break t;case"keydown":case"keyup":V=zE;break;case"focusin":bt="focus",V=_h;break;case"focusout":bt="blur",V=_h;break;case"beforeblur":case"afterblur":V=_h;break;case"click":if(a.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":V=R_;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":V=OE;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":V=VE;break;case t0:case e0:case n0:V=DE;break;case i0:V=YE;break;case"scroll":case"scrollend":V=AE;break;case"wheel":V=KE;break;case"copy":case"cut":case"paste":V=BE;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":V=L_;break;case"toggle":case"beforetoggle":V=GE}var ht=(r&4)!==0,le=!ht&&(i==="scroll"||i==="scrollend"),F=ht?j!==null?j+"Capture":null:j;ht=[];for(var R=$,U;R!==null;){var K=R;if(U=K.stateNode,K=K.tag,K!==5&&K!==26&&K!==27||U===null||F===null||(K=lo(R,F),K!=null&&ht.push(Yo(R,K,U))),le)break;R=R.return}0<ht.length&&(j=new V(j,bt,null,a,q),P.push({event:j,listeners:ht}))}}if((r&7)===0){t:{if(j=i==="mouseover"||i==="pointerover",V=i==="mouseout"||i==="pointerout",j&&a!==fh&&(bt=a.relatedTarget||a.fromElement)&&(Aa(bt)||bt[xa]))break t;if((V||j)&&(j=q.window===q?q:(j=q.ownerDocument)?j.defaultView||j.parentWindow:window,V?(bt=a.relatedTarget||a.toElement,V=$,bt=bt?Aa(bt):null,bt!==null&&(le=o(bt),ht=bt.tag,bt!==le||ht!==5&&ht!==27&&ht!==6)&&(bt=null)):(V=null,bt=$),V!==bt)){if(ht=R_,K="onMouseLeave",F="onMouseEnter",R="mouse",(i==="pointerout"||i==="pointerover")&&(ht=L_,K="onPointerLeave",F="onPointerEnter",R="pointer"),le=V==null?j:ao(V),U=bt==null?j:ao(bt),j=new ht(K,R+"leave",V,a,q),j.target=le,j.relatedTarget=U,K=null,Aa(q)===$&&(ht=new ht(F,R+"enter",bt,a,q),ht.target=U,ht.relatedTarget=le,K=ht),le=K,V&&bt)e:{for(ht=V,F=bt,R=0,U=ht;U;U=sl(U))R++;for(U=0,K=F;K;K=sl(K))U++;for(;0<R-U;)ht=sl(ht),R--;for(;0<U-R;)F=sl(F),U--;for(;R--;){if(ht===F||F!==null&&ht===F.alternate)break e;ht=sl(ht),F=sl(F)}ht=null}else ht=null;V!==null&&xv(P,j,V,ht,!1),bt!==null&&le!==null&&xv(P,le,bt,ht,!0)}}t:{if(j=$?ao($):window,V=j.nodeName&&j.nodeName.toLowerCase(),V==="select"||V==="input"&&j.type==="file")var lt=H_;else if(j_(j))if(Y_)lt=rO;else{lt=nO;var kt=eO}else V=j.nodeName,!V||V.toLowerCase()!=="input"||j.type!=="checkbox"&&j.type!=="radio"?$&&ch($.elementType)&&(lt=H_):lt=iO;if(lt&&(lt=lt(i,$))){V_(P,lt,a,q);break t}kt&&kt(i,j,$),i==="focusout"&&$&&j.type==="number"&&$.memoizedProps.value!=null&&uh(j,"number",j.value)}switch(kt=$?ao($):window,i){case"focusin":(j_(kt)||kt.contentEditable==="true")&&(La=kt,xh=$,yo=null);break;case"focusout":yo=xh=La=null;break;case"mousedown":Ah=!0;break;case"contextmenu":case"mouseup":case"dragend":Ah=!1,J_(P,a,q);break;case"selectionchange":if(aO)break;case"keydown":case"keyup":J_(P,a,q)}var ct;if(vh)t:{switch(i){case"compositionstart":var pt="onCompositionStart";break t;case"compositionend":pt="onCompositionEnd";break t;case"compositionupdate":pt="onCompositionUpdate";break t}pt=void 0}else Fa?z_(i,a)&&(pt="onCompositionEnd"):i==="keydown"&&a.keyCode===229&&(pt="onCompositionStart");pt&&(I_&&a.locale!=="ko"&&(Fa||pt!=="onCompositionStart"?pt==="onCompositionEnd"&&Fa&&(ct=M_()):(Lr=q,ph="value"in Lr?Lr.value:Lr.textContent,Fa=!0)),kt=Pc($,pt),0<kt.length&&(pt=new F_(pt,i,null,a,q),P.push({event:pt,listeners:kt}),ct?pt.data=ct:(ct=$_(a),ct!==null&&(pt.data=ct)))),(ct=XE?QE(i,a):JE(i,a))&&(pt=Pc($,"onBeforeInput"),0<pt.length&&(kt=new F_("onBeforeInput","beforeinput",null,a,q),P.push({event:kt,listeners:pt}),kt.data=ct)),VO(P,i,$,a,q)}Tv(P,r)})}function Yo(i,r,a){return{instance:i,listener:r,currentTarget:a}}function Pc(i,r){for(var a=r+"Capture",u=[];i!==null;){var d=i,g=d.stateNode;if(d=d.tag,d!==5&&d!==26&&d!==27||g===null||(d=lo(i,a),d!=null&&u.unshift(Yo(i,d,g)),d=lo(i,r),d!=null&&u.push(Yo(i,d,g))),i.tag===3)return u;i=i.return}return[]}function sl(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5&&i.tag!==27);return i||null}function xv(i,r,a,u,d){for(var g=r._reactName,b=[];a!==null&&a!==u;){var T=a,N=T.alternate,$=T.stateNode;if(T=T.tag,N!==null&&N===u)break;T!==5&&T!==26&&T!==27||$===null||(N=$,d?($=lo(a,g),$!=null&&b.unshift(Yo(a,$,N))):d||($=lo(a,g),$!=null&&b.push(Yo(a,$,N)))),a=a.return}b.length!==0&&i.push({event:r,listeners:b})}var KO=/\r\n?/g,PO=/\u0000|\uFFFD/g;function Av(i){return(typeof i=="string"?i:""+i).replace(KO,`
`).replace(PO,"")}function Ev(i,r){return r=Av(r),Av(i)===r}function Gc(){}function ae(i,r,a,u,d,g){switch(a){case"children":typeof u=="string"?r==="body"||r==="textarea"&&u===""||Ma(i,u):(typeof u=="number"||typeof u=="bigint")&&r!=="body"&&Ma(i,""+u);break;case"className":Wu(i,"class",u);break;case"tabIndex":Wu(i,"tabindex",u);break;case"dir":case"role":case"viewBox":case"width":case"height":Wu(i,a,u);break;case"style":N_(i,u,g);break;case"data":if(r!=="object"){Wu(i,"data",u);break}case"src":case"href":if(u===""&&(r!=="a"||a!=="href")){i.removeAttribute(a);break}if(u==null||typeof u=="function"||typeof u=="symbol"||typeof u=="boolean"){i.removeAttribute(a);break}u=nc(""+u),i.setAttribute(a,u);break;case"action":case"formAction":if(typeof u=="function"){i.setAttribute(a,"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 g=="function"&&(a==="formAction"?(r!=="input"&&ae(i,r,"name",d.name,d,null),ae(i,r,"formEncType",d.formEncType,d,null),ae(i,r,"formMethod",d.formMethod,d,null),ae(i,r,"formTarget",d.formTarget,d,null)):(ae(i,r,"encType",d.encType,d,null),ae(i,r,"method",d.method,d,null),ae(i,r,"target",d.target,d,null)));if(u==null||typeof u=="symbol"||typeof u=="boolean"){i.removeAttribute(a);break}u=nc(""+u),i.setAttribute(a,u);break;case"onClick":u!=null&&(i.onclick=Gc);break;case"onScroll":u!=null&&zt("scroll",i);break;case"onScrollEnd":u!=null&&zt("scrollend",i);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(s(61));if(a=u.__html,a!=null){if(d.children!=null)throw Error(s(60));i.innerHTML=a}}break;case"multiple":i.multiple=u&&typeof u!="function"&&typeof u!="symbol";break;case"muted":i.muted=u&&typeof u!="function"&&typeof u!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(u==null||typeof u=="function"||typeof u=="boolean"||typeof u=="symbol"){i.removeAttribute("xlink:href");break}a=nc(""+u),i.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":u!=null&&typeof u!="function"&&typeof u!="symbol"?i.setAttribute(a,""+u):i.removeAttribute(a);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"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":u&&typeof u!="function"&&typeof u!="symbol"?i.setAttribute(a,""):i.removeAttribute(a);break;case"capture":case"download":u===!0?i.setAttribute(a,""):u!==!1&&u!=null&&typeof u!="function"&&typeof u!="symbol"?i.setAttribute(a,u):i.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":u!=null&&typeof u!="function"&&typeof u!="symbol"&&!isNaN(u)&&1<=u?i.setAttribute(a,u):i.removeAttribute(a);break;case"rowSpan":case"start":u==null||typeof u=="function"||typeof u=="symbol"||isNaN(u)?i.removeAttribute(a):i.setAttribute(a,u);break;case"popover":zt("beforetoggle",i),zt("toggle",i),Ju(i,"popover",u);break;case"xlinkActuate":Xi(i,"http://www.w3.org/1999/xlink","xlink:actuate",u);break;case"xlinkArcrole":Xi(i,"http://www.w3.org/1999/xlink","xlink:arcrole",u);break;case"xlinkRole":Xi(i,"http://www.w3.org/1999/xlink","xlink:role",u);break;case"xlinkShow":Xi(i,"http://www.w3.org/1999/xlink","xlink:show",u);break;case"xlinkTitle":Xi(i,"http://www.w3.org/1999/xlink","xlink:title",u);break;case"xlinkType":Xi(i,"http://www.w3.org/1999/xlink","xlink:type",u);break;case"xmlBase":Xi(i,"http://www.w3.org/XML/1998/namespace","xml:base",u);break;case"xmlLang":Xi(i,"http://www.w3.org/XML/1998/namespace","xml:lang",u);break;case"xmlSpace":Xi(i,"http://www.w3.org/XML/1998/namespace","xml:space",u);break;case"is":Ju(i,"is",u);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=wE.get(a)||a,Ju(i,a,u))}}function Gg(i,r,a,u,d,g){switch(a){case"style":N_(i,u,g);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(s(61));if(a=u.__html,a!=null){if(d.children!=null)throw Error(s(60));i.innerHTML=a}}break;case"children":typeof u=="string"?Ma(i,u):(typeof u=="number"||typeof u=="bigint")&&Ma(i,""+u);break;case"onScroll":u!=null&&zt("scroll",i);break;case"onScrollEnd":u!=null&&zt("scrollend",i);break;case"onClick":u!=null&&(i.onclick=Gc);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!m_.hasOwnProperty(a))t:{if(a[0]==="o"&&a[1]==="n"&&(d=a.endsWith("Capture"),r=a.slice(2,d?a.length-7:void 0),g=i[cn]||null,g=g!=null?g[a]:null,typeof g=="function"&&i.removeEventListener(r,g,d),typeof u=="function")){typeof g!="function"&&g!==null&&(a in i?i[a]=null:i.hasAttribute(a)&&i.removeAttribute(a)),i.addEventListener(r,u,d);break t}a in i?i[a]=u:u===!0?i.setAttribute(a,""):Ju(i,a,u)}}}function qe(i,r,a){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":zt("error",i),zt("load",i);var u=!1,d=!1,g;for(g in a)if(a.hasOwnProperty(g)){var b=a[g];if(b!=null)switch(g){case"src":u=!0;break;case"srcSet":d=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ae(i,r,g,b,a,null)}}d&&ae(i,r,"srcSet",a.srcSet,a,null),u&&ae(i,r,"src",a.src,a,null);return;case"input":zt("invalid",i);var T=g=b=d=null,N=null,$=null;for(u in a)if(a.hasOwnProperty(u)){var q=a[u];if(q!=null)switch(u){case"name":d=q;break;case"type":b=q;break;case"checked":N=q;break;case"defaultChecked":$=q;break;case"value":g=q;break;case"defaultValue":T=q;break;case"children":case"dangerouslySetInnerHTML":if(q!=null)throw Error(s(137,r));break;default:ae(i,r,u,q,a,null)}}x_(i,g,T,N,$,b,d,!1),tc(i);return;case"select":zt("invalid",i),u=b=g=null;for(d in a)if(a.hasOwnProperty(d)&&(T=a[d],T!=null))switch(d){case"value":g=T;break;case"defaultValue":b=T;break;case"multiple":u=T;default:ae(i,r,d,T,a,null)}r=g,a=b,i.multiple=!!u,r!=null?Da(i,!!u,r,!1):a!=null&&Da(i,!!u,a,!0);return;case"textarea":zt("invalid",i),g=d=u=null;for(b in a)if(a.hasOwnProperty(b)&&(T=a[b],T!=null))switch(b){case"value":u=T;break;case"defaultValue":d=T;break;case"children":g=T;break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(s(91));break;default:ae(i,r,b,T,a,null)}E_(i,u,d,g),tc(i);return;case"option":for(N in a)if(a.hasOwnProperty(N)&&(u=a[N],u!=null))switch(N){case"selected":i.selected=u&&typeof u!="function"&&typeof u!="symbol";break;default:ae(i,r,N,u,a,null)}return;case"dialog":zt("beforetoggle",i),zt("toggle",i),zt("cancel",i),zt("close",i);break;case"iframe":case"object":zt("load",i);break;case"video":case"audio":for(u=0;u<Ho.length;u++)zt(Ho[u],i);break;case"image":zt("error",i),zt("load",i);break;case"details":zt("toggle",i);break;case"embed":case"source":case"link":zt("error",i),zt("load",i);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for($ in a)if(a.hasOwnProperty($)&&(u=a[$],u!=null))switch($){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ae(i,r,$,u,a,null)}return;default:if(ch(r)){for(q in a)a.hasOwnProperty(q)&&(u=a[q],u!==void 0&&Gg(i,r,q,u,a,void 0));return}}for(T in a)a.hasOwnProperty(T)&&(u=a[T],u!=null&&ae(i,r,T,u,a,null))}function GO(i,r,a,u){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var d=null,g=null,b=null,T=null,N=null,$=null,q=null;for(V in a){var P=a[V];if(a.hasOwnProperty(V)&&P!=null)switch(V){case"checked":break;case"value":break;case"defaultValue":N=P;default:u.hasOwnProperty(V)||ae(i,r,V,null,u,P)}}for(var j in u){var V=u[j];if(P=a[j],u.hasOwnProperty(j)&&(V!=null||P!=null))switch(j){case"type":g=V;break;case"name":d=V;break;case"checked":$=V;break;case"defaultChecked":q=V;break;case"value":b=V;break;case"defaultValue":T=V;break;case"children":case"dangerouslySetInnerHTML":if(V!=null)throw Error(s(137,r));break;default:V!==P&&ae(i,r,j,V,u,P)}}oh(i,b,T,N,$,q,g,d);return;case"select":V=b=T=j=null;for(g in a)if(N=a[g],a.hasOwnProperty(g)&&N!=null)switch(g){case"value":break;case"multiple":V=N;default:u.hasOwnProperty(g)||ae(i,r,g,null,u,N)}for(d in u)if(g=u[d],N=a[d],u.hasOwnProperty(d)&&(g!=null||N!=null))switch(d){case"value":j=g;break;case"defaultValue":T=g;break;case"multiple":b=g;default:g!==N&&ae(i,r,d,g,u,N)}r=T,a=b,u=V,j!=null?Da(i,!!a,j,!1):!!u!=!!a&&(r!=null?Da(i,!!a,r,!0):Da(i,!!a,a?[]:"",!1));return;case"textarea":V=j=null;for(T in a)if(d=a[T],a.hasOwnProperty(T)&&d!=null&&!u.hasOwnProperty(T))switch(T){case"value":break;case"children":break;default:ae(i,r,T,null,u,d)}for(b in u)if(d=u[b],g=a[b],u.hasOwnProperty(b)&&(d!=null||g!=null))switch(b){case"value":j=d;break;case"defaultValue":V=d;break;case"children":break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(s(91));break;default:d!==g&&ae(i,r,b,d,u,g)}A_(i,j,V);return;case"option":for(var bt in a)if(j=a[bt],a.hasOwnProperty(bt)&&j!=null&&!u.hasOwnProperty(bt))switch(bt){case"selected":i.selected=!1;break;default:ae(i,r,bt,null,u,j)}for(N in u)if(j=u[N],V=a[N],u.hasOwnProperty(N)&&j!==V&&(j!=null||V!=null))switch(N){case"selected":i.selected=j&&typeof j!="function"&&typeof j!="symbol";break;default:ae(i,r,N,j,u,V)}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 ht in a)j=a[ht],a.hasOwnProperty(ht)&&j!=null&&!u.hasOwnProperty(ht)&&ae(i,r,ht,null,u,j);for($ in u)if(j=u[$],V=a[$],u.hasOwnProperty($)&&j!==V&&(j!=null||V!=null))switch($){case"children":case"dangerouslySetInnerHTML":if(j!=null)throw Error(s(137,r));break;default:ae(i,r,$,j,u,V)}return;default:if(ch(r)){for(var le in a)j=a[le],a.hasOwnProperty(le)&&j!==void 0&&!u.hasOwnProperty(le)&&Gg(i,r,le,void 0,u,j);for(q in u)j=u[q],V=a[q],!u.hasOwnProperty(q)||j===V||j===void 0&&V===void 0||Gg(i,r,q,j,u,V);return}}for(var F in a)j=a[F],a.hasOwnProperty(F)&&j!=null&&!u.hasOwnProperty(F)&&ae(i,r,F,null,u,j);for(P in u)j=u[P],V=a[P],!u.hasOwnProperty(P)||j===V||j==null&&V==null||ae(i,r,P,j,u,V)}var Zg=null,Xg=null;function Zc(i){return i.nodeType===9?i:i.ownerDocument}function Ov(i){switch(i){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Nv(i,r){if(i===0)switch(r){case"svg":return 1;case"math":return 2;default:return 0}return i===1&&r==="foreignObject"?0:i}function Qg(i,r){return i==="textarea"||i==="noscript"||typeof r.children=="string"||typeof r.children=="number"||typeof r.children=="bigint"||typeof r.dangerouslySetInnerHTML=="object"&&r.dangerouslySetInnerHTML!==null&&r.dangerouslySetInnerHTML.__html!=null}var Jg=null;function ZO(){var i=window.event;return i&&i.type==="popstate"?i===Jg?!1:(Jg=i,!0):(Jg=null,!1)}var Cv=typeof setTimeout=="function"?setTimeout:void 0,XO=typeof clearTimeout=="function"?clearTimeout:void 0,Dv=typeof Promise=="function"?Promise:void 0,QO=typeof queueMicrotask=="function"?queueMicrotask:typeof Dv<"u"?function(i){return Dv.resolve(null).then(i).catch(JO)}:Cv;function JO(i){setTimeout(function(){throw i})}function Qr(i){return i==="head"}function Mv(i,r){var a=r,u=0,d=0;do{var g=a.nextSibling;if(i.removeChild(a),g&&g.nodeType===8)if(a=g.data,a==="/$"){if(0<u&&8>u){a=u;var b=i.ownerDocument;if(a&1&&qo(b.documentElement),a&2&&qo(b.body),a&4)for(a=b.head,qo(a),b=a.firstChild;b;){var T=b.nextSibling,N=b.nodeName;b[so]||N==="SCRIPT"||N==="STYLE"||N==="LINK"&&b.rel.toLowerCase()==="stylesheet"||a.removeChild(b),b=T}}if(d===0){i.removeChild(g),Wo(r);return}d--}else a==="$"||a==="$?"||a==="$!"?d++:u=a.charCodeAt(0)-48;else u=0;a=g}while(a);Wo(r)}function Wg(i){var r=i.firstChild;for(r&&r.nodeType===10&&(r=r.nextSibling);r;){var a=r;switch(r=r.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":Wg(a),rh(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}i.removeChild(a)}}function WO(i,r,a,u){for(;i.nodeType===1;){var d=a;if(i.nodeName.toLowerCase()!==r.toLowerCase()){if(!u&&(i.nodeName!=="INPUT"||i.type!=="hidden"))break}else if(u){if(!i[so])switch(r){case"meta":if(!i.hasAttribute("itemprop"))break;return i;case"link":if(g=i.getAttribute("rel"),g==="stylesheet"&&i.hasAttribute("data-precedence"))break;if(g!==d.rel||i.getAttribute("href")!==(d.href==null||d.href===""?null:d.href)||i.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin)||i.getAttribute("title")!==(d.title==null?null:d.title))break;return i;case"style":if(i.hasAttribute("data-precedence"))break;return i;case"script":if(g=i.getAttribute("src"),(g!==(d.src==null?null:d.src)||i.getAttribute("type")!==(d.type==null?null:d.type)||i.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin))&&g&&i.hasAttribute("async")&&!i.hasAttribute("itemprop"))break;return i;default:return i}}else if(r==="input"&&i.type==="hidden"){var g=d.name==null?null:""+d.name;if(d.type==="hidden"&&i.getAttribute("name")===g)return i}else return i;if(i=ci(i.nextSibling),i===null)break}return null}function tN(i,r,a){if(r==="")return null;for(;i.nodeType!==3;)if((i.nodeType!==1||i.nodeName!=="INPUT"||i.type!=="hidden")&&!a||(i=ci(i.nextSibling),i===null))return null;return i}function tp(i){return i.data==="$!"||i.data==="$?"&&i.ownerDocument.readyState==="complete"}function eN(i,r){var a=i.ownerDocument;if(i.data!=="$?"||a.readyState==="complete")r();else{var u=function(){r(),a.removeEventListener("DOMContentLoaded",u)};a.addEventListener("DOMContentLoaded",u),i._reactRetry=u}}function ci(i){for(;i!=null;i=i.nextSibling){var r=i.nodeType;if(r===1||r===3)break;if(r===8){if(r=i.data,r==="$"||r==="$!"||r==="$?"||r==="F!"||r==="F")break;if(r==="/$")return null}}return i}var ep=null;function Bv(i){i=i.previousSibling;for(var r=0;i;){if(i.nodeType===8){var a=i.data;if(a==="$"||a==="$!"||a==="$?"){if(r===0)return i;r--}else a==="/$"&&r++}i=i.previousSibling}return null}function Rv(i,r,a){switch(r=Zc(a),i){case"html":if(i=r.documentElement,!i)throw Error(s(452));return i;case"head":if(i=r.head,!i)throw Error(s(453));return i;case"body":if(i=r.body,!i)throw Error(s(454));return i;default:throw Error(s(451))}}function qo(i){for(var r=i.attributes;r.length;)i.removeAttributeNode(r[0]);rh(i)}var Jn=new Map,Fv=new Set;function Xc(i){return typeof i.getRootNode=="function"?i.getRootNode():i.nodeType===9?i:i.ownerDocument}var cr=Q.d;Q.d={f:nN,r:iN,D:rN,C:sN,L:aN,m:lN,X:uN,S:oN,M:cN};function nN(){var i=cr.f(),r=jc();return i||r}function iN(i){var r=Ea(i);r!==null&&r.tag===5&&r.type==="form"?tb(r):cr.r(i)}var al=typeof document>"u"?null:document;function Lv(i,r,a){var u=al;if(u&&typeof r=="string"&&r){var d=qn(r);d='link[rel="'+i+'"][href="'+d+'"]',typeof a=="string"&&(d+='[crossorigin="'+a+'"]'),Fv.has(d)||(Fv.add(d),i={rel:i,crossOrigin:a,href:r},u.querySelector(d)===null&&(r=u.createElement("link"),qe(r,"link",i),ke(r),u.head.appendChild(r)))}}function rN(i){cr.D(i),Lv("dns-prefetch",i,null)}function sN(i,r){cr.C(i,r),Lv("preconnect",i,r)}function aN(i,r,a){cr.L(i,r,a);var u=al;if(u&&i&&r){var d='link[rel="preload"][as="'+qn(r)+'"]';r==="image"&&a&&a.imageSrcSet?(d+='[imagesrcset="'+qn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(d+='[imagesizes="'+qn(a.imageSizes)+'"]')):d+='[href="'+qn(i)+'"]';var g=d;switch(r){case"style":g=ll(i);break;case"script":g=ol(i)}Jn.has(g)||(i=y({rel:"preload",href:r==="image"&&a&&a.imageSrcSet?void 0:i,as:r},a),Jn.set(g,i),u.querySelector(d)!==null||r==="style"&&u.querySelector(Ko(g))||r==="script"&&u.querySelector(Po(g))||(r=u.createElement("link"),qe(r,"link",i),ke(r),u.head.appendChild(r)))}}function lN(i,r){cr.m(i,r);var a=al;if(a&&i){var u=r&&typeof r.as=="string"?r.as:"script",d='link[rel="modulepreload"][as="'+qn(u)+'"][href="'+qn(i)+'"]',g=d;switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=ol(i)}if(!Jn.has(g)&&(i=y({rel:"modulepreload",href:i},r),Jn.set(g,i),a.querySelector(d)===null)){switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Po(g)))return}u=a.createElement("link"),qe(u,"link",i),ke(u),a.head.appendChild(u)}}}function oN(i,r,a){cr.S(i,r,a);var u=al;if(u&&i){var d=Oa(u).hoistableStyles,g=ll(i);r=r||"default";var b=d.get(g);if(!b){var T={loading:0,preload:null};if(b=u.querySelector(Ko(g)))T.loading=5;else{i=y({rel:"stylesheet",href:i,"data-precedence":r},a),(a=Jn.get(g))&&np(i,a);var N=b=u.createElement("link");ke(N),qe(N,"link",i),N._p=new Promise(function($,q){N.onload=$,N.onerror=q}),N.addEventListener("load",function(){T.loading|=1}),N.addEventListener("error",function(){T.loading|=2}),T.loading|=4,Qc(b,r,u)}b={type:"stylesheet",instance:b,count:1,state:T},d.set(g,b)}}}function uN(i,r){cr.X(i,r);var a=al;if(a&&i){var u=Oa(a).hoistableScripts,d=ol(i),g=u.get(d);g||(g=a.querySelector(Po(d)),g||(i=y({src:i,async:!0},r),(r=Jn.get(d))&&ip(i,r),g=a.createElement("script"),ke(g),qe(g,"link",i),a.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},u.set(d,g))}}function cN(i,r){cr.M(i,r);var a=al;if(a&&i){var u=Oa(a).hoistableScripts,d=ol(i),g=u.get(d);g||(g=a.querySelector(Po(d)),g||(i=y({src:i,async:!0,type:"module"},r),(r=Jn.get(d))&&ip(i,r),g=a.createElement("script"),ke(g),qe(g,"link",i),a.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},u.set(d,g))}}function Iv(i,r,a,u){var d=(d=ot.current)?Xc(d):null;if(!d)throw Error(s(446));switch(i){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(r=ll(a.href),a=Oa(d).hoistableStyles,u=a.get(r),u||(u={type:"style",instance:null,count:0,state:null},a.set(r,u)),u):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){i=ll(a.href);var g=Oa(d).hoistableStyles,b=g.get(i);if(b||(d=d.ownerDocument||d,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(i,b),(g=d.querySelector(Ko(i)))&&!g._p&&(b.instance=g,b.state.loading=5),Jn.has(i)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Jn.set(i,a),g||fN(d,i,a,b.state))),r&&u===null)throw Error(s(528,""));return b}if(r&&u!==null)throw Error(s(529,""));return null;case"script":return r=a.async,a=a.src,typeof a=="string"&&r&&typeof r!="function"&&typeof r!="symbol"?(r=ol(a),a=Oa(d).hoistableScripts,u=a.get(r),u||(u={type:"script",instance:null,count:0,state:null},a.set(r,u)),u):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,i))}}function ll(i){return'href="'+qn(i)+'"'}function Ko(i){return'link[rel="stylesheet"]['+i+"]"}function kv(i){return y({},i,{"data-precedence":i.precedence,precedence:null})}function fN(i,r,a,u){i.querySelector('link[rel="preload"][as="style"]['+r+"]")?u.loading=1:(r=i.createElement("link"),u.preload=r,r.addEventListener("load",function(){return u.loading|=1}),r.addEventListener("error",function(){return u.loading|=2}),qe(r,"link",a),ke(r),i.head.appendChild(r))}function ol(i){return'[src="'+qn(i)+'"]'}function Po(i){return"script[async]"+i}function Uv(i,r,a){if(r.count++,r.instance===null)switch(r.type){case"style":var u=i.querySelector('style[data-href~="'+qn(a.href)+'"]');if(u)return r.instance=u,ke(u),u;var d=y({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return u=(i.ownerDocument||i).createElement("style"),ke(u),qe(u,"style",d),Qc(u,a.precedence,i),r.instance=u;case"stylesheet":d=ll(a.href);var g=i.querySelector(Ko(d));if(g)return r.state.loading|=4,r.instance=g,ke(g),g;u=kv(a),(d=Jn.get(d))&&np(u,d),g=(i.ownerDocument||i).createElement("link"),ke(g);var b=g;return b._p=new Promise(function(T,N){b.onload=T,b.onerror=N}),qe(g,"link",u),r.state.loading|=4,Qc(g,a.precedence,i),r.instance=g;case"script":return g=ol(a.src),(d=i.querySelector(Po(g)))?(r.instance=d,ke(d),d):(u=a,(d=Jn.get(g))&&(u=y({},a),ip(u,d)),i=i.ownerDocument||i,d=i.createElement("script"),ke(d),qe(d,"link",u),i.head.appendChild(d),r.instance=d);case"void":return null;default:throw Error(s(443,r.type))}else r.type==="stylesheet"&&(r.state.loading&4)===0&&(u=r.instance,r.state.loading|=4,Qc(u,a.precedence,i));return r.instance}function Qc(i,r,a){for(var u=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),d=u.length?u[u.length-1]:null,g=d,b=0;b<u.length;b++){var T=u[b];if(T.dataset.precedence===r)g=T;else if(g!==d)break}g?g.parentNode.insertBefore(i,g.nextSibling):(r=a.nodeType===9?a.head:a,r.insertBefore(i,r.firstChild))}function np(i,r){i.crossOrigin==null&&(i.crossOrigin=r.crossOrigin),i.referrerPolicy==null&&(i.referrerPolicy=r.referrerPolicy),i.title==null&&(i.title=r.title)}function ip(i,r){i.crossOrigin==null&&(i.crossOrigin=r.crossOrigin),i.referrerPolicy==null&&(i.referrerPolicy=r.referrerPolicy),i.integrity==null&&(i.integrity=r.integrity)}var Jc=null;function zv(i,r,a){if(Jc===null){var u=new Map,d=Jc=new Map;d.set(a,u)}else d=Jc,u=d.get(a),u||(u=new Map,d.set(a,u));if(u.has(i))return u;for(u.set(i,null),a=a.getElementsByTagName(i),d=0;d<a.length;d++){var g=a[d];if(!(g[so]||g[Qe]||i==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var b=g.getAttribute(r)||"";b=i+b;var T=u.get(b);T?T.push(g):u.set(b,[g])}}return u}function $v(i,r,a){i=i.ownerDocument||i,i.head.insertBefore(a,r==="title"?i.querySelector("head > title"):null)}function dN(i,r,a){if(a===1||r.itemProp!=null)return!1;switch(i){case"meta":case"title":return!0;case"style":if(typeof r.precedence!="string"||typeof r.href!="string"||r.href==="")break;return!0;case"link":if(typeof r.rel!="string"||typeof r.href!="string"||r.href===""||r.onLoad||r.onError)break;switch(r.rel){case"stylesheet":return i=r.disabled,typeof r.precedence=="string"&&i==null;default:return!0}case"script":if(r.async&&typeof r.async!="function"&&typeof r.async!="symbol"&&!r.onLoad&&!r.onError&&r.src&&typeof r.src=="string")return!0}return!1}function jv(i){return!(i.type==="stylesheet"&&(i.state.loading&3)===0)}var Go=null;function hN(){}function gN(i,r,a){if(Go===null)throw Error(s(475));var u=Go;if(r.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(r.state.loading&4)===0){if(r.instance===null){var d=ll(a.href),g=i.querySelector(Ko(d));if(g){i=g._p,i!==null&&typeof i=="object"&&typeof i.then=="function"&&(u.count++,u=Wc.bind(u),i.then(u,u)),r.state.loading|=4,r.instance=g,ke(g);return}g=i.ownerDocument||i,a=kv(a),(d=Jn.get(d))&&np(a,d),g=g.createElement("link"),ke(g);var b=g;b._p=new Promise(function(T,N){b.onload=T,b.onerror=N}),qe(g,"link",a),r.instance=g}u.stylesheets===null&&(u.stylesheets=new Map),u.stylesheets.set(r,i),(i=r.state.preload)&&(r.state.loading&3)===0&&(u.count++,r=Wc.bind(u),i.addEventListener("load",r),i.addEventListener("error",r))}}function pN(){if(Go===null)throw Error(s(475));var i=Go;return i.stylesheets&&i.count===0&&rp(i,i.stylesheets),0<i.count?function(r){var a=setTimeout(function(){if(i.stylesheets&&rp(i,i.stylesheets),i.unsuspend){var u=i.unsuspend;i.unsuspend=null,u()}},6e4);return i.unsuspend=r,function(){i.unsuspend=null,clearTimeout(a)}}:null}function Wc(){if(this.count--,this.count===0){if(this.stylesheets)rp(this,this.stylesheets);else if(this.unsuspend){var i=this.unsuspend;this.unsuspend=null,i()}}}var tf=null;function rp(i,r){i.stylesheets=null,i.unsuspend!==null&&(i.count++,tf=new Map,r.forEach(yN,i),tf=null,Wc.call(i))}function yN(i,r){if(!(r.state.loading&4)){var a=tf.get(i);if(a)var u=a.get(null);else{a=new Map,tf.set(i,a);for(var d=i.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<d.length;g++){var b=d[g];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(a.set(b.dataset.precedence,b),u=b)}u&&a.set(null,u)}d=r.instance,b=d.getAttribute("data-precedence"),g=a.get(b)||u,g===u&&a.set(null,d),a.set(b,d),this.count++,u=Wc.bind(this),d.addEventListener("load",u),d.addEventListener("error",u),g?g.parentNode.insertBefore(d,g.nextSibling):(i=i.nodeType===9?i.head:i,i.insertBefore(d,i.firstChild)),r.state.loading|=4}}var Zo={$$typeof:E,Provider:null,Consumer:null,_currentValue:it,_currentValue2:it,_threadCount:0};function mN(i,r,a,u,d,g,b,T){this.tag=1,this.containerInfo=i,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=th(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=th(0),this.hiddenUpdates=th(null),this.identifierPrefix=u,this.onUncaughtError=d,this.onCaughtError=g,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=T,this.incompleteTransitions=new Map}function Vv(i,r,a,u,d,g,b,T,N,$,q,P){return i=new mN(i,r,a,b,T,N,$,P),r=1,g===!0&&(r|=24),g=Nn(3,null,null,r),i.current=g,g.stateNode=i,r=zh(),r.refCount++,i.pooledCache=r,r.refCount++,g.memoizedState={element:u,isDehydrated:a,cache:r},Hh(g),i}function Hv(i){return i?(i=za,i):za}function Yv(i,r,a,u,d,g){d=Hv(d),u.context===null?u.context=d:u.pendingContext=d,u=Ur(r),u.payload={element:a},g=g===void 0?null:g,g!==null&&(u.callback=g),a=zr(i,u,r),a!==null&&(Rn(a,i,r),Ao(a,i,r))}function qv(i,r){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var a=i.retryLane;i.retryLane=a!==0&&a<r?a:r}}function sp(i,r){qv(i,r),(i=i.alternate)&&qv(i,r)}function Kv(i){if(i.tag===13){var r=Ua(i,67108864);r!==null&&Rn(r,i,67108864),sp(i,67108864)}}var ef=!0;function _N(i,r,a,u){var d=H.T;H.T=null;var g=Q.p;try{Q.p=2,ap(i,r,a,u)}finally{Q.p=g,H.T=d}}function bN(i,r,a,u){var d=H.T;H.T=null;var g=Q.p;try{Q.p=8,ap(i,r,a,u)}finally{Q.p=g,H.T=d}}function ap(i,r,a,u){if(ef){var d=lp(u);if(d===null)Pg(i,r,u,nf,a),Gv(i,u);else if(SN(d,i,r,a,u))u.stopPropagation();else if(Gv(i,u),r&4&&-1<vN.indexOf(i)){for(;d!==null;){var g=Ea(d);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var b=Os(g.pendingLanes);if(b!==0){var T=g;for(T.pendingLanes|=2,T.entangledLanes|=2;b;){var N=1<<31-En(b);T.entanglements[1]|=N,b&=~N}Ni(g),(ee&6)===0&&(zc=wi()+500,Vo(0))}}break;case 13:T=Ua(g,2),T!==null&&Rn(T,g,2),jc(),sp(g,2)}if(g=lp(u),g===null&&Pg(i,r,u,nf,a),g===d)break;d=g}d!==null&&u.stopPropagation()}else Pg(i,r,u,null,a)}}function lp(i){return i=dh(i),op(i)}var nf=null;function op(i){if(nf=null,i=Aa(i),i!==null){var r=o(i);if(r===null)i=null;else{var a=r.tag;if(a===13){if(i=c(r),i!==null)return i;i=null}else if(a===3){if(r.stateNode.current.memoizedState.isDehydrated)return r.tag===3?r.stateNode.containerInfo:null;i=null}else r!==i&&(i=null)}}return nf=i,null}function Pv(i){switch(i){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"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(sE()){case l_:return 2;case o_:return 8;case Gu:case aE:return 32;case u_:return 268435456;default:return 32}default:return 32}}var up=!1,Jr=null,Wr=null,ts=null,Xo=new Map,Qo=new Map,es=[],vN="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 Gv(i,r){switch(i){case"focusin":case"focusout":Jr=null;break;case"dragenter":case"dragleave":Wr=null;break;case"mouseover":case"mouseout":ts=null;break;case"pointerover":case"pointerout":Xo.delete(r.pointerId);break;case"gotpointercapture":case"lostpointercapture":Qo.delete(r.pointerId)}}function Jo(i,r,a,u,d,g){return i===null||i.nativeEvent!==g?(i={blockedOn:r,domEventName:a,eventSystemFlags:u,nativeEvent:g,targetContainers:[d]},r!==null&&(r=Ea(r),r!==null&&Kv(r)),i):(i.eventSystemFlags|=u,r=i.targetContainers,d!==null&&r.indexOf(d)===-1&&r.push(d),i)}function SN(i,r,a,u,d){switch(r){case"focusin":return Jr=Jo(Jr,i,r,a,u,d),!0;case"dragenter":return Wr=Jo(Wr,i,r,a,u,d),!0;case"mouseover":return ts=Jo(ts,i,r,a,u,d),!0;case"pointerover":var g=d.pointerId;return Xo.set(g,Jo(Xo.get(g)||null,i,r,a,u,d)),!0;case"gotpointercapture":return g=d.pointerId,Qo.set(g,Jo(Qo.get(g)||null,i,r,a,u,d)),!0}return!1}function Zv(i){var r=Aa(i.target);if(r!==null){var a=o(r);if(a!==null){if(r=a.tag,r===13){if(r=c(a),r!==null){i.blockedOn=r,gE(i.priority,function(){if(a.tag===13){var u=Bn();u=eh(u);var d=Ua(a,u);d!==null&&Rn(d,a,u),sp(a,u)}});return}}else if(r===3&&a.stateNode.current.memoizedState.isDehydrated){i.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}i.blockedOn=null}function rf(i){if(i.blockedOn!==null)return!1;for(var r=i.targetContainers;0<r.length;){var a=lp(i.nativeEvent);if(a===null){a=i.nativeEvent;var u=new a.constructor(a.type,a);fh=u,a.target.dispatchEvent(u),fh=null}else return r=Ea(a),r!==null&&Kv(r),i.blockedOn=a,!1;r.shift()}return!0}function Xv(i,r,a){rf(i)&&a.delete(r)}function TN(){up=!1,Jr!==null&&rf(Jr)&&(Jr=null),Wr!==null&&rf(Wr)&&(Wr=null),ts!==null&&rf(ts)&&(ts=null),Xo.forEach(Xv),Qo.forEach(Xv)}function sf(i,r){i.blockedOn===r&&(i.blockedOn=null,up||(up=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,TN)))}var af=null;function Qv(i){af!==i&&(af=i,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){af===i&&(af=null);for(var r=0;r<i.length;r+=3){var a=i[r],u=i[r+1],d=i[r+2];if(typeof u!="function"){if(op(u||a)===null)continue;break}var g=Ea(a);g!==null&&(i.splice(r,3),r-=3,og(g,{pending:!0,data:d,method:a.method,action:u},u,d))}}))}function Wo(i){function r(N){return sf(N,i)}Jr!==null&&sf(Jr,i),Wr!==null&&sf(Wr,i),ts!==null&&sf(ts,i),Xo.forEach(r),Qo.forEach(r);for(var a=0;a<es.length;a++){var u=es[a];u.blockedOn===i&&(u.blockedOn=null)}for(;0<es.length&&(a=es[0],a.blockedOn===null);)Zv(a),a.blockedOn===null&&es.shift();if(a=(i.ownerDocument||i).$$reactFormReplay,a!=null)for(u=0;u<a.length;u+=3){var d=a[u],g=a[u+1],b=d[cn]||null;if(typeof g=="function")b||Qv(a);else if(b){var T=null;if(g&&g.hasAttribute("formAction")){if(d=g,b=g[cn]||null)T=b.formAction;else if(op(d)!==null)continue}else T=b.action;typeof T=="function"?a[u+1]=T:(a.splice(u,3),u-=3),Qv(a)}}}function cp(i){this._internalRoot=i}lf.prototype.render=cp.prototype.render=function(i){var r=this._internalRoot;if(r===null)throw Error(s(409));var a=r.current,u=Bn();Yv(a,u,i,r,null,null)},lf.prototype.unmount=cp.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var r=i.containerInfo;Yv(i.current,2,null,i,null,null),jc(),r[xa]=null}};function lf(i){this._internalRoot=i}lf.prototype.unstable_scheduleHydration=function(i){if(i){var r=g_();i={blockedOn:null,target:i,priority:r};for(var a=0;a<es.length&&r!==0&&r<es[a].priority;a++);es.splice(a,0,i),a===0&&Zv(i)}};var Jv=t.version;if(Jv!=="19.1.0")throw Error(s(527,Jv,"19.1.0"));Q.findDOMNode=function(i){var r=i._reactInternals;if(r===void 0)throw typeof i.render=="function"?Error(s(188)):(i=Object.keys(i).join(","),Error(s(268,i)));return i=h(r),i=i!==null?p(i):null,i=i===null?null:i.stateNode,i};var wN={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:H,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var of=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!of.isDisabled&&of.supportsFiber)try{no=of.inject(wN),An=of}catch{}}return eu.createRoot=function(i,r){if(!l(i))throw Error(s(299));var a=!1,u="",d=gb,g=pb,b=yb,T=null;return r!=null&&(r.unstable_strictMode===!0&&(a=!0),r.identifierPrefix!==void 0&&(u=r.identifierPrefix),r.onUncaughtError!==void 0&&(d=r.onUncaughtError),r.onCaughtError!==void 0&&(g=r.onCaughtError),r.onRecoverableError!==void 0&&(b=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(T=r.unstable_transitionCallbacks)),r=Vv(i,1,!1,null,null,a,u,d,g,b,T,null),i[xa]=r.current,Kg(i),new cp(r)},eu.hydrateRoot=function(i,r,a){if(!l(i))throw Error(s(299));var u=!1,d="",g=gb,b=pb,T=yb,N=null,$=null;return a!=null&&(a.unstable_strictMode===!0&&(u=!0),a.identifierPrefix!==void 0&&(d=a.identifierPrefix),a.onUncaughtError!==void 0&&(g=a.onUncaughtError),a.onCaughtError!==void 0&&(b=a.onCaughtError),a.onRecoverableError!==void 0&&(T=a.onRecoverableError),a.unstable_transitionCallbacks!==void 0&&(N=a.unstable_transitionCallbacks),a.formState!==void 0&&($=a.formState)),r=Vv(i,1,!0,r,a??null,u,d,g,b,T,N,$),r.context=Hv(null),a=r.current,u=Bn(),u=eh(u),d=Ur(u),d.callback=null,zr(a,d,u),a=u,r.current.lanes=a,ro(r,a),Ni(r),i[xa]=r.current,Kg(i),new lf(r)},eu.version="19.1.0",eu}var uS;function FN(){if(uS)return hp.exports;uS=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(t){console.error(t)}}return n(),hp.exports=RN(),hp.exports}var LN=FN();const IN=zy(LN);var mp={exports:{}},Qt={};/** @license React v16.13.1
 * react-is.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var cS;function kN(){if(cS)return Qt;cS=1;var n=typeof Symbol=="function"&&Symbol.for,t=n?Symbol.for("react.element"):60103,e=n?Symbol.for("react.portal"):60106,s=n?Symbol.for("react.fragment"):60107,l=n?Symbol.for("react.strict_mode"):60108,o=n?Symbol.for("react.profiler"):60114,c=n?Symbol.for("react.provider"):60109,f=n?Symbol.for("react.context"):60110,h=n?Symbol.for("react.async_mode"):60111,p=n?Symbol.for("react.concurrent_mode"):60111,y=n?Symbol.for("react.forward_ref"):60112,m=n?Symbol.for("react.suspense"):60113,_=n?Symbol.for("react.suspense_list"):60120,S=n?Symbol.for("react.memo"):60115,v=n?Symbol.for("react.lazy"):60116,A=n?Symbol.for("react.block"):60121,x=n?Symbol.for("react.fundamental"):60117,C=n?Symbol.for("react.responder"):60118,w=n?Symbol.for("react.scope"):60119;function E(O){if(typeof O=="object"&&O!==null){var D=O.$$typeof;switch(D){case t:switch(O=O.type,O){case h:case p:case s:case o:case l:case m:return O;default:switch(O=O&&O.$$typeof,O){case f:case y:case v:case S:case c:return O;default:return D}}case e:return D}}}function M(O){return E(O)===p}return Qt.AsyncMode=h,Qt.ConcurrentMode=p,Qt.ContextConsumer=f,Qt.ContextProvider=c,Qt.Element=t,Qt.ForwardRef=y,Qt.Fragment=s,Qt.Lazy=v,Qt.Memo=S,Qt.Portal=e,Qt.Profiler=o,Qt.StrictMode=l,Qt.Suspense=m,Qt.isAsyncMode=function(O){return M(O)||E(O)===h},Qt.isConcurrentMode=M,Qt.isContextConsumer=function(O){return E(O)===f},Qt.isContextProvider=function(O){return E(O)===c},Qt.isElement=function(O){return typeof O=="object"&&O!==null&&O.$$typeof===t},Qt.isForwardRef=function(O){return E(O)===y},Qt.isFragment=function(O){return E(O)===s},Qt.isLazy=function(O){return E(O)===v},Qt.isMemo=function(O){return E(O)===S},Qt.isPortal=function(O){return E(O)===e},Qt.isProfiler=function(O){return E(O)===o},Qt.isStrictMode=function(O){return E(O)===l},Qt.isSuspense=function(O){return E(O)===m},Qt.isValidElementType=function(O){return typeof O=="string"||typeof O=="function"||O===s||O===p||O===o||O===l||O===m||O===_||typeof O=="object"&&O!==null&&(O.$$typeof===v||O.$$typeof===S||O.$$typeof===c||O.$$typeof===f||O.$$typeof===y||O.$$typeof===x||O.$$typeof===C||O.$$typeof===w||O.$$typeof===A)},Qt.typeOf=E,Qt}var fS;function UN(){return fS||(fS=1,mp.exports=kN()),mp.exports}var _p,dS;function zN(){if(dS)return _p;dS=1;var n=UN(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},e={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},s={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};o[n.ForwardRef]=s,o[n.Memo]=l;function c(v){return n.isMemo(v)?l:o[v.$$typeof]||t}var f=Object.defineProperty,h=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols,y=Object.getOwnPropertyDescriptor,m=Object.getPrototypeOf,_=Object.prototype;function S(v,A,x){if(typeof A!="string"){if(_){var C=m(A);C&&C!==_&&S(v,C,x)}var w=h(A);p&&(w=w.concat(p(A)));for(var E=c(v),M=c(A),O=0;O<w.length;++O){var D=w[O];if(!e[D]&&!(x&&x[D])&&!(M&&M[D])&&!(E&&E[D])){var I=y(A,D);try{f(v,D,I)}catch{}}}}return v}return _p=S,_p}var $N=zN();const jN=zy($N);function St(n,t,e,s){function l(o){return o instanceof e?o:new e(function(c){c(o)})}return new(e||(e=Promise))(function(o,c){function f(y){try{p(s.next(y))}catch(m){c(m)}}function h(y){try{p(s.throw(y))}catch(m){c(m)}}function p(y){y.done?o(y.value):l(y.value).then(f,h)}p((s=s.apply(n,t||[])).next())})}function hS(n){var t=typeof Symbol=="function"&&Symbol.iterator,e=t&&n[t],s=0;if(e)return e.call(n);if(n&&typeof n.length=="number")return{next:function(){return n&&s>=n.length&&(n=void 0),{value:n&&n[s++],done:!n}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ft(n){return this instanceof Ft?(this.v=n,this):new Ft(n)}function Vi(n,t,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=e.apply(n,t||[]),l,o=[];return l={},f("next"),f("throw"),f("return",c),l[Symbol.asyncIterator]=function(){return this},l;function c(S){return function(v){return Promise.resolve(v).then(S,m)}}function f(S,v){s[S]&&(l[S]=function(A){return new Promise(function(x,C){o.push([S,A,x,C])>1||h(S,A)})},v&&(l[S]=v(l[S])))}function h(S,v){try{p(s[S](v))}catch(A){_(o[0][3],A)}}function p(S){S.value instanceof Ft?Promise.resolve(S.value.v).then(y,m):_(o[0][2],S)}function y(S){h("next",S)}function m(S){h("throw",S)}function _(S,v){S(v),o.shift(),o.length&&h(o[0][0],o[0][1])}}function Tf(n){var t,e;return t={},s("next"),s("throw",function(l){throw l}),s("return"),t[Symbol.iterator]=function(){return this},t;function s(l,o){t[l]=n[l]?function(c){return(e=!e)?{value:Ft(n[l](c)),done:!1}:o?o(c):c}:o}}function sa(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=n[Symbol.asyncIterator],e;return t?t.call(n):(n=typeof hS=="function"?hS(n):n[Symbol.iterator](),e={},s("next"),s("throw"),s("return"),e[Symbol.asyncIterator]=function(){return this},e);function s(o){e[o]=n[o]&&function(c){return new Promise(function(f,h){c=n[o](c),l(f,h,c.done,c.value)})}}function l(o,c,f,h){Promise.resolve(h).then(function(p){o({value:p,done:f})},c)}}const VN=new TextDecoder("utf-8"),Kp=n=>VN.decode(n),HN=new TextEncoder,jy=n=>HN.encode(n),[R3,YN]=(()=>{const n=()=>{throw new Error("BigInt is not available in this environment")};function t(){throw n()}return t.asIntN=()=>{throw n()},t.asUintN=()=>{throw n()},typeof BigInt<"u"?[BigInt,!0]:[t,!1]})(),[Ru,F3]=(()=>{const n=()=>{throw new Error("BigInt64Array is not available in this environment")};class t{static get BYTES_PER_ELEMENT(){return 8}static of(){throw n()}static from(){throw n()}constructor(){throw n()}}return typeof BigInt64Array<"u"?[BigInt64Array,!0]:[t,!1]})(),[Fu,L3]=(()=>{const n=()=>{throw new Error("BigUint64Array is not available in this environment")};class t{static get BYTES_PER_ELEMENT(){return 8}static of(){throw n()}static from(){throw n()}constructor(){throw n()}}return typeof BigUint64Array<"u"?[BigUint64Array,!0]:[t,!1]})(),qN=n=>typeof n=="number",wT=n=>typeof n=="boolean",Fe=n=>typeof n=="function",Tn=n=>n!=null&&Object(n)===n,fs=n=>Tn(n)&&Fe(n.then),Lu=n=>Tn(n)&&Fe(n[Symbol.iterator]),Yl=n=>Tn(n)&&Fe(n[Symbol.asyncIterator]),Pp=n=>Tn(n)&&Tn(n.schema),xT=n=>Tn(n)&&"done"in n&&"value"in n,AT=n=>Tn(n)&&Fe(n.stat)&&qN(n.fd),ET=n=>Tn(n)&&Vy(n.body),Md=n=>"_getDOMStream"in n&&"_getNodeStream"in n,KN=n=>Tn(n)&&Fe(n.abort)&&Fe(n.getWriter)&&!Md(n),Vy=n=>Tn(n)&&Fe(n.cancel)&&Fe(n.getReader)&&!Md(n),PN=n=>Tn(n)&&Fe(n.end)&&Fe(n.write)&&wT(n.writable)&&!Md(n),OT=n=>Tn(n)&&Fe(n.read)&&Fe(n.pipe)&&wT(n.readable)&&!Md(n),GN=n=>Tn(n)&&Fe(n.clear)&&Fe(n.bytes)&&Fe(n.position)&&Fe(n.setPosition)&&Fe(n.capacity)&&Fe(n.getBufferIdentifier)&&Fe(n.createLong),Hy=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:ArrayBuffer;function ZN(n){const t=n[0]?[n[0]]:[];let e,s,l,o;for(let c,f,h=0,p=0,y=n.length;++h<y;){if(c=t[p],f=n[h],!c||!f||c.buffer!==f.buffer||f.byteOffset<c.byteOffset){f&&(t[++p]=f);continue}if({byteOffset:e,byteLength:l}=c,{byteOffset:s,byteLength:o}=f,e+l<s||s+o<e){f&&(t[++p]=f);continue}t[p]=new Uint8Array(c.buffer,e,s-e+o)}return t}function gS(n,t,e=0,s=t.byteLength){const l=n.byteLength,o=new Uint8Array(n.buffer,n.byteOffset,l),c=new Uint8Array(t.buffer,t.byteOffset,Math.min(s,l));return o.set(c,e),n}function qi(n,t){const e=ZN(n),s=e.reduce((y,m)=>y+m.byteLength,0);let l,o,c,f=0,h=-1;const p=Math.min(t||Number.POSITIVE_INFINITY,s);for(const y=e.length;++h<y;){if(l=e[h],o=l.subarray(0,Math.min(l.length,p-f)),p<=f+o.length){o.length<l.length?e[h]=l.subarray(o.length):o.length===l.length&&h++,c?gS(c,o,f):c=o;break}gS(c||(c=new Uint8Array(p)),o,f),f+=o.length}return[c||new Uint8Array(0),e.slice(h),s-(c?c.byteLength:0)]}function ue(n,t){let e=xT(t)?t.value:t;return e instanceof n?n===Uint8Array?new n(e.buffer,e.byteOffset,e.byteLength):e:e?(typeof e=="string"&&(e=jy(e)),e instanceof ArrayBuffer?new n(e):e instanceof Hy?new n(e):GN(e)?ue(n,e.bytes()):ArrayBuffer.isView(e)?e.byteLength<=0?new n(0):new n(e.buffer,e.byteOffset,e.byteLength/n.BYTES_PER_ELEMENT):n.from(e)):new n(0)}const nu=n=>ue(Int32Array,n),Zt=n=>ue(Uint8Array,n),Gp=n=>(n.next(),n);function*XN(n,t){const e=function*(l){yield l},s=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof Hy?e(t):Lu(t)?t:e(t);return yield*Gp(function*(l){let o=null;do o=l.next(yield ue(n,o));while(!o.done)}(s[Symbol.iterator]())),new n}const QN=n=>XN(Uint8Array,n);function NT(n,t){return Vi(this,arguments,function*(){if(fs(t))return yield Ft(yield Ft(yield*Tf(sa(NT(n,yield Ft(t))))));const s=function(c){return Vi(this,arguments,function*(){yield yield Ft(yield Ft(c))})},l=function(c){return Vi(this,arguments,function*(){yield Ft(yield*Tf(sa(Gp(function*(f){let h=null;do h=f.next(yield h==null?void 0:h.value);while(!h.done)}(c[Symbol.iterator]())))))})},o=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof Hy?s(t):Lu(t)?l(t):Yl(t)?t:s(t);return yield Ft(yield*Tf(sa(Gp(function(c){return Vi(this,arguments,function*(){let f=null;do f=yield Ft(c.next(yield yield Ft(ue(n,f))));while(!f.done)})}(o[Symbol.asyncIterator]()))))),yield Ft(new n)})}const JN=n=>NT(Uint8Array,n);function Yy(n,t,e){if(n!==0){e=e.slice(0,t+1);for(let s=-1;++s<=t;)e[s]+=n}return e}function WN(n,t){let e=0;const s=n.length;if(s!==t.length)return!1;if(s>0)do if(n[e]!==t[e])return!1;while(++e<s);return!0}const ei={fromIterable(n){return uf(tC(n))},fromAsyncIterable(n){return uf(eC(n))},fromDOMStream(n){return uf(nC(n))},fromNodeStream(n){return uf(rC(n))},toDOMStream(n,t){throw new Error('"toDOMStream" not available in this environment')},toNodeStream(n,t){throw new Error('"toNodeStream" not available in this environment')}},uf=n=>(n.next(),n);function*tC(n){let t,e=!1,s=[],l,o,c,f=0;function h(){return o==="peek"?qi(s,c)[0]:([l,s,f]=qi(s,c),l)}({cmd:o,size:c}=yield null);const p=QN(n)[Symbol.iterator]();try{do if({done:t,value:l}=Number.isNaN(c-f)?p.next():p.next(c-f),!t&&l.byteLength>0&&(s.push(l),f+=l.byteLength),t||c<=f)do({cmd:o,size:c}=yield h());while(c<f);while(!t)}catch(y){(e=!0)&&typeof p.throw=="function"&&p.throw(y)}finally{e===!1&&typeof p.return=="function"&&p.return(null)}return null}function eC(n){return Vi(this,arguments,function*(){let e,s=!1,l=[],o,c,f,h=0;function p(){return c==="peek"?qi(l,f)[0]:([o,l,h]=qi(l,f),o)}({cmd:c,size:f}=yield yield Ft(null));const y=JN(n)[Symbol.asyncIterator]();try{do if({done:e,value:o}=Number.isNaN(f-h)?yield Ft(y.next()):yield Ft(y.next(f-h)),!e&&o.byteLength>0&&(l.push(o),h+=o.byteLength),e||f<=h)do({cmd:c,size:f}=yield yield Ft(p()));while(f<h);while(!e)}catch(m){(s=!0)&&typeof y.throw=="function"&&(yield Ft(y.throw(m)))}finally{s===!1&&typeof y.return=="function"&&(yield Ft(y.return(new Uint8Array(0))))}return yield Ft(null)})}function nC(n){return Vi(this,arguments,function*(){let e=!1,s=!1,l=[],o,c,f,h=0;function p(){return c==="peek"?qi(l,f)[0]:([o,l,h]=qi(l,f),o)}({cmd:c,size:f}=yield yield Ft(null));const y=new iC(n);try{do if({done:e,value:o}=Number.isNaN(f-h)?yield Ft(y.read()):yield Ft(y.read(f-h)),!e&&o.byteLength>0&&(l.push(Zt(o)),h+=o.byteLength),e||f<=h)do({cmd:c,size:f}=yield yield Ft(p()));while(f<h);while(!e)}catch(m){(s=!0)&&(yield Ft(y.cancel(m)))}finally{s===!1?yield Ft(y.cancel()):n.locked&&y.releaseLock()}return yield Ft(null)})}class iC{constructor(t){this.source=t,this.reader=null,this.reader=this.source.getReader(),this.reader.closed.catch(()=>{})}get closed(){return this.reader?this.reader.closed.catch(()=>{}):Promise.resolve()}releaseLock(){this.reader&&this.reader.releaseLock(),this.reader=null}cancel(t){return St(this,void 0,void 0,function*(){const{reader:e,source:s}=this;e&&(yield e.cancel(t).catch(()=>{})),s&&s.locked&&this.releaseLock()})}read(t){return St(this,void 0,void 0,function*(){if(t===0)return{done:this.reader==null,value:new Uint8Array(0)};const e=yield this.reader.read();return!e.done&&(e.value=Zt(e)),e})}}const bp=(n,t)=>{const e=l=>s([t,l]);let s;return[t,e,new Promise(l=>(s=l)&&n.once(t,e))]};function rC(n){return Vi(this,arguments,function*(){const e=[];let s="error",l=!1,o=null,c,f,h=0,p=[],y;function m(){return c==="peek"?qi(p,f)[0]:([y,p,h]=qi(p,f),y)}if({cmd:c,size:f}=yield yield Ft(null),n.isTTY)return yield yield Ft(new Uint8Array(0)),yield Ft(null);try{e[0]=bp(n,"end"),e[1]=bp(n,"error");do{if(e[2]=bp(n,"readable"),[s,o]=yield Ft(Promise.race(e.map(S=>S[2]))),s==="error")break;if((l=s==="end")||(Number.isFinite(f-h)?(y=Zt(n.read(f-h)),y.byteLength<f-h&&(y=Zt(n.read()))):y=Zt(n.read()),y.byteLength>0&&(p.push(y),h+=y.byteLength)),l||f<=h)do({cmd:c,size:f}=yield yield Ft(m()));while(f<h)}while(!l)}finally{yield Ft(_(e,s==="error"?o:null))}return yield Ft(null);function _(S,v){return y=p=null,new Promise((A,x)=>{for(const[C,w]of S)n.off(C,w);try{const C=n.destroy;C&&C.call(n,v),v=void 0}catch(C){v=C||v}finally{v!=null?x(v):A()}})}})}var kn;(function(n){n[n.V1=0]="V1",n[n.V2=1]="V2",n[n.V3=2]="V3",n[n.V4=3]="V4",n[n.V5=4]="V5"})(kn||(kn={}));var Un;(function(n){n[n.Sparse=0]="Sparse",n[n.Dense=1]="Dense"})(Un||(Un={}));var bn;(function(n){n[n.HALF=0]="HALF",n[n.SINGLE=1]="SINGLE",n[n.DOUBLE=2]="DOUBLE"})(bn||(bn={}));var Or;(function(n){n[n.DAY=0]="DAY",n[n.MILLISECOND=1]="MILLISECOND"})(Or||(Or={}));var Xt;(function(n){n[n.SECOND=0]="SECOND",n[n.MILLISECOND=1]="MILLISECOND",n[n.MICROSECOND=2]="MICROSECOND",n[n.NANOSECOND=3]="NANOSECOND"})(Xt||(Xt={}));var ds;(function(n){n[n.YEAR_MONTH=0]="YEAR_MONTH",n[n.DAY_TIME=1]="DAY_TIME",n[n.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"})(ds||(ds={}));var Jt;(function(n){n[n.NONE=0]="NONE",n[n.Schema=1]="Schema",n[n.DictionaryBatch=2]="DictionaryBatch",n[n.RecordBatch=3]="RecordBatch",n[n.Tensor=4]="Tensor",n[n.SparseTensor=5]="SparseTensor"})(Jt||(Jt={}));var k;(function(n){n[n.NONE=0]="NONE",n[n.Null=1]="Null",n[n.Int=2]="Int",n[n.Float=3]="Float",n[n.Binary=4]="Binary",n[n.Utf8=5]="Utf8",n[n.Bool=6]="Bool",n[n.Decimal=7]="Decimal",n[n.Date=8]="Date",n[n.Time=9]="Time",n[n.Timestamp=10]="Timestamp",n[n.Interval=11]="Interval",n[n.List=12]="List",n[n.Struct=13]="Struct",n[n.Union=14]="Union",n[n.FixedSizeBinary=15]="FixedSizeBinary",n[n.FixedSizeList=16]="FixedSizeList",n[n.Map=17]="Map",n[n.Dictionary=-1]="Dictionary",n[n.Int8=-2]="Int8",n[n.Int16=-3]="Int16",n[n.Int32=-4]="Int32",n[n.Int64=-5]="Int64",n[n.Uint8=-6]="Uint8",n[n.Uint16=-7]="Uint16",n[n.Uint32=-8]="Uint32",n[n.Uint64=-9]="Uint64",n[n.Float16=-10]="Float16",n[n.Float32=-11]="Float32",n[n.Float64=-12]="Float64",n[n.DateDay=-13]="DateDay",n[n.DateMillisecond=-14]="DateMillisecond",n[n.TimestampSecond=-15]="TimestampSecond",n[n.TimestampMillisecond=-16]="TimestampMillisecond",n[n.TimestampMicrosecond=-17]="TimestampMicrosecond",n[n.TimestampNanosecond=-18]="TimestampNanosecond",n[n.TimeSecond=-19]="TimeSecond",n[n.TimeMillisecond=-20]="TimeMillisecond",n[n.TimeMicrosecond=-21]="TimeMicrosecond",n[n.TimeNanosecond=-22]="TimeNanosecond",n[n.DenseUnion=-23]="DenseUnion",n[n.SparseUnion=-24]="SparseUnion",n[n.IntervalDayTime=-25]="IntervalDayTime",n[n.IntervalYearMonth=-26]="IntervalYearMonth"})(k||(k={}));var pr;(function(n){n[n.OFFSET=0]="OFFSET",n[n.DATA=1]="DATA",n[n.VALIDITY=2]="VALIDITY",n[n.TYPE=3]="TYPE"})(pr||(pr={}));const sC=void 0;function _u(n){if(n===null)return"null";if(n===sC)return"undefined";switch(typeof n){case"number":return`${n}`;case"bigint":return`${n}`;case"string":return`"${n}"`}return typeof n[Symbol.toPrimitive]=="function"?n[Symbol.toPrimitive]("string"):ArrayBuffer.isView(n)?n instanceof Ru||n instanceof Fu?`[${[...n].map(t=>_u(t))}]`:`[${n}]`:ArrayBuffer.isView(n)?`[${n}]`:JSON.stringify(n,(t,e)=>typeof e=="bigint"?`${e}`:e)}const aC=Symbol.for("isArrowBigNum");function vi(n,...t){return t.length===0?Object.setPrototypeOf(ue(this.TypedArray,n),this.constructor.prototype):Object.setPrototypeOf(new this.TypedArray(n,...t),this.constructor.prototype)}vi.prototype[aC]=!0;vi.prototype.toJSON=function(){return`"${aa(this)}"`};vi.prototype.valueOf=function(){return CT(this)};vi.prototype.toString=function(){return aa(this)};vi.prototype[Symbol.toPrimitive]=function(n="default"){switch(n){case"number":return CT(this);case"string":return aa(this);case"default":return Zp(this)}return aa(this)};function vl(...n){return vi.apply(this,n)}function Sl(...n){return vi.apply(this,n)}function bu(...n){return vi.apply(this,n)}Object.setPrototypeOf(vl.prototype,Object.create(Int32Array.prototype));Object.setPrototypeOf(Sl.prototype,Object.create(Uint32Array.prototype));Object.setPrototypeOf(bu.prototype,Object.create(Uint32Array.prototype));Object.assign(vl.prototype,vi.prototype,{constructor:vl,signed:!0,TypedArray:Int32Array,BigIntArray:Ru});Object.assign(Sl.prototype,vi.prototype,{constructor:Sl,signed:!1,TypedArray:Uint32Array,BigIntArray:Fu});Object.assign(bu.prototype,vi.prototype,{constructor:bu,signed:!0,TypedArray:Uint32Array,BigIntArray:Fu});function CT(n){const{buffer:t,byteOffset:e,length:s,signed:l}=n,o=new Fu(t,e,s),c=l&&o[o.length-1]&BigInt(1)<<BigInt(63);let f=BigInt(c?1:0),h=BigInt(0);if(c){for(const p of o)f+=~p*(BigInt(1)<<BigInt(32)*h++);f*=BigInt(-1)}else for(const p of o)f+=p*(BigInt(1)<<BigInt(32)*h++);return f}let aa,Zp;YN?(Zp=n=>n.byteLength===8?new n.BigIntArray(n.buffer,n.byteOffset,1)[0]:vp(n),aa=n=>n.byteLength===8?`${new n.BigIntArray(n.buffer,n.byteOffset,1)[0]}`:vp(n)):(aa=vp,Zp=aa);function vp(n){let t="";const e=new Uint32Array(2);let s=new Uint16Array(n.buffer,n.byteOffset,n.byteLength/2);const l=new Uint32Array((s=new Uint16Array(s).reverse()).buffer);let o=-1;const c=s.length-1;do{for(e[0]=s[o=0];o<c;)s[o++]=e[1]=e[0]/10,e[0]=(e[0]-e[1]*10<<16)+s[o];s[o]=e[1]=e[0]/10,e[0]=e[0]-e[1]*10,t=`${e[0]}${t}`}while(l[0]||l[1]||l[2]||l[3]);return t??"0"}class qy{static new(t,e){switch(e){case!0:return new vl(t);case!1:return new Sl(t)}switch(t.constructor){case Int8Array:case Int16Array:case Int32Array:case Ru:return new vl(t)}return t.byteLength===16?new bu(t):new Sl(t)}static signed(t){return new vl(t)}static unsigned(t){return new Sl(t)}static decimal(t){return new bu(t)}constructor(t,e){return qy.new(t,e)}}var DT,MT,BT,RT,FT,LT,IT,kT,UT,zT,$T,jT,VT,HT,YT,qT,KT,PT,GT;class wt{static isNull(t){return(t==null?void 0:t.typeId)===k.Null}static isInt(t){return(t==null?void 0:t.typeId)===k.Int}static isFloat(t){return(t==null?void 0:t.typeId)===k.Float}static isBinary(t){return(t==null?void 0:t.typeId)===k.Binary}static isUtf8(t){return(t==null?void 0:t.typeId)===k.Utf8}static isBool(t){return(t==null?void 0:t.typeId)===k.Bool}static isDecimal(t){return(t==null?void 0:t.typeId)===k.Decimal}static isDate(t){return(t==null?void 0:t.typeId)===k.Date}static isTime(t){return(t==null?void 0:t.typeId)===k.Time}static isTimestamp(t){return(t==null?void 0:t.typeId)===k.Timestamp}static isInterval(t){return(t==null?void 0:t.typeId)===k.Interval}static isList(t){return(t==null?void 0:t.typeId)===k.List}static isStruct(t){return(t==null?void 0:t.typeId)===k.Struct}static isUnion(t){return(t==null?void 0:t.typeId)===k.Union}static isFixedSizeBinary(t){return(t==null?void 0:t.typeId)===k.FixedSizeBinary}static isFixedSizeList(t){return(t==null?void 0:t.typeId)===k.FixedSizeList}static isMap(t){return(t==null?void 0:t.typeId)===k.Map}static isDictionary(t){return(t==null?void 0:t.typeId)===k.Dictionary}static isDenseUnion(t){return wt.isUnion(t)&&t.mode===Un.Dense}static isSparseUnion(t){return wt.isUnion(t)&&t.mode===Un.Sparse}get typeId(){return k.NONE}}DT=Symbol.toStringTag;wt[DT]=(n=>(n.children=null,n.ArrayType=Array,n[Symbol.toStringTag]="DataType"))(wt.prototype);let hs=class extends wt{toString(){return"Null"}get typeId(){return k.Null}};MT=Symbol.toStringTag;hs[MT]=(n=>n[Symbol.toStringTag]="Null")(hs.prototype);class gs extends wt{constructor(t,e){super(),this.isSigned=t,this.bitWidth=e}get typeId(){return k.Int}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array;case 16:return this.isSigned?Int16Array:Uint16Array;case 32:return this.isSigned?Int32Array:Uint32Array;case 64:return this.isSigned?Ru:Fu}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}BT=Symbol.toStringTag;gs[BT]=(n=>(n.isSigned=null,n.bitWidth=null,n[Symbol.toStringTag]="Int"))(gs.prototype);class vu extends gs{constructor(){super(!0,32)}get ArrayType(){return Int32Array}}Object.defineProperty(vu.prototype,"ArrayType",{value:Int32Array});class Su extends wt{constructor(t){super(),this.precision=t}get typeId(){return k.Float}get ArrayType(){switch(this.precision){case bn.HALF:return Uint16Array;case bn.SINGLE:return Float32Array;case bn.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}RT=Symbol.toStringTag;Su[RT]=(n=>(n.precision=null,n[Symbol.toStringTag]="Float"))(Su.prototype);let Ff=class extends wt{constructor(){super()}get typeId(){return k.Binary}toString(){return"Binary"}};FT=Symbol.toStringTag;Ff[FT]=(n=>(n.ArrayType=Uint8Array,n[Symbol.toStringTag]="Binary"))(Ff.prototype);let Lf=class extends wt{constructor(){super()}get typeId(){return k.Utf8}toString(){return"Utf8"}};LT=Symbol.toStringTag;Lf[LT]=(n=>(n.ArrayType=Uint8Array,n[Symbol.toStringTag]="Utf8"))(Lf.prototype);let If=class extends wt{constructor(){super()}get typeId(){return k.Bool}toString(){return"Bool"}};IT=Symbol.toStringTag;If[IT]=(n=>(n.ArrayType=Uint8Array,n[Symbol.toStringTag]="Bool"))(If.prototype);let kf=class extends wt{constructor(t,e,s=128){super(),this.scale=t,this.precision=e,this.bitWidth=s}get typeId(){return k.Decimal}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}};kT=Symbol.toStringTag;kf[kT]=(n=>(n.scale=null,n.precision=null,n.ArrayType=Uint32Array,n[Symbol.toStringTag]="Decimal"))(kf.prototype);class Uf extends wt{constructor(t){super(),this.unit=t}get typeId(){return k.Date}toString(){return`Date${(this.unit+1)*32}<${Or[this.unit]}>`}}UT=Symbol.toStringTag;Uf[UT]=(n=>(n.unit=null,n.ArrayType=Int32Array,n[Symbol.toStringTag]="Date"))(Uf.prototype);class Tu extends wt{constructor(t,e){super(),this.unit=t,this.bitWidth=e}get typeId(){return k.Time}toString(){return`Time${this.bitWidth}<${Xt[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array;case 64:return Ru}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}zT=Symbol.toStringTag;Tu[zT]=(n=>(n.unit=null,n.bitWidth=null,n[Symbol.toStringTag]="Time"))(Tu.prototype);class zf extends wt{constructor(t,e){super(),this.unit=t,this.timezone=e}get typeId(){return k.Timestamp}toString(){return`Timestamp<${Xt[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}$T=Symbol.toStringTag;zf[$T]=(n=>(n.unit=null,n.timezone=null,n.ArrayType=Int32Array,n[Symbol.toStringTag]="Timestamp"))(zf.prototype);class $f extends wt{constructor(t){super(),this.unit=t}get typeId(){return k.Interval}toString(){return`Interval<${ds[this.unit]}>`}}jT=Symbol.toStringTag;$f[jT]=(n=>(n.unit=null,n.ArrayType=Int32Array,n[Symbol.toStringTag]="Interval"))($f.prototype);let jf=class extends wt{constructor(t){super(),this.children=[t]}get typeId(){return k.List}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}};VT=Symbol.toStringTag;jf[VT]=(n=>(n.children=null,n[Symbol.toStringTag]="List"))(jf.prototype);class sn extends wt{constructor(t){super(),this.children=t}get typeId(){return k.Struct}toString(){return`Struct<{${this.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}HT=Symbol.toStringTag;sn[HT]=(n=>(n.children=null,n[Symbol.toStringTag]="Struct"))(sn.prototype);class Vf extends wt{constructor(t,e,s){super(),this.mode=t,this.children=s,this.typeIds=e=Int32Array.from(e),this.typeIdToChildIndex=e.reduce((l,o,c)=>(l[o]=c)&&l||l,Object.create(null))}get typeId(){return k.Union}toString(){return`${this[Symbol.toStringTag]}<${this.children.map(t=>`${t.type}`).join(" | ")}>`}}YT=Symbol.toStringTag;Vf[YT]=(n=>(n.mode=null,n.typeIds=null,n.children=null,n.typeIdToChildIndex=null,n.ArrayType=Int8Array,n[Symbol.toStringTag]="Union"))(Vf.prototype);let Hf=class extends wt{constructor(t){super(),this.byteWidth=t}get typeId(){return k.FixedSizeBinary}toString(){return`FixedSizeBinary[${this.byteWidth}]`}};qT=Symbol.toStringTag;Hf[qT]=(n=>(n.byteWidth=null,n.ArrayType=Uint8Array,n[Symbol.toStringTag]="FixedSizeBinary"))(Hf.prototype);let Yf=class extends wt{constructor(t,e){super(),this.listSize=t,this.children=[e]}get typeId(){return k.FixedSizeList}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}};KT=Symbol.toStringTag;Yf[KT]=(n=>(n.children=null,n.listSize=null,n[Symbol.toStringTag]="FixedSizeList"))(Yf.prototype);class qf extends wt{constructor(t,e=!1){super(),this.children=[t],this.keysSorted=e}get typeId(){return k.Map}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}PT=Symbol.toStringTag;qf[PT]=(n=>(n.children=null,n.keysSorted=null,n[Symbol.toStringTag]="Map_"))(qf.prototype);const lC=(n=>()=>++n)(-1);class Dl extends wt{constructor(t,e,s,l){super(),this.indices=e,this.dictionary=t,this.isOrdered=l||!1,this.id=s==null?lC():typeof s=="number"?s:s.low}get typeId(){return k.Dictionary}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}GT=Symbol.toStringTag;Dl[GT]=(n=>(n.id=null,n.indices=null,n.isOrdered=null,n.dictionary=null,n[Symbol.toStringTag]="Dictionary"))(Dl.prototype);function yr(n){const t=n;switch(n.typeId){case k.Decimal:return n.bitWidth/32;case k.Timestamp:return 2;case k.Date:return 1+t.unit;case k.Interval:return 1+t.unit;case k.FixedSizeList:return t.listSize;case k.FixedSizeBinary:return t.byteWidth;default:return 1}}class jt{visitMany(t,...e){return t.map((s,l)=>this.visit(s,...e.map(o=>o[l])))}visit(...t){return this.getVisitFn(t[0],!1).apply(this,t)}getVisitFn(t,e=!0){return oC(this,t,e)}getVisitFnByTypeId(t,e=!0){return dl(this,t,e)}visitNull(t,...e){return null}visitBool(t,...e){return null}visitInt(t,...e){return null}visitFloat(t,...e){return null}visitUtf8(t,...e){return null}visitBinary(t,...e){return null}visitFixedSizeBinary(t,...e){return null}visitDate(t,...e){return null}visitTimestamp(t,...e){return null}visitTime(t,...e){return null}visitDecimal(t,...e){return null}visitList(t,...e){return null}visitStruct(t,...e){return null}visitUnion(t,...e){return null}visitDictionary(t,...e){return null}visitInterval(t,...e){return null}visitFixedSizeList(t,...e){return null}visitMap(t,...e){return null}}function oC(n,t,e=!0){return typeof t=="number"?dl(n,t,e):typeof t=="string"&&t in k?dl(n,k[t],e):t&&t instanceof wt?dl(n,pS(t),e):t!=null&&t.type&&t.type instanceof wt?dl(n,pS(t.type),e):dl(n,k.NONE,e)}function dl(n,t,e=!0){let s=null;switch(t){case k.Null:s=n.visitNull;break;case k.Bool:s=n.visitBool;break;case k.Int:s=n.visitInt;break;case k.Int8:s=n.visitInt8||n.visitInt;break;case k.Int16:s=n.visitInt16||n.visitInt;break;case k.Int32:s=n.visitInt32||n.visitInt;break;case k.Int64:s=n.visitInt64||n.visitInt;break;case k.Uint8:s=n.visitUint8||n.visitInt;break;case k.Uint16:s=n.visitUint16||n.visitInt;break;case k.Uint32:s=n.visitUint32||n.visitInt;break;case k.Uint64:s=n.visitUint64||n.visitInt;break;case k.Float:s=n.visitFloat;break;case k.Float16:s=n.visitFloat16||n.visitFloat;break;case k.Float32:s=n.visitFloat32||n.visitFloat;break;case k.Float64:s=n.visitFloat64||n.visitFloat;break;case k.Utf8:s=n.visitUtf8;break;case k.Binary:s=n.visitBinary;break;case k.FixedSizeBinary:s=n.visitFixedSizeBinary;break;case k.Date:s=n.visitDate;break;case k.DateDay:s=n.visitDateDay||n.visitDate;break;case k.DateMillisecond:s=n.visitDateMillisecond||n.visitDate;break;case k.Timestamp:s=n.visitTimestamp;break;case k.TimestampSecond:s=n.visitTimestampSecond||n.visitTimestamp;break;case k.TimestampMillisecond:s=n.visitTimestampMillisecond||n.visitTimestamp;break;case k.TimestampMicrosecond:s=n.visitTimestampMicrosecond||n.visitTimestamp;break;case k.TimestampNanosecond:s=n.visitTimestampNanosecond||n.visitTimestamp;break;case k.Time:s=n.visitTime;break;case k.TimeSecond:s=n.visitTimeSecond||n.visitTime;break;case k.TimeMillisecond:s=n.visitTimeMillisecond||n.visitTime;break;case k.TimeMicrosecond:s=n.visitTimeMicrosecond||n.visitTime;break;case k.TimeNanosecond:s=n.visitTimeNanosecond||n.visitTime;break;case k.Decimal:s=n.visitDecimal;break;case k.List:s=n.visitList;break;case k.Struct:s=n.visitStruct;break;case k.Union:s=n.visitUnion;break;case k.DenseUnion:s=n.visitDenseUnion||n.visitUnion;break;case k.SparseUnion:s=n.visitSparseUnion||n.visitUnion;break;case k.Dictionary:s=n.visitDictionary;break;case k.Interval:s=n.visitInterval;break;case k.IntervalDayTime:s=n.visitIntervalDayTime||n.visitInterval;break;case k.IntervalYearMonth:s=n.visitIntervalYearMonth||n.visitInterval;break;case k.FixedSizeList:s=n.visitFixedSizeList;break;case k.Map:s=n.visitMap;break}if(typeof s=="function")return s;if(!e)return()=>null;throw new Error(`Unrecognized type '${k[t]}'`)}function pS(n){switch(n.typeId){case k.Null:return k.Null;case k.Int:{const{bitWidth:t,isSigned:e}=n;switch(t){case 8:return e?k.Int8:k.Uint8;case 16:return e?k.Int16:k.Uint16;case 32:return e?k.Int32:k.Uint32;case 64:return e?k.Int64:k.Uint64}return k.Int}case k.Float:switch(n.precision){case bn.HALF:return k.Float16;case bn.SINGLE:return k.Float32;case bn.DOUBLE:return k.Float64}return k.Float;case k.Binary:return k.Binary;case k.Utf8:return k.Utf8;case k.Bool:return k.Bool;case k.Decimal:return k.Decimal;case k.Time:switch(n.unit){case Xt.SECOND:return k.TimeSecond;case Xt.MILLISECOND:return k.TimeMillisecond;case Xt.MICROSECOND:return k.TimeMicrosecond;case Xt.NANOSECOND:return k.TimeNanosecond}return k.Time;case k.Timestamp:switch(n.unit){case Xt.SECOND:return k.TimestampSecond;case Xt.MILLISECOND:return k.TimestampMillisecond;case Xt.MICROSECOND:return k.TimestampMicrosecond;case Xt.NANOSECOND:return k.TimestampNanosecond}return k.Timestamp;case k.Date:switch(n.unit){case Or.DAY:return k.DateDay;case Or.MILLISECOND:return k.DateMillisecond}return k.Date;case k.Interval:switch(n.unit){case ds.DAY_TIME:return k.IntervalDayTime;case ds.YEAR_MONTH:return k.IntervalYearMonth}return k.Interval;case k.Map:return k.Map;case k.List:return k.List;case k.Struct:return k.Struct;case k.Union:switch(n.mode){case Un.Dense:return k.DenseUnion;case Un.Sparse:return k.SparseUnion}return k.Union;case k.FixedSizeBinary:return k.FixedSizeBinary;case k.FixedSizeList:return k.FixedSizeList;case k.Dictionary:return k.Dictionary}throw new Error(`Unrecognized type '${k[n.typeId]}'`)}jt.prototype.visitInt8=null;jt.prototype.visitInt16=null;jt.prototype.visitInt32=null;jt.prototype.visitInt64=null;jt.prototype.visitUint8=null;jt.prototype.visitUint16=null;jt.prototype.visitUint32=null;jt.prototype.visitUint64=null;jt.prototype.visitFloat16=null;jt.prototype.visitFloat32=null;jt.prototype.visitFloat64=null;jt.prototype.visitDateDay=null;jt.prototype.visitDateMillisecond=null;jt.prototype.visitTimestampSecond=null;jt.prototype.visitTimestampMillisecond=null;jt.prototype.visitTimestampMicrosecond=null;jt.prototype.visitTimestampNanosecond=null;jt.prototype.visitTimeSecond=null;jt.prototype.visitTimeMillisecond=null;jt.prototype.visitTimeMicrosecond=null;jt.prototype.visitTimeNanosecond=null;jt.prototype.visitDenseUnion=null;jt.prototype.visitSparseUnion=null;jt.prototype.visitIntervalDayTime=null;jt.prototype.visitIntervalYearMonth=null;const ZT=new Float64Array(1),ul=new Uint32Array(ZT.buffer);function XT(n){const t=(n&31744)>>10,e=(n&1023)/1024,s=Math.pow(-1,(n&32768)>>15);switch(t){case 31:return s*(e?Number.NaN:1/0);case 0:return s*(e?6103515625e-14*e:0)}return s*Math.pow(2,t-15)*(1+e)}function uC(n){if(n!==n)return 32256;ZT[0]=n;const t=(ul[1]&2147483648)>>16&65535;let e=ul[1]&2146435072,s=0;return e>=1089470464?ul[0]>0?e=31744:(e=(e&2080374784)>>16,s=(ul[1]&1048575)>>10):e<=1056964608?(s=1048576+(ul[1]&1048575),s=1048576+(s<<(e>>20)-998)>>21,e=0):(e=e-1056964608>>10,s=(ul[1]&1048575)+512>>10),t|e|s&65535}class Ct extends jt{}function Bt(n){return(t,e,s)=>{if(t.setValid(e,s!=null))return n(t,e,s)}}const cC=(n,t,e)=>{n[t]=Math.trunc(e/864e5)},Ky=(n,t,e)=>{n[t]=Math.trunc(e%4294967296),n[t+1]=Math.trunc(e/4294967296)},fC=(n,t,e)=>{n[t]=Math.trunc(e*1e3%4294967296),n[t+1]=Math.trunc(e*1e3/4294967296)},dC=(n,t,e)=>{n[t]=Math.trunc(e*1e6%4294967296),n[t+1]=Math.trunc(e*1e6/4294967296)},QT=(n,t,e,s)=>{if(e+1<t.length){const{[e]:l,[e+1]:o}=t;n.set(s.subarray(0,o-l),l)}},hC=({offset:n,values:t},e,s)=>{const l=n+e;s?t[l>>3]|=1<<l%8:t[l>>3]&=~(1<<l%8)},Dr=({values:n},t,e)=>{n[t]=e},Py=({values:n},t,e)=>{n[t]=e},JT=({values:n},t,e)=>{n[t]=uC(e)},gC=(n,t,e)=>{switch(n.type.precision){case bn.HALF:return JT(n,t,e);case bn.SINGLE:case bn.DOUBLE:return Py(n,t,e)}},WT=({values:n},t,e)=>{cC(n,t,e.valueOf())},tw=({values:n},t,e)=>{Ky(n,t*2,e.valueOf())},pC=({stride:n,values:t},e,s)=>{t.set(s.subarray(0,n),n*e)},yC=({values:n,valueOffsets:t},e,s)=>QT(n,t,e,s),mC=({values:n,valueOffsets:t},e,s)=>{QT(n,t,e,jy(s))},_C=(n,t,e)=>{n.type.unit===Or.DAY?WT(n,t,e):tw(n,t,e)},ew=({values:n},t,e)=>Ky(n,t*2,e/1e3),nw=({values:n},t,e)=>Ky(n,t*2,e),iw=({values:n},t,e)=>fC(n,t*2,e),rw=({values:n},t,e)=>dC(n,t*2,e),bC=(n,t,e)=>{switch(n.type.unit){case Xt.SECOND:return ew(n,t,e);case Xt.MILLISECOND:return nw(n,t,e);case Xt.MICROSECOND:return iw(n,t,e);case Xt.NANOSECOND:return rw(n,t,e)}},sw=({values:n},t,e)=>{n[t]=e},aw=({values:n},t,e)=>{n[t]=e},lw=({values:n},t,e)=>{n[t]=e},ow=({values:n},t,e)=>{n[t]=e},vC=(n,t,e)=>{switch(n.type.unit){case Xt.SECOND:return sw(n,t,e);case Xt.MILLISECOND:return aw(n,t,e);case Xt.MICROSECOND:return lw(n,t,e);case Xt.NANOSECOND:return ow(n,t,e)}},SC=({values:n,stride:t},e,s)=>{n.set(s.subarray(0,t),t*e)},TC=(n,t,e)=>{const s=n.children[0],l=n.valueOffsets,o=ai.getVisitFn(s);if(Array.isArray(e))for(let c=-1,f=l[t],h=l[t+1];f<h;)o(s,f++,e[++c]);else for(let c=-1,f=l[t],h=l[t+1];f<h;)o(s,f++,e.get(++c))},wC=(n,t,e)=>{const s=n.children[0],{valueOffsets:l}=n,o=ai.getVisitFn(s);let{[t]:c,[t+1]:f}=l;const h=e instanceof Map?e.entries():Object.entries(e);for(const p of h)if(o(s,c,p),++c>=f)break},xC=(n,t)=>(e,s,l,o)=>s&&e(s,n,t[o]),AC=(n,t)=>(e,s,l,o)=>s&&e(s,n,t.get(o)),EC=(n,t)=>(e,s,l,o)=>s&&e(s,n,t.get(l.name)),OC=(n,t)=>(e,s,l,o)=>s&&e(s,n,t[l.name]),NC=(n,t,e)=>{const s=n.type.children.map(o=>ai.getVisitFn(o.type)),l=e instanceof Map?EC(t,e):e instanceof Wt?AC(t,e):Array.isArray(e)?xC(t,e):OC(t,e);n.type.children.forEach((o,c)=>l(s[c],n.children[c],o,c))},CC=(n,t,e)=>{n.type.mode===Un.Dense?uw(n,t,e):cw(n,t,e)},uw=(n,t,e)=>{const s=n.type.typeIdToChildIndex[n.typeIds[t]],l=n.children[s];ai.visit(l,n.valueOffsets[t],e)},cw=(n,t,e)=>{const s=n.type.typeIdToChildIndex[n.typeIds[t]],l=n.children[s];ai.visit(l,t,e)},DC=(n,t,e)=>{var s;(s=n.dictionary)===null||s===void 0||s.set(n.values[t],e)},MC=(n,t,e)=>{n.type.unit===ds.DAY_TIME?fw(n,t,e):dw(n,t,e)},fw=({values:n},t,e)=>{n.set(e.subarray(0,2),2*t)},dw=({values:n},t,e)=>{n[t]=e[0]*12+e[1]%12},BC=(n,t,e)=>{const{stride:s}=n,l=n.children[0],o=ai.getVisitFn(l);if(Array.isArray(e))for(let c=-1,f=t*s;++c<s;)o(l,f+c,e[c]);else for(let c=-1,f=t*s;++c<s;)o(l,f+c,e.get(c))};Ct.prototype.visitBool=Bt(hC);Ct.prototype.visitInt=Bt(Dr);Ct.prototype.visitInt8=Bt(Dr);Ct.prototype.visitInt16=Bt(Dr);Ct.prototype.visitInt32=Bt(Dr);Ct.prototype.visitInt64=Bt(Dr);Ct.prototype.visitUint8=Bt(Dr);Ct.prototype.visitUint16=Bt(Dr);Ct.prototype.visitUint32=Bt(Dr);Ct.prototype.visitUint64=Bt(Dr);Ct.prototype.visitFloat=Bt(gC);Ct.prototype.visitFloat16=Bt(JT);Ct.prototype.visitFloat32=Bt(Py);Ct.prototype.visitFloat64=Bt(Py);Ct.prototype.visitUtf8=Bt(mC);Ct.prototype.visitBinary=Bt(yC);Ct.prototype.visitFixedSizeBinary=Bt(pC);Ct.prototype.visitDate=Bt(_C);Ct.prototype.visitDateDay=Bt(WT);Ct.prototype.visitDateMillisecond=Bt(tw);Ct.prototype.visitTimestamp=Bt(bC);Ct.prototype.visitTimestampSecond=Bt(ew);Ct.prototype.visitTimestampMillisecond=Bt(nw);Ct.prototype.visitTimestampMicrosecond=Bt(iw);Ct.prototype.visitTimestampNanosecond=Bt(rw);Ct.prototype.visitTime=Bt(vC);Ct.prototype.visitTimeSecond=Bt(sw);Ct.prototype.visitTimeMillisecond=Bt(aw);Ct.prototype.visitTimeMicrosecond=Bt(lw);Ct.prototype.visitTimeNanosecond=Bt(ow);Ct.prototype.visitDecimal=Bt(SC);Ct.prototype.visitList=Bt(TC);Ct.prototype.visitStruct=Bt(NC);Ct.prototype.visitUnion=Bt(CC);Ct.prototype.visitDenseUnion=Bt(uw);Ct.prototype.visitSparseUnion=Bt(cw);Ct.prototype.visitDictionary=Bt(DC);Ct.prototype.visitInterval=Bt(MC);Ct.prototype.visitIntervalDayTime=Bt(fw);Ct.prototype.visitIntervalYearMonth=Bt(dw);Ct.prototype.visitFixedSizeList=Bt(BC);Ct.prototype.visitMap=Bt(wC);const ai=new Ct,di=Symbol.for("parent"),Tl=Symbol.for("rowIndex");class Gy{constructor(t,e){return this[di]=t,this[Tl]=e,new Proxy(this,new FC)}toArray(){return Object.values(this.toJSON())}toJSON(){const t=this[Tl],e=this[di],s=e.type.children,l={};for(let o=-1,c=s.length;++o<c;)l[s[o].name]=wn.visit(e.children[o],t);return l}toString(){return`{${[...this].map(([t,e])=>`${_u(t)}: ${_u(e)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}[Symbol.iterator](){return new RC(this[di],this[Tl])}}class RC{constructor(t,e){this.childIndex=0,this.children=t.children,this.rowIndex=e,this.childFields=t.type.children,this.numChildren=this.childFields.length}[Symbol.iterator](){return this}next(){const t=this.childIndex;return t<this.numChildren?(this.childIndex=t+1,{done:!1,value:[this.childFields[t].name,wn.visit(this.children[t],this.rowIndex)]}):{done:!0,value:null}}}Object.defineProperties(Gy.prototype,{[Symbol.toStringTag]:{enumerable:!1,configurable:!1,value:"Row"},[di]:{writable:!0,enumerable:!1,configurable:!1,value:null},[Tl]:{writable:!0,enumerable:!1,configurable:!1,value:-1}});class FC{isExtensible(){return!1}deleteProperty(){return!1}preventExtensions(){return!0}ownKeys(t){return t[di].type.children.map(e=>e.name)}has(t,e){return t[di].type.children.findIndex(s=>s.name===e)!==-1}getOwnPropertyDescriptor(t,e){if(t[di].type.children.findIndex(s=>s.name===e)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,e){if(Reflect.has(t,e))return t[e];const s=t[di].type.children.findIndex(l=>l.name===e);if(s!==-1){const l=wn.visit(t[di].children[s],t[Tl]);return Reflect.set(t,e,l),l}}set(t,e,s){const l=t[di].type.children.findIndex(o=>o.name===e);return l!==-1?(ai.visit(t[di].children[l],t[Tl],s),Reflect.set(t,e,s)):Reflect.has(t,e)||typeof e=="symbol"?Reflect.set(t,e,s):!1}}class xt extends jt{}function Dt(n){return(t,e)=>t.getValid(e)?n(t,e):null}const LC=(n,t)=>864e5*n[t],Zy=(n,t)=>4294967296*n[t+1]+(n[t]>>>0),IC=(n,t)=>4294967296*(n[t+1]/1e3)+(n[t]>>>0)/1e3,kC=(n,t)=>4294967296*(n[t+1]/1e6)+(n[t]>>>0)/1e6,hw=n=>new Date(n),UC=(n,t)=>hw(LC(n,t)),zC=(n,t)=>hw(Zy(n,t)),$C=(n,t)=>null,gw=(n,t,e)=>{if(e+1>=t.length)return null;const s=t[e],l=t[e+1];return n.subarray(s,l)},jC=({offset:n,values:t},e)=>{const s=n+e;return(t[s>>3]&1<<s%8)!==0},pw=({values:n},t)=>UC(n,t),yw=({values:n},t)=>zC(n,t*2),bs=({stride:n,values:t},e)=>t[n*e],VC=({stride:n,values:t},e)=>XT(t[n*e]),mw=({values:n},t)=>n[t],HC=({stride:n,values:t},e)=>t.subarray(n*e,n*(e+1)),YC=({values:n,valueOffsets:t},e)=>gw(n,t,e),qC=({values:n,valueOffsets:t},e)=>{const s=gw(n,t,e);return s!==null?Kp(s):null},KC=({values:n},t)=>n[t],PC=({type:n,values:t},e)=>n.precision!==bn.HALF?t[e]:XT(t[e]),GC=(n,t)=>n.type.unit===Or.DAY?pw(n,t):yw(n,t),_w=({values:n},t)=>1e3*Zy(n,t*2),bw=({values:n},t)=>Zy(n,t*2),vw=({values:n},t)=>IC(n,t*2),Sw=({values:n},t)=>kC(n,t*2),ZC=(n,t)=>{switch(n.type.unit){case Xt.SECOND:return _w(n,t);case Xt.MILLISECOND:return bw(n,t);case Xt.MICROSECOND:return vw(n,t);case Xt.NANOSECOND:return Sw(n,t)}},Tw=({values:n},t)=>n[t],ww=({values:n},t)=>n[t],xw=({values:n},t)=>n[t],Aw=({values:n},t)=>n[t],XC=(n,t)=>{switch(n.type.unit){case Xt.SECOND:return Tw(n,t);case Xt.MILLISECOND:return ww(n,t);case Xt.MICROSECOND:return xw(n,t);case Xt.NANOSECOND:return Aw(n,t)}},QC=({values:n,stride:t},e)=>qy.decimal(n.subarray(t*e,t*(e+1))),JC=(n,t)=>{const{valueOffsets:e,stride:s,children:l}=n,{[t*s]:o,[t*s+1]:c}=e,h=l[0].slice(o,c-o);return new Wt([h])},WC=(n,t)=>{const{valueOffsets:e,children:s}=n,{[t]:l,[t+1]:o}=e,c=s[0];return new Xy(c.slice(l,o-l))},tD=(n,t)=>new Gy(n,t),eD=(n,t)=>n.type.mode===Un.Dense?Ew(n,t):Ow(n,t),Ew=(n,t)=>{const e=n.type.typeIdToChildIndex[n.typeIds[t]],s=n.children[e];return wn.visit(s,n.valueOffsets[t])},Ow=(n,t)=>{const e=n.type.typeIdToChildIndex[n.typeIds[t]],s=n.children[e];return wn.visit(s,t)},nD=(n,t)=>{var e;return(e=n.dictionary)===null||e===void 0?void 0:e.get(n.values[t])},iD=(n,t)=>n.type.unit===ds.DAY_TIME?Nw(n,t):Cw(n,t),Nw=({values:n},t)=>n.subarray(2*t,2*(t+1)),Cw=({values:n},t)=>{const e=n[t],s=new Int32Array(2);return s[0]=Math.trunc(e/12),s[1]=Math.trunc(e%12),s},rD=(n,t)=>{const{stride:e,children:s}=n,o=s[0].slice(t*e,e);return new Wt([o])};xt.prototype.visitNull=Dt($C);xt.prototype.visitBool=Dt(jC);xt.prototype.visitInt=Dt(KC);xt.prototype.visitInt8=Dt(bs);xt.prototype.visitInt16=Dt(bs);xt.prototype.visitInt32=Dt(bs);xt.prototype.visitInt64=Dt(mw);xt.prototype.visitUint8=Dt(bs);xt.prototype.visitUint16=Dt(bs);xt.prototype.visitUint32=Dt(bs);xt.prototype.visitUint64=Dt(mw);xt.prototype.visitFloat=Dt(PC);xt.prototype.visitFloat16=Dt(VC);xt.prototype.visitFloat32=Dt(bs);xt.prototype.visitFloat64=Dt(bs);xt.prototype.visitUtf8=Dt(qC);xt.prototype.visitBinary=Dt(YC);xt.prototype.visitFixedSizeBinary=Dt(HC);xt.prototype.visitDate=Dt(GC);xt.prototype.visitDateDay=Dt(pw);xt.prototype.visitDateMillisecond=Dt(yw);xt.prototype.visitTimestamp=Dt(ZC);xt.prototype.visitTimestampSecond=Dt(_w);xt.prototype.visitTimestampMillisecond=Dt(bw);xt.prototype.visitTimestampMicrosecond=Dt(vw);xt.prototype.visitTimestampNanosecond=Dt(Sw);xt.prototype.visitTime=Dt(XC);xt.prototype.visitTimeSecond=Dt(Tw);xt.prototype.visitTimeMillisecond=Dt(ww);xt.prototype.visitTimeMicrosecond=Dt(xw);xt.prototype.visitTimeNanosecond=Dt(Aw);xt.prototype.visitDecimal=Dt(QC);xt.prototype.visitList=Dt(JC);xt.prototype.visitStruct=Dt(tD);xt.prototype.visitUnion=Dt(eD);xt.prototype.visitDenseUnion=Dt(Ew);xt.prototype.visitSparseUnion=Dt(Ow);xt.prototype.visitDictionary=Dt(nD);xt.prototype.visitInterval=Dt(iD);xt.prototype.visitIntervalDayTime=Dt(Nw);xt.prototype.visitIntervalYearMonth=Dt(Cw);xt.prototype.visitFixedSizeList=Dt(rD);xt.prototype.visitMap=Dt(WC);const wn=new xt,Li=Symbol.for("keys"),wl=Symbol.for("vals");class Xy{constructor(t){return this[Li]=new Wt([t.children[0]]).memoize(),this[wl]=t.children[1],new Proxy(this,new aD)}[Symbol.iterator](){return new sD(this[Li],this[wl])}get size(){return this[Li].length}toArray(){return Object.values(this.toJSON())}toJSON(){const t=this[Li],e=this[wl],s={};for(let l=-1,o=t.length;++l<o;)s[t.get(l)]=wn.visit(e,l);return s}toString(){return`{${[...this].map(([t,e])=>`${_u(t)}: ${_u(e)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}class sD{constructor(t,e){this.keys=t,this.vals=e,this.keyIndex=0,this.numKeys=t.length}[Symbol.iterator](){return this}next(){const t=this.keyIndex;return t===this.numKeys?{done:!0,value:null}:(this.keyIndex++,{done:!1,value:[this.keys.get(t),wn.visit(this.vals,t)]})}}class aD{isExtensible(){return!1}deleteProperty(){return!1}preventExtensions(){return!0}ownKeys(t){return t[Li].toArray().map(String)}has(t,e){return t[Li].includes(e)}getOwnPropertyDescriptor(t,e){if(t[Li].indexOf(e)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,e){if(Reflect.has(t,e))return t[e];const s=t[Li].indexOf(e);if(s!==-1){const l=wn.visit(Reflect.get(t,wl),s);return Reflect.set(t,e,l),l}}set(t,e,s){const l=t[Li].indexOf(e);return l!==-1?(ai.visit(Reflect.get(t,wl),l,s),Reflect.set(t,e,s)):Reflect.has(t,e)?Reflect.set(t,e,s):!1}}Object.defineProperties(Xy.prototype,{[Symbol.toStringTag]:{enumerable:!1,configurable:!1,value:"Row"},[Li]:{writable:!0,enumerable:!1,configurable:!1,value:null},[wl]:{writable:!0,enumerable:!1,configurable:!1,value:null}});let yS;function Dw(n,t,e,s){const{length:l=0}=n;let o=typeof t!="number"?0:t,c=typeof e!="number"?l:e;return o<0&&(o=(o%l+l)%l),c<0&&(c=(c%l+l)%l),c<o&&(yS=o,o=c,c=yS),c>l&&(c=l),s?s(n,o,c):[o,c]}const mS=n=>n!==n;function ql(n){if(typeof n!=="object"||n===null)return mS(n)?mS:e=>e===n;if(n instanceof Date){const e=n.valueOf();return s=>s instanceof Date?s.valueOf()===e:!1}return ArrayBuffer.isView(n)?e=>e?WN(n,e):!1:n instanceof Map?oD(n):Array.isArray(n)?lD(n):n instanceof Wt?uD(n):cD(n,!0)}function lD(n){const t=[];for(let e=-1,s=n.length;++e<s;)t[e]=ql(n[e]);return Bd(t)}function oD(n){let t=-1;const e=[];for(const s of n.values())e[++t]=ql(s);return Bd(e)}function uD(n){const t=[];for(let e=-1,s=n.length;++e<s;)t[e]=ql(n.get(e));return Bd(t)}function cD(n,t=!1){const e=Object.keys(n);if(!t&&e.length===0)return()=>!1;const s=[];for(let l=-1,o=e.length;++l<o;)s[l]=ql(n[e[l]]);return Bd(s,e)}function Bd(n,t){return e=>{if(!e||typeof e!="object")return!1;switch(e.constructor){case Array:return fD(n,e);case Map:return _S(n,e,e.keys());case Xy:case Gy:case Object:case void 0:return _S(n,e,t||Object.keys(e))}return e instanceof Wt?dD(n,e):!1}}function fD(n,t){const e=n.length;if(t.length!==e)return!1;for(let s=-1;++s<e;)if(!n[s](t[s]))return!1;return!0}function dD(n,t){const e=n.length;if(t.length!==e)return!1;for(let s=-1;++s<e;)if(!n[s](t.get(s)))return!1;return!0}function _S(n,t,e){const s=e[Symbol.iterator](),l=t instanceof Map?t.keys():Object.keys(t)[Symbol.iterator](),o=t instanceof Map?t.values():Object.values(t)[Symbol.iterator]();let c=0;const f=n.length;let h=o.next(),p=s.next(),y=l.next();for(;c<f&&!p.done&&!y.done&&!h.done&&!(p.value!==y.value||!n[c](h.value));++c,p=s.next(),y=l.next(),h=o.next());return c===f&&p.done&&y.done&&h.done?!0:(s.return&&s.return(),l.return&&l.return(),o.return&&o.return(),!1)}function Mw(n,t,e,s){return(e&1<<s)!==0}function hD(n,t,e,s){return(e&1<<s)>>s}function Qy(n,t,e){const s=e.byteLength+7&-8;if(n>0||e.byteLength<s){const l=new Uint8Array(s);return l.set(n%8===0?e.subarray(n>>3):Kf(new Jy(e,n,t,null,Mw)).subarray(0,s)),l}return e}function Kf(n){const t=[];let e=0,s=0,l=0;for(const c of n)c&&(l|=1<<s),++s===8&&(t[e++]=l,l=s=0);(e===0||s>0)&&(t[e++]=l);const o=new Uint8Array(t.length+7&-8);return o.set(t),o}class Jy{constructor(t,e,s,l,o){this.bytes=t,this.length=s,this.context=l,this.get=o,this.bit=e%8,this.byteIndex=e>>3,this.byte=t[this.byteIndex++],this.index=0}next(){return this.index<this.length?(this.bit===8&&(this.bit=0,this.byte=this.bytes[this.byteIndex++]),{value:this.get(this.context,this.index++,this.byte,this.bit++)}):{done:!0,value:null}}[Symbol.iterator](){return this}}function Xp(n,t,e){if(e-t<=0)return 0;if(e-t<8){let o=0;for(const c of new Jy(n,t,e-t,n,hD))o+=c;return o}const s=e>>3<<3,l=t+(t%8===0?0:8-t%8);return Xp(n,t,l)+Xp(n,s,e)+gD(n,l>>3,s-l>>3)}function gD(n,t,e){let s=0,l=Math.trunc(t);const o=new DataView(n.buffer,n.byteOffset,n.byteLength),c=e===void 0?n.byteLength:l+e;for(;c-l>=4;)s+=Sp(o.getUint32(l)),l+=4;for(;c-l>=2;)s+=Sp(o.getUint16(l)),l+=2;for(;c-l>=1;)s+=Sp(o.getUint8(l)),l+=1;return s}function Sp(n){let t=Math.trunc(n);return t=t-(t>>>1&1431655765),t=(t&858993459)+(t>>>2&858993459),(t+(t>>>4)&252645135)*16843009>>>24}const pD=-1;class de{constructor(t,e,s,l,o,c=[],f){this.type=t,this.children=c,this.dictionary=f,this.offset=Math.floor(Math.max(e||0,0)),this.length=Math.floor(Math.max(s||0,0)),this._nullCount=Math.floor(Math.max(l||0,-1));let h;o instanceof de?(this.stride=o.stride,this.values=o.values,this.typeIds=o.typeIds,this.nullBitmap=o.nullBitmap,this.valueOffsets=o.valueOffsets):(this.stride=yr(t),o&&((h=o[0])&&(this.valueOffsets=h),(h=o[1])&&(this.values=h),(h=o[2])&&(this.nullBitmap=h),(h=o[3])&&(this.typeIds=h))),this.nullable=this._nullCount!==0&&this.nullBitmap&&this.nullBitmap.byteLength>0}get typeId(){return this.type.typeId}get ArrayType(){return this.type.ArrayType}get buffers(){return[this.valueOffsets,this.values,this.nullBitmap,this.typeIds]}get byteLength(){let t=0;const{valueOffsets:e,values:s,nullBitmap:l,typeIds:o}=this;return e&&(t+=e.byteLength),s&&(t+=s.byteLength),l&&(t+=l.byteLength),o&&(t+=o.byteLength),this.children.reduce((c,f)=>c+f.byteLength,t)}get nullCount(){let t=this._nullCount,e;return t<=pD&&(e=this.nullBitmap)&&(this._nullCount=t=this.length-Xp(e,this.offset,this.offset+this.length)),t}getValid(t){if(this.nullable&&this.nullCount>0){const e=this.offset+t;return(this.nullBitmap[e>>3]&1<<e%8)!==0}return!0}setValid(t,e){if(!this.nullable)return e;if(!this.nullBitmap||this.nullBitmap.byteLength<=t>>3){const{nullBitmap:h}=this._changeLengthAndBackfillNullBitmap(this.length);Object.assign(this,{nullBitmap:h,_nullCount:0})}const{nullBitmap:s,offset:l}=this,o=l+t>>3,c=(l+t)%8,f=s[o]>>c&1;return e?f===0&&(s[o]|=1<<c,this._nullCount=this.nullCount+1):f===1&&(s[o]&=~(1<<c),this._nullCount=this.nullCount-1),e}clone(t=this.type,e=this.offset,s=this.length,l=this._nullCount,o=this,c=this.children){return new de(t,e,s,l,o,c,this.dictionary)}slice(t,e){const{stride:s,typeId:l,children:o}=this,c=+(this._nullCount===0)-1,f=l===16?s:1,h=this._sliceBuffers(t,e,s,l);return this.clone(this.type,this.offset+t,e,c,h,o.length===0||this.valueOffsets?o:this._sliceChildren(o,f*t,f*e))}_changeLengthAndBackfillNullBitmap(t){if(this.typeId===k.Null)return this.clone(this.type,0,t,0);const{length:e,nullCount:s}=this,l=new Uint8Array((t+63&-64)>>3).fill(255,0,e>>3);l[e>>3]=(1<<e-(e&-8))-1,s>0&&l.set(Qy(this.offset,e,this.nullBitmap),0);const o=this.buffers;return o[pr.VALIDITY]=l,this.clone(this.type,0,t,s+(t-e),o)}_sliceBuffers(t,e,s,l){let o;const{buffers:c}=this;return(o=c[pr.TYPE])&&(c[pr.TYPE]=o.subarray(t,t+e)),(o=c[pr.OFFSET])&&(c[pr.OFFSET]=o.subarray(t,t+e+1))||(o=c[pr.DATA])&&(c[pr.DATA]=l===6?o:o.subarray(s*t,s*(t+e))),c}_sliceChildren(t,e,s){return t.map(l=>l.slice(e,s))}}de.prototype.children=Object.freeze([]);class fu extends jt{visit(t){return this.getVisitFn(t.type).call(this,t)}visitNull(t){const{["type"]:e,["offset"]:s=0,["length"]:l=0}=t;return new de(e,s,l,0)}visitBool(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length>>3,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitInt(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitFloat(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitUtf8(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.data),o=Zt(t.nullBitmap),c=nu(t.valueOffsets),{["length"]:f=c.length-1,["nullCount"]:h=t.nullBitmap?-1:0}=t;return new de(e,s,f,h,[c,l,o])}visitBinary(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.data),o=Zt(t.nullBitmap),c=nu(t.valueOffsets),{["length"]:f=c.length-1,["nullCount"]:h=t.nullBitmap?-1:0}=t;return new de(e,s,f,h,[c,l,o])}visitFixedSizeBinary(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitDate(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitTimestamp(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitTime(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitDecimal(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitList(t){const{["type"]:e,["offset"]:s=0,["child"]:l}=t,o=Zt(t.nullBitmap),c=nu(t.valueOffsets),{["length"]:f=c.length-1,["nullCount"]:h=t.nullBitmap?-1:0}=t;return new de(e,s,f,h,[c,void 0,o],[l])}visitStruct(t){const{["type"]:e,["offset"]:s=0,["children"]:l=[]}=t,o=Zt(t.nullBitmap),{length:c=l.reduce((h,{length:p})=>Math.max(h,p),0),nullCount:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,void 0,o],l)}visitUnion(t){const{["type"]:e,["offset"]:s=0,["children"]:l=[]}=t,o=Zt(t.nullBitmap),c=ue(e.ArrayType,t.typeIds),{["length"]:f=c.length,["nullCount"]:h=t.nullBitmap?-1:0}=t;if(wt.isSparseUnion(e))return new de(e,s,f,h,[void 0,void 0,o,c],l);const p=nu(t.valueOffsets);return new de(e,s,f,h,[p,void 0,o,c],l)}visitDictionary(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.indices.ArrayType,t.data),{["dictionary"]:c=new Wt([new fu().visit({type:e.dictionary})])}=t,{["length"]:f=o.length,["nullCount"]:h=t.nullBitmap?-1:0}=t;return new de(e,s,f,h,[void 0,o,l],[],c)}visitInterval(t){const{["type"]:e,["offset"]:s=0}=t,l=Zt(t.nullBitmap),o=ue(e.ArrayType,t.data),{["length"]:c=o.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,o,l])}visitFixedSizeList(t){const{["type"]:e,["offset"]:s=0,["child"]:l=new fu().visit({type:e.valueType})}=t,o=Zt(t.nullBitmap),{["length"]:c=l.length/yr(e),["nullCount"]:f=t.nullBitmap?-1:0}=t;return new de(e,s,c,f,[void 0,void 0,o],[l])}visitMap(t){const{["type"]:e,["offset"]:s=0,["child"]:l=new fu().visit({type:e.childType})}=t,o=Zt(t.nullBitmap),c=nu(t.valueOffsets),{["length"]:f=c.length-1,["nullCount"]:h=t.nullBitmap?-1:0}=t;return new de(e,s,f,h,[c,void 0,o],[l])}}function $t(n){return new fu().visit(n)}class bS{constructor(t=0,e){this.numChunks=t,this.getChunkIterator=e,this.chunkIndex=0,this.chunkIterator=this.getChunkIterator(0)}next(){for(;this.chunkIndex<this.numChunks;){const t=this.chunkIterator.next();if(!t.done)return t;++this.chunkIndex<this.numChunks&&(this.chunkIterator=this.getChunkIterator(this.chunkIndex))}return{done:!0,value:null}}[Symbol.iterator](){return this}}function Bw(n){return n.reduce((t,e)=>t+e.nullCount,0)}function Rw(n){return n.reduce((t,e,s)=>(t[s+1]=t[s]+e.length,t),new Uint32Array(n.length+1))}function Fw(n,t,e,s){const l=[];for(let o=-1,c=n.length;++o<c;){const f=n[o],h=t[o],{length:p}=f;if(h>=s)break;if(e>=h+p)continue;if(h>=e&&h+p<=s){l.push(f);continue}const y=Math.max(0,e-h),m=Math.min(s-h,p);l.push(f.slice(y,m-y))}return l.length===0&&l.push(n[0].slice(0,0)),l}function Wy(n,t,e,s){let l=0,o=0,c=t.length-1;do{if(l>=c-1)return e<t[c]?s(n,l,e-t[l]):null;o=l+Math.trunc((c-l)*.5),e<t[o]?c=o:l=o}while(l<c)}function tm(n,t){return n.getValid(t)}function xl(n){function t(e,s,l){return n(e[s],l)}return function(e){const s=this.data;return Wy(s,this._offsets,e,t)}}function Lw(n){let t;function e(s,l,o){return n(s[l],o,t)}return function(s,l){const o=this.data;t=l;const c=Wy(o,this._offsets,s,e);return t=void 0,c}}function Iw(n){let t;function e(s,l,o){let c=o,f=0,h=0;for(let p=l-1,y=s.length;++p<y;){const m=s[p];if(~(f=n(m,t,c)))return h+f;c=0,h+=m.length}return-1}return function(s,l){t=s;const o=this.data,c=typeof l!="number"?e(o,0,0):Wy(o,this._offsets,l,e);return t=void 0,c}}class At extends jt{}function yD(n,t){return t===null&&n.length>0?0:-1}function mD(n,t){const{nullBitmap:e}=n;if(!e||n.nullCount<=0)return-1;let s=0;for(const l of new Jy(e,n.offset+(t||0),n.length,e,Mw)){if(!l)return s;++s}return-1}function Lt(n,t,e){if(t===void 0)return-1;if(t===null)return mD(n,e);const s=wn.getVisitFn(n),l=ql(t);for(let o=(e||0)-1,c=n.length;++o<c;)if(l(s(n,o)))return o;return-1}function kw(n,t,e){const s=wn.getVisitFn(n),l=ql(t);for(let o=(e||0)-1,c=n.length;++o<c;)if(l(s(n,o)))return o;return-1}At.prototype.visitNull=yD;At.prototype.visitBool=Lt;At.prototype.visitInt=Lt;At.prototype.visitInt8=Lt;At.prototype.visitInt16=Lt;At.prototype.visitInt32=Lt;At.prototype.visitInt64=Lt;At.prototype.visitUint8=Lt;At.prototype.visitUint16=Lt;At.prototype.visitUint32=Lt;At.prototype.visitUint64=Lt;At.prototype.visitFloat=Lt;At.prototype.visitFloat16=Lt;At.prototype.visitFloat32=Lt;At.prototype.visitFloat64=Lt;At.prototype.visitUtf8=Lt;At.prototype.visitBinary=Lt;At.prototype.visitFixedSizeBinary=Lt;At.prototype.visitDate=Lt;At.prototype.visitDateDay=Lt;At.prototype.visitDateMillisecond=Lt;At.prototype.visitTimestamp=Lt;At.prototype.visitTimestampSecond=Lt;At.prototype.visitTimestampMillisecond=Lt;At.prototype.visitTimestampMicrosecond=Lt;At.prototype.visitTimestampNanosecond=Lt;At.prototype.visitTime=Lt;At.prototype.visitTimeSecond=Lt;At.prototype.visitTimeMillisecond=Lt;At.prototype.visitTimeMicrosecond=Lt;At.prototype.visitTimeNanosecond=Lt;At.prototype.visitDecimal=Lt;At.prototype.visitList=Lt;At.prototype.visitStruct=Lt;At.prototype.visitUnion=Lt;At.prototype.visitDenseUnion=kw;At.prototype.visitSparseUnion=kw;At.prototype.visitDictionary=Lt;At.prototype.visitInterval=Lt;At.prototype.visitIntervalDayTime=Lt;At.prototype.visitIntervalYearMonth=Lt;At.prototype.visitFixedSizeList=Lt;At.prototype.visitMap=Lt;const Pf=new At;class Et extends jt{}function Mt(n){const{type:t}=n;if(n.nullCount===0&&n.stride===1&&(t.typeId===k.Timestamp||t instanceof gs&&t.bitWidth!==64||t instanceof Tu&&t.bitWidth!==64||t instanceof Su&&t.precision!==bn.HALF))return new bS(n.data.length,s=>{const l=n.data[s];return l.values.subarray(0,l.length)[Symbol.iterator]()});let e=0;return new bS(n.data.length,s=>{const o=n.data[s].length,c=n.slice(e,e+o);return e+=o,new _D(c)})}class _D{constructor(t){this.vector=t,this.index=0}next(){return this.index<this.vector.length?{value:this.vector.get(this.index++)}:{done:!0,value:null}}[Symbol.iterator](){return this}}Et.prototype.visitNull=Mt;Et.prototype.visitBool=Mt;Et.prototype.visitInt=Mt;Et.prototype.visitInt8=Mt;Et.prototype.visitInt16=Mt;Et.prototype.visitInt32=Mt;Et.prototype.visitInt64=Mt;Et.prototype.visitUint8=Mt;Et.prototype.visitUint16=Mt;Et.prototype.visitUint32=Mt;Et.prototype.visitUint64=Mt;Et.prototype.visitFloat=Mt;Et.prototype.visitFloat16=Mt;Et.prototype.visitFloat32=Mt;Et.prototype.visitFloat64=Mt;Et.prototype.visitUtf8=Mt;Et.prototype.visitBinary=Mt;Et.prototype.visitFixedSizeBinary=Mt;Et.prototype.visitDate=Mt;Et.prototype.visitDateDay=Mt;Et.prototype.visitDateMillisecond=Mt;Et.prototype.visitTimestamp=Mt;Et.prototype.visitTimestampSecond=Mt;Et.prototype.visitTimestampMillisecond=Mt;Et.prototype.visitTimestampMicrosecond=Mt;Et.prototype.visitTimestampNanosecond=Mt;Et.prototype.visitTime=Mt;Et.prototype.visitTimeSecond=Mt;Et.prototype.visitTimeMillisecond=Mt;Et.prototype.visitTimeMicrosecond=Mt;Et.prototype.visitTimeNanosecond=Mt;Et.prototype.visitDecimal=Mt;Et.prototype.visitList=Mt;Et.prototype.visitStruct=Mt;Et.prototype.visitUnion=Mt;Et.prototype.visitDenseUnion=Mt;Et.prototype.visitSparseUnion=Mt;Et.prototype.visitDictionary=Mt;Et.prototype.visitInterval=Mt;Et.prototype.visitIntervalDayTime=Mt;Et.prototype.visitIntervalYearMonth=Mt;Et.prototype.visitFixedSizeList=Mt;Et.prototype.visitMap=Mt;const em=new Et,bD=(n,t)=>n+t;class vs extends jt{visitNull(t,e){return 0}visitInt(t,e){return t.type.bitWidth/8}visitFloat(t,e){return t.type.ArrayType.BYTES_PER_ELEMENT}visitBool(t,e){return 1/8}visitDecimal(t,e){return t.type.bitWidth/8}visitDate(t,e){return(t.type.unit+1)*4}visitTime(t,e){return t.type.bitWidth/8}visitTimestamp(t,e){return t.type.unit===Xt.SECOND?4:8}visitInterval(t,e){return(t.type.unit+1)*4}visitStruct(t,e){return t.children.reduce((s,l)=>s+Ki.visit(l,e),0)}visitFixedSizeBinary(t,e){return t.type.byteWidth}visitMap(t,e){return 8+t.children.reduce((s,l)=>s+Ki.visit(l,e),0)}visitDictionary(t,e){var s;return t.type.indices.bitWidth/8+(((s=t.dictionary)===null||s===void 0?void 0:s.getByteLength(t.values[e]))||0)}}const vD=({valueOffsets:n},t)=>8+(n[t+1]-n[t]),SD=({valueOffsets:n},t)=>8+(n[t+1]-n[t]),TD=({valueOffsets:n,stride:t,children:e},s)=>{const l=e[0],{[s*t]:o}=n,{[s*t+1]:c}=n,f=Ki.getVisitFn(l.type),h=l.slice(o,c-o);let p=8;for(let y=-1,m=c-o;++y<m;)p+=f(h,y);return p},wD=({stride:n,children:t},e)=>{const s=t[0],l=s.slice(e*n,n),o=Ki.getVisitFn(s.type);let c=0;for(let f=-1,h=l.length;++f<h;)c+=o(l,f);return c},xD=(n,t)=>n.type.mode===Un.Dense?Uw(n,t):zw(n,t),Uw=({type:n,children:t,typeIds:e,valueOffsets:s},l)=>{const o=n.typeIdToChildIndex[e[l]];return 8+Ki.visit(t[o],s[l])},zw=({children:n},t)=>4+Ki.visitMany(n,n.map(()=>t)).reduce(bD,0);vs.prototype.visitUtf8=vD;vs.prototype.visitBinary=SD;vs.prototype.visitList=TD;vs.prototype.visitFixedSizeList=wD;vs.prototype.visitUnion=xD;vs.prototype.visitDenseUnion=Uw;vs.prototype.visitSparseUnion=zw;const Ki=new vs;var $w;const jw={},Vw={};class Wt{constructor(t){var e,s,l;const o=t[0]instanceof Wt?t.flatMap(f=>f.data):t;if(o.length===0||o.some(f=>!(f instanceof de)))throw new TypeError("Vector constructor expects an Array of Data instances.");const c=(e=o[0])===null||e===void 0?void 0:e.type;switch(o.length){case 0:this._offsets=[0];break;case 1:{const{get:f,set:h,indexOf:p,byteLength:y}=jw[c.typeId],m=o[0];this.isValid=_=>tm(m,_),this.get=_=>f(m,_),this.set=(_,S)=>h(m,_,S),this.indexOf=_=>p(m,_),this.getByteLength=_=>y(m,_),this._offsets=[0,m.length];break}default:Object.setPrototypeOf(this,Vw[c.typeId]),this._offsets=Rw(o);break}this.data=o,this.type=c,this.stride=yr(c),this.numChildren=(l=(s=c.children)===null||s===void 0?void 0:s.length)!==null&&l!==void 0?l:0,this.length=this._offsets[this._offsets.length-1]}get byteLength(){return this._byteLength===-1&&(this._byteLength=this.data.reduce((t,e)=>t+e.byteLength,0)),this._byteLength}get nullCount(){return this._nullCount===-1&&(this._nullCount=Bw(this.data)),this._nullCount}get ArrayType(){return this.type.ArrayType}get[Symbol.toStringTag](){return`${this.VectorName}<${this.type[Symbol.toStringTag]}>`}get VectorName(){return`${k[this.type.typeId]}Vector`}isValid(t){return!1}get(t){return null}set(t,e){}indexOf(t,e){return-1}includes(t,e){return this.indexOf(t,e)>0}getByteLength(t){return 0}[Symbol.iterator](){return em.visit(this)}concat(...t){return new Wt(this.data.concat(t.flatMap(e=>e.data).flat(Number.POSITIVE_INFINITY)))}slice(t,e){return new Wt(Dw(this,t,e,({data:s,_offsets:l},o,c)=>Fw(s,l,o,c)))}toJSON(){return[...this]}toArray(){const{type:t,data:e,length:s,stride:l,ArrayType:o}=this;switch(t.typeId){case k.Int:case k.Float:case k.Decimal:case k.Time:case k.Timestamp:switch(e.length){case 0:return new o;case 1:return e[0].values.subarray(0,s*l);default:return e.reduce((c,{values:f,length:h})=>(c.array.set(f.subarray(0,h*l),c.offset),c.offset+=h*l,c),{array:new o(s*l),offset:0}).array}}return[...this]}toString(){return`[${[...this].join(",")}]`}getChild(t){var e;return this.getChildAt((e=this.type.children)===null||e===void 0?void 0:e.findIndex(s=>s.name===t))}getChildAt(t){return t>-1&&t<this.numChildren?new Wt(this.data.map(({children:e})=>e[t])):null}get isMemoized(){return wt.isDictionary(this.type)?this.data[0].dictionary.isMemoized:!1}memoize(){if(wt.isDictionary(this.type)){const t=new Gf(this.data[0].dictionary),e=this.data.map(s=>{const l=s.clone();return l.dictionary=t,l});return new Wt(e)}return new Gf(this)}unmemoize(){if(wt.isDictionary(this.type)&&this.isMemoized){const t=this.data[0].dictionary.unmemoize(),e=this.data.map(s=>{const l=s.clone();return l.dictionary=t,l});return new Wt(e)}return this}}$w=Symbol.toStringTag;Wt[$w]=(n=>{n.type=wt.prototype,n.data=[],n.length=0,n.stride=1,n.numChildren=0,n._nullCount=-1,n._byteLength=-1,n._offsets=new Uint32Array([0]),n[Symbol.isConcatSpreadable]=!0;const t=Object.keys(k).map(e=>k[e]).filter(e=>typeof e=="number"&&e!==k.NONE);for(const e of t){const s=wn.getVisitFnByTypeId(e),l=ai.getVisitFnByTypeId(e),o=Pf.getVisitFnByTypeId(e),c=Ki.getVisitFnByTypeId(e);jw[e]={get:s,set:l,indexOf:o,byteLength:c},Vw[e]=Object.create(n,{isValid:{value:xl(tm)},get:{value:xl(wn.getVisitFnByTypeId(e))},set:{value:Lw(ai.getVisitFnByTypeId(e))},indexOf:{value:Iw(Pf.getVisitFnByTypeId(e))},getByteLength:{value:xl(Ki.getVisitFnByTypeId(e))}})}return"Vector"})(Wt.prototype);class Gf extends Wt{constructor(t){super(t.data);const e=this.get,s=this.set,l=this.slice,o=new Array(this.length);Object.defineProperty(this,"get",{value(c){const f=o[c];if(f!==void 0)return f;const h=e.call(this,c);return o[c]=h,h}}),Object.defineProperty(this,"set",{value(c,f){s.call(this,c,f),o[c]=f}}),Object.defineProperty(this,"slice",{value:(c,f)=>new Gf(l.call(this,c,f))}),Object.defineProperty(this,"isMemoized",{value:!0}),Object.defineProperty(this,"unmemoize",{value:()=>new Wt(this.data)}),Object.defineProperty(this,"memoize",{value:()=>this})}}class Qp{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}offset(){return this.bb.readInt64(this.bb_pos)}metaDataLength(){return this.bb.readInt32(this.bb_pos+8)}bodyLength(){return this.bb.readInt64(this.bb_pos+16)}static sizeOf(){return 24}static createBlock(t,e,s,l){return t.prep(8,24),t.writeInt64(l),t.pad(4),t.writeInt32(s),t.writeInt64(e),t.offset()}}const Tp=2,Ii=4,Sr=4,ce=4,rs=new Int32Array(2),vS=new Float32Array(rs.buffer),SS=new Float64Array(rs.buffer),cf=new Uint16Array(new Uint8Array([1,0]).buffer)[0]===1;let Ar=class Jp{constructor(t,e){this.low=t|0,this.high=e|0}static create(t,e){return t==0&&e==0?Jp.ZERO:new Jp(t,e)}toFloat64(){return(this.low>>>0)+this.high*4294967296}equals(t){return this.low==t.low&&this.high==t.high}};Ar.ZERO=new Ar(0,0);var Wp;(function(n){n[n.UTF8_BYTES=1]="UTF8_BYTES",n[n.UTF16_STRING=2]="UTF16_STRING"})(Wp||(Wp={}));let Ml=class Hw{constructor(t){this.bytes_=t,this.position_=0}static allocate(t){return new Hw(new Uint8Array(t))}clear(){this.position_=0}bytes(){return this.bytes_}position(){return this.position_}setPosition(t){this.position_=t}capacity(){return this.bytes_.length}readInt8(t){return this.readUint8(t)<<24>>24}readUint8(t){return this.bytes_[t]}readInt16(t){return this.readUint16(t)<<16>>16}readUint16(t){return this.bytes_[t]|this.bytes_[t+1]<<8}readInt32(t){return this.bytes_[t]|this.bytes_[t+1]<<8|this.bytes_[t+2]<<16|this.bytes_[t+3]<<24}readUint32(t){return this.readInt32(t)>>>0}readInt64(t){return new Ar(this.readInt32(t),this.readInt32(t+4))}readUint64(t){return new Ar(this.readUint32(t),this.readUint32(t+4))}readFloat32(t){return rs[0]=this.readInt32(t),vS[0]}readFloat64(t){return rs[cf?0:1]=this.readInt32(t),rs[cf?1:0]=this.readInt32(t+4),SS[0]}writeInt8(t,e){this.bytes_[t]=e}writeUint8(t,e){this.bytes_[t]=e}writeInt16(t,e){this.bytes_[t]=e,this.bytes_[t+1]=e>>8}writeUint16(t,e){this.bytes_[t]=e,this.bytes_[t+1]=e>>8}writeInt32(t,e){this.bytes_[t]=e,this.bytes_[t+1]=e>>8,this.bytes_[t+2]=e>>16,this.bytes_[t+3]=e>>24}writeUint32(t,e){this.bytes_[t]=e,this.bytes_[t+1]=e>>8,this.bytes_[t+2]=e>>16,this.bytes_[t+3]=e>>24}writeInt64(t,e){this.writeInt32(t,e.low),this.writeInt32(t+4,e.high)}writeUint64(t,e){this.writeUint32(t,e.low),this.writeUint32(t+4,e.high)}writeFloat32(t,e){vS[0]=e,this.writeInt32(t,rs[0])}writeFloat64(t,e){SS[0]=e,this.writeInt32(t,rs[cf?0:1]),this.writeInt32(t+4,rs[cf?1:0])}getBufferIdentifier(){if(this.bytes_.length<this.position_+Ii+Sr)throw new Error("FlatBuffers: ByteBuffer is too short to contain an identifier.");let t="";for(let e=0;e<Sr;e++)t+=String.fromCharCode(this.readInt8(this.position_+Ii+e));return t}__offset(t,e){const s=t-this.readInt32(t);return e<this.readInt16(s)?this.readInt16(s+e):0}__union(t,e){return t.bb_pos=e+this.readInt32(e),t.bb=this,t}__string(t,e){t+=this.readInt32(t);const s=this.readInt32(t);let l="",o=0;if(t+=Ii,e===Wp.UTF8_BYTES)return this.bytes_.subarray(t,t+s);for(;o<s;){let c;const f=this.readUint8(t+o++);if(f<192)c=f;else{const h=this.readUint8(t+o++);if(f<224)c=(f&31)<<6|h&63;else{const p=this.readUint8(t+o++);if(f<240)c=(f&15)<<12|(h&63)<<6|p&63;else{const y=this.readUint8(t+o++);c=(f&7)<<18|(h&63)<<12|(p&63)<<6|y&63}}}c<65536?l+=String.fromCharCode(c):(c-=65536,l+=String.fromCharCode((c>>10)+55296,(c&1023)+56320))}return l}__union_with_string(t,e){return typeof t=="string"?this.__string(e):this.__union(t,e)}__indirect(t){return t+this.readInt32(t)}__vector(t){return t+this.readInt32(t)+Ii}__vector_len(t){return this.readInt32(t+this.readInt32(t))}__has_identifier(t){if(t.length!=Sr)throw new Error("FlatBuffers: file identifier must be length "+Sr);for(let e=0;e<Sr;e++)if(t.charCodeAt(e)!=this.readInt8(this.position()+Ii+e))return!1;return!0}createLong(t,e){return Ar.create(t,e)}createScalarList(t,e){const s=[];for(let l=0;l<e;++l)t(l)!==null&&s.push(t(l));return s}createObjList(t,e){const s=[];for(let l=0;l<e;++l){const o=t(l);o!==null&&s.push(o.unpack())}return s}},Yw=class qw{constructor(t){this.minalign=1,this.vtable=null,this.vtable_in_use=0,this.isNested=!1,this.object_start=0,this.vtables=[],this.vector_num_elems=0,this.force_defaults=!1,this.string_maps=null;let e;t?e=t:e=1024,this.bb=Ml.allocate(e),this.space=e}clear(){this.bb.clear(),this.space=this.bb.capacity(),this.minalign=1,this.vtable=null,this.vtable_in_use=0,this.isNested=!1,this.object_start=0,this.vtables=[],this.vector_num_elems=0,this.force_defaults=!1,this.string_maps=null}forceDefaults(t){this.force_defaults=t}dataBuffer(){return this.bb}asUint8Array(){return this.bb.bytes().subarray(this.bb.position(),this.bb.position()+this.offset())}prep(t,e){t>this.minalign&&(this.minalign=t);const s=~(this.bb.capacity()-this.space+e)+1&t-1;for(;this.space<s+t+e;){const l=this.bb.capacity();this.bb=qw.growByteBuffer(this.bb),this.space+=this.bb.capacity()-l}this.pad(s)}pad(t){for(let e=0;e<t;e++)this.bb.writeInt8(--this.space,0)}writeInt8(t){this.bb.writeInt8(this.space-=1,t)}writeInt16(t){this.bb.writeInt16(this.space-=2,t)}writeInt32(t){this.bb.writeInt32(this.space-=4,t)}writeInt64(t){this.bb.writeInt64(this.space-=8,t)}writeFloat32(t){this.bb.writeFloat32(this.space-=4,t)}writeFloat64(t){this.bb.writeFloat64(this.space-=8,t)}addInt8(t){this.prep(1,0),this.writeInt8(t)}addInt16(t){this.prep(2,0),this.writeInt16(t)}addInt32(t){this.prep(4,0),this.writeInt32(t)}addInt64(t){this.prep(8,0),this.writeInt64(t)}addFloat32(t){this.prep(4,0),this.writeFloat32(t)}addFloat64(t){this.prep(8,0),this.writeFloat64(t)}addFieldInt8(t,e,s){(this.force_defaults||e!=s)&&(this.addInt8(e),this.slot(t))}addFieldInt16(t,e,s){(this.force_defaults||e!=s)&&(this.addInt16(e),this.slot(t))}addFieldInt32(t,e,s){(this.force_defaults||e!=s)&&(this.addInt32(e),this.slot(t))}addFieldInt64(t,e,s){(this.force_defaults||!e.equals(s))&&(this.addInt64(e),this.slot(t))}addFieldFloat32(t,e,s){(this.force_defaults||e!=s)&&(this.addFloat32(e),this.slot(t))}addFieldFloat64(t,e,s){(this.force_defaults||e!=s)&&(this.addFloat64(e),this.slot(t))}addFieldOffset(t,e,s){(this.force_defaults||e!=s)&&(this.addOffset(e),this.slot(t))}addFieldStruct(t,e,s){e!=s&&(this.nested(e),this.slot(t))}nested(t){if(t!=this.offset())throw new Error("FlatBuffers: struct must be serialized inline.")}notNested(){if(this.isNested)throw new Error("FlatBuffers: object serialization must not be nested.")}slot(t){this.vtable!==null&&(this.vtable[t]=this.offset())}offset(){return this.bb.capacity()-this.space}static growByteBuffer(t){const e=t.capacity();if(e&3221225472)throw new Error("FlatBuffers: cannot grow buffer beyond 2 gigabytes.");const s=e<<1,l=Ml.allocate(s);return l.setPosition(s-e),l.bytes().set(t.bytes(),s-e),l}addOffset(t){this.prep(Ii,0),this.writeInt32(this.offset()-t+Ii)}startObject(t){this.notNested(),this.vtable==null&&(this.vtable=[]),this.vtable_in_use=t;for(let e=0;e<t;e++)this.vtable[e]=0;this.isNested=!0,this.object_start=this.offset()}endObject(){if(this.vtable==null||!this.isNested)throw new Error("FlatBuffers: endObject called without startObject");this.addInt32(0);const t=this.offset();let e=this.vtable_in_use-1;for(;e>=0&&this.vtable[e]==0;e--);const s=e+1;for(;e>=0;e--)this.addInt16(this.vtable[e]!=0?t-this.vtable[e]:0);const l=2;this.addInt16(t-this.object_start);const o=(s+l)*Tp;this.addInt16(o);let c=0;const f=this.space;t:for(e=0;e<this.vtables.length;e++){const h=this.bb.capacity()-this.vtables[e];if(o==this.bb.readInt16(h)){for(let p=Tp;p<o;p+=Tp)if(this.bb.readInt16(f+p)!=this.bb.readInt16(h+p))continue t;c=this.vtables[e];break}}return c?(this.space=this.bb.capacity()-t,this.bb.writeInt32(this.space,c-t)):(this.vtables.push(this.offset()),this.bb.writeInt32(this.bb.capacity()-t,this.offset()-t)),this.isNested=!1,t}finish(t,e,s){const l=s?ce:0;if(e){const o=e;if(this.prep(this.minalign,Ii+Sr+l),o.length!=Sr)throw new Error("FlatBuffers: file identifier must be length "+Sr);for(let c=Sr-1;c>=0;c--)this.writeInt8(o.charCodeAt(c))}this.prep(this.minalign,Ii+l),this.addOffset(t),l&&this.addInt32(this.bb.capacity()-this.space),this.bb.setPosition(this.space)}finishSizePrefixed(t,e){this.finish(t,e,!0)}requiredField(t,e){const s=this.bb.capacity()-t,l=s-this.bb.readInt32(s);if(!(this.bb.readInt16(l+e)!=0))throw new Error("FlatBuffers: field "+e+" must be set")}startVector(t,e,s){this.notNested(),this.vector_num_elems=e,this.prep(Ii,t*e),this.prep(s,t*e)}endVector(){return this.writeInt32(this.vector_num_elems),this.offset()}createSharedString(t){if(!t)return 0;if(this.string_maps||(this.string_maps=new Map),this.string_maps.has(t))return this.string_maps.get(t);const e=this.createString(t);return this.string_maps.set(t,e),e}createString(t){if(!t)return 0;let e;if(t instanceof Uint8Array)e=t;else{e=[];let s=0;for(;s<t.length;){let l;const o=t.charCodeAt(s++);if(o<55296||o>=56320)l=o;else{const c=t.charCodeAt(s++);l=(o<<10)+c+-56613888}l<128?e.push(l):(l<2048?e.push(l>>6&31|192):(l<65536?e.push(l>>12&15|224):e.push(l>>18&7|240,l>>12&63|128),e.push(l>>6&63|128)),e.push(l&63|128))}}this.addInt8(0),this.startVector(1,e.length,1),this.bb.setPosition(this.space-=e.length);for(let s=0,l=this.space,o=this.bb.bytes();s<e.length;s++)o[l++]=e[s];return this.endVector()}createLong(t,e){return Ar.create(t,e)}createObjectOffset(t){return t===null?0:typeof t=="string"?this.createString(t):t.pack(this)}createObjectOffsetList(t){const e=[];for(let s=0;s<t.length;++s){const l=t[s];if(l!==null)e.push(this.createObjectOffset(l));else throw new Error("FlatBuffers: Argument for createObjectOffsetList cannot contain null.")}return e}createStructOffsetList(t,e){return e(this,t.length),this.createObjectOffsetList(t),this.endVector()}};class Le{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsKeyValue(t,e){return(e||new Le).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsKeyValue(t,e){return t.setPosition(t.position()+ce),(e||new Le).__init(t.readInt32(t.position())+t.position(),t)}key(t){const e=this.bb.__offset(this.bb_pos,4);return e?this.bb.__string(this.bb_pos+e,t):null}value(t){const e=this.bb.__offset(this.bb_pos,6);return e?this.bb.__string(this.bb_pos+e,t):null}static startKeyValue(t){t.startObject(2)}static addKey(t,e){t.addFieldOffset(0,e,0)}static addValue(t,e){t.addFieldOffset(1,e,0)}static endKeyValue(t){return t.endObject()}static createKeyValue(t,e,s){return Le.startKeyValue(t),Le.addKey(t,e),Le.addValue(t,s),Le.endKeyValue(t)}}var Bl;(function(n){n[n.V1=0]="V1",n[n.V2=1]="V2",n[n.V3=2]="V3",n[n.V4=3]="V4",n[n.V5=4]="V5"})(Bl||(Bl={}));var Rl;(function(n){n[n.Little=0]="Little",n[n.Big=1]="Big"})(Rl||(Rl={}));var Zf;(function(n){n[n.DenseArray=0]="DenseArray"})(Zf||(Zf={}));class Ln{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsInt(t,e){return(e||new Ln).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsInt(t,e){return t.setPosition(t.position()+ce),(e||new Ln).__init(t.readInt32(t.position())+t.position(),t)}bitWidth(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt32(this.bb_pos+t):0}isSigned(){const t=this.bb.__offset(this.bb_pos,6);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startInt(t){t.startObject(2)}static addBitWidth(t,e){t.addFieldInt32(0,e,0)}static addIsSigned(t,e){t.addFieldInt8(1,+e,0)}static endInt(t){return t.endObject()}static createInt(t,e,s){return Ln.startInt(t),Ln.addBitWidth(t,e),Ln.addIsSigned(t,s),Ln.endInt(t)}}class Tr{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsDictionaryEncoding(t,e){return(e||new Tr).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDictionaryEncoding(t,e){return t.setPosition(t.position()+ce),(e||new Tr).__init(t.readInt32(t.position())+t.position(),t)}id(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}indexType(t){const e=this.bb.__offset(this.bb_pos,6);return e?(t||new Ln).__init(this.bb.__indirect(this.bb_pos+e),this.bb):null}isOrdered(){const t=this.bb.__offset(this.bb_pos,8);return t?!!this.bb.readInt8(this.bb_pos+t):!1}dictionaryKind(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.readInt16(this.bb_pos+t):Zf.DenseArray}static startDictionaryEncoding(t){t.startObject(4)}static addId(t,e){t.addFieldInt64(0,e,t.createLong(0,0))}static addIndexType(t,e){t.addFieldOffset(1,e,0)}static addIsOrdered(t,e){t.addFieldInt8(2,+e,0)}static addDictionaryKind(t,e){t.addFieldInt16(3,e,Zf.DenseArray)}static endDictionaryEncoding(t){return t.endObject()}}class Qs{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsBinary(t,e){return(e||new Qs).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBinary(t,e){return t.setPosition(t.position()+ce),(e||new Qs).__init(t.readInt32(t.position())+t.position(),t)}static startBinary(t){t.startObject(0)}static endBinary(t){return t.endObject()}static createBinary(t){return Qs.startBinary(t),Qs.endBinary(t)}}class Js{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsBool(t,e){return(e||new Js).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBool(t,e){return t.setPosition(t.position()+ce),(e||new Js).__init(t.readInt32(t.position())+t.position(),t)}static startBool(t){t.startObject(0)}static endBool(t){return t.endObject()}static createBool(t){return Js.startBool(t),Js.endBool(t)}}var Xf;(function(n){n[n.DAY=0]="DAY",n[n.MILLISECOND=1]="MILLISECOND"})(Xf||(Xf={}));let wf=class hl{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsDate(t,e){return(e||new hl).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDate(t,e){return t.setPosition(t.position()+ce),(e||new hl).__init(t.readInt32(t.position())+t.position(),t)}unit(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Xf.MILLISECOND}static startDate(t){t.startObject(1)}static addUnit(t,e){t.addFieldInt16(0,e,Xf.MILLISECOND)}static endDate(t){return t.endObject()}static createDate(t,e){return hl.startDate(t),hl.addUnit(t,e),hl.endDate(t)}};class yn{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsDecimal(t,e){return(e||new yn).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDecimal(t,e){return t.setPosition(t.position()+ce),(e||new yn).__init(t.readInt32(t.position())+t.position(),t)}precision(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt32(this.bb_pos+t):0}scale(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt32(this.bb_pos+t):0}bitWidth(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.readInt32(this.bb_pos+t):128}static startDecimal(t){t.startObject(3)}static addPrecision(t,e){t.addFieldInt32(0,e,0)}static addScale(t,e){t.addFieldInt32(1,e,0)}static addBitWidth(t,e){t.addFieldInt32(2,e,128)}static endDecimal(t){return t.endObject()}static createDecimal(t,e,s,l){return yn.startDecimal(t),yn.addPrecision(t,e),yn.addScale(t,s),yn.addBitWidth(t,l),yn.endDecimal(t)}}var Fl;(function(n){n[n.SECOND=0]="SECOND",n[n.MILLISECOND=1]="MILLISECOND",n[n.MICROSECOND=2]="MICROSECOND",n[n.NANOSECOND=3]="NANOSECOND"})(Fl||(Fl={}));class ki{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsFixedSizeBinary(t,e){return(e||new ki).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFixedSizeBinary(t,e){return t.setPosition(t.position()+ce),(e||new ki).__init(t.readInt32(t.position())+t.position(),t)}byteWidth(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt32(this.bb_pos+t):0}static startFixedSizeBinary(t){t.startObject(1)}static addByteWidth(t,e){t.addFieldInt32(0,e,0)}static endFixedSizeBinary(t){return t.endObject()}static createFixedSizeBinary(t,e){return ki.startFixedSizeBinary(t),ki.addByteWidth(t,e),ki.endFixedSizeBinary(t)}}class Ui{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsFixedSizeList(t,e){return(e||new Ui).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFixedSizeList(t,e){return t.setPosition(t.position()+ce),(e||new Ui).__init(t.readInt32(t.position())+t.position(),t)}listSize(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt32(this.bb_pos+t):0}static startFixedSizeList(t){t.startObject(1)}static addListSize(t,e){t.addFieldInt32(0,e,0)}static endFixedSizeList(t){return t.endObject()}static createFixedSizeList(t,e){return Ui.startFixedSizeList(t),Ui.addListSize(t,e),Ui.endFixedSizeList(t)}}var Qf;(function(n){n[n.HALF=0]="HALF",n[n.SINGLE=1]="SINGLE",n[n.DOUBLE=2]="DOUBLE"})(Qf||(Qf={}));class zi{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsFloatingPoint(t,e){return(e||new zi).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFloatingPoint(t,e){return t.setPosition(t.position()+ce),(e||new zi).__init(t.readInt32(t.position())+t.position(),t)}precision(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Qf.HALF}static startFloatingPoint(t){t.startObject(1)}static addPrecision(t,e){t.addFieldInt16(0,e,Qf.HALF)}static endFloatingPoint(t){return t.endObject()}static createFloatingPoint(t,e){return zi.startFloatingPoint(t),zi.addPrecision(t,e),zi.endFloatingPoint(t)}}var Jf;(function(n){n[n.YEAR_MONTH=0]="YEAR_MONTH",n[n.DAY_TIME=1]="DAY_TIME",n[n.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"})(Jf||(Jf={}));class $i{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsInterval(t,e){return(e||new $i).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsInterval(t,e){return t.setPosition(t.position()+ce),(e||new $i).__init(t.readInt32(t.position())+t.position(),t)}unit(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Jf.YEAR_MONTH}static startInterval(t){t.startObject(1)}static addUnit(t,e){t.addFieldInt16(0,e,Jf.YEAR_MONTH)}static endInterval(t){return t.endObject()}static createInterval(t,e){return $i.startInterval(t),$i.addUnit(t,e),$i.endInterval(t)}}class Ws{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsList(t,e){return(e||new Ws).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsList(t,e){return t.setPosition(t.position()+ce),(e||new Ws).__init(t.readInt32(t.position())+t.position(),t)}static startList(t){t.startObject(0)}static endList(t){return t.endObject()}static createList(t){return Ws.startList(t),Ws.endList(t)}}let xf=class gl{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsMap(t,e){return(e||new gl).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsMap(t,e){return t.setPosition(t.position()+ce),(e||new gl).__init(t.readInt32(t.position())+t.position(),t)}keysSorted(){const t=this.bb.__offset(this.bb_pos,4);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startMap(t){t.startObject(1)}static addKeysSorted(t,e){t.addFieldInt8(0,+e,0)}static endMap(t){return t.endObject()}static createMap(t,e){return gl.startMap(t),gl.addKeysSorted(t,e),gl.endMap(t)}};class ta{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsNull(t,e){return(e||new ta).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsNull(t,e){return t.setPosition(t.position()+ce),(e||new ta).__init(t.readInt32(t.position())+t.position(),t)}static startNull(t){t.startObject(0)}static endNull(t){return t.endObject()}static createNull(t){return ta.startNull(t),ta.endNull(t)}}class ea{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsStruct_(t,e){return(e||new ea).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsStruct_(t,e){return t.setPosition(t.position()+ce),(e||new ea).__init(t.readInt32(t.position())+t.position(),t)}static startStruct_(t){t.startObject(0)}static endStruct_(t){return t.endObject()}static createStruct_(t){return ea.startStruct_(t),ea.endStruct_(t)}}class ni{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsTime(t,e){return(e||new ni).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsTime(t,e){return t.setPosition(t.position()+ce),(e||new ni).__init(t.readInt32(t.position())+t.position(),t)}unit(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Fl.MILLISECOND}bitWidth(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt32(this.bb_pos+t):32}static startTime(t){t.startObject(2)}static addUnit(t,e){t.addFieldInt16(0,e,Fl.MILLISECOND)}static addBitWidth(t,e){t.addFieldInt32(1,e,32)}static endTime(t){return t.endObject()}static createTime(t,e,s){return ni.startTime(t),ni.addUnit(t,e),ni.addBitWidth(t,s),ni.endTime(t)}}class ii{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsTimestamp(t,e){return(e||new ii).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsTimestamp(t,e){return t.setPosition(t.position()+ce),(e||new ii).__init(t.readInt32(t.position())+t.position(),t)}unit(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Fl.SECOND}timezone(t){const e=this.bb.__offset(this.bb_pos,6);return e?this.bb.__string(this.bb_pos+e,t):null}static startTimestamp(t){t.startObject(2)}static addUnit(t,e){t.addFieldInt16(0,e,Fl.SECOND)}static addTimezone(t,e){t.addFieldOffset(1,e,0)}static endTimestamp(t){return t.endObject()}static createTimestamp(t,e,s){return ii.startTimestamp(t),ii.addUnit(t,e),ii.addTimezone(t,s),ii.endTimestamp(t)}}var Wf;(function(n){n[n.Sparse=0]="Sparse",n[n.Dense=1]="Dense"})(Wf||(Wf={}));class mn{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsUnion(t,e){return(e||new mn).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsUnion(t,e){return t.setPosition(t.position()+ce),(e||new mn).__init(t.readInt32(t.position())+t.position(),t)}mode(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Wf.Sparse}typeIds(t){const e=this.bb.__offset(this.bb_pos,6);return e?this.bb.readInt32(this.bb.__vector(this.bb_pos+e)+t*4):0}typeIdsLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}typeIdsArray(){const t=this.bb.__offset(this.bb_pos,6);return t?new Int32Array(this.bb.bytes().buffer,this.bb.bytes().byteOffset+this.bb.__vector(this.bb_pos+t),this.bb.__vector_len(this.bb_pos+t)):null}static startUnion(t){t.startObject(2)}static addMode(t,e){t.addFieldInt16(0,e,Wf.Sparse)}static addTypeIds(t,e){t.addFieldOffset(1,e,0)}static createTypeIdsVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addInt32(e[s]);return t.endVector()}static startTypeIdsVector(t,e){t.startVector(4,e,4)}static endUnion(t){return t.endObject()}static createUnion(t,e,s){return mn.startUnion(t),mn.addMode(t,e),mn.addTypeIds(t,s),mn.endUnion(t)}}class na{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsUtf8(t,e){return(e||new na).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsUtf8(t,e){return t.setPosition(t.position()+ce),(e||new na).__init(t.readInt32(t.position())+t.position(),t)}static startUtf8(t){t.startObject(0)}static endUtf8(t){return t.endObject()}static createUtf8(t){return na.startUtf8(t),na.endUtf8(t)}}var me;(function(n){n[n.NONE=0]="NONE",n[n.Null=1]="Null",n[n.Int=2]="Int",n[n.FloatingPoint=3]="FloatingPoint",n[n.Binary=4]="Binary",n[n.Utf8=5]="Utf8",n[n.Bool=6]="Bool",n[n.Decimal=7]="Decimal",n[n.Date=8]="Date",n[n.Time=9]="Time",n[n.Timestamp=10]="Timestamp",n[n.Interval=11]="Interval",n[n.List=12]="List",n[n.Struct_=13]="Struct_",n[n.Union=14]="Union",n[n.FixedSizeBinary=15]="FixedSizeBinary",n[n.FixedSizeList=16]="FixedSizeList",n[n.Map=17]="Map",n[n.Duration=18]="Duration",n[n.LargeBinary=19]="LargeBinary",n[n.LargeUtf8=20]="LargeUtf8",n[n.LargeList=21]="LargeList"})(me||(me={}));let ti=class Af{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsField(t,e){return(e||new Af).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsField(t,e){return t.setPosition(t.position()+ce),(e||new Af).__init(t.readInt32(t.position())+t.position(),t)}name(t){const e=this.bb.__offset(this.bb_pos,4);return e?this.bb.__string(this.bb_pos+e,t):null}nullable(){const t=this.bb.__offset(this.bb_pos,6);return t?!!this.bb.readInt8(this.bb_pos+t):!1}typeType(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.readUint8(this.bb_pos+t):me.NONE}type(t){const e=this.bb.__offset(this.bb_pos,10);return e?this.bb.__union(t,this.bb_pos+e):null}dictionary(t){const e=this.bb.__offset(this.bb_pos,12);return e?(t||new Tr).__init(this.bb.__indirect(this.bb_pos+e),this.bb):null}children(t,e){const s=this.bb.__offset(this.bb_pos,14);return s?(e||new Af).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}childrenLength(){const t=this.bb.__offset(this.bb_pos,14);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,e){const s=this.bb.__offset(this.bb_pos,16);return s?(e||new Le).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,16);return t?this.bb.__vector_len(this.bb_pos+t):0}static startField(t){t.startObject(7)}static addName(t,e){t.addFieldOffset(0,e,0)}static addNullable(t,e){t.addFieldInt8(1,+e,0)}static addTypeType(t,e){t.addFieldInt8(2,e,me.NONE)}static addType(t,e){t.addFieldOffset(3,e,0)}static addDictionary(t,e){t.addFieldOffset(4,e,0)}static addChildren(t,e){t.addFieldOffset(5,e,0)}static createChildrenVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startChildrenVector(t,e){t.startVector(4,e,4)}static addCustomMetadata(t,e){t.addFieldOffset(6,e,0)}static createCustomMetadataVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startCustomMetadataVector(t,e){t.startVector(4,e,4)}static endField(t){return t.endObject()}},Di=class hr{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsSchema(t,e){return(e||new hr).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsSchema(t,e){return t.setPosition(t.position()+ce),(e||new hr).__init(t.readInt32(t.position())+t.position(),t)}endianness(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Rl.Little}fields(t,e){const s=this.bb.__offset(this.bb_pos,6);return s?(e||new ti).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}fieldsLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,e){const s=this.bb.__offset(this.bb_pos,8);return s?(e||new Le).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}features(t){const e=this.bb.__offset(this.bb_pos,10);return e?this.bb.readInt64(this.bb.__vector(this.bb_pos+e)+t*8):this.bb.createLong(0,0)}featuresLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}static startSchema(t){t.startObject(4)}static addEndianness(t,e){t.addFieldInt16(0,e,Rl.Little)}static addFields(t,e){t.addFieldOffset(1,e,0)}static createFieldsVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startFieldsVector(t,e){t.startVector(4,e,4)}static addCustomMetadata(t,e){t.addFieldOffset(2,e,0)}static createCustomMetadataVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startCustomMetadataVector(t,e){t.startVector(4,e,4)}static addFeatures(t,e){t.addFieldOffset(3,e,0)}static createFeaturesVector(t,e){t.startVector(8,e.length,8);for(let s=e.length-1;s>=0;s--)t.addInt64(e[s]);return t.endVector()}static startFeaturesVector(t,e){t.startVector(8,e,8)}static endSchema(t){return t.endObject()}static finishSchemaBuffer(t,e){t.finish(e)}static finishSizePrefixedSchemaBuffer(t,e){t.finish(e,void 0,!0)}static createSchema(t,e,s,l,o){return hr.startSchema(t),hr.addEndianness(t,e),hr.addFields(t,s),hr.addCustomMetadata(t,l),hr.addFeatures(t,o),hr.endSchema(t)}};class Fn{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsFooter(t,e){return(e||new Fn).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFooter(t,e){return t.setPosition(t.position()+ce),(e||new Fn).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Bl.V1}schema(t){const e=this.bb.__offset(this.bb_pos,6);return e?(t||new Di).__init(this.bb.__indirect(this.bb_pos+e),this.bb):null}dictionaries(t,e){const s=this.bb.__offset(this.bb_pos,8);return s?(e||new Qp).__init(this.bb.__vector(this.bb_pos+s)+t*24,this.bb):null}dictionariesLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}recordBatches(t,e){const s=this.bb.__offset(this.bb_pos,10);return s?(e||new Qp).__init(this.bb.__vector(this.bb_pos+s)+t*24,this.bb):null}recordBatchesLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,e){const s=this.bb.__offset(this.bb_pos,12);return s?(e||new Le).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startFooter(t){t.startObject(5)}static addVersion(t,e){t.addFieldInt16(0,e,Bl.V1)}static addSchema(t,e){t.addFieldOffset(1,e,0)}static addDictionaries(t,e){t.addFieldOffset(2,e,0)}static startDictionariesVector(t,e){t.startVector(24,e,8)}static addRecordBatches(t,e){t.addFieldOffset(3,e,0)}static startRecordBatchesVector(t,e){t.startVector(24,e,8)}static addCustomMetadata(t,e){t.addFieldOffset(4,e,0)}static createCustomMetadataVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startCustomMetadataVector(t,e){t.startVector(4,e,4)}static endFooter(t){return t.endObject()}static finishFooterBuffer(t,e){t.finish(e)}static finishSizePrefixedFooterBuffer(t,e){t.finish(e,void 0,!0)}}class te{constructor(t=[],e,s){this.fields=t||[],this.metadata=e||new Map,s||(s=ty(t)),this.dictionaries=s}get[Symbol.toStringTag](){return"Schema"}get names(){return this.fields.map(t=>t.name)}toString(){return`Schema<{ ${this.fields.map((t,e)=>`${e}: ${t}`).join(", ")} }>`}select(t){const e=new Set(t),s=this.fields.filter(l=>e.has(l.name));return new te(s,this.metadata)}selectAt(t){const e=t.map(s=>this.fields[s]).filter(Boolean);return new te(e,this.metadata)}assign(...t){const e=t[0]instanceof te?t[0]:Array.isArray(t[0])?new te(t[0]):new te(t),s=[...this.fields],l=ff(ff(new Map,this.metadata),e.metadata),o=e.fields.filter(f=>{const h=s.findIndex(p=>p.name===f.name);return~h?(s[h]=f.clone({metadata:ff(ff(new Map,s[h].metadata),f.metadata)}))&&!1:!0}),c=ty(o,new Map);return new te([...s,...o],l,new Map([...this.dictionaries,...c]))}}te.prototype.fields=null;te.prototype.metadata=null;te.prototype.dictionaries=null;class he{constructor(t,e,s=!1,l){this.name=t,this.type=e,this.nullable=s,this.metadata=l||new Map}static new(...t){let[e,s,l,o]=t;return t[0]&&typeof t[0]=="object"&&({name:e}=t[0],s===void 0&&(s=t[0].type),l===void 0&&(l=t[0].nullable),o===void 0&&(o=t[0].metadata)),new he(`${e}`,s,l,o)}get typeId(){return this.type.typeId}get[Symbol.toStringTag](){return"Field"}toString(){return`${this.name}: ${this.type}`}clone(...t){let[e,s,l,o]=t;return!t[0]||typeof t[0]!="object"?[e=this.name,s=this.type,l=this.nullable,o=this.metadata]=t:{name:e=this.name,type:s=this.type,nullable:l=this.nullable,metadata:o=this.metadata}=t[0],he.new(e,s,l,o)}}he.prototype.type=null;he.prototype.name=null;he.prototype.nullable=null;he.prototype.metadata=null;function ff(n,t){return new Map([...n||new Map,...t||new Map])}function ty(n,t=new Map){for(let e=-1,s=n.length;++e<s;){const o=n[e].type;if(wt.isDictionary(o)){if(!t.has(o.id))t.set(o.id,o.dictionary);else if(t.get(o.id)!==o.dictionary)throw new Error("Cannot create Schema containing two different dictionaries with the same Id")}o.children&&o.children.length>0&&ty(o.children,t)}return t}var TS=Ar,AD=Yw,ED=Ml;class wu{constructor(t,e=kn.V4,s,l){this.schema=t,this.version=e,s&&(this._recordBatches=s),l&&(this._dictionaryBatches=l)}static decode(t){t=new ED(Zt(t));const e=Fn.getRootAsFooter(t),s=te.decode(e.schema());return new OD(s,e)}static encode(t){const e=new AD,s=te.encode(e,t.schema);Fn.startRecordBatchesVector(e,t.numRecordBatches);for(const c of[...t.recordBatches()].slice().reverse())ps.encode(e,c);const l=e.endVector();Fn.startDictionariesVector(e,t.numDictionaries);for(const c of[...t.dictionaryBatches()].slice().reverse())ps.encode(e,c);const o=e.endVector();return Fn.startFooter(e),Fn.addSchema(e,s),Fn.addVersion(e,kn.V4),Fn.addRecordBatches(e,l),Fn.addDictionaries(e,o),Fn.finishFooterBuffer(e,Fn.endFooter(e)),e.asUint8Array()}get numRecordBatches(){return this._recordBatches.length}get numDictionaries(){return this._dictionaryBatches.length}*recordBatches(){for(let t,e=-1,s=this.numRecordBatches;++e<s;)(t=this.getRecordBatch(e))&&(yield t)}*dictionaryBatches(){for(let t,e=-1,s=this.numDictionaries;++e<s;)(t=this.getDictionaryBatch(e))&&(yield t)}getRecordBatch(t){return t>=0&&t<this.numRecordBatches&&this._recordBatches[t]||null}getDictionaryBatch(t){return t>=0&&t<this.numDictionaries&&this._dictionaryBatches[t]||null}}class OD extends wu{constructor(t,e){super(t,e.version()),this._footer=e}get numRecordBatches(){return this._footer.recordBatchesLength()}get numDictionaries(){return this._footer.dictionariesLength()}getRecordBatch(t){if(t>=0&&t<this.numRecordBatches){const e=this._footer.recordBatches(t);if(e)return ps.decode(e)}return null}getDictionaryBatch(t){if(t>=0&&t<this.numDictionaries){const e=this._footer.dictionaries(t);if(e)return ps.decode(e)}return null}}class ps{constructor(t,e,s){this.metaDataLength=t,this.offset=typeof s=="number"?s:s.low,this.bodyLength=typeof e=="number"?e:e.low}static decode(t){return new ps(t.metaDataLength(),t.bodyLength(),t.offset())}static encode(t,e){const{metaDataLength:s}=e,l=new TS(e.offset,0),o=new TS(e.bodyLength,0);return Qp.createBlock(t,l,s,o)}}const _e=Object.freeze({done:!0,value:void 0});class wS{constructor(t){this._json=t}get schema(){return this._json.schema}get batches(){return this._json.batches||[]}get dictionaries(){return this._json.dictionaries||[]}}class nm{tee(){return this._getDOMStream().tee()}pipe(t,e){return this._getNodeStream().pipe(t,e)}pipeTo(t,e){return this._getDOMStream().pipeTo(t,e)}pipeThrough(t,e){return this._getDOMStream().pipeThrough(t,e)}_getDOMStream(){return this._DOMStream||(this._DOMStream=this.toDOMStream())}_getNodeStream(){return this._nodeStream||(this._nodeStream=this.toNodeStream())}}class ND extends nm{constructor(){super(),this._values=[],this.resolvers=[],this._closedPromise=new Promise(t=>this._closedPromiseResolve=t)}get closed(){return this._closedPromise}cancel(t){return St(this,void 0,void 0,function*(){yield this.return(t)})}write(t){this._ensureOpen()&&(this.resolvers.length<=0?this._values.push(t):this.resolvers.shift().resolve({done:!1,value:t}))}abort(t){this._closedPromiseResolve&&(this.resolvers.length<=0?this._error={error:t}:this.resolvers.shift().reject({done:!0,value:t}))}close(){if(this._closedPromiseResolve){const{resolvers:t}=this;for(;t.length>0;)t.shift().resolve(_e);this._closedPromiseResolve(),this._closedPromiseResolve=void 0}}[Symbol.asyncIterator](){return this}toDOMStream(t){return ei.toDOMStream(this._closedPromiseResolve||this._error?this:this._values,t)}toNodeStream(t){return ei.toNodeStream(this._closedPromiseResolve||this._error?this:this._values,t)}throw(t){return St(this,void 0,void 0,function*(){return yield this.abort(t),_e})}return(t){return St(this,void 0,void 0,function*(){return yield this.close(),_e})}read(t){return St(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return St(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(...t){return this._values.length>0?Promise.resolve({done:!1,value:this._values.shift()}):this._error?Promise.reject({done:!0,value:this._error.error}):this._closedPromiseResolve?new Promise((e,s)=>{this.resolvers.push({resolve:e,reject:s})}):Promise.resolve(_e)}_ensureOpen(){if(this._closedPromiseResolve)return!0;throw new Error("AsyncQueue is closed")}}class Ef extends ND{write(t){if((t=Zt(t)).byteLength>0)return super.write(t)}toString(t=!1){return t?Kp(this.toUint8Array(!0)):this.toUint8Array(!1).then(Kp)}toUint8Array(t=!1){return t?qi(this._values)[0]:St(this,void 0,void 0,function*(){var e,s;const l=[];let o=0;try{for(var c=sa(this),f;f=yield c.next(),!f.done;){const h=f.value;l.push(h),o+=h.byteLength}}catch(h){e={error:h}}finally{try{f&&!f.done&&(s=c.return)&&(yield s.call(c))}finally{if(e)throw e.error}}return qi(l,o)[0]})}}class td{constructor(t){t&&(this.source=new CD(ei.fromIterable(t)))}[Symbol.iterator](){return this}next(t){return this.source.next(t)}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}peek(t){return this.source.peek(t)}read(t){return this.source.read(t)}}class Ll{constructor(t){t instanceof Ll?this.source=t.source:t instanceof Ef?this.source=new qs(ei.fromAsyncIterable(t)):OT(t)?this.source=new qs(ei.fromNodeStream(t)):Vy(t)?this.source=new qs(ei.fromDOMStream(t)):ET(t)?this.source=new qs(ei.fromDOMStream(t.body)):Lu(t)?this.source=new qs(ei.fromIterable(t)):fs(t)?this.source=new qs(ei.fromAsyncIterable(t)):Yl(t)&&(this.source=new qs(ei.fromAsyncIterable(t)))}[Symbol.asyncIterator](){return this}next(t){return this.source.next(t)}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}get closed(){return this.source.closed}cancel(t){return this.source.cancel(t)}peek(t){return this.source.peek(t)}read(t){return this.source.read(t)}}class CD{constructor(t){this.source=t}cancel(t){this.return(t)}peek(t){return this.next(t,"peek").value}read(t){return this.next(t,"read").value}next(t,e="read"){return this.source.next({cmd:e,size:t})}throw(t){return Object.create(this.source.throw&&this.source.throw(t)||_e)}return(t){return Object.create(this.source.return&&this.source.return(t)||_e)}}class qs{constructor(t){this.source=t,this._closedPromise=new Promise(e=>this._closedPromiseResolve=e)}cancel(t){return St(this,void 0,void 0,function*(){yield this.return(t)})}get closed(){return this._closedPromise}read(t){return St(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return St(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(t,e="read"){return St(this,void 0,void 0,function*(){return yield this.source.next({cmd:e,size:t})})}throw(t){return St(this,void 0,void 0,function*(){const e=this.source.throw&&(yield this.source.throw(t))||_e;return this._closedPromiseResolve&&this._closedPromiseResolve(),this._closedPromiseResolve=void 0,Object.create(e)})}return(t){return St(this,void 0,void 0,function*(){const e=this.source.return&&(yield this.source.return(t))||_e;return this._closedPromiseResolve&&this._closedPromiseResolve(),this._closedPromiseResolve=void 0,Object.create(e)})}}class xS extends td{constructor(t,e){super(),this.position=0,this.buffer=Zt(t),this.size=typeof e>"u"?this.buffer.byteLength:e}readInt32(t){const{buffer:e,byteOffset:s}=this.readAt(t,4);return new DataView(e,s).getInt32(0,!0)}seek(t){return this.position=Math.min(t,this.size),t<this.size}read(t){const{buffer:e,size:s,position:l}=this;return e&&l<s?(typeof t!="number"&&(t=Number.POSITIVE_INFINITY),this.position=Math.min(s,l+Math.min(s-l,t)),e.subarray(l,this.position)):null}readAt(t,e){const s=this.buffer,l=Math.min(this.size,t+e);return s?s.subarray(t,l):new Uint8Array(e)}close(){this.buffer&&(this.buffer=null)}throw(t){return this.close(),{done:!0,value:t}}return(t){return this.close(),{done:!0,value:t}}}class ed extends Ll{constructor(t,e){super(),this.position=0,this._handle=t,typeof e=="number"?this.size=e:this._pending=St(this,void 0,void 0,function*(){this.size=(yield t.stat()).size,delete this._pending})}readInt32(t){return St(this,void 0,void 0,function*(){const{buffer:e,byteOffset:s}=yield this.readAt(t,4);return new DataView(e,s).getInt32(0,!0)})}seek(t){return St(this,void 0,void 0,function*(){return this._pending&&(yield this._pending),this.position=Math.min(t,this.size),t<this.size})}read(t){return St(this,void 0,void 0,function*(){this._pending&&(yield this._pending);const{_handle:e,size:s,position:l}=this;if(e&&l<s){typeof t!="number"&&(t=Number.POSITIVE_INFINITY);let o=l,c=0,f=0;const h=Math.min(s,o+Math.min(s-o,t)),p=new Uint8Array(Math.max(0,(this.position=h)-o));for(;(o+=f)<h&&(c+=f)<p.byteLength;)({bytesRead:f}=yield e.read(p,c,p.byteLength-c,o));return p}return null})}readAt(t,e){return St(this,void 0,void 0,function*(){this._pending&&(yield this._pending);const{_handle:s,size:l}=this;if(s&&t+e<l){const o=Math.min(l,t+e),c=new Uint8Array(o-t);return(yield s.read(c,0,e,t)).buffer}return new Uint8Array(e)})}close(){return St(this,void 0,void 0,function*(){const t=this._handle;this._handle=null,t&&(yield t.close())})}throw(t){return St(this,void 0,void 0,function*(){return yield this.close(),{done:!0,value:t}})}return(t){return St(this,void 0,void 0,function*(){return yield this.close(),{done:!0,value:t}})}}const DD=65536;function _l(n){return n<0&&(n=4294967295+n+1),`0x${n.toString(16)}`}const Il=8,im=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8];class Kw{constructor(t){this.buffer=t}high(){return this.buffer[1]}low(){return this.buffer[0]}_times(t){const e=new Uint32Array([this.buffer[1]>>>16,this.buffer[1]&65535,this.buffer[0]>>>16,this.buffer[0]&65535]),s=new Uint32Array([t.buffer[1]>>>16,t.buffer[1]&65535,t.buffer[0]>>>16,t.buffer[0]&65535]);let l=e[3]*s[3];this.buffer[0]=l&65535;let o=l>>>16;return l=e[2]*s[3],o+=l,l=e[3]*s[2]>>>0,o+=l,this.buffer[0]+=o<<16,this.buffer[1]=o>>>0<l?DD:0,this.buffer[1]+=o>>>16,this.buffer[1]+=e[1]*s[3]+e[2]*s[2]+e[3]*s[1],this.buffer[1]+=e[0]*s[3]+e[1]*s[2]+e[2]*s[1]+e[3]*s[0]<<16,this}_plus(t){const e=this.buffer[0]+t.buffer[0]>>>0;this.buffer[1]+=t.buffer[1],e<this.buffer[0]>>>0&&++this.buffer[1],this.buffer[0]=e}lessThan(t){return this.buffer[1]<t.buffer[1]||this.buffer[1]===t.buffer[1]&&this.buffer[0]<t.buffer[0]}equals(t){return this.buffer[1]===t.buffer[1]&&this.buffer[0]==t.buffer[0]}greaterThan(t){return t.lessThan(this)}hex(){return`${_l(this.buffer[1])} ${_l(this.buffer[0])}`}}class re extends Kw{times(t){return this._times(t),this}plus(t){return this._plus(t),this}static from(t,e=new Uint32Array(2)){return re.fromString(typeof t=="string"?t:t.toString(),e)}static fromNumber(t,e=new Uint32Array(2)){return re.fromString(t.toString(),e)}static fromString(t,e=new Uint32Array(2)){const s=t.length,l=new re(e);for(let o=0;o<s;){const c=Il<s-o?Il:s-o,f=new re(new Uint32Array([Number.parseInt(t.slice(o,o+c),10),0])),h=new re(new Uint32Array([im[c],0]));l.times(h),l.plus(f),o+=c}return l}static convertArray(t){const e=new Uint32Array(t.length*2);for(let s=-1,l=t.length;++s<l;)re.from(t[s],new Uint32Array(e.buffer,e.byteOffset+2*s*4,2));return e}static multiply(t,e){return new re(new Uint32Array(t.buffer)).times(e)}static add(t,e){return new re(new Uint32Array(t.buffer)).plus(e)}}class pn extends Kw{negate(){return this.buffer[0]=~this.buffer[0]+1,this.buffer[1]=~this.buffer[1],this.buffer[0]==0&&++this.buffer[1],this}times(t){return this._times(t),this}plus(t){return this._plus(t),this}lessThan(t){const e=this.buffer[1]<<0,s=t.buffer[1]<<0;return e<s||e===s&&this.buffer[0]<t.buffer[0]}static from(t,e=new Uint32Array(2)){return pn.fromString(typeof t=="string"?t:t.toString(),e)}static fromNumber(t,e=new Uint32Array(2)){return pn.fromString(t.toString(),e)}static fromString(t,e=new Uint32Array(2)){const s=t.startsWith("-"),l=t.length,o=new pn(e);for(let c=s?1:0;c<l;){const f=Il<l-c?Il:l-c,h=new pn(new Uint32Array([Number.parseInt(t.slice(c,c+f),10),0])),p=new pn(new Uint32Array([im[f],0]));o.times(p),o.plus(h),c+=f}return s?o.negate():o}static convertArray(t){const e=new Uint32Array(t.length*2);for(let s=-1,l=t.length;++s<l;)pn.from(t[s],new Uint32Array(e.buffer,e.byteOffset+2*s*4,2));return e}static multiply(t,e){return new pn(new Uint32Array(t.buffer)).times(e)}static add(t,e){return new pn(new Uint32Array(t.buffer)).plus(e)}}class Mi{constructor(t){this.buffer=t}high(){return new pn(new Uint32Array(this.buffer.buffer,this.buffer.byteOffset+8,2))}low(){return new pn(new Uint32Array(this.buffer.buffer,this.buffer.byteOffset,2))}negate(){return this.buffer[0]=~this.buffer[0]+1,this.buffer[1]=~this.buffer[1],this.buffer[2]=~this.buffer[2],this.buffer[3]=~this.buffer[3],this.buffer[0]==0&&++this.buffer[1],this.buffer[1]==0&&++this.buffer[2],this.buffer[2]==0&&++this.buffer[3],this}times(t){const e=new re(new Uint32Array([this.buffer[3],0])),s=new re(new Uint32Array([this.buffer[2],0])),l=new re(new Uint32Array([this.buffer[1],0])),o=new re(new Uint32Array([this.buffer[0],0])),c=new re(new Uint32Array([t.buffer[3],0])),f=new re(new Uint32Array([t.buffer[2],0])),h=new re(new Uint32Array([t.buffer[1],0])),p=new re(new Uint32Array([t.buffer[0],0]));let y=re.multiply(o,p);this.buffer[0]=y.low();const m=new re(new Uint32Array([y.high(),0]));return y=re.multiply(l,p),m.plus(y),y=re.multiply(o,h),m.plus(y),this.buffer[1]=m.low(),this.buffer[3]=m.lessThan(y)?1:0,this.buffer[2]=m.high(),new re(new Uint32Array(this.buffer.buffer,this.buffer.byteOffset+8,2)).plus(re.multiply(s,p)).plus(re.multiply(l,h)).plus(re.multiply(o,f)),this.buffer[3]+=re.multiply(e,p).plus(re.multiply(s,h)).plus(re.multiply(l,f)).plus(re.multiply(o,c)).low(),this}plus(t){const e=new Uint32Array(4);return e[3]=this.buffer[3]+t.buffer[3]>>>0,e[2]=this.buffer[2]+t.buffer[2]>>>0,e[1]=this.buffer[1]+t.buffer[1]>>>0,e[0]=this.buffer[0]+t.buffer[0]>>>0,e[0]<this.buffer[0]>>>0&&++e[1],e[1]<this.buffer[1]>>>0&&++e[2],e[2]<this.buffer[2]>>>0&&++e[3],this.buffer[3]=e[3],this.buffer[2]=e[2],this.buffer[1]=e[1],this.buffer[0]=e[0],this}hex(){return`${_l(this.buffer[3])} ${_l(this.buffer[2])} ${_l(this.buffer[1])} ${_l(this.buffer[0])}`}static multiply(t,e){return new Mi(new Uint32Array(t.buffer)).times(e)}static add(t,e){return new Mi(new Uint32Array(t.buffer)).plus(e)}static from(t,e=new Uint32Array(4)){return Mi.fromString(typeof t=="string"?t:t.toString(),e)}static fromNumber(t,e=new Uint32Array(4)){return Mi.fromString(t.toString(),e)}static fromString(t,e=new Uint32Array(4)){const s=t.startsWith("-"),l=t.length,o=new Mi(e);for(let c=s?1:0;c<l;){const f=Il<l-c?Il:l-c,h=new Mi(new Uint32Array([Number.parseInt(t.slice(c,c+f),10),0,0,0])),p=new Mi(new Uint32Array([im[f],0,0,0]));o.times(p),o.plus(h),c+=f}return s?o.negate():o}static convertArray(t){const e=new Uint32Array(t.length*4);for(let s=-1,l=t.length;++s<l;)Mi.from(t[s],new Uint32Array(e.buffer,e.byteOffset+4*4*s,4));return e}}class Pw extends jt{constructor(t,e,s,l){super(),this.nodesIndex=-1,this.buffersIndex=-1,this.bytes=t,this.nodes=e,this.buffers=s,this.dictionaries=l}visit(t){return super.visit(t instanceof he?t.type:t)}visitNull(t,{length:e}=this.nextFieldNode()){return $t({type:t,length:e})}visitBool(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitInt(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitFloat(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitUtf8(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),valueOffsets:this.readOffsets(t),data:this.readData(t)})}visitBinary(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),valueOffsets:this.readOffsets(t),data:this.readData(t)})}visitFixedSizeBinary(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitDate(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitTimestamp(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitTime(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitDecimal(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitList(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),valueOffsets:this.readOffsets(t),child:this.visit(t.children[0])})}visitStruct(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),children:this.visitMany(t.children)})}visitUnion(t){return t.mode===Un.Sparse?this.visitSparseUnion(t):this.visitDenseUnion(t)}visitDenseUnion(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),typeIds:this.readTypeIds(t),valueOffsets:this.readOffsets(t),children:this.visitMany(t.children)})}visitSparseUnion(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),typeIds:this.readTypeIds(t),children:this.visitMany(t.children)})}visitDictionary(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t.indices),dictionary:this.readDictionary(t)})}visitInterval(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),data:this.readData(t)})}visitFixedSizeList(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),child:this.visit(t.children[0])})}visitMap(t,{length:e,nullCount:s}=this.nextFieldNode()){return $t({type:t,length:e,nullCount:s,nullBitmap:this.readNullBitmap(t,s),valueOffsets:this.readOffsets(t),child:this.visit(t.children[0])})}nextFieldNode(){return this.nodes[++this.nodesIndex]}nextBufferRange(){return this.buffers[++this.buffersIndex]}readNullBitmap(t,e,s=this.nextBufferRange()){return e>0&&this.readData(t,s)||new Uint8Array(0)}readOffsets(t,e){return this.readData(t,e)}readTypeIds(t,e){return this.readData(t,e)}readData(t,{length:e,offset:s}=this.nextBufferRange()){return this.bytes.subarray(s,s+e)}readDictionary(t){return this.dictionaries.get(t.id)}}class MD extends Pw{constructor(t,e,s,l){super(new Uint8Array(0),e,s,l),this.sources=t}readNullBitmap(t,e,{offset:s}=this.nextBufferRange()){return e<=0?new Uint8Array(0):Kf(this.sources[s])}readOffsets(t,{offset:e}=this.nextBufferRange()){return ue(Uint8Array,ue(Int32Array,this.sources[e]))}readTypeIds(t,{offset:e}=this.nextBufferRange()){return ue(Uint8Array,ue(t.ArrayType,this.sources[e]))}readData(t,{offset:e}=this.nextBufferRange()){const{sources:s}=this;return wt.isTimestamp(t)||(wt.isInt(t)||wt.isTime(t))&&t.bitWidth===64||wt.isDate(t)&&t.unit===Or.MILLISECOND?ue(Uint8Array,pn.convertArray(s[e])):wt.isDecimal(t)?ue(Uint8Array,Mi.convertArray(s[e])):wt.isBinary(t)||wt.isFixedSizeBinary(t)?BD(s[e]):wt.isBool(t)?Kf(s[e]):wt.isUtf8(t)?jy(s[e].join("")):ue(Uint8Array,ue(t.ArrayType,s[e].map(l=>+l)))}}function BD(n){const t=n.join(""),e=new Uint8Array(t.length/2);for(let s=0;s<t.length;s+=2)e[s>>1]=Number.parseInt(t.slice(s,s+2),16);return e}class Ot extends jt{compareSchemas(t,e){return t===e||e instanceof t.constructor&&this.compareManyFields(t.fields,e.fields)}compareManyFields(t,e){return t===e||Array.isArray(t)&&Array.isArray(e)&&t.length===e.length&&t.every((s,l)=>this.compareFields(s,e[l]))}compareFields(t,e){return t===e||e instanceof t.constructor&&t.name===e.name&&t.nullable===e.nullable&&this.visit(t.type,e.type)}}function xn(n,t){return t instanceof n.constructor}function Iu(n,t){return n===t||xn(n,t)}function Mr(n,t){return n===t||xn(n,t)&&n.bitWidth===t.bitWidth&&n.isSigned===t.isSigned}function Rd(n,t){return n===t||xn(n,t)&&n.precision===t.precision}function RD(n,t){return n===t||xn(n,t)&&n.byteWidth===t.byteWidth}function rm(n,t){return n===t||xn(n,t)&&n.unit===t.unit}function ku(n,t){return n===t||xn(n,t)&&n.unit===t.unit&&n.timezone===t.timezone}function Uu(n,t){return n===t||xn(n,t)&&n.unit===t.unit&&n.bitWidth===t.bitWidth}function FD(n,t){return n===t||xn(n,t)&&n.children.length===t.children.length&&ys.compareManyFields(n.children,t.children)}function LD(n,t){return n===t||xn(n,t)&&n.children.length===t.children.length&&ys.compareManyFields(n.children,t.children)}function sm(n,t){return n===t||xn(n,t)&&n.mode===t.mode&&n.typeIds.every((e,s)=>e===t.typeIds[s])&&ys.compareManyFields(n.children,t.children)}function ID(n,t){return n===t||xn(n,t)&&n.id===t.id&&n.isOrdered===t.isOrdered&&ys.visit(n.indices,t.indices)&&ys.visit(n.dictionary,t.dictionary)}function am(n,t){return n===t||xn(n,t)&&n.unit===t.unit}function kD(n,t){return n===t||xn(n,t)&&n.listSize===t.listSize&&n.children.length===t.children.length&&ys.compareManyFields(n.children,t.children)}function UD(n,t){return n===t||xn(n,t)&&n.keysSorted===t.keysSorted&&n.children.length===t.children.length&&ys.compareManyFields(n.children,t.children)}Ot.prototype.visitNull=Iu;Ot.prototype.visitBool=Iu;Ot.prototype.visitInt=Mr;Ot.prototype.visitInt8=Mr;Ot.prototype.visitInt16=Mr;Ot.prototype.visitInt32=Mr;Ot.prototype.visitInt64=Mr;Ot.prototype.visitUint8=Mr;Ot.prototype.visitUint16=Mr;Ot.prototype.visitUint32=Mr;Ot.prototype.visitUint64=Mr;Ot.prototype.visitFloat=Rd;Ot.prototype.visitFloat16=Rd;Ot.prototype.visitFloat32=Rd;Ot.prototype.visitFloat64=Rd;Ot.prototype.visitUtf8=Iu;Ot.prototype.visitBinary=Iu;Ot.prototype.visitFixedSizeBinary=RD;Ot.prototype.visitDate=rm;Ot.prototype.visitDateDay=rm;Ot.prototype.visitDateMillisecond=rm;Ot.prototype.visitTimestamp=ku;Ot.prototype.visitTimestampSecond=ku;Ot.prototype.visitTimestampMillisecond=ku;Ot.prototype.visitTimestampMicrosecond=ku;Ot.prototype.visitTimestampNanosecond=ku;Ot.prototype.visitTime=Uu;Ot.prototype.visitTimeSecond=Uu;Ot.prototype.visitTimeMillisecond=Uu;Ot.prototype.visitTimeMicrosecond=Uu;Ot.prototype.visitTimeNanosecond=Uu;Ot.prototype.visitDecimal=Iu;Ot.prototype.visitList=FD;Ot.prototype.visitStruct=LD;Ot.prototype.visitUnion=sm;Ot.prototype.visitDenseUnion=sm;Ot.prototype.visitSparseUnion=sm;Ot.prototype.visitDictionary=ID;Ot.prototype.visitInterval=am;Ot.prototype.visitIntervalDayTime=am;Ot.prototype.visitIntervalYearMonth=am;Ot.prototype.visitFixedSizeList=kD;Ot.prototype.visitMap=UD;const ys=new Ot;function ey(n,t){return ys.compareSchemas(n,t)}function wp(n,t){return zD(n,t.map(e=>e.data.concat()))}function zD(n,t){const e=[...n.fields],s=[],l={numBatches:t.reduce((m,_)=>Math.max(m,_.length),0)};let o=0,c=0,f=-1;const h=t.length;let p,y=[];for(;l.numBatches-- >0;){for(c=Number.POSITIVE_INFINITY,f=-1;++f<h;)y[f]=p=t[f].shift(),c=Math.min(c,p?p.length:c);Number.isFinite(c)&&(y=$D(e,c,y,t,l),c>0&&(s[o++]=$t({type:new sn(e),length:c,nullCount:0,children:y.slice()})))}return[n=n.assign(e),s.map(m=>new _n(n,m))]}function $D(n,t,e,s,l){var o;const c=(t+63&-64)>>3;for(let f=-1,h=s.length;++f<h;){const p=e[f],y=p==null?void 0:p.length;if(y>=t)y===t?e[f]=p:(e[f]=p.slice(0,t),l.numBatches=Math.max(l.numBatches,s[f].unshift(p.slice(t,y-t))));else{const m=n[f];n[f]=m.clone({nullable:!0}),e[f]=(o=p==null?void 0:p._changeLengthAndBackfillNullBitmap(t))!==null&&o!==void 0?o:$t({type:m.type,length:t,nullCount:t,nullBitmap:new Uint8Array(c)})}}return e}var Gw;class rn{constructor(...t){var e,s;if(t.length===0)return this.batches=[],this.schema=new te([]),this._offsets=[0],this;let l,o;t[0]instanceof te&&(l=t.shift()),t[t.length-1]instanceof Uint32Array&&(o=t.pop());const c=h=>{if(h){if(h instanceof _n)return[h];if(h instanceof rn)return h.batches;if(h instanceof de){if(h.type instanceof sn)return[new _n(new te(h.type.children),h)]}else{if(Array.isArray(h))return h.flatMap(p=>c(p));if(typeof h[Symbol.iterator]=="function")return[...h].flatMap(p=>c(p));if(typeof h=="object"){const p=Object.keys(h),y=p.map(S=>new Wt([h[S]])),m=new te(p.map((S,v)=>new he(String(S),y[v].type))),[,_]=wp(m,y);return _.length===0?[new _n(h)]:_}}}return[]},f=t.flatMap(h=>c(h));if(l=(s=l??((e=f[0])===null||e===void 0?void 0:e.schema))!==null&&s!==void 0?s:new te([]),!(l instanceof te))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");for(const h of f){if(!(h instanceof _n))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");if(!ey(l,h.schema))throw new TypeError("Table and inner RecordBatch schemas must be equivalent.")}this.schema=l,this.batches=f,this._offsets=o??Rw(this.data)}get data(){return this.batches.map(({data:t})=>t)}get numCols(){return this.schema.fields.length}get numRows(){return this.data.reduce((t,e)=>t+e.length,0)}get nullCount(){return this._nullCount===-1&&(this._nullCount=Bw(this.data)),this._nullCount}isValid(t){return!1}get(t){return null}set(t,e){}indexOf(t,e){return-1}getByteLength(t){return 0}[Symbol.iterator](){return this.batches.length>0?em.visit(new Wt(this.data)):new Array(0)[Symbol.iterator]()}toArray(){return[...this]}toString(){return`[
  ${this.toArray().join(`,
  `)}
]`}concat(...t){const e=this.schema,s=this.data.concat(t.flatMap(({data:l})=>l));return new rn(e,s.map(l=>new _n(e,l)))}slice(t,e){const s=this.schema;[t,e]=Dw({length:this.numRows},t,e);const l=Fw(this.data,this._offsets,t,e);return new rn(s,l.map(o=>new _n(s,o)))}getChild(t){return this.getChildAt(this.schema.fields.findIndex(e=>e.name===t))}getChildAt(t){if(t>-1&&t<this.schema.fields.length){const e=this.data.map(s=>s.children[t]);if(e.length===0){const{type:s}=this.schema.fields[t],l=$t({type:s,length:0,nullCount:0});e.push(l._changeLengthAndBackfillNullBitmap(this.numRows))}return new Wt(e)}return null}setChild(t,e){var s;return this.setChildAt((s=this.schema.fields)===null||s===void 0?void 0:s.findIndex(l=>l.name===t),e)}setChildAt(t,e){let s=this.schema,l=[...this.batches];if(t>-1&&t<this.numCols){e||(e=new Wt([$t({type:new hs,length:this.numRows})]));const o=s.fields.slice(),c=o[t].clone({type:e.type}),f=this.schema.fields.map((h,p)=>this.getChildAt(p));[o[t],f[t]]=[c,e],[s,l]=wp(s,f)}return new rn(s,l)}select(t){const e=this.schema.fields.reduce((s,l,o)=>s.set(l.name,o),new Map);return this.selectAt(t.map(s=>e.get(s)).filter(s=>s>-1))}selectAt(t){const e=this.schema.selectAt(t),s=this.batches.map(l=>l.selectAt(t));return new rn(e,s)}assign(t){const e=this.schema.fields,[s,l]=t.schema.fields.reduce((f,h,p)=>{const[y,m]=f,_=e.findIndex(S=>S.name===h.name);return~_?m[_]=p:y.push(p),f},[[],[]]),o=this.schema.assign(t.schema),c=[...e.map((f,h)=>[h,l[h]]).map(([f,h])=>h===void 0?this.getChildAt(f):t.getChildAt(h)),...s.map(f=>t.getChildAt(f))].filter(Boolean);return new rn(...wp(o,c))}}Gw=Symbol.toStringTag;rn[Gw]=(n=>(n.schema=null,n.batches=[],n._offsets=new Uint32Array([0]),n._nullCount=-1,n[Symbol.isConcatSpreadable]=!0,n.isValid=xl(tm),n.get=xl(wn.getVisitFn(k.Struct)),n.set=Lw(ai.getVisitFn(k.Struct)),n.indexOf=Iw(Pf.getVisitFn(k.Struct)),n.getByteLength=xl(Ki.getVisitFn(k.Struct)),"Table"))(rn.prototype);var Zw;let _n=class su{constructor(...t){switch(t.length){case 2:{if([this.schema]=t,!(this.schema instanceof te))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");if([,this.data=$t({nullCount:0,type:new sn(this.schema.fields),children:this.schema.fields.map(e=>$t({type:e.type,nullCount:0}))})]=t,!(this.data instanceof de))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");[this.schema,this.data]=AS(this.schema,this.data.children);break}case 1:{const[e]=t,{fields:s,children:l,length:o}=Object.keys(e).reduce((h,p,y)=>(h.children[y]=e[p],h.length=Math.max(h.length,e[p].length),h.fields[y]=he.new({name:p,type:e[p].type,nullable:!0}),h),{length:0,fields:new Array,children:new Array}),c=new te(s),f=$t({type:new sn(s),length:o,children:l,nullCount:0});[this.schema,this.data]=AS(c,f.children,o);break}default:throw new TypeError("RecordBatch constructor expects an Object mapping names to child Data, or a [Schema, Data] pair.")}}get dictionaries(){return this._dictionaries||(this._dictionaries=Xw(this.schema.fields,this.data.children))}get numCols(){return this.schema.fields.length}get numRows(){return this.data.length}get nullCount(){return this.data.nullCount}isValid(t){return this.data.getValid(t)}get(t){return wn.visit(this.data,t)}set(t,e){return ai.visit(this.data,t,e)}indexOf(t,e){return Pf.visit(this.data,t,e)}getByteLength(t){return Ki.visit(this.data,t)}[Symbol.iterator](){return em.visit(new Wt([this.data]))}toArray(){return[...this]}concat(...t){return new rn(this.schema,[this,...t])}slice(t,e){const[s]=new Wt([this.data]).slice(t,e).data;return new su(this.schema,s)}getChild(t){var e;return this.getChildAt((e=this.schema.fields)===null||e===void 0?void 0:e.findIndex(s=>s.name===t))}getChildAt(t){return t>-1&&t<this.schema.fields.length?new Wt([this.data.children[t]]):null}setChild(t,e){var s;return this.setChildAt((s=this.schema.fields)===null||s===void 0?void 0:s.findIndex(l=>l.name===t),e)}setChildAt(t,e){let s=this.schema,l=this.data;if(t>-1&&t<this.numCols){e||(e=new Wt([$t({type:new hs,length:this.numRows})]));const o=s.fields.slice(),c=l.children.slice(),f=o[t].clone({type:e.type});[o[t],c[t]]=[f,e.data[0]],s=new te(o,new Map(this.schema.metadata)),l=$t({type:new sn(o),children:c})}return new su(s,l)}select(t){const e=this.schema.select(t),s=new sn(e.fields),l=[];for(const o of t){const c=this.schema.fields.findIndex(f=>f.name===o);~c&&(l[c]=this.data.children[c])}return new su(e,$t({type:s,length:this.numRows,children:l}))}selectAt(t){const e=this.schema.selectAt(t),s=t.map(o=>this.data.children[o]).filter(Boolean),l=$t({type:new sn(e.fields),length:this.numRows,children:s});return new su(e,l)}};Zw=Symbol.toStringTag;_n[Zw]=(n=>(n._nullCount=-1,n[Symbol.isConcatSpreadable]=!0,"RecordBatch"))(_n.prototype);function AS(n,t,e=t.reduce((s,l)=>Math.max(s,l.length),0)){var s;const l=[...n.fields],o=[...t],c=(e+63&-64)>>3;for(const[f,h]of n.fields.entries()){const p=t[f];(!p||p.length!==e)&&(l[f]=h.clone({nullable:!0}),o[f]=(s=p==null?void 0:p._changeLengthAndBackfillNullBitmap(e))!==null&&s!==void 0?s:$t({type:h.type,length:e,nullCount:e,nullBitmap:new Uint8Array(c)}))}return[n.assign(l),$t({type:new sn(l),length:e,children:o})]}function Xw(n,t,e=new Map){for(let s=-1,l=n.length;++s<l;){const c=n[s].type,f=t[s];if(wt.isDictionary(c)){if(!e.has(c.id))f.dictionary&&e.set(c.id,f.dictionary);else if(e.get(c.id)!==f.dictionary)throw new Error("Cannot create Schema containing two different dictionaries with the same Id")}c.children&&c.children.length>0&&Xw(c.children,f.children,e)}return e}class lm extends _n{constructor(t){const e=t.fields.map(l=>$t({type:l.type})),s=$t({type:new sn(t.fields),nullCount:0,children:e});super(t,s)}}var nd;(function(n){n[n.BUFFER=0]="BUFFER"})(nd||(nd={}));var id;(function(n){n[n.LZ4_FRAME=0]="LZ4_FRAME",n[n.ZSTD=1]="ZSTD"})(id||(id={}));class ss{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsBodyCompression(t,e){return(e||new ss).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBodyCompression(t,e){return t.setPosition(t.position()+ce),(e||new ss).__init(t.readInt32(t.position())+t.position(),t)}codec(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt8(this.bb_pos+t):id.LZ4_FRAME}method(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt8(this.bb_pos+t):nd.BUFFER}static startBodyCompression(t){t.startObject(2)}static addCodec(t,e){t.addFieldInt8(0,e,id.LZ4_FRAME)}static addMethod(t,e){t.addFieldInt8(1,e,nd.BUFFER)}static endBodyCompression(t){return t.endObject()}static createBodyCompression(t,e,s){return ss.startBodyCompression(t),ss.addCodec(t,e),ss.addMethod(t,s),ss.endBodyCompression(t)}}class Qw{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}offset(){return this.bb.readInt64(this.bb_pos)}length(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createBuffer(t,e,s){return t.prep(8,16),t.writeInt64(s),t.writeInt64(e),t.offset()}}let Jw=class{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}length(){return this.bb.readInt64(this.bb_pos)}nullCount(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createFieldNode(t,e,s){return t.prep(8,16),t.writeInt64(s),t.writeInt64(e),t.offset()}},mr=class ny{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsRecordBatch(t,e){return(e||new ny).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsRecordBatch(t,e){return t.setPosition(t.position()+ce),(e||new ny).__init(t.readInt32(t.position())+t.position(),t)}length(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}nodes(t,e){const s=this.bb.__offset(this.bb_pos,6);return s?(e||new Jw).__init(this.bb.__vector(this.bb_pos+s)+t*16,this.bb):null}nodesLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}buffers(t,e){const s=this.bb.__offset(this.bb_pos,8);return s?(e||new Qw).__init(this.bb.__vector(this.bb_pos+s)+t*16,this.bb):null}buffersLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}compression(t){const e=this.bb.__offset(this.bb_pos,10);return e?(t||new ss).__init(this.bb.__indirect(this.bb_pos+e),this.bb):null}static startRecordBatch(t){t.startObject(4)}static addLength(t,e){t.addFieldInt64(0,e,t.createLong(0,0))}static addNodes(t,e){t.addFieldOffset(1,e,0)}static startNodesVector(t,e){t.startVector(16,e,8)}static addBuffers(t,e){t.addFieldOffset(2,e,0)}static startBuffersVector(t,e){t.startVector(16,e,8)}static addCompression(t,e){t.addFieldOffset(3,e,0)}static endRecordBatch(t){return t.endObject()}},pl=class iy{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsDictionaryBatch(t,e){return(e||new iy).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDictionaryBatch(t,e){return t.setPosition(t.position()+ce),(e||new iy).__init(t.readInt32(t.position())+t.position(),t)}id(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}data(t){const e=this.bb.__offset(this.bb_pos,6);return e?(t||new mr).__init(this.bb.__indirect(this.bb_pos+e),this.bb):null}isDelta(){const t=this.bb.__offset(this.bb_pos,8);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startDictionaryBatch(t){t.startObject(3)}static addId(t,e){t.addFieldInt64(0,e,t.createLong(0,0))}static addData(t,e){t.addFieldOffset(1,e,0)}static addIsDelta(t,e){t.addFieldInt8(2,+e,0)}static endDictionaryBatch(t){return t.endObject()}};var rd;(function(n){n[n.NONE=0]="NONE",n[n.Schema=1]="Schema",n[n.DictionaryBatch=2]="DictionaryBatch",n[n.RecordBatch=3]="RecordBatch",n[n.Tensor=4]="Tensor",n[n.SparseTensor=5]="SparseTensor"})(rd||(rd={}));let is=class Ci{constructor(){this.bb=null,this.bb_pos=0}__init(t,e){return this.bb_pos=t,this.bb=e,this}static getRootAsMessage(t,e){return(e||new Ci).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsMessage(t,e){return t.setPosition(t.position()+ce),(e||new Ci).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Bl.V1}headerType(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readUint8(this.bb_pos+t):rd.NONE}header(t){const e=this.bb.__offset(this.bb_pos,8);return e?this.bb.__union(t,this.bb_pos+e):null}bodyLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}customMetadata(t,e){const s=this.bb.__offset(this.bb_pos,12);return s?(e||new Le).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+s)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startMessage(t){t.startObject(5)}static addVersion(t,e){t.addFieldInt16(0,e,Bl.V1)}static addHeaderType(t,e){t.addFieldInt8(1,e,rd.NONE)}static addHeader(t,e){t.addFieldOffset(2,e,0)}static addBodyLength(t,e){t.addFieldInt64(3,e,t.createLong(0,0))}static addCustomMetadata(t,e){t.addFieldOffset(4,e,0)}static createCustomMetadataVector(t,e){t.startVector(4,e.length,4);for(let s=e.length-1;s>=0;s--)t.addOffset(e[s]);return t.endVector()}static startCustomMetadataVector(t,e){t.startVector(4,e,4)}static endMessage(t){return t.endObject()}static finishMessageBuffer(t,e){t.finish(e)}static finishSizePrefixedMessageBuffer(t,e){t.finish(e,void 0,!0)}static createMessage(t,e,s,l,o,c){return Ci.startMessage(t),Ci.addVersion(t,e),Ci.addHeaderType(t,s),Ci.addHeader(t,l),Ci.addBodyLength(t,o),Ci.addCustomMetadata(t,c),Ci.endMessage(t)}};var jD=Ar;class VD extends jt{visit(t,e){return t==null||e==null?void 0:super.visit(t,e)}visitNull(t,e){return ta.startNull(e),ta.endNull(e)}visitInt(t,e){return Ln.startInt(e),Ln.addBitWidth(e,t.bitWidth),Ln.addIsSigned(e,t.isSigned),Ln.endInt(e)}visitFloat(t,e){return zi.startFloatingPoint(e),zi.addPrecision(e,t.precision),zi.endFloatingPoint(e)}visitBinary(t,e){return Qs.startBinary(e),Qs.endBinary(e)}visitBool(t,e){return Js.startBool(e),Js.endBool(e)}visitUtf8(t,e){return na.startUtf8(e),na.endUtf8(e)}visitDecimal(t,e){return yn.startDecimal(e),yn.addScale(e,t.scale),yn.addPrecision(e,t.precision),yn.addBitWidth(e,t.bitWidth),yn.endDecimal(e)}visitDate(t,e){return wf.startDate(e),wf.addUnit(e,t.unit),wf.endDate(e)}visitTime(t,e){return ni.startTime(e),ni.addUnit(e,t.unit),ni.addBitWidth(e,t.bitWidth),ni.endTime(e)}visitTimestamp(t,e){const s=t.timezone&&e.createString(t.timezone)||void 0;return ii.startTimestamp(e),ii.addUnit(e,t.unit),s!==void 0&&ii.addTimezone(e,s),ii.endTimestamp(e)}visitInterval(t,e){return $i.startInterval(e),$i.addUnit(e,t.unit),$i.endInterval(e)}visitList(t,e){return Ws.startList(e),Ws.endList(e)}visitStruct(t,e){return ea.startStruct_(e),ea.endStruct_(e)}visitUnion(t,e){mn.startTypeIdsVector(e,t.typeIds.length);const s=mn.createTypeIdsVector(e,t.typeIds);return mn.startUnion(e),mn.addMode(e,t.mode),mn.addTypeIds(e,s),mn.endUnion(e)}visitDictionary(t,e){const s=this.visit(t.indices,e);return Tr.startDictionaryEncoding(e),Tr.addId(e,new jD(t.id,0)),Tr.addIsOrdered(e,t.isOrdered),s!==void 0&&Tr.addIndexType(e,s),Tr.endDictionaryEncoding(e)}visitFixedSizeBinary(t,e){return ki.startFixedSizeBinary(e),ki.addByteWidth(e,t.byteWidth),ki.endFixedSizeBinary(e)}visitFixedSizeList(t,e){return Ui.startFixedSizeList(e),Ui.addListSize(e,t.listSize),Ui.endFixedSizeList(e)}visitMap(t,e){return xf.startMap(e),xf.addKeysSorted(e,t.keysSorted),xf.endMap(e)}}const xp=new VD;function HD(n,t=new Map){return new te(qD(n,t),Of(n.customMetadata),t)}function Ww(n){return new zn(n.count,tx(n.columns),ex(n.columns))}function YD(n){return new Pi(Ww(n.data),n.id,n.isDelta)}function qD(n,t){return(n.fields||[]).filter(Boolean).map(e=>he.fromJSON(e,t))}function ES(n,t){return(n.children||[]).filter(Boolean).map(e=>he.fromJSON(e,t))}function tx(n){return(n||[]).reduce((t,e)=>[...t,new va(e.count,KD(e.VALIDITY)),...tx(e.children)],[])}function ex(n,t=[]){for(let e=-1,s=(n||[]).length;++e<s;){const l=n[e];l.VALIDITY&&t.push(new Hi(t.length,l.VALIDITY.length)),l.TYPE&&t.push(new Hi(t.length,l.TYPE.length)),l.OFFSET&&t.push(new Hi(t.length,l.OFFSET.length)),l.DATA&&t.push(new Hi(t.length,l.DATA.length)),t=ex(l.children,t)}return t}function KD(n){return(n||[]).reduce((t,e)=>t+ +(e===0),0)}function PD(n,t){let e,s,l,o,c,f;return!t||!(o=n.dictionary)?(c=NS(n,ES(n,t)),l=new he(n.name,c,n.nullable,Of(n.customMetadata))):t.has(e=o.id)?(s=(s=o.indexType)?OS(s):new vu,f=new Dl(t.get(e),s,e,o.isOrdered),l=new he(n.name,f,n.nullable,Of(n.customMetadata))):(s=(s=o.indexType)?OS(s):new vu,t.set(e,c=NS(n,ES(n,t))),f=new Dl(c,s,e,o.isOrdered),l=new he(n.name,f,n.nullable,Of(n.customMetadata))),l||null}function Of(n){return new Map(Object.entries(n||{}))}function OS(n){return new gs(n.isSigned,n.bitWidth)}function NS(n,t){const e=n.type.name;switch(e){case"NONE":return new hs;case"null":return new hs;case"binary":return new Ff;case"utf8":return new Lf;case"bool":return new If;case"list":return new jf((t||[])[0]);case"struct":return new sn(t||[]);case"struct_":return new sn(t||[])}switch(e){case"int":{const s=n.type;return new gs(s.isSigned,s.bitWidth)}case"floatingpoint":{const s=n.type;return new Su(bn[s.precision])}case"decimal":{const s=n.type;return new kf(s.scale,s.precision,s.bitWidth)}case"date":{const s=n.type;return new Uf(Or[s.unit])}case"time":{const s=n.type;return new Tu(Xt[s.unit],s.bitWidth)}case"timestamp":{const s=n.type;return new zf(Xt[s.unit],s.timezone)}case"interval":{const s=n.type;return new $f(ds[s.unit])}case"union":{const s=n.type;return new Vf(Un[s.mode],s.typeIds||[],t||[])}case"fixedsizebinary":{const s=n.type;return new Hf(s.byteWidth)}case"fixedsizelist":{const s=n.type;return new Yf(s.listSize,(t||[])[0])}case"map":{const s=n.type;return new qf((t||[])[0],s.keysSorted)}}throw new Error(`Unrecognized type: "${e}"`)}var ca=Ar,GD=Yw,ZD=Ml;class an{constructor(t,e,s,l){this._version=e,this._headerType=s,this.body=new Uint8Array(0),l&&(this._createHeader=()=>l),this._bodyLength=typeof t=="number"?t:t.low}static fromJSON(t,e){const s=new an(0,kn.V4,e);return s._createHeader=XD(t,e),s}static decode(t){t=new ZD(Zt(t));const e=is.getRootAsMessage(t),s=e.bodyLength(),l=e.version(),o=e.headerType(),c=new an(s,l,o);return c._createHeader=QD(e,o),c}static encode(t){const e=new GD;let s=-1;return t.isSchema()?s=te.encode(e,t.header()):t.isRecordBatch()?s=zn.encode(e,t.header()):t.isDictionaryBatch()&&(s=Pi.encode(e,t.header())),is.startMessage(e),is.addVersion(e,kn.V4),is.addHeader(e,s),is.addHeaderType(e,t.headerType),is.addBodyLength(e,new ca(t.bodyLength,0)),is.finishMessageBuffer(e,is.endMessage(e)),e.asUint8Array()}static from(t,e=0){if(t instanceof te)return new an(0,kn.V4,Jt.Schema,t);if(t instanceof zn)return new an(e,kn.V4,Jt.RecordBatch,t);if(t instanceof Pi)return new an(e,kn.V4,Jt.DictionaryBatch,t);throw new Error(`Unrecognized Message header: ${t}`)}get type(){return this.headerType}get version(){return this._version}get headerType(){return this._headerType}get bodyLength(){return this._bodyLength}header(){return this._createHeader()}isSchema(){return this.headerType===Jt.Schema}isRecordBatch(){return this.headerType===Jt.RecordBatch}isDictionaryBatch(){return this.headerType===Jt.DictionaryBatch}}class zn{constructor(t,e,s){this._nodes=e,this._buffers=s,this._length=typeof t=="number"?t:t.low}get nodes(){return this._nodes}get length(){return this._length}get buffers(){return this._buffers}}class Pi{constructor(t,e,s=!1){this._data=t,this._isDelta=s,this._id=typeof e=="number"?e:e.low}get id(){return this._id}get data(){return this._data}get isDelta(){return this._isDelta}get length(){return this.data.length}get nodes(){return this.data.nodes}get buffers(){return this.data.buffers}}class Hi{constructor(t,e){this.offset=typeof t=="number"?t:t.low,this.length=typeof e=="number"?e:e.low}}class va{constructor(t,e){this.length=typeof t=="number"?t:t.low,this.nullCount=typeof e=="number"?e:e.low}}function XD(n,t){return()=>{switch(t){case Jt.Schema:return te.fromJSON(n);case Jt.RecordBatch:return zn.fromJSON(n);case Jt.DictionaryBatch:return Pi.fromJSON(n)}throw new Error(`Unrecognized Message type: { name: ${Jt[t]}, type: ${t} }`)}}function QD(n,t){return()=>{switch(t){case Jt.Schema:return te.decode(n.header(new Di));case Jt.RecordBatch:return zn.decode(n.header(new mr),n.version());case Jt.DictionaryBatch:return Pi.decode(n.header(new pl),n.version())}throw new Error(`Unrecognized Message type: { name: ${Jt[t]}, type: ${t} }`)}}he.encode=o2;he.decode=a2;he.fromJSON=PD;te.encode=l2;te.decode=JD;te.fromJSON=HD;zn.encode=u2;zn.decode=WD;zn.fromJSON=Ww;Pi.encode=c2;Pi.decode=t2;Pi.fromJSON=YD;va.encode=f2;va.decode=n2;Hi.encode=d2;Hi.decode=e2;function JD(n,t=new Map){const e=s2(n,t);return new te(e,Nf(n),t)}function WD(n,t=kn.V4){if(n.compression()!==null)throw new Error("Record batch compression not implemented");return new zn(n.length(),i2(n),r2(n,t))}function t2(n,t=kn.V4){return new Pi(zn.decode(n.data(),t),n.id(),n.isDelta())}function e2(n){return new Hi(n.offset(),n.length())}function n2(n){return new va(n.length(),n.nullCount())}function i2(n){const t=[];for(let e,s=-1,l=-1,o=n.nodesLength();++s<o;)(e=n.nodes(s))&&(t[++l]=va.decode(e));return t}function r2(n,t){const e=[];for(let s,l=-1,o=-1,c=n.buffersLength();++l<c;)(s=n.buffers(l))&&(t<kn.V4&&(s.bb_pos+=8*(l+1)),e[++o]=Hi.decode(s));return e}function s2(n,t){const e=[];for(let s,l=-1,o=-1,c=n.fieldsLength();++l<c;)(s=n.fields(l))&&(e[++o]=he.decode(s,t));return e}function CS(n,t){const e=[];for(let s,l=-1,o=-1,c=n.childrenLength();++l<c;)(s=n.children(l))&&(e[++o]=he.decode(s,t));return e}function a2(n,t){let e,s,l,o,c,f;return!t||!(f=n.dictionary())?(l=MS(n,CS(n,t)),s=new he(n.name(),l,n.nullable(),Nf(n))):t.has(e=f.id().low)?(o=(o=f.indexType())?DS(o):new vu,c=new Dl(t.get(e),o,e,f.isOrdered()),s=new he(n.name(),c,n.nullable(),Nf(n))):(o=(o=f.indexType())?DS(o):new vu,t.set(e,l=MS(n,CS(n,t))),c=new Dl(l,o,e,f.isOrdered()),s=new he(n.name(),c,n.nullable(),Nf(n))),s||null}function Nf(n){const t=new Map;if(n)for(let e,s,l=-1,o=Math.trunc(n.customMetadataLength());++l<o;)(e=n.customMetadata(l))&&(s=e.key())!=null&&t.set(s,e.value());return t}function DS(n){return new gs(n.isSigned(),n.bitWidth())}function MS(n,t){const e=n.typeType();switch(e){case me.NONE:return new hs;case me.Null:return new hs;case me.Binary:return new Ff;case me.Utf8:return new Lf;case me.Bool:return new If;case me.List:return new jf((t||[])[0]);case me.Struct_:return new sn(t||[])}switch(e){case me.Int:{const s=n.type(new Ln);return new gs(s.isSigned(),s.bitWidth())}case me.FloatingPoint:{const s=n.type(new zi);return new Su(s.precision())}case me.Decimal:{const s=n.type(new yn);return new kf(s.scale(),s.precision(),s.bitWidth())}case me.Date:{const s=n.type(new wf);return new Uf(s.unit())}case me.Time:{const s=n.type(new ni);return new Tu(s.unit(),s.bitWidth())}case me.Timestamp:{const s=n.type(new ii);return new zf(s.unit(),s.timezone())}case me.Interval:{const s=n.type(new $i);return new $f(s.unit())}case me.Union:{const s=n.type(new mn);return new Vf(s.mode(),s.typeIdsArray()||[],t||[])}case me.FixedSizeBinary:{const s=n.type(new ki);return new Hf(s.byteWidth())}case me.FixedSizeList:{const s=n.type(new Ui);return new Yf(s.listSize(),(t||[])[0])}case me.Map:{const s=n.type(new xf);return new qf((t||[])[0],s.keysSorted())}}throw new Error(`Unrecognized type: "${me[e]}" (${e})`)}function l2(n,t){const e=t.fields.map(o=>he.encode(n,o));Di.startFieldsVector(n,e.length);const s=Di.createFieldsVector(n,e),l=t.metadata&&t.metadata.size>0?Di.createCustomMetadataVector(n,[...t.metadata].map(([o,c])=>{const f=n.createString(`${o}`),h=n.createString(`${c}`);return Le.startKeyValue(n),Le.addKey(n,f),Le.addValue(n,h),Le.endKeyValue(n)})):-1;return Di.startSchema(n),Di.addFields(n,s),Di.addEndianness(n,h2?Rl.Little:Rl.Big),l!==-1&&Di.addCustomMetadata(n,l),Di.endSchema(n)}function o2(n,t){let e=-1,s=-1,l=-1;const o=t.type;let c=t.typeId;wt.isDictionary(o)?(c=o.dictionary.typeId,l=xp.visit(o,n),s=xp.visit(o.dictionary,n)):s=xp.visit(o,n);const f=(o.children||[]).map(y=>he.encode(n,y)),h=ti.createChildrenVector(n,f),p=t.metadata&&t.metadata.size>0?ti.createCustomMetadataVector(n,[...t.metadata].map(([y,m])=>{const _=n.createString(`${y}`),S=n.createString(`${m}`);return Le.startKeyValue(n),Le.addKey(n,_),Le.addValue(n,S),Le.endKeyValue(n)})):-1;return t.name&&(e=n.createString(t.name)),ti.startField(n),ti.addType(n,s),ti.addTypeType(n,c),ti.addChildren(n,h),ti.addNullable(n,!!t.nullable),e!==-1&&ti.addName(n,e),l!==-1&&ti.addDictionary(n,l),p!==-1&&ti.addCustomMetadata(n,p),ti.endField(n)}function u2(n,t){const e=t.nodes||[],s=t.buffers||[];mr.startNodesVector(n,e.length);for(const c of e.slice().reverse())va.encode(n,c);const l=n.endVector();mr.startBuffersVector(n,s.length);for(const c of s.slice().reverse())Hi.encode(n,c);const o=n.endVector();return mr.startRecordBatch(n),mr.addLength(n,new ca(t.length,0)),mr.addNodes(n,l),mr.addBuffers(n,o),mr.endRecordBatch(n)}function c2(n,t){const e=zn.encode(n,t.data);return pl.startDictionaryBatch(n),pl.addId(n,new ca(t.id,0)),pl.addIsDelta(n,t.isDelta),pl.addData(n,e),pl.endDictionaryBatch(n)}function f2(n,t){return Jw.createFieldNode(n,new ca(t.length,0),new ca(t.nullCount,0))}function d2(n,t){return Qw.createBuffer(n,new ca(t.offset,0),new ca(t.length,0))}const h2=(()=>{const n=new ArrayBuffer(2);return new DataView(n).setInt16(0,256,!0),new Int16Array(n)[0]===256})(),om=n=>`Expected ${Jt[n]} Message in stream, but was null or length 0.`,um=n=>`Header pointer of flatbuffer-encoded ${Jt[n]} Message is null or length 0.`,nx=(n,t)=>`Expected to read ${n} metadata bytes, but only read ${t}.`,ix=(n,t)=>`Expected to read ${n} bytes for message body, but only read ${t}.`;class rx{constructor(t){this.source=t instanceof td?t:new td(t)}[Symbol.iterator](){return this}next(){let t;return(t=this.readMetadataLength()).done||t.value===-1&&(t=this.readMetadataLength()).done||(t=this.readMetadata(t.value)).done?_e:t}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}readMessage(t){let e;if((e=this.next()).done)return null;if(t!=null&&e.value.headerType!==t)throw new Error(om(t));return e.value}readMessageBody(t){if(t<=0)return new Uint8Array(0);const e=Zt(this.source.read(t));if(e.byteLength<t)throw new Error(ix(t,e.byteLength));return e.byteOffset%8===0&&e.byteOffset+e.byteLength<=e.buffer.byteLength?e:e.slice()}readSchema(t=!1){const e=Jt.Schema,s=this.readMessage(e),l=s==null?void 0:s.header();if(t&&!l)throw new Error(um(e));return l}readMetadataLength(){const t=this.source.read(Fd),e=t&&new Ml(t),s=(e==null?void 0:e.readInt32(0))||0;return{done:s===0,value:s}}readMetadata(t){const e=this.source.read(t);if(!e)return _e;if(e.byteLength<t)throw new Error(nx(t,e.byteLength));return{done:!1,value:an.decode(e)}}}class g2{constructor(t,e){this.source=t instanceof Ll?t:AT(t)?new ed(t,e):new Ll(t)}[Symbol.asyncIterator](){return this}next(){return St(this,void 0,void 0,function*(){let t;return(t=yield this.readMetadataLength()).done||t.value===-1&&(t=yield this.readMetadataLength()).done||(t=yield this.readMetadata(t.value)).done?_e:t})}throw(t){return St(this,void 0,void 0,function*(){return yield this.source.throw(t)})}return(t){return St(this,void 0,void 0,function*(){return yield this.source.return(t)})}readMessage(t){return St(this,void 0,void 0,function*(){let e;if((e=yield this.next()).done)return null;if(t!=null&&e.value.headerType!==t)throw new Error(om(t));return e.value})}readMessageBody(t){return St(this,void 0,void 0,function*(){if(t<=0)return new Uint8Array(0);const e=Zt(yield this.source.read(t));if(e.byteLength<t)throw new Error(ix(t,e.byteLength));return e.byteOffset%8===0&&e.byteOffset+e.byteLength<=e.buffer.byteLength?e:e.slice()})}readSchema(t=!1){return St(this,void 0,void 0,function*(){const e=Jt.Schema,s=yield this.readMessage(e),l=s==null?void 0:s.header();if(t&&!l)throw new Error(um(e));return l})}readMetadataLength(){return St(this,void 0,void 0,function*(){const t=yield this.source.read(Fd),e=t&&new Ml(t),s=(e==null?void 0:e.readInt32(0))||0;return{done:s===0,value:s}})}readMetadata(t){return St(this,void 0,void 0,function*(){const e=yield this.source.read(t);if(!e)return _e;if(e.byteLength<t)throw new Error(nx(t,e.byteLength));return{done:!1,value:an.decode(e)}})}}class p2 extends rx{constructor(t){super(new Uint8Array(0)),this._schema=!1,this._body=[],this._batchIndex=0,this._dictionaryIndex=0,this._json=t instanceof wS?t:new wS(t)}next(){const{_json:t}=this;if(!this._schema)return this._schema=!0,{done:!1,value:an.fromJSON(t.schema,Jt.Schema)};if(this._dictionaryIndex<t.dictionaries.length){const e=t.dictionaries[this._dictionaryIndex++];return this._body=e.data.columns,{done:!1,value:an.fromJSON(e,Jt.DictionaryBatch)}}if(this._batchIndex<t.batches.length){const e=t.batches[this._batchIndex++];return this._body=e.columns,{done:!1,value:an.fromJSON(e,Jt.RecordBatch)}}return this._body=[],_e}readMessageBody(t){return e(this._body);function e(s){return(s||[]).reduce((l,o)=>[...l,...o.VALIDITY&&[o.VALIDITY]||[],...o.TYPE&&[o.TYPE]||[],...o.OFFSET&&[o.OFFSET]||[],...o.DATA&&[o.DATA]||[],...e(o.children)],[])}}readMessage(t){let e;if((e=this.next()).done)return null;if(t!=null&&e.value.headerType!==t)throw new Error(om(t));return e.value}readSchema(){const t=Jt.Schema,e=this.readMessage(t),s=e==null?void 0:e.header();if(!e||!s)throw new Error(um(t));return s}}const Fd=4,ry="ARROW1",xu=new Uint8Array(ry.length);for(let n=0;n<ry.length;n+=1)xu[n]=ry.codePointAt(n);function cm(n,t=0){for(let e=-1,s=xu.length;++e<s;)if(xu[e]!==n[t+e])return!1;return!0}const zu=xu.length,sx=zu+Fd,y2=zu*2+Fd;class Er extends nm{constructor(t){super(),this._impl=t}get closed(){return this._impl.closed}get schema(){return this._impl.schema}get autoDestroy(){return this._impl.autoDestroy}get dictionaries(){return this._impl.dictionaries}get numDictionaries(){return this._impl.numDictionaries}get numRecordBatches(){return this._impl.numRecordBatches}get footer(){return this._impl.isFile()?this._impl.footer:null}isSync(){return this._impl.isSync()}isAsync(){return this._impl.isAsync()}isFile(){return this._impl.isFile()}isStream(){return this._impl.isStream()}next(){return this._impl.next()}throw(t){return this._impl.throw(t)}return(t){return this._impl.return(t)}cancel(){return this._impl.cancel()}reset(t){return this._impl.reset(t),this._DOMStream=void 0,this._nodeStream=void 0,this}open(t){const e=this._impl.open(t);return fs(e)?e.then(()=>this):this}readRecordBatch(t){return this._impl.isFile()?this._impl.readRecordBatch(t):null}[Symbol.iterator](){return this._impl[Symbol.iterator]()}[Symbol.asyncIterator](){return this._impl[Symbol.asyncIterator]()}toDOMStream(){return ei.toDOMStream(this.isSync()?{[Symbol.iterator]:()=>this}:{[Symbol.asyncIterator]:()=>this})}toNodeStream(){return ei.toNodeStream(this.isSync()?{[Symbol.iterator]:()=>this}:{[Symbol.asyncIterator]:()=>this},{objectMode:!0})}static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t,e){throw new Error('"throughDOM" not available in this environment')}static from(t){return t instanceof Er?t:Pp(t)?v2(t):AT(t)?w2(t):fs(t)?St(this,void 0,void 0,function*(){return yield Er.from(yield t)}):ET(t)||Vy(t)||OT(t)||Yl(t)?T2(new Ll(t)):S2(new td(t))}static readAll(t){return t instanceof Er?t.isSync()?BS(t):RS(t):Pp(t)||ArrayBuffer.isView(t)||Lu(t)||xT(t)?BS(t):RS(t)}}class sd extends Er{constructor(t){super(t),this._impl=t}readAll(){return[...this]}[Symbol.iterator](){return this._impl[Symbol.iterator]()}[Symbol.asyncIterator](){return Vi(this,arguments,function*(){yield Ft(yield*Tf(sa(this[Symbol.iterator]())))})}}class ad extends Er{constructor(t){super(t),this._impl=t}readAll(){var t,e;return St(this,void 0,void 0,function*(){const s=new Array;try{for(var l=sa(this),o;o=yield l.next(),!o.done;){const c=o.value;s.push(c)}}catch(c){t={error:c}}finally{try{o&&!o.done&&(e=l.return)&&(yield e.call(l))}finally{if(t)throw t.error}}return s})}[Symbol.iterator](){throw new Error("AsyncRecordBatchStreamReader is not Iterable")}[Symbol.asyncIterator](){return this._impl[Symbol.asyncIterator]()}}class ax extends sd{constructor(t){super(t),this._impl=t}}class m2 extends ad{constructor(t){super(t),this._impl=t}}class lx{constructor(t=new Map){this.closed=!1,this.autoDestroy=!0,this._dictionaryIndex=0,this._recordBatchIndex=0,this.dictionaries=t}get numDictionaries(){return this._dictionaryIndex}get numRecordBatches(){return this._recordBatchIndex}isSync(){return!1}isAsync(){return!1}isFile(){return!1}isStream(){return!1}reset(t){return this._dictionaryIndex=0,this._recordBatchIndex=0,this.schema=t,this.dictionaries=new Map,this}_loadRecordBatch(t,e){const s=this._loadVectors(t,e,this.schema.fields),l=$t({type:new sn(this.schema.fields),length:t.length,children:s});return new _n(this.schema,l)}_loadDictionaryBatch(t,e){const{id:s,isDelta:l}=t,{dictionaries:o,schema:c}=this,f=o.get(s);if(l||!f){const h=c.dictionaries.get(s),p=this._loadVectors(t.data,e,[h]);return(f&&l?f.concat(new Wt(p)):new Wt(p)).memoize()}return f.memoize()}_loadVectors(t,e,s){return new Pw(e,t.nodes,t.buffers,this.dictionaries).visitMany(s)}}class ld extends lx{constructor(t,e){super(e),this._reader=Pp(t)?new p2(this._handle=t):new rx(this._handle=t)}isSync(){return!0}isStream(){return!0}[Symbol.iterator](){return this}cancel(){!this.closed&&(this.closed=!0)&&(this.reset()._reader.return(),this._reader=null,this.dictionaries=null)}open(t){return this.closed||(this.autoDestroy=ux(this,t),this.schema||(this.schema=this._reader.readSchema())||this.cancel()),this}throw(t){return!this.closed&&this.autoDestroy&&(this.closed=!0)?this.reset()._reader.throw(t):_e}return(t){return!this.closed&&this.autoDestroy&&(this.closed=!0)?this.reset()._reader.return(t):_e}next(){if(this.closed)return _e;let t;const{_reader:e}=this;for(;t=this._readNextMessageAndValidate();)if(t.isSchema())this.reset(t.header());else if(t.isRecordBatch()){this._recordBatchIndex++;const s=t.header(),l=e.readMessageBody(t.bodyLength);return{done:!1,value:this._loadRecordBatch(s,l)}}else if(t.isDictionaryBatch()){this._dictionaryIndex++;const s=t.header(),l=e.readMessageBody(t.bodyLength),o=this._loadDictionaryBatch(s,l);this.dictionaries.set(s.id,o)}return this.schema&&this._recordBatchIndex===0?(this._recordBatchIndex++,{done:!1,value:new lm(this.schema)}):this.return()}_readNextMessageAndValidate(t){return this._reader.readMessage(t)}}class od extends lx{constructor(t,e){super(e),this._reader=new g2(this._handle=t)}isAsync(){return!0}isStream(){return!0}[Symbol.asyncIterator](){return this}cancel(){return St(this,void 0,void 0,function*(){!this.closed&&(this.closed=!0)&&(yield this.reset()._reader.return(),this._reader=null,this.dictionaries=null)})}open(t){return St(this,void 0,void 0,function*(){return this.closed||(this.autoDestroy=ux(this,t),this.schema||(this.schema=yield this._reader.readSchema())||(yield this.cancel())),this})}throw(t){return St(this,void 0,void 0,function*(){return!this.closed&&this.autoDestroy&&(this.closed=!0)?yield this.reset()._reader.throw(t):_e})}return(t){return St(this,void 0,void 0,function*(){return!this.closed&&this.autoDestroy&&(this.closed=!0)?yield this.reset()._reader.return(t):_e})}next(){return St(this,void 0,void 0,function*(){if(this.closed)return _e;let t;const{_reader:e}=this;for(;t=yield this._readNextMessageAndValidate();)if(t.isSchema())yield this.reset(t.header());else if(t.isRecordBatch()){this._recordBatchIndex++;const s=t.header(),l=yield e.readMessageBody(t.bodyLength);return{done:!1,value:this._loadRecordBatch(s,l)}}else if(t.isDictionaryBatch()){this._dictionaryIndex++;const s=t.header(),l=yield e.readMessageBody(t.bodyLength),o=this._loadDictionaryBatch(s,l);this.dictionaries.set(s.id,o)}return this.schema&&this._recordBatchIndex===0?(this._recordBatchIndex++,{done:!1,value:new lm(this.schema)}):yield this.return()})}_readNextMessageAndValidate(t){return St(this,void 0,void 0,function*(){return yield this._reader.readMessage(t)})}}class ox extends ld{constructor(t,e){super(t instanceof xS?t:new xS(t),e)}get footer(){return this._footer}get numDictionaries(){return this._footer?this._footer.numDictionaries:0}get numRecordBatches(){return this._footer?this._footer.numRecordBatches:0}isSync(){return!0}isFile(){return!0}open(t){if(!this.closed&&!this._footer){this.schema=(this._footer=this._readFooter()).schema;for(const e of this._footer.dictionaryBatches())e&&this._readDictionaryBatch(this._dictionaryIndex++)}return super.open(t)}readRecordBatch(t){var e;if(this.closed)return null;this._footer||this.open();const s=(e=this._footer)===null||e===void 0?void 0:e.getRecordBatch(t);if(s&&this._handle.seek(s.offset)){const l=this._reader.readMessage(Jt.RecordBatch);if(l!=null&&l.isRecordBatch()){const o=l.header(),c=this._reader.readMessageBody(l.bodyLength);return this._loadRecordBatch(o,c)}}return null}_readDictionaryBatch(t){var e;const s=(e=this._footer)===null||e===void 0?void 0:e.getDictionaryBatch(t);if(s&&this._handle.seek(s.offset)){const l=this._reader.readMessage(Jt.DictionaryBatch);if(l!=null&&l.isDictionaryBatch()){const o=l.header(),c=this._reader.readMessageBody(l.bodyLength),f=this._loadDictionaryBatch(o,c);this.dictionaries.set(o.id,f)}}}_readFooter(){const{_handle:t}=this,e=t.size-sx,s=t.readInt32(e),l=t.readAt(e-s,s);return wu.decode(l)}_readNextMessageAndValidate(t){var e;if(this._footer||this.open(),this._footer&&this._recordBatchIndex<this.numRecordBatches){const s=(e=this._footer)===null||e===void 0?void 0:e.getRecordBatch(this._recordBatchIndex);if(s&&this._handle.seek(s.offset))return this._reader.readMessage(t)}return null}}class _2 extends od{constructor(t,...e){const s=typeof e[0]!="number"?e.shift():void 0,l=e[0]instanceof Map?e.shift():void 0;super(t instanceof ed?t:new ed(t,s),l)}get footer(){return this._footer}get numDictionaries(){return this._footer?this._footer.numDictionaries:0}get numRecordBatches(){return this._footer?this._footer.numRecordBatches:0}isFile(){return!0}isAsync(){return!0}open(t){const e=Object.create(null,{open:{get:()=>super.open}});return St(this,void 0,void 0,function*(){if(!this.closed&&!this._footer){this.schema=(this._footer=yield this._readFooter()).schema;for(const s of this._footer.dictionaryBatches())s&&(yield this._readDictionaryBatch(this._dictionaryIndex++))}return yield e.open.call(this,t)})}readRecordBatch(t){var e;return St(this,void 0,void 0,function*(){if(this.closed)return null;this._footer||(yield this.open());const s=(e=this._footer)===null||e===void 0?void 0:e.getRecordBatch(t);if(s&&(yield this._handle.seek(s.offset))){const l=yield this._reader.readMessage(Jt.RecordBatch);if(l!=null&&l.isRecordBatch()){const o=l.header(),c=yield this._reader.readMessageBody(l.bodyLength);return this._loadRecordBatch(o,c)}}return null})}_readDictionaryBatch(t){var e;return St(this,void 0,void 0,function*(){const s=(e=this._footer)===null||e===void 0?void 0:e.getDictionaryBatch(t);if(s&&(yield this._handle.seek(s.offset))){const l=yield this._reader.readMessage(Jt.DictionaryBatch);if(l!=null&&l.isDictionaryBatch()){const o=l.header(),c=yield this._reader.readMessageBody(l.bodyLength),f=this._loadDictionaryBatch(o,c);this.dictionaries.set(o.id,f)}}})}_readFooter(){return St(this,void 0,void 0,function*(){const{_handle:t}=this;t._pending&&(yield t._pending);const e=t.size-sx,s=yield t.readInt32(e),l=yield t.readAt(e-s,s);return wu.decode(l)})}_readNextMessageAndValidate(t){return St(this,void 0,void 0,function*(){if(this._footer||(yield this.open()),this._footer&&this._recordBatchIndex<this.numRecordBatches){const e=this._footer.getRecordBatch(this._recordBatchIndex);if(e&&(yield this._handle.seek(e.offset)))return yield this._reader.readMessage(t)}return null})}}class b2 extends ld{constructor(t,e){super(t,e)}_loadVectors(t,e,s){return new MD(e,t.nodes,t.buffers,this.dictionaries).visitMany(s)}}function ux(n,t){return t&&typeof t.autoDestroy=="boolean"?t.autoDestroy:n.autoDestroy}function*BS(n){const t=Er.from(n);try{if(!t.open({autoDestroy:!1}).closed)do yield t;while(!t.reset().open().closed)}finally{t.cancel()}}function RS(n){return Vi(this,arguments,function*(){const e=yield Ft(Er.from(n));try{if(!(yield Ft(e.open({autoDestroy:!1}))).closed)do yield yield Ft(e);while(!(yield Ft(e.reset().open())).closed)}finally{yield Ft(e.cancel())}})}function v2(n){return new sd(new b2(n))}function S2(n){const t=n.peek(zu+7&-8);return t&&t.byteLength>=4?cm(t)?new ax(new ox(n.read())):new sd(new ld(n)):new sd(new ld(function*(){}()))}function T2(n){return St(this,void 0,void 0,function*(){const t=yield n.peek(zu+7&-8);return t&&t.byteLength>=4?cm(t)?new ax(new ox(yield n.read())):new ad(new od(n)):new ad(new od(function(){return Vi(this,arguments,function*(){})}()))})}function w2(n){return St(this,void 0,void 0,function*(){const{size:t}=yield n.stat(),e=new ed(n,t);return t>=y2&&cm(yield e.readAt(0,zu+7&-8))?new m2(new _2(e)):new ad(new od(e))})}class De extends jt{constructor(){super(),this._byteLength=0,this._nodes=[],this._buffers=[],this._bufferRegions=[]}static assemble(...t){const e=l=>l.flatMap(o=>Array.isArray(o)?e(o):o instanceof _n?o.data.children:o.data),s=new De;return s.visitMany(e(t)),s}visit(t){if(t instanceof Wt)return this.visitMany(t.data),this;const{type:e}=t;if(!wt.isDictionary(e)){const{length:s,nullCount:l}=t;if(s>2147483647)throw new RangeError("Cannot write arrays larger than 2^31 - 1 in length");wt.isNull(e)||gi.call(this,l<=0?new Uint8Array(0):Qy(t.offset,s,t.nullBitmap)),this.nodes.push(new va(s,l))}return super.visit(t)}visitNull(t){return this}visitDictionary(t){return this.visit(t.clone(t.type.indices))}get nodes(){return this._nodes}get buffers(){return this._buffers}get byteLength(){return this._byteLength}get bufferRegions(){return this._bufferRegions}}function gi(n){const t=n.byteLength+7&-8;return this.buffers.push(n),this.bufferRegions.push(new Hi(this._byteLength,t)),this._byteLength+=t,this}function x2(n){const{type:t,length:e,typeIds:s,valueOffsets:l}=n;if(gi.call(this,s),t.mode===Un.Sparse)return sy.call(this,n);if(t.mode===Un.Dense){if(n.offset<=0)return gi.call(this,l),sy.call(this,n);{const o=s.reduce((y,m)=>Math.max(y,m),s[0]),c=new Int32Array(o+1),f=new Int32Array(o+1).fill(-1),h=new Int32Array(e),p=Yy(-l[0],e,l);for(let y,m,_=-1;++_<e;)(m=f[y=s[_]])===-1&&(m=f[y]=p[y]),h[_]=p[_]-m,++c[y];gi.call(this,h);for(let y,m=-1,_=t.children.length;++m<_;)if(y=n.children[m]){const S=t.typeIds[m],v=Math.min(e,c[S]);this.visit(y.slice(f[S],v))}}}return this}function A2(n){let t;return n.nullCount>=n.length?gi.call(this,new Uint8Array(0)):(t=n.values)instanceof Uint8Array?gi.call(this,Qy(n.offset,n.length,t)):gi.call(this,Kf(n.values))}function Ss(n){return gi.call(this,n.values.subarray(0,n.length*n.stride))}function cx(n){const{length:t,values:e,valueOffsets:s}=n,l=s[0],o=s[t],c=Math.min(o-l,e.byteLength-l);return gi.call(this,Yy(-s[0],t,s)),gi.call(this,e.subarray(l,l+c)),this}function fm(n){const{length:t,valueOffsets:e}=n;return e&&gi.call(this,Yy(e[0],t,e)),this.visit(n.children[0])}function sy(n){return this.visitMany(n.type.children.map((t,e)=>n.children[e]).filter(Boolean))[0]}De.prototype.visitBool=A2;De.prototype.visitInt=Ss;De.prototype.visitFloat=Ss;De.prototype.visitUtf8=cx;De.prototype.visitBinary=cx;De.prototype.visitFixedSizeBinary=Ss;De.prototype.visitDate=Ss;De.prototype.visitTimestamp=Ss;De.prototype.visitTime=Ss;De.prototype.visitDecimal=Ss;De.prototype.visitList=fm;De.prototype.visitStruct=sy;De.prototype.visitUnion=x2;De.prototype.visitInterval=Ss;De.prototype.visitFixedSizeList=fm;De.prototype.visitMap=fm;class fx extends nm{constructor(t){super(),this._position=0,this._started=!1,this._sink=new Ef,this._schema=null,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,Tn(t)||(t={autoDestroy:!0,writeLegacyIpcFormat:!1}),this._autoDestroy=typeof t.autoDestroy=="boolean"?t.autoDestroy:!0,this._writeLegacyIpcFormat=typeof t.writeLegacyIpcFormat=="boolean"?t.writeLegacyIpcFormat:!1}static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t,e){throw new Error('"throughDOM" not available in this environment')}toString(t=!1){return this._sink.toString(t)}toUint8Array(t=!1){return this._sink.toUint8Array(t)}writeAll(t){return fs(t)?t.then(e=>this.writeAll(e)):Yl(t)?pm(this,t):gm(this,t)}get closed(){return this._sink.closed}[Symbol.asyncIterator](){return this._sink[Symbol.asyncIterator]()}toDOMStream(t){return this._sink.toDOMStream(t)}toNodeStream(t){return this._sink.toNodeStream(t)}close(){return this.reset()._sink.close()}abort(t){return this.reset()._sink.abort(t)}finish(){return this._autoDestroy?this.close():this.reset(this._sink,this._schema),this}reset(t=this._sink,e=null){return t===this._sink||t instanceof Ef?this._sink=t:(this._sink=new Ef,t&&KN(t)?this.toDOMStream({type:"bytes"}).pipeTo(t):t&&PN(t)&&this.toNodeStream({objectMode:!1}).pipe(t)),this._started&&this._schema&&this._writeFooter(this._schema),this._started=!1,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,(!e||!ey(e,this._schema))&&(e==null?(this._position=0,this._schema=null):(this._started=!0,this._schema=e,this._writeSchema(e))),this}write(t){let e=null;if(this._sink){if(t==null)return this.finish()&&void 0;if(t instanceof rn&&!(e=t.schema))return this.finish()&&void 0;if(t instanceof _n&&!(e=t.schema))return this.finish()&&void 0}else throw new Error("RecordBatchWriter is closed");if(e&&!ey(e,this._schema)){if(this._started&&this._autoDestroy)return this.close();this.reset(this._sink,e)}t instanceof _n?t instanceof lm||this._writeRecordBatch(t):t instanceof rn?this.writeAll(t.batches):Lu(t)&&this.writeAll(t)}_writeMessage(t,e=8){const s=e-1,l=an.encode(t),o=l.byteLength,c=this._writeLegacyIpcFormat?4:8,f=o+c+s&~s,h=f-o-c;return t.headerType===Jt.RecordBatch?this._recordBatchBlocks.push(new ps(f,t.bodyLength,this._position)):t.headerType===Jt.DictionaryBatch&&this._dictionaryBlocks.push(new ps(f,t.bodyLength,this._position)),this._writeLegacyIpcFormat||this._write(Int32Array.of(-1)),this._write(Int32Array.of(f-c)),o>0&&this._write(l),this._writePadding(h)}_write(t){if(this._started){const e=Zt(t);e&&e.byteLength>0&&(this._sink.write(e),this._position+=e.byteLength)}return this}_writeSchema(t){return this._writeMessage(an.from(t))}_writeFooter(t){return this._writeLegacyIpcFormat?this._write(Int32Array.of(0)):this._write(Int32Array.of(-1,0))}_writeMagic(){return this._write(xu)}_writePadding(t){return t>0?this._write(new Uint8Array(t)):this}_writeRecordBatch(t){const{byteLength:e,nodes:s,bufferRegions:l,buffers:o}=De.assemble(t),c=new zn(t.numRows,s,l),f=an.from(c,e);return this._writeDictionaries(t)._writeMessage(f)._writeBodyBuffers(o)}_writeDictionaryBatch(t,e,s=!1){this._dictionaryDeltaOffsets.set(e,t.length+(this._dictionaryDeltaOffsets.get(e)||0));const{byteLength:l,nodes:o,bufferRegions:c,buffers:f}=De.assemble(new Wt([t])),h=new zn(t.length,o,c),p=new Pi(h,e,s),y=an.from(p,l);return this._writeMessage(y)._writeBodyBuffers(f)}_writeBodyBuffers(t){let e,s,l;for(let o=-1,c=t.length;++o<c;)(e=t[o])&&(s=e.byteLength)>0&&(this._write(e),(l=(s+7&-8)-s)>0&&this._writePadding(l));return this}_writeDictionaries(t){for(let[e,s]of t.dictionaries){let l=this._dictionaryDeltaOffsets.get(e)||0;if(l===0||(s=s==null?void 0:s.slice(l)).length>0)for(const o of s.data)this._writeDictionaryBatch(o,e,l>0),l+=o.length}return this}}class dm extends fx{static writeAll(t,e){const s=new dm(e);return fs(t)?t.then(l=>s.writeAll(l)):Yl(t)?pm(s,t):gm(s,t)}}class hm extends fx{static writeAll(t){const e=new hm;return fs(t)?t.then(s=>e.writeAll(s)):Yl(t)?pm(e,t):gm(e,t)}constructor(){super(),this._autoDestroy=!0}_writeSchema(t){return this._writeMagic()._writePadding(2)}_writeFooter(t){const e=wu.encode(new wu(t,kn.V4,this._recordBatchBlocks,this._dictionaryBlocks));return super._writeFooter(t)._write(e)._write(Int32Array.of(e.byteLength))._writeMagic()}}function gm(n,t){let e=t;t instanceof rn&&(e=t.batches,n.reset(void 0,t.schema));for(const s of e)n.write(s);return n.finish()}function pm(n,t){var e,s,l,o;return St(this,void 0,void 0,function*(){try{for(e=sa(t);s=yield e.next(),!s.done;){const c=s.value;n.write(c)}}catch(c){l={error:c}}finally{try{s&&!s.done&&(o=e.return)&&(yield o.call(e))}finally{if(l)throw l.error}}return n.finish()})}function au(n){const t=Er.from(n);return fs(t)?t.then(e=>au(e)):t.isAsync()?t.readAll().then(e=>new rn(e)):new rn(t.readAll())}function Ap(n,t="stream"){return(t==="stream"?dm:hm).writeAll(n).toUint8Array(!0)}var FS=function(){function n(t,e,s,l){var o=this;this.getCell=function(c,f){var h=c<o.headerRows&&f<o.headerColumns,p=c>=o.headerRows&&f<o.headerColumns,y=c<o.headerRows&&f>=o.headerColumns;if(h){var m=["blank"];return f>0&&m.push("level"+c),{type:"blank",classNames:m.join(" "),content:""}}else if(y){var _=f-o.headerColumns,m=["col_heading","level"+c,"col"+_];return{type:"columns",classNames:m.join(" "),content:o.getContent(o.columnsTable,_,c)}}else if(p){var S=c-o.headerRows,m=["row_heading","level"+f,"row"+S];return{type:"index",id:"T_".concat(o.uuid,"level").concat(f,"_row").concat(S),classNames:m.join(" "),content:o.getContent(o.indexTable,S,f)}}else{var S=c-o.headerRows,_=f-o.headerColumns,m=["data","row"+S,"col"+_],v=o.styler?o.getContent(o.styler.displayValuesTable,S,_):o.getContent(o.dataTable,S,_);return{type:"data",id:"T_".concat(o.uuid,"row").concat(S,"_col").concat(_),classNames:m.join(" "),content:v}}},this.getContent=function(c,f,h){var p=c.getChildAt(h);if(p===null)return"";var y=o.getColumnTypeId(c,h);switch(y){case k.Timestamp:return o.nanosToDate(p.get(f));default:return p.get(f)}},this.dataTable=au(t),this.indexTable=au(e),this.columnsTable=au(s),this.styler=l?{caption:l.caption,displayValuesTable:au(l.displayValues),styles:l.styles,uuid:l.uuid}:void 0}return Object.defineProperty(n.prototype,"rows",{get:function(){return this.indexTable.numRows+this.columnsTable.numCols},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"columns",{get:function(){return this.indexTable.numCols+this.columnsTable.numRows},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"headerRows",{get:function(){return this.rows-this.dataRows},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"headerColumns",{get:function(){return this.columns-this.dataColumns},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"dataRows",{get:function(){return this.dataTable.numRows},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"dataColumns",{get:function(){return this.dataTable.numCols},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"uuid",{get:function(){return this.styler&&this.styler.uuid},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"caption",{get:function(){return this.styler&&this.styler.caption},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"styles",{get:function(){return this.styler&&this.styler.styles},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"table",{get:function(){return this.dataTable},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"index",{get:function(){return this.indexTable},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"columnTable",{get:function(){return this.columnsTable},enumerable:!1,configurable:!0}),n.prototype.serialize=function(){return{data:Ap(this.dataTable),index:Ap(this.indexTable),columns:Ap(this.columnsTable)}},n.prototype.getColumnTypeId=function(t,e){return t.schema.fields[e].type.typeId},n.prototype.nanosToDate=function(t){return new Date(t/1e6)},n}(),du=function(){return du=Object.assign||function(n){for(var t,e=1,s=arguments.length;e<s;e++){t=arguments[e];for(var l in t)Object.prototype.hasOwnProperty.call(t,l)&&(n[l]=t[l])}return n},du.apply(this,arguments)},hu;(function(n){n.COMPONENT_READY="streamlit:componentReady",n.SET_COMPONENT_VALUE="streamlit:setComponentValue",n.SET_FRAME_HEIGHT="streamlit:setFrameHeight"})(hu||(hu={}));var br=function(){function n(){}return n.API_VERSION=1,n.RENDER_EVENT="streamlit:render",n.events=new EventTarget,n.registeredMessageListener=!1,n.setComponentReady=function(){n.registeredMessageListener||(window.addEventListener("message",n.onMessageEvent),n.registeredMessageListener=!0),n.sendBackMsg(hu.COMPONENT_READY,{apiVersion:n.API_VERSION})},n.setFrameHeight=function(t){t===void 0&&(t=document.body.scrollHeight),t!==n.lastFrameHeight&&(n.lastFrameHeight=t,n.sendBackMsg(hu.SET_FRAME_HEIGHT,{height:t}))},n.setComponentValue=function(t){var e;t instanceof FS?(e="dataframe",t=t.serialize()):O2(t)?(e="bytes",t=new Uint8Array(t.buffer)):t instanceof ArrayBuffer?(e="bytes",t=new Uint8Array(t)):e="json",n.sendBackMsg(hu.SET_COMPONENT_VALUE,{value:t,dataType:e})},n.onMessageEvent=function(t){var e=t.data.type;switch(e){case n.RENDER_EVENT:n.onRenderMessage(t.data);break}},n.onRenderMessage=function(t){var e=t.args;e==null&&(console.error("Got null args in onRenderMessage. This should never happen"),e={});var s=t.dfs&&t.dfs.length>0?n.argsDataframeToObject(t.dfs):{};e=du(du({},e),s);var l=!!t.disabled,o=t.theme;o&&E2(o);var c={disabled:l,args:e,theme:o},f=new CustomEvent(n.RENDER_EVENT,{detail:c});n.events.dispatchEvent(f)},n.argsDataframeToObject=function(t){var e=t.map(function(s){var l=s.key,o=s.value;return[l,n.toArrowTable(o)]});return Object.fromEntries(e)},n.toArrowTable=function(t){var e,s=(e=t.data,e.data),l=e.index,o=e.columns,c=e.styler;return new FS(s,l,o,c)},n.sendBackMsg=function(t,e){window.parent.postMessage(du({isStreamlitMessage:!0,type:t},e),"*")},n}(),E2=function(n){var t=document.createElement("style");document.head.appendChild(t),t.innerHTML=`
    :root {
      --primary-color: `.concat(n.primaryColor,`;
      --background-color: `).concat(n.backgroundColor,`;
      --secondary-background-color: `).concat(n.secondaryBackgroundColor,`;
      --text-color: `).concat(n.textColor,`;
      --font: `).concat(n.font,`;
    }

    body {
      background-color: var(--background-color);
      color: var(--text-color);
    }
  `)};function O2(n){var t=!1;try{t=n instanceof BigInt64Array||n instanceof BigUint64Array}catch{}return n instanceof Int8Array||n instanceof Uint8Array||n instanceof Uint8ClampedArray||n instanceof Int16Array||n instanceof Uint16Array||n instanceof Int32Array||n instanceof Uint32Array||n instanceof Float32Array||n instanceof Float64Array||t}var dx=function(){var n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var o in l)Object.prototype.hasOwnProperty.call(l,o)&&(s[o]=l[o])},n(t,e)};return function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");n(t,e);function s(){this.constructor=t}t.prototype=e===null?Object.create(e):(s.prototype=e.prototype,new s)}}(),N2=function(n){dx(t,n);function t(){return n!==null&&n.apply(this,arguments)||this}return t.prototype.componentDidMount=function(){br.setFrameHeight()},t.prototype.componentDidUpdate=function(){br.setFrameHeight()},t}(Zs.PureComponent);function C2(n){var t=function(e){dx(s,e);function s(l){var o=e.call(this,l)||this;return o.componentDidMount=function(){br.events.addEventListener(br.RENDER_EVENT,o.onRenderEvent),br.setComponentReady()},o.componentDidUpdate=function(){o.state.componentError!=null&&br.setFrameHeight()},o.componentWillUnmount=function(){br.events.removeEventListener(br.RENDER_EVENT,o.onRenderEvent)},o.onRenderEvent=function(c){o.setState({renderData:c.detail})},o.state={renderData:void 0,componentError:void 0},o}return s.prototype.render=function(){return this.state.componentError!=null?Zs.createElement("div",null,Zs.createElement("h1",null,"Component Error"),Zs.createElement("span",null,this.state.componentError.message)):this.state.renderData==null?null:Zs.createElement(n,{width:window.innerWidth,disabled:this.state.renderData.disabled,args:this.state.renderData.args,theme:this.state.renderData.theme})},s.getDerivedStateFromError=function(l){return{componentError:l}},s}(Zs.PureComponent);return jN(t,n)}const hx=ft.createContext(null);function D2(n,t){return{getTheme:function(){return t??null}}}function Vn(){const n=ft.useContext(hx);return n==null&&function(t,...e){const s=new URL("https://lexical.dev/docs/error"),l=new URLSearchParams;l.append("code",t);for(const o of e)l.append("v",o);throw s.search=l.toString(),Error(`Minified Lexical error #${t}; visit ${s.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}(8),n}function X(n,...t){const e=new URL("https://lexical.dev/docs/error"),s=new URLSearchParams;s.append("code",n);for(const l of t)s.append("v",l);throw e.search=s.toString(),Error(`Minified Lexical error #${n}; visit ${e.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}const Si=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0,M2=Si&&"documentMode"in document?document.documentMode:null,Fi=Si&&/Mac|iPod|iPhone|iPad/.test(navigator.platform),fa=Si&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),ud=!(!Si||!("InputEvent"in window)||M2)&&"getTargetRanges"in new window.InputEvent("input"),Au=Si&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),kl=Si&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,B2=Si&&/Android/.test(navigator.userAgent),gx=Si&&/^(?=.*Chrome).*/i.test(navigator.userAgent),LS=Si&&B2&&gx,cd=Si&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent)&&!gx;function fd(...n){const t=[];for(const e of n)if(e&&typeof e=="string")for(const[s]of e.matchAll(/\S+/g))t.push(s);return t}const R2=1,F2=3,L2=9,I2=11,da=0,px=1,Ul=2,k2=0,U2=1,z2=2,dd=4,hd=8,ym=128,$2=1792|(112|(3|dd|hd)|ym),mm=1,_m=2,bm=3,vm=4,Sm=5,Tm=6,Ld=Au||kl||cd?" ":"​",Nr=`

`,j2=fa?" ":Ld,yx="֑-߿יִ-﷽ﹰ-ﻼ",mx="A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-",V2=new RegExp("^[^"+mx+"]*["+yx+"]"),H2=new RegExp("^[^"+yx+"]*["+mx+"]"),ha={bold:1,capitalize:1024,code:16,highlight:ym,italic:2,lowercase:256,strikethrough:dd,subscript:32,superscript:64,underline:hd,uppercase:512},Y2={directionless:1,unmergeable:2},IS={center:_m,end:Tm,justify:vm,left:mm,right:bm,start:Sm},q2={[_m]:"center",[Tm]:"end",[vm]:"justify",[mm]:"left",[bm]:"right",[Sm]:"start"},K2={normal:0,segmented:2,token:1},P2={[k2]:"normal",[z2]:"segmented",[U2]:"token"},kS="$config";function _x(n,t,e,s,l,o){let c=n.getFirstChild();for(;c!==null;){const f=c.__key;c.__parent===t&&(Y(c)&&_x(c,f,e,s,l,o),e.has(f)||o.delete(f),l.push(f)),c=c.getNextSibling()}}const G2=100;let ay=!1,wm=0;function Z2(n){wm=n.timeStamp}function Ep(n,t,e){const s=n.nodeName==="BR",l=t.__lexicalLineBreak;return l&&(n===l||s&&n.previousSibling===l)||s&&Pd(n,e)!==void 0}function X2(n,t,e){const s=mi(li(e));let l=null,o=null;s!==null&&s.anchorNode===n&&(l=s.anchorOffset,o=s.focusOffset);const c=n.nodeValue;c!==null&&Vm(t,c,l,o,!1)}function Q2(n,t,e){if(Z(n)){const s=n.anchor.getNode();if(s.is(e)&&n.format!==s.getFormat())return!1}return Br(t)&&e.isAttached()}function J2(n,t,e,s){for(let l=n;l&&!XM(l);l=Ku(l)){const o=Pd(l,t);if(o!==void 0){const c=Ce(o,e);if(c)return qt(c)||!Me(l)?void 0:[l,c]}else if(l===s)return[s,pA(e)]}}function bx(n,t,e){ay=!0;const s=performance.now()-wm>G2;try{In(n,()=>{const l=nt()||function(_){return _.getEditorState().read(()=>{const S=nt();return S!==null?S.clone():null})}(n),o=new Map,c=n.getRootElement(),f=n._editorState,h=n._blockCursorElement;let p=!1,y="";for(let _=0;_<t.length;_++){const S=t[_],v=S.type,A=S.target,x=J2(A,n,f,c);if(!x)continue;const[C,w]=x;if(v==="characterData")s&&W(w)&&Br(A)&&Q2(l,A,w)&&X2(A,w,n);else if(v==="childList"){p=!0;const E=S.addedNodes;for(let D=0;D<E.length;D++){const I=E[D],z=hA(I),L=I.parentNode;if(L!=null&&I!==h&&z===null&&!Ep(I,L,n)){if(fa){const J=(Me(I)?I.innerText:null)||I.nodeValue;J&&(y+=J)}L.removeChild(I)}}const M=S.removedNodes,O=M.length;if(O>0){let D=0;for(let I=0;I<O;I++){const z=M[I];(Ep(z,A,n)||h===z)&&(A.appendChild(z),D++)}O!==D&&o.set(C,w)}}}if(o.size>0)for(const[_,S]of o)S.reconcileObservedMutation(_,n);const m=e.takeRecords();if(m.length>0){for(let _=0;_<m.length;_++){const S=m[_],v=S.addedNodes,A=S.target;for(let x=0;x<v.length;x++){const C=v[x],w=C.parentNode;w==null||C.nodeName!=="BR"||Ep(C,A,n)||w.removeChild(C)}}e.takeRecords()}l!==null&&(p&&Ze(l),fa&&bA(n)&&l.insertRawText(y))})}finally{ay=!1}}function vx(n){const t=n._observer;t!==null&&bx(n,t.takeRecords(),t)}function Sx(n){(function(t){wm===0&&li(t).addEventListener("textInput",Z2,!0)})(n),n._observer=new MutationObserver((t,e)=>{bx(n,t,e)})}function W2(n){const t=new Map,e=new Set;for(let s=typeof n=="function"?n:n.replace;s.prototype&&s.prototype.getType!==void 0;s=Object.getPrototypeOf(s)){const{ownNodeConfig:l}=Gm(s);if(l&&l.stateConfigs)for(const o of l.stateConfigs){let c;"stateConfig"in o?(c=o.stateConfig,o.flat&&e.add(c.key)):c=o,t.set(c.key,c)}}return{flatKeys:e,sharedConfigMap:t}}let tM=class Tx{constructor(t,e,s=void 0,l=new Map,o=void 0){this.node=t,this.sharedNodeState=e,this.unknownState=s,this.knownState=l;const{sharedConfigMap:c}=this.sharedNodeState,f=o!==void 0?o:function(h,p,y){let m=y.size;if(p)for(const _ in p){const S=h.get(_);S&&y.has(S)||m++}return m}(c,s,l);this.size=f}getValue(t){const e=this.knownState.get(t);if(e!==void 0)return e;this.sharedNodeState.sharedConfigMap.set(t.key,t);let s=t.defaultValue;if(this.unknownState&&t.key in this.unknownState){const l=this.unknownState[t.key];l!==void 0&&(s=t.parse(l)),this.updateFromKnown(t,s)}return s}getInternalState(){return[this.unknownState,this.knownState]}toJSON(){const t={...this.unknownState},e={};for(const[s,l]of this.knownState)s.isEqual(l,s.defaultValue)?delete t[s.key]:t[s.key]=s.unparse(l);for(const s of this.sharedNodeState.flatKeys)s in t&&(e[s]=t[s],delete t[s]);return US(t)&&(e.$=t),e}getWritable(t){if(this.node===t)return this;const{sharedNodeState:e,unknownState:s}=this,l=new Map(this.knownState);return new Tx(t,e,function(o,c,f){let h;if(f)for(const[p,y]of Object.entries(f)){const m=o.get(p);m?c.has(m)||c.set(m,m.parse(y)):(h=h||{},h[p]=y)}return h}(e.sharedConfigMap,l,s),l,this.size)}updateFromKnown(t,e){const s=t.key;this.sharedNodeState.sharedConfigMap.set(s,t);const{knownState:l,unknownState:o}=this;l.has(t)||o&&s in o||(o&&(delete o[s],this.unknownState=US(o)),this.size++),l.set(t,e)}updateFromUnknown(t,e){const s=this.sharedNodeState.sharedConfigMap.get(t);s?this.updateFromKnown(s,s.parse(e)):(this.unknownState=this.unknownState||{},t in this.unknownState||this.size++,this.unknownState[t]=e)}updateFromJSON(t){const{knownState:e}=this;for(const s of e.keys())e.set(s,s.defaultValue);if(this.size=e.size,this.unknownState=void 0,t)for(const[s,l]of Object.entries(t))this.updateFromUnknown(s,l)}};function eM(n){const t=n.getWritable(),e=t.__state?t.__state.getWritable(t):new tM(t,wx(t));return t.__state=e,e}function wx(n){return n.__state?n.__state.sharedNodeState:cA(qm(),n.getType()).sharedNodeState}function US(n){if(n)for(const t in n)return n}function zS(n,t,e){for(const[s,l]of t.knownState){if(n.has(s.key))continue;n.add(s.key);const o=e?e.getValue(s):s.defaultValue;if(o!==l&&!s.isEqual(o,l))return!0}return!1}function $S(n,t,e){const{unknownState:s}=t,l=e?e.unknownState:void 0;if(s){for(const[o,c]of Object.entries(s))if(!n.has(o)&&(n.add(o),c!==(l?l[o]:void 0)))return!0}return!1}function jS(n,t){const e=n.__state;return e&&e.node===n?e.getWritable(t):e}function VS(n,t){const e=n.__mode,s=n.__format,l=n.__style,o=t.__mode,c=t.__format,f=t.__style,h=n.__state,p=t.__state;return(e===null||e===o)&&(s===null||s===c)&&(l===null||l===f)&&(n.__state===null||h===p||function(y,m){if(y===m)return!0;if(y&&m&&y.size!==m.size)return!1;const _=new Set;return!(y&&zS(_,y,m)||m&&zS(_,m,y)||y&&$S(_,y,m)||m&&$S(_,m,y))}(h,p))}function HS(n,t){const e=n.mergeWithSibling(t),s=ve()._normalizedNodes;return s.add(n.__key),s.add(t.__key),e}function YS(n){let t,e,s=n;if(s.__text!==""||!s.isSimpleText()||s.isUnmergeable()){for(;(t=s.getPreviousSibling())!==null&&W(t)&&t.isSimpleText()&&!t.isUnmergeable();){if(t.__text!==""){if(VS(t,s)){s=HS(t,s);break}break}t.remove()}for(;(e=s.getNextSibling())!==null&&W(e)&&e.isSimpleText()&&!e.isUnmergeable();){if(e.__text!==""){if(VS(s,e)){s=HS(s,e);break}break}e.remove()}}else s.remove()}function gd(n){return qS(n.anchor),qS(n.focus),n}function qS(n){for(;n.type==="element";){const t=n.getNode(),e=n.offset;let s,l;if(e===t.getChildrenSize()?(s=t.getChildAtIndex(e-1),l=!0):(s=t.getChildAtIndex(e),l=!1),W(s)){n.set(s.__key,l?s.getTextContentSize():0,"text",!0);break}if(!Y(s))break;n.set(s.__key,l?s.getChildrenSize():0,"element",!0)}}let ms,on,Eu,Id,ly,oy,ga,pi,uy,Ou,Ie="",ln="",Bi=null,Ri="",vr="",xx=!1,Nu=!1,Cf=null;function pd(n,t){const e=ga.get(n);if(t!==null){const s=dy(n);s.parentNode===t&&t.removeChild(s)}if(pi.has(n)||on._keyToDOMMap.delete(n),Y(e)){const s=md(e,ga);cy(s,0,s.length-1,null)}e!==void 0&&Hm(Ou,Eu,Id,e,"destroyed")}function cy(n,t,e,s){let l=t;for(;l<=e;++l){const o=n[l];o!==void 0&&pd(o,s)}}function Ks(n,t){n.setProperty("text-align",t)}const nM="40px";function Ax(n,t){const e=ms.theme.indent;if(typeof e=="string"){const l=n.classList.contains(e);t>0&&!l?n.classList.add(e):t<1&&l&&n.classList.remove(e)}const s=getComputedStyle(n).getPropertyValue("--lexical-indent-base-value")||nM;n.style.setProperty("padding-inline-start",t===0?"":`calc(${t} * ${s})`)}function Ex(n,t){const e=n.style;t===0?Ks(e,""):t===mm?Ks(e,"left"):t===_m?Ks(e,"center"):t===bm?Ks(e,"right"):t===vm?Ks(e,"justify"):t===Sm?Ks(e,"start"):t===Tm&&Ks(e,"end")}function yd(n,t){const e=pi.get(n);e===void 0&&X(60);const s=e.createDOM(ms,on);if(function(l,o,c){const f=c._keyToDOMMap;(function(h,p,y){const m=`__lexicalKey_${p._key}`;h[m]=y})(o,c,l),f.set(l,o)}(n,s,on),W(e)?s.setAttribute("data-lexical-text","true"):qt(e)&&s.setAttribute("data-lexical-decorator","true"),Y(e)){const l=e.__indent,o=e.__size;if(l!==0&&Ax(s,l),o!==0){const f=o-1;(function(h,p,y,m){const _=ln;ln="",fy(h,y,0,p,y.getDOMSlot(m)),Nx(y,m),ln=_})(md(e,pi),f,e,s)}const c=e.__format;c!==0&&Ex(s,c),e.isInline()||Ox(null,e,s),Gd(e)&&(Ie+=Nr,vr+=Nr)}else{const l=e.getTextContent();if(qt(e)){const o=e.decorate(on,ms);o!==null&&Cx(n,o),s.contentEditable="false"}else W(e)&&(e.isDirectionless()||(ln+=l));Ie+=l,vr+=l}return t!==null&&t.insertChild(s),Hm(Ou,Eu,Id,e,"created"),s}function fy(n,t,e,s,l){const o=Ie;Ie="";let c=e;for(;c<=s;++c){yd(n[c],l);const f=pi.get(n[c]);f!==null&&W(f)&&(Bi===null&&(Bi=f.getFormat()),Ri===""&&(Ri=f.getStyle()))}Gd(t)&&(Ie+=Nr),l.element.__lexicalTextContent=Ie,Ie=o+Ie}function KS(n,t){if(n){const e=n.__last;if(e){const s=t.get(e);if(s)return os(s)?"line-break":qt(s)&&s.isInline()?"decorator":null}return"empty"}return null}function Ox(n,t,e){const s=KS(n,ga),l=KS(t,pi);s!==l&&t.getDOMSlot(e).setManagedLineBreak(l)}function Nx(n,t){const e=t.__lexicalDirTextContent||"",s=t.__lexicalDir||"";if(e!==ln||s!==Cf){const l=ln==="",o=l?Cf:function(c){return V2.test(c)?"rtl":H2.test(c)?"ltr":null}(ln);if(o!==s){const c=t.classList,f=ms.theme;let h=s!==null?f[s]:void 0,p=o!==null?f[o]:void 0;if(h!==void 0){if(typeof h=="string"){const y=fd(h);h=f[s]=y}c.remove(...h)}if(o===null||l&&o==="ltr")t.removeAttribute("dir");else{if(p!==void 0){if(typeof p=="string"){const y=fd(p);p=f[o]=y}p!==void 0&&c.add(...p)}t.dir=o}Nu||(n.getWritable().__dir=o)}Cf=o,t.__lexicalDirTextContent=ln,t.__lexicalDir=o}}function iM(n,t,e){const s=ln;var l;ln="",Bi=null,Ri="",function(o,c,f){const h=Ie,p=o.__size,y=c.__size;Ie="";const m=f.element;if(p===1&&y===1){const _=o.__first,S=c.__first;if(_===S)lu(_,m);else{const A=dy(_),x=yd(S,null);try{m.replaceChild(x,A)}catch(C){if(typeof C=="object"&&C!=null){const w=`${C.toString()} Parent: ${m.tagName}, new child: {tag: ${x.tagName} key: ${S}}, old child: {tag: ${A.tagName}, key: ${_}}.`;throw new Error(w)}throw C}pd(_,null)}const v=pi.get(S);W(v)&&(Bi===null&&(Bi=v.getFormat()),Ri===""&&(Ri=v.getStyle()))}else{const _=md(o,ga),S=md(c,pi);if(_.length!==p&&X(227),S.length!==y&&X(228),p===0)y!==0&&fy(S,c,0,y-1,f);else if(y===0){if(p!==0){const v=f.after==null&&f.before==null&&f.element.__lexicalLineBreak==null;cy(_,0,p-1,v?null:m),v&&(m.textContent="")}}else(function(v,A,x,C,w,E){const M=C-1,O=w-1;let D,I,z=E.getFirstChild(),L=0,J=0;for(;L<=M&&J<=O;){const vt=A[L],mt=x[J];if(vt===mt)z=Op(lu(mt,E.element)),L++,J++;else{D===void 0&&(D=new Set(A)),I===void 0&&(I=new Set(x));const H=I.has(vt),Q=D.has(mt);if(H)if(Q){const it=jl(on,mt);it===z?z=Op(lu(mt,E.element)):(E.withBefore(z).insertChild(it),lu(mt,E.element)),L++,J++}else yd(mt,E.withBefore(z)),J++;else z=Op(dy(vt)),pd(vt,E.element),L++}const ut=pi.get(mt);ut!==null&&W(ut)&&(Bi===null&&(Bi=ut.getFormat()),Ri===""&&(Ri=ut.getStyle()))}const rt=L>M,dt=J>O;if(rt&&!dt){const vt=x[O+1],mt=vt===void 0?null:on.getElementByKey(vt);fy(x,v,J,O,E.withBefore(mt))}else dt&&!rt&&cy(A,L,M,E.element)})(c,_,S,p,y,f)}Gd(c)&&(Ie+=Nr),m.__lexicalTextContent=Ie,Ie=h+Ie}(n,t,t.getDOMSlot(e)),Nx(t,e),l=t,Bi==null||Bi===l.__textFormat||Nu||l.setTextFormat(Bi),function(o){Ri===""||Ri===o.__textStyle||Nu||o.setTextStyle(Ri)}(t),ln=s}function md(n,t){const e=[];let s=n.__first;for(;s!==null;){const l=t.get(s);l===void 0&&X(101),e.push(s),s=l.__next}return e}function lu(n,t){const e=ga.get(n);let s=pi.get(n);e!==void 0&&s!==void 0||X(61);const l=xx||oy.has(n)||ly.has(n),o=jl(on,n);if(e===s&&!l){if(Y(e)){const c=o.__lexicalTextContent;c!==void 0&&(Ie+=c,vr+=c);const f=o.__lexicalDirTextContent;f!==void 0&&(ln+=f)}else{const c=e.getTextContent();W(e)&&!e.isDirectionless()&&(ln+=c),vr+=c,Ie+=c}return o}if(e!==s&&l&&Hm(Ou,Eu,Id,s,"updated"),s.updateDOM(e,o,ms)){const c=yd(n,null);return t===null&&X(62),t.replaceChild(c,o),pd(n,null),c}if(Y(e)&&Y(s)){const c=s.__indent;c!==e.__indent&&Ax(o,c);const f=s.__format;f!==e.__format&&Ex(o,f),l&&(iM(e,s,o),Pe(s)||s.isInline()||Ox(e,s,o)),Gd(s)&&(Ie+=Nr,vr+=Nr)}else{const c=s.getTextContent();if(qt(s)){const f=s.decorate(on,ms);f!==null&&Cx(n,f)}else W(s)&&!s.isDirectionless()&&(ln+=c);Ie+=c,vr+=c}if(!Nu&&Pe(s)&&s.__cachedText!==vr){const c=s.getWritable();c.__cachedText=vr,s=c}return o}function Cx(n,t){let e=on._pendingDecorators;const s=on._decorators;if(e===null){if(s[n]===t)return;e=gA(on)}e[n]=t}function Op(n){let t=n.nextSibling;return t!==null&&t===on._blockCursorElement&&(t=t.nextSibling),t}function rM(n,t,e,s,l,o){Ie="",vr="",ln="",xx=s===Ul,Cf=null,on=e,ms=e._config,Eu=e._nodes,Id=on._listeners.mutation,ly=l,oy=o,ga=n._nodeMap,pi=t._nodeMap,Nu=t._readOnly,uy=new Map(e._keyToDOMMap);const c=new Map;return Ou=c,lu("root",null),on=void 0,Eu=void 0,ly=void 0,oy=void 0,ga=void 0,pi=void 0,ms=void 0,uy=void 0,Ou=void 0,c}function dy(n){const t=uy.get(n);return t===void 0&&X(75,n),t}function yt(n){return{type:n}}const xm=yt("SELECTION_CHANGE_COMMAND"),sM=yt("SELECTION_INSERT_CLIPBOARD_NODES_COMMAND"),Am=yt("CLICK_COMMAND"),la=yt("DELETE_CHARACTER_COMMAND"),Al=yt("INSERT_LINE_BREAK_COMMAND"),Cu=yt("INSERT_PARAGRAPH_COMMAND"),El=yt("CONTROLLED_TEXT_INSERTION_COMMAND"),Em=yt("PASTE_COMMAND"),hy=yt("REMOVE_TEXT_COMMAND"),Du=yt("DELETE_WORD_COMMAND"),Mu=yt("DELETE_LINE_COMMAND"),hi=yt("FORMAT_TEXT_COMMAND"),kd=yt("UNDO_COMMAND"),Ud=yt("REDO_COMMAND"),aM=yt("KEYDOWN_COMMAND"),Dx=yt("KEY_ARROW_RIGHT_COMMAND"),lM=yt("MOVE_TO_END"),Mx=yt("KEY_ARROW_LEFT_COMMAND"),oM=yt("MOVE_TO_START"),Bx=yt("KEY_ARROW_UP_COMMAND"),Rx=yt("KEY_ARROW_DOWN_COMMAND"),_d=yt("KEY_ENTER_COMMAND"),Fx=yt("KEY_SPACE_COMMAND"),Lx=yt("KEY_BACKSPACE_COMMAND"),Ix=yt("KEY_ESCAPE_COMMAND"),kx=yt("KEY_DELETE_COMMAND"),Ux=yt("KEY_TAB_COMMAND"),uM=yt("INSERT_TAB_COMMAND"),cM=yt("INDENT_CONTENT_COMMAND"),PS=yt("OUTDENT_CONTENT_COMMAND"),zx=yt("DROP_COMMAND"),fM=yt("FORMAT_ELEMENT_COMMAND"),$x=yt("DRAGSTART_COMMAND"),jx=yt("DRAGOVER_COMMAND"),dM=yt("DRAGEND_COMMAND"),zd=yt("COPY_COMMAND"),Om=yt("CUT_COMMAND"),gy=yt("SELECT_ALL_COMMAND"),hM=yt("CLEAR_EDITOR_COMMAND"),Vx=yt("CLEAR_HISTORY_COMMAND"),ou=yt("CAN_REDO_COMMAND"),uu=yt("CAN_UNDO_COMMAND"),gM=yt("FOCUS_COMMAND"),pM=yt("BLUR_COMMAND"),yM=yt("KEY_MODIFIER_COMMAND"),fr=Object.freeze({}),py=30,yy=[["keydown",function(n,t){if(gu=n.timeStamp,Hx=n.key,!t.isComposing()&&!st(t,aM,n)&&n.key!=null){if(Np&&S1(n))return In(t,()=>{df(t,Cp)}),Np=!1,void(Cp="");if(function(e){return ie(e,"ArrowRight",{shiftKey:"any"})}(n))st(t,Dx,n);else if(function(e){return ie(e,"ArrowRight",gr)}(n))st(t,lM,n);else if(function(e){return ie(e,"ArrowLeft",{shiftKey:"any"})}(n))st(t,Mx,n);else if(function(e){return ie(e,"ArrowLeft",gr)}(n))st(t,oM,n);else if(function(e){return ie(e,"ArrowUp",{altKey:"any",shiftKey:"any"})}(n))st(t,Bx,n);else if(function(e){return ie(e,"ArrowDown",{altKey:"any",shiftKey:"any"})}(n))st(t,Rx,n);else if(function(e){return ie(e,"Enter",{altKey:"any",ctrlKey:"any",metaKey:"any",shiftKey:!0})}(n))pu=!0,st(t,_d,n);else if(function(e){return e.key===" "}(n))st(t,Fx,n);else if(function(e){return Fi&&ie(e,"o",{ctrlKey:!0})}(n))n.preventDefault(),pu=!0,st(t,Al,!0);else if(function(e){return ie(e,"Enter",{altKey:"any",ctrlKey:"any",metaKey:"any"})}(n))pu=!1,st(t,_d,n);else if(function(e){return ie(e,"Backspace",{shiftKey:"any"})||Fi&&ie(e,"h",{ctrlKey:!0})}(n))S1(n)?st(t,Lx,n):(n.preventDefault(),st(t,la,!0));else if(function(e){return e.key==="Escape"}(n))st(t,Ix,n);else if(function(e){return ie(e,"Delete",{})||Fi&&ie(e,"d",{ctrlKey:!0})}(n))(function(e){return e.key==="Delete"})(n)?st(t,kx,n):(n.preventDefault(),st(t,la,!1));else if(function(e){return ie(e,"Backspace",v1)}(n))n.preventDefault(),st(t,Du,!0);else if(function(e){return ie(e,"Delete",v1)}(n))n.preventDefault(),st(t,Du,!1);else if(function(e){return Fi&&ie(e,"Backspace",{metaKey:!0})}(n))n.preventDefault(),st(t,Mu,!0);else if(function(e){return Fi&&(ie(e,"Delete",{metaKey:!0})||ie(e,"k",{ctrlKey:!0}))}(n))n.preventDefault(),st(t,Mu,!1);else if(function(e){return ie(e,"b",gr)}(n))n.preventDefault(),st(t,hi,"bold");else if(function(e){return ie(e,"u",gr)}(n))n.preventDefault(),st(t,hi,"underline");else if(function(e){return ie(e,"i",gr)}(n))n.preventDefault(),st(t,hi,"italic");else if(function(e){return ie(e,"Tab",{shiftKey:"any"})}(n))st(t,Ux,n);else if(function(e){return ie(e,"z",gr)}(n))n.preventDefault(),st(t,kd,void 0);else if(function(e){return Fi?ie(e,"z",{metaKey:!0,shiftKey:!0}):ie(e,"y",{ctrlKey:!0})||ie(e,"z",{ctrlKey:!0,shiftKey:!0})}(n))n.preventDefault(),st(t,Ud,void 0);else{const e=t._editorState._selection;e===null||Z(e)?T1(n)&&(n.preventDefault(),st(t,gy,n)):function(s){return ie(s,"c",gr)}(n)?(n.preventDefault(),st(t,zd,n)):function(s){return ie(s,"x",gr)}(n)?(n.preventDefault(),st(t,Om,n)):T1(n)&&(n.preventDefault(),st(t,gy,n))}(function(e){return e.ctrlKey||e.shiftKey||e.altKey||e.metaKey})(n)&&st(t,yM,n)}}],["pointerdown",function(n,t){const e=n.target,s=n.pointerType;Zl(e)&&s!=="touch"&&s!=="pen"&&n.button===0&&In(t,()=>{m1(e)||(_y=!0)})}],["compositionstart",function(n,t){In(t,()=>{const e=nt();if(Z(e)&&!t.isComposing()){const s=e.anchor,l=e.anchor.getNode();Ke(s.key),(n.timeStamp<gu+py||s.type==="element"||!e.isCollapsed()||l.getFormat()!==e.format||W(l)&&l.getStyle()!==e.style)&&st(t,El,j2)}})}],["compositionend",function(n,t){fa?iu=!0:kl||!Au&&!cd?In(t,()=>{df(t,n.data)}):(Np=!0,Cp=n.data)}],["input",function(n,t){n.stopPropagation(),In(t,()=>{if(Me(n.target)&&m1(n.target))return;const e=nt(),s=n.data,l=Gx(n);if(s!=null&&Z(e)&&Kx(e,l,s,n.timeStamp,!1)){iu&&(df(t,s),iu=!1);const o=e.anchor.getNode(),c=mi(li(t));if(c===null)return;const f=e.isBackward(),h=f?e.anchor.offset:e.focus.offset,p=f?e.focus.offset:e.anchor.offset;ud&&!e.isCollapsed()&&W(o)&&c.anchorNode!==null&&o.getTextContent().slice(0,h)+s+o.getTextContent().slice(h+p)===_A(c.anchorNode)||st(t,El,s);const y=s.length;fa&&y>1&&n.inputType==="insertCompositionText"&&!t.isComposing()&&(e.anchor.offset-=y),Au||kl||cd||!t.isComposing()||(gu=0,Ke(null))}else jm(!1,t,s!==null?s:void 0),iu&&(df(t,s||void 0),iu=!1);(function(){en();const o=ve();vx(o)})()},{event:n}),yl=null}],["click",function(n,t){In(t,()=>{const e=nt(),s=mi(li(t)),l=Gl();if(s){if(Z(e)){const o=e.anchor,c=o.getNode();if(o.type==="element"&&o.offset===0&&e.isCollapsed()&&!Pe(c)&&ge().getChildrenSize()===1&&c.getTopLevelElementOrThrow().isEmpty()&&l!==null&&e.is(l))s.removeAllRanges(),e.dirty=!0;else if(n.detail===3&&!e.isCollapsed()&&c!==e.focus.getNode()){const f=function(h,p){let y=h;for(;y!==ge()&&y!=null;){if(p(y))return y;y=y.getParent()}return null}(c,h=>Y(h)&&!h.isInline());Y(f)&&f.select(0)}}else if(n.pointerType==="touch"||n.pointerType==="pen"){const o=s.anchorNode;(Me(o)||Br(o))&&Ze(Dm(l,s,t,n))}}st(t,Am,n)})}],["cut",fr],["copy",fr],["dragstart",fr],["dragover",fr],["dragend",fr],["paste",fr],["focus",fr],["blur",fr],["drop",fr]];ud&&yy.push(["beforeinput",(n,t)=>function(e,s){const l=e.inputType,o=Gx(e);l==="deleteCompositionText"||fa&&bA(s)||l!=="insertCompositionText"&&In(s,()=>{const c=nt();if(l==="deleteContentBackward"){if(c===null){const S=Gl();if(!Z(S))return;Ze(S.clone())}if(Z(c)){const S=c.anchor.key===c.focus.key;if(f=e.timeStamp,Hx==="MediaLast"&&f<gu+py&&s.isComposing()&&S){if(Ke(null),gu=0,setTimeout(()=>{In(s,()=>{Ke(null)})},py),Z(c)){const v=c.anchor.getNode();v.markDirty(),W(v)||X(142),Px(c,v)}}else{Ke(null),e.preventDefault();const v=c.anchor.getNode(),A=v.getTextContent(),x=v.canInsertTextAfter(),C=c.anchor.offset===0&&c.focus.offset===A.length;let w=LS&&S&&!C&&x;if(w&&c.isCollapsed()&&(w=!qt(wy(c.anchor,!0))),!w){st(s,la,!0);const E=nt();LS&&Z(E)&&E.isCollapsed()&&(Xs=E,setTimeout(()=>Xs=null))}}return}}var f;if(!Z(c))return;const h=e.data;yl!==null&&jm(!1,s,yl),c.dirty&&yl===null||!c.isCollapsed()||Pe(c.anchor.getNode())||o===null||c.applyDOMRange(o),yl=null;const p=c.anchor,y=c.focus,m=p.getNode(),_=y.getNode();if(l!=="insertText"&&l!=="insertTranspose")switch(e.preventDefault(),l){case"insertFromYank":case"insertFromDrop":case"insertReplacementText":st(s,El,e);break;case"insertFromComposition":Ke(null),st(s,El,e);break;case"insertLineBreak":Ke(null),st(s,Al,!1);break;case"insertParagraph":Ke(null),pu&&!kl?(pu=!1,st(s,Al,!1)):st(s,Cu,void 0);break;case"insertFromPaste":case"insertFromPasteAsQuotation":st(s,Em,e);break;case"deleteByComposition":(function(S,v){return S!==v||Y(S)||Y(v)||!oa(S)||!oa(v)})(m,_)&&st(s,hy,e);break;case"deleteByDrag":case"deleteByCut":st(s,hy,e);break;case"deleteContent":st(s,la,!1);break;case"deleteWordBackward":st(s,Du,!0);break;case"deleteWordForward":st(s,Du,!1);break;case"deleteHardLineBackward":case"deleteSoftLineBackward":st(s,Mu,!0);break;case"deleteContentForward":case"deleteHardLineForward":case"deleteSoftLineForward":st(s,Mu,!1);break;case"formatStrikeThrough":st(s,hi,"strikethrough");break;case"formatBold":st(s,hi,"bold");break;case"formatItalic":st(s,hi,"italic");break;case"formatUnderline":st(s,hi,"underline");break;case"historyUndo":st(s,kd,void 0);break;case"historyRedo":st(s,Ud,void 0)}else{if(h===`
`)e.preventDefault(),st(s,Al,!1);else if(h===Nr)e.preventDefault(),st(s,Cu,void 0);else if(h==null&&e.dataTransfer){const S=e.dataTransfer.getData("text/plain");e.preventDefault(),c.insertRawText(S)}else h!=null&&Kx(c,o,h,e.timeStamp,!0)?(e.preventDefault(),st(s,El,h)):yl=h;Yx=e.timeStamp}})}(n,t)]);let gu=0,Hx=null,Yx=0,yl=null;const bd=new WeakMap;let my=!1,_y=!1,pu=!1,iu=!1,Np=!1,Cp="",Xs=null,qx=[0,"",0,"root",0];function Kx(n,t,e,s,l){const o=n.anchor,c=n.focus,f=o.getNode(),h=ve(),p=mi(li(h)),y=p!==null?p.anchorNode:null,m=o.key,_=h.getElementByKey(m),S=e.length;return m!==c.key||!W(f)||(!l&&(!ud||Yx<s+50)||f.isDirty()&&S<2||yA(e))&&o.offset!==c.offset&&!f.isComposing()||_r(f)||f.isDirty()&&S>1||(l||!ud)&&_!==null&&!f.isComposing()&&y!==zl(_)||p!==null&&t!==null&&(!t.collapsed||t.startContainer!==p.anchorNode||t.startOffset!==p.anchorOffset)||f.getFormat()!==n.format||f.getStyle()!==n.style||function(v,A){if(A.isSegmented())return!0;if(!v.isCollapsed())return!1;const x=v.anchor.offset,C=A.getParentOrThrow(),w=oa(A);return x===0?!A.canInsertTextBefore()||!C.canInsertTextBefore()&&!A.isComposing()||w||function(E){const M=E.getPreviousSibling();return(W(M)||Y(M)&&M.isInline())&&!M.canInsertTextAfter()}(A):x===A.getTextContentSize()&&(!A.canInsertTextAfter()||!C.canInsertTextAfter()&&!A.isComposing()||w)}(n,f)}function GS(n,t){return Br(n)&&n.nodeValue!==null&&t!==0&&t!==n.nodeValue.length}function ZS(n,t,e){const{anchorNode:s,anchorOffset:l,focusNode:o,focusOffset:c}=n;my&&(my=!1,GS(s,l)&&GS(o,c)&&!Xs)||In(t,()=>{if(!e)return void Ze(null);if(!qu(t,s,o))return;let f=nt();if(Xs&&Z(f)&&f.isCollapsed()){const h=f.anchor,p=Xs.anchor;(h.key===p.key&&h.offset===p.offset+1||h.offset===1&&p.getNode().is(h.getNode().getPreviousSibling()))&&(f=Xs.clone(),Ze(f))}if(Xs=null,Z(f)){const h=f.anchor,p=h.getNode();if(f.isCollapsed()){n.type==="Range"&&n.anchorNode===n.focusNode&&(f.dirty=!0);const y=li(t).event,m=y?y.timeStamp:performance.now(),[_,S,v,A,x]=qx,C=ge(),w=t.isComposing()===!1&&C.getTextContent()==="";if(m<x+200&&h.offset===v&&h.key===A)Df(f,_,S);else if(h.type==="text")W(p)||X(141),Px(f,p);else if(h.type==="element"&&!w){Y(p)||X(259);const E=h.getNode();E.isEmpty()?function(M,O){const D=O.getTextFormat(),I=O.getTextStyle();Df(M,D,I)}(f,E):Df(f,0,"")}}else{const y=h.key,m=f.focus.key,_=f.getNodes(),S=_.length,v=f.isBackward(),A=v?c:l,x=v?l:c,C=v?m:y,w=v?y:m;let E=$2,M=!1;for(let O=0;O<S;O++){const D=_[O],I=D.getTextContentSize();if(W(D)&&I!==0&&!(O===0&&D.__key===C&&A===I||O===S-1&&D.__key===w&&x===0)&&(M=!0,E&=D.getFormat(),E===0))break}f.format=M?E:0}}st(t,xm,void 0)})}function Df(n,t,e){n.format===t&&n.style===e||(n.format=t,n.style=e,n.dirty=!0)}function Px(n,t){Df(n,t.getFormat(),t.getStyle())}function Gx(n){if(!n.getTargetRanges)return null;const t=n.getTargetRanges();return t.length===0?null:t[0]}function df(n,t){const e=n._compositionKey;if(Ke(null),e!==null&&t!=null){if(t===""){const s=Ce(e),l=zl(n.getElementByKey(e));return void(l!==null&&l.nodeValue!==null&&W(s)&&Vm(s,l.nodeValue,null,null,!0))}if(t[t.length-1]===`
`){const s=nt();if(Z(s)){const l=s.focus;return s.anchor.set(l.key,l.offset,l.type),void st(n,_d,null)}}}jm(!0,n,t)}function Zx(n){let t=n.__lexicalEventHandles;return t===void 0&&(t=[],n.__lexicalEventHandles=t),t}const Ol=new Map;function Xx(n){const t=GM(n.target);if(t===null)return;const e=fA(t.anchorNode);if(e===null)return;_y&&(_y=!1,In(e,()=>{const h=Gl(),p=t.anchorNode;(Me(p)||Br(p))&&Ze(Dm(h,t,e,n))}));const s=$m(e),l=s[s.length-1],o=l._key,c=Ol.get(o),f=c||l;f!==e&&ZS(t,f,!1),ZS(t,e,!0),e!==l?Ol.set(o,e):c&&Ol.delete(o)}function XS(n){n._lexicalHandled=!0}function QS(n){return n._lexicalHandled===!0}function mM(n){const t=n.ownerDocument,e=bd.get(t);if(e===void 0)return;const s=e-1;s>=0||X(164),bd.set(t,s),s===0&&t.removeEventListener("selectionchange",Xx);const l=Kd(n);zm(l)?(function(c){if(c._parentEditor!==null){const f=$m(c),h=f[f.length-1]._key;Ol.get(h)===c&&Ol.delete(h)}else Ol.delete(c._key)}(l),n.__lexicalEditor=null):l&&X(198);const o=Zx(n);for(let c=0;c<o.length;c++)o[c]();n.__lexicalEventHandles=[]}function by(n,t,e){en();const s=n.__key,l=n.getParent();if(l===null)return;const o=function(f){const h=nt();if(!Z(h)||!Y(f))return h;const{anchor:p,focus:y}=h,m=p.getNode(),_=y.getNode();return xy(m,f)&&p.set(f.__key,0,"element"),xy(_,f)&&y.set(f.__key,0,"element"),h}(n);let c=!1;if(Z(o)&&t){const f=o.anchor,h=o.focus;f.key===s&&(Sd(f,n,l,n.getPreviousSibling(),n.getNextSibling()),c=!0),h.key===s&&(Sd(h,n,l,n.getPreviousSibling(),n.getNextSibling()),c=!0)}else tn(o)&&t&&n.isSelected()&&n.selectPrevious();if(Z(o)&&t&&!c){const f=n.getIndexWithinParent();ua(n),vd(o,l,f,-1)}else ua(n);e||un(l)||l.canBeEmpty()||!l.isEmpty()||by(l,t),t&&o&&Pe(l)&&l.isEmpty()&&l.selectEnd()}class Kl{static getType(){const{ownNodeType:t}=Gm(this);return t===void 0&&X(64,this.name),t}static clone(t){X(65,this.name)}$config(){return{}}config(t,e){const s=e.extends||Object.getPrototypeOf(this.constructor);return Object.assign(e,{extends:s,type:t}),{[t]:e}}afterCloneFrom(t){this.__key===t.__key?(this.__parent=t.__parent,this.__next=t.__next,this.__prev=t.__prev,this.__state=t.__state):t.__state&&(this.__state=t.__state.getWritable(this))}constructor(t){this.__type=this.constructor.getType(),this.__parent=null,this.__prev=null,this.__next=null,Object.defineProperty(this,"__state",{configurable:!0,enumerable:!1,value:void 0,writable:!0}),jM(this,t)}getType(){return this.__type}isInline(){X(137,this.constructor.name)}isAttached(){let t=this.__key;for(;t!==null;){if(t==="root")return!0;const e=Ce(t);if(e===null)break;t=e.__parent}return!1}isSelected(t){const e=t||nt();if(e==null)return!1;const s=e.getNodes().some(l=>l.__key===this.__key);if(W(this))return s;if(Z(e)&&e.anchor.type==="element"&&e.focus.type==="element"){if(e.isCollapsed())return!1;const l=this.getParent();if(qt(this)&&this.isInline()&&l){const o=e.isBackward()?e.focus:e.anchor;if(l.is(o.getNode())&&o.offset===l.getChildrenSize()&&this.is(l.getLastChild()))return!1}}return s}getKey(){return this.__key}getIndexWithinParent(){const t=this.getParent();if(t===null)return-1;let e=t.getFirstChild(),s=0;for(;e!==null;){if(this.is(e))return s;s++,e=e.getNextSibling()}return-1}getParent(){const t=this.getLatest().__parent;return t===null?null:Ce(t)}getParentOrThrow(){const t=this.getParent();return t===null&&X(66,this.__key),t}getTopLevelElement(){let t=this;for(;t!==null;){const e=t.getParent();if(un(e))return Y(t)||t===this&&qt(t)||X(194),t;t=e}return null}getTopLevelElementOrThrow(){const t=this.getTopLevelElement();return t===null&&X(67,this.__key),t}getParents(){const t=[];let e=this.getParent();for(;e!==null;)t.push(e),e=e.getParent();return t}getParentKeys(){const t=[];let e=this.getParent();for(;e!==null;)t.push(e.__key),e=e.getParent();return t}getPreviousSibling(){const t=this.getLatest().__prev;return t===null?null:Ce(t)}getPreviousSiblings(){const t=[],e=this.getParent();if(e===null)return t;let s=e.getFirstChild();for(;s!==null&&!s.is(this);)t.push(s),s=s.getNextSibling();return t}getNextSibling(){const t=this.getLatest().__next;return t===null?null:Ce(t)}getNextSiblings(){const t=[];let e=this.getNextSibling();for(;e!==null;)t.push(e),e=e.getNextSibling();return t}getCommonAncestor(t){const e=Y(this)?this:this.getParent(),s=Y(t)?t:t.getParent(),l=e&&s?Bf(e,s):null;return l?l.commonAncestor:null}is(t){return t!=null&&this.__key===t.__key}isBefore(t){const e=Bf(this,t);return e!==null&&(e.type==="descendant"||(e.type==="branch"?xA(e)===-1:(e.type!=="same"&&e.type!=="ancestor"&&X(279),!1)))}isParentOf(t){const e=Bf(this,t);return e!==null&&e.type==="ancestor"}getNodesBetween(t){const e=this.isBefore(t),s=[],l=new Set;let o=this;for(;o!==null;){const c=o.__key;if(l.has(c)||(l.add(c),s.push(o)),o===t)break;const f=Y(o)?e?o.getFirstChild():o.getLastChild():null;if(f!==null){o=f;continue}const h=e?o.getNextSibling():o.getPreviousSibling();if(h!==null){o=h;continue}const p=o.getParentOrThrow();if(l.has(p.__key)||s.push(p),p===t)break;let y=null,m=p;do{if(m===null&&X(68),y=e?m.getNextSibling():m.getPreviousSibling(),m=m.getParent(),m===null)break;y!==null||l.has(m.__key)||s.push(m)}while(y===null);o=y}return e||s.reverse(),s}isDirty(){const t=ve()._dirtyLeaves;return t!==null&&t.has(this.__key)}getLatest(){const t=Ce(this.__key);return t===null&&X(113),t}getWritable(){en();const t=ws(),e=ve(),s=t._nodeMap,l=this.__key,o=this.getLatest(),c=e._cloneNotNeeded,f=nt();if(f!==null&&f.setCachedNodes(null),c.has(l))return xd(o),o;const h=Km(o);return c.add(l),xd(h),s.set(l,h),h}getTextContent(){return""}getTextContentSize(){return this.getTextContent().length}createDOM(t,e){X(70)}updateDOM(t,e,s){X(71)}exportDOM(t){return{element:this.createDOM(t._config,t)}}exportJSON(){const t=this.__state?this.__state.toJSON():void 0;return{type:this.__type,version:1,...t}}static importJSON(t){X(18,this.name)}updateFromJSON(t){return function(e,s){const l=e.getWritable(),o=s.$;let c=o;for(const f of wx(l).flatKeys)f in s&&(c!==void 0&&c!==o||(c={...o}),c[f]=s[f]);return(l.__state||c)&&eM(e).updateFromJSON(c),l}(this,t)}static transform(){return null}remove(t){by(this,!0,t)}replace(t,e){en();let s=nt();s!==null&&(s=s.clone()),Lp(this,t);const l=this.getLatest(),o=this.__key,c=t.__key,f=t.getWritable(),h=this.getParentOrThrow().getWritable(),p=h.__size;ua(f);const y=l.getPreviousSibling(),m=l.getNextSibling(),_=l.__prev,S=l.__next,v=l.__parent;if(by(l,!1,!0),y===null?h.__first=c:y.getWritable().__next=c,f.__prev=_,m===null?h.__last=c:m.getWritable().__prev=c,f.__next=S,f.__parent=v,h.__size=p,e&&(Y(this)&&Y(f)||X(139),this.getChildren().forEach(A=>{f.append(A)})),Z(s)){Ze(s);const A=s.anchor,x=s.focus;A.key===o&&e1(A,f),x.key===o&&e1(x,f)}return as()===o&&Ke(c),f}insertAfter(t,e=!0){en(),Lp(this,t);const s=this.getWritable(),l=t.getWritable(),o=l.getParent(),c=nt();let f=!1,h=!1;if(o!==null){const S=t.getIndexWithinParent();if(ua(l),Z(c)){const v=o.__key,A=c.anchor,x=c.focus;f=A.type==="element"&&A.key===v&&A.offset===S+1,h=x.type==="element"&&x.key===v&&x.offset===S+1}}const p=this.getNextSibling(),y=this.getParentOrThrow().getWritable(),m=l.__key,_=s.__next;if(p===null?y.__last=m:p.getWritable().__prev=m,y.__size++,s.__next=m,l.__next=_,l.__prev=s.__key,l.__parent=s.__parent,e&&Z(c)){const S=this.getIndexWithinParent();vd(c,y,S+1);const v=y.__key;f&&c.anchor.set(v,S+2,"element"),h&&c.focus.set(v,S+2,"element")}return t}insertBefore(t,e=!0){en(),Lp(this,t);const s=this.getWritable(),l=t.getWritable(),o=l.__key;ua(l);const c=this.getPreviousSibling(),f=this.getParentOrThrow().getWritable(),h=s.__prev,p=this.getIndexWithinParent();c===null?f.__first=o:c.getWritable().__next=o,f.__size++,s.__prev=o,l.__prev=h,l.__next=s.__key,l.__parent=s.__parent;const y=nt();return e&&Z(y)&&vd(y,this.getParentOrThrow(),p),t}isParentRequired(){return!1}createParentElementNode(){return be()}selectStart(){return this.selectPrevious()}selectEnd(){return this.selectNext(0,0)}selectPrevious(t,e){en();const s=this.getPreviousSibling(),l=this.getParentOrThrow();if(s===null)return l.select(0,0);if(Y(s))return s.select();if(!W(s)){const o=s.getIndexWithinParent()+1;return l.select(o,o)}return s.select(t,e)}selectNext(t,e){en();const s=this.getNextSibling(),l=this.getParentOrThrow();if(s===null)return l.select();if(Y(s))return s.select(0,0);if(!W(s)){const o=s.getIndexWithinParent();return l.select(o,o)}return s.select(t,e)}markDirty(){this.getWritable()}reconcileObservedMutation(t,e){this.markDirty()}}class $u extends Kl{static getType(){return"linebreak"}static clone(t){return new $u(t.__key)}constructor(t){super(t)}getTextContent(){return`
`}createDOM(){return document.createElement("br")}updateDOM(){return!1}isInline(){return!0}static importDOM(){return{br:t=>function(e){const s=e.parentElement;if(s!==null&&Ad(s)){const l=s.firstChild;if(l===e||l.nextSibling===e&&hf(l)){const o=s.lastChild;if(o===e||o.previousSibling===e&&hf(o))return!0}}return!1}(t)||function(e){const s=e.parentElement;if(s!==null&&Ad(s)){const l=s.firstChild;if(l===e||l.nextSibling===e&&hf(l))return!1;const o=s.lastChild;if(o===e||o.previousSibling===e&&hf(o))return!0}return!1}(t)?null:{conversion:_M,priority:0}}}static importJSON(t){return yi().updateFromJSON(t)}}function _M(n){return{node:yi()}}function yi(){return Hn(new $u)}function os(n){return n instanceof $u}function hf(n){return Br(n)&&/^( |\t|\r?\n)+$/.test(n.textContent||"")}function Dp(n,t){return 16&t?"code":t&ym?"mark":32&t?"sub":64&t?"sup":null}function Mp(n,t){return 1&t?"strong":2&t?"em":"span"}function Qx(n,t,e,s,l){const o=s.classList;let c=Cl(l,"base");c!==void 0&&o.add(...c),c=Cl(l,"underlineStrikethrough");let f=!1;const h=t&hd&&t&dd;c!==void 0&&(e&hd&&e&dd?(f=!0,h||o.add(...c)):h&&o.remove(...c));for(const p in ha){const y=ha[p];if(c=Cl(l,p),c!==void 0)if(e&y){if(f&&(p==="underline"||p==="strikethrough")){t&y&&o.remove(...c);continue}t&y&&(!h||p!=="underline")&&p!=="strikethrough"||o.add(...c)}else t&y&&o.remove(...c)}}function Jx(n,t,e){const s=t.firstChild,l=e.isComposing(),o=n+(l?Ld:"");if(s==null)t.textContent=o;else{const c=s.nodeValue;if(c!==o)if(l||fa){const[f,h,p]=function(y,m){const _=y.length,S=m.length;let v=0,A=0;for(;v<_&&v<S&&y[v]===m[v];)v++;for(;A+v<_&&A+v<S&&y[_-A-1]===m[S-A-1];)A++;return[v,_-v-A,m.slice(v,S-A)]}(c,o);h!==0&&s.deleteData(f,h),s.insertData(f,p)}else s.nodeValue=o}}function JS(n,t,e,s,l,o){Jx(l,n,t);const c=o.theme.text;c!==void 0&&Qx(0,0,s,n,c)}function gf(n,t){const e=document.createElement(t);return e.appendChild(n),e}class Ts extends Kl{static getType(){return"text"}static clone(t){return new Ts(t.__text,t.__key)}afterCloneFrom(t){super.afterCloneFrom(t),this.__text=t.__text,this.__format=t.__format,this.__style=t.__style,this.__mode=t.__mode,this.__detail=t.__detail}constructor(t="",e){super(e),this.__text=t,this.__format=0,this.__style="",this.__mode=0,this.__detail=0}getFormat(){return this.getLatest().__format}getDetail(){return this.getLatest().__detail}getMode(){const t=this.getLatest();return P2[t.__mode]}getStyle(){return this.getLatest().__style}isToken(){return this.getLatest().__mode===1}isComposing(){return this.__key===as()}isSegmented(){return this.getLatest().__mode===2}isDirectionless(){return!!(1&this.getLatest().__detail)}isUnmergeable(){return!!(2&this.getLatest().__detail)}hasFormat(t){const e=ha[t];return!!(this.getFormat()&e)}isSimpleText(){return this.__type==="text"&&this.__mode===0}getTextContent(){return this.getLatest().__text}getFormatFlags(t,e){return wd(this.getLatest().__format,t,e)}canHaveFormat(){return!0}isInline(){return!0}createDOM(t,e){const s=this.__format,l=Dp(0,s),o=Mp(0,s),c=l===null?o:l,f=document.createElement(c);let h=f;this.hasFormat("code")&&f.setAttribute("spellcheck","false"),l!==null&&(h=document.createElement(o),f.appendChild(h)),JS(h,this,0,s,this.__text,t);const p=this.__style;return p!==""&&(f.style.cssText=p),f}updateDOM(t,e,s){const l=this.__text,o=t.__format,c=this.__format,f=Dp(0,o),h=Dp(0,c),p=Mp(0,o),y=Mp(0,c);if((f===null?p:f)!==(h===null?y:h))return!0;if(f===h&&p!==y){const A=e.firstChild;A==null&&X(48);const x=document.createElement(y);return JS(x,this,0,c,l,s),e.replaceChild(x,A),!1}let m=e;h!==null&&f!==null&&(m=e.firstChild,m==null&&X(49)),Jx(l,m,this);const _=s.theme.text;_!==void 0&&o!==c&&Qx(0,o,c,m,_);const S=t.__style,v=this.__style;return S!==v&&(e.style.cssText=v),!1}static importDOM(){return{"#text":()=>({conversion:TM,priority:0}),b:()=>({conversion:vM,priority:0}),code:()=>({conversion:dr,priority:0}),em:()=>({conversion:dr,priority:0}),i:()=>({conversion:dr,priority:0}),mark:()=>({conversion:dr,priority:0}),s:()=>({conversion:dr,priority:0}),span:()=>({conversion:bM,priority:0}),strong:()=>({conversion:dr,priority:0}),sub:()=>({conversion:dr,priority:0}),sup:()=>({conversion:dr,priority:0}),u:()=>({conversion:dr,priority:0})}}static importJSON(t){return Ee().updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setTextContent(t.text).setFormat(t.format).setDetail(t.detail).setMode(t.mode).setStyle(t.style)}exportDOM(t){let{element:e}=super.exportDOM(t);return Me(e)||X(132),e.style.whiteSpace="pre-wrap",this.hasFormat("lowercase")?e.style.textTransform="lowercase":this.hasFormat("uppercase")?e.style.textTransform="uppercase":this.hasFormat("capitalize")&&(e.style.textTransform="capitalize"),this.hasFormat("bold")&&(e=gf(e,"b")),this.hasFormat("italic")&&(e=gf(e,"i")),this.hasFormat("strikethrough")&&(e=gf(e,"s")),this.hasFormat("underline")&&(e=gf(e,"u")),{element:e}}exportJSON(){return{detail:this.getDetail(),format:this.getFormat(),mode:this.getMode(),style:this.getStyle(),text:this.getTextContent(),...super.exportJSON()}}selectionTransform(t,e){}setFormat(t){const e=this.getWritable();return e.__format=typeof t=="string"?ha[t]:t,e}setDetail(t){const e=this.getWritable();return e.__detail=typeof t=="string"?Y2[t]:t,e}setStyle(t){const e=this.getWritable();return e.__style=t,e}toggleFormat(t){const e=wd(this.getFormat(),t,null);return this.setFormat(e)}toggleDirectionless(){const t=this.getWritable();return t.__detail^=1,t}toggleUnmergeable(){const t=this.getWritable();return t.__detail^=2,t}setMode(t){const e=K2[t];if(this.__mode===e)return this;const s=this.getWritable();return s.__mode=e,s}setTextContent(t){if(this.__text===t)return this;const e=this.getWritable();return e.__text=t,e}select(t,e){en();let s=t,l=e;const o=nt(),c=this.getTextContent(),f=this.__key;if(typeof c=="string"){const h=c.length;s===void 0&&(s=h),l===void 0&&(l=h)}else s=0,l=0;if(!Z(o))return eA(f,s,f,l,"text","text");{const h=as();h!==o.anchor.key&&h!==o.focus.key||Ke(f),o.setTextNodeRange(this,s,this,l)}return o}selectStart(){return this.select(0,0)}selectEnd(){const t=this.getTextContentSize();return this.select(t,t)}spliceText(t,e,s,l){const o=this.getWritable(),c=o.__text,f=s.length;let h=t;h<0&&(h=f+h,h<0&&(h=0));const p=nt();if(l&&Z(p)){const m=t+f;p.setTextNodeRange(o,m,o,m)}const y=c.slice(0,h)+s+c.slice(h+e);return o.__text=y,o}canInsertTextBefore(){return!0}canInsertTextAfter(){return!0}splitText(...t){en();const e=this.getLatest(),s=e.getTextContent();if(s==="")return[];const l=e.__key,o=as(),c=s.length;t.sort((z,L)=>z-L),t.push(c);const f=[],h=t.length;for(let z=0,L=0;z<c&&L<=h;L++){const J=t[L];J>z&&(f.push(s.slice(z,J)),z=J)}const p=f.length;if(p===1)return[e];const y=f[0],m=e.getParent();let _;const S=e.getFormat(),v=e.getStyle(),A=e.__detail;let x=!1,C=null,w=null;const E=nt();if(Z(E)){const[z,L]=E.isBackward()?[E.focus,E.anchor]:[E.anchor,E.focus];z.type==="text"&&z.key===l&&(C=z),L.type==="text"&&L.key===l&&(w=L)}e.isSegmented()?(_=Ee(y),_.__format=S,_.__style=v,_.__detail=A,_.__state=jS(e,_),x=!0):_=e.setTextContent(y);const M=[_];for(let z=1;z<p;z++){const L=Ee(f[z]);L.__format=S,L.__style=v,L.__detail=A,L.__state=jS(e,L);const J=L.__key;o===l&&Ke(J),M.push(L)}const O=C?C.offset:null,D=w?w.offset:null;let I=0;for(const z of M){if(!C&&!w)break;const L=I+z.getTextContentSize();if(C!==null&&O!==null&&O<=L&&O>=I&&(C.set(z.getKey(),O-I,"text"),O<L&&(C=null)),w!==null&&D!==null&&D<=L&&D>=I){w.set(z.getKey(),D-I,"text");break}I=L}if(m!==null){(function(J){const rt=J.getPreviousSibling(),dt=J.getNextSibling();rt!==null&&xd(rt),dt!==null&&xd(dt)})(this);const z=m.getWritable(),L=this.getIndexWithinParent();x?(z.splice(L,0,M),this.remove()):z.splice(L,1,M),Z(E)&&vd(E,m,L,p-1)}return M}mergeWithSibling(t){const e=t===this.getPreviousSibling();e||t===this.getNextSibling()||X(50);const s=this.__key,l=t.__key,o=this.__text,c=o.length;as()===l&&Ke(s);const f=nt();if(Z(f)){const m=f.anchor,_=f.focus;m!==null&&m.key===l&&o1(m,e,s,t,c),_!==null&&_.key===l&&o1(_,e,s,t,c)}const h=t.__text,p=e?h+o:o+h;this.setTextContent(p);const y=this.getWritable();return t.remove(),y}isTextEntity(){return!1}}function bM(n){return{forChild:Nm(n.style),node:null}}function vM(n){const t=n,e=t.style.fontWeight==="normal";return{forChild:Nm(t.style,e?void 0:"bold"),node:null}}const WS=new WeakMap;function SM(n){if(!Me(n))return!1;if(n.nodeName==="PRE")return!0;const t=n.style.whiteSpace;return typeof t=="string"&&t.startsWith("pre")}function TM(n){const t=n;n.parentElement===null&&X(129);let e=t.textContent||"";if(function(s){let l,o=s.parentNode;const c=[s];for(;o!==null&&(l=WS.get(o))===void 0&&!SM(o);)c.push(o),o=o.parentNode;const f=l===void 0?o:l;for(let h=0;h<c.length;h++)WS.set(c[h],f);return f}(t)!==null){const s=e.split(/(\r?\n|\t)/),l=[],o=s.length;for(let c=0;c<o;c++){const f=s[c];f===`
`||f===`\r
`?l.push(yi()):f==="	"?l.push(Pl()):f!==""&&l.push(Ee(f))}return{node:l}}if(e=e.replace(/\r/g,"").replace(/[ \t\n]+/g," "),e==="")return{node:null};if(e[0]===" "){let s=t,l=!0;for(;s!==null&&(s=t1(s,!1))!==null;){const o=s.textContent||"";if(o.length>0){/[ \t\n]$/.test(o)&&(e=e.slice(1)),l=!1;break}}l&&(e=e.slice(1))}if(e[e.length-1]===" "){let s=t,l=!0;for(;s!==null&&(s=t1(s,!0))!==null;)if((s.textContent||"").replace(/^( |\t|\r?\n)+/,"").length>0){l=!1;break}l&&(e=e.slice(0,e.length-1))}return e===""?{node:null}:{node:Ee(e)}}function t1(n,t){let e=n;for(;;){let s;for(;(s=t?e.nextSibling:e.previousSibling)===null;){const o=e.parentElement;if(o===null)return null;e=o}if(e=s,Me(e)){const o=e.style.display;if(o===""&&!Oy(e)||o!==""&&!o.startsWith("inline"))return null}let l=e;for(;(l=t?e.firstChild:e.lastChild)!==null;)e=l;if(Br(e))return e;if(e.nodeName==="BR")return null}}const wM={code:"code",em:"italic",i:"italic",mark:"highlight",s:"strikethrough",strong:"bold",sub:"subscript",sup:"superscript",u:"underline"};function dr(n){const t=wM[n.nodeName.toLowerCase()];return t===void 0?{node:null}:{forChild:Nm(n.style,t),node:null}}function Ee(n=""){return Hn(new Ts(n))}function W(n){return n instanceof Ts}function Nm(n,t){const e=n.fontWeight,s=n.textDecoration.split(" "),l=e==="700"||e==="bold",o=s.includes("line-through"),c=n.fontStyle==="italic",f=s.includes("underline"),h=n.verticalAlign;return p=>(W(p)&&(l&&!p.hasFormat("bold")&&p.toggleFormat("bold"),o&&!p.hasFormat("strikethrough")&&p.toggleFormat("strikethrough"),c&&!p.hasFormat("italic")&&p.toggleFormat("italic"),f&&!p.hasFormat("underline")&&p.toggleFormat("underline"),h!=="sub"||p.hasFormat("subscript")||p.toggleFormat("subscript"),h!=="super"||p.hasFormat("superscript")||p.toggleFormat("superscript"),t&&!p.hasFormat(t)&&p.toggleFormat(t)),p)}class ju extends Ts{static getType(){return"tab"}static clone(t){return new ju(t.__key)}constructor(t){super("	",t),this.__detail=2}static importDOM(){return null}createDOM(t){const e=super.createDOM(t),s=Cl(t.theme,"tab");return s!==void 0&&e.classList.add(...s),e}static importJSON(t){return Pl().updateFromJSON(t)}setTextContent(t){return t!=="	"&&t!==""&&X(126),super.setTextContent("	")}spliceText(t,e,s,l){return s===""&&e===0||s==="	"&&e===1||X(286),this}setDetail(t){return t!==2&&X(127),this}setMode(t){return t!=="normal"&&X(128),this}canInsertTextBefore(){return!1}canInsertTextAfter(){return!1}}function Pl(){return Hn(new ju)}function $d(n){return n instanceof ju}class xM{constructor(t,e,s){this._selection=null,this.key=t,this.offset=e,this.type=s}is(t){return this.key===t.key&&this.offset===t.offset&&this.type===t.type}isBefore(t){return this.key===t.key?this.offset<t.offset:wA(si(Cr(this,"next")),si(Cr(t,"next")))<0}getNode(){const t=Ce(this.key);return t===null&&X(20),t}set(t,e,s,l){const o=this._selection,c=this.key;l&&this.key===t&&this.offset===e&&this.type===s||(this.key=t,this.offset=e,this.type=s,Vu()||(as()===c&&Ke(t),o!==null&&(o.setCachedNodes(null),o.dirty=!0)))}}function Gi(n,t,e){return new xM(n,t,e)}function Bp(n,t){let e=t.__key,s=n.offset,l="element";if(W(t)){l="text";const o=t.getTextContentSize();s>o&&(s=o)}else if(!Y(t)){const o=t.getNextSibling();if(W(o))e=o.__key,s=0,l="text";else{const c=t.getParent();c&&(e=c.__key,s=t.getIndexWithinParent()+1)}}n.set(e,s,l)}function e1(n,t){if(Y(t)){const e=t.getLastDescendant();Y(e)||W(e)?Bp(n,e):Bp(n,t)}else Bp(n,t)}class jd{constructor(t){this._cachedNodes=null,this._nodes=t,this.dirty=!1}getCachedNodes(){return this._cachedNodes}setCachedNodes(t){this._cachedNodes=t}is(t){if(!tn(t))return!1;const e=this._nodes,s=t._nodes;return e.size===s.size&&Array.from(e).every(l=>s.has(l))}isCollapsed(){return!1}isBackward(){return!1}getStartEndPoints(){return null}add(t){this.dirty=!0,this._nodes.add(t),this._cachedNodes=null}delete(t){this.dirty=!0,this._nodes.delete(t),this._cachedNodes=null}clear(){this.dirty=!0,this._nodes.clear(),this._cachedNodes=null}has(t){return this._nodes.has(t)}clone(){return new jd(new Set(this._nodes))}extract(){return this.getNodes()}insertRawText(t){}insertText(){}insertNodes(t){const e=this.getNodes(),s=e.length,l=e[s-1];let o;if(W(l))o=l.select();else{const c=l.getIndexWithinParent()+1;o=l.getParentOrThrow().select(c,c)}o.insertNodes(t);for(let c=0;c<s;c++)e[c].remove()}getNodes(){const t=this._cachedNodes;if(t!==null)return t;const e=this._nodes,s=[];for(const l of e){const o=Ce(l);o!==null&&s.push(o)}return Vu()||(this._cachedNodes=s),s}getTextContent(){const t=this.getNodes();let e="";for(let s=0;s<t.length;s++)e+=t[s].getTextContent();return e}deleteNodes(){const t=this.getNodes();if((nt()||Gl())===this&&t[0]){const e=Ge(t[0],"next");sB(_s(e,e))}for(const e of t)e.remove()}}function Z(n){return n instanceof Sa}class Sa{constructor(t,e,s,l){this.anchor=t,this.focus=e,t._selection=this,e._selection=this,this._cachedNodes=null,this.format=s,this.style=l,this.dirty=!1}getCachedNodes(){return this._cachedNodes}setCachedNodes(t){this._cachedNodes=t}is(t){return!!Z(t)&&this.anchor.is(t.anchor)&&this.focus.is(t.focus)&&this.format===t.format&&this.style===t.style}isCollapsed(){return this.anchor.is(this.focus)}getNodes(){const t=this._cachedNodes;if(t!==null)return t;const e=function(s){const l=[],[o,c]=s.getTextSlices();o&&l.push(o.caret.origin);const f=new Set,h=new Set;for(const p of s)if(Yi(p)){const{origin:y}=p;l.length===0?f.add(y):(h.add(y),l.push(y))}else{const{origin:y}=p;Y(y)&&h.has(y)||l.push(y)}if(c&&l.push(c.caret.origin),Vl(s.focus)&&Y(s.focus.origin)&&s.focus.getNodeAtCaret()===null)for(let p=_i(s.focus.origin,"previous");Yi(p)&&f.has(p.origin)&&!p.origin.isEmpty()&&p.origin.is(l[l.length-1]);p=Qm(p))f.delete(p.origin),l.pop();for(;l.length>1;){const p=l[l.length-1];if(!Y(p)||h.has(p)||p.isEmpty()||f.has(p))break;l.pop()}if(l.length===0&&s.isCollapsed()){const p=si(s.anchor),y=si(s.anchor.getFlipped()),m=S=>us(S)?S.origin:S.getNodeAtCaret(),_=m(p)||m(y)||(s.anchor.getNodeAtCaret()?p.origin:y.origin);l.push(_)}return l}(EA(N1(this),"next"));return Vu()||(this._cachedNodes=e),e}setTextNodeRange(t,e,s,l){this.anchor.set(t.__key,e,"text"),this.focus.set(s.__key,l,"text")}getTextContent(){const t=this.getNodes();if(t.length===0)return"";const e=t[0],s=t[t.length-1],l=this.anchor,o=this.focus,c=l.isBefore(o),[f,h]=vy(this);let p="",y=!0;for(let m=0;m<t.length;m++){const _=t[m];if(Y(_)&&!_.isInline())y||(p+=`
`),y=!_.isEmpty();else if(y=!1,W(_)){let S=_.getTextContent();_===e?_===s?l.type==="element"&&o.type==="element"&&o.offset!==l.offset||(S=f<h?S.slice(f,h):S.slice(h,f)):S=c?S.slice(f):S.slice(h):_===s&&(S=c?S.slice(0,h):S.slice(0,f)),p+=S}else!qt(_)&&!os(_)||_===s&&this.isCollapsed()||(p+=_.getTextContent())}return p}applyDOMRange(t){const e=ve(),s=e.getEditorState()._selection,l=tA(t.startContainer,t.startOffset,t.endContainer,t.endOffset,e,s);if(l===null)return;const[o,c]=l;this.anchor.set(o.key,o.offset,o.type,!0),this.focus.set(c.key,c.offset,c.type,!0),gd(this)}clone(){const t=this.anchor,e=this.focus;return new Sa(Gi(t.key,t.offset,t.type),Gi(e.key,e.offset,e.type),this.format,this.style)}toggleFormat(t){this.format=wd(this.format,t,null),this.dirty=!0}setFormat(t){this.format=t,this.dirty=!0}setStyle(t){this.style=t,this.dirty=!0}hasFormat(t){const e=ha[t];return!!(this.format&e)}insertRawText(t){const e=t.split(/(\r?\n|\t)/),s=[],l=e.length;for(let o=0;o<l;o++){const c=e[o];c===`
`||c===`\r
`?s.push(yi()):c==="	"?s.push(Pl()):s.push(Ee(c))}this.insertNodes(s)}insertText(t){const e=this.anchor,s=this.focus,l=this.format,o=this.style;let c=e,f=s;!this.isCollapsed()&&s.isBefore(e)&&(c=s,f=e),c.type==="element"&&function(x,C,w,E){const M=x.getNode(),O=M.getChildAtIndex(x.offset),D=Ee(),I=Pe(M)?be().append(D):D;D.setFormat(w),D.setStyle(E),O===null?M.append(I):O.insertBefore(I),x.is(C)&&C.set(D.__key,0,"text"),x.set(D.__key,0,"text")}(c,f,l,o),f.type==="element"&&_a(f,si(Cr(f,"next")));const h=c.offset;let p=f.offset;const y=this.getNodes(),m=y.length;let _=y[0];W(_)||X(26);const S=_.getTextContent().length,v=_.getParentOrThrow();let A=y[m-1];if(m===1&&f.type==="element"&&(p=S,f.set(c.key,p,"text")),this.isCollapsed()&&h===S&&(_r(_)||!_.canInsertTextAfter()||!v.canInsertTextAfter()&&_.getNextSibling()===null)){let x=_.getNextSibling();if(W(x)&&x.canInsertTextBefore()&&!_r(x)||(x=Ee(),x.setFormat(l),x.setStyle(o),v.canInsertTextAfter()?_.insertAfter(x):v.insertAfter(x)),x.select(0,0),_=x,t!=="")return void this.insertText(t)}else if(this.isCollapsed()&&h===0&&(_r(_)||!_.canInsertTextBefore()||!v.canInsertTextBefore()&&_.getPreviousSibling()===null)){let x=_.getPreviousSibling();if(W(x)&&!_r(x)||(x=Ee(),x.setFormat(l),v.canInsertTextBefore()?_.insertBefore(x):v.insertBefore(x)),x.select(),_=x,t!=="")return void this.insertText(t)}else if(_.isSegmented()&&h!==S){const x=Ee(_.getTextContent());x.setFormat(l),_.replace(x),_=x}else if(!this.isCollapsed()&&t!==""){const x=A.getParent();if(!v.canInsertTextBefore()||!v.canInsertTextAfter()||Y(x)&&(!x.canInsertTextBefore()||!x.canInsertTextAfter()))return this.insertText(""),Wx(this.anchor,this.focus,null),void this.insertText(t)}if(m===1){if(oa(_)){const E=Ee(t);return E.select(),void _.replace(E)}const x=_.getFormat(),C=_.getStyle();if(h!==p||x===l&&C===o){if($d(_)){const E=Ee(t);return E.setFormat(l),E.setStyle(o),E.select(),void _.replace(E)}}else{if(_.getTextContent()!==""){const E=Ee(t);if(E.setFormat(l),E.setStyle(o),E.select(),h===0)_.insertBefore(E,!1);else{const[M]=_.splitText(h);M.insertAfter(E,!1)}return void(E.isComposing()&&this.anchor.type==="text"&&(this.anchor.offset-=t.length))}_.setFormat(l),_.setStyle(o)}const w=p-h;_=_.spliceText(h,w,t,!0),_.getTextContent()===""?_.remove():this.anchor.type==="text"&&(_.isComposing()?this.anchor.offset-=t.length:(this.format=x,this.style=C))}else{const x=new Set([..._.getParentKeys(),...A.getParentKeys()]),C=Y(_)?_:_.getParentOrThrow();let w=Y(A)?A:A.getParentOrThrow(),E=A;if(!C.is(w)&&w.isInline())do E=w,w=w.getParentOrThrow();while(w.isInline());if(f.type==="text"&&(p!==0||A.getTextContent()==="")||f.type==="element"&&A.getIndexWithinParent()<p)if(W(A)&&!oa(A)&&p!==A.getTextContentSize()){if(A.isSegmented()){const z=Ee(A.getTextContent());A.replace(z),A=z}Pe(f.getNode())||f.type!=="text"||(A=A.spliceText(0,p,"")),x.add(A.__key)}else{const z=A.getParentOrThrow();z.canBeEmpty()||z.getChildrenSize()!==1?A.remove():z.remove()}else x.add(A.__key);const M=w.getChildren(),O=new Set(y),D=C.is(w),I=C.isInline()&&_.getNextSibling()===null?C:_;for(let z=M.length-1;z>=0;z--){const L=M[z];if(L.is(_)||Y(L)&&L.isParentOf(_))break;L.isAttached()&&(!O.has(L)||L.is(E)?D||I.insertAfter(L,!1):L.remove())}if(!D){let z=w,L=null;for(;z!==null;){const J=z.getChildren(),rt=J.length;(rt===0||J[rt-1].is(L))&&(x.delete(z.__key),L=z),z=z.getParent()}}if(oa(_))if(h===S)_.select();else{const z=Ee(t);z.select(),_.replace(z)}else _=_.spliceText(h,S-h,t,!0),_.getTextContent()===""?_.remove():_.isComposing()&&this.anchor.type==="text"&&(this.anchor.offset-=t.length);for(let z=1;z<m;z++){const L=y[z],J=L.__key;x.has(J)||L.remove()}}}removeText(){const t=nt()===this;Rf(this,aB(N1(this))),t&&nt()!==this&&Ze(this)}formatText(t,e=null){if(this.isCollapsed())return this.toggleFormat(t),void Ke(null);const s=this.getNodes(),l=[];for(const M of s)W(M)&&l.push(M);const o=M=>{s.forEach(O=>{if(Y(O)){const D=O.getFormatFlags(t,M);O.setTextFormat(D)}})},c=l.length;if(c===0)return this.toggleFormat(t),Ke(null),void o(e);const f=this.anchor,h=this.focus,p=this.isBackward(),y=p?h:f,m=p?f:h;let _=0,S=l[0],v=y.type==="element"?0:y.offset;if(y.type==="text"&&v===S.getTextContentSize()&&(_=1,S=l[1],v=0),S==null)return;const A=S.getFormatFlags(t,e);o(A);const x=c-1;let C=l[x];const w=m.type==="text"?m.offset:C.getTextContentSize();if(S.is(C)){if(v===w)return;if(_r(S)||v===0&&w===S.getTextContentSize())S.setFormat(A);else{const M=S.splitText(v,w),O=v===0?M[0]:M[1];O.setFormat(A),y.type==="text"&&y.set(O.__key,0,"text"),m.type==="text"&&m.set(O.__key,w-v,"text")}return void(this.format=A)}v===0||_r(S)||([,S]=S.splitText(v),v=0),S.setFormat(A);const E=C.getFormatFlags(t,A);w>0&&(w===C.getTextContentSize()||_r(C)||([C]=C.splitText(w)),C.setFormat(E));for(let M=_+1;M<x;M++){const O=l[M],D=O.getFormatFlags(t,E);O.setFormat(D)}y.type==="text"&&y.set(S.__key,v,"text"),m.type==="text"&&m.set(C.__key,w,"text"),this.format=A|E}insertNodes(t){if(t.length===0)return;if(this.isCollapsed()||this.removeText(),this.anchor.key==="root"){this.insertParagraph();const v=nt();return Z(v)||X(134),v.insertNodes(t)}const e=(this.isBackward()?this.focus:this.anchor).getNode(),s=kp(e,ri),l=t[t.length-1];if(Y(s)&&"__language"in s){if("__language"in t[0])this.insertText(t[0].getTextContent());else{const v=Rp(this);s.splice(v,0,t),l.selectEnd()}return}if(!t.some(v=>(Y(v)||qt(v))&&!v.isInline())){Y(s)||X(211,e.constructor.name,e.getType());const v=Rp(this);return s.splice(v,0,t),void l.selectEnd()}const o=function(v){const A=be();let x=null;for(let C=0;C<v.length;C++){const w=v[C],E=os(w);if(E||qt(w)&&w.isInline()||Y(w)&&w.isInline()||W(w)||w.isParentRequired()){if(x===null&&(x=w.createParentElementNode(),A.append(x),E))continue;x!==null&&x.append(w)}else A.append(w),x=null}return A}(t),c=o.getLastDescendant(),f=o.getChildren(),h=!Y(s)||!s.isEmpty()?this.insertParagraph():null,p=f[f.length-1];let y=f[0];var m;Y(m=y)&&ri(m)&&!m.isEmpty()&&Y(s)&&(!s.isEmpty()||s.canMergeWhenEmpty())&&(Y(s)||X(211,e.constructor.name,e.getType()),s.append(...y.getChildren()),y=f[1]),y&&(s===null&&X(212,e.constructor.name,e.getType()),function(v,A,x){const C=A.getParentOrThrow().getLastChild();let w=A;const E=[A];for(;w!==C;)w.getNextSibling()||X(140),w=w.getNextSibling(),E.push(w);let M=v;for(const O of E)M=M.insertAfter(O)}(s,y));const _=kp(c,ri);h&&Y(_)&&(h.canMergeWhenEmpty()||ri(p))&&(_.append(...h.getChildren()),h.remove()),Y(s)&&s.isEmpty()&&s.remove(),c.selectEnd();const S=Y(s)?s.getLastChild():null;os(S)&&_!==s&&S.remove()}insertParagraph(){if(this.anchor.key==="root"){const c=be();return ge().splice(this.anchor.offset,0,[c]),c.select(),c}const t=Rp(this),e=kp(this.anchor.getNode(),ri);Y(e)||X(213);const s=e.getChildAtIndex(t),l=s?[s,...s.getNextSiblings()]:[],o=e.insertNewAfter(this,!1);return o?(o.append(...l),o.selectStart(),o):null}insertLineBreak(t){const e=yi();if(this.insertNodes([e]),t){const s=e.getParentOrThrow(),l=e.getIndexWithinParent();s.select(l,l)}}extract(){const t=this.getNodes(),e=t.length,s=e-1,l=this.anchor,o=this.focus;let c=t[0],f=t[s];const[h,p]=vy(this);if(e===0)return[];if(e===1){if(W(c)&&!this.isCollapsed()){const m=h>p?p:h,_=h>p?h:p,S=c.splitText(m,_),v=m===0?S[0]:S[1];return v!=null?[v]:[]}return[c]}const y=l.isBefore(o);if(W(c)){const m=y?h:p;m===c.getTextContentSize()?t.shift():m!==0&&([,c]=c.splitText(m),t[0]=c)}if(W(f)){const m=f.getTextContent().length,_=y?p:h;_===0?t.pop():_!==m&&([f]=f.splitText(_),t[s]=f)}return t}modify(t,e,s){if(u1(this,t,e,s))return;const l=t==="move",o=ve(),c=mi(li(o));if(!c)return;const f=o._blockCursorElement,h=o._rootElement,p=this.focus.getNode();if(h===null||f===null||!Y(p)||p.isInline()||p.canBeEmpty()||Ay(f,o,h),this.dirty){let y=jl(o,this.anchor.key),m=jl(o,this.focus.key);this.anchor.type==="text"&&(y=zl(y)),this.focus.type==="text"&&(m=zl(m)),y&&m&&nA(c,y,this.anchor.offset,m,this.focus.offset)}if(function(y,m,_,S){y.modify(m,_,S)}(c,t,e?"backward":"forward",s),c.rangeCount>0){const y=c.getRangeAt(0),m=this.anchor.getNode(),_=Pe(m)?m:KM(m);if(this.applyDOMRange(y),this.dirty=!0,!l){const S=this.getNodes(),v=[];let A=!1;for(let x=0;x<S.length;x++){const C=S[x];xy(C,_)?v.push(C):A=!0}if(A&&v.length>0)if(e){const x=v[0];Y(x)?x.selectStart():x.getParentOrThrow().selectStart()}else{const x=v[v.length-1];Y(x)?x.selectEnd():x.getParentOrThrow().selectEnd()}c.anchorNode===y.startContainer&&c.anchorOffset===y.startOffset||function(x){const C=x.focus,w=x.anchor,E=w.key,M=w.offset,O=w.type;w.set(C.key,C.offset,C.type,!0),C.set(E,M,O,!0)}(this)}}s==="lineboundary"&&u1(this,t,e,s,"decorators")}forwardDeletion(t,e,s){if(!s&&(t.type==="element"&&Y(e)&&t.offset===e.getChildrenSize()||t.type==="text"&&t.offset===e.getTextContentSize())){const l=e.getParent(),o=e.getNextSibling()||(l===null?null:l.getNextSibling());if(Y(o)&&o.isShadowRoot())return!0}return!1}deleteCharacter(t){const e=this.isCollapsed();if(this.isCollapsed()){const s=this.anchor;let l=s.getNode();if(this.forwardDeletion(s,l,t))return;const o=Wm(Cr(s,t?"previous":"next"));if(o.getTextSlices().every(f=>f===null||f.distance===0)){let f={type:"initial"};for(const h of o.iterNodeCarets("shadowRoot"))if(Yi(h)){if(!h.origin.isInline()){if(h.origin.isShadowRoot()){if(f.type==="merge-block")break;if(Y(o.anchor.origin)&&o.anchor.origin.isEmpty()){const p=si(h);Rf(this,_s(p,p)),o.anchor.origin.remove()}return}f.type!=="merge-next-block"&&f.type!=="merge-block"||(f={block:f.block,caret:h,type:"merge-block"})}}else{if(f.type==="merge-block")break;if(Vl(h)){if(Y(h.origin)){if(h.origin.isInline()){if(!h.origin.isParentOf(o.anchor.origin))break}else f={block:h.origin,type:"merge-next-block"};continue}if(qt(h.origin)){if(!h.origin.isIsolated())if(f.type==="merge-next-block"&&(h.origin.isKeyboardSelectable()||!h.origin.isInline())&&Y(o.anchor.origin)&&o.anchor.origin.isEmpty()){o.anchor.origin.remove();const p=Cm();p.add(h.origin.getKey()),Ze(p)}else h.origin.remove();return}break}}if(f.type==="merge-block"){const{caret:h,block:p}=f;return Rf(this,_s(!h.origin.isEmpty()&&p.isEmpty()?t_(Ge(p,h.direction)):o.anchor,h)),this.removeText()}}const c=this.focus;if(this.modify("extend",t,"character"),this.isCollapsed()){if(t&&s.offset===0&&i1(this,s.getNode()))return}else{const f=c.type==="text"?c.getNode():null;if(l=s.type==="text"?s.getNode():null,f!==null&&f.isSegmented()){const h=c.offset,p=f.getTextContentSize();if(f.is(l)||t&&h!==p||!t&&h!==0)return void r1(f,t,h)}else if(l!==null&&l.isSegmented()){const h=s.offset,p=l.getTextContentSize();if(l.is(f)||t&&h!==0||!t&&h!==p)return void r1(l,t,h)}(function(h,p){const y=h.anchor,m=h.focus,_=y.getNode(),S=m.getNode();if(_===S&&y.type==="text"&&m.type==="text"){const v=y.offset,A=m.offset,x=v<A,C=x?v:A,w=x?A:v,E=w-1;C!==E&&function(M){return!(yA(M)||AM(M))}(_.getTextContent().slice(C,w))&&(p?m.set(m.key,E,m.type):y.set(y.key,E,y.type))}})(this,t)}}if(this.removeText(),t&&!e&&this.isCollapsed()&&this.anchor.type==="element"&&this.anchor.offset===0){const s=this.anchor.getNode();s.isEmpty()&&Pe(s.getParent())&&s.getPreviousSibling()===null&&i1(this,s)}}deleteLine(t){this.isCollapsed()&&this.modify("extend",t,"lineboundary"),this.isCollapsed()?this.deleteCharacter(t):this.removeText()}deleteWord(t){if(this.isCollapsed()){const e=this.anchor,s=e.getNode();if(this.forwardDeletion(e,s,t))return;this.modify("extend",t,"word")}this.removeText()}isBackward(){return this.focus.isBefore(this.anchor)}getStartEndPoints(){return[this.anchor,this.focus]}}function tn(n){return n instanceof jd}function n1(n){const t=n.offset;if(n.type==="text")return t;const e=n.getNode();return t===e.getChildrenSize()?e.getTextContent().length:0}function vy(n){const t=n.getStartEndPoints();if(t===null)return[0,0];const[e,s]=t;return e.type==="element"&&s.type==="element"&&e.key===s.key&&e.offset===s.offset?[0,0]:[n1(e),n1(s)]}function i1(n,t){for(let e=t;e;e=e.getParent()){if(Y(e)){if(e.collapseAtStart(n))return!0;if(un(e))break}if(e.getPreviousSibling())break}return!1}const AM=(()=>{try{const n=new RegExp("\\p{Emoji}","u"),t=n.test.bind(n);if(t("❤️")&&t("#️⃣")&&t("👍"))return t}catch{}return()=>!1})();function r1(n,t,e){const s=n,l=s.getTextContent().split(/(?=\s)/g),o=l.length;let c=0,f=0;for(let p=0;p<o;p++){const y=p===o-1;if(f=c,c+=l[p].length,t&&c===e||c>e||y){l.splice(p,1),y&&(f=void 0);break}}const h=l.join("").trim();h===""?s.remove():(s.setTextContent(h),s.select(f,f))}function s1(n,t,e,s){let l,o=t;if(Me(n)){let c=!1;const f=n.childNodes,h=f.length,p=s._blockCursorElement;o===h&&(c=!0,o=h-1);let y=f[o],m=!1;if(y===p)y=f[o+1],m=!0;else if(p!==null){const _=p.parentNode;n===_&&t>Array.prototype.indexOf.call(_.children,p)&&o--}if(l=bl(y),W(l))o=b1(l,c);else{let _=bl(n);if(_===null)return null;if(Y(_)){const S=s.getElementByKey(_.getKey());S===null&&X(214),[_,o]=_.getDOMSlot(S).resolveChildIndex(_,S,n,t),Y(_)||X(215),c&&o>=_.getChildrenSize()&&(o=Math.max(0,_.getChildrenSize()-1));let A=_.getChildAtIndex(o);if(Y(A)&&function(x,C,w){const E=x.getParent();return w===null||E===null||!E.canBeEmpty()||E!==w.getNode()}(A,0,e)){const x=c?A.getLastDescendant():A.getFirstDescendant();x===null?_=A:(A=x,_=Y(A)?A:A.getParentOrThrow()),o=0}W(A)?(l=A,_=null,o=b1(A,c)):A!==_&&c&&!m&&(Y(_)||X(216),o=Math.min(_.getChildrenSize(),o+1))}else{const S=_.getIndexWithinParent();o=t===0&&qt(_)&&bl(n)===_?S:S+1,_=_.getParentOrThrow()}if(Y(_))return Gi(_.__key,o,"element")}}else l=bl(n);return W(l)?Gi(l.__key,o,"text"):null}function a1(n,t,e){const s=n.offset,l=n.getNode();if(s===0){const o=l.getPreviousSibling(),c=l.getParent();if(t){if((e||!t)&&o===null&&Y(c)&&c.isInline()){const f=c.getPreviousSibling();W(f)&&n.set(f.__key,f.getTextContent().length,"text")}}else Y(o)&&!e&&o.isInline()?n.set(o.__key,o.getChildrenSize(),"element"):W(o)&&n.set(o.__key,o.getTextContent().length,"text")}else if(s===l.getTextContent().length){const o=l.getNextSibling(),c=l.getParent();if(t&&Y(o)&&o.isInline())n.set(o.__key,0,"element");else if((e||t)&&o===null&&Y(c)&&c.isInline()&&!c.canInsertTextAfter()){const f=c.getNextSibling();W(f)&&n.set(f.__key,0,"text")}}}function Wx(n,t,e){if(n.type==="text"&&t.type==="text"){const s=n.isBefore(t),l=n.is(t);a1(n,s,l),a1(t,!s,l),l&&t.set(n.key,n.offset,n.type);const o=ve();if(o.isComposing()&&o._compositionKey!==n.key&&Z(e)){const c=e.anchor,f=e.focus;n.set(c.key,c.offset,c.type,!0),t.set(f.key,f.offset,f.type,!0)}}}function tA(n,t,e,s,l,o){if(n===null||e===null||!qu(l,n,e))return null;const c=s1(n,t,Z(o)?o.anchor:null,l);if(c===null)return null;const f=s1(e,s,Z(o)?o.focus:null,l);if(f===null)return null;if(c.type==="element"&&f.type==="element"){const h=bl(n),p=bl(e);if(qt(h)&&qt(p))return null}return Wx(c,f,o),[c,f]}function Sy(n){return Y(n)&&!n.isInline()}function eA(n,t,e,s,l,o){const c=ws(),f=new Sa(Gi(n,t,l),Gi(e,s,o),0,"");return f.dirty=!0,c._selection=f,f}function Vd(){const n=Gi("root",0,"element"),t=Gi("root",0,"element");return new Sa(n,t,0,"")}function Cm(){return new jd(new Set)}function Dm(n,t,e,s){const l=e._window;if(l===null)return null;const o=s||l.event,c=o?o.type:void 0,f=c==="selectionchange",h=!ay&&(f||c==="beforeinput"||c==="compositionstart"||c==="compositionend"||c==="click"&&o&&o.detail===3||c==="drop"||c===void 0);let p,y,m,_;if(Z(n)&&!h)return n.clone();if(t===null)return null;if(p=t.anchorNode,y=t.focusNode,m=t.anchorOffset,_=t.focusOffset,f&&Z(n)&&!qu(e,p,y))return n.clone();const S=tA(p,m,y,_,e,n);if(S===null)return null;const[v,A]=S;return new Sa(v,A,Z(n)?n.format:0,Z(n)?n.style:"")}function nt(){return ws()._selection}function Gl(){return ve()._editorState._selection}function vd(n,t,e,s=1){const l=n.anchor,o=n.focus,c=l.getNode(),f=o.getNode();if(!t.is(c)&&!t.is(f))return;const h=t.__key;if(n.isCollapsed()){const p=l.offset;if(e<=p&&s>0||e<p&&s<0){const y=Math.max(0,p+s);l.set(h,y,"element"),o.set(h,y,"element"),l1(n)}}else{const p=n.isBackward(),y=p?o:l,m=y.getNode(),_=p?l:o,S=_.getNode();if(t.is(m)){const v=y.offset;(e<=v&&s>0||e<v&&s<0)&&y.set(h,Math.max(0,v+s),"element")}if(t.is(S)){const v=_.offset;(e<=v&&s>0||e<v&&s<0)&&_.set(h,Math.max(0,v+s),"element")}}l1(n)}function l1(n){const t=n.anchor,e=t.offset,s=n.focus,l=s.offset,o=t.getNode(),c=s.getNode();if(n.isCollapsed()){if(!Y(o))return;const f=o.getChildrenSize(),h=e>=f,p=h?o.getChildAtIndex(f-1):o.getChildAtIndex(e);if(W(p)){let y=0;h&&(y=p.getTextContentSize()),t.set(p.__key,y,"text"),s.set(p.__key,y,"text")}}else{if(Y(o)){const f=o.getChildrenSize(),h=e>=f,p=h?o.getChildAtIndex(f-1):o.getChildAtIndex(e);if(W(p)){let y=0;h&&(y=p.getTextContentSize()),t.set(p.__key,y,"text")}}if(Y(c)){const f=c.getChildrenSize(),h=l>=f,p=h?c.getChildAtIndex(f-1):c.getChildAtIndex(l);if(W(p)){let y=0;h&&(y=p.getTextContentSize()),s.set(p.__key,y,"text")}}}}function Sd(n,t,e,s,l){let o=null,c=0,f=null;s!==null?(o=s.__key,W(s)?(c=s.getTextContentSize(),f="text"):Y(s)&&(c=s.getChildrenSize(),f="element")):l!==null&&(o=l.__key,W(l)?f="text":Y(l)&&(f="element")),o!==null&&f!==null?n.set(o,c,f):(c=t.getIndexWithinParent(),c===-1&&(c=e.getChildrenSize()),n.set(e.__key,c,"element"))}function o1(n,t,e,s,l){n.type==="text"?n.set(e,n.offset+(t?0:l),"text"):n.offset>s.getIndexWithinParent()&&n.set(n.key,n.offset-1,"element")}function nA(n,t,e,s,l){try{n.setBaseAndExtent(t,e,s,l)}catch{}}function EM(n,t,e,s,l,o,c){const f=s.anchorNode,h=s.focusNode,p=s.anchorOffset,y=s.focusOffset,m=document.activeElement;if(l.has(oA)&&m!==o||m!==null&&Um(m))return;if(!Z(t))return void(n!==null&&qu(e,f,h)&&s.removeAllRanges());const _=t.anchor,S=t.focus,v=_.key,A=S.key,x=jl(e,v),C=jl(e,A),w=_.offset,E=S.offset,M=t.format,O=t.style,D=t.isCollapsed();let I=x,z=C,L=!1;if(_.type==="text"){I=zl(x);const ut=_.getNode();L=ut.getFormat()!==M||ut.getStyle()!==O}else Z(n)&&n.anchor.type==="text"&&(L=!0);var J,rt,dt,vt,mt;if(S.type==="text"&&(z=zl(C)),I!==null&&z!==null&&(D&&(n===null||L||Z(n)&&(n.format!==M||n.style!==O))&&(J=M,rt=O,dt=w,vt=v,mt=performance.now(),qx=[J,rt,dt,vt,mt]),p!==w||y!==E||f!==I||h!==z||s.type==="Range"&&D||(m!==null&&o.contains(m)||o.focus({preventScroll:!0}),_.type==="element"))){if(nA(s,I,w,z,E),!l.has(RM)&&t.isCollapsed()&&o!==null&&o===document.activeElement){const ut=Z(t)&&t.anchor.type==="element"?I.childNodes[w]||null:s.rangeCount>0?s.getRangeAt(0):null;if(ut!==null){let H;if(ut instanceof Text){const Q=document.createRange();Q.selectNode(ut),H=Q.getBoundingClientRect()}else H=ut.getBoundingClientRect();(function(Q,it,_t){const B=vA(_t),G=Ym(B);if(B===null||G===null)return;let{top:tt,bottom:et}=it,at=0,Nt=0,ot=_t;for(;ot!==null;){const Se=ot===B.body;if(Se)at=0,Nt=li(Q).innerHeight;else{const Xe=ot.getBoundingClientRect();at=Xe.top,Nt=Xe.bottom}let Vt=0;if(tt<at?Vt=-(at-tt):et>Nt&&(Vt=et-Nt),Vt!==0)if(Se)G.scrollBy(0,Vt);else{const Xe=ot.scrollTop;ot.scrollTop+=Vt;const Ti=ot.scrollTop-Xe;tt-=Ti,et-=Ti}if(Se)break;ot=Ku(ot)}})(e,H,o)}}my=!0}}function OM(n){let t=nt()||Gl();t===null&&(t=ge().selectEnd()),t.insertNodes(n)}function Rp(n){let t=n;n.isCollapsed()||t.removeText();const e=nt();Z(e)&&(t=e),Z(t)||X(161);const s=t.anchor;let l=s.getNode(),o=s.offset;for(;!ri(l);){const c=l;if([l,o]=NM(l,o),c.is(l))break}return o}function NM(n,t){const e=n.getParent();if(!e){const l=be();return ge().append(l),l.select(),[ge(),0]}if(W(n)){const l=n.splitText(t);if(l.length===0)return[e,n.getIndexWithinParent()];const o=t===0?0:1;return[e,l[0].getIndexWithinParent()+o]}if(!Y(n)||t===0)return[e,n.getIndexWithinParent()];const s=n.getChildAtIndex(t);if(s){const l=new Sa(Gi(n.__key,t,"element"),Gi(n.__key,t,"element"),0,""),o=n.insertNewAfter(l);o&&o.append(s,...s.getNextSiblings())}return[e,n.getIndexWithinParent()+1]}function u1(n,t,e,s,l="decorators-and-blocks"){if(t==="move"&&s==="character"&&!n.isCollapsed()){const[y,m]=e===n.isBackward()?[n.focus,n.anchor]:[n.anchor,n.focus];return m.set(y.key,y.offset,y.type),!0}const o=Cr(n.focus,e?"previous":"next"),c=s==="lineboundary",f=t==="move";let h=o,p=l==="decorators-and-blocks";if(!AA(h)){for(const y of h){p=!1;const{origin:m}=y;if(!qt(m)||m.isIsolated()||(h=y,!c||!m.isInline()))break}if(p)for(const y of Wm(o).iterNodeCarets(t==="extend"?"shadowRoot":"root")){if(Yi(y))y.origin.isInline()||(h=y);else{if(Y(y.origin))continue;qt(y.origin)&&!y.origin.isInline()&&(h=y)}break}}if(h===o)return!1;if(f&&!c&&qt(h.origin)&&h.origin.isKeyboardSelectable()){const y=Cm();return y.add(h.origin.getKey()),Ze(y),!0}return h=si(h),f&&_a(n.anchor,h),_a(n.focus,h),p||!c}let je=null,Ve=null,vn=!1,Fp=!1,Mf=0;const c1={characterData:!0,childList:!0,subtree:!0};function Vu(){return vn||je!==null&&je._readOnly}function en(){vn&&X(13)}function iA(){Mf>99&&X(14)}function ws(){return je===null&&X(195,rA()),je}function ve(){return Ve===null&&X(196,rA()),Ve}function rA(){let n=0;const t=new Set,e=qd.version;if(typeof window<"u")for(const l of document.querySelectorAll("[contenteditable]")){const o=Kd(l);if(zm(o))n++;else if(o){let c=String(o.constructor.version||"<0.17.1");c===e&&(c+=" (separately built, likely a bundler configuration issue)"),t.add(c)}}let s=` Detected on the page: ${n} compatible editor(s) with version ${e}`;return t.size&&(s+=` and incompatible editors with versions ${Array.from(t).join(", ")}`),s}function CM(){return Ve}function f1(n,t,e){const s=t.__type,l=cA(n,s);let o=e.get(s);o===void 0&&(o=Array.from(l.transforms),e.set(s,o));const c=o.length;for(let f=0;f<c&&(o[f](t),t.isAttached());f++);}function d1(n,t){return n!==void 0&&n.__key!==t&&n.isAttached()}function sA(n,t){if(!t)return;const e=n._updateTags;let s=t;Array.isArray(t)||(s=[t]);for(const l of s)e.add(l)}function DM(n){return Mm(n,ve()._nodes)}function Mm(n,t){const e=n.type,s=t.get(e);s===void 0&&X(17,e);const l=s.klass;n.type!==l.getType()&&X(18,l.name);const o=l.importJSON(n),c=n.children;if(Y(o)&&Array.isArray(c))for(let f=0;f<c.length;f++){const h=Mm(c[f],t);o.append(h)}return o}function h1(n,t,e){const s=je,l=vn,o=Ve;je=t,vn=!0,Ve=n;try{return e()}finally{je=s,vn=l,Ve=o}}function wr(n,t){const e=n._pendingEditorState,s=n._rootElement,l=n._headless||s===null;if(e===null)return;const o=n._editorState,c=o._selection,f=e._selection,h=n._dirtyType!==da,p=je,y=vn,m=Ve,_=n._updating,S=n._observer;let v=null;if(n._pendingEditorState=null,n._editorState=e,!l&&h&&S!==null){Ve=n,je=e,vn=!1,n._updating=!0;try{const D=n._dirtyType,I=n._dirtyElements,z=n._dirtyLeaves;S.disconnect(),v=rM(o,e,n,D,I,z)}catch(D){if(D instanceof Error&&n._onError(D),Fp)throw D;return uA(n,null,s,e),Sx(n),n._dirtyType=Ul,Fp=!0,wr(n,o),void(Fp=!1)}finally{S.observe(s,c1),n._updating=_,je=p,vn=y,Ve=m}}e._readOnly||(e._readOnly=!0);const A=n._dirtyLeaves,x=n._dirtyElements,C=n._normalizedNodes,w=n._updateTags,E=n._deferred;h&&(n._dirtyType=da,n._cloneNotNeeded.clear(),n._dirtyLeaves=new Set,n._dirtyElements=new Map,n._normalizedNodes=new Set,n._updateTags=new Set),function(D,I){const z=D._decorators;let L=D._pendingDecorators||z;const J=I._nodeMap;let rt;for(rt in L)J.has(rt)||(L===z&&(L=gA(D)),delete L[rt])}(n,e);const M=l?null:mi(li(n));if(n._editable&&M!==null&&(h||f===null||f.dirty)&&s!==null&&!w.has(FM)){Ve=n,je=e;try{if(S!==null&&S.disconnect(),h||f===null||f.dirty){const D=n._blockCursorElement;D!==null&&Ay(D,n,s),EM(c,f,n,M,w,s)}(function(D,I,z){let L=D._blockCursorElement;if(Z(z)&&z.isCollapsed()&&z.anchor.type==="element"&&I.contains(document.activeElement)){const J=z.anchor,rt=J.getNode(),dt=J.offset;let vt=!1,mt=null;if(dt===rt.getChildrenSize())Ip(rt.getChildAtIndex(dt-1))&&(vt=!0);else{const ut=rt.getChildAtIndex(dt);if(ut!==null&&Ip(ut)){const H=ut.getPreviousSibling();(H===null||Ip(H))&&(vt=!0,mt=D.getElementByKey(ut.__key))}}if(vt){const ut=D.getElementByKey(rt.__key);return L===null&&(D._blockCursorElement=L=function(H){const Q=H.theme,it=document.createElement("div");it.contentEditable="false",it.setAttribute("data-lexical-cursor","true");let _t=Q.blockCursor;if(_t!==void 0){if(typeof _t=="string"){const B=fd(_t);_t=Q.blockCursor=B}_t!==void 0&&it.classList.add(..._t)}return it}(D._config)),I.style.caretColor="transparent",void(mt===null?ut.appendChild(L):ut.insertBefore(L,mt))}}L!==null&&Ay(L,D,I)})(n,s,f)}finally{S!==null&&S.observe(s,c1),Ve=m,je=p}}v!==null&&function(D,I,z,L,J){const rt=Array.from(D._listeners.mutation),dt=rt.length;for(let vt=0;vt<dt;vt++){const[mt,ut]=rt[vt];for(const H of ut){const Q=I.get(H);Q!==void 0&&mt(Q,{dirtyLeaves:L,prevEditorState:J,updateTags:z})}}}(n,v,w,A,o),Z(f)||f===null||c!==null&&c.is(f)||n.dispatchCommand(xm,void 0);const O=n._pendingDecorators;O!==null&&(n._decorators=O,n._pendingDecorators=null,yu("decorator",n,!0,O)),function(D,I,z){const L=_1(I),J=_1(z);L!==J&&yu("textcontent",D,!0,J)}(n,t||o,e),yu("update",n,!0,{dirtyElements:x,dirtyLeaves:A,editorState:e,mutatedNodes:v,normalizedNodes:C,prevEditorState:t||o,tags:w}),function(D,I){if(D._deferred=[],I.length!==0){const z=D._updating;D._updating=!0;try{for(let L=0;L<I.length;L++)I[L]()}finally{D._updating=z}}}(n,E),function(D){const I=D._updates;if(I.length!==0){const z=I.shift();if(z){const[L,J]=z;Bm(D,L,J)}}}(n)}function yu(n,t,e,...s){const l=t._updating;t._updating=e;try{const o=Array.from(t._listeners[n]);for(let c=0;c<o.length;c++)o[c].apply(null,s)}finally{t._updating=l}}function g1(n,t){const e=n._updates;let s=t||!1;for(;e.length!==0;){const l=e.shift();if(l){const[o,c]=l;let f;if(c!==void 0){if(f=c.onUpdate,c.skipTransforms&&(s=!0),c.discrete){const h=n._pendingEditorState;h===null&&X(191),h._flushSync=!0}f&&n._deferred.push(f),sA(n,c.tag)}o()}}return s}function Bm(n,t,e){const s=n._updateTags;let l,o=!1,c=!1;e!==void 0&&(l=e.onUpdate,sA(n,e.tag),o=e.skipTransforms||!1,c=e.discrete||!1),l&&n._deferred.push(l);const f=n._editorState;let h=n._pendingEditorState,p=!1;(h===null||h._readOnly)&&(h=n._pendingEditorState=aA(h||f),p=!0),h._flushSync=c;const y=je,m=vn,_=Ve,S=n._updating;je=h,vn=!1,n._updating=!0,Ve=n;const v=n._headless||n.getRootElement()===null;Im(null);try{p&&(v?f._selection!==null&&(h._selection=f._selection.clone()):h._selection=function(w,E){const M=w.getEditorState()._selection,O=mi(li(w));return Z(M)||M==null?Dm(M,O,w,E):M.clone()}(n,e&&e.event||null));const x=n._compositionKey;t(),o=g1(n,o),function(w,E){const M=E.getEditorState()._selection,O=w._selection;if(Z(O)){const D=O.anchor,I=O.focus;let z;if(D.type==="text"&&(z=D.getNode(),z.selectionTransform(M,O)),I.type==="text"){const L=I.getNode();z!==L&&L.selectionTransform(M,O)}}}(h,n),n._dirtyType!==da&&(o?function(w,E){const M=E._dirtyLeaves,O=w._nodeMap;for(const D of M){const I=O.get(D);W(I)&&I.isAttached()&&I.isSimpleText()&&!I.isUnmergeable()&&YS(I)}}(h,n):function(w,E){const M=E._dirtyLeaves,O=E._dirtyElements,D=w._nodeMap,I=as(),z=new Map;let L=M,J=L.size,rt=O,dt=rt.size;for(;J>0||dt>0;){if(J>0){E._dirtyLeaves=new Set;for(const vt of L){const mt=D.get(vt);W(mt)&&mt.isAttached()&&mt.isSimpleText()&&!mt.isUnmergeable()&&YS(mt),mt!==void 0&&d1(mt,I)&&f1(E,mt,z),M.add(vt)}if(L=E._dirtyLeaves,J=L.size,J>0){Mf++;continue}}E._dirtyLeaves=new Set,E._dirtyElements=new Map,rt.delete("root")&&rt.set("root",!0);for(const vt of rt){const mt=vt[0],ut=vt[1];if(O.set(mt,ut),!ut)continue;const H=D.get(mt);H!==void 0&&d1(H,I)&&f1(E,H,z)}L=E._dirtyLeaves,J=L.size,rt=E._dirtyElements,dt=rt.size,Mf++}E._dirtyLeaves=M,E._dirtyElements=O}(h,n),g1(n),function(w,E,M,O){const D=w._nodeMap,I=E._nodeMap,z=[];for(const[L]of O){const J=I.get(L);J!==void 0&&(J.isAttached()||(Y(J)&&_x(J,L,D,I,z,O),D.has(L)||O.delete(L),z.push(L)))}for(const L of z)I.delete(L);for(const L of M){const J=I.get(L);J===void 0||J.isAttached()||(D.has(L)||M.delete(L),I.delete(L))}}(f,h,n._dirtyLeaves,n._dirtyElements)),x!==n._compositionKey&&(h._flushSync=!0);const C=h._selection;if(Z(C)){const w=h._nodeMap,E=C.anchor.key,M=C.focus.key;w.get(E)!==void 0&&w.get(M)!==void 0||X(19)}else tn(C)&&C._nodes.size===0&&(h._selection=null)}catch(x){return x instanceof Error&&n._onError(x),n._pendingEditorState=f,n._dirtyType=Ul,n._cloneNotNeeded.clear(),n._dirtyLeaves=new Set,n._dirtyElements.clear(),void wr(n)}finally{je=y,vn=m,Ve=_,n._updating=S,Mf=0}n._dirtyType!==da||n._deferred.length>0||function(x,C){const w=C.getEditorState()._selection,E=x._selection;if(E!==null){if(E.dirty||!E.is(w))return!0}else if(w!==null)return!0;return!1}(h,n)?h._flushSync?(h._flushSync=!1,wr(n)):p&&zM(()=>{wr(n)}):(h._flushSync=!1,p&&(s.clear(),n._deferred=[],n._pendingEditorState=null))}function In(n,t,e){Ve===n&&e===void 0?t():Bm(n,t,e)}class mu{constructor(t,e,s){this.element=t,this.before=e||null,this.after=s||null}withBefore(t){return new mu(this.element,t,this.after)}withAfter(t){return new mu(this.element,this.before,t)}withElement(t){return this.element===t?this:new mu(t,this.before,this.after)}insertChild(t){const e=this.before||this.getManagedLineBreak();return e!==null&&e.parentElement!==this.element&&X(222),this.element.insertBefore(t,e),this}removeChild(t){return t.parentElement!==this.element&&X(223),this.element.removeChild(t),this}replaceChild(t,e){return e.parentElement!==this.element&&X(224),this.element.replaceChild(t,e),this}getFirstChild(){const t=this.after?this.after.nextSibling:this.element.firstChild;return t===this.before||t===this.getManagedLineBreak()?null:t}getManagedLineBreak(){return this.element.__lexicalLineBreak||null}setManagedLineBreak(t){if(t===null)this.removeManagedLineBreak();else{const e=t==="decorator"&&(kl||Au);this.insertManagedLineBreak(e)}}removeManagedLineBreak(){const t=this.getManagedLineBreak();if(t){const e=this.element,s=t.nodeName==="IMG"?t.nextSibling:null;s&&e.removeChild(s),e.removeChild(t),e.__lexicalLineBreak=void 0}}insertManagedLineBreak(t){const e=this.getManagedLineBreak();if(e){if(t===(e.nodeName==="IMG"))return;this.removeManagedLineBreak()}const s=this.element,l=this.before,o=document.createElement("br");if(s.insertBefore(o,l),t){const c=document.createElement("img");c.setAttribute("data-lexical-linebreak","true"),c.style.cssText="display: inline !important; border: 0px !important; margin: 0px !important;",c.alt="",s.insertBefore(c,o),s.__lexicalLineBreak=c}else s.__lexicalLineBreak=o}getFirstChildOffset(){let t=0;for(let e=this.after;e!==null;e=e.previousSibling)t++;return t}resolveChildIndex(t,e,s,l){if(s===this.element){const h=this.getFirstChildOffset();return[t,Math.min(h+t.getChildrenSize(),Math.max(h,l))]}const o=p1(e,s);o.push(l);const c=p1(e,this.element);let f=t.getIndexWithinParent();for(let h=0;h<c.length;h++){const p=o[h],y=c[h];if(p===void 0||p<y)break;if(p>y){f+=1;break}}return[t.getParentOrThrow(),f]}}function p1(n,t){const e=[];let s=t;for(;s!==n&&s!==null;s=s.parentNode){let l=0;for(let o=s.previousSibling;o!==null;o=o.previousSibling)l++;e.push(l)}return s!==n&&X(225),e.reverse()}class $n extends Kl{constructor(t){super(t),this.__first=null,this.__last=null,this.__size=0,this.__format=0,this.__style="",this.__indent=0,this.__dir=null,this.__textFormat=0,this.__textStyle=""}afterCloneFrom(t){super.afterCloneFrom(t),this.__key===t.__key&&(this.__first=t.__first,this.__last=t.__last,this.__size=t.__size),this.__indent=t.__indent,this.__format=t.__format,this.__style=t.__style,this.__dir=t.__dir,this.__textFormat=t.__textFormat,this.__textStyle=t.__textStyle}getFormat(){return this.getLatest().__format}getFormatType(){const t=this.getFormat();return q2[t]||""}getStyle(){return this.getLatest().__style}getIndent(){return this.getLatest().__indent}getChildren(){const t=[];let e=this.getFirstChild();for(;e!==null;)t.push(e),e=e.getNextSibling();return t}getChildrenKeys(){const t=[];let e=this.getFirstChild();for(;e!==null;)t.push(e.__key),e=e.getNextSibling();return t}getChildrenSize(){return this.getLatest().__size}isEmpty(){return this.getChildrenSize()===0}isDirty(){const t=ve()._dirtyElements;return t!==null&&t.has(this.__key)}isLastChild(){const t=this.getLatest(),e=this.getParentOrThrow().getLastChild();return e!==null&&e.is(t)}getAllTextNodes(){const t=[];let e=this.getFirstChild();for(;e!==null;){if(W(e)&&t.push(e),Y(e)){const s=e.getAllTextNodes();t.push(...s)}e=e.getNextSibling()}return t}getFirstDescendant(){let t=this.getFirstChild();for(;Y(t);){const e=t.getFirstChild();if(e===null)break;t=e}return t}getLastDescendant(){let t=this.getLastChild();for(;Y(t);){const e=t.getLastChild();if(e===null)break;t=e}return t}getDescendantByIndex(t){const e=this.getChildren(),s=e.length;if(t>=s){const o=e[s-1];return Y(o)&&o.getLastDescendant()||o||null}const l=e[t];return Y(l)&&l.getFirstDescendant()||l||null}getFirstChild(){const t=this.getLatest().__first;return t===null?null:Ce(t)}getFirstChildOrThrow(){const t=this.getFirstChild();return t===null&&X(45,this.__key),t}getLastChild(){const t=this.getLatest().__last;return t===null?null:Ce(t)}getLastChildOrThrow(){const t=this.getLastChild();return t===null&&X(96,this.__key),t}getChildAtIndex(t){const e=this.getChildrenSize();let s,l;if(t<e/2){for(s=this.getFirstChild(),l=0;s!==null&&l<=t;){if(l===t)return s;s=s.getNextSibling(),l++}return null}for(s=this.getLastChild(),l=e-1;s!==null&&l>=t;){if(l===t)return s;s=s.getPreviousSibling(),l--}return null}getTextContent(){let t="";const e=this.getChildren(),s=e.length;for(let l=0;l<s;l++){const o=e[l];t+=o.getTextContent(),Y(o)&&l!==s-1&&!o.isInline()&&(t+=Nr)}return t}getTextContentSize(){let t=0;const e=this.getChildren(),s=e.length;for(let l=0;l<s;l++){const o=e[l];t+=o.getTextContentSize(),Y(o)&&l!==s-1&&!o.isInline()&&(t+=Nr.length)}return t}getDirection(){return this.getLatest().__dir}getTextFormat(){return this.getLatest().__textFormat}hasFormat(t){if(t!==""){const e=IS[t];return!!(this.getFormat()&e)}return!1}hasTextFormat(t){const e=ha[t];return!!(this.getTextFormat()&e)}getFormatFlags(t,e){return wd(this.getLatest().__textFormat,t,e)}getTextStyle(){return this.getLatest().__textStyle}select(t,e){en();const s=nt();let l=t,o=e;const c=this.getChildrenSize();if(!this.canBeEmpty()){if(t===0&&e===0){const h=this.getFirstChild();if(W(h)||Y(h))return h.select(0,0)}else if(!(t!==void 0&&t!==c||e!==void 0&&e!==c)){const h=this.getLastChild();if(W(h)||Y(h))return h.select()}}l===void 0&&(l=c),o===void 0&&(o=c);const f=this.__key;return Z(s)?(s.anchor.set(f,l,"element"),s.focus.set(f,o,"element"),s.dirty=!0,s):eA(f,l,f,o,"element","element")}selectStart(){const t=this.getFirstDescendant();return t?t.selectStart():this.select()}selectEnd(){const t=this.getLastDescendant();return t?t.selectEnd():this.select()}clear(){const t=this.getWritable();return this.getChildren().forEach(e=>e.remove()),t}append(...t){return this.splice(this.getChildrenSize(),0,t)}setDirection(t){const e=this.getWritable();return e.__dir=t,e}setFormat(t){return this.getWritable().__format=t!==""?IS[t]:0,this}setStyle(t){return this.getWritable().__style=t||"",this}setTextFormat(t){const e=this.getWritable();return e.__textFormat=t,e}setTextStyle(t){const e=this.getWritable();return e.__textStyle=t,e}setIndent(t){return this.getWritable().__indent=t,this}splice(t,e,s){const l=s.length,o=this.getChildrenSize(),c=this.getWritable();t+e<=o||X(226,String(t),String(e),String(o));const f=c.__key,h=[],p=[],y=this.getChildAtIndex(t+e);let m=null,_=o-e+l;if(t!==0)if(t===o)m=this.getLastChild();else{const v=this.getChildAtIndex(t);v!==null&&(m=v.getPreviousSibling())}if(e>0){let v=m===null?this.getFirstChild():m.getNextSibling();for(let A=0;A<e;A++){v===null&&X(100);const x=v.getNextSibling(),C=v.__key;ua(v.getWritable()),p.push(C),v=x}}let S=m;for(let v=0;v<l;v++){const A=s[v];S!==null&&A.is(S)&&(m=S=S.getPreviousSibling());const x=A.getWritable();x.__parent===f&&_--,ua(x);const C=A.__key;if(S===null)c.__first=C,x.__prev=null;else{const w=S.getWritable();w.__next=C,x.__prev=w.__key}A.__key===f&&X(76),x.__parent=f,h.push(C),S=A}if(t+e===o)S!==null&&(S.getWritable().__next=null,c.__last=S.__key);else if(y!==null){const v=y.getWritable();if(S!==null){const A=S.getWritable();v.__prev=S.__key,A.__next=y.__key}else v.__prev=null}if(c.__size=_,p.length){const v=nt();if(Z(v)){const A=new Set(p),x=new Set(h),{anchor:C,focus:w}=v;y1(C,A,x)&&Sd(C,C.getNode(),this,m,y),y1(w,A,x)&&Sd(w,w.getNode(),this,m,y),_!==0||this.canBeEmpty()||un(this)||this.remove()}}return c}getDOMSlot(t){return new mu(t)}exportDOM(t){const{element:e}=super.exportDOM(t);if(Me(e)){const s=this.getIndent();s>0&&(e.style.paddingInlineStart=40*s+"px");const l=this.getDirection();l&&(e.dir=l)}return{element:e}}exportJSON(){const t={children:[],direction:this.getDirection(),format:this.getFormatType(),indent:this.getIndent(),...super.exportJSON()},e=this.getTextFormat(),s=this.getTextStyle();return e!==0&&(t.textFormat=e),s!==""&&(t.textStyle=s),t}updateFromJSON(t){return super.updateFromJSON(t).setFormat(t.format).setIndent(t.indent).setDirection(t.direction).setTextFormat(t.textFormat||0).setTextStyle(t.textStyle||"")}insertNewAfter(t,e){return null}canIndent(){return!0}collapseAtStart(t){return!1}excludeFromCopy(t){return!1}canReplaceWith(t){return!0}canInsertAfter(t){return!0}canBeEmpty(){return!0}canInsertTextBefore(){return!0}canInsertTextAfter(){return!0}isInline(){return!1}isShadowRoot(){return!1}canMergeWith(t){return!1}extractWithChild(t,e,s){return!1}canMergeWhenEmpty(){return!1}reconcileObservedMutation(t,e){const s=this.getDOMSlot(t);let l=s.getFirstChild();for(let o=this.getFirstChild();o;o=o.getNextSibling()){const c=e.getElementByKey(o.getKey());c!==null&&(l==null?(s.insertChild(c),l=c):l!==c&&s.replaceChild(c,l),l=l.nextSibling)}}}function Y(n){return n instanceof $n}function y1(n,t,e){let s=n.getNode();for(;s;){const l=s.__key;if(t.has(l)&&!e.has(l))return!0;s=s.getParent()}return!1}class Rm extends Kl{decorate(t,e){X(47)}isIsolated(){return!1}isInline(){return!0}isKeyboardSelectable(){return!0}}function qt(n){return n instanceof Rm}class Hu extends $n{static getType(){return"root"}static clone(){return new Hu}constructor(){super("root"),this.__cachedText=null}getTopLevelElementOrThrow(){X(51)}getTextContent(){const t=this.__cachedText;return!Vu()&&ve()._dirtyType!==da||t===null?super.getTextContent():t}remove(){X(52)}replace(t){X(53)}insertBefore(t){X(54)}insertAfter(t){X(55)}updateDOM(t,e){return!1}splice(t,e,s){for(const l of s)Y(l)||qt(l)||X(282);return super.splice(t,e,s)}static importJSON(t){return ge().updateFromJSON(t)}collapseAtStart(){return!0}}function Pe(n){return n instanceof Hu}function aA(n){return new Hd(new Map(n._nodeMap))}function Fm(){return new Hd(new Map([["root",new Hu]]))}function lA(n){const t=n.exportJSON(),e=n.constructor;if(t.type!==e.getType()&&X(130,e.name),Y(n)){const s=t.children;Array.isArray(s)||X(59,e.name);const l=n.getChildren();for(let o=0;o<l.length;o++){const c=lA(l[o]);s.push(c)}}return t}class Hd{constructor(t,e){this._nodeMap=t,this._selection=e||null,this._flushSync=!1,this._readOnly=!1}isEmpty(){return this._nodeMap.size===1&&this._selection===null}read(t,e){return h1(e&&e.editor||null,this,t)}clone(t){const e=new Hd(this._nodeMap,t===void 0?this._selection:t);return e._readOnly=!0,e}toJSON(){return h1(null,this,()=>({root:lA(ge())}))}}const Td="historic",MM="history-push",Nl="history-merge",BM="paste",oA="collaboration",RM="skip-scroll-into-view",FM="skip-dom-selection";class Lm extends $n{static getType(){return"artificial"}createDOM(t){return document.createElement("div")}}class Yu extends $n{static getType(){return"paragraph"}static clone(t){return new Yu(t.__key)}createDOM(t){const e=document.createElement("p"),s=Cl(t.theme,"paragraph");return s!==void 0&&e.classList.add(...s),e}updateDOM(t,e,s){return!1}static importDOM(){return{p:t=>({conversion:LM,priority:0})}}exportDOM(t){const{element:e}=super.exportDOM(t);if(Me(e)){this.isEmpty()&&e.append(document.createElement("br"));const s=this.getFormatType();s&&(e.style.textAlign=s)}return{element:e}}static importJSON(t){return be().updateFromJSON(t)}exportJSON(){return{...super.exportJSON(),textFormat:this.getTextFormat(),textStyle:this.getTextStyle()}}insertNewAfter(t,e){const s=be();s.setTextFormat(t.format),s.setTextStyle(t.style);const l=this.getDirection();return s.setDirection(l),s.setFormat(this.getFormatType()),s.setStyle(this.getStyle()),this.insertAfter(s,e),s}collapseAtStart(){const t=this.getChildren();if(t.length===0||W(t[0])&&t[0].getTextContent().trim()===""){if(this.getNextSibling()!==null)return this.selectNext(),this.remove(),!0;if(this.getPreviousSibling()!==null)return this.selectPrevious(),this.remove(),!0}return!1}}function LM(n){const t=be();return n.style&&(t.setFormat(n.style.textAlign),Pm(n,t)),{node:t}}function be(){return Hn(new Yu)}function Yd(n){return n instanceof Yu}const Yt=0,ml=1,IM=4;function uA(n,t,e,s){const l=n._keyToDOMMap;l.clear(),n._editorState=Fm(),n._pendingEditorState=s,n._compositionKey=null,n._dirtyType=da,n._cloneNotNeeded.clear(),n._dirtyLeaves=new Set,n._dirtyElements.clear(),n._normalizedNodes=new Set,n._updateTags=new Set,n._updates=[],n._blockCursorElement=null;const o=n._observer;o!==null&&(o.disconnect(),n._observer=null),t!==null&&(t.textContent=""),e!==null&&(e.textContent="",l.set("root",e))}function kM(n){const t=n||{},e=CM(),s=t.theme||{},l=n===void 0?e:t.parentEditor||null,o=t.disableEvents||!1,c=Fm(),f=t.namespace||(l!==null?l._config.namespace:mA()),h=t.editorState,p=[Hu,Ts,$u,ju,Yu,Lm,...t.nodes||[]],{onError:y,html:m}=t,_=t.editable===void 0||t.editable;let S;if(n===void 0&&e!==null)S=e._nodes;else{S=new Map;for(let A=0;A<p.length;A++){let x=p[A],C=null,w=null;if(typeof x!="function"){const I=x;x=I.replace,C=I.with,w=I.withKlass||null}const{ownNodeConfig:E}=Gm(x),M=x.getType(),O=x.transform(),D=new Set;E&&E.$transform&&D.add(E.$transform),O!==null&&D.add(O),S.set(M,{exportDOM:m&&m.export?m.export.get(x):void 0,klass:x,replace:C,replaceWithKlass:w,sharedNodeState:W2(p[A]),transforms:D})}}const v=new qd(c,l,S,{disableEvents:o,namespace:f,theme:s},y||console.error,function(A,x){const C=new Map,w=new Set,E=M=>{Object.keys(M).forEach(O=>{let D=C.get(O);D===void 0&&(D=[],C.set(O,D)),D.push(M[O])})};return A.forEach(M=>{const O=M.klass.importDOM;if(O==null||w.has(O))return;w.add(O);const D=O.call(M.klass);D!==null&&E(D)}),x&&E(x),C}(S,m?m.import:void 0),_,n);return h!==void 0&&(v._pendingEditorState=h,v._dirtyType=Ul),v}class qd{constructor(t,e,s,l,o,c,f,h){this._createEditorArgs=h,this._parentEditor=e,this._rootElement=null,this._editorState=t,this._pendingEditorState=null,this._compositionKey=null,this._deferred=[],this._keyToDOMMap=new Map,this._updates=[],this._updating=!1,this._listeners={decorator:new Set,editable:new Set,mutation:new Map,root:new Set,textcontent:new Set,update:new Set},this._commands=new Map,this._config=l,this._nodes=s,this._decorators={},this._pendingDecorators=null,this._dirtyType=da,this._cloneNotNeeded=new Set,this._dirtyLeaves=new Set,this._dirtyElements=new Map,this._normalizedNodes=new Set,this._updateTags=new Set,this._observer=null,this._key=mA(),this._onError=o,this._htmlConversions=c,this._editable=f,this._headless=e!==null&&e._headless,this._window=null,this._blockCursorElement=null}isComposing(){return this._compositionKey!=null}registerUpdateListener(t){const e=this._listeners.update;return e.add(t),()=>{e.delete(t)}}registerEditableListener(t){const e=this._listeners.editable;return e.add(t),()=>{e.delete(t)}}registerDecoratorListener(t){const e=this._listeners.decorator;return e.add(t),()=>{e.delete(t)}}registerTextContentListener(t){const e=this._listeners.textcontent;return e.add(t),()=>{e.delete(t)}}registerRootListener(t){const e=this._listeners.root;return t(this._rootElement,null),e.add(t),()=>{t(null,this._rootElement),e.delete(t)}}registerCommand(t,e,s){s===void 0&&X(35);const l=this._commands;l.has(t)||l.set(t,[new Set,new Set,new Set,new Set,new Set]);const o=l.get(t);o===void 0&&X(36,String(t));const c=o[s];return c.add(e),()=>{c.delete(e),o.every(f=>f.size===0)&&l.delete(t)}}registerMutationListener(t,e,s){const l=this.resolveRegisteredNodeAfterReplacements(this.getRegisteredNode(t)).klass,o=this._listeners.mutation;let c=o.get(e);c===void 0&&(c=new Set,o.set(e,c)),c.add(l);const f=s&&s.skipInitialization;return f!==void 0&&f||this.initializeMutationListener(e,l),()=>{c.delete(l),c.size===0&&o.delete(e)}}getRegisteredNode(t){const e=this._nodes.get(t.getType());return e===void 0&&X(37,t.name),e}resolveRegisteredNodeAfterReplacements(t){for(;t.replaceWithKlass;)t=this.getRegisteredNode(t.replaceWithKlass);return t}initializeMutationListener(t,e){const s=this._editorState,l=A1(s).get(e.getType());if(!l)return;const o=new Map;for(const c of l.keys())o.set(c,"created");o.size>0&&t(o,{dirtyLeaves:new Set,prevEditorState:s,updateTags:new Set(["registerMutationListener"])})}registerNodeTransformToKlass(t,e){const s=this.getRegisteredNode(t);return s.transforms.add(e),s}registerNodeTransform(t,e){const s=this.registerNodeTransformToKlass(t,e),l=[s],o=s.replaceWithKlass;if(o!=null){const c=this.registerNodeTransformToKlass(o,e);l.push(c)}return function(c,f){const h=A1(c.getEditorState()),p=[];for(const y of f){const m=h.get(y);m&&p.push(m)}p.length!==0&&c.update(()=>{for(const y of p)for(const m of y.keys()){const _=Ce(m);_&&_.markDirty()}},c._pendingEditorState===null?{tag:Nl}:void 0)}(this,l.map(c=>c.klass.getType())),()=>{l.forEach(c=>c.transforms.delete(e))}}hasNode(t){return this._nodes.has(t.getType())}hasNodes(t){return t.every(this.hasNode.bind(this))}dispatchCommand(t,e){return st(this,t,e)}getDecorators(){return this._decorators}getRootElement(){return this._rootElement}getKey(){return this._key}setRootElement(t){const e=this._rootElement;if(t!==e){const s=Cl(this._config.theme,"root"),l=this._pendingEditorState||this._editorState;if(this._rootElement=t,uA(this,e,t,l),e!==null&&(this._config.disableEvents||mM(e),s!=null&&e.classList.remove(...s)),t!==null){const o=Ym(t),c=t.style;c.userSelect="text",c.whiteSpace="pre-wrap",c.wordBreak="break-word",t.setAttribute("data-lexical-editor","true"),this._window=o,this._dirtyType=Ul,Sx(this),this._updateTags.add(Nl),wr(this),this._config.disableEvents||function(f,h){const p=f.ownerDocument,y=bd.get(p);(y===void 0||y<1)&&p.addEventListener("selectionchange",Xx),bd.set(p,(y||0)+1),f.__lexicalEditor=h;const m=Zx(f);for(let _=0;_<yy.length;_++){const[S,v]=yy[_],A=typeof v=="function"?x=>{QS(x)||(XS(x),(h.isEditable()||S==="click")&&v(x,h))}:x=>{if(QS(x))return;XS(x);const C=h.isEditable();switch(S){case"cut":return C&&st(h,Om,x);case"copy":return st(h,zd,x);case"paste":return C&&st(h,Em,x);case"dragstart":return C&&st(h,$x,x);case"dragover":return C&&st(h,jx,x);case"dragend":return C&&st(h,dM,x);case"focus":return C&&st(h,gM,x);case"blur":return C&&st(h,pM,x);case"drop":return C&&st(h,zx,x)}};f.addEventListener(S,A),m.push(()=>{f.removeEventListener(S,A)})}}(t,this),s!=null&&t.classList.add(...s)}else this._window=null,this._updateTags.add(Nl),wr(this);yu("root",this,!1,t,e)}}getElementByKey(t){return this._keyToDOMMap.get(t)||null}getEditorState(){return this._editorState}setEditorState(t,e){t.isEmpty()&&X(38);let s=t;s._readOnly&&(s=aA(t),s._selection=t._selection?t._selection.clone():null),vx(this);const l=this._pendingEditorState,o=this._updateTags,c=e!==void 0?e.tag:null;l===null||l.isEmpty()||(c!=null&&o.add(c),wr(this)),this._pendingEditorState=s,this._dirtyType=Ul,this._dirtyElements.set("root",!1),this._compositionKey=null,c!=null&&o.add(c),this._updating||wr(this)}parseEditorState(t,e){return function(s,l,o){const c=Fm(),f=je,h=vn,p=Ve,y=l._dirtyElements,m=l._dirtyLeaves,_=l._cloneNotNeeded,S=l._dirtyType;l._dirtyElements=new Map,l._dirtyLeaves=new Set,l._cloneNotNeeded=new Set,l._dirtyType=0,je=c,vn=!1,Ve=l,Im(null);try{const v=l._nodes;Mm(s.root,v),o&&o(),c._readOnly=!0}catch(v){v instanceof Error&&l._onError(v)}finally{l._dirtyElements=y,l._dirtyLeaves=m,l._cloneNotNeeded=_,l._dirtyType=S,je=f,vn=h,Ve=p}return c}(typeof t=="string"?JSON.parse(t):t,this,e)}read(t){return wr(this),this.getEditorState().read(t,{editor:this})}update(t,e){(function(s,l,o){s._updating?s._updates.push([l,o]):Bm(s,l,o)})(this,t,e)}focus(t,e={}){const s=this._rootElement;s!==null&&(s.setAttribute("autocapitalize","off"),In(this,()=>{const l=nt(),o=ge();l!==null?l.dirty||Ze(l.clone()):o.getChildrenSize()!==0&&(e.defaultSelection==="rootStart"?o.selectStart():o.selectEnd()),YM("focus"),qM(()=>{s.removeAttribute("autocapitalize"),t&&t()})}),this._pendingEditorState===null&&s.removeAttribute("autocapitalize"))}blur(){const t=this._rootElement;t!==null&&t.blur();const e=mi(this._window);e!==null&&e.removeAllRanges()}isEditable(){return this._editable}setEditable(t){this._editable!==t&&(this._editable=t,yu("editable",this,!0,t))}toJSON(){return{editorState:this._editorState.toJSON()}}}qd.version="0.33.1+prod.esm";let Ty=null;function Im(n){Ty=n}let UM=1;function cA(n,t){const e=km(n,t);return e===void 0&&X(30,t),e}function km(n,t){return n._nodes.get(t)}const zM=typeof queueMicrotask=="function"?queueMicrotask:n=>{Promise.resolve().then(n)};function m1(n){return qt($l(n))}function Um(n){const t=document.activeElement;if(!Me(t))return!1;const e=t.nodeName;return qt($l(n))&&(e==="INPUT"||e==="TEXTAREA"||t.contentEditable==="true"&&Kd(t)==null)}function qu(n,t,e){const s=n.getRootElement();try{return s!==null&&s.contains(t)&&s.contains(e)&&t!==null&&!Um(t)&&fA(t)===n}catch{return!1}}function zm(n){return n instanceof qd}function fA(n){let t=n;for(;t!=null;){const e=Kd(t);if(zm(e))return e;t=Ku(t)}return null}function Kd(n){return n?n.__lexicalEditor:null}function oa(n){return $d(n)||n.isToken()}function _r(n){return oa(n)||n.isSegmented()}function Br(n){return Zl(n)&&n.nodeType===F2}function $M(n){return Zl(n)&&n.nodeType===L2}function zl(n){let t=n;for(;t!=null;){if(Br(t))return t;t=t.firstChild}return null}function wd(n,t,e){const s=ha[t];if(e!==null&&(n&s)==(e&s))return n;let l=n^s;return t==="subscript"?l&=-65:t==="superscript"?l&=-33:t==="lowercase"?(l&=-513,l&=-1025):t==="uppercase"?(l&=-257,l&=-1025):t==="capitalize"&&(l&=-257,l&=-513),l}function dA(n){return W(n)||os(n)||qt(n)}function jM(n,t){const e=function(){const c=Ty;return Ty=null,c}();if((t=t||e&&e.__key)!=null)return void(n.__key=t);en(),iA();const s=ve(),l=ws(),o=""+UM++;l._nodeMap.set(o,n),Y(n)?s._dirtyElements.set(o,!0):s._dirtyLeaves.add(o),s._cloneNotNeeded.add(o),s._dirtyType=px,n.__key=o}function ua(n){const t=n.getParent();if(t!==null){const e=n.getWritable(),s=t.getWritable(),l=n.getPreviousSibling(),o=n.getNextSibling(),c=o!==null?o.__key:null,f=l!==null?l.__key:null,h=l!==null?l.getWritable():null,p=o!==null?o.getWritable():null;l===null&&(s.__first=c),o===null&&(s.__last=f),h!==null&&(h.__next=c),p!==null&&(p.__prev=f),e.__prev=null,e.__next=null,e.__parent=null,s.__size--}}function xd(n){iA();const t=n.getLatest(),e=t.__parent,s=ws(),l=ve(),o=s._nodeMap,c=l._dirtyElements;e!==null&&function(h,p,y){let m=h;for(;m!==null;){if(y.has(m))return;const _=p.get(m);if(_===void 0)break;y.set(m,!1),m=_.__parent}}(e,o,c);const f=t.__key;l._dirtyType=px,Y(n)?c.set(f,!0):l._dirtyLeaves.add(f)}function Ke(n){en();const t=ve(),e=t._compositionKey;if(n!==e){if(t._compositionKey=n,e!==null){const s=Ce(e);s!==null&&s.getWritable()}if(n!==null){const s=Ce(n);s!==null&&s.getWritable()}}}function as(){return Vu()?null:ve()._compositionKey}function Ce(n,t){const e=(t||ws())._nodeMap.get(n);return e===void 0?null:e}function hA(n,t){const e=Pd(n,ve());return e!==void 0?Ce(e,t):null}function Pd(n,t){return n[`__lexicalKey_${t._key}`]}function $l(n,t){let e=n;for(;e!=null;){const s=hA(e,t);if(s!==null)return s;e=Ku(e)}return null}function gA(n){const t=n._decorators,e=Object.assign({},t);return n._pendingDecorators=e,e}function _1(n){return n.read(()=>ge().getTextContent())}function ge(){return pA(ws())}function pA(n){return n._nodeMap.get("root")}function Ze(n){en();const t=ws();n!==null&&(n.dirty=!0,n.setCachedNodes(null)),t._selection=n}function bl(n){const t=ve(),e=function(s,l){let o=s;for(;o!=null;){const c=Pd(o,l);if(c!==void 0)return c;o=Ku(o)}return null}(n,t);return e===null?n===t.getRootElement()?Ce("root"):null:Ce(e)}function b1(n,t){return t?n.getTextContentSize():0}function yA(n){return/[\uD800-\uDBFF][\uDC00-\uDFFF]/g.test(n)}function $m(n){const t=[];let e=n;for(;e!==null;)t.push(e),e=e._parentEditor;return t}function mA(){return Math.random().toString(36).replace(/[^a-z]+/g,"").substring(0,5)}function _A(n){return Br(n)?n.nodeValue:null}function jm(n,t,e){const s=mi(li(t));if(s===null)return;const l=s.anchorNode;let{anchorOffset:o,focusOffset:c}=s;if(l!==null){let f=_A(l);const h=$l(l);if(f!==null&&W(h)){if(f===Ld&&e){const p=e.length;f=e,o=p,c=p}f!==null&&Vm(h,f,o,c,n)}}}function Vm(n,t,e,s,l){let o=n;if(o.isAttached()&&(l||!o.isDirty())){const c=o.isComposing();let f=t;(c||l)&&t[t.length-1]===Ld&&(f=t.slice(0,-1));const h=o.getTextContent();if(l||f!==h){if(f===""){if(Ke(null),Au||kl||cd)o.remove();else{const A=ve();setTimeout(()=>{A.update(()=>{o.isAttached()&&o.remove()})},20)}return}const p=o.getParent(),y=Gl(),m=o.getTextContentSize(),_=as(),S=o.getKey();if(o.isToken()||_!==null&&S===_&&!c||Z(y)&&(p!==null&&!p.canInsertTextBefore()&&y.anchor.offset===0||y.anchor.key===n.__key&&y.anchor.offset===0&&!o.canInsertTextBefore()&&!c||y.focus.key===n.__key&&y.focus.offset===m&&!o.canInsertTextAfter()&&!c))return void o.markDirty();const v=nt();if(!Z(v)||e===null||s===null)return void o.setTextContent(f);if(v.setTextNodeRange(o,e,o,s),o.isSegmented()){const A=Ee(o.getTextContent());o.replace(A),o=A}o.setTextContent(f)}}}function pf(n,t,e){const s=t[e]||!1;return s==="any"||s===n[e]}function VM(n,t){return pf(n,t,"altKey")&&pf(n,t,"ctrlKey")&&pf(n,t,"shiftKey")&&pf(n,t,"metaKey")}function ie(n,t,e){return VM(n,e)&&n.key.toLowerCase()===t.toLowerCase()}const gr={ctrlKey:!Fi,metaKey:Fi},v1={altKey:Fi,ctrlKey:!Fi};function S1(n){return n.key==="Backspace"}function T1(n){return ie(n,"a",gr)}function HM(n){const t=ge();if(Z(n)){const e=n.anchor,s=n.focus,l=e.getNode().getTopLevelElementOrThrow().getParentOrThrow();return e.set(l.getKey(),0,"element"),s.set(l.getKey(),l.getChildrenSize(),"element"),gd(n),n}{const e=t.select(0,t.getChildrenSize());return Ze(gd(e)),e}}function Cl(n,t){n.__lexicalClassNameCache===void 0&&(n.__lexicalClassNameCache={});const e=n.__lexicalClassNameCache,s=e[t];if(s!==void 0)return s;const l=n[t];if(typeof l=="string"){const o=fd(l);return e[t]=o,o}return l}function Hm(n,t,e,s,l){if(e.size===0)return;const o=s.__type,c=s.__key,f=t.get(o);f===void 0&&X(33,o);const h=f.klass;let p=n.get(h);p===void 0&&(p=new Map,n.set(h,p));const y=p.get(c),m=y==="destroyed"&&l==="created";(y===void 0||m)&&p.set(c,m?"updated":l)}function w1(n,t,e){const s=n.getParent();let l=e,o=n;return s!==null&&(t&&e===0?(l=o.getIndexWithinParent(),o=s):t||e!==o.getChildrenSize()||(l=o.getIndexWithinParent()+1,o=s)),o.getChildAtIndex(t?l-1:l)}function wy(n,t){const e=n.offset;if(n.type==="element")return w1(n.getNode(),t,e);{const s=n.getNode();if(t&&e===0||!t&&e===s.getTextContentSize()){const l=t?s.getPreviousSibling():s.getNextSibling();return l===null?w1(s.getParentOrThrow(),t,s.getIndexWithinParent()+(t?0:1)):l}}return null}function bA(n){const t=li(n).event,e=t&&t.inputType;return e==="insertFromPaste"||e==="insertFromPasteAsQuotation"}function st(n,t,e){return function(s,l,o){const c=$m(s);for(let f=4;f>=0;f--)for(let h=0;h<c.length;h++){const p=c[h],y=p._commands.get(l);if(y!==void 0){const m=y[f];if(m!==void 0){const _=Array.from(m),S=_.length;let v=!1;if(In(p,()=>{for(let A=0;A<S;A++)if(_[A](o,s))return void(v=!0)}),v)return v}}}return!1}(n,t,e)}function Gd(n){return!Pe(n)&&!n.isLastChild()&&!n.isInline()}function jl(n,t){const e=n._keyToDOMMap.get(t);return e===void 0&&X(75,t),e}function Ku(n){const t=n.assignedSlot||n.parentElement;return Ey(t)?t.host:t}function vA(n){return $M(n)?n:Me(n)?n.ownerDocument:null}function YM(n){en(),ve()._updateTags.add(n)}function qM(n){en(),ve()._deferred.push(n)}function xy(n,t){let e=n.getParent();for(;e!==null;){if(e.is(t))return!0;e=e.getParent()}return!1}function Ym(n){const t=vA(n);return t?t.defaultView:null}function li(n){const t=n._window;return t===null&&X(78),t}function KM(n){let t=n.getParentOrThrow();for(;t!==null;){if(un(t))return t;t=t.getParentOrThrow()}return t}function un(n){return Pe(n)||Y(n)&&n.isShadowRoot()}function Hn(n){const t=ve(),e=n.getType(),s=km(t,e);s===void 0&&X(200,n.constructor.name,e);const{replace:l,replaceWithKlass:o}=s;if(l!==null){const c=l(n),f=c.constructor;return o!==null?c instanceof o||X(201,o.name,o.getType(),f.name,f.getType(),n.constructor.name,e):c instanceof n.constructor&&f!==n.constructor||X(202,f.name,f.getType(),n.constructor.name,e),c.__key===n.__key&&X(203,n.constructor.name,e,f.name,f.getType()),c}return n}function Lp(n,t){!Pe(n.getParent())||Y(t)||qt(t)||X(99)}function PM(n){const t=Ce(n);return t===null&&X(63,n),t}function Ip(n){return(qt(n)||Y(n)&&!n.canBeEmpty())&&!n.isInline()}function Ay(n,t,e){e.style.removeProperty("caret-color"),t._blockCursorElement=null;const s=n.parentElement;s!==null&&s.removeChild(n)}function mi(n){return Si?(n||window).getSelection():null}function GM(n){const t=Ym(n);return t?t.getSelection():null}function SA(n){return Me(n)&&n.tagName==="A"}function Me(n){return Zl(n)&&n.nodeType===R2}function Zl(n){return typeof n=="object"&&n!==null&&"nodeType"in n&&typeof n.nodeType=="number"}function Ey(n){return Zl(n)&&n.nodeType===I2}function Oy(n){const t=new RegExp(/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|mark|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var|#text)$/,"i");return n.nodeName.match(t)!==null}function Ad(n){const t=new RegExp(/^(address|article|aside|blockquote|canvas|dd|div|dl|dt|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|header|hr|li|main|nav|noscript|ol|p|pre|section|table|td|tfoot|ul|video)$/,"i");return n.nodeName.match(t)!==null}function ri(n){if(qt(n)&&!n.isInline())return!0;if(!Y(n)||un(n))return!1;const t=n.getFirstChild(),e=t===null||os(t)||W(t)||t.isInline();return!n.isInline()&&n.canBeEmpty()!==!1&&e}function kp(n,t){let e=n;for(;e!==null&&e.getParent()!==null&&!t(e);)e=e.getParentOrThrow();return t(e)?e:null}function qm(){return ve()}const x1=new WeakMap,ZM=new Map;function A1(n){if(!n._readOnly&&n.isEmpty())return ZM;n._readOnly||X(192);let t=x1.get(n);return t||(t=function(e){const s=new Map;for(const[l,o]of e._nodeMap){const c=o.__type;let f=s.get(c);f||(f=new Map,s.set(c,f)),f.set(l,o)}return s}(n),x1.set(n,t)),t}function Km(n){const t=n.constructor.clone(n);return t.afterCloneFrom(n),t}function Pm(n,t){const e=parseInt(n.style.paddingInlineStart,10)||0,s=Math.round(e/40);t.setIndent(s)}function XM(n){return n.__lexicalUnmanaged===!0}function ru(n,t){return function(e,s){return Object.prototype.hasOwnProperty.call(e,s)}(n,t)&&n[t]!==Kl[t]}function Gm(n){const t=kS in n.prototype?n.prototype[kS]():void 0,e=function(c){return c===Rm||c===$n||c===Kl}(n),s=!e&&ru(n,"getType")?n.getType():void 0;let l,o=s;if(t)if(s)l=t[s];else for(const[c,f]of Object.entries(t))o=c,l=f;if(!e&&o&&(ru(n,"getType")||(n.getType=()=>o),ru(n,"clone")||(n.clone=c=>(Im(c),new n)),ru(n,"importJSON")||(n.importJSON=l&&l.$importJSON||(c=>new n().updateFromJSON(c))),!ru(n,"importDOM")&&l)){const{importDOM:c}=l;c&&(n.importDOM=()=>c)}return{ownNodeConfig:l,ownNodeType:o}}const QM={next:"previous",previous:"next"};class Zm{constructor(t){this.origin=t}[Symbol.iterator](){return TA({hasNext:Vl,initial:this.getAdjacentCaret(),map:t=>t,step:t=>t.getAdjacentCaret()})}getAdjacentCaret(){return Ge(this.getNodeAtCaret(),this.direction)}getSiblingCaret(){return Ge(this.origin,this.direction)}remove(){const t=this.getNodeAtCaret();return t&&t.remove(),this}replaceOrInsert(t,e){const s=this.getNodeAtCaret();return t.is(this.origin)||t.is(s)||(s===null?this.insert(t):s.replace(t,e)),this}splice(t,e,s="next"){const l=s===this.direction?e:Array.from(e).reverse();let o=this;const c=this.getParentAtCaret(),f=new Map;for(let h=o.getAdjacentCaret();h!==null&&f.size<t;h=h.getAdjacentCaret()){const p=h.origin.getWritable();f.set(p.getKey(),p)}for(const h of l){if(f.size>0){const p=o.getNodeAtCaret();if(p){if(f.delete(p.getKey()),f.delete(h.getKey()),!(p.is(h)||o.origin.is(h))){const y=h.getParent();y&&y.is(c)&&h.remove(),p.replace(h)}}else p===null&&X(263,Array.from(f).join(" "))}else o.insert(h);o=Ge(h,this.direction)}for(const h of f.values())h.remove();return this}}class Bu extends Zm{constructor(){super(...arguments);Wn(this,"type","child")}getLatest(){const e=this.origin.getLatest();return e===this.origin?this:_i(e,this.direction)}getParentCaret(e="root"){return Ge(Xm(this.getParentAtCaret(),e),this.direction)}getFlipped(){const e=Xl(this.direction);return Ge(this.getNodeAtCaret(),e)||_i(this.origin,e)}getParentAtCaret(){return this.origin}getChildCaret(){return this}isSameNodeCaret(e){return e instanceof Bu&&this.direction===e.direction&&this.origin.is(e.origin)}isSamePointCaret(e){return this.isSameNodeCaret(e)}}const JM={root:Pe,shadowRoot:un};function Xl(n){return QM[n]}function Xm(n,t="root"){return JM[t](n)?null:n}class pa extends Zm{constructor(){super(...arguments);Wn(this,"type","sibling")}getLatest(){const e=this.origin.getLatest();return e===this.origin?this:Ge(e,this.direction)}getSiblingCaret(){return this}getParentAtCaret(){return this.origin.getParent()}getChildCaret(){return Y(this.origin)?_i(this.origin,this.direction):null}getParentCaret(e="root"){return Ge(Xm(this.getParentAtCaret(),e),this.direction)}getFlipped(){const e=Xl(this.direction);return Ge(this.getNodeAtCaret(),e)||_i(this.origin.getParentOrThrow(),e)}isSamePointCaret(e){return e instanceof pa&&this.direction===e.direction&&this.origin.is(e.origin)}isSameNodeCaret(e){return(e instanceof pa||e instanceof ya)&&this.direction===e.direction&&this.origin.is(e.origin)}}class ya extends Zm{constructor(e,s){super(e);Wn(this,"type","text");this.offset=s}getLatest(){const e=this.origin.getLatest();return e===this.origin?this:ma(e,this.direction,this.offset)}getParentAtCaret(){return this.origin.getParent()}getChildCaret(){return null}getParentCaret(e="root"){return Ge(Xm(this.getParentAtCaret(),e),this.direction)}getFlipped(){return ma(this.origin,Xl(this.direction),this.offset)}isSamePointCaret(e){return e instanceof ya&&this.direction===e.direction&&this.origin.is(e.origin)&&this.offset===e.offset}isSameNodeCaret(e){return(e instanceof pa||e instanceof ya)&&this.direction===e.direction&&this.origin.is(e.origin)}getSiblingCaret(){return Ge(this.origin,this.direction)}}function us(n){return n instanceof ya}function Vl(n){return n instanceof pa}function Yi(n){return n instanceof Bu}const WM={next:class extends ya{constructor(){super(...arguments);Wn(this,"direction","next")}getNodeAtCaret(){return this.origin.getNextSibling()}insert(t){return this.origin.insertAfter(t),this}},previous:class extends ya{constructor(){super(...arguments);Wn(this,"direction","previous")}getNodeAtCaret(){return this.origin.getPreviousSibling()}insert(t){return this.origin.insertBefore(t),this}}},tB={next:class extends pa{constructor(){super(...arguments);Wn(this,"direction","next")}getNodeAtCaret(){return this.origin.getNextSibling()}insert(t){return this.origin.insertAfter(t),this}},previous:class extends pa{constructor(){super(...arguments);Wn(this,"direction","previous")}getNodeAtCaret(){return this.origin.getPreviousSibling()}insert(t){return this.origin.insertBefore(t),this}}},eB={next:class extends Bu{constructor(){super(...arguments);Wn(this,"direction","next")}getNodeAtCaret(){return this.origin.getFirstChild()}insert(t){return this.origin.splice(0,0,[t]),this}},previous:class extends Bu{constructor(){super(...arguments);Wn(this,"direction","previous")}getNodeAtCaret(){return this.origin.getLastChild()}insert(t){return this.origin.splice(this.origin.getChildrenSize(),0,[t]),this}}};function Ge(n,t){return n?new tB[t](n):null}function ma(n,t,e){return n?new WM[t](n,Zd(n,e)):null}function Zd(n,t){const e=n.getTextContentSize();let s=t==="next"?e:t==="previous"?0:t;return(s<0||s>e)&&(function(l,...o){const c=new URL("https://lexical.dev/docs/error"),f=new URLSearchParams;f.append("code",l);for(const h of o)f.append("v",h);c.search=f.toString(),console.warn(`Minified Lexical warning #${l}; visit ${c.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}(284,String(t),String(e),n.getKey()),s=s<0?0:e),s}function E1(n,t){return new iB(n,t)}function _i(n,t){return Y(n)?new eB[t](n):null}function nB(n){return n&&n.getChildCaret()||n}function Qm(n){return n&&nB(n.getAdjacentCaret())}class Jm{constructor(t,e,s){Wn(this,"type","node-caret-range");this.anchor=t,this.focus=e,this.direction=s}getLatest(){const t=this.anchor.getLatest(),e=this.focus.getLatest();return t===this.anchor&&e===this.focus?this:new Jm(t,e,this.direction)}isCollapsed(){return this.anchor.isSamePointCaret(this.focus)}getTextSlices(){const t=l=>{const o=this[l].getLatest();return us(o)?function(c,f){const{direction:h,origin:p}=c,y=Zd(p,f==="focus"?Xl(h):h);return E1(c,y-c.offset)}(o,l):null},e=t("anchor"),s=t("focus");if(e&&s){const{caret:l}=e,{caret:o}=s;if(l.isSameNodeCaret(o))return[E1(l,o.offset-l.offset),null]}return[e,s]}iterNodeCarets(t="root"){const e=us(this.anchor)?this.anchor.getSiblingCaret():this.anchor.getLatest(),s=this.focus.getLatest(),l=us(s),o=c=>c.isSameNodeCaret(s)?null:Qm(c)||c.getParentCaret(t);return TA({hasNext:c=>c!==null&&!(l&&s.isSameNodeCaret(c)),initial:e.isSameNodeCaret(s)?null:o(e),map:c=>c,step:o})}[Symbol.iterator](){return this.iterNodeCarets("root")}}class iB{constructor(t,e){Wn(this,"type","slice");this.caret=t,this.distance=e}getSliceIndices(){const{distance:t,caret:{offset:e}}=this,s=e+t;return s<e?[s,e]:[e,s]}getTextContent(){const[t,e]=this.getSliceIndices();return this.caret.origin.getTextContent().slice(t,e)}getTextContentSize(){return Math.abs(this.distance)}removeTextSlice(){const{caret:{origin:t,direction:e}}=this,[s,l]=this.getSliceIndices(),o=t.getTextContent();return ma(t.setTextContent(o.slice(0,s)+o.slice(l)),e,s)}}function Wm(n){return _s(n,Ge(ge(),n.direction))}function rB(n){return _s(n,n)}function _s(n,t){return n.direction!==t.direction&&X(265),new Jm(n,t,n.direction)}function TA(n){const{initial:t,hasNext:e,step:s,map:l}=n;let o=t;return{[Symbol.iterator](){return this},next(){if(!e(o))return{done:!0,value:void 0};const c={done:!1,value:l(o)};return o=s(o),c}}}function wA(n,t){const e=Bf(n.origin,t.origin);switch(e===null&&X(275,n.origin.getKey(),t.origin.getKey()),e.type){case"same":{const s=n.type==="text",l=t.type==="text";return s&&l?function(o,c){return Math.sign(o-c)}(n.offset,t.offset):n.type===t.type?0:s?-1:l?1:n.type==="child"?-1:1}case"ancestor":return n.type==="child"?-1:1;case"descendant":return t.type==="child"?1:-1;case"branch":return xA(e)}}function xA(n){const{a:t,b:e}=n,s=t.__key,l=e.__key;let o=t,c=e;for(;o&&c;o=o.getNextSibling(),c=c.getNextSibling()){if(o.__key===l)return-1;if(c.__key===s)return 1}return o===null?1:-1}function yf(n,t){return t.is(n)}function O1(n){return Y(n)?[n.getLatest(),null]:[n.getParent(),n.getLatest()]}function Bf(n,t){if(n.is(t))return{commonAncestor:n,type:"same"};const e=new Map;for(let[s,l]=O1(n);s;l=s,s=s.getParent())e.set(s,l);for(let[s,l]=O1(t);s;l=s,s=s.getParent()){const o=e.get(s);if(o!==void 0)return o===null?(yf(n,s)||X(276),{commonAncestor:s,type:"ancestor"}):l===null?(yf(t,s)||X(277),{commonAncestor:s,type:"descendant"}):((Y(o)||yf(n,o))&&(Y(l)||yf(t,l))&&s.is(o.getParent())&&s.is(l.getParent())||X(278),{a:o,b:l,commonAncestor:s,type:"branch"})}return null}function Cr(n,t){const{type:e,key:s,offset:l}=n,o=PM(n.key);return e==="text"?(W(o)||X(266,o.getType(),s),ma(o,t,l)):(Y(o)||X(267,o.getType(),s),lB(o,n.offset,t))}function _a(n,t){const{origin:e,direction:s}=t,l=s==="next";us(t)?n.set(e.getKey(),t.offset,"text"):Vl(t)?W(e)?n.set(e.getKey(),Zd(e,s),"text"):n.set(e.getParentOrThrow().getKey(),e.getIndexWithinParent()+(l?1:0),"element"):(Yi(t)&&Y(e)||X(268),n.set(e.getKey(),l?0:e.getChildrenSize(),"element"))}function sB(n){const t=nt(),e=Z(t)?t:Vd();return Rf(e,n),Ze(e),e}function Rf(n,t){_a(n.anchor,t.anchor),_a(n.focus,t.focus)}function N1(n){const{anchor:t,focus:e}=n,s=Cr(t,"next"),l=Cr(e,"next"),o=wA(s,l)<=0?"next":"previous";return _s(Hl(s,o),Hl(l,o))}function t_(n){const{direction:t,origin:e}=n,s=Ge(e,Xl(t)).getNodeAtCaret();return s?Ge(s,t):_i(e.getParentOrThrow(),t)}function C1(n,t="root"){const e=[n];for(let s=Yi(n)?n.getParentCaret(t):n.getSiblingCaret();s!==null;s=s.getParentCaret(t))e.push(t_(s));return e}function Up(n){return!!n&&n.origin.isAttached()}function aB(n,t="removeEmptySlices"){if(n.isCollapsed())return n;const e="root",s="next";let l=t;const o=EA(n,s),c=C1(o.anchor,e),f=C1(o.focus.getFlipped(),e),h=new Set,p=[];for(const v of o.iterNodeCarets(e))if(Yi(v))h.add(v.origin.getKey());else if(Vl(v)){const{origin:A}=v;Y(A)&&!h.has(A.getKey())||p.push(A)}for(const v of p)v.remove();for(const v of o.getTextSlices()){if(!v)continue;const{origin:A}=v.caret,x=A.getTextContentSize(),C=t_(Ge(A,s)),w=A.getMode();if(Math.abs(v.distance)===x&&l==="removeEmptySlices"||w==="token"&&v.distance!==0)C.remove();else if(v.distance!==0){l="removeEmptySlices";let E=v.removeTextSlice();const M=v.caret.origin;if(w==="segmented"){const O=E.origin,D=Ee(O.getTextContent()).setStyle(O.getStyle()).setFormat(O.getFormat());C.replaceOrInsert(D),E=ma(D,s,E.offset)}M.is(c[0].origin)&&(c[0]=E),M.is(f[0].origin)&&(f[0]=E.getFlipped())}}let y,m;for(const v of c)if(Up(v)){y=si(v);break}for(const v of f)if(Up(v)){m=si(v);break}const _=function(v,A,x){if(!v||!A)return null;const C=v.getParentAtCaret(),w=A.getParentAtCaret();if(!C||!w)return null;const E=C.getParents().reverse();E.push(C);const M=w.getParents().reverse();M.push(w);const O=Math.min(E.length,M.length);let D;for(D=0;D<O&&E[D]===M[D];D++);const I=(J,rt)=>{let dt;for(let vt=D;vt<J.length;vt++){const mt=J[vt];if(un(mt))return;!dt&&rt(mt)&&(dt=mt)}return dt},z=I(E,ri),L=z&&I(M,J=>x.has(J.getKey())&&ri(J));return z&&L?[z,L]:null}(y,m,h);if(_){const[v,A]=_;_i(v,"previous").splice(0,A.getChildren()),A.remove()}const S=[y,m,...c,...f].find(Up);if(S)return rB(Hl(si(S),n.direction));X(269,JSON.stringify(c.map(v=>v.origin.__key)))}function si(n){const t=function(l){let o=l;for(;Yi(o);){const c=Qm(o);if(!Yi(c))break;o=c}return o}(n.getLatest()),{direction:e}=t;if(W(t.origin))return us(t)?t:ma(t.origin,e,e);const s=t.getAdjacentCaret();return Vl(s)&&W(s.origin)?ma(s.origin,e,Xl(e)):t}function AA(n){return us(n)&&n.offset!==Zd(n.origin,n.direction)}function Hl(n,t){return n.direction===t?n:n.getFlipped()}function EA(n,t){return n.direction===t?n:_s(Hl(n.focus,t),Hl(n.anchor,t))}function lB(n,t,e){let s=_i(n,"next");for(let l=0;l<t;l++){const o=s.getAdjacentCaret();if(o===null)break;s=o}return Hl(s,e)}const OA=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0,oB=OA?ft.useLayoutEffect:ft.useEffect,mf={tag:Nl};function uB({initialConfig:n,children:t}){const e=ft.useMemo(()=>{const{theme:s,namespace:l,nodes:o,onError:c,editorState:f,html:h}=n,p=D2(null,s),y=kM({editable:n.editable,html:h,namespace:l,nodes:o,onError:m=>c(m,y),theme:s});return function(m,_){if(_!==null){if(_===void 0)m.update(()=>{const S=ge();if(S.isEmpty()){const v=be();S.append(v);const A=OA?document.activeElement:null;(nt()!==null||A!==null&&A===m.getRootElement())&&v.select()}},mf);else if(_!==null)switch(typeof _){case"string":{const S=m.parseEditorState(_);m.setEditorState(S,mf);break}case"object":m.setEditorState(_,mf);break;case"function":m.update(()=>{ge().isEmpty()&&_(m)},mf)}}}(y,f),[y,p]},[]);return oB(()=>{const s=n.editable,[l]=e;l.setEditable(s===void 0||s)},[]),gt.jsx(hx.Provider,{value:e,children:t})}const cB=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0?ft.useLayoutEffect:ft.useEffect;function fB(n){return{initialValueFn:()=>n.isEditable(),subscribe:t=>n.registerEditableListener(t)}}function dB(){return function(n){const[t]=Vn(),e=ft.useMemo(()=>n(t),[t,n]),[s,l]=ft.useState(()=>e.initialValueFn()),o=ft.useRef(s);return cB(()=>{const{initialValueFn:c,subscribe:f}=e,h=c();return o.current!==h&&(o.current=h,l(h)),f(p=>{o.current=p,l(p)})},[e,n]),s}(fB)}function hB(){return ge().getTextContent()}function gB(n,t=!0){if(n)return!1;let e=hB();return t&&(e=e.trim()),e===""}function pB(n){if(!gB(n,!1))return!1;const t=ge().getChildren(),e=t.length;if(e>1)return!1;for(let s=0;s<e;s++){const l=t[s];if(qt(l))return!1;if(Y(l)){if(!Yd(l)||l.__indent!==0)return!1;const o=l.getChildren(),c=o.length;for(let f=0;f<c;f++){const h=o[s];if(!W(h))return!1}}}return!0}function NA(n){return()=>pB(n)}const Ny=new Map;function CA(n){const t={};if(!n)return t;const e=n.split(";");for(const s of e)if(s!==""){const[l,o]=s.split(/:([^]+)/);l&&o&&(t[l.trim()]=o.trim())}return t}function D1(n){let t=Ny.get(n);return t===void 0&&(t=CA(n),Ny.set(n,t)),t}function DA(n,t){const e=n.getStartEndPoints();if(t.isSelected(n)&&!_r(t)&&e!==null){const[s,l]=e,o=n.isBackward(),c=s.getNode(),f=l.getNode(),h=t.is(c),p=t.is(f);if(h||p){const[y,m]=vy(n),_=c.is(f),S=t.is(o?f:c),v=t.is(o?c:f);let A,x=0;_?(x=y>m?m:y,A=y>m?y:m):S?(x=o?m:y,A=void 0):v&&(x=0,A=o?y:m),t.__text=t.__text.slice(x,A)}}return t}function yB(n){const t=n.getStyle(),e=CA(t);Ny.set(t,e)}function mB(n,t){const e=n.getFormatType(),s=n.getIndent();e!==t.getFormatType()&&t.setFormat(e),s!==t.getIndent()&&t.setIndent(s)}function _B(n,t,e=mB){if(n===null)return;const s=n.getStartEndPoints(),l=new Map;let o=null;if(s){const[c,f]=s;o=Vd(),o.anchor.set(c.key,c.offset,c.type),o.focus.set(f.key,f.offset,f.type);const h=zp(c.getNode(),ri),p=zp(f.getNode(),ri);Y(h)&&l.set(h.getKey(),h),Y(p)&&l.set(p.getKey(),p)}for(const c of n.getNodes())if(Y(c)&&ri(c))l.set(c.getKey(),c);else if(s===null){const f=zp(c,ri);Y(f)&&l.set(f.getKey(),f)}for(const[c,f]of l){const h=t();e(f,h),f.replace(h,!0),o&&(c===o.anchor.key&&o.anchor.set(h.getKey(),o.anchor.offset,o.anchor.type),c===o.focus.key&&o.focus.set(h.getKey(),o.focus.offset,o.focus.type))}o&&n.is(nt())&&Ze(o)}function MA(n){const t=n.anchor.getNode(),e=Pe(t)?t:t.getParentOrThrow(),s=qm().getElementByKey(e.getKey());if(s===null)return!1;const l=s.ownerDocument.defaultView;return l===null?!1:l.getComputedStyle(s).writingMode==="vertical-rl"}function M1(n,t){const e=MA(n)?!t:t,s=Cr(n.focus,e?"previous":"next");if(AA(s))return!1;for(const l of Wm(s)){if(Yi(l))return!l.origin.isInline();if(!Y(l.origin)){if(qt(l.origin))return!0;break}}return!1}function bB(n,t,e,s){n.modify(t?"extend":"move",e,s)}function vB(n){const t=n.anchor.getNode();return(Pe(t)?t:t.getParentOrThrow()).getDirection()==="rtl"}function B1(n,t,e){const s=vB(n);let l;l=MA(n)||s?!e:e,bB(n,t,l,"character")}function zp(n,t){let e=n;for(;e!==null&&e.getParent()!==null&&!t(e);)e=e.getParentOrThrow();return t(e)?e:null}function SB(n,...t){const e=new URL("https://lexical.dev/docs/error"),s=new URLSearchParams;s.append("code",n);for(const l of t)s.append("v",l);throw e.search=s.toString(),Error(`Minified Lexical error #${n}; visit ${e.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}const BA=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0,TB=BA&&"documentMode"in document?document.documentMode:null;!(!BA||!("InputEvent"in window)||TB)&&"getTargetRanges"in new window.InputEvent("input");function RA(...n){const t=[];for(const e of n)if(e&&typeof e=="string")for(const[s]of e.matchAll(/\S+/g))t.push(s);return t}function xs(...n){return()=>{for(let t=n.length-1;t>=0;t--)n[t]();n.length=0}}function bi(n,...t){const e=RA(...t);e.length>0&&n.classList.add(...e)}function Xd(n,...t){const e=RA(...t);e.length>0&&n.classList.remove(...e)}function wB(n){return n?n.getAdjacentCaret():null}function xB(n,t){let e=n;for(;e!=null;){if(e instanceof t)return e;e=e.getParent()}return null}function AB(n){const t=Pu(n,e=>Y(e)&&!e.isInline());return Y(t)||SB(4,n.__key),t}const Pu=(n,t)=>{let e=n;for(;e!==ge()&&e!=null;){if(t(e))return e;e=e.getParent()}return null};function ia(n,t){return n!==null&&Object.getPrototypeOf(n).constructor.name===t.name}var R1=TT();function EB(n){const t=window.location.origin,e=s=>{if(s.origin!==t)return;const l=n.getRootElement();if(document.activeElement!==l)return;const o=s.data;if(typeof o=="string"){let c;try{c=JSON.parse(o)}catch{return}if(c&&c.protocol==="nuanria_messaging"&&c.type==="request"){const f=c.payload;if(f&&f.functionId==="makeChanges"){const h=f.args;if(h){const[p,y,m,_,S,v]=h;n.update(()=>{const A=nt();if(Z(A)){const x=A.anchor;let C=x.getNode(),w=0,E=0;if(W(C)&&p>=0&&y>=0&&(w=p,E=p+y,A.setTextNodeRange(C,w,C,E)),w===E&&m===""||(A.insertRawText(m),C=x.getNode()),W(C)){w=_,E=_+S;const M=C.getTextContentSize();w=w>M?M:w,E=E>M?M:E,A.setTextNodeRange(C,w,C,E)}s.stopImmediatePropagation()}})}}}}};return window.addEventListener("message",e,!0),()=>{window.removeEventListener("message",e,!0)}}function OB(n,t){const e=t.body?t.body.childNodes:[];let s=[];const l=[];for(let o=0;o<e.length;o++){const c=e[o];if(!LA.has(c.nodeName)){const f=IA(c,n,l,!1);f!==null&&(s=s.concat(f))}}return function(o){for(const c of o)c.getNextSibling()instanceof Lm&&c.insertAfter(yi());for(const c of o){const f=c.getChildren();for(const h of f)c.insertBefore(h);c.remove()}}(l),s}function NB(n,t){if(typeof document>"u"||typeof window>"u"&&global.window===void 0)throw new Error("To use $generateHtmlFromNodes in headless mode please initialize a headless browser implementation such as JSDom before calling this function.");const e=document.createElement("div"),s=ge().getChildren();for(let l=0;l<s.length;l++)FA(n,s[l],e,t);return e.innerHTML}function FA(n,t,e,s=null){let l=s===null||t.isSelected(s);const o=Y(t)&&t.excludeFromCopy("html");let c=t;if(s!==null){let S=Km(t);S=W(S)&&s!==null?DA(s,S):S,c=S}const f=Y(c)?c.getChildren():[],h=km(n,c.getType());let p;p=h&&h.exportDOM!==void 0?h.exportDOM(n,c):c.exportDOM(n);const{element:y,after:m}=p;if(!y)return!1;const _=document.createDocumentFragment();for(let S=0;S<f.length;S++){const v=f[S],A=FA(n,v,_,s);!l&&Y(t)&&A&&t.extractWithChild(v,s,"html")&&(l=!0)}if(l&&!o){if((Me(y)||Ey(y))&&y.append(_),e.append(y),m){const S=m.call(c,y);S&&(Ey(y)?y.replaceChildren(S):y.replaceWith(S))}}else e.append(_);return l}const LA=new Set(["STYLE","SCRIPT"]);function IA(n,t,e,s,l=new Map,o){let c=[];if(LA.has(n.nodeName))return c;let f=null;const h=function(v,A){const{nodeName:x}=v,C=A._htmlConversions.get(x.toLowerCase());let w=null;if(C!==void 0)for(const E of C){const M=E(v);M!==null&&(w===null||(w.priority||0)<=(M.priority||0))&&(w=M)}return w!==null?w.conversion:null}(n,t),p=h?h(n):null;let y=null;if(p!==null){y=p.after;const v=p.node;if(f=Array.isArray(v)?v[v.length-1]:v,f!==null){for(const[,A]of l)if(f=A(f,o),!f)break;f&&c.push(...Array.isArray(v)?v:[f])}p.forChild!=null&&l.set(n.nodeName,p.forChild)}const m=n.childNodes;let _=[];const S=(f==null||!un(f))&&(f!=null&&Sy(f)||s);for(let v=0;v<m.length;v++)_.push(...IA(m[v],t,e,S,new Map(l),f));return y!=null&&(_=y(_)),Ad(n)&&(_=CB(n,_,S?()=>{const v=new Lm;return e.push(v),v}:be)),f==null?_.length>0?c=c.concat(_):Ad(n)&&function(v){return v.nextSibling==null||v.previousSibling==null?!1:Oy(v.nextSibling)&&Oy(v.previousSibling)}(n)&&(c=c.concat(yi())):Y(f)&&f.append(..._),c}function CB(n,t,e){const s=n.style.textAlign,l=[];let o=[];for(let c=0;c<t.length;c++){const f=t[c];if(Sy(f))s&&!f.getFormat()&&f.setFormat(s),l.push(f);else if(o.push(f),c===t.length-1||c<t.length-1&&Sy(t[c+1])){const h=e();h.setFormat(s),h.append(...o),l.push(h),o=[]}}return l}function Ed(n,...t){const e=new URL("https://lexical.dev/docs/error"),s=new URLSearchParams;s.append("code",n);for(const l of t)s.append("v",l);throw e.search=s.toString(),Error(`Minified Lexical error #${n}; visit ${e.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}function DB(n,t=nt()){return t==null&&Ed(166),Z(t)&&t.isCollapsed()||t.getNodes().length===0?"":NB(n,t)}function MB(n,t=nt()){return t==null&&Ed(166),Z(t)&&t.isCollapsed()||t.getNodes().length===0?null:JSON.stringify(BB(n,t))}function F1(n,t,e){const s=n.getData("application/x-lexical-editor");if(s)try{const f=JSON.parse(s);if(f.namespace===e._config.namespace&&Array.isArray(f.nodes))return L1(e,RB(f.nodes),t)}catch{}const l=n.getData("text/html"),o=n.getData("text/plain");if(l&&o!==l)try{const f=new DOMParser().parseFromString(function(h){return window.trustedTypes&&window.trustedTypes.createPolicy?window.trustedTypes.createPolicy("lexical",{createHTML:p=>p}).createHTML(h):h}(l),"text/html");return L1(e,OB(e,f),t)}catch{}const c=o||n.getData("text/uri-list");if(c!=null)if(Z(t)){const f=c.split(/(\r?\n|\t)/);f[f.length-1]===""&&f.pop();for(let h=0;h<f.length;h++){const p=nt();if(Z(p)){const y=f[h];y===`
`||y===`\r
`?p.insertParagraph():y==="	"?p.insertNodes([Pl()]):p.insertText(y)}}}else t.insertRawText(c)}function L1(n,t,e){n.dispatchCommand(sM,{nodes:t,selection:e})||(e.insertNodes(t),function(s){if(Z(s)&&s.isCollapsed()){const l=s.anchor;let o=null;const c=Cr(l,"previous");if(c)if(us(c))o=c.origin;else{const f=_s(c,_i(ge(),"next").getFlipped());for(const h of f){if(W(h.origin)){o=h.origin;break}if(Y(h.origin)&&!h.origin.isInline())break}}if(o&&W(o)){const f=o.getFormat(),h=o.getStyle();s.format===f&&s.style===h||(s.format=f,s.style=h,s.dirty=!0)}}}(e))}function kA(n,t,e,s=[]){let l=t===null||e.isSelected(t);const o=Y(e)&&e.excludeFromCopy("html");let c=e;if(t!==null){let p=Km(e);p=W(p)&&t!==null?DA(t,p):p,c=p}const f=Y(c)?c.getChildren():[],h=function(p){const y=p.exportJSON(),m=p.constructor;if(y.type!==m.getType()&&Ed(58,m.name),Y(p)){const _=y.children;Array.isArray(_)||Ed(59,m.name)}return y}(c);if(W(c)){const p=c.__text;p.length>0?h.text=p:l=!1}for(let p=0;p<f.length;p++){const y=f[p],m=kA(n,t,y,h.children);!l&&Y(e)&&m&&e.extractWithChild(y,t,"clone")&&(l=!0)}if(l&&!o)s.push(h);else if(Array.isArray(h.children))for(let p=0;p<h.children.length;p++){const y=h.children[p];s.push(y)}return l}function BB(n,t){const e=[],s=ge().getChildren();for(let l=0;l<s.length;l++)kA(n,t,s[l],e);return{namespace:n._config.namespace,nodes:e}}function RB(n){const t=[];for(let e=0;e<n.length;e++){const s=n[e],l=DM(s);W(l)&&yB(l),t.push(l)}return t}let cl=null;async function I1(n,t,e){if(cl!==null)return!1;if(t!==null)return new Promise((p,y)=>{n.update(()=>{p(k1(n,t,e))})});const s=n.getRootElement(),l=n._window||window,o=window.document,c=mi(l);if(s===null||c===null)return!1;const f=o.createElement("span");f.style.cssText="position: fixed; top: -1000px;",f.append(o.createTextNode("#")),s.append(f);const h=new Range;return h.setStart(f,0),h.setEnd(f,1),c.removeAllRanges(),c.addRange(h),new Promise((p,y)=>{const m=n.registerCommand(zd,_=>(ia(_,ClipboardEvent)&&(m(),cl!==null&&(window.clearTimeout(cl),cl=null),p(k1(n,_,e))),!0),IM);cl=window.setTimeout(()=>{m(),cl=null,p(!1)},50),o.execCommand("copy"),f.remove()})}function k1(n,t,e){if(e===void 0){const l=mi(n._window);if(!l)return!1;const o=l.anchorNode,c=l.focusNode;if(o!==null&&c!==null&&!qu(n,o,c))return!1;const f=nt();if(f===null)return!1;e=LB(f)}t.preventDefault();const s=t.clipboardData;return s!==null&&(IB(s,e),!0)}const FB=[["text/html",DB],["application/x-lexical-editor",MB]];function LB(n=nt()){const t={"text/plain":n?n.getTextContent():""};if(n){const e=qm();for(const[s,l]of FB){const o=l(e,n);o!==null&&(t[s]=o)}}return t}function IB(n,t){for(const e in t){const s=t[e];s!==void 0&&n.setData(e,s)}}function U1(n,t){if(document.caretRangeFromPoint!==void 0){const e=document.caretRangeFromPoint(n,t);return e===null?null:{node:e.startContainer,offset:e.startOffset}}if(document.caretPositionFromPoint!=="undefined"){const e=document.caretPositionFromPoint(n,t);return e===null?null:{node:e.offsetNode,offset:e.offset}}return null}const Ql=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0,kB=Ql&&"documentMode"in document?document.documentMode:null,UB=!(!Ql||!("InputEvent"in window)||kB)&&"getTargetRanges"in new window.InputEvent("input"),zB=Ql&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),z1=Ql&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,$B=Ql&&/^(?=.*Chrome).*/i.test(navigator.userAgent),jB=Ql&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent)&&!$B,$1=yt("DRAG_DROP_PASTE_FILE");class Jl extends $n{static getType(){return"quote"}static clone(t){return new Jl(t.__key)}createDOM(t){const e=document.createElement("blockquote");return bi(e,t.theme.quote),e}updateDOM(t,e){return!1}static importDOM(){return{blockquote:t=>({conversion:VB,priority:0})}}exportDOM(t){const{element:e}=super.exportDOM(t);if(Me(e)){this.isEmpty()&&e.append(document.createElement("br"));const s=this.getFormatType();s&&(e.style.textAlign=s);const l=this.getDirection();l&&(e.dir=l)}return{element:e}}static importJSON(t){return e_().updateFromJSON(t)}insertNewAfter(t,e){const s=be(),l=this.getDirection();return s.setDirection(l),this.insertAfter(s,e),s}collapseAtStart(){const t=be();return this.getChildren().forEach(e=>t.append(e)),this.replace(t),!0}canMergeWhenEmpty(){return!0}}function e_(){return Hn(new Jl)}function Cy(n){return n instanceof Jl}let Qd=class UA extends $n{static getType(){return"heading"}static clone(t){return new UA(t.__tag,t.__key)}constructor(t,e){super(e),this.__tag=t}getTag(){return this.__tag}setTag(t){const e=this.getWritable();return this.__tag=t,e}createDOM(t){const e=this.__tag,s=document.createElement(e),l=t.theme.heading;if(l!==void 0){const o=l[e];bi(s,o)}return s}updateDOM(t,e,s){return t.__tag!==this.__tag}static importDOM(){return{h1:t=>({conversion:fl,priority:0}),h2:t=>({conversion:fl,priority:0}),h3:t=>({conversion:fl,priority:0}),h4:t=>({conversion:fl,priority:0}),h5:t=>({conversion:fl,priority:0}),h6:t=>({conversion:fl,priority:0}),p:t=>{const e=t.firstChild;return e!==null&&j1(e)?{conversion:()=>({node:null}),priority:3}:null},span:t=>j1(t)?{conversion:e=>({node:ra("h1")}),priority:3}:null}}exportDOM(t){const{element:e}=super.exportDOM(t);if(Me(e)){this.isEmpty()&&e.append(document.createElement("br"));const s=this.getFormatType();s&&(e.style.textAlign=s);const l=this.getDirection();l&&(e.dir=l)}return{element:e}}static importJSON(t){return ra(t.tag).updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setTag(t.tag)}exportJSON(){return{...super.exportJSON(),tag:this.getTag()}}insertNewAfter(t,e=!0){const s=t?t.anchor.offset:0,l=this.getLastDescendant(),o=!l||t&&t.anchor.key===l.getKey()&&s===l.getTextContentSize()||!t?be():ra(this.getTag()),c=this.getDirection();if(o.setDirection(c),this.insertAfter(o,e),s===0&&!this.isEmpty()&&t){const f=be();f.select(),this.replace(f,!0)}return o}collapseAtStart(){const t=this.isEmpty()?be():ra(this.getTag());return this.getChildren().forEach(e=>t.append(e)),this.replace(t),!0}extractWithChild(){return!0}};function j1(n){return n.nodeName.toLowerCase()==="span"&&n.style.fontSize==="26pt"}function fl(n){const t=n.nodeName.toLowerCase();let e=null;return t!=="h1"&&t!=="h2"&&t!=="h3"&&t!=="h4"&&t!=="h5"&&t!=="h6"||(e=ra(t),n.style!==null&&(Pm(n,e),e.setFormat(n.style.textAlign))),{node:e}}function VB(n){const t=e_();return n.style!==null&&(t.setFormat(n.style.textAlign),Pm(n,t)),{node:t}}function ra(n="h1"){return Hn(new Qd(n))}function HB(n){return n instanceof Qd}function _f(n){let t=null;if(ia(n,DragEvent)?t=n.dataTransfer:ia(n,ClipboardEvent)&&(t=n.clipboardData),t===null)return[!1,[],!1];const e=t.types,s=e.includes("Files"),l=e.includes("text/html")||e.includes("text/plain");return[s,Array.from(t.files),l]}function V1(n){const t=nt();if(!Z(t))return!1;const e=new Set,s=t.getNodes();for(let l=0;l<s.length;l++){const o=s[l],c=o.getKey();if(e.has(c))continue;const f=Pu(o,p=>Y(p)&&!p.isInline());if(f===null)continue;const h=f.getKey();f.canIndent()&&!e.has(h)&&(e.add(h),n(f))}return e.size>0}function H1(n){const t=$l(n);return qt(t)}function $p(n){for(const t of["lowercase","uppercase","capitalize"])n.hasFormat(t)&&n.toggleFormat(t)}function YB(n){return xs(n.registerCommand(Am,t=>{const e=nt();return!!tn(e)&&(e.clear(),!0)},Yt),n.registerCommand(la,t=>{const e=nt();return Z(e)?(e.deleteCharacter(t),!0):!!tn(e)&&(e.deleteNodes(),!0)},Yt),n.registerCommand(Du,t=>{const e=nt();return!!Z(e)&&(e.deleteWord(t),!0)},Yt),n.registerCommand(Mu,t=>{const e=nt();return!!Z(e)&&(e.deleteLine(t),!0)},Yt),n.registerCommand(El,t=>{const e=nt();if(typeof t=="string")e!==null&&e.insertText(t);else{if(e===null)return!1;const s=t.dataTransfer;if(s!=null)F1(s,e,n);else if(Z(e)){const l=t.data;return l&&e.insertText(l),!0}}return!0},Yt),n.registerCommand(hy,()=>{const t=nt();return!!Z(t)&&(t.removeText(),!0)},Yt),n.registerCommand(hi,t=>{const e=nt();return!!Z(e)&&(e.formatText(t),!0)},Yt),n.registerCommand(fM,t=>{const e=nt();if(!Z(e)&&!tn(e))return!1;const s=e.getNodes();for(const l of s){const o=Pu(l,c=>Y(c)&&!c.isInline());o!==null&&o.setFormat(t)}return!0},Yt),n.registerCommand(Al,t=>{const e=nt();return!!Z(e)&&(e.insertLineBreak(t),!0)},Yt),n.registerCommand(Cu,()=>{const t=nt();return!!Z(t)&&(t.insertParagraph(),!0)},Yt),n.registerCommand(uM,()=>(OM([Pl()]),!0),Yt),n.registerCommand(cM,()=>V1(t=>{const e=t.getIndent();t.setIndent(e+1)}),Yt),n.registerCommand(PS,()=>V1(t=>{const e=t.getIndent();e>0&&t.setIndent(Math.max(0,e-1))}),Yt),n.registerCommand(Bx,t=>{const e=nt();if(tn(e)){const s=e.getNodes();if(s.length>0)return s[0].selectPrevious(),!0}else if(Z(e)){const s=wy(e.focus,!0);if(!t.shiftKey&&qt(s)&&!s.isIsolated()&&!s.isInline())return s.selectPrevious(),t.preventDefault(),!0}return!1},Yt),n.registerCommand(Rx,t=>{const e=nt();if(tn(e)){const s=e.getNodes();if(s.length>0)return s[0].selectNext(0,0),!0}else if(Z(e)){if(function(l){const o=l.focus;return o.key==="root"&&o.offset===ge().getChildrenSize()}(e))return t.preventDefault(),!0;const s=wy(e.focus,!1);if(!t.shiftKey&&qt(s)&&!s.isIsolated()&&!s.isInline())return s.selectNext(),t.preventDefault(),!0}return!1},Yt),n.registerCommand(Mx,t=>{const e=nt();if(tn(e)){const s=e.getNodes();if(s.length>0)return t.preventDefault(),s[0].selectPrevious(),!0}if(!Z(e))return!1;if(M1(e,!0)){const s=t.shiftKey;return t.preventDefault(),B1(e,s,!0),!0}return!1},Yt),n.registerCommand(Dx,t=>{const e=nt();if(tn(e)){const l=e.getNodes();if(l.length>0)return t.preventDefault(),l[0].selectNext(0,0),!0}if(!Z(e))return!1;const s=t.shiftKey;return!!M1(e,!1)&&(t.preventDefault(),B1(e,s,!1),!0)},Yt),n.registerCommand(Lx,t=>{if(H1(t.target))return!1;const e=nt();if(Z(e)){if(function(s){if(!s.isCollapsed())return!1;const{anchor:l}=s;if(l.offset!==0)return!1;const o=l.getNode();if(Pe(o))return!1;const c=AB(o);return c.getIndent()>0&&(c.is(o)||o.is(c.getFirstDescendant()))}(e))return t.preventDefault(),n.dispatchCommand(PS,void 0);if(z1&&navigator.language==="ko-KR")return!1}else if(!tn(e))return!1;return t.preventDefault(),n.dispatchCommand(la,!0)},Yt),n.registerCommand(kx,t=>{if(H1(t.target))return!1;const e=nt();return!(!Z(e)&&!tn(e))&&(t.preventDefault(),n.dispatchCommand(la,!1))},Yt),n.registerCommand(_d,t=>{const e=nt();if(!Z(e))return!1;if($p(e),t!==null){if((z1||zB||jB)&&UB)return!1;if(t.preventDefault(),t.shiftKey)return n.dispatchCommand(Al,!1)}return n.dispatchCommand(Cu,void 0)},Yt),n.registerCommand(Ix,()=>{const t=nt();return!!Z(t)&&(n.blur(),!0)},Yt),n.registerCommand(zx,t=>{const[,e]=_f(t);if(e.length>0){const l=U1(t.clientX,t.clientY);if(l!==null){const{offset:o,node:c}=l,f=$l(c);if(f!==null){const h=Vd();if(W(f))h.anchor.set(f.getKey(),o,"text"),h.focus.set(f.getKey(),o,"text");else{const y=f.getParentOrThrow().getKey(),m=f.getIndexWithinParent()+1;h.anchor.set(y,m,"element"),h.focus.set(y,m,"element")}const p=gd(h);Ze(p)}n.dispatchCommand($1,e)}return t.preventDefault(),!0}const s=nt();return!!Z(s)},Yt),n.registerCommand($x,t=>{const[e]=_f(t),s=nt();return!(e&&!Z(s))},Yt),n.registerCommand(jx,t=>{const[e]=_f(t),s=nt();if(e&&!Z(s))return!1;const l=U1(t.clientX,t.clientY);if(l!==null){const o=$l(l.node);qt(o)&&t.preventDefault()}return!0},Yt),n.registerCommand(gy,()=>(HM(),!0),Yt),n.registerCommand(zd,t=>(I1(n,ia(t,ClipboardEvent)?t:null),!0),Yt),n.registerCommand(Om,t=>(async function(e,s){await I1(s,ia(e,ClipboardEvent)?e:null),s.update(()=>{const l=nt();Z(l)?l.removeText():tn(l)&&l.getNodes().forEach(o=>o.remove())})}(t,n),!0),Yt),n.registerCommand(Em,t=>{const[,e,s]=_f(t);return e.length>0&&!s?(n.dispatchCommand($1,e),!0):Zl(t.target)&&Um(t.target)?!1:nt()!==null&&(function(l,o){l.preventDefault(),o.update(()=>{const c=nt(),f=ia(l,InputEvent)||ia(l,KeyboardEvent)?null:l.clipboardData;f!=null&&c!==null&&F1(f,c,o)},{tag:BM})}(t,n),!0)},Yt),n.registerCommand(Fx,t=>{const e=nt();return Z(e)&&$p(e),!1},Yt),n.registerCommand(Ux,t=>{const e=nt();return Z(e)&&$p(e),!1},Yt))}const Dy=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0?ft.useLayoutEffect:ft.useEffect;function Y1(n){return n.getEditorState().read(NA(n.isComposing()))}function qB({contentEditable:n,placeholder:t=null,ErrorBoundary:e}){const[s]=Vn(),l=function(o,c){const[f,h]=ft.useState(()=>o.getDecorators());return Dy(()=>o.registerDecoratorListener(p=>{R1.flushSync(()=>{h(p)})}),[o]),ft.useEffect(()=>{h(o.getDecorators())},[o]),ft.useMemo(()=>{const p=[],y=Object.keys(f);for(let m=0;m<y.length;m++){const _=y[m],S=gt.jsx(c,{onError:A=>o._onError(A),children:gt.jsx(ft.Suspense,{fallback:null,children:f[_]})}),v=o.getElementByKey(_);v!==null&&p.push(R1.createPortal(S,v,_))}return p},[c,f,o])}(s,e);return function(o){Dy(()=>xs(YB(o),EB(o)),[o])}(s),gt.jsxs(gt.Fragment,{children:[n,gt.jsx(KB,{content:t}),l]})}function KB({content:n}){const[t]=Vn(),e=function(l){const[o,c]=ft.useState(()=>Y1(l));return Dy(()=>{function f(){const h=Y1(l);c(h)}return f(),xs(l.registerUpdateListener(()=>{f()}),l.registerEditableListener(()=>{f()}))},[l]),o}(t),s=dB();return e?typeof n=="function"?n(s):n:null}const zA=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0?ft.useLayoutEffect:ft.useEffect;function PB({editor:n,ariaActiveDescendant:t,ariaAutoComplete:e,ariaControls:s,ariaDescribedBy:l,ariaErrorMessage:o,ariaExpanded:c,ariaInvalid:f,ariaLabel:h,ariaLabelledBy:p,ariaMultiline:y,ariaOwns:m,ariaRequired:_,autoCapitalize:S,className:v,id:A,role:x="textbox",spellCheck:C=!0,style:w,tabIndex:E,"data-testid":M,...O},D){const[I,z]=ft.useState(n.isEditable()),L=ft.useCallback(rt=>{rt&&rt.ownerDocument&&rt.ownerDocument.defaultView?n.setRootElement(rt):n.setRootElement(null)},[n]),J=ft.useMemo(()=>function(...rt){return dt=>{rt.forEach(vt=>{typeof vt=="function"?vt(dt):vt!=null&&(vt.current=dt)})}}(D,L),[L,D]);return zA(()=>(z(n.isEditable()),n.registerEditableListener(rt=>{z(rt)})),[n]),gt.jsx("div",{"aria-activedescendant":I?t:void 0,"aria-autocomplete":I?e:"none","aria-controls":I?s:void 0,"aria-describedby":l,...o!=null?{"aria-errormessage":o}:{},"aria-expanded":I&&x==="combobox"?!!c:void 0,...f!=null?{"aria-invalid":f}:{},"aria-label":h,"aria-labelledby":p,"aria-multiline":y,"aria-owns":I?m:void 0,"aria-readonly":!I||void 0,"aria-required":_,autoCapitalize:S,className:v,contentEditable:I,"data-testid":M,id:A,ref:J,role:x,spellCheck:C,style:w,tabIndex:E,...O})}const GB=ft.forwardRef(PB);function q1(n){return n.getEditorState().read(NA(n.isComposing()))}const ZB=ft.forwardRef(XB);function XB(n,t){const{placeholder:e,...s}=n,[l]=Vn();return gt.jsxs(gt.Fragment,{children:[gt.jsx(GB,{editor:l,...s,ref:t}),e!=null&&gt.jsx(QB,{editor:l,content:e})]})}function QB({content:n,editor:t}){const e=function(c){const[f,h]=ft.useState(()=>q1(c));return zA(()=>{function p(){const y=q1(c);h(y)}return p(),xs(c.registerUpdateListener(()=>{p()}),c.registerEditableListener(()=>{p()}))},[c]),f}(t),[s,l]=ft.useState(t.isEditable());if(ft.useLayoutEffect(()=>(l(t.isEditable()),t.registerEditableListener(c=>{l(c)})),[t]),!e)return null;let o=null;return typeof n=="function"?o=n(s):n!==null&&(o=n),o===null?null:gt.jsx("div",{"aria-hidden":!0,children:o})}const bf=0,My=1,By=2,fi=0,JB=1,K1=2,WB=3,tR=4;function eR(n,t,e,s,l){if(n===null||e.size===0&&s.size===0&&!l)return fi;const o=t._selection,c=n._selection;if(l)return JB;if(!(Z(o)&&Z(c)&&c.isCollapsed()&&o.isCollapsed()))return fi;const f=function(C,w,E){const M=C._nodeMap,O=[];for(const D of w){const I=M.get(D);I!==void 0&&O.push(I)}for(const[D,I]of E){if(!I)continue;const z=M.get(D);z===void 0||Pe(z)||O.push(z)}return O}(t,e,s);if(f.length===0)return fi;if(f.length>1){const C=t._nodeMap,w=C.get(o.anchor.key),E=C.get(c.anchor.key);return w&&E&&!n._nodeMap.has(w.__key)&&W(w)&&w.__text.length===1&&o.anchor.offset===1?K1:fi}const h=f[0],p=n._nodeMap.get(h.__key);if(!W(p)||!W(h)||p.__mode!==h.__mode)return fi;const y=p.__text,m=h.__text;if(y===m)return fi;const _=o.anchor,S=c.anchor;if(_.key!==S.key||_.type!=="text")return fi;const v=_.offset,A=S.offset,x=m.length-y.length;return x===1&&A===v-1?K1:x===-1&&A===v+1?WB:x===-1&&A===v?tR:fi}function nR(n,t){let e=Date.now(),s=fi;return(l,o,c,f,h,p)=>{const y=Date.now();if(p.has(Td))return s=fi,e=y,By;const m=eR(l,o,f,h,n.isComposing()),_=(()=>{const S=c===null||c.editor===n,v=p.has(MM);if(!v&&S&&p.has(Nl))return bf;if(l===null)return My;const A=o._selection;return f.size>0||h.size>0?v===!1&&m!==fi&&m===s&&y<e+t&&S||f.size===1&&function(x,C,w){const E=C._nodeMap.get(x),M=w._nodeMap.get(x),O=C._selection,D=w._selection;return!(Z(O)&&Z(D)&&O.anchor.type==="element"&&O.focus.type==="element"&&D.anchor.type==="text"&&D.focus.type==="text"||!W(E)||!W(M)||E.__parent!==M.__parent)&&JSON.stringify(C.read(()=>E.exportJSON()))===JSON.stringify(w.read(()=>M.exportJSON()))}(Array.from(f)[0],l,o)?bf:My:A!==null?bf:By})();return e=y,s=m,_}}function P1(n){n.undoStack=[],n.redoStack=[],n.current=null}function iR(n,t,e){const s=nR(n,e);return xs(n.registerCommand(kd,()=>(function(o,c){const f=c.redoStack,h=c.undoStack;if(h.length!==0){const p=c.current,y=h.pop();p!==null&&(f.push(p),o.dispatchCommand(ou,!0)),h.length===0&&o.dispatchCommand(uu,!1),c.current=y||null,y&&y.editor.setEditorState(y.editorState,{tag:Td})}}(n,t),!0),Yt),n.registerCommand(Ud,()=>(function(o,c){const f=c.redoStack,h=c.undoStack;if(f.length!==0){const p=c.current;p!==null&&(h.push(p),o.dispatchCommand(uu,!0));const y=f.pop();f.length===0&&o.dispatchCommand(ou,!1),c.current=y||null,y&&y.editor.setEditorState(y.editorState,{tag:Td})}}(n,t),!0),Yt),n.registerCommand(hM,()=>(P1(t),!1),Yt),n.registerCommand(Vx,()=>(P1(t),n.dispatchCommand(ou,!1),n.dispatchCommand(uu,!1),!0),Yt),n.registerUpdateListener(({editorState:o,prevEditorState:c,dirtyLeaves:f,dirtyElements:h,tags:p})=>{const y=t.current,m=t.redoStack,_=t.undoStack,S=y===null?null:y.editorState;if(y!==null&&o===S)return;const v=s(c,o,y,f,h,p);if(v===My)m.length!==0&&(t.redoStack=[],n.dispatchCommand(ou,!1)),y!==null&&(_.push({...y}),n.dispatchCommand(uu,!0));else if(v===By)return;t.current={editor:n,editorState:o}}))}function rR(){return{current:null,redoStack:[],undoStack:[]}}function sR({delay:n,externalHistoryState:t}){const[e]=Vn();return function(s,l,o=1e3){const c=ft.useMemo(()=>l||rR(),[l]);ft.useEffect(()=>iR(s,c,o),[o,s,c])}(e,t,n),null}function aR({defaultSelection:n}){const[t]=Vn();return ft.useEffect(()=>{t.focus(()=>{const e=document.activeElement,s=t.getRootElement();s===null||e!==null&&s.contains(e)||s.focus({preventScroll:!0})},{defaultSelection:n})},[n,t]),null}const lR=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0?ft.useLayoutEffect:ft.useEffect;function oR({ignoreHistoryMergeTagChange:n=!0,ignoreSelectionChange:t=!1,onChange:e}){const[s]=Vn();return lR(()=>{if(e)return s.registerUpdateListener(({editorState:l,dirtyElements:o,dirtyLeaves:c,prevEditorState:f,tags:h})=>{t&&o.size===0&&c.size===0||n&&h.has(Nl)||f.isEmpty()||e(l,s,h)})},[s,n,t,e]),null}function Ry(n,t){return Ry=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,s){return e.__proto__=s,e},Ry(n,t)}var G1={error:null},uR=function(n){var t,e;function s(){for(var o,c=arguments.length,f=new Array(c),h=0;h<c;h++)f[h]=arguments[h];return(o=n.call.apply(n,[this].concat(f))||this).state=G1,o.resetErrorBoundary=function(){for(var p,y=arguments.length,m=new Array(y),_=0;_<y;_++)m[_]=arguments[_];o.props.onReset==null||(p=o.props).onReset.apply(p,m),o.reset()},o}e=n,(t=s).prototype=Object.create(e.prototype),t.prototype.constructor=t,Ry(t,e),s.getDerivedStateFromError=function(o){return{error:o}};var l=s.prototype;return l.reset=function(){this.setState(G1)},l.componentDidCatch=function(o,c){var f,h;(f=(h=this.props).onError)==null||f.call(h,o,c)},l.componentDidUpdate=function(o,c){var f,h,p,y,m=this.state.error,_=this.props.resetKeys;m!==null&&c.error!==null&&((p=o.resetKeys)===void 0&&(p=[]),(y=_)===void 0&&(y=[]),p.length!==y.length||p.some(function(S,v){return!Object.is(S,y[v])}))&&((f=(h=this.props).onResetKeysChange)==null||f.call(h,o.resetKeys,_),this.reset())},l.render=function(){var o=this.state.error,c=this.props,f=c.fallbackRender,h=c.FallbackComponent,p=c.fallback;if(o!==null){var y={error:o,resetErrorBoundary:this.resetErrorBoundary};if(ft.isValidElement(p))return p;if(typeof f=="function")return f(y);if(h)return ft.createElement(h,y);throw new Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},s}(ft.Component);function cR({children:n,onError:t}){return gt.jsx(uR,{fallback:gt.jsx("div",{style:{border:"1px solid #f00",color:"#f00",padding:"8px"},children:"An error was thrown."}),onError:t,children:n})}const jp=1;function Z1(){return gt.jsx("div",{className:"divider"})}function fR(){const[n]=Vn(),t=ft.useRef(null),[e,s]=ft.useState(!1),[l,o]=ft.useState(!1),[c,f]=ft.useState(!1),[h,p]=ft.useState(!1),[y,m]=ft.useState(!1),[_,S]=ft.useState("paragraph"),v=ft.useCallback(()=>{const x=nt();if(Z(x)){f(x.hasFormat("bold")),p(x.hasFormat("italic")),m(x.hasFormat("underline"));const C=x.anchor.getNode(),w=C.getKey()==="root"?C:C.getTopLevelElement();if(w!==null){const E=w.getKey(),M=n.getElementByKey(E);M!==null&&(M.tagName==="P"?S("paragraph"):M.tagName.match(/^H[1-6]$/)&&S(M.tagName.toLowerCase()))}}},[n]),A=ft.useCallback(x=>{n.update(()=>{const C=nt();Z(C)&&_B(C,()=>x.target.value==="paragraph"?be():ra(x.target.value))})},[n]);return ft.useEffect(()=>xs(n.registerUpdateListener(({editorState:x})=>{x.read(()=>{v()})}),n.registerCommand(xm,(x,C)=>(v(),!1),jp),n.registerCommand(uu,x=>(s(x),!1),jp),n.registerCommand(ou,x=>(o(x),!1),jp)),[n,v]),gt.jsxs("div",{className:"toolbar",ref:t,children:[gt.jsx("button",{disabled:!e,onClick:()=>{n.dispatchCommand(kd,void 0)},className:"toolbar-item spaced","aria-label":"Undo",children:gt.jsx("i",{className:"format undo"})}),gt.jsx("button",{disabled:!l,onClick:()=>{n.dispatchCommand(Ud,void 0)},className:"toolbar-item","aria-label":"Redo",children:gt.jsx("i",{className:"format redo"})}),gt.jsx(Z1,{}),gt.jsx("button",{onClick:()=>{n.dispatchCommand(hi,"bold")},className:"toolbar-item spaced "+(c?"active":""),"aria-label":"Format Bold",children:gt.jsx("i",{className:"format bold"})}),gt.jsx("button",{onClick:()=>{n.dispatchCommand(hi,"italic")},className:"toolbar-item spaced "+(h?"active":""),"aria-label":"Format Italics",children:gt.jsx("i",{className:"format italic"})}),gt.jsx("button",{onClick:()=>{n.dispatchCommand(hi,"underline")},className:"toolbar-item spaced "+(y?"active":""),"aria-label":"Format Underline",children:gt.jsx("i",{className:"format underline"})}),gt.jsx(Z1,{}),gt.jsxs("select",{className:"toolbar-item block-controls",value:_,onChange:A,children:[gt.jsx("option",{value:"paragraph",children:"Normal"}),gt.jsx("option",{value:"h1",children:"Heading 1"}),gt.jsx("option",{value:"h2",children:"Heading 2"}),gt.jsx("option",{value:"h3",children:"Heading 3"})]})]})}const dR={code:"editor-code",heading:{h1:"editor-heading-h1",h2:"editor-heading-h2",h3:"editor-heading-h3",h4:"editor-heading-h4",h5:"editor-heading-h5",h6:"editor-heading-h6"},image:"editor-image",link:"editor-link",list:{listitem:"editor-listitem",nested:{listitem:"editor-nested-listitem"},ol:"editor-list-ol",ul:"editor-list-ul"},ltr:"ltr",paragraph:"editor-paragraph",placeholder:"editor-placeholder",quote:"editor-quote",rtl:"rtl",text:{bold:"editor-text-bold",code:"editor-text-code",hashtag:"editor-text-hashtag",italic:"editor-text-italic",overflowed:"editor-text-overflowed",strikethrough:"editor-text-strikethrough",underline:"editor-text-underline",underlineStrikethrough:"editor-text-underlineStrikethrough"}};function ls(n,...t){const e=new URL("https://lexical.dev/docs/error"),s=new URLSearchParams;s.append("code",n);for(const l of t)s.append("v",l);throw e.search=s.toString(),Error(`Minified Lexical error #${n}; visit ${e.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}function Fy(n){let t=1,e=n.getParent();for(;e!=null;){if(Pt(e)){const s=e.getParent();if(Tt(s)){t++,e=s.getParent();continue}ls(40)}return t}return t}function Ly(n){let t=n.getParent();Tt(t)||ls(40);let e=t;for(;e!==null;)e=e.getParent(),Tt(e)&&(t=e);return t}function $A(n){let t=[];const e=n.getChildren().filter(Pt);for(let s=0;s<e.length;s++){const l=e[s],o=l.getFirstChild();Tt(o)?t=t.concat($A(o)):t.push(l)}return t}function ji(n){return Pt(n)&&Tt(n.getFirstChild())}function X1(n){return jn().append(n)}function jA(n,t){return Pt(n)&&(t.length===0||t.length===1&&n.is(t[0])&&n.getChildrenSize()===0)}function Q1(n){const t=nt();if(t!==null){let e=t.getNodes();if(Z(t)){const l=t.getStartEndPoints();l===null&&ls(143);const[o]=l,c=o.getNode(),f=c.getParent();if(un(c)){const h=c.getFirstChild();if(h)e=h.selectStart().getNodes();else{const p=be();c.append(p),e=p.select().getNodes()}}else if(jA(c,e)){const h=Sn(n);if(un(f)){c.replace(h);const p=jn();Y(c)&&(p.setFormat(c.getFormatType()),p.setIndent(c.getIndent())),h.append(p)}else if(Pt(c)){const p=c.getParentOrThrow();ba(h,p.getChildren()),p.replace(h)}return}}const s=new Set;for(let l=0;l<e.length;l++){const o=e[l];if(Y(o)&&o.isEmpty()&&!Pt(o)&&!s.has(o.getKey())){J1(o,n);continue}let c=dA(o)?o.getParent():Pt(o)&&o.isEmpty()?o:null;for(;c!=null;){const f=c.getKey();if(Tt(c)){if(!s.has(f)){const h=Sn(n);ba(h,c.getChildren()),c.replace(h),s.add(f)}break}{const h=c.getParent();if(un(h)&&!s.has(f)){s.add(f),J1(c,n);break}c=h}}}}}function ba(n,t){n.splice(n.getChildrenSize(),0,t)}function J1(n,t){if(Tt(n))return n;const e=n.getPreviousSibling(),s=n.getNextSibling(),l=jn();let o;if(ba(l,n.getChildren()),Tt(e)&&t===e.getListType())e.append(l),Tt(s)&&t===s.getListType()&&(ba(e,s.getChildren()),s.remove()),o=e;else if(Tt(s)&&t===s.getListType())s.getFirstChildOrThrow().insertBefore(l),o=s;else{const c=Sn(t);c.append(l),n.replace(c),o=c}return l.setFormat(n.getFormatType()),l.setIndent(n.getIndent()),n.remove(),o}function n_(n,t){const e=n.getLastChild(),s=t.getFirstChild();e&&s&&ji(e)&&ji(s)&&(n_(e.getFirstChild(),s.getFirstChild()),s.remove());const l=t.getChildren();l.length>0&&n.append(...l),t.remove()}function hR(){const n=nt();if(Z(n)){const t=new Set,e=n.getNodes(),s=n.anchor.getNode();if(jA(s,e))t.add(Ly(s));else for(let l=0;l<e.length;l++){const o=e[l];if(dA(o)){const c=xB(o,As);c!=null&&t.add(Ly(c))}}for(const l of t){let o=l;const c=$A(l);for(const f of c){const h=be().setTextStyle(n.style).setTextFormat(n.format);ba(h,f.getChildren()),o.insertAfter(h),o=h,f.__key===n.anchor.key&&_a(n.anchor,si(_i(h,"next"))),f.__key===n.focus.key&&_a(n.focus,si(_i(h,"next"))),f.remove()}l.remove()}}}function VA(n){const t=n.getListType()!=="check";let e=n.getStart();for(const s of n.getChildren())Pt(s)&&(s.getValue()!==e&&s.setValue(e),t&&s.getLatest().__checked!=null&&s.setChecked(void 0),Tt(s.getFirstChild())||e++)}function gR(n){const t=new Set;if(ji(n)||t.has(n.getKey()))return;const e=n.getParent(),s=n.getNextSibling(),l=n.getPreviousSibling();if(ji(s)&&ji(l)){const o=l.getFirstChild();if(Tt(o)){o.append(n);const c=s.getFirstChild();Tt(c)&&(ba(o,c.getChildren()),s.remove(),t.add(s.getKey()))}}else if(ji(s)){const o=s.getFirstChild();if(Tt(o)){const c=o.getFirstChild();c!==null&&c.insertBefore(n)}}else if(ji(l)){const o=l.getFirstChild();Tt(o)&&o.append(n)}else if(Tt(e)){const o=jn().setTextFormat(n.getTextFormat()).setTextStyle(n.getTextStyle()),c=Sn(e.getListType()).setTextFormat(e.getTextFormat()).setTextStyle(e.getTextStyle());o.append(c),c.append(n),l?l.insertAfter(o):s?s.insertBefore(o):e.append(o)}}function pR(n){if(ji(n))return;const t=n.getParent(),e=t?t.getParent():void 0;if(Tt(e?e.getParent():void 0)&&Pt(e)&&Tt(t)){const s=t?t.getFirstChild():void 0,l=t?t.getLastChild():void 0;if(n.is(s))e.insertBefore(n),t.isEmpty()&&e.remove();else if(n.is(l))e.insertAfter(n),t.isEmpty()&&e.remove();else{const o=t.getListType(),c=jn(),f=Sn(o);c.append(f),n.getPreviousSiblings().forEach(y=>f.append(y));const h=jn(),p=Sn(o);h.append(p),ba(p,n.getNextSiblings()),e.insertBefore(c),e.insertAfter(h),e.replace(n)}}}function yR(){const n=nt();if(!Z(n)||!n.isCollapsed())return!1;const t=n.anchor.getNode();if(!Pt(t)||t.getChildrenSize()!==0)return!1;const e=Ly(t),s=t.getParent();Tt(s)||ls(40);const l=s.getParent();let o;if(un(l))o=be(),e.insertAfter(o);else{if(!Pt(l))return!1;o=jn(),l.insertAfter(o)}o.setTextStyle(n.style).setTextFormat(n.format).select();const c=t.getNextSiblings();if(c.length>0){const f=Sn(s.getListType());if(Pt(o)){const h=jn();h.append(f),o.insertAfter(h)}else o.insertAfter(f);f.append(...c)}return function(f){let h=f;for(;h.getNextSibling()==null&&h.getPreviousSibling()==null;){const p=h.getParent();if(p==null||!Pt(p)&&!Tt(p))break;h=p}h.remove()}(t),!0}function Od(...n){const t=[];for(const e of n)if(e&&typeof e=="string")for(const[s]of e.matchAll(/\S+/g))t.push(s);return t}let As=class extends $n{$config(){return this.config("listitem",{$transform:t=>{if(t.__checked==null)return;const e=t.getParent();Tt(e)&&e.getListType()!=="check"&&t.getChecked()!=null&&t.setChecked(void 0)},extends:$n,importDOM:{li:()=>({conversion:mR,priority:0})}})}constructor(t=1,e=void 0,s){super(s),this.__value=t===void 0?1:t,this.__checked=e}afterCloneFrom(t){super.afterCloneFrom(t),this.__value=t.__value,this.__checked=t.__checked}createDOM(t){const e=document.createElement("li");return this.updateListItemDOM(null,e,t),e}updateListItemDOM(t,e,s){const l=this.getParent();Tt(l)&&l.getListType()==="check"&&function(f,h,p,y){Tt(h.getFirstChild())?(f.removeAttribute("role"),f.removeAttribute("tabIndex"),f.removeAttribute("aria-checked")):(f.setAttribute("role","checkbox"),f.setAttribute("tabIndex","-1"),p&&h.__checked===p.__checked||f.setAttribute("aria-checked",h.getChecked()?"true":"false"))}(e,this,t),e.value=this.__value,function(f,h,p){const y=[],m=[],_=h.list,S=_?_.listitem:void 0;let v;if(_&&_.nested&&(v=_.nested.listitem),S!==void 0&&y.push(...Od(S)),_){const A=p.getParent(),x=Tt(A)&&A.getListType()==="check",C=p.getChecked();x&&!C||m.push(_.listitemUnchecked),x&&C||m.push(_.listitemChecked),x&&y.push(C?_.listitemChecked:_.listitemUnchecked)}if(v!==void 0){const A=Od(v);p.getChildren().some(x=>Tt(x))?y.push(...A):m.push(...A)}m.length>0&&Xd(f,...m),y.length>0&&bi(f,...y)}(e,s.theme,this);const o=t?t.__style:"",c=this.__style;o!==c&&(c===""?e.removeAttribute("style"):e.style.cssText=c),function(f,h,p){const y=D1(h.__textStyle);for(const m in y)f.style.setProperty(`--listitem-marker-${m}`,y[m]);if(p)for(const m in D1(p.__textStyle))m in y||f.style.removeProperty(`--listitem-marker-${m}`)}(e,this,t)}updateDOM(t,e,s){const l=e;return this.updateListItemDOM(t,l,s),!1}updateFromJSON(t){return super.updateFromJSON(t).setValue(t.value).setChecked(t.checked)}exportDOM(t){const e=this.createDOM(t._config),s=this.getFormatType();s&&(e.style.textAlign=s);const l=this.getDirection();return l&&(e.dir=l),{element:e}}exportJSON(){return{...super.exportJSON(),checked:this.getChecked(),value:this.getValue()}}append(...t){for(let e=0;e<t.length;e++){const s=t[e];if(Y(s)&&this.canMergeWith(s)){const l=s.getChildren();this.append(...l),s.remove()}else super.append(s)}return this}replace(t,e){if(Pt(t))return super.replace(t);this.setIndent(0);const s=this.getParentOrThrow();if(!Tt(s))return t;if(s.__first===this.getKey())s.insertBefore(t);else if(s.__last===this.getKey())s.insertAfter(t);else{const l=Sn(s.getListType());let o=this.getNextSibling();for(;o;){const c=o;o=o.getNextSibling(),l.append(c)}s.insertAfter(t),t.insertAfter(l)}return e&&(Y(t)||ls(139),this.getChildren().forEach(l=>{t.append(l)})),this.remove(),s.getChildrenSize()===0&&s.remove(),t}insertAfter(t,e=!0){const s=this.getParentOrThrow();if(Tt(s)||ls(39),Pt(t))return super.insertAfter(t,e);const l=this.getNextSiblings();if(s.insertAfter(t,e),l.length!==0){const o=Sn(s.getListType());l.forEach(c=>o.append(c)),t.insertAfter(o,e)}return t}remove(t){const e=this.getPreviousSibling(),s=this.getNextSibling();super.remove(t),e&&s&&ji(e)&&ji(s)&&(n_(e.getFirstChild(),s.getFirstChild()),s.remove())}insertNewAfter(t,e=!0){const s=jn().updateFromJSON(this.exportJSON()).setChecked(!this.getChecked()&&void 0);return this.insertAfter(s,e),s}collapseAtStart(t){const e=be();this.getChildren().forEach(c=>e.append(c));const s=this.getParentOrThrow(),l=s.getParentOrThrow(),o=Pt(l);if(s.getChildrenSize()===1)if(o)s.remove(),l.select();else{s.insertBefore(e),s.remove();const c=t.anchor,f=t.focus,h=e.getKey();c.type==="element"&&c.getNode().is(this)&&c.set(h,c.offset,"element"),f.type==="element"&&f.getNode().is(this)&&f.set(h,f.offset,"element")}else s.insertBefore(e),this.remove();return!0}getValue(){return this.getLatest().__value}setValue(t){const e=this.getWritable();return e.__value=t,e}getChecked(){const t=this.getLatest();let e;const s=this.getParent();return Tt(s)&&(e=s.getListType()),e==="check"?!!t.__checked:void 0}setChecked(t){const e=this.getWritable();return e.__checked=t,e}toggleChecked(){const t=this.getWritable();return t.setChecked(!t.__checked)}getIndent(){const t=this.getParent();if(t===null||!this.isAttached())return this.getLatest().__indent;let e=t.getParentOrThrow(),s=0;for(;Pt(e);)e=e.getParentOrThrow().getParentOrThrow(),s++;return s}setIndent(t){typeof t!="number"&&ls(117),(t=Math.floor(t))>=0||ls(199);let e=this.getIndent();for(;e!==t;)e<t?(gR(this),e++):(pR(this),e--);return this}canInsertAfter(t){return Pt(t)}canReplaceWith(t){return Pt(t)}canMergeWith(t){return Pt(t)||Yd(t)}extractWithChild(t,e){if(!Z(e))return!1;const s=e.anchor.getNode(),l=e.focus.getNode();return this.isParentOf(s)&&this.isParentOf(l)&&this.getTextContent().length===e.getTextContent().length}isParentRequired(){return!0}createParentElementNode(){return Sn("bullet")}canMergeWhenEmpty(){return!0}};function mR(n){if(n.classList.contains("task-list-item")){for(const e of n.children)if(e.tagName==="INPUT")return _R(e)}const t=n.getAttribute("aria-checked");return{node:jn(t==="true"||t!=="false"&&void 0)}}function _R(n){return n.getAttribute("type")!=="checkbox"?{node:null}:{node:jn(n.hasAttribute("checked"))}}function jn(n){return Hn(new As(void 0,n))}function Pt(n){return n instanceof As}let Ta=class extends $n{$config(){return this.config("list",{$transform:t=>{(function(e){const s=e.getNextSibling();Tt(s)&&e.getListType()===s.getListType()&&n_(e,s)})(t),VA(t)},extends:$n,importDOM:{ol:()=>({conversion:tT,priority:0}),ul:()=>({conversion:tT,priority:0})}})}constructor(t="number",e=1,s){super(s);const l=vR[t]||t;this.__listType=l,this.__tag=l==="number"?"ol":"ul",this.__start=e}afterCloneFrom(t){super.afterCloneFrom(t),this.__listType=t.__listType,this.__tag=t.__tag,this.__start=t.__start}getTag(){return this.getLatest().__tag}setListType(t){const e=this.getWritable();return e.__listType=t,e.__tag=t==="number"?"ol":"ul",e}getListType(){return this.getLatest().__listType}getStart(){return this.getLatest().__start}setStart(t){const e=this.getWritable();return e.__start=t,e}createDOM(t,e){const s=this.__tag,l=document.createElement(s);return this.__start!==1&&l.setAttribute("start",String(this.__start)),l.__lexicalListType=this.__listType,W1(l,t.theme,this),l}updateDOM(t,e,s){return t.__tag!==this.__tag||(W1(e,s.theme,this),!1)}updateFromJSON(t){return super.updateFromJSON(t).setListType(t.listType).setStart(t.start)}exportDOM(t){const e=this.createDOM(t._config,t);return Me(e)&&(this.__start!==1&&e.setAttribute("start",String(this.__start)),this.__listType==="check"&&e.setAttribute("__lexicalListType","check")),{element:e}}exportJSON(){return{...super.exportJSON(),listType:this.getListType(),start:this.getStart(),tag:this.getTag()}}canBeEmpty(){return!1}canIndent(){return!1}splice(t,e,s){let l=s;for(let o=0;o<s.length;o++){const c=s[o];Pt(c)||(l===s&&(l=[...s]),l[o]=jn().append(!Y(c)||Tt(c)||c.isInline()?c:Ee(c.getTextContent())))}return super.splice(t,e,l)}extractWithChild(t){return Pt(t)}};function W1(n,t,e){const s=[],l=[],o=t.list;if(o!==void 0){const c=o[`${e.__tag}Depth`]||[],f=Fy(e)-1,h=f%c.length,p=c[h],y=o[e.__tag];let m;const _=o.nested,S=o.checklist;if(_!==void 0&&_.list&&(m=_.list),y!==void 0&&s.push(y),S!==void 0&&e.__listType==="check"&&s.push(S),p!==void 0){s.push(...Od(p));for(let v=0;v<c.length;v++)v!==h&&l.push(e.__tag+v)}if(m!==void 0){const v=Od(m);f>1?s.push(...v):l.push(...v)}}l.length>0&&Xd(n,...l),s.length>0&&bi(n,...s)}function bR(n){const t=[];for(let e=0;e<n.length;e++){const s=n[e];if(Pt(s)){t.push(s);const l=s.getChildren();l.length>1&&l.forEach(o=>{Tt(o)&&t.push(X1(o))})}else t.push(X1(s))}return t}function tT(n){const t=n.nodeName.toLowerCase();let e=null;return t==="ol"?e=Sn("number",n.start):t==="ul"&&(e=function(s){if(s.getAttribute("__lexicallisttype")==="check"||s.classList.contains("contains-task-list"))return!0;for(const l of s.childNodes)if(Me(l)&&l.hasAttribute("aria-checked"))return!0;return!1}(n)?Sn("check"):Sn("bullet")),{after:bR,node:e}}const vR={ol:"number",ul:"bullet"};function Sn(n="number",t=1){return Hn(new Ta(n,t))}function Tt(n){return n instanceof Ta}const SR=yt("UPDATE_LIST_START_COMMAND"),TR=yt("INSERT_UNORDERED_LIST_COMMAND"),wR=yt("INSERT_ORDERED_LIST_COMMAND"),xR=yt("REMOVE_LIST_COMMAND");function AR(n){return xs(n.registerCommand(wR,()=>(Q1("number"),!0),ml),n.registerCommand(SR,t=>{const{listNodeKey:e,newStart:s}=t,l=Ce(e);return!!Tt(l)&&(l.getListType()==="number"&&(l.setStart(s),VA(l)),!0)},ml),n.registerCommand(TR,()=>(Q1("bullet"),!0),ml),n.registerCommand(xR,()=>(hR(),!0),ml),n.registerCommand(Cu,()=>yR(),ml),n.registerNodeTransform(As,t=>{const e=t.getFirstChild();if(e){if(W(e)){const s=e.getStyle(),l=e.getFormat();t.getTextStyle()!==s&&t.setTextStyle(s),t.getTextFormat()!==l&&t.setTextFormat(l)}}else{const s=nt();Z(s)&&(s.style!==t.getTextStyle()||s.format!==t.getTextFormat())&&s.isCollapsed()&&t.is(s.anchor.getNode())&&t.setTextStyle(s.style).setTextFormat(s.format)}}),n.registerNodeTransform(Ts,t=>{const e=t.getParent();if(Pt(e)&&t.is(e.getFirstChild())){const s=t.getStyle(),l=t.getFormat();s===e.getTextStyle()&&l===e.getTextFormat()||e.setTextStyle(s).setTextFormat(l)}}))}function ER(n){const t=e=>{const s=e.getParent();if(Tt(e.getFirstChild())||!Tt(s))return;const l=Pu(e,o=>Pt(o)&&Tt(o.getParent())&&Pt(o.getPreviousSibling()));if(l===null&&e.getIndent()>0)e.setIndent(0);else if(Pt(l)){const o=l.getPreviousSibling();if(Pt(o)){const c=function(h){let p=h,y=p.getFirstChild();for(;Tt(y);){const m=y.getLastChild();if(!Pt(m))break;p=m,y=p.getFirstChild()}return p}(o),f=c.getParent();if(Tt(f)){const h=Fy(f);h+1<Fy(s)&&e.setIndent(h)}}}};return n.registerNodeTransform(Ta,e=>{const s=[e];for(;s.length>0;){const l=s.shift();if(Tt(l)){for(const o of l.getChildren())if(Pt(o)){t(o);const c=o.getFirstChild();Tt(c)&&s.push(c)}}}})}var Vp={exports:{}},eT;function OR(){return eT||(eT=1,function(n){var t=typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{};/**
 * Prism: Lightweight, robust, elegant syntax highlighting
 *
 * @license MIT <https://opensource.org/licenses/MIT>
 * @author Lea Verou <https://lea.verou.me>
 * @namespace
 * @public
 */var e=function(s){var l=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,o=0,c={},f={manual:s.Prism&&s.Prism.manual,disableWorkerMessageHandler:s.Prism&&s.Prism.disableWorkerMessageHandler,util:{encode:function w(E){return E instanceof h?new h(E.type,w(E.content),E.alias):Array.isArray(E)?E.map(w):E.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(w){return Object.prototype.toString.call(w).slice(8,-1)},objId:function(w){return w.__id||Object.defineProperty(w,"__id",{value:++o}),w.__id},clone:function w(E,M){M=M||{};var O,D;switch(f.util.type(E)){case"Object":if(D=f.util.objId(E),M[D])return M[D];O={},M[D]=O;for(var I in E)E.hasOwnProperty(I)&&(O[I]=w(E[I],M));return O;case"Array":return D=f.util.objId(E),M[D]?M[D]:(O=[],M[D]=O,E.forEach(function(z,L){O[L]=w(z,M)}),O);default:return E}},getLanguage:function(w){for(;w;){var E=l.exec(w.className);if(E)return E[1].toLowerCase();w=w.parentElement}return"none"},setLanguage:function(w,E){w.className=w.className.replace(RegExp(l,"gi"),""),w.classList.add("language-"+E)},currentScript:function(){if(typeof document>"u")return null;if(document.currentScript&&document.currentScript.tagName==="SCRIPT")return document.currentScript;try{throw new Error}catch(O){var w=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(O.stack)||[])[1];if(w){var E=document.getElementsByTagName("script");for(var M in E)if(E[M].src==w)return E[M]}return null}},isActive:function(w,E,M){for(var O="no-"+E;w;){var D=w.classList;if(D.contains(E))return!0;if(D.contains(O))return!1;w=w.parentElement}return!!M}},languages:{plain:c,plaintext:c,text:c,txt:c,extend:function(w,E){var M=f.util.clone(f.languages[w]);for(var O in E)M[O]=E[O];return M},insertBefore:function(w,E,M,O){O=O||f.languages;var D=O[w],I={};for(var z in D)if(D.hasOwnProperty(z)){if(z==E)for(var L in M)M.hasOwnProperty(L)&&(I[L]=M[L]);M.hasOwnProperty(z)||(I[z]=D[z])}var J=O[w];return O[w]=I,f.languages.DFS(f.languages,function(rt,dt){dt===J&&rt!=w&&(this[rt]=I)}),I},DFS:function w(E,M,O,D){D=D||{};var I=f.util.objId;for(var z in E)if(E.hasOwnProperty(z)){M.call(E,z,E[z],O||z);var L=E[z],J=f.util.type(L);J==="Object"&&!D[I(L)]?(D[I(L)]=!0,w(L,M,null,D)):J==="Array"&&!D[I(L)]&&(D[I(L)]=!0,w(L,M,z,D))}}},plugins:{},highlightAll:function(w,E){f.highlightAllUnder(document,w,E)},highlightAllUnder:function(w,E,M){var O={callback:M,container:w,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};f.hooks.run("before-highlightall",O),O.elements=Array.prototype.slice.apply(O.container.querySelectorAll(O.selector)),f.hooks.run("before-all-elements-highlight",O);for(var D=0,I;I=O.elements[D++];)f.highlightElement(I,E===!0,O.callback)},highlightElement:function(w,E,M){var O=f.util.getLanguage(w),D=f.languages[O];f.util.setLanguage(w,O);var I=w.parentElement;I&&I.nodeName.toLowerCase()==="pre"&&f.util.setLanguage(I,O);var z=w.textContent,L={element:w,language:O,grammar:D,code:z};function J(dt){L.highlightedCode=dt,f.hooks.run("before-insert",L),L.element.innerHTML=L.highlightedCode,f.hooks.run("after-highlight",L),f.hooks.run("complete",L),M&&M.call(L.element)}if(f.hooks.run("before-sanity-check",L),I=L.element.parentElement,I&&I.nodeName.toLowerCase()==="pre"&&!I.hasAttribute("tabindex")&&I.setAttribute("tabindex","0"),!L.code){f.hooks.run("complete",L),M&&M.call(L.element);return}if(f.hooks.run("before-highlight",L),!L.grammar){J(f.util.encode(L.code));return}if(E&&s.Worker){var rt=new Worker(f.filename);rt.onmessage=function(dt){J(dt.data)},rt.postMessage(JSON.stringify({language:L.language,code:L.code,immediateClose:!0}))}else J(f.highlight(L.code,L.grammar,L.language))},highlight:function(w,E,M){var O={code:w,grammar:E,language:M};if(f.hooks.run("before-tokenize",O),!O.grammar)throw new Error('The language "'+O.language+'" has no grammar.');return O.tokens=f.tokenize(O.code,O.grammar),f.hooks.run("after-tokenize",O),h.stringify(f.util.encode(O.tokens),O.language)},tokenize:function(w,E){var M=E.rest;if(M){for(var O in M)E[O]=M[O];delete E.rest}var D=new m;return _(D,D.head,w),y(w,D,E,D.head,0),v(D)},hooks:{all:{},add:function(w,E){var M=f.hooks.all;M[w]=M[w]||[],M[w].push(E)},run:function(w,E){var M=f.hooks.all[w];if(!(!M||!M.length))for(var O=0,D;D=M[O++];)D(E)}},Token:h};s.Prism=f;function h(w,E,M,O){this.type=w,this.content=E,this.alias=M,this.length=(O||"").length|0}h.stringify=function w(E,M){if(typeof E=="string")return E;if(Array.isArray(E)){var O="";return E.forEach(function(J){O+=w(J,M)}),O}var D={type:E.type,content:w(E.content,M),tag:"span",classes:["token",E.type],attributes:{},language:M},I=E.alias;I&&(Array.isArray(I)?Array.prototype.push.apply(D.classes,I):D.classes.push(I)),f.hooks.run("wrap",D);var z="";for(var L in D.attributes)z+=" "+L+'="'+(D.attributes[L]||"").replace(/"/g,"&quot;")+'"';return"<"+D.tag+' class="'+D.classes.join(" ")+'"'+z+">"+D.content+"</"+D.tag+">"};function p(w,E,M,O){w.lastIndex=E;var D=w.exec(M);if(D&&O&&D[1]){var I=D[1].length;D.index+=I,D[0]=D[0].slice(I)}return D}function y(w,E,M,O,D,I){for(var z in M)if(!(!M.hasOwnProperty(z)||!M[z])){var L=M[z];L=Array.isArray(L)?L:[L];for(var J=0;J<L.length;++J){if(I&&I.cause==z+","+J)return;var rt=L[J],dt=rt.inside,vt=!!rt.lookbehind,mt=!!rt.greedy,ut=rt.alias;if(mt&&!rt.pattern.global){var H=rt.pattern.toString().match(/[imsuy]*$/)[0];rt.pattern=RegExp(rt.pattern.source,H+"g")}for(var Q=rt.pattern||rt,it=O.next,_t=D;it!==E.tail&&!(I&&_t>=I.reach);_t+=it.value.length,it=it.next){var B=it.value;if(E.length>w.length)return;if(!(B instanceof h)){var G=1,tt;if(mt){if(tt=p(Q,_t,w,vt),!tt||tt.index>=w.length)break;var ot=tt.index,et=tt.index+tt[0].length,at=_t;for(at+=it.value.length;ot>=at;)it=it.next,at+=it.value.length;if(at-=it.value.length,_t=at,it.value instanceof h)continue;for(var Nt=it;Nt!==E.tail&&(at<et||typeof Nt.value=="string");Nt=Nt.next)G++,at+=Nt.value.length;G--,B=w.slice(_t,at),tt.index-=_t}else if(tt=p(Q,0,B,vt),!tt)continue;var ot=tt.index,Se=tt[0],Vt=B.slice(0,ot),Xe=B.slice(ot+Se.length),Ti=_t+B.length;I&&Ti>I.reach&&(I.reach=Ti);var Zi=it.prev;Vt&&(Zi=_(E,Zi,Vt),_t+=Vt.length),S(E,Zi,G);var eo=new h(z,dt?f.tokenize(Se,dt):Se,ut,Se);if(it=_(E,Zi,eo),Xe&&_(E,it,Xe),G>1){var Es={cause:z+","+J,reach:Ti};y(w,E,M,it.prev,_t,Es),I&&Es.reach>I.reach&&(I.reach=Es.reach)}}}}}}function m(){var w={value:null,prev:null,next:null},E={value:null,prev:w,next:null};w.next=E,this.head=w,this.tail=E,this.length=0}function _(w,E,M){var O=E.next,D={value:M,prev:E,next:O};return E.next=D,O.prev=D,w.length++,D}function S(w,E,M){for(var O=E.next,D=0;D<M&&O!==w.tail;D++)O=O.next;E.next=O,O.prev=E,w.length-=D}function v(w){for(var E=[],M=w.head.next;M!==w.tail;)E.push(M.value),M=M.next;return E}if(!s.document)return s.addEventListener&&(f.disableWorkerMessageHandler||s.addEventListener("message",function(w){var E=JSON.parse(w.data),M=E.language,O=E.code,D=E.immediateClose;s.postMessage(f.highlight(O,f.languages[M],M)),D&&s.close()},!1)),f;var A=f.util.currentScript();A&&(f.filename=A.src,A.hasAttribute("data-manual")&&(f.manual=!0));function x(){f.manual||f.highlightAll()}if(!f.manual){var C=document.readyState;C==="loading"||C==="interactive"&&A&&A.defer?document.addEventListener("DOMContentLoaded",x):window.requestAnimationFrame?window.requestAnimationFrame(x):window.setTimeout(x,16)}return f}(t);n.exports&&(n.exports=e),typeof Wv<"u"&&(Wv.Prism=e),e.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},e.languages.markup.tag.inside["attr-value"].inside.entity=e.languages.markup.entity,e.languages.markup.doctype.inside["internal-subset"].inside=e.languages.markup,e.hooks.add("wrap",function(s){s.type==="entity"&&(s.attributes.title=s.content.replace(/&amp;/,"&"))}),Object.defineProperty(e.languages.markup.tag,"addInlined",{value:function(l,o){var c={};c["language-"+o]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:e.languages[o]},c.cdata=/^<!\[CDATA\[|\]\]>$/i;var f={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:c}};f["language-"+o]={pattern:/[\s\S]+/,inside:e.languages[o]};var h={};h[l]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return l}),"i"),lookbehind:!0,greedy:!0,inside:f},e.languages.insertBefore("markup","cdata",h)}}),Object.defineProperty(e.languages.markup.tag,"addAttribute",{value:function(s,l){e.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+s+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[l,"language-"+l],inside:e.languages[l]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),e.languages.html=e.languages.markup,e.languages.mathml=e.languages.markup,e.languages.svg=e.languages.markup,e.languages.xml=e.languages.extend("markup",{}),e.languages.ssml=e.languages.xml,e.languages.atom=e.languages.xml,e.languages.rss=e.languages.xml,function(s){var l=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;s.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+l.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+l.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+l.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+l.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:l,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},s.languages.css.atrule.inside.rest=s.languages.css;var o=s.languages.markup;o&&(o.tag.addInlined("style","css"),o.tag.addAttribute("style","css"))}(e),e.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},e.languages.javascript=e.languages.extend("clike",{"class-name":[e.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),e.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,e.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:e.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:e.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:e.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:e.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:e.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),e.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:e.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),e.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),e.languages.markup&&(e.languages.markup.tag.addInlined("script","javascript"),e.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),e.languages.js=e.languages.javascript,function(){if(typeof e>"u"||typeof document>"u")return;Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var s="Loading…",l=function(A,x){return"✖ Error "+A+" while fetching file: "+x},o="✖ Error: File does not exist or is empty",c={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},f="data-src-status",h="loading",p="loaded",y="failed",m="pre[data-src]:not(["+f+'="'+p+'"]):not(['+f+'="'+h+'"])';function _(A,x,C){var w=new XMLHttpRequest;w.open("GET",A,!0),w.onreadystatechange=function(){w.readyState==4&&(w.status<400&&w.responseText?x(w.responseText):w.status>=400?C(l(w.status,w.statusText)):C(o))},w.send(null)}function S(A){var x=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(A||"");if(x){var C=Number(x[1]),w=x[2],E=x[3];return w?E?[C,Number(E)]:[C,void 0]:[C,C]}}e.hooks.add("before-highlightall",function(A){A.selector+=", "+m}),e.hooks.add("before-sanity-check",function(A){var x=A.element;if(x.matches(m)){A.code="",x.setAttribute(f,h);var C=x.appendChild(document.createElement("CODE"));C.textContent=s;var w=x.getAttribute("data-src"),E=A.language;if(E==="none"){var M=(/\.(\w+)$/.exec(w)||[,"none"])[1];E=c[M]||M}e.util.setLanguage(C,E),e.util.setLanguage(x,E);var O=e.plugins.autoloader;O&&O.loadLanguages(E),_(w,function(D){x.setAttribute(f,p);var I=S(x.getAttribute("data-range"));if(I){var z=D.split(/\r\n?|\n/g),L=I[0],J=I[1]==null?z.length:I[1];L<0&&(L+=z.length),L=Math.max(0,Math.min(L-1,z.length)),J<0&&(J+=z.length),J=Math.max(0,Math.min(J,z.length)),D=z.slice(L,J).join(`
`),x.hasAttribute("data-start")||x.setAttribute("data-start",String(L+1))}C.textContent=D,e.highlightElement(C)},function(D){x.setAttribute(f,y),C.textContent=D})}}),e.plugins.fileHighlight={highlight:function(x){for(var C=(x||document).querySelectorAll(m),w=0,E;E=C[w++];)e.highlightElement(E)}};var v=!1;e.fileHighlight=function(){v||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),v=!0),e.plugins.fileHighlight.highlight.apply(this,arguments)}}()}(Vp)),Vp.exports}OR();Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/};Prism.languages.javascript=Prism.languages.extend("clike",{"class-name":[Prism.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/});Prism.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/;Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/});Prism.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}});Prism.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}});Prism.languages.markup&&(Prism.languages.markup.tag.addInlined("script","javascript"),Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript"));Prism.languages.js=Prism.languages.javascript;Prism.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]};Prism.languages.markup.tag.inside["attr-value"].inside.entity=Prism.languages.markup.entity;Prism.languages.markup.doctype.inside["internal-subset"].inside=Prism.languages.markup;Prism.hooks.add("wrap",function(n){n.type==="entity"&&(n.attributes.title=n.content.replace(/&amp;/,"&"))});Object.defineProperty(Prism.languages.markup.tag,"addInlined",{value:function(t,e){var s={};s["language-"+e]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:Prism.languages[e]},s.cdata=/^<!\[CDATA\[|\]\]>$/i;var l={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:s}};l["language-"+e]={pattern:/[\s\S]+/,inside:Prism.languages[e]};var o={};o[t]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return t}),"i"),lookbehind:!0,greedy:!0,inside:l},Prism.languages.insertBefore("markup","cdata",o)}});Object.defineProperty(Prism.languages.markup.tag,"addAttribute",{value:function(n,t){Prism.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+n+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:Prism.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}});Prism.languages.html=Prism.languages.markup;Prism.languages.mathml=Prism.languages.markup;Prism.languages.svg=Prism.languages.markup;Prism.languages.xml=Prism.languages.extend("markup",{});Prism.languages.ssml=Prism.languages.xml;Prism.languages.atom=Prism.languages.xml;Prism.languages.rss=Prism.languages.xml;(function(n){var t=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function e(y){return y=y.replace(/<inner>/g,function(){return t}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+y+")")}var s=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,l=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return s}),o=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;n.languages.markdown=n.languages.extend("markup",{}),n.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:n.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+l+o+"(?:"+l+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+l+o+")(?:"+l+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(s),inside:n.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+l+")"+o+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+l+"$"),inside:{"table-header":{pattern:RegExp(s),alias:"important",inside:n.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:e(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:e(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:e(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:e(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(y){["url","bold","italic","strike","code-snippet"].forEach(function(m){y!==m&&(n.languages.markdown[y].inside.content.inside[m]=n.languages.markdown[m])})}),n.hooks.add("after-tokenize",function(y){if(y.language!=="markdown"&&y.language!=="md")return;function m(_){if(!(!_||typeof _=="string"))for(var S=0,v=_.length;S<v;S++){var A=_[S];if(A.type!=="code"){m(A.content);continue}var x=A.content[1],C=A.content[3];if(x&&C&&x.type==="code-language"&&C.type==="code-block"&&typeof x.content=="string"){var w=x.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp");w=(/[a-z][\w-]*/i.exec(w)||[""])[0].toLowerCase();var E="language-"+w;C.alias?typeof C.alias=="string"?C.alias=[C.alias,E]:C.alias.push(E):C.alias=[E]}}}m(y.tokens)}),n.hooks.add("wrap",function(y){if(y.type==="code-block"){for(var m="",_=0,S=y.classes.length;_<S;_++){var v=y.classes[_],A=/language-(.+)/.exec(v);if(A){m=A[1];break}}var x=n.languages[m];if(x)y.content=n.highlight(p(y.content),x,m);else if(m&&m!=="none"&&n.plugins.autoloader){var C="md-"+new Date().valueOf()+"-"+Math.floor(Math.random()*1e16);y.attributes.id=C,n.plugins.autoloader.loadLanguages(m,function(){var w=document.getElementById(C);w&&(w.innerHTML=n.highlight(w.textContent,n.languages[m],m))})}}});var c=RegExp(n.languages.markup.tag.pattern.source,"gi"),f={amp:"&",lt:"<",gt:">",quot:'"'},h=String.fromCodePoint||String.fromCharCode;function p(y){var m=y.replace(c,"");return m=m.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(_,S){if(S=S.toLowerCase(),S[0]==="#"){var v;return S[1]==="x"?v=parseInt(S.slice(2),16):v=Number(S.slice(1)),h(v)}else{var A=f[S];return A||_}}),m}n.languages.md=n.languages.markdown})(Prism);Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/});Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}});Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}});Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/});delete Prism.languages.c.boolean;(function(n){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;n.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},n.languages.css.atrule.inside.rest=n.languages.css;var e=n.languages.markup;e&&(e.tag.addInlined("style","css"),e.tag.addAttribute("style","css"))})(Prism);Prism.languages.objectivec=Prism.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/});delete Prism.languages.objectivec["class-name"];Prism.languages.objc=Prism.languages.objectivec;Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/};(function(n){var t=n.languages.powershell={comment:[{pattern:/(^|[^`])<#[\s\S]*?#>/,lookbehind:!0},{pattern:/(^|[^`])#.*/,lookbehind:!0}],string:[{pattern:/"(?:`[\s\S]|[^`"])*"/,greedy:!0,inside:null},{pattern:/'(?:[^']|'')*'/,greedy:!0}],namespace:/\[[a-z](?:\[(?:\[[^\]]*\]|[^\[\]])*\]|[^\[\]])*\]/i,boolean:/\$(?:false|true)\b/i,variable:/\$\w+\b/,function:[/\b(?:Add|Approve|Assert|Backup|Block|Checkpoint|Clear|Close|Compare|Complete|Compress|Confirm|Connect|Convert|ConvertFrom|ConvertTo|Copy|Debug|Deny|Disable|Disconnect|Dismount|Edit|Enable|Enter|Exit|Expand|Export|Find|ForEach|Format|Get|Grant|Group|Hide|Import|Initialize|Install|Invoke|Join|Limit|Lock|Measure|Merge|Move|New|Open|Optimize|Out|Ping|Pop|Protect|Publish|Push|Read|Receive|Redo|Register|Remove|Rename|Repair|Request|Reset|Resize|Resolve|Restart|Restore|Resume|Revoke|Save|Search|Select|Send|Set|Show|Skip|Sort|Split|Start|Step|Stop|Submit|Suspend|Switch|Sync|Tee|Test|Trace|Unblock|Undo|Uninstall|Unlock|Unprotect|Unpublish|Unregister|Update|Use|Wait|Watch|Where|Write)-[a-z]+\b/i,/\b(?:ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i],keyword:/\b(?:Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,operator:{pattern:/(^|\W)(?:!|-(?:b?(?:and|x?or)|as|(?:Not)?(?:Contains|In|Like|Match)|eq|ge|gt|is(?:Not)?|Join|le|lt|ne|not|Replace|sh[lr])\b|-[-=]?|\+[+=]?|[*\/%]=?)/i,lookbehind:!0},punctuation:/[|{}[\];(),.]/};t.string[0].inside={function:{pattern:/(^|[^`])\$\((?:\$\([^\r\n()]*\)|(?!\$\()[^\r\n)])*\)/,lookbehind:!0,inside:t},boolean:t.boolean,variable:t.variable}})(Prism);var nT={},iT;function NR(){return iT||(iT=1,Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python),nT}NR();var rT={},sT;function CR(){return sT||(sT=1,function(n){for(var t=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,e=0;e<2;e++)t=t.replace(/<self>/g,function(){return t});t=t.replace(/<self>/g,function(){return/[^\s\S]/.source}),n.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},n.languages.rust["closure-params"].inside.rest=n.languages.rust,n.languages.rust.attribute.inside.string=n.languages.rust.string}(Prism)),rT}CR();Prism.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+(/(?:elseif|if)\b/.source+"(?:[ 	]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+")+"|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/};Prism.languages.swift["string-literal"].forEach(function(n){n.inside.interpolation.inside=Prism.languages.swift});var aT={},lT;function DR(){return lT||(lT=1,function(n){n.languages.typescript=n.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),n.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete n.languages.typescript.parameter,delete n.languages.typescript["literal-property"];var t=n.languages.extend("typescript",{});delete t["class-name"],n.languages.typescript["class-name"].inside=t,n.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:t}}}}),n.languages.ts=n.languages.typescript}(Prism)),aT}DR();var oT={},uT;function MR(){return uT||(uT=1,function(n){var t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,e=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,s={pattern:RegExp(/(^|[^\w.])/.source+e+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};n.languages.java=n.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[s,{pattern:RegExp(/(^|[^\w.])/.source+e+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:s.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+e+/[A-Z]\w*\b/.source),lookbehind:!0,inside:s.inside}],keyword:t,function:[n.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),n.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),n.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":s,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+e+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:s.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+e+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:s.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(Prism)),oT}MR();var cT={},fT;function BR(){return fT||(fT=1,function(n){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,e=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return t.source});n.languages.cpp=n.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),n.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return e})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),n.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:n.languages.cpp}}}}),n.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),n.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:n.languages.extend("cpp",{})}}),n.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},n.languages.cpp["base-clause"])}(Prism)),cT}BR();(function(n){n.languages.diff={coord:[/^(?:\*{3}|-{3}|\+{3}).*$/m,/^@@.*@@$/m,/^\d.*$/m]};var t={"deleted-sign":"-","deleted-arrow":"<","inserted-sign":"+","inserted-arrow":">",unchanged:" ",diff:"!"};Object.keys(t).forEach(function(e){var s=t[e],l=[];/^\w+$/.test(e)||l.push(/\w+/.exec(e)[0]),e==="diff"&&l.push("bold"),n.languages.diff[e]={pattern:RegExp("^(?:["+s+`].*(?:\r
?|
|(?![\\s\\S])))+`,"m"),alias:l,inside:{line:{pattern:/(.)(?=[\s\S]).*(?:\r\n?|\n)?/,lookbehind:!0},prefix:{pattern:/[\s\S]/,alias:/\w+/.exec(e)[0]}}}}),Object.defineProperty(n.languages.diff,"PREFIXES",{value:t})})(Prism);const Hp=globalThis.Prism||window.Prism,dT=n=>{const t=/^diff-([\w-]+)/i;try{if(!n)return!1;const e=t.exec(n);return e?Hp.languages.hasOwnProperty("diff")&&Hp.languages.hasOwnProperty(e[1]):Hp.languages.hasOwnProperty(n)}catch{return!1}};function HA(n,t){for(const e of n.childNodes){if(Me(e)&&e.tagName===t)return!0;HA(e,t)}return!1}const cu="data-language",vf="data-highlight-language";class Wl extends $n{static getType(){return"code"}static clone(t){return new Wl(t.__language,t.__key)}constructor(t,e){super(e),this.__language=t||void 0,this.__isSyntaxHighlightSupported=dT(t)}createDOM(t){const e=document.createElement("code");bi(e,t.theme.code),e.setAttribute("spellcheck","false");const s=this.getLanguage();return s&&(e.setAttribute(cu,s),this.getIsSyntaxHighlightSupported()&&e.setAttribute(vf,s)),e}updateDOM(t,e,s){const l=this.__language,o=t.__language;return l?l!==o&&(e.setAttribute(cu,l),this.__isSyntaxHighlightSupported&&e.setAttribute(vf,l)):o&&(e.removeAttribute(cu),t.__isSyntaxHighlightSupported&&e.removeAttribute(vf)),!1}exportDOM(t){const e=document.createElement("pre");bi(e,t._config.theme.code),e.setAttribute("spellcheck","false");const s=this.getLanguage();return s&&(e.setAttribute(cu,s),this.getIsSyntaxHighlightSupported()&&e.setAttribute(vf,s)),{element:e}}static importDOM(){return{code:t=>t.textContent!=null&&(/\r?\n/.test(t.textContent)||HA(t,"BR"))?{conversion:hT,priority:1}:null,div:()=>({conversion:RR,priority:1}),pre:()=>({conversion:hT,priority:0}),table:t=>Yp(t)?{conversion:FR,priority:3}:null,td:t=>{const e=t,s=e.closest("table");return e.classList.contains("js-file-line")||s&&Yp(s)?{conversion:gT,priority:3}:null},tr:t=>{const e=t.closest("table");return e&&Yp(e)?{conversion:gT,priority:3}:null}}}static importJSON(t){return xr().updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setLanguage(t.language)}exportJSON(){return{...super.exportJSON(),language:this.getLanguage()}}insertNewAfter(t,e=!0){const s=this.getChildren(),l=s.length;if(l>=2&&s[l-1].getTextContent()===`
`&&s[l-2].getTextContent()===`
`&&t.isCollapsed()&&t.anchor.key===this.__key&&t.anchor.offset===l){s[l-1].remove(),s[l-2].remove();const h=be();return this.insertAfter(h,e),h}const{anchor:o,focus:c}=t,f=(o.isBefore(c)?o:c).getNode();if(W(f)){let h=IR(f);const p=[];for(;;)if($d(h))p.push(Pl()),h=h.getNextSibling();else{if(!PA(h))break;{let x=0;const C=h.getTextContent(),w=h.getTextContentSize();for(;x<w&&C[x]===" ";)x++;if(x!==0&&p.push(KA(" ".repeat(x))),x!==w)break;h=h.getNextSibling()}}const y=f.splitText(o.offset)[0],m=o.offset===0?0:1,_=y.getIndexWithinParent()+m,S=f.getParentOrThrow(),v=[yi(),...p];S.splice(_,0,v);const A=p[p.length-1];A?A.select():o.offset===0?y.selectPrevious():y.getNextSibling().selectNext(0,0)}if(i_(f)){const{offset:h}=t.anchor;f.splice(h,0,[yi()]),f.select(h+1,h+1)}return null}canIndent(){return!1}collapseAtStart(){const t=be();return this.getChildren().forEach(e=>t.append(e)),this.replace(t),!0}setLanguage(t){const e=this.getWritable();return e.__language=t||void 0,e.__isSyntaxHighlightSupported=dT(t),e}getLanguage(){return this.getLatest().__language}getIsSyntaxHighlightSupported(){return this.getLatest().__isSyntaxHighlightSupported}}function xr(n){return Hn(new Wl(n))}function i_(n){return n instanceof Wl}function hT(n){return{node:xr(n.getAttribute(cu))}}function RR(n){const t=n,e=pT(t);return e||function(s){let l=s.parentElement;for(;l!==null;){if(pT(l))return!0;l=l.parentElement}return!1}(t)?{node:e?xr():null}:{node:null}}function FR(){return{node:xr()}}function gT(){return{node:null}}function pT(n){return n.style.fontFamily.match("monospace")!==null}function Yp(n){return n.classList.contains("js-file-line-container")}let YA=class qA extends Ts{constructor(t="",e,s){super(t,s),this.__highlightType=e}static getType(){return"code-highlight"}static clone(t){return new qA(t.__text,t.__highlightType||void 0,t.__key)}getHighlightType(){return this.getLatest().__highlightType}setHighlightType(t){const e=this.getWritable();return e.__highlightType=t||void 0,e}canHaveFormat(){return!1}createDOM(t){const e=super.createDOM(t),s=qp(t.theme,this.__highlightType);return bi(e,s),e}updateDOM(t,e,s){const l=super.updateDOM(t,e,s),o=qp(s.theme,t.__highlightType),c=qp(s.theme,this.__highlightType);return o!==c&&(o&&Xd(e,o),c&&bi(e,c)),l}static importJSON(t){return KA().updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setHighlightType(t.highlightType)}exportJSON(){return{...super.exportJSON(),highlightType:this.getHighlightType()}}setFormat(t){return this}isParentRequired(){return!0}createParentElementNode(){return xr()}};function qp(n,t){return t&&n&&n.codeHighlight&&n.codeHighlight[t]}function KA(n="",t){return Hn(new YA(n,t))}function PA(n){return n instanceof YA}function LR(n,t){let e=n;for(let s=Ge(n,t);s&&(PA(s.origin)||$d(s.origin));s=wB(s))e=s.origin;return e}function IR(n){return LR(n,"previous")}const kR=new Set(["http:","https:","mailto:","sms:","tel:"]);class wa extends $n{static getType(){return"link"}static clone(t){return new wa(t.__url,{rel:t.__rel,target:t.__target,title:t.__title},t.__key)}constructor(t="",e={},s){super(s);const{target:l=null,rel:o=null,title:c=null}=e;this.__url=t,this.__target=l,this.__rel=o,this.__title=c}createDOM(t){const e=document.createElement("a");return this.updateLinkDOM(null,e,t),bi(e,t.theme.link),e}updateLinkDOM(t,e,s){if(SA(e)){t&&t.__url===this.__url||(e.href=this.sanitizeUrl(this.__url));for(const l of["target","rel","title"]){const o=`__${l}`,c=this[o];t&&t[o]===c||(c?e[l]=c:e.removeAttribute(l))}}}updateDOM(t,e,s){return this.updateLinkDOM(t,e,s),!1}static importDOM(){return{a:t=>({conversion:UR,priority:1})}}static importJSON(t){return Nd().updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setURL(t.url).setRel(t.rel||null).setTarget(t.target||null).setTitle(t.title||null)}sanitizeUrl(t){t=mT(t);try{const e=new URL(mT(t));if(!kR.has(e.protocol))return"about:blank"}catch{return t}return t}exportJSON(){return{...super.exportJSON(),rel:this.getRel(),target:this.getTarget(),title:this.getTitle(),url:this.getURL()}}getURL(){return this.getLatest().__url}setURL(t){const e=this.getWritable();return e.__url=t,e}getTarget(){return this.getLatest().__target}setTarget(t){const e=this.getWritable();return e.__target=t,e}getRel(){return this.getLatest().__rel}setRel(t){const e=this.getWritable();return e.__rel=t,e}getTitle(){return this.getLatest().__title}setTitle(t){const e=this.getWritable();return e.__title=t,e}insertNewAfter(t,e=!0){const s=Nd(this.__url,{rel:this.__rel,target:this.__target,title:this.__title});return this.insertAfter(s,e),s}canInsertTextBefore(){return!1}canInsertTextAfter(){return!1}canBeEmpty(){return!1}isInline(){return!0}extractWithChild(t,e,s){if(!Z(e))return!1;const l=e.anchor.getNode(),o=e.focus.getNode();return this.isParentOf(l)&&this.isParentOf(o)&&e.getTextContent().length>0}isEmailURI(){return this.__url.startsWith("mailto:")}isWebSiteURI(){return this.__url.startsWith("https://")||this.__url.startsWith("http://")}}function UR(n){let t=null;if(SA(n)){const e=n.textContent;(e!==null&&e!==""||n.children.length>0)&&(t=Nd(n.getAttribute("href")||"",{rel:n.getAttribute("rel"),target:n.getAttribute("target"),title:n.getAttribute("title")}))}return{node:t}}function Nd(n="",t){return Hn(new wa(n,t))}function zR(n){return n instanceof wa}class Jd extends wa{constructor(t="",e={},s){super(t,e,s),this.__isUnlinked=e.isUnlinked!==void 0&&e.isUnlinked!==null&&e.isUnlinked}static getType(){return"autolink"}static clone(t){return new Jd(t.__url,{isUnlinked:t.__isUnlinked,rel:t.__rel,target:t.__target,title:t.__title},t.__key)}getIsUnlinked(){return this.__isUnlinked}setIsUnlinked(t){const e=this.getWritable();return e.__isUnlinked=t,e}createDOM(t){return this.__isUnlinked?document.createElement("span"):super.createDOM(t)}updateDOM(t,e,s){return super.updateDOM(t,e,s)||t.__isUnlinked!==this.__isUnlinked}static importJSON(t){return yT().updateFromJSON(t)}updateFromJSON(t){return super.updateFromJSON(t).setIsUnlinked(t.isUnlinked||!1)}static importDOM(){return null}exportJSON(){return{...super.exportJSON(),isUnlinked:this.__isUnlinked}}insertNewAfter(t,e=!0){const s=this.getParentOrThrow().insertNewAfter(t,e);if(Y(s)){const l=yT(this.__url,{isUnlinked:this.__isUnlinked,rel:this.__rel,target:this.__target,title:this.__title});return s.append(l),l}return null}}function yT(n="",t){return Hn(new Jd(n,t))}function $R(n){return n instanceof Jd}const jR=/^\+?[0-9\s()-]{5,}$/;function mT(n){return n.match(/^[a-z][a-z0-9+.-]*:/i)||n.match(/^[/#.]/)?n:n.includes("@")?`mailto:${n}`:jR.test(n)?`tel:${n}`:`https://${n}`}function Iy(n,t){const e={};for(const s of n){const l=t(s);l&&(e[l]?e[l].push(s):e[l]=[s])}return e}function r_(n){const t=Iy(n,e=>e.type);return{element:t.element||[],multilineElement:t["multiline-element"]||[],textFormat:t["text-format"]||[],textMatch:t["text-match"]||[]}}const Cd=/[!-/:-@[-`{-~\s]/,VR=/^\s{0,3}$/;function ky(n){if(!Yd(n))return!1;const t=n.getFirstChild();return t==null||n.getChildrenSize()===1&&W(t)&&VR.test(t.getTextContent())}function HR(n,t,e,s){for(const l of t){if(!l.export)continue;const o=l.export(n,c=>Dd(c,e,s));if(o!=null)return o}return Y(n)?Dd(n,e,s):qt(n)?n.getTextContent():null}function Dd(n,t,e,s,l){const o=[],c=n.getChildren();s||(s=[]),l||(l=[]);t:for(const f of c){for(const h of e){if(!h.export)continue;const p=h.export(f,y=>Dd(y,t,e,s,[...l,...s]),(y,m)=>_T(y,m,t,s,l));if(p!=null){o.push(p);continue t}}os(f)?o.push(`
`):W(f)?o.push(_T(f,f.getTextContent(),t,s,l)):Y(f)?o.push(Dd(f,t,e,s,l)):qt(f)&&o.push(f.getTextContent())}return o.join("")}function _T(n,t,e,s,l){let o=n.getFormat()===0?t:function(_){return _.replace(/^\s+|\s+$/g,S=>[...S].map(v=>"&#"+v.codePointAt(0)+";").join(""))}(t);n.hasFormat("code")||(o=o.replace(/([*_`~\\])/g,"\\$1"));let c="",f="",h="";const p=bT(n,!0),y=bT(n,!1),m=new Set;for(const _ of e){const S=_.format[0],v=_.tag;Sf(n,S)&&!m.has(S)&&(m.add(S),Sf(p,S)&&s.find(A=>A.tag===v)||(s.push({format:S,tag:v}),c+=v))}for(let _=0;_<s.length;_++){const S=Sf(n,s[_].format),v=Sf(y,s[_].format);if(S&&v)continue;const A=[...s];for(;A.length>_;){const x=A.pop();l&&x&&l.find(C=>C.tag===x.tag)||(x&&typeof x.tag=="string"&&(S?v||(h+=x.tag):f+=x.tag),s.pop())}break}return o=c+o+h,f+o}function bT(n,t){let e=t?n.getPreviousSibling():n.getNextSibling();if(!e){const s=n.getParentOrThrow();s.isInline()&&(e=t?s.getPreviousSibling():s.getNextSibling())}for(;e;){if(Y(e)){if(!e.isInline())break;const s=t?e.getLastDescendant():e.getFirstDescendant();if(W(s))return s;e=t?e.getPreviousSibling():e.getNextSibling()}if(W(e))return e;if(!Y(e))return null}return null}function Sf(n,t){return W(n)&&n.hasFormat(t)}function YR(n,t){const e=function(l,o){const c=l.match(o.openTagsRegExp);if(c==null)return null;for(const f of c){const h=f.replace(/^\s/,""),p=o.fullMatchRegExpByTag[h];if(p==null)continue;const y=l.match(p),m=o.transformersByTag[h];if(y!=null&&m!=null){if(m.intraword!==!1)return y;const{index:_=0}=y,S=l[_-1],v=l[_+y[0].length];if((!S||Cd.test(S))&&(!v||Cd.test(v)))return y}}return null}(n.getTextContent(),t);if(!e)return null;const s=e.index||0;return{endIndex:s+e[0].length,match:e,startIndex:s,transformer:t.transformersByTag[e[1]]}}function Ps(n){return W(n)&&!n.hasFormat("code")}function Gs(n,t,e){let s=YR(n,t),l=function(c,f){const h=c;let p,y,m,_;for(const S of f){if(!S.replace||!S.importRegExp)continue;const v=h.getTextContent().match(S.importRegExp);if(!v)continue;const A=v.index||0,x=S.getEndIndex?S.getEndIndex(h,v):A+v[0].length;x!==!1&&(p===void 0||y===void 0||A<p&&x>y)&&(p=A,y=x,m=S,_=v)}return p===void 0||y===void 0||m===void 0||_===void 0?null:{endIndex:y,match:_,startIndex:p,transformer:m}}(n,e);if(s&&l&&(s.startIndex<=l.startIndex&&s.endIndex>=l.endIndex?l=null:s=null),s){const c=function(f,h,p,y,m){const _=f.getTextContent();let S,v,A;if(m[0]===_?S=f:h===0?[S,v]=f.splitText(p):[A,S,v]=f.splitText(h,p),S.setTextContent(m[2]),y)for(const x of y.format)S.hasFormat(x)||S.toggleFormat(x);return{nodeAfter:v,nodeBefore:A,transformedNode:S}}(n,s.startIndex,s.endIndex,s.transformer,s.match);Ps(c.nodeAfter)&&Gs(c.nodeAfter,t,e),Ps(c.nodeBefore)&&Gs(c.nodeBefore,t,e),Ps(c.transformedNode)&&Gs(c.transformedNode,t,e)}else if(l){const c=function(f,h,p,y,m){let _,S,v;return h===0?[_,S]=f.splitText(p):[v,_,S]=f.splitText(h,p),y.replace?{nodeAfter:S,nodeBefore:v,transformedNode:y.replace(_,m)||void 0}:null}(n,l.startIndex,l.endIndex,l.transformer,l.match);if(!c)return;Ps(c.nodeAfter)&&Gs(c.nodeAfter,t,e),Ps(c.nodeBefore)&&Gs(c.nodeBefore,t,e),Ps(c.transformedNode)&&Gs(c.transformedNode,t,e)}const o=n.getTextContent().replace(/\\([*_`~\\])/g,"$1").replace(/&#(\d+);/g,(c,f)=>String.fromCodePoint(f));n.setTextContent(o)}function qR(n,t=!1){const e=r_(n),s=function(l){const o={},c={},f=[],h="(?<![\\\\])";for(const p of l){const{tag:y}=p;o[y]=p;const m=y.replace(/(\*|\^|\+)/g,"\\$1");f.push(m),y.length===1?c[y]=new RegExp(`(?<![\\\\${m}])(${m})((\\\\${m})?.*?[^${m}\\s](\\\\${m})?)((?<!\\\\)|(?<=\\\\\\\\))(${m})(?![\\\\${m}])`):c[y]=new RegExp(`(?<!\\\\)(${m})((\\\\${m})?.*?[^\\s](\\\\${m})?)((?<!\\\\)|(?<=\\\\\\\\))(${m})(?!\\\\)`)}return{fullMatchRegExpByTag:c,openTagsRegExp:new RegExp(`${h}(${f.join("|")})`,"g"),transformersByTag:o}}(e.textFormat);return(l,o)=>{const c=l.split(`
`),f=c.length,h=o||ge();h.clear();for(let y=0;y<f;y++){const m=c[y],[_,S]=KR(c,y,e.multilineElement,h);_?y=S:PR(m,h,e.element,s,e.textMatch,t)}const p=h.getChildren();for(const y of p)!t&&ky(y)&&h.getChildrenSize()>1&&y.remove();nt()!==null&&h.selectStart()}}function KR(n,t,e,s){for(const l of e){const{handleImportAfterStartMatch:o,regExpEnd:c,regExpStart:f,replace:h}=l,p=n[t].match(f);if(!p)continue;if(o){const v=o({lines:n,rootNode:s,startLineIndex:t,startMatch:p,transformer:l});if(v===null)continue;if(v)return v}const y=typeof c=="object"&&"regExp"in c?c.regExp:c,m=c&&typeof c=="object"&&"optional"in c?c.optional:!c;let _=t;const S=n.length;for(;_<S;){const v=y?n[_].match(y):null;if(!v&&(!m||m&&_<S-1)){_++;continue}if(v&&t===_&&v.index===p.index){_++;continue}const A=[];if(v&&t===_)A.push(n[t].slice(p[0].length,-v[0].length));else for(let x=t;x<=_;x++)if(x===t){const C=n[x].slice(p[0].length);A.push(C)}else if(x===_&&v){const C=n[x].slice(0,-v[0].length);A.push(C)}else A.push(n[x]);if(h(s,null,p,v,A,!0)!==!1)return[!0,_];break}}return[!1,t]}function PR(n,t,e,s,l,o){const c=Ee(n),f=be();f.append(c),t.append(f);for(const{regExp:h,replace:p}of e){const y=n.match(h);if(y&&(c.setTextContent(n.slice(y[0].length)),p(f,[c],y,!0)!==!1))break}if(Gs(c,s,l),f.isAttached()&&n.length>0){const h=f.getPreviousSibling();if(!o&&(Yd(h)||Cy(h)||Tt(h))){let p=h;if(Tt(h)){const y=h.getLastDescendant();p=y==null?null:Pu(y,Pt)}p!=null&&p.getTextContentSize()>0&&(p.splice(p.getChildrenSize(),0,[yi(),...f.getChildren()]),f.remove())}}}function GR(n,...t){const e=new URL("https://lexical.dev/docs/error"),s=new URLSearchParams;s.append("code",n);for(const l of t)s.append("v",l);throw e.search=s.toString(),Error(`Minified Lexical error #${n}; visit ${e.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}function vT(n,t,e){const s=e.length;for(let l=t;l>=s;l--){const o=l-s;if(GA(n,o,e,0,s)&&n[o+s]!==" ")return o}return-1}function GA(n,t,e,s,l){for(let o=0;o<l;o++)if(n[t+o]!==e[s+o])return!1;return!0}function ZR(n,t=cs){const e=r_(t),s=Iy(e.textFormat,({tag:c})=>c[c.length-1]),l=Iy(e.textMatch,({trigger:c})=>c);for(const c of t){const f=c.type;if(f==="element"||f==="text-match"||f==="multiline-element"){const h=c.dependencies;for(const p of h)n.hasNode(p)||GR(173,p.getType())}}const o=(c,f,h)=>{(function(p,y,m,_){const S=p.getParent();if(!un(S)||p.getFirstChild()!==y)return!1;const v=y.getTextContent();if(v[m-1]!==" ")return!1;for(const{regExp:A,replace:x}of _){const C=v.match(A);if(C&&C[0].length===(C[0].endsWith(" ")?m:m-1)){const w=y.getNextSiblings(),[E,M]=y.splitText(m);if(x(p,M?[M,...w]:w,C,!1)!==!1)return E.remove(),!0}}return!1})(c,f,h,e.element)||function(p,y,m,_){const S=p.getParent();if(!un(S)||p.getFirstChild()!==y)return!1;const v=y.getTextContent();if(v[m-1]!==" ")return!1;for(const{regExpStart:A,replace:x,regExpEnd:C}of _){if(C&&!("optional"in C)||C&&"optional"in C&&!C.optional)continue;const w=v.match(A);if(w&&w[0].length===(w[0].endsWith(" ")?m:m-1)){const E=y.getNextSiblings(),[M,O]=y.splitText(m);if(x(p,O?[O,...E]:E,w,null,null,!1)!==!1)return M.remove(),!0}}return!1}(c,f,h,e.multilineElement)||function(p,y,m){let _=p.getTextContent();const S=m[_[y-1]];if(S==null)return!1;y<_.length&&(_=_.slice(0,y));for(const v of S){if(!v.replace||!v.regExp)continue;const A=_.match(v.regExp);if(A===null)continue;const x=A.index||0,C=x+A[0].length;let w;return x===0?[w]=p.splitText(C):[,w]=p.splitText(x,C),w.selectNext(0,0),v.replace(w,A),!0}return!1}(f,h,l)||function(p,y,m){const _=p.getTextContent(),S=y-1,v=_[S],A=m[v];if(!A)return!1;for(const x of A){const{tag:C}=x,w=C.length,E=S-w+1;if(w>1&&!GA(_,E,C,0,w)||_[E-1]===" ")continue;const M=_[S+1];if(x.intraword===!1&&M&&!Cd.test(M))continue;const O=p;let D=O,I=vT(_,E,C),z=D;for(;I<0&&(z=z.getPreviousSibling())&&!os(z);)if(W(z)){if(z.hasFormat("code"))continue;const Q=z.getTextContent();D=z,I=vT(Q,Q.length,C)}if(I<0||D===O&&I+w===E)continue;const L=D.getTextContent();if(I>0&&L[I-1]===v)continue;const J=L[I-1];if(x.intraword===!1&&J&&!Cd.test(J))continue;const rt=O.getTextContent(),dt=rt.slice(0,E)+rt.slice(S+1);O.setTextContent(dt);const vt=D===O?dt:L;D.setTextContent(vt.slice(0,I)+vt.slice(I+w));const mt=nt(),ut=Vd();Ze(ut);const H=S-w*(D===O?2:1)+1;ut.anchor.set(D.__key,I,"text"),ut.focus.set(O.__key,H,"text");for(const Q of x.format)ut.hasFormat(Q)||ut.formatText(Q);ut.anchor.set(ut.focus.key,ut.focus.offset,ut.focus.type);for(const Q of x.format)ut.hasFormat(Q)&&ut.toggleFormat(Q);return Z(mt)&&(ut.format=mt.format),!0}}(f,h,s)};return n.registerUpdateListener(({tags:c,dirtyLeaves:f,editorState:h,prevEditorState:p})=>{if(c.has(oA)||c.has(Td)||n.isComposing())return;const y=h.read(nt),m=p.read(nt);if(!Z(m)||!Z(y)||!y.isCollapsed()||y.is(m))return;const _=y.anchor.key,S=y.anchor.offset,v=h._nodeMap.get(_);!W(v)||!f.has(_)||S!==1&&S>m.anchor.offset+1||n.update(()=>{if(!Ps(v))return;const A=v.getParent();A===null||i_(A)||o(A,v,y.anchor.offset)})})}const ZA=/^(\s*)(\d{1,})\.\s/,XA=/^(\s*)[-*+]\s/,XR=/^(\s*)(?:-\s)?\s?(\[(\s|x)?\])\s/i,Uy=/^(#{1,6})\s/,QA=/^>\s/,JA=/^[ \t]*```([\w-]+)?/,WA=/[ \t]*```$/,QR=/^[ \t]*```[^`]+(?:(?:`{1,2}|`{4,})[^`]+)*```(?:[^`]|$)/,JR=/^(?:\|)(.+)(?:\|)\s?$/,WR=/^(\| ?:?-*:? ?)+\|\s?$/,tE=n=>(t,e,s,l)=>{const o=n(s);o.append(...e),t.replace(o),l||o.select(0,0)},eE=n=>(t,e,s,l)=>{const o=t.getPreviousSibling(),c=t.getNextSibling(),f=jn(n==="check"?s[3]==="x":void 0);if(Tt(c)&&c.getListType()===n){const p=c.getFirstChild();p!==null?p.insertBefore(f):c.append(f),t.remove()}else if(Tt(o)&&o.getListType()===n)o.append(f),t.remove();else{const p=Sn(n,n==="number"?Number(s[2]):void 0);p.append(f),t.replace(p)}f.append(...e),l||f.select(0,0);const h=function(p){const y=p.match(/\t/g),m=p.match(/ /g);let _=0;return y&&(_+=y.length),m&&(_+=Math.floor(m.length/4)),_}(s[1]);h&&f.setIndent(h)},s_=(n,t,e)=>{const s=[],l=n.getChildren();let o=0;for(const c of l)if(Pt(c)){if(c.getChildrenSize()===1){const y=c.getFirstChild();if(Tt(y)){s.push(s_(y,t,e+1));continue}}const f=" ".repeat(4*e),h=n.getListType(),p=h==="number"?`${n.getStart()+o}. `:h==="check"?`- [${c.getChecked()?"x":" "}] `:"- ";s.push(f+p+t(c)),o++}return s.join(`
`)},t3={dependencies:[Qd],export:(n,t)=>{if(!HB(n))return null;const e=Number(n.getTag().slice(1));return"#".repeat(e)+" "+t(n)},regExp:Uy,replace:tE(n=>{const t="h"+n[1].length;return ra(t)}),type:"element"},e3={dependencies:[Jl],export:(n,t)=>{if(!Cy(n))return null;const e=t(n).split(`
`),s=[];for(const l of e)s.push("> "+l);return s.join(`
`)},regExp:QA,replace:(n,t,e,s)=>{if(s){const o=n.getPreviousSibling();if(Cy(o))return o.splice(o.getChildrenSize(),0,[yi(),...t]),void n.remove()}const l=e_();l.append(...t),n.replace(l),s||l.select(0,0)},type:"element"},n3={dependencies:[Wl],export:n=>{if(!i_(n))return null;const t=n.getTextContent();return"```"+(n.getLanguage()||"")+(t?`
`+t:"")+"\n```"},regExpEnd:{optional:!0,regExp:WA},regExpStart:JA,replace:(n,t,e,s,l,o)=>{let c,f;if(!t&&l){if(l.length===1)s?(c=xr(),f=e[1]+l[0]):(c=xr(e[1]),f=l[0].startsWith(" ")?l[0].slice(1):l[0]);else{if(c=xr(e[1]),l[0].trim().length===0)for(;l.length>0&&!l[0].length;)l.shift();else l[0]=l[0].startsWith(" ")?l[0].slice(1):l[0];for(;l.length>0&&!l[l.length-1].length;)l.pop();f=l.join(`
`)}const h=Ee(f);c.append(h),n.append(c)}else t&&tE(h=>xr(h?h[1]:void 0))(n,t,e,o)},type:"multiline-element"},i3={dependencies:[Ta,As],export:(n,t)=>Tt(n)?s_(n,t,0):null,regExp:XA,replace:eE("bullet"),type:"element"},r3={dependencies:[Ta,As],export:(n,t)=>Tt(n)?s_(n,t,0):null,regExp:ZA,replace:eE("number"),type:"element"},s3={format:["code"],tag:"`",type:"text-format"},a3={format:["highlight"],tag:"==",type:"text-format"},l3={format:["bold","italic"],tag:"***",type:"text-format"},o3={format:["bold","italic"],intraword:!1,tag:"___",type:"text-format"},u3={format:["bold"],tag:"**",type:"text-format"},c3={format:["bold"],intraword:!1,tag:"__",type:"text-format"},f3={format:["strikethrough"],tag:"~~",type:"text-format"},d3={format:["italic"],tag:"*",type:"text-format"},h3={format:["italic"],intraword:!1,tag:"_",type:"text-format"},g3={dependencies:[wa],export:(n,t,e)=>{if(!zR(n)||$R(n))return null;const s=n.getTitle(),l=t(n);return s?`[${l}](${n.getURL()} "${s}")`:`[${l}](${n.getURL()})`},importRegExp:/(?:\[([^[]+)\])(?:\((?:([^()\s]+)(?:\s"((?:[^"]*\\")*[^"]*)"\s*)?)\))/,regExp:/(?:\[([^[]+)\])(?:\((?:([^()\s]+)(?:\s"((?:[^"]*\\")*[^"]*)"\s*)?)\))$/,replace:(n,t)=>{const[,e,s,l]=t,o=Nd(s,{title:l}),c=Ee(e);return c.setFormat(n.getFormat()),o.append(c),n.replace(o),c},trigger:")",type:"text-match"},p3=[t3,e3,i3,r3],y3=[n3],m3=[s3,l3,o3,u3,c3,a3,d3,h3,f3],_3=[g3],cs=[...p3,...y3,...m3,..._3];function nE(n,t=cs,e,s=!1,l=!1){const o=s?n:function(c,f=!1){const h=c.split(`
`);let p=!1;const y=[];for(let m=0;m<h.length;m++){const _=h[m],S=y[y.length-1];QR.test(_)?y.push(_):JA.test(_)||WA.test(_)?(p=!p,y.push(_)):p||_===""||S===""||!S||Uy.test(S)||Uy.test(_)||QA.test(_)||ZA.test(_)||XA.test(_)||XR.test(_)||JR.test(_)||WR.test(_)||!f?y.push(_):y[y.length-1]=S+_}return y.join(`
`)}(n,l);return qR(t,s)(o,e)}function b3(n=cs,t,e=!1){return function(l,o=!1){const c=r_(l),f=[...c.multilineElement,...c.element],h=!o,p=c.textFormat.filter(y=>y.format.length===1).sort((y,m)=>Number(y.format.includes("code"))-Number(m.format.includes("code")));return y=>{const m=[],_=(y||ge()).getChildren();for(let S=0;S<_.length;S++){const v=_[S],A=HR(v,f,p,c.textMatch);A!=null&&m.push(h&&S>0&&!ky(v)&&!ky(_[S-1])?`
`.concat(A):A)}return m.join(`
`)}}(n,e)(t)}function ST(n,t){return n.getEditorState().read(()=>{const e=Ce(t);return e!==null&&e.isSelected()})}function v3(n){const[t]=Vn(),[e,s]=ft.useState(()=>ST(t,n));return ft.useEffect(()=>{let l=!0;const o=t.registerUpdateListener(()=>{l&&s(ST(t,n))});return()=>{l=!1,o()}},[t,n]),[e,ft.useCallback(l=>{t.update(()=>{let o=nt();tn(o)||(o=Cm(),Ze(o)),tn(o)&&(l?o.add(n):o.delete(n))})},[t,n]),ft.useCallback(()=>{t.update(()=>{const l=nt();tn(l)&&l.clear()})},[t])]}function S3({nodeKey:n}){const[t]=Vn(),[e,s,l]=v3(n);return ft.useEffect(()=>xs(t.registerCommand(Am,o=>{const c=t.getElementByKey(n);return o.target===c&&(o.shiftKey||l(),s(!e),!0)},ml)),[l,t,e,n,s]),ft.useEffect(()=>{const o=t.getElementByKey(n),c=t._config.theme.hrSelected??"selected";o!==null&&(e?bi(o,c):Xd(o,c))},[t,e,n]),null}class to extends Rm{static getType(){return"horizontalrule"}static clone(t){return new to(t.__key)}static importJSON(t){return a_().updateFromJSON(t)}static importDOM(){return{hr:()=>({conversion:T3,priority:0})}}exportDOM(){return{element:document.createElement("hr")}}createDOM(t){const e=document.createElement("hr");return bi(e,t.theme.hr),e}getTextContent(){return`
`}isInline(){return!1}updateDOM(){return!1}decorate(){return gt.jsx(S3,{nodeKey:this.__key})}}function T3(){return{node:a_()}}function a_(){return Hn(new to)}function w3(n){return n instanceof to}const x3=[{dependencies:[to],export:n=>w3(n)?"***":null,regExp:/^(---|\*\*\*|___)\s?$/,replace:(n,t,e,s)=>{const l=a_();s||n.getNextSibling()!=null?n.replace(l):n.insertBefore(l),l.selectNext()},type:"element"},...cs];function A3({transformers:n=x3}){const[t]=Vn();return ft.useEffect(()=>ZR(t,n),[t,n]),null}function E3({hasStrictIndent:n=!1}){const[t]=Vn();return ft.useEffect(()=>{if(!t.hasNodes([Ta,As]))throw new Error("ListPlugin: ListNode and/or ListItemNode not registered on editor")},[t]),ft.useEffect(()=>{if(n)return ER(t)},[t,n]),function(e){ft.useEffect(()=>AR(e),[e])}(t),null}class O3 extends N2{constructor(){super(...arguments),this.state={editorState:""},this.markdownRef={current:this.props.args.value},this.editorConfig={namespace:`MyStreamlitRichTextEditor-${this.props.args.key}`,theme:dR,onError:t=>{console.error("Lexical error:",t)},editorState:()=>nE(this.props.args.value,cs,void 0,!0),nodes:[to,Qd,Jl,Wl,Ta,As,wa]},this.render=()=>{const{theme:t,args:e}=this.props,s={};return t&&(s.borderColor=t.primaryColor),gt.jsx("div",{style:s,className:"streamlit-lexical-editor",children:gt.jsxs(uB,{initialConfig:this.editorConfig,children:[gt.jsx(N3,{content:e.value,overwrite:e.overwrite,currentMarkdown:this.markdownRef.current}),gt.jsxs("div",{className:"editor-container",children:[gt.jsx(fR,{}),gt.jsxs("div",{className:"editor-inner",children:[gt.jsx(qB,{contentEditable:gt.jsx(ZB,{className:"editor-input",style:{minHeight:`${e.min_height}px`,maxHeight:`${e.min_height}px`,overflowY:"auto"}}),placeholder:gt.jsx(C3,{text:e.placeholder}),ErrorBoundary:cR}),gt.jsx(sR,{}),gt.jsx(aR,{}),gt.jsx(A3,{transformers:cs}),gt.jsx(E3,{}),gt.jsx(oR,{onChange:this.handleEditorChange})]})]})]})})},this.handleEditorChange=t=>{t.read(()=>{const e=b3(cs,void 0,!0);this.debouncedSetComponentValue(e)})},this.debouncedSetComponentValue=D3(t=>{this.markdownRef.current=t,br.setComponentValue(t)},this.props.args.debounce)}}function N3({content:n,overwrite:t,currentMarkdown:e}){const[s]=Vn();return ft.useEffect(()=>{n!==e&&s.update(()=>{const l=ge();(l.getTextContent()===""||t)&&(l.clear(),nE(n,cs,void 0,!0),s.dispatchCommand(Vx,void 0))})},[s,n,t]),null}function C3({text:n}){return gt.jsx("div",{className:"editor-placeholder",children:n})}function D3(n,t){let e=null;return function(...s){e&&clearTimeout(e),e=setTimeout(()=>{n.apply(this,s)},t)}}const M3=C2(O3);IN.createRoot(document.getElementById("root")).render(gt.jsx(Zs.StrictMode,{children:gt.jsx(M3,{})}));
